6 lines
9.8 KiB
JavaScript
6 lines
9.8 KiB
JavaScript
|
(self.webpackChunkant_design_pro=self.webpackChunkant_design_pro||[]).push([[13202],{13202:function(k,y,C){k=C.nmd(k),ace.define("ace/mode/xml_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(g,b,T){"use strict";var h=g("../lib/oop"),p=g("./text_highlight_rules").TextHighlightRules,x=function(v){var r="[_:a-zA-Z\xC0-\uFFFF][-_:.a-zA-Z0-9\xC0-\uFFFF]*";this.$rules={start:[{token:"string.cdata.xml",regex:"<\\!\\[CDATA\\[",next:"cdata"},{token:["punctuation.instruction.xml","keyword.instruction.xml"],regex:"(<\\?)("+r+")",next:"processing_instruction"},{token:"comment.start.xml",regex:"<\\!--",next:"comment"},{token:["xml-pe.doctype.xml","xml-pe.doctype.xml"],regex:"(<\\!)(DOCTYPE)(?=[\\s])",next:"doctype",caseInsensitive:!0},{include:"tag"},{token:"text.end-tag-open.xml",regex:"</"},{token:"text.tag-open.xml",regex:"<"},{include:"reference"},{defaultToken:"text.xml"}],processing_instruction:[{token:"entity.other.attribute-name.decl-attribute-name.xml",regex:r},{token:"keyword.operator.decl-attribute-equals.xml",regex:"="},{include:"whitespace"},{include:"string"},{token:"punctuation.xml-decl.xml",regex:"\\?>",next:"start"}],doctype:[{include:"whitespace"},{include:"string"},{token:"xml-pe.doctype.xml",regex:">",next:"start"},{token:"xml-pe.xml",regex:"[-_a-zA-Z0-9:]+"},{token:"punctuation.int-subset",regex:"\\[",push:"int_subset"}],int_subset:[{token:"text.xml",regex:"\\s+"},{token:"punctuation.int-subset.xml",regex:"]",next:"pop"},{token:["punctuation.markup-decl.xml","keyword.markup-decl.xml"],regex:"(<\\!)("+r+")",push:[{token:"text",regex:"\\s+"},{token:"punctuation.markup-decl.xml",regex:">",next:"pop"},{include:"string"}]}],cdata:[{token:"string.cdata.xml",regex:"\\]\\]>",next:"start"},{token:"text.xml",regex:"\\s+"},{token:"text.xml",regex:"(?:[^\\]]|\\](?!\\]>))+"}],comment:[{token:"comment.end.xml",regex:"-->",next:"start"},{defaultToken:"comment.xml"}],reference:[{token:"constant.language.escape.reference.xml",regex:"(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"}],attr_reference:[{token:"constant.language.escape.reference.attribute-value.xml",regex:"(?:&#[0-9]+;)|(?:&#x[0-9a-fA-F]+;)|(?:&[a-zA-Z0-9_:\\.-]+;)"}],tag:[{token:["meta.tag.punctuation.tag-open.xml","meta.tag.punctuation.end-tag-open.xml","meta.tag.tag-name.xml"],regex:"(?:(<)|(</))((?:"+r+":)?"+r+")",next:[{include:"attributes"},{token:"meta.tag.punctuation.tag-close.xml",regex:"/?>",next:"start"}]}],tag_whitespace:[{token:"text.tag-whitespace.xml",regex:"\\s+"}],whitespace:[{token:"text.whitespace.xml",regex:"\\s+"}],string:[{token:"string.xml",regex:"'",push:[{token:"string.xml",regex:"'",next:"pop"},{defaultToken:"string.xml"}]},{token:"string.xml",regex:'"',push:[{token:"string.xml",regex:'"',next:"pop"},{defaultToken:"string.xml"}]}],attributes:[{token:"entity.other.attribute-name.xml",regex:r},{token:"keyword.operator.attribute-equals.xml",regex:"="},{include:"tag_whitespace"},{include:"attribute_value"}],attribute_value:[{token:"string.attribute-value.xml",regex:"'",push:[{token:"string.attribute-value.xml",regex:"'",next:"pop"},{include:"attr_reference"},{defaultToken:"string.attribute-value.xml"}]},{token:"string.attribute-value.xml",regex:'"',push:[{token:"string.attribute-value.xml",regex:'"',next:"pop"},{include:"attr_reference"},{defaultToken:"string.attribute-value.xml"}]}]},this.constructor===x&&this.normalizeRules()};(function(){this.embedTagRules=function(v,r,s){this.$rules.tag.unshift({token:["meta.tag.punctuation.tag-open.xml","meta.tag."+s+".tag-name.xml"],regex:"(<)("+s+"(?=\\s|>|$))",next:[{include:"attributes"},{token:"meta.tag.punctuation.tag-close.xml",regex:"/?>",next:r+"start"}]}),this.$rules[s+"-end"]=[{include:"attributes"},{token:"meta.tag.punctuation.tag-close.xml",regex:"/?>",next:"start",onMatch:function(i,o,a){return a.splice(0),this.token}}],this.embedRules(v,r,[{token:["meta.tag.punctuation.end-tag-open.xml","meta.tag."+s+".tag-name.xml"],regex:"(</)("+s+"(?=\\s|>|$))",next:s+"-end"},{token:"string.cdata.xml",regex:"<\\!\\[CDATA\\["},{token:"string
|
||
|
`){var t=a.getCursorPosition(),u=e.getLine(t.row),n=new x(e,t.row,t.column),c=n.getCurrentToken();if(c&&c.type.indexOf("tag-close")!==-1){if(c.value=="/>")return;for(;c&&c.type.indexOf("tag-name")===-1;)c=n.stepBackward();if(!c)return;var d=c.value,w=n.getCurrentTokenRow();if(c=n.stepBackward(),!c||c.type.indexOf("end-tag")!==-1)return;if(this.voidElements&&!this.voidElements[d]){var m=e.getTokenAt(t.row,t.column+1),u=e.getLine(w),f=this.$getIndent(u),_=f+e.getTabString();return m&&m.value==="</"?{text:`
|
||
|
`+_+`
|
||
|
`+f,selection:[1,_.length,1,_.length]}:{text:`
|
||
|
`+_}}}}})};h.inherits(s,p),b.XmlBehaviour=s}),ace.define("ace/mode/folding/xml",["require","exports","module","ace/lib/oop","ace/range","ace/mode/folding/fold_mode"],function(g,b,T){"use strict";var h=g("../../lib/oop"),p=g("../../range").Range,x=g("./fold_mode").FoldMode,v=b.FoldMode=function(i,o){x.call(this),this.voidElements=i||{},this.optionalEndTags=h.mixin({},this.voidElements),o&&h.mixin(this.optionalEndTags,o)};h.inherits(v,x);var r=function(){this.tagName="",this.closing=!1,this.selfClosing=!1,this.start={row:0,column:0},this.end={row:0,column:0}};function s(i,o){return i.type.lastIndexOf(o+".xml")>-1}(function(){this.getFoldWidget=function(i,o,a){var e=this._getFirstTagInLine(i,a);return e?e.closing||!e.tagName&&e.selfClosing?o==="markbeginend"?"end":"":!e.tagName||e.selfClosing||this.voidElements.hasOwnProperty(e.tagName.toLowerCase())||this._findEndTagInLine(i,a,e.tagName,e.end.column)?"":"start":this.getCommentFoldWidget(i,a)},this.getCommentFoldWidget=function(i,o){return/comment/.test(i.getState(o))&&/<!-/.test(i.getLine(o))?"start":""},this._getFirstTagInLine=function(i,o){for(var a=i.getTokens(o),e=new r,l=0;l<a.length;l++){var t=a[l];if(s(t,"tag-open")){if(e.end.column=e.start.column+t.value.length,e.closing=s(t,"end-tag-open"),t=a[++l],!t)return null;for(e.tagName=t.value,e.end.column+=t.value.length,l++;l<a.length;l++)if(t=a[l],e.end.column+=t.value.length,s(t,"tag-close")){e.selfClosing=t.value=="/>";break}return e}else if(s(t,"tag-close"))return e.selfClosing=t.value=="/>",e;e.start.column+=t.value.length}return null},this._findEndTagInLine=function(i,o,a,e){for(var l=i.getTokens(o),t=0,u=0;u<l.length;u++){var n=l[u];if(t+=n.value.length,!(t<e)&&s(n,"end-tag-open")&&(n=l[u+1],n&&n.value==a))return!0}return!1},this.getFoldWidgetRange=function(i,o,a){var e=i.getMatchingTags({row:a,column:0});return e?new p(e.openTag.end.row,e.openTag.end.column,e.closeTag.start.row,e.closeTag.start.column):this.getCommentFoldWidget(i,a)&&i.getCommentFoldRange(a,i.getLine(a).length)}}).call(v.prototype)}),ace.define("ace/mode/xml",["require","exports","module","ace/lib/oop","ace/lib/lang","ace/mode/text","ace/mode/xml_highlight_rules","ace/mode/behaviour/xml","ace/mode/folding/xml","ace/worker/worker_client"],function(g,b,T){"use strict";var h=g("../lib/oop"),p=g("../lib/lang"),x=g("./text").Mode,v=g("./xml_highlight_rules").XmlHighlightRules,r=g("./behaviour/xml").XmlBehaviour,s=g("./folding/xml").FoldMode,i=g("../worker/worker_client").WorkerClient,o=function(){this.HighlightRules=v,this.$behaviour=new r,this.foldingRules=new s};h.inherits(o,x),function(){this.voidElements=p.arrayToMap([]),this.blockComment={start:"<!--",end:"-->"},this.createWorker=function(a){var e=new i(["ace"],"ace/mode/xml_worker","Worker");return e.attachToDocument(a.getDocument()),e.on("error",function(l){a.setAnnotations(l.data)}),e.on("terminate",function(){a.clearAnnotations()}),e},this.$id="ace/mode/xml"}.call(o.prototype),b.Mode=o}),function(){ace.require(["ace/mode/xml"],function(g){k&&(k.exports=g)})}()}}]);
|