From c422734d44ae9897c1700daf08bd415e0dc5f9e1 Mon Sep 17 00:00:00 2001
From: Domenic Denicola
Date: Tue, 21 Feb 2017 16:11:13 -0500
Subject: [PATCH] Tweak [CEReactions] definition and usage
This fixes #2362, by:
* Making it clearer that the steps inserted by [CEReactions] apply
before/after what Web IDL calls "the actions listed in the description
of" a given construct.
* Removing [CEReactions] from [PutForwards]-decorated readonly
attributes, as it is redundant there.
---
source | 23 +++++++++++------------
1 file changed, 11 insertions(+), 12 deletions(-)
diff --git a/source b/source
index c1446d7b076..c8c1e764aee 100644
--- a/source
+++ b/source
@@ -9209,7 +9209,7 @@ interface HTMLElement : Element {
[CEReactions] attribute DOMString accessKey;
readonly attribute DOMString accessKeyLabel;
[CEReactions] attribute boolean draggable;
- [CEReactions, SameObject, PutForwards=value] readonly attribute DOMTokenList dropzone;
+ [SameObject, PutForwards=value] readonly attribute DOMTokenList dropzone;
[CEReactions] attribute HTMLMenuElement? contextMenu;
[CEReactions] attribute boolean spellcheck;
void forceSpellCheck();
@@ -12266,13 +12266,13 @@ interface HTMLLinkElement : HTMLElement {
[CEReactions] attribute DOMString? crossOrigin;
[CEReactions] attribute DOMString rel;
[CEReactions] attribute RequestDestination as; // (default "")
- [CEReactions, SameObject, PutForwards=value] readonly attribute DOMTokenList relList;
+ [SameObject, PutForwards=value] readonly attribute DOMTokenList relList;
[CEReactions] attribute DOMString media;
[CEReactions] attribute DOMString nonce;
[CEReactions] attribute DOMString integrity;
[CEReactions] attribute DOMString hreflang;
[CEReactions] attribute DOMString type;
- [CEReactions, SameObject, PutForwards=value] readonly attribute DOMTokenList sizes;
+ [SameObject, PutForwards=value] readonly attribute DOMTokenList sizes;
[CEReactions] attribute DOMString referrerPolicy;
[CEReactions] attribute USVString scope;
[CEReactions] attribute WorkerType workerType;
@@ -18464,7 +18464,7 @@ interface HTMLAnchorElement : HTMLElement {
[CEReactions] attribute DOMString download;
[CEReactions] attribute USVString ping;
[CEReactions] attribute DOMString rel;
- [CEReactions, SameObject, PutForwards=value] readonly attribute DOMTokenList relList;
+ [SameObject, PutForwards=value] readonly attribute DOMTokenList relList;
[CEReactions] attribute DOMString hreflang;
[CEReactions] attribute DOMString type;
@@ -28095,7 +28095,7 @@ interface HTMLIFrameElement : HTMLElement {
[CEReactions] attribute USVString src;
[CEReactions] attribute DOMString srcdoc;
[CEReactions] attribute DOMString name;
- [CEReactions, SameObject, PutForwards=value] readonly attribute DOMTokenList sandbox;
+ [SameObject, PutForwards=value] readonly attribute DOMTokenList sandbox;
[CEReactions] attribute boolean allowFullscreen;
[CEReactions] attribute boolean allowPaymentRequest;
[CEReactions] attribute boolean allowUserMedia;
@@ -37419,7 +37419,7 @@ interface HTMLAreaElement : HTMLElement {
[CEReactions] attribute DOMString download;
[CEReactions] attribute USVString ping;
[CEReactions] attribute DOMString rel;
- [CEReactions, SameObject, PutForwards=value] readonly attribute DOMTokenList relList;
+ [SameObject, PutForwards=value] readonly attribute DOMTokenList relList;
[CEReactions] attribute DOMString referrerPolicy;
};
HTMLAreaElement implements HTMLHyperlinkElementUtils;
@@ -50095,7 +50095,7 @@ Daddy"></textarea>
[HTMLConstructor]
interface HTMLOutputElement : HTMLElement {
- [CEReactions, SameObject, PutForwards=value] readonly attribute DOMTokenList htmlFor;
+ [SameObject, PutForwards=value] readonly attribute DOMTokenList htmlFor;
readonly attribute HTMLFormElement? form;
[CEReactions] attribute DOMString name;
@@ -66682,20 +66682,19 @@ customElements.define("x-foo", class extends HTMLElement {
The [CEReactions]
extended attribute must take no
arguments, and must not appear on anything other than an operation, attribute, setter, or deleter.
- Additionally, it must not appear on readonly attributes, unless the readonly attribute is also
- annotated with [PutForwards]
.
+ Additionally, it must not appear on readonly attributes.
Operations, attributes, setters, or deleters annotated with the [CEReactions]
extended attribute must run the following steps
- surrounding the main algorithm specified for the operation, setter, deleter, or for the
+ surrounding the actions listed in the description of the operation, setter, deleter, or the
attribute's setter:
- - Before executing the algorithm's steps
+ - Before executing the listed actions
- Push a new element queue onto the custom element reactions
stack.
- - After executing the algorithm's steps
+ - After executing the listed actions
- Pop the element queue from the custom element reactions stack, and
invoke custom element reactions in that queue.