@pibit.ai/cure-design-system 0.6.29 → 0.6.31
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/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +359 -347
- package/dist/patterns/file-upload/file-upload-filename.d.ts +31 -0
- package/dist/patterns/file-upload/file-upload-filename.d.ts.map +1 -0
- package/dist/patterns/file-upload/file-upload-filename.js +46 -0
- package/dist/patterns/file-upload/file-upload.d.ts +109 -0
- package/dist/patterns/file-upload/file-upload.d.ts.map +1 -0
- package/dist/patterns/file-upload/file-upload.js +418 -0
- package/dist/patterns/file-upload/index.d.ts +3 -0
- package/dist/patterns/file-upload/index.d.ts.map +1 -0
- package/dist/primitives/select/SearchInput.d.ts.map +1 -1
- package/dist/primitives/select/SearchInput.js +114 -97
- package/dist/primitives/select/searchable-select.d.ts.map +1 -1
- package/dist/primitives/select/searchable-select.js +193 -185
- package/dist/styles/components.css +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { CSSProperties } from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* Split a filename for the editable upload list item: base field + fixed extension suffix.
|
|
4
|
+
* Names like `.pdf` (after clearing `report.pdf`) map to an empty base and `.pdf` as extension.
|
|
5
|
+
*/
|
|
6
|
+
export declare function splitEditableUploadFileName(filename: string): {
|
|
7
|
+
base: string;
|
|
8
|
+
extension: string;
|
|
9
|
+
};
|
|
10
|
+
/**
|
|
11
|
+
* Whether the filename has a non-empty base (stem), consistent with {@link splitEditableUploadFileName}.
|
|
12
|
+
*/
|
|
13
|
+
export declare function hasNonEmptyUploadFileBaseName(filename: string): boolean;
|
|
14
|
+
/**
|
|
15
|
+
* Fills an empty base name with `id`, using the same base/extension rules as
|
|
16
|
+
* {@link splitEditableUploadFileName}; a name that already has a base comes back unchanged.
|
|
17
|
+
* Leading-dot names like `.pdf` become `{id}.pdf` (not `.pdf_{id}`).
|
|
18
|
+
*/
|
|
19
|
+
export declare function uniquifyUploadFileName(filename: string, id: string): string;
|
|
20
|
+
/**
|
|
21
|
+
* Before submit, disambiguate duplicate display names in order: same trimmed base+extension
|
|
22
|
+
* (per {@link splitEditableUploadFileName}) gets ` (1)`, ` (2)`, … inserted before the extension.
|
|
23
|
+
*/
|
|
24
|
+
export declare function uniquifyUploadFilesForSubmit(uploadedFiles: File[]): File[];
|
|
25
|
+
/**
|
|
26
|
+
* Right padding for a filename input whose fixed extension is drawn as a `trailingAction`.
|
|
27
|
+
* The design-system input only reserves room for an icon there, so a long base name would
|
|
28
|
+
* run underneath the extension; this reserves the extension's width plus the action's inset.
|
|
29
|
+
*/
|
|
30
|
+
export declare function extensionTrailingPadding(extension: string): CSSProperties | undefined;
|
|
31
|
+
//# sourceMappingURL=file-upload-filename.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"file-upload-filename.d.ts","sourceRoot":"","sources":["../../../src/patterns/file-upload/file-upload-filename.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAE3C;;;GAGG;AACH,wBAAgB,2BAA2B,CAAC,QAAQ,EAAE,MAAM,GAAG;IAAE,IAAI,EAAE,MAAM,CAAC;IAAC,SAAS,EAAE,MAAM,CAAA;CAAE,CAcjG;AAED;;GAEG;AACH,wBAAgB,6BAA6B,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAQvE;AAED;;;;GAIG;AACH,wBAAgB,sBAAsB,CAAC,QAAQ,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,GAAG,MAAM,CAO3E;AAED;;;GAGG;AACH,wBAAgB,4BAA4B,CAAC,aAAa,EAAE,IAAI,EAAE,GAAG,IAAI,EAAE,CAqB1E;AAED;;;;GAIG;AACH,wBAAgB,wBAAwB,CAAC,SAAS,EAAE,MAAM,GAAG,aAAa,GAAG,SAAS,CAGrF"}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
function c(i) {
|
|
2
|
+
const t = i, e = t.lastIndexOf(".");
|
|
3
|
+
if (e < 0) return { base: t, extension: "" };
|
|
4
|
+
if (e === 0) {
|
|
5
|
+
const n = t.slice(1);
|
|
6
|
+
return n.length > 0 && !n.includes(".") && /^[a-z0-9]{1,5}$/i.test(n) ? { base: "", extension: t } : { base: t, extension: "" };
|
|
7
|
+
}
|
|
8
|
+
return { base: t.slice(0, e), extension: t.slice(e) };
|
|
9
|
+
}
|
|
10
|
+
function m(i) {
|
|
11
|
+
const t = i.trim();
|
|
12
|
+
if (!t) return !1;
|
|
13
|
+
const { base: e, extension: n } = c(t);
|
|
14
|
+
return n ? e.trim().length > 0 : !0;
|
|
15
|
+
}
|
|
16
|
+
function f(i, t) {
|
|
17
|
+
const { base: e, extension: n } = c(i);
|
|
18
|
+
return n ? e.trim() ? `${e}${n}` : `${t}${n}` : e.trim() || t;
|
|
19
|
+
}
|
|
20
|
+
function d(i) {
|
|
21
|
+
const t = /* @__PURE__ */ new Map();
|
|
22
|
+
return i.map((e) => {
|
|
23
|
+
const n = e.name.trim(), { base: r, extension: s } = c(n), u = `${r}\0${s}`, o = t.get(u) ?? 0;
|
|
24
|
+
t.set(u, o + 1);
|
|
25
|
+
let a = n;
|
|
26
|
+
if (o > 0) {
|
|
27
|
+
const l = ` (${o})`;
|
|
28
|
+
a = s ? `${r}${l}${s}` : `${r}${l}`;
|
|
29
|
+
}
|
|
30
|
+
return a === e.name ? e : new File([e], a, {
|
|
31
|
+
type: e.type,
|
|
32
|
+
lastModified: e.lastModified
|
|
33
|
+
});
|
|
34
|
+
});
|
|
35
|
+
}
|
|
36
|
+
function $(i) {
|
|
37
|
+
if (i)
|
|
38
|
+
return { paddingRight: `calc(${i.length}ch + 1.25rem)` };
|
|
39
|
+
}
|
|
40
|
+
export {
|
|
41
|
+
$ as extensionTrailingPadding,
|
|
42
|
+
m as hasNonEmptyUploadFileBaseName,
|
|
43
|
+
c as splitEditableUploadFileName,
|
|
44
|
+
f as uniquifyUploadFileName,
|
|
45
|
+
d as uniquifyUploadFilesForSubmit
|
|
46
|
+
};
|
|
@@ -0,0 +1,109 @@
|
|
|
1
|
+
import { ComponentPropsWithRef, ReactNode } from 'react';
|
|
2
|
+
import { FileIconProps } from '../../primitives/file-icon';
|
|
3
|
+
/**
|
|
4
|
+
* Returns a human-readable file size.
|
|
5
|
+
* @param bytes - The size of the file in bytes.
|
|
6
|
+
* @returns A string representing the file size in a human-readable format (rounded down; "0 KB" for 0 or invalid input).
|
|
7
|
+
*/
|
|
8
|
+
export declare const getReadableFileSize: (bytes: number) => string;
|
|
9
|
+
export interface FileUploadDropZoneProps {
|
|
10
|
+
/** The class name of the drop zone. */
|
|
11
|
+
className?: string;
|
|
12
|
+
/**
|
|
13
|
+
* A hint text explaining what files can be dropped.
|
|
14
|
+
*/
|
|
15
|
+
hint?: string;
|
|
16
|
+
/**
|
|
17
|
+
* Disables dropping or uploading files.
|
|
18
|
+
*/
|
|
19
|
+
isDisabled?: boolean;
|
|
20
|
+
/**
|
|
21
|
+
* Specifies the types of files that the server accepts.
|
|
22
|
+
* Examples: "image/*", ".pdf,image/*", "image/*,video/mpeg,application/pdf"
|
|
23
|
+
*/
|
|
24
|
+
accept?: string;
|
|
25
|
+
/**
|
|
26
|
+
* Allows multiple file uploads.
|
|
27
|
+
*/
|
|
28
|
+
allowsMultiple?: boolean;
|
|
29
|
+
/**
|
|
30
|
+
* Maximum file size in bytes.
|
|
31
|
+
*/
|
|
32
|
+
maxSize?: number;
|
|
33
|
+
/**
|
|
34
|
+
* Callback function that is called with the list of dropped files
|
|
35
|
+
* when files are dropped on the drop zone.
|
|
36
|
+
*/
|
|
37
|
+
onDropFiles?: (files: FileList) => void;
|
|
38
|
+
/**
|
|
39
|
+
* Callback function that is called with the list of unaccepted files
|
|
40
|
+
* when files are dropped on the drop zone.
|
|
41
|
+
*/
|
|
42
|
+
onDropUnacceptedFiles?: (files: FileList) => void;
|
|
43
|
+
/**
|
|
44
|
+
* Callback function that is called with the list of files that exceed
|
|
45
|
+
* the size limit when files are dropped on the drop zone.
|
|
46
|
+
*/
|
|
47
|
+
onSizeLimitExceed?: (files: FileList) => void;
|
|
48
|
+
}
|
|
49
|
+
export declare const FileUploadDropZoneCompact: (props: FileUploadDropZoneProps) => import("react/jsx-runtime").JSX.Element;
|
|
50
|
+
export declare const FileUploadDropZone: (props: FileUploadDropZoneProps) => import("react/jsx-runtime").JSX.Element;
|
|
51
|
+
/** Password UI state for protected uploads. Omit / `hidden` keeps existing list-item behavior. */
|
|
52
|
+
export type FileListItemPasswordState = "hidden" | "detecting" | "required" | "verifying" | "verified" | "incorrect" | "unverifiable";
|
|
53
|
+
export interface FileListItemProps {
|
|
54
|
+
/** The name of the file. */
|
|
55
|
+
name: string;
|
|
56
|
+
/** The description of the file. */
|
|
57
|
+
description?: ReactNode;
|
|
58
|
+
/** The size of the file. */
|
|
59
|
+
size: number;
|
|
60
|
+
/** The upload progress of the file. */
|
|
61
|
+
progress: number;
|
|
62
|
+
/** Whether the file failed to upload. */
|
|
63
|
+
failed?: boolean;
|
|
64
|
+
/** The message to display when the file failed to upload. */
|
|
65
|
+
failedMessage?: string;
|
|
66
|
+
/** The type of the file. */
|
|
67
|
+
type?: FileIconProps["type"];
|
|
68
|
+
/** The class name of the file list item. */
|
|
69
|
+
className?: string;
|
|
70
|
+
/** The variant of the file icon. */
|
|
71
|
+
fileIconVariant?: FileIconProps["variant"];
|
|
72
|
+
/** The function to call when the file is deleted. */
|
|
73
|
+
onDelete?: () => void;
|
|
74
|
+
/** The function to call when the file upload is retried. */
|
|
75
|
+
onRetry?: () => void;
|
|
76
|
+
/** Whether to show the progress bar. Defaults to true. */
|
|
77
|
+
showProgressBar?: boolean;
|
|
78
|
+
/** Whether the file is disabled. */
|
|
79
|
+
isDisabled?: boolean;
|
|
80
|
+
/** When true, the file base name is editable in a text field; extension stays fixed as trailing text. @default false */
|
|
81
|
+
isEditable?: boolean;
|
|
82
|
+
/** Called with the next full file name (base + extension) when the base name is edited. */
|
|
83
|
+
onFileNameChange?: (nextFullFileName: string) => void;
|
|
84
|
+
/** When true, shows a lock icon + "Protected" next to the file size. */
|
|
85
|
+
isProtected?: boolean;
|
|
86
|
+
/** When true, shows "Corrupted" in the protected-file slot and failed styling. */
|
|
87
|
+
isCorrupted?: boolean;
|
|
88
|
+
/** Controls password input / verify UI. Defaults to `hidden` (no password UI). */
|
|
89
|
+
passwordState?: FileListItemPasswordState;
|
|
90
|
+
/** Current password field value. */
|
|
91
|
+
passwordValue?: string;
|
|
92
|
+
/** Called when the password field changes. */
|
|
93
|
+
onPasswordChange?: (password: string) => void;
|
|
94
|
+
/** Called when the user clicks Verify. */
|
|
95
|
+
onVerifyPassword?: () => void;
|
|
96
|
+
/** Tooltip shown on the disabled Verify control when state is `unverifiable` and the file is encrypted. */
|
|
97
|
+
unverifiableVerifyTooltip?: string;
|
|
98
|
+
/** Tooltip on the Unverifiable status when detection could not decide encryption. */
|
|
99
|
+
unverifiableStatusTooltip?: string;
|
|
100
|
+
}
|
|
101
|
+
export declare const FileListItemProgressBar: ({ name, description, size, progress, failed, failedMessage, type, fileIconVariant, onDelete, onRetry, className, showProgressBar, isDisabled, isEditable, onFileNameChange, isProtected, isCorrupted, passwordState, passwordValue, onPasswordChange, onVerifyPassword, unverifiableVerifyTooltip, unverifiableStatusTooltip, }: FileListItemProps) => import("react/jsx-runtime").JSX.Element;
|
|
102
|
+
export declare const FileUpload: {
|
|
103
|
+
Root: (props: ComponentPropsWithRef<"div">) => import("react/jsx-runtime").JSX.Element;
|
|
104
|
+
List: (props: ComponentPropsWithRef<"ul">) => import("react/jsx-runtime").JSX.Element;
|
|
105
|
+
DropZone: (props: FileUploadDropZoneProps) => import("react/jsx-runtime").JSX.Element;
|
|
106
|
+
DropZoneCompact: (props: FileUploadDropZoneProps) => import("react/jsx-runtime").JSX.Element;
|
|
107
|
+
ListItemProgressBar: ({ name, description, size, progress, failed, failedMessage, type, fileIconVariant, onDelete, onRetry, className, showProgressBar, isDisabled, isEditable, onFileNameChange, isProtected, isCorrupted, passwordState, passwordValue, onPasswordChange, onVerifyPassword, unverifiableVerifyTooltip, unverifiableStatusTooltip, }: FileListItemProps) => import("react/jsx-runtime").JSX.Element;
|
|
108
|
+
};
|
|
109
|
+
//# sourceMappingURL=file-upload.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"file-upload.d.ts","sourceRoot":"","sources":["../../../src/patterns/file-upload/file-upload.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAgB9D,OAAO,EAAY,KAAK,aAAa,EAAE,MAAM,wBAAwB,CAAC;AActE;;;;GAIG;AACH,eAAO,MAAM,mBAAmB,GAAI,OAAO,MAAM,WAQhD,CAAC;AAIF,MAAM,WAAW,uBAAuB;IACtC,uCAAuC;IACvC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IACd;;OAEG;IACH,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;;OAEG;IACH,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB;;;OAGG;IACH,WAAW,CAAC,EAAE,CAAC,KAAK,EAAE,QAAQ,KAAK,IAAI,CAAC;IACxC;;;OAGG;IACH,qBAAqB,CAAC,EAAE,CAAC,KAAK,EAAE,QAAQ,KAAK,IAAI,CAAC;IAClD;;;OAGG;IACH,iBAAiB,CAAC,EAAE,CAAC,KAAK,EAAE,QAAQ,KAAK,IAAI,CAAC;CAC/C;AA6ID,eAAO,MAAM,yBAAyB,GAAI,OAAO,uBAAuB,4CAkDvE,CAAC;AAEF,eAAO,MAAM,kBAAkB,GAAI,OAAO,uBAAuB,4CAkDhE,CAAC;AAEF,kGAAkG;AAClG,MAAM,MAAM,yBAAyB,GACjC,QAAQ,GACR,WAAW,GACX,UAAU,GACV,WAAW,GACX,UAAU,GACV,WAAW,GACX,cAAc,CAAC;AAEnB,MAAM,WAAW,iBAAiB;IAChC,4BAA4B;IAC5B,IAAI,EAAE,MAAM,CAAC;IACb,mCAAmC;IACnC,WAAW,CAAC,EAAE,SAAS,CAAC;IACxB,4BAA4B;IAC5B,IAAI,EAAE,MAAM,CAAC;IACb,uCAAuC;IACvC,QAAQ,EAAE,MAAM,CAAC;IACjB,yCAAyC;IACzC,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,6DAA6D;IAC7D,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,4BAA4B;IAC5B,IAAI,CAAC,EAAE,aAAa,CAAC,MAAM,CAAC,CAAC;IAC7B,4CAA4C;IAC5C,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,oCAAoC;IACpC,eAAe,CAAC,EAAE,aAAa,CAAC,SAAS,CAAC,CAAC;IAC3C,qDAAqD;IACrD,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAC;IACtB,4DAA4D;IAC5D,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,0DAA0D;IAC1D,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,oCAAoC;IACpC,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,wHAAwH;IACxH,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,2FAA2F;IAC3F,gBAAgB,CAAC,EAAE,CAAC,gBAAgB,EAAE,MAAM,KAAK,IAAI,CAAC;IACtD,wEAAwE;IACxE,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,kFAAkF;IAClF,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,kFAAkF;IAClF,aAAa,CAAC,EAAE,yBAAyB,CAAC;IAC1C,oCAAoC;IACpC,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,8CAA8C;IAC9C,gBAAgB,CAAC,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,IAAI,CAAC;IAC9C,0CAA0C;IAC1C,gBAAgB,CAAC,EAAE,MAAM,IAAI,CAAC;IAC9B,2GAA2G;IAC3G,yBAAyB,CAAC,EAAE,MAAM,CAAC;IACnC,qFAAqF;IACrF,yBAAyB,CAAC,EAAE,MAAM,CAAC;CACpC;AAED,eAAO,MAAM,uBAAuB,GAAI,iUAwBrC,iBAAiB,4CA2QnB,CAAC;AAcF,eAAO,MAAM,UAAU;kBAZQ,qBAAqB,CAAC,KAAK,CAAC;kBAM5B,qBAAqB,CAAC,IAAI,CAAC;sBA1ZhB,uBAAuB;6BApDhB,uBAAuB;2VA2LrE,iBAAiB;CA+RnB,CAAC"}
|
|
@@ -0,0 +1,418 @@
|
|
|
1
|
+
import { jsx as e, jsxs as r, Fragment as B } from "react/jsx-runtime";
|
|
2
|
+
import { useMemo as Q, useState as L, useEffect as S, useId as ee, useRef as re } from "react";
|
|
3
|
+
import { AlertTriangle as te, Lock01 as ie, HelpCircle as ne, CheckCircle as j, XCircle as se, RefreshCcw01 as ae, Trash01 as le, UploadCloud02 as J } from "@untitledui/icons";
|
|
4
|
+
import { cx as F } from "../../utils/cn.js";
|
|
5
|
+
import { splitEditableUploadFileName as oe, extensionTrailingPadding as ce } from "./file-upload-filename.js";
|
|
6
|
+
import { motion as de } from "../../node_modules/framer-motion/dist/es/render/components/motion/proxy.js";
|
|
7
|
+
import { FileIcon as $ } from "@untitledui/file-icons";
|
|
8
|
+
import { Input as V } from "../../primitives/input/input.js";
|
|
9
|
+
import { Tooltip as W } from "../../primitives/tooltip/tooltip.js";
|
|
10
|
+
import { ProgressBar as me } from "../../primitives/progress-bar/progress-bar.js";
|
|
11
|
+
import { ButtonUtility as H } from "../../primitives/button/button-utility.js";
|
|
12
|
+
import { Button as _ } from "../../primitives/button/button.js";
|
|
13
|
+
import { FeaturedIcon as pe } from "../../primitives/featured-icon/featured-icon.js";
|
|
14
|
+
import { AnimatePresence as fe } from "../../node_modules/framer-motion/dist/es/components/AnimatePresence/index.js";
|
|
15
|
+
const ue = (t) => {
|
|
16
|
+
if (!Number.isFinite(t) || t <= 0) return "0 KB";
|
|
17
|
+
const d = ["B", "KB", "MB", "GB", "TB", "PB", "EB", "ZB", "YB"], f = Math.floor(Math.log(t) / Math.log(1024));
|
|
18
|
+
return Math.floor(t / Math.pow(1024, f)) + " " + d[f];
|
|
19
|
+
}, he = "File name cannot be empty", K = ({
|
|
20
|
+
isDisabled: t,
|
|
21
|
+
accept: d,
|
|
22
|
+
allowsMultiple: f = !0,
|
|
23
|
+
maxSize: l,
|
|
24
|
+
onDropFiles: a,
|
|
25
|
+
onDropUnacceptedFiles: y,
|
|
26
|
+
onSizeLimitExceed: m
|
|
27
|
+
}) => {
|
|
28
|
+
const u = ee(), x = re(null), [v, g] = L(!1), [w, o] = L(!1), C = (i) => d ? d.split(",").map((c) => c.trim()).some((c) => {
|
|
29
|
+
var b;
|
|
30
|
+
if (c.startsWith("."))
|
|
31
|
+
return `.${(b = i.name.split(".").pop()) == null ? void 0 : b.toLowerCase()}` === c.toLowerCase();
|
|
32
|
+
if (c.endsWith("/*")) {
|
|
33
|
+
const z = c.split("/")[0];
|
|
34
|
+
return i.type.startsWith(`${z}/`);
|
|
35
|
+
}
|
|
36
|
+
return i.type === c;
|
|
37
|
+
}) : !0, k = (i) => {
|
|
38
|
+
t || (i.preventDefault(), i.stopPropagation(), o(!0));
|
|
39
|
+
}, I = (i) => {
|
|
40
|
+
t || (i.preventDefault(), i.stopPropagation(), o(!1));
|
|
41
|
+
}, h = (i) => {
|
|
42
|
+
g(!1);
|
|
43
|
+
const D = [], c = [], b = [];
|
|
44
|
+
if ((f ? i : i.slice(0, 1)).forEach((s) => {
|
|
45
|
+
if (l && s.size > l) {
|
|
46
|
+
b.push(s);
|
|
47
|
+
return;
|
|
48
|
+
}
|
|
49
|
+
C(s) ? D.push(s) : c.push(s);
|
|
50
|
+
}), b.length > 0 && typeof m == "function") {
|
|
51
|
+
const s = new DataTransfer();
|
|
52
|
+
b.forEach((N) => s.items.add(N)), g(!0), m(s.files);
|
|
53
|
+
}
|
|
54
|
+
if (D.length > 0 && typeof a == "function") {
|
|
55
|
+
const s = new DataTransfer();
|
|
56
|
+
D.forEach((N) => s.items.add(N)), a(s.files);
|
|
57
|
+
}
|
|
58
|
+
if (c.length > 0 && typeof y == "function") {
|
|
59
|
+
const s = new DataTransfer();
|
|
60
|
+
c.forEach((N) => s.items.add(N)), g(!0), y(s.files);
|
|
61
|
+
}
|
|
62
|
+
x.current && (x.current.value = "");
|
|
63
|
+
};
|
|
64
|
+
return {
|
|
65
|
+
id: u,
|
|
66
|
+
inputRef: x,
|
|
67
|
+
isInvalid: v,
|
|
68
|
+
isDraggingOver: w,
|
|
69
|
+
dropTargetProps: {
|
|
70
|
+
onDragOver: k,
|
|
71
|
+
onDragEnter: k,
|
|
72
|
+
onDragLeave: I,
|
|
73
|
+
onDragEnd: I,
|
|
74
|
+
onDrop: (i) => {
|
|
75
|
+
t || (I(i), h(Array.from(i.dataTransfer.files)));
|
|
76
|
+
}
|
|
77
|
+
},
|
|
78
|
+
handleInputFileChange: (i) => {
|
|
79
|
+
h(Array.from(i.target.files || []));
|
|
80
|
+
}
|
|
81
|
+
};
|
|
82
|
+
}, xe = (t) => {
|
|
83
|
+
const { className: d, hint: f, isDisabled: l, accept: a, allowsMultiple: y = !0 } = t, { id: m, inputRef: u, isInvalid: x, isDraggingOver: v, dropTargetProps: g, handleInputFileChange: w } = K(t);
|
|
84
|
+
return /* @__PURE__ */ r(
|
|
85
|
+
"div",
|
|
86
|
+
{
|
|
87
|
+
"data-dropzone-compact": !0,
|
|
88
|
+
...g,
|
|
89
|
+
className: F(
|
|
90
|
+
"relative flex items-center justify-between gap-3 rounded-lg bg-primary px-4 py-3 text-tertiary ring-1 ring-secondary transition duration-100 ease-linear ring-inset cursor-pointer",
|
|
91
|
+
"hover:ring-2 hover:ring-brand",
|
|
92
|
+
v && "ring-2 ring-brand",
|
|
93
|
+
l && "cursor-not-allowed bg-disabled_subtle ring-disabled_subtle text-quaternary hover:ring-1 hover:ring-disabled_subtle",
|
|
94
|
+
d
|
|
95
|
+
),
|
|
96
|
+
children: [
|
|
97
|
+
/* @__PURE__ */ r("div", { className: "flex flex-col gap-0.5", children: [
|
|
98
|
+
/* @__PURE__ */ r("div", { className: "flex items-center gap-1", children: [
|
|
99
|
+
/* @__PURE__ */ e(
|
|
100
|
+
"input",
|
|
101
|
+
{
|
|
102
|
+
ref: u,
|
|
103
|
+
id: m,
|
|
104
|
+
type: "file",
|
|
105
|
+
className: "peer sr-only",
|
|
106
|
+
disabled: l,
|
|
107
|
+
accept: a,
|
|
108
|
+
multiple: y,
|
|
109
|
+
onChange: w
|
|
110
|
+
}
|
|
111
|
+
),
|
|
112
|
+
/* @__PURE__ */ e("label", { htmlFor: m, className: "flex cursor-pointer", children: /* @__PURE__ */ e(
|
|
113
|
+
_,
|
|
114
|
+
{
|
|
115
|
+
color: "link-color",
|
|
116
|
+
size: "sm",
|
|
117
|
+
isDisabled: l,
|
|
118
|
+
onClick: () => {
|
|
119
|
+
var o;
|
|
120
|
+
return (o = u.current) == null ? void 0 : o.click();
|
|
121
|
+
},
|
|
122
|
+
className: "p-0 h-auto",
|
|
123
|
+
children: "Click to upload"
|
|
124
|
+
}
|
|
125
|
+
) }),
|
|
126
|
+
/* @__PURE__ */ e("span", { className: "text-sm", children: "or drag and drop" })
|
|
127
|
+
] }),
|
|
128
|
+
/* @__PURE__ */ e("p", { className: F("text-xs transition duration-100 ease-linear", x && "text-error-primary"), children: f || "SVG, PNG, JPG or GIF (max. 800x400px)" })
|
|
129
|
+
] }),
|
|
130
|
+
/* @__PURE__ */ e(J, { className: "size-5 shrink-0 text-quaternary" })
|
|
131
|
+
]
|
|
132
|
+
}
|
|
133
|
+
);
|
|
134
|
+
}, ge = (t) => {
|
|
135
|
+
const { className: d, hint: f, isDisabled: l, accept: a, allowsMultiple: y = !0 } = t, { id: m, inputRef: u, isInvalid: x, isDraggingOver: v, dropTargetProps: g, handleInputFileChange: w } = K(t);
|
|
136
|
+
return /* @__PURE__ */ r(
|
|
137
|
+
"div",
|
|
138
|
+
{
|
|
139
|
+
"data-dropzone": !0,
|
|
140
|
+
...g,
|
|
141
|
+
className: F(
|
|
142
|
+
"relative flex flex-col items-center gap-3 rounded-xl bg-primary px-6 py-4 text-tertiary ring-1 ring-secondary transition duration-100 ease-linear ring-inset",
|
|
143
|
+
v && "ring-2 ring-brand",
|
|
144
|
+
l && "cursor-not-allowed bg-disabled_subtle ring-disabled_subtle",
|
|
145
|
+
d
|
|
146
|
+
),
|
|
147
|
+
children: [
|
|
148
|
+
/* @__PURE__ */ e(pe, { color: "gray", theme: "modern", size: "md", children: /* @__PURE__ */ e(J, { className: "size-5" }) }),
|
|
149
|
+
/* @__PURE__ */ r("div", { className: "flex flex-col gap-1 text-center", children: [
|
|
150
|
+
/* @__PURE__ */ r("div", { className: "flex justify-center gap-1 text-center", children: [
|
|
151
|
+
/* @__PURE__ */ e(
|
|
152
|
+
"input",
|
|
153
|
+
{
|
|
154
|
+
ref: u,
|
|
155
|
+
id: m,
|
|
156
|
+
type: "file",
|
|
157
|
+
className: "peer sr-only",
|
|
158
|
+
disabled: l,
|
|
159
|
+
accept: a,
|
|
160
|
+
multiple: y,
|
|
161
|
+
onChange: w
|
|
162
|
+
}
|
|
163
|
+
),
|
|
164
|
+
/* @__PURE__ */ e("label", { htmlFor: m, className: "flex cursor-pointer", children: /* @__PURE__ */ r(
|
|
165
|
+
_,
|
|
166
|
+
{
|
|
167
|
+
className: "text-brand-tertiary font-semibold text-sm hover:text-brand-tertiary",
|
|
168
|
+
size: "md",
|
|
169
|
+
color: "link-color",
|
|
170
|
+
isDisabled: l,
|
|
171
|
+
onClick: () => {
|
|
172
|
+
var o;
|
|
173
|
+
return (o = u.current) == null ? void 0 : o.click();
|
|
174
|
+
},
|
|
175
|
+
children: [
|
|
176
|
+
"Click to upload ",
|
|
177
|
+
/* @__PURE__ */ e("span", { className: "md:hidden", children: "and attach files" })
|
|
178
|
+
]
|
|
179
|
+
}
|
|
180
|
+
) }),
|
|
181
|
+
/* @__PURE__ */ e("span", { className: "text-sm max-md:hidden", children: "or drag and drop" })
|
|
182
|
+
] }),
|
|
183
|
+
/* @__PURE__ */ e("p", { className: F("text-xs transition duration-100 ease-linear", x && "text-error-primary"), children: f || "SVG, PNG, JPG or GIF (max. 800x400px)" })
|
|
184
|
+
] })
|
|
185
|
+
]
|
|
186
|
+
}
|
|
187
|
+
);
|
|
188
|
+
}, Ne = ({
|
|
189
|
+
name: t,
|
|
190
|
+
description: d = null,
|
|
191
|
+
size: f,
|
|
192
|
+
progress: l,
|
|
193
|
+
failed: a,
|
|
194
|
+
failedMessage: y,
|
|
195
|
+
type: m,
|
|
196
|
+
fileIconVariant: u,
|
|
197
|
+
onDelete: x,
|
|
198
|
+
onRetry: v,
|
|
199
|
+
className: g,
|
|
200
|
+
showProgressBar: w = !0,
|
|
201
|
+
isDisabled: o = !1,
|
|
202
|
+
isEditable: C = !1,
|
|
203
|
+
onFileNameChange: k,
|
|
204
|
+
isProtected: I = !1,
|
|
205
|
+
isCorrupted: h = !1,
|
|
206
|
+
passwordState: n = "hidden",
|
|
207
|
+
passwordValue: M = "",
|
|
208
|
+
onPasswordChange: i,
|
|
209
|
+
onVerifyPassword: D,
|
|
210
|
+
unverifiableVerifyTooltip: c = "Password cannot be verified in the browser for this file type",
|
|
211
|
+
unverifiableStatusTooltip: b = "Could not determine whether this file is password protected"
|
|
212
|
+
}) => {
|
|
213
|
+
const z = l === 100, s = !z && !a, N = n === "verifying", Y = n === "unverifiable" && !I && !h, X = n !== "hidden" && n !== "detecting" && !h && !(n === "unverifiable" && !I), U = z && !a && !(n === "detecting" || n === "required" || n === "incorrect" || n === "verifying"), A = !!a || o || N, { base: R, extension: T } = Q(() => oe(t), [t]), [P, E] = L(R), O = C && P.trim().length === 0;
|
|
214
|
+
S(() => {
|
|
215
|
+
E(R);
|
|
216
|
+
}, [R]);
|
|
217
|
+
const G = (p) => {
|
|
218
|
+
const q = `${p.trim()}${T}`;
|
|
219
|
+
q !== t && (k == null || k(q));
|
|
220
|
+
}, Z = /* @__PURE__ */ e(
|
|
221
|
+
_,
|
|
222
|
+
{
|
|
223
|
+
color: "secondary",
|
|
224
|
+
size: "sm",
|
|
225
|
+
onClick: D,
|
|
226
|
+
isDisabled: A || n === "unverifiable" || n === "verified" || !M,
|
|
227
|
+
isLoading: n === "verifying",
|
|
228
|
+
className: "shrink-0",
|
|
229
|
+
children: "Verify"
|
|
230
|
+
}
|
|
231
|
+
);
|
|
232
|
+
return /* @__PURE__ */ e(
|
|
233
|
+
de.li,
|
|
234
|
+
{
|
|
235
|
+
layout: "position",
|
|
236
|
+
className: F(
|
|
237
|
+
"relative flex gap-3 rounded-xl bg-primary p-4 ring-1 ring-secondary transition-shadow duration-100 ease-linear ring-inset",
|
|
238
|
+
a && "ring-2 ring-error",
|
|
239
|
+
g
|
|
240
|
+
),
|
|
241
|
+
children: /* @__PURE__ */ r("div", { className: "flex flex-col gap-4 w-full", children: [
|
|
242
|
+
/* @__PURE__ */ r("div", { className: "flex gap-3", children: [
|
|
243
|
+
/* @__PURE__ */ e(
|
|
244
|
+
$,
|
|
245
|
+
{
|
|
246
|
+
className: "size-10 shrink-0 dark:hidden",
|
|
247
|
+
type: m ?? "empty",
|
|
248
|
+
theme: "light",
|
|
249
|
+
variant: u ?? "default"
|
|
250
|
+
}
|
|
251
|
+
),
|
|
252
|
+
/* @__PURE__ */ e(
|
|
253
|
+
$,
|
|
254
|
+
{
|
|
255
|
+
className: "size-10 shrink-0 not-dark:hidden",
|
|
256
|
+
type: m ?? "empty",
|
|
257
|
+
theme: "dark",
|
|
258
|
+
variant: u ?? "default"
|
|
259
|
+
}
|
|
260
|
+
),
|
|
261
|
+
/* @__PURE__ */ e("div", { className: "flex min-w-0 flex-1 flex-col items-start", children: /* @__PURE__ */ r("div", { className: "flex w-full max-w-full min-w-0 flex-1 items-start gap-3", children: [
|
|
262
|
+
/* @__PURE__ */ r("div", { className: "min-w-0 flex-1 gap-1", children: [
|
|
263
|
+
C ? /* @__PURE__ */ e("div", { className: "flex min-w-0 max-w-full items-center gap-1", children: /* @__PURE__ */ e("div", { className: "min-w-0 flex-1", children: /* @__PURE__ */ e(
|
|
264
|
+
V,
|
|
265
|
+
{
|
|
266
|
+
size: "sm",
|
|
267
|
+
value: P,
|
|
268
|
+
onChange: (p) => {
|
|
269
|
+
E(p), G(p);
|
|
270
|
+
},
|
|
271
|
+
onBlur: () => {
|
|
272
|
+
const p = P.trim();
|
|
273
|
+
if (p.length === 0) {
|
|
274
|
+
E(""), G("");
|
|
275
|
+
return;
|
|
276
|
+
}
|
|
277
|
+
P !== p && E(p), G(p);
|
|
278
|
+
},
|
|
279
|
+
isInvalid: O,
|
|
280
|
+
hint: O ? he : void 0,
|
|
281
|
+
isDisabled: o || N,
|
|
282
|
+
isReadOnly: !k || o || N,
|
|
283
|
+
showInfoIcon: !1,
|
|
284
|
+
"aria-label": "File name",
|
|
285
|
+
placeholder: "",
|
|
286
|
+
className: "min-w-0 gap-0",
|
|
287
|
+
inputClassName: "font-medium text-secondary min-w-0",
|
|
288
|
+
customStyles: ce(T),
|
|
289
|
+
trailingAction: T ? /* @__PURE__ */ e("span", { className: "shrink-0 text-xs font-medium text-tertiary pointer-events-none", children: T }) : null
|
|
290
|
+
}
|
|
291
|
+
) }) }) : /* @__PURE__ */ e("p", { className: "truncate text-sm font-medium text-secondary", children: t }),
|
|
292
|
+
/* @__PURE__ */ r("div", { className: "mt-0.5 flex flex-wrap items-center gap-2", children: [
|
|
293
|
+
/* @__PURE__ */ e("p", { className: "truncate text-2xs whitespace-nowrap text-tertiary", children: ue(f) }),
|
|
294
|
+
n === "detecting" && /* @__PURE__ */ r(B, { children: [
|
|
295
|
+
/* @__PURE__ */ e("hr", { className: "h-3 w-px rounded-t-full rounded-b-full border-none bg-border-primary" }),
|
|
296
|
+
/* @__PURE__ */ e("p", { className: "text-2xs font-medium text-tertiary", children: "Checking protection…" })
|
|
297
|
+
] }),
|
|
298
|
+
h && /* @__PURE__ */ r(B, { children: [
|
|
299
|
+
/* @__PURE__ */ e("hr", { className: "h-3 w-px rounded-t-full rounded-b-full border-none bg-border-primary" }),
|
|
300
|
+
/* @__PURE__ */ r("div", { className: "flex items-center gap-1", children: [
|
|
301
|
+
/* @__PURE__ */ e(te, { className: "size-3.5 text-fg-error-primary" }),
|
|
302
|
+
/* @__PURE__ */ e("p", { className: "text-2xs font-medium text-error-primary", children: "Corrupted" })
|
|
303
|
+
] })
|
|
304
|
+
] }),
|
|
305
|
+
I && !h && /* @__PURE__ */ r(B, { children: [
|
|
306
|
+
/* @__PURE__ */ e("hr", { className: "h-3 w-px rounded-t-full rounded-b-full border-none bg-border-primary" }),
|
|
307
|
+
/* @__PURE__ */ r("div", { className: "flex items-center gap-1", children: [
|
|
308
|
+
/* @__PURE__ */ e(ie, { className: "size-3.5 text-fg-quaternary" }),
|
|
309
|
+
/* @__PURE__ */ e("p", { className: "text-2xs font-medium text-tertiary", children: "Protected" })
|
|
310
|
+
] })
|
|
311
|
+
] }),
|
|
312
|
+
Y && /* @__PURE__ */ r(B, { children: [
|
|
313
|
+
/* @__PURE__ */ e("hr", { className: "h-3 w-px rounded-t-full rounded-b-full border-none bg-border-primary" }),
|
|
314
|
+
/* @__PURE__ */ e(W, { title: b, placement: "top", children: /* @__PURE__ */ r("span", { className: "inline-flex items-center gap-1", children: [
|
|
315
|
+
/* @__PURE__ */ e(ne, { className: "size-3.5 text-fg-quaternary" }),
|
|
316
|
+
/* @__PURE__ */ e("p", { className: "text-2xs font-medium text-tertiary", children: "Unverifiable" })
|
|
317
|
+
] }) })
|
|
318
|
+
] }),
|
|
319
|
+
(U || a && !h || s) && /* @__PURE__ */ r(B, { children: [
|
|
320
|
+
/* @__PURE__ */ e("hr", { className: "h-3 w-px rounded-t-full rounded-b-full border-none bg-border-primary" }),
|
|
321
|
+
/* @__PURE__ */ r("div", { className: "flex items-center gap-1", children: [
|
|
322
|
+
U && /* @__PURE__ */ e(j, { className: "size-4 stroke-[2.5px] text-fg-success-primary" }),
|
|
323
|
+
U && /* @__PURE__ */ e("p", { className: "text-2xs font-medium text-success-primary", children: "Complete" }),
|
|
324
|
+
s && /* @__PURE__ */ r("div", { className: "flex items-center gap-2", children: [
|
|
325
|
+
/* @__PURE__ */ r("p", { className: "text-2xs font-medium text-utility-brand-600", children: [
|
|
326
|
+
"Uploading ",
|
|
327
|
+
Math.round(l),
|
|
328
|
+
"%"
|
|
329
|
+
] }),
|
|
330
|
+
w && /* @__PURE__ */ e(
|
|
331
|
+
me,
|
|
332
|
+
{
|
|
333
|
+
max: 100,
|
|
334
|
+
min: 0,
|
|
335
|
+
value: l,
|
|
336
|
+
className: "h-[6px] w-[90px] shrink-0"
|
|
337
|
+
}
|
|
338
|
+
)
|
|
339
|
+
] }),
|
|
340
|
+
a && !h && /* @__PURE__ */ e(se, { className: "size-4 text-fg-error-primary" }),
|
|
341
|
+
a && !h && /* @__PURE__ */ e("p", { className: "text-2xs font-medium text-error-primary", children: y || "Failed" })
|
|
342
|
+
] })
|
|
343
|
+
] })
|
|
344
|
+
] })
|
|
345
|
+
] }),
|
|
346
|
+
X && /* @__PURE__ */ r("div", { className: "flex shrink-0 flex-col items-stretch gap-1 pt-0.5", children: [
|
|
347
|
+
/* @__PURE__ */ r("div", { className: "flex items-center gap-2", children: [
|
|
348
|
+
/* @__PURE__ */ e(
|
|
349
|
+
V,
|
|
350
|
+
{
|
|
351
|
+
size: "sm",
|
|
352
|
+
inputType: "password",
|
|
353
|
+
value: M,
|
|
354
|
+
onChange: (p) => i == null ? void 0 : i(p),
|
|
355
|
+
placeholder: "Enter password",
|
|
356
|
+
"aria-label": "File password",
|
|
357
|
+
isDisabled: A || n === "verified",
|
|
358
|
+
isReadOnly: n === "verified",
|
|
359
|
+
showInfoIcon: !1,
|
|
360
|
+
className: "w-[148px] min-w-0 gap-0",
|
|
361
|
+
inputClassName: "text-sm"
|
|
362
|
+
}
|
|
363
|
+
),
|
|
364
|
+
n === "verified" ? /* @__PURE__ */ r("div", { className: "flex items-center gap-1 px-1", children: [
|
|
365
|
+
/* @__PURE__ */ e(j, { className: "size-4 stroke-[2.5px] text-fg-success-primary" }),
|
|
366
|
+
/* @__PURE__ */ e("p", { className: "text-2xs font-medium whitespace-nowrap text-success-primary", children: "Verified" })
|
|
367
|
+
] }) : n === "unverifiable" ? /* @__PURE__ */ e(W, { title: c, placement: "top", children: /* @__PURE__ */ e("span", { className: "inline-flex", children: Z }) }) : Z
|
|
368
|
+
] }),
|
|
369
|
+
n === "incorrect" && /* @__PURE__ */ e("p", { className: "text-2xs font-medium text-error-primary", children: "Incorrect password" })
|
|
370
|
+
] }),
|
|
371
|
+
/* @__PURE__ */ r("div", { className: "flex shrink-0 items-start gap-1", children: [
|
|
372
|
+
a && v && /* @__PURE__ */ e(
|
|
373
|
+
H,
|
|
374
|
+
{
|
|
375
|
+
color: "tertiary",
|
|
376
|
+
tooltip: "Retry",
|
|
377
|
+
icon: ae,
|
|
378
|
+
size: "xs",
|
|
379
|
+
className: "text-fg-error-primary hover:text-fg-error-primary",
|
|
380
|
+
onClick: v,
|
|
381
|
+
isDisabled: o
|
|
382
|
+
}
|
|
383
|
+
),
|
|
384
|
+
/* @__PURE__ */ e(
|
|
385
|
+
H,
|
|
386
|
+
{
|
|
387
|
+
color: "tertiary",
|
|
388
|
+
tooltip: "Delete",
|
|
389
|
+
icon: le,
|
|
390
|
+
size: "xs",
|
|
391
|
+
onClick: x,
|
|
392
|
+
isDisabled: o
|
|
393
|
+
}
|
|
394
|
+
)
|
|
395
|
+
] })
|
|
396
|
+
] }) })
|
|
397
|
+
] }),
|
|
398
|
+
d && /* @__PURE__ */ r(B, { children: [
|
|
399
|
+
/* @__PURE__ */ e("div", { className: "w-[0.5px] w-full border-[0.5px] border-secondary" }),
|
|
400
|
+
d
|
|
401
|
+
] })
|
|
402
|
+
] })
|
|
403
|
+
}
|
|
404
|
+
);
|
|
405
|
+
}, ye = (t) => /* @__PURE__ */ e("div", { ...t, className: F("flex flex-col gap-4", t.className), children: t.children }), ve = (t) => /* @__PURE__ */ e("ul", { ...t, className: F("flex flex-col gap-3", t.className), children: /* @__PURE__ */ e(fe, { initial: !1, children: t.children }) }), Le = {
|
|
406
|
+
Root: ye,
|
|
407
|
+
List: ve,
|
|
408
|
+
DropZone: ge,
|
|
409
|
+
DropZoneCompact: xe,
|
|
410
|
+
ListItemProgressBar: Ne
|
|
411
|
+
};
|
|
412
|
+
export {
|
|
413
|
+
Ne as FileListItemProgressBar,
|
|
414
|
+
Le as FileUpload,
|
|
415
|
+
ge as FileUploadDropZone,
|
|
416
|
+
xe as FileUploadDropZoneCompact,
|
|
417
|
+
ue as getReadableFileSize
|
|
418
|
+
};
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
export { FileUpload, FileUploadDropZone, FileUploadDropZoneCompact, FileListItemProgressBar, getReadableFileSize, type FileUploadDropZoneProps, type FileListItemProps, type FileListItemPasswordState, } from './file-upload';
|
|
2
|
+
export { splitEditableUploadFileName, hasNonEmptyUploadFileBaseName, uniquifyUploadFileName, uniquifyUploadFilesForSubmit, extensionTrailingPadding, } from './file-upload-filename';
|
|
3
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/patterns/file-upload/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,UAAU,EACV,kBAAkB,EAClB,yBAAyB,EACzB,uBAAuB,EACvB,mBAAmB,EACnB,KAAK,uBAAuB,EAC5B,KAAK,iBAAiB,EACtB,KAAK,yBAAyB,GAC/B,MAAM,eAAe,CAAC;AACvB,OAAO,EACL,2BAA2B,EAC3B,6BAA6B,EAC7B,sBAAsB,EACtB,4BAA4B,EAC5B,wBAAwB,GACzB,MAAM,wBAAwB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SearchInput.d.ts","sourceRoot":"","sources":["../../../src/primitives/select/SearchInput.tsx"],"names":[],"mappings":"AAAA,OAAO,EAKL,KAAK,iBAAiB,EACtB,KAAK,oBAAoB,EAC1B,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"SearchInput.d.ts","sourceRoot":"","sources":["../../../src/primitives/select/SearchInput.tsx"],"names":[],"mappings":"AAAA,OAAO,EAKL,KAAK,iBAAiB,EACtB,KAAK,oBAAoB,EAC1B,MAAM,OAAO,CAAC;AAef,MAAM,WAAW,gBAAgB;IAC/B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,IAAI,CAAC,EAAE,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;IACjC,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACnC,MAAM,CAAC,EAAE,iBAAiB,CAAC;IAC3B,OAAO,CAAC,EAAE,iBAAiB,CAAC;IAC5B,SAAS,CAAC,EAAE,oBAAoB,CAAC;IACjC,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB;;;;;OAKG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB;;;OAGG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB;;;;OAIG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,uHAAuH;IACvH,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,8GAA8G;IAC9G,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAyGD,MAAM,CAAC,OAAO,UAAU,WAAW,CAAC,EAClC,IAAW,EACX,QAAgB,EAChB,gBAAgB,EAChB,QAAgB,EAChB,cAAc,EACd,SAAiB,EACjB,WAAW,EACX,iBAAiB,EACjB,KAAK,EACL,QAAQ,EACR,SAAS,EACT,SAAS,EACT,UAAkB,EAClB,YAAY,EAAE,SAAS,EACvB,GAAG,KAAK,EACT,EAAE,gBAAgB,2CAwIlB"}
|