<commit_before>;(function($, window, document, undefined) {
	
	$.fn.HUBfancyselect = function( method ) {
		if ( methods[method] ) 
		{
			return methods[method].apply( this, Array.prototype.slice.call( arguments, 1 ));
		} 
		else if ( typeof method === 'object' || ! method ) 
		{
			return methods.init.apply( this, arguments );
		} 
		else 
		{
			$.error( 'Method ' +  method + ' does not exist' );
		}
	};
	
	var methods = {},
		defaults = {
			hideSelect: true,
			showSearch: false,
			searchPlaceholder: 'Search...',
			maxHeightWithSearch: 500,
			onSearch: function() {},
			onSelected: function() {}
		};
	
	methods.init = function( options ) {
		var settings = $.extend({}, defaults, options);
		return this.each(function(){
			var $this = $(this),
				dropdown = '',
				children = $this.children();
			
			// must be a select element
			if (!$this.is('select'))
			{
				return 'Must be <select> element';
			}
			
			//set random #id
			$this.data('fancyselect', {
				id: Math.floor((Math.random()*1000)+1),
				settings: settings
			});
			
			// create dropdown<commit_msg>[JS_HUBFANCYSELECT] No longer uses random number for id, but incrementing number. This way they are always the same id on page.<commit_after>;(function($, window, document, undefined) {
	var idNumber = 0;
	$.fn.HUBfancyselect = function( method ) {
		if ( methods[method] ) 
		{
			return methods[method].apply( this, Array.prototype.slice.call( arguments, 1 ));
		} 
		else if ( typeof method === 'object' || ! method ) 
		{
			return methods.init.apply( this, arguments );
		} 
		else 
		{
			$.error( 'Method ' +  method + ' does not exist' );
		}
	};
	
	var methods = {},
		defaults = {
			hideSelect: true,
			showSearch: false,
			searchPlaceholder: 'Search...',
			maxHeightWithSearch: 500,
			onSearch: function() {},
			onSelected: function() {}
		};
	
	methods.init = function( options ) {
		var settings = $.extend({}, defaults, options);
		return this.each(function(){
			var $this = $(this),
				dropdown = '',
				children = $this.children();
			
			// must be a select element
			if (!$this.is('select'))
			{
				return 'Must be <select> element';
			}
			
			idNumber++;
			
			//set random #id
			$this.data('fancyselect', {
				id: idNumber,
				settings: settings
			});
			
			// create dropdown
{'fraction_non_alphanumeric': 0.16031195840554593, 'fraction_numerical': 0.006065857885615251, 'mean_word_length': 2.848333333333333, 'pattern_counts': {'":': 0, '<': 5, '<?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': '394528', 'n_tokens_mistral': 910, 'n_tokens_neox': 724, 'n_words': 193}