MCPcopy
hub / github.com/Semantic-Org/Semantic-UI-React / DropdownMenu

Function DropdownMenu

src/modules/Dropdown/DropdownMenu.js:16–33  ·  view source on GitHub ↗

* A dropdown menu can contain a menu.

(props)

Source from the content-addressed store, hash-verified

14 * A dropdown menu can contain a menu.
15 */
16function DropdownMenu(props) {
17 const { children, className, content, direction, open, scrolling } = props
18 const classes = cx(
19 direction,
20 useKeyOnly(open, 'visible'),
21 useKeyOnly(scrolling, 'scrolling'),
22 'menu transition',
23 className,
24 )
25 const rest = getUnhandledProps(DropdownMenu, props)
26 const ElementType = getElementType(DropdownMenu, props)
27
28 return (
29 <ElementType {...rest} className={classes}>
30 {childrenUtils.isNil(children) ? content : children}
31 </ElementType>
32 )
33}
34
35DropdownMenu.propTypes = {
36 /** An element type to render as (string or function). */

Callers

nothing calls this directly

Calls 3

useKeyOnlyFunction · 0.90
getUnhandledPropsFunction · 0.90
getElementTypeFunction · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…