Skip to content

Commit

Permalink
fix(web): confirm button is disabled if two dialogs are shown subsequ…
Browse files Browse the repository at this point in the history
…ently (immich-app#10440)
  • Loading branch information
alextran1502 committed Jun 17, 2024
1 parent 1b67ea2 commit e8994d9
Showing 1 changed file with 1 addition and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,7 @@
export let onCancel: () => void;
export let onConfirm: () => void;
let isConfirmButtonDisabled = false;
const handleConfirm = () => {
isConfirmButtonDisabled = true;
onConfirm();
};
</script>
Expand All @@ -37,7 +34,7 @@
{cancelText}
</Button>
{/if}
<Button color={confirmColor} fullwidth on:click={handleConfirm} disabled={disabled || isConfirmButtonDisabled}>
<Button color={confirmColor} fullwidth on:click={handleConfirm} {disabled}>
{confirmText}
</Button>
</svelte:fragment>
Expand Down

0 comments on commit e8994d9

Please sign in to comment.