@epam/ai-dial-ui-kit 0.15.0-dev.5 → 0.15.0-dev.50
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 +194 -1
- package/dist/CHANGELOG.md +86 -0
- package/dist/{DateCellRenderer-BVM-Q8yx.cjs → DateCellRenderer-CZNa4jVJ.cjs} +31 -31
- package/dist/DateCellRenderer-X6vXPDIG.cjs +1 -0
- package/dist/IconButton-DHOFapLo.cjs +1 -0
- package/dist/JsonEditor-Bxui5wJH.cjs +1 -0
- package/dist/{MarkdownEditor-C9-ZMRVi.cjs → MarkdownEditor-BKtFs714.cjs} +1 -1
- package/dist/MarkdownEditor-Bapd1ycU.cjs +1 -0
- package/dist/MarkdownEditorContainer-B5aHwoYF.cjs +1 -0
- package/dist/{Switch-CUKClcEz.cjs → Switch-DE6MrcqJ.cjs} +1 -1
- package/dist/components/Button/constants.js +9 -8
- package/dist/components/Dropdown/Dropdown.js +70 -65
- package/dist/components/Dropdown/DropdownSubMenuItem.js +63 -55
- package/dist/components/Dropdown/constants.js +16 -14
- package/dist/components/DropdownIcon/DropdownIcon.js +43 -32
- package/dist/components/FileManager/FileManager.js +373 -372
- package/dist/components/FileManager/FileManagerProvider.js +266 -264
- package/dist/components/FileManager/hooks/use-grid-context-menu.js +59 -59
- package/dist/components/MarkdownEditor/MarkdownEditor.js +23 -21
- package/dist/components/MarkdownEditor/MarkdownEditorContainer.js +27 -27
- package/dist/components/New/Accordion/Accordion.js +87 -71
- package/dist/components/New/AutocompleteTagInput/AutocompleteTagInput.js +207 -0
- package/dist/components/New/AutocompleteTagInput/utils.js +11 -0
- package/dist/components/New/Avatar/Avatar.js +70 -0
- package/dist/components/New/Badge/Badge.js +45 -0
- package/dist/components/New/BottomSheet/BottomSheet.js +128 -0
- package/dist/components/New/Breadcrumbs/Breadcrumbs.js +159 -0
- package/dist/components/New/Breadcrumbs/constants.js +41 -0
- package/dist/components/New/Button/Button.js +32 -32
- package/dist/components/New/Button/ButtonWrappers.js +103 -37
- package/dist/components/New/Button/constants.js +3 -0
- package/dist/components/New/Button/utils.js +18 -8
- package/dist/components/New/ButtonDropdown/ButtonDropdown.js +26 -16
- package/dist/components/New/Calendar/Calendar.js +253 -222
- package/dist/components/New/Calendar/constants.js +5 -5
- package/dist/components/New/CaptionText/CaptionText.js +18 -15
- package/dist/components/New/CardShell/CardShell.js +5 -3
- package/dist/components/New/Checkbox/Checkbox.js +67 -56
- package/dist/components/New/Checkbox/CheckboxBox.js +5 -3
- package/dist/components/New/CloseButton/CloseButton.js +18 -16
- package/dist/components/New/CollapsibleSidebar/CollapsibleSidebar.js +39 -34
- package/dist/components/New/ConfirmationPopup/ConfirmationPopup.js +38 -37
- package/dist/components/New/ConfirmationPopup/constants.js +8 -11
- package/dist/components/New/Dropdown/Dropdown.js +112 -105
- package/dist/components/New/Dropdown/DropdownSubMenuItem.js +17 -17
- package/dist/components/New/Dropdown/constants.js +22 -17
- package/dist/components/New/EllipsisTooltip/EllipsisTooltip.js +20 -18
- package/dist/components/New/EntityIdentity/EntityIdentity.js +135 -0
- package/dist/components/New/FileDropzone/FileDropzone.js +27 -25
- package/dist/components/New/FileIcon/FileIcon.js +55 -0
- package/dist/components/New/FileIcon/constants.js +134 -0
- package/dist/components/New/FileIcon/icons/FileGlyph.js +150 -0
- package/dist/components/New/FileIcon/icons/FolderGlyph.js +50 -0
- package/dist/components/New/FileName/FileName.js +78 -0
- package/dist/components/New/FilterChips/FilterChips.js +43 -0
- package/dist/components/New/FilterChips/constants.js +5 -0
- package/dist/components/New/FolderName/FolderName.js +16 -0
- package/dist/components/New/FolderPath/FolderPath.js +29 -28
- package/dist/components/New/Highlight/Highlight.js +23 -30
- package/dist/components/New/IconButton/IconButton.js +30 -28
- package/dist/components/New/InfoButton/InfoButton.js +13 -11
- package/dist/components/New/InlineSelect/InlineSelect.js +74 -56
- package/dist/components/New/InteractiveTooltip/InteractiveTooltip.js +41 -39
- package/dist/components/New/InteractiveTooltip/constants.js +2 -2
- package/dist/components/New/Label/Label.js +13 -8
- package/dist/components/New/MarkdownEditor/MarkdownEditor.js +29 -27
- package/dist/components/New/MenuItem/MenuItem.js +29 -27
- package/dist/components/New/MenuItem/constants.js +9 -8
- package/dist/components/New/NoDataContent/NoDataContent.js +21 -19
- package/dist/components/New/Notification/Notification.js +33 -29
- package/dist/components/New/NumberInput/NumberInput.js +42 -33
- package/dist/components/New/PasswordInput/PasswordInput.js +41 -35
- package/dist/components/New/Popup/Popup.js +46 -44
- package/dist/components/New/Popup/constants.js +3 -3
- package/dist/components/New/Radio/Radio.js +75 -64
- package/dist/components/New/RadioGroup/RadioGroup.js +76 -65
- package/dist/components/New/RadioGroupPopupField/RadioGroupPopupField.js +117 -106
- package/dist/components/New/ResizableContainer/ResizableContainer.js +42 -40
- package/dist/components/New/SchemaRenderer/SchemaRenderer.js +164 -0
- package/dist/components/New/SchemaRenderer/components/SchemaAnyOfEditor.js +65 -0
- package/dist/components/New/SchemaRenderer/components/SchemaArrayEditor.js +109 -0
- package/dist/components/New/SchemaRenderer/components/SchemaField.js +83 -0
- package/dist/components/New/SchemaRenderer/components/SchemaFieldContent.js +72 -0
- package/dist/components/New/SchemaRenderer/components/SchemaJsonEditor.js +41 -0
- package/dist/components/New/SchemaRenderer/components/SchemaKeyValueEditor.js +250 -0
- package/dist/components/New/SchemaRenderer/components/SchemaObjectEditor.js +36 -0
- package/dist/components/New/SchemaRenderer/components/SchemaOneOfEditor.js +163 -0
- package/dist/components/New/SchemaRenderer/components/SchemaPrimitiveField.js +150 -0
- package/dist/components/New/SchemaRenderer/components/SchemaSection.js +135 -0
- package/dist/components/New/SchemaRenderer/context.js +17 -0
- package/dist/components/New/Search/Search.js +29 -27
- package/dist/components/New/SegmentedControl/SegmentedControl.js +29 -23
- package/dist/components/New/Select/CollapsedSelectTags.js +127 -0
- package/dist/components/New/Select/MultiSelectTags.js +18 -15
- package/dist/components/New/Select/Select.js +219 -197
- package/dist/components/New/Select/constants.js +23 -20
- package/dist/components/New/SharedEntityIndicator/SharedEntityIndicator.js +34 -0
- package/dist/components/New/SideDrawer/SideDrawer.js +148 -0
- package/dist/components/New/Slider/Slider.js +151 -90
- package/dist/components/New/Slider/utils.js +12 -0
- package/dist/components/New/Switch/Switch.js +69 -58
- package/dist/components/New/Tabs/Tabs.js +125 -61
- package/dist/components/New/Tag/Tag.js +42 -40
- package/dist/components/New/TagInput/TagInput.js +48 -44
- package/dist/components/New/Textarea/Textarea.js +21 -20
- package/dist/components/New/ToggleIconButton/ToggleIconButton.js +26 -24
- package/dist/components/New/Tooltip/TooltipContent.js +11 -9
- package/dist/components/New/Tooltip/constants.js +1 -1
- package/dist/components/New/TransferQueue/TransferQueue.js +124 -0
- package/dist/components/New/TransferQueue/TransferQueueHeader.js +71 -0
- package/dist/components/New/TransferQueue/TransferQueueRow.js +119 -0
- package/dist/components/New/TransferQueue/constants.js +24 -0
- package/dist/components/New/constants/overlay.js +17 -9
- package/dist/components/Popup/constants.js +8 -8
- package/dist/components/ProgressBar/ProgressBar.js +45 -33
- package/dist/components/SchemaRenderer/SchemaRenderer.js +16 -15
- package/dist/components/SchemaRenderer/components/SchemaAdditionalPropertiesEditor.js +46 -31
- package/dist/components/SchemaRenderer/components/SchemaAnyOfEditor.js +2 -2
- package/dist/components/SchemaRenderer/components/SchemaArrayEditor.js +1 -1
- package/dist/components/SchemaRenderer/components/SchemaField.js +23 -23
- package/dist/components/SchemaRenderer/components/SchemaFieldContent.js +19 -19
- package/dist/components/SchemaRenderer/components/SchemaKeyValueEditor.js +223 -135
- package/dist/components/SchemaRenderer/components/SchemaObjectEditor.js +1 -1
- package/dist/components/SchemaRenderer/components/SchemaOneOfEditor.js +13 -13
- package/dist/components/SchemaRenderer/components/SchemaPrimitiveField.js +5 -5
- package/dist/components/Skeleton/Skeleton.js +25 -19
- package/dist/components/Spinner/Spinner.js +7 -5
- package/dist/components/Tooltip/TooltipContent.js +11 -11
- package/dist/components-manifest.json +1837 -84
- package/dist/constants/public-class-names.js +218 -0
- package/dist/constants/schema-renderer.js +33 -0
- package/dist/dial-ui-kit.cjs +2 -2
- package/dist/dial-ui-kit.js +356 -307
- package/dist/editors.cjs +1 -1
- package/dist/file-manager.cjs +1 -1
- package/dist/grid.cjs +1 -1
- package/dist/index.css +2 -2
- package/dist/lazy-_W6FYhKg.cjs +1 -0
- package/dist/merge-classes-BEJXjzkx.cjs +1 -0
- package/dist/migration-guides/0.15.0/legacy-theme-variable-fallbacks-removal.md +69 -0
- package/dist/migration-guides/0.15.0/slider-redesign.md +110 -0
- package/dist/migration-guides/README.md +2 -0
- package/dist/node_modules/tailwind-merge/dist/bundle-mjs.js +419 -399
- package/dist/src/components/FileManager/FileManager.d.ts +2 -0
- package/dist/src/components/FileManager/FileManagerContext.d.ts +1 -0
- package/dist/src/components/FileManager/hooks/use-grid-context-menu.d.ts +2 -1
- package/dist/src/components/MarkdownEditor/MarkdownEditor.d.ts +2 -0
- package/dist/src/components/MarkdownEditor/MarkdownEditorContainer.d.ts +2 -0
- package/dist/src/components/New/Accordion/Accordion.d.ts +6 -1
- package/dist/src/components/New/AutocompleteTagInput/AutocompleteTagInput.d.ts +97 -0
- package/dist/src/components/New/AutocompleteTagInput/utils.d.ts +17 -0
- package/dist/src/components/New/AutocompleteTagInput/utils.spec.d.ts +1 -0
- package/dist/src/components/New/Avatar/Avatar.d.ts +55 -0
- package/dist/src/components/New/Badge/Badge.d.ts +47 -0
- package/dist/src/components/New/BottomSheet/BottomSheet.d.ts +84 -0
- package/dist/src/components/New/Breadcrumbs/Breadcrumbs.d.ts +94 -0
- package/dist/src/components/New/Breadcrumbs/constants.d.ts +60 -0
- package/dist/src/components/New/Button/Button.d.ts +4 -1
- package/dist/src/components/New/Button/ButtonWrappers.d.ts +21 -0
- package/dist/src/components/New/Button/utils.d.ts +15 -0
- package/dist/src/components/New/ButtonDropdown/ButtonDropdown.d.ts +4 -0
- package/dist/src/components/New/Calendar/constants.d.ts +1 -1
- package/dist/src/components/New/ConfirmationPopup/constants.d.ts +0 -1
- package/dist/src/components/New/Dropdown/Dropdown.d.ts +9 -1
- package/dist/src/components/New/Dropdown/constants.d.ts +3 -0
- package/dist/src/components/New/EntityIdentity/EntityIdentity.d.ts +85 -0
- package/dist/src/components/New/FileIcon/FileIcon.d.ts +61 -0
- package/dist/src/components/New/FileIcon/constants.d.ts +16 -0
- package/dist/src/components/New/FileIcon/icons/FileGlyph.d.ts +18 -0
- package/dist/src/components/New/FileIcon/icons/FolderGlyph.d.ts +17 -0
- package/dist/src/components/New/FileName/FileName.d.ts +79 -0
- package/dist/src/components/New/FilterChips/FilterChips.d.ts +69 -0
- package/dist/src/components/New/FilterChips/constants.d.ts +13 -0
- package/dist/src/components/New/FolderName/FolderName.d.ts +37 -0
- package/dist/src/components/New/InlineSelect/InlineSelect.d.ts +16 -1
- package/dist/src/components/New/InteractiveTooltip/constants.d.ts +5 -4
- package/dist/src/components/New/MarkdownEditor/MarkdownEditor.d.ts +3 -0
- package/dist/src/components/New/Notification/Notification.d.ts +18 -0
- package/dist/src/components/New/Popup/constants.d.ts +1 -1
- package/dist/src/components/New/SchemaRenderer/SchemaRenderer.d.ts +38 -0
- package/dist/src/components/New/SchemaRenderer/components/SchemaAnyOfEditor.d.ts +37 -0
- package/dist/src/components/New/SchemaRenderer/components/SchemaArrayEditor.d.ts +35 -0
- package/dist/src/components/New/SchemaRenderer/components/SchemaField.d.ts +33 -0
- package/dist/src/components/New/SchemaRenderer/components/SchemaFieldContent.d.ts +30 -0
- package/dist/src/components/New/SchemaRenderer/components/SchemaJsonEditor.d.ts +29 -0
- package/dist/src/components/New/SchemaRenderer/components/SchemaKeyValueEditor.d.ts +37 -0
- package/dist/src/components/New/SchemaRenderer/components/SchemaObjectEditor.d.ts +32 -0
- package/dist/src/components/New/SchemaRenderer/components/SchemaOneOfEditor.d.ts +39 -0
- package/dist/src/components/New/SchemaRenderer/components/SchemaPrimitiveField.d.ts +38 -0
- package/dist/src/components/New/SchemaRenderer/components/SchemaSection.d.ts +39 -0
- package/dist/src/components/New/SchemaRenderer/context.d.ts +8 -0
- package/dist/src/components/New/SchemaRenderer/types.d.ts +76 -0
- package/dist/src/components/New/Select/CollapsedSelectTags.d.ts +22 -0
- package/dist/src/components/New/Select/MultiSelectTags.d.ts +5 -0
- package/dist/src/components/New/Select/Select.d.ts +9 -0
- package/dist/src/components/New/Select/constants.d.ts +3 -2
- package/dist/src/components/New/SharedEntityIndicator/SharedEntityIndicator.d.ts +35 -0
- package/dist/src/components/New/SideDrawer/SideDrawer.d.ts +100 -0
- package/dist/src/components/New/Slider/Slider.d.ts +20 -1
- package/dist/src/components/New/Slider/utils.d.ts +6 -0
- package/dist/src/components/New/Slider/utils.spec.d.ts +1 -0
- package/dist/src/components/New/Tabs/Tabs.d.ts +54 -6
- package/dist/src/components/New/Tooltip/constants.d.ts +5 -3
- package/dist/src/components/New/TransferQueue/TransferQueue.d.ts +139 -0
- package/dist/src/components/New/TransferQueue/TransferQueueHeader.d.ts +16 -0
- package/dist/src/components/New/TransferQueue/TransferQueueRow.d.ts +10 -0
- package/dist/src/components/New/TransferQueue/constants.d.ts +6 -0
- package/dist/src/components/New/constants/overlay.d.ts +13 -0
- package/dist/src/components/Popup/constants.d.ts +1 -1
- package/dist/src/components/SchemaRenderer/types.d.ts +5 -82
- package/dist/src/components/SchemaRenderer/utils.d.ts +1 -13
- package/dist/src/constants/public-class-names.d.ts +209 -0
- package/dist/src/constants/schema-renderer.d.ts +2 -0
- package/dist/src/index.d.ts +39 -2
- package/dist/src/models/json-schema.d.ts +71 -0
- package/dist/src/types/accordion.d.ts +7 -0
- package/dist/src/types/avatar.d.ts +7 -0
- package/dist/src/types/badge.d.ts +16 -0
- package/dist/src/types/breadcrumbs.d.ts +9 -0
- package/dist/src/types/button.d.ts +1 -0
- package/dist/src/types/entity-type.d.ts +9 -0
- package/dist/src/types/json-schema.d.ts +22 -0
- package/dist/src/types/transfer-queue.d.ts +10 -0
- package/dist/src/utils/__tests__/avatar.spec.d.ts +1 -0
- package/dist/src/utils/avatar.d.ts +12 -0
- package/dist/src/utils/json-schema.d.ts +23 -0
- package/dist/src/utils/sub-menu-floating.d.ts +7 -4
- package/dist/types/accordion.js +4 -0
- package/dist/types/avatar.js +4 -0
- package/dist/types/badge.js +5 -0
- package/dist/types/breadcrumbs.js +4 -0
- package/dist/types/button.js +3 -3
- package/dist/types/entity-type.js +4 -0
- package/dist/types/json-schema.js +7 -0
- package/dist/types/transfer-queue.js +4 -0
- package/dist/use-file-manager-tabs-Bzzwwcgk.cjs +3 -0
- package/dist/utils/avatar.js +22 -0
- package/dist/{components/SchemaRenderer/utils.js → utils/json-schema.js} +122 -95
- package/dist/utils/merge-classes.js +12 -5
- package/dist/utils/sub-menu-floating.js +99 -54
- package/package.json +4 -9
- package/dist/DateCellRenderer-ssp7eaZY.cjs +0 -1
- package/dist/IconButton-DWqoaBWf.cjs +0 -1
- package/dist/JsonEditor-D2jSlRFi.cjs +0 -1
- package/dist/MarkdownEditor-BzEbdj7R.cjs +0 -1
- package/dist/MarkdownEditorContainer-BvwJjkiZ.cjs +0 -1
- package/dist/components/SchemaRenderer/types.js +0 -27
- package/dist/editor-_174x-qy.cjs +0 -1
- package/dist/lazy-DM-7dL0Y.cjs +0 -1
- package/dist/merge-classes-Dipy1Ih1.cjs +0 -1
- package/dist/use-file-manager-tabs-DjdR_mYM.cjs +0 -3
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { jsx as a } from "react/jsx-runtime";
|
|
2
2
|
import "react";
|
|
3
3
|
import { mergeClasses as t } from "../../../utils/merge-classes.js";
|
|
4
|
-
|
|
4
|
+
import { DIAL_KIT_CLASS as s } from "../../../constants/public-class-names.js";
|
|
5
|
+
const m = ({
|
|
5
6
|
className: r,
|
|
6
7
|
children: e,
|
|
7
8
|
...o
|
|
@@ -12,11 +13,12 @@ const i = ({
|
|
|
12
13
|
className: t(
|
|
13
14
|
"relative flex flex-col gap-3 rounded-[20px] border-2 border-transparent p-5",
|
|
14
15
|
"bg-layer-raised shadow-md transition-[transform,box-shadow] duration-200 ease-out hover:-translate-y-[3px] hover:shadow-lg motion-reduce:transition-none motion-reduce:hover:translate-y-0",
|
|
15
|
-
r
|
|
16
|
+
r,
|
|
17
|
+
s.cardShell
|
|
16
18
|
),
|
|
17
19
|
children: e
|
|
18
20
|
}
|
|
19
21
|
);
|
|
20
22
|
export {
|
|
21
|
-
|
|
23
|
+
m as CardShell
|
|
22
24
|
};
|
|
@@ -3,26 +3,27 @@ import { useId as u, useCallback as x } from "react";
|
|
|
3
3
|
import { ElementSize as v } from "../../../types/size.js";
|
|
4
4
|
import { mergeClasses as f } from "../../../utils/merge-classes.js";
|
|
5
5
|
import { resolveAccessibleName as C } from "../../../utils/accessible-name.js";
|
|
6
|
-
import { Label as
|
|
7
|
-
import { CheckboxBox as
|
|
8
|
-
|
|
6
|
+
import { Label as I } from "../Label/Label.js";
|
|
7
|
+
import { CheckboxBox as A } from "./CheckboxBox.js";
|
|
8
|
+
import { DIAL_KIT_CLASS as L } from "../../../constants/public-class-names.js";
|
|
9
|
+
const D = ({
|
|
9
10
|
id: h,
|
|
10
11
|
labelProps: e,
|
|
11
12
|
isSelected: t = !1,
|
|
12
13
|
isIndeterminate: r = !1,
|
|
13
14
|
invalid: i = !1,
|
|
14
15
|
disabled: s,
|
|
15
|
-
onChange:
|
|
16
|
-
caption:
|
|
16
|
+
onChange: l,
|
|
17
|
+
caption: m,
|
|
17
18
|
className: y,
|
|
18
19
|
boxClassName: b,
|
|
19
20
|
...n
|
|
20
21
|
}) => {
|
|
21
|
-
const
|
|
22
|
+
const k = u(), a = h ?? k, d = m ? `${a}-caption` : void 0, g = x(
|
|
22
23
|
(o) => {
|
|
23
|
-
|
|
24
|
+
l?.(o.target.checked);
|
|
24
25
|
},
|
|
25
|
-
[
|
|
26
|
+
[l]
|
|
26
27
|
), N = x(
|
|
27
28
|
(o) => {
|
|
28
29
|
o && (o.indeterminate = r);
|
|
@@ -30,63 +31,73 @@ const T = ({
|
|
|
30
31
|
[r]
|
|
31
32
|
);
|
|
32
33
|
return /* @__PURE__ */ p("div", { className: "flex flex-col gap-1", children: [
|
|
33
|
-
/* @__PURE__ */ p(
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
34
|
+
/* @__PURE__ */ p(
|
|
35
|
+
"div",
|
|
36
|
+
{
|
|
37
|
+
className: f(
|
|
38
|
+
"flex items-center gap-2",
|
|
39
|
+
y,
|
|
40
|
+
L.checkbox
|
|
41
|
+
),
|
|
42
|
+
children: [
|
|
43
|
+
/* @__PURE__ */ c(
|
|
44
|
+
"input",
|
|
45
|
+
{
|
|
46
|
+
...n,
|
|
47
|
+
ref: N,
|
|
48
|
+
type: "checkbox",
|
|
49
|
+
id: a,
|
|
50
|
+
checked: t,
|
|
51
|
+
disabled: s,
|
|
52
|
+
onChange: g,
|
|
53
|
+
"aria-checked": r ? "mixed" : t,
|
|
54
|
+
"aria-invalid": i || void 0,
|
|
55
|
+
"aria-label": C(
|
|
56
|
+
typeof e?.label != "string" ? n["aria-label"] : void 0
|
|
57
|
+
),
|
|
58
|
+
"aria-describedby": d,
|
|
59
|
+
className: "peer sr-only"
|
|
60
|
+
}
|
|
61
|
+
),
|
|
62
|
+
/* @__PURE__ */ c(
|
|
63
|
+
A,
|
|
64
|
+
{
|
|
65
|
+
htmlFor: a,
|
|
66
|
+
isSelected: t,
|
|
67
|
+
isIndeterminate: r,
|
|
68
|
+
invalid: i,
|
|
69
|
+
disabled: s,
|
|
70
|
+
className: b
|
|
71
|
+
}
|
|
48
72
|
),
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
),
|
|
64
|
-
e && /* @__PURE__ */ c(
|
|
65
|
-
j,
|
|
66
|
-
{
|
|
67
|
-
size: v.Standard,
|
|
68
|
-
...e,
|
|
69
|
-
htmlFor: a,
|
|
70
|
-
className: f(
|
|
71
|
-
// `Label` defaults to the secondary colour; a checkbox's own label
|
|
72
|
-
// is primary while the control is usable.
|
|
73
|
-
"py-[1px]",
|
|
74
|
-
s ? "cursor-not-allowed text-control-disable-primary" : "cursor-pointer text-primary",
|
|
75
|
-
e.className
|
|
73
|
+
e && /* @__PURE__ */ c(
|
|
74
|
+
I,
|
|
75
|
+
{
|
|
76
|
+
size: v.Standard,
|
|
77
|
+
...e,
|
|
78
|
+
htmlFor: a,
|
|
79
|
+
className: f(
|
|
80
|
+
// `Label` defaults to the secondary colour; a checkbox's own label
|
|
81
|
+
// is primary while the control is usable.
|
|
82
|
+
"py-[1px]",
|
|
83
|
+
s ? "cursor-not-allowed text-control-disable-primary" : "cursor-pointer text-primary",
|
|
84
|
+
e.className
|
|
85
|
+
)
|
|
86
|
+
}
|
|
76
87
|
)
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
88
|
+
]
|
|
89
|
+
}
|
|
90
|
+
),
|
|
91
|
+
m && /* @__PURE__ */ c(
|
|
81
92
|
"span",
|
|
82
93
|
{
|
|
83
94
|
id: d,
|
|
84
95
|
className: "dial-tiny-text text-secondary ml-[28px]",
|
|
85
|
-
children:
|
|
96
|
+
children: m
|
|
86
97
|
}
|
|
87
98
|
)
|
|
88
99
|
] });
|
|
89
100
|
};
|
|
90
101
|
export {
|
|
91
|
-
|
|
102
|
+
D as Checkbox
|
|
92
103
|
};
|
|
@@ -2,7 +2,8 @@ import { jsx as t } from "react/jsx-runtime";
|
|
|
2
2
|
import { IconMinus as u, IconCheck as d } from "@tabler/icons-react";
|
|
3
3
|
import { mergeClasses as b } from "../../../utils/merge-classes.js";
|
|
4
4
|
import { CHECKBOX_ICON_PROPS as p } from "./constants.js";
|
|
5
|
-
|
|
5
|
+
import { DIAL_KIT_CLASS as f } from "../../../constants/public-class-names.js";
|
|
6
|
+
const v = ({
|
|
6
7
|
isSelected: n = !1,
|
|
7
8
|
isIndeterminate: c = !1,
|
|
8
9
|
invalid: r = !1,
|
|
@@ -25,10 +26,11 @@ const C = ({
|
|
|
25
26
|
!r && !o && "border-default bg-control-neutral hover:border-accent hover:bg-control-accent-alpha-hover"
|
|
26
27
|
),
|
|
27
28
|
a ? "cursor-not-allowed" : e && "cursor-pointer",
|
|
28
|
-
m
|
|
29
|
+
m,
|
|
30
|
+
f.checkboxBox
|
|
29
31
|
), i = c ? /* @__PURE__ */ t(u, { ...p }) : n && /* @__PURE__ */ t(d, { ...p });
|
|
30
32
|
return e ? /* @__PURE__ */ t("label", { htmlFor: s, className: l, children: i }) : /* @__PURE__ */ t("span", { "aria-hidden": "true", className: l, children: i });
|
|
31
33
|
};
|
|
32
34
|
export {
|
|
33
|
-
|
|
35
|
+
v as CheckboxBox
|
|
34
36
|
};
|
|
@@ -1,27 +1,29 @@
|
|
|
1
1
|
import { jsx as r } from "react/jsx-runtime";
|
|
2
|
-
import { IconX as
|
|
2
|
+
import { IconX as n } from "@tabler/icons-react";
|
|
3
3
|
import { DIAL_KIT_ICON_STROKE as a } from "../constants/icon.js";
|
|
4
|
-
import { DIAL_ICON_SIZE as
|
|
5
|
-
import { ElementSize as
|
|
6
|
-
import { GhostIconButton as
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
4
|
+
import { DIAL_ICON_SIZE as m } from "../../../constants/icon.js";
|
|
5
|
+
import { ElementSize as t } from "../../../types/size.js";
|
|
6
|
+
import { GhostIconButton as I } from "../IconButton/IconButtonWrappers.js";
|
|
7
|
+
import { DIAL_KIT_CLASS as p } from "../../../constants/public-class-names.js";
|
|
8
|
+
import { mergeClasses as f } from "../../../utils/merge-classes.js";
|
|
9
|
+
const B = ({
|
|
10
|
+
ariaLabel: e = "Close",
|
|
11
|
+
className: i,
|
|
12
|
+
size: o = t.Small,
|
|
11
13
|
onClose: l,
|
|
12
|
-
...
|
|
14
|
+
...s
|
|
13
15
|
}) => /* @__PURE__ */ r(
|
|
14
|
-
|
|
16
|
+
I,
|
|
15
17
|
{
|
|
16
|
-
...
|
|
18
|
+
...s,
|
|
17
19
|
size: o,
|
|
18
|
-
"aria-label":
|
|
19
|
-
className:
|
|
20
|
+
"aria-label": e,
|
|
21
|
+
className: f(i, p.closeButton),
|
|
20
22
|
onClick: l,
|
|
21
23
|
icon: /* @__PURE__ */ r(
|
|
22
|
-
|
|
24
|
+
n,
|
|
23
25
|
{
|
|
24
|
-
size: o ===
|
|
26
|
+
size: o === t.Small ? m.SM : m.MD,
|
|
25
27
|
stroke: a,
|
|
26
28
|
"aria-hidden": "true"
|
|
27
29
|
}
|
|
@@ -29,5 +31,5 @@ const u = ({
|
|
|
29
31
|
}
|
|
30
32
|
);
|
|
31
33
|
export {
|
|
32
|
-
|
|
34
|
+
B as CloseButton
|
|
33
35
|
};
|
|
@@ -1,39 +1,44 @@
|
|
|
1
1
|
import { jsxs as l, jsx as t } from "react/jsx-runtime";
|
|
2
|
-
import { useState as
|
|
3
|
-
import { IconChevronsLeft as
|
|
2
|
+
import { useState as j, useId as w } from "react";
|
|
3
|
+
import { IconChevronsLeft as E, IconChevronsRight as O } from "@tabler/icons-react";
|
|
4
4
|
import { DIAL_KIT_ICON_STROKE as d } from "../constants/icon.js";
|
|
5
5
|
import { DIAL_ICON_SIZE as p } from "../../../constants/icon.js";
|
|
6
|
-
import { ButtonAppearance as
|
|
7
|
-
import { ElementSize as
|
|
6
|
+
import { ButtonAppearance as k, ButtonVariant as z } from "../../../types/button.js";
|
|
7
|
+
import { ElementSize as T } from "../../../types/size.js";
|
|
8
8
|
import { mergeClasses as r } from "../../../utils/merge-classes.js";
|
|
9
|
-
import { IconButton as
|
|
10
|
-
|
|
9
|
+
import { IconButton as B } from "../IconButton/IconButton.js";
|
|
10
|
+
import { DIAL_KIT_CLASS as K } from "../../../constants/public-class-names.js";
|
|
11
|
+
const P = 48, J = ({
|
|
11
12
|
children: c,
|
|
12
13
|
title: m,
|
|
13
14
|
width: f = 280,
|
|
14
|
-
collapsedWidth:
|
|
15
|
+
collapsedWidth: b = P,
|
|
15
16
|
isOpened: o,
|
|
16
|
-
defaultOpened:
|
|
17
|
-
onToggle:
|
|
18
|
-
additionalButtons:
|
|
19
|
-
ariaLabel:
|
|
20
|
-
collapseLabel:
|
|
21
|
-
expandLabel:
|
|
22
|
-
className:
|
|
23
|
-
titleClassName:
|
|
24
|
-
contentClassName:
|
|
25
|
-
footerClassName:
|
|
17
|
+
defaultOpened: h = !0,
|
|
18
|
+
onToggle: x,
|
|
19
|
+
additionalButtons: I,
|
|
20
|
+
ariaLabel: u = "Sidebar",
|
|
21
|
+
collapseLabel: C = "Collapse sidebar",
|
|
22
|
+
expandLabel: S = "Expand sidebar",
|
|
23
|
+
className: y,
|
|
24
|
+
titleClassName: v,
|
|
25
|
+
contentClassName: L,
|
|
26
|
+
footerClassName: _
|
|
26
27
|
}) => {
|
|
27
|
-
const i = o !== void 0, [
|
|
28
|
+
const i = o !== void 0, [g, D] = j(h), e = i ? o : g, a = `collapsible-sidebar-content-${w()}`, n = e ? C : S, A = (N) => {
|
|
28
29
|
const s = !e;
|
|
29
|
-
i ||
|
|
30
|
+
i || D(s), x?.(s, N);
|
|
30
31
|
};
|
|
31
32
|
return /* @__PURE__ */ l(
|
|
32
33
|
"aside",
|
|
33
34
|
{
|
|
34
|
-
"aria-label":
|
|
35
|
-
style: { width: `${e ? f :
|
|
36
|
-
className: r(
|
|
35
|
+
"aria-label": u,
|
|
36
|
+
style: { width: `${e ? f : b}px` },
|
|
37
|
+
className: r(
|
|
38
|
+
"flex flex-col justify-between",
|
|
39
|
+
y,
|
|
40
|
+
K.collapsibleSidebar
|
|
41
|
+
),
|
|
37
42
|
children: [
|
|
38
43
|
/* @__PURE__ */ t(
|
|
39
44
|
"div",
|
|
@@ -42,7 +47,7 @@ const T = 48, q = ({
|
|
|
42
47
|
hidden: !e,
|
|
43
48
|
className: r(
|
|
44
49
|
"min-h-0 flex-1 overflow-auto p-4",
|
|
45
|
-
|
|
50
|
+
L
|
|
46
51
|
),
|
|
47
52
|
children: c
|
|
48
53
|
}
|
|
@@ -53,7 +58,7 @@ const T = 48, q = ({
|
|
|
53
58
|
hidden: e,
|
|
54
59
|
className: r(
|
|
55
60
|
"rotate-180 px-3 py-4 [writing-mode:tb-rl] dial-small-text text-primary",
|
|
56
|
-
|
|
61
|
+
v
|
|
57
62
|
),
|
|
58
63
|
children: m
|
|
59
64
|
}
|
|
@@ -64,30 +69,30 @@ const T = 48, q = ({
|
|
|
64
69
|
className: r(
|
|
65
70
|
"flex h-12 shrink-0 flex-row items-center gap-2 border-t border-tertiary py-1",
|
|
66
71
|
e ? "justify-end px-2" : "justify-center",
|
|
67
|
-
|
|
72
|
+
_
|
|
68
73
|
),
|
|
69
74
|
children: [
|
|
70
|
-
e &&
|
|
75
|
+
e && I,
|
|
71
76
|
/* @__PURE__ */ t(
|
|
72
|
-
|
|
77
|
+
B,
|
|
73
78
|
{
|
|
74
|
-
variant:
|
|
75
|
-
appearance:
|
|
76
|
-
size:
|
|
77
|
-
onClick:
|
|
79
|
+
variant: z.Primary,
|
|
80
|
+
appearance: k.Ghost,
|
|
81
|
+
size: T.Standard,
|
|
82
|
+
onClick: A,
|
|
78
83
|
"aria-label": n,
|
|
79
84
|
"aria-expanded": e,
|
|
80
85
|
"aria-controls": a,
|
|
81
86
|
tooltipProps: { tooltip: n },
|
|
82
87
|
icon: e ? /* @__PURE__ */ t(
|
|
83
|
-
|
|
88
|
+
E,
|
|
84
89
|
{
|
|
85
90
|
size: p.MD,
|
|
86
91
|
stroke: d,
|
|
87
92
|
"aria-hidden": "true"
|
|
88
93
|
}
|
|
89
94
|
) : /* @__PURE__ */ t(
|
|
90
|
-
|
|
95
|
+
O,
|
|
91
96
|
{
|
|
92
97
|
size: p.MD,
|
|
93
98
|
stroke: d,
|
|
@@ -104,5 +109,5 @@ const T = 48, q = ({
|
|
|
104
109
|
);
|
|
105
110
|
};
|
|
106
111
|
export {
|
|
107
|
-
|
|
112
|
+
J as CollapsibleSidebar
|
|
108
113
|
};
|
|
@@ -1,75 +1,76 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { useCallback as
|
|
3
|
-
import { Button as
|
|
4
|
-
import { NeutralButton as
|
|
5
|
-
import { Popup as
|
|
6
|
-
import { Spinner as
|
|
7
|
-
import { ConfirmationPopupVariant as
|
|
8
|
-
import { PopupSize as
|
|
1
|
+
import { jsxs as x, jsx as r } from "react/jsx-runtime";
|
|
2
|
+
import { useCallback as I } from "react";
|
|
3
|
+
import { Button as j } from "../Button/Button.js";
|
|
4
|
+
import { NeutralButton as z } from "../Button/ButtonWrappers.js";
|
|
5
|
+
import { Popup as A } from "../Popup/Popup.js";
|
|
6
|
+
import { Spinner as _ } from "../../Spinner/Spinner.js";
|
|
7
|
+
import { ConfirmationPopupVariant as D } from "../../../types/confirmation-popup.js";
|
|
8
|
+
import { PopupSize as F } from "../../../types/popup.js";
|
|
9
9
|
import { mergeClasses as f } from "../../../utils/merge-classes.js";
|
|
10
|
-
import { actionsBaseClassName as
|
|
10
|
+
import { actionsBaseClassName as K, defaultCancelLabel as L, defaultConfirmLabel as T, variantConfig as s, loaderContainerClassName as V, descriptionBaseClassName as q } from "./constants.js";
|
|
11
|
+
import { DIAL_KIT_CLASS as w } from "../../../constants/public-class-names.js";
|
|
11
12
|
const X = ({
|
|
12
13
|
header: p,
|
|
13
14
|
description: a,
|
|
14
15
|
descriptionClassName: m,
|
|
15
16
|
open: u = !1,
|
|
16
|
-
confirmLabel: c =
|
|
17
|
-
cancelLabel: C =
|
|
18
|
-
isLoading:
|
|
17
|
+
confirmLabel: c = T,
|
|
18
|
+
cancelLabel: C = L,
|
|
19
|
+
isLoading: o = !1,
|
|
19
20
|
disableConfirmButton: d = !1,
|
|
20
21
|
className: N,
|
|
21
22
|
confirmClassName: b,
|
|
22
|
-
onClose:
|
|
23
|
+
onClose: t,
|
|
23
24
|
onConfirm: v,
|
|
24
|
-
onCancel:
|
|
25
|
-
children:
|
|
26
|
-
variant:
|
|
27
|
-
size:
|
|
28
|
-
footer:
|
|
29
|
-
hideClose:
|
|
30
|
-
...
|
|
25
|
+
onCancel: l,
|
|
26
|
+
children: e,
|
|
27
|
+
variant: n = D.Info,
|
|
28
|
+
size: P = F.Sm,
|
|
29
|
+
footer: i,
|
|
30
|
+
hideClose: S,
|
|
31
|
+
...B
|
|
31
32
|
}) => {
|
|
32
|
-
const
|
|
33
|
+
const h = o ? null : /* @__PURE__ */ x("div", { className: K, children: [
|
|
33
34
|
/* @__PURE__ */ r(
|
|
34
|
-
|
|
35
|
+
z,
|
|
35
36
|
{
|
|
36
37
|
label: C,
|
|
37
|
-
onClick: () =>
|
|
38
|
+
onClick: () => l ? l() : t?.()
|
|
38
39
|
}
|
|
39
40
|
),
|
|
40
41
|
/* @__PURE__ */ r(
|
|
41
|
-
|
|
42
|
+
j,
|
|
42
43
|
{
|
|
43
|
-
variant:
|
|
44
|
-
appearance:
|
|
44
|
+
variant: s[n].confirm.variant,
|
|
45
|
+
appearance: s[n].confirm.appearance,
|
|
45
46
|
className: b,
|
|
46
47
|
label: c,
|
|
47
48
|
disabled: d,
|
|
48
49
|
onClick: v
|
|
49
50
|
}
|
|
50
51
|
)
|
|
51
|
-
] }),
|
|
52
|
+
] }), k = I(() => o ? /* @__PURE__ */ r("div", { className: V, children: /* @__PURE__ */ r(_, { size: 40 }) }) : e ?? (a ? /* @__PURE__ */ r(
|
|
52
53
|
"div",
|
|
53
54
|
{
|
|
54
55
|
className: f(
|
|
55
|
-
|
|
56
|
+
q,
|
|
56
57
|
m
|
|
57
58
|
),
|
|
58
59
|
children: a
|
|
59
60
|
}
|
|
60
|
-
) : null), [
|
|
61
|
+
) : null), [e, a, o, m]);
|
|
61
62
|
return /* @__PURE__ */ r(
|
|
62
|
-
|
|
63
|
+
A,
|
|
63
64
|
{
|
|
64
|
-
...
|
|
65
|
+
...B,
|
|
65
66
|
open: u,
|
|
66
67
|
header: p,
|
|
67
|
-
className: f(
|
|
68
|
-
onClose: () =>
|
|
69
|
-
footer:
|
|
70
|
-
size:
|
|
71
|
-
hideClose:
|
|
72
|
-
children:
|
|
68
|
+
className: f(N, w.confirmationPopup),
|
|
69
|
+
onClose: () => t?.(),
|
|
70
|
+
footer: i ?? h,
|
|
71
|
+
size: P,
|
|
72
|
+
hideClose: S ?? (!o && i === void 0),
|
|
73
|
+
children: k()
|
|
73
74
|
}
|
|
74
75
|
);
|
|
75
76
|
};
|
|
@@ -1,24 +1,21 @@
|
|
|
1
|
-
import { ButtonAppearance as a, ButtonVariant as
|
|
2
|
-
import { ConfirmationPopupVariant as
|
|
3
|
-
const
|
|
4
|
-
[
|
|
1
|
+
import { ButtonAppearance as a, ButtonVariant as n } from "../../../types/button.js";
|
|
2
|
+
import { ConfirmationPopupVariant as r } from "../../../types/confirmation-popup.js";
|
|
3
|
+
const o = "flex justify-end gap-2 px-6 py-4 border-t border-tertiary", i = "text-secondary dial-small-paragraph-text px-6 pb-4", p = "px-6 py-4 h-[120px]", s = "Cancel", c = "Ok", l = {
|
|
4
|
+
[r.Info]: {
|
|
5
5
|
confirm: {
|
|
6
|
-
variant:
|
|
6
|
+
variant: n.Primary,
|
|
7
7
|
appearance: a.Solid
|
|
8
8
|
}
|
|
9
9
|
},
|
|
10
|
-
[
|
|
11
|
-
// Utilities rather than the legacy `.dial-danger-popup` SCSS rule, which is
|
|
12
|
-
// scoped as `div .dial-danger-popup` and only lands by accident of nesting.
|
|
13
|
-
container: "border-t-4 border-error",
|
|
10
|
+
[r.Danger]: {
|
|
14
11
|
confirm: {
|
|
15
|
-
variant:
|
|
12
|
+
variant: n.Danger,
|
|
16
13
|
appearance: a.Solid
|
|
17
14
|
}
|
|
18
15
|
}
|
|
19
16
|
};
|
|
20
17
|
export {
|
|
21
|
-
|
|
18
|
+
o as actionsBaseClassName,
|
|
22
19
|
s as defaultCancelLabel,
|
|
23
20
|
c as defaultConfirmLabel,
|
|
24
21
|
i as descriptionBaseClassName,
|