66type DOMString = string ;
77
88interface EditContext extends EventTarget {
9-
109 updateText ( rangeStart : number , rangeEnd : number , text : DOMString ) : void ;
1110 updateSelection ( start : number , end : number ) : void ;
1211 updateControlBounds ( controlBounds : DOMRect ) : void ;
@@ -36,10 +35,32 @@ interface EditContext extends EventTarget {
3635 get oncompositionend ( ) : EventHandler | null ;
3736 set oncompositionend ( value : EventHandler | null ) ;
3837
39- addEventListener < K extends keyof EditContextEventHandlersEventMap > ( type : K , listener : ( this : GlobalEventHandlers , ev : EditContextEventHandlersEventMap [ K ] ) => any , options ?: boolean | AddEventListenerOptions ) : void ;
40- addEventListener ( type : string , listener : EventListenerOrEventListenerObject , options ?: boolean | AddEventListenerOptions ) : void ;
41- removeEventListener < K extends keyof EditContextEventHandlersEventMap > ( type : K , listener : ( this : GlobalEventHandlers , ev : EditContextEventHandlersEventMap [ K ] ) => any , options ?: boolean | EventListenerOptions ) : void ;
42- removeEventListener ( type : string , listener : EventListenerOrEventListenerObject , options ?: boolean | EventListenerOptions ) : void ;
38+ addEventListener < K extends keyof EditContextEventHandlersEventMap > (
39+ type : K ,
40+ listener : (
41+ this : GlobalEventHandlers ,
42+ ev : EditContextEventHandlersEventMap [ K ] ,
43+ ) => any ,
44+ options ?: boolean | AddEventListenerOptions ,
45+ ) : void ;
46+ addEventListener (
47+ type : string ,
48+ listener : EventListenerOrEventListenerObject ,
49+ options ?: boolean | AddEventListenerOptions ,
50+ ) : void ;
51+ removeEventListener < K extends keyof EditContextEventHandlersEventMap > (
52+ type : K ,
53+ listener : (
54+ this : GlobalEventHandlers ,
55+ ev : EditContextEventHandlersEventMap [ K ] ,
56+ ) => any ,
57+ options ?: boolean | EventListenerOptions ,
58+ ) : void ;
59+ removeEventListener (
60+ type : string ,
61+ listener : EventListenerOrEventListenerObject ,
62+ options ?: boolean | EventListenerOptions ,
63+ ) : void ;
4364}
4465
4566interface EditContextInit {
@@ -59,7 +80,7 @@ interface EditContextEventHandlersEventMap {
5980type EventHandler < TEvent extends Event = Event > = ( event : TEvent ) => void ;
6081
6182interface TextUpdateEvent extends Event {
62- new ( type : DOMString , options ?: TextUpdateEventInit ) : TextUpdateEvent ;
83+ new ( type : DOMString , options ?: TextUpdateEventInit ) : TextUpdateEvent ;
6384
6485 readonly updateRangeStart : number ;
6586 readonly updateRangeEnd : number ;
@@ -79,7 +100,7 @@ interface TextUpdateEventInit extends EventInit {
79100}
80101
81102interface TextFormat {
82- new ( options ?: TextFormatInit ) : TextFormat ;
103+ new ( options ?: TextFormatInit ) : TextFormat ;
83104
84105 readonly rangeStart : number ;
85106 readonly rangeEnd : number ;
@@ -94,11 +115,14 @@ interface TextFormatInit {
94115 underlineThickness : UnderlineThickness ;
95116}
96117
97- type UnderlineStyle = ' none' | ' solid' | ' dotted' | ' dashed' | ' wavy' ;
98- type UnderlineThickness = ' none' | ' thin' | ' thick' ;
118+ type UnderlineStyle = " none" | " solid" | " dotted" | " dashed" | " wavy" ;
119+ type UnderlineThickness = " none" | " thin" | " thick" ;
99120
100121interface TextFormatUpdateEvent extends Event {
101- new ( type : DOMString , options ?: TextFormatUpdateEventInit ) : TextFormatUpdateEvent ;
122+ new (
123+ type : DOMString ,
124+ options ?: TextFormatUpdateEventInit ,
125+ ) : TextFormatUpdateEvent ;
102126 getTextFormats ( ) : TextFormat [ ] ;
103127}
104128
@@ -107,7 +131,10 @@ interface TextFormatUpdateEventInit extends EventInit {
107131}
108132
109133interface CharacterBoundsUpdateEvent extends Event {
110- new ( type : DOMString , options ?: CharacterBoundsUpdateEventInit ) : CharacterBoundsUpdateEvent ;
134+ new (
135+ type : DOMString ,
136+ options ?: CharacterBoundsUpdateEventInit ,
137+ ) : CharacterBoundsUpdateEvent ;
111138
112139 readonly rangeStart : number ;
113140 readonly rangeEnd : number ;
0 commit comments