ember-cli-materialize
ember-cli-materialize copied to clipboard
md-collapsible doesn't admit div in collapsible body
Trying to use components inside the md-collapsible component, I've realized with the <p> tag you couldn't use <div> tag in the collapsible body because <p> doesn't admit <div> tag inside.
In order to allow this, we can change the <p> tag with a <div> tag.
What do you think about this solution?
<div> {{yield}} </div>
Shall I create a PR with the code?
<div class="collapsible-body">
<p>{{yield}}</p>
</div>
I assume you mean something like this (keeping the CSS class name):
<div class="collapsible-header {{if active 'active'}}" onClick={{action "headerClicked"}}>
{{#if icon}}
{{bw-compat-icon icon}}
{{/if}}
{{title}}
</div>
<div class="collapsible-body">{{yield}}</div>
MaterializeCSS suggests <span> but that has the same problem as <p> in that it's an inline element.
Yes, That's exactly what I'm talking about.