Epitouille Epitouille - 1 month ago 25
CSS Question

angular design material md-list-item in the right

According the exemple :

https://material.angularjs.org/#/demo/material.components.list

the checkboxes are stacked on the right :

enter image description here

So in my code the checkboxes are under the text :

enter image description here

I don't know why the result is different in my code because I copy-past the exemple, I juste changed ng-repeat by 2 elements.

Here is my codepen :

http://codepen.io/anon/pen/wBbREV

<md-list>
<md-subheader class="md-no-sticky">md-list</md-subheader>

<md-list-item>
<p> title </p>
<md-checkbox class="md-secondary"></md-checkbox>
</md-list-item>

<md-list-item>
<p> title </p>
<md-checkbox class="md-secondary"></md-checkbox>
</md-list-item>

</mdlist>


Thanks!

Answer

To make it on the same row, Just align the layout like this,

<md-list-item layout="row">

Here is the updated Version

Comments