MCPcopy Create free account
hub / github.com/alibaba/lowcode-engine / getMenuItemHeight

Function getMenuItemHeight

packages/utils/src/context-menu.tsx:183–193  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

181let cachedMenuItemHeight: string | undefined;
182
183function getMenuItemHeight() {
184 if (cachedMenuItemHeight) {
185 return cachedMenuItemHeight;
186 }
187 const root = document.documentElement;
188 const styles = getComputedStyle(root);
189 const menuItemHeight = styles.getPropertyValue('--context-menu-item-height').trim();
190 cachedMenuItemHeight = menuItemHeight;
191
192 return menuItemHeight;
193}
194
195export function createContextMenu(children: React.ReactNode[], {
196 event,

Callers 1

createContextMenuFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…