mirror of
https://github.com/immich-app/immich.git
synced 2026-02-02 10:14:50 -08:00
Compare commits
1 Commits
fix-migrat
...
fix/disabl
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
049aeabcc1 |
@@ -7,7 +7,6 @@
|
|||||||
import AddToStackAction from '$lib/components/asset-viewer/actions/add-to-stack-action.svelte';
|
import AddToStackAction from '$lib/components/asset-viewer/actions/add-to-stack-action.svelte';
|
||||||
import ArchiveAction from '$lib/components/asset-viewer/actions/archive-action.svelte';
|
import ArchiveAction from '$lib/components/asset-viewer/actions/archive-action.svelte';
|
||||||
import DeleteAction from '$lib/components/asset-viewer/actions/delete-action.svelte';
|
import DeleteAction from '$lib/components/asset-viewer/actions/delete-action.svelte';
|
||||||
import EditAction from '$lib/components/asset-viewer/actions/edit-action.svelte';
|
|
||||||
import KeepThisDeleteOthersAction from '$lib/components/asset-viewer/actions/keep-this-delete-others.svelte';
|
import KeepThisDeleteOthersAction from '$lib/components/asset-viewer/actions/keep-this-delete-others.svelte';
|
||||||
import RatingAction from '$lib/components/asset-viewer/actions/rating-action.svelte';
|
import RatingAction from '$lib/components/asset-viewer/actions/rating-action.svelte';
|
||||||
import RemoveAssetFromStack from '$lib/components/asset-viewer/actions/remove-asset-from-stack.svelte';
|
import RemoveAssetFromStack from '$lib/components/asset-viewer/actions/remove-asset-from-stack.svelte';
|
||||||
@@ -20,7 +19,6 @@
|
|||||||
import UnstackAction from '$lib/components/asset-viewer/actions/unstack-action.svelte';
|
import UnstackAction from '$lib/components/asset-viewer/actions/unstack-action.svelte';
|
||||||
import ButtonContextMenu from '$lib/components/shared-components/context-menu/button-context-menu.svelte';
|
import ButtonContextMenu from '$lib/components/shared-components/context-menu/button-context-menu.svelte';
|
||||||
import MenuOption from '$lib/components/shared-components/context-menu/menu-option.svelte';
|
import MenuOption from '$lib/components/shared-components/context-menu/menu-option.svelte';
|
||||||
import { ProjectionType } from '$lib/constants';
|
|
||||||
import { featureFlagsManager } from '$lib/managers/feature-flags-manager.svelte';
|
import { featureFlagsManager } from '$lib/managers/feature-flags-manager.svelte';
|
||||||
import { Route } from '$lib/route';
|
import { Route } from '$lib/route';
|
||||||
import { getGlobalActions } from '$lib/services/app.service';
|
import { getGlobalActions } from '$lib/services/app.service';
|
||||||
@@ -73,7 +71,7 @@
|
|||||||
onUndoDelete?: OnUndoDelete;
|
onUndoDelete?: OnUndoDelete;
|
||||||
onRunJob: (name: AssetJobName) => void;
|
onRunJob: (name: AssetJobName) => void;
|
||||||
onPlaySlideshow: () => void;
|
onPlaySlideshow: () => void;
|
||||||
onEdit: () => void;
|
// onEdit: () => void;
|
||||||
onClose?: () => void;
|
onClose?: () => void;
|
||||||
playOriginalVideo: boolean;
|
playOriginalVideo: boolean;
|
||||||
setPlayOriginalVideo: (value: boolean) => void;
|
setPlayOriginalVideo: (value: boolean) => void;
|
||||||
@@ -93,7 +91,7 @@
|
|||||||
onRunJob,
|
onRunJob,
|
||||||
onPlaySlideshow,
|
onPlaySlideshow,
|
||||||
onClose,
|
onClose,
|
||||||
onEdit,
|
// onEdit,
|
||||||
playOriginalVideo = false,
|
playOriginalVideo = false,
|
||||||
setPlayOriginalVideo,
|
setPlayOriginalVideo,
|
||||||
}: Props = $props();
|
}: Props = $props();
|
||||||
@@ -128,17 +126,17 @@
|
|||||||
const sharedLink = getSharedLink();
|
const sharedLink = getSharedLink();
|
||||||
|
|
||||||
// TODO: Enable when edits are ready for release
|
// TODO: Enable when edits are ready for release
|
||||||
let showEditorButton = $derived(
|
// let showEditorButton = $derived(
|
||||||
isOwner &&
|
// isOwner &&
|
||||||
asset.type === AssetTypeEnum.Image &&
|
// asset.type === AssetTypeEnum.Image &&
|
||||||
!(
|
// !(
|
||||||
asset.exifInfo?.projectionType === ProjectionType.EQUIRECTANGULAR ||
|
// asset.exifInfo?.projectionType === ProjectionType.EQUIRECTANGULAR ||
|
||||||
(asset.originalPath && asset.originalPath.toLowerCase().endsWith('.insp'))
|
// (asset.originalPath && asset.originalPath.toLowerCase().endsWith('.insp'))
|
||||||
) &&
|
// ) &&
|
||||||
!(asset.originalPath && asset.originalPath.toLowerCase().endsWith('.gif')) &&
|
// !(asset.originalPath && asset.originalPath.toLowerCase().endsWith('.gif')) &&
|
||||||
!(asset.originalPath && asset.originalPath.toLowerCase().endsWith('.svg')) &&
|
// !(asset.originalPath && asset.originalPath.toLowerCase().endsWith('.svg')) &&
|
||||||
!asset.livePhotoVideoId,
|
// !asset.livePhotoVideoId,
|
||||||
);
|
// );
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<CommandPaletteDefaultProvider
|
<CommandPaletteDefaultProvider
|
||||||
@@ -191,9 +189,9 @@
|
|||||||
<RatingAction {asset} {onAction} />
|
<RatingAction {asset} {onAction} />
|
||||||
{/if}
|
{/if}
|
||||||
|
|
||||||
{#if showEditorButton}
|
<!-- {#if showEditorButton}
|
||||||
<EditAction onAction={onEdit} />
|
<EditAction onAction={onEdit} />
|
||||||
{/if}
|
{/if} -->
|
||||||
|
|
||||||
{#if isOwner}
|
{#if isOwner}
|
||||||
<DeleteAction {asset} {onAction} {preAction} {onUndoDelete} />
|
<DeleteAction {asset} {onAction} {preAction} {onUndoDelete} />
|
||||||
|
|||||||
@@ -254,12 +254,12 @@
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
const showEditor = () => {
|
// const showEditor = () => {
|
||||||
if (assetViewerManager.isShowActivityPanel) {
|
// if (assetViewerManager.isShowActivityPanel) {
|
||||||
assetViewerManager.isShowActivityPanel = false;
|
// assetViewerManager.isShowActivityPanel = false;
|
||||||
}
|
// }
|
||||||
isShowEditor = !isShowEditor;
|
// isShowEditor = !isShowEditor;
|
||||||
};
|
// };
|
||||||
|
|
||||||
const handleRunJob = async (name: AssetJobName) => {
|
const handleRunJob = async (name: AssetJobName) => {
|
||||||
try {
|
try {
|
||||||
@@ -466,7 +466,6 @@
|
|||||||
preAction={handlePreAction}
|
preAction={handlePreAction}
|
||||||
onAction={handleAction}
|
onAction={handleAction}
|
||||||
{onUndoDelete}
|
{onUndoDelete}
|
||||||
onEdit={showEditor}
|
|
||||||
onRunJob={handleRunJob}
|
onRunJob={handleRunJob}
|
||||||
onPlaySlideshow={() => ($slideshowState = SlideshowState.PlaySlideshow)}
|
onPlaySlideshow={() => ($slideshowState = SlideshowState.PlaySlideshow)}
|
||||||
onClose={onClose ? () => onClose(asset) : undefined}
|
onClose={onClose ? () => onClose(asset) : undefined}
|
||||||
|
|||||||
Reference in New Issue
Block a user