Documentation

@kanunilabs/datagrid-react


@kanunilabs/datagrid-react / GridToolbarButtonProps

Interface: GridToolbarButtonProps

Properties

disabledReason?

optional disabledReason?: string

Set while the button cannot be used: it reads as unavailable, ignores clicks, and the tooltip and screen reader give this reason.


icon

icon: ReactNode

The glyph, e.g. an inline SVG or <ToolbarIcon name="columns" />.


label

label: string

The button's name: its accessible name and the start of its tooltip.


onClick?

optional onClick?: () => void

Returns

void


shortcut?

optional shortcut?: string

Keyboard shortcut shown in the tooltip ("Export (Ctrl+E)") and as aria-keyshortcuts.


showLabel?

optional showLabel?: boolean

Show the label beside the icon. Default false (icon only).


testId?

optional testId?: string

data-testid on the button.