jsxRuntime jsx jsxFrag import * as React from "react" ; import * as p from "@plasmicapp/react-web" ; import { hasVariant , classNames , wrapWithClassName , createPlasmicElementProxy , makeFragment , MultiChoiceArg , SingleBooleanChoiceArg , SingleChoiceArg , pick , omit , useTrigger , StrictProps , deriveRenderOpts , ensureGlobalVariants , } from "@plasmicapp/react-web" ; import Menu__Item from "../../menu/Menu__Item" ; import "@plasmicapp/react-web/lib/plasmic.css" ; import * as defaultcss from "../plasmic__default_style.module.css" ; import * as projectcss from "./plasmic_plume_main.module.css" ; import * as sty from "./PlasmicMenu__Group.module.css" ; import SUPER__PlasmicMenu from "./PlasmicMenu" ; export type PlasmicMenu__Group__VariantMembers = { isFirst : "isFirst" ; noTitle : "noTitle" ; } ; export type PlasmicMenu__Group__VariantsArgs = { isFirst ? : SingleBooleanChoiceArg < "isFirst" > ; noTitle ? : SingleBooleanChoiceArg < "noTitle" > ; } ; type VariantPropType = keyof PlasmicMenu__Group__VariantsArgs ; export const PlasmicMenu__Group__VariantProps = new Array < VariantPropType > ( "isFirst" , "noTitle" ) ; export type PlasmicMenu__Group__ArgsType = { children ? : React . ReactNode ; title ? : React . ReactNode ; } ; type ArgPropType = keyof PlasmicMenu__Group__ArgsType ; export const PlasmicMenu__Group__ArgProps = new Array < ArgPropType > ( "children" , "title" ) ; export type PlasmicMenu__Group__OverridesType = { root ? : p . Flex < "div" > ; separator ? : p . Flex < "div" > ; titleContainer ? : p . Flex < "div" > ; itemsContainer ? : p . Flex < "ul" > ; } ; export interface DefaultMenu__GroupProps extends p . BaseMenuGroupProps { title ? : React . ReactNode ; noTitle ? : SingleBooleanChoiceArg < "noTitle" > ; } function PlasmicMenu__Group__RenderFunc ( props ) { const { variants , args , overrides , forNode } = props ; const superContexts = { Menu : React . useContext ( SUPER__PlasmicMenu . Context ) , } ; return ( < div data - plasmic - name = { "root" } data - plasmic - override = { overrides . root } data - plasmic - root = { true } data - plasmic - for - node = { forNode } className = { classNames ( defaultcss . all , projectcss . root_reset , sty . root ) } > { ( hasVariant ( variants , "isFirst" , "isFirst" ) ? false : true ) ? ( < div data - plasmic - name = { "separator" } data - plasmic - override = { overrides . separator } className = { classNames ( defaultcss . all , sty . separator , { [ sty . separator__isFirst ] : hasVariant ( variants , "isFirst" , "isFirst" ) , } ) } />) : null} { ( hasVariant ( variants , "noTitle" , "noTitle" ) ? false : true ) ? ( < div data - plasmic - name = { "titleContainer" } data - plasmic - override = { overrides . titleContainer } className = { classNames ( defaultcss . all , sty . titleContainer , { [ sty . titleContainer__noTitle ] : hasVariant ( variants , "noTitle" , "noTitle" ) , } ) } > { p . renderPlasmicSlot ( { defaultContents : "Group title" , value : args . title , className : classNames ( sty . slotTitle ) , } ) } < /div>) : null} < ul data - plasmic - name = { "itemsContainer" } data - plasmic - override = { overrides . itemsContainer } className = { classNames ( defaultcss . ul , sty . itemsContainer ) } > { p . renderPlasmicSlot ( { defaultContents : ( < Menu__Item className = { classNames ( "__wab_instance" , sty . item__sGa3W ) } / > ) , value : args . children , } ) } < /ul> < /div>) as React.ReactElement | null; } function useBehavior < P extends p . BaseMenuGroupProps > ( props ) { return p . useMenuGroup ( PlasmicMenu__Group , props , { noTitleVariant : { group : "noTitle" , variant : "noTitle" } , isFirstVariant : { group : "isFirst" , variant : "isFirst" } , itemsSlot : "children" , titleSlot : "title" , root : "root" , separator : "separator" , titleContainer : "titleContainer" , itemsContainer : "itemsContainer" , } ) ; } const PlasmicDescendants = { root : [ "root" , "separator" , "titleContainer" , "itemsContainer" ] , separator : [ "separator" ] , titleContainer : [ "titleContainer" ] , itemsContainer : [ "itemsContainer" ] , } as const ; type NodeNameType = keyof typeof PlasmicDescendants ; type DescendantsType < T extends NodeNameType > = typeof PlasmicDescendants [ T ] [ number ] ; type NodeDefaultElementType = { root : "div" ; separator : "div" ; titleContainer : "div" ; itemsContainer : "ul" ; } ; type ReservedPropsType = "variants" | "args" | "overrides" ; type NodeOverridesType < T extends NodeNameType > = Pick < PlasmicMenu__Group__OverridesType , DescendantsType < T > > ; type NodeComponentProps < T extends NodeNameType > = { variants ? : PlasmicMenu__Group__VariantsArgs ; args ? : PlasmicMenu__Group__ArgsType ; overrides ? : NodeOverridesType < T > ; } & Omit < PlasmicMenu__Group__VariantsArgs , ReservedPropsType > & Omit < PlasmicMenu__Group__ArgsType , ReservedPropsType > & Omit < NodeOverridesType < T > , ReservedPropsType | VariantPropType | ArgPropType > & Omit < Partial < React . ComponentProps < NodeDefaultElementType [ T ] > > , ReservedPropsType | VariantPropType | ArgPropType | DescendantsType < T > > ; function makeNodeComponent < NodeName extends NodeNameType > ( nodeName ) { type PropsType = NodeComponentProps < NodeName > & { key ? : React . Key ; } ; const func = function < T extends PropsType > ( props ) { const { variants , args , overrides } = deriveRenderOpts ( props , { name : nodeName , descendantNames : [ ... PlasmicDescendants [ nodeName ] ] , internalArgPropNames : PlasmicMenu__Group__ArgProps , internalVariantPropNames : PlasmicMenu__Group__VariantProps , } ) ; return PlasmicMenu__Group__RenderFunc ( { variants , args , overrides , forNode : nodeName , } ) ; } ; if ( nodeName === "root" ) { func . displayName = "PlasmicMenu__Group" ; } else { func . displayName = `PlasmicMenu__Group.${ nodeName }` ; } return func ; } export const PlasmicMenu__Group = Object . assign ( makeNodeComponent ( "root" ) , { separator : makeNodeComponent ( "separator" ) , titleContainer : makeNodeComponent ( "titleContainer" ) , itemsContainer : makeNodeComponent ( "itemsContainer" ) , internalVariantProps : PlasmicMenu__Group__VariantProps , internalArgProps : PlasmicMenu__Group__ArgProps , useBehavior , } ) ; export default PlasmicMenu__Group ;