@webx-ui/core 0.10.0 → 0.12.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/dist/components/Actions/Actions.d.ts +8 -2
- package/dist/components/Descriptions/types.d.ts +2 -0
- package/dist/components/FileCard/FileCard.d.ts +322 -0
- package/dist/components/FileCard/files.d.ts +22 -0
- package/dist/components/FileCard/index.d.ts +3 -0
- package/dist/components/FileCard/types.d.ts +64 -0
- package/dist/components/Icon/icons.d.ts +76 -0
- package/dist/components/SelectionArea/SelectionArea.d.ts +2 -0
- package/dist/components/SelectionArea/types.d.ts +10 -1
- package/dist/components/Steps/Steps.d.ts +7 -2
- package/dist/components/Steps/types.d.ts +5 -0
- package/dist/components/Tooltip/Tooltip.d.ts +1 -1
- package/dist/components/Tree/types.d.ts +6 -0
- package/dist/components/Upload/Upload.d.ts +1 -1
- package/dist/components/index.d.ts +1 -0
- package/dist/index.js +6123 -5607
- package/dist/index.js.map +1 -1
- package/dist/internal/nodes.d.ts +10 -0
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -1,10 +1,14 @@
|
|
|
1
1
|
import { ActionsProps } from './types';
|
|
2
|
+
type __VLS_Props = ActionsProps;
|
|
2
3
|
/**
|
|
3
4
|
* The row is measured against the space its container gives it. When it collapses
|
|
4
5
|
* the row is not unmounted, only taken out of the flow — it keeps its natural width,
|
|
5
6
|
* which is the only way to know when there is room for it again.
|
|
6
7
|
*/
|
|
7
8
|
declare function measure(): void;
|
|
9
|
+
type __VLS_PublicProps = {
|
|
10
|
+
'menuOpen'?: boolean;
|
|
11
|
+
} & __VLS_Props;
|
|
8
12
|
declare function __VLS_template(): {
|
|
9
13
|
attrs: Partial<{}>;
|
|
10
14
|
slots: {
|
|
@@ -20,13 +24,15 @@ declare function __VLS_template(): {
|
|
|
20
24
|
rootEl: HTMLDivElement;
|
|
21
25
|
};
|
|
22
26
|
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
23
|
-
declare const __VLS_component: import('vue').DefineComponent<
|
|
27
|
+
declare const __VLS_component: import('vue').DefineComponent<__VLS_PublicProps, {
|
|
24
28
|
collapsed: import('vue').Ref<boolean, boolean>;
|
|
25
29
|
measure: typeof measure;
|
|
26
30
|
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
27
31
|
collapse: (collapsed: boolean) => any;
|
|
28
|
-
|
|
32
|
+
"update:menuOpen": (value: boolean) => any;
|
|
33
|
+
}, string, import('vue').PublicProps, Readonly<__VLS_PublicProps> & Readonly<{
|
|
29
34
|
onCollapse?: ((collapsed: boolean) => any) | undefined;
|
|
35
|
+
"onUpdate:menuOpen"?: ((value: boolean) => any) | undefined;
|
|
30
36
|
}>, {
|
|
31
37
|
size: import('..').ActionSize;
|
|
32
38
|
align: import('./types').ActionsAlign;
|
|
@@ -0,0 +1,322 @@
|
|
|
1
|
+
import { nextTick } from 'vue';
|
|
2
|
+
import { FileCardProps } from './types';
|
|
3
|
+
declare function __VLS_template(): {
|
|
4
|
+
attrs: Partial<{}>;
|
|
5
|
+
slots: Readonly<{
|
|
6
|
+
/** The whole preview box — a video still, a player, whatever the file really needs. */
|
|
7
|
+
preview?: (props: {
|
|
8
|
+
picture: boolean;
|
|
9
|
+
}) => unknown;
|
|
10
|
+
/** Actions of your own, after the ones the card offers. */
|
|
11
|
+
actions?: () => unknown;
|
|
12
|
+
/** Under the name: a size, a date, dimensions. */
|
|
13
|
+
meta?: () => unknown;
|
|
14
|
+
}> & {
|
|
15
|
+
/** The whole preview box — a video still, a player, whatever the file really needs. */
|
|
16
|
+
preview?: (props: {
|
|
17
|
+
picture: boolean;
|
|
18
|
+
}) => unknown;
|
|
19
|
+
/** Actions of your own, after the ones the card offers. */
|
|
20
|
+
actions?: () => unknown;
|
|
21
|
+
/** Under the name: a size, a date, dimensions. */
|
|
22
|
+
meta?: () => unknown;
|
|
23
|
+
};
|
|
24
|
+
refs: {
|
|
25
|
+
field: ({
|
|
26
|
+
$: import('vue').ComponentInternalInstance;
|
|
27
|
+
$data: {};
|
|
28
|
+
$props: {
|
|
29
|
+
readonly modelValue?: import('..').InputModelValue;
|
|
30
|
+
readonly id?: string | undefined;
|
|
31
|
+
readonly type?: import('..').InputNativeType | undefined;
|
|
32
|
+
readonly size?: import('..').InputSize | undefined;
|
|
33
|
+
readonly status?: import('..').InputStatus | undefined;
|
|
34
|
+
readonly placeholder?: string | undefined;
|
|
35
|
+
readonly disabled?: boolean | undefined;
|
|
36
|
+
readonly readonly?: boolean | undefined;
|
|
37
|
+
readonly clearable?: boolean | undefined;
|
|
38
|
+
readonly maxlength?: number | undefined;
|
|
39
|
+
readonly showCount?: boolean | undefined;
|
|
40
|
+
readonly autocomplete?: string | undefined;
|
|
41
|
+
readonly ariaLabel?: string | undefined;
|
|
42
|
+
readonly onChange?: ((value: string) => any) | undefined;
|
|
43
|
+
readonly "onUpdate:modelValue"?: ((value: import('..').InputModelValue) => any) | undefined;
|
|
44
|
+
readonly onInput?: ((value: string) => any) | undefined;
|
|
45
|
+
readonly onClear?: (() => any) | undefined;
|
|
46
|
+
readonly onBlur?: ((event: FocusEvent) => any) | undefined;
|
|
47
|
+
readonly onFocus?: ((event: FocusEvent) => any) | undefined;
|
|
48
|
+
} & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps;
|
|
49
|
+
$attrs: import('vue').Attrs;
|
|
50
|
+
$refs: {
|
|
51
|
+
[x: string]: unknown;
|
|
52
|
+
} & {
|
|
53
|
+
inputRef: HTMLInputElement;
|
|
54
|
+
};
|
|
55
|
+
$slots: Readonly<{
|
|
56
|
+
[name: string]: import('vue').Slot<any> | undefined;
|
|
57
|
+
}>;
|
|
58
|
+
$root: import('vue').ComponentPublicInstance | null;
|
|
59
|
+
$parent: import('vue').ComponentPublicInstance | null;
|
|
60
|
+
$host: Element | null;
|
|
61
|
+
$emit: ((event: "change", value: string) => void) & ((event: "update:modelValue", value: import('..').InputModelValue) => void) & ((event: "input", value: string) => void) & ((event: "clear") => void) & ((event: "blur", event: FocusEvent) => void) & ((event: "focus", event: FocusEvent) => void);
|
|
62
|
+
$el: any;
|
|
63
|
+
$options: import('vue').ComponentOptionsBase<Readonly<{
|
|
64
|
+
modelValue?: import('..').InputModelValue;
|
|
65
|
+
} & import('..').InputProps> & Readonly<{
|
|
66
|
+
onChange?: ((value: string) => any) | undefined;
|
|
67
|
+
"onUpdate:modelValue"?: ((value: import('..').InputModelValue) => any) | undefined;
|
|
68
|
+
onInput?: ((value: string) => any) | undefined;
|
|
69
|
+
onClear?: (() => any) | undefined;
|
|
70
|
+
onBlur?: ((event: FocusEvent) => any) | undefined;
|
|
71
|
+
onFocus?: ((event: FocusEvent) => any) | undefined;
|
|
72
|
+
}>, {
|
|
73
|
+
focus: () => void | undefined;
|
|
74
|
+
blur: () => void | undefined;
|
|
75
|
+
select: () => void | undefined;
|
|
76
|
+
input: import('vue').Ref<HTMLInputElement | null, HTMLInputElement | null>;
|
|
77
|
+
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
78
|
+
change: (value: string) => any;
|
|
79
|
+
"update:modelValue": (value: import('..').InputModelValue) => any;
|
|
80
|
+
input: (value: string) => any;
|
|
81
|
+
clear: () => any;
|
|
82
|
+
blur: (event: FocusEvent) => any;
|
|
83
|
+
focus: (event: FocusEvent) => any;
|
|
84
|
+
}, string, {
|
|
85
|
+
size: import('..').InputSize;
|
|
86
|
+
disabled: boolean;
|
|
87
|
+
type: import('..').InputNativeType;
|
|
88
|
+
placeholder: string;
|
|
89
|
+
ariaLabel: string;
|
|
90
|
+
clearable: boolean;
|
|
91
|
+
status: import('..').InputStatus;
|
|
92
|
+
id: string;
|
|
93
|
+
readonly: boolean;
|
|
94
|
+
autocomplete: string;
|
|
95
|
+
maxlength: number;
|
|
96
|
+
showCount: boolean;
|
|
97
|
+
}, {}, string, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, import('vue').ComponentProvideOptions> & {
|
|
98
|
+
beforeCreate?: (() => void) | (() => void)[];
|
|
99
|
+
created?: (() => void) | (() => void)[];
|
|
100
|
+
beforeMount?: (() => void) | (() => void)[];
|
|
101
|
+
mounted?: (() => void) | (() => void)[];
|
|
102
|
+
beforeUpdate?: (() => void) | (() => void)[];
|
|
103
|
+
updated?: (() => void) | (() => void)[];
|
|
104
|
+
activated?: (() => void) | (() => void)[];
|
|
105
|
+
deactivated?: (() => void) | (() => void)[];
|
|
106
|
+
beforeDestroy?: (() => void) | (() => void)[];
|
|
107
|
+
beforeUnmount?: (() => void) | (() => void)[];
|
|
108
|
+
destroyed?: (() => void) | (() => void)[];
|
|
109
|
+
unmounted?: (() => void) | (() => void)[];
|
|
110
|
+
renderTracked?: ((e: import('vue').DebuggerEvent) => void) | ((e: import('vue').DebuggerEvent) => void)[];
|
|
111
|
+
renderTriggered?: ((e: import('vue').DebuggerEvent) => void) | ((e: import('vue').DebuggerEvent) => void)[];
|
|
112
|
+
errorCaptured?: ((err: unknown, instance: import('vue').ComponentPublicInstance | null, info: string) => boolean | void) | ((err: unknown, instance: import('vue').ComponentPublicInstance | null, info: string) => boolean | void)[];
|
|
113
|
+
};
|
|
114
|
+
$forceUpdate: () => void;
|
|
115
|
+
$nextTick: typeof nextTick;
|
|
116
|
+
$watch<T extends string | ((...args: any) => any)>(source: T, cb: T extends (...args: any) => infer R ? (...args: [R, R, import('@vue/reactivity').OnCleanup]) => any : (...args: [any, any, import('@vue/reactivity').OnCleanup]) => any, options?: import('vue').WatchOptions): import('vue').WatchStopHandle;
|
|
117
|
+
} & Readonly<{
|
|
118
|
+
size: import('..').InputSize;
|
|
119
|
+
disabled: boolean;
|
|
120
|
+
type: import('..').InputNativeType;
|
|
121
|
+
placeholder: string;
|
|
122
|
+
ariaLabel: string;
|
|
123
|
+
clearable: boolean;
|
|
124
|
+
status: import('..').InputStatus;
|
|
125
|
+
id: string;
|
|
126
|
+
readonly: boolean;
|
|
127
|
+
autocomplete: string;
|
|
128
|
+
maxlength: number;
|
|
129
|
+
showCount: boolean;
|
|
130
|
+
}> & Omit<Readonly<{
|
|
131
|
+
modelValue?: import('..').InputModelValue;
|
|
132
|
+
} & import('..').InputProps> & Readonly<{
|
|
133
|
+
onChange?: ((value: string) => any) | undefined;
|
|
134
|
+
"onUpdate:modelValue"?: ((value: import('..').InputModelValue) => any) | undefined;
|
|
135
|
+
onInput?: ((value: string) => any) | undefined;
|
|
136
|
+
onClear?: (() => any) | undefined;
|
|
137
|
+
onBlur?: ((event: FocusEvent) => any) | undefined;
|
|
138
|
+
onFocus?: ((event: FocusEvent) => any) | undefined;
|
|
139
|
+
}>, "input" | "select" | "blur" | "focus" | ("size" | "disabled" | "type" | "placeholder" | "ariaLabel" | "clearable" | "status" | "id" | "readonly" | "autocomplete" | "maxlength" | "showCount")> & {
|
|
140
|
+
focus: () => void | undefined;
|
|
141
|
+
blur: () => void | undefined;
|
|
142
|
+
select: () => void | undefined;
|
|
143
|
+
input: HTMLInputElement | null;
|
|
144
|
+
} & {} & import('vue').ComponentCustomProperties & {} & {
|
|
145
|
+
$slots: {
|
|
146
|
+
prefix?(_: {}): any;
|
|
147
|
+
suffix?(_: {}): any;
|
|
148
|
+
};
|
|
149
|
+
}) | null;
|
|
150
|
+
label: HTMLSpanElement;
|
|
151
|
+
};
|
|
152
|
+
rootEl: HTMLDivElement;
|
|
153
|
+
};
|
|
154
|
+
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
155
|
+
declare const __VLS_component: import('vue').DefineComponent<FileCardProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
156
|
+
edit: () => any;
|
|
157
|
+
copy: (url: string) => any;
|
|
158
|
+
remove: () => any;
|
|
159
|
+
rename: (name: string) => any;
|
|
160
|
+
"copy-error": (error: unknown) => any;
|
|
161
|
+
}, string, import('vue').PublicProps, Readonly<FileCardProps> & Readonly<{
|
|
162
|
+
onEdit?: (() => any) | undefined;
|
|
163
|
+
onCopy?: ((url: string) => any) | undefined;
|
|
164
|
+
onRemove?: (() => any) | undefined;
|
|
165
|
+
onRename?: ((name: string) => any) | undefined;
|
|
166
|
+
"onCopy-error"?: ((error: unknown) => any) | undefined;
|
|
167
|
+
}>, {
|
|
168
|
+
size: import('./types').FileCardSize;
|
|
169
|
+
disabled: boolean;
|
|
170
|
+
type: string;
|
|
171
|
+
icon: import('..').IconName;
|
|
172
|
+
url: string;
|
|
173
|
+
selected: boolean;
|
|
174
|
+
thumbnail: string;
|
|
175
|
+
renamable: boolean;
|
|
176
|
+
editable: boolean;
|
|
177
|
+
removable: boolean;
|
|
178
|
+
confirmRemove: boolean;
|
|
179
|
+
copyable: boolean;
|
|
180
|
+
renameLabel: string;
|
|
181
|
+
saveLabel: string;
|
|
182
|
+
cancelLabel: string;
|
|
183
|
+
editLabel: string;
|
|
184
|
+
removeLabel: string;
|
|
185
|
+
removeConfirmText: string;
|
|
186
|
+
copyLabel: string;
|
|
187
|
+
copiedLabel: string;
|
|
188
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {
|
|
189
|
+
field: ({
|
|
190
|
+
$: import('vue').ComponentInternalInstance;
|
|
191
|
+
$data: {};
|
|
192
|
+
$props: {
|
|
193
|
+
readonly modelValue?: import('..').InputModelValue;
|
|
194
|
+
readonly id?: string | undefined;
|
|
195
|
+
readonly type?: import('..').InputNativeType | undefined;
|
|
196
|
+
readonly size?: import('..').InputSize | undefined;
|
|
197
|
+
readonly status?: import('..').InputStatus | undefined;
|
|
198
|
+
readonly placeholder?: string | undefined;
|
|
199
|
+
readonly disabled?: boolean | undefined;
|
|
200
|
+
readonly readonly?: boolean | undefined;
|
|
201
|
+
readonly clearable?: boolean | undefined;
|
|
202
|
+
readonly maxlength?: number | undefined;
|
|
203
|
+
readonly showCount?: boolean | undefined;
|
|
204
|
+
readonly autocomplete?: string | undefined;
|
|
205
|
+
readonly ariaLabel?: string | undefined;
|
|
206
|
+
readonly onChange?: ((value: string) => any) | undefined;
|
|
207
|
+
readonly "onUpdate:modelValue"?: ((value: import('..').InputModelValue) => any) | undefined;
|
|
208
|
+
readonly onInput?: ((value: string) => any) | undefined;
|
|
209
|
+
readonly onClear?: (() => any) | undefined;
|
|
210
|
+
readonly onBlur?: ((event: FocusEvent) => any) | undefined;
|
|
211
|
+
readonly onFocus?: ((event: FocusEvent) => any) | undefined;
|
|
212
|
+
} & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps;
|
|
213
|
+
$attrs: import('vue').Attrs;
|
|
214
|
+
$refs: {
|
|
215
|
+
[x: string]: unknown;
|
|
216
|
+
} & {
|
|
217
|
+
inputRef: HTMLInputElement;
|
|
218
|
+
};
|
|
219
|
+
$slots: Readonly<{
|
|
220
|
+
[name: string]: import('vue').Slot<any> | undefined;
|
|
221
|
+
}>;
|
|
222
|
+
$root: import('vue').ComponentPublicInstance | null;
|
|
223
|
+
$parent: import('vue').ComponentPublicInstance | null;
|
|
224
|
+
$host: Element | null;
|
|
225
|
+
$emit: ((event: "change", value: string) => void) & ((event: "update:modelValue", value: import('..').InputModelValue) => void) & ((event: "input", value: string) => void) & ((event: "clear") => void) & ((event: "blur", event: FocusEvent) => void) & ((event: "focus", event: FocusEvent) => void);
|
|
226
|
+
$el: any;
|
|
227
|
+
$options: import('vue').ComponentOptionsBase<Readonly<{
|
|
228
|
+
modelValue?: import('..').InputModelValue;
|
|
229
|
+
} & import('..').InputProps> & Readonly<{
|
|
230
|
+
onChange?: ((value: string) => any) | undefined;
|
|
231
|
+
"onUpdate:modelValue"?: ((value: import('..').InputModelValue) => any) | undefined;
|
|
232
|
+
onInput?: ((value: string) => any) | undefined;
|
|
233
|
+
onClear?: (() => any) | undefined;
|
|
234
|
+
onBlur?: ((event: FocusEvent) => any) | undefined;
|
|
235
|
+
onFocus?: ((event: FocusEvent) => any) | undefined;
|
|
236
|
+
}>, {
|
|
237
|
+
focus: () => void | undefined;
|
|
238
|
+
blur: () => void | undefined;
|
|
239
|
+
select: () => void | undefined;
|
|
240
|
+
input: import('vue').Ref<HTMLInputElement | null, HTMLInputElement | null>;
|
|
241
|
+
}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
242
|
+
change: (value: string) => any;
|
|
243
|
+
"update:modelValue": (value: import('..').InputModelValue) => any;
|
|
244
|
+
input: (value: string) => any;
|
|
245
|
+
clear: () => any;
|
|
246
|
+
blur: (event: FocusEvent) => any;
|
|
247
|
+
focus: (event: FocusEvent) => any;
|
|
248
|
+
}, string, {
|
|
249
|
+
size: import('..').InputSize;
|
|
250
|
+
disabled: boolean;
|
|
251
|
+
type: import('..').InputNativeType;
|
|
252
|
+
placeholder: string;
|
|
253
|
+
ariaLabel: string;
|
|
254
|
+
clearable: boolean;
|
|
255
|
+
status: import('..').InputStatus;
|
|
256
|
+
id: string;
|
|
257
|
+
readonly: boolean;
|
|
258
|
+
autocomplete: string;
|
|
259
|
+
maxlength: number;
|
|
260
|
+
showCount: boolean;
|
|
261
|
+
}, {}, string, {}, import('vue').GlobalComponents, import('vue').GlobalDirectives, string, import('vue').ComponentProvideOptions> & {
|
|
262
|
+
beforeCreate?: (() => void) | (() => void)[];
|
|
263
|
+
created?: (() => void) | (() => void)[];
|
|
264
|
+
beforeMount?: (() => void) | (() => void)[];
|
|
265
|
+
mounted?: (() => void) | (() => void)[];
|
|
266
|
+
beforeUpdate?: (() => void) | (() => void)[];
|
|
267
|
+
updated?: (() => void) | (() => void)[];
|
|
268
|
+
activated?: (() => void) | (() => void)[];
|
|
269
|
+
deactivated?: (() => void) | (() => void)[];
|
|
270
|
+
beforeDestroy?: (() => void) | (() => void)[];
|
|
271
|
+
beforeUnmount?: (() => void) | (() => void)[];
|
|
272
|
+
destroyed?: (() => void) | (() => void)[];
|
|
273
|
+
unmounted?: (() => void) | (() => void)[];
|
|
274
|
+
renderTracked?: ((e: import('vue').DebuggerEvent) => void) | ((e: import('vue').DebuggerEvent) => void)[];
|
|
275
|
+
renderTriggered?: ((e: import('vue').DebuggerEvent) => void) | ((e: import('vue').DebuggerEvent) => void)[];
|
|
276
|
+
errorCaptured?: ((err: unknown, instance: import('vue').ComponentPublicInstance | null, info: string) => boolean | void) | ((err: unknown, instance: import('vue').ComponentPublicInstance | null, info: string) => boolean | void)[];
|
|
277
|
+
};
|
|
278
|
+
$forceUpdate: () => void;
|
|
279
|
+
$nextTick: typeof nextTick;
|
|
280
|
+
$watch<T extends string | ((...args: any) => any)>(source: T, cb: T extends (...args: any) => infer R ? (...args: [R, R, import('@vue/reactivity').OnCleanup]) => any : (...args: [any, any, import('@vue/reactivity').OnCleanup]) => any, options?: import('vue').WatchOptions): import('vue').WatchStopHandle;
|
|
281
|
+
} & Readonly<{
|
|
282
|
+
size: import('..').InputSize;
|
|
283
|
+
disabled: boolean;
|
|
284
|
+
type: import('..').InputNativeType;
|
|
285
|
+
placeholder: string;
|
|
286
|
+
ariaLabel: string;
|
|
287
|
+
clearable: boolean;
|
|
288
|
+
status: import('..').InputStatus;
|
|
289
|
+
id: string;
|
|
290
|
+
readonly: boolean;
|
|
291
|
+
autocomplete: string;
|
|
292
|
+
maxlength: number;
|
|
293
|
+
showCount: boolean;
|
|
294
|
+
}> & Omit<Readonly<{
|
|
295
|
+
modelValue?: import('..').InputModelValue;
|
|
296
|
+
} & import('..').InputProps> & Readonly<{
|
|
297
|
+
onChange?: ((value: string) => any) | undefined;
|
|
298
|
+
"onUpdate:modelValue"?: ((value: import('..').InputModelValue) => any) | undefined;
|
|
299
|
+
onInput?: ((value: string) => any) | undefined;
|
|
300
|
+
onClear?: (() => any) | undefined;
|
|
301
|
+
onBlur?: ((event: FocusEvent) => any) | undefined;
|
|
302
|
+
onFocus?: ((event: FocusEvent) => any) | undefined;
|
|
303
|
+
}>, "input" | "select" | "blur" | "focus" | ("size" | "disabled" | "type" | "placeholder" | "ariaLabel" | "clearable" | "status" | "id" | "readonly" | "autocomplete" | "maxlength" | "showCount")> & {
|
|
304
|
+
focus: () => void | undefined;
|
|
305
|
+
blur: () => void | undefined;
|
|
306
|
+
select: () => void | undefined;
|
|
307
|
+
input: HTMLInputElement | null;
|
|
308
|
+
} & {} & import('vue').ComponentCustomProperties & {} & {
|
|
309
|
+
$slots: {
|
|
310
|
+
prefix?(_: {}): any;
|
|
311
|
+
suffix?(_: {}): any;
|
|
312
|
+
};
|
|
313
|
+
}) | null;
|
|
314
|
+
label: HTMLSpanElement;
|
|
315
|
+
}, HTMLDivElement>;
|
|
316
|
+
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
317
|
+
export default _default;
|
|
318
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
319
|
+
new (): {
|
|
320
|
+
$slots: S;
|
|
321
|
+
};
|
|
322
|
+
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { IconName } from '../Icon/types';
|
|
2
|
+
/**
|
|
3
|
+
* The extension of a file name, lower case and without the dot. A URL is accepted too:
|
|
4
|
+
* the query and the fragment are cut off first, because `photo.jpg?v=2` is a JPEG.
|
|
5
|
+
*/
|
|
6
|
+
export declare function extensionOf(name: string): string;
|
|
7
|
+
/**
|
|
8
|
+
* Whether the file is a picture, and so has a preview rather than a glyph.
|
|
9
|
+
*
|
|
10
|
+
* The MIME type is asked first because it is the one that knows: an extension is a
|
|
11
|
+
* guess a file name makes about itself. `image/*` minus the formats no browser draws —
|
|
12
|
+
* a TIFF is an image and still renders as a broken picture.
|
|
13
|
+
*/
|
|
14
|
+
export declare function isPicture(name: string, type?: string): boolean;
|
|
15
|
+
/**
|
|
16
|
+
* The icon for a file, by extension.
|
|
17
|
+
*
|
|
18
|
+
* The registry is what answers, not a list kept here, so `registerIcons({ 'file-dwg': … })`
|
|
19
|
+
* in an application is all it takes for a `.dwg` to have its own drawing — no release of
|
|
20
|
+
* this library, and nothing to pass per card.
|
|
21
|
+
*/
|
|
22
|
+
export declare function fileIconName(name: string): IconName;
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import { IconName } from '../Icon/types';
|
|
2
|
+
export type FileCardSize = 'sm' | 'md' | 'lg';
|
|
3
|
+
export interface FileCardProps {
|
|
4
|
+
/** The file name, extension and all. It is what the card shows and what it renames. */
|
|
5
|
+
name: string;
|
|
6
|
+
/**
|
|
7
|
+
* Where the file is. The copy action puts this on the clipboard, and a picture with
|
|
8
|
+
* no `thumbnail` of its own is drawn from it.
|
|
9
|
+
*/
|
|
10
|
+
url?: string;
|
|
11
|
+
/** A smaller picture to draw instead of `url` — the one the backend already made. */
|
|
12
|
+
thumbnail?: string;
|
|
13
|
+
/**
|
|
14
|
+
* MIME type. It decides picture or glyph; without it the extension decides, which is
|
|
15
|
+
* right often enough and wrong for a `.bin` that happens to be a JPEG.
|
|
16
|
+
*/
|
|
17
|
+
type?: string;
|
|
18
|
+
/** Icon to draw instead of the one the extension picks. */
|
|
19
|
+
icon?: IconName;
|
|
20
|
+
/** Draws the card as chosen. The choosing itself belongs to whatever holds the cards. */
|
|
21
|
+
selected?: boolean;
|
|
22
|
+
size?: FileCardSize;
|
|
23
|
+
/** Nothing can be done to the file: every action goes, and the name cannot be edited. */
|
|
24
|
+
disabled?: boolean;
|
|
25
|
+
/** Offers renaming. The card edits the name in place and reports the new one. */
|
|
26
|
+
renamable?: boolean;
|
|
27
|
+
/**
|
|
28
|
+
* Offers the edit action, which says "open this picture in an editor" and nothing
|
|
29
|
+
* more — the editing itself is somebody else's component. Pictures only: there is
|
|
30
|
+
* nothing to open for a `.zip`.
|
|
31
|
+
*/
|
|
32
|
+
editable?: boolean;
|
|
33
|
+
removable?: boolean;
|
|
34
|
+
/**
|
|
35
|
+
* Asks before deleting. On, because a file deleted from a grid of thumbnails is a file
|
|
36
|
+
* deleted by a misplaced click. Off where the screen asks its own question, or where
|
|
37
|
+
* the deletion is undoable.
|
|
38
|
+
*/
|
|
39
|
+
confirmRemove?: boolean;
|
|
40
|
+
/** Offers copying `url` to the clipboard. */
|
|
41
|
+
copyable?: boolean;
|
|
42
|
+
renameLabel?: string;
|
|
43
|
+
/** The two buttons under the field renaming opens. */
|
|
44
|
+
saveLabel?: string;
|
|
45
|
+
cancelLabel?: string;
|
|
46
|
+
editLabel?: string;
|
|
47
|
+
removeLabel?: string;
|
|
48
|
+
/** The question `confirmRemove` asks. The file name is worth putting in it. */
|
|
49
|
+
removeConfirmText?: string;
|
|
50
|
+
copyLabel?: string;
|
|
51
|
+
/** Shown on the copy action for a moment after it worked. */
|
|
52
|
+
copiedLabel?: string;
|
|
53
|
+
}
|
|
54
|
+
export interface FileCardEmits {
|
|
55
|
+
/** A new name was committed. The file is not renamed until the caller says so. */
|
|
56
|
+
rename: [name: string];
|
|
57
|
+
/** Open this picture in an editor. */
|
|
58
|
+
edit: [];
|
|
59
|
+
remove: [];
|
|
60
|
+
/** The URL reached the clipboard. */
|
|
61
|
+
copy: [url: string];
|
|
62
|
+
/** It did not — no clipboard, or permission refused. */
|
|
63
|
+
'copy-error': [error: unknown];
|
|
64
|
+
}
|
|
@@ -18,6 +18,7 @@ export declare const builtinIcons: {
|
|
|
18
18
|
readonly copy: "<rect x=\"8.5\" y=\"8.5\" width=\"11\" height=\"11\" rx=\"2.2\"/><path d=\"M15.5 8.5v-2a2 2 0 0 0-2-2h-7a2 2 0 0 0-2 2v7a2 2 0 0 0 2 2h2\"/>";
|
|
19
19
|
readonly search: "<circle cx=\"11\" cy=\"11\" r=\"6.5\"/><path d=\"m16 16 4.5 4.5\"/>";
|
|
20
20
|
readonly filter: "<path d=\"M4 5.5h16l-6.2 7.2v5.1l-3.6 2v-7.1z\"/>";
|
|
21
|
+
readonly crop: "<path d=\"M6.5 2.5v13a2 2 0 0 0 2 2h13\"/><path d=\"M2.5 6.5h13a2 2 0 0 1 2 2v13\"/>";
|
|
21
22
|
readonly refresh: "<path d=\"M4 12a8 8 0 0 1 13.7-5.6L20 8.5\"/><path d=\"M20 4.5v4h-4\"/><path d=\"M20 12a8 8 0 0 1-13.7 5.6L4 15.5\"/><path d=\"M4 19.5v-4h4\"/>";
|
|
22
23
|
readonly upload: "<path d=\"M12 16V4m0 0-4.5 4.5M12 4l4.5 4.5\"/><path d=\"M4 15v3.5A1.5 1.5 0 0 0 5.5 20h13a1.5 1.5 0 0 0 1.5-1.5V15\"/>";
|
|
23
24
|
readonly download: "<path d=\"M12 4v12m0 0-4.5-4.5M12 16l4.5-4.5\"/><path d=\"M4 15v3.5A1.5 1.5 0 0 0 5.5 20h13a1.5 1.5 0 0 0 1.5-1.5V15\"/>";
|
|
@@ -66,6 +67,81 @@ export declare const builtinIcons: {
|
|
|
66
67
|
readonly warning: "<path d=\"M10.3 4.9a2 2 0 0 1 3.4 0l7 12.1a2 2 0 0 1-1.7 3H5a2 2 0 0 1-1.7-3z\"/><path d=\"M12 9.5v4\"/><circle cx=\"12\" cy=\"16.6\" r=\"1.05\" fill=\"currentColor\" stroke=\"none\"/>";
|
|
67
68
|
readonly question: "<circle cx=\"12\" cy=\"12\" r=\"8.5\"/><path d=\"M9.6 9.4a2.5 2.5 0 0 1 4.9.6c0 1.7-2.5 2-2.5 3.5\"/><circle cx=\"12\" cy=\"16.6\" r=\"1.05\" fill=\"currentColor\" stroke=\"none\"/>";
|
|
68
69
|
readonly loader: "<path d=\"M12 3.5v4M12 16.5v4M3.5 12h4M16.5 12h4M6 6l2.8 2.8M15.2 15.2 18 18M18 6l-2.8 2.8M8.8 15.2 6 18\"/>";
|
|
70
|
+
readonly 'file-generic': "<path d=\"M13.5 3.5H7a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2V9zm0 0V9H19\"/>";
|
|
71
|
+
readonly 'file-txt': string;
|
|
72
|
+
readonly 'file-md': string;
|
|
73
|
+
readonly 'file-rtf': string;
|
|
74
|
+
readonly 'file-doc': string;
|
|
75
|
+
readonly 'file-docx': string;
|
|
76
|
+
readonly 'file-odt': string;
|
|
77
|
+
readonly 'file-pages': string;
|
|
78
|
+
readonly 'file-csv': string;
|
|
79
|
+
readonly 'file-xls': string;
|
|
80
|
+
readonly 'file-xlsx': string;
|
|
81
|
+
readonly 'file-ods': string;
|
|
82
|
+
readonly 'file-numbers': string;
|
|
83
|
+
readonly 'file-ppt': string;
|
|
84
|
+
readonly 'file-pptx': string;
|
|
85
|
+
readonly 'file-odp': string;
|
|
86
|
+
readonly 'file-key': string;
|
|
87
|
+
readonly 'file-pdf': string;
|
|
88
|
+
readonly 'file-zip': string;
|
|
89
|
+
readonly 'file-rar': string;
|
|
90
|
+
readonly 'file-7z': string;
|
|
91
|
+
readonly 'file-tar': string;
|
|
92
|
+
readonly 'file-gz': string;
|
|
93
|
+
readonly 'file-bz2': string;
|
|
94
|
+
readonly 'file-mp3': string;
|
|
95
|
+
readonly 'file-wav': string;
|
|
96
|
+
readonly 'file-ogg': string;
|
|
97
|
+
readonly 'file-flac': string;
|
|
98
|
+
readonly 'file-aac': string;
|
|
99
|
+
readonly 'file-m4a': string;
|
|
100
|
+
readonly 'file-mp4': string;
|
|
101
|
+
readonly 'file-mov': string;
|
|
102
|
+
readonly 'file-avi': string;
|
|
103
|
+
readonly 'file-webm': string;
|
|
104
|
+
readonly 'file-mkv': string;
|
|
105
|
+
readonly 'file-m4v': string;
|
|
106
|
+
readonly 'file-jpg': string;
|
|
107
|
+
readonly 'file-jpeg': string;
|
|
108
|
+
readonly 'file-png': string;
|
|
109
|
+
readonly 'file-gif': string;
|
|
110
|
+
readonly 'file-webp': string;
|
|
111
|
+
readonly 'file-avif': string;
|
|
112
|
+
readonly 'file-bmp': string;
|
|
113
|
+
readonly 'file-tiff': string;
|
|
114
|
+
readonly 'file-ico': string;
|
|
115
|
+
readonly 'file-svg': string;
|
|
116
|
+
readonly 'file-ai': string;
|
|
117
|
+
readonly 'file-eps': string;
|
|
118
|
+
readonly 'file-psd': string;
|
|
119
|
+
readonly 'file-xcf': string;
|
|
120
|
+
readonly 'file-fig': string;
|
|
121
|
+
readonly 'file-sketch': string;
|
|
122
|
+
readonly 'file-js': string;
|
|
123
|
+
readonly 'file-ts': string;
|
|
124
|
+
readonly 'file-jsx': string;
|
|
125
|
+
readonly 'file-tsx': string;
|
|
126
|
+
readonly 'file-vue': string;
|
|
127
|
+
readonly 'file-json': string;
|
|
128
|
+
readonly 'file-xml': string;
|
|
129
|
+
readonly 'file-yml': string;
|
|
130
|
+
readonly 'file-yaml': string;
|
|
131
|
+
readonly 'file-html': string;
|
|
132
|
+
readonly 'file-css': string;
|
|
133
|
+
readonly 'file-scss': string;
|
|
134
|
+
readonly 'file-php': string;
|
|
135
|
+
readonly 'file-py': string;
|
|
136
|
+
readonly 'file-rb': string;
|
|
137
|
+
readonly 'file-go': string;
|
|
138
|
+
readonly 'file-java': string;
|
|
139
|
+
readonly 'file-sh': string;
|
|
140
|
+
readonly 'file-sql': string;
|
|
141
|
+
readonly 'file-ttf': string;
|
|
142
|
+
readonly 'file-otf': string;
|
|
143
|
+
readonly 'file-woff': string;
|
|
144
|
+
readonly 'file-woff2': string;
|
|
69
145
|
};
|
|
70
146
|
/** Every name the library ships with. */
|
|
71
147
|
export type BuiltinIconName = keyof typeof builtinIcons;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { SelectionAreaProps, SelectionAreaSlotProps, SelectionValue } from './types';
|
|
2
2
|
type __VLS_Props = SelectionAreaProps;
|
|
3
|
+
/** Everything there is. Nothing at all where only one may be held. */
|
|
3
4
|
declare function selectAll(): void;
|
|
4
5
|
declare function clear(): void;
|
|
5
6
|
type __VLS_PublicProps = {
|
|
@@ -30,6 +31,7 @@ declare const __VLS_component: import('vue').DefineComponent<__VLS_PublicProps,
|
|
|
30
31
|
onEnd?: ((value: SelectionValue[]) => any) | undefined;
|
|
31
32
|
"onUpdate:modelValue"?: ((value: SelectionValue[]) => any) | undefined;
|
|
32
33
|
}>, {
|
|
34
|
+
multiple: boolean;
|
|
33
35
|
disabled: boolean;
|
|
34
36
|
match: import('./types').SelectionMatch;
|
|
35
37
|
threshold: number;
|
|
@@ -1,13 +1,22 @@
|
|
|
1
1
|
export type SelectionValue = string | number;
|
|
2
2
|
export type SelectionMatch = 'intersect' | 'contain';
|
|
3
3
|
export interface SelectionAreaProps {
|
|
4
|
+
/**
|
|
5
|
+
* Whether more than one item may be held at once. Off, the model never holds more than
|
|
6
|
+
* a single value: there is no box, no run and no toggle, and a click or a tap picks the
|
|
7
|
+
* item under it. A gallery wants several; a file picker wants one.
|
|
8
|
+
*/
|
|
9
|
+
multiple?: boolean;
|
|
4
10
|
/** Whether the box has to cover an item or merely touch it. */
|
|
5
11
|
match?: SelectionMatch;
|
|
6
12
|
/** How far the pointer travels before it is a drag rather than a click, in pixels. */
|
|
7
13
|
threshold?: number;
|
|
8
14
|
/** A click picks one item; a click on the background clears the selection. */
|
|
9
15
|
clickSelect?: boolean;
|
|
10
|
-
/**
|
|
16
|
+
/**
|
|
17
|
+
* Draw the box with a finger too, at the cost of the area scrolling with one. Off,
|
|
18
|
+
* because on a touch screen a drag means scroll — a tap still picks either way.
|
|
19
|
+
*/
|
|
11
20
|
touch?: boolean;
|
|
12
21
|
/** How near the scroller's edge the pointer scrolls it, in pixels. `0` never does. */
|
|
13
22
|
edgeScroll?: number;
|
|
@@ -6,7 +6,9 @@ declare function __VLS_template(): {
|
|
|
6
6
|
}> & {
|
|
7
7
|
default?: () => unknown;
|
|
8
8
|
};
|
|
9
|
-
refs: {
|
|
9
|
+
refs: {
|
|
10
|
+
list: HTMLOListElement;
|
|
11
|
+
};
|
|
10
12
|
rootEl: HTMLOListElement;
|
|
11
13
|
};
|
|
12
14
|
type __VLS_TemplateResult = ReturnType<typeof __VLS_template>;
|
|
@@ -21,7 +23,10 @@ declare const __VLS_component: import('vue').DefineComponent<StepsProps, {}, {},
|
|
|
21
23
|
current: number;
|
|
22
24
|
direction: import('./types').StepsDirection;
|
|
23
25
|
clickable: boolean;
|
|
24
|
-
|
|
26
|
+
minStepWidth: number;
|
|
27
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {
|
|
28
|
+
list: HTMLOListElement;
|
|
29
|
+
}, HTMLOListElement>;
|
|
25
30
|
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
26
31
|
export default _default;
|
|
27
32
|
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
@@ -15,6 +15,11 @@ export interface StepsProps {
|
|
|
15
15
|
* offered: the steps ahead are the ones that have not been filled in.
|
|
16
16
|
*/
|
|
17
17
|
clickable?: boolean;
|
|
18
|
+
/**
|
|
19
|
+
* How narrow a step may get before a horizontal sequence turns down the page, in
|
|
20
|
+
* pixels. `0` never folds, and a sequence that is already vertical ignores it.
|
|
21
|
+
*/
|
|
22
|
+
minStepWidth?: number;
|
|
18
23
|
/** Accessible name of the sequence. */
|
|
19
24
|
ariaLabel?: string;
|
|
20
25
|
}
|
|
@@ -31,9 +31,9 @@ declare const __VLS_component: import('vue').DefineComponent<__VLS_PublicProps,
|
|
|
31
31
|
align: import('./types').TooltipAlign;
|
|
32
32
|
offset: number;
|
|
33
33
|
teleport: boolean;
|
|
34
|
+
arrow: boolean;
|
|
34
35
|
delay: number;
|
|
35
36
|
maxWidth: number | string;
|
|
36
|
-
arrow: boolean;
|
|
37
37
|
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
38
38
|
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
39
39
|
export default _default;
|
|
@@ -61,6 +61,12 @@ export interface TreeProps<T = TreeNode> {
|
|
|
61
61
|
allowDrag?: (node: T) => boolean;
|
|
62
62
|
/** Vetoes a landing spot — say, to keep a page out of the root. */
|
|
63
63
|
allowDrop?: (drag: T, drop: T, zone: TreeDropZone) => boolean;
|
|
64
|
+
/**
|
|
65
|
+
* How long a node dragged over a closed branch waits before that branch opens.
|
|
66
|
+
* Dropping into a branch you cannot see the inside of is a guess; this turns the
|
|
67
|
+
* guess into a look. Zero switches it off.
|
|
68
|
+
*/
|
|
69
|
+
springDelay?: number;
|
|
64
70
|
/** Children are fetched when a branch first opens. Requires `load`. */
|
|
65
71
|
lazy?: boolean;
|
|
66
72
|
/** Fetches the children of one node. */
|