{"version":3,"file":"ConflictPicker.mjs","sources":["../../lib/components/ConflictPicker/ConflictPickerCard.vue","../../lib/components/ConflictPicker/ConflictPickerEntry.vue","../../lib/components/ConflictPicker/ConflictPicker.vue"],"sourcesContent":["<!--\n  - SPDX-FileCopyrightText: 2026 Nextcloud GmbH and Nextcloud contributors\n  - SPDX-License-Identifier: AGPL-3.0-or-later\n-->\n\n<script setup lang=\"ts\">\nimport { mdiFile, mdiFolder } from '@mdi/js'\nimport { formatFileSize } from '@nextcloud/files'\nimport { computed, ref, watch } from 'vue'\nimport NcDateTime from '@nextcloud/vue/components/NcDateTime'\nimport NcIconSvgWrapper from '@nextcloud/vue/components/NcIconSvgWrapper'\nimport { t } from '../../utils/l10n.ts'\n\nconst props = defineProps<{\n\t/**\n\t * Preview URL, if available\n\t */\n\tpreview?: string\n\n\t/**\n\t * Modification time, if available\n\t */\n\tmtime?: Date\n\n\t/**\n\t * File size in bytes, if available\n\t */\n\tsize?: number\n\n\t/**\n\t * Whether the node is a folder (changes the fallback icon)\n\t */\n\tisFolder: boolean\n\n\t/**\n\t * Visually hidden label describing this side (\"Existing version\"/\"New version\").\n\t * Kept for screen readers as the column heading already labels it visually.\n\t */\n\tlabel: string\n\n\t/**\n\t * Bold the modification time (it is the more recent one)\n\t */\n\tboldDate?: boolean\n\n\t/**\n\t * Bold the size (it is the larger one)\n\t */\n\tboldSize?: boolean\n}>()\n\n// Previews can 404, fall back to the icon instead of a broken image\nconst previewFailed = ref(false)\nwatch(() => props.preview, () => {\n\tpreviewFailed.value = false\n})\nconst showPreview = computed(() => !!props.preview && !previewFailed.value)\n</script>\n\n<template>\n\t<span :class=\"$style.card\">\n\t\t<!-- Icon or preview -->\n\t\t<NcIconSvgWrapper\n\t\t\tv-if=\"!showPreview\"\n\t\t\t:class=\"[$style.cardIcon, { [$style.cardIcon_folder]: isFolder }]\"\n\t\t\t:path=\"isFolder ? mdiFolder : mdiFile\"\n\t\t\t:size=\"48\" />\n\t\t<img\n\t\t\tv-else\n\t\t\t:class=\"$style.cardPreview\"\n\t\t\t:src=\"preview\"\n\t\t\talt=\"\"\n\t\t\tloading=\"lazy\"\n\t\t\t@error=\"previewFailed = true\">\n\n\t\t<!-- Description -->\n\t\t<span :class=\"$style.cardDescription\">\n\t\t\t<NcDateTime\n\t\t\t\tv-if=\"mtime\"\n\t\t\t\t:class=\"{ [$style.bold]: boldDate }\"\n\t\t\t\t:timestamp=\"mtime\"\n\t\t\t\t:relativeTime=\"false\"\n\t\t\t\t:format=\"{ timeStyle: 'short', dateStyle: 'medium' }\" />\n\t\t\t<span v-else>\n\t\t\t\t{{ t('Last modified date unknown') }}\n\t\t\t</span>\n\t\t\t<span v-if=\"size !== undefined\" :class=\"{ [$style.bold]: boldSize }\">\n\t\t\t\t{{ formatFileSize(size) }}\n\t\t\t</span>\n\t\t</span>\n\n\t\t<span class=\"hidden-visually\">{{ label }}</span>\n\t</span>\n</template>\n\n<style module lang=\"scss\">\n$height: 64px;\n\n.card {\n\tdisplay: flex;\n\talign-items: center;\n\theight: $height;\n}\n\n.cardIcon,\n.cardPreview {\n\theight: $height;\n\twidth: $height;\n\tmargin: 0 var(--secondary-margin);\n\tdisplay: block;\n\tflex: 0 0 $height;\n}\n\n.cardIcon {\n\tcolor: var(--color-text-maxcontrast);\n}\n\n.cardIcon_folder {\n\tcolor: var(--color-primary-element);\n}\n\n.cardPreview {\n\toverflow: hidden;\n\tborder-radius: calc(var(--border-radius) * 2);\n\tobject-fit: cover;\n}\n\n.cardDescription {\n\tdisplay: flex;\n\tflex-direction: column;\n\tmin-width: 0;\n\n\tspan,\n\t:deep(time) {\n\t\twhite-space: nowrap;\n\t}\n}\n\n.bold {\n\tfont-weight: bold;\n}\n</style>\n","<!--\n  - SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors\n  - SPDX-License-Identifier: AGPL-3.0-or-later\n-->\n\n<script setup lang=\"ts\">\nimport type { INode } from '@nextcloud/files'\nimport type { ConflictInput } from '../../conflict-picker.ts'\n\nimport { mdiArrowRight } from '@mdi/js'\nimport { FileType } from '@nextcloud/files'\nimport { computed, ref, watch } from 'vue'\nimport NcCheckboxRadioSwitch from '@nextcloud/vue/components/NcCheckboxRadioSwitch'\nimport NcIconSvgWrapper from '@nextcloud/vue/components/NcIconSvgWrapper'\nimport ConflictPickerCard from './ConflictPickerCard.vue'\nimport { getPreviewURL } from '../../composables/preview.ts'\nimport { t } from '../../utils/l10n.ts'\n\n/**\n * Is the existing node selected\n */\nconst existingSelected = defineModel<boolean>('existingSelected', { required: true })\n\n/**\n * Is the incoming node selected\n */\nconst incomingSelected = defineModel<boolean>('incomingSelected', { required: true })\n\nconst props = defineProps<{\n\t/**\n\t * The existing node\n\t */\n\texisting: INode\n\n\t/**\n\t * The new incoming node\n\t */\n\tincoming: ConflictInput\n\n\t/**\n\t * Single-file mode: render the two versions without checkboxes.\n\t * The parent then offers \"Keep both\"/\"Replace\" buttons instead.\n\t */\n\tisSingle?: boolean\n}>()\n\ndefineExpose({ validate })\n\nconst isFileSystemEntry = (o: unknown): o is FileSystemEntry => 'FileSystemEntry' in window && o instanceof window.FileSystemEntry\nconst isFileSystemFileEntry = (o: unknown): o is FileSystemFileEntry => 'FileSystemFileEntry' in window && o instanceof window.FileSystemFileEntry\n\nconst PREVIEW_SIZE = 64\n\nconst validationMessage = ref('')\n\nconst incomingPreview = ref<string>()\nconst existingPreview = ref<string>()\n\nconst incomingMTime = ref<Date>()\nconst existingMTime = ref<Date>()\n\nconst incomingSize = ref<number>()\nconst existingSize = ref<number>()\n\nconst conflictResolved = computed(() => incomingSelected.value || existingSelected.value)\n\nconst isExistingFolder = computed(() => props.existing.type === FileType.Folder)\nconst isIncomingFolder = computed(() => {\n\tif (isFileSystemEntry(props.incoming)) {\n\t\treturn props.incoming.isDirectory\n\t} else if (props.incoming instanceof File) {\n\t\treturn false\n\t}\n\treturn props.incoming.type === FileType.Folder\n})\n\n// Bold whichever value differs to ease comparison: the newer date and the larger size.\nconst incomingNewer = computed(() => !!incomingMTime.value && !!existingMTime.value && incomingMTime.value > existingMTime.value)\nconst existingNewer = computed(() => !!incomingMTime.value && !!existingMTime.value && existingMTime.value > incomingMTime.value)\nconst incomingLarger = computed(() => incomingSize.value !== undefined && existingSize.value !== undefined && incomingSize.value > existingSize.value)\nconst existingLarger = computed(() => incomingSize.value !== undefined && existingSize.value !== undefined && existingSize.value > incomingSize.value)\n\nwatch(() => props.existing, async () => {\n\texistingMTime.value = getMTime(props.existing)\n\texistingSize.value = getSize(props.existing)\n\texistingPreview.value = await getPreview(props.existing)\n})\n\nwatch(() => props.incoming, async () => {\n\tconst file = await getFileOrNode(props.incoming)\n\tif (file === null) {\n\t\treturn\n\t}\n\n\tincomingMTime.value = getMTime(file)\n\tincomingSize.value = getSize(file)\n\tincomingPreview.value = await getPreview(file)\n})\n\n/**\n * If the input is a filesystem file entry the file is loaded and returned.\n * In case of a directory null is returned.\n * Otherwise the INode or File is returned.\n *\n * @param input - The conflict input\n */\nasync function getFileOrNode(input: ConflictInput): Promise<File | INode | null> {\n\tif (isFileSystemFileEntry(input)) {\n\t\treturn await new Promise((resolve, reject) => input.file(resolve, reject))\n\t} else if (isFileSystemEntry(input)) {\n\t\treturn null\n\t}\n\treturn input\n}\n\n/**\n * Get the filesize if available.\n *\n * @param input - The input file or node\n */\nfunction getSize(input: INode | File): number | undefined {\n\treturn input.size\n}\n\n/**\n * Get the mtime if available.\n *\n * @param input - The input file or node\n */\nfunction getMTime(input: INode | File): Date | undefined {\n\tif (input instanceof File) {\n\t\tconst mtime = input.lastModified\n\t\tif (mtime > 0) {\n\t\t\treturn new Date(mtime)\n\t\t}\n\t} else {\n\t\treturn input.mtime\n\t}\n}\n\n/**\n * Get the preview url if possible.\n * For INode the server preview endpoint is used, for files a data URL is generated.\n *\n * @param input - The input file or node\n */\nasync function getPreview(input: INode | File): Promise<string | undefined> {\n\tif (input instanceof File) {\n\t\treturn await getFilePreview(input)\n\t}\n\treturn getPreviewURL(input, { size: PREVIEW_SIZE })?.toString()\n}\n\n/**\n * Get a object url for a local file.\n *\n * @param file - The input file\n */\nasync function getFilePreview(file: File): Promise<string | undefined> {\n\tif (!file.type.startsWith('image/')) {\n\t\treturn undefined\n\t}\n\n\tconst { resolve, promise } = Promise.withResolvers<string | undefined>()\n\tconst reader = new FileReader()\n\treader.onload = async (e) => {\n\t\tconst result = e?.target?.result\n\t\tif (result instanceof ArrayBuffer) {\n\t\t\tconst blob = new Blob([result], { type: file.type })\n\t\t\tconst url = URL.createObjectURL(blob)\n\t\t\tresolve(url)\n\t\t\treturn\n\t\t}\n\t\tresolve(undefined)\n\t}\n\treader.readAsArrayBuffer(file)\n\treturn promise\n}\n\n/**\n * Check the validitiy of the conflict resolution\n */\nfunction validate() {\n\tvalidationMessage.value = !incomingSelected.value && !existingSelected.value\n\t\t? t('You need to choose at least one conflict solution')\n\t\t: ''\n}\n</script>\n\n<template>\n\t<fieldset :class=\"$style.pickerEntry\">\n\t\t<legend>{{ existing.displayname }}</legend>\n\n\t\t<!-- Existing version (left) -->\n\t\t<NcCheckboxRadioSwitch\n\t\t\tv-if=\"!isSingle\"\n\t\t\tv-model=\"existingSelected\"\n\t\t\t:class=\"$style.pickerEntryColumn\"\n\t\t\t:error=\"!!validationMessage\"\n\t\t\t:helperText=\"validationMessage\"\n\t\t\t:required=\"!conflictResolved\">\n\t\t\t<ConflictPickerCard\n\t\t\t\t:preview=\"existingPreview\"\n\t\t\t\t:mtime=\"existingMTime\"\n\t\t\t\t:size=\"existingSize\"\n\t\t\t\t:isFolder=\"isExistingFolder\"\n\t\t\t\t:label=\"t('Existing version')\"\n\t\t\t\t:boldDate=\"existingNewer\"\n\t\t\t\t:boldSize=\"existingLarger\" />\n\t\t</NcCheckboxRadioSwitch>\n\t\t<ConflictPickerCard\n\t\t\tv-else\n\t\t\t:class=\"$style.pickerEntryColumn\"\n\t\t\t:preview=\"existingPreview\"\n\t\t\t:mtime=\"existingMTime\"\n\t\t\t:size=\"existingSize\"\n\t\t\t:isFolder=\"isExistingFolder\"\n\t\t\t:label=\"t('Existing version')\"\n\t\t\t:boldDate=\"existingNewer\"\n\t\t\t:boldSize=\"existingLarger\" />\n\n\t\t<!-- Arrow pointing from the existing to the new version -->\n\t\t<NcIconSvgWrapper\n\t\t\t:class=\"$style.pickerEntryArrow\"\n\t\t\tdirectional\n\t\t\t:path=\"mdiArrowRight\" />\n\n\t\t<!-- New version (right) -->\n\t\t<NcCheckboxRadioSwitch\n\t\t\tv-if=\"!isSingle\"\n\t\t\tv-model=\"incomingSelected\"\n\t\t\t:class=\"$style.pickerEntryColumn\"\n\t\t\t:error=\"!!validationMessage\"\n\t\t\t:helperText=\"validationMessage\"\n\t\t\t:required=\"!conflictResolved\">\n\t\t\t<ConflictPickerCard\n\t\t\t\t:preview=\"incomingPreview\"\n\t\t\t\t:mtime=\"incomingMTime\"\n\t\t\t\t:size=\"incomingSize\"\n\t\t\t\t:isFolder=\"isIncomingFolder\"\n\t\t\t\t:label=\"t('New version')\"\n\t\t\t\t:boldDate=\"incomingNewer\"\n\t\t\t\t:boldSize=\"incomingLarger\" />\n\t\t</NcCheckboxRadioSwitch>\n\t\t<ConflictPickerCard\n\t\t\tv-else\n\t\t\t:class=\"$style.pickerEntryColumn\"\n\t\t\t:preview=\"incomingPreview\"\n\t\t\t:mtime=\"incomingMTime\"\n\t\t\t:size=\"incomingSize\"\n\t\t\t:isFolder=\"isIncomingFolder\"\n\t\t\t:label=\"t('New version')\"\n\t\t\t:boldDate=\"incomingNewer\"\n\t\t\t:boldSize=\"incomingLarger\" />\n\t</fieldset>\n</template>\n\n<style module lang=\"scss\">\n.pickerEntry {\n\tdisplay: grid;\n\talign-items: center;\n\tgrid-template-columns: 1fr var(--arrow-column) 1fr;\n\n\t// last fieldset does not have a border\n\t&:not(:last-of-type) {\n\t\tborder-bottom: 1px solid var(--color-border);\n\t}\n\n\tlegend {\n\t\t// span the full row above the two columns\n\t\tgrid-column: 1 / -1;\n\t\t// the legend names the file both versions belong to\n\t\tfont-weight: bold;\n\t}\n}\n\n.pickerEntryArrow {\n\tjustify-self: center;\n\tcolor: var(--color-text-maxcontrast);\n}\n</style>\n","<!--\n  - SPDX-FileCopyrightText: 2023 Nextcloud GmbH and Nextcloud contributors\n  - SPDX-License-Identifier: AGPL-3.0-or-later\n-->\n\n<script setup lang=\"ts\">\nimport type { INode } from '@nextcloud/files'\nimport type { ConflictInput, ConflictResolutionResult } from '../../conflict-picker.ts'\n\nimport { mdiArrowRight } from '@mdi/js'\nimport { basename } from '@nextcloud/paths'\nimport { computed, shallowRef, useTemplateRef } from 'vue'\nimport NcButton from '@nextcloud/vue/components/NcButton'\nimport NcCheckboxRadioSwitch from '@nextcloud/vue/components/NcCheckboxRadioSwitch'\nimport NcDialog from '@nextcloud/vue/components/NcDialog'\nimport NcIconSvgWrapper from '@nextcloud/vue/components/NcIconSvgWrapper'\nimport ConflictPickerEntry from './ConflictPickerEntry.vue'\nimport { showError } from '../../toast.ts'\nimport { n, t } from '../../utils/l10n.ts'\nimport { logger } from '../../utils/logger.ts'\n\nconst props = defineProps<{\n\t/**\n\t * Container for the dialog\n\t */\n\tcontainer?: string | undefined\n\n\t/**\n\t * Directory with the conflicts, its name is shown in the description\n\t */\n\tdirname?: string\n\n\t/**\n\t * The existing nodes (same names as the conflicts)\n\t */\n\texisting: INode[]\n\n\t/**\n\t * The incoming nodes with conflicting names compared to `existing`\n\t */\n\tincoming: ConflictInput[]\n\n\t/**\n\t * If set to true no hint about overwriting directory content will be shown\n\t */\n\trecursiveUpload?: boolean\n\n\t/**\n\t * If set tot true a hint is shown that any folder content will be overwritten\n\t */\n\tisOverwriting?: boolean\n}>()\n\nconst emit = defineEmits<{\n\tclose: [result: ConflictResolutionResult<ConflictInput> | null]\n}>()\n\nconst blockedTitle = t('You need to select at least one version of each file to continue.')\n\nconst formElement = useTemplateRef('form')\nconst conflictEntries = useTemplateRef('conflictEntry')\n\nconst isSingle = computed(() => props.incoming.length === 1)\n\n// Preselect the new files so the user can continue right away.\nconst newSelected = shallowRef<ConflictInput[]>([...props.incoming])\nconst oldSelected = shallowRef<ConflictInput[]>([])\n\nconst isNoNewSelected = computed(() => newSelected.value.length === 0)\nconst areAllNewSelected = computed(() => newSelected.value.length === props.incoming.length)\nconst areSomeNewSelected = computed(() => !areAllNewSelected.value && !isNoNewSelected.value)\nconst areAllOldSelected = computed(() => oldSelected.value.length === props.existing.length)\nconst areSomeOldSelected = computed(() => !areAllOldSelected.value && !isNoNewSelected.value)\nconst areConflictsResolved = computed(() => {\n\tfor (const conflict of props.incoming) {\n\t\tif (oldSelected.value.includes(conflict) || newSelected.value.includes(conflict)) {\n\t\t\tcontinue\n\t\t}\n\t\treturn false\n\t}\n\treturn true\n})\n\nconst dialogName = computed(() => isSingle.value\n\t? t('Select file to keep')\n\t: t('Select files to keep'))\n\n// Only the folder name, the root folder is called \"All files\" in the Files app\nconst folderName = computed(() => basename(props.dirname ?? '') || t('All files'))\n\n// Split on the placeholder so the folder name can be shown in bold\nconst descriptionParts = computed(() => {\n\tconst message = isSingle.value\n\t\t? t('An item with the same name already exists in {dirname}.')\n\t\t: t('Items with the same name already exist in {dirname}, select which to keep.')\n\tconst [before, after = ''] = message.split('{dirname}')\n\treturn { before, after }\n})\n\n/**\n * Cancel the conflic resolution (closing the dialog)\n */\nfunction onCancel() {\n\temit('close', null)\n}\n\n/**\n * Single-file: replace the existing file with the new one.\n */\nfunction onReplace() {\n\temit('close', {\n\t\tselected: [...props.incoming],\n\t\trenamed: [],\n\t\tskipped: [],\n\t})\n}\n\n/**\n * Single-file: keep both, the new file is uploaded with a renamed copy.\n */\nfunction onKeepBoth() {\n\temit('close', {\n\t\tselected: [],\n\t\trenamed: [...props.incoming],\n\t\tskipped: [],\n\t})\n}\n\n/**\n * Skip all conflicts (no upload will be performed)\n */\nfunction onSkipAll() {\n\tlogger.debug('Conflict skipped. Ignoring all conflicting files')\n\temit('close', {\n\t\tselected: [],\n\t\trenamed: [],\n\t\tskipped: [...props.incoming],\n\t})\n}\n\n/**\n * @param selected - The toggle state\n */\nfunction onSelectAllNew(selected: boolean) {\n\tif (selected) {\n\t\tlogger.debug('Selected all new files')\n\t\tnewSelected.value = [...props.incoming]\n\t} else {\n\t\tlogger.debug('Cleared new selection')\n\t\tnewSelected.value = []\n\t}\n}\n\n/**\n * @param selected - The toggle state\n */\nfunction onSelectAllOld(selected: boolean) {\n\tif (selected) {\n\t\tlogger.debug('Selected all existing files')\n\t\toldSelected.value = [...props.incoming]\n\t} else {\n\t\tlogger.debug('Cleared old selection')\n\t\toldSelected.value = []\n\t}\n}\n\n/**\n * @param conflict - The conflict that should be skipped\n */\nfunction toggleOldSelected(conflict: ConflictInput) {\n\tif (oldSelected.value.includes(conflict)) {\n\t\toldSelected.value = oldSelected.value.filter((entry) => entry !== conflict)\n\t} else {\n\t\toldSelected.value = [...oldSelected.value, conflict]\n\t}\n}\n\n/**\n * @param conflict - The conflict where the incoming node should be used\n */\nfunction toggleNewSelected(conflict: ConflictInput) {\n\tif (newSelected.value.includes(conflict)) {\n\t\tnewSelected.value = newSelected.value.filter((entry) => entry !== conflict)\n\t} else {\n\t\tnewSelected.value = [...newSelected.value, conflict]\n\t}\n}\n\n/**\n * Handle submit by validating all conflict resolutions\n */\nfunction onSubmit() {\n\tif (!areConflictsResolved.value) {\n\t\tfor (const entry of conflictEntries.value!) {\n\t\t\tentry!.validate()\n\t\t}\n\n\t\tformElement.value!.reportValidity()\n\t\tshowError(blockedTitle)\n\t\treturn\n\t}\n\n\tconst selected = newSelected.value.filter((entry) => !oldSelected.value.includes(entry))\n\tconst renamed = newSelected.value.filter((entry) => oldSelected.value.includes(entry))\n\tconst skipped = oldSelected.value.filter((entry) => !newSelected.value.includes(entry))\n\n\temit('close', {\n\t\trenamed,\n\t\tselected,\n\t\tskipped,\n\t})\n}\n</script>\n\n<template>\n\t<NcDialog\n\t\t:container\n\t\t:class=\"$style.picker\"\n\t\t:name=\"dialogName\"\n\t\tsize=\"large\"\n\t\t@closing=\"onCancel\">\n\t\t<!-- Header -->\n\t\t<div :class=\"$style.pickerHeader\">\n\t\t\t<!-- Description -->\n\t\t\t<p id=\"conflict-picker-description\" :class=\"$style.pickerDescription\">\n\t\t\t\t{{ descriptionParts.before }}<strong>{{ folderName }}</strong>{{ descriptionParts.after }}<br>\n\t\t\t\t<template v-if=\"!isSingle\">\n\t\t\t\t\t{{ t('Existing files and folders will be deleted if not selected. If both are chosen, they will be renamed.') }}<br>\n\t\t\t\t</template>\n\t\t\t\t<template v-if=\"recursiveUpload\">\n\t\t\t\t\t{{ t('When a new folder is selected, the content is written into the existing folder and a recursive conflict resolution is performed.') }}\n\t\t\t\t</template>\n\t\t\t\t<template v-else-if=\"isOverwriting\">\n\t\t\t\t\t{{ t('When a new folder is selected, any files within it will also be overwritten.') }}\n\t\t\t\t</template>\n\t\t\t\t<template v-else>\n\t\t\t\t\t{{ t('When a new folder is selected, any conflicting files within it will also be overwritten.') }}\n\t\t\t\t</template>\n\t\t\t</p>\n\t\t</div>\n\n\t\t<!-- Main form and conflict picker -->\n\t\t<form\n\t\t\tref=\"form\"\n\t\t\taria-labelledby=\"conflict-picker-description\"\n\t\t\t:class=\"$style.pickerForm\"\n\t\t\t@submit.prevent.stop=\"onSubmit\">\n\t\t\t<!-- Column headings / select all checkboxes (only useful with multiple files) -->\n\t\t\t<fieldset v-if=\"!isSingle\" :class=\"$style.pickerSelectAll\">\n\t\t\t\t<legend class=\"hidden-visually\">\n\t\t\t\t\t{{ t('Select all checkboxes') }}\n\t\t\t\t</legend>\n\t\t\t\t<NcCheckboxRadioSwitch\n\t\t\t\t\t:modelValue=\"areAllOldSelected\"\n\t\t\t\t\t:indeterminate=\"areSomeOldSelected\"\n\t\t\t\t\t@update:modelValue=\"onSelectAllOld\">\n\t\t\t\t\t{{ t('Existing files') }}\n\t\t\t\t</NcCheckboxRadioSwitch>\n\t\t\t\t<span />\n\t\t\t\t<NcCheckboxRadioSwitch\n\t\t\t\t\t:modelValue=\"areAllNewSelected\"\n\t\t\t\t\t:indeterminate=\"areSomeNewSelected\"\n\t\t\t\t\t@update:modelValue=\"onSelectAllNew\">\n\t\t\t\t\t{{ t('New files') }}\n\t\t\t\t</NcCheckboxRadioSwitch>\n\t\t\t</fieldset>\n\n\t\t\t<!-- Files loop -->\n\t\t\t<ConflictPickerEntry\n\t\t\t\tv-for=\"(node, index) in existing\"\n\t\t\t\tref=\"conflictEntry\"\n\t\t\t\t:key=\"node.fileid\"\n\t\t\t\t:isSingle=\"isSingle\"\n\t\t\t\t:incoming=\"incoming[index]!\"\n\t\t\t\t:existing=\"node\"\n\t\t\t\t:incomingSelected=\"newSelected.includes(incoming[index]!)\"\n\t\t\t\t:existingSelected=\"oldSelected.includes(incoming[index]!)\"\n\t\t\t\t@update:existingSelected=\"toggleOldSelected(incoming[index]!)\"\n\t\t\t\t@update:incomingSelected=\"toggleNewSelected(incoming[index]!)\" />\n\t\t</form>\n\n\t\t<!-- Controls -->\n\t\t<template #actions>\n\t\t\t<!-- Cancel the entire operation -->\n\t\t\t<NcButton\n\t\t\t\t:title=\"t('Cancel the entire operation')\"\n\t\t\t\tdata-cy-conflict-picker-cancel\n\t\t\t\tvariant=\"tertiary\"\n\t\t\t\t@click=\"onCancel\">\n\t\t\t\t{{ t('Cancel') }}\n\t\t\t</NcButton>\n\n\t\t\t<!-- Align right -->\n\t\t\t<span :class=\"$style.pickerActionSeparator\" />\n\n\t\t\t<!-- Single file: keep both or replace -->\n\t\t\t<template v-if=\"isSingle\">\n\t\t\t\t<NcButton variant=\"secondary\" @click=\"onKeepBoth\">\n\t\t\t\t\t{{ t('Keep both') }}\n\t\t\t\t</NcButton>\n\t\t\t\t<NcButton variant=\"primary\" @click=\"onReplace\">\n\t\t\t\t\t{{ t('Replace') }}\n\t\t\t\t</NcButton>\n\t\t\t</template>\n\n\t\t\t<!-- Multiple files: skip all or continue with the selection -->\n\t\t\t<template v-else>\n\t\t\t\t<NcButton @click=\"onSkipAll\">\n\t\t\t\t\t{{ n('Skip %n file', 'Skip %n files', incoming.length) }}\n\t\t\t\t</NcButton>\n\t\t\t\t<NcButton\n\t\t\t\t\t:aria-disabled=\"!areConflictsResolved\"\n\t\t\t\t\t:class=\"[\n\t\t\t\t\t\t$style.pickerActionSubmit,\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t[$style.pickerActionSubmit_disabled]: !areConflictsResolved,\n\t\t\t\t\t\t},\n\t\t\t\t\t]\"\n\t\t\t\t\t:title=\"areConflictsResolved ? '' : blockedTitle\"\n\t\t\t\t\ttype=\"submit\"\n\t\t\t\t\tvariant=\"primary\"\n\t\t\t\t\t@click.stop.prevent=\"onSubmit\">\n\t\t\t\t\t<template #icon>\n\t\t\t\t\t\t<NcIconSvgWrapper directional :path=\"mdiArrowRight\" />\n\t\t\t\t\t</template>\n\t\t\t\t\t{{ t('Continue') }}\n\t\t\t\t\t<span v-if=\"!areConflictsResolved\" class=\"hidden-visually\">{{ blockedTitle }}</span>\n\t\t\t\t</NcButton>\n\t\t\t</template>\n\t\t</template>\n\t</NcDialog>\n</template>\n\n<style module lang=\"scss\">\n.picker {\n\t--margin: 36px;\n\t--secondary-margin: 18px;\n\t// shared width of the middle arrow column, so headings and entries line up\n\t--arrow-column: 44px;\n\n\t:global(.dialog__actions) {\n\t\t// Match the whitespace the buttons have on the sides\n\t\tmargin-block-end: calc(var(--default-grid-baseline) * 6);\n\t}\n}\n\n// Keeps the cancel button on the start side, all other actions stay at the end\n.pickerActionSeparator {\n\tmargin-inline-start: auto;\n}\n\n.pickerHeader {\n\tposition: sticky;\n\tz-index: 10;\n\ttop: 0;\n\tpadding: 0 var(--margin);\n\tpadding-bottom: var(--secondary-margin);\n\tbackground-color: var(--color-main-background);\n}\n\n.pickerForm {\n\tposition: relative;\n\toverflow: auto;\n\tpadding: 0 var(--margin);\n\t// overlap header bottom padding\n\tmargin-top: calc(-1 * var(--secondary-margin));\n}\n\n.pickerActionSubmit_disabled {\n\topacity: 0.7;\n\tfilter: saturate(50%);\n}\n\n.pickerSelectAll {\n\tdisplay: grid;\n\twidth: 100%;\n\tmargin-top: calc(var(--secondary-margin) * 1.5);\n\tpadding-bottom: var(--secondary-margin);\n\tgrid-template-columns: 1fr var(--arrow-column) 1fr;\n\talign-items: center;\n\n\tlegend {\n\t\tdisplay: flex;\n\t\talign-items: center;\n\t\tgrid-column: 1 / -1;\n\t\twidth: 100%;\n\t\tmargin-bottom: calc(var(--secondary-margin) / 2);\n\t}\n\n\t&.conflict-picker__all {\n\t\tposition: sticky;\n\t\ttop: 0;\n\t\tmargin: 0;\n\t\tpadding: var(--secondary-margin) 0;\n\t\tbackground-image: linear-gradient(to top, transparent, var(--color-main-background-blur) 10%, var(--color-main-background) 15%);\n\t\t// Proper select all checkboxes alignment\n\t\t& + fieldset {\n\t\t\tmargin-top: 0;\n\t\t}\n\n\t\t:deep(label) {\n\t\t\tfont-weight: bold;\n\t\t}\n\t}\n}\n</style>\n"],"names":["_createElementBlock","_normalizeClass","$style","_createBlock","_unref","_createElementVNode","_openBlock","_toDisplayString","_useModel","_createVNode","_Fragment","_createTextVNode","_renderList"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAaA,UAAM,QAAQ;AAuCd,UAAM,gBAAgB,IAAI,KAAK;AAC/B,UAAM,MAAM,MAAM,SAAS,MAAM;AAChC,oBAAc,QAAQ;AAAA,IACvB,CAAC;AACD,UAAM,cAAc,SAAS,MAAM,CAAC,CAAC,MAAM,WAAW,CAAC,cAAc,KAAK;;0BAIzEA,mBAgCO,QAAA;AAAA,QAhCA,OAAKC,eAAEC,KAAAA,OAAO,IAAI;AAAA,MAAA;SAGhB,YAAA,sBADRC,YAIcC,MAAA,gBAAA,GAAA;AAAA;UAFZ,OAAKH,eAAA,CAAGC,YAAO,aAAaA,KAAAA,OAAO,eAAe,GAAG,QAAA,SAAA,CAAQ,CAAA;AAAA,UAC7D,MAAM,QAAA,WAAWE,MAAA,SAAA,IAAYA,MAAA,OAAA;AAAA,UAC7B,MAAM;AAA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