ablok-components 0.0.31 → 0.0.34

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.
@@ -0,0 +1,439 @@
1
+ export declare function fileToDataUrl(file: File): Promise<any>;
2
+ declare const _default: {
3
+ new (...args: any[]): {
4
+ $: import("vue").ComponentInternalInstance;
5
+ $data: {};
6
+ $props: Partial<{
7
+ label: string;
8
+ pattern: string;
9
+ required: boolean;
10
+ modelValue: [{
11
+ type?: string | undefined;
12
+ src: string;
13
+ }][];
14
+ variant: string;
15
+ name: string;
16
+ id: string;
17
+ disabled: boolean;
18
+ readOnly: boolean;
19
+ placeholder: string;
20
+ multiple: boolean;
21
+ accept: string;
22
+ }> & Omit<Readonly<import("vue").ExtractPropTypes<{
23
+ modelValue: {
24
+ type: {
25
+ (arrayLength: number): [{
26
+ type?: string | undefined;
27
+ src: string;
28
+ }][];
29
+ (...items: [{
30
+ type?: string | undefined;
31
+ src: string;
32
+ }][]): [{
33
+ type?: string | undefined;
34
+ src: string;
35
+ }][];
36
+ new (arrayLength: number): [{
37
+ type?: string | undefined;
38
+ src: string;
39
+ }][];
40
+ new (...items: [{
41
+ type?: string | undefined;
42
+ src: string;
43
+ }][]): [{
44
+ type?: string | undefined;
45
+ src: string;
46
+ }][];
47
+ isArray(arg: any): arg is any[];
48
+ readonly prototype: any[];
49
+ from<T>(arrayLike: ArrayLike<T>): T[];
50
+ from<T_1, U>(arrayLike: ArrayLike<T_1>, mapfn: (v: T_1, k: number) => U, thisArg?: any): U[];
51
+ from<T_2>(iterable: Iterable<T_2> | ArrayLike<T_2>): T_2[];
52
+ from<T_3, U_1>(iterable: Iterable<T_3> | ArrayLike<T_3>, mapfn: (v: T_3, k: number) => U_1, thisArg?: any): U_1[];
53
+ of<T_4>(...items: T_4[]): T_4[];
54
+ readonly [Symbol.species]: ArrayConstructor;
55
+ };
56
+ default: never[];
57
+ };
58
+ src: {
59
+ type: StringConstructor;
60
+ };
61
+ name: {
62
+ type: StringConstructor;
63
+ default: () => string;
64
+ };
65
+ id: {
66
+ type: StringConstructor;
67
+ default: () => string;
68
+ };
69
+ label: {
70
+ type: StringConstructor;
71
+ default: string;
72
+ };
73
+ placeholder: {
74
+ type: StringConstructor;
75
+ default: string;
76
+ };
77
+ variant: {
78
+ type: StringConstructor;
79
+ default: string;
80
+ };
81
+ disabled: {
82
+ type: BooleanConstructor;
83
+ default: boolean;
84
+ };
85
+ readOnly: {
86
+ type: BooleanConstructor;
87
+ default: boolean;
88
+ };
89
+ required: {
90
+ type: BooleanConstructor;
91
+ default: boolean;
92
+ };
93
+ pattern: {
94
+ type: StringConstructor;
95
+ default: null;
96
+ };
97
+ multiple: {
98
+ type: BooleanConstructor;
99
+ default: boolean;
100
+ };
101
+ accept: {
102
+ type: StringConstructor;
103
+ default: string;
104
+ };
105
+ }>> & {
106
+ "onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
107
+ "onUpdate:src"?: ((...args: any[]) => any) | undefined;
108
+ } & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, "label" | "pattern" | "required" | "modelValue" | "variant" | "name" | "id" | "disabled" | "readOnly" | "placeholder" | "multiple" | "accept">;
109
+ $attrs: {
110
+ [x: string]: unknown;
111
+ };
112
+ $refs: {
113
+ [x: string]: unknown;
114
+ };
115
+ $slots: Readonly<{
116
+ [name: string]: import("vue").Slot | undefined;
117
+ }>;
118
+ $root: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}>> | null;
119
+ $parent: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}>> | null;
120
+ $emit: (event: "update:modelValue" | "update:src", ...args: any[]) => void;
121
+ $el: any;
122
+ $options: import("vue").ComponentOptionsBase<Readonly<import("vue").ExtractPropTypes<{
123
+ modelValue: {
124
+ type: {
125
+ (arrayLength: number): [{
126
+ type?: string | undefined;
127
+ src: string;
128
+ }][];
129
+ (...items: [{
130
+ type?: string | undefined;
131
+ src: string;
132
+ }][]): [{
133
+ type?: string | undefined;
134
+ src: string;
135
+ }][];
136
+ new (arrayLength: number): [{
137
+ type?: string | undefined;
138
+ src: string;
139
+ }][];
140
+ new (...items: [{
141
+ type?: string | undefined;
142
+ src: string;
143
+ }][]): [{
144
+ type?: string | undefined;
145
+ src: string;
146
+ }][];
147
+ isArray(arg: any): arg is any[];
148
+ readonly prototype: any[];
149
+ from<T>(arrayLike: ArrayLike<T>): T[];
150
+ from<T_1, U>(arrayLike: ArrayLike<T_1>, mapfn: (v: T_1, k: number) => U, thisArg?: any): U[];
151
+ from<T_2>(iterable: Iterable<T_2> | ArrayLike<T_2>): T_2[];
152
+ from<T_3, U_1>(iterable: Iterable<T_3> | ArrayLike<T_3>, mapfn: (v: T_3, k: number) => U_1, thisArg?: any): U_1[];
153
+ of<T_4>(...items: T_4[]): T_4[];
154
+ readonly [Symbol.species]: ArrayConstructor;
155
+ };
156
+ default: never[];
157
+ };
158
+ src: {
159
+ type: StringConstructor;
160
+ };
161
+ name: {
162
+ type: StringConstructor;
163
+ default: () => string;
164
+ };
165
+ id: {
166
+ type: StringConstructor;
167
+ default: () => string;
168
+ };
169
+ label: {
170
+ type: StringConstructor;
171
+ default: string;
172
+ };
173
+ placeholder: {
174
+ type: StringConstructor;
175
+ default: string;
176
+ };
177
+ variant: {
178
+ type: StringConstructor;
179
+ default: string;
180
+ };
181
+ disabled: {
182
+ type: BooleanConstructor;
183
+ default: boolean;
184
+ };
185
+ readOnly: {
186
+ type: BooleanConstructor;
187
+ default: boolean;
188
+ };
189
+ required: {
190
+ type: BooleanConstructor;
191
+ default: boolean;
192
+ };
193
+ pattern: {
194
+ type: StringConstructor;
195
+ default: null;
196
+ };
197
+ multiple: {
198
+ type: BooleanConstructor;
199
+ default: boolean;
200
+ };
201
+ accept: {
202
+ type: StringConstructor;
203
+ default: string;
204
+ };
205
+ }>> & {
206
+ "onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
207
+ "onUpdate:src"?: ((...args: any[]) => any) | undefined;
208
+ }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "update:src")[], string, {
209
+ label: string;
210
+ pattern: string;
211
+ required: boolean;
212
+ modelValue: [{
213
+ type?: string | undefined;
214
+ src: string;
215
+ }][];
216
+ variant: string;
217
+ name: string;
218
+ id: string;
219
+ disabled: boolean;
220
+ readOnly: boolean;
221
+ placeholder: string;
222
+ multiple: boolean;
223
+ accept: string;
224
+ }> & {
225
+ beforeCreate?: ((() => void) | (() => void)[]) | undefined;
226
+ created?: ((() => void) | (() => void)[]) | undefined;
227
+ beforeMount?: ((() => void) | (() => void)[]) | undefined;
228
+ mounted?: ((() => void) | (() => void)[]) | undefined;
229
+ beforeUpdate?: ((() => void) | (() => void)[]) | undefined;
230
+ updated?: ((() => void) | (() => void)[]) | undefined;
231
+ activated?: ((() => void) | (() => void)[]) | undefined;
232
+ deactivated?: ((() => void) | (() => void)[]) | undefined;
233
+ beforeDestroy?: ((() => void) | (() => void)[]) | undefined;
234
+ beforeUnmount?: ((() => void) | (() => void)[]) | undefined;
235
+ destroyed?: ((() => void) | (() => void)[]) | undefined;
236
+ unmounted?: ((() => void) | (() => void)[]) | undefined;
237
+ renderTracked?: (((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[]) | undefined;
238
+ renderTriggered?: (((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[]) | undefined;
239
+ errorCaptured?: (((err: unknown, instance: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}>> | null, info: string) => boolean | void) | ((err: unknown, instance: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}>> | null, info: string) => boolean | void)[]) | undefined;
240
+ };
241
+ $forceUpdate: () => void;
242
+ $nextTick: typeof import("vue").nextTick;
243
+ $watch(source: string | Function, cb: Function, options?: import("vue").WatchOptions<boolean> | undefined): import("vue").WatchStopHandle;
244
+ } & Readonly<import("vue").ExtractPropTypes<{
245
+ modelValue: {
246
+ type: {
247
+ (arrayLength: number): [{
248
+ type?: string | undefined;
249
+ src: string;
250
+ }][];
251
+ (...items: [{
252
+ type?: string | undefined;
253
+ src: string;
254
+ }][]): [{
255
+ type?: string | undefined;
256
+ src: string;
257
+ }][];
258
+ new (arrayLength: number): [{
259
+ type?: string | undefined;
260
+ src: string;
261
+ }][];
262
+ new (...items: [{
263
+ type?: string | undefined;
264
+ src: string;
265
+ }][]): [{
266
+ type?: string | undefined;
267
+ src: string;
268
+ }][];
269
+ isArray(arg: any): arg is any[];
270
+ readonly prototype: any[];
271
+ from<T>(arrayLike: ArrayLike<T>): T[];
272
+ from<T_1, U>(arrayLike: ArrayLike<T_1>, mapfn: (v: T_1, k: number) => U, thisArg?: any): U[];
273
+ from<T_2>(iterable: Iterable<T_2> | ArrayLike<T_2>): T_2[];
274
+ from<T_3, U_1>(iterable: Iterable<T_3> | ArrayLike<T_3>, mapfn: (v: T_3, k: number) => U_1, thisArg?: any): U_1[];
275
+ of<T_4>(...items: T_4[]): T_4[];
276
+ readonly [Symbol.species]: ArrayConstructor;
277
+ };
278
+ default: never[];
279
+ };
280
+ src: {
281
+ type: StringConstructor;
282
+ };
283
+ name: {
284
+ type: StringConstructor;
285
+ default: () => string;
286
+ };
287
+ id: {
288
+ type: StringConstructor;
289
+ default: () => string;
290
+ };
291
+ label: {
292
+ type: StringConstructor;
293
+ default: string;
294
+ };
295
+ placeholder: {
296
+ type: StringConstructor;
297
+ default: string;
298
+ };
299
+ variant: {
300
+ type: StringConstructor;
301
+ default: string;
302
+ };
303
+ disabled: {
304
+ type: BooleanConstructor;
305
+ default: boolean;
306
+ };
307
+ readOnly: {
308
+ type: BooleanConstructor;
309
+ default: boolean;
310
+ };
311
+ required: {
312
+ type: BooleanConstructor;
313
+ default: boolean;
314
+ };
315
+ pattern: {
316
+ type: StringConstructor;
317
+ default: null;
318
+ };
319
+ multiple: {
320
+ type: BooleanConstructor;
321
+ default: boolean;
322
+ };
323
+ accept: {
324
+ type: StringConstructor;
325
+ default: string;
326
+ };
327
+ }>> & {
328
+ "onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
329
+ "onUpdate:src"?: ((...args: any[]) => any) | undefined;
330
+ } & import("vue").ShallowUnwrapRef<{}> & {} & import("vue").ComponentCustomProperties;
331
+ __isFragment?: undefined;
332
+ __isTeleport?: undefined;
333
+ __isSuspense?: undefined;
334
+ } & import("vue").ComponentOptionsBase<Readonly<import("vue").ExtractPropTypes<{
335
+ modelValue: {
336
+ type: {
337
+ (arrayLength: number): [{
338
+ type?: string | undefined;
339
+ src: string;
340
+ }][];
341
+ (...items: [{
342
+ type?: string | undefined;
343
+ src: string;
344
+ }][]): [{
345
+ type?: string | undefined;
346
+ src: string;
347
+ }][];
348
+ new (arrayLength: number): [{
349
+ type?: string | undefined;
350
+ src: string;
351
+ }][];
352
+ new (...items: [{
353
+ type?: string | undefined;
354
+ src: string;
355
+ }][]): [{
356
+ type?: string | undefined;
357
+ src: string;
358
+ }][];
359
+ isArray(arg: any): arg is any[];
360
+ readonly prototype: any[];
361
+ from<T>(arrayLike: ArrayLike<T>): T[];
362
+ from<T_1, U>(arrayLike: ArrayLike<T_1>, mapfn: (v: T_1, k: number) => U, thisArg?: any): U[];
363
+ from<T_2>(iterable: Iterable<T_2> | ArrayLike<T_2>): T_2[];
364
+ from<T_3, U_1>(iterable: Iterable<T_3> | ArrayLike<T_3>, mapfn: (v: T_3, k: number) => U_1, thisArg?: any): U_1[];
365
+ of<T_4>(...items: T_4[]): T_4[];
366
+ readonly [Symbol.species]: ArrayConstructor;
367
+ };
368
+ default: never[];
369
+ };
370
+ src: {
371
+ type: StringConstructor;
372
+ };
373
+ name: {
374
+ type: StringConstructor;
375
+ default: () => string;
376
+ };
377
+ id: {
378
+ type: StringConstructor;
379
+ default: () => string;
380
+ };
381
+ label: {
382
+ type: StringConstructor;
383
+ default: string;
384
+ };
385
+ placeholder: {
386
+ type: StringConstructor;
387
+ default: string;
388
+ };
389
+ variant: {
390
+ type: StringConstructor;
391
+ default: string;
392
+ };
393
+ disabled: {
394
+ type: BooleanConstructor;
395
+ default: boolean;
396
+ };
397
+ readOnly: {
398
+ type: BooleanConstructor;
399
+ default: boolean;
400
+ };
401
+ required: {
402
+ type: BooleanConstructor;
403
+ default: boolean;
404
+ };
405
+ pattern: {
406
+ type: StringConstructor;
407
+ default: null;
408
+ };
409
+ multiple: {
410
+ type: BooleanConstructor;
411
+ default: boolean;
412
+ };
413
+ accept: {
414
+ type: StringConstructor;
415
+ default: string;
416
+ };
417
+ }>> & {
418
+ "onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
419
+ "onUpdate:src"?: ((...args: any[]) => any) | undefined;
420
+ }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "update:src")[], "update:modelValue" | "update:src", {
421
+ label: string;
422
+ pattern: string;
423
+ required: boolean;
424
+ modelValue: [{
425
+ type?: string | undefined;
426
+ src: string;
427
+ }][];
428
+ variant: string;
429
+ name: string;
430
+ id: string;
431
+ disabled: boolean;
432
+ readOnly: boolean;
433
+ placeholder: string;
434
+ multiple: boolean;
435
+ accept: string;
436
+ }> & import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & (new () => {
437
+ $slots: {};
438
+ });
439
+ export default _default;
package/dist/index.d.ts CHANGED
@@ -6,3 +6,4 @@ export { default as CheckGroup } from "./components/check-group.vue";
6
6
  export { default as RadioGroup } from "./components/radio-group.vue";
7
7
  export { default as InputDropdown } from "./components/input-dropdown.vue";
8
8
  export { default as FileInput } from "./components/file-input.vue";
9
+ export { default as MediaUpload } from "./components/media-upload.vue";
package/dist/style.css CHANGED
@@ -1 +1 @@
1
- .svg-icon{display:inline-block}.svg-icon svg{display:block;stroke-width:0;stroke:currentColor;fill:currentColor;width:1.5em;height:1.5em}.svg-icon--xxl svg{width:12rem;height:12rem}.svg-icon--xl svg{width:8rem;height:8rem}.svg-icon--large svg{width:4rem;height:4rem}.loading-spinner{min-width:2rem}.base-button{display:flex;justify-content:center;align-items:center;box-sizing:border-box;transition:all .2s ease;text-decoration:none;width:100%;margin:0;padding:1.036em 1.625em;appearance:none;outline:none;border:none;border-radius:.4375em;font-size:.875em;line-height:1.125em;text-transform:uppercase;font-weight:700}@media screen and (min-width: 600px){.base-button{width:auto}}.base-button .icon{width:16px;height:16px;margin-top:-1px}.base-button.s-collapsed>.caption{display:none}.base-button.s-pending{background-repeat:no-repeat;background-position:center center}.base-button.s-pending .caption{margin-left:25px;visibility:hidden}@media screen and (min-width: 600px){.base-button.s-pending{background-position:1.625em center}.base-button.s-pending .caption{visibility:visible}}.base-button[readonly],.base-button[disabled]{cursor:not-allowed}.form-input{display:flex;flex-flow:column}.form-input>*{order:2}.form-input__label{order:0}.form-input__input-group{flex-wrap:nowrap;order:1}.form-input__color-swatch{flex:0 0 3rem;display:block;border-top-right-radius:var(--border-radius);border-bottom-right-radius:var(--border-radius);overflow:hidden;border:thin solid var(--border-color);border-left:none}.form-input input[type=color]{display:block;height:100%;padding:0;border-width:0}.form-input input[type=color]::-webkit-color-swatch-wrapper{padding:0}.form-input input[type=color]::-webkit-color-swatch{border:none}:root,*:before,*:after{--border-color: #ced4da;--border-radius: .25rem}.file-input{display:flex;flex-flow:column}.file-input>*{order:2}.file-input__label{order:0}.file-input__input-group{flex-wrap:nowrap;order:1}.file-input__color-swatch{flex:0 0 3rem;display:block;border-top-right-radius:var(--border-radius);border-bottom-right-radius:var(--border-radius);overflow:hidden;border:thin solid var(--border-color);border-left:none}.file-input input[type=color]{display:block;height:100%;padding:0;border-width:0}.file-input input[type=color]::-webkit-color-swatch-wrapper{padding:0}.file-input input[type=color]::-webkit-color-swatch{border:none}
1
+ .svg-icon{display:inline-block}.svg-icon svg{display:block;stroke-width:0;stroke:currentColor;fill:currentColor;width:1.5em;height:1.5em}.svg-icon--xxl svg{width:12rem;height:12rem}.svg-icon--xl svg{width:8rem;height:8rem}.svg-icon--large svg{width:4rem;height:4rem}.loading-spinner{min-width:2rem}.base-button{display:flex;justify-content:center;align-items:center;box-sizing:border-box;transition:all .2s ease;text-decoration:none;width:100%;margin:0;padding:1.036em 1.625em;appearance:none;outline:none;border:none;border-radius:.4375em;font-size:.875em;line-height:1.125em;text-transform:uppercase;font-weight:700}@media screen and (min-width: 600px){.base-button{width:auto}}.base-button .icon{width:16px;height:16px;margin-top:-1px}.base-button.s-collapsed>.caption{display:none}.base-button.s-pending{background-repeat:no-repeat;background-position:center center}.base-button.s-pending .caption{margin-left:25px;visibility:hidden}@media screen and (min-width: 600px){.base-button.s-pending{background-position:1.625em center}.base-button.s-pending .caption{visibility:visible}}.base-button[readonly],.base-button[disabled]{cursor:not-allowed}.form-input{display:flex;flex-flow:column}.form-input>*{order:2}.form-input__label{order:0}.form-input__input-group{flex-wrap:nowrap;order:1}.form-input__color-swatch{flex:0 0 3rem;display:block;border-top-right-radius:var(--border-radius);border-bottom-right-radius:var(--border-radius);overflow:hidden;border:thin solid var(--border-color);border-left:none}.form-input input[type=color]{display:block;height:100%;padding:0;border-width:0}.form-input input[type=color]::-webkit-color-swatch-wrapper{padding:0}.form-input input[type=color]::-webkit-color-swatch{border:none}:root,*:before,*:after{--border-color: #ced4da;--border-radius: .25rem}.media-upload__thumbnail{position:relative}.media-upload__thumbnail .btn{position:absolute;right:0;top:0}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "ablok-components",
3
3
  "private": false,
4
- "version": "0.0.31",
4
+ "version": "0.0.34",
5
5
  "scripts": {
6
6
  "dev": "vite",
7
7
  "build": "vue-tsc --noEmit && vite build",