Customising Default Pages
CnIndexPage and its sub-components are designed to be extended without forking. This guide covers every customisation scenario with working code examples.
Overview of extension points
CnIndexPage
│
├── Page header (inline title / icon / description)
│ prop: show-title, icon, description
│
├── CnActionsBar (top toolbar)
│ ├── slot: #action-items ← add buttons to the Actions dropdown
│ ├── slot: #mass-actions ← add mass-action buttons when rows selected
│ └── slot: #header-actions ← add buttons to the far-right of the bar
│
├── CnDataTable (the table)
│ ├── slot: #column-{key} ← custom cell renderer for a column
│ ├── slot: #row-actions ← replace the entire ⋯ action menu
│ └── slot: #empty ← custom empty state
│
├── CnCardGrid (card view — when viewMode="cards")
│ ├── slot: #card ← replace the entire card template
│ ├── slot: #card-actions ← add action buttons on each card
│ └── slot: #card-badges ← add badge/status chips to each card
│
├── CnIndexSidebar (right panel)
│ ├── prop: default-tab ← set the initially active tab
│ ├── event: tab-change ← notified when the user switches tabs
│ ├── slot: #tabs ← inject additional NcAppSidebarTab components
│ ├── slot: #search-extra ← append to Search tab
│ └── slot: #columns-extra ← append to Columns tab