@aures5g/vue-component-library 0.1.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 +45 -0
- package/dist/components/HelloWorld/HelloWorld.vue.d.ts +15 -0
- package/dist/components/button/UIButton.vue.d.ts +266 -0
- package/dist/config/primevue.d.ts +2 -0
- package/dist/index.d.ts +5 -0
- package/dist/style.css +1 -0
- package/dist/vue-component-library.js +2648 -0
- package/dist/vue-component-library.umd.cjs +78 -0
- package/package.json +63 -0
package/README.md
ADDED
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
# vue-component-library
|
|
2
|
+
|
|
3
|
+
This template should help get you started developing with Vue 3 in Vite.
|
|
4
|
+
|
|
5
|
+
## Recommended IDE Setup
|
|
6
|
+
|
|
7
|
+
[VSCode](https://code.visualstudio.com/) + [Volar](https://marketplace.visualstudio.com/items?itemName=Vue.volar) (and disable Vetur).
|
|
8
|
+
|
|
9
|
+
## Type Support for `.vue` Imports in TS
|
|
10
|
+
|
|
11
|
+
TypeScript cannot handle type information for `.vue` imports by default, so we replace the `tsc` CLI with `vue-tsc` for type checking. In editors, we need [Volar](https://marketplace.visualstudio.com/items?itemName=Vue.volar) to make the TypeScript language service aware of `.vue` types.
|
|
12
|
+
|
|
13
|
+
## Customize configuration
|
|
14
|
+
|
|
15
|
+
See [Vite Configuration Reference](https://vitejs.dev/config/).
|
|
16
|
+
|
|
17
|
+
## Project Setup
|
|
18
|
+
|
|
19
|
+
```sh
|
|
20
|
+
npm install
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
### Compile and Hot-Reload for Development
|
|
24
|
+
|
|
25
|
+
```sh
|
|
26
|
+
npm run dev
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
### Type-Check, Compile and Minify for Production
|
|
30
|
+
|
|
31
|
+
```sh
|
|
32
|
+
npm run build
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
### Run Unit Tests with [Vitest](https://vitest.dev/)
|
|
36
|
+
|
|
37
|
+
```sh
|
|
38
|
+
npm run test:unit
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
### Lint with [ESLint](https://eslint.org/)
|
|
42
|
+
|
|
43
|
+
```sh
|
|
44
|
+
npm run lint
|
|
45
|
+
```
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
declare const _default: import("vue").DefineComponent<__VLS_TypePropsToOption<{
|
|
2
|
+
msg: string;
|
|
3
|
+
}>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToOption<{
|
|
4
|
+
msg: string;
|
|
5
|
+
}>>>, {}, {}>;
|
|
6
|
+
export default _default;
|
|
7
|
+
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
8
|
+
type __VLS_TypePropsToOption<T> = {
|
|
9
|
+
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
10
|
+
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
11
|
+
} : {
|
|
12
|
+
type: import('vue').PropType<T[K]>;
|
|
13
|
+
required: true;
|
|
14
|
+
};
|
|
15
|
+
};
|
|
@@ -0,0 +1,266 @@
|
|
|
1
|
+
import { type VNode } from 'vue';
|
|
2
|
+
import { type ButtonPassThroughOptions } from 'primevue/button';
|
|
3
|
+
import type { PassThroughOptions } from 'primevue/passthrough';
|
|
4
|
+
import type { PassThrough, HintedString } from 'primevue/ts-helpers';
|
|
5
|
+
declare const _default: __VLS_WithTemplateSlots<import("vue").DefineComponent<__VLS_TypePropsToOption<{
|
|
6
|
+
/**
|
|
7
|
+
* Text of the button.
|
|
8
|
+
*/
|
|
9
|
+
label?: string;
|
|
10
|
+
/**
|
|
11
|
+
* Name of the icon.
|
|
12
|
+
*/
|
|
13
|
+
icon?: string;
|
|
14
|
+
/**
|
|
15
|
+
* Position of the icon.
|
|
16
|
+
* @defaultValue left
|
|
17
|
+
*/
|
|
18
|
+
iconPos?: "left" | "top" | "bottom" | "right";
|
|
19
|
+
/**
|
|
20
|
+
* Style class of the icon.
|
|
21
|
+
*/
|
|
22
|
+
iconClass?: string;
|
|
23
|
+
/**
|
|
24
|
+
* Value of the badge.
|
|
25
|
+
*/
|
|
26
|
+
badge?: string;
|
|
27
|
+
/**
|
|
28
|
+
* Style class of the badge.
|
|
29
|
+
*/
|
|
30
|
+
badgeClass?: string;
|
|
31
|
+
/**
|
|
32
|
+
* Severity type of the badge.
|
|
33
|
+
*/
|
|
34
|
+
badgeSeverity?: HintedString<"success" | "secondary" | "info" | "warning" | "danger" | "contrast">;
|
|
35
|
+
/**
|
|
36
|
+
* Whether the button is in loading state.
|
|
37
|
+
* @defaultValue false
|
|
38
|
+
*/
|
|
39
|
+
loading?: boolean;
|
|
40
|
+
/**
|
|
41
|
+
* Icon to display in loading state.
|
|
42
|
+
*/
|
|
43
|
+
loadingIcon?: string;
|
|
44
|
+
/**
|
|
45
|
+
* Add a link style to the button.
|
|
46
|
+
* @defaultValue false
|
|
47
|
+
*/
|
|
48
|
+
link?: boolean;
|
|
49
|
+
/**
|
|
50
|
+
* Defines the style of the button.
|
|
51
|
+
*/
|
|
52
|
+
severity?: HintedString<"success" | "help" | "secondary" | "info" | "warning" | "danger" | "contrast">;
|
|
53
|
+
/**
|
|
54
|
+
* Add a shadow to indicate elevation.
|
|
55
|
+
* @defaultValue false
|
|
56
|
+
*/
|
|
57
|
+
raised?: boolean;
|
|
58
|
+
/**
|
|
59
|
+
* Add a circular border radius to the button.
|
|
60
|
+
* @defaultValue false
|
|
61
|
+
*/
|
|
62
|
+
rounded?: boolean;
|
|
63
|
+
/**
|
|
64
|
+
* Add a textual class to the button without a background initially.
|
|
65
|
+
* @defaultValue false
|
|
66
|
+
*/
|
|
67
|
+
text?: boolean;
|
|
68
|
+
/**
|
|
69
|
+
* Add a border class without a background initially.
|
|
70
|
+
* @defaultValue false
|
|
71
|
+
*/
|
|
72
|
+
outlined?: boolean;
|
|
73
|
+
/**
|
|
74
|
+
* Defines the size of the button.
|
|
75
|
+
*/
|
|
76
|
+
size?: "small" | "large";
|
|
77
|
+
/**
|
|
78
|
+
* Add a plain textual class to the button without a background initially.
|
|
79
|
+
* @defaultValue false
|
|
80
|
+
*/
|
|
81
|
+
plain?: boolean;
|
|
82
|
+
/**
|
|
83
|
+
* Used to pass attributes to DOM elements inside the component.
|
|
84
|
+
* @type {ButtonPassThroughOptions}
|
|
85
|
+
*/
|
|
86
|
+
pt?: PassThrough<ButtonPassThroughOptions<any>>;
|
|
87
|
+
/**
|
|
88
|
+
* Used to configure passthrough(pt) options of the component.
|
|
89
|
+
* @type {PassThroughOptions}
|
|
90
|
+
*/
|
|
91
|
+
ptOptions?: PassThroughOptions;
|
|
92
|
+
/**
|
|
93
|
+
* When enabled, it removes component related styles in the core.
|
|
94
|
+
* @defaultValue false
|
|
95
|
+
*/
|
|
96
|
+
unstyled?: boolean;
|
|
97
|
+
}>, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<__VLS_TypePropsToOption<{
|
|
98
|
+
/**
|
|
99
|
+
* Text of the button.
|
|
100
|
+
*/
|
|
101
|
+
label?: string;
|
|
102
|
+
/**
|
|
103
|
+
* Name of the icon.
|
|
104
|
+
*/
|
|
105
|
+
icon?: string;
|
|
106
|
+
/**
|
|
107
|
+
* Position of the icon.
|
|
108
|
+
* @defaultValue left
|
|
109
|
+
*/
|
|
110
|
+
iconPos?: "left" | "top" | "bottom" | "right";
|
|
111
|
+
/**
|
|
112
|
+
* Style class of the icon.
|
|
113
|
+
*/
|
|
114
|
+
iconClass?: string;
|
|
115
|
+
/**
|
|
116
|
+
* Value of the badge.
|
|
117
|
+
*/
|
|
118
|
+
badge?: string;
|
|
119
|
+
/**
|
|
120
|
+
* Style class of the badge.
|
|
121
|
+
*/
|
|
122
|
+
badgeClass?: string;
|
|
123
|
+
/**
|
|
124
|
+
* Severity type of the badge.
|
|
125
|
+
*/
|
|
126
|
+
badgeSeverity?: HintedString<"success" | "secondary" | "info" | "warning" | "danger" | "contrast">;
|
|
127
|
+
/**
|
|
128
|
+
* Whether the button is in loading state.
|
|
129
|
+
* @defaultValue false
|
|
130
|
+
*/
|
|
131
|
+
loading?: boolean;
|
|
132
|
+
/**
|
|
133
|
+
* Icon to display in loading state.
|
|
134
|
+
*/
|
|
135
|
+
loadingIcon?: string;
|
|
136
|
+
/**
|
|
137
|
+
* Add a link style to the button.
|
|
138
|
+
* @defaultValue false
|
|
139
|
+
*/
|
|
140
|
+
link?: boolean;
|
|
141
|
+
/**
|
|
142
|
+
* Defines the style of the button.
|
|
143
|
+
*/
|
|
144
|
+
severity?: HintedString<"success" | "help" | "secondary" | "info" | "warning" | "danger" | "contrast">;
|
|
145
|
+
/**
|
|
146
|
+
* Add a shadow to indicate elevation.
|
|
147
|
+
* @defaultValue false
|
|
148
|
+
*/
|
|
149
|
+
raised?: boolean;
|
|
150
|
+
/**
|
|
151
|
+
* Add a circular border radius to the button.
|
|
152
|
+
* @defaultValue false
|
|
153
|
+
*/
|
|
154
|
+
rounded?: boolean;
|
|
155
|
+
/**
|
|
156
|
+
* Add a textual class to the button without a background initially.
|
|
157
|
+
* @defaultValue false
|
|
158
|
+
*/
|
|
159
|
+
text?: boolean;
|
|
160
|
+
/**
|
|
161
|
+
* Add a border class without a background initially.
|
|
162
|
+
* @defaultValue false
|
|
163
|
+
*/
|
|
164
|
+
outlined?: boolean;
|
|
165
|
+
/**
|
|
166
|
+
* Defines the size of the button.
|
|
167
|
+
*/
|
|
168
|
+
size?: "small" | "large";
|
|
169
|
+
/**
|
|
170
|
+
* Add a plain textual class to the button without a background initially.
|
|
171
|
+
* @defaultValue false
|
|
172
|
+
*/
|
|
173
|
+
plain?: boolean;
|
|
174
|
+
/**
|
|
175
|
+
* Used to pass attributes to DOM elements inside the component.
|
|
176
|
+
* @type {ButtonPassThroughOptions}
|
|
177
|
+
*/
|
|
178
|
+
pt?: PassThrough<ButtonPassThroughOptions<any>>;
|
|
179
|
+
/**
|
|
180
|
+
* Used to configure passthrough(pt) options of the component.
|
|
181
|
+
* @type {PassThroughOptions}
|
|
182
|
+
*/
|
|
183
|
+
ptOptions?: PassThroughOptions;
|
|
184
|
+
/**
|
|
185
|
+
* When enabled, it removes component related styles in the core.
|
|
186
|
+
* @defaultValue false
|
|
187
|
+
*/
|
|
188
|
+
unstyled?: boolean;
|
|
189
|
+
}>>>, {}, {}>, Readonly<{
|
|
190
|
+
/**
|
|
191
|
+
* Custom content such as icons, images and text can be placed inside the button via the default slot. Note that when slot is used, label, icon and badge properties are not included.
|
|
192
|
+
*/
|
|
193
|
+
default(): VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
194
|
+
[key: string]: any;
|
|
195
|
+
}>[];
|
|
196
|
+
/**
|
|
197
|
+
* Custom icon template.
|
|
198
|
+
* @param {Object} scope - icon slot's params.
|
|
199
|
+
*/
|
|
200
|
+
icon(scope: {
|
|
201
|
+
/**
|
|
202
|
+
* Style class of the icon.
|
|
203
|
+
*/
|
|
204
|
+
class: string;
|
|
205
|
+
}): VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
206
|
+
[key: string]: any;
|
|
207
|
+
}>[];
|
|
208
|
+
/**
|
|
209
|
+
* Custom loading icon template.
|
|
210
|
+
* @param {Object} scope - loading icon slot's params.
|
|
211
|
+
*/
|
|
212
|
+
loadingicon(scope: {
|
|
213
|
+
/**
|
|
214
|
+
* Style class of the loading icon.
|
|
215
|
+
*/
|
|
216
|
+
class: string;
|
|
217
|
+
}): VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
218
|
+
[key: string]: any;
|
|
219
|
+
}>[];
|
|
220
|
+
}> & {
|
|
221
|
+
/**
|
|
222
|
+
* Custom content such as icons, images and text can be placed inside the button via the default slot. Note that when slot is used, label, icon and badge properties are not included.
|
|
223
|
+
*/
|
|
224
|
+
default(): VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
225
|
+
[key: string]: any;
|
|
226
|
+
}>[];
|
|
227
|
+
/**
|
|
228
|
+
* Custom icon template.
|
|
229
|
+
* @param {Object} scope - icon slot's params.
|
|
230
|
+
*/
|
|
231
|
+
icon(scope: {
|
|
232
|
+
/**
|
|
233
|
+
* Style class of the icon.
|
|
234
|
+
*/
|
|
235
|
+
class: string;
|
|
236
|
+
}): VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
237
|
+
[key: string]: any;
|
|
238
|
+
}>[];
|
|
239
|
+
/**
|
|
240
|
+
* Custom loading icon template.
|
|
241
|
+
* @param {Object} scope - loading icon slot's params.
|
|
242
|
+
*/
|
|
243
|
+
loadingicon(scope: {
|
|
244
|
+
/**
|
|
245
|
+
* Style class of the loading icon.
|
|
246
|
+
*/
|
|
247
|
+
class: string;
|
|
248
|
+
}): VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
249
|
+
[key: string]: any;
|
|
250
|
+
}>[];
|
|
251
|
+
}>;
|
|
252
|
+
export default _default;
|
|
253
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
254
|
+
new (): {
|
|
255
|
+
$slots: S;
|
|
256
|
+
};
|
|
257
|
+
};
|
|
258
|
+
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
259
|
+
type __VLS_TypePropsToOption<T> = {
|
|
260
|
+
[K in keyof T]-?: {} extends Pick<T, K> ? {
|
|
261
|
+
type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
|
|
262
|
+
} : {
|
|
263
|
+
type: import('vue').PropType<T[K]>;
|
|
264
|
+
required: true;
|
|
265
|
+
};
|
|
266
|
+
};
|
package/dist/index.d.ts
ADDED