mirror of
https://github.com/immich-app/immich.git
synced 2025-12-21 01:11:16 +03:00
fix(web): consistent modal escape behavior (#7677)
* fix(web): consistent modal escape behavior * make onClose optional
This commit is contained in:
@@ -59,8 +59,8 @@
|
||||
<ConfirmDialogue
|
||||
title="Remove from {album.albumName}"
|
||||
confirmText="Remove"
|
||||
on:confirm={removeFromAlbum}
|
||||
on:cancel={() => (isShowConfirmation = false)}
|
||||
onConfirm={removeFromAlbum}
|
||||
onClose={() => (isShowConfirmation = false)}
|
||||
>
|
||||
<svelte:fragment slot="prompt">
|
||||
<p>
|
||||
|
||||
@@ -53,7 +53,7 @@
|
||||
title="Remove Assets?"
|
||||
prompt="Are you sure you want to remove {getAssets().size} asset(s) from this shared link?"
|
||||
confirmText="Remove"
|
||||
on:confirm={() => handleRemove()}
|
||||
on:cancel={() => (removing = false)}
|
||||
onConfirm={() => handleRemove()}
|
||||
onClose={() => (removing = false)}
|
||||
/>
|
||||
{/if}
|
||||
|
||||
@@ -27,9 +27,8 @@
|
||||
<ConfirmDialogue
|
||||
title="Permanently Delete Asset{size > 1 ? 's' : ''}"
|
||||
confirmText="Delete"
|
||||
on:confirm={handleConfirm}
|
||||
on:cancel={() => dispatch('cancel')}
|
||||
on:escape={() => dispatch('cancel')}
|
||||
onConfirm={handleConfirm}
|
||||
onClose={() => dispatch('cancel')}
|
||||
>
|
||||
<svelte:fragment slot="prompt">
|
||||
<p>
|
||||
|
||||
Reference in New Issue
Block a user