cetec-design-system 4.9.1-0 → 4.11.0-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/dist/index.js CHANGED
@@ -974,7 +974,7 @@ const spinnerVariantKeys = [
974
974
  "inverse",
975
975
  "centered"
976
976
  ];
977
- const getVariantProps$z = (variants) => ({ ...spinnerDefaultVariants, ...compact(variants) });
977
+ const getVariantProps$B = (variants) => ({ ...spinnerDefaultVariants, ...compact(variants) });
978
978
  const spinner = /* @__PURE__ */ Object.assign(spinnerFn, {
979
979
  __recipe__: false,
980
980
  __name__: "spinner",
@@ -999,7 +999,7 @@ const spinner = /* @__PURE__ */ Object.assign(spinnerFn, {
999
999
  splitVariantProps(props) {
1000
1000
  return splitProps$1(props, spinnerVariantKeys);
1001
1001
  },
1002
- getVariantProps: getVariantProps$z
1002
+ getVariantProps: getVariantProps$B
1003
1003
  });
1004
1004
  const tagFn = /* @__PURE__ */ createRecipe("tag", {
1005
1005
  "variant": "default",
@@ -1667,7 +1667,7 @@ const toggleFn = memo((props = {}) => {
1667
1667
  return Object.fromEntries(toggleSlotFns.map(([slotName, slotFn]) => [slotName, slotFn.recipeFn(props)]));
1668
1668
  });
1669
1669
  const toggleVariantKeys = [];
1670
- const getVariantProps$y = (variants) => ({ ...toggleDefaultVariants, ...compact(variants) });
1670
+ const getVariantProps$A = (variants) => ({ ...toggleDefaultVariants, ...compact(variants) });
1671
1671
  const toggle = /* @__PURE__ */ Object.assign(toggleFn, {
1672
1672
  __recipe__: false,
1673
1673
  __name__: "toggle",
@@ -1678,7 +1678,7 @@ const toggle = /* @__PURE__ */ Object.assign(toggleFn, {
1678
1678
  splitVariantProps(props) {
1679
1679
  return splitProps$1(props, toggleVariantKeys);
1680
1680
  },
1681
- getVariantProps: getVariantProps$y
1681
+ getVariantProps: getVariantProps$A
1682
1682
  });
1683
1683
  const alertDefaultVariants = {
1684
1684
  "tone": "info"
@@ -1721,7 +1721,7 @@ const alertFn = memo((props = {}) => {
1721
1721
  const alertVariantKeys = [
1722
1722
  "tone"
1723
1723
  ];
1724
- const getVariantProps$x = (variants) => ({ ...alertDefaultVariants, ...compact(variants) });
1724
+ const getVariantProps$z = (variants) => ({ ...alertDefaultVariants, ...compact(variants) });
1725
1725
  const alert = /* @__PURE__ */ Object.assign(alertFn, {
1726
1726
  __recipe__: false,
1727
1727
  __name__: "alert",
@@ -1740,7 +1740,7 @@ const alert = /* @__PURE__ */ Object.assign(alertFn, {
1740
1740
  splitVariantProps(props) {
1741
1741
  return splitProps$1(props, alertVariantKeys);
1742
1742
  },
1743
- getVariantProps: getVariantProps$x
1743
+ getVariantProps: getVariantProps$z
1744
1744
  });
1745
1745
  const autocompleteDefaultVariants = {
1746
1746
  "size": "md",
@@ -1797,7 +1797,7 @@ const autocompleteVariantKeys = [
1797
1797
  "layer",
1798
1798
  "size"
1799
1799
  ];
1800
- const getVariantProps$w = (variants) => ({ ...autocompleteDefaultVariants, ...compact(variants) });
1800
+ const getVariantProps$y = (variants) => ({ ...autocompleteDefaultVariants, ...compact(variants) });
1801
1801
  const autocomplete = /* @__PURE__ */ Object.assign(autocompleteFn, {
1802
1802
  __recipe__: false,
1803
1803
  __name__: "autocomplete",
@@ -1819,7 +1819,7 @@ const autocomplete = /* @__PURE__ */ Object.assign(autocompleteFn, {
1819
1819
  splitVariantProps(props) {
1820
1820
  return splitProps$1(props, autocompleteVariantKeys);
1821
1821
  },
1822
- getVariantProps: getVariantProps$w
1822
+ getVariantProps: getVariantProps$y
1823
1823
  });
1824
1824
  const avatarDefaultVariants = {
1825
1825
  "size": "md",
@@ -1856,7 +1856,7 @@ const avatarVariantKeys = [
1856
1856
  "size",
1857
1857
  "shape"
1858
1858
  ];
1859
- const getVariantProps$v = (variants) => ({ ...avatarDefaultVariants, ...compact(variants) });
1859
+ const getVariantProps$x = (variants) => ({ ...avatarDefaultVariants, ...compact(variants) });
1860
1860
  const avatar = /* @__PURE__ */ Object.assign(avatarFn, {
1861
1861
  __recipe__: false,
1862
1862
  __name__: "avatar",
@@ -1881,7 +1881,7 @@ const avatar = /* @__PURE__ */ Object.assign(avatarFn, {
1881
1881
  splitVariantProps(props) {
1882
1882
  return splitProps$1(props, avatarVariantKeys);
1883
1883
  },
1884
- getVariantProps: getVariantProps$v
1884
+ getVariantProps: getVariantProps$x
1885
1885
  });
1886
1886
  const badgeDefaultVariants = {
1887
1887
  "size": "md",
@@ -1908,7 +1908,7 @@ const badgeVariantKeys = [
1908
1908
  "dot",
1909
1909
  "variant"
1910
1910
  ];
1911
- const getVariantProps$u = (variants) => ({ ...badgeDefaultVariants, ...compact(variants) });
1911
+ const getVariantProps$w = (variants) => ({ ...badgeDefaultVariants, ...compact(variants) });
1912
1912
  const badge = /* @__PURE__ */ Object.assign(badgeFn, {
1913
1913
  __recipe__: false,
1914
1914
  __name__: "badge",
@@ -1944,7 +1944,7 @@ const badge = /* @__PURE__ */ Object.assign(badgeFn, {
1944
1944
  splitVariantProps(props) {
1945
1945
  return splitProps$1(props, badgeVariantKeys);
1946
1946
  },
1947
- getVariantProps: getVariantProps$u
1947
+ getVariantProps: getVariantProps$w
1948
1948
  });
1949
1949
  const breadcrumbsDefaultVariants = {};
1950
1950
  const breadcrumbsCompoundVariants = [];
@@ -1971,7 +1971,7 @@ const breadcrumbsFn = memo((props = {}) => {
1971
1971
  return Object.fromEntries(breadcrumbsSlotFns.map(([slotName, slotFn]) => [slotName, slotFn.recipeFn(props)]));
1972
1972
  });
1973
1973
  const breadcrumbsVariantKeys = [];
1974
- const getVariantProps$t = (variants) => ({ ...breadcrumbsDefaultVariants, ...compact(variants) });
1974
+ const getVariantProps$v = (variants) => ({ ...breadcrumbsDefaultVariants, ...compact(variants) });
1975
1975
  const breadcrumbs = /* @__PURE__ */ Object.assign(breadcrumbsFn, {
1976
1976
  __recipe__: false,
1977
1977
  __name__: "breadcrumbs",
@@ -1982,7 +1982,7 @@ const breadcrumbs = /* @__PURE__ */ Object.assign(breadcrumbsFn, {
1982
1982
  splitVariantProps(props) {
1983
1983
  return splitProps$1(props, breadcrumbsVariantKeys);
1984
1984
  },
1985
- getVariantProps: getVariantProps$t
1985
+ getVariantProps: getVariantProps$v
1986
1986
  });
1987
1987
  const buttonDefaultVariants = {
1988
1988
  "variant": "standard",
@@ -2013,7 +2013,7 @@ const buttonVariantKeys = [
2013
2013
  "before",
2014
2014
  "after"
2015
2015
  ];
2016
- const getVariantProps$s = (variants) => ({ ...buttonDefaultVariants, ...compact(variants) });
2016
+ const getVariantProps$u = (variants) => ({ ...buttonDefaultVariants, ...compact(variants) });
2017
2017
  const button = /* @__PURE__ */ Object.assign(buttonFn, {
2018
2018
  __recipe__: false,
2019
2019
  __name__: "button",
@@ -2047,7 +2047,7 @@ const button = /* @__PURE__ */ Object.assign(buttonFn, {
2047
2047
  splitVariantProps(props) {
2048
2048
  return splitProps$1(props, buttonVariantKeys);
2049
2049
  },
2050
- getVariantProps: getVariantProps$s
2050
+ getVariantProps: getVariantProps$u
2051
2051
  });
2052
2052
  const calendarDefaultVariants = {
2053
2053
  "type": "days"
@@ -2086,7 +2086,7 @@ const calendarFn = memo((props = {}) => {
2086
2086
  const calendarVariantKeys = [
2087
2087
  "type"
2088
2088
  ];
2089
- const getVariantProps$r = (variants) => ({ ...calendarDefaultVariants, ...compact(variants) });
2089
+ const getVariantProps$t = (variants) => ({ ...calendarDefaultVariants, ...compact(variants) });
2090
2090
  const calendar = /* @__PURE__ */ Object.assign(calendarFn, {
2091
2091
  __recipe__: false,
2092
2092
  __name__: "calendar",
@@ -2103,7 +2103,7 @@ const calendar = /* @__PURE__ */ Object.assign(calendarFn, {
2103
2103
  splitVariantProps(props) {
2104
2104
  return splitProps$1(props, calendarVariantKeys);
2105
2105
  },
2106
- getVariantProps: getVariantProps$r
2106
+ getVariantProps: getVariantProps$t
2107
2107
  });
2108
2108
  const checkboxDefaultVariants = {};
2109
2109
  const checkboxCompoundVariants = [];
@@ -2130,7 +2130,7 @@ const checkboxFn = memo((props = {}) => {
2130
2130
  return Object.fromEntries(checkboxSlotFns.map(([slotName, slotFn]) => [slotName, slotFn.recipeFn(props)]));
2131
2131
  });
2132
2132
  const checkboxVariantKeys = [];
2133
- const getVariantProps$q = (variants) => ({ ...checkboxDefaultVariants, ...compact(variants) });
2133
+ const getVariantProps$s = (variants) => ({ ...checkboxDefaultVariants, ...compact(variants) });
2134
2134
  const checkbox = /* @__PURE__ */ Object.assign(checkboxFn, {
2135
2135
  __recipe__: false,
2136
2136
  __name__: "checkbox",
@@ -2141,7 +2141,7 @@ const checkbox = /* @__PURE__ */ Object.assign(checkboxFn, {
2141
2141
  splitVariantProps(props) {
2142
2142
  return splitProps$1(props, checkboxVariantKeys);
2143
2143
  },
2144
- getVariantProps: getVariantProps$q
2144
+ getVariantProps: getVariantProps$s
2145
2145
  });
2146
2146
  const chipDefaultVariants = {
2147
2147
  "size": "md"
@@ -2179,7 +2179,7 @@ const chipVariantKeys = [
2179
2179
  "after",
2180
2180
  "dismissable"
2181
2181
  ];
2182
- const getVariantProps$p = (variants) => ({ ...chipDefaultVariants, ...compact(variants) });
2182
+ const getVariantProps$r = (variants) => ({ ...chipDefaultVariants, ...compact(variants) });
2183
2183
  const chip = /* @__PURE__ */ Object.assign(chipFn, {
2184
2184
  __recipe__: false,
2185
2185
  __name__: "chip",
@@ -2206,7 +2206,7 @@ const chip = /* @__PURE__ */ Object.assign(chipFn, {
2206
2206
  splitVariantProps(props) {
2207
2207
  return splitProps$1(props, chipVariantKeys);
2208
2208
  },
2209
- getVariantProps: getVariantProps$p
2209
+ getVariantProps: getVariantProps$r
2210
2210
  });
2211
2211
  const codeBlockDefaultVariants = {
2212
2212
  "tone": "default",
@@ -2275,7 +2275,7 @@ const codeBlockVariantKeys = [
2275
2275
  "collapsed",
2276
2276
  "actionGutter"
2277
2277
  ];
2278
- const getVariantProps$o = (variants) => ({ ...codeBlockDefaultVariants, ...compact(variants) });
2278
+ const getVariantProps$q = (variants) => ({ ...codeBlockDefaultVariants, ...compact(variants) });
2279
2279
  const codeBlock = /* @__PURE__ */ Object.assign(codeBlockFn, {
2280
2280
  __recipe__: false,
2281
2281
  __name__: "codeBlock",
@@ -2311,7 +2311,7 @@ const codeBlock = /* @__PURE__ */ Object.assign(codeBlockFn, {
2311
2311
  splitVariantProps(props) {
2312
2312
  return splitProps$1(props, codeBlockVariantKeys);
2313
2313
  },
2314
- getVariantProps: getVariantProps$o
2314
+ getVariantProps: getVariantProps$q
2315
2315
  });
2316
2316
  const dateMenusDefaultVariants = {};
2317
2317
  const dateMenusCompoundVariants = [];
@@ -2334,7 +2334,7 @@ const dateMenusFn = memo((props = {}) => {
2334
2334
  return Object.fromEntries(dateMenusSlotFns.map(([slotName, slotFn]) => [slotName, slotFn.recipeFn(props)]));
2335
2335
  });
2336
2336
  const dateMenusVariantKeys = [];
2337
- const getVariantProps$n = (variants) => ({ ...dateMenusDefaultVariants, ...compact(variants) });
2337
+ const getVariantProps$p = (variants) => ({ ...dateMenusDefaultVariants, ...compact(variants) });
2338
2338
  const dateMenus = /* @__PURE__ */ Object.assign(dateMenusFn, {
2339
2339
  __recipe__: false,
2340
2340
  __name__: "dateMenus",
@@ -2345,7 +2345,7 @@ const dateMenus = /* @__PURE__ */ Object.assign(dateMenusFn, {
2345
2345
  splitVariantProps(props) {
2346
2346
  return splitProps$1(props, dateMenusVariantKeys);
2347
2347
  },
2348
- getVariantProps: getVariantProps$n
2348
+ getVariantProps: getVariantProps$p
2349
2349
  });
2350
2350
  const dateTimeMenusDefaultVariants = {};
2351
2351
  const dateTimeMenusCompoundVariants = [];
@@ -2368,7 +2368,7 @@ const dateTimeMenusFn = memo((props = {}) => {
2368
2368
  return Object.fromEntries(dateTimeMenusSlotFns.map(([slotName, slotFn]) => [slotName, slotFn.recipeFn(props)]));
2369
2369
  });
2370
2370
  const dateTimeMenusVariantKeys = [];
2371
- const getVariantProps$m = (variants) => ({ ...dateTimeMenusDefaultVariants, ...compact(variants) });
2371
+ const getVariantProps$o = (variants) => ({ ...dateTimeMenusDefaultVariants, ...compact(variants) });
2372
2372
  const dateTimeMenus = /* @__PURE__ */ Object.assign(dateTimeMenusFn, {
2373
2373
  __recipe__: false,
2374
2374
  __name__: "dateTimeMenus",
@@ -2379,7 +2379,7 @@ const dateTimeMenus = /* @__PURE__ */ Object.assign(dateTimeMenusFn, {
2379
2379
  splitVariantProps(props) {
2380
2380
  return splitProps$1(props, dateTimeMenusVariantKeys);
2381
2381
  },
2382
- getVariantProps: getVariantProps$m
2382
+ getVariantProps: getVariantProps$o
2383
2383
  });
2384
2384
  const drawerDefaultVariants = {
2385
2385
  "side": "right",
@@ -2426,7 +2426,7 @@ const drawerVariantKeys = [
2426
2426
  "size",
2427
2427
  "scrollable"
2428
2428
  ];
2429
- const getVariantProps$l = (variants) => ({ ...drawerDefaultVariants, ...compact(variants) });
2429
+ const getVariantProps$n = (variants) => ({ ...drawerDefaultVariants, ...compact(variants) });
2430
2430
  const drawer = /* @__PURE__ */ Object.assign(drawerFn, {
2431
2431
  __recipe__: false,
2432
2432
  __name__: "drawer",
@@ -2453,7 +2453,7 @@ const drawer = /* @__PURE__ */ Object.assign(drawerFn, {
2453
2453
  splitVariantProps(props) {
2454
2454
  return splitProps$1(props, drawerVariantKeys);
2455
2455
  },
2456
- getVariantProps: getVariantProps$l
2456
+ getVariantProps: getVariantProps$n
2457
2457
  });
2458
2458
  const filterFieldDefaultVariants = {};
2459
2459
  const filterFieldCompoundVariants = [];
@@ -2500,7 +2500,7 @@ const filterFieldFn = memo((props = {}) => {
2500
2500
  return Object.fromEntries(filterFieldSlotFns.map(([slotName, slotFn]) => [slotName, slotFn.recipeFn(props)]));
2501
2501
  });
2502
2502
  const filterFieldVariantKeys = [];
2503
- const getVariantProps$k = (variants) => ({ ...filterFieldDefaultVariants, ...compact(variants) });
2503
+ const getVariantProps$m = (variants) => ({ ...filterFieldDefaultVariants, ...compact(variants) });
2504
2504
  const filterField = /* @__PURE__ */ Object.assign(filterFieldFn, {
2505
2505
  __recipe__: false,
2506
2506
  __name__: "filterField",
@@ -2511,7 +2511,7 @@ const filterField = /* @__PURE__ */ Object.assign(filterFieldFn, {
2511
2511
  splitVariantProps(props) {
2512
2512
  return splitProps$1(props, filterFieldVariantKeys);
2513
2513
  },
2514
- getVariantProps: getVariantProps$k
2514
+ getVariantProps: getVariantProps$m
2515
2515
  });
2516
2516
  const filterMenuDefaultVariants = {
2517
2517
  "layer": "elevated"
@@ -2550,7 +2550,7 @@ const filterMenuFn = memo((props = {}) => {
2550
2550
  const filterMenuVariantKeys = [
2551
2551
  "layer"
2552
2552
  ];
2553
- const getVariantProps$j = (variants) => ({ ...filterMenuDefaultVariants, ...compact(variants) });
2553
+ const getVariantProps$l = (variants) => ({ ...filterMenuDefaultVariants, ...compact(variants) });
2554
2554
  const filterMenu = /* @__PURE__ */ Object.assign(filterMenuFn, {
2555
2555
  __recipe__: false,
2556
2556
  __name__: "filterMenu",
@@ -2566,7 +2566,7 @@ const filterMenu = /* @__PURE__ */ Object.assign(filterMenuFn, {
2566
2566
  splitVariantProps(props) {
2567
2567
  return splitProps$1(props, filterMenuVariantKeys);
2568
2568
  },
2569
- getVariantProps: getVariantProps$j
2569
+ getVariantProps: getVariantProps$l
2570
2570
  });
2571
2571
  const filterTokenDefaultVariants = {};
2572
2572
  const filterTokenCompoundVariants = [];
@@ -2613,7 +2613,7 @@ const filterTokenFn = memo((props = {}) => {
2613
2613
  return Object.fromEntries(filterTokenSlotFns.map(([slotName, slotFn]) => [slotName, slotFn.recipeFn(props)]));
2614
2614
  });
2615
2615
  const filterTokenVariantKeys = [];
2616
- const getVariantProps$i = (variants) => ({ ...filterTokenDefaultVariants, ...compact(variants) });
2616
+ const getVariantProps$k = (variants) => ({ ...filterTokenDefaultVariants, ...compact(variants) });
2617
2617
  const filterToken = /* @__PURE__ */ Object.assign(filterTokenFn, {
2618
2618
  __recipe__: false,
2619
2619
  __name__: "filterToken",
@@ -2624,7 +2624,7 @@ const filterToken = /* @__PURE__ */ Object.assign(filterTokenFn, {
2624
2624
  splitVariantProps(props) {
2625
2625
  return splitProps$1(props, filterTokenVariantKeys);
2626
2626
  },
2627
- getVariantProps: getVariantProps$i
2627
+ getVariantProps: getVariantProps$k
2628
2628
  });
2629
2629
  const formFieldDefaultVariants = {
2630
2630
  "layout": "default",
@@ -2653,7 +2653,7 @@ const formFieldVariantKeys = [
2653
2653
  "layout",
2654
2654
  "size"
2655
2655
  ];
2656
- const getVariantProps$h = (variants) => ({ ...formFieldDefaultVariants, ...compact(variants) });
2656
+ const getVariantProps$j = (variants) => ({ ...formFieldDefaultVariants, ...compact(variants) });
2657
2657
  const formField = /* @__PURE__ */ Object.assign(formFieldFn, {
2658
2658
  __recipe__: false,
2659
2659
  __name__: "formField",
@@ -2675,7 +2675,7 @@ const formField = /* @__PURE__ */ Object.assign(formFieldFn, {
2675
2675
  splitVariantProps(props) {
2676
2676
  return splitProps$1(props, formFieldVariantKeys);
2677
2677
  },
2678
- getVariantProps: getVariantProps$h
2678
+ getVariantProps: getVariantProps$j
2679
2679
  });
2680
2680
  const iconButtonDefaultVariants = {
2681
2681
  "variant": "standard",
@@ -2704,7 +2704,7 @@ const iconButtonVariantKeys = [
2704
2704
  "variant",
2705
2705
  "size"
2706
2706
  ];
2707
- const getVariantProps$g = (variants) => ({ ...iconButtonDefaultVariants, ...compact(variants) });
2707
+ const getVariantProps$i = (variants) => ({ ...iconButtonDefaultVariants, ...compact(variants) });
2708
2708
  const iconButton = /* @__PURE__ */ Object.assign(iconButtonFn, {
2709
2709
  __recipe__: false,
2710
2710
  __name__: "iconButton",
@@ -2732,7 +2732,7 @@ const iconButton = /* @__PURE__ */ Object.assign(iconButtonFn, {
2732
2732
  splitVariantProps(props) {
2733
2733
  return splitProps$1(props, iconButtonVariantKeys);
2734
2734
  },
2735
- getVariantProps: getVariantProps$g
2735
+ getVariantProps: getVariantProps$i
2736
2736
  });
2737
2737
  const inlineNoteDefaultVariants = {
2738
2738
  "tone": "info"
@@ -2759,7 +2759,7 @@ const inlineNoteFn = memo((props = {}) => {
2759
2759
  const inlineNoteVariantKeys = [
2760
2760
  "tone"
2761
2761
  ];
2762
- const getVariantProps$f = (variants) => ({ ...inlineNoteDefaultVariants, ...compact(variants) });
2762
+ const getVariantProps$h = (variants) => ({ ...inlineNoteDefaultVariants, ...compact(variants) });
2763
2763
  const inlineNote = /* @__PURE__ */ Object.assign(inlineNoteFn, {
2764
2764
  __recipe__: false,
2765
2765
  __name__: "inlineNote",
@@ -2778,7 +2778,7 @@ const inlineNote = /* @__PURE__ */ Object.assign(inlineNoteFn, {
2778
2778
  splitVariantProps(props) {
2779
2779
  return splitProps$1(props, inlineNoteVariantKeys);
2780
2780
  },
2781
- getVariantProps: getVariantProps$f
2781
+ getVariantProps: getVariantProps$h
2782
2782
  });
2783
2783
  const kbdDefaultVariants = {
2784
2784
  "variant": "default"
@@ -2801,7 +2801,7 @@ const kbdFn = memo((props = {}) => {
2801
2801
  const kbdVariantKeys = [
2802
2802
  "variant"
2803
2803
  ];
2804
- const getVariantProps$e = (variants) => ({ ...kbdDefaultVariants, ...compact(variants) });
2804
+ const getVariantProps$g = (variants) => ({ ...kbdDefaultVariants, ...compact(variants) });
2805
2805
  const kbd = /* @__PURE__ */ Object.assign(kbdFn, {
2806
2806
  __recipe__: false,
2807
2807
  __name__: "kbd",
@@ -2817,7 +2817,7 @@ const kbd = /* @__PURE__ */ Object.assign(kbdFn, {
2817
2817
  splitVariantProps(props) {
2818
2818
  return splitProps$1(props, kbdVariantKeys);
2819
2819
  },
2820
- getVariantProps: getVariantProps$e
2820
+ getVariantProps: getVariantProps$g
2821
2821
  });
2822
2822
  const listItemGroupDefaultVariants = {
2823
2823
  "density": "compact"
@@ -2844,7 +2844,7 @@ const listItemGroupFn = memo((props = {}) => {
2844
2844
  const listItemGroupVariantKeys = [
2845
2845
  "density"
2846
2846
  ];
2847
- const getVariantProps$d = (variants) => ({ ...listItemGroupDefaultVariants, ...compact(variants) });
2847
+ const getVariantProps$f = (variants) => ({ ...listItemGroupDefaultVariants, ...compact(variants) });
2848
2848
  const listItemGroup = /* @__PURE__ */ Object.assign(listItemGroupFn, {
2849
2849
  __recipe__: false,
2850
2850
  __name__: "listItemGroup",
@@ -2861,7 +2861,7 @@ const listItemGroup = /* @__PURE__ */ Object.assign(listItemGroupFn, {
2861
2861
  splitVariantProps(props) {
2862
2862
  return splitProps$1(props, listItemGroupVariantKeys);
2863
2863
  },
2864
- getVariantProps: getVariantProps$d
2864
+ getVariantProps: getVariantProps$f
2865
2865
  });
2866
2866
  const listItemDefaultVariants = {
2867
2867
  "variant": "default",
@@ -2921,7 +2921,7 @@ const listItemVariantKeys = [
2921
2921
  "iconBefore",
2922
2922
  "iconAfter"
2923
2923
  ];
2924
- const getVariantProps$c = (variants) => ({ ...listItemDefaultVariants, ...compact(variants) });
2924
+ const getVariantProps$e = (variants) => ({ ...listItemDefaultVariants, ...compact(variants) });
2925
2925
  const listItem = /* @__PURE__ */ Object.assign(listItemFn, {
2926
2926
  __recipe__: false,
2927
2927
  __name__: "listItem",
@@ -2956,7 +2956,7 @@ const listItem = /* @__PURE__ */ Object.assign(listItemFn, {
2956
2956
  splitVariantProps(props) {
2957
2957
  return splitProps$1(props, listItemVariantKeys);
2958
2958
  },
2959
- getVariantProps: getVariantProps$c
2959
+ getVariantProps: getVariantProps$e
2960
2960
  });
2961
2961
  const menuDefaultVariants = {
2962
2962
  "density": "compact",
@@ -3003,7 +3003,7 @@ const menuVariantKeys = [
3003
3003
  "panel",
3004
3004
  "scrollable"
3005
3005
  ];
3006
- const getVariantProps$b = (variants) => ({ ...menuDefaultVariants, ...compact(variants) });
3006
+ const getVariantProps$d = (variants) => ({ ...menuDefaultVariants, ...compact(variants) });
3007
3007
  const menu = /* @__PURE__ */ Object.assign(menuFn, {
3008
3008
  __recipe__: false,
3009
3009
  __name__: "menu",
@@ -3030,7 +3030,7 @@ const menu = /* @__PURE__ */ Object.assign(menuFn, {
3030
3030
  splitVariantProps(props) {
3031
3031
  return splitProps$1(props, menuVariantKeys);
3032
3032
  },
3033
- getVariantProps: getVariantProps$b
3033
+ getVariantProps: getVariantProps$d
3034
3034
  });
3035
3035
  const modalDefaultVariants = {
3036
3036
  "size": "md",
@@ -3079,7 +3079,7 @@ const modalVariantKeys = [
3079
3079
  "size",
3080
3080
  "position"
3081
3081
  ];
3082
- const getVariantProps$a = (variants) => ({ ...modalDefaultVariants, ...compact(variants) });
3082
+ const getVariantProps$c = (variants) => ({ ...modalDefaultVariants, ...compact(variants) });
3083
3083
  const modal = /* @__PURE__ */ Object.assign(modalFn, {
3084
3084
  __recipe__: false,
3085
3085
  __name__: "modal",
@@ -3103,7 +3103,7 @@ const modal = /* @__PURE__ */ Object.assign(modalFn, {
3103
3103
  splitVariantProps(props) {
3104
3104
  return splitProps$1(props, modalVariantKeys);
3105
3105
  },
3106
- getVariantProps: getVariantProps$a
3106
+ getVariantProps: getVariantProps$c
3107
3107
  });
3108
3108
  const pageBannerDefaultVariants = {
3109
3109
  "tone": "info"
@@ -3138,7 +3138,7 @@ const pageBannerFn = memo((props = {}) => {
3138
3138
  const pageBannerVariantKeys = [
3139
3139
  "tone"
3140
3140
  ];
3141
- const getVariantProps$9 = (variants) => ({ ...pageBannerDefaultVariants, ...compact(variants) });
3141
+ const getVariantProps$b = (variants) => ({ ...pageBannerDefaultVariants, ...compact(variants) });
3142
3142
  const pageBanner = /* @__PURE__ */ Object.assign(pageBannerFn, {
3143
3143
  __recipe__: false,
3144
3144
  __name__: "pageBanner",
@@ -3157,6 +3157,148 @@ const pageBanner = /* @__PURE__ */ Object.assign(pageBannerFn, {
3157
3157
  splitVariantProps(props) {
3158
3158
  return splitProps$1(props, pageBannerVariantKeys);
3159
3159
  },
3160
+ getVariantProps: getVariantProps$b
3161
+ });
3162
+ const popoverDefaultVariants = {
3163
+ "size": "md",
3164
+ "interaction": "rich",
3165
+ "layer": "elevated"
3166
+ };
3167
+ const popoverCompoundVariants = [];
3168
+ const popoverSlotNames = [
3169
+ [
3170
+ "content",
3171
+ "popover__content"
3172
+ ],
3173
+ [
3174
+ "header",
3175
+ "popover__header"
3176
+ ],
3177
+ [
3178
+ "title",
3179
+ "popover__title"
3180
+ ],
3181
+ [
3182
+ "titleIcon",
3183
+ "popover__titleIcon"
3184
+ ],
3185
+ [
3186
+ "description",
3187
+ "popover__description"
3188
+ ],
3189
+ [
3190
+ "body",
3191
+ "popover__body"
3192
+ ],
3193
+ [
3194
+ "media",
3195
+ "popover__media"
3196
+ ],
3197
+ [
3198
+ "footer",
3199
+ "popover__footer"
3200
+ ],
3201
+ [
3202
+ "close",
3203
+ "popover__close"
3204
+ ],
3205
+ [
3206
+ "trigger",
3207
+ "popover__trigger"
3208
+ ]
3209
+ ];
3210
+ const popoverSlotFns = /* @__PURE__ */ popoverSlotNames.map(([slotName, slotKey]) => [slotName, createRecipe(slotKey, popoverDefaultVariants, getSlotCompoundVariant(popoverCompoundVariants, slotName))]);
3211
+ const popoverFn = memo((props = {}) => {
3212
+ return Object.fromEntries(popoverSlotFns.map(([slotName, slotFn]) => [slotName, slotFn.recipeFn(props)]));
3213
+ });
3214
+ const popoverVariantKeys = [
3215
+ "interaction",
3216
+ "layer",
3217
+ "size",
3218
+ "tone"
3219
+ ];
3220
+ const getVariantProps$a = (variants) => ({ ...popoverDefaultVariants, ...compact(variants) });
3221
+ const popover = /* @__PURE__ */ Object.assign(popoverFn, {
3222
+ __recipe__: false,
3223
+ __name__: "popover",
3224
+ raw: (props) => props,
3225
+ classNameMap: {},
3226
+ variantKeys: popoverVariantKeys,
3227
+ variantMap: {
3228
+ "interaction": [
3229
+ "definition",
3230
+ "rich"
3231
+ ],
3232
+ "layer": [
3233
+ "elevated",
3234
+ "modalFloating"
3235
+ ],
3236
+ "size": [
3237
+ "sm",
3238
+ "md",
3239
+ "lg"
3240
+ ],
3241
+ "tone": [
3242
+ "note",
3243
+ "tip",
3244
+ "warning",
3245
+ "important",
3246
+ "caution"
3247
+ ]
3248
+ },
3249
+ splitVariantProps(props) {
3250
+ return splitProps$1(props, popoverVariantKeys);
3251
+ },
3252
+ getVariantProps: getVariantProps$a
3253
+ });
3254
+ const printPreviewDefaultVariants = {};
3255
+ const printPreviewCompoundVariants = [];
3256
+ const printPreviewSlotNames = [
3257
+ [
3258
+ "root",
3259
+ "printPreview__root"
3260
+ ],
3261
+ [
3262
+ "stack",
3263
+ "printPreview__stack"
3264
+ ],
3265
+ [
3266
+ "page",
3267
+ "printPreview__page"
3268
+ ],
3269
+ [
3270
+ "sheet",
3271
+ "printPreview__sheet"
3272
+ ],
3273
+ [
3274
+ "overlay",
3275
+ "printPreview__overlay"
3276
+ ],
3277
+ [
3278
+ "marginArea",
3279
+ "printPreview__marginArea"
3280
+ ],
3281
+ [
3282
+ "margins",
3283
+ "printPreview__margins"
3284
+ ]
3285
+ ];
3286
+ const printPreviewSlotFns = /* @__PURE__ */ printPreviewSlotNames.map(([slotName, slotKey]) => [slotName, createRecipe(slotKey, printPreviewDefaultVariants, getSlotCompoundVariant(printPreviewCompoundVariants, slotName))]);
3287
+ const printPreviewFn = memo((props = {}) => {
3288
+ return Object.fromEntries(printPreviewSlotFns.map(([slotName, slotFn]) => [slotName, slotFn.recipeFn(props)]));
3289
+ });
3290
+ const printPreviewVariantKeys = [];
3291
+ const getVariantProps$9 = (variants) => ({ ...printPreviewDefaultVariants, ...compact(variants) });
3292
+ const printPreview = /* @__PURE__ */ Object.assign(printPreviewFn, {
3293
+ __recipe__: false,
3294
+ __name__: "printPreview",
3295
+ raw: (props) => props,
3296
+ classNameMap: {},
3297
+ variantKeys: printPreviewVariantKeys,
3298
+ variantMap: {},
3299
+ splitVariantProps(props) {
3300
+ return splitProps$1(props, printPreviewVariantKeys);
3301
+ },
3160
3302
  getVariantProps: getVariantProps$9
3161
3303
  });
3162
3304
  const radioDefaultVariants = {};
@@ -15364,10 +15506,10 @@ function tokenVar(path, fallback) {
15364
15506
  }
15365
15507
  token.var = tokenVar;
15366
15508
  const createOverlayMiddleware = (options = {}) => {
15367
- const { offset: offset$12 = 4, shiftPadding = 8, extras = [] } = options;
15509
+ const { offset: offset$12 = 4, shiftPadding = 8, flipOptions, extras = [] } = options;
15368
15510
  return [
15369
15511
  offset(offset$12),
15370
- flip(),
15512
+ flip(flipOptions),
15371
15513
  shift({ padding: shiftPadding }),
15372
15514
  ...extras
15373
15515
  ];
@@ -15638,6 +15780,7 @@ const defaultLocaleLabels = {
15638
15780
  dismiss: "Dismiss",
15639
15781
  closeDialog: "Close dialog",
15640
15782
  closeDrawer: "Close drawer",
15783
+ closePopover: "Close",
15641
15784
  removeItem: (item) => `Remove ${item}`,
15642
15785
  removeFilter: (filter) => `Remove filter: ${filter}`,
15643
15786
  switchToTheme: (nextTheme) => `Switch to ${nextTheme} theme`,
@@ -15712,14 +15855,14 @@ const LocaleContext = createContext({
15712
15855
  function useLocale() {
15713
15856
  return useContext(LocaleContext);
15714
15857
  }
15715
- const toneIconNames$3 = {
15858
+ const toneIconNames$4 = {
15716
15859
  info: "info",
15717
15860
  success: "success",
15718
15861
  warning: "warning",
15719
15862
  danger: "error",
15720
15863
  neutral: "info"
15721
15864
  };
15722
- const toneIconColors$2 = {
15865
+ const toneIconColors$3 = {
15723
15866
  info: "icon.info",
15724
15867
  success: "icon.success",
15725
15868
  warning: "icon.warning",
@@ -15741,7 +15884,7 @@ const Alert = (props) => {
15741
15884
  } = props;
15742
15885
  const [className, otherProps] = splitProps(rest);
15743
15886
  const classes = alert({ tone });
15744
- const iconName = toneIconNames$3[tone];
15887
+ const iconName = toneIconNames$4[tone];
15745
15888
  const hasActions = Boolean(primaryAction ?? secondaryAction);
15746
15889
  return /* @__PURE__ */ jsxs(
15747
15890
  Box,
@@ -15756,7 +15899,7 @@ const Alert = (props) => {
15756
15899
  {
15757
15900
  name: iconName,
15758
15901
  size: "20",
15759
- fill: toneIconColors$2[tone],
15902
+ fill: toneIconColors$3[tone],
15760
15903
  "aria-hidden": "true"
15761
15904
  }
15762
15905
  ) }),
@@ -23505,14 +23648,14 @@ const FormField = (props) => {
23505
23648
  }
23506
23649
  );
23507
23650
  };
23508
- const toneIconNames$2 = {
23651
+ const toneIconNames$3 = {
23509
23652
  info: "info",
23510
23653
  success: "success",
23511
23654
  warning: "warning",
23512
23655
  danger: "error",
23513
23656
  neutral: "info"
23514
23657
  };
23515
- const toneIconColors$1 = {
23658
+ const toneIconColors$2 = {
23516
23659
  info: "icon.info",
23517
23660
  success: "icon.success",
23518
23661
  warning: "icon.warning",
@@ -23530,7 +23673,7 @@ const InlineNote = (props) => {
23530
23673
  const { tone = "info", children, ...rest } = props;
23531
23674
  const [className, otherProps] = splitProps(rest);
23532
23675
  const classes = inlineNote({ tone });
23533
- const iconName = toneIconNames$2[tone];
23676
+ const iconName = toneIconNames$3[tone];
23534
23677
  return /* @__PURE__ */ jsxs(
23535
23678
  Box,
23536
23679
  {
@@ -23543,7 +23686,7 @@ const InlineNote = (props) => {
23543
23686
  {
23544
23687
  name: iconName,
23545
23688
  size: "16",
23546
- fill: toneIconColors$1[tone],
23689
+ fill: toneIconColors$2[tone],
23547
23690
  "aria-hidden": "true"
23548
23691
  }
23549
23692
  ) }),
@@ -23896,7 +24039,7 @@ const ConfirmationModal = (props) => {
23896
24039
  }
23897
24040
  );
23898
24041
  };
23899
- const toneIconNames$1 = {
24042
+ const toneIconNames$2 = {
23900
24043
  info: "info",
23901
24044
  success: "success",
23902
24045
  warning: "warning",
@@ -23922,7 +24065,7 @@ const PageBanner = (props) => {
23922
24065
  const [className, otherProps] = splitProps(rest);
23923
24066
  const classes = pageBanner({ tone });
23924
24067
  const isBold = emphasis === "bold";
23925
- const iconName = toneIconNames$1[tone];
24068
+ const iconName = toneIconNames$2[tone];
23926
24069
  const iconColor = isBold ? "icon.inverse" : subtleIconColors[tone];
23927
24070
  const textColor = isBold ? "text.inverse" : "text";
23928
24071
  const hasActions = Boolean(primaryAction ?? secondaryAction);
@@ -23945,6 +24088,216 @@ const PageBanner = (props) => {
23945
24088
  }
23946
24089
  );
23947
24090
  };
24091
+ const CSS_PIXELS_PER_UNIT = {
24092
+ in: 96,
24093
+ mm: 96 / 25.4,
24094
+ pt: 96 / 72
24095
+ };
24096
+ const toCssPixels = (value, unit) => value * CSS_PIXELS_PER_UNIT[unit];
24097
+ const resolvePageBox = (size2, orientation, margins = 0) => {
24098
+ let width = toCssPixels(size2.width, size2.unit);
24099
+ let height = toCssPixels(size2.height, size2.unit);
24100
+ const isLandscape = width > height;
24101
+ if (orientation === "landscape" && !isLandscape || orientation === "portrait" && isLandscape) {
24102
+ [width, height] = [height, width];
24103
+ }
24104
+ const sides = typeof margins === "number" ? { top: margins, right: margins, bottom: margins, left: margins } : margins;
24105
+ return {
24106
+ width,
24107
+ height,
24108
+ margins: {
24109
+ top: toCssPixels(sides.top, size2.unit),
24110
+ right: toCssPixels(sides.right, size2.unit),
24111
+ bottom: toCssPixels(sides.bottom, size2.unit),
24112
+ left: toCssPixels(sides.left, size2.unit)
24113
+ }
24114
+ };
24115
+ };
24116
+ const computeScale = (fit, available, largestPage) => {
24117
+ if (typeof fit === "number") return fit;
24118
+ if (!available || !largestPage) return null;
24119
+ if (available.width <= 0 || largestPage.width <= 0) return null;
24120
+ const widthScale = available.width / largestPage.width;
24121
+ if (fit === "width") return widthScale;
24122
+ const heightScale = available.height / largestPage.height;
24123
+ return Math.min(widthScale, heightScale);
24124
+ };
24125
+ const PrintPreviewContext = createContext(null);
24126
+ const PrintPageContext = createContext(
24127
+ null
24128
+ );
24129
+ const PrintPreview = (props) => {
24130
+ const { fit = "page", children, ref, ...rest } = props;
24131
+ const [className, otherProps] = splitProps(rest);
24132
+ const classes = useMemo(() => printPreview(), []);
24133
+ const rootRef = useRef(null);
24134
+ const [available, setAvailable] = useState(null);
24135
+ const [pages, setPages] = useState(() => /* @__PURE__ */ new Map());
24136
+ const setRootRef = useCallback(
24137
+ (node) => {
24138
+ rootRef.current = node;
24139
+ if (typeof ref === "function") ref(node);
24140
+ else if (ref) ref.current = node;
24141
+ },
24142
+ [ref]
24143
+ );
24144
+ useLayoutEffect(() => {
24145
+ const node = rootRef.current;
24146
+ if (!node) return;
24147
+ const measure = () => {
24148
+ const style = getComputedStyle(node);
24149
+ const width = node.clientWidth - parseFloat(style.paddingLeft) - parseFloat(style.paddingRight);
24150
+ const height = node.clientHeight - parseFloat(style.paddingTop) - parseFloat(style.paddingBottom);
24151
+ setAvailable(
24152
+ (current) => (current == null ? void 0 : current.width) === width && current.height === height ? current : { width, height }
24153
+ );
24154
+ };
24155
+ measure();
24156
+ const observer = new ResizeObserver(measure);
24157
+ observer.observe(node);
24158
+ return () => observer.disconnect();
24159
+ }, []);
24160
+ const registerPage = useCallback((id, size2) => {
24161
+ setPages((current) => {
24162
+ const existing = current.get(id);
24163
+ if ((existing == null ? void 0 : existing.width) === size2.width && existing.height === size2.height) {
24164
+ return current;
24165
+ }
24166
+ const next = new Map(current);
24167
+ next.set(id, size2);
24168
+ return next;
24169
+ });
24170
+ }, []);
24171
+ const unregisterPage = useCallback((id) => {
24172
+ setPages((current) => {
24173
+ if (!current.has(id)) return current;
24174
+ const next = new Map(current);
24175
+ next.delete(id);
24176
+ return next;
24177
+ });
24178
+ }, []);
24179
+ const largestPage = useMemo(() => {
24180
+ if (pages.size === 0) return null;
24181
+ let width = 0;
24182
+ let height = 0;
24183
+ pages.forEach((size2) => {
24184
+ width = Math.max(width, size2.width);
24185
+ height = Math.max(height, size2.height);
24186
+ });
24187
+ return { width, height };
24188
+ }, [pages]);
24189
+ const scale = computeScale(fit, available, largestPage);
24190
+ const contextValue = useMemo(
24191
+ () => ({ scale, registerPage, unregisterPage, classes }),
24192
+ [scale, registerPage, unregisterPage, classes]
24193
+ );
24194
+ return /* @__PURE__ */ jsx(PrintPreviewContext.Provider, { value: contextValue, children: /* @__PURE__ */ jsx(
24195
+ Box,
24196
+ {
24197
+ ...dsComponent("PrintPreview"),
24198
+ ref: setRootRef,
24199
+ tabIndex: 0,
24200
+ className: cx(classes.root, className),
24201
+ ...otherProps,
24202
+ children: /* @__PURE__ */ jsx(Box, { className: classes.stack, children })
24203
+ }
24204
+ ) });
24205
+ };
24206
+ const PrintPage = (props) => {
24207
+ const {
24208
+ size: size2,
24209
+ orientation,
24210
+ margins,
24211
+ showMargins = false,
24212
+ overlay,
24213
+ children,
24214
+ style,
24215
+ ...rest
24216
+ } = props;
24217
+ const [className, otherProps] = splitProps(rest);
24218
+ const preview = useContext(PrintPreviewContext);
24219
+ const previewClasses = preview == null ? void 0 : preview.classes;
24220
+ const classes = useMemo(
24221
+ () => previewClasses ?? printPreview(),
24222
+ [previewClasses]
24223
+ );
24224
+ const id = useId$1();
24225
+ const { width, height, unit } = size2;
24226
+ const sides = typeof margins === "object" ? margins : {
24227
+ top: margins ?? 0,
24228
+ right: margins ?? 0,
24229
+ bottom: margins ?? 0,
24230
+ left: margins ?? 0
24231
+ };
24232
+ const { top, right, bottom, left } = sides;
24233
+ const pageBox = useMemo(
24234
+ () => resolvePageBox({ width, height, unit }, orientation, {
24235
+ top,
24236
+ right,
24237
+ bottom,
24238
+ left
24239
+ }),
24240
+ [width, height, unit, orientation, top, right, bottom, left]
24241
+ );
24242
+ const registerPage = preview == null ? void 0 : preview.registerPage;
24243
+ const unregisterPage = preview == null ? void 0 : preview.unregisterPage;
24244
+ useLayoutEffect(() => {
24245
+ if (!registerPage || !unregisterPage) return;
24246
+ registerPage(id, { width: pageBox.width, height: pageBox.height });
24247
+ return () => unregisterPage(id);
24248
+ }, [id, pageBox.width, pageBox.height, registerPage, unregisterPage]);
24249
+ const measuring = preview !== null && preview.scale === null;
24250
+ const scale = preview ? preview.scale ?? 1 : 1;
24251
+ const pageContext = useMemo(
24252
+ () => ({ ...pageBox, scale }),
24253
+ [pageBox, scale]
24254
+ );
24255
+ const pageStyle = {
24256
+ "--print-scale": scale,
24257
+ "--print-page-w": `${String(pageBox.width)}px`,
24258
+ "--print-page-h": `${String(pageBox.height)}px`,
24259
+ "--print-margin-top": `${String(pageBox.margins.top)}px`,
24260
+ "--print-margin-right": `${String(pageBox.margins.right)}px`,
24261
+ "--print-margin-bottom": `${String(pageBox.margins.bottom)}px`,
24262
+ "--print-margin-left": `${String(pageBox.margins.left)}px`,
24263
+ ...style
24264
+ };
24265
+ return /* @__PURE__ */ jsx(PrintPageContext.Provider, { value: pageContext, children: /* @__PURE__ */ jsxs(
24266
+ Box,
24267
+ {
24268
+ ...dsComponent("PrintPage"),
24269
+ className: cx(classes.page, className),
24270
+ "data-measuring": measuring || void 0,
24271
+ style: pageStyle,
24272
+ ...otherProps,
24273
+ children: [
24274
+ /* @__PURE__ */ jsxs(Box, { className: classes.sheet, children: [
24275
+ children,
24276
+ overlay !== void 0 && /* @__PURE__ */ jsx(Box, { className: classes.overlay, children: overlay })
24277
+ ] }),
24278
+ showMargins && /* @__PURE__ */ jsxs(Fragment, { children: [
24279
+ /* @__PURE__ */ jsx(Box, { className: classes.marginArea, "aria-hidden": true }),
24280
+ /* @__PURE__ */ jsx(Box, { className: classes.margins, "aria-hidden": true })
24281
+ ] })
24282
+ ]
24283
+ }
24284
+ ) });
24285
+ };
24286
+ const pageSizes = {
24287
+ letter: { width: 8.5, height: 11, unit: "in" },
24288
+ legal: { width: 8.5, height: 14, unit: "in" },
24289
+ tabloid: { width: 11, height: 17, unit: "in" },
24290
+ halfLetter: { width: 5.5, height: 8.5, unit: "in" },
24291
+ a3: { width: 297, height: 420, unit: "mm" },
24292
+ a4: { width: 210, height: 297, unit: "mm" },
24293
+ a5: { width: 148, height: 210, unit: "mm" },
24294
+ a6: { width: 105, height: 148, unit: "mm" },
24295
+ label4x6: { width: 4, height: 6, unit: "in" },
24296
+ label4x3: { width: 4, height: 3, unit: "in" },
24297
+ label4x2: { width: 4, height: 2, unit: "in" },
24298
+ label3x2: { width: 3, height: 2, unit: "in" },
24299
+ label2x1: { width: 2, height: 1, unit: "in" }
24300
+ };
23948
24301
  const Radio = (props) => {
23949
24302
  const fieldContext = useFieldContext();
23950
24303
  const {
@@ -26433,14 +26786,14 @@ const ThemeSwitcher = () => {
26433
26786
  }
26434
26787
  );
26435
26788
  };
26436
- const toneIconNames = {
26789
+ const toneIconNames$1 = {
26437
26790
  info: "info",
26438
26791
  success: "success",
26439
26792
  warning: "warning",
26440
26793
  danger: "error",
26441
26794
  neutral: "info"
26442
26795
  };
26443
- const toneIconColors = {
26796
+ const toneIconColors$1 = {
26444
26797
  info: "icon.info",
26445
26798
  success: "icon.success",
26446
26799
  warning: "icon.warning",
@@ -26496,7 +26849,7 @@ const Toast = (props) => {
26496
26849
  );
26497
26850
  };
26498
26851
  }, [duration, paused, state]);
26499
- const iconName = toneIconNames[tone];
26852
+ const iconName = toneIconNames$1[tone];
26500
26853
  const hasActions = Boolean(primaryAction ?? secondaryAction);
26501
26854
  return /* @__PURE__ */ jsxs(
26502
26855
  Box,
@@ -26533,7 +26886,7 @@ const Toast = (props) => {
26533
26886
  {
26534
26887
  name: iconName,
26535
26888
  size: "20",
26536
- fill: toneIconColors[tone],
26889
+ fill: toneIconColors$1[tone],
26537
26890
  "aria-hidden": "true"
26538
26891
  }
26539
26892
  ) }),
@@ -26799,6 +27152,420 @@ const Skeleton = (props) => {
26799
27152
  }
26800
27153
  );
26801
27154
  };
27155
+ const PopoverContext = createContext(null);
27156
+ const usePopoverContext = () => {
27157
+ const context2 = useContext(PopoverContext);
27158
+ if (!context2) {
27159
+ throw new Error("Popover components must be used within a <Popover> root");
27160
+ }
27161
+ return context2;
27162
+ };
27163
+ const Popover = (props) => {
27164
+ const {
27165
+ children,
27166
+ interaction = "rich",
27167
+ open: openProp,
27168
+ defaultOpen = false,
27169
+ onOpenChange,
27170
+ placement = "bottom",
27171
+ offset: offset2 = 8,
27172
+ showArrow = true,
27173
+ size: size2 = "md",
27174
+ tone
27175
+ } = props;
27176
+ const [uncontrolledOpen, setUncontrolledOpen] = useState(defaultOpen);
27177
+ const isControlled = openProp !== void 0;
27178
+ const open = isControlled ? openProp : uncontrolledOpen;
27179
+ const setOpen = useCallback(
27180
+ (nextOpen) => {
27181
+ if (!isControlled) {
27182
+ setUncontrolledOpen(nextOpen);
27183
+ }
27184
+ onOpenChange == null ? void 0 : onOpenChange(nextOpen);
27185
+ },
27186
+ [isControlled, onOpenChange]
27187
+ );
27188
+ const arrowRef = useRef(null);
27189
+ const [titleId, setTitleId] = useState();
27190
+ const [descriptionId, setDescriptionId] = useState();
27191
+ const [hasAnchor, setHasAnchor] = useState(false);
27192
+ const isDefinition = interaction === "definition";
27193
+ const { refs, elements, floatingStyles, context: context2 } = useOverlayFloating({
27194
+ open,
27195
+ onOpenChange: setOpen,
27196
+ placement,
27197
+ middleware: createOverlayMiddleware({
27198
+ offset: offset2,
27199
+ flipOptions: { fallbackAxisSideDirection: "end" },
27200
+ extras: [arrow({ element: arrowRef })]
27201
+ })
27202
+ });
27203
+ const hover = useHover(context2, {
27204
+ enabled: isDefinition,
27205
+ move: false,
27206
+ delay: { open: 200, close: 150 },
27207
+ handleClose: safePolygon({ requireIntent: false })
27208
+ });
27209
+ const focus = useFocus(context2, { enabled: isDefinition });
27210
+ const click = useClick(context2, { enabled: !isDefinition });
27211
+ const dismiss = useDismiss(context2);
27212
+ const role = useRole(context2, {
27213
+ role: isDefinition ? "tooltip" : "dialog"
27214
+ });
27215
+ const { domReference } = elements;
27216
+ const { setReference } = refs;
27217
+ useEffect(() => {
27218
+ if (!hasAnchor && domReference) {
27219
+ setReference(domReference);
27220
+ }
27221
+ }, [hasAnchor, domReference, setReference]);
27222
+ const { getReferenceProps, getFloatingProps } = useInteractions([
27223
+ hover,
27224
+ focus,
27225
+ click,
27226
+ dismiss,
27227
+ role
27228
+ ]);
27229
+ const setReferenceRef = useCallback(
27230
+ (node) => {
27231
+ refs.setReference(node);
27232
+ },
27233
+ [refs]
27234
+ );
27235
+ const setFloatingRef = useCallback(
27236
+ (node) => {
27237
+ refs.setFloating(node);
27238
+ },
27239
+ [refs]
27240
+ );
27241
+ const contextValue = useMemo(
27242
+ () => ({
27243
+ open,
27244
+ setOpen,
27245
+ interaction,
27246
+ placement,
27247
+ offset: offset2,
27248
+ showArrow,
27249
+ size: size2,
27250
+ tone,
27251
+ floatingContext: context2,
27252
+ refs: {
27253
+ setReference: refs.setReference,
27254
+ setFloating: refs.setFloating,
27255
+ setPositionReference: refs.setPositionReference
27256
+ },
27257
+ floatingStyles,
27258
+ domReference: elements.domReference,
27259
+ getReferenceProps: (userProps) => getReferenceProps(userProps),
27260
+ getFloatingProps: (userProps) => getFloatingProps(userProps),
27261
+ arrowRef,
27262
+ titleId,
27263
+ setTitleId,
27264
+ descriptionId,
27265
+ setDescriptionId,
27266
+ hasAnchor,
27267
+ setHasAnchor,
27268
+ setReferenceRef,
27269
+ setFloatingRef
27270
+ }),
27271
+ [
27272
+ open,
27273
+ setOpen,
27274
+ interaction,
27275
+ placement,
27276
+ offset2,
27277
+ showArrow,
27278
+ size2,
27279
+ tone,
27280
+ context2,
27281
+ refs.setReference,
27282
+ refs.setFloating,
27283
+ refs.setPositionReference,
27284
+ floatingStyles,
27285
+ elements.domReference,
27286
+ getReferenceProps,
27287
+ getFloatingProps,
27288
+ titleId,
27289
+ descriptionId,
27290
+ hasAnchor,
27291
+ setReferenceRef,
27292
+ setFloatingRef
27293
+ ]
27294
+ );
27295
+ return /* @__PURE__ */ jsx(PopoverContext.Provider, { value: contextValue, children });
27296
+ };
27297
+ const PopoverTrigger = (props) => {
27298
+ const { children, ref, ...rest } = props;
27299
+ const [className, otherProps] = splitProps(rest);
27300
+ const { interaction, getReferenceProps, setReferenceRef } = usePopoverContext();
27301
+ const classes = popover({ interaction });
27302
+ const childArray = Children.toArray(children);
27303
+ const onlyChild = childArray.length === 1 ? childArray[0] : null;
27304
+ const childRefProp = isValidElement(onlyChild) ? onlyChild.props.ref : void 0;
27305
+ const mergedRef = useMergeRefs([childRefProp, ref, setReferenceRef]);
27306
+ if (isValidElement(onlyChild)) {
27307
+ const child = onlyChild;
27308
+ const referenceProps = getReferenceProps({
27309
+ ...otherProps,
27310
+ ...child.props
27311
+ });
27312
+ return cloneElement(child, {
27313
+ ...referenceProps,
27314
+ ref: mergedRef,
27315
+ className: cx(child.props.className, className) || void 0
27316
+ });
27317
+ }
27318
+ if (interaction === "rich") {
27319
+ return /* @__PURE__ */ jsx(
27320
+ Box,
27321
+ {
27322
+ as: "button",
27323
+ type: "button",
27324
+ ref: mergedRef,
27325
+ className: cx(classes.trigger, className),
27326
+ ...getReferenceProps(otherProps),
27327
+ children
27328
+ }
27329
+ );
27330
+ }
27331
+ return /* @__PURE__ */ jsx(
27332
+ Box,
27333
+ {
27334
+ as: "span",
27335
+ ref: mergedRef,
27336
+ tabIndex: 0,
27337
+ className: cx(classes.trigger, className),
27338
+ ...getReferenceProps(otherProps),
27339
+ children
27340
+ }
27341
+ );
27342
+ };
27343
+ const PopoverAnchor = (props) => {
27344
+ const {
27345
+ children,
27346
+ ref: consumerRef,
27347
+ ...rest
27348
+ } = props;
27349
+ const { refs, setHasAnchor } = usePopoverContext();
27350
+ useEffect(() => {
27351
+ setHasAnchor(true);
27352
+ return () => setHasAnchor(false);
27353
+ }, [setHasAnchor]);
27354
+ const childArray = Children.toArray(children);
27355
+ const onlyChild = childArray.length === 1 ? childArray[0] : null;
27356
+ const childRefProp = isValidElement(onlyChild) ? onlyChild.props.ref : void 0;
27357
+ const mergedRef = useMergeRefs([
27358
+ consumerRef,
27359
+ childRefProp,
27360
+ refs.setPositionReference
27361
+ ]);
27362
+ if (isValidElement(onlyChild)) {
27363
+ const child = onlyChild;
27364
+ return cloneElement(child, {
27365
+ ...rest,
27366
+ ref: mergedRef
27367
+ });
27368
+ }
27369
+ return /* @__PURE__ */ jsx(Box, { as: "span", display: "inline", ...rest, ref: mergedRef, children });
27370
+ };
27371
+ const PopoverContent = (props) => {
27372
+ const { children, ref, ...rest } = props;
27373
+ const [className, otherProps] = splitProps(rest);
27374
+ const {
27375
+ open,
27376
+ interaction,
27377
+ showArrow,
27378
+ size: size2,
27379
+ tone,
27380
+ floatingContext,
27381
+ floatingStyles,
27382
+ domReference,
27383
+ getFloatingProps,
27384
+ setFloatingRef,
27385
+ arrowRef,
27386
+ titleId,
27387
+ descriptionId
27388
+ } = usePopoverContext();
27389
+ const floatingLayer = useFloatingLayer();
27390
+ const mergedRef = useMergeRefs([ref, setFloatingRef]);
27391
+ const classes = popover({ size: size2, tone, layer: floatingLayer });
27392
+ const isRich = interaction === "rich";
27393
+ if (!open) {
27394
+ return null;
27395
+ }
27396
+ const arrowFill = token.var("colors.surface.overlay");
27397
+ const panel = /* @__PURE__ */ jsxs(
27398
+ Box,
27399
+ {
27400
+ ...dsComponent("PopoverContent"),
27401
+ ref: mergedRef,
27402
+ className: cx(classes.content, className),
27403
+ "aria-labelledby": titleId,
27404
+ "aria-describedby": descriptionId,
27405
+ ...getFloatingProps(otherProps),
27406
+ style: floatingStyles,
27407
+ children: [
27408
+ children,
27409
+ showArrow && /* @__PURE__ */ jsx(
27410
+ FloatingArrow,
27411
+ {
27412
+ ref: arrowRef,
27413
+ context: floatingContext,
27414
+ fill: arrowFill,
27415
+ stroke: token.var("colors.border"),
27416
+ strokeWidth: 1
27417
+ }
27418
+ )
27419
+ ]
27420
+ }
27421
+ );
27422
+ return /* @__PURE__ */ jsx(FloatingPortal, { children: /* @__PURE__ */ jsx(DsChainPortalRoot, { reference: domReference, children: isRich ? /* @__PURE__ */ jsx(
27423
+ FloatingFocusManager,
27424
+ {
27425
+ context: floatingContext,
27426
+ modal: true,
27427
+ returnFocus: true,
27428
+ children: panel
27429
+ }
27430
+ ) : panel }) });
27431
+ };
27432
+ const PopoverClose = (props) => {
27433
+ const { labels } = useLocale();
27434
+ const { altText = labels.closePopover, onClick, ...rest } = props;
27435
+ const [className, otherProps] = splitProps(rest);
27436
+ const { setOpen } = usePopoverContext();
27437
+ const classes = popover();
27438
+ return /* @__PURE__ */ jsx(
27439
+ IconButton,
27440
+ {
27441
+ variant: "ghost",
27442
+ size: "sm",
27443
+ iconName: "x",
27444
+ altText,
27445
+ "aria-label": altText,
27446
+ className: cx(classes.close, className),
27447
+ onClick: (event) => {
27448
+ onClick == null ? void 0 : onClick(event);
27449
+ setOpen(false);
27450
+ },
27451
+ ...otherProps
27452
+ }
27453
+ );
27454
+ };
27455
+ const PopoverHeader = (props) => {
27456
+ const { children, ...rest } = props;
27457
+ const [className, otherProps] = splitProps(rest);
27458
+ const classes = popover();
27459
+ return /* @__PURE__ */ jsx(Box, { className: cx(classes.header, className), ...otherProps, children });
27460
+ };
27461
+ const toneIconNames = {
27462
+ note: "note",
27463
+ tip: "info",
27464
+ warning: "warning",
27465
+ important: "flag",
27466
+ caution: "warning"
27467
+ };
27468
+ const toneIconColors = {
27469
+ note: "icon.subtle",
27470
+ tip: "icon.info",
27471
+ warning: "icon.warning",
27472
+ important: "icon.danger",
27473
+ caution: "icon.warning"
27474
+ };
27475
+ const PopoverTitle = (props) => {
27476
+ const { children, showToneIcon = true, id: idProp, ...rest } = props;
27477
+ const [className, otherProps] = splitProps(rest);
27478
+ const { tone, size: size2, setTitleId } = usePopoverContext();
27479
+ const generatedId = useId$1();
27480
+ const titleId = idProp ?? generatedId;
27481
+ const classes = popover({ size: size2, tone });
27482
+ useEffect(() => {
27483
+ setTitleId(titleId);
27484
+ return () => setTitleId(void 0);
27485
+ }, [setTitleId, titleId]);
27486
+ return /* @__PURE__ */ jsxs(
27487
+ Box,
27488
+ {
27489
+ as: "div",
27490
+ id: titleId,
27491
+ className: cx(classes.title, className),
27492
+ ...otherProps,
27493
+ children: [
27494
+ showToneIcon && tone && /* @__PURE__ */ jsx(Box, { className: classes.titleIcon, "aria-hidden": "true", children: /* @__PURE__ */ jsx(
27495
+ Icon,
27496
+ {
27497
+ name: toneIconNames[tone],
27498
+ size: "16",
27499
+ fill: toneIconColors[tone]
27500
+ }
27501
+ ) }),
27502
+ children
27503
+ ]
27504
+ }
27505
+ );
27506
+ };
27507
+ const PopoverDescription = (props) => {
27508
+ const { children, id: idProp, ...rest } = props;
27509
+ const [className, otherProps] = splitProps(rest);
27510
+ const { size: size2, setDescriptionId } = usePopoverContext();
27511
+ const generatedId = useId$1();
27512
+ const descriptionId = idProp ?? generatedId;
27513
+ const classes = popover({ size: size2 });
27514
+ useEffect(() => {
27515
+ setDescriptionId(descriptionId);
27516
+ return () => setDescriptionId(void 0);
27517
+ }, [descriptionId, setDescriptionId]);
27518
+ return /* @__PURE__ */ jsx(
27519
+ Box,
27520
+ {
27521
+ as: "div",
27522
+ id: descriptionId,
27523
+ className: cx(classes.description, className),
27524
+ ...otherProps,
27525
+ children
27526
+ }
27527
+ );
27528
+ };
27529
+ const PopoverBody = (props) => {
27530
+ const { children, ...rest } = props;
27531
+ const [className, otherProps] = splitProps(rest);
27532
+ const { size: size2 } = usePopoverContext();
27533
+ const classes = popover({ size: size2 });
27534
+ return /* @__PURE__ */ jsx(Box, { className: cx(classes.body, className), ...otherProps, children });
27535
+ };
27536
+ const PopoverMedia = (props) => {
27537
+ const { children, ...rest } = props;
27538
+ const [className, otherProps] = splitProps(rest);
27539
+ const classes = popover();
27540
+ return /* @__PURE__ */ jsx(Box, { className: cx(classes.media, className), ...otherProps, children });
27541
+ };
27542
+ const PopoverFooter = (props) => {
27543
+ const { children, ...rest } = props;
27544
+ const [className, otherProps] = splitProps(rest);
27545
+ const classes = popover();
27546
+ return /* @__PURE__ */ jsx(Box, { className: cx(classes.footer, className), ...otherProps, children });
27547
+ };
27548
+ const PopoverArrow = (props) => {
27549
+ const { fill, stroke } = props;
27550
+ const { floatingContext, arrowRef } = usePopoverContext();
27551
+ return /* @__PURE__ */ jsx(
27552
+ FloatingArrow,
27553
+ {
27554
+ ref: arrowRef,
27555
+ context: floatingContext,
27556
+ fill: fill ?? token.var("colors.surface.overlay"),
27557
+ stroke: stroke ?? token.var("colors.border"),
27558
+ strokeWidth: 1
27559
+ }
27560
+ );
27561
+ };
27562
+ const usePrintPage = () => {
27563
+ const context2 = useContext(PrintPageContext);
27564
+ if (!context2) {
27565
+ throw new Error("usePrintPage must be used within a <PrintPage>");
27566
+ }
27567
+ return context2;
27568
+ };
26802
27569
  const useToast = () => useToastApi();
26803
27570
  export {
26804
27571
  Alert,
@@ -26863,6 +27630,20 @@ export {
26863
27630
  ModalWrapper,
26864
27631
  Option,
26865
27632
  PageBanner,
27633
+ Popover,
27634
+ PopoverAnchor,
27635
+ PopoverArrow,
27636
+ PopoverBody,
27637
+ PopoverClose,
27638
+ PopoverContent,
27639
+ PopoverDescription,
27640
+ PopoverFooter,
27641
+ PopoverHeader,
27642
+ PopoverMedia,
27643
+ PopoverTitle,
27644
+ PopoverTrigger,
27645
+ PrintPage,
27646
+ PrintPreview,
26866
27647
  Radio,
26867
27648
  RadioGroup,
26868
27649
  RadioInput,
@@ -26901,6 +27682,7 @@ export {
26901
27682
  getHighlightedTextParts,
26902
27683
  hasMatchingItems,
26903
27684
  isItemMatch,
27685
+ pageSizes,
26904
27686
  splitProps,
26905
27687
  useChipGroup,
26906
27688
  useClipboard,
@@ -26917,6 +27699,8 @@ export {
26917
27699
  useMenuRootContext,
26918
27700
  useModalWrapperContext,
26919
27701
  useOverflowItems,
27702
+ usePopoverContext,
27703
+ usePrintPage,
26920
27704
  useTabPanelActive,
26921
27705
  useTabsContext,
26922
27706
  useTheme,