Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions dojo/static/dojo/css/dojo.css
Original file line number Diff line number Diff line change
Expand Up @@ -1289,6 +1289,8 @@ span.endpoint_product {
.dojo-filter-set select[multiple],
.dojo-filter-set select[multiple=multiple] {
width: 100%;
/* override the fixed .form-control height, which would clip the list to a single option row */
height: auto;
min-height: 2.125rem;
max-height: 5rem;
font-size: 0.8125rem;
Expand Down
13 changes: 10 additions & 3 deletions dojo/templates/dojo/filter_js_snippet.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,16 @@
<script type="application/javascript">
$(function () {
$(function () {
$('.similar-filters select[multiple]').not('[data-tagulous]').each(function () {
$(this).select2();
})
// Select2 is only available when a tagulous widget pulled it in via form.media,
// so leave the native multiselect in place when it is not loaded.
if ($.fn.select2) {
$('.dojo-filter-set select[multiple], .similar-filters select[multiple]')
.not('[data-tagulous]')
.not('.select2-hidden-accessible')
.each(function () {
$(this).select2();
})
}
$('input[data-tagulous]').each(function () {
Tagulous.select2($(this))
})
Expand Down
Loading