#Workspace
<Adaptable.Workspace /> places a main pane beside the settings panel, with a
resizable split between them. By default the main pane is the full
Adaptable.UI (dashboard, grid and overlays) and the panel sits below it.
<Adaptable.Provider v-bind="props">
<Adaptable.Workspace settingsPanel="right" />
</Adaptable.Provider>#The settings panel
settingsPanel prop takes a position — 'left', 'right', 'top' or
'bottom' (default) — or a config object:
<Adaptable.Workspace
:settingsPanel="{
position: 'left',
defaultSize: 420,
minSize: 360,
defaultItemId: 'view-sorting',
}"
main="grid"
/>className— a class on the panel slot.defaultItemId— the settings page shown first (default'views').defaultSize— the initial panel size along the split (default 620 for a side panel, 360 for a stacked one).minSize(default 320) andmaxSizebound the resize. All three take pixels or a CSS length such as'30%','20rem'or'calc(100% - 600px)'; percentages are relative to the workspace.position— where the panel sits.leftandrightsplit horizontally,topandbottomstack vertically.renderCollapsed— what stays on the panel's edge while it is collapsed; see Collapsing.size/onSizeChange— control the size.onSizeChangeis called with the size in pixels once a resize is committed (pointer up, or a keyboard resize).
To replace the settings panel with your own content, use the settingsPanel
slot of the workspace (<template #settingsPanel>).
:settingsPanel="false" renders the main pane alone; the settings pages then
open in a dialog.
The panel sits below the grid and opens on the Sorting page. The main pane
is just the grid (main="grid"). Drag the gap between them to resize.
#Settings page ids
defaultItemId, Adaptable.UI.SettingsPanel's itemId and
adaptableApi.settingsPanelApi.showSettingsPanel(id) take one of these ids:
| Group | Pages |
|---|---|
| Grid | views, view-columns, view-sorting, view-grouping, view-aggregations, view-filter, view-selection |
| Data | calculated-columns, named-queries, export |
| Styling | styled-cells, flashing-cells, theme |
| Alerts & Messages | cell-notes, alerts |
| Search | quick-search |
| Layout | dashboard |
The view-* pages edit the current view. For a pivot view, view-columns
edits the pivot columns, view-grouping the row groups, and there is no
view-filter page.
#The main pane
main picks the built-in main pane: 'ui' (default) for the full
Adaptable.UI, or 'grid' for Adaptable.UI.DataGrid without the dashboard
(the overlays are still included). Use the default slot for your own layout
instead — any mix of the UI components or any other content. Unless it
contains Adaptable.UI, include <Adaptable.UI.Overlays /> once (for
notifications and cell notes).
#Collapsing
The panel collapses from the button in its header and expands from the strip left on its edge. While collapsed, the strip shows the expand button followed by an icon per settings page; clicking an icon expands the panel on that page.
:collapsible="false"keeps the panel always open.:showIconsWhenCollapsed="false"leaves only the expand button on the strip.settingsPanel.renderCollapsed, or thecollapsedslot of the workspace, replaces the strip's content. It receives{ position, orientation, expand, expandButton, items }:expand(itemId?)expands the panel (on a page, when given),expandButtonis the default button, as a component (<component :is="expandButton" />), anditemslists the settings pages (id,label,description,icon,group) in sidebar order; an item'siconis a component too. PassrenderCollapsed: falseto leave nothing on the edge and expand the panel from elsewhere.
The collapsed flag is state.config.settingsPanelCollapsed, so it persists
with the rest of the state, and you can set it in defaultState. Toggle it
from anywhere inside the provider with <Adaptable.Workspace.Toggle /> — pass
it the panel's position so it shows the matching icon — or with
adaptableApi.settingsPanelApi.toggleCollapsed(), expand() and collapse().
A toolbar with Adaptable.UI.ViewPicker, Adaptable.UI.QuickSearch and
Adaptable.Workspace.Toggle, above an Adaptable.Workspace whose main pane is
Adaptable.UI.ColumnChooser next to Adaptable.UI.DataGrid.
The panel starts collapsed and renderCollapsed: false leaves nothing on its
edge — click the toggle on the right of the toolbar to open it.
#A custom split
Adaptable.Workspace covers a main pane and one panel. For more panes, or a
split of your own, compose Adaptable.UI (or Adaptable.UI.DataGrid) and
Adaptable.UI.SettingsPanel yourself — see UI components.
#Props
This list is generated from the React types. The Vue component takes the same
props, except children: the main pane is the default slot. Where a
description says settingsPanel.children, read the settingsPanel slot.
#childrenReactNode
The main pane, replacing the built-in one picked by main.
#classNamestring
Class name on the workspace root element.
#collapsiblebooleandefault: true
Whether the settings panel can be collapsed. The collapsed flag is state.config.settingsPanelCollapsed, so it persists with the rest of the state; toggle it with adaptableApi.settingsPanelApi.toggleCollapsed() or render Adaptable.Workspace.Toggle anywhere inside the provider. The built-in panel gets a collapse button in its header; a replacement panel (settingsPanel.children) supplies its own.
#main'ui' | 'grid'default: 'ui'
Built-in main pane, used when children are omitted. 'ui' is Adaptable.UI (dashboard, grid and overlays). 'grid' is Adaptable.UI.DataGrid with Adaptable.UI.Overlays. Custom children render Adaptable.UI.Overlays themselves (it comes with Adaptable.UI).
#settingsPanelAdaptableWorkspacePanelPosition | AdaptableWorkspaceSettingsPanelConfig | false | nulldefault: 'bottom'
Settings panel placement. A position ('left' | 'right' | 'top' | 'bottom') or a config object. false or null renders the main pane alone; When the settings panel is not rendered, the settings will open in a dialog.
#showIconsWhenCollapsedbooleandefault: true
While collapsed, show an icon per settings page after the expand button; clicking one expands the panel on that page. Ignored when settingsPanel.renderCollapsed or settingsPanel.children is set.
#styleCSSProperties
Inline styles for the workspace root element.