@uzum-tech/ui 2.3.1 → 2.3.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.
Files changed (52) hide show
  1. package/dist/index.js +373 -340
  2. package/dist/index.mjs +373 -340
  3. package/dist/index.prod.js +2 -2
  4. package/dist/index.prod.mjs +2 -2
  5. package/es/components.d.ts +10 -7
  6. package/es/image/src/ImagePreview.d.ts +1 -0
  7. package/es/image/src/ImagePreview.mjs +7 -35
  8. package/es/image/src/public-types.d.ts +4 -4
  9. package/es/message-bubble/src/MessageBubble.mjs +10 -3
  10. package/es/upload/index.d.ts +2 -1
  11. package/es/upload/index.mjs +2 -1
  12. package/es/upload/src/Upload.d.ts +73 -1007
  13. package/es/upload/src/Upload.mjs +43 -124
  14. package/es/upload/src/UploadFile.d.ts +1 -1
  15. package/es/upload/src/UploadFile.mjs +8 -2
  16. package/es/upload/src/UploadFileList.mjs +17 -2
  17. package/es/upload/src/UploadProgress.d.ts +3 -2
  18. package/es/upload/src/interface.d.ts +1086 -92
  19. package/es/upload/src/interface.mjs +117 -1
  20. package/es/upload/src/public-types.d.ts +17 -2
  21. package/es/upload/src/useUploadActionsRender.d.ts +2 -27
  22. package/es/upload/src/useUploadActionsRender.mjs +2 -2
  23. package/es/upload/src/useUploadInternals.d.ts +2 -25
  24. package/es/upload/src/utils.d.ts +2 -0
  25. package/es/upload/src/utils.mjs +7 -0
  26. package/es/version.d.ts +1 -1
  27. package/es/version.mjs +1 -1
  28. package/lib/components.d.ts +10 -7
  29. package/lib/image/src/ImagePreview.d.ts +1 -0
  30. package/lib/image/src/ImagePreview.js +3 -19
  31. package/lib/image/src/public-types.d.ts +4 -4
  32. package/lib/message-bubble/src/MessageBubble.js +10 -4
  33. package/lib/upload/index.d.ts +2 -1
  34. package/lib/upload/index.js +2 -1
  35. package/lib/upload/src/Upload.d.ts +73 -1007
  36. package/lib/upload/src/Upload.js +40 -68
  37. package/lib/upload/src/UploadFile.d.ts +1 -1
  38. package/lib/upload/src/UploadFile.js +12 -4
  39. package/lib/upload/src/UploadFileList.js +8 -1
  40. package/lib/upload/src/UploadProgress.d.ts +3 -2
  41. package/lib/upload/src/interface.d.ts +1086 -92
  42. package/lib/upload/src/interface.js +59 -1
  43. package/lib/upload/src/public-types.d.ts +17 -2
  44. package/lib/upload/src/useUploadActionsRender.d.ts +2 -27
  45. package/lib/upload/src/useUploadActionsRender.js +2 -2
  46. package/lib/upload/src/useUploadInternals.d.ts +2 -25
  47. package/lib/upload/src/utils.d.ts +2 -0
  48. package/lib/upload/src/utils.js +10 -0
  49. package/lib/version.d.ts +1 -1
  50. package/lib/version.js +1 -1
  51. package/package.json +1 -1
  52. package/web-types.json +104 -23
@@ -1,5 +1,63 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.uploadInjectionKey = void 0;
3
+ exports.uploadProps = exports.uploadInjectionKey = void 0;
4
+ const _mixins_1 = require("../../_mixins");
4
5
  const _utils_1 = require("../../_utils");
6
+ const utils_1 = require("./utils");
5
7
  exports.uploadInjectionKey = (0, _utils_1.createInjectionKey)('u-upload');
8
+ exports.uploadProps = Object.assign(Object.assign({}, _mixins_1.useTheme.props), { name: {
9
+ type: String,
10
+ default: 'file'
11
+ }, accept: String, action: String, customRequest: Function, directory: Boolean, directoryDnd: { type: Boolean, default: undefined }, method: {
12
+ type: String,
13
+ default: 'POST'
14
+ }, multiple: Boolean, showFileList: {
15
+ type: Boolean,
16
+ default: true
17
+ }, data: [Object, Function], headers: [Object, Function], withCredentials: Boolean, responseType: {
18
+ type: String,
19
+ default: ''
20
+ }, disabled: {
21
+ type: Boolean,
22
+ default: undefined
23
+ }, vertical: {
24
+ type: Boolean,
25
+ default: false
26
+ }, icon: Object, onChange: Function, onRemove: Function, onFinish: Function, onError: Function, onRetry: Function, onBeforeUpload: Function, isErrorState: Function, onDownload: Function, defaultUpload: {
27
+ type: Boolean,
28
+ default: true
29
+ }, fileList: Array, 'onUpdate:fileList': [Function, Array], onUpdateFileList: [Function, Array], fileListClass: String, fileListStyle: [String, Object], defaultFileList: {
30
+ type: Array,
31
+ default: () => []
32
+ }, showCancelButton: {
33
+ type: Boolean,
34
+ default: true
35
+ }, showRemoveButton: {
36
+ type: Boolean,
37
+ default: true
38
+ }, showDownloadButton: Boolean, showRetryButton: {
39
+ type: Boolean,
40
+ default: true
41
+ }, customDownload: Function, showPreviewButton: {
42
+ type: Boolean,
43
+ default: true
44
+ }, listType: {
45
+ type: String,
46
+ default: 'text'
47
+ }, onPreview: Function, shouldUseThumbnailUrl: {
48
+ type: Function,
49
+ default: (file) => {
50
+ if (!utils_1.environmentSupportFile)
51
+ return false;
52
+ return (0, utils_1.isImageFile)(file);
53
+ }
54
+ }, createThumbnailUrl: Function, abstract: Boolean, max: Number, maxSize: Number, showTrigger: {
55
+ type: Boolean,
56
+ default: true
57
+ }, imageGroupProps: Object, inputProps: Object, triggerClass: String, triggerStyle: [String, Object], renderIcon: Function, label: String, size: {
58
+ type: String,
59
+ default: 'medium'
60
+ }, title: String, subtitle: String, noIcon: {
61
+ type: Boolean,
62
+ default: false
63
+ } });
@@ -1,13 +1,28 @@
1
- import type { CustomRequestOptions, FileInfo, FuncOrRecordOrUndef, OnChange, OnDownload, OnFinish, OnRemove, OnRetry, SettledFileInfo, UploadInst as UploadInstInner } from './interface';
2
- export type { UploadProps } from './Upload';
1
+ import type { CustomRequestOptions, FileInfo, FuncOrRecordOrUndef, IsErrorState, ListType, OnBeforeUpload, OnBeforeUploadPayload, OnChange, OnChangePayload, OnDownload, OnError, OnErrorPayload, OnFinish, OnFinishPayload, OnPreview, OnRemove, OnRemovePayload, OnRetry, OnRetryPayload, OnUpdateFileList, RenderIcon, SettledFileInfo, ShouldUseThumbnailUrl, SubmitOptions, UploadInst as UploadInstInner } from './interface';
2
+ export type { UploadLocale, UploadProps, UploadSize } from './interface';
3
3
  export interface UploadInst extends UploadInstInner {
4
4
  }
5
5
  export type UploadFileInfo = FileInfo;
6
6
  export type UploadCustomRequestOptions = CustomRequestOptions;
7
7
  export type UploadSettledFileInfo = SettledFileInfo;
8
+ export type UploadListType = ListType;
9
+ export type UploadIsErrorState = IsErrorState;
10
+ export type UploadRenderIcon = RenderIcon;
11
+ export type UploadShouldUseThumbnailUrl = ShouldUseThumbnailUrl;
12
+ export type UploadSubmitOptions = SubmitOptions;
8
13
  export type UploadOnChange = OnChange;
14
+ export type UploadOnChangePayload = OnChangePayload;
9
15
  export type UploadOnFinish = OnFinish;
16
+ export type UploadOnFinishPayload = OnFinishPayload;
17
+ export type UploadOnError = OnError;
18
+ export type UploadOnErrorPayload = OnErrorPayload;
10
19
  export type UploadOnRemove = OnRemove;
20
+ export type UploadOnRemovePayload = OnRemovePayload;
11
21
  export type UploadOnDownload = OnDownload;
12
22
  export type UploadOnRetry = OnRetry;
23
+ export type UploadOnRetryPayload = OnRetryPayload;
24
+ export type UploadOnPreview = OnPreview;
25
+ export type UploadOnBeforeUpload = OnBeforeUpload;
26
+ export type UploadOnBeforeUploadPayload = OnBeforeUploadPayload;
27
+ export type UploadOnUpdateFileList = OnUpdateFileList;
13
28
  export type { FuncOrRecordOrUndef };
@@ -1,27 +1,2 @@
1
- import type { VNode } from 'vue';
2
- import type { ListType, RenderIcon, SettledFileInfo } from './interface';
3
- interface Options {
4
- clsPrefix: string;
5
- listType: ListType;
6
- file: SettledFileInfo;
7
- renderIcon?: RenderIcon;
8
- showPreviewButton: string | boolean | null;
9
- showRemoveButton: boolean;
10
- showCancelButton: boolean;
11
- showRetryButton: boolean;
12
- showDownloadButton: boolean;
13
- disabled: boolean;
14
- buttonType: string | undefined;
15
- mergedTheme: any;
16
- buttonThemeOverrides: any;
17
- handlePreviewClick: () => void;
18
- handleRemoveOrCancelClick: (e: MouseEvent) => void;
19
- handleRetryClick: () => void;
20
- handleDownloadClick: (e: MouseEvent) => void;
21
- capitalizeFirstLetter: (text: string) => string;
22
- }
23
- export declare function useUploadActionsRender(opts: Options): {
24
- actionsNode: VNode;
25
- icon: VNode;
26
- };
27
- export {};
1
+ import type { UploadActionsRenderOptions, UploadActionsRenderReturn } from './interface';
2
+ export declare function useUploadActionsRender(options: UploadActionsRenderOptions): UploadActionsRenderReturn;
@@ -5,8 +5,8 @@ const vue_1 = require("vue");
5
5
  const _internal_1 = require("../../_internal");
6
6
  const icons_1 = require("../../_internal/icons");
7
7
  const button_1 = require("../../button");
8
- function useUploadActionsRender(opts) {
9
- const { clsPrefix, listType, file, renderIcon, showPreviewButton, showRemoveButton, showCancelButton, showRetryButton, showDownloadButton, disabled, buttonType, mergedTheme, buttonThemeOverrides, handlePreviewClick, handleRemoveOrCancelClick, handleRetryClick, handleDownloadClick, capitalizeFirstLetter } = opts;
8
+ function useUploadActionsRender(options) {
9
+ const { clsPrefix, listType, file, renderIcon, showPreviewButton, showRemoveButton, showCancelButton, showRetryButton, showDownloadButton, disabled, buttonType, mergedTheme, buttonThemeOverrides, handlePreviewClick, handleRemoveOrCancelClick, handleRetryClick, handleDownloadClick, capitalizeFirstLetter } = options;
10
10
  const getExt = (name) => {
11
11
  const i = name.lastIndexOf('.');
12
12
  return i === -1 || i === name.length - 1 ? '' : name.slice(i + 1);
@@ -1,25 +1,2 @@
1
- import type { Slots, VNode } from 'vue';
2
- interface UseUploadInternalsOptions {
3
- mergedClsPrefix: string;
4
- accept?: string;
5
- multiple?: boolean;
6
- inputProps?: Record<string, any>;
7
- directory?: boolean;
8
- onChange?: (e: Event) => void;
9
- label?: string;
10
- title?: string;
11
- subtitle?: string;
12
- vertical?: boolean;
13
- noIcon?: boolean;
14
- icon?: any;
15
- localeRef: {
16
- title: string;
17
- subtitle: string;
18
- };
19
- slots: Slots;
20
- }
21
- export declare function useUploadInternals(options: UseUploadInternalsOptions): {
22
- inputNode: VNode;
23
- renderDefaultTrigger: () => VNode[];
24
- };
25
- export {};
1
+ import type { UseUploadInternalsOptions, UseUploadInternalsReturn } from './interface';
2
+ export declare function useUploadInternals(options: UseUploadInternalsOptions): UseUploadInternalsReturn;
@@ -10,6 +10,8 @@ export declare const environmentSupportFile: false | {
10
10
  export declare function isFileSystemDirectoryEntry(item: FileSystemEntry | FileSystemFileEntry | FileSystemDirectoryEntry): item is FileSystemDirectoryEntry;
11
11
  export declare function isFileSystemFileEntry(item: FileSystemEntry | FileSystemFileEntry | FileSystemDirectoryEntry): item is FileSystemFileEntry;
12
12
  export declare function getFilesFromEntries(entries: readonly FileSystemEntry[] | Array<FileSystemEntry | null>, directory: boolean): Promise<FileAndEntry[]>;
13
+ export declare function getFilePreviewSrc(file: SettledFileInfo): string | null;
14
+ export declare function isFileSizeExceeded(file: File | null | undefined, maxSize: number | undefined): boolean;
13
15
  export declare function createSettledFileInfo(fileInfo: FileInfo): SettledFileInfo;
14
16
  /**
15
17
  * This is a rather simple version. I may fix it later to make it more accurate.
@@ -16,6 +16,8 @@ exports.createImageDataUrl = createImageDataUrl;
16
16
  exports.isFileSystemDirectoryEntry = isFileSystemDirectoryEntry;
17
17
  exports.isFileSystemFileEntry = isFileSystemFileEntry;
18
18
  exports.getFilesFromEntries = getFilesFromEntries;
19
+ exports.getFilePreviewSrc = getFilePreviewSrc;
20
+ exports.isFileSizeExceeded = isFileSizeExceeded;
19
21
  exports.createSettledFileInfo = createSettledFileInfo;
20
22
  exports.matchType = matchType;
21
23
  exports.download = download;
@@ -118,6 +120,14 @@ function getFilesFromEntries(entries, directory) {
118
120
  return fileAndEntries;
119
121
  });
120
122
  }
123
+ function getFilePreviewSrc(file) {
124
+ return file.url || file.thumbnailUrl || null;
125
+ }
126
+ function isFileSizeExceeded(file, maxSize) {
127
+ if (maxSize === undefined || !file)
128
+ return false;
129
+ return file.size > maxSize;
130
+ }
121
131
  function createSettledFileInfo(fileInfo) {
122
132
  const { id, name, percentage, status, url, file, thumbnailUrl, type, fullPath, batchId } = fileInfo;
123
133
  return {
package/lib/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- declare const _default: "2.3.1";
1
+ declare const _default: "2.3.2";
2
2
  export default _default;
package/lib/version.js CHANGED
@@ -1,3 +1,3 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.default = '2.3.1';
3
+ exports.default = '2.3.2';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@uzum-tech/ui",
3
- "version": "2.3.1",
3
+ "version": "2.3.2",
4
4
  "packageManager": "pnpm@10.33.0",
5
5
  "description": "A Vue 3 Component Library. Fairly Complete, Theme Customizable, Uses TypeScript, Fast",
6
6
  "author": {
package/web-types.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "$schema": "https://raw.githubusercontent.com/JetBrains/web-types/master/schema/web-types.json",
3
3
  "framework": "vue",
4
4
  "name": "@uzum-tech/ui",
5
- "version": "2.3.1",
5
+ "version": "2.3.2",
6
6
  "js-types-syntax": "typescript",
7
7
  "contributions": {
8
8
  "html": {
@@ -2604,7 +2604,7 @@
2604
2604
  "name": "message-upload-props",
2605
2605
  "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/chat",
2606
2606
  "type": "Partial<UploadProps>",
2607
- "description": "Props for upload display in messages.",
2607
+ "description": "Props for upload display in messages. Attachments are rendered with `list-type=\"preview-list\"`, so the ones with a `preview`/`thumbnail` image open in the built-in image preview; it can be overridden here.",
2608
2608
  "default": "undefined"
2609
2609
  }
2610
2610
  ],
@@ -10395,14 +10395,14 @@
10395
10395
  "name": "attachments",
10396
10396
  "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/message-bubble",
10397
10397
  "type": "MessageBubbleAttachment | MessageBubbleAttachment[]",
10398
- "description": "Attachments rendered through upload file list UI.",
10398
+ "description": "Attachments rendered through upload file list UI. Attachments with a `preview` or `thumbnail` image can be opened in the built-in image preview.",
10399
10399
  "default": "undefined"
10400
10400
  },
10401
10401
  {
10402
10402
  "name": "upload-props",
10403
10403
  "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/message-bubble",
10404
10404
  "type": "Partial<UploadProps>",
10405
- "description": "Props passed to internal `UUpload`.",
10405
+ "description": "Props passed to internal `UUpload`. It's rendered with `list-type=\"preview-list\"` and a `should-use-thumbnail-url` that marks the attachments with an image as previewable, both can be overridden here.",
10406
10406
  "default": "undefined"
10407
10407
  },
10408
10408
  {
@@ -16619,6 +16619,28 @@
16619
16619
  "name": "default",
16620
16620
  "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
16621
16621
  "description": "The content of the upload."
16622
+ },
16623
+ {
16624
+ "name": "title",
16625
+ "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
16626
+ "description": "Title of the default trigger. Overridden by the `title` prop."
16627
+ },
16628
+ {
16629
+ "name": "subtitle",
16630
+ "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
16631
+ "description": "Subtitle of the default trigger. Overridden by the `subtitle` prop."
16632
+ },
16633
+ {
16634
+ "name": "upload-file-title",
16635
+ "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
16636
+ "type": "{ file: UploadSettledFileInfo }",
16637
+ "description": "Title of a file item, the file name by default."
16638
+ },
16639
+ {
16640
+ "name": "upload-file-subtitle",
16641
+ "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
16642
+ "type": "{ file: UploadSettledFileInfo }",
16643
+ "description": "Subtitle of a file item, empty by default."
16622
16644
  }
16623
16645
  ],
16624
16646
  "attributes": [],
@@ -16750,6 +16772,13 @@
16750
16772
  "description": "The additional HTTP Headers of request.",
16751
16773
  "default": "undefined"
16752
16774
  },
16775
+ {
16776
+ "name": "icon",
16777
+ "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
16778
+ "type": "VNodeChild",
16779
+ "description": "Icon of the default trigger.",
16780
+ "default": "undefined"
16781
+ },
16753
16782
  {
16754
16783
  "name": "input-props",
16755
16784
  "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
@@ -16764,7 +16793,7 @@
16764
16793
  "name": "image-group-props",
16765
16794
  "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
16766
16795
  "type": "ImageGroupProps",
16767
- "description": "Props of `u-image` inside upload. See [ImageGroup Props](image#ImageGroup-Props).",
16796
+ "description": "Props of the `u-image-group` used for image preview. See [ImageGroup Props](image#ImageGroup-Props). With `list-type=\"preview-list\"` the `src-list`, `show` and `current` props of the group are managed by the component.",
16768
16797
  "default": "undefined",
16769
16798
  "description-sections": {
16770
16799
  "since": "2.24.0"
@@ -16780,12 +16809,22 @@
16780
16809
  "since": "2.29.1"
16781
16810
  }
16782
16811
  },
16812
+ {
16813
+ "name": "label",
16814
+ "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
16815
+ "type": "string",
16816
+ "description": "Text rendered above the default trigger.",
16817
+ "default": "undefined"
16818
+ },
16783
16819
  {
16784
16820
  "name": "list-type",
16785
16821
  "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
16786
16822
  "type": "string",
16787
- "description": "Built-in styles for file lists, `text`, `image` and `image-card`.",
16788
- "default": "'text'"
16823
+ "description": "Built-in styles for file lists, `text`, `image`, `image-card` and `preview-list`. `preview-list` looks exactly like `text`, but image files are opened in the built-in image preview.",
16824
+ "default": "'text'",
16825
+ "description-sections": {
16826
+ "since": "`preview-list` 2.3.2"
16827
+ }
16789
16828
  },
16790
16829
  {
16791
16830
  "name": "max",
@@ -16794,6 +16833,16 @@
16794
16833
  "description": "Uploaded files limit.",
16795
16834
  "default": "undefined"
16796
16835
  },
16836
+ {
16837
+ "name": "max-size",
16838
+ "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
16839
+ "type": "number",
16840
+ "description": "Max size of a single file in bytes. A file that exceeds it isn't uploaded — it's added to the file list with the `error` status.",
16841
+ "default": "undefined",
16842
+ "description-sections": {
16843
+ "since": "2.3.2"
16844
+ }
16845
+ },
16797
16846
  {
16798
16847
  "name": "method",
16799
16848
  "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
@@ -16815,11 +16864,18 @@
16815
16864
  "description": "The field name for the file(s) in the HTTP request's form data.",
16816
16865
  "default": "'file'"
16817
16866
  },
16867
+ {
16868
+ "name": "no-icon",
16869
+ "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
16870
+ "type": "boolean",
16871
+ "description": "Whether to hide the icon of the default trigger.",
16872
+ "default": "false"
16873
+ },
16818
16874
  {
16819
16875
  "name": "render-icon",
16820
16876
  "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
16821
16877
  "type": "(file: UploadSettledFileInfo) => VNodeChild",
16822
- "description": "Render function of file icon. It only works when `list-type=\"image\"` or `list-type=\"image-card\"`.",
16878
+ "description": "Render function of file icon. Replaces the default icon of the file item for any `list-type`.",
16823
16879
  "default": "undefined",
16824
16880
  "description-sections": {
16825
16881
  "since": "2.34.0"
@@ -16839,10 +16895,10 @@
16839
16895
  "name": "should-use-thumbnail-url",
16840
16896
  "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
16841
16897
  "type": "(file: UploadSettledFileInfo) => boolean",
16842
- "description": "A function that determines whether to show thumbnail for the file. It only works when `list-type=\"image\"` or `list-type=\"image-card\"`.",
16898
+ "description": "A function that determines whether to show thumbnail for the file. It only works when `list-type=\"image\"` or `list-type=\"image-card\"`. For `list-type=\"preview-list\"` it determines which files can be opened in the image preview.",
16843
16899
  "default": "A function that only returns `true` for image typed file.",
16844
16900
  "description-sections": {
16845
- "since": "2.34.0"
16901
+ "since": "2.34.0, `preview-list` 2.3.2"
16846
16902
  }
16847
16903
  },
16848
16904
  {
@@ -16870,8 +16926,11 @@
16870
16926
  "name": "show-preview-button",
16871
16927
  "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
16872
16928
  "type": "boolean",
16873
- "description": "Show a preview button (when `list-type` is `image-card`). Use the `on-preview` callback for this event.",
16874
- "default": "true"
16929
+ "description": "Show a preview button (when `list-type` is `image-card` or `preview-list`). Use the `on-preview` callback to replace the built-in preview.",
16930
+ "default": "true",
16931
+ "description-sections": {
16932
+ "since": "`preview-list` 2.3.2"
16933
+ }
16875
16934
  },
16876
16935
  {
16877
16936
  "name": "show-remove-button",
@@ -16897,6 +16956,27 @@
16897
16956
  "since": "2.21.5"
16898
16957
  }
16899
16958
  },
16959
+ {
16960
+ "name": "size",
16961
+ "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
16962
+ "type": "'small' | 'medium' | 'large'",
16963
+ "description": "Size of the default trigger, it sets the dragger width from the theme (`small` — 140px, `medium` and `large` — auto). Falls back to the size of the parent form item.",
16964
+ "default": "'medium'"
16965
+ },
16966
+ {
16967
+ "name": "subtitle",
16968
+ "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
16969
+ "type": "string",
16970
+ "description": "Subtitle of the default trigger. Falls back to the `subtitle` slot and then to the locale text.",
16971
+ "default": "undefined"
16972
+ },
16973
+ {
16974
+ "name": "title",
16975
+ "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
16976
+ "type": "string",
16977
+ "description": "Title of the default trigger. Falls back to the `title` slot and then to the locale text.",
16978
+ "default": "undefined"
16979
+ },
16900
16980
  {
16901
16981
  "name": "trigger-class",
16902
16982
  "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
@@ -16917,6 +16997,13 @@
16917
16997
  "since": "2.29.1"
16918
16998
  }
16919
16999
  },
17000
+ {
17001
+ "name": "vertical",
17002
+ "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
17003
+ "type": "boolean",
17004
+ "description": "Stack the icon and the text of the default trigger vertically.",
17005
+ "default": "false"
17006
+ },
16920
17007
  {
16921
17008
  "name": "with-credentials",
16922
17009
  "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
@@ -16968,22 +17055,16 @@
16968
17055
  {
16969
17056
  "name": "preview",
16970
17057
  "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
16971
- "type": "(file: FileInfo, detail: { event: MouseEvent }) => void",
16972
- "description": "Callback for clicking file links or preview buttons. You can use `preventDefault` to prevent default anchor link open behavior.",
16973
- "default": "undefined",
16974
- "description-sections": {
16975
- "since": "`detail.event` 2.39.0"
16976
- }
17058
+ "type": "(file: UploadFileInfo) => void",
17059
+ "description": "Callback for clicking a file name or a preview button. When it's set, it replaces the built-in preview.",
17060
+ "default": "undefined"
16977
17061
  },
16978
17062
  {
16979
17063
  "name": "remove",
16980
17064
  "doc-url": "https://uzum-ui.kapitalbank.uz/en-US/os-theme/components/upload",
16981
- "type": "(options: { file: UploadFileInfo, fileList: Array<UploadFileInfo>, index: number }) => Promise<boolean> | boolean | any",
17065
+ "type": "(options: { file: UploadFileInfo, fileList: Array<UploadFileInfo> }) => Promise<boolean> | boolean | any",
16982
17066
  "description": "File removed callback. Returning `false`, a promise resolved with `false`, or a rejected promise will cancel this removal.",
16983
- "default": "() => true",
16984
- "description-sections": {
16985
- "since": "`index` 2.38.2"
16986
- }
17067
+ "default": "() => true"
16987
17068
  },
16988
17069
  {
16989
17070
  "name": "retry",