UX: Автоматическое выделение суммы для быстрой замены
При выборе способа оплаты сумма теперь автоматически выделяется, позволяя пользователю сразу начать вводить новое значение без необходимости вручную выделять текст. Улучшение скорости ввода для оператора POS. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -233,7 +233,10 @@ export class PaymentWidget {
|
|||||||
|
|
||||||
// Автофокус на поле суммы
|
// Автофокус на поле суммы
|
||||||
const amountInput = document.querySelector(`.payment-amount-input[data-index="${index}"]`);
|
const amountInput = document.querySelector(`.payment-amount-input[data-index="${index}"]`);
|
||||||
if (amountInput) amountInput.focus();
|
if (amountInput) {
|
||||||
|
amountInput.focus();
|
||||||
|
amountInput.select(); // Выделяем всю сумму для быстрой замены
|
||||||
|
}
|
||||||
|
|
||||||
// Если кошелек - ограничить сумму
|
// Если кошелек - ограничить сумму
|
||||||
if (option.dataset.code === 'account_balance' && this.customer) {
|
if (option.dataset.code === 'account_balance' && this.customer) {
|
||||||
|
|||||||
Reference in New Issue
Block a user