@dimah-s3/ui 0.6.2 → 0.7.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/README.md +13 -1
- package/css/shadcn.css +30 -0
- package/dist/components/{ui → dimah-s3/attachment}/circle-progress.d.ts +2 -1
- package/dist/components/dimah-s3/attachment/circle-progress.d.ts.map +1 -0
- package/dist/components/dimah-s3/attachment/file-attachment.d.ts +25 -0
- package/dist/components/dimah-s3/attachment/file-attachment.d.ts.map +1 -0
- package/dist/components/dimah-s3/attachment/status-attachment.d.ts +20 -0
- package/dist/components/dimah-s3/attachment/status-attachment.d.ts.map +1 -0
- package/dist/components/{delete → dimah-s3/delete}/delete-button.d.ts +11 -5
- package/dist/components/dimah-s3/delete/delete-button.d.ts.map +1 -0
- package/dist/components/{download → dimah-s3/download}/download-button.d.ts +11 -5
- package/dist/components/dimah-s3/download/download-button.d.ts.map +1 -0
- package/dist/components/{download → dimah-s3/download}/progress-download-button.d.ts +11 -5
- package/dist/components/dimah-s3/download/progress-download-button.d.ts.map +1 -0
- package/dist/components/dimah-s3/upload/multi-upload-status.d.ts +12 -0
- package/dist/components/dimah-s3/upload/multi-upload-status.d.ts.map +1 -0
- package/dist/components/dimah-s3/upload/upload-button.d.ts +36 -0
- package/dist/components/dimah-s3/upload/upload-button.d.ts.map +1 -0
- package/dist/components/dimah-s3/upload/upload-dropzone.d.ts +31 -0
- package/dist/components/dimah-s3/upload/upload-dropzone.d.ts.map +1 -0
- package/dist/components/{upload → dimah-s3/upload}/upload-status-block.d.ts +5 -7
- package/dist/components/dimah-s3/upload/upload-status-block.d.ts.map +1 -0
- package/dist/components/dimah-s3/upload/upload-status.d.ts +14 -0
- package/dist/components/dimah-s3/upload/upload-status.d.ts.map +1 -0
- package/dist/components/ui/attachment.d.ts +24 -0
- package/dist/components/ui/attachment.d.ts.map +1 -0
- package/dist/components/ui/button.d.ts.map +1 -1
- package/dist/hooks/use-file-reject-toast.d.ts +7 -0
- package/dist/hooks/use-file-reject-toast.d.ts.map +1 -0
- package/dist/hooks/use-upload-toast.d.ts +2 -5
- package/dist/hooks/use-upload-toast.d.ts.map +1 -1
- package/dist/index.d.ts +12 -8
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1072 -333
- package/dist/index.js.map +1 -1
- package/dist/lib/attachment.d.ts +37 -0
- package/dist/lib/attachment.d.ts.map +1 -0
- package/dist/lib/file-type-icon.d.ts +13 -0
- package/dist/lib/file-type-icon.d.ts.map +1 -0
- package/package.json +19 -11
- package/styles.css +8 -2
- package/dist/components/delete/delete-button.d.ts.map +0 -1
- package/dist/components/download/download-button.d.ts.map +0 -1
- package/dist/components/download/progress-download-button.d.ts.map +0 -1
- package/dist/components/ui/circle-progress.d.ts.map +0 -1
- package/dist/components/upload/multi-upload-status.d.ts +0 -9
- package/dist/components/upload/multi-upload-status.d.ts.map +0 -1
- package/dist/components/upload/upload-button.d.ts +0 -30
- package/dist/components/upload/upload-button.d.ts.map +0 -1
- package/dist/components/upload/upload-dropzone.d.ts +0 -22
- package/dist/components/upload/upload-dropzone.d.ts.map +0 -1
- package/dist/components/upload/upload-status-block.d.ts.map +0 -1
- package/dist/components/upload/upload-status.d.ts +0 -14
- package/dist/components/upload/upload-status.d.ts.map +0 -1
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import type { ComponentProps, ReactNode } from "react";
|
|
2
|
+
import { Attachment } from "../components/ui/attachment";
|
|
3
|
+
/**
|
|
4
|
+
* Attachment layout/state types — derived from stock shadcn {@link Attachment}
|
|
5
|
+
* (do not edit `components/ui/attachment.tsx`).
|
|
6
|
+
*/
|
|
7
|
+
export type AttachmentState = NonNullable<ComponentProps<typeof Attachment>["state"]>;
|
|
8
|
+
export type AttachmentSize = NonNullable<ComponentProps<typeof Attachment>["size"]>;
|
|
9
|
+
export type AttachmentOrientation = NonNullable<ComponentProps<typeof Attachment>["orientation"]>;
|
|
10
|
+
/** `size` / `orientation` forwarded onto stock `Attachment`. */
|
|
11
|
+
export type AttachmentLayoutProps = {
|
|
12
|
+
size?: AttachmentSize;
|
|
13
|
+
orientation?: AttachmentOrientation;
|
|
14
|
+
};
|
|
15
|
+
/**
|
|
16
|
+
* Wired button/dropzone aliases — avoids clashing with Button `size`.
|
|
17
|
+
* Maps to {@link AttachmentLayoutProps} on status rows.
|
|
18
|
+
*/
|
|
19
|
+
export type AttachmentLayoutAliases = {
|
|
20
|
+
/** Attachment size (not the trigger button size). @default "sm" */
|
|
21
|
+
attachmentSize?: AttachmentSize;
|
|
22
|
+
/** Attachment orientation. @default "horizontal" */
|
|
23
|
+
attachmentOrientation?: AttachmentOrientation;
|
|
24
|
+
};
|
|
25
|
+
/** Error description: allow wrap past truncate (AttachmentDescription default). */
|
|
26
|
+
export declare const ATTACHMENT_ERROR_DESCRIPTION_CLASS = "overflow-visible whitespace-normal [overflow-wrap:anywhere]";
|
|
27
|
+
/**
|
|
28
|
+
* Controls inline status rendering for wired UI components.
|
|
29
|
+
*
|
|
30
|
+
* - `true` (default): render the status node in the default slot
|
|
31
|
+
* - `false`: hide status
|
|
32
|
+
* - `(node) => ReactNode`: wrap or relocate the status node
|
|
33
|
+
*/
|
|
34
|
+
export type StatusSlot = boolean | ((node: ReactNode) => ReactNode);
|
|
35
|
+
/** Resolve a {@link StatusSlot} against a built status node. */
|
|
36
|
+
export declare function resolveStatusSlot(slot: StatusSlot | undefined, node: ReactNode): ReactNode;
|
|
37
|
+
//# sourceMappingURL=attachment.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"attachment.d.ts","sourceRoot":"","sources":["../../src/lib/attachment.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AACvD,OAAO,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAC;AAExD;;;GAGG;AACH,MAAM,MAAM,eAAe,GAAG,WAAW,CACvC,cAAc,CAAC,OAAO,UAAU,CAAC,CAAC,OAAO,CAAC,CAC3C,CAAC;AAEF,MAAM,MAAM,cAAc,GAAG,WAAW,CACtC,cAAc,CAAC,OAAO,UAAU,CAAC,CAAC,MAAM,CAAC,CAC1C,CAAC;AAEF,MAAM,MAAM,qBAAqB,GAAG,WAAW,CAC7C,cAAc,CAAC,OAAO,UAAU,CAAC,CAAC,aAAa,CAAC,CACjD,CAAC;AAEF,gEAAgE;AAChE,MAAM,MAAM,qBAAqB,GAAG;IAClC,IAAI,CAAC,EAAE,cAAc,CAAC;IACtB,WAAW,CAAC,EAAE,qBAAqB,CAAC;CACrC,CAAC;AAEF;;;GAGG;AACH,MAAM,MAAM,uBAAuB,GAAG;IACpC,mEAAmE;IACnE,cAAc,CAAC,EAAE,cAAc,CAAC;IAChC,oDAAoD;IACpD,qBAAqB,CAAC,EAAE,qBAAqB,CAAC;CAC/C,CAAC;AAEF,mFAAmF;AACnF,eAAO,MAAM,kCAAkC,gEACgB,CAAC;AAEhE;;;;;;GAMG;AACH,MAAM,MAAM,UAAU,GAAG,OAAO,GAAG,CAAC,CAAC,IAAI,EAAE,SAAS,KAAK,SAAS,CAAC,CAAC;AAEpE,gEAAgE;AAChE,wBAAgB,iBAAiB,CAC/B,IAAI,EAAE,UAAU,YAAO,EACvB,IAAI,EAAE,SAAS,GACd,SAAS,CAIX"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/** Resolve a curated extension key for icon styling (or `null` if unknown). */
|
|
2
|
+
export declare function resolveFileTypeExtension(fileName: string, mimeType?: string | null): string | null;
|
|
3
|
+
export type FileTypeGlyphProps = {
|
|
4
|
+
fileName: string;
|
|
5
|
+
fileType?: string | null;
|
|
6
|
+
className?: string;
|
|
7
|
+
};
|
|
8
|
+
/**
|
|
9
|
+
* Colored file glyph for attachment media (no image preview).
|
|
10
|
+
* Uses `react-file-icon` + a lean curated extension map.
|
|
11
|
+
*/
|
|
12
|
+
export declare function FileTypeGlyph({ fileName, fileType, className, }: FileTypeGlyphProps): import("react").JSX.Element;
|
|
13
|
+
//# sourceMappingURL=file-type-icon.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"file-type-icon.d.ts","sourceRoot":"","sources":["../../src/lib/file-type-icon.tsx"],"names":[],"mappings":"AAmJA,+EAA+E;AAC/E,wBAAgB,wBAAwB,CACtC,QAAQ,EAAE,MAAM,EAChB,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,GACvB,MAAM,GAAG,IAAI,CAYf;AAYD,MAAM,MAAM,kBAAkB,GAAG;IAC/B,QAAQ,EAAE,MAAM,CAAC;IACjB,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB,CAAC;AAEF;;;GAGG;AACH,wBAAgB,aAAa,CAAC,EAC5B,QAAQ,EACR,QAAQ,EACR,SAAS,GACV,EAAE,kBAAkB,+BAkBpB"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dimah-s3/ui",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.7.0",
|
|
4
4
|
"description": "Pre-built React UI components for S3 file upload, download, and delete",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"s3",
|
|
@@ -22,22 +22,27 @@
|
|
|
22
22
|
"bugs": {
|
|
23
23
|
"url": "https://github.com/dimah-kz/dimah-s3/issues"
|
|
24
24
|
},
|
|
25
|
-
"sideEffects":
|
|
25
|
+
"sideEffects": [
|
|
26
|
+
"*.css"
|
|
27
|
+
],
|
|
26
28
|
"type": "module",
|
|
27
29
|
"exports": {
|
|
28
30
|
".": {
|
|
29
31
|
"types": "./dist/index.d.ts",
|
|
30
32
|
"default": "./dist/index.js"
|
|
31
33
|
},
|
|
32
|
-
"./styles.css": "./styles.css"
|
|
34
|
+
"./styles.css": "./styles.css",
|
|
35
|
+
"./css/shadcn.css": "./css/shadcn.css"
|
|
33
36
|
},
|
|
34
37
|
"files": [
|
|
35
38
|
"dist",
|
|
36
|
-
"styles.css"
|
|
39
|
+
"styles.css",
|
|
40
|
+
"css"
|
|
37
41
|
],
|
|
38
42
|
"dependencies": {
|
|
39
|
-
"
|
|
40
|
-
"@dimah-s3/
|
|
43
|
+
"react-file-icon": "^1.6.0",
|
|
44
|
+
"@dimah-s3/core": "0.7.0",
|
|
45
|
+
"@dimah-s3/react": "0.7.0"
|
|
41
46
|
},
|
|
42
47
|
"peerDependencies": {
|
|
43
48
|
"@base-ui/react": ">=1.0.0",
|
|
@@ -50,18 +55,20 @@
|
|
|
50
55
|
"devDependencies": {
|
|
51
56
|
"@base-ui/react": "^1.7.0",
|
|
52
57
|
"@fuma-translate/react": "^1.0.2",
|
|
53
|
-
"@types/node": "^26.
|
|
58
|
+
"@types/node": "^26.2.0",
|
|
54
59
|
"@types/react": "^19.2.18",
|
|
60
|
+
"@types/react-file-icon": "^1.0.5",
|
|
55
61
|
"class-variance-authority": "^0.7.1",
|
|
56
62
|
"cnfast": "^0.1.0",
|
|
57
|
-
"eslint": "^10.8.
|
|
58
|
-
"lucide-react": "^1.
|
|
63
|
+
"eslint": "^10.8.1",
|
|
64
|
+
"lucide-react": "^1.31.0",
|
|
59
65
|
"react": "^19.2.8",
|
|
66
|
+
"shadcn": "^4.16.2",
|
|
60
67
|
"tsc-alias": "^1.9.1",
|
|
61
68
|
"tsup": "^8.5.1",
|
|
62
69
|
"typescript": "7.0.2",
|
|
63
|
-
"@workspace/
|
|
64
|
-
"@workspace/
|
|
70
|
+
"@workspace/typescript-config": "0.0.1",
|
|
71
|
+
"@workspace/eslint-config": "0.0.1"
|
|
65
72
|
},
|
|
66
73
|
"publishConfig": {
|
|
67
74
|
"access": "public"
|
|
@@ -69,6 +76,7 @@
|
|
|
69
76
|
"scripts": {
|
|
70
77
|
"build": "pnpm run sync-registry && tsup --config tsup.config.ts && tsc --emitDeclarationOnly && tsc-alias",
|
|
71
78
|
"sync-registry": "node ./scripts/enforce-src-alias-imports.mjs && node ./scripts/sync-registry.mjs",
|
|
79
|
+
"sync:shadcn": "node scripts/sync-shadcn.mjs",
|
|
72
80
|
"normalize-imports": "node ./scripts/enforce-src-alias-imports.mjs",
|
|
73
81
|
"lint": "eslint",
|
|
74
82
|
"check-types": "tsc --noEmit"
|
package/styles.css
CHANGED
|
@@ -1,7 +1,13 @@
|
|
|
1
|
-
/* @dimah-s3/ui — Tailwind v4 source registration
|
|
1
|
+
/* @dimah-s3/ui — Tailwind v4 source registration + default shadcn color bridge
|
|
2
2
|
Import this file in your CSS so Tailwind can detect the utility classes
|
|
3
|
-
used by this package:
|
|
3
|
+
used by this package and inherit your shadcn theme:
|
|
4
4
|
|
|
5
5
|
@import "@dimah-s3/ui/styles.css";
|
|
6
|
+
|
|
7
|
+
To theme dimah-s3 independently, override `--color-dimah-s3-*` after this
|
|
8
|
+
import (see css/shadcn.css). Stock shadcn primitives (`Button`,
|
|
9
|
+
`Attachment`, …) keep using your app `--primary` / `--card` tokens.
|
|
6
10
|
*/
|
|
11
|
+
@import "./css/shadcn.css";
|
|
12
|
+
|
|
7
13
|
@source "./dist";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"delete-button.d.ts","sourceRoot":"","sources":["../../../src/components/delete/delete-button.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AASvD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AACnD,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,gBAAgB,CAAC;AAG5C,OAAO,EAAE,MAAM,EAAE,MAAM,wBAAwB,CAAC;AAyBhD,sCAAsC;AACtC,MAAM,MAAM,iBAAiB,GAAG,WAAW,GAAG;IAC5C,qEAAqE;IACrE,GAAG,CAAC,EAAE,KAAK,CAAC;IACZ,+BAA+B;IAC/B,SAAS,EAAE,MAAM,CAAC;IAClB,oDAAoD;IACpD,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,oDAAoD;IACpD,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,gDAAgD;IAChD,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,oBAAoB;IACpB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,4DAA4D;IAC5D,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,gDAAgD;IAChD,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,wDAAwD;IACxD,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,6CAA6C;IAC7C,OAAO,CAAC,EAAE,cAAc,CAAC,OAAO,MAAM,CAAC,CAAC,SAAS,CAAC,CAAC;IACnD,sCAAsC;IACtC,IAAI,CAAC,EAAE,cAAc,CAAC,OAAO,MAAM,CAAC,CAAC,MAAM,CAAC,CAAC;IAC7C,mDAAmD;IACnD,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B,CAAC;AAEF,wBAAgB,YAAY,CAAC,EAC3B,GAAG,EACH,SAAS,EACT,QAAQ,EACR,QAAQ,EACR,MAAM,EACN,KAAK,EACL,QAAQ,EACR,SAAS,EACT,QAAQ,EACR,WAAW,EACX,KAAK,EAAE,WAAkB,EACzB,UAAiB,EACjB,YAAY,EACZ,kBAAkB,EAClB,OAAuB,EACvB,IAAgB,EAChB,eAAe,EACf,YAAY,EACZ,aAAa,EACb,SAAS,EACT,OAAO,GACR,EAAE,iBAAiB,+BAyInB"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"download-button.d.ts","sourceRoot":"","sources":["../../../src/components/download/download-button.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAGvD,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,gBAAgB,CAAC;AAG5C,OAAO,EAAE,MAAM,EAAE,MAAM,wBAAwB,CAAC;AAGhD,wCAAwC;AACxC,MAAM,MAAM,mBAAmB,GAAG;IAChC,qEAAqE;IACrE,GAAG,CAAC,EAAE,KAAK,CAAC;IACZ,iCAAiC;IACjC,SAAS,EAAE,MAAM,CAAC;IAClB,iDAAiD;IACjD,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,oBAAoB;IACpB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,4DAA4D;IAC5D,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,uDAAuD;IACvD,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,wDAAwD;IACxD,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,yCAAyC;IACzC,OAAO,CAAC,EAAE,cAAc,CAAC,OAAO,MAAM,CAAC,CAAC,SAAS,CAAC,CAAC;IACnD,sCAAsC;IACtC,IAAI,CAAC,EAAE,cAAc,CAAC,OAAO,MAAM,CAAC,CAAC,MAAM,CAAC,CAAC;IAC7C,mDAAmD;IACnD,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B,CAAC;AAEF,wBAAgB,cAAc,CAAC,EAC7B,GAAG,EACH,SAAS,EACT,QAAQ,EACR,KAAK,EACL,QAAQ,EACR,SAAS,EACT,QAAQ,EACR,KAAK,EAAE,WAAkB,EACzB,UAAiB,EACjB,OAAmB,EACnB,IAAgB,EAChB,eAAe,GAChB,EAAE,mBAAmB,+BAqDrB"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"progress-download-button.d.ts","sourceRoot":"","sources":["../../../src/components/download/progress-download-button.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAIvD,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,iBAAiB,CAAC;AAC1D,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,gBAAgB,CAAC;AAG5C,OAAO,EAAE,MAAM,EAAE,MAAM,wBAAwB,CAAC;AAQhD,gDAAgD;AAChD,MAAM,MAAM,2BAA2B,GAAG,kBAAkB,GAAG;IAC7D,qEAAqE;IACrE,GAAG,CAAC,EAAE,KAAK,CAAC;IACZ,iCAAiC;IACjC,SAAS,EAAE,MAAM,CAAC;IAClB,iDAAiD;IACjD,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,4DAA4D;IAC5D,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,gDAAgD;IAChD,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,oBAAoB;IACpB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,4EAA4E;IAC5E,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,4EAA4E;IAC5E,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,iDAAiD;IACjD,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,wDAAwD;IACxD,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,yCAAyC;IACzC,OAAO,CAAC,EAAE,cAAc,CAAC,OAAO,MAAM,CAAC,CAAC,SAAS,CAAC,CAAC;IACnD,sCAAsC;IACtC,IAAI,CAAC,EAAE,cAAc,CAAC,OAAO,MAAM,CAAC,CAAC,MAAM,CAAC,CAAC;IAC7C,mDAAmD;IACnD,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B,CAAC;AAEF,wBAAgB,sBAAsB,CAAC,EACrC,GAAG,EACH,SAAS,EACT,QAAQ,EACR,QAAQ,EACR,MAAM,EACN,KAAK,EACL,QAAQ,EACR,SAAS,EACT,aAAa,EACb,QAAQ,EACR,WAAW,EACX,iBAAiB,EACjB,KAAK,EAAE,WAAkB,EACzB,UAAiB,EACjB,OAAmB,EACnB,IAAgB,EAChB,eAAe,EACf,cAAc,EACd,eAAe,EACf,UAAU,EACV,SAAS,EACT,OAAO,EACP,QAAQ,GACT,EAAE,2BAA2B,+BAoH7B"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"circle-progress.d.ts","sourceRoot":"","sources":["../../../src/components/ui/circle-progress.tsx"],"names":[],"mappings":"AAEA,wBAAgB,cAAc,CAAC,EAC7B,OAAO,EACP,IAAS,EACT,WAAiB,GAClB,EAAE;IACD,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,+BA6BA"}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import type { UploadProgress, MultiUploadFileState } from "@dimah-s3/react";
|
|
2
|
-
export declare function MultiUploadStatus({ phase, files, totalProgress, error, onCancel, }: {
|
|
3
|
-
phase: string;
|
|
4
|
-
files: MultiUploadFileState[];
|
|
5
|
-
totalProgress: UploadProgress;
|
|
6
|
-
error: string | null;
|
|
7
|
-
onCancel?: () => void;
|
|
8
|
-
}): import("react").JSX.Element | null;
|
|
9
|
-
//# sourceMappingURL=multi-upload-status.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"multi-upload-status.d.ts","sourceRoot":"","sources":["../../../src/components/upload/multi-upload-status.tsx"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,cAAc,EAAE,oBAAoB,EAAE,MAAM,iBAAiB,CAAC;AAS5E,wBAAgB,iBAAiB,CAAC,EAChC,KAAK,EACL,KAAK,EACL,aAAa,EACb,KAAK,EACL,QAAQ,GACT,EAAE;IACD,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,oBAAoB,EAAE,CAAC;IAC9B,aAAa,EAAE,cAAc,CAAC;IAC9B,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAC;CACvB,sCAyFA"}
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import type { ComponentProps, ReactNode } from "react";
|
|
2
|
-
import { type UseUploadControlsOptions, type UseMultiUploadControlsOptions } from "@dimah-s3/react";
|
|
3
|
-
import { Button } from "../../components/ui/button";
|
|
4
|
-
/** Props for {@link UploadButton}. Extends {@link UseUploadControlsOptions} or {@link UseMultiUploadControlsOptions}. */
|
|
5
|
-
export type UploadButtonProps = (UseUploadControlsOptions | UseMultiUploadControlsOptions) & {
|
|
6
|
-
className?: string;
|
|
7
|
-
/** Button label. */
|
|
8
|
-
label?: string;
|
|
9
|
-
/** Custom button content. Replaces default icon + label. */
|
|
10
|
-
children?: ReactNode;
|
|
11
|
-
disabled?: boolean;
|
|
12
|
-
tooltipText?: string;
|
|
13
|
-
/** Show toasts during upload. @default true */
|
|
14
|
-
toast?: boolean;
|
|
15
|
-
/** Show inline status below the button. @default true */
|
|
16
|
-
showStatus?: boolean;
|
|
17
|
-
/**
|
|
18
|
-
* Force multi-file mode. When omitted, multi mode is inferred from
|
|
19
|
-
* `maxFiles > 1`.
|
|
20
|
-
*/
|
|
21
|
-
multiple?: boolean;
|
|
22
|
-
/** Button variant. @default "default" */
|
|
23
|
-
variant?: ComponentProps<typeof Button>["variant"];
|
|
24
|
-
/** Button size. @default "default" */
|
|
25
|
-
size?: ComponentProps<typeof Button>["size"];
|
|
26
|
-
/** Extra classes on the trigger button element. */
|
|
27
|
-
buttonClassName?: string;
|
|
28
|
-
};
|
|
29
|
-
export declare function UploadButton({ className, label, children, disabled, tooltipText, toast: enableToast, showStatus, multiple, variant, size, buttonClassName, ...options }: UploadButtonProps): import("react").JSX.Element;
|
|
30
|
-
//# sourceMappingURL=upload-button.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"upload-button.d.ts","sourceRoot":"","sources":["../../../src/components/upload/upload-button.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAGvD,OAAO,EAGL,KAAK,wBAAwB,EAC7B,KAAK,6BAA6B,EAGnC,MAAM,iBAAiB,CAAC;AAEzB,OAAO,EAAE,MAAM,EAAE,MAAM,wBAAwB,CAAC;AAYhD,yHAAyH;AACzH,MAAM,MAAM,iBAAiB,GAAG,CAC9B,wBAAwB,GAAG,6BAA6B,CACzD,GAAG;IACF,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,oBAAoB;IACpB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,4DAA4D;IAC5D,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,+CAA+C;IAC/C,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,yDAAyD;IACzD,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB;;;OAGG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,yCAAyC;IACzC,OAAO,CAAC,EAAE,cAAc,CAAC,OAAO,MAAM,CAAC,CAAC,SAAS,CAAC,CAAC;IACnD,sCAAsC;IACtC,IAAI,CAAC,EAAE,cAAc,CAAC,OAAO,MAAM,CAAC,CAAC,MAAM,CAAC,CAAC;IAC7C,mDAAmD;IACnD,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B,CAAC;AAEF,wBAAgB,YAAY,CAAC,EAC3B,SAAS,EACT,KAAK,EACL,QAAQ,EACR,QAAQ,EACR,WAAW,EACX,KAAK,EAAE,WAAkB,EACzB,UAAiB,EACjB,QAAQ,EACR,OAAmB,EACnB,IAAgB,EAChB,eAAe,EACf,GAAG,OAAO,EACX,EAAE,iBAAiB,+BAyGnB"}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { type ReactNode } from "react";
|
|
2
|
-
import { type UseUploadControlsOptions, type UseMultiUploadControlsOptions } from "@dimah-s3/react";
|
|
3
|
-
/** Props for {@link UploadDropzone}. Extends {@link UseUploadControlsOptions} or {@link UseMultiUploadControlsOptions}. */
|
|
4
|
-
export type UploadDropzoneProps = (UseUploadControlsOptions | UseMultiUploadControlsOptions) & {
|
|
5
|
-
className?: string;
|
|
6
|
-
/** Dropzone label. */
|
|
7
|
-
label?: string;
|
|
8
|
-
/** Custom dropzone content. Replaces built-in icon/text/status block. */
|
|
9
|
-
children?: ReactNode;
|
|
10
|
-
disabled?: boolean;
|
|
11
|
-
/** Show toasts during upload. @default true */
|
|
12
|
-
toast?: boolean;
|
|
13
|
-
/** Show inline status inside the dropzone. @default true */
|
|
14
|
-
showStatus?: boolean;
|
|
15
|
-
/**
|
|
16
|
-
* Force multi-file mode. When omitted, multi mode is inferred from
|
|
17
|
-
* `maxFiles > 1`.
|
|
18
|
-
*/
|
|
19
|
-
multiple?: boolean;
|
|
20
|
-
};
|
|
21
|
-
export declare function UploadDropzone({ className, label, children, disabled, toast: enableToast, showStatus, multiple, ...options }: UploadDropzoneProps): import("react").JSX.Element;
|
|
22
|
-
//# sourceMappingURL=upload-dropzone.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"upload-dropzone.d.ts","sourceRoot":"","sources":["../../../src/components/upload/upload-dropzone.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAgC,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAGrE,OAAO,EAIL,KAAK,wBAAwB,EAC7B,KAAK,6BAA6B,EAGnC,MAAM,iBAAiB,CAAC;AASzB,2HAA2H;AAC3H,MAAM,MAAM,mBAAmB,GAAG,CAChC,wBAAwB,GAAG,6BAA6B,CACzD,GAAG;IACF,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,sBAAsB;IACtB,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,yEAAyE;IACzE,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,+CAA+C;IAC/C,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,4DAA4D;IAC5D,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB;;;OAGG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB,CAAC;AAEF,wBAAgB,cAAc,CAAC,EAC7B,SAAS,EACT,KAAK,EACL,QAAQ,EACR,QAAQ,EACR,KAAK,EAAE,WAAkB,EACzB,UAAiB,EACjB,QAAQ,EACR,GAAG,OAAO,EACX,EAAE,mBAAmB,+BA+KrB"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"upload-status-block.d.ts","sourceRoot":"","sources":["../../../src/components/upload/upload-status-block.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EACV,WAAW,EACX,cAAc,EACd,oBAAoB,EACpB,gBAAgB,EACjB,MAAM,iBAAiB,CAAC;AAIzB,MAAM,MAAM,sBAAsB,GAC9B;IACE,IAAI,EAAE,QAAQ,CAAC;IACf,KAAK,EAAE,WAAW,CAAC;IACnB,QAAQ,EAAE,cAAc,CAAC;IACzB,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,QAAQ,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI,CAAC;IAChD,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAC;IACtB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;CACtB,GACD;IACE,IAAI,EAAE,OAAO,CAAC;IACd,KAAK,EAAE,gBAAgB,CAAC;IACxB,KAAK,EAAE,oBAAoB,EAAE,CAAC;IAC9B,aAAa,EAAE,cAAc,CAAC;IAC9B,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAC;IACtB,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;CACtB,CAAC;AAEN,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,sBAAsB,+BAoC9D"}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import type { UploadPhase, UploadProgress } from "@dimah-s3/react";
|
|
2
|
-
export declare function UploadStatus({ phase, progress, error, fileInfo, onCancel, onPause, }: {
|
|
3
|
-
phase: UploadPhase;
|
|
4
|
-
progress: UploadProgress;
|
|
5
|
-
error: string | null;
|
|
6
|
-
fileInfo: {
|
|
7
|
-
name: string;
|
|
8
|
-
size: number;
|
|
9
|
-
} | null;
|
|
10
|
-
onCancel?: () => void;
|
|
11
|
-
/** When set (typically with an `uploadStore`), shows a pause control. */
|
|
12
|
-
onPause?: () => void;
|
|
13
|
-
}): import("react").JSX.Element | null;
|
|
14
|
-
//# sourceMappingURL=upload-status.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"upload-status.d.ts","sourceRoot":"","sources":["../../../src/components/upload/upload-status.tsx"],"names":[],"mappings":"AAWA,OAAO,KAAK,EAAE,WAAW,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAInE,wBAAgB,YAAY,CAAC,EAC3B,KAAK,EACL,QAAQ,EACR,KAAK,EACL,QAAQ,EACR,QAAQ,EACR,OAAO,GACR,EAAE;IACD,KAAK,EAAE,WAAW,CAAC;IACnB,QAAQ,EAAE,cAAc,CAAC;IACzB,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,QAAQ,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAE,GAAG,IAAI,CAAC;IAChD,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAC;IACtB,yEAAyE;IACzE,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;CACtB,sCAyFA"}
|