diff --git a/lang/ar/gallery.php b/lang/ar/gallery.php index eddbbc304d0..0f95f13baf6 100644 --- a/lang/ar/gallery.php +++ b/lang/ar/gallery.php @@ -140,6 +140,8 @@ 'header_photos' => 'الصور', 'show_highlighted' => 'Filter highlighted images', 'copy_highlighted_names' => 'Copy highlighted photo names to clipboard', + 'toggle_touch_select' => 'Toggle selection mode', + 'photo_actions' => 'Photo actions', 'no_results' => 'لا يوجد شيء هنا', 'upload' => 'رفع الصور', 'tabs' => [ diff --git a/lang/bg/gallery.php b/lang/bg/gallery.php index 0271040c022..0b7c1bda2e5 100644 --- a/lang/bg/gallery.php +++ b/lang/bg/gallery.php @@ -140,6 +140,8 @@ 'header_photos' => 'Снимки', 'show_highlighted' => 'Филтрирай отбелязаните снимки', 'copy_highlighted_names' => 'Копирай имената на маркираните снимки', + 'toggle_touch_select' => 'Toggle selection mode', + 'photo_actions' => 'Photo actions', 'no_results' => 'Няма какво да се покаже', 'upload' => 'Качване на снимки', 'tabs' => [ diff --git a/lang/cz/gallery.php b/lang/cz/gallery.php index 856f2f9d877..a2748ed5026 100644 --- a/lang/cz/gallery.php +++ b/lang/cz/gallery.php @@ -140,6 +140,8 @@ 'header_photos' => 'Fotografie', 'show_highlighted' => 'Filtrovat zvýrazněné obrázky', 'copy_highlighted_names' => 'Kopírovat názvy zvýrazněných fotografií do schránky', + 'toggle_touch_select' => 'Toggle selection mode', + 'photo_actions' => 'Photo actions', 'no_results' => 'Zde není nic k vidění', 'upload' => 'Nahrát fotografie', 'tabs' => [ diff --git a/lang/de/gallery.php b/lang/de/gallery.php index 4f0c0b5e638..9b8389d6225 100644 --- a/lang/de/gallery.php +++ b/lang/de/gallery.php @@ -139,6 +139,8 @@ 'header_photos' => 'Fotos', 'show_highlighted' => 'Favoriten filtern', 'copy_highlighted_names' => 'Namen der Favoriten in die Zwischenablage kopieren', + 'toggle_touch_select' => 'Toggle selection mode', + 'photo_actions' => 'Photo actions', 'no_results' => 'Hier gibt es nichts zu sehen', 'upload' => 'Fotos hochladen', 'tabs' => [ diff --git a/lang/el/gallery.php b/lang/el/gallery.php index d6fd852a9f6..f97f7084fda 100644 --- a/lang/el/gallery.php +++ b/lang/el/gallery.php @@ -140,6 +140,8 @@ 'header_photos' => 'Photos', 'show_highlighted' => 'Filter highlighted images', 'copy_highlighted_names' => 'Copy highlighted photo names to clipboard', + 'toggle_touch_select' => 'Toggle selection mode', + 'photo_actions' => 'Photo actions', 'no_results' => 'Nothing to see here', 'upload' => 'Upload photos', 'tabs' => [ diff --git a/lang/en/gallery.php b/lang/en/gallery.php index 1324a3de326..f6559990706 100644 --- a/lang/en/gallery.php +++ b/lang/en/gallery.php @@ -140,6 +140,8 @@ 'header_photos' => 'Photos', 'show_highlighted' => 'Filter highlighted images', 'copy_highlighted_names' => 'Copy highlighted photo names to clipboard', + 'toggle_touch_select' => 'Toggle selection mode', + 'photo_actions' => 'Photo actions', 'no_results' => 'Nothing to see here', 'upload' => 'Upload photos', 'tabs' => [ diff --git a/lang/es/gallery.php b/lang/es/gallery.php index 8eb34238c22..f46ed8e1396 100644 --- a/lang/es/gallery.php +++ b/lang/es/gallery.php @@ -139,6 +139,8 @@ 'header_photos' => 'Fotos', 'show_highlighted' => 'Filter highlighted images', 'copy_highlighted_names' => 'Copy highlighted photo names to clipboard', + 'toggle_touch_select' => 'Toggle selection mode', + 'photo_actions' => 'Photo actions', 'no_results' => 'No hay nada que ver aquí', 'upload' => 'Subir fotos', 'tabs' => [ diff --git a/lang/fa/gallery.php b/lang/fa/gallery.php index d25142504a2..0cc7a72a0e6 100644 --- a/lang/fa/gallery.php +++ b/lang/fa/gallery.php @@ -140,6 +140,8 @@ 'header_photos' => 'عکس‌ها', 'show_highlighted' => 'Filter highlighted images', 'copy_highlighted_names' => 'Copy highlighted photo names to clipboard', + 'toggle_touch_select' => 'Toggle selection mode', + 'photo_actions' => 'Photo actions', 'no_results' => 'اینجا چیزی برای نمایش نیست', 'upload' => 'بارگذاری عکس‌ها', 'tabs' => [ diff --git a/lang/fr/gallery.php b/lang/fr/gallery.php index d20d3a1f841..91bc26312a2 100644 --- a/lang/fr/gallery.php +++ b/lang/fr/gallery.php @@ -140,6 +140,8 @@ 'header_photos' => 'Photos', 'show_highlighted' => 'Filter highlighted images', 'copy_highlighted_names' => 'Copy highlighted photo names to clipboard', + 'toggle_touch_select' => 'Toggle selection mode', + 'photo_actions' => 'Photo actions', 'no_results' => 'Rien à voir ici', 'upload' => 'Téléverser des photos', 'tabs' => [ diff --git a/lang/hu/gallery.php b/lang/hu/gallery.php index 5208cee3d7f..add68d7b20e 100644 --- a/lang/hu/gallery.php +++ b/lang/hu/gallery.php @@ -140,6 +140,8 @@ 'header_photos' => 'Photos', 'show_highlighted' => 'Filter highlighted images', 'copy_highlighted_names' => 'Copy highlighted photo names to clipboard', + 'toggle_touch_select' => 'Toggle selection mode', + 'photo_actions' => 'Photo actions', 'no_results' => 'Nothing to see here', 'upload' => 'Upload photos', 'tabs' => [ diff --git a/lang/it/gallery.php b/lang/it/gallery.php index 1f7865be7dc..ba45ed94d99 100644 --- a/lang/it/gallery.php +++ b/lang/it/gallery.php @@ -140,6 +140,8 @@ 'header_photos' => 'Photos', 'show_highlighted' => 'Filter highlighted images', 'copy_highlighted_names' => 'Copy highlighted photo names to clipboard', + 'toggle_touch_select' => 'Toggle selection mode', + 'photo_actions' => 'Photo actions', 'no_results' => 'Nothing to see here', 'upload' => 'Upload photos', 'tabs' => [ diff --git a/lang/ja/gallery.php b/lang/ja/gallery.php index 7a2476c349f..fff72c47527 100644 --- a/lang/ja/gallery.php +++ b/lang/ja/gallery.php @@ -140,6 +140,8 @@ 'header_photos' => 'Photos', 'show_highlighted' => 'Filter highlighted images', 'copy_highlighted_names' => 'Copy highlighted photo names to clipboard', + 'toggle_touch_select' => 'Toggle selection mode', + 'photo_actions' => 'Photo actions', 'no_results' => 'Nothing to see here', 'upload' => 'Upload photos', 'tabs' => [ diff --git a/lang/nl/gallery.php b/lang/nl/gallery.php index 7f7860750df..3b47f9521f4 100644 --- a/lang/nl/gallery.php +++ b/lang/nl/gallery.php @@ -140,6 +140,8 @@ 'header_photos' => 'Foto’s', 'show_highlighted' => 'Filter highlighted images', 'copy_highlighted_names' => 'Copy highlighted photo names to clipboard', + 'toggle_touch_select' => 'Toggle selection mode', + 'photo_actions' => 'Photo actions', 'no_results' => 'Niets te zien hier', 'upload' => 'Foto’s uploaden', 'tabs' => [ diff --git a/lang/no/gallery.php b/lang/no/gallery.php index 85dbfc07376..ef236962e33 100644 --- a/lang/no/gallery.php +++ b/lang/no/gallery.php @@ -139,6 +139,8 @@ 'header_photos' => 'Bilder', 'show_highlighted' => 'Filter highlighted images', 'copy_highlighted_names' => 'Copy highlighted photo names to clipboard', + 'toggle_touch_select' => 'Toggle selection mode', + 'photo_actions' => 'Photo actions', 'no_results' => 'Ingenting å se her', 'upload' => 'Last opp bilder', 'tabs' => [ diff --git a/lang/pl/gallery.php b/lang/pl/gallery.php index aca2c6f26b4..8308d48627a 100644 --- a/lang/pl/gallery.php +++ b/lang/pl/gallery.php @@ -140,6 +140,8 @@ 'header_photos' => 'Zdjęcia', 'show_highlighted' => 'Filter highlighted images', 'copy_highlighted_names' => 'Copy highlighted photo names to clipboard', + 'toggle_touch_select' => 'Toggle selection mode', + 'photo_actions' => 'Photo actions', 'no_results' => 'Nie ma tu nic do oglądania', 'upload' => 'Przesyłanie zdjęć', 'tabs' => [ diff --git a/lang/pt/gallery.php b/lang/pt/gallery.php index 7868fb39e36..b4b201e2073 100644 --- a/lang/pt/gallery.php +++ b/lang/pt/gallery.php @@ -140,6 +140,8 @@ 'header_photos' => 'Photos', 'show_highlighted' => 'Filter highlighted images', 'copy_highlighted_names' => 'Copy highlighted photo names to clipboard', + 'toggle_touch_select' => 'Toggle selection mode', + 'photo_actions' => 'Photo actions', 'no_results' => 'Nothing to see here', 'upload' => 'Upload photos', 'tabs' => [ diff --git a/lang/ru/gallery.php b/lang/ru/gallery.php index fb74d262206..303c1b517b9 100644 --- a/lang/ru/gallery.php +++ b/lang/ru/gallery.php @@ -140,6 +140,8 @@ 'header_photos' => 'Фотографии', 'show_highlighted' => 'Filter highlighted images', 'copy_highlighted_names' => 'Copy highlighted photo names to clipboard', + 'toggle_touch_select' => 'Toggle selection mode', + 'photo_actions' => 'Photo actions', 'no_results' => 'Здесь ничего нет', 'upload' => 'Загрузить фотографии', 'tabs' => [ diff --git a/lang/sk/gallery.php b/lang/sk/gallery.php index 2bbf9fc1b25..2a2ba6bd91c 100644 --- a/lang/sk/gallery.php +++ b/lang/sk/gallery.php @@ -140,6 +140,8 @@ 'header_photos' => 'Photos', 'show_highlighted' => 'Filter highlighted images', 'copy_highlighted_names' => 'Copy highlighted photo names to clipboard', + 'toggle_touch_select' => 'Toggle selection mode', + 'photo_actions' => 'Photo actions', 'no_results' => 'Nothing to see here', 'upload' => 'Upload photos', 'tabs' => [ diff --git a/lang/sv/gallery.php b/lang/sv/gallery.php index 8c21468a330..5cc5f017748 100644 --- a/lang/sv/gallery.php +++ b/lang/sv/gallery.php @@ -140,6 +140,8 @@ 'header_photos' => 'Photos', 'show_highlighted' => 'Filter highlighted images', 'copy_highlighted_names' => 'Copy highlighted photo names to clipboard', + 'toggle_touch_select' => 'Toggle selection mode', + 'photo_actions' => 'Photo actions', 'no_results' => 'Nothing to see here', 'upload' => 'Upload photos', 'tabs' => [ diff --git a/lang/tr/gallery.php b/lang/tr/gallery.php index 2b169a0c35e..98d1ceb05b5 100644 --- a/lang/tr/gallery.php +++ b/lang/tr/gallery.php @@ -140,6 +140,8 @@ 'header_photos' => 'Photos', 'show_highlighted' => 'Filter highlighted images', 'copy_highlighted_names' => 'Copy highlighted photo names to clipboard', + 'toggle_touch_select' => 'Toggle selection mode', + 'photo_actions' => 'Photo actions', 'no_results' => 'Nothing to see here', 'upload' => 'Upload photos', 'tabs' => [ diff --git a/lang/vi/gallery.php b/lang/vi/gallery.php index 5ea7b5b549c..7cb900c4b63 100644 --- a/lang/vi/gallery.php +++ b/lang/vi/gallery.php @@ -140,6 +140,8 @@ 'header_photos' => 'Photos', 'show_highlighted' => 'Filter highlighted images', 'copy_highlighted_names' => 'Copy highlighted photo names to clipboard', + 'toggle_touch_select' => 'Toggle selection mode', + 'photo_actions' => 'Photo actions', 'no_results' => 'Nothing to see here', 'upload' => 'Upload photos', 'tabs' => [ diff --git a/lang/zh_CN/gallery.php b/lang/zh_CN/gallery.php index 6cc702ed31d..47bf1cda53f 100644 --- a/lang/zh_CN/gallery.php +++ b/lang/zh_CN/gallery.php @@ -140,6 +140,8 @@ 'header_photos' => '照片', 'show_highlighted' => 'Filter highlighted images', 'copy_highlighted_names' => 'Copy highlighted photo names to clipboard', + 'toggle_touch_select' => 'Toggle selection mode', + 'photo_actions' => 'Photo actions', 'no_results' => '这里什么都没有', 'upload' => '上传照片', 'tabs' => [ diff --git a/lang/zh_TW/gallery.php b/lang/zh_TW/gallery.php index 3cd8b8a8c98..edac1815be1 100644 --- a/lang/zh_TW/gallery.php +++ b/lang/zh_TW/gallery.php @@ -140,6 +140,8 @@ 'header_photos' => 'Photos', 'show_highlighted' => 'Filter highlighted images', 'copy_highlighted_names' => 'Copy highlighted photo names to clipboard', + 'toggle_touch_select' => 'Toggle selection mode', + 'photo_actions' => 'Photo actions', 'no_results' => 'Nothing to see here', 'upload' => 'Upload photos', 'tabs' => [ diff --git a/resources/js/components/gallery/albumModule/AlbumListItem.vue b/resources/js/components/gallery/albumModule/AlbumListItem.vue index 99fe257afe1..259bb9ff22f 100644 --- a/resources/js/components/gallery/albumModule/AlbumListItem.vue +++ b/resources/js/components/gallery/albumModule/AlbumListItem.vue @@ -1,13 +1,26 @@ @@ -25,6 +26,7 @@ const props = defineProps<{ const emits = defineEmits<{ clicked: [event: MouseEvent, id: string]; + selected: [event: MouseEvent, id: string]; contexted: [event: MouseEvent, id: string]; }>(); diff --git a/resources/js/components/gallery/albumModule/AlbumPanel.vue b/resources/js/components/gallery/albumModule/AlbumPanel.vue index 9be15d2c224..cc5b29647d7 100644 --- a/resources/js/components/gallery/albumModule/AlbumPanel.vue +++ b/resources/js/components/gallery/albumModule/AlbumPanel.vue @@ -9,6 +9,7 @@ @open-search="emits('openSearch')" @go-back="emits('goBack')" @show-selected="albumCallbacks.copyHighlighted()" + @open-context-menu="openContextMenuFromHeader" /> @@ -27,6 +28,7 @@ const props = defineProps<{ // bubble up. const emits = defineEmits<{ clicked: [event: MouseEvent, id: string]; + selected: [event: MouseEvent, id: string]; contexted: [event: MouseEvent, id: string]; }>(); diff --git a/resources/js/components/gallery/albumModule/PhotoThumbPanelList.vue b/resources/js/components/gallery/albumModule/PhotoThumbPanelList.vue index 698c1bea918..5818664b36b 100644 --- a/resources/js/components/gallery/albumModule/PhotoThumbPanelList.vue +++ b/resources/js/components/gallery/albumModule/PhotoThumbPanelList.vue @@ -38,6 +38,7 @@ import { useRoute } from "vue-router"; import { useLayoutStore } from "@/stores/LayoutState"; import { useAlbumStore } from "@/stores/AlbumState"; import { useCatalogStore } from "@/stores/CatalogState"; +import { useTogglablesStateStore } from "@/stores/ModalsState"; const props = defineProps<{ photos: App.Http.Resources.Models.PhotoResource[]; @@ -50,6 +51,9 @@ const lycheeStore = useLycheeStateStore(); const layoutStore = useLayoutStore(); const albumStore = useAlbumStore(); const catalogStore = useCatalogStore(); +const togglableStore = useTogglablesStateStore(); + +const { is_touch_select_mode } = storeToRefs(togglableStore); const isBuyable = computed(() => catalogStore.catalog?.album_purchasable !== undefined && catalogStore.catalog.album_purchasable !== null); const { is_timeline_left_border_visible } = storeToRefs(lycheeStore); @@ -69,7 +73,7 @@ const emits = defineEmits<{ }>(); function maySelect(id: string, e: MouseEvent) { - if (ctrlKeyState.value || metaKeyState.value || shiftKeyState.value) { + if (is_touch_select_mode.value || ctrlKeyState.value || metaKeyState.value || shiftKeyState.value) { emits("selected", id, e); return; } diff --git a/resources/js/components/gallery/albumModule/thumbs/AlbumThumb.vue b/resources/js/components/gallery/albumModule/thumbs/AlbumThumb.vue index c22ef4e4f06..9902aec261d 100644 --- a/resources/js/components/gallery/albumModule/thumbs/AlbumThumb.vue +++ b/resources/js/components/gallery/albumModule/thumbs/AlbumThumb.vue @@ -64,6 +64,18 @@ + +
+ +
+ +