@joist/element 3.2.1 → 3.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/target/lib/element.d.ts +48 -45
package/package.json
CHANGED
package/target/lib/element.d.ts
CHANGED
|
@@ -24,11 +24,11 @@ export declare function element<Target extends CustomElementConstructor>(Base: T
|
|
|
24
24
|
click(): void;
|
|
25
25
|
hidePopover(): void;
|
|
26
26
|
showPopover(): void;
|
|
27
|
-
togglePopover(force?: boolean
|
|
28
|
-
addEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions
|
|
29
|
-
addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions
|
|
30
|
-
removeEventListener<
|
|
31
|
-
removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions
|
|
27
|
+
togglePopover(force?: boolean): boolean;
|
|
28
|
+
addEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
|
|
29
|
+
addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
|
|
30
|
+
removeEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
|
|
31
|
+
removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
|
|
32
32
|
disconnectedCallback?(): void;
|
|
33
33
|
readonly attributes: NamedNodeMap;
|
|
34
34
|
readonly classList: DOMTokenList;
|
|
@@ -54,10 +54,10 @@ export declare function element<Target extends CustomElementConstructor>(Base: T
|
|
|
54
54
|
slot: string;
|
|
55
55
|
readonly tagName: string;
|
|
56
56
|
attachShadow(init: ShadowRootInit): ShadowRoot;
|
|
57
|
-
checkVisibility(options?: CheckVisibilityOptions
|
|
58
|
-
closest<
|
|
59
|
-
closest<
|
|
60
|
-
closest<
|
|
57
|
+
checkVisibility(options?: CheckVisibilityOptions): boolean;
|
|
58
|
+
closest<K extends keyof HTMLElementTagNameMap>(selector: K): HTMLElementTagNameMap[K] | null;
|
|
59
|
+
closest<K extends keyof SVGElementTagNameMap>(selector: K): SVGElementTagNameMap[K] | null;
|
|
60
|
+
closest<K extends keyof MathMLElementTagNameMap>(selector: K): MathMLElementTagNameMap[K] | null;
|
|
61
61
|
closest<E extends Element = Element>(selectors: string): E | null;
|
|
62
62
|
computedStyleMap(): StylePropertyMapReadOnly;
|
|
63
63
|
getAttribute(qualifiedName: string): string | null;
|
|
@@ -68,10 +68,10 @@ export declare function element<Target extends CustomElementConstructor>(Base: T
|
|
|
68
68
|
getBoundingClientRect(): DOMRect;
|
|
69
69
|
getClientRects(): DOMRectList;
|
|
70
70
|
getElementsByClassName(classNames: string): HTMLCollectionOf<Element>;
|
|
71
|
-
getElementsByTagName<
|
|
72
|
-
getElementsByTagName<
|
|
73
|
-
getElementsByTagName<
|
|
74
|
-
getElementsByTagName<
|
|
71
|
+
getElementsByTagName<K extends keyof HTMLElementTagNameMap>(qualifiedName: K): HTMLCollectionOf<HTMLElementTagNameMap[K]>;
|
|
72
|
+
getElementsByTagName<K extends keyof SVGElementTagNameMap>(qualifiedName: K): HTMLCollectionOf<SVGElementTagNameMap[K]>;
|
|
73
|
+
getElementsByTagName<K extends keyof MathMLElementTagNameMap>(qualifiedName: K): HTMLCollectionOf<MathMLElementTagNameMap[K]>;
|
|
74
|
+
getElementsByTagName<K extends keyof HTMLElementDeprecatedTagNameMap>(qualifiedName: K): HTMLCollectionOf<HTMLElementDeprecatedTagNameMap[K]>;
|
|
75
75
|
getElementsByTagName(qualifiedName: string): HTMLCollectionOf<Element>;
|
|
76
76
|
getElementsByTagNameNS(namespaceURI: "http://www.w3.org/1999/xhtml", localName: string): HTMLCollectionOf<HTMLElement>;
|
|
77
77
|
getElementsByTagNameNS(namespaceURI: "http://www.w3.org/2000/svg", localName: string): HTMLCollectionOf<SVGElement>;
|
|
@@ -89,21 +89,22 @@ export declare function element<Target extends CustomElementConstructor>(Base: T
|
|
|
89
89
|
removeAttribute(qualifiedName: string): void;
|
|
90
90
|
removeAttributeNS(namespace: string | null, localName: string): void;
|
|
91
91
|
removeAttributeNode(attr: Attr): Attr;
|
|
92
|
-
requestFullscreen(options?: FullscreenOptions
|
|
92
|
+
requestFullscreen(options?: FullscreenOptions): Promise<void>;
|
|
93
93
|
requestPointerLock(): void;
|
|
94
|
-
scroll(options?: ScrollToOptions
|
|
94
|
+
scroll(options?: ScrollToOptions): void;
|
|
95
95
|
scroll(x: number, y: number): void;
|
|
96
|
-
scrollBy(options?: ScrollToOptions
|
|
96
|
+
scrollBy(options?: ScrollToOptions): void;
|
|
97
97
|
scrollBy(x: number, y: number): void;
|
|
98
|
-
scrollIntoView(arg?: boolean | ScrollIntoViewOptions
|
|
99
|
-
scrollTo(options?: ScrollToOptions
|
|
98
|
+
scrollIntoView(arg?: boolean | ScrollIntoViewOptions): void;
|
|
99
|
+
scrollTo(options?: ScrollToOptions): void;
|
|
100
100
|
scrollTo(x: number, y: number): void;
|
|
101
101
|
setAttribute(qualifiedName: string, value: string): void;
|
|
102
102
|
setAttributeNS(namespace: string | null, qualifiedName: string, value: string): void;
|
|
103
103
|
setAttributeNode(attr: Attr): Attr | null;
|
|
104
104
|
setAttributeNodeNS(attr: Attr): Attr | null;
|
|
105
|
+
setHTMLUnsafe(html: string): void;
|
|
105
106
|
setPointerCapture(pointerId: number): void;
|
|
106
|
-
toggleAttribute(qualifiedName: string, force?: boolean
|
|
107
|
+
toggleAttribute(qualifiedName: string, force?: boolean): boolean;
|
|
107
108
|
webkitMatchesSelector(selectors: string): boolean;
|
|
108
109
|
readonly baseURI: string;
|
|
109
110
|
readonly childNodes: NodeListOf<ChildNode>;
|
|
@@ -119,20 +120,20 @@ export declare function element<Target extends CustomElementConstructor>(Base: T
|
|
|
119
120
|
readonly previousSibling: ChildNode | null;
|
|
120
121
|
textContent: string | null;
|
|
121
122
|
appendChild<T extends Node>(node: T): T;
|
|
122
|
-
cloneNode(deep?: boolean
|
|
123
|
+
cloneNode(deep?: boolean): Node;
|
|
123
124
|
compareDocumentPosition(other: Node): number;
|
|
124
125
|
contains(other: Node | null): boolean;
|
|
125
|
-
getRootNode(options?: GetRootNodeOptions
|
|
126
|
+
getRootNode(options?: GetRootNodeOptions): Node;
|
|
126
127
|
hasChildNodes(): boolean;
|
|
127
|
-
insertBefore<
|
|
128
|
+
insertBefore<T extends Node>(node: T, child: Node | null): T;
|
|
128
129
|
isDefaultNamespace(namespace: string | null): boolean;
|
|
129
130
|
isEqualNode(otherNode: Node | null): boolean;
|
|
130
131
|
isSameNode(otherNode: Node | null): boolean;
|
|
131
132
|
lookupNamespaceURI(prefix: string | null): string | null;
|
|
132
133
|
lookupPrefix(namespace: string | null): string | null;
|
|
133
134
|
normalize(): void;
|
|
134
|
-
removeChild<
|
|
135
|
-
replaceChild<
|
|
135
|
+
removeChild<T extends Node>(child: T): T;
|
|
136
|
+
replaceChild<T extends Node>(node: Node, child: T): T;
|
|
136
137
|
readonly ELEMENT_NODE: 1;
|
|
137
138
|
readonly ATTRIBUTE_NODE: 2;
|
|
138
139
|
readonly TEXT_NODE: 3;
|
|
@@ -154,6 +155,8 @@ export declare function element<Target extends CustomElementConstructor>(Base: T
|
|
|
154
155
|
dispatchEvent(event: Event): boolean;
|
|
155
156
|
ariaAtomic: string | null;
|
|
156
157
|
ariaAutoComplete: string | null;
|
|
158
|
+
ariaBrailleLabel: string | null;
|
|
159
|
+
ariaBrailleRoleDescription: string | null;
|
|
157
160
|
ariaBusy: string | null;
|
|
158
161
|
ariaChecked: string | null;
|
|
159
162
|
ariaColCount: string | null;
|
|
@@ -191,12 +194,12 @@ export declare function element<Target extends CustomElementConstructor>(Base: T
|
|
|
191
194
|
ariaValueNow: string | null;
|
|
192
195
|
ariaValueText: string | null;
|
|
193
196
|
role: string | null;
|
|
194
|
-
animate(keyframes:
|
|
195
|
-
getAnimations(options?: GetAnimationsOptions
|
|
196
|
-
after(...nodes: (
|
|
197
|
-
before(...nodes: (
|
|
197
|
+
animate(keyframes: Keyframe[] | PropertyIndexedKeyframes | null, options?: number | KeyframeAnimationOptions): Animation;
|
|
198
|
+
getAnimations(options?: GetAnimationsOptions): Animation[];
|
|
199
|
+
after(...nodes: (Node | string)[]): void;
|
|
200
|
+
before(...nodes: (Node | string)[]): void;
|
|
198
201
|
remove(): void;
|
|
199
|
-
replaceWith(...nodes: (
|
|
202
|
+
replaceWith(...nodes: (Node | string)[]): void;
|
|
200
203
|
innerHTML: string;
|
|
201
204
|
readonly nextElementSibling: Element | null;
|
|
202
205
|
readonly previousElementSibling: Element | null;
|
|
@@ -204,19 +207,19 @@ export declare function element<Target extends CustomElementConstructor>(Base: T
|
|
|
204
207
|
readonly children: HTMLCollection;
|
|
205
208
|
readonly firstElementChild: Element | null;
|
|
206
209
|
readonly lastElementChild: Element | null;
|
|
207
|
-
append(...nodes: (
|
|
208
|
-
prepend(...nodes: (
|
|
209
|
-
querySelector<
|
|
210
|
-
querySelector<
|
|
211
|
-
querySelector<
|
|
212
|
-
querySelector<
|
|
213
|
-
querySelector<
|
|
214
|
-
querySelectorAll<
|
|
215
|
-
querySelectorAll<
|
|
216
|
-
querySelectorAll<
|
|
217
|
-
querySelectorAll<
|
|
218
|
-
querySelectorAll<
|
|
219
|
-
replaceChildren(...nodes: (
|
|
210
|
+
append(...nodes: (Node | string)[]): void;
|
|
211
|
+
prepend(...nodes: (Node | string)[]): void;
|
|
212
|
+
querySelector<K extends keyof HTMLElementTagNameMap>(selectors: K): HTMLElementTagNameMap[K] | null;
|
|
213
|
+
querySelector<K extends keyof SVGElementTagNameMap>(selectors: K): SVGElementTagNameMap[K] | null;
|
|
214
|
+
querySelector<K extends keyof MathMLElementTagNameMap>(selectors: K): MathMLElementTagNameMap[K] | null;
|
|
215
|
+
querySelector<K extends keyof HTMLElementDeprecatedTagNameMap>(selectors: K): HTMLElementDeprecatedTagNameMap[K] | null;
|
|
216
|
+
querySelector<E extends Element = Element>(selectors: string): E | null;
|
|
217
|
+
querySelectorAll<K extends keyof HTMLElementTagNameMap>(selectors: K): NodeListOf<HTMLElementTagNameMap[K]>;
|
|
218
|
+
querySelectorAll<K extends keyof SVGElementTagNameMap>(selectors: K): NodeListOf<SVGElementTagNameMap[K]>;
|
|
219
|
+
querySelectorAll<K extends keyof MathMLElementTagNameMap>(selectors: K): NodeListOf<MathMLElementTagNameMap[K]>;
|
|
220
|
+
querySelectorAll<K extends keyof HTMLElementDeprecatedTagNameMap>(selectors: K): NodeListOf<HTMLElementDeprecatedTagNameMap[K]>;
|
|
221
|
+
querySelectorAll<E extends Element = Element>(selectors: string): NodeListOf<E>;
|
|
222
|
+
replaceChildren(...nodes: (Node | string)[]): void;
|
|
220
223
|
readonly assignedSlot: HTMLSlotElement | null;
|
|
221
224
|
readonly attributeStyleMap: StylePropertyMap;
|
|
222
225
|
readonly style: CSSStyleDeclaration;
|
|
@@ -287,7 +290,7 @@ export declare function element<Target extends CustomElementConstructor>(Base: T
|
|
|
287
290
|
onpointerout: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
|
|
288
291
|
onpointerover: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
|
|
289
292
|
onpointerup: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
|
|
290
|
-
onprogress: ((this: GlobalEventHandlers, ev: ProgressEvent
|
|
293
|
+
onprogress: ((this: GlobalEventHandlers, ev: ProgressEvent) => any) | null;
|
|
291
294
|
onratechange: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
292
295
|
onreset: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
293
296
|
onresize: ((this: GlobalEventHandlers, ev: UIEvent) => any) | null;
|
|
@@ -322,10 +325,10 @@ export declare function element<Target extends CustomElementConstructor>(Base: T
|
|
|
322
325
|
onwheel: ((this: GlobalEventHandlers, ev: WheelEvent) => any) | null;
|
|
323
326
|
autofocus: boolean;
|
|
324
327
|
readonly dataset: DOMStringMap;
|
|
325
|
-
nonce?: string
|
|
328
|
+
nonce?: string;
|
|
326
329
|
tabIndex: number;
|
|
327
330
|
blur(): void;
|
|
328
|
-
focus(options?: FocusOptions
|
|
331
|
+
focus(options?: FocusOptions): void;
|
|
329
332
|
};
|
|
330
333
|
observedAttributes: string[];
|
|
331
334
|
} & Target;
|