Skip to main content

rc-disclosure

Disclosure wrapper for a native <details>/<summary> pair with controlled open state, following the WAI-ARIA Disclosure pattern.

Package
@rcarls/rc-disclosure
Element
<rc-disclosure>
Native dependency
Requires a native details child
State model
Controlled or uncontrolled open state
Main events
rc-disclosure-toggle

Installation

npm install @rcarls/rc-disclosure
import '@rcarls/rc-disclosure/define';

Live demo

Theming

The default demo mode shows the component without a package theme. Use the shared preview controls on this page to compare inherited, light, and dark color schemes or to apply the optional Material theme only inside the demo frames.

API

Properties

PropertyMarkupTypeDefaultDescription
openJS property onlybooleanNot specifiedCurrent open state mirrored to the child `<details>`.
fragmentJS property onlybooleanNot specifiedNo description provided.

Methods

No public methods are documented in the custom elements manifest.

Events

EventDetail typeDescription
rc-disclosure-toggleNo detail type documentedFires when the child `<details>` toggles.

Slots

No slots are documented in the custom elements manifest.

CSS Custom Properties

No CSS custom properties are documented in the custom elements manifest.

CSS Parts

No CSS parts are documented in the custom elements manifest.