|
5 | 5 | @dragleave.prevent="dragging = false" |
6 | 6 | @drop.prevent="dragging = false; doEmit($event.dataTransfer.files)" |
7 | 7 | > |
8 | | - <label :id="id" class="flex flex-col items-center justify-center w-full border-2 border-dashed rounded-lg cursor-pointer dark:hover:bg-gray-800 |
9 | | - hover:bg-gray-100 dark:hover:border-gray-500 dark:hover:bg-gray-600" |
| 8 | + <label :id="id" class="flex flex-col items-center justify-center w-full border-2 border-dashed rounded-lg cursor-pointer |
| 9 | + hover:bg-lightDropzoneBackgroundHover hover:border-lightDropzoneBorderHover dark:hover:border-darkDropzoneBorderHover dark:hover:bg-darkDropzoneBackgroundHover" |
10 | 10 | :class="{ |
11 | | - 'border-blue-600 dark:border-blue-400': dragging, |
12 | | - 'border-gray-300 dark:border-gray-600': !dragging, |
13 | | - 'bg-blue-50 dark:bg-blue-800': dragging, |
14 | | - 'bg-gray-50 dark:bg-gray-800': !dragging, |
| 11 | + 'border-lightDropzoneBorderDragging dark:border-darkDropzoneBorderDragging': dragging, |
| 12 | + 'border-lightDropzoneBorder dark:border-darkDropzoneBorder': !dragging, |
| 13 | + 'bg-lightDropzoneBackgroundDragging dark:bg-darkDropzoneBackgroundDragging': dragging, |
| 14 | + 'bg-lightDropzoneBackground dark:bg-darkDropzoneBackground': !dragging, |
15 | 15 | 'min-h-32 h-full': props.multiple, |
16 | 16 | 'h-32': !props.multiple, |
17 | 17 | }" |
18 | 18 | > |
19 | 19 | <div class="flex flex-col items-center justify-center pt-5 pb-6"> |
20 | 20 |
|
21 | 21 |
|
22 | | - <svg v-if="!selectedFiles.length" class="w-8 h-8 mb-4 text-gray-500 dark:text-gray-400" aria-hidden="true" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 20 16"> |
| 22 | + <svg v-if="!selectedFiles.length" class="w-8 h-8 mb-4 text-lightDropzoneIcon dark:text-darkDropzoneIcon" aria-hidden="true" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 20 16"> |
23 | 23 | <path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M13 13h3a3 3 0 0 0 0-6h-.025A5.56 5.56 0 0 0 16 6.5 5.5 5.5 0 0 0 5.207 5.021C5.137 5.017 5.071 5 5 5a4 4 0 0 0 0 8h2.167M10 15V6m0 0L8 8m2-2 2 2"/> |
24 | 24 | </svg> |
25 | 25 | <div v-else class="flex items-center justify-center flex-wrap gap-1 w-full mt-1 mb-4"> |
26 | 26 | <template v-for="file in selectedFiles"> |
27 | | - <p class="text-sm text-gray-500 dark:text-gray-400 flex items-center gap-1"> |
| 27 | + <p class="text-sm text-lightDropzoneIcon dark:text-darkDropzoneIcon flex items-center gap-1"> |
28 | 28 | <IconFileSolid class="w-5 h-5" /> |
29 | 29 | {{ file.name }} ({{ humanifySize(file.size) }}) |
30 | 30 | </p> |
31 | 31 | </template> |
32 | 32 |
|
33 | 33 | </div> |
34 | 34 |
|
35 | | - <p v-if="!selectedFiles.length" class="mb-2 text-sm text-gray-500 dark:text-gray-400"><span class="font-semibold">{{ $t('Click to upload') }}</span> {{ $t('or drag and drop') }}</p> |
36 | | - <p class="text-xs text-gray-500 dark:text-gray-400"> |
| 35 | + <p v-if="!selectedFiles.length" class="mb-2 text-sm text-lightDropzoneText dark:text-darkDropzoneText"><span class="font-semibold">{{ $t('Click to upload') }}</span> {{ $t('or drag and drop') }}</p> |
| 36 | + <p class="text-xs text-lightDropzoneText dark:text-darkDropzoneText"> |
37 | 37 | {{ props.extensions.join(', ').toUpperCase().replace(/\./g, '') }} |
38 | 38 | <template v-if="props.maxSizeBytes"> |
39 | 39 | (Max size: {{ humanifySize(props.maxSizeBytes) }}) |
|
0 commit comments