<commit_before>var RiceContrib = RiceContrib || {};
RiceContrib.MultiSelect = RiceContrib.MultiSelect || {};
(function(namespace, $) {
	namespace.init = function() {
		$('.selectpicker').selectpicker('refresh');
		$('select.advanced_select').each(function() {
			if ($(this).siblings('.bootstrap-select').length == 0) {
				var template = $(this).data('template');
				var defaultSettings = {
					selectedTextFormat : "count > 5",
					liveSearch : $(this).attr('multiple') ? true : false,
				};
				
				$(this).selectpicker($.extend({}, defaultSettings, template));
			}
		});
		$("[data-role='View']").on(kradVariables.EVENTS.UPDATE_CONTENT, namespace.init);
	};
})(RiceContrib.MultiSelect, jQuery);

jQuery(document).ready(function() { RiceContrib.MultiSelect.init(); });<commit_msg>KRACOEUS-7970 performance/lock up fix for multiselect<commit_after>var RiceContrib = RiceContrib || {};
RiceContrib.MultiSelect = RiceContrib.MultiSelect || {};
(function(namespace, $) {
	namespace.init = function() {
		$('.selectpicker').selectpicker('refresh');
		$('select.advanced_select').each(function() {
			if ($(this).siblings('.bootstrap-select').length == 0) {
				var template = $(this).data('template');
				var defaultSettings = {
					selectedTextFormat : "count > 5",
					liveSearch : $(this).attr('multiple') ? true : false
				};
				
				$(this).selectpicker($.extend({}, defaultSettings, template));
			}
		});
	};
})(RiceContrib.MultiSelect, jQuery);

jQuery(document).ready(function() {
    RiceContrib.MultiSelect.init();
    jQuery("[data-role='View']").on(kradVariables.EVENTS.UPDATE_CONTENT, RiceContrib.MultiSelect.init);
});
{'fraction_non_alphanumeric': 0.19549330085261876, 'fraction_numerical': 0.0048721071863581, 'mean_word_length': 4.888888888888889, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3746554', 'n_tokens_mistral': 576, 'n_tokens_neox': 501, 'n_words': 73}