Skip to content

Commit

Permalink
Add global element attributes/properties (#2423)
Browse files Browse the repository at this point in the history
Co-authored-by: Patrick Brosset <patrickbrosset@gmail.com>
Co-authored-by: Daniel D. Beck <daniel@ddbeck.com>
  • Loading branch information
3 people authored Dec 18, 2024
1 parent 92d6be7 commit 1862105
Show file tree
Hide file tree
Showing 32 changed files with 563 additions and 17 deletions.
9 changes: 9 additions & 0 deletions features/accesskey.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
name: Accesskey
description: The `accessKey` global HTML attribute gives a hint for generating a keyboard shortcut for the current element. The attribute value must consist of a single printable character.
spec: https://html.spec.whatwg.org/multipage/interaction.html#the-accesskey-attribute
status:
compute_from: api.HTMLElement.accessKey
compat_features:
- api.HTMLElement.accessKey
- api.HTMLElement.accessKeyLabel
- html.global_attributes.accesskey
50 changes: 50 additions & 0 deletions features/accesskey.yml.dist
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
# Generated from: accesskey.yml
# Do not edit this file by hand. Edit the source file instead!

status:
baseline: high
baseline_low_date: 2015-07-29
baseline_high_date: 2018-01-29
support:
chrome: "17"
chrome_android: "18"
edge: "12"
firefox: "5"
firefox_android: "5"
safari: "6"
safari_ios: "6"
compat_features:
# baseline: high
# baseline_low_date: 2015-07-29
# baseline_high_date: 2018-01-29
# support:
# chrome: "1"
# chrome_android: "18"
# edge: "12"
# firefox: "1"
# firefox_android: "4"
# safari: ≤4
# safari_ios: ≤3.2
- html.global_attributes.accesskey

# ⬇️ Same status as overall feature ⬇️
# baseline: high
# baseline_low_date: 2015-07-29
# baseline_high_date: 2018-01-29
# support:
# chrome: "17"
# chrome_android: "18"
# edge: "12"
# firefox: "5"
# firefox_android: "5"
# safari: "6"
# safari_ios: "6"
- api.HTMLElement.accessKey

# baseline: false
# support:
# firefox: "8"
# firefox_android: "8"
# safari: "14"
# safari_ios: "14"
- api.HTMLElement.accessKeyLabel
6 changes: 6 additions & 0 deletions features/autocapitalize.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
name: Autocapitalize
description: The `autocapitalize` global HTML attribute sets the virtual keyboard capitalization behavior for user input on an element, such as the first letter of sentences or all words.
spec: https://html.spec.whatwg.org/multipage/interaction.html#autocapitalization
compat_features:
- api.HTMLElement.autocapitalize
- html.global_attributes.autocapitalize
33 changes: 33 additions & 0 deletions features/autocapitalize.yml.dist
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# Generated from: autocapitalize.yml
# Do not edit this file by hand. Edit the source file instead!

status:
baseline: false
support:
chrome: "66"
chrome_android: "66"
edge: "79"
firefox: "111"
firefox_android: "111"
safari_ios: "10.3"
compat_features:
# baseline: false
# support:
# chrome: "43"
# chrome_android: "43"
# edge: "79"
# firefox: "111"
# firefox_android: "111"
# safari_ios: "5"
- html.global_attributes.autocapitalize

# ⬇️ Same status as overall feature ⬇️
# baseline: false
# support:
# chrome: "66"
# chrome_android: "66"
# edge: "79"
# firefox: "111"
# firefox_android: "111"
# safari_ios: "10.3"
- api.HTMLElement.autocapitalize
6 changes: 6 additions & 0 deletions features/autocorrect.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
name: Autocorrect
description: The `autocorrect` global HTML attribute controls whether to automatically correct spelling or punctuation errors for user input.
spec: https://html.spec.whatwg.org/multipage/interaction.html#autocorrection
compat_features:
- api.HTMLElement.autocorrect
- html.global_attributes.autocorrect
17 changes: 17 additions & 0 deletions features/autocorrect.yml.dist
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Generated from: autocorrect.yml
# Do not edit this file by hand. Edit the source file instead!

status:
baseline: false
support: {}
compat_features:
# baseline: false
# support:
# safari: "14.1"
# safari_ios: "14.5"
- api.HTMLElement.autocorrect

# ⬇️ Same status as overall feature ⬇️
# baseline: false
# support: {}
- html.global_attributes.autocorrect
7 changes: 7 additions & 0 deletions features/change-event.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
name: Change event
description: The `change` event for `<input>`, `<select>`, and `<textarea>` elements fires when the user modifies the element's value. Unlike the `input` event, the change event does not necessarily fire on every alteration to an element's value.
spec:
- https://html.spec.whatwg.org/multipage/indices.html#event-change
- https://html.spec.whatwg.org/multipage/webappapis.html#handler-onchange
compat_features:
- api.HTMLElement.change_event
17 changes: 17 additions & 0 deletions features/change-event.yml.dist
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# Generated from: change-event.yml
# Do not edit this file by hand. Edit the source file instead!

status:
baseline: high
baseline_low_date: 2015-07-29
baseline_high_date: 2018-01-29
support:
chrome: "1"
chrome_android: "18"
edge: "12"
firefox: "1"
firefox_android: "4"
safari: "3"
safari_ios: "2"
compat_features:
- api.HTMLElement.change_event
6 changes: 6 additions & 0 deletions features/contenteditable-plaintextonly.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
name: 'contenteditable="plaintext-only"'
description: The `contenteditable="plaintext-only"` global HTML attribute allows the user to edit the content of an element, but prevents rich-text formatting.
spec: https://html.spec.whatwg.org/multipage/interaction.html#attr-contenteditable-plaintextonly-state
compat_features:
- html.global_attributes.contenteditable.plaintext-only
- api.HTMLElement.contentEditable.plaintext-only
30 changes: 30 additions & 0 deletions features/contenteditable-plaintextonly.yml.dist
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Generated from: contenteditable-plaintextonly.yml
# Do not edit this file by hand. Edit the source file instead!

status:
baseline: false
support:
chrome: "51"
chrome_android: "51"
edge: ≤79
safari: ≤13.1
safari_ios: ≤13.4
compat_features:
# baseline: false
# support:
# chrome: "51"
# chrome_android: "51"
# edge: ≤79
# safari: "5.1"
# safari_ios: "5"
- api.HTMLElement.contentEditable.plaintext-only

# ⬇️ Same status as overall feature ⬇️
# baseline: false
# support:
# chrome: "51"
# chrome_android: "51"
# edge: ≤79
# safari: ≤13.1
# safari_ios: ≤13.4
- html.global_attributes.contenteditable.plaintext-only
9 changes: 9 additions & 0 deletions features/contenteditable.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
name: Contenteditable
description: The `contenteditable` global HTML attribute allows the user to edit the content of an element, such as inserting or deleting text.
spec: https://html.spec.whatwg.org/multipage/interaction.html#contenteditable
caniuse: contenteditable
compat_features:
- html.global_attributes.contenteditable
- api.HTMLElement.contentEditable
- api.HTMLElement.inputMode
- api.HTMLElement.isContentEditable
68 changes: 68 additions & 0 deletions features/contenteditable.yml.dist
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
# Generated from: contenteditable.yml
# Do not edit this file by hand. Edit the source file instead!

status:
baseline: high
baseline_low_date: 2021-12-07
baseline_high_date: 2024-06-07
support:
chrome: "66"
chrome_android: "66"
edge: "79"
firefox: "95"
firefox_android: "79"
safari: "12.1"
safari_ios: "12.2"
compat_features:
# baseline: high
# baseline_low_date: 2015-07-29
# baseline_high_date: 2018-01-29
# support:
# chrome: "1"
# chrome_android: "18"
# edge: "12"
# firefox: "3"
# firefox_android: "4"
# safari: "3"
# safari_ios: "1"
- api.HTMLElement.contentEditable

# baseline: high
# baseline_low_date: 2015-07-29
# baseline_high_date: 2018-01-29
# support:
# chrome: "1"
# chrome_android: "18"
# edge: "12"
# firefox: "3"
# firefox_android: "4"
# safari: ≤4
# safari_ios: ≤3.2
- html.global_attributes.contenteditable

# baseline: high
# baseline_low_date: 2015-07-29
# baseline_high_date: 2018-01-29
# support:
# chrome: "1"
# chrome_android: "18"
# edge: "12"
# firefox: "4"
# firefox_android: "4"
# safari: "3"
# safari_ios: "1"
- api.HTMLElement.isContentEditable

# ⬇️ Same status as overall feature ⬇️
# baseline: high
# baseline_low_date: 2021-12-07
# baseline_high_date: 2024-06-07
# support:
# chrome: "66"
# chrome_android: "66"
# edge: "79"
# firefox: "95"
# firefox_android: "79"
# safari: "12.1"
# safari_ios: "12.2"
- api.HTMLElement.inputMode
3 changes: 3 additions & 0 deletions features/csp.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ compat_features:
- api.CSPViolationReportBody.toJSON
- api.Document.securitypolicyviolation_event
- api.Element.securitypolicyviolation_event
- api.HTMLElement.nonce
- api.HTMLIFrameElement.csp
- api.SecurityPolicyViolationEvent
- api.SecurityPolicyViolationEvent.SecurityPolicyViolationEvent
Expand All @@ -45,6 +46,8 @@ compat_features:
- api.WorkerGlobalScope.securitypolicyviolation_event
- html.elements.iframe.csp
- html.elements.meta.http-equiv.content-security-policy
- html.global_attributes.nonce
- html.global_attributes.nonce.nonce_hiding
- http.headers.Content-Security-Policy
- http.headers.Content-Security-Policy-Report-Only
- http.headers.Content-Security-Policy.base-uri
Expand Down
35 changes: 35 additions & 0 deletions features/csp.yml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -232,6 +232,32 @@ compat_features:
# safari_ios: "15.4"
- http.headers.Content-Security-Policy.report-sample

# baseline: high
# baseline_low_date: 2022-03-14
# baseline_high_date: 2024-09-14
# support:
# chrome: "61"
# chrome_android: "61"
# edge: "79"
# firefox: "31"
# firefox_android: "31"
# safari: "15.4"
# safari_ios: "15.4"
- html.global_attributes.nonce

# baseline: high
# baseline_low_date: 2022-03-14
# baseline_high_date: 2024-09-14
# support:
# chrome: "61"
# chrome_android: "61"
# edge: "79"
# firefox: "75"
# firefox_android: "79"
# safari: "15.4"
# safari_ios: "15.4"
- api.HTMLElement.nonce

# baseline: high
# baseline_low_date: 2022-03-14
# baseline_high_date: 2024-09-14
Expand Down Expand Up @@ -328,6 +354,15 @@ compat_features:
# firefox_android: "63"
- api.SecurityPolicyViolationEvent.worker_support

# baseline: false
# support:
# chrome: "61"
# chrome_android: "61"
# edge: "79"
# firefox: "75"
# firefox_android: "79"
- html.global_attributes.nonce.nonce_hiding

# baseline: false
# support:
# chrome: "70"
Expand Down
1 change: 1 addition & 0 deletions features/details.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,5 +9,6 @@ compat_features:
- api.HTMLDetailsElement
- api.HTMLDetailsElement.open
- api.HTMLElement.toggle_event
- api.HTMLElement.toggle_event.details_elements
- html.elements.details
- html.elements.details.open
1 change: 1 addition & 0 deletions features/details.yml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -55,3 +55,4 @@ compat_features:
# safari: "10.1"
# safari_ios: "10.3"
- api.HTMLElement.toggle_event
- api.HTMLElement.toggle_event.details_elements
4 changes: 4 additions & 0 deletions features/dialog.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ description: The `<dialog>` HTML element represents a modal or non-modal dialog
spec: https://html.spec.whatwg.org/multipage/interactive-elements.html#the-dialog-element
group: html-elements
caniuse: dialog
status:
compute_from: html.elements.dialog
compat_features:
- api.HTMLDialogElement
- api.HTMLDialogElement.cancel_event
Expand All @@ -12,5 +14,7 @@ compat_features:
- api.HTMLDialogElement.returnValue
- api.HTMLDialogElement.show
- api.HTMLDialogElement.showModal
- api.HTMLElement.beforetoggle_event.dialog_elements
- api.HTMLElement.toggle_event.dialog_elements
- html.elements.dialog
- html.elements.dialog.open
19 changes: 19 additions & 0 deletions features/dialog.yml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,18 @@ status:
safari: "15.4"
safari_ios: "15.4"
compat_features:
# ⬇️ Same status as overall feature ⬇️
# baseline: high
# baseline_low_date: 2022-03-14
# baseline_high_date: 2024-09-14
# support:
# chrome: "37"
# chrome_android: "37"
# edge: "79"
# firefox: "98"
# firefox_android: "98"
# safari: "15.4"
# safari_ios: "15.4"
- api.HTMLDialogElement
- api.HTMLDialogElement.cancel_event
- api.HTMLDialogElement.close
Expand All @@ -24,3 +36,10 @@ compat_features:
- api.HTMLDialogElement.showModal
- html.elements.dialog
- html.elements.dialog.open

# baseline: false
# support:
# firefox: "133"
# firefox_android: "133"
- api.HTMLElement.beforetoggle_event.dialog_elements
- api.HTMLElement.toggle_event.dialog_elements
Loading

0 comments on commit 1862105

Please sign in to comment.