Skip to main content

Table Mode Config

modeConfig.table controls the presentation of table mode — layout type, toggles, conditional row styling, and hook callbacks.

content: {
mode: 'table',
modeConfig: {
table: {
type: 'traditional',
alternatingRows: true,
hover: true,
},
},
item: { fields: […], layout: { type: 'auto' } },
},

Options​

OptionValuesDefaultEffect
typetraditional, rich-cellstraditionalChooses classic row/cell table layout or richer multi-column cell blocks.
columnsany number >= 11Number of rich-cell columns when type is rich-cells.
hovertrue, falsetrueEnables row hover behavior.
showHeadertrue, falsetrueShows or hides the header row.
alternatingRowstrue, falsetrueApplies zebra striping to alternating rows.
rowSeparatortrue, falsetrueDraws row bottom borders.
conditionalBackgroundColor(entity) => string | { backgroundColor, color? }unsetApplies dynamic row background and optional text color per entity.
hooks.onSort(field, direction) => voidunsetFires when a column sort changes.
hooks.onGroup(field) => voidunsetFires when grouping changes.
hooks.preRowRender(entity) => entityunsetLets you transform a row before render.
hooks.onGroupToggle(groupValue, isExpanded) => voidunsetFires when a group expands or collapses.

Mode-Specific Caveats​

  • columns applies only when type is rich-cells.
  • Grouping dropdown visibility requires at least one field with groupable: true.

Coverage Summary​

Every table setting is represented by at least one interactive example on the Table Mode guide page:

  • type and columns: Traditional Table, Rich Cells
  • hover, showHeader, alternatingRows, rowSeparator: Traditional Table, Presentation Toggles
  • conditionalBackgroundColor: Conditional Row Styling
  • groupings.showDropdownControl and groupings.showHeaderControls: Grouping Control Variants
  • hooks.onSort, hooks.onGroup, hooks.preRowRender, hooks.onGroupToggle: Hook Callbacks

See Also​