@caseparts-org/caseblocks 0.0.250 → 0.0.251
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Table-f_q_CCA-.js +187 -0
- package/dist/assets/Select.css +1 -1
- package/dist/assets/Table.css +1 -1
- package/dist/atoms/Pill/Pill.d.ts +3 -2
- package/dist/atoms/Pill/Pill.js +29 -26
- package/dist/atoms/Select/Select.js +53 -42
- package/dist/main-client.js +1 -1
- package/dist/molecules/CustomWizardBadge/CustomWizardBadge.d.ts +3 -2
- package/dist/molecules/CustomWizardBadge/CustomWizardBadge.js +23 -22
- package/dist/molecules/Disclaimer/Disclaimer.d.ts +11 -10
- package/dist/molecules/Disclaimer/Disclaimer.js +44 -41
- package/dist/molecules/Disclaimer/Disclaimer.stories.d.ts +5 -5
- package/dist/molecules/Error/Error.d.ts +4 -3
- package/dist/molecules/Error/Error.js +104 -101
- package/dist/molecules/Table/Table.d.ts +7 -4
- package/dist/molecules/Table/Table.js +4 -3
- package/dist/molecules/Table/Table.stories.js +1 -1
- package/package.json +1 -1
- package/dist/Table-BX4PtCNE.js +0 -178
|
@@ -0,0 +1,187 @@
|
|
|
1
|
+
import { jsx as a, jsxs as V } from "react/jsx-runtime";
|
|
2
|
+
import c from "react";
|
|
3
|
+
import { c as m } from "./clsx-OuTLNxxd.js";
|
|
4
|
+
import { getHideAtStyles as E } from "./atoms/HideAt.js";
|
|
5
|
+
import { Icon as ee } from "./atoms/Icon/Icon.js";
|
|
6
|
+
import './assets/Table.css';const ne = "_bordered_xcio5_8", te = "_table_xcio5_2", le = "_columnContent_xcio5_40", oe = "_columnLabel_xcio5_49", ae = "_clickableHeader_xcio5_69", ce = "_columnsRow_xcio5_76", se = "_noPaddingRow_xcio5_127", de = "_clickableRow_xcio5_138", ie = "_clickableCell_xcio5_139", re = "_expandedContentCell_xcio5_141", me = "_expandedContentRow_xcio5_150", ue = "_expandedRow_xcio5_155", pe = "_expanded_xcio5_141", n = {
|
|
7
|
+
"table-container": "_table-container_xcio5_2",
|
|
8
|
+
bordered: ne,
|
|
9
|
+
table: te,
|
|
10
|
+
"table-alternating": "_table-alternating_xcio5_22",
|
|
11
|
+
columnContent: le,
|
|
12
|
+
columnLabel: oe,
|
|
13
|
+
"sorted-column": "_sorted-column_xcio5_58",
|
|
14
|
+
clickableHeader: ae,
|
|
15
|
+
"icon-ascending": "_icon-ascending_xcio5_70",
|
|
16
|
+
columnsRow: ce,
|
|
17
|
+
noPaddingRow: se,
|
|
18
|
+
clickableRow: de,
|
|
19
|
+
clickableCell: ie,
|
|
20
|
+
expandedContentCell: re,
|
|
21
|
+
expandedContentRow: me,
|
|
22
|
+
expandedRow: ue,
|
|
23
|
+
expanded: pe
|
|
24
|
+
}, L = ({ children: u }) => null;
|
|
25
|
+
L.displayName = "Table.Columns";
|
|
26
|
+
const j = ({ children: u }) => null;
|
|
27
|
+
j.displayName = "Table.Column";
|
|
28
|
+
const M = ({ children: u }) => null;
|
|
29
|
+
M.displayName = "Table.Body";
|
|
30
|
+
const O = ({ children: u }) => null;
|
|
31
|
+
O.displayName = "Table.Row";
|
|
32
|
+
const z = ({ children: u }) => null;
|
|
33
|
+
z.displayName = "Table.Cell";
|
|
34
|
+
const x = ({ children: u, className: D, alternatingRows: q = !1, bordered: G = !0, isSortable: H = !1, sortField: J, sortFieldKey: Q, sortOrder: U = "descending", onSort: F, hideAt: W, ...X }) => {
|
|
35
|
+
const B = [];
|
|
36
|
+
let p, g;
|
|
37
|
+
const r = (t, l) => {
|
|
38
|
+
var e;
|
|
39
|
+
return !!t && c.isValidElement(t) && ((e = t.type) == null ? void 0 : e.displayName) === l;
|
|
40
|
+
}, Y = p ? c.Children.toArray(p.props.children).map(
|
|
41
|
+
(t) => r(t, "Table.Column") ? t.props.hideAt : void 0
|
|
42
|
+
) : [];
|
|
43
|
+
c.Children.forEach(u, (t) => {
|
|
44
|
+
r(t, "Table.Columns") ? p = t : r(t, "Table.Body") ? g = t : B.push(t);
|
|
45
|
+
});
|
|
46
|
+
const v = (t) => t.flatMap((l) => {
|
|
47
|
+
if (c.isValidElement(l) && l.type === c.Fragment) {
|
|
48
|
+
const e = l.props.children;
|
|
49
|
+
return c.Children.toArray(e);
|
|
50
|
+
}
|
|
51
|
+
return [l];
|
|
52
|
+
}), Z = () => {
|
|
53
|
+
if (!p) return null;
|
|
54
|
+
const t = c.Children.toArray(p.props.children);
|
|
55
|
+
return /* @__PURE__ */ a("thead", { className: n.thead, children: /* @__PURE__ */ a("tr", { ...p.props, className: n.columnsRow, children: t.map((l, e) => {
|
|
56
|
+
if (r(l, "Table.Column")) {
|
|
57
|
+
const d = l, {
|
|
58
|
+
children: o,
|
|
59
|
+
align: i,
|
|
60
|
+
colSpan: C,
|
|
61
|
+
width: R,
|
|
62
|
+
style: k,
|
|
63
|
+
sortField: y,
|
|
64
|
+
sortFieldKey: s,
|
|
65
|
+
hideAt: b,
|
|
66
|
+
...T
|
|
67
|
+
} = d.props, w = {
|
|
68
|
+
textAlign: i ?? "left",
|
|
69
|
+
width: R,
|
|
70
|
+
...k
|
|
71
|
+
}, A = i === "right" ? "flex-end" : i === "center" ? "center" : "flex-start", h = !!y, N = H && h && (h && J === y) && (s !== void 0 ? Q === s : !0), _ = H && h && typeof F == "function";
|
|
72
|
+
return /* @__PURE__ */ a(
|
|
73
|
+
"th",
|
|
74
|
+
{
|
|
75
|
+
className: m(n.th, N && n["sorted-column"], _ && n.clickableHeader, E(b)),
|
|
76
|
+
style: w,
|
|
77
|
+
colSpan: C,
|
|
78
|
+
onClick: _ ? () => F(y, s) : void 0,
|
|
79
|
+
...T,
|
|
80
|
+
children: /* @__PURE__ */ V("div", { className: n.columnContent, style: { justifyContent: A }, children: [
|
|
81
|
+
/* @__PURE__ */ a("span", { className: n.columnLabel, children: o }),
|
|
82
|
+
N && /* @__PURE__ */ a("span", { className: m(U === "ascending" && n["icon-ascending"]), children: /* @__PURE__ */ a(ee, { iconKey: "fa-solid fa-chevron-down", size: "3xs" }) })
|
|
83
|
+
] })
|
|
84
|
+
},
|
|
85
|
+
e
|
|
86
|
+
);
|
|
87
|
+
}
|
|
88
|
+
return /* @__PURE__ */ a("th", { className: n.th, children: l }, e);
|
|
89
|
+
}) }) });
|
|
90
|
+
}, f = (t, l, e) => {
|
|
91
|
+
const d = c.Children.toArray(t).map((s, b) => {
|
|
92
|
+
if (r(s, "Table.Cell")) {
|
|
93
|
+
const T = s, {
|
|
94
|
+
children: w,
|
|
95
|
+
align: A,
|
|
96
|
+
colSpan: h,
|
|
97
|
+
width: S,
|
|
98
|
+
style: K,
|
|
99
|
+
hideAt: N,
|
|
100
|
+
..._
|
|
101
|
+
} = T.props, I = {
|
|
102
|
+
textAlign: A ?? "left",
|
|
103
|
+
width: S,
|
|
104
|
+
...K
|
|
105
|
+
}, P = !!(_ && typeof _.onClick == "function");
|
|
106
|
+
return /* @__PURE__ */ a(
|
|
107
|
+
"td",
|
|
108
|
+
{
|
|
109
|
+
className: m(
|
|
110
|
+
n.cell,
|
|
111
|
+
(e == null ? void 0 : e.isExpanded) && n.expanded,
|
|
112
|
+
(e == null ? void 0 : e.isExpandedContent) && n.expandedContentCell,
|
|
113
|
+
P && n.clickableCell,
|
|
114
|
+
E(N ?? Y[b])
|
|
115
|
+
),
|
|
116
|
+
style: I,
|
|
117
|
+
colSpan: h,
|
|
118
|
+
..._,
|
|
119
|
+
children: w
|
|
120
|
+
},
|
|
121
|
+
b
|
|
122
|
+
);
|
|
123
|
+
}
|
|
124
|
+
return c.isValidElement(s) && typeof s.type == "string" && s.type === "td" ? s : /* @__PURE__ */ a(
|
|
125
|
+
"td",
|
|
126
|
+
{
|
|
127
|
+
className: m(
|
|
128
|
+
n.cell,
|
|
129
|
+
(e == null ? void 0 : e.isExpanded) && n.expanded,
|
|
130
|
+
(e == null ? void 0 : e.isExpandedContent) && n.expandedContentCell
|
|
131
|
+
),
|
|
132
|
+
children: s
|
|
133
|
+
},
|
|
134
|
+
b
|
|
135
|
+
);
|
|
136
|
+
}), { className: o, style: i, isExpanded: C, isExpandedContent: R, ...k } = e ?? {}, y = !!(e && typeof e.onClick == "function");
|
|
137
|
+
return /* @__PURE__ */ a(
|
|
138
|
+
"tr",
|
|
139
|
+
{
|
|
140
|
+
className: m(
|
|
141
|
+
n.row,
|
|
142
|
+
o,
|
|
143
|
+
C && n.expandedRow,
|
|
144
|
+
R && n.noPaddingRow,
|
|
145
|
+
R && n.expandedContentRow,
|
|
146
|
+
y && n.clickableRow
|
|
147
|
+
),
|
|
148
|
+
style: i,
|
|
149
|
+
...k,
|
|
150
|
+
children: d
|
|
151
|
+
},
|
|
152
|
+
l
|
|
153
|
+
);
|
|
154
|
+
}, $ = () => {
|
|
155
|
+
if (g) {
|
|
156
|
+
const d = v(c.Children.toArray(g.props.children)).map((o, i) => {
|
|
157
|
+
if (r(o, "Table.Row")) {
|
|
158
|
+
const C = o;
|
|
159
|
+
return f(C.props.children, i, C.props);
|
|
160
|
+
}
|
|
161
|
+
return c.isValidElement(o) && typeof o.type == "string" && o.type === "tr" ? o : f(o, i);
|
|
162
|
+
});
|
|
163
|
+
return /* @__PURE__ */ a("tbody", { className: n.tbody, children: d });
|
|
164
|
+
}
|
|
165
|
+
const l = v(B).map((e, d) => {
|
|
166
|
+
if (r(e, "Table.Row")) {
|
|
167
|
+
const o = e;
|
|
168
|
+
return f(o.props.children, d, o.props);
|
|
169
|
+
}
|
|
170
|
+
return c.isValidElement(e) && typeof e.type == "string" && e.type === "tr" ? e : f(e, d);
|
|
171
|
+
});
|
|
172
|
+
return /* @__PURE__ */ a("tbody", { className: n.tbody, children: l });
|
|
173
|
+
};
|
|
174
|
+
return /* @__PURE__ */ a("div", { className: m(n["table-container"], G && n.bordered), children: /* @__PURE__ */ V("table", { className: m(n.table, D, q && n["table-alternating"], E(W)), ...X, children: [
|
|
175
|
+
Z(),
|
|
176
|
+
$()
|
|
177
|
+
] }) });
|
|
178
|
+
};
|
|
179
|
+
x.Columns = L;
|
|
180
|
+
x.Column = j;
|
|
181
|
+
x.Body = M;
|
|
182
|
+
x.Row = O;
|
|
183
|
+
x.Cell = z;
|
|
184
|
+
export {
|
|
185
|
+
x as T,
|
|
186
|
+
n as s
|
|
187
|
+
};
|
package/dist/assets/Select.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
._select-
|
|
1
|
+
._select-container_kfi8n_1{display:flex;position:relative;flex-direction:column;align-items:flex-start;width:100%;box-sizing:border-box}._select_kfi8n_1{height:32px;min-height:32px;width:100%;box-sizing:border-box;border:1px solid var(--border-border-primary, #dfdfdf);border-radius:var(--radius-radius-sm, .25rem);background:var(--surface-surface-primary);color:var(--text-text-primary, #272727);font-size:var(--font-size-sm, .875rem);padding:0 var(--spacing-spacing-2xl, 32px) 0 var(--spacing-spacing-1xs, 12px);outline:none;-webkit-appearance:none;-moz-appearance:none;appearance:none}@media (max-width: 767px){._select_kfi8n_1{font-size:var(--font-size-md)}}._icon_kfi8n_29{position:absolute;top:50%;right:var(--spacing-spacing-default);pointer-events:none;transform:translateY(-50%)}._select_kfi8n_1:hover:not(:disabled){border:1px solid var(--border-border-primary-btn, #1380b1)}._select_kfi8n_1:focus:not(:disabled){border:1px solid var(--border-border-primary-btn, #1380b1);box-shadow:0 0 2px 1px var(--border-border-primary-btn, #1380b1)}._select_kfi8n_1:disabled{border:1px solid var(--border-border-primary, #dfdfdf);background-color:var(--surface-surface-secondary, #f6f6f6);color:var(--text-text-disabled, #b2b2b2);cursor:not-allowed}._select_kfi8n_1:disabled:hover,._select_kfi8n_1:disabled:focus{border:1px solid var(--border-border-primary, #dfdfdf);box-shadow:none}._selectError_kfi8n_59{border-color:var(--text-text-error-warning, #d40000)}._label_kfi8n_63{position:absolute;align-self:flex-start;left:8px;top:-8px;z-index:1;padding:0 8px;cursor:text;transition:all .2s ease-in;font-family:var(--font-family-label);font-size:var(--font-size-xxs);color:var(--text-text-quaternary);background-color:var(--surface-surface-primary)}._labelPlaceholder_kfi8n_78{position:absolute;align-self:flex-start;box-sizing:border-box;max-width:calc(100% - 24px);z-index:1;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-style:italic;font-family:var(--font-family-label);font-size:var(--font-size-sm);background-color:transparent;color:var(--text-text-quaternary);left:12px;top:8px;padding:0 2px;pointer-events:none;transition:all .2s ease-in}._labelDisabled_kfi8n_99{color:var(--text-text-disabled, #b2b2b2)}._errorMessage_kfi8n_103{width:100%;margin-top:4px;font-size:var(--font-size-xs, .75rem);color:var(--text-text-error-warning, #d40000)}
|
package/dist/assets/Table.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
._table-
|
|
1
|
+
._table-container_xcio5_2{border-radius:var(--border-radius-sm);overflow-x:hidden;width:100%}._bordered_xcio5_8{border:1px solid var(--border-border-primary)}._table_xcio5_2{min-width:100%;max-width:1056px;width:max-content;border-collapse:collapse;table-layout:fixed}._table-alternating_xcio5_22 tr:nth-child(2n){background-color:#f0f0f0}._table_xcio5_2 th,._table_xcio5_2 td{max-width:clamp(72px,10vw,180px);min-width:60px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._columnContent_xcio5_40{display:flex;flex-direction:row;align-items:center;gap:var(--spacing-spacing-4xs);width:100%;min-width:0}._columnLabel_xcio5_49{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._sorted-column_xcio5_58 svg,._sorted-column_xcio5_58 i{height:8px;width:8px;transition:transform .3s ease-in-out;vertical-align:middle;padding:0;margin:0 0 0 4px}._table_xcio5_2 th._clickableHeader_xcio5_69{cursor:pointer}._icon-ascending_xcio5_70 svg,._icon-ascending_xcio5_70 i{transform:rotate(180deg)}._columnsRow_xcio5_76{background-color:var(--surface-surface-secondary)}._table_xcio5_2 th{border-bottom:1px solid var(--border-border-primary);cursor:auto;transition:background-color .2s ease-in}._table_xcio5_2 th:hover{background-color:#f0f0f0}._sorted-column_xcio5_58{text-align:start;font-size:var(--font-size-xs);font-weight:var(--font-weight-semibold);color:var(--text-text-quaternary);row-gap:4px}._table_xcio5_2 th:not(._sorted-column_xcio5_58){text-align:start;font-size:var(--font-size-xs);font-weight:var(--font-weight-medium);color:var(--text-text-quaternary)}._table_xcio5_2 th:last-of-type,._table_xcio5_2 td:last-of-type{border-top-right-radius:var(--border-radius-sm);text-align:end;padding-right:.5rem}._table_xcio5_2 th:first-of-type,._table_xcio5_2 td:first-of-type{border-top-left-radius:var(--border-radius-sm);text-align:start;padding:.45rem .5rem}._table_xcio5_2 th:not(:first-of-type):not(:last-of-type),._table_xcio5_2 td:not(:first-of-type):not(:last-of-type){padding:.45rem .5rem}._noPaddingRow_xcio5_127 td{padding:0!important}._table_xcio5_2 td{text-align:start;cursor:auto}._table_xcio5_2 ._clickableRow_xcio5_138 td,._table_xcio5_2 td._clickableCell_xcio5_139{cursor:pointer}._table_xcio5_2 td:not(._expandedContentCell_xcio5_141){border-bottom:1px solid var(--border-border-primary)}._table_xcio5_2>tbody tr{transition:background-color .2s linear}._table_xcio5_2>tbody tr:not(._expandedContentRow_xcio5_150):hover{background-color:var(--color-neutrals-neutral-1)}._expandedRow_xcio5_155 td:first-of-type{border-left:1px solid var(--border-border-black-box)}._expandedRow_xcio5_155 td:last-of-type{border-right:1px solid var(--border-border-black-box)}._expanded_xcio5_141{border-top:4px solid var(--color-brand-primary-primary-teal-blue)}._expandedContentCell_xcio5_141{border-left:1px solid var(--border-border-black-box);border-right:1px solid var(--border-border-black-box);border-bottom:1px solid var(--border-border-black-box);border-top:0}._expandedContentRow_xcio5_150{background-color:transparent}._new-column_xcio5_182{animation:_highlight_xcio5_1 2s ease-in-out}@keyframes _highlight_xcio5_1{0%{background-color:#ff0}to{background-color:transparent}}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { default as React, ReactNode } from 'react';
|
|
2
2
|
import { TextColorToken, TextWeight } from '../Text/Text';
|
|
3
|
-
|
|
3
|
+
import { HideAtProps } from '../HideAt';
|
|
4
|
+
export interface PillProps extends React.HTMLAttributes<HTMLSpanElement>, HideAtProps {
|
|
4
5
|
children: ReactNode;
|
|
5
6
|
colorToken?: "neutral" | "secondary" | "caution-tips" | "warning" | "success" | "error-warning";
|
|
6
7
|
customColor?: string;
|
|
@@ -11,4 +12,4 @@ export interface PillProps extends React.HTMLAttributes<HTMLSpanElement> {
|
|
|
11
12
|
size?: "xs" | "sm" | "md";
|
|
12
13
|
className?: string;
|
|
13
14
|
}
|
|
14
|
-
export declare function Pill({ colorToken, textColorToken, customColor, weight, uppercase, hideBorder, size, className, children, ...otherProps }: PillProps): import("react/jsx-runtime").JSX.Element;
|
|
15
|
+
export declare function Pill({ colorToken, textColorToken, customColor, weight, uppercase, hideBorder, size, hideAt, className, children, ...otherProps }: PillProps): import("react/jsx-runtime").JSX.Element;
|
package/dist/atoms/Pill/Pill.js
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { Text as
|
|
3
|
-
import { c as
|
|
4
|
-
import
|
|
5
|
-
|
|
1
|
+
import { jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import { Text as j } from "../Text/Text.js";
|
|
3
|
+
import { c as p } from "../../clsx-OuTLNxxd.js";
|
|
4
|
+
import { getHideAtStyles as m } from "../HideAt.js";
|
|
5
|
+
import '../../assets/Pill.css';const b = "_pill_i5js9_1", g = "_noBorder_i5js9_137", w = "_uppercase_i5js9_145", l = {
|
|
6
|
+
pill: b,
|
|
6
7
|
"pill-xs": "_pill-xs_i5js9_17",
|
|
7
8
|
"pill-sm": "_pill-sm_i5js9_25",
|
|
8
9
|
"pill-md": "_pill-md_i5js9_33",
|
|
@@ -18,41 +19,43 @@ import '../../assets/Pill.css';const j = "_pill_i5js9_1", m = "_noBorder_i5js9_1
|
|
|
18
19
|
"pill-border-warning": "_pill-border-warning_i5js9_113",
|
|
19
20
|
"pill-border-success": "_pill-border-success_i5js9_121",
|
|
20
21
|
"pill-border-error-warning": "_pill-border-error-warning_i5js9_129",
|
|
21
|
-
noBorder:
|
|
22
|
-
uppercase:
|
|
22
|
+
noBorder: g,
|
|
23
|
+
uppercase: w
|
|
23
24
|
};
|
|
24
|
-
function
|
|
25
|
-
colorToken:
|
|
26
|
-
textColorToken:
|
|
25
|
+
function $({
|
|
26
|
+
colorToken: r = "success",
|
|
27
|
+
textColorToken: _,
|
|
27
28
|
customColor: s,
|
|
28
29
|
weight: c = "medium",
|
|
29
30
|
uppercase: n = !1,
|
|
30
31
|
hideBorder: o = !1,
|
|
31
32
|
size: i = "xs",
|
|
32
|
-
|
|
33
|
+
hideAt: a,
|
|
34
|
+
className: t,
|
|
33
35
|
children: d,
|
|
34
|
-
...
|
|
36
|
+
...u
|
|
35
37
|
}) {
|
|
36
|
-
return /* @__PURE__ */
|
|
38
|
+
return /* @__PURE__ */ e(
|
|
37
39
|
"span",
|
|
38
40
|
{
|
|
39
|
-
className:
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
!o &&
|
|
44
|
-
o &&
|
|
45
|
-
a
|
|
41
|
+
className: p(
|
|
42
|
+
l.pill,
|
|
43
|
+
l[`pill-color-${r}`],
|
|
44
|
+
l[`pill-${i}`],
|
|
45
|
+
!o && l[`pill-border-${r}`],
|
|
46
|
+
o && l.noBorder,
|
|
47
|
+
m(a),
|
|
48
|
+
t
|
|
46
49
|
),
|
|
47
50
|
style: s ? { background: s } : void 0,
|
|
48
|
-
...
|
|
49
|
-
children: /* @__PURE__ */
|
|
50
|
-
|
|
51
|
+
...u,
|
|
52
|
+
children: /* @__PURE__ */ e(
|
|
53
|
+
j,
|
|
51
54
|
{
|
|
52
55
|
size: i === "xs" ? "xxs" : i === "sm" ? "xs" : "sm",
|
|
53
56
|
weight: c,
|
|
54
|
-
colorToken:
|
|
55
|
-
className:
|
|
57
|
+
colorToken: _ ?? (r === "neutral" ? "primary" : r === "secondary" ? "secondary" : r === "success" ? "success" : r === "error-warning" ? "error-warning" : "warning"),
|
|
58
|
+
className: p(n && l.uppercase),
|
|
56
59
|
children: d
|
|
57
60
|
}
|
|
58
61
|
)
|
|
@@ -60,5 +63,5 @@ function y({
|
|
|
60
63
|
);
|
|
61
64
|
}
|
|
62
65
|
export {
|
|
63
|
-
|
|
66
|
+
$ as Pill
|
|
64
67
|
};
|
|
@@ -1,68 +1,79 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import
|
|
3
|
-
import { c as
|
|
4
|
-
import { getHideAtStyles as
|
|
5
|
-
import
|
|
6
|
-
|
|
7
|
-
select:
|
|
8
|
-
|
|
1
|
+
import { jsxs as u, jsx as a } from "react/jsx-runtime";
|
|
2
|
+
import w, { useState as E } from "react";
|
|
3
|
+
import { c as f } from "../../clsx-OuTLNxxd.js";
|
|
4
|
+
import { getHideAtStyles as M } from "../HideAt.js";
|
|
5
|
+
import { Icon as F } from "../Icon/Icon.js";
|
|
6
|
+
import '../../assets/Select.css';const V = "_select_kfi8n_1", j = "_icon_kfi8n_29", I = "_selectError_kfi8n_59", L = "_label_kfi8n_63", P = "_labelPlaceholder_kfi8n_78", R = "_labelDisabled_kfi8n_99", z = "_errorMessage_kfi8n_103", e = {
|
|
7
|
+
"select-container": "_select-container_kfi8n_1",
|
|
8
|
+
select: V,
|
|
9
|
+
icon: j,
|
|
10
|
+
selectError: I,
|
|
9
11
|
label: L,
|
|
10
12
|
labelPlaceholder: P,
|
|
11
13
|
labelDisabled: R,
|
|
12
|
-
errorMessage:
|
|
13
|
-
},
|
|
14
|
+
errorMessage: z
|
|
15
|
+
}, A = w.forwardRef(
|
|
14
16
|
({
|
|
15
17
|
label: s,
|
|
16
|
-
placeholder:
|
|
17
|
-
options:
|
|
18
|
+
placeholder: o,
|
|
19
|
+
options: k,
|
|
18
20
|
value: m,
|
|
19
|
-
defaultValue:
|
|
21
|
+
defaultValue: i,
|
|
20
22
|
hideAt: g,
|
|
21
23
|
className: D,
|
|
22
|
-
error:
|
|
23
|
-
onFocus:
|
|
24
|
-
onBlur:
|
|
25
|
-
...
|
|
26
|
-
},
|
|
27
|
-
const [
|
|
28
|
-
return /* @__PURE__ */
|
|
29
|
-
(s ||
|
|
24
|
+
error: t,
|
|
25
|
+
onFocus: r,
|
|
26
|
+
onBlur: d,
|
|
27
|
+
...c
|
|
28
|
+
}, N) => {
|
|
29
|
+
const [S, b] = E(!1), x = !!c.disabled, n = m !== void 0, v = n ? String(m ?? "") : void 0, h = !n && i !== void 0 && i !== null ? String(i) : "", _ = !!s && (S || (n ? v !== "" : h !== "")), y = !!o && !_, p = s ? "" : o ?? "";
|
|
30
|
+
return /* @__PURE__ */ u("div", { className: f(e["select-container"], M(g)), children: [
|
|
31
|
+
(s || y) && /* @__PURE__ */ a(
|
|
30
32
|
"label",
|
|
31
33
|
{
|
|
32
|
-
htmlFor:
|
|
33
|
-
className:
|
|
34
|
-
|
|
35
|
-
x ?
|
|
34
|
+
htmlFor: c.name,
|
|
35
|
+
className: f(
|
|
36
|
+
_ ? e.label : e.labelPlaceholder,
|
|
37
|
+
x ? e.labelDisabled : void 0
|
|
36
38
|
),
|
|
37
|
-
children:
|
|
39
|
+
children: _ ? s : o ?? s
|
|
38
40
|
}
|
|
39
41
|
),
|
|
40
|
-
/* @__PURE__ */
|
|
42
|
+
/* @__PURE__ */ u(
|
|
41
43
|
"select",
|
|
42
44
|
{
|
|
43
|
-
...
|
|
44
|
-
ref:
|
|
45
|
-
id:
|
|
46
|
-
value:
|
|
47
|
-
defaultValue:
|
|
48
|
-
className:
|
|
49
|
-
onFocus: (
|
|
50
|
-
|
|
45
|
+
...c,
|
|
46
|
+
ref: N,
|
|
47
|
+
id: c.name,
|
|
48
|
+
value: v,
|
|
49
|
+
defaultValue: n ? void 0 : h,
|
|
50
|
+
className: f(e.select, t ? e.selectError : void 0, D),
|
|
51
|
+
onFocus: (l) => {
|
|
52
|
+
b(!0), r == null || r(l);
|
|
51
53
|
},
|
|
52
|
-
onBlur: (
|
|
53
|
-
|
|
54
|
+
onBlur: (l) => {
|
|
55
|
+
b(!1), d == null || d(l);
|
|
54
56
|
},
|
|
55
57
|
children: [
|
|
56
|
-
|
|
57
|
-
|
|
58
|
+
o ? /* @__PURE__ */ a("option", { value: "", disabled: !0, hidden: !!s, children: p }) : null,
|
|
59
|
+
k.map((l) => /* @__PURE__ */ a("option", { value: l.value, children: l.label }, l.value))
|
|
58
60
|
]
|
|
59
61
|
}
|
|
60
62
|
),
|
|
61
|
-
|
|
63
|
+
/* @__PURE__ */ a(
|
|
64
|
+
F,
|
|
65
|
+
{
|
|
66
|
+
className: e.icon,
|
|
67
|
+
iconKey: "fa-solid fa-chevron-down",
|
|
68
|
+
size: "3xs",
|
|
69
|
+
colorToken: "secondary"
|
|
70
|
+
}
|
|
71
|
+
),
|
|
72
|
+
t ? /* @__PURE__ */ a("div", { className: e.errorMessage, children: t }) : null
|
|
62
73
|
] });
|
|
63
74
|
}
|
|
64
75
|
);
|
|
65
|
-
|
|
76
|
+
A.displayName = "Select";
|
|
66
77
|
export {
|
|
67
|
-
|
|
78
|
+
A as Select
|
|
68
79
|
};
|
package/dist/main-client.js
CHANGED
|
@@ -49,7 +49,7 @@ import { AnimatedCheckMark as jo } from "./molecules/StatefulButton/AnimatedChec
|
|
|
49
49
|
import { AddToCart as Jo } from "./molecules/AddToCart/AddToCart.js";
|
|
50
50
|
import { Modal as Uo } from "./molecules/Modal/Modal.js";
|
|
51
51
|
import { ImageViewer as Yo } from "./molecules/ImageViewer/ImageViewer.js";
|
|
52
|
-
import { T as $o } from "./Table-
|
|
52
|
+
import { T as $o } from "./Table-f_q_CCA-.js";
|
|
53
53
|
import { Error as rr } from "./molecules/Error/Error.js";
|
|
54
54
|
import { MainNav as er } from "./organisms/MainNav/MainNav.js";
|
|
55
55
|
import { ChipSelector as pr } from "./organisms/ChipSelector/ChipSelector.js";
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
+
import { HideAtProps } from '../../atoms/HideAt';
|
|
1
2
|
import { TextProps } from '../../atoms/Text/Text';
|
|
2
|
-
export interface CustomWizardBadgeProps {
|
|
3
|
+
export interface CustomWizardBadgeProps extends HideAtProps {
|
|
3
4
|
href: string;
|
|
4
5
|
text?: string;
|
|
5
6
|
colorToken?: TextProps['colorToken'];
|
|
6
7
|
className?: string;
|
|
7
8
|
textClassName?: string;
|
|
8
9
|
}
|
|
9
|
-
export declare function CustomWizardBadge({ href, text, colorToken, className, textClassName, }: CustomWizardBadgeProps): import("react/jsx-runtime").JSX.Element;
|
|
10
|
+
export declare function CustomWizardBadge({ href, text, colorToken, hideAt, className, textClassName, }: CustomWizardBadgeProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,43 +1,44 @@
|
|
|
1
1
|
import { jsx as r } from "react/jsx-runtime";
|
|
2
2
|
import { c as e } from "../../clsx-OuTLNxxd.js";
|
|
3
|
-
import { Link as
|
|
4
|
-
import { Text as
|
|
5
|
-
import '../../assets/CustomWizardBadge.css';const
|
|
6
|
-
badge:
|
|
7
|
-
inherit:
|
|
8
|
-
warning:
|
|
9
|
-
disabled:
|
|
3
|
+
import { Link as c } from "../../atoms/Link/Link.js";
|
|
4
|
+
import { Text as g } from "../../atoms/Text/Text.js";
|
|
5
|
+
import '../../assets/CustomWizardBadge.css';const d = "_badge_iwjsg_1", w = "_inherit_iwjsg_31", l = "_warning_iwjsg_35", j = "_disabled_iwjsg_39", u = "_links_iwjsg_51", m = "_primary_iwjsg_59", y = "_quaternary_iwjsg_63", f = "_secondary_iwjsg_71", h = "_success_iwjsg_75", p = "_tertiary_iwjsg_79", b = "_footer_iwjsg_83", x = "_text_iwjsg_87", s = {
|
|
6
|
+
badge: d,
|
|
7
|
+
inherit: w,
|
|
8
|
+
warning: l,
|
|
9
|
+
disabled: j,
|
|
10
10
|
"error-warning": "_error-warning_iwjsg_43",
|
|
11
11
|
"default-inverted": "_default-inverted_iwjsg_47",
|
|
12
|
-
links:
|
|
12
|
+
links: u,
|
|
13
13
|
"links-hover-press": "_links-hover-press_iwjsg_55",
|
|
14
|
-
primary:
|
|
15
|
-
quaternary:
|
|
14
|
+
primary: m,
|
|
15
|
+
quaternary: y,
|
|
16
16
|
"search-bar": "_search-bar_iwjsg_67",
|
|
17
|
-
secondary:
|
|
18
|
-
success:
|
|
19
|
-
tertiary:
|
|
20
|
-
footer:
|
|
21
|
-
text:
|
|
17
|
+
secondary: f,
|
|
18
|
+
success: h,
|
|
19
|
+
tertiary: p,
|
|
20
|
+
footer: b,
|
|
21
|
+
text: x
|
|
22
22
|
};
|
|
23
|
-
function
|
|
23
|
+
function C({
|
|
24
24
|
href: i,
|
|
25
25
|
text: t = "Customize",
|
|
26
26
|
colorToken: n = "secondary",
|
|
27
|
-
|
|
28
|
-
|
|
27
|
+
hideAt: _,
|
|
28
|
+
className: a,
|
|
29
|
+
textClassName: o
|
|
29
30
|
}) {
|
|
30
|
-
return /* @__PURE__ */ r(
|
|
31
|
-
|
|
31
|
+
return /* @__PURE__ */ r(c, { href: i, unstyled: !0, hideAt: _, className: e(s.badge, s[n], a), children: /* @__PURE__ */ r(
|
|
32
|
+
g,
|
|
32
33
|
{
|
|
33
34
|
size: "xs",
|
|
34
35
|
weight: "regular",
|
|
35
36
|
colorToken: "default-inverted",
|
|
36
|
-
className: e(s.text,
|
|
37
|
+
className: e(s.text, o),
|
|
37
38
|
children: t
|
|
38
39
|
}
|
|
39
40
|
) });
|
|
40
41
|
}
|
|
41
42
|
export {
|
|
42
|
-
|
|
43
|
+
C as CustomWizardBadge
|
|
43
44
|
};
|
|
@@ -1,34 +1,35 @@
|
|
|
1
1
|
import { ComponentPropsWithoutRef, ReactNode } from 'react';
|
|
2
2
|
import { IconProps } from '../../atoms/Icon/Icon';
|
|
3
|
+
import { HideAtProps } from '../../atoms/HideAt';
|
|
3
4
|
export type DisclaimerColorToken = "neutral" | "secondary" | "caution-tips" | "warning" | "success" | "error-warning";
|
|
4
5
|
export type DisclaimerIcon = "info" | "question" | "warning" | "security" | "lock";
|
|
5
|
-
export interface DisclaimerProps extends ComponentPropsWithoutRef<"aside"
|
|
6
|
+
export interface DisclaimerProps extends ComponentPropsWithoutRef<"aside">, HideAtProps {
|
|
6
7
|
backgroundColorToken?: DisclaimerColorToken;
|
|
7
8
|
borderColorToken?: DisclaimerColorToken;
|
|
8
9
|
layout?: "inline" | "stacked";
|
|
9
10
|
}
|
|
10
|
-
export interface DisclaimerContentProps extends ComponentPropsWithoutRef<"div"
|
|
11
|
+
export interface DisclaimerContentProps extends ComponentPropsWithoutRef<"div">, HideAtProps {
|
|
11
12
|
children: ReactNode;
|
|
12
13
|
}
|
|
13
14
|
export interface DisclaimerIconProps extends Omit<IconProps, "iconKey"> {
|
|
14
15
|
icon?: DisclaimerIcon;
|
|
15
16
|
iconKey?: IconProps["iconKey"];
|
|
16
17
|
}
|
|
17
|
-
export interface DisclaimerPrimaryProps extends ComponentPropsWithoutRef<"span"
|
|
18
|
+
export interface DisclaimerPrimaryProps extends ComponentPropsWithoutRef<"span">, HideAtProps {
|
|
18
19
|
children: ReactNode;
|
|
19
20
|
}
|
|
20
|
-
export interface DisclaimerSubtextProps extends ComponentPropsWithoutRef<"span"
|
|
21
|
+
export interface DisclaimerSubtextProps extends ComponentPropsWithoutRef<"span">, HideAtProps {
|
|
21
22
|
children: ReactNode;
|
|
22
23
|
}
|
|
23
|
-
export interface DisclaimerCTAProps extends ComponentPropsWithoutRef<"div"
|
|
24
|
+
export interface DisclaimerCTAProps extends ComponentPropsWithoutRef<"div">, HideAtProps {
|
|
24
25
|
children: ReactNode;
|
|
25
26
|
}
|
|
26
|
-
declare function DisclaimerRoot({ backgroundColorToken, borderColorToken, layout, className, children, ...otherProps }: DisclaimerProps): import("react/jsx-runtime").JSX.Element;
|
|
27
|
-
declare function DisclaimerContent({ className, children, ...otherProps }: DisclaimerContentProps): import("react/jsx-runtime").JSX.Element;
|
|
27
|
+
declare function DisclaimerRoot({ backgroundColorToken, borderColorToken, layout, hideAt, className, children, ...otherProps }: DisclaimerProps): import("react/jsx-runtime").JSX.Element;
|
|
28
|
+
declare function DisclaimerContent({ hideAt, className, children, ...otherProps }: DisclaimerContentProps): import("react/jsx-runtime").JSX.Element;
|
|
28
29
|
declare function DisclaimerIcon({ icon, iconKey, className, ...otherProps }: DisclaimerIconProps): import("react/jsx-runtime").JSX.Element;
|
|
29
|
-
declare function DisclaimerPrimary({ className, children, ...otherProps }: DisclaimerPrimaryProps): import("react/jsx-runtime").JSX.Element;
|
|
30
|
-
declare function DisclaimerSubtext({ className, children, ...otherProps }: DisclaimerSubtextProps): import("react/jsx-runtime").JSX.Element;
|
|
31
|
-
declare function DisclaimerCTA({ className, children, ...otherProps }: DisclaimerCTAProps): import("react/jsx-runtime").JSX.Element;
|
|
30
|
+
declare function DisclaimerPrimary({ hideAt, className, children, ...otherProps }: DisclaimerPrimaryProps): import("react/jsx-runtime").JSX.Element;
|
|
31
|
+
declare function DisclaimerSubtext({ hideAt, className, children, ...otherProps }: DisclaimerSubtextProps): import("react/jsx-runtime").JSX.Element;
|
|
32
|
+
declare function DisclaimerCTA({ hideAt, className, children, ...otherProps }: DisclaimerCTAProps): import("react/jsx-runtime").JSX.Element;
|
|
32
33
|
export declare const Disclaimer: typeof DisclaimerRoot & {
|
|
33
34
|
Content: typeof DisclaimerContent;
|
|
34
35
|
Icon: typeof DisclaimerIcon;
|