@trunkjs/browser-utils 1.0.31 → 1.0.32
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/CHANGELOG.md +4 -0
- package/index.js +46 -46
- package/mixins/BreakPointMixin.d.ts +3 -341
- package/mixins/EventBindingsMixin.d.ts +2 -2
- package/mixins/LoggingMixin.d.ts +3 -3
- package/mixins/SlotVisibilityMixin.d.ts +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
## 1.0.32 (2026-02-07)
|
|
2
|
+
|
|
3
|
+
This was a version bump only for browser-utils to align it with other projects, there were no code changes.
|
|
4
|
+
|
|
1
5
|
## 1.0.31 (2026-02-07)
|
|
2
6
|
|
|
3
7
|
This was a version bump only for browser-utils to align it with other projects, there were no code changes.
|
package/index.js
CHANGED
|
@@ -1,31 +1,31 @@
|
|
|
1
1
|
var D = Object.defineProperty;
|
|
2
|
-
var
|
|
2
|
+
var v = (t) => {
|
|
3
3
|
throw TypeError(t);
|
|
4
4
|
};
|
|
5
5
|
var $ = (t, e, n) => e in t ? D(t, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : t[e] = n;
|
|
6
|
-
var c = (t, e, n) => $(t, typeof e != "symbol" ? e + "" : e, n),
|
|
7
|
-
var u = (t, e, n) => (
|
|
8
|
-
const
|
|
6
|
+
var c = (t, e, n) => $(t, typeof e != "symbol" ? e + "" : e, n), T = (t, e, n) => e.has(t) || v("Cannot " + n);
|
|
7
|
+
var u = (t, e, n) => (T(t, e, "read from private field"), n ? n.call(t) : e.get(t)), m = (t, e, n) => e.has(t) ? v("Cannot add the same private member more than once") : e instanceof WeakSet ? e.add(t) : e.set(t, n), w = (t, e, n, i) => (T(t, e, "write to private field"), i ? i.call(t, n) : e.set(t, n), n), E = (t, e, n) => (T(t, e, "access private method"), n);
|
|
8
|
+
const L = [
|
|
9
9
|
{ name: "xs", minWidth: 0 },
|
|
10
10
|
{ name: "sm", minWidth: 576 },
|
|
11
11
|
{ name: "md", minWidth: 768 },
|
|
12
12
|
{ name: "lg", minWidth: 992 },
|
|
13
13
|
{ name: "xl", minWidth: 1200 },
|
|
14
14
|
{ name: "xxl", minWidth: 1400 }
|
|
15
|
-
],
|
|
15
|
+
], k = L.reduce(
|
|
16
16
|
(t, e) => (t[e.name] = e.minWidth, t),
|
|
17
17
|
{}
|
|
18
18
|
);
|
|
19
|
-
function
|
|
20
|
-
if (!(t in
|
|
19
|
+
function p(t) {
|
|
20
|
+
if (!(t in k))
|
|
21
21
|
throw new Error(`Unknown breakpoint: ${t}`);
|
|
22
|
-
return
|
|
22
|
+
return k[t];
|
|
23
23
|
}
|
|
24
24
|
function R(t) {
|
|
25
25
|
t === void 0 && (t = window.innerWidth);
|
|
26
|
-
for (let e =
|
|
27
|
-
if (t >=
|
|
28
|
-
return
|
|
26
|
+
for (let e = L.length - 1; e >= 0; e--)
|
|
27
|
+
if (t >= L[e].minWidth)
|
|
28
|
+
return L[e].name;
|
|
29
29
|
return "xs";
|
|
30
30
|
}
|
|
31
31
|
function O(t, e = {}, n = []) {
|
|
@@ -37,7 +37,7 @@ function O(t, e = {}, n = []) {
|
|
|
37
37
|
i.append(typeof s == "string" ? document.createTextNode(s) : s);
|
|
38
38
|
return i;
|
|
39
39
|
}
|
|
40
|
-
class
|
|
40
|
+
class M {
|
|
41
41
|
/**
|
|
42
42
|
*
|
|
43
43
|
* @param delay Debounce delay in milliseconds
|
|
@@ -73,11 +73,11 @@ function F(t, e = !1) {
|
|
|
73
73
|
return function(i, s) {
|
|
74
74
|
if (s.kind !== "method") return i;
|
|
75
75
|
const a = s.name;
|
|
76
|
-
return function(...
|
|
76
|
+
return function(...l) {
|
|
77
77
|
let r = n.get(this);
|
|
78
78
|
r || (r = /* @__PURE__ */ new Map(), n.set(this, r));
|
|
79
79
|
let o = r.get(a);
|
|
80
|
-
o || (o = new
|
|
80
|
+
o || (o = new M(t, e), r.set(a, o)), o.debounce(() => i.apply(this, l));
|
|
81
81
|
};
|
|
82
82
|
};
|
|
83
83
|
}
|
|
@@ -153,8 +153,8 @@ class V {
|
|
|
153
153
|
}
|
|
154
154
|
function z(t, e, n) {
|
|
155
155
|
return new Promise((i, s) => {
|
|
156
|
-
const a = (
|
|
157
|
-
t.removeEventListener(e, a, n), i(
|
|
156
|
+
const a = (l) => {
|
|
157
|
+
t.removeEventListener(e, a, n), i(l);
|
|
158
158
|
};
|
|
159
159
|
t.addEventListener(e, a, n);
|
|
160
160
|
});
|
|
@@ -185,16 +185,16 @@ function X(t) {
|
|
|
185
185
|
class e extends t {
|
|
186
186
|
constructor() {
|
|
187
187
|
super(...arguments);
|
|
188
|
-
m(this, n, new
|
|
188
|
+
m(this, n, new M(200, 5e3));
|
|
189
189
|
c(this, "currentBreakPoint", null);
|
|
190
190
|
m(this, i, async () => {
|
|
191
|
-
var
|
|
191
|
+
var b;
|
|
192
192
|
await u(this, n).wait(), await N();
|
|
193
|
-
const
|
|
194
|
-
if (!
|
|
193
|
+
const l = this, r = window.innerWidth, o = getComputedStyle(l).getPropertyValue("--breakpoint");
|
|
194
|
+
if (!o || o === "")
|
|
195
195
|
return;
|
|
196
|
-
const
|
|
197
|
-
this.currentBreakPoint !==
|
|
196
|
+
const d = o.split(","), h = d[0].trim(), f = ((b = d[1]) == null ? void 0 : b.trim()) ?? h, g = R(r);
|
|
197
|
+
this.currentBreakPoint !== g && (p(f) <= p(g) ? l.setAttribute("mode", "desktop") : p(h) > p(g) ? l.setAttribute("mode", "mobile") : l.setAttribute("mode", "tablet"));
|
|
198
198
|
});
|
|
199
199
|
}
|
|
200
200
|
connectedCallback() {
|
|
@@ -206,20 +206,20 @@ function X(t) {
|
|
|
206
206
|
}
|
|
207
207
|
return n = new WeakMap(), i = new WeakMap(), e;
|
|
208
208
|
}
|
|
209
|
-
const
|
|
209
|
+
const y = Symbol("listenerDefs"), x = Symbol("withEventBindings");
|
|
210
210
|
function J(t, e) {
|
|
211
211
|
const n = Array.isArray(t) ? t : [t];
|
|
212
212
|
return function(i, s) {
|
|
213
213
|
if (s.kind !== "method") throw new Error("@Listen nur für Methoden");
|
|
214
214
|
return s.addInitializer(function() {
|
|
215
215
|
const a = this.constructor;
|
|
216
|
-
(a[
|
|
216
|
+
(a[y] || (a[y] = [])).push({
|
|
217
217
|
method: s.name,
|
|
218
218
|
events: n,
|
|
219
219
|
opts: e
|
|
220
220
|
});
|
|
221
221
|
}), function(...a) {
|
|
222
|
-
if (!this[
|
|
222
|
+
if (!this[x])
|
|
223
223
|
throw new Error("[EventBindings] @Listen - decorator requires EventBindingMixin.");
|
|
224
224
|
return i.apply(this, a);
|
|
225
225
|
};
|
|
@@ -230,31 +230,31 @@ function _(t, e) {
|
|
|
230
230
|
return !e || e === "host" ? t : e === "document" ? t.ownerDocument ?? document : e === "window" ? ((n = t.ownerDocument) == null ? void 0 : n.defaultView) ?? window : e === "shadowRoot" ? t.shadowRoot ?? t : typeof e == "function" ? e(t) : e;
|
|
231
231
|
}
|
|
232
232
|
function K(t) {
|
|
233
|
-
var n, i,
|
|
233
|
+
var n, i, A;
|
|
234
234
|
class e extends t {
|
|
235
235
|
constructor(...r) {
|
|
236
236
|
super(...r);
|
|
237
237
|
m(this, i);
|
|
238
238
|
m(this, n);
|
|
239
|
-
this[
|
|
239
|
+
this[x] = !0;
|
|
240
240
|
}
|
|
241
241
|
connectedCallback() {
|
|
242
242
|
var r;
|
|
243
|
-
(r = super.connectedCallback) == null || r.call(this),
|
|
243
|
+
(r = super.connectedCallback) == null || r.call(this), E(this, i, A).call(this);
|
|
244
244
|
}
|
|
245
245
|
disconnectedCallback() {
|
|
246
246
|
var r, o;
|
|
247
247
|
(r = u(this, n)) == null || r.abort(), (o = super.disconnectedCallback) == null || o.call(this);
|
|
248
248
|
}
|
|
249
249
|
}
|
|
250
|
-
return n = new WeakMap(), i = new WeakSet(),
|
|
251
|
-
var o, d,
|
|
250
|
+
return n = new WeakMap(), i = new WeakSet(), A = function() {
|
|
251
|
+
var o, d, h;
|
|
252
252
|
(o = u(this, n)) == null || o.abort(), w(this, n, new AbortController());
|
|
253
|
-
const r = this.constructor[
|
|
254
|
-
for (const
|
|
255
|
-
const g = _(this, (d =
|
|
256
|
-
for (const P of
|
|
257
|
-
g.addEventListener(P, C, { ...
|
|
253
|
+
const r = this.constructor[y] || [];
|
|
254
|
+
for (const f of r) {
|
|
255
|
+
const g = _(this, (d = f.opts) == null ? void 0 : d.target), b = ((h = f.opts) == null ? void 0 : h.options) ?? {}, C = this[f.method].bind(this);
|
|
256
|
+
for (const P of f.events)
|
|
257
|
+
g.addEventListener(P, C, { ...b, signal: u(this, n).signal });
|
|
258
258
|
}
|
|
259
259
|
}, e;
|
|
260
260
|
}
|
|
@@ -297,45 +297,45 @@ function Q(t) {
|
|
|
297
297
|
return n = new WeakMap(), i = new WeakMap(), s = new WeakMap(), e;
|
|
298
298
|
}
|
|
299
299
|
function Y(t) {
|
|
300
|
-
var n,
|
|
300
|
+
var n, W, s, I;
|
|
301
301
|
class e extends t {
|
|
302
302
|
constructor() {
|
|
303
303
|
super(...arguments);
|
|
304
304
|
m(this, n);
|
|
305
305
|
m(this, s, (o) => {
|
|
306
306
|
const d = o.target;
|
|
307
|
-
d.assignedNodes({ flatten: !0 }).filter((g) =>
|
|
307
|
+
d.assignedNodes({ flatten: !0 }).filter((g) => E(this, n, I).call(this, g)).length > 0 && d.classList.remove("slot-empty");
|
|
308
308
|
});
|
|
309
309
|
}
|
|
310
310
|
firstUpdated(o) {
|
|
311
311
|
var d;
|
|
312
|
-
(d = super.firstUpdated) == null || d.call(this, o),
|
|
312
|
+
(d = super.firstUpdated) == null || d.call(this, o), E(this, n, W).call(this);
|
|
313
313
|
}
|
|
314
314
|
}
|
|
315
|
-
return n = new WeakSet(),
|
|
315
|
+
return n = new WeakSet(), W = function() {
|
|
316
316
|
var d;
|
|
317
317
|
const o = (d = this.shadowRoot) == null ? void 0 : d.querySelectorAll("slot");
|
|
318
|
-
o == null || o.forEach((
|
|
319
|
-
|
|
318
|
+
o == null || o.forEach((h) => {
|
|
319
|
+
h.classList.add("slot-empty"), h.addEventListener("slotchange", (f) => u(this, s).call(this, f));
|
|
320
320
|
});
|
|
321
|
-
}, s = new WeakMap(),
|
|
321
|
+
}, s = new WeakMap(), I = function(o) {
|
|
322
322
|
return o.nodeType === Node.TEXT_NODE ? (o.textContent || "").trim().length > 0 : o.nodeType === Node.ELEMENT_NODE;
|
|
323
323
|
}, e;
|
|
324
324
|
}
|
|
325
325
|
export {
|
|
326
326
|
X as BreakPointMixin,
|
|
327
|
-
|
|
327
|
+
M as Debouncer,
|
|
328
328
|
K as EventBindingsMixin,
|
|
329
329
|
J as Listen,
|
|
330
330
|
B as Logger,
|
|
331
331
|
Q as LoggingMixin,
|
|
332
332
|
Y as SlotVisibilityMixin,
|
|
333
333
|
V as Stopwatch,
|
|
334
|
-
|
|
335
|
-
|
|
334
|
+
k as breakpointMap,
|
|
335
|
+
L as breakpoints,
|
|
336
336
|
O as create_element,
|
|
337
337
|
F as debounce,
|
|
338
|
-
|
|
338
|
+
p as getBreakpointMinWidth,
|
|
339
339
|
R as getCurrentBreakpoint,
|
|
340
340
|
H as getErrorLocation,
|
|
341
341
|
j as sleep,
|
|
@@ -3,349 +3,11 @@ type Constructor<T = object> = abstract new (...args: any[]) => T;
|
|
|
3
3
|
export interface BreakPointMixinInterface {
|
|
4
4
|
currentBreakPoint: string | null;
|
|
5
5
|
}
|
|
6
|
-
export declare function BreakPointMixin<TBase extends Constructor<
|
|
7
|
-
"__#
|
|
6
|
+
export declare function BreakPointMixin<TBase extends Constructor<object>>(Base: TBase): (abstract new (...args: any[]) => {
|
|
7
|
+
"__#2564@#debouncer": Debouncer;
|
|
8
8
|
currentBreakPoint: string | null;
|
|
9
|
-
"__#
|
|
9
|
+
"__#2564@#updateBreakPoint": () => Promise<void>;
|
|
10
10
|
connectedCallback(): void;
|
|
11
11
|
disconnectedCallback(): void;
|
|
12
|
-
accessKey: string;
|
|
13
|
-
readonly accessKeyLabel: string;
|
|
14
|
-
autocapitalize: string;
|
|
15
|
-
dir: string;
|
|
16
|
-
draggable: boolean;
|
|
17
|
-
hidden: boolean;
|
|
18
|
-
inert: boolean;
|
|
19
|
-
innerText: string;
|
|
20
|
-
lang: string;
|
|
21
|
-
readonly offsetHeight: number;
|
|
22
|
-
readonly offsetLeft: number;
|
|
23
|
-
readonly offsetParent: Element | null;
|
|
24
|
-
readonly offsetTop: number;
|
|
25
|
-
readonly offsetWidth: number;
|
|
26
|
-
outerText: string;
|
|
27
|
-
popover: string | null;
|
|
28
|
-
spellcheck: boolean;
|
|
29
|
-
title: string;
|
|
30
|
-
translate: boolean;
|
|
31
|
-
writingSuggestions: string;
|
|
32
|
-
attachInternals(): ElementInternals;
|
|
33
|
-
click(): void;
|
|
34
|
-
hidePopover(): void;
|
|
35
|
-
showPopover(): void;
|
|
36
|
-
togglePopover(options?: boolean): boolean;
|
|
37
|
-
addEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): void;
|
|
38
|
-
addEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | AddEventListenerOptions): void;
|
|
39
|
-
removeEventListener<K extends keyof HTMLElementEventMap>(type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | EventListenerOptions): void;
|
|
40
|
-
removeEventListener(type: string, listener: EventListenerOrEventListenerObject, options?: boolean | EventListenerOptions): void;
|
|
41
|
-
readonly attributes: NamedNodeMap;
|
|
42
|
-
get classList(): DOMTokenList;
|
|
43
|
-
set classList(value: string);
|
|
44
|
-
className: string;
|
|
45
|
-
readonly clientHeight: number;
|
|
46
|
-
readonly clientLeft: number;
|
|
47
|
-
readonly clientTop: number;
|
|
48
|
-
readonly clientWidth: number;
|
|
49
|
-
readonly currentCSSZoom: number;
|
|
50
|
-
id: string;
|
|
51
|
-
innerHTML: string;
|
|
52
|
-
readonly localName: string;
|
|
53
|
-
readonly namespaceURI: string | null;
|
|
54
|
-
onfullscreenchange: ((this: Element, ev: Event) => any) | null;
|
|
55
|
-
onfullscreenerror: ((this: Element, ev: Event) => any) | null;
|
|
56
|
-
outerHTML: string;
|
|
57
|
-
readonly ownerDocument: Document;
|
|
58
|
-
get part(): DOMTokenList;
|
|
59
|
-
set part(value: string);
|
|
60
|
-
readonly prefix: string | null;
|
|
61
|
-
readonly scrollHeight: number;
|
|
62
|
-
scrollLeft: number;
|
|
63
|
-
scrollTop: number;
|
|
64
|
-
readonly scrollWidth: number;
|
|
65
|
-
readonly shadowRoot: ShadowRoot | null;
|
|
66
|
-
slot: string;
|
|
67
|
-
readonly tagName: string;
|
|
68
|
-
attachShadow(init: ShadowRootInit): ShadowRoot;
|
|
69
|
-
checkVisibility(options?: CheckVisibilityOptions): boolean;
|
|
70
|
-
closest<K extends keyof HTMLElementTagNameMap>(selector: K): HTMLElementTagNameMap[K] | null;
|
|
71
|
-
closest<K extends keyof SVGElementTagNameMap>(selector: K): SVGElementTagNameMap[K] | null;
|
|
72
|
-
closest<K extends keyof MathMLElementTagNameMap>(selector: K): MathMLElementTagNameMap[K] | null;
|
|
73
|
-
closest<E extends Element = Element>(selectors: string): E | null;
|
|
74
|
-
computedStyleMap(): StylePropertyMapReadOnly;
|
|
75
|
-
getAttribute(qualifiedName: string): string | null;
|
|
76
|
-
getAttributeNS(namespace: string | null, localName: string): string | null;
|
|
77
|
-
getAttributeNames(): string[];
|
|
78
|
-
getAttributeNode(qualifiedName: string): Attr | null;
|
|
79
|
-
getAttributeNodeNS(namespace: string | null, localName: string): Attr | null;
|
|
80
|
-
getBoundingClientRect(): DOMRect;
|
|
81
|
-
getClientRects(): DOMRectList;
|
|
82
|
-
getElementsByClassName(classNames: string): HTMLCollectionOf<Element>;
|
|
83
|
-
getElementsByTagName<K extends keyof HTMLElementTagNameMap>(qualifiedName: K): HTMLCollectionOf<HTMLElementTagNameMap[K]>;
|
|
84
|
-
getElementsByTagName<K extends keyof SVGElementTagNameMap>(qualifiedName: K): HTMLCollectionOf<SVGElementTagNameMap[K]>;
|
|
85
|
-
getElementsByTagName<K extends keyof MathMLElementTagNameMap>(qualifiedName: K): HTMLCollectionOf<MathMLElementTagNameMap[K]>;
|
|
86
|
-
getElementsByTagName<K extends keyof HTMLElementDeprecatedTagNameMap>(qualifiedName: K): HTMLCollectionOf<HTMLElementDeprecatedTagNameMap[K]>;
|
|
87
|
-
getElementsByTagName(qualifiedName: string): HTMLCollectionOf<Element>;
|
|
88
|
-
getElementsByTagNameNS(namespaceURI: "http://www.w3.org/1999/xhtml", localName: string): HTMLCollectionOf<HTMLElement>;
|
|
89
|
-
getElementsByTagNameNS(namespaceURI: "http://www.w3.org/2000/svg", localName: string): HTMLCollectionOf<SVGElement>;
|
|
90
|
-
getElementsByTagNameNS(namespaceURI: "http://www.w3.org/1998/Math/MathML", localName: string): HTMLCollectionOf<MathMLElement>;
|
|
91
|
-
getElementsByTagNameNS(namespace: string | null, localName: string): HTMLCollectionOf<Element>;
|
|
92
|
-
getHTML(options?: GetHTMLOptions): string;
|
|
93
|
-
hasAttribute(qualifiedName: string): boolean;
|
|
94
|
-
hasAttributeNS(namespace: string | null, localName: string): boolean;
|
|
95
|
-
hasAttributes(): boolean;
|
|
96
|
-
hasPointerCapture(pointerId: number): boolean;
|
|
97
|
-
insertAdjacentElement(where: InsertPosition, element: Element): Element | null;
|
|
98
|
-
insertAdjacentHTML(position: InsertPosition, string: string): void;
|
|
99
|
-
insertAdjacentText(where: InsertPosition, data: string): void;
|
|
100
|
-
matches(selectors: string): boolean;
|
|
101
|
-
releasePointerCapture(pointerId: number): void;
|
|
102
|
-
removeAttribute(qualifiedName: string): void;
|
|
103
|
-
removeAttributeNS(namespace: string | null, localName: string): void;
|
|
104
|
-
removeAttributeNode(attr: Attr): Attr;
|
|
105
|
-
requestFullscreen(options?: FullscreenOptions): Promise<void>;
|
|
106
|
-
requestPointerLock(options?: PointerLockOptions): Promise<void>;
|
|
107
|
-
scroll(options?: ScrollToOptions): void;
|
|
108
|
-
scroll(x: number, y: number): void;
|
|
109
|
-
scrollBy(options?: ScrollToOptions): void;
|
|
110
|
-
scrollBy(x: number, y: number): void;
|
|
111
|
-
scrollIntoView(arg?: boolean | ScrollIntoViewOptions): void;
|
|
112
|
-
scrollTo(options?: ScrollToOptions): void;
|
|
113
|
-
scrollTo(x: number, y: number): void;
|
|
114
|
-
setAttribute(qualifiedName: string, value: string): void;
|
|
115
|
-
setAttributeNS(namespace: string | null, qualifiedName: string, value: string): void;
|
|
116
|
-
setAttributeNode(attr: Attr): Attr | null;
|
|
117
|
-
setAttributeNodeNS(attr: Attr): Attr | null;
|
|
118
|
-
setHTMLUnsafe(html: string): void;
|
|
119
|
-
setPointerCapture(pointerId: number): void;
|
|
120
|
-
toggleAttribute(qualifiedName: string, force?: boolean): boolean;
|
|
121
|
-
webkitMatchesSelector(selectors: string): boolean;
|
|
122
|
-
readonly baseURI: string;
|
|
123
|
-
readonly childNodes: NodeListOf<ChildNode>;
|
|
124
|
-
readonly firstChild: ChildNode | null;
|
|
125
|
-
readonly isConnected: boolean;
|
|
126
|
-
readonly lastChild: ChildNode | null;
|
|
127
|
-
readonly nextSibling: ChildNode | null;
|
|
128
|
-
readonly nodeName: string;
|
|
129
|
-
readonly nodeType: number;
|
|
130
|
-
nodeValue: string | null;
|
|
131
|
-
readonly parentElement: HTMLElement | null;
|
|
132
|
-
readonly parentNode: ParentNode | null;
|
|
133
|
-
readonly previousSibling: ChildNode | null;
|
|
134
|
-
textContent: string | null;
|
|
135
|
-
appendChild<T extends Node>(node: T): T;
|
|
136
|
-
cloneNode(subtree?: boolean): Node;
|
|
137
|
-
compareDocumentPosition(other: Node): number;
|
|
138
|
-
contains(other: Node | null): boolean;
|
|
139
|
-
getRootNode(options?: GetRootNodeOptions): Node;
|
|
140
|
-
hasChildNodes(): boolean;
|
|
141
|
-
insertBefore<T extends Node>(node: T, child: Node | null): T;
|
|
142
|
-
isDefaultNamespace(namespace: string | null): boolean;
|
|
143
|
-
isEqualNode(otherNode: Node | null): boolean;
|
|
144
|
-
isSameNode(otherNode: Node | null): boolean;
|
|
145
|
-
lookupNamespaceURI(prefix: string | null): string | null;
|
|
146
|
-
lookupPrefix(namespace: string | null): string | null;
|
|
147
|
-
normalize(): void;
|
|
148
|
-
removeChild<T extends Node>(child: T): T;
|
|
149
|
-
replaceChild<T extends Node>(node: Node, child: T): T;
|
|
150
|
-
readonly ELEMENT_NODE: 1;
|
|
151
|
-
readonly ATTRIBUTE_NODE: 2;
|
|
152
|
-
readonly TEXT_NODE: 3;
|
|
153
|
-
readonly CDATA_SECTION_NODE: 4;
|
|
154
|
-
readonly ENTITY_REFERENCE_NODE: 5;
|
|
155
|
-
readonly ENTITY_NODE: 6;
|
|
156
|
-
readonly PROCESSING_INSTRUCTION_NODE: 7;
|
|
157
|
-
readonly COMMENT_NODE: 8;
|
|
158
|
-
readonly DOCUMENT_NODE: 9;
|
|
159
|
-
readonly DOCUMENT_TYPE_NODE: 10;
|
|
160
|
-
readonly DOCUMENT_FRAGMENT_NODE: 11;
|
|
161
|
-
readonly NOTATION_NODE: 12;
|
|
162
|
-
readonly DOCUMENT_POSITION_DISCONNECTED: 1;
|
|
163
|
-
readonly DOCUMENT_POSITION_PRECEDING: 2;
|
|
164
|
-
readonly DOCUMENT_POSITION_FOLLOWING: 4;
|
|
165
|
-
readonly DOCUMENT_POSITION_CONTAINS: 8;
|
|
166
|
-
readonly DOCUMENT_POSITION_CONTAINED_BY: 16;
|
|
167
|
-
readonly DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC: 32;
|
|
168
|
-
dispatchEvent(event: Event): boolean;
|
|
169
|
-
ariaAtomic: string | null;
|
|
170
|
-
ariaAutoComplete: string | null;
|
|
171
|
-
ariaBrailleLabel: string | null;
|
|
172
|
-
ariaBrailleRoleDescription: string | null;
|
|
173
|
-
ariaBusy: string | null;
|
|
174
|
-
ariaChecked: string | null;
|
|
175
|
-
ariaColCount: string | null;
|
|
176
|
-
ariaColIndex: string | null;
|
|
177
|
-
ariaColIndexText: string | null;
|
|
178
|
-
ariaColSpan: string | null;
|
|
179
|
-
ariaCurrent: string | null;
|
|
180
|
-
ariaDescription: string | null;
|
|
181
|
-
ariaDisabled: string | null;
|
|
182
|
-
ariaExpanded: string | null;
|
|
183
|
-
ariaHasPopup: string | null;
|
|
184
|
-
ariaHidden: string | null;
|
|
185
|
-
ariaInvalid: string | null;
|
|
186
|
-
ariaKeyShortcuts: string | null;
|
|
187
|
-
ariaLabel: string | null;
|
|
188
|
-
ariaLevel: string | null;
|
|
189
|
-
ariaLive: string | null;
|
|
190
|
-
ariaModal: string | null;
|
|
191
|
-
ariaMultiLine: string | null;
|
|
192
|
-
ariaMultiSelectable: string | null;
|
|
193
|
-
ariaOrientation: string | null;
|
|
194
|
-
ariaPlaceholder: string | null;
|
|
195
|
-
ariaPosInSet: string | null;
|
|
196
|
-
ariaPressed: string | null;
|
|
197
|
-
ariaReadOnly: string | null;
|
|
198
|
-
ariaRelevant: string | null;
|
|
199
|
-
ariaRequired: string | null;
|
|
200
|
-
ariaRoleDescription: string | null;
|
|
201
|
-
ariaRowCount: string | null;
|
|
202
|
-
ariaRowIndex: string | null;
|
|
203
|
-
ariaRowIndexText: string | null;
|
|
204
|
-
ariaRowSpan: string | null;
|
|
205
|
-
ariaSelected: string | null;
|
|
206
|
-
ariaSetSize: string | null;
|
|
207
|
-
ariaSort: string | null;
|
|
208
|
-
ariaValueMax: string | null;
|
|
209
|
-
ariaValueMin: string | null;
|
|
210
|
-
ariaValueNow: string | null;
|
|
211
|
-
ariaValueText: string | null;
|
|
212
|
-
role: string | null;
|
|
213
|
-
animate(keyframes: Keyframe[] | PropertyIndexedKeyframes | null, options?: number | KeyframeAnimationOptions): Animation;
|
|
214
|
-
getAnimations(options?: GetAnimationsOptions): Animation[];
|
|
215
|
-
after(...nodes: (Node | string)[]): void;
|
|
216
|
-
before(...nodes: (Node | string)[]): void;
|
|
217
|
-
remove(): void;
|
|
218
|
-
replaceWith(...nodes: (Node | string)[]): void;
|
|
219
|
-
readonly nextElementSibling: Element | null;
|
|
220
|
-
readonly previousElementSibling: Element | null;
|
|
221
|
-
readonly childElementCount: number;
|
|
222
|
-
readonly children: HTMLCollection;
|
|
223
|
-
readonly firstElementChild: Element | null;
|
|
224
|
-
readonly lastElementChild: Element | null;
|
|
225
|
-
append(...nodes: (Node | string)[]): void;
|
|
226
|
-
prepend(...nodes: (Node | string)[]): void;
|
|
227
|
-
querySelector<K extends keyof HTMLElementTagNameMap>(selectors: K): HTMLElementTagNameMap[K] | null;
|
|
228
|
-
querySelector<K extends keyof SVGElementTagNameMap>(selectors: K): SVGElementTagNameMap[K] | null;
|
|
229
|
-
querySelector<K extends keyof MathMLElementTagNameMap>(selectors: K): MathMLElementTagNameMap[K] | null;
|
|
230
|
-
querySelector<K extends keyof HTMLElementDeprecatedTagNameMap>(selectors: K): HTMLElementDeprecatedTagNameMap[K] | null;
|
|
231
|
-
querySelector<E extends Element = Element>(selectors: string): E | null;
|
|
232
|
-
querySelectorAll<K extends keyof HTMLElementTagNameMap>(selectors: K): NodeListOf<HTMLElementTagNameMap[K]>;
|
|
233
|
-
querySelectorAll<K extends keyof SVGElementTagNameMap>(selectors: K): NodeListOf<SVGElementTagNameMap[K]>;
|
|
234
|
-
querySelectorAll<K extends keyof MathMLElementTagNameMap>(selectors: K): NodeListOf<MathMLElementTagNameMap[K]>;
|
|
235
|
-
querySelectorAll<K extends keyof HTMLElementDeprecatedTagNameMap>(selectors: K): NodeListOf<HTMLElementDeprecatedTagNameMap[K]>;
|
|
236
|
-
querySelectorAll<E extends Element = Element>(selectors: string): NodeListOf<E>;
|
|
237
|
-
replaceChildren(...nodes: (Node | string)[]): void;
|
|
238
|
-
readonly assignedSlot: HTMLSlotElement | null;
|
|
239
|
-
readonly attributeStyleMap: StylePropertyMap;
|
|
240
|
-
get style(): CSSStyleDeclaration;
|
|
241
|
-
set style(cssText: string);
|
|
242
|
-
contentEditable: string;
|
|
243
|
-
enterKeyHint: string;
|
|
244
|
-
inputMode: string;
|
|
245
|
-
readonly isContentEditable: boolean;
|
|
246
|
-
onabort: ((this: GlobalEventHandlers, ev: UIEvent) => any) | null;
|
|
247
|
-
onanimationcancel: ((this: GlobalEventHandlers, ev: AnimationEvent) => any) | null;
|
|
248
|
-
onanimationend: ((this: GlobalEventHandlers, ev: AnimationEvent) => any) | null;
|
|
249
|
-
onanimationiteration: ((this: GlobalEventHandlers, ev: AnimationEvent) => any) | null;
|
|
250
|
-
onanimationstart: ((this: GlobalEventHandlers, ev: AnimationEvent) => any) | null;
|
|
251
|
-
onauxclick: ((this: GlobalEventHandlers, ev: MouseEvent) => any) | null;
|
|
252
|
-
onbeforeinput: ((this: GlobalEventHandlers, ev: InputEvent) => any) | null;
|
|
253
|
-
onbeforetoggle: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
254
|
-
onblur: ((this: GlobalEventHandlers, ev: FocusEvent) => any) | null;
|
|
255
|
-
oncancel: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
256
|
-
oncanplay: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
257
|
-
oncanplaythrough: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
258
|
-
onchange: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
259
|
-
onclick: ((this: GlobalEventHandlers, ev: MouseEvent) => any) | null;
|
|
260
|
-
onclose: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
261
|
-
oncontextlost: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
262
|
-
oncontextmenu: ((this: GlobalEventHandlers, ev: MouseEvent) => any) | null;
|
|
263
|
-
oncontextrestored: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
264
|
-
oncopy: ((this: GlobalEventHandlers, ev: ClipboardEvent) => any) | null;
|
|
265
|
-
oncuechange: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
266
|
-
oncut: ((this: GlobalEventHandlers, ev: ClipboardEvent) => any) | null;
|
|
267
|
-
ondblclick: ((this: GlobalEventHandlers, ev: MouseEvent) => any) | null;
|
|
268
|
-
ondrag: ((this: GlobalEventHandlers, ev: DragEvent) => any) | null;
|
|
269
|
-
ondragend: ((this: GlobalEventHandlers, ev: DragEvent) => any) | null;
|
|
270
|
-
ondragenter: ((this: GlobalEventHandlers, ev: DragEvent) => any) | null;
|
|
271
|
-
ondragleave: ((this: GlobalEventHandlers, ev: DragEvent) => any) | null;
|
|
272
|
-
ondragover: ((this: GlobalEventHandlers, ev: DragEvent) => any) | null;
|
|
273
|
-
ondragstart: ((this: GlobalEventHandlers, ev: DragEvent) => any) | null;
|
|
274
|
-
ondrop: ((this: GlobalEventHandlers, ev: DragEvent) => any) | null;
|
|
275
|
-
ondurationchange: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
276
|
-
onemptied: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
277
|
-
onended: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
278
|
-
onerror: OnErrorEventHandler;
|
|
279
|
-
onfocus: ((this: GlobalEventHandlers, ev: FocusEvent) => any) | null;
|
|
280
|
-
onformdata: ((this: GlobalEventHandlers, ev: FormDataEvent) => any) | null;
|
|
281
|
-
ongotpointercapture: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
|
|
282
|
-
oninput: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
283
|
-
oninvalid: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
284
|
-
onkeydown: ((this: GlobalEventHandlers, ev: KeyboardEvent) => any) | null;
|
|
285
|
-
onkeypress: ((this: GlobalEventHandlers, ev: KeyboardEvent) => any) | null;
|
|
286
|
-
onkeyup: ((this: GlobalEventHandlers, ev: KeyboardEvent) => any) | null;
|
|
287
|
-
onload: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
288
|
-
onloadeddata: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
289
|
-
onloadedmetadata: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
290
|
-
onloadstart: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
291
|
-
onlostpointercapture: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
|
|
292
|
-
onmousedown: ((this: GlobalEventHandlers, ev: MouseEvent) => any) | null;
|
|
293
|
-
onmouseenter: ((this: GlobalEventHandlers, ev: MouseEvent) => any) | null;
|
|
294
|
-
onmouseleave: ((this: GlobalEventHandlers, ev: MouseEvent) => any) | null;
|
|
295
|
-
onmousemove: ((this: GlobalEventHandlers, ev: MouseEvent) => any) | null;
|
|
296
|
-
onmouseout: ((this: GlobalEventHandlers, ev: MouseEvent) => any) | null;
|
|
297
|
-
onmouseover: ((this: GlobalEventHandlers, ev: MouseEvent) => any) | null;
|
|
298
|
-
onmouseup: ((this: GlobalEventHandlers, ev: MouseEvent) => any) | null;
|
|
299
|
-
onpaste: ((this: GlobalEventHandlers, ev: ClipboardEvent) => any) | null;
|
|
300
|
-
onpause: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
301
|
-
onplay: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
302
|
-
onplaying: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
303
|
-
onpointercancel: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
|
|
304
|
-
onpointerdown: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
|
|
305
|
-
onpointerenter: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
|
|
306
|
-
onpointerleave: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
|
|
307
|
-
onpointermove: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
|
|
308
|
-
onpointerout: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
|
|
309
|
-
onpointerover: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
|
|
310
|
-
onpointerup: ((this: GlobalEventHandlers, ev: PointerEvent) => any) | null;
|
|
311
|
-
onprogress: ((this: GlobalEventHandlers, ev: ProgressEvent) => any) | null;
|
|
312
|
-
onratechange: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
313
|
-
onreset: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
314
|
-
onresize: ((this: GlobalEventHandlers, ev: UIEvent) => any) | null;
|
|
315
|
-
onscroll: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
316
|
-
onscrollend: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
317
|
-
onsecuritypolicyviolation: ((this: GlobalEventHandlers, ev: SecurityPolicyViolationEvent) => any) | null;
|
|
318
|
-
onseeked: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
319
|
-
onseeking: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
320
|
-
onselect: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
321
|
-
onselectionchange: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
322
|
-
onselectstart: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
323
|
-
onslotchange: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
324
|
-
onstalled: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
325
|
-
onsubmit: ((this: GlobalEventHandlers, ev: SubmitEvent) => any) | null;
|
|
326
|
-
onsuspend: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
327
|
-
ontimeupdate: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
328
|
-
ontoggle: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
329
|
-
ontouchcancel?: ((this: GlobalEventHandlers, ev: TouchEvent) => any) | null | undefined;
|
|
330
|
-
ontouchend?: ((this: GlobalEventHandlers, ev: TouchEvent) => any) | null | undefined;
|
|
331
|
-
ontouchmove?: ((this: GlobalEventHandlers, ev: TouchEvent) => any) | null | undefined;
|
|
332
|
-
ontouchstart?: ((this: GlobalEventHandlers, ev: TouchEvent) => any) | null | undefined;
|
|
333
|
-
ontransitioncancel: ((this: GlobalEventHandlers, ev: TransitionEvent) => any) | null;
|
|
334
|
-
ontransitionend: ((this: GlobalEventHandlers, ev: TransitionEvent) => any) | null;
|
|
335
|
-
ontransitionrun: ((this: GlobalEventHandlers, ev: TransitionEvent) => any) | null;
|
|
336
|
-
ontransitionstart: ((this: GlobalEventHandlers, ev: TransitionEvent) => any) | null;
|
|
337
|
-
onvolumechange: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
338
|
-
onwaiting: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
339
|
-
onwebkitanimationend: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
340
|
-
onwebkitanimationiteration: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
341
|
-
onwebkitanimationstart: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
342
|
-
onwebkittransitionend: ((this: GlobalEventHandlers, ev: Event) => any) | null;
|
|
343
|
-
onwheel: ((this: GlobalEventHandlers, ev: WheelEvent) => any) | null;
|
|
344
|
-
autofocus: boolean;
|
|
345
|
-
readonly dataset: DOMStringMap;
|
|
346
|
-
nonce?: string;
|
|
347
|
-
tabIndex: number;
|
|
348
|
-
blur(): void;
|
|
349
|
-
focus(options?: FocusOptions): void;
|
|
350
12
|
}) & TBase;
|
|
351
13
|
export {};
|
|
@@ -9,9 +9,9 @@ type OneOrMany<N extends EventName> = N | readonly N[];
|
|
|
9
9
|
type EventFromInput<I extends OneOrMany<EventName>> = I extends readonly (infer K)[] ? K extends EventName ? DocumentEventMap[K] : never : I extends EventName ? DocumentEventMap[I] : never;
|
|
10
10
|
export declare function Listen<I extends OneOrMany<EventName>>(type: I, opts?: ListenOpts): <This, Fn extends (this: This, ev: EventFromInput<I>, ...args: any[]) => any>(value: Fn, context: ClassMethodDecoratorContext<This, Fn>) => Fn;
|
|
11
11
|
export declare function EventBindingsMixin<TBase extends Ctor<object>>(Base: TBase): (abstract new (...a: any[]) => {
|
|
12
|
-
"__#
|
|
12
|
+
"__#2565@#ac"?: AbortController;
|
|
13
13
|
connectedCallback(): void;
|
|
14
14
|
disconnectedCallback(): void;
|
|
15
|
-
"__#
|
|
15
|
+
"__#2565@#bindEventListeners"(): void;
|
|
16
16
|
}) & TBase;
|
|
17
17
|
export {};
|
package/mixins/LoggingMixin.d.ts
CHANGED
|
@@ -33,14 +33,14 @@ export interface LoggerMixinInterface {
|
|
|
33
33
|
* <my-element debug></my-element> // enables debug logging
|
|
34
34
|
*/
|
|
35
35
|
export declare function LoggingMixin<TBase extends Constructor<object>>(Base: TBase): (abstract new (...args: any[]) => {
|
|
36
|
-
"__#
|
|
37
|
-
"__#
|
|
36
|
+
"__#2566@#debugCached": boolean | null;
|
|
37
|
+
"__#2566@#myElementId": number;
|
|
38
38
|
/**
|
|
39
39
|
* Clears the cached debug flag so the attribute will be checked again
|
|
40
40
|
* on the next log/warn/error call.
|
|
41
41
|
*/
|
|
42
42
|
invalidateDebugCache(): void;
|
|
43
|
-
"__#
|
|
43
|
+
"__#2566@#myLoggerInstance": Logger | null;
|
|
44
44
|
readonly _debug: boolean;
|
|
45
45
|
getLogger(instanceId?: string): Logger;
|
|
46
46
|
log(...args: any[]): void;
|
|
@@ -3,5 +3,5 @@ type Constructor<T = object> = abstract new (...args: any[]) => T;
|
|
|
3
3
|
export interface SlotVisibilityInterface {
|
|
4
4
|
firstUpdated(changedProperties: Map<string, unknown>): void;
|
|
5
5
|
}
|
|
6
|
-
export declare function SlotVisibilityMixin<TBase extends Constructor<LitElement>>(Base: TBase): TBase & Constructor<SlotVisibilityInterface>;
|
|
6
|
+
export declare function SlotVisibilityMixin<TBase extends Constructor<object & LitElement>>(Base: TBase): TBase & Constructor<SlotVisibilityInterface>;
|
|
7
7
|
export {};
|