property-practice-ui 0.2.0 → 0.3.0
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 +6 -0
- package/dist/Button-GGqCRrab.d.cts +29 -0
- package/dist/Button-GGqCRrab.d.ts +29 -0
- package/dist/FileButton-DGczdE12.d.cts +22 -0
- package/dist/FileButton-HFyj2Jod.d.ts +22 -0
- package/dist/{Textarea-BNvLsAXP.d.cts → Textarea-BVqF5_5c.d.cts} +2 -27
- package/dist/{Textarea-BNvLsAXP.d.ts → Textarea-BVqF5_5c.d.ts} +2 -27
- package/dist/atoms.d.cts +4 -2
- package/dist/atoms.d.ts +4 -2
- package/dist/index.d.cts +9 -415
- package/dist/index.d.ts +9 -415
- package/dist/molecules.cjs +2457 -0
- package/dist/molecules.cjs.map +1 -0
- package/dist/molecules.d.cts +283 -0
- package/dist/molecules.d.ts +283 -0
- package/dist/molecules.js +2431 -0
- package/dist/molecules.js.map +1 -0
- package/dist/organisms.cjs +2859 -0
- package/dist/organisms.cjs.map +1 -0
- package/dist/organisms.d.cts +126 -0
- package/dist/organisms.d.ts +126 -0
- package/dist/organisms.js +2845 -0
- package/dist/organisms.js.map +1 -0
- package/dist/{toast-CvZfLJrO.d.cts → tableListItem-irbfqxnQ.d.cts} +1 -3
- package/dist/{toast-CvZfLJrO.d.ts → tableListItem-irbfqxnQ.d.ts} +1 -3
- package/dist/toast-JPCqJveR.d.cts +3 -0
- package/dist/toast-JPCqJveR.d.ts +3 -0
- package/dist/types.d.cts +2 -1
- package/dist/types.d.ts +2 -1
- package/package.json +11 -1
- package/tsup.config.ts +2 -0
|
@@ -0,0 +1,2457 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var react = require('react');
|
|
4
|
+
var styled40 = require('styled-components');
|
|
5
|
+
var jsxRuntime = require('react/jsx-runtime');
|
|
6
|
+
var fa = require('react-icons/fa');
|
|
7
|
+
var fa6 = require('react-icons/fa6');
|
|
8
|
+
var hi2 = require('react-icons/hi2');
|
|
9
|
+
var hi = require('react-icons/hi');
|
|
10
|
+
|
|
11
|
+
function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
|
|
12
|
+
|
|
13
|
+
var styled40__default = /*#__PURE__*/_interopDefault(styled40);
|
|
14
|
+
|
|
15
|
+
// src/molecules/Accordion/Accordion.tsx
|
|
16
|
+
|
|
17
|
+
// src/tokens/colors.ts
|
|
18
|
+
var colors = {
|
|
19
|
+
background: {
|
|
20
|
+
primary: "#FFFFFF",
|
|
21
|
+
secondary: "#EEF1F5",
|
|
22
|
+
tertiary: "#1E4384",
|
|
23
|
+
subtle: "rgba(102, 153, 153, 1)",
|
|
24
|
+
blue: "#36b8e7",
|
|
25
|
+
brand: "#1D3C77",
|
|
26
|
+
success: "#00ab3fff",
|
|
27
|
+
error: "#F87171",
|
|
28
|
+
light: "#cacbcc"
|
|
29
|
+
},
|
|
30
|
+
border: {
|
|
31
|
+
primary: "#669999",
|
|
32
|
+
secondary: "rgba(30, 67, 132, 0.2)",
|
|
33
|
+
hover: "#cacbcc",
|
|
34
|
+
active: "#828282",
|
|
35
|
+
error: "#F87171",
|
|
36
|
+
focus: "#3B82F6",
|
|
37
|
+
brand: "#1D3C77",
|
|
38
|
+
light: "#f3f3f3"
|
|
39
|
+
},
|
|
40
|
+
text: {
|
|
41
|
+
brand: "#1D3C77",
|
|
42
|
+
primary: "#262626",
|
|
43
|
+
secondary: "#FFFFFF",
|
|
44
|
+
tertiary: "#669999",
|
|
45
|
+
subtle: "#919EB0",
|
|
46
|
+
light: "#b5b6b8ff",
|
|
47
|
+
error: "#F87171",
|
|
48
|
+
blue: "#3B82F6"
|
|
49
|
+
},
|
|
50
|
+
button: {
|
|
51
|
+
primary: "rgba(30, 67, 132, 0.2)",
|
|
52
|
+
hover: "rgba(30, 67, 132, 0.5)",
|
|
53
|
+
active: "rgba(30, 67, 132, 0.8)",
|
|
54
|
+
secondary: "rgba(30, 67, 132, 1)"
|
|
55
|
+
}
|
|
56
|
+
};
|
|
57
|
+
|
|
58
|
+
// src/tokens/radii.ts
|
|
59
|
+
var radii = {
|
|
60
|
+
sm: "4px",
|
|
61
|
+
md: "8px",
|
|
62
|
+
lg: "10px",
|
|
63
|
+
xl: "16px"
|
|
64
|
+
};
|
|
65
|
+
|
|
66
|
+
// src/tokens/spaces.ts
|
|
67
|
+
var spaces = {
|
|
68
|
+
0: "0px",
|
|
69
|
+
0.5: "2px",
|
|
70
|
+
1: "4px",
|
|
71
|
+
1.5: "6px",
|
|
72
|
+
2: "8px",
|
|
73
|
+
2.5: "10px",
|
|
74
|
+
3: "12px",
|
|
75
|
+
3.5: "14px",
|
|
76
|
+
4: "16px",
|
|
77
|
+
4.5: "18px",
|
|
78
|
+
5: "20px",
|
|
79
|
+
5.5: "22px",
|
|
80
|
+
6: "24px",
|
|
81
|
+
6.5: "28px",
|
|
82
|
+
7: "34px",
|
|
83
|
+
7.5: "38px",
|
|
84
|
+
8: "44px",
|
|
85
|
+
9: "56px",
|
|
86
|
+
20: "150px"
|
|
87
|
+
};
|
|
88
|
+
var Container = styled40__default.default.div`
|
|
89
|
+
width: 100%;
|
|
90
|
+
padding: ${spaces[4]};
|
|
91
|
+
`;
|
|
92
|
+
var AccordionContent = ({ children }) => {
|
|
93
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Container, { children });
|
|
94
|
+
};
|
|
95
|
+
var variants = ["brand", "teal", "blue"];
|
|
96
|
+
var StyledContainer = styled40__default.default.button`
|
|
97
|
+
padding: 0.75rem;
|
|
98
|
+
${(props) => props.as === "button" ? `
|
|
99
|
+
width: 2.5rem;
|
|
100
|
+
height: 2.5rem;
|
|
101
|
+
` : ""}
|
|
102
|
+
flex-shrink: 0;
|
|
103
|
+
background-color: ${(props) => {
|
|
104
|
+
switch (props.variant) {
|
|
105
|
+
case "brand":
|
|
106
|
+
return colors.background.brand;
|
|
107
|
+
case "teal":
|
|
108
|
+
return colors.background.subtle;
|
|
109
|
+
case "blue":
|
|
110
|
+
return colors.background.blue;
|
|
111
|
+
default:
|
|
112
|
+
return colors.background.brand;
|
|
113
|
+
}
|
|
114
|
+
}};
|
|
115
|
+
transition: all 0.2s;
|
|
116
|
+
border: none;
|
|
117
|
+
cursor: pointer;
|
|
118
|
+
display: flex;
|
|
119
|
+
align-items: center;
|
|
120
|
+
justify-content: center;
|
|
121
|
+
|
|
122
|
+
&:hover svg {
|
|
123
|
+
transform: rotate(45deg);
|
|
124
|
+
}
|
|
125
|
+
`;
|
|
126
|
+
var StyledIcon = styled40__default.default(hi2.HiArrowUpRight)`
|
|
127
|
+
width: 1rem;
|
|
128
|
+
height: 1rem;
|
|
129
|
+
color: ${colors.text.secondary};
|
|
130
|
+
transition: transform 0.2s;
|
|
131
|
+
`;
|
|
132
|
+
var ArrowButton = ({
|
|
133
|
+
onClick,
|
|
134
|
+
asChild = false,
|
|
135
|
+
variant = "brand"
|
|
136
|
+
}) => {
|
|
137
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
138
|
+
StyledContainer,
|
|
139
|
+
{
|
|
140
|
+
as: asChild ? "div" : "button",
|
|
141
|
+
onClick,
|
|
142
|
+
variant,
|
|
143
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(StyledIcon, { "aria-hidden": true })
|
|
144
|
+
}
|
|
145
|
+
);
|
|
146
|
+
};
|
|
147
|
+
ArrowButton.variants = variants;
|
|
148
|
+
var spin = styled40.keyframes`
|
|
149
|
+
to { transform: rotate(360deg); }
|
|
150
|
+
`;
|
|
151
|
+
var Ring = styled40__default.default.span`
|
|
152
|
+
display: inline-block;
|
|
153
|
+
width: ${({ size }) => typeof size === "number" ? `${size}px` : size};
|
|
154
|
+
height: ${({ size }) => typeof size === "number" ? `${size}px` : size};
|
|
155
|
+
border-radius: 50%;
|
|
156
|
+
box-sizing: border-box;
|
|
157
|
+
|
|
158
|
+
border: ${({ thickness }) => thickness}px solid ${colors.background.brand};
|
|
159
|
+
|
|
160
|
+
border-top-color: ${colors.border.active};
|
|
161
|
+
|
|
162
|
+
animation: ${spin} ${({ speed }) => speed} linear infinite;
|
|
163
|
+
|
|
164
|
+
@media (prefers-reduced-motion: reduce) {
|
|
165
|
+
animation: none;
|
|
166
|
+
border-top-color: ${colors.border.active};
|
|
167
|
+
}
|
|
168
|
+
`;
|
|
169
|
+
var Loader = ({
|
|
170
|
+
size = 32,
|
|
171
|
+
thickness = 3,
|
|
172
|
+
speed = "0.8s"
|
|
173
|
+
}) => {
|
|
174
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
175
|
+
Ring,
|
|
176
|
+
{
|
|
177
|
+
role: "status",
|
|
178
|
+
"aria-live": "polite",
|
|
179
|
+
size,
|
|
180
|
+
thickness,
|
|
181
|
+
speed
|
|
182
|
+
}
|
|
183
|
+
);
|
|
184
|
+
};
|
|
185
|
+
var ButtonTypes = ["submit", "reset", "button"];
|
|
186
|
+
var StyledButton = styled40__default.default.button`
|
|
187
|
+
padding: ${spaces[2]} ${spaces[4]};
|
|
188
|
+
background-color: ${(props) => props.variant === "light" ? colors.button.primary : colors.button.secondary};
|
|
189
|
+
border-radius: ${radii.lg};
|
|
190
|
+
color: ${(props) => props.variant === "light" ? colors.text.primary : colors.text.secondary};
|
|
191
|
+
display: flex;
|
|
192
|
+
align-items: center;
|
|
193
|
+
justify-content: center;
|
|
194
|
+
gap: ${spaces[2]};
|
|
195
|
+
max-height: 34px;
|
|
196
|
+
|
|
197
|
+
&:hover {
|
|
198
|
+
background-color: ${colors.button.hover};
|
|
199
|
+
cursor: pointer;
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
&:active {
|
|
203
|
+
background-color: ${colors.button.active};
|
|
204
|
+
color: ${colors.text.secondary};
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
&:disabled {
|
|
208
|
+
background-color: ${colors.button.primary};
|
|
209
|
+
cursor: not-allowed;
|
|
210
|
+
color: ${colors.text.primary};
|
|
211
|
+
}
|
|
212
|
+
`;
|
|
213
|
+
var ButtonText = styled40__default.default.span`
|
|
214
|
+
font-size: 12px;
|
|
215
|
+
font-weight: 700;
|
|
216
|
+
`;
|
|
217
|
+
var Button = ({
|
|
218
|
+
onClick,
|
|
219
|
+
text,
|
|
220
|
+
type = "button",
|
|
221
|
+
disabled,
|
|
222
|
+
icon = void 0,
|
|
223
|
+
variant = "light",
|
|
224
|
+
isLoading
|
|
225
|
+
}) => {
|
|
226
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
227
|
+
StyledButton,
|
|
228
|
+
{
|
|
229
|
+
type,
|
|
230
|
+
onClick,
|
|
231
|
+
disabled: disabled || isLoading,
|
|
232
|
+
variant,
|
|
233
|
+
children: !isLoading ? /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
234
|
+
typeof icon !== "undefined" && icon,
|
|
235
|
+
/* @__PURE__ */ jsxRuntime.jsx(ButtonText, { children: text })
|
|
236
|
+
] }) : /* @__PURE__ */ jsxRuntime.jsx(Loader, { size: "20px" })
|
|
237
|
+
}
|
|
238
|
+
);
|
|
239
|
+
};
|
|
240
|
+
Button.types = ButtonTypes;
|
|
241
|
+
var variants2 = ["primary", "secondary", "subtle", "error"];
|
|
242
|
+
var StyledDescription = styled40__default.default.p`
|
|
243
|
+
margin: 0;
|
|
244
|
+
font-size: 1rem;
|
|
245
|
+
line-height: 1.6;
|
|
246
|
+
color: ${(props) => {
|
|
247
|
+
switch (props.variant) {
|
|
248
|
+
case "primary":
|
|
249
|
+
return colors.text.primary;
|
|
250
|
+
case "secondary":
|
|
251
|
+
return colors.text.secondary;
|
|
252
|
+
case "subtle":
|
|
253
|
+
return colors.text.subtle;
|
|
254
|
+
case "error":
|
|
255
|
+
return colors.text.error;
|
|
256
|
+
default:
|
|
257
|
+
return colors.text.primary;
|
|
258
|
+
}
|
|
259
|
+
}};
|
|
260
|
+
`;
|
|
261
|
+
var Description = ({
|
|
262
|
+
children,
|
|
263
|
+
variant = "primary"
|
|
264
|
+
}) => {
|
|
265
|
+
return /* @__PURE__ */ jsxRuntime.jsx(StyledDescription, { variant, children });
|
|
266
|
+
};
|
|
267
|
+
Description.variants = variants2;
|
|
268
|
+
var StyledButton2 = styled40__default.default.button`
|
|
269
|
+
display: flex;
|
|
270
|
+
align-items: center;
|
|
271
|
+
height: 2.5rem;
|
|
272
|
+
border: none;
|
|
273
|
+
cursor: pointer;
|
|
274
|
+
transition: opacity 0.2s;
|
|
275
|
+
padding: 0;
|
|
276
|
+
background: transparent;
|
|
277
|
+
|
|
278
|
+
&:hover {
|
|
279
|
+
opacity: 0.9;
|
|
280
|
+
}
|
|
281
|
+
`;
|
|
282
|
+
var ExtendedButton = ({
|
|
283
|
+
text,
|
|
284
|
+
onClick,
|
|
285
|
+
arrowVariant = "teal",
|
|
286
|
+
textBgVariant = "brand",
|
|
287
|
+
textVariant = "secondary"
|
|
288
|
+
}) => {
|
|
289
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(StyledButton2, { onClick, children: [
|
|
290
|
+
/* @__PURE__ */ jsxRuntime.jsx(ArrowButton, { asChild: true, variant: arrowVariant }),
|
|
291
|
+
/* @__PURE__ */ jsxRuntime.jsx(TextButton, { asChild: true, text, bgVariant: textBgVariant, textVariant, uppercase: false })
|
|
292
|
+
] });
|
|
293
|
+
};
|
|
294
|
+
var Container2 = styled40__default.default.div`
|
|
295
|
+
display: flex;
|
|
296
|
+
gap: 1rem;
|
|
297
|
+
background-color: transparent;
|
|
298
|
+
`;
|
|
299
|
+
var ThumbnailWrapper = styled40__default.default.div`
|
|
300
|
+
width: ${(props) => props.$size || "3rem"};
|
|
301
|
+
height: ${(props) => props.$size || "3rem"};
|
|
302
|
+
border-radius: 50%;
|
|
303
|
+
background-color: ${(props) => colors.background[props.thumbnailBgColor]};
|
|
304
|
+
display: flex;
|
|
305
|
+
align-items: center;
|
|
306
|
+
justify-content: center;
|
|
307
|
+
flex-shrink: 0;
|
|
308
|
+
`;
|
|
309
|
+
var Content = styled40__default.default.div`
|
|
310
|
+
display: flex;
|
|
311
|
+
flex-direction: column;
|
|
312
|
+
gap: 0.25rem;
|
|
313
|
+
`;
|
|
314
|
+
var Title = styled40__default.default.h3`
|
|
315
|
+
margin: 0;
|
|
316
|
+
font-size: 1rem;
|
|
317
|
+
font-weight: 600;
|
|
318
|
+
color: ${(props) => colors.text[props.titleColor]};
|
|
319
|
+
`;
|
|
320
|
+
var Description2 = styled40__default.default.p`
|
|
321
|
+
margin: 0;
|
|
322
|
+
font-size: 0.875rem;
|
|
323
|
+
line-height: 1.5;
|
|
324
|
+
color: ${(props) => colors.text[props.descriptionColor]};
|
|
325
|
+
`;
|
|
326
|
+
var FeatureItem = ({
|
|
327
|
+
thumbnail,
|
|
328
|
+
title,
|
|
329
|
+
description,
|
|
330
|
+
thumbnailSize,
|
|
331
|
+
thumbnailBgColor = "brand",
|
|
332
|
+
titleColor = "primary",
|
|
333
|
+
descriptionVariant = "subtle"
|
|
334
|
+
}) => {
|
|
335
|
+
const getDescriptionColor = () => {
|
|
336
|
+
switch (descriptionVariant) {
|
|
337
|
+
case "primary":
|
|
338
|
+
return "primary";
|
|
339
|
+
case "secondary":
|
|
340
|
+
return "secondary";
|
|
341
|
+
case "subtle":
|
|
342
|
+
return "subtle";
|
|
343
|
+
case "error":
|
|
344
|
+
return "error";
|
|
345
|
+
default:
|
|
346
|
+
return "subtle";
|
|
347
|
+
}
|
|
348
|
+
};
|
|
349
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(Container2, { children: [
|
|
350
|
+
/* @__PURE__ */ jsxRuntime.jsx(ThumbnailWrapper, { $size: thumbnailSize, thumbnailBgColor, children: thumbnail }),
|
|
351
|
+
/* @__PURE__ */ jsxRuntime.jsxs(Content, { children: [
|
|
352
|
+
/* @__PURE__ */ jsxRuntime.jsx(Title, { titleColor, children: title }),
|
|
353
|
+
/* @__PURE__ */ jsxRuntime.jsx(Description2, { descriptionColor: getDescriptionColor(), children: description })
|
|
354
|
+
] })
|
|
355
|
+
] });
|
|
356
|
+
};
|
|
357
|
+
|
|
358
|
+
// src/tokens/breakpoints.ts
|
|
359
|
+
var breakpoints = {
|
|
360
|
+
sm: "640px",
|
|
361
|
+
lg: "1024px"};
|
|
362
|
+
styled40__default.default.div`
|
|
363
|
+
width: 100%;
|
|
364
|
+
display: flex;
|
|
365
|
+
justify-content: center;
|
|
366
|
+
`;
|
|
367
|
+
styled40__default.default.div`
|
|
368
|
+
display: flex;
|
|
369
|
+
flex-direction: column;
|
|
370
|
+
padding: ${spaces[4]};
|
|
371
|
+
width: 100%;
|
|
372
|
+
max-width: ${breakpoints.lg};
|
|
373
|
+
gap: ${(props) => spaces[props.space]};
|
|
374
|
+
`;
|
|
375
|
+
var variants3 = {
|
|
376
|
+
h1: {
|
|
377
|
+
fontSize: "24px",
|
|
378
|
+
fontWeight: 700,
|
|
379
|
+
letterSpacing: "0.6px",
|
|
380
|
+
lineHeight: "32px"
|
|
381
|
+
},
|
|
382
|
+
h2: {
|
|
383
|
+
fontSize: "20px",
|
|
384
|
+
fontWeight: 700,
|
|
385
|
+
lineHeight: "28px",
|
|
386
|
+
letterSpacing: "0.4px"
|
|
387
|
+
},
|
|
388
|
+
h3: {
|
|
389
|
+
fontSize: "18px",
|
|
390
|
+
fontWeight: 600,
|
|
391
|
+
lineHeight: "28px",
|
|
392
|
+
letterSpacing: "0.2px"
|
|
393
|
+
}
|
|
394
|
+
};
|
|
395
|
+
var StyledText = styled40__default.default.h1`
|
|
396
|
+
color: ${(props) => colors.text[props?.color]};
|
|
397
|
+
font-size: ${(props) => variants3[props.variant].fontSize};
|
|
398
|
+
font-weight: ${(props) => variants3[props.variant].fontWeight};
|
|
399
|
+
letter-spacing: ${(props) => variants3[props.variant].letterSpacing};
|
|
400
|
+
line-height: ${(props) => variants3[props.variant].lineHeight};
|
|
401
|
+
`;
|
|
402
|
+
var Header = ({
|
|
403
|
+
children,
|
|
404
|
+
variant = "h1",
|
|
405
|
+
color = "primary"
|
|
406
|
+
}) => {
|
|
407
|
+
return /* @__PURE__ */ jsxRuntime.jsx(StyledText, { variant, color, children });
|
|
408
|
+
};
|
|
409
|
+
|
|
410
|
+
// src/types.ts
|
|
411
|
+
var InputTypes = ["number", "text", "email", "date"];
|
|
412
|
+
var StyledInput = styled40__default.default.input`
|
|
413
|
+
display: block;
|
|
414
|
+
height: 100%;
|
|
415
|
+
width: 100%;
|
|
416
|
+
outline: none;
|
|
417
|
+
background-color: transparent;
|
|
418
|
+
color: ${colors.text.subtle};
|
|
419
|
+
font-weight: 600;
|
|
420
|
+
`;
|
|
421
|
+
var Input = ({ name, onChange, ...rest }) => {
|
|
422
|
+
return /* @__PURE__ */ jsxRuntime.jsx(StyledInput, { name, onChange, ...rest });
|
|
423
|
+
};
|
|
424
|
+
Input.types = InputTypes;
|
|
425
|
+
|
|
426
|
+
// src/tokens/sizes.ts
|
|
427
|
+
var sizes = {
|
|
428
|
+
sm: "12px",
|
|
429
|
+
lg: "18px",
|
|
430
|
+
xl: "24px",
|
|
431
|
+
0: "1px"};
|
|
432
|
+
var StyledLabel = styled40__default.default.span`
|
|
433
|
+
color: ${(props) => colors.text[props?.color]};
|
|
434
|
+
font-size: ${sizes.sm};
|
|
435
|
+
font-weight: ${(props) => props.fontWeight};
|
|
436
|
+
`;
|
|
437
|
+
var StyledFloatingLabel = styled40__default.default(StyledLabel)`
|
|
438
|
+
position: absolute;
|
|
439
|
+
left: 0;
|
|
440
|
+
bottom: 100%;
|
|
441
|
+
margin-left: ${spaces[3]};
|
|
442
|
+
margin-bottom: -${spaces[2.5]};
|
|
443
|
+
transform: translateY(-${spaces[0.5]});
|
|
444
|
+
background-color: ${colors.background.primary};
|
|
445
|
+
padding: 0 ${spaces[1]};
|
|
446
|
+
`;
|
|
447
|
+
var Label = ({
|
|
448
|
+
value,
|
|
449
|
+
color = "subtle",
|
|
450
|
+
fontWeight = "500"
|
|
451
|
+
}) => {
|
|
452
|
+
return /* @__PURE__ */ jsxRuntime.jsx(StyledLabel, { color, fontWeight, children: value });
|
|
453
|
+
};
|
|
454
|
+
var FloatingLabel = ({
|
|
455
|
+
value,
|
|
456
|
+
color = "subtle",
|
|
457
|
+
fontWeight = "500"
|
|
458
|
+
}) => {
|
|
459
|
+
return /* @__PURE__ */ jsxRuntime.jsx(StyledFloatingLabel, { color, fontWeight, children: value });
|
|
460
|
+
};
|
|
461
|
+
styled40__default.default.span`
|
|
462
|
+
display: inline-block;
|
|
463
|
+
padding: 0.5rem 1rem;
|
|
464
|
+
border-radius: 9999px;
|
|
465
|
+
font-size: 0.75rem;
|
|
466
|
+
font-weight: 600;
|
|
467
|
+
background-color: ${(props) => {
|
|
468
|
+
if (props.$inverse) return "transparent";
|
|
469
|
+
switch (props.variant) {
|
|
470
|
+
case "primary":
|
|
471
|
+
return colors.text.brand;
|
|
472
|
+
case "secondary":
|
|
473
|
+
return colors.text.blue;
|
|
474
|
+
case "subtle":
|
|
475
|
+
return colors.text.subtle;
|
|
476
|
+
case "error":
|
|
477
|
+
return colors.text.error;
|
|
478
|
+
default:
|
|
479
|
+
return colors.text.brand;
|
|
480
|
+
}
|
|
481
|
+
}};
|
|
482
|
+
color: ${(props) => {
|
|
483
|
+
if (props.$inverse) {
|
|
484
|
+
switch (props.variant) {
|
|
485
|
+
case "primary":
|
|
486
|
+
return colors.text.brand;
|
|
487
|
+
case "secondary":
|
|
488
|
+
return colors.text.blue;
|
|
489
|
+
case "subtle":
|
|
490
|
+
return colors.text.subtle;
|
|
491
|
+
case "error":
|
|
492
|
+
return colors.text.error;
|
|
493
|
+
default:
|
|
494
|
+
return colors.text.brand;
|
|
495
|
+
}
|
|
496
|
+
}
|
|
497
|
+
return colors.text.secondary;
|
|
498
|
+
}};
|
|
499
|
+
border: ${(props) => {
|
|
500
|
+
if (!props.$inverse) return "none";
|
|
501
|
+
switch (props.variant) {
|
|
502
|
+
case "primary":
|
|
503
|
+
return `1px solid ${colors.text.brand}`;
|
|
504
|
+
case "secondary":
|
|
505
|
+
return `1px solid ${colors.text.blue}`;
|
|
506
|
+
case "subtle":
|
|
507
|
+
return `1px solid ${colors.text.subtle}`;
|
|
508
|
+
case "error":
|
|
509
|
+
return `1px solid ${colors.text.error}`;
|
|
510
|
+
default:
|
|
511
|
+
return `1px solid ${colors.text.brand}`;
|
|
512
|
+
}
|
|
513
|
+
}};
|
|
514
|
+
`;
|
|
515
|
+
var Container4 = styled40__default.default.div`
|
|
516
|
+
border-radius: ${radii.md};
|
|
517
|
+
padding: ${spaces["3"]};
|
|
518
|
+
display: flex;
|
|
519
|
+
flex: 1;
|
|
520
|
+
gap: ${spaces[2]};
|
|
521
|
+
background-color: white;
|
|
522
|
+
align-items: center;
|
|
523
|
+
justify-content: center;
|
|
524
|
+
border-width: 1px;
|
|
525
|
+
border-color: ${colors.border.active};
|
|
526
|
+
transition:
|
|
527
|
+
background-color 0.25s ease,
|
|
528
|
+
box-shadow 0.35s ease,
|
|
529
|
+
transform 0.25s ease;
|
|
530
|
+
|
|
531
|
+
&:hover {
|
|
532
|
+
background-color: rgba(255, 255, 255, 0.96);
|
|
533
|
+
border-color: ${colors.border.hover};
|
|
534
|
+
cursor: pointer;
|
|
535
|
+
}
|
|
536
|
+
|
|
537
|
+
&:active {
|
|
538
|
+
background-color: rgba(255, 255, 255, 0.92);
|
|
539
|
+
}
|
|
540
|
+
`;
|
|
541
|
+
var Label2 = styled40__default.default.span`
|
|
542
|
+
font-size: 16px;
|
|
543
|
+
font-weight: ${(props) => props.isSelected ? "800" : "400"};
|
|
544
|
+
text-align: center;
|
|
545
|
+
`;
|
|
546
|
+
var RadioItem = ({ label, isSelected, onClick }) => {
|
|
547
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(Container4, { onClick, children: [
|
|
548
|
+
isSelected && /* @__PURE__ */ jsxRuntime.jsx(fa.FaCheckCircle, { color: colors.background.blue }),
|
|
549
|
+
/* @__PURE__ */ jsxRuntime.jsx(Label2, { isSelected, children: label })
|
|
550
|
+
] });
|
|
551
|
+
};
|
|
552
|
+
styled40__default.default.div`
|
|
553
|
+
width: 100%;
|
|
554
|
+
`;
|
|
555
|
+
styled40__default.default.label`
|
|
556
|
+
display: block;
|
|
557
|
+
font-size: 13px;
|
|
558
|
+
font-weight: 600;
|
|
559
|
+
color: ${(props) => props.$color ? colors.text[props.$color] : colors.text.primary};
|
|
560
|
+
opacity: 0.8;
|
|
561
|
+
margin-bottom: 0.5rem;
|
|
562
|
+
`;
|
|
563
|
+
styled40__default.default.input`
|
|
564
|
+
box-sizing: border-box;
|
|
565
|
+
height: 2.75rem;
|
|
566
|
+
width: 100%;
|
|
567
|
+
border-radius: 6px;
|
|
568
|
+
border: 1px solid ${(props) => props.$borderColor || "#d1d5db"};
|
|
569
|
+
background-color: ${(props) => props.$bgColor ? colors.background[props.$bgColor] : colors.background?.secondary};
|
|
570
|
+
padding: 0 0.75rem;
|
|
571
|
+
font-size: 15px;
|
|
572
|
+
color: ${(props) => props.$textColor ? colors.text[props.$textColor] : colors.text.primary};
|
|
573
|
+
outline: none;
|
|
574
|
+
|
|
575
|
+
&::placeholder {
|
|
576
|
+
color: ${(props) => props.$placeholderColor ? colors.text[props.$placeholderColor] : colors.text.secondary};
|
|
577
|
+
}
|
|
578
|
+
|
|
579
|
+
&:focus {
|
|
580
|
+
box-shadow: 0 0 0 2px ${(props) => {
|
|
581
|
+
const color = props.$focusRingColor ? colors.text[props.$focusRingColor] : colors.text.primary;
|
|
582
|
+
return `${color}33`;
|
|
583
|
+
}};
|
|
584
|
+
}
|
|
585
|
+
`;
|
|
586
|
+
styled40__default.default.textarea`
|
|
587
|
+
box-sizing: border-box;
|
|
588
|
+
width: 100%;
|
|
589
|
+
border-radius: 6px;
|
|
590
|
+
border: 1px solid ${(props) => props.$borderColor || "#d1d5db"};
|
|
591
|
+
background-color: ${(props) => props.$bgColor ? colors.background[props.$bgColor] : colors.background?.secondary};
|
|
592
|
+
padding: 0.75rem;
|
|
593
|
+
font-size: 15px;
|
|
594
|
+
color: ${(props) => props.$textColor ? colors.text[props.$textColor] : colors.text.primary};
|
|
595
|
+
outline: none;
|
|
596
|
+
|
|
597
|
+
&::placeholder {
|
|
598
|
+
color: ${(props) => props.$placeholderColor ? colors.text[props.$placeholderColor] : colors.text.secondary};
|
|
599
|
+
}
|
|
600
|
+
|
|
601
|
+
&:focus {
|
|
602
|
+
box-shadow: 0 0 0 2px ${(props) => {
|
|
603
|
+
const color = props.$focusRingColor ? colors.text[props.$focusRingColor] : colors.text.primary;
|
|
604
|
+
return `${color}33`;
|
|
605
|
+
}};
|
|
606
|
+
}
|
|
607
|
+
`;
|
|
608
|
+
styled40__default.default.button`
|
|
609
|
+
width: 2.5rem;
|
|
610
|
+
height: 2.5rem;
|
|
611
|
+
display: flex;
|
|
612
|
+
align-items: center;
|
|
613
|
+
justify-content: center;
|
|
614
|
+
border-radius: 4px;
|
|
615
|
+
background-color: ${(props) => {
|
|
616
|
+
switch (props.variant) {
|
|
617
|
+
case "filled":
|
|
618
|
+
return colors.background.brand;
|
|
619
|
+
case "primary":
|
|
620
|
+
case "secondary":
|
|
621
|
+
case "inverse":
|
|
622
|
+
default:
|
|
623
|
+
return "transparent";
|
|
624
|
+
}
|
|
625
|
+
}};
|
|
626
|
+
border: 2px solid ${(props) => {
|
|
627
|
+
switch (props.variant) {
|
|
628
|
+
case "primary":
|
|
629
|
+
return colors.text.brand;
|
|
630
|
+
case "secondary":
|
|
631
|
+
return colors.text.blue;
|
|
632
|
+
case "inverse":
|
|
633
|
+
return colors.text.secondary;
|
|
634
|
+
case "filled":
|
|
635
|
+
return colors.background.brand;
|
|
636
|
+
default:
|
|
637
|
+
return colors.text.brand;
|
|
638
|
+
}
|
|
639
|
+
}};
|
|
640
|
+
color: ${(props) => {
|
|
641
|
+
switch (props.variant) {
|
|
642
|
+
case "primary":
|
|
643
|
+
return colors.text.brand;
|
|
644
|
+
case "secondary":
|
|
645
|
+
return colors.text.blue;
|
|
646
|
+
case "inverse":
|
|
647
|
+
return colors.text.secondary;
|
|
648
|
+
case "filled":
|
|
649
|
+
return colors.text.secondary;
|
|
650
|
+
default:
|
|
651
|
+
return colors.text.brand;
|
|
652
|
+
}
|
|
653
|
+
}};
|
|
654
|
+
cursor: pointer;
|
|
655
|
+
transition: all 0.2s;
|
|
656
|
+
|
|
657
|
+
&:hover {
|
|
658
|
+
opacity: 0.8;
|
|
659
|
+
}
|
|
660
|
+
|
|
661
|
+
svg {
|
|
662
|
+
width: 1.25rem;
|
|
663
|
+
height: 1.25rem;
|
|
664
|
+
}
|
|
665
|
+
`;
|
|
666
|
+
styled40__default.default.label`
|
|
667
|
+
display: flex;
|
|
668
|
+
align-items: flex-start;
|
|
669
|
+
gap: 0.75rem;
|
|
670
|
+
cursor: pointer;
|
|
671
|
+
font-size: 0.875rem;
|
|
672
|
+
line-height: 1.5;
|
|
673
|
+
`;
|
|
674
|
+
styled40__default.default.input.attrs({ type: "checkbox" })`
|
|
675
|
+
position: absolute;
|
|
676
|
+
opacity: 0;
|
|
677
|
+
cursor: pointer;
|
|
678
|
+
`;
|
|
679
|
+
styled40__default.default.div`
|
|
680
|
+
width: 1.25rem;
|
|
681
|
+
height: 1.25rem;
|
|
682
|
+
border: 2px solid ${(props) => {
|
|
683
|
+
if (props.$checked) {
|
|
684
|
+
switch (props.variant) {
|
|
685
|
+
case "primary":
|
|
686
|
+
return colors.text.brand;
|
|
687
|
+
case "secondary":
|
|
688
|
+
return colors.text.blue;
|
|
689
|
+
case "subtle":
|
|
690
|
+
return colors.text.subtle;
|
|
691
|
+
default:
|
|
692
|
+
return colors.text.brand;
|
|
693
|
+
}
|
|
694
|
+
}
|
|
695
|
+
return colors.text.subtle;
|
|
696
|
+
}};
|
|
697
|
+
border-radius: 4px;
|
|
698
|
+
background-color: ${(props) => {
|
|
699
|
+
if (props.$checked) {
|
|
700
|
+
switch (props.variant) {
|
|
701
|
+
case "primary":
|
|
702
|
+
return colors.text.brand;
|
|
703
|
+
case "secondary":
|
|
704
|
+
return colors.text.blue;
|
|
705
|
+
case "subtle":
|
|
706
|
+
return colors.text.subtle;
|
|
707
|
+
default:
|
|
708
|
+
return colors.text.brand;
|
|
709
|
+
}
|
|
710
|
+
}
|
|
711
|
+
return "transparent";
|
|
712
|
+
}};
|
|
713
|
+
display: flex;
|
|
714
|
+
align-items: center;
|
|
715
|
+
justify-content: center;
|
|
716
|
+
flex-shrink: 0;
|
|
717
|
+
transition: all 0.2s;
|
|
718
|
+
|
|
719
|
+
&::after {
|
|
720
|
+
content: '✓';
|
|
721
|
+
color: ${colors.text.secondary}; // white checkmark
|
|
722
|
+
font-size: 0.875rem;
|
|
723
|
+
font-weight: bold;
|
|
724
|
+
display: ${(props) => props.$checked ? "block" : "none"};
|
|
725
|
+
}
|
|
726
|
+
`;
|
|
727
|
+
styled40__default.default.span`
|
|
728
|
+
color: ${(props) => {
|
|
729
|
+
switch (props.variant) {
|
|
730
|
+
case "primary":
|
|
731
|
+
return colors.text.primary;
|
|
732
|
+
case "secondary":
|
|
733
|
+
return colors.text.blue;
|
|
734
|
+
case "subtle":
|
|
735
|
+
return colors.text.subtle;
|
|
736
|
+
default:
|
|
737
|
+
return colors.text.primary;
|
|
738
|
+
}
|
|
739
|
+
}};
|
|
740
|
+
`;
|
|
741
|
+
styled40__default.default.a`
|
|
742
|
+
color: ${(props) => {
|
|
743
|
+
switch (props.variant) {
|
|
744
|
+
case "primary":
|
|
745
|
+
return colors.text.brand;
|
|
746
|
+
case "secondary":
|
|
747
|
+
return colors.text.blue;
|
|
748
|
+
case "subtle":
|
|
749
|
+
return colors.text.subtle;
|
|
750
|
+
default:
|
|
751
|
+
return colors.text.brand;
|
|
752
|
+
}
|
|
753
|
+
}};
|
|
754
|
+
font-weight: 700;
|
|
755
|
+
text-decoration: underline;
|
|
756
|
+
cursor: pointer;
|
|
757
|
+
|
|
758
|
+
&:hover {
|
|
759
|
+
opacity: 0.8;
|
|
760
|
+
}
|
|
761
|
+
`;
|
|
762
|
+
var variants7 = {
|
|
763
|
+
sm: {
|
|
764
|
+
fontSize: "14px",
|
|
765
|
+
fontWeight: 500
|
|
766
|
+
},
|
|
767
|
+
md: {
|
|
768
|
+
fontSize: "16px",
|
|
769
|
+
fontWeight: 500
|
|
770
|
+
},
|
|
771
|
+
lg: {
|
|
772
|
+
fontSize: "18px",
|
|
773
|
+
fontWeight: 500
|
|
774
|
+
}
|
|
775
|
+
};
|
|
776
|
+
styled40__default.default.h1`
|
|
777
|
+
color: ${(props) => colors.text[props?.color]};
|
|
778
|
+
font-size: ${(props) => variants7[props.variant].fontSize};
|
|
779
|
+
font-weight: ${(props) => variants7[props.variant].fontWeight};
|
|
780
|
+
`;
|
|
781
|
+
var StyledTextarea = styled40__default.default.textarea`
|
|
782
|
+
display: block;
|
|
783
|
+
width: 100%;
|
|
784
|
+
height: 100%;
|
|
785
|
+
outline: none;
|
|
786
|
+
background-color: transparent;
|
|
787
|
+
color: ${colors.text.subtle};
|
|
788
|
+
font-weight: 600;
|
|
789
|
+
resize: vertical;
|
|
790
|
+
`;
|
|
791
|
+
var Textarea = ({
|
|
792
|
+
name,
|
|
793
|
+
onChange,
|
|
794
|
+
rows = 3,
|
|
795
|
+
...rest
|
|
796
|
+
}) => {
|
|
797
|
+
return /* @__PURE__ */ jsxRuntime.jsx(StyledTextarea, { name, onChange, rows, ...rest });
|
|
798
|
+
};
|
|
799
|
+
Textarea.types = InputTypes;
|
|
800
|
+
var bgVariants = ["primary", "secondary", "tertiary", "subtle", "blue", "brand", "light", "transparent"];
|
|
801
|
+
var textVariants = ["brand", "primary", "secondary", "tertiary", "subtle", "light", "error", "blue"];
|
|
802
|
+
var StyledContainer2 = styled40__default.default.button`
|
|
803
|
+
padding: 0 1rem;
|
|
804
|
+
height: 2.5rem;
|
|
805
|
+
display: flex;
|
|
806
|
+
align-items: center;
|
|
807
|
+
flex-shrink:0;
|
|
808
|
+
white-space: nowrap;
|
|
809
|
+
background-color: ${(props) => {
|
|
810
|
+
if (props.bgVariant === "transparent") return "transparent";
|
|
811
|
+
return colors.background[props.bgVariant];
|
|
812
|
+
}};
|
|
813
|
+
transition: all 0.2s;
|
|
814
|
+
border: none;
|
|
815
|
+
cursor: pointer;
|
|
816
|
+
|
|
817
|
+
&:hover {
|
|
818
|
+
opacity: 0.9;
|
|
819
|
+
}
|
|
820
|
+
`;
|
|
821
|
+
var StyledText3 = styled40__default.default.span`
|
|
822
|
+
color: ${(props) => colors.text[props.textVariant]};
|
|
823
|
+
font-size: 0.75rem;
|
|
824
|
+
letter-spacing: 0.05em;
|
|
825
|
+
text-transform: ${(props) => props.$uppercase ? "uppercase" : "none"};
|
|
826
|
+
font-weight: ${(props) => props.$bold ? 700 : 600};
|
|
827
|
+
`;
|
|
828
|
+
var TextButton = ({
|
|
829
|
+
text,
|
|
830
|
+
onClick,
|
|
831
|
+
asChild = false,
|
|
832
|
+
bgVariant = "brand",
|
|
833
|
+
textVariant = "secondary",
|
|
834
|
+
uppercase = true,
|
|
835
|
+
bold = false
|
|
836
|
+
}) => {
|
|
837
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
838
|
+
StyledContainer2,
|
|
839
|
+
{
|
|
840
|
+
as: asChild ? "div" : "button",
|
|
841
|
+
onClick,
|
|
842
|
+
bgVariant,
|
|
843
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(StyledText3, { textVariant, $uppercase: uppercase, $bold: bold, children: text })
|
|
844
|
+
}
|
|
845
|
+
);
|
|
846
|
+
};
|
|
847
|
+
TextButton.bgVariants = bgVariants;
|
|
848
|
+
TextButton.textVariants = textVariants;
|
|
849
|
+
styled40__default.default.div`
|
|
850
|
+
display: inline-flex;
|
|
851
|
+
background-color: ${(props) => {
|
|
852
|
+
switch (props.variant) {
|
|
853
|
+
case "primary":
|
|
854
|
+
return colors.background.secondary;
|
|
855
|
+
case "secondary":
|
|
856
|
+
return colors.background.light;
|
|
857
|
+
case "subtle":
|
|
858
|
+
return colors.background.subtle;
|
|
859
|
+
default:
|
|
860
|
+
return colors.background.secondary;
|
|
861
|
+
}
|
|
862
|
+
}};
|
|
863
|
+
border-radius: 9999px;
|
|
864
|
+
padding: 0.25rem;
|
|
865
|
+
gap: 0.25rem;
|
|
866
|
+
`;
|
|
867
|
+
styled40__default.default.button`
|
|
868
|
+
padding: 0.5rem 1.5rem;
|
|
869
|
+
border-radius: 9999px;
|
|
870
|
+
border: none;
|
|
871
|
+
font-size: 0.875rem;
|
|
872
|
+
font-weight: 600;
|
|
873
|
+
cursor: pointer;
|
|
874
|
+
transition: all 0.2s;
|
|
875
|
+
text-transform: uppercase;
|
|
876
|
+
letter-spacing: 0.05em;
|
|
877
|
+
|
|
878
|
+
background-color: ${(props) => {
|
|
879
|
+
if (!props.$isActive) return "transparent";
|
|
880
|
+
switch (props.variant) {
|
|
881
|
+
case "primary":
|
|
882
|
+
return colors.background.brand;
|
|
883
|
+
case "secondary":
|
|
884
|
+
return colors.background.blue;
|
|
885
|
+
case "subtle":
|
|
886
|
+
return colors.background.subtle;
|
|
887
|
+
default:
|
|
888
|
+
return colors.background.brand;
|
|
889
|
+
}
|
|
890
|
+
}};
|
|
891
|
+
|
|
892
|
+
color: ${(props) => {
|
|
893
|
+
if (props.$isActive) {
|
|
894
|
+
return colors.text.secondary;
|
|
895
|
+
}
|
|
896
|
+
switch (props.variant) {
|
|
897
|
+
case "primary":
|
|
898
|
+
return colors.text.brand;
|
|
899
|
+
case "secondary":
|
|
900
|
+
return colors.text.blue;
|
|
901
|
+
case "subtle":
|
|
902
|
+
return colors.text.subtle;
|
|
903
|
+
default:
|
|
904
|
+
return colors.text.brand;
|
|
905
|
+
}
|
|
906
|
+
}};
|
|
907
|
+
|
|
908
|
+
&:hover {
|
|
909
|
+
opacity: ${(props) => props.$isActive ? 1 : 0.7};
|
|
910
|
+
}
|
|
911
|
+
`;
|
|
912
|
+
var Container6 = styled40__default.default.div`
|
|
913
|
+
display: flex;
|
|
914
|
+
align-items: center;
|
|
915
|
+
justify-content: space-between;
|
|
916
|
+
width: 100%;
|
|
917
|
+
`;
|
|
918
|
+
var HeaderContainer = styled40__default.default.div`
|
|
919
|
+
display: flex;
|
|
920
|
+
align-items: center;
|
|
921
|
+
gap: ${spaces[2]};
|
|
922
|
+
|
|
923
|
+
&:hover {
|
|
924
|
+
cursor: pointer;
|
|
925
|
+
}
|
|
926
|
+
`;
|
|
927
|
+
var AccordionHeader = ({
|
|
928
|
+
title,
|
|
929
|
+
isOpen,
|
|
930
|
+
buttonText,
|
|
931
|
+
onAccordionPress,
|
|
932
|
+
onButtonPress,
|
|
933
|
+
rightElement
|
|
934
|
+
}) => {
|
|
935
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(Container6, { children: [
|
|
936
|
+
/* @__PURE__ */ jsxRuntime.jsxs(HeaderContainer, { onClick: onAccordionPress, children: [
|
|
937
|
+
/* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: isOpen ? /* @__PURE__ */ jsxRuntime.jsx(fa.FaMinus, { color: colors.text.primary, size: sizes.lg }) : /* @__PURE__ */ jsxRuntime.jsx(fa.FaPlus, { color: colors.text.primary, size: sizes.lg }) }),
|
|
938
|
+
/* @__PURE__ */ jsxRuntime.jsx(Header, { variant: "h2", children: title })
|
|
939
|
+
] }),
|
|
940
|
+
rightElement ? rightElement : /* @__PURE__ */ jsxRuntime.jsx(
|
|
941
|
+
Button,
|
|
942
|
+
{
|
|
943
|
+
text: buttonText,
|
|
944
|
+
icon: /* @__PURE__ */ jsxRuntime.jsx(fa6.FaPlus, { fontSize: "10px" }),
|
|
945
|
+
onClick: onButtonPress
|
|
946
|
+
}
|
|
947
|
+
)
|
|
948
|
+
] });
|
|
949
|
+
};
|
|
950
|
+
var Container7 = styled40__default.default.div`
|
|
951
|
+
border-radius: ${radii.lg};
|
|
952
|
+
background-color: ${colors.background.secondary};
|
|
953
|
+
padding: ${spaces[4]};
|
|
954
|
+
`;
|
|
955
|
+
var Accordion = ({
|
|
956
|
+
buttonText,
|
|
957
|
+
onButtonPress,
|
|
958
|
+
title,
|
|
959
|
+
children,
|
|
960
|
+
rightElement
|
|
961
|
+
}) => {
|
|
962
|
+
const [isOpen, setIsOpen] = react.useState(false);
|
|
963
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(Container7, { children: [
|
|
964
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
965
|
+
AccordionHeader,
|
|
966
|
+
{
|
|
967
|
+
isOpen,
|
|
968
|
+
buttonText,
|
|
969
|
+
onButtonPress,
|
|
970
|
+
onAccordionPress: () => setIsOpen((previousState) => !previousState),
|
|
971
|
+
title,
|
|
972
|
+
rightElement
|
|
973
|
+
}
|
|
974
|
+
),
|
|
975
|
+
isOpen && /* @__PURE__ */ jsxRuntime.jsx(AccordionContent, { children })
|
|
976
|
+
] });
|
|
977
|
+
};
|
|
978
|
+
var variants9 = ["primary", "inverse", "subtle"];
|
|
979
|
+
var AddressContainer = styled40__default.default.div`
|
|
980
|
+
display: flex;
|
|
981
|
+
flex-direction: column;
|
|
982
|
+
background-color: transparent;
|
|
983
|
+
padding: 2rem;
|
|
984
|
+
|
|
985
|
+
/* Desktop: normal spacing */
|
|
986
|
+
@media (min-width: 768px) {
|
|
987
|
+
gap: 1rem;
|
|
988
|
+
}
|
|
989
|
+
|
|
990
|
+
/* Mobile: no gap, handled by collapse */
|
|
991
|
+
@media (max-width: 767px) {
|
|
992
|
+
padding: 1rem;
|
|
993
|
+
gap: 0;
|
|
994
|
+
}
|
|
995
|
+
`;
|
|
996
|
+
var HeaderWrapper = styled40__default.default.div`
|
|
997
|
+
display: flex;
|
|
998
|
+
justify-content: space-between;
|
|
999
|
+
align-items: center;
|
|
1000
|
+
|
|
1001
|
+
/* Desktop: not clickable */
|
|
1002
|
+
@media (min-width: 768px) {
|
|
1003
|
+
cursor: default;
|
|
1004
|
+
}
|
|
1005
|
+
|
|
1006
|
+
/* Mobile: clickable */
|
|
1007
|
+
@media (max-width: 767px) {
|
|
1008
|
+
cursor: ${(props) => props.$isClickable ? "pointer" : "default"};
|
|
1009
|
+
padding: 0.5rem 0;
|
|
1010
|
+
user-select: none;
|
|
1011
|
+
}
|
|
1012
|
+
`;
|
|
1013
|
+
var ToggleIcon = styled40__default.default.div`
|
|
1014
|
+
display: none;
|
|
1015
|
+
|
|
1016
|
+
/* Only show on mobile */
|
|
1017
|
+
@media (max-width: 767px) {
|
|
1018
|
+
display: flex;
|
|
1019
|
+
align-items: center;
|
|
1020
|
+
font-size: 1.5rem;
|
|
1021
|
+
|
|
1022
|
+
color: ${(props) => {
|
|
1023
|
+
switch (props.variant) {
|
|
1024
|
+
case "primary":
|
|
1025
|
+
return colors.text.primary;
|
|
1026
|
+
case "inverse":
|
|
1027
|
+
return colors.text.secondary;
|
|
1028
|
+
case "subtle":
|
|
1029
|
+
return colors.text.subtle;
|
|
1030
|
+
default:
|
|
1031
|
+
return colors.text.primary;
|
|
1032
|
+
}
|
|
1033
|
+
}};
|
|
1034
|
+
}
|
|
1035
|
+
`;
|
|
1036
|
+
var CollapseContent = styled40__default.default.div`
|
|
1037
|
+
display: flex;
|
|
1038
|
+
flex-direction: column;
|
|
1039
|
+
gap: 1rem;
|
|
1040
|
+
|
|
1041
|
+
/* Desktop: always visible */
|
|
1042
|
+
@media (min-width: 768px) {
|
|
1043
|
+
display: flex;
|
|
1044
|
+
}
|
|
1045
|
+
|
|
1046
|
+
/* Mobile: collapsible */
|
|
1047
|
+
@media (max-width: 767px) {
|
|
1048
|
+
max-height: ${(props) => props.$isOpen ? "500px" : "0"};
|
|
1049
|
+
opacity: ${(props) => props.$isOpen ? "1" : "0"};
|
|
1050
|
+
overflow: hidden;
|
|
1051
|
+
transition: max-height 0.3s ease, opacity 0.3s ease;
|
|
1052
|
+
padding-top: ${(props) => props.$isOpen ? "1rem" : "0"};
|
|
1053
|
+
}
|
|
1054
|
+
`;
|
|
1055
|
+
var InfoSection = styled40__default.default.div`
|
|
1056
|
+
display: flex;
|
|
1057
|
+
flex-direction: column;
|
|
1058
|
+
gap: 0.5rem;
|
|
1059
|
+
`;
|
|
1060
|
+
var InfoText = styled40__default.default.p`
|
|
1061
|
+
margin: 0;
|
|
1062
|
+
font-size: 0.875rem;
|
|
1063
|
+
line-height: 1.6;
|
|
1064
|
+
color: ${(props) => {
|
|
1065
|
+
switch (props.variant) {
|
|
1066
|
+
case "primary":
|
|
1067
|
+
return colors.text.primary;
|
|
1068
|
+
case "inverse":
|
|
1069
|
+
return colors.text.secondary;
|
|
1070
|
+
case "subtle":
|
|
1071
|
+
return colors.text.subtle;
|
|
1072
|
+
default:
|
|
1073
|
+
return colors.text.primary;
|
|
1074
|
+
}
|
|
1075
|
+
}};
|
|
1076
|
+
font-weight: ${(props) => props.$bold ? 600 : 400};
|
|
1077
|
+
`;
|
|
1078
|
+
var ButtonWrapper = styled40__default.default.div`
|
|
1079
|
+
margin-top: 0.5rem;
|
|
1080
|
+
`;
|
|
1081
|
+
var Address = ({
|
|
1082
|
+
title,
|
|
1083
|
+
phone,
|
|
1084
|
+
email,
|
|
1085
|
+
addressLines,
|
|
1086
|
+
directionsText = "GET DIRECTIONS",
|
|
1087
|
+
onDirectionsClick,
|
|
1088
|
+
variant = "primary"
|
|
1089
|
+
}) => {
|
|
1090
|
+
const [isOpen, setIsOpen] = react.useState(false);
|
|
1091
|
+
const handleDirectionsClick = () => {
|
|
1092
|
+
if (onDirectionsClick) {
|
|
1093
|
+
onDirectionsClick();
|
|
1094
|
+
} else {
|
|
1095
|
+
const fullAddress = addressLines.join(", ");
|
|
1096
|
+
const encodedAddress = encodeURIComponent(fullAddress);
|
|
1097
|
+
const mapsUrl = `https://www.google.com/maps/search/?api=1&query=${encodedAddress}`;
|
|
1098
|
+
window.open(mapsUrl, "_blank");
|
|
1099
|
+
}
|
|
1100
|
+
};
|
|
1101
|
+
const getHeaderVariant = () => {
|
|
1102
|
+
switch (variant) {
|
|
1103
|
+
case "primary":
|
|
1104
|
+
return "primary";
|
|
1105
|
+
case "inverse":
|
|
1106
|
+
return "secondary";
|
|
1107
|
+
case "subtle":
|
|
1108
|
+
return "subtle";
|
|
1109
|
+
default:
|
|
1110
|
+
return "primary";
|
|
1111
|
+
}
|
|
1112
|
+
};
|
|
1113
|
+
const getButtonBgVariant = () => {
|
|
1114
|
+
return "transparent";
|
|
1115
|
+
};
|
|
1116
|
+
const getButtonTextVariant = () => {
|
|
1117
|
+
switch (variant) {
|
|
1118
|
+
case "primary":
|
|
1119
|
+
return "primary";
|
|
1120
|
+
case "inverse":
|
|
1121
|
+
return "secondary";
|
|
1122
|
+
case "subtle":
|
|
1123
|
+
return "subtle";
|
|
1124
|
+
default:
|
|
1125
|
+
return "primary";
|
|
1126
|
+
}
|
|
1127
|
+
};
|
|
1128
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(AddressContainer, { children: [
|
|
1129
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
1130
|
+
HeaderWrapper,
|
|
1131
|
+
{
|
|
1132
|
+
$isClickable: true,
|
|
1133
|
+
onClick: () => setIsOpen(!isOpen),
|
|
1134
|
+
children: [
|
|
1135
|
+
/* @__PURE__ */ jsxRuntime.jsx(Header, { variant: "h1", color: getHeaderVariant(), children: title }),
|
|
1136
|
+
/* @__PURE__ */ jsxRuntime.jsx(ToggleIcon, { variant, children: isOpen ? /* @__PURE__ */ jsxRuntime.jsx(hi2.HiMinus, {}) : /* @__PURE__ */ jsxRuntime.jsx(hi2.HiPlus, {}) })
|
|
1137
|
+
]
|
|
1138
|
+
}
|
|
1139
|
+
),
|
|
1140
|
+
/* @__PURE__ */ jsxRuntime.jsxs(CollapseContent, { $isOpen: isOpen, children: [
|
|
1141
|
+
/* @__PURE__ */ jsxRuntime.jsxs(InfoSection, { children: [
|
|
1142
|
+
phone && /* @__PURE__ */ jsxRuntime.jsx(InfoText, { variant, children: phone }),
|
|
1143
|
+
email && /* @__PURE__ */ jsxRuntime.jsx(InfoText, { variant, $bold: true, children: email.toUpperCase() }),
|
|
1144
|
+
addressLines.map((line, index) => /* @__PURE__ */ jsxRuntime.jsx(InfoText, { variant, children: line }, index))
|
|
1145
|
+
] }),
|
|
1146
|
+
/* @__PURE__ */ jsxRuntime.jsx(ButtonWrapper, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1147
|
+
TextButton,
|
|
1148
|
+
{
|
|
1149
|
+
text: directionsText,
|
|
1150
|
+
onClick: handleDirectionsClick,
|
|
1151
|
+
bgVariant: getButtonBgVariant(),
|
|
1152
|
+
textVariant: getButtonTextVariant(),
|
|
1153
|
+
uppercase: true
|
|
1154
|
+
}
|
|
1155
|
+
) })
|
|
1156
|
+
] })
|
|
1157
|
+
] });
|
|
1158
|
+
};
|
|
1159
|
+
Address.variants = variants9;
|
|
1160
|
+
var CheckboxWrapper = styled40__default.default.label`
|
|
1161
|
+
display: flex;
|
|
1162
|
+
align-items: center;
|
|
1163
|
+
gap: ${spaces[2]};
|
|
1164
|
+
cursor: pointer;
|
|
1165
|
+
font-size: 16px;
|
|
1166
|
+
color: ${colors.text.subtle};
|
|
1167
|
+
`;
|
|
1168
|
+
var HiddenCheckbox2 = styled40__default.default.input.attrs({ type: "checkbox" })`
|
|
1169
|
+
display: none;
|
|
1170
|
+
`;
|
|
1171
|
+
var StyledCheckbox2 = styled40__default.default.span`
|
|
1172
|
+
width: ${sizes.lg};
|
|
1173
|
+
height: ${sizes.lg};
|
|
1174
|
+
border: 1.5px solid ${colors.background.tertiary};
|
|
1175
|
+
border-radius: ${radii.md};
|
|
1176
|
+
background-color: ${({ checked }) => checked ? colors.background.tertiary : "transparent"};
|
|
1177
|
+
transition: all 0.2s ease-in-out;
|
|
1178
|
+
`;
|
|
1179
|
+
var CheckboxItem = ({
|
|
1180
|
+
label,
|
|
1181
|
+
onClick,
|
|
1182
|
+
checked
|
|
1183
|
+
}) => {
|
|
1184
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(CheckboxWrapper, { onClick, children: [
|
|
1185
|
+
/* @__PURE__ */ jsxRuntime.jsx(HiddenCheckbox2, { checked, readOnly: true }),
|
|
1186
|
+
/* @__PURE__ */ jsxRuntime.jsx(StyledCheckbox2, { checked }),
|
|
1187
|
+
label
|
|
1188
|
+
] });
|
|
1189
|
+
};
|
|
1190
|
+
var Container8 = styled40__default.default.div`
|
|
1191
|
+
display: flex;
|
|
1192
|
+
flex-direction: column;
|
|
1193
|
+
`;
|
|
1194
|
+
var OptionsContainer = styled40__default.default.div`
|
|
1195
|
+
display: flex;
|
|
1196
|
+
gap: ${spaces[4]};
|
|
1197
|
+
`;
|
|
1198
|
+
var Checkbox = ({
|
|
1199
|
+
error,
|
|
1200
|
+
label,
|
|
1201
|
+
onChange,
|
|
1202
|
+
options,
|
|
1203
|
+
value
|
|
1204
|
+
}) => {
|
|
1205
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(Container8, { children: [
|
|
1206
|
+
typeof label === "string" && label?.length ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
1207
|
+
Label,
|
|
1208
|
+
{
|
|
1209
|
+
value: label,
|
|
1210
|
+
color: typeof error === "string" && error?.length ? "error" : void 0,
|
|
1211
|
+
fontWeight: "600"
|
|
1212
|
+
}
|
|
1213
|
+
) : null,
|
|
1214
|
+
/* @__PURE__ */ jsxRuntime.jsx(OptionsContainer, { children: options.map((option) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1215
|
+
CheckboxItem,
|
|
1216
|
+
{
|
|
1217
|
+
checked: value === option.value,
|
|
1218
|
+
label: option.label,
|
|
1219
|
+
onClick: () => onChange(option.value),
|
|
1220
|
+
value: option.value
|
|
1221
|
+
}
|
|
1222
|
+
)) })
|
|
1223
|
+
] });
|
|
1224
|
+
};
|
|
1225
|
+
var Container9 = styled40__default.default.div`
|
|
1226
|
+
display: flex;
|
|
1227
|
+
flex-direction: column;
|
|
1228
|
+
gap: 1rem;
|
|
1229
|
+
background-color: #ffffff;
|
|
1230
|
+
width: 284px;
|
|
1231
|
+
height: 482px;
|
|
1232
|
+
padding: 1.5rem;
|
|
1233
|
+
border-radius: 8px;
|
|
1234
|
+
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
|
|
1235
|
+
flex-shrink: 0;
|
|
1236
|
+
|
|
1237
|
+
@media (max-width: 767px) {
|
|
1238
|
+
width: 70vw;
|
|
1239
|
+
}
|
|
1240
|
+
`;
|
|
1241
|
+
var ThumbnailWrapper2 = styled40__default.default.div`
|
|
1242
|
+
width: 180px;
|
|
1243
|
+
height: 180px;
|
|
1244
|
+
border-radius: 50%;
|
|
1245
|
+
background-color: ${(props) => colors.background[props.thumbnailBgColor]};
|
|
1246
|
+
display: flex;
|
|
1247
|
+
align-items: center;
|
|
1248
|
+
justify-content: center;
|
|
1249
|
+
flex-shrink: 0;
|
|
1250
|
+
align-self: center;
|
|
1251
|
+
`;
|
|
1252
|
+
var ButtonWrapper2 = styled40__default.default.div`
|
|
1253
|
+
display: flex;
|
|
1254
|
+
justify-content: flex-start;
|
|
1255
|
+
margin-top: auto;
|
|
1256
|
+
`;
|
|
1257
|
+
var ContentCard = ({
|
|
1258
|
+
thumbnail,
|
|
1259
|
+
title,
|
|
1260
|
+
description,
|
|
1261
|
+
onArrowClick,
|
|
1262
|
+
headerVariant = "h2",
|
|
1263
|
+
titleColor = "brand",
|
|
1264
|
+
descriptionVariant = "subtle",
|
|
1265
|
+
arrowVariant = "teal",
|
|
1266
|
+
thumbnailBgColor = "brand"
|
|
1267
|
+
}) => {
|
|
1268
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(Container9, { children: [
|
|
1269
|
+
/* @__PURE__ */ jsxRuntime.jsx(ThumbnailWrapper2, { thumbnailBgColor, children: thumbnail }),
|
|
1270
|
+
/* @__PURE__ */ jsxRuntime.jsx(Header, { variant: headerVariant, color: titleColor, children: title }),
|
|
1271
|
+
/* @__PURE__ */ jsxRuntime.jsx(Description, { variant: descriptionVariant, children: description }),
|
|
1272
|
+
/* @__PURE__ */ jsxRuntime.jsx(ButtonWrapper2, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1273
|
+
ArrowButton,
|
|
1274
|
+
{
|
|
1275
|
+
onClick: onArrowClick,
|
|
1276
|
+
variant: arrowVariant
|
|
1277
|
+
}
|
|
1278
|
+
) })
|
|
1279
|
+
] });
|
|
1280
|
+
};
|
|
1281
|
+
var variants10 = ["primary", "secondary", "transparent"];
|
|
1282
|
+
var Container10 = styled40__default.default.div`
|
|
1283
|
+
display: flex;
|
|
1284
|
+
flex-direction: column;
|
|
1285
|
+
gap: 1.5rem;
|
|
1286
|
+
padding: 3rem 2rem;
|
|
1287
|
+
max-width: 500px;
|
|
1288
|
+
|
|
1289
|
+
/* Mobile adjustments */
|
|
1290
|
+
@media (max-width: 767px) {
|
|
1291
|
+
padding: 2rem 1rem;
|
|
1292
|
+
max-width: 100%;
|
|
1293
|
+
}
|
|
1294
|
+
`;
|
|
1295
|
+
var Header2 = styled40__default.default.h1`
|
|
1296
|
+
margin: 0;
|
|
1297
|
+
font-size: 2.5rem;
|
|
1298
|
+
font-weight: 700;
|
|
1299
|
+
line-height: 1.2;
|
|
1300
|
+
color: ${(props) => colors.text[props.textColor]};
|
|
1301
|
+
|
|
1302
|
+
/* Responsive font size */
|
|
1303
|
+
@media (max-width: 767px) {
|
|
1304
|
+
font-size: 2rem;
|
|
1305
|
+
}
|
|
1306
|
+
|
|
1307
|
+
@media (max-width: 480px) {
|
|
1308
|
+
font-size: 1.75rem;
|
|
1309
|
+
}
|
|
1310
|
+
`;
|
|
1311
|
+
var Description3 = styled40__default.default.p`
|
|
1312
|
+
margin: 0;
|
|
1313
|
+
font-size: 1.125rem;
|
|
1314
|
+
line-height: 1.6;
|
|
1315
|
+
color: ${(props) => colors.text[props.textColor]};
|
|
1316
|
+
|
|
1317
|
+
/* Responsive font size */
|
|
1318
|
+
@media (max-width: 767px) {
|
|
1319
|
+
font-size: 1rem;
|
|
1320
|
+
}
|
|
1321
|
+
`;
|
|
1322
|
+
var ButtonGroup = styled40__default.default.div`
|
|
1323
|
+
display: flex;
|
|
1324
|
+
gap: 1rem;
|
|
1325
|
+
align-items: center;
|
|
1326
|
+
|
|
1327
|
+
/* Stack vertically on mobile */
|
|
1328
|
+
@media (max-width: 767px) {
|
|
1329
|
+
flex-direction: column;
|
|
1330
|
+
align-items: stretch;
|
|
1331
|
+
width: 100%;
|
|
1332
|
+
}
|
|
1333
|
+
`;
|
|
1334
|
+
var CTAContainer = ({
|
|
1335
|
+
header,
|
|
1336
|
+
description,
|
|
1337
|
+
primaryButtonText,
|
|
1338
|
+
secondaryButtonText,
|
|
1339
|
+
onPrimaryClick,
|
|
1340
|
+
onSecondaryClick,
|
|
1341
|
+
variant = "transparent",
|
|
1342
|
+
headerTextColor = "secondary",
|
|
1343
|
+
descriptionTextColor = "secondary",
|
|
1344
|
+
primaryArrowVariant = "teal",
|
|
1345
|
+
primaryTextBgVariant = "brand",
|
|
1346
|
+
primaryTextVariant = "secondary",
|
|
1347
|
+
secondaryBgVariant = "transparent",
|
|
1348
|
+
secondaryTextVariant = "secondary"
|
|
1349
|
+
}) => {
|
|
1350
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(Container10, { variant, children: [
|
|
1351
|
+
/* @__PURE__ */ jsxRuntime.jsx(Header2, { textColor: headerTextColor, children: header }),
|
|
1352
|
+
/* @__PURE__ */ jsxRuntime.jsx(Description3, { textColor: descriptionTextColor, children: description }),
|
|
1353
|
+
/* @__PURE__ */ jsxRuntime.jsxs(ButtonGroup, { children: [
|
|
1354
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1355
|
+
ExtendedButton,
|
|
1356
|
+
{
|
|
1357
|
+
text: primaryButtonText,
|
|
1358
|
+
onClick: onPrimaryClick,
|
|
1359
|
+
arrowVariant: primaryArrowVariant,
|
|
1360
|
+
textBgVariant: primaryTextBgVariant,
|
|
1361
|
+
textVariant: primaryTextVariant
|
|
1362
|
+
}
|
|
1363
|
+
),
|
|
1364
|
+
secondaryButtonText && /* @__PURE__ */ jsxRuntime.jsx(
|
|
1365
|
+
TextButton,
|
|
1366
|
+
{
|
|
1367
|
+
text: secondaryButtonText,
|
|
1368
|
+
onClick: onSecondaryClick,
|
|
1369
|
+
bgVariant: secondaryBgVariant,
|
|
1370
|
+
textVariant: secondaryTextVariant
|
|
1371
|
+
}
|
|
1372
|
+
)
|
|
1373
|
+
] })
|
|
1374
|
+
] });
|
|
1375
|
+
};
|
|
1376
|
+
CTAContainer.variants = variants10;
|
|
1377
|
+
var Container11 = styled40__default.default.div`
|
|
1378
|
+
width: 100%;
|
|
1379
|
+
`;
|
|
1380
|
+
var InnerContainer2 = styled40__default.default.div`
|
|
1381
|
+
position: relative;
|
|
1382
|
+
width: 100%;
|
|
1383
|
+
min-height: 58px;
|
|
1384
|
+
display: flex;
|
|
1385
|
+
align-items: center;
|
|
1386
|
+
|
|
1387
|
+
border-style: solid;
|
|
1388
|
+
border-width: ${(props) => props?.variant === "outline" ? sizes[0] : "0px"};
|
|
1389
|
+
border-color: ${(props) => props?.error ? colors.border.error : colors.border.active};
|
|
1390
|
+
border-radius: ${radii.lg};
|
|
1391
|
+
|
|
1392
|
+
padding: ${spaces[3]} ${spaces[3]} ${spaces[2]};
|
|
1393
|
+
|
|
1394
|
+
&:hover {
|
|
1395
|
+
border-color: ${colors.border.hover};
|
|
1396
|
+
cursor: text;
|
|
1397
|
+
}
|
|
1398
|
+
|
|
1399
|
+
&:focus-within {
|
|
1400
|
+
border-color: ${colors.border.focus};
|
|
1401
|
+
}
|
|
1402
|
+
`;
|
|
1403
|
+
var InputContainer = ({
|
|
1404
|
+
error,
|
|
1405
|
+
children,
|
|
1406
|
+
variant = "outline"
|
|
1407
|
+
}) => {
|
|
1408
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(Container11, { children: [
|
|
1409
|
+
/* @__PURE__ */ jsxRuntime.jsx(InnerContainer2, { error, variant, children }),
|
|
1410
|
+
typeof error === "string" && /* @__PURE__ */ jsxRuntime.jsx(Label, { value: error, color: "error" })
|
|
1411
|
+
] });
|
|
1412
|
+
};
|
|
1413
|
+
var Select = styled40__default.default.select`
|
|
1414
|
+
width: 100%;
|
|
1415
|
+
color: ${colors.text.subtle};
|
|
1416
|
+
background: transparent;
|
|
1417
|
+
font-weight: 600;
|
|
1418
|
+
border: none;
|
|
1419
|
+
outline: none;
|
|
1420
|
+
padding: 0;
|
|
1421
|
+
margin: 0;
|
|
1422
|
+
|
|
1423
|
+
&:focus,
|
|
1424
|
+
&:active,
|
|
1425
|
+
&:hover {
|
|
1426
|
+
border: none;
|
|
1427
|
+
outline: none;
|
|
1428
|
+
box-shadow: none;
|
|
1429
|
+
}
|
|
1430
|
+
|
|
1431
|
+
&:invalid {
|
|
1432
|
+
color: ${colors.text.subtle};
|
|
1433
|
+
}
|
|
1434
|
+
`;
|
|
1435
|
+
var OptionItem = styled40__default.default.option`
|
|
1436
|
+
color: ${(props) => props.disabled ? colors.text.light : colors.text.subtle};
|
|
1437
|
+
`;
|
|
1438
|
+
var Dropdown = ({
|
|
1439
|
+
error,
|
|
1440
|
+
onChange,
|
|
1441
|
+
options,
|
|
1442
|
+
value,
|
|
1443
|
+
label,
|
|
1444
|
+
name,
|
|
1445
|
+
placeholder = "Select an option",
|
|
1446
|
+
disabled
|
|
1447
|
+
}) => {
|
|
1448
|
+
const isInvalid = react.useMemo(
|
|
1449
|
+
() => error ? typeof error === "string" && error?.length > 0 : false,
|
|
1450
|
+
[error]
|
|
1451
|
+
);
|
|
1452
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(InputContainer, { error, children: [
|
|
1453
|
+
typeof label === "string" && /* @__PURE__ */ jsxRuntime.jsx(
|
|
1454
|
+
FloatingLabel,
|
|
1455
|
+
{
|
|
1456
|
+
value: label,
|
|
1457
|
+
color: isInvalid ? "error" : "subtle",
|
|
1458
|
+
fontWeight: "600"
|
|
1459
|
+
}
|
|
1460
|
+
),
|
|
1461
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
1462
|
+
Select,
|
|
1463
|
+
{
|
|
1464
|
+
name,
|
|
1465
|
+
value: value ?? "",
|
|
1466
|
+
onChange: (e) => onChange(e.target.value),
|
|
1467
|
+
isInvalid,
|
|
1468
|
+
disabled,
|
|
1469
|
+
children: [
|
|
1470
|
+
/* @__PURE__ */ jsxRuntime.jsx(OptionItem, { value: "", disabled: true, hidden: true, children: placeholder }),
|
|
1471
|
+
options.map((option) => /* @__PURE__ */ jsxRuntime.jsx(OptionItem, { value: option.value, children: option.label }, option.value))
|
|
1472
|
+
]
|
|
1473
|
+
}
|
|
1474
|
+
)
|
|
1475
|
+
] });
|
|
1476
|
+
};
|
|
1477
|
+
var AccordionContainer = styled40__default.default.div`
|
|
1478
|
+
border-bottom: 1px solid ${colors.text.light};
|
|
1479
|
+
padding: 1.5rem 0;
|
|
1480
|
+
`;
|
|
1481
|
+
var AccordionHeader2 = styled40__default.default.button`
|
|
1482
|
+
width: 100%;
|
|
1483
|
+
display: flex;
|
|
1484
|
+
align-items: center;
|
|
1485
|
+
gap: 1rem;
|
|
1486
|
+
background: none;
|
|
1487
|
+
border: none;
|
|
1488
|
+
cursor: pointer;
|
|
1489
|
+
text-align: left;
|
|
1490
|
+
padding: 0;
|
|
1491
|
+
`;
|
|
1492
|
+
var NumberBadge = styled40__default.default.span`
|
|
1493
|
+
font-size: 1rem;
|
|
1494
|
+
font-weight: 600;
|
|
1495
|
+
color: ${(props) => colors.text[props.numberColor]};
|
|
1496
|
+
flex-shrink: 0;
|
|
1497
|
+
`;
|
|
1498
|
+
var HeaderWrapper2 = styled40__default.default.div`
|
|
1499
|
+
flex-grow: 1;
|
|
1500
|
+
`;
|
|
1501
|
+
var IconWrapper = styled40__default.default.div`
|
|
1502
|
+
color: ${(props) => colors.text[props.iconColor]};
|
|
1503
|
+
flex-shrink: 0;
|
|
1504
|
+
display: flex;
|
|
1505
|
+
align-items: center;
|
|
1506
|
+
justify-content: center;
|
|
1507
|
+
`;
|
|
1508
|
+
var AccordionContent2 = styled40__default.default.div`
|
|
1509
|
+
max-height: ${(props) => props.$isOpen ? "1000px" : "0"};
|
|
1510
|
+
overflow: hidden;
|
|
1511
|
+
transition: max-height 0.3s ease-in-out;
|
|
1512
|
+
padding-left: 2.5rem;
|
|
1513
|
+
margin-top: ${(props) => props.$isOpen ? "1rem" : "0"};
|
|
1514
|
+
`;
|
|
1515
|
+
var FAQAccordion = ({
|
|
1516
|
+
number,
|
|
1517
|
+
title,
|
|
1518
|
+
content,
|
|
1519
|
+
defaultOpen = false,
|
|
1520
|
+
headerVariant = "h3",
|
|
1521
|
+
numberColor = "brand",
|
|
1522
|
+
titleColor = "brand",
|
|
1523
|
+
iconColor = "brand",
|
|
1524
|
+
contentVariant = "primary"
|
|
1525
|
+
}) => {
|
|
1526
|
+
const [isOpen, setIsOpen] = react.useState(defaultOpen);
|
|
1527
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(AccordionContainer, { children: [
|
|
1528
|
+
/* @__PURE__ */ jsxRuntime.jsxs(AccordionHeader2, { onClick: () => setIsOpen(!isOpen), children: [
|
|
1529
|
+
/* @__PURE__ */ jsxRuntime.jsx(NumberBadge, { numberColor, children: number }),
|
|
1530
|
+
/* @__PURE__ */ jsxRuntime.jsx(HeaderWrapper2, { children: /* @__PURE__ */ jsxRuntime.jsx(Header, { variant: headerVariant, color: titleColor, children: title }) }),
|
|
1531
|
+
/* @__PURE__ */ jsxRuntime.jsx(IconWrapper, { iconColor, children: isOpen ? /* @__PURE__ */ jsxRuntime.jsx(hi2.HiMinus, { size: 24 }) : /* @__PURE__ */ jsxRuntime.jsx(hi2.HiPlus, { size: 24 }) })
|
|
1532
|
+
] }),
|
|
1533
|
+
/* @__PURE__ */ jsxRuntime.jsx(AccordionContent2, { $isOpen: isOpen, children: /* @__PURE__ */ jsxRuntime.jsx(Description, { variant: contentVariant, children: content }) })
|
|
1534
|
+
] });
|
|
1535
|
+
};
|
|
1536
|
+
var Container12 = styled40__default.default.div`
|
|
1537
|
+
display: flex;
|
|
1538
|
+
flex-direction: column;
|
|
1539
|
+
`;
|
|
1540
|
+
var FeatureWrapper = styled40__default.default.div`
|
|
1541
|
+
padding: 1rem 0;
|
|
1542
|
+
border-bottom: 1px solid #e5e7eb;
|
|
1543
|
+
|
|
1544
|
+
&:last-child {
|
|
1545
|
+
border-bottom: none;
|
|
1546
|
+
}
|
|
1547
|
+
`;
|
|
1548
|
+
var FeatureContainer = ({
|
|
1549
|
+
items,
|
|
1550
|
+
thumbnailBgColor = "brand",
|
|
1551
|
+
titleColor = "primary",
|
|
1552
|
+
descriptionVariant = "subtle"
|
|
1553
|
+
}) => {
|
|
1554
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Container12, { children: items.map((item, index) => /* @__PURE__ */ jsxRuntime.jsx(FeatureWrapper, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1555
|
+
FeatureItem,
|
|
1556
|
+
{
|
|
1557
|
+
thumbnail: item.thumbnail,
|
|
1558
|
+
title: item.title,
|
|
1559
|
+
description: item.description,
|
|
1560
|
+
thumbnailSize: item.thumbnailSize,
|
|
1561
|
+
thumbnailBgColor,
|
|
1562
|
+
titleColor,
|
|
1563
|
+
descriptionVariant
|
|
1564
|
+
}
|
|
1565
|
+
) }, index)) });
|
|
1566
|
+
};
|
|
1567
|
+
var FileButton = ({
|
|
1568
|
+
onFileSelect,
|
|
1569
|
+
accept = [".pdf"],
|
|
1570
|
+
multiple = false,
|
|
1571
|
+
...rest
|
|
1572
|
+
}) => {
|
|
1573
|
+
const fileInputRef = react.useRef(null);
|
|
1574
|
+
const handleClick = () => {
|
|
1575
|
+
if (fileInputRef.current) {
|
|
1576
|
+
fileInputRef.current.click();
|
|
1577
|
+
}
|
|
1578
|
+
};
|
|
1579
|
+
const handleFileChange = (event) => {
|
|
1580
|
+
const files = event.target.files;
|
|
1581
|
+
if (files && files.length > 0 && onFileSelect) {
|
|
1582
|
+
Array.from(files).forEach((file) => onFileSelect(file));
|
|
1583
|
+
}
|
|
1584
|
+
};
|
|
1585
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
1586
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1587
|
+
Button,
|
|
1588
|
+
{
|
|
1589
|
+
...rest,
|
|
1590
|
+
icon: /* @__PURE__ */ jsxRuntime.jsx(fa6.FaPlus, { fontSize: "10px" }),
|
|
1591
|
+
onClick: handleClick
|
|
1592
|
+
}
|
|
1593
|
+
),
|
|
1594
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1595
|
+
"input",
|
|
1596
|
+
{
|
|
1597
|
+
type: "file",
|
|
1598
|
+
ref: fileInputRef,
|
|
1599
|
+
style: { display: "none" },
|
|
1600
|
+
onChange: handleFileChange,
|
|
1601
|
+
accept: accept?.map((item) => item).join(","),
|
|
1602
|
+
multiple
|
|
1603
|
+
}
|
|
1604
|
+
)
|
|
1605
|
+
] });
|
|
1606
|
+
};
|
|
1607
|
+
var Input2 = ({ label, error, ...rest }) => {
|
|
1608
|
+
const isInvalid = react.useMemo(
|
|
1609
|
+
() => typeof error === "string" && error.length > 0,
|
|
1610
|
+
[error]
|
|
1611
|
+
);
|
|
1612
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(InputContainer, { error, children: [
|
|
1613
|
+
typeof label === "string" && /* @__PURE__ */ jsxRuntime.jsx(
|
|
1614
|
+
FloatingLabel,
|
|
1615
|
+
{
|
|
1616
|
+
color: isInvalid ? "error" : "subtle",
|
|
1617
|
+
value: label,
|
|
1618
|
+
fontWeight: "600"
|
|
1619
|
+
}
|
|
1620
|
+
),
|
|
1621
|
+
/* @__PURE__ */ jsxRuntime.jsx(Input, { ...rest })
|
|
1622
|
+
] });
|
|
1623
|
+
};
|
|
1624
|
+
Input2.types = Input.types;
|
|
1625
|
+
var fadeIn = styled40.keyframes`
|
|
1626
|
+
from { opacity: 0 }
|
|
1627
|
+
to { opacity: 1 }
|
|
1628
|
+
`;
|
|
1629
|
+
styled40.keyframes`
|
|
1630
|
+
from { transform: translateY(8px) scale(.98); opacity: 0 }
|
|
1631
|
+
to { transform: translateY(0) scale(1); opacity: 1 }
|
|
1632
|
+
`;
|
|
1633
|
+
var Overlay = styled40__default.default.div`
|
|
1634
|
+
height: 100vh;
|
|
1635
|
+
width: 100vw;
|
|
1636
|
+
background-color: rgba(0, 0, 0, 0.4);
|
|
1637
|
+
position: fixed;
|
|
1638
|
+
inset: 0;
|
|
1639
|
+
z-index: 1000;
|
|
1640
|
+
display: flex;
|
|
1641
|
+
align-items: ${(props) => props.contentPosition === "center" ? "center" : props.contentPosition === "bottom" ? "flex-end" : "flex-start"};
|
|
1642
|
+
justify-content: center;
|
|
1643
|
+
animation: ${fadeIn} 160ms ease-out;
|
|
1644
|
+
`;
|
|
1645
|
+
var ContentContainer = styled40__default.default.div`
|
|
1646
|
+
position: relative;
|
|
1647
|
+
width: min(${breakpoints.sm}, 92vw);
|
|
1648
|
+
max-height: 86vh;
|
|
1649
|
+
overflow: auto;
|
|
1650
|
+
border-radius: ${radii.xl};
|
|
1651
|
+
padding: ${spaces[6]};
|
|
1652
|
+
background-color: ${colors.background.primary};
|
|
1653
|
+
`;
|
|
1654
|
+
var Modal = ({
|
|
1655
|
+
visible,
|
|
1656
|
+
contentPosition = "center",
|
|
1657
|
+
dismissable = true,
|
|
1658
|
+
onClose,
|
|
1659
|
+
children
|
|
1660
|
+
}) => {
|
|
1661
|
+
function onDismiss() {
|
|
1662
|
+
if (dismissable) {
|
|
1663
|
+
onClose();
|
|
1664
|
+
}
|
|
1665
|
+
}
|
|
1666
|
+
if (!visible) return /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, {});
|
|
1667
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Overlay, { contentPosition, onClick: onDismiss, children: /* @__PURE__ */ jsxRuntime.jsx(ContentContainer, { onClick: (e) => e.stopPropagation(), children }) });
|
|
1668
|
+
};
|
|
1669
|
+
var Container13 = styled40__default.default.div`
|
|
1670
|
+
display: flex;
|
|
1671
|
+
align-items: center ;
|
|
1672
|
+
justify-content: space-between;
|
|
1673
|
+
padding: ${spaces[2]} ${spaces[3]};
|
|
1674
|
+
background-color: ${(props) => props.isComplete ? colors.background.blue : colors.background.light};
|
|
1675
|
+
border-radius: ${radii.sm};
|
|
1676
|
+
`;
|
|
1677
|
+
var Row = styled40__default.default.div`
|
|
1678
|
+
display: flex;
|
|
1679
|
+
align-items: center;
|
|
1680
|
+
gap: ${spaces[2]};
|
|
1681
|
+
`;
|
|
1682
|
+
var OverviewRowItem = ({ isComplete, isMainHeader, title }) => {
|
|
1683
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(Container13, { isComplete, children: [
|
|
1684
|
+
/* @__PURE__ */ jsxRuntime.jsx(Header, { variant: isMainHeader ? "h2" : "h3", color: isComplete ? "secondary" : "primary", children: title }),
|
|
1685
|
+
/* @__PURE__ */ jsxRuntime.jsxs(Row, { children: [
|
|
1686
|
+
/* @__PURE__ */ jsxRuntime.jsx(Header, { variant: "h3", color: isComplete ? "secondary" : "primary", children: isComplete ? "Complete" : "Information Outstanding" }),
|
|
1687
|
+
isComplete ? /* @__PURE__ */ jsxRuntime.jsx(fa6.FaCircleCheck, { color: colors.background.success }) : /* @__PURE__ */ jsxRuntime.jsx(fa6.FaCircleExclamation, { color: colors.background.error })
|
|
1688
|
+
] })
|
|
1689
|
+
] });
|
|
1690
|
+
};
|
|
1691
|
+
function Spinner(props) {
|
|
1692
|
+
return /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1693
|
+
"svg",
|
|
1694
|
+
{
|
|
1695
|
+
"aria-hidden": "true",
|
|
1696
|
+
className: "w-8 h-8 text-gray-200 animate-spin dark:text-gray-600 fill-blue-600",
|
|
1697
|
+
viewBox: "0 0 100 101",
|
|
1698
|
+
fill: "none",
|
|
1699
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
1700
|
+
...props,
|
|
1701
|
+
children: [
|
|
1702
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1703
|
+
"path",
|
|
1704
|
+
{
|
|
1705
|
+
d: "M100 50.5908C100 78.2051 77.6142 100.591 50 100.591C22.3858 100.591 0 78.2051 0 50.5908C0 22.9766 22.3858 0.59082 50 0.59082C77.6142 0.59082 100 22.9766 100 50.5908ZM9.08144 50.5908C9.08144 73.1895 27.4013 91.5094 50 91.5094C72.5987 91.5094 90.9186 73.1895 90.9186 50.5908C90.9186 27.9921 72.5987 9.67226 50 9.67226C27.4013 9.67226 9.08144 27.9921 9.08144 50.5908Z",
|
|
1706
|
+
fill: "currentColor"
|
|
1707
|
+
}
|
|
1708
|
+
),
|
|
1709
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1710
|
+
"path",
|
|
1711
|
+
{
|
|
1712
|
+
d: "M93.9676 39.0409C96.393 38.4038 97.8624 35.9116 97.0079 33.5539C95.2932 28.8227 92.871 24.3692 89.8167 20.348C85.8452 15.1192 80.8826 10.7238 75.2124 7.41289C69.5422 4.10194 63.2754 1.94025 56.7698 1.05124C51.7666 0.367541 46.6976 0.446843 41.7345 1.27873C39.2613 1.69328 37.813 4.19778 38.4501 6.62326C39.0873 9.04874 41.5694 10.4717 44.0505 10.1071C47.8511 9.54855 51.7191 9.52689 55.5402 10.0491C60.8642 10.7766 65.9928 12.5457 70.6331 15.2552C75.2735 17.9648 79.3347 21.5619 82.5849 25.841C84.9175 28.9121 86.7997 32.2913 88.1811 35.8758C89.083 38.2158 91.5421 39.6781 93.9676 39.0409Z",
|
|
1713
|
+
fill: "currentFill"
|
|
1714
|
+
}
|
|
1715
|
+
)
|
|
1716
|
+
]
|
|
1717
|
+
}
|
|
1718
|
+
) });
|
|
1719
|
+
}
|
|
1720
|
+
var Container14 = styled40__default.default.div`
|
|
1721
|
+
width: '100%';
|
|
1722
|
+
min-height: '100vh';
|
|
1723
|
+
padding-bottom: ${spaces[9]};
|
|
1724
|
+
`;
|
|
1725
|
+
var HeaderContainer2 = styled40__default.default.div`
|
|
1726
|
+
padding: ${spaces[4.5]} ${spaces[6]};
|
|
1727
|
+
display: flex;
|
|
1728
|
+
align-items: center;
|
|
1729
|
+
justify-content: space-between;
|
|
1730
|
+
`;
|
|
1731
|
+
var ContentContainer2 = styled40__default.default.div`
|
|
1732
|
+
border-top: 1px solid ${colors.border.hover};
|
|
1733
|
+
`;
|
|
1734
|
+
var SpinnerContainer = styled40__default.default.div`
|
|
1735
|
+
display: flex;
|
|
1736
|
+
width: 100%;
|
|
1737
|
+
padding: ${spaces[6]};
|
|
1738
|
+
align-items: center;
|
|
1739
|
+
justify-content: center;
|
|
1740
|
+
`;
|
|
1741
|
+
var PageLayout = ({
|
|
1742
|
+
title,
|
|
1743
|
+
children,
|
|
1744
|
+
isLoading = false,
|
|
1745
|
+
rightElement
|
|
1746
|
+
}) => {
|
|
1747
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(Container14, { children: [
|
|
1748
|
+
/* @__PURE__ */ jsxRuntime.jsxs(HeaderContainer2, { children: [
|
|
1749
|
+
/* @__PURE__ */ jsxRuntime.jsx(Header, { color: "subtle", children: title }),
|
|
1750
|
+
" ",
|
|
1751
|
+
rightElement && rightElement
|
|
1752
|
+
] }),
|
|
1753
|
+
isLoading ? /* @__PURE__ */ jsxRuntime.jsx(SpinnerContainer, { children: /* @__PURE__ */ jsxRuntime.jsx(Spinner, {}) }) : /* @__PURE__ */ jsxRuntime.jsx(ContentContainer2, { children })
|
|
1754
|
+
] });
|
|
1755
|
+
};
|
|
1756
|
+
var variants11 = ["documents", "properties"];
|
|
1757
|
+
var Container15 = styled40__default.default.div`
|
|
1758
|
+
display: flex;
|
|
1759
|
+
flex-direction: column;
|
|
1760
|
+
align-items: center;
|
|
1761
|
+
justify-content: center;
|
|
1762
|
+
flex: 1;
|
|
1763
|
+
gap: ${spaces[4]};
|
|
1764
|
+
padding: ${spaces[8]};
|
|
1765
|
+
`;
|
|
1766
|
+
var EmptyState = ({ variant, message }) => {
|
|
1767
|
+
const size = sizes.xl;
|
|
1768
|
+
const color = colors.text.primary;
|
|
1769
|
+
const Icon = react.useMemo(() => {
|
|
1770
|
+
switch (variant) {
|
|
1771
|
+
case "documents":
|
|
1772
|
+
return /* @__PURE__ */ jsxRuntime.jsx(fa6.FaRegFolderOpen, { size, color });
|
|
1773
|
+
case "properties":
|
|
1774
|
+
return /* @__PURE__ */ jsxRuntime.jsx(fa6.FaHouse, { size, color });
|
|
1775
|
+
}
|
|
1776
|
+
}, [variant]);
|
|
1777
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(Container15, { children: [
|
|
1778
|
+
Icon,
|
|
1779
|
+
/* @__PURE__ */ jsxRuntime.jsx(Header, { variant: "h3", children: message })
|
|
1780
|
+
] });
|
|
1781
|
+
};
|
|
1782
|
+
EmptyState.variants = variants11;
|
|
1783
|
+
var Container16 = styled40__default.default.div`
|
|
1784
|
+
width: 100%;
|
|
1785
|
+
height: 100%;
|
|
1786
|
+
`;
|
|
1787
|
+
var PDFPreviewer = ({ url }) => {
|
|
1788
|
+
const [error, setError] = react.useState(null);
|
|
1789
|
+
react.useEffect(() => {
|
|
1790
|
+
setError(null);
|
|
1791
|
+
try {
|
|
1792
|
+
new URL(url);
|
|
1793
|
+
} catch {
|
|
1794
|
+
setError("Invalid preview URL");
|
|
1795
|
+
}
|
|
1796
|
+
}, [url]);
|
|
1797
|
+
if (typeof error === "string")
|
|
1798
|
+
return /* @__PURE__ */ jsxRuntime.jsx(EmptyState, { message: "Failed to load this document", variant: "documents" });
|
|
1799
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Container16, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
1800
|
+
"iframe",
|
|
1801
|
+
{
|
|
1802
|
+
src: `${url}#view=FitH&toolbar=1&navpanes=0`,
|
|
1803
|
+
title: "Document preview",
|
|
1804
|
+
allow: "clipboard-read; clipboard-write",
|
|
1805
|
+
referrerPolicy: "no-referrer",
|
|
1806
|
+
style: { width: "100%", height: "100%", border: "0" }
|
|
1807
|
+
}
|
|
1808
|
+
) });
|
|
1809
|
+
};
|
|
1810
|
+
var Container17 = styled40__default.default.div`
|
|
1811
|
+
display: flex;
|
|
1812
|
+
gap: 1.5rem;
|
|
1813
|
+
align-items: center;
|
|
1814
|
+
max-width: 600px;
|
|
1815
|
+
|
|
1816
|
+
/* Mobile: stack vertically */
|
|
1817
|
+
@media (max-width: 767px) {
|
|
1818
|
+
flex-direction: column;
|
|
1819
|
+
align-items: flex-start;
|
|
1820
|
+
max-width: 100%;
|
|
1821
|
+
}
|
|
1822
|
+
`;
|
|
1823
|
+
var ImageWrapper = styled40__default.default.div`
|
|
1824
|
+
flex-shrink: 0;
|
|
1825
|
+
width: 180px;
|
|
1826
|
+
height: 180px;
|
|
1827
|
+
border-radius: 8px;
|
|
1828
|
+
overflow: hidden;
|
|
1829
|
+
|
|
1830
|
+
img {
|
|
1831
|
+
width: 100%;
|
|
1832
|
+
height: 100%;
|
|
1833
|
+
object-fit: cover;
|
|
1834
|
+
}
|
|
1835
|
+
|
|
1836
|
+
/* Mobile: full width */
|
|
1837
|
+
@media (max-width: 767px) {
|
|
1838
|
+
width: 100%;
|
|
1839
|
+
height: 200px;
|
|
1840
|
+
}
|
|
1841
|
+
`;
|
|
1842
|
+
var ContentWrapper = styled40__default.default.div`
|
|
1843
|
+
display: flex;
|
|
1844
|
+
flex-direction: column;
|
|
1845
|
+
gap: 1rem;
|
|
1846
|
+
|
|
1847
|
+
/* Mobile: full width */
|
|
1848
|
+
@media (max-width: 767px) {
|
|
1849
|
+
width: 100%;
|
|
1850
|
+
}
|
|
1851
|
+
`;
|
|
1852
|
+
var LogoWrapper = styled40__default.default.div`
|
|
1853
|
+
max-width: 200px;
|
|
1854
|
+
|
|
1855
|
+
img {
|
|
1856
|
+
width: 100%;
|
|
1857
|
+
height: auto;
|
|
1858
|
+
}
|
|
1859
|
+
`;
|
|
1860
|
+
var ProductInfo = ({
|
|
1861
|
+
image,
|
|
1862
|
+
logoImage,
|
|
1863
|
+
title,
|
|
1864
|
+
buttonText,
|
|
1865
|
+
onButtonClick,
|
|
1866
|
+
titleVariant = "h2",
|
|
1867
|
+
titleColor = "brand",
|
|
1868
|
+
buttonArrowVariant = "teal",
|
|
1869
|
+
buttonTextBgVariant = "brand",
|
|
1870
|
+
buttonTextVariant = "secondary"
|
|
1871
|
+
}) => {
|
|
1872
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(Container17, { children: [
|
|
1873
|
+
/* @__PURE__ */ jsxRuntime.jsx(ImageWrapper, { children: /* @__PURE__ */ jsxRuntime.jsx("img", { src: image, alt: "Product" }) }),
|
|
1874
|
+
/* @__PURE__ */ jsxRuntime.jsxs(ContentWrapper, { children: [
|
|
1875
|
+
/* @__PURE__ */ jsxRuntime.jsx(LogoWrapper, { children: /* @__PURE__ */ jsxRuntime.jsx("img", { src: logoImage, alt: "Logo" }) }),
|
|
1876
|
+
/* @__PURE__ */ jsxRuntime.jsx(Header, { variant: titleVariant, color: titleColor, children: title }),
|
|
1877
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1878
|
+
ExtendedButton,
|
|
1879
|
+
{
|
|
1880
|
+
text: buttonText,
|
|
1881
|
+
onClick: onButtonClick,
|
|
1882
|
+
arrowVariant: buttonArrowVariant,
|
|
1883
|
+
textBgVariant: buttonTextBgVariant,
|
|
1884
|
+
textVariant: buttonTextVariant
|
|
1885
|
+
}
|
|
1886
|
+
)
|
|
1887
|
+
] })
|
|
1888
|
+
] });
|
|
1889
|
+
};
|
|
1890
|
+
var Container18 = styled40__default.default.div``;
|
|
1891
|
+
var OptionsContainer2 = styled40__default.default.div`
|
|
1892
|
+
margin-top: ${spaces[2]};
|
|
1893
|
+
display: flex;
|
|
1894
|
+
flex-direction: row;
|
|
1895
|
+
flex: 1;
|
|
1896
|
+
gap: ${spaces[2]};
|
|
1897
|
+
`;
|
|
1898
|
+
var LabelContainer = styled40__default.default.div`
|
|
1899
|
+
padding-left: ${spaces[1]};
|
|
1900
|
+
`;
|
|
1901
|
+
var RadioGroup = ({
|
|
1902
|
+
label,
|
|
1903
|
+
options,
|
|
1904
|
+
value,
|
|
1905
|
+
onClick,
|
|
1906
|
+
className
|
|
1907
|
+
}) => {
|
|
1908
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(Container18, { className, children: [
|
|
1909
|
+
typeof label === "string" && /* @__PURE__ */ jsxRuntime.jsx(LabelContainer, { children: /* @__PURE__ */ jsxRuntime.jsx(Label, { value: label, fontWeight: "600" }) }),
|
|
1910
|
+
/* @__PURE__ */ jsxRuntime.jsx(OptionsContainer2, { children: options.map((option, idx) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1911
|
+
RadioItem,
|
|
1912
|
+
{
|
|
1913
|
+
isSelected: value === option.value,
|
|
1914
|
+
label: option.label,
|
|
1915
|
+
disabled: option.disabled,
|
|
1916
|
+
onClick: () => onClick(option.value)
|
|
1917
|
+
},
|
|
1918
|
+
idx
|
|
1919
|
+
)) })
|
|
1920
|
+
] });
|
|
1921
|
+
};
|
|
1922
|
+
var variants12 = ["primary", "secondary", "subtle"];
|
|
1923
|
+
var Overlay2 = styled40__default.default.div`
|
|
1924
|
+
position: fixed;
|
|
1925
|
+
top: 0;
|
|
1926
|
+
left: 0;
|
|
1927
|
+
right: 0;
|
|
1928
|
+
bottom: 0;
|
|
1929
|
+
background-color: rgba(0, 0, 0, 0.5);
|
|
1930
|
+
display: flex;
|
|
1931
|
+
align-items: center;
|
|
1932
|
+
justify-content: center;
|
|
1933
|
+
z-index: 1000;
|
|
1934
|
+
`;
|
|
1935
|
+
var ChartContainer = styled40__default.default.div`
|
|
1936
|
+
background-color: #ffffff;
|
|
1937
|
+
border-radius: 8px;
|
|
1938
|
+
padding: 2rem;
|
|
1939
|
+
max-width: 400px;
|
|
1940
|
+
width: 90%;
|
|
1941
|
+
box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
|
|
1942
|
+
`;
|
|
1943
|
+
var HeaderSection = styled40__default.default.div`
|
|
1944
|
+
display: flex;
|
|
1945
|
+
justify-content: space-between;
|
|
1946
|
+
align-items: center;
|
|
1947
|
+
margin-bottom: 1.5rem;
|
|
1948
|
+
`;
|
|
1949
|
+
var CloseButton = styled40__default.default.button`
|
|
1950
|
+
background-color: ${(props) => {
|
|
1951
|
+
switch (props.variant) {
|
|
1952
|
+
case "primary":
|
|
1953
|
+
return colors.background.brand;
|
|
1954
|
+
case "secondary":
|
|
1955
|
+
return colors.background.blue;
|
|
1956
|
+
case "subtle":
|
|
1957
|
+
return colors.background.subtle;
|
|
1958
|
+
default:
|
|
1959
|
+
return colors.background.brand;
|
|
1960
|
+
}
|
|
1961
|
+
}};
|
|
1962
|
+
color: #ffffff;
|
|
1963
|
+
border: none;
|
|
1964
|
+
border-radius: 4px;
|
|
1965
|
+
width: 2rem;
|
|
1966
|
+
height: 2rem;
|
|
1967
|
+
display: flex;
|
|
1968
|
+
align-items: center;
|
|
1969
|
+
justify-content: center;
|
|
1970
|
+
cursor: pointer;
|
|
1971
|
+
transition: opacity 0.2s;
|
|
1972
|
+
|
|
1973
|
+
&:hover {
|
|
1974
|
+
opacity: 0.8;
|
|
1975
|
+
}
|
|
1976
|
+
`;
|
|
1977
|
+
var Table = styled40__default.default.table`
|
|
1978
|
+
width: 100%;
|
|
1979
|
+
border-collapse: collapse;
|
|
1980
|
+
`;
|
|
1981
|
+
var TableHeader = styled40__default.default.thead`
|
|
1982
|
+
border-bottom: 2px solid #e5e7eb;
|
|
1983
|
+
`;
|
|
1984
|
+
var TableHeaderCell = styled40__default.default.th`
|
|
1985
|
+
text-align: left;
|
|
1986
|
+
padding: 0.75rem 0;
|
|
1987
|
+
font-size: 0.875rem;
|
|
1988
|
+
font-weight: 700;
|
|
1989
|
+
text-transform: uppercase;
|
|
1990
|
+
color: ${(props) => {
|
|
1991
|
+
switch (props.variant) {
|
|
1992
|
+
case "primary":
|
|
1993
|
+
return colors.text.brand;
|
|
1994
|
+
case "secondary":
|
|
1995
|
+
return colors.text.blue;
|
|
1996
|
+
case "subtle":
|
|
1997
|
+
return colors.text.subtle;
|
|
1998
|
+
default:
|
|
1999
|
+
return colors.text.brand;
|
|
2000
|
+
}
|
|
2001
|
+
}};
|
|
2002
|
+
`;
|
|
2003
|
+
var TableBody = styled40__default.default.tbody``;
|
|
2004
|
+
var TableRow = styled40__default.default.tr`
|
|
2005
|
+
border-bottom: 1px solid #f3f4f6;
|
|
2006
|
+
|
|
2007
|
+
&:last-child {
|
|
2008
|
+
border-bottom: none;
|
|
2009
|
+
}
|
|
2010
|
+
`;
|
|
2011
|
+
var TableCell = styled40__default.default.td`
|
|
2012
|
+
padding: 0.75rem 0;
|
|
2013
|
+
font-size: 0.875rem;
|
|
2014
|
+
color: ${(props) => {
|
|
2015
|
+
switch (props.variant) {
|
|
2016
|
+
case "primary":
|
|
2017
|
+
case "secondary":
|
|
2018
|
+
return colors.text.primary;
|
|
2019
|
+
case "subtle":
|
|
2020
|
+
return colors.text.subtle;
|
|
2021
|
+
default:
|
|
2022
|
+
return colors.text.primary;
|
|
2023
|
+
}
|
|
2024
|
+
}};
|
|
2025
|
+
`;
|
|
2026
|
+
var RatesChart = ({
|
|
2027
|
+
title = "Rates chart",
|
|
2028
|
+
rates,
|
|
2029
|
+
onClose,
|
|
2030
|
+
variant = "primary"
|
|
2031
|
+
}) => {
|
|
2032
|
+
const getHeaderColor = () => {
|
|
2033
|
+
switch (variant) {
|
|
2034
|
+
case "primary":
|
|
2035
|
+
return "brand";
|
|
2036
|
+
case "secondary":
|
|
2037
|
+
return "primary";
|
|
2038
|
+
case "subtle":
|
|
2039
|
+
return "subtle";
|
|
2040
|
+
default:
|
|
2041
|
+
return "brand";
|
|
2042
|
+
}
|
|
2043
|
+
};
|
|
2044
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Overlay2, { onClick: onClose, children: /* @__PURE__ */ jsxRuntime.jsxs(ChartContainer, { onClick: (e) => e.stopPropagation(), children: [
|
|
2045
|
+
/* @__PURE__ */ jsxRuntime.jsxs(HeaderSection, { children: [
|
|
2046
|
+
/* @__PURE__ */ jsxRuntime.jsx(Header, { variant: "h2", color: getHeaderColor(), children: title }),
|
|
2047
|
+
/* @__PURE__ */ jsxRuntime.jsx(CloseButton, { onClick: onClose, variant, children: /* @__PURE__ */ jsxRuntime.jsx(hi.HiX, { size: 20 }) })
|
|
2048
|
+
] }),
|
|
2049
|
+
/* @__PURE__ */ jsxRuntime.jsxs(Table, { children: [
|
|
2050
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableHeader, { children: /* @__PURE__ */ jsxRuntime.jsxs("tr", { children: [
|
|
2051
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableHeaderCell, { variant, children: "Transaction type" }),
|
|
2052
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableHeaderCell, { variant, children: "Price" })
|
|
2053
|
+
] }) }),
|
|
2054
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableBody, { children: rates.map((rate, index) => /* @__PURE__ */ jsxRuntime.jsxs(TableRow, { children: [
|
|
2055
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableCell, { variant, children: rate.transactionType }),
|
|
2056
|
+
/* @__PURE__ */ jsxRuntime.jsx(TableCell, { variant, children: rate.price })
|
|
2057
|
+
] }, index)) })
|
|
2058
|
+
] })
|
|
2059
|
+
] }) });
|
|
2060
|
+
};
|
|
2061
|
+
RatesChart.variants = variants12;
|
|
2062
|
+
var Backdrop = styled40__default.default.div`
|
|
2063
|
+
display: none;
|
|
2064
|
+
|
|
2065
|
+
@media (max-width: 767px) {
|
|
2066
|
+
display: ${(props) => props.$isOpen ? "block" : "none"};
|
|
2067
|
+
position: fixed;
|
|
2068
|
+
top: 0;
|
|
2069
|
+
left: 0;
|
|
2070
|
+
right: 0;
|
|
2071
|
+
bottom: 0;
|
|
2072
|
+
background-color: rgba(0, 0, 0, 0.5);
|
|
2073
|
+
z-index: 9998;
|
|
2074
|
+
}
|
|
2075
|
+
`;
|
|
2076
|
+
var BackToTopWrapper = styled40__default.default.div`
|
|
2077
|
+
@media (max-width: 767px) {
|
|
2078
|
+
display: none;
|
|
2079
|
+
}
|
|
2080
|
+
`;
|
|
2081
|
+
var StyledNav = styled40__default.default.nav`
|
|
2082
|
+
width: 195px;
|
|
2083
|
+
display: flex;
|
|
2084
|
+
flex-direction: column;
|
|
2085
|
+
min-height: 500px;
|
|
2086
|
+
height: 100vh;
|
|
2087
|
+
padding-bottom: 15px;
|
|
2088
|
+
|
|
2089
|
+
@media (min-width: 768px) {
|
|
2090
|
+
position: relative;
|
|
2091
|
+
background-color: #ffffff;
|
|
2092
|
+
border-right: 1px solid #e5e7eb;
|
|
2093
|
+
}
|
|
2094
|
+
|
|
2095
|
+
@media (max-width: 767px) {
|
|
2096
|
+
position: fixed;
|
|
2097
|
+
top: 0;
|
|
2098
|
+
left: 0;
|
|
2099
|
+
width: 100%;
|
|
2100
|
+
z-index: 9999;
|
|
2101
|
+
background-color: ${(props) => colors.background[props.$mobileBgVariant]};
|
|
2102
|
+
border-right: 1px solid ${(props) => colors.border[props.$borderVariant]};
|
|
2103
|
+
transform: translateX(${(props) => props.$isOpen ? "0" : "-100%"});
|
|
2104
|
+
transition: transform 0.3s ease-in-out;
|
|
2105
|
+
box-shadow: ${(props) => props.$isOpen ? "2px 0 8px rgba(0, 0, 0, 0.15)" : "none"};
|
|
2106
|
+
}
|
|
2107
|
+
`;
|
|
2108
|
+
var CloseButton2 = styled40__default.default.button`
|
|
2109
|
+
background: none;
|
|
2110
|
+
border: none;
|
|
2111
|
+
font-size: 1.5rem;
|
|
2112
|
+
cursor: pointer;
|
|
2113
|
+
padding: 0.5rem;
|
|
2114
|
+
color: ${(props) => colors.border[props.$textVariant]};
|
|
2115
|
+
|
|
2116
|
+
&:hover {
|
|
2117
|
+
opacity: 0.7;
|
|
2118
|
+
}
|
|
2119
|
+
`;
|
|
2120
|
+
var MobileHeader = styled40__default.default.div`
|
|
2121
|
+
display: none;
|
|
2122
|
+
|
|
2123
|
+
@media (max-width: 767px) {
|
|
2124
|
+
display: flex;
|
|
2125
|
+
justify-content: space-between;
|
|
2126
|
+
align-items: center;
|
|
2127
|
+
padding: 1rem;
|
|
2128
|
+
}
|
|
2129
|
+
`;
|
|
2130
|
+
var NavList = styled40__default.default.ul`
|
|
2131
|
+
display: flex;
|
|
2132
|
+
flex-direction: column;
|
|
2133
|
+
list-style: none;
|
|
2134
|
+
margin: 0;
|
|
2135
|
+
padding: 0;
|
|
2136
|
+
`;
|
|
2137
|
+
var DesktopNavList = styled40__default.default(NavList)`
|
|
2138
|
+
@media (max-width: 767px) {
|
|
2139
|
+
display: none;
|
|
2140
|
+
}
|
|
2141
|
+
`;
|
|
2142
|
+
var MobileNavList = styled40__default.default(NavList)`
|
|
2143
|
+
display: none;
|
|
2144
|
+
|
|
2145
|
+
@media (max-width: 767px) {
|
|
2146
|
+
display: flex;
|
|
2147
|
+
}
|
|
2148
|
+
`;
|
|
2149
|
+
var NavItem = styled40__default.default.li`
|
|
2150
|
+
display: flex;
|
|
2151
|
+
`;
|
|
2152
|
+
var NavLink = styled40__default.default.a`
|
|
2153
|
+
display: flex;
|
|
2154
|
+
align-items: center;
|
|
2155
|
+
text-decoration: none;
|
|
2156
|
+
width: 100%;
|
|
2157
|
+
padding-left: 0.5rem;
|
|
2158
|
+
|
|
2159
|
+
${(props) => !props.$isActive && `
|
|
2160
|
+
&:hover {
|
|
2161
|
+
font-weight: 100;
|
|
2162
|
+
}
|
|
2163
|
+
`}
|
|
2164
|
+
`;
|
|
2165
|
+
var ActiveTriangle = styled40__default.default.div`
|
|
2166
|
+
width: 0;
|
|
2167
|
+
height: 0;
|
|
2168
|
+
border-top: 4px solid transparent;
|
|
2169
|
+
border-left: 6px solid ${(props) => colors.border[props.triangleColor]};
|
|
2170
|
+
border-bottom: 4px solid transparent;
|
|
2171
|
+
flex-shrink: 0;
|
|
2172
|
+
margin-left: 1.5rem;
|
|
2173
|
+
`;
|
|
2174
|
+
var InactiveSpacer = styled40__default.default.span`
|
|
2175
|
+
width: 6px;
|
|
2176
|
+
margin-right: 0.5rem;
|
|
2177
|
+
flex-shrink: 0;
|
|
2178
|
+
`;
|
|
2179
|
+
var Divider = styled40__default.default.div`
|
|
2180
|
+
height: 1px;
|
|
2181
|
+
background-color: ${(props) => colors.border[props.dividerColor]};
|
|
2182
|
+
margin: 1rem;
|
|
2183
|
+
`;
|
|
2184
|
+
var Spacer = styled40__default.default.div`
|
|
2185
|
+
flex-grow: 1;
|
|
2186
|
+
`;
|
|
2187
|
+
var DesktopOnlySpacer = styled40__default.default(Spacer)`
|
|
2188
|
+
@media (max-width: 767px) {
|
|
2189
|
+
display: none;
|
|
2190
|
+
}
|
|
2191
|
+
`;
|
|
2192
|
+
var MobileButtonsWrapper = styled40__default.default.div`
|
|
2193
|
+
display: none;
|
|
2194
|
+
|
|
2195
|
+
@media (max-width: 767px) {
|
|
2196
|
+
display: flex;
|
|
2197
|
+
flex-direction: row;
|
|
2198
|
+
gap: 0.5rem;
|
|
2199
|
+
padding: 0 1rem;
|
|
2200
|
+
margin-top: auto;
|
|
2201
|
+
margin-bottom: 20px;
|
|
2202
|
+
}
|
|
2203
|
+
`;
|
|
2204
|
+
var SideNav = ({
|
|
2205
|
+
logo,
|
|
2206
|
+
items,
|
|
2207
|
+
activeItem,
|
|
2208
|
+
onBackToTop,
|
|
2209
|
+
isOpen = true,
|
|
2210
|
+
onClose,
|
|
2211
|
+
mobileButtons = [],
|
|
2212
|
+
mobileBgVariant = "tertiary",
|
|
2213
|
+
borderVariant = "primary",
|
|
2214
|
+
closeButtonVariant = "light",
|
|
2215
|
+
mobileActiveTextBgVariant = "transparent",
|
|
2216
|
+
mobileActiveTextVariant = "light",
|
|
2217
|
+
mobileInactiveTextBgVariant = "transparent",
|
|
2218
|
+
mobileInactiveTextVariant = "light",
|
|
2219
|
+
triangleColor = "primary",
|
|
2220
|
+
dividerColor = "light",
|
|
2221
|
+
activeTextBgVariant = "transparent",
|
|
2222
|
+
activeTextVariant = "brand",
|
|
2223
|
+
inactiveTextBgVariant = "transparent",
|
|
2224
|
+
inactiveTextVariant = "subtle",
|
|
2225
|
+
backToTopBgVariant = "transparent",
|
|
2226
|
+
backToTopTextVariant = "subtle"
|
|
2227
|
+
}) => {
|
|
2228
|
+
const renderNavItems = (isMobile) => items.map((item) => {
|
|
2229
|
+
const isActive = activeItem === item.href;
|
|
2230
|
+
return /* @__PURE__ */ jsxRuntime.jsx(NavItem, { children: /* @__PURE__ */ jsxRuntime.jsxs(NavLink, { href: item.href, $isActive: isActive, children: [
|
|
2231
|
+
isActive ? /* @__PURE__ */ jsxRuntime.jsx(ActiveTriangle, { triangleColor }) : /* @__PURE__ */ jsxRuntime.jsx(InactiveSpacer, {}),
|
|
2232
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2233
|
+
TextButton,
|
|
2234
|
+
{
|
|
2235
|
+
asChild: true,
|
|
2236
|
+
text: item.label,
|
|
2237
|
+
bgVariant: isActive ? isMobile && mobileActiveTextBgVariant ? mobileActiveTextBgVariant : activeTextBgVariant : isMobile && mobileInactiveTextBgVariant ? mobileInactiveTextBgVariant : inactiveTextBgVariant,
|
|
2238
|
+
textVariant: isActive ? isMobile && mobileActiveTextVariant ? mobileActiveTextVariant : activeTextVariant : isMobile && mobileInactiveTextVariant ? mobileInactiveTextVariant : inactiveTextVariant,
|
|
2239
|
+
uppercase: false,
|
|
2240
|
+
bold: isActive
|
|
2241
|
+
}
|
|
2242
|
+
)
|
|
2243
|
+
] }) }, item.href);
|
|
2244
|
+
});
|
|
2245
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
2246
|
+
/* @__PURE__ */ jsxRuntime.jsx(Backdrop, { $isOpen: isOpen, onClick: onClose }),
|
|
2247
|
+
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
2248
|
+
StyledNav,
|
|
2249
|
+
{
|
|
2250
|
+
$isOpen: isOpen,
|
|
2251
|
+
$mobileBgVariant: mobileBgVariant,
|
|
2252
|
+
$borderVariant: borderVariant,
|
|
2253
|
+
children: [
|
|
2254
|
+
/* @__PURE__ */ jsxRuntime.jsxs(MobileHeader, { children: [
|
|
2255
|
+
logo,
|
|
2256
|
+
/* @__PURE__ */ jsxRuntime.jsx(CloseButton2, { onClick: onClose, "aria-label": "Close menu", $textVariant: closeButtonVariant, children: "\u2715" })
|
|
2257
|
+
] }),
|
|
2258
|
+
/* @__PURE__ */ jsxRuntime.jsx(DesktopOnlySpacer, {}),
|
|
2259
|
+
/* @__PURE__ */ jsxRuntime.jsx(DesktopNavList, { children: renderNavItems(false) }),
|
|
2260
|
+
/* @__PURE__ */ jsxRuntime.jsx(MobileNavList, { children: renderNavItems(true) }),
|
|
2261
|
+
/* @__PURE__ */ jsxRuntime.jsx(Divider, { dividerColor }),
|
|
2262
|
+
/* @__PURE__ */ jsxRuntime.jsx(Spacer, {}),
|
|
2263
|
+
mobileButtons.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
2264
|
+
/* @__PURE__ */ jsxRuntime.jsx(Divider, { dividerColor }),
|
|
2265
|
+
/* @__PURE__ */ jsxRuntime.jsx(MobileButtonsWrapper, { children: mobileButtons.map((button, index) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2266
|
+
ExtendedButton,
|
|
2267
|
+
{
|
|
2268
|
+
text: button.text,
|
|
2269
|
+
onClick: button.onClick,
|
|
2270
|
+
textBgVariant: button.bgVariant || "transparent",
|
|
2271
|
+
textVariant: button.textVariant || "subtle",
|
|
2272
|
+
arrowVariant: button.arrowButton || "blue"
|
|
2273
|
+
},
|
|
2274
|
+
index
|
|
2275
|
+
)) })
|
|
2276
|
+
] }),
|
|
2277
|
+
/* @__PURE__ */ jsxRuntime.jsx(BackToTopWrapper, { children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
2278
|
+
TextButton,
|
|
2279
|
+
{
|
|
2280
|
+
text: "Back to top",
|
|
2281
|
+
onClick: onBackToTop,
|
|
2282
|
+
bgVariant: backToTopBgVariant,
|
|
2283
|
+
textVariant: backToTopTextVariant,
|
|
2284
|
+
uppercase: false
|
|
2285
|
+
}
|
|
2286
|
+
) })
|
|
2287
|
+
]
|
|
2288
|
+
}
|
|
2289
|
+
)
|
|
2290
|
+
] });
|
|
2291
|
+
};
|
|
2292
|
+
var Overlay3 = styled40__default.default.div`
|
|
2293
|
+
position: fixed;
|
|
2294
|
+
top: 0;
|
|
2295
|
+
left: 0;
|
|
2296
|
+
right: 0;
|
|
2297
|
+
bottom: 0;
|
|
2298
|
+
background-color: rgba(0, 0, 0, 0.5);
|
|
2299
|
+
display: ${(props) => props.$isOpen ? "flex" : "none"};
|
|
2300
|
+
justify-content: flex-end;
|
|
2301
|
+
z-index: 1000;
|
|
2302
|
+
`;
|
|
2303
|
+
var PanelContainer = styled40__default.default.div`
|
|
2304
|
+
background-color: #ffffff;
|
|
2305
|
+
width: 100%;
|
|
2306
|
+
max-width: 400px;
|
|
2307
|
+
height: 100vh;
|
|
2308
|
+
padding: 3rem 2rem;
|
|
2309
|
+
box-shadow: -4px 0 15px rgba(0, 0, 0, 0.2);
|
|
2310
|
+
display: flex;
|
|
2311
|
+
flex-direction: column;
|
|
2312
|
+
gap: 2rem;
|
|
2313
|
+
transform: ${(props) => props.$isOpen ? "translateX(0)" : "translateX(100%)"};
|
|
2314
|
+
transition: transform 0.3s ease-in-out;
|
|
2315
|
+
overflow-y: auto;
|
|
2316
|
+
`;
|
|
2317
|
+
var CloseButton3 = styled40__default.default.button`
|
|
2318
|
+
position: absolute;
|
|
2319
|
+
top: 1.5rem;
|
|
2320
|
+
right: 1.5rem;
|
|
2321
|
+
background-color: ${(props) => colors.background[props.closeButtonBgColor]};
|
|
2322
|
+
color: #ffffff;
|
|
2323
|
+
border: none;
|
|
2324
|
+
border-radius: 4px;
|
|
2325
|
+
width: 2.5rem;
|
|
2326
|
+
height: 2.5rem;
|
|
2327
|
+
display: flex;
|
|
2328
|
+
align-items: center;
|
|
2329
|
+
justify-content: center;
|
|
2330
|
+
cursor: pointer;
|
|
2331
|
+
transition: opacity 0.2s;
|
|
2332
|
+
z-index: 10;
|
|
2333
|
+
|
|
2334
|
+
&:hover {
|
|
2335
|
+
opacity: 0.8;
|
|
2336
|
+
}
|
|
2337
|
+
`;
|
|
2338
|
+
var IconWrapper2 = styled40__default.default.div`
|
|
2339
|
+
width: 100%;
|
|
2340
|
+
display: flex;
|
|
2341
|
+
justify-content: center;
|
|
2342
|
+
margin-bottom: 1rem;
|
|
2343
|
+
|
|
2344
|
+
svg {
|
|
2345
|
+
width: 150px;
|
|
2346
|
+
height: 150px;
|
|
2347
|
+
}
|
|
2348
|
+
|
|
2349
|
+
img {
|
|
2350
|
+
width: 150px;
|
|
2351
|
+
height: 150px;
|
|
2352
|
+
object-fit: contain;
|
|
2353
|
+
}
|
|
2354
|
+
`;
|
|
2355
|
+
var ContentWrapper2 = styled40__default.default.div`
|
|
2356
|
+
display: flex;
|
|
2357
|
+
flex-direction: column;
|
|
2358
|
+
gap: 1.5rem;
|
|
2359
|
+
`;
|
|
2360
|
+
var SidePanel = ({
|
|
2361
|
+
isOpen,
|
|
2362
|
+
onClose,
|
|
2363
|
+
icon,
|
|
2364
|
+
title,
|
|
2365
|
+
description,
|
|
2366
|
+
buttonText,
|
|
2367
|
+
onButtonClick,
|
|
2368
|
+
closeButtonBgColor = "subtle",
|
|
2369
|
+
titleColor = "brand",
|
|
2370
|
+
descriptionVariant = "primary",
|
|
2371
|
+
buttonArrowVariant = "teal",
|
|
2372
|
+
buttonTextBgVariant = "brand",
|
|
2373
|
+
buttonTextVariant = "secondary"
|
|
2374
|
+
}) => {
|
|
2375
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Overlay3, { $isOpen: isOpen, onClick: onClose, children: /* @__PURE__ */ jsxRuntime.jsxs(PanelContainer, { $isOpen: isOpen, onClick: (e) => e.stopPropagation(), children: [
|
|
2376
|
+
/* @__PURE__ */ jsxRuntime.jsx(CloseButton3, { onClick: onClose, closeButtonBgColor, children: /* @__PURE__ */ jsxRuntime.jsx(hi.HiX, { size: 24 }) }),
|
|
2377
|
+
/* @__PURE__ */ jsxRuntime.jsx(IconWrapper2, { children: icon }),
|
|
2378
|
+
/* @__PURE__ */ jsxRuntime.jsxs(ContentWrapper2, { children: [
|
|
2379
|
+
/* @__PURE__ */ jsxRuntime.jsx(Header, { variant: "h2", color: titleColor, children: title }),
|
|
2380
|
+
/* @__PURE__ */ jsxRuntime.jsx(Description, { variant: descriptionVariant, children: description }),
|
|
2381
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2382
|
+
ExtendedButton,
|
|
2383
|
+
{
|
|
2384
|
+
text: buttonText,
|
|
2385
|
+
onClick: onButtonClick,
|
|
2386
|
+
arrowVariant: buttonArrowVariant,
|
|
2387
|
+
textBgVariant: buttonTextBgVariant,
|
|
2388
|
+
textVariant: buttonTextVariant
|
|
2389
|
+
}
|
|
2390
|
+
)
|
|
2391
|
+
] })
|
|
2392
|
+
] }) });
|
|
2393
|
+
};
|
|
2394
|
+
var Container19 = styled40__default.default.div`
|
|
2395
|
+
width: 100%;
|
|
2396
|
+
background-color: ${(props) => props.isSelected ? colors.background.blue : colors.background.primary};
|
|
2397
|
+
border: 1px solid ${colors.background.blue};
|
|
2398
|
+
border-radius: ${radii.lg};
|
|
2399
|
+
display: flex;
|
|
2400
|
+
justify-content: center;
|
|
2401
|
+
align-items: center;
|
|
2402
|
+
padding: ${spaces[2]} ${spaces[3]};
|
|
2403
|
+
cursor: pointer;
|
|
2404
|
+
`;
|
|
2405
|
+
var StyledLabel2 = styled40__default.default.span`
|
|
2406
|
+
color: ${(props) => props.isSelected ? colors.text.secondary : colors.text.blue};
|
|
2407
|
+
font-size: ${sizes.sm};
|
|
2408
|
+
font-weight: 700;
|
|
2409
|
+
`;
|
|
2410
|
+
var StepperHeaderTab = ({
|
|
2411
|
+
title,
|
|
2412
|
+
isSelected,
|
|
2413
|
+
onClick
|
|
2414
|
+
}) => {
|
|
2415
|
+
return /* @__PURE__ */ jsxRuntime.jsx(Container19, { isSelected, onClick, children: /* @__PURE__ */ jsxRuntime.jsx(StyledLabel2, { isSelected, children: title }) });
|
|
2416
|
+
};
|
|
2417
|
+
var Textarea2 = ({ label, error, ...rest }) => {
|
|
2418
|
+
const isInvalid = react.useMemo(
|
|
2419
|
+
() => typeof error === "string" && error.length > 0,
|
|
2420
|
+
[error]
|
|
2421
|
+
);
|
|
2422
|
+
return /* @__PURE__ */ jsxRuntime.jsxs(InputContainer, { children: [
|
|
2423
|
+
typeof label === "string" && /* @__PURE__ */ jsxRuntime.jsx(
|
|
2424
|
+
FloatingLabel,
|
|
2425
|
+
{
|
|
2426
|
+
color: isInvalid ? "error" : "subtle",
|
|
2427
|
+
value: label,
|
|
2428
|
+
fontWeight: "600"
|
|
2429
|
+
}
|
|
2430
|
+
),
|
|
2431
|
+
/* @__PURE__ */ jsxRuntime.jsx(Textarea, { ...rest })
|
|
2432
|
+
] });
|
|
2433
|
+
};
|
|
2434
|
+
|
|
2435
|
+
exports.Accordion = Accordion;
|
|
2436
|
+
exports.Address = Address;
|
|
2437
|
+
exports.CTAContainer = CTAContainer;
|
|
2438
|
+
exports.Checkbox = Checkbox;
|
|
2439
|
+
exports.ContentCard = ContentCard;
|
|
2440
|
+
exports.Dropdown = Dropdown;
|
|
2441
|
+
exports.FAQAccordion = FAQAccordion;
|
|
2442
|
+
exports.FeatureContainer = FeatureContainer;
|
|
2443
|
+
exports.FileButton = FileButton;
|
|
2444
|
+
exports.Input = Input2;
|
|
2445
|
+
exports.Modal = Modal;
|
|
2446
|
+
exports.OverviewRowItem = OverviewRowItem;
|
|
2447
|
+
exports.PDFPreviewer = PDFPreviewer;
|
|
2448
|
+
exports.PageLayout = PageLayout;
|
|
2449
|
+
exports.ProductInfo = ProductInfo;
|
|
2450
|
+
exports.RadioGroup = RadioGroup;
|
|
2451
|
+
exports.RatesChart = RatesChart;
|
|
2452
|
+
exports.SideNav = SideNav;
|
|
2453
|
+
exports.SidePanel = SidePanel;
|
|
2454
|
+
exports.StepperHeaderTab = StepperHeaderTab;
|
|
2455
|
+
exports.Textarea = Textarea2;
|
|
2456
|
+
//# sourceMappingURL=molecules.cjs.map
|
|
2457
|
+
//# sourceMappingURL=molecules.cjs.map
|