illright / attractions

A pretty cool UI kit for Svelte
https://illright.github.io/attractions
MIT License
1.03k stars 37 forks source link

Add Advanced Documentation for the AccordionSection Element #342

Closed zPhoeniqz closed 2 years ago

zPhoeniqz commented 2 years ago

On the attractions website form example, the accordion at the left in the component section has this vertical grey line (I am sure there is a separate term for this, but I don't know it). I would like to implement this in my app, but I don't know how and I cannot find any information about this on the website.

zPhoeniqz commented 2 years ago

It looks like this feature is not available, which explains why there is no documentation about it

zPhoeniqz commented 2 years ago

This is a solution which looks quite the same as the accordion on the website:



<div class="wrapper-position-adjust">
    <div class="content-wrapper">
        <slot />
    </div>
</div>

Then add this component where you need it, but inside the <AccordionSection> element, after the <div slot="handle">...</div>. Inside the tag you can add the hidden content, e.g. links the accordion will show on click. I'm not sure if this should become an own component as it is pretty easy to write yourself and barely requires any CSS skills.

I will close this issue now.