@trunkjs/browser-utils 1.0.42 → 1.0.43
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 +1 -1
- package/mixins/EventBindingsMixin.d.ts +2 -2
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
## 1.0.43 (2026-04-23)
|
|
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.42 (2026-04-14)
|
|
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
|
@@ -423,7 +423,7 @@ function at(e) {
|
|
|
423
423
|
h(this, n);
|
|
424
424
|
h(this, r, (o) => {
|
|
425
425
|
const d = o.target;
|
|
426
|
-
d.assignedNodes({ flatten: !0 }).filter((g) => y(this, n, S).call(this, g)).length > 0 && d.classList.remove("slot-empty");
|
|
426
|
+
d.assignedNodes({ flatten: !0 }).filter((g) => y(this, n, S).call(this, g)).length > 0 && d.childNodes.length > 0 && d.classList.remove("slot-empty");
|
|
427
427
|
});
|
|
428
428
|
}
|
|
429
429
|
firstUpdated(o) {
|
|
@@ -6,7 +6,7 @@ type ListenOpts = {
|
|
|
6
6
|
};
|
|
7
7
|
type EventName = keyof DocumentEventMap;
|
|
8
8
|
type OneOrMany<N extends EventName> = N | readonly N[];
|
|
9
|
-
type EventFromInput<I extends OneOrMany<EventName
|
|
10
|
-
export declare function Listen<I extends OneOrMany<EventName
|
|
9
|
+
type EventFromInput<I extends OneOrMany<EventName> | string> = I extends readonly (infer K)[] ? K extends EventName ? DocumentEventMap[K] : never : I extends EventName ? DocumentEventMap[I] : never;
|
|
10
|
+
export declare function Listen<I extends OneOrMany<EventName> | string>(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): TBase;
|
|
12
12
|
export {};
|