Ghost/ghost/admin/app/templates/components/power-select-vertical-collection-options.hbs

19 lines
854 B
Handlebars
Raw Normal View History

<ul role="listbox" aria-controls="ember-power-select-trigger-{{@select.uniqueId}}" {{did-insert this.addHandlers}} ...attributes>
{{#if @select.loading}}
{{#if @loadingMessage}}
<li class="ember-power-select-option ember-power-select-option--loading-message" role="option">{{@loadingMessage}}</li>
{{/if}}
{{/if}}
{{#vertical-collection options minHeight=30 estimateHeight=6 bufferSize=10 as |opt index|}}
<li class="ember-power-select-option"
aria-selected="{{ember-power-select-is-selected opt select.selected}}"
aria-disabled={{if opt.disabled "true"}}
aria-current="{{eq opt @select.highlighted}}"
data-option-index="{{@groupIndex}}{{index}}"
role="option">
{{yield opt @select}}
</li>
{{/vertical-collection}}
</ul>