1.0.2 • Published 8 months ago

svelte-animated-details v1.0.2

Weekly downloads
-
License
-
Repository
-
Last release
8 months ago

svelte-animated-details

Add a smooth accordion animation to your <details> elements using one line of Svelte.

Demo: https://andrewlester.net/svelte-animated-details/

Installation

npm i -D svelte-animated-details

Configuration

You must:

  • Give your <details> element overflow: hidden or overflow: clip. You'll be warned in dev if you aren't.

An example configuration is shown below:

<details use:animatedDetails>
    <summary>Summary</summary>
    <p>Content</p>
</details>

<style>
    details {
        overflow: hidden;
    }
</style>
1.0.2

8 months ago

1.0.1

1 year ago

1.0.0

1 year ago

0.0.2

1 year ago

0.0.1

1 year ago