@epam/ai-dial-chat-shared 1.3.0-dev.98 → 1.4.0-dev.5
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/components/ActionMenu/ActionMenu.d.ts +26 -0
- package/components/ActionMenu/ActionMenu.d.ts.map +1 -0
- package/components/ActionMenu/ActionMenu.js +50 -0
- package/components/ConfirmationDialog/ConfirmationDialog.d.ts +6 -1
- package/components/ConfirmationDialog/ConfirmationDialog.d.ts.map +1 -1
- package/components/ConfirmationDialog/ConfirmationDialog.js +11 -9
- package/components/ConfirmationIdentityCard/ConfirmationIdentityCard.module.scss.js +5 -4
- package/components/ConfirmationIdentityRow/ConfirmationIdentityRow.js +2 -2
- package/components/ConfirmationIdentityRow/ConfirmationIdentityRow.module.scss.js +3 -2
- package/components/ConfirmationView/ConfirmationFooter.d.ts.map +1 -1
- package/components/ConfirmationView/ConfirmationFooter.js +24 -25
- package/components/ConfirmationView/ConfirmationView.d.ts +2 -0
- package/components/ConfirmationView/ConfirmationView.d.ts.map +1 -1
- package/components/ConfirmationView/ConfirmationView.js +12 -12
- package/components/ConfirmationView/ConfirmationView.module.scss.js +6 -5
- package/components/DeleteConfirmationDrawer/DeleteConfirmationDrawer.d.ts +31 -0
- package/components/DeleteConfirmationDrawer/DeleteConfirmationDrawer.d.ts.map +1 -0
- package/components/DeleteConfirmationDrawer/DeleteConfirmationDrawer.js +36 -0
- package/components/DeleteConfirmationView/DeleteConfirmationView.d.ts +3 -0
- package/components/DeleteConfirmationView/DeleteConfirmationView.d.ts.map +1 -1
- package/components/DeleteConfirmationView/DeleteConfirmationView.js +36 -27
- package/components/DeleteConfirmationView/DeleteConfirmationView.module.scss.js +5 -4
- package/components/DeploymentIcon/DeploymentIcon.module.scss.js +3 -2
- package/components/EntityHeader/EntityHeader.js +1 -1
- package/components/InitialsAvatar/InitialsAvatar.d.ts +3 -0
- package/components/InitialsAvatar/InitialsAvatar.d.ts.map +1 -1
- package/components/InitialsAvatar/InitialsAvatar.js +4 -3
- package/components/ItemHeader/ItemHeader.module.scss.js +5 -4
- package/components/MarkdownRenderer/CodeBlock/CodeBlock.d.ts +6 -2
- package/components/MarkdownRenderer/CodeBlock/CodeBlock.d.ts.map +1 -1
- package/components/MarkdownRenderer/CodeBlock/CodeBlock.js +58 -58
- package/components/MarkdownRenderer/CodeBlock/CodeBlock.module.scss.js +9 -8
- package/components/MarkdownRenderer/CodeBlock/syntax-theme.d.ts.map +1 -1
- package/components/MarkdownRenderer/MarkdownRenderer.d.ts +6 -0
- package/components/MarkdownRenderer/MarkdownRenderer.d.ts.map +1 -1
- package/components/MarkdownRenderer/MarkdownRenderer.js +29 -24
- package/components/MarkdownRenderer/MarkdownRenderer.module.scss.js +9 -8
- package/components/MarkdownRenderer/Math/MarkdownMathBlock.module.scss.js +5 -4
- package/components/MarkdownRenderer/PlainTextRenderer.js +1 -1
- package/components/MarkdownRenderer/Table/MarkdownTable.d.ts +4 -0
- package/components/MarkdownRenderer/Table/MarkdownTable.d.ts.map +1 -1
- package/components/MarkdownRenderer/Table/MarkdownTable.js +68 -63
- package/components/MarkdownRenderer/Table/MarkdownTable.module.scss.js +15 -13
- package/components/MarkdownRenderer/Table/TableHeader.module.scss.js +3 -2
- package/components/MarkdownRenderer/markdown-whitespace.js +2 -6
- package/components/NewVersionAlert/NewVersionAlert.d.ts +27 -0
- package/components/NewVersionAlert/NewVersionAlert.d.ts.map +1 -0
- package/components/NewVersionAlert/NewVersionAlert.js +28 -0
- package/components/NewVersionAlert/NewVersionAlert.module.scss.js +4 -0
- package/components/NotificationStack/NotificationStack.d.ts +48 -0
- package/components/NotificationStack/NotificationStack.d.ts.map +1 -0
- package/components/NotificationStack/NotificationStack.js +111 -0
- package/components/PanelEmptyState/PanelEmptyState.d.ts +12 -2
- package/components/PanelEmptyState/PanelEmptyState.d.ts.map +1 -1
- package/components/PanelEmptyState/PanelEmptyState.js +19 -9
- package/components/PanelEmptyState/PanelEmptyState.module.scss.js +6 -2
- package/components/ResourceSummary/ResourceSummary.module.scss.js +5 -4
- package/components/TextRefinementField/TextRefinementField.d.ts +4 -2
- package/components/TextRefinementField/TextRefinementField.d.ts.map +1 -1
- package/components/TextRefinementField/TextRefinementField.js +84 -55
- package/components/UnsavedChangesProvider/UnsavedChangesProvider.d.ts +22 -0
- package/components/UnsavedChangesProvider/UnsavedChangesProvider.d.ts.map +1 -0
- package/components/UnsavedChangesProvider/UnsavedChangesProvider.js +57 -0
- package/components/UnsavedChangesProvider/unsaved-changes-context.d.ts +44 -0
- package/components/UnsavedChangesProvider/unsaved-changes-context.d.ts.map +1 -0
- package/components/UnsavedChangesProvider/unsaved-changes-context.js +13 -0
- package/constants/breakpoint.d.ts +6 -0
- package/constants/breakpoint.d.ts.map +1 -1
- package/constants/breakpoint.js +2 -2
- package/conversation-transfer/conversation-transfer-queue.d.ts +16 -0
- package/conversation-transfer/conversation-transfer-queue.d.ts.map +1 -0
- package/conversation-transfer/conversation-transfer-queue.js +24 -0
- package/file-manager/DialFileManagerShell/DialFileManagerShell.d.ts +9 -0
- package/file-manager/DialFileManagerShell/DialFileManagerShell.d.ts.map +1 -1
- package/file-manager/DialFileManagerShell/DialFileManagerShell.js +330 -269
- package/file-manager/DialFileManagerShell/DialFileManagerShell.module.scss.js +8 -0
- package/file-manager/FileManagerAttachModal/FileManagerAttachModal.d.ts +7 -0
- package/file-manager/FileManagerAttachModal/FileManagerAttachModal.d.ts.map +1 -1
- package/file-manager/FileManagerAttachModal/FileManagerAttachModal.js +85 -80
- package/file-manager/FileManagerAttachModal/FileManagerAttachModal.module.scss.js +7 -0
- package/file-manager/OperationLoaderModal/OperationLoaderModal.d.ts +5 -0
- package/file-manager/OperationLoaderModal/OperationLoaderModal.d.ts.map +1 -1
- package/file-manager/OperationLoaderModal/OperationLoaderModal.js +25 -20
- package/file-manager/OperationLoaderModal/OperationLoaderModal.module.scss.js +4 -0
- package/file-manager/file-manager-controller.d.ts +11 -3
- package/file-manager/file-manager-controller.d.ts.map +1 -1
- package/file-manager/index.d.ts +1 -0
- package/file-manager/index.d.ts.map +1 -1
- package/file-manager/labels.d.ts +21 -2
- package/file-manager/labels.d.ts.map +1 -1
- package/file-manager/shell-styles.d.ts +37 -0
- package/file-manager/shell-styles.d.ts.map +1 -0
- package/file-manager/upload-batch.d.ts +46 -0
- package/file-manager/upload-batch.d.ts.map +1 -1
- package/file-manager/upload-batch.js +6 -2
- package/file-manager/upload-queue.d.ts +44 -4
- package/file-manager/upload-queue.d.ts.map +1 -1
- package/file-manager/upload-queue.js +45 -13
- package/file-manager.js +4 -4
- package/hooks/useAvailableHeightCap.js +1 -1
- package/hooks/useControlErrorAssociation.d.ts +3 -0
- package/hooks/useControlErrorAssociation.d.ts.map +1 -0
- package/hooks/useControlErrorAssociation.js +12 -0
- package/hooks/useIsMobile.js +1 -1
- package/hooks/useIsPhone.d.ts +3 -0
- package/hooks/useIsPhone.d.ts.map +1 -0
- package/hooks/useIsPhone.js +13 -0
- package/hooks/useIsTablet.d.ts +3 -0
- package/hooks/useIsTablet.d.ts.map +1 -0
- package/hooks/useIsTablet.js +13 -0
- package/hooks/useIsTextClipped.d.ts +26 -0
- package/hooks/useIsTextClipped.d.ts.map +1 -0
- package/hooks/useIsTextClipped.js +25 -0
- package/hooks/useIsVerticallyClamped.d.ts +16 -0
- package/hooks/useIsVerticallyClamped.d.ts.map +1 -0
- package/hooks/useIsVerticallyClamped.js +20 -0
- package/hooks/useTextRefinement.d.ts +1 -1
- package/hooks/useTextRefinement.d.ts.map +1 -1
- package/hooks/useTextRefinement.js +4 -4
- package/hooks/useUnsavedChangesGuard.js +1 -5
- package/hooks/useUnsavedChangesLeaveConfirmation.d.ts +12 -0
- package/hooks/useUnsavedChangesLeaveConfirmation.d.ts.map +1 -0
- package/hooks/useUnsavedChangesLeaveConfirmation.js +22 -0
- package/hooks/useUnsavedChangesLeaveGuard.d.ts +24 -0
- package/hooks/useUnsavedChangesLeaveGuard.d.ts.map +1 -0
- package/hooks/useUnsavedChangesLeaveGuard.js +24 -0
- package/index.css +2 -2
- package/index.d.ts +15 -0
- package/index.d.ts.map +1 -1
- package/index.js +93 -78
- package/models/auth.d.ts +2 -0
- package/models/auth.d.ts.map +1 -1
- package/models/chat.d.ts +19 -0
- package/models/chat.d.ts.map +1 -1
- package/models/conversation-classification.d.ts +5 -0
- package/models/conversation-classification.d.ts.map +1 -1
- package/models/conversation-classification.js +3 -1
- package/models/text-refinement.d.ts +6 -2
- package/models/text-refinement.d.ts.map +1 -1
- package/package.json +10 -17
- package/types/mime-type.d.ts +30 -0
- package/types/mime-type.d.ts.map +1 -1
- package/types/mime-type.js +1 -1
- package/utils/dom.d.ts +8 -0
- package/utils/dom.d.ts.map +1 -0
- package/utils/dom.js +10 -0
- package/utils/format-price.js +10 -10
- package/utils/inline-segments.js +1 -1
- package/utils/latex.d.ts +4 -3
- package/utils/latex.d.ts.map +1 -1
- package/utils/latex.js +47 -41
- package/utils/message-attachment-to-display.js +1 -1
- package/utils/mime-type.js +1 -1
- package/utils/prompt-variables.js +5 -9
- package/utils/syntax-highlighting.js +8 -8
|
@@ -1,323 +1,384 @@
|
|
|
1
1
|
import { mergeClasses as e } from "../../utils/merge-class.js";
|
|
2
|
-
import {
|
|
2
|
+
import { buildCssVars as t } from "../../utils/build-css-vars.js";
|
|
3
|
+
import { DialFileManagerActionProfile as n, DialFileManagerVariant as r } from "../file-manager-variant.js";
|
|
3
4
|
import { getParentFolderPath as ee } from "../path.js";
|
|
4
5
|
import { useGridEditingScroll as te } from "../useGridEditingScroll/useGridEditingScroll.js";
|
|
5
6
|
import { OperationLoaderModal as ne } from "../OperationLoaderModal/OperationLoaderModal.js";
|
|
6
|
-
import {
|
|
7
|
-
import
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
7
|
+
import { TransferQueueRowKind as re, buildTransferQueueLabels as ie, parseTransferQueueRowId as ae, toTransferQueueItems as oe } from "../upload-queue.js";
|
|
8
|
+
import i from "./DialFileManagerShell.module.scss.js";
|
|
9
|
+
import { Button as se, ButtonAppearance as ce, ButtonVariant as a, ElementSize as le, ErrorMessageNotification as ue, LiveRegion as de, LiveRegionElement as fe, NOT_ALLOWED_SYMBOLS_REGEXP as pe, Spinner as me, TransferQueue as he } from "@epam/ai-dial-ui-kit";
|
|
10
|
+
import { memo as o, useCallback as ge, useEffect as _e, useMemo as s, useState as ve } from "react";
|
|
11
|
+
import { Fragment as ye, jsx as c, jsxs as l } from "react/jsx-runtime";
|
|
12
|
+
import { DialFileManager as be, DialFileManagerActions as u, DialFileManagerTabs as xe, GridSelectionMode as Se } from "@epam/ai-dial-react-file-manager";
|
|
11
13
|
//#region src/file-manager/DialFileManagerShell/DialFileManagerShell.tsx
|
|
12
|
-
var
|
|
13
|
-
if (e.isDownloading) return t.downloadingLabel;
|
|
14
|
+
var Ce = (e, t) => {
|
|
14
15
|
if (e.isDeleting) return t.deletingLabel;
|
|
15
16
|
if (e.isRenaming && !e.isMoving) return t.renamingLabel;
|
|
16
17
|
if (e.isUnsharing) return t.unsharingLabel;
|
|
17
18
|
if (e.isRemovingAccess) return t.removingAccessLabel;
|
|
18
|
-
},
|
|
19
|
-
let { items:
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
}, [
|
|
23
|
-
let
|
|
19
|
+
}, d = ({ controller: o, labels: d, activeTab: f, tabs: p, onTabChange: m, selectedPaths: h, onSelectedPathsChange: we, variant: g, actionProfile: Te, autoSelectUploadedItems: Ee = !1, allowedFileTypes: De, maxSelectableFileSize: _, oversizedUploadMessage: Oe, isRowSelectable: v, getDisabledTooltip: ke, unsupportedFileTypeTooltip: Ae, treeContainerClassName: y, onPreview: je, onTableFileClick: Me, previewExtensions: Ne, styles: b }) => {
|
|
20
|
+
let { items: Pe, isLoading: Fe, error: Ie, path: x, onPathChange: Le, retry: Re, onSearchFiles: ze, isSearching: Be, searchResults: Ve, clearSearchResults: He, expandedPaths: Ue, loadedPaths: S, onExpandedPathsChange: We, onFolderPopupPathChange: Ge, folderPopupLoadingPaths: C, onUploadFiles: Ke, onUploadArchive: qe, onValidateUpload: Je, uploadBatchState: w, cancelUpload: T, cancelUploadFile: E, clearUploadBatch: D, downloadBatchState: O, cancelDownloadFile: k, cancelAllDownloads: A, clearDownloadBatch: j, onCreateFolder: Ye, onCreateFolderValidate: Xe, onDownloadFiles: Ze, onDeleteFiles: Qe, isDeleting: $e, onMoveToFiles: et, onRenameValidate: tt, isRenaming: nt, onCopyFiles: rt, isCopying: it, isMoving: M, cancelCopyMove: at, uploadEnabled: N, isNewButtonDisabled: P, disabledNewButtonTooltip: F, visibleColumns: I, dateLocale: L, dateOptions: R, actionLabels: z, sharedWithMeIds: ot, sharedByMePaths: B, onUnshareFiles: st, isUnsharing: ct, onRemoveFilesAccess: lt, isRemovingAccess: ut, fileMetadata: V, isFileMetadataLoading: H, onGetInfo: dt, clearMetadata: U, sectionTab: ft } = o, W = ft ?? f, [G, pt] = ve(void 0), { handleGridApiChange: mt, reset: K } = te();
|
|
21
|
+
_e(() => {
|
|
22
|
+
K();
|
|
23
|
+
}, [W, K]);
|
|
24
|
+
let q = s(() => {
|
|
24
25
|
let e = {};
|
|
25
|
-
return
|
|
26
|
+
return u.Download in z && (e[u.Download] = d.downloadLabel), u.Delete in z && (e[u.Delete] = d.deleteLabel), u.Rename in z && (e[u.Rename] = d.renameLabel), u.Copy in z && (e[u.Copy] = d.copyLabel), u.Move in z && (e[u.Move] = d.moveLabel), u.Duplicate in z && (e[u.Duplicate] = d.duplicateLabel), u.Unshare in z && (e[u.Unshare] = d.unshareLabel), u.RemoveAccess in z && (e[u.RemoveAccess] = d.removeAccessLabel), e;
|
|
26
27
|
}, [
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
]),
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
28
|
+
z,
|
|
29
|
+
d.downloadLabel,
|
|
30
|
+
d.deleteLabel,
|
|
31
|
+
d.renameLabel,
|
|
32
|
+
d.copyLabel,
|
|
33
|
+
d.moveLabel,
|
|
34
|
+
d.duplicateLabel,
|
|
35
|
+
d.unshareLabel,
|
|
36
|
+
d.removeAccessLabel
|
|
37
|
+
]), J = s(() => {
|
|
38
|
+
let e = d.previewLabel == null ? q : {
|
|
39
|
+
...q,
|
|
40
|
+
[u.Preview]: d.previewLabel
|
|
41
|
+
};
|
|
42
|
+
return u.Info in z ? {
|
|
43
|
+
...e,
|
|
44
|
+
[u.Info]: d.infoLabel
|
|
45
|
+
} : e;
|
|
46
|
+
}, [
|
|
47
|
+
q,
|
|
48
|
+
z,
|
|
49
|
+
d.infoLabel,
|
|
50
|
+
d.previewLabel
|
|
51
|
+
]), Y = s(() => {
|
|
52
|
+
if (h.size === 0) return !1;
|
|
53
|
+
for (let e of h) if (!B.has(e)) return !1;
|
|
46
54
|
return !0;
|
|
47
|
-
}, [
|
|
48
|
-
if (
|
|
49
|
-
let { [
|
|
55
|
+
}, [h, B]), X = s(() => {
|
|
56
|
+
if (Y) return q;
|
|
57
|
+
let { [u.RemoveAccess]: e, ...t } = q;
|
|
50
58
|
return t;
|
|
51
|
-
}, [
|
|
52
|
-
selectionMode:
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
59
|
+
}, [q, Y]), Z = g === r.Attach, ht = s(() => ({
|
|
60
|
+
selectionMode: Se.MULTIPLE,
|
|
61
|
+
filterable: !1,
|
|
62
|
+
withoutHeaderBorders: !0,
|
|
63
|
+
containerClassName: Z ? void 0 : "rounded-none shadow-none",
|
|
64
|
+
visibleColumns: I,
|
|
65
|
+
dateLocale: L,
|
|
66
|
+
dateOptions: R,
|
|
57
67
|
additionalGridOptions: {
|
|
58
68
|
domLayout: "normal",
|
|
59
69
|
rowSelection: {
|
|
60
70
|
mode: "multiRow",
|
|
61
|
-
isRowSelectable:
|
|
71
|
+
isRowSelectable: v ?? (() => !0)
|
|
62
72
|
}
|
|
63
73
|
},
|
|
64
|
-
actionLabels:
|
|
74
|
+
actionLabels: J
|
|
65
75
|
}), [
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
]),
|
|
73
|
-
header:
|
|
74
|
-
containerClassName:
|
|
75
|
-
tabsAriaLabel:
|
|
76
|
-
tabs:
|
|
77
|
-
activeTab:
|
|
78
|
-
onTabChange:
|
|
79
|
-
expandedPaths:
|
|
80
|
-
loadedPaths:
|
|
81
|
-
loadingPaths:
|
|
82
|
-
onExpandedPathsChange:
|
|
83
|
-
actionLabels:
|
|
76
|
+
I,
|
|
77
|
+
L,
|
|
78
|
+
R,
|
|
79
|
+
J,
|
|
80
|
+
v,
|
|
81
|
+
Z
|
|
82
|
+
]), gt = s(() => ({
|
|
83
|
+
header: d.treeHeader ?? null,
|
|
84
|
+
containerClassName: y ?? (g === r.Attach ? e("relative z-1 min-h-0 h-full w-[360px] shrink-0 border-e", i.tree) : void 0),
|
|
85
|
+
tabsAriaLabel: d.treeHeaderByTab[f],
|
|
86
|
+
tabs: p,
|
|
87
|
+
activeTab: f,
|
|
88
|
+
onTabChange: m,
|
|
89
|
+
expandedPaths: Ue,
|
|
90
|
+
loadedPaths: S,
|
|
91
|
+
loadingPaths: C,
|
|
92
|
+
onExpandedPathsChange: We,
|
|
93
|
+
actionLabels: q
|
|
84
94
|
}), [
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
p,
|
|
88
|
-
u,
|
|
89
|
-
l,
|
|
90
|
-
d,
|
|
95
|
+
d.treeHeader,
|
|
96
|
+
d.treeHeaderByTab,
|
|
91
97
|
y,
|
|
92
|
-
|
|
98
|
+
g,
|
|
99
|
+
p,
|
|
100
|
+
f,
|
|
101
|
+
m,
|
|
102
|
+
Ue,
|
|
93
103
|
S,
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
104
|
+
C,
|
|
105
|
+
We,
|
|
106
|
+
q
|
|
107
|
+
]), _t = g === r.Standalone && Te === n.Full && W === xe.MyFiles && N, vt = s(() => ({
|
|
97
108
|
showHiddenFilesToggle: !0,
|
|
98
|
-
...
|
|
99
|
-
hiddenFilesSwitcherLabel:
|
|
100
|
-
showHiddenFilesLabel:
|
|
101
|
-
hideHiddenFilesLabel:
|
|
102
|
-
isNewButtonDisabled:
|
|
103
|
-
disabledNewButtonTooltip:
|
|
109
|
+
...Z ? { newButtonVariant: a.Neutral } : {},
|
|
110
|
+
hiddenFilesSwitcherLabel: d.hiddenFilesLabel,
|
|
111
|
+
showHiddenFilesLabel: d.showHiddenFilesLabel,
|
|
112
|
+
hideHiddenFilesLabel: d.hideHiddenFilesLabel,
|
|
113
|
+
isNewButtonDisabled: P,
|
|
114
|
+
disabledNewButtonTooltip: F,
|
|
104
115
|
newActions: {
|
|
105
116
|
uploadFiles: {
|
|
106
|
-
label:
|
|
117
|
+
label: d.uploadFilesLabel,
|
|
107
118
|
icon: null
|
|
108
119
|
},
|
|
109
120
|
newFolder: {
|
|
110
|
-
label:
|
|
121
|
+
label: d.newFolderLabel,
|
|
111
122
|
icon: null
|
|
112
123
|
},
|
|
113
|
-
...
|
|
114
|
-
label:
|
|
124
|
+
..._t ? { uploadArchive: {
|
|
125
|
+
label: d.uploadArchiveAction,
|
|
115
126
|
icon: null
|
|
116
127
|
} } : {}
|
|
117
128
|
}
|
|
118
129
|
}), [
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
]),
|
|
130
|
-
getSelectionLabel:
|
|
131
|
-
actionLabels:
|
|
130
|
+
Z,
|
|
131
|
+
d.hiddenFilesLabel,
|
|
132
|
+
d.showHiddenFilesLabel,
|
|
133
|
+
d.hideHiddenFilesLabel,
|
|
134
|
+
P,
|
|
135
|
+
F,
|
|
136
|
+
d.uploadFilesLabel,
|
|
137
|
+
d.newFolderLabel,
|
|
138
|
+
_t,
|
|
139
|
+
d.uploadArchiveAction
|
|
140
|
+
]), yt = s(() => Z ? void 0 : {
|
|
141
|
+
getSelectionLabel: d.getSelectionLabel,
|
|
142
|
+
actionLabels: X
|
|
132
143
|
}, [
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
]),
|
|
137
|
-
cancelLabel:
|
|
138
|
-
confirmLabel:
|
|
139
|
-
closeLabel:
|
|
140
|
-
titleRenderer:
|
|
141
|
-
contentRenderer:
|
|
144
|
+
Z,
|
|
145
|
+
d.getSelectionLabel,
|
|
146
|
+
X
|
|
147
|
+
]), bt = s(() => ({
|
|
148
|
+
cancelLabel: d.deleteCancelLabel,
|
|
149
|
+
confirmLabel: d.deleteConfirmLabel,
|
|
150
|
+
closeLabel: d.deleteCloseLabel,
|
|
151
|
+
titleRenderer: d.deleteConfirmTitle,
|
|
152
|
+
contentRenderer: d.deleteConfirmBody
|
|
142
153
|
}), [
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
]),
|
|
154
|
+
d.deleteCancelLabel,
|
|
155
|
+
d.deleteConfirmLabel,
|
|
156
|
+
d.deleteCloseLabel,
|
|
157
|
+
d.deleteConfirmTitle,
|
|
158
|
+
d.deleteConfirmBody
|
|
159
|
+
]), xt = s(() => {
|
|
149
160
|
let e;
|
|
150
|
-
for (let t of
|
|
161
|
+
for (let t of h) {
|
|
151
162
|
let n = ee(t);
|
|
152
163
|
if (e === void 0) e = n;
|
|
153
164
|
else if (e !== n) return;
|
|
154
165
|
}
|
|
155
166
|
return e;
|
|
156
|
-
}, [
|
|
157
|
-
copyLabel:
|
|
158
|
-
moveLabel:
|
|
159
|
-
addFolderLabel:
|
|
160
|
-
hiddenFilesSwitcherLabel:
|
|
161
|
-
getCopyHeader:
|
|
162
|
-
getMoveHeader:
|
|
163
|
-
disabledPathTooltip:
|
|
164
|
-
movedIntoItselfTooltip:
|
|
165
|
-
emptyStateTitle:
|
|
166
|
-
emptyStateDescription:
|
|
167
|
-
sourceFolder:
|
|
168
|
-
destinationFolderPath:
|
|
169
|
-
setDestinationFolderPath:
|
|
170
|
-
filesLoading:
|
|
167
|
+
}, [h]), Q = G != null && C.has(G), St = Q ? G : xt, Ct = s(() => ({
|
|
168
|
+
copyLabel: d.copyLabel,
|
|
169
|
+
moveLabel: d.moveLabel,
|
|
170
|
+
addFolderLabel: d.addFolderLabel,
|
|
171
|
+
hiddenFilesSwitcherLabel: d.hiddenFilesSwitcherLabel,
|
|
172
|
+
getCopyHeader: d.getCopyHeader,
|
|
173
|
+
getMoveHeader: d.getMoveHeader,
|
|
174
|
+
disabledPathTooltip: Q ? d.folderPickerLoadingTooltip : d.moveSourceDisabledTooltip,
|
|
175
|
+
movedIntoItselfTooltip: d.movedIntoItselfTooltip,
|
|
176
|
+
emptyStateTitle: d.folderPickerEmptyStateTitle,
|
|
177
|
+
emptyStateDescription: d.folderPickerEmptyStateDescription,
|
|
178
|
+
sourceFolder: St,
|
|
179
|
+
destinationFolderPath: G,
|
|
180
|
+
setDestinationFolderPath: pt,
|
|
181
|
+
filesLoading: Q
|
|
171
182
|
}), [
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
]),
|
|
187
|
-
|
|
188
|
-
}, [
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
183
|
+
d.copyLabel,
|
|
184
|
+
d.moveLabel,
|
|
185
|
+
d.addFolderLabel,
|
|
186
|
+
d.hiddenFilesSwitcherLabel,
|
|
187
|
+
d.getCopyHeader,
|
|
188
|
+
d.getMoveHeader,
|
|
189
|
+
d.folderPickerLoadingTooltip,
|
|
190
|
+
d.moveSourceDisabledTooltip,
|
|
191
|
+
d.movedIntoItselfTooltip,
|
|
192
|
+
d.folderPickerEmptyStateTitle,
|
|
193
|
+
d.folderPickerEmptyStateDescription,
|
|
194
|
+
Q,
|
|
195
|
+
St,
|
|
196
|
+
G
|
|
197
|
+
]), wt = ge(() => {
|
|
198
|
+
T(), A(), D(), j();
|
|
199
|
+
}, [
|
|
200
|
+
T,
|
|
201
|
+
A,
|
|
202
|
+
D,
|
|
203
|
+
j
|
|
204
|
+
]), Tt = ge((e) => {
|
|
205
|
+
let t = ae(e);
|
|
206
|
+
t?.kind === re.Upload ? E(t.entryId) : t?.kind === re.Download && k(t.entryId);
|
|
207
|
+
}, [E, k]), Et = s(() => oe(w, O, d.uploadFailureMessages), [
|
|
208
|
+
w,
|
|
209
|
+
O,
|
|
210
|
+
d.uploadFailureMessages
|
|
211
|
+
]), Dt = w?.files.length ?? 0, Ot = O?.files.length ?? 0, kt = d.getTransferQueueTitle?.({
|
|
212
|
+
uploads: Dt,
|
|
213
|
+
downloads: Ot
|
|
214
|
+
}) ?? d.getUploadQueueTitle(Dt + Ot), At = s(() => ie({
|
|
215
|
+
uploadLabels: d.uploadQueueLabels,
|
|
216
|
+
downloadLabels: d.downloadQueueLabels,
|
|
217
|
+
mixedProgressLabel: d.transferQueueProgressAriaLabel,
|
|
218
|
+
uploadNames: new Set(w?.files.map((e) => e.name)),
|
|
219
|
+
downloadNames: new Set(O?.files.map((e) => e.name))
|
|
198
220
|
}), [
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
221
|
+
d.uploadQueueLabels,
|
|
222
|
+
d.downloadQueueLabels,
|
|
223
|
+
d.transferQueueProgressAriaLabel,
|
|
224
|
+
w,
|
|
225
|
+
O
|
|
226
|
+
]), jt = s(() => ({
|
|
227
|
+
fileMetadata: V,
|
|
228
|
+
loading: H,
|
|
229
|
+
clearMetadata: U,
|
|
230
|
+
header: d.metadataHeader,
|
|
231
|
+
nameLabel: d.metadataNameLabel,
|
|
232
|
+
pathLabel: d.metadataPathLabel,
|
|
233
|
+
modifiedDateLabel: d.metadataModifiedDateLabel,
|
|
234
|
+
sizeLabel: d.metadataSizeLabel,
|
|
235
|
+
authorLabel: d.metadataAuthorLabel
|
|
236
|
+
}), [
|
|
237
|
+
V,
|
|
238
|
+
H,
|
|
239
|
+
U,
|
|
240
|
+
d.metadataHeader,
|
|
241
|
+
d.metadataNameLabel,
|
|
242
|
+
d.metadataPathLabel,
|
|
243
|
+
d.metadataModifiedDateLabel,
|
|
244
|
+
d.metadataSizeLabel,
|
|
245
|
+
d.metadataAuthorLabel
|
|
246
|
+
]), $ = Ce({
|
|
247
|
+
isDeleting: $e,
|
|
248
|
+
isRenaming: nt,
|
|
249
|
+
isMoving: M,
|
|
250
|
+
isUnsharing: ct,
|
|
251
|
+
isRemovingAccess: ut
|
|
252
|
+
}, d), Mt = s(() => x.split("/").filter(Boolean).length > 1 ? {
|
|
253
|
+
title: d.folderEmptyStateTitle,
|
|
217
254
|
description: ""
|
|
218
|
-
} :
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
])
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
255
|
+
} : d.emptyStateByTab[W], [
|
|
256
|
+
x,
|
|
257
|
+
d.folderEmptyStateTitle,
|
|
258
|
+
d.emptyStateByTab,
|
|
259
|
+
W
|
|
260
|
+
]), Nt = t({
|
|
261
|
+
"--dfms-surface": b?.colors?.surface,
|
|
262
|
+
"--dfms-tree-bg": b?.colors?.treeBackground,
|
|
263
|
+
"--dfms-tree-border": b?.colors?.treeBorder,
|
|
264
|
+
"--dfms-tree-shadow": b?.colors?.treeShadow,
|
|
265
|
+
"--dfms-overlay-backdrop": b?.colors?.overlayBackdrop
|
|
266
|
+
});
|
|
267
|
+
return /* @__PURE__ */ l(ye, { children: [
|
|
268
|
+
Ie == null ? /* @__PURE__ */ l("div", {
|
|
269
|
+
style: Nt,
|
|
270
|
+
className: e("relative flex min-h-0 w-full grow overflow-auto", i.surface),
|
|
271
|
+
children: [
|
|
272
|
+
/* @__PURE__ */ c(be, {
|
|
273
|
+
className: e("min-h-0 w-full grow", i.surface, Z && "p-0"),
|
|
274
|
+
contentClassName: Z ? "px-0 pb-0" : void 0,
|
|
275
|
+
gridClassName: g === r.Attach ? "size-full gap-6 px-6 py-4" : "size-full",
|
|
276
|
+
items: Pe,
|
|
277
|
+
path: x,
|
|
278
|
+
onPathChange: Le,
|
|
279
|
+
onGridApiChange: mt,
|
|
280
|
+
filesLoading: Fe,
|
|
281
|
+
allowedFileTypes: De,
|
|
282
|
+
maxSelectableFileSize: _,
|
|
283
|
+
maxFileSize: _,
|
|
284
|
+
uploadValidationMessages: Oe == null ? void 0 : { oversizedFiles: Oe },
|
|
285
|
+
selectedPaths: h,
|
|
286
|
+
onSelectedPathsChange: we,
|
|
287
|
+
navigationPanelOptions: {
|
|
288
|
+
searchable: !0,
|
|
289
|
+
placeholder: d.searchPlaceholderByTab?.[W]
|
|
290
|
+
},
|
|
291
|
+
hideSearchPathItemName: !0,
|
|
292
|
+
onSearchFiles: ze,
|
|
293
|
+
searchInProgress: Be,
|
|
294
|
+
searchResults: Ve ?? [],
|
|
295
|
+
clearSearchResults: He,
|
|
296
|
+
gridOptions: ht,
|
|
297
|
+
treeOptions: gt,
|
|
298
|
+
onFolderPopupPathChange: Ge,
|
|
299
|
+
toolbarOptions: vt,
|
|
300
|
+
bulkActionsToolbarOptions: yt,
|
|
301
|
+
autoSelectUploadedItems: Ee,
|
|
302
|
+
emptyStateTitle: Mt.title,
|
|
303
|
+
emptyStateDescription: Mt.description,
|
|
304
|
+
searchEmptyStateTitle: d.searchEmptyStateTitle,
|
|
305
|
+
uploadEnabled: N,
|
|
306
|
+
sharedWithMeIds: ot,
|
|
307
|
+
sharedByMePaths: B,
|
|
308
|
+
onUnshareFiles: st,
|
|
309
|
+
onRemoveFilesAccess: lt,
|
|
310
|
+
fileMetadataPopupOptions: jt,
|
|
311
|
+
onGetInfo: dt,
|
|
312
|
+
onPreview: je,
|
|
313
|
+
onTableFileClick: Me,
|
|
314
|
+
previewExtensions: Ne,
|
|
315
|
+
onUploadFiles: Ke,
|
|
316
|
+
onUploadArchive: qe,
|
|
317
|
+
onValidateUpload: Je,
|
|
318
|
+
onCreateFolder: Ye,
|
|
319
|
+
onCreateFolderValidate: Xe,
|
|
320
|
+
onDownloadFiles: Ze,
|
|
321
|
+
onDeleteFiles: Qe,
|
|
322
|
+
onMoveToFiles: et,
|
|
323
|
+
onCopyFiles: rt,
|
|
324
|
+
onRenameValidate: tt,
|
|
325
|
+
renameValidationMessages: d.renameValidationMessages,
|
|
326
|
+
isRenameFileAvailable: N,
|
|
327
|
+
deleteConfirmationOptions: bt,
|
|
328
|
+
conflictResolutionPopupOptions: d.conflictResolutionPopupOptions,
|
|
329
|
+
destinationFolderPopupOptions: Ct,
|
|
330
|
+
forbiddenSymbolsRegExp: pe,
|
|
331
|
+
forbiddenSymbolsTooltip: d.forbiddenSymbolsTooltip,
|
|
332
|
+
getDisabledTooltip: ke,
|
|
333
|
+
unsupportedFileTypeTooltip: Ae
|
|
334
|
+
}),
|
|
335
|
+
/* @__PURE__ */ c(de, {
|
|
336
|
+
visuallyHidden: !0,
|
|
337
|
+
as: fe.Span,
|
|
338
|
+
children: $ ?? ""
|
|
339
|
+
}),
|
|
340
|
+
$ != null && /* @__PURE__ */ c("div", {
|
|
341
|
+
className: e("absolute inset-0 z-52 flex items-center justify-center desktop:p-4", i.overlay),
|
|
342
|
+
children: /* @__PURE__ */ c(me, {
|
|
343
|
+
size: 32,
|
|
344
|
+
fullWidth: !1,
|
|
345
|
+
ariaLabel: $
|
|
346
|
+
})
|
|
293
347
|
})
|
|
294
|
-
|
|
295
|
-
}) : /* @__PURE__ */
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
348
|
+
]
|
|
349
|
+
}) : /* @__PURE__ */ c("div", {
|
|
350
|
+
className: "p-6",
|
|
351
|
+
children: /* @__PURE__ */ c(ue, {
|
|
352
|
+
message: d.errorMessage,
|
|
353
|
+
action: /* @__PURE__ */ c(se, {
|
|
354
|
+
variant: a.Neutral,
|
|
355
|
+
appearance: ce.Outlined,
|
|
356
|
+
size: le.Small,
|
|
357
|
+
label: d.retryLabel,
|
|
358
|
+
onClick: Re
|
|
359
|
+
})
|
|
360
|
+
})
|
|
302
361
|
}),
|
|
303
|
-
/* @__PURE__ */
|
|
304
|
-
className: "fixed
|
|
305
|
-
children: /* @__PURE__ */
|
|
306
|
-
title:
|
|
307
|
-
items:
|
|
308
|
-
onClose:
|
|
309
|
-
onCancelItem:
|
|
310
|
-
labels:
|
|
362
|
+
/* @__PURE__ */ c("div", {
|
|
363
|
+
className: "fixed inset-e-4 bottom-4 z-51",
|
|
364
|
+
children: /* @__PURE__ */ c(he, {
|
|
365
|
+
title: kt,
|
|
366
|
+
items: Et,
|
|
367
|
+
onClose: wt,
|
|
368
|
+
onCancelItem: Tt,
|
|
369
|
+
labels: At
|
|
311
370
|
})
|
|
312
371
|
}),
|
|
313
|
-
(
|
|
314
|
-
title:
|
|
315
|
-
text:
|
|
316
|
-
cancelLabel:
|
|
317
|
-
onCancel:
|
|
372
|
+
(it || M) && /* @__PURE__ */ c(ne, {
|
|
373
|
+
title: M ? d.operationLoaderMoveTitle : d.operationLoaderCopyTitle,
|
|
374
|
+
text: M ? d.movingLabel : d.copyingLabel,
|
|
375
|
+
cancelLabel: d.operationLoaderCancelLabel,
|
|
376
|
+
onCancel: at,
|
|
377
|
+
colors: b?.operationLoader,
|
|
378
|
+
textClassName: b?.operationLoaderTextClassName
|
|
318
379
|
})
|
|
319
380
|
] });
|
|
320
381
|
};
|
|
321
|
-
|
|
382
|
+
o(d);
|
|
322
383
|
//#endregion
|
|
323
|
-
export {
|
|
384
|
+
export { d as DialFileManagerShell };
|