From b493063e407013febeffaf53e80782cf4b350c77 Mon Sep 17 00:00:00 2001 From: ralf Date: Thu, 13 Jun 2024 15:29:07 +0200 Subject: [PATCH] fix Et2Number shows scroll-buttons if disabled and allows to in/decrement value --- api/js/etemplate/Et2Textbox/Et2Number.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/api/js/etemplate/Et2Textbox/Et2Number.ts b/api/js/etemplate/Et2Textbox/Et2Number.ts index 4742dff8e5..138928f290 100644 --- a/api/js/etemplate/Et2Textbox/Et2Number.ts +++ b/api/js/etemplate/Et2Textbox/Et2Number.ts @@ -184,6 +184,7 @@ export class Et2Number extends Et2Textbox private handleScroll(e) { + if (this.disabled) return; const old_value = this.value; let min = parseFloat(this.min ?? Number.MIN_SAFE_INTEGER); if(Number.isNaN(min)) @@ -208,7 +209,7 @@ export class Et2Number extends Et2Textbox return ''; } - return html` + return this.disabled ? '' : html` `;