From e1f311166f7a892d752f5f1c0231994206aaeed6 Mon Sep 17 00:00:00 2001
From: Keith Cirkel onchange
onclick
onclose
oncommand
oncontextlost
oncontextmenu
oncontextrestored
command
commandfor
disabled
form
formaction
Constraint validation: If the type
attribute is in the Reset Button state or the
Button state, the element is barred from
constraint validation.
If specified, the commandfor
attribute value must be the ID of an element in the same tree as the button with the commandfor
attribute.
The command
+ attribute is an enumerated attribute with the following keywords and states:
Keyword + | State + | Brief description + |
---|---|---|
toggle-popover
+ | Toggle popover + | Shows or hides the targeted popover element.
+ |
show-popover
+ | Show popover + | Shows the targeted popover element.
+ |
hide-popover
+ | Hide popover + | Hides the targeted popover element.
+ |
close
+ | Close + | Closes the targeted dialog element.
+ |
show-modal
+ | Show modal + | Opens the targeted dialog element as modal.
+ |
The attribute's missing value default and invalid value default are both the unknown state.
+ +A valid custom command is a string whose first two code points are the U+002D + HYPHEN-MINUS character.
+ +A button
element element's activation behavior given
event is:
If element's node document is not fully active, then return.
If element has a form owner and element's commandfor
or command
attributes are present,
+ and the element's type
attribute is not in
+ the button
state, then return.
If element has a form owner then switch on element's type
attribute's state, then:
Run the popover target attribute activation behavior given element and event's target.
Let invokee be the result of running element's get the commandfor
associated
+ element.
If invokee is not null, then:
+ +If element has a form owner and element's type
attribute is not in the button
state, then return.
Let command be element's command
attribute.
Let isCustom be true if the command attribute is in the + unknown state, and command's + value is a valid custom command, and false otherwise.
If the command attribute is in the unknown state and isCustom is false, + then return.
Let isPopover be true if invokee's popover attribute is not in the no popover state, and false otherwise.
If isPopover is false and isCustom is false, then:
+ +Assert: invokee's + namespace is the HTML namespace.
If this standard does not define is valid invoker command steps for + invokee's local name, then + return.
+ +Otherwise, if the result of running invokee's corresponding is valid + invoker command steps given command is not true, then return.
Let continue be the result of firing an
+ event named command
at invokee, using
+ CommandEvent
, with its command
+ attribute initialized to command's value, its source
attribute initialized to element,
+ and its cancelable
and composed
attributes initialized to true.
If continue is false, then return.
If isCustom is true, then return.
Let shouldShowPopover be false.
Let shouldHidePopover be false.
If command is in the hidepopover state, then:
+ +If invokee's popover visibility state is showing, then set shouldHidePopover to + true.
Otherwise return.
If command is in the showpopover state, then:
+ +If invokee's popover visibility state is hidden, then set shouldShowPopover to + true.
Otherwise return.
If shouldShowPopover is true and the result of running + check popover validity given invokee, false, false, and null is true, + then:
+ +Assert: shouldHidePopover is false.
Assert: isPopover is true.
Run the show popover given invokee, false, and + element.
Otherwise, if shouldHidePopover is true and the result of running + check popover validity given invokee, true, false, and null is true, + then:
+ +Assert: shouldShowPopover is false.
Assert: isPopover is true.
Run the hide popover algorithm given invokee, true, true, and + false.
Otherwise, if this standard defines invoker command steps for + invokee's local name, then:
+ +Assert: shouldShowPopover is false and + shouldHidePopover is false.
Run the corresponding invoker command steps given invokee, + element and command.
Otherwise, run the popover target attribute activation behavior given + element.
An HTML element can have specific + is valid invoker command steps and invoker command steps defined for the + element's local name.
+The form
attribute is used to explicitly associate the
button
element with its form owner. The name
attribute represents the element's name. The disabled
attribute is used to make the control non-interactive and
- to prevent its value from being submitted. The formaction
,
- formenctype
, disabled
attribute is used to make the control non-interactive
+ and to prevent its value from being submitted. The formaction
, formenctype
, formmethod
, formnovalidate
, and formtarget
attributes are attributes for form
- submission.
The formnovalidate
attribute can be
used to make submit buttons that do not trigger the constraint validation.
A button (and its value) is only included in the form submission if the button itself was used to initiate the form submission.
-The commandForElement
IDL attribute must
+ reflect the content attribute of the same name.
The command
IDL attribute must reflect the
+ content attribute of the same name.
The value
IDL attribute must reflect the content attribute of the same name.
The following buttons use commandfor to open and close a popover box when activated:
+<button type=button
+ commandfor="the-popover"
+ command="toggle-popover">
+ Show menu
+</button>
+<div popover
+ id="the-popover">
+ <button commandfor="the-popover"
+ command="hide-popover">
+ Hide menu
+ </button>
+</div>
+
+ The following buttons use commandfor with a custom command on an element, demonstrating how + one could utilise custom commands for unspecified behavior:
+ +<button type=button
+ commandfor="the-image"
+ command="--rotate-left">
+ Rotate Left
+</button>
+<button type=button
+ commandfor="the-image"
+ command="--rotate-right">
+ Rotate Right
+</button>
+<img id="the-image"
+ src="photo.jpg">
+<script>
+ const image = document.getElementById("the-image");
+ image.addEventListener("command", (event) => {
+ if ( event.command == "--rotate-left" ) {
+ event.target.style.rotate = "-90deg"
+ } else if ( event.command == "--rotate-right" ) {
+ event.target.style.rotate = "90deg"
+ }
+ });
+</script>
+
+ select
elementIf this has an open
attribute and the
- is modal flag of this is true, then return.
Show this as modal.
If this has an open
attribute, then
- throw an "InvalidStateError
" DOMException
.
When a dialog
element subject is to be shown as modal, run these steps:
If this's node document is not fully active, then +
If subject has an open
attribute and
+ the is modal flag of subject is true, then return.
If subject has an open
attribute, then
throw an "InvalidStateError
" DOMException
.
If this is not connected, then throw an +
If subject's node document is not fully active,
+ then throw an "InvalidStateError
" DOMException
.
If subject is not connected, then throw an
"InvalidStateError
" DOMException
.
If this is in the popover showing
- state, then throw an "InvalidStateError
"
- DOMException
.
If subject is in the popover showing state, then throw an
+ "InvalidStateError
" DOMException
.
If the result of firing an event named beforetoggle
, using ToggleEvent
, with the cancelable
attribute initialized to true, the oldState
attribute initialized to "closed
", and the newState
- attribute initialized to "open
" at this is false, then
+ attribute initialized to "open
" at subject is false, then
return.
If this has an open
attribute,
+
If subject has an open
attribute,
then return.
If this is not connected, then return.
If subject is not connected, then return.
If this is in the popover showing - state, then return.
If subject is in the popover showing state, then return.
Queue a dialog toggle event task given subject, "closed
", and "open
".
Add an open
attribute to this, whose
+
Add an open
attribute to subject, whose
value is the empty string.
Set the is modal flag of this to true.
Set the is modal flag of subject to true.
Let this's node document be blocked by the modal dialog this.
+Let subject's node document be blocked by the modal dialog subject.
This will cause the focused area of the document to become inert (unless that currently focused area is a @@ -61913,41 +62170,41 @@ interface HTMLDialogElement : HTMLElement { focus.
If this's node document's top layer does not - already contain this, then add an element - to the top layer given this.
If subject's node document's top layer does not + already contain subject, then add an element + to the top layer given subject.
Set this's close watcher to the +
Set subject's close watcher to the result of establishing a close watcher given - this's relevant global object, with:
+ subject's relevant global object, with:cancelAction given
canPreventClose being to return the result of firing an event named cancel
at this, with the cancel
at subject, with the cancelable
attribute initialized to
canPreventClose.
closeAction being to close the - dialog given this and null.
Set this's previously focused element to the +
Set subject's previously focused element to the focused element.
Let hideUntil be the result of running topmost popover ancestor - given this, null, and false.
If hideUntil is null, then set hideUntil to this's +
If hideUntil is null, then set hideUntil to subject's node document.
Run hide all popovers until given hideUntil, false, and true.
Run the dialog focusing steps given this.
Run the dialog focusing steps given subject.
The dialog focusing steps, given a dialog
element subject,
@@ -61989,6 +62246,78 @@ interface HTMLDialogElement : HTMLElement {
Set topDocument's autofocus processed flag to true.
The is valid invoker command steps, given a dialog
element
+ subject and command, are:
If command is in the close state, then return true.
If command is in the show modal state, then return true.
+Return false.
The invoker command steps, given a dialog
element
+ invokee, invoker, and command, are:
If invokee is in the popover showing state, then return.
If command is in the close state, then:
+ +If invokee has an open
attribute, then:
Let value be invoker's value
Close the dialog invokee with value.
If command is in the show modal state, then:
+ +If invokee does not have an open
+ attribute, then show modal dialog invokee.
The following buttons use commandfor to open and close a "confirm" dialog as modal when + activated:
+ +<button type=button
+ commandfor="the-dialog"
+ command="show-modal">
+ Delete
+</button>
+<dialog id="the-dialog">
+ <form action="/delete" method="POST">
+ <button type="submit">
+ Delete
+ </button>
+ <button commandfor="the-dialog"
+ command="close">
+ Cancel
+ </button>
+ </form>
+</dialog>
+
+ The dialog
HTML element removing steps, given removedNode
and oldParent, are:
If removedNode's node document's top layer contains removedNode, then remove an element from - the top layer immediately given removedNode.
Set the is modal flag of removedNode to false.
Close the dialog this with returnValue.
When a dialog
element subject is to be closed, with null or a string result, run these steps:
When a dialog
element subject is to be closed, with null or a string result, run these
+ steps:
If subject does not have an open
@@ -62044,11 +62375,12 @@ interface HTMLDialogElement : HTMLElement {
Remove subject's open
attribute.
If the is modal flag of subject is true, then request an - element to be removed from the top layer given subject.
If the is modal flag of subject is true, then + request an element to be removed from the top layer given subject.
+Let wasModal be the value of subject's is - modal flag.
Let wasModal be the value of subject's + is modal flag.
Set the is modal flag of subject to false.
Queue an element task on the user interaction task source given the - subject element to fire an event named +
Queue an element task on the user interaction task source given
+ the subject element to fire an event named
close
at subject.
If subject's close watcher is not null, - then:
+If subject's close watcher is not + null, then:
Destroy subject's ToggleEventInit : EventInit {
the Returns what action the element can take. Returns the The The oldState
attribute.
+ The
+
+ CommandEvent
interface
+
+ [Exposed=Window]
+interface CommandEvent : Event {
+ constructor(DOMString type, optional CommandEventInit eventInitDict = {});
+ readonly attribute Element? source;
+ readonly attribute DOMString action;
+};
+
+dictionary CommandEventInit : EventInit {
+ Element? source = null;
+ DOMString action = "auto";
+};
+
+
+ event.command
event.source
Element
that was interacted with in order to cause this event.command
attribute must return the value it as
+ initialized to.source
getter steps are to
+ return the result of retargeting source
against this's currentTarget
.Focus
@@ -86550,7 +86921,6 @@ dictionary DragEventInit : MouseEventInit {
onchange
change
onclick
click
onclose
close
+ oncommand
command
oncontextlost
contextlost
oncontextmenu
contextmenu
oncontextrestored
contextrestored
@@ -113555,6 +113926,7 @@ typedef OnBeforeUnloadEventHandlerNonNull? OnBeforeUnl
attribute EventHandler onchange;
attribute EventHandler onclick;
attribute EventHandler onclose;
+ attribute EventHandler oncommand;
attribute EventHandler oncontextlost;
attribute EventHandler oncontextmenu;
attribute EventHandler oncontextrestored;
@@ -142509,6 +142881,22 @@ interface External {
script
command
+ button
+ toggle-popover
";
+ "show-popover
";
+ "hide-popover
";
+ "close
";
+ "show-modal
";
+ a valid custom command;
+ the empty string
+ commandfor
+ button
+ is
close
event handler
oncommand
+ command
event handler
+ oncontextlost
CloseWatcher
, dialog
elements, MessagePort
CloseWatcher
objects or dialog
elements when they are closed via a close request or via web developer code, or at MessagePort
objects when disentangled
+ command
+ CommandEvent
+ commandfor
attribute.
+
connect
MessageEvent
From 672183fba35f57a374a1e5e3984c51487848c8d9 Mon Sep 17 00:00:00 2001
From: Keith Cirkel If element has a form owner and element's commandfor
or command
attributes are present,
- and the element's type
attribute is not in
- the button
state, then return.
command
attributes are present,
+ and the element's type
attribute is not in
+ the button
state, then return.
If element has a form owner then switch on element's Let isCustom be true if the command attribute is in the
unknown state, and command's
- value is a valid custom command, and false otherwise.
Date: Fri, 8 Nov 2024 11:07:09 +0000
Subject: [PATCH 03/73] s/and false otherwise/; otherwise false
---
source | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/source b/source
index 7da9098fcd3..6381569a166 100644
--- a/source
+++ b/source
@@ -53592,7 +53592,7 @@ interface HTMLButtonElement : HTMLElement {
If the command attribute is in the unknown state and isCustom is false, @@ -53600,7 +53600,7 @@ interface HTMLButtonElement : HTMLElement {
Let isPopover be true if invokee's popover attribute is not in the no popover state, and false otherwise.
If isPopover is false and isCustom is false, then:
From a76843c7b78f3f03813299a29a6af9d15f7f245d Mon Sep 17 00:00:00 2001 From: Keith CirkelLet isCustom be true if the command attribute is in the - unknown state, and command's - value is a valid custom command; otherwise false.
If the command attribute is in the unknown state and isCustom is false,
From f65b298bca4035296e8d02367fa2deff96e936dc Mon Sep 17 00:00:00 2001
From: Keith Cirkel
If the command attribute is in the unknown state and isCustom is false, + data-x="attr-button-command-unknown">unknown state and isCustom is false, then return.
Let isPopover be true if invokee's popover attribute is not in the no popover state; otherwise false.
If isPopover is false and isCustom is false, then:
@@ -53636,10 +53636,10 @@ interface HTMLButtonElement : HTMLElement {If command is in the hidepopover state, then:
+ data-x="attr-button-command-hide-popover-state">hidepopover state, then:If invokee's popover visibility state is If invokee's popover visibility state is showing, then set shouldHidePopover to
true.
If command is in the showpopover state, then:
+ data-x="attr-button-command-show-popover-state">showpopover state, then:If invokee's popover visibility state is If invokee's popover visibility state is hidden, then set shouldShowPopover to
true.
If command is in the close state, then return true.
If command is in the show modal state, then return true.
+ data-x="attr-button-command-show-modal-state">show modal state, then return true.Return false.
If invokee is in the popover showing state, then return.
If command is in the close state, then:
+ data-x="attr-button-command-close-state">close state, then:If invokee has an If command is in the show modal state, then:HTMLDialogElement : HTMLElement {
If invokee does not have an If command is in the close state, then: If invokee has an Let value be invoker's HTMLDialogElement : HTMLElement {
If command is in the show modal state, then: If invokee does not have an The The The The The The following buttons use commandfor to open and close a popover box when activated: The following buttons use commandfor to show and hide a popover box when activated: If isPopover is false and isCustom is false, then: If isPopover is false and isCustom is false: Assert: invokee's
@@ -53636,7 +53636,7 @@ interface HTMLButtonElement : HTMLElement {
If command is in the hidepopover state, then: If invokee's popover visibility state is HTMLButtonElement : HTMLElement {
If command is in the showpopover state, then: If invokee's popover visibility state is HTMLButtonElement : HTMLElement {
Otherwise, if this standard defines invoker command steps for
- invokee's local name, then: Assert: shouldShowPopover is false and
From c43b2fc76af339615ceb2a653df42735b955a356 Mon Sep 17 00:00:00 2001
From: Keith Cirkel The If invokee's popover visibility state is If invokee's popover visibility state is showing, then set shouldHidePopover to
true. If invokee's popover visibility state is If invokee's popover visibility state is hidden, then set shouldShowPopover to
true. The The The The The The is valid invoker command steps, given a If command is in the close state, then return true. If command is in the show modal state, then return true. If command is the close
+ state or the show modal state, then
+ return true. Return false. The invoker command steps, given a If invokee is in the popover showing state, then return. If invokee is the popover showing
+ state, then return. If command is in the close state: If command is the close
+ state: If invokee has an If command is in the If command is the show modal state: The The The attribute's missing value default and invalid value default are both the unknown state. A valid custom command is a string whose first two code points are the U+002D
HYPHEN-MINUS character. Let isCustom be true if the command attribute is in the
- unknown state and command's value
- is a valid custom command; otherwise false.
If the command attribute is in the unknown state and isCustom is false,
- then return. Let isPopover be true if invokee's popover attribute is not in the HTMLButtonElement : HTMLElement {
content attribute. The The If the If the Constraint validation: If the If element's node document is not fully active, then
return. If element has a form owner and element's If element has a form owner then switch on element's Submit element's form
- owner from element with userInvolvement set to event's user navigation involvement. If element has a form owner and is a submit button, then Submit element's form owner from
+ element with userInvolvement set to
+ event's user navigation involvement and return. Reset element's form
- owner. Do nothing. If element has a form owner and element's Run the popover target attribute activation behavior given element
and event's target. The Let command be this's command attribute. If command is in the Toggle Popover state, return the string
+ " If command is in the Show Popover state, return the string
+ " If command is in the Hide Popover state, return the string
+ " If command is in the Close state, return the string " If command is in the Close state, return the string " If command is in the unknown state and command's value
+ is a valid custom command; return command's value. Return the empty string. The The The The The The Let type be this's type attribute. If type is in the Submit state, and this is a submit button, return the string
+ " If type is in the Reset state, return the string
+ " Return the string " The The The The The If element has a form owner and is a submit button, then Submit element's form owner from
+ data-x="concept-form-submit">submit element's form owner from
element with userInvolvement set to
event's user navigation involvement and return. If type is in the Submit state, and this is a submit button, return the string
+ data-x="concept-submit-button">submit button then return the string
" If type is in the Reset state, return the string
+ data-x="attr-button-type-reset-state">Reset state then return the string
" Return the string " Let type be this's type attribute. If this is a submit button then
+ return the string " If type is in the Submit state, and this is a submit button then return the string
- " If type is in the Reset state then return the string
+ If this's type attribute is in the
+ Reset state then return the string
" Return the string " If the Issue #1328 tracks how to
+ better standardize associated event data in a way which makes sense on Events. Currently an event
+ attribute initialized to a value cannot also have a getter, and so an internal slot (or map of
+ additional fields) is required to properly specify this. The The A button (and its value) is only included in the form submission if the button
itself was used to initiate the form submission. The If removedNode's node document's top layer contains removedNode, then
- remove an element from the top layer immediately given removedNode. Set the is modal flag of removedNode to false. Close the dialog this with returnValue. When a When a Remove subject's If the is modal flag of subject is true, then
- request an element to be removed from the top layer given subject. If the is modal flag of subject is true, then request an
+ element to be removed from the top layer given subject. Let wasModal be the value of subject's
- is modal flag. Let wasModal be the value of subject's is
+ modal flag. Set the is modal flag of subject to false. If subject's close watcher is not
- null, then: If subject's close watcher is not null,
+ then: Destroy subject's
Date: Tue, 26 Nov 2024 11:02:32 +0000
Subject: [PATCH 29/73] remove erroneous rebase artefact
---
source | 1 -
1 file changed, 1 deletion(-)
diff --git a/source b/source
index 766655918ea..983f7363a3c 100644
--- a/source
+++ b/source
@@ -53703,7 +53703,6 @@ interface HTMLButtonElement : HTMLElement {
Otherwise, run the popover target attribute activation behavior given
element. An HTML element can have specific
From aa804b61a0b742d40666ea97569ca19cb3fc253b Mon Sep 17 00:00:00 2001
From: Keith Cirkel Let command be this's command attribute. If command is in the Toggle Popover state, return the string
From 729674c8be0b391a1e97ba3e1a3499dbfb441035 Mon Sep 17 00:00:00 2001
From: Keith Cirkel If command is in the unknown state and command's value
- is a valid custom command; return command's value. Return the empty string. If this is a submit button then
- return the string " If this is a submit button, then
+ return " If this's type attribute is in the
- Reset state then return the string
- " Return the string " Return " The The following buttons use commandfor to show and hide a popover box when activated: The following code shows how buttons can use commandfor to show and hide a popover box when
+ activated: The following buttons use commandfor with a custom command on an element, demonstrating how
- one could utilise custom commands for unspecified behavior: The following code shows how buttons use commandfor with a custom command on an element,
+ demonstrating how one could utilise custom commands for unspecified behavior: Issue #1328 tracks how to
+ DOM Standard Issue #1328 tracks how to
better standardize associated event data in a way which makes sense on Events. Currently an event
attribute initialized to a value cannot also have a getter, and so an internal slot (or map of
additional fields) is required to properly specify this. A valid custom command is a string whose first two code points are the U+002D
HYPHEN-MINUS character. The A If element's node document is not fully active, then
return. If element has a form owner and is a submit button, then submit element's form owner from
- element with userInvolvement set to
- event's user navigation involvement and return. If element has a form owner and element's If element is a submit button: If element has a form owner then submit element's form owner from
+ element with userInvolvement set to
+ event's user navigation involvement and
+ return. Otherwise, return. If element's If element has a form owner then Reset element's form owner and
+ return. Otherwise, return. Run the popover target attribute activation behavior given element
and event's target. Let continue be the result of firing an
- event named Let continue be the result of firing an
+ event named DOM Standard Issue
+ #1328 tracks how to better standardize associated event data in a way which makes sense on
+ Events. Currently an event attribute initialized to a value cannot also have a getter, and so
+ an internal slot (or map of additional fields) is required to properly specify this. If continue is false, then return. If the If the Constraint validation: If the Run the popover target attribute activation behavior given element
- and event's target. Let invokee be the result of running element's get the If the Constraint validation: If the Otherwise, run the popover target attribute activation behavior given
- element. An HTML element can have specific
From 767c4c3436891a28bb081582227e09f661977d10 Mon Sep 17 00:00:00 2001
From: Keith Cirkel The attribute's missing value default and HTMLButtonElement : HTMLElement {
data-x="attr-button-command">command attribute.
Let isCustom be true if the command attribute is in the
- unknown state and command's
+ custom state and command's
value is a valid custom command; otherwise false. If the command attribute is in the HTMLButtonElement : HTMLElement {
data-x="">show-modal". If command is in the unknown state and command's value
+ data-x="attr-button-command-custom-state">custom state and command's value
is a valid custom command, then return command's value. Return the empty string. A valid custom command is a string whose first two code points are the U+002D
+ A custom command keyword is a string whose first two code points are the U+002D
HYPHEN-MINUS character. The A custom command keyword is a string whose first two code points are the U+002D
HYPHEN-MINUS character. The A Let command be element's Let isCustom be true if the command attribute is in the
- custom state and command's
- value is a valid custom command; otherwise false. If the command attribute is in the unknown state and isCustom is
- false, then return. If command is in the Unknown state, then return. Let isPopover be true if invokee's popover attribute is not in the no popover state; otherwise false. If isPopover is false and isCustom is false: If isPopover is false and the command attribute is not in the Custom state: Assert: invokee's
@@ -53647,7 +53643,8 @@ interface HTMLButtonElement : HTMLElement {
If continue is false, then return. If isCustom is true, then return. If command is in the Custom state, then return. Let shouldShowPopover be false. If command is in the Close state, return the string " If command is in the custom state and command's value
- is a valid custom command, then return command's value. Return the empty string. The attribute's missing value default and invalid value default are both the unknown state. A custom command keyword is a string whose first two code points are the U+002D
HYPHEN-MINUS character. If command is in the hidepopover state: If invokee's popover visibility state is HTMLButtonElement : HTMLElement {
If command is in the showpopover state: If invokee's popover visibility state is HTMLDialogElement : HTMLElement {
subject and state command, are: If command is the close
- state or the show modal state, then
+ If command is the Close
+ state or the Show modal state, then
return true. Return false. If command is the close
+ If command is the Close
state: If command is the show modal state: If invokee does not have an If invokee is not null, then: If element has a form owner and element's Let command be element's The following code shows how buttons can use commandfor to show and hide a popover box when
+ The following shows how buttons can use The following code shows how buttons use commandfor with a custom command on an element,
- demonstrating how one could utilise custom commands for unspecified behavior: The following shows how buttons can use The following shows how buttons can use The attribute's missing value default and invalid value default are both the Unknown state. A custom command keyword is a string whose first two code points are the U+002D
- HYPHEN-MINUS character. A custom command keyword is a string whose first two code points are U+002D
+ (-). If element has a form owner then submit element's form owner from
element with userInvolvement set to
- event's user navigation involvement and
- return. Otherwise, return. Return. If element has a form owner then Reset element's form owner and
- return. Otherwise, return. Return. If command is in the Toggle Popover state, return the string
- " If command is in the Show Popover state, return the string
- " If command is in the Hide Popover state, return the string
- " If command is in the Close state, return the string " If command is in the Show modal state, return the string " If command is in the HTMLDialogElement : HTMLElement {
When a If subject does not have an Queue an element task on the user interaction task source given
- the subject element to fire an event named
+ Queue an element task on the user interaction task source given the
+ subject element to fire an event named
DOM Standard Issue #1328 tracks how to
- better standardize associated event data in a way which makes sense on Events. Currently an event
- attribute initialized to a value cannot also have a getter, and so an internal slot (or map of
- additional fields) is required to properly specify this. DOM standard issue #1328
+ tracks how to better standardize associated event data in a way which makes sense on Events.
+ Currently an event attribute initialized to a value cannot also have a getter, and so an internal
+ slot (or map of additional fields) is required to properly specify this. A custom command keyword is a string whose first two code points are U+002D
- (-). A custom command keyword is a string whose
+ first two code points are U+002D (-). The following shows how buttons can use The following shows how Buttons can use The following shows how buttons can use If command is in the Unknown state, then return. Let isPopover be true if invokee's popover attribute is not in the Let isPopover be true if invokee's Otherwise, if the result of running invokee's corresponding is valid
- invoker command steps given command is not true, then return. If command is in the Custom state, then return. Let shouldShowPopover be false. Let shouldHidePopover be false. If command is in the Hide popover state: If invokee's popover visibility state is showing, then set shouldHidePopover to
- true. Otherwise return. If command is in the Otherwise, if command is in the Show popover state: If invokee's popover visibility state is hidden, then set shouldShowPopover to
- true. Otherwise return. If shouldShowPopover is true and the result of running
- check popover validity given invokee, false, false, and null is true,
- then: Assert: shouldHidePopover is false. Assert: isPopover is true. Run the show popover given invokee, false, and
- element. Otherwise, if shouldHidePopover is true and the result of running
- check popover validity given invokee, true, false, and null is true,
- then: Assert: shouldShowPopover is false. Assert: isPopover is true. Run the hide popover algorithm given invokee, true, true, and
- false. Otherwise, if this standard defines invoker command steps for
- invokee's local name: Assert: shouldShowPopover is false and
- shouldHidePopover is false. Run the corresponding invoker command steps given invokee,
- element and command. Otherwise, if this standard defines invoker command steps for
+ invokee's local name, then run the
+ corresponding invoker command steps given invokee, element
+ and command. The following shows how Buttons can use The invoker command steps, given a If invokee is the popover showing
From 224c61d64980808c67e5447a440375c651d130c7 Mon Sep 17 00:00:00 2001
From: Keith Cirkel If invokee is the popover showing
- state, then return. If invokee is in the popover showing state, then return. If command is the Close
+ If command is in the Close
state: If command is the If command is in the Show modal state: DOM Standard Issue
+ DOM standard issue
#1328 tracks how to better standardize associated event data in a way which makes sense on
Events. Currently an event attribute initialized to a value cannot also have a getter, and so
an internal slot (or map of additional fields) is required to properly specify this. The following buttons use commandfor to open and close a "confirm" dialog as modal when
- activated: The following buttons use Let command be element's If command is in the If the state of Let isPopover be true if invokee's If isPopover is false and the command attribute is not in the Custom state: If isPopover is false and the state of Assert: invokee's
@@ -53625,7 +53627,7 @@ interface HTMLButtonElement : HTMLElement {
Let continue be the result of firing an
event named If continue is false, then return. If command is in the Custom state, then return. If the state of If command is in the If the state of Otherwise, if command is in the Otherwise, if the state of Otherwise, if this standard defines invoker command steps for
invokee's local name, then run the
corresponding invoker command steps given invokee, element
- and command. The is valid invoker command steps, given a If command is the Close
@@ -62279,14 +62286,15 @@ interface HTMLDialogElement : HTMLElement {
The invoker command steps, given a If invokee is in the popover showing state, then return. If command is in the Close
+ If command is the Close
state: If command is in the If command is the Show modal state: If the state of If invokee's popover visibility state is HTMLButtonElement : HTMLElement {
Otherwise, if the state of If invokee's popover visibility state is HTMLButtonElement : HTMLElement {
data-x="attr-button-command">command attribute. If command is in the Toggle popover state, return " If command is in the Show popover state, return " If command is in the HTMLButtonElement : HTMLElement {
data-x="">close". If command is in the Show modal state, return " If command is in the HTMLDialogElement : HTMLElement {
If command is the Close
- state or the Show modal state, then
+ state or the Show Modal state, then
return true. Return false. If command is the Show modal state: If invokee does not have an Let command be element's If the state of If the state of Otherwise, if the state of Otherwise, if the state of Otherwise, if this standard defines invoker command steps for
invokee's local name, then run the
corresponding invoker command steps given invokee, element
- and the state of Let command be element's If the state of If the state of the Let isPopover be true if invokee's If isPopover is false and the state of If isPopover is false and the state of the If command is in the Toggle Popover state, return " If command is in the Show Popover state, return " If command is in the Hide popover state, return " If command is in the Close state, return " If command is in the Show Modal state, return " If command is in the Custom state, return command's
+ data-x="attr-button-command-custom-state">Custom state, then return command's
value. Return the empty string. If the If the A custom command keyword is a string whose
- first two code points are U+002D (-). A custom command keyword is a string whose first
+ two code points are U+002D (-). If element's If element's If element has a form owner then Reset element's
- form owner. Return. If invokee's popover visibility state is Showing, and the result of running
- check popover validity given invokee, true, false, and null is
- true, then run the hide popover algorithm given invokee, true,
+ check popover validity given invokee, true, false, and null is true,
+ then run the hide popover algorithm given invokee, true,
true, and false. Otherwise, if the state of If invokee's popover visibility state is Hidden, and the result of running
- check popover validity given invokee, false, false, and null is
- true, then run the show popover algorithm give
+ check popover validity given invokee, false, false, and null is true,
+ then run the show popover algorithm give
invokee, true, true, and false. A custom command keyword is a string whose first
- two code points are U+002D (-). A custom command keyword is a string that
+ starts with " If invokee is not null, then: If invokee is not null: Let command be element's The following shows how Buttons can use The Show this as modal. When a To show a modal dialog given a If subject has an If subject is not connected, then throw an
" If subject is in the popover showing state, then throw an
- " If subject is in the popover showing
+ state, then throw an " If the result of firing an event named If subject is not connected, then return. If subject is in the popover showing state, then return. If subject is in the popover showing
+ state, then return. Queue a dialog toggle event task given subject, " Set the is modal flag of subject to true. Let subject's node document be blocked by the modal dialog subject. Let subject's node document be blocked by the modal dialog subject. This will cause the focused area of the
document to become inert (unless that currently focused area is a
@@ -142611,6 +142606,21 @@ interface External {
If invokee does not have an If the Constraint validation: If the If invokee is not null: If element has a form owner and element's Let command be element's If the An element is said to be a submit button if any of
+ the following are true: If the The Constraint validation: If the The Constraint validation: If the element is not a submit button, the element is barred from constraint
+ validation. If specified, the If element is a submit button: If element has a form owner then submit element's form owner from
- element with userInvolvement set to
- event's user navigation involvement. Return. If element has a form owner then If element has a form owner, then Reset element's form owner. Return. The The The The If this is a submit button, then
+ return " If this's type attribute is in the
+ Reset state, then return " Return " The The The The open
From 4e07504107fed8a204845d124f774910006a144a Mon Sep 17 00:00:00 2001
From: Keith Cirkel
toggle-popover
- Toggle popover
+ Toggle Popover
Shows or hides the targeted popover
element.
show-popover
- Show popover
+ Show Popover
Shows the targeted popover
element.
hide-popover
- Hide popover
+ Hide Popover
Hides the targeted popover
element.
HTMLButtonElement : HTMLElement {
show-modal
- Show modal
+ Show Modal
Opens the targeted dialog
element as modal.
@@ -62269,11 +62269,11 @@ interface HTMLDialogElement : HTMLElement {
open
attribute, then:
open
From a128e7aeb7ab8500bb6d5f3b22f482364797f4ed Mon Sep 17 00:00:00 2001
From: Keith Cirkel commandForElement
IDL attribute must
+ commandForElement
IDL attribute must
reflect the content attribute of the same name.command
IDL attribute must reflect the
- content attribute of the same name.command
IDL attribute must reflect
+ the content attribute of the same name.value
IDL attribute must reflect the content attribute of the same name.<button type=button
commandfor="the-popover"
From 8afb669bfa2690bce3a690879c77c753dd805763 Mon Sep 17 00:00:00 2001
From: Keith Cirkel
+
source
getter steps are to
- return the result of retargeting retargeting
source
against this's currentTarget
.Loading web pages
-
-
commandForElement
IDL attribute must
- reflect the content attribute of the same name.commandfor
+ content attribute.
command
IDL attribute must reflect
the content attribute of the same name.commandfor
content attribute.
- command
IDL attribute must reflect
- the content attribute of the same name.command
IDL attribute must reflect the content
+ attribute of the same name.value
IDL attribute must reflect the content attribute of the same name.dialog
element
- subject and command, are:
-
dialog
element
- invokee, invoker, and command, are:
-
HTMLDialogElement : HTMLElement {
From 150eec82a4baa05817b579df9b3dd8225805d65a Mon Sep 17 00:00:00 2001
From: Keith Cirkel
commandForElement
IDL attribute must
+ commandForElement
IDL attribute must
reflect the element's commandfor
content attribute.command
IDL attribute must reflect the content
- attribute of the same name.toggle-popover
" if the content attribute is set to the Toggle Popover state, "show-popover
" if the content attribute is set to the Show Popover state, "hide-popover
" if the content attribute is set to the Hide Popover state, "close
" if the content attribute is set to the close state, "show-modal
" if the content attribute is set to the show-modal state, the
+ command
attribute if the content attribute is set to
+ the unknown state and the attribute is a
+ valid custom command; and null otherwise. On setting, must set the command
content attribute to the given new value.
value
IDL attribute must reflect the content attribute of the same name.
submit
- Submit Button
+ Submit Button
Submits the form.
reset
- Reset Button
+ Reset Button
Resets the form.
button
- Button
+ Button
Does nothing.
@@ -53477,8 +53477,16 @@ interface HTMLButtonElement : HTMLElement {
data-x="attr-button-type-submit-state">Submit Button state.
type
attribute is in the Submit Button state, the element is specifically a
- submit button.type
, command
,
+ and commandfor
content attributes are not present,
+ then the element is specifically a submit button.
+
+ type
attribute is in the Submit Button state, and the
+ command
, or commandfor
content attributes are present, then the
+ element is specifically not a submit button.type
attribute is in the Reset Button state or the
@@ -53547,30 +53555,17 @@ interface HTMLButtonElement : HTMLElement {
commandfor
or command
attributes are present,
- and the element's type
attribute is not in
- the button
state, then return.type
attribute's state, then:
-
type
attribute is in the Reset Button state, then Reset element's form owner and
+ return.command
IDL attribute, on getting, must return
- the string "toggle-popover
" if the content attribute is set to the Toggle Popover state, "show-popover
" if the content attribute is set to the Show Popover state, "hide-popover
" if the content attribute is set to the Hide Popover state, "close
" if the content attribute is set to the close state, "show-modal
" if the content attribute is set to the show-modal state, the
- command
attribute if the content attribute is set to
- the unknown state and the attribute is a
- valid custom command; and null otherwise. On setting, must set the command
content attribute to the given new value.
+
+
+ toggle-popover
".show-popover
".hide-popover
".close
".show-modal
".command
setter steps are to set the command
content attribute to the given value.value
IDL attribute must reflect the content attribute of the same name.value
IDL attribute must reflect the content attribute of the same name.type
IDL
- attribute must reflect the content attribute of the same name, limited to only
- known values.type
+ getter steps are:type
+ getter steps are:
+
+
+ submit
".reset
".button
".type
setter steps are to set the type
content attribute to the given value.willValidate
, validity
, and
Date: Sun, 10 Nov 2024 17:24:49 +0000
Subject: [PATCH 21/73] remove duplicate statement
---
source | 4 ----
1 file changed, 4 deletions(-)
diff --git a/source b/source
index f54e74ab05d..69f63b162c8 100644
--- a/source
+++ b/source
@@ -53791,10 +53791,6 @@ interface HTMLButtonElement : HTMLElement {
value
IDL attribute must reflect the content attribute of the same name.type
- getter steps are:type
getter steps are:submit
".reset
".button
".
-
submit
".submit
".reset
".button
".type
attribute is in the Submit Button state, and the
- command
, or command
and commandfor
content attributes are present, then the
element is specifically not a submit button.currentTarget
.
+ Focus
From 8779da9ffbc3d6efa9df9954120c8613886d938b Mon Sep 17 00:00:00 2001
From: Keith Cirkel form
attribute is used to explicitly associate the
button
element with its form owner. The name
attribute represents the element's name. The disabled
attribute is used to make the control non-interactive
- and to prevent its value from being submitted. The formaction
, formenctype
, disabled
attribute is used to make the control non-interactive and
+ to prevent its value from being submitted. The formaction
,
+ formenctype
, formmethod
, formnovalidate
, and formtarget
attributes are
- attributes for form submission.formnovalidate
attribute can be
used to make submit buttons that do not trigger the constraint validation.
+
HTMLDialogElement
: HTMLElement {
dialog
element subject is to be closed, with null or a string result, run these
+ dialog
element subject is to be closed, with null or a string result, run these
steps:
@@ -62414,12 +62414,11 @@ interface HTMLDialogElement : HTMLElement {
@@ -53795,14 +53795,14 @@ interface HTMLButtonElement : HTMLElement {
getter steps are:
open
attribute.close
at subject.
-
submit
".submit
".reset
".reset
".
- button
".button
".type
setter steps are to set the
Date: Tue, 26 Nov 2024 11:03:32 +0000
Subject: [PATCH 32/73] rephase examples to say "the following code shows"
---
source | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
diff --git a/source b/source
index e349d357d98..814f96649d2 100644
--- a/source
+++ b/source
@@ -53833,7 +53833,8 @@ interface HTMLButtonElement : HTMLElement {
<button type=button
commandfor="the-popover"
@@ -53851,8 +53852,8 @@ interface HTMLButtonElement : HTMLElement {
<button type=button
commandfor="the-image"
From 4757ab1cfd14f74e0e30cfb7e192c3b5038a200e Mon Sep 17 00:00:00 2001
From: Keith Cirkel
against this's currentTarget
.
- command
attribute can be a
+ predefined value (one of the values in the table above) or start with two dashes,
+ allowing for developers to build custom commands. Custom commands will dispatch the
+ command
event, but will never execute other pre-defined
+ behavior. Values which are not pre-defined and do not start with two dashes will not dispatch
+ the command
event and are to be avoided.button
element element's activation behavior given
From 7d5fc66a3fe1a9a97b27736e554abc1f7ac6f20d Mon Sep 17 00:00:00 2001
From: Keith Cirkel type
attribute is in the Reset Button state, then Reset element's form owner and
- return.
+
+ type
attribute is in the
+ Reset Button state:
+
+ command
at invokee, using
- CommandEvent
, with its command
- attribute initialized to command's value, its source
attribute initialized to element,
- and its cancelable
and composed
attributes initialized to true.command
at invokee, using
+ CommandEvent
, with its command
+ attribute initialized to command's value, its source
attribute initialized to element,
+ and its cancelable
and composed
attributes initialized to true.commandfor
content attributes are not present,
then the element is specifically a submit button.type
attribute is in the Submit Button state, and the
+ type
content attribute is present and in the
+ Submit Button state, and the
command
and commandfor
content attributes are present, then the
- element is specifically not a submit button.type
attribute is in the Reset Button state or the
From a3bbc4a38ec83bd15becb7cd9ab551591777f99d Mon Sep 17 00:00:00 2001
From: Keith Cirkel commandfor
associated
element.type
content attribute is present and in the
Submit Button state, and the
command
and commandfor
content attributes are present, then the
+ data-x="attr-button-commandfor">commandfor content attributes are not present, then the
element is specifically a submit button.type
From 21fefc6eab22164ba38146357b6801a22620b90a Mon Sep 17 00:00:00 2001
From: Keith Cirkel show-modal
Show Modal
Opens the targeted dialog
element as modal.
+
+ (valid custom command)
+ Custom
+ Only dispatches the command
event.
close
";
"show-modal
";
a valid custom command;
- the empty string
commandfor
button
From a033ef8320d48f6a3301b45e13e1164bc369bc37 Mon Sep 17 00:00:00 2001
From: Keith Cirkel Opens the targeted dialog
element as modal.
(valid custom command)
+ data-x="attr-button-command-custom">(Custom command keyword)
Custom
Only dispatches the command
event.
@@ -53545,7 +53545,7 @@ interface HTMLButtonElement : HTMLElement {
data-x="invalid value default">invalid value default are both the unknown state.
- command
attribute can be a
@@ -142965,7 +142965,7 @@ interface External {
"hide-popover
";
"close
";
"show-modal
";
- a valid custom command;
+ a (Custom command keyword)
commandfor
button
From 8e6b74e7a04865ae965568f6c4953809aa725a6e Mon Sep 17 00:00:00 2001
From: Keith Cirkel command
attribute can be a
- predefined value (one of the values in the table above) or start with two dashes,
- allowing for developers to build custom commands. Custom commands will dispatch the
- command
event, but will never execute other pre-defined
- behavior. Values which are not pre-defined and do not start with two dashes will not dispatch
- the command
event and are to be avoided.button
element element's activation behavior given
From 8d2a17bbc8076054d1e8ba4dfa132dc89d7d723d Mon Sep 17 00:00:00 2001
From: Keith Cirkel command
attribute.
Show modal state, return the string "
show-modal
".
-
@@ -62347,7 +62347,7 @@ interface HTMLDialogElement : HTMLElement {
open
From d6536f1cff73685035954992c651107c153f1b47 Mon Sep 17 00:00:00 2001
From: Keith Cirkel
-
type
attribute is not in the button
state, then return.command
attribute.commandfor
to show and hide a popover box when
activated:<button type=button
@@ -53869,8 +53870,10 @@ interface HTMLButtonElement : HTMLElement {
commandfor
with a (Custom command keyword) on an element, demonstrating
+ how one could utilise custom commands for unspecified behavior:<button type=button
commandfor="the-image"
From eb62a522dd903f7983b593091af18d0a8e05846e Mon Sep 17 00:00:00 2001
From: Keith Cirkel
commandfor
with a (Custom command keyword) on an element, demonstrating
+ data-x="attr-button-command-custom">Custom command keyword on an element, demonstrating
how one could utilise custom commands for unspecified behavior:<button type=button
From 8621f0a213382ad8dc6b80580f74fc7014966860 Mon Sep 17 00:00:00 2001
From: Keith Cirkel
toggle-popover
- Toggle Popover
+ Toggle popover
Shows or hides the targeted popover
element.
show-popover
- Show Popover
+ Show popover
Shows the targeted popover
element.
hide-popover
- Hide Popover
+ Hide popover
Hides the targeted popover
element.
HTMLButtonElement : HTMLElement {
Show Modal
Opens the targeted dialog
element as modal.
- (Custom command keyword)
+ A Custom command keyword
Custom
- Only dispatches the command
event.
+ Only dispatches the command
event on the targeted
+ element.
@@ -53776,23 +53775,23 @@ interface HTMLButtonElement : HTMLElement {
data-x="attr-button-command">command attribute.
toggle-popover
".toggle-popover
".
show-popover
".show-popover
".
hide-popover
".hide-popover
".
Close state, return "
close
".Show modal state, return "
show-modal
".dialog
element subject is to be closed, with null or a string result, run these
- steps:
open
@@ -62462,8 +62460,8 @@ interface HTMLDialogElement : HTMLElement {
close
at subject.currentTarget
.
- Focus
From 44a398d5bb282973bc29c24229d5607b58fbcda1 Mon Sep 17 00:00:00 2001
From: Keith Cirkel Show Modal
Opens the targeted dialog
element as modal.
- A Custom command keyword
+ A Custom command keyword
Custom
Only dispatches the command
event on the targeted
element.
@@ -53545,8 +53545,8 @@ interface HTMLButtonElement : HTMLElement {
data-x="invalid value default">invalid value default are both the Unknown state.
- commandfor
to show and hide a popover box when
- activated:commandfor
to show and hide an element with
+ the popover attribute when activated:<button type=button
commandfor="the-popover"
From e47a66c2e347458ddb2a0bb3f8b2de706987c810 Mon Sep 17 00:00:00 2001
From: Keith Cirkel
Show Modal
Opens the targeted dialog
element as modal.
- A Custom command keyword
+ A custom command keyword
Custom
Only dispatches the command
event on the targeted
element.
From c1c8f42d5ae48ee52e7eec724491186230439d39 Mon Sep 17 00:00:00 2001
From: Keith Cirkel commandfor
with a Custom command keyword on an element, demonstrating
+ data-x="attr-button-command-custom">custom command keyword on an element, demonstrating
how one could utilise custom commands for unspecified behavior:<button type=button
@@ -142954,7 +142954,7 @@ interface External {
"
hide-popover
";
"close
";
"show-modal
";
- a (Custom command keyword)
+ a custom command keyword
commandfor
button
From 34e7de821f76d173ed8ec73d1aa34fa145d50955 Mon Sep 17 00:00:00 2001
From: Keith Cirkel hide-popover
";
"close
";
"show-modal
";
- a custom command keyword
+ a custom command keyword
commandfor
button
From b5c402a82f78bbd76f8094fd7b6dd368a75b131a Mon Sep 17 00:00:00 2001
From: Keith Cirkel popover
attribute is not in the no popover state; otherwise false.
-
-
-
-
-
- commandfor
to show and hide an element with
- the popover attribute when activated:popover
attribute when activated:
<button type=button
commandfor="the-popover"
From f07be5ac7b40bab75ae03baa6327629901a9050f Mon Sep 17 00:00:00 2001
From: Keith Cirkel
dialog
element
- invokee, an element invoker and a state command, are:
-
@@ -62303,7 +62303,7 @@ interface HTMLDialogElement : HTMLElement {
From 0ce6b7e47250bb5caaf36d25b48df1f542bfcfb1 Mon Sep 17 00:00:00 2001
From: Keith Cirkel
show-modal
- Show Modal
+ Show modal
Opens the targeted dialog
element as modal.
A custom command keyword
@@ -53630,7 +53630,7 @@ interface HTMLButtonElement : HTMLElement {
and its cancelable
and composed
attributes initialized to true.
- commandfor
to open and
+ close a "confirm" dialog
as modal when activated:<button type=button
commandfor="the-dialog"
From 2cf379afb1136cb0dc033adec0adbda4db9b6a5b Mon Sep 17 00:00:00 2001
From: Keith Cirkel
attribute value.
-
command
attribute.command
of corresponding to
+ command is in the Unknown state, then return.HTMLButtonElement : HTMLElement {
data-x="attr-popover-none-state">no popover state; otherwise false.
command
corresponding to command is in the
+ Custom state:
command
at invokee, using
CommandEvent
, with its command
- attribute initialized to command's value, its command, its
source
attribute initialized to element,
and its cancelable
and composed
attributes initialized to true.command
corresponding to
+ command is in the Custom
+ state, then return.command
corresponding to
+ command is in the Hide popover state:
@@ -53655,7 +53659,8 @@ interface HTMLButtonElement : HTMLElement {
command
of corresponding to
+ command is in the Show popover state:
@@ -53670,7 +53675,8 @@ interface HTMLButtonElement : HTMLElement {
command
of corresponding to
+ command.dialog
element
- subject and state command, are:
dialog
element
- invokee, an element invoker, and a state command, are:
@@ -62303,7 +62311,7 @@ interface HTMLDialogElement : HTMLElement {
From d2eb8df889dff6a1b5830dd107d6c979e9942e0f Mon Sep 17 00:00:00 2001
From: Keith Cirkel
toggle-popover
- Toggle popover
+ Toggle Popover
Shows or hides the targeted popover
element.
show-popover
- Show popover
+ Show Popover
Shows the targeted popover
element.
hide-popover
- Hide popover
+ Hide Popover
Hides the targeted popover
element.
HTMLButtonElement : HTMLElement {
show-modal
- Show modal
+ Show Modal
Opens the targeted dialog
element as modal.
A custom command keyword
@@ -53647,7 +53647,7 @@ interface HTMLButtonElement : HTMLElement {
command
corresponding to
command is in the Hide popover state:
command
of corresponding to
command is in the Show popover state:
Toggle Popover state, return "
toggle-popover
".Show Popover state, return "
show-popover
".Show Modal state, return "
show-modal
".
state:
open
From 0a57503abbf898e9c3e22622a8a0c8b9c1d03424 Mon Sep 17 00:00:00 2001
From: Keith Cirkel command
attribute value.command
of corresponding to
+ command
corresponding to
command is in the Unknown state, then return.command
of corresponding to
+ command
corresponding to
command is in the Show Popover state:command
of corresponding to
+ and the state of command
corresponding to
command.command
attribute value.command
corresponding to
- command is in the command
attribute with
+ value command is the Unknown state, then return.HTMLButtonElement : HTMLElement {
data-x="attr-popover-none-state">no popover state; otherwise false.
command
corresponding to command is in the
+ command
attribute with value command is the
Custom state:
From 9aa71093f51ee816f9b1ebb783d9625665e3b717 Mon Sep 17 00:00:00 2001
From: Keith Cirkel
toggle-popover
".toggle-popover
".Show Popover state, then return "
show-popover
".Hide popover state, then return "
hide-popover
".Close state, then return "
close
".Show Modal state, then return "
show-modal
".type
attribute is in the Submit Button state, and the
- type
, command
,
- and commandfor
content attributes are not present,
- then the element is specifically a submit button.type
, command
, and
+ commandfor
content attributes are not present, then
+ the element is specifically a submit button.
type
content attribute is present and in the
- Submit Button state, and the
- command
and Submit Button state, and the
command
and commandfor
content attributes are not present, then the
element is specifically a submit button.type
attribute is in the
- Reset Button state:type
attribute is in the Reset Button state:
command
corresponding to
- command is in the Otherwise, if the state of command
corresponding
+ to command is in the Show Popover state:
--
".
HTMLButtonElement : HTMLElement {
The following shows how buttons can use
commandfor
to show and hide an element with
the popover
attribute when activated:showModal()
method steps are:
-
-
- dialog
element subject is to be shown as modal, run these steps:dialog
element subject:
open
attribute and
@@ -62156,9 +62151,9 @@ interface HTMLDialogElement : HTMLElement {
InvalidStateError
" DOMException
.InvalidStateError
" DOMException
.InvalidStateError
"
+ DOMException
.beforetoggle
, using ToggleEvent
, with the HTMLDialogElement : HTMLElement {
closed
", and "open
".th
Number of columns that the cell is to span
Valid non-negative integer greater than zero
+
+ command
+ button
+ Indicates to the targeted element which action to take.
+ " toggle-popover
";
+ "show-popover
";
+ "hide-popover
";
+ "close
";
+ "show-modal
";
+ a custom command keyword
+
+ commandfor
+ button
+ Targets another element to be invoked.
+ ID*
content
meta
@@ -142910,21 +142920,6 @@ interface External {
script
Integrity metadata used in Subresource Integrity checks SRI
Text
-
- command
- button
- Indicates to the targeted element which action to take.
- " toggle-popover
";
- "show-popover
";
- "hide-popover
";
- "close
";
- "show-modal
";
- a custom command keyword
-
- commandfor
- button
- Targets another element to be invoked.
- ID*
is
HTML elements
From 35849e782d8aac06fcb519a0fc5d46015a2c6b36 Mon Sep 17 00:00:00 2001
From: Anne van Kesteren
From d27d5149bfb3280d5d10fb73da14cfbf03b22377 Mon Sep 17 00:00:00 2001
From: Keith Cirkel open
- attribute, then show modal dialog invokee.type
content attribute is present and in the
- Submit Button state, and the command
and commandfor
content attributes are not present, then the
- element is specifically a submit button.type
attribute is in the Reset Button state or the
@@ -53593,6 +53591,10 @@ interface HTMLButtonElement : HTMLElement {
+
@@ -53606,7 +53607,7 @@ interface HTMLButtonElement : HTMLElement {
data-x="attr-button-type-reset-state">Reset Button state:
type
attribute is in the Submit Button state, then return.command
attribute value.type
attribute is in the Submit Button state, and the type
, command
, and
- commandfor
content attributes are not present, then
- the element is specifically a submit button.type
content attribute is present and in the
- Submit Button state, then the element is
- specifically a submit button.
+
+
+ type
attribute is in the Submit Button state; ortype
- attribute is in the Reset Button state or the
- Button state, the element is barred from
- constraint validation.type
content attribute is present, and in the
+ Submit Button state.commandfor
attribute value must be the HTMLButtonElement : HTMLElement {
+
-
formmethod
, formnovalidate
, and formtarget
must not be specified if the element's type
attribute is not in the Submit Button state.
+ data-x="attr-fs-formtarget">formtarget must not be specified if the element is not a submit button
.
commandForElement
IDL attribute must
@@ -53802,9 +53802,22 @@ interface HTMLButtonElement : HTMLElement {
value
IDL attribute must reflect the content attribute of the same name.type
IDL
- attribute must reflect the content attribute of the same name, limited to only
- known values.type
+ getter steps are:
+
+
+ submit
".reset
".button
".type
setter steps are to set the type
content attribute to the given value.willValidate
, validity
, and
Date: Thu, 6 Feb 2025 20:31:00 +0000
Subject: [PATCH 73/73] ensure button submit state is submit only when
command/commandfor aren't present
---
source | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/source b/source
index 7aec90585b1..5e8972d9826 100644
--- a/source
+++ b/source
@@ -53511,7 +53511,10 @@ interface HTMLButtonElement : HTMLElement {
type
attribute is in the Submit Button state; orcommand
and commandfor
content attributes are not present;
+ ortype
content attribute is present, and in the
Submit Button state.