import{n as e}from"./rolldown-runtime-DkW27tQK.js";function t(e,t,n){return t.tokenize=n,n(e,t)}function n(e,n){var i=e.next(),c=!1,p=h(e);if(i==`<`){if(e.match(`!--`,!0))return t(e,n,l);if(e.match(`![CDATA`,!1))return n.tokenize=u,`tag`;if(e.match(`?`,!1))return t(e,n,d);var g=e.eat(`/`);e.eatSpace();for(var b=``,x;x=e.eat(/[^\s\u00a0=<>\"\'\/?]/);)b+=x;return t(e,n,s(b,g))}if(i==`{`)return _(n,{type:`codeblock`}),null;if(i==`}`)return v(n),null;if(f(n))return i==`>`?`tag`:i==`/`&&e.eat(`>`)?(v(n),`tag`):`variable`;if(/\d/.test(i))return e.match(/^\d*(?:\.\d*)?(?:E[+\-]?\d+)?/),`atom`;if(i===`(`&&e.eat(`:`))return _(n,{type:`comment`}),t(e,n,r);if(!p&&(i===`"`||i===`'`))return a(e,n,i);if(i===`$`)return t(e,n,o);if(i===`:`&&e.eat(`=`))return`keyword`;if(i===`(`)return _(n,{type:`paren`}),null;if(i===`)`)return v(n),null;if(i===`[`)return _(n,{type:`bracket`}),null;if(i===`]`)return v(n),null;var S=y.propertyIsEnumerable(i)&&y[i];if(p&&i===`"`)for(;e.next()!==`"`;);if(p&&i===`'`)for(;e.next()!==`'`;);S||e.eatWhile(/[\w\$_-]/);var C=e.eat(`:`);!e.eat(`:`)&&C&&e.eatWhile(/[\w\$_-]/),e.match(/^[ \t]*\(/,!1)&&(c=!0);var w=e.current();return S=y.propertyIsEnumerable(w)&&y[w],c&&!S&&(S={type:`function_call`,style:`def`}),m(n)?(v(n),`variable`):((w==`element`||w==`attribute`||S.type==`axis_specifier`)&&_(n,{type:`xmlconstructor`}),S?S.style:`variable`)}function r(e,t){for(var n=!1,r=!1,i=0,a;a=e.next();){if(a==`)`&&n){if(i>0)i--;else{v(t);break}}else a==`:`&&r&&i++;n=a==`:`,r=a==`(`}return`comment`}function i(e,t){return function(r,i){for(var a;a=r.next();)if(a==e){v(i),t&&(i.tokenize=t);break}else if(r.match(`{`,!1)&&p(i))return _(i,{type:`codeblock`}),i.tokenize=n,`string`;return`string`}}function a(e,n,r,a){let o=i(r,a);return _(n,{type:`string`,name:r,tokenize:o}),t(e,n,o)}function o(e,t){var r=/[\w\$_-]/;if(e.eat(`"`)){for(;e.next()!==`"`;);e.eat(`:`)}else e.eatWhile(r),e.match(`:=`,!1)||e.eat(`:`);return e.eatWhile(r),t.tokenize=n,`variable`}function s(e,t){return function(r,i){if(r.eatSpace(),t&&r.eat(`>`))return v(i),i.tokenize=n,`tag`;if(r.eat(`/`)||_(i,{type:`tag`,name:e,tokenize:n}),r.eat(`>`))i.tokenize=n;else return i.tokenize=c,`tag`;return`tag`}}function c(e,t){var r=e.next();return r==`/`&&e.eat(`>`)?(p(t)&&v(t),f(t)&&v(t),`tag`):r==`>`?(p(t)&&v(t),`tag`):r==`=`?null:r==`"`||r==`'`?a(e,t,r,c):(p(t)||_(t,{type:`attribute`,tokenize:c}),e.eat(/[a-zA-Z_:]/),e.eatWhile(/[-a-zA-Z0-9_:.]/),e.eatSpace(),(e.match(`>`,!1)||e.match(`/`,!1))&&(v(t),t.tokenize=n),`attribute`)}function l(e,t){for(var r;r=e.next();)if(r==`-`&&e.match(`->`,!0))return t.tokenize=n,`comment`}function u(e,t){for(var r;r=e.next();)if(r==`]`&&e.match(`]`,!0))return t.tokenize=n,`comment`}function d(e,t){for(var r;r=e.next();)if(r==`?`&&e.match(`>`,!0))return t.tokenize=n,`processingInstruction`}function f(e){return g(e,`tag`)}function p(e){return g(e,`attribute`)}function m(e){return g(e,`xmlconstructor`)}function h(e){return e.current()===`"`?e.match(/^[^\"]+\"\:/,!1):e.current()===`'`&&e.match(/^[^\"]+\'\:/,!1)}function g(e,t){return e.stack.length&&e.stack[e.stack.length-1].type==t}function _(e,t){e.stack.push(t)}function v(e){e.stack.pop(),e.tokenize=e.stack.length&&e.stack[e.stack.length-1].tokenize||n}var y,b;function x(){return(x=e((()=>{y=function(){function e(e){return{type:e,style:`keyword`}}for(var t=e(`operator`),n={type:`atom`,style:`atom`},r={type:`punctuation`,style:null},i={type:`axis_specifier`,style:`qualifier`},a={",":r},o=`after.all.allowing.ancestor.ancestor-or-self.any.array.as.ascending.at.attribute.base-uri.before.boundary-space.by.case.cast.castable.catch.child.collation.comment.construction.contains.content.context.copy.copy-namespaces.count.decimal-format.declare.default.delete.descendant.descendant-or-self.descending.diacritics.different.distance.document.document-node.element.else.empty.empty-sequence.encoding.end.entire.every.exactly.except.external.first.following.following-sibling.for.from.ftand.ftnot.ft-option.ftor.function.fuzzy.greatest.group.if.import.in.inherit.insensitive.insert.instance.intersect.into.invoke.is.item.language.last.lax.least.let.levels.lowercase.map.modify.module.most.namespace.next.no.node.nodes.no-inherit.no-preserve.not.occurs.of.only.option.order.ordered.ordering.paragraph.paragraphs.parent.phrase.preceding.preceding-sibling.preserve.previous.processing-instruction.relationship.rename.replace.return.revalidation.same.satisfies.schema.schema-attribute.schema-element.score.self.sensitive.sentence.sentences.sequence.skip.sliding.some.stable.start.stemming.stop.strict.strip.switch.text.then.thesaurus.times.to.transform.treat.try.tumbling.type.typeswitch.union.unordered.update.updating.uppercase.using.validate.value.variable.version.weight.when.where.wildcards.window.with.without.word.words.xquery`.split(`.`),s=0,c=o.length;s`,`>=`,`<`,`<=`,`.`,`|`,`?`,`and`,`or`,`div`,`idiv`,`mod`,`*`,`/`,`+`,`-`],s=0,c=u.length;s