paper-collapse icon indicating copy to clipboard operation
paper-collapse copied to clipboard

expanded by default

Open jmls opened this issue 9 years ago • 5 comments

is it possible to have a section expanded by default ?

awesome work, by the way.

jmls avatar Mar 19 '15 21:03 jmls

First of, thank you for your kind words.

Good idea, i will roll this out in the next version.

As a quick fix and workaround you can try to add the 'active' class to the collapse-card and add a style attribute to the collapse-card__body with display block. This would make on component expanded by default.

Example:

<div class="collapse-card active">
  <div class="collapse-card__heading">
    <div class="collapse-card__title">
      <i class="fa fa-question-circle fa-2x fa-fw"></i>
      title here
    </div>
  </div>
  <div class="collapse-card__body" style="display: block;">
    text here
  </div>
</div>

alexander-ruehle avatar Mar 20 '15 08:03 alexander-ruehle

ohhh, close ;) thanks for the feedback - however there is a problem. When the form is first viewed, the card is indeed popped out - but with no content. click on the card to shrink, click again to expand, and it's all there. see below ;)

screenshot - 200315 - 08 47 20 screenshot - 200315 - 08 47 36

jmls avatar Mar 20 '15 08:03 jmls

Can you post your code here? I think you missed the style="display: block;" part on the .collapse-card__body

alexander-ruehle avatar Mar 20 '15 08:03 alexander-ruehle

um, ah, well, cough

No, I didn't miss it out ... I had

<div class="collapse-card__body style="display: block;">

spot the deliberate mistake ;)

thanks again

jmls avatar Mar 20 '15 09:03 jmls

That explains a lot. ;) Glad i could help.

alexander-ruehle avatar Mar 20 '15 09:03 alexander-ruehle