cksource-archive / samples-framework

☠☠☠ This repository is no longer used ☠☠☠
Other
0 stars 0 forks source link

Improvements to toggler component example in docs #36

Open oleq opened 9 years ago

oleq commented 9 years ago

A heritage of #34.

The layout of the icon is broken because <div> is used:

screen shot 2015-03-27 at 16 31 19

With the following markup

<div class="grid-container" style="outline: 1px solid #eee">
    <p class="grid-width-100">
        <span data-for="collapseexample" class="toggler expanded icon-pos-left icon-toggler-expanded button-a">
            <label data-collapse>Collapse this box</label>
            <label data-expand>Expand this box</label>
        </span>
    </p>
    <div id="collapseexample" class="toggler-container grid-width-100">
<pre><code>var day = new Date().getDay();</code></pre>
    </div>
</div>

we can do better than that:

screen shot 2015-03-27 at 16 40 53