@atomic-ui/ui-vue 0.2.0 → 0.5.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/README.md +54 -6
- package/dist/chunk-WM4MLN2U.js +27 -0
- package/dist/chunk-WM4MLN2U.js.map +1 -0
- package/dist/components.d.ts +516 -0
- package/dist/index.d.ts +22 -182
- package/dist/index.js +172 -72
- package/dist/index.js.map +1 -1
- package/dist/strata-components.d.ts +288 -0
- package/dist/strata.d.ts +20 -0
- package/dist/strata.js +131 -0
- package/dist/strata.js.map +1 -0
- package/dist/wrap.d.ts +32 -0
- package/package.json +22 -8
package/dist/wrap.d.ts
ADDED
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { type DefineSetupFnComponent, type SlotsType, type VNode } from 'vue';
|
|
2
|
+
/** The emits of a wrapper, from its events: `{ change: CustomEvent<…> }` gives a typed `@change`. */
|
|
3
|
+
type EmitsOf<Events> = {
|
|
4
|
+
[K in keyof Events]: (event: Events[K]) => true;
|
|
5
|
+
};
|
|
6
|
+
/**
|
|
7
|
+
* A Vue component around one element, typed: its props are the element's own
|
|
8
|
+
* properties, and attributes by their HTML names, and its events are typed emits.
|
|
9
|
+
*/
|
|
10
|
+
export type ImpaktComponent<E, K extends keyof E, Attributes extends string, Events> = DefineSetupFnComponent<{
|
|
11
|
+
[P in K]?: E[P];
|
|
12
|
+
} & {
|
|
13
|
+
[A in Attributes]?: string | number | boolean;
|
|
14
|
+
}, EmitsOf<Events>, SlotsType<{
|
|
15
|
+
default?: () => VNode[];
|
|
16
|
+
}>>;
|
|
17
|
+
/**
|
|
18
|
+
* Build a Vue component around one element.
|
|
19
|
+
*
|
|
20
|
+
* `domProps` names the props that must be bound as properties rather than
|
|
21
|
+
* attributes — anything that is not a string, a number or a boolean. Everything
|
|
22
|
+
* else goes through as an attribute, which is what a custom element expects and
|
|
23
|
+
* what keeps the rendered markup readable.
|
|
24
|
+
*/
|
|
25
|
+
export declare function wrap(tag: string, domProps?: string[], events?: Record<string, string>): import("vue").DefineComponent<{}, () => VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
26
|
+
[key: string]: any;
|
|
27
|
+
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, string[], string, import("vue").PublicProps, Readonly<{}> & Readonly<{
|
|
28
|
+
[x: `on${Capitalize<string>}`]: ((...args: any[]) => any) | undefined;
|
|
29
|
+
}>, {}, SlotsType<{
|
|
30
|
+
default?: () => VNode[];
|
|
31
|
+
}>, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
32
|
+
export {};
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atomic-ui/ui-vue",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"description": "Vue bindings for @atomic-ui/ui: typed props bound as DOM properties, and
|
|
3
|
+
"version": "0.5.0",
|
|
4
|
+
"description": "Vue bindings for @atomic-ui/ui and @atomic-ui/strata: a typed component for every element, props bound as DOM properties, typed events, and GlobalComponents types.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
7
7
|
"url": "git+https://github.com/matthill8286/impkt-design-system.git",
|
|
@@ -14,17 +14,25 @@
|
|
|
14
14
|
".": {
|
|
15
15
|
"types": "./dist/index.d.ts",
|
|
16
16
|
"import": "./dist/index.js"
|
|
17
|
+
},
|
|
18
|
+
"./strata": {
|
|
19
|
+
"types": "./dist/strata.d.ts",
|
|
20
|
+
"import": "./dist/strata.js"
|
|
17
21
|
}
|
|
18
22
|
},
|
|
19
23
|
"dependencies": {
|
|
20
|
-
"@atomic-ui/ui": "^0.
|
|
24
|
+
"@atomic-ui/ui": "^0.5.0"
|
|
21
25
|
},
|
|
22
26
|
"peerDependencies": {
|
|
23
|
-
"vue": "^3.4.0"
|
|
27
|
+
"vue": "^3.4.0",
|
|
28
|
+
"@atomic-ui/strata": "^0.5.0"
|
|
24
29
|
},
|
|
25
30
|
"devDependencies": {
|
|
31
|
+
"happy-dom": "^21.0.4",
|
|
26
32
|
"typescript": "^5.5.0",
|
|
27
|
-
"
|
|
33
|
+
"vitest": "^2.0.0",
|
|
34
|
+
"vue": "^3.4.0",
|
|
35
|
+
"@atomic-ui/strata": "^0.5.0"
|
|
28
36
|
},
|
|
29
37
|
"files": [
|
|
30
38
|
"dist",
|
|
@@ -34,9 +42,15 @@
|
|
|
34
42
|
"registry": "https://registry.npmjs.org",
|
|
35
43
|
"access": "public"
|
|
36
44
|
},
|
|
45
|
+
"peerDependenciesMeta": {
|
|
46
|
+
"@atomic-ui/strata": {
|
|
47
|
+
"optional": true
|
|
48
|
+
}
|
|
49
|
+
},
|
|
37
50
|
"scripts": {
|
|
38
|
-
"
|
|
39
|
-
"
|
|
40
|
-
"
|
|
51
|
+
"generate": "node scripts/generate.mjs",
|
|
52
|
+
"build": "node scripts/generate.mjs && tsc -p tsconfig.json",
|
|
53
|
+
"typecheck": "node scripts/generate.mjs --check && tsc -p tsconfig.json",
|
|
54
|
+
"test": "vitest run"
|
|
41
55
|
}
|
|
42
56
|
}
|