芝麻web文件管理V1.00
编辑当前文件:/home/mgatv524/tvc.mgaplay.com.br/web/dist/vendor/ckeditor/plugins/codemirror/js/beautify.min.js
!function(){var t=function(t){function e(i){if(n[i])return n[i].exports;var u=n[i]={i:i,l:!1,exports:{}};return t[i].call(u.exports,u,u.exports,e),u.l=!0,u.exports}var n={};return e.m=t,e.c=n,e.d=function(t,n,i){e.o(t,n)||Object.defineProperty(t,n,{enumerable:!0,get:i})},e.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},e.t=function(t,n){if(1&n&&(t=e(t)),8&n||4&n&&"object"==typeof t&&t&&t.__esModule)return t;var i=Object.create(null);if(e.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:t}),2&n&&"string"!=typeof t)for(var u in t)e.d(i,u,function(e){return t[e]}.bind(null,u));return i},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="",e(e.s=0)}([function(t,e,n){var i=n(1).Beautifier,u=n(5).Options;t.exports=function(t,e){return new i(t,e).beautify()},t.exports.defaultOptions=function(){return new u}},function(t,e,n){function i(t,e){return-1!==e.indexOf(t)}function u(t,e){return t&&t.type===b.RESERVED&&t.text===e}function _(t,e){return t&&t.type===b.RESERVED&&i(t.text,e)}function a(t,e){e.multiline_frame||e.mode===w.ForInitializer||e.mode===w.Conditional||t.remove_indent(e.start_line_index)}function s(t){return i(t,[w.Expression,w.ForInitializer,w.Conditional])}function r(t,e){e=e||{},this._source_text=t||"",this._flag_store=this._previous_flags=this._flags=this._last_last_text=this._tokens=this._output=null,this._options=new c(e)}var o=n(2).Output,p=n(3).Token,h=n(4),c=n(5).Options,l=n(7).Tokenizer,f=n(7).line_starters,d=n(7).positionable_operators,b=n(7).TOKEN,g="case return do if throw else await break continue async".split(" "),m=function(t){for(var e={},n=0;n
n&&(n=t.line_indent_level)),{mode:e,parent:t,last_token:t?t.last_token:new p(b.START_BLOCK,""),last_word:t?t.last_word:"",declaration_statement:!1,declaration_assignment:!1,multiline_frame:!1,inline_frame:!1,if_block:!1,else_block:!1,do_block:!1,do_while:!1,import_block:!1,in_case_statement:!1,in_case:!1,case_body:!1,indentation_level:n,alignment:0,line_indent_level:t?t.line_indent_level:n,start_line_index:this._output.get_line_number(),ternary_depth:0}},r.prototype._reset=function(t){var e=t.match(/^[\t ]*/)[0];return this._last_last_text="",this._output=new o(this._options,e),this._output.raw=this._options.test_output_raw,this._flag_store=[],this.set_mode(w.BlockStatement),this._tokens=new l(t,this._options).tokenize(),t},r.prototype.beautify=function(){if(this._options.disabled)return this._source_text;var t=this._reset(this._source_text),e=this._options.eol;for("auto"===this._options.eol&&(e="\n",t&&h.lineBreak.test(t||"")&&(e=t.match(h.lineBreak)[0])),t=this._tokens.next();t;)this.handle_token(t),this._last_last_text=this._flags.last_token.text,this._flags.last_token=t,t=this._tokens.next();return this._output.get_code(e)},r.prototype.handle_token=function(t,e){t.type===b.START_EXPR?this.handle_start_expr(t):t.type===b.END_EXPR?this.handle_end_expr(t):t.type===b.START_BLOCK?this.handle_start_block(t):t.type===b.END_BLOCK?this.handle_end_block(t):t.type===b.WORD||t.type===b.RESERVED?this.handle_word(t):t.type===b.SEMICOLON?this.handle_semicolon(t):t.type===b.STRING?this.handle_string(t):t.type===b.EQUALS?this.handle_equals(t):t.type===b.OPERATOR?this.handle_operator(t):t.type===b.COMMA?this.handle_comma(t):t.type===b.BLOCK_COMMENT?this.handle_block_comment(t,e):t.type===b.COMMENT?this.handle_comment(t,e):t.type===b.DOT?this.handle_dot(t):t.type===b.EOF?this.handle_eof(t):(t.type,b.UNKNOWN,this.handle_unknown(t,e))},r.prototype.handle_whitespace_and_comments=function(t,e){var n=t.newlines,i=this._options.keep_array_indentation&&this._flags.mode===w.ArrayLiteral;if(t.comments_before)for(var u=t.comments_before.next();u;)this.handle_whitespace_and_comments(u,e),this.handle_token(u,e),u=t.comments_before.next();if(i)for(i=0;i
this._options.max_preserve_newlines&&(n=this._options.max_preserve_newlines),this._options.preserve_newlines&&1
this._flags.parent.indentation_level)&&(--this._flags.indentation_level,this._output.set_indent(this._flags.indentation_level,this._flags.alignment))},r.prototype.set_mode=function(t){this._flags?(this._flag_store.push(this._flags),this._previous_flags=this._flags):this._previous_flags=this.create_flags(null,t),this._flags=this.create_flags(this._previous_flags,t),this._output.set_indent(this._flags.indentation_level,this._flags.alignment)},r.prototype.restore_mode=function(){0
"===this._flags.last_token.text?this.set_mode(w.BlockStatement):i(this._flags.last_token.type,[b.EQUALS,b.START_EXPR,b.COMMA,b.OPERATOR])||_(this._flags.last_token,["return","throw","import","default"])?this.set_mode(w.ObjectLiteral):this.set_mode(w.BlockStatement),n=(e=!e.comments_before&&"}"===e.text)&&"function"===this._flags.last_word&&this._flags.last_token.type===b.END_EXPR,this._options.brace_preserve_inline){var u=0,a=null;this._flags.inline_frame=!0;do{if(u+=1,(a=this._tokens.peek(u-1)).newlines){this._flags.inline_frame=!1;break}}while(a.type!==b.EOF&&(a.type!==b.END_BLOCK||a.opened!==t))}("expand"===this._options.brace_style||"none"===this._options.brace_style&&t.newlines)&&!this._flags.inline_frame?this._flags.last_token.type!==b.OPERATOR&&(n||this._flags.last_token.type===b.EQUALS||_(this._flags.last_token,g)&&"else"!==this._flags.last_token.text)?this._output.space_before_token=!0:this.print_newline(!1,!0):(this._previous_flags.mode!==w.ArrayLiteral||this._flags.last_token.type!==b.START_EXPR&&this._flags.last_token.type!==b.COMMA||((this._flags.last_token.type===b.COMMA||this._options.space_in_paren)&&(this._output.space_before_token=!0),(this._flags.last_token.type===b.COMMA||this._flags.last_token.type===b.START_EXPR&&this._flags.inline_frame)&&(this.allow_wrap_or_preserved_newline(t),this._previous_flags.multiline_frame=this._previous_flags.multiline_frame||this._flags.multiline_frame,this._flags.multiline_frame=!1)),this._flags.last_token.type!==b.OPERATOR&&this._flags.last_token.type!==b.START_EXPR&&(this._flags.last_token.type!==b.START_BLOCK||this._flags.inline_frame?this._output.space_before_token=!0:this.print_newline())),this.print_token(t),this.indent(),e||this._options.brace_preserve_inline&&this._flags.inline_frame||this.print_newline()},r.prototype.handle_end_block=function(t){for(this.handle_whitespace_and_comments(t);this._flags.mode===w.Statement;)this.restore_mode();var e=this._flags.last_token.type===b.START_BLOCK;this._flags.inline_frame&&!e?this._output.space_before_token=!0:"expand"===this._options.brace_style?e||this.print_newline():e||(this._flags.mode===w.ArrayLiteral&&this._options.keep_array_indentation?(this._options.keep_array_indentation=!1,this.print_newline(),this._options.keep_array_indentation=!0):this.print_newline()),this.restore_mode(),this.print_token(t)},r.prototype.handle_word=function(t){if(t.type===b.RESERVED&&(i(t.text,["set","get"])&&this._flags.mode!==w.ObjectLiteral||"import"===t.text&&"("===this._tokens.peek().text||i(t.text,["as","from"])&&!this._flags.import_block||this._flags.mode===w.ObjectLiteral&&":"===this._tokens.peek().text)&&(t.type=b.WORD),this.start_of_statement(t)?_(this._flags.last_token,["var","let","const"])&&t.type===b.WORD&&(this._flags.declaration_statement=!0):!t.newlines||s(this._flags.mode)||this._flags.last_token.type===b.OPERATOR&&"--"!==this._flags.last_token.text&&"++"!==this._flags.last_token.text||this._flags.last_token.type===b.EQUALS||!this._options.preserve_newlines&&_(this._flags.last_token,["var","let","const","set","get"])?this.handle_whitespace_and_comments(t):(this.handle_whitespace_and_comments(t),this.print_newline()),this._flags.do_block&&!this._flags.do_while){if(u(t,"while"))return this._output.space_before_token=!0,this.print_token(t),this._output.space_before_token=!0,void(this._flags.do_while=!0);this.print_newline(),this._flags.do_block=!1}if(this._flags.if_block)if(!this._flags.else_block&&u(t,"else"))this._flags.else_block=!0;else{for(;this._flags.mode===w.Statement;)this.restore_mode();this._flags.if_block=!1,this._flags.else_block=!1}if(this._flags.in_case_statement&&_(t,["case","default"]))return this.print_newline(),this._flags.last_token.type!==b.END_BLOCK&&(this._flags.case_body||this._options.jslint_happy)&&this.deindent(),this._flags.case_body=!1,this.print_token(t),void(this._flags.in_case=!0);if(this._flags.last_token.type!==b.COMMA&&this._flags.last_token.type!==b.START_EXPR&&this._flags.last_token.type!==b.EQUALS&&this._flags.last_token.type!==b.OPERATOR||this.start_of_object_property()||this.allow_wrap_or_preserved_newline(t),u(t,"function"))return(i(this._flags.last_token.text,["}",";"])||this._output.just_added_newline()&&!i(this._flags.last_token.text,"([{:=,".split(""))&&this._flags.last_token.type!==b.OPERATOR)&&(this._output.just_added_blankline()||t.comments_before||(this.print_newline(),this.print_newline(!0))),this._flags.last_token.type===b.RESERVED||this._flags.last_token.type===b.WORD?_(this._flags.last_token,["get","set","new","export"])||_(this._flags.last_token,k)||u(this._flags.last_token,"default")&&"export"===this._last_last_text||"declare"===this._flags.last_token.text?this._output.space_before_token=!0:this.print_newline():this._flags.last_token.type===b.OPERATOR||"="===this._flags.last_token.text?this._output.space_before_token=!0:(this._flags.multiline_frame||!s(this._flags.mode)&&this._flags.mode!==w.ArrayLiteral)&&this.print_newline(),this.print_token(t),void(this._flags.last_word=t.text);var e="NONE";this._flags.last_token.type===b.END_BLOCK?this._previous_flags.inline_frame?e="SPACE":_(t,["else","catch","finally","from"])?"expand"===this._options.brace_style||"end-expand"===this._options.brace_style||"none"===this._options.brace_style&&t.newlines?e="NEWLINE":(e="SPACE",this._output.space_before_token=!0):e="NEWLINE":this._flags.last_token.type===b.SEMICOLON&&this._flags.mode===w.BlockStatement?e="NEWLINE":this._flags.last_token.type===b.SEMICOLON&&s(this._flags.mode)?e="SPACE":this._flags.last_token.type===b.STRING?e="NEWLINE":this._flags.last_token.type===b.RESERVED||this._flags.last_token.type===b.WORD||"*"===this._flags.last_token.text&&(i(this._last_last_text,["function","yield"])||this._flags.mode===w.ObjectLiteral&&i(this._last_last_text,["{",","]))?e="SPACE":this._flags.last_token.type===b.START_BLOCK?e=this._flags.inline_frame?"SPACE":"NEWLINE":this._flags.last_token.type===b.END_EXPR&&(this._output.space_before_token=!0,e="NEWLINE"),_(t,f)&&")"!==this._flags.last_token.text&&(e=this._flags.inline_frame||"else"===this._flags.last_token.text||"export"===this._flags.last_token.text?"SPACE":"NEWLINE"),_(t,["else","catch","finally"])?(this._flags.last_token.type!==b.END_BLOCK||this._previous_flags.mode!==w.BlockStatement||"expand"===this._options.brace_style||"end-expand"===this._options.brace_style||"none"===this._options.brace_style&&t.newlines)&&!this._flags.inline_frame?this.print_newline():(this._output.trim(!0),"}"!==this._output.current_line.last()&&this.print_newline(),this._output.space_before_token=!0):"NEWLINE"===e?_(this._flags.last_token,g)||"declare"===this._flags.last_token.text&&_(t,["var","let","const"])?this._output.space_before_token=!0:this._flags.last_token.type!==b.END_EXPR?this._flags.last_token.type===b.START_EXPR&&_(t,["var","let","const"])||":"===this._flags.last_token.text||(u(t,"if")&&u(t.previous,"else")?this._output.space_before_token=!0:this.print_newline()):_(t,f)&&")"!==this._flags.last_token.text&&this.print_newline():this._flags.multiline_frame&&this._flags.mode===w.ArrayLiteral&&","===this._flags.last_token.text&&"}"===this._last_last_text?this.print_newline():"SPACE"===e&&(this._output.space_before_token=!0),!t.previous||t.previous.type!==b.WORD&&t.previous.type!==b.RESERVED||(this._output.space_before_token=!0),this.print_token(t),this._flags.last_word=t.text,t.type===b.RESERVED&&("do"===t.text?this._flags.do_block=!0:"if"===t.text?this._flags.if_block=!0:"import"===t.text?this._flags.import_block=!0:this._flags.import_block&&u(t,"from")&&(this._flags.import_block=!1))},r.prototype.handle_semicolon=function(t){this.start_of_statement(t)?this._output.space_before_token=!1:this.handle_whitespace_and_comments(t);for(var e=this._tokens.peek();!(this._flags.mode!==w.Statement||this._flags.if_block&&u(e,"else")||this._flags.do_block);)this.restore_mode();this._flags.import_block&&(this._flags.import_block=!1),this.print_token(t)},r.prototype.handle_string=function(t){this.start_of_statement(t)?this._output.space_before_token=!0:(this.handle_whitespace_and_comments(t),this._flags.last_token.type===b.RESERVED||this._flags.last_token.type===b.WORD||this._flags.inline_frame?this._output.space_before_token=!0:this._flags.last_token.type===b.COMMA||this._flags.last_token.type===b.START_EXPR||this._flags.last_token.type===b.EQUALS||this._flags.last_token.type===b.OPERATOR?this.start_of_object_property()||this.allow_wrap_or_preserved_newline(t):this.print_newline()),this.print_token(t)},r.prototype.handle_equals=function(t){this.start_of_statement(t)||this.handle_whitespace_and_comments(t),this._flags.declaration_statement&&(this._flags.declaration_assignment=!0),this._output.space_before_token=!0,this.print_token(t),this._output.space_before_token=!0},r.prototype.handle_comma=function(t){this.handle_whitespace_and_comments(t,!0),this.print_token(t),this._output.space_before_token=!0,this._flags.declaration_statement?(s(this._flags.parent.mode)&&(this._flags.declaration_assignment=!1),this._flags.declaration_assignment?(this._flags.declaration_assignment=!1,this.print_newline(!1,!0)):this._options.comma_first&&this.allow_wrap_or_preserved_newline(t)):this._flags.mode===w.ObjectLiteral||this._flags.mode===w.Statement&&this._flags.parent.mode===w.ObjectLiteral?(this._flags.mode===w.Statement&&this.restore_mode(),this._flags.inline_frame||this.print_newline()):this._options.comma_first&&this.allow_wrap_or_preserved_newline(t)},r.prototype.handle_operator=function(t){var e="*"===t.text&&(_(this._flags.last_token,["function","yield"])||i(this._flags.last_token.type,[b.START_BLOCK,b.COMMA,b.END_BLOCK,b.SEMICOLON])),n=i(t.text,["-","+"])&&(i(this._flags.last_token.type,[b.START_BLOCK,b.START_EXPR,b.EQUALS,b.OPERATOR])||i(this._flags.last_token.text,f)||","===this._flags.last_token.text);if(this.start_of_statement(t)||this.handle_whitespace_and_comments(t,!e),_(this._flags.last_token,g))return this._output.space_before_token=!0,void this.print_token(t);if("*"===t.text&&this._flags.last_token.type===b.DOT||"::"===t.text)this.print_token(t);else{if(this._flags.last_token.type===b.OPERATOR&&i(this._options.operator_position,y)&&this.allow_wrap_or_preserved_newline(t),":"===t.text&&this._flags.in_case)return this.print_token(t),this._flags.in_case=!1,this._flags.case_body=!0,void(this._tokens.peek().type!==b.START_BLOCK?(this.indent(),this.print_newline()):this._output.space_before_token=!0);var u=!0,a=!0,r=!1;if(":"===t.text?0===this._flags.ternary_depth?u=!1:(--this._flags.ternary_depth,r=!0):"?"===t.text&&(this._flags.ternary_depth+=1),!n&&!e&&this._options.preserve_newlines&&i(t.text,d)){var o=":"===t.text,p=o&&r;switch(r=o&&!r,this._options.operator_position){case m.before_newline:return this._output.space_before_token=!r,this.print_token(t),o&&!p||this.allow_wrap_or_preserved_newline(t),void(this._output.space_before_token=!0);case m.after_newline:return this._output.space_before_token=!0,!o||p?this._tokens.peek().newlines?this.print_newline(!1,!0):this.allow_wrap_or_preserved_newline(t):this._output.space_before_token=!1,this.print_token(t),void(this._output.space_before_token=!0);case m.preserve_newline:return r||this.allow_wrap_or_preserved_newline(t),u=!(this._output.just_added_newline()||r),this._output.space_before_token=u,this.print_token(t),void(this._output.space_before_token=!0)}}e?(this.allow_wrap_or_preserved_newline(t),u=!1,a=(e=this._tokens.peek())&&i(e.type,[b.WORD,b.RESERVED])):"..."===t.text?(this.allow_wrap_or_preserved_newline(t),u=this._flags.last_token.type===b.START_BLOCK,a=!1):(i(t.text,["--","++","!","~"])||n)&&(this._flags.last_token.type!==b.COMMA&&this._flags.last_token.type!==b.START_EXPR||this.allow_wrap_or_preserved_newline(t),u=!1,a=!1,!t.newlines||"--"!==t.text&&"++"!==t.text||this.print_newline(!1,!0),";"===this._flags.last_token.text&&s(this._flags.mode)&&(u=!0),this._flags.last_token.type===b.RESERVED?u=!0:this._flags.last_token.type===b.END_EXPR?u=!("]"===this._flags.last_token.text&&("--"===t.text||"++"===t.text)):this._flags.last_token.type===b.OPERATOR&&(u=i(t.text,["--","-","++","+"])&&i(this._flags.last_token.text,["--","-","++","+"]),i(t.text,["+","-"])&&i(this._flags.last_token.text,["--","++"])&&(a=!0)),(this._flags.mode!==w.BlockStatement||this._flags.inline_frame)&&this._flags.mode!==w.Statement||"{"!==this._flags.last_token.text&&";"!==this._flags.last_token.text||this.print_newline()),this._output.space_before_token=this._output.space_before_token||u,this.print_token(t),this._output.space_before_token=a}},r.prototype.handle_block_comment=function(t,e){return this._output.raw?(this._output.add_raw_token(t),void(t.directives&&"end"===t.directives.preserve&&(this._output.raw=this._options.test_output_raw))):t.directives?(this.print_newline(!1,e),this.print_token(t),"start"===t.directives.preserve&&(this._output.raw=!0),void this.print_newline(!1,!0)):h.newline.test(t.text)||t.newlines?void this.print_block_commment(t,e):(this._output.space_before_token=!0,this.print_token(t),void(this._output.space_before_token=!0))},r.prototype.print_block_commment=function(t,e){for(var n,i,u=[],_=(i=(i=t.text).replace(h.allLineBreaks,"\n")).indexOf("\n");-1!==_;)u.push(i.substring(0,_)),_=(i=i.substring(_+1)).indexOf("\n");i.length&&u.push(i),i=u;var a=_=!1;if(u=(a=t.whitespace_before).length,this.print_newline(!1,e),this.print_token_line_indentation(t),this._output.add_token(i[0]),this.print_newline(!1,e),1
t?this.__items[this.__items.length+t]:this.__items[t]},i.prototype.has_match=function(t){for(var e=this.__items.length-1;0<=e;e--)if(this.__items[e].match(t))return!0;return!1},i.prototype.set_indent=function(t,e){this.is_empty()&&(this.__indent_count=t||0,this.__alignment_count=e||0,this.__character_count=this.__parent.get_indent_size(this.__indent_count,this.__alignment_count))},i.prototype._set_wrap_point=function(){this.__parent.wrap_line_length&&(this.__wrap_point_index=this.__items.length,this.__wrap_point_character_count=this.__character_count,this.__wrap_point_indent_count=this.__parent.next_line.__indent_count,this.__wrap_point_alignment_count=this.__parent.next_line.__alignment_count)},i.prototype._should_wrap=function(){return this.__wrap_point_index&&this.__character_count>this.__parent.wrap_line_length&&this.__wrap_point_character_count>this.__parent.next_line.__character_count},i.prototype._allow_wrap=function(){if(this._should_wrap()){this.__parent.add_new_line();var t=this.__parent.current_line;return t.set_indent(this.__wrap_point_indent_count,this.__wrap_point_alignment_count),t.__items=this.__items.slice(this.__wrap_point_index),this.__items=this.__items.slice(0,this.__wrap_point_index),t.__character_count+=this.__character_count-this.__wrap_point_character_count,this.__character_count=this.__wrap_point_character_count," "===t.__items[0]&&(t.__items.splice(0,1),--t.__character_count),!0}return!1},i.prototype.is_empty=function(){return 0===this.__items.length},i.prototype.last=function(){return this.is_empty()?null:this.__items[this.__items.length-1]},i.prototype.push=function(t){this.__items.push(t);var e=t.lastIndexOf("\n");-1!==e?this.__character_count=t.length-e:this.__character_count+=t.length},i.prototype.pop=function(){var t=null;return this.is_empty()||(t=this.__items.pop(),this.__character_count-=t.length),t},i.prototype._remove_indent=function(){0
t&&(n=0),(n+=t*this.__indent_size)+e},u.prototype.get_indent_string=function(t,e){var n=this.__base_string;return e=e||0,0>t&&(t=0,n=""),e+=t*this.__indent_size,this.__ensure_cache(e),n+this.__cache[e]},u.prototype.__ensure_cache=function(t){for(;t>=this.__cache.length;)this.__add_column()},u.prototype.__add_column=function(){var t=this.__cache.length,e=0,n="";this.__indent_size&&t>=this.__indent_size&&(t-=(e=Math.floor(t/this.__indent_size))*this.__indent_size,n=Array(e+1).join(this.__indent_string)),t&&(n+=Array(t+1).join(" ")),this.__cache.push(n)},_.prototype.__add_outputline=function(){this.previous_line=this.current_line,this.current_line=this.next_line.clone_empty(),this.__lines.push(this.current_line)},_.prototype.get_line_number=function(){return this.__lines.length},_.prototype.get_indent_string=function(t,e){return this.__indent_cache.get_indent_string(t,e)},_.prototype.get_indent_size=function(t,e){return this.__indent_cache.get_indent_size(t,e)},_.prototype.is_empty=function(){return!this.previous_line&&this.current_line.is_empty()},_.prototype.add_new_line=function(t){return!(this.is_empty()||!t&&this.just_added_newline()||(this.raw||this.__add_outputline(),0))},_.prototype.get_code=function(t){this.trim(!0);var e=this.current_line.pop();return e&&("\n"===e[e.length-1]&&(e=e.replace(/\n+$/g,"")),this.current_line.push(e)),this._end_with_newline&&this.__add_outputline(),e=this.__lines.join("\n"),"\n"!==t&&(e=e.replace(/[\n]/g,t)),e},_.prototype.set_wrap_point=function(){this.current_line._set_wrap_point()},_.prototype.set_indent=function(t,e){return t=t||0,e=e||0,this.next_line.set_indent(t,e),1
>>= ... >>= <<= === >>> !== **= => ^= :: /= << <= == && -= >= >> != -- += ** || ?? ++ %= &= *= |= |> = ! ? > < : / ^ - + * & % ~ |".replace(/[-[\]{}()*+?.,\\^$|#]/g,"\\$&"))).replace(/ /g,"|");var d,b=new RegExp(n);e=(n="continue try throw return var let const if switch case default for while break function import export".split(" ")).concat("do in of else get set new catch finally typeof yield async await from as".split(" "));var g=new RegExp("^(?:"+e.join("|")+")$");e=function(t,e){_.call(this,t,e),this._patterns.whitespace=this._patterns.whitespace.matching(/\u00A0\u1680\u180e\u2000-\u200a\u202f\u205f\u3000\ufeff/.source,/\u2028\u2029/.source);var n=new r(this._input),i=new o(this._input).read_options(this._options);this.__patterns={template:i,identifier:i.starting_with(s.identifier).matching(s.identifierMatch),number:n.matching(c),punct:n.matching(b),comment:n.starting_with(/\/\//).until(/[\n\r\u2028\u2029]/),block_comment:n.starting_with(/\/\*/).until_after(/\*\//),html_comment_start:n.matching(/\x3c!--/),html_comment_end:n.matching(/--\x3e/),include:n.starting_with(/#include/).until_after(s.lineBreak),shebang:n.starting_with(/#!/).until_after(s.lineBreak),xml:n.matching(/[\s\S]*?<(\/?)([-a-zA-Z:0-9_.]+|{[\s\S]+?}|!\[CDATA\[[\s\S]*?\]\])(\s+{[\s\S]+?}|\s+[-a-zA-Z:0-9_.]+|\s+[-a-zA-Z:0-9_.]+\s*=\s*('[^']*'|"[^"]*"|{[\s\S]+?}))*\s*(\/?)\s*>/),single_quote:i.until(/['\\\n\r\u2028\u2029]/),double_quote:i.until(/["\\\n\r\u2028\u2029]/),template_text:i.until(/[`\\$]/),template_expression:i.until(/[`}\\]/)}},e.prototype=new _,e.prototype._is_comment=function(t){return t.type===p.COMMENT||t.type===p.BLOCK_COMMENT||t.type===p.UNKNOWN},e.prototype._is_opening=function(t){return t.type===p.START_BLOCK||t.type===p.START_EXPR},e.prototype._is_closing=function(t,e){return(t.type===p.END_BLOCK||t.type===p.END_EXPR)&&e&&("]"===t.text&&"["===e.text||")"===t.text&&"("===e.text||"}"===t.text&&"{"===e.text)},e.prototype._reset=function(){d=!1},e.prototype._get_next_token=function(t,e){var n=null;this._readWhitespace();var i=this._input.peek();return null===i?this._create_token(p.EOF,""):(n=(n=(n=(n=(n=(n=(n=(n=n||this._read_non_javascript(i))||this._read_string(i))||this._read_word(t))||this._read_singles(i))||this._read_comment(i))||this._read_regexp(i,t))||this._read_xml(i,t))||this._read_punctuation())||this._create_token(p.UNKNOWN,this._input.next())},e.prototype._read_word=function(t){var e;return""!==(e=this.__patterns.identifier.read())?(e=e.replace(s.allLineBreaks,"\n"),t.type!==p.DOT&&(t.type!==p.RESERVED||"set"!==t.text&&"get"!==t.text)&&g.test(e)?"in"===e||"of"===e?this._create_token(p.OPERATOR,e):this._create_token(p.RESERVED,e):this._create_token(p.WORD,e)):""!==(e=this.__patterns.number.read())?this._create_token(p.WORD,e):void 0},e.prototype._read_singles=function(t){var e=null;return"("===t||"["===t?e=this._create_token(p.START_EXPR,t):")"===t||"]"===t?e=this._create_token(p.END_EXPR,t):"{"===t?e=this._create_token(p.START_BLOCK,t):"}"===t?e=this._create_token(p.END_BLOCK,t):";"===t?e=this._create_token(p.SEMICOLON,t):"."===t&&f.test(this._input.peek(1))?e=this._create_token(p.DOT,t):","===t&&(e=this._create_token(p.COMMA,t)),e&&this._input.next(),e},e.prototype._read_punctuation=function(){var t=this.__patterns.punct.read();if(""!==t)return"="===t?this._create_token(p.EQUALS,t):"?."===t?this._create_token(p.DOT,t):this._create_token(p.OPERATOR,t)},e.prototype._read_non_javascript=function(t){var e="";if("#"===t){if(this._is_first_token()&&(e=this.__patterns.shebang.read())||(e=this.__patterns.include.read()))return this._create_token(p.UNKNOWN,e.trim()+"\n");if(this._input.next(),e="#",this._input.hasNext()&&this._input.testChar(l)){do{e+=t=this._input.next()}while(this._input.hasNext()&&"#"!==t&&"="!==t);return"#"===t||("["===this._input.peek()&&"]"===this._input.peek(1)?(e+="[]",this._input.next(),this._input.next()):"{"===this._input.peek()&&"}"===this._input.peek(1)&&(e+="{}",this._input.next(),this._input.next())),this._create_token(p.WORD,e)}this._input.back()}else if("<"===t&&this._is_first_token()){if(e=this.__patterns.html_comment_start.read()){for(;this._input.hasNext()&&!this._input.testChar(s.newline);)e+=this._input.next();return d=!0,this._create_token(p.COMMENT,e)}}else if(d&&"-"===t&&(e=this.__patterns.html_comment_end.read()))return d=!1,this._create_token(p.COMMENT,e);return null},e.prototype._read_comment=function(t){var e=null;if("/"===t)if(t="","*"===this._input.peek(1)){t=this.__patterns.block_comment.read();var n=h.get_directives(t);n&&"start"===n.ignore&&(t+=h.readIgnored(this._input)),t=t.replace(s.allLineBreaks,"\n"),(e=this._create_token(p.BLOCK_COMMENT,t)).directives=n}else"/"===this._input.peek(1)&&(t=this.__patterns.comment.read(),e=this._create_token(p.COMMENT,t));return e},e.prototype._read_string=function(t){if("`"===t||"'"===t||'"'===t){var e=this._input.next();if(this.has_char_escapes=!1,e+="`"===t?this._read_string_recursive("`",!0,"${"):this._read_string_recursive(t),this.has_char_escapes&&this._options.unescape_strings)t:{for(var n="",i=0,_=new u(e),a=null;_.hasNext();)if((a=_.match(/([\s]|[^\\]|\\\\)+/g))&&(n+=a[0]),"\\"===_.peek()){if(_.next(),"x"===_.peek())a=_.match(/x([0-9A-Fa-f]{2})/g);else{if("u"!==_.peek()){n+="\\",_.hasNext()&&(n+=_.next());continue}a=_.match(/u([0-9A-Fa-f]{4})/g)}if(!a)break t;if(126<(i=parseInt(a[1],16))&&255>=i&&0===a[0].indexOf("x"))break t;n=0<=i&&32>i?n+"\\"+a[0]:n+(34===i||39===i||92===i?"\\"+String.fromCharCode(i):String.fromCharCode(i))}e=n}return this._input.peek()===t&&(e+=this._input.next()),e=e.replace(s.allLineBreaks,"\n"),this._create_token(p.STRING,e)}return null},e.prototype._allow_regexp_or_xml=function(t){return t.type===p.RESERVED&&i(t.text,"return case throw else do typeof yield".split(" "))||t.type===p.END_EXPR&&")"===t.text&&t.opened.previous.type===p.RESERVED&&i(t.opened.previous.text,["if","while","for"])||i(t.type,[p.COMMENT,p.START_EXPR,p.START_BLOCK,p.START,p.END_BLOCK,p.OPERATOR,p.EQUALS,p.EOF,p.SEMICOLON,p.COMMA])},e.prototype._read_regexp=function(t,e){if("/"===t&&this._allow_regexp_or_xml(e)){for(var n=this._input.next(),i=!1,u=!1;this._input.hasNext()&&(i||u||this._input.peek()!==t)&&!this._input.testChar(s.newline);)n+=this._input.peek(),i?i=!1:(i="\\"===this._input.peek(),"["===this._input.peek()?u=!0:"]"===this._input.peek()&&(u=!1)),this._input.next();return this._input.peek()===t&&(n+=this._input.next(),n+=this._input.read(s.identifier)),this._create_token(p.STRING,n)}return null},e.prototype._read_xml=function(t,e){if(this._options.e4x&&"<"===t&&this._allow_regexp_or_xml(e)){var n="",i=this.__patterns.xml.read_match();if(i){for(var u=i[2].replace(/^{\s+/,"{").replace(/\s+}$/,"}"),_=0===u.indexOf("{"),a=0;i;){var r=!!i[1],o=i[2];if(!(i[i.length-1]||"![CDATA["===o.slice(0,8))&&(o===u||_&&o.replace(/^{\s+/,"{").replace(/\s+}$/,"}"))&&(r?--a:++a),n+=i[0],0>=a)break;i=this.__patterns.xml.read_match()}return i||(n+=this._input.match(/[\s\S]*/g)[0]),n=n.replace(s.allLineBreaks,"\n"),this._create_token(p.STRING,n)}}return null},e.prototype._read_string_recursive=function(t,e,n){var i,u;"'"===t?u=this.__patterns.single_quote:'"'===t?u=this.__patterns.double_quote:"`"===t?u=this.__patterns.template_text:"}"===t&&(u=this.__patterns.template_expression);for(var _=u.read(),a="";this._input.hasNext();){if((a=this._input.next())===t||!e&&s.newline.test(a)){this._input.back();break}"\\"===a&&this._input.hasNext()?("x"===(i=this._input.peek())||"u"===i?this.has_char_escapes=!0:"\r"===i&&"\n"===this._input.peek(1)&&this._input.next(),a+=this._input.next()):n&&("${"===n&&"$"===a&&"{"===this._input.peek()&&(a+=this._input.next()),n===a&&(a+="`"===t?this._read_string_recursive("}",e,"`"):this._read_string_recursive("`",e,"${"),this._input.hasNext()&&(a+=this._input.next()))),_+=a+=u.read()}return _},t.exports.Tokenizer=e,t.exports.TOKEN=p,t.exports.positionable_operators=">>> === !== << && >= ** != == <= >> || ?? |> < / - + > : & % ? ^ | *".split(" ").slice(),t.exports.line_starters=n.slice()},function(t,e,n){function i(t){this.__input=t||"",this.__input_length=this.__input.length,this.__position=0}var u=RegExp.prototype.hasOwnProperty("sticky");i.prototype.restart=function(){this.__position=0},i.prototype.back=function(){0
=t.length&&this.__input.substring(e-t.length,e).toLowerCase()===t},t.exports.InputScanner=i},function(t,e,n){var i=n(8).InputScanner,u=n(3).Token,_=n(10).TokenStream,a=n(11).WhitespacePattern,s={START:"TK_START",RAW:"TK_RAW",EOF:"TK_EOF"};e=function(t,e){this._input=new i(t),this._options=e||{},this.__tokens=null,this._patterns={},this._patterns.whitespace=new a(this._input)},e.prototype.tokenize=function(){this._input.restart(),this.__tokens=new _,this._reset();for(var t,e=new u(s.START,""),n=null,i=[],a=new _;e.type!==s.EOF;){for(t=this._get_next_token(e,n);this._is_comment(t);)a.add(t),t=this._get_next_token(e,n);a.isEmpty()||(t.comments_before=a,a=new _),t.parent=n,this._is_opening(t)?(i.push(n),n=t):n&&this._is_closing(t,n)&&(t.opened=n,n.closed=t,n=i.pop(),t.parent=n),t.previous=e,e.next=t,this.__tokens.add(t),e=t}return this.__tokens},e.prototype._is_first_token=function(){return this.__tokens.isEmpty()},e.prototype._reset=function(){},e.prototype._get_next_token=function(t,e){this._readWhitespace();var n=this._input.read(/.+/g);return n?this._create_token(s.RAW,n):this._create_token(s.EOF,"")},e.prototype._is_comment=function(t){return!1},e.prototype._is_opening=function(t){return!1},e.prototype._is_closing=function(t,e){return!1},e.prototype._create_token=function(t,e){return new u(t,e,this._patterns.whitespace.newline_count,this._patterns.whitespace.whitespace_before_token)},e.prototype._readWhitespace=function(){return this._patterns.whitespace.read()},t.exports.Tokenizer=e,t.exports.TOKEN=s},function(t,e,n){function i(t){this.__tokens=[],this.__tokens_length=this.__tokens.length,this.__position=0,this.__parent_token=t}i.prototype.restart=function(){this.__position=0},i.prototype.isEmpty=function(){return 0===this.__tokens_length},i.prototype.hasNext=function(){return this.__position
/),erb:n.starting_with(/<%[^%]/).until_after(/[^%]%>/),django:n.starting_with(/{%/).until_after(/%}/),django_value:n.starting_with(/{{/).until_after(/}}/),django_comment:n.starting_with(/{#/).until_after(/#}/)}}var u=n(12).Pattern,_={django:!1,erb:!1,handlebars:!1,php:!1};i.prototype=new u,i.prototype._create=function(){return new i(this._input,this)},i.prototype._update=function(){this.__set_templated_pattern()},i.prototype.disable=function(t){var e=this._create();return e._disabled[t]=!0,e._update(),e},i.prototype.read_options=function(t){var e,n=this._create();for(e in _)n._disabled[e]=-1===t.templating.indexOf(e);return n._update(),n},i.prototype.exclude=function(t){var e=this._create();return e._excluded[t]=!0,e._update(),e},i.prototype.read=function(){for(var t="",e=(t=this._match_pattern?this._input.read(this._starting_pattern):this._input.read(this._starting_pattern,this.__template_pattern),this._read_template());e;)this._match_pattern?e+=this._input.read(this._match_pattern):e+=this._input.readUntil(this.__template_pattern),t+=e,e=this._read_template();return this._until_after&&(t+=this._input.readUntilAfter(this._until_pattern)),t},i.prototype.__set_templated_pattern=function(){var t=[];this._disabled.php||t.push(this.__patterns.php._starting_pattern.source),this._disabled.handlebars||t.push(this.__patterns.handlebars._starting_pattern.source),this._disabled.erb||t.push(this.__patterns.erb._starting_pattern.source),this._disabled.django||(t.push(this.__patterns.django._starting_pattern.source),t.push(this.__patterns.django_value._starting_pattern.source),t.push(this.__patterns.django_comment._starting_pattern.source)),this._until_pattern&&t.push(this._until_pattern.source),this.__template_pattern=this._input.get_regexp("(?:"+t.join("|")+")")},i.prototype._read_template=function(){var t="",e=this._input.peek();return"<"===e?(e=this._input.peek(1),this._disabled.php||this._excluded.php||"?"!==e||(t=t||this.__patterns.php.read()),this._disabled.erb||this._excluded.erb||"%"!==e||(t=t||this.__patterns.erb.read())):"{"===e&&(this._disabled.handlebars||this._excluded.handlebars||(t=(t=(t=t||this.__patterns.handlebars_comment.read())||this.__patterns.handlebars_unescaped.read())||this.__patterns.handlebars.read()),this._disabled.django||(this._excluded.django||this._excluded.handlebars||(t=t||this.__patterns.django_value.read()),this._excluded.django||(t=(t=t||this.__patterns.django_comment.read())||this.__patterns.django.read()))),t},t.exports.TemplatablePattern=i}]);"function"==typeof define&&define.amd?define("beautify.js",[],(function(){return{js_beautify:t}})):"undefined"!=typeof exports?exports.js_beautify=t:"undefined"!=typeof window?window.js_beautify=t:"undefined"!=typeof global&&(global.js_beautify=t)}(),function(){var t=function(t){function e(i){if(n[i])return n[i].exports;var u=n[i]={i:i,l:!1,exports:{}};return t[i].call(u.exports,u,u.exports,e),u.l=!0,u.exports}var n={};return e.m=t,e.c=n,e.d=function(t,n,i){e.o(t,n)||Object.defineProperty(t,n,{enumerable:!0,get:i})},e.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},e.t=function(t,n){if(1&n&&(t=e(t)),8&n||4&n&&"object"==typeof t&&t&&t.__esModule)return t;var i=Object.create(null);if(e.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:t}),2&n&&"string"!=typeof t)for(var u in t)e.d(i,u,function(e){return t[e]}.bind(null,u));return i},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="",e(e.s=18)}([,,function(t,e,n){function i(t){this.__parent=t,this.__character_count=0,this.__indent_count=-1,this.__wrap_point_character_count=this.__wrap_point_index=this.__alignment_count=0,this.__wrap_point_indent_count=-1,this.__wrap_point_alignment_count=0,this.__items=[]}function u(t,e){this.__cache=[""],this.__indent_size=t.indent_size,this.__indent_string=t.indent_char,t.indent_with_tabs||(this.__indent_string=Array(t.indent_size+1).join(t.indent_char)),e=e||"",0
t?this.__items[this.__items.length+t]:this.__items[t]},i.prototype.has_match=function(t){for(var e=this.__items.length-1;0<=e;e--)if(this.__items[e].match(t))return!0;return!1},i.prototype.set_indent=function(t,e){this.is_empty()&&(this.__indent_count=t||0,this.__alignment_count=e||0,this.__character_count=this.__parent.get_indent_size(this.__indent_count,this.__alignment_count))},i.prototype._set_wrap_point=function(){this.__parent.wrap_line_length&&(this.__wrap_point_index=this.__items.length,this.__wrap_point_character_count=this.__character_count,this.__wrap_point_indent_count=this.__parent.next_line.__indent_count,this.__wrap_point_alignment_count=this.__parent.next_line.__alignment_count)},i.prototype._should_wrap=function(){return this.__wrap_point_index&&this.__character_count>this.__parent.wrap_line_length&&this.__wrap_point_character_count>this.__parent.next_line.__character_count},i.prototype._allow_wrap=function(){if(this._should_wrap()){this.__parent.add_new_line();var t=this.__parent.current_line;return t.set_indent(this.__wrap_point_indent_count,this.__wrap_point_alignment_count),t.__items=this.__items.slice(this.__wrap_point_index),this.__items=this.__items.slice(0,this.__wrap_point_index),t.__character_count+=this.__character_count-this.__wrap_point_character_count,this.__character_count=this.__wrap_point_character_count," "===t.__items[0]&&(t.__items.splice(0,1),--t.__character_count),!0}return!1},i.prototype.is_empty=function(){return 0===this.__items.length},i.prototype.last=function(){return this.is_empty()?null:this.__items[this.__items.length-1]},i.prototype.push=function(t){this.__items.push(t);var e=t.lastIndexOf("\n");-1!==e?this.__character_count=t.length-e:this.__character_count+=t.length},i.prototype.pop=function(){var t=null;return this.is_empty()||(t=this.__items.pop(),this.__character_count-=t.length),t},i.prototype._remove_indent=function(){0
t&&(n=0),(n+=t*this.__indent_size)+e},u.prototype.get_indent_string=function(t,e){var n=this.__base_string;return e=e||0,0>t&&(t=0,n=""),e+=t*this.__indent_size,this.__ensure_cache(e),n+this.__cache[e]},u.prototype.__ensure_cache=function(t){for(;t>=this.__cache.length;)this.__add_column()},u.prototype.__add_column=function(){var t=this.__cache.length,e=0,n="";this.__indent_size&&t>=this.__indent_size&&(t-=(e=Math.floor(t/this.__indent_size))*this.__indent_size,n=Array(e+1).join(this.__indent_string)),t&&(n+=Array(t+1).join(" ")),this.__cache.push(n)},_.prototype.__add_outputline=function(){this.previous_line=this.current_line,this.current_line=this.next_line.clone_empty(),this.__lines.push(this.current_line)},_.prototype.get_line_number=function(){return this.__lines.length},_.prototype.get_indent_string=function(t,e){return this.__indent_cache.get_indent_string(t,e)},_.prototype.get_indent_size=function(t,e){return this.__indent_cache.get_indent_size(t,e)},_.prototype.is_empty=function(){return!this.previous_line&&this.current_line.is_empty()},_.prototype.add_new_line=function(t){return!(this.is_empty()||!t&&this.just_added_newline()||(this.raw||this.__add_outputline(),0))},_.prototype.get_code=function(t){this.trim(!0);var e=this.current_line.pop();return e&&("\n"===e[e.length-1]&&(e=e.replace(/\n+$/g,"")),this.current_line.push(e)),this._end_with_newline&&this.__add_outputline(),e=this.__lines.join("\n"),"\n"!==t&&(e=e.replace(/[\n]/g,t)),e},_.prototype.set_wrap_point=function(){this.current_line._set_wrap_point()},_.prototype.set_indent=function(t,e){return t=t||0,e=e||0,this.next_line.set_indent(t,e),1
=t.length&&this.__input.substring(e-t.length,e).toLowerCase()===t},t.exports.InputScanner=i},function(t,e,n){var i=n(8).InputScanner,u=n(3).Token,_=n(10).TokenStream,a=n(11).WhitespacePattern,s={START:"TK_START",RAW:"TK_RAW",EOF:"TK_EOF"};e=function(t,e){this._input=new i(t),this._options=e||{},this.__tokens=null,this._patterns={},this._patterns.whitespace=new a(this._input)},e.prototype.tokenize=function(){this._input.restart(),this.__tokens=new _,this._reset();for(var t,e=new u(s.START,""),n=null,i=[],a=new _;e.type!==s.EOF;){for(t=this._get_next_token(e,n);this._is_comment(t);)a.add(t),t=this._get_next_token(e,n);a.isEmpty()||(t.comments_before=a,a=new _),t.parent=n,this._is_opening(t)?(i.push(n),n=t):n&&this._is_closing(t,n)&&(t.opened=n,n.closed=t,n=i.pop(),t.parent=n),t.previous=e,e.next=t,this.__tokens.add(t),e=t}return this.__tokens},e.prototype._is_first_token=function(){return this.__tokens.isEmpty()},e.prototype._reset=function(){},e.prototype._get_next_token=function(t,e){this._readWhitespace();var n=this._input.read(/.+/g);return n?this._create_token(s.RAW,n):this._create_token(s.EOF,"")},e.prototype._is_comment=function(t){return!1},e.prototype._is_opening=function(t){return!1},e.prototype._is_closing=function(t,e){return!1},e.prototype._create_token=function(t,e){return new u(t,e,this._patterns.whitespace.newline_count,this._patterns.whitespace.whitespace_before_token)},e.prototype._readWhitespace=function(){return this._patterns.whitespace.read()},t.exports.Tokenizer=e,t.exports.TOKEN=s},function(t,e,n){function i(t){this.__tokens=[],this.__tokens_length=this.__tokens.length,this.__position=0,this.__parent_token=t}i.prototype.restart=function(){this.__position=0},i.prototype.isEmpty=function(){return 0===this.__tokens_length},i.prototype.hasNext=function(){return this.__position
/),erb:n.starting_with(/<%[^%]/).until_after(/[^%]%>/),django:n.starting_with(/{%/).until_after(/%}/),django_value:n.starting_with(/{{/).until_after(/}}/),django_comment:n.starting_with(/{#/).until_after(/#}/)}}var u=n(12).Pattern,_={django:!1,erb:!1,handlebars:!1,php:!1};i.prototype=new u,i.prototype._create=function(){return new i(this._input,this)},i.prototype._update=function(){this.__set_templated_pattern()},i.prototype.disable=function(t){var e=this._create();return e._disabled[t]=!0,e._update(),e},i.prototype.read_options=function(t){var e,n=this._create();for(e in _)n._disabled[e]=-1===t.templating.indexOf(e);return n._update(),n},i.prototype.exclude=function(t){var e=this._create();return e._excluded[t]=!0,e._update(),e},i.prototype.read=function(){for(var t="",e=(t=this._match_pattern?this._input.read(this._starting_pattern):this._input.read(this._starting_pattern,this.__template_pattern),this._read_template());e;)this._match_pattern?e+=this._input.read(this._match_pattern):e+=this._input.readUntil(this.__template_pattern),t+=e,e=this._read_template();return this._until_after&&(t+=this._input.readUntilAfter(this._until_pattern)),t},i.prototype.__set_templated_pattern=function(){var t=[];this._disabled.php||t.push(this.__patterns.php._starting_pattern.source),this._disabled.handlebars||t.push(this.__patterns.handlebars._starting_pattern.source),this._disabled.erb||t.push(this.__patterns.erb._starting_pattern.source),this._disabled.django||(t.push(this.__patterns.django._starting_pattern.source),t.push(this.__patterns.django_value._starting_pattern.source),t.push(this.__patterns.django_comment._starting_pattern.source)),this._until_pattern&&t.push(this._until_pattern.source),this.__template_pattern=this._input.get_regexp("(?:"+t.join("|")+")")},i.prototype._read_template=function(){var t="",e=this._input.peek();return"<"===e?(e=this._input.peek(1),this._disabled.php||this._excluded.php||"?"!==e||(t=t||this.__patterns.php.read()),this._disabled.erb||this._excluded.erb||"%"!==e||(t=t||this.__patterns.erb.read())):"{"===e&&(this._disabled.handlebars||this._excluded.handlebars||(t=(t=(t=t||this.__patterns.handlebars_comment.read())||this.__patterns.handlebars_unescaped.read())||this.__patterns.handlebars.read()),this._disabled.django||(this._excluded.django||this._excluded.handlebars||(t=t||this.__patterns.django_value.read()),this._excluded.django||(t=(t=t||this.__patterns.django_comment.read())||this.__patterns.django.read()))),t},t.exports.TemplatablePattern=i},,,,function(t,e,n){var i=n(19).Beautifier,u=n(20).Options;t.exports=function(t,e,n,u){return new i(t,e,n,u).beautify()},t.exports.defaultOptions=function(){return new u}},function(t,e,n){function i(t,e,n){this.parent=t||null,this.tag=e?e.tag_name:"",this.indent_level=n||0,this.parser_token=e||null}function u(t){this._printer=t,this._current_frame=null}function _(t,e,n,i){this._source_text=t||"",e=e||{},this._js_beautify=n,this._css_beautify=i,this._tag_stack=null,this._options=new a(e,"html"),this._is_wrap_attributes_force="force"===this._options.wrap_attributes.substr(0,5),this._is_wrap_attributes_force_expand_multiline="force-expand-multiline"===this._options.wrap_attributes,this._is_wrap_attributes_force_aligned="force-aligned"===this._options.wrap_attributes,this._is_wrap_attributes_aligned_multiple="aligned-multiple"===this._options.wrap_attributes,this._is_wrap_attributes_preserve="preserve"===this._options.wrap_attributes.substr(0,8),this._is_wrap_attributes_preserve_aligned="preserve-aligned"===this._options.wrap_attributes}var a=n(20).Options,s=n(2).Output,r=n(21).Tokenizer,o=n(21).TOKEN,p=/\r\n|[\r\n]/,h=/\r\n|[\r\n]/g,c=function(t,e){this.alignment_size=this.indent_level=0,this.max_preserve_newlines=t.max_preserve_newlines,this.preserve_newlines=t.preserve_newlines,this._output=new s(t,e)};c.prototype.current_line_has_match=function(t){return this._output.current_line.has_match(t)},c.prototype.set_space_before_token=function(t,e){this._output.space_before_token=t,this._output.non_breaking_space=e},c.prototype.set_wrap_point=function(){this._output.set_indent(this.indent_level,this.alignment_size),this._output.set_wrap_point()},c.prototype.add_raw_token=function(t){this._output.add_raw_token(t)},c.prototype.print_preserved_newlines=function(t){var e=0;for(t.type!==o.TEXT&&t.previous.type!==o.TEXT&&(e=t.newlines?1:0),this.preserve_newlines&&(e=t.newlines
(t=this.indent_level+(t||0))?"":this._output.get_indent_string(t)},u.prototype.get_parser_token=function(){return this._current_frame?this._current_frame.parser_token:null},u.prototype.record_tag=function(t){this._current_frame=new i(this._current_frame,t,this._printer.indent_level)},u.prototype._try_pop_frame=function(t){var e=null;return t&&(e=t.parser_token,this._printer.indent_level=t.indent_level,this._current_frame=t.parent),e},u.prototype._get_frame=function(t,e){for(var n=this._current_frame;n&&-1===t.indexOf(n.tag);){if(e&&-1!==e.indexOf(n.tag)){n=null;break}n=n.parent}return n},u.prototype.try_pop=function(t,e){var n=this._get_frame([t],e);return this._try_pop_frame(n)},u.prototype.indent_to_tag=function(t){(t=this._get_frame(t))&&(this._printer.indent_level=t.indent_level)},_.prototype.beautify=function(){if(this._options.disabled)return this._source_text;var t=this._source_text,e=this._options.eol;"auto"===this._options.eol&&(e="\n",t&&p.test(t)&&(e=t.match(p)[0]));var n=(t=t.replace(h,"\n")).match(/^[\t ]*/)[0],i={text:"",type:""},_=new l;n=new c(this._options,n),t=new r(t,this._options).tokenize(),this._tag_stack=new u(n);for(var a=null,s=t.next();s.type!==o.EOF;)s.type===o.TAG_OPEN||s.type===o.COMMENT?_=a=this._handle_tag_open(n,s,_,i):s.type===o.ATTRIBUTE||s.type===o.EQUALS||s.type===o.VALUE||s.type===o.TEXT&&!_.tag_complete?a=this._handle_inside_tag(n,s,_,t):s.type===o.TAG_CLOSE?a=this._handle_tag_close(n,s,_):s.type===o.TEXT?a=this._handle_text(n,s,_):n.add_raw_token(s),i=a,s=t.next();return n._output.get_code(e)},_.prototype._handle_tag_close=function(t,e,n){var i={text:e.text,type:e.type};return t.alignment_size=0,n.tag_complete=!0,t.set_space_before_token(e.newlines||""!==e.whitespace_before,!0),n.is_unformatted?t.add_raw_token(e):("<"===n.tag_start_char&&(t.set_space_before_token("/"===e.text[0],!0),this._is_wrap_attributes_force_expand_multiline&&n.has_wrapped_attrs&&t.print_newline(!1)),t.print_token(e)),!n.indent_content||n.is_unformatted||n.is_content_unformatted||(t.indent(),n.indent_content=!1),n.is_inline_element||n.is_unformatted||n.is_content_unformatted||t.set_wrap_point(),i},_.prototype._handle_inside_tag=function(t,e,n,i){var u=n.has_wrapped_attrs,_={text:e.text,type:e.type};if(t.set_space_before_token(e.newlines||""!==e.whitespace_before,!0),n.is_unformatted)t.add_raw_token(e);else if("{"===n.tag_start_char&&e.type===o.TEXT)t.print_preserved_newlines(e)?(e.newlines=0,t.add_raw_token(e)):t.print_token(e);else{if(e.type===o.ATTRIBUTE?(t.set_space_before_token(!0),n.attr_count+=1):(e.type===o.EQUALS||e.type===o.VALUE&&e.previous.type===o.EQUALS)&&t.set_space_before_token(!1),e.type===o.ATTRIBUTE&&"<"===n.tag_start_char&&((this._is_wrap_attributes_preserve||this._is_wrap_attributes_preserve_aligned)&&(t.traverse_whitespace(e),u=u||0!==e.newlines),this._is_wrap_attributes_force)){var a=1
r&&s.type!==o.EOF&&s.type!==o.TAG_CLOSE);a=!a}a&&(t.print_newline(!1),u=!0)}t.print_token(e),u=u||t.previous_token_wrapped(),n.has_wrapped_attrs=u}return _},_.prototype._handle_text=function(t,e,n){var i={text:e.text,type:"TK_CONTENT"};return n.custom_beautifier_name?this._print_custom_beatifier_text(t,e,n):n.is_unformatted||n.is_content_unformatted?t.add_raw_token(e):(t.traverse_whitespace(e),t.print_token(e)),i},_.prototype._print_custom_beatifier_text=function(t,e,n){var i=this;if(""!==e.text){var u,a=e.text,s=1,r="",o="";if("javascript"===n.custom_beautifier_name&&"function"==typeof this._js_beautify?u=this._js_beautify:"css"===n.custom_beautifier_name&&"function"==typeof this._css_beautify?u=this._css_beautify:"html"===n.custom_beautifier_name&&(u=function(t,e){return new _(t,e,i._js_beautify,i._css_beautify).beautify()}),"keep"===this._options.indent_scripts?s=0:"separate"===this._options.indent_scripts&&(s=-t.indent_level),s=t.get_full_indent(s),a=a.replace(/\n[ \t]*$/,""),"html"!==n.custom_beautifier_name&&"<"===a[0]&&a.match(/^(\x3c!--|]*)/),this.tag_check=n?n[1]:""):(n=e.text.match(/^{{(?:[\^]|#\*?)?([^\s}]+)/),this.tag_check=n?n[1]:"","{{#>"===e.text&&">"===this.tag_check&&null!==e.next&&(this.tag_check=e.next.text)),this.tag_check=this.tag_check.toLowerCase(),e.type===o.COMMENT&&(this.tag_complete=!0),this.tag_name=(this.is_start_tag="/"!==this.tag_check.charAt(0))?this.tag_check:this.tag_check.substr(1),this.is_end_tag=(this.is_end_tag=!this.is_start_tag||e.closed&&"/>"===e.closed.text)||"{"===this.tag_start_char&&(3>this.text.length||/[^#\^]/.test(this.text.charAt(2)))):this.tag_complete=!0};_.prototype._get_tag_open_token=function(t){return(t=new l(this._tag_stack.get_parser_token(),t)).alignment_size=this._options.wrap_attributes_indent_size,t.is_end_tag=t.is_end_tag||-1!==this._options.void_elements.indexOf(t.tag_check),t.is_empty_element=t.tag_complete||t.is_start_tag&&t.is_end_tag,t.is_unformatted=!t.tag_complete&&-1!==this._options.unformatted.indexOf(t.tag_check),t.is_content_unformatted=!t.is_empty_element&&-1!==this._options.content_unformatted.indexOf(t.tag_check),t.is_inline_element=-1!==this._options.inline.indexOf(t.tag_name)||"{"===t.tag_start_char,t},_.prototype._set_tag_position=function(t,e,n,i,u){if(!n.is_empty_element)if(n.is_end_tag)n.start_tag_token=this._tag_stack.try_pop(n.tag_name);else if(this._do_optional_end_element(n)&&(n.is_inline_element||t.print_newline(!1)),this._tag_stack.record_tag(n),!("script"!==n.tag_name&&"style"!==n.tag_name||n.is_unformatted||n.is_content_unformatted)){var _=n.tag_check,a=null,s=null;if(e.closed){"script"===_?a="text/javascript":"style"===_&&(a="text/css"),_=null;for(var r=e.next;r.type!==o.EOF&&e.closed!==r;){if(r.type===o.ATTRIBUTE&&"type"===r.text){r.next&&r.next.type===o.EQUALS&&r.next.next&&r.next.next.type===o.VALUE&&(_=r.next.next.text);break}r=r.next}-1<(a=_||a).search("text/css")?s="css":-1
]|\/>/),element_name:n.until(/[\n\r\t >\/]/),handlebars_comment:u.starting_with(/{{!--/).until_after(/--}}/),handlebars:u.starting_with(/{{/).until_after(/}}/),handlebars_open:u.until(/[\n\r\t }]/),handlebars_raw_close:u.until(/}}/),comment:u.starting_with(/\x3c!--/).until_after(/--\x3e/),cdata:u.starting_with(//),processing:u.starting_with(/<\?/).until_after(/\?>/)},this._options.indent_handlebars&&(this.__patterns.word=this.__patterns.word.exclude("handlebars")),this._unformatted_content_delimiter=null,this._options.unformatted_content_delimiter&&(n=this._input.get_literal_regexp(this._options.unformatted_content_delimiter),this.__patterns.unformatted_content_delimiter=u.matching(n).until_after(n))},n.prototype=new i,n.prototype._is_comment=function(t){return!1},n.prototype._is_opening=function(t){return t.type===s.TAG_OPEN},n.prototype._is_closing=function(t,e){return t.type===s.TAG_CLOSE&&e&&((">"===t.text||"/>"===t.text)&&"<"===e.text[0]||"}}"===t.text&&"{"===e.text[0]&&"{"===e.text[1])},n.prototype._reset=function(){this._current_tag_name=""},n.prototype._get_next_token=function(t,e){var n=null;this._readWhitespace();var i=this._input.peek();return null===i?this._create_token(s.EOF,""):(n=(n=(n=(n=(n=(n=(n=(n=n||this._read_open_handlebars(i,e))||this._read_attribute(i,t,e))||this._read_close(i,e))||this._read_raw_content(i,t,e))||this._read_content_word(i))||this._read_comment_or_cdata(i))||this._read_processing(i))||this._read_open(i,e))||this._create_token(s.UNKNOWN,this._input.next())},n.prototype._read_comment_or_cdata=function(t){var e=null,n=null,i=null;return"<"===t&&("!"===this._input.peek(1)&&((n=this.__patterns.comment.read())?(i=r.get_directives(n))&&"start"===i.ignore&&(n+=r.readIgnored(this._input)):n=this.__patterns.cdata.read()),n&&((e=this._create_token(s.COMMENT,n)).directives=i)),e},n.prototype._read_processing=function(t){var e=null,n=null;return"<"===t&&("!"!==(t=this._input.peek(1))&&"?"!==t||(n=(n=this.__patterns.conditional_comment.read())||this.__patterns.processing.read()),n&&((e=this._create_token(s.COMMENT,n)).directives=null)),e},n.prototype._read_open=function(t,e){var n=null,i=null;return e||"<"===t&&(n=this._input.next(),"/"===this._input.peek()&&(n+=this._input.next()),n+=this.__patterns.element_name.read(),i=this._create_token(s.TAG_OPEN,n)),i},n.prototype._read_open_handlebars=function(t,e){var n=null,i=null;return e||this._options.indent_handlebars&&"{"===t&&"{"===this._input.peek(1)&&("!"===this._input.peek(2)?(n=(n=this.__patterns.handlebars_comment.read())||this.__patterns.handlebars.read(),i=this._create_token(s.COMMENT,n)):(n=this.__patterns.handlebars_open.read(),i=this._create_token(s.TAG_OPEN,n))),i},n.prototype._read_close=function(t,e){var n=null,i=null;return e&&("<"===e.text[0]&&(">"===t||"/"===t&&">"===this._input.peek(1))?(n=this._input.next(),"/"===t&&(n+=this._input.next()),i=this._create_token(s.TAG_CLOSE,n)):"{"===e.text[0]&&"}"===t&&"}"===this._input.peek(1)&&(this._input.next(),this._input.next(),i=this._create_token(s.TAG_CLOSE,"}}"))),i},n.prototype._read_attribute=function(t,e,n){var i=null,u="";return n&&"<"===n.text[0]&&("="===t?i=this._create_token(s.EQUALS,this._input.next()):'"'===t||"'"===t?(e=this._input.next(),e+='"'===t?this.__patterns.double_quote.read():this.__patterns.single_quote.read(),i=this._create_token(s.VALUE,e)):(u=this.__patterns.attribute.read())&&(i=e.type===s.EQUALS?this._create_token(s.VALUE,u):this._create_token(s.ATTRIBUTE,u))),i},n.prototype._is_content_unformatted=function(t){return-1===this._options.void_elements.indexOf(t)&&(-1!==this._options.content_unformatted.indexOf(t)||-1!==this._options.unformatted.indexOf(t))},n.prototype._read_raw_content=function(t,e,n){var i="";if(n&&"{"===n.text[0])i=this.__patterns.handlebars_raw_close.read();else if(e.type===s.TAG_CLOSE&&"<"===e.opened.text[0]&&"/"!==e.text[0])if("script"===(e=e.opened.text.substr(1).toLowerCase())||"style"===e){if(t=this._read_comment_or_cdata(t))return t.type=s.TEXT,t;i=this._input.readUntil(new RegExp(""+e+"[\\n\\r\\t ]*?>","ig"))}else this._is_content_unformatted(e)&&(i=this._input.readUntil(new RegExp(""+e+"[\\n\\r\\t ]*?>","ig")));return i?this._create_token(s.TEXT,i):null},n.prototype._read_content_word=function(t){var e="";if(this._options.unformatted_content_delimiter&&t===this._options.unformatted_content_delimiter[0]&&(e=this.__patterns.unformatted_content_delimiter.read()),e||(e=this.__patterns.word.read()),e)return this._create_token(s.TEXT,e)},t.exports.Tokenizer=n,t.exports.TOKEN=s}]);if("function"==typeof define&&define.amd)define("beautify-html.js",["require","./beautify","./beautify-css"],(function(e){var n=e("./beautify"),i=e("./beautify-css");return{html_beautify:function(e,u){return t(e,u,n.js_beautify,i.css_beautify)}}}));else if("undefined"!=typeof exports){var e=require("./beautify.js"),n=require("./beautify-css.js");exports.html_beautify=function(i,u){return t(i,u,e.js_beautify,n.css_beautify)}}else"undefined"!=typeof window?window.html_beautify=function(e,n){return t(e,n,window.js_beautify,window.css_beautify)}:"undefined"!=typeof global&&(global.html_beautify=function(e,n){return t(e,n,global.js_beautify,global.css_beautify)})}(),function(t){"function"==typeof t.define&&(t.define("beautify",["beautify.js"],(function(t){return t})),t.define("beautify-css",[],(function(){return{css_beautify:void 0}})),t.define("beautifyModule",["beautify","beautify-html.js"],(function(e,n){t.js_beautify=e.js_beautify,t.html_beautify=n.html_beautify})))}(this);