From e7a864d84e14b6b84bce5623fa6216304b61b345 Mon Sep 17 00:00:00 2001 From: jean-emmanuel Date: Wed, 5 Nov 2025 09:13:48 +0100 Subject: [PATCH] input: numeric: select all content when focused (doesn't work on all browsers though) --- src/client/widgets/basics/input.mjs | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/client/widgets/basics/input.mjs b/src/client/widgets/basics/input.mjs index e22e0293..ffc89619 100644 --- a/src/client/widgets/basics/input.mjs +++ b/src/client/widgets/basics/input.mjs @@ -126,11 +126,9 @@ class Input extends Canvas { } - if (!this.getProp('numeric')) { - setTimeout(()=>{ - this.input.setSelectionRange(0, this.input.value.length) - }) - } + setTimeout(()=>{ + this.input.select() + }) }