@esportsplus/template 0.19.3 → 0.19.4
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/build/types.d.ts +2 -2
- package/package.json +2 -2
- package/src/types.ts +3 -2
package/build/types.d.ts
CHANGED
|
@@ -18,13 +18,13 @@ type Attributes = {
|
|
|
18
18
|
onrender?: (element: Element) => void;
|
|
19
19
|
} & Record<PropertyKey, unknown>;
|
|
20
20
|
type Effect<T> = () => T extends [] ? Renderable[] : Renderable;
|
|
21
|
-
type Element = HTMLElement & Attributes
|
|
21
|
+
type Element = HTMLElement & Attributes;
|
|
22
22
|
type Primitive = bigint | boolean | null | number | string | undefined;
|
|
23
23
|
type Renderable<T = unknown> = DocumentFragment | Effect<T> | Node | NodeList | Primitive | RenderableReactive<T> | Renderable[];
|
|
24
24
|
type RenderableReactive<T> = Readonly<{
|
|
25
25
|
[RENDERABLE]: typeof RENDERABLE_HTML_REACTIVE_ARRAY;
|
|
26
26
|
array: ReactiveArray<T>;
|
|
27
|
-
template: (this: ReactiveArray<T>,
|
|
27
|
+
template: (this: ReactiveArray<T>, value: T, i: number) => ReturnType<typeof html>;
|
|
28
28
|
}>;
|
|
29
29
|
type SlotGroup = {
|
|
30
30
|
head: Element;
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"author": "ICJR",
|
|
3
3
|
"dependencies": {
|
|
4
4
|
"@esportsplus/queue": "^0.1.0",
|
|
5
|
-
"@esportsplus/reactivity": "^0.16.
|
|
5
|
+
"@esportsplus/reactivity": "^0.16.7",
|
|
6
6
|
"@esportsplus/tasks": "^0.2.1",
|
|
7
7
|
"@esportsplus/utilities": "^0.22.1"
|
|
8
8
|
},
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
"private": false,
|
|
15
15
|
"type": "module",
|
|
16
16
|
"types": "./build/index.d.ts",
|
|
17
|
-
"version": "0.19.
|
|
17
|
+
"version": "0.19.4",
|
|
18
18
|
"scripts": {
|
|
19
19
|
"build": "tsc && tsc-alias",
|
|
20
20
|
"-": "-"
|
package/src/types.ts
CHANGED
|
@@ -23,7 +23,7 @@ type Attributes = {
|
|
|
23
23
|
|
|
24
24
|
type Effect<T> = () => T extends [] ? Renderable[] : Renderable;
|
|
25
25
|
|
|
26
|
-
type Element = HTMLElement & Attributes
|
|
26
|
+
type Element = HTMLElement & Attributes;
|
|
27
27
|
|
|
28
28
|
// Copied from '@esportsplus/utilities'
|
|
29
29
|
// - Importing from ^ causes 'cannot be named without a reference to...' error
|
|
@@ -36,7 +36,8 @@ type RenderableReactive<T> = Readonly<{
|
|
|
36
36
|
array: ReactiveArray<T>;
|
|
37
37
|
template: (
|
|
38
38
|
this: ReactiveArray<T>,
|
|
39
|
-
|
|
39
|
+
value: T,
|
|
40
|
+
i: number
|
|
40
41
|
) => ReturnType<typeof html>;
|
|
41
42
|
}>;
|
|
42
43
|
|