From 642f0c5951f1108c9ee964d0f38d08da13d85fdd Mon Sep 17 00:00:00 2001 From: Patrick Mulligan Date: Wed, 25 Feb 2026 19:26:06 -0500 Subject: [PATCH] fix(machine): hide cancel after bills inserted, kiosk-only UI cleanup - Hide header cancel button after bills are in cash box - Add spinning hourglass to displayingQR waiting indicator - Hide keyboard-dependent UI in Electron kiosk mode: QR mode selector, manual payment options, copy buttons These remain available in browser (web-ui) mode. Co-Authored-By: Claude Opus 4.6 --- apps/machine/src/views/CashInView.vue | 36 +++++++++++++++++++++----- apps/machine/src/views/CashOutView.vue | 5 ++-- 2 files changed, 32 insertions(+), 9 deletions(-) diff --git a/apps/machine/src/views/CashInView.vue b/apps/machine/src/views/CashInView.vue index db3cefb..146c815 100644 --- a/apps/machine/src/views/CashInView.vue +++ b/apps/machine/src/views/CashInView.vue @@ -13,6 +13,19 @@ import QRCode from '@/components/QRCode.vue' const router = useRouter() const atmStore = useAtmStore() +const isElectron = typeof window !== 'undefined' && window.electronAPI !== undefined + +// Whether the header cancel button should be visible +// Hide after bills are inserted — state machine routes to confirmAbandon instead +const showCancelButton = computed(() => { + const state = atmStore.nestedState + const hasBills = (atmStore.context?.billsInserted.length ?? 0) > 0 + // Always show in insertingBills (before bills) and error (without bills) + if (state === 'insertingBills' || state === 'fetchingRate') return true + if (state === 'error' && !hasBills) return true + // Hide when bills are in the cash box + return false +}) // CLINK Debit: customer's npub/pubkey const pubkeyInput = ref('') @@ -190,7 +203,10 @@ const isProcessing = computed(() => atmStore.isPayingInvoice || atmStore.isReque
- + +

Buy Bitcoin

@@ -312,8 +328,8 @@ const isProcessing = computed(() => atmStore.isPayingInvoice || atmStore.isReque

- -
+ +

Scan with

- -
+ +
+ ⏳ +

Waiting for payment...

+
+ + +

{{ qrMode === 'unified' @@ -395,8 +417,8 @@ const isProcessing = computed(() => atmStore.isPayingInvoice || atmStore.isReque

- -
+ +
Alternative: Manual payment options diff --git a/apps/machine/src/views/CashOutView.vue b/apps/machine/src/views/CashOutView.vue index 62bed0a..cd84eae 100644 --- a/apps/machine/src/views/CashOutView.vue +++ b/apps/machine/src/views/CashOutView.vue @@ -12,6 +12,7 @@ import QRCode from '@/components/QRCode.vue' const router = useRouter() const atmStore = useAtmStore() +const isElectron = typeof window !== 'undefined' && window.electronAPI !== undefined // Copy invoice functionality const copyButtonText = ref('Copy Invoice') @@ -254,8 +255,8 @@ function formatFiat(cents: number): string {

Waiting for payment...

- -
+ +

{{ context.invoice.slice(0, 50) }}...