Index: main/plugin-odf-web/resources/js/search/facet-links.i18n.js =================================================================== --- main/plugin-odf-web/resources/js/search/facet-links.i18n.js (revision 39736) +++ main/plugin-odf-web/resources/js/search/facet-links.i18n.js (working copy) @@ -46,7 +46,7 @@ var sortByCountDesc = function(a, b) { - return parseCount($j(b)) - parseCount($j(a)); + return parseSelected($j(b)) ? 1 : parseCount($j(b)) - parseCount($j(a)); } var parseCount = function($elt) @@ -61,3 +61,9 @@ } return 0; } + +var parseSelected = function($elt) +{ + return $elt.hasClass('selected'); +} +