From 9bed709ef86112e471bcf0a5cae9d721a2f38eed Mon Sep 17 00:00:00 2001
From: Joey Arhar
If removedNode's popup
attribute is not in the
+ no pop-up state, then run the hide pop-up
+ algorithm given removedNode, false, and true.
A The tree, shadow tree, and node tree concepts
The following features are defined in UI Events: The algorithm to update
- animations and send events is defined in Web Animations. . The following features and terms are defined in the Web Animations
+ specification: Implementations that support scripting must support the CSS Object Model. The following
features and terms are defined in the CSSOM specifications:
@@ -10993,6 +11007,12 @@ interface HTMLElement : Element {
[CEReactions] attribute [LegacyNullToEmptyString] DOMString outerText;
ElementInternals attachInternals();
+
+ // The pop-up API
+ void showPopUp();
+ void hidePopUp();
+ [Unscopable, CEReactions] attribute DOMString? popUp;
+ [CEReactions] attribute boolean defaultOpen;
};
HTMLElement includes GlobalEventHandlers;
@@ -12228,6 +12248,7 @@ https://software.hixie.ch/utilities/js/live-dom-viewer/?%3C%21DOCTYPE%20HTML%3E%
Run this element's input activation behavior, if any, and do nothing
otherwise. Run the pop-up target attribute activation behavior on this element. Recall that an element's activation behavior runs for both
@@ -46654,6 +46756,9 @@ interface HTMLInputElement : HTMLElement {
The The following common The following content attributes must not be specified and do not apply to the
element:
The following common The following content attributes must not be specified and do not apply to the
element:
If element is disabled, then
return. If element does not have a form owner, then return. If element's node document is not fully active, then
return. Switch on element's If element has a form owner then switch on element's Do nothing. Run the pop-up target attribute activation behavior given
+ element. The The If focus event target is not null, fire a focus event
- named If focus event target is not null, then: Let defaultNotPreventedbe the result of firing a focus event
+ named If defaultNotPrevented is false, then: Let ancestor be the result of running nearest open ancestral
+ pop-up given focus event target and " Run hide all pop-ups until given
+ ancestor, false, false, and true. In some cases, e.g. if entry is an To fire a focus event named e at an element t with a given
- related target r, fire an event named
- e at t, using The When the The An element's nearest ancestor autofocus scoping root element is the element itself
- if the element is a There must not be two elements with the same nearest ancestor autofocus scoping root
@@ -80931,6 +81143,1124 @@ dictionary DragEventInit : MouseEventInit {
+ All elements may have the The The The attribute may be omitted. The invalid value default
+ and the missing value default are both the manual state.
+
+ When the Every element has a pop-up visibility state with these potential values: hidden transitioning showing The pop-up visibility transitioning state and The following is an example of an animated pop-up: The The The The Every element has the following members: A pop-up previously focused element, which is an A pop-up invoker, which is an The following attribute change steps
+ are used for the If localName is not If oldValue is in the no pop-up
+ state, then return. If value is not in the no pop-up
+ state, then return. Run the hide pop-up algorithm given element, true, and
+ false. The Run show pop-up given this. To show pop-up, given an If element's If element's pop-up visibility state is not hidden, then throw a
+ " If element is not connected, then throw a
+ " If the result of firing an event named If element is not connected, then return. If element's If element's pop-up visibility state is showing, then return. These validity checks are repeated because firing the Let document be element's node document. Let shouldRestoreFocus be false. If element's If document's currently-showing hint pop-up is not null, then
+ run the hide pop-up algorithm given document's currently-showing
+ hint pop-up, true, and false. Let ancestor be the result of running the nearest open ancestral
+ pop-up algorithm given element and " If ancestor is not null, then run hide
+ all pop-ups until given ancestor, false, false, and true. If element's Let ancestor be the result of running the nearest open ancestral
+ pop-up algorithm given element and " Run hide all pop-ups until given
+ ancestor, false, false, and true. If element's If element's If element's pop-up visibility state is not hidden, then return. If element is not connected, then return. These validity checks are repeated because running hide all pop-ups until above could have fired the
+ If the result of running topmost pop-up auto or hint on document
+ is null, then set shouldRestoreFocus to true. Otherwise, set
+ shouldRestoreFocus to false. This ensures that focus is returned to the previously-focused element only for the first
+ pop-up in a stack. If element's If element's Stop element from waiting for any animations to resolve before running pop-up hide finish if needed. Set element's pop-up previously focused element to null. Let originallyFocusedElement be document's focused area of the
+ document. Add element to document's top layer. Set element's pop-up visibility state to transitioning. Recalculate styles and update layout for document. Set element's pop-up visibility state to showing. Run the hide pop-up algorithm given element, true, and
+ false. Run the pop-up focusing steps given element. If shouldRestoreFocus is true, element's The If this's If this's pop-up visibility state is not showing, then throw a
+ " Run the hide pop-up algorithm given this, true, and
+ false. To hide a pop-up given an Let document be element's node document. If element's Run hide all pop-ups until given
+ element, focusPreviousElement, hideImmediately, and
+ false. If element's If element is not connected, then return. If element's pop-up visibility state is not showing, then return. These validity checks are repeated because running hide all pop-ups until above could have fired the
+ If element's If element's Add element to document's pop-ups waiting to
+ hide. Let previousAnimations be the set of all relevant Set element's pop-up invoker to null. Set element's pop-up visibility state to transitioning. If hideImmediately is true, then: Queue an element task given user interaction task source and
+ element to fire an event named Run pop-up hide finish if needed
+ given element. Return. Fire an event named If element is not connected, then return. If element's If element's pop-up visibility state is transitioning, then return. Let animations be the set of all relevant Remove all items in animations which exist in
+ previousAnimations. If animations is empty, then run pop-up hide finish if needed given
+ element. Let previouslyFocusedElement be element's previously focused
+ element. If previouslyFocusedElement is not null, then: Set element's previously focused element to null. If focusPreviousElement is true, then run the focusing steps for
+ previouslyFocusedElement. If animations is not empty, then run these steps in parallel: Wait for each animation in animations to resolve as either canceled or finished. Run pop-up hide finish if needed
+ given element. To finish hiding a pop-up if needed, given an
+ Remove element from element's node document's
+ pop-ups waiting to hide. Remove element from the top layer. Set element's pop-up visibility state to hidden. Stop element from waiting for any animations to resolve before running this
+ algorithm. To hide all pop-ups until, given an
+ Let document be endpoint's node document. If hideImmediately is true, then: For each elementWaitingToHide in document's pop-ups waiting to
+ hide: Run pop-up hide finish if needed
+ given elementWaitingToHide. Clear document's pop-ups waiting to hide. If endpoint's If document's currently-showing hint pop-up is not equal to
+ endpoint, then run the hide pop-up algorithm given endpoint,
+ focusPreviousElement, and hideImmediately. While document's auto pop-up stack is not empty: Run the hide pop-up algorithm given endpoint,
+ focusPreviousElement, and hideImmediately. If endpoint's Let hintAncestor be null. If document's currently-showing hint pop-up is not null, then: Let hintAncestor be the result of running the nearest open ancestral
+ pop-up algorithm given document's currently-showing hint
+ pop-up and " If hintAncestor is null and hideUnrelated is true, then run the
+ hide pop-up algorithm given document's currently-showing hint
+ pop-up, focusPreviousElement and hideImmediately. While document's auto pop-up stack is not empty: If document's auto pop-up stack's top element is
+ hintAncestor, then run the hide pop-up algorithm given
+ document's currently-showing hint pop-up,
+ focusPreviousElement and hideImmediately. If document's auto pop-up stack's top element is equal to
+ endpoint, then break. Run the hide pop-up algorithm given document's auto
+ pop-up stack's top element, focusPreviousElement, and
+ hideImmediately. The hide all pop-ups until algorithm is used in
+ several cases to hide all pop-ups that don't stay open when something happens. For example,
+ during light-dismiss of a pop-up, this algorithm ensures that we close only the pop-ups that
+ aren't related to the node clicked by the user. The interaction between To find the nearest open ancestral pop-up,
+ given a Let document be node's node document. Let hintShowing be document's currently-showing hint
+ pop-up. Let anchorsToPopUps be an empty map. For each popUp in document's auto pop-up stack: Let anchor be the result of getting the
+ pop-up anchor element of popUp. If anchor is not null, then set
+ anchorsToPopUps[anchor] to popUp. If hintShowing is not null, then: Let anchor be the result of running getting the pop-up anchor element of
+ hintShowing. If anchor is not null, then set
+ anchorsToPopUps[anchor] to hintShowing. Let popUpPositions be an empty map. Let index be 0. For each popUp in document's auto pop-up stack: Set popUpPositions[popUp] to
+ index. Increment index by 1. If hintShowing is not null, then: Set popUpPositions[hintShowing] to
+ index. Increment index by 1. If ancestorType is " Set popUpPositions[node] to
+ index. Let upperBound be 2147483647. If popUpPositions[node] exists, then set upperBound to
+ popUpPositions[node]. If hintShowing is not null and ancestorType is " If ancestorType is " Let currentNode be node. While currentNode has a parent node within the flat tree: If currentNode's If popUpPositions[currentNode] + 1 is greater than
+ upperBound, then set upperBound to
+ popUpPositions[currentNode] + 1. Let targetPopUp be currentNode's pop-up target
+ element. If targetPopUp's If popUpPositions[targetPopUp] + 1 is greater than
+ upperBound, then set upperBound to
+ popUpPositions[targetPopUp] + 1. Set currentNode to the parent node of currentNode within the
+ flat tree. Let seen be an empty set. Return the result of finding the nearest open ancestral pop-up recursively
+ given node, popUpPositions, anchorsToPopUps,
+ upperBound, and seen. To find the nearest open ancestral pop-up
+ recursively, given a If node is null, then return null. If seen contains node, then return null. Add node to seen. Let ancestor be null. Let position be −1. Let update be an algorithm which performs the following steps given
+ popUp: If popUp is not null and popUp's pop-up visibility state
+ is not showing and popUp's Let newPosition be popUpPositions[popUp]. If newPosition is greater than position and newPosition
+ is less than upperBound, then: Set ancestor to popUp. Set position to newPosition. Let recurseAndUpdate be an algorithm which performs the following steps given
+ node: Let nearestOpenAncestor be the result of finding the nearest open ancestral pop-up
+ recursively given node, popUpPositions,
+ anchorsToPopUps, upperBound, and seen. Run update given nearestOpenAncestor. Run update given node. If popUpPositions[node] exists, then: Run recurseAndUpdate given node's pop-up anchor element. Run recurseAndUpdate given node's pop-up
+ invoker. If node has a pop-up target element, then run
+ recurseAndUpdate given node's pop-up target element. If anchorsToPopUps[node] exists, then run
+ recurseAndUpdate given anchorsToPopUps[node]. Run recurseAndUpdate given node's parent node in the flat
+ tree. Return ancestor. To get the pop-up anchor element of an
+ If element's Let anchorAttribute be the result of running get an attribute by
+ name given element and 'anchor'. If anchorAttribute is null, then return null. Return the first element, in tree
+ order, within element's root's descendants, whose ID is
+ anchorAttribute; otherwise, if there is no such element, null. To find the topmost pop-up auto or hint given a
+ If document's currently-showing hint pop-up is not null, then return
+ document's currently-showing hint pop-up. If document's auto pop-up stack is not empty, then return
+ document's auto pop-up stack's last element. Return null. To perform the pop-up focusing steps for an Let control be the result of running pop-up focusable area given
+ subject. If control is null, then return. Run the focusing steps given control. Let topDocument be the active document of control's
+ node document's browsing context's
+ top-level browsing context. If control's node document's origin is not the same
+ as the origin of topDocument, then
+ return. Empty topDocument's
+ autofocus candidates. Set topDocument's autofocus processed flag to true. To get the pop-up focusable area given an element subject, perform the
+ following steps. They return an If subject has the For each node in the flat tree within subject: If node is a If node is not focusable, then continue. If node does not have the Return node. Return null. Supported elements may have the
+ following content attributes, known as the pop-up target attributes: The pop-up target attributes allow certain types of buttons to show and hide
+ element with the The following shows how The following shows how The pop-up target attributes are only supported on the following elements: The The The To run the pop-up target attribute activation behavior given a If node is disabled, then
+ return. If node is not supported by the pop-up target
+ attributes, then return. Let popUp be node's pop-up target element. If popUp is null, then return. If node doesn't have the If node has the If node has the If node doesn't have the If node has a form owner and node is in any of the
+ following states, then return: node is a node is an node is an If popUp's pop-up visibility state is showing, then run the hide pop-up algorithm
+ given popUp, true, and false. Otherwise: Set popUp's pop-up invoker to node. Run show pop-up given popUp. To get the pop-up target element given a If node is not supported, then return null. Let idref be null. If node has the Otherwise, if node has the Otherwise, if node has the If idref is null, then return null. Let popupElement be the first element, in
+ tree order, within node's root's descendants, whose ID is
+ idref; otherwise, if there is no such element,
+ null. If popupElement is null, then return null. If popupElement's Return popupElement. "Light dismiss" means that pressing the Esc key or clicking outside of a pop-up
+ whose When a Let topmostPopup be the result of running topmost pop-up auto or
+ hint given document. If topmostPopup is null, then return. Let target be event's target. If event is a Set document's pop-up mousedown target to the result of running
+ nearest open ancestral pop-up given target and " If event is a Let ancestor be the result of running nearest open ancestral
+ pop-up given target and " Let sameTarget be true if ancestor is document's
+ pop-up mousedown target. Set document's pop-up mousedown target to null. If sameTarget is true, then run hide
+ all pop-ups until given ancestor, false, false, and true. If event is a Run the hide pop-up algorithm given topmostPopup, true, and
+ false. All elements may have the The If element has the Queue an element task on the user interaction task source given
+ element to run the following steps: If element is not connected, then abort these steps. If element's If element's If element's This ensures that only the first popup=auto element with defaultopen is shown. Run show pop-up given element. Push element onto the stack of open elements so that it is the new
current node. Elements with the To implement a custom context menu, use script to handle the is
valueMutationObserver
interface and mutation observers in general
+
autofocus
contenteditable
dir
defaultopen
draggable
enterkeyhint
hidden
itemtype
lang
nonce
popup
spellcheck
style
tabindex
onpause
onplay
onplaying
onpopuphide
onpopupshow
onprogress
onratechange
onreset
name
pattern
placeholder
popuphidetarget
popupshowtarget
popuptoggletarget
readonly
required
size
HTMLInputElement
.
- readonly
- ·
- Yes
-
- Yes
- Yes
- Yes
- Yes
-
-
-
- Yes
- Yes
- ·
- ·
- ·
-
- ·
- ·
- ·
- ·
-
-
-
- required
- ·
- Yes
-
- Yes
- Yes
- Yes
- Yes
-
-
-
- Yes
- Yes
- ·
- ·
- Yes
-
- Yes
- ·
- ·
- ·
-
-
-
- size
- ·
- Yes
-
- Yes
- Yes
- Yes
- ·
-
-
-
- ·
- ·
- ·
- ·
- ·
-
- ·
- ·
- ·
- ·
-
-
-
- src
+ popuphidetarget
·
·
@@ -45822,37 +45778,13 @@ interface HTMLInputElement : HTMLElement {
·
·
- ·
+ Yes
Yes
- ·
-
+ Yes
+
- step
- ·
- ·
-
- ·
- ·
- ·
- Yes
-
-
-
- Yes
- Yes
- Yes
- ·
- ·
-
- ·
- ·
- ·
- ·
-
-
-
-
width
+ popupshowtarget
·
·
@@ -45870,17 +45802,13 @@ interface HTMLInputElement : HTMLElement {
·
·
- ·
+ Yes
Yes
- ·
-
+ Yes
+
-
- IDL attributes and methods
-
-
- checked
+ popuptoggletarget
·
·
@@ -45891,78 +45819,6 @@ interface HTMLInputElement : HTMLElement {
- ·
- ·
- ·
- ·
- Yes
-
- ·
- ·
- ·
- ·
-
-
-
- files
- ·
- ·
-
- ·
- ·
- ·
- ·
-
-
-
- ·
- ·
- ·
- ·
- ·
-
- Yes
- ·
- ·
- ·
-
-
-
- value
- default
- value
-
- value
- value
- value
- value
-
-
-
- value
- value
- value
- value
- default/on
-
- filename
- default
- default
- default
-
-
-
- valueAsDate
- ·
- ·
-
- ·
- ·
- ·
- Yes
-
-
-
·
·
·
@@ -45970,26 +45826,26 @@ interface HTMLInputElement : HTMLElement {
·
·
- ·
- ·
- ·
-
+ Yes
+ Yes
+ Yes
+
- valueAsNumber
+ readonly
·
- ·
-
- ·
- ·
- ·
+ Yes
+
+ Yes
+ Yes
+ Yes
Yes
Yes
Yes
- Yes
+ ·
·
·
@@ -46000,132 +45856,36 @@ interface HTMLInputElement : HTMLElement {
- list
+ required
·
Yes
Yes
Yes
- ·
+ Yes
Yes
Yes
Yes
- Yes
- Yes
- ·
-
- ·
- ·
- ·
- ·
-
-
-
- select()
- ·
- Yes
-
- Yes
- Yes†
- Yes
- Yes†
-
-
-
- Yes†
- Yes†
- ·
- Yes†
- ·
-
- Yes†
- ·
- ·
- ·
-
-
-
- selectionStart
- ·
- Yes
-
- Yes
- ·
- Yes
- ·
-
-
-
- ·
- ·
- ·
- ·
- ·
-
- ·
- ·
- ·
- ·
-
-
-
- selectionEnd
- ·
- Yes
-
- Yes
- ·
- Yes
- ·
-
-
-
- ·
- ·
·
·
- ·
-
- ·
- ·
- ·
- ·
-
-
-
- selectionDirection
- ·
- Yes
-
- Yes
- ·
- Yes
- ·
-
-
-
- ·
- ·
- ·
- ·
- ·
-
- ·
+ Yes
+
+ Yes
·
·
·
- setRangeText()
+ size
·
Yes
Yes
- ·
+ Yes
Yes
·
@@ -46144,13 +45904,13 @@ interface HTMLInputElement : HTMLElement {
- setSelectionRange()
+ src
·
- Yes
-
- Yes
+ ·
+
+ ·
·
- Yes
+ ·
·
@@ -46163,12 +45923,352 @@ interface HTMLInputElement : HTMLElement {
·
·
- ·
+ Yes
·
- stepDown()
+ step
+ ·
+ ·
+
+ ·
+ ·
+ ·
+ Yes
+
+
+
+ Yes
+ Yes
+ Yes
+ ·
+ ·
+
+ ·
+ ·
+ ·
+ ·
+
+
+
+
+ width
+ ·
+ ·
+
+ ·
+ ·
+ ·
+ ·
+
+
+
+ ·
+ ·
+ ·
+ ·
+ ·
+
+ ·
+ ·
+ Yes
+ ·
+
+
+
+ IDL attributes and methods
+
+
+ checked
+ ·
+ ·
+
+ ·
+ ·
+ ·
+ ·
+
+
+
+ ·
+ ·
+ ·
+ ·
+ Yes
+
+ ·
+ ·
+ ·
+ ·
+
+
+
+ files
+ ·
+ ·
+
+ ·
+ ·
+ ·
+ ·
+
+
+
+ ·
+ ·
+ ·
+ ·
+ ·
+
+ Yes
+ ·
+ ·
+ ·
+
+
+
+ value
+ default
+ value
+
+ value
+ value
+ value
+ value
+
+
+
+ value
+ value
+ value
+ value
+ default/on
+
+ filename
+ default
+ default
+ default
+
+
+
+ valueAsDate
+ ·
+ ·
+
+ ·
+ ·
+ ·
+ Yes
+
+
+
+ ·
+ ·
+ ·
+ ·
+ ·
+
+ ·
+ ·
+ ·
+ ·
+
+
+
+ valueAsNumber
+ ·
+ ·
+
+ ·
+ ·
+ ·
+ Yes
+
+
+
+ Yes
+ Yes
+ Yes
+ ·
+ ·
+
+ ·
+ ·
+ ·
+ ·
+
+
+
+ list
+ ·
+ Yes
+
+ Yes
+ Yes
+ ·
+ Yes
+
+
+
+ Yes
+ Yes
+ Yes
+ Yes
+ ·
+
+ ·
+ ·
+ ·
+ ·
+
+
+
+ select()
+ ·
+ Yes
+
+ Yes
+ Yes†
+ Yes
+ Yes†
+
+
+
+ Yes†
+ Yes†
+ ·
+ Yes†
+ ·
+
+ Yes†
+ ·
+ ·
+ ·
+
+
+
+ selectionStart
+ ·
+ Yes
+
+ Yes
+ ·
+ Yes
+ ·
+
+
+
+ ·
+ ·
+ ·
+ ·
+ ·
+
+ ·
+ ·
+ ·
+ ·
+
+
+
+ selectionEnd
+ ·
+ Yes
+
+ Yes
+ ·
+ Yes
+ ·
+
+
+
+ ·
+ ·
+ ·
+ ·
+ ·
+
+ ·
+ ·
+ ·
+ ·
+
+
+
+ selectionDirection
+ ·
+ Yes
+
+ Yes
+ ·
+ Yes
+ ·
+
+
+
+ ·
+ ·
+ ·
+ ·
+ ·
+
+ ·
+ ·
+ ·
+ ·
+
+
+
+ setRangeText()
+ ·
+ Yes
+
+ Yes
+ ·
+ Yes
+ ·
+
+
+
+ ·
+ ·
+ ·
+ ·
+ ·
+
+ ·
+ ·
+ ·
+ ·
+
+
+
+ setSelectionRange()
+ ·
+ Yes
+
+ Yes
+ ·
+ Yes
+ ·
+
+
+
+ ·
+ ·
+ ·
+ ·
+ ·
+
+ ·
+ ·
+ ·
+ ·
+
+
+
+ stepDown()
·
·
@@ -46376,6 +46476,8 @@ interface HTMLInputElement : HTMLElement {
multiple
,
pattern
,
placeholder
,
+ popuphidetarget
,
+ popupshowtarget
,
+ popuptoggletarget
,
readonly
,
required
,
size
,
@@ -46789,6 +46894,9 @@ interface HTMLInputElement : HTMLElement {
max
,
min
,
multiple
,
+ popuphidetarget
,
+ popupshowtarget
,
+ popuptoggletarget
,
src
,
step
, and
width
.max
,
min
,
multiple
,
+ popuphidetarget
,
+ popupshowtarget
,
+ popuptoggletarget
,
src
,
step
, and
width
.
@@ -46993,6 +47104,9 @@ interface HTMLInputElement : HTMLElement {
max
,
min
,
multiple
,
+ popuphidetarget
,
+ popupshowtarget
,
+ popuptoggletarget
,
src
,
step
, and
width
.
@@ -47261,6 +47375,9 @@ ldh-str = < as defined in height,
max
,
min
,
+ popuphidetarget
,
+ popupshowtarget
,
+ popuptoggletarget
,
src
,
step
, and
width
.
@@ -47357,6 +47474,9 @@ ldh-str = < as defined in max,
min
,
multiple
,
+ popuphidetarget
,
+ popupshowtarget
,
+ popuptoggletarget
,
src
,
step
, and
width
.
@@ -47530,6 +47650,9 @@ ldh-str = < as defined in multiple,
pattern
,
placeholder
,
+ popuphidetarget
,
+ popupshowtarget
,
+ popuptoggletarget
,
size
,
src
, and
width
.
@@ -47681,6 +47804,9 @@ ldh-str = < as defined in multiple,
pattern
,
placeholder
,
+ popuphidetarget
,
+ popupshowtarget
,
+ popuptoggletarget
,
size
,
src
, and
width
.
@@ -47836,6 +47962,9 @@ ldh-str = < as defined in multiple,
pattern
,
placeholder
,
+ popuphidetarget
,
+ popupshowtarget
,
+ popuptoggletarget
,
size
,
src
, and
width
.
@@ -47987,6 +48116,9 @@ ldh-str = < as defined in multiple,
pattern
,
placeholder
,
+ popuphidetarget
,
+ popupshowtarget
,
+ popuptoggletarget
,
size
,
src
, and
width
.
@@ -48131,6 +48263,9 @@ ldh-str = < as defined in multiple,
pattern
,
placeholder
,
+ popuphidetarget
,
+ popupshowtarget
,
+ popuptoggletarget
,
size
,
src
, and
width
.
@@ -48293,6 +48428,9 @@ ldh-str = < as defined in minlength,
multiple
,
pattern
,
+ popuphidetarget
,
+ popupshowtarget
,
+ popuptoggletarget
,
size
,
src
, and
width
.
@@ -48563,6 +48701,9 @@ ldh-str = < as defined in multiple,
pattern
,
placeholder
,
+ popuphidetarget
,
+ popupshowtarget
,
+ popuptoggletarget
,
readonly
,
required
,
size
,
@@ -48669,6 +48810,9 @@ ldh-str = < as defined in multiple,
pattern
,
placeholder
,
+ popuphidetarget
,
+ popupshowtarget
,
+ popuptoggletarget
,
readonly
,
required
,
size
,
@@ -48783,6 +48927,9 @@ ldh-str = < as defined in multiple,
pattern
,
placeholder
,
+ popuphidetarget
,
+ popupshowtarget
,
+ popuptoggletarget
,
readonly
,
size
,
src
,
@@ -48958,6 +49105,9 @@ ldh-str = < as defined in multiple,
pattern
,
placeholder
,
+ popuphidetarget
,
+ popupshowtarget
,
+ popuptoggletarget
,
readonly
,
size
,
src
,
@@ -49208,6 +49358,9 @@ ldh-str = < as defined in min,
minlength
,
pattern
,
+ popuphidetarget
,
+ popupshowtarget
,
+ popuptoggletarget
,
placeholder
,
readonly
,
size
,
@@ -49291,9 +49444,12 @@ ldh-str = < as defined in formaction,
formenctype
,
formmethod
,
- formnovalidate
, and
- formtarget
content attributes;
- value
IDL attribute.
+ formnovalidate
,
+ formtarget
,
+ popuphidetarget
,
+ popupshowtarget
, and
+ popuptoggletarget
, content
+ attributes; value
IDL attribute.
value
IDL attribute is in mode default.formtarget
,
height
,
+ popuphidetarget
,
+ popupshowtarget
,
+ popuptoggletarget
,
src
, and
width
content attributes;
value
IDL attribute.
@@ -49682,6 +49841,13 @@ ldh-str = < as defined in applies to this element and is in mode default.
+ input
element content attributes apply to the element:
+ popuphidetarget
,
+ popupshowtarget
, and
+ popuptoggletarget
content
+ attributes.accept
,
@@ -49762,6 +49928,13 @@ ldh-str = < as defined in applies to this element and is in mode default.input
element content attributes apply to the element:
+ popuphidetarget
,
+ popupshowtarget
, and
+ popuptoggletarget
content
+ attributes.accept
,
@@ -51340,6 +51513,9 @@ You cannot submit this form when the field is incorrect.
formnovalidate
formtarget
name
popuphidetarget
popupshowtarget
popuptoggletarget
type
value
HTMLButtonElement
.type
attribute's state:type
attribute's state, then:
:open
:open
pseudo-class is defined to match
+ any element whose popup
attribute not in the no pop-up state and whose pop-up visibility
+ state is showing.:enabled
:enabled
pseudo-class must match any
@@ -77124,9 +77311,28 @@ partial interface {
focus target be null.focus
at focus event target, with
- related focus target as the related target.
+
+
focus
at focus event target, with
+ related focus target as the related target.
+
+ inclusive
".area
element's shape, a scrollable region, or a viewport, no event is fired.FocusEvent
, with the r, return the result of firing an
+ event named e at t, using
FocusEvent
, with the relatedTarget
attribute initialized to r,
- the view
attribute initialized to t's
- node document's relevant global object, and the composed
- flag set.view
attribute initialized to t's node
+ document's relevant global object, and the composed flag set.
@@ -77589,15 +77794,22 @@ partial interface {
autofocus
content attribute allows the author to indicate that an element is to be focused as soon as the
- page is loaded or as soon as the dialog
within which it finds itself is shown,
- allowing the user to just start typing without having to manually focus the main element.autofocus
attribute is specified on an element
+ inside dialog
elements or elements whose popup
+ attribute is set, then it will be focused when the dialog or pop-up becomes shown.autofocus
attribute is a boolean
attribute.dialog
element, or else is the element's nearest ancestor
- dialog
element, if any, or else is the element's last inclusive ancestor
+ if the element is a dialog
or has the popup
+ attribute not in the no pop-up state, or else is the
+ element's nearest ancestor dialog
or element whose popup
attribute is not in the no
+ pop-up state, if any, or else is the element's last inclusive ancestor
element.The
+
+ popup
attributepopup
content attribute set. When specified, the element won't be
+ rendered until it becomes shown, at which point it will be rendered on top of other page
+ content.popup
attribute is an enumerated attribute.
+ The following table lists the states for this attribute:
+
+
+
+
+
+ State
+ Keywords
+ Description
+
+ Auto state
+ auto
+ Closes other pop-ups when opened; has light
+ dismiss.
+
+ The empty string
+
+ Hint state
+ hint
+ Closes other hint pop-ups when opened; has light
+ dismiss.
+
+ Manual state
+ manual
+ Does not close other pop-ups; does not light
+ dismiss.
+ popUp
IDL attribute
+ must reflect the popup attribute.popup
attribute is not set on an element, then the
+ element's popup
attribute is considered to be in the no pop-up state.
+
+
+ :open
pseudo selectors exist to allow pop-ups to animate open or
+ closed because animating between display: none
and other
+ 'display' values is not possible.
+ <div popup="auto" id="foo">
+ A fancy pop-up with no Javascript
+</div>
+<style>
+ [popup] {
+ opacity: 0;
+ transform: translate(-100px,100px);
+ transition: all 1.5s;
+ }
+ [popup]:open {
+ transform: translate(0,0);
+ opacity: 1;
+ }
+</style>
Document
has an auto pop-up stack, which is a stack,
+ initially empty.Document
has a currently-showing hint pop-up, which is an
+ Element
or null, initially null.Document
has pop-ups waiting to hide, which is a set,
+ initially empty.Document
has a pop-up mousedown target, which is an
+ Element
or null, initially null.
+
+
+ Element
or null,
+ initially set to null.Element
or null, initially set to
+ null.popup
attribute:
+
+
+ popup
, then
+ return.
+
+
+ element.showPopUp()
popup
attribute is in the auto state or hint
+ state, then this will also close all other auto and hint
+ pop-ups unless they are an ancestor of element according to the nearest open
+ ancestral pop-up algorithm.element.hidePopUp()
display: none
to it.showPopUp()
method steps
+ are:
+
+
+ Element
element:
+
+
+ popup
attribute is in the no pop-up state, then throw a
+ "NotSupportedError
" DOMException
.InvalidStateError
" DOMException
.InvalidStateError
" DOMException
.popupshow
at element is false, then return.popup
attribute is in the no pop-up state, then return.popupshow
event could have disconnected this element or changed
+ its popup
attribute.popup
attribute is in the hint state, then:
+
+ new-pop-up
".popup
attribute is in the auto state, then:
+
+ new-pop-up
".popup
attribute is in the auto state or in the hint state, then:
+
+ popup
attribute is in the no pop-up state, then return.popuphide
event, and an event handler could have
+ disconnected this element or changed its popup
+ attribute.popup
attribute is in the auto state, then push element onto
+ document's auto pop-up stack.popup
attribute is in the hint state, then set document's
+ currently-showing hint pop-up to element.popup
attribute is not in the no
+ pop-up state, and originallyFocusedElement is not the focused
+ element, then set element's pop-up previously focused element to
+ originallyFocusedElement.hidePopUp()
method steps
+ are:
+
+
+ popup
attribute is in the no pop-up state, then throw a
+ "NotSupportedError
" DOMException
.InvalidStateError
" DOMException
.Element
+ element, a boolean focusPreviousElement, and a boolean
+ hideImmediately:
+
+
+ popup
attribute is in the auto state or the hint state, then:
+
+ popup
attribute is in the no pop-up state, then return.popuphide
event, and an event handler could have
+ disconnected this element or changed its popup
+ attribute.popup
attribute is in the auto state, then pop from
+ document's auto pop-up stack.popup
attribute is in the hint state, then set document's
+ currently-showing hint pop-up to null.Animation
objects that contain at least one
+ animation effect whose effect target is element.
+
+ popuphide
at element.popuphide
at element.popup
attribute is in the no pop-up state, then return.Animation
objects that contain at least one
+ animation effect whose effect target is element.
+
+
+
+ Element
element:
+
+
+ Element
endpoint, a boolean focusPreviousElement, a boolean
+ hideImmediately, and a boolean hideUnrelated:
+
+
+
+
+
+
+ popup
attribute is in the hint state and hideUnrelated is true, then:
+
+
+
+ popup
attribute is in the auto state or endpoint is null, then:
+
+
+
+ default
"
+
+ popup=auto
and
+ popup=hint
is captured here, where a popup=hint
that is
+ "nested" inside a popup=auto
is only hidden at the appropriate time.Node
node and a string ancestorType, perform the
+ following steps. They return an Element
or null.
+
+
+
+
+
+
+
+
+
+
+ new-pop-up
", then:
+
+ new-pop-up
", then set upperBound to
+ popUpPositions[hintShowing].inclusive
", then:
+
+
+
+ popup
attribute is not in
+ the no pop-up state and currentNode's
+ pop-up visibility state is showing
+ and currentNode's popup
attribute is not in the
+ manual state, then:
+
+ popup
attribute is not
+ null and targetPopUp's pop-up visibility state is showing and targetPopUp's popup
attribute is not in the manual state, then:
+
+ Node
node, a map
+ popUpPositions, a map anchorsToPopUps, an integer upperBound,
+ and a set seen, perform the following steps. They return an
+ Element
or null.
+
+
+
+
+ popup
attribute is not in the manual state, then:
+
+
+
+
+
+
+
+ Element
element, perform the following steps. They return an
+ Element
or null.
+
+
+ popup
attribute is in the no pop-up state, then return null.Document
document, perform the following steps. They return an
+ Element
or null.
+
+
+ Element
+ subject:
+
+
+ Element
or null.
+
+
+ autofocus
attribute,
+ then return subject.
+
+ dialog
element or node's popup
attribute is not in the no pop-up state, then continue without traversing into
+ the child nodes of node.autofocus
+ attribute, then continue.The pop-up target attributes
+
+
+
+
+ popuptoggletarget
popuphidetarget
popupshowtarget
popup
attribute. If a pop-up target attribute is
+ specified, then that attribute's value must be the ID of element with the popup
attribute.popupshowtarget
can be
+ used to open a pop-up:
+
+ <div popup=auto id="foo">
+ This is a pop-up!
+</div>
+
+<button popupshowtarget="foo">
+ Show a pop-up
+</button>
popuptoggletarget
can
+ open and close a manual pop-up, which can't be closed with light dismiss:
+ <div popup=manual id="foo">
+ This is a pop-up!
+</div>
+
+<button popuptoggletarget="foo">
+ Show or hide a pop-up
+</button>
+
+
+ DOM interface:
+ button
elementsinput
elements in the Button
+ state.input
elements in the Submit
+ Button state.input
elements in the Image
+ Button state.input
elements in the Reset
+ Button state.
+
+ interface mixin PopUpTargetElement {
+ [CEReactions] attribute DOMString? popUpToggleTarget;
+ [CEReactions] attribute DOMString? popUpHideTarget;
+ [CEReactions] attribute DOMString? popUpShowTarget;
+};
popUpToggleTarget
IDL attribute must
+ reflect the popuptoggletarget
+ attribute.popUpHideTarget
IDL attribute must reflect
+ the popuphidetarget
attribute.popUpShowTarget
IDL attribute must reflect
+ the popupshowtarget
attribute.Node
+ node:
+
+
+ popuptoggletarget
attribute, then:
+
+ popupshowtarget
+ attribute and popUp's pop-up visibility state is showing, then return.popuphidetarget
+ attribute and popUp's pop-up visibility state is hidden, then return.popupshowtarget
attribute and node doesn't
+ have the popuphidetarget
attribute, then
+ return.
+
+ button
element in the submit state.input
element in the submit state.input
element in the image state.
+
+ Node
node, perform
+ the following steps. They return an Element
or null.
+
+
+ popuptoggletarget
attribute, then set idref
+ to the value of node's popuptoggletarget
attribute.popupshowtarget
attribute, then set idref to
+ the value of node's popupshowtarget
+ attribute.popuphidetarget
attribute, then set idref to
+ the value of node's popuphidetarget
+ attribute.popup
attribute is in the
+ no pop-up state, then return null.Pop-up light dismiss
+
+ popup
attribute is in the auto or hint
+ states will close the pop-up.Document
document receives an Event
+ event in the capture phase:
+
+
+ mousedown
event, then:
+
+ inclusive
".mouseup
event, then:
+
+ inclusive
".keydown
event for the
+ Escape key, then:
+
+ The
+
+ defaultopen
attributedefaultopen
content attribute set. When specified on an
+ element whose popup
attribute is not in the no pop-up state, it makes the element shown automatically
+ when the page is loaded. defaultopen
is a boolean
+ attribute.defaultOpen
+ IDL attribute must reflect the defaultopen
+ content attribute.Loading web pages
@@ -98271,6 +99601,8 @@ typedef OnBeforeUnloadEventHandlerNonNull? OnBeforeUnl
onseeked
seeked
onseeking
seeking
onselect
select
+ onpopuphide
popuphide
+ onpopupshow
popupshow
onslotchange
slotchange
onstalled
stalled
onsubmit
submit
@@ -113102,6 +114434,40 @@ dictionary StorageEventInit : EventInit {
element is dropped on the floor.
+ defaultopen
attribute
+ set, then:
+
+
+
+ popup
attribute is in the
+ no pop-up state, then abort these steps.popup
attribute is in the
+ hint state, then abort these steps.popup
attribute is in the auto state and element's node
+ document's auto pop-up stack is not empty, then abort these steps.popup
attribute set whose pop-up
+ visibility state is hidden are expected to act as
+ if they had a user-agent-level style sheet rule setting their 'display' property set
+ to 'none'.Phrasing content
@namespace url(http://www.w3.org/1999/xhtml);
@@ -121816,7 +123207,6 @@ if (s = prompt('What is your name?')) {
label
on menu
elementscontextmenu
on all elementsonshow
on all elementscontextmenu
event. track
Enable the track if no other text track is more suitable
Boolean attribute
+
+ defaultopen
+ HTML elements
+ Makes pop-up elements automatically open on page load
+ Boolean attribute
defer
script
@@ -126391,6 +127786,31 @@ interface External {
video
Encourage the user agent to display video content within the element's playback area
Boolean attribute
+
+ popup
+ HTML elements
+ Makes the element a pop-up element
+ " auto
";
+ "hint
";
+ "manual
";
+
+ popuphidetarget
+ input
;
+ button
+ Hides the specified pop-up element when clicked
+ Id of the element to hide
+
+ popupshowtarget
+ input
;
+ button
+ Shows the specified pop-up element when clicked
+ Id of the element to show
+
+ popuptoggletarget
+ input
;
+ button
+ Toggles the specified pop-up element when clicked
+ Id of the element to toggle
poster
video
@@ -127107,6 +128527,18 @@ interface External {
popstate
event handler for Window
object
Event handler content attribute
+
+ onpopuphide
+ HTML elements
+ popuphide
event handler
+ Event handler content attribute
+
+
+ onpopupshow
+ HTML elements
+ popupshow
event handler
+ Event handler content attribute
+
onprogress
HTML elements
@@ -127911,6 +129343,18 @@ INSERT INTERFACES HERE
Window
Fired at the Window
when the user navigates the session history
+
+ popuphide
+ Event
+ Elements
+ Fired on an element with the popup
attribute when it is hidden.
+
+
+ popupshow
+ Event
+ Elements
+ Fired on an element with the popup
attribute when it is shown.
+
readystatechange
Event