@bridge-ui/vue 0.11.0 → 0.13.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.
Files changed (131) hide show
  1. package/ai/skills/bridge-ui-components/SKILL.md +2 -1
  2. package/dist/Adapters/Examples/date-moment.js +31 -31
  3. package/dist/Adapters/Examples/i18n-dictionary.js +14 -0
  4. package/dist/Adapters/Examples/icon-fontawesome.js +53 -40
  5. package/dist/Adapters/Examples/icon-heroicons.js +46 -33
  6. package/dist/Adapters/Examples/icon-lucide.js +47 -34
  7. package/dist/Adapters/Examples/icon-phosphor.js +48 -35
  8. package/dist/Adapters/Examples/icon-tabler.js +45 -32
  9. package/dist/Adapters/Examples/rich-text-tiptap.d.ts +5 -0
  10. package/dist/Adapters/Examples/rich-text-tiptap.js +138 -0
  11. package/dist/Adapters/RichText/index.d.ts +1 -0
  12. package/dist/Adapters/RichText/index.js +2 -0
  13. package/dist/Adapters/RichText/mockRichTextAdapter.d.ts +5 -0
  14. package/dist/Adapters/RichText/useRichTextAdapter.d.ts +12 -0
  15. package/dist/Adapters/RichText/useRichTextAdapter.js +13 -0
  16. package/dist/Adapters/index.d.ts +1 -0
  17. package/dist/Adapters/index.js +2 -1
  18. package/dist/Components/ActionFooter/composables/useActionFooter.d.ts +6 -6
  19. package/dist/Components/Autocomplete/composables/useAutocomplete.js +2 -2
  20. package/dist/Components/BaseField/composables/useBaseField.d.ts +3 -3
  21. package/dist/Components/BaseField/composables/useBaseField.js +7 -7
  22. package/dist/Components/Breadcrumb/Breadcrumb.vue.d.ts +17 -10
  23. package/dist/Components/Breadcrumb/Breadcrumb.vue_vue_type_script_setup_true_lang.js +7 -2
  24. package/dist/Components/Breadcrumb/breadcrumb.types.d.ts +22 -4
  25. package/dist/Components/Breadcrumb/breadcrumbInjectionKey.d.ts +5 -1
  26. package/dist/Components/Breadcrumb/composables/useBreadcrumb.d.ts +6 -5
  27. package/dist/Components/Breadcrumb/composables/useBreadcrumb.js +2 -0
  28. package/dist/Components/BreadcrumbItem/BreadcrumbItem.vue.d.ts +17 -11
  29. package/dist/Components/BreadcrumbItem/BreadcrumbItem.vue_vue_type_script_setup_true_lang.js +2 -0
  30. package/dist/Components/BreadcrumbItem/breadcrumbItem.types.d.ts +21 -3
  31. package/dist/Components/BreadcrumbItem/composables/useBreadcrumbItem.d.ts +10 -6
  32. package/dist/Components/BreadcrumbItem/composables/useBreadcrumbItem.js +65 -59
  33. package/dist/Components/Button/Button.vue.d.ts +17 -8
  34. package/dist/Components/Button/Button.vue_vue_type_script_setup_true_lang.js +10 -10
  35. package/dist/Components/Button/button.types.d.ts +22 -5
  36. package/dist/Components/Button/composables/useButton.d.ts +198 -8
  37. package/dist/Components/Button/composables/useButton.js +101 -86
  38. package/dist/Components/Calendar/Calendar.vue_vue_type_script_setup_true_lang.js +8 -8
  39. package/dist/Components/Carousel/Carousel.js +5 -0
  40. package/dist/Components/Carousel/Carousel.vue.d.ts +22 -0
  41. package/dist/Components/Carousel/Carousel.vue_vue_type_script_setup_true_lang.js +49 -0
  42. package/dist/Components/Carousel/carousel.types.d.ts +236 -0
  43. package/dist/Components/Carousel/carouselInjectionKey.d.ts +48 -0
  44. package/dist/Components/Carousel/carouselInjectionKey.js +4 -0
  45. package/dist/Components/Carousel/composables/useCarousel.d.ts +91 -0
  46. package/dist/Components/Carousel/composables/useCarousel.js +331 -0
  47. package/dist/Components/Carousel/index.d.ts +4 -0
  48. package/dist/Components/Carousel/index.js +4 -0
  49. package/dist/Components/CarouselSlide/CarouselSlide.js +5 -0
  50. package/dist/Components/CarouselSlide/CarouselSlide.vue.d.ts +11 -0
  51. package/dist/Components/CarouselSlide/CarouselSlide.vue_vue_type_script_setup_true_lang.js +17 -0
  52. package/dist/Components/CarouselSlide/carouselSlide.types.d.ts +40 -0
  53. package/dist/Components/CarouselSlide/composables/useCarouselSlide.d.ts +205 -0
  54. package/dist/Components/CarouselSlide/composables/useCarouselSlide.js +79 -0
  55. package/dist/Components/CarouselSlide/index.d.ts +3 -0
  56. package/dist/Components/CarouselSlide/index.js +3 -0
  57. package/dist/Components/ColorPicker/composables/useColorPicker.js +1 -1
  58. package/dist/Components/DataTable/DataTable.vue.d.ts +1 -1
  59. package/dist/Components/DataTable/composables/useDataTable.d.ts +1 -1
  60. package/dist/Components/DataTable/composables/useDataTable.js +288 -282
  61. package/dist/Components/Drawer/composables/useDrawer.d.ts +1 -1
  62. package/dist/Components/Drawer/composables/useDrawer.js +2 -2
  63. package/dist/Components/FileUpload/FileUpload.js +5 -0
  64. package/dist/Components/FileUpload/FileUpload.vue.d.ts +26 -0
  65. package/dist/Components/FileUpload/FileUpload.vue_vue_type_script_setup_true_lang.js +141 -0
  66. package/dist/Components/FileUpload/composables/useFileUpload.d.ts +120 -0
  67. package/dist/Components/FileUpload/composables/useFileUpload.js +235 -0
  68. package/dist/Components/FileUpload/fileUpload.types.d.ts +396 -0
  69. package/dist/Components/FileUpload/fileUploadInjectionKey.d.ts +61 -0
  70. package/dist/Components/FileUpload/fileUploadInjectionKey.js +4 -0
  71. package/dist/Components/FileUpload/index.d.ts +3 -0
  72. package/dist/Components/FileUpload/index.js +3 -0
  73. package/dist/Components/FileUploadItem/FileUploadItem.js +5 -0
  74. package/dist/Components/FileUploadItem/FileUploadItem.vue.d.ts +12 -0
  75. package/dist/Components/FileUploadItem/FileUploadItem.vue_vue_type_script_setup_true_lang.js +83 -0
  76. package/dist/Components/FileUploadItem/composables/useFileUploadItem.d.ts +1153 -0
  77. package/dist/Components/FileUploadItem/composables/useFileUploadItem.js +94 -0
  78. package/dist/Components/FileUploadItem/fileUploadItem.types.d.ts +20 -0
  79. package/dist/Components/FileUploadItem/index.d.ts +3 -0
  80. package/dist/Components/FileUploadItem/index.js +3 -0
  81. package/dist/Components/FormField/composables/useFormField.d.ts +1 -1
  82. package/dist/Components/Link/Link.vue.d.ts +17 -8
  83. package/dist/Components/Link/Link.vue_vue_type_script_setup_true_lang.js +30 -25
  84. package/dist/Components/Link/composables/useLink.d.ts +8 -6
  85. package/dist/Components/Link/composables/useLink.js +52 -45
  86. package/dist/Components/Link/link.types.d.ts +21 -4
  87. package/dist/Components/ListItem/ListItem.vue.d.ts +17 -15
  88. package/dist/Components/ListItem/ListItem.vue_vue_type_script_setup_true_lang.js +2 -0
  89. package/dist/Components/ListItem/composables/useListItem.d.ts +7 -6
  90. package/dist/Components/ListItem/composables/useListItem.js +108 -105
  91. package/dist/Components/ListItem/listItem.types.d.ts +19 -3
  92. package/dist/Components/Listbox/composables/useListbox.d.ts +2 -2
  93. package/dist/Components/Menu/composables/useMenu.js +6 -6
  94. package/dist/Components/Modal/composables/useModal.d.ts +1 -1
  95. package/dist/Components/Modal/composables/useModal.js +2 -2
  96. package/dist/Components/Pagination/composables/usePagination.d.ts +1 -1
  97. package/dist/Components/RichTextEditor/RichTextEditor.js +5 -0
  98. package/dist/Components/RichTextEditor/RichTextEditor.vue.d.ts +23 -0
  99. package/dist/Components/RichTextEditor/RichTextEditor.vue_vue_type_script_setup_true_lang.js +104 -0
  100. package/dist/Components/RichTextEditor/composables/useRichTextEditor.d.ts +488 -0
  101. package/dist/Components/RichTextEditor/composables/useRichTextEditor.js +226 -0
  102. package/dist/Components/RichTextEditor/index.d.ts +3 -0
  103. package/dist/Components/RichTextEditor/index.js +3 -0
  104. package/dist/Components/RichTextEditor/richTextEditor.types.d.ts +103 -0
  105. package/dist/Components/Select/composables/useSelect.js +2 -2
  106. package/dist/Components/Sidebar/SidebarListItem.vue.d.ts +17 -9
  107. package/dist/Components/Sidebar/SidebarListItem.vue_vue_type_script_setup_true_lang.js +2 -0
  108. package/dist/Components/Sidebar/composables/useSidebarListItem.js +1 -1
  109. package/dist/Components/Sidebar/composables/useSidebarTrigger.d.ts +1 -1
  110. package/dist/Components/Sidebar/sidebar.types.d.ts +2 -1
  111. package/dist/Components/Snackbar/composables/useSnackbar.js +1 -1
  112. package/dist/Components/Textarea/composables/useTextarea.js +1 -1
  113. package/dist/Components/Tooltip/composables/useTooltip.js +3 -3
  114. package/dist/Utils/linkAs.d.ts +29 -0
  115. package/dist/Utils/linkAs.js +18 -0
  116. package/dist/augments.d.ts +19 -0
  117. package/dist/index.d.ts +11 -0
  118. package/dist/index.js +181 -170
  119. package/dist/theme.css +3 -0
  120. package/docs/README.md +4 -0
  121. package/docs/components/Breadcrumb.md +16 -0
  122. package/docs/components/BridgeUIProvider.md +18 -1
  123. package/docs/components/Button.md +31 -19
  124. package/docs/components/Carousel.md +113 -0
  125. package/docs/components/DataTable.md +1 -1
  126. package/docs/components/FileUpload.md +197 -0
  127. package/docs/components/Link.md +28 -12
  128. package/docs/components/List.md +21 -19
  129. package/docs/components/RichTextEditor.md +88 -0
  130. package/docs/components/Sidebar.md +1 -1
  131. package/package.json +54 -18
@@ -0,0 +1,396 @@
1
+ import { HTMLAttributes, InputHTMLAttributes, Slot } from 'vue';
2
+ import { FileUploadModel, FileUploadValue } from '@bridge-ui/core/Domain';
3
+ import { FileUploadColor, FileUploadOrientation, FileUploadRounded, FileUploadSize, FileUploadVariant } from '@bridge-ui/core/Tokens';
4
+ import { MergeHtmlProps, MergeProps } from '@bridge-ui/core/Utils';
5
+ export interface FileUploadSizeOverrides {}
6
+ export interface FileUploadColorOverrides {}
7
+ export interface FileUploadRoundedOverrides {}
8
+ export interface FileUploadVariantOverrides {}
9
+ export interface FileUploadOrientationOverrides {}
10
+ export interface FileUploadClasses {
11
+ /**
12
+ * Classes for the actions cluster on a file card.
13
+ */
14
+ actions?: string;
15
+ /**
16
+ * Classes for the title + description stack on a file card.
17
+ */
18
+ content?: string;
19
+ /**
20
+ * Classes for helper text below the picker / list.
21
+ */
22
+ description?: string;
23
+ /**
24
+ * Classes for the dropzone surface.
25
+ */
26
+ dropzone?: string;
27
+ /**
28
+ * Classes for validation / error text.
29
+ */
30
+ errorMessage?: string;
31
+ /**
32
+ * Classes for each file card.
33
+ */
34
+ item?: string;
35
+ /**
36
+ * Classes for the optional field label.
37
+ */
38
+ label?: string;
39
+ /**
40
+ * Classes for the selected-files list.
41
+ */
42
+ list?: string;
43
+ /**
44
+ * Classes for the media slot (icon or image preview).
45
+ */
46
+ media?: string;
47
+ /**
48
+ * Classes for the root wrapper.
49
+ */
50
+ root?: string;
51
+ /**
52
+ * Classes for the file name on a card.
53
+ */
54
+ title?: string;
55
+ /**
56
+ * Classes for the button-variant trigger wrapper.
57
+ */
58
+ trigger?: string;
59
+ }
60
+ export interface FileUploadCustomProps {
61
+ /**
62
+ * Props forwarded to the actions cluster on a file card.
63
+ */
64
+ actions?: HTMLAttributes;
65
+ /**
66
+ * Props forwarded to the title + description stack.
67
+ */
68
+ content?: HTMLAttributes;
69
+ /**
70
+ * Props forwarded to helper text below the picker / list.
71
+ */
72
+ description?: HTMLAttributes;
73
+ /**
74
+ * Props forwarded to the dropzone surface.
75
+ */
76
+ dropzone?: HTMLAttributes;
77
+ /**
78
+ * Props forwarded to validation / error text.
79
+ */
80
+ errorMessage?: HTMLAttributes;
81
+ /**
82
+ * Props forwarded to the hidden file input.
83
+ */
84
+ input?: InputHTMLAttributes;
85
+ /**
86
+ * Props forwarded to each file card.
87
+ */
88
+ item?: HTMLAttributes;
89
+ /**
90
+ * Props forwarded to the optional field label wrapper.
91
+ */
92
+ label?: HTMLAttributes;
93
+ /**
94
+ * Props forwarded to the selected-files list.
95
+ */
96
+ list?: HTMLAttributes;
97
+ /**
98
+ * Props forwarded to the media slot.
99
+ */
100
+ media?: HTMLAttributes;
101
+ /**
102
+ * Props forwarded to the root wrapper.
103
+ */
104
+ root?: HTMLAttributes;
105
+ /**
106
+ * Props forwarded to the file name element.
107
+ */
108
+ title?: HTMLAttributes;
109
+ /**
110
+ * Props forwarded to the button-variant trigger wrapper.
111
+ */
112
+ trigger?: HTMLAttributes;
113
+ }
114
+ export interface FileUploadEmits {
115
+ /**
116
+ * Emitted when an item is removed from the list.
117
+ */
118
+ remove: [value: FileUploadValue, index: number];
119
+ /**
120
+ * Emitted when retry is pressed on an item whose `state` is `error`.
121
+ */
122
+ retry: [value: FileUploadValue, index: number];
123
+ /**
124
+ * Emitted when the selection changes (`v-model`).
125
+ * One item or `null` when `multiple` is false, a list when it is true.
126
+ */
127
+ "update:modelValue": [value: FileUploadModel];
128
+ }
129
+ export interface FileUploadItemSlotProps {
130
+ /**
131
+ * Index in the current selection.
132
+ */
133
+ index: number;
134
+ /**
135
+ * Whether the item can show an image preview.
136
+ */
137
+ isImage: boolean;
138
+ /**
139
+ * Metadata line (type · size).
140
+ */
141
+ metaLabel: string;
142
+ /**
143
+ * Image preview URL (`url` for a remote image, object URL for a `File`).
144
+ */
145
+ previewUrl?: string;
146
+ /**
147
+ * Removes this item from the selection.
148
+ */
149
+ remove: () => void;
150
+ /**
151
+ * Retries this item. Set when the parent listens for `retry`.
152
+ */
153
+ retry?: () => void;
154
+ /**
155
+ * Formatted file size for display.
156
+ */
157
+ sizeLabel: string;
158
+ /**
159
+ * The selected `File` or remote attachment.
160
+ */
161
+ value: FileUploadValue;
162
+ }
163
+ export interface FileUploadItemSlots {
164
+ /**
165
+ * Replaces the remove button.
166
+ */
167
+ end?: Slot<FileUploadItemSlotProps>;
168
+ /**
169
+ * Leading content, before the file media. Use it for a drag handle.
170
+ */
171
+ start?: Slot<FileUploadItemSlotProps>;
172
+ }
173
+ export interface FileUploadListSlotProps {
174
+ /**
175
+ * Selected items in list order. When `multiple` is true, reorder by writing a new array to the model.
176
+ */
177
+ items: FileUploadItemSlotProps[];
178
+ }
179
+ /**
180
+ * File picker with optional dropzone. Selected files always render as the same
181
+ * attachment-style cards whether `multiple` is on or off — there is no FormField
182
+ * chrome for a single file.
183
+ */
184
+ export interface FileUploadOwnProps<Multiple extends boolean = false> {
185
+ /**
186
+ * Native `accept` filter for the file input.
187
+ *
188
+ * @default undefined
189
+ */
190
+ accept?: string;
191
+ /**
192
+ * Label for the button-variant trigger.
193
+ *
194
+ * @default "Choose file" / "Choose files" when `multiple`
195
+ */
196
+ buttonLabel?: string;
197
+ /**
198
+ * The classes to apply to FileUpload parts.
199
+ *
200
+ * @default undefined
201
+ */
202
+ classes?: FileUploadClasses;
203
+ /**
204
+ * Color of the trigger, the remove button, and the dropzone highlight while dragging.
205
+ *
206
+ * @default "primary"
207
+ */
208
+ color?: MergeProps<FileUploadColor, FileUploadColorOverrides>;
209
+ /**
210
+ * Secondary label text at the inline end of the header row.
211
+ *
212
+ * @default undefined
213
+ */
214
+ corner?: string;
215
+ /**
216
+ * Extra props for internal parts (`input`, `dropzone`, `list`, `item`, …).
217
+ *
218
+ * @default undefined
219
+ */
220
+ customProps?: FileUploadCustomProps;
221
+ /**
222
+ * Uncontrolled initial selection. One item or `null` unless `multiple` is true.
223
+ *
224
+ * @default undefined
225
+ */
226
+ defaultValue?: Multiple extends true ? FileUploadValue[] : null | FileUploadValue;
227
+ /**
228
+ * Helper text below the picker / list. Inside the dropzone, also used as the
229
+ * secondary line when `variant="dropzone"`.
230
+ *
231
+ * @default undefined
232
+ */
233
+ description?: string;
234
+ /**
235
+ * Whether picking and dropping are disabled.
236
+ *
237
+ * @default false
238
+ */
239
+ disabled?: boolean;
240
+ /**
241
+ * Marks the control as invalid (error styling on helper chrome).
242
+ *
243
+ * @default false
244
+ */
245
+ error?: boolean;
246
+ /**
247
+ * Error copy shown below the picker / list.
248
+ *
249
+ * @default undefined
250
+ */
251
+ errorMessage?: string;
252
+ /**
253
+ * Optional field label above the picker.
254
+ *
255
+ * @default undefined
256
+ */
257
+ label?: string;
258
+ /**
259
+ * Cap on selected files when `multiple` is true.
260
+ *
261
+ * @default undefined
262
+ */
263
+ maxFiles?: number;
264
+ /**
265
+ * Max bytes per file (validated in the UI; the app still enforces on upload).
266
+ *
267
+ * @default undefined
268
+ */
269
+ maxSize?: number;
270
+ /**
271
+ * When false, the model is one item or `null`. When true, it is a list.
272
+ * A single selection still uses the same attachment card — not a FormField input shell.
273
+ *
274
+ * @default false
275
+ */
276
+ multiple?: Multiple;
277
+ /**
278
+ * Lay each card's media beside the name, or stacked above it.
279
+ *
280
+ * @default "horizontal"
281
+ */
282
+ orientation?: MergeProps<FileUploadOrientation, FileUploadOrientationOverrides>;
283
+ /**
284
+ * Marks the field as required (asterisk on the label).
285
+ *
286
+ * @default false
287
+ */
288
+ required?: boolean;
289
+ /**
290
+ * Border radius for the dropzone, file cards, and media.
291
+ *
292
+ * @default "md"
293
+ */
294
+ rounded?: MergeProps<FileUploadRounded, FileUploadRoundedOverrides>;
295
+ /**
296
+ * Density / dropzone and card scale.
297
+ *
298
+ * @default "md"
299
+ */
300
+ size?: MergeProps<FileUploadSize, FileUploadSizeOverrides>;
301
+ /**
302
+ * Primary copy inside the dropzone surface.
303
+ *
304
+ * @default undefined
305
+ */
306
+ title?: string;
307
+ /**
308
+ * Compact trigger vs large drop surface.
309
+ *
310
+ * @default "button"
311
+ */
312
+ variant?: MergeProps<FileUploadVariant, FileUploadVariantOverrides>;
313
+ }
314
+ export interface FileUploadSlots {
315
+ /**
316
+ * Secondary label at the inline end of the header row.
317
+ */
318
+ corner?: Slot<undefined>;
319
+ /**
320
+ * Replaces helper text below the picker / list.
321
+ */
322
+ description?: Slot<undefined>;
323
+ /**
324
+ * Replaces the default dropzone title / description copy.
325
+ */
326
+ dropzone?: Slot<undefined>;
327
+ /**
328
+ * Replaces the remove button on each default card.
329
+ */
330
+ end?: Slot<FileUploadItemSlotProps>;
331
+ /**
332
+ * Replaces validation / error text.
333
+ */
334
+ errorMessage?: Slot<undefined>;
335
+ /**
336
+ * Replaces the default file card (media + title + meta + remove).
337
+ */
338
+ item?: Slot<FileUploadItemSlotProps>;
339
+ /**
340
+ * Replaces the optional field label.
341
+ */
342
+ label?: Slot<undefined>;
343
+ /**
344
+ * Replaces the default file list. The app owns markup and order.
345
+ * Render `FileUploadItem` to keep the default card.
346
+ */
347
+ list?: Slot<FileUploadListSlotProps>;
348
+ /**
349
+ * Leading content on each default card, before the file media.
350
+ * Use it for a drag handle.
351
+ */
352
+ start?: Slot<FileUploadItemSlotProps>;
353
+ /**
354
+ * Replaces the default button-variant trigger.
355
+ */
356
+ trigger?: Slot<undefined>;
357
+ }
358
+ export type { FileUploadItemState, FileUploadModel, FileUploadRemote, FileUploadValue, } from '@bridge-ui/core/Domain';
359
+ type FileUploadDomProps = Omit<InputHTMLAttributes, "size" | "type" | "value" | "accept" | "disabled" | "multiple" | "onChange" | "defaultValue">;
360
+ export type FileUploadSingleProps = MergeHtmlProps<Omit<FileUploadOwnProps, "multiple" | "defaultValue"> & {
361
+ /**
362
+ * Uncontrolled initial item. `null` when empty.
363
+ *
364
+ * @default undefined
365
+ */
366
+ defaultValue?: null | FileUploadValue;
367
+ /**
368
+ * When false, the model is one item or `null`.
369
+ *
370
+ * @default false
371
+ */
372
+ multiple?: false;
373
+ }, FileUploadDomProps> & {
374
+ /**
375
+ * Bound with `v-model`. One item, or `null` when empty.
376
+ */
377
+ modelValue?: null | FileUploadValue;
378
+ };
379
+ export type FileUploadMultipleProps = MergeHtmlProps<Omit<FileUploadOwnProps, "multiple" | "defaultValue"> & {
380
+ /**
381
+ * Uncontrolled initial list.
382
+ *
383
+ * @default undefined
384
+ */
385
+ defaultValue?: FileUploadValue[];
386
+ /**
387
+ * When true, the model is a list.
388
+ */
389
+ multiple: true;
390
+ }, FileUploadDomProps> & {
391
+ /**
392
+ * Bound with `v-model`.
393
+ */
394
+ modelValue?: FileUploadValue[];
395
+ };
396
+ export type FileUploadProps = FileUploadSingleProps | FileUploadMultipleProps;
@@ -0,0 +1,61 @@
1
+ import { ComputedRef, HTMLAttributes, InjectionKey } from 'vue';
2
+ import { FileUploadOrientation, FileUploadState } from '@bridge-ui/core/Tokens';
3
+ import { ButtonProps } from '../Button';
4
+ /**
5
+ * Card chrome shared by `FileUpload` and `FileUploadItem`.
6
+ */
7
+ export type FileUploadItemContextValue = {
8
+ /**
9
+ * Props for the remove-button cluster.
10
+ */
11
+ actionsBind: HTMLAttributes;
12
+ /**
13
+ * Color forwarded to the default remove button.
14
+ */
15
+ color?: ButtonProps["color"];
16
+ /**
17
+ * Props for the name + metadata stack.
18
+ */
19
+ contentBind: HTMLAttributes;
20
+ /**
21
+ * Props for the metadata line.
22
+ */
23
+ descriptionBind: HTMLAttributes;
24
+ /**
25
+ * Whether the remove button is disabled.
26
+ */
27
+ disabled?: boolean;
28
+ /**
29
+ * Props for the card root.
30
+ */
31
+ getItemBind: (index: number) => HTMLAttributes;
32
+ /**
33
+ * Props for the preview or file icon.
34
+ */
35
+ mediaBind: HTMLAttributes;
36
+ /**
37
+ * Field orientation. Cards inherit it unless they pass their own.
38
+ */
39
+ orientation: string;
40
+ /**
41
+ * Merged orientation tokens, including registry overrides.
42
+ */
43
+ orientationItems: Partial<FileUploadOrientation>;
44
+ /**
45
+ * Radius forwarded to the card and the remove button.
46
+ */
47
+ rounded?: ButtonProps["rounded"];
48
+ /**
49
+ * Field size. `xs` hides the default type · size line.
50
+ */
51
+ size: string;
52
+ /**
53
+ * Merged upload-state tokens, including registry overrides.
54
+ */
55
+ stateItems: Partial<FileUploadState>;
56
+ /**
57
+ * Props for the file name.
58
+ */
59
+ titleBind: HTMLAttributes;
60
+ };
61
+ export declare const FILE_UPLOAD_KEY: InjectionKey<ComputedRef<FileUploadItemContextValue>>;
@@ -0,0 +1,4 @@
1
+ //#region src/Components/FileUpload/fileUploadInjectionKey.ts
2
+ var e = Symbol("bridge-file-upload");
3
+ //#endregion
4
+ export { e as FILE_UPLOAD_KEY };
@@ -0,0 +1,3 @@
1
+ export { useFileUpload } from './composables/useFileUpload';
2
+ export type { FileUploadClasses, FileUploadColorOverrides, FileUploadCustomProps, FileUploadEmits, FileUploadItemSlotProps, FileUploadItemSlots, FileUploadItemState, FileUploadListSlotProps, FileUploadModel, FileUploadOrientationOverrides, FileUploadOwnProps, FileUploadProps, FileUploadRemote, FileUploadRoundedOverrides, FileUploadSizeOverrides, FileUploadSlots, FileUploadValue, FileUploadVariantOverrides, } from './fileUpload.types';
3
+ export { default as FileUpload } from './FileUpload.vue';
@@ -0,0 +1,3 @@
1
+ import { useFileUpload as e } from "./composables/useFileUpload.js";
2
+ import t from "./FileUpload.js";
3
+ export { t as FileUpload, e as useFileUpload };
@@ -0,0 +1,5 @@
1
+ import e from "./FileUploadItem.vue_vue_type_script_setup_true_lang.js";
2
+ //#region src/Components/FileUploadItem/FileUploadItem.vue
3
+ var t = e;
4
+ //#endregion
5
+ export { t as default };
@@ -0,0 +1,12 @@
1
+ import { FileUploadItemSlots } from '../FileUpload/fileUpload.types';
2
+ import { FileUploadItemOwnProps } from './fileUploadItem.types';
3
+ type __VLS_Slots = FileUploadItemSlots;
4
+ declare const __VLS_base: import('vue').DefineComponent<FileUploadItemOwnProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<FileUploadItemOwnProps> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
5
+ declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
6
+ declare const _default: typeof __VLS_export;
7
+ export default _default;
8
+ type __VLS_WithSlots<T, S> = T & {
9
+ new (): {
10
+ $slots: S;
11
+ };
12
+ };
@@ -0,0 +1,83 @@
1
+ import { hasNamedSlot as e } from "../../Utils/slotOrProp.js";
2
+ import t from "../Icon/Icon.js";
3
+ import n from "../Button/Button.js";
4
+ import { useFileUploadItem as r } from "./composables/useFileUploadItem.js";
5
+ import { computed as i, createBlock as a, createCommentVNode as o, createElementBlock as s, createElementVNode as c, defineComponent as l, guardReactiveProps as u, mergeProps as d, normalizeClass as f, normalizeProps as p, openBlock as m, renderSlot as h, toDisplayString as g, unref as _, useSlots as v } from "vue";
6
+ //#region src/Components/FileUploadItem/FileUploadItem.vue?vue&type=script&setup=true&lang.ts
7
+ var y = {
8
+ key: 0,
9
+ class: "flex shrink-0 items-center"
10
+ }, b = ["src"], x = /*@__PURE__*/ l({
11
+ inheritAttrs: !1,
12
+ __name: "FileUploadItem",
13
+ props: {
14
+ description: {},
15
+ orientation: {},
16
+ index: {},
17
+ isImage: { type: Boolean },
18
+ metaLabel: {},
19
+ previewUrl: {},
20
+ remove: { type: Function },
21
+ retry: { type: Function },
22
+ sizeLabel: {},
23
+ value: {}
24
+ },
25
+ setup(l) {
26
+ let x = l, S = v(), { name: C, media: w, retry: T, color: E, remove: D, rounded: O, disabled: k, rootBind: A, showRetry: j, mediaBind: M, titleBind: N, contentBind: P, actionsBind: F, statusLabel: I, descriptionBind: L, showDescription: R } = r(x), z = i(() => w.value.kind === "image" ? w.value.src : void 0), B = i(() => w.value.kind === "icon" ? w.value.icon : "download"), V = i(() => w.value.kind === "icon" && w.value.spin);
27
+ function H() {
28
+ T.value?.();
29
+ }
30
+ function U() {
31
+ D.value();
32
+ }
33
+ return (r, i) => (m(), s("li", p(u(_(A))), [
34
+ _(e)(_(S), "start") ? (m(), s("div", y, [h(r.$slots, "start", p(u(x)))])) : o("", !0),
35
+ c("div", p(u(_(M))), [z.value ? (m(), s("img", {
36
+ key: 0,
37
+ alt: "",
38
+ src: z.value
39
+ }, null, 8, b)) : (m(), a(_(t), {
40
+ key: 1,
41
+ icon: B.value,
42
+ class: f(V.value ? "animate-spin" : void 0)
43
+ }, null, 8, ["icon", "class"]))], 16),
44
+ c("div", p(u(_(P))), [c("p", p(u(_(N))), g(_(C)), 17), _(R) ? (m(), s("p", p(d({ key: 0 }, _(L))), g(_(I)), 17)) : o("", !0)], 16),
45
+ c("div", p(u(_(F))), [_(j) ? (m(), a(_(n), {
46
+ key: 0,
47
+ size: "sm",
48
+ type: "button",
49
+ color: "error",
50
+ icon: "refresh",
51
+ variant: "flat",
52
+ density: "mini",
53
+ rounded: _(O),
54
+ onClick: H,
55
+ disabled: _(k),
56
+ "aria-label": `Retry ${_(C)}`
57
+ }, null, 8, [
58
+ "rounded",
59
+ "disabled",
60
+ "aria-label"
61
+ ])) : o("", !0), _(e)(_(S), "end") ? h(r.$slots, "end", p(u(x)), void 0, void 0, 1) : (m(), a(_(n), {
62
+ key: 2,
63
+ size: "sm",
64
+ icon: "clear",
65
+ type: "button",
66
+ variant: "flat",
67
+ density: "mini",
68
+ color: _(E),
69
+ rounded: _(O),
70
+ disabled: _(k),
71
+ onClick: U,
72
+ "aria-label": `Remove ${_(C)}`
73
+ }, null, 8, [
74
+ "color",
75
+ "rounded",
76
+ "disabled",
77
+ "aria-label"
78
+ ]))], 16)
79
+ ], 16));
80
+ }
81
+ });
82
+ //#endregion
83
+ export { x as default };