").addClass("terminal-output").attr("role","log").appendTo(He);ne.addClass("terminal");if(Fe.login&&q("onBeforeLogin")===false){Le=false}var qe;if(typeof e==="string"){qe=e}else if(is_array(e)){for(var We=0,Ke=e.length;We
',{raw:true})}function a(e){var t=window.URL||window.webkitURL;return t.createObjectURL(e)}function o(e,t){if(!t&&is_function(Fe.onPaste)){var n={target:ne};if(typeof e==="string"){n["text"]=e}else if(e instanceof Blob){n["image"]=a(e)}var r=q("onPaste",[n]);if(r){if(is_function(r.then||r.done)){return(r.then||r.done).call(r,function(e){o(e,true)})}else{o(r,true)}}else{o(n.image||n.text,true)}}else if(e instanceof Blob){i(a(e))}else if(typeof e==="string"){if(e.match(/^(data:|blob:)/)){i(e)}else{ne.insert(e)}}}if(e.clipboardData){if(ne.enabled()){var n=e.clipboardData.items;if(n){for(var r=0;r
").appendTo(He).cmd({tabindex:Fe.tabindex,mobileDelete:Fe.mobileDelete,mobileIngoreAutoSpace:Fe.mobileIngoreAutoSpace,prompt:Je?false:t,history:Fe.memory?"memory":Fe.history,historyFilter:Fe.historyFilter,historySize:Fe.historySize,caseSensitiveSearch:Fe.caseSensitiveSearch,onPaste:Fe.onPaste,width:"100%",enabled:false,char_width:ke.width,keydown:X,keymap:Ze,clickTimeout:Fe.clickTimeout,holdTimeout:Fe.holdTimeout,holdRepeatTimeout:Fe.holdRepeatTimeout,repeatTimeoutKeys:Fe.repeatTimeoutKeys,allowedAttributes:Fe.allowedAttributes,keypress:Z,tabs:Fe.tabs,onPositionChange:function(){var e=[].slice.call(arguments);K();q("onPositionChange",e)},onCommandChange:function(e){if(Ee!==Ue.width()){ne.resizer()}q("onCommandChange",[e]);K()},commands:I});function n(e){if(is_mobile){return}e=e.originalEvent;if(e){var t=document.elementFromPoint(e.clientX,e.clientY);if(!$(t).closest(".terminal").length&&ne.enabled()){ne.disable()}}}ne.oneTime(100,function(){$(document).bind("click.terminal_"+ne.id(),n).bind("contextmenu.terminal_"+ne.id(),n)});var r=$(window);document.addEventListener("resume",function(){ne.disable()});if(is_mobile){(function(){ne.addClass("terminal-mobile");var i;var a;var n;var o=3;var e=Pe.clip();var r=200;var u;e.$node.off("touchstart.cmd");ne.on("touchstart.terminal",function(e){e=e.originalEvent;window.touch_event=e;if(e.target.tagName.toLowerCase()==="a"){return}if(!Be&&e.touches.length===1){n=ne.enabled();var t=e.touches[0];i={x:t.clientX,y:t.clientY};u=setTimeout(function(){i=null},r)}}).on("touchmove.terminal",function(e){if(e.touches.length===1&&i){var t=e.touches[0];var n=Math.abs(t.clientX-i.x);var r=Math.abs(t.clientY-i.y);if(n>o||r>o){a=true}}}).on("touchend.terminal",function(){if(i){clearTimeout(u);if(!a){if(!n){e.focus();ne.focus()}else{e.blur();ne.disable()}}}a=false;i=null})})()}else{r.on("focus.terminal_"+ne.id(),Qe).on("blur.terminal_"+ne.id(),Ye);(function(){var t=0;var r;var n="click_"+ne.id();var i=ne.find(".cmd textarea");function a(){if(r.is(".terminal")||r.is(".terminal-wrapper")){var e=ne.get_command().length;ne.set_position(e)}else if(r.closest(".cmd-prompt").length){ne.set_position(0)}if(!i.is(":focus")){var t=Pe.offset();var n=ne.offset();i.css({left:n.left-t.left,top:n.top-t.top}).focus();ne.stopTime("focus");ne.oneTime(10,"focus",function(){i.css({left:"",top:""})})}o()}function o(){t=0;r=null}var u=".terminal-output textarea,"+".terminal-output input";ne.mousedown(function(e){if(!scrollbar_event(e,Ue)){r=$(e.target)}}).mouseup(function(){if(r&&r.closest(u).length){if(Re){ne.disable()}}else if(get_selected_html()===""&&r){if(++t===1){if(!Be){if(!Re){ne.focus()}else{var e=Fe.clickTimeout;ne.oneTime(e,n,a);return}}}else{ne.stopTime(n)}}o()}).dblclick(function(){o();ne.stopTime(n)})})();(function(){var n=Pe.clip().$node;function r(e){return e.type==="mousedown"&&e.buttons===2||e.type==="contextmenu"}ne.on("contextmenu.terminal mousedown.terminal",function(e){if(get_selected_html()===""&&r(e)){if(!$(e.target).is("img,value,audio,object,canvas,a")){if(!ne.enabled()){ne.enable()}var t=Pe.offset();n.css({left:e.pageX-t.left-20,top:e.pageY-t.top-20,width:"5em",height:"4em"});if(!n.is(":focus")){n.focus()}ne.stopTime("textarea");ne.oneTime(100,"textarea",function(){var e={left:"",top:"",width:"",height:""};if(!is_css_variables_supported){var t=ne.find(".cmd .cmd-cursor-line").prevUntil(".cmd-prompt").length;e.top=t*14+"px"}n.css(e)});ne.stopTime("selection");ne.everyTime(20,"selection",function(){if(n[0].selection!==n[0].value){if(get_textarea_selection(n[0])){clear_textarea_selection(n[0]);select(ne.find(".terminal-output")[0],ne.find(".cmd div:last-of-type")[0]);ne.stopTime("selection")}}})}}})})()}ne.on("click","a",function(e){var t=$(this);if(t.closest(".terminal-exception").length){var n=t.attr("href");if(n.match(/:[0-9]+$/)){e.preventDefault();m(n,ne.cols())}}if(Re){ne.find(".cmd textarea").focus()}});function i(){var e=ke.width;ke=get_char_size(ne);if(e!==ke.width){Pe.option("char_width",ke.width).refresh()}}a();function a(){if(ne.is(":visible")){var e=Ue.width();var t=Ue.height();if(xe!==t||Ee!==e){ne.resize()}xe=t;Ee=e}}function o(){var e={prefix:"terminal-"};ne.resizer("unbind").resizer(a,e);Me.resizer("unbind").resizer(function(){i();ne.resize()},e)}function u(e){ye=e[0].intersectionRatio===1}function s(){if(window.IntersectionObserver){var e=$('
').appendTo(ne);var t=e;if(Fe.scrollBottomOffset!==-1){t=$("
").css({height:Fe.scrollBottomOffset}).appendTo(e)}be=new IntersectionObserver(u,{root:ne[0]});be.observe(t[0])}}s();if(ne.is(":visible")){o()}function l(){if(Ie){if(Ie.unobserve){Ie.unobserve(ne[0])}else{clearInterval(Ie)}}var e=ne.enabled();var t=ne.is(":visible");if(e&&!t){ne.disable()}if(t){o()}else{He.css("visibility","hidden")}function n(){if(ne.is(":visible")&&!t){t=true;o();i();a();if(e){ne.enable()}He.css("visibility","")}else if(t&&!ne.is(":visible")){t=false;e=$.terminal.active()===ne&&ne.enabled();ne.disable();He.css("visibility","hidden")}}if(window.IntersectionObserver&&ne.css("position")!=="fixed"){Ie=new IntersectionObserver(n,{root:null});Ie.observe(ne[0])}else{Ie=setInterval(n,100)}}var f=!!ne.closest("body").length;var c=window.MutationObserver||window.WebKitMutationObserver;if(c){Ne=new c(function(){if(ne.closest("body").length){if(!f){ne.scroll_to_bottom();l();a()}f=true}else if(f){f=false}});Ne.observe(document.body,{childList:true})}if(f){l()}ve.resolve();if(Re&&ne.is(":visible")&&!is_mobile){ne.focus(undefined,true)}else{ne.disable()}if(is_function(Je)){ne.login(Je,true,Q)}else{Q()}function p(e){var t=terminals.get()[e[0]];if(t&&fe===t.id()){if(!e[2]){n.resolve();return n.promise()}else if(je){var n=$.Deferred();z.push(function(){return t.exec(e[2]).done(function(){t.save_state(e[2],true,e[1]);n.resolve()})});return n.promise()}else{return t.exec(e[2]).done(function(){t.save_state(e[2],true,e[1])})}}}if(Fe.execHash){if(location.hash){setTimeout(function(){try{var e=location.hash.replace(/^#/,"");hash_commands=JSON.parse(decodeURIComponent(e));var n=0;(function e(){var t=hash_commands[n++];if(t){p(t).done(e)}else{change_hash=true}})()}catch(e){}})}else{change_hash=true}}else{change_hash=true}(function(){var i=false;$(document).bind("keydown.terminal_"+ne.id(),function(e){if(e.shiftKey){i=true}}).bind("keyup.terminal_"+ne.id(),function(e){if(e.shiftKey||e.which===16){i=false}});function n(e,t){if(!i){var n=Oe.top();var r;if(is_function(n.mousewheel)){r=n.mousewheel(e,t,ne)}else if(is_function(Fe.mousewheel)){r=Fe.mousewheel(e,t,ne)}if(r===true){return}if((B()||r===false)&&!e.ctrlKey){e.stopPropagation();e.preventDefault()}if(r===false){return false}if(t>0){ne.scroll(-40)}else{ne.scroll(40)}}}if($.event.special.mousewheel){ne.on("mousewheel",n)}else{var r;var e=document.createElement("div");if("onwheel"in e){r="wheel"}else if(document.onmousewheel!==undefined){r="mousewheel"}else{r="DOMMouseScroll"}e=null;ne.on(r,function(e){var t;if(r==="mousewheel"){t=-1/40*e.originalEvent.wheelDelta}else{t=e.originalEvent.deltaY||e.originalEvent.detail}n(e,-t)})}ne.touch_scroll(function(e){var t=e.current.clientY-e.previous.clientY;var n;var r=Oe.top();if(is_function(r.touchscroll)){n=r.touchscroll(e,t,ne)}else if(is_function(Fe.touchscroll)){n=Fe.touchscroll(e,t,ne)}if(n===true){return}return false})})()});return ne}});
//# sourceMappingURL=jquery.terminal.min.js.map
\ No newline at end of file
diff --git a/js/jquery.terminal.min.js.map b/js/jquery.terminal.min.js.map
index 3e3bf380f..c3e3a7449 100644
--- a/js/jquery.terminal.min.js.map
+++ b/js/jquery.terminal.min.js.map
@@ -1 +1 @@
-{"version":3,"sources":["jquery.terminal.js"],"names":["ctx","sprintf","cache","hasOwnProperty","arguments","parse","format","call","parse_tree","argv","cursor","tree_length","length","node_type","arg","output","i","k","match","pad","pad_character","pad_length","get_type","push","test","toString","String","fromCharCode","parseInt","toExponential","parseFloat","toFixed","slice","toUpperCase","charAt","str_repeat","join","fmt","_fmt","arg_names","exec","field_list","replacement_field","field_match","vsprintf","_argv","splice","apply","variable","Object","prototype","toLowerCase","input","multiplier","global","window","factory","undefined","root","define","amd","jquery","wcwidth","module","exports","jQuery","require","$","debug","str","console","log","DelayQueue","callbacks","Callbacks","resolved","this","resolve","fire","add","fn","omap","o","result","each","v","text_length","map","text","get","reduce","a","b","Clone","clone_object","object","tmp","isArray","clone_array","key","array","is_function","Array","Error","item","bind","clone","Map","clear","forEach","value","delete","localStorage","hasLS","testKey","storage","setItem","removeItem","error","hasCookies","document","cookie","split","e","isLS","wls","n","c","wc","dt","Date","setTime","getTime","toGMTString","rls","rc","nn","ca","indexOf","dls","dc","extend","Storage","set","remove","debounce","FUNC_ERROR_TEXT","isObject","type","now","func","wait","options","nativeMax","Math","max","nativeMin","min","lastArgs","lastThis","maxWait","timerId","lastCallTime","lastInvokeTime","leading","maxing","trailing","TypeError","invokeFunc","time","args","thisArg","leadingEdge","setTimeout","timerExpired","remainingWait","timeSinceLastCall","timeSinceLastInvoke","timeWaiting","shouldInvoke","trailingEdge","cancel","clearTimeout","flush","debounced","isInvoking","everyTime","interval","label","times","belay","timer","oneTime","stopTime","guid","regex","powers","ms","cs","ds","s","das","hs","ks","timeParse","trim","num","mult","element","counter","isFunction","isNaN","constructor","Number","$timers","$timerID","handler","inProgress","setInterval","timers","ret","lab","clearInterval","_fn","navigator","userAgent","one","els","undef","nativeSplit","compliantExecNpcg","self","separator","limit","flags","ignoreCase","multiline","extended","sticky","lastLastIndex","separator2","lastIndex","lastLength","RegExp","source","index","replace","caret","pos","target","isContentEditable","contentEditable","getSelection","is","focus","range1","getRangeAt","range2","cloneRange","selectNodeContents","setEnd","endContainer","endOffset","selectionStart","selection","createRange","body","createTextRange","moveToElementText","setEndPoint","range","duplicate","bookmark","getBookmark","moveToBookmark","moveStart","collapse","focusNode","setSelectionRange","select","make_callback_plugin","factory_settings","init","noop","destroy","name","callback","trigger","unbind","data_name","$this","fireWith","data","has","removeData","resizer","settings","prefix","first","on","ResizeObserver","observe","iframe","addClass","appendTo","contentWindow","observer","unobserve","find","off","touch_scroll","origin","previous","originalEvent","tagName","touches","current","preventDefault","jquery_resolve","defer","Deferred","promise","unpromise","catch","done","then","is_fully_in_viewport","is_visible","node","container","box","getBoundingClientRect","viewport","top","bottom","height","IntersectionObserver","item_observer","entries","isIntersecting","ratio","entity_re","combine_chr_re","astral_symbols_re","emoji_re","mobile_re","tablet_re","format_split_re","format_parts_re","format_re","format_exist_re","format_full_re","format_begin_re","format_start_re","format_end_re","self_closing_re","color_hex_re","url_re","url_nf_re","email_re","url_full_re","email_full_re","command_re","extended_command_re","format_exec_re","float_re","re_re","string_re","unclosed_strings_re","broken_image","use_broken_image","animation_supported","animation","domPrefixes","elm","createElement","style","animationName","agent","is_IE","is_IEMobile","is_ch_unit_supported","div","width","is_css_variables_supported","CSS","supports","is_android","is_key_native","KeyboardEvent","proto","getOwnPropertyDescriptor","is_mobile","check","substr","vendor","opera","ch_unit_bug","base","ch","space","css","obj","isPlainObject","keys","setProperty","getPropertyValue","a11y_hide","attr","role","aria-hidden","excepctions","alert_exception","terminal","Exception","message","exception_message","scrollbar_event","left","offset","outerWidth","clientX","fileName","Cycle","rotate","skip","defined","filter","append","front","restart","Boolean","Stack","is_array","size","pop","concat","WorkerCache","validation","action","onCache","_onCache","_action","_validation","_cache","validate","valid","History","memory","enabled","storage_key","JSON","stringify","new_data","reset","last","end","position","next","old","purge","enable","disable","toggle","cmd_index","cmd","defaults","mask","caseSensitiveSearch","historySize","prompt","history","onPositionChange","onCommandChange","inputStyle","mobileDelete","onPaste","clickTimeout","holdTimeout","holdRepeatTimeout","mobileIngoreAutoSpace","repeatTimeoutKeys","tabindex","tabs","mobile_ignore_key","maybe_data","id","wrapper","clip","$node","autocapitalize","autocorrect","spellcheck","insertAfter","val","html","blur","removeAllRanges","num_chars","char_width","last_rendered_prompt","prompt_last_line","prompt_len","prompt_node","reverse_search","rev_search_str","reverse_search_position","backup_prompt","command","last_command","kill_text","formatted_position","restart_animation","paste_count","line_marker","line_marker_re","get_char_pos","closest","parent","prevAll","prevUntil","key_mapping","SPACEBAR","UP","DOWN","LEFT","RIGHT","DEL","MULTIPLY","DIVIDE","SUBTRACT","ADD","ie_key_fix","get_key","combo","ctrlKey","metaKey","shiftKey","altKey","keycodes","3","6","8","9","12","13","16","17","18","19","20","27","28","29","30","31","32","33","34","35","36","37","38","39","40","41","42","43","44","45","46","48","49","50","51","52","53","54","55","56","57","91","93","144","145","181","182","183","186","187","188","189","190","191","192","219","220","221","222","224","225","246","247","248","249","250","251","letter","reversed_keycodes","which","keymap","default_keymap","ALT+D","delete_forward","clipboard","HOLD+ALT+D","hold","HOLD+DELETE","HOLD+SHIFT+DELETE","ENTER","historyFilter","prev_command","no_keydown","commands","draw_prompt","SHIFT+ENTER","insert","BACKSPACE","backspace_key","SHIFT+BACKSPACE","TAB","CTRL+D","DELETE","HOLD+ARROWUP","up_arrow","ARROWUP","CTRL+P","prev_history","ARROWDOWN","down_arrow","HOLD+ARROWDOWN","CTRL+N","next_history","ARROWLEFT","HOLD+ARROWLEFT","CTRL+B","CTRL+ARROWLEFT","len","CTRL+R","reverse_history_search","draw_reverse_prompt","redraw","CTRL+G","ARROWRIGHT","right","HOLD+ARROWRIGHT","CTRL+F","CTRL+ARROWRIGHT","re","bare_text","F12","return_true","END","CTRL+END","CTRL+E","HOME","home","CTRL+HOME","CTRL+A","SHIFT+INSERT","paste_event","CTRL+SHIFT+T","CTRL+W","delete_backward","HOLD+BACKSPACE","HOLD+SHIFT+BACKSPACE","CTRL+H","CTRL+X","CTRL+C","get_selected_html","CTRL+T","CTRL+Y","CTRL+V","META+V","CTRL+K","text_to_clipboard","CTRL+U","CTRL+TAB","META+`","META+R","META+L","delete_character_forward","delete_word_forward","substring","m","delete_character_backward","delete_word_backward","isenabled","paste","fix_textarea","first_up_history","have_newlines","string","have_wrapping","lengths","line","wrap","match_column","col","before","column","after","before_newline","include_prompt","lastIndexOf","lines","sum","mobile_focus","$clip","fix_cursor","getComputedStyle","_class","className","position_only","removeClass","new_cursor","insertBefore","animating","blink","toggleClass","clear_reverse_state","history_data","save_string","j","escape_regex","get_char_width","$prompt","get_num_chars","floor","process_cmd_line","split_equal","skip_empty","strip","nextUntil","escape_brackets","first_len","strlen","splitted","cmd_line_worker","_previous_value","_cols","get_splitted_command_line","formatting","skip_formatted_position","escape_formatting","format_options","unixFormattingEscapeBrackets","formatted","apply_formatters","normalize","stack","encoded","encode","allowedAttributes","partition","raw","start","prev","cursor_line","draw_cursor_line","end_line","cursor_end_line","before_str","c_before","cursor_len","lines_after","last_ins","lines_before","display","original_string","from_last","last_len","new_pos","line_index","current_len","msg","strings","redrawError","in_line","find_position","make_guess","opts","cmp","search_pos","guess","next_guess","codepoint_len","binary_search","chars","split_characters","prev_prompt_data","crlf","have_formatting","encoded_last_line","last_line","fire_change_command","clean","option","stay","removed","silent","new_keymap","original","bare_command","doc","keypress_event","keydown_event","input_event","user_prompt","should_redraw","relative","refresh","display_position","command_len","new_formatted_pos","visible","show","resize","new_num_chars","invoke_key","shortcut","ctrl","shift","alt","meta","Event","documentElement","keyCode","new_mask","skip_keypress","dead_key","single_key","no_keypress","no_key","backspace","process","hold_pause","skip_insert","prev_key","is_backspace","is_single","is_delay_key","specials","clear_reverse_search_key","skip_keydown","fake","exception","keydown","clear_hold","is_terminal_selected","keypress","normalized","inArray","event","chr","skip_input","get_next_character","keycode","charCodeAt","abs","was_down","count","$target","is_prompt","down","button","count_selfclosing_formatting","format_split","is_formatting","safe","char_len","make_re_fn","starts_with","make_next_char_fun","tests","m1","m2","match_entity","match_combo","match_emoji","astral_match","normalize_position","acc","char_width_prop","extra_css","bare","wide_characters","specs","arr","spec","make_string","compare_fn","more_args","mid","startContainer","parentNode","term","sel","rangeCount","appendChild","cloneContents","innerHTML","with_selection","ranges","addRange","process_selected_line","$self","hasClass","process_div","process_selected_html","stdout","$html","$cmd_lines","queryCommandSupported","$textarea","had_focus","writeText","execCommand","$text","get_textarea_selection","textarea","selectionEnd","clear_textarea_selection","common_string","matchCase","string_case","candidate","candidateLower","currentLower","trigger_terminal_change","terminals","onTerminalChange","setBaseAndExtent","setStart","childNodes","process_command","quotes","rest","args_quotes","version","date","color_names","valid_color","color","unclosed_strings","special","tracking_replace","rex","replacement","new_string","rep_string","new_position","last_index","c0","rep_len","iterate_formatting","is_space","is_open_formatting","is_escape_bracket","is_text","not_formatting","opening","next_iteration","char","is_next_space","prev_space","is_last","in_text","space_count","re_ent","braket","start_index","end_index","start_formatting","end_formatting","prev_index","_","semicolons","amp","keep_words","prev_format","first_index","line_length","last_bracket","can_break","stripped","text_len","after_index","new_index","closed_formatting","matched","sp","nested_formatting","get_inherit_style","ignore","__inherit__","test_lengths","formatter","__no_warn__","warn","formatters","apply_function_formatter","__meta__","found_position","partials","this_len","length_before","loop","position_partial","partial","linksNoReferrer","linksNoFollow","escape","anyLinks","filter_attr_names","names","allowed","filters","clean_data","add_attrs","attrs","rel_attr","rel","unshift","is_path","url","with_url_validation","valid_href","valid_src","background","data_text","style_str","text_decoration","extra","unescape_brackets","columns","cols","no_formatting","column_limit","whole","bracket","active","last_id","parse_argument","strict","parse_string","quote","parse_arguments","split_arguments","parse_command","split_command","parse_options","boolean","token","single","extended_command","invokeMethods","change_hash","eval","iterator","Symbol","replacer","search","new_formatter","Terminal_Exception","hidden","warnings","ids","jrpc","method","params","success","deferred","validJSONRPC","response","isNumeric","request","jsonrpc","ajax","beforeSend","jxhr","status","jqXHR","content_type","getResponseHeader","json","reject","contentType","dataType","async","terminal_ready","get_char_size","rect","visiblity","temp","char_size","get_num_rows","all","same","same_case","is_promise","version_set","copyright","version_string","reg","name_ver","signatures","exit","maskChar","checkArity","exceptionHandler","pauseEvents","softPause","mousewheel","touchscroll","cancelableAjax","processArguments","processRPCResponse","completionEscape","convertLinks","scrollObject","historyState","importHistory","echoCommand","scrollOnEcho","login","outputLimit","onAjaxError","pasteImage","scrollBottomOffset","wordAutocomplete","caseSensitiveAutocomplete","describe","onRPCError","doubleTab","doubleTabEchoCommand","ansiParser","completion","onInit","onClear","onBlur","onFocus","onExit","onPush","onPop","renderHandler","onAfterRedraw","onEchoCommand","onFlush","onBeforeCommand","onAfterCommand","onBeforeEcho","onAfterEcho","onBeforeLogin","onAfterLogout","onBeforeLogout","comletionParameters","wrongPasswordTryAgain","wrongPassword","ajaxAbortError","wrongArity","commandNotFound","oneRPCWithIgnore","oneInterpreterFunction","loginFunctionMissing","noTokenError","serverResponse","wrongGreetings","notWhileLogin","loginIsNotAFunction","canExitError","invalidCompletion","invalidSelector","invalidTerminalId","password","recursiveLoop","notAString","invalidStrings","defunctTerminal","requests","save_state","hash_commands","fire_hash_change","first_instance","init_interpreter","StorageHelper","get_processed_command","preprocess_value","is_node","unmount","prepare_render","finalize","replaceWith","render","echo","get_node","Element","display_object","print_line","url_spec","pause","file","code","resume","display_json_rpc_error","at","make_basic_json_rpc","auth","interpreter","display_exception","ajax_error","make_object_interpreter","arity","fallback","user_command","onCommandNotFound","xhr","responseText","make_json_rpc_object","jrpc_success","jrpc_request","jrpc_response","procs","field","interpreter_object","proc","args_len","help","found","make_interpreter","user_intrp","rpc_count","fn_interpreter","recur","interpreters","new_obj","make_json_rpc_login","user","passwd","output_buffer","NEW_LINE","format_cache","buffer_line","use_cache","useCache","format_buff","newline","links","escaped","should_wrap","string_cache","process_line","line_settings","stringify_value","parts","prev_exec_cmd","words","keepWords","update","scroll","command_line","detached_output","empty","detach","lines_to_show","rows","pivot","fire_event","limit_lines","$lines","for_remove","parents","show_greetings","greetings","signature","make_label_error","echo_command","get_command","have_scrollbar","fill","restore_state","command_idx","import_view","export_view","maybe_update_hash","location","hash","first_command","resume_callbacks","init_state","execHash","after_exec","saved_change_hash","invoke","force_awake","when","paused","ghost","level","logout","in_login","get_token","set_token","global_logout","clear_loging_storage","global_login_fn","initialize","prefix_name","maybe_append_name","interpreter_name","prepare_top_interpreter","login_name","context_callback_proxy","fun","init_queue","onStart","skip_local","scroll_to_view","scroll_to","it","make_cursor_visible","hashchange","decodeURIComponent","was_paused","onPause","user_key_down","get_position","set_command","CTRL+L","orignal","caseSensitive","before_cursor","complete","word","scroll_to_bottom","PAGEDOWN","PAGEUP","key_down","tab_count","r","readyState","abort","key_press","ready","queue","selector","body_terminal","terminal_id","prop","scrollTop","user_export","get_prompt","view","when_ready","set_prompt","ignore_hash","state","d","cmd_ready","delayed_commands","autologin","infinite","logins","popUserPass","login_callback","set_mask","pass","cmd_strings","double_quotes","single_quote","prev_string","sensitive","slash","matched_strings","pre","post","to_insert","set_position","reverse","common","set_interpreter","overwrite_interpreter","numChars","numRows","num_rows","history_state","run","setImmediate","clear_history_state","x","animate","freeze","frozen","clear_cache","is_bottom","get_output","new_num_rows","self_offset","--terminal-x","--terminal-y","e1","e2","remove_line","arg_defined","locals","img","Image","onerror","src","lineNumber","trace","amount","round","local","local_name","intrp","read","infiniteLogin","push_settings","object_or_name","font_resizer","blur_terminal","focus_terminal","visibility_observer","scroll_marker","is_bottom_observer","mutation_observer","disconnect","$body","removeAttr","defunct","elem","scrollHeight","is_bottom_detected","scroll_height","scroll_top","offsetHeight","command_queue","old_width","old_height","old_enabled","ignoreSystemDescribe","hide","base_interpreter","parseObject","proxy","is_type","echo_image","image","data_uri","blob","URL","webkitURL","createObjectURL","ignoreEvents","Blob","clipboardData","items","getAsFile","getAsString","getData","onResize","elementFromPoint","clientY","$win","addEventListener","move","SENSITIVITY","HOLD_TIME","touch_event","point","y","diff_x","diff_y","click","ignore_elements","mousedown","mouseup","timeout","dblclick","is_context_event","buttons","pageX","pageY","props","href","calculate_char_size","create_resizers","bottom_detect","intersections","intersectionRatio","create_bottom_detect","marker","observe_visibility","was_enabled","visibility_checker","in_dom","MutationObsrv","MutationObserver","WebKitMutationObserver","childList","exec_spec","delta","stopPropagation","onmousewheel","wheelDelta","deltaY","detail"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAgDA,SAAUA,GACN,IAAIC,EAAU,WACV,IAAKA,EAAQC,MAAMC,eAAeC,UAAU,IAAK,CAC7CH,EAAQC,MAAME,UAAU,IAAMH,EAAQI,MAAMD,UAAU,IAE1D,OAAOH,EAAQK,OAAOC,KAAK,KAAMN,EAAQC,MAAME,UAAU,IAAKA,YAElEH,EAAQK,OAAS,SAASE,EAAYC,GAClC,IAAIC,EAAS,EAAGC,EAAcH,EAAWI,OAAQC,EAAY,GAAIC,EAAKC,EAAS,GAAIC,EAAGC,EAAGC,EAAOC,EAAKC,EAAeC,EACpH,IAAKL,EAAI,EAAGA,EAAIL,EAAaK,IAAK,CAC9BH,EAAYS,EAASd,EAAWQ,IAChC,GAAIH,IAAc,SAAU,CACxBE,EAAOQ,KAAKf,EAAWQ,SAEtB,GAAIH,IAAc,QAAS,CAC5BK,EAAQV,EAAWQ,GACnB,GAAIE,EAAM,GAAI,CACVJ,EAAML,EAAKC,GACX,IAAKO,EAAI,EAAGA,EAAIC,EAAM,GAAGN,OAAQK,IAAK,CAClC,IAAKH,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 __ ___ / /\n * __ / // // // // // _ // _// // / / // _ // _// // // \\/ // _ \\/ /\n * / / // // // // // ___// / / // / / // ___// / / / / // // /\\ // // / /__\n * \\___//____ \\\\___//____//_/ _\\_ / /_//____//_/ /_/ /_//_//_/ /_/ \\__\\_\\___/\n * \\/ /____/ version 2.15.2\n *\n * This file is part of jQuery Terminal. https://terminal.jcubic.pl\n *\n * Copyright (c) 2010-2020 Jakub T. Jankiewicz
e\n * Released under the MIT license\n *\n * Contains:\n *\n * Storage plugin Distributed under the MIT License\n * modified to work from Data URIs that block storage and cookies in Chrome\n * Copyright (c) 2010 Dave Schindler\n *\n * jQuery Timers licenced with the WTFPL\n * \n *\n * Cross-Browser Split 1.1.1\n * Copyright 2007-2012 Steven Levithan \n * Available under the MIT License\n *\n * jQuery Caret\n * Copyright (c) 2009, Gideon Sireling\n * 3 clause BSD License\n *\n * sprintf.js\n * Copyright (c) 2007-2013 Alexandru Marasteanu \n * licensed under 3 clause BSD license\n *\n * debounce function from Lodash\n * Copyright JS Foundation and other contributors \n * The MIT License\n *\n * emoji regex v7.0.1 by Mathias Bynens\n * MIT license\n *\n * broken image by Sophia Bai from the Noun Project (CC-BY)\n *\n * Date: Sat, 21 Mar 2020 11:26:31 +0000\n */\n/* global define, Map */\n/* eslint-disable */\n/* istanbul ignore next */\n(function(ctx) {\n var sprintf = function() {\n if (!sprintf.cache.hasOwnProperty(arguments[0])) {\n sprintf.cache[arguments[0]] = sprintf.parse(arguments[0]);\n }\n return sprintf.format.call(null, sprintf.cache[arguments[0]], arguments);\n };\n sprintf.format = function(parse_tree, argv) {\n var cursor = 1, tree_length = parse_tree.length, node_type = '', arg, output = [], i, k, match, pad, pad_character, pad_length;\n for (i = 0; i < tree_length; i++) {\n node_type = get_type(parse_tree[i]);\n if (node_type === 'string') {\n output.push(parse_tree[i]);\n }\n else if (node_type === 'array') {\n match = parse_tree[i]; // convenience purposes only\n if (match[2]) { // keyword argument\n arg = argv[cursor];\n for (k = 0; k < match[2].length; k++) {\n if (!arg.hasOwnProperty(match[2][k])) {\n throw(sprintf('[sprintf] property \"%s\" does not exist', match[2][k]));\n }\n arg = arg[match[2][k]];\n }\n }\n else if (match[1]) { // positional argument (explicit)\n arg = argv[match[1]];\n }\n else { // positional argument (implicit)\n arg = argv[cursor++];\n }\n\n if (/[^s]/.test(match[8]) && (get_type(arg) !== 'number')) {\n throw(sprintf('[sprintf] expecting number but found %s', get_type(arg)));\n }\n switch (match[8]) {\n case 'b': arg = arg.toString(2); break;\n case 'c': arg = String.fromCharCode(arg); break;\n case 'd': arg = parseInt(arg, 10); break;\n case 'e': arg = match[7] ? arg.toExponential(match[7]) : arg.toExponential(); break;\n case 'f': arg = match[7] ? parseFloat(arg).toFixed(match[7]) : parseFloat(arg); break;\n case 'o': arg = arg.toString(8); break;\n case 's': arg = ((arg = String(arg)) && match[7] ? arg.slice(0, match[7]) : arg); break;\n case 'u': arg = arg >>> 0; break;\n case 'x': arg = arg.toString(16); break;\n case 'X': arg = arg.toString(16).toUpperCase(); break;\n }\n arg = (/[def]/.test(match[8]) && match[3] && arg >= 0 ? ' +' + arg : arg);\n pad_character = match[4] ? match[4] === '0' ? '0' : match[4].charAt(1) : ' ';\n pad_length = match[6] - String(arg).length;\n pad = match[6] ? str_repeat(pad_character, pad_length) : '';\n output.push(match[5] ? arg + pad : pad + arg);\n }\n }\n return output.join('');\n };\n\n sprintf.cache = {};\n\n sprintf.parse = function(fmt) {\n var _fmt = fmt, match = [], parse_tree = [], arg_names = 0;\n while (_fmt) {\n if ((match = /^[^\\x25]+/.exec(_fmt)) !== null) {\n parse_tree.push(match[0]);\n }\n else if ((match = /^\\x25{2}/.exec(_fmt)) !== null) {\n parse_tree.push('%');\n }\n else if ((match = /^\\x25(?:([1-9]\\d*)\\$|\\(([^\\)]+)\\))?(\\+)?(0|'[^$])?(-)?(\\d+)?(?:\\.(\\d+))?([b-fosuxX])/.exec(_fmt)) !== null) {\n if (match[2]) {\n arg_names |= 1;\n var field_list = [], replacement_field = match[2], field_match = [];\n if ((field_match = /^([a-z_][a-z_\\d]*)/i.exec(replacement_field)) !== null) {\n field_list.push(field_match[1]);\n while ((replacement_field = replacement_field.slice(field_match[0].length)) !== '') {\n if ((field_match = /^\\.([a-z_][a-z_\\d]*)/i.exec(replacement_field)) !== null) {\n field_list.push(field_match[1]);\n }\n else if ((field_match = /^\\[(\\d+)\\]/.exec(replacement_field)) !== null) {\n field_list.push(field_match[1]);\n }\n else {\n throw('[sprintf] huh?');\n }\n }\n }\n else {\n throw('[sprintf] huh?');\n }\n match[2] = field_list;\n }\n else {\n arg_names |= 2;\n }\n if (arg_names === 3) {\n throw('[sprintf] mixing positional and named placeholders is not (yet) supported');\n }\n parse_tree.push(match);\n }\n else {\n throw('[sprintf] huh?');\n }\n _fmt = _fmt.slice(match[0].length);\n }\n return parse_tree;\n };\n\n var vsprintf = function(fmt, argv, _argv) {\n _argv = argv.slice(0);\n _argv.splice(0, 0, fmt);\n return sprintf.apply(null, _argv);\n };\n\n /**\n * helpers\n */\n function get_type(variable) {\n return Object.prototype.toString.call(variable).slice(8, -1).toLowerCase();\n }\n\n function str_repeat(input, multiplier) {\n for (var output = []; multiplier > 0; output[--multiplier] = input) {/* do nothing */}\n return output.join('');\n }\n\n /**\n * export to either browser or node.js\n */\n ctx.sprintf = sprintf;\n ctx.vsprintf = vsprintf;\n})(typeof global !== \"undefined\" ? global : window);\n// -----------------------------------------------------------------------\n/* eslint-enable */\n// UMD taken from https://github.com/umdjs/umd\n(function(factory, undefined) {\n var root = typeof window !== 'undefined' ? window : global;\n if (typeof define === 'function' && define.amd) {\n // AMD. Register as an anonymous module.\n // istanbul ignore next\n define(['jquery', 'wcwidth'], function(jquery, wcwidth) {\n factory(jquery, wcwidth, root);\n return jquery;\n });\n } else if (typeof module === 'object' && module.exports) {\n // Node/CommonJS\n module.exports = function(root, jQuery, wcwidth) {\n if (jQuery === undefined) {\n // require('jQuery') returns a factory that requires window to\n // build a jQuery instance, we normalize how we use modules\n // that require this pattern but the window provided is a noop\n // if it's defined (how jquery works)\n if (window !== undefined) {\n jQuery = require('jquery');\n } else {\n jQuery = require('jquery')(root);\n }\n }\n if (wcwidth === undefined) {\n wcwidth = require('wcwidth');\n }\n factory(jQuery, wcwidth, root);\n return jQuery;\n };\n } else {\n // Browser\n // istanbul ignore next\n factory(root.jQuery, root.wcwidth, root);\n }\n})(function($, wcwidth, root, undefined) {\n 'use strict';\n // -----------------------------------------------------------------------\n // :: debug functions\n // -----------------------------------------------------------------------\n /* eslint-disable */\n /* istanbul ignore next */\n function debug(str) {\n if (false) {\n console.log(str);\n //$.terminal.active().echo(str);\n }\n }\n /* eslint-enable */\n // -----------------------------------------------------------------------\n // :: Replacemenet for jQuery 2 deferred objects\n // -----------------------------------------------------------------------\n function DelayQueue() {\n var callbacks = $.Callbacks();\n var resolved = false;\n this.resolve = function() {\n callbacks.fire();\n resolved = true;\n };\n this.add = function(fn) {\n if (resolved) {\n fn();\n } else {\n callbacks.add(fn);\n }\n };\n }\n // -----------------------------------------------------------------------\n // :: map object to object\n // -----------------------------------------------------------------------\n $.omap = function(o, fn) {\n var result = {};\n $.each(o, function(k, v) {\n result[k] = fn.call(o, k, v);\n });\n return result;\n };\n $.fn.text_length = function() {\n return this.map(function() {\n return $(this).text().length;\n }).get().reduce(function(a, b) {\n return a + b;\n }, 0);\n };\n // -----------------------------------------------------------------------\n // :: Deep clone of objects and arrays\n // -----------------------------------------------------------------------\n var Clone = {\n clone_object: function(object) {\n var tmp = {};\n if (typeof object === 'object') {\n if ($.isArray(object)) {\n return this.clone_array(object);\n } else if (object === null) {\n return object;\n } else {\n for (var key in object) {\n if ($.isArray(object[key])) {\n tmp[key] = this.clone_array(object[key]);\n } else if (typeof object[key] === 'object') {\n tmp[key] = this.clone_object(object[key]);\n } else {\n tmp[key] = object[key];\n }\n }\n }\n }\n return tmp;\n },\n clone_array: function(array) {\n if (!is_function(Array.prototype.map)) {\n throw new Error(\"Your browser don't support ES5 array map \" +\n 'use es5-shim');\n }\n return array.slice(0).map(function(item) {\n if (typeof item === 'object') {\n return this.clone_object(item);\n } else {\n return item;\n }\n }.bind(this));\n }\n };\n var clone = function(object) {\n return Clone.clone_object(object);\n };\n // -----------------------------------------------------------------------\n // IE11 polyfill\n // -----------------------------------------------------------------------\n /* eslint-disable */\n if (!('clear' in Map.prototype)) {\n Map.prototype.clear = function() {\n this.forEach(function(value, key, map) {\n map.delete(key);\n });\n };\n }\n // -----------------------------------------------------------------------\n // :: Storage plugin\n // -----------------------------------------------------------------------\n var localStorage;\n /* istanbul ignore next */\n (function() {\n var hasLS = function() {\n try {\n var testKey = 'test', storage = window.localStorage;\n storage.setItem(testKey, '1');\n storage.removeItem(testKey);\n return true;\n } catch (error) {\n return false;\n }\n };\n var hasCookies = function() {\n try {\n document.cookie.split(';');\n return true;\n } catch (e) {\n return false;\n }\n };\n // Private data\n var isLS = hasLS();\n // Private functions\n function wls(n, v) {\n var c;\n if (typeof n === 'string' && typeof v === 'string') {\n localStorage[n] = v;\n return true;\n } else if (typeof n === 'object' && typeof v === 'undefined') {\n for (c in n) {\n if (n.hasOwnProperty(c)) {\n localStorage[c] = n[c];\n }\n }\n return true;\n }\n return false;\n }\n function wc(n, v) {\n var dt, e, c;\n dt = new Date();\n dt.setTime(dt.getTime() + 31536000000);\n e = '; expires=' + dt.toGMTString();\n if (typeof n === 'string' && typeof v === 'string') {\n document.cookie = n + '=' + v + e + '; path=/';\n return true;\n } else if (typeof n === 'object' && typeof v === 'undefined') {\n for (c in n) {\n if (n.hasOwnProperty(c)) {\n document.cookie = c + '=' + n[c] + e + '; path=/';\n }\n }\n return true;\n }\n return false;\n }\n function rls(n) {\n return localStorage[n];\n }\n function rc(n) {\n var nn, ca, i, c;\n nn = n + '=';\n ca = document.cookie.split(';');\n for (i = 0; i < ca.length; i++) {\n c = ca[i];\n while (c.charAt(0) === ' ') {\n c = c.slice(1, c.length);\n }\n if (c.indexOf(nn) === 0) {\n return c.slice(nn.length, c.length);\n }\n }\n return null;\n }\n function dls(n) {\n return delete localStorage[n];\n }\n function dc(n) {\n return wc(n, '', -1);\n }\n /**\n * Public API\n * $.Storage.set(\"name\", \"value\")\n * $.Storage.set({\"name1\":\"value1\", \"name2\":\"value2\", etc})\n * $.Storage.get(\"name\")\n * $.Storage.remove(\"name\")\n */\n if (!hasCookies() && !isLS) {\n localStorage = {};\n $.extend({\n Storage: {\n set: wls,\n get: rls,\n remove: dls\n }\n });\n } else {\n if (isLS) {\n localStorage = window.localStorage;\n }\n $.extend({\n Storage: {\n set: isLS ? wls : wc,\n get: isLS ? rls : rc,\n remove: isLS ? dls : dc\n }\n });\n }\n })();\n // -----------------------------------------------------------------------\n // :: Debounce from Lodash\n // -----------------------------------------------------------------------\n /* istanbul ignore next */\n var debounce = (function() {\n var FUNC_ERROR_TEXT = 'Expected a function';\n function isObject(value) {\n var type = typeof value;\n return value != null && (type == 'object' || type == 'function');\n }\n function now() {\n return Date.now();\n }\n return function debounce(func, wait, options) {\n var nativeMax = Math.max,\n nativeMin = Math.min;\n\n var lastArgs,\n lastThis,\n maxWait,\n result,\n timerId,\n lastCallTime,\n lastInvokeTime = 0,\n leading = false,\n maxing = false,\n trailing = true;\n\n if (typeof func != 'function') {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n wait = wait || 0;\n if (isObject(options)) {\n leading = !!options.leading;\n maxing = 'maxWait' in options;\n maxWait = maxing ? nativeMax(options.maxWait || 0, wait) : maxWait;\n trailing = 'trailing' in options ? !!options.trailing : trailing;\n }\n\n function invokeFunc(time) {\n var args = lastArgs,\n thisArg = lastThis;\n\n lastArgs = lastThis = undefined;\n lastInvokeTime = time;\n result = func.apply(thisArg, args);\n return result;\n }\n\n function leadingEdge(time) {\n // Reset any `maxWait` timer.\n lastInvokeTime = time;\n // Start the timer for the trailing edge.\n timerId = setTimeout(timerExpired, wait);\n // Invoke the leading edge.\n return leading ? invokeFunc(time) : result;\n }\n\n function remainingWait(time) {\n var timeSinceLastCall = time - lastCallTime,\n timeSinceLastInvoke = time - lastInvokeTime,\n timeWaiting = wait - timeSinceLastCall;\n\n return maxing\n ? nativeMin(timeWaiting, maxWait - timeSinceLastInvoke)\n : timeWaiting;\n }\n\n function shouldInvoke(time) {\n var timeSinceLastCall = time - lastCallTime,\n timeSinceLastInvoke = time - lastInvokeTime;\n\n // Either this is the first call, activity has stopped and we're at the\n // trailing edge, the system time has gone backwards and we're treating\n // it as the trailing edge, or we've hit the `maxWait` limit.\n return (lastCallTime === undefined || (timeSinceLastCall >= wait) ||\n (timeSinceLastCall < 0) || (maxing && timeSinceLastInvoke >= maxWait));\n }\n\n function timerExpired() {\n var time = now();\n if (shouldInvoke(time)) {\n return trailingEdge(time);\n }\n // Restart the timer.\n timerId = setTimeout(timerExpired, remainingWait(time));\n }\n\n function trailingEdge(time) {\n timerId = undefined;\n\n // Only invoke if we have `lastArgs` which means `func` has been\n // debounced at least once.\n if (trailing && lastArgs) {\n return invokeFunc(time);\n }\n lastArgs = lastThis = undefined;\n return result;\n }\n\n function cancel() {\n if (timerId !== undefined) {\n clearTimeout(timerId);\n }\n lastInvokeTime = 0;\n lastArgs = lastCallTime = lastThis = timerId = undefined;\n }\n\n function flush() {\n return timerId === undefined ? result : trailingEdge(now());\n }\n\n function debounced() {\n var time = now(),\n isInvoking = shouldInvoke(time);\n\n lastArgs = arguments;\n lastThis = this;\n lastCallTime = time;\n\n if (isInvoking) {\n if (timerId === undefined) {\n return leadingEdge(lastCallTime);\n }\n if (maxing) {\n // Handle invocations in a tight loop.\n timerId = setTimeout(timerExpired, wait);\n return invokeFunc(lastCallTime);\n }\n }\n if (timerId === undefined) {\n timerId = setTimeout(timerExpired, wait);\n }\n return result;\n }\n debounced.cancel = cancel;\n debounced.flush = flush;\n return debounced;\n };\n })();\n // -----------------------------------------------------------------------\n // :: jQuery Timers\n // -----------------------------------------------------------------------\n var jQuery = $;\n /* istanbul ignore next */\n (function($) {\n jQuery.fn.extend({\n everyTime: function(interval, label, fn, times, belay) {\n return this.each(function() {\n jQuery.timer.add(this, interval, label, fn, times, belay);\n });\n },\n oneTime: function(interval, label, fn) {\n return this.each(function() {\n jQuery.timer.add(this, interval, label, fn, 1);\n });\n },\n stopTime: function(label, fn) {\n return this.each(function() {\n jQuery.timer.remove(this, label, fn);\n });\n }\n });\n\n jQuery.extend({\n timer: {\n guid: 1,\n global: {},\n regex: /^([0-9]+)\\s*(.*s)?$/,\n powers: {\n // Yeah this is major overkill...\n 'ms': 1,\n 'cs': 10,\n 'ds': 100,\n 's': 1000,\n 'das': 10000,\n 'hs': 100000,\n 'ks': 1000000\n },\n timeParse: function(value) {\n if (value === undefined || value === null) {\n return null;\n }\n var result = this.regex.exec(jQuery.trim(value.toString()));\n if (result[2]) {\n var num = parseInt(result[1], 10);\n var mult = this.powers[result[2]] || 1;\n return num * mult;\n } else {\n return value;\n }\n },\n add: function(element, interval, label, fn, times, belay) {\n var counter = 0;\n\n if (jQuery.isFunction(label)) {\n if (!times) {\n times = fn;\n }\n fn = label;\n label = interval;\n }\n\n interval = jQuery.timer.timeParse(interval);\n\n if (typeof interval !== 'number' ||\n isNaN(interval) ||\n interval <= 0) {\n return;\n }\n if (times && times.constructor !== Number) {\n belay = !!times;\n times = 0;\n }\n\n times = times || 0;\n belay = belay || false;\n\n if (!element.$timers) {\n element.$timers = {};\n }\n if (!element.$timers[label]) {\n element.$timers[label] = {};\n }\n fn.$timerID = fn.$timerID || this.guid++;\n\n var handler = function() {\n if (belay && handler.inProgress) {\n return;\n }\n handler.inProgress = true;\n if ((++counter > times && times !== 0) ||\n fn.call(element, counter) === false) {\n jQuery.timer.remove(element, label, fn);\n }\n handler.inProgress = false;\n };\n\n handler.$timerID = fn.$timerID;\n\n if (!element.$timers[label][fn.$timerID]) {\n element.$timers[label][fn.$timerID] = window.setInterval(handler, interval);\n }\n\n if (!this.global[label]) {\n this.global[label] = [];\n }\n this.global[label].push(element);\n\n },\n remove: function(element, label, fn) {\n var timers = element.$timers, ret;\n\n if (timers) {\n\n if (!label) {\n for (var lab in timers) {\n if (timers.hasOwnProperty(lab)) {\n this.remove(element, lab, fn);\n }\n }\n } else if (timers[label]) {\n if (fn) {\n if (fn.$timerID) {\n window.clearInterval(timers[label][fn.$timerID]);\n delete timers[label][fn.$timerID];\n }\n } else {\n for (var _fn in timers[label]) {\n if (timers[label].hasOwnProperty(_fn)) {\n window.clearInterval(timers[label][_fn]);\n delete timers[label][_fn];\n }\n }\n }\n\n for (ret in timers[label]) {\n if (timers[label].hasOwnProperty(ret)) {\n break;\n }\n }\n if (!ret) {\n ret = null;\n delete timers[label];\n }\n }\n\n for (ret in timers) {\n if (timers.hasOwnProperty(ret)) {\n break;\n }\n }\n if (!ret) {\n element.$timers = null;\n }\n }\n }\n }\n });\n if (/(msie) ([\\w.]+)/.exec(navigator.userAgent.toLowerCase())) {\n $(window).one('unload', function() {\n var global = jQuery.timer.global;\n for (var label in global) {\n if (global.hasOwnProperty(label)) {\n var els = global[label], i = els.length;\n while (--i) {\n jQuery.timer.remove(els[i], label);\n }\n }\n }\n });\n }\n })(jQuery);\n // -----------------------------------------------------------------------\n // :: CROSS BROWSER SPLIT\n // -----------------------------------------------------------------------\n /* istanbul ignore next */\n (function(undef) {\n // prevent double include\n\n if (!String.prototype.split.toString().match(/\\[native/)) {\n return;\n }\n\n var nativeSplit = String.prototype.split,\n compliantExecNpcg = /()??/.exec(\"\")[1] === undef, // NPCG: nonparticipating capturing group\n self;\n\n self = function(str, separator, limit) {\n // If `separator` is not a regex, use `nativeSplit`\n if (Object.prototype.toString.call(separator) !== \"[object RegExp]\") {\n return nativeSplit.call(str, separator, limit);\n }\n var output = [],\n flags = (separator.ignoreCase ? \"i\" : \"\") +\n (separator.multiline ? \"m\" : \"\") +\n (separator.extended ? \"x\" : \"\") + // Proposed for ES6\n (separator.sticky ? \"y\" : \"\"), // Firefox 3+\n lastLastIndex = 0,\n // Make `global` and avoid `lastIndex` issues by working with a copy\n separator2, match, lastIndex, lastLength;\n separator = new RegExp(separator.source, flags + \"g\");\n str += \"\"; // Type-convert\n if (!compliantExecNpcg) {\n // Doesn't need flags gy, but they don't hurt\n separator2 = new RegExp(\"^\" + separator.source + \"$(?!\\\\s)\", flags);\n }\n /* Values for `limit`, per the spec:\n * If undefined: 4294967295 // Math.pow(2, 32) - 1\n * If 0, Infinity, or NaN: 0\n * If positive number: limit = Math.floor(limit); if (limit > 4294967295) limit -= 4294967296;\n * If negative number: 4294967296 - Math.floor(Math.abs(limit))\n * If other: Type-convert, then use the above rules\n */\n // ? Math.pow(2, 32) - 1 : ToUint32(limit)\n limit = limit === undef ? -1 >>> 0 : limit >>> 0;\n while (match = separator.exec(str)) {\n // `separator.lastIndex` is not reliable cross-browser\n lastIndex = match.index + match[0].length;\n if (lastIndex > lastLastIndex) {\n output.push(str.slice(lastLastIndex, match.index));\n // Fix browsers whose `exec` methods don't consistently return `undefined` for\n // nonparticipating capturing groups\n if (!compliantExecNpcg && match.length > 1) {\n match[0].replace(separator2, function() {\n for (var i = 1; i < arguments.length - 2; i++) {\n if (arguments[i] === undef) {\n match[i] = undef;\n }\n }\n });\n }\n if (match.length > 1 && match.index < str.length) {\n Array.prototype.push.apply(output, match.slice(1));\n }\n lastLength = match[0].length;\n lastLastIndex = lastIndex;\n if (output.length >= limit) {\n break;\n }\n }\n if (separator.lastIndex === match.index) {\n separator.lastIndex++; // Avoid an infinite loop\n }\n }\n if (lastLastIndex === str.length) {\n if (lastLength || !separator.test(\"\")) {\n output.push(\"\");\n }\n } else {\n output.push(str.slice(lastLastIndex));\n }\n return output.length > limit ? output.slice(0, limit) : output;\n };\n\n // For convenience\n String.prototype.split = function(separator, limit) {\n return self(this, separator, limit);\n };\n\n return self;\n\n })();\n // -----------------------------------------------------------------------\n // :: jQuery Caret\n // -----------------------------------------------------------------------\n /* istanbul ignore next */\n $.fn.caret = function(pos) {\n var target = this[0];\n var isContentEditable = target.contentEditable === 'true';\n //get\n if (arguments.length === 0) {\n //HTML5\n if (window.getSelection) {\n //contenteditable\n if (isContentEditable) {\n if (!this.is(':focus')) {\n target.focus();\n }\n var range1 = window.getSelection().getRangeAt(0),\n range2 = range1.cloneRange();\n range2.selectNodeContents(target);\n range2.setEnd(range1.endContainer, range1.endOffset);\n return range2.toString().length;\n }\n //textarea\n return target.selectionStart;\n }\n //IE<9\n if (document.selection) {\n target.focus();\n //contenteditable\n if (isContentEditable) {\n var range1 = document.selection.createRange(),\n range2 = document.body.createTextRange();\n range2.moveToElementText(target);\n range2.setEndPoint('EndToEnd', range1);\n return range2.text.length;\n }\n //textarea\n var pos = 0,\n range = target.createTextRange(),\n range2 = document.selection.createRange().duplicate(),\n bookmark = range2.getBookmark();\n range.moveToBookmark(bookmark);\n while (range.moveStart('character', -1) !== 0) pos++;\n return pos;\n }\n //not supported\n return 0;\n }\n //set\n if (pos === -1)\n pos = this[isContentEditable? 'text' : 'val']().length;\n //HTML5\n if (window.getSelection) {\n //contenteditable\n if (isContentEditable) {\n if (!this.is(':focus')) {\n target.focus();\n }\n var selection = window.getSelection();\n selection.collapse(selection.focusNode, pos);\n }\n //textarea\n else\n target.setSelectionRange(pos, pos);\n }\n //IE<9\n else if (document.body.createTextRange) {\n var range = document.body.createTextRange();\n range.moveToElementText(target);\n range.moveStart('character', pos);\n range.collapse(true);\n range.select();\n }\n if (!isContentEditable && !this.is(':focus')) {\n target.focus();\n }\n return pos;\n };\n /* eslint-enable */\n // -----------------------------------------------------------------------\n // :: callback based event handler plugin generator\n // -----------------------------------------------------------------------\n function make_callback_plugin(options) {\n var factory_settings = $.extend({\n init: $.noop,\n destroy: $.noop,\n name: 'event'\n }, options);\n return function(callback, options) {\n var trigger = arguments.length === 0;\n var unbind = arguments[0] === \"unbind\";\n if (!trigger && !unbind && !is_function(callback)) {\n throw new Error('Invalid argument, it need to a function or string ' +\n '\"unbind\" or no arguments.');\n }\n if (unbind) {\n callback = is_function(arguments[1]) ? arguments[1] : null;\n }\n var data_name = 'callbacks_' + factory_settings.name;\n return this.each(function() {\n var $this = $(this);\n var callbacks;\n function handler(arg) {\n callbacks.fireWith($this, [arg]);\n }\n if (trigger || unbind) {\n callbacks = $this.data(data_name);\n if (trigger) {\n callbacks && callbacks.fire();\n } else {\n if (callback && callbacks) {\n callbacks.remove(callback);\n if (!callbacks.has()) {\n callbacks = null;\n }\n } else {\n callbacks = null;\n }\n if (!callbacks) {\n $this.removeData(data_name);\n factory_settings.destroy.call(this, handler, options);\n }\n }\n } else if ($this.data(data_name)) {\n $(this).data(data_name).add(callback);\n } else {\n callbacks = $.Callbacks();\n callbacks.add(callback);\n $this.data(data_name, callbacks);\n factory_settings.init.call(this, handler, options);\n }\n });\n };\n }\n // -----------------------------------------------------------------------\n // :: Cross-browser resize element plugin using sentinel iframe or\n // :: resizeObserver\n // -----------------------------------------------------------------------\n $.fn.resizer = make_callback_plugin({\n name: 'resize',\n init: function(handler, options) {\n var settings = $.extend({\n prefix: ''\n }, options);\n var $this = $(this);\n var resizer;\n var first = true;\n if ($this.is('body')) {\n $(window).on('resize.resizer', handler);\n } else if (window.ResizeObserver) {\n resizer = new ResizeObserver(function() {\n if (!first) {\n handler();\n }\n first = false;\n });\n resizer.observe(this);\n $this.data('observer', resizer);\n } else {\n var iframe = $('').addClass(settings.prefix + 'resizer')\n .appendTo(this)[0];\n $(iframe.contentWindow).on('resize', handler);\n }\n },\n destroy: function() {\n var $this = $(this);\n if (window.ResizeObserver) {\n var observer = $this.data('observer');\n if (observer) {\n observer.unobserve(this);\n $this.removeData('observer');\n }\n } else {\n var iframe = $this.find('> iframe[class$=\"resizer\"]');\n if (iframe.length) {\n // just in case of memory leaks in IE\n $(iframe[0].contentWindow).off('resize').remove();\n iframe.remove();\n } else if ($this.is('body')) {\n $(window).off('resize.resizer');\n }\n }\n }\n });\n // -----------------------------------------------------------------------\n // :: mobile friendly scroll that work without scrollbar (for less)\n // -----------------------------------------------------------------------\n $.fn.touch_scroll = make_callback_plugin({\n name: 'touch',\n init: function(handler) {\n var origin;\n var previous;\n $(this).on('touchstart.scroll', function(e) {\n e = e.originalEvent;\n if (e.target.tagName.toLowerCase() !== 'a' && e.touches.length === 1) {\n previous = origin = e.touches[0];\n }\n }).on('touchmove.scroll', function(e) {\n e = e.originalEvent;\n if (origin && e.touches.length === 1) {\n var current = e.touches[0];\n var ret = handler({\n origin: origin,\n previous: previous,\n current: current\n });\n if (ret === false) {\n e.preventDefault();\n }\n previous = current;\n }\n }).on('touchend.scroll', function() {\n if (origin || previous) {\n origin = previous = null;\n }\n });\n },\n destroy: function() {\n $(this).off('touchstart.scroll touchmove.scroll touchend.scroll');\n }\n });\n // -----------------------------------------------------------------------\n function jquery_resolve(value) {\n var defer = jQuery.Deferred();\n defer.resolve(value);\n return defer.promise();\n }\n // -----------------------------------------------------------------------\n function unpromise(value, callback, error) {\n if (value !== undefined) {\n if (is_function(value.catch)) {\n value.catch(error);\n }\n if (is_function(value.done)) {\n return value.done(callback);\n } else if (is_function(value.then)) {\n return value.then(callback);\n } else {\n return callback(value);\n }\n }\n }\n // -----------------------------------------------------------------------\n // :: based on https://github.com/zeusdeux/isInViewport\n // :: work only vertically and on dom elements\n // -----------------------------------------------------------------------\n $.fn.is_fully_in_viewport = (function() {\n function is_visible(node, container) {\n var box = node.getBoundingClientRect();\n var viewport = container[0].getBoundingClientRect();\n var top = box.top - viewport.top;\n var bottom = box.bottom - viewport.top;\n var height = container.height();\n return bottom > 0 && top <= height;\n }\n if (window.IntersectionObserver) {\n return function(container) {\n var node = this[0];\n var defer = jQuery.Deferred();\n var item_observer = new window.IntersectionObserver(function(entries) {\n defer.resolve(entries[0].isIntersecting && entries[0].ratio === 1);\n item_observer.unobserve(node);\n }, {\n root: container[0]\n });\n item_observer.observe(node);\n return defer.promise();\n };\n } else {\n return function(container) {\n return jquery_resolve(is_visible(this[0], container));\n };\n }\n })();\n // -------------------------------------------------------------------------\n /* eslint-disable */\n var entity_re = /(&(?:[a-z\\d]+|#\\d+|#x[a-f\\d]+);)/i;\n // regex that match single character at begining and folowing combine character\n // https://en.wikipedia.org/wiki/Combining_character\n var combine_chr_re = /(.(?:[\\u0300-\\u036F]|[\\u1AB0-\\u1abE]|[\\u1DC0-\\u1DF9]|[\\u1DFB-\\u1DFF]|[\\u20D0-\\u20F0]|[\\uFE20-\\uFE2F])+)/;\n // source: https://mathiasbynens.be/notes/javascript-unicode\n var astral_symbols_re = /([\\uD800-\\uDBFF][\\uDC00-\\uDFFF])/;\n // source: https://github.com/mathiasbynens/emoji-regex\n var emoji_re = /(\\uD83C\\uDFF4(?:\\uDB40\\uDC67\\uDB40\\uDC62(?:\\uDB40\\uDC65\\uDB40\\uDC6E\\uDB40\\uDC67|\\uDB40\\uDC77\\uDB40\\uDC6C\\uDB40\\uDC73|\\uDB40\\uDC73\\uDB40\\uDC63\\uDB40\\uDC74)\\uDB40\\uDC7F|\\u200D\\u2620\\uFE0F)|\\uD83D\\uDC69\\u200D\\uD83D\\uDC69\\u200D(?:\\uD83D\\uDC66\\u200D\\uD83D\\uDC66|\\uD83D\\uDC67\\u200D(?:\\uD83D[\\uDC66\\uDC67]))|\\uD83D\\uDC68(?:\\u200D(?:\\u2764\\uFE0F\\u200D(?:\\uD83D\\uDC8B\\u200D)?\\uD83D\\uDC68|(?:\\uD83D[\\uDC68\\uDC69])\\u200D(?:\\uD83D\\uDC66\\u200D\\uD83D\\uDC66|\\uD83D\\uDC67\\u200D(?:\\uD83D[\\uDC66\\uDC67]))|\\uD83D\\uDC66\\u200D\\uD83D\\uDC66|\\uD83D\\uDC67\\u200D(?:\\uD83D[\\uDC66\\uDC67])|\\uD83C[\\uDF3E\\uDF73\\uDF93\\uDFA4\\uDFA8\\uDFEB\\uDFED]|\\uD83D[\\uDCBB\\uDCBC\\uDD27\\uDD2C\\uDE80\\uDE92]|\\uD83E[\\uDDB0-\\uDDB3])|(?:\\uD83C[\\uDFFB-\\uDFFF])\\u200D(?:\\uD83C[\\uDF3E\\uDF73\\uDF93\\uDFA4\\uDFA8\\uDFEB\\uDFED]|\\uD83D[\\uDCBB\\uDCBC\\uDD27\\uDD2C\\uDE80\\uDE92]|\\uD83E[\\uDDB0-\\uDDB3]))|\\uD83D\\uDC69\\u200D(?:\\u2764\\uFE0F\\u200D(?:\\uD83D\\uDC8B\\u200D(?:\\uD83D[\\uDC68\\uDC69])|\\uD83D[\\uDC68\\uDC69])|\\uD83C[\\uDF3E\\uDF73\\uDF93\\uDFA4\\uDFA8\\uDFEB\\uDFED]|\\uD83D[\\uDCBB\\uDCBC\\uDD27\\uDD2C\\uDE80\\uDE92]|\\uD83E[\\uDDB0-\\uDDB3])|\\uD83D\\uDC69\\u200D\\uD83D\\uDC66\\u200D\\uD83D\\uDC66|(?:\\uD83D\\uDC41\\uFE0F\\u200D\\uD83D\\uDDE8|\\uD83D\\uDC69(?:\\uD83C[\\uDFFB-\\uDFFF])\\u200D[\\u2695\\u2696\\u2708]|\\uD83D\\uDC68(?:(?:\\uD83C[\\uDFFB-\\uDFFF])\\u200D[\\u2695\\u2696\\u2708]|\\u200D[\\u2695\\u2696\\u2708])|(?:(?:\\u26F9|\\uD83C[\\uDFCB\\uDFCC]|\\uD83D\\uDD75)\\uFE0F|\\uD83D\\uDC6F|\\uD83E[\\uDD3C\\uDDDE\\uDDDF])\\u200D[\\u2640\\u2642]|(?:\\u26F9|\\uD83C[\\uDFCB\\uDFCC]|\\uD83D\\uDD75)(?:\\uD83C[\\uDFFB-\\uDFFF])\\u200D[\\u2640\\u2642]|(?:\\uD83C[\\uDFC3\\uDFC4\\uDFCA]|\\uD83D[\\uDC6E\\uDC71\\uDC73\\uDC77\\uDC81\\uDC82\\uDC86\\uDC87\\uDE45-\\uDE47\\uDE4B\\uDE4D\\uDE4E\\uDEA3\\uDEB4-\\uDEB6]|\\uD83E[\\uDD26\\uDD37-\\uDD39\\uDD3D\\uDD3E\\uDDB8\\uDDB9\\uDDD6-\\uDDDD])(?:(?:\\uD83C[\\uDFFB-\\uDFFF])\\u200D[\\u2640\\u2642]|\\u200D[\\u2640\\u2642])|\\uD83D\\uDC69\\u200D[\\u2695\\u2696\\u2708])\\uFE0F|\\uD83D\\uDC69\\u200D\\uD83D\\uDC67\\u200D(?:\\uD83D[\\uDC66\\uDC67])|\\uD83D\\uDC69\\u200D\\uD83D\\uDC69\\u200D(?:\\uD83D[\\uDC66\\uDC67])|\\uD83D\\uDC68(?:\\u200D(?:(?:\\uD83D[\\uDC68\\uDC69])\\u200D(?:\\uD83D[\\uDC66\\uDC67])|\\uD83D[\\uDC66\\uDC67])|\\uD83C[\\uDFFB-\\uDFFF])|\\uD83C\\uDFF3\\uFE0F\\u200D\\uD83C\\uDF08|\\uD83D\\uDC69\\u200D\\uD83D\\uDC67|\\uD83D\\uDC69(?:\\uD83C[\\uDFFB-\\uDFFF])\\u200D(?:\\uD83C[\\uDF3E\\uDF73\\uDF93\\uDFA4\\uDFA8\\uDFEB\\uDFED]|\\uD83D[\\uDCBB\\uDCBC\\uDD27\\uDD2C\\uDE80\\uDE92]|\\uD83E[\\uDDB0-\\uDDB3])|\\uD83D\\uDC69\\u200D\\uD83D\\uDC66|\\uD83C\\uDDF6\\uD83C\\uDDE6|\\uD83C\\uDDFD\\uD83C\\uDDF0|\\uD83C\\uDDF4\\uD83C\\uDDF2|\\uD83D\\uDC69(?:\\uD83C[\\uDFFB-\\uDFFF])|\\uD83C\\uDDED(?:\\uD83C[\\uDDF0\\uDDF2\\uDDF3\\uDDF7\\uDDF9\\uDDFA])|\\uD83C\\uDDEC(?:\\uD83C[\\uDDE6\\uDDE7\\uDDE9-\\uDDEE\\uDDF1-\\uDDF3\\uDDF5-\\uDDFA\\uDDFC\\uDDFE])|\\uD83C\\uDDEA(?:\\uD83C[\\uDDE6\\uDDE8\\uDDEA\\uDDEC\\uDDED\\uDDF7-\\uDDFA])|\\uD83C\\uDDE8(?:\\uD83C[\\uDDE6\\uDDE8\\uDDE9\\uDDEB-\\uDDEE\\uDDF0-\\uDDF5\\uDDF7\\uDDFA-\\uDDFF])|\\uD83C\\uDDF2(?:\\uD83C[\\uDDE6\\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B-\\uDFFF])|(?:[\\u231A\\u231B\\u23E9-\\u23EC\\u23F0\\u23F3\\u25FD\\u25FE\\u2614\\u2615\\u2648-\\u2653\\u267F\\u2693\\u26A1\\u26AA\\u26AB\\u26BD\\u26BE\\u26C4\\u26C5\\u26CE\\u26D4\\u26EA\\u26F2\\u26F3\\u26F5\\u26FA\\u26FD\\u2705\\u270A\\u270B\\u2728\\u274C\\u274E\\u2753-\\u2755\\u2757\\u2795-\\u2797\\u27B0\\u27BF\\u2B1B\\u2B1C\\u2B50\\u2B55]|\\uD83C[\\uDC04\\uDCCF\\uDD8E\\uDD91-\\uDD9A\\uDDE6-\\uDDFF\\uDE01\\uDE1A\\uDE2F\\uDE32-\\uDE36\\uDE38-\\uDE3A\\uDE50\\uDE51\\uDF00-\\uDF20\\uDF2D-\\uDF35\\uDF37-\\uDF7C\\uDF7E-\\uDF93\\uDFA0-\\uDFCA\\uDFCF-\\uDFD3\\uDFE0-\\uDFF0\\uDFF4\\uDFF8-\\uDFFF]|\\uD83D[\\uDC00-\\uDC3E\\uDC40\\uDC42-\\uDCFC\\uDCFF-\\uDD3D\\uDD4B-\\uDD4E\\uDD50-\\uDD67\\uDD7A\\uDD95\\uDD96\\uDDA4\\uDDFB-\\uDE4F\\uDE80-\\uDEC5\\uDECC\\uDED0-\\uDED2\\uDEEB\\uDEEC\\uDEF4-\\uDEF9]|\\uD83E[\\uDD10-\\uDD3A\\uDD3C-\\uDD3E\\uDD40-\\uDD45\\uDD47-\\uDD70\\uDD73-\\uDD76\\uDD7A\\uDD7C-\\uDDA2\\uDDB0-\\uDDB9\\uDDC0-\\uDDC2\\uDDD0-\\uDDFF])|(?:[#\\*0-9\\xA9\\xAE\\u203C\\u2049\\u2122\\u2139\\u2194-\\u2199\\u21A9\\u21AA\\u231A\\u231B\\u2328\\u23CF\\u23E9-\\u23F3\\u23F8-\\u23FA\\u24C2\\u25AA\\u25AB\\u25B6\\u25C0\\u25FB-\\u25FE\\u2600-\\u2604\\u260E\\u2611\\u2614\\u2615\\u2618\\u261D\\u2620\\u2622\\u2623\\u2626\\u262A\\u262E\\u262F\\u2638-\\u263A\\u2640\\u2642\\u2648-\\u2653\\u265F\\u2660\\u2663\\u2665\\u2666\\u2668\\u267B\\u267E\\u267F\\u2692-\\u2697\\u2699\\u269B\\u269C\\u26A0\\u26A1\\u26AA\\u26AB\\u26B0\\u26B1\\u26BD\\u26BE\\u26C4\\u26C5\\u26C8\\u26CE\\u26CF\\u26D1\\u26D3\\u26D4\\u26E9\\u26EA\\u26F0-\\u26F5\\u26F7-\\u26FA\\u26FD\\u2702\\u2705\\u2708-\\u270D\\u270F\\u2712\\u2714\\u2716\\u271D\\u2721\\u2728\\u2733\\u2734\\u2744\\u2747\\u274C\\u274E\\u2753-\\u2755\\u2757\\u2763\\u2764\\u2795-\\u2797\\u27A1\\u27B0\\u27BF\\u2934\\u2935\\u2B05-\\u2B07\\u2B1B\\u2B1C\\u2B50\\u2B55\\u3030\\u303D\\u3297\\u3299]|\\uD83C[\\uDC04\\uDCCF\\uDD70\\uDD71\\uDD7E\\uDD7F\\uDD8E\\uDD91-\\uDD9A\\uDDE6-\\uDDFF\\uDE01\\uDE02\\uDE1A\\uDE2F\\uDE32-\\uDE3A\\uDE50\\uDE51\\uDF00-\\uDF21\\uDF24-\\uDF93\\uDF96\\uDF97\\uDF99-\\uDF9B\\uDF9E-\\uDFF0\\uDFF3-\\uDFF5\\uDFF7-\\uDFFF]|\\uD83D[\\uDC00-\\uDCFD\\uDCFF-\\uDD3D\\uDD49-\\uDD4E\\uDD50-\\uDD67\\uDD6F\\uDD70\\uDD73-\\uDD7A\\uDD87\\uDD8A-\\uDD8D\\uDD90\\uDD95\\uDD96\\uDDA4\\uDDA5\\uDDA8\\uDDB1\\uDDB2\\uDDBC\\uDDC2-\\uDDC4\\uDDD1-\\uDDD3\\uDDDC-\\uDDDE\\uDDE1\\uDDE3\\uDDE8\\uDDEF\\uDDF3\\uDDFA-\\uDE4F\\uDE80-\\uDEC5\\uDECB-\\uDED2\\uDEE0-\\uDEE5\\uDEE9\\uDEEB\\uDEEC\\uDEF0\\uDEF3-\\uDEF9]|\\uD83E[\\uDD10-\\uDD3A\\uDD3C-\\uDD3E\\uDD40-\\uDD45\\uDD47-\\uDD70\\uDD73-\\uDD76\\uDD7A\\uDD7C-\\uDDA2\\uDDB0-\\uDDB9\\uDDC0-\\uDDC2\\uDDD0-\\uDDFF])\\uFE0F|(?:[\\u261D\\u26F9\\u270A-\\u270D]|\\uD83C[\\uDF85\\uDFC2-\\uDFC4\\uDFC7\\uDFCA-\\uDFCC]|\\uD83D[\\uDC42\\uDC43\\uDC46-\\uDC50\\uDC66-\\uDC69\\uDC6E\\uDC70-\\uDC78\\uDC7C\\uDC81-\\uDC83\\uDC85-\\uDC87\\uDCAA\\uDD74\\uDD75\\uDD7A\\uDD90\\uDD95\\uDD96\\uDE45-\\uDE47\\uDE4B-\\uDE4F\\uDEA3\\uDEB4-\\uDEB6\\uDEC0\\uDECC]|\\uD83E[\\uDD18-\\uDD1C\\uDD1E\\uDD1F\\uDD26\\uDD30-\\uDD39\\uDD3D\\uDD3E\\uDDB5\\uDDB6\\uDDB8\\uDDB9\\uDDD1-\\uDDDD]))/;\n // https://stackoverflow.com/questions/11381673/detecting-a-mobile-browser\n var mobile_re = /(android|bb\\d+|meego).+mobile|avantgo|bada\\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\\.(browser|link)|vodafone|wap|windows ce|xda|xiino|android|ipad|playbook|silk/i;\n var tablet_re = /1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\\-(n|u)|c55\\/|capi|ccwa|cdm\\-|cell|chtm|cldc|cmd\\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\\-s|devi|dica|dmob|do(c|p)o|ds(12|\\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\\-|_)|g1 u|g560|gene|gf\\-5|g\\-mo|go(\\.w|od)|gr(ad|un)|haie|hcit|hd\\-(m|p|t)|hei\\-|hi(pt|ta)|hp( i|ip)|hs\\-c|ht(c(\\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\\-(20|go|ma)|i230|iac( |\\-|\\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\\/)|klon|kpt |kwc\\-|kyo(c|k)|le(no|xi)|lg( g|\\/(k|l|u)|50|54|\\-[a-w])|libw|lynx|m1\\-w|m3ga|m50\\/|ma(te|ui|xo)|mc(01|21|ca)|m\\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\\-2|po(ck|rt|se)|prox|psio|pt\\-g|qa\\-a|qc(07|12|21|32|60|\\-[2-7]|i\\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\\-|oo|p\\-)|sdk\\/|se(c(\\-|0|1)|47|mc|nd|ri)|sgh\\-|shar|sie(\\-|m)|sk\\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\\-|v\\-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\\-|tdg\\-|tel(i|m)|tim\\-|t\\-mo|to(pl|sh)|ts(70|m\\-|m3|m5)|tx\\-9|up(\\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\\-|your|zeto|zte\\-/i;\n var format_split_re = /(\\[\\[(?:-?[@!gbiuso])*;[^;]*;[^\\]]*\\](?:[^\\]\\\\]*(?:\\\\\\\\)*\\\\\\][^\\]]*|[^\\]]*|[^[]*\\[[^\\]]*)\\]?)/i;\n var format_parts_re = /\\[\\[((?:-?[@!gbiuso])*);([^;]*);([^;\\]]*);?([^;\\]]*);?([^\\]]*)\\]([^\\]\\\\]*\\\\\\][^\\]]*|[^\\]]*|[^[]*\\[[^\\]]+)\\]?/gi;\n var format_re = /\\[\\[((?:-?[@!gbiuso])*;[^;\\]]*;[^;\\]]*(?:;|[^\\]()]*);?[^\\]]*)\\]([^\\]]*\\\\\\][^\\]]*|[^\\]]*|[^[]*\\[[^\\]]*)\\]?/gi;\n var format_exist_re = /\\[\\[((?:-?[@!gbiuso])*;[^;\\]]*;[^;\\]]*(?:;|[^\\]()]*);?[^\\]]*)\\]([^\\]]*\\\\\\][^\\]]*|[^\\]]*|[^[]*\\[[^\\]]*)\\]/gi;\n var format_full_re = /^(\\[\\[(?:(?:-?[@!gbiuso])*;[^;\\]]*;[^;\\]]*(?:;|[^\\]()]*);?[^\\]]*)\\])([^\\]]*\\\\\\][^\\]]*|[^\\]]*|[^[]*\\[[^\\]]*)(\\])$/i;\n var format_begin_re = /(\\[\\[(?:-?[@!gbiuso])*;[^;]*;[^\\]]*\\])/i;\n var format_start_re = /^(\\[\\[(?:-?[@!gbiuso])*;[^;]*;[^\\]]*\\])/i;\n var format_end_re = /\\[\\[(?:-?[@!gbiuso])*;[^;]*;[^\\]]*\\]?$/i;\n var self_closing_re = /^(?:\\[\\[)?[^;]*@[^;]*;/;\n var color_hex_re = /^#([0-9a-f]{3}|[0-9a-f]{6})$/i;\n var url_re = /(\\bhttps?:\\/\\/(?:(?:(?!&[^;]+;)|(?=&))[^\\s\"'<>\\][)])+)/gi;\n var url_nf_re = /\\b(?![^\"\\s[\\]]*])(https?:\\/\\/(?:(?:(?!&[^;]+;)|(?=&))[^\\s\"'<>\\][)])+)/gi;\n var email_re = /((([^<>('\")[\\]\\\\.,;:\\s@\"]+(\\.[^<>()[\\]\\\\.,;:\\s@\"]+)*)|(\".+\"))@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\])|(([a-zA-Z\\-0-9]+\\.)+[a-zA-Z]{2,})))/g;\n var url_full_re = /^(https?:\\/\\/(?:(?:(?!&[^;]+;)|(?=&))[^\\s\"'<>\\][)])+)$/gi;\n var email_full_re = /^((([^<>('\")[\\]\\\\.,;:\\s@\"]+(\\.[^<>()[\\]\\\\.,;:\\s@\"]+)*)|(\".+\"))@((\\[[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\])|(([a-zA-Z\\-0-9]+\\.)+[a-zA-Z]{2,})))$/g;\n var command_re = /((?:\"[^\"\\\\]*(?:\\\\[\\S\\s][^\"\\\\]*)*\"|'[^'\\\\]*(?:\\\\[\\S\\s][^'\\\\]*)*'|\\/[^\\/\\\\]*(?:\\\\[\\S\\s][^\\/\\\\]*)*\\/[gimsuy]*(?=\\s|$)|(?:\\\\\\s|\\S))+)(?=\\s|$)/gi;\n var extended_command_re = /^\\s*((terminal|cmd)::([a-z_]+)\\(([\\s\\S]*)\\))\\s*$/;\n var format_exec_re = /(\\[\\[(?:[^\\][]|\\\\\\])+\\]\\])/;\n var float_re = /^[-+]?[0-9]*\\.?[0-9]+([eE][-+]?[0-9]+)?$/;\n var re_re = /^\\/((?:\\\\\\/|[^/]|\\[[^\\]]*\\/[^\\]]*\\])+)\\/([gimsuy]*)$/;\n var string_re = /(\"(?:[^\"\\\\]|\\\\(?:\\\\\\\\)*\"|\\\\\\\\)*\"|'(?:[^'\\\\]|\\\\(?:\\\\\\\\)*'|\\\\\\\\)*')/;\n var unclosed_strings_re = /^(?=((?:[^\"']+|\"[^\"\\\\]*(?:\\\\[^][^\"\\\\]*)*\"|'[^'\\\\]*(?:\\\\[^][^'\\\\]*)*')*))\\1./;\n var broken_image = '';\n var use_broken_image = '';\n /* eslint-enable */\n // -------------------------------------------------------------------------\n // :: features flags\n // -------------------------------------------------------------------------\n // taken from https://hacks.mozilla.org/2011/09/detecting-and-generating-\n // css-animations-in-javascript/\n var animation_supported = (function() {\n var animation = false,\n domPrefixes = 'Webkit Moz O ms Khtml'.split(' '),\n elm = document.createElement('div');\n if (elm.style.animationName) {\n animation = true;\n }\n if (animation === false) {\n for (var i = 0; i < domPrefixes.length; i++) {\n var name = domPrefixes[i] + 'AnimationName';\n if (elm.style[name] !== undefined) {\n animation = true;\n break;\n }\n }\n }\n elm = null;\n return animation;\n })();\n // -------------------------------------------------------------------------\n var agent = window.navigator.userAgent;\n var is_IE = /MSIE|Trident/.test(agent) || /rv:11.0/i.test(agent);\n var is_IEMobile = /IEMobile/.test(agent);\n // -------------------------------------------------------------------------\n var is_ch_unit_supported = (function() {\n if (is_IE && !is_IEMobile) {\n return false;\n }\n var div = document.createElement('div');\n div.style.width = '1ch';\n return div.style.width === '1ch';\n })();\n // -------------------------------------------------------------------------\n var is_css_variables_supported = window.CSS && window.CSS.supports &&\n window.CSS.supports('--fake-var', 0);\n // -------------------------------------------------------------------------\n var is_android = navigator.userAgent.toLowerCase().indexOf('android') !== -1;\n // -------------------------------------------------------------------------\n var is_key_native = (function is_key_native() {\n if (!('KeyboardEvent' in window && 'key' in window.KeyboardEvent.prototype)) {\n return false;\n }\n var proto = window.KeyboardEvent.prototype;\n var get = Object.getOwnPropertyDescriptor(proto, 'key').get;\n return !!get.toString().match(/\\[native code\\]/);\n })();\n // -------------------------------------------------------------------------\n var is_mobile = (function(a) {\n var check = false;\n if (mobile_re.test(a) || tablet_re.test(a.substr(0, 4))) {\n check = true;\n }\n return check;\n })(navigator.userAgent || navigator.vendor || window.opera);\n\n // -------------------------------------------------------------------------\n // IE ch unit bug detection - better that UserAgent that can be changed\n // -------------------------------------------------------------------------\n var ch_unit_bug = false;\n $(function() {\n function width(e) {\n return e[0].getBoundingClientRect().width;\n }\n var base = ' ').appendTo('body');\n var space = $(base + '\"> ').appendTo('body');\n ch_unit_bug = width(ch) !== width(space);\n ch.remove();\n space.remove();\n });\n // -----------------------------------------------------------------------\n // :: css helper that work with css variables\n // :: jQuery css method from 3.4 support them by default\n // -----------------------------------------------------------------------\n function css(node, obj, value) {\n if ($.isPlainObject(obj)) {\n Object.keys(obj).forEach(function(key) {\n node.style.setProperty(key, obj[key]);\n });\n } else if (typeof value === 'undefined') {\n return node.style.getPropertyValue(obj);\n } else {\n node.style.setProperty(obj, value);\n }\n }\n // -----------------------------------------------------------------------\n // :: hide elements from screen readers\n // -----------------------------------------------------------------------\n function a11y_hide(element) {\n element.attr({\n role: 'presentation',\n 'aria-hidden': 'true'\n });\n }\n // ---------------------------------------------------------------------\n // :: alert only first exception of type\n // ---------------------------------------------------------------------\n var excepctions = [];\n function alert_exception(label, e) {\n if (arguments[0] instanceof $.terminal.Exception) {\n label = arguments[0].type;\n e = arguments[0];\n }\n var message = (label ? label + ': ' : '') + exception_message(e);\n if (excepctions.indexOf(message) === -1) {\n excepctions.push(message);\n setTimeout(function() {\n throw e;\n }, 0);\n //alert(message + (e.stack ? '\\n' + e.stack : ''));\n }\n }\n // ---------------------------------------------------------------------\n // :; detect if mouse event happen on scrollbar\n // ---------------------------------------------------------------------\n function scrollbar_event(e, node) {\n var left = node.offset().left;\n return node.outerWidth() <= e.clientX - left;\n }\n // ---------------------------------------------------------------------\n // :: Return exception message as string\n // ---------------------------------------------------------------------\n function exception_message(e) {\n if (typeof e === 'string') {\n return e;\n } else if (typeof e.fileName === 'string') {\n return e.fileName + ': ' + e.message;\n } else {\n return e.message;\n }\n }\n // -----------------------------------------------------------------------\n // :: CYCLE DATA STRUCTURE\n // -----------------------------------------------------------------------\n function Cycle() {\n var data = [].slice.call(arguments);\n var pos = 0;\n $.extend(this, {\n get: function() {\n return data;\n },\n index: function() {\n return pos;\n },\n rotate: function(skip, init) {\n if (init === undefined) {\n init = pos;\n } else if (init === pos) {\n return;\n }\n if (!skip) {\n var defined = data.filter(function(item) {\n return typeof item !== 'undefined';\n });\n if (!defined.length) {\n return;\n }\n }\n if (!data.length) {\n return;\n }\n if (data.length === 1) {\n return data[0];\n } else {\n if (pos === data.length - 1) {\n pos = 0;\n } else {\n ++pos;\n }\n if (typeof data[pos] !== 'undefined') {\n return data[pos];\n } else {\n return this.rotate(true, init);\n }\n }\n },\n length: function() {\n return data.length;\n },\n remove: function(index) {\n delete data[index];\n },\n set: function(item) {\n for (var i = data.length; i--;) {\n if (data[i] === item) {\n pos = i;\n return;\n }\n }\n this.append(item);\n pos = data.length - 1;\n },\n front: function() {\n if (data.length) {\n var index = pos;\n var restart = false;\n while (!data[index]) {\n index++;\n if (index > data.length) {\n if (restart) {\n break;\n }\n index = 0;\n restart = true;\n }\n }\n return data[index];\n }\n },\n map: function(fn) {\n return data.map(function(item, i) {\n if (typeof item !== 'undefined') {\n return fn(item, i);\n }\n return null;\n }).filter(Boolean);\n },\n forEach: function(fn) {\n return data.forEach(function(item, i) {\n if (typeof item !== 'undefined') {\n fn(item, i);\n }\n });\n },\n append: function(item) {\n data.push(item);\n }\n });\n }\n /*\n function time() {\n // performance.now almost equal Date.now()- performance.timing.navigationStart\n // the difference check should be almost the same\n return performance ? performance.now() : Date.now();\n }\n */\n // -----------------------------------------------------------------------\n // :: STACK DATA STRUCTURE\n // -----------------------------------------------------------------------\n function Stack(init) {\n var data = is_array(init) ? init : init ? [init] : [];\n $.extend(this, {\n data: function() {\n return data;\n },\n map: function(fn) {\n return $.map(data, fn);\n },\n size: function() {\n return data.length;\n },\n pop: function() {\n if (data.length === 0) {\n return null;\n } else {\n var value = data[data.length - 1];\n data = data.slice(0, data.length - 1);\n return value;\n }\n },\n push: function(value) {\n data = data.concat([value]);\n return value;\n },\n top: function() {\n return data.length > 0 ? data[data.length - 1] : null;\n },\n clone: function() {\n return new Stack(data.slice(0));\n }\n });\n }\n // -------------------------------------------------------------------------\n // :: Class for Worker that do some computation when needed\n // :: if validation function return false it mean that condition changed\n // :: and cache need to be cleared. If value was not prcessed it will run\n // :: the action\n // -------------------------------------------------------------------------\n function WorkerCache(options) {\n var settings = $.extend({\n validation: $.noop,\n action: $.noop,\n onCache: $.noop\n }, options);\n this._onCache = settings.onCache.bind(this);\n this._action = settings.action.bind(this);\n this._validation = settings.validation.bind(this);\n this._cache = new Map();\n }\n // -------------------------------------------------------------------------\n WorkerCache.prototype.validate = function(key) {\n var valid = this._validation(key);\n var test = valid === undefined || valid === true;\n if (!test) {\n this._cache.clear();\n }\n return test;\n };\n // -------------------------------------------------------------------------\n WorkerCache.prototype.get = function(key) {\n var value;\n if (this.validate(key) && this._cache.has(key)) {\n value = this._cache.get(key);\n this._onCache({cache: value});\n return value;\n }\n value = this._action(key);\n this._cache.set(key, value);\n return value;\n };\n // -------------------------------------------------------------------------\n // :: HISTORY CLASS\n // -------------------------------------------------------------------------\n function History(name, size, memory) {\n var enabled = true;\n var storage_key = '';\n if (typeof name === 'string' && name !== '') {\n storage_key = name + '_';\n }\n storage_key += 'commands';\n var data;\n if (memory) {\n data = [];\n } else {\n data = $.Storage.get(storage_key);\n data = data ? JSON.parse(data) : [];\n }\n var pos = data.length - 1;\n $.extend(this, {\n append: function(item) {\n if (enabled) {\n if (data[data.length - 1] !== item) {\n data.push(item);\n if (size && data.length > size) {\n data = data.slice(-size);\n }\n pos = data.length - 1;\n if (!memory) {\n $.Storage.set(storage_key, JSON.stringify(data));\n }\n }\n }\n },\n set: function(new_data) {\n if (is_array(new_data)) {\n data = new_data;\n if (!memory) {\n $.Storage.set(storage_key, JSON.stringify(data));\n }\n }\n },\n data: function() {\n return data;\n },\n reset: function() {\n pos = data.length - 1;\n },\n last: function() {\n return data[data.length - 1];\n },\n end: function() {\n return pos === data.length - 1;\n },\n position: function() {\n return pos;\n },\n current: function() {\n return data[pos];\n },\n next: function() {\n var old = pos;\n if (pos < data.length - 1) {\n ++pos;\n }\n if (old !== pos) {\n return data[pos];\n }\n },\n previous: function() {\n var old = pos;\n if (pos > 0) {\n --pos;\n }\n if (old !== pos) {\n return data[pos];\n }\n },\n clear: function() {\n data = [];\n this.purge();\n },\n enabled: function() {\n return enabled;\n },\n enable: function() {\n enabled = true;\n },\n purge: function() {\n if (!memory) {\n $.Storage.remove(storage_key);\n }\n },\n disable: function() {\n enabled = false;\n },\n toggle: function(value) {\n if (typeof value === 'undefined') {\n enabled = !enabled;\n } else {\n enabled = value;\n }\n }\n });\n }\n // -------------------------------------------------------------------------\n // :: COMMAND LINE PLUGIN\n // -------------------------------------------------------------------------\n var cmd_index = 0;\n $.cmd = {\n defaults: {\n mask: false,\n caseSensitiveSearch: true,\n historySize: 60,\n prompt: '> ',\n enabled: true,\n history: true,\n onPositionChange: $.noop,\n onCommandChange: $.noop,\n inputStyle: 'textarea',\n mobileDelete: is_mobile,\n onPaste: $.noop,\n clickTimeout: 200,\n holdTimeout: 400,\n holdRepeatTimeout: 200,\n mobileIngoreAutoSpace: [],\n repeatTimeoutKeys: [],\n tabindex: 1,\n tabs: 4\n }\n };\n $.fn.cmd = function(options) {\n var settings = $.extend({}, $.cmd.defaults, options);\n function mobile_ignore_key(key) {\n return settings.mobileIngoreAutoSpace.length &&\n settings.mobileIngoreAutoSpace.indexOf(key) !== -1 && is_android;\n }\n var self = this;\n var maybe_data = self.data('cmd');\n if (maybe_data) {\n return maybe_data;\n }\n var id = cmd_index++;\n self.addClass('cmd');\n var wrapper = $('').appendTo(self);\n wrapper.append('
');\n wrapper.append('
' +\n '' +\n '' +\n ' ' +\n '' +\n '
');\n // a11y: don't read command it's in textarea that's in focus\n a11y_hide(wrapper.find('.cmd-cursor-line'));\n // on mobile the only way to hide textarea on desktop it's needed because\n // textarea show up after focus\n //self.append('
');\n var clip;\n if (is_mobile) {\n clip = (function() {\n var $node = $('').attr({\n autocapitalize: 'off',\n autocorrect: 'off',\n spellcheck: 'false',\n tabindex: settings.tabindex\n }).insertAfter(self);\n $node.on('focus', function() {\n self.enable();\n }).on('blur', function() {\n self.disable();\n });\n var timer;\n var clip = {\n $node: $node,\n val: function(value) {\n if (typeof value === 'undefined') {\n return $node.text();\n } else {\n $node.html(value);\n }\n },\n reset: function() {\n clearTimeout(timer);\n timer = setTimeout(function() {\n $node.css('top', '');\n }, 400);\n },\n focus: function() {\n $node.css('top', 0);\n clip.reset();\n },\n blur: function() {\n $node.css('top', '100%').blur();\n // just in case of Webkit bug\n window.getSelection().removeAllRanges();\n clip.reset();\n }\n };\n return clip;\n })();\n self.addClass('cmd-mobile');\n } else {\n clip = (function() {\n var $node = $('