fix: Remove image dublicate (#271)

This commit is contained in:
Petr Mironychev
2025-11-20 23:25:00 +01:00
committed by GitHub
parent 24565dc81f
commit a3527e1442
8 changed files with 70 additions and 51 deletions

View File

@ -61,12 +61,18 @@ ChatRootView {
SplitDropZone {
anchors.fill: parent
onFilesDroppedToAttach: (filePaths) => {
root.addFilesToAttachList(filePaths)
onFilesDroppedToAttach: (urlStrings) => {
var localPaths = root.convertUrlsToLocalPaths(urlStrings)
if (localPaths.length > 0) {
root.addFilesToAttachList(localPaths)
}
}
onFilesDroppedToLink: (filePaths) => {
root.addFilesToLinkList(filePaths)
onFilesDroppedToLink: (urlStrings) => {
var localPaths = root.convertUrlsToLocalPaths(urlStrings)
if (localPaths.length > 0) {
root.addFilesToLinkList(localPaths)
}
}
}