<commit_before>(function($) {
	$.fn.templating = function(templateId, data)
	{
		var html = $("#" + templateId).html();
		var template = Handlebars.compile(html);
		$(this).html(template(data));
	};

    $.fn.attrr = function(key)
    {
    	var value = $(this).attr(key);
    	$(this).removeAttr(key);
    	return value;
    };

    $.fn.getRect = function()
    {
    	return this.get(0).getBoundingClientRect();
    };

    $.fn.showProgress = function()
    {
    	try
    	{
    		if(this.get(0) != null)
    		{
    			var progress = document.createElement('div');
            	progress.className = "imboard-progress";

            	var style = getComputedStyle(this.get(0));

            	var width = new Number(style.width.replace("px", ""));
            	var height = new Number(style.height.replace("px", ""));

            	if(width > 100 || height > 100)
            	{
            		width = 100;
            		height = 100;

            		var rect = this.get(0).getBoundingClientRect();

            		var mw = (rect.width - width) / 2;
            		var mh = (rect.height - height) / 2;

            		progress.style.margin = mh + "px " + mw + "px";
            	}

            	progress.style.width = width + "px";
            	progress.style.height = height + "px";

            	$(progress).insertBefore(this);
            	this.get(0).progress = progress;
            	this.hide();
    		}
    		else
    		{
    			console.error("Progress target is null");
    		}
    	}
    	catch(err)
    	{
    		console.error(err.stack);
    	}
    };

    $.fn.isProcessing = function()
    {
    	if(this.get(0) != null)
    		return this.get(0).progress != null;
    	else
    		return false;
    };

    $.fn.dismissProgress = function()
    {
    	if(this.get(0) != null)
    	{
    		var progress = this.get(0).progress;
        	$(progress).remove();

        	this.get(0).progress = null;
    	}

    	this.show();
    };

    $.fn.flickering = function(option)
    {
    	var theme = option && option.theme ? option.theme : "default";
    	var time = option && option.time ? option.time : 500;
    	this.addClass(theme);
    	this.addClass("flickering");

    	var that = this;
    	setTimeout(function(){
    		that.removeClass(theme);
    		setTimeout(function()
    		{
    			that.removeClass('flickering');
    		}, time);
    	}, time);
    };

    $.fn.getData = function()
    {
    	if(this.get(0).getData)
    		return this.get(0).getData();
    	else
    		return null;
    };

    $.fn.setData = function(data)
    {
    	if(this.get(0).setData)
    		this.get(0).setData(data);
    };
    
    $.fn.makeValidationMessage = function(message)
    {
    	$(".imboard-ui-validation").remove();
    		
    	var that = this.get(0);
		var rect = that.getBoundingClientRect();
		
		if(!message)
			message = that.validationMessage;

		var pos = {left : that.offsetLeft, top : that.offsetTop};

		var parent = that.offsetParent;
		while(parent)
		{
			pos.left += parent.offsetLeft;
			pos.top += parent.offsetTop;

			parent = parent.offsetParent;
		}

		var div = document.createElement("div");
		div.className = "imboard-ui-validation"
		div.style.left = pos.left + 20 + "px";
		div.style.top = pos.top + rect.height + 5 + "px";

		var arrow = document.createElement("span");
		arrow.className = "arrow";

		var arrowBorder = document.createElement("span");
		arrowBorder.className = "arrowBorder";

		var span = document.createElement("span");
		span.className = "validation-message";
		span.innerText = message;

		div.appendChild(arrowBorder);
		div.appendChild(arrow);
		div.appendChild(span);

		document.body.appendChild(div);
		
		that.focus();
		$(that).off("input blur");
		$(that).on("input blur", function(e)<commit_msg>imboard-ui validation 메시지 blur조건 추가.<commit_after>(function($) {
	$.fn.templating = function(templateId, data)
	{
		var html = $("#" + templateId).html();
		var template = Handlebars.compile(html);
		$(this).html(template(data));
	};

    $.fn.attrr = function(key)
    {
    	var value = $(this).attr(key);
    	$(this).removeAttr(key);
    	return value;
    };

    $.fn.getRect = function()
    {
    	return this.get(0).getBoundingClientRect();
    };

    $.fn.showProgress = function()
    {
    	try
    	{
    		if(this.get(0) != null)
    		{
    			var progress = document.createElement('div');
            	progress.className = "imboard-progress";

            	var style = getComputedStyle(this.get(0));

            	var width = new Number(style.width.replace("px", ""));
            	var height = new Number(style.height.replace("px", ""));

            	if(width > 100 || height > 100)
            	{
            		width = 100;
            		height = 100;

            		var rect = this.get(0).getBoundingClientRect();

            		var mw = (rect.width - width) / 2;
            		var mh = (rect.height - height) / 2;

            		progress.style.margin = mh + "px " + mw + "px";
            	}

            	progress.style.width = width + "px";
            	progress.style.height = height + "px";

            	$(progress).insertBefore(this);
            	this.get(0).progress = progress;
            	this.hide();
    		}
    		else
    		{
    			console.error("Progress target is null");
    		}
    	}
    	catch(err)
    	{
    		console.error(err.stack);
    	}
    };

    $.fn.isProcessing = function()
    {
    	if(this.get(0) != null)
    		return this.get(0).progress != null;
    	else
    		return false;
    };

    $.fn.dismissProgress = function()
    {
    	if(this.get(0) != null)
    	{
    		var progress = this.get(0).progress;
        	$(progress).remove();

        	this.get(0).progress = null;
    	}

    	this.show();
    };

    $.fn.flickering = function(option)
    {
    	var theme = option && option.theme ? option.theme : "default";
    	var time = option && option.time ? option.time : 500;
    	this.addClass(theme);
    	this.addClass("flickering");

    	var that = this;
    	setTimeout(function(){
    		that.removeClass(theme);
    		setTimeout(function()
    		{
    			that.removeClass('flickering');
    		}, time);
    	}, time);
    };

    $.fn.getData = function()
    {
    	if(this.get(0).getData)
    		return this.get(0).getData();
    	else
    		return null;
    };

    $.fn.setData = function(data)
    {
    	if(this.get(0).setData)
    		this.get(0).setData(data);
    };
    
    $.fn.makeValidationMessage = function(message)
    {
    	$(".imboard-ui-validation").remove();
    		
    	var that = this.get(0);
		var rect = that.getBoundingClientRect();
		
		if(!message)
			message = that.validationMessage;

		var pos = {left : that.offsetLeft, top : that.offsetTop};

		var parent = that.offsetParent;
		while(parent)
		{
			pos.left += parent.offsetLeft;
			pos.top += parent.offsetTop;

			parent = parent.offsetParent;
		}

		var div = document.createElement("div");
		div.className = "imboard-ui-validation"
		div.style.left = pos.left + 20 + "px";
		div.style.top = pos.top + rect.height + 5 + "px";

		var arrow = document.createElement("span");
		arrow.className = "arrow";

		var arrowBorder = document.createElement("span");
		arrowBorder.className = "arrowBorder";

		var span = document.createElement("span");
		span.className = "validation-message";
		span.innerText = message;

		div.appendChild(arrowBorder);
		div.appendChild(arrow);
		div.appendChild(span);

		document.body.appendChild(div);

		document.body.scrollTop = that.getBoundingClientRect().top + document.body.scrollTop;
		that.focus();
		$(that).off("input blur");
		$(that).on("input blur click", function(e)
{'fraction_non_alphanumeric': 0.1580327868852459, 'fraction_numerical': 0.009180327868852459, 'mean_word_length': 2.1473380107304996, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, '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': '4540388', 'n_tokens_mistral': 2711, 'n_tokens_neox': 2537, 'n_words': 435}