Skip to content
↑↓ to navigate↵ to openesc to close

Menu

Expandable Action Bar

Preview

Install

Add it with your package manager, or copy the source manually.

Run it in a project set up with shadcn-vue. The source is copied to components/beui and its dependencies are added to your package.json. Read the shadcn-vue guide

bunx --bun shadcn-vue@latest add @beui-vue/expandable-action-bar

Import the shared styles once in your application.

TSUsage
import ExpandableActionBar from '@/components/beui/blocks/ExpandableActionBar.vue'
import '@/components/beui/styles.css'

API Reference

items
readonly BlockAction[]
Default—
v-model:expanded?
boolean
Defaultundefined
defaultExpanded?
boolean
Defaultfalse
activeId?
string
Default—
@action?
(item: BlockAction) => void
Default—
size?
ExpandableActionBarSize

Default `md`.

Defaultmd
expandOnHover?
boolean

Expand when a hovering pointer rests on the bar. It also governs the touch equivalent: with no hover to reveal the labels, the first tap expands the bar and runs no action, and the second one acts. Set false to make every tap and click act immediately.

Defaulttrue
expandOnFocus?
boolean
Defaulttrue
collapseDelay?
number
Default90
className?
string
Default—
classNames?
ExpandableActionBarClassNames
Default—
#renderItem?
{ item: BlockAction; expanded: boolean; active: boolean }

Alias of `item`, named after the React `renderItem` prop.

Default—
@expanded-change?
(value: boolean) => void
Default—
#icon?
{ item: BlockAction }

Replaces an action's icon.

Default—
#item?
{ item: BlockAction; expanded: boolean; active: boolean }

Replaces a whole action's contents (icon, label, shortcut and badge).

Default—

Updated