From 78a46aa008f463613c8a55d525efe28a9ea46947 Mon Sep 17 00:00:00 2001 From: Simon Pieters Date: Fri, 24 Nov 2023 01:02:48 +0100 Subject: [PATCH] Specify the textInput event Fixes #353 --- sections/legacy-event-types.txt | 113 ++++++++++++++++++++++++++++++++ 1 file changed, 113 insertions(+) diff --git a/sections/legacy-event-types.txt b/sections/legacy-event-types.txt index fcacea4..1a615c4 100644 --- a/sections/legacy-event-types.txt +++ b/sections/legacy-event-types.txt @@ -51,6 +51,7 @@ completeness. +| keypress | Sync | Yes | Element | KeyboardEvent | Yes | Yes | Varies: launch text composition system; | | | | | | | | | EVENT{blur} and EVENT{focus} events; | | | | | | | | | EVENT{DOMActivate} event; other event | ++| textInput | Sync | Yes | Element | TextEvent | Yes | Yes | EVENT{input} event | ++-----------------------------+--------+----------+------------------------------------------+------------------+------------+------------+------------------------------------------------+ @@ -517,6 +518,118 @@ completeness. ++---+-------------+------------------------+---------------------+--------------------------------+ +

Legacy {{TextEvent}} events

+ +

Interface TextEvent

+ + +
+	[Exposed=Window]
+	interface TextEvent : Event {
+		readonly attribute DOMString data;
+		void initTextEvent(DOMString type,
+			optional boolean bubbles = false,
+			optional boolean cancelable = false,
+			optional Window? view = null,
+			optional DOMString data = "undefined");
+	};
+	
+ +
+
data
+
+ data holds the value of the characters generated by + an input method. This MAY be a single Unicode character or a + non-empty sequence of Unicode characters [[Unicode]]. Characters + SHOULD be normalized as defined by the Unicode normalization + form NFC, defined in [[UAX15]]. This + attribute MAY be the empty string. + + The un-initialized value of this attribute MUST be + "" (the empty string). +
+ +
initTextEvent(typeArg)
+
+ Initializes attributes of a TextEvent object. + This method has the same behavior as {{Event/initEvent()}}. + +
+
DOMString typeArg
+
+ Refer to the {{Event/initEvent()}} method for a description of this parameter. +
+ +
boolean bubblesArg
+
+ Refer to the {{Event/initEvent()}} method for a description of this parameter. +
+ +
boolean cancelableArg
+
+ Refer to the {{Event/initEvent()}} method for a description of this parameter. +
+ +
Window? view
+
+ Specifies {{UIEvent/view}}. This value MAY be null. +
+
+
+
+ +

Legacy {{TextEvent}} event types

+ +
textInput
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
TypetextInput
Interface{{TextEvent}}
Sync / AsyncSync
BubblesYes
Trusted TargetsElement
CancelableYes
ComposedYes
Default action + EVENT{input} event
Context
(trusted events)
+
    +
  • Issue: TODO
  • +
+
+ + If supported by a user agent, this event MUST be dispatched + as the default action of a EVENT{beforeinput} event. + +

Legacy {{MutationEvent}} events

The mutation and mutation name event modules are designed to allow