opentui: fix: Dialog button clicks leak through (#3589)

This commit is contained in:
Haris Gušić 2025-10-31 04:50:55 +01:00 committed by GitHub
parent 4acd7d83f0
commit 8033b4e929
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 2 additions and 3 deletions

View file

@ -8,7 +8,6 @@ import {
createEffect,
untrack,
ErrorBoundary,
createMemo,
createSignal,
} from "solid-js"
import { Installation } from "@/installation"

View file

@ -33,7 +33,7 @@ export function DialogAlert(props: DialogAlertProps) {
paddingLeft={3}
paddingRight={3}
backgroundColor={theme.primary}
onMouseDown={() => {
onMouseUp={() => {
props.onConfirm?.()
dialog.clear()
}}

View file

@ -47,7 +47,7 @@ export function DialogConfirm(props: DialogConfirmProps) {
paddingLeft={1}
paddingRight={1}
backgroundColor={key === store.active ? theme.primary : undefined}
onMouseDown={() => {
onMouseUp={(evt) => {
if (key === "confirm") props.onConfirm?.()
if (key === "cancel") props.onCancel?.()
dialog.clear()