jenosize-ui 0.2.0 → 0.2.1

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.
Files changed (180) hide show
  1. package/README.md +2 -2
  2. package/dist/{PaymentInput-CKPIPNWH.d.ts → PaymentInput-Dn5WVQVy.d.ts} +4 -0
  3. package/dist/{Select-CVbEQ2Ep.d.ts → Select-Dt5ARIH8.d.ts} +4 -0
  4. package/dist/{TagInput-CTJYOB4J.d.ts → TagInput-BaBeve6L.d.ts} +4 -0
  5. package/dist/area-chart.d.ts +3 -2
  6. package/dist/area-chart.js +6 -5
  7. package/dist/avatar.d.ts +5 -0
  8. package/dist/avatar.js +9 -8
  9. package/dist/badge.d.ts +4 -0
  10. package/dist/badge.js +5 -4
  11. package/dist/bar-chart.d.ts +3 -2
  12. package/dist/bar-chart.js +6 -5
  13. package/dist/breadcrumb.d.ts +4 -0
  14. package/dist/breadcrumb.js +4 -2
  15. package/dist/button.d.ts +6 -1
  16. package/dist/button.js +9 -8
  17. package/dist/calendar.d.ts +5 -0
  18. package/dist/calendar.js +15 -13
  19. package/dist/callout.d.ts +6 -6
  20. package/dist/callout.js +11 -9
  21. package/dist/card-D56VxyAe.d.ts +123 -0
  22. package/dist/card.d.ts +3 -51
  23. package/dist/card.js +5 -5
  24. package/dist/checkbox.js +8 -7
  25. package/dist/{chunk-75M43ELV.js → chunk-22M75A3N.js} +75 -45
  26. package/dist/{chunk-A46ED5JQ.js → chunk-33TOK7ES.js} +7 -5
  27. package/dist/{chunk-RNXRZGXN.js → chunk-3H444OJA.js} +5 -3
  28. package/dist/{chunk-DJYWPJZ3.js → chunk-3QXLIZIX.js} +3 -12
  29. package/dist/chunk-3ZEEGXYF.js +8 -0
  30. package/dist/chunk-45Y2ZGNK.js +34 -0
  31. package/dist/{chunk-ILICYNK7.js → chunk-4RBIWI2Q.js} +3 -3
  32. package/dist/{chunk-FIGBJGH2.js → chunk-4VGEJG4M.js} +115 -79
  33. package/dist/{chunk-EX374YWB.js → chunk-54SIZR63.js} +15 -7
  34. package/dist/chunk-5AZKP4KZ.js +49 -0
  35. package/dist/{chunk-NA35YZRD.js → chunk-5DP7W5HX.js} +13 -11
  36. package/dist/{chunk-QKDEQFOQ.js → chunk-5KSD4WKN.js} +13 -4
  37. package/dist/{chunk-RIXEUAPY.js → chunk-5XPMY2LF.js} +5 -5
  38. package/dist/{chunk-6UBYHSBX.js → chunk-5ZEUTSCV.js} +5 -5
  39. package/dist/{chunk-DCGTB7P7.js → chunk-667ZHY3T.js} +111 -39
  40. package/dist/{chunk-MYQ3FD4Y.js → chunk-6B6BWTXC.js} +8 -5
  41. package/dist/{chunk-6HJA7NPL.js → chunk-6H4LNWQ7.js} +3 -3
  42. package/dist/{chunk-JAVNGTOE.js → chunk-6MMBQVRO.js} +58 -43
  43. package/dist/{chunk-JMWYCT63.js → chunk-7GUPNTAH.js} +14 -6
  44. package/dist/{chunk-TBN644IN.js → chunk-7ZM7SNCZ.js} +3 -3
  45. package/dist/{chunk-BD5YKFRA.js → chunk-A323V6AI.js} +5 -3
  46. package/dist/{chunk-AC6ZWKRN.js → chunk-AFYXSZGW.js} +2 -2
  47. package/dist/chunk-AIARANKE.js +33 -0
  48. package/dist/{chunk-54S5CUY6.js → chunk-AIGYMTCU.js} +5 -4
  49. package/dist/{chunk-C6OTOTKI.js → chunk-AZ7DKRBY.js} +5 -5
  50. package/dist/{chunk-QBHQOX23.js → chunk-BBKE4W3B.js} +18 -10
  51. package/dist/{chunk-4BRMM3I5.js → chunk-BFVJHH7S.js} +7 -6
  52. package/dist/{chunk-FFTRB2UU.js → chunk-CFFWYXDW.js} +18 -6
  53. package/dist/{chunk-42FCPC77.js → chunk-CGHYXWTT.js} +10 -4
  54. package/dist/{chunk-VEOYCAJP.js → chunk-CKMWBVRR.js} +27 -7
  55. package/dist/{chunk-GTHJWR3Q.js → chunk-D7EE5GWU.js} +21 -22
  56. package/dist/{chunk-NMERLWT7.js → chunk-E2YZ7IMT.js} +23 -7
  57. package/dist/{chunk-GAFGIT4Q.js → chunk-FFMTYQXE.js} +30 -10
  58. package/dist/{chunk-L53Y7KUV.js → chunk-FH7Z7SGQ.js} +61 -28
  59. package/dist/{chunk-5JRM3OES.js → chunk-FNQJJO63.js} +3 -3
  60. package/dist/{chunk-MD4AR43X.js → chunk-FWRHBMWT.js} +3 -3
  61. package/dist/{chunk-4K6V6NNK.js → chunk-GLKFFA7N.js} +10 -8
  62. package/dist/{chunk-EDOUI2BG.js → chunk-GQRSABRN.js} +4 -4
  63. package/dist/{chunk-BNIWT6CW.js → chunk-GZMDZF2V.js} +7 -6
  64. package/dist/{chunk-HSVBTIP2.js → chunk-HHYEAFCL.js} +70 -27
  65. package/dist/{chunk-P7DH62UY.js → chunk-I6WMNXC7.js} +5 -5
  66. package/dist/{chunk-34J5AANZ.js → chunk-IQNVSQRK.js} +3 -3
  67. package/dist/{chunk-MCUASLZH.js → chunk-KHGW72BM.js} +3 -3
  68. package/dist/{chunk-4R7WDDCW.js → chunk-KZP6B6B3.js} +4 -4
  69. package/dist/{chunk-7HV6EIGZ.js → chunk-LLPWQDF7.js} +3 -3
  70. package/dist/{chunk-FZBZGA3P.js → chunk-LO22VQL5.js} +4 -4
  71. package/dist/{chunk-JXHZHUB3.js → chunk-LQURV7HQ.js} +9 -7
  72. package/dist/{chunk-EDT5J5WK.js → chunk-LYXPJERB.js} +14 -4
  73. package/dist/{chunk-6IUTVDNI.js → chunk-MCQG4H6T.js} +35 -3
  74. package/dist/{chunk-JYBGO6GY.js → chunk-MVG5MABV.js} +11 -8
  75. package/dist/{chunk-PXEJ5RKO.js → chunk-N3RVMBPX.js} +6 -9
  76. package/dist/{chunk-VWGAMOSE.js → chunk-NKG4N6HA.js} +3 -3
  77. package/dist/{chunk-A5WQLN4B.js → chunk-OACWA4TC.js} +14 -52
  78. package/dist/{chunk-LBYCCLVI.js → chunk-OLLD2BZN.js} +9 -9
  79. package/dist/{chunk-T2WAD4QP.js → chunk-POQTE7JI.js} +55 -16
  80. package/dist/{chunk-74HPBSVY.js → chunk-QDKETK7D.js} +4 -4
  81. package/dist/{chunk-VH35QHD4.js → chunk-QHH6AUR3.js} +16 -8
  82. package/dist/chunk-RJTVCA62.js +42 -0
  83. package/dist/{chunk-DTMYD63D.js → chunk-S5TEWPWW.js} +46 -26
  84. package/dist/{chunk-3GT43XPK.js → chunk-SB3DG572.js} +15 -8
  85. package/dist/{chunk-NKDW6C7K.js → chunk-SKRR3ZMP.js} +3 -3
  86. package/dist/{chunk-CTENRS34.js → chunk-T4ZFZTY6.js} +8 -6
  87. package/dist/{chunk-YLEHYDXC.js → chunk-T5574MXM.js} +33 -45
  88. package/dist/{chunk-USL3TDZM.js → chunk-U4WSJAYK.js} +321 -105
  89. package/dist/{chunk-4W6AYGLR.js → chunk-UGKELBNC.js} +55 -39
  90. package/dist/{chunk-M5TVCASC.js → chunk-ULGCGKOE.js} +8 -6
  91. package/dist/{chunk-JUWDRRD6.js → chunk-X2VMIBK5.js} +4 -4
  92. package/dist/{chunk-763VS2FY.js → chunk-YHBI52P2.js} +3 -3
  93. package/dist/chunk-YIHKQ63K.js +13 -0
  94. package/dist/{chunk-3Z3SDKIA.js → chunk-YQYVGWIC.js} +5 -5
  95. package/dist/{chunk-4HKDD3PR.js → chunk-ZHAT2XZ4.js} +91 -57
  96. package/dist/{chunk-CWMFEF6R.js → chunk-ZMFY7WAY.js} +60 -24
  97. package/dist/{chunk-WKWAUU64.js → chunk-ZZSNTCCL.js} +6 -5
  98. package/dist/combobox.d.ts +5 -0
  99. package/dist/combobox.js +12 -11
  100. package/dist/date-input.d.ts +4 -0
  101. package/dist/date-input.js +11 -9
  102. package/dist/date-picker.d.ts +6 -0
  103. package/dist/date-picker.js +23 -21
  104. package/dist/dialog.d.ts +21 -1
  105. package/dist/dialog.js +10 -8
  106. package/dist/drawer.d.ts +11 -1
  107. package/dist/drawer.js +9 -7
  108. package/dist/dropdown-menu.d.ts +12 -0
  109. package/dist/dropdown-menu.js +6 -5
  110. package/dist/dropzone.d.ts +3 -2
  111. package/dist/dropzone.js +13 -12
  112. package/dist/form.d.ts +5 -4
  113. package/dist/form.js +60 -44
  114. package/dist/header-navigation.d.ts +5 -1
  115. package/dist/header-navigation.js +21 -19
  116. package/dist/helper.d.ts +36 -0
  117. package/dist/helper.js +3 -0
  118. package/dist/index.d.ts +13 -11
  119. package/dist/index.js +81 -76
  120. package/dist/indicator.js +4 -4
  121. package/dist/input.d.ts +4 -0
  122. package/dist/input.js +9 -8
  123. package/dist/kanban-board.d.ts +21 -81
  124. package/dist/kanban-board.js +14 -12
  125. package/dist/labels-DPrh0se9.d.ts +627 -0
  126. package/dist/line-chart.d.ts +3 -2
  127. package/dist/line-chart.js +6 -5
  128. package/dist/{nav-DcCyt00p.d.ts → nav-CKKqjBs6.d.ts} +10 -0
  129. package/dist/number-input.d.ts +4 -0
  130. package/dist/number-input.js +9 -8
  131. package/dist/pagination.d.ts +7 -1
  132. package/dist/pagination.js +11 -10
  133. package/dist/payment-input.d.ts +3 -2
  134. package/dist/payment-input.js +9 -8
  135. package/dist/pie-chart.d.ts +7 -3
  136. package/dist/pie-chart.js +6 -5
  137. package/dist/popover.js +9 -7
  138. package/dist/progress-steps.js +2 -2
  139. package/dist/progress.d.ts +21 -1
  140. package/dist/progress.js +3 -2
  141. package/dist/provider.d.ts +212 -0
  142. package/dist/provider.js +7 -0
  143. package/dist/radar-chart.d.ts +7 -3
  144. package/dist/radar-chart.js +6 -5
  145. package/dist/radial-chart.d.ts +7 -3
  146. package/dist/radial-chart.js +6 -5
  147. package/dist/radio.js +8 -7
  148. package/dist/select.d.ts +2 -1
  149. package/dist/select.js +14 -13
  150. package/dist/shared-CxAedkiy.d.ts +68 -0
  151. package/dist/sidebar-navigation.d.ts +28 -7
  152. package/dist/sidebar-navigation.js +15 -13
  153. package/dist/skeleton.js +2 -2
  154. package/dist/styles.css +1 -1
  155. package/dist/switch.js +4 -4
  156. package/dist/table.d.ts +56 -6
  157. package/dist/table.js +36 -34
  158. package/dist/tabs.d.ts +22 -0
  159. package/dist/tabs.js +3 -3
  160. package/dist/tag-input.d.ts +3 -2
  161. package/dist/tag-input.js +12 -11
  162. package/dist/tag.d.ts +4 -0
  163. package/dist/tag.js +3 -2
  164. package/dist/textarea.js +6 -5
  165. package/dist/theme.css +69 -6
  166. package/dist/theme.js +10 -9
  167. package/dist/toast.d.ts +11 -2
  168. package/dist/toast.js +11 -9
  169. package/dist/{tooltip-surface-Dmvb8v5K.d.ts → tooltip-surface-C2I9o2QM.d.ts} +1 -1
  170. package/dist/tooltip.d.ts +2 -2
  171. package/dist/tooltip.js +3 -3
  172. package/dist/tree.d.ts +5 -0
  173. package/dist/tree.js +5 -4
  174. package/dist/{types-6kvYwtRH.d.ts → types-DR9rAEy1.d.ts} +45 -13
  175. package/dist/{use-uploads-ButS4dGe.d.ts → use-uploads-KaPqDklo.d.ts} +9 -0
  176. package/dist/verification-code-input.js +8 -7
  177. package/package.json +12 -1
  178. package/dist/chunk-MFJP5FA7.js +0 -20
  179. package/dist/shared-BNXAdgh2.d.ts +0 -9
  180. package/dist/surface-DFyDnrTJ.d.ts +0 -34
@@ -1,19 +1,19 @@
1
- import { seriesColorClass, useSeriesColors } from './chunk-75M43ELV.js';
1
+ import { seriesColor, useSeriesColors, paletteLength } from './chunk-22M75A3N.js';
2
2
  import * as React from 'react';
3
3
 
4
4
  function usePolarData(component, data, palette) {
5
- const resolve = React.useCallback((i) => seriesColorClass(data[i]?.color, i, palette), [data, palette]);
6
- const colors = useSeriesColors(component, data.length, resolve);
5
+ const resolve = React.useCallback((i) => seriesColor(data[i]?.color, i, palette), [data, palette]);
6
+ const colors = useSeriesColors(component, data.length, resolve, paletteLength(palette));
7
7
  return React.useMemo(() => {
8
8
  const rows = [];
9
9
  const legendItems = [];
10
10
  const colorMap = {};
11
11
  const labelMap = {};
12
12
  for (const [i, datum] of data.entries()) {
13
- const className = colors[i] ?? "";
14
- rows.push({ name: datum.label, value: datum.value, className });
15
- legendItems.push({ label: datum.label, colorClass: className });
16
- colorMap[datum.label] = className;
13
+ const color = colors[i] ?? "";
14
+ rows.push({ name: datum.label, value: datum.value, style: { color } });
15
+ legendItems.push({ label: datum.label, color });
16
+ colorMap[datum.label] = color;
17
17
  labelMap[datum.label] = datum.label;
18
18
  }
19
19
  return { rows, legendItems, colorMap, labelMap };
@@ -29,5 +29,5 @@ function resolveMax(max, values) {
29
29
  }
30
30
 
31
31
  export { resolveMax, usePolarData };
32
- //# sourceMappingURL=chunk-LBYCCLVI.js.map
33
- //# sourceMappingURL=chunk-LBYCCLVI.js.map
32
+ //# sourceMappingURL=chunk-OLLD2BZN.js.map
33
+ //# sourceMappingURL=chunk-OLLD2BZN.js.map
@@ -1,12 +1,13 @@
1
1
  import { DRAG_GHOST, DROP_LINE, DROP_LINE_Y, dragGhostProps, ghostPosition } from './chunk-5ZPUAGOP.js';
2
2
  import { useAutoScroll, useDrag } from './chunk-P6CON2R2.js';
3
- import { Skeleton } from './chunk-7HV6EIGZ.js';
3
+ import { Skeleton } from './chunk-LLPWQDF7.js';
4
4
  import { useDebounced } from './chunk-F6NLE6XJ.js';
5
- import { Slot } from './chunk-52IFGFTL.js';
6
5
  import { useIsomorphicLayoutEffect } from './chunk-EDSK6FEH.js';
6
+ import { Slot } from './chunk-52IFGFTL.js';
7
7
  import { LoaderCircleIcon, CircleAlertIcon, ChevronRightIcon, GripVerticalIcon, CheckIcon, MinusIcon } from './chunk-BLIZ3CL3.js';
8
- import { devWarn, warnNonNegativeInt, warnNeedsName } from './chunk-QDYE5LVT.js';
9
8
  import { cn } from './chunk-ZSNJ6UA3.js';
9
+ import { useLabels } from './chunk-RJTVCA62.js';
10
+ import { devWarn, warnNonNegativeInt, warnNeedsName } from './chunk-QDYE5LVT.js';
10
11
  import * as React from 'react';
11
12
  import { mergeProps } from '@base-ui/react/merge-props';
12
13
  import { useRender } from '@base-ui/react/use-render';
@@ -774,6 +775,28 @@ function treeKeydown(event, ctx) {
774
775
  }
775
776
  }
776
777
  }
778
+
779
+ // src/components/tree/labels.ts
780
+ var TREE_LABELS = {
781
+ /** The default behind the `emptyMessage` prop. */
782
+ emptyMessage: "Nothing here",
783
+ /** The OTHER empty state: "nothing matched" and "there is nothing here" are different sentences. */
784
+ noMatches: (ctx) => `No matches for \u201C${ctx.query}\u201D`,
785
+ /** A branch whose lazy children failed to load, and the button beside it. */
786
+ loadError: "Couldn\u2019t load",
787
+ retry: "Retry",
788
+ /** The name a moved node falls back to when its label is a node, not a string. */
789
+ itemFallback: "Item",
790
+ /**
791
+ * The reorder live region.
792
+ *
793
+ * The ctx carries the raw `position` union, not an English preposition — a translation should not
794
+ * have to parse `"into"`, so the position → verb mapping is this default's job.
795
+ */
796
+ moved: (ctx) => `${ctx.name} moved ${ctx.position === "child" ? "into" : ctx.position} ${ctx.target}`,
797
+ /** The same move with no named target. */
798
+ movedRoot: (ctx) => `${ctx.name} moved`
799
+ };
777
800
  var TREE_INDENT = 20;
778
801
  var HALF_GLYPH = { md: 8, lg: 10 };
779
802
  var ROW_PX = { md: 6, lg: 8 };
@@ -976,7 +999,7 @@ function TreeItem({
976
999
  reserve,
977
1000
  lastChain
978
1001
  }) {
979
- const { tree, size, guide, emptyMessage } = ctx;
1002
+ const { tree, size, guide, emptyMessage, t } = ctx;
980
1003
  const rowId = React.useId();
981
1004
  const branch = isBranch(node);
982
1005
  const children = node.children;
@@ -1020,8 +1043,8 @@ function TreeItem({
1020
1043
  interactive content in a tree, and it is NOT in `tree.visible`, so ↑↓ skip it. */
1021
1044
  /* @__PURE__ */ jsxs("li", { role: "none", className: cn("flex items-center gap-2", EMPTY_ROW[size]), style: groupRowStyle, children: [
1022
1045
  groupRules,
1023
- /* @__PURE__ */ jsx("span", { className: "text-error-primary", children: "Couldn\u2019t load" }),
1024
- /* @__PURE__ */ jsx("button", { type: "button", onClick: () => tree.retryLoad(node.id), className: RETRY_BUTTON, children: "Retry" })
1046
+ /* @__PURE__ */ jsx("span", { className: "text-error-primary", children: t.loadError }),
1047
+ /* @__PURE__ */ jsx("button", { type: "button", onClick: () => tree.retryLoad(node.id), className: RETRY_BUTTON, children: t.retry })
1025
1048
  ] })
1026
1049
  ) }) }) : null,
1027
1050
  branch && children != null ? /* @__PURE__ */ jsx(
@@ -1062,7 +1085,9 @@ function TreeRows({
1062
1085
  )) });
1063
1086
  }
1064
1087
  function Tree(props) {
1065
- const { tree, size = "md", guide = "line", emptyMessage = "Nothing here", render, className, ...rest } = props;
1088
+ const { tree, size = "md", guide = "line", emptyMessage, labels, render, className, ...rest } = props;
1089
+ const t = useLabels("tree", TREE_LABELS, labels);
1090
+ const resolvedEmptyMessage = emptyMessage ?? t.emptyMessage;
1066
1091
  warnNeedsName("Tree", rest["aria-label"] != null || rest["aria-labelledby"] != null, "`aria-label` or `aria-labelledby`");
1067
1092
  const rootRef = React.useRef(null);
1068
1093
  const [focusedId, setFocusedId] = React.useState(null);
@@ -1114,13 +1139,13 @@ function Tree(props) {
1114
1139
  (committed) => {
1115
1140
  const moved = tree.nodeById(committed.id);
1116
1141
  const target = tree.nodeById(committed.target);
1117
- const name = typeof moved?.label === "string" ? moved.label : "Item";
1142
+ const name = typeof moved?.label === "string" ? moved.label : t.itemFallback;
1118
1143
  const into = typeof target?.label === "string" ? target.label : "";
1119
- const verb = committed.position === "child" ? "into" : committed.position;
1120
1144
  clearTimeout(announceTimer.current ?? void 0);
1121
- announceTimer.current = setTimeout(() => setAnnouncement(into ? `${name} moved ${verb} ${into}` : `${name} moved`), ANNOUNCE_DEBOUNCE_MS);
1145
+ const sentence = into ? t.moved({ name, position: committed.position, target: into }) : t.movedRoot({ name });
1146
+ announceTimer.current = setTimeout(() => setAnnouncement(sentence), ANNOUNCE_DEBOUNCE_MS);
1122
1147
  },
1123
- [tree]
1148
+ [tree, t]
1124
1149
  );
1125
1150
  const onRowClick = React.useCallback(
1126
1151
  (id, event) => {
@@ -1301,8 +1326,22 @@ function Tree(props) {
1301
1326
  [announce, moveFocus, resolvedFocus, tree]
1302
1327
  );
1303
1328
  const ctx = React.useMemo(
1304
- () => ({ tree, size, guide, emptyMessage, focusedId: resolvedFocus, onRowFocus, showMarkers, keptIds, onRowClick, onRowDoubleClick, drag, dragHandlers }),
1305
- [tree, size, guide, emptyMessage, resolvedFocus, onRowFocus, showMarkers, keptIds, onRowClick, onRowDoubleClick, drag, dragHandlers]
1329
+ () => ({
1330
+ tree,
1331
+ size,
1332
+ guide,
1333
+ emptyMessage: resolvedEmptyMessage,
1334
+ t,
1335
+ focusedId: resolvedFocus,
1336
+ onRowFocus,
1337
+ showMarkers,
1338
+ keptIds,
1339
+ onRowClick,
1340
+ onRowDoubleClick,
1341
+ drag,
1342
+ dragHandlers
1343
+ }),
1344
+ [tree, size, guide, resolvedEmptyMessage, t, resolvedFocus, onRowFocus, showMarkers, keptIds, onRowClick, onRowDoubleClick, drag, dragHandlers]
1306
1345
  );
1307
1346
  const empty = tree.visible.length === 0;
1308
1347
  const element = useRender({
@@ -1320,7 +1359,7 @@ function Tree(props) {
1320
1359
  onKeyDown: handleKeyDown,
1321
1360
  onBlur: handleBlur,
1322
1361
  className: cn("", className),
1323
- children: empty ? /* @__PURE__ */ jsx("li", { role: "none", className: EMPTY_ROW[size], children: tree.isFiltering ? `No matches for \u201C${tree.query}\u201D` : emptyMessage }) : /* @__PURE__ */ jsx(TreeRows, { nodes: tree.nodes, depth: 0, ctx, parentChain: [] })
1362
+ children: empty ? /* @__PURE__ */ jsx("li", { role: "none", className: EMPTY_ROW[size], children: tree.isFiltering ? t.noMatches({ query: tree.query }) : resolvedEmptyMessage }) : /* @__PURE__ */ jsx(TreeRows, { nodes: tree.nodes, depth: 0, ctx, parentChain: [] })
1324
1363
  },
1325
1364
  rest
1326
1365
  )
@@ -1334,5 +1373,5 @@ function Tree(props) {
1334
1373
  Tree.displayName = "Tree";
1335
1374
 
1336
1375
  export { Tree, ancestorIds, applyTreeMove, attachChildren, isBranch, isDescendant, useTree, walkTree };
1337
- //# sourceMappingURL=chunk-T2WAD4QP.js.map
1338
- //# sourceMappingURL=chunk-T2WAD4QP.js.map
1376
+ //# sourceMappingURL=chunk-POQTE7JI.js.map
1377
+ //# sourceMappingURL=chunk-POQTE7JI.js.map
@@ -1,6 +1,6 @@
1
- import { OptionRow } from './chunk-GTHJWR3Q.js';
2
- import { warnNeedsName } from './chunk-QDYE5LVT.js';
1
+ import { OptionRow } from './chunk-D7EE5GWU.js';
3
2
  import { cn } from './chunk-ZSNJ6UA3.js';
3
+ import { warnNeedsName } from './chunk-QDYE5LVT.js';
4
4
  import { Switch as Switch$1 } from '@base-ui/react/switch';
5
5
  import * as React from 'react';
6
6
  import { jsx } from 'react/jsx-runtime';
@@ -63,5 +63,5 @@ function Switch(props) {
63
63
  }
64
64
 
65
65
  export { Switch };
66
- //# sourceMappingURL=chunk-74HPBSVY.js.map
67
- //# sourceMappingURL=chunk-74HPBSVY.js.map
66
+ //# sourceMappingURL=chunk-QDKETK7D.js.map
67
+ //# sourceMappingURL=chunk-QDKETK7D.js.map
@@ -1,13 +1,19 @@
1
- import { Tag } from './chunk-EDT5J5WK.js';
2
- import { useTagRow } from './chunk-6HJA7NPL.js';
3
- import { FieldShell } from './chunk-JUWDRRD6.js';
1
+ import { Tag } from './chunk-LYXPJERB.js';
2
+ import { useTagRow } from './chunk-6H4LNWQ7.js';
3
+ import { FieldShell } from './chunk-X2VMIBK5.js';
4
4
  import { useIsomorphicLayoutEffect } from './chunk-EDSK6FEH.js';
5
- import { CONTROL_TEXT, CONTROL_RADIUS, useFieldValidity, FieldFrame } from './chunk-QKDEQFOQ.js';
5
+ import { CONTROL_TEXT, CONTROL_RADIUS, useFieldValidity, FieldFrame } from './chunk-5KSD4WKN.js';
6
6
  import { cn } from './chunk-ZSNJ6UA3.js';
7
+ import { useLabels } from './chunk-RJTVCA62.js';
7
8
  import { Field } from '@base-ui/react/field';
8
9
  import * as React from 'react';
9
10
  import { jsxs, Fragment, jsx } from 'react/jsx-runtime';
10
11
 
12
+ // src/components/tag-input/labels.ts
13
+ var TAG_INPUT_LABELS = {
14
+ /** Default behind the `placeholder` prop — the caller's own prop still wins. */
15
+ placeholder: "Add tag\u2026"
16
+ };
11
17
  var SEPARATOR = {
12
18
  enter: { key: "Enter", paste: "\n" },
13
19
  comma: { key: ",", paste: "," },
@@ -166,9 +172,11 @@ function useTagInput(opts) {
166
172
  }
167
173
  var PILL_SIZE = { sm: "sm", md: "md", lg: "md" };
168
174
  function TagInput(props) {
175
+ const t = useLabels("tagInput", TAG_INPUT_LABELS, props.labels);
169
176
  const {
170
177
  size = "md",
171
- placeholder = "Add tag\u2026",
178
+ placeholder = t.placeholder,
179
+ labels: _labels,
172
180
  label,
173
181
  tooltip,
174
182
  tooltipDescription,
@@ -264,6 +272,6 @@ function TagInput(props) {
264
272
  );
265
273
  }
266
274
 
267
- export { TAG_PILL_FOCUS_RING, TagInput, useTagInput };
268
- //# sourceMappingURL=chunk-VH35QHD4.js.map
269
- //# sourceMappingURL=chunk-VH35QHD4.js.map
275
+ export { TAG_INPUT_LABELS, TAG_PILL_FOCUS_RING, TagInput, useTagInput };
276
+ //# sourceMappingURL=chunk-QHH6AUR3.js.map
277
+ //# sourceMappingURL=chunk-QHH6AUR3.js.map
@@ -0,0 +1,42 @@
1
+ import { devWarn } from './chunk-QDYE5LVT.js';
2
+ import * as React from 'react';
3
+
4
+ var LabelsContext = React.createContext(void 0);
5
+ if (process.env.NODE_ENV !== "production") LabelsContext.displayName = "JenosizeUILabelsContext";
6
+ function resolveOne(scope, key, fallback, override) {
7
+ if (override === void 0) return fallback;
8
+ if (typeof fallback === "function") return typeof override === "function" ? override : () => override;
9
+ if (typeof override === "string") return override;
10
+ devWarn(`labels.${scope}.${key} must be a string \u2014 a function was given for a key that takes no context. Ignored.`);
11
+ return fallback;
12
+ }
13
+ function useLabels(scope, defaults, local) {
14
+ const app = React.useContext(LabelsContext)?.[scope];
15
+ return React.useMemo(() => {
16
+ if (app === void 0 && local === void 0) return defaults;
17
+ const merged = {};
18
+ for (const [key, fallback] of Object.entries(defaults)) {
19
+ const override = local?.[key] ?? app?.[key];
20
+ merged[key] = resolveOne(scope, key, fallback, override);
21
+ }
22
+ return merged;
23
+ }, [scope, defaults, app, local]);
24
+ }
25
+ function usePublishedLabels(scope, local) {
26
+ const outer = React.useContext(LabelsContext);
27
+ return React.useMemo(() => local === void 0 ? outer : mergeLabels(outer, { [scope]: local }), [outer, scope, local]);
28
+ }
29
+ function mergeLabels(outer, inner) {
30
+ if (outer === void 0) return inner;
31
+ if (inner === void 0) return outer;
32
+ const merged = { ...outer };
33
+ for (const [scope, table] of Object.entries(inner)) {
34
+ const before = merged[scope];
35
+ merged[scope] = before === void 0 ? table : { ...before, ...table };
36
+ }
37
+ return merged;
38
+ }
39
+
40
+ export { LabelsContext, mergeLabels, useLabels, usePublishedLabels };
41
+ //# sourceMappingURL=chunk-RJTVCA62.js.map
42
+ //# sourceMappingURL=chunk-RJTVCA62.js.map
@@ -1,21 +1,37 @@
1
1
  import { useDebouncedCallback } from './chunk-F6NLE6XJ.js';
2
- import { useControlScrollFade } from './chunk-7EUAMHMU.js';
3
- import { ListboxFooter, MultiValueCount } from './chunk-ILICYNK7.js';
4
- import { useTagRow } from './chunk-6HJA7NPL.js';
2
+ import { ListboxFooter, MultiValueCount } from './chunk-4RBIWI2Q.js';
3
+ import { useTagRow } from './chunk-6H4LNWQ7.js';
5
4
  import { tagSlotClass, tagContentClass, tagCloseClass, tagRootClass } from './chunk-4P2NBLBW.js';
6
5
  import { ScrollView } from './chunk-FKVPAEJ6.js';
7
6
  import { mapOptions, isOptionGroup, buildOptionMap } from './chunk-7JBNLEJ7.js';
8
- import { FieldShell } from './chunk-JUWDRRD6.js';
7
+ import { useControlScrollFade } from './chunk-7EUAMHMU.js';
8
+ import { FieldShell } from './chunk-X2VMIBK5.js';
9
+ import { useFieldValidity, FieldFrame, LISTBOX_PX_SM, CONTROL_ICON, SLOT_ICON } from './chunk-5KSD4WKN.js';
9
10
  import { Slot } from './chunk-52IFGFTL.js';
10
- import { useFieldValidity, FieldFrame, LISTBOX_PX_SM, CONTROL_ICON, SLOT_ICON } from './chunk-QKDEQFOQ.js';
11
11
  import { POPUP_MOTION } from './chunk-O4GRKO3I.js';
12
12
  import { PlusIcon, XIcon, ChevronDownIcon, LoaderCircleIcon, CheckIcon } from './chunk-BLIZ3CL3.js';
13
- import { warnNonNegativeInt } from './chunk-QDYE5LVT.js';
14
13
  import { cn } from './chunk-ZSNJ6UA3.js';
14
+ import { useLabels, usePublishedLabels, LabelsContext } from './chunk-RJTVCA62.js';
15
+ import { warnNonNegativeInt } from './chunk-QDYE5LVT.js';
15
16
  import { Combobox as Combobox$1 } from '@base-ui/react/combobox';
16
17
  import * as React from 'react';
17
- import { jsxs, jsx } from 'react/jsx-runtime';
18
+ import { jsx, jsxs } from 'react/jsx-runtime';
18
19
 
20
+ // src/components/combobox/labels.ts
21
+ var COMBOBOX_LABELS = {
22
+ /** The trigger that opens the list without typing. */
23
+ showOptions: "Show options",
24
+ /** The ✕ that empties the input. */
25
+ clear: "Clear",
26
+ /** A multi-value chip's remove button, named after the value it drops. */
27
+ removeValue: (ctx) => `Remove ${ctx.label}`,
28
+ /** The free-text creation row. */
29
+ create: (ctx) => `Create \u201C${ctx.query}\u201D`,
30
+ /** Defaults behind the `placeholder`, `emptyMessage` and loading props — each prop still wins. */
31
+ placeholder: "Search\u2026",
32
+ emptyMessage: "No results found.",
33
+ loading: "Loading\u2026"
34
+ };
19
35
  var ComboboxContext = React.createContext({
20
36
  size: "md",
21
37
  multiple: false,
@@ -141,7 +157,7 @@ function ghostRemainder(optionMap, query) {
141
157
  return completion;
142
158
  }
143
159
  function ComboboxInput({
144
- placeholder = "Search\u2026",
160
+ placeholder,
145
161
  leading,
146
162
  trailing,
147
163
  leadingAddon,
@@ -156,13 +172,14 @@ function ComboboxInput({
156
172
  className
157
173
  }) {
158
174
  const { size, multiple, labelId, optionMap, query, anchorRef } = useComboboxContext();
175
+ const t = useLabels("combobox", COMBOBOX_LABELS, void 0);
159
176
  const chips = multiple && display === "tags";
160
177
  const { ref: fadeRef, style: fadeStyle } = useControlScrollFade(scrollFade && !multiple);
161
178
  const ghost = !multiple && optionMap.size > 0;
162
179
  const remainder = ghost ? ghostRemainder(optionMap, query) : "";
163
180
  const chipRow = useTagRow({ size, maxRows, count: selectedCount, hasPills: chips && selectedCount > 0, scrollbar: "none" });
164
181
  const showCount = multiple && !chips && selectedCount > 0;
165
- const inputPlaceholder = showCount ? void 0 : placeholder;
182
+ const inputPlaceholder = showCount ? void 0 : placeholder ?? t.placeholder;
166
183
  return /* @__PURE__ */ jsxs(
167
184
  FieldShell,
168
185
  {
@@ -216,7 +233,7 @@ function ComboboxInput({
216
233
  /* @__PURE__ */ jsx(
217
234
  Combobox$1.ChipRemove,
218
235
  {
219
- "aria-label": `Remove ${typeof chip.label === "string" ? chip.label : String(value)}`,
236
+ "aria-label": t.removeValue({ label: typeof chip.label === "string" ? chip.label : String(value) }),
220
237
  className: tagCloseClass(CHIP_SIZE[size]),
221
238
  children: /* @__PURE__ */ jsx(XIcon, {})
222
239
  }
@@ -227,7 +244,7 @@ function ComboboxInput({
227
244
  );
228
245
  });
229
246
  } }),
230
- /* @__PURE__ */ jsx(Combobox$1.Input, { "aria-labelledby": labelId, placeholder, className: cn(INNER_INPUT, "min-w-[4rem]") })
247
+ /* @__PURE__ */ jsx(Combobox$1.Input, { "aria-labelledby": labelId, placeholder: placeholder ?? t.placeholder, className: cn(INNER_INPUT, "min-w-[4rem]") })
231
248
  ] }) : (
232
249
  // ONE structure for the ghost-text and plain inputs — the input's position and element type
233
250
  // are identical whether or not there is a ghost remainder.
@@ -272,15 +289,17 @@ function ComboboxInput({
272
289
  }
273
290
  var TRAILING_BTN = "inline-flex shrink-0 cursor-pointer items-center justify-center rounded-md text-fg-quaternary outline-none transition-colors hover:text-fg-quaternary_hover focus-visible:text-fg-quaternary_hover data-[disabled]:cursor-not-allowed";
274
291
  function ComboboxTrigger({ className }) {
292
+ const t = useLabels("combobox", COMBOBOX_LABELS, void 0);
275
293
  const { size } = useComboboxContext();
276
- return /* @__PURE__ */ jsx(Combobox$1.Trigger, { "aria-label": "Show options", className: cn(TRAILING_BTN, CONTROL_ICON[size], className), children: /* @__PURE__ */ jsx(Combobox$1.Icon, { className: "inline-flex transition-transform duration-200 group-data-[popup-open]:rotate-180", children: /* @__PURE__ */ jsx(ChevronDownIcon, {}) }) });
294
+ return /* @__PURE__ */ jsx(Combobox$1.Trigger, { "aria-label": t.showOptions, className: cn(TRAILING_BTN, CONTROL_ICON[size], className), children: /* @__PURE__ */ jsx(Combobox$1.Icon, { className: "inline-flex transition-transform duration-200 group-data-[popup-open]:rotate-180", children: /* @__PURE__ */ jsx(ChevronDownIcon, {}) }) });
277
295
  }
278
296
  function ComboboxClear({ className }) {
297
+ const t = useLabels("combobox", COMBOBOX_LABELS, void 0);
279
298
  const { clearable, size } = useComboboxContext();
280
299
  if (!clearable) {
281
300
  return null;
282
301
  }
283
- return /* @__PURE__ */ jsx(Combobox$1.Clear, { "aria-label": "Clear", className: cn(TRAILING_BTN, CONTROL_ICON[size], className), children: /* @__PURE__ */ jsx(XIcon, {}) });
302
+ return /* @__PURE__ */ jsx(Combobox$1.Clear, { "aria-label": t.clear, className: cn(TRAILING_BTN, CONTROL_ICON[size], className), children: /* @__PURE__ */ jsx(XIcon, {}) });
284
303
  }
285
304
  var POPUP = cn("w-full rounded-lg bg-primary p-1 text-primary shadow-lg ring-1 ring-secondary_alt outline-none ring-inset", POPUP_MOTION);
286
305
  var LIST_MAX_H = {
@@ -377,10 +396,11 @@ function ComboboxGroupLabel({ children, className }) {
377
396
  function ComboboxEmpty({ children, className }) {
378
397
  return /* @__PURE__ */ jsx(Combobox$1.Empty, { className: cn("px-3 py-6 text-center text-sm text-tertiary", className), children });
379
398
  }
380
- function ComboboxLoading({ children = "Loading\u2026", className }) {
399
+ function ComboboxLoading({ children, className }) {
400
+ const t = useLabels("combobox", COMBOBOX_LABELS, void 0);
381
401
  return /* @__PURE__ */ jsxs(Combobox$1.Status, { className: cn("flex items-center justify-center gap-2 px-3 py-6 text-sm text-tertiary [&_svg]:size-4", className), children: [
382
402
  /* @__PURE__ */ jsx(LoaderCircleIcon, { className: "animate-spin" }),
383
- /* @__PURE__ */ jsx("span", { children })
403
+ /* @__PURE__ */ jsx("span", { children: children ?? t.loading })
384
404
  ] });
385
405
  }
386
406
  function optionLabelText(option) {
@@ -393,9 +413,6 @@ function asStringList(v) {
393
413
  if (Array.isArray(v)) return v.filter((entry) => typeof entry === "string");
394
414
  return typeof v === "string" ? [v] : [];
395
415
  }
396
- function defaultCreateLabel(query) {
397
- return `Create \u201C${query}\u201D`;
398
- }
399
416
  function defaultContains(option, query) {
400
417
  return optionLabelText(option).toLowerCase().includes(query.trim().toLowerCase());
401
418
  }
@@ -425,7 +442,7 @@ function ComboboxFlat(props) {
425
442
  filter,
426
443
  loading = false,
427
444
  loadingMessage,
428
- emptyMessage = "No results found.",
445
+ emptyMessage,
429
446
  placeholder,
430
447
  leading,
431
448
  trailing,
@@ -440,15 +457,18 @@ function ComboboxFlat(props) {
440
457
  meta,
441
458
  creatable = false,
442
459
  onCreate,
443
- createLabel = defaultCreateLabel,
460
+ createLabel,
444
461
  validateCreate,
445
462
  multiple,
446
463
  autoHighlight,
447
464
  onInputChange,
448
465
  searchDebounce = 0,
449
466
  onValueChange,
467
+ labels,
450
468
  ...rootProps
451
469
  } = props;
470
+ const t = useLabels("combobox", COMBOBOX_LABELS, labels);
471
+ const publishedLabels = usePublishedLabels("combobox", labels);
452
472
  const size = props.size ?? "md";
453
473
  const [query, setQuery] = React.useState("");
454
474
  const [selectedSingle, setSelectedSingle] = React.useState(() => asString(props.value ?? props.defaultValue));
@@ -490,7 +510,7 @@ function ComboboxFlat(props) {
490
510
  const knownAlready = createQuery === "" || flattenOptions(options).some((o) => o.value.toLowerCase() === trimmed || optionLabelText(o).toLowerCase() === trimmed) || selectedValues.some((v) => v.toLowerCase() === trimmed);
491
511
  const showCreate = creatable && !loading && !knownAlready && (validateCreate?.(createQuery) ?? true);
492
512
  const isEmpty = !loading && !showCreate && flattenOptions(rows).length === 0;
493
- return /* @__PURE__ */ jsxs(
513
+ return /* @__PURE__ */ jsx(LabelsContext.Provider, { value: publishedLabels, children: /* @__PURE__ */ jsxs(
494
514
  ComboboxRoot,
495
515
  {
496
516
  options,
@@ -523,7 +543,7 @@ function ComboboxFlat(props) {
523
543
  ),
524
544
  /* @__PURE__ */ jsxs(ComboboxContent, { footer: /* @__PURE__ */ jsx(ListboxFooter, { meta, actions, size }), children: [
525
545
  loading ? /* @__PURE__ */ jsx(ComboboxLoading, { children: loadingMessage }) : null,
526
- isEmpty ? /* @__PURE__ */ jsx(ComboboxEmpty, { children: emptyMessage }) : null,
546
+ isEmpty ? /* @__PURE__ */ jsx(ComboboxEmpty, { children: emptyMessage ?? t.emptyMessage }) : null,
527
547
  loading ? null : mapOptions(rows, {
528
548
  item: (opt) => /* @__PURE__ */ jsx(ComboboxItem, { value: opt.value, disabled: opt.disabled, children: opt.label ?? opt.value }, opt.value),
529
549
  group: (label, groupChildren) => /* @__PURE__ */ jsxs(ComboboxGroup, { children: [
@@ -531,11 +551,11 @@ function ComboboxFlat(props) {
531
551
  groupChildren
532
552
  ] }, label)
533
553
  }),
534
- showCreate ? /* @__PURE__ */ jsx(ComboboxItem, { value: createQuery, leading: /* @__PURE__ */ jsx(PlusIcon, {}), hideIndicator: true, children: createLabel(createQuery) }) : null
554
+ showCreate ? /* @__PURE__ */ jsx(ComboboxItem, { value: createQuery, leading: /* @__PURE__ */ jsx(PlusIcon, {}), hideIndicator: true, children: createLabel ? createLabel(createQuery) : t.create({ query: createQuery }) }) : null
535
555
  ] })
536
556
  ]
537
557
  }
538
- );
558
+ ) });
539
559
  }
540
560
  ComboboxFlat.displayName = "Combobox";
541
561
  ComboboxRoot.displayName = "ComboboxRoot";
@@ -551,5 +571,5 @@ ComboboxLoading.displayName = "ComboboxLoading";
551
571
  var Combobox = ComboboxFlat;
552
572
 
553
573
  export { Combobox };
554
- //# sourceMappingURL=chunk-DTMYD63D.js.map
555
- //# sourceMappingURL=chunk-DTMYD63D.js.map
574
+ //# sourceMappingURL=chunk-S5TEWPWW.js.map
575
+ //# sourceMappingURL=chunk-S5TEWPWW.js.map
@@ -1,8 +1,9 @@
1
1
  import { useControlScrollFade } from './chunk-7EUAMHMU.js';
2
- import { FieldShell } from './chunk-JUWDRRD6.js';
3
- import { useFieldValidity, FieldFrame } from './chunk-QKDEQFOQ.js';
4
- import { warnPositiveInt } from './chunk-QDYE5LVT.js';
2
+ import { FieldShell } from './chunk-X2VMIBK5.js';
3
+ import { useFieldValidity, FieldFrame } from './chunk-5KSD4WKN.js';
5
4
  import { cn } from './chunk-ZSNJ6UA3.js';
5
+ import { useLabels } from './chunk-RJTVCA62.js';
6
+ import { warnPositiveInt } from './chunk-QDYE5LVT.js';
6
7
  import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
7
8
  import { Field } from '@base-ui/react/field';
8
9
  import * as React from 'react';
@@ -257,8 +258,12 @@ function applyCardNumberEdit(rawValue, caret, previous, maxDigits = DEFAULT_MAX_
257
258
  const value = groupDigits(digits, CARD_GROUPS[detectCardType(digits)]);
258
259
  return { value, caret: caretAfterDigits(value, before) };
259
260
  }
260
- var DEFAULT_BRAND_ERROR = "This card type isn't accepted.";
261
- var DEFAULT_LUHN_ERROR = "Check the card number \u2014 a digit looks wrong.";
261
+
262
+ // src/components/payment-input/labels.ts
263
+ var PAYMENT_INPUT_LABELS = {
264
+ brandError: "This card type isn't accepted.",
265
+ luhnError: "Check the card number \u2014 a digit looks wrong."
266
+ };
262
267
  var LOGO_PL = { sm: "pl-1.5 gap-2", md: "pl-2", lg: "pl-2.5" };
263
268
  function PaymentInput(props) {
264
269
  const {
@@ -280,6 +285,7 @@ function PaymentInput(props) {
280
285
  acceptedBrands,
281
286
  brandError,
282
287
  luhnError,
288
+ labels,
283
289
  maxDigits = DEFAULT_MAX_DIGITS,
284
290
  required = false,
285
291
  hideRequiredIndicator = false,
@@ -294,6 +300,7 @@ function PaymentInput(props) {
294
300
  const inputRef = React.useRef(null);
295
301
  const { ref: fadeRef, style: fadeStyle } = useControlScrollFade(scrollFade, "horizontal", inputRef);
296
302
  const isControlled = value !== void 0;
303
+ const t = useLabels("paymentInput", PAYMENT_INPUT_LABELS, labels);
297
304
  warnPositiveInt("PaymentInput", "maxDigits", maxDigits);
298
305
  const [internal, setInternal] = React.useState(() => formatCardNumber(defaultValue ?? "", maxDigits));
299
306
  const [focused, setFocused] = React.useState(false);
@@ -303,7 +310,7 @@ function PaymentInput(props) {
303
310
  const brandRejected = acceptedBrands != null && cardType !== "unknown" && !acceptedBrands.includes(cardType);
304
311
  const checksumFailed = hasChecksumError(current, maxDigits) && (!focused || isLengthSettled(current, maxDigits));
305
312
  const parentHasError = error != null && error !== "";
306
- const effectiveError = parentHasError ? error : brandRejected ? brandError ?? DEFAULT_BRAND_ERROR : checksumFailed ? luhnError ?? DEFAULT_LUHN_ERROR : void 0;
313
+ const effectiveError = parentHasError ? error : brandRejected ? brandError ?? t.brandError : checksumFailed ? luhnError ?? t.luhnError : void 0;
307
314
  const { isInvalid, showError } = useFieldValidity(invalid, effectiveError);
308
315
  const caretRef = React.useRef(null);
309
316
  React.useLayoutEffect(() => {
@@ -383,5 +390,5 @@ function PaymentInput(props) {
383
390
  }
384
391
 
385
392
  export { CARD_ICON, DEFAULT_MAX_DIGITS, PaymentInput, applyCardNumberEdit, detectCardType, formatCardNumber, hasChecksumError, isCompleteCardNumber, isLengthSettled, luhnValid, onlyDigits };
386
- //# sourceMappingURL=chunk-3GT43XPK.js.map
387
- //# sourceMappingURL=chunk-3GT43XPK.js.map
393
+ //# sourceMappingURL=chunk-SB3DG572.js.map
394
+ //# sourceMappingURL=chunk-SB3DG572.js.map
@@ -1,4 +1,4 @@
1
- import { Cartesian } from './chunk-NA35YZRD.js';
1
+ import { Cartesian } from './chunk-5DP7W5HX.js';
2
2
  import { jsx } from 'react/jsx-runtime';
3
3
 
4
4
  function BarChart({ stacked = false, layout = "columns", ...rest }) {
@@ -6,5 +6,5 @@ function BarChart({ stacked = false, layout = "columns", ...rest }) {
6
6
  }
7
7
 
8
8
  export { BarChart };
9
- //# sourceMappingURL=chunk-NKDW6C7K.js.map
10
- //# sourceMappingURL=chunk-NKDW6C7K.js.map
9
+ //# sourceMappingURL=chunk-SKRR3ZMP.js.map
10
+ //# sourceMappingURL=chunk-SKRR3ZMP.js.map
@@ -1,5 +1,5 @@
1
- import { usePolarData } from './chunk-LBYCCLVI.js';
2
- import { PIE_SIZE, PIE_DONUT, ChartDataTable, formatNumber, ChartFrame, PieChart, MARGIN, Tooltip, NO_ANIMATION, ChartTooltipContent, Pie, POLAR_ROOT, POLAR_HOVER, ChartLegendContent } from './chunk-75M43ELV.js';
1
+ import { usePolarData } from './chunk-OLLD2BZN.js';
2
+ import { DEFAULT_PALETTE, PIE_SIZE, PIE_DONUT, ChartDataTable, formatNumber, ChartFrame, PieChart, MARGIN, Tooltip, NO_ANIMATION, ChartTooltipContent, Pie, POLAR_ROOT, POLAR_HOVER, ChartLegendContent } from './chunk-22M75A3N.js';
3
3
  import { cn } from './chunk-ZSNJ6UA3.js';
4
4
  import { jsx, jsxs } from 'react/jsx-runtime';
5
5
 
@@ -7,12 +7,13 @@ function PieChart2({
7
7
  data,
8
8
  donut = "regular",
9
9
  size = "md",
10
- palette = "brand",
10
+ palette = DEFAULT_PALETTE,
11
11
  legend = "bottom",
12
12
  formatValue = formatNumber,
13
13
  tooltip = true,
14
14
  tooltipTone = "surface",
15
- emptyMessage = "No data to display",
15
+ emptyMessage,
16
+ labels,
16
17
  className,
17
18
  "aria-label": ariaLabel
18
19
  }) {
@@ -28,6 +29,7 @@ function PieChart2({
28
29
  height: geometry.height,
29
30
  isEmpty: data.length === 0,
30
31
  emptyMessage,
32
+ labels,
31
33
  className,
32
34
  table,
33
35
  legendPlacement: legend === "none" ? void 0 : legend,
@@ -56,5 +58,5 @@ function PieChart2({
56
58
  }
57
59
 
58
60
  export { PieChart2 as PieChart };
59
- //# sourceMappingURL=chunk-CTENRS34.js.map
60
- //# sourceMappingURL=chunk-CTENRS34.js.map
61
+ //# sourceMappingURL=chunk-T4ZFZTY6.js.map
62
+ //# sourceMappingURL=chunk-T4ZFZTY6.js.map