UNPKG

@bnnvara/hub

Version:

A fixed toolbar on top of a page

35 lines (27 loc) 825 B
## HUB Implements a toolbar like component that can be placed on top of the page and can hold some navigation controls and buttons. ### Examples The component takes the following optional properties: | name | type | description | |---|---|---| | children | React.Children | a collection of elements that will be placed on the left hand side of the component | | actions | [ React.Node ] | an array of elements that will be placed on the right hand side of the component | ###code ``` import React from 'react'; import Hub from '@bnnvara/hub'; import { Close, Search, Logo, Settings } from '@bnnvara/icons' export default const () => ( <Hub actions={[ <Settings key="settings" />, <Search key="search" />, <Close key="close" />, ]} > <Logo/> </Hub> ) ```