SpeedDial API

API documentation for SpeedDial component

SpeedDialRoot#

Props#

Defines valid properties in SpeedDial component.

nametypedefaultdescription
refRef<unknown>
null
The reference to the component instance.
pIfboolean
true
Whether the component should be rendered.
styleCSSProperties | ((instance?: SpeedDialRootInstance) => CSSProperties)
null
The style to apply to the component.
classNamestring | ((instance?: SpeedDialRootInstance) => string)
null
The class name to apply to the component.
asstring | number | bigint | boolean | ComponentClass<any, any> | FunctionComponent<any> | ReactElement<unknown, string | JSXElementConstructor<any>> | Iterable<ReactNode, any, any> | ReactPortal | Promise<AwaitedReactNode>
null
The component type to render.
asChildboolean
false
Whether the component should be rendered as a child component.
ptSafeRecord<SpeedDialRootPassThrough>
null
The pass-through props to pass to the component
ptOptionsPassThroughOptions
null
The pass-through options to pass to the component
unstyledboolean
null
Whether the component should be rendered without classes.
dtunknown
null
The design token to use for the component.
stylesStylesOptions<ComponentInstance>
null
The styles to use for the component.
childrenReactNode | ((instance: SpeedDialRootInstance) => ReactNode)
null
The children to render.
disabledboolean
false
Whether the component is disabled.
onVisibleChange(event: SpeedDialRootVisibleChangeEvent) => void
null
Callback fired when the speeddial's visibility changes.
visibleboolean
null
Whether the speeddial is visible or not.
defaultVisibleboolean
null
Whether the speeddial is visible or not.
direction"right" | "left" | "up" | "down" | "up-left" | "up-right" | "down-left" | "down-right"
up
Specifies the opening direction of actions.
transitionDelaynumber
30
Transition delay step for each action item.
type"circle" | "linear" | "semi-circle" | "quarter-circle"
linear
Specifies the opening type of actions.
radiusnumber
0
Radius for *circle types.
hideOnClickOutsideboolean
true
Whether the actions close when clicked outside.
[key: string]any
null
pt-{optionName}-*-
null
Pass through attributes for customizing component. For more info, see Pass Through tab.

State#

Defines valid state in SpeedDial component.

nametypedefaultdescription
visibleboolean
null
Visible state of the component.
focusedOptionIndexstring | number
null
Current focused option index.

Exposes#

Defines the methods and properties exposed by SpeedDial component.

nametypedefaultdescription
stateuseSpeedDialState
null
The state of the useSpeedDial.
listRefRefObject<HTMLUListElement>
null
Reference to the currently list element.
registerItem() => number
null
Registers a new item and returns its index.
getItemStyle(index: number) => CSSProperties
null
Handler for item's style
onBlur(event: FocusEvent<HTMLElement>) => void
null
Handler for blur event.
onKeyDown(event: KeyboardEvent) => void
null
Handler for keydown events.
onTriggerClick() => void
null
Handler for click event.
onTriggerKeyDown(event: KeyboardEvent) => void
null
Handler for keydown events on toggler.
onItemClick(e: KeyboardEvent<Element> | MouseEvent<Element, MouseEvent>) => void
null
Handler for click event on items.
onItemKeyDown(e: KeyboardEvent) => void
null
Handler for keydown event on items.

Interfaces#

Defines passthrough(pt) options of SpeedDial component.

nametypedefaultdescription
rootSpeedDialRootPassThroughType<HTMLAttributes<HTMLDivElement>>
null
Used to pass attributes to the root's DOM element.
buttonSpeedDialRootPassThroughType<HTMLAttributes<HTMLButtonElement>>
null
Used to pass attributes to the button's DOM element.
listSpeedDialRootPassThroughType<HTMLAttributes<HTMLUListElement>>
null
Used to pass attributes to the list's DOM element.
itemSpeedDialRootPassThroughType<HTMLAttributes<HTMLLIElement>>
null
Used to pass attributes to the item's DOM element.
actionSpeedDialRootPassThroughType<HTMLAttributes<HTMLButtonElement>>
null
Used to pass attributes to the action's DOM element.

Types#

Instance of SpeedDial component.

values
ComponentInstance<SpeedDialRootProps, SpeedDialRootState, SpeedDialRootExposes>

SpeedDialTrigger#

Props#

Defines valid properties in SpeedDialTrigger component.

nametypedefaultdescription
refRef<unknown>
null
The reference to the component instance.
pIfboolean
true
Whether the component should be rendered.
styleCSSProperties | ((instance?: SpeedDialTriggerInstance) => CSSProperties)
null
The style to apply to the component.
classNamestring | ((instance?: SpeedDialTriggerInstance) => string)
null
The class name to apply to the component.
asstring | number | bigint | boolean | ComponentClass<any, any> | FunctionComponent<any> | ReactElement<unknown, string | JSXElementConstructor<any>> | Iterable<ReactNode, any, any> | ReactPortal | Promise<AwaitedReactNode>
null
The component type to render.
asChildboolean
false
Whether the component should be rendered as a child component.
ptSafeRecord<SpeedDialTriggerPassThrough>
null
The pass-through props to pass to the component
ptOptionsPassThroughOptions
null
The pass-through options to pass to the component
unstyledboolean
null
Whether the component should be rendered without classes.
dtunknown
null
The design token to use for the component.
stylesStylesOptions<ComponentInstance>
null
The styles to use for the component.
childrenReactNode | ((instance: SpeedDialTriggerInstance) => ReactNode)
null
The children to render.
iconOnlyboolean
true
Whether to show the SpeedDialTrigger with a borderless style.
roundedboolean
true
Whether to show the SpeedDialTrigger with a rounded style.
[key: string]any
null
pt-{optionName}-*-
null
Pass through attributes for customizing component. For more info, see Pass Through tab.

Exposes#

Defines the methods and properties exposed by SpeedDialTrigger component.

nametypedefaultdescription
speeddialSpeedDialRootInstance
null
Instance of the SpeedDial component.

Interfaces#

Defines passthrough(pt) options of SpeedDialTrigger component.

nametypedefaultdescription
rootSpeedDialTriggerPassThroughType<HTMLAttributes<HTMLButtonElement>>
null
Used to pass attributes to the root's DOM element.

Types#

Instance of SpeedDialTrigger component.

values
ComponentInstance<SpeedDialTriggerProps, SpeedDialTriggerState, SpeedDialTriggerExposes>

SpeedDialList#

Props#

Defines valid properties in SpeedDialList component.

nametypedefaultdescription
refRef<unknown>
null
The reference to the component instance.
pIfboolean
true
Whether the component should be rendered.
styleCSSProperties | ((instance?: SpeedDialListInstance) => CSSProperties)
null
The style to apply to the component.
classNamestring | ((instance?: SpeedDialListInstance) => string)
null
The class name to apply to the component.
asstring | number | bigint | boolean | ComponentClass<any, any> | FunctionComponent<any> | ReactElement<unknown, string | JSXElementConstructor<any>> | Iterable<ReactNode, any, any> | ReactPortal | Promise<AwaitedReactNode>
null
The component type to render.
asChildboolean
false
Whether the component should be rendered as a child component.
ptSafeRecord<SpeedDialListPassThrough>
null
The pass-through props to pass to the component
ptOptionsPassThroughOptions
null
The pass-through options to pass to the component
unstyledboolean
null
Whether the component should be rendered without classes.
dtunknown
null
The design token to use for the component.
stylesStylesOptions<ComponentInstance>
null
The styles to use for the component.
childrenReactNode | ((instance: SpeedDialListInstance) => ReactNode)
null
The children to render.
[key: string]any
null
pt-{optionName}-*-
null
Pass through attributes for customizing component. For more info, see Pass Through tab.

Exposes#

Defines the methods and properties exposed by SpeedDialList component.

nametypedefaultdescription
speeddialSpeedDialRootInstance
null
Instance of the SpeedDial component.

Interfaces#

Defines passthrough(pt) options of SpeedDialList component.

nametypedefaultdescription
rootSpeedDialListPassThroughType<HTMLAttributes<HTMLUListElement>>
null
Used to pass attributes to the root's DOM element.

Types#

Instance of SpeedDialList component.

values
ComponentInstance<SpeedDialListProps, SpeedDialListState, SpeedDialListExposes>

SpeedDialItem#

Props#

Defines valid properties in SpeedDialItem component.

nametypedefaultdescription
refRef<unknown>
null
The reference to the component instance.
pIfboolean
true
Whether the component should be rendered.
styleCSSProperties | ((instance?: SpeedDialItemInstance) => CSSProperties)
null
The style to apply to the component.
classNamestring | ((instance?: SpeedDialItemInstance) => string)
null
The class name to apply to the component.
asstring | number | bigint | boolean | ComponentClass<any, any> | FunctionComponent<any> | ReactElement<unknown, string | JSXElementConstructor<any>> | Iterable<ReactNode, any, any> | ReactPortal | Promise<AwaitedReactNode>
null
The component type to render.
asChildboolean
false
Whether the component should be rendered as a child component.
ptSafeRecord<SpeedDialItemPassThrough>
null
The pass-through props to pass to the component
ptOptionsPassThroughOptions
null
The pass-through options to pass to the component
unstyledboolean
null
Whether the component should be rendered without classes.
dtunknown
null
The design token to use for the component.
stylesStylesOptions<ComponentInstance>
null
The styles to use for the component.
childrenReactNode | ((instance: SpeedDialItemInstance) => ReactNode)
null
The children to render.
[key: string]any
null
pt-{optionName}-*-
null
Pass through attributes for customizing component. For more info, see Pass Through tab.

Exposes#

Defines the methods and properties exposed by SpeedDialItem component.

nametypedefaultdescription
speeddialSpeedDialRootInstance
null
Instance of the SpeedDial component.

Interfaces#

Defines passthrough(pt) options of SpeedDialItem component.

nametypedefaultdescription
rootSpeedDialItemPassThroughType<HTMLAttributes<HTMLLIElement>>
null
Used to pass attributes to the root's DOM element.

Types#

Instance of SpeedDialItem component.

values
ComponentInstance<SpeedDialItemProps, SpeedDialItemState, SpeedDialItemExposes>

SpeedDialAction#

Props#

Defines valid properties in SpeedDialAction component.

nametypedefaultdescription
refRef<unknown>
null
The reference to the component instance.
pIfboolean
true
Whether the component should be rendered.
styleCSSProperties | ((instance?: SpeedDialActionInstance) => CSSProperties)
null
The style to apply to the component.
classNamestring | ((instance?: SpeedDialActionInstance) => string)
null
The class name to apply to the component.
asstring | number | bigint | boolean | ComponentClass<any, any> | FunctionComponent<any> | ReactElement<unknown, string | JSXElementConstructor<any>> | Iterable<ReactNode, any, any> | ReactPortal | Promise<AwaitedReactNode>
null
The component type to render.
asChildboolean
false
Whether the component should be rendered as a child component.
ptSafeRecord<SpeedDialActionPassThrough>
null
The pass-through props to pass to the component
ptOptionsPassThroughOptions
null
The pass-through options to pass to the component
unstyledboolean
null
Whether the component should be rendered without classes.
dtunknown
null
The design token to use for the component.
stylesStylesOptions<ComponentInstance>
null
The styles to use for the component.
childrenReactNode | ((instance: SpeedDialActionInstance) => ReactNode)
null
The children to render.
iconOnlyboolean
true
Whether to show the SpeedDialAction with a borderless style.
severitystring & {} | "secondary" | "info" | "success" | "warn" | "danger" | "contrast" | "help"
'secondary'
Severity type of the SpeedDialAction.
roundedboolean
true
Whether to show the SpeedDialAction with a rounded style.
size"small" | "large"
'small'
Size of the Button.
[key: string]any
null
pt-{optionName}-*-
null
Pass through attributes for customizing component. For more info, see Pass Through tab.

Exposes#

Defines the methods and properties exposed by SpeedDialAction component.

nametypedefaultdescription
speeddialSpeedDialRootInstance
null
Instance of the SpeedDial component.

Interfaces#

Defines passthrough(pt) options of SpeedDialAction component.

nametypedefaultdescription
rootSpeedDialActionPassThroughType<HTMLAttributes<HTMLButtonElement>>
null
Used to pass attributes to the root's DOM element.

Types#

Instance of SpeedDialAction component.

values
ComponentInstance<SpeedDialActionProps, SpeedDialActionState, SpeedDialActionExposes>

useSpeedDial#

Props#

Defines valid properties in useSpeedDial.

nametypedefaultdescription
visibleboolean
null
Whether the speeddial is visible or not.
defaultVisibleboolean
null
Whether the speeddial is visible or not.
direction"right" | "left" | "up" | "down" | "up-left" | "up-right" | "down-left" | "down-right"
up
Specifies the opening direction of actions.
transitionDelaynumber
30
Transition delay step for each action item.
type"circle" | "linear" | "semi-circle" | "quarter-circle"
linear
Specifies the opening type of actions.
radiusnumber
0
Radius for *circle types.
hideOnClickOutsideboolean
true
Whether the actions close when clicked outside.
onVisibleChange(event: useSpeedDialChangeEvent) => void
null
Callback fired when the speeddial's visibility changes.

State#

Defines valid state in useSpeedDial.

nametypedefaultdescription
visibleboolean
null
Visible state of the component.
focusedOptionIndexstring | number
null
Current focused option index.

Exposes#

Defines the methods and properties exposed by useSpeedDial.

nametypedefaultdescription
stateuseSpeedDialState
null
The state of the useSpeedDial.
listRefRefObject<HTMLUListElement>
null
Reference to the currently list element.
registerItem() => number
null
Registers a new item and returns its index.
getItemStyle(index: number) => CSSProperties
null
Handler for item's style
onBlur(event: FocusEvent<HTMLElement>) => void
null
Handler for blur event.
onKeyDown(event: KeyboardEvent) => void
null
Handler for keydown events.
onTriggerClick() => void
null
Handler for click event.
onTriggerKeyDown(event: KeyboardEvent) => void
null
Handler for keydown events on toggler.
onItemClick(e: KeyboardEvent<Element> | MouseEvent<Element, MouseEvent>) => void
null
Handler for click event on items.
onItemKeyDown(e: KeyboardEvent) => void
null
Handler for keydown event on items.

Events#

Event fired when the speeddial's visibility changes.

nametypedescription
valuebooleanThe value of the speeddial.

Types#

Instance of useSpeedDial headless.

values
HeadlessInstance<useSpeedDialProps, useSpeedDialState, useSpeedDialExposes>