Skip to content

Commit

Permalink
Remove a ton of repeated code using new dialog
Browse files Browse the repository at this point in the history
  • Loading branch information
scosman committed Jan 4, 2025
1 parent c0bbf00 commit 4c36cb9
Show file tree
Hide file tree
Showing 2 changed files with 134 additions and 215 deletions.
2 changes: 2 additions & 0 deletions app/web_ui/src/lib/ui/dialog.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
asyncAction?: () => Promise<boolean>
action?: () => boolean
isCancel?: boolean
disabled?: boolean
}
export let action_buttons: ActionButton[] = []
let action_running = false
Expand Down Expand Up @@ -91,6 +92,7 @@
{:else}
<button
class="btn btn-sm h-10 min-w-24 btn-secondary"
disabled={button.disabled}
on:click={() => perform_button_action(button)}
>
{button.label || "Confirm"}
Expand Down
Loading

0 comments on commit 4c36cb9

Please sign in to comment.