From 66c19eed1eced577ea43d6e14a88299c185fd0df Mon Sep 17 00:00:00 2001 From: Chris Mills Date: Fri, 26 Jan 2024 13:27:30 +0000 Subject: [PATCH] make number formatting consistent --- files/en-us/web/html/attributes/step/index.md | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/files/en-us/web/html/attributes/step/index.md b/files/en-us/web/html/attributes/step/index.md index 6441cafc49b9c60..16e8e4b76bd5523 100644 --- a/files/en-us/web/html/attributes/step/index.md +++ b/files/en-us/web/html/attributes/step/index.md @@ -80,16 +80,16 @@ If `any` is not explicitly set, valid values for the `number`, date/time input t ``` -If `step` is omitted, any integer is valid, but floats like 4.2 are not valid as `step` defaults to 1. For 4.2 to be valid: +If `step` is omitted, any integer is valid but floats like 4.2 are not valid as `step` defaults to 1. For 4.2 to be valid: - either `step` would have to be set to `any`, 0.1, or 0.2, -- or the `min` value would have to be a number ending in .2, such as `0.2`, `1.2`, or `5.2`. +- or the `min` value would have to be a number ending in .2, such as 0.2, 1.2, or -5.2. ## Examples ### `min` impact on step -The value of `min` defines valid values, even if the `step` attribute is not included. This is because `step` defaults to `1`. +The value of `min` defines valid values, even if the `step` attribute is not included. This is because `step` defaults to 1. In this example, we add a big red border around invalid inputs: @@ -99,13 +99,13 @@ input:invalid { } ``` -We then define an input with a minimum value of `1.2` and a step value of `2`: +We then define an input with a minimum value of 1.2 and a step value of 2: ```html ``` -Valid values include `1.2`, `3.2`, `5.2`, `7.2`, `9.2`, `11.2`, and so on. Only floats with an odd-numbered integer part and a decimal part of `.2` are valid. The number spinner, if present, generates valid float values of `1.2` and greater, in increments of `2`. +Valid values include 1.2, 3.2, 5.2, 7.2, 9.2, 11.2, and so on. Only floats with an odd-numbered integer part and a decimal part of .2 are valid. The number spinner, if present, generates valid float values of 1.2 and greater, in increments of 2. {{EmbedLiveSample("min_impact_on_step","100%",55)}}