// Autosize 1.15.3 - jQuery plugin for textareas
// (c) 2013 Jack Moore - jacklmoore.com
// license: www.opensource.org/licenses/mit-license.php
(function($){var defaults={className:'autosizejs',append:'',callback:false},hidden='hidden',borderBox='border-box',lineHeight='lineHeight',copy='',copyStyle=['fontFamily','fontSize','fontWeight','fontStyle','letterSpacing','textTransform','wordSpacing','textIndent'],oninput='oninput',onpropertychange='onpropertychange',mirrored,mirror=$(copy).data('autosize',true)[0];mirror.style.lineHeight='99px';if($(mirror).css(lineHeight)==='99px'){copyStyle.push(lineHeight)}mirror.style.lineHeight='';$.fn.autosize=function(options){options=$.extend({},defaults,options||{});if(mirror.parentNode!==document.body){$(document.body).append(mirror)}return this.each(function(){var ta=this,$ta=$(ta),minHeight=$ta.height(),active,resize,boxOffset=0,callback=$.isFunction(options.callback);if($ta.data('autosize')){return}if($ta.css('box-sizing')===borderBox||$ta.css('-moz-box-sizing')===borderBox||$ta.css('-webkit-box-sizing')===borderBox){boxOffset=$ta.outerHeight()-$ta.height()}resize=($ta.css('resize')==='none'||$ta.css('resize')==='vertical')?'none':'horizontal';$ta.css({overflow:hidden,overflowY:hidden,wordWrap:'break-word',resize:resize}).data('autosize',true);function initMirror(){mirrored=ta;mirror.className=options.className;$.each(copyStyle,function(i,val){mirror.style[val]=$ta.css(val)})}function adjust(){var height,overflow,original;if(mirrored!==ta){initMirror()}if(!active){active=true;mirror.value=ta.value+options.append;mirror.style.overflowY=ta.style.overflowY;original=parseInt(ta.style.height,10);mirror.style.width=$ta.width()+'px';mirror.scrollTop=0;mirror.scrollTop=9e4;height=mirror.scrollTop;var maxHeight=parseInt($ta.css('maxHeight'),10);maxHeight=maxHeight&&maxHeight>0?maxHeight:9e4;if(height>maxHeight){height=maxHeight;overflow='scroll'}else if(height