@lazhus/kg-ui 0.2.2
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 +128 -0
- package/custom-elements.json +3815 -0
- package/dist/components/kg-accordion-item.js +117 -0
- package/dist/components/kg-accordion.js +32 -0
- package/dist/components/kg-button.js +241 -0
- package/dist/components/kg-card.js +129 -0
- package/dist/components/kg-checkbox.js +147 -0
- package/dist/components/kg-colorpicker.js +240 -0
- package/dist/components/kg-column.js +48 -0
- package/dist/components/kg-datagrid.js +428 -0
- package/dist/components/kg-datepicker.js +650 -0
- package/dist/components/kg-divider.js +118 -0
- package/dist/components/kg-drawer.js +178 -0
- package/dist/components/kg-file-upload.js +274 -0
- package/dist/components/kg-grid.js +46 -0
- package/dist/components/kg-image.js +100 -0
- package/dist/components/kg-input.js +318 -0
- package/dist/components/kg-loader.js +175 -0
- package/dist/components/kg-modal.js +165 -0
- package/dist/components/kg-progress.js +82 -0
- package/dist/components/kg-radio-group.js +75 -0
- package/dist/components/kg-radio.js +121 -0
- package/dist/components/kg-row.js +42 -0
- package/dist/components/kg-select.js +331 -0
- package/dist/components/kg-skeleton.js +108 -0
- package/dist/components/kg-slider.js +196 -0
- package/dist/components/kg-spinner.js +79 -0
- package/dist/components/kg-stepper.js +214 -0
- package/dist/components/kg-switch.js +106 -0
- package/dist/components/kg-tab-panel.js +35 -0
- package/dist/components/kg-tabs.js +158 -0
- package/dist/components/kg-text.js +141 -0
- package/dist/components/kg-textarea.js +162 -0
- package/dist/components/kg-toast.js +200 -0
- package/dist/index.js +68 -0
- package/dist/kg-ui.css +1 -0
- package/package.json +57 -0
- package/types/components/kg-accordion-item.d.ts +25 -0
- package/types/components/kg-accordion.d.ts +22 -0
- package/types/components/kg-button.d.ts +34 -0
- package/types/components/kg-card.d.ts +31 -0
- package/types/components/kg-checkbox.d.ts +28 -0
- package/types/components/kg-colorpicker.d.ts +28 -0
- package/types/components/kg-column.d.ts +20 -0
- package/types/components/kg-datagrid.d.ts +55 -0
- package/types/components/kg-datepicker.d.ts +43 -0
- package/types/components/kg-divider.d.ts +34 -0
- package/types/components/kg-drawer.d.ts +31 -0
- package/types/components/kg-file-upload.d.ts +40 -0
- package/types/components/kg-grid.d.ts +20 -0
- package/types/components/kg-image.d.ts +40 -0
- package/types/components/kg-input.d.ts +34 -0
- package/types/components/kg-loader.d.ts +31 -0
- package/types/components/kg-modal.d.ts +31 -0
- package/types/components/kg-progress.d.ts +37 -0
- package/types/components/kg-radio-group.d.ts +25 -0
- package/types/components/kg-radio.d.ts +25 -0
- package/types/components/kg-row.d.ts +20 -0
- package/types/components/kg-select.d.ts +37 -0
- package/types/components/kg-skeleton.d.ts +34 -0
- package/types/components/kg-slider.d.ts +40 -0
- package/types/components/kg-spinner.d.ts +28 -0
- package/types/components/kg-stepper.d.ts +31 -0
- package/types/components/kg-switch.d.ts +28 -0
- package/types/components/kg-tab-panel.d.ts +28 -0
- package/types/components/kg-tabs.d.ts +25 -0
- package/types/components/kg-text.d.ts +31 -0
- package/types/components/kg-textarea.d.ts +43 -0
- package/types/components/kg-toast.d.ts +28 -0
- package/types/index.d.ts +335 -0
package/types/index.d.ts
ADDED
|
@@ -0,0 +1,335 @@
|
|
|
1
|
+
import { LitElement } from 'lit';
|
|
2
|
+
|
|
3
|
+
export { kgaccordionitem } from './components/kg-accordion-item';
|
|
4
|
+
export { kgaccordion } from './components/kg-accordion';
|
|
5
|
+
export { kgbutton } from './components/kg-button';
|
|
6
|
+
export { kgcard } from './components/kg-card';
|
|
7
|
+
export { kgcheckbox } from './components/kg-checkbox';
|
|
8
|
+
export { kgcolorpicker } from './components/kg-colorpicker';
|
|
9
|
+
export { kgcolumn } from './components/kg-column';
|
|
10
|
+
export { kgdatagrid } from './components/kg-datagrid';
|
|
11
|
+
export { kgdatepicker } from './components/kg-datepicker';
|
|
12
|
+
export { kgdivider } from './components/kg-divider';
|
|
13
|
+
export { kgdrawer } from './components/kg-drawer';
|
|
14
|
+
export { kgfileupload } from './components/kg-file-upload';
|
|
15
|
+
export { kggrid } from './components/kg-grid';
|
|
16
|
+
export { kgimage } from './components/kg-image';
|
|
17
|
+
export { kginput } from './components/kg-input';
|
|
18
|
+
export { kgloader } from './components/kg-loader';
|
|
19
|
+
export { kgmodal } from './components/kg-modal';
|
|
20
|
+
export { kgprogress } from './components/kg-progress';
|
|
21
|
+
export { kgradiogroup } from './components/kg-radio-group';
|
|
22
|
+
export { kgradio } from './components/kg-radio';
|
|
23
|
+
export { kgrow } from './components/kg-row';
|
|
24
|
+
export { kgselect } from './components/kg-select';
|
|
25
|
+
export { kgskeleton } from './components/kg-skeleton';
|
|
26
|
+
export { kgslider } from './components/kg-slider';
|
|
27
|
+
export { kgspinner } from './components/kg-spinner';
|
|
28
|
+
export { kgstepper } from './components/kg-stepper';
|
|
29
|
+
export { kgswitch } from './components/kg-switch';
|
|
30
|
+
export { kgtabpanel } from './components/kg-tab-panel';
|
|
31
|
+
export { kgtabs } from './components/kg-tabs';
|
|
32
|
+
export { kgtext } from './components/kg-text';
|
|
33
|
+
export { kgtextarea } from './components/kg-textarea';
|
|
34
|
+
export { kgtoast } from './components/kg-toast';
|
|
35
|
+
|
|
36
|
+
declare global {
|
|
37
|
+
interface HTMLElementTagNameMap {
|
|
38
|
+
'kg-accordion-item': kgaccordionitem;
|
|
39
|
+
'kg-accordion': kgaccordion;
|
|
40
|
+
'kg-button': kgbutton;
|
|
41
|
+
'kg-card': kgcard;
|
|
42
|
+
'kg-checkbox': kgcheckbox;
|
|
43
|
+
'kg-colorpicker': kgcolorpicker;
|
|
44
|
+
'kg-column': kgcolumn;
|
|
45
|
+
'kg-datagrid': kgdatagrid;
|
|
46
|
+
'kg-datepicker': kgdatepicker;
|
|
47
|
+
'kg-divider': kgdivider;
|
|
48
|
+
'kg-drawer': kgdrawer;
|
|
49
|
+
'kg-file-upload': kgfileupload;
|
|
50
|
+
'kg-grid': kggrid;
|
|
51
|
+
'kg-image': kgimage;
|
|
52
|
+
'kg-input': kginput;
|
|
53
|
+
'kg-loader': kgloader;
|
|
54
|
+
'kg-modal': kgmodal;
|
|
55
|
+
'kg-progress': kgprogress;
|
|
56
|
+
'kg-radio-group': kgradiogroup;
|
|
57
|
+
'kg-radio': kgradio;
|
|
58
|
+
'kg-row': kgrow;
|
|
59
|
+
'kg-select': kgselect;
|
|
60
|
+
'kg-skeleton': kgskeleton;
|
|
61
|
+
'kg-slider': kgslider;
|
|
62
|
+
'kg-spinner': kgspinner;
|
|
63
|
+
'kg-stepper': kgstepper;
|
|
64
|
+
'kg-switch': kgswitch;
|
|
65
|
+
'kg-tab-panel': kgtabpanel;
|
|
66
|
+
'kg-tabs': kgtabs;
|
|
67
|
+
'kg-text': kgtext;
|
|
68
|
+
'kg-textarea': kgtextarea;
|
|
69
|
+
'kg-toast': kgtoast;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
namespace JSX {
|
|
73
|
+
interface IntrinsicElements {
|
|
74
|
+
'kg-accordion-item': {
|
|
75
|
+
open?: boolean;
|
|
76
|
+
disabled?: boolean;
|
|
77
|
+
[key: string]: any;
|
|
78
|
+
};
|
|
79
|
+
'kg-accordion': {
|
|
80
|
+
exclusive?: boolean;
|
|
81
|
+
[key: string]: any;
|
|
82
|
+
};
|
|
83
|
+
'kg-button': {
|
|
84
|
+
color?: string;
|
|
85
|
+
size?: string;
|
|
86
|
+
hasText?: boolean;
|
|
87
|
+
hasLeft?: boolean;
|
|
88
|
+
hasRight?: boolean;
|
|
89
|
+
[key: string]: any;
|
|
90
|
+
};
|
|
91
|
+
'kg-card': {
|
|
92
|
+
raised?: boolean;
|
|
93
|
+
inverted?: boolean;
|
|
94
|
+
basic?: boolean;
|
|
95
|
+
padded?: boolean;
|
|
96
|
+
[key: string]: any;
|
|
97
|
+
};
|
|
98
|
+
'kg-checkbox': {
|
|
99
|
+
checked?: boolean;
|
|
100
|
+
disabled?: boolean;
|
|
101
|
+
indeterminate?: boolean;
|
|
102
|
+
[key: string]: any;
|
|
103
|
+
};
|
|
104
|
+
'kg-colorpicker': {
|
|
105
|
+
value?: string;
|
|
106
|
+
open?: boolean;
|
|
107
|
+
disabled?: boolean;
|
|
108
|
+
[key: string]: any;
|
|
109
|
+
};
|
|
110
|
+
'kg-column': {
|
|
111
|
+
|
|
112
|
+
[key: string]: any;
|
|
113
|
+
};
|
|
114
|
+
'kg-datagrid': {
|
|
115
|
+
columns?: any[];
|
|
116
|
+
data?: any[];
|
|
117
|
+
loading?: boolean;
|
|
118
|
+
striped?: boolean;
|
|
119
|
+
bordered?: boolean;
|
|
120
|
+
hover?: boolean;
|
|
121
|
+
selectable?: boolean;
|
|
122
|
+
selectionMode?: string;
|
|
123
|
+
selectedRows?: any[];
|
|
124
|
+
sortable?: boolean;
|
|
125
|
+
pagination?: boolean;
|
|
126
|
+
pageSize?: number;
|
|
127
|
+
[key: string]: any;
|
|
128
|
+
};
|
|
129
|
+
'kg-datepicker': {
|
|
130
|
+
open?: boolean;
|
|
131
|
+
disabled?: boolean;
|
|
132
|
+
mode?: string;
|
|
133
|
+
locale?: string;
|
|
134
|
+
placeholder?: string;
|
|
135
|
+
min?: string;
|
|
136
|
+
max?: string;
|
|
137
|
+
value?: string;
|
|
138
|
+
[key: string]: any;
|
|
139
|
+
};
|
|
140
|
+
'kg-divider': {
|
|
141
|
+
vertical?: boolean;
|
|
142
|
+
dashed?: boolean;
|
|
143
|
+
fitted?: boolean;
|
|
144
|
+
inverted?: boolean;
|
|
145
|
+
label?: string;
|
|
146
|
+
[key: string]: any;
|
|
147
|
+
};
|
|
148
|
+
'kg-drawer': {
|
|
149
|
+
open?: boolean;
|
|
150
|
+
placement?: string;
|
|
151
|
+
size?: string;
|
|
152
|
+
closable?: boolean;
|
|
153
|
+
[key: string]: any;
|
|
154
|
+
};
|
|
155
|
+
'kg-file-upload': {
|
|
156
|
+
label?: string;
|
|
157
|
+
placeholder?: string;
|
|
158
|
+
accept?: string;
|
|
159
|
+
multiple?: boolean;
|
|
160
|
+
disabled?: boolean;
|
|
161
|
+
hideChips?: boolean;
|
|
162
|
+
files?: any[];
|
|
163
|
+
[key: string]: any;
|
|
164
|
+
};
|
|
165
|
+
'kg-grid': {
|
|
166
|
+
|
|
167
|
+
[key: string]: any;
|
|
168
|
+
};
|
|
169
|
+
'kg-image': {
|
|
170
|
+
src?: string;
|
|
171
|
+
alt?: string;
|
|
172
|
+
width?: string;
|
|
173
|
+
height?: string;
|
|
174
|
+
fit?: string;
|
|
175
|
+
shape?: string;
|
|
176
|
+
lazy?: boolean;
|
|
177
|
+
[key: string]: any;
|
|
178
|
+
};
|
|
179
|
+
'kg-input': {
|
|
180
|
+
type?: string;
|
|
181
|
+
value?: string;
|
|
182
|
+
placeholder?: string;
|
|
183
|
+
hasLeft?: boolean;
|
|
184
|
+
hasRight?: boolean;
|
|
185
|
+
[key: string]: any;
|
|
186
|
+
};
|
|
187
|
+
'kg-loader': {
|
|
188
|
+
src?: string;
|
|
189
|
+
text?: string;
|
|
190
|
+
visible?: boolean;
|
|
191
|
+
glass?: boolean;
|
|
192
|
+
[key: string]: any;
|
|
193
|
+
};
|
|
194
|
+
'kg-modal': {
|
|
195
|
+
open?: boolean;
|
|
196
|
+
size?: string;
|
|
197
|
+
closable?: boolean;
|
|
198
|
+
basic?: boolean;
|
|
199
|
+
[key: string]: any;
|
|
200
|
+
};
|
|
201
|
+
'kg-progress': {
|
|
202
|
+
value?: number;
|
|
203
|
+
max?: number;
|
|
204
|
+
color?: string;
|
|
205
|
+
height?: string;
|
|
206
|
+
showValue?: boolean;
|
|
207
|
+
indeterminate?: boolean;
|
|
208
|
+
[key: string]: any;
|
|
209
|
+
};
|
|
210
|
+
'kg-radio-group': {
|
|
211
|
+
direction?: string;
|
|
212
|
+
value?: string;
|
|
213
|
+
[key: string]: any;
|
|
214
|
+
};
|
|
215
|
+
'kg-radio': {
|
|
216
|
+
checked?: boolean;
|
|
217
|
+
disabled?: boolean;
|
|
218
|
+
[key: string]: any;
|
|
219
|
+
};
|
|
220
|
+
'kg-row': {
|
|
221
|
+
|
|
222
|
+
[key: string]: any;
|
|
223
|
+
};
|
|
224
|
+
'kg-select': {
|
|
225
|
+
options?: any[];
|
|
226
|
+
value?: any;
|
|
227
|
+
placeholder?: string;
|
|
228
|
+
multiple?: boolean;
|
|
229
|
+
disabled?: boolean;
|
|
230
|
+
searchable?: boolean;
|
|
231
|
+
[key: string]: any;
|
|
232
|
+
};
|
|
233
|
+
'kg-skeleton': {
|
|
234
|
+
variant?: string;
|
|
235
|
+
animation?: string;
|
|
236
|
+
width?: string;
|
|
237
|
+
height?: string;
|
|
238
|
+
borderRadius?: string;
|
|
239
|
+
[key: string]: any;
|
|
240
|
+
};
|
|
241
|
+
'kg-slider': {
|
|
242
|
+
value?: number;
|
|
243
|
+
min?: number;
|
|
244
|
+
max?: number;
|
|
245
|
+
step?: number;
|
|
246
|
+
disabled?: boolean;
|
|
247
|
+
hideValue?: boolean;
|
|
248
|
+
showPins?: boolean;
|
|
249
|
+
[key: string]: any;
|
|
250
|
+
};
|
|
251
|
+
'kg-spinner': {
|
|
252
|
+
size?: string;
|
|
253
|
+
color?: string;
|
|
254
|
+
thickness?: number;
|
|
255
|
+
[key: string]: any;
|
|
256
|
+
};
|
|
257
|
+
'kg-stepper': {
|
|
258
|
+
steps?: any[];
|
|
259
|
+
activeStep?: number;
|
|
260
|
+
vertical?: boolean;
|
|
261
|
+
clickable?: boolean;
|
|
262
|
+
[key: string]: any;
|
|
263
|
+
};
|
|
264
|
+
'kg-switch': {
|
|
265
|
+
checked?: boolean;
|
|
266
|
+
disabled?: boolean;
|
|
267
|
+
color?: string;
|
|
268
|
+
[key: string]: any;
|
|
269
|
+
};
|
|
270
|
+
'kg-tab-panel': {
|
|
271
|
+
value?: string;
|
|
272
|
+
label?: string;
|
|
273
|
+
active?: boolean;
|
|
274
|
+
[key: string]: any;
|
|
275
|
+
};
|
|
276
|
+
'kg-tabs': {
|
|
277
|
+
activeTab?: string;
|
|
278
|
+
vertical?: boolean;
|
|
279
|
+
[key: string]: any;
|
|
280
|
+
};
|
|
281
|
+
'kg-text': {
|
|
282
|
+
variant?: string;
|
|
283
|
+
weight?: string;
|
|
284
|
+
align?: string;
|
|
285
|
+
dividing?: boolean;
|
|
286
|
+
[key: string]: any;
|
|
287
|
+
};
|
|
288
|
+
'kg-textarea': {
|
|
289
|
+
value?: string;
|
|
290
|
+
placeholder?: string;
|
|
291
|
+
rows?: number;
|
|
292
|
+
disabled?: boolean;
|
|
293
|
+
error?: boolean;
|
|
294
|
+
fullwidth?: boolean;
|
|
295
|
+
inverted?: boolean;
|
|
296
|
+
resize?: string;
|
|
297
|
+
[key: string]: any;
|
|
298
|
+
};
|
|
299
|
+
'kg-toast': {
|
|
300
|
+
duration?: number;
|
|
301
|
+
visible?: boolean;
|
|
302
|
+
color?: string;
|
|
303
|
+
[key: string]: any;
|
|
304
|
+
};
|
|
305
|
+
}
|
|
306
|
+
}
|
|
307
|
+
}
|
|
308
|
+
|
|
309
|
+
|
|
310
|
+
export interface ToastOptions {
|
|
311
|
+
title: string;
|
|
312
|
+
message?: string;
|
|
313
|
+
color?: 'primary' | 'secondary' | 'tertiary' | 'error';
|
|
314
|
+
duration?: number;
|
|
315
|
+
position?: 'top-right' | 'top-left' | 'bottom-right' | 'bottom-left';
|
|
316
|
+
}
|
|
317
|
+
|
|
318
|
+
export const toast: {
|
|
319
|
+
show(options: ToastOptions): void;
|
|
320
|
+
success(title: string, message?: string): void;
|
|
321
|
+
error(title: string, message?: string): void;
|
|
322
|
+
info(title: string, message?: string): void;
|
|
323
|
+
warning(title: string, message?: string): void;
|
|
324
|
+
};
|
|
325
|
+
|
|
326
|
+
export interface LoaderOptions {
|
|
327
|
+
src?: string;
|
|
328
|
+
text?: string;
|
|
329
|
+
glass?: boolean;
|
|
330
|
+
}
|
|
331
|
+
|
|
332
|
+
export const loader: {
|
|
333
|
+
show(options?: LoaderOptions): void;
|
|
334
|
+
hide(): void;
|
|
335
|
+
};
|