Inputs of type number are being flagged as invalid if they contain decimals

Steps to reproduce

  1. Create any input anywhere in obsidian of type number
  2. Create a CSS rule to target inputs of type number with the invalid attribute:
input[type="number"]:invalid {
    border: 1px solid red;
  1. Type any decimal number in the input, for example 1.1 and see the red border appearing. Any other number, like 11 does not trigger this state

Did you follow the troubleshooting guide? [Y/N]

This happens in the sandbox vault too

Expected result

Decimals should not be flagged as invalid

Actual result

the :invalid attribute is added


Obsidian version: v1.5.8
Installer version: v1.5.3
Operating system: Darwin Kernel Version 22.5.0: Mon Apr 24 20:53:19 PDT 2023; root:xnu-8796.121.2~5/RELEASE_ARM64_T6020 22.5.0
Login status: not logged in
Insider build toggle: off
Live preview: on
Base theme: adapt to system
Community theme: none
Snippets enabled: 0
Restricted mode: on


Ok, this seems to be standard HTML behaviour, my bad: