#Building Blocks
The components export holds buttons, selects, checkboxes and other controls
with the Adaptable look, for toolbars and panels that sit next to the grid. They
need an <Adaptable.Provider /> ancestor.
For the parts of the grid itself (the dashboard, the view picker, the settings panel and its pages), see UI.
import { components } from '@adaptabletools/datagrid-react';
const { Select, Button } = components;components contains:
Button—variant('text' | 'outlined' | 'contained'),tone,size('small' | 'medium' | 'large'),icon,tooltip,onClick, …Select— a dropdown; see below.CheckBoxIconLogoLayout— a flex container.TabsGridFilterInput— the grid filter editor of the current view, as shown in the dashboard.
The SelectProps and ButtonProps types are exported too.
#Using the Select component
Select needs three props:
options—{ label, value, disabled? }[]. Options can also be grouped ({ label, options }) or separated with'separator'.value— the selected value.onChange(value)— called when the user picks an option.
Optional props include size ('small' | 'medium'), placeholder, disabled,
label, className and style.