@deriv-web-design/ui 0.0.2 → 0.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -1,6 +1,3 @@
1
- // primitives/Button/Button.module.css
2
- var Button_default = {};
3
-
4
1
  // primitives/Button/Button.tsx
5
2
  import { jsx, jsxs } from "react/jsx-runtime";
6
3
  var Button = ({
@@ -18,13 +15,13 @@ var Button = ({
18
15
  }) => {
19
16
  const isIconOnly = iconPosition === "icon-only";
20
17
  const classNames = [
21
- Button_default.button,
22
- Button_default[`${colorScheme}_${variant}`],
23
- isIconOnly ? Button_default.iconOnly : "",
24
- fullWidth ? Button_default.fullWidth : "",
18
+ "button",
19
+ `${colorScheme}_${variant}`,
20
+ isIconOnly ? "iconOnly" : "",
21
+ fullWidth ? "fullWidth" : "",
25
22
  className ?? ""
26
23
  ].filter(Boolean).join(" ");
27
- const iconNode = icon ? /* @__PURE__ */ jsx("span", { className: Button_default.icon, children: icon }) : null;
24
+ const iconNode = icon ? /* @__PURE__ */ jsx("span", { className: "icon", children: icon }) : null;
28
25
  return /* @__PURE__ */ jsxs(
29
26
  "button",
30
27
  {
@@ -34,18 +31,15 @@ var Button = ({
34
31
  ...props,
35
32
  children: [
36
33
  iconPosition === "icon-left" && iconNode,
37
- !isIconOnly && /* @__PURE__ */ jsx("span", { className: Button_default.label, children: label ?? children }),
34
+ !isIconOnly && /* @__PURE__ */ jsx("span", { className: "label", children: label ?? children }),
38
35
  iconPosition === "icon-only" && iconNode,
39
36
  iconPosition === "icon-right" && iconNode,
40
- showFocusRing && /* @__PURE__ */ jsx("span", { className: Button_default.focusRing, "aria-hidden": "true" })
37
+ showFocusRing && /* @__PURE__ */ jsx("span", { className: "focusRing", "aria-hidden": "true" })
41
38
  ]
42
39
  }
43
40
  );
44
41
  };
45
42
 
46
- // primitives/Link/Link.module.css
47
- var Link_default = {};
48
-
49
43
  // primitives/Link/Link.tsx
50
44
  import { jsx as jsx2, jsxs as jsxs2 } from "react/jsx-runtime";
51
45
  var ChevronIcon = () => /* @__PURE__ */ jsx2("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg", "aria-hidden": "true", children: /* @__PURE__ */ jsx2("path", { d: "M3 8h10M9 4l4 4-4 4", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) });
@@ -62,10 +56,10 @@ var Link = ({
62
56
  }) => {
63
57
  const hasIcon = !!icon;
64
58
  const classNames = [
65
- Link_default.link,
66
- Link_default[colorScheme],
67
- hasIcon ? Link_default.withIcon : Link_default.withChevron,
68
- disabled ? Link_default.disabled : "",
59
+ "link",
60
+ colorScheme,
61
+ hasIcon ? "withIcon" : "withChevron",
62
+ disabled ? "disabled" : "",
69
63
  className ?? ""
70
64
  ].filter(Boolean).join(" ");
71
65
  const handleClick = (e) => {
@@ -84,17 +78,14 @@ var Link = ({
84
78
  onClick: handleClick,
85
79
  ...props,
86
80
  children: [
87
- hasIcon && /* @__PURE__ */ jsx2("span", { className: Link_default.icon, children: icon }),
88
- /* @__PURE__ */ jsx2("span", { className: Link_default.label, children: label ?? children }),
89
- !hasIcon && showChevron && /* @__PURE__ */ jsx2("span", { className: Link_default.chevron, "aria-hidden": "true", children: /* @__PURE__ */ jsx2(ChevronIcon, {}) })
81
+ hasIcon && /* @__PURE__ */ jsx2("span", { className: "icon", children: icon }),
82
+ /* @__PURE__ */ jsx2("span", { className: "label", children: label ?? children }),
83
+ !hasIcon && showChevron && /* @__PURE__ */ jsx2("span", { className: "chevron", "aria-hidden": "true", children: /* @__PURE__ */ jsx2(ChevronIcon, {}) })
90
84
  ]
91
85
  }
92
86
  );
93
87
  };
94
88
 
95
- // primitives/Chip/Chip.module.css
96
- var Chip_default = {};
97
-
98
89
  // primitives/Chip/Chip.tsx
99
90
  import { jsx as jsx3, jsxs as jsxs3 } from "react/jsx-runtime";
100
91
  var Chip = ({
@@ -110,9 +101,9 @@ var Chip = ({
110
101
  ...props
111
102
  }) => {
112
103
  const classNames = [
113
- Chip_default.chip,
114
- Chip_default[size],
115
- selected ? Chip_default.selected : "",
104
+ "chip",
105
+ size,
106
+ selected ? "selected" : "",
116
107
  className ?? ""
117
108
  ].filter(Boolean).join(" ");
118
109
  return /* @__PURE__ */ jsxs3(
@@ -123,18 +114,15 @@ var Chip = ({
123
114
  "aria-pressed": selected,
124
115
  ...props,
125
116
  children: [
126
- icon && /* @__PURE__ */ jsx3("span", { className: Chip_default.icon, children: icon }),
127
- /* @__PURE__ */ jsx3("span", { className: Chip_default.label, children: label ?? children }),
128
- tag && /* @__PURE__ */ jsx3("span", { className: Chip_default.tag, children: tag }),
129
- showFocusRing && /* @__PURE__ */ jsx3("span", { className: Chip_default.focusRing, "aria-hidden": "true" })
117
+ icon && /* @__PURE__ */ jsx3("span", { className: "icon", children: icon }),
118
+ /* @__PURE__ */ jsx3("span", { className: "label", children: label ?? children }),
119
+ tag && /* @__PURE__ */ jsx3("span", { className: "tag", children: tag }),
120
+ showFocusRing && /* @__PURE__ */ jsx3("span", { className: "focusRing", "aria-hidden": "true" })
130
121
  ]
131
122
  }
132
123
  );
133
124
  };
134
125
 
135
- // primitives/Tag/Tag.module.css
136
- var Tag_default = {};
137
-
138
126
  // primitives/Tag/Tag.tsx
139
127
  import { jsx as jsx4, jsxs as jsxs4 } from "react/jsx-runtime";
140
128
  var Tag = ({
@@ -148,25 +136,20 @@ var Tag = ({
148
136
  ...props
149
137
  }) => {
150
138
  const classNames = [
151
- Tag_default.tag,
152
- Tag_default[size],
153
- Tag_default[variant],
154
- Tag_default[fontWeight],
139
+ "tag",
140
+ size,
141
+ variant,
142
+ fontWeight,
155
143
  className ?? ""
156
144
  ].filter(Boolean).join(" ");
157
145
  return /* @__PURE__ */ jsxs4("span", { className: classNames, ...props, children: [
158
- icon && /* @__PURE__ */ jsx4("span", { className: Tag_default.icon, children: icon }),
159
- /* @__PURE__ */ jsx4("span", { className: Tag_default.label, children: label ?? children })
146
+ icon && /* @__PURE__ */ jsx4("span", { className: "icon", children: icon }),
147
+ /* @__PURE__ */ jsx4("span", { className: "label", children: label ?? children })
160
148
  ] });
161
149
  };
162
150
 
163
151
  // primitives/Accordion/Accordion.tsx
164
152
  import { useState } from "react";
165
-
166
- // primitives/Accordion/Accordion.module.css
167
- var Accordion_default = {};
168
-
169
- // primitives/Accordion/Accordion.tsx
170
153
  import { jsx as jsx5, jsxs as jsxs5 } from "react/jsx-runtime";
171
154
  var ChevronIcon2 = () => /* @__PURE__ */ jsx5("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg", "aria-hidden": "true", children: /* @__PURE__ */ jsx5("path", { d: "M4 6l4 4 4-4", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) });
172
155
  var Accordion = ({
@@ -188,7 +171,7 @@ var Accordion = ({
188
171
  if (!isControlled) setInternalOpen(next);
189
172
  onToggle?.(next);
190
173
  };
191
- const classNames = [Accordion_default.accordion, className ?? ""].filter(Boolean).join(" ");
174
+ const classNames = ["accordion", className ?? ""].filter(Boolean).join(" ");
192
175
  return /* @__PURE__ */ jsxs5(
193
176
  "div",
194
177
  {
@@ -201,17 +184,17 @@ var Accordion = ({
201
184
  /* @__PURE__ */ jsxs5(
202
185
  "button",
203
186
  {
204
- className: Accordion_default.header,
187
+ className: "header",
205
188
  onClick: handleToggle,
206
189
  "aria-expanded": isOpen,
207
190
  children: [
208
- /* @__PURE__ */ jsx5("span", { className: Accordion_default.titleWrapper, children: /* @__PURE__ */ jsx5("span", { className: Accordion_default.title, children: title }) }),
209
- /* @__PURE__ */ jsx5("span", { className: [Accordion_default.chevron, isOpen ? Accordion_default.chevronRotated : ""].filter(Boolean).join(" "), children: /* @__PURE__ */ jsx5(ChevronIcon2, {}) }),
210
- showFocusRing && /* @__PURE__ */ jsx5("span", { className: Accordion_default.focusRing, "aria-hidden": "true" })
191
+ /* @__PURE__ */ jsx5("span", { className: "titleWrapper", children: /* @__PURE__ */ jsx5("span", { className: "title", children: title }) }),
192
+ /* @__PURE__ */ jsx5("span", { className: ["chevron", isOpen ? "chevronRotated" : ""].filter(Boolean).join(" "), children: /* @__PURE__ */ jsx5(ChevronIcon2, {}) }),
193
+ showFocusRing && /* @__PURE__ */ jsx5("span", { className: "focusRing", "aria-hidden": "true" })
211
194
  ]
212
195
  }
213
196
  ),
214
- /* @__PURE__ */ jsx5("div", { className: [Accordion_default.bodyWrapper, isOpen ? Accordion_default.bodyWrapperOpen : ""].filter(Boolean).join(" "), children: /* @__PURE__ */ jsx5("div", { className: Accordion_default.bodyInner, children: /* @__PURE__ */ jsx5("div", { className: Accordion_default.body, children }) }) })
197
+ /* @__PURE__ */ jsx5("div", { className: ["bodyWrapper", isOpen ? "bodyWrapperOpen" : ""].filter(Boolean).join(" "), children: /* @__PURE__ */ jsx5("div", { className: "bodyInner", children: /* @__PURE__ */ jsx5("div", { className: "body", children }) }) })
215
198
  ]
216
199
  }
217
200
  );
@@ -219,11 +202,6 @@ var Accordion = ({
219
202
 
220
203
  // primitives/TextField/TextField.tsx
221
204
  import { forwardRef } from "react";
222
-
223
- // primitives/TextField/TextField.module.css
224
- var TextField_default = {};
225
-
226
- // primitives/TextField/TextField.tsx
227
205
  import { jsx as jsx6, jsxs as jsxs6 } from "react/jsx-runtime";
228
206
  var SuccessIcon = () => /* @__PURE__ */ jsxs6("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg", "aria-hidden": "true", children: [
229
207
  /* @__PURE__ */ jsx6("circle", { cx: "8", cy: "8", r: "6", stroke: "currentColor", strokeWidth: "1.5" }),
@@ -243,9 +221,9 @@ var TextField = forwardRef(
243
221
  ...inputProps
244
222
  }, ref) => {
245
223
  const wrapperClass = [
246
- TextField_default.wrapper,
247
- TextField_default[variant],
248
- TextField_default[status],
224
+ "tf-wrapper",
225
+ variant,
226
+ status,
249
227
  className ?? ""
250
228
  ].filter(Boolean).join(" ");
251
229
  return /* @__PURE__ */ jsxs6("div", { className: wrapperClass, "data-disabled": disabled || void 0, children: [
@@ -253,13 +231,13 @@ var TextField = forwardRef(
253
231
  "input",
254
232
  {
255
233
  ref,
256
- className: TextField_default.input,
234
+ className: "tf-input",
257
235
  disabled,
258
236
  ...inputProps
259
237
  }
260
238
  ),
261
- status === "success" && /* @__PURE__ */ jsx6("span", { className: [TextField_default.iconSlot, TextField_default.iconSuccess].join(" "), children: /* @__PURE__ */ jsx6(SuccessIcon, {}) }),
262
- status === "fail" && /* @__PURE__ */ jsx6("span", { className: [TextField_default.iconSlot, TextField_default.iconFail].join(" "), children: /* @__PURE__ */ jsx6(FailIcon, {}) })
239
+ status === "success" && /* @__PURE__ */ jsx6("span", { className: "iconSlot iconSuccess", children: /* @__PURE__ */ jsx6(SuccessIcon, {}) }),
240
+ status === "fail" && /* @__PURE__ */ jsx6("span", { className: "iconSlot iconFail", children: /* @__PURE__ */ jsx6(FailIcon, {}) })
263
241
  ] });
264
242
  }
265
243
  );
@@ -267,11 +245,6 @@ TextField.displayName = "TextField";
267
245
 
268
246
  // primitives/SearchField/SearchField.tsx
269
247
  import { forwardRef as forwardRef2, useRef, useState as useState2, useCallback } from "react";
270
-
271
- // primitives/SearchField/SearchField.module.css
272
- var SearchField_default = {};
273
-
274
- // primitives/SearchField/SearchField.tsx
275
248
  import { jsx as jsx7, jsxs as jsxs7 } from "react/jsx-runtime";
276
249
  var SearchIcon = () => /* @__PURE__ */ jsxs7("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg", "aria-hidden": "true", children: [
277
250
  /* @__PURE__ */ jsx7("circle", { cx: "6.5", cy: "6.5", r: "4", stroke: "currentColor", strokeWidth: "1.25" }),
@@ -336,8 +309,8 @@ var SearchField = forwardRef2(
336
309
  const showSuccessIcon = status === "success" && hasValue && !disabled;
337
310
  const showClearButton = hasValue && !disabled;
338
311
  const wrapperClass = [
339
- SearchField_default.wrapper,
340
- SearchField_default[status],
312
+ "sf-wrapper",
313
+ status,
341
314
  className ?? ""
342
315
  ].filter(Boolean).join(" ");
343
316
  return /* @__PURE__ */ jsxs7(
@@ -346,12 +319,12 @@ var SearchField = forwardRef2(
346
319
  className: wrapperClass,
347
320
  "data-disabled": disabled || void 0,
348
321
  children: [
349
- /* @__PURE__ */ jsx7("span", { className: SearchField_default.iconSlot, children: /* @__PURE__ */ jsx7(SearchIcon, {}) }),
322
+ /* @__PURE__ */ jsx7("span", { className: "iconSlot", children: /* @__PURE__ */ jsx7(SearchIcon, {}) }),
350
323
  /* @__PURE__ */ jsx7(
351
324
  "input",
352
325
  {
353
326
  ref: setRef,
354
- className: SearchField_default.input,
327
+ className: "sf-input",
355
328
  disabled,
356
329
  value,
357
330
  defaultValue,
@@ -359,13 +332,13 @@ var SearchField = forwardRef2(
359
332
  ...inputProps
360
333
  }
361
334
  ),
362
- showSuccessIcon && /* @__PURE__ */ jsx7("span", { className: [SearchField_default.iconSlot, SearchField_default.iconSuccess].join(" "), children: /* @__PURE__ */ jsx7(SuccessIcon2, {}) }),
363
- showFailIcon && /* @__PURE__ */ jsx7("span", { className: [SearchField_default.iconSlot, SearchField_default.iconFail].join(" "), children: /* @__PURE__ */ jsx7(FailIcon2, {}) }),
335
+ showSuccessIcon && /* @__PURE__ */ jsx7("span", { className: "iconSlot iconSuccess", children: /* @__PURE__ */ jsx7(SuccessIcon2, {}) }),
336
+ showFailIcon && /* @__PURE__ */ jsx7("span", { className: "iconSlot iconFail", children: /* @__PURE__ */ jsx7(FailIcon2, {}) }),
364
337
  showClearButton && /* @__PURE__ */ jsx7(
365
338
  "button",
366
339
  {
367
340
  type: "button",
368
- className: SearchField_default.clearButton,
341
+ className: "clearButton",
369
342
  onClick: handleClear,
370
343
  "aria-label": "Clear search",
371
344
  tabIndex: -1,
@@ -381,11 +354,6 @@ SearchField.displayName = "SearchField";
381
354
 
382
355
  // primitives/Breadcrumb/Breadcrumb.tsx
383
356
  import { useState as useState3 } from "react";
384
-
385
- // primitives/Breadcrumb/Breadcrumb.module.css
386
- var Breadcrumb_default = {};
387
-
388
- // primitives/Breadcrumb/Breadcrumb.tsx
389
357
  import { Fragment, jsx as jsx8, jsxs as jsxs8 } from "react/jsx-runtime";
390
358
  var ChevronRightIcon = () => /* @__PURE__ */ jsx8(
391
359
  "svg",
@@ -410,8 +378,8 @@ var ChevronRightIcon = () => /* @__PURE__ */ jsx8(
410
378
  );
411
379
  function BreadcrumbLink({ item }) {
412
380
  return /* @__PURE__ */ jsxs8(Fragment, { children: [
413
- /* @__PURE__ */ jsx8("a", { href: item.href, onClick: item.onClick, className: Breadcrumb_default.link, children: item.label }),
414
- /* @__PURE__ */ jsx8("span", { className: Breadcrumb_default.separator, "aria-hidden": "true", children: /* @__PURE__ */ jsx8(ChevronRightIcon, {}) })
381
+ /* @__PURE__ */ jsx8("a", { href: item.href, onClick: item.onClick, className: "bc-link", children: item.label }),
382
+ /* @__PURE__ */ jsx8("span", { className: "bc-separator", "aria-hidden": "true", children: /* @__PURE__ */ jsx8(ChevronRightIcon, {}) })
415
383
  ] });
416
384
  }
417
385
  function Breadcrumb({
@@ -424,15 +392,15 @@ function Breadcrumb({
424
392
  const [expanded, setExpanded] = useState3(false);
425
393
  const truncatable = collapsible && items.length > 3;
426
394
  const listClass = [
427
- Breadcrumb_default.list,
428
- Breadcrumb_default[size],
429
- truncatable ? Breadcrumb_default.collapsible : "",
430
- truncatable && expanded ? Breadcrumb_default.expanded : ""
395
+ "bc-list",
396
+ size,
397
+ truncatable ? "collapsible" : "",
398
+ truncatable && expanded ? "expanded" : ""
431
399
  ].filter(Boolean).join(" ");
432
400
  if (!truncatable) {
433
401
  return /* @__PURE__ */ jsx8("nav", { "aria-label": "Breadcrumb", className, ...navProps, children: /* @__PURE__ */ jsx8("ol", { className: listClass, children: items.map((item, index) => {
434
402
  const isLast = index === items.length - 1;
435
- return /* @__PURE__ */ jsx8("li", { className: Breadcrumb_default.item, children: isLast ? /* @__PURE__ */ jsx8("span", { className: Breadcrumb_default.current, "aria-current": "page", children: item.label }) : /* @__PURE__ */ jsx8(BreadcrumbLink, { item }) }, index);
403
+ return /* @__PURE__ */ jsx8("li", { className: "bc-item", children: isLast ? /* @__PURE__ */ jsx8("span", { className: "bc-current", "aria-current": "page", children: item.label }) : /* @__PURE__ */ jsx8(BreadcrumbLink, { item }) }, index);
436
404
  }) }) });
437
405
  }
438
406
  const firstItem = items[0];
@@ -440,32 +408,27 @@ function Breadcrumb({
440
408
  const parentItem = items[items.length - 2];
441
409
  const currentItem = items[items.length - 1];
442
410
  return /* @__PURE__ */ jsx8("nav", { "aria-label": "Breadcrumb", className, ...navProps, children: /* @__PURE__ */ jsxs8("ol", { className: listClass, children: [
443
- /* @__PURE__ */ jsx8("li", { className: Breadcrumb_default.item, children: /* @__PURE__ */ jsx8(BreadcrumbLink, { item: firstItem }) }),
444
- /* @__PURE__ */ jsxs8("li", { className: Breadcrumb_default.ellipsisItem, "aria-hidden": expanded, children: [
411
+ /* @__PURE__ */ jsx8("li", { className: "bc-item", children: /* @__PURE__ */ jsx8(BreadcrumbLink, { item: firstItem }) }),
412
+ /* @__PURE__ */ jsxs8("li", { className: "bc-ellipsisItem", "aria-hidden": expanded, children: [
445
413
  /* @__PURE__ */ jsx8(
446
414
  "button",
447
415
  {
448
- className: Breadcrumb_default.ellipsisButton,
416
+ className: "bc-ellipsisButton",
449
417
  onClick: () => setExpanded(true),
450
418
  "aria-label": "Show all breadcrumb items",
451
419
  children: "\u2026"
452
420
  }
453
421
  ),
454
- /* @__PURE__ */ jsx8("span", { className: Breadcrumb_default.separator, "aria-hidden": "true", children: /* @__PURE__ */ jsx8(ChevronRightIcon, {}) })
422
+ /* @__PURE__ */ jsx8("span", { className: "bc-separator", "aria-hidden": "true", children: /* @__PURE__ */ jsx8(ChevronRightIcon, {}) })
455
423
  ] }),
456
- middleItems.map((item, index) => /* @__PURE__ */ jsx8("li", { className: Breadcrumb_default.middleItem, children: /* @__PURE__ */ jsx8(BreadcrumbLink, { item }) }, `m-${index}`)),
457
- /* @__PURE__ */ jsx8("li", { className: Breadcrumb_default.item, children: /* @__PURE__ */ jsx8(BreadcrumbLink, { item: parentItem }) }),
458
- /* @__PURE__ */ jsx8("li", { className: Breadcrumb_default.item, children: /* @__PURE__ */ jsx8("span", { className: Breadcrumb_default.current, "aria-current": "page", children: currentItem.label }) })
424
+ middleItems.map((item, index) => /* @__PURE__ */ jsx8("li", { className: "bc-middleItem", children: /* @__PURE__ */ jsx8(BreadcrumbLink, { item }) }, `m-${index}`)),
425
+ /* @__PURE__ */ jsx8("li", { className: "bc-item", children: /* @__PURE__ */ jsx8(BreadcrumbLink, { item: parentItem }) }),
426
+ /* @__PURE__ */ jsx8("li", { className: "bc-item", children: /* @__PURE__ */ jsx8("span", { className: "bc-current", "aria-current": "page", children: currentItem.label }) })
459
427
  ] }) });
460
428
  }
461
429
 
462
430
  // primitives/ChipDropdown/ChipDropdown.tsx
463
431
  import { useEffect, useRef as useRef2, useState as useState4 } from "react";
464
-
465
- // primitives/ChipDropdown/ChipDropdown.module.css
466
- var ChipDropdown_default = {};
467
-
468
- // primitives/ChipDropdown/ChipDropdown.tsx
469
432
  import { jsx as jsx9, jsxs as jsxs9 } from "react/jsx-runtime";
470
433
  var ChevronDownIcon = () => /* @__PURE__ */ jsx9(
471
434
  "svg",
@@ -537,16 +500,16 @@ var ChipDropdown = ({
537
500
  return () => document.removeEventListener("mousedown", handleClickOutside);
538
501
  }, [open]);
539
502
  const triggerClassNames = [
540
- ChipDropdown_default.trigger,
541
- ChipDropdown_default[size],
542
- isSelected ? ChipDropdown_default.selected : "",
543
- open ? ChipDropdown_default.expand : "",
503
+ "cd-trigger",
504
+ size,
505
+ isSelected ? "selected" : "",
506
+ open ? "expand" : "",
544
507
  className ?? ""
545
508
  ].filter(Boolean).join(" ");
546
509
  const handleKeyDown = (e) => {
547
510
  if (e.key === "Escape") setOpen(false);
548
511
  };
549
- return /* @__PURE__ */ jsxs9("div", { ref: wrapperRef, className: ChipDropdown_default.wrapper, children: [
512
+ return /* @__PURE__ */ jsxs9("div", { ref: wrapperRef, className: "cd-wrapper", children: [
550
513
  /* @__PURE__ */ jsxs9(
551
514
  "button",
552
515
  {
@@ -559,13 +522,13 @@ var ChipDropdown = ({
559
522
  onKeyDown: handleKeyDown,
560
523
  ...props,
561
524
  children: [
562
- icon && /* @__PURE__ */ jsx9("span", { className: ChipDropdown_default.icon, children: icon }),
563
- /* @__PURE__ */ jsx9("span", { className: ChipDropdown_default.label, children: displayLabel }),
564
- tag && /* @__PURE__ */ jsx9("span", { className: ChipDropdown_default.tag, children: tag }),
525
+ icon && /* @__PURE__ */ jsx9("span", { className: "cd-icon", children: icon }),
526
+ /* @__PURE__ */ jsx9("span", { className: "cd-label", children: displayLabel }),
527
+ tag && /* @__PURE__ */ jsx9("span", { className: "cd-tag", children: tag }),
565
528
  /* @__PURE__ */ jsx9(
566
529
  "span",
567
530
  {
568
- className: [ChipDropdown_default.chevron, open ? ChipDropdown_default.chevronOpen : ""].filter(Boolean).join(" "),
531
+ className: ["cd-chevron", open ? "chevronOpen" : ""].filter(Boolean).join(" "),
569
532
  "aria-hidden": "true",
570
533
  children: /* @__PURE__ */ jsx9(ChevronDownIcon, {})
571
534
  }
@@ -578,7 +541,7 @@ var ChipDropdown = ({
578
541
  {
579
542
  role: "listbox",
580
543
  "aria-label": label,
581
- className: ChipDropdown_default.list,
544
+ className: "cd-list",
582
545
  children: options.map((option) => {
583
546
  const isActive = option.value === value;
584
547
  return /* @__PURE__ */ jsxs9(
@@ -587,16 +550,16 @@ var ChipDropdown = ({
587
550
  role: "option",
588
551
  "aria-selected": isActive,
589
552
  className: [
590
- ChipDropdown_default.item,
591
- isActive ? ChipDropdown_default.itemSelected : ""
553
+ "cd-item",
554
+ isActive ? "itemSelected" : ""
592
555
  ].filter(Boolean).join(" "),
593
556
  onClick: () => {
594
557
  onChange?.(option.value);
595
558
  setOpen(false);
596
559
  },
597
560
  children: [
598
- /* @__PURE__ */ jsx9("span", { className: ChipDropdown_default.itemLabel, children: option.label }),
599
- isActive && /* @__PURE__ */ jsx9("span", { className: ChipDropdown_default.itemCheck, children: /* @__PURE__ */ jsx9(CheckIcon, {}) })
561
+ /* @__PURE__ */ jsx9("span", { className: "cd-itemLabel", children: option.label }),
562
+ isActive && /* @__PURE__ */ jsx9("span", { className: "cd-itemCheck", children: /* @__PURE__ */ jsx9(CheckIcon, {}) })
600
563
  ]
601
564
  },
602
565
  option.value
@@ -607,32 +570,8 @@ var ChipDropdown = ({
607
570
  ] });
608
571
  };
609
572
 
610
- // components/Card/CardPrimaryVariant.module.css
611
- var CardPrimaryVariant_default = {};
612
-
613
573
  // components/Card/CardPrimaryVariant.tsx
614
574
  import { jsx as jsx10, jsxs as jsxs10 } from "react/jsx-runtime";
615
- var ArrowRightIcon = () => /* @__PURE__ */ jsx10(
616
- "svg",
617
- {
618
- "aria-hidden": "true",
619
- fill: "none",
620
- height: "16",
621
- viewBox: "0 0 16 16",
622
- width: "16",
623
- xmlns: "http://www.w3.org/2000/svg",
624
- children: /* @__PURE__ */ jsx10(
625
- "path",
626
- {
627
- d: "M3 8h10M9 4l4 4-4 4",
628
- stroke: "currentColor",
629
- strokeLinecap: "round",
630
- strokeLinejoin: "round",
631
- strokeWidth: "1.5"
632
- }
633
- )
634
- }
635
- );
636
575
  var CardPrimaryVariant = ({
637
576
  colorScheme = "light",
638
577
  title,
@@ -651,64 +590,36 @@ var CardPrimaryVariant = ({
651
590
  "div",
652
591
  {
653
592
  className: [
654
- CardPrimaryVariant_default.card,
655
- CardPrimaryVariant_default[`style--${colorScheme}`],
593
+ "card-primary",
594
+ `style--${colorScheme}`,
656
595
  className ?? ""
657
596
  ].filter(Boolean).join(" "),
658
597
  ...props,
659
598
  children: [
660
- colorScheme === "image" && image && /* @__PURE__ */ jsxs10("div", { "aria-hidden": "true", className: CardPrimaryVariant_default.imageOverlay, children: [
661
- /* @__PURE__ */ jsx10("img", { alt: "", className: CardPrimaryVariant_default.overlayImg, src: image }),
662
- /* @__PURE__ */ jsx10("div", { className: CardPrimaryVariant_default.gradient })
599
+ colorScheme === "image" && image && /* @__PURE__ */ jsxs10("div", { "aria-hidden": "true", className: "cp-imageOverlay", children: [
600
+ /* @__PURE__ */ jsx10("img", { alt: "", className: "cp-overlayImg", src: image }),
601
+ /* @__PURE__ */ jsx10("div", { className: "cp-gradient" })
663
602
  ] }),
664
- /* @__PURE__ */ jsxs10("div", { className: CardPrimaryVariant_default.content, children: [
665
- /* @__PURE__ */ jsx10("p", { className: [CardPrimaryVariant_default.title, isInverse ? CardPrimaryVariant_default.textInverse : CardPrimaryVariant_default.textDefault].join(" "), children: title }),
666
- /* @__PURE__ */ jsx10("p", { className: [CardPrimaryVariant_default.description, isInverse ? CardPrimaryVariant_default.textInverse : CardPrimaryVariant_default.textDefault].join(" "), children: description }),
667
- showLink && /* @__PURE__ */ jsxs10(
668
- "button",
603
+ /* @__PURE__ */ jsxs10("div", { className: "cp-content", children: [
604
+ /* @__PURE__ */ jsx10("p", { className: ["cp-title", isInverse ? "textInverse" : "textDefault"].join(" "), children: title }),
605
+ /* @__PURE__ */ jsx10("p", { className: ["cp-description", isInverse ? "textInverse" : "textDefault"].join(" "), children: description }),
606
+ showLink && /* @__PURE__ */ jsx10(
607
+ Link,
669
608
  {
670
- className: [CardPrimaryVariant_default.link, isInverse ? CardPrimaryVariant_default.linkInverse : CardPrimaryVariant_default.linkCoral].join(" "),
671
- onClick: onLinkClick,
672
- type: "button",
673
- children: [
674
- /* @__PURE__ */ jsx10("span", { children: linkText }),
675
- /* @__PURE__ */ jsx10(ArrowRightIcon, {})
676
- ]
609
+ colorScheme: isInverse ? "white" : "coral",
610
+ label: linkText,
611
+ onClick: onLinkClick
677
612
  }
678
613
  )
679
614
  ] }),
680
- colorScheme !== "image" && /* @__PURE__ */ jsx10("div", { className: CardPrimaryVariant_default.imageSection, children: image && /* @__PURE__ */ jsx10("img", { alt: imageAlt, className: CardPrimaryVariant_default.image, src: image }) })
615
+ colorScheme !== "image" && image && /* @__PURE__ */ jsx10("div", { className: "cp-imageSection", children: /* @__PURE__ */ jsx10("img", { alt: imageAlt, className: "cp-image", src: image }) })
681
616
  ]
682
617
  }
683
618
  );
684
619
  };
685
620
 
686
- // components/Card/CardSecondaryVariant.module.css
687
- var CardSecondaryVariant_default = {};
688
-
689
621
  // components/Card/CardSecondaryVariant.tsx
690
622
  import { jsx as jsx11, jsxs as jsxs11 } from "react/jsx-runtime";
691
- var ArrowRightIcon2 = () => /* @__PURE__ */ jsx11(
692
- "svg",
693
- {
694
- "aria-hidden": "true",
695
- fill: "none",
696
- height: "16",
697
- viewBox: "0 0 16 16",
698
- width: "16",
699
- xmlns: "http://www.w3.org/2000/svg",
700
- children: /* @__PURE__ */ jsx11(
701
- "path",
702
- {
703
- d: "M3 8h10M9 4l4 4-4 4",
704
- stroke: "currentColor",
705
- strokeLinecap: "round",
706
- strokeLinejoin: "round",
707
- strokeWidth: "1.5"
708
- }
709
- )
710
- }
711
- );
712
623
  var CardSecondaryVariant = ({
713
624
  title,
714
625
  description,
@@ -724,22 +635,18 @@ var CardSecondaryVariant = ({
724
635
  return /* @__PURE__ */ jsxs11(
725
636
  "div",
726
637
  {
727
- className: [CardSecondaryVariant_default.card, className ?? ""].filter(Boolean).join(" "),
638
+ className: ["card-secondary", className ?? ""].filter(Boolean).join(" "),
728
639
  ...props,
729
640
  children: [
730
- showIcon && icon && /* @__PURE__ */ jsx11("span", { className: CardSecondaryVariant_default.icon, children: icon }),
731
- /* @__PURE__ */ jsx11("p", { className: CardSecondaryVariant_default.title, children: title }),
732
- /* @__PURE__ */ jsx11("p", { className: CardSecondaryVariant_default.description, children: description }),
733
- showLink && /* @__PURE__ */ jsxs11(
734
- "button",
641
+ showIcon && icon && /* @__PURE__ */ jsx11("span", { className: "cs-icon", children: icon }),
642
+ /* @__PURE__ */ jsx11("p", { className: "cs-title", children: title }),
643
+ /* @__PURE__ */ jsx11("p", { className: "cs-description", children: description }),
644
+ showLink && /* @__PURE__ */ jsx11(
645
+ Link,
735
646
  {
736
- className: CardSecondaryVariant_default.link,
737
- onClick: onLinkClick,
738
- type: "button",
739
- children: [
740
- /* @__PURE__ */ jsx11("span", { children: linkText }),
741
- /* @__PURE__ */ jsx11(ArrowRightIcon2, {})
742
- ]
647
+ colorScheme: "coral",
648
+ label: linkText,
649
+ onClick: onLinkClick
743
650
  }
744
651
  )
745
652
  ]
@@ -747,9 +654,6 @@ var CardSecondaryVariant = ({
747
654
  );
748
655
  };
749
656
 
750
- // components/Card/CardThumbnailVariant.module.css
751
- var CardThumbnailVariant_default = {};
752
-
753
657
  // components/Card/CardThumbnailVariant.tsx
754
658
  import { jsx as jsx12, jsxs as jsxs12 } from "react/jsx-runtime";
755
659
  var LinkIcon = () => /* @__PURE__ */ jsxs12(
@@ -820,30 +724,30 @@ var CardThumbnailVariant = ({
820
724
  return /* @__PURE__ */ jsxs12(
821
725
  "div",
822
726
  {
823
- className: [CardThumbnailVariant_default.card, className ?? ""].filter(Boolean).join(" "),
727
+ className: ["card-thumbnail", className ?? ""].filter(Boolean).join(" "),
824
728
  ...props,
825
729
  children: [
826
- /* @__PURE__ */ jsxs12("div", { className: CardThumbnailVariant_default.thumbnailWrapper, children: [
827
- /* @__PURE__ */ jsx12("img", { alt: thumbnailAlt, className: CardThumbnailVariant_default.thumbnailImage, src: thumbnail }),
828
- isVideo && /* @__PURE__ */ jsx12("span", { "aria-label": "Play video", className: CardThumbnailVariant_default.playButton, children: /* @__PURE__ */ jsx12(PlayIcon, {}) }),
829
- !isVideo && avatar && /* @__PURE__ */ jsx12("img", { alt: avatarAlt, className: CardThumbnailVariant_default.avatar, src: avatar })
730
+ /* @__PURE__ */ jsxs12("div", { className: "ct-thumbnailWrapper", children: [
731
+ /* @__PURE__ */ jsx12("img", { alt: thumbnailAlt, className: "ct-thumbnailImage", src: thumbnail }),
732
+ isVideo && /* @__PURE__ */ jsx12("span", { "aria-label": "Play video", className: "ct-playButton", children: /* @__PURE__ */ jsx12(PlayIcon, {}) }),
733
+ !isVideo && avatar && /* @__PURE__ */ jsx12("img", { alt: avatarAlt, className: "ct-avatar", src: avatar })
830
734
  ] }),
831
- /* @__PURE__ */ jsxs12("div", { className: CardThumbnailVariant_default.content, children: [
832
- /* @__PURE__ */ jsxs12("div", { className: CardThumbnailVariant_default.metaRow, children: [
833
- !hideTags && /* @__PURE__ */ jsx12("div", { className: CardThumbnailVariant_default.tagsList, children: tags.map((tag, i) => /* @__PURE__ */ jsx12(Tag, { icon: tag.icon, label: tag.label, size: "md", variant: "fill" }, i)) }),
735
+ /* @__PURE__ */ jsxs12("div", { className: "ct-content", children: [
736
+ /* @__PURE__ */ jsxs12("div", { className: "ct-metaRow", children: [
737
+ !hideTags && /* @__PURE__ */ jsx12("div", { className: "ct-tagsList", children: tags.map((tag, i) => /* @__PURE__ */ jsx12(Tag, { icon: tag.icon, label: tag.label, size: "md", variant: "fill" }, i)) }),
834
738
  showCopyLink && /* @__PURE__ */ jsx12(
835
739
  "button",
836
740
  {
837
741
  "aria-label": "Copy link",
838
- className: CardThumbnailVariant_default.copyLink,
742
+ className: "ct-copyLink",
839
743
  onClick: onCopyLink,
840
744
  type: "button",
841
745
  children: /* @__PURE__ */ jsx12(LinkIcon, {})
842
746
  }
843
747
  )
844
748
  ] }),
845
- /* @__PURE__ */ jsx12("p", { className: CardThumbnailVariant_default.title, children: title }),
846
- /* @__PURE__ */ jsx12("p", { className: CardThumbnailVariant_default.summary, children: summary })
749
+ /* @__PURE__ */ jsx12("p", { className: "ct-title", children: title }),
750
+ /* @__PURE__ */ jsx12("p", { className: "ct-summary", children: summary })
847
751
  ] })
848
752
  ]
849
753
  }
@@ -862,9 +766,6 @@ var Card = (props) => {
862
766
  return /* @__PURE__ */ jsx13(CardThumbnailVariant, { ...props });
863
767
  };
864
768
 
865
- // primitives/Pagination/Pagination.module.css
866
- var Pagination_default = {};
867
-
868
769
  // primitives/Pagination/Pagination.tsx
869
770
  import { jsx as jsx14, jsxs as jsxs13 } from "react/jsx-runtime";
870
771
  var ChevronLeft = () => /* @__PURE__ */ jsx14("svg", { width: "16", height: "16", viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg", "aria-hidden": "true", children: /* @__PURE__ */ jsx14("path", { d: "M10 12L6 8L10 4", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) });
@@ -893,17 +794,17 @@ var Pagination = ({
893
794
  return /* @__PURE__ */ jsxs13(
894
795
  "nav",
895
796
  {
896
- className: [Pagination_default.pagination, className ?? ""].filter(Boolean).join(" "),
797
+ className: ["pagination", className ?? ""].filter(Boolean).join(" "),
897
798
  "aria-label": "Pagination navigation",
898
799
  children: [
899
800
  /* @__PURE__ */ jsx14(
900
801
  "button",
901
802
  {
902
- className: [Pagination_default.navButton, isPrevDisabled ? Pagination_default.navButtonDisabled : ""].filter(Boolean).join(" "),
803
+ className: ["navButton", isPrevDisabled ? "navButtonDisabled" : ""].filter(Boolean).join(" "),
903
804
  onClick: () => onPageChange(currentPage - 1),
904
805
  disabled: isPrevDisabled,
905
806
  "aria-label": "Previous page",
906
- children: /* @__PURE__ */ jsx14("span", { className: Pagination_default.navIcon, children: /* @__PURE__ */ jsx14(ChevronLeft, {}) })
807
+ children: /* @__PURE__ */ jsx14("span", { className: "navIcon", children: /* @__PURE__ */ jsx14(ChevronLeft, {}) })
907
808
  }
908
809
  ),
909
810
  items.map((item, index) => {
@@ -911,7 +812,7 @@ var Pagination = ({
911
812
  return /* @__PURE__ */ jsx14(
912
813
  "span",
913
814
  {
914
- className: Pagination_default.ellipsis,
815
+ className: "ellipsis",
915
816
  "aria-hidden": "true",
916
817
  children: "\u2026"
917
818
  },
@@ -922,7 +823,7 @@ var Pagination = ({
922
823
  return /* @__PURE__ */ jsx14(
923
824
  "button",
924
825
  {
925
- className: [Pagination_default.pageButton, isSelected ? Pagination_default.pageButtonSelected : ""].filter(Boolean).join(" "),
826
+ className: ["pageButton", isSelected ? "pageButtonSelected" : ""].filter(Boolean).join(" "),
926
827
  onClick: () => {
927
828
  if (!isSelected) onPageChange(item);
928
829
  },
@@ -936,17 +837,59 @@ var Pagination = ({
936
837
  /* @__PURE__ */ jsx14(
937
838
  "button",
938
839
  {
939
- className: [Pagination_default.navButton, isNextDisabled ? Pagination_default.navButtonDisabled : ""].filter(Boolean).join(" "),
840
+ className: ["navButton", isNextDisabled ? "navButtonDisabled" : ""].filter(Boolean).join(" "),
940
841
  onClick: () => onPageChange(currentPage + 1),
941
842
  disabled: isNextDisabled,
942
843
  "aria-label": "Next page",
943
- children: /* @__PURE__ */ jsx14("span", { className: Pagination_default.navIcon, children: /* @__PURE__ */ jsx14(ChevronRight, {}) })
844
+ children: /* @__PURE__ */ jsx14("span", { className: "navIcon", children: /* @__PURE__ */ jsx14(ChevronRight, {}) })
944
845
  }
945
846
  )
946
847
  ]
947
848
  }
948
849
  );
949
850
  };
851
+
852
+ // templates/FeatureCards/FeatureCards.tsx
853
+ import { jsx as jsx15, jsxs as jsxs14 } from "react/jsx-runtime";
854
+ var FeatureCards = ({
855
+ sectionTitle,
856
+ sectionDescription,
857
+ showLink = false,
858
+ linkText = "Learn more",
859
+ onLinkClick,
860
+ cardColorScheme = "image",
861
+ cards
862
+ }) => {
863
+ return /* @__PURE__ */ jsx15("section", { className: "fc-section", children: /* @__PURE__ */ jsxs14("div", { className: "fc-container", children: [
864
+ /* @__PURE__ */ jsxs14("div", { className: "fc-header", children: [
865
+ /* @__PURE__ */ jsx15("h2", { className: "fc-sectionTitle", children: sectionTitle }),
866
+ sectionDescription && /* @__PURE__ */ jsx15("p", { className: "fc-sectionDescription", children: sectionDescription }),
867
+ showLink && /* @__PURE__ */ jsx15(
868
+ Link,
869
+ {
870
+ colorScheme: "coral",
871
+ label: linkText,
872
+ onClick: onLinkClick
873
+ }
874
+ )
875
+ ] }),
876
+ /* @__PURE__ */ jsx15("div", { className: "fc-grid", children: cards.map((card, index) => /* @__PURE__ */ jsx15(
877
+ Card,
878
+ {
879
+ variant: "primary",
880
+ colorScheme: card.colorScheme ?? cardColorScheme,
881
+ title: card.title,
882
+ description: card.description,
883
+ image: card.image,
884
+ imageAlt: card.imageAlt,
885
+ showLink: card.showLink,
886
+ linkText: card.linkText,
887
+ onLinkClick: card.onLinkClick
888
+ },
889
+ index
890
+ )) })
891
+ ] }) });
892
+ };
950
893
  export {
951
894
  Accordion,
952
895
  Breadcrumb,
@@ -954,6 +897,7 @@ export {
954
897
  Card,
955
898
  Chip,
956
899
  ChipDropdown,
900
+ FeatureCards,
957
901
  Link,
958
902
  Pagination,
959
903
  SearchField,