Collapse
A content area which can be collapsed and expanded.
When To Use#
- Can be used to group or hide complex regions to keep the page clean.
Accordion
is a special kind ofCollapse
, which allows only one panel to be expanded at a time.
import { NzCollapseModule } from 'ng-zorro-antd/collapse';
Examples
A dog is a type of domesticated animal. Known for its loyalty and faithfulness, it can be found as a welcome guest in many households across the world.
Loading...
This is panel header 1 content
Loading...
This is panel header 1
A dog is a type of domesticated animal. Known for its loyalty and faithfulness, it can be found as a welcome guest in many households across the world.
Loading...
This is panel header 1 content
Loading...
This is panel header 1 content
Loading...
A dog is a type of domesticated animal. Known for its loyalty and faithfulness, it can be found as a welcome guest in many households across the world.
Loading...
A dog is a type of domesticated animal. Known for its loyalty and faithfulness, it can be found as a welcome guest in many households across the world.
Expand Icon Position:
Loading...
A dog is a type of domesticated animal. Known for its loyalty and faithfulness, it can be found as a welcome guest in many households across the world.
Loading...
API#
nz-collapse#
Property | Description | Type | Default | Global Config |
---|---|---|---|---|
[nzAccordion] | Accordion mode | boolean | false | ✅ |
[nzBordered] | Set border style | boolean | true | ✅ |
[nzGhost] | Make the collapse borderless and its background transparent | boolean | false | ✅ |
[nzExpandIconPosition] | Set expand icon position | 'start' | 'end' | start | - |
nz-collapse-panel#
Property | Description | Type | Default | Global Config |
---|---|---|---|---|
[nzDisabled] | If true , panel cannot be opened or closed | boolean | false | - |
[nzHeader] | Title of the panel | string | TemplateRef<void> | - | - |
[nzExpandedIcon] | Customize an icon for toggle | string | TemplateRef<void> | - | - |
[nzExtra] | Extra element in the corner | string | TemplateRef<void> | - | - |
[nzShowArrow] | Display arrow or not | boolean | true | ✅ |
[nzActive] | Active status of panel, double binding | boolean | - | - |
(nzActiveChange) | Callback function of the active status | EventEmitter<boolean> | - | - |