- Name
service- Kind
- parameter
- Type
DropdownMenuService- Requirement
- required
Docs/API reference/Headless/dropdown-menu
dropdown-menu headless API
The core connector and vanilla mount are always visible. Use the framework choice to inspect native composition, props, outputs, context and hooks for the selected adapter.
@grassroot/ui-headless-core/dropdown-menu
Core connector and vanilla API
packages/ui-headless/core/src/dropdown-menu/index.ts
activateMenuLayer
functionManager lifecycle helper (spec's "Dismissal" section) — pushes a NON-MODAL layer (no scroll lock, no focus trap) whose `onDismiss` forwards straight to `service.send({ type: "CLOSE", reason })`, with `getElements` covering the mounted Content *and* Trigger (so a trigger click while open is never treated as an outside click — the trigger owns its own TOGGLE handler instead). Callers (adapters/`mountDropdownMenu`) invoke this once the menu commits open, and call the returned `release()` on close-commit or unmount. Requires Trigger and Content to already be registered in `scope` — this is a mount-time-only manager wire-up, never called at SSR or before the menu's DOM exists (mirrors `activateDialogManagers`'s own stance).
declare function activateMenuLayer(service: DropdownMenuService, scope: PartScope, doc: Document): () => void;serviceDropdownMenuServicescopePartScopedocDocumentreturn() => void- Name
scope- Kind
- parameter
- Type
PartScope- Requirement
- required
- Name
doc- Kind
- parameter
- Type
Document- Requirement
- required
- Name
return- Kind
- return value
- Type
() => void- Requirement
- n/a
connectDropdownMenu
functiondeclare function connectDropdownMenu(service: DropdownMenuService, scope: PartScope, options?: DropdownMenuConnectOptions): DropdownMenuApi;serviceDropdownMenuServicescopePartScopeoptionsDropdownMenuConnectOptionsreturnDropdownMenuApi- Name
service- Kind
- parameter
- Type
DropdownMenuService- Requirement
- required
- Name
scope- Kind
- parameter
- Type
PartScope- Requirement
- required
- Name
options- Kind
- parameter
- Type
DropdownMenuConnectOptions- Requirement
- optional
- Name
return- Kind
- return value
- Type
DropdownMenuApi- Requirement
- n/a
dropdownMenuAnatomy
valueexport declare const dropdownMenuAnatomy: { readonly scope: "dropdown-menu"; readonly parts: readonly ["trigger", "positioner", "content", "item", "separator", "group-label"];};partsreadonly ["trigger", "positioner", "content", "item", "separator", "group-label"]scope"dropdown-menu"- Name
parts- Kind
- property
- Type
readonly ["trigger", "positioner", "content", "item", "separator", "group-label"]- Requirement
- required
- Name
scope- Kind
- property
- Type
"dropdown-menu"- Requirement
- required
DropdownMenuApi
interfaceinterface DropdownMenuApi { triggerProps(): PartProps; positionerProps(): PartProps; contentProps(): PartProps; itemProps(item: DropdownMenuItem): PartProps; separatorProps(): PartProps; groupLabelProps(): PartProps; readonly open: boolean;}contentProps() => PartPropsgroupLabelProps() => PartPropsitemProps(item: DropdownMenuItem) => PartPropsopenbooleanpositionerProps() => PartPropsseparatorProps() => PartPropstriggerProps() => PartProps- Name
contentProps- Kind
- method
- Type
() => PartProps- Requirement
- required
- Name
groupLabelProps- Kind
- method
- Type
() => PartProps- Requirement
- required
- Name
itemProps- Kind
- method
- Type
(item: DropdownMenuItem) => PartProps- Requirement
- required
- Name
open- Kind
- property
- Type
boolean- Requirement
- required
- Name
positionerProps- Kind
- method
- Type
() => PartProps- Requirement
- required
- Name
separatorProps- Kind
- method
- Type
() => PartProps- Requirement
- required
- Name
triggerProps- Kind
- method
- Type
() => PartProps- Requirement
- required
type DropdownMenuChangeReason = DropdownMenuOpenReason | DropdownMenuCloseReason;type DropdownMenuCloseReason = "escape" | "outside-click" | "select" | "programmatic";DropdownMenuCommand
typetype DropdownMenuCommand = (CommandObject & { readonly type: "OPEN_CHANGE_REQUEST"; readonly open: boolean; readonly reason: DropdownMenuChangeReason;}) | (CommandObject & { readonly type: "SELECT_ITEM"; readonly id: string;}) | ScheduleCommand<DropdownMenuEvent> | CancelCommand;DropdownMenuConnectOptions
interfaceinterface DropdownMenuConnectOptions { /** Positioning hint carried as `data-align` on the positioner, read * fresh on every positionerProps() call (adapters may back it with a * getter — see connectDropdownMenu's alignOf comment) * (spec: "carries data-align="start" | "end""; positioning itself stays * CSS as legacy — no floating/measure machinery this slice). Default * "start". */ readonly align?: "start" | "end";}align"start" | "end"- Name
align- Kind
- property
- Type
"start" | "end"- Requirement
- optional
- Description
- Positioning hint carried as `data-align` on the positioner, read fresh on every positionerProps() call (adapters may back it with a getter — see connectDropdownMenu's alignOf comment) (spec: "carries data-align="start" | "end""; positioning itself stays CSS as legacy — no floating/measure machinery this slice). Default "start".
DropdownMenuContext
typetype DropdownMenuContext = MenuContext;DropdownMenuEvent
typetype DropdownMenuEvent = { readonly type: "TOGGLE"; readonly reason: "trigger";} | { readonly type: "OPEN"; readonly reason: DropdownMenuOpenReason; readonly highlight?: "first" | "last";} | { readonly type: "CLOSE"; readonly reason: DropdownMenuCloseReason;} | { readonly type: "MOVE"; readonly direction: -1 | 1;} | { readonly type: "HIGHLIGHT"; readonly index: number;} | { readonly type: "HOME";} | { readonly type: "END";} | { readonly type: "SELECT";} | { readonly type: "TYPEAHEAD"; readonly char: string;};DropdownMenuInput
typetype DropdownMenuInput = { readonly open?: boolean; readonly defaultOpen?: boolean; readonly items: readonly DropdownMenuItem[]; readonly typeaheadTimeoutMs?: number;};defaultOpenbooleanitemsreadonly DropdownMenuItem[]openbooleantypeaheadTimeoutMsnumber- Name
defaultOpen- Kind
- property
- Type
boolean- Requirement
- optional
- Name
items- Kind
- property
- Type
readonly DropdownMenuItem[]- Requirement
- required
- Name
open- Kind
- property
- Type
boolean- Requirement
- optional
- Name
typeaheadTimeoutMs- Kind
- property
- Type
number- Requirement
- optional
DropdownMenuItem
interfaceinterface DropdownMenuItem { readonly id: string; readonly disabled?: boolean; readonly textValue?: string;}disabledbooleanidstringtextValuestring- Name
disabled- Kind
- property
- Type
boolean- Requirement
- optional
- Name
id- Kind
- property
- Type
string- Requirement
- required
- Name
textValue- Kind
- property
- Type
string- Requirement
- optional
dropdownMenuMachine
valueexport declare const dropdownMenuMachine: DropdownMenuMachine;DropdownMenuMount
interfaceinterface DropdownMenuMount { readonly service: DropdownMenuService; readonly connector: DropdownMenuApi; readonly root: HTMLElement; readonly trigger: HTMLElement; destroy(): void;}connectorDropdownMenuApidestroy() => voidrootHTMLElementserviceDropdownMenuServicetriggerHTMLElement- Name
connector- Kind
- property
- Type
DropdownMenuApi- Requirement
- required
- Name
destroy- Kind
- method
- Type
() => void- Requirement
- required
- Name
root- Kind
- property
- Type
HTMLElement- Requirement
- required
- Name
service- Kind
- property
- Type
DropdownMenuService- Requirement
- required
- Name
trigger- Kind
- property
- Type
HTMLElement- Requirement
- required
DropdownMenuOpenChangeDetail
interfaceinterface DropdownMenuOpenChangeDetail { readonly open: boolean; readonly reason: DropdownMenuChangeReason;}openbooleanreasonDropdownMenuChangeReason- Name
open- Kind
- property
- Type
boolean- Requirement
- required
- Name
reason- Kind
- property
- Type
DropdownMenuChangeReason- Requirement
- required
type DropdownMenuOpenReason = "trigger" | "programmatic";DropdownMenuPart
typetype DropdownMenuPart = (typeof dropdownMenuAnatomy.parts)[number];DropdownMenuRow
typeOne row of the presentational render order — either a menu item (backed by a machine `DropdownMenuItem`) or a purely-decorative separator.
type DropdownMenuRow = { readonly type: "item"; readonly item: DropdownMenuItem;} | { readonly type: "separator";};dropdownMenuSelectors
valueexport declare const dropdownMenuSelectors: { open: (snapshot: DropdownMenuSnapshot) => boolean; highlightedIndex: (snapshot: DropdownMenuSnapshot) => number; typeaheadBuffer: (snapshot: DropdownMenuSnapshot) => string;};highlightedIndex(snapshot: DropdownMenuSnapshot) => numberopen(snapshot: DropdownMenuSnapshot) => booleantypeaheadBuffer(snapshot: DropdownMenuSnapshot) => string- Name
highlightedIndex- Kind
- property
- Type
(snapshot: DropdownMenuSnapshot) => number- Requirement
- required
- Name
open- Kind
- property
- Type
(snapshot: DropdownMenuSnapshot) => boolean- Requirement
- required
- Name
typeaheadBuffer- Kind
- property
- Type
(snapshot: DropdownMenuSnapshot) => string- Requirement
- required
DropdownMenuService
typetype DropdownMenuService = Service<DropdownMenuInput, DropdownMenuStateValue, DropdownMenuContext, DropdownMenuEvent, DropdownMenuCommand>;DropdownMenuSnapshot
typetype DropdownMenuSnapshot = Snapshot<DropdownMenuStateValue, DropdownMenuContext>;type DropdownMenuStateValue = "open" | "closed";mountDropdownMenu
functiondeclare function mountDropdownMenu(container: HTMLElement, options: MountDropdownMenuOptions): DropdownMenuMount;containerHTMLElementoptionsMountDropdownMenuOptionsreturnDropdownMenuMount- Name
container- Kind
- parameter
- Type
HTMLElement- Requirement
- required
- Name
options- Kind
- parameter
- Type
MountDropdownMenuOptions- Requirement
- required
- Name
return- Kind
- return value
- Type
DropdownMenuMount- Requirement
- n/a
MountDropdownMenuOptions
interfaceinterface MountDropdownMenuOptions extends DropdownMenuInput { /** Presentational render order (items + separators). Defaults to * `items.map((item) => ({ type: "item", item }))` when omitted — i.e. * no separators. */ readonly rows?: readonly DropdownMenuRow[]; /** Renders a `Menu.GroupLabel` (the legacy `header` slot) above the item * rows and wires it to Content's `aria-labelledby` when supplied. */ readonly groupLabel?: string; readonly align?: "start" | "end"; readonly onOpenChange?: (detail: DropdownMenuOpenChangeDetail) => void; readonly onSelect?: (id: string) => void; /** Native (production) by default; inject a virtual scheduler for tests. */ readonly scheduler?: Scheduler; /** Render callback for the trigger's content; default = "Open" as textContent. */ readonly renderTrigger?: (button: HTMLElement) => void; /** Render callback for one item row's content; default = item.textValue ?? item.id as textContent. */ readonly renderItem?: (li: HTMLElement, item: DropdownMenuItem) => void;}align"start" | "end"groupLabelstringonOpenChange(detail: DropdownMenuOpenChangeDetail) => voidonSelect(id: string) => voidrenderItem(li: HTMLElement, item: DropdownMenuItem) => voidrenderTrigger(button: HTMLElement) => voidrowsreadonly DropdownMenuRow[]schedulerScheduler- Name
align- Kind
- property
- Type
"start" | "end"- Requirement
- optional
- Description
- —
- Name
groupLabel- Kind
- property
- Type
string- Requirement
- optional
- Description
- Renders a `Menu.GroupLabel` (the legacy `header` slot) above the item rows and wires it to Content's `aria-labelledby` when supplied.
- Name
onOpenChange- Kind
- property
- Type
(detail: DropdownMenuOpenChangeDetail) => void- Requirement
- optional
- Description
- —
- Name
onSelect- Kind
- property
- Type
(id: string) => void- Requirement
- optional
- Description
- —
- Name
renderItem- Kind
- property
- Type
(li: HTMLElement, item: DropdownMenuItem) => void- Requirement
- optional
- Description
- Render callback for one item row's content; default = item.textValue ?? item.id as textContent.
- Name
renderTrigger- Kind
- property
- Type
(button: HTMLElement) => void- Requirement
- optional
- Description
- Render callback for the trigger's content; default = "Open" as textContent.
- Name
rows- Kind
- property
- Type
readonly DropdownMenuRow[]- Requirement
- optional
- Description
- Presentational render order (items + separators). Defaults to `items.map((item) => ({ type: "item", item }))` when omitted — i.e. no separators.
- Name
scheduler- Kind
- property
- Type
Scheduler- Requirement
- optional
- Description
- Native (production) by default; inject a virtual scheduler for tests.
runDropdownMenuCommand
functionDropdownMenu-shaped command runner — mirrors `runDialogCommand`/ `runTooltipCommand`. Pass this as the `runCommand` option when constructing the DropdownMenu `Service` (wrapped in `createScheduledEventRunner`, never called by `connectDropdownMenu` itself). Resolves `OPEN_CHANGE_REQUEST` against an optional `onOpenChange` callback and `SELECT_ITEM` against an optional `onSelect` callback. `statechart.schedule`/`statechart.cancel` are reserved S13 commands intercepted by `createScheduledEventRunner` before they ever reach this runner — the `default` branch stays defensively silent on them (and on any other unrecognized command).
declare function runDropdownMenuCommand(command: DropdownMenuCommand, _scope: PartScope, options?: { readonly onOpenChange?: (detail: { open: boolean; reason: DropdownMenuChangeReason; }) => void; readonly onSelect?: (id: string) => void;}): void;commandDropdownMenuCommand_scopePartScopeoptions{
readonly onOpenChange?: (detail: {
open: boolean;
reason: DropdownMenuChangeReason;
}) => void;
readonly onSelect?: (id: string) => void;
}returnvoid- Name
command- Kind
- parameter
- Type
DropdownMenuCommand- Requirement
- required
- Name
_scope- Kind
- parameter
- Type
PartScope- Requirement
- required
- Name
options- Kind
- parameter
- Type
{ readonly onOpenChange?: (detail: { open: boolean; reason: DropdownMenuChangeReason; }) => void; readonly onSelect?: (id: string) => void; }- Requirement
- optional
- Name
return- Kind
- return value
- Type
void- Requirement
- n/a
Framework adapters
Each panel keeps its adapter's public vocabulary. React compound exports, Vue composables, standalone Angular declarations, Svelte components, and Solid hooks stay native to their framework.
React imports
import { Content, GroupLabel, Item, Menu, Positioner, Root, Separator, Trigger } from "@grassroot/ui-headless-react/dropdown-menu";Vue imports
<script setup lang="ts">import { MenuContent, MenuGroupLabel, MenuItem, MenuPositioner, MenuRoot, MenuSeparator, MenuTrigger } from "@grassroot/ui-headless-vue/dropdown-menu";</script>Angular imports
import { Component } from "@angular/core";import { GR_DROPDOWN_MENU_DECLARATIONS } from "@grassroot/ui-headless-angular/dropdown-menu"; @Component({ standalone: true, imports: [GR_DROPDOWN_MENU_DECLARATIONS], template: `<!-- compose the dropdown-menu parts here -->` })export class Example {}Svelte imports
<script lang="ts"> import { DropdownMenuContent, DropdownMenuGroupLabel, DropdownMenuItem, DropdownMenuPositioner, DropdownMenuRoot, DropdownMenuSeparator, DropdownMenuTrigger } from "@grassroot/ui-headless-svelte/dropdown-menu";</script>Solid imports
import { MenuContent, MenuGroupLabel, MenuItem, MenuPositioner, MenuRoot, MenuSeparator, MenuTrigger } from "@grassroot/ui-headless-solid/dropdown-menu";@grassroot/ui-headless-react/dropdown-menu
React adapter
packages/ui-headless/react/src/dropdown-menu/index.ts
Content
valueexport declare const Content: import("react").ForwardRefExoticComponent<DropdownMenuContentProps & import("react").RefAttributes<HTMLDivElement>>;propsPreturnReactNode- Name
props- Kind
- parameter
- Type
P- Requirement
- required
- Name
return- Kind
- return value
- Type
ReactNode- Requirement
- n/a
DropdownMenuContentProps
interfaceinterface DropdownMenuContentProps extends ComponentPropsWithoutRef<"div"> { readonly asChild?: boolean;}asChildboolean- Name
asChild- Kind
- property
- Type
boolean- Requirement
- optional
DropdownMenuContext
valueexport declare const DropdownMenuContext: import("react").Context<DropdownMenuContextValue | null>;propsPreturnReactNode- Name
props- Kind
- parameter
- Type
P- Requirement
- required
- Name
return- Kind
- return value
- Type
ReactNode- Requirement
- n/a
DropdownMenuContextValue
interfaceinterface DropdownMenuContextValue { readonly service: DropdownMenuService; readonly connector: DropdownMenuApi; readonly scope: PartScope;}connectorDropdownMenuApiscopePartScopeserviceDropdownMenuService- Name
connector- Kind
- property
- Type
DropdownMenuApi- Requirement
- required
- Name
scope- Kind
- property
- Type
PartScope- Requirement
- required
- Name
service- Kind
- property
- Type
DropdownMenuService- Requirement
- required
DropdownMenuGroupLabelProps
interfaceinterface DropdownMenuGroupLabelProps extends ComponentPropsWithoutRef<"div"> { readonly asChild?: boolean;}asChildboolean- Name
asChild- Kind
- property
- Type
boolean- Requirement
- optional
DropdownMenuItemProps
interfaceinterface DropdownMenuItemProps extends ComponentPropsWithoutRef<"div"> { readonly asChild?: boolean; /** The machine item this row represents — id/disabled/textValue map * straight through to the connector's item model. */ readonly item: DropdownMenuItem;}asChildbooleanitemDropdownMenuItem- Name
asChild- Kind
- property
- Type
boolean- Requirement
- optional
- Description
- —
- Name
item- Kind
- property
- Type
DropdownMenuItem- Requirement
- required
- Description
- The machine item this row represents — id/disabled/textValue map straight through to the connector's item model.
DropdownMenuOpenChangeDetail
interfaceinterface DropdownMenuOpenChangeDetail { readonly open: boolean; readonly reason: DropdownMenuChangeReason;}openbooleanreasonDropdownMenuChangeReason- Name
open- Kind
- property
- Type
boolean- Requirement
- required
- Name
reason- Kind
- property
- Type
DropdownMenuChangeReason- Requirement
- required
DropdownMenuPositionerProps
interfaceinterface DropdownMenuPositionerProps extends ComponentPropsWithoutRef<"div"> { readonly asChild?: boolean;}asChildboolean- Name
asChild- Kind
- property
- Type
boolean- Requirement
- optional
DropdownMenuRootProps
interfaceinterface DropdownMenuRootProps { readonly open?: DropdownMenuInput["open"]; readonly defaultOpen?: DropdownMenuInput["defaultOpen"]; readonly items: DropdownMenuInput["items"]; readonly typeaheadTimeoutMs?: DropdownMenuInput["typeaheadTimeoutMs"]; /** Static positioning hint carried as `data-align` on the positioner. Default "start". */ readonly align?: UseDropdownMenuOptions["align"]; readonly onOpenChange?: (detail: DropdownMenuOpenChangeDetail) => void; readonly onSelect?: (id: string) => void; /** Native (production) by default; inject a virtual scheduler for tests. */ readonly scheduler?: UseDropdownMenuOptions["scheduler"]; readonly children?: ReactNode;}alignUseDropdownMenuOptions["align"]childrenReactNodedefaultOpenDropdownMenuInput["defaultOpen"]itemsDropdownMenuInput["items"]onOpenChange(detail: DropdownMenuOpenChangeDetail) => voidonSelect(id: string) => voidopenDropdownMenuInput["open"]schedulerUseDropdownMenuOptions["scheduler"]typeaheadTimeoutMsDropdownMenuInput["typeaheadTimeoutMs"]- Name
align- Kind
- property
- Type
UseDropdownMenuOptions["align"]- Requirement
- optional
- Description
- Static positioning hint carried as `data-align` on the positioner. Default "start".
- Name
children- Kind
- property
- Type
ReactNode- Requirement
- optional
- Description
- —
- Name
defaultOpen- Kind
- property
- Type
DropdownMenuInput["defaultOpen"]- Requirement
- optional
- Description
- —
- Name
items- Kind
- property
- Type
DropdownMenuInput["items"]- Requirement
- required
- Description
- —
- Name
onOpenChange- Kind
- property
- Type
(detail: DropdownMenuOpenChangeDetail) => void- Requirement
- optional
- Description
- —
- Name
onSelect- Kind
- property
- Type
(id: string) => void- Requirement
- optional
- Description
- —
- Name
open- Kind
- property
- Type
DropdownMenuInput["open"]- Requirement
- optional
- Description
- —
- Name
scheduler- Kind
- property
- Type
UseDropdownMenuOptions["scheduler"]- Requirement
- optional
- Description
- Native (production) by default; inject a virtual scheduler for tests.
- Name
typeaheadTimeoutMs- Kind
- property
- Type
DropdownMenuInput["typeaheadTimeoutMs"]- Requirement
- optional
- Description
- —
DropdownMenuSeparatorProps
interfaceinterface DropdownMenuSeparatorProps extends ComponentPropsWithoutRef<"hr"> { readonly asChild?: boolean;}asChildboolean- Name
asChild- Kind
- property
- Type
boolean- Requirement
- optional
DropdownMenuTriggerProps
interfaceinterface DropdownMenuTriggerProps extends Omit<ComponentPropsWithoutRef<"button">, "type"> { readonly asChild?: boolean;}asChildboolean- Name
asChild- Kind
- property
- Type
boolean- Requirement
- optional
GroupLabel
valueexport declare const GroupLabel: import("react").ForwardRefExoticComponent<DropdownMenuGroupLabelProps & import("react").RefAttributes<HTMLDivElement>>;propsPreturnReactNode- Name
props- Kind
- parameter
- Type
P- Requirement
- required
- Name
return- Kind
- return value
- Type
ReactNode- Requirement
- n/a
Item
valueexport declare const Item: import("react").ForwardRefExoticComponent<DropdownMenuItemProps & import("react").RefAttributes<HTMLDivElement>>;propsPreturnReactNode- Name
props- Kind
- parameter
- Type
P- Requirement
- required
- Name
return- Kind
- return value
- Type
ReactNode- Requirement
- n/a
Menu
valueexport declare const Menu: { Root: typeof Root; Trigger: import("react").ForwardRefExoticComponent<DropdownMenuTriggerProps & import("react").RefAttributes<HTMLButtonElement>>; Positioner: import("react").ForwardRefExoticComponent<DropdownMenuPositionerProps & import("react").RefAttributes<HTMLDivElement>>; Content: import("react").ForwardRefExoticComponent<DropdownMenuContentProps & import("react").RefAttributes<HTMLDivElement>>; Item: import("react").ForwardRefExoticComponent<DropdownMenuItemProps & import("react").RefAttributes<HTMLDivElement>>; Separator: import("react").ForwardRefExoticComponent<DropdownMenuSeparatorProps & import("react").RefAttributes<HTMLHRElement>>; GroupLabel: import("react").ForwardRefExoticComponent<DropdownMenuGroupLabelProps & import("react").RefAttributes<HTMLDivElement>>;};Contentimport("react").ForwardRefExoticComponent<DropdownMenuContentProps & import("react").RefAttributes<HTMLDivElement>>GroupLabelimport("react").ForwardRefExoticComponent<DropdownMenuGroupLabelProps & import("react").RefAttributes<HTMLDivElement>>Itemimport("react").ForwardRefExoticComponent<DropdownMenuItemProps & import("react").RefAttributes<HTMLDivElement>>Positionerimport("react").ForwardRefExoticComponent<DropdownMenuPositionerProps & import("react").RefAttributes<HTMLDivElement>>Roottypeof RootSeparatorimport("react").ForwardRefExoticComponent<DropdownMenuSeparatorProps & import("react").RefAttributes<HTMLHRElement>>Triggerimport("react").ForwardRefExoticComponent<DropdownMenuTriggerProps & import("react").RefAttributes<HTMLButtonElement>>- Name
Content- Kind
- property
- Type
import("react").ForwardRefExoticComponent<DropdownMenuContentProps & import("react").RefAttributes<HTMLDivElement>>- Requirement
- required
- Name
GroupLabel- Kind
- property
- Type
import("react").ForwardRefExoticComponent<DropdownMenuGroupLabelProps & import("react").RefAttributes<HTMLDivElement>>- Requirement
- required
- Name
Item- Kind
- property
- Type
import("react").ForwardRefExoticComponent<DropdownMenuItemProps & import("react").RefAttributes<HTMLDivElement>>- Requirement
- required
- Name
Positioner- Kind
- property
- Type
import("react").ForwardRefExoticComponent<DropdownMenuPositionerProps & import("react").RefAttributes<HTMLDivElement>>- Requirement
- required
- Name
Root- Kind
- property
- Type
typeof Root- Requirement
- required
- Name
Separator- Kind
- property
- Type
import("react").ForwardRefExoticComponent<DropdownMenuSeparatorProps & import("react").RefAttributes<HTMLHRElement>>- Requirement
- required
- Name
Trigger- Kind
- property
- Type
import("react").ForwardRefExoticComponent<DropdownMenuTriggerProps & import("react").RefAttributes<HTMLButtonElement>>- Requirement
- required
Positioner
valueexport declare const Positioner: import("react").ForwardRefExoticComponent<DropdownMenuPositionerProps & import("react").RefAttributes<HTMLDivElement>>;propsPreturnReactNode- Name
props- Kind
- parameter
- Type
P- Requirement
- required
- Name
return- Kind
- return value
- Type
ReactNode- Requirement
- n/a
Root
functiondeclare function Root(props: DropdownMenuRootProps): import("react").JSX.Element;propsDropdownMenuRootPropsreturnimport("react").JSX.Element- Name
props- Kind
- parameter
- Type
DropdownMenuRootProps- Requirement
- required
- Name
return- Kind
- return value
- Type
import("react").JSX.Element- Requirement
- n/a
Separator
valueexport declare const Separator: import("react").ForwardRefExoticComponent<DropdownMenuSeparatorProps & import("react").RefAttributes<HTMLHRElement>>;propsPreturnReactNode- Name
props- Kind
- parameter
- Type
P- Requirement
- required
- Name
return- Kind
- return value
- Type
ReactNode- Requirement
- n/a
Trigger
valueexport declare const Trigger: import("react").ForwardRefExoticComponent<DropdownMenuTriggerProps & import("react").RefAttributes<HTMLButtonElement>>;propsPreturnReactNode- Name
props- Kind
- parameter
- Type
P- Requirement
- required
- Name
return- Kind
- return value
- Type
ReactNode- Requirement
- n/a
useDropdownMenu
functiondeclare function useDropdownMenu(input: DropdownMenuInput$1, options?: UseDropdownMenuOptions): UseDropdownMenuResult;inputDropdownMenuInput$1optionsUseDropdownMenuOptionsreturnUseDropdownMenuResult- Name
input- Kind
- parameter
- Type
DropdownMenuInput$1- Requirement
- required
- Name
options- Kind
- parameter
- Type
UseDropdownMenuOptions- Requirement
- optional
- Name
return- Kind
- return value
- Type
UseDropdownMenuResult- Requirement
- n/a
useDropdownMenuContext
functiondeclare function useDropdownMenuContext(partName: string): DropdownMenuContextValue;partNamestringreturnDropdownMenuContextValue- Name
partName- Kind
- parameter
- Type
string- Requirement
- required
- Name
return- Kind
- return value
- Type
DropdownMenuContextValue- Requirement
- n/a
UseDropdownMenuOptions
interfaceinterface UseDropdownMenuOptions { readonly onOpenChange?: (detail: DropdownMenuOpenChangeDetail) => void; readonly onSelect?: (id: string) => void; readonly align?: "start" | "end"; /** Native (production) by default; inject a virtual scheduler for tests. */ readonly scheduler?: Scheduler;}align"start" | "end"onOpenChange(detail: DropdownMenuOpenChangeDetail) => voidonSelect(id: string) => voidschedulerScheduler- Name
align- Kind
- property
- Type
"start" | "end"- Requirement
- optional
- Description
- —
- Name
onOpenChange- Kind
- property
- Type
(detail: DropdownMenuOpenChangeDetail) => void- Requirement
- optional
- Description
- —
- Name
onSelect- Kind
- property
- Type
(id: string) => void- Requirement
- optional
- Description
- —
- Name
scheduler- Kind
- property
- Type
Scheduler- Requirement
- optional
- Description
- Native (production) by default; inject a virtual scheduler for tests.
UseDropdownMenuResult
interfaceinterface UseDropdownMenuResult { readonly service: DropdownMenuService; readonly connector: DropdownMenuApi; readonly scope: PartScope; readonly snapshot: DropdownMenuSnapshot;}connectorDropdownMenuApiscopePartScopeserviceDropdownMenuServicesnapshotDropdownMenuSnapshot- Name
connector- Kind
- property
- Type
DropdownMenuApi- Requirement
- required
- Name
scope- Kind
- property
- Type
PartScope- Requirement
- required
- Name
service- Kind
- property
- Type
DropdownMenuService- Requirement
- required
- Name
snapshot- Kind
- property
- Type
DropdownMenuSnapshot- Requirement
- required
useServiceVersion
functionSubscribes a component to a service's committed-snapshot version.
declare function useServiceVersion<S extends Service<any, any, any, any, any, any>>(service: S): ReturnType<S["getSnapshot"]>;serviceSreturnReturnType<S["getSnapshot"]>- Name
service- Kind
- parameter
- Type
S- Requirement
- required
- Name
return- Kind
- return value
- Type
ReturnType<S["getSnapshot"]>- Requirement
- n/a
@grassroot/ui-headless-vue/dropdown-menu
Vue adapter
packages/ui-headless/vue/src/dropdown-menu/index.ts
DropdownMenuContextKey
valueexport declare const DropdownMenuContextKey: InjectionKey<DropdownMenuContextValue>;DropdownMenuContextValue
interfaceinterface DropdownMenuContextValue { readonly service: DropdownMenuService; readonly connector: DropdownMenuApi; readonly scope: PartScope; /** Bumped on every committed machine update; parts read `.value` to establish a reactive dependency. */ readonly snapshot: ShallowRef<DropdownMenuSnapshot>;}connectorDropdownMenuApiscopePartScopeserviceDropdownMenuServicesnapshotShallowRef<DropdownMenuSnapshot>- Name
connector- Kind
- property
- Type
DropdownMenuApi- Requirement
- required
- Description
- —
- Name
scope- Kind
- property
- Type
PartScope- Requirement
- required
- Description
- —
- Name
service- Kind
- property
- Type
DropdownMenuService- Requirement
- required
- Description
- —
- Name
snapshot- Kind
- property
- Type
ShallowRef<DropdownMenuSnapshot>- Requirement
- required
- Description
- Bumped on every committed machine update; parts read `.value` to establish a reactive dependency.
DropdownMenuOpenChangeDetail
interfaceinterface DropdownMenuOpenChangeDetail { readonly open: boolean; readonly reason: DropdownMenuChangeReason;}openbooleanreasonDropdownMenuChangeReason- Name
open- Kind
- property
- Type
boolean- Requirement
- required
- Name
reason- Kind
- property
- Type
DropdownMenuChangeReason- Requirement
- required
MenuContent
valueexport declare const MenuContent: import("vue").DefineComponent<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; };}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, { [key: string]: any;}> | null, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; };}>> & Readonly<{}>, { asChild: boolean;}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;MenuGroupLabel
valueexport declare const MenuGroupLabel: import("vue").DefineComponent<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; };}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, { [key: string]: any;}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; };}>> & Readonly<{}>, { asChild: boolean;}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;MenuItem
valueexport declare const MenuItem: import("vue").DefineComponent<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; }; /** The machine item this row represents — id/disabled/textValue map * straight through to the connector's item model. */ item: { type: PropType<DropdownMenuItem>; required: true; };}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, { [key: string]: any;}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; }; /** The machine item this row represents — id/disabled/textValue map * straight through to the connector's item model. */ item: { type: PropType<DropdownMenuItem>; required: true; };}>> & Readonly<{}>, { asChild: boolean;}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;MenuPositioner
valueexport declare const MenuPositioner: import("vue").DefineComponent<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; };}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, { [key: string]: any;}> | null, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; };}>> & Readonly<{}>, { asChild: boolean;}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;MenuRoot
valueexport declare const MenuRoot: import("vue").DefineComponent<import("vue").ExtractPropTypes<{ open: { type: PropType<DropdownMenuInput["open"]>; default: undefined; }; defaultOpen: { type: PropType<DropdownMenuInput["defaultOpen"]>; default: undefined; }; items: { type: PropType<DropdownMenuInput["items"]>; required: true; }; typeaheadTimeoutMs: { type: PropType<DropdownMenuInput["typeaheadTimeoutMs"]>; default: undefined; }; /** Static positioning hint carried as `data-align` on the positioner. Default "start". */ align: { type: PropType<UseDropdownMenuOptions["align"]>; default: undefined; }; /** Native (production) by default; inject a virtual scheduler for tests. */ scheduler: { type: PropType<UseDropdownMenuOptions["scheduler"]>; default: undefined; };}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, { [key: string]: any;}>[] | undefined, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, { openChange: (_detail: DropdownMenuOpenChangeDetail) => true; select: (_id: string) => true;}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{ open: { type: PropType<DropdownMenuInput["open"]>; default: undefined; }; defaultOpen: { type: PropType<DropdownMenuInput["defaultOpen"]>; default: undefined; }; items: { type: PropType<DropdownMenuInput["items"]>; required: true; }; typeaheadTimeoutMs: { type: PropType<DropdownMenuInput["typeaheadTimeoutMs"]>; default: undefined; }; /** Static positioning hint carried as `data-align` on the positioner. Default "start". */ align: { type: PropType<UseDropdownMenuOptions["align"]>; default: undefined; }; /** Native (production) by default; inject a virtual scheduler for tests. */ scheduler: { type: PropType<UseDropdownMenuOptions["scheduler"]>; default: undefined; };}>> & Readonly<{ onOpenChange?: ((_detail: DropdownMenuOpenChangeDetail) => any) | undefined; onSelect?: ((_id: string) => any) | undefined;}>, { open: boolean | undefined; defaultOpen: boolean | undefined; typeaheadTimeoutMs: number | undefined; align: "end" | "start" | undefined; scheduler: import("@grassroot/statechart/scheduler").Scheduler | undefined;}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;MenuSeparator
valueexport declare const MenuSeparator: import("vue").DefineComponent<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; };}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, { [key: string]: any;}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; };}>> & Readonly<{}>, { asChild: boolean;}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;MenuTrigger
valueexport declare const MenuTrigger: import("vue").DefineComponent<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; };}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, { [key: string]: any;}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{ asChild: { type: BooleanConstructor; default: boolean; };}>> & Readonly<{}>, { asChild: boolean;}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;useDropdownMenu
functiondeclare function useDropdownMenu(input: DropdownMenuInput | (() => DropdownMenuInput), options?: UseDropdownMenuOptions): UseDropdownMenuResult;inputDropdownMenuInput | (() => DropdownMenuInput)optionsUseDropdownMenuOptionsreturnUseDropdownMenuResult- Name
input- Kind
- parameter
- Type
DropdownMenuInput | (() => DropdownMenuInput)- Requirement
- required
- Name
options- Kind
- parameter
- Type
UseDropdownMenuOptions- Requirement
- optional
- Name
return- Kind
- return value
- Type
UseDropdownMenuResult- Requirement
- n/a
useDropdownMenuContext
functiondeclare function useDropdownMenuContext(partName: string): DropdownMenuContextValue;partNamestringreturnDropdownMenuContextValue- Name
partName- Kind
- parameter
- Type
string- Requirement
- required
- Name
return- Kind
- return value
- Type
DropdownMenuContextValue- Requirement
- n/a
UseDropdownMenuOptions
interfaceinterface UseDropdownMenuOptions { readonly onOpenChange?: (detail: DropdownMenuOpenChangeDetail) => void; readonly onSelect?: (id: string) => void; readonly align?: "start" | "end"; readonly scheduler?: Scheduler;}align"start" | "end"onOpenChange(detail: DropdownMenuOpenChangeDetail) => voidonSelect(id: string) => voidschedulerScheduler- Name
align- Kind
- property
- Type
"start" | "end"- Requirement
- optional
- Name
onOpenChange- Kind
- property
- Type
(detail: DropdownMenuOpenChangeDetail) => void- Requirement
- optional
- Name
onSelect- Kind
- property
- Type
(id: string) => void- Requirement
- optional
- Name
scheduler- Kind
- property
- Type
Scheduler- Requirement
- optional
UseDropdownMenuResult
interfaceinterface UseDropdownMenuResult { readonly service: DropdownMenuService; readonly connector: DropdownMenuApi; readonly scope: PartScope; readonly snapshot: ShallowRef<DropdownMenuSnapshot>;}connectorDropdownMenuApiscopePartScopeserviceDropdownMenuServicesnapshotShallowRef<DropdownMenuSnapshot>- Name
connector- Kind
- property
- Type
DropdownMenuApi- Requirement
- required
- Name
scope- Kind
- property
- Type
PartScope- Requirement
- required
- Name
service- Kind
- property
- Type
DropdownMenuService- Requirement
- required
- Name
snapshot- Kind
- property
- Type
ShallowRef<DropdownMenuSnapshot>- Requirement
- required
@grassroot/ui-headless-angular/dropdown-menu
Angular adapter
packages/ui-headless/angular/src/dropdown-menu/index.ts
createDropdownMenuStore
functionexport declare function createDropdownMenuStore(initialInput: DropdownMenuInput, options?: CreateDropdownMenuStoreOptions): DropdownMenuStore;initialInputDropdownMenuInputoptionsCreateDropdownMenuStoreOptionsreturnDropdownMenuStore- Name
initialInput- Kind
- parameter
- Type
DropdownMenuInput- Requirement
- required
- Name
options- Kind
- parameter
- Type
CreateDropdownMenuStoreOptions- Requirement
- optional
- Name
return- Kind
- return value
- Type
DropdownMenuStore- Requirement
- n/a
CreateDropdownMenuStoreOptions
interfaceexport interface CreateDropdownMenuStoreOptions { readonly onOpenChange?: (detail: DropdownMenuOpenChangeDetail) => void; readonly onSelect?: (id: string) => void; readonly onCommit?: () => void; readonly align?: "start" | "end" | (() => "start" | "end" | undefined); readonly scheduler?: Scheduler;}align"start" | "end" | (() => "start" | "end" | undefined)onCommit() => voidonOpenChange(detail: DropdownMenuOpenChangeDetail) => voidonSelect(id: string) => voidschedulerScheduler- Name
align- Kind
- property
- Type
"start" | "end" | (() => "start" | "end" | undefined)- Requirement
- optional
- Name
onCommit- Kind
- property
- Type
() => void- Requirement
- optional
- Name
onOpenChange- Kind
- property
- Type
(detail: DropdownMenuOpenChangeDetail) => void- Requirement
- optional
- Name
onSelect- Kind
- property
- Type
(id: string) => void- Requirement
- optional
- Name
scheduler- Kind
- property
- Type
Scheduler- Requirement
- optional
DROPDOWN_MENU_STORE
valueexport declare const DROPDOWN_MENU_STORE: InjectionToken<DropdownMenuStore>;DropdownMenuOpenChangeDetail
interfaceexport interface DropdownMenuOpenChangeDetail { readonly open: boolean; readonly reason: DropdownMenuChangeReason;}openbooleanreasonDropdownMenuChangeReason- Name
open- Kind
- property
- Type
boolean- Requirement
- required
- Name
reason- Kind
- property
- Type
DropdownMenuChangeReason- Requirement
- required
DropdownMenuStore
interfaceexport interface DropdownMenuStore { readonly service: DropdownMenuService; readonly connector: DropdownMenuApi; readonly scope: PartScope; /** * Bumped on every committed machine update. Effects that read the * connector's prop bags must read this signal first — inside the same * `effect()` — so Angular's reactivity re-runs the effect on every * committed change (the staleness bug class called out across every * other adapter). */ readonly version: WritableSignal<number>; /** Starts the underlying service (idempotent) — call from the browser only. */ start(): void; /** Stops the underlying service (idempotent). */ stop(): void; /** Forwards a new committed input to the machine (no-op on the very first call). */ sync(input: DropdownMenuInput): void;}connectorDropdownMenuApiscopePartScopeserviceDropdownMenuServicestart() => voidstop() => voidsync(input: DropdownMenuInput) => voidversionWritableSignal<number>- Name
connector- Kind
- property
- Type
DropdownMenuApi- Requirement
- required
- Description
- —
- Name
scope- Kind
- property
- Type
PartScope- Requirement
- required
- Description
- —
- Name
service- Kind
- property
- Type
DropdownMenuService- Requirement
- required
- Description
- —
- Name
start- Kind
- method
- Type
() => void- Requirement
- required
- Description
- Starts the underlying service (idempotent) — call from the browser only.
- Name
stop- Kind
- method
- Type
() => void- Requirement
- required
- Description
- Stops the underlying service (idempotent).
- Name
sync- Kind
- method
- Type
(input: DropdownMenuInput) => void- Requirement
- required
- Description
- Forwards a new committed input to the machine (no-op on the very first call).
- Name
version- Kind
- property
- Type
WritableSignal<number>- Requirement
- required
- Description
- Bumped on every committed machine update. Effects that read the connector's prop bags must read this signal first — inside the same `effect()` — so Angular's reactivity re-runs the effect on every committed change (the staleness bug class called out across every other adapter).
export declare const GR_DROPDOWN_MENU_DECLARATIONS: readonly [typeof GrDropdownMenuRoot, typeof GrDropdownMenuTrigger, typeof GrDropdownMenuOpen, typeof GrDropdownMenuPositioner, typeof GrDropdownMenuContent, typeof GrDropdownMenuItem, typeof GrDropdownMenuSeparator, typeof GrDropdownMenuGroupLabel];GrDropdownMenuContent
classexport declare class GrDropdownMenuContent implements OnDestroy { private readonly store; private readonly elementRef; private readonly listeners; private readonly consumerProps; constructor(); ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration<GrDropdownMenuContent, never>; static ɵdir: i0.ɵɵDirectiveDeclaration<GrDropdownMenuContent, "[grDropdownMenuContent]", never, {}, {}, never, never, true, never>;}consumerPropsanyelementRefanylistenersanyngOnDestroy() => voidɵdiri0.ɵɵDirectiveDeclaration<GrDropdownMenuContent, "[grDropdownMenuContent]", never, {}, {}, never, never, true, never>ɵfaci0.ɵɵFactoryDeclaration<GrDropdownMenuContent, never>storeany- Name
consumerProps- Kind
- property
- Type
any- Requirement
- required
- Name
elementRef- Kind
- property
- Type
any- Requirement
- required
- Name
listeners- Kind
- property
- Type
any- Requirement
- required
- Name
ngOnDestroy- Kind
- method
- Type
() => void- Requirement
- required
- Name
ɵdir- Kind
- property
- Type
i0.ɵɵDirectiveDeclaration<GrDropdownMenuContent, "[grDropdownMenuContent]", never, {}, {}, never, never, true, never>- Requirement
- required
- Name
ɵfac- Kind
- property
- Type
i0.ɵɵFactoryDeclaration<GrDropdownMenuContent, never>- Requirement
- required
- Name
store- Kind
- property
- Type
any- Requirement
- required
GrDropdownMenuGroupLabel
classexport declare class GrDropdownMenuGroupLabel implements OnDestroy { private readonly store; private readonly elementRef; private readonly listeners; private readonly consumerProps; constructor(); ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration<GrDropdownMenuGroupLabel, never>; static ɵdir: i0.ɵɵDirectiveDeclaration<GrDropdownMenuGroupLabel, "[grDropdownMenuGroupLabel]", never, {}, {}, never, never, true, never>;}consumerPropsanyelementRefanylistenersanyngOnDestroy() => voidɵdiri0.ɵɵDirectiveDeclaration<GrDropdownMenuGroupLabel, "[grDropdownMenuGroupLabel]", never, {}, {}, never, never, true, never>ɵfaci0.ɵɵFactoryDeclaration<GrDropdownMenuGroupLabel, never>storeany- Name
consumerProps- Kind
- property
- Type
any- Requirement
- required
- Name
elementRef- Kind
- property
- Type
any- Requirement
- required
- Name
listeners- Kind
- property
- Type
any- Requirement
- required
- Name
ngOnDestroy- Kind
- method
- Type
() => void- Requirement
- required
- Name
ɵdir- Kind
- property
- Type
i0.ɵɵDirectiveDeclaration<GrDropdownMenuGroupLabel, "[grDropdownMenuGroupLabel]", never, {}, {}, never, never, true, never>- Requirement
- required
- Name
ɵfac- Kind
- property
- Type
i0.ɵɵFactoryDeclaration<GrDropdownMenuGroupLabel, never>- Requirement
- required
- Name
store- Kind
- property
- Type
any- Requirement
- required
GrDropdownMenuItem
classexport declare class GrDropdownMenuItem implements OnDestroy { readonly item: import("@angular/core").InputSignal<DropdownMenuItem>; private readonly store; private readonly elementRef; private readonly listeners; private readonly consumerProps; private registeredKey; constructor(); ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration<GrDropdownMenuItem, never>; static ɵdir: i0.ɵɵDirectiveDeclaration<GrDropdownMenuItem, "[grDropdownMenuItem]", never, { "item": { "alias": "item"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>;}consumerPropsanyelementRefanyitemimport("@angular/core").InputSignal<DropdownMenuItem>listenersanyngOnDestroy() => voidɵdiri0.ɵɵDirectiveDeclaration<GrDropdownMenuItem, "[grDropdownMenuItem]", never, { "item": { "alias": "item"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>ɵfaci0.ɵɵFactoryDeclaration<GrDropdownMenuItem, never>registeredKeyanystoreany- Name
consumerProps- Kind
- property
- Type
any- Requirement
- required
- Name
elementRef- Kind
- property
- Type
any- Requirement
- required
- Name
item- Kind
- property
- Type
import("@angular/core").InputSignal<DropdownMenuItem>- Requirement
- required
- Name
listeners- Kind
- property
- Type
any- Requirement
- required
- Name
ngOnDestroy- Kind
- method
- Type
() => void- Requirement
- required
- Name
ɵdir- Kind
- property
- Type
i0.ɵɵDirectiveDeclaration<GrDropdownMenuItem, "[grDropdownMenuItem]", never, { "item": { "alias": "item"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>- Requirement
- required
- Name
ɵfac- Kind
- property
- Type
i0.ɵɵFactoryDeclaration<GrDropdownMenuItem, never>- Requirement
- required
- Name
registeredKey- Kind
- property
- Type
any- Requirement
- required
- Name
store- Kind
- property
- Type
any- Requirement
- required
GrDropdownMenuOpen
classexport declare class GrDropdownMenuOpen implements OnDestroy { private readonly store; private readonly templateRef; private readonly viewContainerRef; private hasView; constructor(); ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration<GrDropdownMenuOpen, never>; static ɵdir: i0.ɵɵDirectiveDeclaration<GrDropdownMenuOpen, "[grDropdownMenuOpen]", never, {}, {}, never, never, true, never>;}hasViewanyngOnDestroy() => voidɵdiri0.ɵɵDirectiveDeclaration<GrDropdownMenuOpen, "[grDropdownMenuOpen]", never, {}, {}, never, never, true, never>ɵfaci0.ɵɵFactoryDeclaration<GrDropdownMenuOpen, never>storeanytemplateRefanyviewContainerRefany- Name
hasView- Kind
- property
- Type
any- Requirement
- required
- Name
ngOnDestroy- Kind
- method
- Type
() => void- Requirement
- required
- Name
ɵdir- Kind
- property
- Type
i0.ɵɵDirectiveDeclaration<GrDropdownMenuOpen, "[grDropdownMenuOpen]", never, {}, {}, never, never, true, never>- Requirement
- required
- Name
ɵfac- Kind
- property
- Type
i0.ɵɵFactoryDeclaration<GrDropdownMenuOpen, never>- Requirement
- required
- Name
store- Kind
- property
- Type
any- Requirement
- required
- Name
templateRef- Kind
- property
- Type
any- Requirement
- required
- Name
viewContainerRef- Kind
- property
- Type
any- Requirement
- required
GrDropdownMenuPositioner
classexport declare class GrDropdownMenuPositioner implements OnDestroy { private readonly store; private readonly elementRef; private readonly listeners; private readonly consumerProps; constructor(); ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration<GrDropdownMenuPositioner, never>; static ɵdir: i0.ɵɵDirectiveDeclaration<GrDropdownMenuPositioner, "[grDropdownMenuPositioner]", never, {}, {}, never, never, true, never>;}consumerPropsanyelementRefanylistenersanyngOnDestroy() => voidɵdiri0.ɵɵDirectiveDeclaration<GrDropdownMenuPositioner, "[grDropdownMenuPositioner]", never, {}, {}, never, never, true, never>ɵfaci0.ɵɵFactoryDeclaration<GrDropdownMenuPositioner, never>storeany- Name
consumerProps- Kind
- property
- Type
any- Requirement
- required
- Name
elementRef- Kind
- property
- Type
any- Requirement
- required
- Name
listeners- Kind
- property
- Type
any- Requirement
- required
- Name
ngOnDestroy- Kind
- method
- Type
() => void- Requirement
- required
- Name
ɵdir- Kind
- property
- Type
i0.ɵɵDirectiveDeclaration<GrDropdownMenuPositioner, "[grDropdownMenuPositioner]", never, {}, {}, never, never, true, never>- Requirement
- required
- Name
ɵfac- Kind
- property
- Type
i0.ɵɵFactoryDeclaration<GrDropdownMenuPositioner, never>- Requirement
- required
- Name
store- Kind
- property
- Type
any- Requirement
- required
GrDropdownMenuRoot
classexport declare class GrDropdownMenuRoot implements OnDestroy { readonly open: import("@angular/core").InputSignal<boolean | undefined>; readonly defaultOpen: import("@angular/core").InputSignal<boolean | undefined>; readonly items: import("@angular/core").InputSignal<readonly import("@grassroot/ui-machines/dropdown-menu").DropdownMenuItem[]>; readonly typeaheadTimeoutMs: import("@angular/core").InputSignal<number | undefined>; /** Static positioning hint — see `use-dropdown-menu.ts`'s * `CreateDropdownMenuStoreOptions.align` doc comment: read once, here, * at construction (no live setter, mirroring core's own one-shot * `options.align` read). */ readonly align: import("@angular/core").InputSignal<"start" | "end" | undefined>; readonly openChange: import("@angular/core").OutputEmitterRef<DropdownMenuOpenChangeDetail>; readonly select: import("@angular/core").OutputEmitterRef<string>; private readonly injector; private lastSynced; private releaseManagers; readonly store: DropdownMenuStore; constructor(); ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration<GrDropdownMenuRoot, never>; static ɵdir: i0.ɵɵDirectiveDeclaration<GrDropdownMenuRoot, "[grDropdownMenuRoot]", never, { "open": { "alias": "open"; "required": false; "isSignal": true; }; "defaultOpen": { "alias": "defaultOpen"; "required": false; "isSignal": true; }; "items": { "alias": "items"; "required": false; "isSignal": true; }; "typeaheadTimeoutMs": { "alias": "typeaheadTimeoutMs"; "required": false; "isSignal": true; }; "align": { "alias": "align"; "required": false; "isSignal": true; }; }, { "openChange": "openChange"; "select": "select"; }, never, never, true, never>;}alignimport("@angular/core").InputSignal<"start" | "end" | undefined>defaultOpenimport("@angular/core").InputSignal<boolean | undefined>injectoranyitemsimport("@angular/core").InputSignal<readonly import("@grassroot/ui-machines/dropdown-menu").DropdownMenuItem[]>lastSyncedanyngOnDestroy() => voidopenimport("@angular/core").InputSignal<boolean | undefined>openChangeimport("@angular/core").OutputEmitterRef<DropdownMenuOpenChangeDetail>ɵdiri0.ɵɵDirectiveDeclaration<GrDropdownMenuRoot, "[grDropdownMenuRoot]", never, { "open": { "alias": "open"; "required": false; "isSignal": true; }; "defaultOpen": { "alias": "defaultOpen"; "required": false; "isSignal": true; }; "items": { "alias": "items"; "required": false; "isSignal": true; }; "typeaheadTimeoutMs": { "alias": "typeaheadTimeoutMs"; "required": false; "isSignal": true; }; "align": { "alias": "align"; "required": false; "isSignal": true; }; }, { "openChange": "openChange"; "select": "select"; }, never, never, true, never>ɵfaci0.ɵɵFactoryDeclaration<GrDropdownMenuRoot, never>releaseManagersanyselectimport("@angular/core").OutputEmitterRef<string>storeDropdownMenuStoretypeaheadTimeoutMsimport("@angular/core").InputSignal<number | undefined>- Name
align- Kind
- property
- Type
import("@angular/core").InputSignal<"start" | "end" | undefined>- Requirement
- required
- Description
- Static positioning hint — see `use-dropdown-menu.ts`'s `CreateDropdownMenuStoreOptions.align` doc comment: read once, here, at construction (no live setter, mirroring core's own one-shot `options.align` read).
- Name
defaultOpen- Kind
- property
- Type
import("@angular/core").InputSignal<boolean | undefined>- Requirement
- required
- Description
- —
- Name
injector- Kind
- property
- Type
any- Requirement
- required
- Description
- —
- Name
items- Kind
- property
- Type
import("@angular/core").InputSignal<readonly import("@grassroot/ui-machines/dropdown-menu").DropdownMenuItem[]>- Requirement
- required
- Description
- —
- Name
lastSynced- Kind
- property
- Type
any- Requirement
- required
- Description
- —
- Name
ngOnDestroy- Kind
- method
- Type
() => void- Requirement
- required
- Description
- —
- Name
open- Kind
- property
- Type
import("@angular/core").InputSignal<boolean | undefined>- Requirement
- required
- Description
- —
- Name
openChange- Kind
- property
- Type
import("@angular/core").OutputEmitterRef<DropdownMenuOpenChangeDetail>- Requirement
- required
- Description
- —
- Name
ɵdir- Kind
- property
- Type
i0.ɵɵDirectiveDeclaration<GrDropdownMenuRoot, "[grDropdownMenuRoot]", never, { "open": { "alias": "open"; "required": false; "isSignal": true; }; "defaultOpen": { "alias": "defaultOpen"; "required": false; "isSignal": true; }; "items": { "alias": "items"; "required": false; "isSignal": true; }; "typeaheadTimeoutMs": { "alias": "typeaheadTimeoutMs"; "required": false; "isSignal": true; }; "align": { "alias": "align"; "required": false; "isSignal": true; }; }, { "openChange": "openChange"; "select": "select"; }, never, never, true, never>- Requirement
- required
- Description
- —
- Name
ɵfac- Kind
- property
- Type
i0.ɵɵFactoryDeclaration<GrDropdownMenuRoot, never>- Requirement
- required
- Description
- —
- Name
releaseManagers- Kind
- property
- Type
any- Requirement
- required
- Description
- —
- Name
select- Kind
- property
- Type
import("@angular/core").OutputEmitterRef<string>- Requirement
- required
- Description
- —
- Name
store- Kind
- property
- Type
DropdownMenuStore- Requirement
- required
- Description
- —
- Name
typeaheadTimeoutMs- Kind
- property
- Type
import("@angular/core").InputSignal<number | undefined>- Requirement
- required
- Description
- —
GrDropdownMenuSeparator
classexport declare class GrDropdownMenuSeparator implements OnDestroy { private readonly store; private readonly elementRef; private readonly listeners; private readonly consumerProps; constructor(); ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration<GrDropdownMenuSeparator, never>; static ɵdir: i0.ɵɵDirectiveDeclaration<GrDropdownMenuSeparator, "[grDropdownMenuSeparator]", never, {}, {}, never, never, true, never>;}consumerPropsanyelementRefanylistenersanyngOnDestroy() => voidɵdiri0.ɵɵDirectiveDeclaration<GrDropdownMenuSeparator, "[grDropdownMenuSeparator]", never, {}, {}, never, never, true, never>ɵfaci0.ɵɵFactoryDeclaration<GrDropdownMenuSeparator, never>storeany- Name
consumerProps- Kind
- property
- Type
any- Requirement
- required
- Name
elementRef- Kind
- property
- Type
any- Requirement
- required
- Name
listeners- Kind
- property
- Type
any- Requirement
- required
- Name
ngOnDestroy- Kind
- method
- Type
() => void- Requirement
- required
- Name
ɵdir- Kind
- property
- Type
i0.ɵɵDirectiveDeclaration<GrDropdownMenuSeparator, "[grDropdownMenuSeparator]", never, {}, {}, never, never, true, never>- Requirement
- required
- Name
ɵfac- Kind
- property
- Type
i0.ɵɵFactoryDeclaration<GrDropdownMenuSeparator, never>- Requirement
- required
- Name
store- Kind
- property
- Type
any- Requirement
- required
GrDropdownMenuTrigger
classexport declare class GrDropdownMenuTrigger implements OnDestroy { private readonly store; private readonly elementRef; private readonly listeners; private readonly consumerProps; constructor(); ngOnDestroy(): void; static ɵfac: i0.ɵɵFactoryDeclaration<GrDropdownMenuTrigger, never>; static ɵdir: i0.ɵɵDirectiveDeclaration<GrDropdownMenuTrigger, "[grDropdownMenuTrigger]", never, {}, {}, never, never, true, never>;}consumerPropsanyelementRefanylistenersanyngOnDestroy() => voidɵdiri0.ɵɵDirectiveDeclaration<GrDropdownMenuTrigger, "[grDropdownMenuTrigger]", never, {}, {}, never, never, true, never>ɵfaci0.ɵɵFactoryDeclaration<GrDropdownMenuTrigger, never>storeany- Name
consumerProps- Kind
- property
- Type
any- Requirement
- required
- Name
elementRef- Kind
- property
- Type
any- Requirement
- required
- Name
listeners- Kind
- property
- Type
any- Requirement
- required
- Name
ngOnDestroy- Kind
- method
- Type
() => void- Requirement
- required
- Name
ɵdir- Kind
- property
- Type
i0.ɵɵDirectiveDeclaration<GrDropdownMenuTrigger, "[grDropdownMenuTrigger]", never, {}, {}, never, never, true, never>- Requirement
- required
- Name
ɵfac- Kind
- property
- Type
i0.ɵɵFactoryDeclaration<GrDropdownMenuTrigger, never>- Requirement
- required
- Name
store- Kind
- property
- Type
any- Requirement
- required
@grassroot/ui-headless-svelte/dropdown-menu
Svelte adapter
packages/ui-headless/svelte/src/dropdown-menu/index.ts
createDropdownMenu
functionexport declare function createDropdownMenu(inputGetter: () => DropdownMenuInput, options?: UseDropdownMenuOptions): UseDropdownMenuResult;inputGetter() => DropdownMenuInputoptionsUseDropdownMenuOptionsreturnUseDropdownMenuResult- Name
inputGetter- Kind
- parameter
- Type
() => DropdownMenuInput- Requirement
- required
- Name
options- Kind
- parameter
- Type
UseDropdownMenuOptions- Requirement
- optional
- Name
return- Kind
- return value
- Type
UseDropdownMenuResult- Requirement
- n/a
type DropdownMenuChangeReason = DropdownMenuOpenReason | DropdownMenuCloseReason;type DropdownMenuCloseReason = "escape" | "outside-click" | "select" | "programmatic";DropdownMenuCommand
typetype DropdownMenuCommand = (CommandObject & { readonly type: "OPEN_CHANGE_REQUEST"; readonly open: boolean; readonly reason: DropdownMenuChangeReason;}) | (CommandObject & { readonly type: "SELECT_ITEM"; readonly id: string;}) | ScheduleCommand<DropdownMenuEvent> | CancelCommand;DropdownMenuContent
valueexport declare const DropdownMenuContent: LegacyComponentType;argsParameters<Component<Record<string, any>>>returnReturnType<Component<Record<string, any>, Record<string, any>>>- Name
args- Kind
- parameter
- Type
Parameters<Component<Record<string, any>>>- Requirement
- optional
- Name
return- Kind
- return value
- Type
ReturnType<Component<Record<string, any>, Record<string, any>>>- Requirement
- n/a
DropdownMenuContext
typetype DropdownMenuContext = MenuContext;DropdownMenuContextValue
interfaceexport interface DropdownMenuContextValue { readonly service: DropdownMenuService; readonly connector: DropdownMenuApi; readonly scope: PartScope; /** * Bumped on every committed machine update. Parts must read this * (`ctx.version()`) *inside* the `$derived` that computes their prop * bag — not once at setup — so Svelte's fine-grained reactivity tracks * the dependency and recomputes on every committed change (mirrors the * Dialog/Tooltip adapters' equivalent staleness fix; see * `../dialog/context.ts`). */ readonly version: () => number;}connectorDropdownMenuApiscopePartScopeserviceDropdownMenuServiceversion() => number- Name
connector- Kind
- property
- Type
DropdownMenuApi- Requirement
- required
- Description
- —
- Name
scope- Kind
- property
- Type
PartScope- Requirement
- required
- Description
- —
- Name
service- Kind
- property
- Type
DropdownMenuService- Requirement
- required
- Description
- —
- Name
version- Kind
- property
- Type
() => number- Requirement
- required
- Description
- Bumped on every committed machine update. Parts must read this (`ctx.version()`) *inside* the `$derived` that computes their prop bag — not once at setup — so Svelte's fine-grained reactivity tracks the dependency and recomputes on every committed change (mirrors the Dialog/Tooltip adapters' equivalent staleness fix; see `../dialog/context.ts`).
DropdownMenuEvent
typetype DropdownMenuEvent = { readonly type: "TOGGLE"; readonly reason: "trigger";} | { readonly type: "OPEN"; readonly reason: DropdownMenuOpenReason; readonly highlight?: "first" | "last";} | { readonly type: "CLOSE"; readonly reason: DropdownMenuCloseReason;} | { readonly type: "MOVE"; readonly direction: -1 | 1;} | { readonly type: "HIGHLIGHT"; readonly index: number;} | { readonly type: "HOME";} | { readonly type: "END";} | { readonly type: "SELECT";} | { readonly type: "TYPEAHEAD"; readonly char: string;};DropdownMenuGroupLabel
valueexport declare const DropdownMenuGroupLabel: LegacyComponentType;argsParameters<Component<Record<string, any>>>returnReturnType<Component<Record<string, any>, Record<string, any>>>- Name
args- Kind
- parameter
- Type
Parameters<Component<Record<string, any>>>- Requirement
- optional
- Name
return- Kind
- return value
- Type
ReturnType<Component<Record<string, any>, Record<string, any>>>- Requirement
- n/a
DropdownMenuInput
typetype DropdownMenuInput = { readonly open?: boolean; readonly defaultOpen?: boolean; readonly items: readonly DropdownMenuItem[]; readonly typeaheadTimeoutMs?: number;};defaultOpenbooleanitemsreadonly DropdownMenuItem[]openbooleantypeaheadTimeoutMsnumber- Name
defaultOpen- Kind
- property
- Type
boolean- Requirement
- optional
- Name
items- Kind
- property
- Type
readonly DropdownMenuItem[]- Requirement
- required
- Name
open- Kind
- property
- Type
boolean- Requirement
- optional
- Name
typeaheadTimeoutMs- Kind
- property
- Type
number- Requirement
- optional
DropdownMenuItem
valueexport declare const DropdownMenuItem: LegacyComponentType;argsParameters<Component<Record<string, any>>>returnReturnType<Component<Record<string, any>, Record<string, any>>>- Name
args- Kind
- parameter
- Type
Parameters<Component<Record<string, any>>>- Requirement
- optional
- Name
return- Kind
- return value
- Type
ReturnType<Component<Record<string, any>, Record<string, any>>>- Requirement
- n/a
DropdownMenuItemModel
interfaceinterface DropdownMenuItem { readonly id: string; readonly disabled?: boolean; readonly textValue?: string;}disabledbooleanidstringtextValuestring- Name
disabled- Kind
- property
- Type
boolean- Requirement
- optional
- Name
id- Kind
- property
- Type
string- Requirement
- required
- Name
textValue- Kind
- property
- Type
string- Requirement
- optional
DropdownMenuMachine
typetype DropdownMenuMachine = Machine<DropdownMenuInput, DropdownMenuStateValue, DropdownMenuContext, DropdownMenuEvent, DropdownMenuCommand>;DropdownMenuOpenChangeDetail
interfaceexport interface DropdownMenuOpenChangeDetail { readonly open: boolean; readonly reason: DropdownMenuChangeReason;}openbooleanreasonDropdownMenuChangeReason- Name
open- Kind
- property
- Type
boolean- Requirement
- required
- Name
reason- Kind
- property
- Type
DropdownMenuChangeReason- Requirement
- required
type DropdownMenuOpenReason = "trigger" | "programmatic";DropdownMenuPositioner
valueexport declare const DropdownMenuPositioner: LegacyComponentType;argsParameters<Component<Record<string, any>>>returnReturnType<Component<Record<string, any>, Record<string, any>>>- Name
args- Kind
- parameter
- Type
Parameters<Component<Record<string, any>>>- Requirement
- optional
- Name
return- Kind
- return value
- Type
ReturnType<Component<Record<string, any>, Record<string, any>>>- Requirement
- n/a
DropdownMenuRoot
valueexport declare const DropdownMenuRoot: LegacyComponentType;argsParameters<Component<Record<string, any>>>returnReturnType<Component<Record<string, any>, Record<string, any>>>- Name
args- Kind
- parameter
- Type
Parameters<Component<Record<string, any>>>- Requirement
- optional
- Name
return- Kind
- return value
- Type
ReturnType<Component<Record<string, any>, Record<string, any>>>- Requirement
- n/a
DropdownMenuSeparator
valueexport declare const DropdownMenuSeparator: LegacyComponentType;argsParameters<Component<Record<string, any>>>returnReturnType<Component<Record<string, any>, Record<string, any>>>- Name
args- Kind
- parameter
- Type
Parameters<Component<Record<string, any>>>- Requirement
- optional
- Name
return- Kind
- return value
- Type
ReturnType<Component<Record<string, any>, Record<string, any>>>- Requirement
- n/a
DropdownMenuSnapshot
typetype DropdownMenuSnapshot = Snapshot<DropdownMenuStateValue, DropdownMenuContext>;type DropdownMenuStateValue = "open" | "closed";DropdownMenuTrigger
valueexport declare const DropdownMenuTrigger: LegacyComponentType;argsParameters<Component<Record<string, any>>>returnReturnType<Component<Record<string, any>, Record<string, any>>>- Name
args- Kind
- parameter
- Type
Parameters<Component<Record<string, any>>>- Requirement
- optional
- Name
return- Kind
- return value
- Type
ReturnType<Component<Record<string, any>, Record<string, any>>>- Requirement
- n/a
useDropdownMenuContext
functionexport declare function useDropdownMenuContext(partName: string): DropdownMenuContextValue;partNamestringreturnDropdownMenuContextValue- Name
partName- Kind
- parameter
- Type
string- Requirement
- required
- Name
return- Kind
- return value
- Type
DropdownMenuContextValue- Requirement
- n/a
UseDropdownMenuOptions
interfaceexport interface UseDropdownMenuOptions { readonly onOpenChange?: (detail: DropdownMenuOpenChangeDetail) => void; readonly onSelect?: (id: string) => void; readonly align?: "start" | "end"; readonly scheduler?: Scheduler;}align"start" | "end"onOpenChange(detail: DropdownMenuOpenChangeDetail) => voidonSelect(id: string) => voidschedulerScheduler- Name
align- Kind
- property
- Type
"start" | "end"- Requirement
- optional
- Name
onOpenChange- Kind
- property
- Type
(detail: DropdownMenuOpenChangeDetail) => void- Requirement
- optional
- Name
onSelect- Kind
- property
- Type
(id: string) => void- Requirement
- optional
- Name
scheduler- Kind
- property
- Type
Scheduler- Requirement
- optional
UseDropdownMenuResult
interfaceexport interface UseDropdownMenuResult { readonly service: DropdownMenuService; readonly connector: DropdownMenuApi; readonly scope: PartScope; readonly version: () => number;}connectorDropdownMenuApiscopePartScopeserviceDropdownMenuServiceversion() => number- Name
connector- Kind
- property
- Type
DropdownMenuApi- Requirement
- required
- Name
scope- Kind
- property
- Type
PartScope- Requirement
- required
- Name
service- Kind
- property
- Type
DropdownMenuService- Requirement
- required
- Name
version- Kind
- property
- Type
() => number- Requirement
- required
@grassroot/ui-headless-solid/dropdown-menu
Solid adapter
packages/ui-headless/solid/src/dropdown-menu/index.ts
DropdownMenuContentProps
interfaceexport interface DropdownMenuContentProps extends JSX.HTMLAttributes<HTMLDivElement> { readonly as?: AsProp;}asAsProp- Name
as- Kind
- property
- Type
AsProp- Requirement
- optional
DropdownMenuContext
valueexport declare const DropdownMenuContext: import("solid-js").Context<DropdownMenuContextValue | undefined>;DropdownMenuContextValue
interfaceexport interface DropdownMenuContextValue { readonly service: DropdownMenuService; readonly connector: DropdownMenuApi; readonly scope: PartScope; /** * Bumped on every committed machine update. Parts must call this * accessor *inside* the JSX/spread thunk that reads the connector's prop * bags — not once at setup — so Solid's fine-grained reactivity tracks * the dependency and re-runs on every committed change. */ readonly snapshot: Accessor<DropdownMenuSnapshot>;}connectorDropdownMenuApiscopePartScopeserviceDropdownMenuServicesnapshotAccessor<DropdownMenuSnapshot>- Name
connector- Kind
- property
- Type
DropdownMenuApi- Requirement
- required
- Description
- —
- Name
scope- Kind
- property
- Type
PartScope- Requirement
- required
- Description
- —
- Name
service- Kind
- property
- Type
DropdownMenuService- Requirement
- required
- Description
- —
- Name
snapshot- Kind
- property
- Type
Accessor<DropdownMenuSnapshot>- Requirement
- required
- Description
- Bumped on every committed machine update. Parts must call this accessor *inside* the JSX/spread thunk that reads the connector's prop bags — not once at setup — so Solid's fine-grained reactivity tracks the dependency and re-runs on every committed change.
DropdownMenuGroupLabelProps
interfaceexport interface DropdownMenuGroupLabelProps extends JSX.HTMLAttributes<HTMLDivElement> { readonly as?: AsProp;}asAsProp- Name
as- Kind
- property
- Type
AsProp- Requirement
- optional
DropdownMenuItemProps
interfaceexport interface DropdownMenuItemProps extends JSX.HTMLAttributes<HTMLDivElement> { readonly as?: AsProp; /** The machine item this row represents — id/disabled/textValue map * straight through to the connector's item model. */ readonly item: DropdownMenuItem;}asAsPropitemDropdownMenuItem- Name
as- Kind
- property
- Type
AsProp- Requirement
- optional
- Description
- —
- Name
item- Kind
- property
- Type
DropdownMenuItem- Requirement
- required
- Description
- The machine item this row represents — id/disabled/textValue map straight through to the connector's item model.
DropdownMenuOpenChangeDetail
interfaceexport interface DropdownMenuOpenChangeDetail { readonly open: boolean; readonly reason: DropdownMenuChangeReason;}openbooleanreasonDropdownMenuChangeReason- Name
open- Kind
- property
- Type
boolean- Requirement
- required
- Name
reason- Kind
- property
- Type
DropdownMenuChangeReason- Requirement
- required
DropdownMenuPositionerProps
interfaceexport interface DropdownMenuPositionerProps extends JSX.HTMLAttributes<HTMLDivElement> { readonly as?: AsProp;}asAsProp- Name
as- Kind
- property
- Type
AsProp- Requirement
- optional
DropdownMenuRootProps
interfaceexport interface DropdownMenuRootProps { readonly open?: DropdownMenuInput["open"]; readonly defaultOpen?: DropdownMenuInput["defaultOpen"]; readonly items: DropdownMenuInput["items"]; readonly typeaheadTimeoutMs?: DropdownMenuInput["typeaheadTimeoutMs"]; /** Static positioning hint carried as `data-align` on the positioner. Default "start". */ readonly align?: UseDropdownMenuOptions["align"]; readonly onOpenChange?: (detail: DropdownMenuOpenChangeDetail) => void; readonly onSelect?: (id: string) => void; /** Native (production) by default; inject a virtual scheduler for tests. */ readonly scheduler?: UseDropdownMenuOptions["scheduler"]; readonly children?: JSX.Element;}alignUseDropdownMenuOptions["align"]childrenJSX.ElementdefaultOpenDropdownMenuInput["defaultOpen"]itemsDropdownMenuInput["items"]onOpenChange(detail: DropdownMenuOpenChangeDetail) => voidonSelect(id: string) => voidopenDropdownMenuInput["open"]schedulerUseDropdownMenuOptions["scheduler"]typeaheadTimeoutMsDropdownMenuInput["typeaheadTimeoutMs"]- Name
align- Kind
- property
- Type
UseDropdownMenuOptions["align"]- Requirement
- optional
- Description
- Static positioning hint carried as `data-align` on the positioner. Default "start".
- Name
children- Kind
- property
- Type
JSX.Element- Requirement
- optional
- Description
- —
- Name
defaultOpen- Kind
- property
- Type
DropdownMenuInput["defaultOpen"]- Requirement
- optional
- Description
- —
- Name
items- Kind
- property
- Type
DropdownMenuInput["items"]- Requirement
- required
- Description
- —
- Name
onOpenChange- Kind
- property
- Type
(detail: DropdownMenuOpenChangeDetail) => void- Requirement
- optional
- Description
- —
- Name
onSelect- Kind
- property
- Type
(id: string) => void- Requirement
- optional
- Description
- —
- Name
open- Kind
- property
- Type
DropdownMenuInput["open"]- Requirement
- optional
- Description
- —
- Name
scheduler- Kind
- property
- Type
UseDropdownMenuOptions["scheduler"]- Requirement
- optional
- Description
- Native (production) by default; inject a virtual scheduler for tests.
- Name
typeaheadTimeoutMs- Kind
- property
- Type
DropdownMenuInput["typeaheadTimeoutMs"]- Requirement
- optional
- Description
- —
DropdownMenuSeparatorProps
interfaceexport interface DropdownMenuSeparatorProps extends JSX.HTMLAttributes<HTMLHRElement> { readonly as?: AsProp;}asAsProp- Name
as- Kind
- property
- Type
AsProp- Requirement
- optional
DropdownMenuTriggerProps
interfaceexport interface DropdownMenuTriggerProps extends Omit<JSX.ButtonHTMLAttributes<HTMLButtonElement>, "type"> { readonly as?: AsProp;}asAsProp- Name
as- Kind
- property
- Type
AsProp- Requirement
- optional
MenuContent
functionexport declare function MenuContent(props: DropdownMenuContentProps): JSX.Element;propsDropdownMenuContentPropsreturnJSX.Element- Name
props- Kind
- parameter
- Type
DropdownMenuContentProps- Requirement
- required
- Name
return- Kind
- return value
- Type
JSX.Element- Requirement
- n/a
MenuGroupLabel
functionexport declare function MenuGroupLabel(props: DropdownMenuGroupLabelProps): JSX.Element;propsDropdownMenuGroupLabelPropsreturnJSX.Element- Name
props- Kind
- parameter
- Type
DropdownMenuGroupLabelProps- Requirement
- required
- Name
return- Kind
- return value
- Type
JSX.Element- Requirement
- n/a
MenuItem
functionexport declare function MenuItem(props: DropdownMenuItemProps): JSX.Element;propsDropdownMenuItemPropsreturnJSX.Element- Name
props- Kind
- parameter
- Type
DropdownMenuItemProps- Requirement
- required
- Name
return- Kind
- return value
- Type
JSX.Element- Requirement
- n/a
MenuPositioner
functionexport declare function MenuPositioner(props: DropdownMenuPositionerProps): JSX.Element;propsDropdownMenuPositionerPropsreturnJSX.Element- Name
props- Kind
- parameter
- Type
DropdownMenuPositionerProps- Requirement
- required
- Name
return- Kind
- return value
- Type
JSX.Element- Requirement
- n/a
MenuRoot
functionexport declare function MenuRoot(props: DropdownMenuRootProps): JSX.Element;propsDropdownMenuRootPropsreturnJSX.Element- Name
props- Kind
- parameter
- Type
DropdownMenuRootProps- Requirement
- required
- Name
return- Kind
- return value
- Type
JSX.Element- Requirement
- n/a
MenuSeparator
functionexport declare function MenuSeparator(props: DropdownMenuSeparatorProps): JSX.Element;propsDropdownMenuSeparatorPropsreturnJSX.Element- Name
props- Kind
- parameter
- Type
DropdownMenuSeparatorProps- Requirement
- required
- Name
return- Kind
- return value
- Type
JSX.Element- Requirement
- n/a
MenuTrigger
functionexport declare function MenuTrigger(props: DropdownMenuTriggerProps): JSX.Element;propsDropdownMenuTriggerPropsreturnJSX.Element- Name
props- Kind
- parameter
- Type
DropdownMenuTriggerProps- Requirement
- required
- Name
return- Kind
- return value
- Type
JSX.Element- Requirement
- n/a
useDropdownMenu
functionexport declare function useDropdownMenu(input: Accessor<DropdownMenuInput>, options?: UseDropdownMenuOptions): UseDropdownMenuResult;inputAccessor<DropdownMenuInput>optionsUseDropdownMenuOptionsreturnUseDropdownMenuResult- Name
input- Kind
- parameter
- Type
Accessor<DropdownMenuInput>- Requirement
- required
- Name
options- Kind
- parameter
- Type
UseDropdownMenuOptions- Requirement
- optional
- Name
return- Kind
- return value
- Type
UseDropdownMenuResult- Requirement
- n/a
useDropdownMenuContext
functionexport declare function useDropdownMenuContext(partName: string): DropdownMenuContextValue;partNamestringreturnDropdownMenuContextValue- Name
partName- Kind
- parameter
- Type
string- Requirement
- required
- Name
return- Kind
- return value
- Type
DropdownMenuContextValue- Requirement
- n/a
UseDropdownMenuOptions
interfaceexport interface UseDropdownMenuOptions { readonly onOpenChange?: (detail: DropdownMenuOpenChangeDetail) => void; readonly onSelect?: (id: string) => void; readonly align?: "start" | "end"; readonly scheduler?: Scheduler;}align"start" | "end"onOpenChange(detail: DropdownMenuOpenChangeDetail) => voidonSelect(id: string) => voidschedulerScheduler- Name
align- Kind
- property
- Type
"start" | "end"- Requirement
- optional
- Name
onOpenChange- Kind
- property
- Type
(detail: DropdownMenuOpenChangeDetail) => void- Requirement
- optional
- Name
onSelect- Kind
- property
- Type
(id: string) => void- Requirement
- optional
- Name
scheduler- Kind
- property
- Type
Scheduler- Requirement
- optional
UseDropdownMenuResult
interfaceexport interface UseDropdownMenuResult { readonly service: DropdownMenuService; readonly connector: DropdownMenuApi; readonly scope: PartScope; readonly snapshot: Accessor<DropdownMenuSnapshot>;}connectorDropdownMenuApiscopePartScopeserviceDropdownMenuServicesnapshotAccessor<DropdownMenuSnapshot>- Name
connector- Kind
- property
- Type
DropdownMenuApi- Requirement
- required
- Name
scope- Kind
- property
- Type
PartScope- Requirement
- required
- Name
service- Kind
- property
- Type
DropdownMenuService- Requirement
- required
- Name
snapshot- Kind
- property
- Type
Accessor<DropdownMenuSnapshot>- Requirement
- required