@automattic/charts 1.10.0 → 1.10.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.
package/dist/index.js CHANGED
@@ -10,21 +10,21 @@ import { addDays, differenceInCalendarWeeks, differenceInHours, differenceInYear
10
10
  import { Text, getStringWidth } from "@visx/text";
11
11
  import deepmerge from "deepmerge";
12
12
  import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
13
+ import { useTooltip, useTooltipInPortal } from "@visx/tooltip";
13
14
  import { createScale, getTicks, scaleBand, scaleOrdinal, scaleTime } from "@visx/scale";
14
15
  import { Group } from "@visx/group";
15
16
  import { LegendItem, LegendLabel, LegendOrdinal, LegendShape } from "@visx/legend";
17
+ import { __assign } from "tslib";
18
+ import { Icon, chevronRight } from "@wordpress/icons";
16
19
  import { LinearGradient } from "@visx/gradient";
17
20
  import { curveCatmullRom, curveLinear, curveMonotoneX } from "@visx/curve";
18
21
  import { useParentSize } from "@visx/responsive";
19
22
  import { Annotation, CircleSubject, Connector, HtmlLabel, Label, LineSubject } from "@visx/annotation";
20
23
  import { PatternCircles, PatternHexagons, PatternLines, PatternWaves } from "@visx/pattern";
21
- import { useTooltip, useTooltipInPortal } from "@visx/tooltip";
22
24
  import { Chart } from "react-google-charts";
23
25
  import DOMPurify from "dompurify";
24
- import { __assign } from "tslib";
25
26
  import _extends from "@babel/runtime/helpers/esm/extends";
26
27
  import "@babel/runtime/helpers/extends";
27
- import { Icon, chevronRight } from "@wordpress/icons";
28
28
  import { Pie } from "@visx/shape";
29
29
  //#region \0rolldown/runtime.js
30
30
  var __create = Object.create;
@@ -445,6 +445,22 @@ const lightenHexColor = (hex, blend) => {
445
445
  return `#${newR.toString(16).padStart(2, "0")}${newG.toString(16).padStart(2, "0")}${newB.toString(16).padStart(2, "0")}`;
446
446
  };
447
447
  /**
448
+ * Blend one hex color toward another, per-channel in sRGB.
449
+ *
450
+ * @param fromHex - Starting hex color, returned when blend is 0
451
+ * @param toHex - Target hex color, returned when blend is 1
452
+ * @param blend - Amount toward toHex, clamped to [0, 1]
453
+ * @return Blended hex color string
454
+ * @throws {Error} if either hex string is malformed
455
+ */
456
+ const mixHexColors = (fromHex, toHex, blend) => {
457
+ validateHexColor(fromHex);
458
+ validateHexColor(toHex);
459
+ const amount = Math.min(1, Math.max(0, blend));
460
+ const channel = (start, end) => Math.round(start + (end - start) * amount).toString(16).padStart(2, "0");
461
+ return `#${channel(parseInt(fromHex.slice(1, 3), 16), parseInt(toHex.slice(1, 3), 16))}${channel(parseInt(fromHex.slice(3, 5), 16), parseInt(toHex.slice(3, 5), 16))}${channel(parseInt(fromHex.slice(5, 7), 16), parseInt(toHex.slice(5, 7), 16))}`;
462
+ };
463
+ /**
448
464
  * WCAG relative luminance of a hex color (0 = black, 1 = white).
449
465
  *
450
466
  * @param hex - Hex color string (e.g., '#98C8DF')
@@ -879,6 +895,7 @@ const GlobalChartsProvider = ({ children, theme }) => {
879
895
  }
880
896
  return getChartColor(index, colorCache);
881
897
  }, [colorCache, groupToColorMap]);
898
+ const resolveThemeColor = useCallback((value) => value ? normalizeColorToHex(value, wrapperRef.current, resolveCssVariable) : "", []);
882
899
  const getElementStyles = useCallback(({ data, index, overrideColor, legendShape }) => {
883
900
  const isSeriesData = data && typeof data === "object" && "data" in data && "options" in data;
884
901
  const isPointPercentageData = data && typeof data === "object" && "value" in data && typeof data.value === "number" && !("data" in data);
@@ -921,6 +938,7 @@ const GlobalChartsProvider = ({ children, theme }) => {
921
938
  getChartData,
922
939
  theme: providerTheme,
923
940
  getElementStyles,
941
+ resolveThemeColor,
924
942
  toggleSeriesVisibility,
925
943
  isSeriesVisible,
926
944
  getHiddenSeries,
@@ -932,6 +950,7 @@ const GlobalChartsProvider = ({ children, theme }) => {
932
950
  getChartData,
933
951
  providerTheme,
934
952
  getElementStyles,
953
+ resolveThemeColor,
935
954
  toggleSeriesVisibility,
936
955
  isSeriesVisible,
937
956
  getHiddenSeries,
@@ -1140,7 +1159,9 @@ const useChartMargin = (height, options, data, theme, horizontal = false) => {
1140
1159
  };
1141
1160
  const yAxisOrientation = options.axis?.y?.orientation;
1142
1161
  const yAxisStyles = yAxisOrientation === "right" ? theme.axisStyles.y.right : theme.axisStyles.y.left;
1143
- const yMarginValue = (getLongestTickWidth(yTicks, options.axis?.y?.tickFormat, yAxisStyles.axisLabel) ?? DEFAULT_Y_TICK_WIDTH) + (yAxisStyles?.tickLength ?? 0);
1162
+ const yTickWidth = getLongestTickWidth(yTicks, options.axis?.y?.tickFormat, yAxisStyles.axisLabel);
1163
+ const yTickLabelFontSize = resolveFontSize(yAxisStyles?.tickLabel?.fontSize) || DEFAULT_FONT_SIZE;
1164
+ const yMarginValue = (yTickWidth ?? DEFAULT_Y_TICK_WIDTH) + (yAxisStyles?.tickLength ?? 0) + Math.ceil(yTickLabelFontSize * .25);
1144
1165
  if (yAxisOrientation === "right") defaultMargin.right = yMarginValue;
1145
1166
  else defaultMargin.left = yMarginValue;
1146
1167
  const xOrientation = options.axis?.x?.orientation === "top" ? "top" : "bottom";
@@ -1227,7 +1248,8 @@ function useTextTruncation(enabled = true) {
1227
1248
  }
1228
1249
  if (node && enabled) {
1229
1250
  const checkTruncation = () => {
1230
- setIsTruncated(node.scrollWidth > node.clientWidth);
1251
+ const truncated = node.scrollWidth > node.clientWidth;
1252
+ setIsTruncated(truncated);
1231
1253
  };
1232
1254
  checkTruncation();
1233
1255
  const resizeObserver = new ResizeObserver(checkTruncation);
@@ -1428,168 +1450,102 @@ const useGlobalChartsTheme = () => {
1428
1450
  return useContext(GlobalChartsContext)?.theme ?? defaultTheme;
1429
1451
  };
1430
1452
  //#endregion
1431
- //#region ../../../node_modules/.pnpm/@base-ui+utils@0.2.9_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/mergeObjects.js
1432
- function mergeObjects(a, b) {
1433
- if (a && !b) return a;
1434
- if (!a && b) return b;
1435
- if (a || b) return {
1436
- ...a,
1437
- ...b
1438
- };
1453
+ //#region ../../../node_modules/.pnpm/is-plain-object@5.0.0/node_modules/is-plain-object/dist/is-plain-object.mjs
1454
+ /*!
1455
+ * is-plain-object <https://github.com/jonschlinkert/is-plain-object>
1456
+ *
1457
+ * Copyright (c) 2014-2017, Jon Schlinkert.
1458
+ * Released under the MIT License.
1459
+ */
1460
+ function isObject(o) {
1461
+ return Object.prototype.toString.call(o) === "[object Object]";
1462
+ }
1463
+ function isPlainObject(o) {
1464
+ var ctor, prot;
1465
+ if (isObject(o) === false) return false;
1466
+ ctor = o.constructor;
1467
+ if (ctor === void 0) return true;
1468
+ prot = ctor.prototype;
1469
+ if (isObject(prot) === false) return false;
1470
+ if (prot.hasOwnProperty("isPrototypeOf") === false) return false;
1471
+ return true;
1439
1472
  }
1440
1473
  //#endregion
1441
- //#region ../../../node_modules/.pnpm/@base-ui+react@1.5.0_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/esm/merge-props/mergeProps.js
1442
- const EMPTY_PROPS = {};
1474
+ //#region ../../../node_modules/.pnpm/lower-case@2.0.2/node_modules/lower-case/dist.es2015/index.js
1443
1475
  /**
1444
- * Merges multiple sets of React props. It follows the Object.assign pattern where the rightmost object's fields overwrite
1445
- * the conflicting ones from others. This doesn't apply to event handlers, `className` and `style` props.
1446
- *
1447
- * Event handlers are merged and called in right-to-left order (rightmost handler executes first, leftmost last).
1448
- * For React synthetic events, the rightmost handler can prevent prior (left-positioned) handlers from executing
1449
- * by calling `event.preventBaseUIHandler()`. For non-synthetic events (custom events with primitive/object values),
1450
- * all handlers always execute without prevention capability.
1451
- *
1452
- * The `className` prop is merged by concatenating classes in right-to-left order (rightmost class appears first in the string).
1453
- * The `style` prop is merged with rightmost styles overwriting the prior ones.
1454
- *
1455
- * Props can either be provided as objects or as functions that take the previous props as an argument.
1456
- * The function will receive the merged props up to that point (going from left to right):
1457
- * so in the case of `(obj1, obj2, fn, obj3)`, `fn` will receive the merged props of `obj1` and `obj2`.
1458
- * The function is responsible for chaining event handlers if needed (that is, we don't run the merge logic).
1459
- *
1460
- * Event handlers returned by the functions are not automatically prevented when `preventBaseUIHandler` is called.
1461
- * They must check `event.baseUIHandlerPrevented` themselves and bail out if it's true.
1462
- *
1463
- * @important **`ref` is not merged.**
1464
- * @param a Props object to merge.
1465
- * @param b Props object to merge. The function will overwrite conflicting props from `a`.
1466
- * @param c Props object to merge. The function will overwrite conflicting props from previous parameters.
1467
- * @param d Props object to merge. The function will overwrite conflicting props from previous parameters.
1468
- * @param e Props object to merge. The function will overwrite conflicting props from previous parameters.
1469
- * @returns The merged props.
1470
- * @public
1476
+ * Lower case as a function.
1471
1477
  */
1472
- function mergeProps(a, b, c, d, e) {
1473
- if (!c && !d && !e && !a) return createInitialMergedProps(b);
1474
- let merged = createInitialMergedProps(a);
1475
- if (b) merged = mergeInto(merged, b);
1476
- if (c) merged = mergeInto(merged, c);
1477
- if (d) merged = mergeInto(merged, d);
1478
- if (e) merged = mergeInto(merged, e);
1479
- return merged;
1478
+ function lowerCase(str) {
1479
+ return str.toLowerCase();
1480
1480
  }
1481
+ //#endregion
1482
+ //#region ../../../node_modules/.pnpm/no-case@3.0.4/node_modules/no-case/dist.es2015/index.js
1483
+ var DEFAULT_SPLIT_REGEXP = [/([a-z0-9])([A-Z])/g, /([A-Z])([A-Z][a-z])/g];
1484
+ var DEFAULT_STRIP_REGEXP = /[^A-Z0-9]+/gi;
1481
1485
  /**
1482
- * Merges an arbitrary number of React props using the same logic as {@link mergeProps}.
1483
- * This function accepts an array of props instead of individual arguments.
1484
- *
1485
- * This has slightly lower performance than {@link mergeProps} due to accepting an array
1486
- * instead of a fixed number of arguments. Prefer {@link mergeProps} when merging 5 or
1487
- * fewer prop sets for better performance.
1488
- *
1489
- * @param props Array of props to merge.
1490
- * @returns The merged props.
1491
- * @see mergeProps
1492
- * @public
1486
+ * Normalize the string into something other libraries can manipulate easier.
1493
1487
  */
1494
- function mergePropsN(props) {
1495
- if (props.length === 0) return EMPTY_PROPS;
1496
- if (props.length === 1) return createInitialMergedProps(props[0]);
1497
- let merged = createInitialMergedProps(props[0]);
1498
- for (let i = 1; i < props.length; i += 1) merged = mergeInto(merged, props[i]);
1499
- return merged;
1500
- }
1501
- function createInitialMergedProps(inputProps) {
1502
- if (isPropsGetter(inputProps)) return { ...resolvePropsGetter(inputProps, EMPTY_PROPS) };
1503
- return copyInitialProps(inputProps);
1504
- }
1505
- function mergeInto(merged, inputProps) {
1506
- if (isPropsGetter(inputProps)) return resolvePropsGetter(inputProps, merged);
1507
- return mutablyMergeInto(merged, inputProps);
1508
- }
1509
- function copyInitialProps(inputProps) {
1510
- const copiedProps = { ...inputProps };
1511
- for (const propName in copiedProps) {
1512
- const propValue = copiedProps[propName];
1513
- if (isEventHandler(propName, propValue)) copiedProps[propName] = wrapEventHandler(propValue);
1514
- }
1515
- return copiedProps;
1488
+ function noCase(input, options) {
1489
+ if (options === void 0) options = {};
1490
+ var _a = options.splitRegexp, splitRegexp = _a === void 0 ? DEFAULT_SPLIT_REGEXP : _a, _b = options.stripRegexp, stripRegexp = _b === void 0 ? DEFAULT_STRIP_REGEXP : _b, _c = options.transform, transform = _c === void 0 ? lowerCase : _c, _d = options.delimiter, delimiter = _d === void 0 ? " " : _d;
1491
+ var result = replace$1(replace$1(input, splitRegexp, "$1\0$2"), stripRegexp, "\0");
1492
+ var start = 0;
1493
+ var end = result.length;
1494
+ while (result.charAt(start) === "\0") start++;
1495
+ while (result.charAt(end - 1) === "\0") end--;
1496
+ return result.slice(start, end).split("\0").map(transform).join(delimiter);
1516
1497
  }
1517
1498
  /**
1518
- * Merges two sets of props. In case of conflicts, the external props take precedence.
1499
+ * Replace `re` in the input string with the replacement value.
1519
1500
  */
1520
- function mutablyMergeInto(mergedProps, externalProps) {
1521
- if (!externalProps) return mergedProps;
1522
- for (const propName in externalProps) {
1523
- const externalPropValue = externalProps[propName];
1524
- switch (propName) {
1525
- case "style":
1526
- mergedProps[propName] = mergeObjects(mergedProps.style, externalPropValue);
1527
- break;
1528
- case "className":
1529
- mergedProps[propName] = mergeClassNames(mergedProps.className, externalPropValue);
1530
- break;
1531
- default: if (isEventHandler(propName, externalPropValue)) mergedProps[propName] = mergeEventHandlers(mergedProps[propName], externalPropValue);
1532
- else mergedProps[propName] = externalPropValue;
1533
- }
1534
- }
1535
- return mergedProps;
1501
+ function replace$1(input, re, value) {
1502
+ if (re instanceof RegExp) return input.replace(re, value);
1503
+ return re.reduce(function(input, re) {
1504
+ return input.replace(re, value);
1505
+ }, input);
1536
1506
  }
1537
- function isEventHandler(key, value) {
1538
- const code0 = key.charCodeAt(0);
1539
- const code1 = key.charCodeAt(1);
1540
- const code2 = key.charCodeAt(2);
1541
- return code0 === 111 && code1 === 110 && code2 >= 65 && code2 <= 90 && (typeof value === "function" || typeof value === "undefined");
1507
+ //#endregion
1508
+ //#region ../../../node_modules/.pnpm/dot-case@3.0.4/node_modules/dot-case/dist.es2015/index.js
1509
+ function dotCase(input, options) {
1510
+ if (options === void 0) options = {};
1511
+ return noCase(input, __assign({ delimiter: "." }, options));
1542
1512
  }
1543
- function isPropsGetter(inputProps) {
1544
- return typeof inputProps === "function";
1513
+ //#endregion
1514
+ //#region ../../../node_modules/.pnpm/param-case@3.0.4/node_modules/param-case/dist.es2015/index.js
1515
+ function paramCase(input, options) {
1516
+ if (options === void 0) options = {};
1517
+ return dotCase(input, __assign({ delimiter: "-" }, options));
1545
1518
  }
1546
- function resolvePropsGetter(inputProps, previousProps) {
1547
- if (isPropsGetter(inputProps)) return inputProps(previousProps);
1548
- return inputProps ?? EMPTY_PROPS;
1519
+ //#endregion
1520
+ //#region ../../../node_modules/.pnpm/@base-ui+utils@0.3.1_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/useRefWithInit.mjs
1521
+ const UNINITIALIZED = {};
1522
+ /**
1523
+ * A React.useRef() that is initialized with a function. Note that it accepts an optional
1524
+ * initialization argument, so the initialization function doesn't need to be an inline closure.
1525
+ *
1526
+ * @usage
1527
+ * const ref = useRefWithInit(sortColumns, columns)
1528
+ */
1529
+ function useRefWithInit(init, initArg) {
1530
+ const ref = React.useRef(UNINITIALIZED);
1531
+ if (ref.current === UNINITIALIZED) ref.current = init(initArg);
1532
+ return ref;
1549
1533
  }
1550
- function mergeEventHandlers(ourHandler, theirHandler) {
1551
- if (!theirHandler) return ourHandler;
1552
- if (!ourHandler) return wrapEventHandler(theirHandler);
1553
- return (...args) => {
1554
- const event = args[0];
1555
- if (isSyntheticEvent(event)) {
1556
- const baseUIEvent = event;
1557
- makeEventPreventable(baseUIEvent);
1558
- const result = theirHandler(...args);
1559
- if (!baseUIEvent.baseUIHandlerPrevented) ourHandler?.(...args);
1560
- return result;
1534
+ //#endregion
1535
+ //#region ../../../node_modules/.pnpm/@base-ui+utils@0.3.1_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/warn.mjs
1536
+ let set;
1537
+ if (process.env.NODE_ENV !== "production") set = /* @__PURE__ */ new Set();
1538
+ function warn(...messages) {
1539
+ if (process.env.NODE_ENV !== "production") {
1540
+ const messageKey = messages.join(" ");
1541
+ if (!set.has(messageKey)) {
1542
+ set.add(messageKey);
1543
+ console.warn(`Base UI: ${messageKey}`);
1561
1544
  }
1562
- const result = theirHandler(...args);
1563
- ourHandler?.(...args);
1564
- return result;
1565
- };
1566
- }
1567
- function wrapEventHandler(handler) {
1568
- if (!handler) return handler;
1569
- return (...args) => {
1570
- const event = args[0];
1571
- if (isSyntheticEvent(event)) makeEventPreventable(event);
1572
- return handler(...args);
1573
- };
1574
- }
1575
- function makeEventPreventable(event) {
1576
- event.preventBaseUIHandler = () => {
1577
- event.baseUIHandlerPrevented = true;
1578
- };
1579
- return event;
1580
- }
1581
- function mergeClassNames(ourClassName, theirClassName) {
1582
- if (theirClassName) {
1583
- if (ourClassName) return theirClassName + " " + ourClassName;
1584
- return theirClassName;
1585
1545
  }
1586
- return ourClassName;
1587
- }
1588
- function isSyntheticEvent(event) {
1589
- return event != null && typeof event === "object" && "nativeEvent" in event;
1590
1546
  }
1591
1547
  //#endregion
1592
- //#region ../../../node_modules/.pnpm/@base-ui+utils@0.2.9_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/formatErrorMessage.js
1548
+ //#region ../../../node_modules/.pnpm/@base-ui+utils@0.3.1_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/formatErrorMessage.mjs
1593
1549
  /**
1594
1550
  * Creates a formatErrorMessage function with a custom URL and prefix.
1595
1551
  * @param baseUrl - The base URL for the error page (e.g., 'https://base-ui.com/production-error')
@@ -1615,22 +1571,7 @@ function createFormatErrorMessage(baseUrl, prefix) {
1615
1571
  */
1616
1572
  const formatErrorMessage = createFormatErrorMessage("https://base-ui.com/production-error", "Base UI");
1617
1573
  //#endregion
1618
- //#region ../../../node_modules/.pnpm/@base-ui+utils@0.2.9_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/useRefWithInit.js
1619
- const UNINITIALIZED = {};
1620
- /**
1621
- * A React.useRef() that is initialized with a function. Note that it accepts an optional
1622
- * initialization argument, so the initialization function doesn't need to be an inline closure.
1623
- *
1624
- * @usage
1625
- * const ref = useRefWithInit(sortColumns, columns)
1626
- */
1627
- function useRefWithInit(init, initArg) {
1628
- const ref = React.useRef(UNINITIALIZED);
1629
- if (ref.current === UNINITIALIZED) ref.current = init(initArg);
1630
- return ref;
1631
- }
1632
- //#endregion
1633
- //#region ../../../node_modules/.pnpm/@base-ui+utils@0.2.9_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/useMergedRefs.js
1574
+ //#region ../../../node_modules/.pnpm/@base-ui+utils@0.3.1_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/useMergedRefs.mjs
1634
1575
  /**
1635
1576
  * Merges refs into a single memoized callback ref or `null`.
1636
1577
  * This makes sure multiple refs are updated together and have the same value.
@@ -1721,13 +1662,13 @@ function update(forkRef, refs) {
1721
1662
  };
1722
1663
  }
1723
1664
  //#endregion
1724
- //#region ../../../node_modules/.pnpm/@base-ui+utils@0.2.9_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/reactVersion.js
1665
+ //#region ../../../node_modules/.pnpm/@base-ui+utils@0.3.1_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/reactVersion.mjs
1725
1666
  const majorVersion = parseInt(React.version, 10);
1726
1667
  function isReactVersionAtLeast(reactVersionToCheck) {
1727
1668
  return majorVersion >= reactVersionToCheck;
1728
1669
  }
1729
1670
  //#endregion
1730
- //#region ../../../node_modules/.pnpm/@base-ui+utils@0.2.9_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/getReactElementRef.js
1671
+ //#region ../../../node_modules/.pnpm/@base-ui+utils@0.3.1_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/getReactElementRef.mjs
1731
1672
  /**
1732
1673
  * Extracts the `ref` from a React element, handling different React versions.
1733
1674
  */
@@ -1738,24 +1679,21 @@ function getReactElementRef(element) {
1738
1679
  return (isReactVersionAtLeast(19) ? propsWithRef?.ref : reactElement.ref) ?? null;
1739
1680
  }
1740
1681
  //#endregion
1741
- //#region ../../../node_modules/.pnpm/@base-ui+utils@0.2.9_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/esm/warn.js
1742
- let set;
1743
- if (process.env.NODE_ENV !== "production") set = /* @__PURE__ */ new Set();
1744
- function warn(...messages) {
1745
- if (process.env.NODE_ENV !== "production") {
1746
- const messageKey = messages.join(" ");
1747
- if (!set.has(messageKey)) {
1748
- set.add(messageKey);
1749
- console.warn(`Base UI: ${messageKey}`);
1750
- }
1751
- }
1752
- }
1753
- Object.freeze([]);
1754
- const EMPTY_OBJECT = Object.freeze({});
1755
- //#endregion
1756
- //#region ../../../node_modules/.pnpm/@base-ui+react@1.5.0_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/esm/internals/getStateAttributesProps.js
1757
- function getStateAttributesProps(state, customMapping) {
1758
- const props = {};
1682
+ //#region ../../../node_modules/.pnpm/@base-ui+utils@0.3.1_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/utils/mergeObjects.mjs
1683
+ function mergeObjects(a, b) {
1684
+ if (a && !b) return a;
1685
+ if (!a && b) return b;
1686
+ if (a || b) return {
1687
+ ...a,
1688
+ ...b
1689
+ };
1690
+ }
1691
+ Object.freeze([]);
1692
+ const EMPTY_OBJECT = Object.freeze({});
1693
+ //#endregion
1694
+ //#region ../../../node_modules/.pnpm/@base-ui+react@1.6.0_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/internals/getStateAttributesProps.mjs
1695
+ function getStateAttributesProps(state, customMapping) {
1696
+ const props = {};
1759
1697
  for (const key in state) {
1760
1698
  const value = state[key];
1761
1699
  if (customMapping?.hasOwnProperty(key)) {
@@ -1769,7 +1707,7 @@ function getStateAttributesProps(state, customMapping) {
1769
1707
  return props;
1770
1708
  }
1771
1709
  //#endregion
1772
- //#region ../../../node_modules/.pnpm/@base-ui+react@1.5.0_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/esm/utils/resolveClassName.js
1710
+ //#region ../../../node_modules/.pnpm/@base-ui+react@1.6.0_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/utils/resolveClassName.mjs
1773
1711
  /**
1774
1712
  * If the provided className is a string, it will be returned as is.
1775
1713
  * Otherwise, the function will call the className function with the state as the first argument.
@@ -1781,7 +1719,7 @@ function resolveClassName(className, state) {
1781
1719
  return typeof className === "function" ? className(state) : className;
1782
1720
  }
1783
1721
  //#endregion
1784
- //#region ../../../node_modules/.pnpm/@base-ui+react@1.5.0_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/esm/utils/resolveStyle.js
1722
+ //#region ../../../node_modules/.pnpm/@base-ui+react@1.6.0_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/utils/resolveStyle.mjs
1785
1723
  /**
1786
1724
  * If the provided style is an object, it will be returned as is.
1787
1725
  * Otherwise, the function will call the style function with the state as the first argument.
@@ -1793,7 +1731,158 @@ function resolveStyle(style, state) {
1793
1731
  return typeof style === "function" ? style(state) : style;
1794
1732
  }
1795
1733
  //#endregion
1796
- //#region ../../../node_modules/.pnpm/@base-ui+react@1.5.0_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/esm/internals/useRenderElement.js
1734
+ //#region ../../../node_modules/.pnpm/@base-ui+react@1.6.0_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/merge-props/mergeProps.mjs
1735
+ const EMPTY_PROPS = {};
1736
+ /**
1737
+ * Merges multiple sets of React props. It follows the Object.assign pattern where the rightmost object's fields overwrite
1738
+ * the conflicting ones from others. This doesn't apply to event handlers, `className` and `style` props.
1739
+ *
1740
+ * Event handlers are merged and called in right-to-left order (rightmost handler executes first, leftmost last).
1741
+ * For React synthetic events, the rightmost handler can prevent prior (left-positioned) handlers from executing
1742
+ * by calling `event.preventBaseUIHandler()`. For non-synthetic events (custom events with primitive/object values),
1743
+ * all handlers always execute without prevention capability.
1744
+ *
1745
+ * The `className` prop is merged by concatenating classes in right-to-left order (rightmost class appears first in the string).
1746
+ * The `style` prop is merged with rightmost styles overwriting the prior ones.
1747
+ *
1748
+ * Props can either be provided as objects or as functions that take the previous props as an argument.
1749
+ * The function will receive the merged props up to that point (going from left to right):
1750
+ * so in the case of `(obj1, obj2, fn, obj3)`, `fn` will receive the merged props of `obj1` and `obj2`.
1751
+ * The function is responsible for chaining event handlers if needed (that is, we don't run the merge logic).
1752
+ *
1753
+ * Event handlers returned by the functions are not automatically prevented when `preventBaseUIHandler` is called.
1754
+ * They must check `event.baseUIHandlerPrevented` themselves and bail out if it's true.
1755
+ *
1756
+ * @important **`ref` is not merged.**
1757
+ * @param a Props object to merge.
1758
+ * @param b Props object to merge. The function will overwrite conflicting props from `a`.
1759
+ * @param c Props object to merge. The function will overwrite conflicting props from previous parameters.
1760
+ * @param d Props object to merge. The function will overwrite conflicting props from previous parameters.
1761
+ * @param e Props object to merge. The function will overwrite conflicting props from previous parameters.
1762
+ * @returns The merged props.
1763
+ * @public
1764
+ */
1765
+ function mergeProps(a, b, c, d, e) {
1766
+ if (!c && !d && !e && !a) return createInitialMergedProps(b);
1767
+ let merged = createInitialMergedProps(a);
1768
+ if (b) merged = mergeInto(merged, b);
1769
+ if (c) merged = mergeInto(merged, c);
1770
+ if (d) merged = mergeInto(merged, d);
1771
+ if (e) merged = mergeInto(merged, e);
1772
+ return merged;
1773
+ }
1774
+ /**
1775
+ * Merges an arbitrary number of React props using the same logic as {@link mergeProps}.
1776
+ * This function accepts an array of props instead of individual arguments.
1777
+ *
1778
+ * This has slightly lower performance than {@link mergeProps} due to accepting an array
1779
+ * instead of a fixed number of arguments. Prefer {@link mergeProps} when merging 5 or
1780
+ * fewer prop sets for better performance.
1781
+ *
1782
+ * @param props Array of props to merge.
1783
+ * @returns The merged props.
1784
+ * @see mergeProps
1785
+ * @public
1786
+ */
1787
+ function mergePropsN(props) {
1788
+ if (props.length === 0) return EMPTY_PROPS;
1789
+ if (props.length === 1) return createInitialMergedProps(props[0]);
1790
+ let merged = createInitialMergedProps(props[0]);
1791
+ for (let i = 1; i < props.length; i += 1) merged = mergeInto(merged, props[i]);
1792
+ return merged;
1793
+ }
1794
+ function createInitialMergedProps(inputProps) {
1795
+ if (isPropsGetter(inputProps)) return { ...resolvePropsGetter(inputProps, EMPTY_PROPS) };
1796
+ return copyInitialProps(inputProps);
1797
+ }
1798
+ function mergeInto(merged, inputProps) {
1799
+ if (isPropsGetter(inputProps)) return resolvePropsGetter(inputProps, merged);
1800
+ return mutablyMergeInto(merged, inputProps);
1801
+ }
1802
+ function copyInitialProps(inputProps) {
1803
+ const copiedProps = { ...inputProps };
1804
+ for (const propName in copiedProps) {
1805
+ const propValue = copiedProps[propName];
1806
+ if (isEventHandler(propName, propValue)) copiedProps[propName] = wrapEventHandler(propValue);
1807
+ }
1808
+ return copiedProps;
1809
+ }
1810
+ /**
1811
+ * Merges two sets of props. In case of conflicts, the external props take precedence.
1812
+ */
1813
+ function mutablyMergeInto(mergedProps, externalProps) {
1814
+ if (!externalProps) return mergedProps;
1815
+ for (const propName in externalProps) {
1816
+ const externalPropValue = externalProps[propName];
1817
+ switch (propName) {
1818
+ case "style":
1819
+ mergedProps[propName] = mergeObjects(mergedProps.style, externalPropValue);
1820
+ break;
1821
+ case "className":
1822
+ mergedProps[propName] = mergeClassNames(mergedProps.className, externalPropValue);
1823
+ break;
1824
+ default: if (isEventHandler(propName, externalPropValue)) mergedProps[propName] = mergeEventHandlers(mergedProps[propName], externalPropValue);
1825
+ else mergedProps[propName] = externalPropValue;
1826
+ }
1827
+ }
1828
+ return mergedProps;
1829
+ }
1830
+ function isEventHandler(key, value) {
1831
+ const code0 = key.charCodeAt(0);
1832
+ const code1 = key.charCodeAt(1);
1833
+ const code2 = key.charCodeAt(2);
1834
+ return code0 === 111 && code1 === 110 && code2 >= 65 && code2 <= 90 && (typeof value === "function" || typeof value === "undefined");
1835
+ }
1836
+ function isPropsGetter(inputProps) {
1837
+ return typeof inputProps === "function";
1838
+ }
1839
+ function resolvePropsGetter(inputProps, previousProps) {
1840
+ if (isPropsGetter(inputProps)) return inputProps(previousProps);
1841
+ return inputProps ?? EMPTY_PROPS;
1842
+ }
1843
+ function mergeEventHandlers(ourHandler, theirHandler) {
1844
+ if (!theirHandler) return ourHandler;
1845
+ if (!ourHandler) return wrapEventHandler(theirHandler);
1846
+ return (...args) => {
1847
+ const event = args[0];
1848
+ if (isSyntheticEvent(event)) {
1849
+ const baseUIEvent = event;
1850
+ makeEventPreventable(baseUIEvent);
1851
+ const result = theirHandler(...args);
1852
+ if (!baseUIEvent.baseUIHandlerPrevented) ourHandler?.(...args);
1853
+ return result;
1854
+ }
1855
+ const result = theirHandler(...args);
1856
+ ourHandler?.(...args);
1857
+ return result;
1858
+ };
1859
+ }
1860
+ function wrapEventHandler(handler) {
1861
+ if (!handler) return handler;
1862
+ return (...args) => {
1863
+ const event = args[0];
1864
+ if (isSyntheticEvent(event)) makeEventPreventable(event);
1865
+ return handler(...args);
1866
+ };
1867
+ }
1868
+ function makeEventPreventable(event) {
1869
+ event.preventBaseUIHandler = () => {
1870
+ event.baseUIHandlerPrevented = true;
1871
+ };
1872
+ return event;
1873
+ }
1874
+ function mergeClassNames(ourClassName, theirClassName) {
1875
+ if (theirClassName) {
1876
+ if (ourClassName) return theirClassName + " " + ourClassName;
1877
+ return theirClassName;
1878
+ }
1879
+ return ourClassName;
1880
+ }
1881
+ function isSyntheticEvent(event) {
1882
+ return event != null && typeof event === "object" && "nativeEvent" in event;
1883
+ }
1884
+ //#endregion
1885
+ //#region ../../../node_modules/.pnpm/@base-ui+react@1.6.0_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/internals/useRenderElement.mjs
1797
1886
  /**
1798
1887
  * Renders a Base UI element.
1799
1888
  *
@@ -1882,7 +1971,7 @@ function renderTag(Tag, props) {
1882
1971
  return /*#__PURE__*/ React.createElement(Tag, props);
1883
1972
  }
1884
1973
  //#endregion
1885
- //#region ../../../node_modules/.pnpm/@base-ui+react@1.5.0_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/esm/use-render/useRender.js
1974
+ //#region ../../../node_modules/.pnpm/@base-ui+react@1.6.0_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@base-ui/react/use-render/useRender.mjs
1886
1975
  /**
1887
1976
  * Renders a Base UI element.
1888
1977
  *
@@ -1892,7 +1981,7 @@ function useRender(params) {
1892
1981
  return useRenderElement(params.defaultTagName ?? "div", params, params);
1893
1982
  }
1894
1983
  //#endregion
1895
- //#region ../../../node_modules/.pnpm/@wordpress+ui@0.17.0_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/ui/build-module/stack/stack.mjs
1984
+ //#region ../../../node_modules/.pnpm/@wordpress+ui@0.17.0_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/ui/build-module/text/text.mjs
1896
1985
  var STYLE_HASH_ATTRIBUTE$1 = "data-wp-hash";
1897
1986
  function getRuntime$1() {
1898
1987
  const globalScope = globalThis;
@@ -1948,35 +2037,39 @@ function registerStyle$1(hash, css) {
1948
2037
  runtime.styles.set(hash, css);
1949
2038
  for (const targetDocument of runtime.documents.keys()) injectStyle$1(targetDocument, hash, css);
1950
2039
  }
1951
- if (typeof process === "undefined" || process.env.NODE_ENV !== "test") registerStyle$1("32aba35fe1", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._19ce0419607e1896__stack{display:flex}}}");
1952
- var style_default$1 = { "stack": "_19ce0419607e1896__stack" };
1953
- var gapTokens = {
1954
- xs: "var(--wpds-dimension-gap-xs, 4px)",
1955
- sm: "var(--wpds-dimension-gap-sm, 8px)",
1956
- md: "var(--wpds-dimension-gap-md, 12px)",
1957
- lg: "var(--wpds-dimension-gap-lg, 16px)",
1958
- xl: "var(--wpds-dimension-gap-xl, 24px)",
1959
- "2xl": "var(--wpds-dimension-gap-2xl, 32px)",
1960
- "3xl": "var(--wpds-dimension-gap-3xl, 40px)"
2040
+ if (typeof process === "undefined" || process.env.NODE_ENV !== "test") registerStyle$1("0c5702ddca", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._83ed8a8da5dd50ea__text{margin:0}._14437cfb77831647__heading-2xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-medium,499);--_gcd-p-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-p-line-height:var(--wpds-typography-line-height-2xl,40px);font-size:var(--wpds-typography-font-size-2xl,32px);line-height:var(--wpds-typography-line-height-2xl,40px)}._14437cfb77831647__heading-2xl,._3c78b7fa9b4072dd__heading-xl{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,\"Segoe UI\",\"Roboto\",\"Oxygen-Sans\",\"Ubuntu\",\"Cantarell\",\"Helvetica Neue\",sans-serif);font-weight:var(--wpds-typography-font-weight-medium,499)}._3c78b7fa9b4072dd__heading-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-medium,499);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-md,24px)}.aa58f227716bcde2__heading-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-medium,499);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-lg,15px)}.aa58f227716bcde2__heading-lg,.fc4da56d8dfe52c4__heading-md{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,\"Segoe UI\",\"Roboto\",\"Oxygen-Sans\",\"Ubuntu\",\"Cantarell\",\"Helvetica Neue\",sans-serif);font-weight:var(--wpds-typography-font-weight-medium,499);line-height:var(--wpds-typography-line-height-sm,20px)}.fc4da56d8dfe52c4__heading-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-medium,499);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px)}.a9b78c7c82e8dff7__heading-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-medium,499);--_gcd-p-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,\"Segoe UI\",\"Roboto\",\"Oxygen-Sans\",\"Ubuntu\",\"Cantarell\",\"Helvetica Neue\",sans-serif);font-size:var(--wpds-typography-font-size-xs,11px);font-weight:var(--wpds-typography-font-weight-medium,499);line-height:var(--wpds-typography-line-height-xs,16px);text-transform:uppercase}._305ff559e52180d5__body-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-regular,400);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-xl,32px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-xl,32px)}._305ff559e52180d5__body-xl,.ca1aa3fc2029e958__body-lg{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,\"Segoe UI\",\"Roboto\",\"Oxygen-Sans\",\"Ubuntu\",\"Cantarell\",\"Helvetica Neue\",sans-serif);font-weight:var(--wpds-typography-font-weight-regular,400)}.ca1aa3fc2029e958__body-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-regular,400);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-lg,15px);line-height:var(--wpds-typography-line-height-md,24px)}._131101940be12424__body-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-regular,400);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px);line-height:var(--wpds-typography-line-height-sm,20px)}._0e8d87a42c1f75fa__body-sm,._131101940be12424__body-md{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,\"Segoe UI\",\"Roboto\",\"Oxygen-Sans\",\"Ubuntu\",\"Cantarell\",\"Helvetica Neue\",sans-serif);font-weight:var(--wpds-typography-font-weight-regular,400)}._0e8d87a42c1f75fa__body-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-regular,400);--_gcd-p-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-size:var(--wpds-typography-font-size-sm,12px);line-height:var(--wpds-typography-line-height-xs,16px)}}}");
2041
+ var style_default$1 = {
2042
+ "text": "_83ed8a8da5dd50ea__text",
2043
+ "heading-2xl": "_14437cfb77831647__heading-2xl",
2044
+ "heading-xl": "_3c78b7fa9b4072dd__heading-xl",
2045
+ "heading-lg": "aa58f227716bcde2__heading-lg",
2046
+ "heading-md": "fc4da56d8dfe52c4__heading-md",
2047
+ "heading-sm": "a9b78c7c82e8dff7__heading-sm",
2048
+ "body-xl": "_305ff559e52180d5__body-xl",
2049
+ "body-lg": "ca1aa3fc2029e958__body-lg",
2050
+ "body-md": "_131101940be12424__body-md",
2051
+ "body-sm": "_0e8d87a42c1f75fa__body-sm"
1961
2052
  };
1962
- var Stack = forwardRef$1(function Stack2({ direction, gap, align, justify, wrap, render, ...props }, ref) {
2053
+ if (typeof process === "undefined" || process.env.NODE_ENV !== "test") registerStyle$1("d390e935a7", "._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-medium,499));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}");
2054
+ var global_css_defense_default = {
2055
+ "button": "_6defc79820e382c6__button",
2056
+ "input": "d2cff2e5dea83bd1__input",
2057
+ "textarea": "_547d86373d02e108__textarea",
2058
+ "div": "_8c15fd0ed9f28ba4__div",
2059
+ "p": "_43cec3e1eec1066d__p",
2060
+ "heading": "e97669c6d9a38497__heading",
2061
+ "a": "_2c0831b0499dbd6e__a"
2062
+ };
2063
+ var Text$1 = forwardRef$1(function Text2({ variant = "body-md", render, className, ...props }, ref) {
1963
2064
  return useRender({
1964
2065
  render,
2066
+ defaultTagName: "span",
1965
2067
  ref,
1966
- props: mergeProps(props, {
1967
- style: {
1968
- gap: gap && gapTokens[gap],
1969
- alignItems: align,
1970
- justifyContent: justify,
1971
- flexDirection: direction,
1972
- flexWrap: wrap
1973
- },
1974
- className: style_default$1.stack
1975
- })
2068
+ props: mergeProps(props, { className: clsx(style_default$1.text, global_css_defense_default.heading, global_css_defense_default.p, style_default$1[variant], className) })
1976
2069
  });
1977
2070
  });
1978
2071
  //#endregion
1979
- //#region ../../../node_modules/.pnpm/@wordpress+ui@0.17.0_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/ui/build-module/text/text.mjs
2072
+ //#region ../../../node_modules/.pnpm/@wordpress+ui@0.17.0_@types+react@18.3.28_date-fns@4.1.0_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/ui/build-module/stack/stack.mjs
1980
2073
  var STYLE_HASH_ATTRIBUTE = "data-wp-hash";
1981
2074
  function getRuntime() {
1982
2075
  const globalScope = globalThis;
@@ -2032,35 +2125,31 @@ function registerStyle(hash, css) {
2032
2125
  runtime.styles.set(hash, css);
2033
2126
  for (const targetDocument of runtime.documents.keys()) injectStyle(targetDocument, hash, css);
2034
2127
  }
2035
- if (typeof process === "undefined" || process.env.NODE_ENV !== "test") registerStyle("0c5702ddca", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._83ed8a8da5dd50ea__text{margin:0}._14437cfb77831647__heading-2xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-medium,499);--_gcd-p-font-size:var(--wpds-typography-font-size-2xl,32px);--_gcd-p-line-height:var(--wpds-typography-line-height-2xl,40px);font-size:var(--wpds-typography-font-size-2xl,32px);line-height:var(--wpds-typography-line-height-2xl,40px)}._14437cfb77831647__heading-2xl,._3c78b7fa9b4072dd__heading-xl{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,\"Segoe UI\",\"Roboto\",\"Oxygen-Sans\",\"Ubuntu\",\"Cantarell\",\"Helvetica Neue\",sans-serif);font-weight:var(--wpds-typography-font-weight-medium,499)}._3c78b7fa9b4072dd__heading-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-medium,499);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-md,24px)}.aa58f227716bcde2__heading-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-medium,499);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-lg,15px)}.aa58f227716bcde2__heading-lg,.fc4da56d8dfe52c4__heading-md{font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,\"Segoe UI\",\"Roboto\",\"Oxygen-Sans\",\"Ubuntu\",\"Cantarell\",\"Helvetica Neue\",sans-serif);font-weight:var(--wpds-typography-font-weight-medium,499);line-height:var(--wpds-typography-line-height-sm,20px)}.fc4da56d8dfe52c4__heading-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-medium,499);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px)}.a9b78c7c82e8dff7__heading-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-medium,499);--_gcd-p-font-size:var(--wpds-typography-font-size-xs,11px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-family:var(--wpds-typography-font-family-heading,-apple-system,system-ui,\"Segoe UI\",\"Roboto\",\"Oxygen-Sans\",\"Ubuntu\",\"Cantarell\",\"Helvetica Neue\",sans-serif);font-size:var(--wpds-typography-font-size-xs,11px);font-weight:var(--wpds-typography-font-weight-medium,499);line-height:var(--wpds-typography-line-height-xs,16px);text-transform:uppercase}._305ff559e52180d5__body-xl{--_gcd-heading-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-regular,400);--_gcd-p-font-size:var(--wpds-typography-font-size-xl,20px);--_gcd-p-line-height:var(--wpds-typography-line-height-xl,32px);font-size:var(--wpds-typography-font-size-xl,20px);line-height:var(--wpds-typography-line-height-xl,32px)}._305ff559e52180d5__body-xl,.ca1aa3fc2029e958__body-lg{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,\"Segoe UI\",\"Roboto\",\"Oxygen-Sans\",\"Ubuntu\",\"Cantarell\",\"Helvetica Neue\",sans-serif);font-weight:var(--wpds-typography-font-weight-regular,400)}.ca1aa3fc2029e958__body-lg{--_gcd-heading-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-regular,400);--_gcd-p-font-size:var(--wpds-typography-font-size-lg,15px);--_gcd-p-line-height:var(--wpds-typography-line-height-md,24px);font-size:var(--wpds-typography-font-size-lg,15px);line-height:var(--wpds-typography-line-height-md,24px)}._131101940be12424__body-md{--_gcd-heading-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-regular,400);--_gcd-p-font-size:var(--wpds-typography-font-size-md,13px);--_gcd-p-line-height:var(--wpds-typography-line-height-sm,20px);font-size:var(--wpds-typography-font-size-md,13px);line-height:var(--wpds-typography-line-height-sm,20px)}._0e8d87a42c1f75fa__body-sm,._131101940be12424__body-md{font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,\"Segoe UI\",\"Roboto\",\"Oxygen-Sans\",\"Ubuntu\",\"Cantarell\",\"Helvetica Neue\",sans-serif);font-weight:var(--wpds-typography-font-weight-regular,400)}._0e8d87a42c1f75fa__body-sm{--_gcd-heading-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-heading-font-weight:var(--wpds-typography-font-weight-regular,400);--_gcd-p-font-size:var(--wpds-typography-font-size-sm,12px);--_gcd-p-line-height:var(--wpds-typography-line-height-xs,16px);font-size:var(--wpds-typography-font-size-sm,12px);line-height:var(--wpds-typography-line-height-xs,16px)}}}");
2036
- var style_default = {
2037
- "text": "_83ed8a8da5dd50ea__text",
2038
- "heading-2xl": "_14437cfb77831647__heading-2xl",
2039
- "heading-xl": "_3c78b7fa9b4072dd__heading-xl",
2040
- "heading-lg": "aa58f227716bcde2__heading-lg",
2041
- "heading-md": "fc4da56d8dfe52c4__heading-md",
2042
- "heading-sm": "a9b78c7c82e8dff7__heading-sm",
2043
- "body-xl": "_305ff559e52180d5__body-xl",
2044
- "body-lg": "ca1aa3fc2029e958__body-lg",
2045
- "body-md": "_131101940be12424__body-md",
2046
- "body-sm": "_0e8d87a42c1f75fa__body-sm"
2047
- };
2048
- if (typeof process === "undefined" || process.env.NODE_ENV !== "test") registerStyle("d390e935a7", "._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-input-box-sizing,border-box);font-family:var(--_gcd-input-font-family,inherit);font-size:var(--_gcd-input-font-size,inherit);font-weight:var(--_gcd-input-font-weight,inherit);margin:var(--_gcd-input-margin,0);&:is(textarea,[type=text],[type=password],[type=color],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){background-color:var(--_gcd-input-background-color,transparent);border:var(--_gcd-input-border,none);border-radius:var(--_gcd-input-border-radius,0);box-shadow:var(--_gcd-input-box-shadow,0 0 0 transparent);color:var(--_gcd-input-color,var(--wpds-color-foreground-interactive-neutral,#1e1e1e));&:focus{border-color:var(--_gcd-input-border-color-focus,var(--wp-admin-theme-color));box-shadow:var(--_gcd-input-box-shadow-focus,none);outline:var(--_gcd-input-outline-focus,none)}&:disabled{background:var(--_gcd-input-background-disabled,transparent);border-color:var(--_gcd-input-border-color-disabled,transparent);box-shadow:var(--_gcd-input-box-shadow-disabled,none);color:var(--_gcd-input-color-disabled,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}&::placeholder{color:var(--_gcd-input-placeholder-color,var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d))}}&:is(textarea,[type=text],[type=password],[type=date],[type=datetime],[type=datetime-local],[type=email],[type=month],[type=number],[type=search],[type=tel],[type=time],[type=url],[type=week]){line-height:var(--_gcd-input-line-height,inherit);min-height:var(--_gcd-input-min-height,auto);padding:var(--_gcd-input-padding,0)}}._547d86373d02e108__textarea{box-sizing:var(--_gcd-textarea-box-sizing,border-box);overflow:var(--_gcd-textarea-overflow,auto);resize:var(--_gcd-textarea-resize,block)}._8c15fd0ed9f28ba4__div{outline:var(--_gcd-div-outline,0 solid transparent)}p._43cec3e1eec1066d__p{font-size:var(--_gcd-p-font-size,13px);line-height:var(--_gcd-p-line-height,1.5);margin:var(--_gcd-p-margin,0)}:is(h1,h2,h3,h4,h5,h6).e97669c6d9a38497__heading{color:var(--_gcd-heading-color,var(--wpds-color-foreground-content-neutral,#1e1e1e));font-size:var(--_gcd-heading-font-size,inherit);font-weight:var(--_gcd-heading-font-weight,var(--wpds-typography-font-weight-medium,499));margin:var(--_gcd-heading-margin,0)}._2c0831b0499dbd6e__a,._2c0831b0499dbd6e__a:is(:hover,:focus,:active){border-radius:var(--_gcd-a-border-radius,0);box-shadow:var(--_gcd-a-box-shadow,none);color:var(--_gcd-a-color,inherit);outline:var(--_gcd-a-outline,0 solid transparent);transition:var(--_gcd-a-transition,none)}");
2049
- var global_css_defense_default = {
2050
- "button": "_6defc79820e382c6__button",
2051
- "input": "d2cff2e5dea83bd1__input",
2052
- "textarea": "_547d86373d02e108__textarea",
2053
- "div": "_8c15fd0ed9f28ba4__div",
2054
- "p": "_43cec3e1eec1066d__p",
2055
- "heading": "e97669c6d9a38497__heading",
2056
- "a": "_2c0831b0499dbd6e__a"
2128
+ if (typeof process === "undefined" || process.env.NODE_ENV !== "test") registerStyle("32aba35fe1", "@layer wp-ui{@layer utilities, components, compositions, overrides;@layer components{._19ce0419607e1896__stack{display:flex}}}");
2129
+ var style_default = { "stack": "_19ce0419607e1896__stack" };
2130
+ var gapTokens = {
2131
+ xs: "var(--wpds-dimension-gap-xs, 4px)",
2132
+ sm: "var(--wpds-dimension-gap-sm, 8px)",
2133
+ md: "var(--wpds-dimension-gap-md, 12px)",
2134
+ lg: "var(--wpds-dimension-gap-lg, 16px)",
2135
+ xl: "var(--wpds-dimension-gap-xl, 24px)",
2136
+ "2xl": "var(--wpds-dimension-gap-2xl, 32px)",
2137
+ "3xl": "var(--wpds-dimension-gap-3xl, 40px)"
2057
2138
  };
2058
- var Text$1 = forwardRef$1(function Text2({ variant = "body-md", render, className, ...props }, ref) {
2139
+ var Stack = forwardRef$1(function Stack2({ direction, gap, align, justify, wrap, render, ...props }, ref) {
2059
2140
  return useRender({
2060
2141
  render,
2061
- defaultTagName: "span",
2062
2142
  ref,
2063
- props: mergeProps(props, { className: clsx(style_default.text, global_css_defense_default.heading, global_css_defense_default.p, style_default[variant], className) })
2143
+ props: mergeProps(props, {
2144
+ style: {
2145
+ gap: gap && gapTokens[gap],
2146
+ alignItems: align,
2147
+ justifyContent: justify,
2148
+ flexDirection: direction,
2149
+ flexWrap: wrap
2150
+ },
2151
+ className: style_default.stack
2152
+ })
2064
2153
  });
2065
2154
  });
2066
2155
  //#endregion
@@ -3081,90 +3170,6 @@ var line_chart_module_default = {
3081
3170
  "line-chart--animated": "a8ccharts-inuQka-line-chart--animated",
3082
3171
  "rise": "a8ccharts-inuQka-rise"
3083
3172
  };
3084
- //#endregion
3085
- //#region src/charts/line-chart/private/line-chart-annotations-overlay.tsx
3086
- const LineChartAnnotationsOverlay = ({ children }) => {
3087
- const { chartRef, chartWidth, chartHeight } = useSingleChartContext();
3088
- const [scales, setScales] = useState(null);
3089
- const [scalesStable, setScalesStable] = useState(false);
3090
- const createScaleSignature = useCallback((scaleData) => {
3091
- const xDomain = scaleData.xScale.domain();
3092
- const yDomain = scaleData.yScale.domain();
3093
- const xRange = scaleData.xScale.range();
3094
- const yRange = scaleData.yScale.range();
3095
- return `${xDomain.join(",")}-${yDomain.join(",")}-${xRange.join(",")}-${yRange.join(",")}`;
3096
- }, []);
3097
- const getScalesData = useCallback(() => {
3098
- if (chartRef?.current) {
3099
- const scaleData = chartRef.current.getScales();
3100
- if (scaleData) {
3101
- const scaleInfo = {
3102
- xScale: scaleData.xScale,
3103
- yScale: scaleData.yScale
3104
- };
3105
- return {
3106
- scales: scaleInfo,
3107
- signature: createScaleSignature(scaleInfo)
3108
- };
3109
- }
3110
- }
3111
- return null;
3112
- }, [chartRef, createScaleSignature]);
3113
- useEffect(() => {
3114
- let timeoutId = null;
3115
- let lastSignature = null;
3116
- let retryCount = 0;
3117
- const maxRetries = 20;
3118
- const checkInterval = 50;
3119
- setScalesStable(false);
3120
- const monitorScales = () => {
3121
- const currentScaleData = getScalesData();
3122
- if (currentScaleData) {
3123
- if (lastSignature && currentScaleData.signature === lastSignature) {
3124
- setScalesStable(true);
3125
- return;
3126
- }
3127
- setScales(currentScaleData.scales);
3128
- lastSignature = currentScaleData.signature;
3129
- }
3130
- if (retryCount < maxRetries) {
3131
- retryCount++;
3132
- timeoutId = setTimeout(monitorScales, checkInterval);
3133
- }
3134
- };
3135
- monitorScales();
3136
- return () => {
3137
- if (timeoutId) clearTimeout(timeoutId);
3138
- };
3139
- }, [
3140
- getScalesData,
3141
- chartWidth,
3142
- chartHeight
3143
- ]);
3144
- if (!chartRef || !children || !chartWidth || !chartHeight) return null;
3145
- if (!scales || !scalesStable) return null;
3146
- const dataContextValue = {
3147
- xScale: scales.xScale,
3148
- yScale: scales.yScale,
3149
- margin: {
3150
- top: 0,
3151
- right: 0,
3152
- bottom: 0,
3153
- left: 0
3154
- },
3155
- width: chartWidth,
3156
- height: chartHeight
3157
- };
3158
- return /* @__PURE__ */ jsx(DataContext.Provider, {
3159
- value: dataContextValue,
3160
- children: /* @__PURE__ */ jsx("svg", {
3161
- width: chartWidth,
3162
- height: chartHeight,
3163
- className: line_chart_module_default["line-chart__annotations-overlay"],
3164
- children
3165
- })
3166
- });
3167
- };
3168
3173
  const CloseIcon = () => /* @__PURE__ */ jsx("svg", {
3169
3174
  width: "16",
3170
3175
  height: "16",
@@ -3246,6 +3251,90 @@ const LineChartAnnotationLabelWithPopover = ({ title, subtitle, renderLabel, ren
3246
3251
  });
3247
3252
  };
3248
3253
  //#endregion
3254
+ //#region src/charts/line-chart/private/line-chart-annotations-overlay.tsx
3255
+ const LineChartAnnotationsOverlay = ({ children }) => {
3256
+ const { chartRef, chartWidth, chartHeight } = useSingleChartContext();
3257
+ const [scales, setScales] = useState(null);
3258
+ const [scalesStable, setScalesStable] = useState(false);
3259
+ const createScaleSignature = useCallback((scaleData) => {
3260
+ const xDomain = scaleData.xScale.domain();
3261
+ const yDomain = scaleData.yScale.domain();
3262
+ const xRange = scaleData.xScale.range();
3263
+ const yRange = scaleData.yScale.range();
3264
+ return `${xDomain.join(",")}-${yDomain.join(",")}-${xRange.join(",")}-${yRange.join(",")}`;
3265
+ }, []);
3266
+ const getScalesData = useCallback(() => {
3267
+ if (chartRef?.current) {
3268
+ const scaleData = chartRef.current.getScales();
3269
+ if (scaleData) {
3270
+ const scaleInfo = {
3271
+ xScale: scaleData.xScale,
3272
+ yScale: scaleData.yScale
3273
+ };
3274
+ return {
3275
+ scales: scaleInfo,
3276
+ signature: createScaleSignature(scaleInfo)
3277
+ };
3278
+ }
3279
+ }
3280
+ return null;
3281
+ }, [chartRef, createScaleSignature]);
3282
+ useEffect(() => {
3283
+ let timeoutId = null;
3284
+ let lastSignature = null;
3285
+ let retryCount = 0;
3286
+ const maxRetries = 20;
3287
+ const checkInterval = 50;
3288
+ setScalesStable(false);
3289
+ const monitorScales = () => {
3290
+ const currentScaleData = getScalesData();
3291
+ if (currentScaleData) {
3292
+ if (lastSignature && currentScaleData.signature === lastSignature) {
3293
+ setScalesStable(true);
3294
+ return;
3295
+ }
3296
+ setScales(currentScaleData.scales);
3297
+ lastSignature = currentScaleData.signature;
3298
+ }
3299
+ if (retryCount < maxRetries) {
3300
+ retryCount++;
3301
+ timeoutId = setTimeout(monitorScales, checkInterval);
3302
+ }
3303
+ };
3304
+ monitorScales();
3305
+ return () => {
3306
+ if (timeoutId) clearTimeout(timeoutId);
3307
+ };
3308
+ }, [
3309
+ getScalesData,
3310
+ chartWidth,
3311
+ chartHeight
3312
+ ]);
3313
+ if (!chartRef || !children || !chartWidth || !chartHeight) return null;
3314
+ if (!scales || !scalesStable) return null;
3315
+ const dataContextValue = {
3316
+ xScale: scales.xScale,
3317
+ yScale: scales.yScale,
3318
+ margin: {
3319
+ top: 0,
3320
+ right: 0,
3321
+ bottom: 0,
3322
+ left: 0
3323
+ },
3324
+ width: chartWidth,
3325
+ height: chartHeight
3326
+ };
3327
+ return /* @__PURE__ */ jsx(DataContext.Provider, {
3328
+ value: dataContextValue,
3329
+ children: /* @__PURE__ */ jsx("svg", {
3330
+ width: chartWidth,
3331
+ height: chartHeight,
3332
+ className: line_chart_module_default["line-chart__annotations-overlay"],
3333
+ children
3334
+ })
3335
+ });
3336
+ };
3337
+ //#endregion
3249
3338
  //#region src/charts/line-chart/private/line-chart-annotation.tsx
3250
3339
  const ANNOTATION_MAX_WIDTH = 125;
3251
3340
  const ANNOTATION_INIT_HEIGHT = 100;
@@ -3309,7 +3398,10 @@ const LineChartAnnotation = ({ datum, title, subtitle, subjectType = "circle", s
3309
3398
  const styles = deepmerge(providerTheme.annotationStyles ?? {}, datumStyles ?? {});
3310
3399
  const resolveColor = (value) => value ? resolveCssVariable(value) ?? value : value;
3311
3400
  useEffect(() => {
3312
- if (labelRef.current?.getBBox) setHeight(labelRef.current.getBBox().height);
3401
+ if (labelRef.current?.getBBox) {
3402
+ const bbox = labelRef.current.getBBox();
3403
+ setHeight(bbox.height);
3404
+ }
3313
3405
  }, []);
3314
3406
  const positionData = useMemo(() => {
3315
3407
  if (!datum || !datum.date || datum.value == null || !xScale || !yScale) return null;
@@ -4950,8 +5042,9 @@ const BarChartInternal = ({ data, chartId: providedChartId, width, height, class
4950
5042
  if (dataPointIndex >= maxDataPoints || seriesIndex >= primaryCount) return "";
4951
5043
  const seriesData = primaryEntries[seriesIndex]?.series;
4952
5044
  if (!seriesData || dataPointIndex >= seriesData.data.length) return "";
5045
+ const actualBarIndex = seriesIndex * maxDataPoints + dataPointIndex;
4953
5046
  return `
4954
- .bar-chart[data-chart-id="bar-chart-${chartId}"] .visx-bar-group .visx-bar:nth-child(${seriesIndex * maxDataPoints + dataPointIndex + 1}) {
5047
+ .bar-chart[data-chart-id="bar-chart-${chartId}"] .visx-bar-group .visx-bar:nth-child(${actualBarIndex + 1}) {
4955
5048
  stroke: #005fcc;
4956
5049
  stroke-width: 2px;
4957
5050
  }
@@ -5171,16 +5264,18 @@ const AxisRenderer = ({ ticks, tickLabelProps, yOffset, labelPosition, valuePosi
5171
5264
  const getDefaultYOffset = (data, yScaleConfig, height, isMultiSeries) => {
5172
5265
  if (!isMultiSeries) return 0;
5173
5266
  const dataKeys = data.map(({ label }) => label);
5174
- return -(getScaleBandwidth(scaleBand({
5267
+ const yScale = createScale({
5268
+ type: "band",
5269
+ range: [0, height],
5175
5270
  domain: dataKeys,
5176
- range: [0, getScaleBandwidth(createScale({
5177
- type: "band",
5178
- range: [0, height],
5179
- domain: dataKeys,
5180
- ...yScaleConfig
5181
- }))],
5271
+ ...yScaleConfig
5272
+ });
5273
+ const groupScale = scaleBand({
5274
+ domain: dataKeys,
5275
+ range: [0, getScaleBandwidth(yScale)],
5182
5276
  padding: yScaleConfig.paddingInner
5183
- })) + 6);
5277
+ });
5278
+ return -(getScaleBandwidth(groupScale) + 6);
5184
5279
  };
5185
5280
  const BarListChartInternal = ({ data, width, height, options = {}, margin = {
5186
5281
  left: 0,
@@ -5937,12 +6032,17 @@ const buildCalendarHeatmapData = (series, options = {}) => {
5937
6032
  const gridStart = startOfWeek(minDate, { weekStartsOn });
5938
6033
  const weekCount = differenceInCalendarWeeks(maxDate, gridStart, { weekStartsOn }) + 1;
5939
6034
  const rowLabels = Array.from({ length: 7 }, (_, row) => LABELLED_ROWS.includes(row) ? format(addDays(gridStart, row), "EEE") : "");
6035
+ const MIN_FIRST_MONTH_WEEKS = 2;
6036
+ const firstMonth = gridStart.getMonth();
6037
+ let firstMonthWeeks = 0;
6038
+ while (firstMonthWeeks < weekCount && addDays(gridStart, firstMonthWeeks * 7).getMonth() === firstMonth) firstMonthWeeks++;
6039
+ const showFirstMonthLabel = !(firstMonthWeeks < weekCount) || firstMonthWeeks >= MIN_FIRST_MONTH_WEEKS;
5940
6040
  const data = [];
5941
6041
  let previousMonth = -1;
5942
6042
  for (let week = 0; week < weekCount; week++) {
5943
6043
  const columnStart = addDays(gridStart, week * 7);
5944
6044
  const month = columnStart.getMonth();
5945
- const label = month !== previousMonth ? format(columnStart, "MMM") : "";
6045
+ const label = month !== previousMonth && (week !== 0 || showFirstMonthLabel) ? format(columnStart, "MMM") : "";
5946
6046
  previousMonth = month;
5947
6047
  const cells = [];
5948
6048
  for (let row = 0; row < 7; row++) {
@@ -5964,10 +6064,14 @@ const buildCalendarHeatmapData = (series, options = {}) => {
5964
6064
  };
5965
6065
  };
5966
6066
  //#endregion
6067
+ //#region src/charts/heatmap-chart/private/heatmap-context.ts
6068
+ /** Shared by the chart and legend without importing back from `heatmap-chart.tsx`. */
6069
+ const HeatmapContext = createContext(null);
6070
+ //#endregion
5967
6071
  //#region src/charts/heatmap-chart/private/heatmap-legend.tsx
5968
6072
  const HeatmapLegend = ({ steps = 5, lessLabel, moreLabel }) => {
5969
6073
  const context = useContext(HeatmapContext);
5970
- const { legend } = useGlobalChartsTheme();
6074
+ const { legend, backgroundColor } = useGlobalChartsTheme();
5971
6075
  if (!context) return null;
5972
6076
  const { primaryColorHex } = context;
5973
6077
  const labelStyle = legend.labelStyles;
@@ -5991,6 +6095,7 @@ const HeatmapLegend = ({ steps = 5, lessLabel, moreLabel }) => {
5991
6095
  className: heatmap_chart_module_default["heatmap-chart__legend-swatch"],
5992
6096
  style: {
5993
6097
  "--heatmap-primary": primaryColorHex,
6098
+ "--heatmap-bg": backgroundColor,
5994
6099
  "--intensity": intensity
5995
6100
  }
5996
6101
  }, index);
@@ -6006,11 +6111,10 @@ const HeatmapLegend = ({ steps = 5, lessLabel, moreLabel }) => {
6006
6111
  };
6007
6112
  //#endregion
6008
6113
  //#region src/charts/heatmap-chart/heatmap-chart.tsx
6009
- const HeatmapContext = createContext(null);
6010
6114
  const CELL_MIX_FLOOR = .15;
6011
6115
  const HeatmapChartInternal = ({ data, chartId: providedChartId, width = 0, height = 0, className, compact = false, showValues, rowLabels = [], primaryColor, gap = "md", withTooltips = false, renderTooltip, children }) => {
6012
6116
  const chartId = useChartId(providedChartId);
6013
- const { getElementStyles, theme } = useGlobalChartsContext();
6117
+ const { getElementStyles, resolveThemeColor, theme } = useGlobalChartsContext();
6014
6118
  const { heatmapChart: heatmapChartSettings } = theme;
6015
6119
  const { nonLegendChildren } = useChartChildren(children, "HeatmapChart");
6016
6120
  const [selectedIndex, setSelectedIndex] = useState();
@@ -6025,8 +6129,9 @@ const HeatmapChartInternal = ({ data, chartId: providedChartId, width = 0, heigh
6025
6129
  index: 0,
6026
6130
  overrideColor: primaryColor || heatmapChartSettings.primaryColor
6027
6131
  });
6132
+ const chartBackgroundHex = resolveThemeColor(theme.backgroundColor);
6028
6133
  const primaryHex = normalizeColorToHex(primaryColorHex);
6029
- const cellHasLightText = (intensity) => isValidHexColor(primaryHex) && prefersLightText(lightenHexColor(primaryHex, 1 - (CELL_MIX_FLOOR + (1 - CELL_MIX_FLOOR) * intensity)));
6134
+ const cellHasLightText = (intensity) => isValidHexColor(primaryHex) && isValidHexColor(chartBackgroundHex) && prefersLightText(mixHexColors(primaryHex, chartBackgroundHex, 1 - (CELL_MIX_FLOOR + (1 - CELL_MIX_FLOOR) * intensity)));
6030
6135
  const extent = useMemo(() => getValueExtent(data), [data]);
6031
6136
  const heatmapContext = useMemo(() => ({
6032
6137
  extent,
@@ -6140,6 +6245,7 @@ const HeatmapChartInternal = ({ data, chartId: providedChartId, width = 0, heigh
6140
6245
  const trackSize = compact ? "var(--heatmap-cell-size)" : "minmax(0, 1fr)";
6141
6246
  const gridStyle = {
6142
6247
  "--heatmap-primary": primaryColorHex,
6248
+ "--heatmap-bg": theme.backgroundColor,
6143
6249
  gridTemplateColumns: `auto repeat(${columns}, ${trackSize})`,
6144
6250
  gridTemplateRows: `auto repeat(${rows}, ${trackSize})`
6145
6251
  };
@@ -6175,55 +6281,55 @@ const HeatmapChartInternal = ({ data, chartId: providedChartId, width = 0, heigh
6175
6281
  onKeyDown: onChartKeyDown,
6176
6282
  className: clsx(heatmap_chart_module_default["heatmap-chart__grid"], { [heatmap_chart_module_default["heatmap-chart__grid--compact"]]: compact }),
6177
6283
  style: gridStyle,
6178
- children: [
6179
- /* @__PURE__ */ jsx("span", { "aria-hidden": "true" }),
6180
- data.map((column, columnIndex) => /* @__PURE__ */ jsx("span", {
6181
- "aria-hidden": "true",
6284
+ children: [/* @__PURE__ */ jsxs("div", {
6285
+ role: "row",
6286
+ "aria-hidden": "true",
6287
+ className: heatmap_chart_module_default["heatmap-chart__row"],
6288
+ children: [/* @__PURE__ */ jsx("span", {}), data.map((column, columnIndex) => /* @__PURE__ */ jsx("span", {
6182
6289
  className: heatmap_chart_module_default["heatmap-chart__col-label"],
6183
6290
  children: column.label
6184
- }, `col-${columnIndex}`)),
6185
- Array.from({ length: rows }).map((_row, rowIndex) => {
6186
- const labelVisible = !compact || rowIndex % 2 === 0;
6187
- return /* @__PURE__ */ jsxs("div", {
6188
- role: "row",
6189
- "aria-rowindex": rowIndex + 1,
6190
- className: heatmap_chart_module_default["heatmap-chart__row"],
6191
- children: [/* @__PURE__ */ jsx("span", {
6192
- "aria-hidden": "true",
6193
- className: heatmap_chart_module_default["heatmap-chart__row-label"],
6194
- children: labelVisible ? rowLabels[rowIndex] ?? "" : ""
6195
- }), data.map((column, columnIndex) => {
6196
- const value = column.data[rowIndex]?.value ?? null;
6197
- const present = isPresent(value);
6198
- const normalized = present ? getNormalizedValue(value, extent) : 0;
6199
- const flatIndex = columnIndex * rows + rowIndex;
6200
- const info = buildTooltipData(columnIndex, rowIndex);
6201
- const accessibleLabel = `${info.cellLabel || `${info.columnLabel ?? ""} ${info.rowLabel ?? ""}`.trim()}: ${info.value === null ? __("No data", "jetpack-charts") : formatNumber(info.value)}`;
6202
- return /* @__PURE__ */ jsx("div", {
6203
- id: `${chartId}-cell-${columnIndex}-${rowIndex}`,
6204
- role: "gridcell",
6205
- tabIndex: -1,
6206
- "aria-colindex": columnIndex + 1,
6207
- "aria-label": accessibleLabel,
6208
- "data-column": columnIndex,
6209
- "data-row": rowIndex,
6210
- className: clsx(heatmap_chart_module_default["heatmap-chart__cell"], {
6211
- [heatmap_chart_module_default["heatmap-chart__cell--filled"]]: present,
6212
- [heatmap_chart_module_default["heatmap-chart__cell--strong"]]: present && cellHasLightText(normalized),
6213
- [heatmap_chart_module_default["heatmap-chart__cell--selected"]]: selectedIndex === flatIndex
6214
- }),
6215
- style: present ? { "--intensity": normalized } : void 0,
6216
- onMouseMove: handleCellMouseMove,
6217
- onMouseLeave: handleCellMouseLeave,
6218
- children: drawValues && present && /* @__PURE__ */ jsx("span", {
6219
- className: heatmap_chart_module_default["heatmap-chart__cell-value"],
6220
- children: formatNumberCompact(value)
6221
- })
6222
- }, `cell-${columnIndex}-${rowIndex}`);
6223
- })]
6224
- }, `row-${rowIndex}`);
6225
- })
6226
- ]
6291
+ }, `col-${columnIndex}`))]
6292
+ }), Array.from({ length: rows }).map((_row, rowIndex) => {
6293
+ const labelVisible = !compact || rowIndex % 2 === 0;
6294
+ return /* @__PURE__ */ jsxs("div", {
6295
+ role: "row",
6296
+ "aria-rowindex": rowIndex + 1,
6297
+ className: heatmap_chart_module_default["heatmap-chart__row"],
6298
+ children: [/* @__PURE__ */ jsx("span", {
6299
+ "aria-hidden": "true",
6300
+ className: heatmap_chart_module_default["heatmap-chart__row-label"],
6301
+ children: labelVisible ? rowLabels[rowIndex] ?? "" : ""
6302
+ }), data.map((column, columnIndex) => {
6303
+ const value = column.data[rowIndex]?.value ?? null;
6304
+ const present = isPresent(value);
6305
+ const normalized = present ? getNormalizedValue(value, extent) : 0;
6306
+ const flatIndex = columnIndex * rows + rowIndex;
6307
+ const info = buildTooltipData(columnIndex, rowIndex);
6308
+ const accessibleLabel = `${info.cellLabel || `${info.columnLabel ?? ""} ${info.rowLabel ?? ""}`.trim()}: ${info.value === null ? __("No data", "jetpack-charts") : formatNumber(info.value)}`;
6309
+ return /* @__PURE__ */ jsx("div", {
6310
+ id: `${chartId}-cell-${columnIndex}-${rowIndex}`,
6311
+ role: "gridcell",
6312
+ tabIndex: -1,
6313
+ "aria-colindex": columnIndex + 1,
6314
+ "aria-label": accessibleLabel,
6315
+ "data-column": columnIndex,
6316
+ "data-row": rowIndex,
6317
+ className: clsx(heatmap_chart_module_default["heatmap-chart__cell"], {
6318
+ [heatmap_chart_module_default["heatmap-chart__cell--filled"]]: present,
6319
+ [heatmap_chart_module_default["heatmap-chart__cell--strong"]]: present && cellHasLightText(normalized),
6320
+ [heatmap_chart_module_default["heatmap-chart__cell--selected"]]: selectedIndex === flatIndex
6321
+ }),
6322
+ style: present ? { "--intensity": normalized } : void 0,
6323
+ onMouseMove: handleCellMouseMove,
6324
+ onMouseLeave: handleCellMouseLeave,
6325
+ children: drawValues && present && /* @__PURE__ */ jsx("span", {
6326
+ className: heatmap_chart_module_default["heatmap-chart__cell-value"],
6327
+ children: formatNumberCompact(value)
6328
+ })
6329
+ }, `cell-${columnIndex}-${rowIndex}`);
6330
+ })]
6331
+ }, `row-${rowIndex}`);
6332
+ })]
6227
6333
  }), withTooltips && tooltipOpen && tooltipData && /* @__PURE__ */ jsx(TooltipInPortal, {
6228
6334
  top: tooltipTop,
6229
6335
  left: tooltipLeft,
@@ -6251,318 +6357,32 @@ const HeatmapChartResponsiveInner = (props) => /* @__PURE__ */ jsx(HeatmapChartW
6251
6357
  HeatmapChartResponsiveInner.displayName = "HeatmapChart";
6252
6358
  const HeatmapChartResponsive = attachSubComponents(withResponsive(HeatmapChartResponsiveInner), { Legend: HeatmapLegend });
6253
6359
  //#endregion
6254
- //#region ../../../node_modules/.pnpm/@wordpress+warning@3.50.0/node_modules/@wordpress/warning/build-module/utils.mjs
6255
- var logged = /* @__PURE__ */ new Set();
6256
- //#endregion
6257
- //#region ../../../node_modules/.pnpm/@wordpress+warning@3.50.0/node_modules/@wordpress/warning/build-module/index.mjs
6258
- function isDev() {
6259
- return globalThis.SCRIPT_DEBUG === true;
6260
- }
6261
- function warning(message) {
6262
- if (!isDev()) return;
6263
- if (logged.has(message)) return;
6264
- console.warn(message);
6265
- try {
6266
- throw Error(message);
6267
- } catch {}
6268
- logged.add(message);
6269
- }
6270
- //#endregion
6271
- //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/context/constants.mjs
6272
- var COMPONENT_NAMESPACE = "data-wp-component";
6273
- var CONNECTED_NAMESPACE = "data-wp-c16t";
6274
- var CONNECT_STATIC_NAMESPACE = "__contextSystemKey__";
6275
- //#endregion
6276
- //#region ../../../node_modules/.pnpm/lower-case@2.0.2/node_modules/lower-case/dist.es2015/index.js
6277
- /**
6278
- * Lower case as a function.
6279
- */
6280
- function lowerCase(str) {
6281
- return str.toLowerCase();
6360
+ //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/utils/hooks/use-update-effect.mjs
6361
+ function useUpdateEffect(effect, deps) {
6362
+ const mountedRef = useRef$1(false);
6363
+ useEffect$1(() => {
6364
+ if (mountedRef.current) return effect();
6365
+ mountedRef.current = true;
6366
+ }, deps);
6367
+ useEffect$1(() => () => {
6368
+ mountedRef.current = false;
6369
+ }, []);
6282
6370
  }
6371
+ var use_update_effect_default = useUpdateEffect;
6283
6372
  //#endregion
6284
- //#region ../../../node_modules/.pnpm/no-case@3.0.4/node_modules/no-case/dist.es2015/index.js
6285
- var DEFAULT_SPLIT_REGEXP = [/([a-z0-9])([A-Z])/g, /([A-Z])([A-Z][a-z])/g];
6286
- var DEFAULT_STRIP_REGEXP = /[^A-Z0-9]+/gi;
6287
- /**
6288
- * Normalize the string into something other libraries can manipulate easier.
6289
- */
6290
- function noCase(input, options) {
6291
- if (options === void 0) options = {};
6292
- var _a = options.splitRegexp, splitRegexp = _a === void 0 ? DEFAULT_SPLIT_REGEXP : _a, _b = options.stripRegexp, stripRegexp = _b === void 0 ? DEFAULT_STRIP_REGEXP : _b, _c = options.transform, transform = _c === void 0 ? lowerCase : _c, _d = options.delimiter, delimiter = _d === void 0 ? " " : _d;
6293
- var result = replace$1(replace$1(input, splitRegexp, "$1\0$2"), stripRegexp, "\0");
6294
- var start = 0;
6295
- var end = result.length;
6296
- while (result.charAt(start) === "\0") start++;
6297
- while (result.charAt(end - 1) === "\0") end--;
6298
- return result.slice(start, end).split("\0").map(transform).join(delimiter);
6299
- }
6300
- /**
6301
- * Replace `re` in the input string with the replacement value.
6302
- */
6303
- function replace$1(input, re, value) {
6304
- if (re instanceof RegExp) return input.replace(re, value);
6305
- return re.reduce(function(input, re) {
6306
- return input.replace(re, value);
6307
- }, input);
6373
+ //#region ../../../node_modules/.pnpm/@emotion+sheet@1.4.0/node_modules/@emotion/sheet/dist/emotion-sheet.esm.js
6374
+ function sheetForTag(tag) {
6375
+ if (tag.sheet) return tag.sheet;
6376
+ /* istanbul ignore next */
6377
+ for (var i = 0; i < document.styleSheets.length; i++) if (document.styleSheets[i].ownerNode === tag) return document.styleSheets[i];
6308
6378
  }
6309
- //#endregion
6310
- //#region ../../../node_modules/.pnpm/dot-case@3.0.4/node_modules/dot-case/dist.es2015/index.js
6311
- function dotCase(input, options) {
6312
- if (options === void 0) options = {};
6313
- return noCase(input, __assign({ delimiter: "." }, options));
6314
- }
6315
- //#endregion
6316
- //#region ../../../node_modules/.pnpm/param-case@3.0.4/node_modules/param-case/dist.es2015/index.js
6317
- function paramCase(input, options) {
6318
- if (options === void 0) options = {};
6319
- return dotCase(input, __assign({ delimiter: "-" }, options));
6320
- }
6321
- //#endregion
6322
- //#region ../../../node_modules/.pnpm/memize@2.1.1/node_modules/memize/dist/index.js
6323
- /**
6324
- * Memize options object.
6325
- *
6326
- * @typedef MemizeOptions
6327
- *
6328
- * @property {number} [maxSize] Maximum size of the cache.
6329
- */
6330
- /**
6331
- * Internal cache entry.
6332
- *
6333
- * @typedef MemizeCacheNode
6334
- *
6335
- * @property {?MemizeCacheNode|undefined} [prev] Previous node.
6336
- * @property {?MemizeCacheNode|undefined} [next] Next node.
6337
- * @property {Array<*>} args Function arguments for cache
6338
- * entry.
6339
- * @property {*} val Function result.
6340
- */
6341
- /**
6342
- * Properties of the enhanced function for controlling cache.
6343
- *
6344
- * @typedef MemizeMemoizedFunction
6345
- *
6346
- * @property {()=>void} clear Clear the cache.
6347
- */
6348
- /**
6349
- * Accepts a function to be memoized, and returns a new memoized function, with
6350
- * optional options.
6351
- *
6352
- * @template {(...args: any[]) => any} F
6353
- *
6354
- * @param {F} fn Function to memoize.
6355
- * @param {MemizeOptions} [options] Options object.
6356
- *
6357
- * @return {((...args: Parameters<F>) => ReturnType<F>) & MemizeMemoizedFunction} Memoized function.
6358
- */
6359
- function memize(fn, options) {
6360
- var size = 0;
6361
- /** @type {?MemizeCacheNode|undefined} */
6362
- var head;
6363
- /** @type {?MemizeCacheNode|undefined} */
6364
- var tail;
6365
- options = options || {};
6366
- function memoized() {
6367
- var node = head, len = arguments.length, args, i;
6368
- searchCache: while (node) {
6369
- if (node.args.length !== arguments.length) {
6370
- node = node.next;
6371
- continue;
6372
- }
6373
- for (i = 0; i < len; i++) if (node.args[i] !== arguments[i]) {
6374
- node = node.next;
6375
- continue searchCache;
6376
- }
6377
- if (node !== head) {
6378
- if (node === tail) tail = node.prev;
6379
- /** @type {MemizeCacheNode} */ node.prev.next = node.next;
6380
- if (node.next) node.next.prev = node.prev;
6381
- node.next = head;
6382
- node.prev = null;
6383
- /** @type {MemizeCacheNode} */ head.prev = node;
6384
- head = node;
6385
- }
6386
- return node.val;
6387
- }
6388
- args = new Array(len);
6389
- for (i = 0; i < len; i++) args[i] = arguments[i];
6390
- node = {
6391
- args,
6392
- val: fn.apply(null, args)
6393
- };
6394
- if (head) {
6395
- head.prev = node;
6396
- node.next = head;
6397
- } else tail = node;
6398
- if (size === options.maxSize) {
6399
- tail = tail.prev;
6400
- /** @type {MemizeCacheNode} */ tail.next = null;
6401
- } else size++;
6402
- head = node;
6403
- return node.val;
6404
- }
6405
- memoized.clear = function() {
6406
- head = null;
6407
- tail = null;
6408
- size = 0;
6409
- };
6410
- return memoized;
6411
- }
6412
- //#endregion
6413
- //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/context/get-styled-class-name-from-key.mjs
6414
- function getStyledClassName(namespace) {
6415
- return `components-${paramCase(namespace)}`;
6416
- }
6417
- var getStyledClassNameFromKey = memize(getStyledClassName);
6418
- //#endregion
6419
- //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/context/context-connect.mjs
6420
- function contextConnect(Component, namespace) {
6421
- return _contextConnect(Component, namespace, { forwardsRef: true });
6422
- }
6423
- function _contextConnect(Component, namespace, options) {
6424
- const WrappedComponent = options?.forwardsRef ? forwardRef$1(Component) : Component;
6425
- if (typeof namespace === "undefined") globalThis.SCRIPT_DEBUG === true && warning("contextConnect: Please provide a namespace");
6426
- let mergedNamespace = WrappedComponent["__contextSystemKey__"] || [namespace];
6427
- if (Array.isArray(namespace)) mergedNamespace = [...mergedNamespace, ...namespace];
6428
- if (typeof namespace === "string") mergedNamespace = [...mergedNamespace, namespace];
6429
- return Object.assign(WrappedComponent, {
6430
- [CONNECT_STATIC_NAMESPACE]: [...new Set(mergedNamespace)],
6431
- displayName: namespace,
6432
- selector: `.${getStyledClassNameFromKey(namespace)}`
6433
- });
6434
- }
6435
- //#endregion
6436
- //#region ../../../node_modules/.pnpm/fast-deep-equal@3.1.3/node_modules/fast-deep-equal/es6/index.js
6437
- var require_es6 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
6438
- module.exports = function equal(a, b) {
6439
- if (a === b) return true;
6440
- if (a && b && typeof a == "object" && typeof b == "object") {
6441
- if (a.constructor !== b.constructor) return false;
6442
- var length, i, keys;
6443
- if (Array.isArray(a)) {
6444
- length = a.length;
6445
- if (length != b.length) return false;
6446
- for (i = length; i-- !== 0;) if (!equal(a[i], b[i])) return false;
6447
- return true;
6448
- }
6449
- if (a instanceof Map && b instanceof Map) {
6450
- if (a.size !== b.size) return false;
6451
- for (i of a.entries()) if (!b.has(i[0])) return false;
6452
- for (i of a.entries()) if (!equal(i[1], b.get(i[0]))) return false;
6453
- return true;
6454
- }
6455
- if (a instanceof Set && b instanceof Set) {
6456
- if (a.size !== b.size) return false;
6457
- for (i of a.entries()) if (!b.has(i[0])) return false;
6458
- return true;
6459
- }
6460
- if (ArrayBuffer.isView(a) && ArrayBuffer.isView(b)) {
6461
- length = a.length;
6462
- if (length != b.length) return false;
6463
- for (i = length; i-- !== 0;) if (a[i] !== b[i]) return false;
6464
- return true;
6465
- }
6466
- if (a.constructor === RegExp) return a.source === b.source && a.flags === b.flags;
6467
- if (a.valueOf !== Object.prototype.valueOf) return a.valueOf() === b.valueOf();
6468
- if (a.toString !== Object.prototype.toString) return a.toString() === b.toString();
6469
- keys = Object.keys(a);
6470
- length = keys.length;
6471
- if (length !== Object.keys(b).length) return false;
6472
- for (i = length; i-- !== 0;) if (!Object.prototype.hasOwnProperty.call(b, keys[i])) return false;
6473
- for (i = length; i-- !== 0;) {
6474
- var key = keys[i];
6475
- if (!equal(a[key], b[key])) return false;
6476
- }
6477
- return true;
6478
- }
6479
- return a !== a && b !== b;
6480
- };
6481
- }));
6482
- //#endregion
6483
- //#region ../../../node_modules/.pnpm/is-plain-object@5.0.0/node_modules/is-plain-object/dist/is-plain-object.mjs
6484
- /*!
6485
- * is-plain-object <https://github.com/jonschlinkert/is-plain-object>
6486
- *
6487
- * Copyright (c) 2014-2017, Jon Schlinkert.
6488
- * Released under the MIT License.
6489
- */
6490
- function isObject(o) {
6491
- return Object.prototype.toString.call(o) === "[object Object]";
6492
- }
6493
- function isPlainObject(o) {
6494
- var ctor, prot;
6495
- if (isObject(o) === false) return false;
6496
- ctor = o.constructor;
6497
- if (ctor === void 0) return true;
6498
- prot = ctor.prototype;
6499
- if (isObject(prot) === false) return false;
6500
- if (prot.hasOwnProperty("isPrototypeOf") === false) return false;
6501
- return true;
6502
- }
6503
- //#endregion
6504
- //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/utils/hooks/use-update-effect.mjs
6505
- function useUpdateEffect(effect, deps) {
6506
- const mountedRef = useRef$1(false);
6507
- useEffect$1(() => {
6508
- if (mountedRef.current) return effect();
6509
- mountedRef.current = true;
6510
- }, deps);
6511
- useEffect$1(() => () => {
6512
- mountedRef.current = false;
6513
- }, []);
6514
- }
6515
- var use_update_effect_default = useUpdateEffect;
6516
- //#endregion
6517
- //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/context/context-system-provider.mjs
6518
- var import_es6 = /* @__PURE__ */ __toESM(require_es6(), 1);
6519
- var ComponentsContext = createContext$1(
6520
- /** @type {Record<string, any>} */
6521
- {}
6522
- );
6523
- ComponentsContext.displayName = "ComponentsContext";
6524
- var useComponentsContext = () => useContext$1(ComponentsContext);
6525
- function useContextSystemBridge({ value }) {
6526
- const parentContext = useComponentsContext();
6527
- const valueRef = useRef$1(value);
6528
- use_update_effect_default(() => {
6529
- if ((0, import_es6.default)(valueRef.current, value) && valueRef.current !== value) globalThis.SCRIPT_DEBUG === true && warning(`Please memoize your context: ${JSON.stringify(value)}`);
6530
- }, [value]);
6531
- return useMemo$1(() => {
6532
- return deepmerge(parentContext ?? {}, value ?? {}, { isMergeableObject: isPlainObject });
6533
- }, [parentContext, value]);
6534
- }
6535
- var BaseContextSystemProvider = ({ children, value }) => {
6536
- const contextValue = useContextSystemBridge({ value });
6537
- return /* @__PURE__ */ jsx(ComponentsContext.Provider, {
6538
- value: contextValue,
6539
- children
6540
- });
6541
- };
6542
- memo(BaseContextSystemProvider);
6543
- //#endregion
6544
- //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/context/utils.mjs
6545
- function getNamespace(componentName) {
6546
- return { [COMPONENT_NAMESPACE]: componentName };
6547
- }
6548
- function getConnectedNamespace() {
6549
- return { [CONNECTED_NAMESPACE]: true };
6550
- }
6551
- //#endregion
6552
- //#region ../../../node_modules/.pnpm/@emotion+sheet@1.4.0/node_modules/@emotion/sheet/dist/emotion-sheet.esm.js
6553
- var isDevelopment$3 = false;
6554
- function sheetForTag(tag) {
6555
- if (tag.sheet) return tag.sheet;
6556
- /* istanbul ignore next */
6557
- for (var i = 0; i < document.styleSheets.length; i++) if (document.styleSheets[i].ownerNode === tag) return document.styleSheets[i];
6558
- }
6559
- function createStyleElement(options) {
6560
- var tag = document.createElement("style");
6561
- tag.setAttribute("data-emotion", options.key);
6562
- if (options.nonce !== void 0) tag.setAttribute("nonce", options.nonce);
6563
- tag.appendChild(document.createTextNode(""));
6564
- tag.setAttribute("data-s", "");
6565
- return tag;
6379
+ function createStyleElement(options) {
6380
+ var tag = document.createElement("style");
6381
+ tag.setAttribute("data-emotion", options.key);
6382
+ if (options.nonce !== void 0) tag.setAttribute("nonce", options.nonce);
6383
+ tag.appendChild(document.createTextNode(""));
6384
+ tag.setAttribute("data-s", "");
6385
+ return tag;
6566
6386
  }
6567
6387
  var StyleSheet = /*#__PURE__*/ function() {
6568
6388
  function StyleSheet(options) {
@@ -6576,7 +6396,7 @@ var StyleSheet = /*#__PURE__*/ function() {
6576
6396
  _this.container.insertBefore(tag, before);
6577
6397
  _this.tags.push(tag);
6578
6398
  };
6579
- this.isSpeedy = options.speedy === void 0 ? !isDevelopment$3 : options.speedy;
6399
+ this.isSpeedy = options.speedy === void 0 ? true : options.speedy;
6580
6400
  this.tags = [];
6581
6401
  this.ctr = 0;
6582
6402
  this.nonce = options.nonce;
@@ -7372,7 +7192,25 @@ var createCache = function createCache(options) {
7372
7192
  * LICENSE file in the root directory of this source tree.
7373
7193
  */
7374
7194
  var require_react_is_production_min = /* @__PURE__ */ __commonJSMin(((exports) => {
7375
- var b = "function" === typeof Symbol && Symbol.for, c = b ? Symbol.for("react.element") : 60103, d = b ? Symbol.for("react.portal") : 60106, e = b ? Symbol.for("react.fragment") : 60107, f = b ? Symbol.for("react.strict_mode") : 60108, g = b ? Symbol.for("react.profiler") : 60114, h = b ? Symbol.for("react.provider") : 60109, k = b ? Symbol.for("react.context") : 60110, l = b ? Symbol.for("react.async_mode") : 60111, m = b ? Symbol.for("react.concurrent_mode") : 60111, n = b ? Symbol.for("react.forward_ref") : 60112, p = b ? Symbol.for("react.suspense") : 60113, q = b ? Symbol.for("react.suspense_list") : 60120, r = b ? Symbol.for("react.memo") : 60115, t = b ? Symbol.for("react.lazy") : 60116, v = b ? Symbol.for("react.block") : 60121, w = b ? Symbol.for("react.fundamental") : 60117, x = b ? Symbol.for("react.responder") : 60118, y = b ? Symbol.for("react.scope") : 60119;
7195
+ var b = "function" === typeof Symbol && Symbol.for;
7196
+ var c = b ? Symbol.for("react.element") : 60103;
7197
+ var d = b ? Symbol.for("react.portal") : 60106;
7198
+ var e = b ? Symbol.for("react.fragment") : 60107;
7199
+ var f = b ? Symbol.for("react.strict_mode") : 60108;
7200
+ var g = b ? Symbol.for("react.profiler") : 60114;
7201
+ var h = b ? Symbol.for("react.provider") : 60109;
7202
+ var k = b ? Symbol.for("react.context") : 60110;
7203
+ var l = b ? Symbol.for("react.async_mode") : 60111;
7204
+ var m = b ? Symbol.for("react.concurrent_mode") : 60111;
7205
+ var n = b ? Symbol.for("react.forward_ref") : 60112;
7206
+ var p = b ? Symbol.for("react.suspense") : 60113;
7207
+ var q = b ? Symbol.for("react.suspense_list") : 60120;
7208
+ var r = b ? Symbol.for("react.memo") : 60115;
7209
+ var t = b ? Symbol.for("react.lazy") : 60116;
7210
+ var v = b ? Symbol.for("react.block") : 60121;
7211
+ var w = b ? Symbol.for("react.fundamental") : 60117;
7212
+ var x = b ? Symbol.for("react.responder") : 60118;
7213
+ var y = b ? Symbol.for("react.scope") : 60119;
7376
7214
  function z(a) {
7377
7215
  if ("object" === typeof a && null !== a) {
7378
7216
  var u = a.$$typeof;
@@ -7695,7 +7533,6 @@ var require_hoist_non_react_statics_cjs = /* @__PURE__ */ __commonJSMin(((export
7695
7533
  }));
7696
7534
  //#endregion
7697
7535
  //#region ../../../node_modules/.pnpm/@emotion+utils@1.4.2/node_modules/@emotion/utils/dist/emotion-utils.browser.esm.js
7698
- var isBrowser = true;
7699
7536
  function getRegisteredStyles$1(registered, registeredStyles, classNames) {
7700
7537
  var rawClassName = "";
7701
7538
  classNames.split(" ").forEach(function(className) {
@@ -7706,7 +7543,7 @@ function getRegisteredStyles$1(registered, registeredStyles, classNames) {
7706
7543
  }
7707
7544
  var registerStyles = function registerStyles(cache, serialized, isStringTag) {
7708
7545
  var className = cache.key + "-" + serialized.name;
7709
- if ((isStringTag === false || isBrowser === false) && cache.registered[className] === void 0) cache.registered[className] = serialized.styles;
7546
+ if ((isStringTag === false || false) && cache.registered[className] === void 0) cache.registered[className] = serialized.styles;
7710
7547
  };
7711
7548
  var insertStyles = function insertStyles(cache, serialized, isStringTag) {
7712
7549
  registerStyles(cache, serialized, isStringTag);
@@ -8078,11 +7915,12 @@ var classnames = function classnames(args) {
8078
7915
  }
8079
7916
  }
8080
7917
  return cls;
8081
- }, _createEmotion = createEmotion({ key: "css" });
8082
- _createEmotion.flush;
8083
- _createEmotion.hydrate;
7918
+ };
8084
7919
  //#endregion
8085
7920
  //#region ../../../node_modules/.pnpm/@emotion+css@11.13.5/node_modules/@emotion/css/dist/emotion-css.esm.js
7921
+ var _createEmotion = createEmotion({ key: "css" });
7922
+ _createEmotion.flush;
7923
+ _createEmotion.hydrate;
8086
7924
  var cx = _createEmotion.cx;
8087
7925
  _createEmotion.merge;
8088
7926
  _createEmotion.getRegisteredStyles;
@@ -8108,11 +7946,373 @@ var useCx = () => {
8108
7946
  }, [cache]);
8109
7947
  };
8110
7948
  //#endregion
8111
- //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/context/use-context-system.mjs
8112
- function useContextSystem(props, namespace) {
8113
- const contextSystemProps = useComponentsContext();
8114
- if (typeof namespace === "undefined") globalThis.SCRIPT_DEBUG === true && warning("useContextSystem: Please provide a namespace");
8115
- const contextProps = contextSystemProps?.[namespace] || {};
7949
+ //#region ../../../node_modules/.pnpm/memize@2.1.1/node_modules/memize/dist/index.js
7950
+ /**
7951
+ * Memize options object.
7952
+ *
7953
+ * @typedef MemizeOptions
7954
+ *
7955
+ * @property {number} [maxSize] Maximum size of the cache.
7956
+ */
7957
+ /**
7958
+ * Internal cache entry.
7959
+ *
7960
+ * @typedef MemizeCacheNode
7961
+ *
7962
+ * @property {?MemizeCacheNode|undefined} [prev] Previous node.
7963
+ * @property {?MemizeCacheNode|undefined} [next] Next node.
7964
+ * @property {Array<*>} args Function arguments for cache
7965
+ * entry.
7966
+ * @property {*} val Function result.
7967
+ */
7968
+ /**
7969
+ * Properties of the enhanced function for controlling cache.
7970
+ *
7971
+ * @typedef MemizeMemoizedFunction
7972
+ *
7973
+ * @property {()=>void} clear Clear the cache.
7974
+ */
7975
+ /**
7976
+ * Accepts a function to be memoized, and returns a new memoized function, with
7977
+ * optional options.
7978
+ *
7979
+ * @template {(...args: any[]) => any} F
7980
+ *
7981
+ * @param {F} fn Function to memoize.
7982
+ * @param {MemizeOptions} [options] Options object.
7983
+ *
7984
+ * @return {((...args: Parameters<F>) => ReturnType<F>) & MemizeMemoizedFunction} Memoized function.
7985
+ */
7986
+ function memize(fn, options) {
7987
+ var size = 0;
7988
+ /** @type {?MemizeCacheNode|undefined} */
7989
+ var head;
7990
+ /** @type {?MemizeCacheNode|undefined} */
7991
+ var tail;
7992
+ options = options || {};
7993
+ function memoized() {
7994
+ var node = head, len = arguments.length, args, i;
7995
+ searchCache: while (node) {
7996
+ if (node.args.length !== arguments.length) {
7997
+ node = node.next;
7998
+ continue;
7999
+ }
8000
+ for (i = 0; i < len; i++) if (node.args[i] !== arguments[i]) {
8001
+ node = node.next;
8002
+ continue searchCache;
8003
+ }
8004
+ if (node !== head) {
8005
+ if (node === tail) tail = node.prev;
8006
+ /** @type {MemizeCacheNode} */ node.prev.next = node.next;
8007
+ if (node.next) node.next.prev = node.prev;
8008
+ node.next = head;
8009
+ node.prev = null;
8010
+ /** @type {MemizeCacheNode} */ head.prev = node;
8011
+ head = node;
8012
+ }
8013
+ return node.val;
8014
+ }
8015
+ args = new Array(len);
8016
+ for (i = 0; i < len; i++) args[i] = arguments[i];
8017
+ node = {
8018
+ args,
8019
+ val: fn.apply(null, args)
8020
+ };
8021
+ if (head) {
8022
+ head.prev = node;
8023
+ node.next = head;
8024
+ } else tail = node;
8025
+ if (size === options.maxSize) {
8026
+ tail = tail.prev;
8027
+ /** @type {MemizeCacheNode} */ tail.next = null;
8028
+ } else size++;
8029
+ head = node;
8030
+ return node.val;
8031
+ }
8032
+ memoized.clear = function() {
8033
+ head = null;
8034
+ tail = null;
8035
+ size = 0;
8036
+ };
8037
+ return memoized;
8038
+ }
8039
+ //#endregion
8040
+ //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/utils/colors-values.mjs
8041
+ var white = "#fff";
8042
+ var GRAY = {
8043
+ 900: "#1e1e1e",
8044
+ 800: "#2f2f2f",
8045
+ /** Meets 4.6:1 text contrast against white. */
8046
+ 700: "#757575",
8047
+ /** Meets 3:1 UI or large text contrast against white. */
8048
+ 600: "#949494",
8049
+ 400: "#ccc",
8050
+ /** Used for most borders. */
8051
+ 300: "#ddd",
8052
+ /** Used sparingly for light borders. */
8053
+ 200: "#e0e0e0",
8054
+ /** Used for light gray backgrounds. */
8055
+ 100: "#f0f0f0"
8056
+ };
8057
+ var ALERT = {
8058
+ yellow: "#f0b849",
8059
+ red: "#d94f4f",
8060
+ green: "#4ab866"
8061
+ };
8062
+ var THEME = {
8063
+ accent: `var(--wp-components-color-accent, var(--wp-admin-theme-color, #3858e9))`,
8064
+ accentDarker10: `var(--wp-components-color-accent-darker-10, var(--wp-admin-theme-color-darker-10, #2145e6))`,
8065
+ accentDarker20: `var(--wp-components-color-accent-darker-20, var(--wp-admin-theme-color-darker-20, #183ad6))`,
8066
+ /** Used when placing text on the accent color. */
8067
+ accentInverted: `var(--wp-components-color-accent-inverted, var(--wpds-color-foreground-interactive-brand-strong, #fff))`,
8068
+ background: `var(--wp-components-color-background, var(--wpds-color-background-surface-neutral-strong, #fff))`,
8069
+ foreground: `var(--wp-components-color-foreground, var(--wpds-color-foreground-content-neutral, #1e1e1e))`,
8070
+ /** Used when placing text on the foreground color. */
8071
+ foregroundInverted: `var(--wp-components-color-foreground-inverted, var(--wpds-color-background-surface-neutral, #fcfcfc))`,
8072
+ gray: {
8073
+ /** @deprecated Use `COLORS.theme.foreground` instead. */
8074
+ 900: `var(--wp-components-color-foreground, var(--wpds-color-foreground-content-neutral, #1e1e1e))`,
8075
+ 800: `var(--wp-components-color-gray-800, var(--wpds-color-foreground-content-neutral, #1e1e1e))`,
8076
+ 700: `var(--wp-components-color-gray-700, var(--wpds-color-foreground-content-neutral-weak, #707070))`,
8077
+ 600: `var(--wp-components-color-gray-600, var(--wpds-color-stroke-interactive-neutral, #8d8d8d))`,
8078
+ 400: `var(--wp-components-color-gray-400, var(--wpds-color-stroke-interactive-neutral, #8d8d8d))`,
8079
+ 300: `var(--wp-components-color-gray-300, var(--wpds-color-stroke-surface-neutral, #dbdbdb))`,
8080
+ 200: `var(--wp-components-color-gray-200, var(--wpds-color-stroke-surface-neutral, #dbdbdb))`,
8081
+ 100: `var(--wp-components-color-gray-100, var(--wpds-color-background-surface-neutral, #fcfcfc))`
8082
+ }
8083
+ };
8084
+ var UI = {
8085
+ background: THEME.background,
8086
+ backgroundDisabled: THEME.gray[100],
8087
+ border: THEME.gray[600],
8088
+ borderHover: THEME.gray[700],
8089
+ borderFocus: THEME.accent,
8090
+ borderDisabled: THEME.gray[400],
8091
+ textDisabled: THEME.gray[600],
8092
+ darkGrayPlaceholder: `color-mix(in srgb, ${THEME.foreground}, transparent 38%)`,
8093
+ lightGrayPlaceholder: `color-mix(in srgb, ${THEME.background}, transparent 35%)`
8094
+ };
8095
+ var COLORS = Object.freeze({
8096
+ /**
8097
+ * The main gray color object.
8098
+ *
8099
+ * @deprecated Use semantic aliases in `COLORS.ui` or theme-ready variables in `COLORS.theme.gray`.
8100
+ */
8101
+ gray: GRAY,
8102
+ /**
8103
+ * @deprecated Prefer theme-ready variables in `COLORS.theme`.
8104
+ */
8105
+ white,
8106
+ alert: ALERT,
8107
+ /**
8108
+ * Theme-ready variables with fallbacks.
8109
+ *
8110
+ * Prefer semantic aliases in `COLORS.ui` when applicable.
8111
+ */
8112
+ theme: THEME,
8113
+ /**
8114
+ * Semantic aliases (prefer these over raw variables when applicable).
8115
+ */
8116
+ ui: UI
8117
+ });
8118
+ //#endregion
8119
+ //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/utils/config-values.mjs
8120
+ var CONTROL_HEIGHT = "36px";
8121
+ var CONTROL_PROPS = {
8122
+ controlPaddingX: 12,
8123
+ controlPaddingXSmall: 8,
8124
+ controlPaddingXLarge: 12 * 1.3334,
8125
+ controlBoxShadowFocus: `0 0 0 0.5px ${COLORS.theme.accent}`,
8126
+ controlHeight: CONTROL_HEIGHT,
8127
+ controlHeightXSmall: `calc( ${CONTROL_HEIGHT} * 0.6 )`,
8128
+ controlHeightSmall: `calc( ${CONTROL_HEIGHT} * 0.8 )`,
8129
+ controlHeightLarge: `calc( ${CONTROL_HEIGHT} * 1.2 )`,
8130
+ controlHeightXLarge: `calc( ${CONTROL_HEIGHT} * 1.4 )`
8131
+ };
8132
+ var config_values_default = Object.assign({}, CONTROL_PROPS, {
8133
+ colorDivider: "rgba(0, 0, 0, 0.1)",
8134
+ colorScrollbarThumb: "rgba(0, 0, 0, 0.2)",
8135
+ colorScrollbarThumbHover: "rgba(0, 0, 0, 0.5)",
8136
+ colorScrollbarTrack: "rgba(0, 0, 0, 0.04)",
8137
+ elevationIntensity: 1,
8138
+ radiusXSmall: "1px",
8139
+ radiusSmall: "2px",
8140
+ radiusMedium: "4px",
8141
+ radiusLarge: "8px",
8142
+ radiusFull: "9999px",
8143
+ radiusRound: "50%",
8144
+ borderWidth: "1px",
8145
+ borderWidthFocus: "1.5px",
8146
+ borderWidthTab: "4px",
8147
+ spinnerSize: 16,
8148
+ fontSize: "13px",
8149
+ fontSizeH1: "calc(2.44 * 13px)",
8150
+ fontSizeH2: "calc(1.95 * 13px)",
8151
+ fontSizeH3: "calc(1.56 * 13px)",
8152
+ fontSizeH4: "calc(1.25 * 13px)",
8153
+ fontSizeH5: "13px",
8154
+ fontSizeH6: "calc(0.8 * 13px)",
8155
+ fontSizeInputMobile: "16px",
8156
+ fontSizeMobile: "15px",
8157
+ fontSizeSmall: "calc(0.92 * 13px)",
8158
+ fontSizeXSmall: "calc(0.75 * 13px)",
8159
+ fontLineHeightBase: "1.4",
8160
+ fontWeight: "normal",
8161
+ fontWeightMedium: "499",
8162
+ fontWeightHeading: "600",
8163
+ gridBase: "4px",
8164
+ elevationXSmall: `0 1px 1px rgba(0, 0, 0, 0.03), 0 1px 2px rgba(0, 0, 0, 0.02), 0 3px 3px rgba(0, 0, 0, 0.02), 0 4px 4px rgba(0, 0, 0, 0.01)`,
8165
+ elevationSmall: `0 1px 2px rgba(0, 0, 0, 0.05), 0 2px 3px rgba(0, 0, 0, 0.04), 0 6px 6px rgba(0, 0, 0, 0.03), 0 8px 8px rgba(0, 0, 0, 0.02)`,
8166
+ elevationMedium: `0 2px 3px rgba(0, 0, 0, 0.05), 0 4px 5px rgba(0, 0, 0, 0.04), 0 12px 12px rgba(0, 0, 0, 0.03), 0 16px 16px rgba(0, 0, 0, 0.02)`,
8167
+ elevationLarge: `0 5px 15px rgba(0, 0, 0, 0.08), 0 15px 27px rgba(0, 0, 0, 0.07), 0 30px 36px rgba(0, 0, 0, 0.04), 0 50px 43px rgba(0, 0, 0, 0.02)`,
8168
+ surfaceBackgroundColor: COLORS.white,
8169
+ surfaceBackgroundSubtleColor: "#F3F3F3",
8170
+ surfaceBackgroundTintColor: "#F5F5F5",
8171
+ surfaceBorderColor: "rgba(0, 0, 0, 0.1)",
8172
+ surfaceBorderBoldColor: "rgba(0, 0, 0, 0.15)",
8173
+ surfaceBorderSubtleColor: "rgba(0, 0, 0, 0.05)",
8174
+ surfaceBackgroundTertiaryColor: COLORS.white,
8175
+ surfaceColor: COLORS.white,
8176
+ transitionDuration: "200ms",
8177
+ transitionDurationFast: "160ms",
8178
+ transitionDurationFaster: "120ms",
8179
+ transitionDurationFastest: "100ms",
8180
+ transitionTimingFunction: "cubic-bezier(0.08, 0.52, 0.52, 1)",
8181
+ transitionTimingFunctionControl: "cubic-bezier(0.12, 0.8, 0.32, 1)"
8182
+ });
8183
+ //#endregion
8184
+ //#region ../../../node_modules/.pnpm/fast-deep-equal@3.1.3/node_modules/fast-deep-equal/es6/index.js
8185
+ var require_es6 = /* @__PURE__ */ __commonJSMin(((exports, module) => {
8186
+ module.exports = function equal(a, b) {
8187
+ if (a === b) return true;
8188
+ if (a && b && typeof a == "object" && typeof b == "object") {
8189
+ if (a.constructor !== b.constructor) return false;
8190
+ var length, i, keys;
8191
+ if (Array.isArray(a)) {
8192
+ length = a.length;
8193
+ if (length != b.length) return false;
8194
+ for (i = length; i-- !== 0;) if (!equal(a[i], b[i])) return false;
8195
+ return true;
8196
+ }
8197
+ if (a instanceof Map && b instanceof Map) {
8198
+ if (a.size !== b.size) return false;
8199
+ for (i of a.entries()) if (!b.has(i[0])) return false;
8200
+ for (i of a.entries()) if (!equal(i[1], b.get(i[0]))) return false;
8201
+ return true;
8202
+ }
8203
+ if (a instanceof Set && b instanceof Set) {
8204
+ if (a.size !== b.size) return false;
8205
+ for (i of a.entries()) if (!b.has(i[0])) return false;
8206
+ return true;
8207
+ }
8208
+ if (ArrayBuffer.isView(a) && ArrayBuffer.isView(b)) {
8209
+ length = a.length;
8210
+ if (length != b.length) return false;
8211
+ for (i = length; i-- !== 0;) if (a[i] !== b[i]) return false;
8212
+ return true;
8213
+ }
8214
+ if (a.constructor === RegExp) return a.source === b.source && a.flags === b.flags;
8215
+ if (a.valueOf !== Object.prototype.valueOf) return a.valueOf() === b.valueOf();
8216
+ if (a.toString !== Object.prototype.toString) return a.toString() === b.toString();
8217
+ keys = Object.keys(a);
8218
+ length = keys.length;
8219
+ if (length !== Object.keys(b).length) return false;
8220
+ for (i = length; i-- !== 0;) if (!Object.prototype.hasOwnProperty.call(b, keys[i])) return false;
8221
+ for (i = length; i-- !== 0;) {
8222
+ var key = keys[i];
8223
+ if (!equal(a[key], b[key])) return false;
8224
+ }
8225
+ return true;
8226
+ }
8227
+ return a !== a && b !== b;
8228
+ };
8229
+ }));
8230
+ //#endregion
8231
+ //#region ../../../node_modules/.pnpm/@wordpress+warning@3.50.0/node_modules/@wordpress/warning/build-module/utils.mjs
8232
+ var logged = /* @__PURE__ */ new Set();
8233
+ //#endregion
8234
+ //#region ../../../node_modules/.pnpm/@wordpress+warning@3.50.0/node_modules/@wordpress/warning/build-module/index.mjs
8235
+ function isDev() {
8236
+ return globalThis.SCRIPT_DEBUG === true;
8237
+ }
8238
+ function warning(message) {
8239
+ if (!isDev()) return;
8240
+ if (logged.has(message)) return;
8241
+ console.warn(message);
8242
+ try {
8243
+ throw Error(message);
8244
+ } catch {}
8245
+ logged.add(message);
8246
+ }
8247
+ //#endregion
8248
+ //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/context/context-system-provider.mjs
8249
+ var import_es6 = /* @__PURE__ */ __toESM(require_es6(), 1);
8250
+ var ComponentsContext = createContext$1(
8251
+ /** @type {Record<string, any>} */
8252
+ {}
8253
+ );
8254
+ ComponentsContext.displayName = "ComponentsContext";
8255
+ var useComponentsContext = () => useContext$1(ComponentsContext);
8256
+ function useContextSystemBridge({ value }) {
8257
+ const parentContext = useComponentsContext();
8258
+ const valueRef = useRef$1(value);
8259
+ use_update_effect_default(() => {
8260
+ if ((0, import_es6.default)(valueRef.current, value) && valueRef.current !== value) globalThis.SCRIPT_DEBUG === true && warning(`Please memoize your context: ${JSON.stringify(value)}`);
8261
+ }, [value]);
8262
+ return useMemo$1(() => {
8263
+ return deepmerge(parentContext ?? {}, value ?? {}, { isMergeableObject: isPlainObject });
8264
+ }, [parentContext, value]);
8265
+ }
8266
+ var BaseContextSystemProvider = ({ children, value }) => {
8267
+ const contextValue = useContextSystemBridge({ value });
8268
+ return /* @__PURE__ */ jsx(ComponentsContext.Provider, {
8269
+ value: contextValue,
8270
+ children
8271
+ });
8272
+ };
8273
+ memo(BaseContextSystemProvider);
8274
+ //#endregion
8275
+ //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/context/constants.mjs
8276
+ var COMPONENT_NAMESPACE = "data-wp-component";
8277
+ var CONNECTED_NAMESPACE = "data-wp-c16t";
8278
+ var CONNECT_STATIC_NAMESPACE = "__contextSystemKey__";
8279
+ //#endregion
8280
+ //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/context/get-styled-class-name-from-key.mjs
8281
+ function getStyledClassName(namespace) {
8282
+ return `components-${paramCase(namespace)}`;
8283
+ }
8284
+ var getStyledClassNameFromKey = memize(getStyledClassName);
8285
+ //#endregion
8286
+ //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/context/context-connect.mjs
8287
+ function contextConnect(Component, namespace) {
8288
+ return _contextConnect(Component, namespace, { forwardsRef: true });
8289
+ }
8290
+ function _contextConnect(Component, namespace, options) {
8291
+ const WrappedComponent = options?.forwardsRef ? forwardRef$1(Component) : Component;
8292
+ if (typeof namespace === "undefined") globalThis.SCRIPT_DEBUG === true && warning("contextConnect: Please provide a namespace");
8293
+ let mergedNamespace = WrappedComponent["__contextSystemKey__"] || [namespace];
8294
+ if (Array.isArray(namespace)) mergedNamespace = [...mergedNamespace, ...namespace];
8295
+ if (typeof namespace === "string") mergedNamespace = [...mergedNamespace, namespace];
8296
+ return Object.assign(WrappedComponent, {
8297
+ [CONNECT_STATIC_NAMESPACE]: [...new Set(mergedNamespace)],
8298
+ displayName: namespace,
8299
+ selector: `.${getStyledClassNameFromKey(namespace)}`
8300
+ });
8301
+ }
8302
+ //#endregion
8303
+ //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/context/utils.mjs
8304
+ function getNamespace(componentName) {
8305
+ return { [COMPONENT_NAMESPACE]: componentName };
8306
+ }
8307
+ function getConnectedNamespace() {
8308
+ return { [CONNECTED_NAMESPACE]: true };
8309
+ }
8310
+ //#endregion
8311
+ //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/context/use-context-system.mjs
8312
+ function useContextSystem(props, namespace) {
8313
+ const contextSystemProps = useComponentsContext();
8314
+ if (typeof namespace === "undefined") globalThis.SCRIPT_DEBUG === true && warning("useContextSystem: Please provide a namespace");
8315
+ const contextProps = contextSystemProps?.[namespace] || {};
8116
8316
  const finalComponentProps = {
8117
8317
  ...getConnectedNamespace(),
8118
8318
  ...getNamespace(namespace)
@@ -8128,6 +8328,22 @@ function useContextSystem(props, namespace) {
8128
8328
  return finalComponentProps;
8129
8329
  }
8130
8330
  //#endregion
8331
+ //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/visually-hidden/styles.mjs
8332
+ var visuallyHidden = {
8333
+ border: 0,
8334
+ clip: "rect(1px, 1px, 1px, 1px)",
8335
+ WebkitClipPath: "inset( 50% )",
8336
+ clipPath: "inset( 50% )",
8337
+ height: "1px",
8338
+ margin: "-1px",
8339
+ overflow: "hidden",
8340
+ padding: 0,
8341
+ position: "absolute",
8342
+ width: "1px",
8343
+ wordWrap: "normal",
8344
+ wordBreak: "normal"
8345
+ };
8346
+ //#endregion
8131
8347
  //#region ../../../node_modules/.pnpm/@emotion+is-prop-valid@1.4.0/node_modules/@emotion/is-prop-valid/dist/emotion-is-prop-valid.esm.js
8132
8348
  var reactPropsRegex = /^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|fetchpriority|fetchPriority|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|popover|popoverTarget|popoverTargetAction|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/;
8133
8349
  var isPropValid = /* #__PURE__ */ memoize(function(prop) {
@@ -8243,7 +8459,56 @@ function UnforwardedView({ as, ...restProps }, ref) {
8243
8459
  ...restProps
8244
8460
  });
8245
8461
  }
8246
- var component_default$1 = Object.assign(forwardRef$1(UnforwardedView), { selector: ".components-view" });
8462
+ var component_default$2 = Object.assign(forwardRef$1(UnforwardedView), { selector: ".components-view" });
8463
+ //#endregion
8464
+ //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/visually-hidden/component.mjs
8465
+ function UnconnectedVisuallyHidden(props, forwardedRef) {
8466
+ const { style: styleProp, ...contextProps } = useContextSystem(props, "VisuallyHidden");
8467
+ return /* @__PURE__ */ jsx(component_default$2, {
8468
+ ref: forwardedRef,
8469
+ ...contextProps,
8470
+ "data-visually-hidden": "",
8471
+ style: {
8472
+ ...visuallyHidden,
8473
+ ...styleProp || {}
8474
+ }
8475
+ });
8476
+ }
8477
+ var component_default$1 = contextConnect(UnconnectedVisuallyHidden, "VisuallyHidden");
8478
+ //#endregion
8479
+ //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/utils/use-responsive-value.mjs
8480
+ var breakpoints = [
8481
+ "40em",
8482
+ "52em",
8483
+ "64em"
8484
+ ];
8485
+ var useBreakpointIndex = (options = {}) => {
8486
+ const { defaultIndex = 0 } = options;
8487
+ if (typeof defaultIndex !== "number") throw new TypeError(`Default breakpoint index should be a number. Got: ${defaultIndex}, ${typeof defaultIndex}`);
8488
+ else if (defaultIndex < 0 || defaultIndex > breakpoints.length - 1) throw new RangeError(`Default breakpoint index out of range. Theme has ${breakpoints.length} breakpoints, got index ${defaultIndex}`);
8489
+ const [value, setValue] = useState$1(defaultIndex);
8490
+ useEffect$1(() => {
8491
+ const getIndex = () => breakpoints.filter((bp) => {
8492
+ return typeof window !== "undefined" ? window.matchMedia(`screen and (min-width: ${bp})`).matches : false;
8493
+ }).length;
8494
+ const onResize = () => {
8495
+ const newValue = getIndex();
8496
+ if (value !== newValue) setValue(newValue);
8497
+ };
8498
+ onResize();
8499
+ if (typeof window !== "undefined") window.addEventListener("resize", onResize);
8500
+ return () => {
8501
+ if (typeof window !== "undefined") window.removeEventListener("resize", onResize);
8502
+ };
8503
+ }, [value]);
8504
+ return value;
8505
+ };
8506
+ function useResponsiveValue(values, options = {}) {
8507
+ const index = useBreakpointIndex(options);
8508
+ if (!Array.isArray(values) && typeof values !== "function") return values;
8509
+ const array = values || [];
8510
+ return array[index >= array.length ? array.length - 1 : index];
8511
+ }
8247
8512
  //#endregion
8248
8513
  //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/grid/utils.mjs
8249
8514
  var ALIGNMENTS = {
@@ -8293,184 +8558,6 @@ function getAlignmentProps(alignment) {
8293
8558
  return alignment ? ALIGNMENTS[alignment] : {};
8294
8559
  }
8295
8560
  //#endregion
8296
- //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/utils/use-responsive-value.mjs
8297
- var breakpoints = [
8298
- "40em",
8299
- "52em",
8300
- "64em"
8301
- ];
8302
- var useBreakpointIndex = (options = {}) => {
8303
- const { defaultIndex = 0 } = options;
8304
- if (typeof defaultIndex !== "number") throw new TypeError(`Default breakpoint index should be a number. Got: ${defaultIndex}, ${typeof defaultIndex}`);
8305
- else if (defaultIndex < 0 || defaultIndex > breakpoints.length - 1) throw new RangeError(`Default breakpoint index out of range. Theme has ${breakpoints.length} breakpoints, got index ${defaultIndex}`);
8306
- const [value, setValue] = useState$1(defaultIndex);
8307
- useEffect$1(() => {
8308
- const getIndex = () => breakpoints.filter((bp) => {
8309
- return typeof window !== "undefined" ? window.matchMedia(`screen and (min-width: ${bp})`).matches : false;
8310
- }).length;
8311
- const onResize = () => {
8312
- const newValue = getIndex();
8313
- if (value !== newValue) setValue(newValue);
8314
- };
8315
- onResize();
8316
- if (typeof window !== "undefined") window.addEventListener("resize", onResize);
8317
- return () => {
8318
- if (typeof window !== "undefined") window.removeEventListener("resize", onResize);
8319
- };
8320
- }, [value]);
8321
- return value;
8322
- };
8323
- function useResponsiveValue(values, options = {}) {
8324
- const index = useBreakpointIndex(options);
8325
- if (!Array.isArray(values) && typeof values !== "function") return values;
8326
- const array = values || [];
8327
- return array[index >= array.length ? array.length - 1 : index];
8328
- }
8329
- //#endregion
8330
- //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/utils/colors-values.mjs
8331
- var white = "#fff";
8332
- var GRAY = {
8333
- 900: "#1e1e1e",
8334
- 800: "#2f2f2f",
8335
- /** Meets 4.6:1 text contrast against white. */
8336
- 700: "#757575",
8337
- /** Meets 3:1 UI or large text contrast against white. */
8338
- 600: "#949494",
8339
- 400: "#ccc",
8340
- /** Used for most borders. */
8341
- 300: "#ddd",
8342
- /** Used sparingly for light borders. */
8343
- 200: "#e0e0e0",
8344
- /** Used for light gray backgrounds. */
8345
- 100: "#f0f0f0"
8346
- };
8347
- var ALERT = {
8348
- yellow: "#f0b849",
8349
- red: "#d94f4f",
8350
- green: "#4ab866"
8351
- };
8352
- var THEME = {
8353
- accent: `var(--wp-components-color-accent, var(--wp-admin-theme-color, #3858e9))`,
8354
- accentDarker10: `var(--wp-components-color-accent-darker-10, var(--wp-admin-theme-color-darker-10, #2145e6))`,
8355
- accentDarker20: `var(--wp-components-color-accent-darker-20, var(--wp-admin-theme-color-darker-20, #183ad6))`,
8356
- /** Used when placing text on the accent color. */
8357
- accentInverted: `var(--wp-components-color-accent-inverted, var(--wpds-color-foreground-interactive-brand-strong, #fff))`,
8358
- background: `var(--wp-components-color-background, var(--wpds-color-background-surface-neutral-strong, #fff))`,
8359
- foreground: `var(--wp-components-color-foreground, var(--wpds-color-foreground-content-neutral, #1e1e1e))`,
8360
- /** Used when placing text on the foreground color. */
8361
- foregroundInverted: `var(--wp-components-color-foreground-inverted, var(--wpds-color-background-surface-neutral, #fcfcfc))`,
8362
- gray: {
8363
- /** @deprecated Use `COLORS.theme.foreground` instead. */
8364
- 900: `var(--wp-components-color-foreground, var(--wpds-color-foreground-content-neutral, #1e1e1e))`,
8365
- 800: `var(--wp-components-color-gray-800, var(--wpds-color-foreground-content-neutral, #1e1e1e))`,
8366
- 700: `var(--wp-components-color-gray-700, var(--wpds-color-foreground-content-neutral-weak, #707070))`,
8367
- 600: `var(--wp-components-color-gray-600, var(--wpds-color-stroke-interactive-neutral, #8d8d8d))`,
8368
- 400: `var(--wp-components-color-gray-400, var(--wpds-color-stroke-interactive-neutral, #8d8d8d))`,
8369
- 300: `var(--wp-components-color-gray-300, var(--wpds-color-stroke-surface-neutral, #dbdbdb))`,
8370
- 200: `var(--wp-components-color-gray-200, var(--wpds-color-stroke-surface-neutral, #dbdbdb))`,
8371
- 100: `var(--wp-components-color-gray-100, var(--wpds-color-background-surface-neutral, #fcfcfc))`
8372
- }
8373
- };
8374
- var UI = {
8375
- background: THEME.background,
8376
- backgroundDisabled: THEME.gray[100],
8377
- border: THEME.gray[600],
8378
- borderHover: THEME.gray[700],
8379
- borderFocus: THEME.accent,
8380
- borderDisabled: THEME.gray[400],
8381
- textDisabled: THEME.gray[600],
8382
- darkGrayPlaceholder: `color-mix(in srgb, ${THEME.foreground}, transparent 38%)`,
8383
- lightGrayPlaceholder: `color-mix(in srgb, ${THEME.background}, transparent 35%)`
8384
- };
8385
- var COLORS = Object.freeze({
8386
- /**
8387
- * The main gray color object.
8388
- *
8389
- * @deprecated Use semantic aliases in `COLORS.ui` or theme-ready variables in `COLORS.theme.gray`.
8390
- */
8391
- gray: GRAY,
8392
- /**
8393
- * @deprecated Prefer theme-ready variables in `COLORS.theme`.
8394
- */
8395
- white,
8396
- alert: ALERT,
8397
- /**
8398
- * Theme-ready variables with fallbacks.
8399
- *
8400
- * Prefer semantic aliases in `COLORS.ui` when applicable.
8401
- */
8402
- theme: THEME,
8403
- /**
8404
- * Semantic aliases (prefer these over raw variables when applicable).
8405
- */
8406
- ui: UI
8407
- });
8408
- //#endregion
8409
- //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/utils/config-values.mjs
8410
- var CONTROL_HEIGHT = "36px";
8411
- var CONTROL_PROPS = {
8412
- controlPaddingX: 12,
8413
- controlPaddingXSmall: 8,
8414
- controlPaddingXLarge: 12 * 1.3334,
8415
- controlBoxShadowFocus: `0 0 0 0.5px ${COLORS.theme.accent}`,
8416
- controlHeight: CONTROL_HEIGHT,
8417
- controlHeightXSmall: `calc( ${CONTROL_HEIGHT} * 0.6 )`,
8418
- controlHeightSmall: `calc( ${CONTROL_HEIGHT} * 0.8 )`,
8419
- controlHeightLarge: `calc( ${CONTROL_HEIGHT} * 1.2 )`,
8420
- controlHeightXLarge: `calc( ${CONTROL_HEIGHT} * 1.4 )`
8421
- };
8422
- var config_values_default = Object.assign({}, CONTROL_PROPS, {
8423
- colorDivider: "rgba(0, 0, 0, 0.1)",
8424
- colorScrollbarThumb: "rgba(0, 0, 0, 0.2)",
8425
- colorScrollbarThumbHover: "rgba(0, 0, 0, 0.5)",
8426
- colorScrollbarTrack: "rgba(0, 0, 0, 0.04)",
8427
- elevationIntensity: 1,
8428
- radiusXSmall: "1px",
8429
- radiusSmall: "2px",
8430
- radiusMedium: "4px",
8431
- radiusLarge: "8px",
8432
- radiusFull: "9999px",
8433
- radiusRound: "50%",
8434
- borderWidth: "1px",
8435
- borderWidthFocus: "1.5px",
8436
- borderWidthTab: "4px",
8437
- spinnerSize: 16,
8438
- fontSize: "13px",
8439
- fontSizeH1: "calc(2.44 * 13px)",
8440
- fontSizeH2: "calc(1.95 * 13px)",
8441
- fontSizeH3: "calc(1.56 * 13px)",
8442
- fontSizeH4: "calc(1.25 * 13px)",
8443
- fontSizeH5: "13px",
8444
- fontSizeH6: "calc(0.8 * 13px)",
8445
- fontSizeInputMobile: "16px",
8446
- fontSizeMobile: "15px",
8447
- fontSizeSmall: "calc(0.92 * 13px)",
8448
- fontSizeXSmall: "calc(0.75 * 13px)",
8449
- fontLineHeightBase: "1.4",
8450
- fontWeight: "normal",
8451
- fontWeightMedium: "499",
8452
- fontWeightHeading: "600",
8453
- gridBase: "4px",
8454
- elevationXSmall: `0 1px 1px rgba(0, 0, 0, 0.03), 0 1px 2px rgba(0, 0, 0, 0.02), 0 3px 3px rgba(0, 0, 0, 0.02), 0 4px 4px rgba(0, 0, 0, 0.01)`,
8455
- elevationSmall: `0 1px 2px rgba(0, 0, 0, 0.05), 0 2px 3px rgba(0, 0, 0, 0.04), 0 6px 6px rgba(0, 0, 0, 0.03), 0 8px 8px rgba(0, 0, 0, 0.02)`,
8456
- elevationMedium: `0 2px 3px rgba(0, 0, 0, 0.05), 0 4px 5px rgba(0, 0, 0, 0.04), 0 12px 12px rgba(0, 0, 0, 0.03), 0 16px 16px rgba(0, 0, 0, 0.02)`,
8457
- elevationLarge: `0 5px 15px rgba(0, 0, 0, 0.08), 0 15px 27px rgba(0, 0, 0, 0.07), 0 30px 36px rgba(0, 0, 0, 0.04), 0 50px 43px rgba(0, 0, 0, 0.02)`,
8458
- surfaceBackgroundColor: COLORS.white,
8459
- surfaceBackgroundSubtleColor: "#F3F3F3",
8460
- surfaceBackgroundTintColor: "#F5F5F5",
8461
- surfaceBorderColor: "rgba(0, 0, 0, 0.1)",
8462
- surfaceBorderBoldColor: "rgba(0, 0, 0, 0.15)",
8463
- surfaceBorderSubtleColor: "rgba(0, 0, 0, 0.05)",
8464
- surfaceBackgroundTertiaryColor: COLORS.white,
8465
- surfaceColor: COLORS.white,
8466
- transitionDuration: "200ms",
8467
- transitionDurationFast: "160ms",
8468
- transitionDurationFaster: "120ms",
8469
- transitionDurationFastest: "100ms",
8470
- transitionTimingFunction: "cubic-bezier(0.08, 0.52, 0.52, 1)",
8471
- transitionTimingFunctionControl: "cubic-bezier(0.12, 0.8, 0.32, 1)"
8472
- });
8473
- //#endregion
8474
8561
  //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/grid/hook.mjs
8475
8562
  function useGrid(props) {
8476
8563
  const { align, alignment, className, columnGap, columns = 2, gap = 3, isInline = false, justify, rowGap, rows, templateColumns, templateRows, ...otherProps } = useContextSystem(props, "Grid");
@@ -8481,7 +8568,7 @@ function useGrid(props) {
8481
8568
  const cx = useCx();
8482
8569
  const classes = useMemo$1(() => {
8483
8570
  const alignmentProps = getAlignmentProps(alignment);
8484
- return cx(/* @__PURE__ */ css$1({
8571
+ const gridClasses = /* @__PURE__ */ css$1({
8485
8572
  alignItems: align,
8486
8573
  display: isInline ? "inline-grid" : "grid",
8487
8574
  gap: `calc( ${config_values_default.gridBase} * ${gap} )`,
@@ -8492,7 +8579,8 @@ function useGrid(props) {
8492
8579
  justifyContent: justify,
8493
8580
  verticalAlign: isInline ? "middle" : void 0,
8494
8581
  ...alignmentProps
8495
- }, process.env.NODE_ENV === "production" ? "" : ";label:gridClasses;", process.env.NODE_ENV === "production" ? "" : "/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbImhvb2sudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBdURzQiIsImZpbGUiOiJob29rLnRzIiwic291cmNlc0NvbnRlbnQiOlsiLyoqXG4gKiBFeHRlcm5hbCBkZXBlbmRlbmNpZXNcbiAqL1xuaW1wb3J0IHsgY3NzIH0gZnJvbSAnQGVtb3Rpb24vcmVhY3QnO1xuXG4vKipcbiAqIFdvcmRQcmVzcyBkZXBlbmRlbmNpZXNcbiAqL1xuaW1wb3J0IHsgdXNlTWVtbyB9IGZyb20gJ0B3b3JkcHJlc3MvZWxlbWVudCc7XG5cbi8qKlxuICogSW50ZXJuYWwgZGVwZW5kZW5jaWVzXG4gKi9cbmltcG9ydCB0eXBlIHsgV29yZFByZXNzQ29tcG9uZW50UHJvcHMgfSBmcm9tICcuLi9jb250ZXh0JztcbmltcG9ydCB7IHVzZUNvbnRleHRTeXN0ZW0gfSBmcm9tICcuLi9jb250ZXh0JztcbmltcG9ydCB7IGdldEFsaWdubWVudFByb3BzIH0gZnJvbSAnLi91dGlscyc7XG5pbXBvcnQgeyB1c2VSZXNwb25zaXZlVmFsdWUgfSBmcm9tICcuLi91dGlscy91c2UtcmVzcG9uc2l2ZS12YWx1ZSc7XG5pbXBvcnQgQ09ORklHIGZyb20gJy4uL3V0aWxzL2NvbmZpZy12YWx1ZXMnO1xuaW1wb3J0IHsgdXNlQ3ggfSBmcm9tICcuLi91dGlscy9ob29rcy91c2UtY3gnO1xuaW1wb3J0IHR5cGUgeyBHcmlkUHJvcHMgfSBmcm9tICcuL3R5cGVzJztcblxuZXhwb3J0IGRlZmF1bHQgZnVuY3Rpb24gdXNlR3JpZChcblx0cHJvcHM6IFdvcmRQcmVzc0NvbXBvbmVudFByb3BzPCBHcmlkUHJvcHMsICdkaXYnID5cbikge1xuXHRjb25zdCB7XG5cdFx0YWxpZ24sXG5cdFx0YWxpZ25tZW50LFxuXHRcdGNsYXNzTmFtZSxcblx0XHRjb2x1bW5HYXAsXG5cdFx0Y29sdW1ucyA9IDIsXG5cdFx0Z2FwID0gMyxcblx0XHRpc0lubGluZSA9IGZhbHNlLFxuXHRcdGp1c3RpZnksXG5cdFx0cm93R2FwLFxuXHRcdHJvd3MsXG5cdFx0dGVtcGxhdGVDb2x1bW5zLFxuXHRcdHRlbXBsYXRlUm93cyxcblx0XHQuLi5vdGhlclByb3BzXG5cdH0gPSB1c2VDb250ZXh0U3lzdGVtKCBwcm9wcywgJ0dyaWQnICk7XG5cblx0Y29uc3QgY29sdW1uc0FzQXJyYXkgPSBBcnJheS5pc0FycmF5KCBjb2x1bW5zICkgPyBjb2x1bW5zIDogWyBjb2x1bW5zIF07XG5cdGNvbnN0IGNvbHVtbiA9IHVzZVJlc3BvbnNpdmVWYWx1ZSggY29sdW1uc0FzQXJyYXkgKTtcblx0Y29uc3Qgcm93c0FzQXJyYXkgPSBBcnJheS5pc0FycmF5KCByb3dzICkgPyByb3dzIDogWyByb3dzIF07XG5cdGNvbnN0IHJvdyA9IHVzZVJlc3BvbnNpdmVWYWx1ZSggcm93c0FzQXJyYXkgKTtcblxuXHRjb25zdCBncmlkVGVtcGxhdGVDb2x1bW5zID1cblx0XHR0ZW1wbGF0ZUNvbHVtbnMgfHwgKCAhISBjb2x1bW5zICYmIGByZXBlYXQoICR7IGNvbHVtbiB9LCAxZnIgKWAgKTtcblx0Y29uc3QgZ3JpZFRlbXBsYXRlUm93cyA9XG5cdFx0dGVtcGxhdGVSb3dzIHx8ICggISEgcm93cyAmJiBgcmVwZWF0KCAkeyByb3cgfSwgMWZyIClgICk7XG5cblx0Y29uc3QgY3ggPSB1c2VDeCgpO1xuXG5cdGNvbnN0IGNsYXNzZXMgPSB1c2VNZW1vKCAoKSA9PiB7XG5cdFx0Y29uc3QgYWxpZ25tZW50UHJvcHMgPSBnZXRBbGlnbm1lbnRQcm9wcyggYWxpZ25tZW50ICk7XG5cblx0XHRjb25zdCBncmlkQ2xhc3NlcyA9IGNzcygge1xuXHRcdFx0YWxpZ25JdGVtczogYWxpZ24sXG5cdFx0XHRkaXNwbGF5OiBpc0lubGluZSA/ICdpbmxpbmUtZ3JpZCcgOiAnZ3JpZCcsXG5cdFx0XHRnYXA6IGBjYWxjKCAkeyBDT05GSUcuZ3JpZEJhc2UgfSAqICR7IGdhcCB9IClgLFxuXHRcdFx0Z3JpZFRlbXBsYXRlQ29sdW1uczogZ3JpZFRlbXBsYXRlQ29sdW1ucyB8fCB1bmRlZmluZWQsXG5cdFx0XHRncmlkVGVtcGxhdGVSb3dzOiBncmlkVGVtcGxhdGVSb3dzIHx8IHVuZGVmaW5lZCxcblx0XHRcdGdyaWRSb3dHYXA6IHJvd0dhcCxcblx0XHRcdGdyaWRDb2x1bW5HYXA6IGNvbHVtbkdhcCxcblx0XHRcdGp1c3RpZnlDb250ZW50OiBqdXN0aWZ5LFxuXHRcdFx0dmVydGljYWxBbGlnbjogaXNJbmxpbmUgPyAnbWlkZGxlJyA6IHVuZGVmaW5lZCxcblx0XHRcdC4uLmFsaWdubWVudFByb3BzLFxuXHRcdH0gKTtcblxuXHRcdHJldHVybiBjeCggZ3JpZENsYXNzZXMsIGNsYXNzTmFtZSApO1xuXHR9LCBbXG5cdFx0YWxpZ24sXG5cdFx0YWxpZ25tZW50LFxuXHRcdGNsYXNzTmFtZSxcblx0XHRjb2x1bW5HYXAsXG5cdFx0Y3gsXG5cdFx0Z2FwLFxuXHRcdGdyaWRUZW1wbGF0ZUNvbHVtbnMsXG5cdFx0Z3JpZFRlbXBsYXRlUm93cyxcblx0XHRpc0lubGluZSxcblx0XHRqdXN0aWZ5LFxuXHRcdHJvd0dhcCxcblx0XSApO1xuXG5cdHJldHVybiB7IC4uLm90aGVyUHJvcHMsIGNsYXNzTmFtZTogY2xhc3NlcyB9O1xufVxuIl19 */"), className);
8582
+ }, process.env.NODE_ENV === "production" ? "" : ";label:gridClasses;", process.env.NODE_ENV === "production" ? "" : "/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbImhvb2sudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBdURzQiIsImZpbGUiOiJob29rLnRzIiwic291cmNlc0NvbnRlbnQiOlsiLyoqXG4gKiBFeHRlcm5hbCBkZXBlbmRlbmNpZXNcbiAqL1xuaW1wb3J0IHsgY3NzIH0gZnJvbSAnQGVtb3Rpb24vcmVhY3QnO1xuXG4vKipcbiAqIFdvcmRQcmVzcyBkZXBlbmRlbmNpZXNcbiAqL1xuaW1wb3J0IHsgdXNlTWVtbyB9IGZyb20gJ0B3b3JkcHJlc3MvZWxlbWVudCc7XG5cbi8qKlxuICogSW50ZXJuYWwgZGVwZW5kZW5jaWVzXG4gKi9cbmltcG9ydCB0eXBlIHsgV29yZFByZXNzQ29tcG9uZW50UHJvcHMgfSBmcm9tICcuLi9jb250ZXh0JztcbmltcG9ydCB7IHVzZUNvbnRleHRTeXN0ZW0gfSBmcm9tICcuLi9jb250ZXh0JztcbmltcG9ydCB7IGdldEFsaWdubWVudFByb3BzIH0gZnJvbSAnLi91dGlscyc7XG5pbXBvcnQgeyB1c2VSZXNwb25zaXZlVmFsdWUgfSBmcm9tICcuLi91dGlscy91c2UtcmVzcG9uc2l2ZS12YWx1ZSc7XG5pbXBvcnQgQ09ORklHIGZyb20gJy4uL3V0aWxzL2NvbmZpZy12YWx1ZXMnO1xuaW1wb3J0IHsgdXNlQ3ggfSBmcm9tICcuLi91dGlscy9ob29rcy91c2UtY3gnO1xuaW1wb3J0IHR5cGUgeyBHcmlkUHJvcHMgfSBmcm9tICcuL3R5cGVzJztcblxuZXhwb3J0IGRlZmF1bHQgZnVuY3Rpb24gdXNlR3JpZChcblx0cHJvcHM6IFdvcmRQcmVzc0NvbXBvbmVudFByb3BzPCBHcmlkUHJvcHMsICdkaXYnID5cbikge1xuXHRjb25zdCB7XG5cdFx0YWxpZ24sXG5cdFx0YWxpZ25tZW50LFxuXHRcdGNsYXNzTmFtZSxcblx0XHRjb2x1bW5HYXAsXG5cdFx0Y29sdW1ucyA9IDIsXG5cdFx0Z2FwID0gMyxcblx0XHRpc0lubGluZSA9IGZhbHNlLFxuXHRcdGp1c3RpZnksXG5cdFx0cm93R2FwLFxuXHRcdHJvd3MsXG5cdFx0dGVtcGxhdGVDb2x1bW5zLFxuXHRcdHRlbXBsYXRlUm93cyxcblx0XHQuLi5vdGhlclByb3BzXG5cdH0gPSB1c2VDb250ZXh0U3lzdGVtKCBwcm9wcywgJ0dyaWQnICk7XG5cblx0Y29uc3QgY29sdW1uc0FzQXJyYXkgPSBBcnJheS5pc0FycmF5KCBjb2x1bW5zICkgPyBjb2x1bW5zIDogWyBjb2x1bW5zIF07XG5cdGNvbnN0IGNvbHVtbiA9IHVzZVJlc3BvbnNpdmVWYWx1ZSggY29sdW1uc0FzQXJyYXkgKTtcblx0Y29uc3Qgcm93c0FzQXJyYXkgPSBBcnJheS5pc0FycmF5KCByb3dzICkgPyByb3dzIDogWyByb3dzIF07XG5cdGNvbnN0IHJvdyA9IHVzZVJlc3BvbnNpdmVWYWx1ZSggcm93c0FzQXJyYXkgKTtcblxuXHRjb25zdCBncmlkVGVtcGxhdGVDb2x1bW5zID1cblx0XHR0ZW1wbGF0ZUNvbHVtbnMgfHwgKCAhISBjb2x1bW5zICYmIGByZXBlYXQoICR7IGNvbHVtbiB9LCAxZnIgKWAgKTtcblx0Y29uc3QgZ3JpZFRlbXBsYXRlUm93cyA9XG5cdFx0dGVtcGxhdGVSb3dzIHx8ICggISEgcm93cyAmJiBgcmVwZWF0KCAkeyByb3cgfSwgMWZyIClgICk7XG5cblx0Y29uc3QgY3ggPSB1c2VDeCgpO1xuXG5cdGNvbnN0IGNsYXNzZXMgPSB1c2VNZW1vKCAoKSA9PiB7XG5cdFx0Y29uc3QgYWxpZ25tZW50UHJvcHMgPSBnZXRBbGlnbm1lbnRQcm9wcyggYWxpZ25tZW50ICk7XG5cblx0XHRjb25zdCBncmlkQ2xhc3NlcyA9IGNzcygge1xuXHRcdFx0YWxpZ25JdGVtczogYWxpZ24sXG5cdFx0XHRkaXNwbGF5OiBpc0lubGluZSA/ICdpbmxpbmUtZ3JpZCcgOiAnZ3JpZCcsXG5cdFx0XHRnYXA6IGBjYWxjKCAkeyBDT05GSUcuZ3JpZEJhc2UgfSAqICR7IGdhcCB9IClgLFxuXHRcdFx0Z3JpZFRlbXBsYXRlQ29sdW1uczogZ3JpZFRlbXBsYXRlQ29sdW1ucyB8fCB1bmRlZmluZWQsXG5cdFx0XHRncmlkVGVtcGxhdGVSb3dzOiBncmlkVGVtcGxhdGVSb3dzIHx8IHVuZGVmaW5lZCxcblx0XHRcdGdyaWRSb3dHYXA6IHJvd0dhcCxcblx0XHRcdGdyaWRDb2x1bW5HYXA6IGNvbHVtbkdhcCxcblx0XHRcdGp1c3RpZnlDb250ZW50OiBqdXN0aWZ5LFxuXHRcdFx0dmVydGljYWxBbGlnbjogaXNJbmxpbmUgPyAnbWlkZGxlJyA6IHVuZGVmaW5lZCxcblx0XHRcdC4uLmFsaWdubWVudFByb3BzLFxuXHRcdH0gKTtcblxuXHRcdHJldHVybiBjeCggZ3JpZENsYXNzZXMsIGNsYXNzTmFtZSApO1xuXHR9LCBbXG5cdFx0YWxpZ24sXG5cdFx0YWxpZ25tZW50LFxuXHRcdGNsYXNzTmFtZSxcblx0XHRjb2x1bW5HYXAsXG5cdFx0Y3gsXG5cdFx0Z2FwLFxuXHRcdGdyaWRUZW1wbGF0ZUNvbHVtbnMsXG5cdFx0Z3JpZFRlbXBsYXRlUm93cyxcblx0XHRpc0lubGluZSxcblx0XHRqdXN0aWZ5LFxuXHRcdHJvd0dhcCxcblx0XSApO1xuXG5cdHJldHVybiB7IC4uLm90aGVyUHJvcHMsIGNsYXNzTmFtZTogY2xhc3NlcyB9O1xufVxuIl19 */");
8583
+ return cx(gridClasses, className);
8496
8584
  }, [
8497
8585
  align,
8498
8586
  alignment,
@@ -8514,7 +8602,7 @@ function useGrid(props) {
8514
8602
  //#endregion
8515
8603
  //#region ../../../node_modules/.pnpm/@wordpress+components@36.1.0_@types+react@18.3.28_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/@wordpress/components/build-module/grid/component.mjs
8516
8604
  function UnconnectedGrid(props, forwardedRef) {
8517
- return /* @__PURE__ */ jsx(component_default$1, {
8605
+ return /* @__PURE__ */ jsx(component_default$2, {
8518
8606
  ...useGrid(props),
8519
8607
  ref: forwardedRef
8520
8608
  });
@@ -8578,6 +8666,8 @@ var leaderboard_chart_module_default = {
8578
8666
  "bar--animated": "a8ccharts-GovfoW-bar--animated",
8579
8667
  "barWithLabelContainer": "a8ccharts-GovfoW-barWithLabelContainer",
8580
8668
  "chevron": "a8ccharts-GovfoW-chevron",
8669
+ "deltaPlaceholder": "a8ccharts-GovfoW-deltaPlaceholder",
8670
+ "deltaValue": "a8ccharts-GovfoW-deltaValue",
8581
8671
  "emptyState": "a8ccharts-GovfoW-emptyState",
8582
8672
  "interactiveRow": "a8ccharts-GovfoW-interactiveRow",
8583
8673
  "is-overlay": "a8ccharts-GovfoW-is-overlay",
@@ -8628,30 +8718,34 @@ const defaultDeltaFormatter = (value) => {
8628
8718
  * @return A CSS width value.
8629
8719
  */
8630
8720
  const getBarWidth = (share) => `calc(${share}% - var(--a8c--charts--leaderboard--bar--hover-inset, 0px) * ${share} / 100)`;
8721
+ const hasComparisonValue = (entry) => entry.previousValue != null && entry.previousShare != null && entry.delta != null;
8631
8722
  const BarLabel = ({ label }) => /* @__PURE__ */ jsx(Fragment$1, { children: typeof label === "string" ? /* @__PURE__ */ jsx(Text$1, {
8632
8723
  className: leaderboard_chart_module_default.label,
8633
8724
  children: label
8634
8725
  }) : label });
8635
- const BarWithLabel = ({ entry, withComparison, withOverlayLabel, primaryColor, secondaryColor, animation, isPrimaryVisible = true, isComparisonVisible = true }) => /* @__PURE__ */ jsxs("div", {
8636
- className: clsx(leaderboard_chart_module_default.barWithLabelContainer, { [leaderboard_chart_module_default["is-overlay"]]: withOverlayLabel }),
8637
- children: [
8638
- /* @__PURE__ */ jsx(BarLabel, { label: entry.label }),
8639
- isPrimaryVisible && /* @__PURE__ */ jsx("div", {
8640
- className: clsx(leaderboard_chart_module_default.bar, { [leaderboard_chart_module_default["bar--animated"]]: animation }),
8641
- style: {
8642
- width: getBarWidth(entry.currentShare),
8643
- backgroundColor: primaryColor
8644
- }
8645
- }),
8646
- withComparison && !withOverlayLabel && isComparisonVisible && /* @__PURE__ */ jsx("div", {
8647
- className: clsx(leaderboard_chart_module_default.bar, { [leaderboard_chart_module_default["bar--animated"]]: animation }),
8648
- style: {
8649
- width: getBarWidth(entry.previousShare),
8650
- backgroundColor: secondaryColor
8651
- }
8652
- })
8653
- ]
8654
- });
8726
+ const BarWithLabel = ({ entry, withComparison, withOverlayLabel, primaryColor, secondaryColor, animation, isPrimaryVisible = true, isComparisonVisible = true }) => {
8727
+ const showComparisonBar = withComparison && !withOverlayLabel && isComparisonVisible;
8728
+ return /* @__PURE__ */ jsxs("div", {
8729
+ className: clsx(leaderboard_chart_module_default.barWithLabelContainer, { [leaderboard_chart_module_default["is-overlay"]]: withOverlayLabel }),
8730
+ children: [
8731
+ /* @__PURE__ */ jsx(BarLabel, { label: entry.label }),
8732
+ isPrimaryVisible && /* @__PURE__ */ jsx("div", {
8733
+ className: clsx(leaderboard_chart_module_default.bar, { [leaderboard_chart_module_default["bar--animated"]]: animation }),
8734
+ style: {
8735
+ width: getBarWidth(entry.currentShare),
8736
+ backgroundColor: primaryColor
8737
+ }
8738
+ }),
8739
+ showComparisonBar && hasComparisonValue(entry) && /* @__PURE__ */ jsx("div", {
8740
+ className: clsx(leaderboard_chart_module_default.bar, { [leaderboard_chart_module_default["bar--animated"]]: animation }),
8741
+ style: {
8742
+ width: getBarWidth(entry.previousShare),
8743
+ backgroundColor: secondaryColor
8744
+ }
8745
+ })
8746
+ ]
8747
+ });
8748
+ };
8655
8749
  /**
8656
8750
  * LeaderboardChart component displays a ranked list of data with progress bars
8657
8751
  * and optional comparison values.
@@ -8809,7 +8903,12 @@ const LeaderboardChartInternal = ({ data, chartId: providedChartId, width: propW
8809
8903
  rowGap,
8810
8904
  columnGap,
8811
8905
  children: data.map((entry) => {
8812
- const deltaColor = deltaColors[Math.sign(entry.delta) + 1];
8906
+ const showComparisonColumn = withComparison && isComparisonVisible;
8907
+ const hasDeltaValue = hasComparisonValue(entry);
8908
+ const showComparisonValue = showComparisonColumn && hasDeltaValue;
8909
+ const showComparisonPlaceholder = showComparisonColumn && !hasDeltaValue;
8910
+ const colorIndex = showComparisonValue ? Math.sign(entry.delta) + 1 : 1;
8911
+ const deltaColor = deltaColors[colorIndex];
8813
8912
  const rowCells = /* @__PURE__ */ jsxs(Fragment$1, { children: [/* @__PURE__ */ jsx(Stack, {
8814
8913
  direction: "column",
8815
8914
  gap: labelSpacing,
@@ -8827,10 +8926,25 @@ const LeaderboardChartInternal = ({ data, chartId: providedChartId, width: propW
8827
8926
  direction: "row",
8828
8927
  gap: "xs",
8829
8928
  className: clsx(leaderboard_chart_module_default.valueContainer, { [leaderboard_chart_module_default.overlayLabel]: withOverlayLabel }),
8830
- children: [isPrimaryVisible && /* @__PURE__ */ jsx(Text$1, { children: valueFormatter(entry.currentValue) }), withComparison && isComparisonVisible && /* @__PURE__ */ jsx(Text$1, {
8831
- style: { color: deltaColor },
8832
- children: deltaFormatter(entry.delta)
8833
- })]
8929
+ children: [
8930
+ isPrimaryVisible && /* @__PURE__ */ jsx(Text$1, { children: valueFormatter(entry.currentValue) }),
8931
+ showComparisonValue && /* @__PURE__ */ jsx(Text$1, {
8932
+ className: leaderboard_chart_module_default.deltaValue,
8933
+ style: { color: deltaColor },
8934
+ children: deltaFormatter(entry.delta)
8935
+ }),
8936
+ showComparisonPlaceholder && /* @__PURE__ */ jsxs(Text$1, {
8937
+ className: clsx(leaderboard_chart_module_default.deltaValue, leaderboard_chart_module_default.deltaPlaceholder),
8938
+ style: { color: deltaColor },
8939
+ children: [/* @__PURE__ */ jsx("span", {
8940
+ "aria-hidden": "true",
8941
+ children: "-"
8942
+ }), /* @__PURE__ */ jsx(component_default$1, {
8943
+ as: "span",
8944
+ children: __("No comparison data", "jetpack-charts")
8945
+ })]
8946
+ })
8947
+ ]
8834
8948
  })] });
8835
8949
  if (entry.onClick) return /* @__PURE__ */ jsxs("button", {
8836
8950
  type: "button",
@@ -9639,6 +9753,6 @@ function TrendIndicator({ direction, value, className, style, showIcon = true })
9639
9753
  });
9640
9754
  }
9641
9755
  //#endregion
9642
- export { AccessibleTooltip, AreaChartResponsive as AreaChart, AreaChart as AreaChartUnresponsive, BarChartResponsive as BarChart, BarChart as BarChartUnresponsive, BarListChartResponsive as BarListChart, BarListChart as BarListChartUnresponsive, BaseTooltip, ConversionFunnelChartWithProvider as ConversionFunnelChart, GeoChartResponsive as GeoChart, GeoChartWithProvider as GeoChartUnresponsive, GlobalChartsContext, GlobalChartsProvider, GlobalChartsProvider as ThemeProvider, HeatmapChartResponsive as HeatmapChart, HeatmapChart as HeatmapChartUnresponsive, LeaderboardChartResponsive as LeaderboardChart, LeaderboardChart as LeaderboardChartUnresponsive, Legend, LineChartResponsive as LineChart, LineChart as LineChartUnresponsive, PieChartResponsive as PieChart, PieChart as PieChartUnresponsive, PieSemiCircleChartResponsive as PieSemiCircleChart, PieSemiCircleChart as PieSemiCircleChartUnresponsive, Sparkline, SparklineUnresponsive, TrendIndicator, buildCalendarHeatmapData, defaultTheme, formatMetricValue, formatPercentage, getColorDistance, hexToRgba, isValidHexColor, lightenHexColor, mergeThemes, normalizeColorToHex, parseAsLocalDate, parseHslString, parseRgbString, prefersLightText, relativeLuminance, useChartLegendItems, useGlobalChartsContext, useGlobalChartsTheme, useLeaderboardLegendItems, validateHexColor };
9756
+ export { AccessibleTooltip, AreaChartResponsive as AreaChart, AreaChart as AreaChartUnresponsive, BarChartResponsive as BarChart, BarChart as BarChartUnresponsive, BarListChartResponsive as BarListChart, BarListChart as BarListChartUnresponsive, BaseTooltip, ConversionFunnelChartWithProvider as ConversionFunnelChart, GeoChartResponsive as GeoChart, GeoChartWithProvider as GeoChartUnresponsive, GlobalChartsContext, GlobalChartsProvider, GlobalChartsProvider as ThemeProvider, HeatmapChartResponsive as HeatmapChart, HeatmapChart as HeatmapChartUnresponsive, LeaderboardChartResponsive as LeaderboardChart, LeaderboardChart as LeaderboardChartUnresponsive, Legend, LineChartResponsive as LineChart, LineChart as LineChartUnresponsive, PieChartResponsive as PieChart, PieChart as PieChartUnresponsive, PieSemiCircleChartResponsive as PieSemiCircleChart, PieSemiCircleChart as PieSemiCircleChartUnresponsive, Sparkline, SparklineUnresponsive, TrendIndicator, buildCalendarHeatmapData, defaultTheme, formatMetricValue, formatPercentage, getColorDistance, hexToRgba, isValidHexColor, lightenHexColor, mergeThemes, mixHexColors, normalizeColorToHex, parseAsLocalDate, parseHslString, parseRgbString, prefersLightText, relativeLuminance, useChartLegendItems, useGlobalChartsContext, useGlobalChartsTheme, useLeaderboardLegendItems, validateHexColor };
9643
9757
 
9644
9758
  //# sourceMappingURL=index.js.map