Skip to content

SidebarProvider

Overview

Provider component that manages sidebar state and provides context to all child sidebar components.

Theme entry: SidebarProvider

Props

NameTypeRequiredDefaultDescription
themeOverrideString|Object|ArraynullA partial theme object merged with the component's default theme; accepts a class string, class array, or theme object.
classimport('vue').HTMLAttributes['class']undefinedAdditional CSS classes to apply to the root element.
defaultOpenboolean() => !defaultDocument?.cookie.includes(`${SIDEBAR_COOKIE_NAME}=false`)Whether the sidebar is open by default. Reads from cookie if available.
openbooleanundefinedControlled open state.

Slots

default

Slot.

Events

NameDescription
update:openEmitted when the open state changes.

Full event reference

Source

client/lib/navigation/sidebar/SidebarProvider.vue

Documents matching: server v3.0.0a1.post1client v3.0.0-alpha.2