@drivenets/design-system 0.0.3 → 0.0.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/CHANGELOG.md +13 -0
- package/README.md +51 -0
- package/dist/components/ds-alert-banner/ds-alert-banner.cjs +157 -52
- package/dist/components/ds-alert-banner/ds-alert-banner.d.cts +5 -5
- package/dist/components/ds-alert-banner/ds-alert-banner.d.cts.map +1 -1
- package/dist/components/ds-alert-banner/ds-alert-banner.js +157 -52
- package/dist/components/ds-alert-banner/ds-alert-banner.js.map +1 -1
- package/dist/components/ds-alert-banner/ds-alert-banner.types.d.cts.map +1 -1
- package/dist/components/ds-alert-banner/ds-alert-banner.types.js.map +1 -1
- package/dist/components/ds-breadcrumb/ds-breadcrumb.cjs +59 -16
- package/dist/components/ds-breadcrumb/ds-breadcrumb.js +59 -16
- package/dist/components/ds-breadcrumb/ds-breadcrumb.js.map +1 -1
- package/dist/components/ds-button/ds-button.cjs +18 -2
- package/dist/components/ds-button/ds-button.d.cts +2 -2
- package/dist/components/ds-button/ds-button.d.cts.map +1 -1
- package/dist/components/ds-button/ds-button.d.ts +2 -2
- package/dist/components/ds-button/ds-button.js +18 -2
- package/dist/components/ds-button/ds-button.js.map +1 -1
- package/dist/components/ds-button/versions/ds-button-legacy/ds-button-legacy.cjs +79 -10
- package/dist/components/ds-button/versions/ds-button-legacy/ds-button-legacy.js +79 -10
- package/dist/components/ds-button/versions/ds-button-legacy/ds-button-legacy.js.map +1 -1
- package/dist/components/ds-button/versions/ds-button-new/ds-button-new.cjs +78 -10
- package/dist/components/ds-button/versions/ds-button-new/ds-button-new.js +78 -10
- package/dist/components/ds-button/versions/ds-button-new/ds-button-new.js.map +1 -1
- package/dist/components/ds-checkbox/ds-checkbox.cjs +89 -18
- package/dist/components/ds-checkbox/ds-checkbox.js +89 -18
- package/dist/components/ds-checkbox/ds-checkbox.js.map +1 -1
- package/dist/components/ds-chip/ds-chip.cjs +100 -30
- package/dist/components/ds-chip/ds-chip.js +100 -30
- package/dist/components/ds-chip/ds-chip.js.map +1 -1
- package/dist/components/ds-chip-group/ds-chip-group.cjs +6 -6
- package/dist/components/ds-chip-group/ds-chip-group.js +6 -6
- package/dist/components/ds-chip-group/ds-chip-group.js.map +1 -1
- package/dist/components/ds-chip-group/hooks/use-chip-row-calculation.js.map +1 -1
- package/dist/components/ds-confirmation/ds-confirmation.cjs +210 -56
- package/dist/components/ds-confirmation/ds-confirmation.d.cts +8 -8
- package/dist/components/ds-confirmation/ds-confirmation.d.ts +8 -8
- package/dist/components/ds-confirmation/ds-confirmation.js +210 -56
- package/dist/components/ds-confirmation/ds-confirmation.js.map +1 -1
- package/dist/components/ds-dialog/ds-dialog.js.map +1 -1
- package/dist/components/ds-drawer/ds-drawer.cjs +261 -61
- package/dist/components/ds-drawer/ds-drawer.d.cts +9 -9
- package/dist/components/ds-drawer/ds-drawer.d.ts +9 -9
- package/dist/components/ds-drawer/ds-drawer.js +261 -61
- package/dist/components/ds-drawer/ds-drawer.js.map +1 -1
- package/dist/components/ds-dropdown-menu/ds-dropdown-menu.cjs +481 -135
- package/dist/components/ds-dropdown-menu/ds-dropdown-menu.js +481 -135
- package/dist/components/ds-dropdown-menu/ds-dropdown-menu.js.map +1 -1
- package/dist/components/ds-expandable-text-input/ds-expandable-text-input.cjs +146 -56
- package/dist/components/ds-expandable-text-input/ds-expandable-text-input.d.cts +2 -2
- package/dist/components/ds-expandable-text-input/ds-expandable-text-input.d.ts +2 -2
- package/dist/components/ds-expandable-text-input/ds-expandable-text-input.js +146 -56
- package/dist/components/ds-expandable-text-input/ds-expandable-text-input.js.map +1 -1
- package/dist/components/ds-file-upload/components/file-upload/file-upload.cjs +190 -69
- package/dist/components/ds-file-upload/components/file-upload/file-upload.js +190 -69
- package/dist/components/ds-file-upload/components/file-upload/file-upload.js.map +1 -1
- package/dist/components/ds-file-upload/components/file-upload-item/file-upload-item.cjs +273 -132
- package/dist/components/ds-file-upload/components/file-upload-item/file-upload-item.js +273 -132
- package/dist/components/ds-file-upload/components/file-upload-item/file-upload-item.js.map +1 -1
- package/dist/components/ds-file-upload/ds-file-upload.cjs +96 -16
- package/dist/components/ds-file-upload/ds-file-upload.js +96 -16
- package/dist/components/ds-file-upload/ds-file-upload.js.map +1 -1
- package/dist/components/ds-file-upload/errors/file-upload-errors.js.map +1 -1
- package/dist/components/ds-file-upload/hooks/use-file-upload.cjs +93 -93
- package/dist/components/ds-file-upload/hooks/use-file-upload.js +93 -93
- package/dist/components/ds-file-upload/hooks/use-file-upload.js.map +1 -1
- package/dist/components/ds-file-upload/types/accept-types.js.map +1 -1
- package/dist/components/ds-file-upload/utils/accept-utils.js.map +1 -1
- package/dist/components/ds-file-upload/utils/constants.js.map +1 -1
- package/dist/components/ds-file-upload/utils/file-factory.js.map +1 -1
- package/dist/components/ds-file-upload/utils/format-file-size.js.map +1 -1
- package/dist/components/ds-file-upload/utils/generate-helper-text.js.map +1 -1
- package/dist/components/ds-file-upload/utils/get-error-message.js.map +1 -1
- package/dist/components/ds-file-upload/utils/is-file-equal.js.map +1 -1
- package/dist/components/ds-form-control/ds-form-control.cjs +119 -34
- package/dist/components/ds-form-control/ds-form-control.d.cts +7 -7
- package/dist/components/ds-form-control/ds-form-control.d.ts +7 -7
- package/dist/components/ds-form-control/ds-form-control.d.ts.map +1 -1
- package/dist/components/ds-form-control/ds-form-control.js +119 -34
- package/dist/components/ds-form-control/ds-form-control.js.map +1 -1
- package/dist/components/ds-form-control/ds-form-control.types.js.map +1 -1
- package/dist/components/ds-grid/ds-grid.js.map +1 -1
- package/dist/components/ds-icon/ds-icon.cjs +84 -13
- package/dist/components/ds-icon/ds-icon.js +84 -13
- package/dist/components/ds-icon/ds-icon.js.map +1 -1
- package/dist/components/ds-icon/ds-icon.types.d.cts.map +1 -1
- package/dist/components/ds-icon/ds-icon.types.js.map +1 -1
- package/dist/components/ds-modal/ds-modal.cjs +222 -55
- package/dist/components/ds-modal/ds-modal.d.cts +8 -8
- package/dist/components/ds-modal/ds-modal.d.ts +8 -8
- package/dist/components/ds-modal/ds-modal.d.ts.map +1 -1
- package/dist/components/ds-modal/ds-modal.js +222 -55
- package/dist/components/ds-modal/ds-modal.js.map +1 -1
- package/dist/components/ds-number-input/ds-number-input.cjs +136 -49
- package/dist/components/ds-number-input/ds-number-input.js +136 -49
- package/dist/components/ds-number-input/ds-number-input.js.map +1 -1
- package/dist/components/ds-panel/ds-panel.cjs +111 -19
- package/dist/components/ds-panel/ds-panel.d.cts +2 -2
- package/dist/components/ds-panel/ds-panel.d.cts.map +1 -1
- package/dist/components/ds-panel/ds-panel.d.ts +2 -2
- package/dist/components/ds-panel/ds-panel.js +111 -19
- package/dist/components/ds-panel/ds-panel.js.map +1 -1
- package/dist/components/ds-password-input/ds-password-input.cjs +108 -41
- package/dist/components/ds-password-input/ds-password-input.js +108 -41
- package/dist/components/ds-password-input/ds-password-input.js.map +1 -1
- package/dist/components/ds-popover/ds-popover.cjs +50 -12
- package/dist/components/ds-popover/ds-popover.js +50 -12
- package/dist/components/ds-popover/ds-popover.js.map +1 -1
- package/dist/components/ds-radio-group/ds-radio-group.cjs +209 -53
- package/dist/components/ds-radio-group/ds-radio-group.js +209 -53
- package/dist/components/ds-radio-group/ds-radio-group.js.map +1 -1
- package/dist/components/ds-segment-group/ds-segment-group.cjs +215 -0
- package/dist/components/ds-segment-group/ds-segment-group.d.cts +26 -0
- package/dist/components/ds-segment-group/ds-segment-group.d.cts.map +1 -0
- package/dist/components/ds-segment-group/ds-segment-group.d.ts +26 -0
- package/dist/components/ds-segment-group/ds-segment-group.d.ts.map +1 -0
- package/dist/components/ds-segment-group/ds-segment-group.js +214 -0
- package/dist/components/ds-segment-group/ds-segment-group.js.map +1 -0
- package/dist/components/ds-segment-group/ds-segment-group.module.cjs +12 -0
- package/dist/components/ds-segment-group/ds-segment-group.module.js +12 -0
- package/dist/components/ds-segment-group/ds-segment-group.module.js.map +1 -0
- package/dist/components/ds-segment-group/ds-segment-group.types.cjs +2 -0
- package/dist/components/ds-segment-group/ds-segment-group.types.d.cts +52 -0
- package/dist/components/ds-segment-group/ds-segment-group.types.d.cts.map +1 -0
- package/dist/components/ds-segment-group/ds-segment-group.types.d.ts +52 -0
- package/dist/components/ds-segment-group/ds-segment-group.types.d.ts.map +1 -0
- package/dist/components/ds-segment-group/ds-segment-group.types.js +2 -0
- package/dist/components/ds-segment-group/index.cjs +2 -0
- package/dist/components/ds-segment-group/index.d.ts +2 -0
- package/dist/components/ds-segment-group/index.js +2 -0
- package/dist/components/ds-select/ds-select.cjs +198 -89
- package/dist/components/ds-select/ds-select.d.cts +2 -2
- package/dist/components/ds-select/ds-select.d.cts.map +1 -1
- package/dist/components/ds-select/ds-select.d.ts +2 -2
- package/dist/components/ds-select/ds-select.js +198 -89
- package/dist/components/ds-select/ds-select.js.map +1 -1
- package/dist/components/ds-select/select-items-chips.cjs +73 -22
- package/dist/components/ds-select/select-items-chips.js +73 -22
- package/dist/components/ds-select/select-items-chips.js.map +1 -1
- package/dist/components/ds-smart-tabs/ds-smart-tabs.cjs +208 -46
- package/dist/components/ds-smart-tabs/ds-smart-tabs.d.cts +2 -2
- package/dist/components/ds-smart-tabs/ds-smart-tabs.d.cts.map +1 -1
- package/dist/components/ds-smart-tabs/ds-smart-tabs.d.ts +2 -2
- package/dist/components/ds-smart-tabs/ds-smart-tabs.d.ts.map +1 -1
- package/dist/components/ds-smart-tabs/ds-smart-tabs.js +208 -46
- package/dist/components/ds-smart-tabs/ds-smart-tabs.js.map +1 -1
- package/dist/components/ds-smart-tabs/ds-smart-tabs.types.js.map +1 -1
- package/dist/components/ds-spinner/ds-spinner.cjs +90 -20
- package/dist/components/ds-spinner/ds-spinner.js +90 -20
- package/dist/components/ds-spinner/ds-spinner.js.map +1 -1
- package/dist/components/ds-spinner/ds-spinner.types.js.map +1 -1
- package/dist/components/ds-status-badge/ds-status-badge.cjs +54 -11
- package/dist/components/ds-status-badge/ds-status-badge.js +54 -11
- package/dist/components/ds-status-badge/ds-status-badge.js.map +1 -1
- package/dist/components/ds-stepper/components/ds-step-content.cjs +59 -13
- package/dist/components/ds-stepper/components/ds-step-content.d.cts +2 -2
- package/dist/components/ds-stepper/components/ds-step-content.js +59 -13
- package/dist/components/ds-stepper/components/ds-step-content.js.map +1 -1
- package/dist/components/ds-stepper/components/ds-step-description.cjs +14 -5
- package/dist/components/ds-stepper/components/ds-step-description.js +14 -5
- package/dist/components/ds-stepper/components/ds-step-description.js.map +1 -1
- package/dist/components/ds-stepper/components/ds-step-label.cjs +14 -5
- package/dist/components/ds-stepper/components/ds-step-label.js +14 -5
- package/dist/components/ds-stepper/components/ds-step-label.js.map +1 -1
- package/dist/components/ds-stepper/components/ds-step-next-button.cjs +23 -6
- package/dist/components/ds-stepper/components/ds-step-next-button.d.cts +2 -2
- package/dist/components/ds-stepper/components/ds-step-next-button.js +23 -6
- package/dist/components/ds-stepper/components/ds-step-next-button.js.map +1 -1
- package/dist/components/ds-stepper/components/ds-step.cjs +106 -25
- package/dist/components/ds-stepper/components/ds-step.d.cts +2 -2
- package/dist/components/ds-stepper/components/ds-step.js +106 -25
- package/dist/components/ds-stepper/components/ds-step.js.map +1 -1
- package/dist/components/ds-stepper/ds-stepper.cjs +62 -15
- package/dist/components/ds-stepper/ds-stepper.d.cts +2 -2
- package/dist/components/ds-stepper/ds-stepper.d.cts.map +1 -1
- package/dist/components/ds-stepper/ds-stepper.js +62 -15
- package/dist/components/ds-stepper/ds-stepper.js.map +1 -1
- package/dist/components/ds-stepper/hooks/use-stepper.js.map +1 -1
- package/dist/components/ds-stepper/hooks/use-steps.cjs +29 -9
- package/dist/components/ds-stepper/hooks/use-steps.js +29 -9
- package/dist/components/ds-stepper/hooks/use-steps.js.map +1 -1
- package/dist/components/ds-system-status/ds-system-status.cjs +37 -7
- package/dist/components/ds-system-status/ds-system-status.js +37 -7
- package/dist/components/ds-system-status/ds-system-status.js.map +1 -1
- package/dist/components/ds-system-status/ds-system-status.types.js.map +1 -1
- package/dist/components/ds-table/components/core-table/core-table.cjs +281 -48
- package/dist/components/ds-table/components/core-table/core-table.js +281 -48
- package/dist/components/ds-table/components/core-table/core-table.js.map +1 -1
- package/dist/components/ds-table/components/ds-table-bulk-actions/ds-table-bulk-actions.cjs +134 -50
- package/dist/components/ds-table/components/ds-table-bulk-actions/ds-table-bulk-actions.js +134 -50
- package/dist/components/ds-table/components/ds-table-bulk-actions/ds-table-bulk-actions.js.map +1 -1
- package/dist/components/ds-table/components/ds-table-cell/ds-table-cell.cjs +140 -43
- package/dist/components/ds-table/components/ds-table-cell/ds-table-cell.js +140 -43
- package/dist/components/ds-table/components/ds-table-cell/ds-table-cell.js.map +1 -1
- package/dist/components/ds-table/components/ds-table-header/ds-table-header.cjs +37 -6
- package/dist/components/ds-table/components/ds-table-header/ds-table-header.js +37 -6
- package/dist/components/ds-table/components/ds-table-header/ds-table-header.js.map +1 -1
- package/dist/components/ds-table/components/ds-table-row/ds-table-row.cjs +272 -100
- package/dist/components/ds-table/components/ds-table-row/ds-table-row.js +272 -100
- package/dist/components/ds-table/components/ds-table-row/ds-table-row.js.map +1 -1
- package/dist/components/ds-table/context/ds-table-context.js.map +1 -1
- package/dist/components/ds-table/ds-table.cjs +15 -15
- package/dist/components/ds-table/ds-table.d.cts +2 -2
- package/dist/components/ds-table/ds-table.js +15 -15
- package/dist/components/ds-table/ds-table.js.map +1 -1
- package/dist/components/ds-table/hooks/use-drag-and-drop.cjs +126 -38
- package/dist/components/ds-table/hooks/use-drag-and-drop.js +126 -38
- package/dist/components/ds-table/hooks/use-drag-and-drop.js.map +1 -1
- package/dist/components/ds-table/utils/column-styling.js.map +1 -1
- package/dist/components/ds-table/utils/create-columns-grid-template.js.map +1 -1
- package/dist/components/ds-table/utils/merge-refs.js.map +1 -1
- package/dist/components/ds-text-input/ds-text-input.cjs +128 -43
- package/dist/components/ds-text-input/ds-text-input.js +128 -43
- package/dist/components/ds-text-input/ds-text-input.js.map +1 -1
- package/dist/components/ds-text-input/ds-text-input.types.js.map +1 -1
- package/dist/components/ds-textarea/ds-textarea.cjs +66 -22
- package/dist/components/ds-textarea/ds-textarea.js +66 -22
- package/dist/components/ds-textarea/ds-textarea.js.map +1 -1
- package/dist/components/ds-toast/ds-toast-context.cjs +62 -17
- package/dist/components/ds-toast/ds-toast-context.js +62 -17
- package/dist/components/ds-toast/ds-toast-context.js.map +1 -1
- package/dist/components/ds-toast/ds-toast.cjs +90 -26
- package/dist/components/ds-toast/ds-toast.js +90 -26
- package/dist/components/ds-toast/ds-toast.js.map +1 -1
- package/dist/components/ds-tooltip/ds-tooltip.cjs +51 -13
- package/dist/components/ds-tooltip/ds-tooltip.js +51 -13
- package/dist/components/ds-tooltip/ds-tooltip.js.map +1 -1
- package/dist/components/ds-typography/ds-typography.cjs +51 -7
- package/dist/components/ds-typography/ds-typography.config.js.map +1 -1
- package/dist/components/ds-typography/ds-typography.js +51 -7
- package/dist/components/ds-typography/ds-typography.js.map +1 -1
- package/dist/components/ds-vertical-tabs/ds-vertical-tabs.cjs +91 -30
- package/dist/components/ds-vertical-tabs/ds-vertical-tabs.d.cts +5 -5
- package/dist/components/ds-vertical-tabs/ds-vertical-tabs.d.ts +5 -5
- package/dist/components/ds-vertical-tabs/ds-vertical-tabs.js +91 -30
- package/dist/components/ds-vertical-tabs/ds-vertical-tabs.js.map +1 -1
- package/dist/index.cjs +3 -0
- package/dist/index.d.cts +3 -1
- package/dist/index.d.ts +4 -1
- package/dist/index.js +3 -1
- package/dist/index.min.css +1 -1
- package/package.json +8 -2
- package/src/components/ds-segment-group/ds-segment-group.module.scss +99 -0
- package/src/components/ds-segment-group/ds-segment-group.tsx +76 -0
- package/src/components/ds-segment-group/ds-segment-group.types.tsx +64 -0
- package/src/components/ds-segment-group/index.tsx +2 -0
- package/src/index.ts +1 -0
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
const require_rolldown_runtime = require('../../_virtual/rolldown_runtime.cjs');
|
|
2
2
|
const require_ds_spinner_module = require('./ds-spinner.module.cjs');
|
|
3
|
+
let react_compiler_runtime = require("react/compiler-runtime");
|
|
3
4
|
let classnames = require("classnames");
|
|
4
5
|
classnames = require_rolldown_runtime.__toESM(classnames);
|
|
5
6
|
let react_jsx_runtime = require("react/jsx-runtime");
|
|
@@ -18,33 +19,102 @@ const widthMap = {
|
|
|
18
19
|
/**
|
|
19
20
|
* Design system Spinner component
|
|
20
21
|
*/
|
|
21
|
-
const DsSpinner = (
|
|
22
|
+
const DsSpinner = (t0) => {
|
|
23
|
+
const $ = (0, react_compiler_runtime.c)(26);
|
|
24
|
+
let className;
|
|
25
|
+
let props;
|
|
26
|
+
let t1;
|
|
27
|
+
let t2;
|
|
28
|
+
if ($[0] !== t0) {
|
|
29
|
+
({size: t1, className, style: t2, ...props} = t0);
|
|
30
|
+
$[0] = t0;
|
|
31
|
+
$[1] = className;
|
|
32
|
+
$[2] = props;
|
|
33
|
+
$[3] = t1;
|
|
34
|
+
$[4] = t2;
|
|
35
|
+
} else {
|
|
36
|
+
className = $[1];
|
|
37
|
+
props = $[2];
|
|
38
|
+
t1 = $[3];
|
|
39
|
+
t2 = $[4];
|
|
40
|
+
}
|
|
41
|
+
const size = t1 === void 0 ? "medium" : t1;
|
|
42
|
+
let t3;
|
|
43
|
+
if ($[5] !== t2) {
|
|
44
|
+
t3 = t2 === void 0 ? {} : t2;
|
|
45
|
+
$[5] = t2;
|
|
46
|
+
$[6] = t3;
|
|
47
|
+
} else t3 = $[6];
|
|
48
|
+
const style = t3;
|
|
22
49
|
const actualSize = sizeMap[size];
|
|
23
50
|
const actualWidth = widthMap[size];
|
|
24
51
|
const radius = (actualSize - actualWidth) / 2;
|
|
25
52
|
const circumference = 2 * Math.PI * radius;
|
|
26
53
|
const strokeDasharray = `${String(.25 * circumference)} ${String(circumference)}`;
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
54
|
+
const t4 = require_ds_spinner_module.default[size];
|
|
55
|
+
let t5;
|
|
56
|
+
if ($[7] !== className || $[8] !== t4) {
|
|
57
|
+
t5 = (0, classnames.default)(require_ds_spinner_module.default.spinnerContainer, t4, className);
|
|
58
|
+
$[7] = className;
|
|
59
|
+
$[8] = t4;
|
|
60
|
+
$[9] = t5;
|
|
61
|
+
} else t5 = $[9];
|
|
62
|
+
let t6;
|
|
63
|
+
if ($[10] === Symbol.for("react.memo_cache_sentinel")) {
|
|
64
|
+
t6 = (0, classnames.default)(require_ds_spinner_module.default.progressCircle, require_ds_spinner_module.default.spin);
|
|
65
|
+
$[10] = t6;
|
|
66
|
+
} else t6 = $[10];
|
|
67
|
+
const t7 = `0 0 ${String(actualSize)} ${String(actualSize)}`;
|
|
68
|
+
const t8 = actualSize / 2;
|
|
69
|
+
const t9 = actualSize / 2;
|
|
70
|
+
let t10;
|
|
71
|
+
if ($[11] !== actualWidth || $[12] !== radius || $[13] !== strokeDasharray || $[14] !== t8 || $[15] !== t9) {
|
|
72
|
+
t10 = /* @__PURE__ */ (0, react_jsx_runtime.jsx)("circle", {
|
|
73
|
+
className: require_ds_spinner_module.default.progressArc,
|
|
74
|
+
cx: t8,
|
|
75
|
+
cy: t9,
|
|
76
|
+
r: radius,
|
|
77
|
+
fill: "none",
|
|
78
|
+
strokeWidth: actualWidth,
|
|
79
|
+
strokeDasharray,
|
|
80
|
+
strokeLinecap: "round"
|
|
81
|
+
});
|
|
82
|
+
$[11] = actualWidth;
|
|
83
|
+
$[12] = radius;
|
|
84
|
+
$[13] = strokeDasharray;
|
|
85
|
+
$[14] = t8;
|
|
86
|
+
$[15] = t9;
|
|
87
|
+
$[16] = t10;
|
|
88
|
+
} else t10 = $[16];
|
|
89
|
+
let t11;
|
|
90
|
+
if ($[17] !== actualSize || $[18] !== t10 || $[19] !== t7) {
|
|
91
|
+
t11 = /* @__PURE__ */ (0, react_jsx_runtime.jsx)("svg", {
|
|
92
|
+
className: t6,
|
|
33
93
|
width: actualSize,
|
|
34
94
|
height: actualSize,
|
|
35
|
-
viewBox:
|
|
36
|
-
children:
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
95
|
+
viewBox: t7,
|
|
96
|
+
children: t10
|
|
97
|
+
});
|
|
98
|
+
$[17] = actualSize;
|
|
99
|
+
$[18] = t10;
|
|
100
|
+
$[19] = t7;
|
|
101
|
+
$[20] = t11;
|
|
102
|
+
} else t11 = $[20];
|
|
103
|
+
let t12;
|
|
104
|
+
if ($[21] !== props || $[22] !== style || $[23] !== t11 || $[24] !== t5) {
|
|
105
|
+
t12 = /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
106
|
+
className: t5,
|
|
107
|
+
style,
|
|
108
|
+
...props,
|
|
109
|
+
children: t11
|
|
110
|
+
});
|
|
111
|
+
$[21] = props;
|
|
112
|
+
$[22] = style;
|
|
113
|
+
$[23] = t11;
|
|
114
|
+
$[24] = t5;
|
|
115
|
+
$[25] = t12;
|
|
116
|
+
} else t12 = $[25];
|
|
117
|
+
return t12;
|
|
48
118
|
};
|
|
49
119
|
var ds_spinner_default = DsSpinner;
|
|
50
120
|
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import ds_spinner_module_default from "./ds-spinner.module.js";
|
|
2
|
+
import { c } from "react/compiler-runtime";
|
|
2
3
|
import classNames from "classnames";
|
|
3
4
|
import { jsx } from "react/jsx-runtime";
|
|
4
5
|
|
|
@@ -16,33 +17,102 @@ const widthMap = {
|
|
|
16
17
|
/**
|
|
17
18
|
* Design system Spinner component
|
|
18
19
|
*/
|
|
19
|
-
const DsSpinner = (
|
|
20
|
+
const DsSpinner = (t0) => {
|
|
21
|
+
const $ = c(26);
|
|
22
|
+
let className;
|
|
23
|
+
let props;
|
|
24
|
+
let t1;
|
|
25
|
+
let t2;
|
|
26
|
+
if ($[0] !== t0) {
|
|
27
|
+
({size: t1, className, style: t2, ...props} = t0);
|
|
28
|
+
$[0] = t0;
|
|
29
|
+
$[1] = className;
|
|
30
|
+
$[2] = props;
|
|
31
|
+
$[3] = t1;
|
|
32
|
+
$[4] = t2;
|
|
33
|
+
} else {
|
|
34
|
+
className = $[1];
|
|
35
|
+
props = $[2];
|
|
36
|
+
t1 = $[3];
|
|
37
|
+
t2 = $[4];
|
|
38
|
+
}
|
|
39
|
+
const size = t1 === void 0 ? "medium" : t1;
|
|
40
|
+
let t3;
|
|
41
|
+
if ($[5] !== t2) {
|
|
42
|
+
t3 = t2 === void 0 ? {} : t2;
|
|
43
|
+
$[5] = t2;
|
|
44
|
+
$[6] = t3;
|
|
45
|
+
} else t3 = $[6];
|
|
46
|
+
const style = t3;
|
|
20
47
|
const actualSize = sizeMap[size];
|
|
21
48
|
const actualWidth = widthMap[size];
|
|
22
49
|
const radius = (actualSize - actualWidth) / 2;
|
|
23
50
|
const circumference = 2 * Math.PI * radius;
|
|
24
51
|
const strokeDasharray = `${String(.25 * circumference)} ${String(circumference)}`;
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
52
|
+
const t4 = ds_spinner_module_default[size];
|
|
53
|
+
let t5;
|
|
54
|
+
if ($[7] !== className || $[8] !== t4) {
|
|
55
|
+
t5 = classNames(ds_spinner_module_default.spinnerContainer, t4, className);
|
|
56
|
+
$[7] = className;
|
|
57
|
+
$[8] = t4;
|
|
58
|
+
$[9] = t5;
|
|
59
|
+
} else t5 = $[9];
|
|
60
|
+
let t6;
|
|
61
|
+
if ($[10] === Symbol.for("react.memo_cache_sentinel")) {
|
|
62
|
+
t6 = classNames(ds_spinner_module_default.progressCircle, ds_spinner_module_default.spin);
|
|
63
|
+
$[10] = t6;
|
|
64
|
+
} else t6 = $[10];
|
|
65
|
+
const t7 = `0 0 ${String(actualSize)} ${String(actualSize)}`;
|
|
66
|
+
const t8 = actualSize / 2;
|
|
67
|
+
const t9 = actualSize / 2;
|
|
68
|
+
let t10;
|
|
69
|
+
if ($[11] !== actualWidth || $[12] !== radius || $[13] !== strokeDasharray || $[14] !== t8 || $[15] !== t9) {
|
|
70
|
+
t10 = /* @__PURE__ */ jsx("circle", {
|
|
71
|
+
className: ds_spinner_module_default.progressArc,
|
|
72
|
+
cx: t8,
|
|
73
|
+
cy: t9,
|
|
74
|
+
r: radius,
|
|
75
|
+
fill: "none",
|
|
76
|
+
strokeWidth: actualWidth,
|
|
77
|
+
strokeDasharray,
|
|
78
|
+
strokeLinecap: "round"
|
|
79
|
+
});
|
|
80
|
+
$[11] = actualWidth;
|
|
81
|
+
$[12] = radius;
|
|
82
|
+
$[13] = strokeDasharray;
|
|
83
|
+
$[14] = t8;
|
|
84
|
+
$[15] = t9;
|
|
85
|
+
$[16] = t10;
|
|
86
|
+
} else t10 = $[16];
|
|
87
|
+
let t11;
|
|
88
|
+
if ($[17] !== actualSize || $[18] !== t10 || $[19] !== t7) {
|
|
89
|
+
t11 = /* @__PURE__ */ jsx("svg", {
|
|
90
|
+
className: t6,
|
|
31
91
|
width: actualSize,
|
|
32
92
|
height: actualSize,
|
|
33
|
-
viewBox:
|
|
34
|
-
children:
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
93
|
+
viewBox: t7,
|
|
94
|
+
children: t10
|
|
95
|
+
});
|
|
96
|
+
$[17] = actualSize;
|
|
97
|
+
$[18] = t10;
|
|
98
|
+
$[19] = t7;
|
|
99
|
+
$[20] = t11;
|
|
100
|
+
} else t11 = $[20];
|
|
101
|
+
let t12;
|
|
102
|
+
if ($[21] !== props || $[22] !== style || $[23] !== t11 || $[24] !== t5) {
|
|
103
|
+
t12 = /* @__PURE__ */ jsx("div", {
|
|
104
|
+
className: t5,
|
|
105
|
+
style,
|
|
106
|
+
...props,
|
|
107
|
+
children: t11
|
|
108
|
+
});
|
|
109
|
+
$[21] = props;
|
|
110
|
+
$[22] = style;
|
|
111
|
+
$[23] = t11;
|
|
112
|
+
$[24] = t5;
|
|
113
|
+
$[25] = t12;
|
|
114
|
+
} else t12 = $[25];
|
|
115
|
+
return t12;
|
|
46
116
|
};
|
|
47
117
|
var ds_spinner_default = DsSpinner;
|
|
48
118
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ds-spinner.js","names":["sizeMap
|
|
1
|
+
{"version":3,"file":"ds-spinner.js","names":["React","classNames","styles","DsSpinnerProps","SpinnerSize","sizeMap","Record","small","medium","large","widthMap","DsSpinner","FC","t0","$","_c","className","props","t1","t2","size","style","undefined","t3","actualSize","actualWidth","radius","circumference","Math","PI","strokeDasharray","String","t4","t5","spinnerContainer","t6","Symbol","for","progressCircle","spin","t7","t8","t9","t10","progressArc","t11","t12"],"sources":["../../../src/components/ds-spinner/ds-spinner.tsx"],"sourcesContent":["import type React from 'react';\nimport classNames from 'classnames';\nimport styles from './ds-spinner.module.scss';\nimport type { DsSpinnerProps, SpinnerSize } from './ds-spinner.types';\n\nconst sizeMap: Record<SpinnerSize, number> = {\n\tsmall: 50,\n\tmedium: 75,\n\tlarge: 100,\n};\n\nconst widthMap: Record<SpinnerSize, number> = {\n\tsmall: 4,\n\tmedium: 7,\n\tlarge: 9,\n};\n\n/**\n * Design system Spinner component\n */\nconst DsSpinner: React.FC<DsSpinnerProps> = ({ size = 'medium', className, style = {}, ...props }) => {\n\tconst actualSize = sizeMap[size];\n\tconst actualWidth = widthMap[size];\n\tconst radius = (actualSize - actualWidth) / 2;\n\tconst circumference = 2 * Math.PI * radius;\n\tconst strokeDasharray = `${String(0.25 * circumference)} ${String(circumference)}`;\n\n\treturn (\n\t\t<div className={classNames(styles.spinnerContainer, styles[size], className)} style={style} {...props}>\n\t\t\t<svg\n\t\t\t\tclassName={classNames(styles.progressCircle, styles.spin)}\n\t\t\t\twidth={actualSize}\n\t\t\t\theight={actualSize}\n\t\t\t\tviewBox={`0 0 ${String(actualSize)} ${String(actualSize)}`}\n\t\t\t>\n\t\t\t\t<circle\n\t\t\t\t\tclassName={styles.progressArc}\n\t\t\t\t\tcx={actualSize / 2}\n\t\t\t\t\tcy={actualSize / 2}\n\t\t\t\t\tr={radius}\n\t\t\t\t\tfill=\"none\"\n\t\t\t\t\tstrokeWidth={actualWidth}\n\t\t\t\t\tstrokeDasharray={strokeDasharray}\n\t\t\t\t\tstrokeLinecap=\"round\"\n\t\t\t\t/>\n\t\t\t</svg>\n\t\t</div>\n\t);\n};\n\nexport default DsSpinner;\n"],"mappings":"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"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ds-spinner.types.js","names":[],"sources":["../../../src/components/ds-spinner/ds-spinner.types.tsx"],"sourcesContent":["import type React from 'react';\n\nexport const spinnerSizes = ['small', 'medium', 'large'] as const;\nexport type SpinnerSize = (typeof spinnerSizes)[number];\n\nexport interface DsSpinnerProps {\n\t/**\n\t * The size of the spinner\n\t * @default 'medium'\n\t */\n\tsize?: SpinnerSize;\n\t/**\n\t * Additional CSS class names\n\t */\n\tclassName?: string;\n\t/**\n\t * Additional styles to apply to the component\n\t */\n\tstyle?: React.CSSProperties;\n}\n"],"mappings":";AAEA,
|
|
1
|
+
{"version":3,"file":"ds-spinner.types.js","names":["React","spinnerSizes","const","SpinnerSize","DsSpinnerProps","size","className","style","CSSProperties"],"sources":["../../../src/components/ds-spinner/ds-spinner.types.tsx"],"sourcesContent":["import type React from 'react';\n\nexport const spinnerSizes = ['small', 'medium', 'large'] as const;\nexport type SpinnerSize = (typeof spinnerSizes)[number];\n\nexport interface DsSpinnerProps {\n\t/**\n\t * The size of the spinner\n\t * @default 'medium'\n\t */\n\tsize?: SpinnerSize;\n\t/**\n\t * Additional CSS class names\n\t */\n\tclassName?: string;\n\t/**\n\t * Additional styles to apply to the component\n\t */\n\tstyle?: React.CSSProperties;\n}\n"],"mappings":";AAEA,MAAaC,eAAe;CAAC;CAAS;CAAU;CAAQ"}
|
|
@@ -4,6 +4,7 @@ require('../ds-icon/index.cjs');
|
|
|
4
4
|
const require_ds_typography = require('../ds-typography/ds-typography.cjs');
|
|
5
5
|
require('../ds-typography/index.cjs');
|
|
6
6
|
const require_ds_status_badge_module = require('./ds-status-badge.module.cjs');
|
|
7
|
+
let react_compiler_runtime = require("react/compiler-runtime");
|
|
7
8
|
let classnames = require("classnames");
|
|
8
9
|
classnames = require_rolldown_runtime.__toESM(classnames);
|
|
9
10
|
let react_jsx_runtime = require("react/jsx-runtime");
|
|
@@ -12,23 +13,65 @@ let react_jsx_runtime = require("react/jsx-runtime");
|
|
|
12
13
|
/**
|
|
13
14
|
* Design system StatusBadge component
|
|
14
15
|
*/
|
|
15
|
-
const DsStatusBadge = (
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
16
|
+
const DsStatusBadge = (t0) => {
|
|
17
|
+
const $ = (0, react_compiler_runtime.c)(16);
|
|
18
|
+
const { icon, status, label: t1, className, style, ghost: t2, size: t3, "aria-label": t4 } = t0;
|
|
19
|
+
const label = t1 === void 0 ? status : t1;
|
|
20
|
+
const ghost = t2 === void 0 ? false : t2;
|
|
21
|
+
const size = t3 === void 0 ? "medium" : t3;
|
|
22
|
+
const ariaLabel = t4 === void 0 ? label : t4;
|
|
23
|
+
const t5 = require_ds_status_badge_module.default[status];
|
|
24
|
+
const t6 = ghost && require_ds_status_badge_module.default.ghost;
|
|
25
|
+
const t7 = size === "small" && require_ds_status_badge_module.default.small;
|
|
26
|
+
let t8;
|
|
27
|
+
if ($[0] !== className || $[1] !== t5 || $[2] !== t6 || $[3] !== t7) {
|
|
28
|
+
t8 = (0, classnames.default)(require_ds_status_badge_module.default.container, t5, t6, t7, className);
|
|
29
|
+
$[0] = className;
|
|
30
|
+
$[1] = t5;
|
|
31
|
+
$[2] = t6;
|
|
32
|
+
$[3] = t7;
|
|
33
|
+
$[4] = t8;
|
|
34
|
+
} else t8 = $[4];
|
|
35
|
+
let t9;
|
|
36
|
+
if ($[5] !== icon) {
|
|
37
|
+
t9 = icon && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_ds_icon.default, {
|
|
22
38
|
icon,
|
|
23
39
|
size: "tiny",
|
|
24
40
|
filled: true,
|
|
25
41
|
"aria-hidden": "true"
|
|
26
|
-
})
|
|
42
|
+
});
|
|
43
|
+
$[5] = icon;
|
|
44
|
+
$[6] = t9;
|
|
45
|
+
} else t9 = $[6];
|
|
46
|
+
const t10 = ghost ? "body-xs-md" : "body-xs-reg";
|
|
47
|
+
let t11;
|
|
48
|
+
if ($[7] !== label || $[8] !== t10) {
|
|
49
|
+
t11 = /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_ds_typography.default, {
|
|
27
50
|
className: require_ds_status_badge_module.default.label,
|
|
28
|
-
variant:
|
|
51
|
+
variant: t10,
|
|
29
52
|
children: label
|
|
30
|
-
})
|
|
31
|
-
|
|
53
|
+
});
|
|
54
|
+
$[7] = label;
|
|
55
|
+
$[8] = t10;
|
|
56
|
+
$[9] = t11;
|
|
57
|
+
} else t11 = $[9];
|
|
58
|
+
let t12;
|
|
59
|
+
if ($[10] !== ariaLabel || $[11] !== style || $[12] !== t11 || $[13] !== t8 || $[14] !== t9) {
|
|
60
|
+
t12 = /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
61
|
+
style,
|
|
62
|
+
className: t8,
|
|
63
|
+
role: "status",
|
|
64
|
+
"aria-label": ariaLabel,
|
|
65
|
+
children: [t9, t11]
|
|
66
|
+
});
|
|
67
|
+
$[10] = ariaLabel;
|
|
68
|
+
$[11] = style;
|
|
69
|
+
$[12] = t11;
|
|
70
|
+
$[13] = t8;
|
|
71
|
+
$[14] = t9;
|
|
72
|
+
$[15] = t12;
|
|
73
|
+
} else t12 = $[15];
|
|
74
|
+
return t12;
|
|
32
75
|
};
|
|
33
76
|
var ds_status_badge_default = DsStatusBadge;
|
|
34
77
|
|
|
@@ -3,6 +3,7 @@ import "../ds-icon/index.js";
|
|
|
3
3
|
import ds_typography_default from "../ds-typography/ds-typography.js";
|
|
4
4
|
import "../ds-typography/index.js";
|
|
5
5
|
import ds_status_badge_module_default from "./ds-status-badge.module.js";
|
|
6
|
+
import { c } from "react/compiler-runtime";
|
|
6
7
|
import classNames from "classnames";
|
|
7
8
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
8
9
|
|
|
@@ -10,23 +11,65 @@ import { jsx, jsxs } from "react/jsx-runtime";
|
|
|
10
11
|
/**
|
|
11
12
|
* Design system StatusBadge component
|
|
12
13
|
*/
|
|
13
|
-
const DsStatusBadge = (
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
14
|
+
const DsStatusBadge = (t0) => {
|
|
15
|
+
const $ = c(16);
|
|
16
|
+
const { icon, status, label: t1, className, style, ghost: t2, size: t3, "aria-label": t4 } = t0;
|
|
17
|
+
const label = t1 === void 0 ? status : t1;
|
|
18
|
+
const ghost = t2 === void 0 ? false : t2;
|
|
19
|
+
const size = t3 === void 0 ? "medium" : t3;
|
|
20
|
+
const ariaLabel = t4 === void 0 ? label : t4;
|
|
21
|
+
const t5 = ds_status_badge_module_default[status];
|
|
22
|
+
const t6 = ghost && ds_status_badge_module_default.ghost;
|
|
23
|
+
const t7 = size === "small" && ds_status_badge_module_default.small;
|
|
24
|
+
let t8;
|
|
25
|
+
if ($[0] !== className || $[1] !== t5 || $[2] !== t6 || $[3] !== t7) {
|
|
26
|
+
t8 = classNames(ds_status_badge_module_default.container, t5, t6, t7, className);
|
|
27
|
+
$[0] = className;
|
|
28
|
+
$[1] = t5;
|
|
29
|
+
$[2] = t6;
|
|
30
|
+
$[3] = t7;
|
|
31
|
+
$[4] = t8;
|
|
32
|
+
} else t8 = $[4];
|
|
33
|
+
let t9;
|
|
34
|
+
if ($[5] !== icon) {
|
|
35
|
+
t9 = icon && /* @__PURE__ */ jsx(ds_icon_default, {
|
|
20
36
|
icon,
|
|
21
37
|
size: "tiny",
|
|
22
38
|
filled: true,
|
|
23
39
|
"aria-hidden": "true"
|
|
24
|
-
})
|
|
40
|
+
});
|
|
41
|
+
$[5] = icon;
|
|
42
|
+
$[6] = t9;
|
|
43
|
+
} else t9 = $[6];
|
|
44
|
+
const t10 = ghost ? "body-xs-md" : "body-xs-reg";
|
|
45
|
+
let t11;
|
|
46
|
+
if ($[7] !== label || $[8] !== t10) {
|
|
47
|
+
t11 = /* @__PURE__ */ jsx(ds_typography_default, {
|
|
25
48
|
className: ds_status_badge_module_default.label,
|
|
26
|
-
variant:
|
|
49
|
+
variant: t10,
|
|
27
50
|
children: label
|
|
28
|
-
})
|
|
29
|
-
|
|
51
|
+
});
|
|
52
|
+
$[7] = label;
|
|
53
|
+
$[8] = t10;
|
|
54
|
+
$[9] = t11;
|
|
55
|
+
} else t11 = $[9];
|
|
56
|
+
let t12;
|
|
57
|
+
if ($[10] !== ariaLabel || $[11] !== style || $[12] !== t11 || $[13] !== t8 || $[14] !== t9) {
|
|
58
|
+
t12 = /* @__PURE__ */ jsxs("div", {
|
|
59
|
+
style,
|
|
60
|
+
className: t8,
|
|
61
|
+
role: "status",
|
|
62
|
+
"aria-label": ariaLabel,
|
|
63
|
+
children: [t9, t11]
|
|
64
|
+
});
|
|
65
|
+
$[10] = ariaLabel;
|
|
66
|
+
$[11] = style;
|
|
67
|
+
$[12] = t11;
|
|
68
|
+
$[13] = t8;
|
|
69
|
+
$[14] = t9;
|
|
70
|
+
$[15] = t12;
|
|
71
|
+
} else t12 = $[15];
|
|
72
|
+
return t12;
|
|
30
73
|
};
|
|
31
74
|
var ds_status_badge_default = DsStatusBadge;
|
|
32
75
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ds-status-badge.js","names":["
|
|
1
|
+
{"version":3,"file":"ds-status-badge.js","names":["React","classNames","styles","DsStatusBadgeProps","DsIcon","DsTypography","DsStatusBadge","FC","t0","$","_c","icon","status","label","t1","className","style","ghost","t2","size","t3","t4","undefined","ariaLabel","t5","t6","t7","small","t8","container","t9","t10","t11","t12"],"sources":["../../../src/components/ds-status-badge/ds-status-badge.tsx"],"sourcesContent":["import type React from 'react';\nimport classNames from 'classnames';\nimport styles from './ds-status-badge.module.scss';\nimport type { DsStatusBadgeProps } from './ds-status-badge.types';\nimport { DsIcon } from '../ds-icon';\nimport { DsTypography } from '../ds-typography';\n\n/**\n * Design system StatusBadge component\n */\nconst DsStatusBadge: React.FC<DsStatusBadgeProps> = ({\n\ticon,\n\tstatus,\n\tlabel = status,\n\tclassName,\n\tstyle,\n\tghost = false,\n\tsize = 'medium',\n\t'aria-label': ariaLabel = label,\n}) => {\n\treturn (\n\t\t<div\n\t\t\tstyle={style}\n\t\t\tclassName={classNames(\n\t\t\t\tstyles.container,\n\t\t\t\tstyles[status],\n\t\t\t\tghost && styles.ghost,\n\t\t\t\tsize === 'small' && styles.small,\n\t\t\t\tclassName,\n\t\t\t)}\n\t\t\trole=\"status\"\n\t\t\taria-label={ariaLabel}\n\t\t>\n\t\t\t{icon && <DsIcon icon={icon} size=\"tiny\" filled aria-hidden=\"true\" />}\n\t\t\t<DsTypography className={styles.label} variant={ghost ? 'body-xs-md' : 'body-xs-reg'}>\n\t\t\t\t{label}\n\t\t\t</DsTypography>\n\t\t</div>\n\t);\n};\n\nexport default DsStatusBadge;\n"],"mappings":";;;;;;;;;;;;;AAUA,MAAMM,iBAA8CE,OAAA;CAAA,MAAAC,IAAAC,EAAA,GAAA;CAAC,MAAA,EAAAC,MAAAC,QAAAC,OAAAC,IAAAC,WAAAC,OAAAC,OAAAC,IAAAC,MAAAC,IAAA,cAAAC,OAAAb;CAGpD,MAAAK,QAAAC,OAAAQ,SAAAV,SAAAE;CAGA,MAAAG,QAAAC,OAAAI,SAAA,QAAAJ;CACA,MAAAC,OAAAC,OAAAE,SAAA,WAAAF;CACc,MAAAG,YAAAF,OAAAC,SAAAT,QAAAQ;CAOX,MAAAG,KAAAtB,+BAAOU;CACP,MAAAa,KAAAR,SAASf,+BAAMe;CACf,MAAAS,KAAAP,SAAS,WAAWjB,+BAAMyB;CAAM,IAAAC;AAAA,KAAAnB,EAAA,OAAAM,aAAAN,EAAA,OAAAe,MAAAf,EAAA,OAAAgB,MAAAhB,EAAA,OAAAiB,IAAA;AAJtBE,OAAA3B,WACVC,+BAAM2B,WACNL,IACAC,IACAC,IACAX,UACA;AAAAN,IAAA,KAAAM;AAAAN,IAAA,KAAAe;AAAAf,IAAA,KAAAgB;AAAAhB,IAAA,KAAAiB;AAAAjB,IAAA,KAAAmB;OAAAA,MAAAnB,EAAA;CAAA,IAAAqB;AAAA,KAAArB,EAAA,OAAAE,MAAA;AAIAmB,OAAAnB,QAAQ,oBAAC;GAAaA;GAAW,MAAA;GAAO,QAAA;GAAmB,eAAA;IAAS;AAAAF,IAAA,KAAAE;AAAAF,IAAA,KAAAqB;OAAAA,MAAArB,EAAA;CACrB,MAAAsB,MAAAd,QAAA,eAAA;CAAoC,IAAAe;AAAA,KAAAvB,EAAA,OAAAI,SAAAJ,EAAA,OAAAsB,KAAA;AAApFC,QAAA,oBAAC;GAAwB,WAAA9B,+BAAMW;GAAiB,SAAAkB;aAC9ClB;IACa;AAAAJ,IAAA,KAAAI;AAAAJ,IAAA,KAAAsB;AAAAtB,IAAA,KAAAuB;OAAAA,OAAAvB,EAAA;CAAA,IAAAwB;AAAA,KAAAxB,EAAA,QAAAc,aAAAd,EAAA,QAAAO,SAAAP,EAAA,QAAAuB,OAAAvB,EAAA,QAAAmB,MAAAnB,EAAA,QAAAqB,IAAA;AAfhBG,QAAA,qBAAA;GACQjB;GACI,WAAAY;GAON,MAAA;GACOL,cAAAA;cAEXO,IACDE;IAGK;AAAAvB,IAAA,MAAAc;AAAAd,IAAA,MAAAO;AAAAP,IAAA,MAAAuB;AAAAvB,IAAA,MAAAmB;AAAAnB,IAAA,MAAAqB;AAAArB,IAAA,MAAAwB;OAAAA,OAAAxB,EAAA;AAAA,QAhBNwB;;AAoBF,8BAAe3B"}
|
|
@@ -3,25 +3,71 @@ const require_ds_stepper_module = require('../ds-stepper.module.cjs');
|
|
|
3
3
|
const require_use_stepper = require('../hooks/use-stepper.cjs');
|
|
4
4
|
const require_ds_step_label = require('./ds-step-label.cjs');
|
|
5
5
|
const require_ds_step_description = require('./ds-step-description.cjs');
|
|
6
|
+
let react_compiler_runtime = require("react/compiler-runtime");
|
|
6
7
|
let classnames = require("classnames");
|
|
7
8
|
classnames = require_rolldown_runtime.__toESM(classnames);
|
|
8
9
|
let react_jsx_runtime = require("react/jsx-runtime");
|
|
9
10
|
|
|
10
11
|
//#region src/components/ds-stepper/components/ds-step-content.tsx
|
|
11
|
-
function DsStepContent(
|
|
12
|
+
function DsStepContent(t0) {
|
|
13
|
+
const $ = (0, react_compiler_runtime.c)(18);
|
|
14
|
+
const { index, label, description, actions } = t0;
|
|
12
15
|
const { variant, stepsApi } = require_use_stepper.useStepper();
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
16
|
+
let t1;
|
|
17
|
+
if ($[0] !== index || $[1] !== stepsApi) {
|
|
18
|
+
t1 = stepsApi.getItemState({ index });
|
|
19
|
+
$[0] = index;
|
|
20
|
+
$[1] = stepsApi;
|
|
21
|
+
$[2] = t1;
|
|
22
|
+
} else t1 = $[2];
|
|
23
|
+
const { current } = t1;
|
|
24
|
+
const t2 = variant === "single";
|
|
25
|
+
let t3;
|
|
26
|
+
if ($[3] !== t2) {
|
|
27
|
+
t3 = (0, classnames.default)(require_ds_stepper_module.default.stepContent, { [require_ds_stepper_module.default.stepContentSingle]: t2 });
|
|
28
|
+
$[3] = t2;
|
|
29
|
+
$[4] = t3;
|
|
30
|
+
} else t3 = $[4];
|
|
31
|
+
let t4;
|
|
32
|
+
if ($[5] !== label) {
|
|
33
|
+
t4 = /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_ds_step_label.DsStepLabel, { children: label });
|
|
34
|
+
$[5] = label;
|
|
35
|
+
$[6] = t4;
|
|
36
|
+
} else t4 = $[6];
|
|
37
|
+
let t5;
|
|
38
|
+
if ($[7] !== description || $[8] !== variant) {
|
|
39
|
+
t5 = variant !== "single" && description && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(require_ds_step_description.DsStepDescription, { children: description });
|
|
40
|
+
$[7] = description;
|
|
41
|
+
$[8] = variant;
|
|
42
|
+
$[9] = t5;
|
|
43
|
+
} else t5 = $[9];
|
|
44
|
+
let t6;
|
|
45
|
+
if ($[10] !== actions || $[11] !== current) {
|
|
46
|
+
t6 = actions && current && /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", {
|
|
47
|
+
className: require_ds_stepper_module.default.stepActions,
|
|
48
|
+
children: actions
|
|
49
|
+
});
|
|
50
|
+
$[10] = actions;
|
|
51
|
+
$[11] = current;
|
|
52
|
+
$[12] = t6;
|
|
53
|
+
} else t6 = $[12];
|
|
54
|
+
let t7;
|
|
55
|
+
if ($[13] !== t3 || $[14] !== t4 || $[15] !== t5 || $[16] !== t6) {
|
|
56
|
+
t7 = /* @__PURE__ */ (0, react_jsx_runtime.jsxs)("div", {
|
|
57
|
+
className: t3,
|
|
58
|
+
children: [
|
|
59
|
+
t4,
|
|
60
|
+
t5,
|
|
61
|
+
t6
|
|
62
|
+
]
|
|
63
|
+
});
|
|
64
|
+
$[13] = t3;
|
|
65
|
+
$[14] = t4;
|
|
66
|
+
$[15] = t5;
|
|
67
|
+
$[16] = t6;
|
|
68
|
+
$[17] = t7;
|
|
69
|
+
} else t7 = $[17];
|
|
70
|
+
return t7;
|
|
25
71
|
}
|
|
26
72
|
|
|
27
73
|
//#endregion
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react_jsx_runtime39 from "react/jsx-runtime";
|
|
2
2
|
import { ReactNode } from "react";
|
|
3
3
|
|
|
4
4
|
//#region src/components/ds-stepper/components/ds-step-content.d.ts
|
|
@@ -13,7 +13,7 @@ declare function DsStepContent({
|
|
|
13
13
|
label,
|
|
14
14
|
description,
|
|
15
15
|
actions
|
|
16
|
-
}: DsStepContentProps):
|
|
16
|
+
}: DsStepContentProps): react_jsx_runtime39.JSX.Element;
|
|
17
17
|
//#endregion
|
|
18
18
|
export { DsStepContent };
|
|
19
19
|
//# sourceMappingURL=ds-step-content.d.cts.map
|
|
@@ -2,24 +2,70 @@ import ds_stepper_module_default from "../ds-stepper.module.js";
|
|
|
2
2
|
import { useStepper } from "../hooks/use-stepper.js";
|
|
3
3
|
import { DsStepLabel } from "./ds-step-label.js";
|
|
4
4
|
import { DsStepDescription } from "./ds-step-description.js";
|
|
5
|
+
import { c } from "react/compiler-runtime";
|
|
5
6
|
import classNames from "classnames";
|
|
6
7
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
7
8
|
|
|
8
9
|
//#region src/components/ds-stepper/components/ds-step-content.tsx
|
|
9
|
-
function DsStepContent(
|
|
10
|
+
function DsStepContent(t0) {
|
|
11
|
+
const $ = c(18);
|
|
12
|
+
const { index, label, description, actions } = t0;
|
|
10
13
|
const { variant, stepsApi } = useStepper();
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
14
|
+
let t1;
|
|
15
|
+
if ($[0] !== index || $[1] !== stepsApi) {
|
|
16
|
+
t1 = stepsApi.getItemState({ index });
|
|
17
|
+
$[0] = index;
|
|
18
|
+
$[1] = stepsApi;
|
|
19
|
+
$[2] = t1;
|
|
20
|
+
} else t1 = $[2];
|
|
21
|
+
const { current } = t1;
|
|
22
|
+
const t2 = variant === "single";
|
|
23
|
+
let t3;
|
|
24
|
+
if ($[3] !== t2) {
|
|
25
|
+
t3 = classNames(ds_stepper_module_default.stepContent, { [ds_stepper_module_default.stepContentSingle]: t2 });
|
|
26
|
+
$[3] = t2;
|
|
27
|
+
$[4] = t3;
|
|
28
|
+
} else t3 = $[4];
|
|
29
|
+
let t4;
|
|
30
|
+
if ($[5] !== label) {
|
|
31
|
+
t4 = /* @__PURE__ */ jsx(DsStepLabel, { children: label });
|
|
32
|
+
$[5] = label;
|
|
33
|
+
$[6] = t4;
|
|
34
|
+
} else t4 = $[6];
|
|
35
|
+
let t5;
|
|
36
|
+
if ($[7] !== description || $[8] !== variant) {
|
|
37
|
+
t5 = variant !== "single" && description && /* @__PURE__ */ jsx(DsStepDescription, { children: description });
|
|
38
|
+
$[7] = description;
|
|
39
|
+
$[8] = variant;
|
|
40
|
+
$[9] = t5;
|
|
41
|
+
} else t5 = $[9];
|
|
42
|
+
let t6;
|
|
43
|
+
if ($[10] !== actions || $[11] !== current) {
|
|
44
|
+
t6 = actions && current && /* @__PURE__ */ jsx("div", {
|
|
45
|
+
className: ds_stepper_module_default.stepActions,
|
|
46
|
+
children: actions
|
|
47
|
+
});
|
|
48
|
+
$[10] = actions;
|
|
49
|
+
$[11] = current;
|
|
50
|
+
$[12] = t6;
|
|
51
|
+
} else t6 = $[12];
|
|
52
|
+
let t7;
|
|
53
|
+
if ($[13] !== t3 || $[14] !== t4 || $[15] !== t5 || $[16] !== t6) {
|
|
54
|
+
t7 = /* @__PURE__ */ jsxs("div", {
|
|
55
|
+
className: t3,
|
|
56
|
+
children: [
|
|
57
|
+
t4,
|
|
58
|
+
t5,
|
|
59
|
+
t6
|
|
60
|
+
]
|
|
61
|
+
});
|
|
62
|
+
$[13] = t3;
|
|
63
|
+
$[14] = t4;
|
|
64
|
+
$[15] = t5;
|
|
65
|
+
$[16] = t6;
|
|
66
|
+
$[17] = t7;
|
|
67
|
+
} else t7 = $[17];
|
|
68
|
+
return t7;
|
|
23
69
|
}
|
|
24
70
|
|
|
25
71
|
//#endregion
|