@xsolla/xui-context-menu 0.106.0 → 0.108.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/web/index.mjs CHANGED
@@ -1382,6 +1382,7 @@ import { jsx as jsx383 } from "react/jsx-runtime";
1382
1382
  import { jsx as jsx384 } from "react/jsx-runtime";
1383
1383
  import { jsx as jsx385 } from "react/jsx-runtime";
1384
1384
  import { jsx as jsx386 } from "react/jsx-runtime";
1385
+ import { jsx as jsx387 } from "react/jsx-runtime";
1385
1386
  var StyledIcon2 = styled5.div`
1386
1387
  display: inline-flex;
1387
1388
  align-items: center;
@@ -1399,15 +1400,15 @@ var BaseIcon = ({
1399
1400
  variant = "line",
1400
1401
  size = 24,
1401
1402
  color = "currentColor",
1402
- solidContent: solidContent386,
1403
- lineContent: lineContent386,
1403
+ solidContent: solidContent387,
1404
+ lineContent: lineContent387,
1404
1405
  className,
1405
1406
  style,
1406
1407
  "data-testid": testId,
1407
1408
  "aria-label": ariaLabel,
1408
1409
  "aria-hidden": ariaHidden
1409
1410
  }) => {
1410
- const svgContent = variant === "line" ? lineContent386 : solidContent386;
1411
+ const svgContent = variant === "line" ? lineContent387 : solidContent387;
1411
1412
  const sizeValue = typeof size === "number" ? `${size}px` : size;
1412
1413
  return /* @__PURE__ */ jsx11(
1413
1414
  StyledIcon2,
@@ -1424,13 +1425,13 @@ var BaseIcon = ({
1424
1425
  }
1425
1426
  );
1426
1427
  };
1427
- var solidContent372 = `<svg viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" width="100%" height="100%"><g id="icon_search--line"><path id="Union" fill-rule="evenodd" clip-rule="evenodd" d="M10 2C14.4183 2 18 5.58172 18 10C18 11.8484 17.3711 13.5488 16.3184 14.9033L21.957 20.543L20.543 21.957L14.9033 16.3174C13.5487 17.3703 11.8486 18 10 18C5.58172 18 2 14.4183 2 10C2 5.58172 5.58172 2 10 2ZM10 4C6.68629 4 4 6.68629 4 10C4 13.3137 6.68629 16 10 16C13.3137 16 16 13.3137 16 10C16 6.68629 13.3137 4 10 4Z" style="fill: currentColor"/></g></svg>`;
1428
- var lineContent372 = `<svg viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" width="100%" height="100%"><g id="icon_search--line"><path id="Union" fill-rule="evenodd" clip-rule="evenodd" d="M10 2C14.4183 2 18 5.58172 18 10C18 11.8484 17.3711 13.5488 16.3184 14.9033L21.957 20.543L20.543 21.957L14.9033 16.3174C13.5487 17.3703 11.8486 18 10 18C5.58172 18 2 14.4183 2 10C2 5.58172 5.58172 2 10 2ZM10 4C6.68629 4 4 6.68629 4 10C4 13.3137 6.68629 16 10 16C13.3137 16 16 13.3137 16 10C16 6.68629 13.3137 4 10 4Z" style="fill: currentColor"/></g></svg>`;
1429
- var Search = (props) => /* @__PURE__ */ jsx373(BaseIcon, { ...props, solidContent: solidContent372, lineContent: lineContent372 });
1428
+ var solidContent373 = `<svg viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" width="100%" height="100%"><g id="icon_search--line"><path id="Union" fill-rule="evenodd" clip-rule="evenodd" d="M10 2C14.4183 2 18 5.58172 18 10C18 11.8484 17.3711 13.5488 16.3184 14.9033L21.957 20.543L20.543 21.957L14.9033 16.3174C13.5487 17.3703 11.8486 18 10 18C5.58172 18 2 14.4183 2 10C2 5.58172 5.58172 2 10 2ZM10 4C6.68629 4 4 6.68629 4 10C4 13.3137 6.68629 16 10 16C13.3137 16 16 13.3137 16 10C16 6.68629 13.3137 4 10 4Z" style="fill: currentColor"/></g></svg>`;
1429
+ var lineContent373 = `<svg viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg" width="100%" height="100%"><g id="icon_search--line"><path id="Union" fill-rule="evenodd" clip-rule="evenodd" d="M10 2C14.4183 2 18 5.58172 18 10C18 11.8484 17.3711 13.5488 16.3184 14.9033L21.957 20.543L20.543 21.957L14.9033 16.3174C13.5487 17.3703 11.8486 18 10 18C5.58172 18 2 14.4183 2 10C2 5.58172 5.58172 2 10 2ZM10 4C6.68629 4 4 6.68629 4 10C4 13.3137 6.68629 16 10 16C13.3137 16 16 13.3137 16 10C16 6.68629 13.3137 4 10 4Z" style="fill: currentColor"/></g></svg>`;
1430
+ var Search = (props) => /* @__PURE__ */ jsx374(BaseIcon, { ...props, solidContent: solidContent373, lineContent: lineContent373 });
1430
1431
 
1431
1432
  // src/ContextMenuSearch.tsx
1432
1433
  import { Divider } from "@xsolla/xui-divider";
1433
- import { jsx as jsx387, jsxs as jsxs5 } from "react/jsx-runtime";
1434
+ import { jsx as jsx388, jsxs as jsxs5 } from "react/jsx-runtime";
1434
1435
  var ContextMenuSearch = forwardRef7(
1435
1436
  ({
1436
1437
  value,
@@ -1479,15 +1480,15 @@ var ContextMenuSearch = forwardRef7(
1479
1480
  "data-testid": testId,
1480
1481
  children: [
1481
1482
  /* @__PURE__ */ jsxs5(Box, { flexDirection: "row", alignItems: "center", gap: 8, children: [
1482
- /* @__PURE__ */ jsx387(
1483
+ /* @__PURE__ */ jsx388(
1483
1484
  Icon,
1484
1485
  {
1485
1486
  size: sizeStyles.searchIconSize,
1486
1487
  color: inputColors.placeholder,
1487
- children: /* @__PURE__ */ jsx387(Search, {})
1488
+ children: /* @__PURE__ */ jsx388(Search, {})
1488
1489
  }
1489
1490
  ),
1490
- /* @__PURE__ */ jsx387(Box, { flex: 1, children: /* @__PURE__ */ jsx387(
1491
+ /* @__PURE__ */ jsx388(Box, { flex: 1, children: /* @__PURE__ */ jsx388(
1491
1492
  InputPrimitive,
1492
1493
  {
1493
1494
  ref: inputRef,
@@ -1506,7 +1507,7 @@ var ContextMenuSearch = forwardRef7(
1506
1507
  }
1507
1508
  ) })
1508
1509
  ] }),
1509
- /* @__PURE__ */ jsx387(Divider, {})
1510
+ /* @__PURE__ */ jsx388(Divider, {})
1510
1511
  ]
1511
1512
  }
1512
1513
  );
@@ -1515,7 +1516,7 @@ var ContextMenuSearch = forwardRef7(
1515
1516
  ContextMenuSearch.displayName = "ContextMenuSearch";
1516
1517
 
1517
1518
  // src/ContextMenu.tsx
1518
- import { jsx as jsx388, jsxs as jsxs6 } from "react/jsx-runtime";
1519
+ import { jsx as jsx389, jsxs as jsxs6 } from "react/jsx-runtime";
1519
1520
  var ContextMenuRoot = forwardRef8(
1520
1521
  ({
1521
1522
  children,
@@ -1694,7 +1695,7 @@ var ContextMenuRoot = forwardRef8(
1694
1695
  "data-testid": `context-menu-item-${item.id || index}`
1695
1696
  };
1696
1697
  if (item.variant === "checkbox") {
1697
- return /* @__PURE__ */ jsx388(
1698
+ return /* @__PURE__ */ jsx389(
1698
1699
  ContextMenuCheckboxItem,
1699
1700
  {
1700
1701
  ...commonProps,
@@ -1707,7 +1708,7 @@ var ContextMenuRoot = forwardRef8(
1707
1708
  );
1708
1709
  }
1709
1710
  if (item.variant === "radio") {
1710
- return /* @__PURE__ */ jsx388(
1711
+ return /* @__PURE__ */ jsx389(
1711
1712
  ContextMenuRadioItem,
1712
1713
  {
1713
1714
  ...commonProps,
@@ -1718,7 +1719,7 @@ var ContextMenuRoot = forwardRef8(
1718
1719
  itemKey
1719
1720
  );
1720
1721
  }
1721
- return /* @__PURE__ */ jsx388(
1722
+ return /* @__PURE__ */ jsx389(
1722
1723
  ContextMenuItem,
1723
1724
  {
1724
1725
  ...commonProps,
@@ -1737,8 +1738,8 @@ var ContextMenuRoot = forwardRef8(
1737
1738
  };
1738
1739
  const renderGroups = (groupsData) => {
1739
1740
  return groupsData.map((group, groupIndex) => /* @__PURE__ */ jsxs6(React7.Fragment, { children: [
1740
- groupIndex > 0 && /* @__PURE__ */ jsx388(ContextMenuSeparator, {}),
1741
- /* @__PURE__ */ jsx388(
1741
+ groupIndex > 0 && /* @__PURE__ */ jsx389(ContextMenuSeparator, {}),
1742
+ /* @__PURE__ */ jsx389(
1742
1743
  ContextMenuGroup,
1743
1744
  {
1744
1745
  label: group.label,
@@ -1752,14 +1753,14 @@ var ContextMenuRoot = forwardRef8(
1752
1753
  const renderContent = () => {
1753
1754
  if (isLoading) {
1754
1755
  const brandColor = theme.colors.control.brand.primary.bg;
1755
- return /* @__PURE__ */ jsx388(
1756
+ return /* @__PURE__ */ jsx389(
1756
1757
  Box,
1757
1758
  {
1758
1759
  padding: 16,
1759
1760
  alignItems: "center",
1760
1761
  justifyContent: "center",
1761
1762
  minHeight: 60,
1762
- children: /* @__PURE__ */ jsx388(Spinner, { size: "md", color: brandColor })
1763
+ children: /* @__PURE__ */ jsx389(Spinner, { size: "md", color: brandColor })
1763
1764
  }
1764
1765
  );
1765
1766
  }
@@ -1774,7 +1775,7 @@ var ContextMenuRoot = forwardRef8(
1774
1775
  }
1775
1776
  return null;
1776
1777
  };
1777
- return /* @__PURE__ */ jsx388(ContextMenuContext.Provider, { value: contextValue, children: /* @__PURE__ */ jsxs6(
1778
+ return /* @__PURE__ */ jsx389(ContextMenuContext.Provider, { value: contextValue, children: /* @__PURE__ */ jsxs6(
1778
1779
  "div",
1779
1780
  {
1780
1781
  ref: containerRef,
@@ -1785,7 +1786,7 @@ var ContextMenuRoot = forwardRef8(
1785
1786
  },
1786
1787
  "data-testid": testId,
1787
1788
  children: [
1788
- trigger && /* @__PURE__ */ jsx388(
1789
+ trigger && /* @__PURE__ */ jsx389(
1789
1790
  "div",
1790
1791
  {
1791
1792
  onClick: toggleMenu,
@@ -1794,7 +1795,7 @@ var ContextMenuRoot = forwardRef8(
1794
1795
  children: trigger
1795
1796
  }
1796
1797
  ),
1797
- isOpen && /* @__PURE__ */ jsx388(
1798
+ isOpen && /* @__PURE__ */ jsx389(
1798
1799
  Box,
1799
1800
  {
1800
1801
  ref: (node) => {