Browser: Chrome
Vue 2 with vue-material-beta
For example:
<md-content>
<md-field class="md-alignment-top-left">
<md-input></md-input>
</md-field>
<md-button class="md-alignment-top-right">test</md-button>
</md-content>
Hey, can you please explain what you mean inline? or create some example?
@Samuell1 I wish the components display in the same row.
like <span></span> <span></span> not <div></div> <div></div>
I think this kind of layout make the user easily understand inputand buttonare paired.
The button's size is based on the text of the button, and the input will fill remaining space.
Like this
You can use Layout (https://vuematerial.io/ui-elements/layout)
<div class="md-layout">
<div class="md-layout-item">
input here
</div>
<div class="md-layout-item">
button here
</div>
</div>
Or use flex
https://codepen.io/VdustR/pen/mXVyjp
@Samuell1 I tried that but the width of md-layout-item are equal, looks really weird. it better displays flex. I wonder why the md-alignment-top-right doesn't work.
@VdustR Thanks!
@arkceajin md-alignment-top-right works only ifdisplay: flex or md-layout class is on element
@Samuell1
https://codepen.io/arkceajin/pen/ZrQGVy
Could you please help check this code, still not work.
it needs to be on same element @arkceajin
That is for parent
<div class="md-layout box md-alignment-top-right">
<md-button>TOP RIGHT</md-button>
<span>SPAN TOP RIGHT</span>
</div>
Most helpful comment
Or use flex
https://codepen.io/VdustR/pen/mXVyjp