Ga naar hoofdinhoud

CnDetailCard

Card container for sections on detail pages. Provides a consistent header (icon + title + optional actions), scrollable content area, and optional footer. Supports optional collapse/expand behavior.

Try it​

Loading CnDetailCard playground…

Usage​

<!-- Basic card -->
<CnDetailCard title="Core Information">
<CnDetailGrid :fields="fields" />
</CnDetailCard>

<!-- With icon and header actions -->
<CnDetailCard title="Pipeline" :icon="ChartTimelineVariant">
<template #header-actions>
<NcButton type="tertiary" @click="editStage">Edit</NcButton>
</template>
<CnTimelineStages :stages="stages" :current-stage="currentStage" />
</CnDetailCard>

<!-- Collapsible card, starts collapsed -->
<CnDetailCard title="Extended Properties" :collapsible="true" :collapsed="true">
<CnDetailGrid :fields="extraFields" />
</CnDetailCard>

<!-- Flush (no content padding) — for tables or lists that go edge-to-edge -->
<CnDetailCard title="Related Items" :flush="true">
<CnDataTable :rows="rows" :columns="columns" />
</CnDetailCard>

Props​

PropTypeDefaultDescription
titleString''Card title shown in the header
subtitleString''A muted line under the title, as given (translate before passing). No line when empty. The widget host passes a widget's translated subtitle to an integration card.
iconObject | FunctionnullVue component for the header icon (MDI component reference)
collapsibleBooleanfalseWhether the card body can be collapsed by clicking the header
chevronStart (chevron-start)BooleanfalseDraw the collapse chevron before the title instead of after the header actions (only relevant when collapsible is true).
chromelessBooleanfalseRender the content without the card: no border, background, padding or header. For a surface that already draws the card and names it, such as a tab panel whose open tab is its title.
collapsedBooleanfalseInitial collapsed state (only applies when collapsible is true). Supports .sync
flushBooleanfalseRemove content padding — lets tables and lists extend edge-to-edge

Events​

EventPayloadDescription
update:collapsedbooleanEmitted when the collapsed state changes (for use with .sync)

Slots​

SlotDescription
defaultCard body content
iconCustom icon element replacing the icon prop
header-actionsButtons or controls placed in the right side of the header
footerFooter content rendered below the body with a top border

Reference (auto-generated)​

The tables below are generated from the SFC source via vue-docgen-cli. They reflect what's actually in CnDetailCard.vue and update automatically whenever the component changes.

OpenRegister reliance​

light: this component touches OpenRegister lightly. 0 direct references, 3 files reached through imports.

See the reliance overview for the filterable list.

Props​

NameTypeRequiredDefaultDescription
chromelessbooleanfalseRender the card's content without the card: no border, no background, no padding, and no header. For a surface that already supplies both, such as a tab panel whose open tab names it. Drawing the card there nests a card inside a card and shows the title twice.
titlestring''Card header title
subtitlestring''A muted line under the title, as given (translate before passing).
iconobject&#124;funcnullOptional MDI icon component for the header
collapsiblebooleanfalseWhether the card can be collapsed
chevronStartbooleanfalseDraw the collapse chevron before the title instead of after the header actions (only relevant when collapsible is true).
collapsedbooleanfalseInitial collapsed state (only relevant when collapsible is true)
flushbooleanfalseRemove content padding — allows tables and lists to go edge-to-edge.

Events​

NamePayloadDescription
update:collapsed—

Slots​

NameBindingsDescription
icon—
actions—
default—
footer—