Unstyled heading element (h3 by default) wrapping the trigger of a primitive accordion item.
import AccordionHeaderPrimitive from "@wikicasa-dev/components/UIKit/Accordion/AccordionHeaderPrimitive";
Part of the primitive accordion composition: see the AccordionItemPrimitive doc for the full example. Place it inside AccordionItemPrimitive, with an AccordionTriggerPrimitive inside.
Usage
<script setup lang="ts">
import AccordionHeaderPrimitive from "@wikicasa-dev/components/UIKit/Accordion/AccordionHeaderPrimitive";
import AccordionTriggerPrimitive from "@wikicasa-dev/components/UIKit/Accordion/AccordionTriggerPrimitive";
</script>
<template>
<!-- inside <AccordionItemPrimitive> -->
<AccordionHeaderPrimitive as="h4">
<AccordionTriggerPrimitive>Spese condominiali</AccordionTriggerPrimitive>
</AccordionHeaderPrimitive>
</template>
Do / Don't
- Change the heading level with
asto fit the page outline (defaulth3). - Keep extra header content (checkboxes, badges) next to the trigger, not inside it.
API
Generated from the component's types. Do not edit by hand.
Props
| Name | Type | Default | Required | Description |
|---|---|---|---|---|
asChild |
boolean |
Change the default rendered element for the one passed as a child, merging their props and behavior. Read our Composition guide for more details. | ||
as |
AsTag | Component |
The element or component this component should render as. Can be overwritten by asChild. |
Events
None.
v-model
None.
Slots
| Name | Slot props |
|---|---|
default |
Exposed (template ref)
None.