portality/static/widget/fq_widget_depends_compiled.js
// Alternative active filter renderers which use buttons - deprecated due to usability/ux concerns
Alternative active filter renderers which use buttons - deprecated due to usability/ux concerns
Alternative active filter renderers which use buttons - deprecated due to usability / ux concerns
function renderActiveTermsFilterButton(options, facet, field, filter_list) {
    var clean = safeId(field)
    var display = facet.display ? facet.display : facet.field
    var logic = facet.logic ? facet.logic : options.default_facet_operator
    var frag = "<div id='facetview_filter_group_" + clean + "' class='btn-group'>";
    if (options.show_filter_field) {
        frag += '<a class="btn btn-info facetview_inactive_link facetview_filterselected" href="' + field + '">'
        frag += '<span class="facetview_filterselected_text"><strong>' + display + '</strong></span>'
        frag += "</a>"
    }
    for (var i = 0; i < filter_list.length; i++) {
        var value = filter_list[i]
        if (facet.value_function) {
            value = facet.value_function(value)
        }
        frag += '<a class="facetview_filterselected facetview_clear btn btn-info" data-field="' + field + '" data-value="' + escapeHtml(value) + '" alt="remove" title="remove" href="' + escapeHtml(value) + '">'
        frag += '<span class="facetview_filterselected_text">' + escapeHtml(value) + '</span> <i class="icon-white icon-remove" style="margin-top:1px;"></i>'
        frag += "</a>"
        if (i !== filter_list.length - 1 && options.show_filter_logic) {
            frag += '<a class="btn btn-info facetview_inactive_link facetview_filterselected" href="' + field + '">'
            frag += '<span class="facetview_filterselected_text"><strong>' + logic + '</strong></span>'
            frag += "</a>"
        }
    }
    frag += "</div>"
    return frag
}
function renderActiveTermsFilterButton ( options , facet , field , filter_list ) { var clean = safeId ( field ) var display = facet . display ? facet . display : facet . field var logic = facet . logic ? facet . logic : options . default_facet_operator var frag = "<div id='facetview_filter_group_" + clean + "' class='btn-group'>" ; if ( options . show_filter_field ) { frag += '<a class="btn btn-info facetview_inactive_link facetview_filterselected" href="' + field + '">' frag += '<span class="facetview_filterselected_text"><strong>' + display + '</strong></span>' frag += "</a>" } for ( var i = 0 ; i < filter_list . length ; i ++ ) { var value = filter_list [ i ] if ( facet . value_function ) { value = facet . value_function ( value ) } frag += '<a class="facetview_filterselected facetview_clear btn btn-info" data-field="' + field + '" data-value="' + escapeHtml ( value ) + '" alt="remove" title="remove" href="' + escapeHtml ( value ) + '">' frag += '<span class="facetview_filterselected_text">' + escapeHtml ( value ) + '</span> <i class="icon-white icon-remove" style="margin-top:1px;"></i>' frag += "</a>" if ( i !== filter_list . length - 1 && options . show_filter_logic ) { frag += '<a class="btn btn-info facetview_inactive_link facetview_filterselected" href="' + field + '">' frag += '<span class="facetview_filterselected_text"><strong>' + logic + '</strong></span>' frag += "</a>" } } frag += "</div>" return frag }
Alternative active filter renderers which use buttons - deprecated due to usability/ux concerns
Alternative active filter renderers which use buttons - deprecated due to usability / ux concerns
/*****************************************
     * overrides must provide the following classes and ids
     *
     * class: facetview_filterselected - anchor tag for any clickable filter selection
     * class: facetview_clear - anchor tag for any link which will remove the filter (should also provide data-value and data-field)
     * class: facetview_inactive_link - any link combined with facetview_filterselected which should not execute when clicked
     *
     * should (not must) respect the config
     *
     * options.show_filter_field - whether to include the name of the field the filter is active on
     * options.show_filter_logic - whether to include AND/OR along with filters
     * facet.value_function - the value function to be applied to all displayed values
     */