- {/* Payment options - hide when keyboard open */}
- {hasOptions && method.options && !isInputFocused && (
-
- {method.options.map((option) => (
+ {/* Payment options */}
+ {hasOptions && method.options && (
+
+ {method.options.map((opt) => (
))}
@@ -201,36 +175,27 @@ export default function TopUpModal({ method, onClose, initialAmountRubles }: Top
inputMode="decimal"
value={amount}
onChange={(e) => setAmount(e.target.value)}
- onFocus={() => setIsInputFocused(true)}
- onBlur={() => setTimeout(() => setIsInputFocused(false), 150)}
placeholder={`${formatAmount(minRubles, 0)} – ${formatAmount(maxRubles, 0)}`}
- step={inputStep}
- className="w-full h-14 px-4 pr-16 text-xl font-semibold bg-dark-800 border border-dark-700 rounded-xl text-dark-100 placeholder:text-dark-500 focus:outline-none focus:border-accent-500 focus:ring-1 focus:ring-accent-500"
+ className="w-full h-12 px-4 pr-12 text-lg font-semibold bg-dark-800 border border-dark-700 rounded-xl text-dark-100 placeholder:text-dark-500 focus:outline-none focus:border-accent-500"
autoComplete="off"
/>
-
+
{currencySymbol}
- {/* Quick amounts - always show, they help dismiss keyboard */}
+ {/* Quick amounts */}
{quickAmounts.length > 0 && (
-
+
{quickAmounts.map((a) => {
- const quickValue = getQuickAmountValue(a)
- const isSelected = amount === quickValue
+ const val = getQuickValue(a)
return (
)}
- {/* Error - hide when keyboard open */}
- {error && !isInputFocused && (
-
- {error}
-
+ {/* Error */}
+ {error && (
+
{error}
)}
- {/* Submit button - always visible */}
+ {/* Submit */}
-
- {/* Cancel - hide when keyboard open */}
- {!isInputFocused && (
-
- )}
-
- {/* Safe area for iPhone */}
-