Fix sats output

This commit is contained in:
2026-01-30 02:57:30 +00:00
parent 03a86ca056
commit aa6bce6481
2 changed files with 25 additions and 6 deletions

BIN
Electrum.sqlite-journal Normal file

Binary file not shown.

View File

@@ -250,6 +250,13 @@ export function ActionWizardScreen(): React.ReactElement {
// Handle step-specific logic
if (stepType === 'variables') {
// Validate that all required variables have values
const emptyVars = variables.filter(v => !v.value || v.value.trim() === '');
if (emptyVars.length > 0) {
showError(`Please enter values for: ${emptyVars.map(v => v.name).join(', ')}`);
return;
}
// Create invitation and add variables
await createInvitationWithVariables();
return;
@@ -476,18 +483,30 @@ export function ActionWizardScreen(): React.ReactElement {
});
}, []);
// Check if TextInput should have exclusive focus (variables step with content focus)
const textInputHasFocus = currentStepData?.type === 'variables' && focusArea === 'content';
// Handle keyboard navigation
useInput((input, key) => {
// When TextInput has focus, only handle Tab to navigate away
if (textInputHasFocus) {
if (key.tab) {
// Move to next variable or to buttons
if (focusedInput < variables.length - 1) {
setFocusedInput(prev => prev + 1);
} else {
setFocusArea('buttons');
setFocusedButton('next');
}
}
// Let TextInput handle all other input
return;
}
// Tab to switch between content and buttons
if (key.tab) {
if (focusArea === 'content') {
// Handle tab based on current step type
if (currentStepData?.type === 'variables' && variables.length > 0) {
if (focusedInput < variables.length - 1) {
setFocusedInput(prev => prev + 1);
return;
}
}
if (currentStepData?.type === 'inputs' && availableUtxos.length > 0) {
if (selectedUtxoIndex < availableUtxos.length - 1) {
setSelectedUtxoIndex(prev => prev + 1);