mirror of
https://github.com/withastro/astro.git
synced 2024-12-30 22:03:56 -05:00
add checked
to htmlBooleanAttributes (#12311)
Co-authored-by: Emanuele Stoppa <my.burning@gmail.com>
This commit is contained in:
parent
c4726d7ba8
commit
bf2723e831
2 changed files with 6 additions and 1 deletions
5
.changeset/brown-rocks-ring.md
Normal file
5
.changeset/brown-rocks-ring.md
Normal file
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
'astro': patch
|
||||
---
|
||||
|
||||
Adds `checked` to the list of boolean attributes.
|
|
@ -7,7 +7,7 @@ import { HTMLString, markHTMLString } from '../escape.js';
|
|||
export const voidElementNames =
|
||||
/^(area|base|br|col|command|embed|hr|img|input|keygen|link|meta|param|source|track|wbr)$/i;
|
||||
const htmlBooleanAttributes =
|
||||
/^(?:allowfullscreen|async|autofocus|autoplay|controls|default|defer|disabled|disablepictureinpicture|disableremoteplayback|formnovalidate|hidden|loop|nomodule|novalidate|open|playsinline|readonly|required|reversed|scoped|seamless|selected|itemscope)$/i;
|
||||
/^(?:allowfullscreen|async|autofocus|autoplay|checked|controls|default|defer|disabled|disablepictureinpicture|disableremoteplayback|formnovalidate|hidden|loop|nomodule|novalidate|open|playsinline|readonly|required|reversed|scoped|seamless|selected|itemscope)$/i;
|
||||
const htmlEnumAttributes = /^(?:contenteditable|draggable|spellcheck|value)$/i;
|
||||
// Note: SVG is case-sensitive!
|
||||
const svgEnumAttributes = /^(?:autoReverse|externalResourcesRequired|focusable|preserveAlpha)$/i;
|
||||
|
|
Loading…
Reference in a new issue