/** * * SidebarMenuItem component - part of the headless Sidebar compound component family. * * @module sidebarmenuitem * */ import type { DefineComponent, DesignToken, EmitFn, PassThrough } from '@primevue/core'; import type { ComponentHooks } from '@primevue/core/basecomponent'; import type { PassThroughOptions } from 'primevue/passthrough'; import { VNode } from 'vue'; export declare type SidebarMenuItemPassThroughOptionType = SidebarMenuItemPassThroughAttributes | ((options: SidebarMenuItemPassThroughMethodOptions) => SidebarMenuItemPassThroughAttributes | string) | string | null | undefined; /** * Custom passthrough(pt) option method. */ export interface SidebarMenuItemPassThroughMethodOptions { /** * Defines instance. */ instance: any; /** * Defines valid properties. */ props: SidebarMenuItemProps; /** * Defines current inline state. */ state: SidebarMenuItemState; /** * Defines valid attributes. */ attrs: any; /** * Defines parent options. */ parent: any; /** * Defines passthrough(pt) options in global config. */ global: object | undefined; } /** * Custom passthrough(pt) options. * @see {@link SidebarMenuItemProps.pt} */ export interface SidebarMenuItemPassThroughOptions { /** * Used to pass attributes to the root's DOM element. */ root?: SidebarMenuItemPassThroughOptionType; /** * Used to manage all lifecycle hooks. * @see {@link BaseComponent.ComponentHooks} */ hooks?: ComponentHooks; } /** * Custom passthrough attributes for each DOM elements. */ export interface SidebarMenuItemPassThroughAttributes { [key: string]: any; } /** * Defines current inline state in SidebarMenuItem component. */ export interface SidebarMenuItemState { /** * Current open state as a boolean. */ d_open: boolean; } /** * Defines valid properties in SidebarMenuItem component. */ export interface SidebarMenuItemProps { /** * Marks the item as collapsible. * @defaultValue false */ collapsible?: boolean; /** * Controlled open state for the collapsible content. */ open?: boolean; /** * Initial open state for uncontrolled usage. * @defaultValue true */ defaultOpen?: boolean; /** * Disables the item; toggle is a no-op. * @defaultValue false */ disabled?: boolean; /** * The element or component to render. Defaults to a sensible HTML element. */ as?: string | object; /** * When true, renders the slot content as the root element with merged props. * @defaultValue false */ asChild?: boolean; /** * It generates scoped CSS variables using design tokens for the component. */ dt?: DesignToken; /** * Used to pass attributes to DOM elements inside the component. * @type {SidebarMenuItemPassThroughOptions} */ pt?: PassThrough; /** * Used to configure passthrough(pt) options of the component. * @type {PassThroughOptions} */ ptOptions?: PassThroughOptions; /** * When enabled, it removes component related styles in the core. * @defaultValue false */ unstyled?: boolean; } /** * Defines valid slots in SidebarMenuItem component. */ export interface SidebarMenuItemSlots { /** * Default slot. * * The `scope` argument is only provided when `asChild` is `true`. In that mode the * consumer must spread `a11yAttrs` and apply `class` on the rendered root, and may * use `open` / `toggle` to drive a custom collapsible trigger. * @param {Object} scope - default slot's params. */ default(scope?: { /** * Class name of the root element. */ class: string; /** * Accessibility data attributes to spread on the rendered root. */ a11yAttrs: Record; /** * Current open state of the collapsible item. */ open: boolean; /** * Toggles the item's open state. No-op when `collapsible` is falsy or `disabled` is true. * @param {Event} [event] - Browser event. */ toggle: (event?: Event) => void; }): VNode[]; } /** * Defines valid emits in SidebarMenuItem component. */ export interface SidebarMenuItemEmitsOptions { /** * Emitted when the open state changes. * @param {boolean} value - New open state. */ 'update:open': (value: boolean) => void; } export declare type SidebarMenuItemEmits = EmitFn; /** * **PrimeVue - SidebarMenuItem** * * _SidebarMenuItem component - part of the headless Sidebar compound component family._ * * @group Component * */ declare const SidebarMenuItem: DefineComponent; declare module 'vue' { export interface GlobalComponents { SidebarMenuItem: DefineComponent; } } export default SidebarMenuItem;