@@ -41,7 +41,7 @@
diff --git a/frontend/src/components/prompts/Rename.vue b/frontend/src/components/prompts/Rename.vue
index f18ed7a089..4e1bb095bc 100644
--- a/frontend/src/components/prompts/Rename.vue
+++ b/frontend/src/components/prompts/Rename.vue
@@ -6,7 +6,7 @@
- {{ $t("prompts.renameMessage") }} {{ oldName() }}{{ oldName }}:
{{ $t("buttons.rename") }}
@@ -56,7 +57,7 @@ export default {
};
},
created() {
- this.name = this.oldName();
+ this.name = this.oldName;
},
inject: ["$showError"],
computed: {
@@ -67,25 +68,28 @@ export default {
"isListing",
]),
...mapWritableState(useFileStore, ["reload", "preselect"]),
- },
- methods: {
- ...mapActions(useLayoutStore, ["closeHovers"]),
- cancel: function () {
- this.closeHovers();
- },
- oldName: function () {
+ oldName() {
if (!this.isListing) {
return this.req.name;
}
if (this.selectedCount === 0 || this.selectedCount > 1) {
// This shouldn't happen.
- return;
+ return "";
}
return this.req.items[this.selected[0]].name;
},
+ },
+ methods: {
+ ...mapActions(useLayoutStore, ["closeHovers"]),
+ cancel: function () {
+ this.closeHovers();
+ },
submit: async function () {
+ if (this.name === "" || this.name === this.oldName) {
+ return;
+ }
let oldLink = "";
let newLink = "";
diff --git a/frontend/src/components/prompts/ReplaceRename.vue b/frontend/src/components/prompts/ReplaceRename.vue
deleted file mode 100644
index 1d49d735bd..0000000000
--- a/frontend/src/components/prompts/ReplaceRename.vue
+++ /dev/null
@@ -1,57 +0,0 @@
-
-
-
-
{{ $t("prompts.replace") }}
-
-
-
-
{{ $t("prompts.replaceMessage") }}
-
-
-
-
-
-
-
-
-
-
-
diff --git a/frontend/src/components/prompts/ResolveConflict.vue b/frontend/src/components/prompts/ResolveConflict.vue
new file mode 100644
index 0000000000..e7bf9c7462
--- /dev/null
+++ b/frontend/src/components/prompts/ResolveConflict.vue
@@ -0,0 +1,307 @@
+
+
+
+
+ {{
+ personalized
+ ? $t("prompts.resolveConflict")
+ : $t("prompts.replaceOrSkip")
+ }}
+
+
+
+
+
+
+ {{ $t("prompts.singleConflictResolve") }}
+
+
+
+
+
+
+ {{ item.name }}
+
+
+
+ {{ $t("prompts.rename") }}
+
+
+ {{ $t("prompts.forbiddenError") }}
+
+
+
+ {{ $t("prompts.override") }}
+
+
+ {{ $t("prompts.skip") }}
+
+
+
+
+
+
+ {{ humanTime(item.origin.lastModified) }}
+
+
+ {{ humanSize(item.origin.size) }}
+
+
+
+
+
+
+
+ {{ humanTime(item.dest.lastModified) }}
+
+
+ {{ humanSize(item.dest.size) }}
+
+
+
+
+
+
+
+
+
+ {{ $t("prompts.fastConflictResolve", { count: conflict.length }) }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/frontend/src/components/prompts/Upload.vue b/frontend/src/components/prompts/Upload.vue
index 75f7951f26..19b1fbb175 100644
--- a/frontend/src/components/prompts/Upload.vue
+++ b/frontend/src/components/prompts/Upload.vue
@@ -69,18 +69,29 @@ const uploadInput = (event: Event) => {
const path = route.path.endsWith("/") ? route.path : route.path + "/";
const conflict = upload.checkConflict(uploadFiles, fileStore.req!.items);
- if (conflict) {
+ if (conflict.length > 0) {
layoutStore.showHover({
- prompt: "replace",
- action: (event: Event) => {
- event.preventDefault();
- layoutStore.closeHovers();
- upload.handleFiles(uploadFiles, path, false);
+ prompt: "resolve-conflict",
+ props: {
+ conflict: conflict,
+ isUploadAction: true,
},
- confirm: (event: Event) => {
+ confirm: (event: Event, result: Array
) => {
event.preventDefault();
layoutStore.closeHovers();
- upload.handleFiles(uploadFiles, path, true);
+ for (let i = result.length - 1; i >= 0; i--) {
+ const item = result[i];
+ if (item.checked.length == 2) {
+ continue;
+ } else if (item.checked.length == 1 && item.checked[0] == "origin") {
+ uploadFiles[item.index].overwrite = true;
+ } else {
+ uploadFiles.splice(item.index, 1);
+ }
+ }
+ if (uploadFiles.length > 0) {
+ upload.handleFiles(uploadFiles, path);
+ }
},
});
diff --git a/frontend/src/css/base.css b/frontend/src/css/base.css
index f0b8ef0cee..cdb3319bf8 100644
--- a/frontend/src/css/base.css
+++ b/frontend/src/css/base.css
@@ -182,10 +182,11 @@ html[dir="rtl"] .breadcrumbs a {
background: var(--textSecondary) !important;
}
-.vfm-modal {
- z-index: 9999999 !important;
-}
-
body > div[style*="z-index: 9990"] {
z-index: 10000 !important;
}
+
+#modal-background .button:focus {
+ outline: 1px solid #2195f32d;
+ outline-offset: 1px;
+}
diff --git a/frontend/src/css/styles.css b/frontend/src/css/styles.css
index 5ac7d8d516..bab7cd192d 100644
--- a/frontend/src/css/styles.css
+++ b/frontend/src/css/styles.css
@@ -1,6 +1,5 @@
@import "normalize.css/normalize.css";
@import "vue-toastification/dist/index.css";
-@import "vue-final-modal/style.css";
@import "./_variables.css";
@import "./_buttons.css";
@import "./_inputs.css";
diff --git a/frontend/src/i18n/ar.json b/frontend/src/i18n/ar.json
index cf600a381b..5df31c3ff4 100644
--- a/frontend/src/i18n/ar.json
+++ b/frontend/src/i18n/ar.json
@@ -48,7 +48,11 @@
"saveChanges": "حفظ التغييرات",
"editAsText": "تعديل على شكل نص",
"increaseFontSize": "زيادة حجم الخط",
- "decreaseFontSize": "تصغير حجم الخط"
+ "decreaseFontSize": "تصغير حجم الخط",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "تحميل الملف",
@@ -161,7 +165,17 @@
"uploadMessage": "إختر الملفات التي تريد رفعها.",
"optionalPassword": "كلمة مرور إختيارية",
"resolution": "الدقة",
- "discardEditorChanges": "هل تريد بالتأكيد إلغاء التغييرات؟"
+ "discardEditorChanges": "هل تريد بالتأكيد إلغاء التغييرات؟",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "الصور",
diff --git a/frontend/src/i18n/bg.json b/frontend/src/i18n/bg.json
index db4ece315a..582c1059e3 100644
--- a/frontend/src/i18n/bg.json
+++ b/frontend/src/i18n/bg.json
@@ -48,7 +48,11 @@
"saveChanges": "Запиши промените",
"editAsText": "Edit as Text",
"increaseFontSize": "Increase font size",
- "decreaseFontSize": "Decrease font size"
+ "decreaseFontSize": "Decrease font size",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Свали файл",
@@ -161,7 +165,17 @@
"uploadMessage": "Изберете опция за качване.",
"optionalPassword": "Опционална парола",
"resolution": "Резолюция",
- "discardEditorChanges": "Сигурни ли сте, че искате да откажете направените промени?"
+ "discardEditorChanges": "Сигурни ли сте, че искате да откажете направените промени?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "Изображения",
diff --git a/frontend/src/i18n/ca.json b/frontend/src/i18n/ca.json
index da6dfcc99a..c9e64b0f2d 100644
--- a/frontend/src/i18n/ca.json
+++ b/frontend/src/i18n/ca.json
@@ -48,7 +48,11 @@
"saveChanges": "Save changes",
"editAsText": "Edit as Text",
"increaseFontSize": "Increase font size",
- "decreaseFontSize": "Decrease font size"
+ "decreaseFontSize": "Decrease font size",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Descarregar fitxer",
@@ -161,7 +165,17 @@
"uploadMessage": "Seleccioneu una opció per pujar.",
"optionalPassword": "Contrasenya opcional",
"resolution": "Resolució",
- "discardEditorChanges": "Esteu segur que voleu descartar els canvis que heu fet?"
+ "discardEditorChanges": "Esteu segur que voleu descartar els canvis que heu fet?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "Imatges",
diff --git a/frontend/src/i18n/cs.json b/frontend/src/i18n/cs.json
index 560e015c91..5d08768ac6 100644
--- a/frontend/src/i18n/cs.json
+++ b/frontend/src/i18n/cs.json
@@ -48,7 +48,11 @@
"saveChanges": "Save changes",
"editAsText": "Edit as Text",
"increaseFontSize": "Increase font size",
- "decreaseFontSize": "Decrease font size"
+ "decreaseFontSize": "Decrease font size",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Stáhnout soubor",
@@ -161,7 +165,17 @@
"uploadMessage": "Vyberte možnost pro nahrání.",
"optionalPassword": "Volitelné heslo",
"resolution": "Rozlišení",
- "discardEditorChanges": "Opravdu chcete zrušit provedené změny?"
+ "discardEditorChanges": "Opravdu chcete zrušit provedené změny?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "Obrázky",
diff --git a/frontend/src/i18n/de.json b/frontend/src/i18n/de.json
index 0cd29ba839..bacaf0fa96 100644
--- a/frontend/src/i18n/de.json
+++ b/frontend/src/i18n/de.json
@@ -42,13 +42,17 @@
"update": "Aktualisieren",
"upload": "Hochladen",
"openFile": "Datei öffnen",
- "openDirect": "View raw",
+ "openDirect": "Original anzeigen",
"discardChanges": "Verwerfen",
"stopSearch": "Suche beenden",
"saveChanges": "Änderungen speichern",
"editAsText": "Als Text bearbeiten",
"increaseFontSize": "Schrift vergrößern",
- "decreaseFontSize": "Schrift verkleinern"
+ "decreaseFontSize": "Schrift verkleinern",
+ "overrideAll": "Alle Dateien im Zielordner ersetzen",
+ "skipAll": "Alle in Konflikt stehenden Dateien überspringen",
+ "renameAll": "Alle Dateien umbenennen (Kopie erstellen)",
+ "singleDecision": "Bei jeder Datei mit Konflikt entscheiden"
},
"download": {
"downloadFile": "Datei herunterladen",
@@ -161,7 +165,17 @@
"uploadMessage": "Wähle eine Upload-Option.",
"optionalPassword": "Optionales Passwort",
"resolution": "Auflösung",
- "discardEditorChanges": "Möchtest du deine Änderungen wirklich verwerfen?"
+ "discardEditorChanges": "Möchtest du deine Änderungen wirklich verwerfen?",
+ "replaceOrSkip": "Dateien ersetzen oder überspringen",
+ "resolveConflict": "Welche Dateien möchtest du behalten?",
+ "singleConflictResolve": "Wenn du beide Versionen auswählst, wird dem Namen der kopierten Datei eine Nummer hinzugefügt.",
+ "fastConflictResolve": "Der Zielordner enthält {count} Dateien mit demselben Namen.",
+ "uploadingFiles": "Dateien werden hochgeladen",
+ "filesInOrigin": "Dateien im Ursprungsordner",
+ "filesInDest": "Dateien im Zielordner",
+ "override": "Überschreiben",
+ "skip": "Überspringen",
+ "forbiddenError": "Zugriff verweigert"
},
"search": {
"images": "Bilder",
diff --git a/frontend/src/i18n/el.json b/frontend/src/i18n/el.json
index ab0e0914f5..0ab2b58971 100644
--- a/frontend/src/i18n/el.json
+++ b/frontend/src/i18n/el.json
@@ -48,7 +48,11 @@
"saveChanges": "Save changes",
"editAsText": "Edit as Text",
"increaseFontSize": "Increase font size",
- "decreaseFontSize": "Decrease font size"
+ "decreaseFontSize": "Decrease font size",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Λήψη αρχείου",
@@ -161,7 +165,17 @@
"uploadMessage": "Επιλέξτε μια επιλογή για τη μεταφόρτωση.",
"optionalPassword": "Προαιρετικός κωδικός πρόσβασης",
"resolution": "Resolution",
- "discardEditorChanges": "Are you sure you wish to discard the changes you've made?"
+ "discardEditorChanges": "Are you sure you wish to discard the changes you've made?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "Εικόνες",
diff --git a/frontend/src/i18n/en.json b/frontend/src/i18n/en.json
index 0410f7f860..8f3223fff4 100644
--- a/frontend/src/i18n/en.json
+++ b/frontend/src/i18n/en.json
@@ -48,7 +48,11 @@
"saveChanges": "Save changes",
"editAsText": "Edit as Text",
"increaseFontSize": "Increase font size",
- "decreaseFontSize": "Decrease font size"
+ "decreaseFontSize": "Decrease font size",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Download File",
@@ -161,7 +165,19 @@
"uploadMessage": "Select an option to upload.",
"optionalPassword": "Optional password",
"resolution": "Resolution",
- "discardEditorChanges": "Are you sure you wish to discard the changes you've made?"
+ "discardEditorChanges": "Are you sure you wish to discard the changes you've made?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error",
+ "currentPassword": "Your password",
+ "currentPasswordMessage": "Enter your password to validate this action."
},
"search": {
"images": "Images",
diff --git a/frontend/src/i18n/es.json b/frontend/src/i18n/es.json
index 94b77c490c..9f06513755 100644
--- a/frontend/src/i18n/es.json
+++ b/frontend/src/i18n/es.json
@@ -48,7 +48,11 @@
"saveChanges": "Guardar cambios",
"editAsText": "Edit as Text",
"increaseFontSize": "Increase font size",
- "decreaseFontSize": "Decrease font size"
+ "decreaseFontSize": "Decrease font size",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Descargar fichero",
@@ -161,7 +165,17 @@
"uploadMessage": "Seleccione una opción para subir.",
"optionalPassword": "Contraseña opcional",
"resolution": "Resolution",
- "discardEditorChanges": "Are you sure you wish to discard the changes you've made?"
+ "discardEditorChanges": "Are you sure you wish to discard the changes you've made?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "Imágenes",
diff --git a/frontend/src/i18n/fa.json b/frontend/src/i18n/fa.json
index 53fef115dd..9f4504bd09 100644
--- a/frontend/src/i18n/fa.json
+++ b/frontend/src/i18n/fa.json
@@ -48,7 +48,11 @@
"saveChanges": "Save changes",
"editAsText": "Edit as Text",
"increaseFontSize": "Increase font size",
- "decreaseFontSize": "Decrease font size"
+ "decreaseFontSize": "Decrease font size",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "دانلود فایل",
@@ -161,7 +165,17 @@
"uploadMessage": "یک گزینه برای آپلود انتخاب کنید.",
"optionalPassword": "رمز عبور اختیاری",
"resolution": "وضوح تصویر",
- "discardEditorChanges": "آیا مطمئن هستید که میخواهید تغییراتی را که ایجاد کردهاید، لغو کنید؟"
+ "discardEditorChanges": "آیا مطمئن هستید که میخواهید تغییراتی را که ایجاد کردهاید، لغو کنید؟",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "تصاویر",
diff --git a/frontend/src/i18n/fr.json b/frontend/src/i18n/fr.json
index 3f9a36e889..5d39372c1c 100644
--- a/frontend/src/i18n/fr.json
+++ b/frontend/src/i18n/fr.json
@@ -48,7 +48,11 @@
"saveChanges": "Enregistrer changements",
"editAsText": "Editer comme Texte",
"increaseFontSize": "Augmenter taille police",
- "decreaseFontSize": "Réduire taille police"
+ "decreaseFontSize": "Réduire taille police",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Télécharger le fichier",
@@ -161,7 +165,17 @@
"uploadMessage": "Sélectionnez une option d'import.",
"optionalPassword": "Mot de passe optionnel",
"resolution": "Résolution",
- "discardEditorChanges": "Êtes-vous sûr de vouloir annuler les modifications apportées ?"
+ "discardEditorChanges": "Êtes-vous sûr de vouloir annuler les modifications apportées ?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "Images",
diff --git a/frontend/src/i18n/he.json b/frontend/src/i18n/he.json
index a9aed87d45..dbb3263cc2 100644
--- a/frontend/src/i18n/he.json
+++ b/frontend/src/i18n/he.json
@@ -48,7 +48,11 @@
"saveChanges": "Save changes",
"editAsText": "Edit as Text",
"increaseFontSize": "Increase font size",
- "decreaseFontSize": "Decrease font size"
+ "decreaseFontSize": "Decrease font size",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "הורד קובץ",
@@ -161,7 +165,17 @@
"uploadMessage": "בחר אפשרות העלאה.",
"optionalPassword": "סיסמא אופציונלית",
"resolution": "Resolution",
- "discardEditorChanges": "האם אתה בטוח שברצונך לבטל את השינויים שביצעת?"
+ "discardEditorChanges": "האם אתה בטוח שברצונך לבטל את השינויים שביצעת?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "תמונות",
diff --git a/frontend/src/i18n/hr.json b/frontend/src/i18n/hr.json
index df1fb6da7c..1cb4368f0d 100644
--- a/frontend/src/i18n/hr.json
+++ b/frontend/src/i18n/hr.json
@@ -48,7 +48,11 @@
"saveChanges": "Spremi promjene",
"editAsText": "Uredi kao tekst",
"increaseFontSize": "Povećaj veličinu fonta",
- "decreaseFontSize": "Smanji veličinu fonta"
+ "decreaseFontSize": "Smanji veličinu fonta",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Preuzmi Datoteku",
@@ -161,7 +165,17 @@
"uploadMessage": "Odaberite opciju za prijenos.",
"optionalPassword": "Opcionalna lozinka",
"resolution": "Rezolucija",
- "discardEditorChanges": "Jeste li sigurni da želite odbaciti promjene koje ste napravili?"
+ "discardEditorChanges": "Jeste li sigurni da želite odbaciti promjene koje ste napravili?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "Slike",
diff --git a/frontend/src/i18n/hu.json b/frontend/src/i18n/hu.json
index 38732646ae..bdcb33ba00 100644
--- a/frontend/src/i18n/hu.json
+++ b/frontend/src/i18n/hu.json
@@ -48,7 +48,11 @@
"saveChanges": "Save changes",
"editAsText": "Edit as Text",
"increaseFontSize": "Increase font size",
- "decreaseFontSize": "Decrease font size"
+ "decreaseFontSize": "Decrease font size",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Fájl letöltése",
@@ -161,7 +165,17 @@
"uploadMessage": "Válasszon egy feltöltési módot.",
"optionalPassword": "Választható jelszó",
"resolution": "Resolution",
- "discardEditorChanges": "Are you sure you wish to discard the changes you've made?"
+ "discardEditorChanges": "Are you sure you wish to discard the changes you've made?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "Képek",
diff --git a/frontend/src/i18n/is.json b/frontend/src/i18n/is.json
index 6b7d8abbd5..3825849218 100644
--- a/frontend/src/i18n/is.json
+++ b/frontend/src/i18n/is.json
@@ -48,7 +48,11 @@
"saveChanges": "Save changes",
"editAsText": "Edit as Text",
"increaseFontSize": "Increase font size",
- "decreaseFontSize": "Decrease font size"
+ "decreaseFontSize": "Decrease font size",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Sækja skjal",
@@ -161,7 +165,17 @@
"uploadMessage": "Select an option to upload.",
"optionalPassword": "Optional password",
"resolution": "Resolution",
- "discardEditorChanges": "Are you sure you wish to discard the changes you've made?"
+ "discardEditorChanges": "Are you sure you wish to discard the changes you've made?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "Myndir",
diff --git a/frontend/src/i18n/it.json b/frontend/src/i18n/it.json
index a17eb7461e..f3e7478abf 100644
--- a/frontend/src/i18n/it.json
+++ b/frontend/src/i18n/it.json
@@ -48,7 +48,11 @@
"saveChanges": "Save changes",
"editAsText": "Edit as Text",
"increaseFontSize": "Increase font size",
- "decreaseFontSize": "Decrease font size"
+ "decreaseFontSize": "Decrease font size",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Scarica file",
@@ -161,7 +165,17 @@
"uploadMessage": "Seleziona un'opzione per il caricamento.",
"optionalPassword": "Password opzionale",
"resolution": "Risoluzione",
- "discardEditorChanges": "Sei sicuro di voler scartare le modifiche apportate?"
+ "discardEditorChanges": "Sei sicuro di voler scartare le modifiche apportate?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "Immagini",
diff --git a/frontend/src/i18n/ja.json b/frontend/src/i18n/ja.json
index 853fe8d8ab..bf623ec224 100644
--- a/frontend/src/i18n/ja.json
+++ b/frontend/src/i18n/ja.json
@@ -48,7 +48,11 @@
"saveChanges": "Save changes",
"editAsText": "Edit as Text",
"increaseFontSize": "Increase font size",
- "decreaseFontSize": "Decrease font size"
+ "decreaseFontSize": "Decrease font size",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "ファイルのダウンロード",
@@ -161,7 +165,17 @@
"uploadMessage": "アップロードするオプションを選択してください。",
"optionalPassword": "パスワード(オプション)",
"resolution": "Resolution",
- "discardEditorChanges": "Are you sure you wish to discard the changes you've made?"
+ "discardEditorChanges": "Are you sure you wish to discard the changes you've made?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "画像",
diff --git a/frontend/src/i18n/ko.json b/frontend/src/i18n/ko.json
index 9c1cd76491..5bad2d5616 100644
--- a/frontend/src/i18n/ko.json
+++ b/frontend/src/i18n/ko.json
@@ -42,13 +42,17 @@
"update": "업데이트",
"upload": "업로드",
"openFile": "파일 열기",
- "openDirect": "View raw",
+ "openDirect": "원본 보기",
"discardChanges": "변경 사항 취소",
"stopSearch": "검색 중단",
"saveChanges": "변경사항 저장",
"editAsText": "텍스트로 편집",
"increaseFontSize": "글꼴 크기 증가",
- "decreaseFontSize": "글꼴 크기 감소"
+ "decreaseFontSize": "글꼴 크기 감소",
+ "overrideAll": "대상 폴더의 모든 파일을 대체",
+ "skipAll": "충돌하는 모든 파일을 건너뛰기",
+ "renameAll": "모든 파일의 이름 변경 (복사본 생성)",
+ "singleDecision": "충돌하는 각 파일을 확인"
},
"download": {
"downloadFile": "파일 다운로드",
@@ -161,7 +165,17 @@
"uploadMessage": "업로드 옵션을 선택하세요.",
"optionalPassword": "비밀번호 (선택)",
"resolution": "해상도",
- "discardEditorChanges": "변경 사항을 취소하시겠습니까?"
+ "discardEditorChanges": "변경 사항을 취소하시겠습니까?",
+ "replaceOrSkip": "파일 대체 또는 건너뛰기",
+ "resolveConflict": "어떤 파일을 유지하시겠습니까?",
+ "singleConflictResolve": "모든 버전을 선택하면 복사한 파일의 이름에 번호를 추가합니다.",
+ "fastConflictResolve": "대상 폴더에 같은 이름을 가진 파일이 {count}개 있습니다.",
+ "uploadingFiles": "파일 업로드 중",
+ "filesInOrigin": "원본 파일",
+ "filesInDest": "대상 경로의 파일",
+ "override": "덮어쓰기",
+ "skip": "건너뛰기",
+ "forbiddenError": "권한 오류"
},
"search": {
"images": "이미지",
diff --git a/frontend/src/i18n/lv.json b/frontend/src/i18n/lv.json
index 2d55756691..e852b17026 100644
--- a/frontend/src/i18n/lv.json
+++ b/frontend/src/i18n/lv.json
@@ -48,7 +48,11 @@
"saveChanges": "Saglabāt izmaiņas",
"editAsText": "Rediģēt kā tekstu",
"increaseFontSize": "Palieliniet fonta lielumu",
- "decreaseFontSize": "Samaziniet fonta lielumu"
+ "decreaseFontSize": "Samaziniet fonta lielumu",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Lejupielādēt failu",
@@ -161,7 +165,17 @@
"uploadMessage": "Atlasiet augšupielādes opciju.",
"optionalPassword": "Izvēles parole",
"resolution": "Izšķirtspēja",
- "discardEditorChanges": "Vai tiešām vēlaties atmest veiktās izmaiņas?"
+ "discardEditorChanges": "Vai tiešām vēlaties atmest veiktās izmaiņas?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "Attēli",
diff --git a/frontend/src/i18n/lv_LV.json b/frontend/src/i18n/lv_LV.json
index 67fbdb8e0e..748614d600 100644
--- a/frontend/src/i18n/lv_LV.json
+++ b/frontend/src/i18n/lv_LV.json
@@ -48,7 +48,11 @@
"saveChanges": "Saglabāt izmaiņas",
"editAsText": "Rediģēt kā tekstu",
"increaseFontSize": "Palieliniet fonta lielumu",
- "decreaseFontSize": "Samaziniet fonta lielumu"
+ "decreaseFontSize": "Samaziniet fonta lielumu",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Lejupielādēt failu",
@@ -161,7 +165,17 @@
"uploadMessage": "Atlasiet augšupielādes opciju.",
"optionalPassword": "Izvēles parole",
"resolution": "Izšķirtspēja",
- "discardEditorChanges": "Vai tiešām vēlaties atmest veiktās izmaiņas?"
+ "discardEditorChanges": "Vai tiešām vēlaties atmest veiktās izmaiņas?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "Attēli",
diff --git a/frontend/src/i18n/nl-be.json b/frontend/src/i18n/nl-be.json
index d9f76406c7..ee27329e97 100644
--- a/frontend/src/i18n/nl-be.json
+++ b/frontend/src/i18n/nl-be.json
@@ -48,7 +48,11 @@
"saveChanges": "Save changes",
"editAsText": "Edit as Text",
"increaseFontSize": "Increase font size",
- "decreaseFontSize": "Decrease font size"
+ "decreaseFontSize": "Decrease font size",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Bestand downloaden",
@@ -161,7 +165,17 @@
"uploadMessage": "Select an option to upload.",
"optionalPassword": "Optional password",
"resolution": "Resolution",
- "discardEditorChanges": "Are you sure you wish to discard the changes you've made?"
+ "discardEditorChanges": "Are you sure you wish to discard the changes you've made?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "Afbeeldingen",
diff --git a/frontend/src/i18n/nl.json b/frontend/src/i18n/nl.json
index 70e9b2446c..5d507a5535 100644
--- a/frontend/src/i18n/nl.json
+++ b/frontend/src/i18n/nl.json
@@ -42,13 +42,17 @@
"update": "Bijwerken",
"upload": "Uploaden",
"openFile": "Bestand openen",
- "openDirect": "View raw",
+ "openDirect": "Raw weergeven",
"discardChanges": "Weggooien",
"stopSearch": "Stoppen met zoeken",
"saveChanges": "Wijzigingen opslaan",
"editAsText": "Als tekst bewerken",
"increaseFontSize": "Lettertype vergroten",
- "decreaseFontSize": "Lettertype verkleinen"
+ "decreaseFontSize": "Lettertype verkleinen",
+ "overrideAll": "Alle bestanden in doelmap vervangen",
+ "skipAll": "Alle conflicterende bestanden overslaan",
+ "renameAll": "Alle bestanden hernoemen (een kopie maken)",
+ "singleDecision": "Voor elk conflicterend bestand besluiten"
},
"download": {
"downloadFile": "Bestand downloaden",
@@ -161,7 +165,17 @@
"uploadMessage": "Kies een optie bij de upload.",
"optionalPassword": "Optioneel wachtwoord",
"resolution": "Resolutie",
- "discardEditorChanges": "Weet u zeker dat u de door u aangebrachte wijzigingen wilt weggooien?"
+ "discardEditorChanges": "Weet u zeker dat u de door u aangebrachte wijzigingen wilt weggooien?",
+ "replaceOrSkip": "Bestanden vervangen of overslaan",
+ "resolveConflict": "Welke bestanden wilt u behouden?",
+ "singleConflictResolve": "Als u beide versies selecteert, wordt er een nummer toegevoegd aan de naam van het gekopieerde bestand.",
+ "fastConflictResolve": "De doelmap daar bevat {count} bestanden met dezelfde naam.",
+ "uploadingFiles": "Bestanden uploaden",
+ "filesInOrigin": "Bestanden in origineel",
+ "filesInDest": "Bestanden in bestemming",
+ "override": "Overschrijven",
+ "skip": "Overslaan",
+ "forbiddenError": "Verboden Fout"
},
"search": {
"images": "Afbeeldingen",
diff --git a/frontend/src/i18n/no.json b/frontend/src/i18n/no.json
index 4c9fb225ee..dd82ee85f8 100644
--- a/frontend/src/i18n/no.json
+++ b/frontend/src/i18n/no.json
@@ -48,7 +48,11 @@
"saveChanges": "Lagre Endringane ",
"editAsText": "Edit as Text",
"increaseFontSize": "Increase font size",
- "decreaseFontSize": "Decrease font size"
+ "decreaseFontSize": "Decrease font size",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Nedlast filen",
@@ -161,7 +165,17 @@
"uploadMessage": "Velg et alternativ for opplasting.",
"optionalPassword": "Valgfritt passord",
"resolution": "Oppløysning",
- "discardEditorChanges": "Er du sikker på at du vil forkaste endringene du har gjort?"
+ "discardEditorChanges": "Er du sikker på at du vil forkaste endringene du har gjort?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "Bilde",
diff --git a/frontend/src/i18n/pl.json b/frontend/src/i18n/pl.json
index 9f9d3a29d7..2a46352892 100644
--- a/frontend/src/i18n/pl.json
+++ b/frontend/src/i18n/pl.json
@@ -42,13 +42,17 @@
"update": "Aktualizuj",
"upload": "Wyślij",
"openFile": "Otwórz plik",
- "openDirect": "View raw",
+ "openDirect": "Otwórz bezpośrednio",
"discardChanges": "Odrzuć",
"stopSearch": "Zatrzymaj wyszukiwanie",
"saveChanges": "Zapisz zmiany",
"editAsText": "Edytuj jako tekst",
"increaseFontSize": "Zwiększ rozmiar czcionki",
- "decreaseFontSize": "Zmniejsz rozmiar czcionki"
+ "decreaseFontSize": "Zmniejsz rozmiar czcionki",
+ "overrideAll": "Zastąp wszystkie pliki w folderze docelowym",
+ "skipAll": "Pomiń wszystkie pliki powodujące konflikty",
+ "renameAll": "Zmień nazwy wszystkich plików (utwórz kopię)",
+ "singleDecision": "Podejmij decyzję dla każdego pliku powodującego konflikt"
},
"download": {
"downloadFile": "Pobierz plik",
@@ -161,7 +165,17 @@
"uploadMessage": "Wybierz opcję przesyłania.",
"optionalPassword": "Opcjonalne hasło",
"resolution": "Rozdzielczość",
- "discardEditorChanges": "Czy na pewno chcesz odrzucić wprowadzone zmiany?"
+ "discardEditorChanges": "Czy na pewno chcesz odrzucić wprowadzone zmiany?",
+ "replaceOrSkip": "Zastąp lub pomiń pliki",
+ "resolveConflict": "Które pliki chcesz zachować?",
+ "singleConflictResolve": "Jeśli wybierzesz obie wersje, do nazwy kopiowanego pliku zostanie dodany numer.",
+ "fastConflictResolve": "W folderze docelowym liczba plików o tej samej nazwie to {count}.",
+ "uploadingFiles": "Wysyłanie plików",
+ "filesInOrigin": "Pliki w miejscu pochodzenia",
+ "filesInDest": "Pliki w miejscu docelowym",
+ "override": "Zastąp",
+ "skip": "Pomiń",
+ "forbiddenError": "Błąd zabronionego dostępu"
},
"search": {
"images": "Obrazy",
diff --git a/frontend/src/i18n/pt-br.json b/frontend/src/i18n/pt-br.json
index 5f36c337ea..9b9122c65b 100644
--- a/frontend/src/i18n/pt-br.json
+++ b/frontend/src/i18n/pt-br.json
@@ -48,7 +48,11 @@
"saveChanges": "Save changes",
"editAsText": "Edit as Text",
"increaseFontSize": "Increase font size",
- "decreaseFontSize": "Decrease font size"
+ "decreaseFontSize": "Decrease font size",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Baixar arquivo",
@@ -161,7 +165,17 @@
"uploadMessage": "Selecione uma opção para enviar.",
"optionalPassword": "Senha opcional",
"resolution": "Resolution",
- "discardEditorChanges": "Are you sure you wish to discard the changes you've made?"
+ "discardEditorChanges": "Are you sure you wish to discard the changes you've made?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "Imagens",
diff --git a/frontend/src/i18n/pt.json b/frontend/src/i18n/pt.json
index 0e50052255..8f5e852455 100644
--- a/frontend/src/i18n/pt.json
+++ b/frontend/src/i18n/pt.json
@@ -48,7 +48,11 @@
"saveChanges": "Save changes",
"editAsText": "Edit as Text",
"increaseFontSize": "Increase font size",
- "decreaseFontSize": "Decrease font size"
+ "decreaseFontSize": "Decrease font size",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Descarregar ficheiro",
@@ -161,7 +165,17 @@
"uploadMessage": "Select an option to upload.",
"optionalPassword": "Optional password",
"resolution": "Resolution",
- "discardEditorChanges": "Are you sure you wish to discard the changes you've made?"
+ "discardEditorChanges": "Are you sure you wish to discard the changes you've made?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "Imagens",
diff --git a/frontend/src/i18n/ro.json b/frontend/src/i18n/ro.json
index 5495e884d8..b36436ea1b 100644
--- a/frontend/src/i18n/ro.json
+++ b/frontend/src/i18n/ro.json
@@ -48,7 +48,11 @@
"saveChanges": "Save changes",
"editAsText": "Edit as Text",
"increaseFontSize": "Increase font size",
- "decreaseFontSize": "Decrease font size"
+ "decreaseFontSize": "Decrease font size",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Descarcă fișier",
@@ -161,7 +165,17 @@
"uploadMessage": "Select an option to upload.",
"optionalPassword": "Optional password",
"resolution": "Resolution",
- "discardEditorChanges": "Are you sure you wish to discard the changes you've made?"
+ "discardEditorChanges": "Are you sure you wish to discard the changes you've made?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "Imagini",
diff --git a/frontend/src/i18n/ru.json b/frontend/src/i18n/ru.json
index 05514e4a64..6cd70e1317 100644
--- a/frontend/src/i18n/ru.json
+++ b/frontend/src/i18n/ru.json
@@ -48,7 +48,11 @@
"saveChanges": "Сохранить",
"editAsText": "Редактировать как текст",
"increaseFontSize": "Увеличить размер шрифта",
- "decreaseFontSize": "Уменьшить размер шрифта"
+ "decreaseFontSize": "Уменьшить размер шрифта",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Скачать файл",
@@ -161,7 +165,17 @@
"uploadMessage": "Выберите вариант для загрузки.",
"optionalPassword": "Необязательный пароль",
"resolution": "Разрешение",
- "discardEditorChanges": "Вы действительно желаете отменить ваши правки?"
+ "discardEditorChanges": "Вы действительно желаете отменить ваши правки?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "Изображения",
diff --git a/frontend/src/i18n/sk.json b/frontend/src/i18n/sk.json
index 225a4f748e..82089d7ba2 100644
--- a/frontend/src/i18n/sk.json
+++ b/frontend/src/i18n/sk.json
@@ -48,7 +48,11 @@
"saveChanges": "Uložiť zmeny",
"editAsText": "Edit as Text",
"increaseFontSize": "Increase font size",
- "decreaseFontSize": "Decrease font size"
+ "decreaseFontSize": "Decrease font size",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Stiahnuť súbor",
@@ -161,7 +165,17 @@
"uploadMessage": "Zvoľte možnosť nahrávania.",
"optionalPassword": "Voliteľné heslo",
"resolution": "Rozlíšenie",
- "discardEditorChanges": "Naozaj chcete zahodiť vykonané zmeny?"
+ "discardEditorChanges": "Naozaj chcete zahodiť vykonané zmeny?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "Obrázky",
diff --git a/frontend/src/i18n/sv-se.json b/frontend/src/i18n/sv-se.json
index 5542c7159f..a7cf261a2d 100644
--- a/frontend/src/i18n/sv-se.json
+++ b/frontend/src/i18n/sv-se.json
@@ -48,7 +48,11 @@
"saveChanges": "Spara ändringar",
"editAsText": "Edit as Text",
"increaseFontSize": "Increase font size",
- "decreaseFontSize": "Decrease font size"
+ "decreaseFontSize": "Decrease font size",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Ladda ner fil",
@@ -161,7 +165,17 @@
"uploadMessage": "Välj ett alternativ att ladda upp.",
"optionalPassword": "Valfritt lösenord",
"resolution": "Upplösning",
- "discardEditorChanges": "Är du säker på att du vill förkasta ändringarna du gjort?"
+ "discardEditorChanges": "Är du säker på att du vill förkasta ändringarna du gjort?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "Bilder",
diff --git a/frontend/src/i18n/tr.json b/frontend/src/i18n/tr.json
index 5ff72853e6..800c9e6493 100644
--- a/frontend/src/i18n/tr.json
+++ b/frontend/src/i18n/tr.json
@@ -48,7 +48,11 @@
"saveChanges": "Save changes",
"editAsText": "Edit as Text",
"increaseFontSize": "Increase font size",
- "decreaseFontSize": "Decrease font size"
+ "decreaseFontSize": "Decrease font size",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Dosyayı indir",
@@ -161,7 +165,17 @@
"uploadMessage": "Yüklemek için bir seçenek belirleyin.",
"optionalPassword": "İsteğe bağlı şifre",
"resolution": "Resolution",
- "discardEditorChanges": "Are you sure you wish to discard the changes you've made?"
+ "discardEditorChanges": "Are you sure you wish to discard the changes you've made?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "Görseller",
diff --git a/frontend/src/i18n/uk.json b/frontend/src/i18n/uk.json
index ccaf9a41f0..d9aa3fb4f1 100644
--- a/frontend/src/i18n/uk.json
+++ b/frontend/src/i18n/uk.json
@@ -48,7 +48,11 @@
"saveChanges": "Save changes",
"editAsText": "Edit as Text",
"increaseFontSize": "Increase font size",
- "decreaseFontSize": "Decrease font size"
+ "decreaseFontSize": "Decrease font size",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Завантажити файл",
@@ -161,7 +165,17 @@
"uploadMessage": "Виберіть варіант для вивантаження.",
"optionalPassword": "Необов'язковий пароль",
"resolution": "Розширення",
- "discardEditorChanges": "Чи дійсно ви хочете скасувати поточні зміни?"
+ "discardEditorChanges": "Чи дійсно ви хочете скасувати поточні зміни?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "Зображення",
diff --git a/frontend/src/i18n/vi.json b/frontend/src/i18n/vi.json
index ef3aeab580..ab73c0cb27 100644
--- a/frontend/src/i18n/vi.json
+++ b/frontend/src/i18n/vi.json
@@ -48,7 +48,11 @@
"saveChanges": "Save changes",
"editAsText": "Edit as Text",
"increaseFontSize": "Increase font size",
- "decreaseFontSize": "Decrease font size"
+ "decreaseFontSize": "Decrease font size",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "Tải xuống tệp tin",
@@ -161,7 +165,17 @@
"uploadMessage": "Chọn một tùy chọn để tải lên.",
"optionalPassword": "Mật khẩu tùy chọn",
"resolution": "Độ phân giải",
- "discardEditorChanges": "Bạn có chắc chắn muốn hủy bỏ các thay đổi đã thực hiện không?"
+ "discardEditorChanges": "Bạn có chắc chắn muốn hủy bỏ các thay đổi đã thực hiện không?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "Hình ảnh",
diff --git a/frontend/src/i18n/zh-cn.json b/frontend/src/i18n/zh-cn.json
index 4a16eef972..816e1d8d82 100644
--- a/frontend/src/i18n/zh-cn.json
+++ b/frontend/src/i18n/zh-cn.json
@@ -48,7 +48,11 @@
"saveChanges": "保存更改",
"editAsText": "以文本形式编辑",
"increaseFontSize": "增大字体大小",
- "decreaseFontSize": "减小字体大小"
+ "decreaseFontSize": "减小字体大小",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "下载文件",
@@ -161,7 +165,17 @@
"uploadMessage": "选择上传选项。",
"optionalPassword": "密码(选填,不填即无密码)",
"resolution": "分辨率",
- "discardEditorChanges": "你确定要放弃所做的更改吗?"
+ "discardEditorChanges": "你确定要放弃所做的更改吗?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "图像",
diff --git a/frontend/src/i18n/zh-tw.json b/frontend/src/i18n/zh-tw.json
index 61f264f38e..986b1d3b03 100644
--- a/frontend/src/i18n/zh-tw.json
+++ b/frontend/src/i18n/zh-tw.json
@@ -48,7 +48,11 @@
"saveChanges": "Save changes",
"editAsText": "Edit as Text",
"increaseFontSize": "Increase font size",
- "decreaseFontSize": "Decrease font size"
+ "decreaseFontSize": "Decrease font size",
+ "overrideAll": "Replace all files in destination folder",
+ "skipAll": "Skip all conflicting files",
+ "renameAll": "Rename all files (create a copy)",
+ "singleDecision": "Decide for each conflicting file"
},
"download": {
"downloadFile": "下載檔案",
@@ -161,7 +165,17 @@
"uploadMessage": "選擇上傳項。",
"optionalPassword": "密碼(選填,不填即無密碼)",
"resolution": "解析度",
- "discardEditorChanges": "你確定要放棄所做的變更嗎?"
+ "discardEditorChanges": "你確定要放棄所做的變更嗎?",
+ "replaceOrSkip": "Replace or skip files",
+ "resolveConflict": "Which files do you want to keep?",
+ "singleConflictResolve": "If you select both versions, a number will be added to the name of the copied file.",
+ "fastConflictResolve": "The destination folder there are {count} files with same name.",
+ "uploadingFiles": "Uploading files",
+ "filesInOrigin": "Files in origin",
+ "filesInDest": "Files in destination",
+ "override": "Overwrite",
+ "skip": "Skip",
+ "forbiddenError": "Forbidden Error"
},
"search": {
"images": "影像",
diff --git a/frontend/src/main.ts b/frontend/src/main.ts
index 42f4420564..f6b7ac78c5 100644
--- a/frontend/src/main.ts
+++ b/frontend/src/main.ts
@@ -2,7 +2,6 @@ import { disableExternal } from "@/utils/constants";
import { createApp } from "vue";
import VueNumberInput from "@chenfengyuan/vue-number-input";
import VueLazyload from "vue-lazyload";
-import { createVfm } from "vue-final-modal";
import Toast, { POSITION, useToast } from "vue-toastification";
import type {
ToastOptions,
@@ -27,7 +26,6 @@ dayjs.extend(relativeTime);
dayjs.extend(duration);
const pinia = createPinia(router);
-const vfm = createVfm();
const app = createApp(App);
@@ -39,7 +37,6 @@ app.use(Toast, {
newestOnTop: true,
} satisfies PluginOptions);
-app.use(vfm);
app.use(i18n);
app.use(pinia);
app.use(router);
diff --git a/frontend/src/stores/layout.ts b/frontend/src/stores/layout.ts
index 372fca06e8..fbd6d99f6a 100644
--- a/frontend/src/stores/layout.ts
+++ b/frontend/src/stores/layout.ts
@@ -76,7 +76,7 @@ export const useLayoutStore = defineStore("layout", {
});
},
closeHovers() {
- this.prompts.shift()?.close?.();
+ this.prompts.pop()?.close?.();
},
// easily reset state using `$reset`
clearLayout() {
diff --git a/frontend/src/types/file.d.ts b/frontend/src/types/file.d.ts
index 6b9b6372cd..e6511b3919 100644
--- a/frontend/src/types/file.d.ts
+++ b/frontend/src/types/file.d.ts
@@ -52,6 +52,8 @@ type DownloadFormat =
interface ClipItem {
from: string;
name: string;
+ size?: number;
+ modified?: string;
}
interface BreadCrumb {
@@ -59,6 +61,19 @@ interface BreadCrumb {
url: string;
}
+interface ConflictingItem {
+ lastModified: number | string | undefined;
+ size: number | undefined;
+}
+
+interface ConflictingResource {
+ index: number;
+ name: string;
+ origin: ConflictingItem;
+ dest: ConflictingItem;
+ checked: Array<"origin" | "dest">;
+}
+
interface CsvData {
headers: string[];
rows: string[][];
diff --git a/frontend/src/types/global.d.ts b/frontend/src/types/global.d.ts
index 5475c908fd..287388f0ec 100644
--- a/frontend/src/types/global.d.ts
+++ b/frontend/src/types/global.d.ts
@@ -10,4 +10,8 @@ declare global {
// TODO: no idea what the exact type is
__vue__: any;
}
+
+ interface HTMLElement {
+ clickOutsideEvent?: (event: Event) => void;
+ }
}
diff --git a/frontend/src/types/upload.d.ts b/frontend/src/types/upload.d.ts
index 4bad9e0650..5e5716acb1 100644
--- a/frontend/src/types/upload.d.ts
+++ b/frontend/src/types/upload.d.ts
@@ -17,6 +17,7 @@ interface UploadEntry {
isDir: boolean;
fullPath?: string;
file?: File;
+ overwrite?: boolean;
}
type UploadList = UploadEntry[];
diff --git a/frontend/src/utils/encodings.ts b/frontend/src/utils/encodings.ts
index 80f1e21975..9be1017a4e 100644
--- a/frontend/src/utils/encodings.ts
+++ b/frontend/src/utils/encodings.ts
@@ -1,4 +1,5 @@
export const availableEncodings = [
+ // encodings
"utf-8",
"ibm866",
"iso-8859-2",
@@ -37,6 +38,178 @@ export const availableEncodings = [
"euc-kr",
"utf-16be",
"utf-16le",
+ // label encodings
+ "unicode-1-1-utf-8",
+ "utf8",
+ "866",
+ "cp866",
+ "csibm866",
+ "csisolatin2",
+ "iso-ir-101",
+ "iso8859-2",
+ "iso88592",
+ "iso_8859-2",
+ "iso_8859-2:1987",
+ "l2",
+ "latin2",
+ "csisolatin3",
+ "iso-ir-109",
+ "iso8859-3",
+ "iso88593",
+ "iso_8859-3",
+ "iso_8859-3:1988",
+ "l3",
+ "latin3",
+ "csisolatin4",
+ "iso-ir-110",
+ "iso8859-4",
+ "iso88594",
+ "iso_8859-4",
+ "iso_8859-4:1988",
+ "l4",
+ "latin4",
+ "csisolatincyrillic",
+ "cyrillic",
+ "iso-ir-144",
+ "iso88595",
+ "iso_8859-5",
+ "iso_8859-5:1988",
+ "arabic",
+ "asmo-708",
+ "csiso88596e",
+ "csiso88596i",
+ "csisolatinarabic",
+ "ecma-114",
+ "iso-8859-6-e",
+ "iso-8859-6-i",
+ "iso-ir-127",
+ "iso8859-6",
+ "iso88596",
+ "iso_8859-6",
+ "iso_8859-6:1987",
+ "csisolatingreek",
+ "ecma-118",
+ "elot_928",
+ "greek",
+ "greek8",
+ "iso-ir-126",
+ "iso8859-7",
+ "iso88597",
+ "iso_8859-7",
+ "iso_8859-7:1987",
+ "sun_eu_greek",
+ "csiso88598e",
+ "csisolatinhebrew",
+ "hebrew",
+ "iso-8859-8-e",
+ "iso-ir-138",
+ "iso8859-8",
+ "iso88598",
+ "iso_8859-8",
+ "iso_8859-8:1988",
+ "visual",
+ "csiso88598i",
+ "logical",
+ "csisolatin6",
+ "iso-ir-157",
+ "iso8859-10",
+ "iso885910",
+ "l6",
+ "latin6",
+ "iso8859-13",
+ "iso885913",
+ "iso8859-14",
+ "iso885914",
+ "csisolatin9",
+ "iso8859-15",
+ "iso885915",
+ "l9",
+ "latin9",
+ "cskoi8r",
+ "koi",
+ "koi8",
+ "koi8_r",
+ "csmacintosh",
+ "mac",
+ "x-mac-roman",
+ "dos-874",
+ "iso-8859-11",
+ "iso8859-11",
+ "iso885911",
+ "tis-620",
+ "cp1250",
+ "x-cp1250",
+ "cp1251",
+ "x-cp1251",
+ "ansi_x3.4-1968",
+ "ascii",
+ "cp1252",
+ "cp819",
+ "csisolatin1",
+ "ibm819",
+ "iso-8859-1",
+ "iso-ir-100",
+ "iso8859-1",
+ "iso88591",
+ "iso_8859-1",
+ "iso_8859-1:1987",
+ "l1",
+ "latin1",
+ "us-ascii",
+ "x-cp1252",
+ "cp1253",
+ "x-cp1253",
+ "cp1254",
+ "csisolatin5",
+ "iso-8859-9",
+ "iso-ir-148",
+ "iso8859-9",
+ "iso88599",
+ "iso_8859-9",
+ "iso_8859-9:1989",
+ "l5",
+ "latin5",
+ "x-cp1254",
+ "cp1255",
+ "x-cp1255",
+ "cp1256",
+ "x-cp1256",
+ "cp1257",
+ "x-cp1257",
+ "cp1258",
+ "x-cp1258",
+ "x-mac-ukrainian",
+ "chinese",
+ "csgb2312",
+ "csiso58gb231280",
+ "gb2312",
+ "gb_2312",
+ "gb_2312-80",
+ "iso-ir-58",
+ "x-gbk",
+ "big5-hkscs",
+ "cn-big5",
+ "csbig5",
+ "x-x-big5",
+ "cseucpkdfmtjapanese",
+ "x-euc-jp",
+ "csiso2022jp",
+ "csshiftjis",
+ "ms_kanji",
+ "shift-jis",
+ "sjis",
+ "windows-31j",
+ "x-sjis",
+ "cseuckr",
+ "csksc56011987",
+ "iso-ir-149",
+ "korean",
+ "ks_c_5601-1987",
+ "ks_c_5601-1989",
+ "ksc5601",
+ "ksc_5601",
+ "windows-949",
+ "utf-16",
];
export function decode(content: ArrayBuffer, encoding: string): string {
diff --git a/frontend/src/utils/index.ts b/frontend/src/utils/index.ts
index d7f0bd9b7f..faca153923 100644
--- a/frontend/src/utils/index.ts
+++ b/frontend/src/utils/index.ts
@@ -4,3 +4,25 @@ import { partial } from "filesize";
* Formats filesize as KiB/MiB/...
*/
export const filesize = partial({ base: 2 });
+
+export const vClickOutside = {
+ created(el: HTMLElement, binding: any) {
+ el.clickOutsideEvent = (event: Event) => {
+ const target = event.target;
+
+ if (target instanceof Node) {
+ if (!el.contains(target)) {
+ binding.value(event);
+ }
+ }
+ };
+
+ document.addEventListener("click", el.clickOutsideEvent);
+ },
+
+ unmounted(el: HTMLElement) {
+ if (el.clickOutsideEvent) {
+ document.removeEventListener("click", el.clickOutsideEvent);
+ }
+ },
+};
diff --git a/frontend/src/utils/upload.ts b/frontend/src/utils/upload.ts
index e951cb43cb..a5a62b1dfc 100644
--- a/frontend/src/utils/upload.ts
+++ b/frontend/src/utils/upload.ts
@@ -3,16 +3,24 @@ import { useUploadStore } from "@/stores/upload";
import url from "@/utils/url";
export function checkConflict(
- files: UploadList,
+ files: UploadList | Array,
dest: ResourceItem[]
-): boolean {
+): ConflictingResource[] {
if (typeof dest === "undefined" || dest === null) {
dest = [];
}
+ const conflictingFiles: ConflictingResource[] = [];
const folder_upload = files[0].fullPath !== undefined;
- const names = new Set();
+ function getFile(name: string): ResourceItem | null {
+ for (const item of dest) {
+ if (item.name == name) return item;
+ }
+
+ return null;
+ }
+
for (let i = 0; i < files.length; i++) {
const file = files[i];
let name = file.name;
@@ -24,10 +32,25 @@ export function checkConflict(
}
}
- names.add(name);
+ const item = getFile(name);
+ if (item != null) {
+ conflictingFiles.push({
+ index: i,
+ name: item.path,
+ origin: {
+ lastModified: file.modified || file.file?.lastModified,
+ size: file.size,
+ },
+ dest: {
+ lastModified: item.modified,
+ size: item.size,
+ },
+ checked: ["origin"],
+ });
+ }
}
- return dest.some((d) => names.has(d.name));
+ return conflictingFiles;
}
export function scanFiles(dt: DataTransfer): Promise {
@@ -146,6 +169,12 @@ export function handleFiles(
const type = file.isDir ? "dir" : detectType((file.file as File).type);
- uploadStore.upload(path, file.name, file.file ?? null, overwrite, type);
+ uploadStore.upload(
+ path,
+ file.name,
+ file.file ?? null,
+ file.overwrite || overwrite,
+ type
+ );
}
}
diff --git a/frontend/src/views/files/Editor.vue b/frontend/src/views/files/Editor.vue
index dbde609e29..2b2852d37b 100644
--- a/frontend/src/views/files/Editor.vue
+++ b/frontend/src/views/files/Editor.vue
@@ -121,7 +121,7 @@ const isMarkdownFile =
fileStore.req?.name.endsWith(".markdown");
const katexOptions = {
output: "mathml" as const,
- throwOnError: false
+ throwOnError: false,
};
marked.use(markedKatex(katexOptions));
@@ -233,6 +233,11 @@ const initEditor = (fileContent: string) => {
editor.value.setFontSize(fontSize.value);
editor.value.focus();
+
+ const selection = editor.value?.getSelection();
+ selection.on("changeSelection", function () {
+ isSelectionEmpty.value = selection.isEmpty();
+ });
};
const keyEvent = (event: KeyboardEvent) => {
@@ -296,6 +301,7 @@ const close = () => {
prompt: "discardEditorChanges",
confirm: (event: Event) => {
event.preventDefault();
+ editor.value?.session.getUndoManager().reset();
finishClose();
},
saveAction: async () => {
diff --git a/frontend/src/views/files/FileListing.vue b/frontend/src/views/files/FileListing.vue
index 0a86b359ee..f612ab1d16 100644
--- a/frontend/src/views/files/FileListing.vue
+++ b/frontend/src/views/files/FileListing.vue
@@ -628,6 +628,8 @@ const copyCut = (event: Event | KeyboardEvent): void => {
items.push({
from: fileStore.req.items[i].url,
name: fileStore.req.items[i].name,
+ size: fileStore.req.items[i].size,
+ modified: fileStore.req.items[i].modified,
});
}
@@ -651,7 +653,15 @@ const paste = (event: Event) => {
for (const item of clipboardStore.items) {
const from = item.from.endsWith("/") ? item.from.slice(0, -1) : item.from;
const to = route.path + encodeURIComponent(item.name);
- items.push({ from, to, name: item.name });
+ items.push({
+ from,
+ to,
+ name: item.name,
+ size: item.size,
+ modified: item.modified,
+ overwrite: false,
+ rename: clipboardStore.path == route.path,
+ });
}
if (items.length === 0) {
@@ -660,7 +670,7 @@ const paste = (event: Event) => {
const preselect = removePrefix(route.path) + items[0].name;
- let action = (overwrite: boolean, rename: boolean) => {
+ let action = (overwrite?: boolean, rename?: boolean) => {
api
.copy(items, overwrite, rename)
.then(() => {
@@ -683,34 +693,37 @@ const paste = (event: Event) => {
};
}
- if (clipboardStore.path == route.path) {
- action(false, true);
-
- return;
- }
-
const conflict = upload.checkConflict(items, fileStore.req!.items);
- let overwrite = false;
- let rename = false;
-
- if (conflict) {
+ if (conflict.length > 0) {
layoutStore.showHover({
- prompt: "replace-rename",
- confirm: (event: Event, option: string) => {
- overwrite = option == "overwrite";
- rename = option == "rename";
-
+ prompt: "resolve-conflict",
+ props: {
+ conflict: conflict,
+ },
+ confirm: (event: Event, result: Array) => {
event.preventDefault();
layoutStore.closeHovers();
- action(overwrite, rename);
+ for (let i = result.length - 1; i >= 0; i--) {
+ const item = result[i];
+ if (item.checked.length == 2) {
+ items[item.index].rename = true;
+ } else if (item.checked.length == 1 && item.checked[0] == "origin") {
+ items[item.index].overwrite = true;
+ } else {
+ items.splice(item.index, 1);
+ }
+ }
+ if (items.length > 0) {
+ action();
+ }
},
});
return;
}
- action(overwrite, rename);
+ action(false, false);
};
const columnsResize = () => {
@@ -806,20 +819,30 @@ const drop = async (event: DragEvent) => {
const preselect = removePrefix(path) + (files[0].fullPath || files[0].name);
- if (conflict) {
+ if (conflict.length > 0) {
layoutStore.showHover({
- prompt: "replace",
- action: (event: Event) => {
- event.preventDefault();
- layoutStore.closeHovers();
- upload.handleFiles(files, path, false);
- fileStore.preselect = preselect;
+ prompt: "resolve-conflict",
+ props: {
+ conflict: conflict,
+ isUploadAction: true,
},
- confirm: (event: Event) => {
+ confirm: (event: Event, result: Array) => {
event.preventDefault();
layoutStore.closeHovers();
- upload.handleFiles(files, path, true);
- fileStore.preselect = preselect;
+ for (let i = result.length - 1; i >= 0; i--) {
+ const item = result[i];
+ if (item.checked.length == 2) {
+ continue;
+ } else if (item.checked.length == 1 && item.checked[0] == "origin") {
+ files[item.index].overwrite = true;
+ } else {
+ files.splice(item.index, 1);
+ }
+ }
+ if (files.length > 0) {
+ upload.handleFiles(files, path, true);
+ fileStore.preselect = preselect;
+ }
},
});
@@ -852,18 +875,29 @@ const uploadInput = (event: Event) => {
const path = route.path.endsWith("/") ? route.path : route.path + "/";
const conflict = upload.checkConflict(uploadFiles, fileStore.req!.items);
- if (conflict) {
+ if (conflict.length > 0) {
layoutStore.showHover({
- prompt: "replace",
- action: (event: Event) => {
- event.preventDefault();
- layoutStore.closeHovers();
- upload.handleFiles(uploadFiles, path, false);
+ prompt: "resolve-conflict",
+ props: {
+ conflict: conflict,
+ isUploadAction: true,
},
- confirm: (event: Event) => {
+ confirm: (event: Event, result: Array) => {
event.preventDefault();
layoutStore.closeHovers();
- upload.handleFiles(uploadFiles, path, true);
+ for (let i = result.length - 1; i >= 0; i--) {
+ const item = result[i];
+ if (item.checked.length == 2) {
+ continue;
+ } else if (item.checked.length == 1 && item.checked[0] == "origin") {
+ uploadFiles[item.index].overwrite = true;
+ } else {
+ uploadFiles.splice(item.index, 1);
+ }
+ }
+ if (uploadFiles.length > 0) {
+ upload.handleFiles(uploadFiles, path, true);
+ }
},
});
diff --git a/frontend/src/views/files/Preview.vue b/frontend/src/views/files/Preview.vue
index 9a67de2d7c..2a60e7df30 100644
--- a/frontend/src/views/files/Preview.vue
+++ b/frontend/src/views/files/Preview.vue
@@ -311,7 +311,11 @@ const isPdf = computed(() => fileStore.req?.extension.toLowerCase() == ".pdf");
const isEpub = computed(
() => fileStore.req?.extension.toLowerCase() == ".epub"
);
-const isCsv = computed(() => fileStore.req?.extension.toLowerCase() == ".csv");
+const isCsv = computed(
+ () =>
+ fileStore.req?.extension.toLowerCase() == ".csv" &&
+ fileStore.req.size <= CSV_MAX_SIZE
+);
const isResizeEnabled = computed(() => resizePreview);
diff --git a/frontend/src/views/settings/User.vue b/frontend/src/views/settings/User.vue
index 77786e2a99..b726d9ef0e 100644
--- a/frontend/src/views/settings/User.vue
+++ b/frontend/src/views/settings/User.vue
@@ -15,19 +15,6 @@
:isDefault="false"
:isNew="isNew"
/>
-
-
-
-
-
@@ -77,7 +64,6 @@ const error = ref();
const originalUser = ref();
const user = ref();
const createUserDir = ref(false);
-const currentPassword = ref("");
const isCurrentPasswordRequired = ref(false);
const $showError = inject("$showError")!;
@@ -134,16 +120,30 @@ const fetchData = async () => {
}
};
-const deletePrompt = () =>
- layoutStore.showHover({ prompt: "deleteUser", confirm: deleteUser });
+const deletePrompt = () => {
+ if (isCurrentPasswordRequired.value) {
+ layoutStore.showHover({
+ prompt: "current-password",
+ confirm: (event: Event, currentPassword: string) => {
+ event.preventDefault();
+ layoutStore.closeHovers();
+ deleteUser(currentPassword);
+ },
+ });
+ } else {
+ layoutStore.showHover({
+ prompt: "deleteUser",
+ confirm: () => deleteUser(""),
+ });
+ }
+};
-const deleteUser = async (e: Event) => {
- e.preventDefault();
+const deleteUser = async (currentPassword: string) => {
if (!user.value) {
return false;
}
try {
- await api.remove(user.value.id, currentPassword.value);
+ await api.remove(user.value.id, currentPassword);
router.push({ path: "/settings/users" });
$showSuccess(t("settings.userDeleted"));
} catch (err) {
@@ -157,8 +157,25 @@ const deleteUser = async (e: Event) => {
return true;
};
-const save = async (event: Event) => {
+const save = (event: Event) => {
event.preventDefault();
+ if (isCurrentPasswordRequired.value) {
+ layoutStore.showHover({
+ prompt: "current-password",
+ confirm: (event: Event, currentPassword: string) => {
+ event.preventDefault();
+ layoutStore.closeHovers();
+ send(currentPassword);
+ },
+ });
+ } else {
+ send("");
+ }
+
+ return true;
+};
+
+const send = async (currentPassword: string) => {
if (!user.value) {
return false;
}
@@ -170,11 +187,11 @@ const save = async (event: Event) => {
...user.value,
};
- const loc = await api.create(newUser, currentPassword.value);
+ const loc = await api.create(newUser, currentPassword);
router.push({ path: loc || "/settings/users" });
$showSuccess(t("settings.userCreated"));
} else {
- await api.update(user.value, ["all"], currentPassword.value);
+ await api.update(user.value, ["all"], currentPassword);
if (user.value.id === authStore.user?.id) {
authStore.updateUser(user.value);
@@ -185,7 +202,5 @@ const save = async (event: Event) => {
} catch (e: any) {
$showError(e);
}
-
- return true;
};
diff --git a/frontend/vite.config.ts b/frontend/vite.config.ts
index 583b2e3829..081591773d 100644
--- a/frontend/vite.config.ts
+++ b/frontend/vite.config.ts
@@ -14,7 +14,7 @@ const plugins = [
// defaults already drop IE support
targets: ["defaults"],
}),
- compression({ include: /\.js$/i, deleteOriginalAssets: true }),
+ compression({ include: /\.js$/, deleteOriginalAssets: false }),
];
const resolve = {
diff --git a/go.mod b/go.mod
index 8e0f0f1025..cf34bdf122 100644
--- a/go.mod
+++ b/go.mod
@@ -4,7 +4,7 @@ go 1.25
require (
github.com/asdine/storm/v3 v3.2.1
- github.com/asticode/go-astisub v0.38.0
+ github.com/asticode/go-astisub v0.39.0
github.com/disintegration/imaging v1.6.2
github.com/dsoprea/go-exif/v3 v3.0.1
github.com/flynn/go-shlex v0.0.0-20150515145356-3f9db97f8568
@@ -16,9 +16,9 @@ require (
github.com/marusama/semaphore/v2 v2.5.0
github.com/mholt/archives v0.1.5
github.com/mitchellh/go-homedir v1.1.0
- github.com/redis/go-redis/v9 v9.17.3
- github.com/samber/lo v1.52.0
- github.com/shirou/gopsutil/v4 v4.26.1
+ github.com/redis/go-redis/v9 v9.18.0
+ github.com/samber/lo v1.53.0
+ github.com/shirou/gopsutil/v4 v4.26.2
github.com/spf13/afero v1.15.0
github.com/spf13/cobra v1.10.2
github.com/spf13/pflag v1.0.10
@@ -47,7 +47,7 @@ require (
github.com/dsnet/compress v0.0.2-0.20230904184137-39efe44ab707 // indirect
github.com/dsoprea/go-logging v0.0.0-20200710184922-b02d349568dd // indirect
github.com/dsoprea/go-utility/v2 v2.0.0-20221003172846-a3e1774ef349 // indirect
- github.com/ebitengine/purego v0.9.1 // indirect
+ github.com/ebitengine/purego v0.10.0 // indirect
github.com/fsnotify/fsnotify v1.9.0 // indirect
github.com/go-errors/errors v1.5.1 // indirect
github.com/go-ole/go-ole v1.3.0 // indirect
@@ -74,6 +74,7 @@ require (
github.com/ulikunitz/xz v0.5.15 // indirect
github.com/yusufpapurcu/wmi v1.2.4 // indirect
go.etcd.io/bbolt v1.4.3 // indirect
+ go.uber.org/atomic v1.11.0 // indirect
go.yaml.in/yaml/v3 v3.0.4 // indirect
go4.org v0.0.0-20230225012048-214862532bf5 // indirect
golang.org/x/net v0.49.0 // indirect
diff --git a/go.sum b/go.sum
index 262a280c87..459182b048 100644
--- a/go.sum
+++ b/go.sum
@@ -31,8 +31,8 @@ github.com/asticode/go-astikit v0.20.0/go.mod h1:h4ly7idim1tNhaVkdVBeXQZEE3L0xbl
github.com/asticode/go-astikit v0.30.0/go.mod h1:h4ly7idim1tNhaVkdVBeXQZEE3L0xblP7fCWbgwipF0=
github.com/asticode/go-astikit v0.56.0 h1:DmD2p7YnvxiPdF0h+dRmos3bsejNEXbycENsY5JfBqw=
github.com/asticode/go-astikit v0.56.0/go.mod h1:fV43j20UZYfXzP9oBn33udkvCvDvCDhzjVqoLFuuYZE=
-github.com/asticode/go-astisub v0.38.0 h1:Qh3IO8Cotn0wwok5maid7xqsIJTwn2DtABT1UajKJaI=
-github.com/asticode/go-astisub v0.38.0/go.mod h1:WTkuSzFB+Bp7wezuSf2Oxulj5A8zu2zLRVFf6bIFQK8=
+github.com/asticode/go-astisub v0.39.0 h1:j1/rFLRUH0TT2CW9YCtBek9lRdMp96oxaZm6vbgE96M=
+github.com/asticode/go-astisub v0.39.0/go.mod h1:WTkuSzFB+Bp7wezuSf2Oxulj5A8zu2zLRVFf6bIFQK8=
github.com/asticode/go-astits v1.8.0/go.mod h1:DkOWmBNQpnr9mv24KfZjq4JawCFX1FCqjLVGvO0DygQ=
github.com/asticode/go-astits v1.13.0 h1:XOgkaadfZODnyZRR5Y0/DWkA9vrkLLPLeeOvDwfKZ1c=
github.com/asticode/go-astits v1.13.0/go.mod h1:QSHmknZ51pf6KJdHKZHJTLlMegIrhega3LPWz3ND/iI=
@@ -83,8 +83,8 @@ github.com/dsoprea/go-utility/v2 v2.0.0-20221003142440-7a1927d49d9d/go.mod h1:LV
github.com/dsoprea/go-utility/v2 v2.0.0-20221003160719-7bc88537c05e/go.mod h1:VZ7cB0pTjm1ADBWhJUOHESu4ZYy9JN+ZPqjfiW09EPU=
github.com/dsoprea/go-utility/v2 v2.0.0-20221003172846-a3e1774ef349 h1:DilThiXje0z+3UQ5YjYiSRRzVdtamFpvBQXKwMglWqw=
github.com/dsoprea/go-utility/v2 v2.0.0-20221003172846-a3e1774ef349/go.mod h1:4GC5sXji84i/p+irqghpPFZBF8tRN/Q7+700G0/DLe8=
-github.com/ebitengine/purego v0.9.1 h1:a/k2f2HQU3Pi399RPW1MOaZyhKJL9w/xFpKAg4q1s0A=
-github.com/ebitengine/purego v0.9.1/go.mod h1:iIjxzd6CiRiOG0UyXP+V1+jWqUXVjPKLAI0mRfJZTmQ=
+github.com/ebitengine/purego v0.10.0 h1:QIw4xfpWT6GWTzaW5XEKy3HXoqrJGx1ijYHzTF0/ISU=
+github.com/ebitengine/purego v0.10.0/go.mod h1:iIjxzd6CiRiOG0UyXP+V1+jWqUXVjPKLAI0mRfJZTmQ=
github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4=
github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c=
github.com/flynn/go-shlex v0.0.0-20150515145356-3f9db97f8568 h1:BHsljHzVlRcyQhjrss6TZTdY2VfCqZPbv5k3iBFa2ZQ=
@@ -166,7 +166,10 @@ github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+o
github.com/klauspost/compress v1.4.1/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A=
github.com/klauspost/compress v1.18.0 h1:c/Cqfb0r+Yi+JtIEq73FWXVkRonBlf0CRNYc8Zttxdo=
github.com/klauspost/compress v1.18.0/go.mod h1:2Pp+KzxcywXVXMr50+X0Q/Lsb43OQHYWRCY2AiWywWQ=
+github.com/klauspost/cpuid v1.2.0 h1:NMpwD2G9JSFOE1/TJjGSo5zG7Yb2bTe7eq1jH+irmeE=
github.com/klauspost/cpuid v1.2.0/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek=
+github.com/klauspost/cpuid/v2 v2.0.9 h1:lgaqFMSdTdQYdZ04uHyN2d/eKdOMyi2YLSvlQIBFYa4=
+github.com/klauspost/cpuid/v2 v2.0.9/go.mod h1:FInQzS24/EEf25PyTYn52gqo7WaD8xa0213Md/qVLRg=
github.com/klauspost/pgzip v1.2.6 h1:8RXeL5crjEUFnR2/Sn6GJNWtSQ3Dk8pq4CL3jvdDyjU=
github.com/klauspost/pgzip v1.2.6/go.mod h1:Ch1tH69qFZu15pkjo5kYi6mth2Zzwzt50oCQKQE9RUs=
github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo=
@@ -202,8 +205,8 @@ github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2/go.mod h1:iKH
github.com/power-devops/perfstat v0.0.0-20240221224432-82ca36839d55 h1:o4JXh1EVt9k/+g42oCprj/FisM4qX9L3sZB3upGN2ZU=
github.com/power-devops/perfstat v0.0.0-20240221224432-82ca36839d55/go.mod h1:OmDBASR4679mdNQnz2pUhc2G8CO2JrUAVFDRBDP/hJE=
github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA=
-github.com/redis/go-redis/v9 v9.17.3 h1:fN29NdNrE17KttK5Ndf20buqfDZwGNgoUr9qjl1DQx4=
-github.com/redis/go-redis/v9 v9.17.3/go.mod h1:u410H11HMLoB+TP67dz8rL9s6QW2j76l0//kSOd3370=
+github.com/redis/go-redis/v9 v9.18.0 h1:pMkxYPkEbMPwRdenAzUNyFNrDgHx9U+DrBabWNfSRQs=
+github.com/redis/go-redis/v9 v9.18.0/go.mod h1:k3ufPphLU5YXwNTUcCRXGxUoF1fqxnhFQmscfkCoDA0=
github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4=
github.com/rogpeppe/go-internal v1.9.0 h1:73kH8U+JUqXU8lRuOHeVHaa/SZPifC7BkcraZVejAe8=
github.com/rogpeppe/go-internal v1.9.0/go.mod h1:WtVeX8xhTBvf0smdhujwtBcq4Qrzq/fJaraNFVN+nFs=
@@ -212,10 +215,10 @@ github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQD
github.com/rwcarlsen/goexif v0.0.0-20190401172101-9e8deecbddbd/go.mod h1:hPqNNc0+uJM6H+SuU8sEs5K5IQeKccPqeSjfgcKGgPk=
github.com/sagikazarmark/locafero v0.11.0 h1:1iurJgmM9G3PA/I+wWYIOw/5SyBtxapeHDcg+AAIFXc=
github.com/sagikazarmark/locafero v0.11.0/go.mod h1:nVIGvgyzw595SUSUE6tvCp3YYTeHs15MvlmU87WwIik=
-github.com/samber/lo v1.52.0 h1:Rvi+3BFHES3A8meP33VPAxiBZX/Aws5RxrschYGjomw=
-github.com/samber/lo v1.52.0/go.mod h1:4+MXEGsJzbKGaUEQFKBq2xtfuznW9oz/WrgyzMzRoM0=
-github.com/shirou/gopsutil/v4 v4.26.1 h1:TOkEyriIXk2HX9d4isZJtbjXbEjf5qyKPAzbzY0JWSo=
-github.com/shirou/gopsutil/v4 v4.26.1/go.mod h1:medLI9/UNAb0dOI9Q3/7yWSqKkj00u+1tgY8nvv41pc=
+github.com/samber/lo v1.53.0 h1:t975lj2py4kJPQ6haz1QMgtId2gtmfktACxIXArw3HM=
+github.com/samber/lo v1.53.0/go.mod h1:4+MXEGsJzbKGaUEQFKBq2xtfuznW9oz/WrgyzMzRoM0=
+github.com/shirou/gopsutil/v4 v4.26.2 h1:X8i6sicvUFih4BmYIGT1m2wwgw2VG9YgrDTi7cIRGUI=
+github.com/shirou/gopsutil/v4 v4.26.2/go.mod h1:LZ6ewCSkBqUpvSOf+LsTGnRinC6iaNUNMGBtDkJBaLQ=
github.com/sorairolake/lzip-go v0.3.8 h1:j5Q2313INdTA80ureWYRhX+1K78mUXfMoPZCw/ivWik=
github.com/sorairolake/lzip-go v0.3.8/go.mod h1:JcBqGMV0frlxwrsE9sMWXDjqn3EeVf0/54YPsw66qkU=
github.com/sourcegraph/conc v0.3.1-0.20240121214520-5f936abd7ae8 h1:+jumHNA0Wrelhe64i8F6HNlS8pkoyMv5sreGx2Ry5Rw=
@@ -257,6 +260,8 @@ github.com/xyproto/randomstring v1.0.5/go.mod h1:rgmS5DeNXLivK7YprL0pY+lTuhNQW3i
github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY=
github.com/yusufpapurcu/wmi v1.2.4 h1:zFUKzehAFReQwLys1b/iSMl+JQGSCSjtVqQn9bBrPo0=
github.com/yusufpapurcu/wmi v1.2.4/go.mod h1:SBZ9tNy3G9/m5Oi98Zks0QjeHVDvuK0qfxQmPyzfmi0=
+github.com/zeebo/xxh3 v1.0.2 h1:xZmwmqxHZA8AI603jOQ0tMqmBr9lPeFwGg6d+xy9DC0=
+github.com/zeebo/xxh3 v1.0.2/go.mod h1:5NWz9Sef7zIDm2JHfFlcQvNekmcEl9ekUZQQKCYaDcA=
go.etcd.io/bbolt v1.3.4/go.mod h1:G5EMThwa9y8QZGBClrRx5EY+Yw9kAhnjy3bSjsnlVTQ=
go.etcd.io/bbolt v1.4.3 h1:dEadXpI6G79deX5prL3QRNP6JB8UxVkqo4UPnHaNXJo=
go.etcd.io/bbolt v1.4.3/go.mod h1:tKQlpPaYCVFctUIgFKFnAlvbmB3tpy1vkTnDWohtc0E=
@@ -264,6 +269,8 @@ go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU=
go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8=
go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
go.opencensus.io v0.22.3/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
+go.uber.org/atomic v1.11.0 h1:ZvwS0R+56ePWxUNi+Atn9dWONBPp/AUETXlHW0DxSjE=
+go.uber.org/atomic v1.11.0/go.mod h1:LUxbIzbOniOlMKjJjyPfpl4v+PKK2cNJn91OQbhoJI0=
go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto=
go.uber.org/goleak v1.3.0/go.mod h1:CoHD4mav9JJNrW/WLlf7HGZPjdw8EucARQHekz1X6bE=
go.yaml.in/yaml/v3 v3.0.4 h1:tfq32ie2Jv2UxXFdLJdh3jXuOzWiL1fo0bu/FbuKpbc=
diff --git a/http/public.go b/http/public.go
index 6dcdaff1a5..596a03c972 100644
--- a/http/public.go
+++ b/http/public.go
@@ -56,7 +56,7 @@ var withHashFile = func(fn handleFunc) handleFunc {
filePath := ""
if file.IsDir {
- basePath = filepath.Dir(basePath)
+ basePath = filepath.Clean(link.Path)
filePath = ifPath
}
diff --git a/http/resource.go b/http/resource.go
index 7066f35a63..f528473d95 100644
--- a/http/resource.go
+++ b/http/resource.go
@@ -43,7 +43,7 @@ var resourceGetHandler = withUser(func(w http.ResponseWriter, r *http.Request, d
return renderJSON(w, r, file)
} else if encoding == "true" {
if file.Type != "text" {
- return http.StatusUnsupportedMediaType, fmt.Errorf("file is not a text file")
+ return renderJSON(w, r, file)
}
f, err := d.user.Fs.Open(r.URL.Path)
diff --git a/http/tus_handlers.go b/http/tus_handlers.go
index b659d47965..68931f5d4f 100644
--- a/http/tus_handlers.go
+++ b/http/tus_handlers.go
@@ -240,7 +240,7 @@ func tusPatchHandler(cache UploadCache) handleFunc {
func tusDeleteHandler(cache UploadCache) handleFunc {
return withUser(func(_ http.ResponseWriter, r *http.Request, d *data) (int, error) {
- if r.URL.Path == "/" || !d.user.Perm.Create {
+ if r.URL.Path == "/" || !d.user.Perm.Delete {
return http.StatusForbidden, nil
}