Shared:ContextMenu:Fixed incorrect opening of the second level menu under the tablet.

This commit is contained in:
Vlada Gazizova 2024-07-31 13:43:36 +03:00
parent cdf3be34b8
commit 80ac3a0f71

View File

@ -91,11 +91,9 @@ const SubMenu = (props: {
) => {
const { disabled, url, onClick, items, action, label } = item;
if (label && (items || item.onLoad)) {
if (isMobile() && label && (items || item.onLoad)) {
e.preventDefault();
if (!isMobileDevice) return;
if (items) onMobileItemClick?.(e, label as string, items, undefined);
else if (item.onLoad)
onMobileItemClick?.(e, label as string, undefined, item.onLoad);