"use strict";const o=require("../../../../../../../_virtual/index40.js");require("../../../../../js-tokens@4.0.0/node_modules/js-tokens/index.js");require("../../../../../@babel_helper-validator-identifier@7.18.6/node_modules/@babel/helper-validator-identifier/lib/index.js");require("../../../../../chalk@2.4.2/node_modules/chalk/index.js");const v=require("../../../../../../../_virtual/index26.js"),_=require("../../../../../../../_virtual/index24.js"),g=require("../../../../../../../_virtual/index25.js");Object.defineProperty(o.__exports,"__esModule",{value:!0});o.__exports.default=w;o.__exports.getChalk=f;o.__exports.shouldHighlight=c;var s=_.__exports,a=g.__exports,u=v.chalk.exports;const h=new Set(["as","async","from","get","of","set"]);function x(r){return{keyword:r.cyan,capitalized:r.yellow,jsxIdentifier:r.yellow,punctuator:r.yellow,number:r.magenta,string:r.green,regex:r.magenta,comment:r.grey,invalid:r.white.bgRed.bold}}const y=/\r\n|[\n\r\u2028\u2029]/,m=/^[()[\]{}]$/;let d;{const r=/^[a-z][\w-]*$/i,n=function(e,t,i){if(e.type==="name"){if((0,a.isKeyword)(e.value)||(0,a.isStrictReservedWord)(e.value,!0)||h.has(e.value))return"keyword";if(r.test(e.value)&&(i[t-1]==="<"||i.slice(t-2,t)=="</"))return"jsxIdentifier";if(e.value[0]!==e.value[0].toLowerCase())return"capitalized"}return e.type==="punctuator"&&m.test(e.value)?"bracket":e.type==="invalid"&&(e.value==="@"||e.value==="#")?"punctuator":e.type};d=function*(e){let t;for(;t=s.default.exec(e);){const i=s.matchToToken(t);yield{type:n(i,t.index,e),value:i.value}}}}function j(r,n){let e="";for(const{type:t,value:i}of d(n)){const l=r[t];l?e+=i.split(y).map(p=>l(p)).join(`
`):e+=i}return e}function c(r){return!!u.supportsColor||r.forceColor}function f(r){return r.forceColor?new u.constructor({enabled:!0,level:1}):u}function w(r,n={}){if(r!==""&&c(n)){const e=f(n),t=x(e);return j(t,r)}else return r}
//# sourceMappingURL=index.js.map
