mirror of
https://github.com/immich-app/immich.git
synced 2025-12-22 01:11:20 +03:00
fix(web): reset select all button state on escape press (#13600)
* factor out cancel multiselect state logic to utils * use cancel multiselct helper in album page * use cancel multiselct helper in album-viewer component * use cancel multiselct helper in asset-grid component * remove unused to fix lint
This commit is contained in:
@@ -6,7 +6,7 @@
|
||||
import type { AlbumResponseDto, SharedLinkResponseDto, UserResponseDto } from '@immich/sdk';
|
||||
import { createAssetInteractionStore } from '$lib/stores/asset-interaction.store';
|
||||
import { AssetStore } from '$lib/stores/assets.store';
|
||||
import { downloadAlbum } from '$lib/utils/asset-utils';
|
||||
import { cancelMultiselect, downloadAlbum } from '$lib/utils/asset-utils';
|
||||
import CircleIconButton from '../elements/buttons/circle-icon-button.svelte';
|
||||
import DownloadAction from '../photos-page/actions/download-action.svelte';
|
||||
import AssetGrid from '../photos-page/asset-grid.svelte';
|
||||
@@ -49,7 +49,7 @@
|
||||
shortcut: { key: 'Escape' },
|
||||
onShortcut: () => {
|
||||
if (!$showAssetViewer && $isMultiSelectState) {
|
||||
assetInteractionStore.clearMultiselect();
|
||||
cancelMultiselect(assetInteractionStore);
|
||||
}
|
||||
},
|
||||
}}
|
||||
|
||||
Reference in New Issue
Block a user