Collapsible
Einen Bereich ein- und ausblenden – mit einem Auslöser, der aria-expanded und aria-controls synchron hält.
Verfügbar für- Angular: verfügbar
- Vue: verfügbar
- React: verfügbar
- React Native: verfügbar
Verwendung
- Ada Park: share the launch checklist
- Sam Lee: review the pricing page copy
- Kai Moreno: book the design review
<section soneCollapsible [(expanded)]="open" class="demo-stack" style="max-width: 28rem">
<button soneCollapsibleTrigger>
<svg soneCollapsibleIcon viewBox="0 0 16 16" fill="none">
<path d="M6 4l4 4-4 4" stroke="currentColor" stroke-width="1.5" stroke-linecap="round" stroke-linejoin="round" />
</svg>
<strong>Action items</strong>
</button>
<ul soneCollapsibleContent id="action-items" style="margin: 0; color: var(--text-secondary)">
<li>Ada Park: share the launch checklist</li>
<li>Sam Lee: review the pricing page copy</li>
<li>Kai Moreno: book the design review</li>
</ul>
</section>
Import
import {
SoneCollapsibleContentDirective,
SoneCollapsibleDirective,
SoneCollapsibleIconDirective,
SoneCollapsibleTriggerDirective,
} from "@surface-one/angular/collapsible";
API-Referenz
SoneCollapsibleContentDirectiveDirektive
- Selektor
[soneCollapsibleContent]
SoneCollapsibleDirectiveDirektive
- Selektor
[soneCollapsible]- Export als
soneCollapsible
SoneCollapsibleIconDirectiveDirektive
- Selektor
[soneCollapsibleIcon]
SoneCollapsibleTriggerDirectiveDirektive
- Selektor
button[soneCollapsibleTrigger]