@xsolla/xui-context-menu 0.202.3 → 0.203.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/native/index.d.mts +1 -0
- package/native/index.d.ts +1 -0
- package/native/index.js +16 -7
- package/native/index.js.map +1 -1
- package/native/index.mjs +16 -7
- package/native/index.mjs.map +1 -1
- package/package.json +10 -10
- package/web/index.d.mts +1 -0
- package/web/index.d.ts +1 -0
- package/web/index.js +16 -7
- package/web/index.js.map +1 -1
- package/web/index.mjs +16 -7
- package/web/index.mjs.map +1 -1
package/native/index.d.mts
CHANGED
package/native/index.d.ts
CHANGED
package/native/index.js
CHANGED
|
@@ -595,7 +595,7 @@ var OptionCell = ({
|
|
|
595
595
|
if (hasSubmenu) scheduleClose();
|
|
596
596
|
};
|
|
597
597
|
const labelColor = disabled ? theme.colors.control.input.textDisable : destructive ? theme.colors.content.alert.primary : theme.colors.content.primary;
|
|
598
|
-
const bg = inHoverState ? theme.colors.
|
|
598
|
+
const bg = checked ? theme.colors.overlay.brand : inHoverState ? theme.colors.overlay.mono : "transparent";
|
|
599
599
|
const role = !hasSubmenu && checked !== void 0 ? leadingControl === "radio" ? "menuitemradio" : "menuitemcheckbox" : "menuitem";
|
|
600
600
|
const ariaChecked = !hasSubmenu && checked !== void 0 ? checked ? "true" : "false" : void 0;
|
|
601
601
|
const handleClick = () => {
|
|
@@ -1205,11 +1205,12 @@ var ContextMenuSubmenu = ({
|
|
|
1205
1205
|
Box,
|
|
1206
1206
|
{
|
|
1207
1207
|
role: "menu",
|
|
1208
|
-
backgroundColor: xuiTheme.colors.
|
|
1208
|
+
backgroundColor: xuiTheme.colors.layer.float,
|
|
1209
1209
|
borderColor: xuiTheme.colors.border.secondary,
|
|
1210
1210
|
borderWidth: 1,
|
|
1211
1211
|
borderRadius,
|
|
1212
1212
|
paddingVertical: sizeStyles.paddingVertical,
|
|
1213
|
+
paddingHorizontal: sizeStyles.paddingHorizontal,
|
|
1213
1214
|
style: {
|
|
1214
1215
|
boxShadow: "0 4px 12px rgba(0,0,0,0.15)",
|
|
1215
1216
|
minWidth: sizeStyles.minWidth
|
|
@@ -1571,7 +1572,7 @@ var ContextMenuRoot = (0, import_react6.forwardRef)(
|
|
|
1571
1572
|
position: "absolute",
|
|
1572
1573
|
width: ARROW_SIZE,
|
|
1573
1574
|
height: ARROW_SIZE,
|
|
1574
|
-
backgroundColor: xuiTheme.colors.
|
|
1575
|
+
backgroundColor: xuiTheme.colors.layer.float,
|
|
1575
1576
|
borderStyle: "solid",
|
|
1576
1577
|
borderColor: xuiTheme.colors.border.secondary,
|
|
1577
1578
|
// 1px outline only on the two outward-facing edges of the rotated square
|
|
@@ -1782,7 +1783,7 @@ var ContextMenuRoot = (0, import_react6.forwardRef)(
|
|
|
1782
1783
|
position: "sticky",
|
|
1783
1784
|
top: 0,
|
|
1784
1785
|
zIndex: 1,
|
|
1785
|
-
backgroundColor: xuiTheme.colors.
|
|
1786
|
+
backgroundColor: xuiTheme.colors.layer.float
|
|
1786
1787
|
},
|
|
1787
1788
|
children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
1788
1789
|
ContextMenuItem,
|
|
@@ -1924,11 +1925,12 @@ var ContextMenuRoot = (0, import_react6.forwardRef)(
|
|
|
1924
1925
|
"data-testid": dataTestId ?? testID ?? "context-menu",
|
|
1925
1926
|
"data-xui-context-menu-portal": trigger || position ? menuId : void 0,
|
|
1926
1927
|
"data-placement": resolvedPlacement,
|
|
1927
|
-
backgroundColor: xuiTheme.colors.
|
|
1928
|
+
backgroundColor: xuiTheme.colors.layer.float,
|
|
1928
1929
|
borderColor: xuiTheme.colors.border.secondary,
|
|
1929
1930
|
borderWidth: 1,
|
|
1930
1931
|
borderRadius,
|
|
1931
1932
|
paddingVertical: sizeStyles.paddingVertical,
|
|
1933
|
+
paddingHorizontal: sizeStyles.paddingHorizontal,
|
|
1932
1934
|
width,
|
|
1933
1935
|
minWidth: sizeStyles.minWidth,
|
|
1934
1936
|
tabIndex: -1,
|
|
@@ -1943,7 +1945,9 @@ var ContextMenuRoot = (0, import_react6.forwardRef)(
|
|
|
1943
1945
|
overflow: "visible"
|
|
1944
1946
|
} : {
|
|
1945
1947
|
maxHeight,
|
|
1946
|
-
overflowY: "auto"
|
|
1948
|
+
overflowY: "auto",
|
|
1949
|
+
// Panel still scrolls; the bar itself is hidden.
|
|
1950
|
+
scrollbarWidth: "none"
|
|
1947
1951
|
},
|
|
1948
1952
|
outline: "none"
|
|
1949
1953
|
},
|
|
@@ -1959,7 +1963,12 @@ var ContextMenuRoot = (0, import_react6.forwardRef)(
|
|
|
1959
1963
|
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
1960
1964
|
"div",
|
|
1961
1965
|
{
|
|
1962
|
-
style: {
|
|
1966
|
+
style: {
|
|
1967
|
+
maxHeight,
|
|
1968
|
+
overflowY: "auto",
|
|
1969
|
+
scrollbarWidth: "none",
|
|
1970
|
+
borderRadius
|
|
1971
|
+
},
|
|
1963
1972
|
children: renderContent()
|
|
1964
1973
|
}
|
|
1965
1974
|
)
|