Expand / Collapse Widget Examples

Basic expand/collapse pattern using a button and a controlled container with class="details".

Animated open/close. The script computes the height for a smooth transition and restores auto height when open.

Nested expand/collapse widget. Both widgets are wrapped in their own .example and their content containers use class="details".