I use Multiselect from AngularJS ui-select.
My multiselect looks like this http://plnkr.co/edit/zJRUW8STsGlrJ38iVwhI?p=preview
Spans can be arranged in multiple lines if there are many. I want to do nice vertical aligment for this.
I managed to do it for one line:
(source: cs630525.vk.me)
But it fails on multiple lines:
(source: cs630525.vk.me)
(source: cs630525.vk.me)
"nice vertical aligment" - paddings with same colors must be equal
(source: cs630525.vk.me)
HTML
<ui-select multiple class="ui-select-container ui-select-multiple ui-select-bootstrap form-control dropdown"
ng-model="multipleDemo.colors" ng-disabled="disabled">
<ui-select-match class="ui-select-match" placeholder="Select colors...">{{$item}}</ui-select-match>
<ui-select-choices repeat="color in availableColors | filter:$select.search">
{{color}}
</ui-select-choices>
</ui-select>
CSS
.ui-select-multiple.ui-select-bootstrap {
padding: 0 3px;
min-height: 34px;
height: auto;
width: 300px;
}
.ui-select-match {
display: inline;
vertical-align: baseline;
}
.ui-select-multiple.ui-select-bootstrap input.ui-select-search {
min-height: 32px;
margin: 0;
}
.ui-select-multiple.ui-select-bootstrap > div {
min-height: 32px;
}
.form-control {
display: block;
width: 100%;
height: 34px;
padding: 6px 12px;
font-size: 14px;
line-height: 1.42857143;
color: #555;
background-color: #fff;
background-image: none;
border: 1px solid #ccc;
border-radius: 4px;
}
How can I do this?