From f24651f522e2076c7db816a50935ec8fec139303 Mon Sep 17 00:00:00 2001 From: "Thomas M. Edwards" Date: Sun, 8 Nov 2020 04:53:06 -0600 Subject: [PATCH] UPDATE: Improve `<>` behavior for decimals. See #79 . Not nearly a complete solution for decimals, but at least this keeps Firefox, and possibly others, from flagging decimal numbers as invalid. --- src/macros/macrolib.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/macros/macrolib.js b/src/macros/macrolib.js index 7383bd0..610e3fe 100644 --- a/src/macros/macrolib.js +++ b/src/macros/macrolib.js @@ -1680,6 +1680,11 @@ })) .appendTo(this.output); + // Set the step value for ``. + if (asNumber) { + el.step = 'any'; + } + // Set the variable and input element to the default value. State.setVar(varName, defaultValue); el.value = defaultValue;