CustomToolbar

Custom Toolbar (which AdapTable will manage) enabling devs to populate Dashboard with bespoke content.

TypeScript
export interface CustomToolbar<TData extends

Properties

PropertyTypeDescription
frameworkComponentAdaptableFrameworkComponentThe Framework-specific (Angular, React or Vue) component to be rendered
namestringHow Toolbar is referenced (e.g. in Dashboard Popup when managing toolbars)
onToolbarFormChange(formData: TData, context:CustomToolbarFormContext<TData>) => voidCallback invoked whenever the user changes a value in the toolbar form
render(customRenderContext:CustomRenderContext) => string | nullFunction to provide custom content when NOT using a Framework wrapper
titlestringTitle to display in Toolbar; if unset or empty string, nothing will show
toolbarActionsToolbarActionsActions available in a Custom Dashboard Toolbar
toolbarButtonsAdaptableButton<CustomToolbarButtonContext>[]Optional set of buttons to show in the Toolbar
toolbarFormAdaptableForm<CustomToolbarFormContext<TData>, TData>Optional inline form to render in the Toolbar (e.g. selects, checkboxes, inputs).

Property Details

frameworkComponent

The Framework-specific (Angular, React or Vue) component to be rendered

TypeScript
frameworkComponent?: AdaptableFrameworkComponent;
Property Value

AdaptableFrameworkComponent

name

How Toolbar is referenced (e.g. in Dashboard Popup when managing toolbars)

TypeScript
name: string;
Property Value

string

onToolbarFormChange

Callback invoked whenever the user changes a value in the toolbar form

TypeScript
onToolbarFormChange?: (formData: TData, context: CustomToolbarFormContext<TData>) => void;
Property Value

(formData: TData, context:CustomToolbarFormContext<TData>) => void

render

Function to provide custom content when NOT using a Framework wrapper

TypeScript
render?: (customRenderContext: CustomRenderContext) => string | null;
Property Value

(customRenderContext:CustomRenderContext) => string | null

title

Title to display in Toolbar; if unset or empty string, nothing will show

TypeScript
title?: string;
Property Value

string

toolbarActions

Actions available in a Custom Dashboard Toolbar

TypeScript
toolbarActions?: ToolbarActions;
Property Value

ToolbarActions

toolbarButtons

Optional set of buttons to show in the Toolbar

TypeScript
toolbarButtons?: AdaptableButton<CustomToolbarButtonContext>[];
Property Value

AdaptableButton<CustomToolbarButtonContext>[]

toolbarForm

Optional inline form to render in the Toolbar (e.g. selects, checkboxes, inputs).

Use this when you want to expose interactive controls - rather than just buttons - in your Custom Toolbar without resorting to bespoke render or frameworkComponent content.

The form's fields are rendered side-by-side using the inline form layout. When the user changes any value the callback is invoked. Buttons declared on the form receive a which includes the current formData.

TypeScript
toolbarForm?: AdaptableForm<CustomToolbarFormContext<TData>, TData>;
Property Value

AdaptableForm<CustomToolbarFormContext<TData>, TData>