@langgraph-js/ui 5.5.4 → 5.5.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (56) hide show
  1. package/dist/assets/{arc-CCRsznwF.js → arc-WVCQhjSa.js} +1 -1
  2. package/dist/assets/{architectureDiagram-VXUJARFQ-BfObVU7b.js → architectureDiagram-VXUJARFQ-D9SrKD3y.js} +1 -1
  3. package/dist/assets/{blockDiagram-VD42YOAC-bLcZuVpA.js → blockDiagram-VD42YOAC-CMaERonH.js} +1 -1
  4. package/dist/assets/{c4Diagram-YG6GDRKO-Dd9G7NL1.js → c4Diagram-YG6GDRKO-CoJmKiid.js} +1 -1
  5. package/dist/assets/channel-CWz-ppLB.js +1 -0
  6. package/dist/assets/{chunk-4BX2VUAB-DZSMywfn.js → chunk-4BX2VUAB-CV--qKo6.js} +1 -1
  7. package/dist/assets/{chunk-55IACEB6-ajY5Rtne.js → chunk-55IACEB6-DhweZ0ii.js} +1 -1
  8. package/dist/assets/{chunk-B4BG7PRW-CybLsxdx.js → chunk-B4BG7PRW-jtA-ffKg.js} +1 -1
  9. package/dist/assets/{chunk-DI55MBZ5-C0-4F-3U.js → chunk-DI55MBZ5-Co-OzlZu.js} +1 -1
  10. package/dist/assets/{chunk-FMBD7UC4-X_3IcCSx.js → chunk-FMBD7UC4-B-36vljg.js} +1 -1
  11. package/dist/assets/{chunk-QN33PNHL-Bom7Zn6N.js → chunk-QN33PNHL-D9mef-NY.js} +1 -1
  12. package/dist/assets/{chunk-QZHKN3VN-CvrNSlnQ.js → chunk-QZHKN3VN-PKL0oBi_.js} +1 -1
  13. package/dist/assets/{chunk-TZMSLE5B-BMgUWgQK.js → chunk-TZMSLE5B-Dsn0-kOR.js} +1 -1
  14. package/dist/assets/classDiagram-2ON5EDUG-D28cezvO.js +1 -0
  15. package/dist/assets/classDiagram-v2-WZHVMYZB-D28cezvO.js +1 -0
  16. package/dist/assets/clone-B42FQsGa.js +1 -0
  17. package/dist/assets/{cose-bilkent-S5V4N54A-DdQbiA16.js → cose-bilkent-S5V4N54A-VnjNd4dQ.js} +1 -1
  18. package/dist/assets/{dagre-6UL2VRFP-2jZsJhIh.js → dagre-6UL2VRFP-D_I57Lj9.js} +1 -1
  19. package/dist/assets/{diagram-PSM6KHXK-B6C7l-bv.js → diagram-PSM6KHXK-HwA0KaVT.js} +1 -1
  20. package/dist/assets/{diagram-QEK2KX5R-CF6AMwmL.js → diagram-QEK2KX5R-Bk9Jw5N9.js} +1 -1
  21. package/dist/assets/{diagram-S2PKOQOG-B0WBxLDG.js → diagram-S2PKOQOG-DmCObSV2.js} +1 -1
  22. package/dist/assets/{erDiagram-Q2GNP2WA-ESbsyWDG.js → erDiagram-Q2GNP2WA-BOVQCyg7.js} +1 -1
  23. package/dist/assets/{flowDiagram-NV44I4VS-Bz6n61Nw.js → flowDiagram-NV44I4VS-KyZ5TS82.js} +1 -1
  24. package/dist/assets/{ganttDiagram-LVOFAZNH-BbfwlM24.js → ganttDiagram-LVOFAZNH-CMmlJAgm.js} +1 -1
  25. package/dist/assets/{gitGraphDiagram-NY62KEGX-CU1_889Q.js → gitGraphDiagram-NY62KEGX-BFOsZqAj.js} +1 -1
  26. package/dist/assets/{graph-Dl8eFIRQ.js → graph-DO4T8RhC.js} +1 -1
  27. package/dist/assets/{index-H4WNGlF1.js → index-BpV-aY20.js} +5 -5
  28. package/dist/assets/{infoDiagram-F6ZHWCRC-J0ZcIHpI.js → infoDiagram-F6ZHWCRC-23SkJeY3.js} +1 -1
  29. package/dist/assets/{isUndefined-Ds0P7m0l.js → isUndefined-BiEVyTmN.js} +1 -1
  30. package/dist/assets/{journeyDiagram-XKPGCS4Q-CXasqH68.js → journeyDiagram-XKPGCS4Q-k8jbOiVD.js} +1 -1
  31. package/dist/assets/{kanban-definition-3W4ZIXB7-DutwIYFW.js → kanban-definition-3W4ZIXB7-BP7Xrq9r.js} +1 -1
  32. package/dist/assets/{layout-Bg16SQtM.js → layout-CyxG1NeQ.js} +1 -1
  33. package/dist/assets/{linear-BV8JH_WF.js → linear-DQNxs4T7.js} +1 -1
  34. package/dist/assets/{mermaid.core-74bjT8p7.js → mermaid.core-kI_4o89S.js} +5 -5
  35. package/dist/assets/{min-CU3qZjj5.js → min-DETcxTwB.js} +1 -1
  36. package/dist/assets/{mindmap-definition-VGOIOE7T-DuBPY8B6.js → mindmap-definition-VGOIOE7T-DIzZRUcC.js} +1 -1
  37. package/dist/assets/{pieDiagram-ADFJNKIX-BBMDzp8C.js → pieDiagram-ADFJNKIX--7qZx3qQ.js} +1 -1
  38. package/dist/assets/{quadrantDiagram-AYHSOK5B-D8qI7cAm.js → quadrantDiagram-AYHSOK5B-DHXjZ77w.js} +1 -1
  39. package/dist/assets/{requirementDiagram-UZGBJVZJ-CCR63rSs.js → requirementDiagram-UZGBJVZJ-BxvG1nSa.js} +1 -1
  40. package/dist/assets/{sankeyDiagram-TZEHDZUN-BfALWY92.js → sankeyDiagram-TZEHDZUN-B2aKbDyv.js} +1 -1
  41. package/dist/assets/{sequenceDiagram-WL72ISMW-DLABL7jS.js → sequenceDiagram-WL72ISMW-C2mjYEb_.js} +1 -1
  42. package/dist/assets/{stateDiagram-FKZM4ZOC-C6mBBRHP.js → stateDiagram-FKZM4ZOC-p-7LlEtR.js} +1 -1
  43. package/dist/assets/stateDiagram-v2-4FDKWEC3-CT2TcWwE.js +1 -0
  44. package/dist/assets/{timeline-definition-IT6M3QCI-Wlqb2wZi.js → timeline-definition-IT6M3QCI-DY9iviWh.js} +1 -1
  45. package/dist/assets/{treemap-KMMF4GRG-CbnX4hqf.js → treemap-KMMF4GRG-CJoB2Fs4.js} +1 -1
  46. package/dist/assets/{xychartDiagram-PRI3JC2R-Blxs0jT7.js → xychartDiagram-PRI3JC2R-BoMJyak2.js} +1 -1
  47. package/dist/index.html +1 -1
  48. package/package.json +2 -2
  49. package/src/chat/components/MessageBox.tsx +2 -12
  50. package/src/chat/components/MessageTool.tsx +4 -5
  51. package/src/chat/tools/create_artifacts.tsx +0 -1
  52. package/dist/assets/channel-CcullKYL.js +0 -1
  53. package/dist/assets/classDiagram-2ON5EDUG-BDI83uK2.js +0 -1
  54. package/dist/assets/classDiagram-v2-WZHVMYZB-BDI83uK2.js +0 -1
  55. package/dist/assets/clone-BVSHSqaR.js +0 -1
  56. package/dist/assets/stateDiagram-v2-4FDKWEC3-Bfp03N2r.js +0 -1
@@ -54,7 +54,7 @@ Error generating stack: `+Kt.message+`
54
54
  `,r:"\r",t:" "};function jsonrepair(e){let t=0,Ye="";ct(),nt()||gr(),ct();const rt=At(",");for(rt&&at(),isStartOfValue(e[t])&&endsWithCommaOrNewline(Ye)?(rt||(Ye=insertBeforeLastWhitespace(Ye,",")),zt()):rt&&(Ye=stripLastOccurrence(Ye,","));e[t]==="}"||e[t]==="]";)t++,at();if(t>=e.length)return Ye;fr();function nt(){at();const Er=Ut()||Ht()||Yt()||Vt()||Zt()||Qt(!1)||er();return at(),Er}function at(){let Er=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;const _r=t;let Tr=it(Er);do Tr=ot(),Tr&&(Tr=it(Er));while(Tr);return t>_r}function it(Er){const _r=Er?isWhitespace$1:isWhitespaceExceptNewline;let Tr="";for(;;)if(_r(e,t))Tr+=e[t],t++;else if(isSpecialWhitespace(e,t))Tr+=" ",t++;else break;return Tr.length>0?(Ye+=Tr,!0):!1}function ot(){if(e[t]==="/"&&e[t+1]==="*"){for(;t<e.length&&!atEndOfBlockComment(e,t);)t++;return t+=2,!0}if(e[t]==="/"&&e[t+1]==="/"){for(;t<e.length&&e[t]!==`
55
55
  `;)t++;return!0}return!1}function ct(){if(e.slice(t,t+3)==="```"){if(t+=3,isFunctionNameCharStart(e[t]))for(;t<e.length&&isFunctionNameChar(e[t]);)t++;return at(),!0}return!1}function At(Er){return e[t]===Er?(Ye+=e[t],t++,!0):!1}function Rt(Er){return e[t]===Er?(t++,!0):!1}function qt(){return Rt("\\")}function Ft(){return at(),e[t]==="."&&e[t+1]==="."&&e[t+2]==="."?(t+=3,at(),Rt(","),!0):!1}function Ut(){if(e[t]==="{"){Ye+="{",t++,at(),Rt(",")&&at();let Er=!0;for(;t<e.length&&e[t]!=="}";){let _r;if(Er?(_r=!0,Er=!1):(_r=At(","),_r||(Ye=insertBeforeLastWhitespace(Ye,",")),at()),Ft(),!(Yt()||Qt(!0))){e[t]==="}"||e[t]==="{"||e[t]==="]"||e[t]==="["||e[t]===void 0?Ye=stripLastOccurrence(Ye,","):dr();break}at();const ur=At(":"),cr=t>=e.length;ur||(isStartOfValue(e[t])||cr?Ye=insertBeforeLastWhitespace(Ye,":"):vr()),nt()||(ur||cr?Ye+="null":vr())}return e[t]==="}"?(Ye+="}",t++):Ye=insertBeforeLastWhitespace(Ye,"}"),!0}return!1}function Ht(){if(e[t]==="["){Ye+="[",t++,at(),Rt(",")&&at();let Er=!0;for(;t<e.length&&e[t]!=="]";)if(Er?Er=!1:At(",")||(Ye=insertBeforeLastWhitespace(Ye,",")),Ft(),!nt()){Ye=stripLastOccurrence(Ye,",");break}return e[t]==="]"?(Ye+="]",t++):Ye=insertBeforeLastWhitespace(Ye,"]"),!0}return!1}function zt(){let Er=!0,_r=!0;for(;_r;)Er?Er=!1:At(",")||(Ye=insertBeforeLastWhitespace(Ye,",")),_r=nt();_r||(Ye=stripLastOccurrence(Ye,",")),Ye=`[
56
56
  `.concat(Ye,`
57
- ]`)}function Yt(){let Er=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,_r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:-1,Tr=e[t]==="\\";if(Tr&&(t++,Tr=!0),isQuote(e[t])){const ur=isDoubleQuote(e[t])?isDoubleQuote:isSingleQuote(e[t])?isSingleQuote:isSingleQuoteLike(e[t])?isSingleQuoteLike:isDoubleQuoteLike,cr=t,yr=Ye.length;let ir='"';for(t++;;){if(t>=e.length){const or=nr(t-1);return!Er&&isDelimiter(e.charAt(or))?(t=cr,Ye=Ye.substring(0,yr),Yt(!0)):(ir=insertBeforeLastWhitespace(ir,'"'),Ye+=ir,!0)}else{if(t===_r)return ir=insertBeforeLastWhitespace(ir,'"'),Ye+=ir,!0;if(ur(e[t])){const or=t,hr=ir.length;if(ir+='"',t++,Ye+=ir,at(!1),Er||t>=e.length||isDelimiter(e[t])||isQuote(e[t])||isDigit(e[t]))return Gt(),!0;const Sr=nr(or-1),wr=e.charAt(Sr);if(wr===",")return t=cr,Ye=Ye.substring(0,yr),Yt(!1,Sr);if(isDelimiter(wr))return t=cr,Ye=Ye.substring(0,yr),Yt(!0);Ye=Ye.substring(0,yr),t=or+1,ir="".concat(ir.substring(0,hr),"\\").concat(ir.substring(hr))}else if(Er&&isUnquotedStringDelimiter(e[t])){if(e[t-1]===":"&&regexUrlStart.test(e.substring(cr+1,t+2)))for(;t<e.length&&regexUrlChar.test(e[t]);)ir+=e[t],t++;return ir=insertBeforeLastWhitespace(ir,'"'),Ye+=ir,Gt(),!0}else if(e[t]==="\\"){const or=e.charAt(t+1);if(escapeCharacters[or]!==void 0)ir+=e.slice(t,t+2),t+=2;else if(or==="u"){let Sr=2;for(;Sr<6&&isHex(e[t+Sr]);)Sr++;Sr===6?(ir+=e.slice(t,t+6),t+=6):t+Sr>=e.length?t=e.length:mr()}else ir+=or,t+=2}else{const or=e.charAt(t);or==='"'&&e[t-1]!=="\\"?(ir+="\\".concat(or),t++):isControlCharacter(or)?(ir+=controlCharacters[or],t++):(isValidStringCharacter(or)||lr(or),ir+=or,t++)}}Tr&&qt()}}return!1}function Gt(){let Er=!1;for(at();e[t]==="+";){Er=!0,t++,at(),Ye=stripLastOccurrence(Ye,'"',!0);const _r=Ye.length;Yt()?Ye=removeAtIndex(Ye,_r,1):Ye=insertBeforeLastWhitespace(Ye,'"')}return Er}function Vt(){const Er=t;if(e[t]==="-"){if(t++,ar())return sr(Er),!0;if(!isDigit(e[t]))return t=Er,!1}for(;isDigit(e[t]);)t++;if(e[t]==="."){if(t++,ar())return sr(Er),!0;if(!isDigit(e[t]))return t=Er,!1;for(;isDigit(e[t]);)t++}if(e[t]==="e"||e[t]==="E"){if(t++,(e[t]==="-"||e[t]==="+")&&t++,ar())return sr(Er),!0;if(!isDigit(e[t]))return t=Er,!1;for(;isDigit(e[t]);)t++}if(!ar())return t=Er,!1;if(t>Er){const _r=e.slice(Er,t),Tr=/^0\d/.test(_r);return Ye+=Tr?'"'.concat(_r,'"'):_r,!0}return!1}function Zt(){return Xt("true","true")||Xt("false","false")||Xt("null","null")||Xt("True","true")||Xt("False","false")||Xt("None","null")}function Xt(Er,_r){return e.slice(t,t+Er.length)===Er?(Ye+=_r,t+=Er.length,!0):!1}function Qt(Er){const _r=t;if(isFunctionNameCharStart(e[t])){for(;t<e.length&&isFunctionNameChar(e[t]);)t++;let Tr=t;for(;isWhitespace$1(e,Tr);)Tr++;if(e[Tr]==="(")return t=Tr+1,nt(),e[t]===")"&&(t++,e[t]===";"&&t++),!0}for(;t<e.length&&!isUnquotedStringDelimiter(e[t])&&!isQuote(e[t])&&(!Er||e[t]!==":");)t++;if(e[t-1]===":"&&regexUrlStart.test(e.substring(_r,t+2)))for(;t<e.length&&regexUrlChar.test(e[t]);)t++;if(t>_r){for(;isWhitespace$1(e,t-1)&&t>0;)t--;const Tr=e.slice(_r,t);return Ye+=Tr==="undefined"?"null":JSON.stringify(Tr),e[t]==='"'&&t++,!0}}function er(){if(e[t]==="/"){const Er=t;for(t++;t<e.length&&(e[t]!=="/"||e[t-1]==="\\");)t++;return t++,Ye+='"'.concat(e.substring(Er,t),'"'),!0}}function nr(Er){let _r=Er;for(;_r>0&&isWhitespace$1(e,_r);)_r--;return _r}function ar(){return t>=e.length||isDelimiter(e[t])||isWhitespace$1(e,t)}function sr(Er){Ye+="".concat(e.slice(Er,t),"0")}function lr(Er){throw new JSONRepairError("Invalid character ".concat(JSON.stringify(Er)),t)}function fr(){throw new JSONRepairError("Unexpected character ".concat(JSON.stringify(e[t])),t)}function gr(){throw new JSONRepairError("Unexpected end of json string",e.length)}function dr(){throw new JSONRepairError("Object key expected",t)}function vr(){throw new JSONRepairError("Colon expected",t)}function mr(){const Er=e.slice(t,t+6);throw new JSONRepairError('Invalid unicode character "'.concat(Er,'"'),t)}}function atEndOfBlockComment(e,t){return e[t]==="*"&&e[t+1]==="/"}class ToolRenderData{constructor(t,Ye){this.message=t,this.client=Ye}getHumanInTheLoopData(){var Ye;const t=(Ye=this.client.humanInTheLoop)==null?void 0:Ye.find(tt=>{var rt;return(rt=tt.value.reviewConfigs)==null?void 0:rt.some(nt=>nt.actionName===this.message.name)});return t?{config:t,reviewConfig:t.value.reviewConfigs.find(tt=>tt.actionName===this.message.name),actionRequest:t.value.actionRequests.find(tt=>tt.name===this.message.name)}:null}sendResumeData(t){return t.type==="edit"&&(t.editedAction=t.edited_action),this.client.doneFEToolWaiting(this.message.id,{decisions:[t]})}get state(){var t,Ye,tt;return this.message.type==="tool"&&((Ye=(t=this.message)==null?void 0:t.additional_kwargs)!=null&&Ye.done)?"done":this.client.status==="interrupted"&&((tt=this.client.humanInTheLoop)!=null&&tt.some(rt=>{var nt;return(nt=rt.value.reviewConfigs)==null?void 0:nt.some(at=>at.actionName===this.message.name)}))?"interrupted":this.message.tool_input?"loading":"idle"}get input(){try{return JSON.parse(this.message.tool_input)}catch{return null}}get output(){return getMessageContent(this.message.content)}getJSONOutput(){return JSON.parse(this.output)}getJSONOutputSafe(){try{return JSON.parse(this.output)}catch{return null}}getInputRepaired(){try{return JSON.parse(jsonrepair(this.message.tool_input||""))}catch{return{}}}response(t){this.client.doneFEToolWaiting(this.message.id,JSON.stringify(t))}}const DEFAULT_FETCH_IMPLEMENTATION=(...e)=>fetch(...e),LANGSMITH_FETCH_IMPLEMENTATION_KEY=Symbol.for("lg:fetch_implementation"),_getFetchImplementation=()=>globalThis[LANGSMITH_FETCH_IMPLEMENTATION_KEY]??DEFAULT_FETCH_IMPLEMENTATION;var pRetry$1={exports:{}},retry$1={},retry_operation,hasRequiredRetry_operation;function requireRetry_operation(){if(hasRequiredRetry_operation)return retry_operation;hasRequiredRetry_operation=1;function e(t,Ye){typeof Ye=="boolean"&&(Ye={forever:Ye}),this._originalTimeouts=JSON.parse(JSON.stringify(t)),this._timeouts=t,this._options=Ye||{},this._maxRetryTime=Ye&&Ye.maxRetryTime||1/0,this._fn=null,this._errors=[],this._attempts=1,this._operationTimeout=null,this._operationTimeoutCb=null,this._timeout=null,this._operationStart=null,this._timer=null,this._options.forever&&(this._cachedTimeouts=this._timeouts.slice(0))}return retry_operation=e,e.prototype.reset=function(){this._attempts=1,this._timeouts=this._originalTimeouts.slice(0)},e.prototype.stop=function(){this._timeout&&clearTimeout(this._timeout),this._timer&&clearTimeout(this._timer),this._timeouts=[],this._cachedTimeouts=null},e.prototype.retry=function(t){if(this._timeout&&clearTimeout(this._timeout),!t)return!1;var Ye=new Date().getTime();if(t&&Ye-this._operationStart>=this._maxRetryTime)return this._errors.push(t),this._errors.unshift(new Error("RetryOperation timeout occurred")),!1;this._errors.push(t);var tt=this._timeouts.shift();if(tt===void 0)if(this._cachedTimeouts)this._errors.splice(0,this._errors.length-1),tt=this._cachedTimeouts.slice(-1);else return!1;var rt=this;return this._timer=setTimeout(function(){rt._attempts++,rt._operationTimeoutCb&&(rt._timeout=setTimeout(function(){rt._operationTimeoutCb(rt._attempts)},rt._operationTimeout),rt._options.unref&&rt._timeout.unref()),rt._fn(rt._attempts)},tt),this._options.unref&&this._timer.unref(),!0},e.prototype.attempt=function(t,Ye){this._fn=t,Ye&&(Ye.timeout&&(this._operationTimeout=Ye.timeout),Ye.cb&&(this._operationTimeoutCb=Ye.cb));var tt=this;this._operationTimeoutCb&&(this._timeout=setTimeout(function(){tt._operationTimeoutCb()},tt._operationTimeout)),this._operationStart=new Date().getTime(),this._fn(this._attempts)},e.prototype.try=function(t){console.log("Using RetryOperation.try() is deprecated"),this.attempt(t)},e.prototype.start=function(t){console.log("Using RetryOperation.start() is deprecated"),this.attempt(t)},e.prototype.start=e.prototype.try,e.prototype.errors=function(){return this._errors},e.prototype.attempts=function(){return this._attempts},e.prototype.mainError=function(){if(this._errors.length===0)return null;for(var t={},Ye=null,tt=0,rt=0;rt<this._errors.length;rt++){var nt=this._errors[rt],at=nt.message,it=(t[at]||0)+1;t[at]=it,it>=tt&&(Ye=nt,tt=it)}return Ye},retry_operation}var hasRequiredRetry$1;function requireRetry$1(){return hasRequiredRetry$1||(hasRequiredRetry$1=1,function(e){var t=requireRetry_operation();e.operation=function(Ye){var tt=e.timeouts(Ye);return new t(tt,{forever:Ye&&(Ye.forever||Ye.retries===1/0),unref:Ye&&Ye.unref,maxRetryTime:Ye&&Ye.maxRetryTime})},e.timeouts=function(Ye){if(Ye instanceof Array)return[].concat(Ye);var tt={retries:10,factor:2,minTimeout:1*1e3,maxTimeout:1/0,randomize:!1};for(var rt in Ye)tt[rt]=Ye[rt];if(tt.minTimeout>tt.maxTimeout)throw new Error("minTimeout is greater than maxTimeout");for(var nt=[],at=0;at<tt.retries;at++)nt.push(this.createTimeout(at,tt));return Ye&&Ye.forever&&!nt.length&&nt.push(this.createTimeout(at,tt)),nt.sort(function(it,ot){return it-ot}),nt},e.createTimeout=function(Ye,tt){var rt=tt.randomize?Math.random()+1:1,nt=Math.round(rt*Math.max(tt.minTimeout,1)*Math.pow(tt.factor,Ye));return nt=Math.min(nt,tt.maxTimeout),nt},e.wrap=function(Ye,tt,rt){if(tt instanceof Array&&(rt=tt,tt=null),!rt){rt=[];for(var nt in Ye)typeof Ye[nt]=="function"&&rt.push(nt)}for(var at=0;at<rt.length;at++){var it=rt[at],ot=Ye[it];Ye[it]=(function(At){var Rt=e.operation(tt),qt=Array.prototype.slice.call(arguments,1),Ft=qt.pop();qt.push(function(Ut){Rt.retry(Ut)||(Ut&&(arguments[0]=Rt.mainError()),Ft.apply(this,arguments))}),Rt.attempt(function(){At.apply(Ye,qt)})}).bind(Ye,ot),Ye[it].options=tt}}}(retry$1)),retry$1}var retry,hasRequiredRetry;function requireRetry(){return hasRequiredRetry||(hasRequiredRetry=1,retry=requireRetry$1()),retry}var hasRequiredPRetry;function requirePRetry(){if(hasRequiredPRetry)return pRetry$1.exports;hasRequiredPRetry=1;const e=requireRetry(),t=["Failed to fetch","NetworkError when attempting to fetch resource.","The Internet connection appears to be offline.","Network request failed"];class Ye extends Error{constructor(it){super(),it instanceof Error?(this.originalError=it,{message:it}=it):(this.originalError=new Error(it),this.originalError.stack=this.stack),this.name="AbortError",this.message=it}}const tt=(at,it,ot)=>{const ct=ot.retries-(it-1);return at.attemptNumber=it,at.retriesLeft=ct,at},rt=at=>t.includes(at),nt=(at,it)=>new Promise((ot,ct)=>{it={onFailedAttempt:()=>{},retries:10,...it};const At=e.operation(it);At.attempt(async Rt=>{try{ot(await at(Rt))}catch(qt){if(!(qt instanceof Error)){ct(new TypeError(`Non-error was thrown: "${qt}". You should only throw errors.`));return}if(qt instanceof Ye)At.stop(),ct(qt.originalError);else if(qt instanceof TypeError&&!rt(qt.message))At.stop(),ct(qt);else{tt(qt,Rt,it);try{await it.onFailedAttempt(qt)}catch(Ft){ct(Ft);return}At.retry(qt)||ct(At.mainError())}}})});return pRetry$1.exports=nt,pRetry$1.exports.default=nt,pRetry$1.exports.AbortError=Ye,pRetry$1.exports}var pRetryExports=requirePRetry();const pRetry=getDefaultExportFromCjs(pRetryExports);var dist$1={},eventemitter3$1={exports:{}},hasRequiredEventemitter3$1;function requireEventemitter3$1(){return hasRequiredEventemitter3$1||(hasRequiredEventemitter3$1=1,function(e){var t=Object.prototype.hasOwnProperty,Ye="~";function tt(){}Object.create&&(tt.prototype=Object.create(null),new tt().__proto__||(Ye=!1));function rt(ot,ct,At){this.fn=ot,this.context=ct,this.once=At||!1}function nt(ot,ct,At,Rt,qt){if(typeof At!="function")throw new TypeError("The listener must be a function");var Ft=new rt(At,Rt||ot,qt),Ut=Ye?Ye+ct:ct;return ot._events[Ut]?ot._events[Ut].fn?ot._events[Ut]=[ot._events[Ut],Ft]:ot._events[Ut].push(Ft):(ot._events[Ut]=Ft,ot._eventsCount++),ot}function at(ot,ct){--ot._eventsCount===0?ot._events=new tt:delete ot._events[ct]}function it(){this._events=new tt,this._eventsCount=0}it.prototype.eventNames=function(){var ct=[],At,Rt;if(this._eventsCount===0)return ct;for(Rt in At=this._events)t.call(At,Rt)&&ct.push(Ye?Rt.slice(1):Rt);return Object.getOwnPropertySymbols?ct.concat(Object.getOwnPropertySymbols(At)):ct},it.prototype.listeners=function(ct){var At=Ye?Ye+ct:ct,Rt=this._events[At];if(!Rt)return[];if(Rt.fn)return[Rt.fn];for(var qt=0,Ft=Rt.length,Ut=new Array(Ft);qt<Ft;qt++)Ut[qt]=Rt[qt].fn;return Ut},it.prototype.listenerCount=function(ct){var At=Ye?Ye+ct:ct,Rt=this._events[At];return Rt?Rt.fn?1:Rt.length:0},it.prototype.emit=function(ct,At,Rt,qt,Ft,Ut){var Ht=Ye?Ye+ct:ct;if(!this._events[Ht])return!1;var zt=this._events[Ht],Yt=arguments.length,Gt,Vt;if(zt.fn){switch(zt.once&&this.removeListener(ct,zt.fn,void 0,!0),Yt){case 1:return zt.fn.call(zt.context),!0;case 2:return zt.fn.call(zt.context,At),!0;case 3:return zt.fn.call(zt.context,At,Rt),!0;case 4:return zt.fn.call(zt.context,At,Rt,qt),!0;case 5:return zt.fn.call(zt.context,At,Rt,qt,Ft),!0;case 6:return zt.fn.call(zt.context,At,Rt,qt,Ft,Ut),!0}for(Vt=1,Gt=new Array(Yt-1);Vt<Yt;Vt++)Gt[Vt-1]=arguments[Vt];zt.fn.apply(zt.context,Gt)}else{var Zt=zt.length,Xt;for(Vt=0;Vt<Zt;Vt++)switch(zt[Vt].once&&this.removeListener(ct,zt[Vt].fn,void 0,!0),Yt){case 1:zt[Vt].fn.call(zt[Vt].context);break;case 2:zt[Vt].fn.call(zt[Vt].context,At);break;case 3:zt[Vt].fn.call(zt[Vt].context,At,Rt);break;case 4:zt[Vt].fn.call(zt[Vt].context,At,Rt,qt);break;default:if(!Gt)for(Xt=1,Gt=new Array(Yt-1);Xt<Yt;Xt++)Gt[Xt-1]=arguments[Xt];zt[Vt].fn.apply(zt[Vt].context,Gt)}}return!0},it.prototype.on=function(ct,At,Rt){return nt(this,ct,At,Rt,!1)},it.prototype.once=function(ct,At,Rt){return nt(this,ct,At,Rt,!0)},it.prototype.removeListener=function(ct,At,Rt,qt){var Ft=Ye?Ye+ct:ct;if(!this._events[Ft])return this;if(!At)return at(this,Ft),this;var Ut=this._events[Ft];if(Ut.fn)Ut.fn===At&&(!qt||Ut.once)&&(!Rt||Ut.context===Rt)&&at(this,Ft);else{for(var Ht=0,zt=[],Yt=Ut.length;Ht<Yt;Ht++)(Ut[Ht].fn!==At||qt&&!Ut[Ht].once||Rt&&Ut[Ht].context!==Rt)&&zt.push(Ut[Ht]);zt.length?this._events[Ft]=zt.length===1?zt[0]:zt:at(this,Ft)}return this},it.prototype.removeAllListeners=function(ct){var At;return ct?(At=Ye?Ye+ct:ct,this._events[At]&&at(this,At)):(this._events=new tt,this._eventsCount=0),this},it.prototype.off=it.prototype.removeListener,it.prototype.addListener=it.prototype.on,it.prefixed=Ye,it.EventEmitter=it,e.exports=it}(eventemitter3$1)),eventemitter3$1.exports}var pTimeout={exports:{}},pFinally,hasRequiredPFinally;function requirePFinally(){return hasRequiredPFinally||(hasRequiredPFinally=1,pFinally=(e,t)=>(t=t||(()=>{}),e.then(Ye=>new Promise(tt=>{tt(t())}).then(()=>Ye),Ye=>new Promise(tt=>{tt(t())}).then(()=>{throw Ye})))),pFinally}var hasRequiredPTimeout;function requirePTimeout(){if(hasRequiredPTimeout)return pTimeout.exports;hasRequiredPTimeout=1;const e=requirePFinally();class t extends Error{constructor(rt){super(rt),this.name="TimeoutError"}}const Ye=(tt,rt,nt)=>new Promise((at,it)=>{if(typeof rt!="number"||rt<0)throw new TypeError("Expected `milliseconds` to be a positive number");if(rt===1/0){at(tt);return}const ot=setTimeout(()=>{if(typeof nt=="function"){try{at(nt())}catch(Rt){it(Rt)}return}const ct=typeof nt=="string"?nt:`Promise timed out after ${rt} milliseconds`,At=nt instanceof Error?nt:new t(ct);typeof tt.cancel=="function"&&tt.cancel(),it(At)},rt);e(tt.then(at,it),()=>{clearTimeout(ot)})});return pTimeout.exports=Ye,pTimeout.exports.default=Ye,pTimeout.exports.TimeoutError=t,pTimeout.exports}var priorityQueue$1={},lowerBound={},hasRequiredLowerBound;function requireLowerBound(){if(hasRequiredLowerBound)return lowerBound;hasRequiredLowerBound=1,Object.defineProperty(lowerBound,"__esModule",{value:!0});function e(t,Ye,tt){let rt=0,nt=t.length;for(;nt>0;){const at=nt/2|0;let it=rt+at;tt(t[it],Ye)<=0?(rt=++it,nt-=at+1):nt=at}return rt}return lowerBound.default=e,lowerBound}var hasRequiredPriorityQueue$1;function requirePriorityQueue$1(){if(hasRequiredPriorityQueue$1)return priorityQueue$1;hasRequiredPriorityQueue$1=1,Object.defineProperty(priorityQueue$1,"__esModule",{value:!0});const e=requireLowerBound();class t{constructor(){this._queue=[]}enqueue(tt,rt){rt=Object.assign({priority:0},rt);const nt={priority:rt.priority,run:tt};if(this.size&&this._queue[this.size-1].priority>=rt.priority){this._queue.push(nt);return}const at=e.default(this._queue,nt,(it,ot)=>ot.priority-it.priority);this._queue.splice(at,0,nt)}dequeue(){const tt=this._queue.shift();return tt==null?void 0:tt.run}filter(tt){return this._queue.filter(rt=>rt.priority===tt.priority).map(rt=>rt.run)}get size(){return this._queue.length}}return priorityQueue$1.default=t,priorityQueue$1}var hasRequiredDist$1;function requireDist$1(){if(hasRequiredDist$1)return dist$1;hasRequiredDist$1=1,Object.defineProperty(dist$1,"__esModule",{value:!0});const e=requireEventemitter3$1(),t=requirePTimeout(),Ye=requirePriorityQueue$1(),tt=()=>{},rt=new t.TimeoutError;class nt extends e{constructor(it){var ot,ct,At,Rt;if(super(),this._intervalCount=0,this._intervalEnd=0,this._pendingCount=0,this._resolveEmpty=tt,this._resolveIdle=tt,it=Object.assign({carryoverConcurrencyCount:!1,intervalCap:1/0,interval:0,concurrency:1/0,autoStart:!0,queueClass:Ye.default},it),!(typeof it.intervalCap=="number"&&it.intervalCap>=1))throw new TypeError(`Expected \`intervalCap\` to be a number from 1 and up, got \`${(ct=(ot=it.intervalCap)===null||ot===void 0?void 0:ot.toString())!==null&&ct!==void 0?ct:""}\` (${typeof it.intervalCap})`);if(it.interval===void 0||!(Number.isFinite(it.interval)&&it.interval>=0))throw new TypeError(`Expected \`interval\` to be a finite number >= 0, got \`${(Rt=(At=it.interval)===null||At===void 0?void 0:At.toString())!==null&&Rt!==void 0?Rt:""}\` (${typeof it.interval})`);this._carryoverConcurrencyCount=it.carryoverConcurrencyCount,this._isIntervalIgnored=it.intervalCap===1/0||it.interval===0,this._intervalCap=it.intervalCap,this._interval=it.interval,this._queue=new it.queueClass,this._queueClass=it.queueClass,this.concurrency=it.concurrency,this._timeout=it.timeout,this._throwOnTimeout=it.throwOnTimeout===!0,this._isPaused=it.autoStart===!1}get _doesIntervalAllowAnother(){return this._isIntervalIgnored||this._intervalCount<this._intervalCap}get _doesConcurrentAllowAnother(){return this._pendingCount<this._concurrency}_next(){this._pendingCount--,this._tryToStartAnother(),this.emit("next")}_resolvePromises(){this._resolveEmpty(),this._resolveEmpty=tt,this._pendingCount===0&&(this._resolveIdle(),this._resolveIdle=tt,this.emit("idle"))}_onResumeInterval(){this._onInterval(),this._initializeIntervalIfNeeded(),this._timeoutId=void 0}_isIntervalPaused(){const it=Date.now();if(this._intervalId===void 0){const ot=this._intervalEnd-it;if(ot<0)this._intervalCount=this._carryoverConcurrencyCount?this._pendingCount:0;else return this._timeoutId===void 0&&(this._timeoutId=setTimeout(()=>{this._onResumeInterval()},ot)),!0}return!1}_tryToStartAnother(){if(this._queue.size===0)return this._intervalId&&clearInterval(this._intervalId),this._intervalId=void 0,this._resolvePromises(),!1;if(!this._isPaused){const it=!this._isIntervalPaused();if(this._doesIntervalAllowAnother&&this._doesConcurrentAllowAnother){const ot=this._queue.dequeue();return ot?(this.emit("active"),ot(),it&&this._initializeIntervalIfNeeded(),!0):!1}}return!1}_initializeIntervalIfNeeded(){this._isIntervalIgnored||this._intervalId!==void 0||(this._intervalId=setInterval(()=>{this._onInterval()},this._interval),this._intervalEnd=Date.now()+this._interval)}_onInterval(){this._intervalCount===0&&this._pendingCount===0&&this._intervalId&&(clearInterval(this._intervalId),this._intervalId=void 0),this._intervalCount=this._carryoverConcurrencyCount?this._pendingCount:0,this._processQueue()}_processQueue(){for(;this._tryToStartAnother(););}get concurrency(){return this._concurrency}set concurrency(it){if(!(typeof it=="number"&&it>=1))throw new TypeError(`Expected \`concurrency\` to be a number from 1 and up, got \`${it}\` (${typeof it})`);this._concurrency=it,this._processQueue()}async add(it,ot={}){return new Promise((ct,At)=>{const Rt=async()=>{this._pendingCount++,this._intervalCount++;try{const qt=this._timeout===void 0&&ot.timeout===void 0?it():t.default(Promise.resolve(it()),ot.timeout===void 0?this._timeout:ot.timeout,()=>{(ot.throwOnTimeout===void 0?this._throwOnTimeout:ot.throwOnTimeout)&&At(rt)});ct(await qt)}catch(qt){At(qt)}this._next()};this._queue.enqueue(Rt,ot),this._tryToStartAnother(),this.emit("add")})}async addAll(it,ot){return Promise.all(it.map(async ct=>this.add(ct,ot)))}start(){return this._isPaused?(this._isPaused=!1,this._processQueue(),this):this}pause(){this._isPaused=!0}clear(){this._queue=new this._queueClass}async onEmpty(){if(this._queue.size!==0)return new Promise(it=>{const ot=this._resolveEmpty;this._resolveEmpty=()=>{ot(),it()}})}async onIdle(){if(!(this._pendingCount===0&&this._queue.size===0))return new Promise(it=>{const ot=this._resolveIdle;this._resolveIdle=()=>{ot(),it()}})}get size(){return this._queue.size}sizeBy(it){return this._queue.filter(it).length}get pending(){return this._pendingCount}get isPaused(){return this._isPaused}get timeout(){return this._timeout}set timeout(it){this._timeout=it}}return dist$1.default=nt,dist$1}var distExports$1=requireDist$1();const PQueueMod=getDefaultExportFromCjs(distExports$1),STATUS_NO_RETRY=[400,401,402,403,404,405,406,407,408,409,422];function isResponse$1(e){return e==null||typeof e!="object"?!1:"status"in e&&"statusText"in e&&"text"in e}var HTTPError=class Qd extends Error{constructor(Ye,tt,rt){super(`HTTP ${Ye}: ${tt}`);Cr(this,"status");Cr(this,"text");Cr(this,"response");this.status=Ye,this.text=tt,this.response=rt}static async fromResponse(Ye,tt){try{return new Qd(Ye.status,await Ye.text(),tt!=null&&tt.includeResponse?Ye:void 0)}catch{return new Qd(Ye.status,Ye.statusText,tt!=null&&tt.includeResponse?Ye:void 0)}}},AsyncCaller=class{constructor(e){Cr(this,"maxConcurrency");Cr(this,"maxRetries");Cr(this,"queue");Cr(this,"onFailedResponseHook");Cr(this,"customFetch");this.maxConcurrency=e.maxConcurrency??1/0,this.maxRetries=e.maxRetries??4,"default"in PQueueMod?this.queue=new PQueueMod.default({concurrency:this.maxConcurrency}):this.queue=new PQueueMod({concurrency:this.maxConcurrency}),this.onFailedResponseHook=e==null?void 0:e.onFailedResponseHook,this.customFetch=e.fetch}call(e,...t){const{onFailedResponseHook:Ye}=this;return this.queue.add(()=>pRetry(()=>e(...t).catch(async tt=>{throw tt instanceof Error?tt:isResponse$1(tt)?await HTTPError.fromResponse(tt,{includeResponse:!!Ye}):new Error(tt)}),{async onFailedAttempt(tt){if(tt.message.startsWith("Cancel")||tt.message.startsWith("TimeoutError")||tt.message.startsWith("AbortError")||(tt==null?void 0:tt.code)==="ECONNABORTED")throw tt;if(tt instanceof HTTPError){if(STATUS_NO_RETRY.includes(tt.status))throw tt;Ye&&tt.response&&await Ye(tt.response)}},retries:this.maxRetries,randomize:!0}),{throwOnTimeout:!0})}callWithOptions(e,t,...Ye){return e.signal?Promise.race([this.call(t,...Ye),new Promise((tt,rt)=>{var nt;(nt=e.signal)==null||nt.addEventListener("abort",()=>{rt(new Error("AbortError"))})})]):this.call(t,...Ye)}fetch(...e){const t=this.customFetch??_getFetchImplementation();return this.call(()=>t(...e).then(Ye=>Ye.ok?Ye:Promise.reject(Ye)))}},define_process_env_default={};function getEnvironmentVariable(e){try{return typeof process<"u"?define_process_env_default==null?void 0:define_process_env_default[e]:void 0}catch{return}}function mergeSignals(...e){const t=e.filter(tt=>tt!=null);if(t.length===0)return;if(t.length===1)return t[0];const Ye=new AbortController;for(const tt of e){if(tt!=null&&tt.aborted)return Ye.abort(tt.reason),Ye.signal;tt==null||tt.addEventListener("abort",()=>Ye.abort(tt.reason),{once:!0})}return Ye.signal}const CR=13,LF=10,NULL=0,COLON=58,SPACE=32,TRAILING_NEWLINE=[CR,LF];function BytesLineDecoder(){let e=[],t=!1;return new TransformStream({start(){e=[],t=!1},transform(Ye,tt){let rt=Ye;if(t&&(rt=joinArrays([[CR],rt]),t=!1),rt.length>0&&rt.at(-1)===CR&&(t=!0,rt=rt.subarray(0,-1)),!rt.length)return;const nt=TRAILING_NEWLINE.includes(rt.at(-1)),at=rt.length-1,{lines:it}=rt.reduce((ot,ct,At)=>(ot.from>At||((ct===CR||ct===LF)&&(ot.lines.push(rt.subarray(ot.from,At)),ct===CR&&rt[At+1]===LF?ot.from=At+2:ot.from=At+1),At===at&&ot.from<=at&&ot.lines.push(rt.subarray(ot.from))),ot),{lines:[],from:0});if(it.length===1&&!nt){e.push(it[0]);return}e.length&&(e.push(it[0]),it[0]=joinArrays(e),e=[]),nt||it.length&&(e=[it.pop()]);for(const ot of it)tt.enqueue(ot)},flush(Ye){e.length&&Ye.enqueue(joinArrays(e))}})}function SSEDecoder(){let e="",t=[],Ye="",tt=null;const rt=new TextDecoder;return new TransformStream({transform(nt,at){if(!nt.length){if(!e&&!t.length&&!Ye&&tt==null)return;const At={id:Ye||void 0,event:e,data:t.length?decodeArraysToJson(rt,t):null};e="",t=[],tt=null,at.enqueue(At);return}if(nt[0]===COLON)return;const it=nt.indexOf(COLON);if(it===-1)return;const ot=rt.decode(nt.subarray(0,it));let ct=nt.subarray(it+1);if(ct[0]===SPACE&&(ct=ct.subarray(1)),ot==="event")e=rt.decode(ct);else if(ot==="data")t.push(ct);else if(ot==="id")ct.indexOf(NULL)===-1&&(Ye=rt.decode(ct));else if(ot==="retry"){const At=Number.parseInt(rt.decode(ct),10);Number.isNaN(At)||(tt=At)}},flush(nt){e&&nt.enqueue({id:Ye||void 0,event:e,data:t.length?decodeArraysToJson(rt,t):null})}})}function joinArrays(e){const t=e.reduce((rt,nt)=>rt+nt.length,0),Ye=new Uint8Array(t);let tt=0;for(const rt of e)Ye.set(rt,tt),tt+=rt.length;return Ye}function decodeArraysToJson(e,t){return JSON.parse(e.decode(joinArrays(t)))}var IterableReadableStream=class Jd extends ReadableStream{constructor(){super(...arguments);Cr(this,"reader")}ensureReader(){this.reader||(this.reader=this.getReader())}async next(){this.ensureReader();try{const Ye=await this.reader.read();return Ye.done?(this.reader.releaseLock(),{done:!0,value:void 0}):{done:!1,value:Ye.value}}catch(Ye){throw this.reader.releaseLock(),Ye}}async return(){if(this.ensureReader(),this.locked){const Ye=this.reader.cancel();this.reader.releaseLock(),await Ye}return{done:!0,value:void 0}}async throw(Ye){if(this.ensureReader(),this.locked){const tt=this.reader.cancel();this.reader.releaseLock(),await tt}throw Ye}async[Symbol.asyncDispose](){await this.return()}[Symbol.asyncIterator](){return this}static fromReadableStream(Ye){const tt=Ye.getReader();return new Jd({start(rt){return nt();function nt(){return tt.read().then(({done:at,value:it})=>{if(at){rt.close();return}return rt.enqueue(it),nt()})}},cancel(){tt.releaseLock()}})}static fromAsyncGenerator(Ye){return new Jd({async pull(tt){const{value:rt,done:nt}=await Ye.next();nt&&tt.close(),tt.enqueue(rt)},async cancel(tt){await Ye.return(tt)}})}};function*iterateHeaders(e){let t,Ye=!1;if(e instanceof Headers){const tt=[];e.forEach((rt,nt)=>{tt.push([nt,rt])}),t=tt}else Array.isArray(e)?t=e:(Ye=!0,t=Object.entries(e??{}));for(const tt of t){const rt=tt[0];if(typeof rt!="string")throw new TypeError(`Expected header name to be a string, got ${typeof rt}`);const nt=Array.isArray(tt[1])?tt[1]:[tt[1]];let at=!1;for(const it of nt)it!==void 0&&(Ye&&!at&&(at=!0,yield[rt,null]),yield[rt,it])}}function mergeHeaders(...e){const t=new Headers;for(const tt of e)if(tt)for(const[rt,nt]of iterateHeaders(tt))nt===null?t.delete(rt):t.append(rt,nt);const Ye=[];return t.forEach((tt,rt)=>{Ye.push([rt,tt])}),Object.fromEntries(Ye)}function getApiKey(e){if(e)return e;const t=["LANGGRAPH","LANGSMITH","LANGCHAIN"];for(const Ye of t){const tt=getEnvironmentVariable(`${Ye}_API_KEY`);if(tt)return tt.trim().replace(/^["']|["']$/g,"")}}const REGEX_RUN_METADATA=/(\/threads\/(?<thread_id>.+))?\/runs\/(?<run_id>.+)/;function getRunMetadataFromResponse(e){var tt;const t=e.headers.get("Content-Location");if(!t)return;const Ye=REGEX_RUN_METADATA.exec(t);if((tt=Ye==null?void 0:Ye.groups)!=null&&tt.run_id)return{run_id:Ye.groups.run_id,thread_id:Ye.groups.thread_id||void 0}}var BaseClient=class{constructor(e){Cr(this,"asyncCaller");Cr(this,"timeoutMs");Cr(this,"apiUrl");Cr(this,"defaultHeaders");Cr(this,"onRequest");var rt;const t={maxRetries:4,maxConcurrency:4,...e==null?void 0:e.callerOptions};let Ye="http://localhost:8123";if(!(e!=null&&e.apiUrl)&&typeof globalThis=="object"&&globalThis!=null){const nt=Symbol.for("langgraph_api:fetch"),at=Symbol.for("langgraph_api:url"),it=globalThis;it[nt]&&(t.fetch??(t.fetch=it[nt])),it[at]&&(Ye=it[at])}this.asyncCaller=new AsyncCaller(t),this.timeoutMs=e==null?void 0:e.timeoutMs,this.apiUrl=((rt=e==null?void 0:e.apiUrl)==null?void 0:rt.replace(/\/$/,""))||Ye,this.defaultHeaders=(e==null?void 0:e.defaultHeaders)||{},this.onRequest=e==null?void 0:e.onRequest;const tt=getApiKey(e==null?void 0:e.apiKey);tt&&(this.defaultHeaders["x-api-key"]=tt)}prepareFetchOptions(e,t){const Ye={...t,headers:mergeHeaders(this.defaultHeaders,t==null?void 0:t.headers)};Ye.json&&(Ye.body=JSON.stringify(Ye.json),Ye.headers=mergeHeaders(Ye.headers,{"content-type":"application/json"}),delete Ye.json),Ye.withResponse&&delete Ye.withResponse;let tt=null;typeof(t==null?void 0:t.timeoutMs)<"u"?t.timeoutMs!=null&&(tt=AbortSignal.timeout(t.timeoutMs)):this.timeoutMs!=null&&(tt=AbortSignal.timeout(this.timeoutMs)),Ye.signal=mergeSignals(tt,Ye.signal);const rt=new URL(`${this.apiUrl}${e}`);if(Ye.params){for(const[nt,at]of Object.entries(Ye.params)){if(at==null)continue;const it=typeof at=="string"||typeof at=="number"?at.toString():JSON.stringify(at);rt.searchParams.append(nt,it)}delete Ye.params}return[rt,Ye]}async fetch(e,t){const[Ye,tt]=this.prepareFetchOptions(e,t);let rt=tt;this.onRequest&&(rt=await this.onRequest(Ye,tt));const nt=await this.asyncCaller.fetch(Ye,rt),at=(()=>{if(!(nt.status===202||nt.status===204))return nt.json()})();return t!=null&&t.withResponse?[await at,nt]:at}},CronsClient=class extends BaseClient{async createForThread(e,t,Ye){const tt={schedule:Ye==null?void 0:Ye.schedule,input:Ye==null?void 0:Ye.input,config:Ye==null?void 0:Ye.config,context:Ye==null?void 0:Ye.context,metadata:Ye==null?void 0:Ye.metadata,assistant_id:t,interrupt_before:Ye==null?void 0:Ye.interruptBefore,interrupt_after:Ye==null?void 0:Ye.interruptAfter,webhook:Ye==null?void 0:Ye.webhook,multitask_strategy:Ye==null?void 0:Ye.multitaskStrategy,if_not_exists:Ye==null?void 0:Ye.ifNotExists,checkpoint_during:Ye==null?void 0:Ye.checkpointDuring,durability:Ye==null?void 0:Ye.durability};return this.fetch(`/threads/${e}/runs/crons`,{method:"POST",json:tt})}async create(e,t){const Ye={schedule:t==null?void 0:t.schedule,input:t==null?void 0:t.input,config:t==null?void 0:t.config,context:t==null?void 0:t.context,metadata:t==null?void 0:t.metadata,assistant_id:e,interrupt_before:t==null?void 0:t.interruptBefore,interrupt_after:t==null?void 0:t.interruptAfter,webhook:t==null?void 0:t.webhook,multitask_strategy:t==null?void 0:t.multitaskStrategy,if_not_exists:t==null?void 0:t.ifNotExists,checkpoint_during:t==null?void 0:t.checkpointDuring,durability:t==null?void 0:t.durability};return this.fetch("/runs/crons",{method:"POST",json:Ye})}async delete(e){await this.fetch(`/runs/crons/${e}`,{method:"DELETE"})}async search(e){return this.fetch("/runs/crons/search",{method:"POST",json:{assistant_id:(e==null?void 0:e.assistantId)??void 0,thread_id:(e==null?void 0:e.threadId)??void 0,limit:(e==null?void 0:e.limit)??10,offset:(e==null?void 0:e.offset)??0,sort_by:(e==null?void 0:e.sortBy)??void 0,sort_order:(e==null?void 0:e.sortOrder)??void 0,select:(e==null?void 0:e.select)??void 0}})}async count(e){return this.fetch("/runs/crons/count",{method:"POST",json:{assistant_id:(e==null?void 0:e.assistantId)??void 0,thread_id:(e==null?void 0:e.threadId)??void 0}})}},AssistantsClient=class extends BaseClient{async get(e){return this.fetch(`/assistants/${e}`)}async getGraph(e,t){return this.fetch(`/assistants/${e}/graph`,{params:{xray:t==null?void 0:t.xray}})}async getSchemas(e){return this.fetch(`/assistants/${e}/schemas`)}async getSubgraphs(e,t){return t!=null&&t.namespace?this.fetch(`/assistants/${e}/subgraphs/${t.namespace}`,{params:{recurse:t==null?void 0:t.recurse}}):this.fetch(`/assistants/${e}/subgraphs`,{params:{recurse:t==null?void 0:t.recurse}})}async create(e){return this.fetch("/assistants",{method:"POST",json:{graph_id:e.graphId,config:e.config,context:e.context,metadata:e.metadata,assistant_id:e.assistantId,if_exists:e.ifExists,name:e.name,description:e.description}})}async update(e,t){return this.fetch(`/assistants/${e}`,{method:"PATCH",json:{graph_id:t.graphId,config:t.config,context:t.context,metadata:t.metadata,name:t.name,description:t.description}})}async delete(e){return this.fetch(`/assistants/${e}`,{method:"DELETE"})}async search(e){return this.fetch("/assistants/search",{method:"POST",json:{graph_id:(e==null?void 0:e.graphId)??void 0,metadata:(e==null?void 0:e.metadata)??void 0,limit:(e==null?void 0:e.limit)??10,offset:(e==null?void 0:e.offset)??0,sort_by:(e==null?void 0:e.sortBy)??void 0,sort_order:(e==null?void 0:e.sortOrder)??void 0,select:(e==null?void 0:e.select)??void 0}})}async count(e){return this.fetch("/assistants/count",{method:"POST",json:{metadata:(e==null?void 0:e.metadata)??void 0,graph_id:(e==null?void 0:e.graphId)??void 0}})}async getVersions(e,t){return this.fetch(`/assistants/${e}/versions`,{method:"POST",json:{metadata:(t==null?void 0:t.metadata)??void 0,limit:(t==null?void 0:t.limit)??10,offset:(t==null?void 0:t.offset)??0}})}async setLatest(e,t){return this.fetch(`/assistants/${e}/latest`,{method:"POST",json:{version:t}})}},ThreadsClient=class extends BaseClient{async get(e){return this.fetch(`/threads/${e}`)}async create(e){var Ye;const t=typeof(e==null?void 0:e.ttl)=="number"?{ttl:e.ttl,strategy:"delete"}:e==null?void 0:e.ttl;return this.fetch("/threads",{method:"POST",json:{metadata:{...e==null?void 0:e.metadata,graph_id:e==null?void 0:e.graphId},thread_id:e==null?void 0:e.threadId,if_exists:e==null?void 0:e.ifExists,supersteps:(Ye=e==null?void 0:e.supersteps)==null?void 0:Ye.map(tt=>({updates:tt.updates.map(rt=>({values:rt.values,command:rt.command,as_node:rt.asNode}))})),ttl:t}})}async copy(e){return this.fetch(`/threads/${e}/copy`,{method:"POST"})}async update(e,t){const Ye=typeof(t==null?void 0:t.ttl)=="number"?{ttl:t.ttl,strategy:"delete"}:t==null?void 0:t.ttl;return this.fetch(`/threads/${e}`,{method:"PATCH",json:{metadata:t==null?void 0:t.metadata,ttl:Ye}})}async delete(e){return this.fetch(`/threads/${e}`,{method:"DELETE"})}async search(e){return this.fetch("/threads/search",{method:"POST",json:{metadata:(e==null?void 0:e.metadata)??void 0,ids:(e==null?void 0:e.ids)??void 0,limit:(e==null?void 0:e.limit)??10,offset:(e==null?void 0:e.offset)??0,status:e==null?void 0:e.status,sort_by:e==null?void 0:e.sortBy,sort_order:e==null?void 0:e.sortOrder,select:(e==null?void 0:e.select)??void 0}})}async count(e){return this.fetch("/threads/count",{method:"POST",json:{metadata:(e==null?void 0:e.metadata)??void 0,values:(e==null?void 0:e.values)??void 0,status:(e==null?void 0:e.status)??void 0}})}async getState(e,t,Ye){return t!=null?typeof t!="string"?this.fetch(`/threads/${e}/state/checkpoint`,{method:"POST",json:{checkpoint:t,subgraphs:Ye==null?void 0:Ye.subgraphs}}):this.fetch(`/threads/${e}/state/${t}`,{params:{subgraphs:Ye==null?void 0:Ye.subgraphs}}):this.fetch(`/threads/${e}/state`,{params:{subgraphs:Ye==null?void 0:Ye.subgraphs}})}async updateState(e,t){return this.fetch(`/threads/${e}/state`,{method:"POST",json:{values:t.values,checkpoint_id:t.checkpointId,checkpoint:t.checkpoint,as_node:t==null?void 0:t.asNode}})}async patchState(e,t){var tt;let Ye;if(typeof e!="string"){if(typeof((tt=e.configurable)==null?void 0:tt.thread_id)!="string")throw new Error("Thread ID is required when updating state with a config.");Ye=e.configurable.thread_id}else Ye=e;return this.fetch(`/threads/${Ye}/state`,{method:"PATCH",json:{metadata:t}})}async getHistory(e,t){return this.fetch(`/threads/${e}/history`,{method:"POST",json:{limit:(t==null?void 0:t.limit)??10,before:t==null?void 0:t.before,metadata:t==null?void 0:t.metadata,checkpoint:t==null?void 0:t.checkpoint}})}async*joinStream(e,t){let[Ye,tt]=this.prepareFetchOptions(`/threads/${e}/stream`,{method:"GET",headers:t!=null&&t.lastEventId?{"Last-Event-ID":t.lastEventId}:void 0,params:t!=null&&t.streamMode?{stream_mode:t.streamMode}:void 0});this.onRequest!=null&&(tt=await this.onRequest(Ye,tt));const nt=((await this.asyncCaller.fetch(Ye,tt)).body||new ReadableStream({start:at=>at.close()})).pipeThrough(BytesLineDecoder()).pipeThrough(SSEDecoder());yield*IterableReadableStream.fromReadableStream(nt)}},RunsClient=class extends BaseClient{async*stream(e,t,Ye){var At;const tt={input:Ye==null?void 0:Ye.input,command:Ye==null?void 0:Ye.command,config:Ye==null?void 0:Ye.config,context:Ye==null?void 0:Ye.context,metadata:Ye==null?void 0:Ye.metadata,stream_mode:Ye==null?void 0:Ye.streamMode,stream_subgraphs:Ye==null?void 0:Ye.streamSubgraphs,stream_resumable:Ye==null?void 0:Ye.streamResumable,feedback_keys:Ye==null?void 0:Ye.feedbackKeys,assistant_id:t,interrupt_before:Ye==null?void 0:Ye.interruptBefore,interrupt_after:Ye==null?void 0:Ye.interruptAfter,checkpoint:Ye==null?void 0:Ye.checkpoint,checkpoint_id:Ye==null?void 0:Ye.checkpointId,webhook:Ye==null?void 0:Ye.webhook,multitask_strategy:Ye==null?void 0:Ye.multitaskStrategy,on_completion:Ye==null?void 0:Ye.onCompletion,on_disconnect:Ye==null?void 0:Ye.onDisconnect,after_seconds:Ye==null?void 0:Ye.afterSeconds,if_not_exists:Ye==null?void 0:Ye.ifNotExists,checkpoint_during:Ye==null?void 0:Ye.checkpointDuring,durability:Ye==null?void 0:Ye.durability},rt=e==null?"/runs/stream":`/threads/${e}/runs/stream`;let[nt,at]=this.prepareFetchOptions(rt,{method:"POST",json:tt,timeoutMs:null,signal:Ye==null?void 0:Ye.signal});this.onRequest!=null&&(at=await this.onRequest(nt,at));const it=await this.asyncCaller.fetch(nt,at),ot=getRunMetadataFromResponse(it);ot&&((At=Ye==null?void 0:Ye.onRunCreated)==null||At.call(Ye,ot));const ct=(it.body||new ReadableStream({start:Rt=>Rt.close()})).pipeThrough(BytesLineDecoder()).pipeThrough(SSEDecoder());yield*IterableReadableStream.fromReadableStream(ct)}async create(e,t,Ye){var ot,ct,At;const tt={input:Ye==null?void 0:Ye.input,command:Ye==null?void 0:Ye.command,config:Ye==null?void 0:Ye.config,context:Ye==null?void 0:Ye.context,metadata:Ye==null?void 0:Ye.metadata,stream_mode:Ye==null?void 0:Ye.streamMode,stream_subgraphs:Ye==null?void 0:Ye.streamSubgraphs,stream_resumable:Ye==null?void 0:Ye.streamResumable,assistant_id:t,interrupt_before:Ye==null?void 0:Ye.interruptBefore,interrupt_after:Ye==null?void 0:Ye.interruptAfter,webhook:Ye==null?void 0:Ye.webhook,checkpoint:Ye==null?void 0:Ye.checkpoint,checkpoint_id:Ye==null?void 0:Ye.checkpointId,multitask_strategy:Ye==null?void 0:Ye.multitaskStrategy,after_seconds:Ye==null?void 0:Ye.afterSeconds,if_not_exists:Ye==null?void 0:Ye.ifNotExists,checkpoint_during:Ye==null?void 0:Ye.checkpointDuring,durability:Ye==null?void 0:Ye.durability,langsmith_tracer:Ye!=null&&Ye._langsmithTracer?{project_name:(ot=Ye==null?void 0:Ye._langsmithTracer)==null?void 0:ot.projectName,example_id:(ct=Ye==null?void 0:Ye._langsmithTracer)==null?void 0:ct.exampleId}:void 0},rt=e===null?"/runs":`/threads/${e}/runs`,[nt,at]=await this.fetch(rt,{method:"POST",json:tt,signal:Ye==null?void 0:Ye.signal,withResponse:!0}),it=getRunMetadataFromResponse(at);return it&&((At=Ye==null?void 0:Ye.onRunCreated)==null||At.call(Ye,it)),nt}async createBatch(e){const t=e.map(Ye=>({...Ye,assistant_id:Ye.assistantId})).map(Ye=>Object.fromEntries(Object.entries(Ye).filter(([tt,rt])=>rt!==void 0)));return this.fetch("/runs/batch",{method:"POST",json:t})}async wait(e,t,Ye){var ct,At,Rt,qt,Ft;const tt={input:Ye==null?void 0:Ye.input,command:Ye==null?void 0:Ye.command,config:Ye==null?void 0:Ye.config,context:Ye==null?void 0:Ye.context,metadata:Ye==null?void 0:Ye.metadata,assistant_id:t,interrupt_before:Ye==null?void 0:Ye.interruptBefore,interrupt_after:Ye==null?void 0:Ye.interruptAfter,checkpoint:Ye==null?void 0:Ye.checkpoint,checkpoint_id:Ye==null?void 0:Ye.checkpointId,webhook:Ye==null?void 0:Ye.webhook,multitask_strategy:Ye==null?void 0:Ye.multitaskStrategy,on_completion:Ye==null?void 0:Ye.onCompletion,on_disconnect:Ye==null?void 0:Ye.onDisconnect,after_seconds:Ye==null?void 0:Ye.afterSeconds,if_not_exists:Ye==null?void 0:Ye.ifNotExists,checkpoint_during:Ye==null?void 0:Ye.checkpointDuring,durability:Ye==null?void 0:Ye.durability,langsmith_tracer:Ye!=null&&Ye._langsmithTracer?{project_name:(ct=Ye==null?void 0:Ye._langsmithTracer)==null?void 0:ct.projectName,example_id:(At=Ye==null?void 0:Ye._langsmithTracer)==null?void 0:At.exampleId}:void 0},rt=e==null?"/runs/wait":`/threads/${e}/runs/wait`,[nt,at]=await this.fetch(rt,{method:"POST",json:tt,timeoutMs:null,signal:Ye==null?void 0:Ye.signal,withResponse:!0}),it=getRunMetadataFromResponse(at);if(it&&((Rt=Ye==null?void 0:Ye.onRunCreated)==null||Rt.call(Ye,it)),((Ye==null?void 0:Ye.raiseError)!==void 0?Ye.raiseError:!0)&&"__error__"in nt&&typeof nt.__error__=="object"&&nt.__error__&&"error"in nt.__error__&&"message"in nt.__error__)throw new Error(`${(qt=nt.__error__)==null?void 0:qt.error}: ${(Ft=nt.__error__)==null?void 0:Ft.message}`);return nt}async list(e,t){return this.fetch(`/threads/${e}/runs`,{params:{limit:(t==null?void 0:t.limit)??10,offset:(t==null?void 0:t.offset)??0,status:(t==null?void 0:t.status)??void 0,select:(t==null?void 0:t.select)??void 0}})}async get(e,t){return this.fetch(`/threads/${e}/runs/${t}`)}async cancel(e,t,Ye=!1,tt="interrupt"){return this.fetch(`/threads/${e}/runs/${t}/cancel`,{method:"POST",params:{wait:Ye?"1":"0",action:tt}})}async join(e,t,Ye){return this.fetch(`/threads/${e}/runs/${t}/join`,{timeoutMs:null,signal:Ye==null?void 0:Ye.signal})}async*joinStream(e,t,Ye){const tt=typeof Ye=="object"&&Ye!=null&&Ye instanceof AbortSignal?{signal:Ye}:Ye;let[rt,nt]=this.prepareFetchOptions(e!=null?`/threads/${e}/runs/${t}/stream`:`/runs/${t}/stream`,{method:"GET",timeoutMs:null,signal:tt==null?void 0:tt.signal,headers:tt!=null&&tt.lastEventId?{"Last-Event-ID":tt.lastEventId}:void 0,params:{cancel_on_disconnect:tt!=null&&tt.cancelOnDisconnect?"1":"0",stream_mode:tt==null?void 0:tt.streamMode}});this.onRequest!=null&&(nt=await this.onRequest(rt,nt));const it=((await this.asyncCaller.fetch(rt,nt)).body||new ReadableStream({start:ot=>ot.close()})).pipeThrough(BytesLineDecoder()).pipeThrough(SSEDecoder());yield*IterableReadableStream.fromReadableStream(it)}async delete(e,t){return this.fetch(`/threads/${e}/runs/${t}`,{method:"DELETE"})}},StoreClient=class extends BaseClient{async putItem(e,t,Ye,tt){e.forEach(nt=>{if(nt.includes("."))throw new Error(`Invalid namespace label '${nt}'. Namespace labels cannot contain periods ('.')`)});const rt={namespace:e,key:t,value:Ye,index:tt==null?void 0:tt.index,ttl:tt==null?void 0:tt.ttl};return this.fetch("/store/items",{method:"PUT",json:rt})}async getItem(e,t,Ye){e.forEach(nt=>{if(nt.includes("."))throw new Error(`Invalid namespace label '${nt}'. Namespace labels cannot contain periods ('.')`)});const tt={namespace:e.join("."),key:t};(Ye==null?void 0:Ye.refreshTtl)!==void 0&&(tt.refresh_ttl=Ye.refreshTtl);const rt=await this.fetch("/store/items",{params:tt});return rt?{...rt,createdAt:rt.created_at,updatedAt:rt.updated_at}:null}async deleteItem(e,t){return e.forEach(Ye=>{if(Ye.includes("."))throw new Error(`Invalid namespace label '${Ye}'. Namespace labels cannot contain periods ('.')`)}),this.fetch("/store/items",{method:"DELETE",json:{namespace:e,key:t}})}async searchItems(e,t){const Ye={namespace_prefix:e,filter:t==null?void 0:t.filter,limit:(t==null?void 0:t.limit)??10,offset:(t==null?void 0:t.offset)??0,query:t==null?void 0:t.query,refresh_ttl:t==null?void 0:t.refreshTtl};return{items:(await this.fetch("/store/items/search",{method:"POST",json:Ye})).items.map(rt=>({...rt,createdAt:rt.created_at,updatedAt:rt.updated_at}))}}async listNamespaces(e){const t={prefix:e==null?void 0:e.prefix,suffix:e==null?void 0:e.suffix,max_depth:e==null?void 0:e.maxDepth,limit:(e==null?void 0:e.limit)??100,offset:(e==null?void 0:e.offset)??0};return this.fetch("/store/namespaces",{method:"POST",json:t})}},fi,UiClient=(fi=class extends BaseClient{static getOrCached(t,Ye){if(fi.promiseCache[t]!=null)return fi.promiseCache[t];const tt=Ye();return fi.promiseCache[t]=tt,tt}async getComponent(t,Ye){return fi.getOrCached(`${this.apiUrl}-${t}-${Ye}`,async()=>{let[tt,rt]=this.prepareFetchOptions(`/ui/${t}`,{headers:{Accept:"text/html","Content-Type":"application/json"},method:"POST",json:{name:Ye}});return this.onRequest!=null&&(rt=await this.onRequest(tt,rt)),(await this.asyncCaller.fetch(tt,rt)).text()})}},Cr(fi,"promiseCache",{}),fi),Client=class{constructor(e){Cr(this,"assistants");Cr(this,"threads");Cr(this,"runs");Cr(this,"crons");Cr(this,"store");Cr(this,"~ui");Cr(this,"~configHash");this["~configHash"]=(()=>{var t,Ye,tt,rt;return JSON.stringify({apiUrl:e==null?void 0:e.apiUrl,apiKey:e==null?void 0:e.apiKey,timeoutMs:e==null?void 0:e.timeoutMs,defaultHeaders:e==null?void 0:e.defaultHeaders,maxConcurrency:(t=e==null?void 0:e.callerOptions)==null?void 0:t.maxConcurrency,maxRetries:(Ye=e==null?void 0:e.callerOptions)==null?void 0:Ye.maxRetries,callbacks:{onFailedResponseHook:((tt=e==null?void 0:e.callerOptions)==null?void 0:tt.onFailedResponseHook)!=null,onRequest:(e==null?void 0:e.onRequest)!=null,fetch:((rt=e==null?void 0:e.callerOptions)==null?void 0:rt.fetch)!=null}})})(),this.assistants=new AssistantsClient(e),this.threads=new ThreadsClient(e),this.runs=new RunsClient(e),this.crons=new CronsClient(e),this.store=new StoreClient(e),this["~ui"]=new UiClient(e)}};const createLangGraphServerClient=async e=>new Client(e);function $constructor(e,t,Ye){function tt(it,ot){var ct;Object.defineProperty(it,"_zod",{value:it._zod??{},enumerable:!1}),(ct=it._zod).traits??(ct.traits=new Set),it._zod.traits.add(e),t(it,ot);for(const At in at.prototype)At in it||Object.defineProperty(it,At,{value:at.prototype[At].bind(it)});it._zod.constr=at,it._zod.def=ot}const rt=(Ye==null?void 0:Ye.Parent)??Object;class nt extends rt{}Object.defineProperty(nt,"name",{value:e});function at(it){var ot;const ct=Ye!=null&&Ye.Parent?new nt:this;tt(ct,it),(ot=ct._zod).deferred??(ot.deferred=[]);for(const At of ct._zod.deferred)At();return ct}return Object.defineProperty(at,"init",{value:tt}),Object.defineProperty(at,Symbol.hasInstance,{value:it=>{var ot,ct;return Ye!=null&&Ye.Parent&&it instanceof Ye.Parent?!0:(ct=(ot=it==null?void 0:it._zod)==null?void 0:ot.traits)==null?void 0:ct.has(e)}}),Object.defineProperty(at,"name",{value:e}),at}class $ZodAsyncError extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}}class $ZodEncodeError extends Error{constructor(t){super(`Encountered unidirectional transform during encode: ${t}`),this.name="ZodEncodeError"}}const globalConfig={};function config(e){return globalConfig}function getEnumValues(e){const t=Object.values(e).filter(tt=>typeof tt=="number");return Object.entries(e).filter(([tt,rt])=>t.indexOf(+tt)===-1).map(([tt,rt])=>rt)}function jsonStringifyReplacer(e,t){return typeof t=="bigint"?t.toString():t}function cached(e){return{get value(){{const t=e();return Object.defineProperty(this,"value",{value:t}),t}}}}function nullish(e){return e==null}function cleanRegex(e){const t=e.startsWith("^")?1:0,Ye=e.endsWith("$")?e.length-1:e.length;return e.slice(t,Ye)}const EVALUATING=Symbol("evaluating");function defineLazy(e,t,Ye){let tt;Object.defineProperty(e,t,{get(){if(tt!==EVALUATING)return tt===void 0&&(tt=EVALUATING,tt=Ye()),tt},set(rt){Object.defineProperty(e,t,{value:rt})},configurable:!0})}function assignProp$1(e,t,Ye){Object.defineProperty(e,t,{value:Ye,writable:!0,enumerable:!0,configurable:!0})}function mergeDefs(...e){const t={};for(const Ye of e){const tt=Object.getOwnPropertyDescriptors(Ye);Object.assign(t,tt)}return Object.defineProperties({},t)}function esc(e){return JSON.stringify(e)}const captureStackTrace="captureStackTrace"in Error?Error.captureStackTrace:(...e)=>{};function isObject$5(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}const allowsEval=cached(()=>{var e;if(typeof navigator<"u"&&((e=navigator==null?void 0:navigator.userAgent)!=null&&e.includes("Cloudflare")))return!1;try{const t=Function;return new t(""),!0}catch{return!1}});function isPlainObject$2(e){if(isObject$5(e)===!1)return!1;const t=e.constructor;if(t===void 0)return!0;const Ye=t.prototype;return!(isObject$5(Ye)===!1||Object.prototype.hasOwnProperty.call(Ye,"isPrototypeOf")===!1)}function shallowClone(e){return isPlainObject$2(e)?{...e}:Array.isArray(e)?[...e]:e}const propertyKeyTypes=new Set(["string","number","symbol"]);function escapeRegex(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function clone$1(e,t,Ye){const tt=new e._zod.constr(t??e._zod.def);return(!t||Ye!=null&&Ye.parent)&&(tt._zod.parent=e),tt}function normalizeParams(e){const t=e;if(!t)return{};if(typeof t=="string")return{error:()=>t};if((t==null?void 0:t.message)!==void 0){if((t==null?void 0:t.error)!==void 0)throw new Error("Cannot specify both `message` and `error` params");t.error=t.message}return delete t.message,typeof t.error=="string"?{...t,error:()=>t.error}:t}function optionalKeys(e){return Object.keys(e).filter(t=>e[t]._zod.optin==="optional"&&e[t]._zod.optout==="optional")}function pick$1(e,t){const Ye=e._zod.def,tt=mergeDefs(e._zod.def,{get shape(){const rt={};for(const nt in t){if(!(nt in Ye.shape))throw new Error(`Unrecognized key: "${nt}"`);t[nt]&&(rt[nt]=Ye.shape[nt])}return assignProp$1(this,"shape",rt),rt},checks:[]});return clone$1(e,tt)}function omit$1(e,t){const Ye=e._zod.def,tt=mergeDefs(e._zod.def,{get shape(){const rt={...e._zod.def.shape};for(const nt in t){if(!(nt in Ye.shape))throw new Error(`Unrecognized key: "${nt}"`);t[nt]&&delete rt[nt]}return assignProp$1(this,"shape",rt),rt},checks:[]});return clone$1(e,tt)}function extend$3(e,t){if(!isPlainObject$2(t))throw new Error("Invalid input to extend: expected a plain object");const Ye=e._zod.def.checks;if(Ye&&Ye.length>0)throw new Error("Object schemas containing refinements cannot be extended. Use `.safeExtend()` instead.");const rt=mergeDefs(e._zod.def,{get shape(){const nt={...e._zod.def.shape,...t};return assignProp$1(this,"shape",nt),nt},checks:[]});return clone$1(e,rt)}function safeExtend(e,t){if(!isPlainObject$2(t))throw new Error("Invalid input to safeExtend: expected a plain object");const Ye={...e._zod.def,get shape(){const tt={...e._zod.def.shape,...t};return assignProp$1(this,"shape",tt),tt},checks:e._zod.def.checks};return clone$1(e,Ye)}function merge$3(e,t){const Ye=mergeDefs(e._zod.def,{get shape(){const tt={...e._zod.def.shape,...t._zod.def.shape};return assignProp$1(this,"shape",tt),tt},get catchall(){return t._zod.def.catchall},checks:[]});return clone$1(e,Ye)}function partial(e,t,Ye){const tt=mergeDefs(t._zod.def,{get shape(){const rt=t._zod.def.shape,nt={...rt};if(Ye)for(const at in Ye){if(!(at in rt))throw new Error(`Unrecognized key: "${at}"`);Ye[at]&&(nt[at]=e?new e({type:"optional",innerType:rt[at]}):rt[at])}else for(const at in rt)nt[at]=e?new e({type:"optional",innerType:rt[at]}):rt[at];return assignProp$1(this,"shape",nt),nt},checks:[]});return clone$1(t,tt)}function required$2(e,t,Ye){const tt=mergeDefs(t._zod.def,{get shape(){const rt=t._zod.def.shape,nt={...rt};if(Ye)for(const at in Ye){if(!(at in nt))throw new Error(`Unrecognized key: "${at}"`);Ye[at]&&(nt[at]=new e({type:"nonoptional",innerType:rt[at]}))}else for(const at in rt)nt[at]=new e({type:"nonoptional",innerType:rt[at]});return assignProp$1(this,"shape",nt),nt},checks:[]});return clone$1(t,tt)}function aborted(e,t=0){var Ye;if(e.aborted===!0)return!0;for(let tt=t;tt<e.issues.length;tt++)if(((Ye=e.issues[tt])==null?void 0:Ye.continue)!==!0)return!0;return!1}function prefixIssues(e,t){return t.map(Ye=>{var tt;return(tt=Ye).path??(tt.path=[]),Ye.path.unshift(e),Ye})}function unwrapMessage(e){return typeof e=="string"?e:e==null?void 0:e.message}function finalizeIssue(e,t,Ye){var rt,nt,at,it,ot,ct;const tt={...e,path:e.path??[]};if(!e.message){const At=unwrapMessage((at=(nt=(rt=e.inst)==null?void 0:rt._zod.def)==null?void 0:nt.error)==null?void 0:at.call(nt,e))??unwrapMessage((it=t==null?void 0:t.error)==null?void 0:it.call(t,e))??unwrapMessage((ot=Ye.customError)==null?void 0:ot.call(Ye,e))??unwrapMessage((ct=Ye.localeError)==null?void 0:ct.call(Ye,e))??"Invalid input";tt.message=At}return delete tt.inst,delete tt.continue,t!=null&&t.reportInput||delete tt.input,tt}function getLengthableOrigin(e){return Array.isArray(e)?"array":typeof e=="string"?"string":"unknown"}function issue(...e){const[t,Ye,tt]=e;return typeof t=="string"?{message:t,code:"custom",input:Ye,inst:tt}:{...t}}const initializer$1=(e,t)=>{e.name="$ZodError",Object.defineProperty(e,"_zod",{value:e._zod,enumerable:!1}),Object.defineProperty(e,"issues",{value:t,enumerable:!1}),e.message=JSON.stringify(t,jsonStringifyReplacer,2),Object.defineProperty(e,"toString",{value:()=>e.message,enumerable:!1})},$ZodError=$constructor("$ZodError",initializer$1),$ZodRealError=$constructor("$ZodError",initializer$1,{Parent:Error});function flattenError(e,t=Ye=>Ye.message){const Ye={},tt=[];for(const rt of e.issues)rt.path.length>0?(Ye[rt.path[0]]=Ye[rt.path[0]]||[],Ye[rt.path[0]].push(t(rt))):tt.push(t(rt));return{formErrors:tt,fieldErrors:Ye}}function formatError(e,t=Ye=>Ye.message){const Ye={_errors:[]},tt=rt=>{for(const nt of rt.issues)if(nt.code==="invalid_union"&&nt.errors.length)nt.errors.map(at=>tt({issues:at}));else if(nt.code==="invalid_key")tt({issues:nt.issues});else if(nt.code==="invalid_element")tt({issues:nt.issues});else if(nt.path.length===0)Ye._errors.push(t(nt));else{let at=Ye,it=0;for(;it<nt.path.length;){const ot=nt.path[it];it===nt.path.length-1?(at[ot]=at[ot]||{_errors:[]},at[ot]._errors.push(t(nt))):at[ot]=at[ot]||{_errors:[]},at=at[ot],it++}}};return tt(e),Ye}const _parse=e=>(t,Ye,tt,rt)=>{const nt=tt?Object.assign(tt,{async:!1}):{async:!1},at=t._zod.run({value:Ye,issues:[]},nt);if(at instanceof Promise)throw new $ZodAsyncError;if(at.issues.length){const it=new((rt==null?void 0:rt.Err)??e)(at.issues.map(ot=>finalizeIssue(ot,nt,config())));throw captureStackTrace(it,rt==null?void 0:rt.callee),it}return at.value},_parseAsync=e=>async(t,Ye,tt,rt)=>{const nt=tt?Object.assign(tt,{async:!0}):{async:!0};let at=t._zod.run({value:Ye,issues:[]},nt);if(at instanceof Promise&&(at=await at),at.issues.length){const it=new((rt==null?void 0:rt.Err)??e)(at.issues.map(ot=>finalizeIssue(ot,nt,config())));throw captureStackTrace(it,rt==null?void 0:rt.callee),it}return at.value},_safeParse=e=>(t,Ye,tt)=>{const rt=tt?{...tt,async:!1}:{async:!1},nt=t._zod.run({value:Ye,issues:[]},rt);if(nt instanceof Promise)throw new $ZodAsyncError;return nt.issues.length?{success:!1,error:new(e??$ZodError)(nt.issues.map(at=>finalizeIssue(at,rt,config())))}:{success:!0,data:nt.value}},safeParse$1=_safeParse($ZodRealError),_safeParseAsync=e=>async(t,Ye,tt)=>{const rt=tt?Object.assign(tt,{async:!0}):{async:!0};let nt=t._zod.run({value:Ye,issues:[]},rt);return nt instanceof Promise&&(nt=await nt),nt.issues.length?{success:!1,error:new e(nt.issues.map(at=>finalizeIssue(at,rt,config())))}:{success:!0,data:nt.value}},safeParseAsync$1=_safeParseAsync($ZodRealError),_encode=e=>(t,Ye,tt)=>{const rt=tt?Object.assign(tt,{direction:"backward"}):{direction:"backward"};return _parse(e)(t,Ye,rt)},_decode=e=>(t,Ye,tt)=>_parse(e)(t,Ye,tt),_encodeAsync=e=>async(t,Ye,tt)=>{const rt=tt?Object.assign(tt,{direction:"backward"}):{direction:"backward"};return _parseAsync(e)(t,Ye,rt)},_decodeAsync=e=>async(t,Ye,tt)=>_parseAsync(e)(t,Ye,tt),_safeEncode=e=>(t,Ye,tt)=>{const rt=tt?Object.assign(tt,{direction:"backward"}):{direction:"backward"};return _safeParse(e)(t,Ye,rt)},_safeDecode=e=>(t,Ye,tt)=>_safeParse(e)(t,Ye,tt),_safeEncodeAsync=e=>async(t,Ye,tt)=>{const rt=tt?Object.assign(tt,{direction:"backward"}):{direction:"backward"};return _safeParseAsync(e)(t,Ye,rt)},_safeDecodeAsync=e=>async(t,Ye,tt)=>_safeParseAsync(e)(t,Ye,tt),cuid=/^[cC][^\s-]{8,}$/,cuid2=/^[0-9a-z]+$/,ulid=/^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/,xid=/^[0-9a-vA-V]{20}$/,ksuid=/^[A-Za-z0-9]{27}$/,nanoid=/^[a-zA-Z0-9_-]{21}$/,duration$1=/^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/,guid=/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$/,uuid=e=>e?new RegExp(`^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-${e}[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$`):/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$/,email=/^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/,_emoji$1="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";function emoji(){return new RegExp(_emoji$1,"u")}const ipv4=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,ipv6=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:))$/,cidrv4=/^((25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/([0-9]|[1-2][0-9]|3[0-2])$/,cidrv6=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|::|([0-9a-fA-F]{1,4})?::([0-9a-fA-F]{1,4}:?){0,6})\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,base64=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,base64url=/^[A-Za-z0-9_-]*$/,hostname=/^(?=.{1,253}\.?$)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[-0-9a-zA-Z]{0,61}[0-9a-zA-Z])?)*\.?$/,e164=/^\+(?:[0-9]){6,14}[0-9]$/,dateSource="(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))",date$1=new RegExp(`^${dateSource}$`);function timeSource(e){const t="(?:[01]\\d|2[0-3]):[0-5]\\d";return typeof e.precision=="number"?e.precision===-1?`${t}`:e.precision===0?`${t}:[0-5]\\d`:`${t}:[0-5]\\d\\.\\d{${e.precision}}`:`${t}(?::[0-5]\\d(?:\\.\\d+)?)?`}function time$1(e){return new RegExp(`^${timeSource(e)}$`)}function datetime$1(e){const t=timeSource({precision:e.precision}),Ye=["Z"];e.local&&Ye.push(""),e.offset&&Ye.push("([+-](?:[01]\\d|2[0-3]):[0-5]\\d)");const tt=`${t}(?:${Ye.join("|")})`;return new RegExp(`^${dateSource}T(?:${tt})$`)}const string$3=e=>{const t=e?`[\\s\\S]{${(e==null?void 0:e.minimum)??0},${(e==null?void 0:e.maximum)??""}}`:"[\\s\\S]*";return new RegExp(`^${t}$`)},lowercase=/^[^A-Z]*$/,uppercase$1=/^[^a-z]*$/,$ZodCheck=$constructor("$ZodCheck",(e,t)=>{var Ye;e._zod??(e._zod={}),e._zod.def=t,(Ye=e._zod).onattach??(Ye.onattach=[])}),$ZodCheckMaxLength=$constructor("$ZodCheckMaxLength",(e,t)=>{var Ye;$ZodCheck.init(e,t),(Ye=e._zod.def).when??(Ye.when=tt=>{const rt=tt.value;return!nullish(rt)&&rt.length!==void 0}),e._zod.onattach.push(tt=>{const rt=tt._zod.bag.maximum??Number.POSITIVE_INFINITY;t.maximum<rt&&(tt._zod.bag.maximum=t.maximum)}),e._zod.check=tt=>{const rt=tt.value;if(rt.length<=t.maximum)return;const at=getLengthableOrigin(rt);tt.issues.push({origin:at,code:"too_big",maximum:t.maximum,inclusive:!0,input:rt,inst:e,continue:!t.abort})}}),$ZodCheckMinLength=$constructor("$ZodCheckMinLength",(e,t)=>{var Ye;$ZodCheck.init(e,t),(Ye=e._zod.def).when??(Ye.when=tt=>{const rt=tt.value;return!nullish(rt)&&rt.length!==void 0}),e._zod.onattach.push(tt=>{const rt=tt._zod.bag.minimum??Number.NEGATIVE_INFINITY;t.minimum>rt&&(tt._zod.bag.minimum=t.minimum)}),e._zod.check=tt=>{const rt=tt.value;if(rt.length>=t.minimum)return;const at=getLengthableOrigin(rt);tt.issues.push({origin:at,code:"too_small",minimum:t.minimum,inclusive:!0,input:rt,inst:e,continue:!t.abort})}}),$ZodCheckLengthEquals=$constructor("$ZodCheckLengthEquals",(e,t)=>{var Ye;$ZodCheck.init(e,t),(Ye=e._zod.def).when??(Ye.when=tt=>{const rt=tt.value;return!nullish(rt)&&rt.length!==void 0}),e._zod.onattach.push(tt=>{const rt=tt._zod.bag;rt.minimum=t.length,rt.maximum=t.length,rt.length=t.length}),e._zod.check=tt=>{const rt=tt.value,nt=rt.length;if(nt===t.length)return;const at=getLengthableOrigin(rt),it=nt>t.length;tt.issues.push({origin:at,...it?{code:"too_big",maximum:t.length}:{code:"too_small",minimum:t.length},inclusive:!0,exact:!0,input:tt.value,inst:e,continue:!t.abort})}}),$ZodCheckStringFormat=$constructor("$ZodCheckStringFormat",(e,t)=>{var Ye,tt;$ZodCheck.init(e,t),e._zod.onattach.push(rt=>{const nt=rt._zod.bag;nt.format=t.format,t.pattern&&(nt.patterns??(nt.patterns=new Set),nt.patterns.add(t.pattern))}),t.pattern?(Ye=e._zod).check??(Ye.check=rt=>{t.pattern.lastIndex=0,!t.pattern.test(rt.value)&&rt.issues.push({origin:"string",code:"invalid_format",format:t.format,input:rt.value,...t.pattern?{pattern:t.pattern.toString()}:{},inst:e,continue:!t.abort})}):(tt=e._zod).check??(tt.check=()=>{})}),$ZodCheckRegex=$constructor("$ZodCheckRegex",(e,t)=>{$ZodCheckStringFormat.init(e,t),e._zod.check=Ye=>{t.pattern.lastIndex=0,!t.pattern.test(Ye.value)&&Ye.issues.push({origin:"string",code:"invalid_format",format:"regex",input:Ye.value,pattern:t.pattern.toString(),inst:e,continue:!t.abort})}}),$ZodCheckLowerCase=$constructor("$ZodCheckLowerCase",(e,t)=>{t.pattern??(t.pattern=lowercase),$ZodCheckStringFormat.init(e,t)}),$ZodCheckUpperCase=$constructor("$ZodCheckUpperCase",(e,t)=>{t.pattern??(t.pattern=uppercase$1),$ZodCheckStringFormat.init(e,t)}),$ZodCheckIncludes=$constructor("$ZodCheckIncludes",(e,t)=>{$ZodCheck.init(e,t);const Ye=escapeRegex(t.includes),tt=new RegExp(typeof t.position=="number"?`^.{${t.position}}${Ye}`:Ye);t.pattern=tt,e._zod.onattach.push(rt=>{const nt=rt._zod.bag;nt.patterns??(nt.patterns=new Set),nt.patterns.add(tt)}),e._zod.check=rt=>{rt.value.includes(t.includes,t.position)||rt.issues.push({origin:"string",code:"invalid_format",format:"includes",includes:t.includes,input:rt.value,inst:e,continue:!t.abort})}}),$ZodCheckStartsWith=$constructor("$ZodCheckStartsWith",(e,t)=>{$ZodCheck.init(e,t);const Ye=new RegExp(`^${escapeRegex(t.prefix)}.*`);t.pattern??(t.pattern=Ye),e._zod.onattach.push(tt=>{const rt=tt._zod.bag;rt.patterns??(rt.patterns=new Set),rt.patterns.add(Ye)}),e._zod.check=tt=>{tt.value.startsWith(t.prefix)||tt.issues.push({origin:"string",code:"invalid_format",format:"starts_with",prefix:t.prefix,input:tt.value,inst:e,continue:!t.abort})}}),$ZodCheckEndsWith=$constructor("$ZodCheckEndsWith",(e,t)=>{$ZodCheck.init(e,t);const Ye=new RegExp(`.*${escapeRegex(t.suffix)}$`);t.pattern??(t.pattern=Ye),e._zod.onattach.push(tt=>{const rt=tt._zod.bag;rt.patterns??(rt.patterns=new Set),rt.patterns.add(Ye)}),e._zod.check=tt=>{tt.value.endsWith(t.suffix)||tt.issues.push({origin:"string",code:"invalid_format",format:"ends_with",suffix:t.suffix,input:tt.value,inst:e,continue:!t.abort})}}),$ZodCheckOverwrite=$constructor("$ZodCheckOverwrite",(e,t)=>{$ZodCheck.init(e,t),e._zod.check=Ye=>{Ye.value=t.tx(Ye.value)}});class Doc{constructor(t=[]){this.content=[],this.indent=0,this&&(this.args=t)}indented(t){this.indent+=1,t(this),this.indent-=1}write(t){if(typeof t=="function"){t(this,{execution:"sync"}),t(this,{execution:"async"});return}const tt=t.split(`
57
+ ]`)}function Yt(){let Er=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1,_r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:-1,Tr=e[t]==="\\";if(Tr&&(t++,Tr=!0),isQuote(e[t])){const ur=isDoubleQuote(e[t])?isDoubleQuote:isSingleQuote(e[t])?isSingleQuote:isSingleQuoteLike(e[t])?isSingleQuoteLike:isDoubleQuoteLike,cr=t,yr=Ye.length;let ir='"';for(t++;;){if(t>=e.length){const or=nr(t-1);return!Er&&isDelimiter(e.charAt(or))?(t=cr,Ye=Ye.substring(0,yr),Yt(!0)):(ir=insertBeforeLastWhitespace(ir,'"'),Ye+=ir,!0)}else{if(t===_r)return ir=insertBeforeLastWhitespace(ir,'"'),Ye+=ir,!0;if(ur(e[t])){const or=t,hr=ir.length;if(ir+='"',t++,Ye+=ir,at(!1),Er||t>=e.length||isDelimiter(e[t])||isQuote(e[t])||isDigit(e[t]))return Gt(),!0;const Sr=nr(or-1),wr=e.charAt(Sr);if(wr===",")return t=cr,Ye=Ye.substring(0,yr),Yt(!1,Sr);if(isDelimiter(wr))return t=cr,Ye=Ye.substring(0,yr),Yt(!0);Ye=Ye.substring(0,yr),t=or+1,ir="".concat(ir.substring(0,hr),"\\").concat(ir.substring(hr))}else if(Er&&isUnquotedStringDelimiter(e[t])){if(e[t-1]===":"&&regexUrlStart.test(e.substring(cr+1,t+2)))for(;t<e.length&&regexUrlChar.test(e[t]);)ir+=e[t],t++;return ir=insertBeforeLastWhitespace(ir,'"'),Ye+=ir,Gt(),!0}else if(e[t]==="\\"){const or=e.charAt(t+1);if(escapeCharacters[or]!==void 0)ir+=e.slice(t,t+2),t+=2;else if(or==="u"){let Sr=2;for(;Sr<6&&isHex(e[t+Sr]);)Sr++;Sr===6?(ir+=e.slice(t,t+6),t+=6):t+Sr>=e.length?t=e.length:mr()}else ir+=or,t+=2}else{const or=e.charAt(t);or==='"'&&e[t-1]!=="\\"?(ir+="\\".concat(or),t++):isControlCharacter(or)?(ir+=controlCharacters[or],t++):(isValidStringCharacter(or)||lr(or),ir+=or,t++)}}Tr&&qt()}}return!1}function Gt(){let Er=!1;for(at();e[t]==="+";){Er=!0,t++,at(),Ye=stripLastOccurrence(Ye,'"',!0);const _r=Ye.length;Yt()?Ye=removeAtIndex(Ye,_r,1):Ye=insertBeforeLastWhitespace(Ye,'"')}return Er}function Vt(){const Er=t;if(e[t]==="-"){if(t++,ar())return sr(Er),!0;if(!isDigit(e[t]))return t=Er,!1}for(;isDigit(e[t]);)t++;if(e[t]==="."){if(t++,ar())return sr(Er),!0;if(!isDigit(e[t]))return t=Er,!1;for(;isDigit(e[t]);)t++}if(e[t]==="e"||e[t]==="E"){if(t++,(e[t]==="-"||e[t]==="+")&&t++,ar())return sr(Er),!0;if(!isDigit(e[t]))return t=Er,!1;for(;isDigit(e[t]);)t++}if(!ar())return t=Er,!1;if(t>Er){const _r=e.slice(Er,t),Tr=/^0\d/.test(_r);return Ye+=Tr?'"'.concat(_r,'"'):_r,!0}return!1}function Zt(){return Xt("true","true")||Xt("false","false")||Xt("null","null")||Xt("True","true")||Xt("False","false")||Xt("None","null")}function Xt(Er,_r){return e.slice(t,t+Er.length)===Er?(Ye+=_r,t+=Er.length,!0):!1}function Qt(Er){const _r=t;if(isFunctionNameCharStart(e[t])){for(;t<e.length&&isFunctionNameChar(e[t]);)t++;let Tr=t;for(;isWhitespace$1(e,Tr);)Tr++;if(e[Tr]==="(")return t=Tr+1,nt(),e[t]===")"&&(t++,e[t]===";"&&t++),!0}for(;t<e.length&&!isUnquotedStringDelimiter(e[t])&&!isQuote(e[t])&&(!Er||e[t]!==":");)t++;if(e[t-1]===":"&&regexUrlStart.test(e.substring(_r,t+2)))for(;t<e.length&&regexUrlChar.test(e[t]);)t++;if(t>_r){for(;isWhitespace$1(e,t-1)&&t>0;)t--;const Tr=e.slice(_r,t);return Ye+=Tr==="undefined"?"null":JSON.stringify(Tr),e[t]==='"'&&t++,!0}}function er(){if(e[t]==="/"){const Er=t;for(t++;t<e.length&&(e[t]!=="/"||e[t-1]==="\\");)t++;return t++,Ye+='"'.concat(e.substring(Er,t),'"'),!0}}function nr(Er){let _r=Er;for(;_r>0&&isWhitespace$1(e,_r);)_r--;return _r}function ar(){return t>=e.length||isDelimiter(e[t])||isWhitespace$1(e,t)}function sr(Er){Ye+="".concat(e.slice(Er,t),"0")}function lr(Er){throw new JSONRepairError("Invalid character ".concat(JSON.stringify(Er)),t)}function fr(){throw new JSONRepairError("Unexpected character ".concat(JSON.stringify(e[t])),t)}function gr(){throw new JSONRepairError("Unexpected end of json string",e.length)}function dr(){throw new JSONRepairError("Object key expected",t)}function vr(){throw new JSONRepairError("Colon expected",t)}function mr(){const Er=e.slice(t,t+6);throw new JSONRepairError('Invalid unicode character "'.concat(Er,'"'),t)}}function atEndOfBlockComment(e,t){return e[t]==="*"&&e[t+1]==="/"}const createActionRequestID=e=>e.name+JSON.stringify(e.args);class ToolRenderData{constructor(t,Ye){this.message=t,this.client=Ye}getToolActionRequestID(){return createActionRequestID({name:this.message.name,args:this.getInputRepaired()})}getHumanInTheLoopData(){const t=this.getToolActionRequestID();if(!this.client.humanInTheLoop)return null;const Ye=this.client.humanInTheLoop.interruptData.find(rt=>rt.value.actionRequests.some(nt=>nt.id===t));if(!Ye)return null;const tt=Ye.value.actionRequests.findIndex(rt=>rt.id===t);return tt===-1?null:{actionRequestIndex:tt,config:Ye,reviewConfig:Ye.value.reviewConfigs.find(rt=>rt.actionName===Ye.value.actionRequests[tt].name),actionRequest:Ye.value.actionRequests[tt],result:this.client.humanInTheLoop.result[t]}}sendResumeData(t){return t.type==="edit"&&(t.editedAction=t.edited_action),this.client.doneHumanInTheLoopWaiting(this.message.id,this.getToolActionRequestID(),t)}get state(){var Ye,tt;if(this.message.type==="tool"&&((tt=(Ye=this.message)==null?void 0:Ye.additional_kwargs)!=null&&tt.done))return"done";const t=this.getHumanInTheLoopData();return t!=null&&t.result?"done":this.client.status==="interrupted"&&(t!=null&&t.actionRequest)?"interrupted":this.message.tool_input?"loading":"idle"}get input(){try{return JSON.parse(this.message.tool_input)}catch{return null}}get output(){return getMessageContent(this.message.content)}getJSONOutput(){return JSON.parse(this.output)}getJSONOutputSafe(){try{return JSON.parse(this.output)}catch{return null}}getInputRepaired(){try{return JSON.parse(jsonrepair(this.message.tool_input||""))}catch{return{}}}response(t){this.client.doneFEToolWaiting(this.message.id,JSON.stringify(t))}}const DEFAULT_FETCH_IMPLEMENTATION=(...e)=>fetch(...e),LANGSMITH_FETCH_IMPLEMENTATION_KEY=Symbol.for("lg:fetch_implementation"),_getFetchImplementation=()=>globalThis[LANGSMITH_FETCH_IMPLEMENTATION_KEY]??DEFAULT_FETCH_IMPLEMENTATION;var pRetry$1={exports:{}},retry$1={},retry_operation,hasRequiredRetry_operation;function requireRetry_operation(){if(hasRequiredRetry_operation)return retry_operation;hasRequiredRetry_operation=1;function e(t,Ye){typeof Ye=="boolean"&&(Ye={forever:Ye}),this._originalTimeouts=JSON.parse(JSON.stringify(t)),this._timeouts=t,this._options=Ye||{},this._maxRetryTime=Ye&&Ye.maxRetryTime||1/0,this._fn=null,this._errors=[],this._attempts=1,this._operationTimeout=null,this._operationTimeoutCb=null,this._timeout=null,this._operationStart=null,this._timer=null,this._options.forever&&(this._cachedTimeouts=this._timeouts.slice(0))}return retry_operation=e,e.prototype.reset=function(){this._attempts=1,this._timeouts=this._originalTimeouts.slice(0)},e.prototype.stop=function(){this._timeout&&clearTimeout(this._timeout),this._timer&&clearTimeout(this._timer),this._timeouts=[],this._cachedTimeouts=null},e.prototype.retry=function(t){if(this._timeout&&clearTimeout(this._timeout),!t)return!1;var Ye=new Date().getTime();if(t&&Ye-this._operationStart>=this._maxRetryTime)return this._errors.push(t),this._errors.unshift(new Error("RetryOperation timeout occurred")),!1;this._errors.push(t);var tt=this._timeouts.shift();if(tt===void 0)if(this._cachedTimeouts)this._errors.splice(0,this._errors.length-1),tt=this._cachedTimeouts.slice(-1);else return!1;var rt=this;return this._timer=setTimeout(function(){rt._attempts++,rt._operationTimeoutCb&&(rt._timeout=setTimeout(function(){rt._operationTimeoutCb(rt._attempts)},rt._operationTimeout),rt._options.unref&&rt._timeout.unref()),rt._fn(rt._attempts)},tt),this._options.unref&&this._timer.unref(),!0},e.prototype.attempt=function(t,Ye){this._fn=t,Ye&&(Ye.timeout&&(this._operationTimeout=Ye.timeout),Ye.cb&&(this._operationTimeoutCb=Ye.cb));var tt=this;this._operationTimeoutCb&&(this._timeout=setTimeout(function(){tt._operationTimeoutCb()},tt._operationTimeout)),this._operationStart=new Date().getTime(),this._fn(this._attempts)},e.prototype.try=function(t){console.log("Using RetryOperation.try() is deprecated"),this.attempt(t)},e.prototype.start=function(t){console.log("Using RetryOperation.start() is deprecated"),this.attempt(t)},e.prototype.start=e.prototype.try,e.prototype.errors=function(){return this._errors},e.prototype.attempts=function(){return this._attempts},e.prototype.mainError=function(){if(this._errors.length===0)return null;for(var t={},Ye=null,tt=0,rt=0;rt<this._errors.length;rt++){var nt=this._errors[rt],at=nt.message,it=(t[at]||0)+1;t[at]=it,it>=tt&&(Ye=nt,tt=it)}return Ye},retry_operation}var hasRequiredRetry$1;function requireRetry$1(){return hasRequiredRetry$1||(hasRequiredRetry$1=1,function(e){var t=requireRetry_operation();e.operation=function(Ye){var tt=e.timeouts(Ye);return new t(tt,{forever:Ye&&(Ye.forever||Ye.retries===1/0),unref:Ye&&Ye.unref,maxRetryTime:Ye&&Ye.maxRetryTime})},e.timeouts=function(Ye){if(Ye instanceof Array)return[].concat(Ye);var tt={retries:10,factor:2,minTimeout:1*1e3,maxTimeout:1/0,randomize:!1};for(var rt in Ye)tt[rt]=Ye[rt];if(tt.minTimeout>tt.maxTimeout)throw new Error("minTimeout is greater than maxTimeout");for(var nt=[],at=0;at<tt.retries;at++)nt.push(this.createTimeout(at,tt));return Ye&&Ye.forever&&!nt.length&&nt.push(this.createTimeout(at,tt)),nt.sort(function(it,ot){return it-ot}),nt},e.createTimeout=function(Ye,tt){var rt=tt.randomize?Math.random()+1:1,nt=Math.round(rt*Math.max(tt.minTimeout,1)*Math.pow(tt.factor,Ye));return nt=Math.min(nt,tt.maxTimeout),nt},e.wrap=function(Ye,tt,rt){if(tt instanceof Array&&(rt=tt,tt=null),!rt){rt=[];for(var nt in Ye)typeof Ye[nt]=="function"&&rt.push(nt)}for(var at=0;at<rt.length;at++){var it=rt[at],ot=Ye[it];Ye[it]=(function(At){var Rt=e.operation(tt),qt=Array.prototype.slice.call(arguments,1),Ft=qt.pop();qt.push(function(Ut){Rt.retry(Ut)||(Ut&&(arguments[0]=Rt.mainError()),Ft.apply(this,arguments))}),Rt.attempt(function(){At.apply(Ye,qt)})}).bind(Ye,ot),Ye[it].options=tt}}}(retry$1)),retry$1}var retry,hasRequiredRetry;function requireRetry(){return hasRequiredRetry||(hasRequiredRetry=1,retry=requireRetry$1()),retry}var hasRequiredPRetry;function requirePRetry(){if(hasRequiredPRetry)return pRetry$1.exports;hasRequiredPRetry=1;const e=requireRetry(),t=["Failed to fetch","NetworkError when attempting to fetch resource.","The Internet connection appears to be offline.","Network request failed"];class Ye extends Error{constructor(it){super(),it instanceof Error?(this.originalError=it,{message:it}=it):(this.originalError=new Error(it),this.originalError.stack=this.stack),this.name="AbortError",this.message=it}}const tt=(at,it,ot)=>{const ct=ot.retries-(it-1);return at.attemptNumber=it,at.retriesLeft=ct,at},rt=at=>t.includes(at),nt=(at,it)=>new Promise((ot,ct)=>{it={onFailedAttempt:()=>{},retries:10,...it};const At=e.operation(it);At.attempt(async Rt=>{try{ot(await at(Rt))}catch(qt){if(!(qt instanceof Error)){ct(new TypeError(`Non-error was thrown: "${qt}". You should only throw errors.`));return}if(qt instanceof Ye)At.stop(),ct(qt.originalError);else if(qt instanceof TypeError&&!rt(qt.message))At.stop(),ct(qt);else{tt(qt,Rt,it);try{await it.onFailedAttempt(qt)}catch(Ft){ct(Ft);return}At.retry(qt)||ct(At.mainError())}}})});return pRetry$1.exports=nt,pRetry$1.exports.default=nt,pRetry$1.exports.AbortError=Ye,pRetry$1.exports}var pRetryExports=requirePRetry();const pRetry=getDefaultExportFromCjs(pRetryExports);var dist$1={},eventemitter3$1={exports:{}},hasRequiredEventemitter3$1;function requireEventemitter3$1(){return hasRequiredEventemitter3$1||(hasRequiredEventemitter3$1=1,function(e){var t=Object.prototype.hasOwnProperty,Ye="~";function tt(){}Object.create&&(tt.prototype=Object.create(null),new tt().__proto__||(Ye=!1));function rt(ot,ct,At){this.fn=ot,this.context=ct,this.once=At||!1}function nt(ot,ct,At,Rt,qt){if(typeof At!="function")throw new TypeError("The listener must be a function");var Ft=new rt(At,Rt||ot,qt),Ut=Ye?Ye+ct:ct;return ot._events[Ut]?ot._events[Ut].fn?ot._events[Ut]=[ot._events[Ut],Ft]:ot._events[Ut].push(Ft):(ot._events[Ut]=Ft,ot._eventsCount++),ot}function at(ot,ct){--ot._eventsCount===0?ot._events=new tt:delete ot._events[ct]}function it(){this._events=new tt,this._eventsCount=0}it.prototype.eventNames=function(){var ct=[],At,Rt;if(this._eventsCount===0)return ct;for(Rt in At=this._events)t.call(At,Rt)&&ct.push(Ye?Rt.slice(1):Rt);return Object.getOwnPropertySymbols?ct.concat(Object.getOwnPropertySymbols(At)):ct},it.prototype.listeners=function(ct){var At=Ye?Ye+ct:ct,Rt=this._events[At];if(!Rt)return[];if(Rt.fn)return[Rt.fn];for(var qt=0,Ft=Rt.length,Ut=new Array(Ft);qt<Ft;qt++)Ut[qt]=Rt[qt].fn;return Ut},it.prototype.listenerCount=function(ct){var At=Ye?Ye+ct:ct,Rt=this._events[At];return Rt?Rt.fn?1:Rt.length:0},it.prototype.emit=function(ct,At,Rt,qt,Ft,Ut){var Ht=Ye?Ye+ct:ct;if(!this._events[Ht])return!1;var zt=this._events[Ht],Yt=arguments.length,Gt,Vt;if(zt.fn){switch(zt.once&&this.removeListener(ct,zt.fn,void 0,!0),Yt){case 1:return zt.fn.call(zt.context),!0;case 2:return zt.fn.call(zt.context,At),!0;case 3:return zt.fn.call(zt.context,At,Rt),!0;case 4:return zt.fn.call(zt.context,At,Rt,qt),!0;case 5:return zt.fn.call(zt.context,At,Rt,qt,Ft),!0;case 6:return zt.fn.call(zt.context,At,Rt,qt,Ft,Ut),!0}for(Vt=1,Gt=new Array(Yt-1);Vt<Yt;Vt++)Gt[Vt-1]=arguments[Vt];zt.fn.apply(zt.context,Gt)}else{var Zt=zt.length,Xt;for(Vt=0;Vt<Zt;Vt++)switch(zt[Vt].once&&this.removeListener(ct,zt[Vt].fn,void 0,!0),Yt){case 1:zt[Vt].fn.call(zt[Vt].context);break;case 2:zt[Vt].fn.call(zt[Vt].context,At);break;case 3:zt[Vt].fn.call(zt[Vt].context,At,Rt);break;case 4:zt[Vt].fn.call(zt[Vt].context,At,Rt,qt);break;default:if(!Gt)for(Xt=1,Gt=new Array(Yt-1);Xt<Yt;Xt++)Gt[Xt-1]=arguments[Xt];zt[Vt].fn.apply(zt[Vt].context,Gt)}}return!0},it.prototype.on=function(ct,At,Rt){return nt(this,ct,At,Rt,!1)},it.prototype.once=function(ct,At,Rt){return nt(this,ct,At,Rt,!0)},it.prototype.removeListener=function(ct,At,Rt,qt){var Ft=Ye?Ye+ct:ct;if(!this._events[Ft])return this;if(!At)return at(this,Ft),this;var Ut=this._events[Ft];if(Ut.fn)Ut.fn===At&&(!qt||Ut.once)&&(!Rt||Ut.context===Rt)&&at(this,Ft);else{for(var Ht=0,zt=[],Yt=Ut.length;Ht<Yt;Ht++)(Ut[Ht].fn!==At||qt&&!Ut[Ht].once||Rt&&Ut[Ht].context!==Rt)&&zt.push(Ut[Ht]);zt.length?this._events[Ft]=zt.length===1?zt[0]:zt:at(this,Ft)}return this},it.prototype.removeAllListeners=function(ct){var At;return ct?(At=Ye?Ye+ct:ct,this._events[At]&&at(this,At)):(this._events=new tt,this._eventsCount=0),this},it.prototype.off=it.prototype.removeListener,it.prototype.addListener=it.prototype.on,it.prefixed=Ye,it.EventEmitter=it,e.exports=it}(eventemitter3$1)),eventemitter3$1.exports}var pTimeout={exports:{}},pFinally,hasRequiredPFinally;function requirePFinally(){return hasRequiredPFinally||(hasRequiredPFinally=1,pFinally=(e,t)=>(t=t||(()=>{}),e.then(Ye=>new Promise(tt=>{tt(t())}).then(()=>Ye),Ye=>new Promise(tt=>{tt(t())}).then(()=>{throw Ye})))),pFinally}var hasRequiredPTimeout;function requirePTimeout(){if(hasRequiredPTimeout)return pTimeout.exports;hasRequiredPTimeout=1;const e=requirePFinally();class t extends Error{constructor(rt){super(rt),this.name="TimeoutError"}}const Ye=(tt,rt,nt)=>new Promise((at,it)=>{if(typeof rt!="number"||rt<0)throw new TypeError("Expected `milliseconds` to be a positive number");if(rt===1/0){at(tt);return}const ot=setTimeout(()=>{if(typeof nt=="function"){try{at(nt())}catch(Rt){it(Rt)}return}const ct=typeof nt=="string"?nt:`Promise timed out after ${rt} milliseconds`,At=nt instanceof Error?nt:new t(ct);typeof tt.cancel=="function"&&tt.cancel(),it(At)},rt);e(tt.then(at,it),()=>{clearTimeout(ot)})});return pTimeout.exports=Ye,pTimeout.exports.default=Ye,pTimeout.exports.TimeoutError=t,pTimeout.exports}var priorityQueue$1={},lowerBound={},hasRequiredLowerBound;function requireLowerBound(){if(hasRequiredLowerBound)return lowerBound;hasRequiredLowerBound=1,Object.defineProperty(lowerBound,"__esModule",{value:!0});function e(t,Ye,tt){let rt=0,nt=t.length;for(;nt>0;){const at=nt/2|0;let it=rt+at;tt(t[it],Ye)<=0?(rt=++it,nt-=at+1):nt=at}return rt}return lowerBound.default=e,lowerBound}var hasRequiredPriorityQueue$1;function requirePriorityQueue$1(){if(hasRequiredPriorityQueue$1)return priorityQueue$1;hasRequiredPriorityQueue$1=1,Object.defineProperty(priorityQueue$1,"__esModule",{value:!0});const e=requireLowerBound();class t{constructor(){this._queue=[]}enqueue(tt,rt){rt=Object.assign({priority:0},rt);const nt={priority:rt.priority,run:tt};if(this.size&&this._queue[this.size-1].priority>=rt.priority){this._queue.push(nt);return}const at=e.default(this._queue,nt,(it,ot)=>ot.priority-it.priority);this._queue.splice(at,0,nt)}dequeue(){const tt=this._queue.shift();return tt==null?void 0:tt.run}filter(tt){return this._queue.filter(rt=>rt.priority===tt.priority).map(rt=>rt.run)}get size(){return this._queue.length}}return priorityQueue$1.default=t,priorityQueue$1}var hasRequiredDist$1;function requireDist$1(){if(hasRequiredDist$1)return dist$1;hasRequiredDist$1=1,Object.defineProperty(dist$1,"__esModule",{value:!0});const e=requireEventemitter3$1(),t=requirePTimeout(),Ye=requirePriorityQueue$1(),tt=()=>{},rt=new t.TimeoutError;class nt extends e{constructor(it){var ot,ct,At,Rt;if(super(),this._intervalCount=0,this._intervalEnd=0,this._pendingCount=0,this._resolveEmpty=tt,this._resolveIdle=tt,it=Object.assign({carryoverConcurrencyCount:!1,intervalCap:1/0,interval:0,concurrency:1/0,autoStart:!0,queueClass:Ye.default},it),!(typeof it.intervalCap=="number"&&it.intervalCap>=1))throw new TypeError(`Expected \`intervalCap\` to be a number from 1 and up, got \`${(ct=(ot=it.intervalCap)===null||ot===void 0?void 0:ot.toString())!==null&&ct!==void 0?ct:""}\` (${typeof it.intervalCap})`);if(it.interval===void 0||!(Number.isFinite(it.interval)&&it.interval>=0))throw new TypeError(`Expected \`interval\` to be a finite number >= 0, got \`${(Rt=(At=it.interval)===null||At===void 0?void 0:At.toString())!==null&&Rt!==void 0?Rt:""}\` (${typeof it.interval})`);this._carryoverConcurrencyCount=it.carryoverConcurrencyCount,this._isIntervalIgnored=it.intervalCap===1/0||it.interval===0,this._intervalCap=it.intervalCap,this._interval=it.interval,this._queue=new it.queueClass,this._queueClass=it.queueClass,this.concurrency=it.concurrency,this._timeout=it.timeout,this._throwOnTimeout=it.throwOnTimeout===!0,this._isPaused=it.autoStart===!1}get _doesIntervalAllowAnother(){return this._isIntervalIgnored||this._intervalCount<this._intervalCap}get _doesConcurrentAllowAnother(){return this._pendingCount<this._concurrency}_next(){this._pendingCount--,this._tryToStartAnother(),this.emit("next")}_resolvePromises(){this._resolveEmpty(),this._resolveEmpty=tt,this._pendingCount===0&&(this._resolveIdle(),this._resolveIdle=tt,this.emit("idle"))}_onResumeInterval(){this._onInterval(),this._initializeIntervalIfNeeded(),this._timeoutId=void 0}_isIntervalPaused(){const it=Date.now();if(this._intervalId===void 0){const ot=this._intervalEnd-it;if(ot<0)this._intervalCount=this._carryoverConcurrencyCount?this._pendingCount:0;else return this._timeoutId===void 0&&(this._timeoutId=setTimeout(()=>{this._onResumeInterval()},ot)),!0}return!1}_tryToStartAnother(){if(this._queue.size===0)return this._intervalId&&clearInterval(this._intervalId),this._intervalId=void 0,this._resolvePromises(),!1;if(!this._isPaused){const it=!this._isIntervalPaused();if(this._doesIntervalAllowAnother&&this._doesConcurrentAllowAnother){const ot=this._queue.dequeue();return ot?(this.emit("active"),ot(),it&&this._initializeIntervalIfNeeded(),!0):!1}}return!1}_initializeIntervalIfNeeded(){this._isIntervalIgnored||this._intervalId!==void 0||(this._intervalId=setInterval(()=>{this._onInterval()},this._interval),this._intervalEnd=Date.now()+this._interval)}_onInterval(){this._intervalCount===0&&this._pendingCount===0&&this._intervalId&&(clearInterval(this._intervalId),this._intervalId=void 0),this._intervalCount=this._carryoverConcurrencyCount?this._pendingCount:0,this._processQueue()}_processQueue(){for(;this._tryToStartAnother(););}get concurrency(){return this._concurrency}set concurrency(it){if(!(typeof it=="number"&&it>=1))throw new TypeError(`Expected \`concurrency\` to be a number from 1 and up, got \`${it}\` (${typeof it})`);this._concurrency=it,this._processQueue()}async add(it,ot={}){return new Promise((ct,At)=>{const Rt=async()=>{this._pendingCount++,this._intervalCount++;try{const qt=this._timeout===void 0&&ot.timeout===void 0?it():t.default(Promise.resolve(it()),ot.timeout===void 0?this._timeout:ot.timeout,()=>{(ot.throwOnTimeout===void 0?this._throwOnTimeout:ot.throwOnTimeout)&&At(rt)});ct(await qt)}catch(qt){At(qt)}this._next()};this._queue.enqueue(Rt,ot),this._tryToStartAnother(),this.emit("add")})}async addAll(it,ot){return Promise.all(it.map(async ct=>this.add(ct,ot)))}start(){return this._isPaused?(this._isPaused=!1,this._processQueue(),this):this}pause(){this._isPaused=!0}clear(){this._queue=new this._queueClass}async onEmpty(){if(this._queue.size!==0)return new Promise(it=>{const ot=this._resolveEmpty;this._resolveEmpty=()=>{ot(),it()}})}async onIdle(){if(!(this._pendingCount===0&&this._queue.size===0))return new Promise(it=>{const ot=this._resolveIdle;this._resolveIdle=()=>{ot(),it()}})}get size(){return this._queue.size}sizeBy(it){return this._queue.filter(it).length}get pending(){return this._pendingCount}get isPaused(){return this._isPaused}get timeout(){return this._timeout}set timeout(it){this._timeout=it}}return dist$1.default=nt,dist$1}var distExports$1=requireDist$1();const PQueueMod=getDefaultExportFromCjs(distExports$1),STATUS_NO_RETRY=[400,401,402,403,404,405,406,407,408,409,422];function isResponse$1(e){return e==null||typeof e!="object"?!1:"status"in e&&"statusText"in e&&"text"in e}var HTTPError=class Qd extends Error{constructor(Ye,tt,rt){super(`HTTP ${Ye}: ${tt}`);Cr(this,"status");Cr(this,"text");Cr(this,"response");this.status=Ye,this.text=tt,this.response=rt}static async fromResponse(Ye,tt){try{return new Qd(Ye.status,await Ye.text(),tt!=null&&tt.includeResponse?Ye:void 0)}catch{return new Qd(Ye.status,Ye.statusText,tt!=null&&tt.includeResponse?Ye:void 0)}}},AsyncCaller=class{constructor(e){Cr(this,"maxConcurrency");Cr(this,"maxRetries");Cr(this,"queue");Cr(this,"onFailedResponseHook");Cr(this,"customFetch");this.maxConcurrency=e.maxConcurrency??1/0,this.maxRetries=e.maxRetries??4,"default"in PQueueMod?this.queue=new PQueueMod.default({concurrency:this.maxConcurrency}):this.queue=new PQueueMod({concurrency:this.maxConcurrency}),this.onFailedResponseHook=e==null?void 0:e.onFailedResponseHook,this.customFetch=e.fetch}call(e,...t){const{onFailedResponseHook:Ye}=this;return this.queue.add(()=>pRetry(()=>e(...t).catch(async tt=>{throw tt instanceof Error?tt:isResponse$1(tt)?await HTTPError.fromResponse(tt,{includeResponse:!!Ye}):new Error(tt)}),{async onFailedAttempt(tt){if(tt.message.startsWith("Cancel")||tt.message.startsWith("TimeoutError")||tt.message.startsWith("AbortError")||(tt==null?void 0:tt.code)==="ECONNABORTED")throw tt;if(tt instanceof HTTPError){if(STATUS_NO_RETRY.includes(tt.status))throw tt;Ye&&tt.response&&await Ye(tt.response)}},retries:this.maxRetries,randomize:!0}),{throwOnTimeout:!0})}callWithOptions(e,t,...Ye){return e.signal?Promise.race([this.call(t,...Ye),new Promise((tt,rt)=>{var nt;(nt=e.signal)==null||nt.addEventListener("abort",()=>{rt(new Error("AbortError"))})})]):this.call(t,...Ye)}fetch(...e){const t=this.customFetch??_getFetchImplementation();return this.call(()=>t(...e).then(Ye=>Ye.ok?Ye:Promise.reject(Ye)))}},define_process_env_default={};function getEnvironmentVariable(e){try{return typeof process<"u"?define_process_env_default==null?void 0:define_process_env_default[e]:void 0}catch{return}}function mergeSignals(...e){const t=e.filter(tt=>tt!=null);if(t.length===0)return;if(t.length===1)return t[0];const Ye=new AbortController;for(const tt of e){if(tt!=null&&tt.aborted)return Ye.abort(tt.reason),Ye.signal;tt==null||tt.addEventListener("abort",()=>Ye.abort(tt.reason),{once:!0})}return Ye.signal}const CR=13,LF=10,NULL=0,COLON=58,SPACE=32,TRAILING_NEWLINE=[CR,LF];function BytesLineDecoder(){let e=[],t=!1;return new TransformStream({start(){e=[],t=!1},transform(Ye,tt){let rt=Ye;if(t&&(rt=joinArrays([[CR],rt]),t=!1),rt.length>0&&rt.at(-1)===CR&&(t=!0,rt=rt.subarray(0,-1)),!rt.length)return;const nt=TRAILING_NEWLINE.includes(rt.at(-1)),at=rt.length-1,{lines:it}=rt.reduce((ot,ct,At)=>(ot.from>At||((ct===CR||ct===LF)&&(ot.lines.push(rt.subarray(ot.from,At)),ct===CR&&rt[At+1]===LF?ot.from=At+2:ot.from=At+1),At===at&&ot.from<=at&&ot.lines.push(rt.subarray(ot.from))),ot),{lines:[],from:0});if(it.length===1&&!nt){e.push(it[0]);return}e.length&&(e.push(it[0]),it[0]=joinArrays(e),e=[]),nt||it.length&&(e=[it.pop()]);for(const ot of it)tt.enqueue(ot)},flush(Ye){e.length&&Ye.enqueue(joinArrays(e))}})}function SSEDecoder(){let e="",t=[],Ye="",tt=null;const rt=new TextDecoder;return new TransformStream({transform(nt,at){if(!nt.length){if(!e&&!t.length&&!Ye&&tt==null)return;const At={id:Ye||void 0,event:e,data:t.length?decodeArraysToJson(rt,t):null};e="",t=[],tt=null,at.enqueue(At);return}if(nt[0]===COLON)return;const it=nt.indexOf(COLON);if(it===-1)return;const ot=rt.decode(nt.subarray(0,it));let ct=nt.subarray(it+1);if(ct[0]===SPACE&&(ct=ct.subarray(1)),ot==="event")e=rt.decode(ct);else if(ot==="data")t.push(ct);else if(ot==="id")ct.indexOf(NULL)===-1&&(Ye=rt.decode(ct));else if(ot==="retry"){const At=Number.parseInt(rt.decode(ct),10);Number.isNaN(At)||(tt=At)}},flush(nt){e&&nt.enqueue({id:Ye||void 0,event:e,data:t.length?decodeArraysToJson(rt,t):null})}})}function joinArrays(e){const t=e.reduce((rt,nt)=>rt+nt.length,0),Ye=new Uint8Array(t);let tt=0;for(const rt of e)Ye.set(rt,tt),tt+=rt.length;return Ye}function decodeArraysToJson(e,t){return JSON.parse(e.decode(joinArrays(t)))}var IterableReadableStream=class Jd extends ReadableStream{constructor(){super(...arguments);Cr(this,"reader")}ensureReader(){this.reader||(this.reader=this.getReader())}async next(){this.ensureReader();try{const Ye=await this.reader.read();return Ye.done?(this.reader.releaseLock(),{done:!0,value:void 0}):{done:!1,value:Ye.value}}catch(Ye){throw this.reader.releaseLock(),Ye}}async return(){if(this.ensureReader(),this.locked){const Ye=this.reader.cancel();this.reader.releaseLock(),await Ye}return{done:!0,value:void 0}}async throw(Ye){if(this.ensureReader(),this.locked){const tt=this.reader.cancel();this.reader.releaseLock(),await tt}throw Ye}async[Symbol.asyncDispose](){await this.return()}[Symbol.asyncIterator](){return this}static fromReadableStream(Ye){const tt=Ye.getReader();return new Jd({start(rt){return nt();function nt(){return tt.read().then(({done:at,value:it})=>{if(at){rt.close();return}return rt.enqueue(it),nt()})}},cancel(){tt.releaseLock()}})}static fromAsyncGenerator(Ye){return new Jd({async pull(tt){const{value:rt,done:nt}=await Ye.next();nt&&tt.close(),tt.enqueue(rt)},async cancel(tt){await Ye.return(tt)}})}};function*iterateHeaders(e){let t,Ye=!1;if(e instanceof Headers){const tt=[];e.forEach((rt,nt)=>{tt.push([nt,rt])}),t=tt}else Array.isArray(e)?t=e:(Ye=!0,t=Object.entries(e??{}));for(const tt of t){const rt=tt[0];if(typeof rt!="string")throw new TypeError(`Expected header name to be a string, got ${typeof rt}`);const nt=Array.isArray(tt[1])?tt[1]:[tt[1]];let at=!1;for(const it of nt)it!==void 0&&(Ye&&!at&&(at=!0,yield[rt,null]),yield[rt,it])}}function mergeHeaders(...e){const t=new Headers;for(const tt of e)if(tt)for(const[rt,nt]of iterateHeaders(tt))nt===null?t.delete(rt):t.append(rt,nt);const Ye=[];return t.forEach((tt,rt)=>{Ye.push([rt,tt])}),Object.fromEntries(Ye)}function getApiKey(e){if(e)return e;const t=["LANGGRAPH","LANGSMITH","LANGCHAIN"];for(const Ye of t){const tt=getEnvironmentVariable(`${Ye}_API_KEY`);if(tt)return tt.trim().replace(/^["']|["']$/g,"")}}const REGEX_RUN_METADATA=/(\/threads\/(?<thread_id>.+))?\/runs\/(?<run_id>.+)/;function getRunMetadataFromResponse(e){var tt;const t=e.headers.get("Content-Location");if(!t)return;const Ye=REGEX_RUN_METADATA.exec(t);if((tt=Ye==null?void 0:Ye.groups)!=null&&tt.run_id)return{run_id:Ye.groups.run_id,thread_id:Ye.groups.thread_id||void 0}}var BaseClient=class{constructor(e){Cr(this,"asyncCaller");Cr(this,"timeoutMs");Cr(this,"apiUrl");Cr(this,"defaultHeaders");Cr(this,"onRequest");var rt;const t={maxRetries:4,maxConcurrency:4,...e==null?void 0:e.callerOptions};let Ye="http://localhost:8123";if(!(e!=null&&e.apiUrl)&&typeof globalThis=="object"&&globalThis!=null){const nt=Symbol.for("langgraph_api:fetch"),at=Symbol.for("langgraph_api:url"),it=globalThis;it[nt]&&(t.fetch??(t.fetch=it[nt])),it[at]&&(Ye=it[at])}this.asyncCaller=new AsyncCaller(t),this.timeoutMs=e==null?void 0:e.timeoutMs,this.apiUrl=((rt=e==null?void 0:e.apiUrl)==null?void 0:rt.replace(/\/$/,""))||Ye,this.defaultHeaders=(e==null?void 0:e.defaultHeaders)||{},this.onRequest=e==null?void 0:e.onRequest;const tt=getApiKey(e==null?void 0:e.apiKey);tt&&(this.defaultHeaders["x-api-key"]=tt)}prepareFetchOptions(e,t){const Ye={...t,headers:mergeHeaders(this.defaultHeaders,t==null?void 0:t.headers)};Ye.json&&(Ye.body=JSON.stringify(Ye.json),Ye.headers=mergeHeaders(Ye.headers,{"content-type":"application/json"}),delete Ye.json),Ye.withResponse&&delete Ye.withResponse;let tt=null;typeof(t==null?void 0:t.timeoutMs)<"u"?t.timeoutMs!=null&&(tt=AbortSignal.timeout(t.timeoutMs)):this.timeoutMs!=null&&(tt=AbortSignal.timeout(this.timeoutMs)),Ye.signal=mergeSignals(tt,Ye.signal);const rt=new URL(`${this.apiUrl}${e}`);if(Ye.params){for(const[nt,at]of Object.entries(Ye.params)){if(at==null)continue;const it=typeof at=="string"||typeof at=="number"?at.toString():JSON.stringify(at);rt.searchParams.append(nt,it)}delete Ye.params}return[rt,Ye]}async fetch(e,t){const[Ye,tt]=this.prepareFetchOptions(e,t);let rt=tt;this.onRequest&&(rt=await this.onRequest(Ye,tt));const nt=await this.asyncCaller.fetch(Ye,rt),at=(()=>{if(!(nt.status===202||nt.status===204))return nt.json()})();return t!=null&&t.withResponse?[await at,nt]:at}},CronsClient=class extends BaseClient{async createForThread(e,t,Ye){const tt={schedule:Ye==null?void 0:Ye.schedule,input:Ye==null?void 0:Ye.input,config:Ye==null?void 0:Ye.config,context:Ye==null?void 0:Ye.context,metadata:Ye==null?void 0:Ye.metadata,assistant_id:t,interrupt_before:Ye==null?void 0:Ye.interruptBefore,interrupt_after:Ye==null?void 0:Ye.interruptAfter,webhook:Ye==null?void 0:Ye.webhook,multitask_strategy:Ye==null?void 0:Ye.multitaskStrategy,if_not_exists:Ye==null?void 0:Ye.ifNotExists,checkpoint_during:Ye==null?void 0:Ye.checkpointDuring,durability:Ye==null?void 0:Ye.durability};return this.fetch(`/threads/${e}/runs/crons`,{method:"POST",json:tt})}async create(e,t){const Ye={schedule:t==null?void 0:t.schedule,input:t==null?void 0:t.input,config:t==null?void 0:t.config,context:t==null?void 0:t.context,metadata:t==null?void 0:t.metadata,assistant_id:e,interrupt_before:t==null?void 0:t.interruptBefore,interrupt_after:t==null?void 0:t.interruptAfter,webhook:t==null?void 0:t.webhook,multitask_strategy:t==null?void 0:t.multitaskStrategy,if_not_exists:t==null?void 0:t.ifNotExists,checkpoint_during:t==null?void 0:t.checkpointDuring,durability:t==null?void 0:t.durability};return this.fetch("/runs/crons",{method:"POST",json:Ye})}async delete(e){await this.fetch(`/runs/crons/${e}`,{method:"DELETE"})}async search(e){return this.fetch("/runs/crons/search",{method:"POST",json:{assistant_id:(e==null?void 0:e.assistantId)??void 0,thread_id:(e==null?void 0:e.threadId)??void 0,limit:(e==null?void 0:e.limit)??10,offset:(e==null?void 0:e.offset)??0,sort_by:(e==null?void 0:e.sortBy)??void 0,sort_order:(e==null?void 0:e.sortOrder)??void 0,select:(e==null?void 0:e.select)??void 0}})}async count(e){return this.fetch("/runs/crons/count",{method:"POST",json:{assistant_id:(e==null?void 0:e.assistantId)??void 0,thread_id:(e==null?void 0:e.threadId)??void 0}})}},AssistantsClient=class extends BaseClient{async get(e){return this.fetch(`/assistants/${e}`)}async getGraph(e,t){return this.fetch(`/assistants/${e}/graph`,{params:{xray:t==null?void 0:t.xray}})}async getSchemas(e){return this.fetch(`/assistants/${e}/schemas`)}async getSubgraphs(e,t){return t!=null&&t.namespace?this.fetch(`/assistants/${e}/subgraphs/${t.namespace}`,{params:{recurse:t==null?void 0:t.recurse}}):this.fetch(`/assistants/${e}/subgraphs`,{params:{recurse:t==null?void 0:t.recurse}})}async create(e){return this.fetch("/assistants",{method:"POST",json:{graph_id:e.graphId,config:e.config,context:e.context,metadata:e.metadata,assistant_id:e.assistantId,if_exists:e.ifExists,name:e.name,description:e.description}})}async update(e,t){return this.fetch(`/assistants/${e}`,{method:"PATCH",json:{graph_id:t.graphId,config:t.config,context:t.context,metadata:t.metadata,name:t.name,description:t.description}})}async delete(e){return this.fetch(`/assistants/${e}`,{method:"DELETE"})}async search(e){return this.fetch("/assistants/search",{method:"POST",json:{graph_id:(e==null?void 0:e.graphId)??void 0,metadata:(e==null?void 0:e.metadata)??void 0,limit:(e==null?void 0:e.limit)??10,offset:(e==null?void 0:e.offset)??0,sort_by:(e==null?void 0:e.sortBy)??void 0,sort_order:(e==null?void 0:e.sortOrder)??void 0,select:(e==null?void 0:e.select)??void 0}})}async count(e){return this.fetch("/assistants/count",{method:"POST",json:{metadata:(e==null?void 0:e.metadata)??void 0,graph_id:(e==null?void 0:e.graphId)??void 0}})}async getVersions(e,t){return this.fetch(`/assistants/${e}/versions`,{method:"POST",json:{metadata:(t==null?void 0:t.metadata)??void 0,limit:(t==null?void 0:t.limit)??10,offset:(t==null?void 0:t.offset)??0}})}async setLatest(e,t){return this.fetch(`/assistants/${e}/latest`,{method:"POST",json:{version:t}})}},ThreadsClient=class extends BaseClient{async get(e){return this.fetch(`/threads/${e}`)}async create(e){var Ye;const t=typeof(e==null?void 0:e.ttl)=="number"?{ttl:e.ttl,strategy:"delete"}:e==null?void 0:e.ttl;return this.fetch("/threads",{method:"POST",json:{metadata:{...e==null?void 0:e.metadata,graph_id:e==null?void 0:e.graphId},thread_id:e==null?void 0:e.threadId,if_exists:e==null?void 0:e.ifExists,supersteps:(Ye=e==null?void 0:e.supersteps)==null?void 0:Ye.map(tt=>({updates:tt.updates.map(rt=>({values:rt.values,command:rt.command,as_node:rt.asNode}))})),ttl:t}})}async copy(e){return this.fetch(`/threads/${e}/copy`,{method:"POST"})}async update(e,t){const Ye=typeof(t==null?void 0:t.ttl)=="number"?{ttl:t.ttl,strategy:"delete"}:t==null?void 0:t.ttl;return this.fetch(`/threads/${e}`,{method:"PATCH",json:{metadata:t==null?void 0:t.metadata,ttl:Ye}})}async delete(e){return this.fetch(`/threads/${e}`,{method:"DELETE"})}async search(e){return this.fetch("/threads/search",{method:"POST",json:{metadata:(e==null?void 0:e.metadata)??void 0,ids:(e==null?void 0:e.ids)??void 0,limit:(e==null?void 0:e.limit)??10,offset:(e==null?void 0:e.offset)??0,status:e==null?void 0:e.status,sort_by:e==null?void 0:e.sortBy,sort_order:e==null?void 0:e.sortOrder,select:(e==null?void 0:e.select)??void 0}})}async count(e){return this.fetch("/threads/count",{method:"POST",json:{metadata:(e==null?void 0:e.metadata)??void 0,values:(e==null?void 0:e.values)??void 0,status:(e==null?void 0:e.status)??void 0}})}async getState(e,t,Ye){return t!=null?typeof t!="string"?this.fetch(`/threads/${e}/state/checkpoint`,{method:"POST",json:{checkpoint:t,subgraphs:Ye==null?void 0:Ye.subgraphs}}):this.fetch(`/threads/${e}/state/${t}`,{params:{subgraphs:Ye==null?void 0:Ye.subgraphs}}):this.fetch(`/threads/${e}/state`,{params:{subgraphs:Ye==null?void 0:Ye.subgraphs}})}async updateState(e,t){return this.fetch(`/threads/${e}/state`,{method:"POST",json:{values:t.values,checkpoint_id:t.checkpointId,checkpoint:t.checkpoint,as_node:t==null?void 0:t.asNode}})}async patchState(e,t){var tt;let Ye;if(typeof e!="string"){if(typeof((tt=e.configurable)==null?void 0:tt.thread_id)!="string")throw new Error("Thread ID is required when updating state with a config.");Ye=e.configurable.thread_id}else Ye=e;return this.fetch(`/threads/${Ye}/state`,{method:"PATCH",json:{metadata:t}})}async getHistory(e,t){return this.fetch(`/threads/${e}/history`,{method:"POST",json:{limit:(t==null?void 0:t.limit)??10,before:t==null?void 0:t.before,metadata:t==null?void 0:t.metadata,checkpoint:t==null?void 0:t.checkpoint}})}async*joinStream(e,t){let[Ye,tt]=this.prepareFetchOptions(`/threads/${e}/stream`,{method:"GET",headers:t!=null&&t.lastEventId?{"Last-Event-ID":t.lastEventId}:void 0,params:t!=null&&t.streamMode?{stream_mode:t.streamMode}:void 0});this.onRequest!=null&&(tt=await this.onRequest(Ye,tt));const nt=((await this.asyncCaller.fetch(Ye,tt)).body||new ReadableStream({start:at=>at.close()})).pipeThrough(BytesLineDecoder()).pipeThrough(SSEDecoder());yield*IterableReadableStream.fromReadableStream(nt)}},RunsClient=class extends BaseClient{async*stream(e,t,Ye){var At;const tt={input:Ye==null?void 0:Ye.input,command:Ye==null?void 0:Ye.command,config:Ye==null?void 0:Ye.config,context:Ye==null?void 0:Ye.context,metadata:Ye==null?void 0:Ye.metadata,stream_mode:Ye==null?void 0:Ye.streamMode,stream_subgraphs:Ye==null?void 0:Ye.streamSubgraphs,stream_resumable:Ye==null?void 0:Ye.streamResumable,feedback_keys:Ye==null?void 0:Ye.feedbackKeys,assistant_id:t,interrupt_before:Ye==null?void 0:Ye.interruptBefore,interrupt_after:Ye==null?void 0:Ye.interruptAfter,checkpoint:Ye==null?void 0:Ye.checkpoint,checkpoint_id:Ye==null?void 0:Ye.checkpointId,webhook:Ye==null?void 0:Ye.webhook,multitask_strategy:Ye==null?void 0:Ye.multitaskStrategy,on_completion:Ye==null?void 0:Ye.onCompletion,on_disconnect:Ye==null?void 0:Ye.onDisconnect,after_seconds:Ye==null?void 0:Ye.afterSeconds,if_not_exists:Ye==null?void 0:Ye.ifNotExists,checkpoint_during:Ye==null?void 0:Ye.checkpointDuring,durability:Ye==null?void 0:Ye.durability},rt=e==null?"/runs/stream":`/threads/${e}/runs/stream`;let[nt,at]=this.prepareFetchOptions(rt,{method:"POST",json:tt,timeoutMs:null,signal:Ye==null?void 0:Ye.signal});this.onRequest!=null&&(at=await this.onRequest(nt,at));const it=await this.asyncCaller.fetch(nt,at),ot=getRunMetadataFromResponse(it);ot&&((At=Ye==null?void 0:Ye.onRunCreated)==null||At.call(Ye,ot));const ct=(it.body||new ReadableStream({start:Rt=>Rt.close()})).pipeThrough(BytesLineDecoder()).pipeThrough(SSEDecoder());yield*IterableReadableStream.fromReadableStream(ct)}async create(e,t,Ye){var ot,ct,At;const tt={input:Ye==null?void 0:Ye.input,command:Ye==null?void 0:Ye.command,config:Ye==null?void 0:Ye.config,context:Ye==null?void 0:Ye.context,metadata:Ye==null?void 0:Ye.metadata,stream_mode:Ye==null?void 0:Ye.streamMode,stream_subgraphs:Ye==null?void 0:Ye.streamSubgraphs,stream_resumable:Ye==null?void 0:Ye.streamResumable,assistant_id:t,interrupt_before:Ye==null?void 0:Ye.interruptBefore,interrupt_after:Ye==null?void 0:Ye.interruptAfter,webhook:Ye==null?void 0:Ye.webhook,checkpoint:Ye==null?void 0:Ye.checkpoint,checkpoint_id:Ye==null?void 0:Ye.checkpointId,multitask_strategy:Ye==null?void 0:Ye.multitaskStrategy,after_seconds:Ye==null?void 0:Ye.afterSeconds,if_not_exists:Ye==null?void 0:Ye.ifNotExists,checkpoint_during:Ye==null?void 0:Ye.checkpointDuring,durability:Ye==null?void 0:Ye.durability,langsmith_tracer:Ye!=null&&Ye._langsmithTracer?{project_name:(ot=Ye==null?void 0:Ye._langsmithTracer)==null?void 0:ot.projectName,example_id:(ct=Ye==null?void 0:Ye._langsmithTracer)==null?void 0:ct.exampleId}:void 0},rt=e===null?"/runs":`/threads/${e}/runs`,[nt,at]=await this.fetch(rt,{method:"POST",json:tt,signal:Ye==null?void 0:Ye.signal,withResponse:!0}),it=getRunMetadataFromResponse(at);return it&&((At=Ye==null?void 0:Ye.onRunCreated)==null||At.call(Ye,it)),nt}async createBatch(e){const t=e.map(Ye=>({...Ye,assistant_id:Ye.assistantId})).map(Ye=>Object.fromEntries(Object.entries(Ye).filter(([tt,rt])=>rt!==void 0)));return this.fetch("/runs/batch",{method:"POST",json:t})}async wait(e,t,Ye){var ct,At,Rt,qt,Ft;const tt={input:Ye==null?void 0:Ye.input,command:Ye==null?void 0:Ye.command,config:Ye==null?void 0:Ye.config,context:Ye==null?void 0:Ye.context,metadata:Ye==null?void 0:Ye.metadata,assistant_id:t,interrupt_before:Ye==null?void 0:Ye.interruptBefore,interrupt_after:Ye==null?void 0:Ye.interruptAfter,checkpoint:Ye==null?void 0:Ye.checkpoint,checkpoint_id:Ye==null?void 0:Ye.checkpointId,webhook:Ye==null?void 0:Ye.webhook,multitask_strategy:Ye==null?void 0:Ye.multitaskStrategy,on_completion:Ye==null?void 0:Ye.onCompletion,on_disconnect:Ye==null?void 0:Ye.onDisconnect,after_seconds:Ye==null?void 0:Ye.afterSeconds,if_not_exists:Ye==null?void 0:Ye.ifNotExists,checkpoint_during:Ye==null?void 0:Ye.checkpointDuring,durability:Ye==null?void 0:Ye.durability,langsmith_tracer:Ye!=null&&Ye._langsmithTracer?{project_name:(ct=Ye==null?void 0:Ye._langsmithTracer)==null?void 0:ct.projectName,example_id:(At=Ye==null?void 0:Ye._langsmithTracer)==null?void 0:At.exampleId}:void 0},rt=e==null?"/runs/wait":`/threads/${e}/runs/wait`,[nt,at]=await this.fetch(rt,{method:"POST",json:tt,timeoutMs:null,signal:Ye==null?void 0:Ye.signal,withResponse:!0}),it=getRunMetadataFromResponse(at);if(it&&((Rt=Ye==null?void 0:Ye.onRunCreated)==null||Rt.call(Ye,it)),((Ye==null?void 0:Ye.raiseError)!==void 0?Ye.raiseError:!0)&&"__error__"in nt&&typeof nt.__error__=="object"&&nt.__error__&&"error"in nt.__error__&&"message"in nt.__error__)throw new Error(`${(qt=nt.__error__)==null?void 0:qt.error}: ${(Ft=nt.__error__)==null?void 0:Ft.message}`);return nt}async list(e,t){return this.fetch(`/threads/${e}/runs`,{params:{limit:(t==null?void 0:t.limit)??10,offset:(t==null?void 0:t.offset)??0,status:(t==null?void 0:t.status)??void 0,select:(t==null?void 0:t.select)??void 0}})}async get(e,t){return this.fetch(`/threads/${e}/runs/${t}`)}async cancel(e,t,Ye=!1,tt="interrupt"){return this.fetch(`/threads/${e}/runs/${t}/cancel`,{method:"POST",params:{wait:Ye?"1":"0",action:tt}})}async join(e,t,Ye){return this.fetch(`/threads/${e}/runs/${t}/join`,{timeoutMs:null,signal:Ye==null?void 0:Ye.signal})}async*joinStream(e,t,Ye){const tt=typeof Ye=="object"&&Ye!=null&&Ye instanceof AbortSignal?{signal:Ye}:Ye;let[rt,nt]=this.prepareFetchOptions(e!=null?`/threads/${e}/runs/${t}/stream`:`/runs/${t}/stream`,{method:"GET",timeoutMs:null,signal:tt==null?void 0:tt.signal,headers:tt!=null&&tt.lastEventId?{"Last-Event-ID":tt.lastEventId}:void 0,params:{cancel_on_disconnect:tt!=null&&tt.cancelOnDisconnect?"1":"0",stream_mode:tt==null?void 0:tt.streamMode}});this.onRequest!=null&&(nt=await this.onRequest(rt,nt));const it=((await this.asyncCaller.fetch(rt,nt)).body||new ReadableStream({start:ot=>ot.close()})).pipeThrough(BytesLineDecoder()).pipeThrough(SSEDecoder());yield*IterableReadableStream.fromReadableStream(it)}async delete(e,t){return this.fetch(`/threads/${e}/runs/${t}`,{method:"DELETE"})}},StoreClient=class extends BaseClient{async putItem(e,t,Ye,tt){e.forEach(nt=>{if(nt.includes("."))throw new Error(`Invalid namespace label '${nt}'. Namespace labels cannot contain periods ('.')`)});const rt={namespace:e,key:t,value:Ye,index:tt==null?void 0:tt.index,ttl:tt==null?void 0:tt.ttl};return this.fetch("/store/items",{method:"PUT",json:rt})}async getItem(e,t,Ye){e.forEach(nt=>{if(nt.includes("."))throw new Error(`Invalid namespace label '${nt}'. Namespace labels cannot contain periods ('.')`)});const tt={namespace:e.join("."),key:t};(Ye==null?void 0:Ye.refreshTtl)!==void 0&&(tt.refresh_ttl=Ye.refreshTtl);const rt=await this.fetch("/store/items",{params:tt});return rt?{...rt,createdAt:rt.created_at,updatedAt:rt.updated_at}:null}async deleteItem(e,t){return e.forEach(Ye=>{if(Ye.includes("."))throw new Error(`Invalid namespace label '${Ye}'. Namespace labels cannot contain periods ('.')`)}),this.fetch("/store/items",{method:"DELETE",json:{namespace:e,key:t}})}async searchItems(e,t){const Ye={namespace_prefix:e,filter:t==null?void 0:t.filter,limit:(t==null?void 0:t.limit)??10,offset:(t==null?void 0:t.offset)??0,query:t==null?void 0:t.query,refresh_ttl:t==null?void 0:t.refreshTtl};return{items:(await this.fetch("/store/items/search",{method:"POST",json:Ye})).items.map(rt=>({...rt,createdAt:rt.created_at,updatedAt:rt.updated_at}))}}async listNamespaces(e){const t={prefix:e==null?void 0:e.prefix,suffix:e==null?void 0:e.suffix,max_depth:e==null?void 0:e.maxDepth,limit:(e==null?void 0:e.limit)??100,offset:(e==null?void 0:e.offset)??0};return this.fetch("/store/namespaces",{method:"POST",json:t})}},fi,UiClient=(fi=class extends BaseClient{static getOrCached(t,Ye){if(fi.promiseCache[t]!=null)return fi.promiseCache[t];const tt=Ye();return fi.promiseCache[t]=tt,tt}async getComponent(t,Ye){return fi.getOrCached(`${this.apiUrl}-${t}-${Ye}`,async()=>{let[tt,rt]=this.prepareFetchOptions(`/ui/${t}`,{headers:{Accept:"text/html","Content-Type":"application/json"},method:"POST",json:{name:Ye}});return this.onRequest!=null&&(rt=await this.onRequest(tt,rt)),(await this.asyncCaller.fetch(tt,rt)).text()})}},Cr(fi,"promiseCache",{}),fi),Client=class{constructor(e){Cr(this,"assistants");Cr(this,"threads");Cr(this,"runs");Cr(this,"crons");Cr(this,"store");Cr(this,"~ui");Cr(this,"~configHash");this["~configHash"]=(()=>{var t,Ye,tt,rt;return JSON.stringify({apiUrl:e==null?void 0:e.apiUrl,apiKey:e==null?void 0:e.apiKey,timeoutMs:e==null?void 0:e.timeoutMs,defaultHeaders:e==null?void 0:e.defaultHeaders,maxConcurrency:(t=e==null?void 0:e.callerOptions)==null?void 0:t.maxConcurrency,maxRetries:(Ye=e==null?void 0:e.callerOptions)==null?void 0:Ye.maxRetries,callbacks:{onFailedResponseHook:((tt=e==null?void 0:e.callerOptions)==null?void 0:tt.onFailedResponseHook)!=null,onRequest:(e==null?void 0:e.onRequest)!=null,fetch:((rt=e==null?void 0:e.callerOptions)==null?void 0:rt.fetch)!=null}})})(),this.assistants=new AssistantsClient(e),this.threads=new ThreadsClient(e),this.runs=new RunsClient(e),this.crons=new CronsClient(e),this.store=new StoreClient(e),this["~ui"]=new UiClient(e)}};const createLangGraphServerClient=async e=>new Client(e);function $constructor(e,t,Ye){function tt(it,ot){var ct;Object.defineProperty(it,"_zod",{value:it._zod??{},enumerable:!1}),(ct=it._zod).traits??(ct.traits=new Set),it._zod.traits.add(e),t(it,ot);for(const At in at.prototype)At in it||Object.defineProperty(it,At,{value:at.prototype[At].bind(it)});it._zod.constr=at,it._zod.def=ot}const rt=(Ye==null?void 0:Ye.Parent)??Object;class nt extends rt{}Object.defineProperty(nt,"name",{value:e});function at(it){var ot;const ct=Ye!=null&&Ye.Parent?new nt:this;tt(ct,it),(ot=ct._zod).deferred??(ot.deferred=[]);for(const At of ct._zod.deferred)At();return ct}return Object.defineProperty(at,"init",{value:tt}),Object.defineProperty(at,Symbol.hasInstance,{value:it=>{var ot,ct;return Ye!=null&&Ye.Parent&&it instanceof Ye.Parent?!0:(ct=(ot=it==null?void 0:it._zod)==null?void 0:ot.traits)==null?void 0:ct.has(e)}}),Object.defineProperty(at,"name",{value:e}),at}class $ZodAsyncError extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}}class $ZodEncodeError extends Error{constructor(t){super(`Encountered unidirectional transform during encode: ${t}`),this.name="ZodEncodeError"}}const globalConfig={};function config(e){return globalConfig}function getEnumValues(e){const t=Object.values(e).filter(tt=>typeof tt=="number");return Object.entries(e).filter(([tt,rt])=>t.indexOf(+tt)===-1).map(([tt,rt])=>rt)}function jsonStringifyReplacer(e,t){return typeof t=="bigint"?t.toString():t}function cached(e){return{get value(){{const t=e();return Object.defineProperty(this,"value",{value:t}),t}}}}function nullish(e){return e==null}function cleanRegex(e){const t=e.startsWith("^")?1:0,Ye=e.endsWith("$")?e.length-1:e.length;return e.slice(t,Ye)}const EVALUATING=Symbol("evaluating");function defineLazy(e,t,Ye){let tt;Object.defineProperty(e,t,{get(){if(tt!==EVALUATING)return tt===void 0&&(tt=EVALUATING,tt=Ye()),tt},set(rt){Object.defineProperty(e,t,{value:rt})},configurable:!0})}function assignProp$1(e,t,Ye){Object.defineProperty(e,t,{value:Ye,writable:!0,enumerable:!0,configurable:!0})}function mergeDefs(...e){const t={};for(const Ye of e){const tt=Object.getOwnPropertyDescriptors(Ye);Object.assign(t,tt)}return Object.defineProperties({},t)}function esc(e){return JSON.stringify(e)}const captureStackTrace="captureStackTrace"in Error?Error.captureStackTrace:(...e)=>{};function isObject$5(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}const allowsEval=cached(()=>{var e;if(typeof navigator<"u"&&((e=navigator==null?void 0:navigator.userAgent)!=null&&e.includes("Cloudflare")))return!1;try{const t=Function;return new t(""),!0}catch{return!1}});function isPlainObject$2(e){if(isObject$5(e)===!1)return!1;const t=e.constructor;if(t===void 0)return!0;const Ye=t.prototype;return!(isObject$5(Ye)===!1||Object.prototype.hasOwnProperty.call(Ye,"isPrototypeOf")===!1)}function shallowClone(e){return isPlainObject$2(e)?{...e}:Array.isArray(e)?[...e]:e}const propertyKeyTypes=new Set(["string","number","symbol"]);function escapeRegex(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function clone$1(e,t,Ye){const tt=new e._zod.constr(t??e._zod.def);return(!t||Ye!=null&&Ye.parent)&&(tt._zod.parent=e),tt}function normalizeParams(e){const t=e;if(!t)return{};if(typeof t=="string")return{error:()=>t};if((t==null?void 0:t.message)!==void 0){if((t==null?void 0:t.error)!==void 0)throw new Error("Cannot specify both `message` and `error` params");t.error=t.message}return delete t.message,typeof t.error=="string"?{...t,error:()=>t.error}:t}function optionalKeys(e){return Object.keys(e).filter(t=>e[t]._zod.optin==="optional"&&e[t]._zod.optout==="optional")}function pick$1(e,t){const Ye=e._zod.def,tt=mergeDefs(e._zod.def,{get shape(){const rt={};for(const nt in t){if(!(nt in Ye.shape))throw new Error(`Unrecognized key: "${nt}"`);t[nt]&&(rt[nt]=Ye.shape[nt])}return assignProp$1(this,"shape",rt),rt},checks:[]});return clone$1(e,tt)}function omit$1(e,t){const Ye=e._zod.def,tt=mergeDefs(e._zod.def,{get shape(){const rt={...e._zod.def.shape};for(const nt in t){if(!(nt in Ye.shape))throw new Error(`Unrecognized key: "${nt}"`);t[nt]&&delete rt[nt]}return assignProp$1(this,"shape",rt),rt},checks:[]});return clone$1(e,tt)}function extend$3(e,t){if(!isPlainObject$2(t))throw new Error("Invalid input to extend: expected a plain object");const Ye=e._zod.def.checks;if(Ye&&Ye.length>0)throw new Error("Object schemas containing refinements cannot be extended. Use `.safeExtend()` instead.");const rt=mergeDefs(e._zod.def,{get shape(){const nt={...e._zod.def.shape,...t};return assignProp$1(this,"shape",nt),nt},checks:[]});return clone$1(e,rt)}function safeExtend(e,t){if(!isPlainObject$2(t))throw new Error("Invalid input to safeExtend: expected a plain object");const Ye={...e._zod.def,get shape(){const tt={...e._zod.def.shape,...t};return assignProp$1(this,"shape",tt),tt},checks:e._zod.def.checks};return clone$1(e,Ye)}function merge$3(e,t){const Ye=mergeDefs(e._zod.def,{get shape(){const tt={...e._zod.def.shape,...t._zod.def.shape};return assignProp$1(this,"shape",tt),tt},get catchall(){return t._zod.def.catchall},checks:[]});return clone$1(e,Ye)}function partial(e,t,Ye){const tt=mergeDefs(t._zod.def,{get shape(){const rt=t._zod.def.shape,nt={...rt};if(Ye)for(const at in Ye){if(!(at in rt))throw new Error(`Unrecognized key: "${at}"`);Ye[at]&&(nt[at]=e?new e({type:"optional",innerType:rt[at]}):rt[at])}else for(const at in rt)nt[at]=e?new e({type:"optional",innerType:rt[at]}):rt[at];return assignProp$1(this,"shape",nt),nt},checks:[]});return clone$1(t,tt)}function required$2(e,t,Ye){const tt=mergeDefs(t._zod.def,{get shape(){const rt=t._zod.def.shape,nt={...rt};if(Ye)for(const at in Ye){if(!(at in nt))throw new Error(`Unrecognized key: "${at}"`);Ye[at]&&(nt[at]=new e({type:"nonoptional",innerType:rt[at]}))}else for(const at in rt)nt[at]=new e({type:"nonoptional",innerType:rt[at]});return assignProp$1(this,"shape",nt),nt},checks:[]});return clone$1(t,tt)}function aborted(e,t=0){var Ye;if(e.aborted===!0)return!0;for(let tt=t;tt<e.issues.length;tt++)if(((Ye=e.issues[tt])==null?void 0:Ye.continue)!==!0)return!0;return!1}function prefixIssues(e,t){return t.map(Ye=>{var tt;return(tt=Ye).path??(tt.path=[]),Ye.path.unshift(e),Ye})}function unwrapMessage(e){return typeof e=="string"?e:e==null?void 0:e.message}function finalizeIssue(e,t,Ye){var rt,nt,at,it,ot,ct;const tt={...e,path:e.path??[]};if(!e.message){const At=unwrapMessage((at=(nt=(rt=e.inst)==null?void 0:rt._zod.def)==null?void 0:nt.error)==null?void 0:at.call(nt,e))??unwrapMessage((it=t==null?void 0:t.error)==null?void 0:it.call(t,e))??unwrapMessage((ot=Ye.customError)==null?void 0:ot.call(Ye,e))??unwrapMessage((ct=Ye.localeError)==null?void 0:ct.call(Ye,e))??"Invalid input";tt.message=At}return delete tt.inst,delete tt.continue,t!=null&&t.reportInput||delete tt.input,tt}function getLengthableOrigin(e){return Array.isArray(e)?"array":typeof e=="string"?"string":"unknown"}function issue(...e){const[t,Ye,tt]=e;return typeof t=="string"?{message:t,code:"custom",input:Ye,inst:tt}:{...t}}const initializer$1=(e,t)=>{e.name="$ZodError",Object.defineProperty(e,"_zod",{value:e._zod,enumerable:!1}),Object.defineProperty(e,"issues",{value:t,enumerable:!1}),e.message=JSON.stringify(t,jsonStringifyReplacer,2),Object.defineProperty(e,"toString",{value:()=>e.message,enumerable:!1})},$ZodError=$constructor("$ZodError",initializer$1),$ZodRealError=$constructor("$ZodError",initializer$1,{Parent:Error});function flattenError(e,t=Ye=>Ye.message){const Ye={},tt=[];for(const rt of e.issues)rt.path.length>0?(Ye[rt.path[0]]=Ye[rt.path[0]]||[],Ye[rt.path[0]].push(t(rt))):tt.push(t(rt));return{formErrors:tt,fieldErrors:Ye}}function formatError(e,t=Ye=>Ye.message){const Ye={_errors:[]},tt=rt=>{for(const nt of rt.issues)if(nt.code==="invalid_union"&&nt.errors.length)nt.errors.map(at=>tt({issues:at}));else if(nt.code==="invalid_key")tt({issues:nt.issues});else if(nt.code==="invalid_element")tt({issues:nt.issues});else if(nt.path.length===0)Ye._errors.push(t(nt));else{let at=Ye,it=0;for(;it<nt.path.length;){const ot=nt.path[it];it===nt.path.length-1?(at[ot]=at[ot]||{_errors:[]},at[ot]._errors.push(t(nt))):at[ot]=at[ot]||{_errors:[]},at=at[ot],it++}}};return tt(e),Ye}const _parse=e=>(t,Ye,tt,rt)=>{const nt=tt?Object.assign(tt,{async:!1}):{async:!1},at=t._zod.run({value:Ye,issues:[]},nt);if(at instanceof Promise)throw new $ZodAsyncError;if(at.issues.length){const it=new((rt==null?void 0:rt.Err)??e)(at.issues.map(ot=>finalizeIssue(ot,nt,config())));throw captureStackTrace(it,rt==null?void 0:rt.callee),it}return at.value},_parseAsync=e=>async(t,Ye,tt,rt)=>{const nt=tt?Object.assign(tt,{async:!0}):{async:!0};let at=t._zod.run({value:Ye,issues:[]},nt);if(at instanceof Promise&&(at=await at),at.issues.length){const it=new((rt==null?void 0:rt.Err)??e)(at.issues.map(ot=>finalizeIssue(ot,nt,config())));throw captureStackTrace(it,rt==null?void 0:rt.callee),it}return at.value},_safeParse=e=>(t,Ye,tt)=>{const rt=tt?{...tt,async:!1}:{async:!1},nt=t._zod.run({value:Ye,issues:[]},rt);if(nt instanceof Promise)throw new $ZodAsyncError;return nt.issues.length?{success:!1,error:new(e??$ZodError)(nt.issues.map(at=>finalizeIssue(at,rt,config())))}:{success:!0,data:nt.value}},safeParse$1=_safeParse($ZodRealError),_safeParseAsync=e=>async(t,Ye,tt)=>{const rt=tt?Object.assign(tt,{async:!0}):{async:!0};let nt=t._zod.run({value:Ye,issues:[]},rt);return nt instanceof Promise&&(nt=await nt),nt.issues.length?{success:!1,error:new e(nt.issues.map(at=>finalizeIssue(at,rt,config())))}:{success:!0,data:nt.value}},safeParseAsync$1=_safeParseAsync($ZodRealError),_encode=e=>(t,Ye,tt)=>{const rt=tt?Object.assign(tt,{direction:"backward"}):{direction:"backward"};return _parse(e)(t,Ye,rt)},_decode=e=>(t,Ye,tt)=>_parse(e)(t,Ye,tt),_encodeAsync=e=>async(t,Ye,tt)=>{const rt=tt?Object.assign(tt,{direction:"backward"}):{direction:"backward"};return _parseAsync(e)(t,Ye,rt)},_decodeAsync=e=>async(t,Ye,tt)=>_parseAsync(e)(t,Ye,tt),_safeEncode=e=>(t,Ye,tt)=>{const rt=tt?Object.assign(tt,{direction:"backward"}):{direction:"backward"};return _safeParse(e)(t,Ye,rt)},_safeDecode=e=>(t,Ye,tt)=>_safeParse(e)(t,Ye,tt),_safeEncodeAsync=e=>async(t,Ye,tt)=>{const rt=tt?Object.assign(tt,{direction:"backward"}):{direction:"backward"};return _safeParseAsync(e)(t,Ye,rt)},_safeDecodeAsync=e=>async(t,Ye,tt)=>_safeParseAsync(e)(t,Ye,tt),cuid=/^[cC][^\s-]{8,}$/,cuid2=/^[0-9a-z]+$/,ulid=/^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/,xid=/^[0-9a-vA-V]{20}$/,ksuid=/^[A-Za-z0-9]{27}$/,nanoid=/^[a-zA-Z0-9_-]{21}$/,duration$1=/^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/,guid=/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$/,uuid=e=>e?new RegExp(`^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-${e}[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$`):/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$/,email=/^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/,_emoji$1="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";function emoji(){return new RegExp(_emoji$1,"u")}const ipv4=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,ipv6=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:))$/,cidrv4=/^((25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/([0-9]|[1-2][0-9]|3[0-2])$/,cidrv6=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|::|([0-9a-fA-F]{1,4})?::([0-9a-fA-F]{1,4}:?){0,6})\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,base64=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,base64url=/^[A-Za-z0-9_-]*$/,hostname=/^(?=.{1,253}\.?$)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[-0-9a-zA-Z]{0,61}[0-9a-zA-Z])?)*\.?$/,e164=/^\+(?:[0-9]){6,14}[0-9]$/,dateSource="(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))",date$1=new RegExp(`^${dateSource}$`);function timeSource(e){const t="(?:[01]\\d|2[0-3]):[0-5]\\d";return typeof e.precision=="number"?e.precision===-1?`${t}`:e.precision===0?`${t}:[0-5]\\d`:`${t}:[0-5]\\d\\.\\d{${e.precision}}`:`${t}(?::[0-5]\\d(?:\\.\\d+)?)?`}function time$1(e){return new RegExp(`^${timeSource(e)}$`)}function datetime$1(e){const t=timeSource({precision:e.precision}),Ye=["Z"];e.local&&Ye.push(""),e.offset&&Ye.push("([+-](?:[01]\\d|2[0-3]):[0-5]\\d)");const tt=`${t}(?:${Ye.join("|")})`;return new RegExp(`^${dateSource}T(?:${tt})$`)}const string$3=e=>{const t=e?`[\\s\\S]{${(e==null?void 0:e.minimum)??0},${(e==null?void 0:e.maximum)??""}}`:"[\\s\\S]*";return new RegExp(`^${t}$`)},lowercase=/^[^A-Z]*$/,uppercase$1=/^[^a-z]*$/,$ZodCheck=$constructor("$ZodCheck",(e,t)=>{var Ye;e._zod??(e._zod={}),e._zod.def=t,(Ye=e._zod).onattach??(Ye.onattach=[])}),$ZodCheckMaxLength=$constructor("$ZodCheckMaxLength",(e,t)=>{var Ye;$ZodCheck.init(e,t),(Ye=e._zod.def).when??(Ye.when=tt=>{const rt=tt.value;return!nullish(rt)&&rt.length!==void 0}),e._zod.onattach.push(tt=>{const rt=tt._zod.bag.maximum??Number.POSITIVE_INFINITY;t.maximum<rt&&(tt._zod.bag.maximum=t.maximum)}),e._zod.check=tt=>{const rt=tt.value;if(rt.length<=t.maximum)return;const at=getLengthableOrigin(rt);tt.issues.push({origin:at,code:"too_big",maximum:t.maximum,inclusive:!0,input:rt,inst:e,continue:!t.abort})}}),$ZodCheckMinLength=$constructor("$ZodCheckMinLength",(e,t)=>{var Ye;$ZodCheck.init(e,t),(Ye=e._zod.def).when??(Ye.when=tt=>{const rt=tt.value;return!nullish(rt)&&rt.length!==void 0}),e._zod.onattach.push(tt=>{const rt=tt._zod.bag.minimum??Number.NEGATIVE_INFINITY;t.minimum>rt&&(tt._zod.bag.minimum=t.minimum)}),e._zod.check=tt=>{const rt=tt.value;if(rt.length>=t.minimum)return;const at=getLengthableOrigin(rt);tt.issues.push({origin:at,code:"too_small",minimum:t.minimum,inclusive:!0,input:rt,inst:e,continue:!t.abort})}}),$ZodCheckLengthEquals=$constructor("$ZodCheckLengthEquals",(e,t)=>{var Ye;$ZodCheck.init(e,t),(Ye=e._zod.def).when??(Ye.when=tt=>{const rt=tt.value;return!nullish(rt)&&rt.length!==void 0}),e._zod.onattach.push(tt=>{const rt=tt._zod.bag;rt.minimum=t.length,rt.maximum=t.length,rt.length=t.length}),e._zod.check=tt=>{const rt=tt.value,nt=rt.length;if(nt===t.length)return;const at=getLengthableOrigin(rt),it=nt>t.length;tt.issues.push({origin:at,...it?{code:"too_big",maximum:t.length}:{code:"too_small",minimum:t.length},inclusive:!0,exact:!0,input:tt.value,inst:e,continue:!t.abort})}}),$ZodCheckStringFormat=$constructor("$ZodCheckStringFormat",(e,t)=>{var Ye,tt;$ZodCheck.init(e,t),e._zod.onattach.push(rt=>{const nt=rt._zod.bag;nt.format=t.format,t.pattern&&(nt.patterns??(nt.patterns=new Set),nt.patterns.add(t.pattern))}),t.pattern?(Ye=e._zod).check??(Ye.check=rt=>{t.pattern.lastIndex=0,!t.pattern.test(rt.value)&&rt.issues.push({origin:"string",code:"invalid_format",format:t.format,input:rt.value,...t.pattern?{pattern:t.pattern.toString()}:{},inst:e,continue:!t.abort})}):(tt=e._zod).check??(tt.check=()=>{})}),$ZodCheckRegex=$constructor("$ZodCheckRegex",(e,t)=>{$ZodCheckStringFormat.init(e,t),e._zod.check=Ye=>{t.pattern.lastIndex=0,!t.pattern.test(Ye.value)&&Ye.issues.push({origin:"string",code:"invalid_format",format:"regex",input:Ye.value,pattern:t.pattern.toString(),inst:e,continue:!t.abort})}}),$ZodCheckLowerCase=$constructor("$ZodCheckLowerCase",(e,t)=>{t.pattern??(t.pattern=lowercase),$ZodCheckStringFormat.init(e,t)}),$ZodCheckUpperCase=$constructor("$ZodCheckUpperCase",(e,t)=>{t.pattern??(t.pattern=uppercase$1),$ZodCheckStringFormat.init(e,t)}),$ZodCheckIncludes=$constructor("$ZodCheckIncludes",(e,t)=>{$ZodCheck.init(e,t);const Ye=escapeRegex(t.includes),tt=new RegExp(typeof t.position=="number"?`^.{${t.position}}${Ye}`:Ye);t.pattern=tt,e._zod.onattach.push(rt=>{const nt=rt._zod.bag;nt.patterns??(nt.patterns=new Set),nt.patterns.add(tt)}),e._zod.check=rt=>{rt.value.includes(t.includes,t.position)||rt.issues.push({origin:"string",code:"invalid_format",format:"includes",includes:t.includes,input:rt.value,inst:e,continue:!t.abort})}}),$ZodCheckStartsWith=$constructor("$ZodCheckStartsWith",(e,t)=>{$ZodCheck.init(e,t);const Ye=new RegExp(`^${escapeRegex(t.prefix)}.*`);t.pattern??(t.pattern=Ye),e._zod.onattach.push(tt=>{const rt=tt._zod.bag;rt.patterns??(rt.patterns=new Set),rt.patterns.add(Ye)}),e._zod.check=tt=>{tt.value.startsWith(t.prefix)||tt.issues.push({origin:"string",code:"invalid_format",format:"starts_with",prefix:t.prefix,input:tt.value,inst:e,continue:!t.abort})}}),$ZodCheckEndsWith=$constructor("$ZodCheckEndsWith",(e,t)=>{$ZodCheck.init(e,t);const Ye=new RegExp(`.*${escapeRegex(t.suffix)}$`);t.pattern??(t.pattern=Ye),e._zod.onattach.push(tt=>{const rt=tt._zod.bag;rt.patterns??(rt.patterns=new Set),rt.patterns.add(Ye)}),e._zod.check=tt=>{tt.value.endsWith(t.suffix)||tt.issues.push({origin:"string",code:"invalid_format",format:"ends_with",suffix:t.suffix,input:tt.value,inst:e,continue:!t.abort})}}),$ZodCheckOverwrite=$constructor("$ZodCheckOverwrite",(e,t)=>{$ZodCheck.init(e,t),e._zod.check=Ye=>{Ye.value=t.tx(Ye.value)}});class Doc{constructor(t=[]){this.content=[],this.indent=0,this&&(this.args=t)}indented(t){this.indent+=1,t(this),this.indent-=1}write(t){if(typeof t=="function"){t(this,{execution:"sync"}),t(this,{execution:"async"});return}const tt=t.split(`
58
58
  `).filter(at=>at),rt=Math.min(...tt.map(at=>at.length-at.trimStart().length)),nt=tt.map(at=>at.slice(rt)).map(at=>" ".repeat(this.indent*2)+at);for(const at of nt)this.content.push(at)}compile(){const t=Function,Ye=this==null?void 0:this.args,rt=[...((this==null?void 0:this.content)??[""]).map(nt=>` ${nt}`)];return new t(...Ye,rt.join(`
59
59
  `))}}const version$3={major:4,minor:1,patch:12},$ZodType=$constructor("$ZodType",(e,t)=>{var rt;var Ye;e??(e={}),e._zod.def=t,e._zod.bag=e._zod.bag||{},e._zod.version=version$3;const tt=[...e._zod.def.checks??[]];e._zod.traits.has("$ZodCheck")&&tt.unshift(e);for(const nt of tt)for(const at of nt._zod.onattach)at(e);if(tt.length===0)(Ye=e._zod).deferred??(Ye.deferred=[]),(rt=e._zod.deferred)==null||rt.push(()=>{e._zod.run=e._zod.parse});else{const nt=(it,ot,ct)=>{let At=aborted(it),Rt;for(const qt of ot){if(qt._zod.def.when){if(!qt._zod.def.when(it))continue}else if(At)continue;const Ft=it.issues.length,Ut=qt._zod.check(it);if(Ut instanceof Promise&&(ct==null?void 0:ct.async)===!1)throw new $ZodAsyncError;if(Rt||Ut instanceof Promise)Rt=(Rt??Promise.resolve()).then(async()=>{await Ut,it.issues.length!==Ft&&(At||(At=aborted(it,Ft)))});else{if(it.issues.length===Ft)continue;At||(At=aborted(it,Ft))}}return Rt?Rt.then(()=>it):it},at=(it,ot,ct)=>{if(aborted(it))return it.aborted=!0,it;const At=nt(ot,tt,ct);if(At instanceof Promise){if(ct.async===!1)throw new $ZodAsyncError;return At.then(Rt=>e._zod.parse(Rt,ct))}return e._zod.parse(At,ct)};e._zod.run=(it,ot)=>{if(ot.skipChecks)return e._zod.parse(it,ot);if(ot.direction==="backward"){const At=e._zod.parse({value:it.value,issues:[]},{...ot,skipChecks:!0});return At instanceof Promise?At.then(Rt=>at(Rt,it,ot)):at(At,it,ot)}const ct=e._zod.parse(it,ot);if(ct instanceof Promise){if(ot.async===!1)throw new $ZodAsyncError;return ct.then(At=>nt(At,tt,ot))}return nt(ct,tt,ot)}}e["~standard"]={validate:nt=>{var at;try{const it=safeParse$1(e,nt);return it.success?{value:it.data}:{issues:(at=it.error)==null?void 0:at.issues}}catch{return safeParseAsync$1(e,nt).then(ot=>{var ct;return ot.success?{value:ot.data}:{issues:(ct=ot.error)==null?void 0:ct.issues}})}},vendor:"zod",version:1}}),$ZodString=$constructor("$ZodString",(e,t)=>{var Ye;$ZodType.init(e,t),e._zod.pattern=[...((Ye=e==null?void 0:e._zod.bag)==null?void 0:Ye.patterns)??[]].pop()??string$3(e._zod.bag),e._zod.parse=(tt,rt)=>{if(t.coerce)try{tt.value=String(tt.value)}catch{}return typeof tt.value=="string"||tt.issues.push({expected:"string",code:"invalid_type",input:tt.value,inst:e}),tt}}),$ZodStringFormat=$constructor("$ZodStringFormat",(e,t)=>{$ZodCheckStringFormat.init(e,t),$ZodString.init(e,t)}),$ZodGUID=$constructor("$ZodGUID",(e,t)=>{t.pattern??(t.pattern=guid),$ZodStringFormat.init(e,t)}),$ZodUUID=$constructor("$ZodUUID",(e,t)=>{if(t.version){const tt={v1:1,v2:2,v3:3,v4:4,v5:5,v6:6,v7:7,v8:8}[t.version];if(tt===void 0)throw new Error(`Invalid UUID version: "${t.version}"`);t.pattern??(t.pattern=uuid(tt))}else t.pattern??(t.pattern=uuid());$ZodStringFormat.init(e,t)}),$ZodEmail=$constructor("$ZodEmail",(e,t)=>{t.pattern??(t.pattern=email),$ZodStringFormat.init(e,t)}),$ZodURL=$constructor("$ZodURL",(e,t)=>{$ZodStringFormat.init(e,t),e._zod.check=Ye=>{try{const tt=Ye.value.trim(),rt=new URL(tt);t.hostname&&(t.hostname.lastIndex=0,t.hostname.test(rt.hostname)||Ye.issues.push({code:"invalid_format",format:"url",note:"Invalid hostname",pattern:hostname.source,input:Ye.value,inst:e,continue:!t.abort})),t.protocol&&(t.protocol.lastIndex=0,t.protocol.test(rt.protocol.endsWith(":")?rt.protocol.slice(0,-1):rt.protocol)||Ye.issues.push({code:"invalid_format",format:"url",note:"Invalid protocol",pattern:t.protocol.source,input:Ye.value,inst:e,continue:!t.abort})),t.normalize?Ye.value=rt.href:Ye.value=tt;return}catch{Ye.issues.push({code:"invalid_format",format:"url",input:Ye.value,inst:e,continue:!t.abort})}}}),$ZodEmoji=$constructor("$ZodEmoji",(e,t)=>{t.pattern??(t.pattern=emoji()),$ZodStringFormat.init(e,t)}),$ZodNanoID=$constructor("$ZodNanoID",(e,t)=>{t.pattern??(t.pattern=nanoid),$ZodStringFormat.init(e,t)}),$ZodCUID=$constructor("$ZodCUID",(e,t)=>{t.pattern??(t.pattern=cuid),$ZodStringFormat.init(e,t)}),$ZodCUID2=$constructor("$ZodCUID2",(e,t)=>{t.pattern??(t.pattern=cuid2),$ZodStringFormat.init(e,t)}),$ZodULID=$constructor("$ZodULID",(e,t)=>{t.pattern??(t.pattern=ulid),$ZodStringFormat.init(e,t)}),$ZodXID=$constructor("$ZodXID",(e,t)=>{t.pattern??(t.pattern=xid),$ZodStringFormat.init(e,t)}),$ZodKSUID=$constructor("$ZodKSUID",(e,t)=>{t.pattern??(t.pattern=ksuid),$ZodStringFormat.init(e,t)}),$ZodISODateTime=$constructor("$ZodISODateTime",(e,t)=>{t.pattern??(t.pattern=datetime$1(t)),$ZodStringFormat.init(e,t)}),$ZodISODate=$constructor("$ZodISODate",(e,t)=>{t.pattern??(t.pattern=date$1),$ZodStringFormat.init(e,t)}),$ZodISOTime=$constructor("$ZodISOTime",(e,t)=>{t.pattern??(t.pattern=time$1(t)),$ZodStringFormat.init(e,t)}),$ZodISODuration=$constructor("$ZodISODuration",(e,t)=>{t.pattern??(t.pattern=duration$1),$ZodStringFormat.init(e,t)}),$ZodIPv4=$constructor("$ZodIPv4",(e,t)=>{t.pattern??(t.pattern=ipv4),$ZodStringFormat.init(e,t),e._zod.onattach.push(Ye=>{const tt=Ye._zod.bag;tt.format="ipv4"})}),$ZodIPv6=$constructor("$ZodIPv6",(e,t)=>{t.pattern??(t.pattern=ipv6),$ZodStringFormat.init(e,t),e._zod.onattach.push(Ye=>{const tt=Ye._zod.bag;tt.format="ipv6"}),e._zod.check=Ye=>{try{new URL(`http://[${Ye.value}]`)}catch{Ye.issues.push({code:"invalid_format",format:"ipv6",input:Ye.value,inst:e,continue:!t.abort})}}}),$ZodCIDRv4=$constructor("$ZodCIDRv4",(e,t)=>{t.pattern??(t.pattern=cidrv4),$ZodStringFormat.init(e,t)}),$ZodCIDRv6=$constructor("$ZodCIDRv6",(e,t)=>{t.pattern??(t.pattern=cidrv6),$ZodStringFormat.init(e,t),e._zod.check=Ye=>{const tt=Ye.value.split("/");try{if(tt.length!==2)throw new Error;const[rt,nt]=tt;if(!nt)throw new Error;const at=Number(nt);if(`${at}`!==nt)throw new Error;if(at<0||at>128)throw new Error;new URL(`http://[${rt}]`)}catch{Ye.issues.push({code:"invalid_format",format:"cidrv6",input:Ye.value,inst:e,continue:!t.abort})}}});function isValidBase64(e){if(e==="")return!0;if(e.length%4!==0)return!1;try{return atob(e),!0}catch{return!1}}const $ZodBase64=$constructor("$ZodBase64",(e,t)=>{t.pattern??(t.pattern=base64),$ZodStringFormat.init(e,t),e._zod.onattach.push(Ye=>{Ye._zod.bag.contentEncoding="base64"}),e._zod.check=Ye=>{isValidBase64(Ye.value)||Ye.issues.push({code:"invalid_format",format:"base64",input:Ye.value,inst:e,continue:!t.abort})}});function isValidBase64URL(e){if(!base64url.test(e))return!1;const t=e.replace(/[-_]/g,tt=>tt==="-"?"+":"/"),Ye=t.padEnd(Math.ceil(t.length/4)*4,"=");return isValidBase64(Ye)}const $ZodBase64URL=$constructor("$ZodBase64URL",(e,t)=>{t.pattern??(t.pattern=base64url),$ZodStringFormat.init(e,t),e._zod.onattach.push(Ye=>{Ye._zod.bag.contentEncoding="base64url"}),e._zod.check=Ye=>{isValidBase64URL(Ye.value)||Ye.issues.push({code:"invalid_format",format:"base64url",input:Ye.value,inst:e,continue:!t.abort})}}),$ZodE164=$constructor("$ZodE164",(e,t)=>{t.pattern??(t.pattern=e164),$ZodStringFormat.init(e,t)});function isValidJWT(e,t=null){try{const Ye=e.split(".");if(Ye.length!==3)return!1;const[tt]=Ye;if(!tt)return!1;const rt=JSON.parse(atob(tt));return!("typ"in rt&&(rt==null?void 0:rt.typ)!=="JWT"||!rt.alg||t&&(!("alg"in rt)||rt.alg!==t))}catch{return!1}}const $ZodJWT=$constructor("$ZodJWT",(e,t)=>{$ZodStringFormat.init(e,t),e._zod.check=Ye=>{isValidJWT(Ye.value,t.alg)||Ye.issues.push({code:"invalid_format",format:"jwt",input:Ye.value,inst:e,continue:!t.abort})}}),$ZodAny=$constructor("$ZodAny",(e,t)=>{$ZodType.init(e,t),e._zod.parse=Ye=>Ye}),$ZodUnknown=$constructor("$ZodUnknown",(e,t)=>{$ZodType.init(e,t),e._zod.parse=Ye=>Ye}),$ZodNever=$constructor("$ZodNever",(e,t)=>{$ZodType.init(e,t),e._zod.parse=(Ye,tt)=>(Ye.issues.push({expected:"never",code:"invalid_type",input:Ye.value,inst:e}),Ye)});function handleArrayResult(e,t,Ye){e.issues.length&&t.issues.push(...prefixIssues(Ye,e.issues)),t.value[Ye]=e.value}const $ZodArray=$constructor("$ZodArray",(e,t)=>{$ZodType.init(e,t),e._zod.parse=(Ye,tt)=>{const rt=Ye.value;if(!Array.isArray(rt))return Ye.issues.push({expected:"array",code:"invalid_type",input:rt,inst:e}),Ye;Ye.value=Array(rt.length);const nt=[];for(let at=0;at<rt.length;at++){const it=rt[at],ot=t.element._zod.run({value:it,issues:[]},tt);ot instanceof Promise?nt.push(ot.then(ct=>handleArrayResult(ct,Ye,at))):handleArrayResult(ot,Ye,at)}return nt.length?Promise.all(nt).then(()=>Ye):Ye}});function handlePropertyResult(e,t,Ye,tt){e.issues.length&&t.issues.push(...prefixIssues(Ye,e.issues)),e.value===void 0?Ye in tt&&(t.value[Ye]=void 0):t.value[Ye]=e.value}function normalizeDef(e){var tt,rt,nt,at;const t=Object.keys(e.shape);for(const it of t)if(!((at=(nt=(rt=(tt=e.shape)==null?void 0:tt[it])==null?void 0:rt._zod)==null?void 0:nt.traits)!=null&&at.has("$ZodType")))throw new Error(`Invalid element at key "${it}": expected a Zod schema`);const Ye=optionalKeys(e.shape);return{...e,keys:t,keySet:new Set(t),numKeys:t.length,optionalKeys:new Set(Ye)}}function handleCatchall(e,t,Ye,tt,rt,nt){const at=[],it=rt.keySet,ot=rt.catchall._zod,ct=ot.def.type;for(const At of Object.keys(t)){if(it.has(At))continue;if(ct==="never"){at.push(At);continue}const Rt=ot.run({value:t[At],issues:[]},tt);Rt instanceof Promise?e.push(Rt.then(qt=>handlePropertyResult(qt,Ye,At,t))):handlePropertyResult(Rt,Ye,At,t)}return at.length&&Ye.issues.push({code:"unrecognized_keys",keys:at,input:t,inst:nt}),e.length?Promise.all(e).then(()=>Ye):Ye}const $ZodObject=$constructor("$ZodObject",(e,t)=>{$ZodType.init(e,t);const Ye=Object.getOwnPropertyDescriptor(t,"shape");if(!(Ye!=null&&Ye.get)){const it=t.shape;Object.defineProperty(t,"shape",{get:()=>{const ot={...it};return Object.defineProperty(t,"shape",{value:ot}),ot}})}const tt=cached(()=>normalizeDef(t));defineLazy(e._zod,"propValues",()=>{const it=t.shape,ot={};for(const ct in it){const At=it[ct]._zod;if(At.values){ot[ct]??(ot[ct]=new Set);for(const Rt of At.values)ot[ct].add(Rt)}}return ot});const rt=isObject$5,nt=t.catchall;let at;e._zod.parse=(it,ot)=>{at??(at=tt.value);const ct=it.value;if(!rt(ct))return it.issues.push({expected:"object",code:"invalid_type",input:ct,inst:e}),it;it.value={};const At=[],Rt=at.shape;for(const qt of at.keys){const Ut=Rt[qt]._zod.run({value:ct[qt],issues:[]},ot);Ut instanceof Promise?At.push(Ut.then(Ht=>handlePropertyResult(Ht,it,qt,ct))):handlePropertyResult(Ut,it,qt,ct)}return nt?handleCatchall(At,ct,it,ot,tt.value,e):At.length?Promise.all(At).then(()=>it):it}}),$ZodObjectJIT=$constructor("$ZodObjectJIT",(e,t)=>{$ZodObject.init(e,t);const Ye=e._zod.parse,tt=cached(()=>normalizeDef(t)),rt=qt=>{const Ft=new Doc(["shape","payload","ctx"]),Ut=tt.value,Ht=Vt=>{const Zt=esc(Vt);return`shape[${Zt}]._zod.run({ value: input[${Zt}], issues: [] }, ctx)`};Ft.write("const input = payload.value;");const zt=Object.create(null);let Yt=0;for(const Vt of Ut.keys)zt[Vt]=`key_${Yt++}`;Ft.write("const newResult = {};");for(const Vt of Ut.keys){const Zt=zt[Vt],Xt=esc(Vt);Ft.write(`const ${Zt} = ${Ht(Vt)};`),Ft.write(`
60
60
  if (${Zt}.issues.length) {
@@ -77,7 +77,7 @@ Error generating stack: `+Kt.message+`
77
77
  ]))`;continue}else if(tt[ct]==="$"){rt+=`($|(?=[\r
78
78
  ]))`;continue}}if(Ye.s&&tt[ct]==="."){rt+=at?`${tt[ct]}\r
79
79
  `:`[${tt[ct]}\r
80
- ]`;continue}rt+=tt[ct],tt[ct]==="\\"?nt=!0:at&&tt[ct]==="]"?at=!1:!at&&tt[ct]==="["&&(at=!0)}try{new RegExp(rt)}catch{return console.warn(`Could not convert regex pattern at ${t.currentPath.join("/")} to a flag-independent form! Falling back to the flag-ignorant source`),e.source}return rt}function parseRecordDef(e,t){var tt,rt,nt,at,it,ot;if(t.target==="openAi"&&console.warn("Warning: OpenAI may not support records in schemas! Try an array of key-value pairs instead."),t.target==="openApi3"&&((tt=e.keyType)==null?void 0:tt._def.typeName)===ZodFirstPartyTypeKind.ZodEnum)return{type:"object",required:e.keyType._def.values,properties:e.keyType._def.values.reduce((ct,At)=>({...ct,[At]:parseDef(e.valueType._def,{...t,currentPath:[...t.currentPath,"properties",At]})??parseAnyDef(t)}),{}),additionalProperties:t.rejectedAdditionalProperties};const Ye={type:"object",additionalProperties:parseDef(e.valueType._def,{...t,currentPath:[...t.currentPath,"additionalProperties"]})??t.allowedAdditionalProperties};if(t.target==="openApi3")return Ye;if(((rt=e.keyType)==null?void 0:rt._def.typeName)===ZodFirstPartyTypeKind.ZodString&&((nt=e.keyType._def.checks)!=null&&nt.length)){const{type:ct,...At}=parseStringDef(e.keyType._def,t);return{...Ye,propertyNames:At}}else{if(((at=e.keyType)==null?void 0:at._def.typeName)===ZodFirstPartyTypeKind.ZodEnum)return{...Ye,propertyNames:{enum:e.keyType._def.values}};if(((it=e.keyType)==null?void 0:it._def.typeName)===ZodFirstPartyTypeKind.ZodBranded&&e.keyType._def.type._def.typeName===ZodFirstPartyTypeKind.ZodString&&((ot=e.keyType._def.type._def.checks)!=null&&ot.length)){const{type:ct,...At}=parseBrandedDef(e.keyType._def,t);return{...Ye,propertyNames:At}}}return Ye}function parseMapDef(e,t){if(t.mapStrategy==="record")return parseRecordDef(e,t);const Ye=parseDef(e.keyType._def,{...t,currentPath:[...t.currentPath,"items","items","0"]})||parseAnyDef(t),tt=parseDef(e.valueType._def,{...t,currentPath:[...t.currentPath,"items","items","1"]})||parseAnyDef(t);return{type:"array",maxItems:125,items:{type:"array",items:[Ye,tt],minItems:2,maxItems:2}}}function parseNativeEnumDef(e){const t=e.values,tt=Object.keys(e.values).filter(nt=>typeof t[t[nt]]!="number").map(nt=>t[nt]),rt=Array.from(new Set(tt.map(nt=>typeof nt)));return{type:rt.length===1?rt[0]==="string"?"string":"number":["string","number"],enum:tt}}function parseNeverDef(e){return e.target==="openAi"?void 0:{not:parseAnyDef({...e,currentPath:[...e.currentPath,"not"]})}}function parseNullDef(e){return e.target==="openApi3"?{enum:["null"],nullable:!0}:{type:"null"}}const primitiveMappings={ZodString:"string",ZodNumber:"number",ZodBigInt:"integer",ZodBoolean:"boolean",ZodNull:"null"};function parseUnionDef(e,t){if(t.target==="openApi3")return asAnyOf(e,t);const Ye=e.options instanceof Map?Array.from(e.options.values()):e.options;if(Ye.every(tt=>tt._def.typeName in primitiveMappings&&(!tt._def.checks||!tt._def.checks.length))){const tt=Ye.reduce((rt,nt)=>{const at=primitiveMappings[nt._def.typeName];return at&&!rt.includes(at)?[...rt,at]:rt},[]);return{type:tt.length>1?tt:tt[0]}}else if(Ye.every(tt=>tt._def.typeName==="ZodLiteral"&&!tt.description)){const tt=Ye.reduce((rt,nt)=>{const at=typeof nt._def.value;switch(at){case"string":case"number":case"boolean":return[...rt,at];case"bigint":return[...rt,"integer"];case"object":if(nt._def.value===null)return[...rt,"null"];case"symbol":case"undefined":case"function":default:return rt}},[]);if(tt.length===Ye.length){const rt=tt.filter((nt,at,it)=>it.indexOf(nt)===at);return{type:rt.length>1?rt:rt[0],enum:Ye.reduce((nt,at)=>nt.includes(at._def.value)?nt:[...nt,at._def.value],[])}}}else if(Ye.every(tt=>tt._def.typeName==="ZodEnum"))return{type:"string",enum:Ye.reduce((tt,rt)=>[...tt,...rt._def.values.filter(nt=>!tt.includes(nt))],[])};return asAnyOf(e,t)}const asAnyOf=(e,t)=>{const Ye=(e.options instanceof Map?Array.from(e.options.values()):e.options).map((tt,rt)=>parseDef(tt._def,{...t,currentPath:[...t.currentPath,"anyOf",`${rt}`]})).filter(tt=>!!tt&&(!t.strictUnions||typeof tt=="object"&&Object.keys(tt).length>0));return Ye.length?{anyOf:Ye}:void 0};function parseNullableDef(e,t){if(["ZodString","ZodNumber","ZodBigInt","ZodBoolean","ZodNull"].includes(e.innerType._def.typeName)&&(!e.innerType._def.checks||!e.innerType._def.checks.length))return t.target==="openApi3"?{type:primitiveMappings[e.innerType._def.typeName],nullable:!0}:{type:[primitiveMappings[e.innerType._def.typeName],"null"]};if(t.target==="openApi3"){const tt=parseDef(e.innerType._def,{...t,currentPath:[...t.currentPath]});return tt&&"$ref"in tt?{allOf:[tt],nullable:!0}:tt&&{...tt,nullable:!0}}const Ye=parseDef(e.innerType._def,{...t,currentPath:[...t.currentPath,"anyOf","0"]});return Ye&&{anyOf:[Ye,{type:"null"}]}}function parseNumberDef(e,t){const Ye={type:"number"};if(!e.checks)return Ye;for(const tt of e.checks)switch(tt.kind){case"int":Ye.type="integer",addErrorMessage(Ye,"type",tt.message,t);break;case"min":t.target==="jsonSchema7"?tt.inclusive?setResponseValueAndErrors(Ye,"minimum",tt.value,tt.message,t):setResponseValueAndErrors(Ye,"exclusiveMinimum",tt.value,tt.message,t):(tt.inclusive||(Ye.exclusiveMinimum=!0),setResponseValueAndErrors(Ye,"minimum",tt.value,tt.message,t));break;case"max":t.target==="jsonSchema7"?tt.inclusive?setResponseValueAndErrors(Ye,"maximum",tt.value,tt.message,t):setResponseValueAndErrors(Ye,"exclusiveMaximum",tt.value,tt.message,t):(tt.inclusive||(Ye.exclusiveMaximum=!0),setResponseValueAndErrors(Ye,"maximum",tt.value,tt.message,t));break;case"multipleOf":setResponseValueAndErrors(Ye,"multipleOf",tt.value,tt.message,t);break}return Ye}function parseObjectDef(e,t){const Ye=t.target==="openAi",tt={type:"object",properties:{}},rt=[],nt=e.shape();for(const it in nt){let ot=nt[it];if(ot===void 0||ot._def===void 0)continue;let ct=safeIsOptional(ot);ct&&Ye&&(ot._def.typeName==="ZodOptional"&&(ot=ot._def.innerType),ot.isNullable()||(ot=ot.nullable()),ct=!1);const At=parseDef(ot._def,{...t,currentPath:[...t.currentPath,"properties",it],propertyPath:[...t.currentPath,"properties",it]});At!==void 0&&(tt.properties[it]=At,ct||rt.push(it))}rt.length&&(tt.required=rt);const at=decideAdditionalProperties(e,t);return at!==void 0&&(tt.additionalProperties=at),tt}function decideAdditionalProperties(e,t){if(e.catchall._def.typeName!=="ZodNever")return parseDef(e.catchall._def,{...t,currentPath:[...t.currentPath,"additionalProperties"]});switch(e.unknownKeys){case"passthrough":return t.allowedAdditionalProperties;case"strict":return t.rejectedAdditionalProperties;case"strip":return t.removeAdditionalStrategy==="strict"?t.allowedAdditionalProperties:t.rejectedAdditionalProperties}}function safeIsOptional(e){try{return e.isOptional()}catch{return!0}}const parseOptionalDef=(e,t)=>{var tt;if(t.currentPath.toString()===((tt=t.propertyPath)==null?void 0:tt.toString()))return parseDef(e.innerType._def,t);const Ye=parseDef(e.innerType._def,{...t,currentPath:[...t.currentPath,"anyOf","1"]});return Ye?{anyOf:[{not:parseAnyDef(t)},Ye]}:parseAnyDef(t)},parsePipelineDef=(e,t)=>{if(t.pipeStrategy==="input")return parseDef(e.in._def,t);if(t.pipeStrategy==="output")return parseDef(e.out._def,t);const Ye=parseDef(e.in._def,{...t,currentPath:[...t.currentPath,"allOf","0"]}),tt=parseDef(e.out._def,{...t,currentPath:[...t.currentPath,"allOf",Ye?"1":"0"]});return{allOf:[Ye,tt].filter(rt=>rt!==void 0)}};function parsePromiseDef(e,t){return parseDef(e.type._def,t)}function parseSetDef(e,t){const tt={type:"array",uniqueItems:!0,items:parseDef(e.valueType._def,{...t,currentPath:[...t.currentPath,"items"]})};return e.minSize&&setResponseValueAndErrors(tt,"minItems",e.minSize.value,e.minSize.message,t),e.maxSize&&setResponseValueAndErrors(tt,"maxItems",e.maxSize.value,e.maxSize.message,t),tt}function parseTupleDef(e,t){return e.rest?{type:"array",minItems:e.items.length,items:e.items.map((Ye,tt)=>parseDef(Ye._def,{...t,currentPath:[...t.currentPath,"items",`${tt}`]})).reduce((Ye,tt)=>tt===void 0?Ye:[...Ye,tt],[]),additionalItems:parseDef(e.rest._def,{...t,currentPath:[...t.currentPath,"additionalItems"]})}:{type:"array",minItems:e.items.length,maxItems:e.items.length,items:e.items.map((Ye,tt)=>parseDef(Ye._def,{...t,currentPath:[...t.currentPath,"items",`${tt}`]})).reduce((Ye,tt)=>tt===void 0?Ye:[...Ye,tt],[])}}function parseUndefinedDef(e){return{not:parseAnyDef(e)}}function parseUnknownDef(e){return parseAnyDef(e)}const parseReadonlyDef=(e,t)=>parseDef(e.innerType._def,t),selectParser=(e,t,Ye)=>{switch(t){case ZodFirstPartyTypeKind.ZodString:return parseStringDef(e,Ye);case ZodFirstPartyTypeKind.ZodNumber:return parseNumberDef(e,Ye);case ZodFirstPartyTypeKind.ZodObject:return parseObjectDef(e,Ye);case ZodFirstPartyTypeKind.ZodBigInt:return parseBigintDef(e,Ye);case ZodFirstPartyTypeKind.ZodBoolean:return parseBooleanDef();case ZodFirstPartyTypeKind.ZodDate:return parseDateDef(e,Ye);case ZodFirstPartyTypeKind.ZodUndefined:return parseUndefinedDef(Ye);case ZodFirstPartyTypeKind.ZodNull:return parseNullDef(Ye);case ZodFirstPartyTypeKind.ZodArray:return parseArrayDef(e,Ye);case ZodFirstPartyTypeKind.ZodUnion:case ZodFirstPartyTypeKind.ZodDiscriminatedUnion:return parseUnionDef(e,Ye);case ZodFirstPartyTypeKind.ZodIntersection:return parseIntersectionDef(e,Ye);case ZodFirstPartyTypeKind.ZodTuple:return parseTupleDef(e,Ye);case ZodFirstPartyTypeKind.ZodRecord:return parseRecordDef(e,Ye);case ZodFirstPartyTypeKind.ZodLiteral:return parseLiteralDef(e,Ye);case ZodFirstPartyTypeKind.ZodEnum:return parseEnumDef(e);case ZodFirstPartyTypeKind.ZodNativeEnum:return parseNativeEnumDef(e);case ZodFirstPartyTypeKind.ZodNullable:return parseNullableDef(e,Ye);case ZodFirstPartyTypeKind.ZodOptional:return parseOptionalDef(e,Ye);case ZodFirstPartyTypeKind.ZodMap:return parseMapDef(e,Ye);case ZodFirstPartyTypeKind.ZodSet:return parseSetDef(e,Ye);case ZodFirstPartyTypeKind.ZodLazy:return()=>e.getter()._def;case ZodFirstPartyTypeKind.ZodPromise:return parsePromiseDef(e,Ye);case ZodFirstPartyTypeKind.ZodNaN:case ZodFirstPartyTypeKind.ZodNever:return parseNeverDef(Ye);case ZodFirstPartyTypeKind.ZodEffects:return parseEffectsDef(e,Ye);case ZodFirstPartyTypeKind.ZodAny:return parseAnyDef(Ye);case ZodFirstPartyTypeKind.ZodUnknown:return parseUnknownDef(Ye);case ZodFirstPartyTypeKind.ZodDefault:return parseDefaultDef(e,Ye);case ZodFirstPartyTypeKind.ZodBranded:return parseBrandedDef(e,Ye);case ZodFirstPartyTypeKind.ZodReadonly:return parseReadonlyDef(e,Ye);case ZodFirstPartyTypeKind.ZodCatch:return parseCatchDef(e,Ye);case ZodFirstPartyTypeKind.ZodPipeline:return parsePipelineDef(e,Ye);case ZodFirstPartyTypeKind.ZodFunction:case ZodFirstPartyTypeKind.ZodVoid:case ZodFirstPartyTypeKind.ZodSymbol:return;default:return(tt=>{})()}};function parseDef(e,t,Ye=!1){var it;const tt=t.seen.get(e);if(t.override){const ot=(it=t.override)==null?void 0:it.call(t,e,t,tt,Ye);if(ot!==ignoreOverride)return ot}if(tt&&!Ye){const ot=get$ref(tt,t);if(ot!==void 0)return ot}const rt={def:e,path:t.currentPath,jsonSchema:void 0};t.seen.set(e,rt);const nt=selectParser(e,e.typeName,t),at=typeof nt=="function"?parseDef(nt(),t):nt;if(at&&addMeta(e,t,at),t.postProcess){const ot=t.postProcess(at,e,t);return rt.jsonSchema=at,ot}return rt.jsonSchema=at,at}const get$ref=(e,t)=>{switch(t.$refStrategy){case"root":return{$ref:e.path.join("/")};case"relative":return{$ref:getRelativePath(t.currentPath,e.path)};case"none":case"seen":return e.path.length<t.currentPath.length&&e.path.every((Ye,tt)=>t.currentPath[tt]===Ye)?(console.warn(`Recursive reference detected at ${t.currentPath.join("/")}! Defaulting to any`),parseAnyDef(t)):t.$refStrategy==="seen"?parseAnyDef(t):void 0}},addMeta=(e,t,Ye)=>(e.description&&(Ye.description=e.description,t.markdownDescription&&(Ye.markdownDescription=e.description)),Ye),zodToJsonSchema=(e,t)=>{const Ye=getRefs(t);let tt;const rt=t==null?void 0:t.name,nt=parseDef(e._def,Ye,!1)??parseAnyDef(Ye);Ye.flags.hasReferencedOpenAiAnyType&&(tt||(tt={}),tt[Ye.openAiAnyTypeName]||(tt[Ye.openAiAnyTypeName]={type:["string","number","integer","boolean","array","null"],items:{$ref:Ye.$refStrategy==="relative"?"1":[...Ye.basePath,Ye.definitionPath,Ye.openAiAnyTypeName].join("/")}}));const at=rt===void 0?tt?{...nt,[Ye.definitionPath]:tt}:nt:{$ref:[...Ye.$refStrategy==="relative"?[]:Ye.basePath,Ye.definitionPath,rt].join("/"),[Ye.definitionPath]:{...tt,[rt]:nt}};return Ye.target==="jsonSchema7"?at.$schema="http://json-schema.org/draft-07/schema#":(Ye.target==="jsonSchema2019-09"||Ye.target==="openAi")&&(at.$schema="https://json-schema.org/draft/2019-09/schema#"),Ye.target==="openAi"&&("anyOf"in at||"oneOf"in at||"allOf"in at||"type"in at&&Array.isArray(at.type))&&console.warn("Warning: OpenAI may not support schemas with unions as roots! Try wrapping it in an object property."),at},createUITool=e=>{const t=e.execute||(async(Ye,tt)=>{var rt;try{const nt=await((rt=e.handler)==null?void 0:rt.call(e,Ye,tt));return typeof nt=="string"?[{type:"text",text:nt}]:nt.decisions?nt:[{type:"text",text:JSON.stringify(nt)}]}catch(nt){return[{type:"text",text:`Error: ${nt}`}]}});return{...e,execute:t}},createJSONDefineTool=e=>({name:e.name,description:e.description,parameters:e.isPureParams?e.parameters:zodToJsonSchema(object(e.parameters))});class ToolManager{constructor(){Cr(this,"tools",new Map);Cr(this,"waitingMap",new Map)}bindTool(t){this.tools.has(t.name)&&t.name!=="__default__"&&console.warn(`Tool with name ${t.name} already exists`),this.tools.set(t.name,t)}bindTools(t){t.forEach(Ye=>this.bindTool(Ye))}getAllTools(){return Array.from(this.tools.values())}getTool(t){return this.tools.get(t)}removeTool(t){return this.tools.delete(t)}clearTools(){this.tools.clear()}reset(){this.clearTools(),this.clearWaiting()}clearWaiting(){this.waitingMap.clear()}async callTool(t,Ye,tt){var nt;const rt=this.getTool(t)||this.getTool("__default__");return await((nt=rt.execute)==null?void 0:nt.call(rt,Ye,tt))}async toJSON(t,Ye=!0){return Array.from(this.tools.values()).filter(tt=>Ye?!tt.onlyRender:!0).filter(tt=>!tt.allowGraph||tt.allowGraph.includes(t)).map(tt=>createJSONDefineTool(tt))}doneWaiting(t,Ye){return this.waitingMap.has(t)?(this.waitingMap.get(t)(Ye),this.waitingMap.delete(t),!0):(console.warn(`Waiting for tool ${t} not found`),!1)}waitForDone(t){return this.waitingMap.has(t)?this.waitingMap.get(t):new Promise((tt,rt)=>{this.waitingMap.set(t,tt)})}static waitForUIDone(t,Ye){return Ye.client.tools.waitForDone(Ye.message.id)}}class StreamingMessageType{static isTool(t){return t.type==="tool"}static isToolAssistant(t){var Ye,tt;return t.type==="ai"&&(((Ye=t.tool_calls)==null?void 0:Ye.length)||((tt=t.tool_call_chunks)==null?void 0:tt.length))}}class MessageProcessor{constructor(){Cr(this,"streamingMessage",[]);Cr(this,"graphMessages",[])}getStreamingMessages(){return[...this.streamingMessage]}setStreamingMessages(t){this.streamingMessage=t}clearStreamingMessages(){this.streamingMessage=[]}getGraphMessages(){return[...this.graphMessages]}setGraphMessages(t){this.graphMessages=t}updateStreamingMessage(t){const Ye=this.streamingMessage[this.streamingMessage.length-1];if(!(Ye!=null&&Ye.id)||t.id!==Ye.id){this.streamingMessage.push(t);return}this.streamingMessage[this.streamingMessage.length-1]=t}combineGraphMessagesWithStreamingMessages(){const t=new Map(this.streamingMessage.map(Ye=>[Ye.id,Ye]));return[...this.graphMessages.map(Ye=>{if(t.has(Ye.id)){const tt=t.get(Ye.id);return t.delete(Ye.id),tt}return Ye}),...t.values()]}cloneMessage(t){return JSON.parse(JSON.stringify(t))}attachInfoForMessage(t){var rt,nt,at;let Ye=null;const tt=[...t];for(const it of tt){const ot=((rt=it.response_metadata)==null?void 0:rt.create_time)||"";if(it.unique_id=it.tool_call_id||it.id,it.spend_time=new Date(ot).getTime()-new Date(((nt=Ye==null?void 0:Ye.response_metadata)==null?void 0:nt.create_time)||ot).getTime(),!it.usage_metadata&&((at=it.response_metadata)!=null&&at.usage)){const ct=it.response_metadata.usage;it.usage_metadata={...ct,input_tokens:ct.prompt_tokens,output_tokens:ct.completion_tokens,total_tokens:ct.total_tokens}}Ye=it}return tt}composeToolMessages(t){var nt,at;const Ye=[],tt=new Map,rt=new Map;for(const it of t)if(!(StreamingMessageType.isToolAssistant(it)&&((nt=it.tool_calls||it.tool_call_chunks)==null||nt.forEach(ot=>{tt.set(ot.id,ot),rt.set(ot.id,it)}),!it.content))){if(StreamingMessageType.isTool(it)&&!it.tool_input){const ot=tt.get(it.tool_call_id),ct=rt.get(it.tool_call_id);if(ot){it.tool_input=typeof ot.args!="string"?JSON.stringify(ot.args):ot.args;const At=!!it.content;it.done=At,it.additional_kwargs={...(ct==null?void 0:ct.additional_kwargs)||{},...it.additional_kwargs||{},done:At}}ct&&(it.usage_metadata=ct.usage_metadata,it.node_name=ct.name,it.name||(it.name=(at=ct.tool_calls.find(At=>At.id===it.tool_call_id))==null?void 0:at.name))}Ye.push(it)}return Ye}renderMessages(t,Ye,tt){var ot;const rt=new Map,nt=new Set,at=[],it=this.combineGraphMessagesWithStreamingMessages();for(let ct=it.length-1;ct>=0;ct--){const At=this.cloneMessage(it[ct]);if(!At.id){at.unshift(At);continue}if(At.type==="ai"&&(At.name||(At.name=Ye().name)),StreamingMessageType.isToolAssistant(At)){const Rt=At;rt.set(At.id,Rt);const Ft=((ot=Rt.tool_calls)!=null&&ot.length?Rt.tool_calls:Rt.tool_call_chunks).filter(Ut=>!nt.has(Ut.id)).map((Ut,Ht)=>{var zt,Yt,Gt,Vt;return{type:"tool",additional_kwargs:{},tool_input:(Vt=(Gt=(Yt=(zt=Rt.additional_kwargs)==null?void 0:zt.tool_calls)==null?void 0:Yt[Ht])==null?void 0:Gt.function)==null?void 0:Vt.arguments,id:Ut.id,name:Ut.name,response_metadata:{},tool_call_id:Ut.id,content:""}});for(const Ut of Ft)rt.has(Ut.id)||(at.unshift(Ut),rt.set(Ut.id,Ut));at.unshift(Rt)}else At.type==="tool"&&At.tool_call_id&&nt.add(At.tool_call_id),rt.set(At.id,At),at.unshift(At)}return this.processMessages(at,t,tt)}foldTreeMessages(t,Ye,tt){const rt=Object.entries((Ye==null?void 0:Ye.task_store)||{}).map(([At,Rt])=>[At,Rt.messages]),nt=new Map(rt),at=new Set,it=new Map(Object.entries(tt||{}).map(([At,Rt])=>{if(Rt!=null&&Rt.parent_id)return at.add(At),[At,Rt==null?void 0:Rt.parent_id]}).filter(At=>At!==void 0)),ot=nt,ct=[];for(const At of t)if(!at.has(At.id))ct.push(At);else{const qt=it.get(At.id),Ft=ot.get(qt);Ft?Ft.push(At):ot.set(qt,[At])}for(const At of ct)if(At.sub_messages=ot.get(At.id)||[],At.type==="tool"&&ot.has(At.tool_call_id)){At.sub_messages.unshift(...ot.get(At.tool_call_id));const Rt=At.sub_messages.filter((qt,Ft,Ut)=>Ut.findIndex(Ht=>Ht.id===qt.id)===Ft);At.sub_messages=this.beforeFold(Rt)}return ct}beforeFold(t){const Ye=this.composeToolMessages(t);return this.attachInfoForMessage(Ye)}processMessages(t,Ye,tt){return this.foldTreeMessages(this.beforeFold(t),Ye,tt)}}async function revertChatTo(e,t,Ye,tt){const rt=await e.threads.get(t),nt=rt.values.messages,at=nt.findIndex(Rt=>Rt.id===Ye);if(at===-1)throw new Error(`Message id ${Ye} not found`);const it=tt.includeMessageId?at:at+1,ot=nt.slice(it),ct={...rt.values,messages:ot.map(Rt=>({type:"remove",id:Rt.id}))},At=await e.threads.updateState(t,{values:ct});return{state:{messages:nt.slice(0,it)},checkpoint:At}}const isObject$4=e=>typeof e=="object"&&e!==null,isObjectCustom=e=>isObject$4(e)&&!(e instanceof RegExp)&&!(e instanceof Error)&&!(e instanceof Date)&&!(globalThis.Blob&&e instanceof globalThis.Blob),mapObjectSkip=Symbol("mapObjectSkip"),_mapObject=(e,t,Ye,tt=new WeakMap)=>{if(Ye={deep:!1,target:{},...Ye},tt.has(e))return tt.get(e);tt.set(e,Ye.target);const{target:rt}=Ye;delete Ye.target;const nt=at=>at.map(it=>isObjectCustom(it)?_mapObject(it,t,Ye,tt):it);if(Array.isArray(e))return nt(e);for(const[at,it]of Object.entries(e)){const ot=t(at,it,e);if(ot===mapObjectSkip)continue;let[ct,At,{shouldRecurse:Rt=!0}={}]=ot;ct!=="__proto__"&&(Ye.deep&&Rt&&isObjectCustom(At)&&(At=Array.isArray(At)?nt(At):_mapObject(At,t,Ye,tt)),rt[ct]=At)}return rt};function mapObject(e,t,Ye){if(!isObject$4(e))throw new TypeError(`Expected an object, got \`${e}\` (${typeof e})`);if(Array.isArray(e))throw new TypeError("Expected an object, got an array");return _mapObject(e,t,Ye)}const UPPERCASE=/[\p{Lu}]/u,LOWERCASE=/[\p{Ll}]/u,LEADING_CAPITAL=/^[\p{Lu}](?![\p{Lu}])/gu,IDENTIFIER=/([\p{Alpha}\p{N}_]|$)/u,SEPARATORS=/[_.\- ]+/,LEADING_SEPARATORS=new RegExp("^"+SEPARATORS.source),SEPARATORS_AND_IDENTIFIER=new RegExp(SEPARATORS.source+IDENTIFIER.source,"gu"),NUMBERS_AND_IDENTIFIER=new RegExp("\\d+"+IDENTIFIER.source,"gu"),preserveCamelCase=(e,t,Ye,tt)=>{let rt=!1,nt=!1,at=!1,it=!1;for(let ot=0;ot<e.length;ot++){const ct=e[ot];it=ot>2?e[ot-3]==="-":!0,rt&&UPPERCASE.test(ct)?(e=e.slice(0,ot)+"-"+e.slice(ot),rt=!1,at=nt,nt=!0,ot++):nt&&at&&LOWERCASE.test(ct)&&(!it||tt)?(e=e.slice(0,ot-1)+"-"+e.slice(ot-1),at=nt,nt=!1,rt=!0):(rt=t(ct)===ct&&Ye(ct)!==ct,at=nt,nt=Ye(ct)===ct&&t(ct)!==ct)}return e},preserveConsecutiveUppercase=(e,t)=>(LEADING_CAPITAL.lastIndex=0,e.replaceAll(LEADING_CAPITAL,Ye=>t(Ye))),postProcess=(e,t)=>(SEPARATORS_AND_IDENTIFIER.lastIndex=0,NUMBERS_AND_IDENTIFIER.lastIndex=0,e.replaceAll(NUMBERS_AND_IDENTIFIER,(Ye,tt,rt)=>["_","-"].includes(e.charAt(rt+Ye.length))?Ye:t(Ye)).replaceAll(SEPARATORS_AND_IDENTIFIER,(Ye,tt)=>t(tt)));function camelCase(e,t){if(!(typeof e=="string"||Array.isArray(e)))throw new TypeError("Expected the input to be `string | string[]`");if(t={pascalCase:!1,preserveConsecutiveUppercase:!1,...t},Array.isArray(e)?e=e.map(nt=>nt.trim()).filter(nt=>nt.length).join("-"):e=e.trim(),e.length===0)return"";const Ye=t.locale===!1?nt=>nt.toLowerCase():nt=>nt.toLocaleLowerCase(t.locale),tt=t.locale===!1?nt=>nt.toUpperCase():nt=>nt.toLocaleUpperCase(t.locale);return e.length===1?SEPARATORS.test(e)?"":t.pascalCase?tt(e):Ye(e):(e!==Ye(e)&&(e=preserveCamelCase(e,Ye,tt,t.preserveConsecutiveUppercase)),e=e.replace(LEADING_SEPARATORS,""),e=t.preserveConsecutiveUppercase?preserveConsecutiveUppercase(e,Ye):Ye(e),t.pascalCase&&(e=tt(e.charAt(0))+e.slice(1)),postProcess(e,tt))}var ja,Bn,Yn,cs,vo,ds,An,Iu,ri,Zh,ef,tf,rf,Xh,Nu;class QuickLRU extends Map{constructor(Ye={}){super();Na(this,An);Na(this,ja,0);Na(this,Bn,new Map);Na(this,Yn,new Map);Na(this,cs);Na(this,vo);Na(this,ds);if(!(Ye.maxSize&&Ye.maxSize>0))throw new TypeError("`maxSize` must be a number greater than 0");if(typeof Ye.maxAge=="number"&&Ye.maxAge===0)throw new TypeError("`maxAge` must be a number greater than 0");$n(this,cs,Ye.maxSize),$n(this,vo,Ye.maxAge||Number.POSITIVE_INFINITY),$n(this,ds,Ye.onEviction)}get __oldCache(){return Qr(this,Yn)}get(Ye){if(Qr(this,Bn).has(Ye)){const tt=Qr(this,Bn).get(Ye);return jn(this,An,ef).call(this,Ye,tt)}if(Qr(this,Yn).has(Ye)){const tt=Qr(this,Yn).get(Ye);if(jn(this,An,ri).call(this,Ye,tt)===!1)return jn(this,An,Xh).call(this,Ye,tt),tt.value}}set(Ye,tt,{maxAge:rt=Qr(this,vo)}={}){const nt=typeof rt=="number"&&rt!==Number.POSITIVE_INFINITY?Date.now()+rt:void 0;return Qr(this,Bn).has(Ye)?Qr(this,Bn).set(Ye,{value:tt,expiry:nt}):jn(this,An,rf).call(this,Ye,{value:tt,expiry:nt}),this}has(Ye){return Qr(this,Bn).has(Ye)?!jn(this,An,ri).call(this,Ye,Qr(this,Bn).get(Ye)):Qr(this,Yn).has(Ye)?!jn(this,An,ri).call(this,Ye,Qr(this,Yn).get(Ye)):!1}peek(Ye){if(Qr(this,Bn).has(Ye))return jn(this,An,tf).call(this,Ye,Qr(this,Bn));if(Qr(this,Yn).has(Ye))return jn(this,An,tf).call(this,Ye,Qr(this,Yn))}expiresIn(Ye){const tt=Qr(this,Bn).get(Ye)??Qr(this,Yn).get(Ye);if(tt)return tt.expiry?tt.expiry-Date.now():Number.POSITIVE_INFINITY}delete(Ye){const tt=Qr(this,Bn).delete(Ye);return tt&&Xd(this,ja)._--,Qr(this,Yn).delete(Ye)||tt}clear(){Qr(this,Bn).clear(),Qr(this,Yn).clear(),$n(this,ja,0)}resize(Ye){if(!(Ye&&Ye>0))throw new TypeError("`maxSize` must be a number greater than 0");const tt=[...jn(this,An,Nu).call(this)],rt=tt.length-Ye;rt<0?($n(this,Bn,new Map(tt)),$n(this,Yn,new Map),$n(this,ja,tt.length)):(rt>0&&jn(this,An,Iu).call(this,tt.slice(0,rt)),$n(this,Yn,new Map(tt.slice(rt))),$n(this,Bn,new Map),$n(this,ja,0)),$n(this,cs,Ye)}evict(Ye=1){const tt=Number(Ye);if(!tt||tt<=0)return;const rt=[...jn(this,An,Nu).call(this)],nt=Math.trunc(Math.min(tt,Math.max(rt.length-1,0)));nt<=0||(jn(this,An,Iu).call(this,rt.slice(0,nt)),$n(this,Yn,new Map(rt.slice(nt))),$n(this,Bn,new Map),$n(this,ja,0))}*keys(){for(const[Ye]of this)yield Ye}*values(){for(const[,Ye]of this)yield Ye}*[Symbol.iterator](){for(const Ye of Qr(this,Bn)){const[tt,rt]=Ye;jn(this,An,ri).call(this,tt,rt)===!1&&(yield[tt,rt.value])}for(const Ye of Qr(this,Yn)){const[tt,rt]=Ye;Qr(this,Bn).has(tt)||jn(this,An,ri).call(this,tt,rt)===!1&&(yield[tt,rt.value])}}*entriesDescending(){let Ye=[...Qr(this,Bn)];for(let tt=Ye.length-1;tt>=0;--tt){const rt=Ye[tt],[nt,at]=rt;jn(this,An,ri).call(this,nt,at)===!1&&(yield[nt,at.value])}Ye=[...Qr(this,Yn)];for(let tt=Ye.length-1;tt>=0;--tt){const rt=Ye[tt],[nt,at]=rt;Qr(this,Bn).has(nt)||jn(this,An,ri).call(this,nt,at)===!1&&(yield[nt,at.value])}}*entriesAscending(){for(const[Ye,tt]of jn(this,An,Nu).call(this))yield[Ye,tt.value]}get size(){if(!Qr(this,ja))return Qr(this,Yn).size;let Ye=0;for(const tt of Qr(this,Yn).keys())Qr(this,Bn).has(tt)||Ye++;return Math.min(Qr(this,ja)+Ye,Qr(this,cs))}get maxSize(){return Qr(this,cs)}get maxAge(){return Qr(this,vo)}entries(){return this.entriesAscending()}forEach(Ye,tt=this){for(const[rt,nt]of this.entriesAscending())Ye.call(tt,nt,rt,this)}get[Symbol.toStringTag](){return"QuickLRU"}toString(){return`QuickLRU(${this.size}/${this.maxSize})`}[Symbol.for("nodejs.util.inspect.custom")](){return this.toString()}}ja=new WeakMap,Bn=new WeakMap,Yn=new WeakMap,cs=new WeakMap,vo=new WeakMap,ds=new WeakMap,An=new WeakSet,Iu=function(Ye){if(typeof Qr(this,ds)=="function")for(const[tt,rt]of Ye)Qr(this,ds).call(this,tt,rt.value)},ri=function(Ye,tt){return typeof tt.expiry=="number"&&tt.expiry<=Date.now()?(typeof Qr(this,ds)=="function"&&Qr(this,ds).call(this,Ye,tt.value),this.delete(Ye)):!1},Zh=function(Ye,tt){if(jn(this,An,ri).call(this,Ye,tt)===!1)return tt.value},ef=function(Ye,tt){return tt.expiry?jn(this,An,Zh).call(this,Ye,tt):tt.value},tf=function(Ye,tt){const rt=tt.get(Ye);return jn(this,An,ef).call(this,Ye,rt)},rf=function(Ye,tt){Qr(this,Bn).set(Ye,tt),Xd(this,ja)._++,Qr(this,ja)>=Qr(this,cs)&&($n(this,ja,0),jn(this,An,Iu).call(this,Qr(this,Yn)),$n(this,Yn,Qr(this,Bn)),$n(this,Bn,new Map))},Xh=function(Ye,tt){Qr(this,Yn).delete(Ye),jn(this,An,rf).call(this,Ye,tt)},Nu=function*(){for(const Ye of Qr(this,Yn)){const[tt,rt]=Ye;Qr(this,Bn).has(tt)||jn(this,An,ri).call(this,tt,rt)===!1&&(yield Ye)}for(const Ye of Qr(this,Bn)){const[tt,rt]=Ye;jn(this,An,ri).call(this,tt,rt)===!1&&(yield Ye)}};const has$1=(e,t)=>e.some(Ye=>typeof Ye=="string"?Ye===t:(Ye.lastIndex=0,Ye.test(t))),isNumericKey=e=>e.trim()!==""&&!Number.isNaN(Number(e)),cache=new QuickLRU({maxSize:1e5}),isBuiltIn=e=>ArrayBuffer.isView(e)||e instanceof Date||e instanceof RegExp||e instanceof Error||e instanceof Map||e instanceof Set||e instanceof WeakMap||e instanceof WeakSet||e instanceof Promise,isObject$3=e=>typeof e=="object"&&e!==null&&!isBuiltIn(e),transform$4=(e,t={},Ye=new WeakMap,tt)=>{if(!isObject$3(e))return e;if(Ye.has(e))return Ye.get(e);const{exclude:rt,pascalCase:nt=!1,stopPaths:at,deep:it=!1,preserveConsecutiveUppercase:ot=!1}=t,ct=new Set(at);if(Array.isArray(e)){const Ut=[];Ye.set(e,Ut);for(const Ht of e)Ut.push(isObject$3(Ht)?transform$4(Ht,t,Ye,tt):Ht);return Ut}const At={};Ye.set(e,At);const qt=mapObject(e,(Ut=>(Ht,zt)=>{if(it&&isObject$3(zt)){const Yt=Ut===void 0?Ht:`${Ut}.${Ht}`;ct.has(Yt)||(zt=Array.isArray(zt)?zt.map(Gt=>isObject$3(Gt)?transform$4(Gt,t,Ye,Yt):Gt):transform$4(zt,t,Ye,Yt))}if(typeof Ht=="string"&&!isNumericKey(Ht)&&!(rt&&has$1(rt,Ht))){const Yt=nt?`${Ht}_`:Ht;if(cache.has(Yt))Ht=cache.get(Yt);else{const Gt=Ht.match(/^[_$]*/)[0],Vt=camelCase(Ht.slice(Gt.length),{pascalCase:nt,locale:!1,preserveConsecutiveUppercase:ot});Ht=Gt+Vt,Ht.length<100&&cache.set(Yt,Ht)}}return[Ht,zt]})(tt),{deep:!1});Object.assign(At,qt);const Ft=Object.getOwnPropertySymbols(e);for(const Ut of Ft)At[Ut]=it&&isObject$3(e[Ut])?transform$4(e[Ut],t,Ye,tt):e[Ut];return At};function camelcaseKeys(e,t){const Ye=new WeakMap;return Array.isArray(e)?e.map(tt=>isObject$3(tt)?transform$4(tt,t,Ye,void 0):tt):transform$4(e,t,Ye)}class LangGraphClient extends EventEmitter{constructor(Ye){super();Cr(this,"client");Cr(this,"currentAssistant",null);Cr(this,"currentThread",null);Cr(this,"tools",new ToolManager);Cr(this,"availableAssistants",[]);Cr(this,"graphState",{});Cr(this,"currentRun");Cr(this,"stopController",null);Cr(this,"messageProcessor");Cr(this,"legacyMode");Cr(this,"_status","idle");Cr(this,"messagesMetadata",{});Cr(this,"humanInTheLoop",null);Cr(this,"graphPosition","");Cr(this,"extraParams",{});this.client=Ye.client,this.legacyMode=Ye.legacyMode??!1,this.messageProcessor=new MessageProcessor}get assistants(){return this.client.assistants}get threads(){return this.client.threads}get runs(){return this.client.runs}get status(){return this._status}listAssistants(){return this.assistants.search({metadata:null,offset:0,limit:100})}async initAssistant(Ye,tt={}){try{const rt=await this.listAssistants();if(this.availableAssistants=rt,rt.length>0)if(Ye){if(this.currentAssistant=rt.find(nt=>nt.graph_id===Ye)||null,!this.currentAssistant){if(tt.fallbackToAvailableAssistants)return this.currentAssistant=this.availableAssistants[0],this.currentAssistant;throw new Error("Agent not found: "+Ye)}}else return this.currentAssistant=rt[0],this.currentAssistant;else throw new Error("No assistants found")}catch(rt){throw console.error("Failed to initialize LangGraphClient:",rt),rt}}async createThread({threadId:Ye,graphId:tt}={}){try{return this.currentThread=await this.threads.create({threadId:Ye,graphId:tt}),this.currentThread}catch(rt){throw console.error("Failed to create new thread:",rt),rt}}graphVisualize(){var Ye;return this.assistants.getGraph((Ye=this.currentAssistant)==null?void 0:Ye.assistant_id,{xray:!0})}async listThreads(Ye={}){return this.threads.search({sortOrder:Ye.sortOrder||"desc",sortBy:Ye.sortBy||"updated_at",offset:Ye.offset||0,limit:Ye.limit||10})}async deleteThread(Ye){return this.threads.delete(Ye)}async resetThread(Ye,tt){var nt;await this.initAssistant(Ye),this.currentThread=await this.threads.get(tt),this.graphState=this.currentThread.values;const rt=((nt=this.graphState)==null?void 0:nt.messages)||[];return this.messageProcessor.setGraphMessages(rt),this.emit("value",{event:"messages/partial",data:{messages:this.messageProcessor.getGraphMessages()}}),this.currentThread}async resetStream(){const Ye=await this.runs.list(this.currentThread.thread_id),tt=Ye==null?void 0:Ye.find(rt=>rt.status==="running"||rt.status==="pending");tt&&await this.sendMessage([],{joinRunId:tt.run_id})}cloneMessage(Ye){return this.messageProcessor.cloneMessage(Ye)}get renderMessage(){return this.messageProcessor.renderMessages(this.graphState,()=>this.getGraphNodeNow(),this.messagesMetadata)}get tokenCounter(){return this.messageProcessor.getGraphMessages().reduce((Ye,tt)=>{var rt,nt,at,it,ot;if(tt.usage_metadata)Ye.total_tokens+=((rt=tt.usage_metadata)==null?void 0:rt.total_tokens)||0,Ye.input_tokens+=((nt=tt.usage_metadata)==null?void 0:nt.input_tokens)||0,Ye.output_tokens+=((at=tt.usage_metadata)==null?void 0:at.output_tokens)||0;else if((it=tt.response_metadata)!=null&&it.usage){const ct=(ot=tt.response_metadata)==null?void 0:ot.usage;Ye.total_tokens+=ct.total_tokens||0,Ye.input_tokens+=ct.prompt_tokens||0,Ye.output_tokens+=ct.completion_tokens||0}return Ye},{total_tokens:0,input_tokens:0,output_tokens:0})}isFELocking(Ye){var nt;const tt=Ye[Ye.length-1];if(!tt)return!1;const rt=this.tools.getTool(tt==null?void 0:tt.name);return rt&&rt.render&&(tt==null?void 0:tt.type)==="tool"&&!((nt=tt==null?void 0:tt.additional_kwargs)!=null&&nt.done)}cancelRun(){var Ye,tt;(Ye=this.currentThread)!=null&&Ye.thread_id&&((tt=this.currentRun)!=null&&tt.run_id)&&this.runs.cancel(this.currentThread.thread_id,this.currentRun.run_id)}async revertChatTo(Ye,tt){const{state:rt,checkpoint:nt}=await revertChatTo(this.client,this.currentThread.thread_id,Ye,tt);return this.graphState=rt,this.messageProcessor.clearStreamingMessages(),this.messageProcessor.setGraphMessages(rt.messages),rt}async sendMessage(Ye,{joinRunId:tt,extraParams:rt,_debug:nt,command:at}={}){if(!this.currentAssistant)throw new Error("Thread or Assistant not initialized");this.currentThread||(await this.createThread({graphId:this.currentAssistant.graph_id}),this.emit("thread",{event:"thread/create",data:{thread:this.currentThread}}));const it=Array.isArray(Ye)?Ye:[{type:"human",content:Ye}],ot=[];this._status="busy",this.emit("start",{event:"start"});const At=await(async()=>{if(nt!=null&&nt.streamResponse)return nt.streamResponse;const qt=this.legacyMode?Ft=>{ot.push(Ft),this.processStreamChunk(Ft,at)}:void 0;return tt?this.runs.joinStream(this.currentThread.thread_id,tt,{onCallback:qt}):this.runs.stream(this.currentThread.thread_id,this.currentAssistant.assistant_id,{input:{...this.graphState,...this.extraParams,...rt||{},messages:it,fe_tools:await this.tools.toJSON(this.currentAssistant.graph_id)},streamMode:["messages","values"],streamSubgraphs:!0,command:at,onCallback:qt})})();if(!this.legacyMode)for await(const qt of At)ot.push(qt),this.processStreamChunk(qt,at);const Rt=await this.runFETool();return Rt&&ot.push(...Rt),this.humanInTheLoop=null,this._status="idle",this.emit("done",{event:"done"}),this.messageProcessor.clearStreamingMessages(),ot}getGraphPosition(){return this.graphPosition.split("|").map(Ye=>{const[tt,rt]=Ye.split(":");return{id:rt,name:tt}})}getGraphNodeNow(){const Ye=this.getGraphPosition();return Ye[Ye.length-1]}processStreamChunk(Ye,tt){if(Ye.event==="metadata")this.currentRun=Ye.data;else if(Ye.event==="error"||Ye.event==="Error"||Ye.event==="__stream_error__")this._status="error",this.emit("error",Ye);else{if(Ye.event==="messages/metadata")return Object.assign(this.messagesMetadata,Ye.data),!0;if(Ye.event==="messages/partial"||Ye.event==="messages/complete"){for(const rt of Ye.data)this.messageProcessor.updateStreamingMessage(rt);return this.emit("message",Ye),!0}else if(Ye.event==="values"){const rt=Ye.data;if(rt.__interrupt__)this._status="interrupted",this.humanInTheLoop=camelcaseKeys(rt.__interrupt__,{deep:!0});else if(rt.messages){const nt=!!(tt!=null&&tt.resume),at=rt.messages.length>=this.messageProcessor.getGraphMessages().length;(!nt||nt&&at)&&(this.messageProcessor.setGraphMessages(rt.messages),this.emit("value",Ye)),this.graphState=Ye.data}return!0}else Ye.event.startsWith("values|")&&(this.graphPosition=Ye.event.split("|")[1])}return!1}runFETool(){var rt;const Ye=this.messageProcessor.getStreamingMessages(),tt=Ye[Ye.length-1];if(tt&&tt.type==="ai"&&(rt=tt.tool_calls)!=null&&rt.length){const nt=tt.tool_calls.map(at=>{const it={...at,tool_call_id:at.id,tool_input:JSON.stringify(at.args),additional_kwargs:{}};return this.callFETool(it,at.args)});return this._status="interrupted",this.currentThread.status="interrupted",Promise.all(nt)}}async callFETool(Ye,tt){const rt=this,nt=await this.tools.callTool(Ye.name,tt,{client:rt,message:Ye});if(nt)return this.resume(nt)}resume(Ye){return this.sendMessage([],{command:{resume:Ye}})}doneFEToolWaiting(Ye,tt){var nt;!this.tools.doneWaiting(Ye,tt)&&((nt=this.currentThread)==null?void 0:nt.status)==="interrupted"&&this.resume(tt)}getCurrentThread(){return this.currentThread}getCurrentAssistant(){return this.currentAssistant}async reset(){var Ye;await this.initAssistant((Ye=this.currentAssistant)==null?void 0:Ye.graph_id),this.currentThread=null,this.graphState={},this.messageProcessor.setGraphMessages([]),this.messageProcessor.clearStreamingMessages(),this.currentRun=void 0,this.tools.clearWaiting(),this._status="idle",this.emit("value",{event:"messages/partial",data:{messages:[]}})}}let History$1=class{constructor(t){Cr(this,"sessions",new Map);Cr(this,"activeSessionId",null);Cr(this,"clientConfig");Cr(this,"virtualClient");this.clientConfig=t,this.virtualClient=new LangGraphClient(t)}async createSession(t={}){var nt;const Ye=t.sessionId||this.generateSessionId(),tt=t.agentName||((nt=this.virtualClient.getCurrentAssistant())==null?void 0:nt.graph_id);if(!tt)throw new Error("Agent name is required. Please call init() first or provide agentName.");if(this.sessions.has(Ye))throw new Error(`Session ${Ye} already exists`);const rt={sessionId:Ye,agentName:tt};return t.restore&&(rt.thread=await this.virtualClient.threads.get(Ye)),this.sessions.set(Ye,rt),rt}async activateSession(t){var rt,nt;const Ye=this.sessions.get(t);if(!Ye)throw new Error(`Session ${t} not found`);if(!Ye.client){const at=new LangGraphClient(this.clientConfig);await at.initAssistant(Ye.agentName),Ye.thread&&await at.resetThread(Ye.agentName,t),Ye.client=at}const tt=this.activeSessionId&&this.sessions.get(this.activeSessionId);return tt&&((rt=tt.client)==null?void 0:rt.status)==="idle"&&((nt=tt.client)==null||nt.reset(),tt.client=void 0),this.activeSessionId=t,Ye}getActiveSession(){return this.activeSessionId&&this.sessions.get(this.activeSessionId)||null}getSession(t){return this.sessions.get(t)||null}getAllSessions(){return Array.from(this.sessions.values())}async deleteSession(t){if(!this.sessions.get(t))return!1;this.activeSessionId===t&&(this.activeSessionId=null);try{await this.virtualClient.deleteThread(t)}catch(tt){console.warn(`Failed to delete thread for session ${t}:`,tt)}return this.sessions.delete(t),!0}async clearAllSessions(){const t=Array.from(this.sessions.keys());for(const Ye of t)await this.deleteSession(Ye);this.activeSessionId=null}getSessionCount(){return this.sessions.size}generateSessionId(){return typeof crypto<"u"&&crypto.randomUUID?crypto.randomUUID():"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,t=>{const Ye=Math.random()*16|0;return(t==="x"?Ye:Ye&3|8).toString(16)})}async addSessionFromThread(t,Ye){var rt;const tt=Ye||((rt=this.virtualClient.getCurrentAssistant())==null?void 0:rt.graph_id);if(!tt)throw new Error("Agent name is required. Please call init() first or provide agentName.");return this.createSession({sessionId:t,agentName:tt,restore:!0})}getActiveClient(){const t=this.getActiveSession();return(t==null?void 0:t.client)||null}async listRemoteSessions(t={}){return this.virtualClient.listThreads(t)}async syncFromRemote(t={}){var nt;const Ye=t.agentName||((nt=this.virtualClient.getCurrentAssistant())==null?void 0:nt.graph_id);if(!Ye)throw new Error("Agent name is required. Please call init() first or provide agentName.");const tt=await this.listRemoteSessions({limit:t.limit||100,sortBy:"updated_at",sortOrder:"desc"}),rt=[];for(const at of tt){const it=at.thread_id;if(this.sessions.has(it)){const ot=this.sessions.get(it);ot.thread=at,rt.push(ot)}else{const ot={sessionId:it,thread:at,agentName:Ye};this.sessions.set(it,ot),rt.push(ot)}}return rt}async init(t,Ye){return this.virtualClient.initAssistant(t,Ye)}};const formatTime=e=>e.toLocaleTimeString(),getMessageContent=e=>typeof e=="string"?e:Array.isArray(e)?e.map(t=>typeof t=="string"?t:t.type==="text"?t.text:t.type==="image_url"?"[图片]":JSON.stringify(t)).join(""):JSON.stringify(e),getHistoryContent=e=>{var Ye,tt,rt;const t=e.title||e.name||((rt=(tt=(Ye=e==null?void 0:e.values)==null?void 0:Ye.messages)==null?void 0:tt[0])==null?void 0:rt.content);return t&&Array.isArray(t)?t.map(nt=>nt.type==="text"?nt.text:void 0).filter(Boolean):typeof t=="string"?t:""},createChatStore=(e,t,Ye={})=>{const tt=atom(null),rt=atom([]),nt=atom(null),at=atom([]),it=atom([]),ot=atom(""),ct=atom(null),At=atom(e),Rt=atom(null),qt=atom("__start__"),Ft=atom([]),Ut=atom([]),Ht=atom(Ye.showHistory??!1),zt=atom(Ye.showGraph??!1),Yt=atom(null);let Gt=null;const Vt=atom(!1),Zt=()=>{const ur=nt.get();ur&&Vt.set(ur.status==="busy")},Xt=r$5(ur=>{if(nt.get()!==ur)return;const cr=ur.renderMessage,yr=cr[cr.length-1];qt.set((yr==null?void 0:yr.node_name)||(yr==null?void 0:yr.name)||"__start__"),it.set(cr)},10),Qt=async()=>{const ur=nt.get();ur&&(ur.tools.clearTools(),ur.tools.bindTools(Ft.get()))},er=async()=>{var ur;zt.get()&&Yt.set(await((ur=nt.get())==null?void 0:ur.graphVisualize())||null)};async function nr(){const ur=new History$1({...t,client:t.client??await createLangGraphServerClient(t)});await ur.init(At.get(),{fallbackToAvailableAssistants:Ye.fallbackToAvailableAssistants}),tt.set(ur),await ar();const cr=rt.get();return Ye.autoRestoreLastSession&&cr.length>0?await fr(cr[0].sessionId):await sr(),ur}async function ar(){const ur=tt.get();if(ur)try{const cr=await ur.syncFromRemote({limit:100});rt.set(cr),at.set(cr.filter(yr=>yr.thread).map(yr=>yr.thread))}catch(cr){console.error("Failed to sync sessions:",cr)}}async function sr(){const ur=tt.get();if(ur)try{const cr=await ur.createSession();await ar(),await fr(cr.sessionId)}catch(cr){console.error("Failed to create new session:",cr),ct.set(cr.message)}}function lr(ur){const cr=()=>nt.get()===ur,yr=()=>{cr()&&Zt()},ir=()=>{if(!cr())return;const Ir=ur.getCurrentThread();Rt.set((Ir==null?void 0:Ir.thread_id)||null),qt.set("__start__");const kr=tt.get(),Mr=kr==null?void 0:kr.getActiveSession();Mr&&Ir&&(Mr.thread=Ir),ar()},or=()=>{cr()&&(Zt(),Xt(ur))},hr=Ir=>{cr()&&(Zt(),ct.set(Ir.data))},Sr=()=>{var Ir;cr()&&(Rt.set(((Ir=ur.getCurrentThread())==null?void 0:Ir.thread_id)||null),Zt(),Xt(ur))},wr=()=>{var Ir;cr()&&(Rt.set(((Ir=ur.getCurrentThread())==null?void 0:Ir.thread_id)||null),Zt(),Xt(ur))};return ur.on("start",yr),ur.on("thread",ir),ur.on("done",or),ur.on("error",hr),ur.on("message",Sr),ur.on("value",wr),()=>{ur.off("start",yr),ur.off("thread",ir),ur.off("done",or),ur.off("error",hr),ur.off("message",Sr),ur.off("value",wr)}}async function fr(ur){var yr;const cr=tt.get();if(cr)try{Gt&&(Gt(),Gt=null),ct.set(null);const or=(await cr.activateSession(ur)).client;if(or){Gt=lr(or),(yr=Ye.onInit)==null||yr.call(Ye,or),nt.set(or),Rt.set(ur);const hr=or.renderMessage;it.set(hr);const Sr=hr[hr.length-1];qt.set((Sr==null?void 0:Sr.node_name)||(Sr==null?void 0:Sr.name)||"__start__"),Zt(),zt.get()&&er(),Qt();const wr=or.getCurrentThread();wr&&(wr.status==="running"||wr.status==="pending")&&await or.resetStream()}}catch(ir){console.error("Failed to activate session:",ir),ct.set(ir.message)}}async function gr(ur,cr,yr=!1){const ir=nt.get();if(!(!yr&&!ot.get().trim()&&!(ur!=null&&ur.length)||!ir)&&ir.status!=="busy"){ct.set(null);try{await ir.sendMessage(ur||ot.get(),cr)}catch(or){if(or.message.includes("422"))await ir.resetStream();else throw or}finally{ot.set(""),Zt()}}}function dr(){var ur;(ur=nt.get())==null||ur.cancelRun()}function vr(ur){const cr=Ut.get();Ut.set(cr.includes(ur)?cr.filter(yr=>yr!==ur):[...cr,ur])}function mr(){Ht.set(!Ht.get()),Ht.get()&&ar()}function Er(ur){const cr=at.get();at.set([ur,...cr])}function _r(ur){var or;const cr=nt.get();if(!cr)return null;const ir=(or=cr.tools.getAllTools().find(hr=>hr.name===ur))==null?void 0:or.render;return ir?hr=>ir(new ToolRenderData(hr,cr)):null}const Tr=useArtifacts$1(it,nt);return{data:{client:nt,history:tt,sessions:rt,renderMessages:it,userInput:ot,loading:Vt,inChatError:ct,currentAgent:At,currentChatId:Rt,currentNodeName:qt,tools:Ft,collapsedTools:Ut,showGraph:zt,graphVisualize:Yt,showHistory:Ht,historyList:at,...Tr.data},mutations:{initClient:nr,getClient:()=>nt.get(),getHistory:()=>tt.get(),activateSession:fr,createNewSession:sr,refreshSessionList:ar,refreshHistoryList:ar,sendMessage:gr,stopGeneration:dr,setUserInput:ur=>ot.set(ur),async revertChatTo(ur,cr=!1,yr){var ir;if(await((ir=nt.get())==null?void 0:ir.revertChatTo(ur,yr||{})),cr)return gr([],yr,!0);Xt(nt.get())},refreshTools:Qt,setTools(ur){Ft.set(ur),Qt()},toggleToolCollapse:vr,getToolUIRender:_r,isFELocking:()=>{var ur;return(ur=nt.get())==null?void 0:ur.isFELocking(it.get())},toggleHistoryVisible:mr,toggleGraphVisible(){zt.set(!zt.get()),zt.get()&&er()},refreshGraph:er,setCurrentAgent(ur){return At.set(ur),nr()},addToHistory:Er,createNewChat:sr,toHistoryChat:ur=>fr(ur.thread_id),async deleteHistoryChat(ur){const cr=tt.get();cr&&(await cr.deleteSession(ur.thread_id),await ar())},...Tr.mutation}}},useUnionStore=(e,t)=>({...Object.fromEntries(Object.entries(e.data).map(([tt,rt])=>[tt,t(rt)])),...e.mutations});let emit=(e,t)=>Ye=>{e.current!==Ye&&(e.current=Ye,t())};function useStore$1(e,{keys:t,deps:Ye=[e,t]}={}){let tt=reactExports.useRef();tt.current=e.get();let rt=reactExports.useCallback(at=>(emit(tt,at)(e.value),(t==null?void 0:t.length)>0?listenKeys(e,t,emit(tt,at)):e.listen(emit(tt,at))),Ye),nt=()=>tt.current;return reactExports.useSyncExternalStore(rt,nt,nt)}const ChatContext=reactExports.createContext(void 0),useChat=()=>{const e=reactExports.useContext(ChatContext);if(!e)throw new Error("useChat must be used within a ChatProvider");return e},ChatProvider=({children:e,defaultAgent:t="",apiUrl:Ye="http://localhost:8123",defaultHeaders:tt,withCredentials:rt=!1,showHistory:nt=!1,showGraph:at=!1,fallbackToAvailableAssistants:it=!1,autoRestoreLastSession:ot=!1,onInitError:ct,client:At,legacyMode:Rt=!1})=>{const qt=reactExports.useMemo(()=>tt||{},[tt]),Ft=reactExports.useRef(ct);reactExports.useEffect(()=>{Ft.current=ct},[ct]);const Ut=reactExports.useMemo(()=>{const Gt={apiUrl:Ye,defaultHeaders:qt,callerOptions:{fetch:rt?(Vt,Zt)=>(Zt.credentials="include",fetch(Vt,Zt)):fetch,maxRetries:1},legacyMode:Rt};return At&&(Gt.client=At),createChatStore(t,Gt,{showHistory:nt,showGraph:at,fallbackToAvailableAssistants:it,autoRestoreLastSession:ot})},[t,Ye,qt,rt,nt,at,it,ot]),Ht=useUnionStore(Ut,useStore$1),zt=reactExports.useRef(!1);return reactExports.useEffect(()=>{zt.current||(zt.current=!0,Ht.initClient().then(Yt=>{Ht.showHistory&&Ht.refreshHistoryList()}).catch(Yt=>{console.error(Yt),Ft.current&&Ft.current(Yt,Ht.currentAgent)}))},[Ht]),reactExports.createElement(ChatContext.Provider,{value:Ht},e)};/**
80
+ ]`;continue}rt+=tt[ct],tt[ct]==="\\"?nt=!0:at&&tt[ct]==="]"?at=!1:!at&&tt[ct]==="["&&(at=!0)}try{new RegExp(rt)}catch{return console.warn(`Could not convert regex pattern at ${t.currentPath.join("/")} to a flag-independent form! Falling back to the flag-ignorant source`),e.source}return rt}function parseRecordDef(e,t){var tt,rt,nt,at,it,ot;if(t.target==="openAi"&&console.warn("Warning: OpenAI may not support records in schemas! Try an array of key-value pairs instead."),t.target==="openApi3"&&((tt=e.keyType)==null?void 0:tt._def.typeName)===ZodFirstPartyTypeKind.ZodEnum)return{type:"object",required:e.keyType._def.values,properties:e.keyType._def.values.reduce((ct,At)=>({...ct,[At]:parseDef(e.valueType._def,{...t,currentPath:[...t.currentPath,"properties",At]})??parseAnyDef(t)}),{}),additionalProperties:t.rejectedAdditionalProperties};const Ye={type:"object",additionalProperties:parseDef(e.valueType._def,{...t,currentPath:[...t.currentPath,"additionalProperties"]})??t.allowedAdditionalProperties};if(t.target==="openApi3")return Ye;if(((rt=e.keyType)==null?void 0:rt._def.typeName)===ZodFirstPartyTypeKind.ZodString&&((nt=e.keyType._def.checks)!=null&&nt.length)){const{type:ct,...At}=parseStringDef(e.keyType._def,t);return{...Ye,propertyNames:At}}else{if(((at=e.keyType)==null?void 0:at._def.typeName)===ZodFirstPartyTypeKind.ZodEnum)return{...Ye,propertyNames:{enum:e.keyType._def.values}};if(((it=e.keyType)==null?void 0:it._def.typeName)===ZodFirstPartyTypeKind.ZodBranded&&e.keyType._def.type._def.typeName===ZodFirstPartyTypeKind.ZodString&&((ot=e.keyType._def.type._def.checks)!=null&&ot.length)){const{type:ct,...At}=parseBrandedDef(e.keyType._def,t);return{...Ye,propertyNames:At}}}return Ye}function parseMapDef(e,t){if(t.mapStrategy==="record")return parseRecordDef(e,t);const Ye=parseDef(e.keyType._def,{...t,currentPath:[...t.currentPath,"items","items","0"]})||parseAnyDef(t),tt=parseDef(e.valueType._def,{...t,currentPath:[...t.currentPath,"items","items","1"]})||parseAnyDef(t);return{type:"array",maxItems:125,items:{type:"array",items:[Ye,tt],minItems:2,maxItems:2}}}function parseNativeEnumDef(e){const t=e.values,tt=Object.keys(e.values).filter(nt=>typeof t[t[nt]]!="number").map(nt=>t[nt]),rt=Array.from(new Set(tt.map(nt=>typeof nt)));return{type:rt.length===1?rt[0]==="string"?"string":"number":["string","number"],enum:tt}}function parseNeverDef(e){return e.target==="openAi"?void 0:{not:parseAnyDef({...e,currentPath:[...e.currentPath,"not"]})}}function parseNullDef(e){return e.target==="openApi3"?{enum:["null"],nullable:!0}:{type:"null"}}const primitiveMappings={ZodString:"string",ZodNumber:"number",ZodBigInt:"integer",ZodBoolean:"boolean",ZodNull:"null"};function parseUnionDef(e,t){if(t.target==="openApi3")return asAnyOf(e,t);const Ye=e.options instanceof Map?Array.from(e.options.values()):e.options;if(Ye.every(tt=>tt._def.typeName in primitiveMappings&&(!tt._def.checks||!tt._def.checks.length))){const tt=Ye.reduce((rt,nt)=>{const at=primitiveMappings[nt._def.typeName];return at&&!rt.includes(at)?[...rt,at]:rt},[]);return{type:tt.length>1?tt:tt[0]}}else if(Ye.every(tt=>tt._def.typeName==="ZodLiteral"&&!tt.description)){const tt=Ye.reduce((rt,nt)=>{const at=typeof nt._def.value;switch(at){case"string":case"number":case"boolean":return[...rt,at];case"bigint":return[...rt,"integer"];case"object":if(nt._def.value===null)return[...rt,"null"];case"symbol":case"undefined":case"function":default:return rt}},[]);if(tt.length===Ye.length){const rt=tt.filter((nt,at,it)=>it.indexOf(nt)===at);return{type:rt.length>1?rt:rt[0],enum:Ye.reduce((nt,at)=>nt.includes(at._def.value)?nt:[...nt,at._def.value],[])}}}else if(Ye.every(tt=>tt._def.typeName==="ZodEnum"))return{type:"string",enum:Ye.reduce((tt,rt)=>[...tt,...rt._def.values.filter(nt=>!tt.includes(nt))],[])};return asAnyOf(e,t)}const asAnyOf=(e,t)=>{const Ye=(e.options instanceof Map?Array.from(e.options.values()):e.options).map((tt,rt)=>parseDef(tt._def,{...t,currentPath:[...t.currentPath,"anyOf",`${rt}`]})).filter(tt=>!!tt&&(!t.strictUnions||typeof tt=="object"&&Object.keys(tt).length>0));return Ye.length?{anyOf:Ye}:void 0};function parseNullableDef(e,t){if(["ZodString","ZodNumber","ZodBigInt","ZodBoolean","ZodNull"].includes(e.innerType._def.typeName)&&(!e.innerType._def.checks||!e.innerType._def.checks.length))return t.target==="openApi3"?{type:primitiveMappings[e.innerType._def.typeName],nullable:!0}:{type:[primitiveMappings[e.innerType._def.typeName],"null"]};if(t.target==="openApi3"){const tt=parseDef(e.innerType._def,{...t,currentPath:[...t.currentPath]});return tt&&"$ref"in tt?{allOf:[tt],nullable:!0}:tt&&{...tt,nullable:!0}}const Ye=parseDef(e.innerType._def,{...t,currentPath:[...t.currentPath,"anyOf","0"]});return Ye&&{anyOf:[Ye,{type:"null"}]}}function parseNumberDef(e,t){const Ye={type:"number"};if(!e.checks)return Ye;for(const tt of e.checks)switch(tt.kind){case"int":Ye.type="integer",addErrorMessage(Ye,"type",tt.message,t);break;case"min":t.target==="jsonSchema7"?tt.inclusive?setResponseValueAndErrors(Ye,"minimum",tt.value,tt.message,t):setResponseValueAndErrors(Ye,"exclusiveMinimum",tt.value,tt.message,t):(tt.inclusive||(Ye.exclusiveMinimum=!0),setResponseValueAndErrors(Ye,"minimum",tt.value,tt.message,t));break;case"max":t.target==="jsonSchema7"?tt.inclusive?setResponseValueAndErrors(Ye,"maximum",tt.value,tt.message,t):setResponseValueAndErrors(Ye,"exclusiveMaximum",tt.value,tt.message,t):(tt.inclusive||(Ye.exclusiveMaximum=!0),setResponseValueAndErrors(Ye,"maximum",tt.value,tt.message,t));break;case"multipleOf":setResponseValueAndErrors(Ye,"multipleOf",tt.value,tt.message,t);break}return Ye}function parseObjectDef(e,t){const Ye=t.target==="openAi",tt={type:"object",properties:{}},rt=[],nt=e.shape();for(const it in nt){let ot=nt[it];if(ot===void 0||ot._def===void 0)continue;let ct=safeIsOptional(ot);ct&&Ye&&(ot._def.typeName==="ZodOptional"&&(ot=ot._def.innerType),ot.isNullable()||(ot=ot.nullable()),ct=!1);const At=parseDef(ot._def,{...t,currentPath:[...t.currentPath,"properties",it],propertyPath:[...t.currentPath,"properties",it]});At!==void 0&&(tt.properties[it]=At,ct||rt.push(it))}rt.length&&(tt.required=rt);const at=decideAdditionalProperties(e,t);return at!==void 0&&(tt.additionalProperties=at),tt}function decideAdditionalProperties(e,t){if(e.catchall._def.typeName!=="ZodNever")return parseDef(e.catchall._def,{...t,currentPath:[...t.currentPath,"additionalProperties"]});switch(e.unknownKeys){case"passthrough":return t.allowedAdditionalProperties;case"strict":return t.rejectedAdditionalProperties;case"strip":return t.removeAdditionalStrategy==="strict"?t.allowedAdditionalProperties:t.rejectedAdditionalProperties}}function safeIsOptional(e){try{return e.isOptional()}catch{return!0}}const parseOptionalDef=(e,t)=>{var tt;if(t.currentPath.toString()===((tt=t.propertyPath)==null?void 0:tt.toString()))return parseDef(e.innerType._def,t);const Ye=parseDef(e.innerType._def,{...t,currentPath:[...t.currentPath,"anyOf","1"]});return Ye?{anyOf:[{not:parseAnyDef(t)},Ye]}:parseAnyDef(t)},parsePipelineDef=(e,t)=>{if(t.pipeStrategy==="input")return parseDef(e.in._def,t);if(t.pipeStrategy==="output")return parseDef(e.out._def,t);const Ye=parseDef(e.in._def,{...t,currentPath:[...t.currentPath,"allOf","0"]}),tt=parseDef(e.out._def,{...t,currentPath:[...t.currentPath,"allOf",Ye?"1":"0"]});return{allOf:[Ye,tt].filter(rt=>rt!==void 0)}};function parsePromiseDef(e,t){return parseDef(e.type._def,t)}function parseSetDef(e,t){const tt={type:"array",uniqueItems:!0,items:parseDef(e.valueType._def,{...t,currentPath:[...t.currentPath,"items"]})};return e.minSize&&setResponseValueAndErrors(tt,"minItems",e.minSize.value,e.minSize.message,t),e.maxSize&&setResponseValueAndErrors(tt,"maxItems",e.maxSize.value,e.maxSize.message,t),tt}function parseTupleDef(e,t){return e.rest?{type:"array",minItems:e.items.length,items:e.items.map((Ye,tt)=>parseDef(Ye._def,{...t,currentPath:[...t.currentPath,"items",`${tt}`]})).reduce((Ye,tt)=>tt===void 0?Ye:[...Ye,tt],[]),additionalItems:parseDef(e.rest._def,{...t,currentPath:[...t.currentPath,"additionalItems"]})}:{type:"array",minItems:e.items.length,maxItems:e.items.length,items:e.items.map((Ye,tt)=>parseDef(Ye._def,{...t,currentPath:[...t.currentPath,"items",`${tt}`]})).reduce((Ye,tt)=>tt===void 0?Ye:[...Ye,tt],[])}}function parseUndefinedDef(e){return{not:parseAnyDef(e)}}function parseUnknownDef(e){return parseAnyDef(e)}const parseReadonlyDef=(e,t)=>parseDef(e.innerType._def,t),selectParser=(e,t,Ye)=>{switch(t){case ZodFirstPartyTypeKind.ZodString:return parseStringDef(e,Ye);case ZodFirstPartyTypeKind.ZodNumber:return parseNumberDef(e,Ye);case ZodFirstPartyTypeKind.ZodObject:return parseObjectDef(e,Ye);case ZodFirstPartyTypeKind.ZodBigInt:return parseBigintDef(e,Ye);case ZodFirstPartyTypeKind.ZodBoolean:return parseBooleanDef();case ZodFirstPartyTypeKind.ZodDate:return parseDateDef(e,Ye);case ZodFirstPartyTypeKind.ZodUndefined:return parseUndefinedDef(Ye);case ZodFirstPartyTypeKind.ZodNull:return parseNullDef(Ye);case ZodFirstPartyTypeKind.ZodArray:return parseArrayDef(e,Ye);case ZodFirstPartyTypeKind.ZodUnion:case ZodFirstPartyTypeKind.ZodDiscriminatedUnion:return parseUnionDef(e,Ye);case ZodFirstPartyTypeKind.ZodIntersection:return parseIntersectionDef(e,Ye);case ZodFirstPartyTypeKind.ZodTuple:return parseTupleDef(e,Ye);case ZodFirstPartyTypeKind.ZodRecord:return parseRecordDef(e,Ye);case ZodFirstPartyTypeKind.ZodLiteral:return parseLiteralDef(e,Ye);case ZodFirstPartyTypeKind.ZodEnum:return parseEnumDef(e);case ZodFirstPartyTypeKind.ZodNativeEnum:return parseNativeEnumDef(e);case ZodFirstPartyTypeKind.ZodNullable:return parseNullableDef(e,Ye);case ZodFirstPartyTypeKind.ZodOptional:return parseOptionalDef(e,Ye);case ZodFirstPartyTypeKind.ZodMap:return parseMapDef(e,Ye);case ZodFirstPartyTypeKind.ZodSet:return parseSetDef(e,Ye);case ZodFirstPartyTypeKind.ZodLazy:return()=>e.getter()._def;case ZodFirstPartyTypeKind.ZodPromise:return parsePromiseDef(e,Ye);case ZodFirstPartyTypeKind.ZodNaN:case ZodFirstPartyTypeKind.ZodNever:return parseNeverDef(Ye);case ZodFirstPartyTypeKind.ZodEffects:return parseEffectsDef(e,Ye);case ZodFirstPartyTypeKind.ZodAny:return parseAnyDef(Ye);case ZodFirstPartyTypeKind.ZodUnknown:return parseUnknownDef(Ye);case ZodFirstPartyTypeKind.ZodDefault:return parseDefaultDef(e,Ye);case ZodFirstPartyTypeKind.ZodBranded:return parseBrandedDef(e,Ye);case ZodFirstPartyTypeKind.ZodReadonly:return parseReadonlyDef(e,Ye);case ZodFirstPartyTypeKind.ZodCatch:return parseCatchDef(e,Ye);case ZodFirstPartyTypeKind.ZodPipeline:return parsePipelineDef(e,Ye);case ZodFirstPartyTypeKind.ZodFunction:case ZodFirstPartyTypeKind.ZodVoid:case ZodFirstPartyTypeKind.ZodSymbol:return;default:return(tt=>{})()}};function parseDef(e,t,Ye=!1){var it;const tt=t.seen.get(e);if(t.override){const ot=(it=t.override)==null?void 0:it.call(t,e,t,tt,Ye);if(ot!==ignoreOverride)return ot}if(tt&&!Ye){const ot=get$ref(tt,t);if(ot!==void 0)return ot}const rt={def:e,path:t.currentPath,jsonSchema:void 0};t.seen.set(e,rt);const nt=selectParser(e,e.typeName,t),at=typeof nt=="function"?parseDef(nt(),t):nt;if(at&&addMeta(e,t,at),t.postProcess){const ot=t.postProcess(at,e,t);return rt.jsonSchema=at,ot}return rt.jsonSchema=at,at}const get$ref=(e,t)=>{switch(t.$refStrategy){case"root":return{$ref:e.path.join("/")};case"relative":return{$ref:getRelativePath(t.currentPath,e.path)};case"none":case"seen":return e.path.length<t.currentPath.length&&e.path.every((Ye,tt)=>t.currentPath[tt]===Ye)?(console.warn(`Recursive reference detected at ${t.currentPath.join("/")}! Defaulting to any`),parseAnyDef(t)):t.$refStrategy==="seen"?parseAnyDef(t):void 0}},addMeta=(e,t,Ye)=>(e.description&&(Ye.description=e.description,t.markdownDescription&&(Ye.markdownDescription=e.description)),Ye),zodToJsonSchema=(e,t)=>{const Ye=getRefs(t);let tt;const rt=t==null?void 0:t.name,nt=parseDef(e._def,Ye,!1)??parseAnyDef(Ye);Ye.flags.hasReferencedOpenAiAnyType&&(tt||(tt={}),tt[Ye.openAiAnyTypeName]||(tt[Ye.openAiAnyTypeName]={type:["string","number","integer","boolean","array","null"],items:{$ref:Ye.$refStrategy==="relative"?"1":[...Ye.basePath,Ye.definitionPath,Ye.openAiAnyTypeName].join("/")}}));const at=rt===void 0?tt?{...nt,[Ye.definitionPath]:tt}:nt:{$ref:[...Ye.$refStrategy==="relative"?[]:Ye.basePath,Ye.definitionPath,rt].join("/"),[Ye.definitionPath]:{...tt,[rt]:nt}};return Ye.target==="jsonSchema7"?at.$schema="http://json-schema.org/draft-07/schema#":(Ye.target==="jsonSchema2019-09"||Ye.target==="openAi")&&(at.$schema="https://json-schema.org/draft/2019-09/schema#"),Ye.target==="openAi"&&("anyOf"in at||"oneOf"in at||"allOf"in at||"type"in at&&Array.isArray(at.type))&&console.warn("Warning: OpenAI may not support schemas with unions as roots! Try wrapping it in an object property."),at},createUITool=e=>{const t=e.execute||(async(Ye,tt)=>{var rt;try{const nt=await((rt=e.handler)==null?void 0:rt.call(e,Ye,tt));return typeof nt=="string"?[{type:"text",text:nt}]:nt.decisions?nt:[{type:"text",text:JSON.stringify(nt)}]}catch(nt){return[{type:"text",text:`Error: ${nt}`}]}});return{...e,execute:t}},createJSONDefineTool=e=>({name:e.name,description:e.description,parameters:e.isPureParams?e.parameters:zodToJsonSchema(object(e.parameters))});class ToolManager{constructor(){Cr(this,"tools",new Map);Cr(this,"waitingMap",new Map)}bindTool(t){this.tools.has(t.name)&&t.name!=="__default__"&&console.warn(`Tool with name ${t.name} already exists`),this.tools.set(t.name,t)}bindTools(t){t.forEach(Ye=>this.bindTool(Ye))}getAllTools(){return Array.from(this.tools.values())}getTool(t){return this.tools.get(t)}removeTool(t){return this.tools.delete(t)}clearTools(){this.tools.clear()}reset(){this.clearTools(),this.clearWaiting()}clearWaiting(){this.waitingMap.clear()}async callTool(t,Ye,tt){var nt;const rt=this.getTool(t)||this.getTool("__default__");return await((nt=rt.execute)==null?void 0:nt.call(rt,Ye,tt))}async toJSON(t,Ye=!0){return Array.from(this.tools.values()).filter(tt=>Ye?!tt.onlyRender:!0).filter(tt=>!tt.allowGraph||tt.allowGraph.includes(t)).map(tt=>createJSONDefineTool(tt))}doneWaiting(t,Ye){return this.waitingMap.has(t)?(this.waitingMap.get(t)(Ye),this.waitingMap.delete(t),!0):(console.warn(`Waiting for tool ${t} not found`),!1)}isAllToolCompleted(){return this.waitingMap.size}waitForDone(t){return new Promise((tt,rt)=>{this.waitingMap.set(t,tt)})}static waitForUIDone(t,Ye){return Ye.client.tools.waitForDone(Ye.message.id)}}class StreamingMessageType{static isTool(t){return t.type==="tool"}static isToolAssistant(t){var Ye,tt;return t.type==="ai"&&(((Ye=t.tool_calls)==null?void 0:Ye.length)||((tt=t.tool_call_chunks)==null?void 0:tt.length))}}class MessageProcessor{constructor(){Cr(this,"streamingMessage",[]);Cr(this,"graphMessages",[])}getStreamingMessages(){return[...this.streamingMessage]}setStreamingMessages(t){this.streamingMessage=t}clearStreamingMessages(){this.streamingMessage=[]}getGraphMessages(){return[...this.graphMessages]}setGraphMessages(t){this.graphMessages=t}updateStreamingMessage(t){const Ye=this.streamingMessage[this.streamingMessage.length-1];if(!(Ye!=null&&Ye.id)||t.id!==Ye.id){this.streamingMessage.push(t);return}this.streamingMessage[this.streamingMessage.length-1]=t}combineGraphMessagesWithStreamingMessages(){const t=new Map(this.streamingMessage.map(Ye=>[Ye.id,Ye]));return[...this.graphMessages.map(Ye=>{if(t.has(Ye.id)){const tt=t.get(Ye.id);return t.delete(Ye.id),tt}return Ye}),...t.values()]}cloneMessage(t){return JSON.parse(JSON.stringify(t))}attachInfoForMessage(t){var rt,nt,at;let Ye=null;const tt=[...t];for(const it of tt){const ot=((rt=it.response_metadata)==null?void 0:rt.create_time)||"";if(it.unique_id=it.tool_call_id||it.id,it.spend_time=new Date(ot).getTime()-new Date(((nt=Ye==null?void 0:Ye.response_metadata)==null?void 0:nt.create_time)||ot).getTime(),!it.usage_metadata&&((at=it.response_metadata)!=null&&at.usage)){const ct=it.response_metadata.usage;it.usage_metadata={...ct,input_tokens:ct.prompt_tokens,output_tokens:ct.completion_tokens,total_tokens:ct.total_tokens}}Ye=it}return tt}composeToolMessages(t){var nt,at;const Ye=[],tt=new Map,rt=new Map;for(const it of t)if(!(StreamingMessageType.isToolAssistant(it)&&((nt=it.tool_calls||it.tool_call_chunks)==null||nt.forEach(ot=>{tt.set(ot.id,ot),rt.set(ot.id,it)}),!it.content))){if(StreamingMessageType.isTool(it)&&!it.tool_input){const ot=tt.get(it.tool_call_id),ct=rt.get(it.tool_call_id);if(ot){it.tool_input=typeof ot.args!="string"?JSON.stringify(ot.args):ot.args;const At=!!it.content;it.done=At,it.additional_kwargs={...(ct==null?void 0:ct.additional_kwargs)||{},...it.additional_kwargs||{},done:At}}ct&&(it.usage_metadata=ct.usage_metadata,it.node_name=ct.name,it.name||(it.name=(at=ct.tool_calls.find(At=>At.id===it.tool_call_id))==null?void 0:at.name))}Ye.push(it)}return Ye}renderMessages(t,Ye,tt){var ot;const rt=new Map,nt=new Set,at=[],it=this.combineGraphMessagesWithStreamingMessages();for(let ct=it.length-1;ct>=0;ct--){const At=this.cloneMessage(it[ct]);if(!At.id){at.unshift(At);continue}if(At.type==="ai"&&(At.name||(At.name=Ye().name)),StreamingMessageType.isToolAssistant(At)){const Rt=At;rt.set(At.id,Rt);const Ft=((ot=Rt.tool_calls)!=null&&ot.length?Rt.tool_calls:Rt.tool_call_chunks).filter(Ut=>!nt.has(Ut.id)).map((Ut,Ht)=>{var zt,Yt,Gt,Vt;return{type:"tool",additional_kwargs:{},tool_input:(Vt=(Gt=(Yt=(zt=Rt.additional_kwargs)==null?void 0:zt.tool_calls)==null?void 0:Yt[Ht])==null?void 0:Gt.function)==null?void 0:Vt.arguments,id:Ut.id,name:Ut.name,response_metadata:{},tool_call_id:Ut.id,content:""}});for(const Ut of Ft)rt.has(Ut.id)||(at.unshift(Ut),rt.set(Ut.id,Ut));at.unshift(Rt)}else At.type==="tool"&&At.tool_call_id&&nt.add(At.tool_call_id),rt.set(At.id,At),at.unshift(At)}return this.processMessages(at,t,tt)}foldTreeMessages(t,Ye,tt){const rt=Object.entries((Ye==null?void 0:Ye.task_store)||{}).map(([At,Rt])=>[At,Rt.messages]),nt=new Map(rt),at=new Set,it=new Map(Object.entries(tt||{}).map(([At,Rt])=>{if(Rt!=null&&Rt.parent_id)return at.add(At),[At,Rt==null?void 0:Rt.parent_id]}).filter(At=>At!==void 0)),ot=nt,ct=[];for(const At of t)if(!at.has(At.id))ct.push(At);else{const qt=it.get(At.id),Ft=ot.get(qt);Ft?Ft.push(At):ot.set(qt,[At])}for(const At of ct)if(At.sub_messages=ot.get(At.id)||[],At.type==="tool"&&ot.has(At.tool_call_id)){At.sub_messages.unshift(...ot.get(At.tool_call_id));const Rt=At.sub_messages.filter((qt,Ft,Ut)=>Ut.findIndex(Ht=>Ht.id===qt.id)===Ft);At.sub_messages=this.beforeFold(Rt)}return ct}beforeFold(t){const Ye=this.composeToolMessages(t);return this.attachInfoForMessage(Ye)}processMessages(t,Ye,tt){return this.foldTreeMessages(this.beforeFold(t),Ye,tt)}}async function revertChatTo(e,t,Ye,tt){const rt=await e.threads.get(t),nt=rt.values.messages,at=nt.findIndex(Rt=>Rt.id===Ye);if(at===-1)throw new Error(`Message id ${Ye} not found`);const it=tt.includeMessageId?at:at+1,ot=nt.slice(it),ct={...rt.values,messages:ot.map(Rt=>({type:"remove",id:Rt.id}))},At=await e.threads.updateState(t,{values:ct});return{state:{messages:nt.slice(0,it)},checkpoint:At}}const isObject$4=e=>typeof e=="object"&&e!==null,isObjectCustom=e=>isObject$4(e)&&!(e instanceof RegExp)&&!(e instanceof Error)&&!(e instanceof Date)&&!(globalThis.Blob&&e instanceof globalThis.Blob),mapObjectSkip=Symbol("mapObjectSkip"),_mapObject=(e,t,Ye,tt=new WeakMap)=>{if(Ye={deep:!1,target:{},...Ye},tt.has(e))return tt.get(e);tt.set(e,Ye.target);const{target:rt}=Ye;delete Ye.target;const nt=at=>at.map(it=>isObjectCustom(it)?_mapObject(it,t,Ye,tt):it);if(Array.isArray(e))return nt(e);for(const[at,it]of Object.entries(e)){const ot=t(at,it,e);if(ot===mapObjectSkip)continue;let[ct,At,{shouldRecurse:Rt=!0}={}]=ot;ct!=="__proto__"&&(Ye.deep&&Rt&&isObjectCustom(At)&&(At=Array.isArray(At)?nt(At):_mapObject(At,t,Ye,tt)),rt[ct]=At)}return rt};function mapObject(e,t,Ye){if(!isObject$4(e))throw new TypeError(`Expected an object, got \`${e}\` (${typeof e})`);if(Array.isArray(e))throw new TypeError("Expected an object, got an array");return _mapObject(e,t,Ye)}const UPPERCASE=/[\p{Lu}]/u,LOWERCASE=/[\p{Ll}]/u,LEADING_CAPITAL=/^[\p{Lu}](?![\p{Lu}])/gu,IDENTIFIER=/([\p{Alpha}\p{N}_]|$)/u,SEPARATORS=/[_.\- ]+/,LEADING_SEPARATORS=new RegExp("^"+SEPARATORS.source),SEPARATORS_AND_IDENTIFIER=new RegExp(SEPARATORS.source+IDENTIFIER.source,"gu"),NUMBERS_AND_IDENTIFIER=new RegExp("\\d+"+IDENTIFIER.source,"gu"),preserveCamelCase=(e,t,Ye,tt)=>{let rt=!1,nt=!1,at=!1,it=!1;for(let ot=0;ot<e.length;ot++){const ct=e[ot];it=ot>2?e[ot-3]==="-":!0,rt&&UPPERCASE.test(ct)?(e=e.slice(0,ot)+"-"+e.slice(ot),rt=!1,at=nt,nt=!0,ot++):nt&&at&&LOWERCASE.test(ct)&&(!it||tt)?(e=e.slice(0,ot-1)+"-"+e.slice(ot-1),at=nt,nt=!1,rt=!0):(rt=t(ct)===ct&&Ye(ct)!==ct,at=nt,nt=Ye(ct)===ct&&t(ct)!==ct)}return e},preserveConsecutiveUppercase=(e,t)=>(LEADING_CAPITAL.lastIndex=0,e.replaceAll(LEADING_CAPITAL,Ye=>t(Ye))),postProcess=(e,t)=>(SEPARATORS_AND_IDENTIFIER.lastIndex=0,NUMBERS_AND_IDENTIFIER.lastIndex=0,e.replaceAll(NUMBERS_AND_IDENTIFIER,(Ye,tt,rt)=>["_","-"].includes(e.charAt(rt+Ye.length))?Ye:t(Ye)).replaceAll(SEPARATORS_AND_IDENTIFIER,(Ye,tt)=>t(tt)));function camelCase(e,t){if(!(typeof e=="string"||Array.isArray(e)))throw new TypeError("Expected the input to be `string | string[]`");if(t={pascalCase:!1,preserveConsecutiveUppercase:!1,...t},Array.isArray(e)?e=e.map(nt=>nt.trim()).filter(nt=>nt.length).join("-"):e=e.trim(),e.length===0)return"";const Ye=t.locale===!1?nt=>nt.toLowerCase():nt=>nt.toLocaleLowerCase(t.locale),tt=t.locale===!1?nt=>nt.toUpperCase():nt=>nt.toLocaleUpperCase(t.locale);return e.length===1?SEPARATORS.test(e)?"":t.pascalCase?tt(e):Ye(e):(e!==Ye(e)&&(e=preserveCamelCase(e,Ye,tt,t.preserveConsecutiveUppercase)),e=e.replace(LEADING_SEPARATORS,""),e=t.preserveConsecutiveUppercase?preserveConsecutiveUppercase(e,Ye):Ye(e),t.pascalCase&&(e=tt(e.charAt(0))+e.slice(1)),postProcess(e,tt))}var ja,Bn,Yn,cs,vo,ds,An,Iu,ri,Zh,ef,tf,rf,Xh,Nu;class QuickLRU extends Map{constructor(Ye={}){super();Na(this,An);Na(this,ja,0);Na(this,Bn,new Map);Na(this,Yn,new Map);Na(this,cs);Na(this,vo);Na(this,ds);if(!(Ye.maxSize&&Ye.maxSize>0))throw new TypeError("`maxSize` must be a number greater than 0");if(typeof Ye.maxAge=="number"&&Ye.maxAge===0)throw new TypeError("`maxAge` must be a number greater than 0");$n(this,cs,Ye.maxSize),$n(this,vo,Ye.maxAge||Number.POSITIVE_INFINITY),$n(this,ds,Ye.onEviction)}get __oldCache(){return Qr(this,Yn)}get(Ye){if(Qr(this,Bn).has(Ye)){const tt=Qr(this,Bn).get(Ye);return jn(this,An,ef).call(this,Ye,tt)}if(Qr(this,Yn).has(Ye)){const tt=Qr(this,Yn).get(Ye);if(jn(this,An,ri).call(this,Ye,tt)===!1)return jn(this,An,Xh).call(this,Ye,tt),tt.value}}set(Ye,tt,{maxAge:rt=Qr(this,vo)}={}){const nt=typeof rt=="number"&&rt!==Number.POSITIVE_INFINITY?Date.now()+rt:void 0;return Qr(this,Bn).has(Ye)?Qr(this,Bn).set(Ye,{value:tt,expiry:nt}):jn(this,An,rf).call(this,Ye,{value:tt,expiry:nt}),this}has(Ye){return Qr(this,Bn).has(Ye)?!jn(this,An,ri).call(this,Ye,Qr(this,Bn).get(Ye)):Qr(this,Yn).has(Ye)?!jn(this,An,ri).call(this,Ye,Qr(this,Yn).get(Ye)):!1}peek(Ye){if(Qr(this,Bn).has(Ye))return jn(this,An,tf).call(this,Ye,Qr(this,Bn));if(Qr(this,Yn).has(Ye))return jn(this,An,tf).call(this,Ye,Qr(this,Yn))}expiresIn(Ye){const tt=Qr(this,Bn).get(Ye)??Qr(this,Yn).get(Ye);if(tt)return tt.expiry?tt.expiry-Date.now():Number.POSITIVE_INFINITY}delete(Ye){const tt=Qr(this,Bn).delete(Ye);return tt&&Xd(this,ja)._--,Qr(this,Yn).delete(Ye)||tt}clear(){Qr(this,Bn).clear(),Qr(this,Yn).clear(),$n(this,ja,0)}resize(Ye){if(!(Ye&&Ye>0))throw new TypeError("`maxSize` must be a number greater than 0");const tt=[...jn(this,An,Nu).call(this)],rt=tt.length-Ye;rt<0?($n(this,Bn,new Map(tt)),$n(this,Yn,new Map),$n(this,ja,tt.length)):(rt>0&&jn(this,An,Iu).call(this,tt.slice(0,rt)),$n(this,Yn,new Map(tt.slice(rt))),$n(this,Bn,new Map),$n(this,ja,0)),$n(this,cs,Ye)}evict(Ye=1){const tt=Number(Ye);if(!tt||tt<=0)return;const rt=[...jn(this,An,Nu).call(this)],nt=Math.trunc(Math.min(tt,Math.max(rt.length-1,0)));nt<=0||(jn(this,An,Iu).call(this,rt.slice(0,nt)),$n(this,Yn,new Map(rt.slice(nt))),$n(this,Bn,new Map),$n(this,ja,0))}*keys(){for(const[Ye]of this)yield Ye}*values(){for(const[,Ye]of this)yield Ye}*[Symbol.iterator](){for(const Ye of Qr(this,Bn)){const[tt,rt]=Ye;jn(this,An,ri).call(this,tt,rt)===!1&&(yield[tt,rt.value])}for(const Ye of Qr(this,Yn)){const[tt,rt]=Ye;Qr(this,Bn).has(tt)||jn(this,An,ri).call(this,tt,rt)===!1&&(yield[tt,rt.value])}}*entriesDescending(){let Ye=[...Qr(this,Bn)];for(let tt=Ye.length-1;tt>=0;--tt){const rt=Ye[tt],[nt,at]=rt;jn(this,An,ri).call(this,nt,at)===!1&&(yield[nt,at.value])}Ye=[...Qr(this,Yn)];for(let tt=Ye.length-1;tt>=0;--tt){const rt=Ye[tt],[nt,at]=rt;Qr(this,Bn).has(nt)||jn(this,An,ri).call(this,nt,at)===!1&&(yield[nt,at.value])}}*entriesAscending(){for(const[Ye,tt]of jn(this,An,Nu).call(this))yield[Ye,tt.value]}get size(){if(!Qr(this,ja))return Qr(this,Yn).size;let Ye=0;for(const tt of Qr(this,Yn).keys())Qr(this,Bn).has(tt)||Ye++;return Math.min(Qr(this,ja)+Ye,Qr(this,cs))}get maxSize(){return Qr(this,cs)}get maxAge(){return Qr(this,vo)}entries(){return this.entriesAscending()}forEach(Ye,tt=this){for(const[rt,nt]of this.entriesAscending())Ye.call(tt,nt,rt,this)}get[Symbol.toStringTag](){return"QuickLRU"}toString(){return`QuickLRU(${this.size}/${this.maxSize})`}[Symbol.for("nodejs.util.inspect.custom")](){return this.toString()}}ja=new WeakMap,Bn=new WeakMap,Yn=new WeakMap,cs=new WeakMap,vo=new WeakMap,ds=new WeakMap,An=new WeakSet,Iu=function(Ye){if(typeof Qr(this,ds)=="function")for(const[tt,rt]of Ye)Qr(this,ds).call(this,tt,rt.value)},ri=function(Ye,tt){return typeof tt.expiry=="number"&&tt.expiry<=Date.now()?(typeof Qr(this,ds)=="function"&&Qr(this,ds).call(this,Ye,tt.value),this.delete(Ye)):!1},Zh=function(Ye,tt){if(jn(this,An,ri).call(this,Ye,tt)===!1)return tt.value},ef=function(Ye,tt){return tt.expiry?jn(this,An,Zh).call(this,Ye,tt):tt.value},tf=function(Ye,tt){const rt=tt.get(Ye);return jn(this,An,ef).call(this,Ye,rt)},rf=function(Ye,tt){Qr(this,Bn).set(Ye,tt),Xd(this,ja)._++,Qr(this,ja)>=Qr(this,cs)&&($n(this,ja,0),jn(this,An,Iu).call(this,Qr(this,Yn)),$n(this,Yn,Qr(this,Bn)),$n(this,Bn,new Map))},Xh=function(Ye,tt){Qr(this,Yn).delete(Ye),jn(this,An,rf).call(this,Ye,tt)},Nu=function*(){for(const Ye of Qr(this,Yn)){const[tt,rt]=Ye;Qr(this,Bn).has(tt)||jn(this,An,ri).call(this,tt,rt)===!1&&(yield Ye)}for(const Ye of Qr(this,Bn)){const[tt,rt]=Ye;jn(this,An,ri).call(this,tt,rt)===!1&&(yield Ye)}};const has$1=(e,t)=>e.some(Ye=>typeof Ye=="string"?Ye===t:(Ye.lastIndex=0,Ye.test(t))),isNumericKey=e=>e.trim()!==""&&!Number.isNaN(Number(e)),cache=new QuickLRU({maxSize:1e5}),isBuiltIn=e=>ArrayBuffer.isView(e)||e instanceof Date||e instanceof RegExp||e instanceof Error||e instanceof Map||e instanceof Set||e instanceof WeakMap||e instanceof WeakSet||e instanceof Promise,isObject$3=e=>typeof e=="object"&&e!==null&&!isBuiltIn(e),transform$4=(e,t={},Ye=new WeakMap,tt)=>{if(!isObject$3(e))return e;if(Ye.has(e))return Ye.get(e);const{exclude:rt,pascalCase:nt=!1,stopPaths:at,deep:it=!1,preserveConsecutiveUppercase:ot=!1}=t,ct=new Set(at);if(Array.isArray(e)){const Ut=[];Ye.set(e,Ut);for(const Ht of e)Ut.push(isObject$3(Ht)?transform$4(Ht,t,Ye,tt):Ht);return Ut}const At={};Ye.set(e,At);const qt=mapObject(e,(Ut=>(Ht,zt)=>{if(it&&isObject$3(zt)){const Yt=Ut===void 0?Ht:`${Ut}.${Ht}`;ct.has(Yt)||(zt=Array.isArray(zt)?zt.map(Gt=>isObject$3(Gt)?transform$4(Gt,t,Ye,Yt):Gt):transform$4(zt,t,Ye,Yt))}if(typeof Ht=="string"&&!isNumericKey(Ht)&&!(rt&&has$1(rt,Ht))){const Yt=nt?`${Ht}_`:Ht;if(cache.has(Yt))Ht=cache.get(Yt);else{const Gt=Ht.match(/^[_$]*/)[0],Vt=camelCase(Ht.slice(Gt.length),{pascalCase:nt,locale:!1,preserveConsecutiveUppercase:ot});Ht=Gt+Vt,Ht.length<100&&cache.set(Yt,Ht)}}return[Ht,zt]})(tt),{deep:!1});Object.assign(At,qt);const Ft=Object.getOwnPropertySymbols(e);for(const Ut of Ft)At[Ut]=it&&isObject$3(e[Ut])?transform$4(e[Ut],t,Ye,tt):e[Ut];return At};function camelcaseKeys(e,t){const Ye=new WeakMap;return Array.isArray(e)?e.map(tt=>isObject$3(tt)?transform$4(tt,t,Ye,void 0):tt):transform$4(e,t,Ye)}class LangGraphClient extends EventEmitter{constructor(Ye){super();Cr(this,"client");Cr(this,"currentAssistant",null);Cr(this,"currentThread",null);Cr(this,"tools",new ToolManager);Cr(this,"availableAssistants",[]);Cr(this,"graphState",{});Cr(this,"currentRun");Cr(this,"stopController",null);Cr(this,"messageProcessor");Cr(this,"legacyMode");Cr(this,"_status","idle");Cr(this,"messagesMetadata",{});Cr(this,"humanInTheLoop",null);Cr(this,"graphPosition","");Cr(this,"extraParams",{});this.client=Ye.client,this.legacyMode=Ye.legacyMode??!1,this.messageProcessor=new MessageProcessor}get assistants(){return this.client.assistants}get threads(){return this.client.threads}get runs(){return this.client.runs}get status(){return this._status}listAssistants(){return this.assistants.search({metadata:null,offset:0,limit:100})}async initAssistant(Ye,tt={}){try{const rt=await this.listAssistants();if(this.availableAssistants=rt,rt.length>0)if(Ye){if(this.currentAssistant=rt.find(nt=>nt.graph_id===Ye)||null,!this.currentAssistant){if(tt.fallbackToAvailableAssistants)return this.currentAssistant=this.availableAssistants[0],this.currentAssistant;throw new Error("Agent not found: "+Ye)}}else return this.currentAssistant=rt[0],this.currentAssistant;else throw new Error("No assistants found")}catch(rt){throw console.error("Failed to initialize LangGraphClient:",rt),rt}}async createThread({threadId:Ye,graphId:tt}={}){try{return this.currentThread=await this.threads.create({threadId:Ye,graphId:tt}),this.currentThread}catch(rt){throw console.error("Failed to create new thread:",rt),rt}}graphVisualize(){var Ye;return this.assistants.getGraph((Ye=this.currentAssistant)==null?void 0:Ye.assistant_id,{xray:!0})}async listThreads(Ye={}){return this.threads.search({sortOrder:Ye.sortOrder||"desc",sortBy:Ye.sortBy||"updated_at",offset:Ye.offset||0,limit:Ye.limit||10})}async deleteThread(Ye){return this.threads.delete(Ye)}async resetThread(Ye,tt){var nt;await this.initAssistant(Ye),this.currentThread=await this.threads.get(tt),this.graphState=this.currentThread.values;const rt=((nt=this.graphState)==null?void 0:nt.messages)||[];return this.messageProcessor.setGraphMessages(rt),this.emit("value",{event:"messages/partial",data:{messages:this.messageProcessor.getGraphMessages()}}),this.currentThread}async resetStream(){const Ye=await this.runs.list(this.currentThread.thread_id),tt=Ye==null?void 0:Ye.find(rt=>rt.status==="running"||rt.status==="pending");tt&&await this.sendMessage([],{joinRunId:tt.run_id})}cloneMessage(Ye){return this.messageProcessor.cloneMessage(Ye)}get renderMessage(){return this.messageProcessor.renderMessages(this.graphState,()=>this.getGraphNodeNow(),this.messagesMetadata)}get tokenCounter(){return this.messageProcessor.getGraphMessages().reduce((Ye,tt)=>{var rt,nt,at,it,ot;if(tt.usage_metadata)Ye.total_tokens+=((rt=tt.usage_metadata)==null?void 0:rt.total_tokens)||0,Ye.input_tokens+=((nt=tt.usage_metadata)==null?void 0:nt.input_tokens)||0,Ye.output_tokens+=((at=tt.usage_metadata)==null?void 0:at.output_tokens)||0;else if((it=tt.response_metadata)!=null&&it.usage){const ct=(ot=tt.response_metadata)==null?void 0:ot.usage;Ye.total_tokens+=ct.total_tokens||0,Ye.input_tokens+=ct.prompt_tokens||0,Ye.output_tokens+=ct.completion_tokens||0}return Ye},{total_tokens:0,input_tokens:0,output_tokens:0})}isFELocking(Ye){var nt;const tt=Ye[Ye.length-1];if(!tt)return!1;const rt=this.tools.getTool(tt==null?void 0:tt.name);return rt&&rt.render&&(tt==null?void 0:tt.type)==="tool"&&!((nt=tt==null?void 0:tt.additional_kwargs)!=null&&nt.done)}cancelRun(){var Ye,tt;(Ye=this.currentThread)!=null&&Ye.thread_id&&((tt=this.currentRun)!=null&&tt.run_id)&&this.runs.cancel(this.currentThread.thread_id,this.currentRun.run_id)}async revertChatTo(Ye,tt){const{state:rt,checkpoint:nt}=await revertChatTo(this.client,this.currentThread.thread_id,Ye,tt);return this.graphState=rt,this.messageProcessor.clearStreamingMessages(),this.messageProcessor.setGraphMessages(rt.messages),rt}async sendMessage(Ye,{joinRunId:tt,extraParams:rt,_debug:nt,command:at}={}){if(!this.currentAssistant)throw new Error("Thread or Assistant not initialized");this.currentThread||(await this.createThread({graphId:this.currentAssistant.graph_id}),this.emit("thread",{event:"thread/create",data:{thread:this.currentThread}}));const it=Array.isArray(Ye)?Ye:[{type:"human",content:Ye}],ot=[];this._status="busy",this.emit("start",{event:"start"});const At=await(async()=>{if(nt!=null&&nt.streamResponse)return nt.streamResponse;const qt=this.legacyMode?Ft=>{ot.push(Ft),this.processStreamChunk(Ft,at)}:void 0;return tt?this.runs.joinStream(this.currentThread.thread_id,tt,{onCallback:qt}):this.runs.stream(this.currentThread.thread_id,this.currentAssistant.assistant_id,{input:{...this.graphState,...this.extraParams,...rt||{},messages:it,fe_tools:await this.tools.toJSON(this.currentAssistant.graph_id)},streamMode:["messages","values"],streamSubgraphs:!0,command:at,onCallback:qt})})();if(!this.legacyMode)for await(const qt of At)ot.push(qt),this.processStreamChunk(qt,at);const Rt=await this.runFETool();return await this.responseHumanInTheLoop(),Rt&&ot.push(...Rt),this._status="idle",this.emit("done",{event:"done"}),this.messageProcessor.clearStreamingMessages(),ot}getGraphPosition(){return this.graphPosition.split("|").map(Ye=>{const[tt,rt]=Ye.split(":");return{id:rt,name:tt}})}getGraphNodeNow(){const Ye=this.getGraphPosition();return Ye[Ye.length-1]}processStreamChunk(Ye,tt){if(Ye.event==="metadata")this.currentRun=Ye.data;else if(Ye.event==="error"||Ye.event==="Error"||Ye.event==="__stream_error__")this._status="error",this.emit("error",Ye);else{if(Ye.event==="messages/metadata")return Object.assign(this.messagesMetadata,Ye.data),!0;if(Ye.event==="messages/partial"||Ye.event==="messages/complete"){for(const rt of Ye.data)this.messageProcessor.updateStreamingMessage(rt);return this.emit("message",Ye),!0}else if(Ye.event==="values"){const rt=Ye.data;if(rt!=null&&rt.__interrupt__){this._status="interrupted";const nt=rt==null?void 0:rt.__interrupt__.map(at=>at&&"review_configs"in at.value?{id:at.id,value:{actionRequests:at.value.action_requests,reviewConfigs:camelcaseKeys(at.value.review_configs,{deep:!0})}}:at);nt.forEach(at=>(at.value.actionRequests.forEach(it=>{it.id=it.id||createActionRequestID(it)}),at)),this.humanInTheLoop={interruptData:nt,result:{}}}else if(rt!=null&&rt.messages){const nt=!!(tt!=null&&tt.resume),at=rt.messages.length>=this.messageProcessor.getGraphMessages().length;(!nt||nt&&at)&&(this.messageProcessor.setGraphMessages(rt.messages),this.emit("value",Ye)),this.graphState=Ye.data}return!0}else Ye.event.startsWith("values|")&&(this.graphPosition=Ye.event.split("|")[1])}return!1}runFETool(){var rt;const Ye=this.messageProcessor.getStreamingMessages(),tt=Ye[Ye.length-1];if(tt&&tt.type==="ai"&&(rt=tt.tool_calls)!=null&&rt.length){const nt=tt.tool_calls.map(at=>{const it={...at,tool_call_id:at.id,tool_input:JSON.stringify(at.args),additional_kwargs:{}};return this.callFETool(it,at.args)});return this._status="interrupted",this.currentThread.status="interrupted",console.log("batch call tools",nt.length),Promise.all(nt)}}async responseHumanInTheLoop(){if(this.humanInTheLoop){const Ye=this.humanInTheLoop;return this.humanInTheLoop=null,this.resume({decisions:Ye.interruptData[0].value.actionRequests.map(tt=>Ye.result[tt.id])})}}async callFETool(Ye,tt){const rt=this;await this.tools.callTool(Ye.name,tt,{client:rt,message:Ye})}resume(Ye){return this.sendMessage([],{command:{resume:Ye}})}doneFEToolWaiting(Ye,tt){var nt;!this.tools.doneWaiting(Ye,tt)&&((nt=this.currentThread)==null?void 0:nt.status)==="interrupted"&&this.resume(tt)}doneHumanInTheLoopWaiting(Ye,tt,rt){this.tools.doneWaiting(Ye,rt),this.humanInTheLoop&&(this.humanInTheLoop.result[tt]=rt)}getCurrentThread(){return this.currentThread}getCurrentAssistant(){return this.currentAssistant}async reset(){var Ye;await this.initAssistant((Ye=this.currentAssistant)==null?void 0:Ye.graph_id),this.currentThread=null,this.graphState={},this.messageProcessor.setGraphMessages([]),this.messageProcessor.clearStreamingMessages(),this.currentRun=void 0,this.tools.clearWaiting(),this._status="idle",this.emit("value",{event:"messages/partial",data:{messages:[]}})}}let History$1=class{constructor(t){Cr(this,"sessions",new Map);Cr(this,"activeSessionId",null);Cr(this,"clientConfig");Cr(this,"virtualClient");this.clientConfig=t,this.virtualClient=new LangGraphClient(t)}async createSession(t={}){var nt;const Ye=t.sessionId||this.generateSessionId(),tt=t.agentName||((nt=this.virtualClient.getCurrentAssistant())==null?void 0:nt.graph_id);if(!tt)throw new Error("Agent name is required. Please call init() first or provide agentName.");if(this.sessions.has(Ye))throw new Error(`Session ${Ye} already exists`);const rt={sessionId:Ye,agentName:tt};return t.restore&&(rt.thread=await this.virtualClient.threads.get(Ye)),this.sessions.set(Ye,rt),rt}async activateSession(t){var rt,nt;const Ye=this.sessions.get(t);if(!Ye)throw new Error(`Session ${t} not found`);if(!Ye.client){const at=new LangGraphClient(this.clientConfig);await at.initAssistant(Ye.agentName),Ye.thread&&await at.resetThread(Ye.agentName,t),Ye.client=at}const tt=this.activeSessionId&&this.sessions.get(this.activeSessionId);return tt&&((rt=tt.client)==null?void 0:rt.status)==="idle"&&((nt=tt.client)==null||nt.reset(),tt.client=void 0),this.activeSessionId=t,Ye}getActiveSession(){return this.activeSessionId&&this.sessions.get(this.activeSessionId)||null}getSession(t){return this.sessions.get(t)||null}getAllSessions(){return Array.from(this.sessions.values())}async deleteSession(t){if(!this.sessions.get(t))return!1;this.activeSessionId===t&&(this.activeSessionId=null);try{await this.virtualClient.deleteThread(t)}catch(tt){console.warn(`Failed to delete thread for session ${t}:`,tt)}return this.sessions.delete(t),!0}async clearAllSessions(){const t=Array.from(this.sessions.keys());for(const Ye of t)await this.deleteSession(Ye);this.activeSessionId=null}getSessionCount(){return this.sessions.size}generateSessionId(){return typeof crypto<"u"&&crypto.randomUUID?crypto.randomUUID():"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,t=>{const Ye=Math.random()*16|0;return(t==="x"?Ye:Ye&3|8).toString(16)})}async addSessionFromThread(t,Ye){var rt;const tt=Ye||((rt=this.virtualClient.getCurrentAssistant())==null?void 0:rt.graph_id);if(!tt)throw new Error("Agent name is required. Please call init() first or provide agentName.");return this.createSession({sessionId:t,agentName:tt,restore:!0})}getActiveClient(){const t=this.getActiveSession();return(t==null?void 0:t.client)||null}async listRemoteSessions(t={}){return this.virtualClient.listThreads(t)}async syncFromRemote(t={}){var nt;const Ye=t.agentName||((nt=this.virtualClient.getCurrentAssistant())==null?void 0:nt.graph_id);if(!Ye)throw new Error("Agent name is required. Please call init() first or provide agentName.");const tt=await this.listRemoteSessions({limit:t.limit||100,sortBy:"updated_at",sortOrder:"desc"}),rt=[];for(const at of tt){const it=at.thread_id;if(this.sessions.has(it)){const ot=this.sessions.get(it);ot.thread=at,rt.push(ot)}else{const ot={sessionId:it,thread:at,agentName:Ye};this.sessions.set(it,ot),rt.push(ot)}}return rt}async init(t,Ye){return this.virtualClient.initAssistant(t,Ye)}};const formatTime=e=>e.toLocaleTimeString(),getMessageContent=e=>typeof e=="string"?e:Array.isArray(e)?e.map(t=>typeof t=="string"?t:t.type==="text"?t.text:t.type==="image_url"?"[图片]":JSON.stringify(t)).join(""):JSON.stringify(e),getHistoryContent=e=>{var Ye,tt,rt;const t=e.title||e.name||((rt=(tt=(Ye=e==null?void 0:e.values)==null?void 0:Ye.messages)==null?void 0:tt[0])==null?void 0:rt.content);return t&&Array.isArray(t)?t.map(nt=>nt.type==="text"?nt.text:void 0).filter(Boolean):typeof t=="string"?t:""},createChatStore=(e,t,Ye={})=>{const tt=atom(null),rt=atom([]),nt=atom(null),at=atom([]),it=atom([]),ot=atom(""),ct=atom(null),At=atom(e),Rt=atom(null),qt=atom("__start__"),Ft=atom([]),Ut=atom([]),Ht=atom(Ye.showHistory??!1),zt=atom(Ye.showGraph??!1),Yt=atom(null);let Gt=null;const Vt=atom(!1),Zt=()=>{const ur=nt.get();ur&&Vt.set(ur.status==="busy")},Xt=r$5(ur=>{if(nt.get()!==ur)return;const cr=ur.renderMessage,yr=cr[cr.length-1];qt.set((yr==null?void 0:yr.node_name)||(yr==null?void 0:yr.name)||"__start__"),it.set(cr)},10),Qt=async()=>{const ur=nt.get();ur&&(ur.tools.clearTools(),ur.tools.bindTools(Ft.get()))},er=async()=>{var ur;zt.get()&&Yt.set(await((ur=nt.get())==null?void 0:ur.graphVisualize())||null)};async function nr(){const ur=new History$1({...t,client:t.client??await createLangGraphServerClient(t)});await ur.init(At.get(),{fallbackToAvailableAssistants:Ye.fallbackToAvailableAssistants}),tt.set(ur),await ar();const cr=rt.get();return Ye.autoRestoreLastSession&&cr.length>0?await fr(cr[0].sessionId):await sr(),ur}async function ar(){const ur=tt.get();if(ur)try{const cr=await ur.syncFromRemote({limit:100});rt.set(cr),at.set(cr.filter(yr=>yr.thread).map(yr=>yr.thread))}catch(cr){console.error("Failed to sync sessions:",cr)}}async function sr(){const ur=tt.get();if(ur)try{const cr=await ur.createSession();await ar(),await fr(cr.sessionId)}catch(cr){console.error("Failed to create new session:",cr),ct.set(cr.message)}}function lr(ur){const cr=()=>nt.get()===ur,yr=()=>{cr()&&Zt()},ir=()=>{if(!cr())return;const Ir=ur.getCurrentThread();Rt.set((Ir==null?void 0:Ir.thread_id)||null),qt.set("__start__");const kr=tt.get(),Mr=kr==null?void 0:kr.getActiveSession();Mr&&Ir&&(Mr.thread=Ir),ar()},or=()=>{cr()&&(Zt(),Xt(ur))},hr=Ir=>{cr()&&(Zt(),ct.set(Ir.data))},Sr=()=>{var Ir;cr()&&(Rt.set(((Ir=ur.getCurrentThread())==null?void 0:Ir.thread_id)||null),Zt(),Xt(ur))},wr=()=>{var Ir;cr()&&(Rt.set(((Ir=ur.getCurrentThread())==null?void 0:Ir.thread_id)||null),Zt(),Xt(ur))};return ur.on("start",yr),ur.on("thread",ir),ur.on("done",or),ur.on("error",hr),ur.on("message",Sr),ur.on("value",wr),()=>{ur.off("start",yr),ur.off("thread",ir),ur.off("done",or),ur.off("error",hr),ur.off("message",Sr),ur.off("value",wr)}}async function fr(ur){var yr;const cr=tt.get();if(cr)try{Gt&&(Gt(),Gt=null),ct.set(null);const or=(await cr.activateSession(ur)).client;if(or){Gt=lr(or),(yr=Ye.onInit)==null||yr.call(Ye,or),nt.set(or),Rt.set(ur);const hr=or.renderMessage;it.set(hr);const Sr=hr[hr.length-1];qt.set((Sr==null?void 0:Sr.node_name)||(Sr==null?void 0:Sr.name)||"__start__"),Zt(),zt.get()&&er(),Qt();const wr=or.getCurrentThread();wr&&(wr.status==="running"||wr.status==="pending")&&await or.resetStream()}}catch(ir){console.error("Failed to activate session:",ir),ct.set(ir.message)}}async function gr(ur,cr,yr=!1){const ir=nt.get();if(!(!yr&&!ot.get().trim()&&!(ur!=null&&ur.length)||!ir)&&ir.status!=="busy"){ct.set(null);try{await ir.sendMessage(ur||ot.get(),cr)}catch(or){if(or.message.includes("422"))await ir.resetStream();else throw or}finally{ot.set(""),Zt()}}}function dr(){var ur;(ur=nt.get())==null||ur.cancelRun()}function vr(ur){const cr=Ut.get();Ut.set(cr.includes(ur)?cr.filter(yr=>yr!==ur):[...cr,ur])}function mr(){Ht.set(!Ht.get()),Ht.get()&&ar()}function Er(ur){const cr=at.get();at.set([ur,...cr])}function _r(ur){var or;const cr=nt.get();if(!cr)return null;const ir=(or=cr.tools.getAllTools().find(hr=>hr.name===ur))==null?void 0:or.render;return ir?hr=>ir(new ToolRenderData(hr,cr)):null}const Tr=useArtifacts$1(it,nt);return{data:{client:nt,history:tt,sessions:rt,renderMessages:it,userInput:ot,loading:Vt,inChatError:ct,currentAgent:At,currentChatId:Rt,currentNodeName:qt,tools:Ft,collapsedTools:Ut,showGraph:zt,graphVisualize:Yt,showHistory:Ht,historyList:at,...Tr.data},mutations:{initClient:nr,getClient:()=>nt.get(),getHistory:()=>tt.get(),activateSession:fr,createNewSession:sr,refreshSessionList:ar,refreshHistoryList:ar,sendMessage:gr,stopGeneration:dr,setUserInput:ur=>ot.set(ur),async revertChatTo(ur,cr=!1,yr){var ir;if(await((ir=nt.get())==null?void 0:ir.revertChatTo(ur,yr||{})),cr)return gr([],yr,!0);Xt(nt.get())},refreshTools:Qt,setTools(ur){Ft.set(ur),Qt()},toggleToolCollapse:vr,getToolUIRender:_r,isFELocking:()=>{var ur;return(ur=nt.get())==null?void 0:ur.isFELocking(it.get())},toggleHistoryVisible:mr,toggleGraphVisible(){zt.set(!zt.get()),zt.get()&&er()},refreshGraph:er,setCurrentAgent(ur){return At.set(ur),nr()},addToHistory:Er,createNewChat:sr,toHistoryChat:ur=>fr(ur.thread_id),async deleteHistoryChat(ur){const cr=tt.get();cr&&(await cr.deleteSession(ur.thread_id),await ar())},...Tr.mutation}}},useUnionStore=(e,t)=>({...Object.fromEntries(Object.entries(e.data).map(([tt,rt])=>[tt,t(rt)])),...e.mutations});let emit=(e,t)=>Ye=>{e.current!==Ye&&(e.current=Ye,t())};function useStore$1(e,{keys:t,deps:Ye=[e,t]}={}){let tt=reactExports.useRef();tt.current=e.get();let rt=reactExports.useCallback(at=>(emit(tt,at)(e.value),(t==null?void 0:t.length)>0?listenKeys(e,t,emit(tt,at)):e.listen(emit(tt,at))),Ye),nt=()=>tt.current;return reactExports.useSyncExternalStore(rt,nt,nt)}const ChatContext=reactExports.createContext(void 0),useChat=()=>{const e=reactExports.useContext(ChatContext);if(!e)throw new Error("useChat must be used within a ChatProvider");return e},ChatProvider=({children:e,defaultAgent:t="",apiUrl:Ye="http://localhost:8123",defaultHeaders:tt,withCredentials:rt=!1,showHistory:nt=!1,showGraph:at=!1,fallbackToAvailableAssistants:it=!1,autoRestoreLastSession:ot=!1,onInitError:ct,client:At,legacyMode:Rt=!1})=>{const qt=reactExports.useMemo(()=>tt||{},[tt]),Ft=reactExports.useRef(ct);reactExports.useEffect(()=>{Ft.current=ct},[ct]);const Ut=reactExports.useMemo(()=>{const Gt={apiUrl:Ye,defaultHeaders:qt,callerOptions:{fetch:rt?(Vt,Zt)=>(Zt.credentials="include",fetch(Vt,Zt)):fetch,maxRetries:1},legacyMode:Rt};return At&&(Gt.client=At),createChatStore(t,Gt,{showHistory:nt,showGraph:at,fallbackToAvailableAssistants:it,autoRestoreLastSession:ot})},[t,Ye,qt,rt,nt,at,it,ot]),Ht=useUnionStore(Ut,useStore$1),zt=reactExports.useRef(!1);return reactExports.useEffect(()=>{zt.current||(zt.current=!0,Ht.initClient().then(Yt=>{Ht.showHistory&&Ht.refreshHistoryList()}).catch(Yt=>{console.error(Yt),Ft.current&&Ft.current(Yt,Ht.currentAgent)}))},[Ht]),reactExports.createElement(ChatContext.Provider,{value:Ht},e)};/**
81
81
  * @license lucide-react v0.544.0 - ISC
82
82
  *
83
83
  * This source code is licensed under the ISC license.
@@ -782,7 +782,7 @@ ${t}</tr>
782
782
  `}tablecell(t){let Ye=this.parser.parseInline(t.tokens),tt=t.header?"th":"td";return(t.align?`<${tt} align="${t.align}">`:`<${tt}>`)+Ye+`</${tt}>
783
783
  `}strong({tokens:t}){return`<strong>${this.parser.parseInline(t)}</strong>`}em({tokens:t}){return`<em>${this.parser.parseInline(t)}</em>`}codespan({text:t}){return`<code>${w$1(t,!0)}</code>`}br(t){return"<br>"}del({tokens:t}){return`<del>${this.parser.parseInline(t)}</del>`}link({href:t,title:Ye,tokens:tt}){let rt=this.parser.parseInline(tt),nt=J$1(t);if(nt===null)return rt;t=nt;let at='<a href="'+t+'"';return Ye&&(at+=' title="'+w$1(Ye)+'"'),at+=">"+rt+"</a>",at}image({href:t,title:Ye,text:tt,tokens:rt}){rt&&(tt=this.parser.parseInline(rt,this.parser.textRenderer));let nt=J$1(t);if(nt===null)return w$1(tt);t=nt;let at=`<img src="${t}" alt="${tt}"`;return Ye&&(at+=` title="${w$1(Ye)}"`),at+=">",at}text(t){return"tokens"in t&&t.tokens?this.parser.parseInline(t.tokens):"escaped"in t&&t.escaped?t.text:w$1(t.text)}},$$1=class{strong({text:t}){return t}em({text:t}){return t}codespan({text:t}){return t}del({text:t}){return t}html({text:t}){return t}text({text:t}){return t}link({text:t}){return""+t}image({text:t}){return""+t}br(){return""}},b$1=class of{constructor(t){Cr(this,"options");Cr(this,"renderer");Cr(this,"textRenderer");this.options=t||T$1,this.options.renderer=this.options.renderer||new P$2,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new $$1}static parse(t,Ye){return new of(Ye).parse(t)}static parseInline(t,Ye){return new of(Ye).parseInline(t)}parse(t,Ye=!0){var rt,nt;let tt="";for(let at=0;at<t.length;at++){let it=t[at];if((nt=(rt=this.options.extensions)==null?void 0:rt.renderers)!=null&&nt[it.type]){let ct=it,At=this.options.extensions.renderers[ct.type].call({parser:this},ct);if(At!==!1||!["space","hr","heading","code","table","blockquote","list","html","def","paragraph","text"].includes(ct.type)){tt+=At||"";continue}}let ot=it;switch(ot.type){case"space":{tt+=this.renderer.space(ot);continue}case"hr":{tt+=this.renderer.hr(ot);continue}case"heading":{tt+=this.renderer.heading(ot);continue}case"code":{tt+=this.renderer.code(ot);continue}case"table":{tt+=this.renderer.table(ot);continue}case"blockquote":{tt+=this.renderer.blockquote(ot);continue}case"list":{tt+=this.renderer.list(ot);continue}case"html":{tt+=this.renderer.html(ot);continue}case"def":{tt+=this.renderer.def(ot);continue}case"paragraph":{tt+=this.renderer.paragraph(ot);continue}case"text":{let ct=ot,At=this.renderer.text(ct);for(;at+1<t.length&&t[at+1].type==="text";)ct=t[++at],At+=`
784
784
  `+this.renderer.text(ct);Ye?tt+=this.renderer.paragraph({type:"paragraph",raw:At,text:At,tokens:[{type:"text",raw:At,text:At,escaped:!0}]}):tt+=At;continue}default:{let ct='Token with "'+ot.type+'" type was not found.';if(this.options.silent)return console.error(ct),"";throw new Error(ct)}}}return tt}parseInline(t,Ye=this.renderer){var rt,nt;let tt="";for(let at=0;at<t.length;at++){let it=t[at];if((nt=(rt=this.options.extensions)==null?void 0:rt.renderers)!=null&&nt[it.type]){let ct=this.options.extensions.renderers[it.type].call({parser:this},it);if(ct!==!1||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(it.type)){tt+=ct||"";continue}}let ot=it;switch(ot.type){case"escape":{tt+=Ye.text(ot);break}case"html":{tt+=Ye.html(ot);break}case"link":{tt+=Ye.link(ot);break}case"image":{tt+=Ye.image(ot);break}case"strong":{tt+=Ye.strong(ot);break}case"em":{tt+=Ye.em(ot);break}case"codespan":{tt+=Ye.codespan(ot);break}case"br":{tt+=Ye.br(ot);break}case"del":{tt+=Ye.del(ot);break}case"text":{tt+=Ye.text(ot);break}default:{let ct='Token with "'+ot.type+'" type was not found.';if(this.options.silent)return console.error(ct),"";throw new Error(ct)}}}return tt}},ku,S$1=(ku=class{constructor(t){Cr(this,"options");Cr(this,"block");this.options=t||T$1}preprocess(t){return t}postprocess(t){return t}processAllTokens(t){return t}emStrongMask(t){return t}provideLexer(){return this.block?x$2.lex:x$2.lexInline}provideParser(){return this.block?b$1.parse:b$1.parseInline}},Cr(ku,"passThroughHooks",new Set(["preprocess","postprocess","processAllTokens","emStrongMask"])),Cr(ku,"passThroughHooksRespectAsync",new Set(["preprocess","postprocess","processAllTokens"])),ku),B$1=class{constructor(...t){Cr(this,"defaults",L$1());Cr(this,"options",this.setOptions);Cr(this,"parse",this.parseMarkdown(!0));Cr(this,"parseInline",this.parseMarkdown(!1));Cr(this,"Parser",b$1);Cr(this,"Renderer",P$2);Cr(this,"TextRenderer",$$1);Cr(this,"Lexer",x$2);Cr(this,"Tokenizer",y$1);Cr(this,"Hooks",S$1);this.use(...t)}walkTokens(t,Ye){var rt,nt;let tt=[];for(let at of t)switch(tt=tt.concat(Ye.call(this,at)),at.type){case"table":{let it=at;for(let ot of it.header)tt=tt.concat(this.walkTokens(ot.tokens,Ye));for(let ot of it.rows)for(let ct of ot)tt=tt.concat(this.walkTokens(ct.tokens,Ye));break}case"list":{let it=at;tt=tt.concat(this.walkTokens(it.items,Ye));break}default:{let it=at;(nt=(rt=this.defaults.extensions)==null?void 0:rt.childTokens)!=null&&nt[it.type]?this.defaults.extensions.childTokens[it.type].forEach(ot=>{let ct=it[ot].flat(1/0);tt=tt.concat(this.walkTokens(ct,Ye))}):it.tokens&&(tt=tt.concat(this.walkTokens(it.tokens,Ye)))}}return tt}use(...t){let Ye=this.defaults.extensions||{renderers:{},childTokens:{}};return t.forEach(tt=>{let rt={...tt};if(rt.async=this.defaults.async||rt.async||!1,tt.extensions&&(tt.extensions.forEach(nt=>{if(!nt.name)throw new Error("extension name required");if("renderer"in nt){let at=Ye.renderers[nt.name];at?Ye.renderers[nt.name]=function(...it){let ot=nt.renderer.apply(this,it);return ot===!1&&(ot=at.apply(this,it)),ot}:Ye.renderers[nt.name]=nt.renderer}if("tokenizer"in nt){if(!nt.level||nt.level!=="block"&&nt.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");let at=Ye[nt.level];at?at.unshift(nt.tokenizer):Ye[nt.level]=[nt.tokenizer],nt.start&&(nt.level==="block"?Ye.startBlock?Ye.startBlock.push(nt.start):Ye.startBlock=[nt.start]:nt.level==="inline"&&(Ye.startInline?Ye.startInline.push(nt.start):Ye.startInline=[nt.start]))}"childTokens"in nt&&nt.childTokens&&(Ye.childTokens[nt.name]=nt.childTokens)}),rt.extensions=Ye),tt.renderer){let nt=this.defaults.renderer||new P$2(this.defaults);for(let at in tt.renderer){if(!(at in nt))throw new Error(`renderer '${at}' does not exist`);if(["options","parser"].includes(at))continue;let it=at,ot=tt.renderer[it],ct=nt[it];nt[it]=(...At)=>{let Rt=ot.apply(nt,At);return Rt===!1&&(Rt=ct.apply(nt,At)),Rt||""}}rt.renderer=nt}if(tt.tokenizer){let nt=this.defaults.tokenizer||new y$1(this.defaults);for(let at in tt.tokenizer){if(!(at in nt))throw new Error(`tokenizer '${at}' does not exist`);if(["options","rules","lexer"].includes(at))continue;let it=at,ot=tt.tokenizer[it],ct=nt[it];nt[it]=(...At)=>{let Rt=ot.apply(nt,At);return Rt===!1&&(Rt=ct.apply(nt,At)),Rt}}rt.tokenizer=nt}if(tt.hooks){let nt=this.defaults.hooks||new S$1;for(let at in tt.hooks){if(!(at in nt))throw new Error(`hook '${at}' does not exist`);if(["options","block"].includes(at))continue;let it=at,ot=tt.hooks[it],ct=nt[it];S$1.passThroughHooks.has(at)?nt[it]=At=>{if(this.defaults.async&&S$1.passThroughHooksRespectAsync.has(at))return(async()=>{let qt=await ot.call(nt,At);return ct.call(nt,qt)})();let Rt=ot.call(nt,At);return ct.call(nt,Rt)}:nt[it]=(...At)=>{if(this.defaults.async)return(async()=>{let qt=await ot.apply(nt,At);return qt===!1&&(qt=await ct.apply(nt,At)),qt})();let Rt=ot.apply(nt,At);return Rt===!1&&(Rt=ct.apply(nt,At)),Rt}}rt.hooks=nt}if(tt.walkTokens){let nt=this.defaults.walkTokens,at=tt.walkTokens;rt.walkTokens=function(it){let ot=[];return ot.push(at.call(this,it)),nt&&(ot=ot.concat(nt.call(this,it))),ot}}this.defaults={...this.defaults,...rt}}),this}setOptions(t){return this.defaults={...this.defaults,...t},this}lexer(t,Ye){return x$2.lex(t,Ye??this.defaults)}parser(t,Ye){return b$1.parse(t,Ye??this.defaults)}parseMarkdown(t){return(Ye,tt)=>{let rt={...tt},nt={...this.defaults,...rt},at=this.onError(!!nt.silent,!!nt.async);if(this.defaults.async===!0&&rt.async===!1)return at(new Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));if(typeof Ye>"u"||Ye===null)return at(new Error("marked(): input parameter is undefined or null"));if(typeof Ye!="string")return at(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(Ye)+", string expected"));if(nt.hooks&&(nt.hooks.options=nt,nt.hooks.block=t),nt.async)return(async()=>{let it=nt.hooks?await nt.hooks.preprocess(Ye):Ye,ot=await(nt.hooks?await nt.hooks.provideLexer():t?x$2.lex:x$2.lexInline)(it,nt),ct=nt.hooks?await nt.hooks.processAllTokens(ot):ot;nt.walkTokens&&await Promise.all(this.walkTokens(ct,nt.walkTokens));let At=await(nt.hooks?await nt.hooks.provideParser():t?b$1.parse:b$1.parseInline)(ct,nt);return nt.hooks?await nt.hooks.postprocess(At):At})().catch(at);try{nt.hooks&&(Ye=nt.hooks.preprocess(Ye));let it=(nt.hooks?nt.hooks.provideLexer():t?x$2.lex:x$2.lexInline)(Ye,nt);nt.hooks&&(it=nt.hooks.processAllTokens(it)),nt.walkTokens&&this.walkTokens(it,nt.walkTokens);let ot=(nt.hooks?nt.hooks.provideParser():t?b$1.parse:b$1.parseInline)(it,nt);return nt.hooks&&(ot=nt.hooks.postprocess(ot)),ot}catch(it){return at(it)}}}onError(t,Ye){return tt=>{if(tt.message+=`
785
- Please report this to https://github.com/markedjs/marked.`,t){let rt="<p>An error occurred:</p><pre>"+w$1(tt.message+"",!0)+"</pre>";return Ye?Promise.resolve(rt):rt}if(Ye)return Promise.reject(tt);throw tt}}},_$1=new B$1;function k$2(e,t){return _$1.parse(e,t)}k$2.options=k$2.setOptions=function(e){return _$1.setOptions(e),k$2.defaults=_$1.defaults,G$2(k$2.defaults),k$2};k$2.getDefaults=L$1;k$2.defaults=T$1;k$2.use=function(...e){return _$1.use(...e),k$2.defaults=_$1.defaults,G$2(k$2.defaults),k$2};k$2.walkTokens=function(e,t){return _$1.walkTokens(e,t)};k$2.parseInline=_$1.parseInline;k$2.Parser=b$1;k$2.parser=b$1.parse;k$2.Renderer=P$2;k$2.TextRenderer=$$1;k$2.Lexer=x$2;k$2.lexer=x$2.lex;k$2.Tokenizer=y$1;k$2.Hooks=S$1;k$2.parse=k$2;k$2.options;k$2.setOptions;k$2.use;k$2.walkTokens;k$2.parseInline;b$1.parse;x$2.lex;var m$1=(...e)=>twMerge(clsx(e)),P$1=(e,t,Ye)=>{let tt=typeof t=="string"?new Blob([t],{type:Ye}):t,rt=URL.createObjectURL(tt),nt=document.createElement("a");nt.href=rt,nt.download=e,document.body.appendChild(nt),nt.click(),document.body.removeChild(nt),URL.revokeObjectURL(rt)},Ze$1=/<pre(\s|>)/,W$1=reactExports.createContext({code:""}),O$1=class{constructor(){this.lightHighlighter=null,this.darkHighlighter=null,this.lightTheme=null,this.darkTheme=null,this.loadedLanguages=new Set,this.initializationPromise=null}isLanguageSupported(t){return Object.hasOwn(bundledLanguages,t)}getFallbackLanguage(){return"text"}async ensureHighlightersInitialized(t,Ye){var tt,rt;let[nt,at]=t,it=createJavaScriptRegexEngine({forgiving:!0}),ot=!this.lightHighlighter||this.lightTheme!==nt,ct=!this.darkHighlighter||this.darkTheme!==at;(ot||ct)&&this.loadedLanguages.clear();let At=this.isLanguageSupported(Ye),Rt=!this.loadedLanguages.has(Ye)&&At;if(ot?(this.lightHighlighter=await createHighlighter({themes:[nt],langs:At?[Ye]:[],engine:it}),this.lightTheme=nt,At&&this.loadedLanguages.add(Ye)):Rt&&await((tt=this.lightHighlighter)==null?void 0:tt.loadLanguage(Ye)),ct){let qt=Rt?[...this.loadedLanguages].concat(At?[Ye]:[]):Array.from(this.loadedLanguages);this.darkHighlighter=await createHighlighter({themes:[at],langs:qt.length>0?qt:At?[Ye]:[],engine:it}),this.darkTheme=at}else Rt&&await((rt=this.darkHighlighter)==null?void 0:rt.loadLanguage(Ye));Rt&&this.loadedLanguages.add(Ye)}async highlightCode(t,Ye,tt,rt){var nt,at;this.initializationPromise&&await this.initializationPromise,this.initializationPromise=this.ensureHighlightersInitialized(tt,Ye),await this.initializationPromise,this.initializationPromise=null;let[it,ot]=tt,ct=this.isLanguageSupported(Ye)?Ye:this.getFallbackLanguage(),At=(nt=this.lightHighlighter)==null?void 0:nt.codeToHtml(t,{lang:ct,theme:it}),Rt=(at=this.darkHighlighter)==null?void 0:at.codeToHtml(t,{lang:ct,theme:ot}),qt=Ft=>rt?Ft.replace(Ze$1,`<pre class="${rt}"$1`):Ft;return[qt(At),qt(Rt)]}},et=new O$1,ee$1=({code:e,language:t,className:Ye,children:tt,preClassName:rt,...nt})=>{let[at,it]=reactExports.useState(""),[ot,ct]=reactExports.useState(""),At=reactExports.useRef(!1),[Rt,qt]=reactExports.useContext(X$2);return reactExports.useEffect(()=>(At.current=!0,et.highlightCode(e,t,[Rt,qt],rt).then(([Ft,Ut])=>{At.current&&(it(Ft),ct(Ut))}),()=>{At.current=!1}),[e,t,Rt,qt,rt]),jsxRuntimeExports.jsx(W$1.Provider,{value:{code:e},children:jsxRuntimeExports.jsxs("div",{className:"my-4 w-full overflow-hidden rounded-xl border","data-code-block-container":!0,"data-language":t,children:[jsxRuntimeExports.jsxs("div",{className:"flex items-center justify-between bg-muted/80 p-3 text-muted-foreground text-xs","data-code-block-header":!0,"data-language":t,children:[jsxRuntimeExports.jsx("span",{className:"ml-1 font-mono lowercase",children:t}),jsxRuntimeExports.jsx("div",{className:"flex items-center gap-2",children:tt})]}),jsxRuntimeExports.jsx("div",{className:"w-full",children:jsxRuntimeExports.jsxs("div",{className:"min-w-full",children:[jsxRuntimeExports.jsx("div",{className:m$1("overflow-x-auto dark:hidden",Ye),dangerouslySetInnerHTML:{__html:at},"data-code-block":!0,"data-language":t,...nt}),jsxRuntimeExports.jsx("div",{className:m$1("hidden overflow-x-auto dark:block",Ye),dangerouslySetInnerHTML:{__html:ot},"data-code-block":!0,"data-language":t,...nt})]})})]})})},Q$1={"1c":"1c","1c-query":"1cq",abap:"abap","actionscript-3":"as",ada:"ada",adoc:"adoc","angular-html":"html","angular-ts":"ts",apache:"conf",apex:"cls",apl:"apl",applescript:"applescript",ara:"ara",asciidoc:"adoc",asm:"asm",astro:"astro",awk:"awk",ballerina:"bal",bash:"sh",bat:"bat",batch:"bat",be:"be",beancount:"beancount",berry:"berry",bibtex:"bib",bicep:"bicep",blade:"blade.php",bsl:"bsl",c:"c","c#":"cs","c++":"cpp",cadence:"cdc",cairo:"cairo",cdc:"cdc",clarity:"clar",clj:"clj",clojure:"clj","closure-templates":"soy",cmake:"cmake",cmd:"cmd",cobol:"cob",codeowners:"CODEOWNERS",codeql:"ql",coffee:"coffee",coffeescript:"coffee","common-lisp":"lisp",console:"sh",coq:"v",cpp:"cpp",cql:"cql",crystal:"cr",cs:"cs",csharp:"cs",css:"css",csv:"csv",cue:"cue",cypher:"cql",d:"d",dart:"dart",dax:"dax",desktop:"desktop",diff:"diff",docker:"dockerfile",dockerfile:"dockerfile",dotenv:"env","dream-maker":"dm",edge:"edge",elisp:"el",elixir:"ex",elm:"elm","emacs-lisp":"el",erb:"erb",erl:"erl",erlang:"erl",f:"f","f#":"fs",f03:"f03",f08:"f08",f18:"f18",f77:"f77",f90:"f90",f95:"f95",fennel:"fnl",fish:"fish",fluent:"ftl",for:"for","fortran-fixed-form":"f","fortran-free-form":"f90",fs:"fs",fsharp:"fs",fsl:"fsl",ftl:"ftl",gdresource:"tres",gdscript:"gd",gdshader:"gdshader",genie:"gs",gherkin:"feature","git-commit":"gitcommit","git-rebase":"gitrebase",gjs:"js",gleam:"gleam","glimmer-js":"js","glimmer-ts":"ts",glsl:"glsl",gnuplot:"plt",go:"go",gql:"gql",graphql:"graphql",groovy:"groovy",gts:"gts",hack:"hack",haml:"haml",handlebars:"hbs",haskell:"hs",haxe:"hx",hbs:"hbs",hcl:"hcl",hjson:"hjson",hlsl:"hlsl",hs:"hs",html:"html","html-derivative":"html",http:"http",hxml:"hxml",hy:"hy",imba:"imba",ini:"ini",jade:"jade",java:"java",javascript:"js",jinja:"jinja",jison:"jison",jl:"jl",js:"js",json:"json",json5:"json5",jsonc:"jsonc",jsonl:"jsonl",jsonnet:"jsonnet",jssm:"jssm",jsx:"jsx",julia:"jl",kotlin:"kt",kql:"kql",kt:"kt",kts:"kts",kusto:"kql",latex:"tex",lean:"lean",lean4:"lean",less:"less",liquid:"liquid",lisp:"lisp",lit:"lit",llvm:"ll",log:"log",logo:"logo",lua:"lua",luau:"luau",make:"mak",makefile:"mak",markdown:"md",marko:"marko",matlab:"m",md:"md",mdc:"mdc",mdx:"mdx",mediawiki:"wiki",mermaid:"mmd",mips:"s",mipsasm:"s",mmd:"mmd",mojo:"mojo",move:"move",nar:"nar",narrat:"narrat",nextflow:"nf",nf:"nf",nginx:"conf",nim:"nim",nix:"nix",nu:"nu",nushell:"nu",objc:"m","objective-c":"m","objective-cpp":"mm",ocaml:"ml",pascal:"pas",perl:"pl",perl6:"p6",php:"php",plsql:"pls",po:"po",polar:"polar",postcss:"pcss",pot:"pot",potx:"potx",powerquery:"pq",powershell:"ps1",prisma:"prisma",prolog:"pl",properties:"properties",proto:"proto",protobuf:"proto",ps:"ps",ps1:"ps1",pug:"pug",puppet:"pp",purescript:"purs",py:"py",python:"py",ql:"ql",qml:"qml",qmldir:"qmldir",qss:"qss",r:"r",racket:"rkt",raku:"raku",razor:"cshtml",rb:"rb",reg:"reg",regex:"regex",regexp:"regexp",rel:"rel",riscv:"s",rs:"rs",rst:"rst",ruby:"rb",rust:"rs",sas:"sas",sass:"sass",scala:"scala",scheme:"scm",scss:"scss",sdbl:"sdbl",sh:"sh",shader:"shader",shaderlab:"shader",shell:"sh",shellscript:"sh",shellsession:"sh",smalltalk:"st",solidity:"sol",soy:"soy",sparql:"rq",spl:"spl",splunk:"spl",sql:"sql","ssh-config":"config",stata:"do",styl:"styl",stylus:"styl",svelte:"svelte",swift:"swift","system-verilog":"sv",systemd:"service",talon:"talon",talonscript:"talon",tasl:"tasl",tcl:"tcl",templ:"templ",terraform:"tf",tex:"tex",tf:"tf",tfvars:"tfvars",toml:"toml",ts:"ts","ts-tags":"ts",tsp:"tsp",tsv:"tsv",tsx:"tsx",turtle:"ttl",twig:"twig",typ:"typ",typescript:"ts",typespec:"tsp",typst:"typ",v:"v",vala:"vala",vb:"vb",verilog:"v",vhdl:"vhdl",vim:"vim",viml:"vim",vimscript:"vim",vue:"vue","vue-html":"html","vue-vine":"vine",vy:"vy",vyper:"vy",wasm:"wasm",wenyan:"wy",wgsl:"wgsl",wiki:"wiki",wikitext:"wiki",wit:"wit",wl:"wl",wolfram:"wl",xml:"xml",xsl:"xsl",yaml:"yaml",yml:"yml",zenscript:"zs",zig:"zig",zsh:"zsh",文言:"wy"},U$2=({onDownload:e,onError:t,language:Ye,children:tt,className:rt,code:nt,...at})=>{let{code:it}=reactExports.useContext(W$1),{isAnimating:ot}=reactExports.useContext(M$2),ct=nt??it,At=`file.${Ye&&Ye in Q$1?Q$1[Ye]:"txt"}`,Rt="text/plain",qt=()=>{try{P$1(At,ct,Rt),e==null||e()}catch(Ft){t==null||t(Ft)}};return jsxRuntimeExports.jsx("button",{className:m$1("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",rt),disabled:ot,onClick:qt,title:"Download file",type:"button",...at,children:tt??jsxRuntimeExports.jsx(Download$1,{size:14})})},z$2=({onCopy:e,onError:t,timeout:Ye=2e3,children:tt,className:rt,code:nt,...at})=>{let[it,ot]=reactExports.useState(!1),ct=reactExports.useRef(0),{code:At}=reactExports.useContext(W$1),{isAnimating:Rt}=reactExports.useContext(M$2),qt=nt??At,Ft=async()=>{var Ht;if(typeof window>"u"||!((Ht=navigator==null?void 0:navigator.clipboard)!=null&&Ht.writeText)){t==null||t(new Error("Clipboard API not available"));return}try{it||(await navigator.clipboard.writeText(qt),ot(!0),e==null||e(),ct.current=window.setTimeout(()=>ot(!1),Ye))}catch(zt){t==null||t(zt)}};reactExports.useEffect(()=>()=>{window.clearTimeout(ct.current)},[]);let Ut=it?Check$1:Copy$1;return jsxRuntimeExports.jsx("button",{className:m$1("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",rt),disabled:Rt,onClick:Ft,type:"button",...at,children:tt??jsxRuntimeExports.jsx(Ut,{size:14})})},te$1=({node:e,className:t,src:Ye,alt:tt,...rt})=>{let nt=async()=>{var at;if(Ye)try{let it=await(await fetch(Ye)).blob(),ot=new URL(Ye,window.location.origin).pathname.split("/").pop()||"",ct=ot.includes(".")&&((at=ot.split(".").pop())==null?void 0:at.length)<=4,At="";if(ct)At=ot;else{let Rt=it.type,qt="png";Rt.includes("jpeg")||Rt.includes("jpg")?qt="jpg":Rt.includes("png")?qt="png":Rt.includes("svg")?qt="svg":Rt.includes("gif")?qt="gif":Rt.includes("webp")&&(qt="webp"),At=`${(tt||ot||"image").replace(/\.[^/.]+$/,"")}.${qt}`}P$1(At,it,it.type)}catch(it){console.error("Failed to download image:",it)}};return Ye?jsxRuntimeExports.jsxs("div",{className:"group relative my-4 inline-block","data-streamdown":"image-wrapper",children:[jsxRuntimeExports.jsx("img",{alt:tt,className:m$1("max-w-full rounded-lg",t),"data-streamdown":"image",src:Ye,...rt}),jsxRuntimeExports.jsx("div",{className:"pointer-events-none absolute inset-0 hidden rounded-lg bg-black/10 group-hover:block"}),jsxRuntimeExports.jsx("button",{className:m$1("absolute right-2 bottom-2 flex h-8 w-8 cursor-pointer items-center justify-center rounded-md border border-border bg-background/90 shadow-sm backdrop-blur-sm transition-all duration-200 hover:bg-background","opacity-0 group-hover:opacity-100"),onClick:nt,title:"Download image",type:"button",children:jsxRuntimeExports.jsx(Download$1,{size:14})})]}):null},st=async e=>{let t={startOnLoad:!1,theme:"default",securityLevel:"strict",fontFamily:"monospace",suppressErrorRendering:!0,...e},Ye=(await __vitePreload(async()=>{const{default:tt}=await import("./mermaid.core-74bjT8p7.js").then(rt=>rt.aI);return{default:tt}},[])).default;return Ye.initialize(t),Ye},oe$1=({chart:e,className:t,config:Ye})=>{let[tt,rt]=reactExports.useState(null),[nt,at]=reactExports.useState(!0),[it,ot]=reactExports.useState(""),[ct,At]=reactExports.useState("");if(reactExports.useEffect(()=>{(async()=>{try{rt(null),at(!0);let qt=await st(Ye),Ft=e.split("").reduce((zt,Yt)=>(zt<<5)-zt+Yt.charCodeAt(0)|0,0),Ut=`mermaid-${Math.abs(Ft)}-${Date.now()}-${Math.random().toString(36).substring(2,9)}`,{svg:Ht}=await qt.render(Ut,e);ot(Ht),At(Ht)}catch(qt){if(!(ct||it)){let Ft=qt instanceof Error?qt.message:"Failed to render Mermaid chart";rt(Ft)}}finally{at(!1)}})()},[e,Ye]),nt&&!it&&!ct)return jsxRuntimeExports.jsx("div",{className:m$1("my-4 flex justify-center p-4",t),children:jsxRuntimeExports.jsxs("div",{className:"flex items-center space-x-2 text-muted-foreground",children:[jsxRuntimeExports.jsx("div",{className:"h-4 w-4 animate-spin rounded-full border-current border-b-2"}),jsxRuntimeExports.jsx("span",{className:"text-sm",children:"Loading diagram..."})]})});if(tt&&!it&&!ct)return jsxRuntimeExports.jsxs("div",{className:m$1("rounded-lg border border-red-200 bg-red-50 p-4",t),children:[jsxRuntimeExports.jsxs("p",{className:"font-mono text-red-700 text-sm",children:["Mermaid Error: ",tt]}),jsxRuntimeExports.jsxs("details",{className:"mt-2",children:[jsxRuntimeExports.jsx("summary",{className:"cursor-pointer text-red-600 text-xs",children:"Show Code"}),jsxRuntimeExports.jsx("pre",{className:"mt-2 overflow-x-auto rounded bg-red-100 p-2 text-red-800 text-xs",children:e})]})]});let Rt=it||ct;return jsxRuntimeExports.jsx("div",{"aria-label":"Mermaid chart",className:m$1("my-4 flex justify-center",t),dangerouslySetInnerHTML:{__html:Rt},role:"img"})};function le$1(e){var t,Ye;let tt=[],rt=[],nt=e.querySelectorAll("thead th");for(let it of nt)tt.push(((t=it.textContent)==null?void 0:t.trim())||"");let at=e.querySelectorAll("tbody tr");for(let it of at){let ot=[],ct=it.querySelectorAll("td");for(let At of ct)ot.push(((Ye=At.textContent)==null?void 0:Ye.trim())||"");rt.push(ot)}return{headers:tt,rows:rt}}function de$1(e){let{headers:t,rows:Ye}=e,tt=nt=>nt.includes(",")||nt.includes('"')||nt.includes(`
785
+ Please report this to https://github.com/markedjs/marked.`,t){let rt="<p>An error occurred:</p><pre>"+w$1(tt.message+"",!0)+"</pre>";return Ye?Promise.resolve(rt):rt}if(Ye)return Promise.reject(tt);throw tt}}},_$1=new B$1;function k$2(e,t){return _$1.parse(e,t)}k$2.options=k$2.setOptions=function(e){return _$1.setOptions(e),k$2.defaults=_$1.defaults,G$2(k$2.defaults),k$2};k$2.getDefaults=L$1;k$2.defaults=T$1;k$2.use=function(...e){return _$1.use(...e),k$2.defaults=_$1.defaults,G$2(k$2.defaults),k$2};k$2.walkTokens=function(e,t){return _$1.walkTokens(e,t)};k$2.parseInline=_$1.parseInline;k$2.Parser=b$1;k$2.parser=b$1.parse;k$2.Renderer=P$2;k$2.TextRenderer=$$1;k$2.Lexer=x$2;k$2.lexer=x$2.lex;k$2.Tokenizer=y$1;k$2.Hooks=S$1;k$2.parse=k$2;k$2.options;k$2.setOptions;k$2.use;k$2.walkTokens;k$2.parseInline;b$1.parse;x$2.lex;var m$1=(...e)=>twMerge(clsx(e)),P$1=(e,t,Ye)=>{let tt=typeof t=="string"?new Blob([t],{type:Ye}):t,rt=URL.createObjectURL(tt),nt=document.createElement("a");nt.href=rt,nt.download=e,document.body.appendChild(nt),nt.click(),document.body.removeChild(nt),URL.revokeObjectURL(rt)},Ze$1=/<pre(\s|>)/,W$1=reactExports.createContext({code:""}),O$1=class{constructor(){this.lightHighlighter=null,this.darkHighlighter=null,this.lightTheme=null,this.darkTheme=null,this.loadedLanguages=new Set,this.initializationPromise=null}isLanguageSupported(t){return Object.hasOwn(bundledLanguages,t)}getFallbackLanguage(){return"text"}async ensureHighlightersInitialized(t,Ye){var tt,rt;let[nt,at]=t,it=createJavaScriptRegexEngine({forgiving:!0}),ot=!this.lightHighlighter||this.lightTheme!==nt,ct=!this.darkHighlighter||this.darkTheme!==at;(ot||ct)&&this.loadedLanguages.clear();let At=this.isLanguageSupported(Ye),Rt=!this.loadedLanguages.has(Ye)&&At;if(ot?(this.lightHighlighter=await createHighlighter({themes:[nt],langs:At?[Ye]:[],engine:it}),this.lightTheme=nt,At&&this.loadedLanguages.add(Ye)):Rt&&await((tt=this.lightHighlighter)==null?void 0:tt.loadLanguage(Ye)),ct){let qt=Rt?[...this.loadedLanguages].concat(At?[Ye]:[]):Array.from(this.loadedLanguages);this.darkHighlighter=await createHighlighter({themes:[at],langs:qt.length>0?qt:At?[Ye]:[],engine:it}),this.darkTheme=at}else Rt&&await((rt=this.darkHighlighter)==null?void 0:rt.loadLanguage(Ye));Rt&&this.loadedLanguages.add(Ye)}async highlightCode(t,Ye,tt,rt){var nt,at;this.initializationPromise&&await this.initializationPromise,this.initializationPromise=this.ensureHighlightersInitialized(tt,Ye),await this.initializationPromise,this.initializationPromise=null;let[it,ot]=tt,ct=this.isLanguageSupported(Ye)?Ye:this.getFallbackLanguage(),At=(nt=this.lightHighlighter)==null?void 0:nt.codeToHtml(t,{lang:ct,theme:it}),Rt=(at=this.darkHighlighter)==null?void 0:at.codeToHtml(t,{lang:ct,theme:ot}),qt=Ft=>rt?Ft.replace(Ze$1,`<pre class="${rt}"$1`):Ft;return[qt(At),qt(Rt)]}},et=new O$1,ee$1=({code:e,language:t,className:Ye,children:tt,preClassName:rt,...nt})=>{let[at,it]=reactExports.useState(""),[ot,ct]=reactExports.useState(""),At=reactExports.useRef(!1),[Rt,qt]=reactExports.useContext(X$2);return reactExports.useEffect(()=>(At.current=!0,et.highlightCode(e,t,[Rt,qt],rt).then(([Ft,Ut])=>{At.current&&(it(Ft),ct(Ut))}),()=>{At.current=!1}),[e,t,Rt,qt,rt]),jsxRuntimeExports.jsx(W$1.Provider,{value:{code:e},children:jsxRuntimeExports.jsxs("div",{className:"my-4 w-full overflow-hidden rounded-xl border","data-code-block-container":!0,"data-language":t,children:[jsxRuntimeExports.jsxs("div",{className:"flex items-center justify-between bg-muted/80 p-3 text-muted-foreground text-xs","data-code-block-header":!0,"data-language":t,children:[jsxRuntimeExports.jsx("span",{className:"ml-1 font-mono lowercase",children:t}),jsxRuntimeExports.jsx("div",{className:"flex items-center gap-2",children:tt})]}),jsxRuntimeExports.jsx("div",{className:"w-full",children:jsxRuntimeExports.jsxs("div",{className:"min-w-full",children:[jsxRuntimeExports.jsx("div",{className:m$1("overflow-x-auto dark:hidden",Ye),dangerouslySetInnerHTML:{__html:at},"data-code-block":!0,"data-language":t,...nt}),jsxRuntimeExports.jsx("div",{className:m$1("hidden overflow-x-auto dark:block",Ye),dangerouslySetInnerHTML:{__html:ot},"data-code-block":!0,"data-language":t,...nt})]})})]})})},Q$1={"1c":"1c","1c-query":"1cq",abap:"abap","actionscript-3":"as",ada:"ada",adoc:"adoc","angular-html":"html","angular-ts":"ts",apache:"conf",apex:"cls",apl:"apl",applescript:"applescript",ara:"ara",asciidoc:"adoc",asm:"asm",astro:"astro",awk:"awk",ballerina:"bal",bash:"sh",bat:"bat",batch:"bat",be:"be",beancount:"beancount",berry:"berry",bibtex:"bib",bicep:"bicep",blade:"blade.php",bsl:"bsl",c:"c","c#":"cs","c++":"cpp",cadence:"cdc",cairo:"cairo",cdc:"cdc",clarity:"clar",clj:"clj",clojure:"clj","closure-templates":"soy",cmake:"cmake",cmd:"cmd",cobol:"cob",codeowners:"CODEOWNERS",codeql:"ql",coffee:"coffee",coffeescript:"coffee","common-lisp":"lisp",console:"sh",coq:"v",cpp:"cpp",cql:"cql",crystal:"cr",cs:"cs",csharp:"cs",css:"css",csv:"csv",cue:"cue",cypher:"cql",d:"d",dart:"dart",dax:"dax",desktop:"desktop",diff:"diff",docker:"dockerfile",dockerfile:"dockerfile",dotenv:"env","dream-maker":"dm",edge:"edge",elisp:"el",elixir:"ex",elm:"elm","emacs-lisp":"el",erb:"erb",erl:"erl",erlang:"erl",f:"f","f#":"fs",f03:"f03",f08:"f08",f18:"f18",f77:"f77",f90:"f90",f95:"f95",fennel:"fnl",fish:"fish",fluent:"ftl",for:"for","fortran-fixed-form":"f","fortran-free-form":"f90",fs:"fs",fsharp:"fs",fsl:"fsl",ftl:"ftl",gdresource:"tres",gdscript:"gd",gdshader:"gdshader",genie:"gs",gherkin:"feature","git-commit":"gitcommit","git-rebase":"gitrebase",gjs:"js",gleam:"gleam","glimmer-js":"js","glimmer-ts":"ts",glsl:"glsl",gnuplot:"plt",go:"go",gql:"gql",graphql:"graphql",groovy:"groovy",gts:"gts",hack:"hack",haml:"haml",handlebars:"hbs",haskell:"hs",haxe:"hx",hbs:"hbs",hcl:"hcl",hjson:"hjson",hlsl:"hlsl",hs:"hs",html:"html","html-derivative":"html",http:"http",hxml:"hxml",hy:"hy",imba:"imba",ini:"ini",jade:"jade",java:"java",javascript:"js",jinja:"jinja",jison:"jison",jl:"jl",js:"js",json:"json",json5:"json5",jsonc:"jsonc",jsonl:"jsonl",jsonnet:"jsonnet",jssm:"jssm",jsx:"jsx",julia:"jl",kotlin:"kt",kql:"kql",kt:"kt",kts:"kts",kusto:"kql",latex:"tex",lean:"lean",lean4:"lean",less:"less",liquid:"liquid",lisp:"lisp",lit:"lit",llvm:"ll",log:"log",logo:"logo",lua:"lua",luau:"luau",make:"mak",makefile:"mak",markdown:"md",marko:"marko",matlab:"m",md:"md",mdc:"mdc",mdx:"mdx",mediawiki:"wiki",mermaid:"mmd",mips:"s",mipsasm:"s",mmd:"mmd",mojo:"mojo",move:"move",nar:"nar",narrat:"narrat",nextflow:"nf",nf:"nf",nginx:"conf",nim:"nim",nix:"nix",nu:"nu",nushell:"nu",objc:"m","objective-c":"m","objective-cpp":"mm",ocaml:"ml",pascal:"pas",perl:"pl",perl6:"p6",php:"php",plsql:"pls",po:"po",polar:"polar",postcss:"pcss",pot:"pot",potx:"potx",powerquery:"pq",powershell:"ps1",prisma:"prisma",prolog:"pl",properties:"properties",proto:"proto",protobuf:"proto",ps:"ps",ps1:"ps1",pug:"pug",puppet:"pp",purescript:"purs",py:"py",python:"py",ql:"ql",qml:"qml",qmldir:"qmldir",qss:"qss",r:"r",racket:"rkt",raku:"raku",razor:"cshtml",rb:"rb",reg:"reg",regex:"regex",regexp:"regexp",rel:"rel",riscv:"s",rs:"rs",rst:"rst",ruby:"rb",rust:"rs",sas:"sas",sass:"sass",scala:"scala",scheme:"scm",scss:"scss",sdbl:"sdbl",sh:"sh",shader:"shader",shaderlab:"shader",shell:"sh",shellscript:"sh",shellsession:"sh",smalltalk:"st",solidity:"sol",soy:"soy",sparql:"rq",spl:"spl",splunk:"spl",sql:"sql","ssh-config":"config",stata:"do",styl:"styl",stylus:"styl",svelte:"svelte",swift:"swift","system-verilog":"sv",systemd:"service",talon:"talon",talonscript:"talon",tasl:"tasl",tcl:"tcl",templ:"templ",terraform:"tf",tex:"tex",tf:"tf",tfvars:"tfvars",toml:"toml",ts:"ts","ts-tags":"ts",tsp:"tsp",tsv:"tsv",tsx:"tsx",turtle:"ttl",twig:"twig",typ:"typ",typescript:"ts",typespec:"tsp",typst:"typ",v:"v",vala:"vala",vb:"vb",verilog:"v",vhdl:"vhdl",vim:"vim",viml:"vim",vimscript:"vim",vue:"vue","vue-html":"html","vue-vine":"vine",vy:"vy",vyper:"vy",wasm:"wasm",wenyan:"wy",wgsl:"wgsl",wiki:"wiki",wikitext:"wiki",wit:"wit",wl:"wl",wolfram:"wl",xml:"xml",xsl:"xsl",yaml:"yaml",yml:"yml",zenscript:"zs",zig:"zig",zsh:"zsh",文言:"wy"},U$2=({onDownload:e,onError:t,language:Ye,children:tt,className:rt,code:nt,...at})=>{let{code:it}=reactExports.useContext(W$1),{isAnimating:ot}=reactExports.useContext(M$2),ct=nt??it,At=`file.${Ye&&Ye in Q$1?Q$1[Ye]:"txt"}`,Rt="text/plain",qt=()=>{try{P$1(At,ct,Rt),e==null||e()}catch(Ft){t==null||t(Ft)}};return jsxRuntimeExports.jsx("button",{className:m$1("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",rt),disabled:ot,onClick:qt,title:"Download file",type:"button",...at,children:tt??jsxRuntimeExports.jsx(Download$1,{size:14})})},z$2=({onCopy:e,onError:t,timeout:Ye=2e3,children:tt,className:rt,code:nt,...at})=>{let[it,ot]=reactExports.useState(!1),ct=reactExports.useRef(0),{code:At}=reactExports.useContext(W$1),{isAnimating:Rt}=reactExports.useContext(M$2),qt=nt??At,Ft=async()=>{var Ht;if(typeof window>"u"||!((Ht=navigator==null?void 0:navigator.clipboard)!=null&&Ht.writeText)){t==null||t(new Error("Clipboard API not available"));return}try{it||(await navigator.clipboard.writeText(qt),ot(!0),e==null||e(),ct.current=window.setTimeout(()=>ot(!1),Ye))}catch(zt){t==null||t(zt)}};reactExports.useEffect(()=>()=>{window.clearTimeout(ct.current)},[]);let Ut=it?Check$1:Copy$1;return jsxRuntimeExports.jsx("button",{className:m$1("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",rt),disabled:Rt,onClick:Ft,type:"button",...at,children:tt??jsxRuntimeExports.jsx(Ut,{size:14})})},te$1=({node:e,className:t,src:Ye,alt:tt,...rt})=>{let nt=async()=>{var at;if(Ye)try{let it=await(await fetch(Ye)).blob(),ot=new URL(Ye,window.location.origin).pathname.split("/").pop()||"",ct=ot.includes(".")&&((at=ot.split(".").pop())==null?void 0:at.length)<=4,At="";if(ct)At=ot;else{let Rt=it.type,qt="png";Rt.includes("jpeg")||Rt.includes("jpg")?qt="jpg":Rt.includes("png")?qt="png":Rt.includes("svg")?qt="svg":Rt.includes("gif")?qt="gif":Rt.includes("webp")&&(qt="webp"),At=`${(tt||ot||"image").replace(/\.[^/.]+$/,"")}.${qt}`}P$1(At,it,it.type)}catch(it){console.error("Failed to download image:",it)}};return Ye?jsxRuntimeExports.jsxs("div",{className:"group relative my-4 inline-block","data-streamdown":"image-wrapper",children:[jsxRuntimeExports.jsx("img",{alt:tt,className:m$1("max-w-full rounded-lg",t),"data-streamdown":"image",src:Ye,...rt}),jsxRuntimeExports.jsx("div",{className:"pointer-events-none absolute inset-0 hidden rounded-lg bg-black/10 group-hover:block"}),jsxRuntimeExports.jsx("button",{className:m$1("absolute right-2 bottom-2 flex h-8 w-8 cursor-pointer items-center justify-center rounded-md border border-border bg-background/90 shadow-sm backdrop-blur-sm transition-all duration-200 hover:bg-background","opacity-0 group-hover:opacity-100"),onClick:nt,title:"Download image",type:"button",children:jsxRuntimeExports.jsx(Download$1,{size:14})})]}):null},st=async e=>{let t={startOnLoad:!1,theme:"default",securityLevel:"strict",fontFamily:"monospace",suppressErrorRendering:!0,...e},Ye=(await __vitePreload(async()=>{const{default:tt}=await import("./mermaid.core-kI_4o89S.js").then(rt=>rt.aI);return{default:tt}},[])).default;return Ye.initialize(t),Ye},oe$1=({chart:e,className:t,config:Ye})=>{let[tt,rt]=reactExports.useState(null),[nt,at]=reactExports.useState(!0),[it,ot]=reactExports.useState(""),[ct,At]=reactExports.useState("");if(reactExports.useEffect(()=>{(async()=>{try{rt(null),at(!0);let qt=await st(Ye),Ft=e.split("").reduce((zt,Yt)=>(zt<<5)-zt+Yt.charCodeAt(0)|0,0),Ut=`mermaid-${Math.abs(Ft)}-${Date.now()}-${Math.random().toString(36).substring(2,9)}`,{svg:Ht}=await qt.render(Ut,e);ot(Ht),At(Ht)}catch(qt){if(!(ct||it)){let Ft=qt instanceof Error?qt.message:"Failed to render Mermaid chart";rt(Ft)}}finally{at(!1)}})()},[e,Ye]),nt&&!it&&!ct)return jsxRuntimeExports.jsx("div",{className:m$1("my-4 flex justify-center p-4",t),children:jsxRuntimeExports.jsxs("div",{className:"flex items-center space-x-2 text-muted-foreground",children:[jsxRuntimeExports.jsx("div",{className:"h-4 w-4 animate-spin rounded-full border-current border-b-2"}),jsxRuntimeExports.jsx("span",{className:"text-sm",children:"Loading diagram..."})]})});if(tt&&!it&&!ct)return jsxRuntimeExports.jsxs("div",{className:m$1("rounded-lg border border-red-200 bg-red-50 p-4",t),children:[jsxRuntimeExports.jsxs("p",{className:"font-mono text-red-700 text-sm",children:["Mermaid Error: ",tt]}),jsxRuntimeExports.jsxs("details",{className:"mt-2",children:[jsxRuntimeExports.jsx("summary",{className:"cursor-pointer text-red-600 text-xs",children:"Show Code"}),jsxRuntimeExports.jsx("pre",{className:"mt-2 overflow-x-auto rounded bg-red-100 p-2 text-red-800 text-xs",children:e})]})]});let Rt=it||ct;return jsxRuntimeExports.jsx("div",{"aria-label":"Mermaid chart",className:m$1("my-4 flex justify-center",t),dangerouslySetInnerHTML:{__html:Rt},role:"img"})};function le$1(e){var t,Ye;let tt=[],rt=[],nt=e.querySelectorAll("thead th");for(let it of nt)tt.push(((t=it.textContent)==null?void 0:t.trim())||"");let at=e.querySelectorAll("tbody tr");for(let it of at){let ot=[],ct=it.querySelectorAll("td");for(let At of ct)ot.push(((Ye=At.textContent)==null?void 0:Ye.trim())||"");rt.push(ot)}return{headers:tt,rows:rt}}function de$1(e){let{headers:t,rows:Ye}=e,tt=nt=>nt.includes(",")||nt.includes('"')||nt.includes(`
786
786
  `)?`"${nt.replace(/"/g,'""')}"`:nt,rt=[];t.length>0&&rt.push(t.map(tt).join(","));for(let nt of Ye)rt.push(nt.map(tt).join(","));return rt.join(`
787
787
  `)}function ce$1(e){let{headers:t,rows:Ye}=e;if(t.length===0)return"";let tt=[],rt=t.map(nt=>nt.replace(/\|/g,"\\|"));tt.push(`| ${rt.join(" | ")} |`),tt.push(`| ${t.map(()=>"---").join(" | ")} |`);for(let nt of Ye){let at=[...nt];for(;at.length<t.length;)at.push("");let it=at.map(ot=>ot.replace(/\|/g,"\\|"));tt.push(`| ${it.join(" | ")} |`)}return tt.join(`
788
788
  `)}var me$1=({children:e,className:t,onCopy:Ye,onError:tt,timeout:rt=2e3,format:nt="markdown"})=>{let[at,it]=reactExports.useState(!1),ot=reactExports.useRef(0),{isAnimating:ct}=reactExports.useContext(M$2),At=async qt=>{var Ft;if(typeof window>"u"||!((Ft=navigator==null?void 0:navigator.clipboard)!=null&&Ft.write)){tt==null||tt(new Error("Clipboard API not available"));return}try{if(!at){let Ut=qt.currentTarget.closest('[data-streamdown="table-wrapper"]'),Ht=Ut==null?void 0:Ut.querySelector("table");if(!Ht){tt==null||tt(new Error("Table not found"));return}let zt=le$1(Ht),Yt=new ClipboardItem({"text/plain":nt==="markdown"?ce$1(zt):de$1(zt),"text/html":new Blob([Ht.outerHTML],{type:"text/html"})});await navigator.clipboard.write([Yt]),it(!0),Ye==null||Ye(),ot.current=window.setTimeout(()=>it(!1),rt)}}catch(Ut){tt==null||tt(Ut)}};reactExports.useEffect(()=>()=>{window.clearTimeout(ot.current)},[]);let Rt=at?Check$1:Copy$1;return jsxRuntimeExports.jsx("button",{className:m$1("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",t),disabled:ct,onClick:At,title:`Copy table as ${nt}`,type:"button",children:e??jsxRuntimeExports.jsx(Rt,{size:14})})},pe$1=({children:e,className:t,onDownload:Ye,onError:tt})=>{let[rt,nt]=reactExports.useState(!1),at=reactExports.useRef(null),{isAnimating:it}=reactExports.useContext(M$2),ot=ct=>{var At;try{let Rt=(At=at.current)==null?void 0:At.closest('[data-streamdown="table-wrapper"]'),qt=Rt==null?void 0:Rt.querySelector("table");if(!qt){tt==null||tt(new Error("Table not found"));return}let Ft=le$1(qt),Ut=ct==="csv"?de$1(Ft):ce$1(Ft);P$1(`table.${ct==="csv"?"csv":"md"}`,Ut,ct==="csv"?"text/csv":"text/markdown"),nt(!1),Ye==null||Ye(ct)}catch(Rt){tt==null||tt(Rt)}};return reactExports.useEffect(()=>{let ct=At=>{at.current&&!at.current.contains(At.target)&&nt(!1)};return document.addEventListener("mousedown",ct),()=>{document.removeEventListener("mousedown",ct)}},[]),jsxRuntimeExports.jsxs("div",{className:"relative",ref:at,children:[jsxRuntimeExports.jsx("button",{className:m$1("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",t),disabled:it,onClick:()=>nt(!rt),title:"Download table",type:"button",children:e??jsxRuntimeExports.jsx(Download$1,{size:14})}),rt&&jsxRuntimeExports.jsxs("div",{className:"absolute top-full right-0 z-10 mt-1 min-w-[120px] rounded-md border border-border bg-background shadow-lg",children:[jsxRuntimeExports.jsx("button",{className:"w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40",onClick:()=>ot("csv"),type:"button",children:"CSV"}),jsxRuntimeExports.jsx("button",{className:"w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40",onClick:()=>ot("markdown"),type:"button",children:"Markdown"})]})]})},lt$1=/language-([^\s]+)/;function A$1(e,t){if(!(e!=null&&e.position||t!=null&&t.position))return!0;if(!(e!=null&&e.position&&t!=null&&t.position))return!1;let Ye=e.position.start,tt=t.position.start,rt=e.position.end,nt=t.position.end;return(Ye==null?void 0:Ye.line)===(tt==null?void 0:tt.line)&&(Ye==null?void 0:Ye.column)===(tt==null?void 0:tt.column)&&(rt==null?void 0:rt.line)===(nt==null?void 0:nt.line)&&(rt==null?void 0:rt.column)===(nt==null?void 0:nt.column)}function k$1(e,t){return e.className===t.className&&A$1(e.node,t.node)}var F$1=(e,t)=>typeof e=="boolean"?e:e[t]!==!1,V$1=reactExports.memo(({children:e,className:t,node:Ye,...tt})=>jsxRuntimeExports.jsx("ol",{className:m$1("ml-4 list-outside list-decimal whitespace-normal",t),"data-streamdown":"ordered-list",...tt,children:e}),(e,t)=>k$1(e,t));V$1.displayName="MarkdownOl";var ue$1=reactExports.memo(({children:e,className:t,node:Ye,...tt})=>jsxRuntimeExports.jsx("li",{className:m$1("py-1",t),"data-streamdown":"list-item",...tt,children:e}),(e,t)=>e.className===t.className&&A$1(e.node,t.node));ue$1.displayName="MarkdownLi";var ge$1=reactExports.memo(({children:e,className:t,node:Ye,...tt})=>jsxRuntimeExports.jsx("ul",{className:m$1("ml-4 list-outside list-disc whitespace-normal",t),"data-streamdown":"unordered-list",...tt,children:e}),(e,t)=>k$1(e,t));ge$1.displayName="MarkdownUl";var fe$1=reactExports.memo(({className:e,node:t,...Ye})=>jsxRuntimeExports.jsx("hr",{className:m$1("my-6 border-border",e),"data-streamdown":"horizontal-rule",...Ye}),(e,t)=>k$1(e,t));fe$1.displayName="MarkdownHr";var he$1=reactExports.memo(({children:e,className:t,node:Ye,...tt})=>jsxRuntimeExports.jsx("span",{className:m$1("font-semibold",t),"data-streamdown":"strong",...tt,children:e}),(e,t)=>k$1(e,t));he$1.displayName="MarkdownStrong";var be$1=reactExports.memo(({children:e,className:t,href:Ye,node:tt,...rt})=>{let nt=Ye==="streamdown:incomplete-link";return jsxRuntimeExports.jsx("a",{className:m$1("wrap-anywhere font-medium text-primary underline",t),"data-incomplete":nt,"data-streamdown":"link",href:Ye,rel:"noreferrer",target:"_blank",...rt,children:e})},(e,t)=>k$1(e,t)&&e.href===t.href);be$1.displayName="MarkdownA";var ke$1=reactExports.memo(({children:e,className:t,node:Ye,...tt})=>jsxRuntimeExports.jsx("h1",{className:m$1("mt-6 mb-2 font-semibold text-3xl",t),"data-streamdown":"heading-1",...tt,children:e}),(e,t)=>k$1(e,t));ke$1.displayName="MarkdownH1";var ye$1=reactExports.memo(({children:e,className:t,node:Ye,...tt})=>jsxRuntimeExports.jsx("h2",{className:m$1("mt-6 mb-2 font-semibold text-2xl",t),"data-streamdown":"heading-2",...tt,children:e}),(e,t)=>k$1(e,t));ye$1.displayName="MarkdownH2";var we$1=reactExports.memo(({children:e,className:t,node:Ye,...tt})=>jsxRuntimeExports.jsx("h3",{className:m$1("mt-6 mb-2 font-semibold text-xl",t),"data-streamdown":"heading-3",...tt,children:e}),(e,t)=>k$1(e,t));we$1.displayName="MarkdownH3";var ve$1=reactExports.memo(({children:e,className:t,node:Ye,...tt})=>jsxRuntimeExports.jsx("h4",{className:m$1("mt-6 mb-2 font-semibold text-lg",t),"data-streamdown":"heading-4",...tt,children:e}),(e,t)=>k$1(e,t));ve$1.displayName="MarkdownH4";var Me$1=reactExports.memo(({children:e,className:t,node:Ye,...tt})=>jsxRuntimeExports.jsx("h5",{className:m$1("mt-6 mb-2 font-semibold text-base",t),"data-streamdown":"heading-5",...tt,children:e}),(e,t)=>k$1(e,t));Me$1.displayName="MarkdownH5";var Te$1=reactExports.memo(({children:e,className:t,node:Ye,...tt})=>jsxRuntimeExports.jsx("h6",{className:m$1("mt-6 mb-2 font-semibold text-sm",t),"data-streamdown":"heading-6",...tt,children:e}),(e,t)=>k$1(e,t));Te$1.displayName="MarkdownH6";var Ce$1=reactExports.memo(({children:e,className:t,node:Ye,...tt})=>{let rt=reactExports.useContext(j$1),nt=F$1(rt,"table");return jsxRuntimeExports.jsxs("div",{className:"my-4 flex flex-col space-y-2","data-streamdown":"table-wrapper",children:[nt&&jsxRuntimeExports.jsxs("div",{className:"flex items-center justify-end gap-1",children:[jsxRuntimeExports.jsx(me$1,{}),jsxRuntimeExports.jsx(pe$1,{})]}),jsxRuntimeExports.jsx("div",{className:"overflow-x-auto",children:jsxRuntimeExports.jsx("table",{className:m$1("w-full border-collapse border border-border",t),"data-streamdown":"table",...tt,children:e})})]})},(e,t)=>k$1(e,t));Ce$1.displayName="MarkdownTable";var Pe$1=reactExports.memo(({children:e,className:t,node:Ye,...tt})=>jsxRuntimeExports.jsx("thead",{className:m$1("bg-muted/80",t),"data-streamdown":"table-header",...tt,children:e}),(e,t)=>k$1(e,t));Pe$1.displayName="MarkdownThead";var Ne$1=reactExports.memo(({children:e,className:t,node:Ye,...tt})=>jsxRuntimeExports.jsx("tbody",{className:m$1("divide-y divide-border bg-muted/40",t),"data-streamdown":"table-body",...tt,children:e}),(e,t)=>k$1(e,t));Ne$1.displayName="MarkdownTbody";var Ie$1=reactExports.memo(({children:e,className:t,node:Ye,...tt})=>jsxRuntimeExports.jsx("tr",{className:m$1("border-border border-b",t),"data-streamdown":"table-row",...tt,children:e}),(e,t)=>k$1(e,t));Ie$1.displayName="MarkdownTr";var Se$1=reactExports.memo(({children:e,className:t,node:Ye,...tt})=>jsxRuntimeExports.jsx("th",{className:m$1("whitespace-nowrap px-4 py-2 text-left font-semibold text-sm",t),"data-streamdown":"table-header-cell",...tt,children:e}),(e,t)=>k$1(e,t));Se$1.displayName="MarkdownTh";var Le$1=reactExports.memo(({children:e,className:t,node:Ye,...tt})=>jsxRuntimeExports.jsx("td",{className:m$1("px-4 py-2 text-sm",t),"data-streamdown":"table-cell",...tt,children:e}),(e,t)=>k$1(e,t));Le$1.displayName="MarkdownTd";var Be$1=reactExports.memo(({children:e,className:t,node:Ye,...tt})=>jsxRuntimeExports.jsx("blockquote",{className:m$1("my-4 border-muted-foreground/30 border-l-4 pl-4 text-muted-foreground italic",t),"data-streamdown":"blockquote",...tt,children:e}),(e,t)=>k$1(e,t));Be$1.displayName="MarkdownBlockquote";var $e$1=reactExports.memo(({children:e,className:t,node:Ye,...tt})=>jsxRuntimeExports.jsx("sup",{className:m$1("text-sm",t),"data-streamdown":"superscript",...tt,children:e}),(e,t)=>k$1(e,t));$e$1.displayName="MarkdownSup";var xe$1=reactExports.memo(({children:e,className:t,node:Ye,...tt})=>jsxRuntimeExports.jsx("sub",{className:m$1("text-sm",t),"data-streamdown":"subscript",...tt,children:e}),(e,t)=>k$1(e,t));xe$1.displayName="MarkdownSub";var He$1=reactExports.memo(({children:e,className:t,node:Ye,...tt})=>{if("data-footnotes"in tt){let rt=at=>{var it,ot;if(!reactExports.isValidElement(at))return!1;let ct=Array.isArray(at.props.children)?at.props.children:[at.props.children],At=!1,Rt=!1;for(let qt of ct)if(qt){if(typeof qt=="string")qt.trim()!==""&&(At=!0);else if(reactExports.isValidElement(qt))if(((it=qt.props)==null?void 0:it["data-footnote-backref"])!==void 0)Rt=!0;else{let Ft=Array.isArray(qt.props.children)?qt.props.children:[qt.props.children];for(let Ut of Ft){if(typeof Ut=="string"&&Ut.trim()!==""){At=!0;break}if(reactExports.isValidElement(Ut)&&((ot=Ut.props)==null?void 0:ot["data-footnote-backref"])===void 0){At=!0;break}}}}return Rt&&!At},nt=Array.isArray(e)?e.map(at=>{if(!reactExports.isValidElement(at))return at;if(at.type===V$1){let it=(Array.isArray(at.props.children)?at.props.children:[at.props.children]).filter(ot=>!rt(ot));return it.length===0?null:{...at,props:{...at.props,children:it}}}return at}):e;return(Array.isArray(nt)?nt.some(at=>at!==null):nt!==null)?jsxRuntimeExports.jsx("section",{className:t,...tt,children:nt}):null}return jsxRuntimeExports.jsx("section",{className:t,...tt,children:e})},(e,t)=>k$1(e,t));He$1.displayName="MarkdownSection";var dt=({node:e,className:t,children:Ye,...tt})=>{var rt,nt,at;let it=((rt=e==null?void 0:e.position)==null?void 0:rt.start.line)===((nt=e==null?void 0:e.position)==null?void 0:nt.end.line),ot=reactExports.useContext(G$1),ct=reactExports.useContext(j$1);if(it)return jsxRuntimeExports.jsx("code",{className:m$1("rounded bg-muted px-1.5 py-0.5 font-mono text-sm",t),"data-streamdown":"inline-code",...tt,children:Ye});let At=t==null?void 0:t.match(lt$1),Rt=(at=At==null?void 0:At.at(1))!=null?at:"",qt="";if(reactExports.isValidElement(Ye)&&Ye.props&&typeof Ye.props=="object"&&"children"in Ye.props&&typeof Ye.props.children=="string"?qt=Ye.props.children:typeof Ye=="string"&&(qt=Ye),Rt==="mermaid"){let Ut=F$1(ct,"mermaid");return jsxRuntimeExports.jsxs("div",{className:m$1("group relative my-4 h-auto rounded-xl border p-4",t),"data-streamdown":"mermaid-block",children:[Ut&&jsxRuntimeExports.jsxs("div",{className:"flex items-center justify-end gap-2",children:[jsxRuntimeExports.jsx(U$2,{code:qt,language:Rt}),jsxRuntimeExports.jsx(z$2,{code:qt})]}),jsxRuntimeExports.jsx(oe$1,{chart:qt,config:ot})]})}let Ft=F$1(ct,"code");return jsxRuntimeExports.jsx(ee$1,{className:m$1("overflow-x-auto border-t",t),code:qt,"data-language":Rt,"data-streamdown":"code-block",language:Rt,preClassName:"overflow-x-auto font-mono text-xs p-4 bg-muted/40",children:Ft&&jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment,{children:[jsxRuntimeExports.jsx(U$2,{code:qt,language:Rt}),jsxRuntimeExports.jsx(z$2,{})]})})},Ae$1=reactExports.memo(dt,(e,t)=>e.className===t.className&&A$1(e.node,t.node));Ae$1.displayName="MarkdownCode";var je$1=reactExports.memo(te$1,(e,t)=>e.className===t.className&&A$1(e.node,t.node));je$1.displayName="MarkdownImg";var Re$1=reactExports.memo(({children:e,className:t,node:Ye,...tt})=>{var rt;let nt=(Array.isArray(e)?e:[e]).filter(at=>at!=null&&at!=="");return nt.length===1&&reactExports.isValidElement(nt[0])&&((rt=nt[0].props.node)==null?void 0:rt.tagName)==="img"?jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment,{children:e}):jsxRuntimeExports.jsx("p",{className:t,...tt,children:e})},(e,t)=>k$1(e,t));Re$1.displayName="MarkdownParagraph";var De$1={ol:V$1,li:ue$1,ul:ge$1,hr:fe$1,strong:he$1,a:be$1,h1:ke$1,h2:ye$1,h3:we$1,h4:ve$1,h5:Me$1,h6:Te$1,table:Ce$1,thead:Pe$1,tbody:Ne$1,tr:Ie$1,th:Se$1,td:Le$1,blockquote:Be$1,code:Ae$1,img:je$1,pre:({children:e})=>e,sup:$e$1,sub:xe$1,p:Re$1,section:He$1},Ee$1=e=>{let t=/\[\^[^\]\s]{1,200}\](?!:)/.test(e),Ye=/\[\^[^\]\s]{1,200}\]:/.test(e);if(t||Ye)return[e];let tt=x$2.lex(e,{gfm:!0}),rt=[],nt=[];for(let at=0;at<tt.length;at++){let it=tt[at],ot=it.raw;if(nt.length>0){if(rt[rt.length-1]+=ot,it.type==="html"){let ct=ot.match(/<\/(\w+)>/);if(ct){let At=ct[1];nt[nt.length-1]===At&&nt.pop()}}continue}if(it.type==="html"&&it.block){let ct=ot.match(/<(\w+)[\s>]/);if(ct){let At=ct[1];ot.includes(`</${At}>`)||nt.push(At)}}if(ot.trim()==="$$"&&rt.length>0){let ct=rt.at(-1);if(!ct){rt.push(ot);continue}let At=ct.trimStart().startsWith("$$"),Rt=(ct.match(/\$\$/g)||[]).length;if(At&&Rt%2===1){rt[rt.length-1]=ct+ot;continue}}if(rt.length>0&&ot.trimEnd().endsWith("$$")){let ct=rt.at(-1);if(!ct){rt.push(ot);continue}let At=ct.trimStart().startsWith("$$"),Rt=(ct.match(/\$\$/g)||[]).length,qt=(ot.match(/\$\$/g)||[]).length;if(At&&Rt%2===1&&!ot.trimStart().startsWith("$$")&&qt===1){rt[rt.length-1]=ct+ot;continue}}rt.push(ot)}return rt},mt=/(!?\[)([^\]]*?)$/,pt=/(\*\*)([^*]*?)$/,ut=/(__)([^_]*?)$/,gt$1=/(\*\*\*)([^*]*?)$/,ft=/(\*)([^*]*?)$/,ht=/(_)([^_]*?)$/,bt=/(`)([^`]*?)$/,kt=/(~~)([^~]*?)$/,R$1=e=>{let t=(e.match(/```/g)||[]).length;return t>0&&t%2===0&&e.includes(`
@@ -811,7 +811,7 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
811
811
  */var Ye=function(tt){var rt=/(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i,nt=0,at={},it={manual:tt.Prism&&tt.Prism.manual,disableWorkerMessageHandler:tt.Prism&&tt.Prism.disableWorkerMessageHandler,util:{encode:function Gt(Vt){return Vt instanceof ot?new ot(Vt.type,Gt(Vt.content),Vt.alias):Array.isArray(Vt)?Vt.map(Gt):Vt.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/\u00a0/g," ")},type:function(Gt){return Object.prototype.toString.call(Gt).slice(8,-1)},objId:function(Gt){return Gt.__id||Object.defineProperty(Gt,"__id",{value:++nt}),Gt.__id},clone:function Gt(Vt,Zt){Zt=Zt||{};var Xt,Qt;switch(it.util.type(Vt)){case"Object":if(Qt=it.util.objId(Vt),Zt[Qt])return Zt[Qt];Xt={},Zt[Qt]=Xt;for(var er in Vt)Vt.hasOwnProperty(er)&&(Xt[er]=Gt(Vt[er],Zt));return Xt;case"Array":return Qt=it.util.objId(Vt),Zt[Qt]?Zt[Qt]:(Xt=[],Zt[Qt]=Xt,Vt.forEach(function(nr,ar){Xt[ar]=Gt(nr,Zt)}),Xt);default:return Vt}},getLanguage:function(Gt){for(;Gt;){var Vt=rt.exec(Gt.className);if(Vt)return Vt[1].toLowerCase();Gt=Gt.parentElement}return"none"},setLanguage:function(Gt,Vt){Gt.className=Gt.className.replace(RegExp(rt,"gi"),""),Gt.classList.add("language-"+Vt)},currentScript:function(){if(typeof document>"u")return null;if("currentScript"in document)return document.currentScript;try{throw new Error}catch(Xt){var Gt=(/at [^(\r\n]*\((.*):[^:]+:[^:]+\)$/i.exec(Xt.stack)||[])[1];if(Gt){var Vt=document.getElementsByTagName("script");for(var Zt in Vt)if(Vt[Zt].src==Gt)return Vt[Zt]}return null}},isActive:function(Gt,Vt,Zt){for(var Xt="no-"+Vt;Gt;){var Qt=Gt.classList;if(Qt.contains(Vt))return!0;if(Qt.contains(Xt))return!1;Gt=Gt.parentElement}return!!Zt}},languages:{plain:at,plaintext:at,text:at,txt:at,extend:function(Gt,Vt){var Zt=it.util.clone(it.languages[Gt]);for(var Xt in Vt)Zt[Xt]=Vt[Xt];return Zt},insertBefore:function(Gt,Vt,Zt,Xt){Xt=Xt||it.languages;var Qt=Xt[Gt],er={};for(var nr in Qt)if(Qt.hasOwnProperty(nr)){if(nr==Vt)for(var ar in Zt)Zt.hasOwnProperty(ar)&&(er[ar]=Zt[ar]);Zt.hasOwnProperty(nr)||(er[nr]=Qt[nr])}var sr=Xt[Gt];return Xt[Gt]=er,it.languages.DFS(it.languages,function(lr,fr){fr===sr&&lr!=Gt&&(this[lr]=er)}),er},DFS:function Gt(Vt,Zt,Xt,Qt){Qt=Qt||{};var er=it.util.objId;for(var nr in Vt)if(Vt.hasOwnProperty(nr)){Zt.call(Vt,nr,Vt[nr],Xt||nr);var ar=Vt[nr],sr=it.util.type(ar);sr==="Object"&&!Qt[er(ar)]?(Qt[er(ar)]=!0,Gt(ar,Zt,null,Qt)):sr==="Array"&&!Qt[er(ar)]&&(Qt[er(ar)]=!0,Gt(ar,Zt,nr,Qt))}}},plugins:{},highlightAll:function(Gt,Vt){it.highlightAllUnder(document,Gt,Vt)},highlightAllUnder:function(Gt,Vt,Zt){var Xt={callback:Zt,container:Gt,selector:'code[class*="language-"], [class*="language-"] code, code[class*="lang-"], [class*="lang-"] code'};it.hooks.run("before-highlightall",Xt),Xt.elements=Array.prototype.slice.apply(Xt.container.querySelectorAll(Xt.selector)),it.hooks.run("before-all-elements-highlight",Xt);for(var Qt=0,er;er=Xt.elements[Qt++];)it.highlightElement(er,Vt===!0,Xt.callback)},highlightElement:function(Gt,Vt,Zt){var Xt=it.util.getLanguage(Gt),Qt=it.languages[Xt];it.util.setLanguage(Gt,Xt);var er=Gt.parentElement;er&&er.nodeName.toLowerCase()==="pre"&&it.util.setLanguage(er,Xt);var nr=Gt.textContent,ar={element:Gt,language:Xt,grammar:Qt,code:nr};function sr(fr){ar.highlightedCode=fr,it.hooks.run("before-insert",ar),ar.element.innerHTML=ar.highlightedCode,it.hooks.run("after-highlight",ar),it.hooks.run("complete",ar),Zt&&Zt.call(ar.element)}if(it.hooks.run("before-sanity-check",ar),er=ar.element.parentElement,er&&er.nodeName.toLowerCase()==="pre"&&!er.hasAttribute("tabindex")&&er.setAttribute("tabindex","0"),!ar.code){it.hooks.run("complete",ar),Zt&&Zt.call(ar.element);return}if(it.hooks.run("before-highlight",ar),!ar.grammar){sr(it.util.encode(ar.code));return}if(Vt&&tt.Worker){var lr=new Worker(it.filename);lr.onmessage=function(fr){sr(fr.data)},lr.postMessage(JSON.stringify({language:ar.language,code:ar.code,immediateClose:!0}))}else sr(it.highlight(ar.code,ar.grammar,ar.language))},highlight:function(Gt,Vt,Zt){var Xt={code:Gt,grammar:Vt,language:Zt};if(it.hooks.run("before-tokenize",Xt),!Xt.grammar)throw new Error('The language "'+Xt.language+'" has no grammar.');return Xt.tokens=it.tokenize(Xt.code,Xt.grammar),it.hooks.run("after-tokenize",Xt),ot.stringify(it.util.encode(Xt.tokens),Xt.language)},tokenize:function(Gt,Vt){var Zt=Vt.rest;if(Zt){for(var Xt in Zt)Vt[Xt]=Zt[Xt];delete Vt.rest}var Qt=new Rt;return qt(Qt,Qt.head,Gt),At(Gt,Qt,Vt,Qt.head,0),Ut(Qt)},hooks:{all:{},add:function(Gt,Vt){var Zt=it.hooks.all;Zt[Gt]=Zt[Gt]||[],Zt[Gt].push(Vt)},run:function(Gt,Vt){var Zt=it.hooks.all[Gt];if(!(!Zt||!Zt.length))for(var Xt=0,Qt;Qt=Zt[Xt++];)Qt(Vt)}},Token:ot};tt.Prism=it;function ot(Gt,Vt,Zt,Xt){this.type=Gt,this.content=Vt,this.alias=Zt,this.length=(Xt||"").length|0}ot.stringify=function Gt(Vt,Zt){if(typeof Vt=="string")return Vt;if(Array.isArray(Vt)){var Xt="";return Vt.forEach(function(sr){Xt+=Gt(sr,Zt)}),Xt}var Qt={type:Vt.type,content:Gt(Vt.content,Zt),tag:"span",classes:["token",Vt.type],attributes:{},language:Zt},er=Vt.alias;er&&(Array.isArray(er)?Array.prototype.push.apply(Qt.classes,er):Qt.classes.push(er)),it.hooks.run("wrap",Qt);var nr="";for(var ar in Qt.attributes)nr+=" "+ar+'="'+(Qt.attributes[ar]||"").replace(/"/g,"&quot;")+'"';return"<"+Qt.tag+' class="'+Qt.classes.join(" ")+'"'+nr+">"+Qt.content+"</"+Qt.tag+">"};function ct(Gt,Vt,Zt,Xt){Gt.lastIndex=Vt;var Qt=Gt.exec(Zt);if(Qt&&Xt&&Qt[1]){var er=Qt[1].length;Qt.index+=er,Qt[0]=Qt[0].slice(er)}return Qt}function At(Gt,Vt,Zt,Xt,Qt,er){for(var nr in Zt)if(!(!Zt.hasOwnProperty(nr)||!Zt[nr])){var ar=Zt[nr];ar=Array.isArray(ar)?ar:[ar];for(var sr=0;sr<ar.length;++sr){if(er&&er.cause==nr+","+sr)return;var lr=ar[sr],fr=lr.inside,gr=!!lr.lookbehind,dr=!!lr.greedy,vr=lr.alias;if(dr&&!lr.pattern.global){var mr=lr.pattern.toString().match(/[imsuy]*$/)[0];lr.pattern=RegExp(lr.pattern.source,mr+"g")}for(var Er=lr.pattern||lr,_r=Xt.next,Tr=Qt;_r!==Vt.tail&&!(er&&Tr>=er.reach);Tr+=_r.value.length,_r=_r.next){var ur=_r.value;if(Vt.length>Gt.length)return;if(!(ur instanceof ot)){var cr=1,yr;if(dr){if(yr=ct(Er,Tr,Gt,gr),!yr||yr.index>=Gt.length)break;var Sr=yr.index,ir=yr.index+yr[0].length,or=Tr;for(or+=_r.value.length;Sr>=or;)_r=_r.next,or+=_r.value.length;if(or-=_r.value.length,Tr=or,_r.value instanceof ot)continue;for(var hr=_r;hr!==Vt.tail&&(or<ir||typeof hr.value=="string");hr=hr.next)cr++,or+=hr.value.length;cr--,ur=Gt.slice(Tr,or),yr.index-=Tr}else if(yr=ct(Er,0,ur,gr),!yr)continue;var Sr=yr.index,wr=yr[0],Ir=ur.slice(0,Sr),kr=ur.slice(Sr+wr.length),Mr=Tr+ur.length;er&&Mr>er.reach&&(er.reach=Mr);var Ar=_r.prev;Ir&&(Ar=qt(Vt,Ar,Ir),Tr+=Ir.length),Ft(Vt,Ar,cr);var Rr=new ot(nr,fr?it.tokenize(wr,fr):wr,vr,wr);if(_r=qt(Vt,Ar,Rr),kr&&qt(Vt,_r,kr),cr>1){var Dr={cause:nr+","+sr,reach:Mr};At(Gt,Vt,Zt,_r.prev,Tr,Dr),er&&Dr.reach>er.reach&&(er.reach=Dr.reach)}}}}}}function Rt(){var Gt={value:null,prev:null,next:null},Vt={value:null,prev:Gt,next:null};Gt.next=Vt,this.head=Gt,this.tail=Vt,this.length=0}function qt(Gt,Vt,Zt){var Xt=Vt.next,Qt={value:Zt,prev:Vt,next:Xt};return Vt.next=Qt,Xt.prev=Qt,Gt.length++,Qt}function Ft(Gt,Vt,Zt){for(var Xt=Vt.next,Qt=0;Qt<Zt&&Xt!==Gt.tail;Qt++)Xt=Xt.next;Vt.next=Xt,Xt.prev=Vt,Gt.length-=Qt}function Ut(Gt){for(var Vt=[],Zt=Gt.head.next;Zt!==Gt.tail;)Vt.push(Zt.value),Zt=Zt.next;return Vt}if(!tt.document)return tt.addEventListener&&(it.disableWorkerMessageHandler||tt.addEventListener("message",function(Gt){var Vt=JSON.parse(Gt.data),Zt=Vt.language,Xt=Vt.code,Qt=Vt.immediateClose;tt.postMessage(it.highlight(Xt,it.languages[Zt],Zt)),Qt&&tt.close()},!1)),it;var Ht=it.util.currentScript();Ht&&(it.filename=Ht.src,Ht.hasAttribute("data-manual")&&(it.manual=!0));function zt(){it.manual||it.highlightAll()}if(!it.manual){var Yt=document.readyState;Yt==="loading"||Yt==="interactive"&&Ht&&Ht.defer?document.addEventListener("DOMContentLoaded",zt):window.requestAnimationFrame?window.requestAnimationFrame(zt):window.setTimeout(zt,16)}return it}(t);e.exports&&(e.exports=Ye),typeof commonjsGlobal<"u"&&(commonjsGlobal.Prism=Ye)}(prismCore)),prismCore.exports}var markup_1,hasRequiredMarkup;function requireMarkup(){if(hasRequiredMarkup)return markup_1;hasRequiredMarkup=1,markup_1=e,e.displayName="markup",e.aliases=["html","mathml","svg","xml","ssml","atom","rss"];function e(t){t.languages.markup={comment:{pattern:/<!--(?:(?!<!--)[\s\S])*?-->/,greedy:!0},prolog:{pattern:/<\?[\s\S]+?\?>/,greedy:!0},doctype:{pattern:/<!DOCTYPE(?:[^>"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|<!--(?:[^-]|-(?!->))*-->)*\]\s*)?>/i,greedy:!0,inside:{"internal-subset":{pattern:/(^[^\[]*\[)[\s\S]+(?=\]>$)/,lookbehind:!0,greedy:!0,inside:null},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},punctuation:/^<!|>$|[[\]]/,"doctype-tag":/^DOCTYPE/i,name:/[^\s<>'"]+/}},cdata:{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,greedy:!0},tag:{pattern:/<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/,greedy:!0,inside:{tag:{pattern:/^<\/?[^\s>\/]+/,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"special-attr":[],"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/,inside:{punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:"named-entity"},/&#x?[\da-f]{1,8};/i]},t.languages.markup.tag.inside["attr-value"].inside.entity=t.languages.markup.entity,t.languages.markup.doctype.inside["internal-subset"].inside=t.languages.markup,t.hooks.add("wrap",function(Ye){Ye.type==="entity"&&(Ye.attributes.title=Ye.content.value.replace(/&amp;/,"&"))}),Object.defineProperty(t.languages.markup.tag,"addInlined",{value:function(tt,rt){var nt={};nt["language-"+rt]={pattern:/(^<!\[CDATA\[)[\s\S]+?(?=\]\]>$)/i,lookbehind:!0,inside:t.languages[rt]},nt.cdata=/^<!\[CDATA\[|\]\]>$/i;var at={"included-cdata":{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,inside:nt}};at["language-"+rt]={pattern:/[\s\S]+/,inside:t.languages[rt]};var it={};it[tt]={pattern:RegExp(/(<__[^>]*>)(?:<!\[CDATA\[(?:[^\]]|\](?!\]>))*\]\]>|(?!<!\[CDATA\[)[\s\S])*?(?=<\/__>)/.source.replace(/__/g,function(){return tt}),"i"),lookbehind:!0,greedy:!0,inside:at},t.languages.insertBefore("markup","cdata",it)}}),Object.defineProperty(t.languages.markup.tag,"addAttribute",{value:function(Ye,tt){t.languages.markup.tag.inside["special-attr"].push({pattern:RegExp(/(^|["'\s])/.source+"(?:"+Ye+")"+/\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))/.source,"i"),lookbehind:!0,inside:{"attr-name":/^[^\s=]+/,"attr-value":{pattern:/=[\s\S]+/,inside:{value:{pattern:/(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/,lookbehind:!0,alias:[tt,"language-"+tt],inside:t.languages[tt]},punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}}}})}}),t.languages.html=t.languages.markup,t.languages.mathml=t.languages.markup,t.languages.svg=t.languages.markup,t.languages.xml=t.languages.extend("markup",{}),t.languages.ssml=t.languages.xml,t.languages.atom=t.languages.xml,t.languages.rss=t.languages.xml}return markup_1}var css_1,hasRequiredCss;function requireCss(){if(hasRequiredCss)return css_1;hasRequiredCss=1,css_1=e,e.displayName="css",e.aliases=[];function e(t){(function(Ye){var tt=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/;Ye.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:/@[\w-](?:[^;{\s]|\s+(?![\s{]))*(?:;|(?=\s*\{))/,inside:{rule:/^@[\w-]+/,"selector-function-argument":{pattern:/(\bselector\s*\(\s*(?![\s)]))(?:[^()\s]|\s+(?![\s)])|\((?:[^()]|\([^()]*\))*\))+(?=\s*\))/,lookbehind:!0,alias:"selector"},keyword:{pattern:/(^|[^\w-])(?:and|not|only|or)(?![\w-])/,lookbehind:!0}}},url:{pattern:RegExp("\\burl\\((?:"+tt.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+tt.source+"$"),alias:"url"}}},selector:{pattern:RegExp(`(^|[{}\\s])[^{}\\s](?:[^{};"'\\s]|\\s+(?![\\s{])|`+tt.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:tt,greedy:!0},property:{pattern:/(^|[^-\w\xA0-\uFFFF])(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*(?=\s*:)/i,lookbehind:!0},important:/!important\b/i,function:{pattern:/(^|[^-a-z0-9])[-a-z0-9]+(?=\()/i,lookbehind:!0},punctuation:/[(){};:,]/},Ye.languages.css.atrule.inside.rest=Ye.languages.css;var rt=Ye.languages.markup;rt&&(rt.tag.addInlined("style","css"),rt.tag.addAttribute("style","css"))})(t)}return css_1}var clike_1,hasRequiredClike;function requireClike(){if(hasRequiredClike)return clike_1;hasRequiredClike=1,clike_1=e,e.displayName="clike",e.aliases=[];function e(t){t.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/}}return clike_1}var javascript_1,hasRequiredJavascript;function requireJavascript(){if(hasRequiredJavascript)return javascript_1;hasRequiredJavascript=1,javascript_1=e,e.displayName="javascript",e.aliases=["js"];function e(t){t.languages.javascript=t.languages.extend("clike",{"class-name":[t.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+(/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|"+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source)+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),t.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,t.languages.insertBefore("javascript","keyword",{regex:{pattern:/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)\/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/,lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:t.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:t.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:t.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:t.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:t.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),t.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:t.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}}),t.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}}),t.languages.markup&&(t.languages.markup.tag.addInlined("script","javascript"),t.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript")),t.languages.js=t.languages.javascript}return javascript_1}var core$2,hasRequiredCore$2;function requireCore$2(){if(hasRequiredCore$2)return core$2;hasRequiredCore$2=1;var e=typeof globalThis=="object"?globalThis:typeof self=="object"?self:typeof window=="object"?window:typeof commonjsGlobal=="object"?commonjsGlobal:{},t=Xt();e.Prism={manual:!0,disableWorkerMessageHandler:!0};var Ye=requireHastscript(),tt=requireParseEntities(),rt=requirePrismCore(),nt=requireMarkup(),at=requireCss(),it=requireClike(),ot=requireJavascript();t();var ct={}.hasOwnProperty;function At(){}At.prototype=rt;var Rt=new At;core$2=Rt,Rt.highlight=Ut,Rt.register=qt,Rt.alias=Ft,Rt.registered=Ht,Rt.listLanguages=zt,qt(nt),qt(at),qt(it),qt(ot),Rt.util.encode=Vt,Rt.Token.stringify=Yt;function qt(Qt){if(typeof Qt!="function"||!Qt.displayName)throw new Error("Expected `function` for `grammar`, got `"+Qt+"`");Rt.languages[Qt.displayName]===void 0&&Qt(Rt)}function Ft(Qt,er){var nr=Rt.languages,ar=Qt,sr,lr,fr,gr;er&&(ar={},ar[Qt]=er);for(sr in ar)for(lr=ar[sr],lr=typeof lr=="string"?[lr]:lr,fr=lr.length,gr=-1;++gr<fr;)nr[lr[gr]]=nr[sr]}function Ut(Qt,er){var nr=rt.highlight,ar;if(typeof Qt!="string")throw new Error("Expected `string` for `value`, got `"+Qt+"`");if(Rt.util.type(er)==="Object")ar=er,er=null;else{if(typeof er!="string")throw new Error("Expected `string` for `name`, got `"+er+"`");if(ct.call(Rt.languages,er))ar=Rt.languages[er];else throw new Error("Unknown language: `"+er+"` is not registered")}return nr.call(this,Qt,ar,er)}function Ht(Qt){if(typeof Qt!="string")throw new Error("Expected `string` for `language`, got `"+Qt+"`");return ct.call(Rt.languages,Qt)}function zt(){var Qt=Rt.languages,er=[],nr;for(nr in Qt)ct.call(Qt,nr)&&typeof Qt[nr]=="object"&&er.push(nr);return er}function Yt(Qt,er,nr){var ar;return typeof Qt=="string"?{type:"text",value:Qt}:Rt.util.type(Qt)==="Array"?Gt(Qt,er):(ar={type:Qt.type,content:Rt.Token.stringify(Qt.content,er,nr),tag:"span",classes:["token",Qt.type],attributes:{},language:er,parent:nr},Qt.alias&&(ar.classes=ar.classes.concat(Qt.alias)),Rt.hooks.run("wrap",ar),Ye(ar.tag+"."+ar.classes.join("."),Zt(ar.attributes),ar.content))}function Gt(Qt,er){for(var nr=[],ar=Qt.length,sr=-1,lr;++sr<ar;)lr=Qt[sr],lr!==""&&lr!==null&&lr!==void 0&&nr.push(lr);for(sr=-1,ar=nr.length;++sr<ar;)lr=nr[sr],nr[sr]=Rt.Token.stringify(lr,er,nr);return nr}function Vt(Qt){return Qt}function Zt(Qt){var er;for(er in Qt)Qt[er]=tt(Qt[er]);return Qt}function Xt(){var Qt="Prism"in e,er=Qt?e.Prism:void 0;return nr;function nr(){Qt?e.Prism=er:delete e.Prism,Qt=void 0,er=void 0}}return core$2}const defaultStyle={'code[class*="language-"]':{color:"black",background:"none",textShadow:"0 1px white",fontFamily:"Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace",fontSize:"1em",textAlign:"left",whiteSpace:"pre",wordSpacing:"normal",wordBreak:"normal",wordWrap:"normal",lineHeight:"1.5",MozTabSize:"4",OTabSize:"4",tabSize:"4",WebkitHyphens:"none",MozHyphens:"none",msHyphens:"none",hyphens:"none"},'pre[class*="language-"]':{color:"black",background:"#f5f2f0",textShadow:"0 1px white",fontFamily:"Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace",fontSize:"1em",textAlign:"left",whiteSpace:"pre",wordSpacing:"normal",wordBreak:"normal",wordWrap:"normal",lineHeight:"1.5",MozTabSize:"4",OTabSize:"4",tabSize:"4",WebkitHyphens:"none",MozHyphens:"none",msHyphens:"none",hyphens:"none",padding:"1em",margin:".5em 0",overflow:"auto"},'pre[class*="language-"]::-moz-selection':{textShadow:"none",background:"#b3d4fc"},'pre[class*="language-"] ::-moz-selection':{textShadow:"none",background:"#b3d4fc"},'code[class*="language-"]::-moz-selection':{textShadow:"none",background:"#b3d4fc"},'code[class*="language-"] ::-moz-selection':{textShadow:"none",background:"#b3d4fc"},'pre[class*="language-"]::selection':{textShadow:"none",background:"#b3d4fc"},'pre[class*="language-"] ::selection':{textShadow:"none",background:"#b3d4fc"},'code[class*="language-"]::selection':{textShadow:"none",background:"#b3d4fc"},'code[class*="language-"] ::selection':{textShadow:"none",background:"#b3d4fc"},':not(pre) > code[class*="language-"]':{background:"#f5f2f0",padding:".1em",borderRadius:".3em",whiteSpace:"normal"},comment:{color:"slategray"},prolog:{color:"slategray"},doctype:{color:"slategray"},cdata:{color:"slategray"},punctuation:{color:"#999"},namespace:{Opacity:".7"},property:{color:"#905"},tag:{color:"#905"},boolean:{color:"#905"},number:{color:"#905"},constant:{color:"#905"},symbol:{color:"#905"},deleted:{color:"#905"},selector:{color:"#690"},"attr-name":{color:"#690"},string:{color:"#690"},char:{color:"#690"},builtin:{color:"#690"},inserted:{color:"#690"},operator:{color:"#9a6e3a",background:"hsla(0, 0%, 100%, .5)"},entity:{color:"#9a6e3a",background:"hsla(0, 0%, 100%, .5)",cursor:"help"},url:{color:"#9a6e3a",background:"hsla(0, 0%, 100%, .5)"},".language-css .token.string":{color:"#9a6e3a",background:"hsla(0, 0%, 100%, .5)"},".style .token.string":{color:"#9a6e3a",background:"hsla(0, 0%, 100%, .5)"},atrule:{color:"#07a"},"attr-value":{color:"#07a"},keyword:{color:"#07a"},function:{color:"#DD4A68"},"class-name":{color:"#DD4A68"},regex:{color:"#e90"},important:{color:"#e90",fontWeight:"bold"},variable:{color:"#e90"},bold:{fontWeight:"bold"},italic:{fontStyle:"italic"}};var abap_1,hasRequiredAbap;function requireAbap(){if(hasRequiredAbap)return abap_1;hasRequiredAbap=1,abap_1=e,e.displayName="abap",e.aliases=[];function e(t){t.languages.abap={comment:/^\*.*/m,string:/(`|')(?:\\.|(?!\1)[^\\\r\n])*\1/,"string-template":{pattern:/([|}])(?:\\.|[^\\|{\r\n])*(?=[|{])/,lookbehind:!0,alias:"string"},"eol-comment":{pattern:/(^|\s)".*/m,lookbehind:!0,alias:"comment"},keyword:{pattern:/(\s|\.|^)(?:SCIENTIFIC_WITH_LEADING_ZERO|SCALE_PRESERVING_SCIENTIFIC|RMC_COMMUNICATION_FAILURE|END-ENHANCEMENT-SECTION|MULTIPLY-CORRESPONDING|SUBTRACT-CORRESPONDING|VERIFICATION-MESSAGE|DIVIDE-CORRESPONDING|ENHANCEMENT-SECTION|CURRENCY_CONVERSION|RMC_SYSTEM_FAILURE|START-OF-SELECTION|MOVE-CORRESPONDING|RMC_INVALID_STATUS|CUSTOMER-FUNCTION|END-OF-DEFINITION|ENHANCEMENT-POINT|SYSTEM-EXCEPTIONS|ADD-CORRESPONDING|SCALE_PRESERVING|SELECTION-SCREEN|CURSOR-SELECTION|END-OF-SELECTION|LOAD-OF-PROGRAM|SCROLL-BOUNDARY|SELECTION-TABLE|EXCEPTION-TABLE|IMPLEMENTATIONS|PARAMETER-TABLE|RIGHT-JUSTIFIED|UNIT_CONVERSION|AUTHORITY-CHECK|LIST-PROCESSING|SIGN_AS_POSTFIX|COL_BACKGROUND|IMPLEMENTATION|INTERFACE-POOL|TRANSFORMATION|IDENTIFICATION|ENDENHANCEMENT|LINE-SELECTION|INITIALIZATION|LEFT-JUSTIFIED|SELECT-OPTIONS|SELECTION-SETS|COMMUNICATION|CORRESPONDING|DECIMAL_SHIFT|PRINT-CONTROL|VALUE-REQUEST|CHAIN-REQUEST|FUNCTION-POOL|FIELD-SYMBOLS|FUNCTIONALITY|INVERTED-DATE|SELECTION-SET|CLASS-METHODS|OUTPUT-LENGTH|CLASS-CODING|COL_NEGATIVE|ERRORMESSAGE|FIELD-GROUPS|HELP-REQUEST|NO-EXTENSION|NO-TOPOFPAGE|REDEFINITION|DISPLAY-MODE|ENDINTERFACE|EXIT-COMMAND|FIELD-SYMBOL|NO-SCROLLING|SHORTDUMP-ID|ACCESSPOLICY|CLASS-EVENTS|COL_POSITIVE|DECLARATIONS|ENHANCEMENTS|FILTER-TABLE|SWITCHSTATES|SYNTAX-CHECK|TRANSPORTING|ASYNCHRONOUS|SYNTAX-TRACE|TOKENIZATION|USER-COMMAND|WITH-HEADING|ABAP-SOURCE|BREAK-POINT|CHAIN-INPUT|COMPRESSION|FIXED-POINT|NEW-SECTION|NON-UNICODE|OCCURRENCES|RESPONSIBLE|SYSTEM-CALL|TRACE-TABLE|ABBREVIATED|CHAR-TO-HEX|END-OF-FILE|ENDFUNCTION|ENVIRONMENT|ASSOCIATION|COL_HEADING|EDITOR-CALL|END-OF-PAGE|ENGINEERING|IMPLEMENTED|INTENSIFIED|RADIOBUTTON|SYSTEM-EXIT|TOP-OF-PAGE|TRANSACTION|APPLICATION|CONCATENATE|DESTINATION|ENHANCEMENT|IMMEDIATELY|NO-GROUPING|PRECOMPILED|REPLACEMENT|TITLE-LINES|ACTIVATION|BYTE-ORDER|CLASS-POOL|CONNECTION|CONVERSION|DEFINITION|DEPARTMENT|EXPIRATION|INHERITING|MESSAGE-ID|NO-HEADING|PERFORMING|QUEUE-ONLY|RIGHTSPACE|SCIENTIFIC|STATUSINFO|STRUCTURES|SYNCPOINTS|WITH-TITLE|ATTRIBUTES|BOUNDARIES|CLASS-DATA|COL_NORMAL|DD\/MM\/YYYY|DESCENDING|INTERFACES|LINE-COUNT|MM\/DD\/YYYY|NON-UNIQUE|PRESERVING|SELECTIONS|STATEMENTS|SUBROUTINE|TRUNCATION|TYPE-POOLS|ARITHMETIC|BACKGROUND|ENDPROVIDE|EXCEPTIONS|IDENTIFIER|INDEX-LINE|OBLIGATORY|PARAMETERS|PERCENTAGE|PUSHBUTTON|RESOLUTION|COMPONENTS|DEALLOCATE|DISCONNECT|DUPLICATES|FIRST-LINE|HEAD-LINES|NO-DISPLAY|OCCURRENCE|RESPECTING|RETURNCODE|SUBMATCHES|TRACE-FILE|ASCENDING|BYPASSING|ENDMODULE|EXCEPTION|EXCLUDING|EXPORTING|INCREMENT|MATCHCODE|PARAMETER|PARTIALLY|PREFERRED|REFERENCE|REPLACING|RETURNING|SELECTION|SEPARATED|SPECIFIED|STATEMENT|TIMESTAMP|TYPE-POOL|ACCEPTING|APPENDAGE|ASSIGNING|COL_GROUP|COMPARING|CONSTANTS|DANGEROUS|IMPORTING|INSTANCES|LEFTSPACE|LOG-POINT|QUICKINFO|READ-ONLY|SCROLLING|SQLSCRIPT|STEP-LOOP|TOP-LINES|TRANSLATE|APPENDING|AUTHORITY|CHARACTER|COMPONENT|CONDITION|DIRECTORY|DUPLICATE|MESSAGING|RECEIVING|SUBSCREEN|ACCORDING|COL_TOTAL|END-LINES|ENDMETHOD|ENDSELECT|EXPANDING|EXTENSION|INCLUDING|INFOTYPES|INTERFACE|INTERVALS|LINE-SIZE|PF-STATUS|PROCEDURE|PROTECTED|REQUESTED|RESUMABLE|RIGHTPLUS|SAP-SPOOL|SECONDARY|STRUCTURE|SUBSTRING|TABLEVIEW|NUMOFCHAR|ADJACENT|ANALYSIS|ASSIGNED|BACKWARD|CHANNELS|CHECKBOX|CONTINUE|CRITICAL|DATAINFO|DD\/MM\/YY|DURATION|ENCODING|ENDCLASS|FUNCTION|LEFTPLUS|LINEFEED|MM\/DD\/YY|OVERFLOW|RECEIVED|SKIPPING|SORTABLE|STANDARD|SUBTRACT|SUPPRESS|TABSTRIP|TITLEBAR|TRUNCATE|UNASSIGN|WHENEVER|ANALYZER|COALESCE|COMMENTS|CONDENSE|DECIMALS|DEFERRED|ENDWHILE|EXPLICIT|KEYWORDS|MESSAGES|POSITION|PRIORITY|RECEIVER|RENAMING|TIMEZONE|TRAILING|ALLOCATE|CENTERED|CIRCULAR|CONTROLS|CURRENCY|DELETING|DESCRIBE|DISTANCE|ENDCATCH|EXPONENT|EXTENDED|GENERATE|IGNORING|INCLUDES|INTERNAL|MAJOR-ID|MODIFIER|NEW-LINE|OPTIONAL|PROPERTY|ROLLBACK|STARTING|SUPPLIED|ABSTRACT|CHANGING|CONTEXTS|CREATING|CUSTOMER|DATABASE|DAYLIGHT|DEFINING|DISTINCT|DIVISION|ENABLING|ENDCHAIN|ESCAPING|HARMLESS|IMPLICIT|INACTIVE|LANGUAGE|MINOR-ID|MULTIPLY|NEW-PAGE|NO-TITLE|POS_HIGH|SEPARATE|TEXTPOOL|TRANSFER|SELECTOR|DBMAXLEN|ITERATOR|ARCHIVE|BIT-XOR|BYTE-CO|COLLECT|COMMENT|CURRENT|DEFAULT|DISPLAY|ENDFORM|EXTRACT|LEADING|LISTBOX|LOCATOR|MEMBERS|METHODS|NESTING|POS_LOW|PROCESS|PROVIDE|RAISING|RESERVE|SECONDS|SUMMARY|VISIBLE|BETWEEN|BIT-AND|BYTE-CS|CLEANUP|COMPUTE|CONTROL|CONVERT|DATASET|ENDCASE|FORWARD|HEADERS|HOTSPOT|INCLUDE|INVERSE|KEEPING|NO-ZERO|OBJECTS|OVERLAY|PADDING|PATTERN|PROGRAM|REFRESH|SECTION|SUMMING|TESTING|VERSION|WINDOWS|WITHOUT|BIT-NOT|BYTE-CA|BYTE-NA|CASTING|CONTEXT|COUNTRY|DYNAMIC|ENABLED|ENDLOOP|EXECUTE|FRIENDS|HANDLER|HEADING|INITIAL|\*-INPUT|LOGFILE|MAXIMUM|MINIMUM|NO-GAPS|NO-SIGN|PRAGMAS|PRIMARY|PRIVATE|REDUCED|REPLACE|REQUEST|RESULTS|UNICODE|WARNING|ALIASES|BYTE-CN|BYTE-NS|CALLING|COL_KEY|COLUMNS|CONNECT|ENDEXEC|ENTRIES|EXCLUDE|FILTERS|FURTHER|HELP-ID|LOGICAL|MAPPING|MESSAGE|NAMETAB|OPTIONS|PACKAGE|PERFORM|RECEIVE|STATICS|VARYING|BINDING|CHARLEN|GREATER|XSTRLEN|ACCEPT|APPEND|DETAIL|ELSEIF|ENDING|ENDTRY|FORMAT|FRAMES|GIVING|HASHED|HEADER|IMPORT|INSERT|MARGIN|MODULE|NATIVE|OBJECT|OFFSET|REMOTE|RESUME|SAVING|SIMPLE|SUBMIT|TABBED|TOKENS|UNIQUE|UNPACK|UPDATE|WINDOW|YELLOW|ACTUAL|ASPECT|CENTER|CURSOR|DELETE|DIALOG|DIVIDE|DURING|ERRORS|EVENTS|EXTEND|FILTER|HANDLE|HAVING|IGNORE|LITTLE|MEMORY|NO-GAP|OCCURS|OPTION|PERSON|PLACES|PUBLIC|REDUCE|REPORT|RESULT|SINGLE|SORTED|SWITCH|SYNTAX|TARGET|VALUES|WRITER|ASSERT|BLOCKS|BOUNDS|BUFFER|CHANGE|COLUMN|COMMIT|CONCAT|COPIES|CREATE|DDMMYY|DEFINE|ENDIAN|ESCAPE|EXPAND|KERNEL|LAYOUT|LEGACY|LEVELS|MMDDYY|NUMBER|OUTPUT|RANGES|READER|RETURN|SCREEN|SEARCH|SELECT|SHARED|SOURCE|STABLE|STATIC|SUBKEY|SUFFIX|TABLES|UNWIND|YYMMDD|ASSIGN|BACKUP|BEFORE|BINARY|BIT-OR|BLANKS|CLIENT|CODING|COMMON|DEMAND|DYNPRO|EXCEPT|EXISTS|EXPORT|FIELDS|GLOBAL|GROUPS|LENGTH|LOCALE|MEDIUM|METHOD|MODIFY|NESTED|OTHERS|REJECT|SCROLL|SUPPLY|SYMBOL|ENDFOR|STRLEN|ALIGN|BEGIN|BOUND|ENDAT|ENTRY|EVENT|FINAL|FLUSH|GRANT|INNER|SHORT|USING|WRITE|AFTER|BLACK|BLOCK|CLOCK|COLOR|COUNT|DUMMY|EMPTY|ENDDO|ENDON|GREEN|INDEX|INOUT|LEAVE|LEVEL|LINES|MODIF|ORDER|OUTER|RANGE|RESET|RETRY|RIGHT|SMART|SPLIT|STYLE|TABLE|THROW|UNDER|UNTIL|UPPER|UTF-8|WHERE|ALIAS|BLANK|CLEAR|CLOSE|EXACT|FETCH|FIRST|FOUND|GROUP|LLANG|LOCAL|OTHER|REGEX|SPOOL|TITLE|TYPES|VALID|WHILE|ALPHA|BOXED|CATCH|CHAIN|CHECK|CLASS|COVER|ENDIF|EQUIV|FIELD|FLOOR|FRAME|INPUT|LOWER|MATCH|NODES|PAGES|PRINT|RAISE|ROUND|SHIFT|SPACE|SPOTS|STAMP|STATE|TASKS|TIMES|TRMAC|ULINE|UNION|VALUE|WIDTH|EQUAL|LOG10|TRUNC|BLOB|CASE|CEIL|CLOB|COND|EXIT|FILE|GAPS|HOLD|INCL|INTO|KEEP|KEYS|LAST|LINE|LONG|LPAD|MAIL|MODE|OPEN|PINK|READ|ROWS|TEST|THEN|ZERO|AREA|BACK|BADI|BYTE|CAST|EDIT|EXEC|FAIL|FIND|FKEQ|FONT|FREE|GKEQ|HIDE|INIT|ITNO|LATE|LOOP|MAIN|MARK|MOVE|NEXT|NULL|RISK|ROLE|UNIT|WAIT|ZONE|BASE|CALL|CODE|DATA|DATE|FKGE|GKGE|HIGH|KIND|LEFT|LIST|MASK|MESH|NAME|NODE|PACK|PAGE|POOL|SEND|SIGN|SIZE|SOME|STOP|TASK|TEXT|TIME|USER|VARY|WITH|WORD|BLUE|CONV|COPY|DEEP|ELSE|FORM|FROM|HINT|ICON|JOIN|LIKE|LOAD|ONLY|PART|SCAN|SKIP|SORT|TYPE|UNIX|VIEW|WHEN|WORK|ACOS|ASIN|ATAN|COSH|EACH|FRAC|LESS|RTTI|SINH|SQRT|TANH|AVG|BIT|DIV|ISO|LET|OUT|PAD|SQL|ALL|CI_|CPI|END|LOB|LPI|MAX|MIN|NEW|OLE|RUN|SET|\?TO|YES|ABS|ADD|AND|BIG|FOR|HDB|JOB|LOW|NOT|SAP|TRY|VIA|XML|ANY|GET|IDS|KEY|MOD|OFF|PUT|RAW|RED|REF|SUM|TAB|XSD|CNT|COS|EXP|LOG|SIN|TAN|XOR|AT|CO|CP|DO|GT|ID|IF|NS|OR|BT|CA|CS|GE|NA|NB|EQ|IN|LT|NE|NO|OF|ON|PF|TO|AS|BY|CN|IS|LE|NP|UP|E|I|M|O|Z|C|X)\b/i,lookbehind:!0},number:/\b\d+\b/,operator:{pattern:/(\s)(?:\*\*?|<[=>]?|>=?|\?=|[-+\/=])(?=\s)/,lookbehind:!0},"string-operator":{pattern:/(\s)&&?(?=\s)/,lookbehind:!0,alias:"keyword"},"token-operator":[{pattern:/(\w)(?:->?|=>|[~|{}])(?=\w)/,lookbehind:!0,alias:"punctuation"},{pattern:/[|{}]/,alias:"punctuation"}],punctuation:/[,.:()]/}}return abap_1}var abnf_1,hasRequiredAbnf;function requireAbnf(){if(hasRequiredAbnf)return abnf_1;hasRequiredAbnf=1,abnf_1=e,e.displayName="abnf",e.aliases=[];function e(t){(function(Ye){var tt="(?:ALPHA|BIT|CHAR|CR|CRLF|CTL|DIGIT|DQUOTE|HEXDIG|HTAB|LF|LWSP|OCTET|SP|VCHAR|WSP)";Ye.languages.abnf={comment:/;.*/,string:{pattern:/(?:%[is])?"[^"\n\r]*"/,greedy:!0,inside:{punctuation:/^%[is]/}},range:{pattern:/%(?:b[01]+-[01]+|d\d+-\d+|x[A-F\d]+-[A-F\d]+)/i,alias:"number"},terminal:{pattern:/%(?:b[01]+(?:\.[01]+)*|d\d+(?:\.\d+)*|x[A-F\d]+(?:\.[A-F\d]+)*)/i,alias:"number"},repetition:{pattern:/(^|[^\w-])(?:\d*\*\d*|\d+)/,lookbehind:!0,alias:"operator"},definition:{pattern:/(^[ \t]*)(?:[a-z][\w-]*|<[^<>\r\n]*>)(?=\s*=)/m,lookbehind:!0,alias:"keyword",inside:{punctuation:/<|>/}},"core-rule":{pattern:RegExp("(?:(^|[^<\\w-])"+tt+"|<"+tt+">)(?![\\w-])","i"),lookbehind:!0,alias:["rule","constant"],inside:{punctuation:/<|>/}},rule:{pattern:/(^|[^<\w-])[a-z][\w-]*|<[^<>\r\n]*>/i,lookbehind:!0,inside:{punctuation:/<|>/}},operator:/=\/?|\//,punctuation:/[()\[\]]/}})(t)}return abnf_1}var actionscript_1,hasRequiredActionscript;function requireActionscript(){if(hasRequiredActionscript)return actionscript_1;hasRequiredActionscript=1,actionscript_1=e,e.displayName="actionscript",e.aliases=[];function e(t){t.languages.actionscript=t.languages.extend("javascript",{keyword:/\b(?:as|break|case|catch|class|const|default|delete|do|dynamic|each|else|extends|final|finally|for|function|get|if|implements|import|in|include|instanceof|interface|internal|is|namespace|native|new|null|override|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|use|var|void|while|with)\b/,operator:/\+\+|--|(?:[+\-*\/%^]|&&?|\|\|?|<<?|>>?>?|[!=]=?)=?|[~?@]/}),t.languages.actionscript["class-name"].alias="function",delete t.languages.actionscript.parameter,delete t.languages.actionscript["literal-property"],t.languages.markup&&t.languages.insertBefore("actionscript","string",{xml:{pattern:/(^|[^.])<\/?\w+(?:\s+[^\s>\/=]+=("|')(?:\\[\s\S]|(?!\2)[^\\])*\2)*\s*\/?>/,lookbehind:!0,inside:t.languages.markup}})}return actionscript_1}var ada_1,hasRequiredAda;function requireAda(){if(hasRequiredAda)return ada_1;hasRequiredAda=1,ada_1=e,e.displayName="ada",e.aliases=[];function e(t){t.languages.ada={comment:/--.*/,string:/"(?:""|[^"\r\f\n])*"/,number:[{pattern:/\b\d(?:_?\d)*#[\dA-F](?:_?[\dA-F])*(?:\.[\dA-F](?:_?[\dA-F])*)?#(?:E[+-]?\d(?:_?\d)*)?/i},{pattern:/\b\d(?:_?\d)*(?:\.\d(?:_?\d)*)?(?:E[+-]?\d(?:_?\d)*)?\b/i}],"attr-name":/\b'\w+/,keyword:/\b(?:abort|abs|abstract|accept|access|aliased|all|and|array|at|begin|body|case|constant|declare|delay|delta|digits|do|else|elsif|end|entry|exception|exit|for|function|generic|goto|if|in|interface|is|limited|loop|mod|new|not|null|of|others|out|overriding|package|pragma|private|procedure|protected|raise|range|record|rem|renames|requeue|return|reverse|select|separate|some|subtype|synchronized|tagged|task|terminate|then|type|until|use|when|while|with|xor)\b/i,boolean:/\b(?:false|true)\b/i,operator:/<[=>]?|>=?|=>?|:=|\/=?|\*\*?|[&+-]/,punctuation:/\.\.?|[,;():]/,char:/'.'/,variable:/\b[a-z](?:\w)*\b/i}}return ada_1}var agda_1,hasRequiredAgda;function requireAgda(){if(hasRequiredAgda)return agda_1;hasRequiredAgda=1,agda_1=e,e.displayName="agda",e.aliases=[];function e(t){(function(Ye){Ye.languages.agda={comment:/\{-[\s\S]*?(?:-\}|$)|--.*/,string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^\\\r\n"])*"/,greedy:!0},punctuation:/[(){}⦃⦄.;@]/,"class-name":{pattern:/((?:data|record) +)\S+/,lookbehind:!0},function:{pattern:/(^[ \t]*)(?!\s)[^:\r\n]+(?=:)/m,lookbehind:!0},operator:{pattern:/(^\s*|\s)(?:[=|:∀→λ\\?_]|->)(?=\s)/,lookbehind:!0},keyword:/\b(?:Set|abstract|constructor|data|eta-equality|field|forall|hiding|import|in|inductive|infix|infixl|infixr|instance|let|macro|module|mutual|no-eta-equality|open|overlap|pattern|postulate|primitive|private|public|quote|quoteContext|quoteGoal|quoteTerm|record|renaming|rewrite|syntax|tactic|unquote|unquoteDecl|unquoteDef|using|variable|where|with)\b/}})(t)}return agda_1}var al_1,hasRequiredAl;function requireAl(){if(hasRequiredAl)return al_1;hasRequiredAl=1,al_1=e,e.displayName="al",e.aliases=[];function e(t){t.languages.al={comment:/\/\/.*|\/\*[\s\S]*?\*\//,string:{pattern:/'(?:''|[^'\r\n])*'(?!')|"(?:""|[^"\r\n])*"(?!")/,greedy:!0},function:{pattern:/(\b(?:event|procedure|trigger)\s+|(?:^|[^.])\.\s*)[a-z_]\w*(?=\s*\()/i,lookbehind:!0},keyword:[/\b(?:array|asserterror|begin|break|case|do|downto|else|end|event|exit|for|foreach|function|if|implements|in|indataset|interface|internal|local|of|procedure|program|protected|repeat|runonclient|securityfiltering|suppressdispose|temporary|then|to|trigger|until|var|while|with|withevents)\b/i,/\b(?:action|actions|addafter|addbefore|addfirst|addlast|area|assembly|chartpart|codeunit|column|controladdin|cuegroup|customizes|dataitem|dataset|dotnet|elements|enum|enumextension|extends|field|fieldattribute|fieldelement|fieldgroup|fieldgroups|fields|filter|fixed|grid|group|key|keys|label|labels|layout|modify|moveafter|movebefore|movefirst|movelast|page|pagecustomization|pageextension|part|profile|query|repeater|report|requestpage|schema|separator|systempart|table|tableelement|tableextension|textattribute|textelement|type|usercontrol|value|xmlport)\b/i],number:/\b(?:0x[\da-f]+|(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?)(?:F|LL?|U(?:LL?)?)?\b/i,boolean:/\b(?:false|true)\b/i,variable:/\b(?:Curr(?:FieldNo|Page|Report)|x?Rec|RequestOptionsPage)\b/,"class-name":/\b(?:automation|biginteger|bigtext|blob|boolean|byte|char|clienttype|code|completiontriggererrorlevel|connectiontype|database|dataclassification|datascope|date|dateformula|datetime|decimal|defaultlayout|dialog|dictionary|dotnetassembly|dotnettypedeclaration|duration|errorinfo|errortype|executioncontext|executionmode|fieldclass|fieldref|fieldtype|file|filterpagebuilder|guid|httpclient|httpcontent|httpheaders|httprequestmessage|httpresponsemessage|instream|integer|joker|jsonarray|jsonobject|jsontoken|jsonvalue|keyref|list|moduledependencyinfo|moduleinfo|none|notification|notificationscope|objecttype|option|outstream|pageresult|record|recordid|recordref|reportformat|securityfilter|sessionsettings|tableconnectiontype|tablefilter|testaction|testfield|testfilterfield|testpage|testpermissions|testrequestpage|text|textbuilder|textconst|textencoding|time|transactionmodel|transactiontype|variant|verbosity|version|view|views|webserviceactioncontext|webserviceactionresultcode|xmlattribute|xmlattributecollection|xmlcdata|xmlcomment|xmldeclaration|xmldocument|xmldocumenttype|xmlelement|xmlnamespacemanager|xmlnametable|xmlnode|xmlnodelist|xmlprocessinginstruction|xmlreadoptions|xmltext|xmlwriteoptions)\b/i,operator:/\.\.|:[=:]|[-+*/]=?|<>|[<>]=?|=|\b(?:and|div|mod|not|or|xor)\b/i,punctuation:/[()\[\]{}:.;,]/}}return al_1}var antlr4_1,hasRequiredAntlr4;function requireAntlr4(){if(hasRequiredAntlr4)return antlr4_1;hasRequiredAntlr4=1,antlr4_1=e,e.displayName="antlr4",e.aliases=["g4"];function e(t){t.languages.antlr4={comment:/\/\/.*|\/\*[\s\S]*?(?:\*\/|$)/,string:{pattern:/'(?:\\.|[^\\'\r\n])*'/,greedy:!0},"character-class":{pattern:/\[(?:\\.|[^\\\]\r\n])*\]/,greedy:!0,alias:"regex",inside:{range:{pattern:/([^[]|(?:^|[^\\])(?:\\\\)*\\\[)-(?!\])/,lookbehind:!0,alias:"punctuation"},escape:/\\(?:u(?:[a-fA-F\d]{4}|\{[a-fA-F\d]+\})|[pP]\{[=\w-]+\}|[^\r\nupP])/,punctuation:/[\[\]]/}},action:{pattern:/\{(?:[^{}]|\{(?:[^{}]|\{(?:[^{}]|\{[^{}]*\})*\})*\})*\}/,greedy:!0,inside:{content:{pattern:/(\{)[\s\S]+(?=\})/,lookbehind:!0},punctuation:/[{}]/}},command:{pattern:/(->\s*(?!\s))(?:\s*(?:,\s*)?\b[a-z]\w*(?:\s*\([^()\r\n]*\))?)+(?=\s*;)/i,lookbehind:!0,inside:{function:/\b\w+(?=\s*(?:[,(]|$))/,punctuation:/[,()]/}},annotation:{pattern:/@\w+(?:::\w+)*/,alias:"keyword"},label:{pattern:/#[ \t]*\w+/,alias:"punctuation"},keyword:/\b(?:catch|channels|finally|fragment|grammar|import|lexer|locals|mode|options|parser|returns|throws|tokens)\b/,definition:[{pattern:/\b[a-z]\w*(?=\s*:)/,alias:["rule","class-name"]},{pattern:/\b[A-Z]\w*(?=\s*:)/,alias:["token","constant"]}],constant:/\b[A-Z][A-Z_]*\b/,operator:/\.\.|->|[|~]|[*+?]\??/,punctuation:/[;:()=]/},t.languages.g4=t.languages.antlr4}return antlr4_1}var apacheconf_1,hasRequiredApacheconf;function requireApacheconf(){if(hasRequiredApacheconf)return apacheconf_1;hasRequiredApacheconf=1,apacheconf_1=e,e.displayName="apacheconf",e.aliases=[];function e(t){t.languages.apacheconf={comment:/#.*/,"directive-inline":{pattern:/(^[\t ]*)\b(?:AcceptFilter|AcceptPathInfo|AccessFileName|Action|Add(?:Alt|AltByEncoding|AltByType|Charset|DefaultCharset|Description|Encoding|Handler|Icon|IconByEncoding|IconByType|InputFilter|Language|ModuleInfo|OutputFilter|OutputFilterByType|Type)|Alias|AliasMatch|Allow(?:CONNECT|EncodedSlashes|Methods|Override|OverrideList)?|Anonymous(?:_LogEmail|_MustGiveEmail|_NoUserID|_VerifyEmail)?|AsyncRequestWorkerFactor|Auth(?:BasicAuthoritative|BasicFake|BasicProvider|BasicUseDigestAlgorithm|DBDUserPWQuery|DBDUserRealmQuery|DBMGroupFile|DBMType|DBMUserFile|Digest(?:Algorithm|Domain|NonceLifetime|Provider|Qop|ShmemSize)|Form(?:Authoritative|Body|DisableNoStore|FakeBasicAuth|Location|LoginRequiredLocation|LoginSuccessLocation|LogoutLocation|Method|Mimetype|Password|Provider|SitePassphrase|Size|Username)|GroupFile|LDAP(?:AuthorizePrefix|BindAuthoritative|BindDN|BindPassword|CharsetConfig|CompareAsUser|CompareDNOnServer|DereferenceAliases|GroupAttribute|GroupAttributeIsDN|InitialBindAsUser|InitialBindPattern|MaxSubGroupDepth|RemoteUserAttribute|RemoteUserIsDN|SearchAsUser|SubGroupAttribute|SubGroupClass|Url)|Merging|Name|nCache(?:Context|Enable|ProvideFor|SOCache|Timeout)|nzFcgiCheckAuthnProvider|nzFcgiDefineProvider|Type|UserFile|zDBDLoginToReferer|zDBDQuery|zDBDRedirectQuery|zDBMType|zSendForbiddenOnFailure)|BalancerGrowth|BalancerInherit|BalancerMember|BalancerPersist|BrowserMatch|BrowserMatchNoCase|BufferedLogs|BufferSize|Cache(?:DefaultExpire|DetailHeader|DirLength|DirLevels|Disable|Enable|File|Header|IgnoreCacheControl|IgnoreHeaders|IgnoreNoLastMod|IgnoreQueryString|IgnoreURLSessionIdentifiers|KeyBaseURL|LastModifiedFactor|Lock|LockMaxAge|LockPath|MaxExpire|MaxFileSize|MinExpire|MinFileSize|NegotiatedDocs|QuickHandler|ReadSize|ReadTime|Root|Socache(?:MaxSize|MaxTime|MinTime|ReadSize|ReadTime)?|StaleOnError|StoreExpired|StoreNoStore|StorePrivate)|CGIDScriptTimeout|CGIMapExtension|CharsetDefault|CharsetOptions|CharsetSourceEnc|CheckCaseOnly|CheckSpelling|ChrootDir|ContentDigest|CookieDomain|CookieExpires|CookieName|CookieStyle|CookieTracking|CoreDumpDirectory|CustomLog|Dav|DavDepthInfinity|DavGenericLockDB|DavLockDB|DavMinTimeout|DBDExptime|DBDInitSQL|DBDKeep|DBDMax|DBDMin|DBDParams|DBDPersist|DBDPrepareSQL|DBDriver|DefaultIcon|DefaultLanguage|DefaultRuntimeDir|DefaultType|Define|Deflate(?:BufferSize|CompressionLevel|FilterNote|InflateLimitRequestBody|InflateRatio(?:Burst|Limit)|MemLevel|WindowSize)|Deny|DirectoryCheckHandler|DirectoryIndex|DirectoryIndexRedirect|DirectorySlash|DocumentRoot|DTracePrivileges|DumpIOInput|DumpIOOutput|EnableExceptionHook|EnableMMAP|EnableSendfile|Error|ErrorDocument|ErrorLog|ErrorLogFormat|Example|ExpiresActive|ExpiresByType|ExpiresDefault|ExtendedStatus|ExtFilterDefine|ExtFilterOptions|FallbackResource|FileETag|FilterChain|FilterDeclare|FilterProtocol|FilterProvider|FilterTrace|ForceLanguagePriority|ForceType|ForensicLog|GprofDir|GracefulShutdownTimeout|Group|Header|HeaderName|Heartbeat(?:Address|Listen|MaxServers|Storage)|HostnameLookups|IdentityCheck|IdentityCheckTimeout|ImapBase|ImapDefault|ImapMenu|Include|IncludeOptional|Index(?:HeadInsert|Ignore|IgnoreReset|Options|OrderDefault|StyleSheet)|InputSed|ISAPI(?:AppendLogToErrors|AppendLogToQuery|CacheFile|FakeAsync|LogNotSupported|ReadAheadBuffer)|KeepAlive|KeepAliveTimeout|KeptBodySize|LanguagePriority|LDAP(?:CacheEntries|CacheTTL|ConnectionPoolTTL|ConnectionTimeout|LibraryDebug|OpCacheEntries|OpCacheTTL|ReferralHopLimit|Referrals|Retries|RetryDelay|SharedCacheFile|SharedCacheSize|Timeout|TrustedClientCert|TrustedGlobalCert|TrustedMode|VerifyServerCert)|Limit(?:InternalRecursion|Request(?:Body|Fields|FieldSize|Line)|XMLRequestBody)|Listen|ListenBackLog|LoadFile|LoadModule|LogFormat|LogLevel|LogMessage|LuaAuthzProvider|LuaCodeCache|Lua(?:Hook(?:AccessChecker|AuthChecker|CheckUserID|Fixups|InsertFilter|Log|MapToStorage|TranslateName|TypeChecker)|Inherit|InputFilter|MapHandler|OutputFilter|PackageCPath|PackagePath|QuickHandler|Root|Scope)|Max(?:ConnectionsPerChild|KeepAliveRequests|MemFree|RangeOverlaps|RangeReversals|Ranges|RequestWorkers|SpareServers|SpareThreads|Threads)|MergeTrailers|MetaDir|MetaFiles|MetaSuffix|MimeMagicFile|MinSpareServers|MinSpareThreads|MMapFile|ModemStandard|ModMimeUsePathInfo|MultiviewsMatch|Mutex|NameVirtualHost|NoProxy|NWSSLTrustedCerts|NWSSLUpgradeable|Options|Order|OutputSed|PassEnv|PidFile|PrivilegesMode|Protocol|ProtocolEcho|Proxy(?:AddHeaders|BadHeader|Block|Domain|ErrorOverride|ExpressDBMFile|ExpressDBMType|ExpressEnable|FtpDirCharset|FtpEscapeWildcards|FtpListOnWildcard|HTML(?:BufSize|CharsetOut|DocType|Enable|Events|Extended|Fixups|Interp|Links|Meta|StripComments|URLMap)|IOBufferSize|MaxForwards|Pass(?:Inherit|InterpolateEnv|Match|Reverse|ReverseCookieDomain|ReverseCookiePath)?|PreserveHost|ReceiveBufferSize|Remote|RemoteMatch|Requests|SCGIInternalRedirect|SCGISendfile|Set|SourceAddress|Status|Timeout|Via)|ReadmeName|ReceiveBufferSize|Redirect|RedirectMatch|RedirectPermanent|RedirectTemp|ReflectorHeader|RemoteIP(?:Header|InternalProxy|InternalProxyList|ProxiesHeader|TrustedProxy|TrustedProxyList)|RemoveCharset|RemoveEncoding|RemoveHandler|RemoveInputFilter|RemoveLanguage|RemoveOutputFilter|RemoveType|RequestHeader|RequestReadTimeout|Require|Rewrite(?:Base|Cond|Engine|Map|Options|Rule)|RLimitCPU|RLimitMEM|RLimitNPROC|Satisfy|ScoreBoardFile|Script(?:Alias|AliasMatch|InterpreterSource|Log|LogBuffer|LogLength|Sock)?|SecureListen|SeeRequestTail|SendBufferSize|Server(?:Admin|Alias|Limit|Name|Path|Root|Signature|Tokens)|Session(?:Cookie(?:Name|Name2|Remove)|Crypto(?:Cipher|Driver|Passphrase|PassphraseFile)|DBD(?:CookieName|CookieName2|CookieRemove|DeleteLabel|InsertLabel|PerUser|SelectLabel|UpdateLabel)|Env|Exclude|Header|Include|MaxAge)?|SetEnv|SetEnvIf|SetEnvIfExpr|SetEnvIfNoCase|SetHandler|SetInputFilter|SetOutputFilter|SSIEndTag|SSIErrorMsg|SSIETag|SSILastModified|SSILegacyExprParser|SSIStartTag|SSITimeFormat|SSIUndefinedEcho|SSL(?:CACertificateFile|CACertificatePath|CADNRequestFile|CADNRequestPath|CARevocationCheck|CARevocationFile|CARevocationPath|CertificateChainFile|CertificateFile|CertificateKeyFile|CipherSuite|Compression|CryptoDevice|Engine|FIPS|HonorCipherOrder|InsecureRenegotiation|OCSP(?:DefaultResponder|Enable|OverrideResponder|ResponderTimeout|ResponseMaxAge|ResponseTimeSkew|UseRequestNonce)|OpenSSLConfCmd|Options|PassPhraseDialog|Protocol|Proxy(?:CACertificateFile|CACertificatePath|CARevocation(?:Check|File|Path)|CheckPeer(?:CN|Expire|Name)|CipherSuite|Engine|MachineCertificate(?:ChainFile|File|Path)|Protocol|Verify|VerifyDepth)|RandomSeed|RenegBufferSize|Require|RequireSSL|Session(?:Cache|CacheTimeout|TicketKeyFile|Tickets)|SRPUnknownUserSeed|SRPVerifierFile|Stapling(?:Cache|ErrorCacheTimeout|FakeTryLater|ForceURL|ResponderTimeout|ResponseMaxAge|ResponseTimeSkew|ReturnResponderErrors|StandardCacheTimeout)|StrictSNIVHostCheck|UserName|UseStapling|VerifyClient|VerifyDepth)|StartServers|StartThreads|Substitute|Suexec|SuexecUserGroup|ThreadLimit|ThreadsPerChild|ThreadStackSize|TimeOut|TraceEnable|TransferLog|TypesConfig|UnDefine|UndefMacro|UnsetEnv|Use|UseCanonicalName|UseCanonicalPhysicalPort|User|UserDir|VHostCGIMode|VHostCGIPrivs|VHostGroup|VHostPrivs|VHostSecure|VHostUser|Virtual(?:DocumentRoot|ScriptAlias)(?:IP)?|WatchdogInterval|XBitHack|xml2EncAlias|xml2EncDefault|xml2StartParse)\b/im,lookbehind:!0,alias:"property"},"directive-block":{pattern:/<\/?\b(?:Auth[nz]ProviderAlias|Directory|DirectoryMatch|Else|ElseIf|Files|FilesMatch|If|IfDefine|IfModule|IfVersion|Limit|LimitExcept|Location|LocationMatch|Macro|Proxy|Require(?:All|Any|None)|VirtualHost)\b.*>/i,inside:{"directive-block":{pattern:/^<\/?\w+/,inside:{punctuation:/^<\/?/},alias:"tag"},"directive-block-parameter":{pattern:/.*[^>]/,inside:{punctuation:/:/,string:{pattern:/("|').*\1/,inside:{variable:/[$%]\{?(?:\w\.?[-+:]?)+\}?/}}},alias:"attr-value"},punctuation:/>/},alias:"tag"},"directive-flags":{pattern:/\[(?:[\w=],?)+\]/,alias:"keyword"},string:{pattern:/("|').*\1/,inside:{variable:/[$%]\{?(?:\w\.?[-+:]?)+\}?/}},variable:/[$%]\{?(?:\w\.?[-+:]?)+\}?/,regex:/\^?.*\$|\^.*\$?/}}return apacheconf_1}var sql_1,hasRequiredSql;function requireSql(){if(hasRequiredSql)return sql_1;hasRequiredSql=1,sql_1=e,e.displayName="sql",e.aliases=[];function e(t){t.languages.sql={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:--|\/\/|#).*)/,lookbehind:!0},variable:[{pattern:/@(["'`])(?:\\[\s\S]|(?!\1)[^\\])+\1/,greedy:!0},/@[\w.$]+/],string:{pattern:/(^|[^@\\])("|')(?:\\[\s\S]|(?!\2)[^\\]|\2\2)*\2/,greedy:!0,lookbehind:!0},identifier:{pattern:/(^|[^@\\])`(?:\\[\s\S]|[^`\\]|``)*`/,greedy:!0,lookbehind:!0,inside:{punctuation:/^`|`$/}},function:/\b(?:AVG|COUNT|FIRST|FORMAT|LAST|LCASE|LEN|MAX|MID|MIN|MOD|NOW|ROUND|SUM|UCASE)(?=\s*\()/i,keyword:/\b(?:ACTION|ADD|AFTER|ALGORITHM|ALL|ALTER|ANALYZE|ANY|APPLY|AS|ASC|AUTHORIZATION|AUTO_INCREMENT|BACKUP|BDB|BEGIN|BERKELEYDB|BIGINT|BINARY|BIT|BLOB|BOOL|BOOLEAN|BREAK|BROWSE|BTREE|BULK|BY|CALL|CASCADED?|CASE|CHAIN|CHAR(?:ACTER|SET)?|CHECK(?:POINT)?|CLOSE|CLUSTERED|COALESCE|COLLATE|COLUMNS?|COMMENT|COMMIT(?:TED)?|COMPUTE|CONNECT|CONSISTENT|CONSTRAINT|CONTAINS(?:TABLE)?|CONTINUE|CONVERT|CREATE|CROSS|CURRENT(?:_DATE|_TIME|_TIMESTAMP|_USER)?|CURSOR|CYCLE|DATA(?:BASES?)?|DATE(?:TIME)?|DAY|DBCC|DEALLOCATE|DEC|DECIMAL|DECLARE|DEFAULT|DEFINER|DELAYED|DELETE|DELIMITERS?|DENY|DESC|DESCRIBE|DETERMINISTIC|DISABLE|DISCARD|DISK|DISTINCT|DISTINCTROW|DISTRIBUTED|DO|DOUBLE|DROP|DUMMY|DUMP(?:FILE)?|DUPLICATE|ELSE(?:IF)?|ENABLE|ENCLOSED|END|ENGINE|ENUM|ERRLVL|ERRORS|ESCAPED?|EXCEPT|EXEC(?:UTE)?|EXISTS|EXIT|EXPLAIN|EXTENDED|FETCH|FIELDS|FILE|FILLFACTOR|FIRST|FIXED|FLOAT|FOLLOWING|FOR(?: EACH ROW)?|FORCE|FOREIGN|FREETEXT(?:TABLE)?|FROM|FULL|FUNCTION|GEOMETRY(?:COLLECTION)?|GLOBAL|GOTO|GRANT|GROUP|HANDLER|HASH|HAVING|HOLDLOCK|HOUR|IDENTITY(?:COL|_INSERT)?|IF|IGNORE|IMPORT|INDEX|INFILE|INNER|INNODB|INOUT|INSERT|INT|INTEGER|INTERSECT|INTERVAL|INTO|INVOKER|ISOLATION|ITERATE|JOIN|KEYS?|KILL|LANGUAGE|LAST|LEAVE|LEFT|LEVEL|LIMIT|LINENO|LINES|LINESTRING|LOAD|LOCAL|LOCK|LONG(?:BLOB|TEXT)|LOOP|MATCH(?:ED)?|MEDIUM(?:BLOB|INT|TEXT)|MERGE|MIDDLEINT|MINUTE|MODE|MODIFIES|MODIFY|MONTH|MULTI(?:LINESTRING|POINT|POLYGON)|NATIONAL|NATURAL|NCHAR|NEXT|NO|NONCLUSTERED|NULLIF|NUMERIC|OFF?|OFFSETS?|ON|OPEN(?:DATASOURCE|QUERY|ROWSET)?|OPTIMIZE|OPTION(?:ALLY)?|ORDER|OUT(?:ER|FILE)?|OVER|PARTIAL|PARTITION|PERCENT|PIVOT|PLAN|POINT|POLYGON|PRECEDING|PRECISION|PREPARE|PREV|PRIMARY|PRINT|PRIVILEGES|PROC(?:EDURE)?|PUBLIC|PURGE|QUICK|RAISERROR|READS?|REAL|RECONFIGURE|REFERENCES|RELEASE|RENAME|REPEAT(?:ABLE)?|REPLACE|REPLICATION|REQUIRE|RESIGNAL|RESTORE|RESTRICT|RETURN(?:ING|S)?|REVOKE|RIGHT|ROLLBACK|ROUTINE|ROW(?:COUNT|GUIDCOL|S)?|RTREE|RULE|SAVE(?:POINT)?|SCHEMA|SECOND|SELECT|SERIAL(?:IZABLE)?|SESSION(?:_USER)?|SET(?:USER)?|SHARE|SHOW|SHUTDOWN|SIMPLE|SMALLINT|SNAPSHOT|SOME|SONAME|SQL|START(?:ING)?|STATISTICS|STATUS|STRIPED|SYSTEM_USER|TABLES?|TABLESPACE|TEMP(?:ORARY|TABLE)?|TERMINATED|TEXT(?:SIZE)?|THEN|TIME(?:STAMP)?|TINY(?:BLOB|INT|TEXT)|TOP?|TRAN(?:SACTIONS?)?|TRIGGER|TRUNCATE|TSEQUAL|TYPES?|UNBOUNDED|UNCOMMITTED|UNDEFINED|UNION|UNIQUE|UNLOCK|UNPIVOT|UNSIGNED|UPDATE(?:TEXT)?|USAGE|USE|USER|USING|VALUES?|VAR(?:BINARY|CHAR|CHARACTER|YING)|VIEW|WAITFOR|WARNINGS|WHEN|WHERE|WHILE|WITH(?: ROLLUP|IN)?|WORK|WRITE(?:TEXT)?|YEAR)\b/i,boolean:/\b(?:FALSE|NULL|TRUE)\b/i,number:/\b0x[\da-f]+\b|\b\d+(?:\.\d*)?|\B\.\d+\b/i,operator:/[-+*\/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?|\b(?:AND|BETWEEN|DIV|ILIKE|IN|IS|LIKE|NOT|OR|REGEXP|RLIKE|SOUNDS LIKE|XOR)\b/i,punctuation:/[;[\]()`,.]/}}return sql_1}var apex_1,hasRequiredApex;function requireApex(){if(hasRequiredApex)return apex_1;hasRequiredApex=1;var e=requireSql();apex_1=t,t.displayName="apex",t.aliases=[];function t(Ye){Ye.register(e),function(tt){var rt=/\b(?:(?:after|before)(?=\s+[a-z])|abstract|activate|and|any|array|as|asc|autonomous|begin|bigdecimal|blob|boolean|break|bulk|by|byte|case|cast|catch|char|class|collect|commit|const|continue|currency|date|datetime|decimal|default|delete|desc|do|double|else|end|enum|exception|exit|export|extends|final|finally|float|for|from|get(?=\s*[{};])|global|goto|group|having|hint|if|implements|import|in|inner|insert|instanceof|int|integer|interface|into|join|like|limit|list|long|loop|map|merge|new|not|null|nulls|number|object|of|on|or|outer|override|package|parallel|pragma|private|protected|public|retrieve|return|rollback|select|set|short|sObject|sort|static|string|super|switch|synchronized|system|testmethod|then|this|throw|time|transaction|transient|trigger|try|undelete|update|upsert|using|virtual|void|webservice|when|where|while|(?:inherited|with|without)\s+sharing)\b/i,nt=/\b(?:(?=[a-z_]\w*\s*[<\[])|(?!<keyword>))[A-Z_]\w*(?:\s*\.\s*[A-Z_]\w*)*\b(?:\s*(?:\[\s*\]|<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>))*/.source.replace(/<keyword>/g,function(){return rt.source});function at(ot){return RegExp(ot.replace(/<CLASS-NAME>/g,function(){return nt}),"i")}var it={keyword:rt,punctuation:/[()\[\]{};,:.<>]/};tt.languages.apex={comment:tt.languages.clike.comment,string:tt.languages.clike.string,sql:{pattern:/((?:[=,({:]|\breturn)\s*)\[[^\[\]]*\]/i,lookbehind:!0,greedy:!0,alias:"language-sql",inside:tt.languages.sql},annotation:{pattern:/@\w+\b/,alias:"punctuation"},"class-name":[{pattern:at(/(\b(?:class|enum|extends|implements|instanceof|interface|new|trigger\s+\w+\s+on)\s+)<CLASS-NAME>/.source),lookbehind:!0,inside:it},{pattern:at(/(\(\s*)<CLASS-NAME>(?=\s*\)\s*[\w(])/.source),lookbehind:!0,inside:it},{pattern:at(/<CLASS-NAME>(?=\s*\w+\s*[;=,(){:])/.source),inside:it}],trigger:{pattern:/(\btrigger\s+)\w+\b/i,lookbehind:!0,alias:"class-name"},keyword:rt,function:/\b[a-z_]\w*(?=\s*\()/i,boolean:/\b(?:false|true)\b/i,number:/(?:\B\.\d+|\b\d+(?:\.\d+|L)?)\b/i,operator:/[!=](?:==?)?|\?\.?|&&|\|\||--|\+\+|[-+*/^&|]=?|:|<<?=?|>{1,3}=?/,punctuation:/[()\[\]{};,.]/}}(Ye)}return apex_1}var apl_1,hasRequiredApl;function requireApl(){if(hasRequiredApl)return apl_1;hasRequiredApl=1,apl_1=e,e.displayName="apl",e.aliases=[];function e(t){t.languages.apl={comment:/(?:⍝|#[! ]).*$/m,string:{pattern:/'(?:[^'\r\n]|'')*'/,greedy:!0},number:/¯?(?:\d*\.?\b\d+(?:e[+¯]?\d+)?|¯|∞)(?:j¯?(?:(?:\d+(?:\.\d+)?|\.\d+)(?:e[+¯]?\d+)?|¯|∞))?/i,statement:/:[A-Z][a-z][A-Za-z]*\b/,"system-function":{pattern:/⎕[A-Z]+/i,alias:"function"},constant:/[⍬⌾#⎕⍞]/,function:/[-+×÷⌈⌊∣|⍳⍸?*⍟○!⌹<≤=>≥≠≡≢∊⍷∪∩~∨∧⍱⍲⍴,⍪⌽⊖⍉↑↓⊂⊃⊆⊇⌷⍋⍒⊤⊥⍕⍎⊣⊢⍁⍂≈⍯↗¤→]/,"monadic-operator":{pattern:/[\\\/⌿⍀¨⍨⌶&∥]/,alias:"operator"},"dyadic-operator":{pattern:/[.⍣⍠⍤∘⌸@⌺⍥]/,alias:"operator"},assignment:{pattern:/←/,alias:"keyword"},punctuation:/[\[;\]()◇⋄]/,dfn:{pattern:/[{}⍺⍵⍶⍹∇⍫:]/,alias:"builtin"}}}return apl_1}var applescript_1,hasRequiredApplescript;function requireApplescript(){if(hasRequiredApplescript)return applescript_1;hasRequiredApplescript=1,applescript_1=e,e.displayName="applescript",e.aliases=[];function e(t){t.languages.applescript={comment:[/\(\*(?:\(\*(?:[^*]|\*(?!\)))*\*\)|(?!\(\*)[\s\S])*?\*\)/,/--.+/,/#.+/],string:/"(?:\\.|[^"\\\r\n])*"/,number:/(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e-?\d+)?\b/i,operator:[/[&=≠≤≥*+\-\/÷^]|[<>]=?/,/\b(?:(?:begin|end|start)s? with|(?:contains?|(?:does not|doesn't) contain)|(?:is|isn't|is not) (?:contained by|in)|(?:(?:is|isn't|is not) )?(?:greater|less) than(?: or equal)?(?: to)?|(?:comes|(?:does not|doesn't) come) (?:after|before)|(?:is|isn't|is not) equal(?: to)?|(?:(?:does not|doesn't) equal|equal to|equals|is not|isn't)|(?:a )?(?:ref(?: to)?|reference to)|(?:and|as|div|mod|not|or))\b/],keyword:/\b(?:about|above|after|against|apart from|around|aside from|at|back|before|beginning|behind|below|beneath|beside|between|but|by|considering|continue|copy|does|eighth|else|end|equal|error|every|exit|false|fifth|first|for|fourth|from|front|get|given|global|if|ignoring|in|instead of|into|is|it|its|last|local|me|middle|my|ninth|of|on|onto|out of|over|prop|property|put|repeat|return|returning|second|set|seventh|since|sixth|some|tell|tenth|that|the|then|third|through|thru|timeout|times|to|transaction|true|try|until|where|while|whose|with|without)\b/,"class-name":/\b(?:POSIX file|RGB color|alias|application|boolean|centimeters|centimetres|class|constant|cubic centimeters|cubic centimetres|cubic feet|cubic inches|cubic meters|cubic metres|cubic yards|date|degrees Celsius|degrees Fahrenheit|degrees Kelvin|feet|file|gallons|grams|inches|integer|kilograms|kilometers|kilometres|list|liters|litres|meters|metres|miles|number|ounces|pounds|quarts|real|record|reference|script|square feet|square kilometers|square kilometres|square meters|square metres|square miles|square yards|text|yards)\b/,punctuation:/[{}():,¬«»《》]/}}return applescript_1}var aql_1,hasRequiredAql;function requireAql(){if(hasRequiredAql)return aql_1;hasRequiredAql=1,aql_1=e,e.displayName="aql",e.aliases=[];function e(t){t.languages.aql={comment:/\/\/.*|\/\*[\s\S]*?\*\//,property:{pattern:/([{,]\s*)(?:(?!\d)\w+|(["'´`])(?:(?!\2)[^\\\r\n]|\\.)*\2)(?=\s*:)/,lookbehind:!0,greedy:!0},string:{pattern:/(["'])(?:(?!\1)[^\\\r\n]|\\.)*\1/,greedy:!0},identifier:{pattern:/([´`])(?:(?!\1)[^\\\r\n]|\\.)*\1/,greedy:!0},variable:/@@?\w+/,keyword:[{pattern:/(\bWITH\s+)COUNT(?=\s+INTO\b)/i,lookbehind:!0},/\b(?:AGGREGATE|ALL|AND|ANY|ASC|COLLECT|DESC|DISTINCT|FILTER|FOR|GRAPH|IN|INBOUND|INSERT|INTO|K_PATHS|K_SHORTEST_PATHS|LET|LIKE|LIMIT|NONE|NOT|NULL|OR|OUTBOUND|REMOVE|REPLACE|RETURN|SHORTEST_PATH|SORT|UPDATE|UPSERT|WINDOW|WITH)\b/i,{pattern:/(^|[^\w.[])(?:KEEP|PRUNE|SEARCH|TO)\b/i,lookbehind:!0},{pattern:/(^|[^\w.[])(?:CURRENT|NEW|OLD)\b/,lookbehind:!0},{pattern:/\bOPTIONS(?=\s*\{)/i}],function:/\b(?!\d)\w+(?=\s*\()/,boolean:/\b(?:false|true)\b/i,range:{pattern:/\.\./,alias:"operator"},number:[/\b0b[01]+/i,/\b0x[0-9a-f]+/i,/(?:\B\.\d+|\b(?:0|[1-9]\d*)(?:\.\d+)?)(?:e[+-]?\d+)?/i],operator:/\*{2,}|[=!]~|[!=<>]=?|&&|\|\||[-+*/%]/,punctuation:/::|[?.:,;()[\]{}]/}}return aql_1}var c_1,hasRequiredC;function requireC(){if(hasRequiredC)return c_1;hasRequiredC=1,c_1=e,e.displayName="c",e.aliases=[];function e(t){t.languages.c=t.languages.extend("clike",{comment:{pattern:/\/\/(?:[^\r\n\\]|\\(?:\r\n?|\n|(?![\r\n])))*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},"class-name":{pattern:/(\b(?:enum|struct)\s+(?:__attribute__\s*\(\([\s\S]*?\)\)\s*)?)\w+|\b[a-z]\w*_t\b/,lookbehind:!0},keyword:/\b(?:_Alignas|_Alignof|_Atomic|_Bool|_Complex|_Generic|_Imaginary|_Noreturn|_Static_assert|_Thread_local|__attribute__|asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|inline|int|long|register|return|short|signed|sizeof|static|struct|switch|typedef|typeof|union|unsigned|void|volatile|while)\b/,function:/\b[a-z_]\w*(?=\s*\()/i,number:/(?:\b0x(?:[\da-f]+(?:\.[\da-f]*)?|\.[\da-f]+)(?:p[+-]?\d+)?|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?)[ful]{0,4}/i,operator:/>>=?|<<=?|->|([-+&|:])\1|[?:~]|[-+*/%&|^!=<>]=?/}),t.languages.insertBefore("c","string",{char:{pattern:/'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n]){0,32}'/,greedy:!0}}),t.languages.insertBefore("c","string",{macro:{pattern:/(^[\t ]*)#\s*[a-z](?:[^\r\n\\/]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|\\(?:\r\n|[\s\S]))*/im,lookbehind:!0,greedy:!0,alias:"property",inside:{string:[{pattern:/^(#\s*include\s*)<[^>]+>/,lookbehind:!0},t.languages.c.string],char:t.languages.c.char,comment:t.languages.c.comment,"macro-name":[{pattern:/(^#\s*define\s+)\w+\b(?!\()/i,lookbehind:!0},{pattern:/(^#\s*define\s+)\w+\b(?=\()/i,lookbehind:!0,alias:"function"}],directive:{pattern:/^(#\s*)[a-z]+/,lookbehind:!0,alias:"keyword"},"directive-hash":/^#/,punctuation:/##|\\(?=[\r\n])/,expression:{pattern:/\S[\s\S]*/,inside:t.languages.c}}}}),t.languages.insertBefore("c","function",{constant:/\b(?:EOF|NULL|SEEK_CUR|SEEK_END|SEEK_SET|__DATE__|__FILE__|__LINE__|__TIMESTAMP__|__TIME__|__func__|stderr|stdin|stdout)\b/}),delete t.languages.c.boolean}return c_1}var cpp_1,hasRequiredCpp;function requireCpp(){if(hasRequiredCpp)return cpp_1;hasRequiredCpp=1;var e=requireC();cpp_1=t,t.displayName="cpp",t.aliases=[];function t(Ye){Ye.register(e),function(tt){var rt=/\b(?:alignas|alignof|asm|auto|bool|break|case|catch|char|char16_t|char32_t|char8_t|class|co_await|co_return|co_yield|compl|concept|const|const_cast|consteval|constexpr|constinit|continue|decltype|default|delete|do|double|dynamic_cast|else|enum|explicit|export|extern|final|float|for|friend|goto|if|import|inline|int|int16_t|int32_t|int64_t|int8_t|long|module|mutable|namespace|new|noexcept|nullptr|operator|override|private|protected|public|register|reinterpret_cast|requires|return|short|signed|sizeof|static|static_assert|static_cast|struct|switch|template|this|thread_local|throw|try|typedef|typeid|typename|uint16_t|uint32_t|uint64_t|uint8_t|union|unsigned|using|virtual|void|volatile|wchar_t|while)\b/,nt=/\b(?!<keyword>)\w+(?:\s*\.\s*\w+)*\b/.source.replace(/<keyword>/g,function(){return rt.source});tt.languages.cpp=tt.languages.extend("c",{"class-name":[{pattern:RegExp(/(\b(?:class|concept|enum|struct|typename)\s+)(?!<keyword>)\w+/.source.replace(/<keyword>/g,function(){return rt.source})),lookbehind:!0},/\b[A-Z]\w*(?=\s*::\s*\w+\s*\()/,/\b[A-Z_]\w*(?=\s*::\s*~\w+\s*\()/i,/\b\w+(?=\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>\s*::\s*\w+\s*\()/],keyword:rt,number:{pattern:/(?:\b0b[01']+|\b0x(?:[\da-f']+(?:\.[\da-f']*)?|\.[\da-f']+)(?:p[+-]?[\d']+)?|(?:\b[\d']+(?:\.[\d']*)?|\B\.[\d']+)(?:e[+-]?[\d']+)?)[ful]{0,4}/i,greedy:!0},operator:/>>=?|<<=?|->|--|\+\+|&&|\|\||[?:~]|<=>|[-+*/%&|^!=<>]=?|\b(?:and|and_eq|bitand|bitor|not|not_eq|or|or_eq|xor|xor_eq)\b/,boolean:/\b(?:false|true)\b/}),tt.languages.insertBefore("cpp","string",{module:{pattern:RegExp(/(\b(?:import|module)\s+)/.source+"(?:"+/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|<[^<>\r\n]*>/.source+"|"+/<mod-name>(?:\s*:\s*<mod-name>)?|:\s*<mod-name>/.source.replace(/<mod-name>/g,function(){return nt})+")"),lookbehind:!0,greedy:!0,inside:{string:/^[<"][\s\S]+/,operator:/:/,punctuation:/\./}},"raw-string":{pattern:/R"([^()\\ ]{0,16})\([\s\S]*?\)\1"/,alias:"string",greedy:!0}}),tt.languages.insertBefore("cpp","keyword",{"generic-function":{pattern:/\b(?!operator\b)[a-z_]\w*\s*<(?:[^<>]|<[^<>]*>)*>(?=\s*\()/i,inside:{function:/^\w+/,generic:{pattern:/<[\s\S]+/,alias:"class-name",inside:tt.languages.cpp}}}}),tt.languages.insertBefore("cpp","operator",{"double-colon":{pattern:/::/,alias:"punctuation"}}),tt.languages.insertBefore("cpp","class-name",{"base-clause":{pattern:/(\b(?:class|struct)\s+\w+\s*:\s*)[^;{}"'\s]+(?:\s+[^;{}"'\s]+)*(?=\s*[;{])/,lookbehind:!0,greedy:!0,inside:tt.languages.extend("cpp",{})}}),tt.languages.insertBefore("inside","double-colon",{"class-name":/\b[a-z_]\w*\b(?!\s*::)/i},tt.languages.cpp["base-clause"])}(Ye)}return cpp_1}var arduino_1,hasRequiredArduino;function requireArduino(){if(hasRequiredArduino)return arduino_1;hasRequiredArduino=1;var e=requireCpp();arduino_1=t,t.displayName="arduino",t.aliases=["ino"];function t(Ye){Ye.register(e),Ye.languages.arduino=Ye.languages.extend("cpp",{keyword:/\b(?:String|array|bool|boolean|break|byte|case|catch|continue|default|do|double|else|finally|for|function|goto|if|in|instanceof|int|integer|long|loop|new|null|return|setup|string|switch|throw|try|void|while|word)\b/,constant:/\b(?:ANALOG_MESSAGE|DEFAULT|DIGITAL_MESSAGE|EXTERNAL|FIRMATA_STRING|HIGH|INPUT|INPUT_PULLUP|INTERNAL|INTERNAL1V1|INTERNAL2V56|LED_BUILTIN|LOW|OUTPUT|REPORT_ANALOG|REPORT_DIGITAL|SET_PIN_MODE|SYSEX_START|SYSTEM_RESET)\b/,builtin:/\b(?:Audio|BSSID|Bridge|Client|Console|EEPROM|Esplora|EsploraTFT|Ethernet|EthernetClient|EthernetServer|EthernetUDP|File|FileIO|FileSystem|Firmata|GPRS|GSM|GSMBand|GSMClient|GSMModem|GSMPIN|GSMScanner|GSMServer|GSMVoiceCall|GSM_SMS|HttpClient|IPAddress|IRread|Keyboard|KeyboardController|LiquidCrystal|LiquidCrystal_I2C|Mailbox|Mouse|MouseController|PImage|Process|RSSI|RobotControl|RobotMotor|SD|SPI|SSID|Scheduler|Serial|Server|Servo|SoftwareSerial|Stepper|Stream|TFT|Task|USBHost|WiFi|WiFiClient|WiFiServer|WiFiUDP|Wire|YunClient|YunServer|abs|addParameter|analogRead|analogReadResolution|analogReference|analogWrite|analogWriteResolution|answerCall|attach|attachGPRS|attachInterrupt|attached|autoscroll|available|background|beep|begin|beginPacket|beginSD|beginSMS|beginSpeaker|beginTFT|beginTransmission|beginWrite|bit|bitClear|bitRead|bitSet|bitWrite|blink|blinkVersion|buffer|changePIN|checkPIN|checkPUK|checkReg|circle|cityNameRead|cityNameWrite|clear|clearScreen|click|close|compassRead|config|connect|connected|constrain|cos|countryNameRead|countryNameWrite|createChar|cursor|debugPrint|delay|delayMicroseconds|detach|detachInterrupt|digitalRead|digitalWrite|disconnect|display|displayLogos|drawBMP|drawCompass|encryptionType|end|endPacket|endSMS|endTransmission|endWrite|exists|exitValue|fill|find|findUntil|flush|gatewayIP|get|getAsynchronously|getBand|getButton|getCurrentCarrier|getIMEI|getKey|getModifiers|getOemKey|getPINUsed|getResult|getSignalStrength|getSocket|getVoiceCallStatus|getXChange|getYChange|hangCall|height|highByte|home|image|interrupts|isActionDone|isDirectory|isListening|isPIN|isPressed|isValid|keyPressed|keyReleased|keyboardRead|knobRead|leftToRight|line|lineFollowConfig|listen|listenOnLocalhost|loadImage|localIP|lowByte|macAddress|maintain|map|max|messageAvailable|micros|millis|min|mkdir|motorsStop|motorsWrite|mouseDragged|mouseMoved|mousePressed|mouseReleased|move|noAutoscroll|noBlink|noBuffer|noCursor|noDisplay|noFill|noInterrupts|noListenOnLocalhost|noStroke|noTone|onReceive|onRequest|open|openNextFile|overflow|parseCommand|parseFloat|parseInt|parsePacket|pauseMode|peek|pinMode|playFile|playMelody|point|pointTo|position|pow|prepare|press|print|printFirmwareVersion|printVersion|println|process|processInput|pulseIn|put|random|randomSeed|read|readAccelerometer|readBlue|readButton|readBytes|readBytesUntil|readGreen|readJoystickButton|readJoystickSwitch|readJoystickX|readJoystickY|readLightSensor|readMessage|readMicrophone|readNetworks|readRed|readSlider|readString|readStringUntil|readTemperature|ready|rect|release|releaseAll|remoteIP|remoteNumber|remotePort|remove|requestFrom|retrieveCallingNumber|rewindDirectory|rightToLeft|rmdir|robotNameRead|robotNameWrite|run|runAsynchronously|runShellCommand|runShellCommandAsynchronously|running|scanNetworks|scrollDisplayLeft|scrollDisplayRight|seek|sendAnalog|sendDigitalPortPair|sendDigitalPorts|sendString|sendSysex|serialEvent|setBand|setBitOrder|setClockDivider|setCursor|setDNS|setDataMode|setFirmwareVersion|setMode|setPINUsed|setSpeed|setTextSize|setTimeout|shiftIn|shiftOut|shutdown|sin|size|sqrt|startLoop|step|stop|stroke|subnetMask|switchPIN|tan|tempoWrite|text|tone|transfer|tuneWrite|turn|updateIR|userNameRead|userNameWrite|voiceCall|waitContinue|width|write|writeBlue|writeGreen|writeJSON|writeMessage|writeMicroseconds|writeRGB|writeRed|yield)\b/}),Ye.languages.ino=Ye.languages.arduino}return arduino_1}var arff_1,hasRequiredArff;function requireArff(){if(hasRequiredArff)return arff_1;hasRequiredArff=1,arff_1=e,e.displayName="arff",e.aliases=[];function e(t){t.languages.arff={comment:/%.*/,string:{pattern:/(["'])(?:\\.|(?!\1)[^\\\r\n])*\1/,greedy:!0},keyword:/@(?:attribute|data|end|relation)\b/i,number:/\b\d+(?:\.\d+)?\b/,punctuation:/[{},]/}}return arff_1}var asciidoc_1,hasRequiredAsciidoc;function requireAsciidoc(){if(hasRequiredAsciidoc)return asciidoc_1;hasRequiredAsciidoc=1,asciidoc_1=e,e.displayName="asciidoc",e.aliases=["adoc"];function e(t){(function(Ye){var tt={pattern:/(^[ \t]*)\[(?!\[)(?:(["'$`])(?:(?!\2)[^\\]|\\.)*\2|\[(?:[^\[\]\\]|\\.)*\]|[^\[\]\\"'$`]|\\.)*\]/m,lookbehind:!0,inside:{quoted:{pattern:/([$`])(?:(?!\1)[^\\]|\\.)*\1/,inside:{punctuation:/^[$`]|[$`]$/}},interpreted:{pattern:/'(?:[^'\\]|\\.)*'/,inside:{punctuation:/^'|'$/}},string:/"(?:[^"\\]|\\.)*"/,variable:/\w+(?==)/,punctuation:/^\[|\]$|,/,operator:/=/,"attr-value":/(?!^\s+$).+/}},rt=Ye.languages.asciidoc={"comment-block":{pattern:/^(\/{4,})(?:\r?\n|\r)(?:[\s\S]*(?:\r?\n|\r))??\1/m,alias:"comment"},table:{pattern:/^\|={3,}(?:(?:\r?\n|\r(?!\n)).*)*?(?:\r?\n|\r)\|={3,}$/m,inside:{specifiers:{pattern:/(?:(?:(?:\d+(?:\.\d+)?|\.\d+)[+*](?:[<^>](?:\.[<^>])?|\.[<^>])?|[<^>](?:\.[<^>])?|\.[<^>])[a-z]*|[a-z]+)(?=\|)/,alias:"attr-value"},punctuation:{pattern:/(^|[^\\])[|!]=*/,lookbehind:!0}}},"passthrough-block":{pattern:/^(\+{4,})(?:\r?\n|\r)(?:[\s\S]*(?:\r?\n|\r))??\1$/m,inside:{punctuation:/^\++|\++$/}},"literal-block":{pattern:/^(-{4,}|\.{4,})(?:\r?\n|\r)(?:[\s\S]*(?:\r?\n|\r))??\1$/m,inside:{punctuation:/^(?:-+|\.+)|(?:-+|\.+)$/}},"other-block":{pattern:/^(--|\*{4,}|_{4,}|={4,})(?:\r?\n|\r)(?:[\s\S]*(?:\r?\n|\r))??\1$/m,inside:{punctuation:/^(?:-+|\*+|_+|=+)|(?:-+|\*+|_+|=+)$/}},"list-punctuation":{pattern:/(^[ \t]*)(?:-|\*{1,5}|\.{1,5}|(?:[a-z]|\d+)\.|[xvi]+\))(?= )/im,lookbehind:!0,alias:"punctuation"},"list-label":{pattern:/(^[ \t]*)[a-z\d].+(?::{2,4}|;;)(?=\s)/im,lookbehind:!0,alias:"symbol"},"indented-block":{pattern:/((\r?\n|\r)\2)([ \t]+)\S.*(?:(?:\r?\n|\r)\3.+)*(?=\2{2}|$)/,lookbehind:!0},comment:/^\/\/.*/m,title:{pattern:/^.+(?:\r?\n|\r)(?:={3,}|-{3,}|~{3,}|\^{3,}|\+{3,})$|^={1,5} .+|^\.(?![\s.]).*/m,alias:"important",inside:{punctuation:/^(?:\.|=+)|(?:=+|-+|~+|\^+|\++)$/}},"attribute-entry":{pattern:/^:[^:\r\n]+:(?: .*?(?: \+(?:\r?\n|\r).*?)*)?$/m,alias:"tag"},attributes:tt,hr:{pattern:/^'{3,}$/m,alias:"punctuation"},"page-break":{pattern:/^<{3,}$/m,alias:"punctuation"},admonition:{pattern:/^(?:CAUTION|IMPORTANT|NOTE|TIP|WARNING):/m,alias:"keyword"},callout:[{pattern:/(^[ \t]*)<?\d*>/m,lookbehind:!0,alias:"symbol"},{pattern:/<\d+>/,alias:"symbol"}],macro:{pattern:/\b[a-z\d][a-z\d-]*::?(?:[^\s\[\]]*\[(?:[^\]\\"']|(["'])(?:(?!\1)[^\\]|\\.)*\1|\\.)*\])/,inside:{function:/^[a-z\d-]+(?=:)/,punctuation:/^::?/,attributes:{pattern:/(?:\[(?:[^\]\\"']|(["'])(?:(?!\1)[^\\]|\\.)*\1|\\.)*\])/,inside:tt.inside}}},inline:{pattern:/(^|[^\\])(?:(?:\B\[(?:[^\]\\"']|(["'])(?:(?!\2)[^\\]|\\.)*\2|\\.)*\])?(?:\b_(?!\s)(?: _|[^_\\\r\n]|\\.)+(?:(?:\r?\n|\r)(?: _|[^_\\\r\n]|\\.)+)*_\b|\B``(?!\s).+?(?:(?:\r?\n|\r).+?)*''\B|\B`(?!\s)(?:[^`'\s]|\s+\S)+['`]\B|\B(['*+#])(?!\s)(?: \3|(?!\3)[^\\\r\n]|\\.)+(?:(?:\r?\n|\r)(?: \3|(?!\3)[^\\\r\n]|\\.)+)*\3\B)|(?:\[(?:[^\]\\"']|(["'])(?:(?!\4)[^\\]|\\.)*\4|\\.)*\])?(?:(__|\*\*|\+\+\+?|##|\$\$|[~^]).+?(?:(?:\r?\n|\r).+?)*\5|\{[^}\r\n]+\}|\[\[\[?.+?(?:(?:\r?\n|\r).+?)*\]?\]\]|<<.+?(?:(?:\r?\n|\r).+?)*>>|\(\(\(?.+?(?:(?:\r?\n|\r).+?)*\)?\)\)))/m,lookbehind:!0,inside:{attributes:tt,url:{pattern:/^(?:\[\[\[?.+?\]?\]\]|<<.+?>>)$/,inside:{punctuation:/^(?:\[\[\[?|<<)|(?:\]\]\]?|>>)$/}},"attribute-ref":{pattern:/^\{.+\}$/,inside:{variable:{pattern:/(^\{)[a-z\d,+_-]+/,lookbehind:!0},operator:/^[=?!#%@$]|!(?=[:}])/,punctuation:/^\{|\}$|::?/}},italic:{pattern:/^(['_])[\s\S]+\1$/,inside:{punctuation:/^(?:''?|__?)|(?:''?|__?)$/}},bold:{pattern:/^\*[\s\S]+\*$/,inside:{punctuation:/^\*\*?|\*\*?$/}},punctuation:/^(?:``?|\+{1,3}|##?|\$\$|[~^]|\(\(\(?)|(?:''?|\+{1,3}|##?|\$\$|[~^`]|\)?\)\))$/}},replacement:{pattern:/\((?:C|R|TM)\)/,alias:"builtin"},entity:/&#?[\da-z]{1,8};/i,"line-continuation":{pattern:/(^| )\+$/m,lookbehind:!0,alias:"punctuation"}};function nt(at){at=at.split(" ");for(var it={},ot=0,ct=at.length;ot<ct;ot++)it[at[ot]]=rt[at[ot]];return it}tt.inside.interpreted.inside.rest=nt("macro inline replacement entity"),rt["passthrough-block"].inside.rest=nt("macro"),rt["literal-block"].inside.rest=nt("callout"),rt.table.inside.rest=nt("comment-block passthrough-block literal-block other-block list-punctuation indented-block comment title attribute-entry attributes hr page-break admonition list-label callout macro inline replacement entity line-continuation"),rt["other-block"].inside.rest=nt("table list-punctuation indented-block comment attribute-entry attributes hr page-break admonition list-label macro inline replacement entity line-continuation"),rt.title.inside.rest=nt("macro inline replacement entity"),Ye.hooks.add("wrap",function(at){at.type==="entity"&&(at.attributes.title=at.content.value.replace(/&amp;/,"&"))}),Ye.languages.adoc=Ye.languages.asciidoc})(t)}return asciidoc_1}var asm6502_1,hasRequiredAsm6502;function requireAsm6502(){if(hasRequiredAsm6502)return asm6502_1;hasRequiredAsm6502=1,asm6502_1=e,e.displayName="asm6502",e.aliases=[];function e(t){t.languages.asm6502={comment:/;.*/,directive:{pattern:/\.\w+(?= )/,alias:"property"},string:/(["'`])(?:\\.|(?!\1)[^\\\r\n])*\1/,"op-code":{pattern:/\b(?:ADC|AND|ASL|BCC|BCS|BEQ|BIT|BMI|BNE|BPL|BRK|BVC|BVS|CLC|CLD|CLI|CLV|CMP|CPX|CPY|DEC|DEX|DEY|EOR|INC|INX|INY|JMP|JSR|LDA|LDX|LDY|LSR|NOP|ORA|PHA|PHP|PLA|PLP|ROL|ROR|RTI|RTS|SBC|SEC|SED|SEI|STA|STX|STY|TAX|TAY|TSX|TXA|TXS|TYA|adc|and|asl|bcc|bcs|beq|bit|bmi|bne|bpl|brk|bvc|bvs|clc|cld|cli|clv|cmp|cpx|cpy|dec|dex|dey|eor|inc|inx|iny|jmp|jsr|lda|ldx|ldy|lsr|nop|ora|pha|php|pla|plp|rol|ror|rti|rts|sbc|sec|sed|sei|sta|stx|sty|tax|tay|tsx|txa|txs|tya)\b/,alias:"keyword"},"hex-number":{pattern:/#?\$[\da-f]{1,4}\b/i,alias:"number"},"binary-number":{pattern:/#?%[01]+\b/,alias:"number"},"decimal-number":{pattern:/#?\b\d+\b/,alias:"number"},register:{pattern:/\b[xya]\b/i,alias:"variable"},punctuation:/[(),:]/}}return asm6502_1}var asmatmel_1,hasRequiredAsmatmel;function requireAsmatmel(){if(hasRequiredAsmatmel)return asmatmel_1;hasRequiredAsmatmel=1,asmatmel_1=e,e.displayName="asmatmel",e.aliases=[];function e(t){t.languages.asmatmel={comment:{pattern:/;.*/,greedy:!0},string:{pattern:/(["'`])(?:\\.|(?!\1)[^\\\r\n])*\1/,greedy:!0},constant:/\b(?:PORT[A-Z]|DDR[A-Z]|(?:DD|P)[A-Z](?:\d|[0-2]\d|3[01]))\b/,directive:{pattern:/\.\w+(?= )/,alias:"property"},"r-register":{pattern:/\br(?:\d|[12]\d|3[01])\b/,alias:"variable"},"op-code":{pattern:/\b(?:ADC|ADD|ADIW|AND|ANDI|ASR|BCLR|BLD|BRBC|BRBS|BRCC|BRCS|BREAK|BREQ|BRGE|BRHC|BRHS|BRID|BRIE|BRLO|BRLT|BRMI|BRNE|BRPL|BRSH|BRTC|BRTS|BRVC|BRVS|BSET|BST|CALL|CBI|CBR|CLC|CLH|CLI|CLN|CLR|CLS|CLT|CLV|CLZ|COM|CP|CPC|CPI|CPSE|DEC|DES|EICALL|EIJMP|ELPM|EOR|FMUL|FMULS|FMULSU|ICALL|IJMP|IN|INC|JMP|LAC|LAS|LAT|LD|LD[A-Za-z0-9]|LPM|LSL|LSR|MOV|MOVW|MUL|MULS|MULSU|NEG|NOP|OR|ORI|OUT|POP|PUSH|RCALL|RET|RETI|RJMP|ROL|ROR|SBC|SBCI|SBI|SBIC|SBIS|SBIW|SBR|SBRC|SBRS|SEC|SEH|SEI|SEN|SER|SES|SET|SEV|SEZ|SLEEP|SPM|ST|ST[A-Z0-9]|SUB|SUBI|SWAP|TST|WDR|XCH|adc|add|adiw|and|andi|asr|bclr|bld|brbc|brbs|brcc|brcs|break|breq|brge|brhc|brhs|brid|brie|brlo|brlt|brmi|brne|brpl|brsh|brtc|brts|brvc|brvs|bset|bst|call|cbi|cbr|clc|clh|cli|cln|clr|cls|clt|clv|clz|com|cp|cpc|cpi|cpse|dec|des|eicall|eijmp|elpm|eor|fmul|fmuls|fmulsu|icall|ijmp|in|inc|jmp|lac|las|lat|ld|ld[a-z0-9]|lpm|lsl|lsr|mov|movw|mul|muls|mulsu|neg|nop|or|ori|out|pop|push|rcall|ret|reti|rjmp|rol|ror|sbc|sbci|sbi|sbic|sbis|sbiw|sbr|sbrc|sbrs|sec|seh|sei|sen|ser|ses|set|sev|sez|sleep|spm|st|st[a-zA-Z0-9]|sub|subi|swap|tst|wdr|xch)\b/,alias:"keyword"},"hex-number":{pattern:/#?\$[\da-f]{2,4}\b/i,alias:"number"},"binary-number":{pattern:/#?%[01]+\b/,alias:"number"},"decimal-number":{pattern:/#?\b\d+\b/,alias:"number"},register:{pattern:/\b[acznvshtixy]\b/i,alias:"variable"},operator:/>>=?|<<=?|&&?|\|\|?|[-+*/%&|^!=<>?]=?/,punctuation:/[(),:]/}}return asmatmel_1}var csharp_1,hasRequiredCsharp;function requireCsharp(){if(hasRequiredCsharp)return csharp_1;hasRequiredCsharp=1,csharp_1=e,e.displayName="csharp",e.aliases=["dotnet","cs"];function e(t){(function(Ye){function tt(cr,yr){return cr.replace(/<<(\d+)>>/g,function(ir,or){return"(?:"+yr[+or]+")"})}function rt(cr,yr,ir){return RegExp(tt(cr,yr),"")}function nt(cr,yr){for(var ir=0;ir<yr;ir++)cr=cr.replace(/<<self>>/g,function(){return"(?:"+cr+")"});return cr.replace(/<<self>>/g,"[^\\s\\S]")}var at={type:"bool byte char decimal double dynamic float int long object sbyte short string uint ulong ushort var void",typeDeclaration:"class enum interface record struct",contextual:"add alias and ascending async await by descending from(?=\\s*(?:\\w|$)) get global group into init(?=\\s*;) join let nameof not notnull on or orderby partial remove select set unmanaged value when where with(?=\\s*{)",other:"abstract as base break case catch checked const continue default delegate do else event explicit extern finally fixed for foreach goto if implicit in internal is lock namespace new null operator out override params private protected public readonly ref return sealed sizeof stackalloc static switch this throw try typeof unchecked unsafe using virtual volatile while yield"};function it(cr){return"\\b(?:"+cr.trim().replace(/ /g,"|")+")\\b"}var ot=it(at.typeDeclaration),ct=RegExp(it(at.type+" "+at.typeDeclaration+" "+at.contextual+" "+at.other)),At=it(at.typeDeclaration+" "+at.contextual+" "+at.other),Rt=it(at.type+" "+at.typeDeclaration+" "+at.other),qt=nt(/<(?:[^<>;=+\-*/%&|^]|<<self>>)*>/.source,2),Ft=nt(/\((?:[^()]|<<self>>)*\)/.source,2),Ut=/@?\b[A-Za-z_]\w*\b/.source,Ht=tt(/<<0>>(?:\s*<<1>>)?/.source,[Ut,qt]),zt=tt(/(?!<<0>>)<<1>>(?:\s*\.\s*<<1>>)*/.source,[At,Ht]),Yt=/\[\s*(?:,\s*)*\]/.source,Gt=tt(/<<0>>(?:\s*(?:\?\s*)?<<1>>)*(?:\s*\?)?/.source,[zt,Yt]),Vt=tt(/[^,()<>[\];=+\-*/%&|^]|<<0>>|<<1>>|<<2>>/.source,[qt,Ft,Yt]),Zt=tt(/\(<<0>>+(?:,<<0>>+)+\)/.source,[Vt]),Xt=tt(/(?:<<0>>|<<1>>)(?:\s*(?:\?\s*)?<<2>>)*(?:\s*\?)?/.source,[Zt,zt,Yt]),Qt={keyword:ct,punctuation:/[<>()?,.:[\]]/},er=/'(?:[^\r\n'\\]|\\.|\\[Uux][\da-fA-F]{1,8})'/.source,nr=/"(?:\\.|[^\\"\r\n])*"/.source,ar=/@"(?:""|\\[\s\S]|[^\\"])*"(?!")/.source;Ye.languages.csharp=Ye.languages.extend("clike",{string:[{pattern:rt(/(^|[^$\\])<<0>>/.source,[ar]),lookbehind:!0,greedy:!0},{pattern:rt(/(^|[^@$\\])<<0>>/.source,[nr]),lookbehind:!0,greedy:!0}],"class-name":[{pattern:rt(/(\busing\s+static\s+)<<0>>(?=\s*;)/.source,[zt]),lookbehind:!0,inside:Qt},{pattern:rt(/(\busing\s+<<0>>\s*=\s*)<<1>>(?=\s*;)/.source,[Ut,Xt]),lookbehind:!0,inside:Qt},{pattern:rt(/(\busing\s+)<<0>>(?=\s*=)/.source,[Ut]),lookbehind:!0},{pattern:rt(/(\b<<0>>\s+)<<1>>/.source,[ot,Ht]),lookbehind:!0,inside:Qt},{pattern:rt(/(\bcatch\s*\(\s*)<<0>>/.source,[zt]),lookbehind:!0,inside:Qt},{pattern:rt(/(\bwhere\s+)<<0>>/.source,[Ut]),lookbehind:!0},{pattern:rt(/(\b(?:is(?:\s+not)?|as)\s+)<<0>>/.source,[Gt]),lookbehind:!0,inside:Qt},{pattern:rt(/\b<<0>>(?=\s+(?!<<1>>|with\s*\{)<<2>>(?:\s*[=,;:{)\]]|\s+(?:in|when)\b))/.source,[Xt,Rt,Ut]),inside:Qt}],keyword:ct,number:/(?:\b0(?:x[\da-f_]*[\da-f]|b[01_]*[01])|(?:\B\.\d+(?:_+\d+)*|\b\d+(?:_+\d+)*(?:\.\d+(?:_+\d+)*)?)(?:e[-+]?\d+(?:_+\d+)*)?)(?:[dflmu]|lu|ul)?\b/i,operator:/>>=?|<<=?|[-=]>|([-+&|])\1|~|\?\?=?|[-+*/%&|^!=<>]=?/,punctuation:/\?\.?|::|[{}[\];(),.:]/}),Ye.languages.insertBefore("csharp","number",{range:{pattern:/\.\./,alias:"operator"}}),Ye.languages.insertBefore("csharp","punctuation",{"named-parameter":{pattern:rt(/([(,]\s*)<<0>>(?=\s*:)/.source,[Ut]),lookbehind:!0,alias:"punctuation"}}),Ye.languages.insertBefore("csharp","class-name",{namespace:{pattern:rt(/(\b(?:namespace|using)\s+)<<0>>(?:\s*\.\s*<<0>>)*(?=\s*[;{])/.source,[Ut]),lookbehind:!0,inside:{punctuation:/\./}},"type-expression":{pattern:rt(/(\b(?:default|sizeof|typeof)\s*\(\s*(?!\s))(?:[^()\s]|\s(?!\s)|<<0>>)*(?=\s*\))/.source,[Ft]),lookbehind:!0,alias:"class-name",inside:Qt},"return-type":{pattern:rt(/<<0>>(?=\s+(?:<<1>>\s*(?:=>|[({]|\.\s*this\s*\[)|this\s*\[))/.source,[Xt,zt]),inside:Qt,alias:"class-name"},"constructor-invocation":{pattern:rt(/(\bnew\s+)<<0>>(?=\s*[[({])/.source,[Xt]),lookbehind:!0,inside:Qt,alias:"class-name"},"generic-method":{pattern:rt(/<<0>>\s*<<1>>(?=\s*\()/.source,[Ut,qt]),inside:{function:rt(/^<<0>>/.source,[Ut]),generic:{pattern:RegExp(qt),alias:"class-name",inside:Qt}}},"type-list":{pattern:rt(/\b((?:<<0>>\s+<<1>>|record\s+<<1>>\s*<<5>>|where\s+<<2>>)\s*:\s*)(?:<<3>>|<<4>>|<<1>>\s*<<5>>|<<6>>)(?:\s*,\s*(?:<<3>>|<<4>>|<<6>>))*(?=\s*(?:where|[{;]|=>|$))/.source,[ot,Ht,Ut,Xt,ct.source,Ft,/\bnew\s*\(\s*\)/.source]),lookbehind:!0,inside:{"record-arguments":{pattern:rt(/(^(?!new\s*\()<<0>>\s*)<<1>>/.source,[Ht,Ft]),lookbehind:!0,greedy:!0,inside:Ye.languages.csharp},keyword:ct,"class-name":{pattern:RegExp(Xt),greedy:!0,inside:Qt},punctuation:/[,()]/}},preprocessor:{pattern:/(^[\t ]*)#.*/m,lookbehind:!0,alias:"property",inside:{directive:{pattern:/(#)\b(?:define|elif|else|endif|endregion|error|if|line|nullable|pragma|region|undef|warning)\b/,lookbehind:!0,alias:"keyword"}}}});var sr=nr+"|"+er,lr=tt(/\/(?![*/])|\/\/[^\r\n]*[\r\n]|\/\*(?:[^*]|\*(?!\/))*\*\/|<<0>>/.source,[sr]),fr=nt(tt(/[^"'/()]|<<0>>|\(<<self>>*\)/.source,[lr]),2),gr=/\b(?:assembly|event|field|method|module|param|property|return|type)\b/.source,dr=tt(/<<0>>(?:\s*\(<<1>>*\))?/.source,[zt,fr]);Ye.languages.insertBefore("csharp","class-name",{attribute:{pattern:rt(/((?:^|[^\s\w>)?])\s*\[\s*)(?:<<0>>\s*:\s*)?<<1>>(?:\s*,\s*<<1>>)*(?=\s*\])/.source,[gr,dr]),lookbehind:!0,greedy:!0,inside:{target:{pattern:rt(/^<<0>>(?=\s*:)/.source,[gr]),alias:"keyword"},"attribute-arguments":{pattern:rt(/\(<<0>>*\)/.source,[fr]),inside:Ye.languages.csharp},"class-name":{pattern:RegExp(zt),inside:{punctuation:/\./}},punctuation:/[:,]/}}});var vr=/:[^}\r\n]+/.source,mr=nt(tt(/[^"'/()]|<<0>>|\(<<self>>*\)/.source,[lr]),2),Er=tt(/\{(?!\{)(?:(?![}:])<<0>>)*<<1>>?\}/.source,[mr,vr]),_r=nt(tt(/[^"'/()]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|<<0>>|\(<<self>>*\)/.source,[sr]),2),Tr=tt(/\{(?!\{)(?:(?![}:])<<0>>)*<<1>>?\}/.source,[_r,vr]);function ur(cr,yr){return{interpolation:{pattern:rt(/((?:^|[^{])(?:\{\{)*)<<0>>/.source,[cr]),lookbehind:!0,inside:{"format-string":{pattern:rt(/(^\{(?:(?![}:])<<0>>)*)<<1>>(?=\}$)/.source,[yr,vr]),lookbehind:!0,inside:{punctuation:/^:/}},punctuation:/^\{|\}$/,expression:{pattern:/[\s\S]+/,alias:"language-csharp",inside:Ye.languages.csharp}}},string:/[\s\S]+/}}Ye.languages.insertBefore("csharp","string",{"interpolation-string":[{pattern:rt(/(^|[^\\])(?:\$@|@\$)"(?:""|\\[\s\S]|\{\{|<<0>>|[^\\{"])*"/.source,[Er]),lookbehind:!0,greedy:!0,inside:ur(Er,mr)},{pattern:rt(/(^|[^@\\])\$"(?:\\.|\{\{|<<0>>|[^\\"{])*"/.source,[Tr]),lookbehind:!0,greedy:!0,inside:ur(Tr,_r)}],char:{pattern:RegExp(er),greedy:!0}}),Ye.languages.dotnet=Ye.languages.cs=Ye.languages.csharp})(t)}return csharp_1}var aspnet_1,hasRequiredAspnet;function requireAspnet(){if(hasRequiredAspnet)return aspnet_1;hasRequiredAspnet=1;var e=requireCsharp();aspnet_1=t,t.displayName="aspnet",t.aliases=[];function t(Ye){Ye.register(e),Ye.languages.aspnet=Ye.languages.extend("markup",{"page-directive":{pattern:/<%\s*@.*%>/,alias:"tag",inside:{"page-directive":{pattern:/<%\s*@\s*(?:Assembly|Control|Implements|Import|Master(?:Type)?|OutputCache|Page|PreviousPageType|Reference|Register)?|%>/i,alias:"tag"},rest:Ye.languages.markup.tag.inside}},directive:{pattern:/<%.*%>/,alias:"tag",inside:{directive:{pattern:/<%\s*?[$=%#:]{0,2}|%>/,alias:"tag"},rest:Ye.languages.csharp}}}),Ye.languages.aspnet.tag.pattern=/<(?!%)\/?[^\s>\/]+(?:\s+[^\s>\/=]+(?:=(?:("|')(?:\\[\s\S]|(?!\1)[^\\])*\1|[^\s'">=]+))?)*\s*\/?>/,Ye.languages.insertBefore("inside","punctuation",{directive:Ye.languages.aspnet.directive},Ye.languages.aspnet.tag.inside["attr-value"]),Ye.languages.insertBefore("aspnet","comment",{"asp-comment":{pattern:/<%--[\s\S]*?--%>/,alias:["asp","comment"]}}),Ye.languages.insertBefore("aspnet",Ye.languages.javascript?"script":"tag",{"asp-script":{pattern:/(<script(?=.*runat=['"]?server\b)[^>]*>)[\s\S]*?(?=<\/script>)/i,lookbehind:!0,alias:["asp","script"],inside:Ye.languages.csharp||{}}})}return aspnet_1}var autohotkey_1,hasRequiredAutohotkey;function requireAutohotkey(){if(hasRequiredAutohotkey)return autohotkey_1;hasRequiredAutohotkey=1,autohotkey_1=e,e.displayName="autohotkey",e.aliases=[];function e(t){t.languages.autohotkey={comment:[{pattern:/(^|\s);.*/,lookbehind:!0},{pattern:/(^[\t ]*)\/\*(?:[\r\n](?![ \t]*\*\/)|[^\r\n])*(?:[\r\n][ \t]*\*\/)?/m,lookbehind:!0,greedy:!0}],tag:{pattern:/^([ \t]*)[^\s,`":]+(?=:[ \t]*$)/m,lookbehind:!0},string:/"(?:[^"\n\r]|"")*"/,variable:/%\w+%/,number:/\b0x[\dA-Fa-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[Ee]-?\d+)?/,operator:/\?|\/\/?=?|:=|\|[=|]?|&[=&]?|\+[=+]?|-[=-]?|\*[=*]?|<(?:<=?|>|=)?|>>?=?|[.^!=~]=?|\b(?:AND|NOT|OR)\b/,boolean:/\b(?:false|true)\b/,selector:/\b(?:AutoTrim|BlockInput|Break|Click|ClipWait|Continue|Control|ControlClick|ControlFocus|ControlGet|ControlGetFocus|ControlGetPos|ControlGetText|ControlMove|ControlSend|ControlSendRaw|ControlSetText|CoordMode|Critical|DetectHiddenText|DetectHiddenWindows|Drive|DriveGet|DriveSpaceFree|EnvAdd|EnvDiv|EnvGet|EnvMult|EnvSet|EnvSub|EnvUpdate|Exit|ExitApp|FileAppend|FileCopy|FileCopyDir|FileCreateDir|FileCreateShortcut|FileDelete|FileEncoding|FileGetAttrib|FileGetShortcut|FileGetSize|FileGetTime|FileGetVersion|FileInstall|FileMove|FileMoveDir|FileRead|FileReadLine|FileRecycle|FileRecycleEmpty|FileRemoveDir|FileSelectFile|FileSelectFolder|FileSetAttrib|FileSetTime|FormatTime|GetKeyState|Gosub|Goto|GroupActivate|GroupAdd|GroupClose|GroupDeactivate|Gui|GuiControl|GuiControlGet|Hotkey|ImageSearch|IniDelete|IniRead|IniWrite|Input|InputBox|KeyWait|ListHotkeys|ListLines|ListVars|Loop|Menu|MouseClick|MouseClickDrag|MouseGetPos|MouseMove|MsgBox|OnExit|OutputDebug|Pause|PixelGetColor|PixelSearch|PostMessage|Process|Progress|Random|RegDelete|RegRead|RegWrite|Reload|Repeat|Return|Run|RunAs|RunWait|Send|SendEvent|SendInput|SendMessage|SendMode|SendPlay|SendRaw|SetBatchLines|SetCapslockState|SetControlDelay|SetDefaultMouseSpeed|SetEnv|SetFormat|SetKeyDelay|SetMouseDelay|SetNumlockState|SetRegView|SetScrollLockState|SetStoreCapslockMode|SetTimer|SetTitleMatchMode|SetWinDelay|SetWorkingDir|Shutdown|Sleep|Sort|SoundBeep|SoundGet|SoundGetWaveVolume|SoundPlay|SoundSet|SoundSetWaveVolume|SplashImage|SplashTextOff|SplashTextOn|SplitPath|StatusBarGetText|StatusBarWait|StringCaseSense|StringGetPos|StringLeft|StringLen|StringLower|StringMid|StringReplace|StringRight|StringSplit|StringTrimLeft|StringTrimRight|StringUpper|Suspend|SysGet|Thread|ToolTip|Transform|TrayTip|URLDownloadToFile|WinActivate|WinActivateBottom|WinClose|WinGet|WinGetActiveStats|WinGetActiveTitle|WinGetClass|WinGetPos|WinGetText|WinGetTitle|WinHide|WinKill|WinMaximize|WinMenuSelectItem|WinMinimize|WinMinimizeAll|WinMinimizeAllUndo|WinMove|WinRestore|WinSet|WinSetTitle|WinShow|WinWait|WinWaitActive|WinWaitClose|WinWaitNotActive)\b/i,constant:/\b(?:a_ahkpath|a_ahkversion|a_appdata|a_appdatacommon|a_autotrim|a_batchlines|a_caretx|a_carety|a_computername|a_controldelay|a_cursor|a_dd|a_ddd|a_dddd|a_defaultmousespeed|a_desktop|a_desktopcommon|a_detecthiddentext|a_detecthiddenwindows|a_endchar|a_eventinfo|a_exitreason|a_fileencoding|a_formatfloat|a_formatinteger|a_gui|a_guicontrol|a_guicontrolevent|a_guievent|a_guiheight|a_guiwidth|a_guix|a_guiy|a_hour|a_iconfile|a_iconhidden|a_iconnumber|a_icontip|a_index|a_ipaddress1|a_ipaddress2|a_ipaddress3|a_ipaddress4|a_is64bitos|a_isadmin|a_iscompiled|a_iscritical|a_ispaused|a_issuspended|a_isunicode|a_keydelay|a_language|a_lasterror|a_linefile|a_linenumber|a_loopfield|a_loopfileattrib|a_loopfiledir|a_loopfileext|a_loopfilefullpath|a_loopfilelongpath|a_loopfilename|a_loopfileshortname|a_loopfileshortpath|a_loopfilesize|a_loopfilesizekb|a_loopfilesizemb|a_loopfiletimeaccessed|a_loopfiletimecreated|a_loopfiletimemodified|a_loopreadline|a_loopregkey|a_loopregname|a_loopregsubkey|a_loopregtimemodified|a_loopregtype|a_mday|a_min|a_mm|a_mmm|a_mmmm|a_mon|a_mousedelay|a_msec|a_mydocuments|a_now|a_nowutc|a_numbatchlines|a_ostype|a_osversion|a_priorhotkey|a_priorkey|a_programfiles|a_programs|a_programscommon|a_ptrsize|a_regview|a_screendpi|a_screenheight|a_screenwidth|a_scriptdir|a_scriptfullpath|a_scripthwnd|a_scriptname|a_sec|a_space|a_startmenu|a_startmenucommon|a_startup|a_startupcommon|a_stringcasesense|a_tab|a_temp|a_thisfunc|a_thishotkey|a_thislabel|a_thismenu|a_thismenuitem|a_thismenuitempos|a_tickcount|a_timeidle|a_timeidlephysical|a_timesincepriorhotkey|a_timesincethishotkey|a_titlematchmode|a_titlematchmodespeed|a_username|a_wday|a_windelay|a_windir|a_workingdir|a_yday|a_year|a_yweek|a_yyyy|clipboard|clipboardall|comspec|errorlevel|programfiles)\b/i,builtin:/\b(?:abs|acos|asc|asin|atan|ceil|chr|class|comobjactive|comobjarray|comobjconnect|comobjcreate|comobjerror|comobjflags|comobjget|comobjquery|comobjtype|comobjvalue|cos|dllcall|exp|fileexist|Fileopen|floor|format|il_add|il_create|il_destroy|instr|isfunc|islabel|IsObject|ln|log|ltrim|lv_add|lv_delete|lv_deletecol|lv_getcount|lv_getnext|lv_gettext|lv_insert|lv_insertcol|lv_modify|lv_modifycol|lv_setimagelist|mod|numget|numput|onmessage|regexmatch|regexreplace|registercallback|round|rtrim|sb_seticon|sb_setparts|sb_settext|sin|sqrt|strlen|strreplace|strsplit|substr|tan|tv_add|tv_delete|tv_get|tv_getchild|tv_getcount|tv_getnext|tv_getparent|tv_getprev|tv_getselection|tv_gettext|tv_modify|varsetcapacity|winactive|winexist|__Call|__Get|__New|__Set)\b/i,symbol:/\b(?:alt|altdown|altup|appskey|backspace|browser_back|browser_favorites|browser_forward|browser_home|browser_refresh|browser_search|browser_stop|bs|capslock|ctrl|ctrlbreak|ctrldown|ctrlup|del|delete|down|end|enter|esc|escape|f1|f10|f11|f12|f13|f14|f15|f16|f17|f18|f19|f2|f20|f21|f22|f23|f24|f3|f4|f5|f6|f7|f8|f9|home|ins|insert|joy1|joy10|joy11|joy12|joy13|joy14|joy15|joy16|joy17|joy18|joy19|joy2|joy20|joy21|joy22|joy23|joy24|joy25|joy26|joy27|joy28|joy29|joy3|joy30|joy31|joy32|joy4|joy5|joy6|joy7|joy8|joy9|joyaxes|joybuttons|joyinfo|joyname|joypov|joyr|joyu|joyv|joyx|joyy|joyz|lalt|launch_app1|launch_app2|launch_mail|launch_media|lbutton|lcontrol|lctrl|left|lshift|lwin|lwindown|lwinup|mbutton|media_next|media_play_pause|media_prev|media_stop|numlock|numpad0|numpad1|numpad2|numpad3|numpad4|numpad5|numpad6|numpad7|numpad8|numpad9|numpadadd|numpadclear|numpaddel|numpaddiv|numpaddot|numpaddown|numpadend|numpadenter|numpadhome|numpadins|numpadleft|numpadmult|numpadpgdn|numpadpgup|numpadright|numpadsub|numpadup|pgdn|pgup|printscreen|ralt|rbutton|rcontrol|rctrl|right|rshift|rwin|rwindown|rwinup|scrolllock|shift|shiftdown|shiftup|space|tab|up|volume_down|volume_mute|volume_up|wheeldown|wheelleft|wheelright|wheelup|xbutton1|xbutton2)\b/i,important:/#\b(?:AllowSameLineComments|ClipboardTimeout|CommentFlag|DerefChar|ErrorStdOut|EscapeChar|HotkeyInterval|HotkeyModifierTimeout|Hotstring|If|IfTimeout|IfWinActive|IfWinExist|IfWinNotActive|IfWinNotExist|Include|IncludeAgain|InputLevel|InstallKeybdHook|InstallMouseHook|KeyHistory|MaxHotkeysPerInterval|MaxMem|MaxThreads|MaxThreadsBuffer|MaxThreadsPerHotkey|MenuMaskKey|NoEnv|NoTrayIcon|Persistent|SingleInstance|UseHook|Warn|WinActivateForce)\b/i,keyword:/\b(?:Abort|AboveNormal|Add|ahk_class|ahk_exe|ahk_group|ahk_id|ahk_pid|All|Alnum|Alpha|AltSubmit|AltTab|AltTabAndMenu|AltTabMenu|AltTabMenuDismiss|AlwaysOnTop|AutoSize|Background|BackgroundTrans|BelowNormal|between|BitAnd|BitNot|BitOr|BitShiftLeft|BitShiftRight|BitXOr|Bold|Border|Button|ByRef|Catch|Checkbox|Checked|CheckedGray|Choose|ChooseString|Close|Color|ComboBox|Contains|ControlList|Count|Date|DateTime|Days|DDL|Default|DeleteAll|Delimiter|Deref|Destroy|Digit|Disable|Disabled|DropDownList|Edit|Eject|Else|Enable|Enabled|Error|Exist|Expand|ExStyle|FileSystem|Finally|First|Flash|Float|FloatFast|Focus|Font|for|global|Grid|Group|GroupBox|GuiClose|GuiContextMenu|GuiDropFiles|GuiEscape|GuiSize|Hdr|Hidden|Hide|High|HKCC|HKCR|HKCU|HKEY_CLASSES_ROOT|HKEY_CURRENT_CONFIG|HKEY_CURRENT_USER|HKEY_LOCAL_MACHINE|HKEY_USERS|HKLM|HKU|Hours|HScroll|Icon|IconSmall|ID|IDLast|If|IfEqual|IfExist|IfGreater|IfGreaterOrEqual|IfInString|IfLess|IfLessOrEqual|IfMsgBox|IfNotEqual|IfNotExist|IfNotInString|IfWinActive|IfWinExist|IfWinNotActive|IfWinNotExist|Ignore|ImageList|in|Integer|IntegerFast|Interrupt|is|italic|Join|Label|LastFound|LastFoundExist|Limit|Lines|List|ListBox|ListView|local|Lock|Logoff|Low|Lower|Lowercase|MainWindow|Margin|Maximize|MaximizeBox|MaxSize|Minimize|MinimizeBox|MinMax|MinSize|Minutes|MonthCal|Mouse|Move|Multi|NA|No|NoActivate|NoDefault|NoHide|NoIcon|NoMainWindow|norm|Normal|NoSort|NoSortHdr|NoStandard|Not|NoTab|NoTimers|Number|Off|Ok|On|OwnDialogs|Owner|Parse|Password|Picture|Pixel|Pos|Pow|Priority|ProcessName|Radio|Range|Read|ReadOnly|Realtime|Redraw|Region|REG_BINARY|REG_DWORD|REG_EXPAND_SZ|REG_MULTI_SZ|REG_SZ|Relative|Rename|Report|Resize|Restore|Retry|RGB|Screen|Seconds|Section|Serial|SetLabel|ShiftAltTab|Show|Single|Slider|SortDesc|Standard|static|Status|StatusBar|StatusCD|strike|Style|Submit|SysMenu|Tab2|TabStop|Text|Theme|Throw|Tile|ToggleCheck|ToggleEnable|ToolWindow|Top|Topmost|TransColor|Transparent|Tray|TreeView|Try|TryAgain|Type|UnCheck|underline|Unicode|Unlock|Until|UpDown|Upper|Uppercase|UseErrorLevel|Vis|VisFirst|Visible|VScroll|Wait|WaitClose|WantCtrlA|WantF2|WantReturn|While|Wrap|Xdigit|xm|xp|xs|Yes|ym|yp|ys)\b/i,function:/[^(); \t,\n+*\-=?>:\\\/<&%\[\]]+(?=\()/,punctuation:/[{}[\]():,]/}}return autohotkey_1}var autoit_1,hasRequiredAutoit;function requireAutoit(){if(hasRequiredAutoit)return autoit_1;hasRequiredAutoit=1,autoit_1=e,e.displayName="autoit",e.aliases=[];function e(t){t.languages.autoit={comment:[/;.*/,{pattern:/(^[\t ]*)#(?:comments-start|cs)[\s\S]*?^[ \t]*#(?:ce|comments-end)/m,lookbehind:!0}],url:{pattern:/(^[\t ]*#include\s+)(?:<[^\r\n>]+>|"[^\r\n"]+")/m,lookbehind:!0},string:{pattern:/(["'])(?:\1\1|(?!\1)[^\r\n])*\1/,greedy:!0,inside:{variable:/([%$@])\w+\1/}},directive:{pattern:/(^[\t ]*)#[\w-]+/m,lookbehind:!0,alias:"keyword"},function:/\b\w+(?=\()/,variable:/[$@]\w+/,keyword:/\b(?:Case|Const|Continue(?:Case|Loop)|Default|Dim|Do|Else(?:If)?|End(?:Func|If|Select|Switch|With)|Enum|Exit(?:Loop)?|For|Func|Global|If|In|Local|Next|Null|ReDim|Select|Static|Step|Switch|Then|To|Until|Volatile|WEnd|While|With)\b/i,number:/\b(?:0x[\da-f]+|\d+(?:\.\d+)?(?:e[+-]?\d+)?)\b/i,boolean:/\b(?:False|True)\b/i,operator:/<[=>]?|[-+*\/=&>]=?|[?^]|\b(?:And|Not|Or)\b/i,punctuation:/[\[\]().,:]/}}return autoit_1}var avisynth_1,hasRequiredAvisynth;function requireAvisynth(){if(hasRequiredAvisynth)return avisynth_1;hasRequiredAvisynth=1,avisynth_1=e,e.displayName="avisynth",e.aliases=["avs"];function e(t){(function(Ye){function tt(At,Rt){return At.replace(/<<(\d+)>>/g,function(qt,Ft){return Rt[+Ft]})}function rt(At,Rt,qt){return RegExp(tt(At,Rt),qt)}var nt=/bool|clip|float|int|string|val/.source,at=[/is(?:bool|clip|float|int|string)|defined|(?:(?:internal)?function|var)?exists?/.source,/apply|assert|default|eval|import|nop|select|undefined/.source,/opt_(?:allowfloataudio|avipadscanlines|dwchannelmask|enable_(?:b64a|planartopackedrgb|v210|y3_10_10|y3_10_16)|usewaveextensible|vdubplanarhack)|set(?:cachemode|maxcpu|memorymax|planarlegacyalignment|workingdir)/.source,/hex(?:value)?|value/.source,/abs|ceil|continued(?:denominator|numerator)?|exp|floor|fmod|frac|log(?:10)?|max|min|muldiv|pi|pow|rand|round|sign|spline|sqrt/.source,/a?sinh?|a?cosh?|a?tan[2h]?/.source,/(?:bit(?:and|not|x?or|[lr]?shift[aslu]?|sh[lr]|sa[lr]|[lr]rotatel?|ro[rl]|te?st|set(?:count)?|cl(?:ea)?r|ch(?:an)?ge?))/.source,/average(?:[bgr]|chroma[uv]|luma)|(?:[rgb]|chroma[uv]|luma|rgb|[yuv](?=difference(?:fromprevious|tonext)))difference(?:fromprevious|tonext)?|[yuvrgb]plane(?:median|min|max|minmaxdifference)/.source,/getprocessinfo|logmsg|script(?:dir(?:utf8)?|file(?:utf8)?|name(?:utf8)?)|setlogparams/.source,/chr|(?:fill|find|left|mid|replace|rev|right)str|format|[lu]case|ord|str(?:cmpi?|fromutf8|len|toutf8)|time|trim(?:all|left|right)/.source,/isversionorgreater|version(?:number|string)/.source,/buildpixeltype|colorspacenametopixeltype/.source,/addautoloaddir|on(?:cpu|cuda)|prefetch|setfiltermtmode/.source].join("|"),it=[/has(?:audio|video)/.source,/height|width/.source,/frame(?:count|rate)|framerate(?:denominator|numerator)/.source,/getparity|is(?:field|frame)based/.source,/bitspercomponent|componentsize|hasalpha|is(?:planar(?:rgba?)?|interleaved|rgb(?:24|32|48|64)?|y(?:8|u(?:va?|y2))?|yv(?:12|16|24|411)|420|422|444|packedrgb)|numcomponents|pixeltype/.source,/audio(?:bits|channels|duration|length(?:[fs]|hi|lo)?|rate)|isaudio(?:float|int)/.source].join("|"),ot=[/avi(?:file)?source|directshowsource|image(?:reader|source|sourceanim)|opendmlsource|segmented(?:avisource|directshowsource)|wavsource/.source,/coloryuv|convertbacktoyuy2|convertto(?:RGB(?:24|32|48|64)|(?:planar)?RGBA?|Y8?|YV(?:12|16|24|411)|YUVA?(?:411|420|422|444)|YUY2)|fixluminance|gr[ae]yscale|invert|levels|limiter|mergea?rgb|merge(?:chroma|luma)|rgbadjust|show(?:alpha|blue|green|red)|swapuv|tweak|[uv]toy8?|ytouv/.source,/(?:colorkey|reset)mask|layer|mask(?:hs)?|merge|overlay|subtract/.source,/addborders|(?:bicubic|bilinear|blackman|gauss|lanczos4|lanczos|point|sinc|spline(?:16|36|64))resize|crop(?:bottom)?|flip(?:horizontal|vertical)|(?:horizontal|vertical)?reduceby2|letterbox|skewrows|turn(?:180|left|right)/.source,/blur|fixbrokenchromaupsampling|generalconvolution|(?:spatial|temporal)soften|sharpen/.source,/trim|(?:un)?alignedsplice|(?:assume|assumescaled|change|convert)FPS|(?:delete|duplicate)frame|dissolve|fade(?:in|io|out)[02]?|freezeframe|interleave|loop|reverse|select(?:even|odd|(?:range)?every)/.source,/assume[bt]ff|assume(?:field|frame)based|bob|complementparity|doubleweave|peculiarblend|pulldown|separate(?:columns|fields|rows)|swapfields|weave(?:columns|rows)?/.source,/amplify(?:db)?|assumesamplerate|audiodub(?:ex)?|audiotrim|convertaudioto(?:(?:8|16|24|32)bit|float)|converttomono|delayaudio|ensurevbrmp3sync|get(?:left|right)?channel|kill(?:audio|video)|mergechannels|mixaudio|monotostereo|normalize|resampleaudio|ssrc|supereq|timestretch/.source,/animate|applyrange|conditional(?:filter|reader|select)|frameevaluate|scriptclip|tcp(?:server|source)|writefile(?:end|if|start)?/.source,/imagewriter/.source,/blackness|blankclip|colorbars(?:hd)?|compare|dumpfiltergraph|echo|histogram|info|messageclip|preroll|setgraphanalysis|show(?:framenumber|smpte|time)|showfiveversions|stack(?:horizontal|vertical)|subtitle|tone|version/.source].join("|"),ct=[at,it,ot].join("|");Ye.languages.avisynth={comment:[{pattern:/(^|[^\\])\[\*(?:[^\[*]|\[(?!\*)|\*(?!\])|\[\*(?:[^\[*]|\[(?!\*)|\*(?!\]))*\*\])*\*\]/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\$])#.*/,lookbehind:!0,greedy:!0}],argument:{pattern:rt(/\b(?:<<0>>)\s+("?)\w+\1/.source,[nt],"i"),inside:{keyword:/^\w+/}},"argument-label":{pattern:/([,(][\s\\]*)\w+\s*=(?!=)/,lookbehind:!0,inside:{"argument-name":{pattern:/^\w+/,alias:"punctuation"},punctuation:/=$/}},string:[{pattern:/"""[\s\S]*?"""/,greedy:!0},{pattern:/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0,inside:{constant:{pattern:/\b(?:DEFAULT_MT_MODE|(?:MAINSCRIPT|PROGRAM|SCRIPT)DIR|(?:MACHINE|USER)_(?:CLASSIC|PLUS)_PLUGINS)\b/}}}],variable:/\b(?:last)\b/i,boolean:/\b(?:false|no|true|yes)\b/i,keyword:/\b(?:catch|else|for|function|global|if|return|try|while|__END__)\b/i,constant:/\bMT_(?:MULTI_INSTANCE|NICE_FILTER|SERIALIZED|SPECIAL_MT)\b/,"builtin-function":{pattern:rt(/\b(?:<<0>>)\b/.source,[ct],"i"),alias:"function"},"type-cast":{pattern:rt(/\b(?:<<0>>)(?=\s*\()/.source,[nt],"i"),alias:"keyword"},function:{pattern:/\b[a-z_]\w*(?=\s*\()|(\.)[a-z_]\w*\b/i,lookbehind:!0},"line-continuation":{pattern:/(^[ \t]*)\\|\\(?=[ \t]*$)/m,lookbehind:!0,alias:"punctuation"},number:/\B\$(?:[\da-f]{6}|[\da-f]{8})\b|(?:(?:\b|\B-)\d+(?:\.\d*)?\b|\B\.\d+\b)/i,operator:/\+\+?|[!=<>]=?|&&|\|\||[?:*/%-]/,punctuation:/[{}\[\]();,.]/},Ye.languages.avs=Ye.languages.avisynth})(t)}return avisynth_1}var avroIdl_1,hasRequiredAvroIdl;function requireAvroIdl(){if(hasRequiredAvroIdl)return avroIdl_1;hasRequiredAvroIdl=1,avroIdl_1=e,e.displayName="avroIdl",e.aliases=[];function e(t){t.languages["avro-idl"]={comment:{pattern:/\/\/.*|\/\*[\s\S]*?\*\//,greedy:!0},string:{pattern:/(^|[^\\])"(?:[^\r\n"\\]|\\.)*"/,lookbehind:!0,greedy:!0},annotation:{pattern:/@(?:[$\w.-]|`[^\r\n`]+`)+/,greedy:!0,alias:"function"},"function-identifier":{pattern:/`[^\r\n`]+`(?=\s*\()/,greedy:!0,alias:"function"},identifier:{pattern:/`[^\r\n`]+`/,greedy:!0},"class-name":{pattern:/(\b(?:enum|error|protocol|record|throws)\b\s+)[$\w]+/,lookbehind:!0,greedy:!0},keyword:/\b(?:array|boolean|bytes|date|decimal|double|enum|error|false|fixed|float|idl|import|int|local_timestamp_ms|long|map|null|oneway|protocol|record|schema|string|throws|time_ms|timestamp_ms|true|union|uuid|void)\b/,function:/\b[a-z_]\w*(?=\s*\()/i,number:[{pattern:/(^|[^\w.])-?(?:(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?|0x(?:[a-f0-9]+(?:\.[a-f0-9]*)?|\.[a-f0-9]+)(?:p[+-]?\d+)?)[dfl]?(?![\w.])/i,lookbehind:!0},/-?\b(?:Infinity|NaN)\b/],operator:/=/,punctuation:/[()\[\]{}<>.:,;-]/},t.languages.avdl=t.languages["avro-idl"]}return avroIdl_1}var bash_1,hasRequiredBash;function requireBash(){if(hasRequiredBash)return bash_1;hasRequiredBash=1,bash_1=e,e.displayName="bash",e.aliases=["shell"];function e(t){(function(Ye){var tt="\\b(?:BASH|BASHOPTS|BASH_ALIASES|BASH_ARGC|BASH_ARGV|BASH_CMDS|BASH_COMPLETION_COMPAT_DIR|BASH_LINENO|BASH_REMATCH|BASH_SOURCE|BASH_VERSINFO|BASH_VERSION|COLORTERM|COLUMNS|COMP_WORDBREAKS|DBUS_SESSION_BUS_ADDRESS|DEFAULTS_PATH|DESKTOP_SESSION|DIRSTACK|DISPLAY|EUID|GDMSESSION|GDM_LANG|GNOME_KEYRING_CONTROL|GNOME_KEYRING_PID|GPG_AGENT_INFO|GROUPS|HISTCONTROL|HISTFILE|HISTFILESIZE|HISTSIZE|HOME|HOSTNAME|HOSTTYPE|IFS|INSTANCE|JOB|LANG|LANGUAGE|LC_ADDRESS|LC_ALL|LC_IDENTIFICATION|LC_MEASUREMENT|LC_MONETARY|LC_NAME|LC_NUMERIC|LC_PAPER|LC_TELEPHONE|LC_TIME|LESSCLOSE|LESSOPEN|LINES|LOGNAME|LS_COLORS|MACHTYPE|MAILCHECK|MANDATORY_PATH|NO_AT_BRIDGE|OLDPWD|OPTERR|OPTIND|ORBIT_SOCKETDIR|OSTYPE|PAPERSIZE|PATH|PIPESTATUS|PPID|PS1|PS2|PS3|PS4|PWD|RANDOM|REPLY|SECONDS|SELINUX_INIT|SESSION|SESSIONTYPE|SESSION_MANAGER|SHELL|SHELLOPTS|SHLVL|SSH_AUTH_SOCK|TERM|UID|UPSTART_EVENTS|UPSTART_INSTANCE|UPSTART_JOB|UPSTART_SESSION|USER|WINDOWID|XAUTHORITY|XDG_CONFIG_DIRS|XDG_CURRENT_DESKTOP|XDG_DATA_DIRS|XDG_GREETER_DATA_DIR|XDG_MENU_PREFIX|XDG_RUNTIME_DIR|XDG_SEAT|XDG_SEAT_PATH|XDG_SESSION_DESKTOP|XDG_SESSION_ID|XDG_SESSION_PATH|XDG_SESSION_TYPE|XDG_VTNR|XMODIFIERS)\\b",rt={pattern:/(^(["']?)\w+\2)[ \t]+\S.*/,lookbehind:!0,alias:"punctuation",inside:null},nt={bash:rt,environment:{pattern:RegExp("\\$"+tt),alias:"constant"},variable:[{pattern:/\$?\(\([\s\S]+?\)\)/,greedy:!0,inside:{variable:[{pattern:/(^\$\(\([\s\S]+)\)\)/,lookbehind:!0},/^\$\(\(/],number:/\b0x[\dA-Fa-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[Ee]-?\d+)?/,operator:/--|\+\+|\*\*=?|<<=?|>>=?|&&|\|\||[=!+\-*/%<>^&|]=?|[?~:]/,punctuation:/\(\(?|\)\)?|,|;/}},{pattern:/\$\((?:\([^)]+\)|[^()])+\)|`[^`]+`/,greedy:!0,inside:{variable:/^\$\(|^`|\)$|`$/}},{pattern:/\$\{[^}]+\}/,greedy:!0,inside:{operator:/:[-=?+]?|[!\/]|##?|%%?|\^\^?|,,?/,punctuation:/[\[\]]/,environment:{pattern:RegExp("(\\{)"+tt),lookbehind:!0,alias:"constant"}}},/\$(?:\w+|[#?*!@$])/],entity:/\\(?:[abceEfnrtv\\"]|O?[0-7]{1,3}|U[0-9a-fA-F]{8}|u[0-9a-fA-F]{4}|x[0-9a-fA-F]{1,2})/};Ye.languages.bash={shebang:{pattern:/^#!\s*\/.*/,alias:"important"},comment:{pattern:/(^|[^"{\\$])#.*/,lookbehind:!0},"function-name":[{pattern:/(\bfunction\s+)[\w-]+(?=(?:\s*\(?:\s*\))?\s*\{)/,lookbehind:!0,alias:"function"},{pattern:/\b[\w-]+(?=\s*\(\s*\)\s*\{)/,alias:"function"}],"for-or-select":{pattern:/(\b(?:for|select)\s+)\w+(?=\s+in\s)/,alias:"variable",lookbehind:!0},"assign-left":{pattern:/(^|[\s;|&]|[<>]\()\w+(?=\+?=)/,inside:{environment:{pattern:RegExp("(^|[\\s;|&]|[<>]\\()"+tt),lookbehind:!0,alias:"constant"}},alias:"variable",lookbehind:!0},string:[{pattern:/((?:^|[^<])<<-?\s*)(\w+)\s[\s\S]*?(?:\r?\n|\r)\2/,lookbehind:!0,greedy:!0,inside:nt},{pattern:/((?:^|[^<])<<-?\s*)(["'])(\w+)\2\s[\s\S]*?(?:\r?\n|\r)\3/,lookbehind:!0,greedy:!0,inside:{bash:rt}},{pattern:/(^|[^\\](?:\\\\)*)"(?:\\[\s\S]|\$\([^)]+\)|\$(?!\()|`[^`]+`|[^"\\`$])*"/,lookbehind:!0,greedy:!0,inside:nt},{pattern:/(^|[^$\\])'[^']*'/,lookbehind:!0,greedy:!0},{pattern:/\$'(?:[^'\\]|\\[\s\S])*'/,greedy:!0,inside:{entity:nt.entity}}],environment:{pattern:RegExp("\\$?"+tt),alias:"constant"},variable:nt.variable,function:{pattern:/(^|[\s;|&]|[<>]\()(?:add|apropos|apt|apt-cache|apt-get|aptitude|aspell|automysqlbackup|awk|basename|bash|bc|bconsole|bg|bzip2|cal|cat|cfdisk|chgrp|chkconfig|chmod|chown|chroot|cksum|clear|cmp|column|comm|composer|cp|cron|crontab|csplit|curl|cut|date|dc|dd|ddrescue|debootstrap|df|diff|diff3|dig|dir|dircolors|dirname|dirs|dmesg|docker|docker-compose|du|egrep|eject|env|ethtool|expand|expect|expr|fdformat|fdisk|fg|fgrep|file|find|fmt|fold|format|free|fsck|ftp|fuser|gawk|git|gparted|grep|groupadd|groupdel|groupmod|groups|grub-mkconfig|gzip|halt|head|hg|history|host|hostname|htop|iconv|id|ifconfig|ifdown|ifup|import|install|ip|jobs|join|kill|killall|less|link|ln|locate|logname|logrotate|look|lpc|lpr|lprint|lprintd|lprintq|lprm|ls|lsof|lynx|make|man|mc|mdadm|mkconfig|mkdir|mke2fs|mkfifo|mkfs|mkisofs|mknod|mkswap|mmv|more|most|mount|mtools|mtr|mutt|mv|nano|nc|netstat|nice|nl|node|nohup|notify-send|npm|nslookup|op|open|parted|passwd|paste|pathchk|ping|pkill|pnpm|podman|podman-compose|popd|pr|printcap|printenv|ps|pushd|pv|quota|quotacheck|quotactl|ram|rar|rcp|reboot|remsync|rename|renice|rev|rm|rmdir|rpm|rsync|scp|screen|sdiff|sed|sendmail|seq|service|sftp|sh|shellcheck|shuf|shutdown|sleep|slocate|sort|split|ssh|stat|strace|su|sudo|sum|suspend|swapon|sync|tac|tail|tar|tee|time|timeout|top|touch|tr|traceroute|tsort|tty|umount|uname|unexpand|uniq|units|unrar|unshar|unzip|update-grub|uptime|useradd|userdel|usermod|users|uudecode|uuencode|v|vcpkg|vdir|vi|vim|virsh|vmstat|wait|watch|wc|wget|whereis|which|who|whoami|write|xargs|xdg-open|yarn|yes|zenity|zip|zsh|zypper)(?=$|[)\s;|&])/,lookbehind:!0},keyword:{pattern:/(^|[\s;|&]|[<>]\()(?:case|do|done|elif|else|esac|fi|for|function|if|in|select|then|until|while)(?=$|[)\s;|&])/,lookbehind:!0},builtin:{pattern:/(^|[\s;|&]|[<>]\()(?:\.|:|alias|bind|break|builtin|caller|cd|command|continue|declare|echo|enable|eval|exec|exit|export|getopts|hash|help|let|local|logout|mapfile|printf|pwd|read|readarray|readonly|return|set|shift|shopt|source|test|times|trap|type|typeset|ulimit|umask|unalias|unset)(?=$|[)\s;|&])/,lookbehind:!0,alias:"class-name"},boolean:{pattern:/(^|[\s;|&]|[<>]\()(?:false|true)(?=$|[)\s;|&])/,lookbehind:!0},"file-descriptor":{pattern:/\B&\d\b/,alias:"important"},operator:{pattern:/\d?<>|>\||\+=|=[=~]?|!=?|<<[<-]?|[&\d]?>>|\d[<>]&?|[<>][&=]?|&[>&]?|\|[&|]?/,inside:{"file-descriptor":{pattern:/^\d/,alias:"important"}}},punctuation:/\$?\(\(?|\)\)?|\.\.|[{}[\];\\]/,number:{pattern:/(^|\s)(?:[1-9]\d*|0)(?:[.,]\d+)?\b/,lookbehind:!0}},rt.inside=Ye.languages.bash;for(var at=["comment","function-name","for-or-select","assign-left","string","environment","function","keyword","builtin","boolean","file-descriptor","operator","punctuation","number"],it=nt.variable[1].inside,ot=0;ot<at.length;ot++)it[at[ot]]=Ye.languages.bash[at[ot]];Ye.languages.shell=Ye.languages.bash})(t)}return bash_1}var basic_1,hasRequiredBasic;function requireBasic(){if(hasRequiredBasic)return basic_1;hasRequiredBasic=1,basic_1=e,e.displayName="basic",e.aliases=[];function e(t){t.languages.basic={comment:{pattern:/(?:!|REM\b).+/i,inside:{keyword:/^REM/i}},string:{pattern:/"(?:""|[!#$%&'()*,\/:;<=>?^\w +\-.])*"/,greedy:!0},number:/(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:E[+-]?\d+)?/i,keyword:/\b(?:AS|BEEP|BLOAD|BSAVE|CALL(?: ABSOLUTE)?|CASE|CHAIN|CHDIR|CLEAR|CLOSE|CLS|COM|COMMON|CONST|DATA|DECLARE|DEF(?: FN| SEG|DBL|INT|LNG|SNG|STR)|DIM|DO|DOUBLE|ELSE|ELSEIF|END|ENVIRON|ERASE|ERROR|EXIT|FIELD|FILES|FOR|FUNCTION|GET|GOSUB|GOTO|IF|INPUT|INTEGER|IOCTL|KEY|KILL|LINE INPUT|LOCATE|LOCK|LONG|LOOP|LSET|MKDIR|NAME|NEXT|OFF|ON(?: COM| ERROR| KEY| TIMER)?|OPEN|OPTION BASE|OUT|POKE|PUT|READ|REDIM|REM|RESTORE|RESUME|RETURN|RMDIR|RSET|RUN|SELECT CASE|SHARED|SHELL|SINGLE|SLEEP|STATIC|STEP|STOP|STRING|SUB|SWAP|SYSTEM|THEN|TIMER|TO|TROFF|TRON|TYPE|UNLOCK|UNTIL|USING|VIEW PRINT|WAIT|WEND|WHILE|WRITE)(?:\$|\b)/i,function:/\b(?:ABS|ACCESS|ACOS|ANGLE|AREA|ARITHMETIC|ARRAY|ASIN|ASK|AT|ATN|BASE|BEGIN|BREAK|CAUSE|CEIL|CHR|CLIP|COLLATE|COLOR|CON|COS|COSH|COT|CSC|DATE|DATUM|DEBUG|DECIMAL|DEF|DEG|DEGREES|DELETE|DET|DEVICE|DISPLAY|DOT|ELAPSED|EPS|ERASABLE|EXLINE|EXP|EXTERNAL|EXTYPE|FILETYPE|FIXED|FP|GO|GRAPH|HANDLER|IDN|IMAGE|IN|INT|INTERNAL|IP|IS|KEYED|LBOUND|LCASE|LEFT|LEN|LENGTH|LET|LINE|LINES|LOG|LOG10|LOG2|LTRIM|MARGIN|MAT|MAX|MAXNUM|MID|MIN|MISSING|MOD|NATIVE|NUL|NUMERIC|OF|OPTION|ORD|ORGANIZATION|OUTIN|OUTPUT|PI|POINT|POINTER|POINTS|POS|PRINT|PROGRAM|PROMPT|RAD|RADIANS|RANDOMIZE|RECORD|RECSIZE|RECTYPE|RELATIVE|REMAINDER|REPEAT|REST|RETRY|REWRITE|RIGHT|RND|ROUND|RTRIM|SAME|SEC|SELECT|SEQUENTIAL|SET|SETTER|SGN|SIN|SINH|SIZE|SKIP|SQR|STANDARD|STATUS|STR|STREAM|STYLE|TAB|TAN|TANH|TEMPLATE|TEXT|THERE|TIME|TIMEOUT|TRACE|TRANSFORM|TRUNCATE|UBOUND|UCASE|USE|VAL|VARIABLE|VIEWPORT|WHEN|WINDOW|WITH|ZER|ZONEWIDTH)(?:\$|\b)/i,operator:/<[=>]?|>=?|[+\-*\/^=&]|\b(?:AND|EQV|IMP|NOT|OR|XOR)\b/i,punctuation:/[,;:()]/}}return basic_1}var batch_1,hasRequiredBatch;function requireBatch(){if(hasRequiredBatch)return batch_1;hasRequiredBatch=1,batch_1=e,e.displayName="batch",e.aliases=[];function e(t){(function(Ye){var tt=/%%?[~:\w]+%?|!\S+!/,rt={pattern:/\/[a-z?]+(?=[ :]|$):?|-[a-z]\b|--[a-z-]+\b/im,alias:"attr-name",inside:{punctuation:/:/}},nt=/"(?:[\\"]"|[^"])*"(?!")/,at=/(?:\b|-)\d+\b/;Ye.languages.batch={comment:[/^::.*/m,{pattern:/((?:^|[&(])[ \t]*)rem\b(?:[^^&)\r\n]|\^(?:\r\n|[\s\S]))*/im,lookbehind:!0}],label:{pattern:/^:.*/m,alias:"property"},command:[{pattern:/((?:^|[&(])[ \t]*)for(?: \/[a-z?](?:[ :](?:"[^"]*"|[^\s"/]\S*))?)* \S+ in \([^)]+\) do/im,lookbehind:!0,inside:{keyword:/\b(?:do|in)\b|^for\b/i,string:nt,parameter:rt,variable:tt,number:at,punctuation:/[()',]/}},{pattern:/((?:^|[&(])[ \t]*)if(?: \/[a-z?](?:[ :](?:"[^"]*"|[^\s"/]\S*))?)* (?:not )?(?:cmdextversion \d+|defined \w+|errorlevel \d+|exist \S+|(?:"[^"]*"|(?!")(?:(?!==)\S)+)?(?:==| (?:equ|geq|gtr|leq|lss|neq) )(?:"[^"]*"|[^\s"]\S*))/im,lookbehind:!0,inside:{keyword:/\b(?:cmdextversion|defined|errorlevel|exist|not)\b|^if\b/i,string:nt,parameter:rt,variable:tt,number:at,operator:/\^|==|\b(?:equ|geq|gtr|leq|lss|neq)\b/i}},{pattern:/((?:^|[&()])[ \t]*)else\b/im,lookbehind:!0,inside:{keyword:/^else\b/i}},{pattern:/((?:^|[&(])[ \t]*)set(?: \/[a-z](?:[ :](?:"[^"]*"|[^\s"/]\S*))?)* (?:[^^&)\r\n]|\^(?:\r\n|[\s\S]))*/im,lookbehind:!0,inside:{keyword:/^set\b/i,string:nt,parameter:rt,variable:[tt,/\w+(?=(?:[*\/%+\-&^|]|<<|>>)?=)/],number:at,operator:/[*\/%+\-&^|]=?|<<=?|>>=?|[!~_=]/,punctuation:/[()',]/}},{pattern:/((?:^|[&(])[ \t]*@?)\w+\b(?:"(?:[\\"]"|[^"])*"(?!")|[^"^&)\r\n]|\^(?:\r\n|[\s\S]))*/m,lookbehind:!0,inside:{keyword:/^\w+\b/,string:nt,parameter:rt,label:{pattern:/(^\s*):\S+/m,lookbehind:!0,alias:"property"},variable:tt,number:at,operator:/\^/}}],operator:/[&@]/,punctuation:/[()']/}})(t)}return batch_1}var bbcode_1,hasRequiredBbcode;function requireBbcode(){if(hasRequiredBbcode)return bbcode_1;hasRequiredBbcode=1,bbcode_1=e,e.displayName="bbcode",e.aliases=["shortcode"];function e(t){t.languages.bbcode={tag:{pattern:/\[\/?[^\s=\]]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'"\]=]+))?(?:\s+[^\s=\]]+\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'"\]=]+))*\s*\]/,inside:{tag:{pattern:/^\[\/?[^\s=\]]+/,inside:{punctuation:/^\[\/?/}},"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'"\]=]+)/,inside:{punctuation:[/^=/,{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\]/,"attr-name":/[^\s=\]]+/}}},t.languages.shortcode=t.languages.bbcode}return bbcode_1}var bicep_1,hasRequiredBicep;function requireBicep(){if(hasRequiredBicep)return bicep_1;hasRequiredBicep=1,bicep_1=e,e.displayName="bicep",e.aliases=[];function e(t){t.languages.bicep={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],property:[{pattern:/([\r\n][ \t]*)[a-z_]\w*(?=[ \t]*:)/i,lookbehind:!0},{pattern:/([\r\n][ \t]*)'(?:\\.|\$(?!\{)|[^'\\\r\n$])*'(?=[ \t]*:)/,lookbehind:!0,greedy:!0}],string:[{pattern:/'''[^'][\s\S]*?'''/,greedy:!0},{pattern:/(^|[^\\'])'(?:\\.|\$(?!\{)|[^'\\\r\n$])*'/,lookbehind:!0,greedy:!0}],"interpolated-string":{pattern:/(^|[^\\'])'(?:\\.|\$(?:(?!\{)|\{[^{}\r\n]*\})|[^'\\\r\n$])*'/,lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/\$\{[^{}\r\n]*\}/,inside:{expression:{pattern:/(^\$\{)[\s\S]+(?=\}$)/,lookbehind:!0},punctuation:/^\$\{|\}$/}},string:/[\s\S]+/}},datatype:{pattern:/(\b(?:output|param)\b[ \t]+\w+[ \t]+)\w+\b/,lookbehind:!0,alias:"class-name"},boolean:/\b(?:false|true)\b/,keyword:/\b(?:existing|for|if|in|module|null|output|param|resource|targetScope|var)\b/,decorator:/@\w+\b/,function:/\b[a-z_]\w*(?=[ \t]*\()/i,number:/(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:E[+-]?\d+)?/i,operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/,punctuation:/[{}[\];(),.:]/},t.languages.bicep["interpolated-string"].inside.interpolation.inside.expression.inside=t.languages.bicep}return bicep_1}var birb_1,hasRequiredBirb;function requireBirb(){if(hasRequiredBirb)return birb_1;hasRequiredBirb=1,birb_1=e,e.displayName="birb",e.aliases=[];function e(t){t.languages.birb=t.languages.extend("clike",{string:{pattern:/r?("|')(?:\\.|(?!\1)[^\\])*\1/,greedy:!0},"class-name":[/\b[A-Z](?:[\d_]*[a-zA-Z]\w*)?\b/,/\b(?:[A-Z]\w*|(?!(?:var|void)\b)[a-z]\w*)(?=\s+\w+\s*[;,=()])/],keyword:/\b(?:assert|break|case|class|const|default|else|enum|final|follows|for|grab|if|nest|new|next|noSeeb|return|static|switch|throw|var|void|while)\b/,operator:/\+\+|--|&&|\|\||<<=?|>>=?|~(?:\/=?)?|[+\-*\/%&^|=!<>]=?|\?|:/,variable:/\b[a-z_]\w*\b/}),t.languages.insertBefore("birb","function",{metadata:{pattern:/<\w+>/,greedy:!0,alias:"symbol"}})}return birb_1}var bison_1,hasRequiredBison;function requireBison(){if(hasRequiredBison)return bison_1;hasRequiredBison=1;var e=requireC();bison_1=t,t.displayName="bison",t.aliases=[];function t(Ye){Ye.register(e),Ye.languages.bison=Ye.languages.extend("c",{}),Ye.languages.insertBefore("bison","comment",{bison:{pattern:/^(?:[^%]|%(?!%))*%%[\s\S]*?%%/,inside:{c:{pattern:/%\{[\s\S]*?%\}|\{(?:\{[^}]*\}|[^{}])*\}/,inside:{delimiter:{pattern:/^%?\{|%?\}$/,alias:"punctuation"},"bison-variable":{pattern:/[$@](?:<[^\s>]+>)?[\w$]+/,alias:"variable",inside:{punctuation:/<|>/}},rest:Ye.languages.c}},comment:Ye.languages.c.comment,string:Ye.languages.c.string,property:/\S+(?=:)/,keyword:/%\w+/,number:{pattern:/(^|[^@])\b(?:0x[\da-f]+|\d+)/i,lookbehind:!0},punctuation:/%[%?]|[|:;\[\]<>]/}}})}return bison_1}var bnf_1,hasRequiredBnf;function requireBnf(){if(hasRequiredBnf)return bnf_1;hasRequiredBnf=1,bnf_1=e,e.displayName="bnf",e.aliases=["rbnf"];function e(t){t.languages.bnf={string:{pattern:/"[^\r\n"]*"|'[^\r\n']*'/},definition:{pattern:/<[^<>\r\n\t]+>(?=\s*::=)/,alias:["rule","keyword"],inside:{punctuation:/^<|>$/}},rule:{pattern:/<[^<>\r\n\t]+>/,inside:{punctuation:/^<|>$/}},operator:/::=|[|()[\]{}*+?]|\.{3}/},t.languages.rbnf=t.languages.bnf}return bnf_1}var brainfuck_1,hasRequiredBrainfuck;function requireBrainfuck(){if(hasRequiredBrainfuck)return brainfuck_1;hasRequiredBrainfuck=1,brainfuck_1=e,e.displayName="brainfuck",e.aliases=[];function e(t){t.languages.brainfuck={pointer:{pattern:/<|>/,alias:"keyword"},increment:{pattern:/\+/,alias:"inserted"},decrement:{pattern:/-/,alias:"deleted"},branching:{pattern:/\[|\]/,alias:"important"},operator:/[.,]/,comment:/\S+/}}return brainfuck_1}var brightscript_1,hasRequiredBrightscript;function requireBrightscript(){if(hasRequiredBrightscript)return brightscript_1;hasRequiredBrightscript=1,brightscript_1=e,e.displayName="brightscript",e.aliases=[];function e(t){t.languages.brightscript={comment:/(?:\brem|').*/i,"directive-statement":{pattern:/(^[\t ]*)#(?:const|else(?:[\t ]+if)?|end[\t ]+if|error|if).*/im,lookbehind:!0,alias:"property",inside:{"error-message":{pattern:/(^#error).+/,lookbehind:!0},directive:{pattern:/^#(?:const|else(?:[\t ]+if)?|end[\t ]+if|error|if)/,alias:"keyword"},expression:{pattern:/[\s\S]+/,inside:null}}},property:{pattern:/([\r\n{,][\t ]*)(?:(?!\d)\w+|"(?:[^"\r\n]|"")*"(?!"))(?=[ \t]*:)/,lookbehind:!0,greedy:!0},string:{pattern:/"(?:[^"\r\n]|"")*"(?!")/,greedy:!0},"class-name":{pattern:/(\bAs[\t ]+)\w+/i,lookbehind:!0},keyword:/\b(?:As|Dim|Each|Else|Elseif|End|Exit|For|Function|Goto|If|In|Print|Return|Step|Stop|Sub|Then|To|While)\b/i,boolean:/\b(?:false|true)\b/i,function:/\b(?!\d)\w+(?=[\t ]*\()/,number:/(?:\b\d+(?:\.\d+)?(?:[ed][+-]\d+)?|&h[a-f\d]+)\b[%&!#]?/i,operator:/--|\+\+|>>=?|<<=?|<>|[-+*/\\<>]=?|[:^=?]|\b(?:and|mod|not|or)\b/i,punctuation:/[.,;()[\]{}]/,constant:/\b(?:LINE_NUM)\b/i},t.languages.brightscript["directive-statement"].inside.expression.inside=t.languages.brightscript}return brightscript_1}var bro_1,hasRequiredBro;function requireBro(){if(hasRequiredBro)return bro_1;hasRequiredBro=1,bro_1=e,e.displayName="bro",e.aliases=[];function e(t){t.languages.bro={comment:{pattern:/(^|[^\\$])#.*/,lookbehind:!0,inside:{italic:/\b(?:FIXME|TODO|XXX)\b/}},string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},boolean:/\b[TF]\b/,function:{pattern:/(\b(?:event|function|hook)[ \t]+)\w+(?:::\w+)?/,lookbehind:!0},builtin:/(?:@(?:load(?:-(?:plugin|sigs))?|unload|prefixes|ifn?def|else|(?:end)?if|DIR|FILENAME))|(?:&?(?:add_func|create_expire|default|delete_func|encrypt|error_handler|expire_func|group|log|mergeable|optional|persistent|priority|raw_output|read_expire|redef|rotate_interval|rotate_size|synchronized|type_column|write_expire))/,constant:{pattern:/(\bconst[ \t]+)\w+/i,lookbehind:!0},keyword:/\b(?:add|addr|alarm|any|bool|break|const|continue|count|delete|double|else|enum|event|export|file|for|function|global|hook|if|in|int|interval|local|module|next|of|opaque|pattern|port|print|record|return|schedule|set|string|subnet|table|time|timeout|using|vector|when)\b/,operator:/--?|\+\+?|!=?=?|<=?|>=?|==?=?|&&|\|\|?|\?|\*|\/|~|\^|%/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,punctuation:/[{}[\];(),.:]/}}return bro_1}var bsl_1,hasRequiredBsl;function requireBsl(){if(hasRequiredBsl)return bsl_1;hasRequiredBsl=1,bsl_1=e,e.displayName="bsl",e.aliases=[];function e(t){t.languages.bsl={comment:/\/\/.*/,string:[{pattern:/"(?:[^"]|"")*"(?!")/,greedy:!0},{pattern:/'(?:[^'\r\n\\]|\\.)*'/}],keyword:[{pattern:/(^|[^\w\u0400-\u0484\u0487-\u052f\u1d2b\u1d78\u2de0-\u2dff\ua640-\ua69f\ufe2e\ufe2f])(?:пока|для|новый|прервать|попытка|исключение|вызватьисключение|иначе|конецпопытки|неопределено|функция|перем|возврат|конецфункции|если|иначеесли|процедура|конецпроцедуры|тогда|знач|экспорт|конецесли|из|каждого|истина|ложь|по|цикл|конеццикла|выполнить)(?![\w\u0400-\u0484\u0487-\u052f\u1d2b\u1d78\u2de0-\u2dff\ua640-\ua69f\ufe2e\ufe2f])/i,lookbehind:!0},{pattern:/\b(?:break|do|each|else|elseif|enddo|endfunction|endif|endprocedure|endtry|except|execute|export|false|for|function|if|in|new|null|procedure|raise|return|then|to|true|try|undefined|val|var|while)\b/i}],number:{pattern:/(^(?=\d)|[^\w\u0400-\u0484\u0487-\u052f\u1d2b\u1d78\u2de0-\u2dff\ua640-\ua69f\ufe2e\ufe2f])(?:\d+(?:\.\d*)?|\.\d+)(?:E[+-]?\d+)?/i,lookbehind:!0},operator:[/[<>+\-*/]=?|[%=]/,{pattern:/(^|[^\w\u0400-\u0484\u0487-\u052f\u1d2b\u1d78\u2de0-\u2dff\ua640-\ua69f\ufe2e\ufe2f])(?:и|или|не)(?![\w\u0400-\u0484\u0487-\u052f\u1d2b\u1d78\u2de0-\u2dff\ua640-\ua69f\ufe2e\ufe2f])/i,lookbehind:!0},{pattern:/\b(?:and|not|or)\b/i}],punctuation:/\(\.|\.\)|[()\[\]:;,.]/,directive:[{pattern:/^([ \t]*)&.*/m,lookbehind:!0,greedy:!0,alias:"important"},{pattern:/^([ \t]*)#.*/gm,lookbehind:!0,greedy:!0,alias:"important"}]},t.languages.oscript=t.languages.bsl}return bsl_1}var cfscript_1,hasRequiredCfscript;function requireCfscript(){if(hasRequiredCfscript)return cfscript_1;hasRequiredCfscript=1,cfscript_1=e,e.displayName="cfscript",e.aliases=[];function e(t){t.languages.cfscript=t.languages.extend("clike",{comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,inside:{annotation:{pattern:/(?:^|[^.])@[\w\.]+/,alias:"punctuation"}}},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],keyword:/\b(?:abstract|break|catch|component|continue|default|do|else|extends|final|finally|for|function|if|in|include|package|private|property|public|remote|required|rethrow|return|static|switch|throw|try|var|while|xml)\b(?!\s*=)/,operator:[/\+\+|--|&&|\|\||::|=>|[!=]==|<=?|>=?|[-+*/%&|^!=<>]=?|\?(?:\.|:)?|[?:]/,/\b(?:and|contains|eq|equal|eqv|gt|gte|imp|is|lt|lte|mod|not|or|xor)\b/],scope:{pattern:/\b(?:application|arguments|cgi|client|cookie|local|session|super|this|variables)\b/,alias:"global"},type:{pattern:/\b(?:any|array|binary|boolean|date|guid|numeric|query|string|struct|uuid|void|xml)\b/,alias:"builtin"}}),t.languages.insertBefore("cfscript","keyword",{"function-variable":{pattern:/[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"}}),delete t.languages.cfscript["class-name"],t.languages.cfc=t.languages.cfscript}return cfscript_1}var chaiscript_1,hasRequiredChaiscript;function requireChaiscript(){if(hasRequiredChaiscript)return chaiscript_1;hasRequiredChaiscript=1;var e=requireCpp();chaiscript_1=t,t.displayName="chaiscript",t.aliases=[];function t(Ye){Ye.register(e),Ye.languages.chaiscript=Ye.languages.extend("clike",{string:{pattern:/(^|[^\\])'(?:[^'\\]|\\[\s\S])*'/,lookbehind:!0,greedy:!0},"class-name":[{pattern:/(\bclass\s+)\w+/,lookbehind:!0},{pattern:/(\b(?:attr|def)\s+)\w+(?=\s*::)/,lookbehind:!0}],keyword:/\b(?:attr|auto|break|case|catch|class|continue|def|default|else|finally|for|fun|global|if|return|switch|this|try|var|while)\b/,number:[Ye.languages.cpp.number,/\b(?:Infinity|NaN)\b/],operator:/>>=?|<<=?|\|\||&&|:[:=]?|--|\+\+|[=!<>+\-*/%|&^]=?|[?~]|`[^`\r\n]{1,4}`/}),Ye.languages.insertBefore("chaiscript","operator",{"parameter-type":{pattern:/([,(]\s*)\w+(?=\s+\w)/,lookbehind:!0,alias:"class-name"}}),Ye.languages.insertBefore("chaiscript","string",{"string-interpolation":{pattern:/(^|[^\\])"(?:[^"$\\]|\\[\s\S]|\$(?!\{)|\$\{(?:[^{}]|\{(?:[^{}]|\{[^{}]*\})*\})*\})*"/,lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^{}]*\})*\})*\}/,lookbehind:!0,inside:{"interpolation-expression":{pattern:/(^\$\{)[\s\S]+(?=\}$)/,lookbehind:!0,inside:Ye.languages.chaiscript},"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"}}},string:/[\s\S]+/}}})}return chaiscript_1}var cil_1,hasRequiredCil;function requireCil(){if(hasRequiredCil)return cil_1;hasRequiredCil=1,cil_1=e,e.displayName="cil",e.aliases=[];function e(t){t.languages.cil={comment:/\/\/.*/,string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},directive:{pattern:/(^|\W)\.[a-z]+(?=\s)/,lookbehind:!0,alias:"class-name"},variable:/\[[\w\.]+\]/,keyword:/\b(?:abstract|ansi|assembly|auto|autochar|beforefieldinit|bool|bstr|byvalstr|catch|char|cil|class|currency|date|decimal|default|enum|error|explicit|extends|extern|famandassem|family|famorassem|final(?:ly)?|float32|float64|hidebysig|u?int(?:8|16|32|64)?|iant|idispatch|implements|import|initonly|instance|interface|iunknown|literal|lpstr|lpstruct|lptstr|lpwstr|managed|method|native(?:Type)?|nested|newslot|object(?:ref)?|pinvokeimpl|private|privatescope|public|reqsecobj|rtspecialname|runtime|sealed|sequential|serializable|specialname|static|string|struct|syschar|tbstr|unicode|unmanagedexp|unsigned|value(?:type)?|variant|virtual|void)\b/,function:/\b(?:(?:constrained|no|readonly|tail|unaligned|volatile)\.)?(?:conv\.(?:[iu][1248]?|ovf\.[iu][1248]?(?:\.un)?|r\.un|r4|r8)|ldc\.(?:i4(?:\.\d+|\.[mM]1|\.s)?|i8|r4|r8)|ldelem(?:\.[iu][1248]?|\.r[48]|\.ref|a)?|ldind\.(?:[iu][1248]?|r[48]|ref)|stelem\.?(?:i[1248]?|r[48]|ref)?|stind\.(?:i[1248]?|r[48]|ref)?|end(?:fault|filter|finally)|ldarg(?:\.[0-3s]|a(?:\.s)?)?|ldloc(?:\.\d+|\.s)?|sub(?:\.ovf(?:\.un)?)?|mul(?:\.ovf(?:\.un)?)?|add(?:\.ovf(?:\.un)?)?|stloc(?:\.[0-3s])?|refany(?:type|val)|blt(?:\.un)?(?:\.s)?|ble(?:\.un)?(?:\.s)?|bgt(?:\.un)?(?:\.s)?|bge(?:\.un)?(?:\.s)?|unbox(?:\.any)?|init(?:blk|obj)|call(?:i|virt)?|brfalse(?:\.s)?|bne\.un(?:\.s)?|ldloca(?:\.s)?|brzero(?:\.s)?|brtrue(?:\.s)?|brnull(?:\.s)?|brinst(?:\.s)?|starg(?:\.s)?|leave(?:\.s)?|shr(?:\.un)?|rem(?:\.un)?|div(?:\.un)?|clt(?:\.un)?|alignment|castclass|ldvirtftn|beq(?:\.s)?|ckfinite|ldsflda|ldtoken|localloc|mkrefany|rethrow|cgt\.un|arglist|switch|stsfld|sizeof|newobj|newarr|ldsfld|ldnull|ldflda|isinst|throw|stobj|stfld|ldstr|ldobj|ldlen|ldftn|ldfld|cpobj|cpblk|break|br\.s|xor|shl|ret|pop|not|nop|neg|jmp|dup|cgt|ceq|box|and|or|br)\b/,boolean:/\b(?:false|true)\b/,number:/\b-?(?:0x[0-9a-f]+|\d+)(?:\.[0-9a-f]+)?\b/i,punctuation:/[{}[\];(),:=]|IL_[0-9A-Za-z]+/}}return cil_1}var clojure_1,hasRequiredClojure;function requireClojure(){if(hasRequiredClojure)return clojure_1;hasRequiredClojure=1,clojure_1=e,e.displayName="clojure",e.aliases=[];function e(t){t.languages.clojure={comment:{pattern:/;.*/,greedy:!0},string:{pattern:/"(?:[^"\\]|\\.)*"/,greedy:!0},char:/\\\w+/,symbol:{pattern:/(^|[\s()\[\]{},])::?[\w*+!?'<>=/.-]+/,lookbehind:!0},keyword:{pattern:/(\()(?:-|->|->>|\.|\.\.|\*|\/|\+|<|<=|=|==|>|>=|accessor|agent|agent-errors|aget|alength|all-ns|alter|and|append-child|apply|array-map|aset|aset-boolean|aset-byte|aset-char|aset-double|aset-float|aset-int|aset-long|aset-short|assert|assoc|await|await-for|bean|binding|bit-and|bit-not|bit-or|bit-shift-left|bit-shift-right|bit-xor|boolean|branch\?|butlast|byte|cast|char|children|class|clear-agent-errors|comment|commute|comp|comparator|complement|concat|cond|conj|cons|constantly|construct-proxy|contains\?|count|create-ns|create-struct|cycle|dec|declare|def|def-|definline|definterface|defmacro|defmethod|defmulti|defn|defn-|defonce|defproject|defprotocol|defrecord|defstruct|deftype|deref|difference|disj|dissoc|distinct|do|doall|doc|dorun|doseq|dosync|dotimes|doto|double|down|drop|drop-while|edit|end\?|ensure|eval|every\?|false\?|ffirst|file-seq|filter|find|find-doc|find-ns|find-var|first|float|flush|fn|fnseq|for|frest|gensym|get|get-proxy-class|hash-map|hash-set|identical\?|identity|if|if-let|if-not|import|in-ns|inc|index|insert-child|insert-left|insert-right|inspect-table|inspect-tree|instance\?|int|interleave|intersection|into|into-array|iterate|join|key|keys|keyword|keyword\?|last|lazy-cat|lazy-cons|left|lefts|let|line-seq|list|list\*|load|load-file|locking|long|loop|macroexpand|macroexpand-1|make-array|make-node|map|map-invert|map\?|mapcat|max|max-key|memfn|merge|merge-with|meta|min|min-key|monitor-enter|name|namespace|neg\?|new|newline|next|nil\?|node|not|not-any\?|not-every\?|not=|ns|ns-imports|ns-interns|ns-map|ns-name|ns-publics|ns-refers|ns-resolve|ns-unmap|nth|nthrest|or|parse|partial|path|peek|pop|pos\?|pr|pr-str|print|print-str|println|println-str|prn|prn-str|project|proxy|proxy-mappings|quot|quote|rand|rand-int|range|re-find|re-groups|re-matcher|re-matches|re-pattern|re-seq|read|read-line|recur|reduce|ref|ref-set|refer|rem|remove|remove-method|remove-ns|rename|rename-keys|repeat|replace|replicate|resolve|rest|resultset-seq|reverse|rfirst|right|rights|root|rrest|rseq|second|select|select-keys|send|send-off|seq|seq-zip|seq\?|set|set!|short|slurp|some|sort|sort-by|sorted-map|sorted-map-by|sorted-set|special-symbol\?|split-at|split-with|str|string\?|struct|struct-map|subs|subvec|symbol|symbol\?|sync|take|take-nth|take-while|test|throw|time|to-array|to-array-2d|tree-seq|true\?|try|union|up|update-proxy|val|vals|var|var-get|var-set|var\?|vector|vector-zip|vector\?|when|when-first|when-let|when-not|with-local-vars|with-meta|with-open|with-out-str|xml-seq|xml-zip|zero\?|zipmap|zipper)(?=[\s)]|$)/,lookbehind:!0},boolean:/\b(?:false|nil|true)\b/,number:{pattern:/(^|[^\w$@])(?:\d+(?:[/.]\d+)?(?:e[+-]?\d+)?|0x[a-f0-9]+|[1-9]\d?r[a-z0-9]+)[lmn]?(?![\w$@])/i,lookbehind:!0},function:{pattern:/((?:^|[^'])\()[\w*+!?'<>=/.-]+(?=[\s)]|$)/,lookbehind:!0},operator:/[#@^`~]/,punctuation:/[{}\[\](),]/}}return clojure_1}var cmake_1,hasRequiredCmake;function requireCmake(){if(hasRequiredCmake)return cmake_1;hasRequiredCmake=1,cmake_1=e,e.displayName="cmake",e.aliases=[];function e(t){t.languages.cmake={comment:/#.*/,string:{pattern:/"(?:[^\\"]|\\.)*"/,greedy:!0,inside:{interpolation:{pattern:/\$\{(?:[^{}$]|\$\{[^{}$]*\})*\}/,inside:{punctuation:/\$\{|\}/,variable:/\w+/}}}},variable:/\b(?:CMAKE_\w+|\w+_(?:(?:BINARY|SOURCE)_DIR|DESCRIPTION|HOMEPAGE_URL|ROOT|VERSION(?:_MAJOR|_MINOR|_PATCH|_TWEAK)?)|(?:ANDROID|APPLE|BORLAND|BUILD_SHARED_LIBS|CACHE|CPACK_(?:ABSOLUTE_DESTINATION_FILES|COMPONENT_INCLUDE_TOPLEVEL_DIRECTORY|ERROR_ON_ABSOLUTE_INSTALL_DESTINATION|INCLUDE_TOPLEVEL_DIRECTORY|INSTALL_DEFAULT_DIRECTORY_PERMISSIONS|INSTALL_SCRIPT|PACKAGING_INSTALL_PREFIX|SET_DESTDIR|WARN_ON_ABSOLUTE_INSTALL_DESTINATION)|CTEST_(?:BINARY_DIRECTORY|BUILD_COMMAND|BUILD_NAME|BZR_COMMAND|BZR_UPDATE_OPTIONS|CHANGE_ID|CHECKOUT_COMMAND|CONFIGURATION_TYPE|CONFIGURE_COMMAND|COVERAGE_COMMAND|COVERAGE_EXTRA_FLAGS|CURL_OPTIONS|CUSTOM_(?:COVERAGE_EXCLUDE|ERROR_EXCEPTION|ERROR_MATCH|ERROR_POST_CONTEXT|ERROR_PRE_CONTEXT|MAXIMUM_FAILED_TEST_OUTPUT_SIZE|MAXIMUM_NUMBER_OF_(?:ERRORS|WARNINGS)|MAXIMUM_PASSED_TEST_OUTPUT_SIZE|MEMCHECK_IGNORE|POST_MEMCHECK|POST_TEST|PRE_MEMCHECK|PRE_TEST|TESTS_IGNORE|WARNING_EXCEPTION|WARNING_MATCH)|CVS_CHECKOUT|CVS_COMMAND|CVS_UPDATE_OPTIONS|DROP_LOCATION|DROP_METHOD|DROP_SITE|DROP_SITE_CDASH|DROP_SITE_PASSWORD|DROP_SITE_USER|EXTRA_COVERAGE_GLOB|GIT_COMMAND|GIT_INIT_SUBMODULES|GIT_UPDATE_CUSTOM|GIT_UPDATE_OPTIONS|HG_COMMAND|HG_UPDATE_OPTIONS|LABELS_FOR_SUBPROJECTS|MEMORYCHECK_(?:COMMAND|COMMAND_OPTIONS|SANITIZER_OPTIONS|SUPPRESSIONS_FILE|TYPE)|NIGHTLY_START_TIME|P4_CLIENT|P4_COMMAND|P4_OPTIONS|P4_UPDATE_OPTIONS|RUN_CURRENT_SCRIPT|SCP_COMMAND|SITE|SOURCE_DIRECTORY|SUBMIT_URL|SVN_COMMAND|SVN_OPTIONS|SVN_UPDATE_OPTIONS|TEST_LOAD|TEST_TIMEOUT|TRIGGER_SITE|UPDATE_COMMAND|UPDATE_OPTIONS|UPDATE_VERSION_ONLY|USE_LAUNCHERS)|CYGWIN|ENV|EXECUTABLE_OUTPUT_PATH|GHS-MULTI|IOS|LIBRARY_OUTPUT_PATH|MINGW|MSVC(?:10|11|12|14|60|70|71|80|90|_IDE|_TOOLSET_VERSION|_VERSION)?|MSYS|PROJECT_(?:BINARY_DIR|DESCRIPTION|HOMEPAGE_URL|NAME|SOURCE_DIR|VERSION|VERSION_(?:MAJOR|MINOR|PATCH|TWEAK))|UNIX|WIN32|WINCE|WINDOWS_PHONE|WINDOWS_STORE|XCODE|XCODE_VERSION))\b/,property:/\b(?:cxx_\w+|(?:ARCHIVE_OUTPUT_(?:DIRECTORY|NAME)|COMPILE_DEFINITIONS|COMPILE_PDB_NAME|COMPILE_PDB_OUTPUT_DIRECTORY|EXCLUDE_FROM_DEFAULT_BUILD|IMPORTED_(?:IMPLIB|LIBNAME|LINK_DEPENDENT_LIBRARIES|LINK_INTERFACE_LANGUAGES|LINK_INTERFACE_LIBRARIES|LINK_INTERFACE_MULTIPLICITY|LOCATION|NO_SONAME|OBJECTS|SONAME)|INTERPROCEDURAL_OPTIMIZATION|LIBRARY_OUTPUT_DIRECTORY|LIBRARY_OUTPUT_NAME|LINK_FLAGS|LINK_INTERFACE_LIBRARIES|LINK_INTERFACE_MULTIPLICITY|LOCATION|MAP_IMPORTED_CONFIG|OSX_ARCHITECTURES|OUTPUT_NAME|PDB_NAME|PDB_OUTPUT_DIRECTORY|RUNTIME_OUTPUT_DIRECTORY|RUNTIME_OUTPUT_NAME|STATIC_LIBRARY_FLAGS|VS_CSHARP|VS_DOTNET_REFERENCEPROP|VS_DOTNET_REFERENCE|VS_GLOBAL_SECTION_POST|VS_GLOBAL_SECTION_PRE|VS_GLOBAL|XCODE_ATTRIBUTE)_\w+|\w+_(?:CLANG_TIDY|COMPILER_LAUNCHER|CPPCHECK|CPPLINT|INCLUDE_WHAT_YOU_USE|OUTPUT_NAME|POSTFIX|VISIBILITY_PRESET)|ABSTRACT|ADDITIONAL_MAKE_CLEAN_FILES|ADVANCED|ALIASED_TARGET|ALLOW_DUPLICATE_CUSTOM_TARGETS|ANDROID_(?:ANT_ADDITIONAL_OPTIONS|API|API_MIN|ARCH|ASSETS_DIRECTORIES|GUI|JAR_DEPENDENCIES|NATIVE_LIB_DEPENDENCIES|NATIVE_LIB_DIRECTORIES|PROCESS_MAX|PROGUARD|PROGUARD_CONFIG_PATH|SECURE_PROPS_PATH|SKIP_ANT_STEP|STL_TYPE)|ARCHIVE_OUTPUT_DIRECTORY|ATTACHED_FILES|ATTACHED_FILES_ON_FAIL|AUTOGEN_(?:BUILD_DIR|ORIGIN_DEPENDS|PARALLEL|SOURCE_GROUP|TARGETS_FOLDER|TARGET_DEPENDS)|AUTOMOC|AUTOMOC_(?:COMPILER_PREDEFINES|DEPEND_FILTERS|EXECUTABLE|MACRO_NAMES|MOC_OPTIONS|SOURCE_GROUP|TARGETS_FOLDER)|AUTORCC|AUTORCC_EXECUTABLE|AUTORCC_OPTIONS|AUTORCC_SOURCE_GROUP|AUTOUIC|AUTOUIC_EXECUTABLE|AUTOUIC_OPTIONS|AUTOUIC_SEARCH_PATHS|BINARY_DIR|BUILDSYSTEM_TARGETS|BUILD_RPATH|BUILD_RPATH_USE_ORIGIN|BUILD_WITH_INSTALL_NAME_DIR|BUILD_WITH_INSTALL_RPATH|BUNDLE|BUNDLE_EXTENSION|CACHE_VARIABLES|CLEAN_NO_CUSTOM|COMMON_LANGUAGE_RUNTIME|COMPATIBLE_INTERFACE_(?:BOOL|NUMBER_MAX|NUMBER_MIN|STRING)|COMPILE_(?:DEFINITIONS|FEATURES|FLAGS|OPTIONS|PDB_NAME|PDB_OUTPUT_DIRECTORY)|COST|CPACK_DESKTOP_SHORTCUTS|CPACK_NEVER_OVERWRITE|CPACK_PERMANENT|CPACK_STARTUP_SHORTCUTS|CPACK_START_MENU_SHORTCUTS|CPACK_WIX_ACL|CROSSCOMPILING_EMULATOR|CUDA_EXTENSIONS|CUDA_PTX_COMPILATION|CUDA_RESOLVE_DEVICE_SYMBOLS|CUDA_SEPARABLE_COMPILATION|CUDA_STANDARD|CUDA_STANDARD_REQUIRED|CXX_EXTENSIONS|CXX_STANDARD|CXX_STANDARD_REQUIRED|C_EXTENSIONS|C_STANDARD|C_STANDARD_REQUIRED|DEBUG_CONFIGURATIONS|DEFINE_SYMBOL|DEFINITIONS|DEPENDS|DEPLOYMENT_ADDITIONAL_FILES|DEPLOYMENT_REMOTE_DIRECTORY|DISABLED|DISABLED_FEATURES|ECLIPSE_EXTRA_CPROJECT_CONTENTS|ECLIPSE_EXTRA_NATURES|ENABLED_FEATURES|ENABLED_LANGUAGES|ENABLE_EXPORTS|ENVIRONMENT|EXCLUDE_FROM_ALL|EXCLUDE_FROM_DEFAULT_BUILD|EXPORT_NAME|EXPORT_PROPERTIES|EXTERNAL_OBJECT|EchoString|FAIL_REGULAR_EXPRESSION|FIND_LIBRARY_USE_LIB32_PATHS|FIND_LIBRARY_USE_LIB64_PATHS|FIND_LIBRARY_USE_LIBX32_PATHS|FIND_LIBRARY_USE_OPENBSD_VERSIONING|FIXTURES_CLEANUP|FIXTURES_REQUIRED|FIXTURES_SETUP|FOLDER|FRAMEWORK|Fortran_FORMAT|Fortran_MODULE_DIRECTORY|GENERATED|GENERATOR_FILE_NAME|GENERATOR_IS_MULTI_CONFIG|GHS_INTEGRITY_APP|GHS_NO_SOURCE_GROUP_FILE|GLOBAL_DEPENDS_DEBUG_MODE|GLOBAL_DEPENDS_NO_CYCLES|GNUtoMS|HAS_CXX|HEADER_FILE_ONLY|HELPSTRING|IMPLICIT_DEPENDS_INCLUDE_TRANSFORM|IMPORTED|IMPORTED_(?:COMMON_LANGUAGE_RUNTIME|CONFIGURATIONS|GLOBAL|IMPLIB|LIBNAME|LINK_DEPENDENT_LIBRARIES|LINK_INTERFACE_(?:LANGUAGES|LIBRARIES|MULTIPLICITY)|LOCATION|NO_SONAME|OBJECTS|SONAME)|IMPORT_PREFIX|IMPORT_SUFFIX|INCLUDE_DIRECTORIES|INCLUDE_REGULAR_EXPRESSION|INSTALL_NAME_DIR|INSTALL_RPATH|INSTALL_RPATH_USE_LINK_PATH|INTERFACE_(?:AUTOUIC_OPTIONS|COMPILE_DEFINITIONS|COMPILE_FEATURES|COMPILE_OPTIONS|INCLUDE_DIRECTORIES|LINK_DEPENDS|LINK_DIRECTORIES|LINK_LIBRARIES|LINK_OPTIONS|POSITION_INDEPENDENT_CODE|SOURCES|SYSTEM_INCLUDE_DIRECTORIES)|INTERPROCEDURAL_OPTIMIZATION|IN_TRY_COMPILE|IOS_INSTALL_COMBINED|JOB_POOLS|JOB_POOL_COMPILE|JOB_POOL_LINK|KEEP_EXTENSION|LABELS|LANGUAGE|LIBRARY_OUTPUT_DIRECTORY|LINKER_LANGUAGE|LINK_(?:DEPENDS|DEPENDS_NO_SHARED|DIRECTORIES|FLAGS|INTERFACE_LIBRARIES|INTERFACE_MULTIPLICITY|LIBRARIES|OPTIONS|SEARCH_END_STATIC|SEARCH_START_STATIC|WHAT_YOU_USE)|LISTFILE_STACK|LOCATION|MACOSX_BUNDLE|MACOSX_BUNDLE_INFO_PLIST|MACOSX_FRAMEWORK_INFO_PLIST|MACOSX_PACKAGE_LOCATION|MACOSX_RPATH|MACROS|MANUALLY_ADDED_DEPENDENCIES|MEASUREMENT|MODIFIED|NAME|NO_SONAME|NO_SYSTEM_FROM_IMPORTED|OBJECT_DEPENDS|OBJECT_OUTPUTS|OSX_ARCHITECTURES|OUTPUT_NAME|PACKAGES_FOUND|PACKAGES_NOT_FOUND|PARENT_DIRECTORY|PASS_REGULAR_EXPRESSION|PDB_NAME|PDB_OUTPUT_DIRECTORY|POSITION_INDEPENDENT_CODE|POST_INSTALL_SCRIPT|PREDEFINED_TARGETS_FOLDER|PREFIX|PRE_INSTALL_SCRIPT|PRIVATE_HEADER|PROCESSORS|PROCESSOR_AFFINITY|PROJECT_LABEL|PUBLIC_HEADER|REPORT_UNDEFINED_PROPERTIES|REQUIRED_FILES|RESOURCE|RESOURCE_LOCK|RULE_LAUNCH_COMPILE|RULE_LAUNCH_CUSTOM|RULE_LAUNCH_LINK|RULE_MESSAGES|RUNTIME_OUTPUT_DIRECTORY|RUN_SERIAL|SKIP_AUTOGEN|SKIP_AUTOMOC|SKIP_AUTORCC|SKIP_AUTOUIC|SKIP_BUILD_RPATH|SKIP_RETURN_CODE|SOURCES|SOURCE_DIR|SOVERSION|STATIC_LIBRARY_FLAGS|STATIC_LIBRARY_OPTIONS|STRINGS|SUBDIRECTORIES|SUFFIX|SYMBOLIC|TARGET_ARCHIVES_MAY_BE_SHARED_LIBS|TARGET_MESSAGES|TARGET_SUPPORTS_SHARED_LIBS|TESTS|TEST_INCLUDE_FILE|TEST_INCLUDE_FILES|TIMEOUT|TIMEOUT_AFTER_MATCH|TYPE|USE_FOLDERS|VALUE|VARIABLES|VERSION|VISIBILITY_INLINES_HIDDEN|VS_(?:CONFIGURATION_TYPE|COPY_TO_OUT_DIR|DEBUGGER_(?:COMMAND|COMMAND_ARGUMENTS|ENVIRONMENT|WORKING_DIRECTORY)|DEPLOYMENT_CONTENT|DEPLOYMENT_LOCATION|DOTNET_REFERENCES|DOTNET_REFERENCES_COPY_LOCAL|GLOBAL_KEYWORD|GLOBAL_PROJECT_TYPES|GLOBAL_ROOTNAMESPACE|INCLUDE_IN_VSIX|IOT_STARTUP_TASK|KEYWORD|RESOURCE_GENERATOR|SCC_AUXPATH|SCC_LOCALPATH|SCC_PROJECTNAME|SCC_PROVIDER|SDK_REFERENCES|SHADER_(?:DISABLE_OPTIMIZATIONS|ENABLE_DEBUG|ENTRYPOINT|FLAGS|MODEL|OBJECT_FILE_NAME|OUTPUT_HEADER_FILE|TYPE|VARIABLE_NAME)|STARTUP_PROJECT|TOOL_OVERRIDE|USER_PROPS|WINRT_COMPONENT|WINRT_EXTENSIONS|WINRT_REFERENCES|XAML_TYPE)|WILL_FAIL|WIN32_EXECUTABLE|WINDOWS_EXPORT_ALL_SYMBOLS|WORKING_DIRECTORY|WRAP_EXCLUDE|XCODE_(?:EMIT_EFFECTIVE_PLATFORM_NAME|EXPLICIT_FILE_TYPE|FILE_ATTRIBUTES|LAST_KNOWN_FILE_TYPE|PRODUCT_TYPE|SCHEME_(?:ADDRESS_SANITIZER|ADDRESS_SANITIZER_USE_AFTER_RETURN|ARGUMENTS|DISABLE_MAIN_THREAD_CHECKER|DYNAMIC_LIBRARY_LOADS|DYNAMIC_LINKER_API_USAGE|ENVIRONMENT|EXECUTABLE|GUARD_MALLOC|MAIN_THREAD_CHECKER_STOP|MALLOC_GUARD_EDGES|MALLOC_SCRIBBLE|MALLOC_STACK|THREAD_SANITIZER(?:_STOP)?|UNDEFINED_BEHAVIOUR_SANITIZER(?:_STOP)?|ZOMBIE_OBJECTS))|XCTEST)\b/,keyword:/\b(?:add_compile_definitions|add_compile_options|add_custom_command|add_custom_target|add_definitions|add_dependencies|add_executable|add_library|add_link_options|add_subdirectory|add_test|aux_source_directory|break|build_command|build_name|cmake_host_system_information|cmake_minimum_required|cmake_parse_arguments|cmake_policy|configure_file|continue|create_test_sourcelist|ctest_build|ctest_configure|ctest_coverage|ctest_empty_binary_directory|ctest_memcheck|ctest_read_custom_files|ctest_run_script|ctest_sleep|ctest_start|ctest_submit|ctest_test|ctest_update|ctest_upload|define_property|else|elseif|enable_language|enable_testing|endforeach|endfunction|endif|endmacro|endwhile|exec_program|execute_process|export|export_library_dependencies|file|find_file|find_library|find_package|find_path|find_program|fltk_wrap_ui|foreach|function|get_cmake_property|get_directory_property|get_filename_component|get_property|get_source_file_property|get_target_property|get_test_property|if|include|include_directories|include_external_msproject|include_guard|include_regular_expression|install|install_files|install_programs|install_targets|link_directories|link_libraries|list|load_cache|load_command|macro|make_directory|mark_as_advanced|math|message|option|output_required_files|project|qt_wrap_cpp|qt_wrap_ui|remove|remove_definitions|return|separate_arguments|set|set_directory_properties|set_property|set_source_files_properties|set_target_properties|set_tests_properties|site_name|source_group|string|subdir_depends|subdirs|target_compile_definitions|target_compile_features|target_compile_options|target_include_directories|target_link_directories|target_link_libraries|target_link_options|target_sources|try_compile|try_run|unset|use_mangled_mesa|utility_source|variable_requires|variable_watch|while|write_file)(?=\s*\()\b/,boolean:/\b(?:FALSE|OFF|ON|TRUE)\b/,namespace:/\b(?:INTERFACE|PRIVATE|PROPERTIES|PUBLIC|SHARED|STATIC|TARGET_OBJECTS)\b/,operator:/\b(?:AND|DEFINED|EQUAL|GREATER|LESS|MATCHES|NOT|OR|STREQUAL|STRGREATER|STRLESS|VERSION_EQUAL|VERSION_GREATER|VERSION_LESS)\b/,inserted:{pattern:/\b\w+::\w+\b/,alias:"class-name"},number:/\b\d+(?:\.\d+)*\b/,function:/\b[a-z_]\w*(?=\s*\()\b/i,punctuation:/[()>}]|\$[<{]/}}return cmake_1}var cobol_1,hasRequiredCobol;function requireCobol(){if(hasRequiredCobol)return cobol_1;hasRequiredCobol=1,cobol_1=e,e.displayName="cobol",e.aliases=[];function e(t){t.languages.cobol={comment:{pattern:/\*>.*|(^[ \t]*)\*.*/m,lookbehind:!0,greedy:!0},string:{pattern:/[xzgn]?(?:"(?:[^\r\n"]|"")*"(?!")|'(?:[^\r\n']|'')*'(?!'))/i,greedy:!0},level:{pattern:/(^[ \t]*)\d+\b/m,lookbehind:!0,greedy:!0,alias:"number"},"class-name":{pattern:/(\bpic(?:ture)?\s+)(?:(?:[-\w$/,:*+<>]|\.(?!\s|$))(?:\(\d+\))?)+/i,lookbehind:!0,inside:{number:{pattern:/(\()\d+/,lookbehind:!0},punctuation:/[()]/}},keyword:{pattern:/(^|[^\w-])(?:ABORT|ACCEPT|ACCESS|ADD|ADDRESS|ADVANCING|AFTER|ALIGNED|ALL|ALPHABET|ALPHABETIC|ALPHABETIC-LOWER|ALPHABETIC-UPPER|ALPHANUMERIC|ALPHANUMERIC-EDITED|ALSO|ALTER|ALTERNATE|ANY|ARE|AREA|AREAS|AS|ASCENDING|ASCII|ASSIGN|ASSOCIATED-DATA|ASSOCIATED-DATA-LENGTH|AT|ATTRIBUTE|AUTHOR|AUTO|AUTO-SKIP|BACKGROUND-COLOR|BACKGROUND-COLOUR|BASIS|BEEP|BEFORE|BEGINNING|BELL|BINARY|BIT|BLANK|BLINK|BLOCK|BOTTOM|BOUNDS|BY|BYFUNCTION|BYTITLE|CALL|CANCEL|CAPABLE|CCSVERSION|CD|CF|CH|CHAINING|CHANGED|CHANNEL|CHARACTER|CHARACTERS|CLASS|CLASS-ID|CLOCK-UNITS|CLOSE|CLOSE-DISPOSITION|COBOL|CODE|CODE-SET|COL|COLLATING|COLUMN|COM-REG|COMMA|COMMITMENT|COMMON|COMMUNICATION|COMP|COMP-1|COMP-2|COMP-3|COMP-4|COMP-5|COMPUTATIONAL|COMPUTATIONAL-1|COMPUTATIONAL-2|COMPUTATIONAL-3|COMPUTATIONAL-4|COMPUTATIONAL-5|COMPUTE|CONFIGURATION|CONTAINS|CONTENT|CONTINUE|CONTROL|CONTROL-POINT|CONTROLS|CONVENTION|CONVERTING|COPY|CORR|CORRESPONDING|COUNT|CRUNCH|CURRENCY|CURSOR|DATA|DATA-BASE|DATE|DATE-COMPILED|DATE-WRITTEN|DAY|DAY-OF-WEEK|DBCS|DE|DEBUG-CONTENTS|DEBUG-ITEM|DEBUG-LINE|DEBUG-NAME|DEBUG-SUB-1|DEBUG-SUB-2|DEBUG-SUB-3|DEBUGGING|DECIMAL-POINT|DECLARATIVES|DEFAULT|DEFAULT-DISPLAY|DEFINITION|DELETE|DELIMITED|DELIMITER|DEPENDING|DESCENDING|DESTINATION|DETAIL|DFHRESP|DFHVALUE|DISABLE|DISK|DISPLAY|DISPLAY-1|DIVIDE|DIVISION|DONTCARE|DOUBLE|DOWN|DUPLICATES|DYNAMIC|EBCDIC|EGCS|EGI|ELSE|EMI|EMPTY-CHECK|ENABLE|END|END-ACCEPT|END-ADD|END-CALL|END-COMPUTE|END-DELETE|END-DIVIDE|END-EVALUATE|END-IF|END-MULTIPLY|END-OF-PAGE|END-PERFORM|END-READ|END-RECEIVE|END-RETURN|END-REWRITE|END-SEARCH|END-START|END-STRING|END-SUBTRACT|END-UNSTRING|END-WRITE|ENDING|ENTER|ENTRY|ENTRY-PROCEDURE|ENVIRONMENT|EOL|EOP|EOS|ERASE|ERROR|ESCAPE|ESI|EVALUATE|EVENT|EVERY|EXCEPTION|EXCLUSIVE|EXHIBIT|EXIT|EXPORT|EXTEND|EXTENDED|EXTERNAL|FD|FILE|FILE-CONTROL|FILLER|FINAL|FIRST|FOOTING|FOR|FOREGROUND-COLOR|FOREGROUND-COLOUR|FROM|FULL|FUNCTION|FUNCTION-POINTER|FUNCTIONNAME|GENERATE|GIVING|GLOBAL|GO|GOBACK|GRID|GROUP|HEADING|HIGH-VALUE|HIGH-VALUES|HIGHLIGHT|I-O|I-O-CONTROL|ID|IDENTIFICATION|IF|IMPLICIT|IMPORT|IN|INDEX|INDEXED|INDICATE|INITIAL|INITIALIZE|INITIATE|INPUT|INPUT-OUTPUT|INSPECT|INSTALLATION|INTEGER|INTO|INVALID|INVOKE|IS|JUST|JUSTIFIED|KANJI|KEPT|KEY|KEYBOARD|LABEL|LANGUAGE|LAST|LB|LD|LEADING|LEFT|LEFTLINE|LENGTH|LENGTH-CHECK|LIBACCESS|LIBPARAMETER|LIBRARY|LIMIT|LIMITS|LINAGE|LINAGE-COUNTER|LINE|LINE-COUNTER|LINES|LINKAGE|LIST|LOCAL|LOCAL-STORAGE|LOCK|LONG-DATE|LONG-TIME|LOW-VALUE|LOW-VALUES|LOWER|LOWLIGHT|MEMORY|MERGE|MESSAGE|MMDDYYYY|MODE|MODULES|MORE-LABELS|MOVE|MULTIPLE|MULTIPLY|NAMED|NATIONAL|NATIONAL-EDITED|NATIVE|NEGATIVE|NETWORK|NEXT|NO|NO-ECHO|NULL|NULLS|NUMBER|NUMERIC|NUMERIC-DATE|NUMERIC-EDITED|NUMERIC-TIME|OBJECT-COMPUTER|OCCURS|ODT|OF|OFF|OMITTED|ON|OPEN|OPTIONAL|ORDER|ORDERLY|ORGANIZATION|OTHER|OUTPUT|OVERFLOW|OVERLINE|OWN|PACKED-DECIMAL|PADDING|PAGE|PAGE-COUNTER|PASSWORD|PERFORM|PF|PH|PIC|PICTURE|PLUS|POINTER|PORT|POSITION|POSITIVE|PRINTER|PRINTING|PRIVATE|PROCEDURE|PROCEDURE-POINTER|PROCEDURES|PROCEED|PROCESS|PROGRAM|PROGRAM-ID|PROGRAM-LIBRARY|PROMPT|PURGE|QUEUE|QUOTE|QUOTES|RANDOM|RD|READ|READER|REAL|RECEIVE|RECEIVED|RECORD|RECORDING|RECORDS|RECURSIVE|REDEFINES|REEL|REF|REFERENCE|REFERENCES|RELATIVE|RELEASE|REMAINDER|REMARKS|REMOTE|REMOVAL|REMOVE|RENAMES|REPLACE|REPLACING|REPORT|REPORTING|REPORTS|REQUIRED|RERUN|RESERVE|RESET|RETURN|RETURN-CODE|RETURNING|REVERSE-VIDEO|REVERSED|REWIND|REWRITE|RF|RH|RIGHT|ROUNDED|RUN|SAME|SAVE|SCREEN|SD|SEARCH|SECTION|SECURE|SECURITY|SEGMENT|SEGMENT-LIMIT|SELECT|SEND|SENTENCE|SEPARATE|SEQUENCE|SEQUENTIAL|SET|SHARED|SHAREDBYALL|SHAREDBYRUNUNIT|SHARING|SHIFT-IN|SHIFT-OUT|SHORT-DATE|SIGN|SIZE|SORT|SORT-CONTROL|SORT-CORE-SIZE|SORT-FILE-SIZE|SORT-MERGE|SORT-MESSAGE|SORT-MODE-SIZE|SORT-RETURN|SOURCE|SOURCE-COMPUTER|SPACE|SPACES|SPECIAL-NAMES|STANDARD|STANDARD-1|STANDARD-2|START|STATUS|STOP|STRING|SUB-QUEUE-1|SUB-QUEUE-2|SUB-QUEUE-3|SUBTRACT|SUM|SUPPRESS|SYMBOL|SYMBOLIC|SYNC|SYNCHRONIZED|TABLE|TALLY|TALLYING|TAPE|TASK|TERMINAL|TERMINATE|TEST|TEXT|THEN|THREAD|THREAD-LOCAL|THROUGH|THRU|TIME|TIMER|TIMES|TITLE|TO|TODAYS-DATE|TODAYS-NAME|TOP|TRAILING|TRUNCATED|TYPE|TYPEDEF|UNDERLINE|UNIT|UNSTRING|UNTIL|UP|UPON|USAGE|USE|USING|VALUE|VALUES|VARYING|VIRTUAL|WAIT|WHEN|WHEN-COMPILED|WITH|WORDS|WORKING-STORAGE|WRITE|YEAR|YYYYDDD|YYYYMMDD|ZERO-FILL|ZEROES|ZEROS)(?![\w-])/i,lookbehind:!0},boolean:{pattern:/(^|[^\w-])(?:false|true)(?![\w-])/i,lookbehind:!0},number:{pattern:/(^|[^\w-])(?:[+-]?(?:(?:\d+(?:[.,]\d+)?|[.,]\d+)(?:e[+-]?\d+)?|zero))(?![\w-])/i,lookbehind:!0},operator:[/<>|[<>]=?|[=+*/&]/,{pattern:/(^|[^\w-])(?:-|and|equal|greater|less|not|or|than)(?![\w-])/i,lookbehind:!0}],punctuation:/[.:,()]/}}return cobol_1}var coffeescript_1,hasRequiredCoffeescript;function requireCoffeescript(){if(hasRequiredCoffeescript)return coffeescript_1;hasRequiredCoffeescript=1,coffeescript_1=e,e.displayName="coffeescript",e.aliases=["coffee"];function e(t){(function(Ye){var tt=/#(?!\{).+/,rt={pattern:/#\{[^}]+\}/,alias:"variable"};Ye.languages.coffeescript=Ye.languages.extend("javascript",{comment:tt,string:[{pattern:/'(?:\\[\s\S]|[^\\'])*'/,greedy:!0},{pattern:/"(?:\\[\s\S]|[^\\"])*"/,greedy:!0,inside:{interpolation:rt}}],keyword:/\b(?:and|break|by|catch|class|continue|debugger|delete|do|each|else|extend|extends|false|finally|for|if|in|instanceof|is|isnt|let|loop|namespace|new|no|not|null|of|off|on|or|own|return|super|switch|then|this|throw|true|try|typeof|undefined|unless|until|when|while|window|with|yes|yield)\b/,"class-member":{pattern:/@(?!\d)\w+/,alias:"variable"}}),Ye.languages.insertBefore("coffeescript","comment",{"multiline-comment":{pattern:/###[\s\S]+?###/,alias:"comment"},"block-regex":{pattern:/\/{3}[\s\S]*?\/{3}/,alias:"regex",inside:{comment:tt,interpolation:rt}}}),Ye.languages.insertBefore("coffeescript","string",{"inline-javascript":{pattern:/`(?:\\[\s\S]|[^\\`])*`/,inside:{delimiter:{pattern:/^`|`$/,alias:"punctuation"},script:{pattern:/[\s\S]+/,alias:"language-javascript",inside:Ye.languages.javascript}}},"multiline-string":[{pattern:/'''[\s\S]*?'''/,greedy:!0,alias:"string"},{pattern:/"""[\s\S]*?"""/,greedy:!0,alias:"string",inside:{interpolation:rt}}]}),Ye.languages.insertBefore("coffeescript","keyword",{property:/(?!\d)\w+(?=\s*:(?!:))/}),delete Ye.languages.coffeescript["template-string"],Ye.languages.coffee=Ye.languages.coffeescript})(t)}return coffeescript_1}var concurnas_1,hasRequiredConcurnas;function requireConcurnas(){if(hasRequiredConcurnas)return concurnas_1;hasRequiredConcurnas=1,concurnas_1=e,e.displayName="concurnas",e.aliases=["conc"];function e(t){t.languages.concurnas={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?(?:\*\/|$)|\/\/.*)/,lookbehind:!0,greedy:!0},langext:{pattern:/\b\w+\s*\|\|[\s\S]+?\|\|/,greedy:!0,inside:{"class-name":/^\w+/,string:{pattern:/(^\s*\|\|)[\s\S]+(?=\|\|$)/,lookbehind:!0},punctuation:/\|\|/}},function:{pattern:/((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/,lookbehind:!0},keyword:/\b(?:abstract|actor|also|annotation|assert|async|await|bool|boolean|break|byte|case|catch|changed|char|class|closed|constant|continue|def|default|del|double|elif|else|enum|every|extends|false|finally|float|for|from|global|gpudef|gpukernel|if|import|in|init|inject|int|lambda|local|long|loop|match|new|nodefault|null|of|onchange|open|out|override|package|parfor|parforsync|post|pre|private|protected|provide|provider|public|return|shared|short|single|size_t|sizeof|super|sync|this|throw|trait|trans|transient|true|try|typedef|unchecked|using|val|var|void|while|with)\b/,boolean:/\b(?:false|true)\b/,number:/\b0b[01][01_]*L?\b|\b0x(?:[\da-f_]*\.)?[\da-f_p+-]+\b|(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?\d[\d_]*)?[dfls]?/i,punctuation:/[{}[\];(),.:]/,operator:/<==|>==|=>|->|<-|<>|&==|&<>|\?:?|\.\?|\+\+|--|[-+*/=<>]=?|[!^~]|\b(?:and|as|band|bor|bxor|comp|is|isnot|mod|or)\b=?/,annotation:{pattern:/@(?:\w+:)?(?:\w+|\[[^\]]+\])?/,alias:"builtin"}},t.languages.insertBefore("concurnas","langext",{"regex-literal":{pattern:/\br("|')(?:\\.|(?!\1)[^\\\r\n])*\1/,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:t.languages.concurnas},regex:/[\s\S]+/}},"string-literal":{pattern:/(?:\B|\bs)("|')(?:\\.|(?!\1)[^\\\r\n])*\1/,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:t.languages.concurnas},string:/[\s\S]+/}}}),t.languages.conc=t.languages.concurnas}return concurnas_1}var coq_1,hasRequiredCoq;function requireCoq(){if(hasRequiredCoq)return coq_1;hasRequiredCoq=1,coq_1=e,e.displayName="coq",e.aliases=[];function e(t){(function(Ye){for(var tt=/\(\*(?:[^(*]|\((?!\*)|\*(?!\))|<self>)*\*\)/.source,rt=0;rt<2;rt++)tt=tt.replace(/<self>/g,function(){return tt});tt=tt.replace(/<self>/g,"[]"),Ye.languages.coq={comment:RegExp(tt),string:{pattern:/"(?:[^"]|"")*"(?!")/,greedy:!0},attribute:[{pattern:RegExp(/#\[(?:[^\[\]("]|"(?:[^"]|"")*"(?!")|\((?!\*)|<comment>)*\]/.source.replace(/<comment>/g,function(){return tt})),greedy:!0,alias:"attr-name",inside:{comment:RegExp(tt),string:{pattern:/"(?:[^"]|"")*"(?!")/,greedy:!0},operator:/=/,punctuation:/^#\[|\]$|[,()]/}},{pattern:/\b(?:Cumulative|Global|Local|Monomorphic|NonCumulative|Polymorphic|Private|Program)\b/,alias:"attr-name"}],keyword:/\b(?:Abort|About|Add|Admit|Admitted|All|Arguments|As|Assumptions|Axiom|Axioms|Back|BackTo|Backtrace|BinOp|BinOpSpec|BinRel|Bind|Blacklist|Canonical|Case|Cd|Check|Class|Classes|Close|CoFixpoint|CoInductive|Coercion|Coercions|Collection|Combined|Compute|Conjecture|Conjectures|Constant|Constants|Constraint|Constructors|Context|Corollary|Create|CstOp|Custom|Cut|Debug|Declare|Defined|Definition|Delimit|Dependencies|Dependent|Derive|Diffs|Drop|Elimination|End|Entry|Equality|Eval|Example|Existential|Existentials|Existing|Export|Extern|Extraction|Fact|Fail|Field|File|Firstorder|Fixpoint|Flags|Focus|From|Funclass|Function|Functional|GC|Generalizable|Goal|Grab|Grammar|Graph|Guarded|Haskell|Heap|Hide|Hint|HintDb|Hints|Hypotheses|Hypothesis|IF|Identity|Immediate|Implicit|Implicits|Import|Include|Induction|Inductive|Infix|Info|Initial|InjTyp|Inline|Inspect|Instance|Instances|Intro|Intros|Inversion|Inversion_clear|JSON|Language|Left|Lemma|Let|Lia|Libraries|Library|Load|LoadPath|Locate|Ltac|Ltac2|ML|Match|Method|Minimality|Module|Modules|Morphism|Next|NoInline|Notation|Number|OCaml|Obligation|Obligations|Opaque|Open|Optimize|Parameter|Parameters|Parametric|Path|Paths|Prenex|Preterm|Primitive|Print|Profile|Projections|Proof|Prop|PropBinOp|PropOp|PropUOp|Property|Proposition|Pwd|Qed|Quit|Rec|Record|Recursive|Redirect|Reduction|Register|Relation|Remark|Remove|Require|Reserved|Reset|Resolve|Restart|Rewrite|Right|Ring|Rings|SProp|Saturate|Save|Scheme|Scope|Scopes|Search|SearchHead|SearchPattern|SearchRewrite|Section|Separate|Set|Setoid|Show|Signatures|Solve|Solver|Sort|Sortclass|Sorted|Spec|Step|Strategies|Strategy|String|Structure|SubClass|Subgraph|SuchThat|Tactic|Term|TestCompile|Theorem|Time|Timeout|To|Transparent|Type|Typeclasses|Types|Typing|UnOp|UnOpSpec|Undelimit|Undo|Unfocus|Unfocused|Unfold|Universe|Universes|Unshelve|Variable|Variables|Variant|Verbose|View|Visibility|Zify|_|apply|as|at|by|cofix|else|end|exists|exists2|fix|for|forall|fun|if|in|let|match|measure|move|removed|return|struct|then|using|wf|where|with)\b/,number:/\b(?:0x[a-f0-9][a-f0-9_]*(?:\.[a-f0-9_]+)?(?:p[+-]?\d[\d_]*)?|\d[\d_]*(?:\.[\d_]+)?(?:e[+-]?\d[\d_]*)?)\b/i,punct:{pattern:/@\{|\{\||\[=|:>/,alias:"punctuation"},operator:/\/\\|\\\/|\.{2,3}|:{1,2}=|\*\*|[-=]>|<(?:->?|[+:=>]|<:)|>(?:=|->)|\|[-|]?|[-!%&*+/<=>?@^~']/,punctuation:/\.\(|`\(|@\{|`\{|\{\||\[=|:>|[:.,;(){}\[\]]/}})(t)}return coq_1}var ruby_1,hasRequiredRuby;function requireRuby(){if(hasRequiredRuby)return ruby_1;hasRequiredRuby=1,ruby_1=e,e.displayName="ruby",e.aliases=["rb"];function e(t){(function(Ye){Ye.languages.ruby=Ye.languages.extend("clike",{comment:{pattern:/#.*|^=begin\s[\s\S]*?^=end/m,greedy:!0},"class-name":{pattern:/(\b(?:class|module)\s+|\bcatch\s+\()[\w.\\]+|\b[A-Z_]\w*(?=\s*\.\s*new\b)/,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:BEGIN|END|alias|and|begin|break|case|class|def|define_method|defined|do|each|else|elsif|end|ensure|extend|for|if|in|include|module|new|next|nil|not|or|prepend|private|protected|public|raise|redo|require|rescue|retry|return|self|super|then|throw|undef|unless|until|when|while|yield)\b/,operator:/\.{2,3}|&\.|===|<?=>|[!=]?~|(?:&&|\|\||<<|>>|\*\*|[+\-*/%<>!^&|=])=?|[?:]/,punctuation:/[(){}[\].,;]/}),Ye.languages.insertBefore("ruby","operator",{"double-colon":{pattern:/::/,alias:"punctuation"}});var tt={pattern:/((?:^|[^\\])(?:\\{2})*)#\{(?:[^{}]|\{[^{}]*\})*\}/,lookbehind:!0,inside:{content:{pattern:/^(#\{)[\s\S]+(?=\}$)/,lookbehind:!0,inside:Ye.languages.ruby},delimiter:{pattern:/^#\{|\}$/,alias:"punctuation"}}};delete Ye.languages.ruby.function;var rt="(?:"+[/([^a-zA-Z0-9\s{(\[<=])(?:(?!\1)[^\\]|\\[\s\S])*\1/.source,/\((?:[^()\\]|\\[\s\S]|\((?:[^()\\]|\\[\s\S])*\))*\)/.source,/\{(?:[^{}\\]|\\[\s\S]|\{(?:[^{}\\]|\\[\s\S])*\})*\}/.source,/\[(?:[^\[\]\\]|\\[\s\S]|\[(?:[^\[\]\\]|\\[\s\S])*\])*\]/.source,/<(?:[^<>\\]|\\[\s\S]|<(?:[^<>\\]|\\[\s\S])*>)*>/.source].join("|")+")",nt=/(?:"(?:\\.|[^"\\\r\n])*"|(?:\b[a-zA-Z_]\w*|[^\s\0-\x7F]+)[?!]?|\$.)/.source;Ye.languages.insertBefore("ruby","keyword",{"regex-literal":[{pattern:RegExp(/%r/.source+rt+/[egimnosux]{0,6}/.source),greedy:!0,inside:{interpolation:tt,regex:/[\s\S]+/}},{pattern:/(^|[^/])\/(?!\/)(?:\[[^\r\n\]]+\]|\\.|[^[/\\\r\n])+\/[egimnosux]{0,6}(?=\s*(?:$|[\r\n,.;})#]))/,lookbehind:!0,greedy:!0,inside:{interpolation:tt,regex:/[\s\S]+/}}],variable:/[@$]+[a-zA-Z_]\w*(?:[?!]|\b)/,symbol:[{pattern:RegExp(/(^|[^:]):/.source+nt),lookbehind:!0,greedy:!0},{pattern:RegExp(/([\r\n{(,][ \t]*)/.source+nt+/(?=:(?!:))/.source),lookbehind:!0,greedy:!0}],"method-definition":{pattern:/(\bdef\s+)\w+(?:\s*\.\s*\w+)?/,lookbehind:!0,inside:{function:/\b\w+$/,keyword:/^self\b/,"class-name":/^\w+/,punctuation:/\./}}}),Ye.languages.insertBefore("ruby","string",{"string-literal":[{pattern:RegExp(/%[qQiIwWs]?/.source+rt),greedy:!0,inside:{interpolation:tt,string:/[\s\S]+/}},{pattern:/("|')(?:#\{[^}]+\}|#(?!\{)|\\(?:\r\n|[\s\S])|(?!\1)[^\\#\r\n])*\1/,greedy:!0,inside:{interpolation:tt,string:/[\s\S]+/}},{pattern:/<<[-~]?([a-z_]\w*)[\r\n](?:.*[\r\n])*?[\t ]*\1/i,alias:"heredoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<[-~]?[a-z_]\w*|\b[a-z_]\w*$/i,inside:{symbol:/\b\w+/,punctuation:/^<<[-~]?/}},interpolation:tt,string:/[\s\S]+/}},{pattern:/<<[-~]?'([a-z_]\w*)'[\r\n](?:.*[\r\n])*?[\t ]*\1/i,alias:"heredoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<[-~]?'[a-z_]\w*'|\b[a-z_]\w*$/i,inside:{symbol:/\b\w+/,punctuation:/^<<[-~]?'|'$/}},string:/[\s\S]+/}}],"command-literal":[{pattern:RegExp(/%x/.source+rt),greedy:!0,inside:{interpolation:tt,command:{pattern:/[\s\S]+/,alias:"string"}}},{pattern:/`(?:#\{[^}]+\}|#(?!\{)|\\(?:\r\n|[\s\S])|[^\\`#\r\n])*`/,greedy:!0,inside:{interpolation:tt,command:{pattern:/[\s\S]+/,alias:"string"}}}]}),delete Ye.languages.ruby.string,Ye.languages.insertBefore("ruby","number",{builtin:/\b(?:Array|Bignum|Binding|Class|Continuation|Dir|Exception|FalseClass|File|Fixnum|Float|Hash|IO|Integer|MatchData|Method|Module|NilClass|Numeric|Object|Proc|Range|Regexp|Stat|String|Struct|Symbol|TMS|Thread|ThreadGroup|Time|TrueClass)\b/,constant:/\b[A-Z][A-Z0-9_]*(?:[?!]|\b)/}),Ye.languages.rb=Ye.languages.ruby})(t)}return ruby_1}var crystal_1,hasRequiredCrystal;function requireCrystal(){if(hasRequiredCrystal)return crystal_1;hasRequiredCrystal=1;var e=requireRuby();crystal_1=t,t.displayName="crystal",t.aliases=[];function t(Ye){Ye.register(e),function(tt){tt.languages.crystal=tt.languages.extend("ruby",{keyword:[/\b(?:__DIR__|__END_LINE__|__FILE__|__LINE__|abstract|alias|annotation|as|asm|begin|break|case|class|def|do|else|elsif|end|ensure|enum|extend|for|fun|if|ifdef|include|instance_sizeof|lib|macro|module|next|of|out|pointerof|private|protected|ptr|require|rescue|return|select|self|sizeof|struct|super|then|type|typeof|undef|uninitialized|union|unless|until|when|while|with|yield)\b/,{pattern:/(\.\s*)(?:is_a|responds_to)\?/,lookbehind:!0}],number:/\b(?:0b[01_]*[01]|0o[0-7_]*[0-7]|0x[\da-fA-F_]*[\da-fA-F]|(?:\d(?:[\d_]*\d)?)(?:\.[\d_]*\d)?(?:[eE][+-]?[\d_]*\d)?)(?:_(?:[uif](?:8|16|32|64))?)?\b/,operator:[/->/,tt.languages.ruby.operator],punctuation:/[(){}[\].,;\\]/}),tt.languages.insertBefore("crystal","string-literal",{attribute:{pattern:/@\[.*?\]/,inside:{delimiter:{pattern:/^@\[|\]$/,alias:"punctuation"},attribute:{pattern:/^(\s*)\w+/,lookbehind:!0,alias:"class-name"},args:{pattern:/\S(?:[\s\S]*\S)?/,inside:tt.languages.crystal}}},expansion:{pattern:/\{(?:\{.*?\}|%.*?%)\}/,inside:{content:{pattern:/^(\{.)[\s\S]+(?=.\}$)/,lookbehind:!0,inside:tt.languages.crystal},delimiter:{pattern:/^\{[\{%]|[\}%]\}$/,alias:"operator"}}},char:{pattern:/'(?:[^\\\r\n]{1,2}|\\(?:.|u(?:[A-Fa-f0-9]{1,4}|\{[A-Fa-f0-9]{1,6}\})))'/,greedy:!0}})}(Ye)}return crystal_1}var cshtml_1,hasRequiredCshtml;function requireCshtml(){if(hasRequiredCshtml)return cshtml_1;hasRequiredCshtml=1;var e=requireCsharp();cshtml_1=t,t.displayName="cshtml",t.aliases=["razor"];function t(Ye){Ye.register(e),function(tt){var rt=/\/(?![/*])|\/\/.*[\r\n]|\/\*[^*]*(?:\*(?!\/)[^*]*)*\*\//.source,nt=/@(?!")|"(?:[^\r\n\\"]|\\.)*"|@"(?:[^\\"]|""|\\[\s\S])*"(?!")/.source+"|"+/'(?:(?:[^\r\n'\\]|\\.|\\[Uux][\da-fA-F]{1,8})'|(?=[^\\](?!')))/.source;function at(zt,Yt){for(var Gt=0;Gt<Yt;Gt++)zt=zt.replace(/<self>/g,function(){return"(?:"+zt+")"});return zt.replace(/<self>/g,"[^\\s\\S]").replace(/<str>/g,"(?:"+nt+")").replace(/<comment>/g,"(?:"+rt+")")}var it=at(/\((?:[^()'"@/]|<str>|<comment>|<self>)*\)/.source,2),ot=at(/\[(?:[^\[\]'"@/]|<str>|<comment>|<self>)*\]/.source,2),ct=at(/\{(?:[^{}'"@/]|<str>|<comment>|<self>)*\}/.source,2),At=at(/<(?:[^<>'"@/]|<str>|<comment>|<self>)*>/.source,2),Rt=/(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?/.source,qt=/(?!\d)[^\s>\/=$<%]+/.source+Rt+/\s*\/?>/.source,Ft=/\B@?/.source+"(?:"+/<([a-zA-Z][\w:]*)/.source+Rt+/\s*>/.source+"(?:"+(/[^<]/.source+"|"+/<\/?(?!\1\b)/.source+qt+"|"+at(/<\1/.source+Rt+/\s*>/.source+"(?:"+(/[^<]/.source+"|"+/<\/?(?!\1\b)/.source+qt+"|<self>")+")*"+/<\/\1\s*>/.source,2))+")*"+/<\/\1\s*>/.source+"|"+/</.source+qt+")";tt.languages.cshtml=tt.languages.extend("markup",{});var Ut=tt.languages.insertBefore("csharp","string",{html:{pattern:RegExp(Ft),greedy:!0,inside:tt.languages.cshtml}},{csharp:tt.languages.extend("csharp",{})}),Ht={pattern:/\S[\s\S]*/,alias:"language-csharp",inside:Ut};tt.languages.insertBefore("cshtml","prolog",{"razor-comment":{pattern:/@\*[\s\S]*?\*@/,greedy:!0,alias:"comment"},block:{pattern:RegExp(/(^|[^@])@/.source+"(?:"+[ct,/(?:code|functions)\s*/.source+ct,/(?:for|foreach|lock|switch|using|while)\s*/.source+it+/\s*/.source+ct,/do\s*/.source+ct+/\s*while\s*/.source+it+/(?:\s*;)?/.source,/try\s*/.source+ct+/\s*catch\s*/.source+it+/\s*/.source+ct+/\s*finally\s*/.source+ct,/if\s*/.source+it+/\s*/.source+ct+"(?:"+/\s*else/.source+"(?:"+/\s+if\s*/.source+it+")?"+/\s*/.source+ct+")*"].join("|")+")"),lookbehind:!0,greedy:!0,inside:{keyword:/^@\w*/,csharp:Ht}},directive:{pattern:/^([ \t]*)@(?:addTagHelper|attribute|implements|inherits|inject|layout|model|namespace|page|preservewhitespace|removeTagHelper|section|tagHelperPrefix|using)(?=\s).*/m,lookbehind:!0,greedy:!0,inside:{keyword:/^@\w+/,csharp:Ht}},value:{pattern:RegExp(/(^|[^@])@/.source+/(?:await\b\s*)?/.source+"(?:"+/\w+\b/.source+"|"+it+")(?:"+/[?!]?\.\w+\b/.source+"|"+it+"|"+ot+"|"+At+it+")*"),lookbehind:!0,greedy:!0,alias:"variable",inside:{keyword:/^@/,csharp:Ht}},"delegate-operator":{pattern:/(^|[^@])@(?=<)/,lookbehind:!0,alias:"operator"}}),tt.languages.razor=tt.languages.cshtml}(Ye)}return cshtml_1}var csp_1,hasRequiredCsp;function requireCsp(){if(hasRequiredCsp)return csp_1;hasRequiredCsp=1,csp_1=e,e.displayName="csp",e.aliases=[];function e(t){(function(Ye){function tt(rt){return RegExp(/([ \t])/.source+"(?:"+rt+")"+/(?=[\s;]|$)/.source,"i")}Ye.languages.csp={directive:{pattern:/(^|[\s;])(?:base-uri|block-all-mixed-content|(?:child|connect|default|font|frame|img|manifest|media|object|prefetch|script|style|worker)-src|disown-opener|form-action|frame-(?:ancestors|options)|input-protection(?:-(?:clip|selectors))?|navigate-to|plugin-types|policy-uri|referrer|reflected-xss|report-(?:to|uri)|require-sri-for|sandbox|(?:script|style)-src-(?:attr|elem)|upgrade-insecure-requests)(?=[\s;]|$)/i,lookbehind:!0,alias:"property"},scheme:{pattern:tt(/[a-z][a-z0-9.+-]*:/.source),lookbehind:!0},none:{pattern:tt(/'none'/.source),lookbehind:!0,alias:"keyword"},nonce:{pattern:tt(/'nonce-[-+/\w=]+'/.source),lookbehind:!0,alias:"number"},hash:{pattern:tt(/'sha(?:256|384|512)-[-+/\w=]+'/.source),lookbehind:!0,alias:"number"},host:{pattern:tt(/[a-z][a-z0-9.+-]*:\/\/[^\s;,']*/.source+"|"+/\*[^\s;,']*/.source+"|"+/[a-z0-9-]+(?:\.[a-z0-9-]+)+(?::[\d*]+)?(?:\/[^\s;,']*)?/.source),lookbehind:!0,alias:"url",inside:{important:/\*/}},keyword:[{pattern:tt(/'unsafe-[a-z-]+'/.source),lookbehind:!0,alias:"unsafe"},{pattern:tt(/'[a-z-]+'/.source),lookbehind:!0,alias:"safe"}],punctuation:/;/}})(t)}return csp_1}var cssExtras_1,hasRequiredCssExtras;function requireCssExtras(){if(hasRequiredCssExtras)return cssExtras_1;hasRequiredCssExtras=1,cssExtras_1=e,e.displayName="cssExtras",e.aliases=[];function e(t){(function(Ye){var tt=/("|')(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,rt;Ye.languages.css.selector={pattern:Ye.languages.css.selector.pattern,lookbehind:!0,inside:rt={"pseudo-element":/:(?:after|before|first-letter|first-line|selection)|::[-\w]+/,"pseudo-class":/:[-\w]+/,class:/\.[-\w]+/,id:/#[-\w]+/,attribute:{pattern:RegExp(`\\[(?:[^[\\]"']|`+tt.source+")*\\]"),greedy:!0,inside:{punctuation:/^\[|\]$/,"case-sensitivity":{pattern:/(\s)[si]$/i,lookbehind:!0,alias:"keyword"},namespace:{pattern:/^(\s*)(?:(?!\s)[-*\w\xA0-\uFFFF])*\|(?!=)/,lookbehind:!0,inside:{punctuation:/\|$/}},"attr-name":{pattern:/^(\s*)(?:(?!\s)[-\w\xA0-\uFFFF])+/,lookbehind:!0},"attr-value":[tt,{pattern:/(=\s*)(?:(?!\s)[-\w\xA0-\uFFFF])+(?=\s*$)/,lookbehind:!0}],operator:/[|~*^$]?=/}},"n-th":[{pattern:/(\(\s*)[+-]?\d*[\dn](?:\s*[+-]\s*\d+)?(?=\s*\))/,lookbehind:!0,inside:{number:/[\dn]+/,operator:/[+-]/}},{pattern:/(\(\s*)(?:even|odd)(?=\s*\))/i,lookbehind:!0}],combinator:/>|\+|~|\|\|/,punctuation:/[(),]/}},Ye.languages.css.atrule.inside["selector-function-argument"].inside=rt,Ye.languages.insertBefore("css","property",{variable:{pattern:/(^|[^-\w\xA0-\uFFFF])--(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*/i,lookbehind:!0}});var nt={pattern:/(\b\d+)(?:%|[a-z]+(?![\w-]))/,lookbehind:!0},at={pattern:/(^|[^\w.-])-?(?:\d+(?:\.\d+)?|\.\d+)/,lookbehind:!0};Ye.languages.insertBefore("css","function",{operator:{pattern:/(\s)[+\-*\/](?=\s)/,lookbehind:!0},hexcode:{pattern:/\B#[\da-f]{3,8}\b/i,alias:"color"},color:[{pattern:/(^|[^\w-])(?:AliceBlue|AntiqueWhite|Aqua|Aquamarine|Azure|Beige|Bisque|Black|BlanchedAlmond|Blue|BlueViolet|Brown|BurlyWood|CadetBlue|Chartreuse|Chocolate|Coral|CornflowerBlue|Cornsilk|Crimson|Cyan|DarkBlue|DarkCyan|DarkGoldenRod|DarkGr[ae]y|DarkGreen|DarkKhaki|DarkMagenta|DarkOliveGreen|DarkOrange|DarkOrchid|DarkRed|DarkSalmon|DarkSeaGreen|DarkSlateBlue|DarkSlateGr[ae]y|DarkTurquoise|DarkViolet|DeepPink|DeepSkyBlue|DimGr[ae]y|DodgerBlue|FireBrick|FloralWhite|ForestGreen|Fuchsia|Gainsboro|GhostWhite|Gold|GoldenRod|Gr[ae]y|Green|GreenYellow|HoneyDew|HotPink|IndianRed|Indigo|Ivory|Khaki|Lavender|LavenderBlush|LawnGreen|LemonChiffon|LightBlue|LightCoral|LightCyan|LightGoldenRodYellow|LightGr[ae]y|LightGreen|LightPink|LightSalmon|LightSeaGreen|LightSkyBlue|LightSlateGr[ae]y|LightSteelBlue|LightYellow|Lime|LimeGreen|Linen|Magenta|Maroon|MediumAquaMarine|MediumBlue|MediumOrchid|MediumPurple|MediumSeaGreen|MediumSlateBlue|MediumSpringGreen|MediumTurquoise|MediumVioletRed|MidnightBlue|MintCream|MistyRose|Moccasin|NavajoWhite|Navy|OldLace|Olive|OliveDrab|Orange|OrangeRed|Orchid|PaleGoldenRod|PaleGreen|PaleTurquoise|PaleVioletRed|PapayaWhip|PeachPuff|Peru|Pink|Plum|PowderBlue|Purple|Red|RosyBrown|RoyalBlue|SaddleBrown|Salmon|SandyBrown|SeaGreen|SeaShell|Sienna|Silver|SkyBlue|SlateBlue|SlateGr[ae]y|Snow|SpringGreen|SteelBlue|Tan|Teal|Thistle|Tomato|Transparent|Turquoise|Violet|Wheat|White|WhiteSmoke|Yellow|YellowGreen)(?![\w-])/i,lookbehind:!0},{pattern:/\b(?:hsl|rgb)\(\s*\d{1,3}\s*,\s*\d{1,3}%?\s*,\s*\d{1,3}%?\s*\)\B|\b(?:hsl|rgb)a\(\s*\d{1,3}\s*,\s*\d{1,3}%?\s*,\s*\d{1,3}%?\s*,\s*(?:0|0?\.\d+|1)\s*\)\B/i,inside:{unit:nt,number:at,function:/[\w-]+(?=\()/,punctuation:/[(),]/}}],entity:/\\[\da-f]{1,8}/i,unit:nt,number:at})})(t)}return cssExtras_1}var csv_1,hasRequiredCsv;function requireCsv(){if(hasRequiredCsv)return csv_1;hasRequiredCsv=1,csv_1=e,e.displayName="csv",e.aliases=[];function e(t){t.languages.csv={value:/[^\r\n,"]+|"(?:[^"]|"")*"(?!")/,punctuation:/,/}}return csv_1}var cypher_1,hasRequiredCypher;function requireCypher(){if(hasRequiredCypher)return cypher_1;hasRequiredCypher=1,cypher_1=e,e.displayName="cypher",e.aliases=[];function e(t){t.languages.cypher={comment:/\/\/.*/,string:{pattern:/"(?:[^"\\\r\n]|\\.)*"|'(?:[^'\\\r\n]|\\.)*'/,greedy:!0},"class-name":{pattern:/(:\s*)(?:\w+|`(?:[^`\\\r\n])*`)(?=\s*[{):])/,lookbehind:!0,greedy:!0},relationship:{pattern:/(-\[\s*(?:\w+\s*|`(?:[^`\\\r\n])*`\s*)?:\s*|\|\s*:\s*)(?:\w+|`(?:[^`\\\r\n])*`)/,lookbehind:!0,greedy:!0,alias:"property"},identifier:{pattern:/`(?:[^`\\\r\n])*`/,greedy:!0},variable:/\$\w+/,keyword:/\b(?:ADD|ALL|AND|AS|ASC|ASCENDING|ASSERT|BY|CALL|CASE|COMMIT|CONSTRAINT|CONTAINS|CREATE|CSV|DELETE|DESC|DESCENDING|DETACH|DISTINCT|DO|DROP|ELSE|END|ENDS|EXISTS|FOR|FOREACH|IN|INDEX|IS|JOIN|KEY|LIMIT|LOAD|MANDATORY|MATCH|MERGE|NODE|NOT|OF|ON|OPTIONAL|OR|ORDER(?=\s+BY)|PERIODIC|REMOVE|REQUIRE|RETURN|SCALAR|SCAN|SET|SKIP|START|STARTS|THEN|UNION|UNIQUE|UNWIND|USING|WHEN|WHERE|WITH|XOR|YIELD)\b/i,function:/\b\w+\b(?=\s*\()/,boolean:/\b(?:false|null|true)\b/i,number:/\b(?:0x[\da-fA-F]+|\d+(?:\.\d+)?(?:[eE][+-]?\d+)?)\b/,operator:/:|<--?|--?>?|<>|=~?|[<>]=?|[+*/%^|]|\.\.\.?/,punctuation:/[()[\]{},;.]/}}return cypher_1}var d_1,hasRequiredD;function requireD(){if(hasRequiredD)return d_1;hasRequiredD=1,d_1=e,e.displayName="d",e.aliases=[];function e(t){t.languages.d=t.languages.extend("clike",{comment:[{pattern:/^\s*#!.+/,greedy:!0},{pattern:RegExp(/(^|[^\\])/.source+"(?:"+[/\/\+(?:\/\+(?:[^+]|\+(?!\/))*\+\/|(?!\/\+)[\s\S])*?\+\//.source,/\/\/.*/.source,/\/\*[\s\S]*?\*\//.source].join("|")+")"),lookbehind:!0,greedy:!0}],string:[{pattern:RegExp([/\b[rx]"(?:\\[\s\S]|[^\\"])*"[cwd]?/.source,/\bq"(?:\[[\s\S]*?\]|\([\s\S]*?\)|<[\s\S]*?>|\{[\s\S]*?\})"/.source,/\bq"((?!\d)\w+)$[\s\S]*?^\1"/.source,/\bq"(.)[\s\S]*?\2"/.source,/(["`])(?:\\[\s\S]|(?!\3)[^\\])*\3[cwd]?/.source].join("|"),"m"),greedy:!0},{pattern:/\bq\{(?:\{[^{}]*\}|[^{}])*\}/,greedy:!0,alias:"token-string"}],keyword:/\$|\b(?:__(?:(?:DATE|EOF|FILE|FUNCTION|LINE|MODULE|PRETTY_FUNCTION|TIMESTAMP|TIME|VENDOR|VERSION)__|gshared|parameters|traits|vector)|abstract|alias|align|asm|assert|auto|body|bool|break|byte|case|cast|catch|cdouble|cent|cfloat|char|class|const|continue|creal|dchar|debug|default|delegate|delete|deprecated|do|double|dstring|else|enum|export|extern|false|final|finally|float|for|foreach|foreach_reverse|function|goto|idouble|if|ifloat|immutable|import|inout|int|interface|invariant|ireal|lazy|long|macro|mixin|module|new|nothrow|null|out|override|package|pragma|private|protected|ptrdiff_t|public|pure|real|ref|return|scope|shared|short|size_t|static|string|struct|super|switch|synchronized|template|this|throw|true|try|typedef|typeid|typeof|ubyte|ucent|uint|ulong|union|unittest|ushort|version|void|volatile|wchar|while|with|wstring)\b/,number:[/\b0x\.?[a-f\d_]+(?:(?!\.\.)\.[a-f\d_]*)?(?:p[+-]?[a-f\d_]+)?[ulfi]{0,4}/i,{pattern:/((?:\.\.)?)(?:\b0b\.?|\b|\.)\d[\d_]*(?:(?!\.\.)\.[\d_]*)?(?:e[+-]?\d[\d_]*)?[ulfi]{0,4}/i,lookbehind:!0}],operator:/\|[|=]?|&[&=]?|\+[+=]?|-[-=]?|\.?\.\.|=[>=]?|!(?:i[ns]\b|<>?=?|>=?|=)?|\bi[ns]\b|(?:<[<>]?|>>?>?|\^\^|[*\/%^~])=?/}),t.languages.insertBefore("d","string",{char:/'(?:\\(?:\W|\w+)|[^\\])'/}),t.languages.insertBefore("d","keyword",{property:/\B@\w*/}),t.languages.insertBefore("d","function",{register:{pattern:/\b(?:[ABCD][LHX]|E?(?:BP|DI|SI|SP)|[BS]PL|[ECSDGF]S|CR[0234]|[DS]IL|DR[012367]|E[ABCD]X|X?MM[0-7]|R(?:1[0-5]|[89])[BWD]?|R[ABCD]X|R[BS]P|R[DS]I|TR[3-7]|XMM(?:1[0-5]|[89])|YMM(?:1[0-5]|\d))\b|\bST(?:\([0-7]\)|\b)/,alias:"variable"}})}return d_1}var dart_1,hasRequiredDart;function requireDart(){if(hasRequiredDart)return dart_1;hasRequiredDart=1,dart_1=e,e.displayName="dart",e.aliases=[];function e(t){(function(Ye){var tt=[/\b(?:async|sync|yield)\*/,/\b(?:abstract|assert|async|await|break|case|catch|class|const|continue|covariant|default|deferred|do|dynamic|else|enum|export|extends|extension|external|factory|final|finally|for|get|hide|if|implements|import|in|interface|library|mixin|new|null|on|operator|part|rethrow|return|set|show|static|super|switch|sync|this|throw|try|typedef|var|void|while|with|yield)\b/],rt=/(^|[^\w.])(?:[a-z]\w*\s*\.\s*)*(?:[A-Z]\w*\s*\.\s*)*/.source,nt={pattern:RegExp(rt+/[A-Z](?:[\d_A-Z]*[a-z]\w*)?\b/.source),lookbehind:!0,inside:{namespace:{pattern:/^[a-z]\w*(?:\s*\.\s*[a-z]\w*)*(?:\s*\.)?/,inside:{punctuation:/\./}}}};Ye.languages.dart=Ye.languages.extend("clike",{"class-name":[nt,{pattern:RegExp(rt+/[A-Z]\w*(?=\s+\w+\s*[;,=()])/.source),lookbehind:!0,inside:nt.inside}],keyword:tt,operator:/\bis!|\b(?:as|is)\b|\+\+|--|&&|\|\||<<=?|>>=?|~(?:\/=?)?|[+\-*\/%&^|=!<>]=?|\?/}),Ye.languages.insertBefore("dart","string",{"string-literal":{pattern:/r?(?:("""|''')[\s\S]*?\1|(["'])(?:\\.|(?!\2)[^\\\r\n])*\2(?!\2))/,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$(?:\w+|\{(?:[^{}]|\{[^{}]*\})*\})/,lookbehind:!0,inside:{punctuation:/^\$\{?|\}$/,expression:{pattern:/[\s\S]+/,inside:Ye.languages.dart}}},string:/[\s\S]+/}},string:void 0}),Ye.languages.insertBefore("dart","class-name",{metadata:{pattern:/@\w+/,alias:"function"}}),Ye.languages.insertBefore("dart","class-name",{generics:{pattern:/<(?:[\w\s,.&?]|<(?:[\w\s,.&?]|<(?:[\w\s,.&?]|<[\w\s,.&?]*>)*>)*>)*>/,inside:{"class-name":nt,keyword:tt,punctuation:/[<>(),.:]/,operator:/[?&|]/}}})})(t)}return dart_1}var dataweave_1,hasRequiredDataweave;function requireDataweave(){if(hasRequiredDataweave)return dataweave_1;hasRequiredDataweave=1,dataweave_1=e,e.displayName="dataweave",e.aliases=[];function e(t){(function(Ye){Ye.languages.dataweave={url:/\b[A-Za-z]+:\/\/[\w/:.?=&-]+|\burn:[\w:.?=&-]+/,property:{pattern:/(?:\b\w+#)?(?:"(?:\\.|[^\\"\r\n])*"|\b\w+)(?=\s*[:@])/,greedy:!0},string:{pattern:/(["'`])(?:\\[\s\S]|(?!\1)[^\\])*\1/,greedy:!0},"mime-type":/\b(?:application|audio|image|multipart|text|video)\/[\w+-]+/,date:{pattern:/\|[\w:+-]+\|/,greedy:!0},comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],regex:{pattern:/\/(?:[^\\\/\r\n]|\\[^\r\n])+\//,greedy:!0},keyword:/\b(?:and|as|at|case|do|else|fun|if|input|is|match|not|ns|null|or|output|type|unless|update|using|var)\b/,function:/\b[A-Z_]\w*(?=\s*\()/i,number:/-?\b\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i,punctuation:/[{}[\];(),.:@]/,operator:/<<|>>|->|[<>~=]=?|!=|--?-?|\+\+?|!|\?/,boolean:/\b(?:false|true)\b/}})(t)}return dataweave_1}var dax_1,hasRequiredDax;function requireDax(){if(hasRequiredDax)return dax_1;hasRequiredDax=1,dax_1=e,e.displayName="dax",e.aliases=[];function e(t){t.languages.dax={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:--|\/\/).*)/,lookbehind:!0},"data-field":{pattern:/'(?:[^']|'')*'(?!')(?:\[[ \w\xA0-\uFFFF]+\])?|\w+\[[ \w\xA0-\uFFFF]+\]/,alias:"symbol"},measure:{pattern:/\[[ \w\xA0-\uFFFF]+\]/,alias:"constant"},string:{pattern:/"(?:[^"]|"")*"(?!")/,greedy:!0},function:/\b(?:ABS|ACOS|ACOSH|ACOT|ACOTH|ADDCOLUMNS|ADDMISSINGITEMS|ALL|ALLCROSSFILTERED|ALLEXCEPT|ALLNOBLANKROW|ALLSELECTED|AND|APPROXIMATEDISTINCTCOUNT|ASIN|ASINH|ATAN|ATANH|AVERAGE|AVERAGEA|AVERAGEX|BETA\.DIST|BETA\.INV|BLANK|CALCULATE|CALCULATETABLE|CALENDAR|CALENDARAUTO|CEILING|CHISQ\.DIST|CHISQ\.DIST\.RT|CHISQ\.INV|CHISQ\.INV\.RT|CLOSINGBALANCEMONTH|CLOSINGBALANCEQUARTER|CLOSINGBALANCEYEAR|COALESCE|COMBIN|COMBINA|COMBINEVALUES|CONCATENATE|CONCATENATEX|CONFIDENCE\.NORM|CONFIDENCE\.T|CONTAINS|CONTAINSROW|CONTAINSSTRING|CONTAINSSTRINGEXACT|CONVERT|COS|COSH|COT|COTH|COUNT|COUNTA|COUNTAX|COUNTBLANK|COUNTROWS|COUNTX|CROSSFILTER|CROSSJOIN|CURRENCY|CURRENTGROUP|CUSTOMDATA|DATATABLE|DATE|DATEADD|DATEDIFF|DATESBETWEEN|DATESINPERIOD|DATESMTD|DATESQTD|DATESYTD|DATEVALUE|DAY|DEGREES|DETAILROWS|DISTINCT|DISTINCTCOUNT|DISTINCTCOUNTNOBLANK|DIVIDE|EARLIER|EARLIEST|EDATE|ENDOFMONTH|ENDOFQUARTER|ENDOFYEAR|EOMONTH|ERROR|EVEN|EXACT|EXCEPT|EXP|EXPON\.DIST|FACT|FALSE|FILTER|FILTERS|FIND|FIRSTDATE|FIRSTNONBLANK|FIRSTNONBLANKVALUE|FIXED|FLOOR|FORMAT|GCD|GENERATE|GENERATEALL|GENERATESERIES|GEOMEAN|GEOMEANX|GROUPBY|HASONEFILTER|HASONEVALUE|HOUR|IF|IF\.EAGER|IFERROR|IGNORE|INT|INTERSECT|ISBLANK|ISCROSSFILTERED|ISEMPTY|ISERROR|ISEVEN|ISFILTERED|ISINSCOPE|ISLOGICAL|ISNONTEXT|ISNUMBER|ISO\.CEILING|ISODD|ISONORAFTER|ISSELECTEDMEASURE|ISSUBTOTAL|ISTEXT|KEEPFILTERS|KEYWORDMATCH|LASTDATE|LASTNONBLANK|LASTNONBLANKVALUE|LCM|LEFT|LEN|LN|LOG|LOG10|LOOKUPVALUE|LOWER|MAX|MAXA|MAXX|MEDIAN|MEDIANX|MID|MIN|MINA|MINUTE|MINX|MOD|MONTH|MROUND|NATURALINNERJOIN|NATURALLEFTOUTERJOIN|NEXTDAY|NEXTMONTH|NEXTQUARTER|NEXTYEAR|NONVISUAL|NORM\.DIST|NORM\.INV|NORM\.S\.DIST|NORM\.S\.INV|NOT|NOW|ODD|OPENINGBALANCEMONTH|OPENINGBALANCEQUARTER|OPENINGBALANCEYEAR|OR|PARALLELPERIOD|PATH|PATHCONTAINS|PATHITEM|PATHITEMREVERSE|PATHLENGTH|PERCENTILE\.EXC|PERCENTILE\.INC|PERCENTILEX\.EXC|PERCENTILEX\.INC|PERMUT|PI|POISSON\.DIST|POWER|PREVIOUSDAY|PREVIOUSMONTH|PREVIOUSQUARTER|PREVIOUSYEAR|PRODUCT|PRODUCTX|QUARTER|QUOTIENT|RADIANS|RAND|RANDBETWEEN|RANK\.EQ|RANKX|RELATED|RELATEDTABLE|REMOVEFILTERS|REPLACE|REPT|RIGHT|ROLLUP|ROLLUPADDISSUBTOTAL|ROLLUPGROUP|ROLLUPISSUBTOTAL|ROUND|ROUNDDOWN|ROUNDUP|ROW|SAMEPERIODLASTYEAR|SAMPLE|SEARCH|SECOND|SELECTCOLUMNS|SELECTEDMEASURE|SELECTEDMEASUREFORMATSTRING|SELECTEDMEASURENAME|SELECTEDVALUE|SIGN|SIN|SINH|SQRT|SQRTPI|STARTOFMONTH|STARTOFQUARTER|STARTOFYEAR|STDEV\.P|STDEV\.S|STDEVX\.P|STDEVX\.S|SUBSTITUTE|SUBSTITUTEWITHINDEX|SUM|SUMMARIZE|SUMMARIZECOLUMNS|SUMX|SWITCH|T\.DIST|T\.DIST\.2T|T\.DIST\.RT|T\.INV|T\.INV\.2T|TAN|TANH|TIME|TIMEVALUE|TODAY|TOPN|TOPNPERLEVEL|TOPNSKIP|TOTALMTD|TOTALQTD|TOTALYTD|TREATAS|TRIM|TRUE|TRUNC|UNICHAR|UNICODE|UNION|UPPER|USERELATIONSHIP|USERNAME|USEROBJECTID|USERPRINCIPALNAME|UTCNOW|UTCTODAY|VALUE|VALUES|VAR\.P|VAR\.S|VARX\.P|VARX\.S|WEEKDAY|WEEKNUM|XIRR|XNPV|YEAR|YEARFRAC)(?=\s*\()/i,keyword:/\b(?:DEFINE|EVALUATE|MEASURE|ORDER\s+BY|RETURN|VAR|START\s+AT|ASC|DESC)\b/i,boolean:{pattern:/\b(?:FALSE|NULL|TRUE)\b/i,alias:"constant"},number:/\b\d+(?:\.\d*)?|\B\.\d+\b/,operator:/:=|[-+*\/=^]|&&?|\|\||<(?:=>?|<|>)?|>[>=]?|\b(?:IN|NOT)\b/i,punctuation:/[;\[\](){}`,.]/}}return dax_1}var dhall_1,hasRequiredDhall;function requireDhall(){if(hasRequiredDhall)return dhall_1;hasRequiredDhall=1,dhall_1=e,e.displayName="dhall",e.aliases=[];function e(t){t.languages.dhall={comment:/--.*|\{-(?:[^-{]|-(?!\})|\{(?!-)|\{-(?:[^-{]|-(?!\})|\{(?!-))*-\})*-\}/,string:{pattern:/"(?:[^"\\]|\\.)*"|''(?:[^']|'(?!')|'''|''\$\{)*''(?!'|\$)/,greedy:!0,inside:{interpolation:{pattern:/\$\{[^{}]*\}/,inside:{expression:{pattern:/(^\$\{)[\s\S]+(?=\}$)/,lookbehind:!0,alias:"language-dhall",inside:null},punctuation:/\$\{|\}/}}}},label:{pattern:/`[^`]*`/,greedy:!0},url:{pattern:/\bhttps?:\/\/[\w.:%!$&'*+;=@~-]+(?:\/[\w.:%!$&'*+;=@~-]*)*(?:\?[/?\w.:%!$&'*+;=@~-]*)?/,greedy:!0},env:{pattern:/\benv:(?:(?!\d)\w+|"(?:[^"\\=]|\\.)*")/,greedy:!0,inside:{function:/^env/,operator:/^:/,variable:/[\s\S]+/}},hash:{pattern:/\bsha256:[\da-fA-F]{64}\b/,inside:{function:/sha256/,operator:/:/,number:/[\da-fA-F]{64}/}},keyword:/\b(?:as|assert|else|forall|if|in|let|merge|missing|then|toMap|using|with)\b|\u2200/,builtin:/\b(?:None|Some)\b/,boolean:/\b(?:False|True)\b/,number:/\bNaN\b|-?\bInfinity\b|[+-]?\b(?:0x[\da-fA-F]+|\d+(?:\.\d+)?(?:e[+-]?\d+)?)\b/,operator:/\/\\|\/\/\\\\|&&|\|\||===|[!=]=|\/\/|->|\+\+|::|[+*#@=:?<>|\\\u2227\u2a53\u2261\u2afd\u03bb\u2192]/,punctuation:/\.\.|[{}\[\](),./]/,"class-name":/\b[A-Z]\w*\b/},t.languages.dhall.string.inside.interpolation.inside.expression.inside=t.languages.dhall}return dhall_1}var diff_1,hasRequiredDiff;function requireDiff(){if(hasRequiredDiff)return diff_1;hasRequiredDiff=1,diff_1=e,e.displayName="diff",e.aliases=[];function e(t){(function(Ye){Ye.languages.diff={coord:[/^(?:\*{3}|-{3}|\+{3}).*$/m,/^@@.*@@$/m,/^\d.*$/m]};var tt={"deleted-sign":"-","deleted-arrow":"<","inserted-sign":"+","inserted-arrow":">",unchanged:" ",diff:"!"};Object.keys(tt).forEach(function(rt){var nt=tt[rt],at=[];/^\w+$/.test(rt)||at.push(/\w+/.exec(rt)[0]),rt==="diff"&&at.push("bold"),Ye.languages.diff[rt]={pattern:RegExp("^(?:["+nt+`].*(?:\r
812
812
  ?|
813
813
  |(?![\\s\\S])))+`,"m"),alias:at,inside:{line:{pattern:/(.)(?=[\s\S]).*(?:\r\n?|\n)?/,lookbehind:!0},prefix:{pattern:/[\s\S]/,alias:/\w+/.exec(rt)[0]}}}}),Object.defineProperty(Ye.languages.diff,"PREFIXES",{value:tt})})(t)}return diff_1}var markupTemplating_1,hasRequiredMarkupTemplating;function requireMarkupTemplating(){if(hasRequiredMarkupTemplating)return markupTemplating_1;hasRequiredMarkupTemplating=1,markupTemplating_1=e,e.displayName="markupTemplating",e.aliases=[];function e(t){(function(Ye){function tt(rt,nt){return"___"+rt.toUpperCase()+nt+"___"}Object.defineProperties(Ye.languages["markup-templating"]={},{buildPlaceholders:{value:function(rt,nt,at,it){if(rt.language===nt){var ot=rt.tokenStack=[];rt.code=rt.code.replace(at,function(ct){if(typeof it=="function"&&!it(ct))return ct;for(var At=ot.length,Rt;rt.code.indexOf(Rt=tt(nt,At))!==-1;)++At;return ot[At]=ct,Rt}),rt.grammar=Ye.languages.markup}}},tokenizePlaceholders:{value:function(rt,nt){if(rt.language!==nt||!rt.tokenStack)return;rt.grammar=Ye.languages[nt];var at=0,it=Object.keys(rt.tokenStack);function ot(ct){for(var At=0;At<ct.length&&!(at>=it.length);At++){var Rt=ct[At];if(typeof Rt=="string"||Rt.content&&typeof Rt.content=="string"){var qt=it[at],Ft=rt.tokenStack[qt],Ut=typeof Rt=="string"?Rt:Rt.content,Ht=tt(nt,qt),zt=Ut.indexOf(Ht);if(zt>-1){++at;var Yt=Ut.substring(0,zt),Gt=new Ye.Token(nt,Ye.tokenize(Ft,rt.grammar),"language-"+nt,Ft),Vt=Ut.substring(zt+Ht.length),Zt=[];Yt&&Zt.push.apply(Zt,ot([Yt])),Zt.push(Gt),Vt&&Zt.push.apply(Zt,ot([Vt])),typeof Rt=="string"?ct.splice.apply(ct,[At,1].concat(Zt)):Rt.content=Zt}}else Rt.content&&ot(Rt.content)}return ct}ot(rt.tokens)}}})})(t)}return markupTemplating_1}var django_1,hasRequiredDjango;function requireDjango(){if(hasRequiredDjango)return django_1;hasRequiredDjango=1;var e=requireMarkupTemplating();django_1=t,t.displayName="django",t.aliases=["jinja2"];function t(Ye){Ye.register(e),function(tt){tt.languages.django={comment:/^\{#[\s\S]*?#\}$/,tag:{pattern:/(^\{%[+-]?\s*)\w+/,lookbehind:!0,alias:"keyword"},delimiter:{pattern:/^\{[{%][+-]?|[+-]?[}%]\}$/,alias:"punctuation"},string:{pattern:/("|')(?:\\.|(?!\1)[^\\\r\n])*\1/,greedy:!0},filter:{pattern:/(\|)\w+/,lookbehind:!0,alias:"function"},test:{pattern:/(\bis\s+(?:not\s+)?)(?!not\b)\w+/,lookbehind:!0,alias:"function"},function:/\b[a-z_]\w+(?=\s*\()/i,keyword:/\b(?:and|as|by|else|for|if|import|in|is|loop|not|or|recursive|with|without)\b/,operator:/[-+%=]=?|!=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,number:/\b\d+(?:\.\d+)?\b/,boolean:/[Ff]alse|[Nn]one|[Tt]rue/,variable:/\b\w+\b/,punctuation:/[{}[\](),.:;]/};var rt=/\{\{[\s\S]*?\}\}|\{%[\s\S]*?%\}|\{#[\s\S]*?#\}/g,nt=tt.languages["markup-templating"];tt.hooks.add("before-tokenize",function(at){nt.buildPlaceholders(at,"django",rt)}),tt.hooks.add("after-tokenize",function(at){nt.tokenizePlaceholders(at,"django")}),tt.languages.jinja2=tt.languages.django,tt.hooks.add("before-tokenize",function(at){nt.buildPlaceholders(at,"jinja2",rt)}),tt.hooks.add("after-tokenize",function(at){nt.tokenizePlaceholders(at,"jinja2")})}(Ye)}return django_1}var dnsZoneFile_1,hasRequiredDnsZoneFile;function requireDnsZoneFile(){if(hasRequiredDnsZoneFile)return dnsZoneFile_1;hasRequiredDnsZoneFile=1,dnsZoneFile_1=e,e.displayName="dnsZoneFile",e.aliases=[];function e(t){t.languages["dns-zone-file"]={comment:/;.*/,string:{pattern:/"(?:\\.|[^"\\\r\n])*"/,greedy:!0},variable:[{pattern:/(^\$ORIGIN[ \t]+)\S+/m,lookbehind:!0},{pattern:/(^|\s)@(?=\s|$)/,lookbehind:!0}],keyword:/^\$(?:INCLUDE|ORIGIN|TTL)(?=\s|$)/m,class:{pattern:/(^|\s)(?:CH|CS|HS|IN)(?=\s|$)/,lookbehind:!0,alias:"keyword"},type:{pattern:/(^|\s)(?:A|A6|AAAA|AFSDB|APL|ATMA|CAA|CDNSKEY|CDS|CERT|CNAME|DHCID|DLV|DNAME|DNSKEY|DS|EID|GID|GPOS|HINFO|HIP|IPSECKEY|ISDN|KEY|KX|LOC|MAILA|MAILB|MB|MD|MF|MG|MINFO|MR|MX|NAPTR|NB|NBSTAT|NIMLOC|NINFO|NS|NSAP|NSAP-PTR|NSEC|NSEC3|NSEC3PARAM|NULL|NXT|OPENPGPKEY|PTR|PX|RKEY|RP|RRSIG|RT|SIG|SINK|SMIMEA|SOA|SPF|SRV|SSHFP|TA|TKEY|TLSA|TSIG|TXT|UID|UINFO|UNSPEC|URI|WKS|X25)(?=\s|$)/,lookbehind:!0,alias:"keyword"},punctuation:/[()]/},t.languages["dns-zone"]=t.languages["dns-zone-file"]}return dnsZoneFile_1}var docker_1,hasRequiredDocker;function requireDocker(){if(hasRequiredDocker)return docker_1;hasRequiredDocker=1,docker_1=e,e.displayName="docker",e.aliases=["dockerfile"];function e(t){(function(Ye){var tt=/\\[\r\n](?:\s|\\[\r\n]|#.*(?!.))*(?![\s#]|\\[\r\n])/.source,rt=/(?:[ \t]+(?![ \t])(?:<SP_BS>)?|<SP_BS>)/.source.replace(/<SP_BS>/g,function(){return tt}),nt=/"(?:[^"\\\r\n]|\\(?:\r\n|[\s\S]))*"|'(?:[^'\\\r\n]|\\(?:\r\n|[\s\S]))*'/.source,at=/--[\w-]+=(?:<STR>|(?!["'])(?:[^\s\\]|\\.)+)/.source.replace(/<STR>/g,function(){return nt}),it={pattern:RegExp(nt),greedy:!0},ot={pattern:/(^[ \t]*)#.*/m,lookbehind:!0,greedy:!0};function ct(At,Rt){return At=At.replace(/<OPT>/g,function(){return at}).replace(/<SP>/g,function(){return rt}),RegExp(At,Rt)}Ye.languages.docker={instruction:{pattern:/(^[ \t]*)(?:ADD|ARG|CMD|COPY|ENTRYPOINT|ENV|EXPOSE|FROM|HEALTHCHECK|LABEL|MAINTAINER|ONBUILD|RUN|SHELL|STOPSIGNAL|USER|VOLUME|WORKDIR)(?=\s)(?:\\.|[^\r\n\\])*(?:\\$(?:\s|#.*$)*(?![\s#])(?:\\.|[^\r\n\\])*)*/im,lookbehind:!0,greedy:!0,inside:{options:{pattern:ct(/(^(?:ONBUILD<SP>)?\w+<SP>)<OPT>(?:<SP><OPT>)*/.source,"i"),lookbehind:!0,greedy:!0,inside:{property:{pattern:/(^|\s)--[\w-]+/,lookbehind:!0},string:[it,{pattern:/(=)(?!["'])(?:[^\s\\]|\\.)+/,lookbehind:!0}],operator:/\\$/m,punctuation:/=/}},keyword:[{pattern:ct(/(^(?:ONBUILD<SP>)?HEALTHCHECK<SP>(?:<OPT><SP>)*)(?:CMD|NONE)\b/.source,"i"),lookbehind:!0,greedy:!0},{pattern:ct(/(^(?:ONBUILD<SP>)?FROM<SP>(?:<OPT><SP>)*(?!--)[^ \t\\]+<SP>)AS/.source,"i"),lookbehind:!0,greedy:!0},{pattern:ct(/(^ONBUILD<SP>)\w+/.source,"i"),lookbehind:!0,greedy:!0},{pattern:/^\w+/,greedy:!0}],comment:ot,string:it,variable:/\$(?:\w+|\{[^{}"'\\]*\})/,operator:/\\$/m}},comment:ot},Ye.languages.dockerfile=Ye.languages.docker})(t)}return docker_1}var dot_1,hasRequiredDot;function requireDot(){if(hasRequiredDot)return dot_1;hasRequiredDot=1,dot_1=e,e.displayName="dot",e.aliases=["gv"];function e(t){(function(Ye){var tt="(?:"+[/[a-zA-Z_\x80-\uFFFF][\w\x80-\uFFFF]*/.source,/-?(?:\.\d+|\d+(?:\.\d*)?)/.source,/"[^"\\]*(?:\\[\s\S][^"\\]*)*"/.source,/<(?:[^<>]|(?!<!--)<(?:[^<>"']|"[^"]*"|'[^']*')+>|<!--(?:[^-]|-(?!->))*-->)*>/.source].join("|")+")",rt={markup:{pattern:/(^<)[\s\S]+(?=>$)/,lookbehind:!0,alias:["language-markup","language-html","language-xml"],inside:Ye.languages.markup}};function nt(at,it){return RegExp(at.replace(/<ID>/g,function(){return tt}),it)}Ye.languages.dot={comment:{pattern:/\/\/.*|\/\*[\s\S]*?\*\/|^#.*/m,greedy:!0},"graph-name":{pattern:nt(/(\b(?:digraph|graph|subgraph)[ \t\r\n]+)<ID>/.source,"i"),lookbehind:!0,greedy:!0,alias:"class-name",inside:rt},"attr-value":{pattern:nt(/(=[ \t\r\n]*)<ID>/.source),lookbehind:!0,greedy:!0,inside:rt},"attr-name":{pattern:nt(/([\[;, \t\r\n])<ID>(?=[ \t\r\n]*=)/.source),lookbehind:!0,greedy:!0,inside:rt},keyword:/\b(?:digraph|edge|graph|node|strict|subgraph)\b/i,"compass-point":{pattern:/(:[ \t\r\n]*)(?:[ewc_]|[ns][ew]?)(?![\w\x80-\uFFFF])/,lookbehind:!0,alias:"builtin"},node:{pattern:nt(/(^|[^-.\w\x80-\uFFFF\\])<ID>/.source),lookbehind:!0,greedy:!0,inside:rt},operator:/[=:]|-[->]/,punctuation:/[\[\]{};,]/},Ye.languages.gv=Ye.languages.dot})(t)}return dot_1}var ebnf_1,hasRequiredEbnf;function requireEbnf(){if(hasRequiredEbnf)return ebnf_1;hasRequiredEbnf=1,ebnf_1=e,e.displayName="ebnf",e.aliases=[];function e(t){t.languages.ebnf={comment:/\(\*[\s\S]*?\*\)/,string:{pattern:/"[^"\r\n]*"|'[^'\r\n]*'/,greedy:!0},special:{pattern:/\?[^?\r\n]*\?/,greedy:!0,alias:"class-name"},definition:{pattern:/^([\t ]*)[a-z]\w*(?:[ \t]+[a-z]\w*)*(?=\s*=)/im,lookbehind:!0,alias:["rule","keyword"]},rule:/\b[a-z]\w*(?:[ \t]+[a-z]\w*)*\b/i,punctuation:/\([:/]|[:/]\)|[.,;()[\]{}]/,operator:/[-=|*/!]/}}return ebnf_1}var editorconfig_1,hasRequiredEditorconfig;function requireEditorconfig(){if(hasRequiredEditorconfig)return editorconfig_1;hasRequiredEditorconfig=1,editorconfig_1=e,e.displayName="editorconfig",e.aliases=[];function e(t){t.languages.editorconfig={comment:/[;#].*/,section:{pattern:/(^[ \t]*)\[.+\]/m,lookbehind:!0,alias:"selector",inside:{regex:/\\\\[\[\]{},!?.*]/,operator:/[!?]|\.\.|\*{1,2}/,punctuation:/[\[\]{},]/}},key:{pattern:/(^[ \t]*)[^\s=]+(?=[ \t]*=)/m,lookbehind:!0,alias:"attr-name"},value:{pattern:/=.*/,alias:"attr-value",inside:{punctuation:/^=/}}}}return editorconfig_1}var eiffel_1,hasRequiredEiffel;function requireEiffel(){if(hasRequiredEiffel)return eiffel_1;hasRequiredEiffel=1,eiffel_1=e,e.displayName="eiffel",e.aliases=[];function e(t){t.languages.eiffel={comment:/--.*/,string:[{pattern:/"([^[]*)\[[\s\S]*?\]\1"/,greedy:!0},{pattern:/"([^{]*)\{[\s\S]*?\}\1"/,greedy:!0},{pattern:/"(?:%(?:(?!\n)\s)*\n\s*%|%\S|[^%"\r\n])*"/,greedy:!0}],char:/'(?:%.|[^%'\r\n])+'/,keyword:/\b(?:across|agent|alias|all|and|as|assign|attached|attribute|check|class|convert|create|Current|debug|deferred|detachable|do|else|elseif|end|ensure|expanded|export|external|feature|from|frozen|if|implies|inherit|inspect|invariant|like|local|loop|not|note|obsolete|old|once|or|Precursor|redefine|rename|require|rescue|Result|retry|select|separate|some|then|undefine|until|variant|Void|when|xor)\b/i,boolean:/\b(?:False|True)\b/i,"class-name":/\b[A-Z][\dA-Z_]*\b/,number:[/\b0[xcb][\da-f](?:_*[\da-f])*\b/i,/(?:\b\d(?:_*\d)*)?\.(?:(?:\d(?:_*\d)*)?e[+-]?)?\d(?:_*\d)*\b|\b\d(?:_*\d)*\b\.?/i],punctuation:/:=|<<|>>|\(\||\|\)|->|\.(?=\w)|[{}[\];(),:?]/,operator:/\\\\|\|\.\.\||\.\.|\/[~\/=]?|[><]=?|[-+*^=~]/}}return eiffel_1}var ejs_1,hasRequiredEjs;function requireEjs(){if(hasRequiredEjs)return ejs_1;hasRequiredEjs=1;var e=requireMarkupTemplating();ejs_1=t,t.displayName="ejs",t.aliases=["eta"];function t(Ye){Ye.register(e),function(tt){tt.languages.ejs={delimiter:{pattern:/^<%[-_=]?|[-_]?%>$/,alias:"punctuation"},comment:/^#[\s\S]*/,"language-javascript":{pattern:/[\s\S]+/,inside:tt.languages.javascript}},tt.hooks.add("before-tokenize",function(rt){var nt=/<%(?!%)[\s\S]+?%>/g;tt.languages["markup-templating"].buildPlaceholders(rt,"ejs",nt)}),tt.hooks.add("after-tokenize",function(rt){tt.languages["markup-templating"].tokenizePlaceholders(rt,"ejs")}),tt.languages.eta=tt.languages.ejs}(Ye)}return ejs_1}var elixir_1,hasRequiredElixir;function requireElixir(){if(hasRequiredElixir)return elixir_1;hasRequiredElixir=1,elixir_1=e,e.displayName="elixir",e.aliases=[];function e(t){t.languages.elixir={doc:{pattern:/@(?:doc|moduledoc)\s+(?:("""|''')[\s\S]*?\1|("|')(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2)/,inside:{attribute:/^@\w+/,string:/['"][\s\S]+/}},comment:{pattern:/#.*/,greedy:!0},regex:{pattern:/~[rR](?:("""|''')(?:\\[\s\S]|(?!\1)[^\\])+\1|([\/|"'])(?:\\.|(?!\2)[^\\\r\n])+\2|\((?:\\.|[^\\)\r\n])+\)|\[(?:\\.|[^\\\]\r\n])+\]|\{(?:\\.|[^\\}\r\n])+\}|<(?:\\.|[^\\>\r\n])+>)[uismxfr]*/,greedy:!0},string:[{pattern:/~[cCsSwW](?:("""|''')(?:\\[\s\S]|(?!\1)[^\\])+\1|([\/|"'])(?:\\.|(?!\2)[^\\\r\n])+\2|\((?:\\.|[^\\)\r\n])+\)|\[(?:\\.|[^\\\]\r\n])+\]|\{(?:\\.|#\{[^}]+\}|#(?!\{)|[^#\\}\r\n])+\}|<(?:\\.|[^\\>\r\n])+>)[csa]?/,greedy:!0,inside:{}},{pattern:/("""|''')[\s\S]*?\1/,greedy:!0,inside:{}},{pattern:/("|')(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0,inside:{}}],atom:{pattern:/(^|[^:]):\w+/,lookbehind:!0,alias:"symbol"},module:{pattern:/\b[A-Z]\w*\b/,alias:"class-name"},"attr-name":/\b\w+\??:(?!:)/,argument:{pattern:/(^|[^&])&\d+/,lookbehind:!0,alias:"variable"},attribute:{pattern:/@\w+/,alias:"variable"},function:/\b[_a-zA-Z]\w*[?!]?(?:(?=\s*(?:\.\s*)?\()|(?=\/\d))/,number:/\b(?:0[box][a-f\d_]+|\d[\d_]*)(?:\.[\d_]+)?(?:e[+-]?[\d_]+)?\b/i,keyword:/\b(?:after|alias|and|case|catch|cond|def(?:callback|delegate|exception|impl|macro|module|n|np|p|protocol|struct)?|do|else|end|fn|for|if|import|not|or|quote|raise|require|rescue|try|unless|unquote|use|when)\b/,boolean:/\b(?:false|nil|true)\b/,operator:[/\bin\b|&&?|\|[|>]?|\\\\|::|\.\.\.?|\+\+?|-[->]?|<[-=>]|>=|!==?|\B!|=(?:==?|[>~])?|[*\/^]/,{pattern:/([^<])<(?!<)/,lookbehind:!0},{pattern:/([^>])>(?!>)/,lookbehind:!0}],punctuation:/<<|>>|[.,%\[\]{}()]/},t.languages.elixir.string.forEach(function(Ye){Ye.inside={interpolation:{pattern:/#\{[^}]+\}/,inside:{delimiter:{pattern:/^#\{|\}$/,alias:"punctuation"},rest:t.languages.elixir}}}})}return elixir_1}var elm_1,hasRequiredElm;function requireElm(){if(hasRequiredElm)return elm_1;hasRequiredElm=1,elm_1=e,e.displayName="elm",e.aliases=[];function e(t){t.languages.elm={comment:/--.*|\{-[\s\S]*?-\}/,char:{pattern:/'(?:[^\\'\r\n]|\\(?:[abfnrtv\\']|\d+|x[0-9a-fA-F]+|u\{[0-9a-fA-F]+\}))'/,greedy:!0},string:[{pattern:/"""[\s\S]*?"""/,greedy:!0},{pattern:/"(?:[^\\"\r\n]|\\.)*"/,greedy:!0}],"import-statement":{pattern:/(^[\t ]*)import\s+[A-Z]\w*(?:\.[A-Z]\w*)*(?:\s+as\s+(?:[A-Z]\w*)(?:\.[A-Z]\w*)*)?(?:\s+exposing\s+)?/m,lookbehind:!0,inside:{keyword:/\b(?:as|exposing|import)\b/}},keyword:/\b(?:alias|as|case|else|exposing|if|in|infixl|infixr|let|module|of|then|type)\b/,builtin:/\b(?:abs|acos|always|asin|atan|atan2|ceiling|clamp|compare|cos|curry|degrees|e|flip|floor|fromPolar|identity|isInfinite|isNaN|logBase|max|min|negate|never|not|pi|radians|rem|round|sin|sqrt|tan|toFloat|toPolar|toString|truncate|turns|uncurry|xor)\b/,number:/\b(?:\d+(?:\.\d+)?(?:e[+-]?\d+)?|0x[0-9a-f]+)\b/i,operator:/\s\.\s|[+\-/*=.$<>:&|^?%#@~!]{2,}|[+\-/*=$<>:&|^?%#@~!]/,hvariable:/\b(?:[A-Z]\w*\.)*[a-z]\w*\b/,constant:/\b(?:[A-Z]\w*\.)*[A-Z]\w*\b/,punctuation:/[{}[\]|(),.:]/}}return elm_1}var erb_1,hasRequiredErb;function requireErb(){if(hasRequiredErb)return erb_1;hasRequiredErb=1;var e=requireRuby(),t=requireMarkupTemplating();erb_1=Ye,Ye.displayName="erb",Ye.aliases=[];function Ye(tt){tt.register(e),tt.register(t),function(rt){rt.languages.erb={delimiter:{pattern:/^(\s*)<%=?|%>(?=\s*$)/,lookbehind:!0,alias:"punctuation"},ruby:{pattern:/\s*\S[\s\S]*/,alias:"language-ruby",inside:rt.languages.ruby}},rt.hooks.add("before-tokenize",function(nt){var at=/<%=?(?:[^\r\n]|[\r\n](?!=begin)|[\r\n]=begin\s(?:[^\r\n]|[\r\n](?!=end))*[\r\n]=end)+?%>/g;rt.languages["markup-templating"].buildPlaceholders(nt,"erb",at)}),rt.hooks.add("after-tokenize",function(nt){rt.languages["markup-templating"].tokenizePlaceholders(nt,"erb")})}(tt)}return erb_1}var erlang_1,hasRequiredErlang;function requireErlang(){if(hasRequiredErlang)return erlang_1;hasRequiredErlang=1,erlang_1=e,e.displayName="erlang",e.aliases=[];function e(t){t.languages.erlang={comment:/%.+/,string:{pattern:/"(?:\\.|[^\\"\r\n])*"/,greedy:!0},"quoted-function":{pattern:/'(?:\\.|[^\\'\r\n])+'(?=\()/,alias:"function"},"quoted-atom":{pattern:/'(?:\\.|[^\\'\r\n])+'/,alias:"atom"},boolean:/\b(?:false|true)\b/,keyword:/\b(?:after|case|catch|end|fun|if|of|receive|try|when)\b/,number:[/\$\\?./,/\b\d+#[a-z0-9]+/i,/(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i],function:/\b[a-z][\w@]*(?=\()/,variable:{pattern:/(^|[^@])(?:\b|\?)[A-Z_][\w@]*/,lookbehind:!0},operator:[/[=\/<>:]=|=[:\/]=|\+\+?|--?|[=*\/!]|\b(?:and|andalso|band|bnot|bor|bsl|bsr|bxor|div|not|or|orelse|rem|xor)\b/,{pattern:/(^|[^<])<(?!<)/,lookbehind:!0},{pattern:/(^|[^>])>(?!>)/,lookbehind:!0}],atom:/\b[a-z][\w@]*/,punctuation:/[()[\]{}:;,.#|]|<<|>>/}}return erlang_1}var lua_1,hasRequiredLua;function requireLua(){if(hasRequiredLua)return lua_1;hasRequiredLua=1,lua_1=e,e.displayName="lua",e.aliases=[];function e(t){t.languages.lua={comment:/^#!.+|--(?:\[(=*)\[[\s\S]*?\]\1\]|.*)/m,string:{pattern:/(["'])(?:(?!\1)[^\\\r\n]|\\z(?:\r\n|\s)|\\(?:\r\n|[^z]))*\1|\[(=*)\[[\s\S]*?\]\2\]/,greedy:!0},number:/\b0x[a-f\d]+(?:\.[a-f\d]*)?(?:p[+-]?\d+)?\b|\b\d+(?:\.\B|(?:\.\d*)?(?:e[+-]?\d+)?\b)|\B\.\d+(?:e[+-]?\d+)?\b/i,keyword:/\b(?:and|break|do|else|elseif|end|false|for|function|goto|if|in|local|nil|not|or|repeat|return|then|true|until|while)\b/,function:/(?!\d)\w+(?=\s*(?:[({]))/,operator:[/[-+*%^&|#]|\/\/?|<[<=]?|>[>=]?|[=~]=?/,{pattern:/(^|[^.])\.\.(?!\.)/,lookbehind:!0}],punctuation:/[\[\](){},;]|\.+|:+/}}return lua_1}var etlua_1,hasRequiredEtlua;function requireEtlua(){if(hasRequiredEtlua)return etlua_1;hasRequiredEtlua=1;var e=requireLua(),t=requireMarkupTemplating();etlua_1=Ye,Ye.displayName="etlua",Ye.aliases=[];function Ye(tt){tt.register(e),tt.register(t),function(rt){rt.languages.etlua={delimiter:{pattern:/^<%[-=]?|-?%>$/,alias:"punctuation"},"language-lua":{pattern:/[\s\S]+/,inside:rt.languages.lua}},rt.hooks.add("before-tokenize",function(nt){var at=/<%[\s\S]+?%>/g;rt.languages["markup-templating"].buildPlaceholders(nt,"etlua",at)}),rt.hooks.add("after-tokenize",function(nt){rt.languages["markup-templating"].tokenizePlaceholders(nt,"etlua")})}(tt)}return etlua_1}var excelFormula_1,hasRequiredExcelFormula;function requireExcelFormula(){if(hasRequiredExcelFormula)return excelFormula_1;hasRequiredExcelFormula=1,excelFormula_1=e,e.displayName="excelFormula",e.aliases=[];function e(t){t.languages["excel-formula"]={comment:{pattern:/(\bN\(\s*)"(?:[^"]|"")*"(?=\s*\))/i,lookbehind:!0,greedy:!0},string:{pattern:/"(?:[^"]|"")*"(?!")/,greedy:!0},reference:{pattern:/(?:'[^']*'|(?:[^\s()[\]{}<>*?"';,$&]*\[[^^\s()[\]{}<>*?"']+\])?\w+)!/,greedy:!0,alias:"string",inside:{operator:/!$/,punctuation:/'/,sheet:{pattern:/[^[\]]+$/,alias:"function"},file:{pattern:/\[[^[\]]+\]$/,inside:{punctuation:/[[\]]/}},path:/[\s\S]+/}},"function-name":{pattern:/\b[A-Z]\w*(?=\()/i,alias:"keyword"},range:{pattern:/\$?\b(?:[A-Z]+\$?\d+:\$?[A-Z]+\$?\d+|[A-Z]+:\$?[A-Z]+|\d+:\$?\d+)\b/i,alias:"property",inside:{operator:/:/,cell:/\$?[A-Z]+\$?\d+/i,column:/\$?[A-Z]+/i,row:/\$?\d+/}},cell:{pattern:/\b[A-Z]+\d+\b|\$[A-Za-z]+\$?\d+\b|\b[A-Za-z]+\$\d+\b/,alias:"property"},number:/(?:\b\d+(?:\.\d+)?|\B\.\d+)(?:e[+-]?\d+)?\b/i,boolean:/\b(?:FALSE|TRUE)\b/i,operator:/[-+*/^%=&,]|<[=>]?|>=?/,punctuation:/[[\]();{}|]/},t.languages.xlsx=t.languages.xls=t.languages["excel-formula"]}return excelFormula_1}var factor_1,hasRequiredFactor;function requireFactor(){if(hasRequiredFactor)return factor_1;hasRequiredFactor=1,factor_1=e,e.displayName="factor",e.aliases=[];function e(t){(function(Ye){var tt={function:/\b(?:BUGS?|FIX(?:MES?)?|NOTES?|TODOS?|XX+|HACKS?|WARN(?:ING)?|\?{2,}|!{2,})\b/},rt={number:/\\[^\s']|%\w/},nt={comment:[{pattern:/(^|\s)(?:! .*|!$)/,lookbehind:!0,inside:tt},{pattern:/(^|\s)\/\*\s[\s\S]*?\*\/(?=\s|$)/,lookbehind:!0,greedy:!0,inside:tt},{pattern:/(^|\s)!\[(={0,6})\[\s[\s\S]*?\]\2\](?=\s|$)/,lookbehind:!0,greedy:!0,inside:tt}],number:[{pattern:/(^|\s)[+-]?\d+(?=\s|$)/,lookbehind:!0},{pattern:/(^|\s)[+-]?0(?:b[01]+|o[0-7]+|d\d+|x[\dA-F]+)(?=\s|$)/i,lookbehind:!0},{pattern:/(^|\s)[+-]?\d+\/\d+\.?(?=\s|$)/,lookbehind:!0},{pattern:/(^|\s)\+?\d+\+\d+\/\d+(?=\s|$)/,lookbehind:!0},{pattern:/(^|\s)-\d+-\d+\/\d+(?=\s|$)/,lookbehind:!0},{pattern:/(^|\s)[+-]?(?:\d*\.\d+|\d+\.\d*|\d+)(?:e[+-]?\d+)?(?=\s|$)/i,lookbehind:!0},{pattern:/(^|\s)NAN:\s+[\da-fA-F]+(?=\s|$)/,lookbehind:!0},{pattern:/(^|\s)[+-]?0(?:b1\.[01]*|o1\.[0-7]*|d1\.\d*|x1\.[\dA-F]*)p\d+(?=\s|$)/i,lookbehind:!0}],regexp:{pattern:/(^|\s)R\/\s(?:\\\S|[^\\/])*\/(?:[idmsr]*|[idmsr]+-[idmsr]+)(?=\s|$)/,lookbehind:!0,alias:"number",inside:{variable:/\\\S/,keyword:/[+?*\[\]^$(){}.|]/,operator:{pattern:/(\/)[idmsr]+(?:-[idmsr]+)?/,lookbehind:!0}}},boolean:{pattern:/(^|\s)[tf](?=\s|$)/,lookbehind:!0},"custom-string":{pattern:/(^|\s)[A-Z0-9\-]+"\s(?:\\\S|[^"\\])*"/,lookbehind:!0,greedy:!0,alias:"string",inside:{number:/\\\S|%\w|\//}},"multiline-string":[{pattern:/(^|\s)STRING:\s+\S+(?:\n|\r\n).*(?:\n|\r\n)\s*;(?=\s|$)/,lookbehind:!0,greedy:!0,alias:"string",inside:{number:rt.number,"semicolon-or-setlocal":{pattern:/([\r\n][ \t]*);(?=\s|$)/,lookbehind:!0,alias:"function"}}},{pattern:/(^|\s)HEREDOC:\s+\S+(?:\n|\r\n).*(?:\n|\r\n)\s*\S+(?=\s|$)/,lookbehind:!0,greedy:!0,alias:"string",inside:rt},{pattern:/(^|\s)\[(={0,6})\[\s[\s\S]*?\]\2\](?=\s|$)/,lookbehind:!0,greedy:!0,alias:"string",inside:rt}],"special-using":{pattern:/(^|\s)USING:(?:\s\S+)*(?=\s+;(?:\s|$))/,lookbehind:!0,alias:"function",inside:{string:{pattern:/(\s)[^:\s]+/,lookbehind:!0}}},"stack-effect-delimiter":[{pattern:/(^|\s)(?:call|eval|execute)?\((?=\s)/,lookbehind:!0,alias:"operator"},{pattern:/(\s)--(?=\s)/,lookbehind:!0,alias:"operator"},{pattern:/(\s)\)(?=\s|$)/,lookbehind:!0,alias:"operator"}],combinators:{pattern:null,lookbehind:!0,alias:"keyword"},"kernel-builtin":{pattern:null,lookbehind:!0,alias:"variable"},"sequences-builtin":{pattern:null,lookbehind:!0,alias:"variable"},"math-builtin":{pattern:null,lookbehind:!0,alias:"variable"},"constructor-word":{pattern:/(^|\s)<(?!=+>|-+>)\S+>(?=\s|$)/,lookbehind:!0,alias:"keyword"},"other-builtin-syntax":{pattern:null,lookbehind:!0,alias:"operator"},"conventionally-named-word":{pattern:/(^|\s)(?!")(?:(?:change|new|set|with)-\S+|\$\S+|>[^>\s]+|[^:>\s]+>|[^>\s]+>[^>\s]+|\+[^+\s]+\+|[^?\s]+\?|\?[^?\s]+|[^>\s]+>>|>>[^>\s]+|[^<\s]+<<|\([^()\s]+\)|[^!\s]+!|[^*\s]\S*\*|[^.\s]\S*\.)(?=\s|$)/,lookbehind:!0,alias:"keyword"},"colon-syntax":{pattern:/(^|\s)(?:[A-Z0-9\-]+#?)?:{1,2}\s+(?:;\S+|(?!;)\S+)(?=\s|$)/,lookbehind:!0,greedy:!0,alias:"function"},"semicolon-or-setlocal":{pattern:/(\s)(?:;|:>)(?=\s|$)/,lookbehind:!0,alias:"function"},"curly-brace-literal-delimiter":[{pattern:/(^|\s)[a-z]*\{(?=\s)/i,lookbehind:!0,alias:"operator"},{pattern:/(\s)\}(?=\s|$)/,lookbehind:!0,alias:"operator"}],"quotation-delimiter":[{pattern:/(^|\s)\[(?=\s)/,lookbehind:!0,alias:"operator"},{pattern:/(\s)\](?=\s|$)/,lookbehind:!0,alias:"operator"}],"normal-word":{pattern:/(^|\s)[^"\s]\S*(?=\s|$)/,lookbehind:!0},string:{pattern:/"(?:\\\S|[^"\\])*"/,greedy:!0,inside:rt}},at=function(At){return(At+"").replace(/([.?*+\^$\[\]\\(){}|\-])/g,"\\$1")},it=function(At){return new RegExp("(^|\\s)(?:"+At.map(at).join("|")+")(?=\\s|$)")},ot={"kernel-builtin":["or","2nipd","4drop","tuck","wrapper","nip","wrapper?","callstack>array","die","dupd","callstack","callstack?","3dup","hashcode","pick","4nip","build",">boolean","nipd","clone","5nip","eq?","?","=","swapd","2over","clear","2dup","get-retainstack","not","tuple?","dup","3nipd","call","-rotd","object","drop","assert=","assert?","-rot","execute","boa","get-callstack","curried?","3drop","pickd","overd","over","roll","3nip","swap","and","2nip","rotd","throw","(clone)","hashcode*","spin","reach","4dup","equal?","get-datastack","assert","2drop","<wrapper>","boolean?","identity-hashcode","identity-tuple?","null","composed?","new","5drop","rot","-roll","xor","identity-tuple","boolean"],"other-builtin-syntax":["=======","recursive","flushable",">>","<<<<<<","M\\","B","PRIVATE>","\\","======","final","inline","delimiter","deprecated","<PRIVATE",">>>>>>","<<<<<<<","parse-complex","malformed-complex","read-only",">>>>>>>","call-next-method","<<","foldable","$","$[","${"],"sequences-builtin":["member-eq?","mismatch","append","assert-sequence=","longer","repetition","clone-like","3sequence","assert-sequence?","last-index-from","reversed","index-from","cut*","pad-tail","join-as","remove-eq!","concat-as","but-last","snip","nths","nth","sequence","longest","slice?","<slice>","remove-nth","tail-slice","empty?","tail*","member?","virtual-sequence?","set-length","drop-prefix","iota","unclip","bounds-error?","unclip-last-slice","non-negative-integer-expected","non-negative-integer-expected?","midpoint@","longer?","?set-nth","?first","rest-slice","prepend-as","prepend","fourth","sift","subseq-start","new-sequence","?last","like","first4","1sequence","reverse","slice","virtual@","repetition?","set-last","index","4sequence","max-length","set-second","immutable-sequence","first2","first3","supremum","unclip-slice","suffix!","insert-nth","tail","3append","short","suffix","concat","flip","immutable?","reverse!","2sequence","sum","delete-all","indices","snip-slice","<iota>","check-slice","sequence?","head","append-as","halves","sequence=","collapse-slice","?second","slice-error?","product","bounds-check?","bounds-check","immutable","virtual-exemplar","harvest","remove","pad-head","last","set-fourth","cartesian-product","remove-eq","shorten","shorter","reversed?","shorter?","shortest","head-slice","pop*","tail-slice*","but-last-slice","iota?","append!","cut-slice","new-resizable","head-slice*","sequence-hashcode","pop","set-nth","?nth","second","join","immutable-sequence?","<reversed>","3append-as","virtual-sequence","subseq?","remove-nth!","length","last-index","lengthen","assert-sequence","copy","move","third","first","tail?","set-first","prefix","bounds-error","<repetition>","exchange","surround","cut","min-length","set-third","push-all","head?","subseq-start-from","delete-slice","rest","sum-lengths","head*","infimum","remove!","glue","slice-error","subseq","push","replace-slice","subseq-as","unclip-last"],"math-builtin":["number=","next-power-of-2","?1+","fp-special?","imaginary-part","float>bits","number?","fp-infinity?","bignum?","fp-snan?","denominator","gcd","*","+","fp-bitwise=","-","u>=","/",">=","bitand","power-of-2?","log2-expects-positive","neg?","<","log2",">","integer?","number","bits>double","2/","zero?","bits>float","float?","shift","ratio?","rect>","even?","ratio","fp-sign","bitnot",">fixnum","complex?","/i","integer>fixnum","/f","sgn",">bignum","next-float","u<","u>","mod","recip","rational",">float","2^","integer","fixnum?","neg","fixnum","sq","bignum",">rect","bit?","fp-qnan?","simple-gcd","complex","<fp-nan>","real",">fraction","double>bits","bitor","rem","fp-nan-payload","real-part","log2-expects-positive?","prev-float","align","unordered?","float","fp-nan?","abs","bitxor","integer>fixnum-strict","u<=","odd?","<=","/mod",">integer","real?","rational?","numerator"]};Object.keys(ot).forEach(function(At){nt[At].pattern=it(ot[At])});var ct=["2bi","while","2tri","bi*","4dip","both?","same?","tri@","curry","prepose","3bi","?if","tri*","2keep","3keep","curried","2keepd","when","2bi*","2tri*","4keep","bi@","keepdd","do","unless*","tri-curry","if*","loop","bi-curry*","when*","2bi@","2tri@","with","2with","either?","bi","until","3dip","3curry","tri-curry*","tri-curry@","bi-curry","keepd","compose","2dip","if","3tri","unless","tuple","keep","2curry","tri","most","while*","dip","composed","bi-curry@","find-last-from","trim-head-slice","map-as","each-from","none?","trim-tail","partition","if-empty","accumulate*","reject!","find-from","accumulate-as","collector-for-as","reject","map","map-sum","accumulate!","2each-from","follow","supremum-by","map!","unless-empty","collector","padding","reduce-index","replicate-as","infimum-by","trim-tail-slice","count","find-index","filter","accumulate*!","reject-as","map-integers","map-find","reduce","selector","interleave","2map","filter-as","binary-reduce","map-index-as","find","produce","filter!","replicate","cartesian-map","cartesian-each","find-index-from","map-find-last","3map-as","3map","find-last","selector-as","2map-as","2map-reduce","accumulate","each","each-index","accumulate*-as","when-empty","all?","collector-as","push-either","new-like","collector-for","2selector","push-if","2all?","map-reduce","3each","any?","trim-slice","2reduce","change-nth","produce-as","2each","trim","trim-head","cartesian-find","map-index","if-zero","each-integer","unless-zero","(find-integer)","when-zero","find-last-integer","(all-integers?)","times","(each-integer)","find-integer","all-integers?","unless-negative","if-positive","when-positive","when-negative","unless-positive","if-negative","case","2cleave","cond>quot","case>quot","3cleave","wrong-values","to-fixed-point","alist>quot","cond","cleave","call-effect","recursive-hashcode","spread","deep-spread>quot","2||","0||","n||","0&&","2&&","3||","1||","1&&","n&&","3&&","smart-unless*","keep-inputs","reduce-outputs","smart-when*","cleave>array","smart-with","smart-apply","smart-if","inputs/outputs","output>sequence-n","map-outputs","map-reduce-outputs","dropping","output>array","smart-map-reduce","smart-2map-reduce","output>array-n","nullary","input<sequence","append-outputs","drop-inputs","inputs","smart-2reduce","drop-outputs","smart-reduce","preserving","smart-when","outputs","append-outputs-as","smart-unless","smart-if*","sum-outputs","input<sequence-unsafe","output>sequence"];nt.combinators.pattern=it(ct),Ye.languages.factor=nt})(t)}return factor_1}var _false,hasRequired_false;function require_false(){if(hasRequired_false)return _false;hasRequired_false=1,_false=e,e.displayName="$false",e.aliases=[];function e(t){(function(Ye){Ye.languages.false={comment:{pattern:/\{[^}]*\}/},string:{pattern:/"[^"]*"/,greedy:!0},"character-code":{pattern:/'(?:[^\r]|\r\n?)/,alias:"number"},"assembler-code":{pattern:/\d+`/,alias:"important"},number:/\d+/,operator:/[-!#$%&'*+,./:;=>?@\\^_`|~ßø]/,punctuation:/\[|\]/,variable:/[a-z]/,"non-standard":{pattern:/[()<BDO®]/,alias:"bold"}}})(t)}return _false}var firestoreSecurityRules_1,hasRequiredFirestoreSecurityRules;function requireFirestoreSecurityRules(){if(hasRequiredFirestoreSecurityRules)return firestoreSecurityRules_1;hasRequiredFirestoreSecurityRules=1,firestoreSecurityRules_1=e,e.displayName="firestoreSecurityRules",e.aliases=[];function e(t){t.languages["firestore-security-rules"]=t.languages.extend("clike",{comment:/\/\/.*/,keyword:/\b(?:allow|function|if|match|null|return|rules_version|service)\b/,operator:/&&|\|\||[<>!=]=?|[-+*/%]|\b(?:in|is)\b/}),delete t.languages["firestore-security-rules"]["class-name"],t.languages.insertBefore("firestore-security-rules","keyword",{path:{pattern:/(^|[\s(),])(?:\/(?:[\w\xA0-\uFFFF]+|\{[\w\xA0-\uFFFF]+(?:=\*\*)?\}|\$\([\w\xA0-\uFFFF.]+\)))+/,lookbehind:!0,greedy:!0,inside:{variable:{pattern:/\{[\w\xA0-\uFFFF]+(?:=\*\*)?\}|\$\([\w\xA0-\uFFFF.]+\)/,inside:{operator:/=/,keyword:/\*\*/,punctuation:/[.$(){}]/}},punctuation:/\//}},method:{pattern:/(\ballow\s+)[a-z]+(?:\s*,\s*[a-z]+)*(?=\s*[:;])/,lookbehind:!0,alias:"builtin",inside:{punctuation:/,/}}})}return firestoreSecurityRules_1}var flow_1,hasRequiredFlow;function requireFlow(){if(hasRequiredFlow)return flow_1;hasRequiredFlow=1,flow_1=e,e.displayName="flow",e.aliases=[];function e(t){(function(Ye){Ye.languages.flow=Ye.languages.extend("javascript",{}),Ye.languages.insertBefore("flow","keyword",{type:[{pattern:/\b(?:[Bb]oolean|Function|[Nn]umber|[Ss]tring|any|mixed|null|void)\b/,alias:"tag"}]}),Ye.languages.flow["function-variable"].pattern=/(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=\s*(?:function\b|(?:\([^()]*\)(?:\s*:\s*\w+)?|(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/i,delete Ye.languages.flow.parameter,Ye.languages.insertBefore("flow","operator",{"flow-punctuation":{pattern:/\{\||\|\}/,alias:"punctuation"}}),Array.isArray(Ye.languages.flow.keyword)||(Ye.languages.flow.keyword=[Ye.languages.flow.keyword]),Ye.languages.flow.keyword.unshift({pattern:/(^|[^$]\b)(?:Class|declare|opaque|type)\b(?!\$)/,lookbehind:!0},{pattern:/(^|[^$]\B)\$(?:Diff|Enum|Exact|Keys|ObjMap|PropertyType|Record|Shape|Subtype|Supertype|await)\b(?!\$)/,lookbehind:!0})})(t)}return flow_1}var fortran_1,hasRequiredFortran;function requireFortran(){if(hasRequiredFortran)return fortran_1;hasRequiredFortran=1,fortran_1=e,e.displayName="fortran",e.aliases=[];function e(t){t.languages.fortran={"quoted-number":{pattern:/[BOZ](['"])[A-F0-9]+\1/i,alias:"number"},string:{pattern:/(?:\b\w+_)?(['"])(?:\1\1|&(?:\r\n?|\n)(?:[ \t]*!.*(?:\r\n?|\n)|(?![ \t]*!))|(?!\1).)*(?:\1|&)/,inside:{comment:{pattern:/(&(?:\r\n?|\n)\s*)!.*/,lookbehind:!0}}},comment:{pattern:/!.*/,greedy:!0},boolean:/\.(?:FALSE|TRUE)\.(?:_\w+)?/i,number:/(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[ED][+-]?\d+)?(?:_\w+)?/i,keyword:[/\b(?:CHARACTER|COMPLEX|DOUBLE ?PRECISION|INTEGER|LOGICAL|REAL)\b/i,/\b(?:END ?)?(?:BLOCK ?DATA|DO|FILE|FORALL|FUNCTION|IF|INTERFACE|MODULE(?! PROCEDURE)|PROGRAM|SELECT|SUBROUTINE|TYPE|WHERE)\b/i,/\b(?:ALLOCATABLE|ALLOCATE|BACKSPACE|CALL|CASE|CLOSE|COMMON|CONTAINS|CONTINUE|CYCLE|DATA|DEALLOCATE|DIMENSION|DO|END|EQUIVALENCE|EXIT|EXTERNAL|FORMAT|GO ?TO|IMPLICIT(?: NONE)?|INQUIRE|INTENT|INTRINSIC|MODULE PROCEDURE|NAMELIST|NULLIFY|OPEN|OPTIONAL|PARAMETER|POINTER|PRINT|PRIVATE|PUBLIC|READ|RETURN|REWIND|SAVE|SELECT|STOP|TARGET|WHILE|WRITE)\b/i,/\b(?:ASSIGNMENT|DEFAULT|ELEMENTAL|ELSE|ELSEIF|ELSEWHERE|ENTRY|IN|INCLUDE|INOUT|KIND|NULL|ONLY|OPERATOR|OUT|PURE|RECURSIVE|RESULT|SEQUENCE|STAT|THEN|USE)\b/i],operator:[/\*\*|\/\/|=>|[=\/]=|[<>]=?|::|[+\-*=%]|\.[A-Z]+\./i,{pattern:/(^|(?!\().)\/(?!\))/,lookbehind:!0}],punctuation:/\(\/|\/\)|[(),;:&]/}}return fortran_1}var fsharp_1,hasRequiredFsharp;function requireFsharp(){if(hasRequiredFsharp)return fsharp_1;hasRequiredFsharp=1,fsharp_1=e,e.displayName="fsharp",e.aliases=[];function e(t){t.languages.fsharp=t.languages.extend("clike",{comment:[{pattern:/(^|[^\\])\(\*(?!\))[\s\S]*?\*\)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(?:"""[\s\S]*?"""|@"(?:""|[^"])*"|"(?:\\[\s\S]|[^\\"])*")B?/,greedy:!0},"class-name":{pattern:/(\b(?:exception|inherit|interface|new|of|type)\s+|\w\s*:\s*|\s:\??>\s*)[.\w]+\b(?:\s*(?:->|\*)\s*[.\w]+\b)*(?!\s*[:.])/,lookbehind:!0,inside:{operator:/->|\*/,punctuation:/\./}},keyword:/\b(?:let|return|use|yield)(?:!\B|\b)|\b(?:abstract|and|as|asr|assert|atomic|base|begin|break|checked|class|component|const|constraint|constructor|continue|default|delegate|do|done|downcast|downto|eager|elif|else|end|event|exception|extern|external|false|finally|fixed|for|fun|function|functor|global|if|in|include|inherit|inline|interface|internal|land|lazy|lor|lsl|lsr|lxor|match|member|method|mixin|mod|module|mutable|namespace|new|not|null|object|of|open|or|override|parallel|private|process|protected|public|pure|rec|sealed|select|sig|static|struct|tailcall|then|to|trait|true|try|type|upcast|val|virtual|void|volatile|when|while|with)\b/,number:[/\b0x[\da-fA-F]+(?:LF|lf|un)?\b/,/\b0b[01]+(?:uy|y)?\b/,/(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[fm]|e[+-]?\d+)?\b/i,/\b\d+(?:[IlLsy]|UL|u[lsy]?)?\b/],operator:/([<>~&^])\1\1|([*.:<>&])\2|<-|->|[!=:]=|<?\|{1,3}>?|\??(?:<=|>=|<>|[-+*/%=<>])\??|[!?^&]|~[+~-]|:>|:\?>?/}),t.languages.insertBefore("fsharp","keyword",{preprocessor:{pattern:/(^[\t ]*)#.*/m,lookbehind:!0,alias:"property",inside:{directive:{pattern:/(^#)\b(?:else|endif|if|light|line|nowarn)\b/,lookbehind:!0,alias:"keyword"}}}}),t.languages.insertBefore("fsharp","punctuation",{"computation-expression":{pattern:/\b[_a-z]\w*(?=\s*\{)/i,alias:"keyword"}}),t.languages.insertBefore("fsharp","string",{annotation:{pattern:/\[<.+?>\]/,greedy:!0,inside:{punctuation:/^\[<|>\]$/,"class-name":{pattern:/^\w+$|(^|;\s*)[A-Z]\w*(?=\()/,lookbehind:!0},"annotation-content":{pattern:/[\s\S]+/,inside:t.languages.fsharp}}},char:{pattern:/'(?:[^\\']|\\(?:.|\d{3}|x[a-fA-F\d]{2}|u[a-fA-F\d]{4}|U[a-fA-F\d]{8}))'B?/,greedy:!0}})}return fsharp_1}var ftl_1,hasRequiredFtl;function requireFtl(){if(hasRequiredFtl)return ftl_1;hasRequiredFtl=1;var e=requireMarkupTemplating();ftl_1=t,t.displayName="ftl",t.aliases=[];function t(Ye){Ye.register(e),function(tt){for(var rt=/[^<()"']|\((?:<expr>)*\)|<(?!#--)|<#--(?:[^-]|-(?!->))*-->|"(?:[^\\"]|\\.)*"|'(?:[^\\']|\\.)*'/.source,nt=0;nt<2;nt++)rt=rt.replace(/<expr>/g,function(){return rt});rt=rt.replace(/<expr>/g,/[^\s\S]/.source);var at={comment:/<#--[\s\S]*?-->/,string:[{pattern:/\br("|')(?:(?!\1)[^\\]|\\.)*\1/,greedy:!0},{pattern:RegExp(/("|')(?:(?!\1|\$\{)[^\\]|\\.|\$\{(?:(?!\})(?:<expr>))*\})*\1/.source.replace(/<expr>/g,function(){return rt})),greedy:!0,inside:{interpolation:{pattern:RegExp(/((?:^|[^\\])(?:\\\\)*)\$\{(?:(?!\})(?:<expr>))*\}/.source.replace(/<expr>/g,function(){return rt})),lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:null}}}}],keyword:/\b(?:as)\b/,boolean:/\b(?:false|true)\b/,"builtin-function":{pattern:/((?:^|[^?])\?\s*)\w+/,lookbehind:!0,alias:"function"},function:/\b\w+(?=\s*\()/,number:/\b\d+(?:\.\d+)?\b/,operator:/\.\.[<*!]?|->|--|\+\+|&&|\|\||\?{1,2}|[-+*/%!=<>]=?|\b(?:gt|gte|lt|lte)\b/,punctuation:/[,;.:()[\]{}]/};at.string[1].inside.interpolation.inside.rest=at,tt.languages.ftl={"ftl-comment":{pattern:/^<#--[\s\S]*/,alias:"comment"},"ftl-directive":{pattern:/^<[\s\S]+>$/,inside:{directive:{pattern:/(^<\/?)[#@][a-z]\w*/i,lookbehind:!0,alias:"keyword"},punctuation:/^<\/?|\/?>$/,content:{pattern:/\s*\S[\s\S]*/,alias:"ftl",inside:at}}},"ftl-interpolation":{pattern:/^\$\{[\s\S]*\}$/,inside:{punctuation:/^\$\{|\}$/,content:{pattern:/\s*\S[\s\S]*/,alias:"ftl",inside:at}}}},tt.hooks.add("before-tokenize",function(it){var ot=RegExp(/<#--[\s\S]*?-->|<\/?[#@][a-zA-Z](?:<expr>)*?>|\$\{(?:<expr>)*?\}/.source.replace(/<expr>/g,function(){return rt}),"gi");tt.languages["markup-templating"].buildPlaceholders(it,"ftl",ot)}),tt.hooks.add("after-tokenize",function(it){tt.languages["markup-templating"].tokenizePlaceholders(it,"ftl")})}(Ye)}return ftl_1}var gap_1,hasRequiredGap;function requireGap(){if(hasRequiredGap)return gap_1;hasRequiredGap=1,gap_1=e,e.displayName="gap",e.aliases=[];function e(t){t.languages.gap={shell:{pattern:/^gap>[\s\S]*?(?=^gap>|$(?![\s\S]))/m,greedy:!0,inside:{gap:{pattern:/^(gap>).+(?:(?:\r(?:\n|(?!\n))|\n)>.*)*/,lookbehind:!0,inside:null},punctuation:/^gap>/}},comment:{pattern:/#.*/,greedy:!0},string:{pattern:/(^|[^\\'"])(?:'(?:[^\r\n\\']|\\.){1,10}'|"(?:[^\r\n\\"]|\\.)*"(?!")|"""[\s\S]*?""")/,lookbehind:!0,greedy:!0,inside:{continuation:{pattern:/([\r\n])>/,lookbehind:!0,alias:"punctuation"}}},keyword:/\b(?:Assert|Info|IsBound|QUIT|TryNextMethod|Unbind|and|atomic|break|continue|do|elif|else|end|fi|for|function|if|in|local|mod|not|od|or|quit|readonly|readwrite|rec|repeat|return|then|until|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b[a-z_]\w*(?=\s*\()/i,number:{pattern:/(^|[^\w.]|\.\.)(?:\d+(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+)?(?:_[a-z]?)?(?=$|[^\w.]|\.\.)/,lookbehind:!0},continuation:{pattern:/([\r\n])>/,lookbehind:!0,alias:"punctuation"},operator:/->|[-+*/^~=!]|<>|[<>]=?|:=|\.\./,punctuation:/[()[\]{},;.:]/},t.languages.gap.shell.inside.gap.inside=t.languages.gap}return gap_1}var gcode_1,hasRequiredGcode;function requireGcode(){if(hasRequiredGcode)return gcode_1;hasRequiredGcode=1,gcode_1=e,e.displayName="gcode",e.aliases=[];function e(t){t.languages.gcode={comment:/;.*|\B\(.*?\)\B/,string:{pattern:/"(?:""|[^"])*"/,greedy:!0},keyword:/\b[GM]\d+(?:\.\d+)?\b/,property:/\b[A-Z]/,checksum:{pattern:/(\*)\d+/,lookbehind:!0,alias:"number"},punctuation:/[:*]/}}return gcode_1}var gdscript_1,hasRequiredGdscript;function requireGdscript(){if(hasRequiredGdscript)return gdscript_1;hasRequiredGdscript=1,gdscript_1=e,e.displayName="gdscript",e.aliases=[];function e(t){t.languages.gdscript={comment:/#.*/,string:{pattern:/@?(?:("|')(?:(?!\1)[^\n\\]|\\[\s\S])*\1(?!"|')|"""(?:[^\\]|\\[\s\S])*?""")/,greedy:!0},"class-name":{pattern:/(^(?:class|class_name|extends)[ \t]+|^export\([ \t]*|\bas[ \t]+|(?:\b(?:const|var)[ \t]|[,(])[ \t]*\w+[ \t]*:[ \t]*|->[ \t]*)[a-zA-Z_]\w*/m,lookbehind:!0},keyword:/\b(?:and|as|assert|break|breakpoint|class|class_name|const|continue|elif|else|enum|export|extends|for|func|if|in|is|master|mastersync|match|not|null|onready|or|pass|preload|puppet|puppetsync|remote|remotesync|return|self|setget|signal|static|tool|var|while|yield)\b/,function:/\b[a-z_]\w*(?=[ \t]*\()/i,variable:/\$\w+/,number:[/\b0b[01_]+\b|\b0x[\da-fA-F_]+\b|(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.[\d_]+)(?:e[+-]?[\d_]+)?\b/,/\b(?:INF|NAN|PI|TAU)\b/],constant:/\b[A-Z][A-Z_\d]*\b/,boolean:/\b(?:false|true)\b/,operator:/->|:=|&&|\|\||<<|>>|[-+*/%&|!<>=]=?|[~^]/,punctuation:/[.:,;()[\]{}]/}}return gdscript_1}var gedcom_1,hasRequiredGedcom;function requireGedcom(){if(hasRequiredGedcom)return gedcom_1;hasRequiredGedcom=1,gedcom_1=e,e.displayName="gedcom",e.aliases=[];function e(t){t.languages.gedcom={"line-value":{pattern:/(^[\t ]*\d+ +(?:@\w[\w!"$%&'()*+,\-./:;<=>?[\\\]^`{|}~\x80-\xfe #]*@ +)?\w+ ).+/m,lookbehind:!0,inside:{pointer:{pattern:/^@\w[\w!"$%&'()*+,\-./:;<=>?[\\\]^`{|}~\x80-\xfe #]*@$/,alias:"variable"}}},tag:{pattern:/(^[\t ]*\d+ +(?:@\w[\w!"$%&'()*+,\-./:;<=>?[\\\]^`{|}~\x80-\xfe #]*@ +)?)\w+/m,lookbehind:!0,alias:"string"},level:{pattern:/(^[\t ]*)\d+/m,lookbehind:!0,alias:"number"},pointer:{pattern:/@\w[\w!"$%&'()*+,\-./:;<=>?[\\\]^`{|}~\x80-\xfe #]*@/,alias:"variable"}}}return gedcom_1}var gherkin_1,hasRequiredGherkin;function requireGherkin(){if(hasRequiredGherkin)return gherkin_1;hasRequiredGherkin=1,gherkin_1=e,e.displayName="gherkin",e.aliases=[];function e(t){(function(Ye){var tt=/(?:\r?\n|\r)[ \t]*\|.+\|(?:(?!\|).)*/.source;Ye.languages.gherkin={pystring:{pattern:/("""|''')[\s\S]+?\1/,alias:"string"},comment:{pattern:/(^[ \t]*)#.*/m,lookbehind:!0},tag:{pattern:/(^[ \t]*)@\S*/m,lookbehind:!0},feature:{pattern:/((?:^|\r?\n|\r)[ \t]*)(?:Ability|Ahoy matey!|Arwedd|Aspekt|Besigheid Behoefte|Business Need|Caracteristica|Característica|Egenskab|Egenskap|Eiginleiki|Feature|Fīča|Fitur|Fonctionnalité|Fonksyonalite|Funcionalidade|Funcionalitat|Functionalitate|Funcţionalitate|Funcționalitate|Functionaliteit|Fungsi|Funkcia|Funkcija|Funkcionalitāte|Funkcionalnost|Funkcja|Funksie|Funktionalität|Funktionalitéit|Funzionalità|Hwaet|Hwæt|Jellemző|Karakteristik|Lastnost|Mak|Mogucnost|laH|Mogućnost|Moznosti|Možnosti|OH HAI|Omadus|Ominaisuus|Osobina|Özellik|Potrzeba biznesowa|perbogh|poQbogh malja'|Požadavek|Požiadavka|Pretty much|Qap|Qu'meH 'ut|Savybė|Tính năng|Trajto|Vermoë|Vlastnosť|Właściwość|Značilnost|Δυνατότητα|Λειτουργία|Могућност|Мөмкинлек|Особина|Свойство|Үзенчәлеклелек|Функционал|Функционалност|Функция|Функціонал|תכונה|خاصية|خصوصیت|صلاحیت|کاروبار کی ضرورت|وِیژگی|रूप लेख|ਖਾਸੀਅਤ|ਨਕਸ਼ ਨੁਹਾਰ|ਮੁਹਾਂਦਰਾ|గుణము|ಹೆಚ್ಚಳ|ความต้องการทางธุรกิจ|ความสามารถ|โครงหลัก|기능|フィーチャ|功能|機能):(?:[^:\r\n]+(?:\r?\n|\r|$))*/,lookbehind:!0,inside:{important:{pattern:/(:)[^\r\n]+/,lookbehind:!0},keyword:/[^:\r\n]+:/}},scenario:{pattern:/(^[ \t]*)(?:Abstract Scenario|Abstrakt Scenario|Achtergrond|Aer|Ær|Agtergrond|All y'all|Antecedentes|Antecedents|Atburðarás|Atburðarásir|Awww, look mate|B4|Background|Baggrund|Bakgrund|Bakgrunn|Bakgrunnur|Beispiele|Beispiller|Bối cảnh|Cefndir|Cenario|Cenário|Cenario de Fundo|Cenário de Fundo|Cenarios|Cenários|Contesto|Context|Contexte|Contexto|Conto|Contoh|Contone|Dæmi|Dasar|Dead men tell no tales|Delineacao do Cenario|Delineação do Cenário|Dis is what went down|Dữ liệu|Dyagram Senaryo|Dyagram senaryo|Egzanp|Ejemplos|Eksempler|Ekzemploj|Enghreifftiau|Esbozo do escenario|Escenari|Escenario|Esempi|Esquema de l'escenari|Esquema del escenario|Esquema do Cenario|Esquema do Cenário|EXAMPLZ|Examples|Exempel|Exemple|Exemples|Exemplos|First off|Fono|Forgatókönyv|Forgatókönyv vázlat|Fundo|Geçmiş|Grundlage|Hannergrond|ghantoH|Háttér|Heave to|Istorik|Juhtumid|Keadaan|Khung kịch bản|Khung tình huống|Kịch bản|Koncept|Konsep skenario|Kontèks|Kontekst|Kontekstas|Konteksts|Kontext|Konturo de la scenaro|Latar Belakang|lut chovnatlh|lut|lutmey|Lýsing Atburðarásar|Lýsing Dæma|MISHUN SRSLY|MISHUN|Menggariskan Senario|mo'|Náčrt Scenára|Náčrt Scénáře|Náčrt Scenáru|Oris scenarija|Örnekler|Osnova|Osnova Scenára|Osnova scénáře|Osnutek|Ozadje|Paraugs|Pavyzdžiai|Példák|Piemēri|Plan du scénario|Plan du Scénario|Plan Senaryo|Plan senaryo|Plang vum Szenario|Pozadí|Pozadie|Pozadina|Príklady|Příklady|Primer|Primeri|Primjeri|Przykłady|Raamstsenaarium|Reckon it's like|Rerefons|Scenár|Scénář|Scenarie|Scenarij|Scenarijai|Scenarijaus šablonas|Scenariji|Scenārijs|Scenārijs pēc parauga|Scenarijus|Scenario|Scénario|Scenario Amlinellol|Scenario Outline|Scenario Template|Scenariomal|Scenariomall|Scenarios|Scenariu|Scenariusz|Scenaro|Schema dello scenario|Se ðe|Se the|Se þe|Senario|Senaryo Deskripsyon|Senaryo deskripsyon|Senaryo|Senaryo taslağı|Shiver me timbers|Situācija|Situai|Situasie Uiteensetting|Situasie|Skenario konsep|Skenario|Skica|Structura scenariu|Structură scenariu|Struktura scenarija|Stsenaarium|Swa hwaer swa|Swa|Swa hwær swa|Szablon scenariusza|Szenario|Szenariogrundriss|Tapaukset|Tapaus|Tapausaihio|Taust|Tausta|Template Keadaan|Template Senario|Template Situai|The thing of it is|Tình huống|Variantai|Voorbeelde|Voorbeelden|Wharrimean is|Yo-ho-ho|You'll wanna|Założenia|Παραδείγματα|Περιγραφή Σεναρίου|Σενάρια|Σενάριο|Υπόβαθρο|Кереш|Контекст|Концепт|Мисаллар|Мисоллар|Основа|Передумова|Позадина|Предистория|Предыстория|Приклади|Пример|Примери|Примеры|Рамка на сценарий|Скица|Структура сценарија|Структура сценария|Структура сценарію|Сценарий|Сценарий структураси|Сценарийның төзелеше|Сценарији|Сценарио|Сценарій|Тарих|Үрнәкләр|דוגמאות|רקע|תבנית תרחיש|תרחיש|الخلفية|الگوی سناریو|امثلة|پس منظر|زمینه|سناریو|سيناريو|سيناريو مخطط|مثالیں|منظر نامے کا خاکہ|منظرنامہ|نمونه ها|उदाहरण|परिदृश्य|परिदृश्य रूपरेखा|पृष्ठभूमि|ਉਦਾਹਰਨਾਂ|ਪਟਕਥਾ|ਪਟਕਥਾ ਢਾਂਚਾ|ਪਟਕਥਾ ਰੂਪ ਰੇਖਾ|ਪਿਛੋਕੜ|ఉదాహరణలు|కథనం|నేపథ్యం|సన్నివేశం|ಉದಾಹರಣೆಗಳು|ಕಥಾಸಾರಾಂಶ|ವಿವರಣೆ|ಹಿನ್ನೆಲೆ|โครงสร้างของเหตุการณ์|ชุดของตัวอย่าง|ชุดของเหตุการณ์|แนวคิด|สรุปเหตุการณ์|เหตุการณ์|배경|시나리오|시나리오 개요|예|サンプル|シナリオ|シナリオアウトライン|シナリオテンプレ|シナリオテンプレート|テンプレ|例|例子|剧本|剧本大纲|劇本|劇本大綱|场景|场景大纲|場景|場景大綱|背景):[^:\r\n]*/m,lookbehind:!0,inside:{important:{pattern:/(:)[^\r\n]*/,lookbehind:!0},keyword:/[^:\r\n]+:/}},"table-body":{pattern:RegExp("("+tt+")(?:"+tt+")+"),lookbehind:!0,inside:{outline:{pattern:/<[^>]+>/,alias:"variable"},td:{pattern:/\s*[^\s|][^|]*/,alias:"string"},punctuation:/\|/}},"table-head":{pattern:RegExp(tt),inside:{th:{pattern:/\s*[^\s|][^|]*/,alias:"variable"},punctuation:/\|/}},atrule:{pattern:/(^[ \t]+)(?:'a|'ach|'ej|7|a|A také|A taktiež|A tiež|A zároveň|Aber|Ac|Adott|Akkor|Ak|Aleshores|Ale|Ali|Allora|Alors|Als|Ama|Amennyiben|Amikor|Ampak|an|AN|Ananging|And y'all|And|Angenommen|Anrhegedig a|An|Apabila|Atès|Atesa|Atunci|Avast!|Aye|A|awer|Bagi|Banjur|Bet|Biết|Blimey!|Buh|But at the end of the day I reckon|But y'all|But|BUT|Cal|Când|Cand|Cando|Ce|Cuando|Če|Ða ðe|Ða|Dadas|Dada|Dados|Dado|DaH ghu' bejlu'|dann|Dann|Dano|Dan|Dar|Dat fiind|Data|Date fiind|Date|Dati fiind|Dati|Daţi fiind|Dați fiind|DEN|Dato|De|Den youse gotta|Dengan|Diberi|Diyelim ki|Donada|Donat|Donitaĵo|Do|Dun|Duota|Ðurh|Eeldades|Ef|Eğer ki|Entao|Então|Entón|E|En|Entonces|Epi|És|Etant donnée|Etant donné|Et|Étant données|Étant donnée|Étant donné|Etant données|Etant donnés|Étant donnés|Fakat|Gangway!|Gdy|Gegeben seien|Gegeben sei|Gegeven|Gegewe|ghu' noblu'|Gitt|Given y'all|Given|Givet|Givun|Ha|Cho|I CAN HAZ|In|Ir|It's just unbelievable|I|Ja|Jeśli|Jeżeli|Kad|Kada|Kadar|Kai|Kaj|Když|Keď|Kemudian|Ketika|Khi|Kiedy|Ko|Kuid|Kui|Kun|Lan|latlh|Le sa a|Let go and haul|Le|Lè sa a|Lè|Logo|Lorsqu'<|Lorsque|mä|Maar|Mais|Mając|Ma|Majd|Maka|Manawa|Mas|Men|Menawa|Mutta|Nalika|Nalikaning|Nanging|Når|När|Nato|Nhưng|Niin|Njuk|O zaman|Och|Og|Oletetaan|Ond|Onda|Oraz|Pak|Pero|Però|Podano|Pokiaľ|Pokud|Potem|Potom|Privzeto|Pryd|Quan|Quand|Quando|qaSDI'|Så|Sed|Se|Siis|Sipoze ke|Sipoze Ke|Sipoze|Si|Şi|Și|Soit|Stel|Tada|Tad|Takrat|Tak|Tapi|Ter|Tetapi|Tha the|Tha|Then y'all|Then|Thì|Thurh|Toda|Too right|Un|Und|ugeholl|Và|vaj|Vendar|Ve|wann|Wanneer|WEN|Wenn|When y'all|When|Wtedy|Wun|Y'know|Yeah nah|Yna|Youse know like when|Youse know when youse got|Y|Za predpokladu|Za předpokladu|Zadan|Zadani|Zadano|Zadate|Zadato|Zakładając|Zaradi|Zatati|Þa þe|Þa|Þá|Þegar|Þurh|Αλλά|Δεδομένου|Και|Όταν|Τότε|А також|Агар|Але|Али|Аммо|А|Әгәр|Әйтик|Әмма|Бирок|Ва|Вә|Дадено|Дано|Допустим|Если|Задате|Задати|Задато|И|І|К тому же|Када|Кад|Когато|Когда|Коли|Ләкин|Лекин|Нәтиҗәдә|Нехай|Но|Онда|Припустимо, що|Припустимо|Пусть|Также|Та|Тогда|Тоді|То|Унда|Һәм|Якщо|אבל|אזי|אז|בהינתן|וגם|כאשר|آنگاه|اذاً|اگر|اما|اور|با فرض|بالفرض|بفرض|پھر|تب|ثم|جب|عندما|فرض کیا|لكن|لیکن|متى|هنگامی|و|अगर|और|कदा|किन्तु|चूंकि|जब|तथा|तदा|तब|परन्तु|पर|यदि|ਅਤੇ|ਜਦੋਂ|ਜਿਵੇਂ ਕਿ|ਜੇਕਰ|ਤਦ|ਪਰ|అప్పుడు|ఈ పరిస్థితిలో|కాని|చెప్పబడినది|మరియు|ಆದರೆ|ನಂತರ|ನೀಡಿದ|ಮತ್ತು|ಸ್ಥಿತಿಯನ್ನು|กำหนดให้|ดังนั้น|แต่|เมื่อ|และ|그러면<|그리고<|단<|만약<|만일<|먼저<|조건<|하지만<|かつ<|しかし<|ただし<|ならば<|もし<|並且<|但し<|但是<|假如<|假定<|假設<|假设<|前提<|同时<|同時<|并且<|当<|當<|而且<|那么<|那麼<)(?=[ \t])/m,lookbehind:!0},string:{pattern:/"(?:\\.|[^"\\\r\n])*"|'(?:\\.|[^'\\\r\n])*'/,inside:{outline:{pattern:/<[^>]+>/,alias:"variable"}}},outline:{pattern:/<[^>]+>/,alias:"variable"}}})(t)}return gherkin_1}var git_1,hasRequiredGit;function requireGit(){if(hasRequiredGit)return git_1;hasRequiredGit=1,git_1=e,e.displayName="git",e.aliases=[];function e(t){t.languages.git={comment:/^#.*/m,deleted:/^[-–].*/m,inserted:/^\+.*/m,string:/("|')(?:\\.|(?!\1)[^\\\r\n])*\1/,command:{pattern:/^.*\$ git .*$/m,inside:{parameter:/\s--?\w+/}},coord:/^@@.*@@$/m,"commit-sha1":/^commit \w{40}$/m}}return git_1}var glsl_1,hasRequiredGlsl;function requireGlsl(){if(hasRequiredGlsl)return glsl_1;hasRequiredGlsl=1;var e=requireC();glsl_1=t,t.displayName="glsl",t.aliases=[];function t(Ye){Ye.register(e),Ye.languages.glsl=Ye.languages.extend("c",{keyword:/\b(?:active|asm|atomic_uint|attribute|[ibdu]?vec[234]|bool|break|buffer|case|cast|centroid|class|coherent|common|const|continue|d?mat[234](?:x[234])?|default|discard|do|double|else|enum|extern|external|false|filter|fixed|flat|float|for|fvec[234]|goto|half|highp|hvec[234]|[iu]?sampler2DMS(?:Array)?|[iu]?sampler2DRect|[iu]?samplerBuffer|[iu]?samplerCube|[iu]?samplerCubeArray|[iu]?sampler[123]D|[iu]?sampler[12]DArray|[iu]?image2DMS(?:Array)?|[iu]?image2DRect|[iu]?imageBuffer|[iu]?imageCube|[iu]?imageCubeArray|[iu]?image[123]D|[iu]?image[12]DArray|if|in|inline|inout|input|int|interface|invariant|layout|long|lowp|mediump|namespace|noinline|noperspective|out|output|partition|patch|precise|precision|public|readonly|resource|restrict|return|sample|sampler[12]DArrayShadow|sampler[12]DShadow|sampler2DRectShadow|sampler3DRect|samplerCubeArrayShadow|samplerCubeShadow|shared|short|sizeof|smooth|static|struct|subroutine|superp|switch|template|this|true|typedef|uint|uniform|union|unsigned|using|varying|void|volatile|while|writeonly)\b/})}return glsl_1}var gml_1,hasRequiredGml;function requireGml(){if(hasRequiredGml)return gml_1;hasRequiredGml=1,gml_1=e,e.displayName="gml",e.aliases=[];function e(t){t.languages.gamemakerlanguage=t.languages.gml=t.languages.extend("clike",{keyword:/\b(?:break|case|continue|default|do|else|enum|exit|for|globalvar|if|repeat|return|switch|until|var|while)\b/,number:/(?:\b0x[\da-f]+|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?)[ulf]{0,4}/i,operator:/--|\+\+|[-+%/=]=?|!=|\*\*?=?|<[<=>]?|>[=>]?|&&?|\^\^?|\|\|?|~|\b(?:and|at|not|or|with|xor)\b/,constant:/\b(?:GM_build_date|GM_version|action_(?:continue|restart|reverse|stop)|all|gamespeed_(?:fps|microseconds)|global|local|noone|other|pi|pointer_(?:invalid|null)|self|timezone_(?:local|utc)|undefined|ev_(?:create|destroy|step|alarm|keyboard|mouse|collision|other|draw|draw_(?:begin|end|post|pre)|keypress|keyrelease|trigger|(?:left|middle|no|right)_button|(?:left|middle|right)_press|(?:left|middle|right)_release|mouse_(?:enter|leave|wheel_down|wheel_up)|global_(?:left|middle|right)_button|global_(?:left|middle|right)_press|global_(?:left|middle|right)_release|joystick(?:1|2)_(?:button1|button2|button3|button4|button5|button6|button7|button8|down|left|right|up)|outside|boundary|game_start|game_end|room_start|room_end|no_more_lives|animation_end|end_of_path|no_more_health|user\d|gui|gui_begin|gui_end|step_(?:begin|end|normal))|vk_(?:alt|anykey|backspace|control|delete|down|end|enter|escape|home|insert|left|nokey|pagedown|pageup|pause|printscreen|return|right|shift|space|tab|up|f\d|numpad\d|add|decimal|divide|lalt|lcontrol|lshift|multiply|ralt|rcontrol|rshift|subtract)|achievement_(?:filter_(?:all_players|favorites_only|friends_only)|friends_info|info|leaderboard_info|our_info|pic_loaded|show_(?:achievement|bank|friend_picker|leaderboard|profile|purchase_prompt|ui)|type_challenge|type_score_challenge)|asset_(?:font|object|path|room|script|shader|sound|sprite|tiles|timeline|unknown)|audio_(?:3d|falloff_(?:exponent_distance|exponent_distance_clamped|inverse_distance|inverse_distance_clamped|linear_distance|linear_distance_clamped|none)|mono|new_system|old_system|stereo)|bm_(?:add|complex|dest_alpha|dest_color|dest_colour|inv_dest_alpha|inv_dest_color|inv_dest_colour|inv_src_alpha|inv_src_color|inv_src_colour|max|normal|one|src_alpha|src_alpha_sat|src_color|src_colour|subtract|zero)|browser_(?:chrome|firefox|ie|ie_mobile|not_a_browser|opera|safari|safari_mobile|tizen|unknown|windows_store)|buffer_(?:bool|f16|f32|f64|fast|fixed|generalerror|grow|invalidtype|network|outofbounds|outofspace|s16|s32|s8|seek_end|seek_relative|seek_start|string|text|u16|u32|u64|u8|vbuffer|wrap)|c_(?:aqua|black|blue|dkgray|fuchsia|gray|green|lime|ltgray|maroon|navy|olive|orange|purple|red|silver|teal|white|yellow)|cmpfunc_(?:always|equal|greater|greaterequal|less|lessequal|never|notequal)|cr_(?:appstart|arrow|beam|cross|default|drag|handpoint|hourglass|none|size_all|size_nesw|size_ns|size_nwse|size_we|uparrow)|cull_(?:clockwise|counterclockwise|noculling)|device_(?:emulator|tablet)|device_ios_(?:ipad|ipad_retina|iphone|iphone5|iphone6|iphone6plus|iphone_retina|unknown)|display_(?:landscape|landscape_flipped|portrait|portrait_flipped)|dll_(?:cdecl|cdel|stdcall)|ds_type_(?:grid|list|map|priority|queue|stack)|ef_(?:cloud|ellipse|explosion|firework|flare|rain|ring|smoke|smokeup|snow|spark|star)|fa_(?:archive|bottom|center|directory|hidden|left|middle|readonly|right|sysfile|top|volumeid)|fb_login_(?:default|fallback_to_webview|forcing_safari|forcing_webview|no_fallback_to_webview|use_system_account)|iap_(?:available|canceled|ev_consume|ev_product|ev_purchase|ev_restore|ev_storeload|failed|purchased|refunded|status_available|status_loading|status_processing|status_restoring|status_unavailable|status_uninitialised|storeload_failed|storeload_ok|unavailable)|leaderboard_type_(?:number|time_mins_secs)|lighttype_(?:dir|point)|matrix_(?:projection|view|world)|mb_(?:any|left|middle|none|right)|network_(?:config_(?:connect_timeout|disable_reliable_udp|enable_reliable_udp|use_non_blocking_socket)|socket_(?:bluetooth|tcp|udp)|type_(?:connect|data|disconnect|non_blocking_connect))|of_challenge_(?:lose|tie|win)|os_(?:android|ios|linux|macosx|ps3|ps4|psvita|unknown|uwp|win32|win8native|windows|winphone|xboxone)|phy_debug_render_(?:aabb|collision_pairs|coms|core_shapes|joints|obb|shapes)|phy_joint_(?:anchor_1_x|anchor_1_y|anchor_2_x|anchor_2_y|angle|angle_limits|damping_ratio|frequency|length_1|length_2|lower_angle_limit|max_force|max_length|max_motor_force|max_motor_torque|max_torque|motor_force|motor_speed|motor_torque|reaction_force_x|reaction_force_y|reaction_torque|speed|translation|upper_angle_limit)|phy_particle_data_flag_(?:category|color|colour|position|typeflags|velocity)|phy_particle_flag_(?:colormixing|colourmixing|elastic|powder|spring|tensile|viscous|wall|water|zombie)|phy_particle_group_flag_(?:rigid|solid)|pr_(?:linelist|linestrip|pointlist|trianglefan|trianglelist|trianglestrip)|ps_(?:distr|shape)_(?:diamond|ellipse|gaussian|invgaussian|line|linear|rectangle)|pt_shape_(?:circle|cloud|disk|explosion|flare|line|pixel|ring|smoke|snow|spark|sphere|square|star)|ty_(?:real|string)|gp_(?:face\d|axislh|axislv|axisrh|axisrv|padd|padl|padr|padu|select|shoulderl|shoulderlb|shoulderr|shoulderrb|start|stickl|stickr)|lb_disp_(?:none|numeric|time_ms|time_sec)|lb_sort_(?:ascending|descending|none)|ov_(?:achievements|community|friends|gamegroup|players|settings)|ugc_(?:filetype_(?:community|microtrans)|list_(?:Favorited|Followed|Published|Subscribed|UsedOrPlayed|VotedDown|VotedOn|VotedUp|WillVoteLater)|match_(?:AllGuides|Artwork|Collections|ControllerBindings|IntegratedGuides|Items|Items_Mtx|Items_ReadyToUse|Screenshots|UsableInGame|Videos|WebGuides)|query_(?:AcceptedForGameRankedByAcceptanceDate|CreatedByFriendsRankedByPublicationDate|FavoritedByFriendsRankedByPublicationDate|NotYetRated)|query_RankedBy(?:NumTimesReported|PublicationDate|TextSearch|TotalVotesAsc|Trend|Vote|VotesUp)|result_success|sortorder_CreationOrder(?:Asc|Desc)|sortorder_(?:ForModeration|LastUpdatedDesc|SubscriptionDateDesc|TitleAsc|VoteScoreDesc)|visibility_(?:friends_only|private|public))|vertex_usage_(?:binormal|blendindices|blendweight|color|colour|depth|fog|normal|position|psize|sample|tangent|texcoord|textcoord)|vertex_type_(?:float\d|color|colour|ubyte4)|input_type|layerelementtype_(?:background|instance|oldtilemap|particlesystem|sprite|tile|tilemap|undefined)|se_(?:chorus|compressor|echo|equalizer|flanger|gargle|none|reverb)|text_type|tile_(?:flip|index_mask|mirror|rotate)|(?:obj|rm|scr|spr)\w+)\b/,variable:/\b(?:alarm|application_surface|async_load|background_(?:alpha|blend|color|colour|foreground|height|hspeed|htiled|index|showcolor|showcolour|visible|vspeed|vtiled|width|x|xscale|y|yscale)|bbox_(?:bottom|left|right|top)|browser_(?:height|width)|caption_(?:health|lives|score)|current_(?:day|hour|minute|month|second|time|weekday|year)|cursor_sprite|debug_mode|delta_time|direction|display_aa|error_(?:last|occurred)|event_(?:action|number|object|type)|fps|fps_real|friction|game_(?:display|project|save)_(?:id|name)|gamemaker_(?:pro|registered|version)|gravity|gravity_direction|(?:h|v)speed|health|iap_data|id|image_(?:alpha|angle|blend|depth|index|number|speed|xscale|yscale)|instance_(?:count|id)|keyboard_(?:key|lastchar|lastkey|string)|layer|lives|mask_index|mouse_(?:button|lastbutton|x|y)|object_index|os_(?:browser|device|type|version)|path_(?:endaction|index|orientation|position|positionprevious|scale|speed)|persistent|phy_(?:rotation|(?:col_normal|collision|com|linear_velocity|position|speed)_(?:x|y)|angular_(?:damping|velocity)|position_(?:x|y)previous|speed|linear_damping|bullet|fixed_rotation|active|mass|inertia|dynamic|kinematic|sleeping|collision_points)|pointer_(?:invalid|null)|room|room_(?:caption|first|height|last|persistent|speed|width)|score|secure_mode|show_(?:health|lives|score)|solid|speed|sprite_(?:height|index|width|xoffset|yoffset)|temp_directory|timeline_(?:index|loop|position|running|speed)|transition_(?:color|kind|steps)|undefined|view_(?:angle|current|enabled|(?:h|v)(?:border|speed)|(?:h|w|x|y)port|(?:h|w|x|y)view|object|surface_id|visible)|visible|webgl_enabled|working_directory|(?:x|y)(?:previous|start)|x|y|argument(?:_relitive|_count|\d)|argument|global|local|other|self)\b/})}return gml_1}var gn_1,hasRequiredGn;function requireGn(){if(hasRequiredGn)return gn_1;hasRequiredGn=1,gn_1=e,e.displayName="gn",e.aliases=["gni"];function e(t){t.languages.gn={comment:{pattern:/#.*/,greedy:!0},"string-literal":{pattern:/(^|[^\\"])"(?:[^\r\n"\\]|\\.)*"/,lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$(?:\{[\s\S]*?\}|[a-zA-Z_]\w*|0x[a-fA-F0-9]{2})/,lookbehind:!0,inside:{number:/^\$0x[\s\S]{2}$/,variable:/^\$\w+$/,"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},expression:{pattern:/[\s\S]+/,inside:null}}},string:/[\s\S]+/}},keyword:/\b(?:else|if)\b/,boolean:/\b(?:false|true)\b/,"builtin-function":{pattern:/\b(?:assert|defined|foreach|import|pool|print|template|tool|toolchain)(?=\s*\()/i,alias:"keyword"},function:/\b[a-z_]\w*(?=\s*\()/i,constant:/\b(?:current_cpu|current_os|current_toolchain|default_toolchain|host_cpu|host_os|root_build_dir|root_gen_dir|root_out_dir|target_cpu|target_gen_dir|target_os|target_out_dir)\b/,number:/-?\b\d+\b/,operator:/[-+!=<>]=?|&&|\|\|/,punctuation:/[(){}[\],.]/},t.languages.gn["string-literal"].inside.interpolation.inside.expression.inside=t.languages.gn,t.languages.gni=t.languages.gn}return gn_1}var goModule_1,hasRequiredGoModule;function requireGoModule(){if(hasRequiredGoModule)return goModule_1;hasRequiredGoModule=1,goModule_1=e,e.displayName="goModule",e.aliases=[];function e(t){t.languages["go-mod"]=t.languages["go-module"]={comment:{pattern:/\/\/.*/,greedy:!0},version:{pattern:/(^|[\s()[\],])v\d+\.\d+\.\d+(?:[+-][-+.\w]*)?(?![^\s()[\],])/,lookbehind:!0,alias:"number"},"go-version":{pattern:/((?:^|\s)go\s+)\d+(?:\.\d+){1,2}/,lookbehind:!0,alias:"number"},keyword:{pattern:/^([ \t]*)(?:exclude|go|module|replace|require|retract)\b/m,lookbehind:!0},operator:/=>/,punctuation:/[()[\],]/}}return goModule_1}var go_1,hasRequiredGo;function requireGo(){if(hasRequiredGo)return go_1;hasRequiredGo=1,go_1=e,e.displayName="go",e.aliases=[];function e(t){t.languages.go=t.languages.extend("clike",{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"|`[^`]*`/,lookbehind:!0,greedy:!0},keyword:/\b(?:break|case|chan|const|continue|default|defer|else|fallthrough|for|func|go(?:to)?|if|import|interface|map|package|range|return|select|struct|switch|type|var)\b/,boolean:/\b(?:_|false|iota|nil|true)\b/,number:[/\b0(?:b[01_]+|o[0-7_]+)i?\b/i,/\b0x(?:[a-f\d_]+(?:\.[a-f\d_]*)?|\.[a-f\d_]+)(?:p[+-]?\d+(?:_\d+)*)?i?(?!\w)/i,/(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?[\d_]+)?i?(?!\w)/i],operator:/[*\/%^!=]=?|\+[=+]?|-[=-]?|\|[=|]?|&(?:=|&|\^=?)?|>(?:>=?|=)?|<(?:<=?|=|-)?|:=|\.\.\./,builtin:/\b(?:append|bool|byte|cap|close|complex|complex(?:64|128)|copy|delete|error|float(?:32|64)|u?int(?:8|16|32|64)?|imag|len|make|new|panic|print(?:ln)?|real|recover|rune|string|uintptr)\b/}),t.languages.insertBefore("go","string",{char:{pattern:/'(?:\\.|[^'\\\r\n]){0,10}'/,greedy:!0}}),delete t.languages.go["class-name"]}return go_1}var graphql_1,hasRequiredGraphql;function requireGraphql(){if(hasRequiredGraphql)return graphql_1;hasRequiredGraphql=1,graphql_1=e,e.displayName="graphql",e.aliases=[];function e(t){t.languages.graphql={comment:/#.*/,description:{pattern:/(?:"""(?:[^"]|(?!""")")*"""|"(?:\\.|[^\\"\r\n])*")(?=\s*[a-z_])/i,greedy:!0,alias:"string",inside:{"language-markdown":{pattern:/(^"(?:"")?)(?!\1)[\s\S]+(?=\1$)/,lookbehind:!0,inside:t.languages.markdown}}},string:{pattern:/"""(?:[^"]|(?!""")")*"""|"(?:\\.|[^\\"\r\n])*"/,greedy:!0},number:/(?:\B-|\b)\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i,boolean:/\b(?:false|true)\b/,variable:/\$[a-z_]\w*/i,directive:{pattern:/@[a-z_]\w*/i,alias:"function"},"attr-name":{pattern:/\b[a-z_]\w*(?=\s*(?:\((?:[^()"]|"(?:\\.|[^\\"\r\n])*")*\))?:)/i,greedy:!0},"atom-input":{pattern:/\b[A-Z]\w*Input\b/,alias:"class-name"},scalar:/\b(?:Boolean|Float|ID|Int|String)\b/,constant:/\b[A-Z][A-Z_\d]*\b/,"class-name":{pattern:/(\b(?:enum|implements|interface|on|scalar|type|union)\s+|&\s*|:\s*|\[)[A-Z_]\w*/,lookbehind:!0},fragment:{pattern:/(\bfragment\s+|\.{3}\s*(?!on\b))[a-zA-Z_]\w*/,lookbehind:!0,alias:"function"},"definition-mutation":{pattern:/(\bmutation\s+)[a-zA-Z_]\w*/,lookbehind:!0,alias:"function"},"definition-query":{pattern:/(\bquery\s+)[a-zA-Z_]\w*/,lookbehind:!0,alias:"function"},keyword:/\b(?:directive|enum|extend|fragment|implements|input|interface|mutation|on|query|repeatable|scalar|schema|subscription|type|union)\b/,operator:/[!=|&]|\.{3}/,"property-query":/\w+(?=\s*\()/,object:/\w+(?=\s*\{)/,punctuation:/[!(){}\[\]:=,]/,property:/\w+/},t.hooks.add("after-tokenize",function(tt){if(tt.language!=="graphql")return;var rt=tt.tokens.filter(function(Yt){return typeof Yt!="string"&&Yt.type!=="comment"&&Yt.type!=="scalar"}),nt=0;function at(Yt){return rt[nt+Yt]}function it(Yt,Gt){Gt=Gt||0;for(var Vt=0;Vt<Yt.length;Vt++){var Zt=at(Vt+Gt);if(!Zt||Zt.type!==Yt[Vt])return!1}return!0}function ot(Yt,Gt){for(var Vt=1,Zt=nt;Zt<rt.length;Zt++){var Xt=rt[Zt],Qt=Xt.content;if(Xt.type==="punctuation"&&typeof Qt=="string"){if(Yt.test(Qt))Vt++;else if(Gt.test(Qt)&&(Vt--,Vt===0))return Zt}}return-1}function ct(Yt,Gt){var Vt=Yt.alias;Vt?Array.isArray(Vt)||(Yt.alias=Vt=[Vt]):Yt.alias=Vt=[],Vt.push(Gt)}for(;nt<rt.length;){var At=rt[nt++];if(At.type==="keyword"&&At.content==="mutation"){var Rt=[];if(it(["definition-mutation","punctuation"])&&at(1).content==="("){nt+=2;var qt=ot(/^\($/,/^\)$/);if(qt===-1)continue;for(;nt<qt;nt++){var Ft=at(0);Ft.type==="variable"&&(ct(Ft,"variable-input"),Rt.push(Ft.content))}nt=qt+1}if(it(["punctuation","property-query"])&&at(0).content==="{"&&(nt++,ct(at(0),"property-mutation"),Rt.length>0)){var Ut=ot(/^\{$/,/^\}$/);if(Ut===-1)continue;for(var Ht=nt;Ht<Ut;Ht++){var zt=rt[Ht];zt.type==="variable"&&Rt.indexOf(zt.content)>=0&&ct(zt,"variable-input")}}}}})}return graphql_1}var groovy_1,hasRequiredGroovy;function requireGroovy(){if(hasRequiredGroovy)return groovy_1;hasRequiredGroovy=1,groovy_1=e,e.displayName="groovy",e.aliases=[];function e(t){t.languages.groovy=t.languages.extend("clike",{string:[{pattern:/("""|''')(?:[^\\]|\\[\s\S])*?\1|\$\/(?:[^/$]|\$(?:[/$]|(?![/$]))|\/(?!\$))*\/\$/,greedy:!0},{pattern:/(["'/])(?:\\.|(?!\1)[^\\\r\n])*\1/,greedy:!0}],keyword:/\b(?:abstract|as|assert|boolean|break|byte|case|catch|char|class|const|continue|def|default|do|double|else|enum|extends|final|finally|float|for|goto|if|implements|import|in|instanceof|int|interface|long|native|new|package|private|protected|public|return|short|static|strictfp|super|switch|synchronized|this|throw|throws|trait|transient|try|void|volatile|while)\b/,number:/\b(?:0b[01_]+|0x[\da-f_]+(?:\.[\da-f_p\-]+)?|[\d_]+(?:\.[\d_]+)?(?:e[+-]?\d+)?)[glidf]?\b/i,operator:{pattern:/(^|[^.])(?:~|==?~?|\?[.:]?|\*(?:[.=]|\*=?)?|\.[@&]|\.\.<|\.\.(?!\.)|-[-=>]?|\+[+=]?|!=?|<(?:<=?|=>?)?|>(?:>>?=?|=)?|&[&=]?|\|[|=]?|\/=?|\^=?|%=?)/,lookbehind:!0},punctuation:/\.+|[{}[\];(),:$]/}),t.languages.insertBefore("groovy","string",{shebang:{pattern:/#!.+/,alias:"comment"}}),t.languages.insertBefore("groovy","punctuation",{"spock-block":/\b(?:and|cleanup|expect|given|setup|then|when|where):/}),t.languages.insertBefore("groovy","function",{annotation:{pattern:/(^|[^.])@\w+/,lookbehind:!0,alias:"punctuation"}}),t.hooks.add("wrap",function(Ye){if(Ye.language==="groovy"&&Ye.type==="string"){var tt=Ye.content.value[0];if(tt!="'"){var rt=/([^\\])(?:\$(?:\{.*?\}|[\w.]+))/;tt==="$"&&(rt=/([^\$])(?:\$(?:\{.*?\}|[\w.]+))/),Ye.content.value=Ye.content.value.replace(/&lt;/g,"<").replace(/&amp;/g,"&"),Ye.content=t.highlight(Ye.content.value,{expression:{pattern:rt,lookbehind:!0,inside:t.languages.groovy}}),Ye.classes.push(tt==="/"?"regex":"gstring")}}})}return groovy_1}var haml_1,hasRequiredHaml;function requireHaml(){if(hasRequiredHaml)return haml_1;hasRequiredHaml=1;var e=requireRuby();haml_1=t,t.displayName="haml",t.aliases=[];function t(Ye){Ye.register(e),function(tt){tt.languages.haml={"multiline-comment":{pattern:/((?:^|\r?\n|\r)([\t ]*))(?:\/|-#).*(?:(?:\r?\n|\r)\2[\t ].+)*/,lookbehind:!0,alias:"comment"},"multiline-code":[{pattern:/((?:^|\r?\n|\r)([\t ]*)(?:[~-]|[&!]?=)).*,[\t ]*(?:(?:\r?\n|\r)\2[\t ].*,[\t ]*)*(?:(?:\r?\n|\r)\2[\t ].+)/,lookbehind:!0,inside:tt.languages.ruby},{pattern:/((?:^|\r?\n|\r)([\t ]*)(?:[~-]|[&!]?=)).*\|[\t ]*(?:(?:\r?\n|\r)\2[\t ].*\|[\t ]*)*/,lookbehind:!0,inside:tt.languages.ruby}],filter:{pattern:/((?:^|\r?\n|\r)([\t ]*)):[\w-]+(?:(?:\r?\n|\r)(?:\2[\t ].+|\s*?(?=\r?\n|\r)))+/,lookbehind:!0,inside:{"filter-name":{pattern:/^:[\w-]+/,alias:"symbol"}}},markup:{pattern:/((?:^|\r?\n|\r)[\t ]*)<.+/,lookbehind:!0,inside:tt.languages.markup},doctype:{pattern:/((?:^|\r?\n|\r)[\t ]*)!!!(?: .+)?/,lookbehind:!0},tag:{pattern:/((?:^|\r?\n|\r)[\t ]*)[%.#][\w\-#.]*[\w\-](?:\([^)]+\)|\{(?:\{[^}]+\}|[^{}])+\}|\[[^\]]+\])*[\/<>]*/,lookbehind:!0,inside:{attributes:[{pattern:/(^|[^#])\{(?:\{[^}]+\}|[^{}])+\}/,lookbehind:!0,inside:tt.languages.ruby},{pattern:/\([^)]+\)/,inside:{"attr-value":{pattern:/(=\s*)(?:"(?:\\.|[^\\"\r\n])*"|[^)\s]+)/,lookbehind:!0},"attr-name":/[\w:-]+(?=\s*!?=|\s*[,)])/,punctuation:/[=(),]/}},{pattern:/\[[^\]]+\]/,inside:tt.languages.ruby}],punctuation:/[<>]/}},code:{pattern:/((?:^|\r?\n|\r)[\t ]*(?:[~-]|[&!]?=)).+/,lookbehind:!0,inside:tt.languages.ruby},interpolation:{pattern:/#\{[^}]+\}/,inside:{delimiter:{pattern:/^#\{|\}$/,alias:"punctuation"},ruby:{pattern:/[\s\S]+/,inside:tt.languages.ruby}}},punctuation:{pattern:/((?:^|\r?\n|\r)[\t ]*)[~=\-&!]+/,lookbehind:!0}};for(var rt="((?:^|\\r?\\n|\\r)([\\t ]*)):{{filter_name}}(?:(?:\\r?\\n|\\r)(?:\\2[\\t ].+|\\s*?(?=\\r?\\n|\\r)))+",nt=["css",{filter:"coffee",language:"coffeescript"},"erb","javascript","less","markdown","ruby","scss","textile"],at={},it=0,ot=nt.length;it<ot;it++){var ct=nt[it];ct=typeof ct=="string"?{filter:ct,language:ct}:ct,tt.languages[ct.language]&&(at["filter-"+ct.filter]={pattern:RegExp(rt.replace("{{filter_name}}",function(){return ct.filter})),lookbehind:!0,inside:{"filter-name":{pattern:/^:[\w-]+/,alias:"symbol"},text:{pattern:/[\s\S]+/,alias:[ct.language,"language-"+ct.language],inside:tt.languages[ct.language]}}})}tt.languages.insertBefore("haml","filter",at)}(Ye)}return haml_1}var handlebars_1,hasRequiredHandlebars;function requireHandlebars(){if(hasRequiredHandlebars)return handlebars_1;hasRequiredHandlebars=1;var e=requireMarkupTemplating();handlebars_1=t,t.displayName="handlebars",t.aliases=["hbs"];function t(Ye){Ye.register(e),function(tt){tt.languages.handlebars={comment:/\{\{![\s\S]*?\}\}/,delimiter:{pattern:/^\{\{\{?|\}\}\}?$/,alias:"punctuation"},string:/(["'])(?:\\.|(?!\1)[^\\\r\n])*\1/,number:/\b0x[\dA-Fa-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[Ee][+-]?\d+)?/,boolean:/\b(?:false|true)\b/,block:{pattern:/^(\s*(?:~\s*)?)[#\/]\S+?(?=\s*(?:~\s*)?$|\s)/,lookbehind:!0,alias:"keyword"},brackets:{pattern:/\[[^\]]+\]/,inside:{punctuation:/\[|\]/,variable:/[\s\S]+/}},punctuation:/[!"#%&':()*+,.\/;<=>@\[\\\]^`{|}~]/,variable:/[^!"#%&'()*+,\/;<=>@\[\\\]^`{|}~\s]+/},tt.hooks.add("before-tokenize",function(rt){var nt=/\{\{\{[\s\S]+?\}\}\}|\{\{[\s\S]+?\}\}/g;tt.languages["markup-templating"].buildPlaceholders(rt,"handlebars",nt)}),tt.hooks.add("after-tokenize",function(rt){tt.languages["markup-templating"].tokenizePlaceholders(rt,"handlebars")}),tt.languages.hbs=tt.languages.handlebars}(Ye)}return handlebars_1}var haskell_1,hasRequiredHaskell;function requireHaskell(){if(hasRequiredHaskell)return haskell_1;hasRequiredHaskell=1,haskell_1=e,e.displayName="haskell",e.aliases=["hs"];function e(t){t.languages.haskell={comment:{pattern:/(^|[^-!#$%*+=?&@|~.:<>^\\\/])(?:--(?:(?=.)[^-!#$%*+=?&@|~.:<>^\\\/].*|$)|\{-[\s\S]*?-\})/m,lookbehind:!0},char:{pattern:/'(?:[^\\']|\\(?:[abfnrtv\\"'&]|\^[A-Z@[\]^_]|ACK|BEL|BS|CAN|CR|DC1|DC2|DC3|DC4|DEL|DLE|EM|ENQ|EOT|ESC|ETB|ETX|FF|FS|GS|HT|LF|NAK|NUL|RS|SI|SO|SOH|SP|STX|SUB|SYN|US|VT|\d+|o[0-7]+|x[0-9a-fA-F]+))'/,alias:"string"},string:{pattern:/"(?:[^\\"]|\\(?:\S|\s+\\))*"/,greedy:!0},keyword:/\b(?:case|class|data|deriving|do|else|if|in|infixl|infixr|instance|let|module|newtype|of|primitive|then|type|where)\b/,"import-statement":{pattern:/(^[\t ]*)import\s+(?:qualified\s+)?(?:[A-Z][\w']*)(?:\.[A-Z][\w']*)*(?:\s+as\s+(?:[A-Z][\w']*)(?:\.[A-Z][\w']*)*)?(?:\s+hiding\b)?/m,lookbehind:!0,inside:{keyword:/\b(?:as|hiding|import|qualified)\b/,punctuation:/\./}},builtin:/\b(?:abs|acos|acosh|all|and|any|appendFile|approxRational|asTypeOf|asin|asinh|atan|atan2|atanh|basicIORun|break|catch|ceiling|chr|compare|concat|concatMap|const|cos|cosh|curry|cycle|decodeFloat|denominator|digitToInt|div|divMod|drop|dropWhile|either|elem|encodeFloat|enumFrom|enumFromThen|enumFromThenTo|enumFromTo|error|even|exp|exponent|fail|filter|flip|floatDigits|floatRadix|floatRange|floor|fmap|foldl|foldl1|foldr|foldr1|fromDouble|fromEnum|fromInt|fromInteger|fromIntegral|fromRational|fst|gcd|getChar|getContents|getLine|group|head|id|inRange|index|init|intToDigit|interact|ioError|isAlpha|isAlphaNum|isAscii|isControl|isDenormalized|isDigit|isHexDigit|isIEEE|isInfinite|isLower|isNaN|isNegativeZero|isOctDigit|isPrint|isSpace|isUpper|iterate|last|lcm|length|lex|lexDigits|lexLitChar|lines|log|logBase|lookup|map|mapM|mapM_|max|maxBound|maximum|maybe|min|minBound|minimum|mod|negate|not|notElem|null|numerator|odd|or|ord|otherwise|pack|pi|pred|primExitWith|print|product|properFraction|putChar|putStr|putStrLn|quot|quotRem|range|rangeSize|read|readDec|readFile|readFloat|readHex|readIO|readInt|readList|readLitChar|readLn|readOct|readParen|readSigned|reads|readsPrec|realToFrac|recip|rem|repeat|replicate|return|reverse|round|scaleFloat|scanl|scanl1|scanr|scanr1|seq|sequence|sequence_|show|showChar|showInt|showList|showLitChar|showParen|showSigned|showString|shows|showsPrec|significand|signum|sin|sinh|snd|sort|span|splitAt|sqrt|subtract|succ|sum|tail|take|takeWhile|tan|tanh|threadToIOResult|toEnum|toInt|toInteger|toLower|toRational|toUpper|truncate|uncurry|undefined|unlines|until|unwords|unzip|unzip3|userError|words|writeFile|zip|zip3|zipWith|zipWith3)\b/,number:/\b(?:\d+(?:\.\d+)?(?:e[+-]?\d+)?|0o[0-7]+|0x[0-9a-f]+)\b/i,operator:[{pattern:/`(?:[A-Z][\w']*\.)*[_a-z][\w']*`/,greedy:!0},{pattern:/(\s)\.(?=\s)/,lookbehind:!0},/[-!#$%*+=?&@|~:<>^\\\/][-!#$%*+=?&@|~.:<>^\\\/]*|\.[-!#$%*+=?&@|~.:<>^\\\/]+/],hvariable:{pattern:/\b(?:[A-Z][\w']*\.)*[_a-z][\w']*/,inside:{punctuation:/\./}},constant:{pattern:/\b(?:[A-Z][\w']*\.)*[A-Z][\w']*/,inside:{punctuation:/\./}},punctuation:/[{}[\];(),.:]/},t.languages.hs=t.languages.haskell}return haskell_1}var haxe_1,hasRequiredHaxe;function requireHaxe(){if(hasRequiredHaxe)return haxe_1;hasRequiredHaxe=1,haxe_1=e,e.displayName="haxe",e.aliases=[];function e(t){t.languages.haxe=t.languages.extend("clike",{string:{pattern:/"(?:[^"\\]|\\[\s\S])*"/,greedy:!0},"class-name":[{pattern:/(\b(?:abstract|class|enum|extends|implements|interface|new|typedef)\s+)[A-Z_]\w*/,lookbehind:!0},/\b[A-Z]\w*/],keyword:/\bthis\b|\b(?:abstract|as|break|case|cast|catch|class|continue|default|do|dynamic|else|enum|extends|extern|final|for|from|function|if|implements|import|in|inline|interface|macro|new|null|operator|overload|override|package|private|public|return|static|super|switch|throw|to|try|typedef|untyped|using|var|while)(?!\.)\b/,function:{pattern:/\b[a-z_]\w*(?=\s*(?:<[^<>]*>\s*)?\()/i,greedy:!0},operator:/\.{3}|\+\+|--|&&|\|\||->|=>|(?:<<?|>{1,3}|[-+*/%!=&|^])=?|[?:~]/}),t.languages.insertBefore("haxe","string",{"string-interpolation":{pattern:/'(?:[^'\\]|\\[\s\S])*'/,greedy:!0,inside:{interpolation:{pattern:/(^|[^\\])\$(?:\w+|\{[^{}]+\})/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{?|\}$/,alias:"punctuation"},expression:{pattern:/[\s\S]+/,inside:t.languages.haxe}}},string:/[\s\S]+/}}}),t.languages.insertBefore("haxe","class-name",{regex:{pattern:/~\/(?:[^\/\\\r\n]|\\.)+\/[a-z]*/,greedy:!0,inside:{"regex-flags":/\b[a-z]+$/,"regex-source":{pattern:/^(~\/)[\s\S]+(?=\/$)/,lookbehind:!0,alias:"language-regex",inside:t.languages.regex},"regex-delimiter":/^~\/|\/$/}}}),t.languages.insertBefore("haxe","keyword",{preprocessor:{pattern:/#(?:else|elseif|end|if)\b.*/,alias:"property"},metadata:{pattern:/@:?[\w.]+/,alias:"symbol"},reification:{pattern:/\$(?:\w+|(?=\{))/,alias:"important"}})}return haxe_1}var hcl_1,hasRequiredHcl;function requireHcl(){if(hasRequiredHcl)return hcl_1;hasRequiredHcl=1,hcl_1=e,e.displayName="hcl",e.aliases=[];function e(t){t.languages.hcl={comment:/(?:\/\/|#).*|\/\*[\s\S]*?(?:\*\/|$)/,heredoc:{pattern:/<<-?(\w+\b)[\s\S]*?^[ \t]*\1/m,greedy:!0,alias:"string"},keyword:[{pattern:/(?:data|resource)\s+(?:"(?:\\[\s\S]|[^\\"])*")(?=\s+"[\w-]+"\s+\{)/i,inside:{type:{pattern:/(resource|data|\s+)(?:"(?:\\[\s\S]|[^\\"])*")/i,lookbehind:!0,alias:"variable"}}},{pattern:/(?:backend|module|output|provider|provisioner|variable)\s+(?:[\w-]+|"(?:\\[\s\S]|[^\\"])*")\s+(?=\{)/i,inside:{type:{pattern:/(backend|module|output|provider|provisioner|variable)\s+(?:[\w-]+|"(?:\\[\s\S]|[^\\"])*")\s+/i,lookbehind:!0,alias:"variable"}}},/[\w-]+(?=\s+\{)/],property:[/[-\w\.]+(?=\s*=(?!=))/,/"(?:\\[\s\S]|[^\\"])+"(?=\s*[:=])/],string:{pattern:/"(?:[^\\$"]|\\[\s\S]|\$(?:(?=")|\$+(?!\$)|[^"${])|\$\{(?:[^{}"]|"(?:[^\\"]|\\[\s\S])*")*\})*"/,greedy:!0,inside:{interpolation:{pattern:/(^|[^$])\$\{(?:[^{}"]|"(?:[^\\"]|\\[\s\S])*")*\}/,lookbehind:!0,inside:{type:{pattern:/(\b(?:count|data|local|module|path|self|terraform|var)\b\.)[\w\*]+/i,lookbehind:!0,alias:"variable"},keyword:/\b(?:count|data|local|module|path|self|terraform|var)\b/i,function:/\w+(?=\()/,string:{pattern:/"(?:\\[\s\S]|[^\\"])*"/,greedy:!0},number:/\b0x[\da-f]+\b|\b\d+(?:\.\d*)?(?:e[+-]?\d+)?/i,punctuation:/[!\$#%&'()*+,.\/;<=>@\[\\\]^`{|}~?:]/}}}},number:/\b0x[\da-f]+\b|\b\d+(?:\.\d*)?(?:e[+-]?\d+)?/i,boolean:/\b(?:false|true)\b/i,punctuation:/[=\[\]{}]/}}return hcl_1}var hlsl_1,hasRequiredHlsl;function requireHlsl(){if(hasRequiredHlsl)return hlsl_1;hasRequiredHlsl=1;var e=requireC();hlsl_1=t,t.displayName="hlsl",t.aliases=[];function t(Ye){Ye.register(e),Ye.languages.hlsl=Ye.languages.extend("c",{"class-name":[Ye.languages.c["class-name"],/\b(?:AppendStructuredBuffer|BlendState|Buffer|ByteAddressBuffer|CompileShader|ComputeShader|ConsumeStructuredBuffer|DepthStencilState|DepthStencilView|DomainShader|GeometryShader|Hullshader|InputPatch|LineStream|OutputPatch|PixelShader|PointStream|RWBuffer|RWByteAddressBuffer|RWStructuredBuffer|RWTexture(?:1D|1DArray|2D|2DArray|3D)|RasterizerState|RenderTargetView|SamplerComparisonState|SamplerState|StructuredBuffer|Texture(?:1D|1DArray|2D|2DArray|2DMS|2DMSArray|3D|Cube|CubeArray)|TriangleStream|VertexShader)\b/],keyword:[/\b(?:asm|asm_fragment|auto|break|case|catch|cbuffer|centroid|char|class|column_major|compile|compile_fragment|const|const_cast|continue|default|delete|discard|do|dynamic_cast|else|enum|explicit|export|extern|for|friend|fxgroup|goto|groupshared|if|in|inline|inout|interface|line|lineadj|linear|long|matrix|mutable|namespace|new|nointerpolation|noperspective|operator|out|packoffset|pass|pixelfragment|point|precise|private|protected|public|register|reinterpret_cast|return|row_major|sample|sampler|shared|short|signed|sizeof|snorm|stateblock|stateblock_state|static|static_cast|string|struct|switch|tbuffer|technique|technique10|technique11|template|texture|this|throw|triangle|triangleadj|try|typedef|typename|uniform|union|unorm|unsigned|using|vector|vertexfragment|virtual|void|volatile|while)\b/,/\b(?:bool|double|dword|float|half|int|min(?:10float|12int|16(?:float|int|uint))|uint)(?:[1-4](?:x[1-4])?)?\b/],number:/(?:(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[eE][+-]?\d+)?|\b0x[\da-fA-F]+)[fFhHlLuU]?\b/,boolean:/\b(?:false|true)\b/})}return hlsl_1}var hoon_1,hasRequiredHoon;function requireHoon(){if(hasRequiredHoon)return hoon_1;hasRequiredHoon=1,hoon_1=e,e.displayName="hoon",e.aliases=[];function e(t){t.languages.hoon={comment:{pattern:/::.*/,greedy:!0},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},constant:/%(?:\.[ny]|[\w-]+)/,"class-name":/@(?:[a-z0-9-]*[a-z0-9])?|\*/i,function:/(?:\+[-+] {2})?(?:[a-z](?:[a-z0-9-]*[a-z0-9])?)/,keyword:/\.[\^\+\*=\?]|![><:\.=\?!]|=[>|:,\.\-\^<+;/~\*\?]|\?[>|:\.\-\^<\+&~=@!]|\|[\$_%:\.\-\^~\*=@\?]|\+[|\$\+\*]|:[_\-\^\+~\*]|%[_:\.\-\^\+~\*=]|\^[|:\.\-\+&~\*=\?]|\$[|_%:<>\-\^&~@=\?]|;[:<\+;\/~\*=]|~[>|\$_%<\+\/&=\?!]|--|==/}}return hoon_1}var hpkp_1,hasRequiredHpkp;function requireHpkp(){if(hasRequiredHpkp)return hpkp_1;hasRequiredHpkp=1,hpkp_1=e,e.displayName="hpkp",e.aliases=[];function e(t){t.languages.hpkp={directive:{pattern:/\b(?:includeSubDomains|max-age|pin-sha256|preload|report-to|report-uri|strict)(?=[\s;=]|$)/i,alias:"property"},operator:/=/,punctuation:/;/}}return hpkp_1}var hsts_1,hasRequiredHsts;function requireHsts(){if(hasRequiredHsts)return hsts_1;hasRequiredHsts=1,hsts_1=e,e.displayName="hsts",e.aliases=[];function e(t){t.languages.hsts={directive:{pattern:/\b(?:includeSubDomains|max-age|preload)(?=[\s;=]|$)/i,alias:"property"},operator:/=/,punctuation:/;/}}return hsts_1}var http_1,hasRequiredHttp;function requireHttp(){if(hasRequiredHttp)return http_1;hasRequiredHttp=1,http_1=e,e.displayName="http",e.aliases=[];function e(t){(function(Ye){function tt(Rt){return RegExp("(^(?:"+Rt+"):[ ]*(?![ ]))[^]+","i")}Ye.languages.http={"request-line":{pattern:/^(?:CONNECT|DELETE|GET|HEAD|OPTIONS|PATCH|POST|PRI|PUT|SEARCH|TRACE)\s(?:https?:\/\/|\/)\S*\sHTTP\/[\d.]+/m,inside:{method:{pattern:/^[A-Z]+\b/,alias:"property"},"request-target":{pattern:/^(\s)(?:https?:\/\/|\/)\S*(?=\s)/,lookbehind:!0,alias:"url",inside:Ye.languages.uri},"http-version":{pattern:/^(\s)HTTP\/[\d.]+/,lookbehind:!0,alias:"property"}}},"response-status":{pattern:/^HTTP\/[\d.]+ \d+ .+/m,inside:{"http-version":{pattern:/^HTTP\/[\d.]+/,alias:"property"},"status-code":{pattern:/^(\s)\d+(?=\s)/,lookbehind:!0,alias:"number"},"reason-phrase":{pattern:/^(\s).+/,lookbehind:!0,alias:"string"}}},header:{pattern:/^[\w-]+:.+(?:(?:\r\n?|\n)[ \t].+)*/m,inside:{"header-value":[{pattern:tt(/Content-Security-Policy/.source),lookbehind:!0,alias:["csp","languages-csp"],inside:Ye.languages.csp},{pattern:tt(/Public-Key-Pins(?:-Report-Only)?/.source),lookbehind:!0,alias:["hpkp","languages-hpkp"],inside:Ye.languages.hpkp},{pattern:tt(/Strict-Transport-Security/.source),lookbehind:!0,alias:["hsts","languages-hsts"],inside:Ye.languages.hsts},{pattern:tt(/[^:]+/.source),lookbehind:!0}],"header-name":{pattern:/^[^:]+/,alias:"keyword"},punctuation:/^:/}}};var rt=Ye.languages,nt={"application/javascript":rt.javascript,"application/json":rt.json||rt.javascript,"application/xml":rt.xml,"text/xml":rt.xml,"text/html":rt.html,"text/css":rt.css,"text/plain":rt.plain},at={"application/json":!0,"application/xml":!0};function it(Rt){var qt=Rt.replace(/^[a-z]+\//,""),Ft="\\w+/(?:[\\w.-]+\\+)+"+qt+"(?![+\\w.-])";return"(?:"+Rt+"|"+Ft+")"}var ot;for(var ct in nt)if(nt[ct]){ot=ot||{};var At=at[ct]?it(ct):ct;ot[ct.replace(/\//g,"-")]={pattern:RegExp("("+/content-type:\s*/.source+At+/(?:(?:\r\n?|\n)[\w-].*)*(?:\r(?:\n|(?!\n))|\n)/.source+")"+/[^ \t\w-][\s\S]*/.source,"i"),lookbehind:!0,inside:nt[ct]}}ot&&Ye.languages.insertBefore("http","header",ot)})(t)}return http_1}var ichigojam_1,hasRequiredIchigojam;function requireIchigojam(){if(hasRequiredIchigojam)return ichigojam_1;hasRequiredIchigojam=1,ichigojam_1=e,e.displayName="ichigojam",e.aliases=[];function e(t){t.languages.ichigojam={comment:/(?:\B'|REM)(?:[^\n\r]*)/i,string:{pattern:/"(?:""|[!#$%&'()*,\/:;<=>?^\w +\-.])*"/,greedy:!0},number:/\B#[0-9A-F]+|\B`[01]+|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:E[+-]?\d+)?/i,keyword:/\b(?:BEEP|BPS|CASE|CLEAR|CLK|CLO|CLP|CLS|CLT|CLV|CONT|COPY|ELSE|END|FILE|FILES|FOR|GOSUB|GOTO|GSB|IF|INPUT|KBD|LED|LET|LIST|LOAD|LOCATE|LRUN|NEW|NEXT|OUT|PLAY|POKE|PRINT|PWM|REM|RENUM|RESET|RETURN|RIGHT|RTN|RUN|SAVE|SCROLL|SLEEP|SRND|STEP|STOP|SUB|TEMPO|THEN|TO|UART|VIDEO|WAIT)(?:\$|\b)/i,function:/\b(?:ABS|ANA|ASC|BIN|BTN|DEC|END|FREE|HELP|HEX|I2CR|I2CW|IN|INKEY|LEN|LINE|PEEK|RND|SCR|SOUND|STR|TICK|USR|VER|VPEEK|ZER)(?:\$|\b)/i,label:/(?:\B@\S+)/,operator:/<[=>]?|>=?|\|\||&&|[+\-*\/=|&^~!]|\b(?:AND|NOT|OR)\b/i,punctuation:/[\[,;:()\]]/}}return ichigojam_1}var icon_1,hasRequiredIcon;function requireIcon(){if(hasRequiredIcon)return icon_1;hasRequiredIcon=1,icon_1=e,e.displayName="icon",e.aliases=[];function e(t){t.languages.icon={comment:/#.*/,string:{pattern:/(["'])(?:(?!\1)[^\\\r\n_]|\\.|_(?!\1)(?:\r\n|[\s\S]))*\1/,greedy:!0},number:/\b(?:\d+r[a-z\d]+|\d+(?:\.\d+)?(?:e[+-]?\d+)?)\b|\.\d+\b/i,"builtin-keyword":{pattern:/&(?:allocated|ascii|clock|collections|cset|current|date|dateline|digits|dump|e|error(?:number|text|value)?|errout|fail|features|file|host|input|lcase|letters|level|line|main|null|output|phi|pi|pos|progname|random|regions|source|storage|subject|time|trace|ucase|version)\b/,alias:"variable"},directive:{pattern:/\$\w+/,alias:"builtin"},keyword:/\b(?:break|by|case|create|default|do|else|end|every|fail|global|if|initial|invocable|link|local|next|not|of|procedure|record|repeat|return|static|suspend|then|to|until|while)\b/,function:/\b(?!\d)\w+(?=\s*[({]|\s*!\s*\[)/,operator:/[+-]:(?!=)|(?:[\/?@^%&]|\+\+?|--?|==?=?|~==?=?|\*\*?|\|\|\|?|<(?:->?|<?=?)|>>?=?)(?::=)?|:(?:=:?)?|[!.\\|~]/,punctuation:/[\[\](){},;]/}}return icon_1}var icuMessageFormat_1,hasRequiredIcuMessageFormat;function requireIcuMessageFormat(){if(hasRequiredIcuMessageFormat)return icuMessageFormat_1;hasRequiredIcuMessageFormat=1,icuMessageFormat_1=e,e.displayName="icuMessageFormat",e.aliases=[];function e(t){(function(Ye){function tt(ct,At){return At<=0?/[]/.source:ct.replace(/<SELF>/g,function(){return tt(ct,At-1)})}var rt=/'[{}:=,](?:[^']|'')*'(?!')/,nt={pattern:/''/,greedy:!0,alias:"operator"},at={pattern:rt,greedy:!0,inside:{escape:nt}},it=tt(/\{(?:[^{}']|'(?![{},'])|''|<STR>|<SELF>)*\}/.source.replace(/<STR>/g,function(){return rt.source}),8),ot={pattern:RegExp(it),inside:{message:{pattern:/^(\{)[\s\S]+(?=\}$)/,lookbehind:!0,inside:null},"message-delimiter":{pattern:/./,alias:"punctuation"}}};Ye.languages["icu-message-format"]={argument:{pattern:RegExp(it),greedy:!0,inside:{content:{pattern:/^(\{)[\s\S]+(?=\}$)/,lookbehind:!0,inside:{"argument-name":{pattern:/^(\s*)[^{}:=,\s]+/,lookbehind:!0},"choice-style":{pattern:/^(\s*,\s*choice\s*,\s*)\S(?:[\s\S]*\S)?/,lookbehind:!0,inside:{punctuation:/\|/,range:{pattern:/^(\s*)[+-]?(?:\d+(?:\.\d*)?|\u221e)\s*[<#\u2264]/,lookbehind:!0,inside:{operator:/[<#\u2264]/,number:/\S+/}},rest:null}},"plural-style":{pattern:/^(\s*,\s*(?:plural|selectordinal)\s*,\s*)\S(?:[\s\S]*\S)?/,lookbehind:!0,inside:{offset:/^offset:\s*\d+/,"nested-message":ot,selector:{pattern:/=\d+|[^{}:=,\s]+/,inside:{keyword:/^(?:few|many|one|other|two|zero)$/}}}},"select-style":{pattern:/^(\s*,\s*select\s*,\s*)\S(?:[\s\S]*\S)?/,lookbehind:!0,inside:{"nested-message":ot,selector:{pattern:/[^{}:=,\s]+/,inside:{keyword:/^other$/}}}},keyword:/\b(?:choice|plural|select|selectordinal)\b/,"arg-type":{pattern:/\b(?:date|duration|number|ordinal|spellout|time)\b/,alias:"keyword"},"arg-skeleton":{pattern:/(,\s*)::[^{}:=,\s]+/,lookbehind:!0},"arg-style":{pattern:/(,\s*)(?:currency|full|integer|long|medium|percent|short)(?=\s*$)/,lookbehind:!0},"arg-style-text":{pattern:RegExp(/(^\s*,\s*(?=\S))/.source+tt(/(?:[^{}']|'[^']*'|\{(?:<SELF>)?\})+/.source,8)+"$"),lookbehind:!0,alias:"string"},punctuation:/,/}},"argument-delimiter":{pattern:/./,alias:"operator"}}},escape:nt,string:at},ot.inside.message.inside=Ye.languages["icu-message-format"],Ye.languages["icu-message-format"].argument.inside.content.inside["choice-style"].inside.rest=Ye.languages["icu-message-format"]})(t)}return icuMessageFormat_1}var idris_1,hasRequiredIdris;function requireIdris(){if(hasRequiredIdris)return idris_1;hasRequiredIdris=1;var e=requireHaskell();idris_1=t,t.displayName="idris",t.aliases=["idr"];function t(Ye){Ye.register(e),Ye.languages.idris=Ye.languages.extend("haskell",{comment:{pattern:/(?:(?:--|\|\|\|).*$|\{-[\s\S]*?-\})/m},keyword:/\b(?:Type|case|class|codata|constructor|corecord|data|do|dsl|else|export|if|implementation|implicit|import|impossible|in|infix|infixl|infixr|instance|interface|let|module|mutual|namespace|of|parameters|partial|postulate|private|proof|public|quoteGoal|record|rewrite|syntax|then|total|using|where|with)\b/,builtin:void 0}),Ye.languages.insertBefore("idris","keyword",{"import-statement":{pattern:/(^\s*import\s+)(?:[A-Z][\w']*)(?:\.[A-Z][\w']*)*/m,lookbehind:!0,inside:{punctuation:/\./}}}),Ye.languages.idr=Ye.languages.idris}return idris_1}var iecst_1,hasRequiredIecst;function requireIecst(){if(hasRequiredIecst)return iecst_1;hasRequiredIecst=1,iecst_1=e,e.displayName="iecst",e.aliases=[];function e(t){t.languages.iecst={comment:[{pattern:/(^|[^\\])(?:\/\*[\s\S]*?(?:\*\/|$)|\(\*[\s\S]*?(?:\*\)|$)|\{[\s\S]*?(?:\}|$))/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},keyword:[/\b(?:END_)?(?:PROGRAM|CONFIGURATION|INTERFACE|FUNCTION_BLOCK|FUNCTION|ACTION|TRANSITION|TYPE|STRUCT|(?:INITIAL_)?STEP|NAMESPACE|LIBRARY|CHANNEL|FOLDER|RESOURCE|VAR_(?:ACCESS|CONFIG|EXTERNAL|GLOBAL|INPUT|IN_OUT|OUTPUT|TEMP)|VAR|METHOD|PROPERTY)\b/i,/\b(?:AT|BY|(?:END_)?(?:CASE|FOR|IF|REPEAT|WHILE)|CONSTANT|CONTINUE|DO|ELSE|ELSIF|EXIT|EXTENDS|FROM|GET|GOTO|IMPLEMENTS|JMP|NON_RETAIN|OF|PRIVATE|PROTECTED|PUBLIC|RETAIN|RETURN|SET|TASK|THEN|TO|UNTIL|USING|WITH|__CATCH|__ENDTRY|__FINALLY|__TRY)\b/],"class-name":/\b(?:ANY|ARRAY|BOOL|BYTE|U?(?:D|L|S)?INT|(?:D|L)?WORD|DATE(?:_AND_TIME)?|DT|L?REAL|POINTER|STRING|TIME(?:_OF_DAY)?|TOD)\b/,address:{pattern:/%[IQM][XBWDL][\d.]*|%[IQ][\d.]*/,alias:"symbol"},number:/\b(?:16#[\da-f]+|2#[01_]+|0x[\da-f]+)\b|\b(?:D|DT|T|TOD)#[\d_shmd:]*|\b[A-Z]*#[\d.,_]*|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,boolean:/\b(?:FALSE|NULL|TRUE)\b/,operator:/S?R?:?=>?|&&?|\*\*?|<[=>]?|>=?|[-:^/+#]|\b(?:AND|EQ|EXPT|GE|GT|LE|LT|MOD|NE|NOT|OR|XOR)\b/,function:/\b[a-z_]\w*(?=\s*\()/i,punctuation:/[()[\].,;]/}}return iecst_1}var ignore_1,hasRequiredIgnore;function requireIgnore(){if(hasRequiredIgnore)return ignore_1;hasRequiredIgnore=1,ignore_1=e,e.displayName="ignore",e.aliases=["gitignore","hgignore","npmignore"];function e(t){(function(Ye){Ye.languages.ignore={comment:/^#.*/m,entry:{pattern:/\S(?:.*(?:(?:\\ )|\S))?/,alias:"string",inside:{operator:/^!|\*\*?|\?/,regex:{pattern:/(^|[^\\])\[[^\[\]]*\]/,lookbehind:!0},punctuation:/\//}}},Ye.languages.gitignore=Ye.languages.ignore,Ye.languages.hgignore=Ye.languages.ignore,Ye.languages.npmignore=Ye.languages.ignore})(t)}return ignore_1}var inform7_1,hasRequiredInform7;function requireInform7(){if(hasRequiredInform7)return inform7_1;hasRequiredInform7=1,inform7_1=e,e.displayName="inform7",e.aliases=[];function e(t){t.languages.inform7={string:{pattern:/"[^"]*"/,inside:{substitution:{pattern:/\[[^\[\]]+\]/,inside:{delimiter:{pattern:/\[|\]/,alias:"punctuation"}}}}},comment:{pattern:/\[[^\[\]]+\]/,greedy:!0},title:{pattern:/^[ \t]*(?:book|chapter|part(?! of)|section|table|volume)\b.+/im,alias:"important"},number:{pattern:/(^|[^-])(?:\b\d+(?:\.\d+)?(?:\^\d+)?(?:(?!\d)\w+)?|\b(?:eight|eleven|five|four|nine|one|seven|six|ten|three|twelve|two))\b(?!-)/i,lookbehind:!0},verb:{pattern:/(^|[^-])\b(?:answering|applying to|are|asking|attacking|be(?:ing)?|burning|buying|called|carries|carry(?! out)|carrying|climbing|closing|conceal(?:ing|s)?|consulting|contain(?:ing|s)?|cutting|drinking|dropping|eating|enclos(?:es?|ing)|entering|examining|exiting|getting|giving|going|ha(?:s|ve|ving)|hold(?:ing|s)?|impl(?:ies|y)|incorporat(?:es?|ing)|inserting|is|jumping|kissing|listening|locking|looking|mean(?:ing|s)?|opening|provid(?:es?|ing)|pulling|pushing|putting|relat(?:es?|ing)|removing|searching|see(?:ing|s)?|setting|showing|singing|sleeping|smelling|squeezing|support(?:ing|s)?|swearing|switching|taking|tasting|telling|thinking|throwing|touching|turning|tying|unlock(?:ing|s)?|var(?:ies|y|ying)|waiting|waking|waving|wear(?:ing|s)?)\b(?!-)/i,lookbehind:!0,alias:"operator"},keyword:{pattern:/(^|[^-])\b(?:after|before|carry out|check|continue the action|definition(?= *:)|do nothing|else|end (?:if|the story|unless)|every turn|if|include|instead(?: of)?|let|move|no|now|otherwise|repeat|report|resume the story|rule for|running through|say(?:ing)?|stop the action|test|try(?:ing)?|understand|unless|use|when|while|yes)\b(?!-)/i,lookbehind:!0},property:{pattern:/(^|[^-])\b(?:adjacent(?! to)|carried|closed|concealed|contained|dark|described|edible|empty|enclosed|enterable|even|female|fixed in place|full|handled|held|improper-named|incorporated|inedible|invisible|lighted|lit|lock(?:able|ed)|male|marked for listing|mentioned|negative|neuter|non-(?:empty|full|recurring)|odd|opaque|open(?:able)?|plural-named|portable|positive|privately-named|proper-named|provided|publically-named|pushable between rooms|recurring|related|rubbing|scenery|seen|singular-named|supported|swinging|switch(?:able|ed(?: off| on)?)|touch(?:able|ed)|transparent|unconcealed|undescribed|unlit|unlocked|unmarked for listing|unmentioned|unopenable|untouchable|unvisited|variable|visible|visited|wearable|worn)\b(?!-)/i,lookbehind:!0,alias:"symbol"},position:{pattern:/(^|[^-])\b(?:above|adjacent to|back side of|below|between|down|east|everywhere|front side|here|in|inside(?: from)?|north(?:east|west)?|nowhere|on(?: top of)?|other side|outside(?: from)?|parts? of|regionally in|south(?:east|west)?|through|up|west|within)\b(?!-)/i,lookbehind:!0,alias:"keyword"},type:{pattern:/(^|[^-])\b(?:actions?|activit(?:ies|y)|actors?|animals?|backdrops?|containers?|devices?|directions?|doors?|holders?|kinds?|lists?|m[ae]n|nobody|nothing|nouns?|numbers?|objects?|people|persons?|player(?:'s holdall)?|regions?|relations?|rooms?|rule(?:book)?s?|scenes?|someone|something|supporters?|tables?|texts?|things?|time|vehicles?|wom[ae]n)\b(?!-)/i,lookbehind:!0,alias:"variable"},punctuation:/[.,:;(){}]/},t.languages.inform7.string.inside.substitution.inside.rest=t.languages.inform7,t.languages.inform7.string.inside.substitution.inside.rest.text={pattern:/\S(?:\s*\S)*/,alias:"comment"}}return inform7_1}var ini_1,hasRequiredIni;function requireIni(){if(hasRequiredIni)return ini_1;hasRequiredIni=1,ini_1=e,e.displayName="ini",e.aliases=[];function e(t){t.languages.ini={comment:{pattern:/(^[ \f\t\v]*)[#;][^\n\r]*/m,lookbehind:!0},section:{pattern:/(^[ \f\t\v]*)\[[^\n\r\]]*\]?/m,lookbehind:!0,inside:{"section-name":{pattern:/(^\[[ \f\t\v]*)[^ \f\t\v\]]+(?:[ \f\t\v]+[^ \f\t\v\]]+)*/,lookbehind:!0,alias:"selector"},punctuation:/\[|\]/}},key:{pattern:/(^[ \f\t\v]*)[^ \f\n\r\t\v=]+(?:[ \f\t\v]+[^ \f\n\r\t\v=]+)*(?=[ \f\t\v]*=)/m,lookbehind:!0,alias:"attr-name"},value:{pattern:/(=[ \f\t\v]*)[^ \f\n\r\t\v]+(?:[ \f\t\v]+[^ \f\n\r\t\v]+)*/,lookbehind:!0,alias:"attr-value",inside:{"inner-value":{pattern:/^("|').+(?=\1$)/,lookbehind:!0}}},punctuation:/=/}}return ini_1}var io_1,hasRequiredIo;function requireIo(){if(hasRequiredIo)return io_1;hasRequiredIo=1,io_1=e,e.displayName="io",e.aliases=[];function e(t){t.languages.io={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?(?:\*\/|$)|\/\/.*|#.*)/,lookbehind:!0,greedy:!0},"triple-quoted-string":{pattern:/"""(?:\\[\s\S]|(?!""")[^\\])*"""/,greedy:!0,alias:"string"},string:{pattern:/"(?:\\.|[^\\\r\n"])*"/,greedy:!0},keyword:/\b(?:activate|activeCoroCount|asString|block|break|call|catch|clone|collectGarbage|compileString|continue|do|doFile|doMessage|doString|else|elseif|exit|for|foreach|forward|getEnvironmentVariable|getSlot|hasSlot|if|ifFalse|ifNil|ifNilEval|ifTrue|isActive|isNil|isResumable|list|message|method|parent|pass|pause|perform|performWithArgList|print|println|proto|raise|raiseResumable|removeSlot|resend|resume|schedulerSleepSeconds|self|sender|setSchedulerSleepSeconds|setSlot|shallowCopy|slotNames|super|system|then|thisBlock|thisContext|try|type|uniqueId|updateSlot|wait|while|write|yield)\b/,builtin:/\b(?:Array|AudioDevice|AudioMixer|BigNum|Block|Box|Buffer|CFunction|CGI|Color|Curses|DBM|DNSResolver|DOConnection|DOProxy|DOServer|Date|Directory|Duration|DynLib|Error|Exception|FFT|File|Fnmatch|Font|Future|GL|GLE|GLScissor|GLU|GLUCylinder|GLUQuadric|GLUSphere|GLUT|Host|Image|Importer|LinkList|List|Lobby|Locals|MD5|MP3Decoder|MP3Encoder|Map|Message|Movie|Notification|Number|Object|OpenGL|Point|Protos|Random|Regex|SGML|SGMLElement|SGMLParser|SQLite|Sequence|Server|ShowMessage|SleepyCat|SleepyCatCursor|Socket|SocketManager|Sound|Soup|Store|String|Tree|UDPSender|UPDReceiver|URL|User|Warning|WeakLink)\b/,boolean:/\b(?:false|nil|true)\b/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e-?\d+)?/i,operator:/[=!*/%+\-^&|]=|>>?=?|<<?=?|:?:?=|\+\+?|--?|\*\*?|\/\/?|%|\|\|?|&&?|\b(?:and|not|or|return)\b|@@?|\?\??|\.\./,punctuation:/[{}[\];(),.:]/}}return io_1}var j_1,hasRequiredJ;function requireJ(){if(hasRequiredJ)return j_1;hasRequiredJ=1,j_1=e,e.displayName="j",e.aliases=[];function e(t){t.languages.j={comment:{pattern:/\bNB\..*/,greedy:!0},string:{pattern:/'(?:''|[^'\r\n])*'/,greedy:!0},keyword:/\b(?:(?:CR|LF|adverb|conjunction|def|define|dyad|monad|noun|verb)\b|(?:assert|break|case|catch[dt]?|continue|do|else|elseif|end|fcase|for|for_\w+|goto_\w+|if|label_\w+|return|select|throw|try|while|whilst)\.)/,verb:{pattern:/(?!\^:|;\.|[=!][.:])(?:\{(?:\.|::?)?|p(?:\.\.?|:)|[=!\]]|[<>+*\-%$|,#][.:]?|[?^]\.?|[;\[]:?|[~}"i][.:]|[ACeEIjLor]\.|(?:[_\/\\qsux]|_?\d):)/,alias:"keyword"},number:/\b_?(?:(?!\d:)\d+(?:\.\d+)?(?:(?:ad|ar|[ejpx])_?\d+(?:\.\d+)?)*(?:b_?[\da-z]+(?:\.[\da-z]+)?)?|_\b(?!\.))/,adverb:{pattern:/[~}]|[\/\\]\.?|[bfM]\.|t[.:]/,alias:"builtin"},operator:/[=a][.:]|_\./,conjunction:{pattern:/&(?:\.:?|:)?|[.:@][.:]?|[!D][.:]|[;dHT]\.|`:?|[\^LS]:|"/,alias:"variable"},punctuation:/[()]/}}return j_1}var java_1,hasRequiredJava;function requireJava(){if(hasRequiredJava)return java_1;hasRequiredJava=1,java_1=e,e.displayName="java",e.aliases=[];function e(t){(function(Ye){var tt=/\b(?:abstract|assert|boolean|break|byte|case|catch|char|class|const|continue|default|do|double|else|enum|exports|extends|final|finally|float|for|goto|if|implements|import|instanceof|int|interface|long|module|native|new|non-sealed|null|open|opens|package|permits|private|protected|provides|public|record|requires|return|sealed|short|static|strictfp|super|switch|synchronized|this|throw|throws|to|transient|transitive|try|uses|var|void|volatile|while|with|yield)\b/,rt=/(^|[^\w.])(?:[a-z]\w*\s*\.\s*)*(?:[A-Z]\w*\s*\.\s*)*/.source,nt={pattern:RegExp(rt+/[A-Z](?:[\d_A-Z]*[a-z]\w*)?\b/.source),lookbehind:!0,inside:{namespace:{pattern:/^[a-z]\w*(?:\s*\.\s*[a-z]\w*)*(?:\s*\.)?/,inside:{punctuation:/\./}},punctuation:/\./}};Ye.languages.java=Ye.languages.extend("clike",{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"/,lookbehind:!0,greedy:!0},"class-name":[nt,{pattern:RegExp(rt+/[A-Z]\w*(?=\s+\w+\s*[;,=()])/.source),lookbehind:!0,inside:nt.inside}],keyword:tt,function:[Ye.languages.clike.function,{pattern:/(::\s*)[a-z_]\w*/,lookbehind:!0}],number:/\b0b[01][01_]*L?\b|\b0x(?:\.[\da-f_p+-]+|[\da-f_]+(?:\.[\da-f_p+-]+)?)\b|(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?\d[\d_]*)?[dfl]?/i,operator:{pattern:/(^|[^.])(?:<<=?|>>>?=?|->|--|\+\+|&&|\|\||::|[?:~]|[-+*/%&|^!=<>]=?)/m,lookbehind:!0}}),Ye.languages.insertBefore("java","string",{"triple-quoted-string":{pattern:/"""[ \t]*[\r\n](?:(?:"|"")?(?:\\.|[^"\\]))*"""/,greedy:!0,alias:"string"},char:{pattern:/'(?:\\.|[^'\\\r\n]){1,6}'/,greedy:!0}}),Ye.languages.insertBefore("java","class-name",{annotation:{pattern:/(^|[^.])@\w+(?:\s*\.\s*\w+)*/,lookbehind:!0,alias:"punctuation"},generics:{pattern:/<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&))*>)*>)*>)*>/,inside:{"class-name":nt,keyword:tt,punctuation:/[<>(),.:]/,operator:/[?&|]/}},namespace:{pattern:RegExp(/(\b(?:exports|import(?:\s+static)?|module|open|opens|package|provides|requires|to|transitive|uses|with)\s+)(?!<keyword>)[a-z]\w*(?:\.[a-z]\w*)*\.?/.source.replace(/<keyword>/g,function(){return tt.source})),lookbehind:!0,inside:{punctuation:/\./}}})})(t)}return java_1}var javadoclike_1,hasRequiredJavadoclike;function requireJavadoclike(){if(hasRequiredJavadoclike)return javadoclike_1;hasRequiredJavadoclike=1,javadoclike_1=e,e.displayName="javadoclike",e.aliases=[];function e(t){(function(Ye){var tt=Ye.languages.javadoclike={parameter:{pattern:/(^[\t ]*(?:\/{3}|\*|\/\*\*)\s*@(?:arg|arguments|param)\s+)\w+/m,lookbehind:!0},keyword:{pattern:/(^[\t ]*(?:\/{3}|\*|\/\*\*)\s*|\{)@[a-z][a-zA-Z-]+\b/m,lookbehind:!0},punctuation:/[{}]/};function rt(at,it){var ot="doc-comment",ct=Ye.languages[at];if(ct){var At=ct[ot];if(!At){var Rt={};Rt[ot]={pattern:/(^|[^\\])\/\*\*[^/][\s\S]*?(?:\*\/|$)/,lookbehind:!0,alias:"comment"},ct=Ye.languages.insertBefore(at,"comment",Rt),At=ct[ot]}if(At instanceof RegExp&&(At=ct[ot]={pattern:At}),Array.isArray(At))for(var qt=0,Ft=At.length;qt<Ft;qt++)At[qt]instanceof RegExp&&(At[qt]={pattern:At[qt]}),it(At[qt]);else it(At)}}function nt(at,it){typeof at=="string"&&(at=[at]),at.forEach(function(ot){rt(ot,function(ct){ct.inside||(ct.inside={}),ct.inside.rest=it})})}Object.defineProperty(tt,"addSupport",{value:nt}),tt.addSupport(["java","javascript","php"],tt)})(t)}return javadoclike_1}var javadoc_1,hasRequiredJavadoc;function requireJavadoc(){if(hasRequiredJavadoc)return javadoc_1;hasRequiredJavadoc=1;var e=requireJava(),t=requireJavadoclike();javadoc_1=Ye,Ye.displayName="javadoc",Ye.aliases=[];function Ye(tt){tt.register(e),tt.register(t),function(rt){var nt=/(^(?:[\t ]*(?:\*\s*)*))[^*\s].*$/m,at=/#\s*\w+(?:\s*\([^()]*\))?/.source,it=/(?:\b[a-zA-Z]\w+\s*\.\s*)*\b[A-Z]\w*(?:\s*<mem>)?|<mem>/.source.replace(/<mem>/g,function(){return at});rt.languages.javadoc=rt.languages.extend("javadoclike",{}),rt.languages.insertBefore("javadoc","keyword",{reference:{pattern:RegExp(/(@(?:exception|link|linkplain|see|throws|value)\s+(?:\*\s*)?)/.source+"(?:"+it+")"),lookbehind:!0,inside:{function:{pattern:/(#\s*)\w+(?=\s*\()/,lookbehind:!0},field:{pattern:/(#\s*)\w+/,lookbehind:!0},namespace:{pattern:/\b(?:[a-z]\w*\s*\.\s*)+/,inside:{punctuation:/\./}},"class-name":/\b[A-Z]\w*/,keyword:rt.languages.java.keyword,punctuation:/[#()[\],.]/}},"class-name":{pattern:/(@param\s+)<[A-Z]\w*>/,lookbehind:!0,inside:{punctuation:/[.<>]/}},"code-section":[{pattern:/(\{@code\s+(?!\s))(?:[^\s{}]|\s+(?![\s}])|\{(?:[^{}]|\{(?:[^{}]|\{(?:[^{}]|\{[^{}]*\})*\})*\})*\})+(?=\s*\})/,lookbehind:!0,inside:{code:{pattern:nt,lookbehind:!0,inside:rt.languages.java,alias:"language-java"}}},{pattern:/(<(code|pre|tt)>(?!<code>)\s*)\S(?:\S|\s+\S)*?(?=\s*<\/\2>)/,lookbehind:!0,inside:{line:{pattern:nt,lookbehind:!0,inside:{tag:rt.languages.markup.tag,entity:rt.languages.markup.entity,code:{pattern:/.+/,inside:rt.languages.java,alias:"language-java"}}}}}],tag:rt.languages.markup.tag,entity:rt.languages.markup.entity}),rt.languages.javadoclike.addSupport("java",rt.languages.javadoc)}(tt)}return javadoc_1}var javastacktrace_1,hasRequiredJavastacktrace;function requireJavastacktrace(){if(hasRequiredJavastacktrace)return javastacktrace_1;hasRequiredJavastacktrace=1,javastacktrace_1=e,e.displayName="javastacktrace",e.aliases=[];function e(t){t.languages.javastacktrace={summary:{pattern:/^([\t ]*)(?:(?:Caused by:|Suppressed:|Exception in thread "[^"]*")[\t ]+)?[\w$.]+(?::.*)?$/m,lookbehind:!0,inside:{keyword:{pattern:/^([\t ]*)(?:(?:Caused by|Suppressed)(?=:)|Exception in thread)/m,lookbehind:!0},string:{pattern:/^(\s*)"[^"]*"/,lookbehind:!0},exceptions:{pattern:/^(:?\s*)[\w$.]+(?=:|$)/,lookbehind:!0,inside:{"class-name":/[\w$]+$/,namespace:/\b[a-z]\w*\b/,punctuation:/\./}},message:{pattern:/(:\s*)\S.*/,lookbehind:!0,alias:"string"},punctuation:/:/}},"stack-frame":{pattern:/^([\t ]*)at (?:[\w$./]|@[\w$.+-]*\/)+(?:<init>)?\([^()]*\)/m,lookbehind:!0,inside:{keyword:{pattern:/^(\s*)at(?= )/,lookbehind:!0},source:[{pattern:/(\()\w+\.\w+:\d+(?=\))/,lookbehind:!0,inside:{file:/^\w+\.\w+/,punctuation:/:/,"line-number":{pattern:/\b\d+\b/,alias:"number"}}},{pattern:/(\()[^()]*(?=\))/,lookbehind:!0,inside:{keyword:/^(?:Native Method|Unknown Source)$/}}],"class-name":/[\w$]+(?=\.(?:<init>|[\w$]+)\()/,function:/(?:<init>|[\w$]+)(?=\()/,"class-loader":{pattern:/(\s)[a-z]\w*(?:\.[a-z]\w*)*(?=\/[\w@$.]*\/)/,lookbehind:!0,alias:"namespace",inside:{punctuation:/\./}},module:{pattern:/([\s/])[a-z]\w*(?:\.[a-z]\w*)*(?:@[\w$.+-]*)?(?=\/)/,lookbehind:!0,inside:{version:{pattern:/(@)[\s\S]+/,lookbehind:!0,alias:"number"},punctuation:/[@.]/}},namespace:{pattern:/(?:\b[a-z]\w*\.)+/,inside:{punctuation:/\./}},punctuation:/[()/.]/}},more:{pattern:/^([\t ]*)\.{3} \d+ [a-z]+(?: [a-z]+)*/m,lookbehind:!0,inside:{punctuation:/\.{3}/,number:/\d+/,keyword:/\b[a-z]+(?: [a-z]+)*\b/}}}}return javastacktrace_1}var jexl_1,hasRequiredJexl;function requireJexl(){if(hasRequiredJexl)return jexl_1;hasRequiredJexl=1,jexl_1=e,e.displayName="jexl",e.aliases=[];function e(t){t.languages.jexl={string:/(["'])(?:\\[\s\S]|(?!\1)[^\\])*\1/,transform:{pattern:/(\|\s*)[a-zA-Zа-яА-Я_\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u00FF$][\wа-яА-Я\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u00FF$]*/,alias:"function",lookbehind:!0},function:/[a-zA-Zа-яА-Я_\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u00FF$][\wа-яА-Я\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u00FF$]*\s*(?=\()/,number:/\b\d+(?:\.\d+)?\b|\B\.\d+\b/,operator:/[<>!]=?|-|\+|&&|==|\|\|?|\/\/?|[?:*^%]/,boolean:/\b(?:false|true)\b/,keyword:/\bin\b/,punctuation:/[{}[\](),.]/}}return jexl_1}var jolie_1,hasRequiredJolie;function requireJolie(){if(hasRequiredJolie)return jolie_1;hasRequiredJolie=1,jolie_1=e,e.displayName="jolie",e.aliases=[];function e(t){t.languages.jolie=t.languages.extend("clike",{string:{pattern:/(^|[^\\])"(?:\\[\s\S]|[^"\\])*"/,lookbehind:!0,greedy:!0},"class-name":{pattern:/((?:\b(?:as|courier|embed|in|inputPort|outputPort|service)\b|@)[ \t]*)\w+/,lookbehind:!0},keyword:/\b(?:as|cH|comp|concurrent|constants|courier|cset|csets|default|define|else|embed|embedded|execution|exit|extender|for|foreach|forward|from|global|if|import|in|include|init|inputPort|install|instanceof|interface|is_defined|linkIn|linkOut|main|new|nullProcess|outputPort|over|private|provide|public|scope|sequential|service|single|spawn|synchronized|this|throw|throws|type|undef|until|while|with)\b/,function:/\b[a-z_]\w*(?=[ \t]*[@(])/i,number:/(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?l?/i,operator:/-[-=>]?|\+[+=]?|<[<=]?|[>=*!]=?|&&|\|\||[?\/%^@|]/,punctuation:/[()[\]{},;.:]/,builtin:/\b(?:Byte|any|bool|char|double|enum|float|int|length|long|ranges|regex|string|undefined|void)\b/}),t.languages.insertBefore("jolie","keyword",{aggregates:{pattern:/(\bAggregates\s*:\s*)(?:\w+(?:\s+with\s+\w+)?\s*,\s*)*\w+(?:\s+with\s+\w+)?/,lookbehind:!0,inside:{keyword:/\bwith\b/,"class-name":/\w+/,punctuation:/,/}},redirects:{pattern:/(\bRedirects\s*:\s*)(?:\w+\s*=>\s*\w+\s*,\s*)*(?:\w+\s*=>\s*\w+)/,lookbehind:!0,inside:{punctuation:/,/,"class-name":/\w+/,operator:/=>/}},property:{pattern:/\b(?:Aggregates|[Ii]nterfaces|Java|Javascript|Jolie|[Ll]ocation|OneWay|[Pp]rotocol|Redirects|RequestResponse)\b(?=[ \t]*:)/}})}return jolie_1}var jq_1,hasRequiredJq;function requireJq(){if(hasRequiredJq)return jq_1;hasRequiredJq=1,jq_1=e,e.displayName="jq",e.aliases=[];function e(t){(function(Ye){var tt=/\\\((?:[^()]|\([^()]*\))*\)/.source,rt=RegExp(/(^|[^\\])"(?:[^"\r\n\\]|\\[^\r\n(]|__)*"/.source.replace(/__/g,function(){return tt})),nt={interpolation:{pattern:RegExp(/((?:^|[^\\])(?:\\{2})*)/.source+tt),lookbehind:!0,inside:{content:{pattern:/^(\\\()[\s\S]+(?=\)$)/,lookbehind:!0,inside:null},punctuation:/^\\\(|\)$/}}},at=Ye.languages.jq={comment:/#.*/,property:{pattern:RegExp(rt.source+/(?=\s*:(?!:))/.source),lookbehind:!0,greedy:!0,inside:nt},string:{pattern:rt,lookbehind:!0,greedy:!0,inside:nt},function:{pattern:/(\bdef\s+)[a-z_]\w+/i,lookbehind:!0},variable:/\B\$\w+/,"property-literal":{pattern:/\b[a-z_]\w*(?=\s*:(?!:))/i,alias:"property"},keyword:/\b(?:as|break|catch|def|elif|else|end|foreach|if|import|include|label|module|modulemeta|null|reduce|then|try|while)\b/,boolean:/\b(?:false|true)\b/,number:/(?:\b\d+\.|\B\.)?\b\d+(?:[eE][+-]?\d+)?\b/,operator:[{pattern:/\|=?/,alias:"pipe"},/\.\.|[!=<>]?=|\?\/\/|\/\/=?|[-+*/%]=?|[<>?]|\b(?:and|not|or)\b/],"c-style-function":{pattern:/\b[a-z_]\w*(?=\s*\()/i,alias:"function"},punctuation:/::|[()\[\]{},:;]|\.(?=\s*[\[\w$])/,dot:{pattern:/\./,alias:"important"}};nt.interpolation.inside.content.inside=at})(t)}return jq_1}var jsExtras_1,hasRequiredJsExtras;function requireJsExtras(){if(hasRequiredJsExtras)return jsExtras_1;hasRequiredJsExtras=1,jsExtras_1=e,e.displayName="jsExtras",e.aliases=[];function e(t){(function(Ye){Ye.languages.insertBefore("javascript","function-variable",{"method-variable":{pattern:RegExp("(\\.\\s*)"+Ye.languages.javascript["function-variable"].pattern.source),lookbehind:!0,alias:["function-variable","method","function","property-access"]}}),Ye.languages.insertBefore("javascript","function",{method:{pattern:RegExp("(\\.\\s*)"+Ye.languages.javascript.function.source),lookbehind:!0,alias:["function","property-access"]}}),Ye.languages.insertBefore("javascript","constant",{"known-class-name":[{pattern:/\b(?:(?:Float(?:32|64)|(?:Int|Uint)(?:8|16|32)|Uint8Clamped)?Array|ArrayBuffer|BigInt|Boolean|DataView|Date|Error|Function|Intl|JSON|(?:Weak)?(?:Map|Set)|Math|Number|Object|Promise|Proxy|Reflect|RegExp|String|Symbol|WebAssembly)\b/,alias:"class-name"},{pattern:/\b(?:[A-Z]\w*)Error\b/,alias:"class-name"}]});function tt(ct,At){return RegExp(ct.replace(/<ID>/g,function(){return/(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*/.source}),At)}Ye.languages.insertBefore("javascript","keyword",{imports:{pattern:tt(/(\bimport\b\s*)(?:<ID>(?:\s*,\s*(?:\*\s*as\s+<ID>|\{[^{}]*\}))?|\*\s*as\s+<ID>|\{[^{}]*\})(?=\s*\bfrom\b)/.source),lookbehind:!0,inside:Ye.languages.javascript},exports:{pattern:tt(/(\bexport\b\s*)(?:\*(?:\s*as\s+<ID>)?(?=\s*\bfrom\b)|\{[^{}]*\})/.source),lookbehind:!0,inside:Ye.languages.javascript}}),Ye.languages.javascript.keyword.unshift({pattern:/\b(?:as|default|export|from|import)\b/,alias:"module"},{pattern:/\b(?:await|break|catch|continue|do|else|finally|for|if|return|switch|throw|try|while|yield)\b/,alias:"control-flow"},{pattern:/\bnull\b/,alias:["null","nil"]},{pattern:/\bundefined\b/,alias:"nil"}),Ye.languages.insertBefore("javascript","operator",{spread:{pattern:/\.{3}/,alias:"operator"},arrow:{pattern:/=>/,alias:"operator"}}),Ye.languages.insertBefore("javascript","punctuation",{"property-access":{pattern:tt(/(\.\s*)#?<ID>/.source),lookbehind:!0},"maybe-class-name":{pattern:/(^|[^$\w\xA0-\uFFFF])[A-Z][$\w\xA0-\uFFFF]+/,lookbehind:!0},dom:{pattern:/\b(?:document|(?:local|session)Storage|location|navigator|performance|window)\b/,alias:"variable"},console:{pattern:/\bconsole(?=\s*\.)/,alias:"class-name"}});for(var rt=["function","function-variable","method","method-variable","property-access"],nt=0;nt<rt.length;nt++){var at=rt[nt],it=Ye.languages.javascript[at];Ye.util.type(it)==="RegExp"&&(it=Ye.languages.javascript[at]={pattern:it});var ot=it.inside||{};it.inside=ot,ot["maybe-class-name"]=/^[A-Z][\s\S]*/}})(t)}return jsExtras_1}var jsTemplates_1,hasRequiredJsTemplates;function requireJsTemplates(){if(hasRequiredJsTemplates)return jsTemplates_1;hasRequiredJsTemplates=1,jsTemplates_1=e,e.displayName="jsTemplates",e.aliases=[];function e(t){(function(Ye){var tt=Ye.languages.javascript["template-string"],rt=tt.pattern.source,nt=tt.inside.interpolation,at=nt.inside["interpolation-punctuation"],it=nt.pattern.source;function ot(Ht,zt){if(Ye.languages[Ht])return{pattern:RegExp("((?:"+zt+")\\s*)"+rt),lookbehind:!0,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},"embedded-code":{pattern:/[\s\S]+/,alias:Ht}}}}Ye.languages.javascript["template-string"]=[ot("css",/\b(?:styled(?:\([^)]*\))?(?:\s*\.\s*\w+(?:\([^)]*\))*)*|css(?:\s*\.\s*(?:global|resolve))?|createGlobalStyle|keyframes)/.source),ot("html",/\bhtml|\.\s*(?:inner|outer)HTML\s*\+?=/.source),ot("svg",/\bsvg/.source),ot("markdown",/\b(?:markdown|md)/.source),ot("graphql",/\b(?:gql|graphql(?:\s*\.\s*experimental)?)/.source),ot("sql",/\bsql/.source),tt].filter(Boolean);function ct(Ht,zt){return"___"+zt.toUpperCase()+"_"+Ht+"___"}function At(Ht,zt,Yt){var Gt={code:Ht,grammar:zt,language:Yt};return Ye.hooks.run("before-tokenize",Gt),Gt.tokens=Ye.tokenize(Gt.code,Gt.grammar),Ye.hooks.run("after-tokenize",Gt),Gt.tokens}function Rt(Ht){var zt={};zt["interpolation-punctuation"]=at;var Yt=Ye.tokenize(Ht,zt);if(Yt.length===3){var Gt=[1,1];Gt.push.apply(Gt,At(Yt[1],Ye.languages.javascript,"javascript")),Yt.splice.apply(Yt,Gt)}return new Ye.Token("interpolation",Yt,nt.alias,Ht)}function qt(Ht,zt,Yt){var Gt=Ye.tokenize(Ht,{interpolation:{pattern:RegExp(it),lookbehind:!0}}),Vt=0,Zt={},Xt=Gt.map(function(ar){if(typeof ar=="string")return ar;for(var sr=ar.content,lr;Ht.indexOf(lr=ct(Vt++,Yt))!==-1;);return Zt[lr]=sr,lr}).join(""),Qt=At(Xt,zt,Yt),er=Object.keys(Zt);Vt=0;function nr(ar){for(var sr=0;sr<ar.length;sr++){if(Vt>=er.length)return;var lr=ar[sr];if(typeof lr=="string"||typeof lr.content=="string"){var fr=er[Vt],gr=typeof lr=="string"?lr:lr.content,dr=gr.indexOf(fr);if(dr!==-1){++Vt;var vr=gr.substring(0,dr),mr=Rt(Zt[fr]),Er=gr.substring(dr+fr.length),_r=[];if(vr&&_r.push(vr),_r.push(mr),Er){var Tr=[Er];nr(Tr),_r.push.apply(_r,Tr)}typeof lr=="string"?(ar.splice.apply(ar,[sr,1].concat(_r)),sr+=_r.length-1):lr.content=_r}}else{var ur=lr.content;Array.isArray(ur)?nr(ur):nr([ur])}}}return nr(Qt),new Ye.Token(Yt,Qt,"language-"+Yt,Ht)}var Ft={javascript:!0,js:!0,typescript:!0,ts:!0,jsx:!0,tsx:!0};Ye.hooks.add("after-tokenize",function(Ht){if(!(Ht.language in Ft))return;function zt(Yt){for(var Gt=0,Vt=Yt.length;Gt<Vt;Gt++){var Zt=Yt[Gt];if(typeof Zt!="string"){var Xt=Zt.content;if(!Array.isArray(Xt)){typeof Xt!="string"&&zt([Xt]);continue}if(Zt.type==="template-string"){var Qt=Xt[1];if(Xt.length===3&&typeof Qt!="string"&&Qt.type==="embedded-code"){var er=Ut(Qt),nr=Qt.alias,ar=Array.isArray(nr)?nr[0]:nr,sr=Ye.languages[ar];if(!sr)continue;Xt[1]=qt(er,sr,ar)}}else zt(Xt)}}}zt(Ht.tokens)});function Ut(Ht){return typeof Ht=="string"?Ht:Array.isArray(Ht)?Ht.map(Ut).join(""):Ut(Ht.content)}})(t)}return jsTemplates_1}var typescript_1,hasRequiredTypescript;function requireTypescript(){if(hasRequiredTypescript)return typescript_1;hasRequiredTypescript=1,typescript_1=e,e.displayName="typescript",e.aliases=["ts"];function e(t){(function(Ye){Ye.languages.typescript=Ye.languages.extend("javascript",{"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|type)\s+)(?!keyof\b)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?:\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>)?/,lookbehind:!0,greedy:!0,inside:null},builtin:/\b(?:Array|Function|Promise|any|boolean|console|never|number|string|symbol|unknown)\b/}),Ye.languages.typescript.keyword.push(/\b(?:abstract|declare|is|keyof|readonly|require)\b/,/\b(?:asserts|infer|interface|module|namespace|type)\b(?=\s*(?:[{_$a-zA-Z\xA0-\uFFFF]|$))/,/\btype\b(?=\s*(?:[\{*]|$))/),delete Ye.languages.typescript.parameter,delete Ye.languages.typescript["literal-property"];var tt=Ye.languages.extend("typescript",{});delete tt["class-name"],Ye.languages.typescript["class-name"].inside=tt,Ye.languages.insertBefore("typescript","function",{decorator:{pattern:/@[$\w\xA0-\uFFFF]+/,inside:{at:{pattern:/^@/,alias:"operator"},function:/^[\s\S]+/}},"generic-function":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>(?=\s*\()/,greedy:!0,inside:{function:/^#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*/,generic:{pattern:/<[\s\S]+/,alias:"class-name",inside:tt}}}}),Ye.languages.ts=Ye.languages.typescript})(t)}return typescript_1}var jsdoc_1,hasRequiredJsdoc;function requireJsdoc(){if(hasRequiredJsdoc)return jsdoc_1;hasRequiredJsdoc=1;var e=requireJavadoclike(),t=requireTypescript();jsdoc_1=Ye,Ye.displayName="jsdoc",Ye.aliases=[];function Ye(tt){tt.register(e),tt.register(t),function(rt){var nt=rt.languages.javascript,at=/\{(?:[^{}]|\{(?:[^{}]|\{[^{}]*\})*\})+\}/.source,it="(@(?:arg|argument|param|property)\\s+(?:"+at+"\\s+)?)";rt.languages.jsdoc=rt.languages.extend("javadoclike",{parameter:{pattern:RegExp(it+/(?:(?!\s)[$\w\xA0-\uFFFF.])+(?=\s|$)/.source),lookbehind:!0,inside:{punctuation:/\./}}}),rt.languages.insertBefore("jsdoc","keyword",{"optional-parameter":{pattern:RegExp(it+/\[(?:(?!\s)[$\w\xA0-\uFFFF.])+(?:=[^[\]]+)?\](?=\s|$)/.source),lookbehind:!0,inside:{parameter:{pattern:/(^\[)[$\w\xA0-\uFFFF\.]+/,lookbehind:!0,inside:{punctuation:/\./}},code:{pattern:/(=)[\s\S]*(?=\]$)/,lookbehind:!0,inside:nt,alias:"language-javascript"},punctuation:/[=[\]]/}},"class-name":[{pattern:RegExp(/(@(?:augments|class|extends|interface|memberof!?|template|this|typedef)\s+(?:<TYPE>\s+)?)[A-Z]\w*(?:\.[A-Z]\w*)*/.source.replace(/<TYPE>/g,function(){return at})),lookbehind:!0,inside:{punctuation:/\./}},{pattern:RegExp("(@[a-z]+\\s+)"+at),lookbehind:!0,inside:{string:nt.string,number:nt.number,boolean:nt.boolean,keyword:rt.languages.typescript.keyword,operator:/=>|\.\.\.|[&|?:*]/,punctuation:/[.,;=<>{}()[\]]/}}],example:{pattern:/(@example\s+(?!\s))(?:[^@\s]|\s+(?!\s))+?(?=\s*(?:\*\s*)?(?:@\w|\*\/))/,lookbehind:!0,inside:{code:{pattern:/^([\t ]*(?:\*\s*)?)\S.*$/m,lookbehind:!0,inside:nt,alias:"language-javascript"}}}}),rt.languages.javadoclike.addSupport("javascript",rt.languages.jsdoc)}(tt)}return jsdoc_1}var json_1,hasRequiredJson$1;function requireJson$1(){if(hasRequiredJson$1)return json_1;hasRequiredJson$1=1,json_1=e,e.displayName="json",e.aliases=["webmanifest"];function e(t){t.languages.json={property:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?=\s*:)/,lookbehind:!0,greedy:!0},string:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"(?!\s*:)/,lookbehind:!0,greedy:!0},comment:{pattern:/\/\/.*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},number:/-?\b\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i,punctuation:/[{}[\],]/,operator:/:/,boolean:/\b(?:false|true)\b/,null:{pattern:/\bnull\b/,alias:"keyword"}},t.languages.webmanifest=t.languages.json}return json_1}var json5_1,hasRequiredJson5;function requireJson5(){if(hasRequiredJson5)return json5_1;hasRequiredJson5=1;var e=requireJson$1();json5_1=t,t.displayName="json5",t.aliases=[];function t(Ye){Ye.register(e),function(tt){var rt=/("|')(?:\\(?:\r\n?|\n|.)|(?!\1)[^\\\r\n])*\1/;tt.languages.json5=tt.languages.extend("json",{property:[{pattern:RegExp(rt.source+"(?=\\s*:)"),greedy:!0},{pattern:/(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/,alias:"unquoted"}],string:{pattern:rt,greedy:!0},number:/[+-]?\b(?:NaN|Infinity|0x[a-fA-F\d]+)\b|[+-]?(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[eE][+-]?\d+\b)?/})}(Ye)}return json5_1}var jsonp_1,hasRequiredJsonp;function requireJsonp(){if(hasRequiredJsonp)return jsonp_1;hasRequiredJsonp=1;var e=requireJson$1();jsonp_1=t,t.displayName="jsonp",t.aliases=[];function t(Ye){Ye.register(e),Ye.languages.jsonp=Ye.languages.extend("json",{punctuation:/[{}[\]();,.]/}),Ye.languages.insertBefore("jsonp","punctuation",{function:/(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*\()/})}return jsonp_1}var jsstacktrace_1,hasRequiredJsstacktrace;function requireJsstacktrace(){if(hasRequiredJsstacktrace)return jsstacktrace_1;hasRequiredJsstacktrace=1,jsstacktrace_1=e,e.displayName="jsstacktrace",e.aliases=[];function e(t){t.languages.jsstacktrace={"error-message":{pattern:/^\S.*/m,alias:"string"},"stack-frame":{pattern:/(^[ \t]+)at[ \t].*/m,lookbehind:!0,inside:{"not-my-code":{pattern:/^at[ \t]+(?!\s)(?:node\.js|<unknown>|.*(?:node_modules|\(<anonymous>\)|\(<unknown>|<anonymous>$|\(internal\/|\(node\.js)).*/m,alias:"comment"},filename:{pattern:/(\bat\s+(?!\s)|\()(?:[a-zA-Z]:)?[^():]+(?=:)/,lookbehind:!0,alias:"url"},function:{pattern:/(\bat\s+(?:new\s+)?)(?!\s)[_$a-zA-Z\xA0-\uFFFF<][.$\w\xA0-\uFFFF<>]*/,lookbehind:!0,inside:{punctuation:/\./}},punctuation:/[()]/,keyword:/\b(?:at|new)\b/,alias:{pattern:/\[(?:as\s+)?(?!\s)[_$a-zA-Z\xA0-\uFFFF][$\w\xA0-\uFFFF]*\]/,alias:"variable"},"line-number":{pattern:/:\d+(?::\d+)?\b/,alias:"number",inside:{punctuation:/:/}}}}}}return jsstacktrace_1}var jsx_1,hasRequiredJsx;function requireJsx(){if(hasRequiredJsx)return jsx_1;hasRequiredJsx=1,jsx_1=e,e.displayName="jsx",e.aliases=[];function e(t){(function(Ye){var tt=Ye.util.clone(Ye.languages.javascript),rt=/(?:\s|\/\/.*(?!.)|\/\*(?:[^*]|\*(?!\/))\*\/)/.source,nt=/(?:\{(?:\{(?:\{[^{}]*\}|[^{}])*\}|[^{}])*\})/.source,at=/(?:\{<S>*\.{3}(?:[^{}]|<BRACES>)*\})/.source;function it(At,Rt){return At=At.replace(/<S>/g,function(){return rt}).replace(/<BRACES>/g,function(){return nt}).replace(/<SPREAD>/g,function(){return at}),RegExp(At,Rt)}at=it(at).source,Ye.languages.jsx=Ye.languages.extend("markup",tt),Ye.languages.jsx.tag.pattern=it(/<\/?(?:[\w.:-]+(?:<S>+(?:[\w.:$-]+(?:=(?:"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*'|[^\s{'"/>=]+|<BRACES>))?|<SPREAD>))*<S>*\/?)?>/.source),Ye.languages.jsx.tag.inside.tag.pattern=/^<\/?[^\s>\/]*/,Ye.languages.jsx.tag.inside["attr-value"].pattern=/=(?!\{)(?:"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*'|[^\s'">]+)/,Ye.languages.jsx.tag.inside.tag.inside["class-name"]=/^[A-Z]\w*(?:\.[A-Z]\w*)*$/,Ye.languages.jsx.tag.inside.comment=tt.comment,Ye.languages.insertBefore("inside","attr-name",{spread:{pattern:it(/<SPREAD>/.source),inside:Ye.languages.jsx}},Ye.languages.jsx.tag),Ye.languages.insertBefore("inside","special-attr",{script:{pattern:it(/=<BRACES>/.source),alias:"language-javascript",inside:{"script-punctuation":{pattern:/^=(?=\{)/,alias:"punctuation"},rest:Ye.languages.jsx}}},Ye.languages.jsx.tag);var ot=function(At){return At?typeof At=="string"?At:typeof At.content=="string"?At.content:At.content.map(ot).join(""):""},ct=function(At){for(var Rt=[],qt=0;qt<At.length;qt++){var Ft=At[qt],Ut=!1;if(typeof Ft!="string"&&(Ft.type==="tag"&&Ft.content[0]&&Ft.content[0].type==="tag"?Ft.content[0].content[0].content==="</"?Rt.length>0&&Rt[Rt.length-1].tagName===ot(Ft.content[0].content[1])&&Rt.pop():Ft.content[Ft.content.length-1].content==="/>"||Rt.push({tagName:ot(Ft.content[0].content[1]),openedBraces:0}):Rt.length>0&&Ft.type==="punctuation"&&Ft.content==="{"?Rt[Rt.length-1].openedBraces++:Rt.length>0&&Rt[Rt.length-1].openedBraces>0&&Ft.type==="punctuation"&&Ft.content==="}"?Rt[Rt.length-1].openedBraces--:Ut=!0),(Ut||typeof Ft=="string")&&Rt.length>0&&Rt[Rt.length-1].openedBraces===0){var Ht=ot(Ft);qt<At.length-1&&(typeof At[qt+1]=="string"||At[qt+1].type==="plain-text")&&(Ht+=ot(At[qt+1]),At.splice(qt+1,1)),qt>0&&(typeof At[qt-1]=="string"||At[qt-1].type==="plain-text")&&(Ht=ot(At[qt-1])+Ht,At.splice(qt-1,1),qt--),At[qt]=new Ye.Token("plain-text",Ht,null,Ht)}Ft.content&&typeof Ft.content!="string"&&ct(Ft.content)}};Ye.hooks.add("after-tokenize",function(At){At.language!=="jsx"&&At.language!=="tsx"||ct(At.tokens)})})(t)}return jsx_1}var julia_1,hasRequiredJulia;function requireJulia(){if(hasRequiredJulia)return julia_1;hasRequiredJulia=1,julia_1=e,e.displayName="julia",e.aliases=[];function e(t){t.languages.julia={comment:{pattern:/(^|[^\\])(?:#=(?:[^#=]|=(?!#)|#(?!=)|#=(?:[^#=]|=(?!#)|#(?!=))*=#)*=#|#.*)/,lookbehind:!0},regex:{pattern:/r"(?:\\.|[^"\\\r\n])*"[imsx]{0,4}/,greedy:!0},string:{pattern:/"""[\s\S]+?"""|(?:\b\w+)?"(?:\\.|[^"\\\r\n])*"|`(?:[^\\`\r\n]|\\.)*`/,greedy:!0},char:{pattern:/(^|[^\w'])'(?:\\[^\r\n][^'\r\n]*|[^\\\r\n])'/,lookbehind:!0,greedy:!0},keyword:/\b(?:abstract|baremodule|begin|bitstype|break|catch|ccall|const|continue|do|else|elseif|end|export|finally|for|function|global|if|immutable|import|importall|in|let|local|macro|module|print|println|quote|return|struct|try|type|typealias|using|while)\b/,boolean:/\b(?:false|true)\b/,number:/(?:\b(?=\d)|\B(?=\.))(?:0[box])?(?:[\da-f]+(?:_[\da-f]+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[efp][+-]?\d+(?:_\d+)*)?j?/i,operator:/&&|\|\||[-+*^%÷⊻&$\\]=?|\/[\/=]?|!=?=?|\|[=>]?|<(?:<=?|[=:|])?|>(?:=|>>?=?)?|==?=?|[~≠≤≥'√∛]/,punctuation:/::?|[{}[\]();,.?]/,constant:/\b(?:(?:Inf|NaN)(?:16|32|64)?|im|pi)\b|[πℯ]/}}return julia_1}var keepalived_1,hasRequiredKeepalived;function requireKeepalived(){if(hasRequiredKeepalived)return keepalived_1;hasRequiredKeepalived=1,keepalived_1=e,e.displayName="keepalived",e.aliases=[];function e(t){t.languages.keepalived={comment:{pattern:/[#!].*/,greedy:!0},string:{pattern:/(^|[^\\])(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/,lookbehind:!0,greedy:!0},ip:{pattern:RegExp(/\b(?:(?:(?:[\da-f]{1,4}:){7}[\da-f]{1,4}|(?:[\da-f]{1,4}:){6}:[\da-f]{1,4}|(?:[\da-f]{1,4}:){5}:(?:[\da-f]{1,4}:)?[\da-f]{1,4}|(?:[\da-f]{1,4}:){4}:(?:[\da-f]{1,4}:){0,2}[\da-f]{1,4}|(?:[\da-f]{1,4}:){3}:(?:[\da-f]{1,4}:){0,3}[\da-f]{1,4}|(?:[\da-f]{1,4}:){2}:(?:[\da-f]{1,4}:){0,4}[\da-f]{1,4}|(?:[\da-f]{1,4}:){6}<ipv4>|(?:[\da-f]{1,4}:){0,5}:<ipv4>|::(?:[\da-f]{1,4}:){0,5}<ipv4>|[\da-f]{1,4}::(?:[\da-f]{1,4}:){0,5}[\da-f]{1,4}|::(?:[\da-f]{1,4}:){0,6}[\da-f]{1,4}|(?:[\da-f]{1,4}:){1,7}:)(?:\/\d{1,3})?|<ipv4>(?:\/\d{1,2})?)\b/.source.replace(/<ipv4>/g,function(){return/(?:(?:(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d\d|[1-9]\d|\d))/.source}),"i"),alias:"number"},path:{pattern:/(\s)\/(?:[^\/\s]+\/)*[^\/\s]*|\b[a-zA-Z]:\\(?:[^\\\s]+\\)*[^\\\s]*/,lookbehind:!0,alias:"string"},variable:/\$\{?\w+\}?/,email:{pattern:/[\w-]+@[\w-]+(?:\.[\w-]{2,3}){1,2}/,alias:"string"},"conditional-configuration":{pattern:/@\^?[\w-]+/,alias:"variable"},operator:/=/,property:/\b(?:BFD_CHECK|DNS_CHECK|FILE_CHECK|HTTP_GET|MISC_CHECK|NAME|PING_CHECK|SCRIPTS|SMTP_CHECK|SSL|SSL_GET|TCP_CHECK|UDP_CHECK|accept|advert_int|alpha|auth_pass|auth_type|authentication|bfd_cpu_affinity|bfd_instance|bfd_no_swap|bfd_priority|bfd_process_name|bfd_rlimit_rttime|bfd_rt_priority|bind_if|bind_port|bindto|ca|certificate|check_unicast_src|checker|checker_cpu_affinity|checker_log_all_failures|checker_no_swap|checker_priority|checker_rlimit_rttime|checker_rt_priority|child_wait_time|connect_ip|connect_port|connect_timeout|dbus_service_name|debug|default_interface|delay|delay_before_retry|delay_loop|digest|dont_track_primary|dynamic|dynamic_interfaces|enable_(?:dbus|script_security|sni|snmp_checker|snmp_rfc|snmp_rfcv2|snmp_rfcv3|snmp_vrrp|traps)|end|fall|fast_recovery|file|flag-[123]|fork_delay|full_command|fwmark|garp_group|garp_interval|garp_lower_prio_delay|garp_lower_prio_repeat|garp_master_delay|garp_master_refresh|garp_master_refresh_repeat|garp_master_repeat|global_defs|global_tracking|gna_interval|group|ha_suspend|hashed|helo_name|higher_prio_send_advert|hoplimit|http_protocol|hysteresis|idle_tx|include|inhibit_on_failure|init_fail|init_file|instance|interface|interfaces|interval|ip_family|ipvs_process_name|keepalived.conf|kernel_rx_buf_size|key|linkbeat_interfaces|linkbeat_use_polling|log_all_failures|log_unknown_vrids|lower_prio_no_advert|lthreshold|lvs_flush|lvs_flush_onstop|lvs_method|lvs_netlink_cmd_rcv_bufs|lvs_netlink_cmd_rcv_bufs_force|lvs_netlink_monitor_rcv_bufs|lvs_netlink_monitor_rcv_bufs_force|lvs_notify_fifo|lvs_notify_fifo_script|lvs_sched|lvs_sync_daemon|max_auto_priority|max_hops|mcast_src_ip|mh-fallback|mh-port|min_auto_priority_delay|min_rx|min_tx|misc_dynamic|misc_path|misc_timeout|multiplier|name|namespace_with_ipsets|native_ipv6|neighbor_ip|net_namespace|net_namespace_ipvs|nftables|nftables_counters|nftables_ifindex|nftables_priority|no_accept|no_checker_emails|no_email_faults|nopreempt|notification_email|notification_email_from|notify|notify_backup|notify_deleted|notify_down|notify_fault|notify_fifo|notify_fifo_script|notify_master|notify_master_rx_lower_pri|notify_priority_changes|notify_stop|notify_up|old_unicast_checksum|omega|ops|param_match|passive|password|path|persistence_engine|persistence_granularity|persistence_timeout|preempt|preempt_delay|priority|process|process_monitor_rcv_bufs|process_monitor_rcv_bufs_force|process_name|process_names|promote_secondaries|protocol|proxy_arp|proxy_arp_pvlan|quorum|quorum_down|quorum_max|quorum_up|random_seed|real_server|regex|regex_max_offset|regex_min_offset|regex_no_match|regex_options|regex_stack|reload_repeat|reload_time_file|require_reply|retry|rise|router_id|rs_init_notifies|script|script_user|sh-fallback|sh-port|shutdown_script|shutdown_script_timeout|skip_check_adv_addr|smtp_alert|smtp_alert_checker|smtp_alert_vrrp|smtp_connect_timeout|smtp_helo_name|smtp_server|snmp_socket|sorry_server|sorry_server_inhibit|sorry_server_lvs_method|source_ip|start|startup_script|startup_script_timeout|state|static_ipaddress|static_routes|static_rules|status_code|step|strict_mode|sync_group_tracking_weight|terminate_delay|timeout|track_bfd|track_file|track_group|track_interface|track_process|track_script|track_src_ip|ttl|type|umask|unicast_peer|unicast_src_ip|unicast_ttl|url|use_ipvlan|use_pid_dir|use_vmac|user|uthreshold|val[123]|version|virtual_ipaddress|virtual_ipaddress_excluded|virtual_router_id|virtual_routes|virtual_rules|virtual_server|virtual_server_group|virtualhost|vmac_xmit_base|vrrp|vrrp_(?:check_unicast_src|cpu_affinity|garp_interval|garp_lower_prio_delay|garp_lower_prio_repeat|garp_master_delay|garp_master_refresh|garp_master_refresh_repeat|garp_master_repeat|gna_interval|higher_prio_send_advert|instance|ipsets|iptables|lower_prio_no_advert|mcast_group4|mcast_group6|min_garp|netlink_cmd_rcv_bufs|netlink_cmd_rcv_bufs_force|netlink_monitor_rcv_bufs|netlink_monitor_rcv_bufs_force|no_swap|notify_fifo|notify_fifo_script|notify_priority_changes|priority|process_name|rlimit_rttime|rt_priority|rx_bufs_multiplier|rx_bufs_policy|script|skip_check_adv_addr|startup_delay|strict|sync_group|track_process|version)|warmup|weight)\b/,constant:/\b(?:A|AAAA|AH|BACKUP|CNAME|DR|MASTER|MX|NAT|NS|PASS|SCTP|SOA|TCP|TUN|TXT|UDP|dh|fo|lblc|lblcr|lc|mh|nq|ovf|rr|sed|sh|wlc|wrr)\b/,number:{pattern:/(^|[^\w.-])-?\d+(?:\.\d+)?/,lookbehind:!0},boolean:/\b(?:false|no|off|on|true|yes)\b/,punctuation:/[\{\}]/}}return keepalived_1}var keyman_1,hasRequiredKeyman;function requireKeyman(){if(hasRequiredKeyman)return keyman_1;hasRequiredKeyman=1,keyman_1=e,e.displayName="keyman",e.aliases=[];function e(t){t.languages.keyman={comment:{pattern:/\bc .*/i,greedy:!0},string:{pattern:/"[^"\r\n]*"|'[^'\r\n]*'/,greedy:!0},"virtual-key":{pattern:/\[\s*(?:(?:ALT|CAPS|CTRL|LALT|LCTRL|NCAPS|RALT|RCTRL|SHIFT)\s+)*(?:[TKU]_[\w?]+|[A-E]\d\d?|"[^"\r\n]*"|'[^'\r\n]*')\s*\]/i,greedy:!0,alias:"function"},"header-keyword":{pattern:/&\w+/,alias:"bold"},"header-statement":{pattern:/\b(?:bitmap|bitmaps|caps always off|caps on only|copyright|hotkey|language|layout|message|name|shift frees caps|version)\b/i,alias:"bold"},"rule-keyword":{pattern:/\b(?:any|baselayout|beep|call|context|deadkey|dk|if|index|layer|notany|nul|outs|platform|reset|return|save|set|store|use)\b/i,alias:"keyword"},"structural-keyword":{pattern:/\b(?:ansi|begin|group|match|nomatch|unicode|using keys)\b/i,alias:"keyword"},"compile-target":{pattern:/\$(?:keyman|keymanonly|keymanweb|kmfl|weaver):/i,alias:"property"},number:/\b(?:U\+[\dA-F]+|d\d+|x[\da-f]+|\d+)\b/i,operator:/[+>\\$]|\.\./,punctuation:/[()=,]/}}return keyman_1}var kotlin_1,hasRequiredKotlin;function requireKotlin(){if(hasRequiredKotlin)return kotlin_1;hasRequiredKotlin=1,kotlin_1=e,e.displayName="kotlin",e.aliases=["kt","kts"];function e(t){(function(Ye){Ye.languages.kotlin=Ye.languages.extend("clike",{keyword:{pattern:/(^|[^.])\b(?:abstract|actual|annotation|as|break|by|catch|class|companion|const|constructor|continue|crossinline|data|do|dynamic|else|enum|expect|external|final|finally|for|fun|get|if|import|in|infix|init|inline|inner|interface|internal|is|lateinit|noinline|null|object|open|operator|out|override|package|private|protected|public|reified|return|sealed|set|super|suspend|tailrec|this|throw|to|try|typealias|val|var|vararg|when|where|while)\b/,lookbehind:!0},function:[{pattern:/(?:`[^\r\n`]+`|\b\w+)(?=\s*\()/,greedy:!0},{pattern:/(\.)(?:`[^\r\n`]+`|\w+)(?=\s*\{)/,lookbehind:!0,greedy:!0}],number:/\b(?:0[xX][\da-fA-F]+(?:_[\da-fA-F]+)*|0[bB][01]+(?:_[01]+)*|\d+(?:_\d+)*(?:\.\d+(?:_\d+)*)?(?:[eE][+-]?\d+(?:_\d+)*)?[fFL]?)\b/,operator:/\+[+=]?|-[-=>]?|==?=?|!(?:!|==?)?|[\/*%<>]=?|[?:]:?|\.\.|&&|\|\||\b(?:and|inv|or|shl|shr|ushr|xor)\b/}),delete Ye.languages.kotlin["class-name"];var tt={"interpolation-punctuation":{pattern:/^\$\{?|\}$/,alias:"punctuation"},expression:{pattern:/[\s\S]+/,inside:Ye.languages.kotlin}};Ye.languages.insertBefore("kotlin","string",{"string-literal":[{pattern:/"""(?:[^$]|\$(?:(?!\{)|\{[^{}]*\}))*?"""/,alias:"multiline",inside:{interpolation:{pattern:/\$(?:[a-z_]\w*|\{[^{}]*\})/i,inside:tt},string:/[\s\S]+/}},{pattern:/"(?:[^"\\\r\n$]|\\.|\$(?:(?!\{)|\{[^{}]*\}))*"/,alias:"singleline",inside:{interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$(?:[a-z_]\w*|\{[^{}]*\})/i,lookbehind:!0,inside:tt},string:/[\s\S]+/}}],char:{pattern:/'(?:[^'\\\r\n]|\\(?:.|u[a-fA-F0-9]{0,4}))'/,greedy:!0}}),delete Ye.languages.kotlin.string,Ye.languages.insertBefore("kotlin","keyword",{annotation:{pattern:/\B@(?:\w+:)?(?:[A-Z]\w*|\[[^\]]+\])/,alias:"builtin"}}),Ye.languages.insertBefore("kotlin","function",{label:{pattern:/\b\w+@|@\w+\b/,alias:"symbol"}}),Ye.languages.kt=Ye.languages.kotlin,Ye.languages.kts=Ye.languages.kotlin})(t)}return kotlin_1}var kumir_1,hasRequiredKumir;function requireKumir(){if(hasRequiredKumir)return kumir_1;hasRequiredKumir=1,kumir_1=e,e.displayName="kumir",e.aliases=["kum"];function e(t){(function(Ye){var tt=/\s\x00-\x1f\x22-\x2f\x3a-\x3f\x5b-\x5e\x60\x7b-\x7e/.source;function rt(nt,at){return RegExp(nt.replace(/<nonId>/g,tt),at)}Ye.languages.kumir={comment:{pattern:/\|.*/},prolog:{pattern:/#.*/,greedy:!0},string:{pattern:/"[^\n\r"]*"|'[^\n\r']*'/,greedy:!0},boolean:{pattern:rt(/(^|[<nonId>])(?:да|нет)(?=[<nonId>]|$)/.source),lookbehind:!0},"operator-word":{pattern:rt(/(^|[<nonId>])(?:и|или|не)(?=[<nonId>]|$)/.source),lookbehind:!0,alias:"keyword"},"system-variable":{pattern:rt(/(^|[<nonId>])знач(?=[<nonId>]|$)/.source),lookbehind:!0,alias:"keyword"},type:[{pattern:rt(/(^|[<nonId>])(?:вещ|лит|лог|сим|цел)(?:\x20*таб)?(?=[<nonId>]|$)/.source),lookbehind:!0,alias:"builtin"},{pattern:rt(/(^|[<nonId>])(?:компл|сканкод|файл|цвет)(?=[<nonId>]|$)/.source),lookbehind:!0,alias:"important"}],keyword:{pattern:rt(/(^|[<nonId>])(?:алг|арг(?:\x20*рез)?|ввод|ВКЛЮЧИТЬ|вс[её]|выбор|вывод|выход|дано|для|до|дс|если|иначе|исп|использовать|кон(?:(?:\x20+|_)исп)?|кц(?:(?:\x20+|_)при)?|надо|нач|нс|нц|от|пауза|пока|при|раза?|рез|стоп|таб|то|утв|шаг)(?=[<nonId>]|$)/.source),lookbehind:!0},name:{pattern:rt(/(^|[<nonId>])[^\d<nonId>][^<nonId>]*(?:\x20+[^<nonId>]+)*(?=[<nonId>]|$)/.source),lookbehind:!0},number:{pattern:rt(/(^|[<nonId>])(?:\B\$[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?)(?=[<nonId>]|$)/.source,"i"),lookbehind:!0},punctuation:/:=|[(),:;\[\]]/,"operator-char":{pattern:/\*\*?|<[=>]?|>=?|[-+/=]/,alias:"operator"}},Ye.languages.kum=Ye.languages.kumir})(t)}return kumir_1}var kusto_1,hasRequiredKusto;function requireKusto(){if(hasRequiredKusto)return kusto_1;hasRequiredKusto=1,kusto_1=e,e.displayName="kusto",e.aliases=[];function e(t){t.languages.kusto={comment:{pattern:/\/\/.*/,greedy:!0},string:{pattern:/```[\s\S]*?```|[hH]?(?:"(?:[^\r\n\\"]|\\.)*"|'(?:[^\r\n\\']|\\.)*'|@(?:"[^\r\n"]*"|'[^\r\n']*'))/,greedy:!0},verb:{pattern:/(\|\s*)[a-z][\w-]*/i,lookbehind:!0,alias:"keyword"},command:{pattern:/\.[a-z][a-z\d-]*\b/,alias:"keyword"},"class-name":/\b(?:bool|datetime|decimal|dynamic|guid|int|long|real|string|timespan)\b/,keyword:/\b(?:access|alias|and|anti|as|asc|auto|between|by|(?:contains|(?:ends|starts)with|has(?:perfix|suffix)?)(?:_cs)?|database|declare|desc|external|from|fullouter|has_all|in|ingestion|inline|inner|innerunique|into|(?:left|right)(?:anti(?:semi)?|inner|outer|semi)?|let|like|local|not|of|on|or|pattern|print|query_parameters|range|restrict|schema|set|step|table|tables|to|view|where|with|matches\s+regex|nulls\s+(?:first|last))(?![\w-])/,boolean:/\b(?:false|null|true)\b/,function:/\b[a-z_]\w*(?=\s*\()/,datetime:[{pattern:/\b(?:(?:Fri|Friday|Mon|Monday|Sat|Saturday|Sun|Sunday|Thu|Thursday|Tue|Tuesday|Wed|Wednesday)\s*,\s*)?\d{1,2}(?:\s+|-)(?:Apr|Aug|Dec|Feb|Jan|Jul|Jun|Mar|May|Nov|Oct|Sep)(?:\s+|-)\d{2}\s+\d{2}:\d{2}(?::\d{2})?(?:\s*(?:\b(?:[A-Z]|(?:[ECMT][DS]|GM|U)T)|[+-]\d{4}))?\b/,alias:"number"},{pattern:/[+-]?\b(?:\d{4}-\d{2}-\d{2}(?:[ T]\d{2}:\d{2}(?::\d{2}(?:\.\d+)?)?)?|\d{2}:\d{2}(?::\d{2}(?:\.\d+)?)?)Z?/,alias:"number"}],number:/\b(?:0x[0-9A-Fa-f]+|\d+(?:\.\d+)?(?:[Ee][+-]?\d+)?)(?:(?:min|sec|[mnµ]s|[dhms]|microsecond|tick)\b)?|[+-]?\binf\b/,operator:/=>|[!=]~|[!=<>]=?|[-+*/%|]|\.\./,punctuation:/[()\[\]{},;.:]/}}return kusto_1}var latex_1,hasRequiredLatex;function requireLatex(){if(hasRequiredLatex)return latex_1;hasRequiredLatex=1,latex_1=e,e.displayName="latex",e.aliases=["tex","context"];function e(t){(function(Ye){var tt=/\\(?:[^a-z()[\]]|[a-z*]+)/i,rt={"equation-command":{pattern:tt,alias:"regex"}};Ye.languages.latex={comment:/%.*/,cdata:{pattern:/(\\begin\{((?:lstlisting|verbatim)\*?)\})[\s\S]*?(?=\\end\{\2\})/,lookbehind:!0},equation:[{pattern:/\$\$(?:\\[\s\S]|[^\\$])+\$\$|\$(?:\\[\s\S]|[^\\$])+\$|\\\([\s\S]*?\\\)|\\\[[\s\S]*?\\\]/,inside:rt,alias:"string"},{pattern:/(\\begin\{((?:align|eqnarray|equation|gather|math|multline)\*?)\})[\s\S]*?(?=\\end\{\2\})/,lookbehind:!0,inside:rt,alias:"string"}],keyword:{pattern:/(\\(?:begin|cite|documentclass|end|label|ref|usepackage)(?:\[[^\]]+\])?\{)[^}]+(?=\})/,lookbehind:!0},url:{pattern:/(\\url\{)[^}]+(?=\})/,lookbehind:!0},headline:{pattern:/(\\(?:chapter|frametitle|paragraph|part|section|subparagraph|subsection|subsubparagraph|subsubsection|subsubsubparagraph)\*?(?:\[[^\]]+\])?\{)[^}]+(?=\})/,lookbehind:!0,alias:"class-name"},function:{pattern:tt,alias:"selector"},punctuation:/[[\]{}&]/},Ye.languages.tex=Ye.languages.latex,Ye.languages.context=Ye.languages.latex})(t)}return latex_1}var php_1,hasRequiredPhp;function requirePhp(){if(hasRequiredPhp)return php_1;hasRequiredPhp=1;var e=requireMarkupTemplating();php_1=t,t.displayName="php",t.aliases=[];function t(Ye){Ye.register(e),function(tt){var rt=/\/\*[\s\S]*?\*\/|\/\/.*|#(?!\[).*/,nt=[{pattern:/\b(?:false|true)\b/i,alias:"boolean"},{pattern:/(::\s*)\b[a-z_]\w*\b(?!\s*\()/i,greedy:!0,lookbehind:!0},{pattern:/(\b(?:case|const)\s+)\b[a-z_]\w*(?=\s*[;=])/i,greedy:!0,lookbehind:!0},/\b(?:null)\b/i,/\b[A-Z_][A-Z0-9_]*\b(?!\s*\()/],at=/\b0b[01]+(?:_[01]+)*\b|\b0o[0-7]+(?:_[0-7]+)*\b|\b0x[\da-f]+(?:_[\da-f]+)*\b|(?:\b\d+(?:_\d+)*\.?(?:\d+(?:_\d+)*)?|\B\.\d+)(?:e[+-]?\d+)?/i,it=/<?=>|\?\?=?|\.{3}|\??->|[!=]=?=?|::|\*\*=?|--|\+\+|&&|\|\||<<|>>|[?~]|[/^|%*&<>.+-]=?/,ot=/[{}\[\](),:;]/;tt.languages.php={delimiter:{pattern:/\?>$|^<\?(?:php(?=\s)|=)?/i,alias:"important"},comment:rt,variable:/\$+(?:\w+\b|(?=\{))/,package:{pattern:/(namespace\s+|use\s+(?:function\s+)?)(?:\\?\b[a-z_]\w*)+\b(?!\\)/i,lookbehind:!0,inside:{punctuation:/\\/}},"class-name-definition":{pattern:/(\b(?:class|enum|interface|trait)\s+)\b[a-z_]\w*(?!\\)\b/i,lookbehind:!0,alias:"class-name"},"function-definition":{pattern:/(\bfunction\s+)[a-z_]\w*(?=\s*\()/i,lookbehind:!0,alias:"function"},keyword:[{pattern:/(\(\s*)\b(?:array|bool|boolean|float|int|integer|object|string)\b(?=\s*\))/i,alias:"type-casting",greedy:!0,lookbehind:!0},{pattern:/([(,?]\s*)\b(?:array(?!\s*\()|bool|callable|(?:false|null)(?=\s*\|)|float|int|iterable|mixed|object|self|static|string)\b(?=\s*\$)/i,alias:"type-hint",greedy:!0,lookbehind:!0},{pattern:/(\)\s*:\s*(?:\?\s*)?)\b(?:array(?!\s*\()|bool|callable|(?:false|null)(?=\s*\|)|float|int|iterable|mixed|object|self|static|string|void)\b/i,alias:"return-type",greedy:!0,lookbehind:!0},{pattern:/\b(?:array(?!\s*\()|bool|float|int|iterable|mixed|object|string|void)\b/i,alias:"type-declaration",greedy:!0},{pattern:/(\|\s*)(?:false|null)\b|\b(?:false|null)(?=\s*\|)/i,alias:"type-declaration",greedy:!0,lookbehind:!0},{pattern:/\b(?:parent|self|static)(?=\s*::)/i,alias:"static-context",greedy:!0},{pattern:/(\byield\s+)from\b/i,lookbehind:!0},/\bclass\b/i,{pattern:/((?:^|[^\s>:]|(?:^|[^-])>|(?:^|[^:]):)\s*)\b(?:abstract|and|array|as|break|callable|case|catch|clone|const|continue|declare|default|die|do|echo|else|elseif|empty|enddeclare|endfor|endforeach|endif|endswitch|endwhile|enum|eval|exit|extends|final|finally|fn|for|foreach|function|global|goto|if|implements|include|include_once|instanceof|insteadof|interface|isset|list|match|namespace|new|or|parent|print|private|protected|public|require|require_once|return|self|static|switch|throw|trait|try|unset|use|var|while|xor|yield|__halt_compiler)\b/i,lookbehind:!0}],"argument-name":{pattern:/([(,]\s+)\b[a-z_]\w*(?=\s*:(?!:))/i,lookbehind:!0},"class-name":[{pattern:/(\b(?:extends|implements|instanceof|new(?!\s+self|\s+static))\s+|\bcatch\s*\()\b[a-z_]\w*(?!\\)\b/i,greedy:!0,lookbehind:!0},{pattern:/(\|\s*)\b[a-z_]\w*(?!\\)\b/i,greedy:!0,lookbehind:!0},{pattern:/\b[a-z_]\w*(?!\\)\b(?=\s*\|)/i,greedy:!0},{pattern:/(\|\s*)(?:\\?\b[a-z_]\w*)+\b/i,alias:"class-name-fully-qualified",greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}},{pattern:/(?:\\?\b[a-z_]\w*)+\b(?=\s*\|)/i,alias:"class-name-fully-qualified",greedy:!0,inside:{punctuation:/\\/}},{pattern:/(\b(?:extends|implements|instanceof|new(?!\s+self\b|\s+static\b))\s+|\bcatch\s*\()(?:\\?\b[a-z_]\w*)+\b(?!\\)/i,alias:"class-name-fully-qualified",greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}},{pattern:/\b[a-z_]\w*(?=\s*\$)/i,alias:"type-declaration",greedy:!0},{pattern:/(?:\\?\b[a-z_]\w*)+(?=\s*\$)/i,alias:["class-name-fully-qualified","type-declaration"],greedy:!0,inside:{punctuation:/\\/}},{pattern:/\b[a-z_]\w*(?=\s*::)/i,alias:"static-context",greedy:!0},{pattern:/(?:\\?\b[a-z_]\w*)+(?=\s*::)/i,alias:["class-name-fully-qualified","static-context"],greedy:!0,inside:{punctuation:/\\/}},{pattern:/([(,?]\s*)[a-z_]\w*(?=\s*\$)/i,alias:"type-hint",greedy:!0,lookbehind:!0},{pattern:/([(,?]\s*)(?:\\?\b[a-z_]\w*)+(?=\s*\$)/i,alias:["class-name-fully-qualified","type-hint"],greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}},{pattern:/(\)\s*:\s*(?:\?\s*)?)\b[a-z_]\w*(?!\\)\b/i,alias:"return-type",greedy:!0,lookbehind:!0},{pattern:/(\)\s*:\s*(?:\?\s*)?)(?:\\?\b[a-z_]\w*)+\b(?!\\)/i,alias:["class-name-fully-qualified","return-type"],greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}}],constant:nt,function:{pattern:/(^|[^\\\w])\\?[a-z_](?:[\w\\]*\w)?(?=\s*\()/i,lookbehind:!0,inside:{punctuation:/\\/}},property:{pattern:/(->\s*)\w+/,lookbehind:!0},number:at,operator:it,punctuation:ot};var ct={pattern:/\{\$(?:\{(?:\{[^{}]+\}|[^{}]+)\}|[^{}])+\}|(^|[^\\{])\$+(?:\w+(?:\[[^\r\n\[\]]+\]|->\w+)?)/,lookbehind:!0,inside:tt.languages.php},At=[{pattern:/<<<'([^']+)'[\r\n](?:.*[\r\n])*?\1;/,alias:"nowdoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<<'[^']+'|[a-z_]\w*;$/i,alias:"symbol",inside:{punctuation:/^<<<'?|[';]$/}}}},{pattern:/<<<(?:"([^"]+)"[\r\n](?:.*[\r\n])*?\1;|([a-z_]\w*)[\r\n](?:.*[\r\n])*?\2;)/i,alias:"heredoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<<(?:"[^"]+"|[a-z_]\w*)|[a-z_]\w*;$/i,alias:"symbol",inside:{punctuation:/^<<<"?|[";]$/}},interpolation:ct}},{pattern:/`(?:\\[\s\S]|[^\\`])*`/,alias:"backtick-quoted-string",greedy:!0},{pattern:/'(?:\\[\s\S]|[^\\'])*'/,alias:"single-quoted-string",greedy:!0},{pattern:/"(?:\\[\s\S]|[^\\"])*"/,alias:"double-quoted-string",greedy:!0,inside:{interpolation:ct}}];tt.languages.insertBefore("php","variable",{string:At,attribute:{pattern:/#\[(?:[^"'\/#]|\/(?![*/])|\/\/.*$|#(?!\[).*$|\/\*(?:[^*]|\*(?!\/))*\*\/|"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*')+\](?=\s*[a-z$#])/im,greedy:!0,inside:{"attribute-content":{pattern:/^(#\[)[\s\S]+(?=\]$)/,lookbehind:!0,inside:{comment:rt,string:At,"attribute-class-name":[{pattern:/([^:]|^)\b[a-z_]\w*(?!\\)\b/i,alias:"class-name",greedy:!0,lookbehind:!0},{pattern:/([^:]|^)(?:\\?\b[a-z_]\w*)+/i,alias:["class-name","class-name-fully-qualified"],greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}}],constant:nt,number:at,operator:it,punctuation:ot}},delimiter:{pattern:/^#\[|\]$/,alias:"punctuation"}}}}),tt.hooks.add("before-tokenize",function(Rt){if(/<\?/.test(Rt.code)){var qt=/<\?(?:[^"'/#]|\/(?![*/])|("|')(?:\\[\s\S]|(?!\1)[^\\])*\1|(?:\/\/|#(?!\[))(?:[^?\n\r]|\?(?!>))*(?=$|\?>|[\r\n])|#\[|\/\*(?:[^*]|\*(?!\/))*(?:\*\/|$))*?(?:\?>|$)/g;tt.languages["markup-templating"].buildPlaceholders(Rt,"php",qt)}}),tt.hooks.add("after-tokenize",function(Rt){tt.languages["markup-templating"].tokenizePlaceholders(Rt,"php")})}(Ye)}return php_1}var latte_1,hasRequiredLatte;function requireLatte(){if(hasRequiredLatte)return latte_1;hasRequiredLatte=1;var e=requireMarkupTemplating(),t=requirePhp();latte_1=Ye,Ye.displayName="latte",Ye.aliases=[];function Ye(tt){tt.register(e),tt.register(t),function(rt){rt.languages.latte={comment:/^\{\*[\s\S]*/,"latte-tag":{pattern:/(^\{(?:\/(?=[a-z]))?)(?:[=_]|[a-z]\w*\b(?!\())/i,lookbehind:!0,alias:"important"},delimiter:{pattern:/^\{\/?|\}$/,alias:"punctuation"},php:{pattern:/\S(?:[\s\S]*\S)?/,alias:"language-php",inside:rt.languages.php}};var nt=rt.languages.extend("markup",{});rt.languages.insertBefore("inside","attr-value",{"n-attr":{pattern:/n:[\w-]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+))?/,inside:{"attr-name":{pattern:/^[^\s=]+/,alias:"important"},"attr-value":{pattern:/=[\s\S]+/,inside:{punctuation:[/^=/,{pattern:/^(\s*)["']|["']$/,lookbehind:!0}],php:{pattern:/\S(?:[\s\S]*\S)?/,inside:rt.languages.php}}}}}},nt.tag),rt.hooks.add("before-tokenize",function(at){if(at.language==="latte"){var it=/\{\*[\s\S]*?\*\}|\{[^'"\s{}*](?:[^"'/{}]|\/(?![*/])|("|')(?:\\[\s\S]|(?!\1)[^\\])*\1|\/\*(?:[^*]|\*(?!\/))*\*\/)*\}/g;rt.languages["markup-templating"].buildPlaceholders(at,"latte",it),at.grammar=nt}}),rt.hooks.add("after-tokenize",function(at){rt.languages["markup-templating"].tokenizePlaceholders(at,"latte")})}(tt)}return latte_1}var less_1,hasRequiredLess;function requireLess(){if(hasRequiredLess)return less_1;hasRequiredLess=1,less_1=e,e.displayName="less",e.aliases=[];function e(t){t.languages.less=t.languages.extend("css",{comment:[/\/\*[\s\S]*?\*\//,{pattern:/(^|[^\\])\/\/.*/,lookbehind:!0}],atrule:{pattern:/@[\w-](?:\((?:[^(){}]|\([^(){}]*\))*\)|[^(){};\s]|\s+(?!\s))*?(?=\s*\{)/,inside:{punctuation:/[:()]/}},selector:{pattern:/(?:@\{[\w-]+\}|[^{};\s@])(?:@\{[\w-]+\}|\((?:[^(){}]|\([^(){}]*\))*\)|[^(){};@\s]|\s+(?!\s))*?(?=\s*\{)/,inside:{variable:/@+[\w-]+/}},property:/(?:@\{[\w-]+\}|[\w-])+(?:\+_?)?(?=\s*:)/,operator:/[+\-*\/]/}),t.languages.insertBefore("less","property",{variable:[{pattern:/@[\w-]+\s*:/,inside:{punctuation:/:/}},/@@?[\w-]+/],"mixin-usage":{pattern:/([{;]\s*)[.#](?!\d)[\w-].*?(?=[(;])/,lookbehind:!0,alias:"function"}})}return less_1}var scheme_1,hasRequiredScheme;function requireScheme(){if(hasRequiredScheme)return scheme_1;hasRequiredScheme=1,scheme_1=e,e.displayName="scheme",e.aliases=[];function e(t){(function(Ye){Ye.languages.scheme={comment:/;.*|#;\s*(?:\((?:[^()]|\([^()]*\))*\)|\[(?:[^\[\]]|\[[^\[\]]*\])*\])|#\|(?:[^#|]|#(?!\|)|\|(?!#)|#\|(?:[^#|]|#(?!\|)|\|(?!#))*\|#)*\|#/,string:{pattern:/"(?:[^"\\]|\\.)*"/,greedy:!0},symbol:{pattern:/'[^()\[\]#'\s]+/,greedy:!0},char:{pattern:/#\\(?:[ux][a-fA-F\d]+\b|[-a-zA-Z]+\b|[\uD800-\uDBFF][\uDC00-\uDFFF]|\S)/,greedy:!0},"lambda-parameter":[{pattern:/((?:^|[^'`#])[(\[]lambda\s+)(?:[^|()\[\]'\s]+|\|(?:[^\\|]|\\.)*\|)/,lookbehind:!0},{pattern:/((?:^|[^'`#])[(\[]lambda\s+[(\[])[^()\[\]']+/,lookbehind:!0}],keyword:{pattern:/((?:^|[^'`#])[(\[])(?:begin|case(?:-lambda)?|cond(?:-expand)?|define(?:-library|-macro|-record-type|-syntax|-values)?|defmacro|delay(?:-force)?|do|else|except|export|guard|if|import|include(?:-ci|-library-declarations)?|lambda|let(?:rec)?(?:-syntax|-values|\*)?|let\*-values|only|parameterize|prefix|(?:quasi-?)?quote|rename|set!|syntax-(?:case|rules)|unless|unquote(?:-splicing)?|when)(?=[()\[\]\s]|$)/,lookbehind:!0},builtin:{pattern:/((?:^|[^'`#])[(\[])(?:abs|and|append|apply|assoc|ass[qv]|binary-port\?|boolean=?\?|bytevector(?:-append|-copy|-copy!|-length|-u8-ref|-u8-set!|\?)?|caar|cadr|call-with-(?:current-continuation|port|values)|call\/cc|car|cdar|cddr|cdr|ceiling|char(?:->integer|-ready\?|\?|<\?|<=\?|=\?|>\?|>=\?)|close-(?:input-port|output-port|port)|complex\?|cons|current-(?:error|input|output)-port|denominator|dynamic-wind|eof-object\??|eq\?|equal\?|eqv\?|error|error-object(?:-irritants|-message|\?)|eval|even\?|exact(?:-integer-sqrt|-integer\?|\?)?|expt|features|file-error\?|floor(?:-quotient|-remainder|\/)?|flush-output-port|for-each|gcd|get-output-(?:bytevector|string)|inexact\??|input-port(?:-open\?|\?)|integer(?:->char|\?)|lcm|length|list(?:->string|->vector|-copy|-ref|-set!|-tail|\?)?|make-(?:bytevector|list|parameter|string|vector)|map|max|member|memq|memv|min|modulo|negative\?|newline|not|null\?|number(?:->string|\?)|numerator|odd\?|open-(?:input|output)-(?:bytevector|string)|or|output-port(?:-open\?|\?)|pair\?|peek-char|peek-u8|port\?|positive\?|procedure\?|quotient|raise|raise-continuable|rational\?|rationalize|read-(?:bytevector|bytevector!|char|error\?|line|string|u8)|real\?|remainder|reverse|round|set-c[ad]r!|square|string(?:->list|->number|->symbol|->utf8|->vector|-append|-copy|-copy!|-fill!|-for-each|-length|-map|-ref|-set!|\?|<\?|<=\?|=\?|>\?|>=\?)?|substring|symbol(?:->string|\?|=\?)|syntax-error|textual-port\?|truncate(?:-quotient|-remainder|\/)?|u8-ready\?|utf8->string|values|vector(?:->list|->string|-append|-copy|-copy!|-fill!|-for-each|-length|-map|-ref|-set!|\?)?|with-exception-handler|write-(?:bytevector|char|string|u8)|zero\?)(?=[()\[\]\s]|$)/,lookbehind:!0},operator:{pattern:/((?:^|[^'`#])[(\[])(?:[-+*%/]|[<>]=?|=>?)(?=[()\[\]\s]|$)/,lookbehind:!0},number:{pattern:RegExp(tt({"<ureal dec>":/\d+(?:\/\d+)|(?:\d+(?:\.\d*)?|\.\d+)(?:[esfdl][+-]?\d+)?/.source,"<real dec>":/[+-]?<ureal dec>|[+-](?:inf|nan)\.0/.source,"<imaginary dec>":/[+-](?:<ureal dec>|(?:inf|nan)\.0)?i/.source,"<complex dec>":/<real dec>(?:@<real dec>|<imaginary dec>)?|<imaginary dec>/.source,"<num dec>":/(?:#d(?:#[ei])?|#[ei](?:#d)?)?<complex dec>/.source,"<ureal box>":/[0-9a-f]+(?:\/[0-9a-f]+)?/.source,"<real box>":/[+-]?<ureal box>|[+-](?:inf|nan)\.0/.source,"<imaginary box>":/[+-](?:<ureal box>|(?:inf|nan)\.0)?i/.source,"<complex box>":/<real box>(?:@<real box>|<imaginary box>)?|<imaginary box>/.source,"<num box>":/#[box](?:#[ei])?|(?:#[ei])?#[box]<complex box>/.source,"<number>":/(^|[()\[\]\s])(?:<num dec>|<num box>)(?=[()\[\]\s]|$)/.source}),"i"),lookbehind:!0},boolean:{pattern:/(^|[()\[\]\s])#(?:[ft]|false|true)(?=[()\[\]\s]|$)/,lookbehind:!0},function:{pattern:/((?:^|[^'`#])[(\[])(?:[^|()\[\]'\s]+|\|(?:[^\\|]|\\.)*\|)(?=[()\[\]\s]|$)/,lookbehind:!0},identifier:{pattern:/(^|[()\[\]\s])\|(?:[^\\|]|\\.)*\|(?=[()\[\]\s]|$)/,lookbehind:!0,greedy:!0},punctuation:/[()\[\]']/};function tt(rt){for(var nt in rt)rt[nt]=rt[nt].replace(/<[\w\s]+>/g,function(at){return"(?:"+rt[at].trim()+")"});return rt[nt]}})(t)}return scheme_1}var lilypond_1,hasRequiredLilypond;function requireLilypond(){if(hasRequiredLilypond)return lilypond_1;hasRequiredLilypond=1;var e=requireScheme();lilypond_1=t,t.displayName="lilypond",t.aliases=[];function t(Ye){Ye.register(e),function(tt){for(var rt=/\((?:[^();"#\\]|\\[\s\S]|;.*(?!.)|"(?:[^"\\]|\\.)*"|#(?:\{(?:(?!#\})[\s\S])*#\}|[^{])|<expr>)*\)/.source,nt=5,at=0;at<nt;at++)rt=rt.replace(/<expr>/g,function(){return rt});rt=rt.replace(/<expr>/g,/[^\s\S]/.source);var it=tt.languages.lilypond={comment:/%(?:(?!\{).*|\{[\s\S]*?%\})/,"embedded-scheme":{pattern:RegExp(/(^|[=\s])#(?:"(?:[^"\\]|\\.)*"|[^\s()"]*(?:[^\s()]|<expr>))/.source.replace(/<expr>/g,function(){return rt}),"m"),lookbehind:!0,greedy:!0,inside:{scheme:{pattern:/^(#)[\s\S]+$/,lookbehind:!0,alias:"language-scheme",inside:{"embedded-lilypond":{pattern:/#\{[\s\S]*?#\}/,greedy:!0,inside:{punctuation:/^#\{|#\}$/,lilypond:{pattern:/[\s\S]+/,alias:"language-lilypond",inside:null}}},rest:tt.languages.scheme}},punctuation:/#/}},string:{pattern:/"(?:[^"\\]|\\.)*"/,greedy:!0},"class-name":{pattern:/(\\new\s+)[\w-]+/,lookbehind:!0},keyword:{pattern:/\\[a-z][-\w]*/i,inside:{punctuation:/^\\/}},operator:/[=|]|<<|>>/,punctuation:{pattern:/(^|[a-z\d])(?:'+|,+|[_^]?-[_^]?(?:[-+^!>._]|(?=\d))|[_^]\.?|[.!])|[{}()[\]<>^~]|\\[()[\]<>\\!]|--|__/,lookbehind:!0},number:/\b\d+(?:\/\d+)?\b/};it["embedded-scheme"].inside.scheme.inside["embedded-lilypond"].inside.lilypond.inside=it,tt.languages.ly=it}(Ye)}return lilypond_1}var liquid_1,hasRequiredLiquid;function requireLiquid(){if(hasRequiredLiquid)return liquid_1;hasRequiredLiquid=1;var e=requireMarkupTemplating();liquid_1=t,t.displayName="liquid",t.aliases=[];function t(Ye){Ye.register(e),Ye.languages.liquid={comment:{pattern:/(^\{%\s*comment\s*%\})[\s\S]+(?=\{%\s*endcomment\s*%\}$)/,lookbehind:!0},delimiter:{pattern:/^\{(?:\{\{|[%\{])-?|-?(?:\}\}|[%\}])\}$/,alias:"punctuation"},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},keyword:/\b(?:as|assign|break|(?:end)?(?:capture|case|comment|for|form|if|paginate|raw|style|tablerow|unless)|continue|cycle|decrement|echo|else|elsif|in|include|increment|limit|liquid|offset|range|render|reversed|section|when|with)\b/,object:/\b(?:address|all_country_option_tags|article|block|blog|cart|checkout|collection|color|country|country_option_tags|currency|current_page|current_tags|customer|customer_address|date|discount_allocation|discount_application|external_video|filter|filter_value|font|forloop|fulfillment|generic_file|gift_card|group|handle|image|line_item|link|linklist|localization|location|measurement|media|metafield|model|model_source|order|page|page_description|page_image|page_title|part|policy|product|product_option|recommendations|request|robots|routes|rule|script|search|selling_plan|selling_plan_allocation|selling_plan_group|shipping_method|shop|shop_locale|sitemap|store_availability|tax_line|template|theme|transaction|unit_price_measurement|user_agent|variant|video|video_source)\b/,function:[{pattern:/(\|\s*)\w+/,lookbehind:!0,alias:"filter"},{pattern:/(\.\s*)(?:first|last|size)/,lookbehind:!0}],boolean:/\b(?:false|nil|true)\b/,range:{pattern:/\.\./,alias:"operator"},number:/\b\d+(?:\.\d+)?\b/,operator:/[!=]=|<>|[<>]=?|[|?:=-]|\b(?:and|contains(?=\s)|or)\b/,punctuation:/[.,\[\]()]/,empty:{pattern:/\bempty\b/,alias:"keyword"}},Ye.hooks.add("before-tokenize",function(tt){var rt=/\{%\s*comment\s*%\}[\s\S]*?\{%\s*endcomment\s*%\}|\{(?:%[\s\S]*?%|\{\{[\s\S]*?\}\}|\{[\s\S]*?\})\}/g,nt=!1;Ye.languages["markup-templating"].buildPlaceholders(tt,"liquid",rt,function(at){var it=/^\{%-?\s*(\w+)/.exec(at);if(it){var ot=it[1];if(ot==="raw"&&!nt)return nt=!0,!0;if(ot==="endraw")return nt=!1,!0}return!nt})}),Ye.hooks.add("after-tokenize",function(tt){Ye.languages["markup-templating"].tokenizePlaceholders(tt,"liquid")})}return liquid_1}var lisp_1,hasRequiredLisp;function requireLisp(){if(hasRequiredLisp)return lisp_1;hasRequiredLisp=1,lisp_1=e,e.displayName="lisp",e.aliases=[];function e(t){(function(Ye){function tt(Ht){return RegExp(/(\()/.source+"(?:"+Ht+")"+/(?=[\s\)])/.source)}function rt(Ht){return RegExp(/([\s([])/.source+"(?:"+Ht+")"+/(?=[\s)])/.source)}var nt=/(?!\d)[-+*/~!@$%^=<>{}\w]+/.source,at="&"+nt,it="(\\()",ot="(?=\\))",ct="(?=\\s)",At=/(?:[^()]|\((?:[^()]|\((?:[^()]|\((?:[^()]|\((?:[^()]|\([^()]*\))*\))*\))*\))*\))*/.source,Rt={heading:{pattern:/;;;.*/,alias:["comment","title"]},comment:/;.*/,string:{pattern:/"(?:[^"\\]|\\.)*"/,greedy:!0,inside:{argument:/[-A-Z]+(?=[.,\s])/,symbol:RegExp("`"+nt+"'")}},"quoted-symbol":{pattern:RegExp("#?'"+nt),alias:["variable","symbol"]},"lisp-property":{pattern:RegExp(":"+nt),alias:"property"},splice:{pattern:RegExp(",@?"+nt),alias:["symbol","variable"]},keyword:[{pattern:RegExp(it+"(?:and|(?:cl-)?letf|cl-loop|cond|cons|error|if|(?:lexical-)?let\\*?|message|not|null|or|provide|require|setq|unless|use-package|when|while)"+ct),lookbehind:!0},{pattern:RegExp(it+"(?:append|by|collect|concat|do|finally|for|in|return)"+ct),lookbehind:!0}],declare:{pattern:tt(/declare/.source),lookbehind:!0,alias:"keyword"},interactive:{pattern:tt(/interactive/.source),lookbehind:!0,alias:"keyword"},boolean:{pattern:rt(/nil|t/.source),lookbehind:!0},number:{pattern:rt(/[-+]?\d+(?:\.\d*)?/.source),lookbehind:!0},defvar:{pattern:RegExp(it+"def(?:const|custom|group|var)\\s+"+nt),lookbehind:!0,inside:{keyword:/^def[a-z]+/,variable:RegExp(nt)}},defun:{pattern:RegExp(it+/(?:cl-)?(?:defmacro|defun\*?)\s+/.source+nt+/\s+\(/.source+At+/\)/.source),lookbehind:!0,greedy:!0,inside:{keyword:/^(?:cl-)?def\S+/,arguments:null,function:{pattern:RegExp("(^\\s)"+nt),lookbehind:!0},punctuation:/[()]/}},lambda:{pattern:RegExp(it+"lambda\\s+\\(\\s*(?:&?"+nt+"(?:\\s+&?"+nt+")*\\s*)?\\)"),lookbehind:!0,greedy:!0,inside:{keyword:/^lambda/,arguments:null,punctuation:/[()]/}},car:{pattern:RegExp(it+nt),lookbehind:!0},punctuation:[/(?:['`,]?\(|[)\[\]])/,{pattern:/(\s)\.(?=\s)/,lookbehind:!0}]},qt={"lisp-marker":RegExp(at),varform:{pattern:RegExp(/\(/.source+nt+/\s+(?=\S)/.source+At+/\)/.source),inside:Rt},argument:{pattern:RegExp(/(^|[\s(])/.source+nt),lookbehind:!0,alias:"variable"},rest:Rt},Ft="\\S+(?:\\s+\\S+)*",Ut={pattern:RegExp(it+At+ot),lookbehind:!0,inside:{"rest-vars":{pattern:RegExp("&(?:body|rest)\\s+"+Ft),inside:qt},"other-marker-vars":{pattern:RegExp("&(?:aux|optional)\\s+"+Ft),inside:qt},keys:{pattern:RegExp("&key\\s+"+Ft+"(?:\\s+&allow-other-keys)?"),inside:qt},argument:{pattern:RegExp(nt),alias:"variable"},punctuation:/[()]/}};Rt.lambda.inside.arguments=Ut,Rt.defun.inside.arguments=Ye.util.clone(Ut),Rt.defun.inside.arguments.inside.sublist=Ut,Ye.languages.lisp=Rt,Ye.languages.elisp=Rt,Ye.languages.emacs=Rt,Ye.languages["emacs-lisp"]=Rt})(t)}return lisp_1}var livescript_1,hasRequiredLivescript;function requireLivescript(){if(hasRequiredLivescript)return livescript_1;hasRequiredLivescript=1,livescript_1=e,e.displayName="livescript",e.aliases=[];function e(t){t.languages.livescript={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?\*\//,lookbehind:!0},{pattern:/(^|[^\\])#.*/,lookbehind:!0}],"interpolated-string":{pattern:/(^|[^"])("""|")(?:\\[\s\S]|(?!\2)[^\\])*\2(?!")/,lookbehind:!0,greedy:!0,inside:{variable:{pattern:/(^|[^\\])#[a-z_](?:-?[a-z]|[\d_])*/m,lookbehind:!0},interpolation:{pattern:/(^|[^\\])#\{[^}]+\}/m,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^#\{|\}$/,alias:"variable"}}},string:/[\s\S]+/}},string:[{pattern:/('''|')(?:\\[\s\S]|(?!\1)[^\\])*\1/,greedy:!0},{pattern:/<\[[\s\S]*?\]>/,greedy:!0},/\\[^\s,;\])}]+/],regex:[{pattern:/\/\/(?:\[[^\r\n\]]*\]|\\.|(?!\/\/)[^\\\[])+\/\/[gimyu]{0,5}/,greedy:!0,inside:{comment:{pattern:/(^|[^\\])#.*/,lookbehind:!0}}},{pattern:/\/(?:\[[^\r\n\]]*\]|\\.|[^/\\\r\n\[])+\/[gimyu]{0,5}/,greedy:!0}],keyword:{pattern:/(^|(?!-).)\b(?:break|case|catch|class|const|continue|default|do|else|extends|fallthrough|finally|for(?: ever)?|function|if|implements|it|let|loop|new|null|otherwise|own|return|super|switch|that|then|this|throw|try|unless|until|var|void|when|while|yield)(?!-)\b/m,lookbehind:!0},"keyword-operator":{pattern:/(^|[^-])\b(?:(?:delete|require|typeof)!|(?:and|by|delete|export|from|import(?: all)?|in|instanceof|is(?: not|nt)?|not|of|or|til|to|typeof|with|xor)(?!-)\b)/m,lookbehind:!0,alias:"operator"},boolean:{pattern:/(^|[^-])\b(?:false|no|off|on|true|yes)(?!-)\b/m,lookbehind:!0},argument:{pattern:/(^|(?!\.&\.)[^&])&(?!&)\d*/m,lookbehind:!0,alias:"variable"},number:/\b(?:\d+~[\da-z]+|\d[\d_]*(?:\.\d[\d_]*)?(?:[a-z]\w*)?)/i,identifier:/[a-z_](?:-?[a-z]|[\d_])*/i,operator:[{pattern:/( )\.(?= )/,lookbehind:!0},/\.(?:[=~]|\.\.?)|\.(?:[&|^]|<<|>>>?)\.|:(?:=|:=?)|&&|\|[|>]|<(?:<<?<?|--?!?|~~?!?|[|=?])?|>[>=?]?|-(?:->?|>)?|\+\+?|@@?|%%?|\*\*?|!(?:~?=|--?>|~?~>)?|~(?:~?>|=)?|==?|\^\^?|[\/?]/],punctuation:/[(){}\[\]|.,:;`]/},t.languages.livescript["interpolated-string"].inside.interpolation.inside.rest=t.languages.livescript}return livescript_1}var llvm_1,hasRequiredLlvm;function requireLlvm(){if(hasRequiredLlvm)return llvm_1;hasRequiredLlvm=1,llvm_1=e,e.displayName="llvm",e.aliases=[];function e(t){(function(Ye){Ye.languages.llvm={comment:/;.*/,string:{pattern:/"[^"]*"/,greedy:!0},boolean:/\b(?:false|true)\b/,variable:/[%@!#](?:(?!\d)(?:[-$.\w]|\\[a-f\d]{2})+|\d+)/i,label:/(?!\d)(?:[-$.\w]|\\[a-f\d]{2})+:/i,type:{pattern:/\b(?:double|float|fp128|half|i[1-9]\d*|label|metadata|ppc_fp128|token|void|x86_fp80|x86_mmx)\b/,alias:"class-name"},keyword:/\b[a-z_][a-z_0-9]*\b/,number:/[+-]?\b\d+(?:\.\d+)?(?:[eE][+-]?\d+)?\b|\b0x[\dA-Fa-f]+\b|\b0xK[\dA-Fa-f]{20}\b|\b0x[ML][\dA-Fa-f]{32}\b|\b0xH[\dA-Fa-f]{4}\b/,punctuation:/[{}[\];(),.!*=<>]/}})(t)}return llvm_1}var log_1,hasRequiredLog;function requireLog(){if(hasRequiredLog)return log_1;hasRequiredLog=1,log_1=e,e.displayName="log",e.aliases=[];function e(t){t.languages.log={string:{pattern:/"(?:[^"\\\r\n]|\\.)*"|'(?![st] | \w)(?:[^'\\\r\n]|\\.)*'/,greedy:!0},exception:{pattern:/(^|[^\w.])[a-z][\w.]*(?:Error|Exception):.*(?:(?:\r\n?|\n)[ \t]*(?:at[ \t].+|\.{3}.*|Caused by:.*))+(?:(?:\r\n?|\n)[ \t]*\.\.\. .*)?/,lookbehind:!0,greedy:!0,alias:["javastacktrace","language-javastacktrace"],inside:t.languages.javastacktrace||{keyword:/\bat\b/,function:/[a-z_][\w$]*(?=\()/,punctuation:/[.:()]/}},level:[{pattern:/\b(?:ALERT|CRIT|CRITICAL|EMERG|EMERGENCY|ERR|ERROR|FAILURE|FATAL|SEVERE)\b/,alias:["error","important"]},{pattern:/\b(?:WARN|WARNING|WRN)\b/,alias:["warning","important"]},{pattern:/\b(?:DISPLAY|INF|INFO|NOTICE|STATUS)\b/,alias:["info","keyword"]},{pattern:/\b(?:DBG|DEBUG|FINE)\b/,alias:["debug","keyword"]},{pattern:/\b(?:FINER|FINEST|TRACE|TRC|VERBOSE|VRB)\b/,alias:["trace","comment"]}],property:{pattern:/((?:^|[\]|])[ \t]*)[a-z_](?:[\w-]|\b\/\b)*(?:[. ]\(?\w(?:[\w-]|\b\/\b)*\)?)*:(?=\s)/im,lookbehind:!0},separator:{pattern:/(^|[^-+])-{3,}|={3,}|\*{3,}|- - /m,lookbehind:!0,alias:"comment"},url:/\b(?:file|ftp|https?):\/\/[^\s|,;'"]*[^\s|,;'">.]/,email:{pattern:/(^|\s)[-\w+.]+@[a-z][a-z0-9-]*(?:\.[a-z][a-z0-9-]*)+(?=\s)/,lookbehind:!0,alias:"url"},"ip-address":{pattern:/\b(?:\d{1,3}(?:\.\d{1,3}){3})\b/,alias:"constant"},"mac-address":{pattern:/\b[a-f0-9]{2}(?::[a-f0-9]{2}){5}\b/i,alias:"constant"},domain:{pattern:/(^|\s)[a-z][a-z0-9-]*(?:\.[a-z][a-z0-9-]*)*\.[a-z][a-z0-9-]+(?=\s)/,lookbehind:!0,alias:"constant"},uuid:{pattern:/\b[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}\b/i,alias:"constant"},hash:{pattern:/\b(?:[a-f0-9]{32}){1,2}\b/i,alias:"constant"},"file-path":{pattern:/\b[a-z]:[\\/][^\s|,;:(){}\[\]"']+|(^|[\s:\[\](>|])\.{0,2}\/\w[^\s|,;:(){}\[\]"']*/i,lookbehind:!0,greedy:!0,alias:"string"},date:{pattern:RegExp(/\b\d{4}[-/]\d{2}[-/]\d{2}(?:T(?=\d{1,2}:)|(?=\s\d{1,2}:))/.source+"|"+/\b\d{1,4}[-/ ](?:\d{1,2}|Apr|Aug|Dec|Feb|Jan|Jul|Jun|Mar|May|Nov|Oct|Sep)[-/ ]\d{2,4}T?\b/.source+"|"+/\b(?:(?:Fri|Mon|Sat|Sun|Thu|Tue|Wed)(?:\s{1,2}(?:Apr|Aug|Dec|Feb|Jan|Jul|Jun|Mar|May|Nov|Oct|Sep))?|Apr|Aug|Dec|Feb|Jan|Jul|Jun|Mar|May|Nov|Oct|Sep)\s{1,2}\d{1,2}\b/.source,"i"),alias:"number"},time:{pattern:/\b\d{1,2}:\d{1,2}:\d{1,2}(?:[.,:]\d+)?(?:\s?[+-]\d{2}:?\d{2}|Z)?\b/,alias:"number"},boolean:/\b(?:false|null|true)\b/i,number:{pattern:/(^|[^.\w])(?:0x[a-f0-9]+|0o[0-7]+|0b[01]+|v?\d[\da-f]*(?:\.\d+)*(?:e[+-]?\d+)?[a-z]{0,3}\b)\b(?!\.\w)/i,lookbehind:!0},operator:/[;:?<=>~/@!$%&+\-|^(){}*#]/,punctuation:/[\[\].,]/}}return log_1}var lolcode_1,hasRequiredLolcode;function requireLolcode(){if(hasRequiredLolcode)return lolcode_1;hasRequiredLolcode=1,lolcode_1=e,e.displayName="lolcode",e.aliases=[];function e(t){t.languages.lolcode={comment:[/\bOBTW\s[\s\S]*?\sTLDR\b/,/\bBTW.+/],string:{pattern:/"(?::.|[^":])*"/,inside:{variable:/:\{[^}]+\}/,symbol:[/:\([a-f\d]+\)/i,/:\[[^\]]+\]/,/:[)>o":]/]},greedy:!0},number:/(?:\B-)?(?:\b\d+(?:\.\d*)?|\B\.\d+)/,symbol:{pattern:/(^|\s)(?:A )?(?:BUKKIT|NOOB|NUMBAR|NUMBR|TROOF|YARN)(?=\s|,|$)/,lookbehind:!0,inside:{keyword:/A(?=\s)/}},label:{pattern:/((?:^|\s)(?:IM IN YR|IM OUTTA YR) )[a-zA-Z]\w*/,lookbehind:!0,alias:"string"},function:{pattern:/((?:^|\s)(?:HOW IZ I|I IZ|IZ) )[a-zA-Z]\w*/,lookbehind:!0},keyword:[{pattern:/(^|\s)(?:AN|FOUND YR|GIMMEH|GTFO|HAI|HAS A|HOW IZ I|I HAS A|I IZ|IF U SAY SO|IM IN YR|IM OUTTA YR|IS NOW(?: A)?|ITZ(?: A)?|IZ|KTHX|KTHXBYE|LIEK(?: A)?|MAEK|MEBBE|MKAY|NERFIN|NO WAI|O HAI IM|O RLY\?|OIC|OMG|OMGWTF|R|SMOOSH|SRS|TIL|UPPIN|VISIBLE|WILE|WTF\?|YA RLY|YR)(?=\s|,|$)/,lookbehind:!0},/'Z(?=\s|,|$)/],boolean:{pattern:/(^|\s)(?:FAIL|WIN)(?=\s|,|$)/,lookbehind:!0},variable:{pattern:/(^|\s)IT(?=\s|,|$)/,lookbehind:!0},operator:{pattern:/(^|\s)(?:NOT|BOTH SAEM|DIFFRINT|(?:ALL|ANY|BIGGR|BOTH|DIFF|EITHER|MOD|PRODUKT|QUOSHUNT|SMALLR|SUM|WON) OF)(?=\s|,|$)/,lookbehind:!0},punctuation:/\.{3}|…|,|!/}}return lolcode_1}var magma_1,hasRequiredMagma;function requireMagma(){if(hasRequiredMagma)return magma_1;hasRequiredMagma=1,magma_1=e,e.displayName="magma",e.aliases=[];function e(t){t.languages.magma={output:{pattern:/^(>.*(?:\r(?:\n|(?!\n))|\n))(?!>)(?:.+|(?:\r(?:\n|(?!\n))|\n)(?!>).*)(?:(?:\r(?:\n|(?!\n))|\n)(?!>).*)*/m,lookbehind:!0,greedy:!0},comment:{pattern:/\/\/.*|\/\*[\s\S]*?\*\//,greedy:!0},string:{pattern:/(^|[^\\"])"(?:[^\r\n\\"]|\\.)*"/,lookbehind:!0,greedy:!0},keyword:/\b(?:_|adj|and|assert|assert2|assert3|assigned|break|by|case|cat|catch|clear|cmpeq|cmpne|continue|declare|default|delete|diff|div|do|elif|else|end|eq|error|eval|exists|exit|for|forall|forward|fprintf|freeze|function|ge|gt|if|iload|import|in|intrinsic|is|join|le|load|local|lt|meet|mod|ne|not|notadj|notin|notsubset|or|print|printf|procedure|quit|random|read|readi|repeat|require|requirege|requirerange|restore|return|save|sdiff|select|subset|then|time|to|try|until|vprint|vprintf|vtime|when|where|while|xor)\b/,boolean:/\b(?:false|true)\b/,generator:{pattern:/\b[a-z_]\w*(?=\s*<)/i,alias:"class-name"},function:/\b[a-z_]\w*(?=\s*\()/i,number:{pattern:/(^|[^\w.]|\.\.)(?:\d+(?:\.\d*)?|\.\d+)(?:[eE][+-]?\d+)?(?:_[a-z]?)?(?=$|[^\w.]|\.\.)/,lookbehind:!0},operator:/->|[-+*/^~!|#=]|:=|\.\./,punctuation:/[()[\]{}<>,;.:]/}}return magma_1}var makefile_1,hasRequiredMakefile;function requireMakefile(){if(hasRequiredMakefile)return makefile_1;hasRequiredMakefile=1,makefile_1=e,e.displayName="makefile",e.aliases=[];function e(t){t.languages.makefile={comment:{pattern:/(^|[^\\])#(?:\\(?:\r\n|[\s\S])|[^\\\r\n])*/,lookbehind:!0},string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"builtin-target":{pattern:/\.[A-Z][^:#=\s]+(?=\s*:(?!=))/,alias:"builtin"},target:{pattern:/^(?:[^:=\s]|[ \t]+(?![\s:]))+(?=\s*:(?!=))/m,alias:"symbol",inside:{variable:/\$+(?:(?!\$)[^(){}:#=\s]+|(?=[({]))/}},variable:/\$+(?:(?!\$)[^(){}:#=\s]+|\([@*%<^+?][DF]\)|(?=[({]))/,keyword:/-include\b|\b(?:define|else|endef|endif|export|ifn?def|ifn?eq|include|override|private|sinclude|undefine|unexport|vpath)\b/,function:{pattern:/(\()(?:abspath|addsuffix|and|basename|call|dir|error|eval|file|filter(?:-out)?|findstring|firstword|flavor|foreach|guile|if|info|join|lastword|load|notdir|or|origin|patsubst|realpath|shell|sort|strip|subst|suffix|value|warning|wildcard|word(?:list|s)?)(?=[ \t])/,lookbehind:!0},operator:/(?:::|[?:+!])?=|[|@]/,punctuation:/[:;(){}]/}}return makefile_1}var markdown_1,hasRequiredMarkdown;function requireMarkdown(){if(hasRequiredMarkdown)return markdown_1;hasRequiredMarkdown=1,markdown_1=e,e.displayName="markdown",e.aliases=["md"];function e(t){(function(Ye){var tt=/(?:\\.|[^\\\n\r]|(?:\n|\r\n?)(?![\r\n]))/.source;function rt(qt){return qt=qt.replace(/<inner>/g,function(){return tt}),RegExp(/((?:^|[^\\])(?:\\{2})*)/.source+"(?:"+qt+")")}var nt=/(?:\\.|``(?:[^`\r\n]|`(?!`))+``|`[^`\r\n]+`|[^\\|\r\n`])+/.source,at=/\|?__(?:\|__)+\|?(?:(?:\n|\r\n?)|(?![\s\S]))/.source.replace(/__/g,function(){return nt}),it=/\|?[ \t]*:?-{3,}:?[ \t]*(?:\|[ \t]*:?-{3,}:?[ \t]*)+\|?(?:\n|\r\n?)/.source;Ye.languages.markdown=Ye.languages.extend("markup",{}),Ye.languages.insertBefore("markdown","prolog",{"front-matter-block":{pattern:/(^(?:\s*[\r\n])?)---(?!.)[\s\S]*?[\r\n]---(?!.)/,lookbehind:!0,greedy:!0,inside:{punctuation:/^---|---$/,"front-matter":{pattern:/\S+(?:\s+\S+)*/,alias:["yaml","language-yaml"],inside:Ye.languages.yaml}}},blockquote:{pattern:/^>(?:[\t ]*>)*/m,alias:"punctuation"},table:{pattern:RegExp("^"+at+it+"(?:"+at+")*","m"),inside:{"table-data-rows":{pattern:RegExp("^("+at+it+")(?:"+at+")*$"),lookbehind:!0,inside:{"table-data":{pattern:RegExp(nt),inside:Ye.languages.markdown},punctuation:/\|/}},"table-line":{pattern:RegExp("^("+at+")"+it+"$"),lookbehind:!0,inside:{punctuation:/\||:?-{3,}:?/}},"table-header-row":{pattern:RegExp("^"+at+"$"),inside:{"table-header":{pattern:RegExp(nt),alias:"important",inside:Ye.languages.markdown},punctuation:/\|/}}}},code:[{pattern:/((?:^|\n)[ \t]*\n|(?:^|\r\n?)[ \t]*\r\n?)(?: {4}|\t).+(?:(?:\n|\r\n?)(?: {4}|\t).+)*/,lookbehind:!0,alias:"keyword"},{pattern:/^```[\s\S]*?^```$/m,greedy:!0,inside:{"code-block":{pattern:/^(```.*(?:\n|\r\n?))[\s\S]+?(?=(?:\n|\r\n?)^```$)/m,lookbehind:!0},"code-language":{pattern:/^(```).+/,lookbehind:!0},punctuation:/```/}}],title:[{pattern:/\S.*(?:\n|\r\n?)(?:==+|--+)(?=[ \t]*$)/m,alias:"important",inside:{punctuation:/==+$|--+$/}},{pattern:/(^\s*)#.+/m,lookbehind:!0,alias:"important",inside:{punctuation:/^#+|#+$/}}],hr:{pattern:/(^\s*)([*-])(?:[\t ]*\2){2,}(?=\s*$)/m,lookbehind:!0,alias:"punctuation"},list:{pattern:/(^\s*)(?:[*+-]|\d+\.)(?=[\t ].)/m,lookbehind:!0,alias:"punctuation"},"url-reference":{pattern:/!?\[[^\]]+\]:[\t ]+(?:\S+|<(?:\\.|[^>\\])+>)(?:[\t ]+(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\)))?/,inside:{variable:{pattern:/^(!?\[)[^\]]+/,lookbehind:!0},string:/(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\))$/,punctuation:/^[\[\]!:]|[<>]/},alias:"url"},bold:{pattern:rt(/\b__(?:(?!_)<inner>|_(?:(?!_)<inner>)+_)+__\b|\*\*(?:(?!\*)<inner>|\*(?:(?!\*)<inner>)+\*)+\*\*/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^..)[\s\S]+(?=..$)/,lookbehind:!0,inside:{}},punctuation:/\*\*|__/}},italic:{pattern:rt(/\b_(?:(?!_)<inner>|__(?:(?!_)<inner>)+__)+_\b|\*(?:(?!\*)<inner>|\*\*(?:(?!\*)<inner>)+\*\*)+\*/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^.)[\s\S]+(?=.$)/,lookbehind:!0,inside:{}},punctuation:/[*_]/}},strike:{pattern:rt(/(~~?)(?:(?!~)<inner>)+\2/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^~~?)[\s\S]+(?=\1$)/,lookbehind:!0,inside:{}},punctuation:/~~?/}},"code-snippet":{pattern:/(^|[^\\`])(?:``[^`\r\n]+(?:`[^`\r\n]+)*``(?!`)|`[^`\r\n]+`(?!`))/,lookbehind:!0,greedy:!0,alias:["code","keyword"]},url:{pattern:rt(/!?\[(?:(?!\])<inner>)+\](?:\([^\s)]+(?:[\t ]+"(?:\\.|[^"\\])*")?\)|[ \t]?\[(?:(?!\])<inner>)+\])/.source),lookbehind:!0,greedy:!0,inside:{operator:/^!/,content:{pattern:/(^\[)[^\]]+(?=\])/,lookbehind:!0,inside:{}},variable:{pattern:/(^\][ \t]?\[)[^\]]+(?=\]$)/,lookbehind:!0},url:{pattern:/(^\]\()[^\s)]+/,lookbehind:!0},string:{pattern:/(^[ \t]+)"(?:\\.|[^"\\])*"(?=\)$)/,lookbehind:!0}}}}),["url","bold","italic","strike"].forEach(function(qt){["url","bold","italic","strike","code-snippet"].forEach(function(Ft){qt!==Ft&&(Ye.languages.markdown[qt].inside.content.inside[Ft]=Ye.languages.markdown[Ft])})}),Ye.hooks.add("after-tokenize",function(qt){if(qt.language!=="markdown"&&qt.language!=="md")return;function Ft(Ut){if(!(!Ut||typeof Ut=="string"))for(var Ht=0,zt=Ut.length;Ht<zt;Ht++){var Yt=Ut[Ht];if(Yt.type!=="code"){Ft(Yt.content);continue}var Gt=Yt.content[1],Vt=Yt.content[3];if(Gt&&Vt&&Gt.type==="code-language"&&Vt.type==="code-block"&&typeof Gt.content=="string"){var Zt=Gt.content.replace(/\b#/g,"sharp").replace(/\b\+\+/g,"pp");Zt=(/[a-z][\w-]*/i.exec(Zt)||[""])[0].toLowerCase();var Xt="language-"+Zt;Vt.alias?typeof Vt.alias=="string"?Vt.alias=[Vt.alias,Xt]:Vt.alias.push(Xt):Vt.alias=[Xt]}}}Ft(qt.tokens)}),Ye.hooks.add("wrap",function(qt){if(qt.type==="code-block"){for(var Ft="",Ut=0,Ht=qt.classes.length;Ut<Ht;Ut++){var zt=qt.classes[Ut],Yt=/language-(.+)/.exec(zt);if(Yt){Ft=Yt[1];break}}var Gt=Ye.languages[Ft];if(Gt)qt.content=Ye.highlight(Rt(qt.content.value),Gt,Ft);else if(Ft&&Ft!=="none"&&Ye.plugins.autoloader){var Vt="md-"+new Date().valueOf()+"-"+Math.floor(Math.random()*1e16);qt.attributes.id=Vt,Ye.plugins.autoloader.loadLanguages(Ft,function(){var Zt=document.getElementById(Vt);Zt&&(Zt.innerHTML=Ye.highlight(Zt.textContent,Ye.languages[Ft],Ft))})}}});var ot=RegExp(Ye.languages.markup.tag.pattern.source,"gi"),ct={amp:"&",lt:"<",gt:">",quot:'"'},At=String.fromCodePoint||String.fromCharCode;function Rt(qt){var Ft=qt.replace(ot,"");return Ft=Ft.replace(/&(\w{1,8}|#x?[\da-f]{1,8});/gi,function(Ut,Ht){if(Ht=Ht.toLowerCase(),Ht[0]==="#"){var zt;return Ht[1]==="x"?zt=parseInt(Ht.slice(2),16):zt=Number(Ht.slice(1)),At(zt)}else{var Yt=ct[Ht];return Yt||Ut}}),Ft}Ye.languages.md=Ye.languages.markdown})(t)}return markdown_1}var matlab_1,hasRequiredMatlab;function requireMatlab(){if(hasRequiredMatlab)return matlab_1;hasRequiredMatlab=1,matlab_1=e,e.displayName="matlab",e.aliases=[];function e(t){t.languages.matlab={comment:[/%\{[\s\S]*?\}%/,/%.+/],string:{pattern:/\B'(?:''|[^'\r\n])*'/,greedy:!0},number:/(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[eE][+-]?\d+)?(?:[ij])?|\b[ij]\b/,keyword:/\b(?:NaN|break|case|catch|continue|else|elseif|end|for|function|if|inf|otherwise|parfor|pause|pi|return|switch|try|while)\b/,function:/\b(?!\d)\w+(?=\s*\()/,operator:/\.?[*^\/\\']|[+\-:@]|[<>=~]=?|&&?|\|\|?/,punctuation:/\.{3}|[.,;\[\](){}!]/}}return matlab_1}var maxscript_1,hasRequiredMaxscript;function requireMaxscript(){if(hasRequiredMaxscript)return maxscript_1;hasRequiredMaxscript=1,maxscript_1=e,e.displayName="maxscript",e.aliases=[];function e(t){(function(Ye){var tt=/\b(?:about|and|animate|as|at|attributes|by|case|catch|collect|continue|coordsys|do|else|exit|fn|for|from|function|global|if|in|local|macroscript|mapped|max|not|of|off|on|or|parameters|persistent|plugin|rcmenu|return|rollout|set|struct|then|throw|to|tool|try|undo|utility|when|where|while|with)\b/i;Ye.languages.maxscript={comment:{pattern:/\/\*[\s\S]*?(?:\*\/|$)|--.*/,greedy:!0},string:{pattern:/(^|[^"\\@])(?:"(?:[^"\\]|\\[\s\S])*"|@"[^"]*")/,lookbehind:!0,greedy:!0},path:{pattern:/\$(?:[\w/\\.*?]|'[^']*')*/,greedy:!0,alias:"string"},"function-call":{pattern:RegExp("((?:"+(/^/.source+"|"+/[;=<>+\-*/^({\[]/.source+"|"+/\b(?:and|by|case|catch|collect|do|else|if|in|not|or|return|then|to|try|where|while|with)\b/.source)+")[ ]*)(?!"+tt.source+")"+/[a-z_]\w*\b/.source+"(?=[ ]*(?:"+("(?!"+tt.source+")"+/[a-z_]/.source+"|"+/\d|-\.?\d/.source+"|"+/[({'"$@#?]/.source)+"))","im"),lookbehind:!0,greedy:!0,alias:"function"},"function-definition":{pattern:/(\b(?:fn|function)\s+)\w+\b/i,lookbehind:!0,alias:"function"},argument:{pattern:/\b[a-z_]\w*(?=:)/i,alias:"attr-name"},keyword:tt,boolean:/\b(?:false|true)\b/,time:{pattern:/(^|[^\w.])(?:(?:(?:\d+(?:\.\d*)?|\.\d+)(?:[eEdD][+-]\d+|[LP])?[msft])+|\d+:\d+(?:\.\d*)?)(?![\w.:])/,lookbehind:!0,alias:"number"},number:[{pattern:/(^|[^\w.])(?:(?:\d+(?:\.\d*)?|\.\d+)(?:[eEdD][+-]\d+|[LP])?|0x[a-fA-F0-9]+)(?![\w.:])/,lookbehind:!0},/\b(?:e|pi)\b/],constant:/\b(?:dontcollect|ok|silentValue|undefined|unsupplied)\b/,color:{pattern:/\b(?:black|blue|brown|gray|green|orange|red|white|yellow)\b/i,alias:"constant"},operator:/[-+*/<>=!]=?|[&^?]|#(?!\()/,punctuation:/[()\[\]{}.:,;]|#(?=\()|\\$/m}})(t)}return maxscript_1}var mel_1,hasRequiredMel;function requireMel(){if(hasRequiredMel)return mel_1;hasRequiredMel=1,mel_1=e,e.displayName="mel",e.aliases=[];function e(t){t.languages.mel={comment:/\/\/.*/,code:{pattern:/`(?:\\.|[^\\`\r\n])*`/,greedy:!0,alias:"italic",inside:{delimiter:{pattern:/^`|`$/,alias:"punctuation"}}},string:{pattern:/"(?:\\.|[^\\"\r\n])*"/,greedy:!0},variable:/\$\w+/,number:/\b0x[\da-fA-F]+\b|\b\d+(?:\.\d*)?|\B\.\d+/,flag:{pattern:/-[^\d\W]\w*/,alias:"operator"},keyword:/\b(?:break|case|continue|default|do|else|float|for|global|if|in|int|matrix|proc|return|string|switch|vector|while)\b/,function:/\b\w+(?=\()|\b(?:CBG|HfAddAttractorToAS|HfAssignAS|HfBuildEqualMap|HfBuildFurFiles|HfBuildFurImages|HfCancelAFR|HfConnectASToHF|HfCreateAttractor|HfDeleteAS|HfEditAS|HfPerformCreateAS|HfRemoveAttractorFromAS|HfSelectAttached|HfSelectAttractors|HfUnAssignAS|Mayatomr|about|abs|addAttr|addAttributeEditorNodeHelp|addDynamic|addNewShelfTab|addPP|addPanelCategory|addPrefixToName|advanceToNextDrivenKey|affectedNet|affects|aimConstraint|air|alias|aliasAttr|align|alignCtx|alignCurve|alignSurface|allViewFit|ambientLight|angle|angleBetween|animCone|animCurveEditor|animDisplay|animView|annotate|appendStringArray|applicationName|applyAttrPreset|applyTake|arcLenDimContext|arcLengthDimension|arclen|arrayMapper|art3dPaintCtx|artAttrCtx|artAttrPaintVertexCtx|artAttrSkinPaintCtx|artAttrTool|artBuildPaintMenu|artFluidAttrCtx|artPuttyCtx|artSelectCtx|artSetPaintCtx|artUserPaintCtx|assignCommand|assignInputDevice|assignViewportFactories|attachCurve|attachDeviceAttr|attachSurface|attrColorSliderGrp|attrCompatibility|attrControlGrp|attrEnumOptionMenu|attrEnumOptionMenuGrp|attrFieldGrp|attrFieldSliderGrp|attrNavigationControlGrp|attrPresetEditWin|attributeExists|attributeInfo|attributeMenu|attributeQuery|autoKeyframe|autoPlace|bakeClip|bakeFluidShading|bakePartialHistory|bakeResults|bakeSimulation|basename|basenameEx|batchRender|bessel|bevel|bevelPlus|binMembership|bindSkin|blend2|blendShape|blendShapeEditor|blendShapePanel|blendTwoAttr|blindDataType|boneLattice|boundary|boxDollyCtx|boxZoomCtx|bufferCurve|buildBookmarkMenu|buildKeyframeMenu|button|buttonManip|cacheFile|cacheFileCombine|cacheFileMerge|cacheFileTrack|camera|cameraView|canCreateManip|canvas|capitalizeString|catch|catchQuiet|ceil|changeSubdivComponentDisplayLevel|changeSubdivRegion|channelBox|character|characterMap|characterOutlineEditor|characterize|chdir|checkBox|checkBoxGrp|checkDefaultRenderGlobals|choice|circle|circularFillet|clamp|clear|clearCache|clip|clipEditor|clipEditorCurrentTimeCtx|clipSchedule|clipSchedulerOutliner|clipTrimBefore|closeCurve|closeSurface|cluster|cmdFileOutput|cmdScrollFieldExecuter|cmdScrollFieldReporter|cmdShell|coarsenSubdivSelectionList|collision|color|colorAtPoint|colorEditor|colorIndex|colorIndexSliderGrp|colorSliderButtonGrp|colorSliderGrp|columnLayout|commandEcho|commandLine|commandPort|compactHairSystem|componentEditor|compositingInterop|computePolysetVolume|condition|cone|confirmDialog|connectAttr|connectControl|connectDynamic|connectJoint|connectionInfo|constrain|constrainValue|constructionHistory|container|containsMultibyte|contextInfo|control|convertFromOldLayers|convertIffToPsd|convertLightmap|convertSolidTx|convertTessellation|convertUnit|copyArray|copyFlexor|copyKey|copySkinWeights|cos|cpButton|cpCache|cpClothSet|cpCollision|cpConstraint|cpConvClothToMesh|cpForces|cpGetSolverAttr|cpPanel|cpProperty|cpRigidCollisionFilter|cpSeam|cpSetEdit|cpSetSolverAttr|cpSolver|cpSolverTypes|cpTool|cpUpdateClothUVs|createDisplayLayer|createDrawCtx|createEditor|createLayeredPsdFile|createMotionField|createNewShelf|createNode|createRenderLayer|createSubdivRegion|cross|crossProduct|ctxAbort|ctxCompletion|ctxEditMode|ctxTraverse|currentCtx|currentTime|currentTimeCtx|currentUnit|curve|curveAddPtCtx|curveCVCtx|curveEPCtx|curveEditorCtx|curveIntersect|curveMoveEPCtx|curveOnSurface|curveSketchCtx|cutKey|cycleCheck|cylinder|dagPose|date|defaultLightListCheckBox|defaultNavigation|defineDataServer|defineVirtualDevice|deformer|deg_to_rad|delete|deleteAttr|deleteShadingGroupsAndMaterials|deleteShelfTab|deleteUI|deleteUnusedBrushes|delrandstr|detachCurve|detachDeviceAttr|detachSurface|deviceEditor|devicePanel|dgInfo|dgdirty|dgeval|dgtimer|dimWhen|directKeyCtx|directionalLight|dirmap|dirname|disable|disconnectAttr|disconnectJoint|diskCache|displacementToPoly|displayAffected|displayColor|displayCull|displayLevelOfDetail|displayPref|displayRGBColor|displaySmoothness|displayStats|displayString|displaySurface|distanceDimContext|distanceDimension|doBlur|dolly|dollyCtx|dopeSheetEditor|dot|dotProduct|doubleProfileBirailSurface|drag|dragAttrContext|draggerContext|dropoffLocator|duplicate|duplicateCurve|duplicateSurface|dynCache|dynControl|dynExport|dynExpression|dynGlobals|dynPaintEditor|dynParticleCtx|dynPref|dynRelEdPanel|dynRelEditor|dynamicLoad|editAttrLimits|editDisplayLayerGlobals|editDisplayLayerMembers|editRenderLayerAdjustment|editRenderLayerGlobals|editRenderLayerMembers|editor|editorTemplate|effector|emit|emitter|enableDevice|encodeString|endString|endsWith|env|equivalent|equivalentTol|erf|error|eval|evalDeferred|evalEcho|event|exactWorldBoundingBox|exclusiveLightCheckBox|exec|executeForEachObject|exists|exp|expression|expressionEditorListen|extendCurve|extendSurface|extrude|fcheck|fclose|feof|fflush|fgetline|fgetword|file|fileBrowserDialog|fileDialog|fileExtension|fileInfo|filetest|filletCurve|filter|filterCurve|filterExpand|filterStudioImport|findAllIntersections|findAnimCurves|findKeyframe|findMenuItem|findRelatedSkinCluster|finder|firstParentOf|fitBspline|flexor|floatEq|floatField|floatFieldGrp|floatScrollBar|floatSlider|floatSlider2|floatSliderButtonGrp|floatSliderGrp|floor|flow|fluidCacheInfo|fluidEmitter|fluidVoxelInfo|flushUndo|fmod|fontDialog|fopen|formLayout|format|fprint|frameLayout|fread|freeFormFillet|frewind|fromNativePath|fwrite|gamma|gauss|geometryConstraint|getApplicationVersionAsFloat|getAttr|getClassification|getDefaultBrush|getFileList|getFluidAttr|getInputDeviceRange|getMayaPanelTypes|getModifiers|getPanel|getParticleAttr|getPluginResource|getenv|getpid|glRender|glRenderEditor|globalStitch|gmatch|goal|gotoBindPose|grabColor|gradientControl|gradientControlNoAttr|graphDollyCtx|graphSelectContext|graphTrackCtx|gravity|grid|gridLayout|group|groupObjectsByName|hardenPointCurve|hardware|hardwareRenderPanel|headsUpDisplay|headsUpMessage|help|helpLine|hermite|hide|hilite|hitTest|hotBox|hotkey|hotkeyCheck|hsv_to_rgb|hudButton|hudSlider|hudSliderButton|hwReflectionMap|hwRender|hwRenderLoad|hyperGraph|hyperPanel|hyperShade|hypot|iconTextButton|iconTextCheckBox|iconTextRadioButton|iconTextRadioCollection|iconTextScrollList|iconTextStaticLabel|ikHandle|ikHandleCtx|ikHandleDisplayScale|ikSolver|ikSplineHandleCtx|ikSystem|ikSystemInfo|ikfkDisplayMethod|illustratorCurves|image|imfPlugins|inheritTransform|insertJoint|insertJointCtx|insertKeyCtx|insertKnotCurve|insertKnotSurface|instance|instanceable|instancer|intField|intFieldGrp|intScrollBar|intSlider|intSliderGrp|interToUI|internalVar|intersect|iprEngine|isAnimCurve|isConnected|isDirty|isParentOf|isSameObject|isTrue|isValidObjectName|isValidString|isValidUiName|isolateSelect|itemFilter|itemFilterAttr|itemFilterRender|itemFilterType|joint|jointCluster|jointCtx|jointDisplayScale|jointLattice|keyTangent|keyframe|keyframeOutliner|keyframeRegionCurrentTimeCtx|keyframeRegionDirectKeyCtx|keyframeRegionDollyCtx|keyframeRegionInsertKeyCtx|keyframeRegionMoveKeyCtx|keyframeRegionScaleKeyCtx|keyframeRegionSelectKeyCtx|keyframeRegionSetKeyCtx|keyframeRegionTrackCtx|keyframeStats|lassoContext|lattice|latticeDeformKeyCtx|launch|launchImageEditor|layerButton|layeredShaderPort|layeredTexturePort|layout|layoutDialog|lightList|lightListEditor|lightListPanel|lightlink|lineIntersection|linearPrecision|linstep|listAnimatable|listAttr|listCameras|listConnections|listDeviceAttachments|listHistory|listInputDeviceAxes|listInputDeviceButtons|listInputDevices|listMenuAnnotation|listNodeTypes|listPanelCategories|listRelatives|listSets|listTransforms|listUnselected|listerEditor|loadFluid|loadNewShelf|loadPlugin|loadPluginLanguageResources|loadPrefObjects|localizedPanelLabel|lockNode|loft|log|longNameOf|lookThru|ls|lsThroughFilter|lsType|lsUI|mag|makeIdentity|makeLive|makePaintable|makeRoll|makeSingleSurface|makeTubeOn|makebot|manipMoveContext|manipMoveLimitsCtx|manipOptions|manipRotateContext|manipRotateLimitsCtx|manipScaleContext|manipScaleLimitsCtx|marker|match|max|memory|menu|menuBarLayout|menuEditor|menuItem|menuItemToShelf|menuSet|menuSetPref|messageLine|min|minimizeApp|mirrorJoint|modelCurrentTimeCtx|modelEditor|modelPanel|mouse|movIn|movOut|move|moveIKtoFK|moveKeyCtx|moveVertexAlongDirection|multiProfileBirailSurface|mute|nParticle|nameCommand|nameField|namespace|namespaceInfo|newPanelItems|newton|nodeCast|nodeIconButton|nodeOutliner|nodePreset|nodeType|noise|nonLinear|normalConstraint|normalize|nurbsBoolean|nurbsCopyUVSet|nurbsCube|nurbsEditUV|nurbsPlane|nurbsSelect|nurbsSquare|nurbsToPoly|nurbsToPolygonsPref|nurbsToSubdiv|nurbsToSubdivPref|nurbsUVSet|nurbsViewDirectionVector|objExists|objectCenter|objectLayer|objectType|objectTypeUI|obsoleteProc|oceanNurbsPreviewPlane|offsetCurve|offsetCurveOnSurface|offsetSurface|openGLExtension|openMayaPref|optionMenu|optionMenuGrp|optionVar|orbit|orbitCtx|orientConstraint|outlinerEditor|outlinerPanel|overrideModifier|paintEffectsDisplay|pairBlend|palettePort|paneLayout|panel|panelConfiguration|panelHistory|paramDimContext|paramDimension|paramLocator|parent|parentConstraint|particle|particleExists|particleInstancer|particleRenderInfo|partition|pasteKey|pathAnimation|pause|pclose|percent|performanceOptions|pfxstrokes|pickWalk|picture|pixelMove|planarSrf|plane|play|playbackOptions|playblast|plugAttr|plugNode|pluginInfo|pluginResourceUtil|pointConstraint|pointCurveConstraint|pointLight|pointMatrixMult|pointOnCurve|pointOnSurface|pointPosition|poleVectorConstraint|polyAppend|polyAppendFacetCtx|polyAppendVertex|polyAutoProjection|polyAverageNormal|polyAverageVertex|polyBevel|polyBlendColor|polyBlindData|polyBoolOp|polyBridgeEdge|polyCacheMonitor|polyCheck|polyChipOff|polyClipboard|polyCloseBorder|polyCollapseEdge|polyCollapseFacet|polyColorBlindData|polyColorDel|polyColorPerVertex|polyColorSet|polyCompare|polyCone|polyCopyUV|polyCrease|polyCreaseCtx|polyCreateFacet|polyCreateFacetCtx|polyCube|polyCut|polyCutCtx|polyCylinder|polyCylindricalProjection|polyDelEdge|polyDelFacet|polyDelVertex|polyDuplicateAndConnect|polyDuplicateEdge|polyEditUV|polyEditUVShell|polyEvaluate|polyExtrudeEdge|polyExtrudeFacet|polyExtrudeVertex|polyFlipEdge|polyFlipUV|polyForceUV|polyGeoSampler|polyHelix|polyInfo|polyInstallAction|polyLayoutUV|polyListComponentConversion|polyMapCut|polyMapDel|polyMapSew|polyMapSewMove|polyMergeEdge|polyMergeEdgeCtx|polyMergeFacet|polyMergeFacetCtx|polyMergeUV|polyMergeVertex|polyMirrorFace|polyMoveEdge|polyMoveFacet|polyMoveFacetUV|polyMoveUV|polyMoveVertex|polyNormal|polyNormalPerVertex|polyNormalizeUV|polyOptUvs|polyOptions|polyOutput|polyPipe|polyPlanarProjection|polyPlane|polyPlatonicSolid|polyPoke|polyPrimitive|polyPrism|polyProjection|polyPyramid|polyQuad|polyQueryBlindData|polyReduce|polySelect|polySelectConstraint|polySelectConstraintMonitor|polySelectCtx|polySelectEditCtx|polySeparate|polySetToFaceNormal|polySewEdge|polyShortestPathCtx|polySmooth|polySoftEdge|polySphere|polySphericalProjection|polySplit|polySplitCtx|polySplitEdge|polySplitRing|polySplitVertex|polyStraightenUVBorder|polySubdivideEdge|polySubdivideFacet|polyToSubdiv|polyTorus|polyTransfer|polyTriangulate|polyUVSet|polyUnite|polyWedgeFace|popen|popupMenu|pose|pow|preloadRefEd|print|progressBar|progressWindow|projFileViewer|projectCurve|projectTangent|projectionContext|projectionManip|promptDialog|propModCtx|propMove|psdChannelOutliner|psdEditTextureFile|psdExport|psdTextureFile|putenv|pwd|python|querySubdiv|quit|rad_to_deg|radial|radioButton|radioButtonGrp|radioCollection|radioMenuItemCollection|rampColorPort|rand|randomizeFollicles|randstate|rangeControl|readTake|rebuildCurve|rebuildSurface|recordAttr|recordDevice|redo|reference|referenceEdit|referenceQuery|refineSubdivSelectionList|refresh|refreshAE|registerPluginResource|rehash|reloadImage|removeJoint|removeMultiInstance|removePanelCategory|rename|renameAttr|renameSelectionList|renameUI|render|renderGlobalsNode|renderInfo|renderLayerButton|renderLayerParent|renderLayerPostProcess|renderLayerUnparent|renderManip|renderPartition|renderQualityNode|renderSettings|renderThumbnailUpdate|renderWindowEditor|renderWindowSelectContext|renderer|reorder|reorderDeformers|requires|reroot|resampleFluid|resetAE|resetPfxToPolyCamera|resetTool|resolutionNode|retarget|reverseCurve|reverseSurface|revolve|rgb_to_hsv|rigidBody|rigidSolver|roll|rollCtx|rootOf|rot|rotate|rotationInterpolation|roundConstantRadius|rowColumnLayout|rowLayout|runTimeCommand|runup|sampleImage|saveAllShelves|saveAttrPreset|saveFluid|saveImage|saveInitialState|saveMenu|savePrefObjects|savePrefs|saveShelf|saveToolSettings|scale|scaleBrushBrightness|scaleComponents|scaleConstraint|scaleKey|scaleKeyCtx|sceneEditor|sceneUIReplacement|scmh|scriptCtx|scriptEditorInfo|scriptJob|scriptNode|scriptTable|scriptToShelf|scriptedPanel|scriptedPanelType|scrollField|scrollLayout|sculpt|searchPathArray|seed|selLoadSettings|select|selectContext|selectCurveCV|selectKey|selectKeyCtx|selectKeyframeRegionCtx|selectMode|selectPref|selectPriority|selectType|selectedNodes|selectionConnection|separator|setAttr|setAttrEnumResource|setAttrMapping|setAttrNiceNameResource|setConstraintRestPosition|setDefaultShadingGroup|setDrivenKeyframe|setDynamic|setEditCtx|setEditor|setFluidAttr|setFocus|setInfinity|setInputDeviceMapping|setKeyCtx|setKeyPath|setKeyframe|setKeyframeBlendshapeTargetWts|setMenuMode|setNodeNiceNameResource|setNodeTypeFlag|setParent|setParticleAttr|setPfxToPolyCamera|setPluginResource|setProject|setStampDensity|setStartupMessage|setState|setToolTo|setUITemplate|setXformManip|sets|shadingConnection|shadingGeometryRelCtx|shadingLightRelCtx|shadingNetworkCompare|shadingNode|shapeCompare|shelfButton|shelfLayout|shelfTabLayout|shellField|shortNameOf|showHelp|showHidden|showManipCtx|showSelectionInTitle|showShadingGroupAttrEditor|showWindow|sign|simplify|sin|singleProfileBirailSurface|size|sizeBytes|skinCluster|skinPercent|smoothCurve|smoothTangentSurface|smoothstep|snap2to2|snapKey|snapMode|snapTogetherCtx|snapshot|soft|softMod|softModCtx|sort|sound|soundControl|source|spaceLocator|sphere|sphrand|spotLight|spotLightPreviewPort|spreadSheetEditor|spring|sqrt|squareSurface|srtContext|stackTrace|startString|startsWith|stitchAndExplodeShell|stitchSurface|stitchSurfacePoints|strcmp|stringArrayCatenate|stringArrayContains|stringArrayCount|stringArrayInsertAtIndex|stringArrayIntersector|stringArrayRemove|stringArrayRemoveAtIndex|stringArrayRemoveDuplicates|stringArrayRemoveExact|stringArrayToString|stringToStringArray|strip|stripPrefixFromName|stroke|subdAutoProjection|subdCleanTopology|subdCollapse|subdDuplicateAndConnect|subdEditUV|subdListComponentConversion|subdMapCut|subdMapSewMove|subdMatchTopology|subdMirror|subdToBlind|subdToPoly|subdTransferUVsToCache|subdiv|subdivCrease|subdivDisplaySmoothness|substitute|substituteAllString|substituteGeometry|substring|surface|surfaceSampler|surfaceShaderList|swatchDisplayPort|switchTable|symbolButton|symbolCheckBox|sysFile|system|tabLayout|tan|tangentConstraint|texLatticeDeformContext|texManipContext|texMoveContext|texMoveUVShellContext|texRotateContext|texScaleContext|texSelectContext|texSelectShortestPathCtx|texSmudgeUVContext|texWinToolCtx|text|textCurves|textField|textFieldButtonGrp|textFieldGrp|textManip|textScrollList|textToShelf|textureDisplacePlane|textureHairColor|texturePlacementContext|textureWindow|threadCount|threePointArcCtx|timeControl|timePort|timerX|toNativePath|toggle|toggleAxis|toggleWindowVisibility|tokenize|tokenizeList|tolerance|tolower|toolButton|toolCollection|toolDropped|toolHasOptions|toolPropertyWindow|torus|toupper|trace|track|trackCtx|transferAttributes|transformCompare|transformLimits|translator|trim|trunc|truncateFluidCache|truncateHairCache|tumble|tumbleCtx|turbulence|twoPointArcCtx|uiRes|uiTemplate|unassignInputDevice|undo|undoInfo|ungroup|uniform|unit|unloadPlugin|untangleUV|untitledFileName|untrim|upAxis|updateAE|userCtx|uvLink|uvSnapshot|validateShelfName|vectorize|view2dToolCtx|viewCamera|viewClipPlane|viewFit|viewHeadOn|viewLookAt|viewManip|viewPlace|viewSet|visor|volumeAxis|vortex|waitCursor|warning|webBrowser|webBrowserPrefs|whatIs|window|windowPref|wire|wireContext|workspace|wrinkle|wrinkleContext|writeTake|xbmLangPathList|xform)\b/,operator:[/\+[+=]?|-[-=]?|&&|\|\||[<>]=|[*\/!=]=?|[%^]/,{pattern:/(^|[^<])<(?!<)/,lookbehind:!0},{pattern:/(^|[^>])>(?!>)/,lookbehind:!0}],punctuation:/<<|>>|[.,:;?\[\](){}]/},t.languages.mel.code.inside.rest=t.languages.mel}return mel_1}var mermaid_1,hasRequiredMermaid;function requireMermaid(){if(hasRequiredMermaid)return mermaid_1;hasRequiredMermaid=1,mermaid_1=e,e.displayName="mermaid",e.aliases=[];function e(t){t.languages.mermaid={comment:{pattern:/%%.*/,greedy:!0},style:{pattern:/^([ \t]*(?:classDef|linkStyle|style)[ \t]+[\w$-]+[ \t]+)\w.*[^\s;]/m,lookbehind:!0,inside:{property:/\b\w[\w-]*(?=[ \t]*:)/,operator:/:/,punctuation:/,/}},"inter-arrow-label":{pattern:/([^<>ox.=-])(?:-[-.]|==)(?![<>ox.=-])[ \t]*(?:"[^"\r\n]*"|[^\s".=-](?:[^\r\n.=-]*[^\s.=-])?)[ \t]*(?:\.+->?|--+[->]|==+[=>])(?![<>ox.=-])/,lookbehind:!0,greedy:!0,inside:{arrow:{pattern:/(?:\.+->?|--+[->]|==+[=>])$/,alias:"operator"},label:{pattern:/^([\s\S]{2}[ \t]*)\S(?:[\s\S]*\S)?/,lookbehind:!0,alias:"property"},"arrow-head":{pattern:/^\S+/,alias:["arrow","operator"]}}},arrow:[{pattern:/(^|[^{}|o.-])[|}][|o](?:--|\.\.)[|o][|{](?![{}|o.-])/,lookbehind:!0,alias:"operator"},{pattern:/(^|[^<>ox.=-])(?:[<ox](?:==+|--+|-\.*-)[>ox]?|(?:==+|--+|-\.*-)[>ox]|===+|---+|-\.+-)(?![<>ox.=-])/,lookbehind:!0,alias:"operator"},{pattern:/(^|[^<>()x-])(?:--?(?:>>|[x>)])(?![<>()x])|(?:<<|[x<(])--?(?!-))/,lookbehind:!0,alias:"operator"},{pattern:/(^|[^<>|*o.-])(?:[*o]--|--[*o]|<\|?(?:--|\.\.)|(?:--|\.\.)\|?>|--|\.\.)(?![<>|*o.-])/,lookbehind:!0,alias:"operator"}],label:{pattern:/(^|[^|<])\|(?:[^\r\n"|]|"[^"\r\n]*")+\|/,lookbehind:!0,greedy:!0,alias:"property"},text:{pattern:/(?:[(\[{]+|\b>)(?:[^\r\n"()\[\]{}]|"[^"\r\n]*")+(?:[)\]}]+|>)/,alias:"string"},string:{pattern:/"[^"\r\n]*"/,greedy:!0},annotation:{pattern:/<<(?:abstract|choice|enumeration|fork|interface|join|service)>>|\[\[(?:choice|fork|join)\]\]/i,alias:"important"},keyword:[{pattern:/(^[ \t]*)(?:action|callback|class|classDef|classDiagram|click|direction|erDiagram|flowchart|gantt|gitGraph|graph|journey|link|linkStyle|pie|requirementDiagram|sequenceDiagram|stateDiagram|stateDiagram-v2|style|subgraph)(?![\w$-])/m,lookbehind:!0,greedy:!0},{pattern:/(^[ \t]*)(?:activate|alt|and|as|autonumber|deactivate|else|end(?:[ \t]+note)?|loop|opt|par|participant|rect|state|note[ \t]+(?:over|(?:left|right)[ \t]+of))(?![\w$-])/im,lookbehind:!0,greedy:!0}],entity:/#[a-z0-9]+;/,operator:{pattern:/(\w[ \t]*)&(?=[ \t]*\w)|:::|:/,lookbehind:!0},punctuation:/[(){};]/}}return mermaid_1}var mizar_1,hasRequiredMizar;function requireMizar(){if(hasRequiredMizar)return mizar_1;hasRequiredMizar=1,mizar_1=e,e.displayName="mizar",e.aliases=[];function e(t){t.languages.mizar={comment:/::.+/,keyword:/@proof\b|\b(?:according|aggregate|all|and|antonym|are|as|associativity|assume|asymmetry|attr|be|begin|being|by|canceled|case|cases|clusters?|coherence|commutativity|compatibility|connectedness|consider|consistency|constructors|contradiction|correctness|def|deffunc|define|definitions?|defpred|do|does|end|environ|equals|ex|exactly|existence|for|from|func|given|hence|hereby|holds|idempotence|identity|iff?|implies|involutiveness|irreflexivity|is|it|let|means|mode|non|not|notations?|now|of|or|otherwise|over|per|pred|prefix|projectivity|proof|provided|qua|reconsider|redefine|reduce|reducibility|reflexivity|registrations?|requirements|reserve|sch|schemes?|section|selector|set|sethood|st|struct|such|suppose|symmetry|synonym|take|that|the|then|theorems?|thesis|thus|to|transitivity|uniqueness|vocabular(?:ies|y)|when|where|with|wrt)\b/,parameter:{pattern:/\$(?:10|\d)/,alias:"variable"},variable:/\b\w+(?=:)/,number:/(?:\b|-)\d+\b/,operator:/\.\.\.|->|&|\.?=/,punctuation:/\(#|#\)|[,:;\[\](){}]/}}return mizar_1}var mongodb_1,hasRequiredMongodb;function requireMongodb(){if(hasRequiredMongodb)return mongodb_1;hasRequiredMongodb=1,mongodb_1=e,e.displayName="mongodb",e.aliases=[];function e(t){(function(Ye){var tt=["$eq","$gt","$gte","$in","$lt","$lte","$ne","$nin","$and","$not","$nor","$or","$exists","$type","$expr","$jsonSchema","$mod","$regex","$text","$where","$geoIntersects","$geoWithin","$near","$nearSphere","$all","$elemMatch","$size","$bitsAllClear","$bitsAllSet","$bitsAnyClear","$bitsAnySet","$comment","$elemMatch","$meta","$slice","$currentDate","$inc","$min","$max","$mul","$rename","$set","$setOnInsert","$unset","$addToSet","$pop","$pull","$push","$pullAll","$each","$position","$slice","$sort","$bit","$addFields","$bucket","$bucketAuto","$collStats","$count","$currentOp","$facet","$geoNear","$graphLookup","$group","$indexStats","$limit","$listLocalSessions","$listSessions","$lookup","$match","$merge","$out","$planCacheStats","$project","$redact","$replaceRoot","$replaceWith","$sample","$set","$skip","$sort","$sortByCount","$unionWith","$unset","$unwind","$setWindowFields","$abs","$accumulator","$acos","$acosh","$add","$addToSet","$allElementsTrue","$and","$anyElementTrue","$arrayElemAt","$arrayToObject","$asin","$asinh","$atan","$atan2","$atanh","$avg","$binarySize","$bsonSize","$ceil","$cmp","$concat","$concatArrays","$cond","$convert","$cos","$dateFromParts","$dateToParts","$dateFromString","$dateToString","$dayOfMonth","$dayOfWeek","$dayOfYear","$degreesToRadians","$divide","$eq","$exp","$filter","$first","$floor","$function","$gt","$gte","$hour","$ifNull","$in","$indexOfArray","$indexOfBytes","$indexOfCP","$isArray","$isNumber","$isoDayOfWeek","$isoWeek","$isoWeekYear","$last","$last","$let","$literal","$ln","$log","$log10","$lt","$lte","$ltrim","$map","$max","$mergeObjects","$meta","$min","$millisecond","$minute","$mod","$month","$multiply","$ne","$not","$objectToArray","$or","$pow","$push","$radiansToDegrees","$range","$reduce","$regexFind","$regexFindAll","$regexMatch","$replaceOne","$replaceAll","$reverseArray","$round","$rtrim","$second","$setDifference","$setEquals","$setIntersection","$setIsSubset","$setUnion","$size","$sin","$slice","$split","$sqrt","$stdDevPop","$stdDevSamp","$strcasecmp","$strLenBytes","$strLenCP","$substr","$substrBytes","$substrCP","$subtract","$sum","$switch","$tan","$toBool","$toDate","$toDecimal","$toDouble","$toInt","$toLong","$toObjectId","$toString","$toLower","$toUpper","$trim","$trunc","$type","$week","$year","$zip","$count","$dateAdd","$dateDiff","$dateSubtract","$dateTrunc","$getField","$rand","$sampleRate","$setField","$unsetField","$comment","$explain","$hint","$max","$maxTimeMS","$min","$orderby","$query","$returnKey","$showDiskLoc","$natural"],rt=["ObjectId","Code","BinData","DBRef","Timestamp","NumberLong","NumberDecimal","MaxKey","MinKey","RegExp","ISODate","UUID"];tt=tt.map(function(at){return at.replace("$","\\$")});var nt="(?:"+tt.join("|")+")\\b";Ye.languages.mongodb=Ye.languages.extend("javascript",{}),Ye.languages.insertBefore("mongodb","string",{property:{pattern:/(?:(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)(?=\s*:)/,greedy:!0,inside:{keyword:RegExp(`^(['"])?`+nt+"(?:\\1)?$")}}}),Ye.languages.mongodb.string.inside={url:{pattern:/https?:\/\/[-\w@:%.+~#=]{1,256}\.[a-z0-9()]{1,6}\b[-\w()@:%+.~#?&/=]*/i,greedy:!0},entity:{pattern:/\b(?:(?:[01]?\d\d?|2[0-4]\d|25[0-5])\.){3}(?:[01]?\d\d?|2[0-4]\d|25[0-5])\b/,greedy:!0}},Ye.languages.insertBefore("mongodb","constant",{builtin:{pattern:RegExp("\\b(?:"+rt.join("|")+")\\b"),alias:"keyword"}})})(t)}return mongodb_1}var monkey_1,hasRequiredMonkey;function requireMonkey(){if(hasRequiredMonkey)return monkey_1;hasRequiredMonkey=1,monkey_1=e,e.displayName="monkey",e.aliases=[];function e(t){t.languages.monkey={comment:{pattern:/^#Rem\s[\s\S]*?^#End|'.+/im,greedy:!0},string:{pattern:/"[^"\r\n]*"/,greedy:!0},preprocessor:{pattern:/(^[ \t]*)#.+/m,lookbehind:!0,greedy:!0,alias:"property"},function:/\b\w+(?=\()/,"type-char":{pattern:/\b[?%#$]/,alias:"class-name"},number:{pattern:/((?:\.\.)?)(?:(?:\b|\B-\.?|\B\.)\d+(?:(?!\.\.)\.\d*)?|\$[\da-f]+)/i,lookbehind:!0},keyword:/\b(?:Abstract|Array|Bool|Case|Catch|Class|Const|Continue|Default|Eachin|Else|ElseIf|End|EndIf|Exit|Extends|Extern|False|Field|Final|Float|For|Forever|Function|Global|If|Implements|Import|Inline|Int|Interface|Local|Method|Module|New|Next|Null|Object|Private|Property|Public|Repeat|Return|Select|Self|Step|Strict|String|Super|Then|Throw|To|True|Try|Until|Void|Wend|While)\b/i,operator:/\.\.|<[=>]?|>=?|:?=|(?:[+\-*\/&~|]|\b(?:Mod|Shl|Shr)\b)=?|\b(?:And|Not|Or)\b/i,punctuation:/[.,:;()\[\]]/}}return monkey_1}var moonscript_1,hasRequiredMoonscript;function requireMoonscript(){if(hasRequiredMoonscript)return moonscript_1;hasRequiredMoonscript=1,moonscript_1=e,e.displayName="moonscript",e.aliases=["moon"];function e(t){t.languages.moonscript={comment:/--.*/,string:[{pattern:/'[^']*'|\[(=*)\[[\s\S]*?\]\1\]/,greedy:!0},{pattern:/"[^"]*"/,greedy:!0,inside:{interpolation:{pattern:/#\{[^{}]*\}/,inside:{moonscript:{pattern:/(^#\{)[\s\S]+(?=\})/,lookbehind:!0,inside:null},"interpolation-punctuation":{pattern:/#\{|\}/,alias:"punctuation"}}}}}],"class-name":[{pattern:/(\b(?:class|extends)[ \t]+)\w+/,lookbehind:!0},/\b[A-Z]\w*/],keyword:/\b(?:class|continue|do|else|elseif|export|extends|for|from|if|import|in|local|nil|return|self|super|switch|then|unless|using|when|while|with)\b/,variable:/@@?\w*/,property:{pattern:/\b(?!\d)\w+(?=:)|(:)(?!\d)\w+/,lookbehind:!0},function:{pattern:/\b(?:_G|_VERSION|assert|collectgarbage|coroutine\.(?:create|resume|running|status|wrap|yield)|debug\.(?:debug|getfenv|gethook|getinfo|getlocal|getmetatable|getregistry|getupvalue|setfenv|sethook|setlocal|setmetatable|setupvalue|traceback)|dofile|error|getfenv|getmetatable|io\.(?:close|flush|input|lines|open|output|popen|read|stderr|stdin|stdout|tmpfile|type|write)|ipairs|load|loadfile|loadstring|math\.(?:abs|acos|asin|atan|atan2|ceil|cos|cosh|deg|exp|floor|fmod|frexp|ldexp|log|log10|max|min|modf|pi|pow|rad|random|randomseed|sin|sinh|sqrt|tan|tanh)|module|next|os\.(?:clock|date|difftime|execute|exit|getenv|remove|rename|setlocale|time|tmpname)|package\.(?:cpath|loaded|loadlib|path|preload|seeall)|pairs|pcall|print|rawequal|rawget|rawset|require|select|setfenv|setmetatable|string\.(?:byte|char|dump|find|format|gmatch|gsub|len|lower|match|rep|reverse|sub|upper)|table\.(?:concat|insert|maxn|remove|sort)|tonumber|tostring|type|unpack|xpcall)\b/,inside:{punctuation:/\./}},boolean:/\b(?:false|true)\b/,number:/(?:\B\.\d+|\b\d+\.\d+|\b\d+(?=[eE]))(?:[eE][-+]?\d+)?\b|\b(?:0x[a-fA-F\d]+|\d+)(?:U?LL)?\b/,operator:/\.{3}|[-=]>|~=|(?:[-+*/%<>!=]|\.\.)=?|[:#^]|\b(?:and|or)\b=?|\b(?:not)\b/,punctuation:/[.,()[\]{}\\]/},t.languages.moonscript.string[1].inside.interpolation.inside.moonscript.inside=t.languages.moonscript,t.languages.moon=t.languages.moonscript}return moonscript_1}var n1ql_1,hasRequiredN1ql;function requireN1ql(){if(hasRequiredN1ql)return n1ql_1;hasRequiredN1ql=1,n1ql_1=e,e.displayName="n1ql",e.aliases=[];function e(t){t.languages.n1ql={comment:{pattern:/\/\*[\s\S]*?(?:$|\*\/)|--.*/,greedy:!0},string:{pattern:/(["'])(?:\\[\s\S]|(?!\1)[^\\]|\1\1)*\1/,greedy:!0},identifier:{pattern:/`(?:\\[\s\S]|[^\\`]|``)*`/,greedy:!0},parameter:/\$[\w.]+/,keyword:/\b(?:ADVISE|ALL|ALTER|ANALYZE|AS|ASC|AT|BEGIN|BINARY|BOOLEAN|BREAK|BUCKET|BUILD|BY|CALL|CAST|CLUSTER|COLLATE|COLLECTION|COMMIT|COMMITTED|CONNECT|CONTINUE|CORRELATE|CORRELATED|COVER|CREATE|CURRENT|DATABASE|DATASET|DATASTORE|DECLARE|DECREMENT|DELETE|DERIVED|DESC|DESCRIBE|DISTINCT|DO|DROP|EACH|ELEMENT|EXCEPT|EXCLUDE|EXECUTE|EXPLAIN|FETCH|FILTER|FLATTEN|FLUSH|FOLLOWING|FOR|FORCE|FROM|FTS|FUNCTION|GOLANG|GRANT|GROUP|GROUPS|GSI|HASH|HAVING|IF|IGNORE|ILIKE|INCLUDE|INCREMENT|INDEX|INFER|INLINE|INNER|INSERT|INTERSECT|INTO|IS|ISOLATION|JAVASCRIPT|JOIN|KEY|KEYS|KEYSPACE|KNOWN|LANGUAGE|LAST|LEFT|LET|LETTING|LEVEL|LIMIT|LSM|MAP|MAPPING|MATCHED|MATERIALIZED|MERGE|MINUS|MISSING|NAMESPACE|NEST|NL|NO|NTH_VALUE|NULL|NULLS|NUMBER|OBJECT|OFFSET|ON|OPTION|OPTIONS|ORDER|OTHERS|OUTER|OVER|PARSE|PARTITION|PASSWORD|PATH|POOL|PRECEDING|PREPARE|PRIMARY|PRIVATE|PRIVILEGE|PROBE|PROCEDURE|PUBLIC|RANGE|RAW|REALM|REDUCE|RENAME|RESPECT|RETURN|RETURNING|REVOKE|RIGHT|ROLE|ROLLBACK|ROW|ROWS|SATISFIES|SAVEPOINT|SCHEMA|SCOPE|SELECT|SELF|SEMI|SET|SHOW|SOME|START|STATISTICS|STRING|SYSTEM|TIES|TO|TRAN|TRANSACTION|TRIGGER|TRUNCATE|UNBOUNDED|UNDER|UNION|UNIQUE|UNKNOWN|UNNEST|UNSET|UPDATE|UPSERT|USE|USER|USING|VALIDATE|VALUE|VALUES|VIA|VIEW|WHERE|WHILE|WINDOW|WITH|WORK|XOR)\b/i,function:/\b[a-z_]\w*(?=\s*\()/i,boolean:/\b(?:FALSE|TRUE)\b/i,number:/(?:\b\d+\.|\B\.)\d+e[+\-]?\d+\b|\b\d+(?:\.\d*)?|\B\.\d+\b/i,operator:/[-+*\/%]|!=|==?|\|\||<[>=]?|>=?|\b(?:AND|ANY|ARRAY|BETWEEN|CASE|ELSE|END|EVERY|EXISTS|FIRST|IN|LIKE|NOT|OR|THEN|VALUED|WHEN|WITHIN)\b/i,punctuation:/[;[\](),.{}:]/}}return n1ql_1}var n4js_1,hasRequiredN4js;function requireN4js(){if(hasRequiredN4js)return n4js_1;hasRequiredN4js=1,n4js_1=e,e.displayName="n4js",e.aliases=["n4jsd"];function e(t){t.languages.n4js=t.languages.extend("javascript",{keyword:/\b(?:Array|any|boolean|break|case|catch|class|const|constructor|continue|debugger|declare|default|delete|do|else|enum|export|extends|false|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|module|new|null|number|package|private|protected|public|return|set|static|string|super|switch|this|throw|true|try|typeof|var|void|while|with|yield)\b/}),t.languages.insertBefore("n4js","constant",{annotation:{pattern:/@+\w+/,alias:"operator"}}),t.languages.n4jsd=t.languages.n4js}return n4js_1}var nand2tetrisHdl_1,hasRequiredNand2tetrisHdl;function requireNand2tetrisHdl(){if(hasRequiredNand2tetrisHdl)return nand2tetrisHdl_1;hasRequiredNand2tetrisHdl=1,nand2tetrisHdl_1=e,e.displayName="nand2tetrisHdl",e.aliases=[];function e(t){t.languages["nand2tetris-hdl"]={comment:/\/\/.*|\/\*[\s\S]*?(?:\*\/|$)/,keyword:/\b(?:BUILTIN|CHIP|CLOCKED|IN|OUT|PARTS)\b/,boolean:/\b(?:false|true)\b/,function:/\b[A-Za-z][A-Za-z0-9]*(?=\()/,number:/\b\d+\b/,operator:/=|\.\./,punctuation:/[{}[\];(),:]/}}return nand2tetrisHdl_1}var naniscript_1,hasRequiredNaniscript;function requireNaniscript(){if(hasRequiredNaniscript)return naniscript_1;hasRequiredNaniscript=1,naniscript_1=e,e.displayName="naniscript",e.aliases=[];function e(t){(function(Ye){var tt=/\{[^\r\n\[\]{}]*\}/,rt={"quoted-string":{pattern:/"(?:[^"\\]|\\.)*"/,alias:"operator"},"command-param-id":{pattern:/(\s)\w+:/,lookbehind:!0,alias:"property"},"command-param-value":[{pattern:tt,alias:"selector"},{pattern:/([\t ])\S+/,lookbehind:!0,greedy:!0,alias:"operator"},{pattern:/\S(?:.*\S)?/,alias:"operator"}]};Ye.languages.naniscript={comment:{pattern:/^([\t ]*);.*/m,lookbehind:!0},define:{pattern:/^>.+/m,alias:"tag",inside:{value:{pattern:/(^>\w+[\t ]+)(?!\s)[^{}\r\n]+/,lookbehind:!0,alias:"operator"},key:{pattern:/(^>)\w+/,lookbehind:!0}}},label:{pattern:/^([\t ]*)#[\t ]*\w+[\t ]*$/m,lookbehind:!0,alias:"regex"},command:{pattern:/^([\t ]*)@\w+(?=[\t ]|$).*/m,lookbehind:!0,alias:"function",inside:{"command-name":/^@\w+/,expression:{pattern:tt,greedy:!0,alias:"selector"},"command-params":{pattern:/\s*\S[\s\S]*/,inside:rt}}},"generic-text":{pattern:/(^[ \t]*)[^#@>;\s].*/m,lookbehind:!0,alias:"punctuation",inside:{"escaped-char":/\\[{}\[\]"]/,expression:{pattern:tt,greedy:!0,alias:"selector"},"inline-command":{pattern:/\[[\t ]*\w[^\r\n\[\]]*\]/,greedy:!0,alias:"function",inside:{"command-params":{pattern:/(^\[[\t ]*\w+\b)[\s\S]+(?=\]$)/,lookbehind:!0,inside:rt},"command-param-name":{pattern:/^(\[[\t ]*)\w+/,lookbehind:!0,alias:"name"},"start-stop-char":/[\[\]]/}}}}},Ye.languages.nani=Ye.languages.naniscript,Ye.hooks.add("after-tokenize",function(it){var ot=it.tokens;ot.forEach(function(ct){if(typeof ct!="string"&&ct.type==="generic-text"){var At=at(ct);nt(At)||(ct.type="bad-line",ct.content=At)}})});function nt(it){for(var ot="[]{}",ct=[],At=0;At<it.length;At++){var Rt=it[At],qt=ot.indexOf(Rt);if(qt!==-1){if(qt%2===0)ct.push(qt+1);else if(ct.pop()!==qt)return!1}}return ct.length===0}function at(it){return typeof it=="string"?it:Array.isArray(it)?it.map(at).join(""):at(it.content)}})(t)}return naniscript_1}var nasm_1,hasRequiredNasm;function requireNasm(){if(hasRequiredNasm)return nasm_1;hasRequiredNasm=1,nasm_1=e,e.displayName="nasm",e.aliases=[];function e(t){t.languages.nasm={comment:/;.*$/m,string:/(["'`])(?:\\.|(?!\1)[^\\\r\n])*\1/,label:{pattern:/(^\s*)[A-Za-z._?$][\w.?$@~#]*:/m,lookbehind:!0,alias:"function"},keyword:[/\[?BITS (?:16|32|64)\]?/,{pattern:/(^\s*)section\s*[a-z.]+:?/im,lookbehind:!0},/(?:extern|global)[^;\r\n]*/i,/(?:CPU|DEFAULT|FLOAT).*$/m],register:{pattern:/\b(?:st\d|[xyz]mm\d\d?|[cdt]r\d|r\d\d?[bwd]?|[er]?[abcd]x|[abcd][hl]|[er]?(?:bp|di|si|sp)|[cdefgs]s)\b/i,alias:"variable"},number:/(?:\b|(?=\$))(?:0[hx](?:\.[\da-f]+|[\da-f]+(?:\.[\da-f]+)?)(?:p[+-]?\d+)?|\d[\da-f]+[hx]|\$\d[\da-f]*|0[oq][0-7]+|[0-7]+[oq]|0[by][01]+|[01]+[by]|0[dt]\d+|(?:\d+(?:\.\d+)?|\.\d+)(?:\.?e[+-]?\d+)?[dt]?)\b/i,operator:/[\[\]*+\-\/%<>=&|$!]/}}return nasm_1}var neon_1,hasRequiredNeon;function requireNeon(){if(hasRequiredNeon)return neon_1;hasRequiredNeon=1,neon_1=e,e.displayName="neon",e.aliases=[];function e(t){t.languages.neon={comment:{pattern:/#.*/,greedy:!0},datetime:{pattern:/(^|[[{(=:,\s])\d\d\d\d-\d\d?-\d\d?(?:(?:[Tt]| +)\d\d?:\d\d:\d\d(?:\.\d*)? *(?:Z|[-+]\d\d?(?::?\d\d)?)?)?(?=$|[\]}),\s])/,lookbehind:!0,alias:"number"},key:{pattern:/(^|[[{(,\s])[^,:=[\]{}()'"\s]+(?=\s*:(?:$|[\]}),\s])|\s*=)/,lookbehind:!0,alias:"atrule"},number:{pattern:/(^|[[{(=:,\s])[+-]?(?:0x[\da-fA-F]+|0o[0-7]+|0b[01]+|(?:\d+(?:\.\d*)?|\.?\d+)(?:[eE][+-]?\d+)?)(?=$|[\]}),:=\s])/,lookbehind:!0},boolean:{pattern:/(^|[[{(=:,\s])(?:false|no|true|yes)(?=$|[\]}),:=\s])/i,lookbehind:!0},null:{pattern:/(^|[[{(=:,\s])(?:null)(?=$|[\]}),:=\s])/i,lookbehind:!0,alias:"keyword"},string:{pattern:/(^|[[{(=:,\s])(?:('''|""")\r?\n(?:(?:[^\r\n]|\r?\n(?![\t ]*\2))*\r?\n)?[\t ]*\2|'[^'\r\n]*'|"(?:\\.|[^\\"\r\n])*")/,lookbehind:!0,greedy:!0},literal:{pattern:/(^|[[{(=:,\s])(?:[^#"',:=[\]{}()\s`-]|[:-][^"',=[\]{}()\s])(?:[^,:=\]})(\s]|:(?![\s,\]})]|$)|[ \t]+[^#,:=\]})(\s])*/,lookbehind:!0,alias:"string"},punctuation:/[,:=[\]{}()-]/}}return neon_1}var nevod_1,hasRequiredNevod;function requireNevod(){if(hasRequiredNevod)return nevod_1;hasRequiredNevod=1,nevod_1=e,e.displayName="nevod",e.aliases=[];function e(t){t.languages.nevod={comment:/\/\/.*|(?:\/\*[\s\S]*?(?:\*\/|$))/,string:{pattern:/(?:"(?:""|[^"])*"(?!")|'(?:''|[^'])*'(?!'))!?\*?/,greedy:!0,inside:{"string-attrs":/!$|!\*$|\*$/}},namespace:{pattern:/(@namespace\s+)[a-zA-Z0-9\-.]+(?=\s*\{)/,lookbehind:!0},pattern:{pattern:/(@pattern\s+)?#?[a-zA-Z0-9\-.]+(?:\s*\(\s*(?:~\s*)?[a-zA-Z0-9\-.]+\s*(?:,\s*(?:~\s*)?[a-zA-Z0-9\-.]*)*\))?(?=\s*=)/,lookbehind:!0,inside:{"pattern-name":{pattern:/^#?[a-zA-Z0-9\-.]+/,alias:"class-name"},fields:{pattern:/\(.*\)/,inside:{"field-name":{pattern:/[a-zA-Z0-9\-.]+/,alias:"variable"},punctuation:/[,()]/,operator:{pattern:/~/,alias:"field-hidden-mark"}}}}},search:{pattern:/(@search\s+|#)[a-zA-Z0-9\-.]+(?:\.\*)?(?=\s*;)/,alias:"function",lookbehind:!0},keyword:/@(?:having|inside|namespace|outside|pattern|require|search|where)\b/,"standard-pattern":{pattern:/\b(?:Alpha|AlphaNum|Any|Blank|End|LineBreak|Num|NumAlpha|Punct|Space|Start|Symbol|Word|WordBreak)\b(?:\([a-zA-Z0-9\-.,\s+]*\))?/,inside:{"standard-pattern-name":{pattern:/^[a-zA-Z0-9\-.]+/,alias:"builtin"},quantifier:{pattern:/\b\d+(?:\s*\+|\s*-\s*\d+)?(?!\w)/,alias:"number"},"standard-pattern-attr":{pattern:/[a-zA-Z0-9\-.]+/,alias:"builtin"},punctuation:/[,()]/}},quantifier:{pattern:/\b\d+(?:\s*\+|\s*-\s*\d+)?(?!\w)/,alias:"number"},operator:[{pattern:/=/,alias:"pattern-def"},{pattern:/&/,alias:"conjunction"},{pattern:/~/,alias:"exception"},{pattern:/\?/,alias:"optionality"},{pattern:/[[\]]/,alias:"repetition"},{pattern:/[{}]/,alias:"variation"},{pattern:/[+_]/,alias:"sequence"},{pattern:/\.{2,3}/,alias:"span"}],"field-capture":[{pattern:/([a-zA-Z0-9\-.]+\s*\()\s*[a-zA-Z0-9\-.]+\s*:\s*[a-zA-Z0-9\-.]+(?:\s*,\s*[a-zA-Z0-9\-.]+\s*:\s*[a-zA-Z0-9\-.]+)*(?=\s*\))/,lookbehind:!0,inside:{"field-name":{pattern:/[a-zA-Z0-9\-.]+/,alias:"variable"},colon:/:/}},{pattern:/[a-zA-Z0-9\-.]+\s*:/,inside:{"field-name":{pattern:/[a-zA-Z0-9\-.]+/,alias:"variable"},colon:/:/}}],punctuation:/[:;,()]/,name:/[a-zA-Z0-9\-.]+/}}return nevod_1}var nginx_1,hasRequiredNginx;function requireNginx(){if(hasRequiredNginx)return nginx_1;hasRequiredNginx=1,nginx_1=e,e.displayName="nginx",e.aliases=[];function e(t){(function(Ye){var tt=/\$(?:\w[a-z\d]*(?:_[^\x00-\x1F\s"'\\()$]*)?|\{[^}\s"'\\]+\})/i;Ye.languages.nginx={comment:{pattern:/(^|[\s{};])#.*/,lookbehind:!0,greedy:!0},directive:{pattern:/(^|\s)\w(?:[^;{}"'\\\s]|\\.|"(?:[^"\\]|\\.)*"|'(?:[^'\\]|\\.)*'|\s+(?:#.*(?!.)|(?![#\s])))*?(?=\s*[;{])/,lookbehind:!0,greedy:!0,inside:{string:{pattern:/((?:^|[^\\])(?:\\\\)*)(?:"(?:[^"\\]|\\.)*"|'(?:[^'\\]|\\.)*')/,lookbehind:!0,greedy:!0,inside:{escape:{pattern:/\\["'\\nrt]/,alias:"entity"},variable:tt}},comment:{pattern:/(\s)#.*/,lookbehind:!0,greedy:!0},keyword:{pattern:/^\S+/,greedy:!0},boolean:{pattern:/(\s)(?:off|on)(?!\S)/,lookbehind:!0},number:{pattern:/(\s)\d+[a-z]*(?!\S)/i,lookbehind:!0},variable:tt}},punctuation:/[{};]/}})(t)}return nginx_1}var nim_1,hasRequiredNim;function requireNim(){if(hasRequiredNim)return nim_1;hasRequiredNim=1,nim_1=e,e.displayName="nim",e.aliases=[];function e(t){t.languages.nim={comment:{pattern:/#.*/,greedy:!0},string:{pattern:/(?:\b(?!\d)(?:\w|\\x[89a-fA-F][0-9a-fA-F])+)?(?:"""[\s\S]*?"""(?!")|"(?:\\[\s\S]|""|[^"\\])*")/,greedy:!0},char:{pattern:/'(?:\\(?:\d+|x[\da-fA-F]{0,2}|.)|[^'])'/,greedy:!0},function:{pattern:/(?:(?!\d)(?:\w|\\x[89a-fA-F][0-9a-fA-F])+|`[^`\r\n]+`)\*?(?:\[[^\]]+\])?(?=\s*\()/,greedy:!0,inside:{operator:/\*$/}},identifier:{pattern:/`[^`\r\n]+`/,greedy:!0,inside:{punctuation:/`/}},number:/\b(?:0[xXoObB][\da-fA-F_]+|\d[\d_]*(?:(?!\.\.)\.[\d_]*)?(?:[eE][+-]?\d[\d_]*)?)(?:'?[iuf]\d*)?/,keyword:/\b(?:addr|as|asm|atomic|bind|block|break|case|cast|concept|const|continue|converter|defer|discard|distinct|do|elif|else|end|enum|except|export|finally|for|from|func|generic|if|import|include|interface|iterator|let|macro|method|mixin|nil|object|out|proc|ptr|raise|ref|return|static|template|try|tuple|type|using|var|when|while|with|without|yield)\b/,operator:{pattern:/(^|[({\[](?=\.\.)|(?![({\[]\.).)(?:(?:[=+\-*\/<>@$~&%|!?^:\\]|\.\.|\.(?![)}\]]))+|\b(?:and|div|in|is|isnot|mod|not|notin|of|or|shl|shr|xor)\b)/m,lookbehind:!0},punctuation:/[({\[]\.|\.[)}\]]|[`(){}\[\],:]/}}return nim_1}var nix_1,hasRequiredNix;function requireNix(){if(hasRequiredNix)return nix_1;hasRequiredNix=1,nix_1=e,e.displayName="nix",e.aliases=[];function e(t){t.languages.nix={comment:{pattern:/\/\*[\s\S]*?\*\/|#.*/,greedy:!0},string:{pattern:/"(?:[^"\\]|\\[\s\S])*"|''(?:(?!'')[\s\S]|''(?:'|\\|\$\{))*''/,greedy:!0,inside:{interpolation:{pattern:/(^|(?:^|(?!'').)[^\\])\$\{(?:[^{}]|\{[^}]*\})*\}/,lookbehind:!0,inside:null}}},url:[/\b(?:[a-z]{3,7}:\/\/)[\w\-+%~\/.:#=?&]+/,{pattern:/([^\/])(?:[\w\-+%~.:#=?&]*(?!\/\/)[\w\-+%~\/.:#=?&])?(?!\/\/)\/[\w\-+%~\/.:#=?&]*/,lookbehind:!0}],antiquotation:{pattern:/\$(?=\{)/,alias:"important"},number:/\b\d+\b/,keyword:/\b(?:assert|builtins|else|if|in|inherit|let|null|or|then|with)\b/,function:/\b(?:abort|add|all|any|attrNames|attrValues|baseNameOf|compareVersions|concatLists|currentSystem|deepSeq|derivation|dirOf|div|elem(?:At)?|fetch(?:Tarball|url)|filter(?:Source)?|fromJSON|genList|getAttr|getEnv|hasAttr|hashString|head|import|intersectAttrs|is(?:Attrs|Bool|Function|Int|List|Null|String)|length|lessThan|listToAttrs|map|mul|parseDrvName|pathExists|read(?:Dir|File)|removeAttrs|replaceStrings|seq|sort|stringLength|sub(?:string)?|tail|throw|to(?:File|JSON|Path|String|XML)|trace|typeOf)\b|\bfoldl'\B/,boolean:/\b(?:false|true)\b/,operator:/[=!<>]=?|\+\+?|\|\||&&|\/\/|->?|[?@]/,punctuation:/[{}()[\].,:;]/},t.languages.nix.string.inside.interpolation.inside=t.languages.nix}return nix_1}var nsis_1,hasRequiredNsis;function requireNsis(){if(hasRequiredNsis)return nsis_1;hasRequiredNsis=1,nsis_1=e,e.displayName="nsis",e.aliases=[];function e(t){t.languages.nsis={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|[#;].*)/,lookbehind:!0,greedy:!0},string:{pattern:/("|')(?:\\.|(?!\1)[^\\\r\n])*\1/,greedy:!0},keyword:{pattern:/(^[\t ]*)(?:Abort|Add(?:BrandingImage|Size)|AdvSplash|Allow(?:RootDirInstall|SkipFiles)|AutoCloseWindow|BG(?:Font|Gradient|Image)|Banner|BrandingText|BringToFront|CRCCheck|Call(?:InstDLL)?|Caption|ChangeUI|CheckBitmap|ClearErrors|CompletedText|ComponentText|CopyFiles|Create(?:Directory|Font|ShortCut)|Delete(?:INISec|INIStr|RegKey|RegValue)?|Detail(?:Print|sButtonText)|Dialer|Dir(?:Text|Var|Verify)|EnableWindow|Enum(?:RegKey|RegValue)|Exch|Exec(?:Shell(?:Wait)?|Wait)?|ExpandEnvStrings|File(?:BufSize|Close|ErrorText|Open|Read|ReadByte|ReadUTF16LE|ReadWord|Seek|Write|WriteByte|WriteUTF16LE|WriteWord)?|Find(?:Close|First|Next|Window)|FlushINI|Get(?:CurInstType|CurrentAddress|DLLVersion(?:Local)?|DlgItem|ErrorLevel|FileTime(?:Local)?|FullPathName|Function(?:Address|End)?|InstDirError|LabelAddress|TempFileName)|Goto|HideWindow|Icon|If(?:Abort|Errors|FileExists|RebootFlag|Silent)|InitPluginsDir|InstProgressFlags|Inst(?:Type(?:GetText|SetText)?)|Install(?:ButtonText|Colors|Dir(?:RegKey)?)|Int(?:64|Ptr)?CmpU?|Int(?:64)?Fmt|Int(?:Ptr)?Op|IsWindow|Lang(?:DLL|String)|License(?:BkColor|Data|ForceSelection|LangString|Text)|LoadLanguageFile|LockWindow|Log(?:Set|Text)|Manifest(?:DPIAware|SupportedOS)|Math|MessageBox|MiscButtonText|NSISdl|Name|Nop|OutFile|PE(?:DllCharacteristics|SubsysVer)|Page(?:Callbacks)?|Pop|Push|Quit|RMDir|Read(?:EnvStr|INIStr|RegDWORD|RegStr)|Reboot|RegDLL|Rename|RequestExecutionLevel|ReserveFile|Return|SearchPath|Section(?:End|GetFlags|GetInstTypes|GetSize|GetText|Group|In|SetFlags|SetInstTypes|SetSize|SetText)?|SendMessage|Set(?:AutoClose|BrandingImage|Compress|Compressor(?:DictSize)?|CtlColors|CurInstType|DatablockOptimize|DateSave|Details(?:Print|View)|ErrorLevel|Errors|FileAttributes|Font|OutPath|Overwrite|PluginUnload|RebootFlag|RegView|ShellVarContext|Silent)|Show(?:InstDetails|UninstDetails|Window)|Silent(?:Install|UnInstall)|Sleep|SpaceTexts|Splash|StartMenu|Str(?:CmpS?|Cpy|Len)|SubCaption|System|UnRegDLL|Unicode|UninstPage|Uninstall(?:ButtonText|Caption|Icon|SubCaption|Text)|UserInfo|VI(?:AddVersionKey|FileVersion|ProductVersion)|VPatch|Var|WindowIcon|Write(?:INIStr|Reg(?:Bin|DWORD|ExpandStr|MultiStr|None|Str)|Uninstaller)|XPStyle|ns(?:Dialogs|Exec))\b/m,lookbehind:!0},property:/\b(?:ARCHIVE|FILE_(?:ATTRIBUTE_ARCHIVE|ATTRIBUTE_NORMAL|ATTRIBUTE_OFFLINE|ATTRIBUTE_READONLY|ATTRIBUTE_SYSTEM|ATTRIBUTE_TEMPORARY)|HK(?:(?:CR|CU|LM)(?:32|64)?|DD|PD|U)|HKEY_(?:CLASSES_ROOT|CURRENT_CONFIG|CURRENT_USER|DYN_DATA|LOCAL_MACHINE|PERFORMANCE_DATA|USERS)|ID(?:ABORT|CANCEL|IGNORE|NO|OK|RETRY|YES)|MB_(?:ABORTRETRYIGNORE|DEFBUTTON1|DEFBUTTON2|DEFBUTTON3|DEFBUTTON4|ICONEXCLAMATION|ICONINFORMATION|ICONQUESTION|ICONSTOP|OK|OKCANCEL|RETRYCANCEL|RIGHT|RTLREADING|SETFOREGROUND|TOPMOST|USERICON|YESNO)|NORMAL|OFFLINE|READONLY|SHCTX|SHELL_CONTEXT|SYSTEM|TEMPORARY|admin|all|auto|both|colored|false|force|hide|highest|lastused|leave|listonly|none|normal|notset|off|on|open|print|show|silent|silentlog|smooth|textonly|true|user)\b/,constant:/\$\{[!\w\.:\^-]+\}|\$\([!\w\.:\^-]+\)/,variable:/\$\w[\w\.]*/,number:/\b0x[\dA-Fa-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[Ee]-?\d+)?/,operator:/--?|\+\+?|<=?|>=?|==?=?|&&?|\|\|?|[?*\/~^%]/,punctuation:/[{}[\];(),.:]/,important:{pattern:/(^[\t ]*)!(?:addincludedir|addplugindir|appendfile|cd|define|delfile|echo|else|endif|error|execute|finalize|getdllversion|gettlbversion|if|ifdef|ifmacrodef|ifmacrondef|ifndef|include|insertmacro|macro|macroend|makensis|packhdr|pragma|searchparse|searchreplace|system|tempfile|undef|verbose|warning)\b/im,lookbehind:!0}}}return nsis_1}var objectivec_1,hasRequiredObjectivec;function requireObjectivec(){if(hasRequiredObjectivec)return objectivec_1;hasRequiredObjectivec=1;var e=requireC();objectivec_1=t,t.displayName="objectivec",t.aliases=["objc"];function t(Ye){Ye.register(e),Ye.languages.objectivec=Ye.languages.extend("c",{string:{pattern:/@?"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},keyword:/\b(?:asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|in|inline|int|long|register|return|self|short|signed|sizeof|static|struct|super|switch|typedef|typeof|union|unsigned|void|volatile|while)\b|(?:@interface|@end|@implementation|@protocol|@class|@public|@protected|@private|@property|@try|@catch|@finally|@throw|@synthesize|@dynamic|@selector)\b/,operator:/-[->]?|\+\+?|!=?|<<?=?|>>?=?|==?|&&?|\|\|?|[~^%?*\/@]/}),delete Ye.languages.objectivec["class-name"],Ye.languages.objc=Ye.languages.objectivec}return objectivec_1}var ocaml_1,hasRequiredOcaml;function requireOcaml(){if(hasRequiredOcaml)return ocaml_1;hasRequiredOcaml=1,ocaml_1=e,e.displayName="ocaml",e.aliases=[];function e(t){t.languages.ocaml={comment:{pattern:/\(\*[\s\S]*?\*\)/,greedy:!0},char:{pattern:/'(?:[^\\\r\n']|\\(?:.|[ox]?[0-9a-f]{1,3}))'/i,greedy:!0},string:[{pattern:/"(?:\\(?:[\s\S]|\r\n)|[^\\\r\n"])*"/,greedy:!0},{pattern:/\{([a-z_]*)\|[\s\S]*?\|\1\}/,greedy:!0}],number:[/\b(?:0b[01][01_]*|0o[0-7][0-7_]*)\b/i,/\b0x[a-f0-9][a-f0-9_]*(?:\.[a-f0-9_]*)?(?:p[+-]?\d[\d_]*)?(?!\w)/i,/\b\d[\d_]*(?:\.[\d_]*)?(?:e[+-]?\d[\d_]*)?(?!\w)/i],directive:{pattern:/\B#\w+/,alias:"property"},label:{pattern:/\B~\w+/,alias:"property"},"type-variable":{pattern:/\B'\w+/,alias:"function"},variant:{pattern:/`\w+/,alias:"symbol"},keyword:/\b(?:as|assert|begin|class|constraint|do|done|downto|else|end|exception|external|for|fun|function|functor|if|in|include|inherit|initializer|lazy|let|match|method|module|mutable|new|nonrec|object|of|open|private|rec|sig|struct|then|to|try|type|val|value|virtual|when|where|while|with)\b/,boolean:/\b(?:false|true)\b/,"operator-like-punctuation":{pattern:/\[[<>|]|[>|]\]|\{<|>\}/,alias:"punctuation"},operator:/\.[.~]|:[=>]|[=<>@^|&+\-*\/$%!?~][!$%&*+\-.\/:<=>?@^|~]*|\b(?:and|asr|land|lor|lsl|lsr|lxor|mod|or)\b/,punctuation:/;;|::|[(){}\[\].,:;#]|\b_\b/}}return ocaml_1}var opencl_1,hasRequiredOpencl;function requireOpencl(){if(hasRequiredOpencl)return opencl_1;hasRequiredOpencl=1;var e=requireC();opencl_1=t,t.displayName="opencl",t.aliases=[];function t(Ye){Ye.register(e),function(tt){tt.languages.opencl=tt.languages.extend("c",{keyword:/\b(?:(?:__)?(?:constant|global|kernel|local|private|read_only|read_write|write_only)|__attribute__|auto|(?:bool|u?(?:char|int|long|short)|half|quad)(?:2|3|4|8|16)?|break|case|complex|const|continue|(?:double|float)(?:16(?:x(?:1|2|4|8|16))?|1x(?:1|2|4|8|16)|2(?:x(?:1|2|4|8|16))?|3|4(?:x(?:1|2|4|8|16))?|8(?:x(?:1|2|4|8|16))?)?|default|do|else|enum|extern|for|goto|if|imaginary|inline|packed|pipe|register|restrict|return|signed|sizeof|static|struct|switch|typedef|uniform|union|unsigned|void|volatile|while)\b/,number:/(?:\b0x(?:[\da-f]+(?:\.[\da-f]*)?|\.[\da-f]+)(?:p[+-]?\d+)?|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?)[fuhl]{0,4}/i,boolean:/\b(?:false|true)\b/,"constant-opencl-kernel":{pattern:/\b(?:CHAR_(?:BIT|MAX|MIN)|CLK_(?:ADDRESS_(?:CLAMP(?:_TO_EDGE)?|NONE|REPEAT)|FILTER_(?:LINEAR|NEAREST)|(?:GLOBAL|LOCAL)_MEM_FENCE|NORMALIZED_COORDS_(?:FALSE|TRUE))|CL_(?:BGRA|(?:HALF_)?FLOAT|INTENSITY|LUMINANCE|A?R?G?B?[Ax]?|(?:(?:UN)?SIGNED|[US]NORM)_(?:INT(?:8|16|32))|UNORM_(?:INT_101010|SHORT_(?:555|565)))|(?:DBL|FLT|HALF)_(?:DIG|EPSILON|(?:MAX|MIN)(?:(?:_10)?_EXP)?|MANT_DIG)|FLT_RADIX|HUGE_VALF?|(?:INT|LONG|SCHAR|SHRT)_(?:MAX|MIN)|INFINITY|MAXFLOAT|M_(?:[12]_PI|2_SQRTPI|E|LN(?:2|10)|LOG(?:2|10)E?|PI(?:_[24])?|SQRT(?:1_2|2))(?:_F|_H)?|NAN|(?:UCHAR|UINT|ULONG|USHRT)_MAX)\b/,alias:"constant"}}),tt.languages.insertBefore("opencl","class-name",{"builtin-type":{pattern:/\b(?:_cl_(?:command_queue|context|device_id|event|kernel|mem|platform_id|program|sampler)|cl_(?:image_format|mem_fence_flags)|clk_event_t|event_t|image(?:1d_(?:array_|buffer_)?t|2d_(?:array_(?:depth_|msaa_depth_|msaa_)?|depth_|msaa_depth_|msaa_)?t|3d_t)|intptr_t|ndrange_t|ptrdiff_t|queue_t|reserve_id_t|sampler_t|size_t|uintptr_t)\b/,alias:"keyword"}});var rt={"type-opencl-host":{pattern:/\b(?:cl_(?:GLenum|GLint|GLuin|addressing_mode|bitfield|bool|buffer_create_type|build_status|channel_(?:order|type)|(?:u?(?:char|int|long|short)|double|float)(?:2|3|4|8|16)?|command_(?:queue(?:_info|_properties)?|type)|context(?:_info|_properties)?|device_(?:exec_capabilities|fp_config|id|info|local_mem_type|mem_cache_type|type)|(?:event|sampler)(?:_info)?|filter_mode|half|image_info|kernel(?:_info|_work_group_info)?|map_flags|mem(?:_flags|_info|_object_type)?|platform_(?:id|info)|profiling_info|program(?:_build_info|_info)?))\b/,alias:"keyword"},"boolean-opencl-host":{pattern:/\bCL_(?:FALSE|TRUE)\b/,alias:"boolean"},"constant-opencl-host":{pattern:/\bCL_(?:A|ABGR|ADDRESS_(?:CLAMP(?:_TO_EDGE)?|MIRRORED_REPEAT|NONE|REPEAT)|ARGB|BGRA|BLOCKING|BUFFER_CREATE_TYPE_REGION|BUILD_(?:ERROR|IN_PROGRESS|NONE|PROGRAM_FAILURE|SUCCESS)|COMMAND_(?:ACQUIRE_GL_OBJECTS|BARRIER|COPY_(?:BUFFER(?:_RECT|_TO_IMAGE)?|IMAGE(?:_TO_BUFFER)?)|FILL_(?:BUFFER|IMAGE)|MAP(?:_BUFFER|_IMAGE)|MARKER|MIGRATE(?:_SVM)?_MEM_OBJECTS|NATIVE_KERNEL|NDRANGE_KERNEL|READ_(?:BUFFER(?:_RECT)?|IMAGE)|RELEASE_GL_OBJECTS|SVM_(?:FREE|MAP|MEMCPY|MEMFILL|UNMAP)|TASK|UNMAP_MEM_OBJECT|USER|WRITE_(?:BUFFER(?:_RECT)?|IMAGE))|COMPILER_NOT_AVAILABLE|COMPILE_PROGRAM_FAILURE|COMPLETE|CONTEXT_(?:DEVICES|INTEROP_USER_SYNC|NUM_DEVICES|PLATFORM|PROPERTIES|REFERENCE_COUNT)|DEPTH(?:_STENCIL)?|DEVICE_(?:ADDRESS_BITS|AFFINITY_DOMAIN_(?:L[1-4]_CACHE|NEXT_PARTITIONABLE|NUMA)|AVAILABLE|BUILT_IN_KERNELS|COMPILER_AVAILABLE|DOUBLE_FP_CONFIG|ENDIAN_LITTLE|ERROR_CORRECTION_SUPPORT|EXECUTION_CAPABILITIES|EXTENSIONS|GLOBAL_(?:MEM_(?:CACHELINE_SIZE|CACHE_SIZE|CACHE_TYPE|SIZE)|VARIABLE_PREFERRED_TOTAL_SIZE)|HOST_UNIFIED_MEMORY|IL_VERSION|IMAGE(?:2D_MAX_(?:HEIGHT|WIDTH)|3D_MAX_(?:DEPTH|HEIGHT|WIDTH)|_BASE_ADDRESS_ALIGNMENT|_MAX_ARRAY_SIZE|_MAX_BUFFER_SIZE|_PITCH_ALIGNMENT|_SUPPORT)|LINKER_AVAILABLE|LOCAL_MEM_SIZE|LOCAL_MEM_TYPE|MAX_(?:CLOCK_FREQUENCY|COMPUTE_UNITS|CONSTANT_ARGS|CONSTANT_BUFFER_SIZE|GLOBAL_VARIABLE_SIZE|MEM_ALLOC_SIZE|NUM_SUB_GROUPS|ON_DEVICE_(?:EVENTS|QUEUES)|PARAMETER_SIZE|PIPE_ARGS|READ_IMAGE_ARGS|READ_WRITE_IMAGE_ARGS|SAMPLERS|WORK_GROUP_SIZE|WORK_ITEM_DIMENSIONS|WORK_ITEM_SIZES|WRITE_IMAGE_ARGS)|MEM_BASE_ADDR_ALIGN|MIN_DATA_TYPE_ALIGN_SIZE|NAME|NATIVE_VECTOR_WIDTH_(?:CHAR|DOUBLE|FLOAT|HALF|INT|LONG|SHORT)|NOT_(?:AVAILABLE|FOUND)|OPENCL_C_VERSION|PARENT_DEVICE|PARTITION_(?:AFFINITY_DOMAIN|BY_AFFINITY_DOMAIN|BY_COUNTS|BY_COUNTS_LIST_END|EQUALLY|FAILED|MAX_SUB_DEVICES|PROPERTIES|TYPE)|PIPE_MAX_(?:ACTIVE_RESERVATIONS|PACKET_SIZE)|PLATFORM|PREFERRED_(?:GLOBAL_ATOMIC_ALIGNMENT|INTEROP_USER_SYNC|LOCAL_ATOMIC_ALIGNMENT|PLATFORM_ATOMIC_ALIGNMENT|VECTOR_WIDTH_(?:CHAR|DOUBLE|FLOAT|HALF|INT|LONG|SHORT))|PRINTF_BUFFER_SIZE|PROFILE|PROFILING_TIMER_RESOLUTION|QUEUE_(?:ON_(?:DEVICE_(?:MAX_SIZE|PREFERRED_SIZE|PROPERTIES)|HOST_PROPERTIES)|PROPERTIES)|REFERENCE_COUNT|SINGLE_FP_CONFIG|SUB_GROUP_INDEPENDENT_FORWARD_PROGRESS|SVM_(?:ATOMICS|CAPABILITIES|COARSE_GRAIN_BUFFER|FINE_GRAIN_BUFFER|FINE_GRAIN_SYSTEM)|TYPE(?:_ACCELERATOR|_ALL|_CPU|_CUSTOM|_DEFAULT|_GPU)?|VENDOR(?:_ID)?|VERSION)|DRIVER_VERSION|EVENT_(?:COMMAND_(?:EXECUTION_STATUS|QUEUE|TYPE)|CONTEXT|REFERENCE_COUNT)|EXEC_(?:KERNEL|NATIVE_KERNEL|STATUS_ERROR_FOR_EVENTS_IN_WAIT_LIST)|FILTER_(?:LINEAR|NEAREST)|FLOAT|FP_(?:CORRECTLY_ROUNDED_DIVIDE_SQRT|DENORM|FMA|INF_NAN|ROUND_TO_INF|ROUND_TO_NEAREST|ROUND_TO_ZERO|SOFT_FLOAT)|GLOBAL|HALF_FLOAT|IMAGE_(?:ARRAY_SIZE|BUFFER|DEPTH|ELEMENT_SIZE|FORMAT|FORMAT_MISMATCH|FORMAT_NOT_SUPPORTED|HEIGHT|NUM_MIP_LEVELS|NUM_SAMPLES|ROW_PITCH|SLICE_PITCH|WIDTH)|INTENSITY|INVALID_(?:ARG_INDEX|ARG_SIZE|ARG_VALUE|BINARY|BUFFER_SIZE|BUILD_OPTIONS|COMMAND_QUEUE|COMPILER_OPTIONS|CONTEXT|DEVICE|DEVICE_PARTITION_COUNT|DEVICE_QUEUE|DEVICE_TYPE|EVENT|EVENT_WAIT_LIST|GLOBAL_OFFSET|GLOBAL_WORK_SIZE|GL_OBJECT|HOST_PTR|IMAGE_DESCRIPTOR|IMAGE_FORMAT_DESCRIPTOR|IMAGE_SIZE|KERNEL|KERNEL_ARGS|KERNEL_DEFINITION|KERNEL_NAME|LINKER_OPTIONS|MEM_OBJECT|MIP_LEVEL|OPERATION|PIPE_SIZE|PLATFORM|PROGRAM|PROGRAM_EXECUTABLE|PROPERTY|QUEUE_PROPERTIES|SAMPLER|VALUE|WORK_DIMENSION|WORK_GROUP_SIZE|WORK_ITEM_SIZE)|KERNEL_(?:ARG_(?:ACCESS_(?:NONE|QUALIFIER|READ_ONLY|READ_WRITE|WRITE_ONLY)|ADDRESS_(?:CONSTANT|GLOBAL|LOCAL|PRIVATE|QUALIFIER)|INFO_NOT_AVAILABLE|NAME|TYPE_(?:CONST|NAME|NONE|PIPE|QUALIFIER|RESTRICT|VOLATILE))|ATTRIBUTES|COMPILE_NUM_SUB_GROUPS|COMPILE_WORK_GROUP_SIZE|CONTEXT|EXEC_INFO_SVM_FINE_GRAIN_SYSTEM|EXEC_INFO_SVM_PTRS|FUNCTION_NAME|GLOBAL_WORK_SIZE|LOCAL_MEM_SIZE|LOCAL_SIZE_FOR_SUB_GROUP_COUNT|MAX_NUM_SUB_GROUPS|MAX_SUB_GROUP_SIZE_FOR_NDRANGE|NUM_ARGS|PREFERRED_WORK_GROUP_SIZE_MULTIPLE|PRIVATE_MEM_SIZE|PROGRAM|REFERENCE_COUNT|SUB_GROUP_COUNT_FOR_NDRANGE|WORK_GROUP_SIZE)|LINKER_NOT_AVAILABLE|LINK_PROGRAM_FAILURE|LOCAL|LUMINANCE|MAP_(?:FAILURE|READ|WRITE|WRITE_INVALIDATE_REGION)|MEM_(?:ALLOC_HOST_PTR|ASSOCIATED_MEMOBJECT|CONTEXT|COPY_HOST_PTR|COPY_OVERLAP|FLAGS|HOST_NO_ACCESS|HOST_PTR|HOST_READ_ONLY|HOST_WRITE_ONLY|KERNEL_READ_AND_WRITE|MAP_COUNT|OBJECT_(?:ALLOCATION_FAILURE|BUFFER|IMAGE1D|IMAGE1D_ARRAY|IMAGE1D_BUFFER|IMAGE2D|IMAGE2D_ARRAY|IMAGE3D|PIPE)|OFFSET|READ_ONLY|READ_WRITE|REFERENCE_COUNT|SIZE|SVM_ATOMICS|SVM_FINE_GRAIN_BUFFER|TYPE|USES_SVM_POINTER|USE_HOST_PTR|WRITE_ONLY)|MIGRATE_MEM_OBJECT_(?:CONTENT_UNDEFINED|HOST)|MISALIGNED_SUB_BUFFER_OFFSET|NONE|NON_BLOCKING|OUT_OF_(?:HOST_MEMORY|RESOURCES)|PIPE_(?:MAX_PACKETS|PACKET_SIZE)|PLATFORM_(?:EXTENSIONS|HOST_TIMER_RESOLUTION|NAME|PROFILE|VENDOR|VERSION)|PROFILING_(?:COMMAND_(?:COMPLETE|END|QUEUED|START|SUBMIT)|INFO_NOT_AVAILABLE)|PROGRAM_(?:BINARIES|BINARY_SIZES|BINARY_TYPE(?:_COMPILED_OBJECT|_EXECUTABLE|_LIBRARY|_NONE)?|BUILD_(?:GLOBAL_VARIABLE_TOTAL_SIZE|LOG|OPTIONS|STATUS)|CONTEXT|DEVICES|IL|KERNEL_NAMES|NUM_DEVICES|NUM_KERNELS|REFERENCE_COUNT|SOURCE)|QUEUED|QUEUE_(?:CONTEXT|DEVICE|DEVICE_DEFAULT|ON_DEVICE|ON_DEVICE_DEFAULT|OUT_OF_ORDER_EXEC_MODE_ENABLE|PROFILING_ENABLE|PROPERTIES|REFERENCE_COUNT|SIZE)|R|RA|READ_(?:ONLY|WRITE)_CACHE|RG|RGB|RGBA|RGBx|RGx|RUNNING|Rx|SAMPLER_(?:ADDRESSING_MODE|CONTEXT|FILTER_MODE|LOD_MAX|LOD_MIN|MIP_FILTER_MODE|NORMALIZED_COORDS|REFERENCE_COUNT)|(?:UN)?SIGNED_INT(?:8|16|32)|SNORM_INT(?:8|16)|SUBMITTED|SUCCESS|UNORM_INT(?:8|16|24|_101010|_101010_2)|UNORM_SHORT_(?:555|565)|VERSION_(?:1_0|1_1|1_2|2_0|2_1)|sBGRA|sRGB|sRGBA|sRGBx)\b/,alias:"constant"},"function-opencl-host":{pattern:/\bcl(?:BuildProgram|CloneKernel|CompileProgram|Create(?:Buffer|CommandQueue(?:WithProperties)?|Context|ContextFromType|Image|Image2D|Image3D|Kernel|KernelsInProgram|Pipe|ProgramWith(?:Binary|BuiltInKernels|IL|Source)|Sampler|SamplerWithProperties|SubBuffer|SubDevices|UserEvent)|Enqueue(?:(?:Barrier|Marker)(?:WithWaitList)?|Copy(?:Buffer(?:Rect|ToImage)?|Image(?:ToBuffer)?)|(?:Fill|Map)(?:Buffer|Image)|MigrateMemObjects|NDRangeKernel|NativeKernel|(?:Read|Write)(?:Buffer(?:Rect)?|Image)|SVM(?:Free|Map|MemFill|Memcpy|MigrateMem|Unmap)|Task|UnmapMemObject|WaitForEvents)|Finish|Flush|Get(?:CommandQueueInfo|ContextInfo|Device(?:AndHostTimer|IDs|Info)|Event(?:Profiling)?Info|ExtensionFunctionAddress(?:ForPlatform)?|HostTimer|ImageInfo|Kernel(?:ArgInfo|Info|SubGroupInfo|WorkGroupInfo)|MemObjectInfo|PipeInfo|Platform(?:IDs|Info)|Program(?:Build)?Info|SamplerInfo|SupportedImageFormats)|LinkProgram|(?:Release|Retain)(?:CommandQueue|Context|Device|Event|Kernel|MemObject|Program|Sampler)|SVM(?:Alloc|Free)|Set(?:CommandQueueProperty|DefaultDeviceCommandQueue|EventCallback|Kernel|Kernel(?:Arg(?:SVMPointer)?|ExecInfo)|MemObjectDestructorCallback|UserEventStatus)|Unload(?:Platform)?Compiler|WaitForEvents)\b/,alias:"function"}};tt.languages.insertBefore("c","keyword",rt),tt.languages.cpp&&(rt["type-opencl-host-cpp"]={pattern:/\b(?:Buffer|BufferGL|BufferRenderGL|CommandQueue|Context|Device|DeviceCommandQueue|EnqueueArgs|Event|Image|Image1D|Image1DArray|Image1DBuffer|Image2D|Image2DArray|Image2DGL|Image3D|Image3DGL|ImageFormat|ImageGL|Kernel|KernelFunctor|LocalSpaceArg|Memory|NDRange|Pipe|Platform|Program|SVMAllocator|SVMTraitAtomic|SVMTraitCoarse|SVMTraitFine|SVMTraitReadOnly|SVMTraitReadWrite|SVMTraitWriteOnly|Sampler|UserEvent)\b/,alias:"keyword"},tt.languages.insertBefore("cpp","keyword",rt))}(Ye)}return opencl_1}var openqasm_1,hasRequiredOpenqasm;function requireOpenqasm(){if(hasRequiredOpenqasm)return openqasm_1;hasRequiredOpenqasm=1,openqasm_1=e,e.displayName="openqasm",e.aliases=["qasm"];function e(t){t.languages.openqasm={comment:/\/\*[\s\S]*?\*\/|\/\/.*/,string:{pattern:/"[^"\r\n\t]*"|'[^'\r\n\t]*'/,greedy:!0},keyword:/\b(?:CX|OPENQASM|U|barrier|boxas|boxto|break|const|continue|ctrl|def|defcal|defcalgrammar|delay|else|end|for|gate|gphase|if|in|include|inv|kernel|lengthof|let|measure|pow|reset|return|rotary|stretchinf|while)\b|#pragma\b/,"class-name":/\b(?:angle|bit|bool|creg|fixed|float|int|length|qreg|qubit|stretch|uint)\b/,function:/\b(?:cos|exp|ln|popcount|rotl|rotr|sin|sqrt|tan)\b(?=\s*\()/,constant:/\b(?:euler|pi|tau)\b|π|𝜏|ℇ/,number:{pattern:/(^|[^.\w$])(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?(?:dt|ns|us|µs|ms|s)?/i,lookbehind:!0},operator:/->|>>=?|<<=?|&&|\|\||\+\+|--|[!=<>&|~^+\-*/%]=?|@/,punctuation:/[(){}\[\];,:.]/},t.languages.qasm=t.languages.openqasm}return openqasm_1}var oz_1,hasRequiredOz;function requireOz(){if(hasRequiredOz)return oz_1;hasRequiredOz=1,oz_1=e,e.displayName="oz",e.aliases=[];function e(t){t.languages.oz={comment:{pattern:/\/\*[\s\S]*?\*\/|%.*/,greedy:!0},string:{pattern:/"(?:[^"\\]|\\[\s\S])*"/,greedy:!0},atom:{pattern:/'(?:[^'\\]|\\[\s\S])*'/,greedy:!0,alias:"builtin"},keyword:/\$|\[\]|\b(?:_|at|attr|case|catch|choice|class|cond|declare|define|dis|else(?:case|if)?|end|export|fail|false|feat|finally|from|fun|functor|if|import|in|local|lock|meth|nil|not|of|or|prepare|proc|prop|raise|require|self|skip|then|thread|true|try|unit)\b/,function:[/\b[a-z][A-Za-z\d]*(?=\()/,{pattern:/(\{)[A-Z][A-Za-z\d]*\b/,lookbehind:!0}],number:/\b(?:0[bx][\da-f]+|\d+(?:\.\d*)?(?:e~?\d+)?)\b|&(?:[^\\]|\\(?:\d{3}|.))/i,variable:/`(?:[^`\\]|\\.)+`/,"attr-name":/\b\w+(?=[ \t]*:(?![:=]))/,operator:/:(?:=|::?)|<[-:=]?|=(?:=|<?:?)|>=?:?|\\=:?|!!?|[|#+\-*\/,~^@]|\b(?:andthen|div|mod|orelse)\b/,punctuation:/[\[\](){}.:;?]/}}return oz_1}var parigp_1,hasRequiredParigp;function requireParigp(){if(hasRequiredParigp)return parigp_1;hasRequiredParigp=1,parigp_1=e,e.displayName="parigp",e.aliases=[];function e(t){t.languages.parigp={comment:/\/\*[\s\S]*?\*\/|\\\\.*/,string:{pattern:/"(?:[^"\\\r\n]|\\.)*"/,greedy:!0},keyword:function(){var Ye=["breakpoint","break","dbg_down","dbg_err","dbg_up","dbg_x","forcomposite","fordiv","forell","forpart","forprime","forstep","forsubgroup","forvec","for","iferr","if","local","my","next","return","until","while"];return Ye=Ye.map(function(tt){return tt.split("").join(" *")}).join("|"),RegExp("\\b(?:"+Ye+")\\b")}(),function:/\b\w(?:[\w ]*\w)?(?= *\()/,number:{pattern:/((?:\. *\. *)?)(?:\b\d(?: *\d)*(?: *(?!\. *\.)\.(?: *\d)*)?|\. *\d(?: *\d)*)(?: *e *(?:[+-] *)?\d(?: *\d)*)?/i,lookbehind:!0},operator:/\. *\.|[*\/!](?: *=)?|%(?: *=|(?: *#)?(?: *')*)?|\+(?: *[+=])?|-(?: *[-=>])?|<(?: *>|(?: *<)?(?: *=)?)?|>(?: *>)?(?: *=)?|=(?: *=){0,2}|\\(?: *\/)?(?: *=)?|&(?: *&)?|\| *\||['#~^]/,punctuation:/[\[\]{}().,:;|]/}}return parigp_1}var parser_1,hasRequiredParser;function requireParser(){if(hasRequiredParser)return parser_1;hasRequiredParser=1,parser_1=e,e.displayName="parser",e.aliases=[];function e(t){(function(Ye){var tt=Ye.languages.parser=Ye.languages.extend("markup",{keyword:{pattern:/(^|[^^])(?:\^(?:case|eval|for|if|switch|throw)\b|@(?:BASE|CLASS|GET(?:_DEFAULT)?|OPTIONS|SET_DEFAULT|USE)\b)/,lookbehind:!0},variable:{pattern:/(^|[^^])\B\$(?:\w+|(?=[.{]))(?:(?:\.|::?)\w+)*(?:\.|::?)?/,lookbehind:!0,inside:{punctuation:/\.|:+/}},function:{pattern:/(^|[^^])\B[@^]\w+(?:(?:\.|::?)\w+)*(?:\.|::?)?/,lookbehind:!0,inside:{keyword:{pattern:/(^@)(?:GET_|SET_)/,lookbehind:!0},punctuation:/\.|:+/}},escape:{pattern:/\^(?:[$^;@()\[\]{}"':]|#[a-f\d]*)/i,alias:"builtin"},punctuation:/[\[\](){};]/});tt=Ye.languages.insertBefore("parser","keyword",{"parser-comment":{pattern:/(\s)#.*/,lookbehind:!0,alias:"comment"},expression:{pattern:/(^|[^^])\((?:[^()]|\((?:[^()]|\((?:[^()])*\))*\))*\)/,greedy:!0,lookbehind:!0,inside:{string:{pattern:/(^|[^^])(["'])(?:(?!\2)[^^]|\^[\s\S])*\2/,lookbehind:!0},keyword:tt.keyword,variable:tt.variable,function:tt.function,boolean:/\b(?:false|true)\b/,number:/\b(?:0x[a-f\d]+|\d+(?:\.\d*)?(?:e[+-]?\d+)?)\b/i,escape:tt.escape,operator:/[~+*\/\\%]|!(?:\|\|?|=)?|&&?|\|\|?|==|<[<=]?|>[>=]?|-[fd]?|\b(?:def|eq|ge|gt|in|is|le|lt|ne)\b/,punctuation:tt.punctuation}}}),Ye.languages.insertBefore("inside","punctuation",{expression:tt.expression,keyword:tt.keyword,variable:tt.variable,function:tt.function,escape:tt.escape,"parser-punctuation":{pattern:tt.punctuation,alias:"punctuation"}},tt.tag.inside["attr-value"])})(t)}return parser_1}var pascal_1,hasRequiredPascal;function requirePascal(){if(hasRequiredPascal)return pascal_1;hasRequiredPascal=1,pascal_1=e,e.displayName="pascal",e.aliases=["objectpascal"];function e(t){t.languages.pascal={directive:{pattern:/\{\$[\s\S]*?\}/,greedy:!0,alias:["marco","property"]},comment:{pattern:/\(\*[\s\S]*?\*\)|\{[\s\S]*?\}|\/\/.*/,greedy:!0},string:{pattern:/(?:'(?:''|[^'\r\n])*'(?!')|#[&$%]?[a-f\d]+)+|\^[a-z]/i,greedy:!0},asm:{pattern:/(\basm\b)[\s\S]+?(?=\bend\s*[;[])/i,lookbehind:!0,greedy:!0,inside:null},keyword:[{pattern:/(^|[^&])\b(?:absolute|array|asm|begin|case|const|constructor|destructor|do|downto|else|end|file|for|function|goto|if|implementation|inherited|inline|interface|label|nil|object|of|operator|packed|procedure|program|record|reintroduce|repeat|self|set|string|then|to|type|unit|until|uses|var|while|with)\b/i,lookbehind:!0},{pattern:/(^|[^&])\b(?:dispose|exit|false|new|true)\b/i,lookbehind:!0},{pattern:/(^|[^&])\b(?:class|dispinterface|except|exports|finalization|finally|initialization|inline|library|on|out|packed|property|raise|resourcestring|threadvar|try)\b/i,lookbehind:!0},{pattern:/(^|[^&])\b(?:absolute|abstract|alias|assembler|bitpacked|break|cdecl|continue|cppdecl|cvar|default|deprecated|dynamic|enumerator|experimental|export|external|far|far16|forward|generic|helper|implements|index|interrupt|iochecks|local|message|name|near|nodefault|noreturn|nostackframe|oldfpccall|otherwise|overload|override|pascal|platform|private|protected|public|published|read|register|reintroduce|result|safecall|saveregisters|softfloat|specialize|static|stdcall|stored|strict|unaligned|unimplemented|varargs|virtual|write)\b/i,lookbehind:!0}],number:[/(?:[&%]\d+|\$[a-f\d]+)/i,/\b\d+(?:\.\d+)?(?:e[+-]?\d+)?/i],operator:[/\.\.|\*\*|:=|<[<=>]?|>[>=]?|[+\-*\/]=?|[@^=]/,{pattern:/(^|[^&])\b(?:and|as|div|exclude|in|include|is|mod|not|or|shl|shr|xor)\b/,lookbehind:!0}],punctuation:/\(\.|\.\)|[()\[\]:;,.]/},t.languages.pascal.asm.inside=t.languages.extend("pascal",{asm:void 0,keyword:void 0,operator:void 0}),t.languages.objectpascal=t.languages.pascal}return pascal_1}var pascaligo_1,hasRequiredPascaligo;function requirePascaligo(){if(hasRequiredPascaligo)return pascaligo_1;hasRequiredPascaligo=1,pascaligo_1=e,e.displayName="pascaligo",e.aliases=[];function e(t){(function(Ye){var tt=/\((?:[^()]|\((?:[^()]|\([^()]*\))*\))*\)/.source,rt=/(?:\b\w+(?:<braces>)?|<braces>)/.source.replace(/<braces>/g,function(){return tt}),nt=Ye.languages.pascaligo={comment:/\(\*[\s\S]+?\*\)|\/\/.*/,string:{pattern:/(["'`])(?:\\[\s\S]|(?!\1)[^\\])*\1|\^[a-z]/i,greedy:!0},"class-name":[{pattern:RegExp(/(\btype\s+\w+\s+is\s+)<type>/.source.replace(/<type>/g,function(){return rt}),"i"),lookbehind:!0,inside:null},{pattern:RegExp(/<type>(?=\s+is\b)/.source.replace(/<type>/g,function(){return rt}),"i"),inside:null},{pattern:RegExp(/(:\s*)<type>/.source.replace(/<type>/g,function(){return rt})),lookbehind:!0,inside:null}],keyword:{pattern:/(^|[^&])\b(?:begin|block|case|const|else|end|fail|for|from|function|if|is|nil|of|remove|return|skip|then|type|var|while|with)\b/i,lookbehind:!0},boolean:{pattern:/(^|[^&])\b(?:False|True)\b/i,lookbehind:!0},builtin:{pattern:/(^|[^&])\b(?:bool|int|list|map|nat|record|string|unit)\b/i,lookbehind:!0},function:/\b\w+(?=\s*\()/,number:[/%[01]+|&[0-7]+|\$[a-f\d]+/i,/\b\d+(?:\.\d+)?(?:e[+-]?\d+)?(?:mtz|n)?/i],operator:/->|=\/=|\.\.|\*\*|:=|<[<=>]?|>[>=]?|[+\-*\/]=?|[@^=|]|\b(?:and|mod|or)\b/,punctuation:/\(\.|\.\)|[()\[\]:;,.{}]/},at=["comment","keyword","builtin","operator","punctuation"].reduce(function(it,ot){return it[ot]=nt[ot],it},{});nt["class-name"].forEach(function(it){it.inside=at})})(t)}return pascaligo_1}var pcaxis_1,hasRequiredPcaxis;function requirePcaxis(){if(hasRequiredPcaxis)return pcaxis_1;hasRequiredPcaxis=1,pcaxis_1=e,e.displayName="pcaxis",e.aliases=["px"];function e(t){t.languages.pcaxis={string:/"[^"]*"/,keyword:{pattern:/((?:^|;)\s*)[-A-Z\d]+(?:\s*\[[-\w]+\])?(?:\s*\("[^"]*"(?:,\s*"[^"]*")*\))?(?=\s*=)/,lookbehind:!0,greedy:!0,inside:{keyword:/^[-A-Z\d]+/,language:{pattern:/^(\s*)\[[-\w]+\]/,lookbehind:!0,inside:{punctuation:/^\[|\]$/,property:/[-\w]+/}},"sub-key":{pattern:/^(\s*)\S[\s\S]*/,lookbehind:!0,inside:{parameter:{pattern:/"[^"]*"/,alias:"property"},punctuation:/^\(|\)$|,/}}}},operator:/=/,tlist:{pattern:/TLIST\s*\(\s*\w+(?:(?:\s*,\s*"[^"]*")+|\s*,\s*"[^"]*"-"[^"]*")?\s*\)/,greedy:!0,inside:{function:/^TLIST/,property:{pattern:/^(\s*\(\s*)\w+/,lookbehind:!0},string:/"[^"]*"/,punctuation:/[(),]/,operator:/-/}},punctuation:/[;,]/,number:{pattern:/(^|\s)\d+(?:\.\d+)?(?!\S)/,lookbehind:!0},boolean:/NO|YES/},t.languages.px=t.languages.pcaxis}return pcaxis_1}var peoplecode_1,hasRequiredPeoplecode;function requirePeoplecode(){if(hasRequiredPeoplecode)return peoplecode_1;hasRequiredPeoplecode=1,peoplecode_1=e,e.displayName="peoplecode",e.aliases=["pcode"];function e(t){t.languages.peoplecode={comment:RegExp([/\/\*[\s\S]*?\*\//.source,/\bREM[^;]*;/.source,/<\*(?:[^<*]|\*(?!>)|<(?!\*)|<\*(?:(?!\*>)[\s\S])*\*>)*\*>/.source,/\/\+[\s\S]*?\+\//.source].join("|")),string:{pattern:/'(?:''|[^'\r\n])*'(?!')|"(?:""|[^"\r\n])*"(?!")/,greedy:!0},variable:/%\w+/,"function-definition":{pattern:/((?:^|[^\w-])(?:function|method)\s+)\w+/i,lookbehind:!0,alias:"function"},"class-name":{pattern:/((?:^|[^-\w])(?:as|catch|class|component|create|extends|global|implements|instance|local|of|property|returns)\s+)\w+(?::\w+)*/i,lookbehind:!0,inside:{punctuation:/:/}},keyword:/\b(?:abstract|alias|as|catch|class|component|constant|create|declare|else|end-(?:class|evaluate|for|function|get|if|method|set|try|while)|evaluate|extends|for|function|get|global|if|implements|import|instance|library|local|method|null|of|out|peopleCode|private|program|property|protected|readonly|ref|repeat|returns?|set|step|then|throw|to|try|until|value|when(?:-other)?|while)\b/i,"operator-keyword":{pattern:/\b(?:and|not|or)\b/i,alias:"operator"},function:/[_a-z]\w*(?=\s*\()/i,boolean:/\b(?:false|true)\b/i,number:/\b\d+(?:\.\d+)?\b/,operator:/<>|[<>]=?|!=|\*\*|[-+*/|=@]/,punctuation:/[:.;,()[\]]/},t.languages.pcode=t.languages.peoplecode}return peoplecode_1}var perl_1,hasRequiredPerl;function requirePerl(){if(hasRequiredPerl)return perl_1;hasRequiredPerl=1,perl_1=e,e.displayName="perl",e.aliases=[];function e(t){(function(Ye){var tt=/(?:\((?:[^()\\]|\\[\s\S])*\)|\{(?:[^{}\\]|\\[\s\S])*\}|\[(?:[^[\]\\]|\\[\s\S])*\]|<(?:[^<>\\]|\\[\s\S])*>)/.source;Ye.languages.perl={comment:[{pattern:/(^\s*)=\w[\s\S]*?=cut.*/m,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\$])#.*/,lookbehind:!0,greedy:!0}],string:[{pattern:RegExp(/\b(?:q|qq|qw|qx)(?![a-zA-Z0-9])\s*/.source+"(?:"+[/([^a-zA-Z0-9\s{(\[<])(?:(?!\1)[^\\]|\\[\s\S])*\1/.source,/([a-zA-Z0-9])(?:(?!\2)[^\\]|\\[\s\S])*\2/.source,tt].join("|")+")"),greedy:!0},{pattern:/("|`)(?:(?!\1)[^\\]|\\[\s\S])*\1/,greedy:!0},{pattern:/'(?:[^'\\\r\n]|\\.)*'/,greedy:!0}],regex:[{pattern:RegExp(/\b(?:m|qr)(?![a-zA-Z0-9])\s*/.source+"(?:"+[/([^a-zA-Z0-9\s{(\[<])(?:(?!\1)[^\\]|\\[\s\S])*\1/.source,/([a-zA-Z0-9])(?:(?!\2)[^\\]|\\[\s\S])*\2/.source,tt].join("|")+")"+/[msixpodualngc]*/.source),greedy:!0},{pattern:RegExp(/(^|[^-])\b(?:s|tr|y)(?![a-zA-Z0-9])\s*/.source+"(?:"+[/([^a-zA-Z0-9\s{(\[<])(?:(?!\2)[^\\]|\\[\s\S])*\2(?:(?!\2)[^\\]|\\[\s\S])*\2/.source,/([a-zA-Z0-9])(?:(?!\3)[^\\]|\\[\s\S])*\3(?:(?!\3)[^\\]|\\[\s\S])*\3/.source,tt+/\s*/.source+tt].join("|")+")"+/[msixpodualngcer]*/.source),lookbehind:!0,greedy:!0},{pattern:/\/(?:[^\/\\\r\n]|\\.)*\/[msixpodualngc]*(?=\s*(?:$|[\r\n,.;})&|\-+*~<>!?^]|(?:and|cmp|eq|ge|gt|le|lt|ne|not|or|x|xor)\b))/,greedy:!0}],variable:[/[&*$@%]\{\^[A-Z]+\}/,/[&*$@%]\^[A-Z_]/,/[&*$@%]#?(?=\{)/,/[&*$@%]#?(?:(?:::)*'?(?!\d)[\w$]+(?![\w$]))+(?:::)*/,/[&*$@%]\d+/,/(?!%=)[$@%][!"#$%&'()*+,\-.\/:;<=>?@[\\\]^_`{|}~]/],filehandle:{pattern:/<(?![<=])\S*?>|\b_\b/,alias:"symbol"},"v-string":{pattern:/v\d+(?:\.\d+)*|\d+(?:\.\d+){2,}/,alias:"string"},function:{pattern:/(\bsub[ \t]+)\w+/,lookbehind:!0},keyword:/\b(?:any|break|continue|default|delete|die|do|else|elsif|eval|for|foreach|given|goto|if|last|local|my|next|our|package|print|redo|require|return|say|state|sub|switch|undef|unless|until|use|when|while)\b/,number:/\b(?:0x[\dA-Fa-f](?:_?[\dA-Fa-f])*|0b[01](?:_?[01])*|(?:(?:\d(?:_?\d)*)?\.)?\d(?:_?\d)*(?:[Ee][+-]?\d+)?)\b/,operator:/-[rwxoRWXOezsfdlpSbctugkTBMAC]\b|\+[+=]?|-[-=>]?|\*\*?=?|\/\/?=?|=[=~>]?|~[~=]?|\|\|?=?|&&?=?|<(?:=>?|<=?)?|>>?=?|![~=]?|[%^]=?|\.(?:=|\.\.?)?|[\\?]|\bx(?:=|\b)|\b(?:and|cmp|eq|ge|gt|le|lt|ne|not|or|xor)\b/,punctuation:/[{}[\];(),:]/}})(t)}return perl_1}var phpExtras_1,hasRequiredPhpExtras;function requirePhpExtras(){if(hasRequiredPhpExtras)return phpExtras_1;hasRequiredPhpExtras=1;var e=requirePhp();phpExtras_1=t,t.displayName="phpExtras",t.aliases=[];function t(Ye){Ye.register(e),Ye.languages.insertBefore("php","variable",{this:{pattern:/\$this\b/,alias:"keyword"},global:/\$(?:GLOBALS|HTTP_RAW_POST_DATA|_(?:COOKIE|ENV|FILES|GET|POST|REQUEST|SERVER|SESSION)|argc|argv|http_response_header|php_errormsg)\b/,scope:{pattern:/\b[\w\\]+::/,inside:{keyword:/\b(?:parent|self|static)\b/,punctuation:/::|\\/}}})}return phpExtras_1}var phpdoc_1,hasRequiredPhpdoc;function requirePhpdoc(){if(hasRequiredPhpdoc)return phpdoc_1;hasRequiredPhpdoc=1;var e=requirePhp(),t=requireJavadoclike();phpdoc_1=Ye,Ye.displayName="phpdoc",Ye.aliases=[];function Ye(tt){tt.register(e),tt.register(t),function(rt){var nt=/(?:\b[a-zA-Z]\w*|[|\\[\]])+/.source;rt.languages.phpdoc=rt.languages.extend("javadoclike",{parameter:{pattern:RegExp("(@(?:global|param|property(?:-read|-write)?|var)\\s+(?:"+nt+"\\s+)?)\\$\\w+"),lookbehind:!0}}),rt.languages.insertBefore("phpdoc","keyword",{"class-name":[{pattern:RegExp("(@(?:global|package|param|property(?:-read|-write)?|return|subpackage|throws|var)\\s+)"+nt),lookbehind:!0,inside:{keyword:/\b(?:array|bool|boolean|callback|double|false|float|int|integer|mixed|null|object|resource|self|string|true|void)\b/,punctuation:/[|\\[\]()]/}}]}),rt.languages.javadoclike.addSupport("php",rt.languages.phpdoc)}(tt)}return phpdoc_1}var plsql_1,hasRequiredPlsql;function requirePlsql(){if(hasRequiredPlsql)return plsql_1;hasRequiredPlsql=1;var e=requireSql();plsql_1=t,t.displayName="plsql",t.aliases=[];function t(Ye){Ye.register(e),Ye.languages.plsql=Ye.languages.extend("sql",{comment:{pattern:/\/\*[\s\S]*?\*\/|--.*/,greedy:!0},keyword:/\b(?:A|ACCESSIBLE|ADD|AGENT|AGGREGATE|ALL|ALTER|AND|ANY|ARRAY|AS|ASC|AT|ATTRIBUTE|AUTHID|AVG|BEGIN|BETWEEN|BFILE_BASE|BINARY|BLOB_BASE|BLOCK|BODY|BOTH|BOUND|BULK|BY|BYTE|C|CALL|CALLING|CASCADE|CASE|CHAR|CHARACTER|CHARSET|CHARSETFORM|CHARSETID|CHAR_BASE|CHECK|CLOB_BASE|CLONE|CLOSE|CLUSTER|CLUSTERS|COLAUTH|COLLECT|COLUMNS|COMMENT|COMMIT|COMMITTED|COMPILED|COMPRESS|CONNECT|CONSTANT|CONSTRUCTOR|CONTEXT|CONTINUE|CONVERT|COUNT|CRASH|CREATE|CREDENTIAL|CURRENT|CURSOR|CUSTOMDATUM|DANGLING|DATA|DATE|DATE_BASE|DAY|DECLARE|DEFAULT|DEFINE|DELETE|DESC|DETERMINISTIC|DIRECTORY|DISTINCT|DOUBLE|DROP|DURATION|ELEMENT|ELSE|ELSIF|EMPTY|END|ESCAPE|EXCEPT|EXCEPTION|EXCEPTIONS|EXCLUSIVE|EXECUTE|EXISTS|EXIT|EXTERNAL|FETCH|FINAL|FIRST|FIXED|FLOAT|FOR|FORALL|FORCE|FROM|FUNCTION|GENERAL|GOTO|GRANT|GROUP|HASH|HAVING|HEAP|HIDDEN|HOUR|IDENTIFIED|IF|IMMEDIATE|IMMUTABLE|IN|INCLUDING|INDEX|INDEXES|INDICATOR|INDICES|INFINITE|INSERT|INSTANTIABLE|INT|INTERFACE|INTERSECT|INTERVAL|INTO|INVALIDATE|IS|ISOLATION|JAVA|LANGUAGE|LARGE|LEADING|LENGTH|LEVEL|LIBRARY|LIKE|LIKE2|LIKE4|LIKEC|LIMIT|LIMITED|LOCAL|LOCK|LONG|LOOP|MAP|MAX|MAXLEN|MEMBER|MERGE|MIN|MINUS|MINUTE|MOD|MODE|MODIFY|MONTH|MULTISET|MUTABLE|NAME|NAN|NATIONAL|NATIVE|NCHAR|NEW|NOCOMPRESS|NOCOPY|NOT|NOWAIT|NULL|NUMBER_BASE|OBJECT|OCICOLL|OCIDATE|OCIDATETIME|OCIDURATION|OCIINTERVAL|OCILOBLOCATOR|OCINUMBER|OCIRAW|OCIREF|OCIREFCURSOR|OCIROWID|OCISTRING|OCITYPE|OF|OLD|ON|ONLY|OPAQUE|OPEN|OPERATOR|OPTION|OR|ORACLE|ORADATA|ORDER|ORGANIZATION|ORLANY|ORLVARY|OTHERS|OUT|OVERLAPS|OVERRIDING|PACKAGE|PARALLEL_ENABLE|PARAMETER|PARAMETERS|PARENT|PARTITION|PASCAL|PERSISTABLE|PIPE|PIPELINED|PLUGGABLE|POLYMORPHIC|PRAGMA|PRECISION|PRIOR|PRIVATE|PROCEDURE|PUBLIC|RAISE|RANGE|RAW|READ|RECORD|REF|REFERENCE|RELIES_ON|REM|REMAINDER|RENAME|RESOURCE|RESULT|RESULT_CACHE|RETURN|RETURNING|REVERSE|REVOKE|ROLLBACK|ROW|SAMPLE|SAVE|SAVEPOINT|SB1|SB2|SB4|SECOND|SEGMENT|SELECT|SELF|SEPARATE|SEQUENCE|SERIALIZABLE|SET|SHARE|SHORT|SIZE|SIZE_T|SOME|SPARSE|SQL|SQLCODE|SQLDATA|SQLNAME|SQLSTATE|STANDARD|START|STATIC|STDDEV|STORED|STRING|STRUCT|STYLE|SUBMULTISET|SUBPARTITION|SUBSTITUTABLE|SUBTYPE|SUM|SYNONYM|TABAUTH|TABLE|TDO|THE|THEN|TIME|TIMESTAMP|TIMEZONE_ABBR|TIMEZONE_HOUR|TIMEZONE_MINUTE|TIMEZONE_REGION|TO|TRAILING|TRANSACTION|TRANSACTIONAL|TRUSTED|TYPE|UB1|UB2|UB4|UNDER|UNION|UNIQUE|UNPLUG|UNSIGNED|UNTRUSTED|UPDATE|USE|USING|VALIST|VALUE|VALUES|VARIABLE|VARIANCE|VARRAY|VARYING|VIEW|VIEWS|VOID|WHEN|WHERE|WHILE|WITH|WORK|WRAPPED|WRITE|YEAR|ZONE)\b/i,operator:/:=?|=>|[<>^~!]=|\.\.|\|\||\*\*|[-+*/%<>=@]/}),Ye.languages.insertBefore("plsql","operator",{label:{pattern:/<<\s*\w+\s*>>/,alias:"symbol"}})}return plsql_1}var powerquery_1,hasRequiredPowerquery;function requirePowerquery(){if(hasRequiredPowerquery)return powerquery_1;hasRequiredPowerquery=1,powerquery_1=e,e.displayName="powerquery",e.aliases=[];function e(t){t.languages.powerquery={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|\/\/.*)/,lookbehind:!0,greedy:!0},"quoted-identifier":{pattern:/#"(?:[^"\r\n]|"")*"(?!")/,greedy:!0},string:{pattern:/(?:#!)?"(?:[^"\r\n]|"")*"(?!")/,greedy:!0},constant:[/\bDay\.(?:Friday|Monday|Saturday|Sunday|Thursday|Tuesday|Wednesday)\b/,/\bTraceLevel\.(?:Critical|Error|Information|Verbose|Warning)\b/,/\bOccurrence\.(?:All|First|Last)\b/,/\bOrder\.(?:Ascending|Descending)\b/,/\bRoundingMode\.(?:AwayFromZero|Down|ToEven|TowardZero|Up)\b/,/\bMissingField\.(?:Error|Ignore|UseNull)\b/,/\bQuoteStyle\.(?:Csv|None)\b/,/\bJoinKind\.(?:FullOuter|Inner|LeftAnti|LeftOuter|RightAnti|RightOuter)\b/,/\bGroupKind\.(?:Global|Local)\b/,/\bExtraValues\.(?:Error|Ignore|List)\b/,/\bJoinAlgorithm\.(?:Dynamic|LeftHash|LeftIndex|PairwiseHash|RightHash|RightIndex|SortMerge)\b/,/\bJoinSide\.(?:Left|Right)\b/,/\bPrecision\.(?:Decimal|Double)\b/,/\bRelativePosition\.From(?:End|Start)\b/,/\bTextEncoding\.(?:Ascii|BigEndianUnicode|Unicode|Utf16|Utf8|Windows)\b/,/\b(?:Any|Binary|Date|DateTime|DateTimeZone|Duration|Function|Int16|Int32|Int64|Int8|List|Logical|None|Number|Record|Table|Text|Time)\.Type\b/,/\bnull\b/],boolean:/\b(?:false|true)\b/,keyword:/\b(?:and|as|each|else|error|if|in|is|let|meta|not|nullable|optional|or|otherwise|section|shared|then|try|type)\b|#(?:binary|date|datetime|datetimezone|duration|infinity|nan|sections|shared|table|time)\b/,function:{pattern:/(^|[^#\w.])[a-z_][\w.]*(?=\s*\()/i,lookbehind:!0},"data-type":{pattern:/\b(?:any|anynonnull|binary|date|datetime|datetimezone|duration|function|list|logical|none|number|record|table|text|time)\b/,alias:"class-name"},number:{pattern:/\b0x[\da-f]+\b|(?:[+-]?(?:\b\d+\.)?\b\d+|[+-]\.\d+|(^|[^.])\B\.\d+)(?:e[+-]?\d+)?\b/i,lookbehind:!0},operator:/[-+*\/&?@^]|<(?:=>?|>)?|>=?|=>?|\.\.\.?/,punctuation:/[,;\[\](){}]/},t.languages.pq=t.languages.powerquery,t.languages.mscript=t.languages.powerquery}return powerquery_1}var powershell_1,hasRequiredPowershell;function requirePowershell(){if(hasRequiredPowershell)return powershell_1;hasRequiredPowershell=1,powershell_1=e,e.displayName="powershell",e.aliases=[];function e(t){(function(Ye){var tt=Ye.languages.powershell={comment:[{pattern:/(^|[^`])<#[\s\S]*?#>/,lookbehind:!0},{pattern:/(^|[^`])#.*/,lookbehind:!0}],string:[{pattern:/"(?:`[\s\S]|[^`"])*"/,greedy:!0,inside:null},{pattern:/'(?:[^']|'')*'/,greedy:!0}],namespace:/\[[a-z](?:\[(?:\[[^\]]*\]|[^\[\]])*\]|[^\[\]])*\]/i,boolean:/\$(?:false|true)\b/i,variable:/\$\w+\b/,function:[/\b(?:Add|Approve|Assert|Backup|Block|Checkpoint|Clear|Close|Compare|Complete|Compress|Confirm|Connect|Convert|ConvertFrom|ConvertTo|Copy|Debug|Deny|Disable|Disconnect|Dismount|Edit|Enable|Enter|Exit|Expand|Export|Find|ForEach|Format|Get|Grant|Group|Hide|Import|Initialize|Install|Invoke|Join|Limit|Lock|Measure|Merge|Move|New|Open|Optimize|Out|Ping|Pop|Protect|Publish|Push|Read|Receive|Redo|Register|Remove|Rename|Repair|Request|Reset|Resize|Resolve|Restart|Restore|Resume|Revoke|Save|Search|Select|Send|Set|Show|Skip|Sort|Split|Start|Step|Stop|Submit|Suspend|Switch|Sync|Tee|Test|Trace|Unblock|Undo|Uninstall|Unlock|Unprotect|Unpublish|Unregister|Update|Use|Wait|Watch|Where|Write)-[a-z]+\b/i,/\b(?:ac|cat|chdir|clc|cli|clp|clv|compare|copy|cp|cpi|cpp|cvpa|dbp|del|diff|dir|ebp|echo|epal|epcsv|epsn|erase|fc|fl|ft|fw|gal|gbp|gc|gci|gcs|gdr|gi|gl|gm|gp|gps|group|gsv|gu|gv|gwmi|iex|ii|ipal|ipcsv|ipsn|irm|iwmi|iwr|kill|lp|ls|measure|mi|mount|move|mp|mv|nal|ndr|ni|nv|ogv|popd|ps|pushd|pwd|rbp|rd|rdr|ren|ri|rm|rmdir|rni|rnp|rp|rv|rvpa|rwmi|sal|saps|sasv|sbp|sc|select|set|shcm|si|sl|sleep|sls|sort|sp|spps|spsv|start|sv|swmi|tee|trcm|type|write)\b/i],keyword:/\b(?:Begin|Break|Catch|Class|Continue|Data|Define|Do|DynamicParam|Else|ElseIf|End|Exit|Filter|Finally|For|ForEach|From|Function|If|InlineScript|Parallel|Param|Process|Return|Sequence|Switch|Throw|Trap|Try|Until|Using|Var|While|Workflow)\b/i,operator:{pattern:/(^|\W)(?:!|-(?:b?(?:and|x?or)|as|(?:Not)?(?:Contains|In|Like|Match)|eq|ge|gt|is(?:Not)?|Join|le|lt|ne|not|Replace|sh[lr])\b|-[-=]?|\+[+=]?|[*\/%]=?)/i,lookbehind:!0},punctuation:/[|{}[\];(),.]/};tt.string[0].inside={function:{pattern:/(^|[^`])\$\((?:\$\([^\r\n()]*\)|(?!\$\()[^\r\n)])*\)/,lookbehind:!0,inside:tt},boolean:tt.boolean,variable:tt.variable}})(t)}return powershell_1}var processing_1,hasRequiredProcessing;function requireProcessing(){if(hasRequiredProcessing)return processing_1;hasRequiredProcessing=1,processing_1=e,e.displayName="processing",e.aliases=[];function e(t){t.languages.processing=t.languages.extend("clike",{keyword:/\b(?:break|case|catch|class|continue|default|else|extends|final|for|if|implements|import|new|null|private|public|return|static|super|switch|this|try|void|while)\b/,function:/\b\w+(?=\s*\()/,operator:/<[<=]?|>[>=]?|&&?|\|\|?|[%?]|[!=+\-*\/]=?/}),t.languages.insertBefore("processing","number",{constant:/\b(?!XML\b)[A-Z][A-Z\d_]+\b/,type:{pattern:/\b(?:boolean|byte|char|color|double|float|int|[A-Z]\w*)\b/,alias:"class-name"}})}return processing_1}var prolog_1,hasRequiredProlog;function requireProlog(){if(hasRequiredProlog)return prolog_1;hasRequiredProlog=1,prolog_1=e,e.displayName="prolog",e.aliases=[];function e(t){t.languages.prolog={comment:{pattern:/\/\*[\s\S]*?\*\/|%.*/,greedy:!0},string:{pattern:/(["'])(?:\1\1|\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1(?!\1)/,greedy:!0},builtin:/\b(?:fx|fy|xf[xy]?|yfx?)\b/,function:/\b[a-z]\w*(?:(?=\()|\/\d+)/,number:/\b\d+(?:\.\d*)?/,operator:/[:\\=><\-?*@\/;+^|!$.]+|\b(?:is|mod|not|xor)\b/,punctuation:/[(){}\[\],]/}}return prolog_1}var promql_1,hasRequiredPromql;function requirePromql(){if(hasRequiredPromql)return promql_1;hasRequiredPromql=1,promql_1=e,e.displayName="promql",e.aliases=[];function e(t){(function(Ye){var tt=["sum","min","max","avg","group","stddev","stdvar","count","count_values","bottomk","topk","quantile"],rt=["on","ignoring","group_right","group_left","by","without"],nt=["offset"],at=tt.concat(rt,nt);Ye.languages.promql={comment:{pattern:/(^[ \t]*)#.*/m,lookbehind:!0},"vector-match":{pattern:new RegExp("((?:"+rt.join("|")+")\\s*)\\([^)]*\\)"),lookbehind:!0,inside:{"label-key":{pattern:/\b[^,]+\b/,alias:"attr-name"},punctuation:/[(),]/}},"context-labels":{pattern:/\{[^{}]*\}/,inside:{"label-key":{pattern:/\b[a-z_]\w*(?=\s*(?:=|![=~]))/,alias:"attr-name"},"label-value":{pattern:/(["'`])(?:\\[\s\S]|(?!\1)[^\\])*\1/,greedy:!0,alias:"attr-value"},punctuation:/\{|\}|=~?|![=~]|,/}},"context-range":[{pattern:/\[[\w\s:]+\]/,inside:{punctuation:/\[|\]|:/,"range-duration":{pattern:/\b(?:\d+(?:[smhdwy]|ms))+\b/i,alias:"number"}}},{pattern:/(\boffset\s+)\w+/,lookbehind:!0,inside:{"range-duration":{pattern:/\b(?:\d+(?:[smhdwy]|ms))+\b/i,alias:"number"}}}],keyword:new RegExp("\\b(?:"+at.join("|")+")\\b","i"),function:/\b[a-z_]\w*(?=\s*\()/i,number:/[-+]?(?:(?:\b\d+(?:\.\d+)?|\B\.\d+)(?:e[-+]?\d+)?\b|\b(?:0x[0-9a-f]+|nan|inf)\b)/i,operator:/[\^*/%+-]|==|!=|<=|<|>=|>|\b(?:and|or|unless)\b/i,punctuation:/[{};()`,.[\]]/}})(t)}return promql_1}var properties_1,hasRequiredProperties$2;function requireProperties$2(){if(hasRequiredProperties$2)return properties_1;hasRequiredProperties$2=1,properties_1=e,e.displayName="properties",e.aliases=[];function e(t){t.languages.properties={comment:/^[ \t]*[#!].*$/m,"attr-value":{pattern:/(^[ \t]*(?:\\(?:\r\n|[\s\S])|[^\\\s:=])+(?: *[=:] *(?! )| ))(?:\\(?:\r\n|[\s\S])|[^\\\r\n])+/m,lookbehind:!0},"attr-name":/^[ \t]*(?:\\(?:\r\n|[\s\S])|[^\\\s:=])+(?= *[=:]| )/m,punctuation:/[=:]/}}return properties_1}var protobuf_1,hasRequiredProtobuf;function requireProtobuf(){if(hasRequiredProtobuf)return protobuf_1;hasRequiredProtobuf=1,protobuf_1=e,e.displayName="protobuf",e.aliases=[];function e(t){(function(Ye){var tt=/\b(?:bool|bytes|double|s?fixed(?:32|64)|float|[su]?int(?:32|64)|string)\b/;Ye.languages.protobuf=Ye.languages.extend("clike",{"class-name":[{pattern:/(\b(?:enum|extend|message|service)\s+)[A-Za-z_]\w*(?=\s*\{)/,lookbehind:!0},{pattern:/(\b(?:rpc\s+\w+|returns)\s*\(\s*(?:stream\s+)?)\.?[A-Za-z_]\w*(?:\.[A-Za-z_]\w*)*(?=\s*\))/,lookbehind:!0}],keyword:/\b(?:enum|extend|extensions|import|message|oneof|option|optional|package|public|repeated|required|reserved|returns|rpc(?=\s+\w)|service|stream|syntax|to)\b(?!\s*=\s*\d)/,function:/\b[a-z_]\w*(?=\s*\()/i}),Ye.languages.insertBefore("protobuf","operator",{map:{pattern:/\bmap<\s*[\w.]+\s*,\s*[\w.]+\s*>(?=\s+[a-z_]\w*\s*[=;])/i,alias:"class-name",inside:{punctuation:/[<>.,]/,builtin:tt}},builtin:tt,"positional-class-name":{pattern:/(?:\b|\B\.)[a-z_]\w*(?:\.[a-z_]\w*)*(?=\s+[a-z_]\w*\s*[=;])/i,alias:"class-name",inside:{punctuation:/\./}},annotation:{pattern:/(\[\s*)[a-z_]\w*(?=\s*=)/i,lookbehind:!0}})})(t)}return protobuf_1}var psl_1,hasRequiredPsl;function requirePsl(){if(hasRequiredPsl)return psl_1;hasRequiredPsl=1,psl_1=e,e.displayName="psl",e.aliases=[];function e(t){t.languages.psl={comment:{pattern:/#.*/,greedy:!0},string:{pattern:/"(?:\\.|[^\\"])*"/,greedy:!0,inside:{symbol:/\\[ntrbA-Z"\\]/}},"heredoc-string":{pattern:/<<<([a-zA-Z_]\w*)[\r\n](?:.*[\r\n])*?\1\b/,alias:"string",greedy:!0},keyword:/\b(?:__multi|__single|case|default|do|else|elsif|exit|export|for|foreach|function|if|last|line|local|next|requires|return|switch|until|while|word)\b/,constant:/\b(?:ALARM|CHART_ADD_GRAPH|CHART_DELETE_GRAPH|CHART_DESTROY|CHART_LOAD|CHART_PRINT|EOF|OFFLINE|OK|PSL_PROF_LOG|R_CHECK_HORIZ|R_CHECK_VERT|R_CLICKER|R_COLUMN|R_FRAME|R_ICON|R_LABEL|R_LABEL_CENTER|R_LIST_MULTIPLE|R_LIST_MULTIPLE_ND|R_LIST_SINGLE|R_LIST_SINGLE_ND|R_MENU|R_POPUP|R_POPUP_SCROLLED|R_RADIO_HORIZ|R_RADIO_VERT|R_ROW|R_SCALE_HORIZ|R_SCALE_VERT|R_SEP_HORIZ|R_SEP_VERT|R_SPINNER|R_TEXT_FIELD|R_TEXT_FIELD_LABEL|R_TOGGLE|TRIM_LEADING|TRIM_LEADING_AND_TRAILING|TRIM_REDUNDANT|TRIM_TRAILING|VOID|WARN)\b/,boolean:/\b(?:FALSE|False|NO|No|TRUE|True|YES|Yes|false|no|true|yes)\b/,variable:/\b(?:PslDebug|errno|exit_status)\b/,builtin:{pattern:/\b(?:PslExecute|PslFunctionCall|PslFunctionExists|PslSetOptions|_snmp_debug|acos|add_diary|annotate|annotate_get|ascii_to_ebcdic|asctime|asin|atan|atexit|batch_set|blackout|cat|ceil|chan_exists|change_state|close|code_cvt|cond_signal|cond_wait|console_type|convert_base|convert_date|convert_locale_date|cos|cosh|create|date|dcget_text|destroy|destroy_lock|dget_text|difference|dump_hist|ebcdic_to_ascii|encrypt|event_archive|event_catalog_get|event_check|event_query|event_range_manage|event_range_query|event_report|event_schedule|event_trigger|event_trigger2|execute|exists|exp|fabs|file|floor|fmod|fopen|fseek|ftell|full_discovery|get|get_chan_info|get_ranges|get_text|get_vars|getenv|gethostinfo|getpid|getpname|grep|history|history_get_retention|in_transition|index|int|internal|intersection|is_var|isnumber|join|kill|length|lines|lock|lock_info|log|log10|loge|matchline|msg_check|msg_get_format|msg_get_severity|msg_printf|msg_sprintf|ntharg|nthargf|nthline|nthlinef|num_bytes|num_consoles|pconfig|popen|poplines|pow|print|printf|proc_exists|process|random|read|readln|refresh_parameters|remote_check|remote_close|remote_event_query|remote_event_trigger|remote_file_send|remote_open|remove|replace|rindex|sec_check_priv|sec_store_get|sec_store_set|set|set_alarm_ranges|set_locale|share|sin|sinh|sleep|snmp_agent_config|snmp_agent_start|snmp_agent_stop|snmp_close|snmp_config|snmp_get|snmp_get_next|snmp_h_get|snmp_h_get_next|snmp_h_set|snmp_open|snmp_set|snmp_trap_ignore|snmp_trap_listen|snmp_trap_raise_std_trap|snmp_trap_receive|snmp_trap_register_im|snmp_trap_send|snmp_walk|sopen|sort|splitline|sprintf|sqrt|srandom|str_repeat|strcasecmp|subset|substr|system|tail|tan|tanh|text_domain|time|tmpnam|tolower|toupper|trace_psl_process|trim|union|unique|unlock|unset|va_arg|va_start|write)\b/,alias:"builtin-function"},"foreach-variable":{pattern:/(\bforeach\s+(?:(?:\w+\b|"(?:\\.|[^\\"])*")\s+){0,2})[_a-zA-Z]\w*(?=\s*\()/,lookbehind:!0,greedy:!0},function:/\b[_a-z]\w*\b(?=\s*\()/i,number:/\b(?:0x[0-9a-f]+|\d+(?:\.\d+)?)\b/i,operator:/--|\+\+|&&=?|\|\|=?|<<=?|>>=?|[=!]~|[-+*/%&|^!=<>]=?|\.|[:?]/,punctuation:/[(){}\[\];,]/}}return psl_1}var pug_1,hasRequiredPug;function requirePug(){if(hasRequiredPug)return pug_1;hasRequiredPug=1,pug_1=e,e.displayName="pug",e.aliases=[];function e(t){(function(Ye){Ye.languages.pug={comment:{pattern:/(^([\t ]*))\/\/.*(?:(?:\r?\n|\r)\2[\t ].+)*/m,lookbehind:!0},"multiline-script":{pattern:/(^([\t ]*)script\b.*\.[\t ]*)(?:(?:\r?\n|\r(?!\n))(?:\2[\t ].+|\s*?(?=\r?\n|\r)))+/m,lookbehind:!0,inside:Ye.languages.javascript},filter:{pattern:/(^([\t ]*)):.+(?:(?:\r?\n|\r(?!\n))(?:\2[\t ].+|\s*?(?=\r?\n|\r)))+/m,lookbehind:!0,inside:{"filter-name":{pattern:/^:[\w-]+/,alias:"variable"},text:/\S[\s\S]*/}},"multiline-plain-text":{pattern:/(^([\t ]*)[\w\-#.]+\.[\t ]*)(?:(?:\r?\n|\r(?!\n))(?:\2[\t ].+|\s*?(?=\r?\n|\r)))+/m,lookbehind:!0},markup:{pattern:/(^[\t ]*)<.+/m,lookbehind:!0,inside:Ye.languages.markup},doctype:{pattern:/((?:^|\n)[\t ]*)doctype(?: .+)?/,lookbehind:!0},"flow-control":{pattern:/(^[\t ]*)(?:case|default|each|else|if|unless|when|while)\b(?: .+)?/m,lookbehind:!0,inside:{each:{pattern:/^each .+? in\b/,inside:{keyword:/\b(?:each|in)\b/,punctuation:/,/}},branch:{pattern:/^(?:case|default|else|if|unless|when|while)\b/,alias:"keyword"},rest:Ye.languages.javascript}},keyword:{pattern:/(^[\t ]*)(?:append|block|extends|include|prepend)\b.+/m,lookbehind:!0},mixin:[{pattern:/(^[\t ]*)mixin .+/m,lookbehind:!0,inside:{keyword:/^mixin/,function:/\w+(?=\s*\(|\s*$)/,punctuation:/[(),.]/}},{pattern:/(^[\t ]*)\+.+/m,lookbehind:!0,inside:{name:{pattern:/^\+\w+/,alias:"function"},rest:Ye.languages.javascript}}],script:{pattern:/(^[\t ]*script(?:(?:&[^(]+)?\([^)]+\))*[\t ]).+/m,lookbehind:!0,inside:Ye.languages.javascript},"plain-text":{pattern:/(^[\t ]*(?!-)[\w\-#.]*[\w\-](?:(?:&[^(]+)?\([^)]+\))*\/?[\t ]).+/m,lookbehind:!0},tag:{pattern:/(^[\t ]*)(?!-)[\w\-#.]*[\w\-](?:(?:&[^(]+)?\([^)]+\))*\/?:?/m,lookbehind:!0,inside:{attributes:[{pattern:/&[^(]+\([^)]+\)/,inside:Ye.languages.javascript},{pattern:/\([^)]+\)/,inside:{"attr-value":{pattern:/(=\s*(?!\s))(?:\{[^}]*\}|[^,)\r\n]+)/,lookbehind:!0,inside:Ye.languages.javascript},"attr-name":/[\w-]+(?=\s*!?=|\s*[,)])/,punctuation:/[!=(),]+/}}],punctuation:/:/,"attr-id":/#[\w\-]+/,"attr-class":/\.[\w\-]+/}},code:[{pattern:/(^[\t ]*(?:-|!?=)).+/m,lookbehind:!0,inside:Ye.languages.javascript}],punctuation:/[.\-!=|]+/};for(var tt=/(^([\t ]*)):<filter_name>(?:(?:\r?\n|\r(?!\n))(?:\2[\t ].+|\s*?(?=\r?\n|\r)))+/.source,rt=[{filter:"atpl",language:"twig"},{filter:"coffee",language:"coffeescript"},"ejs","handlebars","less","livescript","markdown",{filter:"sass",language:"scss"},"stylus"],nt={},at=0,it=rt.length;at<it;at++){var ot=rt[at];ot=typeof ot=="string"?{filter:ot,language:ot}:ot,Ye.languages[ot.language]&&(nt["filter-"+ot.filter]={pattern:RegExp(tt.replace("<filter_name>",function(){return ot.filter}),"m"),lookbehind:!0,inside:{"filter-name":{pattern:/^:[\w-]+/,alias:"variable"},text:{pattern:/\S[\s\S]*/,alias:[ot.language,"language-"+ot.language],inside:Ye.languages[ot.language]}}})}Ye.languages.insertBefore("pug","filter",nt)})(t)}return pug_1}var puppet_1,hasRequiredPuppet;function requirePuppet(){if(hasRequiredPuppet)return puppet_1;hasRequiredPuppet=1,puppet_1=e,e.displayName="puppet",e.aliases=[];function e(t){(function(Ye){Ye.languages.puppet={heredoc:[{pattern:/(@\("([^"\r\n\/):]+)"(?:\/[nrts$uL]*)?\).*(?:\r?\n|\r))(?:.*(?:\r?\n|\r(?!\n)))*?[ \t]*(?:\|[ \t]*)?(?:-[ \t]*)?\2/,lookbehind:!0,alias:"string",inside:{punctuation:/(?=\S).*\S(?= *$)/}},{pattern:/(@\(([^"\r\n\/):]+)(?:\/[nrts$uL]*)?\).*(?:\r?\n|\r))(?:.*(?:\r?\n|\r(?!\n)))*?[ \t]*(?:\|[ \t]*)?(?:-[ \t]*)?\2/,lookbehind:!0,greedy:!0,alias:"string",inside:{punctuation:/(?=\S).*\S(?= *$)/}},{pattern:/@\("?(?:[^"\r\n\/):]+)"?(?:\/[nrts$uL]*)?\)/,alias:"string",inside:{punctuation:{pattern:/(\().+?(?=\))/,lookbehind:!0}}}],"multiline-comment":{pattern:/(^|[^\\])\/\*[\s\S]*?\*\//,lookbehind:!0,greedy:!0,alias:"comment"},regex:{pattern:/((?:\bnode\s+|[~=\(\[\{,]\s*|[=+]>\s*|^\s*))\/(?:[^\/\\]|\\[\s\S])+\/(?:[imx]+\b|\B)/,lookbehind:!0,greedy:!0,inside:{"extended-regex":{pattern:/^\/(?:[^\/\\]|\\[\s\S])+\/[im]*x[im]*$/,inside:{comment:/#.*/}}}},comment:{pattern:/(^|[^\\])#.*/,lookbehind:!0,greedy:!0},string:{pattern:/(["'])(?:\$\{(?:[^'"}]|(["'])(?:(?!\2)[^\\]|\\[\s\S])*\2)+\}|\$(?!\{)|(?!\1)[^\\$]|\\[\s\S])*\1/,greedy:!0,inside:{"double-quoted":{pattern:/^"[\s\S]*"$/,inside:{}}}},variable:{pattern:/\$(?:::)?\w+(?:::\w+)*/,inside:{punctuation:/::/}},"attr-name":/(?:\b\w+|\*)(?=\s*=>)/,function:[{pattern:/(\.)(?!\d)\w+/,lookbehind:!0},/\b(?:contain|debug|err|fail|include|info|notice|realize|require|tag|warning)\b|\b(?!\d)\w+(?=\()/],number:/\b(?:0x[a-f\d]+|\d+(?:\.\d+)?(?:e-?\d+)?)\b/i,boolean:/\b(?:false|true)\b/,keyword:/\b(?:application|attr|case|class|consumes|default|define|else|elsif|function|if|import|inherits|node|private|produces|type|undef|unless)\b/,datatype:{pattern:/\b(?:Any|Array|Boolean|Callable|Catalogentry|Class|Collection|Data|Default|Enum|Float|Hash|Integer|NotUndef|Numeric|Optional|Pattern|Regexp|Resource|Runtime|Scalar|String|Struct|Tuple|Type|Undef|Variant)\b/,alias:"symbol"},operator:/=[=~>]?|![=~]?|<(?:<\|?|[=~|-])?|>[>=]?|->?|~>|\|>?>?|[*\/%+?]|\b(?:and|in|or)\b/,punctuation:/[\[\]{}().,;]|:+/};var tt=[{pattern:/(^|[^\\])\$\{(?:[^'"{}]|\{[^}]*\}|(["'])(?:(?!\2)[^\\]|\\[\s\S])*\2)+\}/,lookbehind:!0,inside:{"short-variable":{pattern:/(^\$\{)(?!\w+\()(?:::)?\w+(?:::\w+)*/,lookbehind:!0,alias:"variable",inside:{punctuation:/::/}},delimiter:{pattern:/^\$/,alias:"variable"},rest:Ye.languages.puppet}},{pattern:/(^|[^\\])\$(?:::)?\w+(?:::\w+)*/,lookbehind:!0,alias:"variable",inside:{punctuation:/::/}}];Ye.languages.puppet.heredoc[0].inside.interpolation=tt,Ye.languages.puppet.string.inside["double-quoted"].inside.interpolation=tt})(t)}return puppet_1}var pure_1,hasRequiredPure;function requirePure(){if(hasRequiredPure)return pure_1;hasRequiredPure=1,pure_1=e,e.displayName="pure",e.aliases=[];function e(t){(function(Ye){Ye.languages.pure={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?\*\//,lookbehind:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0},/#!.+/],"inline-lang":{pattern:/%<[\s\S]+?%>/,greedy:!0,inside:{lang:{pattern:/(^%< *)-\*-.+?-\*-/,lookbehind:!0,alias:"comment"},delimiter:{pattern:/^%<.*|%>$/,alias:"punctuation"}}},string:{pattern:/"(?:\\.|[^"\\\r\n])*"/,greedy:!0},number:{pattern:/((?:\.\.)?)(?:\b(?:inf|nan)\b|\b0x[\da-f]+|(?:\b(?:0b)?\d+(?:\.\d+)?|\B\.\d+)(?:e[+-]?\d+)?L?)/i,lookbehind:!0},keyword:/\b(?:NULL|ans|break|bt|case|catch|cd|clear|const|def|del|dump|else|end|exit|extern|false|force|help|if|infix[lr]?|interface|let|ls|mem|namespace|nonfix|of|otherwise|outfix|override|postfix|prefix|private|public|pwd|quit|run|save|show|stats|then|throw|trace|true|type|underride|using|when|with)\b/,function:/\b(?:abs|add_(?:addr|constdef|(?:fundef|interface|macdef|typedef)(?:_at)?|vardef)|all|any|applp?|arity|bigintp?|blob(?:_crc|_size|p)?|boolp?|byte_c?string(?:_pointer)?|byte_(?:matrix|pointer)|calloc|cat|catmap|ceil|char[ps]?|check_ptrtag|chr|clear_sentry|clearsym|closurep?|cmatrixp?|cols?|colcat(?:map)?|colmap|colrev|colvector(?:p|seq)?|complex(?:_float_(?:matrix|pointer)|_matrix(?:_view)?|_pointer|p)?|conj|cookedp?|cst|cstring(?:_(?:dup|list|vector))?|curry3?|cyclen?|del_(?:constdef|fundef|interface|macdef|typedef|vardef)|delete|diag(?:mat)?|dim|dmatrixp?|do|double(?:_matrix(?:_view)?|_pointer|p)?|dowith3?|drop|dropwhile|eval(?:cmd)?|exactp|filter|fix|fixity|flip|float(?:_matrix|_pointer)|floor|fold[lr]1?|frac|free|funp?|functionp?|gcd|get(?:_(?:byte|constdef|double|float|fundef|int(?:64)?|interface(?:_typedef)?|long|macdef|pointer|ptrtag|sentry|short|string|typedef|vardef))?|globsym|hash|head|id|im|imatrixp?|index|inexactp|infp|init|insert|int(?:_matrix(?:_view)?|_pointer|p)?|int64_(?:matrix|pointer)|integerp?|iteraten?|iterwhile|join|keys?|lambdap?|last(?:err(?:pos)?)?|lcd|list[2p]?|listmap|make_ptrtag|malloc|map|matcat|matrixp?|max|member|min|nanp|nargs|nmatrixp?|null|numberp?|ord|pack(?:ed)?|pointer(?:_cast|_tag|_type|p)?|pow|pred|ptrtag|put(?:_(?:byte|double|float|int(?:64)?|long|pointer|short|string))?|rationalp?|re|realp?|realloc|recordp?|redim|reduce(?:_with)?|refp?|repeatn?|reverse|rlistp?|round|rows?|rowcat(?:map)?|rowmap|rowrev|rowvector(?:p|seq)?|same|scan[lr]1?|sentry|sgn|short_(?:matrix|pointer)|slice|smatrixp?|sort|split|str|strcat|stream|stride|string(?:_(?:dup|list|vector)|p)?|subdiag(?:mat)?|submat|subseq2?|substr|succ|supdiag(?:mat)?|symbolp?|tail|take|takewhile|thunkp?|transpose|trunc|tuplep?|typep|ubyte|uint(?:64)?|ulong|uncurry3?|unref|unzip3?|update|ushort|vals?|varp?|vector(?:p|seq)?|void|zip3?|zipwith3?)\b/,special:{pattern:/\b__[a-z]+__\b/i,alias:"builtin"},operator:/(?:[!"#$%&'*+,\-.\/:<=>?@\\^`|~\u00a1-\u00bf\u00d7-\u00f7\u20d0-\u2bff]|\b_+\b)+|\b(?:and|div|mod|not|or)\b/,punctuation:/[(){}\[\];,|]/};var tt=["c",{lang:"c++",alias:"cpp"},"fortran"],rt=/%< *-\*- *<lang>\d* *-\*-[\s\S]+?%>/.source;tt.forEach(function(nt){var at=nt;if(typeof nt!="string"&&(at=nt.alias,nt=nt.lang),Ye.languages[at]){var it={};it["inline-lang-"+at]={pattern:RegExp(rt.replace("<lang>",nt.replace(/([.+*?\/\\(){}\[\]])/g,"\\$1")),"i"),inside:Ye.util.clone(Ye.languages.pure["inline-lang"].inside)},it["inline-lang-"+at].inside.rest=Ye.util.clone(Ye.languages[at]),Ye.languages.insertBefore("pure","inline-lang",it)}}),Ye.languages.c&&(Ye.languages.pure["inline-lang"].inside.rest=Ye.util.clone(Ye.languages.c))})(t)}return pure_1}var purebasic_1,hasRequiredPurebasic;function requirePurebasic(){if(hasRequiredPurebasic)return purebasic_1;hasRequiredPurebasic=1,purebasic_1=e,e.displayName="purebasic",e.aliases=[];function e(t){t.languages.purebasic=t.languages.extend("clike",{comment:/;.*/,keyword:/\b(?:align|and|as|break|calldebugger|case|compilercase|compilerdefault|compilerelse|compilerelseif|compilerendif|compilerendselect|compilererror|compilerif|compilerselect|continue|data|datasection|debug|debuglevel|declare|declarec|declarecdll|declaredll|declaremodule|default|define|dim|disableasm|disabledebugger|disableexplicit|else|elseif|enableasm|enabledebugger|enableexplicit|end|enddatasection|enddeclaremodule|endenumeration|endif|endimport|endinterface|endmacro|endmodule|endprocedure|endselect|endstructure|endstructureunion|endwith|enumeration|extends|fakereturn|for|foreach|forever|global|gosub|goto|if|import|importc|includebinary|includefile|includepath|interface|macro|module|newlist|newmap|next|not|or|procedure|procedurec|procedurecdll|proceduredll|procedurereturn|protected|prototype|prototypec|read|redim|repeat|restore|return|runtime|select|shared|static|step|structure|structureunion|swap|threaded|to|until|wend|while|with|xincludefile|xor)\b/i,function:/\b\w+(?:\.\w+)?\s*(?=\()/,number:/(?:\$[\da-f]+|\b-?(?:\d+(?:\.\d+)?|\.\d+)(?:e[+-]?\d+)?)\b/i,operator:/(?:@\*?|\?|\*)\w+|-[>-]?|\+\+?|!=?|<<?=?|>>?=?|==?|&&?|\|?\||[~^%?*/@]/}),t.languages.insertBefore("purebasic","keyword",{tag:/#\w+\$?/,asm:{pattern:/(^[\t ]*)!.*/m,lookbehind:!0,alias:"tag",inside:{comment:/;.*/,string:{pattern:/(["'`])(?:\\.|(?!\1)[^\\\r\n])*\1/,greedy:!0},"label-reference-anonymous":{pattern:/(!\s*j[a-z]+\s+)@[fb]/i,lookbehind:!0,alias:"fasm-label"},"label-reference-addressed":{pattern:/(!\s*j[a-z]+\s+)[A-Z._?$@][\w.?$@~#]*/i,lookbehind:!0,alias:"fasm-label"},keyword:[/\b(?:extern|global)\b[^;\r\n]*/i,/\b(?:CPU|DEFAULT|FLOAT)\b.*/],function:{pattern:/^([\t ]*!\s*)[\da-z]+(?=\s|$)/im,lookbehind:!0},"function-inline":{pattern:/(:\s*)[\da-z]+(?=\s)/i,lookbehind:!0,alias:"function"},label:{pattern:/^([\t ]*!\s*)[A-Za-z._?$@][\w.?$@~#]*(?=:)/m,lookbehind:!0,alias:"fasm-label"},register:/\b(?:st\d|[xyz]mm\d\d?|[cdt]r\d|r\d\d?[bwd]?|[er]?[abcd]x|[abcd][hl]|[er]?(?:bp|di|si|sp)|[cdefgs]s|mm\d+)\b/i,number:/(?:\b|-|(?=\$))(?:0[hx](?:[\da-f]*\.)?[\da-f]+(?:p[+-]?\d+)?|\d[\da-f]+[hx]|\$\d[\da-f]*|0[oq][0-7]+|[0-7]+[oq]|0[by][01]+|[01]+[by]|0[dt]\d+|(?:\d+(?:\.\d+)?|\.\d+)(?:\.?e[+-]?\d+)?[dt]?)\b/i,operator:/[\[\]*+\-/%<>=&|$!,.:]/}}}),delete t.languages.purebasic["class-name"],delete t.languages.purebasic.boolean,t.languages.pbfasm=t.languages.purebasic}return purebasic_1}var purescript_1,hasRequiredPurescript;function requirePurescript(){if(hasRequiredPurescript)return purescript_1;hasRequiredPurescript=1;var e=requireHaskell();purescript_1=t,t.displayName="purescript",t.aliases=["purs"];function t(Ye){Ye.register(e),Ye.languages.purescript=Ye.languages.extend("haskell",{keyword:/\b(?:ado|case|class|data|derive|do|else|forall|if|in|infixl|infixr|instance|let|module|newtype|of|primitive|then|type|where)\b|∀/,"import-statement":{pattern:/(^[\t ]*)import\s+[A-Z][\w']*(?:\.[A-Z][\w']*)*(?:\s+as\s+[A-Z][\w']*(?:\.[A-Z][\w']*)*)?(?:\s+hiding\b)?/m,lookbehind:!0,inside:{keyword:/\b(?:as|hiding|import)\b/,punctuation:/\./}},builtin:/\b(?:absurd|add|ap|append|apply|between|bind|bottom|clamp|compare|comparing|compose|conj|const|degree|discard|disj|div|eq|flap|flip|gcd|identity|ifM|join|lcm|liftA1|liftM1|map|max|mempty|min|mod|mul|negate|not|notEq|one|otherwise|recip|show|sub|top|unit|unless|unlessM|void|when|whenM|zero)\b/,operator:[Ye.languages.haskell.operator[0],Ye.languages.haskell.operator[2],/[\xa2-\xa6\xa8\xa9\xac\xae-\xb1\xb4\xb8\xd7\xf7\u02c2-\u02c5\u02d2-\u02df\u02e5-\u02eb\u02ed\u02ef-\u02ff\u0375\u0384\u0385\u03f6\u0482\u058d-\u058f\u0606-\u0608\u060b\u060e\u060f\u06de\u06e9\u06fd\u06fe\u07f6\u07fe\u07ff\u09f2\u09f3\u09fa\u09fb\u0af1\u0b70\u0bf3-\u0bfa\u0c7f\u0d4f\u0d79\u0e3f\u0f01-\u0f03\u0f13\u0f15-\u0f17\u0f1a-\u0f1f\u0f34\u0f36\u0f38\u0fbe-\u0fc5\u0fc7-\u0fcc\u0fce\u0fcf\u0fd5-\u0fd8\u109e\u109f\u1390-\u1399\u166d\u17db\u1940\u19de-\u19ff\u1b61-\u1b6a\u1b74-\u1b7c\u1fbd\u1fbf-\u1fc1\u1fcd-\u1fcf\u1fdd-\u1fdf\u1fed-\u1fef\u1ffd\u1ffe\u2044\u2052\u207a-\u207c\u208a-\u208c\u20a0-\u20bf\u2100\u2101\u2103-\u2106\u2108\u2109\u2114\u2116-\u2118\u211e-\u2123\u2125\u2127\u2129\u212e\u213a\u213b\u2140-\u2144\u214a-\u214d\u214f\u218a\u218b\u2190-\u2307\u230c-\u2328\u232b-\u2426\u2440-\u244a\u249c-\u24e9\u2500-\u2767\u2794-\u27c4\u27c7-\u27e5\u27f0-\u2982\u2999-\u29d7\u29dc-\u29fb\u29fe-\u2b73\u2b76-\u2b95\u2b97-\u2bff\u2ce5-\u2cea\u2e50\u2e51\u2e80-\u2e99\u2e9b-\u2ef3\u2f00-\u2fd5\u2ff0-\u2ffb\u3004\u3012\u3013\u3020\u3036\u3037\u303e\u303f\u309b\u309c\u3190\u3191\u3196-\u319f\u31c0-\u31e3\u3200-\u321e\u322a-\u3247\u3250\u3260-\u327f\u328a-\u32b0\u32c0-\u33ff\u4dc0-\u4dff\ua490-\ua4c6\ua700-\ua716\ua720\ua721\ua789\ua78a\ua828-\ua82b\ua836-\ua839\uaa77-\uaa79\uab5b\uab6a\uab6b\ufb29\ufbb2-\ufbc1\ufdfc\ufdfd\ufe62\ufe64-\ufe66\ufe69\uff04\uff0b\uff1c-\uff1e\uff3e\uff40\uff5c\uff5e\uffe0-\uffe6\uffe8-\uffee\ufffc\ufffd]/]}),Ye.languages.purs=Ye.languages.purescript}return purescript_1}var python_1,hasRequiredPython;function requirePython(){if(hasRequiredPython)return python_1;hasRequiredPython=1,python_1=e,e.displayName="python",e.aliases=["py"];function e(t){t.languages.python={comment:{pattern:/(^|[^\\])#.*/,lookbehind:!0,greedy:!0},"string-interpolation":{pattern:/(?:f|fr|rf)(?:("""|''')[\s\S]*?\1|("|')(?:\\.|(?!\2)[^\\\r\n])*\2)/i,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^{])(?:\{\{)*)\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}])+\})+\})+\}/,lookbehind:!0,inside:{"format-spec":{pattern:/(:)[^:(){}]+(?=\}$)/,lookbehind:!0},"conversion-option":{pattern:/![sra](?=[:}]$)/,alias:"punctuation"},rest:null}},string:/[\s\S]+/}},"triple-quoted-string":{pattern:/(?:[rub]|br|rb)?("""|''')[\s\S]*?\1/i,greedy:!0,alias:"string"},string:{pattern:/(?:[rub]|br|rb)?("|')(?:\\.|(?!\1)[^\\\r\n])*\1/i,greedy:!0},function:{pattern:/((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/g,lookbehind:!0},"class-name":{pattern:/(\bclass\s+)\w+/i,lookbehind:!0},decorator:{pattern:/(^[\t ]*)@\w+(?:\.\w+)*/m,lookbehind:!0,alias:["annotation","punctuation"],inside:{punctuation:/\./}},keyword:/\b(?:_(?=\s*:)|and|as|assert|async|await|break|case|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|match|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b/,builtin:/\b(?:__import__|abs|all|any|apply|ascii|basestring|bin|bool|buffer|bytearray|bytes|callable|chr|classmethod|cmp|coerce|compile|complex|delattr|dict|dir|divmod|enumerate|eval|execfile|file|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|intern|isinstance|issubclass|iter|len|list|locals|long|map|max|memoryview|min|next|object|oct|open|ord|pow|property|range|raw_input|reduce|reload|repr|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|unichr|unicode|vars|xrange|zip)\b/,boolean:/\b(?:False|None|True)\b/,number:/\b0(?:b(?:_?[01])+|o(?:_?[0-7])+|x(?:_?[a-f0-9])+)\b|(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)(?:e[+-]?\d+(?:_\d+)*)?j?(?!\w)/i,operator:/[-+%=]=?|!=|:=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,punctuation:/[{}[\];(),.:]/},t.languages.python["string-interpolation"].inside.interpolation.inside.rest=t.languages.python,t.languages.py=t.languages.python}return python_1}var q_1,hasRequiredQ;function requireQ(){if(hasRequiredQ)return q_1;hasRequiredQ=1,q_1=e,e.displayName="q",e.aliases=[];function e(t){t.languages.q={string:/"(?:\\.|[^"\\\r\n])*"/,comment:[{pattern:/([\t )\]}])\/.*/,lookbehind:!0,greedy:!0},{pattern:/(^|\r?\n|\r)\/[\t ]*(?:(?:\r?\n|\r)(?:.*(?:\r?\n|\r(?!\n)))*?(?:\\(?=[\t ]*(?:\r?\n|\r))|$)|\S.*)/,lookbehind:!0,greedy:!0},{pattern:/^\\[\t ]*(?:\r?\n|\r)[\s\S]+/m,greedy:!0},{pattern:/^#!.+/m,greedy:!0}],symbol:/`(?::\S+|[\w.]*)/,datetime:{pattern:/0N[mdzuvt]|0W[dtz]|\d{4}\.\d\d(?:m|\.\d\d(?:T(?:\d\d(?::\d\d(?::\d\d(?:[.:]\d\d\d)?)?)?)?)?[dz]?)|\d\d:\d\d(?::\d\d(?:[.:]\d\d\d)?)?[uvt]?/,alias:"number"},number:/\b(?![01]:)(?:0N[hje]?|0W[hj]?|0[wn]|0x[\da-fA-F]+|\d+(?:\.\d*)?(?:e[+-]?\d+)?[hjfeb]?)/,keyword:/\\\w+\b|\b(?:abs|acos|aj0?|all|and|any|asc|asin|asof|atan|attr|avgs?|binr?|by|ceiling|cols|cor|cos|count|cov|cross|csv|cut|delete|deltas|desc|dev|differ|distinct|div|do|dsave|ej|enlist|eval|except|exec|exit|exp|fby|fills|first|fkeys|flip|floor|from|get|getenv|group|gtime|hclose|hcount|hdel|hopen|hsym|iasc|identity|idesc|if|ij|in|insert|inter|inv|keys?|last|like|list|ljf?|load|log|lower|lsq|ltime|ltrim|mavg|maxs?|mcount|md5|mdev|med|meta|mins?|mmax|mmin|mmu|mod|msum|neg|next|not|null|or|over|parse|peach|pj|plist|prds?|prev|prior|rand|rank|ratios|raze|read0|read1|reciprocal|reval|reverse|rload|rotate|rsave|rtrim|save|scan|scov|sdev|select|set|setenv|show|signum|sin|sqrt|ssr?|string|sublist|sums?|sv|svar|system|tables|tan|til|trim|txf|type|uj|ungroup|union|update|upper|upsert|value|var|views?|vs|wavg|where|while|within|wj1?|wsum|ww|xasc|xbar|xcols?|xdesc|xexp|xgroup|xkey|xlog|xprev|xrank)\b/,adverb:{pattern:/['\/\\]:?|\beach\b/,alias:"function"},verb:{pattern:/(?:\B\.\B|\b[01]:|<[=>]?|>=?|[:+\-*%,!?~=|$&#@^]):?|\b_\b:?/,alias:"operator"},punctuation:/[(){}\[\];.]/}}return q_1}var qml_1,hasRequiredQml;function requireQml(){if(hasRequiredQml)return qml_1;hasRequiredQml=1,qml_1=e,e.displayName="qml",e.aliases=[];function e(t){(function(Ye){for(var tt=/"(?:\\.|[^\\"\r\n])*"|'(?:\\.|[^\\'\r\n])*'/.source,rt=/\/\/.*(?!.)|\/\*(?:[^*]|\*(?!\/))*\*\//.source,nt=/(?:[^\\()[\]{}"'/]|<string>|\/(?![*/])|<comment>|\(<expr>*\)|\[<expr>*\]|\{<expr>*\}|\\[\s\S])/.source.replace(/<string>/g,function(){return tt}).replace(/<comment>/g,function(){return rt}),at=0;at<2;at++)nt=nt.replace(/<expr>/g,function(){return nt});nt=nt.replace(/<expr>/g,"[^\\s\\S]"),Ye.languages.qml={comment:{pattern:/\/\/.*|\/\*[\s\S]*?\*\//,greedy:!0},"javascript-function":{pattern:RegExp(/((?:^|;)[ \t]*)function\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*\(<js>*\)\s*\{<js>*\}/.source.replace(/<js>/g,function(){return nt}),"m"),lookbehind:!0,greedy:!0,alias:"language-javascript",inside:Ye.languages.javascript},"class-name":{pattern:/((?:^|[:;])[ \t]*)(?!\d)\w+(?=[ \t]*\{|[ \t]+on\b)/m,lookbehind:!0},property:[{pattern:/((?:^|[;{])[ \t]*)(?!\d)\w+(?:\.\w+)*(?=[ \t]*:)/m,lookbehind:!0},{pattern:/((?:^|[;{])[ \t]*)property[ \t]+(?!\d)\w+(?:\.\w+)*[ \t]+(?!\d)\w+(?:\.\w+)*(?=[ \t]*:)/m,lookbehind:!0,inside:{keyword:/^property/,property:/\w+(?:\.\w+)*/}}],"javascript-expression":{pattern:RegExp(/(:[ \t]*)(?![\s;}[])(?:(?!$|[;}])<js>)+/.source.replace(/<js>/g,function(){return nt}),"m"),lookbehind:!0,greedy:!0,alias:"language-javascript",inside:Ye.languages.javascript},string:{pattern:/"(?:\\.|[^\\"\r\n])*"/,greedy:!0},keyword:/\b(?:as|import|on)\b/,punctuation:/[{}[\]:;,]/}})(t)}return qml_1}var qore_1,hasRequiredQore;function requireQore(){if(hasRequiredQore)return qore_1;hasRequiredQore=1,qore_1=e,e.displayName="qore",e.aliases=[];function e(t){t.languages.qore=t.languages.extend("clike",{comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:\/\/|#).*)/,lookbehind:!0},string:{pattern:/("|')(?:\\[\s\S]|(?!\1)[^\\])*\1/,greedy:!0},keyword:/\b(?:abstract|any|assert|binary|bool|boolean|break|byte|case|catch|char|class|code|const|continue|data|default|do|double|else|enum|extends|final|finally|float|for|goto|hash|if|implements|import|inherits|instanceof|int|interface|long|my|native|new|nothing|null|object|our|own|private|reference|rethrow|return|short|soft(?:bool|date|float|int|list|number|string)|static|strictfp|string|sub|super|switch|synchronized|this|throw|throws|transient|try|void|volatile|while)\b/,boolean:/\b(?:false|true)\b/i,function:/\$?\b(?!\d)\w+(?=\()/,number:/\b(?:0b[01]+|0x(?:[\da-f]*\.)?[\da-fp\-]+|(?:\d+(?:\.\d+)?|\.\d+)(?:e\d+)?[df]|(?:\d+(?:\.\d+)?|\.\d+))\b/i,operator:{pattern:/(^|[^.])(?:\+[+=]?|-[-=]?|[!=](?:==?|~)?|>>?=?|<(?:=>?|<=?)?|&[&=]?|\|[|=]?|[*\/%^]=?|[~?])/,lookbehind:!0},variable:/\$(?!\d)\w+\b/})}return qore_1}var qsharp_1,hasRequiredQsharp;function requireQsharp(){if(hasRequiredQsharp)return qsharp_1;hasRequiredQsharp=1,qsharp_1=e,e.displayName="qsharp",e.aliases=["qs"];function e(t){(function(Ye){function tt(Ut,Ht){return Ut.replace(/<<(\d+)>>/g,function(zt,Yt){return"(?:"+Ht[+Yt]+")"})}function rt(Ut,Ht,zt){return RegExp(tt(Ut,Ht),"")}function nt(Ut,Ht){for(var zt=0;zt<Ht;zt++)Ut=Ut.replace(/<<self>>/g,function(){return"(?:"+Ut+")"});return Ut.replace(/<<self>>/g,"[^\\s\\S]")}var at={type:"Adj BigInt Bool Ctl Double false Int One Pauli PauliI PauliX PauliY PauliZ Qubit Range Result String true Unit Zero",other:"Adjoint adjoint apply as auto body borrow borrowing Controlled controlled distribute elif else fail fixup for function if in internal intrinsic invert is let mutable namespace new newtype open operation repeat return self set until use using while within"};function it(Ut){return"\\b(?:"+Ut.trim().replace(/ /g,"|")+")\\b"}var ot=RegExp(it(at.type+" "+at.other)),ct=/\b[A-Za-z_]\w*\b/.source,At=tt(/<<0>>(?:\s*\.\s*<<0>>)*/.source,[ct]),Rt={keyword:ot,punctuation:/[<>()?,.:[\]]/},qt=/"(?:\\.|[^\\"])*"/.source;Ye.languages.qsharp=Ye.languages.extend("clike",{comment:/\/\/.*/,string:[{pattern:rt(/(^|[^$\\])<<0>>/.source,[qt]),lookbehind:!0,greedy:!0}],"class-name":[{pattern:rt(/(\b(?:as|open)\s+)<<0>>(?=\s*(?:;|as\b))/.source,[At]),lookbehind:!0,inside:Rt},{pattern:rt(/(\bnamespace\s+)<<0>>(?=\s*\{)/.source,[At]),lookbehind:!0,inside:Rt}],keyword:ot,number:/(?:\b0(?:x[\da-f]+|b[01]+|o[0-7]+)|(?:\B\.\d+|\b\d+(?:\.\d*)?)(?:e[-+]?\d+)?)l?\b/i,operator:/\band=|\bor=|\band\b|\bnot\b|\bor\b|<[-=]|[-=]>|>>>=?|<<<=?|\^\^\^=?|\|\|\|=?|&&&=?|w\/=?|~~~|[*\/+\-^=!%]=?/,punctuation:/::|[{}[\];(),.:]/}),Ye.languages.insertBefore("qsharp","number",{range:{pattern:/\.\./,alias:"operator"}});var Ft=nt(tt(/\{(?:[^"{}]|<<0>>|<<self>>)*\}/.source,[qt]),2);Ye.languages.insertBefore("qsharp","string",{"interpolation-string":{pattern:rt(/\$"(?:\\.|<<0>>|[^\\"{])*"/.source,[Ft]),greedy:!0,inside:{interpolation:{pattern:rt(/((?:^|[^\\])(?:\\\\)*)<<0>>/.source,[Ft]),lookbehind:!0,inside:{punctuation:/^\{|\}$/,expression:{pattern:/[\s\S]+/,alias:"language-qsharp",inside:Ye.languages.qsharp}}},string:/[\s\S]+/}}})})(t),t.languages.qs=t.languages.qsharp}return qsharp_1}var r_1,hasRequiredR;function requireR(){if(hasRequiredR)return r_1;hasRequiredR=1,r_1=e,e.displayName="r",e.aliases=[];function e(t){t.languages.r={comment:/#.*/,string:{pattern:/(['"])(?:\\.|(?!\1)[^\\\r\n])*\1/,greedy:!0},"percent-operator":{pattern:/%[^%\s]*%/,alias:"operator"},boolean:/\b(?:FALSE|TRUE)\b/,ellipsis:/\.\.(?:\.|\d+)/,number:[/\b(?:Inf|NaN)\b/,/(?:\b0x[\dA-Fa-f]+(?:\.\d*)?|\b\d+(?:\.\d*)?|\B\.\d+)(?:[EePp][+-]?\d+)?[iL]?/],keyword:/\b(?:NA|NA_character_|NA_complex_|NA_integer_|NA_real_|NULL|break|else|for|function|if|in|next|repeat|while)\b/,operator:/->?>?|<(?:=|<?-)?|[>=!]=?|::?|&&?|\|\|?|[+*\/^$@~]/,punctuation:/[(){}\[\],;]/}}return r_1}var racket_1,hasRequiredRacket;function requireRacket(){if(hasRequiredRacket)return racket_1;hasRequiredRacket=1;var e=requireScheme();racket_1=t,t.displayName="racket",t.aliases=["rkt"];function t(Ye){Ye.register(e),Ye.languages.racket=Ye.languages.extend("scheme",{"lambda-parameter":{pattern:/([(\[]lambda\s+[(\[])[^()\[\]'\s]+/,lookbehind:!0}}),Ye.languages.insertBefore("racket","string",{lang:{pattern:/^#lang.+/m,greedy:!0,alias:"keyword"}}),Ye.languages.rkt=Ye.languages.racket}return racket_1}var reason_1,hasRequiredReason;function requireReason(){if(hasRequiredReason)return reason_1;hasRequiredReason=1,reason_1=e,e.displayName="reason",e.aliases=[];function e(t){t.languages.reason=t.languages.extend("clike",{string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^\\\r\n"])*"/,greedy:!0},"class-name":/\b[A-Z]\w*/,keyword:/\b(?:and|as|assert|begin|class|constraint|do|done|downto|else|end|exception|external|for|fun|function|functor|if|in|include|inherit|initializer|lazy|let|method|module|mutable|new|nonrec|object|of|open|or|private|rec|sig|struct|switch|then|to|try|type|val|virtual|when|while|with)\b/,operator:/\.{3}|:[:=]|\|>|->|=(?:==?|>)?|<=?|>=?|[|^?'#!~`]|[+\-*\/]\.?|\b(?:asr|land|lor|lsl|lsr|lxor|mod)\b/}),t.languages.insertBefore("reason","class-name",{char:{pattern:/'(?:\\x[\da-f]{2}|\\o[0-3][0-7][0-7]|\\\d{3}|\\.|[^'\\\r\n])'/,greedy:!0},constructor:/\b[A-Z]\w*\b(?!\s*\.)/,label:{pattern:/\b[a-z]\w*(?=::)/,alias:"symbol"}}),delete t.languages.reason.function}return reason_1}var regex_1,hasRequiredRegex;function requireRegex(){if(hasRequiredRegex)return regex_1;hasRequiredRegex=1,regex_1=e,e.displayName="regex",e.aliases=[];function e(t){(function(Ye){var tt={pattern:/\\[\\(){}[\]^$+*?|.]/,alias:"escape"},rt=/\\(?:x[\da-fA-F]{2}|u[\da-fA-F]{4}|u\{[\da-fA-F]+\}|0[0-7]{0,2}|[123][0-7]{2}|c[a-zA-Z]|.)/,nt={pattern:/\.|\\[wsd]|\\p\{[^{}]+\}/i,alias:"class-name"},at={pattern:/\\[wsd]|\\p\{[^{}]+\}/i,alias:"class-name"},it="(?:[^\\\\-]|"+rt.source+")",ot=RegExp(it+"-"+it),ct={pattern:/(<|')[^<>']+(?=[>']$)/,lookbehind:!0,alias:"variable"};Ye.languages.regex={"char-class":{pattern:/((?:^|[^\\])(?:\\\\)*)\[(?:[^\\\]]|\\[\s\S])*\]/,lookbehind:!0,inside:{"char-class-negation":{pattern:/(^\[)\^/,lookbehind:!0,alias:"operator"},"char-class-punctuation":{pattern:/^\[|\]$/,alias:"punctuation"},range:{pattern:ot,inside:{escape:rt,"range-punctuation":{pattern:/-/,alias:"operator"}}},"special-escape":tt,"char-set":at,escape:rt}},"special-escape":tt,"char-set":nt,backreference:[{pattern:/\\(?![123][0-7]{2})[1-9]/,alias:"keyword"},{pattern:/\\k<[^<>']+>/,alias:"keyword",inside:{"group-name":ct}}],anchor:{pattern:/[$^]|\\[ABbGZz]/,alias:"function"},escape:rt,group:[{pattern:/\((?:\?(?:<[^<>']+>|'[^<>']+'|[>:]|<?[=!]|[idmnsuxU]+(?:-[idmnsuxU]+)?:?))?/,alias:"punctuation",inside:{"group-name":ct}},{pattern:/\)/,alias:"punctuation"}],quantifier:{pattern:/(?:[+*?]|\{\d+(?:,\d*)?\})[?+]?/,alias:"number"},alternation:{pattern:/\|/,alias:"keyword"}}})(t)}return regex_1}var rego_1,hasRequiredRego;function requireRego(){if(hasRequiredRego)return rego_1;hasRequiredRego=1,rego_1=e,e.displayName="rego",e.aliases=[];function e(t){t.languages.rego={comment:/#.*/,property:{pattern:/(^|[^\\.])(?:"(?:\\.|[^\\"\r\n])*"|`[^`]*`|\b[a-z_]\w*\b)(?=\s*:(?!=))/i,lookbehind:!0,greedy:!0},string:{pattern:/(^|[^\\])"(?:\\.|[^\\"\r\n])*"|`[^`]*`/,lookbehind:!0,greedy:!0},keyword:/\b(?:as|default|else|import|not|null|package|set(?=\s*\()|some|with)\b/,boolean:/\b(?:false|true)\b/,function:{pattern:/\b[a-z_]\w*\b(?:\s*\.\s*\b[a-z_]\w*\b)*(?=\s*\()/i,inside:{namespace:/\b\w+\b(?=\s*\.)/,punctuation:/\./}},number:/-?\b\d+(?:\.\d+)?(?:e[+-]?\d+)?\b/i,operator:/[-+*/%|&]|[<>:=]=?|!=|\b_\b/,punctuation:/[,;.\[\]{}()]/}}return rego_1}var renpy_1,hasRequiredRenpy;function requireRenpy(){if(hasRequiredRenpy)return renpy_1;hasRequiredRenpy=1,renpy_1=e,e.displayName="renpy",e.aliases=["rpy"];function e(t){t.languages.renpy={comment:{pattern:/(^|[^\\])#.+/,lookbehind:!0},string:{pattern:/("""|''')[\s\S]+?\1|("|')(?:\\.|(?!\2)[^\\])*\2|(?:^#?(?:(?:[0-9a-fA-F]){3}|[0-9a-fA-F]{6})$)/m,greedy:!0},function:/\b[a-z_]\w*(?=\()/i,property:/\b(?:Update|UpdateVersion|action|activate_sound|adv_nvl_transition|after_load_transition|align|alpha|alt|anchor|antialias|area|auto|background|bar_invert|bar_resizing|bar_vertical|black_color|bold|bottom_bar|bottom_gutter|bottom_margin|bottom_padding|box_reverse|box_wrap|can_update|caret|child|color|crop|default_afm_enable|default_afm_time|default_fullscreen|default_text_cps|developer|directory_name|drag_handle|drag_joined|drag_name|drag_raise|draggable|dragged|drop_shadow|drop_shadow_color|droppable|dropped|easein|easeout|edgescroll|end_game_transition|end_splash_transition|enter_replay_transition|enter_sound|enter_transition|enter_yesno_transition|executable_name|exit_replay_transition|exit_sound|exit_transition|exit_yesno_transition|fadein|fadeout|first_indent|first_spacing|fit_first|focus|focus_mask|font|foreground|game_main_transition|get_installed_packages|google_play_key|google_play_salt|ground|has_music|has_sound|has_voice|height|help|hinting|hover|hover_background|hover_color|hover_sound|hovered|hyperlink_functions|idle|idle_color|image_style|include_update|insensitive|insensitive_background|insensitive_color|inside|intra_transition|italic|justify|kerning|keyboard_focus|language|layer_clipping|layers|layout|left_bar|left_gutter|left_margin|left_padding|length|line_leading|line_overlap_split|line_spacing|linear|main_game_transition|main_menu_music|maximum|min_width|minimum|minwidth|modal|mouse|mousewheel|name|narrator_menu|newline_indent|nvl_adv_transition|offset|order_reverse|outlines|overlay_functions|pos|position|prefix|radius|range|rest_indent|right_bar|right_gutter|right_margin|right_padding|rotate|rotate_pad|ruby_style|sample_sound|save_directory|say_attribute_transition|screen_height|screen_width|scrollbars|selected_hover|selected_hover_color|selected_idle|selected_idle_color|selected_insensitive|show_side_image|show_two_window|side_spacing|side_xpos|side_ypos|size|size_group|slow_cps|slow_cps_multiplier|spacing|strikethrough|subpixel|text_align|text_style|text_xpos|text_y_fudge|text_ypos|thumb|thumb_offset|thumb_shadow|thumbnail_height|thumbnail_width|time|top_bar|top_gutter|top_margin|top_padding|translations|underline|unscrollable|update|value|version|version_name|version_tuple|vertical|width|window_hide_transition|window_icon|window_left_padding|window_show_transition|window_title|windows_icon|xadjustment|xalign|xanchor|xanchoraround|xaround|xcenter|xfill|xinitial|xmargin|xmaximum|xminimum|xoffset|xofsset|xpadding|xpos|xsize|xzoom|yadjustment|yalign|yanchor|yanchoraround|yaround|ycenter|yfill|yinitial|ymargin|ymaximum|yminimum|yoffset|ypadding|ypos|ysize|ysizexysize|yzoom|zoom|zorder)\b/,tag:/\b(?:bar|block|button|buttoscreenn|drag|draggroup|fixed|frame|grid|[hv]box|hotbar|hotspot|image|imagebutton|imagemap|input|key|label|menu|mm_menu_frame|mousearea|nvl|parallel|screen|self|side|tag|text|textbutton|timer|vbar|viewport|window)\b|\$/,keyword:/\b(?:None|add|adjustment|alignaround|allow|angle|animation|around|as|assert|behind|box_layout|break|build|cache|call|center|changed|child_size|choice|circles|class|clear|clicked|clipping|clockwise|config|contains|continue|corner1|corner2|counterclockwise|def|default|define|del|delay|disabled|disabled_text|dissolve|elif|else|event|except|exclude|exec|expression|fade|finally|for|from|function|global|gm_root|has|hide|id|if|import|in|init|is|jump|knot|lambda|left|less_rounded|mm_root|movie|music|null|on|onlayer|pass|pause|persistent|play|print|python|queue|raise|random|renpy|repeat|return|right|rounded_window|scene|scope|set|show|slow|slow_abortable|slow_done|sound|stop|store|style|style_group|substitute|suffix|theme|transform|transform_anchor|transpose|try|ui|unhovered|updater|use|voice|while|widget|widget_hover|widget_selected|widget_text|yield)\b/,boolean:/\b(?:[Ff]alse|[Tt]rue)\b/,number:/(?:\b(?:0[bo])?(?:(?:\d|0x[\da-f])[\da-f]*(?:\.\d*)?)|\B\.\d+)(?:e[+-]?\d+)?j?/i,operator:/[-+%=]=?|!=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]|\b(?:and|at|not|or|with)\b/,punctuation:/[{}[\];(),.:]/},t.languages.rpy=t.languages.renpy}return renpy_1}var rest_1,hasRequiredRest;function requireRest(){if(hasRequiredRest)return rest_1;hasRequiredRest=1,rest_1=e,e.displayName="rest",e.aliases=[];function e(t){t.languages.rest={table:[{pattern:/(^[\t ]*)(?:\+[=-]+)+\+(?:\r?\n|\r)(?:\1[+|].+[+|](?:\r?\n|\r))+\1(?:\+[=-]+)+\+/m,lookbehind:!0,inside:{punctuation:/\||(?:\+[=-]+)+\+/}},{pattern:/(^[\t ]*)=+ [ =]*=(?:(?:\r?\n|\r)\1.+)+(?:\r?\n|\r)\1=+ [ =]*=(?=(?:\r?\n|\r){2}|\s*$)/m,lookbehind:!0,inside:{punctuation:/[=-]+/}}],"substitution-def":{pattern:/(^[\t ]*\.\. )\|(?:[^|\s](?:[^|]*[^|\s])?)\| [^:]+::/m,lookbehind:!0,inside:{substitution:{pattern:/^\|(?:[^|\s]|[^|\s][^|]*[^|\s])\|/,alias:"attr-value",inside:{punctuation:/^\||\|$/}},directive:{pattern:/( )(?! )[^:]+::/,lookbehind:!0,alias:"function",inside:{punctuation:/::$/}}}},"link-target":[{pattern:/(^[\t ]*\.\. )\[[^\]]+\]/m,lookbehind:!0,alias:"string",inside:{punctuation:/^\[|\]$/}},{pattern:/(^[\t ]*\.\. )_(?:`[^`]+`|(?:[^:\\]|\\.)+):/m,lookbehind:!0,alias:"string",inside:{punctuation:/^_|:$/}}],directive:{pattern:/(^[\t ]*\.\. )[^:]+::/m,lookbehind:!0,alias:"function",inside:{punctuation:/::$/}},comment:{pattern:/(^[\t ]*\.\.)(?:(?: .+)?(?:(?:\r?\n|\r).+)+| .+)(?=(?:\r?\n|\r){2}|$)/m,lookbehind:!0},title:[{pattern:/^(([!"#$%&'()*+,\-.\/:;<=>?@\[\\\]^_`{|}~])\2+)(?:\r?\n|\r).+(?:\r?\n|\r)\1$/m,inside:{punctuation:/^[!"#$%&'()*+,\-.\/:;<=>?@\[\\\]^_`{|}~]+|[!"#$%&'()*+,\-.\/:;<=>?@\[\\\]^_`{|}~]+$/,important:/.+/}},{pattern:/(^|(?:\r?\n|\r){2}).+(?:\r?\n|\r)([!"#$%&'()*+,\-.\/:;<=>?@\[\\\]^_`{|}~])\2+(?=\r?\n|\r|$)/,lookbehind:!0,inside:{punctuation:/[!"#$%&'()*+,\-.\/:;<=>?@\[\\\]^_`{|}~]+$/,important:/.+/}}],hr:{pattern:/((?:\r?\n|\r){2})([!"#$%&'()*+,\-.\/:;<=>?@\[\\\]^_`{|}~])\2{3,}(?=(?:\r?\n|\r){2})/,lookbehind:!0,alias:"punctuation"},field:{pattern:/(^[\t ]*):[^:\r\n]+:(?= )/m,lookbehind:!0,alias:"attr-name"},"command-line-option":{pattern:/(^[\t ]*)(?:[+-][a-z\d]|(?:--|\/)[a-z\d-]+)(?:[ =](?:[a-z][\w-]*|<[^<>]+>))?(?:, (?:[+-][a-z\d]|(?:--|\/)[a-z\d-]+)(?:[ =](?:[a-z][\w-]*|<[^<>]+>))?)*(?=(?:\r?\n|\r)? {2,}\S)/im,lookbehind:!0,alias:"symbol"},"literal-block":{pattern:/::(?:\r?\n|\r){2}([ \t]+)(?![ \t]).+(?:(?:\r?\n|\r)\1.+)*/,inside:{"literal-block-punctuation":{pattern:/^::/,alias:"punctuation"}}},"quoted-literal-block":{pattern:/::(?:\r?\n|\r){2}([!"#$%&'()*+,\-.\/:;<=>?@\[\\\]^_`{|}~]).*(?:(?:\r?\n|\r)\1.*)*/,inside:{"literal-block-punctuation":{pattern:/^(?:::|([!"#$%&'()*+,\-.\/:;<=>?@\[\\\]^_`{|}~])\1*)/m,alias:"punctuation"}}},"list-bullet":{pattern:/(^[\t ]*)(?:[*+\-•‣⁃]|\(?(?:\d+|[a-z]|[ivxdclm]+)\)|(?:\d+|[a-z]|[ivxdclm]+)\.)(?= )/im,lookbehind:!0,alias:"punctuation"},"doctest-block":{pattern:/(^[\t ]*)>>> .+(?:(?:\r?\n|\r).+)*/m,lookbehind:!0,inside:{punctuation:/^>>>/}},inline:[{pattern:/(^|[\s\-:\/'"<(\[{])(?::[^:]+:`.*?`|`.*?`:[^:]+:|(\*\*?|``?|\|)(?!\s)(?:(?!\2).)*\S\2(?=[\s\-.,:;!?\\\/'")\]}]|$))/m,lookbehind:!0,inside:{bold:{pattern:/(^\*\*).+(?=\*\*$)/,lookbehind:!0},italic:{pattern:/(^\*).+(?=\*$)/,lookbehind:!0},"inline-literal":{pattern:/(^``).+(?=``$)/,lookbehind:!0,alias:"symbol"},role:{pattern:/^:[^:]+:|:[^:]+:$/,alias:"function",inside:{punctuation:/^:|:$/}},"interpreted-text":{pattern:/(^`).+(?=`$)/,lookbehind:!0,alias:"attr-value"},substitution:{pattern:/(^\|).+(?=\|$)/,lookbehind:!0,alias:"attr-value"},punctuation:/\*\*?|``?|\|/}}],link:[{pattern:/\[[^\[\]]+\]_(?=[\s\-.,:;!?\\\/'")\]}]|$)/,alias:"string",inside:{punctuation:/^\[|\]_$/}},{pattern:/(?:\b[a-z\d]+(?:[_.:+][a-z\d]+)*_?_|`[^`]+`_?_|_`[^`]+`)(?=[\s\-.,:;!?\\\/'")\]}]|$)/i,alias:"string",inside:{punctuation:/^_?`|`$|`?_?_$/}}],punctuation:{pattern:/(^[\t ]*)(?:\|(?= |$)|(?:---?|—|\.\.|__)(?= )|\.\.$)/m,lookbehind:!0}}}return rest_1}var rip_1,hasRequiredRip;function requireRip(){if(hasRequiredRip)return rip_1;hasRequiredRip=1,rip_1=e,e.displayName="rip",e.aliases=[];function e(t){t.languages.rip={comment:{pattern:/#.*/,greedy:!0},char:{pattern:/\B`[^\s`'",.:;#\/\\()<>\[\]{}]\b/,greedy:!0},string:{pattern:/("|')(?:\\.|(?!\1)[^\\\r\n])*\1/,greedy:!0},regex:{pattern:/(^|[^/])\/(?!\/)(?:\[[^\n\r\]]*\]|\\.|[^/\\\r\n\[])+\/(?=\s*(?:$|[\r\n,.;})]))/,lookbehind:!0,greedy:!0},keyword:/(?:=>|->)|\b(?:case|catch|class|else|exit|finally|if|raise|return|switch|try)\b/,builtin:/@|\bSystem\b/,boolean:/\b(?:false|true)\b/,date:/\b\d{4}-\d{2}-\d{2}\b/,time:/\b\d{2}:\d{2}:\d{2}\b/,datetime:/\b\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}\b/,symbol:/:[^\d\s`'",.:;#\/\\()<>\[\]{}][^\s`'",.:;#\/\\()<>\[\]{}]*/,number:/[+-]?\b(?:\d+\.\d+|\d+)\b/,punctuation:/(?:\.{2,3})|[`,.:;=\/\\()<>\[\]{}]/,reference:/[^\d\s`'",.:;#\/\\()<>\[\]{}][^\s`'",.:;#\/\\()<>\[\]{}]*/}}return rip_1}var roboconf_1,hasRequiredRoboconf;function requireRoboconf(){if(hasRequiredRoboconf)return roboconf_1;hasRequiredRoboconf=1,roboconf_1=e,e.displayName="roboconf",e.aliases=[];function e(t){t.languages.roboconf={comment:/#.*/,keyword:{pattern:/(^|\s)(?:(?:external|import)\b|(?:facet|instance of)(?=[ \t]+[\w-]+[ \t]*\{))/,lookbehind:!0},component:{pattern:/[\w-]+(?=[ \t]*\{)/,alias:"variable"},property:/[\w.-]+(?=[ \t]*:)/,value:{pattern:/(=[ \t]*(?![ \t]))[^,;]+/,lookbehind:!0,alias:"attr-value"},optional:{pattern:/\(optional\)/,alias:"builtin"},wildcard:{pattern:/(\.)\*/,lookbehind:!0,alias:"operator"},punctuation:/[{},.;:=]/}}return roboconf_1}var robotframework_1,hasRequiredRobotframework;function requireRobotframework(){if(hasRequiredRobotframework)return robotframework_1;hasRequiredRobotframework=1,robotframework_1=e,e.displayName="robotframework",e.aliases=[];function e(t){(function(Ye){var tt={pattern:/(^[ \t]*| {2}|\t)#.*/m,lookbehind:!0,greedy:!0},rt={pattern:/((?:^|[^\\])(?:\\{2})*)[$@&%]\{(?:[^{}\r\n]|\{[^{}\r\n]*\})*\}/,lookbehind:!0,inside:{punctuation:/^[$@&%]\{|\}$/}};function nt(ct,At){var Rt={};Rt["section-header"]={pattern:/^ ?\*{3}.+?\*{3}/,alias:"keyword"};for(var qt in At)Rt[qt]=At[qt];return Rt.tag={pattern:/([\r\n](?: {2}|\t)[ \t]*)\[[-\w]+\]/,lookbehind:!0,inside:{punctuation:/\[|\]/}},Rt.variable=rt,Rt.comment=tt,{pattern:RegExp(/^ ?\*{3}[ \t]*<name>[ \t]*\*{3}(?:.|[\r\n](?!\*{3}))*/.source.replace(/<name>/g,function(){return ct}),"im"),alias:"section",inside:Rt}}var at={pattern:/(\[Documentation\](?: {2}|\t)[ \t]*)(?![ \t]|#)(?:.|(?:\r\n?|\n)[ \t]*\.{3})+/,lookbehind:!0,alias:"string"},it={pattern:/([\r\n] ?)(?!#)(?:\S(?:[ \t]\S)*)+/,lookbehind:!0,alias:"function",inside:{variable:rt}},ot={pattern:/([\r\n](?: {2}|\t)[ \t]*)(?!\[|\.{3}|#)(?:\S(?:[ \t]\S)*)+/,lookbehind:!0,inside:{variable:rt}};Ye.languages.robotframework={settings:nt("Settings",{documentation:{pattern:/([\r\n] ?Documentation(?: {2}|\t)[ \t]*)(?![ \t]|#)(?:.|(?:\r\n?|\n)[ \t]*\.{3})+/,lookbehind:!0,alias:"string"},property:{pattern:/([\r\n] ?)(?!\.{3}|#)(?:\S(?:[ \t]\S)*)+/,lookbehind:!0}}),variables:nt("Variables"),"test-cases":nt("Test Cases",{"test-name":it,documentation:at,property:ot}),keywords:nt("Keywords",{"keyword-name":it,documentation:at,property:ot}),tasks:nt("Tasks",{"task-name":it,documentation:at,property:ot}),comment:tt},Ye.languages.robot=Ye.languages.robotframework})(t)}return robotframework_1}var rust_1,hasRequiredRust;function requireRust(){if(hasRequiredRust)return rust_1;hasRequiredRust=1,rust_1=e,e.displayName="rust",e.aliases=[];function e(t){(function(Ye){for(var tt=/\/\*(?:[^*/]|\*(?!\/)|\/(?!\*)|<self>)*\*\//.source,rt=0;rt<2;rt++)tt=tt.replace(/<self>/g,function(){return tt});tt=tt.replace(/<self>/g,function(){return/[^\s\S]/.source}),Ye.languages.rust={comment:[{pattern:RegExp(/(^|[^\\])/.source+tt),lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/b?"(?:\\[\s\S]|[^\\"])*"|b?r(#*)"(?:[^"]|"(?!\1))*"\1/,greedy:!0},char:{pattern:/b?'(?:\\(?:x[0-7][\da-fA-F]|u\{(?:[\da-fA-F]_*){1,6}\}|.)|[^\\\r\n\t'])'/,greedy:!0},attribute:{pattern:/#!?\[(?:[^\[\]"]|"(?:\\[\s\S]|[^\\"])*")*\]/,greedy:!0,alias:"attr-name",inside:{string:null}},"closure-params":{pattern:/([=(,:]\s*|\bmove\s*)\|[^|]*\||\|[^|]*\|(?=\s*(?:\{|->))/,lookbehind:!0,greedy:!0,inside:{"closure-punctuation":{pattern:/^\||\|$/,alias:"punctuation"},rest:null}},"lifetime-annotation":{pattern:/'\w+/,alias:"symbol"},"fragment-specifier":{pattern:/(\$\w+:)[a-z]+/,lookbehind:!0,alias:"punctuation"},variable:/\$\w+/,"function-definition":{pattern:/(\bfn\s+)\w+/,lookbehind:!0,alias:"function"},"type-definition":{pattern:/(\b(?:enum|struct|trait|type|union)\s+)\w+/,lookbehind:!0,alias:"class-name"},"module-declaration":[{pattern:/(\b(?:crate|mod)\s+)[a-z][a-z_\d]*/,lookbehind:!0,alias:"namespace"},{pattern:/(\b(?:crate|self|super)\s*)::\s*[a-z][a-z_\d]*\b(?:\s*::(?:\s*[a-z][a-z_\d]*\s*::)*)?/,lookbehind:!0,alias:"namespace",inside:{punctuation:/::/}}],keyword:[/\b(?:Self|abstract|as|async|await|become|box|break|const|continue|crate|do|dyn|else|enum|extern|final|fn|for|if|impl|in|let|loop|macro|match|mod|move|mut|override|priv|pub|ref|return|self|static|struct|super|trait|try|type|typeof|union|unsafe|unsized|use|virtual|where|while|yield)\b/,/\b(?:bool|char|f(?:32|64)|[ui](?:8|16|32|64|128|size)|str)\b/],function:/\b[a-z_]\w*(?=\s*(?:::\s*<|\())/,macro:{pattern:/\b\w+!/,alias:"property"},constant:/\b[A-Z_][A-Z_\d]+\b/,"class-name":/\b[A-Z]\w*\b/,namespace:{pattern:/(?:\b[a-z][a-z_\d]*\s*::\s*)*\b[a-z][a-z_\d]*\s*::(?!\s*<)/,inside:{punctuation:/::/}},number:/\b(?:0x[\dA-Fa-f](?:_?[\dA-Fa-f])*|0o[0-7](?:_?[0-7])*|0b[01](?:_?[01])*|(?:(?:\d(?:_?\d)*)?\.)?\d(?:_?\d)*(?:[Ee][+-]?\d+)?)(?:_?(?:f32|f64|[iu](?:8|16|32|64|size)?))?\b/,boolean:/\b(?:false|true)\b/,punctuation:/->|\.\.=|\.{1,3}|::|[{}[\];(),:]/,operator:/[-+*\/%!^]=?|=[=>]?|&[&=]?|\|[|=]?|<<?=?|>>?=?|[@?]/},Ye.languages.rust["closure-params"].inside.rest=Ye.languages.rust,Ye.languages.rust.attribute.inside.string=Ye.languages.rust.string})(t)}return rust_1}var sas_1,hasRequiredSas;function requireSas(){if(hasRequiredSas)return sas_1;hasRequiredSas=1,sas_1=e,e.displayName="sas",e.aliases=[];function e(t){(function(Ye){var tt=/(?:"(?:""|[^"])*"(?!")|'(?:''|[^'])*'(?!'))/.source,rt=/\b(?:\d[\da-f]*x|\d+(?:\.\d+)?(?:e[+-]?\d+)?)\b/i,nt={pattern:RegExp(tt+"[bx]"),alias:"number"},at={pattern:/&[a-z_]\w*/i},it={pattern:/((?:^|\s|=|\())%(?:ABORT|BY|CMS|COPY|DISPLAY|DO|ELSE|END|EVAL|GLOBAL|GO|GOTO|IF|INC|INCLUDE|INDEX|INPUT|KTRIM|LENGTH|LET|LIST|LOCAL|PUT|QKTRIM|QSCAN|QSUBSTR|QSYSFUNC|QUPCASE|RETURN|RUN|SCAN|SUBSTR|SUPERQ|SYMDEL|SYMEXIST|SYMGLOBL|SYMLOCAL|SYSCALL|SYSEVALF|SYSEXEC|SYSFUNC|SYSGET|SYSRPUT|THEN|TO|TSO|UNQUOTE|UNTIL|UPCASE|WHILE|WINDOW)\b/i,lookbehind:!0,alias:"keyword"},ot={pattern:/(^|\s)(?:proc\s+\w+|data(?!=)|quit|run)\b/i,alias:"keyword",lookbehind:!0},ct=[/\/\*[\s\S]*?\*\//,{pattern:/(^[ \t]*|;\s*)\*[^;]*;/m,lookbehind:!0}],At={pattern:RegExp(tt),greedy:!0},Rt=/[$%@.(){}\[\];,\\]/,qt={pattern:/%?\b\w+(?=\()/,alias:"keyword"},Ft={function:qt,"arg-value":{pattern:/(=\s*)[A-Z\.]+/i,lookbehind:!0},operator:/=/,"macro-variable":at,arg:{pattern:/[A-Z]+/i,alias:"keyword"},number:rt,"numeric-constant":nt,punctuation:Rt,string:At},Ut={pattern:/\b(?:format|put)\b=?[\w'$.]+/i,inside:{keyword:/^(?:format|put)(?==)/i,equals:/=/,format:{pattern:/(?:\w|\$\d)+\.\d?/,alias:"number"}}},Ht={pattern:/\b(?:format|put)\s+[\w']+(?:\s+[$.\w]+)+(?=;)/i,inside:{keyword:/^(?:format|put)/i,format:{pattern:/[\w$]+\.\d?/,alias:"number"}}},zt={pattern:/((?:^|\s)=?)(?:catname|checkpoint execute_always|dm|endsas|filename|footnote|%include|libname|%list|lock|missing|options|page|resetline|%run|sasfile|skip|sysecho|title\d?)\b/i,lookbehind:!0,alias:"keyword"},Yt={pattern:/(^|\s)(?:submit(?:\s+(?:load|norun|parseonly))?|endsubmit)\b/i,lookbehind:!0,alias:"keyword"},Gt=/aStore|accessControl|aggregation|audio|autotune|bayesianNetClassifier|bioMedImage|boolRule|builtins|cardinality|cdm|clustering|conditionalRandomFields|configuration|copula|countreg|dataDiscovery|dataPreprocess|dataSciencePilot|dataStep|decisionTree|deduplication|deepLearn|deepNeural|deepRnn|ds2|ecm|entityRes|espCluster|explainModel|factmac|fastKnn|fcmpact|fedSql|freqTab|gVarCluster|gam|gleam|graphSemiSupLearn|hiddenMarkovModel|hyperGroup|ica|image|iml|kernalPca|langModel|ldaTopic|loadStreams|mbc|mixed|mlTools|modelPublishing|network|neuralNet|nmf|nonParametricBayes|nonlinear|optNetwork|optimization|panel|pca|percentile|phreg|pls|qkb|qlim|quantreg|recommend|regression|reinforcementLearn|robustPca|ruleMining|sampling|sandwich|sccasl|search(?:Analytics)?|sentimentAnalysis|sequence|session(?:Prop)?|severity|simSystem|simple|smartData|sparkEmbeddedProcess|sparseML|spatialreg|spc|stabilityMonitoring|svDataDescription|svm|table|text(?:Filters|Frequency|Mining|Parse|Rule(?:Develop|Score)|Topic|Util)|timeData|transpose|tsInfo|tsReconcile|uniTimeSeries|varReduce/.source,Vt={pattern:RegExp(/(^|\s)(?:action\s+)?(?:<act>)\.[a-z]+\b[^;]+/.source.replace(/<act>/g,function(){return Gt}),"i"),lookbehind:!0,inside:{keyword:RegExp(/(?:<act>)\.[a-z]+\b/.source.replace(/<act>/g,function(){return Gt}),"i"),action:{pattern:/(?:action)/i,alias:"keyword"},comment:ct,function:qt,"arg-value":Ft["arg-value"],operator:Ft.operator,argument:Ft.arg,number:rt,"numeric-constant":nt,punctuation:Rt,string:At}},Zt={pattern:/((?:^|\s)=?)(?:after|analysis|and|array|barchart|barwidth|begingraph|by|call|cas|cbarline|cfill|class(?:lev)?|close|column|computed?|contains|continue|data(?==)|define|delete|describe|document|do\s+over|do|dol|drop|dul|else|end(?:comp|source)?|entryTitle|eval(?:uate)?|exec(?:ute)?|exit|file(?:name)?|fill(?:attrs)?|flist|fnc|function(?:list)?|global|goto|group(?:by)?|headline|headskip|histogram|if|infile|keep|keylabel|keyword|label|layout|leave|legendlabel|length|libname|loadactionset|merge|midpoints|_?null_|name|noobs|nowd|ods|options|or|otherwise|out(?:put)?|over(?:lay)?|plot|print|put|raise|ranexp|rannor|rbreak|retain|return|select|session|sessref|set|source|statgraph|sum|summarize|table|temp|terminate|then\s+do|then|title\d?|to|var|when|where|xaxisopts|y2axisopts|yaxisopts)\b/i,lookbehind:!0};Ye.languages.sas={datalines:{pattern:/^([ \t]*)(?:cards|(?:data)?lines);[\s\S]+?^[ \t]*;/im,lookbehind:!0,alias:"string",inside:{keyword:{pattern:/^(?:cards|(?:data)?lines)/i},punctuation:/;/}},"proc-sql":{pattern:/(^proc\s+(?:fed)?sql(?:\s+[\w|=]+)?;)[\s\S]+?(?=^(?:proc\s+\w+|data|quit|run);|(?![\s\S]))/im,lookbehind:!0,inside:{sql:{pattern:RegExp(/^[ \t]*(?:select|alter\s+table|(?:create|describe|drop)\s+(?:index|table(?:\s+constraints)?|view)|create\s+unique\s+index|insert\s+into|update)(?:<str>|[^;"'])+;/.source.replace(/<str>/g,function(){return tt}),"im"),alias:"language-sql",inside:Ye.languages.sql},"global-statements":zt,"sql-statements":{pattern:/(^|\s)(?:disconnect\s+from|begin|commit|exec(?:ute)?|reset|rollback|validate)\b/i,lookbehind:!0,alias:"keyword"},number:rt,"numeric-constant":nt,punctuation:Rt,string:At}},"proc-groovy":{pattern:/(^proc\s+groovy(?:\s+[\w|=]+)?;)[\s\S]+?(?=^(?:proc\s+\w+|data|quit|run);|(?![\s\S]))/im,lookbehind:!0,inside:{comment:ct,groovy:{pattern:RegExp(/(^[ \t]*submit(?:\s+(?:load|norun|parseonly))?)(?:<str>|[^"'])+?(?=endsubmit;)/.source.replace(/<str>/g,function(){return tt}),"im"),lookbehind:!0,alias:"language-groovy",inside:Ye.languages.groovy},keyword:Zt,"submit-statement":Yt,"global-statements":zt,number:rt,"numeric-constant":nt,punctuation:Rt,string:At}},"proc-lua":{pattern:/(^proc\s+lua(?:\s+[\w|=]+)?;)[\s\S]+?(?=^(?:proc\s+\w+|data|quit|run);|(?![\s\S]))/im,lookbehind:!0,inside:{comment:ct,lua:{pattern:RegExp(/(^[ \t]*submit(?:\s+(?:load|norun|parseonly))?)(?:<str>|[^"'])+?(?=endsubmit;)/.source.replace(/<str>/g,function(){return tt}),"im"),lookbehind:!0,alias:"language-lua",inside:Ye.languages.lua},keyword:Zt,"submit-statement":Yt,"global-statements":zt,number:rt,"numeric-constant":nt,punctuation:Rt,string:At}},"proc-cas":{pattern:/(^proc\s+cas(?:\s+[\w|=]+)?;)[\s\S]+?(?=^(?:proc\s+\w+|quit|data);|(?![\s\S]))/im,lookbehind:!0,inside:{comment:ct,"statement-var":{pattern:/((?:^|\s)=?)saveresult\s[^;]+/im,lookbehind:!0,inside:{statement:{pattern:/^saveresult\s+\S+/i,inside:{keyword:/^(?:saveresult)/i}},rest:Ft}},"cas-actions":Vt,statement:{pattern:/((?:^|\s)=?)(?:default|(?:un)?set|on|output|upload)[^;]+/im,lookbehind:!0,inside:Ft},step:ot,keyword:Zt,function:qt,format:Ut,altformat:Ht,"global-statements":zt,number:rt,"numeric-constant":nt,punctuation:Rt,string:At}},"proc-args":{pattern:RegExp(/(^proc\s+\w+\s+)(?!\s)(?:[^;"']|<str>)+;/.source.replace(/<str>/g,function(){return tt}),"im"),lookbehind:!0,inside:Ft},"macro-keyword":it,"macro-variable":at,"macro-string-functions":{pattern:/((?:^|\s|=))%(?:BQUOTE|NRBQUOTE|NRQUOTE|NRSTR|QUOTE|STR)\(.*?(?:[^%]\))/i,lookbehind:!0,inside:{function:{pattern:/%(?:BQUOTE|NRBQUOTE|NRQUOTE|NRSTR|QUOTE|STR)/i,alias:"keyword"},"macro-keyword":it,"macro-variable":at,"escaped-char":{pattern:/%['"()<>=¬^~;,#]/},punctuation:Rt}},"macro-declaration":{pattern:/^%macro[^;]+(?=;)/im,inside:{keyword:/%macro/i}},"macro-end":{pattern:/^%mend[^;]+(?=;)/im,inside:{keyword:/%mend/i}},macro:{pattern:/%_\w+(?=\()/,alias:"keyword"},input:{pattern:/\binput\s[-\w\s/*.$&]+;/i,inside:{input:{alias:"keyword",pattern:/^input/i},comment:ct,number:rt,"numeric-constant":nt}},"options-args":{pattern:/(^options)[-'"|/\\<>*+=:()\w\s]*(?=;)/im,lookbehind:!0,inside:Ft},"cas-actions":Vt,comment:ct,function:qt,format:Ut,altformat:Ht,"numeric-constant":nt,datetime:{pattern:RegExp(tt+"(?:dt?|t)"),alias:"number"},string:At,step:ot,keyword:Zt,"operator-keyword":{pattern:/\b(?:eq|ge|gt|in|le|lt|ne|not)\b/i,alias:"operator"},number:rt,operator:/\*\*?|\|\|?|!!?|¦¦?|<[>=]?|>[<=]?|[-+\/=&]|[~¬^]=?/,punctuation:Rt}})(t)}return sas_1}var sass_1,hasRequiredSass;function requireSass(){if(hasRequiredSass)return sass_1;hasRequiredSass=1,sass_1=e,e.displayName="sass",e.aliases=[];function e(t){(function(Ye){Ye.languages.sass=Ye.languages.extend("css",{comment:{pattern:/^([ \t]*)\/[\/*].*(?:(?:\r?\n|\r)\1[ \t].+)*/m,lookbehind:!0,greedy:!0}}),Ye.languages.insertBefore("sass","atrule",{"atrule-line":{pattern:/^(?:[ \t]*)[@+=].+/m,greedy:!0,inside:{atrule:/(?:@[\w-]+|[+=])/}}}),delete Ye.languages.sass.atrule;var tt=/\$[-\w]+|#\{\$[-\w]+\}/,rt=[/[+*\/%]|[=!]=|<=?|>=?|\b(?:and|not|or)\b/,{pattern:/(\s)-(?=\s)/,lookbehind:!0}];Ye.languages.insertBefore("sass","property",{"variable-line":{pattern:/^[ \t]*\$.+/m,greedy:!0,inside:{punctuation:/:/,variable:tt,operator:rt}},"property-line":{pattern:/^[ \t]*(?:[^:\s]+ *:.*|:[^:\s].*)/m,greedy:!0,inside:{property:[/[^:\s]+(?=\s*:)/,{pattern:/(:)[^:\s]+/,lookbehind:!0}],punctuation:/:/,variable:tt,operator:rt,important:Ye.languages.sass.important}}}),delete Ye.languages.sass.property,delete Ye.languages.sass.important,Ye.languages.insertBefore("sass","punctuation",{selector:{pattern:/^([ \t]*)\S(?:,[^,\r\n]+|[^,\r\n]*)(?:,[^,\r\n]+)*(?:,(?:\r?\n|\r)\1[ \t]+\S(?:,[^,\r\n]+|[^,\r\n]*)(?:,[^,\r\n]+)*)*/m,lookbehind:!0,greedy:!0}})})(t)}return sass_1}var scala_1,hasRequiredScala;function requireScala(){if(hasRequiredScala)return scala_1;hasRequiredScala=1;var e=requireJava();scala_1=t,t.displayName="scala",t.aliases=[];function t(Ye){Ye.register(e),Ye.languages.scala=Ye.languages.extend("java",{"triple-quoted-string":{pattern:/"""[\s\S]*?"""/,greedy:!0,alias:"string"},string:{pattern:/("|')(?:\\.|(?!\1)[^\\\r\n])*\1/,greedy:!0},keyword:/<-|=>|\b(?:abstract|case|catch|class|def|do|else|extends|final|finally|for|forSome|if|implicit|import|lazy|match|new|null|object|override|package|private|protected|return|sealed|self|super|this|throw|trait|try|type|val|var|while|with|yield)\b/,number:/\b0x(?:[\da-f]*\.)?[\da-f]+|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e\d+)?[dfl]?/i,builtin:/\b(?:Any|AnyRef|AnyVal|Boolean|Byte|Char|Double|Float|Int|Long|Nothing|Short|String|Unit)\b/,symbol:/'[^\d\s\\]\w*/}),Ye.languages.insertBefore("scala","triple-quoted-string",{"string-interpolation":{pattern:/\b[a-z]\w*(?:"""(?:[^$]|\$(?:[^{]|\{(?:[^{}]|\{[^{}]*\})*\}))*?"""|"(?:[^$"\r\n]|\$(?:[^{]|\{(?:[^{}]|\{[^{}]*\})*\}))*")/i,greedy:!0,inside:{id:{pattern:/^\w+/,greedy:!0,alias:"function"},escape:{pattern:/\\\$"|\$[$"]/,greedy:!0,alias:"symbol"},interpolation:{pattern:/\$(?:\w+|\{(?:[^{}]|\{[^{}]*\})*\})/,greedy:!0,inside:{punctuation:/^\$\{?|\}$/,expression:{pattern:/[\s\S]+/,inside:Ye.languages.scala}}},string:/[\s\S]+/}}}),delete Ye.languages.scala["class-name"],delete Ye.languages.scala.function}return scala_1}var scss_1,hasRequiredScss;function requireScss(){if(hasRequiredScss)return scss_1;hasRequiredScss=1,scss_1=e,e.displayName="scss",e.aliases=[];function e(t){t.languages.scss=t.languages.extend("css",{comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|\/\/.*)/,lookbehind:!0},atrule:{pattern:/@[\w-](?:\([^()]+\)|[^()\s]|\s+(?!\s))*?(?=\s+[{;])/,inside:{rule:/@[\w-]+/}},url:/(?:[-a-z]+-)?url(?=\()/i,selector:{pattern:/(?=\S)[^@;{}()]?(?:[^@;{}()\s]|\s+(?!\s)|#\{\$[-\w]+\})+(?=\s*\{(?:\}|\s|[^}][^:{}]*[:{][^}]))/,inside:{parent:{pattern:/&/,alias:"important"},placeholder:/%[-\w]+/,variable:/\$[-\w]+|#\{\$[-\w]+\}/}},property:{pattern:/(?:[-\w]|\$[-\w]|#\{\$[-\w]+\})+(?=\s*:)/,inside:{variable:/\$[-\w]+|#\{\$[-\w]+\}/}}}),t.languages.insertBefore("scss","atrule",{keyword:[/@(?:content|debug|each|else(?: if)?|extend|for|forward|function|if|import|include|mixin|return|use|warn|while)\b/i,{pattern:/( )(?:from|through)(?= )/,lookbehind:!0}]}),t.languages.insertBefore("scss","important",{variable:/\$[-\w]+|#\{\$[-\w]+\}/}),t.languages.insertBefore("scss","function",{"module-modifier":{pattern:/\b(?:as|hide|show|with)\b/i,alias:"keyword"},placeholder:{pattern:/%[-\w]+/,alias:"selector"},statement:{pattern:/\B!(?:default|optional)\b/i,alias:"keyword"},boolean:/\b(?:false|true)\b/,null:{pattern:/\bnull\b/,alias:"keyword"},operator:{pattern:/(\s)(?:[-+*\/%]|[=!]=|<=?|>=?|and|not|or)(?=\s)/,lookbehind:!0}}),t.languages.scss.atrule.inside.rest=t.languages.scss}return scss_1}var shellSession_1,hasRequiredShellSession;function requireShellSession(){if(hasRequiredShellSession)return shellSession_1;hasRequiredShellSession=1;var e=requireBash();shellSession_1=t,t.displayName="shellSession",t.aliases=[];function t(Ye){Ye.register(e),function(tt){var rt=[/"(?:\\[\s\S]|\$\([^)]+\)|\$(?!\()|`[^`]+`|[^"\\`$])*"/.source,/'[^']*'/.source,/\$'(?:[^'\\]|\\[\s\S])*'/.source,/<<-?\s*(["']?)(\w+)\1\s[\s\S]*?[\r\n]\2/.source].join("|");tt.languages["shell-session"]={command:{pattern:RegExp(/^/.source+"(?:"+(/[^\s@:$#%*!/\\]+@[^\r\n@:$#%*!/\\]+(?::[^\0-\x1F$#%*?"<>:;|]+)?/.source+"|"+/[/~.][^\0-\x1F$#%*?"<>@:;|]*/.source)+")?"+/[$#%](?=\s)/.source+/(?:[^\\\r\n \t'"<$]|[ \t](?:(?!#)|#.*$)|\\(?:[^\r]|\r\n?)|\$(?!')|<(?!<)|<<str>>)+/.source.replace(/<<str>>/g,function(){return rt}),"m"),greedy:!0,inside:{info:{pattern:/^[^#$%]+/,alias:"punctuation",inside:{user:/^[^\s@:$#%*!/\\]+@[^\r\n@:$#%*!/\\]+/,punctuation:/:/,path:/[\s\S]+/}},bash:{pattern:/(^[$#%]\s*)\S[\s\S]*/,lookbehind:!0,alias:"language-bash",inside:tt.languages.bash},"shell-symbol":{pattern:/^[$#%]/,alias:"important"}}},output:/.(?:.*(?:[\r\n]|.$))*/},tt.languages["sh-session"]=tt.languages.shellsession=tt.languages["shell-session"]}(Ye)}return shellSession_1}var smali_1,hasRequiredSmali;function requireSmali(){if(hasRequiredSmali)return smali_1;hasRequiredSmali=1,smali_1=e,e.displayName="smali",e.aliases=[];function e(t){t.languages.smali={comment:/#.*/,string:{pattern:/"(?:[^\r\n\\"]|\\.)*"|'(?:[^\r\n\\']|\\(?:.|u[\da-fA-F]{4}))'/,greedy:!0},"class-name":{pattern:/(^|[^L])L(?:(?:\w+|`[^`\r\n]*`)\/)*(?:[\w$]+|`[^`\r\n]*`)(?=\s*;)/,lookbehind:!0,inside:{"class-name":{pattern:/(^L|\/)(?:[\w$]+|`[^`\r\n]*`)$/,lookbehind:!0},namespace:{pattern:/^(L)(?:(?:\w+|`[^`\r\n]*`)\/)+/,lookbehind:!0,inside:{punctuation:/\//}},builtin:/^L/}},builtin:[{pattern:/([();\[])[BCDFIJSVZ]+/,lookbehind:!0},{pattern:/([\w$>]:)[BCDFIJSVZ]/,lookbehind:!0}],keyword:[{pattern:/(\.end\s+)[\w-]+/,lookbehind:!0},{pattern:/(^|[^\w.-])\.(?!\d)[\w-]+/,lookbehind:!0},{pattern:/(^|[^\w.-])(?:abstract|annotation|bridge|constructor|enum|final|interface|private|protected|public|runtime|static|synthetic|system|transient)(?![\w.-])/,lookbehind:!0}],function:{pattern:/(^|[^\w.-])(?:\w+|<[\w$-]+>)(?=\()/,lookbehind:!0},field:{pattern:/[\w$]+(?=:)/,alias:"variable"},register:{pattern:/(^|[^\w.-])[vp]\d(?![\w.-])/,lookbehind:!0,alias:"variable"},boolean:{pattern:/(^|[^\w.-])(?:false|true)(?![\w.-])/,lookbehind:!0},number:{pattern:/(^|[^/\w.-])-?(?:NAN|INFINITY|0x(?:[\dA-F]+(?:\.[\dA-F]*)?|\.[\dA-F]+)(?:p[+-]?[\dA-F]+)?|(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?)[dflst]?(?![\w.-])/i,lookbehind:!0},label:{pattern:/(:)\w+/,lookbehind:!0,alias:"property"},operator:/->|\.\.|[\[=]/,punctuation:/[{}(),;:]/}}return smali_1}var smalltalk_1,hasRequiredSmalltalk;function requireSmalltalk(){if(hasRequiredSmalltalk)return smalltalk_1;hasRequiredSmalltalk=1,smalltalk_1=e,e.displayName="smalltalk",e.aliases=[];function e(t){t.languages.smalltalk={comment:{pattern:/"(?:""|[^"])*"/,greedy:!0},char:{pattern:/\$./,greedy:!0},string:{pattern:/'(?:''|[^'])*'/,greedy:!0},symbol:/#[\da-z]+|#(?:-|([+\/\\*~<>=@%|&?!])\1?)|#(?=\()/i,"block-arguments":{pattern:/(\[\s*):[^\[|]*\|/,lookbehind:!0,inside:{variable:/:[\da-z]+/i,punctuation:/\|/}},"temporary-variables":{pattern:/\|[^|]+\|/,inside:{variable:/[\da-z]+/i,punctuation:/\|/}},keyword:/\b(?:new|nil|self|super)\b/,boolean:/\b(?:false|true)\b/,number:[/\d+r-?[\dA-Z]+(?:\.[\dA-Z]+)?(?:e-?\d+)?/,/\b\d+(?:\.\d+)?(?:e-?\d+)?/],operator:/[<=]=?|:=|~[~=]|\/\/?|\\\\|>[>=]?|[!^+\-*&|,@]/,punctuation:/[.;:?\[\](){}]/}}return smalltalk_1}var smarty_1,hasRequiredSmarty;function requireSmarty(){if(hasRequiredSmarty)return smarty_1;hasRequiredSmarty=1;var e=requireMarkupTemplating();smarty_1=t,t.displayName="smarty",t.aliases=[];function t(Ye){Ye.register(e),function(tt){tt.languages.smarty={comment:{pattern:/^\{\*[\s\S]*?\*\}/,greedy:!0},"embedded-php":{pattern:/^\{php\}[\s\S]*?\{\/php\}/,greedy:!0,inside:{smarty:{pattern:/^\{php\}|\{\/php\}$/,inside:null},php:{pattern:/[\s\S]+/,alias:"language-php",inside:tt.languages.php}}},string:[{pattern:/"(?:\\.|[^"\\\r\n])*"/,greedy:!0,inside:{interpolation:{pattern:/\{[^{}]*\}|`[^`]*`/,inside:{"interpolation-punctuation":{pattern:/^[{`]|[`}]$/,alias:"punctuation"},expression:{pattern:/[\s\S]+/,inside:null}}},variable:/\$\w+/}},{pattern:/'(?:\\.|[^'\\\r\n])*'/,greedy:!0}],keyword:{pattern:/(^\{\/?)[a-z_]\w*\b(?!\()/i,lookbehind:!0,greedy:!0},delimiter:{pattern:/^\{\/?|\}$/,greedy:!0,alias:"punctuation"},number:/\b0x[\dA-Fa-f]+|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[Ee][-+]?\d+)?/,variable:[/\$(?!\d)\w+/,/#(?!\d)\w+#/,{pattern:/(\.|->|\w\s*=)(?!\d)\w+\b(?!\()/,lookbehind:!0},{pattern:/(\[)(?!\d)\w+(?=\])/,lookbehind:!0}],function:{pattern:/(\|\s*)@?[a-z_]\w*|\b[a-z_]\w*(?=\()/i,lookbehind:!0},"attr-name":/\b[a-z_]\w*(?=\s*=)/i,boolean:/\b(?:false|no|off|on|true|yes)\b/,punctuation:/[\[\](){}.,:`]|->/,operator:[/[+\-*\/%]|==?=?|[!<>]=?|&&|\|\|?/,/\bis\s+(?:not\s+)?(?:div|even|odd)(?:\s+by)?\b/,/\b(?:and|eq|gt?e|gt|lt?e|lt|mod|neq?|not|or)\b/]},tt.languages.smarty["embedded-php"].inside.smarty.inside=tt.languages.smarty,tt.languages.smarty.string[0].inside.interpolation.inside.expression.inside=tt.languages.smarty;var rt=/"(?:\\.|[^"\\\r\n])*"|'(?:\\.|[^'\\\r\n])*'/,nt=RegExp(/\{\*[\s\S]*?\*\}/.source+"|"+/\{php\}[\s\S]*?\{\/php\}/.source+"|"+/\{(?:[^{}"']|<str>|\{(?:[^{}"']|<str>|\{(?:[^{}"']|<str>)*\})*\})*\}/.source.replace(/<str>/g,function(){return rt.source}),"g");tt.hooks.add("before-tokenize",function(at){var it="{literal}",ot="{/literal}",ct=!1;tt.languages["markup-templating"].buildPlaceholders(at,"smarty",nt,function(At){return At===ot&&(ct=!1),ct?!1:(At===it&&(ct=!0),!0)})}),tt.hooks.add("after-tokenize",function(at){tt.languages["markup-templating"].tokenizePlaceholders(at,"smarty")})}(Ye)}return smarty_1}var sml_1,hasRequiredSml;function requireSml(){if(hasRequiredSml)return sml_1;hasRequiredSml=1,sml_1=e,e.displayName="sml",e.aliases=["smlnj"];function e(t){(function(Ye){var tt=/\b(?:abstype|and|andalso|as|case|datatype|do|else|end|eqtype|exception|fn|fun|functor|handle|if|in|include|infix|infixr|let|local|nonfix|of|op|open|orelse|raise|rec|sharing|sig|signature|struct|structure|then|type|val|where|while|with|withtype)\b/i;Ye.languages.sml={comment:/\(\*(?:[^*(]|\*(?!\))|\((?!\*)|\(\*(?:[^*(]|\*(?!\))|\((?!\*))*\*\))*\*\)/,string:{pattern:/#?"(?:[^"\\]|\\.)*"/,greedy:!0},"class-name":[{pattern:RegExp(/((?:^|[^:]):\s*)<TERMINAL>(?:\s*(?:(?:\*|->)\s*<TERMINAL>|,\s*<TERMINAL>(?:(?=<NOT-LAST>)|(?!<NOT-LAST>)\s+<LONG-ID>)))*/.source.replace(/<NOT-LAST>/g,function(){return/\s*(?:[*,]|->)/.source}).replace(/<TERMINAL>/g,function(){return/(?:'[\w']*|<LONG-ID>|\((?:[^()]|\([^()]*\))*\)|\{(?:[^{}]|\{[^{}]*\})*\})(?:\s+<LONG-ID>)*/.source}).replace(/<LONG-ID>/g,function(){return/(?!<KEYWORD>)[a-z\d_][\w'.]*/.source}).replace(/<KEYWORD>/g,function(){return tt.source}),"i"),lookbehind:!0,greedy:!0,inside:null},{pattern:/((?:^|[^\w'])(?:datatype|exception|functor|signature|structure|type)\s+)[a-z_][\w'.]*/i,lookbehind:!0}],function:{pattern:/((?:^|[^\w'])fun\s+)[a-z_][\w'.]*/i,lookbehind:!0},keyword:tt,variable:{pattern:/(^|[^\w'])'[\w']*/,lookbehind:!0},number:/~?\b(?:\d+(?:\.\d+)?(?:e~?\d+)?|0x[\da-f]+)\b/i,word:{pattern:/\b0w(?:\d+|x[\da-f]+)\b/i,alias:"constant"},boolean:/\b(?:false|true)\b/i,operator:/\.\.\.|:[>=:]|=>?|->|[<>]=?|[!+\-*/^#|@~]/,punctuation:/[(){}\[\].:,;]/},Ye.languages.sml["class-name"][0].inside=Ye.languages.sml,Ye.languages.smlnj=Ye.languages.sml})(t)}return sml_1}var solidity_1,hasRequiredSolidity;function requireSolidity(){if(hasRequiredSolidity)return solidity_1;hasRequiredSolidity=1,solidity_1=e,e.displayName="solidity",e.aliases=["sol"];function e(t){t.languages.solidity=t.languages.extend("clike",{"class-name":{pattern:/(\b(?:contract|enum|interface|library|new|struct|using)\s+)(?!\d)[\w$]+/,lookbehind:!0},keyword:/\b(?:_|anonymous|as|assembly|assert|break|calldata|case|constant|constructor|continue|contract|default|delete|do|else|emit|enum|event|external|for|from|function|if|import|indexed|inherited|interface|internal|is|let|library|mapping|memory|modifier|new|payable|pragma|private|public|pure|require|returns?|revert|selfdestruct|solidity|storage|struct|suicide|switch|this|throw|using|var|view|while)\b/,operator:/=>|->|:=|=:|\*\*|\+\+|--|\|\||&&|<<=?|>>=?|[-+*/%^&|<>!=]=?|[~?]/}),t.languages.insertBefore("solidity","keyword",{builtin:/\b(?:address|bool|byte|u?int(?:8|16|24|32|40|48|56|64|72|80|88|96|104|112|120|128|136|144|152|160|168|176|184|192|200|208|216|224|232|240|248|256)?|string|bytes(?:[1-9]|[12]\d|3[0-2])?)\b/}),t.languages.insertBefore("solidity","number",{version:{pattern:/([<>]=?|\^)\d+\.\d+\.\d+\b/,lookbehind:!0,alias:"number"}}),t.languages.sol=t.languages.solidity}return solidity_1}var solutionFile_1,hasRequiredSolutionFile;function requireSolutionFile(){if(hasRequiredSolutionFile)return solutionFile_1;hasRequiredSolutionFile=1,solutionFile_1=e,e.displayName="solutionFile",e.aliases=[];function e(t){(function(Ye){var tt={pattern:/\{[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}\}/i,alias:"constant",inside:{punctuation:/[{}]/}};Ye.languages["solution-file"]={comment:{pattern:/#.*/,greedy:!0},string:{pattern:/"[^"\r\n]*"|'[^'\r\n]*'/,greedy:!0,inside:{guid:tt}},object:{pattern:/^([ \t]*)(?:([A-Z]\w*)\b(?=.*(?:\r\n?|\n)(?:\1[ \t].*(?:\r\n?|\n))*\1End\2(?=[ \t]*$))|End[A-Z]\w*(?=[ \t]*$))/m,lookbehind:!0,greedy:!0,alias:"keyword"},property:{pattern:/^([ \t]*)(?!\s)[^\r\n"#=()]*[^\s"#=()](?=\s*=)/m,lookbehind:!0,inside:{guid:tt}},guid:tt,number:/\b\d+(?:\.\d+)*\b/,boolean:/\b(?:FALSE|TRUE)\b/,operator:/=/,punctuation:/[(),]/},Ye.languages.sln=Ye.languages["solution-file"]})(t)}return solutionFile_1}var soy_1,hasRequiredSoy;function requireSoy(){if(hasRequiredSoy)return soy_1;hasRequiredSoy=1;var e=requireMarkupTemplating();soy_1=t,t.displayName="soy",t.aliases=[];function t(Ye){Ye.register(e),function(tt){var rt=/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,nt=/\b\d+(?:\.\d+)?(?:[eE][+-]?\d+)?\b|\b0x[\dA-F]+\b/;tt.languages.soy={comment:[/\/\*[\s\S]*?\*\//,{pattern:/(\s)\/\/.*/,lookbehind:!0,greedy:!0}],"command-arg":{pattern:/(\{+\/?\s*(?:alias|call|delcall|delpackage|deltemplate|namespace|template)\s+)\.?[\w.]+/,lookbehind:!0,alias:"string",inside:{punctuation:/\./}},parameter:{pattern:/(\{+\/?\s*@?param\??\s+)\.?[\w.]+/,lookbehind:!0,alias:"variable"},keyword:[{pattern:/(\{+\/?[^\S\r\n]*)(?:\\[nrt]|alias|call|case|css|default|delcall|delpackage|deltemplate|else(?:if)?|fallbackmsg|for(?:each)?|if(?:empty)?|lb|let|literal|msg|namespace|nil|@?param\??|rb|sp|switch|template|xid)/,lookbehind:!0},/\b(?:any|as|attributes|bool|css|float|html|in|int|js|list|map|null|number|string|uri)\b/],delimiter:{pattern:/^\{+\/?|\/?\}+$/,alias:"punctuation"},property:/\w+(?==)/,variable:{pattern:/\$[^\W\d]\w*(?:\??(?:\.\w+|\[[^\]]+\]))*/,inside:{string:{pattern:rt,greedy:!0},number:nt,punctuation:/[\[\].?]/}},string:{pattern:rt,greedy:!0},function:[/\w+(?=\()/,{pattern:/(\|[^\S\r\n]*)\w+/,lookbehind:!0}],boolean:/\b(?:false|true)\b/,number:nt,operator:/\?:?|<=?|>=?|==?|!=|[+*/%-]|\b(?:and|not|or)\b/,punctuation:/[{}()\[\]|.,:]/},tt.hooks.add("before-tokenize",function(at){var it=/\{\{.+?\}\}|\{.+?\}|\s\/\/.*|\/\*[\s\S]*?\*\//g,ot="{literal}",ct="{/literal}",At=!1;tt.languages["markup-templating"].buildPlaceholders(at,"soy",it,function(Rt){return Rt===ct&&(At=!1),At?!1:(Rt===ot&&(At=!0),!0)})}),tt.hooks.add("after-tokenize",function(at){tt.languages["markup-templating"].tokenizePlaceholders(at,"soy")})}(Ye)}return soy_1}var turtle_1,hasRequiredTurtle;function requireTurtle(){if(hasRequiredTurtle)return turtle_1;hasRequiredTurtle=1,turtle_1=e,e.displayName="turtle",e.aliases=[];function e(t){t.languages.turtle={comment:{pattern:/#.*/,greedy:!0},"multiline-string":{pattern:/"""(?:(?:""?)?(?:[^"\\]|\\.))*"""|'''(?:(?:''?)?(?:[^'\\]|\\.))*'''/,greedy:!0,alias:"string",inside:{comment:/#.*/}},string:{pattern:/"(?:[^\\"\r\n]|\\.)*"|'(?:[^\\'\r\n]|\\.)*'/,greedy:!0},url:{pattern:/<(?:[^\x00-\x20<>"{}|^`\\]|\\(?:u[\da-fA-F]{4}|U[\da-fA-F]{8}))*>/,greedy:!0,inside:{punctuation:/[<>]/}},function:{pattern:/(?:(?![-.\d\xB7])[-.\w\xB7\xC0-\uFFFD]+)?:(?:(?![-.])(?:[-.:\w\xC0-\uFFFD]|%[\da-f]{2}|\\.)+)?/i,inside:{"local-name":{pattern:/([^:]*:)[\s\S]+/,lookbehind:!0},prefix:{pattern:/[\s\S]+/,inside:{punctuation:/:/}}}},number:/[+-]?\b\d+(?:\.\d*)?(?:e[+-]?\d+)?/i,punctuation:/[{}.,;()[\]]|\^\^/,boolean:/\b(?:false|true)\b/,keyword:[/(?:\ba|@prefix|@base)\b|=/,/\b(?:base|graph|prefix)\b/i],tag:{pattern:/@[a-z]+(?:-[a-z\d]+)*/i,inside:{punctuation:/@/}}},t.languages.trig=t.languages.turtle}return turtle_1}var sparql_1,hasRequiredSparql;function requireSparql(){if(hasRequiredSparql)return sparql_1;hasRequiredSparql=1;var e=requireTurtle();sparql_1=t,t.displayName="sparql",t.aliases=["rq"];function t(Ye){Ye.register(e),Ye.languages.sparql=Ye.languages.extend("turtle",{boolean:/\b(?:false|true)\b/i,variable:{pattern:/[?$]\w+/,greedy:!0}}),Ye.languages.insertBefore("sparql","punctuation",{keyword:[/\b(?:A|ADD|ALL|AS|ASC|ASK|BNODE|BY|CLEAR|CONSTRUCT|COPY|CREATE|DATA|DEFAULT|DELETE|DESC|DESCRIBE|DISTINCT|DROP|EXISTS|FILTER|FROM|GROUP|HAVING|INSERT|INTO|LIMIT|LOAD|MINUS|MOVE|NAMED|NOT|NOW|OFFSET|OPTIONAL|ORDER|RAND|REDUCED|SELECT|SEPARATOR|SERVICE|SILENT|STRUUID|UNION|USING|UUID|VALUES|WHERE)\b/i,/\b(?:ABS|AVG|BIND|BOUND|CEIL|COALESCE|CONCAT|CONTAINS|COUNT|DATATYPE|DAY|ENCODE_FOR_URI|FLOOR|GROUP_CONCAT|HOURS|IF|IRI|isBLANK|isIRI|isLITERAL|isNUMERIC|isURI|LANG|LANGMATCHES|LCASE|MAX|MD5|MIN|MINUTES|MONTH|REGEX|REPLACE|ROUND|sameTerm|SAMPLE|SECONDS|SHA1|SHA256|SHA384|SHA512|STR|STRAFTER|STRBEFORE|STRDT|STRENDS|STRLANG|STRLEN|STRSTARTS|SUBSTR|SUM|TIMEZONE|TZ|UCASE|URI|YEAR)\b(?=\s*\()/i,/\b(?:BASE|GRAPH|PREFIX)\b/i]}),Ye.languages.rq=Ye.languages.sparql}return sparql_1}var splunkSpl_1,hasRequiredSplunkSpl;function requireSplunkSpl(){if(hasRequiredSplunkSpl)return splunkSpl_1;hasRequiredSplunkSpl=1,splunkSpl_1=e,e.displayName="splunkSpl",e.aliases=[];function e(t){t.languages["splunk-spl"]={comment:/`comment\("(?:\\.|[^\\"])*"\)`/,string:{pattern:/"(?:\\.|[^\\"])*"/,greedy:!0},keyword:/\b(?:abstract|accum|addcoltotals|addinfo|addtotals|analyzefields|anomalies|anomalousvalue|anomalydetection|append|appendcols|appendcsv|appendlookup|appendpipe|arules|associate|audit|autoregress|bin|bucket|bucketdir|chart|cluster|cofilter|collect|concurrency|contingency|convert|correlate|datamodel|dbinspect|dedup|delete|delta|diff|erex|eval|eventcount|eventstats|extract|fieldformat|fields|fieldsummary|filldown|fillnull|findtypes|folderize|foreach|format|from|gauge|gentimes|geom|geomfilter|geostats|head|highlight|history|iconify|input|inputcsv|inputlookup|iplocation|join|kmeans|kv|kvform|loadjob|localize|localop|lookup|makecontinuous|makemv|makeresults|map|mcollect|metadata|metasearch|meventcollect|mstats|multikv|multisearch|mvcombine|mvexpand|nomv|outlier|outputcsv|outputlookup|outputtext|overlap|pivot|predict|rangemap|rare|regex|relevancy|reltime|rename|replace|rest|return|reverse|rex|rtorder|run|savedsearch|script|scrub|search|searchtxn|selfjoin|sendemail|set|setfields|sichart|sirare|sistats|sitimechart|sitop|sort|spath|stats|strcat|streamstats|table|tags|tail|timechart|timewrap|top|transaction|transpose|trendline|tscollect|tstats|typeahead|typelearner|typer|union|uniq|untable|where|x11|xmlkv|xmlunescape|xpath|xyseries)\b/i,"operator-word":{pattern:/\b(?:and|as|by|not|or|xor)\b/i,alias:"operator"},function:/\b\w+(?=\s*\()/,property:/\b\w+(?=\s*=(?!=))/,date:{pattern:/\b\d{1,2}\/\d{1,2}\/\d{1,4}(?:(?::\d{1,2}){3})?\b/,alias:"number"},number:/\b\d+(?:\.\d+)?\b/,boolean:/\b(?:f|false|t|true)\b/i,operator:/[<>=]=?|[-+*/%|]/,punctuation:/[()[\],]/}}return splunkSpl_1}var sqf_1,hasRequiredSqf;function requireSqf(){if(hasRequiredSqf)return sqf_1;hasRequiredSqf=1,sqf_1=e,e.displayName="sqf",e.aliases=[];function e(t){t.languages.sqf=t.languages.extend("clike",{string:{pattern:/"(?:(?:"")?[^"])*"(?!")|'(?:[^'])*'/,greedy:!0},keyword:/\b(?:breakOut|breakTo|call|case|catch|default|do|echo|else|execFSM|execVM|exitWith|for|forEach|forEachMember|forEachMemberAgent|forEachMemberTeam|from|goto|if|nil|preprocessFile|preprocessFileLineNumbers|private|scopeName|spawn|step|switch|then|throw|to|try|while|with)\b/i,boolean:/\b(?:false|true)\b/i,function:/\b(?:abs|accTime|acos|action|actionIDs|actionKeys|actionKeysImages|actionKeysNames|actionKeysNamesArray|actionName|actionParams|activateAddons|activatedAddons|activateKey|add3DENConnection|add3DENEventHandler|add3DENLayer|addAction|addBackpack|addBackpackCargo|addBackpackCargoGlobal|addBackpackGlobal|addCamShake|addCuratorAddons|addCuratorCameraArea|addCuratorEditableObjects|addCuratorEditingArea|addCuratorPoints|addEditorObject|addEventHandler|addForce|addForceGeneratorRTD|addGoggles|addGroupIcon|addHandgunItem|addHeadgear|addItem|addItemCargo|addItemCargoGlobal|addItemPool|addItemToBackpack|addItemToUniform|addItemToVest|addLiveStats|addMagazine|addMagazineAmmoCargo|addMagazineCargo|addMagazineCargoGlobal|addMagazineGlobal|addMagazinePool|addMagazines|addMagazineTurret|addMenu|addMenuItem|addMissionEventHandler|addMPEventHandler|addMusicEventHandler|addOwnedMine|addPlayerScores|addPrimaryWeaponItem|addPublicVariableEventHandler|addRating|addResources|addScore|addScoreSide|addSecondaryWeaponItem|addSwitchableUnit|addTeamMember|addToRemainsCollector|addTorque|addUniform|addVehicle|addVest|addWaypoint|addWeapon|addWeaponCargo|addWeaponCargoGlobal|addWeaponGlobal|addWeaponItem|addWeaponPool|addWeaponTurret|admin|agent|agents|AGLToASL|aimedAtTarget|aimPos|airDensityCurveRTD|airDensityRTD|airplaneThrottle|airportSide|AISFinishHeal|alive|all3DENEntities|allAirports|allControls|allCurators|allCutLayers|allDead|allDeadMen|allDisplays|allGroups|allMapMarkers|allMines|allMissionObjects|allow3DMode|allowCrewInImmobile|allowCuratorLogicIgnoreAreas|allowDamage|allowDammage|allowFileOperations|allowFleeing|allowGetIn|allowSprint|allPlayers|allSimpleObjects|allSites|allTurrets|allUnits|allUnitsUAV|allVariables|ammo|ammoOnPylon|animate|animateBay|animateDoor|animatePylon|animateSource|animationNames|animationPhase|animationSourcePhase|animationState|append|apply|armoryPoints|arrayIntersect|asin|ASLToAGL|ASLToATL|assert|assignAsCargo|assignAsCargoIndex|assignAsCommander|assignAsDriver|assignAsGunner|assignAsTurret|assignCurator|assignedCargo|assignedCommander|assignedDriver|assignedGunner|assignedItems|assignedTarget|assignedTeam|assignedVehicle|assignedVehicleRole|assignItem|assignTeam|assignToAirport|atan|atan2|atg|ATLToASL|attachedObject|attachedObjects|attachedTo|attachObject|attachTo|attackEnabled|backpack|backpackCargo|backpackContainer|backpackItems|backpackMagazines|backpackSpaceFor|behaviour|benchmark|binocular|blufor|boundingBox|boundingBoxReal|boundingCenter|briefingName|buildingExit|buildingPos|buldozer_EnableRoadDiag|buldozer_IsEnabledRoadDiag|buldozer_LoadNewRoads|buldozer_reloadOperMap|buttonAction|buttonSetAction|cadetMode|callExtension|camCommand|camCommit|camCommitPrepared|camCommitted|camConstuctionSetParams|camCreate|camDestroy|cameraEffect|cameraEffectEnableHUD|cameraInterest|cameraOn|cameraView|campaignConfigFile|camPreload|camPreloaded|camPrepareBank|camPrepareDir|camPrepareDive|camPrepareFocus|camPrepareFov|camPrepareFovRange|camPreparePos|camPrepareRelPos|camPrepareTarget|camSetBank|camSetDir|camSetDive|camSetFocus|camSetFov|camSetFovRange|camSetPos|camSetRelPos|camSetTarget|camTarget|camUseNVG|canAdd|canAddItemToBackpack|canAddItemToUniform|canAddItemToVest|cancelSimpleTaskDestination|canFire|canMove|canSlingLoad|canStand|canSuspend|canTriggerDynamicSimulation|canUnloadInCombat|canVehicleCargo|captive|captiveNum|cbChecked|cbSetChecked|ceil|channelEnabled|cheatsEnabled|checkAIFeature|checkVisibility|civilian|className|clear3DENAttribute|clear3DENInventory|clearAllItemsFromBackpack|clearBackpackCargo|clearBackpackCargoGlobal|clearForcesRTD|clearGroupIcons|clearItemCargo|clearItemCargoGlobal|clearItemPool|clearMagazineCargo|clearMagazineCargoGlobal|clearMagazinePool|clearOverlay|clearRadio|clearVehicleInit|clearWeaponCargo|clearWeaponCargoGlobal|clearWeaponPool|clientOwner|closeDialog|closeDisplay|closeOverlay|collapseObjectTree|collect3DENHistory|collectiveRTD|combatMode|commandArtilleryFire|commandChat|commander|commandFire|commandFollow|commandFSM|commandGetOut|commandingMenu|commandMove|commandRadio|commandStop|commandSuppressiveFire|commandTarget|commandWatch|comment|commitOverlay|compile|compileFinal|completedFSM|composeText|configClasses|configFile|configHierarchy|configName|configNull|configProperties|configSourceAddonList|configSourceMod|configSourceModList|confirmSensorTarget|connectTerminalToUAV|controlNull|controlsGroupCtrl|copyFromClipboard|copyToClipboard|copyWaypoints|cos|count|countEnemy|countFriendly|countSide|countType|countUnknown|create3DENComposition|create3DENEntity|createAgent|createCenter|createDialog|createDiaryLink|createDiaryRecord|createDiarySubject|createDisplay|createGearDialog|createGroup|createGuardedPoint|createLocation|createMarker|createMarkerLocal|createMenu|createMine|createMissionDisplay|createMPCampaignDisplay|createSimpleObject|createSimpleTask|createSite|createSoundSource|createTask|createTeam|createTrigger|createUnit|createVehicle|createVehicleCrew|createVehicleLocal|crew|ctAddHeader|ctAddRow|ctClear|ctCurSel|ctData|ctFindHeaderRows|ctFindRowHeader|ctHeaderControls|ctHeaderCount|ctRemoveHeaders|ctRemoveRows|ctrlActivate|ctrlAddEventHandler|ctrlAngle|ctrlAutoScrollDelay|ctrlAutoScrollRewind|ctrlAutoScrollSpeed|ctrlChecked|ctrlClassName|ctrlCommit|ctrlCommitted|ctrlCreate|ctrlDelete|ctrlEnable|ctrlEnabled|ctrlFade|ctrlHTMLLoaded|ctrlIDC|ctrlIDD|ctrlMapAnimAdd|ctrlMapAnimClear|ctrlMapAnimCommit|ctrlMapAnimDone|ctrlMapCursor|ctrlMapMouseOver|ctrlMapScale|ctrlMapScreenToWorld|ctrlMapWorldToScreen|ctrlModel|ctrlModelDirAndUp|ctrlModelScale|ctrlParent|ctrlParentControlsGroup|ctrlPosition|ctrlRemoveAllEventHandlers|ctrlRemoveEventHandler|ctrlScale|ctrlSetActiveColor|ctrlSetAngle|ctrlSetAutoScrollDelay|ctrlSetAutoScrollRewind|ctrlSetAutoScrollSpeed|ctrlSetBackgroundColor|ctrlSetChecked|ctrlSetDisabledColor|ctrlSetEventHandler|ctrlSetFade|ctrlSetFocus|ctrlSetFont|ctrlSetFontH1|ctrlSetFontH1B|ctrlSetFontH2|ctrlSetFontH2B|ctrlSetFontH3|ctrlSetFontH3B|ctrlSetFontH4|ctrlSetFontH4B|ctrlSetFontH5|ctrlSetFontH5B|ctrlSetFontH6|ctrlSetFontH6B|ctrlSetFontHeight|ctrlSetFontHeightH1|ctrlSetFontHeightH2|ctrlSetFontHeightH3|ctrlSetFontHeightH4|ctrlSetFontHeightH5|ctrlSetFontHeightH6|ctrlSetFontHeightSecondary|ctrlSetFontP|ctrlSetFontPB|ctrlSetFontSecondary|ctrlSetForegroundColor|ctrlSetModel|ctrlSetModelDirAndUp|ctrlSetModelScale|ctrlSetPixelPrecision|ctrlSetPosition|ctrlSetScale|ctrlSetStructuredText|ctrlSetText|ctrlSetTextColor|ctrlSetTextColorSecondary|ctrlSetTextSecondary|ctrlSetTooltip|ctrlSetTooltipColorBox|ctrlSetTooltipColorShade|ctrlSetTooltipColorText|ctrlShow|ctrlShown|ctrlText|ctrlTextHeight|ctrlTextSecondary|ctrlTextWidth|ctrlType|ctrlVisible|ctRowControls|ctRowCount|ctSetCurSel|ctSetData|ctSetHeaderTemplate|ctSetRowTemplate|ctSetValue|ctValue|curatorAddons|curatorCamera|curatorCameraArea|curatorCameraAreaCeiling|curatorCoef|curatorEditableObjects|curatorEditingArea|curatorEditingAreaType|curatorMouseOver|curatorPoints|curatorRegisteredObjects|curatorSelected|curatorWaypointCost|current3DENOperation|currentChannel|currentCommand|currentMagazine|currentMagazineDetail|currentMagazineDetailTurret|currentMagazineTurret|currentMuzzle|currentNamespace|currentTask|currentTasks|currentThrowable|currentVisionMode|currentWaypoint|currentWeapon|currentWeaponMode|currentWeaponTurret|currentZeroing|cursorObject|cursorTarget|customChat|customRadio|cutFadeOut|cutObj|cutRsc|cutText|damage|date|dateToNumber|daytime|deActivateKey|debriefingText|debugFSM|debugLog|deg|delete3DENEntities|deleteAt|deleteCenter|deleteCollection|deleteEditorObject|deleteGroup|deleteGroupWhenEmpty|deleteIdentity|deleteLocation|deleteMarker|deleteMarkerLocal|deleteRange|deleteResources|deleteSite|deleteStatus|deleteTeam|deleteVehicle|deleteVehicleCrew|deleteWaypoint|detach|detectedMines|diag_activeMissionFSMs|diag_activeScripts|diag_activeSQFScripts|diag_activeSQSScripts|diag_captureFrame|diag_captureFrameToFile|diag_captureSlowFrame|diag_codePerformance|diag_drawMode|diag_dynamicSimulationEnd|diag_enable|diag_enabled|diag_fps|diag_fpsMin|diag_frameNo|diag_lightNewLoad|diag_list|diag_log|diag_logSlowFrame|diag_mergeConfigFile|diag_recordTurretLimits|diag_setLightNew|diag_tickTime|diag_toggle|dialog|diarySubjectExists|didJIP|didJIPOwner|difficulty|difficultyEnabled|difficultyEnabledRTD|difficultyOption|direction|directSay|disableAI|disableCollisionWith|disableConversation|disableDebriefingStats|disableMapIndicators|disableNVGEquipment|disableRemoteSensors|disableSerialization|disableTIEquipment|disableUAVConnectability|disableUserInput|displayAddEventHandler|displayCtrl|displayNull|displayParent|displayRemoveAllEventHandlers|displayRemoveEventHandler|displaySetEventHandler|dissolveTeam|distance|distance2D|distanceSqr|distributionRegion|do3DENAction|doArtilleryFire|doFire|doFollow|doFSM|doGetOut|doMove|doorPhase|doStop|doSuppressiveFire|doTarget|doWatch|drawArrow|drawEllipse|drawIcon|drawIcon3D|drawLine|drawLine3D|drawLink|drawLocation|drawPolygon|drawRectangle|drawTriangle|driver|drop|dynamicSimulationDistance|dynamicSimulationDistanceCoef|dynamicSimulationEnabled|dynamicSimulationSystemEnabled|east|edit3DENMissionAttributes|editObject|editorSetEventHandler|effectiveCommander|emptyPositions|enableAI|enableAIFeature|enableAimPrecision|enableAttack|enableAudioFeature|enableAutoStartUpRTD|enableAutoTrimRTD|enableCamShake|enableCaustics|enableChannel|enableCollisionWith|enableCopilot|enableDebriefingStats|enableDiagLegend|enableDynamicSimulation|enableDynamicSimulationSystem|enableEndDialog|enableEngineArtillery|enableEnvironment|enableFatigue|enableGunLights|enableInfoPanelComponent|enableIRLasers|enableMimics|enablePersonTurret|enableRadio|enableReload|enableRopeAttach|enableSatNormalOnDetail|enableSaving|enableSentences|enableSimulation|enableSimulationGlobal|enableStamina|enableStressDamage|enableTeamSwitch|enableTraffic|enableUAVConnectability|enableUAVWaypoints|enableVehicleCargo|enableVehicleSensor|enableWeaponDisassembly|endl|endLoadingScreen|endMission|engineOn|enginesIsOnRTD|enginesPowerRTD|enginesRpmRTD|enginesTorqueRTD|entities|environmentEnabled|estimatedEndServerTime|estimatedTimeLeft|evalObjectArgument|everyBackpack|everyContainer|exec|execEditorScript|exp|expectedDestination|exportJIPMessages|eyeDirection|eyePos|face|faction|fadeMusic|fadeRadio|fadeSound|fadeSpeech|failMission|fillWeaponsFromPool|find|findCover|findDisplay|findEditorObject|findEmptyPosition|findEmptyPositionReady|findIf|findNearestEnemy|finishMissionInit|finite|fire|fireAtTarget|firstBackpack|flag|flagAnimationPhase|flagOwner|flagSide|flagTexture|fleeing|floor|flyInHeight|flyInHeightASL|fog|fogForecast|fogParams|forceAddUniform|forceAtPositionRTD|forcedMap|forceEnd|forceFlagTexture|forceFollowRoad|forceGeneratorRTD|forceMap|forceRespawn|forceSpeed|forceWalk|forceWeaponFire|forceWeatherChange|forgetTarget|format|formation|formationDirection|formationLeader|formationMembers|formationPosition|formationTask|formatText|formLeader|freeLook|fromEditor|fuel|fullCrew|gearIDCAmmoCount|gearSlotAmmoCount|gearSlotData|get3DENActionState|get3DENAttribute|get3DENCamera|get3DENConnections|get3DENEntity|get3DENEntityID|get3DENGrid|get3DENIconsVisible|get3DENLayerEntities|get3DENLinesVisible|get3DENMissionAttribute|get3DENMouseOver|get3DENSelected|getAimingCoef|getAllEnvSoundControllers|getAllHitPointsDamage|getAllOwnedMines|getAllSoundControllers|getAmmoCargo|getAnimAimPrecision|getAnimSpeedCoef|getArray|getArtilleryAmmo|getArtilleryComputerSettings|getArtilleryETA|getAssignedCuratorLogic|getAssignedCuratorUnit|getBackpackCargo|getBleedingRemaining|getBurningValue|getCameraViewDirection|getCargoIndex|getCenterOfMass|getClientState|getClientStateNumber|getCompatiblePylonMagazines|getConnectedUAV|getContainerMaxLoad|getCursorObjectParams|getCustomAimCoef|getDammage|getDescription|getDir|getDirVisual|getDLCAssetsUsage|getDLCAssetsUsageByName|getDLCs|getDLCUsageTime|getEditorCamera|getEditorMode|getEditorObjectScope|getElevationOffset|getEngineTargetRpmRTD|getEnvSoundController|getFatigue|getFieldManualStartPage|getForcedFlagTexture|getFriend|getFSMVariable|getFuelCargo|getGroupIcon|getGroupIconParams|getGroupIcons|getHideFrom|getHit|getHitIndex|getHitPointDamage|getItemCargo|getMagazineCargo|getMarkerColor|getMarkerPos|getMarkerSize|getMarkerType|getMass|getMissionConfig|getMissionConfigValue|getMissionDLCs|getMissionLayerEntities|getMissionLayers|getModelInfo|getMousePosition|getMusicPlayedTime|getNumber|getObjectArgument|getObjectChildren|getObjectDLC|getObjectMaterials|getObjectProxy|getObjectTextures|getObjectType|getObjectViewDistance|getOxygenRemaining|getPersonUsedDLCs|getPilotCameraDirection|getPilotCameraPosition|getPilotCameraRotation|getPilotCameraTarget|getPlateNumber|getPlayerChannel|getPlayerScores|getPlayerUID|getPlayerUIDOld|getPos|getPosASL|getPosASLVisual|getPosASLW|getPosATL|getPosATLVisual|getPosVisual|getPosWorld|getPylonMagazines|getRelDir|getRelPos|getRemoteSensorsDisabled|getRepairCargo|getResolution|getRotorBrakeRTD|getShadowDistance|getShotParents|getSlingLoad|getSoundController|getSoundControllerResult|getSpeed|getStamina|getStatValue|getSuppression|getTerrainGrid|getTerrainHeightASL|getText|getTotalDLCUsageTime|getTrimOffsetRTD|getUnitLoadout|getUnitTrait|getUserMFDText|getUserMFDValue|getVariable|getVehicleCargo|getWeaponCargo|getWeaponSway|getWingsOrientationRTD|getWingsPositionRTD|getWPPos|glanceAt|globalChat|globalRadio|goggles|group|groupChat|groupFromNetId|groupIconSelectable|groupIconsVisible|groupId|groupOwner|groupRadio|groupSelectedUnits|groupSelectUnit|grpNull|gunner|gusts|halt|handgunItems|handgunMagazine|handgunWeapon|handsHit|hasInterface|hasPilotCamera|hasWeapon|hcAllGroups|hcGroupParams|hcLeader|hcRemoveAllGroups|hcRemoveGroup|hcSelected|hcSelectGroup|hcSetGroup|hcShowBar|hcShownBar|headgear|hideBody|hideObject|hideObjectGlobal|hideSelection|hint|hintC|hintCadet|hintSilent|hmd|hostMission|htmlLoad|HUDMovementLevels|humidity|image|importAllGroups|importance|in|inArea|inAreaArray|incapacitatedState|independent|inflame|inflamed|infoPanel|infoPanelComponentEnabled|infoPanelComponents|infoPanels|inGameUISetEventHandler|inheritsFrom|initAmbientLife|inPolygon|inputAction|inRangeOfArtillery|insertEditorObject|intersect|is3DEN|is3DENMultiplayer|isAbleToBreathe|isAgent|isAimPrecisionEnabled|isArray|isAutoHoverOn|isAutonomous|isAutoStartUpEnabledRTD|isAutotest|isAutoTrimOnRTD|isBleeding|isBurning|isClass|isCollisionLightOn|isCopilotEnabled|isDamageAllowed|isDedicated|isDLCAvailable|isEngineOn|isEqualTo|isEqualType|isEqualTypeAll|isEqualTypeAny|isEqualTypeArray|isEqualTypeParams|isFilePatchingEnabled|isFlashlightOn|isFlatEmpty|isForcedWalk|isFormationLeader|isGroupDeletedWhenEmpty|isHidden|isInRemainsCollector|isInstructorFigureEnabled|isIRLaserOn|isKeyActive|isKindOf|isLaserOn|isLightOn|isLocalized|isManualFire|isMarkedForCollection|isMultiplayer|isMultiplayerSolo|isNil|isNull|isNumber|isObjectHidden|isObjectRTD|isOnRoad|isPipEnabled|isPlayer|isRealTime|isRemoteExecuted|isRemoteExecutedJIP|isServer|isShowing3DIcons|isSimpleObject|isSprintAllowed|isStaminaEnabled|isSteamMission|isStreamFriendlyUIEnabled|isStressDamageEnabled|isText|isTouchingGround|isTurnedOut|isTutHintsEnabled|isUAVConnectable|isUAVConnected|isUIContext|isUniformAllowed|isVehicleCargo|isVehicleRadarOn|isVehicleSensorEnabled|isWalking|isWeaponDeployed|isWeaponRested|itemCargo|items|itemsWithMagazines|join|joinAs|joinAsSilent|joinSilent|joinString|kbAddDatabase|kbAddDatabaseTargets|kbAddTopic|kbHasTopic|kbReact|kbRemoveTopic|kbTell|kbWasSaid|keyImage|keyName|knowsAbout|land|landAt|landResult|language|laserTarget|lbAdd|lbClear|lbColor|lbColorRight|lbCurSel|lbData|lbDelete|lbIsSelected|lbPicture|lbPictureRight|lbSelection|lbSetColor|lbSetColorRight|lbSetCurSel|lbSetData|lbSetPicture|lbSetPictureColor|lbSetPictureColorDisabled|lbSetPictureColorSelected|lbSetPictureRight|lbSetPictureRightColor|lbSetPictureRightColorDisabled|lbSetPictureRightColorSelected|lbSetSelectColor|lbSetSelectColorRight|lbSetSelected|lbSetText|lbSetTextRight|lbSetTooltip|lbSetValue|lbSize|lbSort|lbSortByValue|lbText|lbTextRight|lbValue|leader|leaderboardDeInit|leaderboardGetRows|leaderboardInit|leaderboardRequestRowsFriends|leaderboardRequestRowsGlobal|leaderboardRequestRowsGlobalAroundUser|leaderboardsRequestUploadScore|leaderboardsRequestUploadScoreKeepBest|leaderboardState|leaveVehicle|libraryCredits|libraryDisclaimers|lifeState|lightAttachObject|lightDetachObject|lightIsOn|lightnings|limitSpeed|linearConversion|lineBreak|lineIntersects|lineIntersectsObjs|lineIntersectsSurfaces|lineIntersectsWith|linkItem|list|listObjects|listRemoteTargets|listVehicleSensors|ln|lnbAddArray|lnbAddColumn|lnbAddRow|lnbClear|lnbColor|lnbColorRight|lnbCurSelRow|lnbData|lnbDeleteColumn|lnbDeleteRow|lnbGetColumnsPosition|lnbPicture|lnbPictureRight|lnbSetColor|lnbSetColorRight|lnbSetColumnsPos|lnbSetCurSelRow|lnbSetData|lnbSetPicture|lnbSetPictureColor|lnbSetPictureColorRight|lnbSetPictureColorSelected|lnbSetPictureColorSelectedRight|lnbSetPictureRight|lnbSetText|lnbSetTextRight|lnbSetValue|lnbSize|lnbSort|lnbSortByValue|lnbText|lnbTextRight|lnbValue|load|loadAbs|loadBackpack|loadFile|loadGame|loadIdentity|loadMagazine|loadOverlay|loadStatus|loadUniform|loadVest|local|localize|locationNull|locationPosition|lock|lockCameraTo|lockCargo|lockDriver|locked|lockedCargo|lockedDriver|lockedTurret|lockIdentity|lockTurret|lockWP|log|logEntities|logNetwork|logNetworkTerminate|lookAt|lookAtPos|magazineCargo|magazines|magazinesAllTurrets|magazinesAmmo|magazinesAmmoCargo|magazinesAmmoFull|magazinesDetail|magazinesDetailBackpack|magazinesDetailUniform|magazinesDetailVest|magazinesTurret|magazineTurretAmmo|mapAnimAdd|mapAnimClear|mapAnimCommit|mapAnimDone|mapCenterOnCamera|mapGridPosition|markAsFinishedOnSteam|markerAlpha|markerBrush|markerColor|markerDir|markerPos|markerShape|markerSize|markerText|markerType|max|members|menuAction|menuAdd|menuChecked|menuClear|menuCollapse|menuData|menuDelete|menuEnable|menuEnabled|menuExpand|menuHover|menuPicture|menuSetAction|menuSetCheck|menuSetData|menuSetPicture|menuSetValue|menuShortcut|menuShortcutText|menuSize|menuSort|menuText|menuURL|menuValue|min|mineActive|mineDetectedBy|missionConfigFile|missionDifficulty|missionName|missionNamespace|missionStart|missionVersion|modelToWorld|modelToWorldVisual|modelToWorldVisualWorld|modelToWorldWorld|modParams|moonIntensity|moonPhase|morale|move|move3DENCamera|moveInAny|moveInCargo|moveInCommander|moveInDriver|moveInGunner|moveInTurret|moveObjectToEnd|moveOut|moveTime|moveTo|moveToCompleted|moveToFailed|musicVolume|name|nameSound|nearEntities|nearestBuilding|nearestLocation|nearestLocations|nearestLocationWithDubbing|nearestObject|nearestObjects|nearestTerrainObjects|nearObjects|nearObjectsReady|nearRoads|nearSupplies|nearTargets|needReload|netId|netObjNull|newOverlay|nextMenuItemIndex|nextWeatherChange|nMenuItems|numberOfEnginesRTD|numberToDate|objectCurators|objectFromNetId|objectParent|objNull|objStatus|onBriefingGear|onBriefingGroup|onBriefingNotes|onBriefingPlan|onBriefingTeamSwitch|onCommandModeChanged|onDoubleClick|onEachFrame|onGroupIconClick|onGroupIconOverEnter|onGroupIconOverLeave|onHCGroupSelectionChanged|onMapSingleClick|onPlayerConnected|onPlayerDisconnected|onPreloadFinished|onPreloadStarted|onShowNewObject|onTeamSwitch|openCuratorInterface|openDLCPage|openDSInterface|openMap|openSteamApp|openYoutubeVideo|opfor|orderGetIn|overcast|overcastForecast|owner|param|params|parseNumber|parseSimpleArray|parseText|parsingNamespace|particlesQuality|pi|pickWeaponPool|pitch|pixelGrid|pixelGridBase|pixelGridNoUIScale|pixelH|pixelW|playableSlotsNumber|playableUnits|playAction|playActionNow|player|playerRespawnTime|playerSide|playersNumber|playGesture|playMission|playMove|playMoveNow|playMusic|playScriptedMission|playSound|playSound3D|position|positionCameraToWorld|posScreenToWorld|posWorldToScreen|ppEffectAdjust|ppEffectCommit|ppEffectCommitted|ppEffectCreate|ppEffectDestroy|ppEffectEnable|ppEffectEnabled|ppEffectForceInNVG|precision|preloadCamera|preloadObject|preloadSound|preloadTitleObj|preloadTitleRsc|primaryWeapon|primaryWeaponItems|primaryWeaponMagazine|priority|processDiaryLink|processInitCommands|productVersion|profileName|profileNamespace|profileNameSteam|progressLoadingScreen|progressPosition|progressSetPosition|publicVariable|publicVariableClient|publicVariableServer|pushBack|pushBackUnique|putWeaponPool|queryItemsPool|queryMagazinePool|queryWeaponPool|rad|radioChannelAdd|radioChannelCreate|radioChannelRemove|radioChannelSetCallSign|radioChannelSetLabel|radioVolume|rain|rainbow|random|rank|rankId|rating|rectangular|registeredTasks|registerTask|reload|reloadEnabled|remoteControl|remoteExec|remoteExecCall|remoteExecutedOwner|remove3DENConnection|remove3DENEventHandler|remove3DENLayer|removeAction|removeAll3DENEventHandlers|removeAllActions|removeAllAssignedItems|removeAllContainers|removeAllCuratorAddons|removeAllCuratorCameraAreas|removeAllCuratorEditingAreas|removeAllEventHandlers|removeAllHandgunItems|removeAllItems|removeAllItemsWithMagazines|removeAllMissionEventHandlers|removeAllMPEventHandlers|removeAllMusicEventHandlers|removeAllOwnedMines|removeAllPrimaryWeaponItems|removeAllWeapons|removeBackpack|removeBackpackGlobal|removeCuratorAddons|removeCuratorCameraArea|removeCuratorEditableObjects|removeCuratorEditingArea|removeDrawIcon|removeDrawLinks|removeEventHandler|removeFromRemainsCollector|removeGoggles|removeGroupIcon|removeHandgunItem|removeHeadgear|removeItem|removeItemFromBackpack|removeItemFromUniform|removeItemFromVest|removeItems|removeMagazine|removeMagazineGlobal|removeMagazines|removeMagazinesTurret|removeMagazineTurret|removeMenuItem|removeMissionEventHandler|removeMPEventHandler|removeMusicEventHandler|removeOwnedMine|removePrimaryWeaponItem|removeSecondaryWeaponItem|removeSimpleTask|removeSwitchableUnit|removeTeamMember|removeUniform|removeVest|removeWeapon|removeWeaponAttachmentCargo|removeWeaponCargo|removeWeaponGlobal|removeWeaponTurret|reportRemoteTarget|requiredVersion|resetCamShake|resetSubgroupDirection|resistance|resize|resources|respawnVehicle|restartEditorCamera|reveal|revealMine|reverse|reversedMouseY|roadAt|roadsConnectedTo|roleDescription|ropeAttachedObjects|ropeAttachedTo|ropeAttachEnabled|ropeAttachTo|ropeCreate|ropeCut|ropeDestroy|ropeDetach|ropeEndPosition|ropeLength|ropes|ropeUnwind|ropeUnwound|rotorsForcesRTD|rotorsRpmRTD|round|runInitScript|safeZoneH|safeZoneW|safeZoneWAbs|safeZoneX|safeZoneXAbs|safeZoneY|save3DENInventory|saveGame|saveIdentity|saveJoysticks|saveOverlay|saveProfileNamespace|saveStatus|saveVar|savingEnabled|say|say2D|say3D|score|scoreSide|screenshot|screenToWorld|scriptDone|scriptName|scriptNull|scudState|secondaryWeapon|secondaryWeaponItems|secondaryWeaponMagazine|select|selectBestPlaces|selectDiarySubject|selectedEditorObjects|selectEditorObject|selectionNames|selectionPosition|selectLeader|selectMax|selectMin|selectNoPlayer|selectPlayer|selectRandom|selectRandomWeighted|selectWeapon|selectWeaponTurret|sendAUMessage|sendSimpleCommand|sendTask|sendTaskResult|sendUDPMessage|serverCommand|serverCommandAvailable|serverCommandExecutable|serverName|serverTime|set|set3DENAttribute|set3DENAttributes|set3DENGrid|set3DENIconsVisible|set3DENLayer|set3DENLinesVisible|set3DENLogicType|set3DENMissionAttribute|set3DENMissionAttributes|set3DENModelsVisible|set3DENObjectType|set3DENSelected|setAccTime|setActualCollectiveRTD|setAirplaneThrottle|setAirportSide|setAmmo|setAmmoCargo|setAmmoOnPylon|setAnimSpeedCoef|setAperture|setApertureNew|setArmoryPoints|setAttributes|setAutonomous|setBehaviour|setBleedingRemaining|setBrakesRTD|setCameraInterest|setCamShakeDefParams|setCamShakeParams|setCamUseTI|setCaptive|setCenterOfMass|setCollisionLight|setCombatMode|setCompassOscillation|setConvoySeparation|setCuratorCameraAreaCeiling|setCuratorCoef|setCuratorEditingAreaType|setCuratorWaypointCost|setCurrentChannel|setCurrentTask|setCurrentWaypoint|setCustomAimCoef|setCustomWeightRTD|setDamage|setDammage|setDate|setDebriefingText|setDefaultCamera|setDestination|setDetailMapBlendPars|setDir|setDirection|setDrawIcon|setDriveOnPath|setDropInterval|setDynamicSimulationDistance|setDynamicSimulationDistanceCoef|setEditorMode|setEditorObjectScope|setEffectCondition|setEngineRpmRTD|setFace|setFaceAnimation|setFatigue|setFeatureType|setFlagAnimationPhase|setFlagOwner|setFlagSide|setFlagTexture|setFog|setForceGeneratorRTD|setFormation|setFormationTask|setFormDir|setFriend|setFromEditor|setFSMVariable|setFuel|setFuelCargo|setGroupIcon|setGroupIconParams|setGroupIconsSelectable|setGroupIconsVisible|setGroupId|setGroupIdGlobal|setGroupOwner|setGusts|setHideBehind|setHit|setHitIndex|setHitPointDamage|setHorizonParallaxCoef|setHUDMovementLevels|setIdentity|setImportance|setInfoPanel|setLeader|setLightAmbient|setLightAttenuation|setLightBrightness|setLightColor|setLightDayLight|setLightFlareMaxDistance|setLightFlareSize|setLightIntensity|setLightnings|setLightUseFlare|setLocalWindParams|setMagazineTurretAmmo|setMarkerAlpha|setMarkerAlphaLocal|setMarkerBrush|setMarkerBrushLocal|setMarkerColor|setMarkerColorLocal|setMarkerDir|setMarkerDirLocal|setMarkerPos|setMarkerPosLocal|setMarkerShape|setMarkerShapeLocal|setMarkerSize|setMarkerSizeLocal|setMarkerText|setMarkerTextLocal|setMarkerType|setMarkerTypeLocal|setMass|setMimic|setMousePosition|setMusicEffect|setMusicEventHandler|setName|setNameSound|setObjectArguments|setObjectMaterial|setObjectMaterialGlobal|setObjectProxy|setObjectTexture|setObjectTextureGlobal|setObjectViewDistance|setOvercast|setOwner|setOxygenRemaining|setParticleCircle|setParticleClass|setParticleFire|setParticleParams|setParticleRandom|setPilotCameraDirection|setPilotCameraRotation|setPilotCameraTarget|setPilotLight|setPiPEffect|setPitch|setPlateNumber|setPlayable|setPlayerRespawnTime|setPos|setPosASL|setPosASL2|setPosASLW|setPosATL|setPosition|setPosWorld|setPylonLoadOut|setPylonsPriority|setRadioMsg|setRain|setRainbow|setRandomLip|setRank|setRectangular|setRepairCargo|setRotorBrakeRTD|setShadowDistance|setShotParents|setSide|setSimpleTaskAlwaysVisible|setSimpleTaskCustomData|setSimpleTaskDescription|setSimpleTaskDestination|setSimpleTaskTarget|setSimpleTaskType|setSimulWeatherLayers|setSize|setSkill|setSlingLoad|setSoundEffect|setSpeaker|setSpeech|setSpeedMode|setStamina|setStaminaScheme|setStatValue|setSuppression|setSystemOfUnits|setTargetAge|setTaskMarkerOffset|setTaskResult|setTaskState|setTerrainGrid|setText|setTimeMultiplier|setTitleEffect|setToneMapping|setToneMappingParams|setTrafficDensity|setTrafficDistance|setTrafficGap|setTrafficSpeed|setTriggerActivation|setTriggerArea|setTriggerStatements|setTriggerText|setTriggerTimeout|setTriggerType|setType|setUnconscious|setUnitAbility|setUnitLoadout|setUnitPos|setUnitPosWeak|setUnitRank|setUnitRecoilCoefficient|setUnitTrait|setUnloadInCombat|setUserActionText|setUserMFDText|setUserMFDValue|setVariable|setVectorDir|setVectorDirAndUp|setVectorUp|setVehicleAmmo|setVehicleAmmoDef|setVehicleArmor|setVehicleCargo|setVehicleId|setVehicleInit|setVehicleLock|setVehiclePosition|setVehicleRadar|setVehicleReceiveRemoteTargets|setVehicleReportOwnPosition|setVehicleReportRemoteTargets|setVehicleTIPars|setVehicleVarName|setVelocity|setVelocityModelSpace|setVelocityTransformation|setViewDistance|setVisibleIfTreeCollapsed|setWantedRpmRTD|setWaves|setWaypointBehaviour|setWaypointCombatMode|setWaypointCompletionRadius|setWaypointDescription|setWaypointForceBehaviour|setWaypointFormation|setWaypointHousePosition|setWaypointLoiterRadius|setWaypointLoiterType|setWaypointName|setWaypointPosition|setWaypointScript|setWaypointSpeed|setWaypointStatements|setWaypointTimeout|setWaypointType|setWaypointVisible|setWeaponReloadingTime|setWind|setWindDir|setWindForce|setWindStr|setWingForceScaleRTD|setWPPos|show3DIcons|showChat|showCinemaBorder|showCommandingMenu|showCompass|showCuratorCompass|showGPS|showHUD|showLegend|showMap|shownArtilleryComputer|shownChat|shownCompass|shownCuratorCompass|showNewEditorObject|shownGPS|shownHUD|shownMap|shownPad|shownRadio|shownScoretable|shownUAVFeed|shownWarrant|shownWatch|showPad|showRadio|showScoretable|showSubtitles|showUAVFeed|showWarrant|showWatch|showWaypoint|showWaypoints|side|sideAmbientLife|sideChat|sideEmpty|sideEnemy|sideFriendly|sideLogic|sideRadio|sideUnknown|simpleTasks|simulationEnabled|simulCloudDensity|simulCloudOcclusion|simulInClouds|simulWeatherSync|sin|size|sizeOf|skill|skillFinal|skipTime|sleep|sliderPosition|sliderRange|sliderSetPosition|sliderSetRange|sliderSetSpeed|sliderSpeed|slingLoadAssistantShown|soldierMagazines|someAmmo|sort|soundVolume|speaker|speed|speedMode|splitString|sqrt|squadParams|stance|startLoadingScreen|stop|stopEngineRTD|stopped|str|sunOrMoon|supportInfo|suppressFor|surfaceIsWater|surfaceNormal|surfaceType|swimInDepth|switchableUnits|switchAction|switchCamera|switchGesture|switchLight|switchMove|synchronizedObjects|synchronizedTriggers|synchronizedWaypoints|synchronizeObjectsAdd|synchronizeObjectsRemove|synchronizeTrigger|synchronizeWaypoint|systemChat|systemOfUnits|tan|targetKnowledge|targets|targetsAggregate|targetsQuery|taskAlwaysVisible|taskChildren|taskCompleted|taskCustomData|taskDescription|taskDestination|taskHint|taskMarkerOffset|taskNull|taskParent|taskResult|taskState|taskType|teamMember|teamMemberNull|teamName|teams|teamSwitch|teamSwitchEnabled|teamType|terminate|terrainIntersect|terrainIntersectASL|terrainIntersectAtASL|text|textLog|textLogFormat|tg|time|timeMultiplier|titleCut|titleFadeOut|titleObj|titleRsc|titleText|toArray|toFixed|toLower|toString|toUpper|triggerActivated|triggerActivation|triggerArea|triggerAttachedVehicle|triggerAttachObject|triggerAttachVehicle|triggerDynamicSimulation|triggerStatements|triggerText|triggerTimeout|triggerTimeoutCurrent|triggerType|turretLocal|turretOwner|turretUnit|tvAdd|tvClear|tvCollapse|tvCollapseAll|tvCount|tvCurSel|tvData|tvDelete|tvExpand|tvExpandAll|tvPicture|tvPictureRight|tvSetColor|tvSetCurSel|tvSetData|tvSetPicture|tvSetPictureColor|tvSetPictureColorDisabled|tvSetPictureColorSelected|tvSetPictureRight|tvSetPictureRightColor|tvSetPictureRightColorDisabled|tvSetPictureRightColorSelected|tvSetSelectColor|tvSetText|tvSetTooltip|tvSetValue|tvSort|tvSortByValue|tvText|tvTooltip|tvValue|type|typeName|typeOf|UAVControl|uiNamespace|uiSleep|unassignCurator|unassignItem|unassignTeam|unassignVehicle|underwater|uniform|uniformContainer|uniformItems|uniformMagazines|unitAddons|unitAimPosition|unitAimPositionVisual|unitBackpack|unitIsUAV|unitPos|unitReady|unitRecoilCoefficient|units|unitsBelowHeight|unlinkItem|unlockAchievement|unregisterTask|updateDrawIcon|updateMenuItem|updateObjectTree|useAIOperMapObstructionTest|useAISteeringComponent|useAudioTimeForMoves|userInputDisabled|vectorAdd|vectorCos|vectorCrossProduct|vectorDiff|vectorDir|vectorDirVisual|vectorDistance|vectorDistanceSqr|vectorDotProduct|vectorFromTo|vectorMagnitude|vectorMagnitudeSqr|vectorModelToWorld|vectorModelToWorldVisual|vectorMultiply|vectorNormalized|vectorUp|vectorUpVisual|vectorWorldToModel|vectorWorldToModelVisual|vehicle|vehicleCargoEnabled|vehicleChat|vehicleRadio|vehicleReceiveRemoteTargets|vehicleReportOwnPosition|vehicleReportRemoteTargets|vehicles|vehicleVarName|velocity|velocityModelSpace|verifySignature|vest|vestContainer|vestItems|vestMagazines|viewDistance|visibleCompass|visibleGPS|visibleMap|visiblePosition|visiblePositionASL|visibleScoretable|visibleWatch|waitUntil|waves|waypointAttachedObject|waypointAttachedVehicle|waypointAttachObject|waypointAttachVehicle|waypointBehaviour|waypointCombatMode|waypointCompletionRadius|waypointDescription|waypointForceBehaviour|waypointFormation|waypointHousePosition|waypointLoiterRadius|waypointLoiterType|waypointName|waypointPosition|waypoints|waypointScript|waypointsEnabledUAV|waypointShow|waypointSpeed|waypointStatements|waypointTimeout|waypointTimeoutCurrent|waypointType|waypointVisible|weaponAccessories|weaponAccessoriesCargo|weaponCargo|weaponDirection|weaponInertia|weaponLowered|weapons|weaponsItems|weaponsItemsCargo|weaponState|weaponsTurret|weightRTD|west|WFSideText|wind|windDir|windRTD|windStr|wingsForcesRTD|worldName|worldSize|worldToModel|worldToModelVisual|worldToScreen)\b/i,number:/(?:\$|\b0x)[\da-f]+\b|(?:\B\.\d+|\b\d+(?:\.\d+)?)(?:e[+-]?\d+)?\b/i,operator:/##|>>|&&|\|\||[!=<>]=?|[-+*/%#^]|\b(?:and|mod|not|or)\b/i,"magic-variable":{pattern:/\b(?:this|thisList|thisTrigger|_exception|_fnc_scriptName|_fnc_scriptNameParent|_forEachIndex|_this|_thisEventHandler|_thisFSM|_thisScript|_x)\b/i,alias:"keyword"},constant:/\bDIK(?:_[a-z\d]+)+\b/i}),t.languages.insertBefore("sqf","string",{macro:{pattern:/(^[ \t]*)#[a-z](?:[^\r\n\\]|\\(?:\r\n|[\s\S]))*/im,lookbehind:!0,greedy:!0,alias:"property",inside:{directive:{pattern:/#[a-z]+\b/i,alias:"keyword"},comment:t.languages.sqf.comment}}}),delete t.languages.sqf["class-name"]}return sqf_1}var squirrel_1,hasRequiredSquirrel;function requireSquirrel(){if(hasRequiredSquirrel)return squirrel_1;hasRequiredSquirrel=1,squirrel_1=e,e.displayName="squirrel",e.aliases=[];function e(t){t.languages.squirrel=t.languages.extend("clike",{comment:[t.languages.clike.comment[0],{pattern:/(^|[^\\:])(?:\/\/|#).*/,lookbehind:!0,greedy:!0}],string:{pattern:/(^|[^\\"'@])(?:@"(?:[^"]|"")*"(?!")|"(?:[^\\\r\n"]|\\.)*")/,lookbehind:!0,greedy:!0},"class-name":{pattern:/(\b(?:class|enum|extends|instanceof)\s+)\w+(?:\.\w+)*/,lookbehind:!0,inside:{punctuation:/\./}},keyword:/\b(?:__FILE__|__LINE__|base|break|case|catch|class|clone|const|constructor|continue|default|delete|else|enum|extends|for|foreach|function|if|in|instanceof|local|null|resume|return|static|switch|this|throw|try|typeof|while|yield)\b/,number:/\b(?:0x[0-9a-fA-F]+|\d+(?:\.(?:\d+|[eE][+-]?\d+))?)\b/,operator:/\+\+|--|<=>|<[-<]|>>>?|&&?|\|\|?|[-+*/%!=<>]=?|[~^]|::?/,punctuation:/[(){}\[\],;.]/}),t.languages.insertBefore("squirrel","string",{char:{pattern:/(^|[^\\"'])'(?:[^\\']|\\(?:[xuU][0-9a-fA-F]{0,8}|[\s\S]))'/,lookbehind:!0,greedy:!0}}),t.languages.insertBefore("squirrel","operator",{"attribute-punctuation":{pattern:/<\/|\/>/,alias:"important"},lambda:{pattern:/@(?=\()/,alias:"operator"}})}return squirrel_1}var stan_1,hasRequiredStan;function requireStan(){if(hasRequiredStan)return stan_1;hasRequiredStan=1,stan_1=e,e.displayName="stan",e.aliases=[];function e(t){(function(Ye){var tt=/\b(?:algebra_solver|algebra_solver_newton|integrate_1d|integrate_ode|integrate_ode_bdf|integrate_ode_rk45|map_rect|ode_(?:adams|bdf|ckrk|rk45)(?:_tol)?|ode_adjoint_tol_ctl|reduce_sum|reduce_sum_static)\b/;Ye.languages.stan={comment:/\/\/.*|\/\*[\s\S]*?\*\/|#(?!include).*/,string:{pattern:/"[\x20\x21\x23-\x5B\x5D-\x7E]*"/,greedy:!0},directive:{pattern:/^([ \t]*)#include\b.*/m,lookbehind:!0,alias:"property"},"function-arg":{pattern:RegExp("("+tt.source+/\s*\(\s*/.source+")"+/[a-zA-Z]\w*/.source),lookbehind:!0,alias:"function"},constraint:{pattern:/(\b(?:int|matrix|real|row_vector|vector)\s*)<[^<>]*>/,lookbehind:!0,inside:{expression:{pattern:/(=\s*)\S(?:\S|\s+(?!\s))*?(?=\s*(?:>$|,\s*\w+\s*=))/,lookbehind:!0,inside:null},property:/\b[a-z]\w*(?=\s*=)/i,operator:/=/,punctuation:/^<|>$|,/}},keyword:[{pattern:/\bdata(?=\s*\{)|\b(?:functions|generated|model|parameters|quantities|transformed)\b/,alias:"program-block"},/\b(?:array|break|cholesky_factor_corr|cholesky_factor_cov|complex|continue|corr_matrix|cov_matrix|data|else|for|if|in|increment_log_prob|int|matrix|ordered|positive_ordered|print|real|reject|return|row_vector|simplex|target|unit_vector|vector|void|while)\b/,tt],function:/\b[a-z]\w*(?=\s*\()/i,number:/(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)(?:E[+-]?\d+(?:_\d+)*)?i?(?!\w)/i,boolean:/\b(?:false|true)\b/,operator:/<-|\.[*/]=?|\|\|?|&&|[!=<>+\-*/]=?|['^%~?:]/,punctuation:/[()\[\]{},;]/},Ye.languages.stan.constraint.inside.expression.inside=Ye.languages.stan})(t)}return stan_1}var stylus_1,hasRequiredStylus;function requireStylus(){if(hasRequiredStylus)return stylus_1;hasRequiredStylus=1,stylus_1=e,e.displayName="stylus",e.aliases=[];function e(t){(function(Ye){var tt={pattern:/(\b\d+)(?:%|[a-z]+)/,lookbehind:!0},rt={pattern:/(^|[^\w.-])-?(?:\d+(?:\.\d+)?|\.\d+)/,lookbehind:!0},nt={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|\/\/.*)/,lookbehind:!0},url:{pattern:/\burl\((["']?).*?\1\)/i,greedy:!0},string:{pattern:/("|')(?:(?!\1)[^\\\r\n]|\\(?:\r\n|[\s\S]))*\1/,greedy:!0},interpolation:null,func:null,important:/\B!(?:important|optional)\b/i,keyword:{pattern:/(^|\s+)(?:(?:else|for|if|return|unless)(?=\s|$)|@[\w-]+)/,lookbehind:!0},hexcode:/#[\da-f]{3,6}/i,color:[/\b(?:AliceBlue|AntiqueWhite|Aqua|Aquamarine|Azure|Beige|Bisque|Black|BlanchedAlmond|Blue|BlueViolet|Brown|BurlyWood|CadetBlue|Chartreuse|Chocolate|Coral|CornflowerBlue|Cornsilk|Crimson|Cyan|DarkBlue|DarkCyan|DarkGoldenRod|DarkGr[ae]y|DarkGreen|DarkKhaki|DarkMagenta|DarkOliveGreen|DarkOrange|DarkOrchid|DarkRed|DarkSalmon|DarkSeaGreen|DarkSlateBlue|DarkSlateGr[ae]y|DarkTurquoise|DarkViolet|DeepPink|DeepSkyBlue|DimGr[ae]y|DodgerBlue|FireBrick|FloralWhite|ForestGreen|Fuchsia|Gainsboro|GhostWhite|Gold|GoldenRod|Gr[ae]y|Green|GreenYellow|HoneyDew|HotPink|IndianRed|Indigo|Ivory|Khaki|Lavender|LavenderBlush|LawnGreen|LemonChiffon|LightBlue|LightCoral|LightCyan|LightGoldenRodYellow|LightGr[ae]y|LightGreen|LightPink|LightSalmon|LightSeaGreen|LightSkyBlue|LightSlateGr[ae]y|LightSteelBlue|LightYellow|Lime|LimeGreen|Linen|Magenta|Maroon|MediumAquaMarine|MediumBlue|MediumOrchid|MediumPurple|MediumSeaGreen|MediumSlateBlue|MediumSpringGreen|MediumTurquoise|MediumVioletRed|MidnightBlue|MintCream|MistyRose|Moccasin|NavajoWhite|Navy|OldLace|Olive|OliveDrab|Orange|OrangeRed|Orchid|PaleGoldenRod|PaleGreen|PaleTurquoise|PaleVioletRed|PapayaWhip|PeachPuff|Peru|Pink|Plum|PowderBlue|Purple|Red|RosyBrown|RoyalBlue|SaddleBrown|Salmon|SandyBrown|SeaGreen|SeaShell|Sienna|Silver|SkyBlue|SlateBlue|SlateGr[ae]y|Snow|SpringGreen|SteelBlue|Tan|Teal|Thistle|Tomato|Transparent|Turquoise|Violet|Wheat|White|WhiteSmoke|Yellow|YellowGreen)\b/i,{pattern:/\b(?:hsl|rgb)\(\s*\d{1,3}\s*,\s*\d{1,3}%?\s*,\s*\d{1,3}%?\s*\)\B|\b(?:hsl|rgb)a\(\s*\d{1,3}\s*,\s*\d{1,3}%?\s*,\s*\d{1,3}%?\s*,\s*(?:0|0?\.\d+|1)\s*\)\B/i,inside:{unit:tt,number:rt,function:/[\w-]+(?=\()/,punctuation:/[(),]/}}],entity:/\\[\da-f]{1,8}/i,unit:tt,boolean:/\b(?:false|true)\b/,operator:[/~|[+!\/%<>?=]=?|[-:]=|\*[*=]?|\.{2,3}|&&|\|\||\B-\B|\b(?:and|in|is(?: a| defined| not|nt)?|not|or)\b/],number:rt,punctuation:/[{}()\[\];:,]/};nt.interpolation={pattern:/\{[^\r\n}:]+\}/,alias:"variable",inside:{delimiter:{pattern:/^\{|\}$/,alias:"punctuation"},rest:nt}},nt.func={pattern:/[\w-]+\([^)]*\).*/,inside:{function:/^[^(]+/,rest:nt}},Ye.languages.stylus={"atrule-declaration":{pattern:/(^[ \t]*)@.+/m,lookbehind:!0,inside:{atrule:/^@[\w-]+/,rest:nt}},"variable-declaration":{pattern:/(^[ \t]*)[\w$-]+\s*.?=[ \t]*(?:\{[^{}]*\}|\S.*|$)/m,lookbehind:!0,inside:{variable:/^\S+/,rest:nt}},statement:{pattern:/(^[ \t]*)(?:else|for|if|return|unless)[ \t].+/m,lookbehind:!0,inside:{keyword:/^\S+/,rest:nt}},"property-declaration":{pattern:/((?:^|\{)([ \t]*))(?:[\w-]|\{[^}\r\n]+\})+(?:\s*:\s*|[ \t]+)(?!\s)[^{\r\n]*(?:;|[^{\r\n,]$(?!(?:\r?\n|\r)(?:\{|\2[ \t])))/m,lookbehind:!0,inside:{property:{pattern:/^[^\s:]+/,inside:{interpolation:nt.interpolation}},rest:nt}},selector:{pattern:/(^[ \t]*)(?:(?=\S)(?:[^{}\r\n:()]|::?[\w-]+(?:\([^)\r\n]*\)|(?![\w-]))|\{[^}\r\n]+\})+)(?:(?:\r?\n|\r)(?:\1(?:(?=\S)(?:[^{}\r\n:()]|::?[\w-]+(?:\([^)\r\n]*\)|(?![\w-]))|\{[^}\r\n]+\})+)))*(?:,$|\{|(?=(?:\r?\n|\r)(?:\{|\1[ \t])))/m,lookbehind:!0,inside:{interpolation:nt.interpolation,comment:nt.comment,punctuation:/[{},]/}},func:nt.func,string:nt.string,comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|\/\/.*)/,lookbehind:!0,greedy:!0},interpolation:nt.interpolation,punctuation:/[{}()\[\];:.]/}})(t)}return stylus_1}var swift_1,hasRequiredSwift;function requireSwift(){if(hasRequiredSwift)return swift_1;hasRequiredSwift=1,swift_1=e,e.displayName="swift",e.aliases=[];function e(t){t.languages.swift={comment:{pattern:/(^|[^\\:])(?:\/\/.*|\/\*(?:[^/*]|\/(?!\*)|\*(?!\/)|\/\*(?:[^*]|\*(?!\/))*\*\/)*\*\/)/,lookbehind:!0,greedy:!0},"string-literal":[{pattern:RegExp(/(^|[^"#])/.source+"(?:"+/"(?:\\(?:\((?:[^()]|\([^()]*\))*\)|\r\n|[^(])|[^\\\r\n"])*"/.source+"|"+/"""(?:\\(?:\((?:[^()]|\([^()]*\))*\)|[^(])|[^\\"]|"(?!""))*"""/.source+")"+/(?!["#])/.source),lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/(\\\()(?:[^()]|\([^()]*\))*(?=\))/,lookbehind:!0,inside:null},"interpolation-punctuation":{pattern:/^\)|\\\($/,alias:"punctuation"},punctuation:/\\(?=[\r\n])/,string:/[\s\S]+/}},{pattern:RegExp(/(^|[^"#])(#+)/.source+"(?:"+/"(?:\\(?:#+\((?:[^()]|\([^()]*\))*\)|\r\n|[^#])|[^\\\r\n])*?"/.source+"|"+/"""(?:\\(?:#+\((?:[^()]|\([^()]*\))*\)|[^#])|[^\\])*?"""/.source+")\\2"),lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/(\\#+\()(?:[^()]|\([^()]*\))*(?=\))/,lookbehind:!0,inside:null},"interpolation-punctuation":{pattern:/^\)|\\#+\($/,alias:"punctuation"},string:/[\s\S]+/}}],directive:{pattern:RegExp(/#/.source+"(?:"+(/(?:elseif|if)\b/.source+"(?:[ ]*"+/(?:![ \t]*)?(?:\b\w+\b(?:[ \t]*\((?:[^()]|\([^()]*\))*\))?|\((?:[^()]|\([^()]*\))*\))(?:[ \t]*(?:&&|\|\|))?/.source+")+")+"|"+/(?:else|endif)\b/.source+")"),alias:"property",inside:{"directive-name":/^#\w+/,boolean:/\b(?:false|true)\b/,number:/\b\d+(?:\.\d+)*\b/,operator:/!|&&|\|\||[<>]=?/,punctuation:/[(),]/}},literal:{pattern:/#(?:colorLiteral|column|dsohandle|file(?:ID|Literal|Path)?|function|imageLiteral|line)\b/,alias:"constant"},"other-directive":{pattern:/#\w+\b/,alias:"property"},attribute:{pattern:/@\w+/,alias:"atrule"},"function-definition":{pattern:/(\bfunc\s+)\w+/,lookbehind:!0,alias:"function"},label:{pattern:/\b(break|continue)\s+\w+|\b[a-zA-Z_]\w*(?=\s*:\s*(?:for|repeat|while)\b)/,lookbehind:!0,alias:"important"},keyword:/\b(?:Any|Protocol|Self|Type|actor|as|assignment|associatedtype|associativity|async|await|break|case|catch|class|continue|convenience|default|defer|deinit|didSet|do|dynamic|else|enum|extension|fallthrough|fileprivate|final|for|func|get|guard|higherThan|if|import|in|indirect|infix|init|inout|internal|is|isolated|lazy|left|let|lowerThan|mutating|none|nonisolated|nonmutating|open|operator|optional|override|postfix|precedencegroup|prefix|private|protocol|public|repeat|required|rethrows|return|right|safe|self|set|some|static|struct|subscript|super|switch|throw|throws|try|typealias|unowned|unsafe|var|weak|where|while|willSet)\b/,boolean:/\b(?:false|true)\b/,nil:{pattern:/\bnil\b/,alias:"constant"},"short-argument":/\$\d+\b/,omit:{pattern:/\b_\b/,alias:"keyword"},number:/\b(?:[\d_]+(?:\.[\de_]+)?|0x[a-f0-9_]+(?:\.[a-f0-9p_]+)?|0b[01_]+|0o[0-7_]+)\b/i,"class-name":/\b[A-Z](?:[A-Z_\d]*[a-z]\w*)?\b/,function:/\b[a-z_]\w*(?=\s*\()/i,constant:/\b(?:[A-Z_]{2,}|k[A-Z][A-Za-z_]+)\b/,operator:/[-+*/%=!<>&|^~?]+|\.[.\-+*/%=!<>&|^~?]+/,punctuation:/[{}[\]();,.:\\]/},t.languages.swift["string-literal"].forEach(function(Ye){Ye.inside.interpolation.inside=t.languages.swift})}return swift_1}var systemd_1,hasRequiredSystemd;function requireSystemd(){if(hasRequiredSystemd)return systemd_1;hasRequiredSystemd=1,systemd_1=e,e.displayName="systemd",e.aliases=[];function e(t){(function(Ye){var tt={pattern:/^[;#].*/m,greedy:!0},rt=/"(?:[^\r\n"\\]|\\(?:[^\r]|\r\n?))*"(?!\S)/.source;Ye.languages.systemd={comment:tt,section:{pattern:/^\[[^\n\r\[\]]*\](?=[ \t]*$)/m,greedy:!0,inside:{punctuation:/^\[|\]$/,"section-name":{pattern:/[\s\S]+/,alias:"selector"}}},key:{pattern:/^[^\s=]+(?=[ \t]*=)/m,greedy:!0,alias:"attr-name"},value:{pattern:RegExp(/(=[ \t]*(?!\s))/.source+"(?:"+rt+`|(?=[^"\r
814
- ]))(?:`+(/[^\s\\]/.source+'|[ ]+(?:(?![ "])|'+rt+")|"+/\\[\r\n]+(?:[#;].*[\r\n]+)*(?![#;])/.source)+")*"),lookbehind:!0,greedy:!0,alias:"attr-value",inside:{comment:tt,quoted:{pattern:RegExp(/(^|\s)/.source+rt),lookbehind:!0,greedy:!0},punctuation:/\\$/m,boolean:{pattern:/^(?:false|no|off|on|true|yes)$/,greedy:!0}}},punctuation:/=/}})(t)}return systemd_1}var t4Templating_1,hasRequiredT4Templating;function requireT4Templating(){if(hasRequiredT4Templating)return t4Templating_1;hasRequiredT4Templating=1,t4Templating_1=e,e.displayName="t4Templating",e.aliases=[];function e(t){(function(Ye){function tt(nt,at,it){return{pattern:RegExp("<#"+nt+"[\\s\\S]*?#>"),alias:"block",inside:{delimiter:{pattern:RegExp("^<#"+nt+"|#>$"),alias:"important"},content:{pattern:/[\s\S]+/,inside:at,alias:it}}}}function rt(nt){var at=Ye.languages[nt],it="language-"+nt;return{block:{pattern:/<#[\s\S]+?#>/,inside:{directive:tt("@",{"attr-value":{pattern:/=(?:("|')(?:\\[\s\S]|(?!\1)[^\\])*\1|[^\s'">=]+)/,inside:{punctuation:/^=|^["']|["']$/}},keyword:/\b\w+(?=\s)/,"attr-name":/\b\w+/}),expression:tt("=",at,it),"class-feature":tt("\\+",at,it),standard:tt("",at,it)}}}}Ye.languages["t4-templating"]=Object.defineProperty({},"createT4",{value:rt})})(t)}return t4Templating_1}var t4Cs_1,hasRequiredT4Cs;function requireT4Cs(){if(hasRequiredT4Cs)return t4Cs_1;hasRequiredT4Cs=1;var e=requireT4Templating(),t=requireCsharp();t4Cs_1=Ye,Ye.displayName="t4Cs",Ye.aliases=[];function Ye(tt){tt.register(e),tt.register(t),tt.languages.t4=tt.languages["t4-cs"]=tt.languages["t4-templating"].createT4("csharp")}return t4Cs_1}var vbnet_1,hasRequiredVbnet;function requireVbnet(){if(hasRequiredVbnet)return vbnet_1;hasRequiredVbnet=1;var e=requireBasic();vbnet_1=t,t.displayName="vbnet",t.aliases=[];function t(Ye){Ye.register(e),Ye.languages.vbnet=Ye.languages.extend("basic",{comment:[{pattern:/(?:!|REM\b).+/i,inside:{keyword:/^REM/i}},{pattern:/(^|[^\\:])'.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(^|[^"])"(?:""|[^"])*"(?!")/,lookbehind:!0,greedy:!0},keyword:/(?:\b(?:ADDHANDLER|ADDRESSOF|ALIAS|AND|ANDALSO|AS|BEEP|BLOAD|BOOLEAN|BSAVE|BYREF|BYTE|BYVAL|CALL(?: ABSOLUTE)?|CASE|CATCH|CBOOL|CBYTE|CCHAR|CDATE|CDBL|CDEC|CHAIN|CHAR|CHDIR|CINT|CLASS|CLEAR|CLNG|CLOSE|CLS|COBJ|COM|COMMON|CONST|CONTINUE|CSBYTE|CSHORT|CSNG|CSTR|CTYPE|CUINT|CULNG|CUSHORT|DATA|DATE|DECIMAL|DECLARE|DEF(?: FN| SEG|DBL|INT|LNG|SNG|STR)|DEFAULT|DELEGATE|DIM|DIRECTCAST|DO|DOUBLE|ELSE|ELSEIF|END|ENUM|ENVIRON|ERASE|ERROR|EVENT|EXIT|FALSE|FIELD|FILES|FINALLY|FOR(?: EACH)?|FRIEND|FUNCTION|GET|GETTYPE|GETXMLNAMESPACE|GLOBAL|GOSUB|GOTO|HANDLES|IF|IMPLEMENTS|IMPORTS|IN|INHERITS|INPUT|INTEGER|INTERFACE|IOCTL|IS|ISNOT|KEY|KILL|LET|LIB|LIKE|LINE INPUT|LOCATE|LOCK|LONG|LOOP|LSET|ME|MKDIR|MOD|MODULE|MUSTINHERIT|MUSTOVERRIDE|MYBASE|MYCLASS|NAME|NAMESPACE|NARROWING|NEW|NEXT|NOT|NOTHING|NOTINHERITABLE|NOTOVERRIDABLE|OBJECT|OF|OFF|ON(?: COM| ERROR| KEY| TIMER)?|OPEN|OPERATOR|OPTION(?: BASE)?|OPTIONAL|OR|ORELSE|OUT|OVERLOADS|OVERRIDABLE|OVERRIDES|PARAMARRAY|PARTIAL|POKE|PRIVATE|PROPERTY|PROTECTED|PUBLIC|PUT|RAISEEVENT|READ|READONLY|REDIM|REM|REMOVEHANDLER|RESTORE|RESUME|RETURN|RMDIR|RSET|RUN|SBYTE|SELECT(?: CASE)?|SET|SHADOWS|SHARED|SHELL|SHORT|SINGLE|SLEEP|STATIC|STEP|STOP|STRING|STRUCTURE|SUB|SWAP|SYNCLOCK|SYSTEM|THEN|THROW|TIMER|TO|TROFF|TRON|TRUE|TRY|TRYCAST|TYPE|TYPEOF|UINTEGER|ULONG|UNLOCK|UNTIL|USHORT|USING|VIEW PRINT|WAIT|WEND|WHEN|WHILE|WIDENING|WITH|WITHEVENTS|WRITE|WRITEONLY|XOR)|\B(?:#CONST|#ELSE|#ELSEIF|#END|#IF))(?:\$|\b)/i,punctuation:/[,;:(){}]/})}return vbnet_1}var t4Vb_1,hasRequiredT4Vb;function requireT4Vb(){if(hasRequiredT4Vb)return t4Vb_1;hasRequiredT4Vb=1;var e=requireT4Templating(),t=requireVbnet();t4Vb_1=Ye,Ye.displayName="t4Vb",Ye.aliases=[];function Ye(tt){tt.register(e),tt.register(t),tt.languages["t4-vb"]=tt.languages["t4-templating"].createT4("vbnet")}return t4Vb_1}var yaml_1,hasRequiredYaml;function requireYaml(){if(hasRequiredYaml)return yaml_1;hasRequiredYaml=1,yaml_1=e,e.displayName="yaml",e.aliases=["yml"];function e(t){(function(Ye){var tt=/[*&][^\s[\]{},]+/,rt=/!(?:<[\w\-%#;/?:@&=+$,.!~*'()[\]]+>|(?:[a-zA-Z\d-]*!)?[\w\-%#;/?:@&=+$.~*'()]+)?/,nt="(?:"+rt.source+"(?:[ ]+"+tt.source+")?|"+tt.source+"(?:[ ]+"+rt.source+")?)",at=/(?:[^\s\x00-\x08\x0e-\x1f!"#%&'*,\-:>?@[\]`{|}\x7f-\x84\x86-\x9f\ud800-\udfff\ufffe\uffff]|[?:-]<PLAIN>)(?:[ \t]*(?:(?![#:])<PLAIN>|:<PLAIN>))*/.source.replace(/<PLAIN>/g,function(){return/[^\s\x00-\x08\x0e-\x1f,[\]{}\x7f-\x84\x86-\x9f\ud800-\udfff\ufffe\uffff]/.source}),it=/"(?:[^"\\\r\n]|\\.)*"|'(?:[^'\\\r\n]|\\.)*'/.source;function ot(ct,At){At=(At||"").replace(/m/g,"")+"m";var Rt=/([:\-,[{]\s*(?:\s<<prop>>[ \t]+)?)(?:<<value>>)(?=[ \t]*(?:$|,|\]|\}|(?:[\r\n]\s*)?#))/.source.replace(/<<prop>>/g,function(){return nt}).replace(/<<value>>/g,function(){return ct});return RegExp(Rt,At)}Ye.languages.yaml={scalar:{pattern:RegExp(/([\-:]\s*(?:\s<<prop>>[ \t]+)?[|>])[ \t]*(?:((?:\r?\n|\r)[ \t]+)\S[^\r\n]*(?:\2[^\r\n]+)*)/.source.replace(/<<prop>>/g,function(){return nt})),lookbehind:!0,alias:"string"},comment:/#.*/,key:{pattern:RegExp(/((?:^|[:\-,[{\r\n?])[ \t]*(?:<<prop>>[ \t]+)?)<<key>>(?=\s*:\s)/.source.replace(/<<prop>>/g,function(){return nt}).replace(/<<key>>/g,function(){return"(?:"+at+"|"+it+")"})),lookbehind:!0,greedy:!0,alias:"atrule"},directive:{pattern:/(^[ \t]*)%.+/m,lookbehind:!0,alias:"important"},datetime:{pattern:ot(/\d{4}-\d\d?-\d\d?(?:[tT]|[ \t]+)\d\d?:\d{2}:\d{2}(?:\.\d*)?(?:[ \t]*(?:Z|[-+]\d\d?(?::\d{2})?))?|\d{4}-\d{2}-\d{2}|\d\d?:\d{2}(?::\d{2}(?:\.\d*)?)?/.source),lookbehind:!0,alias:"number"},boolean:{pattern:ot(/false|true/.source,"i"),lookbehind:!0,alias:"important"},null:{pattern:ot(/null|~/.source,"i"),lookbehind:!0,alias:"important"},string:{pattern:ot(it),lookbehind:!0,greedy:!0},number:{pattern:ot(/[+-]?(?:0x[\da-f]+|0o[0-7]+|(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?|\.inf|\.nan)/.source,"i"),lookbehind:!0},tag:rt,important:tt,punctuation:/---|[:[\]{}\-,|>?]|\.\.\./},Ye.languages.yml=Ye.languages.yaml})(t)}return yaml_1}var tap_1,hasRequiredTap;function requireTap(){if(hasRequiredTap)return tap_1;hasRequiredTap=1;var e=requireYaml();tap_1=t,t.displayName="tap",t.aliases=[];function t(Ye){Ye.register(e),Ye.languages.tap={fail:/not ok[^#{\n\r]*/,pass:/ok[^#{\n\r]*/,pragma:/pragma [+-][a-z]+/,bailout:/bail out!.*/i,version:/TAP version \d+/i,plan:/\b\d+\.\.\d+(?: +#.*)?/,subtest:{pattern:/# Subtest(?:: .*)?/,greedy:!0},punctuation:/[{}]/,directive:/#.*/,yamlish:{pattern:/(^[ \t]*)---[\s\S]*?[\r\n][ \t]*\.\.\.$/m,lookbehind:!0,inside:Ye.languages.yaml,alias:"language-yaml"}}}return tap_1}var tcl_1,hasRequiredTcl;function requireTcl(){if(hasRequiredTcl)return tcl_1;hasRequiredTcl=1,tcl_1=e,e.displayName="tcl",e.aliases=[];function e(t){t.languages.tcl={comment:{pattern:/(^|[^\\])#.*/,lookbehind:!0},string:{pattern:/"(?:[^"\\\r\n]|\\(?:\r\n|[\s\S]))*"/,greedy:!0},variable:[{pattern:/(\$)(?:::)?(?:[a-zA-Z0-9]+::)*\w+/,lookbehind:!0},{pattern:/(\$)\{[^}]+\}/,lookbehind:!0},{pattern:/(^[\t ]*set[ \t]+)(?:::)?(?:[a-zA-Z0-9]+::)*\w+/m,lookbehind:!0}],function:{pattern:/(^[\t ]*proc[ \t]+)\S+/m,lookbehind:!0},builtin:[{pattern:/(^[\t ]*)(?:break|class|continue|error|eval|exit|for|foreach|if|proc|return|switch|while)\b/m,lookbehind:!0},/\b(?:else|elseif)\b/],scope:{pattern:/(^[\t ]*)(?:global|upvar|variable)\b/m,lookbehind:!0,alias:"constant"},keyword:{pattern:/(^[\t ]*|\[)(?:Safe_Base|Tcl|after|append|apply|array|auto_(?:execok|import|load|mkindex|qualify|reset)|automkindex_old|bgerror|binary|catch|cd|chan|clock|close|concat|dde|dict|encoding|eof|exec|expr|fblocked|fconfigure|fcopy|file(?:event|name)?|flush|gets|glob|history|http|incr|info|interp|join|lappend|lassign|lindex|linsert|list|llength|load|lrange|lrepeat|lreplace|lreverse|lsearch|lset|lsort|math(?:func|op)|memory|msgcat|namespace|open|package|parray|pid|pkg_mkIndex|platform|puts|pwd|re_syntax|read|refchan|regexp|registry|regsub|rename|scan|seek|set|socket|source|split|string|subst|tcl(?:_endOfWord|_findLibrary|startOf(?:Next|Previous)Word|test|vars|wordBreak(?:After|Before))|tell|time|tm|trace|unknown|unload|unset|update|uplevel|vwait)\b/m,lookbehind:!0},operator:/!=?|\*\*?|==|&&?|\|\|?|<[=<]?|>[=>]?|[-+~\/%?^]|\b(?:eq|in|ne|ni)\b/,punctuation:/[{}()\[\]]/}}return tcl_1}var textile_1,hasRequiredTextile;function requireTextile(){if(hasRequiredTextile)return textile_1;hasRequiredTextile=1,textile_1=e,e.displayName="textile",e.aliases=[];function e(t){(function(Ye){var tt=/\([^|()\n]+\)|\[[^\]\n]+\]|\{[^}\n]+\}/.source,rt=/\)|\((?![^|()\n]+\))/.source;function nt(qt,Ft){return RegExp(qt.replace(/<MOD>/g,function(){return"(?:"+tt+")"}).replace(/<PAR>/g,function(){return"(?:"+rt+")"}),Ft||"")}var at={css:{pattern:/\{[^{}]+\}/,inside:{rest:Ye.languages.css}},"class-id":{pattern:/(\()[^()]+(?=\))/,lookbehind:!0,alias:"attr-value"},lang:{pattern:/(\[)[^\[\]]+(?=\])/,lookbehind:!0,alias:"attr-value"},punctuation:/[\\\/]\d+|\S/},it=Ye.languages.textile=Ye.languages.extend("markup",{phrase:{pattern:/(^|\r|\n)\S[\s\S]*?(?=$|\r?\n\r?\n|\r\r)/,lookbehind:!0,inside:{"block-tag":{pattern:nt(/^[a-z]\w*(?:<MOD>|<PAR>|[<>=])*\./.source),inside:{modifier:{pattern:nt(/(^[a-z]\w*)(?:<MOD>|<PAR>|[<>=])+(?=\.)/.source),lookbehind:!0,inside:at},tag:/^[a-z]\w*/,punctuation:/\.$/}},list:{pattern:nt(/^[*#]+<MOD>*\s+\S.*/.source,"m"),inside:{modifier:{pattern:nt(/(^[*#]+)<MOD>+/.source),lookbehind:!0,inside:at},punctuation:/^[*#]+/}},table:{pattern:nt(/^(?:(?:<MOD>|<PAR>|[<>=^~])+\.\s*)?(?:\|(?:(?:<MOD>|<PAR>|[<>=^~_]|[\\/]\d+)+\.|(?!(?:<MOD>|<PAR>|[<>=^~_]|[\\/]\d+)+\.))[^|]*)+\|/.source,"m"),inside:{modifier:{pattern:nt(/(^|\|(?:\r?\n|\r)?)(?:<MOD>|<PAR>|[<>=^~_]|[\\/]\d+)+(?=\.)/.source),lookbehind:!0,inside:at},punctuation:/\||^\./}},inline:{pattern:nt(/(^|[^a-zA-Z\d])(\*\*|__|\?\?|[*_%@+\-^~])<MOD>*.+?\2(?![a-zA-Z\d])/.source),lookbehind:!0,inside:{bold:{pattern:nt(/(^(\*\*?)<MOD>*).+?(?=\2)/.source),lookbehind:!0},italic:{pattern:nt(/(^(__?)<MOD>*).+?(?=\2)/.source),lookbehind:!0},cite:{pattern:nt(/(^\?\?<MOD>*).+?(?=\?\?)/.source),lookbehind:!0,alias:"string"},code:{pattern:nt(/(^@<MOD>*).+?(?=@)/.source),lookbehind:!0,alias:"keyword"},inserted:{pattern:nt(/(^\+<MOD>*).+?(?=\+)/.source),lookbehind:!0},deleted:{pattern:nt(/(^-<MOD>*).+?(?=-)/.source),lookbehind:!0},span:{pattern:nt(/(^%<MOD>*).+?(?=%)/.source),lookbehind:!0},modifier:{pattern:nt(/(^\*\*|__|\?\?|[*_%@+\-^~])<MOD>+/.source),lookbehind:!0,inside:at},punctuation:/[*_%?@+\-^~]+/}},"link-ref":{pattern:/^\[[^\]]+\]\S+$/m,inside:{string:{pattern:/(^\[)[^\]]+(?=\])/,lookbehind:!0},url:{pattern:/(^\])\S+$/,lookbehind:!0},punctuation:/[\[\]]/}},link:{pattern:nt(/"<MOD>*[^"]+":.+?(?=[^\w/]?(?:\s|$))/.source),inside:{text:{pattern:nt(/(^"<MOD>*)[^"]+(?=")/.source),lookbehind:!0},modifier:{pattern:nt(/(^")<MOD>+/.source),lookbehind:!0,inside:at},url:{pattern:/(:).+/,lookbehind:!0},punctuation:/[":]/}},image:{pattern:nt(/!(?:<MOD>|<PAR>|[<>=])*(?![<>=])[^!\s()]+(?:\([^)]+\))?!(?::.+?(?=[^\w/]?(?:\s|$)))?/.source),inside:{source:{pattern:nt(/(^!(?:<MOD>|<PAR>|[<>=])*)(?![<>=])[^!\s()]+(?:\([^)]+\))?(?=!)/.source),lookbehind:!0,alias:"url"},modifier:{pattern:nt(/(^!)(?:<MOD>|<PAR>|[<>=])+/.source),lookbehind:!0,inside:at},url:{pattern:/(:).+/,lookbehind:!0},punctuation:/[!:]/}},footnote:{pattern:/\b\[\d+\]/,alias:"comment",inside:{punctuation:/\[|\]/}},acronym:{pattern:/\b[A-Z\d]+\([^)]+\)/,inside:{comment:{pattern:/(\()[^()]+(?=\))/,lookbehind:!0},punctuation:/[()]/}},mark:{pattern:/\b\((?:C|R|TM)\)/,alias:"comment",inside:{punctuation:/[()]/}}}}}),ot=it.phrase.inside,ct={inline:ot.inline,link:ot.link,image:ot.image,footnote:ot.footnote,acronym:ot.acronym,mark:ot.mark};it.tag.pattern=/<\/?(?!\d)[a-z0-9]+(?:\s+[^\s>\/=]+(?:=(?:("|')(?:\\[\s\S]|(?!\1)[^\\])*\1|[^\s'">=]+))?)*\s*\/?>/i;var At=ot.inline.inside;At.bold.inside=ct,At.italic.inside=ct,At.inserted.inside=ct,At.deleted.inside=ct,At.span.inside=ct;var Rt=ot.table.inside;Rt.inline=ct.inline,Rt.link=ct.link,Rt.image=ct.image,Rt.footnote=ct.footnote,Rt.acronym=ct.acronym,Rt.mark=ct.mark})(t)}return textile_1}var toml_1,hasRequiredToml;function requireToml(){if(hasRequiredToml)return toml_1;hasRequiredToml=1,toml_1=e,e.displayName="toml",e.aliases=[];function e(t){(function(Ye){var tt=/(?:[\w-]+|'[^'\n\r]*'|"(?:\\.|[^\\"\r\n])*")/.source;function rt(nt){return nt.replace(/__/g,function(){return tt})}Ye.languages.toml={comment:{pattern:/#.*/,greedy:!0},table:{pattern:RegExp(rt(/(^[\t ]*\[\s*(?:\[\s*)?)__(?:\s*\.\s*__)*(?=\s*\])/.source),"m"),lookbehind:!0,greedy:!0,alias:"class-name"},key:{pattern:RegExp(rt(/(^[\t ]*|[{,]\s*)__(?:\s*\.\s*__)*(?=\s*=)/.source),"m"),lookbehind:!0,greedy:!0,alias:"property"},string:{pattern:/"""(?:\\[\s\S]|[^\\])*?"""|'''[\s\S]*?'''|'[^'\n\r]*'|"(?:\\.|[^\\"\r\n])*"/,greedy:!0},date:[{pattern:/\b\d{4}-\d{2}-\d{2}(?:[T\s]\d{2}:\d{2}:\d{2}(?:\.\d+)?(?:Z|[+-]\d{2}:\d{2})?)?\b/i,alias:"number"},{pattern:/\b\d{2}:\d{2}:\d{2}(?:\.\d+)?\b/,alias:"number"}],number:/(?:\b0(?:x[\da-zA-Z]+(?:_[\da-zA-Z]+)*|o[0-7]+(?:_[0-7]+)*|b[10]+(?:_[10]+)*))\b|[-+]?\b\d+(?:_\d+)*(?:\.\d+(?:_\d+)*)?(?:[eE][+-]?\d+(?:_\d+)*)?\b|[-+]?\b(?:inf|nan)\b/,boolean:/\b(?:false|true)\b/,punctuation:/[.,=[\]{}]/}})(t)}return toml_1}var tremor_1,hasRequiredTremor;function requireTremor(){if(hasRequiredTremor)return tremor_1;hasRequiredTremor=1,tremor_1=e,e.displayName="tremor",e.aliases=[];function e(t){(function(Ye){Ye.languages.tremor={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:--|\/\/|#).*)/,lookbehind:!0},"interpolated-string":null,extractor:{pattern:/\b[a-z_]\w*\|(?:[^\r\n\\|]|\\(?:\r\n|[\s\S]))*\|/i,greedy:!0,inside:{regex:{pattern:/(^re)\|[\s\S]+/,lookbehind:!0},function:/^\w+/,value:/\|[\s\S]+/}},identifier:{pattern:/`[^`]*`/,greedy:!0},function:/\b[a-z_]\w*(?=\s*(?:::\s*<|\())\b/,keyword:/\b(?:args|as|by|case|config|connect|connector|const|copy|create|default|define|deploy|drop|each|emit|end|erase|event|flow|fn|for|from|group|having|insert|into|intrinsic|let|links|match|merge|mod|move|of|operator|patch|pipeline|recur|script|select|set|sliding|state|stream|to|tumbling|update|use|when|where|window|with)\b/,boolean:/\b(?:false|null|true)\b/i,number:/\b(?:0b[01_]*|0x[0-9a-fA-F_]*|\d[\d_]*(?:\.\d[\d_]*)?(?:[Ee][+-]?[\d_]+)?)\b/,"pattern-punctuation":{pattern:/%(?=[({[])/,alias:"punctuation"},operator:/[-+*\/%~!^]=?|=[=>]?|&[&=]?|\|[|=]?|<<?=?|>>?>?=?|(?:absent|and|not|or|present|xor)\b/,punctuation:/::|[;\[\]()\{\},.:]/};var tt=/#\{(?:[^"{}]|\{[^{}]*\}|"(?:[^"\\\r\n]|\\(?:\r\n|[\s\S]))*")*\}/.source;Ye.languages.tremor["interpolated-string"]={pattern:RegExp(/(^|[^\\])/.source+'(?:"""(?:'+/[^"\\#]|\\[\s\S]|"(?!"")|#(?!\{)/.source+"|"+tt+')*"""|"(?:'+/[^"\\\r\n#]|\\(?:\r\n|[\s\S])|#(?!\{)/.source+"|"+tt+')*")'),lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:RegExp(tt),inside:{punctuation:/^#\{|\}$/,expression:{pattern:/[\s\S]+/,inside:Ye.languages.tremor}}},string:/[\s\S]+/}},Ye.languages.troy=Ye.languages.tremor,Ye.languages.trickle=Ye.languages.tremor})(t)}return tremor_1}var tsx_1,hasRequiredTsx;function requireTsx(){if(hasRequiredTsx)return tsx_1;hasRequiredTsx=1;var e=requireJsx(),t=requireTypescript();tsx_1=Ye,Ye.displayName="tsx",Ye.aliases=[];function Ye(tt){tt.register(e),tt.register(t),function(rt){var nt=rt.util.clone(rt.languages.typescript);rt.languages.tsx=rt.languages.extend("jsx",nt),delete rt.languages.tsx.parameter,delete rt.languages.tsx["literal-property"];var at=rt.languages.tsx.tag;at.pattern=RegExp(/(^|[^\w$]|(?=<\/))/.source+"(?:"+at.pattern.source+")",at.pattern.flags),at.lookbehind=!0}(tt)}return tsx_1}var tt2_1,hasRequiredTt2;function requireTt2(){if(hasRequiredTt2)return tt2_1;hasRequiredTt2=1;var e=requireMarkupTemplating();tt2_1=t,t.displayName="tt2",t.aliases=[];function t(Ye){Ye.register(e),function(tt){tt.languages.tt2=tt.languages.extend("clike",{comment:/#.*|\[%#[\s\S]*?%\]/,keyword:/\b(?:BLOCK|CALL|CASE|CATCH|CLEAR|DEBUG|DEFAULT|ELSE|ELSIF|END|FILTER|FINAL|FOREACH|GET|IF|IN|INCLUDE|INSERT|LAST|MACRO|META|NEXT|PERL|PROCESS|RAWPERL|RETURN|SET|STOP|SWITCH|TAGS|THROW|TRY|UNLESS|USE|WHILE|WRAPPER)\b/,punctuation:/[[\]{},()]/}),tt.languages.insertBefore("tt2","number",{operator:/=[>=]?|!=?|<=?|>=?|&&|\|\|?|\b(?:and|not|or)\b/,variable:{pattern:/\b[a-z]\w*(?:\s*\.\s*(?:\d+|\$?[a-z]\w*))*\b/i}}),tt.languages.insertBefore("tt2","keyword",{delimiter:{pattern:/^(?:\[%|%%)-?|-?%\]$/,alias:"punctuation"}}),tt.languages.insertBefore("tt2","string",{"single-quoted-string":{pattern:/'[^\\']*(?:\\[\s\S][^\\']*)*'/,greedy:!0,alias:"string"},"double-quoted-string":{pattern:/"[^\\"]*(?:\\[\s\S][^\\"]*)*"/,greedy:!0,alias:"string",inside:{variable:{pattern:/\$(?:[a-z]\w*(?:\.(?:\d+|\$?[a-z]\w*))*)/i}}}}),delete tt.languages.tt2.string,tt.hooks.add("before-tokenize",function(rt){var nt=/\[%[\s\S]+?%\]/g;tt.languages["markup-templating"].buildPlaceholders(rt,"tt2",nt)}),tt.hooks.add("after-tokenize",function(rt){tt.languages["markup-templating"].tokenizePlaceholders(rt,"tt2")})}(Ye)}return tt2_1}var twig_1,hasRequiredTwig;function requireTwig(){if(hasRequiredTwig)return twig_1;hasRequiredTwig=1;var e=requireMarkupTemplating();twig_1=t,t.displayName="twig",t.aliases=[];function t(Ye){Ye.register(e),Ye.languages.twig={comment:/^\{#[\s\S]*?#\}$/,"tag-name":{pattern:/(^\{%-?\s*)\w+/,lookbehind:!0,alias:"keyword"},delimiter:{pattern:/^\{[{%]-?|-?[%}]\}$/,alias:"punctuation"},string:{pattern:/("|')(?:\\.|(?!\1)[^\\\r\n])*\1/,inside:{punctuation:/^['"]|['"]$/}},keyword:/\b(?:even|if|odd)\b/,boolean:/\b(?:false|null|true)\b/,number:/\b0x[\dA-Fa-f]+|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[Ee][-+]?\d+)?/,operator:[{pattern:/(\s)(?:and|b-and|b-or|b-xor|ends with|in|is|matches|not|or|same as|starts with)(?=\s)/,lookbehind:!0},/[=<>]=?|!=|\*\*?|\/\/?|\?:?|[-+~%|]/],punctuation:/[()\[\]{}:.,]/},Ye.hooks.add("before-tokenize",function(tt){if(tt.language==="twig"){var rt=/\{(?:#[\s\S]*?#|%[\s\S]*?%|\{[\s\S]*?\})\}/g;Ye.languages["markup-templating"].buildPlaceholders(tt,"twig",rt)}}),Ye.hooks.add("after-tokenize",function(tt){Ye.languages["markup-templating"].tokenizePlaceholders(tt,"twig")})}return twig_1}var typoscript_1,hasRequiredTyposcript;function requireTyposcript(){if(hasRequiredTyposcript)return typoscript_1;hasRequiredTyposcript=1,typoscript_1=e,e.displayName="typoscript",e.aliases=["tsconfig"];function e(t){(function(Ye){var tt=/\b(?:ACT|ACTIFSUB|CARRAY|CASE|CLEARGIF|COA|COA_INT|CONSTANTS|CONTENT|CUR|EDITPANEL|EFFECT|EXT|FILE|FLUIDTEMPLATE|FORM|FRAME|FRAMESET|GIFBUILDER|GMENU|GMENU_FOLDOUT|GMENU_LAYERS|GP|HMENU|HRULER|HTML|IENV|IFSUB|IMAGE|IMGMENU|IMGMENUITEM|IMGTEXT|IMG_RESOURCE|INCLUDE_TYPOSCRIPT|JSMENU|JSMENUITEM|LLL|LOAD_REGISTER|NO|PAGE|RECORDS|RESTORE_REGISTER|TEMPLATE|TEXT|TMENU|TMENUITEM|TMENU_LAYERS|USER|USER_INT|_GIFBUILDER|global|globalString|globalVar)\b/;Ye.languages.typoscript={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0},{pattern:/(^|[^\\:= \t]|(?:^|[^= \t])[ \t]+)\/\/.*/,lookbehind:!0,greedy:!0},{pattern:/(^|[^"'])#.*/,lookbehind:!0,greedy:!0}],function:[{pattern:/<INCLUDE_TYPOSCRIPT:\s*source\s*=\s*(?:"[^"\r\n]*"|'[^'\r\n]*')\s*>/,inside:{string:{pattern:/"[^"\r\n]*"|'[^'\r\n]*'/,inside:{keyword:tt}},keyword:{pattern:/INCLUDE_TYPOSCRIPT/}}},{pattern:/@import\s*(?:"[^"\r\n]*"|'[^'\r\n]*')/,inside:{string:/"[^"\r\n]*"|'[^'\r\n]*'/}}],string:{pattern:/^([^=]*=[< ]?)(?:(?!\]\n).)*/,lookbehind:!0,inside:{function:/\{\$.*\}/,keyword:tt,number:/^\d+$/,punctuation:/[,|:]/}},keyword:tt,number:{pattern:/\b\d+\s*[.{=]/,inside:{operator:/[.{=]/}},tag:{pattern:/\.?[-\w\\]+\.?/,inside:{punctuation:/\./}},punctuation:/[{}[\];(),.:|]/,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/},Ye.languages.tsconfig=Ye.languages.typoscript})(t)}return typoscript_1}var unrealscript_1,hasRequiredUnrealscript;function requireUnrealscript(){if(hasRequiredUnrealscript)return unrealscript_1;hasRequiredUnrealscript=1,unrealscript_1=e,e.displayName="unrealscript",e.aliases=["uc","uscript"];function e(t){t.languages.unrealscript={comment:/\/\/.*|\/\*[\s\S]*?\*\//,string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},category:{pattern:/(\b(?:(?:autoexpand|hide|show)categories|var)\s*\()[^()]+(?=\))/,lookbehind:!0,greedy:!0,alias:"property"},metadata:{pattern:/(\w\s*)<\s*\w+\s*=[^<>|=\r\n]+(?:\|\s*\w+\s*=[^<>|=\r\n]+)*>/,lookbehind:!0,greedy:!0,inside:{property:/\b\w+(?=\s*=)/,operator:/=/,punctuation:/[<>|]/}},macro:{pattern:/`\w+/,alias:"property"},"class-name":{pattern:/(\b(?:class|enum|extends|interface|state(?:\(\))?|struct|within)\s+)\w+/,lookbehind:!0},keyword:/\b(?:abstract|actor|array|auto|autoexpandcategories|bool|break|byte|case|class|classgroup|client|coerce|collapsecategories|config|const|continue|default|defaultproperties|delegate|dependson|deprecated|do|dontcollapsecategories|editconst|editinlinenew|else|enum|event|exec|export|extends|final|float|for|forcescriptorder|foreach|function|goto|guid|hidecategories|hidedropdown|if|ignores|implements|inherits|input|int|interface|iterator|latent|local|material|name|native|nativereplication|noexport|nontransient|noteditinlinenew|notplaceable|operator|optional|out|pawn|perobjectconfig|perobjectlocalized|placeable|postoperator|preoperator|private|protected|reliable|replication|return|server|showcategories|simulated|singular|state|static|string|struct|structdefault|structdefaultproperties|switch|texture|transient|travel|unreliable|until|var|vector|while|within)\b/,function:/\b[a-z_]\w*(?=\s*\()/i,boolean:/\b(?:false|true)\b/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/>>|<<|--|\+\+|\*\*|[-+*/~!=<>$@]=?|&&?|\|\|?|\^\^?|[?:%]|\b(?:ClockwiseFrom|Cross|Dot)\b/,punctuation:/[()[\]{};,.]/},t.languages.uc=t.languages.uscript=t.languages.unrealscript}return unrealscript_1}var uorazor_1,hasRequiredUorazor;function requireUorazor(){if(hasRequiredUorazor)return uorazor_1;hasRequiredUorazor=1,uorazor_1=e,e.displayName="uorazor",e.aliases=[];function e(t){t.languages.uorazor={"comment-hash":{pattern:/#.*/,alias:"comment",greedy:!0},"comment-slash":{pattern:/\/\/.*/,alias:"comment",greedy:!0},string:{pattern:/("|')(?:\\.|(?!\1)[^\\\r\n])*\1/,inside:{punctuation:/^['"]|['"]$/},greedy:!0},"source-layers":{pattern:/\b(?:arms|backpack|blue|bracelet|cancel|clear|cloak|criminal|earrings|enemy|facialhair|friend|friendly|gloves|gray|grey|ground|hair|head|innerlegs|innertorso|innocent|lefthand|middletorso|murderer|neck|nonfriendly|onehandedsecondary|outerlegs|outertorso|pants|red|righthand|ring|self|shirt|shoes|talisman|waist)\b/i,alias:"function"},"source-commands":{pattern:/\b(?:alliance|attack|cast|clearall|clearignore|clearjournal|clearlist|clearsysmsg|createlist|createtimer|dclick|dclicktype|dclickvar|dress|dressconfig|drop|droprelloc|emote|getlabel|guild|gumpclose|gumpresponse|hotkey|ignore|lasttarget|lift|lifttype|menu|menuresponse|msg|org|organize|organizer|overhead|pause|poplist|potion|promptresponse|pushlist|removelist|removetimer|rename|restock|say|scav|scavenger|script|setability|setlasttarget|setskill|settimer|setvar|sysmsg|target|targetloc|targetrelloc|targettype|undress|unignore|unsetvar|useobject|useonce|useskill|usetype|virtue|wait|waitforgump|waitformenu|waitforprompt|waitforstat|waitforsysmsg|waitfortarget|walk|wfsysmsg|wft|whisper|yell)\b/,alias:"function"},"tag-name":{pattern:/(^\{%-?\s*)\w+/,lookbehind:!0,alias:"keyword"},delimiter:{pattern:/^\{[{%]-?|-?[%}]\}$/,alias:"punctuation"},function:/\b(?:atlist|close|closest|count|counter|counttype|dead|dex|diffhits|diffmana|diffstam|diffweight|find|findbuff|finddebuff|findlayer|findtype|findtypelist|followers|gumpexists|hidden|hits|hp|hue|human|humanoid|ingump|inlist|insysmessage|insysmsg|int|invul|lhandempty|list|listexists|mana|maxhits|maxhp|maxmana|maxstam|maxweight|monster|mounted|name|next|noto|paralyzed|poisoned|position|prev|previous|queued|rand|random|rhandempty|skill|stam|str|targetexists|timer|timerexists|varexist|warmode|weight)\b/,keyword:/\b(?:and|as|break|continue|else|elseif|endfor|endif|endwhile|for|if|loop|not|or|replay|stop|while)\b/,boolean:/\b(?:false|null|true)\b/,number:/\b0x[\dA-Fa-f]+|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[Ee][-+]?\d+)?/,operator:[{pattern:/(\s)(?:and|b-and|b-or|b-xor|ends with|in|is|matches|not|or|same as|starts with)(?=\s)/,lookbehind:!0},/[=<>]=?|!=|\*\*?|\/\/?|\?:?|[-+~%|]/],punctuation:/[()\[\]{}:.,]/}}return uorazor_1}var uri_1,hasRequiredUri$1;function requireUri$1(){if(hasRequiredUri$1)return uri_1;hasRequiredUri$1=1,uri_1=e,e.displayName="uri",e.aliases=["url"];function e(t){t.languages.uri={scheme:{pattern:/^[a-z][a-z0-9+.-]*:/im,greedy:!0,inside:{"scheme-delimiter":/:$/}},fragment:{pattern:/#[\w\-.~!$&'()*+,;=%:@/?]*/,inside:{"fragment-delimiter":/^#/}},query:{pattern:/\?[\w\-.~!$&'()*+,;=%:@/?]*/,inside:{"query-delimiter":{pattern:/^\?/,greedy:!0},"pair-delimiter":/[&;]/,pair:{pattern:/^[^=][\s\S]*/,inside:{key:/^[^=]+/,value:{pattern:/(^=)[\s\S]+/,lookbehind:!0}}}}},authority:{pattern:RegExp(/^\/\//.source+/(?:[\w\-.~!$&'()*+,;=%:]*@)?/.source+("(?:"+/\[(?:[0-9a-fA-F:.]{2,48}|v[0-9a-fA-F]+\.[\w\-.~!$&'()*+,;=]+)\]/.source+"|"+/[\w\-.~!$&'()*+,;=%]*/.source+")")+/(?::\d*)?/.source,"m"),inside:{"authority-delimiter":/^\/\//,"user-info-segment":{pattern:/^[\w\-.~!$&'()*+,;=%:]*@/,inside:{"user-info-delimiter":/@$/,"user-info":/^[\w\-.~!$&'()*+,;=%:]+/}},"port-segment":{pattern:/:\d*$/,inside:{"port-delimiter":/^:/,port:/^\d+/}},host:{pattern:/[\s\S]+/,inside:{"ip-literal":{pattern:/^\[[\s\S]+\]$/,inside:{"ip-literal-delimiter":/^\[|\]$/,"ipv-future":/^v[\s\S]+/,"ipv6-address":/^[\s\S]+/}},"ipv4-address":/^(?:(?:[03-9]\d?|[12]\d{0,2})\.){3}(?:[03-9]\d?|[12]\d{0,2})$/}}}},path:{pattern:/^[\w\-.~!$&'()*+,;=%:@/]+/m,inside:{"path-separator":/\//}}},t.languages.url=t.languages.uri}return uri_1}var v_1,hasRequiredV;function requireV(){if(hasRequiredV)return v_1;hasRequiredV=1,v_1=e,e.displayName="v",e.aliases=[];function e(t){(function(Ye){var tt={pattern:/[\s\S]+/,inside:null};Ye.languages.v=Ye.languages.extend("clike",{string:{pattern:/r?(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,alias:"quoted-string",greedy:!0,inside:{interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$(?:\{[^{}]*\}|\w+(?:\.\w+(?:\([^\(\)]*\))?|\[[^\[\]]+\])*)/,lookbehind:!0,inside:{"interpolation-variable":{pattern:/^\$\w[\s\S]*$/,alias:"variable"},"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},"interpolation-expression":tt}}}},"class-name":{pattern:/(\b(?:enum|interface|struct|type)\s+)(?:C\.)?\w+/,lookbehind:!0},keyword:/(?:\b(?:__global|as|asm|assert|atomic|break|chan|const|continue|defer|else|embed|enum|fn|for|go(?:to)?|if|import|in|interface|is|lock|match|module|mut|none|or|pub|return|rlock|select|shared|sizeof|static|struct|type(?:of)?|union|unsafe)|\$(?:else|for|if)|#(?:flag|include))\b/,number:/\b(?:0x[a-f\d]+(?:_[a-f\d]+)*|0b[01]+(?:_[01]+)*|0o[0-7]+(?:_[0-7]+)*|\d+(?:_\d+)*(?:\.\d+(?:_\d+)*)?)\b/i,operator:/~|\?|[*\/%^!=]=?|\+[=+]?|-[=-]?|\|[=|]?|&(?:=|&|\^=?)?|>(?:>=?|=)?|<(?:<=?|=|-)?|:=|\.\.\.?/,builtin:/\b(?:any(?:_float|_int)?|bool|byte(?:ptr)?|charptr|f(?:32|64)|i(?:8|16|64|128|nt)|rune|size_t|string|u(?:16|32|64|128)|voidptr)\b/}),tt.inside=Ye.languages.v,Ye.languages.insertBefore("v","string",{char:{pattern:/`(?:\\`|\\?[^`]{1,2})`/,alias:"rune"}}),Ye.languages.insertBefore("v","operator",{attribute:{pattern:/(^[\t ]*)\[(?:deprecated|direct_array_access|flag|inline|live|ref_only|typedef|unsafe_fn|windows_stdcall)\]/m,lookbehind:!0,alias:"annotation",inside:{punctuation:/[\[\]]/,keyword:/\w+/}},generic:{pattern:/<\w+>(?=\s*[\)\{])/,inside:{punctuation:/[<>]/,"class-name":/\w+/}}}),Ye.languages.insertBefore("v","function",{"generic-function":{pattern:/\b\w+\s*<\w+>(?=\()/,inside:{function:/^\w+/,generic:{pattern:/<\w+>/,inside:Ye.languages.v.generic.inside}}}})})(t)}return v_1}var vala_1,hasRequiredVala;function requireVala(){if(hasRequiredVala)return vala_1;hasRequiredVala=1,vala_1=e,e.displayName="vala",e.aliases=[];function e(t){t.languages.vala=t.languages.extend("clike",{"class-name":[{pattern:/\b[A-Z]\w*(?:\.\w+)*\b(?=(?:\?\s+|\*?\s+\*?)\w)/,inside:{punctuation:/\./}},{pattern:/(\[)[A-Z]\w*(?:\.\w+)*\b/,lookbehind:!0,inside:{punctuation:/\./}},{pattern:/(\b(?:class|interface)\s+[A-Z]\w*(?:\.\w+)*\s*:\s*)[A-Z]\w*(?:\.\w+)*\b/,lookbehind:!0,inside:{punctuation:/\./}},{pattern:/((?:\b(?:class|enum|interface|new|struct)\s+)|(?:catch\s+\())[A-Z]\w*(?:\.\w+)*\b/,lookbehind:!0,inside:{punctuation:/\./}}],keyword:/\b(?:abstract|as|assert|async|base|bool|break|case|catch|char|class|const|construct|continue|default|delegate|delete|do|double|dynamic|else|ensures|enum|errordomain|extern|finally|float|for|foreach|get|if|in|inline|int|int16|int32|int64|int8|interface|internal|is|lock|long|namespace|new|null|out|override|owned|params|private|protected|public|ref|requires|return|set|short|signal|sizeof|size_t|ssize_t|static|string|struct|switch|this|throw|throws|try|typeof|uchar|uint|uint16|uint32|uint64|uint8|ulong|unichar|unowned|ushort|using|value|var|virtual|void|volatile|weak|while|yield)\b/i,function:/\b\w+(?=\s*\()/,number:/(?:\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?)(?:f|u?l?)?/i,operator:/\+\+|--|&&|\|\||<<=?|>>=?|=>|->|~|[+\-*\/%&^|=!<>]=?|\?\??|\.\.\./,punctuation:/[{}[\];(),.:]/,constant:/\b[A-Z0-9_]+\b/}),t.languages.insertBefore("vala","string",{"raw-string":{pattern:/"""[\s\S]*?"""/,greedy:!0,alias:"string"},"template-string":{pattern:/@"[\s\S]*?"/,greedy:!0,inside:{interpolation:{pattern:/\$(?:\([^)]*\)|[a-zA-Z]\w*)/,inside:{delimiter:{pattern:/^\$\(?|\)$/,alias:"punctuation"},rest:t.languages.vala}},string:/[\s\S]+/}}}),t.languages.insertBefore("vala","keyword",{regex:{pattern:/\/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[imsx]{0,4}(?=\s*(?:$|[\r\n,.;})\]]))/,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:t.languages.regex},"regex-delimiter":/^\//,"regex-flags":/^[a-z]+$/}}})}return vala_1}var velocity_1,hasRequiredVelocity;function requireVelocity(){if(hasRequiredVelocity)return velocity_1;hasRequiredVelocity=1,velocity_1=e,e.displayName="velocity",e.aliases=[];function e(t){(function(Ye){Ye.languages.velocity=Ye.languages.extend("markup",{});var tt={variable:{pattern:/(^|[^\\](?:\\\\)*)\$!?(?:[a-z][\w-]*(?:\([^)]*\))?(?:\.[a-z][\w-]*(?:\([^)]*\))?|\[[^\]]+\])*|\{[^}]+\})/i,lookbehind:!0,inside:{}},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},number:/\b\d+\b/,boolean:/\b(?:false|true)\b/,operator:/[=!<>]=?|[+*/%-]|&&|\|\||\.\.|\b(?:eq|g[et]|l[et]|n(?:e|ot))\b/,punctuation:/[(){}[\]:,.]/};tt.variable.inside={string:tt.string,function:{pattern:/([^\w-])[a-z][\w-]*(?=\()/,lookbehind:!0},number:tt.number,boolean:tt.boolean,punctuation:tt.punctuation},Ye.languages.insertBefore("velocity","comment",{unparsed:{pattern:/(^|[^\\])#\[\[[\s\S]*?\]\]#/,lookbehind:!0,greedy:!0,inside:{punctuation:/^#\[\[|\]\]#$/}},"velocity-comment":[{pattern:/(^|[^\\])#\*[\s\S]*?\*#/,lookbehind:!0,greedy:!0,alias:"comment"},{pattern:/(^|[^\\])##.*/,lookbehind:!0,greedy:!0,alias:"comment"}],directive:{pattern:/(^|[^\\](?:\\\\)*)#@?(?:[a-z][\w-]*|\{[a-z][\w-]*\})(?:\s*\((?:[^()]|\([^()]*\))*\))?/i,lookbehind:!0,inside:{keyword:{pattern:/^#@?(?:[a-z][\w-]*|\{[a-z][\w-]*\})|\bin\b/,inside:{punctuation:/[{}]/}},rest:tt}},variable:tt.variable}),Ye.languages.velocity.tag.inside["attr-value"].inside.rest=Ye.languages.velocity})(t)}return velocity_1}var verilog_1,hasRequiredVerilog;function requireVerilog(){if(hasRequiredVerilog)return verilog_1;hasRequiredVerilog=1,verilog_1=e,e.displayName="verilog",e.aliases=[];function e(t){t.languages.verilog={comment:{pattern:/\/\/.*|\/\*[\s\S]*?\*\//,greedy:!0},string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},"kernel-function":{pattern:/\B\$\w+\b/,alias:"property"},constant:/\B`\w+\b/,function:/\b\w+(?=\()/,keyword:/\b(?:alias|and|assert|assign|assume|automatic|before|begin|bind|bins|binsof|bit|break|buf|bufif0|bufif1|byte|case|casex|casez|cell|chandle|class|clocking|cmos|config|const|constraint|context|continue|cover|covergroup|coverpoint|cross|deassign|default|defparam|design|disable|dist|do|edge|else|end|endcase|endclass|endclocking|endconfig|endfunction|endgenerate|endgroup|endinterface|endmodule|endpackage|endprimitive|endprogram|endproperty|endsequence|endspecify|endtable|endtask|enum|event|expect|export|extends|extern|final|first_match|for|force|foreach|forever|fork|forkjoin|function|generate|genvar|highz0|highz1|if|iff|ifnone|ignore_bins|illegal_bins|import|incdir|include|initial|inout|input|inside|instance|int|integer|interface|intersect|join|join_any|join_none|large|liblist|library|local|localparam|logic|longint|macromodule|matches|medium|modport|module|nand|negedge|new|nmos|nor|noshowcancelled|not|notif0|notif1|null|or|output|package|packed|parameter|pmos|posedge|primitive|priority|program|property|protected|pull0|pull1|pulldown|pullup|pulsestyle_ondetect|pulsestyle_onevent|pure|rand|randc|randcase|randsequence|rcmos|real|realtime|ref|reg|release|repeat|return|rnmos|rpmos|rtran|rtranif0|rtranif1|scalared|sequence|shortint|shortreal|showcancelled|signed|small|solve|specify|specparam|static|string|strong0|strong1|struct|super|supply0|supply1|table|tagged|task|this|throughout|time|timeprecision|timeunit|tran|tranif0|tranif1|tri|tri0|tri1|triand|trior|trireg|type|typedef|union|unique|unsigned|use|uwire|var|vectored|virtual|void|wait|wait_order|wand|weak0|weak1|while|wildcard|wire|with|within|wor|xnor|xor)\b/,important:/\b(?:always|always_comb|always_ff|always_latch)\b(?: *@)?/,number:/\B##?\d+|(?:\b\d+)?'[odbh] ?[\da-fzx_?]+|\b(?:\d*[._])?\d+(?:e[-+]?\d+)?/i,operator:/[-+{}^~%*\/?=!<>&|]+/,punctuation:/[[\];(),.:]/}}return verilog_1}var vhdl_1,hasRequiredVhdl;function requireVhdl(){if(hasRequiredVhdl)return vhdl_1;hasRequiredVhdl=1,vhdl_1=e,e.displayName="vhdl",e.aliases=[];function e(t){t.languages.vhdl={comment:/--.+/,"vhdl-vectors":{pattern:/\b[oxb]"[\da-f_]+"|"[01uxzwlh-]+"/i,alias:"number"},"quoted-function":{pattern:/"\S+?"(?=\()/,alias:"function"},string:/"(?:[^\\"\r\n]|\\(?:\r\n|[\s\S]))*"/,constant:/\b(?:library|use)\b/i,keyword:/\b(?:'active|'ascending|'base|'delayed|'driving|'driving_value|'event|'high|'image|'instance_name|'last_active|'last_event|'last_value|'left|'leftof|'length|'low|'path_name|'pos|'pred|'quiet|'range|'reverse_range|'right|'rightof|'simple_name|'stable|'succ|'transaction|'val|'value|access|after|alias|all|architecture|array|assert|attribute|begin|block|body|buffer|bus|case|component|configuration|constant|disconnect|downto|else|elsif|end|entity|exit|file|for|function|generate|generic|group|guarded|if|impure|in|inertial|inout|is|label|library|linkage|literal|loop|map|new|next|null|of|on|open|others|out|package|port|postponed|procedure|process|pure|range|record|register|reject|report|return|select|severity|shared|signal|subtype|then|to|transport|type|unaffected|units|until|use|variable|wait|when|while|with)\b/i,boolean:/\b(?:false|true)\b/i,function:/\w+(?=\()/,number:/'[01uxzwlh-]'|\b(?:\d+#[\da-f_.]+#|\d[\d_.]*)(?:e[-+]?\d+)?/i,operator:/[<>]=?|:=|[-+*/&=]|\b(?:abs|and|mod|nand|nor|not|or|rem|rol|ror|sla|sll|sra|srl|xnor|xor)\b/i,punctuation:/[{}[\];(),.:]/}}return vhdl_1}var vim_1,hasRequiredVim;function requireVim(){if(hasRequiredVim)return vim_1;hasRequiredVim=1,vim_1=e,e.displayName="vim",e.aliases=[];function e(t){t.languages.vim={string:/"(?:[^"\\\r\n]|\\.)*"|'(?:[^'\r\n]|'')*'/,comment:/".*/,function:/\b\w+(?=\()/,keyword:/\b(?:N|Next|P|Print|X|XMLent|XMLns|ab|abbreviate|abc|abclear|abo|aboveleft|al|all|ar|arga|argadd|argd|argdelete|argdo|arge|argedit|argg|argglobal|argl|arglocal|args|argu|argument|as|ascii|b|bN|bNext|ba|bad|badd|ball|bd|bdelete|be|bel|belowright|bf|bfirst|bl|blast|bm|bmodified|bn|bnext|bo|botright|bp|bprevious|br|brea|break|breaka|breakadd|breakd|breakdel|breakl|breaklist|brewind|bro|browse|bufdo|buffer|buffers|bun|bunload|bw|bwipeout|c|cN|cNext|cNfcNfile|ca|cabbrev|cabc|cabclear|cad|caddb|caddbuffer|caddexpr|caddf|caddfile|cal|call|cat|catch|cb|cbuffer|cc|ccl|cclose|cd|ce|center|cex|cexpr|cf|cfile|cfir|cfirst|cg|cgetb|cgetbuffer|cgete|cgetexpr|cgetfile|change|changes|chd|chdir|che|checkpath|checkt|checktime|cl|cla|clast|clist|clo|close|cmapc|cmapclear|cn|cnew|cnewer|cnext|cnf|cnfile|cnorea|cnoreabbrev|co|col|colder|colo|colorscheme|comc|comclear|comp|compiler|con|conf|confirm|continue|cope|copen|copy|cp|cpf|cpfile|cprevious|cq|cquit|cr|crewind|cu|cuna|cunabbrev|cunmap|cw|cwindow|d|debugg|debuggreedy|delc|delcommand|delete|delf|delfunction|delm|delmarks|di|diffg|diffget|diffoff|diffpatch|diffpu|diffput|diffsplit|diffthis|diffu|diffupdate|dig|digraphs|display|dj|djump|dl|dlist|dr|drop|ds|dsearch|dsp|dsplit|e|earlier|echoe|echoerr|echom|echomsg|echon|edit|el|else|elsei|elseif|em|emenu|en|endf|endfo|endfor|endfun|endfunction|endif|endt|endtry|endw|endwhile|ene|enew|ex|exi|exit|exu|exusage|f|file|files|filetype|fin|fina|finally|find|fini|finish|fir|first|fix|fixdel|fo|fold|foldc|foldclose|foldd|folddoc|folddoclosed|folddoopen|foldo|foldopen|for|fu|fun|function|go|goto|gr|grep|grepa|grepadd|h|ha|hardcopy|help|helpf|helpfind|helpg|helpgrep|helpt|helptags|hid|hide|his|history|ia|iabbrev|iabc|iabclear|if|ij|ijump|il|ilist|imapc|imapclear|in|inorea|inoreabbrev|isearch|isp|isplit|iu|iuna|iunabbrev|iunmap|j|join|ju|jumps|k|kee|keepalt|keepj|keepjumps|keepmarks|l|lN|lNext|lNf|lNfile|la|lad|laddb|laddbuffer|laddexpr|laddf|laddfile|lan|language|last|later|lb|lbuffer|lc|lcd|lch|lchdir|lcl|lclose|left|lefta|leftabove|let|lex|lexpr|lf|lfile|lfir|lfirst|lg|lgetb|lgetbuffer|lgete|lgetexpr|lgetfile|lgr|lgrep|lgrepa|lgrepadd|lh|lhelpgrep|list|ll|lla|llast|lli|llist|lm|lmak|lmake|lmap|lmapc|lmapclear|ln|lne|lnew|lnewer|lnext|lnf|lnfile|lnoremap|lo|loadview|loc|lockmarks|lockv|lockvar|lol|lolder|lop|lopen|lp|lpf|lpfile|lprevious|lr|lrewind|ls|lt|ltag|lu|lunmap|lv|lvimgrep|lvimgrepa|lvimgrepadd|lw|lwindow|m|ma|mak|make|mark|marks|mat|match|menut|menutranslate|mk|mkexrc|mks|mksession|mksp|mkspell|mkv|mkvie|mkview|mkvimrc|mod|mode|move|mz|mzf|mzfile|mzscheme|n|nbkey|new|next|nmapc|nmapclear|noh|nohlsearch|norea|noreabbrev|nu|number|nun|nunmap|o|omapc|omapclear|on|only|open|opt|options|ou|ounmap|p|pc|pclose|pe|ped|pedit|perl|perld|perldo|po|pop|popu|popup|pp|ppop|pre|preserve|prev|previous|print|prof|profd|profdel|profile|promptf|promptfind|promptr|promptrepl|ps|psearch|ptN|ptNext|pta|ptag|ptf|ptfirst|ptj|ptjump|ptl|ptlast|ptn|ptnext|ptp|ptprevious|ptr|ptrewind|pts|ptselect|pu|put|pw|pwd|py|pyf|pyfile|python|q|qa|qall|quit|quita|quitall|r|read|rec|recover|red|redi|redir|redo|redr|redraw|redraws|redrawstatus|reg|registers|res|resize|ret|retab|retu|return|rew|rewind|ri|right|rightb|rightbelow|ru|rub|ruby|rubyd|rubydo|rubyf|rubyfile|runtime|rv|rviminfo|sN|sNext|sa|sal|sall|san|sandbox|sargument|sav|saveas|sb|sbN|sbNext|sba|sball|sbf|sbfirst|sbl|sblast|sbm|sbmodified|sbn|sbnext|sbp|sbprevious|sbr|sbrewind|sbuffer|scrip|scripte|scriptencoding|scriptnames|se|set|setf|setfiletype|setg|setglobal|setl|setlocal|sf|sfind|sfir|sfirst|sh|shell|sign|sil|silent|sim|simalt|sl|sla|slast|sleep|sm|smagic|smap|smapc|smapclear|sme|smenu|sn|snext|sni|sniff|sno|snomagic|snor|snoremap|snoreme|snoremenu|so|sor|sort|source|sp|spe|spelld|spelldump|spellgood|spelli|spellinfo|spellr|spellrepall|spellu|spellundo|spellw|spellwrong|split|spr|sprevious|sre|srewind|st|sta|stag|star|startg|startgreplace|startinsert|startr|startreplace|stj|stjump|stop|stopi|stopinsert|sts|stselect|sun|sunhide|sunm|sunmap|sus|suspend|sv|sview|syncbind|t|tN|tNext|ta|tab|tabN|tabNext|tabc|tabclose|tabd|tabdo|tabe|tabedit|tabf|tabfind|tabfir|tabfirst|tabl|tablast|tabm|tabmove|tabn|tabnew|tabnext|tabo|tabonly|tabp|tabprevious|tabr|tabrewind|tabs|tag|tags|tc|tcl|tcld|tcldo|tclf|tclfile|te|tearoff|tf|tfirst|th|throw|tj|tjump|tl|tlast|tm|tmenu|tn|tnext|to|topleft|tp|tprevious|tr|trewind|try|ts|tselect|tu|tunmenu|u|una|unabbreviate|undo|undoj|undojoin|undol|undolist|unh|unhide|unlet|unlo|unlockvar|unm|unmap|up|update|ve|verb|verbose|version|vert|vertical|vi|vie|view|vim|vimgrep|vimgrepa|vimgrepadd|visual|viu|viusage|vmapc|vmapclear|vne|vnew|vs|vsplit|vu|vunmap|w|wN|wNext|wa|wall|wh|while|win|winc|wincmd|windo|winp|winpos|winsize|wn|wnext|wp|wprevious|wq|wqa|wqall|write|ws|wsverb|wv|wviminfo|x|xa|xall|xit|xm|xmap|xmapc|xmapclear|xme|xmenu|xn|xnoremap|xnoreme|xnoremenu|xu|xunmap|y|yank)\b/,builtin:/\b(?:acd|ai|akm|aleph|allowrevins|altkeymap|ambiwidth|ambw|anti|antialias|arab|arabic|arabicshape|ari|arshape|autochdir|autocmd|autoindent|autoread|autowrite|autowriteall|aw|awa|background|backspace|backup|backupcopy|backupdir|backupext|backupskip|balloondelay|ballooneval|balloonexpr|bdir|bdlay|beval|bex|bexpr|bg|bh|bin|binary|biosk|bioskey|bk|bkc|bomb|breakat|brk|browsedir|bs|bsdir|bsk|bt|bufhidden|buflisted|buftype|casemap|ccv|cdpath|cedit|cfu|ch|charconvert|ci|cin|cindent|cink|cinkeys|cino|cinoptions|cinw|cinwords|clipboard|cmdheight|cmdwinheight|cmp|cms|columns|com|comments|commentstring|compatible|complete|completefunc|completeopt|consk|conskey|copyindent|cot|cpo|cpoptions|cpt|cscopepathcomp|cscopeprg|cscopequickfix|cscopetag|cscopetagorder|cscopeverbose|cspc|csprg|csqf|cst|csto|csverb|cuc|cul|cursorcolumn|cursorline|cwh|debug|deco|def|define|delcombine|dex|dg|dict|dictionary|diff|diffexpr|diffopt|digraph|dip|dir|directory|dy|ea|ead|eadirection|eb|ed|edcompatible|ef|efm|ei|ek|enc|encoding|endofline|eol|ep|equalalways|equalprg|errorbells|errorfile|errorformat|esckeys|et|eventignore|expandtab|exrc|fcl|fcs|fdc|fde|fdi|fdl|fdls|fdm|fdn|fdo|fdt|fen|fenc|fencs|fex|ff|ffs|fileencoding|fileencodings|fileformat|fileformats|fillchars|fk|fkmap|flp|fml|fmr|foldcolumn|foldenable|foldexpr|foldignore|foldlevel|foldlevelstart|foldmarker|foldmethod|foldminlines|foldnestmax|foldtext|formatexpr|formatlistpat|formatoptions|formatprg|fp|fs|fsync|ft|gcr|gd|gdefault|gfm|gfn|gfs|gfw|ghr|gp|grepformat|grepprg|gtl|gtt|guicursor|guifont|guifontset|guifontwide|guiheadroom|guioptions|guipty|guitablabel|guitabtooltip|helpfile|helpheight|helplang|hf|hh|hi|hidden|highlight|hk|hkmap|hkmapp|hkp|hl|hlg|hls|hlsearch|ic|icon|iconstring|ignorecase|im|imactivatekey|imak|imc|imcmdline|imd|imdisable|imi|iminsert|ims|imsearch|inc|include|includeexpr|incsearch|inde|indentexpr|indentkeys|indk|inex|inf|infercase|insertmode|invacd|invai|invakm|invallowrevins|invaltkeymap|invanti|invantialias|invar|invarab|invarabic|invarabicshape|invari|invarshape|invautochdir|invautoindent|invautoread|invautowrite|invautowriteall|invaw|invawa|invbackup|invballooneval|invbeval|invbin|invbinary|invbiosk|invbioskey|invbk|invbl|invbomb|invbuflisted|invcf|invci|invcin|invcindent|invcompatible|invconfirm|invconsk|invconskey|invcopyindent|invcp|invcscopetag|invcscopeverbose|invcst|invcsverb|invcuc|invcul|invcursorcolumn|invcursorline|invdeco|invdelcombine|invdg|invdiff|invdigraph|invdisable|invea|inveb|inved|invedcompatible|invek|invendofline|inveol|invequalalways|inverrorbells|invesckeys|invet|invex|invexpandtab|invexrc|invfen|invfk|invfkmap|invfoldenable|invgd|invgdefault|invguipty|invhid|invhidden|invhk|invhkmap|invhkmapp|invhkp|invhls|invhlsearch|invic|invicon|invignorecase|invim|invimc|invimcmdline|invimd|invincsearch|invinf|invinfercase|invinsertmode|invis|invjoinspaces|invjs|invlazyredraw|invlbr|invlinebreak|invlisp|invlist|invloadplugins|invlpl|invlz|invma|invmacatsui|invmagic|invmh|invml|invmod|invmodeline|invmodifiable|invmodified|invmore|invmousef|invmousefocus|invmousehide|invnu|invnumber|invodev|invopendevice|invpaste|invpi|invpreserveindent|invpreviewwindow|invprompt|invpvw|invreadonly|invremap|invrestorescreen|invrevins|invri|invrightleft|invrightleftcmd|invrl|invrlc|invro|invrs|invru|invruler|invsb|invsc|invscb|invscrollbind|invscs|invsecure|invsft|invshellslash|invshelltemp|invshiftround|invshortname|invshowcmd|invshowfulltag|invshowmatch|invshowmode|invsi|invsm|invsmartcase|invsmartindent|invsmarttab|invsmd|invsn|invsol|invspell|invsplitbelow|invsplitright|invspr|invsr|invssl|invsta|invstartofline|invstmp|invswapfile|invswf|invta|invtagbsearch|invtagrelative|invtagstack|invtbi|invtbidi|invtbs|invtermbidi|invterse|invtextauto|invtextmode|invtf|invtgst|invtildeop|invtimeout|invtitle|invto|invtop|invtr|invttimeout|invttybuiltin|invttyfast|invtx|invvb|invvisualbell|invwa|invwarn|invwb|invweirdinvert|invwfh|invwfw|invwildmenu|invwinfixheight|invwinfixwidth|invwiv|invwmnu|invwrap|invwrapscan|invwrite|invwriteany|invwritebackup|invws|isf|isfname|isi|isident|isk|iskeyword|isprint|joinspaces|js|key|keymap|keymodel|keywordprg|km|kmp|kp|langmap|langmenu|laststatus|lazyredraw|lbr|lcs|linebreak|lines|linespace|lisp|lispwords|listchars|loadplugins|lpl|lsp|lz|macatsui|magic|makeef|makeprg|matchpairs|matchtime|maxcombine|maxfuncdepth|maxmapdepth|maxmem|maxmempattern|maxmemtot|mco|mef|menuitems|mfd|mh|mis|mkspellmem|ml|mls|mm|mmd|mmp|mmt|modeline|modelines|modifiable|modified|more|mouse|mousef|mousefocus|mousehide|mousem|mousemodel|mouses|mouseshape|mouset|mousetime|mp|mps|msm|mzq|mzquantum|nf|noacd|noai|noakm|noallowrevins|noaltkeymap|noanti|noantialias|noar|noarab|noarabic|noarabicshape|noari|noarshape|noautochdir|noautoindent|noautoread|noautowrite|noautowriteall|noaw|noawa|nobackup|noballooneval|nobeval|nobin|nobinary|nobiosk|nobioskey|nobk|nobl|nobomb|nobuflisted|nocf|noci|nocin|nocindent|nocompatible|noconfirm|noconsk|noconskey|nocopyindent|nocp|nocscopetag|nocscopeverbose|nocst|nocsverb|nocuc|nocul|nocursorcolumn|nocursorline|nodeco|nodelcombine|nodg|nodiff|nodigraph|nodisable|noea|noeb|noed|noedcompatible|noek|noendofline|noeol|noequalalways|noerrorbells|noesckeys|noet|noex|noexpandtab|noexrc|nofen|nofk|nofkmap|nofoldenable|nogd|nogdefault|noguipty|nohid|nohidden|nohk|nohkmap|nohkmapp|nohkp|nohls|noic|noicon|noignorecase|noim|noimc|noimcmdline|noimd|noincsearch|noinf|noinfercase|noinsertmode|nois|nojoinspaces|nojs|nolazyredraw|nolbr|nolinebreak|nolisp|nolist|noloadplugins|nolpl|nolz|noma|nomacatsui|nomagic|nomh|noml|nomod|nomodeline|nomodifiable|nomodified|nomore|nomousef|nomousefocus|nomousehide|nonu|nonumber|noodev|noopendevice|nopaste|nopi|nopreserveindent|nopreviewwindow|noprompt|nopvw|noreadonly|noremap|norestorescreen|norevins|nori|norightleft|norightleftcmd|norl|norlc|noro|nors|noru|noruler|nosb|nosc|noscb|noscrollbind|noscs|nosecure|nosft|noshellslash|noshelltemp|noshiftround|noshortname|noshowcmd|noshowfulltag|noshowmatch|noshowmode|nosi|nosm|nosmartcase|nosmartindent|nosmarttab|nosmd|nosn|nosol|nospell|nosplitbelow|nosplitright|nospr|nosr|nossl|nosta|nostartofline|nostmp|noswapfile|noswf|nota|notagbsearch|notagrelative|notagstack|notbi|notbidi|notbs|notermbidi|noterse|notextauto|notextmode|notf|notgst|notildeop|notimeout|notitle|noto|notop|notr|nottimeout|nottybuiltin|nottyfast|notx|novb|novisualbell|nowa|nowarn|nowb|noweirdinvert|nowfh|nowfw|nowildmenu|nowinfixheight|nowinfixwidth|nowiv|nowmnu|nowrap|nowrapscan|nowrite|nowriteany|nowritebackup|nows|nrformats|numberwidth|nuw|odev|oft|ofu|omnifunc|opendevice|operatorfunc|opfunc|osfiletype|pa|para|paragraphs|paste|pastetoggle|patchexpr|patchmode|path|pdev|penc|pex|pexpr|pfn|ph|pheader|pi|pm|pmbcs|pmbfn|popt|preserveindent|previewheight|previewwindow|printdevice|printencoding|printexpr|printfont|printheader|printmbcharset|printmbfont|printoptions|prompt|pt|pumheight|pvh|pvw|qe|quoteescape|readonly|remap|report|restorescreen|revins|rightleft|rightleftcmd|rl|rlc|ro|rs|rtp|ruf|ruler|rulerformat|runtimepath|sbo|sc|scb|scr|scroll|scrollbind|scrolljump|scrolloff|scrollopt|scs|sect|sections|secure|sel|selection|selectmode|sessionoptions|sft|shcf|shellcmdflag|shellpipe|shellquote|shellredir|shellslash|shelltemp|shelltype|shellxquote|shiftround|shiftwidth|shm|shortmess|shortname|showbreak|showcmd|showfulltag|showmatch|showmode|showtabline|shq|si|sidescroll|sidescrolloff|siso|sj|slm|smartcase|smartindent|smarttab|smc|smd|softtabstop|sol|spc|spell|spellcapcheck|spellfile|spelllang|spellsuggest|spf|spl|splitbelow|splitright|sps|sr|srr|ss|ssl|ssop|stal|startofline|statusline|stl|stmp|su|sua|suffixes|suffixesadd|sw|swapfile|swapsync|swb|swf|switchbuf|sws|sxq|syn|synmaxcol|syntax|t_AB|t_AF|t_AL|t_CS|t_CV|t_Ce|t_Co|t_Cs|t_DL|t_EI|t_F1|t_F2|t_F3|t_F4|t_F5|t_F6|t_F7|t_F8|t_F9|t_IE|t_IS|t_K1|t_K3|t_K4|t_K5|t_K6|t_K7|t_K8|t_K9|t_KA|t_KB|t_KC|t_KD|t_KE|t_KF|t_KG|t_KH|t_KI|t_KJ|t_KK|t_KL|t_RI|t_RV|t_SI|t_Sb|t_Sf|t_WP|t_WS|t_ZH|t_ZR|t_al|t_bc|t_cd|t_ce|t_cl|t_cm|t_cs|t_da|t_db|t_dl|t_fs|t_k1|t_k2|t_k3|t_k4|t_k5|t_k6|t_k7|t_k8|t_k9|t_kB|t_kD|t_kI|t_kN|t_kP|t_kb|t_kd|t_ke|t_kh|t_kl|t_kr|t_ks|t_ku|t_le|t_mb|t_md|t_me|t_mr|t_ms|t_nd|t_op|t_se|t_so|t_sr|t_te|t_ti|t_ts|t_ue|t_us|t_ut|t_vb|t_ve|t_vi|t_vs|t_xs|tabline|tabpagemax|tabstop|tagbsearch|taglength|tagrelative|tagstack|tal|tb|tbi|tbidi|tbis|tbs|tenc|term|termbidi|termencoding|terse|textauto|textmode|textwidth|tgst|thesaurus|tildeop|timeout|timeoutlen|title|titlelen|titleold|titlestring|toolbar|toolbariconsize|top|tpm|tsl|tsr|ttimeout|ttimeoutlen|ttm|tty|ttybuiltin|ttyfast|ttym|ttymouse|ttyscroll|ttytype|tw|tx|uc|ul|undolevels|updatecount|updatetime|ut|vb|vbs|vdir|verbosefile|vfile|viewdir|viewoptions|viminfo|virtualedit|visualbell|vop|wak|warn|wb|wc|wcm|wd|weirdinvert|wfh|wfw|whichwrap|wi|wig|wildchar|wildcharm|wildignore|wildmenu|wildmode|wildoptions|wim|winaltkeys|window|winfixheight|winfixwidth|winheight|winminheight|winminwidth|winwidth|wiv|wiw|wm|wmh|wmnu|wmw|wop|wrap|wrapmargin|wrapscan|writeany|writebackup|writedelay|ww)\b/,number:/\b(?:0x[\da-f]+|\d+(?:\.\d+)?)\b/i,operator:/\|\||&&|[-+.]=?|[=!](?:[=~][#?]?)?|[<>]=?[#?]?|[*\/%?]|\b(?:is(?:not)?)\b/,punctuation:/[{}[\](),;:]/}}return vim_1}var visualBasic_1,hasRequiredVisualBasic;function requireVisualBasic(){if(hasRequiredVisualBasic)return visualBasic_1;hasRequiredVisualBasic=1,visualBasic_1=e,e.displayName="visualBasic",e.aliases=[];function e(t){t.languages["visual-basic"]={comment:{pattern:/(?:['‘’]|REM\b)(?:[^\r\n_]|_(?:\r\n?|\n)?)*/i,inside:{keyword:/^REM/i}},directive:{pattern:/#(?:Const|Else|ElseIf|End|ExternalChecksum|ExternalSource|If|Region)(?:\b_[ \t]*(?:\r\n?|\n)|.)+/i,alias:"property",greedy:!0},string:{pattern:/\$?["“”](?:["“”]{2}|[^"“”])*["“”]C?/i,greedy:!0},date:{pattern:/#[ \t]*(?:\d+([/-])\d+\1\d+(?:[ \t]+(?:\d+[ \t]*(?:AM|PM)|\d+:\d+(?::\d+)?(?:[ \t]*(?:AM|PM))?))?|\d+[ \t]*(?:AM|PM)|\d+:\d+(?::\d+)?(?:[ \t]*(?:AM|PM))?)[ \t]*#/i,alias:"number"},number:/(?:(?:\b\d+(?:\.\d+)?|\.\d+)(?:E[+-]?\d+)?|&[HO][\dA-F]+)(?:[FRD]|U?[ILS])?/i,boolean:/\b(?:False|Nothing|True)\b/i,keyword:/\b(?:AddHandler|AddressOf|Alias|And(?:Also)?|As|Boolean|ByRef|Byte|ByVal|Call|Case|Catch|C(?:Bool|Byte|Char|Date|Dbl|Dec|Int|Lng|Obj|SByte|Short|Sng|Str|Type|UInt|ULng|UShort)|Char|Class|Const|Continue|Currency|Date|Decimal|Declare|Default|Delegate|Dim|DirectCast|Do|Double|Each|Else(?:If)?|End(?:If)?|Enum|Erase|Error|Event|Exit|Finally|For|Friend|Function|Get(?:Type|XMLNamespace)?|Global|GoSub|GoTo|Handles|If|Implements|Imports|In|Inherits|Integer|Interface|Is|IsNot|Let|Lib|Like|Long|Loop|Me|Mod|Module|Must(?:Inherit|Override)|My(?:Base|Class)|Namespace|Narrowing|New|Next|Not(?:Inheritable|Overridable)?|Object|Of|On|Operator|Option(?:al)?|Or(?:Else)?|Out|Overloads|Overridable|Overrides|ParamArray|Partial|Private|Property|Protected|Public|RaiseEvent|ReadOnly|ReDim|RemoveHandler|Resume|Return|SByte|Select|Set|Shadows|Shared|short|Single|Static|Step|Stop|String|Structure|Sub|SyncLock|Then|Throw|To|Try|TryCast|Type|TypeOf|U(?:Integer|Long|Short)|Until|Using|Variant|Wend|When|While|Widening|With(?:Events)?|WriteOnly|Xor)\b/i,operator:/[+\-*/\\^<=>&#@$%!]|\b_(?=[ \t]*[\r\n])/,punctuation:/[{}().,:?]/},t.languages.vb=t.languages["visual-basic"],t.languages.vba=t.languages["visual-basic"]}return visualBasic_1}var warpscript_1,hasRequiredWarpscript;function requireWarpscript(){if(hasRequiredWarpscript)return warpscript_1;hasRequiredWarpscript=1,warpscript_1=e,e.displayName="warpscript",e.aliases=[];function e(t){t.languages.warpscript={comment:/#.*|\/\/.*|\/\*[\s\S]*?\*\//,string:{pattern:/"(?:[^"\\\r\n]|\\.)*"|'(?:[^'\\\r\n]|\\.)*'|<'(?:[^\\']|'(?!>)|\\.)*'>/,greedy:!0},variable:/\$\S+/,macro:{pattern:/@\S+/,alias:"property"},keyword:/\b(?:BREAK|CHECKMACRO|CONTINUE|CUDF|DEFINED|DEFINEDMACRO|EVAL|FAIL|FOR|FOREACH|FORSTEP|IFT|IFTE|MSGFAIL|NRETURN|RETHROW|RETURN|SWITCH|TRY|UDF|UNTIL|WHILE)\b/,number:/[+-]?\b(?:NaN|Infinity|\d+(?:\.\d*)?(?:[Ee][+-]?\d+)?|0x[\da-fA-F]+|0b[01]+)\b/,boolean:/\b(?:F|T|false|true)\b/,punctuation:/<%|%>|[{}[\]()]/,operator:/==|&&?|\|\|?|\*\*?|>>>?|<<|[<>!~]=?|[-/%^]|\+!?|\b(?:AND|NOT|OR)\b/}}return warpscript_1}var wasm_1,hasRequiredWasm;function requireWasm(){if(hasRequiredWasm)return wasm_1;hasRequiredWasm=1,wasm_1=e,e.displayName="wasm",e.aliases=[];function e(t){t.languages.wasm={comment:[/\(;[\s\S]*?;\)/,{pattern:/;;.*/,greedy:!0}],string:{pattern:/"(?:\\[\s\S]|[^"\\])*"/,greedy:!0},keyword:[{pattern:/\b(?:align|offset)=/,inside:{operator:/=/}},{pattern:/\b(?:(?:f32|f64|i32|i64)(?:\.(?:abs|add|and|ceil|clz|const|convert_[su]\/i(?:32|64)|copysign|ctz|demote\/f64|div(?:_[su])?|eqz?|extend_[su]\/i32|floor|ge(?:_[su])?|gt(?:_[su])?|le(?:_[su])?|load(?:(?:8|16|32)_[su])?|lt(?:_[su])?|max|min|mul|neg?|nearest|or|popcnt|promote\/f32|reinterpret\/[fi](?:32|64)|rem_[su]|rot[lr]|shl|shr_[su]|sqrt|store(?:8|16|32)?|sub|trunc(?:_[su]\/f(?:32|64))?|wrap\/i64|xor))?|memory\.(?:grow|size))\b/,inside:{punctuation:/\./}},/\b(?:anyfunc|block|br(?:_if|_table)?|call(?:_indirect)?|data|drop|elem|else|end|export|func|get_(?:global|local)|global|if|import|local|loop|memory|module|mut|nop|offset|param|result|return|select|set_(?:global|local)|start|table|tee_local|then|type|unreachable)\b/],variable:/\$[\w!#$%&'*+\-./:<=>?@\\^`|~]+/,number:/[+-]?\b(?:\d(?:_?\d)*(?:\.\d(?:_?\d)*)?(?:[eE][+-]?\d(?:_?\d)*)?|0x[\da-fA-F](?:_?[\da-fA-F])*(?:\.[\da-fA-F](?:_?[\da-fA-D])*)?(?:[pP][+-]?\d(?:_?\d)*)?)\b|\binf\b|\bnan(?::0x[\da-fA-F](?:_?[\da-fA-D])*)?\b/,punctuation:/[()]/}}return wasm_1}var webIdl_1,hasRequiredWebIdl;function requireWebIdl(){if(hasRequiredWebIdl)return webIdl_1;hasRequiredWebIdl=1,webIdl_1=e,e.displayName="webIdl",e.aliases=[];function e(t){(function(Ye){var tt=/(?:\B-|\b_|\b)[A-Za-z][\w-]*(?![\w-])/.source,rt="(?:"+/\b(?:unsigned\s+)?long\s+long(?![\w-])/.source+"|"+/\b(?:unrestricted|unsigned)\s+[a-z]+(?![\w-])/.source+"|"+/(?!(?:unrestricted|unsigned)\b)/.source+tt+/(?:\s*<(?:[^<>]|<[^<>]*>)*>)?/.source+")"+/(?:\s*\?)?/.source,nt={};Ye.languages["web-idl"]={comment:{pattern:/\/\/.*|\/\*[\s\S]*?\*\//,greedy:!0},string:{pattern:/"[^"]*"/,greedy:!0},namespace:{pattern:RegExp(/(\bnamespace\s+)/.source+tt),lookbehind:!0},"class-name":[{pattern:/(^|[^\w-])(?:iterable|maplike|setlike)\s*<(?:[^<>]|<[^<>]*>)*>/,lookbehind:!0,inside:nt},{pattern:RegExp(/(\b(?:attribute|const|deleter|getter|optional|setter)\s+)/.source+rt),lookbehind:!0,inside:nt},{pattern:RegExp("("+/\bcallback\s+/.source+tt+/\s*=\s*/.source+")"+rt),lookbehind:!0,inside:nt},{pattern:RegExp(/(\btypedef\b\s*)/.source+rt),lookbehind:!0,inside:nt},{pattern:RegExp(/(\b(?:callback|dictionary|enum|interface(?:\s+mixin)?)\s+)(?!(?:interface|mixin)\b)/.source+tt),lookbehind:!0},{pattern:RegExp(/(:\s*)/.source+tt),lookbehind:!0},RegExp(tt+/(?=\s+(?:implements|includes)\b)/.source),{pattern:RegExp(/(\b(?:implements|includes)\s+)/.source+tt),lookbehind:!0},{pattern:RegExp(rt+"(?="+/\s*(?:\.{3}\s*)?/.source+tt+/\s*[(),;=]/.source+")"),inside:nt}],builtin:/\b(?:ArrayBuffer|BigInt64Array|BigUint64Array|ByteString|DOMString|DataView|Float32Array|Float64Array|FrozenArray|Int16Array|Int32Array|Int8Array|ObservableArray|Promise|USVString|Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray)\b/,keyword:[/\b(?:async|attribute|callback|const|constructor|deleter|dictionary|enum|getter|implements|includes|inherit|interface|mixin|namespace|null|optional|or|partial|readonly|required|setter|static|stringifier|typedef|unrestricted)\b/,/\b(?:any|bigint|boolean|byte|double|float|iterable|long|maplike|object|octet|record|sequence|setlike|short|symbol|undefined|unsigned|void)\b/],boolean:/\b(?:false|true)\b/,number:{pattern:/(^|[^\w-])-?(?:0x[0-9a-f]+|(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?|NaN|Infinity)(?![\w-])/i,lookbehind:!0},operator:/\.{3}|[=:?<>-]/,punctuation:/[(){}[\].,;]/};for(var at in Ye.languages["web-idl"])at!=="class-name"&&(nt[at]=Ye.languages["web-idl"][at]);Ye.languages.webidl=Ye.languages["web-idl"]})(t)}return webIdl_1}var wiki_1,hasRequiredWiki;function requireWiki(){if(hasRequiredWiki)return wiki_1;hasRequiredWiki=1,wiki_1=e,e.displayName="wiki",e.aliases=[];function e(t){t.languages.wiki=t.languages.extend("markup",{"block-comment":{pattern:/(^|[^\\])\/\*[\s\S]*?\*\//,lookbehind:!0,alias:"comment"},heading:{pattern:/^(=+)[^=\r\n].*?\1/m,inside:{punctuation:/^=+|=+$/,important:/.+/}},emphasis:{pattern:/('{2,5}).+?\1/,inside:{"bold-italic":{pattern:/(''''').+?(?=\1)/,lookbehind:!0,alias:["bold","italic"]},bold:{pattern:/(''')[^'](?:.*?[^'])?(?=\1)/,lookbehind:!0},italic:{pattern:/('')[^'](?:.*?[^'])?(?=\1)/,lookbehind:!0},punctuation:/^''+|''+$/}},hr:{pattern:/^-{4,}/m,alias:"punctuation"},url:[/ISBN +(?:97[89][ -]?)?(?:\d[ -]?){9}[\dx]\b|(?:PMID|RFC) +\d+/i,/\[\[.+?\]\]|\[.+?\]/],variable:[/__[A-Z]+__/,/\{{3}.+?\}{3}/,/\{\{.+?\}\}/],symbol:[/^#redirect/im,/~{3,5}/],"table-tag":{pattern:/((?:^|[|!])[|!])[^|\r\n]+\|(?!\|)/m,lookbehind:!0,inside:{"table-bar":{pattern:/\|$/,alias:"punctuation"},rest:t.languages.markup.tag.inside}},punctuation:/^(?:\{\||\|\}|\|-|[*#:;!|])|\|\||!!/m}),t.languages.insertBefore("wiki","tag",{nowiki:{pattern:/<(nowiki|pre|source)\b[^>]*>[\s\S]*?<\/\1>/i,inside:{tag:{pattern:/<(?:nowiki|pre|source)\b[^>]*>|<\/(?:nowiki|pre|source)>/i,inside:t.languages.markup.tag.inside}}}})}return wiki_1}var wolfram_1,hasRequiredWolfram;function requireWolfram(){if(hasRequiredWolfram)return wolfram_1;hasRequiredWolfram=1,wolfram_1=e,e.displayName="wolfram",e.aliases=["mathematica","wl","nb"];function e(t){t.languages.wolfram={comment:/\(\*(?:\(\*(?:[^*]|\*(?!\)))*\*\)|(?!\(\*)[\s\S])*?\*\)/,string:{pattern:/"(?:\\.|[^"\\\r\n])*"/,greedy:!0},keyword:/\b(?:Abs|AbsArg|Accuracy|Block|Do|For|Function|If|Manipulate|Module|Nest|NestList|None|Return|Switch|Table|Which|While)\b/,context:{pattern:/\b\w+`+\w*/,alias:"class-name"},blank:{pattern:/\b\w+_\b/,alias:"regex"},"global-variable":{pattern:/\$\w+/,alias:"variable"},boolean:/\b(?:False|True)\b/,number:/(?:\b(?=\d)|\B(?=\.))(?:0[bo])?(?:(?:\d|0x[\da-f])[\da-f]*(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?j?\b/i,operator:/\/\.|;|=\.|\^=|\^:=|:=|<<|>>|<\||\|>|:>|\|->|->|<-|@@@|@@|@|\/@|=!=|===|==|=|\+|-|\^|\[\/-+%=\]=?|!=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,punctuation:/[{}[\];(),.:]/},t.languages.mathematica=t.languages.wolfram,t.languages.wl=t.languages.wolfram,t.languages.nb=t.languages.wolfram}return wolfram_1}var wren_1,hasRequiredWren;function requireWren(){if(hasRequiredWren)return wren_1;hasRequiredWren=1,wren_1=e,e.displayName="wren",e.aliases=[];function e(t){t.languages.wren={comment:[{pattern:/\/\*(?:[^*/]|\*(?!\/)|\/(?!\*)|\/\*(?:[^*/]|\*(?!\/)|\/(?!\*)|\/\*(?:[^*/]|\*(?!\/)|\/(?!\*))*\*\/)*\*\/)*\*\//,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],"triple-quoted-string":{pattern:/"""[\s\S]*?"""/,greedy:!0,alias:"string"},"string-literal":null,hashbang:{pattern:/^#!\/.+/,greedy:!0,alias:"comment"},attribute:{pattern:/#!?[ \t\u3000]*\w+/,alias:"keyword"},"class-name":[{pattern:/(\bclass\s+)\w+/,lookbehind:!0},/\b[A-Z][a-z\d_]*\b/],constant:/\b[A-Z][A-Z\d_]*\b/,null:{pattern:/\bnull\b/,alias:"keyword"},keyword:/\b(?:as|break|class|construct|continue|else|for|foreign|if|import|in|is|return|static|super|this|var|while)\b/,boolean:/\b(?:false|true)\b/,number:/\b(?:0x[\da-f]+|\d+(?:\.\d+)?(?:e[+-]?\d+)?)\b/i,function:/\b[a-z_]\w*(?=\s*[({])/i,operator:/<<|>>|[=!<>]=?|&&|\|\||[-+*/%~^&|?:]|\.{2,3}/,punctuation:/[\[\](){}.,;]/},t.languages.wren["string-literal"]={pattern:/(^|[^\\"])"(?:[^\\"%]|\\[\s\S]|%(?!\()|%\((?:[^()]|\((?:[^()]|\([^)]*\))*\))*\))*"/,lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)%\((?:[^()]|\((?:[^()]|\([^)]*\))*\))*\)/,lookbehind:!0,inside:{expression:{pattern:/^(%\()[\s\S]+(?=\)$)/,lookbehind:!0,inside:t.languages.wren},"interpolation-punctuation":{pattern:/^%\(|\)$/,alias:"punctuation"}}},string:/[\s\S]+/}}}return wren_1}var xeora_1,hasRequiredXeora;function requireXeora(){if(hasRequiredXeora)return xeora_1;hasRequiredXeora=1,xeora_1=e,e.displayName="xeora",e.aliases=["xeoracube"];function e(t){(function(Ye){Ye.languages.xeora=Ye.languages.extend("markup",{constant:{pattern:/\$(?:DomainContents|PageRenderDuration)\$/,inside:{punctuation:{pattern:/\$/}}},variable:{pattern:/\$@?(?:#+|[-+*~=^])?[\w.]+\$/,inside:{punctuation:{pattern:/[$.]/},operator:{pattern:/#+|[-+*~=^@]/}}},"function-inline":{pattern:/\$F:[-\w.]+\?[-\w.]+(?:,(?:(?:@[-#]*\w+\.[\w+.]\.*)*\|)*(?:(?:[\w+]|[-#*.~^]+[\w+]|=\S)(?:[^$=]|=+[^=])*=*|(?:@[-#]*\w+\.[\w+.]\.*)+(?:(?:[\w+]|[-#*~^][-#*.~^]*[\w+]|=\S)(?:[^$=]|=+[^=])*=*)?)?)?\$/,inside:{variable:{pattern:/(?:[,|])@?(?:#+|[-+*~=^])?[\w.]+/,inside:{punctuation:{pattern:/[,.|]/},operator:{pattern:/#+|[-+*~=^@]/}}},punctuation:{pattern:/\$\w:|[$:?.,|]/}},alias:"function"},"function-block":{pattern:/\$XF:\{[-\w.]+\?[-\w.]+(?:,(?:(?:@[-#]*\w+\.[\w+.]\.*)*\|)*(?:(?:[\w+]|[-#*.~^]+[\w+]|=\S)(?:[^$=]|=+[^=])*=*|(?:@[-#]*\w+\.[\w+.]\.*)+(?:(?:[\w+]|[-#*~^][-#*.~^]*[\w+]|=\S)(?:[^$=]|=+[^=])*=*)?)?)?\}:XF\$/,inside:{punctuation:{pattern:/[$:{}?.,|]/}},alias:"function"},"directive-inline":{pattern:/\$\w(?:#\d+\+?)?(?:\[[-\w.]+\])?:[-\/\w.]+\$/,inside:{punctuation:{pattern:/\$(?:\w:|C(?:\[|#\d))?|[:{[\]]/,inside:{tag:{pattern:/#\d/}}}},alias:"function"},"directive-block-open":{pattern:/\$\w+:\{|\$\w(?:#\d+\+?)?(?:\[[-\w.]+\])?:[-\w.]+:\{(?:![A-Z]+)?/,inside:{punctuation:{pattern:/\$(?:\w:|C(?:\[|#\d))?|[:{[\]]/,inside:{tag:{pattern:/#\d/}}},attribute:{pattern:/![A-Z]+$/,inside:{punctuation:{pattern:/!/}},alias:"keyword"}},alias:"function"},"directive-block-separator":{pattern:/\}:[-\w.]+:\{/,inside:{punctuation:{pattern:/[:{}]/}},alias:"function"},"directive-block-close":{pattern:/\}:[-\w.]+\$/,inside:{punctuation:{pattern:/[:{}$]/}},alias:"function"}}),Ye.languages.insertBefore("inside","punctuation",{variable:Ye.languages.xeora["function-inline"].inside.variable},Ye.languages.xeora["function-block"]),Ye.languages.xeoracube=Ye.languages.xeora})(t)}return xeora_1}var xmlDoc_1,hasRequiredXmlDoc;function requireXmlDoc(){if(hasRequiredXmlDoc)return xmlDoc_1;hasRequiredXmlDoc=1,xmlDoc_1=e,e.displayName="xmlDoc",e.aliases=[];function e(t){(function(Ye){function tt(it,ot){Ye.languages[it]&&Ye.languages.insertBefore(it,"comment",{"doc-comment":ot})}var rt=Ye.languages.markup.tag,nt={pattern:/\/\/\/.*/,greedy:!0,alias:"comment",inside:{tag:rt}},at={pattern:/'''.*/,greedy:!0,alias:"comment",inside:{tag:rt}};tt("csharp",nt),tt("fsharp",nt),tt("vbnet",at)})(t)}return xmlDoc_1}var xojo_1,hasRequiredXojo;function requireXojo(){if(hasRequiredXojo)return xojo_1;hasRequiredXojo=1,xojo_1=e,e.displayName="xojo",e.aliases=[];function e(t){t.languages.xojo={comment:{pattern:/(?:'|\/\/|Rem\b).+/i,greedy:!0},string:{pattern:/"(?:""|[^"])*"/,greedy:!0},number:[/(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:E[+-]?\d+)?/i,/&[bchou][a-z\d]+/i],directive:{pattern:/#(?:Else|ElseIf|Endif|If|Pragma)\b/i,alias:"property"},keyword:/\b(?:AddHandler|App|Array|As(?:signs)?|Auto|Boolean|Break|By(?:Ref|Val)|Byte|Call|Case|Catch|CFStringRef|CGFloat|Class|Color|Const|Continue|CString|Currency|CurrentMethodName|Declare|Delegate|Dim|Do(?:uble|wnTo)?|Each|Else(?:If)?|End|Enumeration|Event|Exception|Exit|Extends|False|Finally|For|Function|Get|GetTypeInfo|Global|GOTO|If|Implements|In|Inherits|Int(?:8|16|32|64|eger|erface)?|Lib|Loop|Me|Module|Next|Nil|Object|Optional|OSType|ParamArray|Private|Property|Protected|PString|Ptr|Raise(?:Event)?|ReDim|RemoveHandler|Return|Select(?:or)?|Self|Set|Shared|Short|Single|Soft|Static|Step|String|Sub|Super|Text|Then|To|True|Try|Ubound|UInt(?:8|16|32|64|eger)?|Until|Using|Var(?:iant)?|Wend|While|WindowPtr|WString)\b/i,operator:/<[=>]?|>=?|[+\-*\/\\^=]|\b(?:AddressOf|And|Ctype|IsA?|Mod|New|Not|Or|WeakAddressOf|Xor)\b/i,punctuation:/[.,;:()]/}}return xojo_1}var xquery_1,hasRequiredXquery;function requireXquery(){if(hasRequiredXquery)return xquery_1;hasRequiredXquery=1,xquery_1=e,e.displayName="xquery",e.aliases=[];function e(t){(function(Ye){Ye.languages.xquery=Ye.languages.extend("markup",{"xquery-comment":{pattern:/\(:[\s\S]*?:\)/,greedy:!0,alias:"comment"},string:{pattern:/(["'])(?:\1\1|(?!\1)[\s\S])*\1/,greedy:!0},extension:{pattern:/\(#.+?#\)/,alias:"symbol"},variable:/\$[-\w:]+/,axis:{pattern:/(^|[^-])(?:ancestor(?:-or-self)?|attribute|child|descendant(?:-or-self)?|following(?:-sibling)?|parent|preceding(?:-sibling)?|self)(?=::)/,lookbehind:!0,alias:"operator"},"keyword-operator":{pattern:/(^|[^:-])\b(?:and|castable as|div|eq|except|ge|gt|idiv|instance of|intersect|is|le|lt|mod|ne|or|union)\b(?=$|[^:-])/,lookbehind:!0,alias:"operator"},keyword:{pattern:/(^|[^:-])\b(?:as|ascending|at|base-uri|boundary-space|case|cast as|collation|construction|copy-namespaces|declare|default|descending|else|empty (?:greatest|least)|encoding|every|external|for|function|if|import|in|inherit|lax|let|map|module|namespace|no-inherit|no-preserve|option|order(?: by|ed|ing)?|preserve|return|satisfies|schema|some|stable|strict|strip|then|to|treat as|typeswitch|unordered|validate|variable|version|where|xquery)\b(?=$|[^:-])/,lookbehind:!0},function:/[\w-]+(?::[\w-]+)*(?=\s*\()/,"xquery-element":{pattern:/(element\s+)[\w-]+(?::[\w-]+)*/,lookbehind:!0,alias:"tag"},"xquery-attribute":{pattern:/(attribute\s+)[\w-]+(?::[\w-]+)*/,lookbehind:!0,alias:"attr-name"},builtin:{pattern:/(^|[^:-])\b(?:attribute|comment|document|element|processing-instruction|text|xs:(?:ENTITIES|ENTITY|ID|IDREFS?|NCName|NMTOKENS?|NOTATION|Name|QName|anyAtomicType|anyType|anyURI|base64Binary|boolean|byte|date|dateTime|dayTimeDuration|decimal|double|duration|float|gDay|gMonth|gMonthDay|gYear|gYearMonth|hexBinary|int|integer|language|long|negativeInteger|nonNegativeInteger|nonPositiveInteger|normalizedString|positiveInteger|short|string|time|token|unsigned(?:Byte|Int|Long|Short)|untyped(?:Atomic)?|yearMonthDuration))\b(?=$|[^:-])/,lookbehind:!0},number:/\b\d+(?:\.\d+)?(?:E[+-]?\d+)?/,operator:[/[+*=?|@]|\.\.?|:=|!=|<[=<]?|>[=>]?/,{pattern:/(\s)-(?=\s)/,lookbehind:!0}],punctuation:/[[\](){},;:/]/}),Ye.languages.xquery.tag.pattern=/<\/?(?!\d)[^\s>\/=$<%]+(?:\s+[^\s>\/=]+(?:=(?:("|')(?:\\[\s\S]|\{(?!\{)(?:\{(?:\{[^{}]*\}|[^{}])*\}|[^{}])+\}|(?!\1)[^\\])*\1|[^\s'">=]+))?)*\s*\/?>/,Ye.languages.xquery.tag.inside["attr-value"].pattern=/=(?:("|')(?:\\[\s\S]|\{(?!\{)(?:\{(?:\{[^{}]*\}|[^{}])*\}|[^{}])+\}|(?!\1)[^\\])*\1|[^\s'">=]+)/,Ye.languages.xquery.tag.inside["attr-value"].inside.punctuation=/^="|"$/,Ye.languages.xquery.tag.inside["attr-value"].inside.expression={pattern:/\{(?!\{)(?:\{(?:\{[^{}]*\}|[^{}])*\}|[^{}])+\}/,inside:Ye.languages.xquery,alias:"language-xquery"};var tt=function(nt){return typeof nt=="string"?nt:typeof nt.content=="string"?nt.content:nt.content.map(tt).join("")},rt=function(nt){for(var at=[],it=0;it<nt.length;it++){var ot=nt[it],ct=!1;if(typeof ot!="string"&&(ot.type==="tag"&&ot.content[0]&&ot.content[0].type==="tag"?ot.content[0].content[0].content==="</"?at.length>0&&at[at.length-1].tagName===tt(ot.content[0].content[1])&&at.pop():ot.content[ot.content.length-1].content==="/>"||at.push({tagName:tt(ot.content[0].content[1]),openedBraces:0}):at.length>0&&ot.type==="punctuation"&&ot.content==="{"&&(!nt[it+1]||nt[it+1].type!=="punctuation"||nt[it+1].content!=="{")&&(!nt[it-1]||nt[it-1].type!=="plain-text"||nt[it-1].content!=="{")?at[at.length-1].openedBraces++:at.length>0&&at[at.length-1].openedBraces>0&&ot.type==="punctuation"&&ot.content==="}"?at[at.length-1].openedBraces--:ot.type!=="comment"&&(ct=!0)),(ct||typeof ot=="string")&&at.length>0&&at[at.length-1].openedBraces===0){var At=tt(ot);it<nt.length-1&&(typeof nt[it+1]=="string"||nt[it+1].type==="plain-text")&&(At+=tt(nt[it+1]),nt.splice(it+1,1)),it>0&&(typeof nt[it-1]=="string"||nt[it-1].type==="plain-text")&&(At=tt(nt[it-1])+At,nt.splice(it-1,1),it--),/^\s+$/.test(At)?nt[it]=At:nt[it]=new Ye.Token("plain-text",At,null,At)}ot.content&&typeof ot.content!="string"&&rt(ot.content)}};Ye.hooks.add("after-tokenize",function(nt){nt.language==="xquery"&&rt(nt.tokens)})})(t)}return xquery_1}var yang_1,hasRequiredYang;function requireYang(){if(hasRequiredYang)return yang_1;hasRequiredYang=1,yang_1=e,e.displayName="yang",e.aliases=[];function e(t){t.languages.yang={comment:/\/\*[\s\S]*?\*\/|\/\/.*/,string:{pattern:/"(?:[^\\"]|\\.)*"|'[^']*'/,greedy:!0},keyword:{pattern:/(^|[{};\r\n][ \t]*)[a-z_][\w.-]*/i,lookbehind:!0},namespace:{pattern:/(\s)[a-z_][\w.-]*(?=:)/i,lookbehind:!0},boolean:/\b(?:false|true)\b/,operator:/\+/,punctuation:/[{};:]/}}return yang_1}var zig_1,hasRequiredZig;function requireZig(){if(hasRequiredZig)return zig_1;hasRequiredZig=1,zig_1=e,e.displayName="zig",e.aliases=[];function e(t){(function(Ye){function tt(At){return function(){return At}}var rt=/\b(?:align|allowzero|and|anyframe|anytype|asm|async|await|break|cancel|catch|comptime|const|continue|defer|else|enum|errdefer|error|export|extern|fn|for|if|inline|linksection|nakedcc|noalias|nosuspend|null|or|orelse|packed|promise|pub|resume|return|stdcallcc|struct|suspend|switch|test|threadlocal|try|undefined|union|unreachable|usingnamespace|var|volatile|while)\b/,nt="\\b(?!"+rt.source+")(?!\\d)\\w+\\b",at=/align\s*\((?:[^()]|\([^()]*\))*\)/.source,it=/(?:\?|\bpromise->|(?:\[[^[\]]*\]|\*(?!\*)|\*\*)(?:\s*<ALIGN>|\s*const\b|\s*volatile\b|\s*allowzero\b)*)/.source.replace(/<ALIGN>/g,tt(at)),ot=/(?:\bpromise\b|(?:\berror\.)?<ID>(?:\.<ID>)*(?!\s+<ID>))/.source.replace(/<ID>/g,tt(nt)),ct="(?!\\s)(?:!?\\s*(?:"+it+"\\s*)*"+ot+")+";Ye.languages.zig={comment:[{pattern:/\/\/[/!].*/,alias:"doc-comment"},/\/{2}.*/],string:[{pattern:/(^|[^\\@])c?"(?:[^"\\\r\n]|\\.)*"/,lookbehind:!0,greedy:!0},{pattern:/([\r\n])([ \t]+c?\\{2}).*(?:(?:\r\n?|\n)\2.*)*/,lookbehind:!0,greedy:!0}],char:{pattern:/(^|[^\\])'(?:[^'\\\r\n]|[\uD800-\uDFFF]{2}|\\(?:.|x[a-fA-F\d]{2}|u\{[a-fA-F\d]{1,6}\}))'/,lookbehind:!0,greedy:!0},builtin:/\B@(?!\d)\w+(?=\s*\()/,label:{pattern:/(\b(?:break|continue)\s*:\s*)\w+\b|\b(?!\d)\w+\b(?=\s*:\s*(?:\{|while\b))/,lookbehind:!0},"class-name":[/\b(?!\d)\w+(?=\s*=\s*(?:(?:extern|packed)\s+)?(?:enum|struct|union)\s*[({])/,{pattern:RegExp(/(:\s*)<TYPE>(?=\s*(?:<ALIGN>\s*)?[=;,)])|<TYPE>(?=\s*(?:<ALIGN>\s*)?\{)/.source.replace(/<TYPE>/g,tt(ct)).replace(/<ALIGN>/g,tt(at))),lookbehind:!0,inside:null},{pattern:RegExp(/(\)\s*)<TYPE>(?=\s*(?:<ALIGN>\s*)?;)/.source.replace(/<TYPE>/g,tt(ct)).replace(/<ALIGN>/g,tt(at))),lookbehind:!0,inside:null}],"builtin-type":{pattern:/\b(?:anyerror|bool|c_u?(?:int|long|longlong|short)|c_longdouble|c_void|comptime_(?:float|int)|f(?:16|32|64|128)|[iu](?:8|16|32|64|128|size)|noreturn|type|void)\b/,alias:"keyword"},keyword:rt,function:/\b(?!\d)\w+(?=\s*\()/,number:/\b(?:0b[01]+|0o[0-7]+|0x[a-fA-F\d]+(?:\.[a-fA-F\d]*)?(?:[pP][+-]?[a-fA-F\d]+)?|\d+(?:\.\d*)?(?:[eE][+-]?\d+)?)\b/,boolean:/\b(?:false|true)\b/,operator:/\.[*?]|\.{2,3}|[-=]>|\*\*|\+\+|\|\||(?:<<|>>|[-+*]%|[-+*/%^&|<>!=])=?|[?~]/,punctuation:/[.:,;(){}[\]]/},Ye.languages.zig["class-name"].forEach(function(At){At.inside===null&&(At.inside=Ye.languages.zig)})})(t)}return zig_1}var refractor_1,hasRequiredRefractor;function requireRefractor(){if(hasRequiredRefractor)return refractor_1;hasRequiredRefractor=1;var e=requireCore$2();return refractor_1=e,e.register(requireAbap()),e.register(requireAbnf()),e.register(requireActionscript()),e.register(requireAda()),e.register(requireAgda()),e.register(requireAl()),e.register(requireAntlr4()),e.register(requireApacheconf()),e.register(requireApex()),e.register(requireApl()),e.register(requireApplescript()),e.register(requireAql()),e.register(requireArduino()),e.register(requireArff()),e.register(requireAsciidoc()),e.register(requireAsm6502()),e.register(requireAsmatmel()),e.register(requireAspnet()),e.register(requireAutohotkey()),e.register(requireAutoit()),e.register(requireAvisynth()),e.register(requireAvroIdl()),e.register(requireBash()),e.register(requireBasic()),e.register(requireBatch()),e.register(requireBbcode()),e.register(requireBicep()),e.register(requireBirb()),e.register(requireBison()),e.register(requireBnf()),e.register(requireBrainfuck()),e.register(requireBrightscript()),e.register(requireBro()),e.register(requireBsl()),e.register(requireC()),e.register(requireCfscript()),e.register(requireChaiscript()),e.register(requireCil()),e.register(requireClojure()),e.register(requireCmake()),e.register(requireCobol()),e.register(requireCoffeescript()),e.register(requireConcurnas()),e.register(requireCoq()),e.register(requireCpp()),e.register(requireCrystal()),e.register(requireCsharp()),e.register(requireCshtml()),e.register(requireCsp()),e.register(requireCssExtras()),e.register(requireCsv()),e.register(requireCypher()),e.register(requireD()),e.register(requireDart()),e.register(requireDataweave()),e.register(requireDax()),e.register(requireDhall()),e.register(requireDiff()),e.register(requireDjango()),e.register(requireDnsZoneFile()),e.register(requireDocker()),e.register(requireDot()),e.register(requireEbnf()),e.register(requireEditorconfig()),e.register(requireEiffel()),e.register(requireEjs()),e.register(requireElixir()),e.register(requireElm()),e.register(requireErb()),e.register(requireErlang()),e.register(requireEtlua()),e.register(requireExcelFormula()),e.register(requireFactor()),e.register(require_false()),e.register(requireFirestoreSecurityRules()),e.register(requireFlow()),e.register(requireFortran()),e.register(requireFsharp()),e.register(requireFtl()),e.register(requireGap()),e.register(requireGcode()),e.register(requireGdscript()),e.register(requireGedcom()),e.register(requireGherkin()),e.register(requireGit()),e.register(requireGlsl()),e.register(requireGml()),e.register(requireGn()),e.register(requireGoModule()),e.register(requireGo()),e.register(requireGraphql()),e.register(requireGroovy()),e.register(requireHaml()),e.register(requireHandlebars()),e.register(requireHaskell()),e.register(requireHaxe()),e.register(requireHcl()),e.register(requireHlsl()),e.register(requireHoon()),e.register(requireHpkp()),e.register(requireHsts()),e.register(requireHttp()),e.register(requireIchigojam()),e.register(requireIcon()),e.register(requireIcuMessageFormat()),e.register(requireIdris()),e.register(requireIecst()),e.register(requireIgnore()),e.register(requireInform7()),e.register(requireIni()),e.register(requireIo()),e.register(requireJ()),e.register(requireJava()),e.register(requireJavadoc()),e.register(requireJavadoclike()),e.register(requireJavastacktrace()),e.register(requireJexl()),e.register(requireJolie()),e.register(requireJq()),e.register(requireJsExtras()),e.register(requireJsTemplates()),e.register(requireJsdoc()),e.register(requireJson$1()),e.register(requireJson5()),e.register(requireJsonp()),e.register(requireJsstacktrace()),e.register(requireJsx()),e.register(requireJulia()),e.register(requireKeepalived()),e.register(requireKeyman()),e.register(requireKotlin()),e.register(requireKumir()),e.register(requireKusto()),e.register(requireLatex()),e.register(requireLatte()),e.register(requireLess()),e.register(requireLilypond()),e.register(requireLiquid()),e.register(requireLisp()),e.register(requireLivescript()),e.register(requireLlvm()),e.register(requireLog()),e.register(requireLolcode()),e.register(requireLua()),e.register(requireMagma()),e.register(requireMakefile()),e.register(requireMarkdown()),e.register(requireMarkupTemplating()),e.register(requireMatlab()),e.register(requireMaxscript()),e.register(requireMel()),e.register(requireMermaid()),e.register(requireMizar()),e.register(requireMongodb()),e.register(requireMonkey()),e.register(requireMoonscript()),e.register(requireN1ql()),e.register(requireN4js()),e.register(requireNand2tetrisHdl()),e.register(requireNaniscript()),e.register(requireNasm()),e.register(requireNeon()),e.register(requireNevod()),e.register(requireNginx()),e.register(requireNim()),e.register(requireNix()),e.register(requireNsis()),e.register(requireObjectivec()),e.register(requireOcaml()),e.register(requireOpencl()),e.register(requireOpenqasm()),e.register(requireOz()),e.register(requireParigp()),e.register(requireParser()),e.register(requirePascal()),e.register(requirePascaligo()),e.register(requirePcaxis()),e.register(requirePeoplecode()),e.register(requirePerl()),e.register(requirePhpExtras()),e.register(requirePhp()),e.register(requirePhpdoc()),e.register(requirePlsql()),e.register(requirePowerquery()),e.register(requirePowershell()),e.register(requireProcessing()),e.register(requireProlog()),e.register(requirePromql()),e.register(requireProperties$2()),e.register(requireProtobuf()),e.register(requirePsl()),e.register(requirePug()),e.register(requirePuppet()),e.register(requirePure()),e.register(requirePurebasic()),e.register(requirePurescript()),e.register(requirePython()),e.register(requireQ()),e.register(requireQml()),e.register(requireQore()),e.register(requireQsharp()),e.register(requireR()),e.register(requireRacket()),e.register(requireReason()),e.register(requireRegex()),e.register(requireRego()),e.register(requireRenpy()),e.register(requireRest()),e.register(requireRip()),e.register(requireRoboconf()),e.register(requireRobotframework()),e.register(requireRuby()),e.register(requireRust()),e.register(requireSas()),e.register(requireSass()),e.register(requireScala()),e.register(requireScheme()),e.register(requireScss()),e.register(requireShellSession()),e.register(requireSmali()),e.register(requireSmalltalk()),e.register(requireSmarty()),e.register(requireSml()),e.register(requireSolidity()),e.register(requireSolutionFile()),e.register(requireSoy()),e.register(requireSparql()),e.register(requireSplunkSpl()),e.register(requireSqf()),e.register(requireSql()),e.register(requireSquirrel()),e.register(requireStan()),e.register(requireStylus()),e.register(requireSwift()),e.register(requireSystemd()),e.register(requireT4Cs()),e.register(requireT4Templating()),e.register(requireT4Vb()),e.register(requireTap()),e.register(requireTcl()),e.register(requireTextile()),e.register(requireToml()),e.register(requireTremor()),e.register(requireTsx()),e.register(requireTt2()),e.register(requireTurtle()),e.register(requireTwig()),e.register(requireTypescript()),e.register(requireTyposcript()),e.register(requireUnrealscript()),e.register(requireUorazor()),e.register(requireUri$1()),e.register(requireV()),e.register(requireVala()),e.register(requireVbnet()),e.register(requireVelocity()),e.register(requireVerilog()),e.register(requireVhdl()),e.register(requireVim()),e.register(requireVisualBasic()),e.register(requireWarpscript()),e.register(requireWasm()),e.register(requireWebIdl()),e.register(requireWiki()),e.register(requireWolfram()),e.register(requireWren()),e.register(requireXeora()),e.register(requireXmlDoc()),e.register(requireXojo()),e.register(requireXquery()),e.register(requireYaml()),e.register(requireYang()),e.register(requireZig()),refractor_1}var refractorExports=requireRefractor();const refractor=getDefaultExportFromCjs(refractorExports);var highlighter=highlight(refractor,defaultStyle);highlighter.supportedLanguages=supportedLanguages;const oneDark={'code[class*="language-"]':{background:"hsl(220, 13%, 18%)",color:"hsl(220, 14%, 71%)",textShadow:"0 1px rgba(0, 0, 0, 0.3)",fontFamily:'"Fira Code", "Fira Mono", Menlo, Consolas, "DejaVu Sans Mono", monospace',direction:"ltr",textAlign:"left",whiteSpace:"pre",wordSpacing:"normal",wordBreak:"normal",lineHeight:"1.5",MozTabSize:"2",OTabSize:"2",tabSize:"2",WebkitHyphens:"none",MozHyphens:"none",msHyphens:"none",hyphens:"none"},'pre[class*="language-"]':{background:"hsl(220, 13%, 18%)",color:"hsl(220, 14%, 71%)",textShadow:"0 1px rgba(0, 0, 0, 0.3)",fontFamily:'"Fira Code", "Fira Mono", Menlo, Consolas, "DejaVu Sans Mono", monospace',direction:"ltr",textAlign:"left",whiteSpace:"pre",wordSpacing:"normal",wordBreak:"normal",lineHeight:"1.5",MozTabSize:"2",OTabSize:"2",tabSize:"2",WebkitHyphens:"none",MozHyphens:"none",msHyphens:"none",hyphens:"none",padding:"1em",margin:"0.5em 0",overflow:"auto",borderRadius:"0.3em"},'code[class*="language-"]::-moz-selection':{background:"hsl(220, 13%, 28%)",color:"inherit",textShadow:"none"},'code[class*="language-"] *::-moz-selection':{background:"hsl(220, 13%, 28%)",color:"inherit",textShadow:"none"},'pre[class*="language-"] *::-moz-selection':{background:"hsl(220, 13%, 28%)",color:"inherit",textShadow:"none"},'code[class*="language-"]::selection':{background:"hsl(220, 13%, 28%)",color:"inherit",textShadow:"none"},'code[class*="language-"] *::selection':{background:"hsl(220, 13%, 28%)",color:"inherit",textShadow:"none"},'pre[class*="language-"] *::selection':{background:"hsl(220, 13%, 28%)",color:"inherit",textShadow:"none"},':not(pre) > code[class*="language-"]':{padding:"0.2em 0.3em",borderRadius:"0.3em",whiteSpace:"normal"},comment:{color:"hsl(220, 10%, 40%)",fontStyle:"italic"},prolog:{color:"hsl(220, 10%, 40%)"},cdata:{color:"hsl(220, 10%, 40%)"},doctype:{color:"hsl(220, 14%, 71%)"},punctuation:{color:"hsl(220, 14%, 71%)"},entity:{color:"hsl(220, 14%, 71%)",cursor:"help"},"attr-name":{color:"hsl(29, 54%, 61%)"},"class-name":{color:"hsl(29, 54%, 61%)"},boolean:{color:"hsl(29, 54%, 61%)"},constant:{color:"hsl(29, 54%, 61%)"},number:{color:"hsl(29, 54%, 61%)"},atrule:{color:"hsl(29, 54%, 61%)"},keyword:{color:"hsl(286, 60%, 67%)"},property:{color:"hsl(355, 65%, 65%)"},tag:{color:"hsl(355, 65%, 65%)"},symbol:{color:"hsl(355, 65%, 65%)"},deleted:{color:"hsl(355, 65%, 65%)"},important:{color:"hsl(355, 65%, 65%)"},selector:{color:"hsl(95, 38%, 62%)"},string:{color:"hsl(95, 38%, 62%)"},char:{color:"hsl(95, 38%, 62%)"},builtin:{color:"hsl(95, 38%, 62%)"},inserted:{color:"hsl(95, 38%, 62%)"},regex:{color:"hsl(95, 38%, 62%)"},"attr-value":{color:"hsl(95, 38%, 62%)"},"attr-value > .token.punctuation":{color:"hsl(95, 38%, 62%)"},variable:{color:"hsl(207, 82%, 66%)"},operator:{color:"hsl(207, 82%, 66%)"},function:{color:"hsl(207, 82%, 66%)"},url:{color:"hsl(187, 47%, 55%)"},"attr-value > .token.punctuation.attr-equals":{color:"hsl(220, 14%, 71%)"},"special-attr > .token.attr-value > .token.value.css":{color:"hsl(220, 14%, 71%)"},".language-css .token.selector":{color:"hsl(355, 65%, 65%)"},".language-css .token.property":{color:"hsl(220, 14%, 71%)"},".language-css .token.function":{color:"hsl(187, 47%, 55%)"},".language-css .token.url > .token.function":{color:"hsl(187, 47%, 55%)"},".language-css .token.url > .token.string.url":{color:"hsl(95, 38%, 62%)"},".language-css .token.important":{color:"hsl(286, 60%, 67%)"},".language-css .token.atrule .token.rule":{color:"hsl(286, 60%, 67%)"},".language-javascript .token.operator":{color:"hsl(286, 60%, 67%)"},".language-javascript .token.template-string > .token.interpolation > .token.interpolation-punctuation.punctuation":{color:"hsl(5, 48%, 51%)"},".language-json .token.operator":{color:"hsl(220, 14%, 71%)"},".language-json .token.null.keyword":{color:"hsl(29, 54%, 61%)"},".language-markdown .token.url":{color:"hsl(220, 14%, 71%)"},".language-markdown .token.url > .token.operator":{color:"hsl(220, 14%, 71%)"},".language-markdown .token.url-reference.url > .token.string":{color:"hsl(220, 14%, 71%)"},".language-markdown .token.url > .token.content":{color:"hsl(207, 82%, 66%)"},".language-markdown .token.url > .token.url":{color:"hsl(187, 47%, 55%)"},".language-markdown .token.url-reference.url":{color:"hsl(187, 47%, 55%)"},".language-markdown .token.blockquote.punctuation":{color:"hsl(220, 10%, 40%)",fontStyle:"italic"},".language-markdown .token.hr.punctuation":{color:"hsl(220, 10%, 40%)",fontStyle:"italic"},".language-markdown .token.code-snippet":{color:"hsl(95, 38%, 62%)"},".language-markdown .token.bold .token.content":{color:"hsl(29, 54%, 61%)"},".language-markdown .token.italic .token.content":{color:"hsl(286, 60%, 67%)"},".language-markdown .token.strike .token.content":{color:"hsl(355, 65%, 65%)"},".language-markdown .token.strike .token.punctuation":{color:"hsl(355, 65%, 65%)"},".language-markdown .token.list.punctuation":{color:"hsl(355, 65%, 65%)"},".language-markdown .token.title.important > .token.punctuation":{color:"hsl(355, 65%, 65%)"},bold:{fontWeight:"bold"},italic:{fontStyle:"italic"},namespace:{Opacity:"0.8"},"token.tab:not(:empty):before":{color:"hsla(220, 14%, 71%, 0.15)",textShadow:"none"},"token.cr:before":{color:"hsla(220, 14%, 71%, 0.15)",textShadow:"none"},"token.lf:before":{color:"hsla(220, 14%, 71%, 0.15)",textShadow:"none"},"token.space:before":{color:"hsla(220, 14%, 71%, 0.15)",textShadow:"none"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item":{marginRight:"0.4em"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > button":{background:"hsl(220, 13%, 26%)",color:"hsl(220, 9%, 55%)",padding:"0.1em 0.4em",borderRadius:"0.3em"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > a":{background:"hsl(220, 13%, 26%)",color:"hsl(220, 9%, 55%)",padding:"0.1em 0.4em",borderRadius:"0.3em"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > span":{background:"hsl(220, 13%, 26%)",color:"hsl(220, 9%, 55%)",padding:"0.1em 0.4em",borderRadius:"0.3em"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > button:hover":{background:"hsl(220, 13%, 28%)",color:"hsl(220, 14%, 71%)"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > button:focus":{background:"hsl(220, 13%, 28%)",color:"hsl(220, 14%, 71%)"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > a:hover":{background:"hsl(220, 13%, 28%)",color:"hsl(220, 14%, 71%)"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > a:focus":{background:"hsl(220, 13%, 28%)",color:"hsl(220, 14%, 71%)"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > span:hover":{background:"hsl(220, 13%, 28%)",color:"hsl(220, 14%, 71%)"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > span:focus":{background:"hsl(220, 13%, 28%)",color:"hsl(220, 14%, 71%)"},".line-highlight.line-highlight":{background:"hsla(220, 100%, 80%, 0.04)"},".line-highlight.line-highlight:before":{background:"hsl(220, 13%, 26%)",color:"hsl(220, 14%, 71%)",padding:"0.1em 0.6em",borderRadius:"0.3em",boxShadow:"0 2px 0 0 rgba(0, 0, 0, 0.2)"},".line-highlight.line-highlight[data-end]:after":{background:"hsl(220, 13%, 26%)",color:"hsl(220, 14%, 71%)",padding:"0.1em 0.6em",borderRadius:"0.3em",boxShadow:"0 2px 0 0 rgba(0, 0, 0, 0.2)"},"pre[id].linkable-line-numbers.linkable-line-numbers span.line-numbers-rows > span:hover:before":{backgroundColor:"hsla(220, 100%, 80%, 0.04)"},".line-numbers.line-numbers .line-numbers-rows":{borderRightColor:"hsla(220, 14%, 71%, 0.15)"},".command-line .command-line-prompt":{borderRightColor:"hsla(220, 14%, 71%, 0.15)"},".line-numbers .line-numbers-rows > span:before":{color:"hsl(220, 14%, 45%)"},".command-line .command-line-prompt > span:before":{color:"hsl(220, 14%, 45%)"},".rainbow-braces .token.token.punctuation.brace-level-1":{color:"hsl(355, 65%, 65%)"},".rainbow-braces .token.token.punctuation.brace-level-5":{color:"hsl(355, 65%, 65%)"},".rainbow-braces .token.token.punctuation.brace-level-9":{color:"hsl(355, 65%, 65%)"},".rainbow-braces .token.token.punctuation.brace-level-2":{color:"hsl(95, 38%, 62%)"},".rainbow-braces .token.token.punctuation.brace-level-6":{color:"hsl(95, 38%, 62%)"},".rainbow-braces .token.token.punctuation.brace-level-10":{color:"hsl(95, 38%, 62%)"},".rainbow-braces .token.token.punctuation.brace-level-3":{color:"hsl(207, 82%, 66%)"},".rainbow-braces .token.token.punctuation.brace-level-7":{color:"hsl(207, 82%, 66%)"},".rainbow-braces .token.token.punctuation.brace-level-11":{color:"hsl(207, 82%, 66%)"},".rainbow-braces .token.token.punctuation.brace-level-4":{color:"hsl(286, 60%, 67%)"},".rainbow-braces .token.token.punctuation.brace-level-8":{color:"hsl(286, 60%, 67%)"},".rainbow-braces .token.token.punctuation.brace-level-12":{color:"hsl(286, 60%, 67%)"},"pre.diff-highlight > code .token.token.deleted:not(.prefix)":{backgroundColor:"hsla(353, 100%, 66%, 0.15)"},"pre > code.diff-highlight .token.token.deleted:not(.prefix)":{backgroundColor:"hsla(353, 100%, 66%, 0.15)"},"pre.diff-highlight > code .token.token.deleted:not(.prefix)::-moz-selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre.diff-highlight > code .token.token.deleted:not(.prefix) *::-moz-selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre > code.diff-highlight .token.token.deleted:not(.prefix)::-moz-selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre > code.diff-highlight .token.token.deleted:not(.prefix) *::-moz-selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre.diff-highlight > code .token.token.deleted:not(.prefix)::selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre.diff-highlight > code .token.token.deleted:not(.prefix) *::selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre > code.diff-highlight .token.token.deleted:not(.prefix)::selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre > code.diff-highlight .token.token.deleted:not(.prefix) *::selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre.diff-highlight > code .token.token.inserted:not(.prefix)":{backgroundColor:"hsla(137, 100%, 55%, 0.15)"},"pre > code.diff-highlight .token.token.inserted:not(.prefix)":{backgroundColor:"hsla(137, 100%, 55%, 0.15)"},"pre.diff-highlight > code .token.token.inserted:not(.prefix)::-moz-selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre.diff-highlight > code .token.token.inserted:not(.prefix) *::-moz-selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre > code.diff-highlight .token.token.inserted:not(.prefix)::-moz-selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre > code.diff-highlight .token.token.inserted:not(.prefix) *::-moz-selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre.diff-highlight > code .token.token.inserted:not(.prefix)::selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre.diff-highlight > code .token.token.inserted:not(.prefix) *::selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre > code.diff-highlight .token.token.inserted:not(.prefix)::selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre > code.diff-highlight .token.token.inserted:not(.prefix) *::selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},".prism-previewer.prism-previewer:before":{borderColor:"hsl(224, 13%, 17%)"},".prism-previewer-gradient.prism-previewer-gradient div":{borderColor:"hsl(224, 13%, 17%)",borderRadius:"0.3em"},".prism-previewer-color.prism-previewer-color:before":{borderRadius:"0.3em"},".prism-previewer-easing.prism-previewer-easing:before":{borderRadius:"0.3em"},".prism-previewer.prism-previewer:after":{borderTopColor:"hsl(224, 13%, 17%)"},".prism-previewer-flipped.prism-previewer-flipped.after":{borderBottomColor:"hsl(224, 13%, 17%)"},".prism-previewer-angle.prism-previewer-angle:before":{background:"hsl(219, 13%, 22%)"},".prism-previewer-time.prism-previewer-time:before":{background:"hsl(219, 13%, 22%)"},".prism-previewer-easing.prism-previewer-easing":{background:"hsl(219, 13%, 22%)"},".prism-previewer-angle.prism-previewer-angle circle":{stroke:"hsl(220, 14%, 71%)",strokeOpacity:"1"},".prism-previewer-time.prism-previewer-time circle":{stroke:"hsl(220, 14%, 71%)",strokeOpacity:"1"},".prism-previewer-easing.prism-previewer-easing circle":{stroke:"hsl(220, 14%, 71%)",fill:"transparent"},".prism-previewer-easing.prism-previewer-easing path":{stroke:"hsl(220, 14%, 71%)"},".prism-previewer-easing.prism-previewer-easing line":{stroke:"hsl(220, 14%, 71%)"}},oneLight={'code[class*="language-"]':{background:"hsl(230, 1%, 98%)",color:"hsl(230, 8%, 24%)",fontFamily:'"Fira Code", "Fira Mono", Menlo, Consolas, "DejaVu Sans Mono", monospace',direction:"ltr",textAlign:"left",whiteSpace:"pre",wordSpacing:"normal",wordBreak:"normal",lineHeight:"1.5",MozTabSize:"2",OTabSize:"2",tabSize:"2",WebkitHyphens:"none",MozHyphens:"none",msHyphens:"none",hyphens:"none"},'pre[class*="language-"]':{background:"hsl(230, 1%, 98%)",color:"hsl(230, 8%, 24%)",fontFamily:'"Fira Code", "Fira Mono", Menlo, Consolas, "DejaVu Sans Mono", monospace',direction:"ltr",textAlign:"left",whiteSpace:"pre",wordSpacing:"normal",wordBreak:"normal",lineHeight:"1.5",MozTabSize:"2",OTabSize:"2",tabSize:"2",WebkitHyphens:"none",MozHyphens:"none",msHyphens:"none",hyphens:"none",padding:"1em",margin:"0.5em 0",overflow:"auto",borderRadius:"0.3em"},'code[class*="language-"]::-moz-selection':{background:"hsl(230, 1%, 90%)",color:"inherit"},'code[class*="language-"] *::-moz-selection':{background:"hsl(230, 1%, 90%)",color:"inherit"},'pre[class*="language-"] *::-moz-selection':{background:"hsl(230, 1%, 90%)",color:"inherit"},'code[class*="language-"]::selection':{background:"hsl(230, 1%, 90%)",color:"inherit"},'code[class*="language-"] *::selection':{background:"hsl(230, 1%, 90%)",color:"inherit"},'pre[class*="language-"] *::selection':{background:"hsl(230, 1%, 90%)",color:"inherit"},':not(pre) > code[class*="language-"]':{padding:"0.2em 0.3em",borderRadius:"0.3em",whiteSpace:"normal"},comment:{color:"hsl(230, 4%, 64%)",fontStyle:"italic"},prolog:{color:"hsl(230, 4%, 64%)"},cdata:{color:"hsl(230, 4%, 64%)"},doctype:{color:"hsl(230, 8%, 24%)"},punctuation:{color:"hsl(230, 8%, 24%)"},entity:{color:"hsl(230, 8%, 24%)",cursor:"help"},"attr-name":{color:"hsl(35, 99%, 36%)"},"class-name":{color:"hsl(35, 99%, 36%)"},boolean:{color:"hsl(35, 99%, 36%)"},constant:{color:"hsl(35, 99%, 36%)"},number:{color:"hsl(35, 99%, 36%)"},atrule:{color:"hsl(35, 99%, 36%)"},keyword:{color:"hsl(301, 63%, 40%)"},property:{color:"hsl(5, 74%, 59%)"},tag:{color:"hsl(5, 74%, 59%)"},symbol:{color:"hsl(5, 74%, 59%)"},deleted:{color:"hsl(5, 74%, 59%)"},important:{color:"hsl(5, 74%, 59%)"},selector:{color:"hsl(119, 34%, 47%)"},string:{color:"hsl(119, 34%, 47%)"},char:{color:"hsl(119, 34%, 47%)"},builtin:{color:"hsl(119, 34%, 47%)"},inserted:{color:"hsl(119, 34%, 47%)"},regex:{color:"hsl(119, 34%, 47%)"},"attr-value":{color:"hsl(119, 34%, 47%)"},"attr-value > .token.punctuation":{color:"hsl(119, 34%, 47%)"},variable:{color:"hsl(221, 87%, 60%)"},operator:{color:"hsl(221, 87%, 60%)"},function:{color:"hsl(221, 87%, 60%)"},url:{color:"hsl(198, 99%, 37%)"},"attr-value > .token.punctuation.attr-equals":{color:"hsl(230, 8%, 24%)"},"special-attr > .token.attr-value > .token.value.css":{color:"hsl(230, 8%, 24%)"},".language-css .token.selector":{color:"hsl(5, 74%, 59%)"},".language-css .token.property":{color:"hsl(230, 8%, 24%)"},".language-css .token.function":{color:"hsl(198, 99%, 37%)"},".language-css .token.url > .token.function":{color:"hsl(198, 99%, 37%)"},".language-css .token.url > .token.string.url":{color:"hsl(119, 34%, 47%)"},".language-css .token.important":{color:"hsl(301, 63%, 40%)"},".language-css .token.atrule .token.rule":{color:"hsl(301, 63%, 40%)"},".language-javascript .token.operator":{color:"hsl(301, 63%, 40%)"},".language-javascript .token.template-string > .token.interpolation > .token.interpolation-punctuation.punctuation":{color:"hsl(344, 84%, 43%)"},".language-json .token.operator":{color:"hsl(230, 8%, 24%)"},".language-json .token.null.keyword":{color:"hsl(35, 99%, 36%)"},".language-markdown .token.url":{color:"hsl(230, 8%, 24%)"},".language-markdown .token.url > .token.operator":{color:"hsl(230, 8%, 24%)"},".language-markdown .token.url-reference.url > .token.string":{color:"hsl(230, 8%, 24%)"},".language-markdown .token.url > .token.content":{color:"hsl(221, 87%, 60%)"},".language-markdown .token.url > .token.url":{color:"hsl(198, 99%, 37%)"},".language-markdown .token.url-reference.url":{color:"hsl(198, 99%, 37%)"},".language-markdown .token.blockquote.punctuation":{color:"hsl(230, 4%, 64%)",fontStyle:"italic"},".language-markdown .token.hr.punctuation":{color:"hsl(230, 4%, 64%)",fontStyle:"italic"},".language-markdown .token.code-snippet":{color:"hsl(119, 34%, 47%)"},".language-markdown .token.bold .token.content":{color:"hsl(35, 99%, 36%)"},".language-markdown .token.italic .token.content":{color:"hsl(301, 63%, 40%)"},".language-markdown .token.strike .token.content":{color:"hsl(5, 74%, 59%)"},".language-markdown .token.strike .token.punctuation":{color:"hsl(5, 74%, 59%)"},".language-markdown .token.list.punctuation":{color:"hsl(5, 74%, 59%)"},".language-markdown .token.title.important > .token.punctuation":{color:"hsl(5, 74%, 59%)"},bold:{fontWeight:"bold"},italic:{fontStyle:"italic"},namespace:{Opacity:"0.8"},"token.tab:not(:empty):before":{color:"hsla(230, 8%, 24%, 0.2)"},"token.cr:before":{color:"hsla(230, 8%, 24%, 0.2)"},"token.lf:before":{color:"hsla(230, 8%, 24%, 0.2)"},"token.space:before":{color:"hsla(230, 8%, 24%, 0.2)"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item":{marginRight:"0.4em"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > button":{background:"hsl(230, 1%, 90%)",color:"hsl(230, 6%, 44%)",padding:"0.1em 0.4em",borderRadius:"0.3em"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > a":{background:"hsl(230, 1%, 90%)",color:"hsl(230, 6%, 44%)",padding:"0.1em 0.4em",borderRadius:"0.3em"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > span":{background:"hsl(230, 1%, 90%)",color:"hsl(230, 6%, 44%)",padding:"0.1em 0.4em",borderRadius:"0.3em"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > button:hover":{background:"hsl(230, 1%, 78%)",color:"hsl(230, 8%, 24%)"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > button:focus":{background:"hsl(230, 1%, 78%)",color:"hsl(230, 8%, 24%)"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > a:hover":{background:"hsl(230, 1%, 78%)",color:"hsl(230, 8%, 24%)"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > a:focus":{background:"hsl(230, 1%, 78%)",color:"hsl(230, 8%, 24%)"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > span:hover":{background:"hsl(230, 1%, 78%)",color:"hsl(230, 8%, 24%)"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > span:focus":{background:"hsl(230, 1%, 78%)",color:"hsl(230, 8%, 24%)"},".line-highlight.line-highlight":{background:"hsla(230, 8%, 24%, 0.05)"},".line-highlight.line-highlight:before":{background:"hsl(230, 1%, 90%)",color:"hsl(230, 8%, 24%)",padding:"0.1em 0.6em",borderRadius:"0.3em",boxShadow:"0 2px 0 0 rgba(0, 0, 0, 0.2)"},".line-highlight.line-highlight[data-end]:after":{background:"hsl(230, 1%, 90%)",color:"hsl(230, 8%, 24%)",padding:"0.1em 0.6em",borderRadius:"0.3em",boxShadow:"0 2px 0 0 rgba(0, 0, 0, 0.2)"},"pre[id].linkable-line-numbers.linkable-line-numbers span.line-numbers-rows > span:hover:before":{backgroundColor:"hsla(230, 8%, 24%, 0.05)"},".line-numbers.line-numbers .line-numbers-rows":{borderRightColor:"hsla(230, 8%, 24%, 0.2)"},".command-line .command-line-prompt":{borderRightColor:"hsla(230, 8%, 24%, 0.2)"},".line-numbers .line-numbers-rows > span:before":{color:"hsl(230, 1%, 62%)"},".command-line .command-line-prompt > span:before":{color:"hsl(230, 1%, 62%)"},".rainbow-braces .token.token.punctuation.brace-level-1":{color:"hsl(5, 74%, 59%)"},".rainbow-braces .token.token.punctuation.brace-level-5":{color:"hsl(5, 74%, 59%)"},".rainbow-braces .token.token.punctuation.brace-level-9":{color:"hsl(5, 74%, 59%)"},".rainbow-braces .token.token.punctuation.brace-level-2":{color:"hsl(119, 34%, 47%)"},".rainbow-braces .token.token.punctuation.brace-level-6":{color:"hsl(119, 34%, 47%)"},".rainbow-braces .token.token.punctuation.brace-level-10":{color:"hsl(119, 34%, 47%)"},".rainbow-braces .token.token.punctuation.brace-level-3":{color:"hsl(221, 87%, 60%)"},".rainbow-braces .token.token.punctuation.brace-level-7":{color:"hsl(221, 87%, 60%)"},".rainbow-braces .token.token.punctuation.brace-level-11":{color:"hsl(221, 87%, 60%)"},".rainbow-braces .token.token.punctuation.brace-level-4":{color:"hsl(301, 63%, 40%)"},".rainbow-braces .token.token.punctuation.brace-level-8":{color:"hsl(301, 63%, 40%)"},".rainbow-braces .token.token.punctuation.brace-level-12":{color:"hsl(301, 63%, 40%)"},"pre.diff-highlight > code .token.token.deleted:not(.prefix)":{backgroundColor:"hsla(353, 100%, 66%, 0.15)"},"pre > code.diff-highlight .token.token.deleted:not(.prefix)":{backgroundColor:"hsla(353, 100%, 66%, 0.15)"},"pre.diff-highlight > code .token.token.deleted:not(.prefix)::-moz-selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre.diff-highlight > code .token.token.deleted:not(.prefix) *::-moz-selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre > code.diff-highlight .token.token.deleted:not(.prefix)::-moz-selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre > code.diff-highlight .token.token.deleted:not(.prefix) *::-moz-selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre.diff-highlight > code .token.token.deleted:not(.prefix)::selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre.diff-highlight > code .token.token.deleted:not(.prefix) *::selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre > code.diff-highlight .token.token.deleted:not(.prefix)::selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre > code.diff-highlight .token.token.deleted:not(.prefix) *::selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre.diff-highlight > code .token.token.inserted:not(.prefix)":{backgroundColor:"hsla(137, 100%, 55%, 0.15)"},"pre > code.diff-highlight .token.token.inserted:not(.prefix)":{backgroundColor:"hsla(137, 100%, 55%, 0.15)"},"pre.diff-highlight > code .token.token.inserted:not(.prefix)::-moz-selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre.diff-highlight > code .token.token.inserted:not(.prefix) *::-moz-selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre > code.diff-highlight .token.token.inserted:not(.prefix)::-moz-selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre > code.diff-highlight .token.token.inserted:not(.prefix) *::-moz-selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre.diff-highlight > code .token.token.inserted:not(.prefix)::selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre.diff-highlight > code .token.token.inserted:not(.prefix) *::selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre > code.diff-highlight .token.token.inserted:not(.prefix)::selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre > code.diff-highlight .token.token.inserted:not(.prefix) *::selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},".prism-previewer.prism-previewer:before":{borderColor:"hsl(0, 0, 95%)"},".prism-previewer-gradient.prism-previewer-gradient div":{borderColor:"hsl(0, 0, 95%)",borderRadius:"0.3em"},".prism-previewer-color.prism-previewer-color:before":{borderRadius:"0.3em"},".prism-previewer-easing.prism-previewer-easing:before":{borderRadius:"0.3em"},".prism-previewer.prism-previewer:after":{borderTopColor:"hsl(0, 0, 95%)"},".prism-previewer-flipped.prism-previewer-flipped.after":{borderBottomColor:"hsl(0, 0, 95%)"},".prism-previewer-angle.prism-previewer-angle:before":{background:"hsl(0, 0%, 100%)"},".prism-previewer-time.prism-previewer-time:before":{background:"hsl(0, 0%, 100%)"},".prism-previewer-easing.prism-previewer-easing":{background:"hsl(0, 0%, 100%)"},".prism-previewer-angle.prism-previewer-angle circle":{stroke:"hsl(230, 8%, 24%)",strokeOpacity:"1"},".prism-previewer-time.prism-previewer-time circle":{stroke:"hsl(230, 8%, 24%)",strokeOpacity:"1"},".prism-previewer-easing.prism-previewer-easing circle":{stroke:"hsl(230, 8%, 24%)",fill:"transparent"},".prism-previewer-easing.prism-previewer-easing path":{stroke:"hsl(230, 8%, 24%)"},".prism-previewer-easing.prism-previewer-easing line":{stroke:"hsl(230, 8%, 24%)"}};var toggleSelection,hasRequiredToggleSelection;function requireToggleSelection(){return hasRequiredToggleSelection||(hasRequiredToggleSelection=1,toggleSelection=function(){var e=document.getSelection();if(!e.rangeCount)return function(){};for(var t=document.activeElement,Ye=[],tt=0;tt<e.rangeCount;tt++)Ye.push(e.getRangeAt(tt));switch(t.tagName.toUpperCase()){case"INPUT":case"TEXTAREA":t.blur();break;default:t=null;break}return e.removeAllRanges(),function(){e.type==="Caret"&&e.removeAllRanges(),e.rangeCount||Ye.forEach(function(rt){e.addRange(rt)}),t&&t.focus()}}),toggleSelection}var copyToClipboard,hasRequiredCopyToClipboard;function requireCopyToClipboard(){if(hasRequiredCopyToClipboard)return copyToClipboard;hasRequiredCopyToClipboard=1;var e=requireToggleSelection(),t={"text/plain":"Text","text/html":"Url",default:"Text"},Ye="Copy to clipboard: #{key}, Enter";function tt(nt){var at=(/mac os x/i.test(navigator.userAgent)?"⌘":"Ctrl")+"+C";return nt.replace(/#{\s*key\s*}/g,at)}function rt(nt,at){var it,ot,ct,At,Rt,qt,Ft=!1;at||(at={}),it=at.debug||!1;try{ct=e(),At=document.createRange(),Rt=document.getSelection(),qt=document.createElement("span"),qt.textContent=nt,qt.ariaHidden="true",qt.style.all="unset",qt.style.position="fixed",qt.style.top=0,qt.style.clip="rect(0, 0, 0, 0)",qt.style.whiteSpace="pre",qt.style.webkitUserSelect="text",qt.style.MozUserSelect="text",qt.style.msUserSelect="text",qt.style.userSelect="text",qt.addEventListener("copy",function(Ht){if(Ht.stopPropagation(),at.format)if(Ht.preventDefault(),typeof Ht.clipboardData>"u"){it&&console.warn("unable to use e.clipboardData"),it&&console.warn("trying IE specific stuff"),window.clipboardData.clearData();var zt=t[at.format]||t.default;window.clipboardData.setData(zt,nt)}else Ht.clipboardData.clearData(),Ht.clipboardData.setData(at.format,nt);at.onCopy&&(Ht.preventDefault(),at.onCopy(Ht.clipboardData))}),document.body.appendChild(qt),At.selectNodeContents(qt),Rt.addRange(At);var Ut=document.execCommand("copy");if(!Ut)throw new Error("copy command was unsuccessful");Ft=!0}catch(Ht){it&&console.error("unable to copy using execCommand: ",Ht),it&&console.warn("trying IE specific stuff");try{window.clipboardData.setData(at.format||"text",nt),at.onCopy&&at.onCopy(window.clipboardData),Ft=!0}catch(zt){it&&console.error("unable to copy using clipboardData: ",zt),it&&console.error("falling back to prompt"),ot=tt("message"in at?at.message:Ye),window.prompt(ot,nt)}}finally{Rt&&(typeof Rt.removeRange=="function"?Rt.removeRange(At):Rt.removeAllRanges()),qt&&document.body.removeChild(qt),ct()}return Ft}return copyToClipboard=rt,copyToClipboard}var copyToClipboardExports=requireCopyToClipboard();const copy=getDefaultExportFromCjs(copyToClipboardExports),CodeBlockContext$1=reactExports.createContext({code:""}),CodeBlock$1=({code:e,language:t,showLineNumbers:Ye=!1,className:tt,children:rt,...nt})=>jsxRuntimeExports.jsx(CodeBlockContext$1.Provider,{value:{code:e},children:jsxRuntimeExports.jsx("div",{className:cn$2("relative w-full overflow-hidden rounded-md border bg-background text-foreground",tt),...nt,children:jsxRuntimeExports.jsxs("div",{className:"relative",children:[jsxRuntimeExports.jsx(highlighter,{className:"overflow-hidden dark:hidden",codeTagProps:{className:"font-mono text-sm"},customStyle:{margin:0,padding:"1rem",fontSize:"0.875rem",background:"hsl(var(--background))",color:"hsl(var(--foreground))"},language:t,lineNumberStyle:{color:"hsl(var(--muted-foreground))",paddingRight:"1rem",minWidth:"2.5rem"},showLineNumbers:Ye,style:oneLight,children:e}),jsxRuntimeExports.jsx(highlighter,{className:"hidden overflow-hidden dark:block",codeTagProps:{className:"font-mono text-sm"},customStyle:{margin:0,padding:"1rem",fontSize:"0.875rem",background:"hsl(var(--background))",color:"hsl(var(--foreground))"},language:t,lineNumberStyle:{color:"hsl(var(--muted-foreground))",paddingRight:"1rem",minWidth:"2.5rem"},showLineNumbers:Ye,style:oneDark,children:e}),rt&&jsxRuntimeExports.jsx("div",{className:"absolute top-2 right-2 flex items-center gap-2",children:rt})]})})}),HumanInTheLoopControls=({tool:e})=>{const t=e.getHumanInTheLoopData();if(!t)return null;const Ye=t.reviewConfig,tt=t.actionRequest;return Ye?jsxRuntimeExports.jsx("div",{className:"flex gap-2",children:Ye.allowedDecisions.map(rt=>rt==="approve"?jsxRuntimeExports.jsx("button",{className:"px-3 py-1 text-xs font-medium text-green-700 bg-green-50 border border-green-200 rounded-lg hover:bg-green-100 transition-colors cursor-pointer",onClick:()=>e.sendResumeData({type:"approve"}),children:"Approve"},rt):rt==="reject"?jsxRuntimeExports.jsx("button",{className:"px-3 py-1 text-xs font-medium text-red-700 bg-red-50 border border-red-200 rounded-lg hover:bg-red-100 transition-colors cursor-pointer",onClick:()=>{const nt=window.prompt("Please enter rejection reason:");nt!==null&&e.sendResumeData({type:"reject",message:nt||void 0})},children:"Reject"},rt):rt==="edit"?jsxRuntimeExports.jsx("button",{className:"px-3 py-1 text-xs font-medium text-blue-700 bg-blue-50 border border-blue-200 rounded-lg hover:bg-blue-100 transition-colors cursor-pointer",onClick:()=>{const nt=JSON.stringify(tt.args),at=window.prompt("Edit tool arguments (JSON):",nt);if(at!==null)try{const it=JSON.parse(at);e.sendResumeData({type:"edit",edited_action:{name:tt.name,args:it}})}catch{alert("Invalid JSON")}},children:"Edit"},rt):rt==="respond"?jsxRuntimeExports.jsx("button",{className:"px-3 py-1 text-xs font-medium text-purple-700 bg-purple-50 border border-purple-200 rounded-lg hover:bg-purple-100 transition-colors cursor-pointer",onClick:()=>{const nt=window.prompt("Please enter response message:");nt!==null&&e.sendResumeData({type:"respond",message:nt||void 0})},children:"Respond"},rt):null)}):null},getStatusColor=e=>{switch(e){case"done":return"text-green-600 bg-green-50 border-green-200";case"loading":return"text-blue-600 bg-blue-50 border-blue-200";case"processing":return"text-orange-600 bg-orange-50 border-orange-200";case"idle":default:return"text-gray-600 bg-gray-50 border-gray-200"}},getStatusIcon=e=>{switch(e){case"done":return"✓";case"loading":return"⟳";case"processing":return"⋯";case"idle":default:return"○"}},TOOL_COLORS=["bg-white","bg-white","bg-white","bg-white","bg-white","bg-white","bg-white"],getToolColorClass=(e="")=>{let t=0;for(let tt=0;tt<e.length;tt++)t=e.charCodeAt(tt)+((t<<5)-t);const Ye=Math.abs(t%TOOL_COLORS.length);return TOOL_COLORS[Ye]},MessageTool=({message:e,isCollapsed:t,onToggleCollapse:Ye})=>{var ot,ct;const{getToolUIRender:tt,client:rt}=useChat(),nt=tt(e.name||""),at=getToolColorClass(e.name||""),it=new ToolRenderData(e,rt);return jsxRuntimeExports.jsxs("div",{className:"flex flex-col w-full",children:[nt?nt(e):jsxRuntimeExports.jsxs("div",{className:`flex flex-col w-full ${at} rounded-2xl overflow-hidden`,children:[jsxRuntimeExports.jsxs("div",{className:"flex items-center justify-between px-5 py-3 cursor-pointer hover:bg-gray-100 transition-colors",onClick:Ye,children:[jsxRuntimeExports.jsxs("div",{className:"text-xs font-medium text-gray-600",onClick:()=>console.log(e),children:[e.node_name," | ",e.name]}),jsxRuntimeExports.jsxs("div",{className:"flex gap-2",children:[it.state==="interrupted"?jsxRuntimeExports.jsx(HumanInTheLoopControls,{tool:it}):null,jsxRuntimeExports.jsxs("div",{className:`inline-flex items-center gap-1 px-2 py-1 text-xs font-medium rounded-md border ${getStatusColor(it.state)}`,children:[jsxRuntimeExports.jsx("span",{children:getStatusIcon(it.state)}),jsxRuntimeExports.jsx("span",{children:it.state})]})]})]}),!t&&jsxRuntimeExports.jsxs("div",{className:"flex flex-col gap-4 px-5 pb-4",children:[(ot=e.additional_kwargs)!=null&&ot.reasoning_content?jsxRuntimeExports.jsx(Reasoning,{message:e}):null,jsxRuntimeExports.jsx(Previewer,{content:JSON.stringify(it.getInputRepaired(),null,2)||"",mode:"json"}),jsxRuntimeExports.jsx(Previewer,{content:getMessageContent(e.content)}),jsxRuntimeExports.jsx(UsageMetadata,{response_metadata:e.response_metadata,usage_metadata:e.usage_metadata||{},spend_time:e.spend_time,id:e.id,tool_call_id:e.tool_call_id})]})]}),(ct=e.sub_messages)!=null&&ct.length?jsxRuntimeExports.jsx("div",{className:"flex flex-col pl-6 py-3 ml-4 border-l-2 border-gray-200",children:jsxRuntimeExports.jsx(MessagesBox,{renderMessages:e.sub_messages,collapsedTools:[],toggleToolCollapse:At=>{},client:rt})}):null]})},Previewer=({content:e,mode:t})=>{const Ye=()=>{try{return JSON.parse(e),!0}catch{return!1}},tt=t==="json"||e.startsWith("{")&&e.endsWith("}")&&Ye(),rt=t==="markdown"||e.includes("#")||e.includes("```")||e.includes("*"),[nt,at]=reactExports.useState(tt),[it,ot]=reactExports.useState(!1),ct=()=>{copy(e)};return jsxRuntimeExports.jsxs("div",{className:"flex flex-col",children:[jsxRuntimeExports.jsxs("div",{className:"flex gap-2 mb-2",children:[jsxRuntimeExports.jsx("button",{onClick:ct,className:"px-3 py-1 text-xs font-medium text-gray-700 bg-white border border-gray-200 rounded-lg hover:bg-gray-100 transition-colors",children:"copy"}),tt&&jsxRuntimeExports.jsx("button",{onClick:()=>at(!nt),className:"px-3 py-1 text-xs font-medium text-gray-700 bg-white border border-gray-200 rounded-lg hover:bg-gray-100 transition-colors",children:"json"}),rt&&jsxRuntimeExports.jsx("button",{onClick:()=>ot(!it),className:"px-3 py-1 text-xs font-medium text-gray-700 bg-white border border-gray-200 rounded-lg hover:bg-gray-100 transition-colors",children:"markdown"})]}),jsxRuntimeExports.jsx("div",{className:"flex flex-col max-h-[300px] bg-white border border-gray-200 rounded-xl p-3 w-full text-xs font-mono",children:jsxRuntimeExports.jsx("div",{className:"overflow-auto max-h-full",children:nt&&tt?jsxRuntimeExports.jsx("div",{className:"overflow-visible",children:jsxRuntimeExports.jsx(CodeBlock$1,{code:JSON.stringify(JSON.parse(e),null,2),language:"json"})}):it&&rt?jsxRuntimeExports.jsx("div",{className:"whitespace-pre-wrap",children:jsxRuntimeExports.jsx(Response$1,{children:e})}):jsxRuntimeExports.jsx("pre",{className:" whitespace-pre-wrap",style:{overflowWrap:"break-word"},children:jsxRuntimeExports.jsx("code",{className:"whitespace-pre-wrap",children:e})})})})]})},MessagesBox=({renderMessages:e,collapsedTools:t,toggleToolCollapse:Ye,client:tt})=>{const[rt,nt]=reactExports.useState(new Map),at=reactExports.useRef(new Map),it=reactExports.useCallback((At,Rt)=>{nt(qt=>{const Ft=new Map(qt),Ut=Ft.get(At)||{showDetail:!1,showContextMenu:!1,contextMenuPosition:{x:0,y:0}};return Ft.set(At,{...Ut,...Rt}),Ft})},[]),ot=reactExports.useCallback((At,Rt)=>{At.preventDefault(),it(Rt,{contextMenuPosition:{x:At.clientX,y:At.clientY},showContextMenu:!0})},[it]),ct=reactExports.useCallback(At=>{it(At,{showContextMenu:!1})},[it]);return reactExports.useEffect(()=>{const At=Rt=>{rt.forEach((qt,Ft)=>{if(qt.showContextMenu){const Ut=at.current.get(Ft);Ut&&!Ut.contains(Rt.target)&&ct(Ft)}})};return Array.from(rt.values()).some(Rt=>Rt.showContextMenu)&&document.addEventListener("click",At),()=>{document.removeEventListener("click",At)}},[rt,ct]),jsxRuntimeExports.jsx("div",{className:"flex flex-col gap-5 w-full",children:e.map((At,Rt)=>{const qt=At.unique_id||`message-${Rt}`,Ft=rt.get(qt)||{showDetail:!1};return jsxRuntimeExports.jsxs("div",{ref:Ut=>{Ut&&at.current.set(qt,Ut)},onContextMenu:Ut=>ot(Ut,qt),children:[At.type==="human"?jsxRuntimeExports.jsx(MessageHuman,{message:At,content:At.content}):At.type==="tool"?jsxRuntimeExports.jsx(MessageTool,{message:At,isCollapsed:t.includes(At.id),onToggleCollapse:()=>Ye(At.id)}):jsxRuntimeExports.jsx(MessageAI,{message:At}),Ft.showDetail&&jsxRuntimeExports.jsx(CodeBlock$1,{code:JSON.stringify(At,null,2),language:"json"})]},qt)})})},HistoryList=({onClose:e})=>{const{historyList:t,currentChatId:Ye,refreshHistoryList:tt,createNewChat:rt,deleteHistoryChat:nt,toHistoryChat:at}=useChat();return jsxRuntimeExports.jsxs("section",{className:"bg-white h-full flex flex-col ",children:[jsxRuntimeExports.jsxs("div",{className:"px-5 flex justify-between items-center py-6",children:[jsxRuntimeExports.jsx("div",{className:"flex items-center gap-3",children:jsxRuntimeExports.jsx("h3",{className:"m-0 text-base font-semibold text-gray-700",children:"历史记录"})}),jsxRuntimeExports.jsx("button",{className:"p-2 rounded-lg bg-gray-100 hover:bg-gray-300 transition-colors flex items-center justify-center group",onClick:tt,title:"刷新列表",children:jsxRuntimeExports.jsx(RefreshCw$1,{className:"w-4 h-4 text-gray-600 group-hover:rotate-180 transition-transform duration-300"})}),jsxRuntimeExports.jsx("button",{className:"p-2 rounded-lg bg-gray-100 hover:bg-gray-300 transition-colors flex items-center justify-center group",onClick:e,title:"关闭",children:jsxRuntimeExports.jsx(X$6,{className:"w-4 h-4 text-red-500"})})]}),jsxRuntimeExports.jsxs("div",{className:"flex-1 overflow-y-auto px-4 py-2",children:[jsxRuntimeExports.jsx("div",{className:"cursor-pointer mb-3",onClick:()=>{rt()},children:jsxRuntimeExports.jsx("div",{className:"flex justify-between items-center px-4 py-3 rounded-xl bg-blue-50/80 hover:bg-blue-200/80 transition-colors",children:jsxRuntimeExports.jsx("div",{className:"text-sm text-gray-700 font-medium truncate",children:"New Chat"})})}),t.length===0?jsxRuntimeExports.jsx("div",{className:"text-center text-gray-400 py-10 text-sm",children:"暂无历史记录"}):jsxRuntimeExports.jsx("div",{className:"flex flex-col gap-2",children:t.sort((it,ot)=>new Date(ot.created_at).getTime()-new Date(it.created_at).getTime()).map(it=>jsxRuntimeExports.jsxs("div",{className:`flex justify-between items-center px-4 py-3 rounded-xl transition-colors ${it.thread_id===Ye?"bg-blue-50/80":"bg-gray-50/60 hover:bg-gray-200/80"}`,children:[jsxRuntimeExports.jsxs("div",{className:"flex-1 min-w-0 mr-2",onClick:()=>{at(it)},children:[jsxRuntimeExports.jsx("div",{className:"text-sm text-gray-700 mb-1 truncate max-w-[180px]",children:getHistoryContent(it)}),jsxRuntimeExports.jsxs("div",{className:"flex gap-3 text-xs text-gray-400",children:[jsxRuntimeExports.jsx("span",{className:"truncate max-w-[100px]",children:formatTime(new Date(it.created_at))}),jsxRuntimeExports.jsx("span",{className:"truncate max-w-[60px]",children:it.status})]})]}),jsxRuntimeExports.jsxs("div",{className:"flex gap-1.5 shrink-0",children:[jsxRuntimeExports.jsx("button",{className:"p-2 rounded-lg bg-white/60 hover:bg-gray-200 transition-colors flex items-center justify-center group",onClick:()=>{at(it)},title:"恢复对话",children:jsxRuntimeExports.jsx(RotateCcw,{className:"w-3.5 h-3.5 text-gray-600 group-hover:-rotate-180 transition-transform duration-300"})}),jsxRuntimeExports.jsx("button",{className:"p-2 rounded-lg bg-white/60 hover:bg-gray-200 transition-colors flex items-center justify-center group",onClick:async()=>{await nt(it)},title:"删除对话",children:jsxRuntimeExports.jsx(Trash2,{className:"w-3.5 h-3.5 text-red-500"})})]})]},it.thread_id))})]})]})};class FileUploadClient{constructor(t={}){Cr(this,"apiUrl");this.apiUrl=t.apiUrl||""}createFormData(t,Ye){const tt=new FormData;if(typeof t=="string"){const rt=new Blob([t],{type:"text/plain"});tt.append("file",rt,Ye||"file.txt")}else tt.append("file",t,Ye||(t instanceof File?t.name:"file"));return tt}async upload(t,Ye={}){const rt={method:"POST",body:this.createFormData(t,Ye.filename)};Ye.signal&&(rt.signal=Ye.signal);try{const nt=await fetch(`${this.apiUrl}${this.getUploadEndpoint()}`,rt);if(!nt.ok)throw new Error(`Upload failed with status: ${nt.status}`);const at=await nt.json();return this.processResponse(at)}catch(nt){throw new Error(`File upload failed: ${nt instanceof Error?nt.message:String(nt)}`)}}}class TmpFilesClient extends FileUploadClient{constructor(t={}){super({apiUrl:t.apiUrl||"https://tmpfiles.org/api/v1"})}getUploadEndpoint(){return"/upload"}processResponse(t){var Ye;return(Ye=t.data)!=null&&Ye.url&&(t.data.url=t.data.url.replace("//tmpfiles.org/","//tmpfiles.org/dl/")),t}}const FileListContext=reactExports.createContext(void 0),useFileList=()=>{const e=reactExports.useContext(FileListContext);if(!e)throw new Error("useFileList must be used within a FileListProvider");return e},FileListProvider=({children:e})=>{const[t,Ye]=reactExports.useState([]),[tt,rt]=reactExports.useState([]),[nt,at]=reactExports.useState({image:!1,video:!1,audio:!1,other:!0}),it=3,ot=new TmpFilesClient,ct=reactExports.useCallback((Ut,Ht)=>{Ht==="image"?rt(zt=>[...zt,{type:"image_url",image_url:{url:Ut},fileType:Ht}]):Ht==="video"?rt(zt=>[...zt,{type:"video_url",video_url:{url:Ut},fileType:Ht}]):Ht==="audio"?rt(zt=>[...zt,{type:"audio_url",audio_url:{url:Ut},fileType:Ht}]):Ht==="other"&&rt(zt=>[...zt,{type:"file_url",file_url:{url:Ut},fileType:Ht}])},[]),At=reactExports.useCallback((Ut,Ht)=>{rt(zt=>zt.filter(Yt=>{var Vt,Zt,Xt,Qt;return(((Vt=Yt.image_url)==null?void 0:Vt.url)||((Zt=Yt.video_url)==null?void 0:Zt.url)||((Xt=Yt.audio_url)==null?void 0:Xt.url)||((Qt=Yt.file_url)==null?void 0:Qt.url))!==Ut}))},[]),Rt=reactExports.useCallback(async Ut=>{var Yt;const zt=Array.from(Ut.target.files||[]);if(t.length+zt.length>it){alert(`最多只能上传${it}个文件`),Ut.target.value="";return}for(const Gt of zt)try{const Vt=await ot.upload(Gt);if((Yt=Vt.data)!=null&&Yt.url){const Zt=getFileType(Gt);if(Zt){const Xt={file:Gt,url:Vt.data.url,type:Zt};Ye(Qt=>[...Qt,Xt]),ct(Vt.data.url,Zt)}}}catch(Vt){console.error("Upload failed:",Vt)}Ut.target.value=""},[t.length,ct]),qt=reactExports.useCallback(Ut=>{const Ht=t[Ut];Ht&&(Ye(zt=>zt.filter((Yt,Gt)=>Gt!==Ut)),At(Ht.url,Ht.type))},[t,At]),Ft={uploadedFiles:t,mediaUrls:tt,isFileTextMode:nt,setIsFileTextMode:at,handleFileUploaded:ct,handleFileRemoved:At,handleFileChange:Rt,removeFile:qt,MAX_FILES:it};return jsxRuntimeExports.jsx(FileListContext.Provider,{value:Ft,children:e})},getFileType=e=>e.type.startsWith("image/")?"image":e.type==="video/mp4"?"video":e.type.startsWith("audio/")?"audio":"other",FileList=()=>{const{uploadedFiles:e,removeFile:t,mediaUrls:Ye,setIsFileTextMode:tt,isFileTextMode:rt}=useFileList();return jsxRuntimeExports.jsxs("div",{children:[Ye.length>0&&jsxRuntimeExports.jsxs("div",{className:"flex items-center gap-2 text-xs text-gray-600 mb-3",title:"文本传输将会把多模态文件转为 XML + URL 的格式传递给大模型",children:[jsxRuntimeExports.jsx("span",{children:"启动文本传输:"}),jsxRuntimeExports.jsx("button",{onClick:()=>tt(nt=>({...nt,image:!nt.image})),className:`px-2 py-1 rounded ${rt.image?"bg-blue-100 text-blue-700":"bg-gray-100 text-gray-500"}`,children:"图片"}),jsxRuntimeExports.jsx("button",{onClick:()=>tt(nt=>({...nt,video:!nt.video})),className:`px-2 py-1 rounded ${rt.video?"bg-blue-100 text-blue-700":"bg-gray-100 text-gray-500"}`,children:"视频"}),jsxRuntimeExports.jsx("button",{onClick:()=>tt(nt=>({...nt,audio:!nt.audio})),className:`px-2 py-1 rounded ${rt.audio?"bg-blue-100 text-blue-700":"bg-gray-100 text-gray-500"}`,children:"音频"}),jsxRuntimeExports.jsx("button",{onClick:()=>tt(nt=>({...nt,other:!nt.other})),className:`px-2 py-1 rounded ${rt.other?"bg-blue-100 text-blue-700":"bg-gray-100 text-gray-500"}`,children:"其他"})]}),jsxRuntimeExports.jsx("div",{className:"flex flex-wrap gap-2",children:e.map((nt,at)=>{const{file:it,type:ot,url:ct}=nt;return jsxRuntimeExports.jsxs("div",{className:"relative w-20 h-20 rounded-xl overflow-hidden border border-gray-200",children:[ot==="image"?jsxRuntimeExports.jsx("img",{src:URL.createObjectURL(it),alt:it.name,className:"w-full h-full object-cover"}):ot==="video"?jsxRuntimeExports.jsx("video",{src:URL.createObjectURL(it),className:"w-full h-full object-cover"}):ot==="audio"?jsxRuntimeExports.jsx("div",{className:"w-full h-full bg-gray-100 flex items-center justify-center",children:jsxRuntimeExports.jsx("svg",{viewBox:"0 0 24 24",width:"24",height:"24",fill:"currentColor",className:"text-gray-500",children:jsxRuntimeExports.jsx("path",{d:"M12 3v10.55c-.59-.34-1.27-.55-2-.55-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4V7h4V3h-6z"})})}):ot==="other"?jsxRuntimeExports.jsx("div",{className:"w-full h-full bg-gray-100 flex items-center justify-center",children:jsxRuntimeExports.jsx("svg",{viewBox:"0 0 24 24",width:"24",height:"24",fill:"currentColor",className:"text-gray-500",children:jsxRuntimeExports.jsx("path",{d:"M14,2H6A2,2 0 0,0 4,4V20A2,2 0 0,0 6,22H18A2,2 0 0,0 20,20V8L14,2M18,20H6V4H13V9H18V20Z"})})}):null,jsxRuntimeExports.jsx("button",{className:"absolute top-1 right-1 w-5 h-5 bg-red-500/90 text-white rounded-full flex items-center justify-center text-sm leading-none hover:bg-red-600 transition-colors backdrop-blur-sm",onClick:()=>t(at),children:"×"})]},at)})})," "]})},LOCAL_STORAGE_KEY="json-editor-presets",ACTIVE_TAB_STORAGE_KEY="json-editor-active-tab",JsonEditorPopup=({isOpen:e,initialJson:t,onClose:Ye,onSave:tt,title:rt,description:nt})=>{const[at,it]=reactExports.useState([]),[ot,ct]=reactExports.useState(0),[At,Rt]=reactExports.useState(""),[qt,Ft]=reactExports.useState(null),[Ut,Ht]=reactExports.useState(null),[zt,Yt]=reactExports.useState("");if(reactExports.useEffect(()=>{if(e){let er=[];try{const ar=localStorage.getItem(LOCAL_STORAGE_KEY);er=ar?JSON.parse(ar):[]}catch(ar){console.error("Failed to parse presets from localStorage",ar),er=[]}er.length===0&&(er=[{name:"Default",data:t}]),it(er);let nr=0;try{const ar=localStorage.getItem(ACTIVE_TAB_STORAGE_KEY);if(ar){const sr=parseInt(ar,10);sr>=0&&sr<er.length&&(nr=sr)}}catch(ar){console.error("Failed to parse active tab from localStorage",ar)}ct(nr),Ft(null)}},[e,t]),reactExports.useEffect(()=>{e&&at.length>0&&at[ot]&&(Rt(JSON.stringify(at[ot].data,null,2)),Ft(null))},[ot,at,e]),reactExports.useEffect(()=>{e&&localStorage.setItem(ACTIVE_TAB_STORAGE_KEY,ot.toString())},[ot,e]),!e)return null;const Gt=er=>{it(er),localStorage.setItem(LOCAL_STORAGE_KEY,JSON.stringify(er))},Vt=()=>{const er={name:`Preset ${at.length+1}`,data:{}},nr=[...at,er];Gt(nr),ct(nr.length-1)},Zt=er=>{let nr=at.filter((ar,sr)=>sr!==er);nr.length===0&&(nr=[{name:"Default",data:t}]),Gt(nr),ot>=er&&ot>0?ct(ot-1):ot>=nr.length&&ct(nr.length-1)},Xt=()=>{try{const er=JSON.parse(At),nr=at.map((ar,sr)=>sr===ot?{...ar,data:er}:ar);Gt(nr),tt(er),Ye()}catch(er){Ft("JSON 格式无效,请检查后重试。"),console.error("Invalid JSON format:",er)}},Qt=er=>{if(zt.trim()!==""){const nr=at.map((ar,sr)=>sr===er?{...ar,name:zt.trim()}:ar);Gt(nr),Ht(null)}};return jsxRuntimeExports.jsx("div",{className:"fixed inset-0 bg-black/30 backdrop-blur-sm flex items-center justify-center z-50",children:jsxRuntimeExports.jsxs("div",{className:"bg-white rounded-2xl w-full max-w-2xl mx-4 flex flex-col overflow-hidden",style:{height:"80vh"},children:[jsxRuntimeExports.jsx("div",{className:"px-6 py-5 bg-white/80 backdrop-blur-sm",children:jsxRuntimeExports.jsx("h2",{className:"text-lg font-semibold text-gray-800",children:rt})}),jsxRuntimeExports.jsx("div",{className:"px-6 py-4 text-sm text-gray-500",children:nt}),jsxRuntimeExports.jsxs("nav",{className:"flex-grow px-6 py-4 overflow-y-auto",children:[jsxRuntimeExports.jsxs("div",{className:"flex items-center mb-4 gap-2",children:[at.map((er,nr)=>jsxRuntimeExports.jsxs("div",{className:`flex items-center px-4 py-2 rounded-xl cursor-pointer text-sm font-medium transition-colors ${ot===nr?"bg-blue-50 text-blue-600":"bg-gray-50 text-gray-600 hover:bg-gray-100"}`,onDoubleClick:()=>{Ht(nr),Yt(er.name)},onClick:()=>ct(nr),children:[Ut===nr?jsxRuntimeExports.jsx("input",{type:"text",value:zt,onChange:ar=>Yt(ar.target.value),onBlur:()=>Qt(nr),onKeyDown:ar=>ar.key==="Enter"&&Qt(nr),className:"text-sm p-0 border-none focus:ring-0 bg-transparent",autoFocus:!0}):jsxRuntimeExports.jsx("span",{children:er.name}),jsxRuntimeExports.jsx("button",{onClick:ar=>{ar.stopPropagation(),Zt(nr)},className:"ml-2 text-gray-400 hover:text-gray-600 w-4 h-4 flex items-center justify-center transition-colors",children:"×"})]},nr)),jsxRuntimeExports.jsx("button",{onClick:Vt,className:"px-3 py-2 text-sm text-gray-500 hover:text-gray-700 bg-gray-50 rounded-xl hover:bg-gray-100 transition-colors",children:"+"})]}),jsxRuntimeExports.jsx("textarea",{value:At,onChange:er=>{Rt(er.target.value),Ft(null)},className:"w-full h-full px-4 py-3 bg-gray-50 rounded-xl font-mono text-sm focus:outline-none focus:bg-gray-100 transition-colors"}),qt&&jsxRuntimeExports.jsx("p",{className:"mt-2 text-sm text-red-600",children:qt})]}),jsxRuntimeExports.jsxs("div",{className:"flex justify-end gap-3 px-6 py-5 bg-gray-50/50",children:[jsxRuntimeExports.jsx("button",{onClick:Ye,className:"px-5 py-2.5 text-sm font-medium text-gray-700 bg-white rounded-xl hover:bg-gray-100 focus:outline-none transition-colors",children:"取消"}),jsxRuntimeExports.jsx("button",{onClick:Xt,className:"px-5 py-2.5 text-sm font-medium text-white bg-blue-500 rounded-xl hover:bg-blue-600 focus:outline-none transition-colors",children:"保存并使用"})]})]})})};function cc(e){if(typeof e=="string"||typeof e=="number")return""+e;let t="";if(Array.isArray(e))for(let Ye=0,tt;Ye<e.length;Ye++)(tt=cc(e[Ye]))!==""&&(t+=(t&&" ")+tt);else for(let Ye in e)e[Ye]&&(t+=(t&&" ")+Ye);return t}var noop$1={value:()=>{}};function dispatch(){for(var e=0,t=arguments.length,Ye={},tt;e<t;++e){if(!(tt=arguments[e]+"")||tt in Ye||/[\s.]/.test(tt))throw new Error("illegal type: "+tt);Ye[tt]=[]}return new Dispatch(Ye)}function Dispatch(e){this._=e}function parseTypenames$1(e,t){return e.trim().split(/^|\s+/).map(function(Ye){var tt="",rt=Ye.indexOf(".");if(rt>=0&&(tt=Ye.slice(rt+1),Ye=Ye.slice(0,rt)),Ye&&!t.hasOwnProperty(Ye))throw new Error("unknown type: "+Ye);return{type:Ye,name:tt}})}Dispatch.prototype=dispatch.prototype={constructor:Dispatch,on:function(e,t){var Ye=this._,tt=parseTypenames$1(e+"",Ye),rt,nt=-1,at=tt.length;if(arguments.length<2){for(;++nt<at;)if((rt=(e=tt[nt]).type)&&(rt=get$2(Ye[rt],e.name)))return rt;return}if(t!=null&&typeof t!="function")throw new Error("invalid callback: "+t);for(;++nt<at;)if(rt=(e=tt[nt]).type)Ye[rt]=set$2(Ye[rt],e.name,t);else if(t==null)for(rt in Ye)Ye[rt]=set$2(Ye[rt],e.name,null);return this},copy:function(){var e={},t=this._;for(var Ye in t)e[Ye]=t[Ye].slice();return new Dispatch(e)},call:function(e,t){if((rt=arguments.length-2)>0)for(var Ye=new Array(rt),tt=0,rt,nt;tt<rt;++tt)Ye[tt]=arguments[tt+2];if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(nt=this._[e],tt=0,rt=nt.length;tt<rt;++tt)nt[tt].value.apply(t,Ye)},apply:function(e,t,Ye){if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(var tt=this._[e],rt=0,nt=tt.length;rt<nt;++rt)tt[rt].value.apply(t,Ye)}};function get$2(e,t){for(var Ye=0,tt=e.length,rt;Ye<tt;++Ye)if((rt=e[Ye]).name===t)return rt.value}function set$2(e,t,Ye){for(var tt=0,rt=e.length;tt<rt;++tt)if(e[tt].name===t){e[tt]=noop$1,e=e.slice(0,tt).concat(e.slice(tt+1));break}return Ye!=null&&e.push({name:t,value:Ye}),e}var xhtml="http://www.w3.org/1999/xhtml";const namespaces={svg:"http://www.w3.org/2000/svg",xhtml,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function namespace(e){var t=e+="",Ye=t.indexOf(":");return Ye>=0&&(t=e.slice(0,Ye))!=="xmlns"&&(e=e.slice(Ye+1)),namespaces.hasOwnProperty(t)?{space:namespaces[t],local:e}:e}function creatorInherit(e){return function(){var t=this.ownerDocument,Ye=this.namespaceURI;return Ye===xhtml&&t.documentElement.namespaceURI===xhtml?t.createElement(e):t.createElementNS(Ye,e)}}function creatorFixed(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function creator(e){var t=namespace(e);return(t.local?creatorFixed:creatorInherit)(t)}function none(){}function selector(e){return e==null?none:function(){return this.querySelector(e)}}function selection_select(e){typeof e!="function"&&(e=selector(e));for(var t=this._groups,Ye=t.length,tt=new Array(Ye),rt=0;rt<Ye;++rt)for(var nt=t[rt],at=nt.length,it=tt[rt]=new Array(at),ot,ct,At=0;At<at;++At)(ot=nt[At])&&(ct=e.call(ot,ot.__data__,At,nt))&&("__data__"in ot&&(ct.__data__=ot.__data__),it[At]=ct);return new Selection$1(tt,this._parents)}function array(e){return e==null?[]:Array.isArray(e)?e:Array.from(e)}function empty(){return[]}function selectorAll(e){return e==null?empty:function(){return this.querySelectorAll(e)}}function arrayAll(e){return function(){return array(e.apply(this,arguments))}}function selection_selectAll(e){typeof e=="function"?e=arrayAll(e):e=selectorAll(e);for(var t=this._groups,Ye=t.length,tt=[],rt=[],nt=0;nt<Ye;++nt)for(var at=t[nt],it=at.length,ot,ct=0;ct<it;++ct)(ot=at[ct])&&(tt.push(e.call(ot,ot.__data__,ct,at)),rt.push(ot));return new Selection$1(tt,rt)}function matcher(e){return function(){return this.matches(e)}}function childMatcher(e){return function(t){return t.matches(e)}}var find=Array.prototype.find;function childFind(e){return function(){return find.call(this.children,e)}}function childFirst(){return this.firstElementChild}function selection_selectChild(e){return this.select(e==null?childFirst:childFind(typeof e=="function"?e:childMatcher(e)))}var filter=Array.prototype.filter;function children$1(){return Array.from(this.children)}function childrenFilter(e){return function(){return filter.call(this.children,e)}}function selection_selectChildren(e){return this.selectAll(e==null?children$1:childrenFilter(typeof e=="function"?e:childMatcher(e)))}function selection_filter(e){typeof e!="function"&&(e=matcher(e));for(var t=this._groups,Ye=t.length,tt=new Array(Ye),rt=0;rt<Ye;++rt)for(var nt=t[rt],at=nt.length,it=tt[rt]=[],ot,ct=0;ct<at;++ct)(ot=nt[ct])&&e.call(ot,ot.__data__,ct,nt)&&it.push(ot);return new Selection$1(tt,this._parents)}function sparse(e){return new Array(e.length)}function selection_enter(){return new Selection$1(this._enter||this._groups.map(sparse),this._parents)}function EnterNode(e,t){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=t}EnterNode.prototype={constructor:EnterNode,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,t){return this._parent.insertBefore(e,t)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}};function constant$4(e){return function(){return e}}function bindIndex(e,t,Ye,tt,rt,nt){for(var at=0,it,ot=t.length,ct=nt.length;at<ct;++at)(it=t[at])?(it.__data__=nt[at],tt[at]=it):Ye[at]=new EnterNode(e,nt[at]);for(;at<ot;++at)(it=t[at])&&(rt[at]=it)}function bindKey(e,t,Ye,tt,rt,nt,at){var it,ot,ct=new Map,At=t.length,Rt=nt.length,qt=new Array(At),Ft;for(it=0;it<At;++it)(ot=t[it])&&(qt[it]=Ft=at.call(ot,ot.__data__,it,t)+"",ct.has(Ft)?rt[it]=ot:ct.set(Ft,ot));for(it=0;it<Rt;++it)Ft=at.call(e,nt[it],it,nt)+"",(ot=ct.get(Ft))?(tt[it]=ot,ot.__data__=nt[it],ct.delete(Ft)):Ye[it]=new EnterNode(e,nt[it]);for(it=0;it<At;++it)(ot=t[it])&&ct.get(qt[it])===ot&&(rt[it]=ot)}function datum(e){return e.__data__}function selection_data(e,t){if(!arguments.length)return Array.from(this,datum);var Ye=t?bindKey:bindIndex,tt=this._parents,rt=this._groups;typeof e!="function"&&(e=constant$4(e));for(var nt=rt.length,at=new Array(nt),it=new Array(nt),ot=new Array(nt),ct=0;ct<nt;++ct){var At=tt[ct],Rt=rt[ct],qt=Rt.length,Ft=arraylike(e.call(At,At&&At.__data__,ct,tt)),Ut=Ft.length,Ht=it[ct]=new Array(Ut),zt=at[ct]=new Array(Ut),Yt=ot[ct]=new Array(qt);Ye(At,Rt,Ht,zt,Yt,Ft,t);for(var Gt=0,Vt=0,Zt,Xt;Gt<Ut;++Gt)if(Zt=Ht[Gt]){for(Gt>=Vt&&(Vt=Gt+1);!(Xt=zt[Vt])&&++Vt<Ut;);Zt._next=Xt||null}}return at=new Selection$1(at,tt),at._enter=it,at._exit=ot,at}function arraylike(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function selection_exit(){return new Selection$1(this._exit||this._groups.map(sparse),this._parents)}function selection_join(e,t,Ye){var tt=this.enter(),rt=this,nt=this.exit();return typeof e=="function"?(tt=e(tt),tt&&(tt=tt.selection())):tt=tt.append(e+""),t!=null&&(rt=t(rt),rt&&(rt=rt.selection())),Ye==null?nt.remove():Ye(nt),tt&&rt?tt.merge(rt).order():rt}function selection_merge(e){for(var t=e.selection?e.selection():e,Ye=this._groups,tt=t._groups,rt=Ye.length,nt=tt.length,at=Math.min(rt,nt),it=new Array(rt),ot=0;ot<at;++ot)for(var ct=Ye[ot],At=tt[ot],Rt=ct.length,qt=it[ot]=new Array(Rt),Ft,Ut=0;Ut<Rt;++Ut)(Ft=ct[Ut]||At[Ut])&&(qt[Ut]=Ft);for(;ot<rt;++ot)it[ot]=Ye[ot];return new Selection$1(it,this._parents)}function selection_order(){for(var e=this._groups,t=-1,Ye=e.length;++t<Ye;)for(var tt=e[t],rt=tt.length-1,nt=tt[rt],at;--rt>=0;)(at=tt[rt])&&(nt&&at.compareDocumentPosition(nt)^4&&nt.parentNode.insertBefore(at,nt),nt=at);return this}function selection_sort(e){e||(e=ascending);function t(Rt,qt){return Rt&&qt?e(Rt.__data__,qt.__data__):!Rt-!qt}for(var Ye=this._groups,tt=Ye.length,rt=new Array(tt),nt=0;nt<tt;++nt){for(var at=Ye[nt],it=at.length,ot=rt[nt]=new Array(it),ct,At=0;At<it;++At)(ct=at[At])&&(ot[At]=ct);ot.sort(t)}return new Selection$1(rt,this._parents).order()}function ascending(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}function selection_call(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this}function selection_nodes(){return Array.from(this)}function selection_node(){for(var e=this._groups,t=0,Ye=e.length;t<Ye;++t)for(var tt=e[t],rt=0,nt=tt.length;rt<nt;++rt){var at=tt[rt];if(at)return at}return null}function selection_size(){let e=0;for(const t of this)++e;return e}function selection_empty(){return!this.node()}function selection_each(e){for(var t=this._groups,Ye=0,tt=t.length;Ye<tt;++Ye)for(var rt=t[Ye],nt=0,at=rt.length,it;nt<at;++nt)(it=rt[nt])&&e.call(it,it.__data__,nt,rt);return this}function attrRemove$1(e){return function(){this.removeAttribute(e)}}function attrRemoveNS$1(e){return function(){this.removeAttributeNS(e.space,e.local)}}function attrConstant$1(e,t){return function(){this.setAttribute(e,t)}}function attrConstantNS$1(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function attrFunction$1(e,t){return function(){var Ye=t.apply(this,arguments);Ye==null?this.removeAttribute(e):this.setAttribute(e,Ye)}}function attrFunctionNS$1(e,t){return function(){var Ye=t.apply(this,arguments);Ye==null?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,Ye)}}function selection_attr(e,t){var Ye=namespace(e);if(arguments.length<2){var tt=this.node();return Ye.local?tt.getAttributeNS(Ye.space,Ye.local):tt.getAttribute(Ye)}return this.each((t==null?Ye.local?attrRemoveNS$1:attrRemove$1:typeof t=="function"?Ye.local?attrFunctionNS$1:attrFunction$1:Ye.local?attrConstantNS$1:attrConstant$1)(Ye,t))}function defaultView(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function styleRemove$1(e){return function(){this.style.removeProperty(e)}}function styleConstant$1(e,t,Ye){return function(){this.style.setProperty(e,t,Ye)}}function styleFunction$1(e,t,Ye){return function(){var tt=t.apply(this,arguments);tt==null?this.style.removeProperty(e):this.style.setProperty(e,tt,Ye)}}function selection_style(e,t,Ye){return arguments.length>1?this.each((t==null?styleRemove$1:typeof t=="function"?styleFunction$1:styleConstant$1)(e,t,Ye??"")):styleValue(this.node(),e)}function styleValue(e,t){return e.style.getPropertyValue(t)||defaultView(e).getComputedStyle(e,null).getPropertyValue(t)}function propertyRemove(e){return function(){delete this[e]}}function propertyConstant(e,t){return function(){this[e]=t}}function propertyFunction(e,t){return function(){var Ye=t.apply(this,arguments);Ye==null?delete this[e]:this[e]=Ye}}function selection_property(e,t){return arguments.length>1?this.each((t==null?propertyRemove:typeof t=="function"?propertyFunction:propertyConstant)(e,t)):this.node()[e]}function classArray(e){return e.trim().split(/^|\s+/)}function classList$1(e){return e.classList||new ClassList(e)}function ClassList(e){this._node=e,this._names=classArray(e.getAttribute("class")||"")}ClassList.prototype={add:function(e){var t=this._names.indexOf(e);t<0&&(this._names.push(e),this._node.setAttribute("class",this._names.join(" ")))},remove:function(e){var t=this._names.indexOf(e);t>=0&&(this._names.splice(t,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(e){return this._names.indexOf(e)>=0}};function classedAdd(e,t){for(var Ye=classList$1(e),tt=-1,rt=t.length;++tt<rt;)Ye.add(t[tt])}function classedRemove(e,t){for(var Ye=classList$1(e),tt=-1,rt=t.length;++tt<rt;)Ye.remove(t[tt])}function classedTrue(e){return function(){classedAdd(this,e)}}function classedFalse(e){return function(){classedRemove(this,e)}}function classedFunction(e,t){return function(){(t.apply(this,arguments)?classedAdd:classedRemove)(this,e)}}function selection_classed(e,t){var Ye=classArray(e+"");if(arguments.length<2){for(var tt=classList$1(this.node()),rt=-1,nt=Ye.length;++rt<nt;)if(!tt.contains(Ye[rt]))return!1;return!0}return this.each((typeof t=="function"?classedFunction:t?classedTrue:classedFalse)(Ye,t))}function textRemove(){this.textContent=""}function textConstant$1(e){return function(){this.textContent=e}}function textFunction$1(e){return function(){var t=e.apply(this,arguments);this.textContent=t??""}}function selection_text(e){return arguments.length?this.each(e==null?textRemove:(typeof e=="function"?textFunction$1:textConstant$1)(e)):this.node().textContent}function htmlRemove(){this.innerHTML=""}function htmlConstant(e){return function(){this.innerHTML=e}}function htmlFunction(e){return function(){var t=e.apply(this,arguments);this.innerHTML=t??""}}function selection_html(e){return arguments.length?this.each(e==null?htmlRemove:(typeof e=="function"?htmlFunction:htmlConstant)(e)):this.node().innerHTML}function raise(){this.nextSibling&&this.parentNode.appendChild(this)}function selection_raise(){return this.each(raise)}function lower(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function selection_lower(){return this.each(lower)}function selection_append(e){var t=typeof e=="function"?e:creator(e);return this.select(function(){return this.appendChild(t.apply(this,arguments))})}function constantNull(){return null}function selection_insert(e,t){var Ye=typeof e=="function"?e:creator(e),tt=t==null?constantNull:typeof t=="function"?t:selector(t);return this.select(function(){return this.insertBefore(Ye.apply(this,arguments),tt.apply(this,arguments)||null)})}function remove(){var e=this.parentNode;e&&e.removeChild(this)}function selection_remove(){return this.each(remove)}function selection_cloneShallow(){var e=this.cloneNode(!1),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function selection_cloneDeep(){var e=this.cloneNode(!0),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function selection_clone(e){return this.select(e?selection_cloneDeep:selection_cloneShallow)}function selection_datum(e){return arguments.length?this.property("__data__",e):this.node().__data__}function contextListener(e){return function(t){e.call(this,t,this.__data__)}}function parseTypenames(e){return e.trim().split(/^|\s+/).map(function(t){var Ye="",tt=t.indexOf(".");return tt>=0&&(Ye=t.slice(tt+1),t=t.slice(0,tt)),{type:t,name:Ye}})}function onRemove(e){return function(){var t=this.__on;if(t){for(var Ye=0,tt=-1,rt=t.length,nt;Ye<rt;++Ye)nt=t[Ye],(!e.type||nt.type===e.type)&&nt.name===e.name?this.removeEventListener(nt.type,nt.listener,nt.options):t[++tt]=nt;++tt?t.length=tt:delete this.__on}}}function onAdd(e,t,Ye){return function(){var tt=this.__on,rt,nt=contextListener(t);if(tt){for(var at=0,it=tt.length;at<it;++at)if((rt=tt[at]).type===e.type&&rt.name===e.name){this.removeEventListener(rt.type,rt.listener,rt.options),this.addEventListener(rt.type,rt.listener=nt,rt.options=Ye),rt.value=t;return}}this.addEventListener(e.type,nt,Ye),rt={type:e.type,name:e.name,value:t,listener:nt,options:Ye},tt?tt.push(rt):this.__on=[rt]}}function selection_on(e,t,Ye){var tt=parseTypenames(e+""),rt,nt=tt.length,at;if(arguments.length<2){var it=this.node().__on;if(it){for(var ot=0,ct=it.length,At;ot<ct;++ot)for(rt=0,At=it[ot];rt<nt;++rt)if((at=tt[rt]).type===At.type&&at.name===At.name)return At.value}return}for(it=t?onAdd:onRemove,rt=0;rt<nt;++rt)this.each(it(tt[rt],t,Ye));return this}function dispatchEvent(e,t,Ye){var tt=defaultView(e),rt=tt.CustomEvent;typeof rt=="function"?rt=new rt(t,Ye):(rt=tt.document.createEvent("Event"),Ye?(rt.initEvent(t,Ye.bubbles,Ye.cancelable),rt.detail=Ye.detail):rt.initEvent(t,!1,!1)),e.dispatchEvent(rt)}function dispatchConstant(e,t){return function(){return dispatchEvent(this,e,t)}}function dispatchFunction(e,t){return function(){return dispatchEvent(this,e,t.apply(this,arguments))}}function selection_dispatch(e,t){return this.each((typeof t=="function"?dispatchFunction:dispatchConstant)(e,t))}function*selection_iterator(){for(var e=this._groups,t=0,Ye=e.length;t<Ye;++t)for(var tt=e[t],rt=0,nt=tt.length,at;rt<nt;++rt)(at=tt[rt])&&(yield at)}var root$1=[null];function Selection$1(e,t){this._groups=e,this._parents=t}function selection(){return new Selection$1([[document.documentElement]],root$1)}function selection_selection(){return this}Selection$1.prototype=selection.prototype={constructor:Selection$1,select:selection_select,selectAll:selection_selectAll,selectChild:selection_selectChild,selectChildren:selection_selectChildren,filter:selection_filter,data:selection_data,enter:selection_enter,exit:selection_exit,join:selection_join,merge:selection_merge,selection:selection_selection,order:selection_order,sort:selection_sort,call:selection_call,nodes:selection_nodes,node:selection_node,size:selection_size,empty:selection_empty,each:selection_each,attr:selection_attr,style:selection_style,property:selection_property,classed:selection_classed,text:selection_text,html:selection_html,raise:selection_raise,lower:selection_lower,append:selection_append,insert:selection_insert,remove:selection_remove,clone:selection_clone,datum:selection_datum,on:selection_on,dispatch:selection_dispatch,[Symbol.iterator]:selection_iterator};function select(e){return typeof e=="string"?new Selection$1([[document.querySelector(e)]],[document.documentElement]):new Selection$1([[e]],root$1)}function sourceEvent(e){let t;for(;t=e.sourceEvent;)e=t;return e}function pointer(e,t){if(e=sourceEvent(e),t===void 0&&(t=e.currentTarget),t){var Ye=t.ownerSVGElement||t;if(Ye.createSVGPoint){var tt=Ye.createSVGPoint();return tt.x=e.clientX,tt.y=e.clientY,tt=tt.matrixTransform(t.getScreenCTM().inverse()),[tt.x,tt.y]}if(t.getBoundingClientRect){var rt=t.getBoundingClientRect();return[e.clientX-rt.left-t.clientLeft,e.clientY-rt.top-t.clientTop]}}return[e.pageX,e.pageY]}const nonpassive={passive:!1},nonpassivecapture={capture:!0,passive:!1};function nopropagation$1(e){e.stopImmediatePropagation()}function noevent$1(e){e.preventDefault(),e.stopImmediatePropagation()}function dragDisable(e){var t=e.document.documentElement,Ye=select(e).on("dragstart.drag",noevent$1,nonpassivecapture);"onselectstart"in t?Ye.on("selectstart.drag",noevent$1,nonpassivecapture):(t.__noselect=t.style.MozUserSelect,t.style.MozUserSelect="none")}function yesdrag(e,t){var Ye=e.document.documentElement,tt=select(e).on("dragstart.drag",null);t&&(tt.on("click.drag",noevent$1,nonpassivecapture),setTimeout(function(){tt.on("click.drag",null)},0)),"onselectstart"in Ye?tt.on("selectstart.drag",null):(Ye.style.MozUserSelect=Ye.__noselect,delete Ye.__noselect)}const constant$3=e=>()=>e;function DragEvent(e,{sourceEvent:t,subject:Ye,target:tt,identifier:rt,active:nt,x:at,y:it,dx:ot,dy:ct,dispatch:At}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},subject:{value:Ye,enumerable:!0,configurable:!0},target:{value:tt,enumerable:!0,configurable:!0},identifier:{value:rt,enumerable:!0,configurable:!0},active:{value:nt,enumerable:!0,configurable:!0},x:{value:at,enumerable:!0,configurable:!0},y:{value:it,enumerable:!0,configurable:!0},dx:{value:ot,enumerable:!0,configurable:!0},dy:{value:ct,enumerable:!0,configurable:!0},_:{value:At}})}DragEvent.prototype.on=function(){var e=this._.on.apply(this._,arguments);return e===this._?this:e};function defaultFilter$1(e){return!e.ctrlKey&&!e.button}function defaultContainer(){return this.parentNode}function defaultSubject(e,t){return t??{x:e.x,y:e.y}}function defaultTouchable$1(){return navigator.maxTouchPoints||"ontouchstart"in this}function drag(){var e=defaultFilter$1,t=defaultContainer,Ye=defaultSubject,tt=defaultTouchable$1,rt={},nt=dispatch("start","drag","end"),at=0,it,ot,ct,At,Rt=0;function qt(Zt){Zt.on("mousedown.drag",Ft).filter(tt).on("touchstart.drag",zt).on("touchmove.drag",Yt,nonpassive).on("touchend.drag touchcancel.drag",Gt).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function Ft(Zt,Xt){if(!(At||!e.call(this,Zt,Xt))){var Qt=Vt(this,t.call(this,Zt,Xt),Zt,Xt,"mouse");Qt&&(select(Zt.view).on("mousemove.drag",Ut,nonpassivecapture).on("mouseup.drag",Ht,nonpassivecapture),dragDisable(Zt.view),nopropagation$1(Zt),ct=!1,it=Zt.clientX,ot=Zt.clientY,Qt("start",Zt))}}function Ut(Zt){if(noevent$1(Zt),!ct){var Xt=Zt.clientX-it,Qt=Zt.clientY-ot;ct=Xt*Xt+Qt*Qt>Rt}rt.mouse("drag",Zt)}function Ht(Zt){select(Zt.view).on("mousemove.drag mouseup.drag",null),yesdrag(Zt.view,ct),noevent$1(Zt),rt.mouse("end",Zt)}function zt(Zt,Xt){if(e.call(this,Zt,Xt)){var Qt=Zt.changedTouches,er=t.call(this,Zt,Xt),nr=Qt.length,ar,sr;for(ar=0;ar<nr;++ar)(sr=Vt(this,er,Zt,Xt,Qt[ar].identifier,Qt[ar]))&&(nopropagation$1(Zt),sr("start",Zt,Qt[ar]))}}function Yt(Zt){var Xt=Zt.changedTouches,Qt=Xt.length,er,nr;for(er=0;er<Qt;++er)(nr=rt[Xt[er].identifier])&&(noevent$1(Zt),nr("drag",Zt,Xt[er]))}function Gt(Zt){var Xt=Zt.changedTouches,Qt=Xt.length,er,nr;for(At&&clearTimeout(At),At=setTimeout(function(){At=null},500),er=0;er<Qt;++er)(nr=rt[Xt[er].identifier])&&(nopropagation$1(Zt),nr("end",Zt,Xt[er]))}function Vt(Zt,Xt,Qt,er,nr,ar){var sr=nt.copy(),lr=pointer(ar||Qt,Xt),fr,gr,dr;if((dr=Ye.call(Zt,new DragEvent("beforestart",{sourceEvent:Qt,target:qt,identifier:nr,active:at,x:lr[0],y:lr[1],dx:0,dy:0,dispatch:sr}),er))!=null)return fr=dr.x-lr[0]||0,gr=dr.y-lr[1]||0,function vr(mr,Er,_r){var Tr=lr,ur;switch(mr){case"start":rt[nr]=vr,ur=at++;break;case"end":delete rt[nr],--at;case"drag":lr=pointer(_r||Er,Xt),ur=at;break}sr.call(mr,Zt,new DragEvent(mr,{sourceEvent:Er,subject:dr,target:qt,identifier:nr,active:ur,x:lr[0]+fr,y:lr[1]+gr,dx:lr[0]-Tr[0],dy:lr[1]-Tr[1],dispatch:sr}),er)}}return qt.filter=function(Zt){return arguments.length?(e=typeof Zt=="function"?Zt:constant$3(!!Zt),qt):e},qt.container=function(Zt){return arguments.length?(t=typeof Zt=="function"?Zt:constant$3(Zt),qt):t},qt.subject=function(Zt){return arguments.length?(Ye=typeof Zt=="function"?Zt:constant$3(Zt),qt):Ye},qt.touchable=function(Zt){return arguments.length?(tt=typeof Zt=="function"?Zt:constant$3(!!Zt),qt):tt},qt.on=function(){var Zt=nt.on.apply(nt,arguments);return Zt===nt?qt:Zt},qt.clickDistance=function(Zt){return arguments.length?(Rt=(Zt=+Zt)*Zt,qt):Math.sqrt(Rt)},qt}function define(e,t,Ye){e.prototype=t.prototype=Ye,Ye.constructor=e}function extend(e,t){var Ye=Object.create(e.prototype);for(var tt in t)Ye[tt]=t[tt];return Ye}function Color(){}var darker=.7,brighter=1/darker,reI="\\s*([+-]?\\d+)\\s*",reN="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",reP="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",reHex=/^#([0-9a-f]{3,8})$/,reRgbInteger=new RegExp(`^rgb\\(${reI},${reI},${reI}\\)$`),reRgbPercent=new RegExp(`^rgb\\(${reP},${reP},${reP}\\)$`),reRgbaInteger=new RegExp(`^rgba\\(${reI},${reI},${reI},${reN}\\)$`),reRgbaPercent=new RegExp(`^rgba\\(${reP},${reP},${reP},${reN}\\)$`),reHslPercent=new RegExp(`^hsl\\(${reN},${reP},${reP}\\)$`),reHslaPercent=new RegExp(`^hsla\\(${reN},${reP},${reP},${reN}\\)$`),named={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};define(Color,color,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:color_formatHex,formatHex:color_formatHex,formatHex8:color_formatHex8,formatHsl:color_formatHsl,formatRgb:color_formatRgb,toString:color_formatRgb});function color_formatHex(){return this.rgb().formatHex()}function color_formatHex8(){return this.rgb().formatHex8()}function color_formatHsl(){return hslConvert(this).formatHsl()}function color_formatRgb(){return this.rgb().formatRgb()}function color(e){var t,Ye;return e=(e+"").trim().toLowerCase(),(t=reHex.exec(e))?(Ye=t[1].length,t=parseInt(t[1],16),Ye===6?rgbn(t):Ye===3?new Rgb(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):Ye===8?rgba(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):Ye===4?rgba(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=reRgbInteger.exec(e))?new Rgb(t[1],t[2],t[3],1):(t=reRgbPercent.exec(e))?new Rgb(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=reRgbaInteger.exec(e))?rgba(t[1],t[2],t[3],t[4]):(t=reRgbaPercent.exec(e))?rgba(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=reHslPercent.exec(e))?hsla(t[1],t[2]/100,t[3]/100,1):(t=reHslaPercent.exec(e))?hsla(t[1],t[2]/100,t[3]/100,t[4]):named.hasOwnProperty(e)?rgbn(named[e]):e==="transparent"?new Rgb(NaN,NaN,NaN,0):null}function rgbn(e){return new Rgb(e>>16&255,e>>8&255,e&255,1)}function rgba(e,t,Ye,tt){return tt<=0&&(e=t=Ye=NaN),new Rgb(e,t,Ye,tt)}function rgbConvert(e){return e instanceof Color||(e=color(e)),e?(e=e.rgb(),new Rgb(e.r,e.g,e.b,e.opacity)):new Rgb}function rgb(e,t,Ye,tt){return arguments.length===1?rgbConvert(e):new Rgb(e,t,Ye,tt??1)}function Rgb(e,t,Ye,tt){this.r=+e,this.g=+t,this.b=+Ye,this.opacity=+tt}define(Rgb,rgb,extend(Color,{brighter(e){return e=e==null?brighter:Math.pow(brighter,e),new Rgb(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?darker:Math.pow(darker,e),new Rgb(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new Rgb(clampi(this.r),clampi(this.g),clampi(this.b),clampa(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:rgb_formatHex,formatHex:rgb_formatHex,formatHex8:rgb_formatHex8,formatRgb:rgb_formatRgb,toString:rgb_formatRgb}));function rgb_formatHex(){return`#${hex(this.r)}${hex(this.g)}${hex(this.b)}`}function rgb_formatHex8(){return`#${hex(this.r)}${hex(this.g)}${hex(this.b)}${hex((isNaN(this.opacity)?1:this.opacity)*255)}`}function rgb_formatRgb(){const e=clampa(this.opacity);return`${e===1?"rgb(":"rgba("}${clampi(this.r)}, ${clampi(this.g)}, ${clampi(this.b)}${e===1?")":`, ${e})`}`}function clampa(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function clampi(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function hex(e){return e=clampi(e),(e<16?"0":"")+e.toString(16)}function hsla(e,t,Ye,tt){return tt<=0?e=t=Ye=NaN:Ye<=0||Ye>=1?e=t=NaN:t<=0&&(e=NaN),new Hsl(e,t,Ye,tt)}function hslConvert(e){if(e instanceof Hsl)return new Hsl(e.h,e.s,e.l,e.opacity);if(e instanceof Color||(e=color(e)),!e)return new Hsl;if(e instanceof Hsl)return e;e=e.rgb();var t=e.r/255,Ye=e.g/255,tt=e.b/255,rt=Math.min(t,Ye,tt),nt=Math.max(t,Ye,tt),at=NaN,it=nt-rt,ot=(nt+rt)/2;return it?(t===nt?at=(Ye-tt)/it+(Ye<tt)*6:Ye===nt?at=(tt-t)/it+2:at=(t-Ye)/it+4,it/=ot<.5?nt+rt:2-nt-rt,at*=60):it=ot>0&&ot<1?0:at,new Hsl(at,it,ot,e.opacity)}function hsl(e,t,Ye,tt){return arguments.length===1?hslConvert(e):new Hsl(e,t,Ye,tt??1)}function Hsl(e,t,Ye,tt){this.h=+e,this.s=+t,this.l=+Ye,this.opacity=+tt}define(Hsl,hsl,extend(Color,{brighter(e){return e=e==null?brighter:Math.pow(brighter,e),new Hsl(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?darker:Math.pow(darker,e),new Hsl(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,Ye=this.l,tt=Ye+(Ye<.5?Ye:1-Ye)*t,rt=2*Ye-tt;return new Rgb(hsl2rgb(e>=240?e-240:e+120,rt,tt),hsl2rgb(e,rt,tt),hsl2rgb(e<120?e+240:e-120,rt,tt),this.opacity)},clamp(){return new Hsl(clamph(this.h),clampt(this.s),clampt(this.l),clampa(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=clampa(this.opacity);return`${e===1?"hsl(":"hsla("}${clamph(this.h)}, ${clampt(this.s)*100}%, ${clampt(this.l)*100}%${e===1?")":`, ${e})`}`}}));function clamph(e){return e=(e||0)%360,e<0?e+360:e}function clampt(e){return Math.max(0,Math.min(1,e||0))}function hsl2rgb(e,t,Ye){return(e<60?t+(Ye-t)*e/60:e<180?Ye:e<240?t+(Ye-t)*(240-e)/60:t)*255}const constant$2=e=>()=>e;function linear(e,t){return function(Ye){return e+Ye*t}}function exponential(e,t,Ye){return e=Math.pow(e,Ye),t=Math.pow(t,Ye)-e,Ye=1/Ye,function(tt){return Math.pow(e+tt*t,Ye)}}function hue(e,t){var Ye=t-e;return Ye?linear(e,Ye>180||Ye<-180?Ye-360*Math.round(Ye/360):Ye):constant$2(isNaN(e)?t:e)}function gamma(e){return(e=+e)==1?nogamma:function(t,Ye){return Ye-t?exponential(t,Ye,e):constant$2(isNaN(t)?Ye:t)}}function nogamma(e,t){var Ye=t-e;return Ye?linear(e,Ye):constant$2(isNaN(e)?t:e)}const interpolateRgb=function e(t){var Ye=gamma(t);function tt(rt,nt){var at=Ye((rt=rgb(rt)).r,(nt=rgb(nt)).r),it=Ye(rt.g,nt.g),ot=Ye(rt.b,nt.b),ct=nogamma(rt.opacity,nt.opacity);return function(At){return rt.r=at(At),rt.g=it(At),rt.b=ot(At),rt.opacity=ct(At),rt+""}}return tt.gamma=e,tt}(1);function interpolateNumber(e,t){return e=+e,t=+t,function(Ye){return e*(1-Ye)+t*Ye}}var reA=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,reB=new RegExp(reA.source,"g");function zero(e){return function(){return e}}function one(e){return function(t){return e(t)+""}}function interpolateString(e,t){var Ye=reA.lastIndex=reB.lastIndex=0,tt,rt,nt,at=-1,it=[],ot=[];for(e=e+"",t=t+"";(tt=reA.exec(e))&&(rt=reB.exec(t));)(nt=rt.index)>Ye&&(nt=t.slice(Ye,nt),it[at]?it[at]+=nt:it[++at]=nt),(tt=tt[0])===(rt=rt[0])?it[at]?it[at]+=rt:it[++at]=rt:(it[++at]=null,ot.push({i:at,x:interpolateNumber(tt,rt)})),Ye=reB.lastIndex;return Ye<t.length&&(nt=t.slice(Ye),it[at]?it[at]+=nt:it[++at]=nt),it.length<2?ot[0]?one(ot[0].x):zero(t):(t=ot.length,function(ct){for(var At=0,Rt;At<t;++At)it[(Rt=ot[At]).i]=Rt.x(ct);return it.join("")})}var degrees=180/Math.PI,identity$3={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function decompose(e,t,Ye,tt,rt,nt){var at,it,ot;return(at=Math.sqrt(e*e+t*t))&&(e/=at,t/=at),(ot=e*Ye+t*tt)&&(Ye-=e*ot,tt-=t*ot),(it=Math.sqrt(Ye*Ye+tt*tt))&&(Ye/=it,tt/=it,ot/=it),e*tt<t*Ye&&(e=-e,t=-t,ot=-ot,at=-at),{translateX:rt,translateY:nt,rotate:Math.atan2(t,e)*degrees,skewX:Math.atan(ot)*degrees,scaleX:at,scaleY:it}}var svgNode;function parseCss(e){const t=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(e+"");return t.isIdentity?identity$3:decompose(t.a,t.b,t.c,t.d,t.e,t.f)}function parseSvg(e){return e==null||(svgNode||(svgNode=document.createElementNS("http://www.w3.org/2000/svg","g")),svgNode.setAttribute("transform",e),!(e=svgNode.transform.baseVal.consolidate()))?identity$3:(e=e.matrix,decompose(e.a,e.b,e.c,e.d,e.e,e.f))}function interpolateTransform(e,t,Ye,tt){function rt(ct){return ct.length?ct.pop()+" ":""}function nt(ct,At,Rt,qt,Ft,Ut){if(ct!==Rt||At!==qt){var Ht=Ft.push("translate(",null,t,null,Ye);Ut.push({i:Ht-4,x:interpolateNumber(ct,Rt)},{i:Ht-2,x:interpolateNumber(At,qt)})}else(Rt||qt)&&Ft.push("translate("+Rt+t+qt+Ye)}function at(ct,At,Rt,qt){ct!==At?(ct-At>180?At+=360:At-ct>180&&(ct+=360),qt.push({i:Rt.push(rt(Rt)+"rotate(",null,tt)-2,x:interpolateNumber(ct,At)})):At&&Rt.push(rt(Rt)+"rotate("+At+tt)}function it(ct,At,Rt,qt){ct!==At?qt.push({i:Rt.push(rt(Rt)+"skewX(",null,tt)-2,x:interpolateNumber(ct,At)}):At&&Rt.push(rt(Rt)+"skewX("+At+tt)}function ot(ct,At,Rt,qt,Ft,Ut){if(ct!==Rt||At!==qt){var Ht=Ft.push(rt(Ft)+"scale(",null,",",null,")");Ut.push({i:Ht-4,x:interpolateNumber(ct,Rt)},{i:Ht-2,x:interpolateNumber(At,qt)})}else(Rt!==1||qt!==1)&&Ft.push(rt(Ft)+"scale("+Rt+","+qt+")")}return function(ct,At){var Rt=[],qt=[];return ct=e(ct),At=e(At),nt(ct.translateX,ct.translateY,At.translateX,At.translateY,Rt,qt),at(ct.rotate,At.rotate,Rt,qt),it(ct.skewX,At.skewX,Rt,qt),ot(ct.scaleX,ct.scaleY,At.scaleX,At.scaleY,Rt,qt),ct=At=null,function(Ft){for(var Ut=-1,Ht=qt.length,zt;++Ut<Ht;)Rt[(zt=qt[Ut]).i]=zt.x(Ft);return Rt.join("")}}}var interpolateTransformCss=interpolateTransform(parseCss,"px, ","px)","deg)"),interpolateTransformSvg=interpolateTransform(parseSvg,", ",")",")"),epsilon2=1e-12;function cosh(e){return((e=Math.exp(e))+1/e)/2}function sinh(e){return((e=Math.exp(e))-1/e)/2}function tanh(e){return((e=Math.exp(2*e))-1)/(e+1)}const interpolateZoom=function e(t,Ye,tt){function rt(nt,at){var it=nt[0],ot=nt[1],ct=nt[2],At=at[0],Rt=at[1],qt=at[2],Ft=At-it,Ut=Rt-ot,Ht=Ft*Ft+Ut*Ut,zt,Yt;if(Ht<epsilon2)Yt=Math.log(qt/ct)/t,zt=function(er){return[it+er*Ft,ot+er*Ut,ct*Math.exp(t*er*Yt)]};else{var Gt=Math.sqrt(Ht),Vt=(qt*qt-ct*ct+tt*Ht)/(2*ct*Ye*Gt),Zt=(qt*qt-ct*ct-tt*Ht)/(2*qt*Ye*Gt),Xt=Math.log(Math.sqrt(Vt*Vt+1)-Vt),Qt=Math.log(Math.sqrt(Zt*Zt+1)-Zt);Yt=(Qt-Xt)/t,zt=function(er){var nr=er*Yt,ar=cosh(Xt),sr=ct/(Ye*Gt)*(ar*tanh(t*nr+Xt)-sinh(Xt));return[it+sr*Ft,ot+sr*Ut,ct*ar/cosh(t*nr+Xt)]}}return zt.duration=Yt*1e3*t/Math.SQRT2,zt}return rt.rho=function(nt){var at=Math.max(.001,+nt),it=at*at,ot=it*it;return e(at,it,ot)},rt}(Math.SQRT2,2,4);var frame=0,timeout$1=0,interval=0,pokeDelay=1e3,taskHead,taskTail,clockLast=0,clockNow=0,clockSkew=0,clock=typeof performance=="object"&&performance.now?performance:Date,setFrame=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function now(){return clockNow||(setFrame(clearNow),clockNow=clock.now()+clockSkew)}function clearNow(){clockNow=0}function Timer(){this._call=this._time=this._next=null}Timer.prototype=timer.prototype={constructor:Timer,restart:function(e,t,Ye){if(typeof e!="function")throw new TypeError("callback is not a function");Ye=(Ye==null?now():+Ye)+(t==null?0:+t),!this._next&&taskTail!==this&&(taskTail?taskTail._next=this:taskHead=this,taskTail=this),this._call=e,this._time=Ye,sleep()},stop:function(){this._call&&(this._call=null,this._time=1/0,sleep())}};function timer(e,t,Ye){var tt=new Timer;return tt.restart(e,t,Ye),tt}function timerFlush(){now(),++frame;for(var e=taskHead,t;e;)(t=clockNow-e._time)>=0&&e._call.call(void 0,t),e=e._next;--frame}function wake(){clockNow=(clockLast=clock.now())+clockSkew,frame=timeout$1=0;try{timerFlush()}finally{frame=0,nap(),clockNow=0}}function poke(){var e=clock.now(),t=e-clockLast;t>pokeDelay&&(clockSkew-=t,clockLast=e)}function nap(){for(var e,t=taskHead,Ye,tt=1/0;t;)t._call?(tt>t._time&&(tt=t._time),e=t,t=t._next):(Ye=t._next,t._next=null,t=e?e._next=Ye:taskHead=Ye);taskTail=e,sleep(tt)}function sleep(e){if(!frame){timeout$1&&(timeout$1=clearTimeout(timeout$1));var t=e-clockNow;t>24?(e<1/0&&(timeout$1=setTimeout(wake,e-clock.now()-clockSkew)),interval&&(interval=clearInterval(interval))):(interval||(clockLast=clock.now(),interval=setInterval(poke,pokeDelay)),frame=1,setFrame(wake))}}function timeout(e,t,Ye){var tt=new Timer;return t=t==null?0:+t,tt.restart(rt=>{tt.stop(),e(rt+t)},t,Ye),tt}var emptyOn=dispatch("start","end","cancel","interrupt"),emptyTween=[],CREATED=0,SCHEDULED=1,STARTING=2,STARTED=3,RUNNING=4,ENDING=5,ENDED=6;function schedule(e,t,Ye,tt,rt,nt){var at=e.__transition;if(!at)e.__transition={};else if(Ye in at)return;create(e,Ye,{name:t,index:tt,group:rt,on:emptyOn,tween:emptyTween,time:nt.time,delay:nt.delay,duration:nt.duration,ease:nt.ease,timer:null,state:CREATED})}function init(e,t){var Ye=get$1(e,t);if(Ye.state>CREATED)throw new Error("too late; already scheduled");return Ye}function set$1(e,t){var Ye=get$1(e,t);if(Ye.state>STARTED)throw new Error("too late; already running");return Ye}function get$1(e,t){var Ye=e.__transition;if(!Ye||!(Ye=Ye[t]))throw new Error("transition not found");return Ye}function create(e,t,Ye){var tt=e.__transition,rt;tt[t]=Ye,Ye.timer=timer(nt,0,Ye.time);function nt(ct){Ye.state=SCHEDULED,Ye.timer.restart(at,Ye.delay,Ye.time),Ye.delay<=ct&&at(ct-Ye.delay)}function at(ct){var At,Rt,qt,Ft;if(Ye.state!==SCHEDULED)return ot();for(At in tt)if(Ft=tt[At],Ft.name===Ye.name){if(Ft.state===STARTED)return timeout(at);Ft.state===RUNNING?(Ft.state=ENDED,Ft.timer.stop(),Ft.on.call("interrupt",e,e.__data__,Ft.index,Ft.group),delete tt[At]):+At<t&&(Ft.state=ENDED,Ft.timer.stop(),Ft.on.call("cancel",e,e.__data__,Ft.index,Ft.group),delete tt[At])}if(timeout(function(){Ye.state===STARTED&&(Ye.state=RUNNING,Ye.timer.restart(it,Ye.delay,Ye.time),it(ct))}),Ye.state=STARTING,Ye.on.call("start",e,e.__data__,Ye.index,Ye.group),Ye.state===STARTING){for(Ye.state=STARTED,rt=new Array(qt=Ye.tween.length),At=0,Rt=-1;At<qt;++At)(Ft=Ye.tween[At].value.call(e,e.__data__,Ye.index,Ye.group))&&(rt[++Rt]=Ft);rt.length=Rt+1}}function it(ct){for(var At=ct<Ye.duration?Ye.ease.call(null,ct/Ye.duration):(Ye.timer.restart(ot),Ye.state=ENDING,1),Rt=-1,qt=rt.length;++Rt<qt;)rt[Rt].call(e,At);Ye.state===ENDING&&(Ye.on.call("end",e,e.__data__,Ye.index,Ye.group),ot())}function ot(){Ye.state=ENDED,Ye.timer.stop(),delete tt[t];for(var ct in tt)return;delete e.__transition}}function interrupt(e,t){var Ye=e.__transition,tt,rt,nt=!0,at;if(Ye){t=t==null?null:t+"";for(at in Ye){if((tt=Ye[at]).name!==t){nt=!1;continue}rt=tt.state>STARTING&&tt.state<ENDING,tt.state=ENDED,tt.timer.stop(),tt.on.call(rt?"interrupt":"cancel",e,e.__data__,tt.index,tt.group),delete Ye[at]}nt&&delete e.__transition}}function selection_interrupt(e){return this.each(function(){interrupt(this,e)})}function tweenRemove(e,t){var Ye,tt;return function(){var rt=set$1(this,e),nt=rt.tween;if(nt!==Ye){tt=Ye=nt;for(var at=0,it=tt.length;at<it;++at)if(tt[at].name===t){tt=tt.slice(),tt.splice(at,1);break}}rt.tween=tt}}function tweenFunction(e,t,Ye){var tt,rt;if(typeof Ye!="function")throw new Error;return function(){var nt=set$1(this,e),at=nt.tween;if(at!==tt){rt=(tt=at).slice();for(var it={name:t,value:Ye},ot=0,ct=rt.length;ot<ct;++ot)if(rt[ot].name===t){rt[ot]=it;break}ot===ct&&rt.push(it)}nt.tween=rt}}function transition_tween(e,t){var Ye=this._id;if(e+="",arguments.length<2){for(var tt=get$1(this.node(),Ye).tween,rt=0,nt=tt.length,at;rt<nt;++rt)if((at=tt[rt]).name===e)return at.value;return null}return this.each((t==null?tweenRemove:tweenFunction)(Ye,e,t))}function tweenValue(e,t,Ye){var tt=e._id;return e.each(function(){var rt=set$1(this,tt);(rt.value||(rt.value={}))[t]=Ye.apply(this,arguments)}),function(rt){return get$1(rt,tt).value[t]}}function interpolate(e,t){var Ye;return(typeof t=="number"?interpolateNumber:t instanceof color?interpolateRgb:(Ye=color(t))?(t=Ye,interpolateRgb):interpolateString)(e,t)}function attrRemove(e){return function(){this.removeAttribute(e)}}function attrRemoveNS(e){return function(){this.removeAttributeNS(e.space,e.local)}}function attrConstant(e,t,Ye){var tt,rt=Ye+"",nt;return function(){var at=this.getAttribute(e);return at===rt?null:at===tt?nt:nt=t(tt=at,Ye)}}function attrConstantNS(e,t,Ye){var tt,rt=Ye+"",nt;return function(){var at=this.getAttributeNS(e.space,e.local);return at===rt?null:at===tt?nt:nt=t(tt=at,Ye)}}function attrFunction(e,t,Ye){var tt,rt,nt;return function(){var at,it=Ye(this),ot;return it==null?void this.removeAttribute(e):(at=this.getAttribute(e),ot=it+"",at===ot?null:at===tt&&ot===rt?nt:(rt=ot,nt=t(tt=at,it)))}}function attrFunctionNS(e,t,Ye){var tt,rt,nt;return function(){var at,it=Ye(this),ot;return it==null?void this.removeAttributeNS(e.space,e.local):(at=this.getAttributeNS(e.space,e.local),ot=it+"",at===ot?null:at===tt&&ot===rt?nt:(rt=ot,nt=t(tt=at,it)))}}function transition_attr(e,t){var Ye=namespace(e),tt=Ye==="transform"?interpolateTransformSvg:interpolate;return this.attrTween(e,typeof t=="function"?(Ye.local?attrFunctionNS:attrFunction)(Ye,tt,tweenValue(this,"attr."+e,t)):t==null?(Ye.local?attrRemoveNS:attrRemove)(Ye):(Ye.local?attrConstantNS:attrConstant)(Ye,tt,t))}function attrInterpolate(e,t){return function(Ye){this.setAttribute(e,t.call(this,Ye))}}function attrInterpolateNS(e,t){return function(Ye){this.setAttributeNS(e.space,e.local,t.call(this,Ye))}}function attrTweenNS(e,t){var Ye,tt;function rt(){var nt=t.apply(this,arguments);return nt!==tt&&(Ye=(tt=nt)&&attrInterpolateNS(e,nt)),Ye}return rt._value=t,rt}function attrTween(e,t){var Ye,tt;function rt(){var nt=t.apply(this,arguments);return nt!==tt&&(Ye=(tt=nt)&&attrInterpolate(e,nt)),Ye}return rt._value=t,rt}function transition_attrTween(e,t){var Ye="attr."+e;if(arguments.length<2)return(Ye=this.tween(Ye))&&Ye._value;if(t==null)return this.tween(Ye,null);if(typeof t!="function")throw new Error;var tt=namespace(e);return this.tween(Ye,(tt.local?attrTweenNS:attrTween)(tt,t))}function delayFunction(e,t){return function(){init(this,e).delay=+t.apply(this,arguments)}}function delayConstant(e,t){return t=+t,function(){init(this,e).delay=t}}function transition_delay(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?delayFunction:delayConstant)(t,e)):get$1(this.node(),t).delay}function durationFunction(e,t){return function(){set$1(this,e).duration=+t.apply(this,arguments)}}function durationConstant(e,t){return t=+t,function(){set$1(this,e).duration=t}}function transition_duration(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?durationFunction:durationConstant)(t,e)):get$1(this.node(),t).duration}function easeConstant(e,t){if(typeof t!="function")throw new Error;return function(){set$1(this,e).ease=t}}function transition_ease(e){var t=this._id;return arguments.length?this.each(easeConstant(t,e)):get$1(this.node(),t).ease}function easeVarying(e,t){return function(){var Ye=t.apply(this,arguments);if(typeof Ye!="function")throw new Error;set$1(this,e).ease=Ye}}function transition_easeVarying(e){if(typeof e!="function")throw new Error;return this.each(easeVarying(this._id,e))}function transition_filter(e){typeof e!="function"&&(e=matcher(e));for(var t=this._groups,Ye=t.length,tt=new Array(Ye),rt=0;rt<Ye;++rt)for(var nt=t[rt],at=nt.length,it=tt[rt]=[],ot,ct=0;ct<at;++ct)(ot=nt[ct])&&e.call(ot,ot.__data__,ct,nt)&&it.push(ot);return new Transition$1(tt,this._parents,this._name,this._id)}function transition_merge(e){if(e._id!==this._id)throw new Error;for(var t=this._groups,Ye=e._groups,tt=t.length,rt=Ye.length,nt=Math.min(tt,rt),at=new Array(tt),it=0;it<nt;++it)for(var ot=t[it],ct=Ye[it],At=ot.length,Rt=at[it]=new Array(At),qt,Ft=0;Ft<At;++Ft)(qt=ot[Ft]||ct[Ft])&&(Rt[Ft]=qt);for(;it<tt;++it)at[it]=t[it];return new Transition$1(at,this._parents,this._name,this._id)}function start(e){return(e+"").trim().split(/^|\s+/).every(function(t){var Ye=t.indexOf(".");return Ye>=0&&(t=t.slice(0,Ye)),!t||t==="start"})}function onFunction(e,t,Ye){var tt,rt,nt=start(t)?init:set$1;return function(){var at=nt(this,e),it=at.on;it!==tt&&(rt=(tt=it).copy()).on(t,Ye),at.on=rt}}function transition_on(e,t){var Ye=this._id;return arguments.length<2?get$1(this.node(),Ye).on.on(e):this.each(onFunction(Ye,e,t))}function removeFunction(e){return function(){var t=this.parentNode;for(var Ye in this.__transition)if(+Ye!==e)return;t&&t.removeChild(this)}}function transition_remove(){return this.on("end.remove",removeFunction(this._id))}function transition_select(e){var t=this._name,Ye=this._id;typeof e!="function"&&(e=selector(e));for(var tt=this._groups,rt=tt.length,nt=new Array(rt),at=0;at<rt;++at)for(var it=tt[at],ot=it.length,ct=nt[at]=new Array(ot),At,Rt,qt=0;qt<ot;++qt)(At=it[qt])&&(Rt=e.call(At,At.__data__,qt,it))&&("__data__"in At&&(Rt.__data__=At.__data__),ct[qt]=Rt,schedule(ct[qt],t,Ye,qt,ct,get$1(At,Ye)));return new Transition$1(nt,this._parents,t,Ye)}function transition_selectAll(e){var t=this._name,Ye=this._id;typeof e!="function"&&(e=selectorAll(e));for(var tt=this._groups,rt=tt.length,nt=[],at=[],it=0;it<rt;++it)for(var ot=tt[it],ct=ot.length,At,Rt=0;Rt<ct;++Rt)if(At=ot[Rt]){for(var qt=e.call(At,At.__data__,Rt,ot),Ft,Ut=get$1(At,Ye),Ht=0,zt=qt.length;Ht<zt;++Ht)(Ft=qt[Ht])&&schedule(Ft,t,Ye,Ht,qt,Ut);nt.push(qt),at.push(At)}return new Transition$1(nt,at,t,Ye)}var Selection=selection.prototype.constructor;function transition_selection(){return new Selection(this._groups,this._parents)}function styleNull(e,t){var Ye,tt,rt;return function(){var nt=styleValue(this,e),at=(this.style.removeProperty(e),styleValue(this,e));return nt===at?null:nt===Ye&&at===tt?rt:rt=t(Ye=nt,tt=at)}}function styleRemove(e){return function(){this.style.removeProperty(e)}}function styleConstant(e,t,Ye){var tt,rt=Ye+"",nt;return function(){var at=styleValue(this,e);return at===rt?null:at===tt?nt:nt=t(tt=at,Ye)}}function styleFunction(e,t,Ye){var tt,rt,nt;return function(){var at=styleValue(this,e),it=Ye(this),ot=it+"";return it==null&&(ot=it=(this.style.removeProperty(e),styleValue(this,e))),at===ot?null:at===tt&&ot===rt?nt:(rt=ot,nt=t(tt=at,it))}}function styleMaybeRemove(e,t){var Ye,tt,rt,nt="style."+t,at="end."+nt,it;return function(){var ot=set$1(this,e),ct=ot.on,At=ot.value[nt]==null?it||(it=styleRemove(t)):void 0;(ct!==Ye||rt!==At)&&(tt=(Ye=ct).copy()).on(at,rt=At),ot.on=tt}}function transition_style(e,t,Ye){var tt=(e+="")=="transform"?interpolateTransformCss:interpolate;return t==null?this.styleTween(e,styleNull(e,tt)).on("end.style."+e,styleRemove(e)):typeof t=="function"?this.styleTween(e,styleFunction(e,tt,tweenValue(this,"style."+e,t))).each(styleMaybeRemove(this._id,e)):this.styleTween(e,styleConstant(e,tt,t),Ye).on("end.style."+e,null)}function styleInterpolate(e,t,Ye){return function(tt){this.style.setProperty(e,t.call(this,tt),Ye)}}function styleTween(e,t,Ye){var tt,rt;function nt(){var at=t.apply(this,arguments);return at!==rt&&(tt=(rt=at)&&styleInterpolate(e,at,Ye)),tt}return nt._value=t,nt}function transition_styleTween(e,t,Ye){var tt="style."+(e+="");if(arguments.length<2)return(tt=this.tween(tt))&&tt._value;if(t==null)return this.tween(tt,null);if(typeof t!="function")throw new Error;return this.tween(tt,styleTween(e,t,Ye??""))}function textConstant(e){return function(){this.textContent=e}}function textFunction(e){return function(){var t=e(this);this.textContent=t??""}}function transition_text(e){return this.tween("text",typeof e=="function"?textFunction(tweenValue(this,"text",e)):textConstant(e==null?"":e+""))}function textInterpolate(e){return function(t){this.textContent=e.call(this,t)}}function textTween(e){var t,Ye;function tt(){var rt=e.apply(this,arguments);return rt!==Ye&&(t=(Ye=rt)&&textInterpolate(rt)),t}return tt._value=e,tt}function transition_textTween(e){var t="text";if(arguments.length<1)return(t=this.tween(t))&&t._value;if(e==null)return this.tween(t,null);if(typeof e!="function")throw new Error;return this.tween(t,textTween(e))}function transition_transition(){for(var e=this._name,t=this._id,Ye=newId(),tt=this._groups,rt=tt.length,nt=0;nt<rt;++nt)for(var at=tt[nt],it=at.length,ot,ct=0;ct<it;++ct)if(ot=at[ct]){var At=get$1(ot,t);schedule(ot,e,Ye,ct,at,{time:At.time+At.delay+At.duration,delay:0,duration:At.duration,ease:At.ease})}return new Transition$1(tt,this._parents,e,Ye)}function transition_end(){var e,t,Ye=this,tt=Ye._id,rt=Ye.size();return new Promise(function(nt,at){var it={value:at},ot={value:function(){--rt===0&&nt()}};Ye.each(function(){var ct=set$1(this,tt),At=ct.on;At!==e&&(t=(e=At).copy(),t._.cancel.push(it),t._.interrupt.push(it),t._.end.push(ot)),ct.on=t}),rt===0&&nt()})}var id$1=0;function Transition$1(e,t,Ye,tt){this._groups=e,this._parents=t,this._name=Ye,this._id=tt}function newId(){return++id$1}var selection_prototype=selection.prototype;Transition$1.prototype={constructor:Transition$1,select:transition_select,selectAll:transition_selectAll,selectChild:selection_prototype.selectChild,selectChildren:selection_prototype.selectChildren,filter:transition_filter,merge:transition_merge,selection:transition_selection,transition:transition_transition,call:selection_prototype.call,nodes:selection_prototype.nodes,node:selection_prototype.node,size:selection_prototype.size,empty:selection_prototype.empty,each:selection_prototype.each,on:transition_on,attr:transition_attr,attrTween:transition_attrTween,style:transition_style,styleTween:transition_styleTween,text:transition_text,textTween:transition_textTween,remove:transition_remove,tween:transition_tween,delay:transition_delay,duration:transition_duration,ease:transition_ease,easeVarying:transition_easeVarying,end:transition_end,[Symbol.iterator]:selection_prototype[Symbol.iterator]};function cubicInOut(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}var defaultTiming={time:null,delay:0,duration:250,ease:cubicInOut};function inherit(e,t){for(var Ye;!(Ye=e.__transition)||!(Ye=Ye[t]);)if(!(e=e.parentNode))throw new Error(`transition ${t} not found`);return Ye}function selection_transition(e){var t,Ye;e instanceof Transition$1?(t=e._id,e=e._name):(t=newId(),(Ye=defaultTiming).time=now(),e=e==null?null:e+"");for(var tt=this._groups,rt=tt.length,nt=0;nt<rt;++nt)for(var at=tt[nt],it=at.length,ot,ct=0;ct<it;++ct)(ot=at[ct])&&schedule(ot,e,t,ct,at,Ye||inherit(ot,t));return new Transition$1(tt,this._parents,e,t)}selection.prototype.interrupt=selection_interrupt;selection.prototype.transition=selection_transition;const constant$1=e=>()=>e;function ZoomEvent(e,{sourceEvent:t,target:Ye,transform:tt,dispatch:rt}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},target:{value:Ye,enumerable:!0,configurable:!0},transform:{value:tt,enumerable:!0,configurable:!0},_:{value:rt}})}function Transform(e,t,Ye){this.k=e,this.x=t,this.y=Ye}Transform.prototype={constructor:Transform,scale:function(e){return e===1?this:new Transform(this.k*e,this.x,this.y)},translate:function(e,t){return e===0&t===0?this:new Transform(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};var identity$2=new Transform(1,0,0);transform$1.prototype=Transform.prototype;function transform$1(e){for(;!e.__zoom;)if(!(e=e.parentNode))return identity$2;return e.__zoom}function nopropagation(e){e.stopImmediatePropagation()}function noevent(e){e.preventDefault(),e.stopImmediatePropagation()}function defaultFilter(e){return(!e.ctrlKey||e.type==="wheel")&&!e.button}function defaultExtent(){var e=this;return e instanceof SVGElement?(e=e.ownerSVGElement||e,e.hasAttribute("viewBox")?(e=e.viewBox.baseVal,[[e.x,e.y],[e.x+e.width,e.y+e.height]]):[[0,0],[e.width.baseVal.value,e.height.baseVal.value]]):[[0,0],[e.clientWidth,e.clientHeight]]}function defaultTransform(){return this.__zoom||identity$2}function defaultWheelDelta(e){return-e.deltaY*(e.deltaMode===1?.05:e.deltaMode?1:.002)*(e.ctrlKey?10:1)}function defaultTouchable(){return navigator.maxTouchPoints||"ontouchstart"in this}function defaultConstrain(e,t,Ye){var tt=e.invertX(t[0][0])-Ye[0][0],rt=e.invertX(t[1][0])-Ye[1][0],nt=e.invertY(t[0][1])-Ye[0][1],at=e.invertY(t[1][1])-Ye[1][1];return e.translate(rt>tt?(tt+rt)/2:Math.min(0,tt)||Math.max(0,rt),at>nt?(nt+at)/2:Math.min(0,nt)||Math.max(0,at))}function zoom(){var e=defaultFilter,t=defaultExtent,Ye=defaultConstrain,tt=defaultWheelDelta,rt=defaultTouchable,nt=[0,1/0],at=[[-1/0,-1/0],[1/0,1/0]],it=250,ot=interpolateZoom,ct=dispatch("start","zoom","end"),At,Rt,qt,Ft=500,Ut=150,Ht=0,zt=10;function Yt(dr){dr.property("__zoom",defaultTransform).on("wheel.zoom",nr,{passive:!1}).on("mousedown.zoom",ar).on("dblclick.zoom",sr).filter(rt).on("touchstart.zoom",lr).on("touchmove.zoom",fr).on("touchend.zoom touchcancel.zoom",gr).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}Yt.transform=function(dr,vr,mr,Er){var _r=dr.selection?dr.selection():dr;_r.property("__zoom",defaultTransform),dr!==_r?Xt(dr,vr,mr,Er):_r.interrupt().each(function(){Qt(this,arguments).event(Er).start().zoom(null,typeof vr=="function"?vr.apply(this,arguments):vr).end()})},Yt.scaleBy=function(dr,vr,mr,Er){Yt.scaleTo(dr,function(){var _r=this.__zoom.k,Tr=typeof vr=="function"?vr.apply(this,arguments):vr;return _r*Tr},mr,Er)},Yt.scaleTo=function(dr,vr,mr,Er){Yt.transform(dr,function(){var _r=t.apply(this,arguments),Tr=this.__zoom,ur=mr==null?Zt(_r):typeof mr=="function"?mr.apply(this,arguments):mr,cr=Tr.invert(ur),yr=typeof vr=="function"?vr.apply(this,arguments):vr;return Ye(Vt(Gt(Tr,yr),ur,cr),_r,at)},mr,Er)},Yt.translateBy=function(dr,vr,mr,Er){Yt.transform(dr,function(){return Ye(this.__zoom.translate(typeof vr=="function"?vr.apply(this,arguments):vr,typeof mr=="function"?mr.apply(this,arguments):mr),t.apply(this,arguments),at)},null,Er)},Yt.translateTo=function(dr,vr,mr,Er,_r){Yt.transform(dr,function(){var Tr=t.apply(this,arguments),ur=this.__zoom,cr=Er==null?Zt(Tr):typeof Er=="function"?Er.apply(this,arguments):Er;return Ye(identity$2.translate(cr[0],cr[1]).scale(ur.k).translate(typeof vr=="function"?-vr.apply(this,arguments):-vr,typeof mr=="function"?-mr.apply(this,arguments):-mr),Tr,at)},Er,_r)};function Gt(dr,vr){return vr=Math.max(nt[0],Math.min(nt[1],vr)),vr===dr.k?dr:new Transform(vr,dr.x,dr.y)}function Vt(dr,vr,mr){var Er=vr[0]-mr[0]*dr.k,_r=vr[1]-mr[1]*dr.k;return Er===dr.x&&_r===dr.y?dr:new Transform(dr.k,Er,_r)}function Zt(dr){return[(+dr[0][0]+ +dr[1][0])/2,(+dr[0][1]+ +dr[1][1])/2]}function Xt(dr,vr,mr,Er){dr.on("start.zoom",function(){Qt(this,arguments).event(Er).start()}).on("interrupt.zoom end.zoom",function(){Qt(this,arguments).event(Er).end()}).tween("zoom",function(){var _r=this,Tr=arguments,ur=Qt(_r,Tr).event(Er),cr=t.apply(_r,Tr),yr=mr==null?Zt(cr):typeof mr=="function"?mr.apply(_r,Tr):mr,ir=Math.max(cr[1][0]-cr[0][0],cr[1][1]-cr[0][1]),or=_r.__zoom,hr=typeof vr=="function"?vr.apply(_r,Tr):vr,Sr=ot(or.invert(yr).concat(ir/or.k),hr.invert(yr).concat(ir/hr.k));return function(wr){if(wr===1)wr=hr;else{var Ir=Sr(wr),kr=ir/Ir[2];wr=new Transform(kr,yr[0]-Ir[0]*kr,yr[1]-Ir[1]*kr)}ur.zoom(null,wr)}})}function Qt(dr,vr,mr){return!mr&&dr.__zooming||new er(dr,vr)}function er(dr,vr){this.that=dr,this.args=vr,this.active=0,this.sourceEvent=null,this.extent=t.apply(dr,vr),this.taps=0}er.prototype={event:function(dr){return dr&&(this.sourceEvent=dr),this},start:function(){return++this.active===1&&(this.that.__zooming=this,this.emit("start")),this},zoom:function(dr,vr){return this.mouse&&dr!=="mouse"&&(this.mouse[1]=vr.invert(this.mouse[0])),this.touch0&&dr!=="touch"&&(this.touch0[1]=vr.invert(this.touch0[0])),this.touch1&&dr!=="touch"&&(this.touch1[1]=vr.invert(this.touch1[0])),this.that.__zoom=vr,this.emit("zoom"),this},end:function(){return--this.active===0&&(delete this.that.__zooming,this.emit("end")),this},emit:function(dr){var vr=select(this.that).datum();ct.call(dr,this.that,new ZoomEvent(dr,{sourceEvent:this.sourceEvent,target:Yt,transform:this.that.__zoom,dispatch:ct}),vr)}};function nr(dr,...vr){if(!e.apply(this,arguments))return;var mr=Qt(this,vr).event(dr),Er=this.__zoom,_r=Math.max(nt[0],Math.min(nt[1],Er.k*Math.pow(2,tt.apply(this,arguments)))),Tr=pointer(dr);if(mr.wheel)(mr.mouse[0][0]!==Tr[0]||mr.mouse[0][1]!==Tr[1])&&(mr.mouse[1]=Er.invert(mr.mouse[0]=Tr)),clearTimeout(mr.wheel);else{if(Er.k===_r)return;mr.mouse=[Tr,Er.invert(Tr)],interrupt(this),mr.start()}noevent(dr),mr.wheel=setTimeout(ur,Ut),mr.zoom("mouse",Ye(Vt(Gt(Er,_r),mr.mouse[0],mr.mouse[1]),mr.extent,at));function ur(){mr.wheel=null,mr.end()}}function ar(dr,...vr){if(qt||!e.apply(this,arguments))return;var mr=dr.currentTarget,Er=Qt(this,vr,!0).event(dr),_r=select(dr.view).on("mousemove.zoom",yr,!0).on("mouseup.zoom",ir,!0),Tr=pointer(dr,mr),ur=dr.clientX,cr=dr.clientY;dragDisable(dr.view),nopropagation(dr),Er.mouse=[Tr,this.__zoom.invert(Tr)],interrupt(this),Er.start();function yr(or){if(noevent(or),!Er.moved){var hr=or.clientX-ur,Sr=or.clientY-cr;Er.moved=hr*hr+Sr*Sr>Ht}Er.event(or).zoom("mouse",Ye(Vt(Er.that.__zoom,Er.mouse[0]=pointer(or,mr),Er.mouse[1]),Er.extent,at))}function ir(or){_r.on("mousemove.zoom mouseup.zoom",null),yesdrag(or.view,Er.moved),noevent(or),Er.event(or).end()}}function sr(dr,...vr){if(e.apply(this,arguments)){var mr=this.__zoom,Er=pointer(dr.changedTouches?dr.changedTouches[0]:dr,this),_r=mr.invert(Er),Tr=mr.k*(dr.shiftKey?.5:2),ur=Ye(Vt(Gt(mr,Tr),Er,_r),t.apply(this,vr),at);noevent(dr),it>0?select(this).transition().duration(it).call(Xt,ur,Er,dr):select(this).call(Yt.transform,ur,Er,dr)}}function lr(dr,...vr){if(e.apply(this,arguments)){var mr=dr.touches,Er=mr.length,_r=Qt(this,vr,dr.changedTouches.length===Er).event(dr),Tr,ur,cr,yr;for(nopropagation(dr),ur=0;ur<Er;++ur)cr=mr[ur],yr=pointer(cr,this),yr=[yr,this.__zoom.invert(yr),cr.identifier],_r.touch0?!_r.touch1&&_r.touch0[2]!==yr[2]&&(_r.touch1=yr,_r.taps=0):(_r.touch0=yr,Tr=!0,_r.taps=1+!!At);At&&(At=clearTimeout(At)),Tr&&(_r.taps<2&&(Rt=yr[0],At=setTimeout(function(){At=null},Ft)),interrupt(this),_r.start())}}function fr(dr,...vr){if(this.__zooming){var mr=Qt(this,vr).event(dr),Er=dr.changedTouches,_r=Er.length,Tr,ur,cr,yr;for(noevent(dr),Tr=0;Tr<_r;++Tr)ur=Er[Tr],cr=pointer(ur,this),mr.touch0&&mr.touch0[2]===ur.identifier?mr.touch0[0]=cr:mr.touch1&&mr.touch1[2]===ur.identifier&&(mr.touch1[0]=cr);if(ur=mr.that.__zoom,mr.touch1){var ir=mr.touch0[0],or=mr.touch0[1],hr=mr.touch1[0],Sr=mr.touch1[1],wr=(wr=hr[0]-ir[0])*wr+(wr=hr[1]-ir[1])*wr,Ir=(Ir=Sr[0]-or[0])*Ir+(Ir=Sr[1]-or[1])*Ir;ur=Gt(ur,Math.sqrt(wr/Ir)),cr=[(ir[0]+hr[0])/2,(ir[1]+hr[1])/2],yr=[(or[0]+Sr[0])/2,(or[1]+Sr[1])/2]}else if(mr.touch0)cr=mr.touch0[0],yr=mr.touch0[1];else return;mr.zoom("touch",Ye(Vt(ur,cr,yr),mr.extent,at))}}function gr(dr,...vr){if(this.__zooming){var mr=Qt(this,vr).event(dr),Er=dr.changedTouches,_r=Er.length,Tr,ur;for(nopropagation(dr),qt&&clearTimeout(qt),qt=setTimeout(function(){qt=null},Ft),Tr=0;Tr<_r;++Tr)ur=Er[Tr],mr.touch0&&mr.touch0[2]===ur.identifier?delete mr.touch0:mr.touch1&&mr.touch1[2]===ur.identifier&&delete mr.touch1;if(mr.touch1&&!mr.touch0&&(mr.touch0=mr.touch1,delete mr.touch1),mr.touch0)mr.touch0[1]=this.__zoom.invert(mr.touch0[0]);else if(mr.end(),mr.taps===2&&(ur=pointer(ur,this),Math.hypot(Rt[0]-ur[0],Rt[1]-ur[1])<zt)){var cr=select(this).on("dblclick.zoom");cr&&cr.apply(this,arguments)}}}return Yt.wheelDelta=function(dr){return arguments.length?(tt=typeof dr=="function"?dr:constant$1(+dr),Yt):tt},Yt.filter=function(dr){return arguments.length?(e=typeof dr=="function"?dr:constant$1(!!dr),Yt):e},Yt.touchable=function(dr){return arguments.length?(rt=typeof dr=="function"?dr:constant$1(!!dr),Yt):rt},Yt.extent=function(dr){return arguments.length?(t=typeof dr=="function"?dr:constant$1([[+dr[0][0],+dr[0][1]],[+dr[1][0],+dr[1][1]]]),Yt):t},Yt.scaleExtent=function(dr){return arguments.length?(nt[0]=+dr[0],nt[1]=+dr[1],Yt):[nt[0],nt[1]]},Yt.translateExtent=function(dr){return arguments.length?(at[0][0]=+dr[0][0],at[1][0]=+dr[1][0],at[0][1]=+dr[0][1],at[1][1]=+dr[1][1],Yt):[[at[0][0],at[0][1]],[at[1][0],at[1][1]]]},Yt.constrain=function(dr){return arguments.length?(Ye=dr,Yt):Ye},Yt.duration=function(dr){return arguments.length?(it=+dr,Yt):it},Yt.interpolate=function(dr){return arguments.length?(ot=dr,Yt):ot},Yt.on=function(){var dr=ct.on.apply(ct,arguments);return dr===ct?Yt:dr},Yt.clickDistance=function(dr){return arguments.length?(Ht=(dr=+dr)*dr,Yt):Math.sqrt(Ht)},Yt.tapDistance=function(dr){return arguments.length?(zt=+dr,Yt):zt},Yt}const errorMessages={error001:()=>"[React Flow]: Seems like you have not used zustand provider as an ancestor. Help: https://reactflow.dev/error#001",error002:()=>"It looks like you've created a new nodeTypes or edgeTypes object. If this wasn't on purpose please define the nodeTypes/edgeTypes outside of the component or memoize them.",error003:e=>`Node type "${e}" not found. Using fallback type "default".`,error004:()=>"The React Flow parent container needs a width and a height to render the graph.",error005:()=>"Only child nodes can use a parent extent.",error006:()=>"Can't create edge. An edge needs a source and a target.",error007:e=>`The old edge with id=${e} does not exist.`,error009:e=>`Marker type "${e}" doesn't exist.`,error008:(e,{id:t,sourceHandle:Ye,targetHandle:tt})=>`Couldn't create edge for ${e} handle id: "${e==="source"?Ye:tt}", edge id: ${t}.`,error010:()=>"Handle: No node id found. Make sure to only use a Handle inside a custom Node.",error011:e=>`Edge type "${e}" not found. Using fallback type "default".`,error012:e=>`Node with id "${e}" does not exist, it may have been removed. This can happen when a node is deleted before the "onNodeClick" handler is called.`,error013:(e="react")=>`It seems that you haven't loaded the styles. Please import '@xyflow/${e}/dist/style.css' or base.css to make sure everything is working properly.`,error014:()=>"useNodeConnections: No node ID found. Call useNodeConnections inside a custom Node or provide a node ID.",error015:()=>"It seems that you are trying to drag a node that is not initialized. Please use onNodesChange as explained in the docs."},infiniteExtent=[[Number.NEGATIVE_INFINITY,Number.NEGATIVE_INFINITY],[Number.POSITIVE_INFINITY,Number.POSITIVE_INFINITY]],elementSelectionKeys=["Enter"," ","Escape"];var ConnectionMode;(function(e){e.Strict="strict",e.Loose="loose"})(ConnectionMode||(ConnectionMode={}));var PanOnScrollMode;(function(e){e.Free="free",e.Vertical="vertical",e.Horizontal="horizontal"})(PanOnScrollMode||(PanOnScrollMode={}));var SelectionMode;(function(e){e.Partial="partial",e.Full="full"})(SelectionMode||(SelectionMode={}));const initialConnection={inProgress:!1,isValid:null,from:null,fromHandle:null,fromPosition:null,fromNode:null,to:null,toHandle:null,toPosition:null,toNode:null};var ConnectionLineType;(function(e){e.Bezier="default",e.Straight="straight",e.Step="step",e.SmoothStep="smoothstep",e.SimpleBezier="simplebezier"})(ConnectionLineType||(ConnectionLineType={}));var MarkerType;(function(e){e.Arrow="arrow",e.ArrowClosed="arrowclosed"})(MarkerType||(MarkerType={}));var Position;(function(e){e.Left="left",e.Top="top",e.Right="right",e.Bottom="bottom"})(Position||(Position={}));const oppositePosition={[Position.Left]:Position.Right,[Position.Right]:Position.Left,[Position.Top]:Position.Bottom,[Position.Bottom]:Position.Top};function getConnectionStatus(e){return e===null?null:e?"valid":"invalid"}const isEdgeBase=e=>"id"in e&&"source"in e&&"target"in e,isNodeBase=e=>"id"in e&&"position"in e&&!("source"in e)&&!("target"in e),isInternalNodeBase=e=>"id"in e&&"internals"in e&&!("source"in e)&&!("target"in e),getNodePositionWithOrigin=(e,t=[0,0])=>{const{width:Ye,height:tt}=getNodeDimensions(e),rt=e.origin??t,nt=Ye*rt[0],at=tt*rt[1];return{x:e.position.x-nt,y:e.position.y-at}},getNodesBounds=(e,t={nodeOrigin:[0,0]})=>{if(e.length===0)return{x:0,y:0,width:0,height:0};const Ye=e.reduce((tt,rt)=>{const nt=typeof rt=="string";let at=!t.nodeLookup&&!nt?rt:void 0;t.nodeLookup&&(at=nt?t.nodeLookup.get(rt):isInternalNodeBase(rt)?rt:t.nodeLookup.get(rt.id));const it=at?nodeToBox(at,t.nodeOrigin):{x:0,y:0,x2:0,y2:0};return getBoundsOfBoxes(tt,it)},{x:1/0,y:1/0,x2:-1/0,y2:-1/0});return boxToRect(Ye)},getInternalNodesBounds=(e,t={})=>{if(e.size===0)return{x:0,y:0,width:0,height:0};let Ye={x:1/0,y:1/0,x2:-1/0,y2:-1/0};return e.forEach(tt=>{if(t.filter===void 0||t.filter(tt)){const rt=nodeToBox(tt);Ye=getBoundsOfBoxes(Ye,rt)}}),boxToRect(Ye)},getNodesInside=(e,t,[Ye,tt,rt]=[0,0,1],nt=!1,at=!1)=>{const it={...pointToRendererPoint(t,[Ye,tt,rt]),width:t.width/rt,height:t.height/rt},ot=[];for(const ct of e.values()){const{measured:At,selectable:Rt=!0,hidden:qt=!1}=ct;if(at&&!Rt||qt)continue;const Ft=At.width??ct.width??ct.initialWidth??null,Ut=At.height??ct.height??ct.initialHeight??null,Ht=getOverlappingArea(it,nodeToRect(ct)),zt=(Ft??0)*(Ut??0),Yt=nt&&Ht>0;(!ct.internals.handleBounds||Yt||Ht>=zt||ct.dragging)&&ot.push(ct)}return ot},getConnectedEdges=(e,t)=>{const Ye=new Set;return e.forEach(tt=>{Ye.add(tt.id)}),t.filter(tt=>Ye.has(tt.source)||Ye.has(tt.target))};function getFitViewNodes(e,t){const Ye=new Map,tt=t!=null&&t.nodes?new Set(t.nodes.map(rt=>rt.id)):null;return e.forEach(rt=>{rt.measured.width&&rt.measured.height&&((t==null?void 0:t.includeHiddenNodes)||!rt.hidden)&&(!tt||tt.has(rt.id))&&Ye.set(rt.id,rt)}),Ye}async function fitViewport({nodes:e,width:t,height:Ye,panZoom:tt,minZoom:rt,maxZoom:nt},at){if(e.size===0)return Promise.resolve(!0);const it=getFitViewNodes(e,at),ot=getInternalNodesBounds(it),ct=getViewportForBounds(ot,t,Ye,(at==null?void 0:at.minZoom)??rt,(at==null?void 0:at.maxZoom)??nt,(at==null?void 0:at.padding)??.1);return await tt.setViewport(ct,{duration:at==null?void 0:at.duration}),Promise.resolve(!0)}function calculateNodePosition({nodeId:e,nextPosition:t,nodeLookup:Ye,nodeOrigin:tt=[0,0],nodeExtent:rt,onError:nt}){const at=Ye.get(e),it=at.parentId?Ye.get(at.parentId):void 0,{x:ot,y:ct}=it?it.internals.positionAbsolute:{x:0,y:0},At=at.origin??tt;let Rt=rt;if(at.extent==="parent"&&!at.expandParent)if(!it)nt==null||nt("005",errorMessages.error005());else{const Ft=it.measured.width,Ut=it.measured.height;Ft&&Ut&&(Rt=[[ot,ct],[ot+Ft,ct+Ut]])}else it&&isCoordinateExtent(at.extent)&&(Rt=[[at.extent[0][0]+ot,at.extent[0][1]+ct],[at.extent[1][0]+ot,at.extent[1][1]+ct]]);const qt=isCoordinateExtent(Rt)?clampPosition(t,Rt,at.measured):t;return(at.measured.width===void 0||at.measured.height===void 0)&&(nt==null||nt("015",errorMessages.error015())),{position:{x:qt.x-ot+(at.measured.width??0)*At[0],y:qt.y-ct+(at.measured.height??0)*At[1]},positionAbsolute:qt}}async function getElementsToRemove({nodesToRemove:e=[],edgesToRemove:t=[],nodes:Ye,edges:tt,onBeforeDelete:rt}){const nt=new Set(e.map(qt=>qt.id)),at=[];for(const qt of Ye){if(qt.deletable===!1)continue;const Ft=nt.has(qt.id),Ut=!Ft&&qt.parentId&&at.find(Ht=>Ht.id===qt.parentId);(Ft||Ut)&&at.push(qt)}const it=new Set(t.map(qt=>qt.id)),ot=tt.filter(qt=>qt.deletable!==!1),At=getConnectedEdges(at,ot);for(const qt of ot)it.has(qt.id)&&!At.find(Ut=>Ut.id===qt.id)&&At.push(qt);if(!rt)return{edges:At,nodes:at};const Rt=await rt({nodes:at,edges:At});return typeof Rt=="boolean"?Rt?{edges:At,nodes:at}:{edges:[],nodes:[]}:Rt}const clamp=(e,t=0,Ye=1)=>Math.min(Math.max(e,t),Ye),clampPosition=(e={x:0,y:0},t,Ye)=>({x:clamp(e.x,t[0][0],t[1][0]-((Ye==null?void 0:Ye.width)??0)),y:clamp(e.y,t[0][1],t[1][1]-((Ye==null?void 0:Ye.height)??0))});function clampPositionToParent(e,t,Ye){const{width:tt,height:rt}=getNodeDimensions(Ye),{x:nt,y:at}=Ye.internals.positionAbsolute;return clampPosition(e,[[nt,at],[nt+tt,at+rt]],t)}const calcAutoPanVelocity=(e,t,Ye)=>e<t?clamp(Math.abs(e-t),1,t)/t:e>Ye?-clamp(Math.abs(e-Ye),1,t)/t:0,calcAutoPan=(e,t,Ye=15,tt=40)=>{const rt=calcAutoPanVelocity(e.x,tt,t.width-tt)*Ye,nt=calcAutoPanVelocity(e.y,tt,t.height-tt)*Ye;return[rt,nt]},getBoundsOfBoxes=(e,t)=>({x:Math.min(e.x,t.x),y:Math.min(e.y,t.y),x2:Math.max(e.x2,t.x2),y2:Math.max(e.y2,t.y2)}),rectToBox=({x:e,y:t,width:Ye,height:tt})=>({x:e,y:t,x2:e+Ye,y2:t+tt}),boxToRect=({x:e,y:t,x2:Ye,y2:tt})=>({x:e,y:t,width:Ye-e,height:tt-t}),nodeToRect=(e,t=[0,0])=>{var rt,nt;const{x:Ye,y:tt}=isInternalNodeBase(e)?e.internals.positionAbsolute:getNodePositionWithOrigin(e,t);return{x:Ye,y:tt,width:((rt=e.measured)==null?void 0:rt.width)??e.width??e.initialWidth??0,height:((nt=e.measured)==null?void 0:nt.height)??e.height??e.initialHeight??0}},nodeToBox=(e,t=[0,0])=>{var rt,nt;const{x:Ye,y:tt}=isInternalNodeBase(e)?e.internals.positionAbsolute:getNodePositionWithOrigin(e,t);return{x:Ye,y:tt,x2:Ye+(((rt=e.measured)==null?void 0:rt.width)??e.width??e.initialWidth??0),y2:tt+(((nt=e.measured)==null?void 0:nt.height)??e.height??e.initialHeight??0)}},getBoundsOfRects=(e,t)=>boxToRect(getBoundsOfBoxes(rectToBox(e),rectToBox(t))),getOverlappingArea=(e,t)=>{const Ye=Math.max(0,Math.min(e.x+e.width,t.x+t.width)-Math.max(e.x,t.x)),tt=Math.max(0,Math.min(e.y+e.height,t.y+t.height)-Math.max(e.y,t.y));return Math.ceil(Ye*tt)},isRectObject=e=>isNumeric(e.width)&&isNumeric(e.height)&&isNumeric(e.x)&&isNumeric(e.y),isNumeric=e=>!isNaN(e)&&isFinite(e),devWarn=(e,t)=>{},snapPosition=(e,t=[1,1])=>({x:t[0]*Math.round(e.x/t[0]),y:t[1]*Math.round(e.y/t[1])}),pointToRendererPoint=({x:e,y:t},[Ye,tt,rt],nt=!1,at=[1,1])=>{const it={x:(e-Ye)/rt,y:(t-tt)/rt};return nt?snapPosition(it,at):it},rendererPointToPoint=({x:e,y:t},[Ye,tt,rt])=>({x:e*rt+Ye,y:t*rt+tt});function parsePadding(e,t){if(typeof e=="number")return Math.floor((t-t/(1+e))*.5);if(typeof e=="string"&&e.endsWith("px")){const Ye=parseFloat(e);if(!Number.isNaN(Ye))return Math.floor(Ye)}if(typeof e=="string"&&e.endsWith("%")){const Ye=parseFloat(e);if(!Number.isNaN(Ye))return Math.floor(t*Ye*.01)}return console.error(`[React Flow] The padding value "${e}" is invalid. Please provide a number or a string with a valid unit (px or %).`),0}function parsePaddings(e,t,Ye){if(typeof e=="string"||typeof e=="number"){const tt=parsePadding(e,Ye),rt=parsePadding(e,t);return{top:tt,right:rt,bottom:tt,left:rt,x:rt*2,y:tt*2}}if(typeof e=="object"){const tt=parsePadding(e.top??e.y??0,Ye),rt=parsePadding(e.bottom??e.y??0,Ye),nt=parsePadding(e.left??e.x??0,t),at=parsePadding(e.right??e.x??0,t);return{top:tt,right:at,bottom:rt,left:nt,x:nt+at,y:tt+rt}}return{top:0,right:0,bottom:0,left:0,x:0,y:0}}function calculateAppliedPaddings(e,t,Ye,tt,rt,nt){const{x:at,y:it}=rendererPointToPoint(e,[t,Ye,tt]),{x:ot,y:ct}=rendererPointToPoint({x:e.x+e.width,y:e.y+e.height},[t,Ye,tt]),At=rt-ot,Rt=nt-ct;return{left:Math.floor(at),top:Math.floor(it),right:Math.floor(At),bottom:Math.floor(Rt)}}const getViewportForBounds=(e,t,Ye,tt,rt,nt)=>{const at=parsePaddings(nt,t,Ye),it=(t-at.x)/e.width,ot=(Ye-at.y)/e.height,ct=Math.min(it,ot),At=clamp(ct,tt,rt),Rt=e.x+e.width/2,qt=e.y+e.height/2,Ft=t/2-Rt*At,Ut=Ye/2-qt*At,Ht=calculateAppliedPaddings(e,Ft,Ut,At,t,Ye),zt={left:Math.min(Ht.left-at.left,0),top:Math.min(Ht.top-at.top,0),right:Math.min(Ht.right-at.right,0),bottom:Math.min(Ht.bottom-at.bottom,0)};return{x:Ft-zt.left+zt.right,y:Ut-zt.top+zt.bottom,zoom:At}},isMacOs=()=>{var e;return typeof navigator<"u"&&((e=navigator==null?void 0:navigator.userAgent)==null?void 0:e.indexOf("Mac"))>=0};function isCoordinateExtent(e){return e!==void 0&&e!=="parent"}function getNodeDimensions(e){var t,Ye;return{width:((t=e.measured)==null?void 0:t.width)??e.width??e.initialWidth??0,height:((Ye=e.measured)==null?void 0:Ye.height)??e.height??e.initialHeight??0}}function nodeHasDimensions(e){var t,Ye;return(((t=e.measured)==null?void 0:t.width)??e.width??e.initialWidth)!==void 0&&(((Ye=e.measured)==null?void 0:Ye.height)??e.height??e.initialHeight)!==void 0}function evaluateAbsolutePosition(e,t={width:0,height:0},Ye,tt,rt){const nt={...e},at=tt.get(Ye);if(at){const it=at.origin||rt;nt.x+=at.internals.positionAbsolute.x-(t.width??0)*it[0],nt.y+=at.internals.positionAbsolute.y-(t.height??0)*it[1]}return nt}function areSetsEqual(e,t){if(e.size!==t.size)return!1;for(const Ye of e)if(!t.has(Ye))return!1;return!0}function withResolvers(){let e,t;return{promise:new Promise((tt,rt)=>{e=tt,t=rt}),resolve:e,reject:t}}function getPointerPosition(e,{snapGrid:t=[0,0],snapToGrid:Ye=!1,transform:tt,containerBounds:rt}){const{x:nt,y:at}=getEventPosition(e),it=pointToRendererPoint({x:nt-((rt==null?void 0:rt.left)??0),y:at-((rt==null?void 0:rt.top)??0)},tt),{x:ot,y:ct}=Ye?snapPosition(it,t):it;return{xSnapped:ot,ySnapped:ct,...it}}const getDimensions=e=>({width:e.offsetWidth,height:e.offsetHeight}),getHostForElement=e=>{var t;return((t=e==null?void 0:e.getRootNode)==null?void 0:t.call(e))||(window==null?void 0:window.document)},inputTags=["INPUT","SELECT","TEXTAREA"];function isInputDOMNode(e){var tt,rt;const t=((rt=(tt=e.composedPath)==null?void 0:tt.call(e))==null?void 0:rt[0])||e.target;return(t==null?void 0:t.nodeType)!==1?!1:inputTags.includes(t.nodeName)||t.hasAttribute("contenteditable")||!!t.closest(".nokey")}const isMouseEvent=e=>"clientX"in e,getEventPosition=(e,t)=>{var nt,at;const Ye=isMouseEvent(e),tt=Ye?e.clientX:(nt=e.touches)==null?void 0:nt[0].clientX,rt=Ye?e.clientY:(at=e.touches)==null?void 0:at[0].clientY;return{x:tt-((t==null?void 0:t.left)??0),y:rt-((t==null?void 0:t.top)??0)}},getHandleBounds=(e,t,Ye,tt,rt)=>{const nt=t.querySelectorAll(`.${e}`);return!nt||!nt.length?null:Array.from(nt).map(at=>{const it=at.getBoundingClientRect();return{id:at.getAttribute("data-handleid"),type:e,nodeId:rt,position:at.getAttribute("data-handlepos"),x:(it.left-Ye.left)/tt,y:(it.top-Ye.top)/tt,...getDimensions(at)}})};function getBezierEdgeCenter({sourceX:e,sourceY:t,targetX:Ye,targetY:tt,sourceControlX:rt,sourceControlY:nt,targetControlX:at,targetControlY:it}){const ot=e*.125+rt*.375+at*.375+Ye*.125,ct=t*.125+nt*.375+it*.375+tt*.125,At=Math.abs(ot-e),Rt=Math.abs(ct-t);return[ot,ct,At,Rt]}function calculateControlOffset(e,t){return e>=0?.5*e:t*25*Math.sqrt(-e)}function getControlWithCurvature({pos:e,x1:t,y1:Ye,x2:tt,y2:rt,c:nt}){switch(e){case Position.Left:return[t-calculateControlOffset(t-tt,nt),Ye];case Position.Right:return[t+calculateControlOffset(tt-t,nt),Ye];case Position.Top:return[t,Ye-calculateControlOffset(Ye-rt,nt)];case Position.Bottom:return[t,Ye+calculateControlOffset(rt-Ye,nt)]}}function getBezierPath({sourceX:e,sourceY:t,sourcePosition:Ye=Position.Bottom,targetX:tt,targetY:rt,targetPosition:nt=Position.Top,curvature:at=.25}){const[it,ot]=getControlWithCurvature({pos:Ye,x1:e,y1:t,x2:tt,y2:rt,c:at}),[ct,At]=getControlWithCurvature({pos:nt,x1:tt,y1:rt,x2:e,y2:t,c:at}),[Rt,qt,Ft,Ut]=getBezierEdgeCenter({sourceX:e,sourceY:t,targetX:tt,targetY:rt,sourceControlX:it,sourceControlY:ot,targetControlX:ct,targetControlY:At});return[`M${e},${t} C${it},${ot} ${ct},${At} ${tt},${rt}`,Rt,qt,Ft,Ut]}function getEdgeCenter({sourceX:e,sourceY:t,targetX:Ye,targetY:tt}){const rt=Math.abs(Ye-e)/2,nt=Ye<e?Ye+rt:Ye-rt,at=Math.abs(tt-t)/2,it=tt<t?tt+at:tt-at;return[nt,it,rt,at]}function getElevatedEdgeZIndex({sourceNode:e,targetNode:t,selected:Ye=!1,zIndex:tt=0,elevateOnSelect:rt=!1}){if(!rt)return tt;const nt=Ye||t.selected||e.selected,at=Math.max(e.internals.z||0,t.internals.z||0,1e3);return tt+(nt?at:0)}function isEdgeVisible({sourceNode:e,targetNode:t,width:Ye,height:tt,transform:rt}){const nt=getBoundsOfBoxes(nodeToBox(e),nodeToBox(t));nt.x===nt.x2&&(nt.x2+=1),nt.y===nt.y2&&(nt.y2+=1);const at={x:-rt[0]/rt[2],y:-rt[1]/rt[2],width:Ye/rt[2],height:tt/rt[2]};return getOverlappingArea(at,boxToRect(nt))>0}const getEdgeId=({source:e,sourceHandle:t,target:Ye,targetHandle:tt})=>`xy-edge__${e}${t||""}-${Ye}${tt||""}`,connectionExists=(e,t)=>t.some(Ye=>Ye.source===e.source&&Ye.target===e.target&&(Ye.sourceHandle===e.sourceHandle||!Ye.sourceHandle&&!e.sourceHandle)&&(Ye.targetHandle===e.targetHandle||!Ye.targetHandle&&!e.targetHandle)),addEdge=(e,t)=>{if(!e.source||!e.target)return t;let Ye;return isEdgeBase(e)?Ye={...e}:Ye={...e,id:getEdgeId(e)},connectionExists(Ye,t)?t:(Ye.sourceHandle===null&&delete Ye.sourceHandle,Ye.targetHandle===null&&delete Ye.targetHandle,t.concat(Ye))};function getStraightPath({sourceX:e,sourceY:t,targetX:Ye,targetY:tt}){const[rt,nt,at,it]=getEdgeCenter({sourceX:e,sourceY:t,targetX:Ye,targetY:tt});return[`M ${e},${t}L ${Ye},${tt}`,rt,nt,at,it]}const handleDirections={[Position.Left]:{x:-1,y:0},[Position.Right]:{x:1,y:0},[Position.Top]:{x:0,y:-1},[Position.Bottom]:{x:0,y:1}},getDirection=({source:e,sourcePosition:t=Position.Bottom,target:Ye})=>t===Position.Left||t===Position.Right?e.x<Ye.x?{x:1,y:0}:{x:-1,y:0}:e.y<Ye.y?{x:0,y:1}:{x:0,y:-1},distance=(e,t)=>Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2));function getPoints({source:e,sourcePosition:t=Position.Bottom,target:Ye,targetPosition:tt=Position.Top,center:rt,offset:nt}){const at=handleDirections[t],it=handleDirections[tt],ot={x:e.x+at.x*nt,y:e.y+at.y*nt},ct={x:Ye.x+it.x*nt,y:Ye.y+it.y*nt},At=getDirection({source:ot,sourcePosition:t,target:ct}),Rt=At.x!==0?"x":"y",qt=At[Rt];let Ft=[],Ut,Ht;const zt={x:0,y:0},Yt={x:0,y:0},[Gt,Vt,Zt,Xt]=getEdgeCenter({sourceX:e.x,sourceY:e.y,targetX:Ye.x,targetY:Ye.y});if(at[Rt]*it[Rt]===-1){Ut=rt.x??Gt,Ht=rt.y??Vt;const er=[{x:Ut,y:ot.y},{x:Ut,y:ct.y}],nr=[{x:ot.x,y:Ht},{x:ct.x,y:Ht}];at[Rt]===qt?Ft=Rt==="x"?er:nr:Ft=Rt==="x"?nr:er}else{const er=[{x:ot.x,y:ct.y}],nr=[{x:ct.x,y:ot.y}];if(Rt==="x"?Ft=at.x===qt?nr:er:Ft=at.y===qt?er:nr,t===tt){const gr=Math.abs(e[Rt]-Ye[Rt]);if(gr<=nt){const dr=Math.min(nt-1,nt-gr);at[Rt]===qt?zt[Rt]=(ot[Rt]>e[Rt]?-1:1)*dr:Yt[Rt]=(ct[Rt]>Ye[Rt]?-1:1)*dr}}if(t!==tt){const gr=Rt==="x"?"y":"x",dr=at[Rt]===it[gr],vr=ot[gr]>ct[gr],mr=ot[gr]<ct[gr];(at[Rt]===1&&(!dr&&vr||dr&&mr)||at[Rt]!==1&&(!dr&&mr||dr&&vr))&&(Ft=Rt==="x"?er:nr)}const ar={x:ot.x+zt.x,y:ot.y+zt.y},sr={x:ct.x+Yt.x,y:ct.y+Yt.y},lr=Math.max(Math.abs(ar.x-Ft[0].x),Math.abs(sr.x-Ft[0].x)),fr=Math.max(Math.abs(ar.y-Ft[0].y),Math.abs(sr.y-Ft[0].y));lr>=fr?(Ut=(ar.x+sr.x)/2,Ht=Ft[0].y):(Ut=Ft[0].x,Ht=(ar.y+sr.y)/2)}return[[e,{x:ot.x+zt.x,y:ot.y+zt.y},...Ft,{x:ct.x+Yt.x,y:ct.y+Yt.y},Ye],Ut,Ht,Zt,Xt]}function getBend(e,t,Ye,tt){const rt=Math.min(distance(e,t)/2,distance(t,Ye)/2,tt),{x:nt,y:at}=t;if(e.x===nt&&nt===Ye.x||e.y===at&&at===Ye.y)return`L${nt} ${at}`;if(e.y===at){const ct=e.x<Ye.x?-1:1,At=e.y<Ye.y?1:-1;return`L ${nt+rt*ct},${at}Q ${nt},${at} ${nt},${at+rt*At}`}const it=e.x<Ye.x?1:-1,ot=e.y<Ye.y?-1:1;return`L ${nt},${at+rt*ot}Q ${nt},${at} ${nt+rt*it},${at}`}function getSmoothStepPath({sourceX:e,sourceY:t,sourcePosition:Ye=Position.Bottom,targetX:tt,targetY:rt,targetPosition:nt=Position.Top,borderRadius:at=5,centerX:it,centerY:ot,offset:ct=20}){const[At,Rt,qt,Ft,Ut]=getPoints({source:{x:e,y:t},sourcePosition:Ye,target:{x:tt,y:rt},targetPosition:nt,center:{x:it,y:ot},offset:ct});return[At.reduce((zt,Yt,Gt)=>{let Vt="";return Gt>0&&Gt<At.length-1?Vt=getBend(At[Gt-1],Yt,At[Gt+1],at):Vt=`${Gt===0?"M":"L"}${Yt.x} ${Yt.y}`,zt+=Vt,zt},""),Rt,qt,Ft,Ut]}function isNodeInitialized(e){var t;return e&&!!(e.internals.handleBounds||(t=e.handles)!=null&&t.length)&&!!(e.measured.width||e.width||e.initialWidth)}function getEdgePosition(e){var Rt;const{sourceNode:t,targetNode:Ye}=e;if(!isNodeInitialized(t)||!isNodeInitialized(Ye))return null;const tt=t.internals.handleBounds||toHandleBounds(t.handles),rt=Ye.internals.handleBounds||toHandleBounds(Ye.handles),nt=getHandle$1((tt==null?void 0:tt.source)??[],e.sourceHandle),at=getHandle$1(e.connectionMode===ConnectionMode.Strict?(rt==null?void 0:rt.target)??[]:((rt==null?void 0:rt.target)??[]).concat((rt==null?void 0:rt.source)??[]),e.targetHandle);if(!nt||!at)return(Rt=e.onError)==null||Rt.call(e,"008",errorMessages.error008(nt?"target":"source",{id:e.id,sourceHandle:e.sourceHandle,targetHandle:e.targetHandle})),null;const it=(nt==null?void 0:nt.position)||Position.Bottom,ot=(at==null?void 0:at.position)||Position.Top,ct=getHandlePosition(t,nt,it),At=getHandlePosition(Ye,at,ot);return{sourceX:ct.x,sourceY:ct.y,targetX:At.x,targetY:At.y,sourcePosition:it,targetPosition:ot}}function toHandleBounds(e){if(!e)return null;const t=[],Ye=[];for(const tt of e)tt.width=tt.width??1,tt.height=tt.height??1,tt.type==="source"?t.push(tt):tt.type==="target"&&Ye.push(tt);return{source:t,target:Ye}}function getHandlePosition(e,t,Ye=Position.Left,tt=!1){const rt=((t==null?void 0:t.x)??0)+e.internals.positionAbsolute.x,nt=((t==null?void 0:t.y)??0)+e.internals.positionAbsolute.y,{width:at,height:it}=t??getNodeDimensions(e);if(tt)return{x:rt+at/2,y:nt+it/2};switch((t==null?void 0:t.position)??Ye){case Position.Top:return{x:rt+at/2,y:nt};case Position.Right:return{x:rt+at,y:nt+it/2};case Position.Bottom:return{x:rt+at/2,y:nt+it};case Position.Left:return{x:rt,y:nt+it/2}}}function getHandle$1(e,t){return e&&(t?e.find(Ye=>Ye.id===t):e[0])||null}function getMarkerId(e,t){return e?typeof e=="string"?e:`${t?`${t}__`:""}${Object.keys(e).sort().map(tt=>`${tt}=${e[tt]}`).join("&")}`:""}function createMarkerIds(e,{id:t,defaultColor:Ye,defaultMarkerStart:tt,defaultMarkerEnd:rt}){const nt=new Set;return e.reduce((at,it)=>([it.markerStart||tt,it.markerEnd||rt].forEach(ot=>{if(ot&&typeof ot=="object"){const ct=getMarkerId(ot,t);nt.has(ct)||(at.push({id:ct,color:ot.color||Ye,...ot}),nt.add(ct))}}),at),[]).sort((at,it)=>at.id.localeCompare(it.id))}const defaultOptions={nodeOrigin:[0,0],nodeExtent:infiniteExtent,elevateNodesOnSelect:!0,defaults:{}},adoptUserNodesDefaultOptions={...defaultOptions,checkEquality:!0};function mergeObjects$1(e,t){const Ye={...e};for(const tt in t)t[tt]!==void 0&&(Ye[tt]=t[tt]);return Ye}function updateAbsolutePositions(e,t,Ye){const tt=mergeObjects$1(defaultOptions,Ye);for(const rt of e.values())if(rt.parentId)updateChildNode(rt,e,t,tt);else{const nt=getNodePositionWithOrigin(rt,tt.nodeOrigin),at=isCoordinateExtent(rt.extent)?rt.extent:tt.nodeExtent,it=clampPosition(nt,at,getNodeDimensions(rt));rt.internals.positionAbsolute=it}}function adoptUserNodes(e,t,Ye,tt){var ot,ct;const rt=mergeObjects$1(adoptUserNodesDefaultOptions,tt);let nt=e.length>0;const at=new Map(t),it=rt!=null&&rt.elevateNodesOnSelect?1e3:0;t.clear(),Ye.clear();for(const At of e){let Rt=at.get(At.id);if(rt.checkEquality&&At===(Rt==null?void 0:Rt.internals.userNode))t.set(At.id,Rt);else{const qt=getNodePositionWithOrigin(At,rt.nodeOrigin),Ft=isCoordinateExtent(At.extent)?At.extent:rt.nodeExtent,Ut=clampPosition(qt,Ft,getNodeDimensions(At));Rt={...rt.defaults,...At,measured:{width:(ot=At.measured)==null?void 0:ot.width,height:(ct=At.measured)==null?void 0:ct.height},internals:{positionAbsolute:Ut,handleBounds:At.measured?Rt==null?void 0:Rt.internals.handleBounds:void 0,z:calculateZ(At,it),userNode:At}},t.set(At.id,Rt)}(Rt.measured===void 0||Rt.measured.width===void 0||Rt.measured.height===void 0)&&!Rt.hidden&&(nt=!1),At.parentId&&updateChildNode(Rt,t,Ye,tt)}return nt}function updateParentLookup(e,t){if(!e.parentId)return;const Ye=t.get(e.parentId);Ye?Ye.set(e.id,e):t.set(e.parentId,new Map([[e.id,e]]))}function updateChildNode(e,t,Ye,tt){const{elevateNodesOnSelect:rt,nodeOrigin:nt,nodeExtent:at}=mergeObjects$1(defaultOptions,tt),it=e.parentId,ot=t.get(it);if(!ot){console.warn(`Parent node ${it} not found. Please make sure that parent nodes are in front of their child nodes in the nodes array.`);return}updateParentLookup(e,Ye);const ct=rt?1e3:0,{x:At,y:Rt,z:qt}=calculateChildXYZ(e,ot,nt,at,ct),{positionAbsolute:Ft}=e.internals,Ut=At!==Ft.x||Rt!==Ft.y;(Ut||qt!==e.internals.z)&&t.set(e.id,{...e,internals:{...e.internals,positionAbsolute:Ut?{x:At,y:Rt}:Ft,z:qt}})}function calculateZ(e,t){return(isNumeric(e.zIndex)?e.zIndex:0)+(e.selected?t:0)}function calculateChildXYZ(e,t,Ye,tt,rt){const{x:nt,y:at}=t.internals.positionAbsolute,it=getNodeDimensions(e),ot=getNodePositionWithOrigin(e,Ye),ct=isCoordinateExtent(e.extent)?clampPosition(ot,e.extent,it):ot;let At=clampPosition({x:nt+ct.x,y:at+ct.y},tt,it);e.extent==="parent"&&(At=clampPositionToParent(At,it,t));const Rt=calculateZ(e,rt),qt=t.internals.z??0;return{x:At.x,y:At.y,z:qt>Rt?qt:Rt}}function handleExpandParent(e,t,Ye,tt=[0,0]){var at;const rt=[],nt=new Map;for(const it of e){const ot=t.get(it.parentId);if(!ot)continue;const ct=((at=nt.get(it.parentId))==null?void 0:at.expandedRect)??nodeToRect(ot),At=getBoundsOfRects(ct,it.rect);nt.set(it.parentId,{expandedRect:At,parent:ot})}return nt.size>0&&nt.forEach(({expandedRect:it,parent:ot},ct)=>{var Vt;const At=ot.internals.positionAbsolute,Rt=getNodeDimensions(ot),qt=ot.origin??tt,Ft=it.x<At.x?Math.round(Math.abs(At.x-it.x)):0,Ut=it.y<At.y?Math.round(Math.abs(At.y-it.y)):0,Ht=Math.max(Rt.width,Math.round(it.width)),zt=Math.max(Rt.height,Math.round(it.height)),Yt=(Ht-Rt.width)*qt[0],Gt=(zt-Rt.height)*qt[1];(Ft>0||Ut>0||Yt||Gt)&&(rt.push({id:ct,type:"position",position:{x:ot.position.x-Ft+Yt,y:ot.position.y-Ut+Gt}}),(Vt=Ye.get(ct))==null||Vt.forEach(Zt=>{e.some(Xt=>Xt.id===Zt.id)||rt.push({id:Zt.id,type:"position",position:{x:Zt.position.x+Ft,y:Zt.position.y+Ut}})})),(Rt.width<it.width||Rt.height<it.height||Ft||Ut)&&rt.push({id:ct,type:"dimensions",setAttributes:!0,dimensions:{width:Ht+(Ft?qt[0]*Ft-Yt:0),height:zt+(Ut?qt[1]*Ut-Gt:0)}})}),rt}function updateNodeInternals(e,t,Ye,tt,rt,nt){const at=tt==null?void 0:tt.querySelector(".xyflow__viewport");let it=!1;if(!at)return{changes:[],updatedInternals:it};const ot=[],ct=window.getComputedStyle(at),{m22:At}=new window.DOMMatrixReadOnly(ct.transform),Rt=[];for(const qt of e.values()){const Ft=t.get(qt.id);if(!Ft)continue;if(Ft.hidden){t.set(Ft.id,{...Ft,internals:{...Ft.internals,handleBounds:void 0}}),it=!0;continue}const Ut=getDimensions(qt.nodeElement),Ht=Ft.measured.width!==Ut.width||Ft.measured.height!==Ut.height;if(!!(Ut.width&&Ut.height&&(Ht||!Ft.internals.handleBounds||qt.force))){const Yt=qt.nodeElement.getBoundingClientRect(),Gt=isCoordinateExtent(Ft.extent)?Ft.extent:nt;let{positionAbsolute:Vt}=Ft.internals;Ft.parentId&&Ft.extent==="parent"?Vt=clampPositionToParent(Vt,Ut,t.get(Ft.parentId)):Gt&&(Vt=clampPosition(Vt,Gt,Ut));const Zt={...Ft,measured:Ut,internals:{...Ft.internals,positionAbsolute:Vt,handleBounds:{source:getHandleBounds("source",qt.nodeElement,Yt,At,Ft.id),target:getHandleBounds("target",qt.nodeElement,Yt,At,Ft.id)}}};t.set(Ft.id,Zt),Ft.parentId&&updateChildNode(Zt,t,Ye,{nodeOrigin:rt}),it=!0,Ht&&(ot.push({id:Ft.id,type:"dimensions",dimensions:Ut}),Ft.expandParent&&Ft.parentId&&Rt.push({id:Ft.id,parentId:Ft.parentId,rect:nodeToRect(Zt,rt)}))}}if(Rt.length>0){const qt=handleExpandParent(Rt,t,Ye,rt);ot.push(...qt)}return{changes:ot,updatedInternals:it}}async function panBy({delta:e,panZoom:t,transform:Ye,translateExtent:tt,width:rt,height:nt}){if(!t||!e.x&&!e.y)return Promise.resolve(!1);const at=await t.setViewportConstrained({x:Ye[0]+e.x,y:Ye[1]+e.y,zoom:Ye[2]},[[0,0],[rt,nt]],tt),it=!!at&&(at.x!==Ye[0]||at.y!==Ye[1]||at.k!==Ye[2]);return Promise.resolve(it)}function addConnectionToLookup(e,t,Ye,tt,rt,nt){let at=rt;const it=tt.get(at)||new Map;tt.set(at,it.set(Ye,t)),at=`${rt}-${e}`;const ot=tt.get(at)||new Map;if(tt.set(at,ot.set(Ye,t)),nt){at=`${rt}-${e}-${nt}`;const ct=tt.get(at)||new Map;tt.set(at,ct.set(Ye,t))}}function updateConnectionLookup(e,t,Ye){e.clear(),t.clear();for(const tt of Ye){const{source:rt,target:nt,sourceHandle:at=null,targetHandle:it=null}=tt,ot={edgeId:tt.id,source:rt,target:nt,sourceHandle:at,targetHandle:it},ct=`${rt}-${at}--${nt}-${it}`,At=`${nt}-${it}--${rt}-${at}`;addConnectionToLookup("source",ot,At,e,rt,at),addConnectionToLookup("target",ot,ct,e,nt,it),t.set(tt.id,tt)}}function isParentSelected(e,t){if(!e.parentId)return!1;const Ye=t.get(e.parentId);return Ye?Ye.selected?!0:isParentSelected(Ye,t):!1}function hasSelector(e,t,Ye){var rt;let tt=e;do{if((rt=tt==null?void 0:tt.matches)!=null&&rt.call(tt,t))return!0;if(tt===Ye)return!1;tt=tt==null?void 0:tt.parentElement}while(tt);return!1}function getDragItems(e,t,Ye,tt){const rt=new Map;for(const[nt,at]of e)if((at.selected||at.id===tt)&&(!at.parentId||!isParentSelected(at,e))&&(at.draggable||t&&typeof at.draggable>"u")){const it=e.get(nt);it&&rt.set(nt,{id:nt,position:it.position||{x:0,y:0},distance:{x:Ye.x-it.internals.positionAbsolute.x,y:Ye.y-it.internals.positionAbsolute.y},extent:it.extent,parentId:it.parentId,origin:it.origin,expandParent:it.expandParent,internals:{positionAbsolute:it.internals.positionAbsolute||{x:0,y:0}},measured:{width:it.measured.width??0,height:it.measured.height??0}})}return rt}function getEventHandlerParams({nodeId:e,dragItems:t,nodeLookup:Ye,dragging:tt=!0}){var at,it,ot;const rt=[];for(const[ct,At]of t){const Rt=(at=Ye.get(ct))==null?void 0:at.internals.userNode;Rt&&rt.push({...Rt,position:At.position,dragging:tt})}if(!e)return[rt[0],rt];const nt=(it=Ye.get(e))==null?void 0:it.internals.userNode;return[nt?{...nt,position:((ot=t.get(e))==null?void 0:ot.position)||nt.position,dragging:tt}:rt[0],rt]}function XYDrag({onNodeMouseDown:e,getStoreItems:t,onDragStart:Ye,onDrag:tt,onDragStop:rt}){let nt={x:null,y:null},at=0,it=new Map,ot=!1,ct={x:0,y:0},At=null,Rt=!1,qt=null,Ft=!1;function Ut({noDragClassName:zt,handleSelector:Yt,domNode:Gt,isSelectable:Vt,nodeId:Zt,nodeClickDistance:Xt=0}){qt=select(Gt);function Qt({x:sr,y:lr},fr){const{nodeLookup:gr,nodeExtent:dr,snapGrid:vr,snapToGrid:mr,nodeOrigin:Er,onNodeDrag:_r,onSelectionDrag:Tr,onError:ur,updateNodePositions:cr}=t();nt={x:sr,y:lr};let yr=!1,ir={x:0,y:0,x2:0,y2:0};if(it.size>1&&dr){const or=getInternalNodesBounds(it);ir=rectToBox(or)}for(const[or,hr]of it){if(!gr.has(or))continue;let Sr={x:sr-hr.distance.x,y:lr-hr.distance.y};mr&&(Sr=snapPosition(Sr,vr));let wr=[[dr[0][0],dr[0][1]],[dr[1][0],dr[1][1]]];if(it.size>1&&dr&&!hr.extent){const{positionAbsolute:Mr}=hr.internals,Ar=Mr.x-ir.x+dr[0][0],Rr=Mr.x+hr.measured.width-ir.x2+dr[1][0],Dr=Mr.y-ir.y+dr[0][1],Lr=Mr.y+hr.measured.height-ir.y2+dr[1][1];wr=[[Ar,Dr],[Rr,Lr]]}const{position:Ir,positionAbsolute:kr}=calculateNodePosition({nodeId:or,nextPosition:Sr,nodeLookup:gr,nodeExtent:wr,nodeOrigin:Er,onError:ur});yr=yr||hr.position.x!==Ir.x||hr.position.y!==Ir.y,hr.position=Ir,hr.internals.positionAbsolute=kr}if(yr&&(cr(it,!0),fr&&(tt||_r||!Zt&&Tr))){const[or,hr]=getEventHandlerParams({nodeId:Zt,dragItems:it,nodeLookup:gr});tt==null||tt(fr,it,or,hr),_r==null||_r(fr,or,hr),Zt||Tr==null||Tr(fr,hr)}}async function er(){if(!At)return;const{transform:sr,panBy:lr,autoPanSpeed:fr,autoPanOnNodeDrag:gr}=t();if(!gr){ot=!1,cancelAnimationFrame(at);return}const[dr,vr]=calcAutoPan(ct,At,fr);(dr!==0||vr!==0)&&(nt.x=(nt.x??0)-dr/sr[2],nt.y=(nt.y??0)-vr/sr[2],await lr({x:dr,y:vr})&&Qt(nt,null)),at=requestAnimationFrame(er)}function nr(sr){var yr;const{nodeLookup:lr,multiSelectionActive:fr,nodesDraggable:gr,transform:dr,snapGrid:vr,snapToGrid:mr,selectNodesOnDrag:Er,onNodeDragStart:_r,onSelectionDragStart:Tr,unselectNodesAndEdges:ur}=t();Rt=!0,(!Er||!Vt)&&!fr&&Zt&&((yr=lr.get(Zt))!=null&&yr.selected||ur()),Vt&&Er&&Zt&&(e==null||e(Zt));const cr=getPointerPosition(sr.sourceEvent,{transform:dr,snapGrid:vr,snapToGrid:mr,containerBounds:At});if(nt=cr,it=getDragItems(lr,gr,cr,Zt),it.size>0&&(Ye||_r||!Zt&&Tr)){const[ir,or]=getEventHandlerParams({nodeId:Zt,dragItems:it,nodeLookup:lr});Ye==null||Ye(sr.sourceEvent,it,ir,or),_r==null||_r(sr.sourceEvent,ir,or),Zt||Tr==null||Tr(sr.sourceEvent,or)}}const ar=drag().clickDistance(Xt).on("start",sr=>{const{domNode:lr,nodeDragThreshold:fr,transform:gr,snapGrid:dr,snapToGrid:vr}=t();At=(lr==null?void 0:lr.getBoundingClientRect())||null,Ft=!1,fr===0&&nr(sr),nt=getPointerPosition(sr.sourceEvent,{transform:gr,snapGrid:dr,snapToGrid:vr,containerBounds:At}),ct=getEventPosition(sr.sourceEvent,At)}).on("drag",sr=>{const{autoPanOnNodeDrag:lr,transform:fr,snapGrid:gr,snapToGrid:dr,nodeDragThreshold:vr,nodeLookup:mr}=t(),Er=getPointerPosition(sr.sourceEvent,{transform:fr,snapGrid:gr,snapToGrid:dr,containerBounds:At});if((sr.sourceEvent.type==="touchmove"&&sr.sourceEvent.touches.length>1||Zt&&!mr.has(Zt))&&(Ft=!0),!Ft){if(!ot&&lr&&Rt&&(ot=!0,er()),!Rt){const _r=Er.xSnapped-(nt.x??0),Tr=Er.ySnapped-(nt.y??0);Math.sqrt(_r*_r+Tr*Tr)>vr&&nr(sr)}(nt.x!==Er.xSnapped||nt.y!==Er.ySnapped)&&it&&Rt&&(ct=getEventPosition(sr.sourceEvent,At),Qt(Er,sr.sourceEvent))}}).on("end",sr=>{if(!(!Rt||Ft)&&(ot=!1,Rt=!1,cancelAnimationFrame(at),it.size>0)){const{nodeLookup:lr,updateNodePositions:fr,onNodeDragStop:gr,onSelectionDragStop:dr}=t();if(fr(it,!1),rt||gr||!Zt&&dr){const[vr,mr]=getEventHandlerParams({nodeId:Zt,dragItems:it,nodeLookup:lr,dragging:!1});rt==null||rt(sr.sourceEvent,it,vr,mr),gr==null||gr(sr.sourceEvent,vr,mr),Zt||dr==null||dr(sr.sourceEvent,mr)}}}).filter(sr=>{const lr=sr.target;return!sr.button&&(!zt||!hasSelector(lr,`.${zt}`,Gt))&&(!Yt||hasSelector(lr,Yt,Gt))});qt.call(ar)}function Ht(){qt==null||qt.on(".drag",null)}return{update:Ut,destroy:Ht}}function getNodesWithinDistance(e,t,Ye){const tt=[],rt={x:e.x-Ye,y:e.y-Ye,width:Ye*2,height:Ye*2};for(const nt of t.values())getOverlappingArea(rt,nodeToRect(nt))>0&&tt.push(nt);return tt}const ADDITIONAL_DISTANCE=250;function getClosestHandle(e,t,Ye,tt){var it,ot;let rt=[],nt=1/0;const at=getNodesWithinDistance(e,Ye,t+ADDITIONAL_DISTANCE);for(const ct of at){const At=[...((it=ct.internals.handleBounds)==null?void 0:it.source)??[],...((ot=ct.internals.handleBounds)==null?void 0:ot.target)??[]];for(const Rt of At){if(tt.nodeId===Rt.nodeId&&tt.type===Rt.type&&tt.id===Rt.id)continue;const{x:qt,y:Ft}=getHandlePosition(ct,Rt,Rt.position,!0),Ut=Math.sqrt(Math.pow(qt-e.x,2)+Math.pow(Ft-e.y,2));Ut>t||(Ut<nt?(rt=[{...Rt,x:qt,y:Ft}],nt=Ut):Ut===nt&&rt.push({...Rt,x:qt,y:Ft}))}}if(!rt.length)return null;if(rt.length>1){const ct=tt.type==="source"?"target":"source";return rt.find(At=>At.type===ct)??rt[0]}return rt[0]}function getHandle(e,t,Ye,tt,rt,nt=!1){var ct,At,Rt;const at=tt.get(e);if(!at)return null;const it=rt==="strict"?(ct=at.internals.handleBounds)==null?void 0:ct[t]:[...((At=at.internals.handleBounds)==null?void 0:At.source)??[],...((Rt=at.internals.handleBounds)==null?void 0:Rt.target)??[]],ot=(Ye?it==null?void 0:it.find(qt=>qt.id===Ye):it==null?void 0:it[0])??null;return ot&&nt?{...ot,...getHandlePosition(at,ot,ot.position,!0)}:ot}function getHandleType(e,t){return e||(t!=null&&t.classList.contains("target")?"target":t!=null&&t.classList.contains("source")?"source":null)}function isConnectionValid(e,t){let Ye=null;return t?Ye=!0:e&&!t&&(Ye=!1),Ye}const alwaysValid=()=>!0;function onPointerDown(e,{connectionMode:t,connectionRadius:Ye,handleId:tt,nodeId:rt,edgeUpdaterType:nt,isTarget:at,domNode:it,nodeLookup:ot,lib:ct,autoPanOnConnect:At,flowId:Rt,panBy:qt,cancelConnection:Ft,onConnectStart:Ut,onConnect:Ht,onConnectEnd:zt,isValidConnection:Yt=alwaysValid,onReconnectEnd:Gt,updateConnection:Vt,getTransform:Zt,getFromHandle:Xt,autoPanSpeed:Qt}){const er=getHostForElement(e.target);let nr=0,ar;const{x:sr,y:lr}=getEventPosition(e),fr=er==null?void 0:er.elementFromPoint(sr,lr),gr=getHandleType(nt,fr),dr=it==null?void 0:it.getBoundingClientRect();if(!dr||!gr)return;const vr=getHandle(rt,gr,tt,ot,t);if(!vr)return;let mr=getEventPosition(e,dr),Er=!1,_r=null,Tr=!1,ur=null;function cr(){if(!At||!dr)return;const[kr,Mr]=calcAutoPan(mr,dr,Qt);qt({x:kr,y:Mr}),nr=requestAnimationFrame(cr)}const yr={...vr,nodeId:rt,type:gr,position:vr.position},ir=ot.get(rt),hr={inProgress:!0,isValid:null,from:getHandlePosition(ir,yr,Position.Left,!0),fromHandle:yr,fromPosition:yr.position,fromNode:ir,to:mr,toHandle:null,toPosition:oppositePosition[yr.position],toNode:null};Vt(hr);let Sr=hr;Ut==null||Ut(e,{nodeId:rt,handleId:tt,handleType:gr});function wr(kr){if(!Xt()||!yr){Ir(kr);return}const Mr=Zt();mr=getEventPosition(kr,dr),ar=getClosestHandle(pointToRendererPoint(mr,Mr,!1,[1,1]),Ye,ot,yr),Er||(cr(),Er=!0);const Ar=isValidHandle(kr,{handle:ar,connectionMode:t,fromNodeId:rt,fromHandleId:tt,fromType:at?"target":"source",isValidConnection:Yt,doc:er,lib:ct,flowId:Rt,nodeLookup:ot});ur=Ar.handleDomNode,_r=Ar.connection,Tr=isConnectionValid(!!ar,Ar.isValid);const Rr={...Sr,isValid:Tr,to:Ar.toHandle&&Tr?rendererPointToPoint({x:Ar.toHandle.x,y:Ar.toHandle.y},Mr):mr,toHandle:Ar.toHandle,toPosition:Tr&&Ar.toHandle?Ar.toHandle.position:oppositePosition[yr.position],toNode:Ar.toHandle?ot.get(Ar.toHandle.nodeId):null};Tr&&ar&&Sr.toHandle&&Rr.toHandle&&Sr.toHandle.type===Rr.toHandle.type&&Sr.toHandle.nodeId===Rr.toHandle.nodeId&&Sr.toHandle.id===Rr.toHandle.id&&Sr.to.x===Rr.to.x&&Sr.to.y===Rr.to.y||(Vt(Rr),Sr=Rr)}function Ir(kr){(ar||ur)&&_r&&Tr&&(Ht==null||Ht(_r));const{inProgress:Mr,...Ar}=Sr,Rr={...Ar,toPosition:Sr.toHandle?Sr.toPosition:null};zt==null||zt(kr,Rr),nt&&(Gt==null||Gt(kr,Rr)),Ft(),cancelAnimationFrame(nr),Er=!1,Tr=!1,_r=null,ur=null,er.removeEventListener("mousemove",wr),er.removeEventListener("mouseup",Ir),er.removeEventListener("touchmove",wr),er.removeEventListener("touchend",Ir)}er.addEventListener("mousemove",wr),er.addEventListener("mouseup",Ir),er.addEventListener("touchmove",wr),er.addEventListener("touchend",Ir)}function isValidHandle(e,{handle:t,connectionMode:Ye,fromNodeId:tt,fromHandleId:rt,fromType:nt,doc:at,lib:it,flowId:ot,isValidConnection:ct=alwaysValid,nodeLookup:At}){const Rt=nt==="target",qt=t?at.querySelector(`.${it}-flow__handle[data-id="${ot}-${t==null?void 0:t.nodeId}-${t==null?void 0:t.id}-${t==null?void 0:t.type}"]`):null,{x:Ft,y:Ut}=getEventPosition(e),Ht=at.elementFromPoint(Ft,Ut),zt=Ht!=null&&Ht.classList.contains(`${it}-flow__handle`)?Ht:qt,Yt={handleDomNode:zt,isValid:!1,connection:null,toHandle:null};if(zt){const Gt=getHandleType(void 0,zt),Vt=zt.getAttribute("data-nodeid"),Zt=zt.getAttribute("data-handleid"),Xt=zt.classList.contains("connectable"),Qt=zt.classList.contains("connectableend");if(!Vt||!Gt)return Yt;const er={source:Rt?Vt:tt,sourceHandle:Rt?Zt:rt,target:Rt?tt:Vt,targetHandle:Rt?rt:Zt};Yt.connection=er;const ar=Xt&&Qt&&(Ye===ConnectionMode.Strict?Rt&&Gt==="source"||!Rt&&Gt==="target":Vt!==tt||Zt!==rt);Yt.isValid=ar&&ct(er),Yt.toHandle=getHandle(Vt,Gt,Zt,At,Ye,!0)}return Yt}const XYHandle={onPointerDown,isValid:isValidHandle};function XYMinimap({domNode:e,panZoom:t,getTransform:Ye,getViewScale:tt}){const rt=select(e);function nt({translateExtent:it,width:ot,height:ct,zoomStep:At=10,pannable:Rt=!0,zoomable:qt=!0,inversePan:Ft=!1}){const Ut=Vt=>{const Zt=Ye();if(Vt.sourceEvent.type!=="wheel"||!t)return;const Xt=-Vt.sourceEvent.deltaY*(Vt.sourceEvent.deltaMode===1?.05:Vt.sourceEvent.deltaMode?1:.002)*At,Qt=Zt[2]*Math.pow(2,Xt);t.scaleTo(Qt)};let Ht=[0,0];const zt=Vt=>{(Vt.sourceEvent.type==="mousedown"||Vt.sourceEvent.type==="touchstart")&&(Ht=[Vt.sourceEvent.clientX??Vt.sourceEvent.touches[0].clientX,Vt.sourceEvent.clientY??Vt.sourceEvent.touches[0].clientY])},Yt=Vt=>{const Zt=Ye();if(Vt.sourceEvent.type!=="mousemove"&&Vt.sourceEvent.type!=="touchmove"||!t)return;const Xt=[Vt.sourceEvent.clientX??Vt.sourceEvent.touches[0].clientX,Vt.sourceEvent.clientY??Vt.sourceEvent.touches[0].clientY],Qt=[Xt[0]-Ht[0],Xt[1]-Ht[1]];Ht=Xt;const er=tt()*Math.max(Zt[2],Math.log(Zt[2]))*(Ft?-1:1),nr={x:Zt[0]-Qt[0]*er,y:Zt[1]-Qt[1]*er},ar=[[0,0],[ot,ct]];t.setViewportConstrained({x:nr.x,y:nr.y,zoom:Zt[2]},ar,it)},Gt=zoom().on("start",zt).on("zoom",Rt?Yt:null).on("zoom.wheel",qt?Ut:null);rt.call(Gt,{})}function at(){rt.on("zoom",null)}return{update:nt,destroy:at,pointer}}const viewChanged=(e,t)=>e.x!==t.x||e.y!==t.y||e.zoom!==t.k,transformToViewport=e=>({x:e.x,y:e.y,zoom:e.k}),viewportToTransform=({x:e,y:t,zoom:Ye})=>identity$2.translate(e,t).scale(Ye),isWrappedWithClass=(e,t)=>e.target.closest(`.${t}`),isRightClickPan=(e,t)=>t===2&&Array.isArray(e)&&e.includes(2),getD3Transition=(e,t=0,Ye=()=>{})=>{const tt=typeof t=="number"&&t>0;return tt||Ye(),tt?e.transition().duration(t).on("end",Ye):e},wheelDelta=e=>{const t=e.ctrlKey&&isMacOs()?10:1;return-e.deltaY*(e.deltaMode===1?.05:e.deltaMode?1:.002)*t};function createPanOnScrollHandler({zoomPanValues:e,noWheelClassName:t,d3Selection:Ye,d3Zoom:tt,panOnScrollMode:rt,panOnScrollSpeed:nt,zoomOnPinch:at,onPanZoomStart:it,onPanZoom:ot,onPanZoomEnd:ct}){return At=>{if(isWrappedWithClass(At,t))return!1;At.preventDefault(),At.stopImmediatePropagation();const Rt=Ye.property("__zoom").k||1;if(At.ctrlKey&&at){const zt=pointer(At),Yt=wheelDelta(At),Gt=Rt*Math.pow(2,Yt);tt.scaleTo(Ye,Gt,zt,At);return}const qt=At.deltaMode===1?20:1;let Ft=rt===PanOnScrollMode.Vertical?0:At.deltaX*qt,Ut=rt===PanOnScrollMode.Horizontal?0:At.deltaY*qt;!isMacOs()&&At.shiftKey&&rt!==PanOnScrollMode.Vertical&&(Ft=At.deltaY*qt,Ut=0),tt.translateBy(Ye,-(Ft/Rt)*nt,-(Ut/Rt)*nt,{internal:!0});const Ht=transformToViewport(Ye.property("__zoom"));clearTimeout(e.panScrollTimeout),e.isPanScrolling||(e.isPanScrolling=!0,it==null||it(At,Ht)),e.isPanScrolling&&(ot==null||ot(At,Ht),e.panScrollTimeout=setTimeout(()=>{ct==null||ct(At,Ht),e.isPanScrolling=!1},150))}}function createZoomOnScrollHandler({noWheelClassName:e,preventScrolling:t,d3ZoomHandler:Ye}){return function(tt,rt){const nt=tt.type==="wheel",at=!t&&nt&&!tt.ctrlKey,it=isWrappedWithClass(tt,e);if(tt.ctrlKey&&nt&&it&&tt.preventDefault(),at||it)return null;tt.preventDefault(),Ye.call(this,tt,rt)}}function createPanZoomStartHandler({zoomPanValues:e,onDraggingChange:t,onPanZoomStart:Ye}){return tt=>{var nt,at,it;if((nt=tt.sourceEvent)!=null&&nt.internal)return;const rt=transformToViewport(tt.transform);e.mouseButton=((at=tt.sourceEvent)==null?void 0:at.button)||0,e.isZoomingOrPanning=!0,e.prevViewport=rt,((it=tt.sourceEvent)==null?void 0:it.type)==="mousedown"&&t(!0),Ye&&(Ye==null||Ye(tt.sourceEvent,rt))}}function createPanZoomHandler({zoomPanValues:e,panOnDrag:t,onPaneContextMenu:Ye,onTransformChange:tt,onPanZoom:rt}){return nt=>{var at,it;e.usedRightMouseButton=!!(Ye&&isRightClickPan(t,e.mouseButton??0)),(at=nt.sourceEvent)!=null&&at.sync||tt([nt.transform.x,nt.transform.y,nt.transform.k]),rt&&!((it=nt.sourceEvent)!=null&&it.internal)&&(rt==null||rt(nt.sourceEvent,transformToViewport(nt.transform)))}}function createPanZoomEndHandler({zoomPanValues:e,panOnDrag:t,panOnScroll:Ye,onDraggingChange:tt,onPanZoomEnd:rt,onPaneContextMenu:nt}){return at=>{var it;if(!((it=at.sourceEvent)!=null&&it.internal)&&(e.isZoomingOrPanning=!1,nt&&isRightClickPan(t,e.mouseButton??0)&&!e.usedRightMouseButton&&at.sourceEvent&&nt(at.sourceEvent),e.usedRightMouseButton=!1,tt(!1),rt&&viewChanged(e.prevViewport,at.transform))){const ot=transformToViewport(at.transform);e.prevViewport=ot,clearTimeout(e.timerId),e.timerId=setTimeout(()=>{rt==null||rt(at.sourceEvent,ot)},Ye?150:0)}}}function createFilter({zoomActivationKeyPressed:e,zoomOnScroll:t,zoomOnPinch:Ye,panOnDrag:tt,panOnScroll:rt,zoomOnDoubleClick:nt,userSelectionActive:at,noWheelClassName:it,noPanClassName:ot,lib:ct}){return At=>{var Ut;const Rt=e||t,qt=Ye&&At.ctrlKey;if(At.button===1&&At.type==="mousedown"&&(isWrappedWithClass(At,`${ct}-flow__node`)||isWrappedWithClass(At,`${ct}-flow__edge`)))return!0;if(!tt&&!Rt&&!rt&&!nt&&!Ye||at||isWrappedWithClass(At,it)&&At.type==="wheel"||isWrappedWithClass(At,ot)&&(At.type!=="wheel"||rt&&At.type==="wheel"&&!e)||!Ye&&At.ctrlKey&&At.type==="wheel")return!1;if(!Ye&&At.type==="touchstart"&&((Ut=At.touches)==null?void 0:Ut.length)>1)return At.preventDefault(),!1;if(!Rt&&!rt&&!qt&&At.type==="wheel"||!tt&&(At.type==="mousedown"||At.type==="touchstart")||Array.isArray(tt)&&!tt.includes(At.button)&&At.type==="mousedown")return!1;const Ft=Array.isArray(tt)&&tt.includes(At.button)||!At.button||At.button<=1;return(!At.ctrlKey||At.type==="wheel")&&Ft}}function XYPanZoom({domNode:e,minZoom:t,maxZoom:Ye,paneClickDistance:tt,translateExtent:rt,viewport:nt,onPanZoom:at,onPanZoomStart:it,onPanZoomEnd:ot,onDraggingChange:ct}){const At={isZoomingOrPanning:!1,usedRightMouseButton:!1,prevViewport:{x:0,y:0,zoom:0},mouseButton:0,timerId:void 0,panScrollTimeout:void 0,isPanScrolling:!1},Rt=e.getBoundingClientRect(),qt=zoom().clickDistance(!isNumeric(tt)||tt<0?0:tt).scaleExtent([t,Ye]).translateExtent(rt),Ft=select(e).call(qt);Vt({x:nt.x,y:nt.y,zoom:clamp(nt.zoom,t,Ye)},[[0,0],[Rt.width,Rt.height]],rt);const Ut=Ft.on("wheel.zoom"),Ht=Ft.on("dblclick.zoom");qt.wheelDelta(wheelDelta);function zt(fr,gr){return Ft?new Promise(dr=>{qt==null||qt.transform(getD3Transition(Ft,gr==null?void 0:gr.duration,()=>dr(!0)),fr)}):Promise.resolve(!1)}function Yt({noWheelClassName:fr,noPanClassName:gr,onPaneContextMenu:dr,userSelectionActive:vr,panOnScroll:mr,panOnDrag:Er,panOnScrollMode:_r,panOnScrollSpeed:Tr,preventScrolling:ur,zoomOnPinch:cr,zoomOnScroll:yr,zoomOnDoubleClick:ir,zoomActivationKeyPressed:or,lib:hr,onTransformChange:Sr}){vr&&!At.isZoomingOrPanning&&Gt();const Ir=mr&&!or&&!vr?createPanOnScrollHandler({zoomPanValues:At,noWheelClassName:fr,d3Selection:Ft,d3Zoom:qt,panOnScrollMode:_r,panOnScrollSpeed:Tr,zoomOnPinch:cr,onPanZoomStart:it,onPanZoom:at,onPanZoomEnd:ot}):createZoomOnScrollHandler({noWheelClassName:fr,preventScrolling:ur,d3ZoomHandler:Ut});if(Ft.on("wheel.zoom",Ir,{passive:!1}),!vr){const Mr=createPanZoomStartHandler({zoomPanValues:At,onDraggingChange:ct,onPanZoomStart:it});qt.on("start",Mr);const Ar=createPanZoomHandler({zoomPanValues:At,panOnDrag:Er,onPaneContextMenu:!!dr,onPanZoom:at,onTransformChange:Sr});qt.on("zoom",Ar);const Rr=createPanZoomEndHandler({zoomPanValues:At,panOnDrag:Er,panOnScroll:mr,onPaneContextMenu:dr,onPanZoomEnd:ot,onDraggingChange:ct});qt.on("end",Rr)}const kr=createFilter({zoomActivationKeyPressed:or,panOnDrag:Er,zoomOnScroll:yr,panOnScroll:mr,zoomOnDoubleClick:ir,zoomOnPinch:cr,userSelectionActive:vr,noPanClassName:gr,noWheelClassName:fr,lib:hr});qt.filter(kr),ir?Ft.on("dblclick.zoom",Ht):Ft.on("dblclick.zoom",null)}function Gt(){qt.on("zoom",null)}async function Vt(fr,gr,dr){const vr=viewportToTransform(fr),mr=qt==null?void 0:qt.constrain()(vr,gr,dr);return mr&&await zt(mr),new Promise(Er=>Er(mr))}async function Zt(fr,gr){const dr=viewportToTransform(fr);return await zt(dr,gr),new Promise(vr=>vr(dr))}function Xt(fr){if(Ft){const gr=viewportToTransform(fr),dr=Ft.property("__zoom");(dr.k!==fr.zoom||dr.x!==fr.x||dr.y!==fr.y)&&(qt==null||qt.transform(Ft,gr,null,{sync:!0}))}}function Qt(){const fr=Ft?transform$1(Ft.node()):{x:0,y:0,k:1};return{x:fr.x,y:fr.y,zoom:fr.k}}function er(fr,gr){return Ft?new Promise(dr=>{qt==null||qt.scaleTo(getD3Transition(Ft,gr==null?void 0:gr.duration,()=>dr(!0)),fr)}):Promise.resolve(!1)}function nr(fr,gr){return Ft?new Promise(dr=>{qt==null||qt.scaleBy(getD3Transition(Ft,gr==null?void 0:gr.duration,()=>dr(!0)),fr)}):Promise.resolve(!1)}function ar(fr){qt==null||qt.scaleExtent(fr)}function sr(fr){qt==null||qt.translateExtent(fr)}function lr(fr){const gr=!isNumeric(fr)||fr<0?0:fr;qt==null||qt.clickDistance(gr)}return{update:Yt,destroy:Gt,setViewport:Zt,setViewportConstrained:Vt,getViewport:Qt,scaleTo:er,scaleBy:nr,setScaleExtent:ar,setTranslateExtent:sr,syncViewport:Xt,setClickDistance:lr}}var ResizeControlVariant;(function(e){e.Line="line",e.Handle="handle"})(ResizeControlVariant||(ResizeControlVariant={}));function getResizeDirection({width:e,prevWidth:t,height:Ye,prevHeight:tt,affectsX:rt,affectsY:nt}){const at=e-t,it=Ye-tt,ot=[at>0?1:at<0?-1:0,it>0?1:it<0?-1:0];return at&&rt&&(ot[0]=ot[0]*-1),it&&nt&&(ot[1]=ot[1]*-1),ot}function getControlDirection(e){const t=e.includes("right")||e.includes("left"),Ye=e.includes("bottom")||e.includes("top"),tt=e.includes("left"),rt=e.includes("top");return{isHorizontal:t,isVertical:Ye,affectsX:tt,affectsY:rt}}function getLowerExtentClamp(e,t){return Math.max(0,t-e)}function getUpperExtentClamp(e,t){return Math.max(0,e-t)}function getSizeClamp(e,t,Ye){return Math.max(0,t-e,e-Ye)}function xor(e,t){return e?!t:t}function getDimensionsAfterResize(e,t,Ye,tt,rt,nt,at,it){let{affectsX:ot,affectsY:ct}=t;const{isHorizontal:At,isVertical:Rt}=t,qt=At&&Rt,{xSnapped:Ft,ySnapped:Ut}=Ye,{minWidth:Ht,maxWidth:zt,minHeight:Yt,maxHeight:Gt}=tt,{x:Vt,y:Zt,width:Xt,height:Qt,aspectRatio:er}=e;let nr=Math.floor(At?Ft-e.pointerX:0),ar=Math.floor(Rt?Ut-e.pointerY:0);const sr=Xt+(ot?-nr:nr),lr=Qt+(ct?-ar:ar),fr=-nt[0]*Xt,gr=-nt[1]*Qt;let dr=getSizeClamp(sr,Ht,zt),vr=getSizeClamp(lr,Yt,Gt);if(at){let _r=0,Tr=0;ot&&nr<0?_r=getLowerExtentClamp(Vt+nr+fr,at[0][0]):!ot&&nr>0&&(_r=getUpperExtentClamp(Vt+sr+fr,at[1][0])),ct&&ar<0?Tr=getLowerExtentClamp(Zt+ar+gr,at[0][1]):!ct&&ar>0&&(Tr=getUpperExtentClamp(Zt+lr+gr,at[1][1])),dr=Math.max(dr,_r),vr=Math.max(vr,Tr)}if(it){let _r=0,Tr=0;ot&&nr>0?_r=getUpperExtentClamp(Vt+nr,it[0][0]):!ot&&nr<0&&(_r=getLowerExtentClamp(Vt+sr,it[1][0])),ct&&ar>0?Tr=getUpperExtentClamp(Zt+ar,it[0][1]):!ct&&ar<0&&(Tr=getLowerExtentClamp(Zt+lr,it[1][1])),dr=Math.max(dr,_r),vr=Math.max(vr,Tr)}if(rt){if(At){const _r=getSizeClamp(sr/er,Yt,Gt)*er;if(dr=Math.max(dr,_r),at){let Tr=0;!ot&&!ct||ot&&!ct&&qt?Tr=getUpperExtentClamp(Zt+gr+sr/er,at[1][1])*er:Tr=getLowerExtentClamp(Zt+gr+(ot?nr:-nr)/er,at[0][1])*er,dr=Math.max(dr,Tr)}if(it){let Tr=0;!ot&&!ct||ot&&!ct&&qt?Tr=getLowerExtentClamp(Zt+sr/er,it[1][1])*er:Tr=getUpperExtentClamp(Zt+(ot?nr:-nr)/er,it[0][1])*er,dr=Math.max(dr,Tr)}}if(Rt){const _r=getSizeClamp(lr*er,Ht,zt)/er;if(vr=Math.max(vr,_r),at){let Tr=0;!ot&&!ct||ct&&!ot&&qt?Tr=getUpperExtentClamp(Vt+lr*er+fr,at[1][0])/er:Tr=getLowerExtentClamp(Vt+(ct?ar:-ar)*er+fr,at[0][0])/er,vr=Math.max(vr,Tr)}if(it){let Tr=0;!ot&&!ct||ct&&!ot&&qt?Tr=getLowerExtentClamp(Vt+lr*er,it[1][0])/er:Tr=getUpperExtentClamp(Vt+(ct?ar:-ar)*er,it[0][0])/er,vr=Math.max(vr,Tr)}}}ar=ar+(ar<0?vr:-vr),nr=nr+(nr<0?dr:-dr),rt&&(qt?sr>lr*er?ar=(xor(ot,ct)?-nr:nr)/er:nr=(xor(ot,ct)?-ar:ar)*er:At?(ar=nr/er,ct=ot):(nr=ar*er,ot=ct));const mr=ot?Vt+nr:Vt,Er=ct?Zt+ar:Zt;return{width:Xt+(ot?-nr:nr),height:Qt+(ct?-ar:ar),x:nt[0]*nr*(ot?-1:1)+mr,y:nt[1]*ar*(ct?-1:1)+Er}}const initPrevValues$1={width:0,height:0,x:0,y:0},initStartValues={...initPrevValues$1,pointerX:0,pointerY:0,aspectRatio:1};function nodeToParentExtent(e){return[[0,0],[e.measured.width,e.measured.height]]}function nodeToChildExtent(e,t,Ye){const tt=t.position.x+e.position.x,rt=t.position.y+e.position.y,nt=e.measured.width??0,at=e.measured.height??0,it=Ye[0]*nt,ot=Ye[1]*at;return[[tt-it,rt-ot],[tt+nt-it,rt+at-ot]]}function XYResizer({domNode:e,nodeId:t,getStoreItems:Ye,onChange:tt,onEnd:rt}){const nt=select(e);function at({controlPosition:ot,boundaries:ct,keepAspectRatio:At,resizeDirection:Rt,onResizeStart:qt,onResize:Ft,onResizeEnd:Ut,shouldResize:Ht}){let zt={...initPrevValues$1},Yt={...initStartValues};const Gt=getControlDirection(ot);let Vt,Zt=null,Xt=[],Qt,er,nr;const ar=drag().on("start",sr=>{const{nodeLookup:lr,transform:fr,snapGrid:gr,snapToGrid:dr,nodeOrigin:vr,paneDomNode:mr}=Ye();if(Vt=lr.get(t),!Vt)return;Zt=(mr==null?void 0:mr.getBoundingClientRect())??null;const{xSnapped:Er,ySnapped:_r}=getPointerPosition(sr.sourceEvent,{transform:fr,snapGrid:gr,snapToGrid:dr,containerBounds:Zt});zt={width:Vt.measured.width??0,height:Vt.measured.height??0,x:Vt.position.x??0,y:Vt.position.y??0},Yt={...zt,pointerX:Er,pointerY:_r,aspectRatio:zt.width/zt.height},Qt=void 0,Vt.parentId&&(Vt.extent==="parent"||Vt.expandParent)&&(Qt=lr.get(Vt.parentId),er=Qt&&Vt.extent==="parent"?nodeToParentExtent(Qt):void 0),Xt=[],nr=void 0;for(const[Tr,ur]of lr)if(ur.parentId===t&&(Xt.push({id:Tr,position:{...ur.position},extent:ur.extent}),ur.extent==="parent"||ur.expandParent)){const cr=nodeToChildExtent(ur,Vt,ur.origin??vr);nr?nr=[[Math.min(cr[0][0],nr[0][0]),Math.min(cr[0][1],nr[0][1])],[Math.max(cr[1][0],nr[1][0]),Math.max(cr[1][1],nr[1][1])]]:nr=cr}qt==null||qt(sr,{...zt})}).on("drag",sr=>{const{transform:lr,snapGrid:fr,snapToGrid:gr,nodeOrigin:dr}=Ye(),vr=getPointerPosition(sr.sourceEvent,{transform:lr,snapGrid:fr,snapToGrid:gr,containerBounds:Zt}),mr=[];if(!Vt)return;const{x:Er,y:_r,width:Tr,height:ur}=zt,cr={},yr=Vt.origin??dr,{width:ir,height:or,x:hr,y:Sr}=getDimensionsAfterResize(Yt,Gt,vr,ct,At,yr,er,nr),wr=ir!==Tr,Ir=or!==ur,kr=hr!==Er&&wr,Mr=Sr!==_r&&Ir;if(!kr&&!Mr&&!wr&&!Ir)return;if((kr||Mr||yr[0]===1||yr[1]===1)&&(cr.x=kr?hr:zt.x,cr.y=Mr?Sr:zt.y,zt.x=cr.x,zt.y=cr.y,Xt.length>0)){const Lr=hr-Er,Ur=Sr-_r;for(const Wr of Xt)Wr.position={x:Wr.position.x-Lr+yr[0]*(ir-Tr),y:Wr.position.y-Ur+yr[1]*(or-ur)},mr.push(Wr)}if((wr||Ir)&&(cr.width=wr&&(!Rt||Rt==="horizontal")?ir:zt.width,cr.height=Ir&&(!Rt||Rt==="vertical")?or:zt.height,zt.width=cr.width,zt.height=cr.height),Qt&&Vt.expandParent){const Lr=yr[0]*(cr.width??0);cr.x&&cr.x<Lr&&(zt.x=Lr,Yt.x=Yt.x-(cr.x-Lr));const Ur=yr[1]*(cr.height??0);cr.y&&cr.y<Ur&&(zt.y=Ur,Yt.y=Yt.y-(cr.y-Ur))}const Ar=getResizeDirection({width:zt.width,prevWidth:Tr,height:zt.height,prevHeight:ur,affectsX:Gt.affectsX,affectsY:Gt.affectsY}),Rr={...zt,direction:Ar};(Ht==null?void 0:Ht(sr,Rr))!==!1&&(Ft==null||Ft(sr,Rr),tt(cr,mr))}).on("end",sr=>{Ut==null||Ut(sr,{...zt}),rt==null||rt({...zt})});nt.call(ar)}function it(){nt.on(".drag",null)}return{update:at,destroy:it}}var withSelector={exports:{}},withSelector_production={},shim={exports:{}},useSyncExternalStoreShim_production={};/**
814
+ ]))(?:`+(/[^\s\\]/.source+'|[ ]+(?:(?![ "])|'+rt+")|"+/\\[\r\n]+(?:[#;].*[\r\n]+)*(?![#;])/.source)+")*"),lookbehind:!0,greedy:!0,alias:"attr-value",inside:{comment:tt,quoted:{pattern:RegExp(/(^|\s)/.source+rt),lookbehind:!0,greedy:!0},punctuation:/\\$/m,boolean:{pattern:/^(?:false|no|off|on|true|yes)$/,greedy:!0}}},punctuation:/=/}})(t)}return systemd_1}var t4Templating_1,hasRequiredT4Templating;function requireT4Templating(){if(hasRequiredT4Templating)return t4Templating_1;hasRequiredT4Templating=1,t4Templating_1=e,e.displayName="t4Templating",e.aliases=[];function e(t){(function(Ye){function tt(nt,at,it){return{pattern:RegExp("<#"+nt+"[\\s\\S]*?#>"),alias:"block",inside:{delimiter:{pattern:RegExp("^<#"+nt+"|#>$"),alias:"important"},content:{pattern:/[\s\S]+/,inside:at,alias:it}}}}function rt(nt){var at=Ye.languages[nt],it="language-"+nt;return{block:{pattern:/<#[\s\S]+?#>/,inside:{directive:tt("@",{"attr-value":{pattern:/=(?:("|')(?:\\[\s\S]|(?!\1)[^\\])*\1|[^\s'">=]+)/,inside:{punctuation:/^=|^["']|["']$/}},keyword:/\b\w+(?=\s)/,"attr-name":/\b\w+/}),expression:tt("=",at,it),"class-feature":tt("\\+",at,it),standard:tt("",at,it)}}}}Ye.languages["t4-templating"]=Object.defineProperty({},"createT4",{value:rt})})(t)}return t4Templating_1}var t4Cs_1,hasRequiredT4Cs;function requireT4Cs(){if(hasRequiredT4Cs)return t4Cs_1;hasRequiredT4Cs=1;var e=requireT4Templating(),t=requireCsharp();t4Cs_1=Ye,Ye.displayName="t4Cs",Ye.aliases=[];function Ye(tt){tt.register(e),tt.register(t),tt.languages.t4=tt.languages["t4-cs"]=tt.languages["t4-templating"].createT4("csharp")}return t4Cs_1}var vbnet_1,hasRequiredVbnet;function requireVbnet(){if(hasRequiredVbnet)return vbnet_1;hasRequiredVbnet=1;var e=requireBasic();vbnet_1=t,t.displayName="vbnet",t.aliases=[];function t(Ye){Ye.register(e),Ye.languages.vbnet=Ye.languages.extend("basic",{comment:[{pattern:/(?:!|REM\b).+/i,inside:{keyword:/^REM/i}},{pattern:/(^|[^\\:])'.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(^|[^"])"(?:""|[^"])*"(?!")/,lookbehind:!0,greedy:!0},keyword:/(?:\b(?:ADDHANDLER|ADDRESSOF|ALIAS|AND|ANDALSO|AS|BEEP|BLOAD|BOOLEAN|BSAVE|BYREF|BYTE|BYVAL|CALL(?: ABSOLUTE)?|CASE|CATCH|CBOOL|CBYTE|CCHAR|CDATE|CDBL|CDEC|CHAIN|CHAR|CHDIR|CINT|CLASS|CLEAR|CLNG|CLOSE|CLS|COBJ|COM|COMMON|CONST|CONTINUE|CSBYTE|CSHORT|CSNG|CSTR|CTYPE|CUINT|CULNG|CUSHORT|DATA|DATE|DECIMAL|DECLARE|DEF(?: FN| SEG|DBL|INT|LNG|SNG|STR)|DEFAULT|DELEGATE|DIM|DIRECTCAST|DO|DOUBLE|ELSE|ELSEIF|END|ENUM|ENVIRON|ERASE|ERROR|EVENT|EXIT|FALSE|FIELD|FILES|FINALLY|FOR(?: EACH)?|FRIEND|FUNCTION|GET|GETTYPE|GETXMLNAMESPACE|GLOBAL|GOSUB|GOTO|HANDLES|IF|IMPLEMENTS|IMPORTS|IN|INHERITS|INPUT|INTEGER|INTERFACE|IOCTL|IS|ISNOT|KEY|KILL|LET|LIB|LIKE|LINE INPUT|LOCATE|LOCK|LONG|LOOP|LSET|ME|MKDIR|MOD|MODULE|MUSTINHERIT|MUSTOVERRIDE|MYBASE|MYCLASS|NAME|NAMESPACE|NARROWING|NEW|NEXT|NOT|NOTHING|NOTINHERITABLE|NOTOVERRIDABLE|OBJECT|OF|OFF|ON(?: COM| ERROR| KEY| TIMER)?|OPEN|OPERATOR|OPTION(?: BASE)?|OPTIONAL|OR|ORELSE|OUT|OVERLOADS|OVERRIDABLE|OVERRIDES|PARAMARRAY|PARTIAL|POKE|PRIVATE|PROPERTY|PROTECTED|PUBLIC|PUT|RAISEEVENT|READ|READONLY|REDIM|REM|REMOVEHANDLER|RESTORE|RESUME|RETURN|RMDIR|RSET|RUN|SBYTE|SELECT(?: CASE)?|SET|SHADOWS|SHARED|SHELL|SHORT|SINGLE|SLEEP|STATIC|STEP|STOP|STRING|STRUCTURE|SUB|SWAP|SYNCLOCK|SYSTEM|THEN|THROW|TIMER|TO|TROFF|TRON|TRUE|TRY|TRYCAST|TYPE|TYPEOF|UINTEGER|ULONG|UNLOCK|UNTIL|USHORT|USING|VIEW PRINT|WAIT|WEND|WHEN|WHILE|WIDENING|WITH|WITHEVENTS|WRITE|WRITEONLY|XOR)|\B(?:#CONST|#ELSE|#ELSEIF|#END|#IF))(?:\$|\b)/i,punctuation:/[,;:(){}]/})}return vbnet_1}var t4Vb_1,hasRequiredT4Vb;function requireT4Vb(){if(hasRequiredT4Vb)return t4Vb_1;hasRequiredT4Vb=1;var e=requireT4Templating(),t=requireVbnet();t4Vb_1=Ye,Ye.displayName="t4Vb",Ye.aliases=[];function Ye(tt){tt.register(e),tt.register(t),tt.languages["t4-vb"]=tt.languages["t4-templating"].createT4("vbnet")}return t4Vb_1}var yaml_1,hasRequiredYaml;function requireYaml(){if(hasRequiredYaml)return yaml_1;hasRequiredYaml=1,yaml_1=e,e.displayName="yaml",e.aliases=["yml"];function e(t){(function(Ye){var tt=/[*&][^\s[\]{},]+/,rt=/!(?:<[\w\-%#;/?:@&=+$,.!~*'()[\]]+>|(?:[a-zA-Z\d-]*!)?[\w\-%#;/?:@&=+$.~*'()]+)?/,nt="(?:"+rt.source+"(?:[ ]+"+tt.source+")?|"+tt.source+"(?:[ ]+"+rt.source+")?)",at=/(?:[^\s\x00-\x08\x0e-\x1f!"#%&'*,\-:>?@[\]`{|}\x7f-\x84\x86-\x9f\ud800-\udfff\ufffe\uffff]|[?:-]<PLAIN>)(?:[ \t]*(?:(?![#:])<PLAIN>|:<PLAIN>))*/.source.replace(/<PLAIN>/g,function(){return/[^\s\x00-\x08\x0e-\x1f,[\]{}\x7f-\x84\x86-\x9f\ud800-\udfff\ufffe\uffff]/.source}),it=/"(?:[^"\\\r\n]|\\.)*"|'(?:[^'\\\r\n]|\\.)*'/.source;function ot(ct,At){At=(At||"").replace(/m/g,"")+"m";var Rt=/([:\-,[{]\s*(?:\s<<prop>>[ \t]+)?)(?:<<value>>)(?=[ \t]*(?:$|,|\]|\}|(?:[\r\n]\s*)?#))/.source.replace(/<<prop>>/g,function(){return nt}).replace(/<<value>>/g,function(){return ct});return RegExp(Rt,At)}Ye.languages.yaml={scalar:{pattern:RegExp(/([\-:]\s*(?:\s<<prop>>[ \t]+)?[|>])[ \t]*(?:((?:\r?\n|\r)[ \t]+)\S[^\r\n]*(?:\2[^\r\n]+)*)/.source.replace(/<<prop>>/g,function(){return nt})),lookbehind:!0,alias:"string"},comment:/#.*/,key:{pattern:RegExp(/((?:^|[:\-,[{\r\n?])[ \t]*(?:<<prop>>[ \t]+)?)<<key>>(?=\s*:\s)/.source.replace(/<<prop>>/g,function(){return nt}).replace(/<<key>>/g,function(){return"(?:"+at+"|"+it+")"})),lookbehind:!0,greedy:!0,alias:"atrule"},directive:{pattern:/(^[ \t]*)%.+/m,lookbehind:!0,alias:"important"},datetime:{pattern:ot(/\d{4}-\d\d?-\d\d?(?:[tT]|[ \t]+)\d\d?:\d{2}:\d{2}(?:\.\d*)?(?:[ \t]*(?:Z|[-+]\d\d?(?::\d{2})?))?|\d{4}-\d{2}-\d{2}|\d\d?:\d{2}(?::\d{2}(?:\.\d*)?)?/.source),lookbehind:!0,alias:"number"},boolean:{pattern:ot(/false|true/.source,"i"),lookbehind:!0,alias:"important"},null:{pattern:ot(/null|~/.source,"i"),lookbehind:!0,alias:"important"},string:{pattern:ot(it),lookbehind:!0,greedy:!0},number:{pattern:ot(/[+-]?(?:0x[\da-f]+|0o[0-7]+|(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?|\.inf|\.nan)/.source,"i"),lookbehind:!0},tag:rt,important:tt,punctuation:/---|[:[\]{}\-,|>?]|\.\.\./},Ye.languages.yml=Ye.languages.yaml})(t)}return yaml_1}var tap_1,hasRequiredTap;function requireTap(){if(hasRequiredTap)return tap_1;hasRequiredTap=1;var e=requireYaml();tap_1=t,t.displayName="tap",t.aliases=[];function t(Ye){Ye.register(e),Ye.languages.tap={fail:/not ok[^#{\n\r]*/,pass:/ok[^#{\n\r]*/,pragma:/pragma [+-][a-z]+/,bailout:/bail out!.*/i,version:/TAP version \d+/i,plan:/\b\d+\.\.\d+(?: +#.*)?/,subtest:{pattern:/# Subtest(?:: .*)?/,greedy:!0},punctuation:/[{}]/,directive:/#.*/,yamlish:{pattern:/(^[ \t]*)---[\s\S]*?[\r\n][ \t]*\.\.\.$/m,lookbehind:!0,inside:Ye.languages.yaml,alias:"language-yaml"}}}return tap_1}var tcl_1,hasRequiredTcl;function requireTcl(){if(hasRequiredTcl)return tcl_1;hasRequiredTcl=1,tcl_1=e,e.displayName="tcl",e.aliases=[];function e(t){t.languages.tcl={comment:{pattern:/(^|[^\\])#.*/,lookbehind:!0},string:{pattern:/"(?:[^"\\\r\n]|\\(?:\r\n|[\s\S]))*"/,greedy:!0},variable:[{pattern:/(\$)(?:::)?(?:[a-zA-Z0-9]+::)*\w+/,lookbehind:!0},{pattern:/(\$)\{[^}]+\}/,lookbehind:!0},{pattern:/(^[\t ]*set[ \t]+)(?:::)?(?:[a-zA-Z0-9]+::)*\w+/m,lookbehind:!0}],function:{pattern:/(^[\t ]*proc[ \t]+)\S+/m,lookbehind:!0},builtin:[{pattern:/(^[\t ]*)(?:break|class|continue|error|eval|exit|for|foreach|if|proc|return|switch|while)\b/m,lookbehind:!0},/\b(?:else|elseif)\b/],scope:{pattern:/(^[\t ]*)(?:global|upvar|variable)\b/m,lookbehind:!0,alias:"constant"},keyword:{pattern:/(^[\t ]*|\[)(?:Safe_Base|Tcl|after|append|apply|array|auto_(?:execok|import|load|mkindex|qualify|reset)|automkindex_old|bgerror|binary|catch|cd|chan|clock|close|concat|dde|dict|encoding|eof|exec|expr|fblocked|fconfigure|fcopy|file(?:event|name)?|flush|gets|glob|history|http|incr|info|interp|join|lappend|lassign|lindex|linsert|list|llength|load|lrange|lrepeat|lreplace|lreverse|lsearch|lset|lsort|math(?:func|op)|memory|msgcat|namespace|open|package|parray|pid|pkg_mkIndex|platform|puts|pwd|re_syntax|read|refchan|regexp|registry|regsub|rename|scan|seek|set|socket|source|split|string|subst|tcl(?:_endOfWord|_findLibrary|startOf(?:Next|Previous)Word|test|vars|wordBreak(?:After|Before))|tell|time|tm|trace|unknown|unload|unset|update|uplevel|vwait)\b/m,lookbehind:!0},operator:/!=?|\*\*?|==|&&?|\|\|?|<[=<]?|>[=>]?|[-+~\/%?^]|\b(?:eq|in|ne|ni)\b/,punctuation:/[{}()\[\]]/}}return tcl_1}var textile_1,hasRequiredTextile;function requireTextile(){if(hasRequiredTextile)return textile_1;hasRequiredTextile=1,textile_1=e,e.displayName="textile",e.aliases=[];function e(t){(function(Ye){var tt=/\([^|()\n]+\)|\[[^\]\n]+\]|\{[^}\n]+\}/.source,rt=/\)|\((?![^|()\n]+\))/.source;function nt(qt,Ft){return RegExp(qt.replace(/<MOD>/g,function(){return"(?:"+tt+")"}).replace(/<PAR>/g,function(){return"(?:"+rt+")"}),Ft||"")}var at={css:{pattern:/\{[^{}]+\}/,inside:{rest:Ye.languages.css}},"class-id":{pattern:/(\()[^()]+(?=\))/,lookbehind:!0,alias:"attr-value"},lang:{pattern:/(\[)[^\[\]]+(?=\])/,lookbehind:!0,alias:"attr-value"},punctuation:/[\\\/]\d+|\S/},it=Ye.languages.textile=Ye.languages.extend("markup",{phrase:{pattern:/(^|\r|\n)\S[\s\S]*?(?=$|\r?\n\r?\n|\r\r)/,lookbehind:!0,inside:{"block-tag":{pattern:nt(/^[a-z]\w*(?:<MOD>|<PAR>|[<>=])*\./.source),inside:{modifier:{pattern:nt(/(^[a-z]\w*)(?:<MOD>|<PAR>|[<>=])+(?=\.)/.source),lookbehind:!0,inside:at},tag:/^[a-z]\w*/,punctuation:/\.$/}},list:{pattern:nt(/^[*#]+<MOD>*\s+\S.*/.source,"m"),inside:{modifier:{pattern:nt(/(^[*#]+)<MOD>+/.source),lookbehind:!0,inside:at},punctuation:/^[*#]+/}},table:{pattern:nt(/^(?:(?:<MOD>|<PAR>|[<>=^~])+\.\s*)?(?:\|(?:(?:<MOD>|<PAR>|[<>=^~_]|[\\/]\d+)+\.|(?!(?:<MOD>|<PAR>|[<>=^~_]|[\\/]\d+)+\.))[^|]*)+\|/.source,"m"),inside:{modifier:{pattern:nt(/(^|\|(?:\r?\n|\r)?)(?:<MOD>|<PAR>|[<>=^~_]|[\\/]\d+)+(?=\.)/.source),lookbehind:!0,inside:at},punctuation:/\||^\./}},inline:{pattern:nt(/(^|[^a-zA-Z\d])(\*\*|__|\?\?|[*_%@+\-^~])<MOD>*.+?\2(?![a-zA-Z\d])/.source),lookbehind:!0,inside:{bold:{pattern:nt(/(^(\*\*?)<MOD>*).+?(?=\2)/.source),lookbehind:!0},italic:{pattern:nt(/(^(__?)<MOD>*).+?(?=\2)/.source),lookbehind:!0},cite:{pattern:nt(/(^\?\?<MOD>*).+?(?=\?\?)/.source),lookbehind:!0,alias:"string"},code:{pattern:nt(/(^@<MOD>*).+?(?=@)/.source),lookbehind:!0,alias:"keyword"},inserted:{pattern:nt(/(^\+<MOD>*).+?(?=\+)/.source),lookbehind:!0},deleted:{pattern:nt(/(^-<MOD>*).+?(?=-)/.source),lookbehind:!0},span:{pattern:nt(/(^%<MOD>*).+?(?=%)/.source),lookbehind:!0},modifier:{pattern:nt(/(^\*\*|__|\?\?|[*_%@+\-^~])<MOD>+/.source),lookbehind:!0,inside:at},punctuation:/[*_%?@+\-^~]+/}},"link-ref":{pattern:/^\[[^\]]+\]\S+$/m,inside:{string:{pattern:/(^\[)[^\]]+(?=\])/,lookbehind:!0},url:{pattern:/(^\])\S+$/,lookbehind:!0},punctuation:/[\[\]]/}},link:{pattern:nt(/"<MOD>*[^"]+":.+?(?=[^\w/]?(?:\s|$))/.source),inside:{text:{pattern:nt(/(^"<MOD>*)[^"]+(?=")/.source),lookbehind:!0},modifier:{pattern:nt(/(^")<MOD>+/.source),lookbehind:!0,inside:at},url:{pattern:/(:).+/,lookbehind:!0},punctuation:/[":]/}},image:{pattern:nt(/!(?:<MOD>|<PAR>|[<>=])*(?![<>=])[^!\s()]+(?:\([^)]+\))?!(?::.+?(?=[^\w/]?(?:\s|$)))?/.source),inside:{source:{pattern:nt(/(^!(?:<MOD>|<PAR>|[<>=])*)(?![<>=])[^!\s()]+(?:\([^)]+\))?(?=!)/.source),lookbehind:!0,alias:"url"},modifier:{pattern:nt(/(^!)(?:<MOD>|<PAR>|[<>=])+/.source),lookbehind:!0,inside:at},url:{pattern:/(:).+/,lookbehind:!0},punctuation:/[!:]/}},footnote:{pattern:/\b\[\d+\]/,alias:"comment",inside:{punctuation:/\[|\]/}},acronym:{pattern:/\b[A-Z\d]+\([^)]+\)/,inside:{comment:{pattern:/(\()[^()]+(?=\))/,lookbehind:!0},punctuation:/[()]/}},mark:{pattern:/\b\((?:C|R|TM)\)/,alias:"comment",inside:{punctuation:/[()]/}}}}}),ot=it.phrase.inside,ct={inline:ot.inline,link:ot.link,image:ot.image,footnote:ot.footnote,acronym:ot.acronym,mark:ot.mark};it.tag.pattern=/<\/?(?!\d)[a-z0-9]+(?:\s+[^\s>\/=]+(?:=(?:("|')(?:\\[\s\S]|(?!\1)[^\\])*\1|[^\s'">=]+))?)*\s*\/?>/i;var At=ot.inline.inside;At.bold.inside=ct,At.italic.inside=ct,At.inserted.inside=ct,At.deleted.inside=ct,At.span.inside=ct;var Rt=ot.table.inside;Rt.inline=ct.inline,Rt.link=ct.link,Rt.image=ct.image,Rt.footnote=ct.footnote,Rt.acronym=ct.acronym,Rt.mark=ct.mark})(t)}return textile_1}var toml_1,hasRequiredToml;function requireToml(){if(hasRequiredToml)return toml_1;hasRequiredToml=1,toml_1=e,e.displayName="toml",e.aliases=[];function e(t){(function(Ye){var tt=/(?:[\w-]+|'[^'\n\r]*'|"(?:\\.|[^\\"\r\n])*")/.source;function rt(nt){return nt.replace(/__/g,function(){return tt})}Ye.languages.toml={comment:{pattern:/#.*/,greedy:!0},table:{pattern:RegExp(rt(/(^[\t ]*\[\s*(?:\[\s*)?)__(?:\s*\.\s*__)*(?=\s*\])/.source),"m"),lookbehind:!0,greedy:!0,alias:"class-name"},key:{pattern:RegExp(rt(/(^[\t ]*|[{,]\s*)__(?:\s*\.\s*__)*(?=\s*=)/.source),"m"),lookbehind:!0,greedy:!0,alias:"property"},string:{pattern:/"""(?:\\[\s\S]|[^\\])*?"""|'''[\s\S]*?'''|'[^'\n\r]*'|"(?:\\.|[^\\"\r\n])*"/,greedy:!0},date:[{pattern:/\b\d{4}-\d{2}-\d{2}(?:[T\s]\d{2}:\d{2}:\d{2}(?:\.\d+)?(?:Z|[+-]\d{2}:\d{2})?)?\b/i,alias:"number"},{pattern:/\b\d{2}:\d{2}:\d{2}(?:\.\d+)?\b/,alias:"number"}],number:/(?:\b0(?:x[\da-zA-Z]+(?:_[\da-zA-Z]+)*|o[0-7]+(?:_[0-7]+)*|b[10]+(?:_[10]+)*))\b|[-+]?\b\d+(?:_\d+)*(?:\.\d+(?:_\d+)*)?(?:[eE][+-]?\d+(?:_\d+)*)?\b|[-+]?\b(?:inf|nan)\b/,boolean:/\b(?:false|true)\b/,punctuation:/[.,=[\]{}]/}})(t)}return toml_1}var tremor_1,hasRequiredTremor;function requireTremor(){if(hasRequiredTremor)return tremor_1;hasRequiredTremor=1,tremor_1=e,e.displayName="tremor",e.aliases=[];function e(t){(function(Ye){Ye.languages.tremor={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:--|\/\/|#).*)/,lookbehind:!0},"interpolated-string":null,extractor:{pattern:/\b[a-z_]\w*\|(?:[^\r\n\\|]|\\(?:\r\n|[\s\S]))*\|/i,greedy:!0,inside:{regex:{pattern:/(^re)\|[\s\S]+/,lookbehind:!0},function:/^\w+/,value:/\|[\s\S]+/}},identifier:{pattern:/`[^`]*`/,greedy:!0},function:/\b[a-z_]\w*(?=\s*(?:::\s*<|\())\b/,keyword:/\b(?:args|as|by|case|config|connect|connector|const|copy|create|default|define|deploy|drop|each|emit|end|erase|event|flow|fn|for|from|group|having|insert|into|intrinsic|let|links|match|merge|mod|move|of|operator|patch|pipeline|recur|script|select|set|sliding|state|stream|to|tumbling|update|use|when|where|window|with)\b/,boolean:/\b(?:false|null|true)\b/i,number:/\b(?:0b[01_]*|0x[0-9a-fA-F_]*|\d[\d_]*(?:\.\d[\d_]*)?(?:[Ee][+-]?[\d_]+)?)\b/,"pattern-punctuation":{pattern:/%(?=[({[])/,alias:"punctuation"},operator:/[-+*\/%~!^]=?|=[=>]?|&[&=]?|\|[|=]?|<<?=?|>>?>?=?|(?:absent|and|not|or|present|xor)\b/,punctuation:/::|[;\[\]()\{\},.:]/};var tt=/#\{(?:[^"{}]|\{[^{}]*\}|"(?:[^"\\\r\n]|\\(?:\r\n|[\s\S]))*")*\}/.source;Ye.languages.tremor["interpolated-string"]={pattern:RegExp(/(^|[^\\])/.source+'(?:"""(?:'+/[^"\\#]|\\[\s\S]|"(?!"")|#(?!\{)/.source+"|"+tt+')*"""|"(?:'+/[^"\\\r\n#]|\\(?:\r\n|[\s\S])|#(?!\{)/.source+"|"+tt+')*")'),lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:RegExp(tt),inside:{punctuation:/^#\{|\}$/,expression:{pattern:/[\s\S]+/,inside:Ye.languages.tremor}}},string:/[\s\S]+/}},Ye.languages.troy=Ye.languages.tremor,Ye.languages.trickle=Ye.languages.tremor})(t)}return tremor_1}var tsx_1,hasRequiredTsx;function requireTsx(){if(hasRequiredTsx)return tsx_1;hasRequiredTsx=1;var e=requireJsx(),t=requireTypescript();tsx_1=Ye,Ye.displayName="tsx",Ye.aliases=[];function Ye(tt){tt.register(e),tt.register(t),function(rt){var nt=rt.util.clone(rt.languages.typescript);rt.languages.tsx=rt.languages.extend("jsx",nt),delete rt.languages.tsx.parameter,delete rt.languages.tsx["literal-property"];var at=rt.languages.tsx.tag;at.pattern=RegExp(/(^|[^\w$]|(?=<\/))/.source+"(?:"+at.pattern.source+")",at.pattern.flags),at.lookbehind=!0}(tt)}return tsx_1}var tt2_1,hasRequiredTt2;function requireTt2(){if(hasRequiredTt2)return tt2_1;hasRequiredTt2=1;var e=requireMarkupTemplating();tt2_1=t,t.displayName="tt2",t.aliases=[];function t(Ye){Ye.register(e),function(tt){tt.languages.tt2=tt.languages.extend("clike",{comment:/#.*|\[%#[\s\S]*?%\]/,keyword:/\b(?:BLOCK|CALL|CASE|CATCH|CLEAR|DEBUG|DEFAULT|ELSE|ELSIF|END|FILTER|FINAL|FOREACH|GET|IF|IN|INCLUDE|INSERT|LAST|MACRO|META|NEXT|PERL|PROCESS|RAWPERL|RETURN|SET|STOP|SWITCH|TAGS|THROW|TRY|UNLESS|USE|WHILE|WRAPPER)\b/,punctuation:/[[\]{},()]/}),tt.languages.insertBefore("tt2","number",{operator:/=[>=]?|!=?|<=?|>=?|&&|\|\|?|\b(?:and|not|or)\b/,variable:{pattern:/\b[a-z]\w*(?:\s*\.\s*(?:\d+|\$?[a-z]\w*))*\b/i}}),tt.languages.insertBefore("tt2","keyword",{delimiter:{pattern:/^(?:\[%|%%)-?|-?%\]$/,alias:"punctuation"}}),tt.languages.insertBefore("tt2","string",{"single-quoted-string":{pattern:/'[^\\']*(?:\\[\s\S][^\\']*)*'/,greedy:!0,alias:"string"},"double-quoted-string":{pattern:/"[^\\"]*(?:\\[\s\S][^\\"]*)*"/,greedy:!0,alias:"string",inside:{variable:{pattern:/\$(?:[a-z]\w*(?:\.(?:\d+|\$?[a-z]\w*))*)/i}}}}),delete tt.languages.tt2.string,tt.hooks.add("before-tokenize",function(rt){var nt=/\[%[\s\S]+?%\]/g;tt.languages["markup-templating"].buildPlaceholders(rt,"tt2",nt)}),tt.hooks.add("after-tokenize",function(rt){tt.languages["markup-templating"].tokenizePlaceholders(rt,"tt2")})}(Ye)}return tt2_1}var twig_1,hasRequiredTwig;function requireTwig(){if(hasRequiredTwig)return twig_1;hasRequiredTwig=1;var e=requireMarkupTemplating();twig_1=t,t.displayName="twig",t.aliases=[];function t(Ye){Ye.register(e),Ye.languages.twig={comment:/^\{#[\s\S]*?#\}$/,"tag-name":{pattern:/(^\{%-?\s*)\w+/,lookbehind:!0,alias:"keyword"},delimiter:{pattern:/^\{[{%]-?|-?[%}]\}$/,alias:"punctuation"},string:{pattern:/("|')(?:\\.|(?!\1)[^\\\r\n])*\1/,inside:{punctuation:/^['"]|['"]$/}},keyword:/\b(?:even|if|odd)\b/,boolean:/\b(?:false|null|true)\b/,number:/\b0x[\dA-Fa-f]+|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[Ee][-+]?\d+)?/,operator:[{pattern:/(\s)(?:and|b-and|b-or|b-xor|ends with|in|is|matches|not|or|same as|starts with)(?=\s)/,lookbehind:!0},/[=<>]=?|!=|\*\*?|\/\/?|\?:?|[-+~%|]/],punctuation:/[()\[\]{}:.,]/},Ye.hooks.add("before-tokenize",function(tt){if(tt.language==="twig"){var rt=/\{(?:#[\s\S]*?#|%[\s\S]*?%|\{[\s\S]*?\})\}/g;Ye.languages["markup-templating"].buildPlaceholders(tt,"twig",rt)}}),Ye.hooks.add("after-tokenize",function(tt){Ye.languages["markup-templating"].tokenizePlaceholders(tt,"twig")})}return twig_1}var typoscript_1,hasRequiredTyposcript;function requireTyposcript(){if(hasRequiredTyposcript)return typoscript_1;hasRequiredTyposcript=1,typoscript_1=e,e.displayName="typoscript",e.aliases=["tsconfig"];function e(t){(function(Ye){var tt=/\b(?:ACT|ACTIFSUB|CARRAY|CASE|CLEARGIF|COA|COA_INT|CONSTANTS|CONTENT|CUR|EDITPANEL|EFFECT|EXT|FILE|FLUIDTEMPLATE|FORM|FRAME|FRAMESET|GIFBUILDER|GMENU|GMENU_FOLDOUT|GMENU_LAYERS|GP|HMENU|HRULER|HTML|IENV|IFSUB|IMAGE|IMGMENU|IMGMENUITEM|IMGTEXT|IMG_RESOURCE|INCLUDE_TYPOSCRIPT|JSMENU|JSMENUITEM|LLL|LOAD_REGISTER|NO|PAGE|RECORDS|RESTORE_REGISTER|TEMPLATE|TEXT|TMENU|TMENUITEM|TMENU_LAYERS|USER|USER_INT|_GIFBUILDER|global|globalString|globalVar)\b/;Ye.languages.typoscript={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0},{pattern:/(^|[^\\:= \t]|(?:^|[^= \t])[ \t]+)\/\/.*/,lookbehind:!0,greedy:!0},{pattern:/(^|[^"'])#.*/,lookbehind:!0,greedy:!0}],function:[{pattern:/<INCLUDE_TYPOSCRIPT:\s*source\s*=\s*(?:"[^"\r\n]*"|'[^'\r\n]*')\s*>/,inside:{string:{pattern:/"[^"\r\n]*"|'[^'\r\n]*'/,inside:{keyword:tt}},keyword:{pattern:/INCLUDE_TYPOSCRIPT/}}},{pattern:/@import\s*(?:"[^"\r\n]*"|'[^'\r\n]*')/,inside:{string:/"[^"\r\n]*"|'[^'\r\n]*'/}}],string:{pattern:/^([^=]*=[< ]?)(?:(?!\]\n).)*/,lookbehind:!0,inside:{function:/\{\$.*\}/,keyword:tt,number:/^\d+$/,punctuation:/[,|:]/}},keyword:tt,number:{pattern:/\b\d+\s*[.{=]/,inside:{operator:/[.{=]/}},tag:{pattern:/\.?[-\w\\]+\.?/,inside:{punctuation:/\./}},punctuation:/[{}[\];(),.:|]/,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/},Ye.languages.tsconfig=Ye.languages.typoscript})(t)}return typoscript_1}var unrealscript_1,hasRequiredUnrealscript;function requireUnrealscript(){if(hasRequiredUnrealscript)return unrealscript_1;hasRequiredUnrealscript=1,unrealscript_1=e,e.displayName="unrealscript",e.aliases=["uc","uscript"];function e(t){t.languages.unrealscript={comment:/\/\/.*|\/\*[\s\S]*?\*\//,string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},category:{pattern:/(\b(?:(?:autoexpand|hide|show)categories|var)\s*\()[^()]+(?=\))/,lookbehind:!0,greedy:!0,alias:"property"},metadata:{pattern:/(\w\s*)<\s*\w+\s*=[^<>|=\r\n]+(?:\|\s*\w+\s*=[^<>|=\r\n]+)*>/,lookbehind:!0,greedy:!0,inside:{property:/\b\w+(?=\s*=)/,operator:/=/,punctuation:/[<>|]/}},macro:{pattern:/`\w+/,alias:"property"},"class-name":{pattern:/(\b(?:class|enum|extends|interface|state(?:\(\))?|struct|within)\s+)\w+/,lookbehind:!0},keyword:/\b(?:abstract|actor|array|auto|autoexpandcategories|bool|break|byte|case|class|classgroup|client|coerce|collapsecategories|config|const|continue|default|defaultproperties|delegate|dependson|deprecated|do|dontcollapsecategories|editconst|editinlinenew|else|enum|event|exec|export|extends|final|float|for|forcescriptorder|foreach|function|goto|guid|hidecategories|hidedropdown|if|ignores|implements|inherits|input|int|interface|iterator|latent|local|material|name|native|nativereplication|noexport|nontransient|noteditinlinenew|notplaceable|operator|optional|out|pawn|perobjectconfig|perobjectlocalized|placeable|postoperator|preoperator|private|protected|reliable|replication|return|server|showcategories|simulated|singular|state|static|string|struct|structdefault|structdefaultproperties|switch|texture|transient|travel|unreliable|until|var|vector|while|within)\b/,function:/\b[a-z_]\w*(?=\s*\()/i,boolean:/\b(?:false|true)\b/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/>>|<<|--|\+\+|\*\*|[-+*/~!=<>$@]=?|&&?|\|\|?|\^\^?|[?:%]|\b(?:ClockwiseFrom|Cross|Dot)\b/,punctuation:/[()[\]{};,.]/},t.languages.uc=t.languages.uscript=t.languages.unrealscript}return unrealscript_1}var uorazor_1,hasRequiredUorazor;function requireUorazor(){if(hasRequiredUorazor)return uorazor_1;hasRequiredUorazor=1,uorazor_1=e,e.displayName="uorazor",e.aliases=[];function e(t){t.languages.uorazor={"comment-hash":{pattern:/#.*/,alias:"comment",greedy:!0},"comment-slash":{pattern:/\/\/.*/,alias:"comment",greedy:!0},string:{pattern:/("|')(?:\\.|(?!\1)[^\\\r\n])*\1/,inside:{punctuation:/^['"]|['"]$/},greedy:!0},"source-layers":{pattern:/\b(?:arms|backpack|blue|bracelet|cancel|clear|cloak|criminal|earrings|enemy|facialhair|friend|friendly|gloves|gray|grey|ground|hair|head|innerlegs|innertorso|innocent|lefthand|middletorso|murderer|neck|nonfriendly|onehandedsecondary|outerlegs|outertorso|pants|red|righthand|ring|self|shirt|shoes|talisman|waist)\b/i,alias:"function"},"source-commands":{pattern:/\b(?:alliance|attack|cast|clearall|clearignore|clearjournal|clearlist|clearsysmsg|createlist|createtimer|dclick|dclicktype|dclickvar|dress|dressconfig|drop|droprelloc|emote|getlabel|guild|gumpclose|gumpresponse|hotkey|ignore|lasttarget|lift|lifttype|menu|menuresponse|msg|org|organize|organizer|overhead|pause|poplist|potion|promptresponse|pushlist|removelist|removetimer|rename|restock|say|scav|scavenger|script|setability|setlasttarget|setskill|settimer|setvar|sysmsg|target|targetloc|targetrelloc|targettype|undress|unignore|unsetvar|useobject|useonce|useskill|usetype|virtue|wait|waitforgump|waitformenu|waitforprompt|waitforstat|waitforsysmsg|waitfortarget|walk|wfsysmsg|wft|whisper|yell)\b/,alias:"function"},"tag-name":{pattern:/(^\{%-?\s*)\w+/,lookbehind:!0,alias:"keyword"},delimiter:{pattern:/^\{[{%]-?|-?[%}]\}$/,alias:"punctuation"},function:/\b(?:atlist|close|closest|count|counter|counttype|dead|dex|diffhits|diffmana|diffstam|diffweight|find|findbuff|finddebuff|findlayer|findtype|findtypelist|followers|gumpexists|hidden|hits|hp|hue|human|humanoid|ingump|inlist|insysmessage|insysmsg|int|invul|lhandempty|list|listexists|mana|maxhits|maxhp|maxmana|maxstam|maxweight|monster|mounted|name|next|noto|paralyzed|poisoned|position|prev|previous|queued|rand|random|rhandempty|skill|stam|str|targetexists|timer|timerexists|varexist|warmode|weight)\b/,keyword:/\b(?:and|as|break|continue|else|elseif|endfor|endif|endwhile|for|if|loop|not|or|replay|stop|while)\b/,boolean:/\b(?:false|null|true)\b/,number:/\b0x[\dA-Fa-f]+|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[Ee][-+]?\d+)?/,operator:[{pattern:/(\s)(?:and|b-and|b-or|b-xor|ends with|in|is|matches|not|or|same as|starts with)(?=\s)/,lookbehind:!0},/[=<>]=?|!=|\*\*?|\/\/?|\?:?|[-+~%|]/],punctuation:/[()\[\]{}:.,]/}}return uorazor_1}var uri_1,hasRequiredUri$1;function requireUri$1(){if(hasRequiredUri$1)return uri_1;hasRequiredUri$1=1,uri_1=e,e.displayName="uri",e.aliases=["url"];function e(t){t.languages.uri={scheme:{pattern:/^[a-z][a-z0-9+.-]*:/im,greedy:!0,inside:{"scheme-delimiter":/:$/}},fragment:{pattern:/#[\w\-.~!$&'()*+,;=%:@/?]*/,inside:{"fragment-delimiter":/^#/}},query:{pattern:/\?[\w\-.~!$&'()*+,;=%:@/?]*/,inside:{"query-delimiter":{pattern:/^\?/,greedy:!0},"pair-delimiter":/[&;]/,pair:{pattern:/^[^=][\s\S]*/,inside:{key:/^[^=]+/,value:{pattern:/(^=)[\s\S]+/,lookbehind:!0}}}}},authority:{pattern:RegExp(/^\/\//.source+/(?:[\w\-.~!$&'()*+,;=%:]*@)?/.source+("(?:"+/\[(?:[0-9a-fA-F:.]{2,48}|v[0-9a-fA-F]+\.[\w\-.~!$&'()*+,;=]+)\]/.source+"|"+/[\w\-.~!$&'()*+,;=%]*/.source+")")+/(?::\d*)?/.source,"m"),inside:{"authority-delimiter":/^\/\//,"user-info-segment":{pattern:/^[\w\-.~!$&'()*+,;=%:]*@/,inside:{"user-info-delimiter":/@$/,"user-info":/^[\w\-.~!$&'()*+,;=%:]+/}},"port-segment":{pattern:/:\d*$/,inside:{"port-delimiter":/^:/,port:/^\d+/}},host:{pattern:/[\s\S]+/,inside:{"ip-literal":{pattern:/^\[[\s\S]+\]$/,inside:{"ip-literal-delimiter":/^\[|\]$/,"ipv-future":/^v[\s\S]+/,"ipv6-address":/^[\s\S]+/}},"ipv4-address":/^(?:(?:[03-9]\d?|[12]\d{0,2})\.){3}(?:[03-9]\d?|[12]\d{0,2})$/}}}},path:{pattern:/^[\w\-.~!$&'()*+,;=%:@/]+/m,inside:{"path-separator":/\//}}},t.languages.url=t.languages.uri}return uri_1}var v_1,hasRequiredV;function requireV(){if(hasRequiredV)return v_1;hasRequiredV=1,v_1=e,e.displayName="v",e.aliases=[];function e(t){(function(Ye){var tt={pattern:/[\s\S]+/,inside:null};Ye.languages.v=Ye.languages.extend("clike",{string:{pattern:/r?(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,alias:"quoted-string",greedy:!0,inside:{interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$(?:\{[^{}]*\}|\w+(?:\.\w+(?:\([^\(\)]*\))?|\[[^\[\]]+\])*)/,lookbehind:!0,inside:{"interpolation-variable":{pattern:/^\$\w[\s\S]*$/,alias:"variable"},"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},"interpolation-expression":tt}}}},"class-name":{pattern:/(\b(?:enum|interface|struct|type)\s+)(?:C\.)?\w+/,lookbehind:!0},keyword:/(?:\b(?:__global|as|asm|assert|atomic|break|chan|const|continue|defer|else|embed|enum|fn|for|go(?:to)?|if|import|in|interface|is|lock|match|module|mut|none|or|pub|return|rlock|select|shared|sizeof|static|struct|type(?:of)?|union|unsafe)|\$(?:else|for|if)|#(?:flag|include))\b/,number:/\b(?:0x[a-f\d]+(?:_[a-f\d]+)*|0b[01]+(?:_[01]+)*|0o[0-7]+(?:_[0-7]+)*|\d+(?:_\d+)*(?:\.\d+(?:_\d+)*)?)\b/i,operator:/~|\?|[*\/%^!=]=?|\+[=+]?|-[=-]?|\|[=|]?|&(?:=|&|\^=?)?|>(?:>=?|=)?|<(?:<=?|=|-)?|:=|\.\.\.?/,builtin:/\b(?:any(?:_float|_int)?|bool|byte(?:ptr)?|charptr|f(?:32|64)|i(?:8|16|64|128|nt)|rune|size_t|string|u(?:16|32|64|128)|voidptr)\b/}),tt.inside=Ye.languages.v,Ye.languages.insertBefore("v","string",{char:{pattern:/`(?:\\`|\\?[^`]{1,2})`/,alias:"rune"}}),Ye.languages.insertBefore("v","operator",{attribute:{pattern:/(^[\t ]*)\[(?:deprecated|direct_array_access|flag|inline|live|ref_only|typedef|unsafe_fn|windows_stdcall)\]/m,lookbehind:!0,alias:"annotation",inside:{punctuation:/[\[\]]/,keyword:/\w+/}},generic:{pattern:/<\w+>(?=\s*[\)\{])/,inside:{punctuation:/[<>]/,"class-name":/\w+/}}}),Ye.languages.insertBefore("v","function",{"generic-function":{pattern:/\b\w+\s*<\w+>(?=\()/,inside:{function:/^\w+/,generic:{pattern:/<\w+>/,inside:Ye.languages.v.generic.inside}}}})})(t)}return v_1}var vala_1,hasRequiredVala;function requireVala(){if(hasRequiredVala)return vala_1;hasRequiredVala=1,vala_1=e,e.displayName="vala",e.aliases=[];function e(t){t.languages.vala=t.languages.extend("clike",{"class-name":[{pattern:/\b[A-Z]\w*(?:\.\w+)*\b(?=(?:\?\s+|\*?\s+\*?)\w)/,inside:{punctuation:/\./}},{pattern:/(\[)[A-Z]\w*(?:\.\w+)*\b/,lookbehind:!0,inside:{punctuation:/\./}},{pattern:/(\b(?:class|interface)\s+[A-Z]\w*(?:\.\w+)*\s*:\s*)[A-Z]\w*(?:\.\w+)*\b/,lookbehind:!0,inside:{punctuation:/\./}},{pattern:/((?:\b(?:class|enum|interface|new|struct)\s+)|(?:catch\s+\())[A-Z]\w*(?:\.\w+)*\b/,lookbehind:!0,inside:{punctuation:/\./}}],keyword:/\b(?:abstract|as|assert|async|base|bool|break|case|catch|char|class|const|construct|continue|default|delegate|delete|do|double|dynamic|else|ensures|enum|errordomain|extern|finally|float|for|foreach|get|if|in|inline|int|int16|int32|int64|int8|interface|internal|is|lock|long|namespace|new|null|out|override|owned|params|private|protected|public|ref|requires|return|set|short|signal|sizeof|size_t|ssize_t|static|string|struct|switch|this|throw|throws|try|typeof|uchar|uint|uint16|uint32|uint64|uint8|ulong|unichar|unowned|ushort|using|value|var|virtual|void|volatile|weak|while|yield)\b/i,function:/\b\w+(?=\s*\()/,number:/(?:\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?)(?:f|u?l?)?/i,operator:/\+\+|--|&&|\|\||<<=?|>>=?|=>|->|~|[+\-*\/%&^|=!<>]=?|\?\??|\.\.\./,punctuation:/[{}[\];(),.:]/,constant:/\b[A-Z0-9_]+\b/}),t.languages.insertBefore("vala","string",{"raw-string":{pattern:/"""[\s\S]*?"""/,greedy:!0,alias:"string"},"template-string":{pattern:/@"[\s\S]*?"/,greedy:!0,inside:{interpolation:{pattern:/\$(?:\([^)]*\)|[a-zA-Z]\w*)/,inside:{delimiter:{pattern:/^\$\(?|\)$/,alias:"punctuation"},rest:t.languages.vala}},string:/[\s\S]+/}}}),t.languages.insertBefore("vala","keyword",{regex:{pattern:/\/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[imsx]{0,4}(?=\s*(?:$|[\r\n,.;})\]]))/,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:t.languages.regex},"regex-delimiter":/^\//,"regex-flags":/^[a-z]+$/}}})}return vala_1}var velocity_1,hasRequiredVelocity;function requireVelocity(){if(hasRequiredVelocity)return velocity_1;hasRequiredVelocity=1,velocity_1=e,e.displayName="velocity",e.aliases=[];function e(t){(function(Ye){Ye.languages.velocity=Ye.languages.extend("markup",{});var tt={variable:{pattern:/(^|[^\\](?:\\\\)*)\$!?(?:[a-z][\w-]*(?:\([^)]*\))?(?:\.[a-z][\w-]*(?:\([^)]*\))?|\[[^\]]+\])*|\{[^}]+\})/i,lookbehind:!0,inside:{}},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},number:/\b\d+\b/,boolean:/\b(?:false|true)\b/,operator:/[=!<>]=?|[+*/%-]|&&|\|\||\.\.|\b(?:eq|g[et]|l[et]|n(?:e|ot))\b/,punctuation:/[(){}[\]:,.]/};tt.variable.inside={string:tt.string,function:{pattern:/([^\w-])[a-z][\w-]*(?=\()/,lookbehind:!0},number:tt.number,boolean:tt.boolean,punctuation:tt.punctuation},Ye.languages.insertBefore("velocity","comment",{unparsed:{pattern:/(^|[^\\])#\[\[[\s\S]*?\]\]#/,lookbehind:!0,greedy:!0,inside:{punctuation:/^#\[\[|\]\]#$/}},"velocity-comment":[{pattern:/(^|[^\\])#\*[\s\S]*?\*#/,lookbehind:!0,greedy:!0,alias:"comment"},{pattern:/(^|[^\\])##.*/,lookbehind:!0,greedy:!0,alias:"comment"}],directive:{pattern:/(^|[^\\](?:\\\\)*)#@?(?:[a-z][\w-]*|\{[a-z][\w-]*\})(?:\s*\((?:[^()]|\([^()]*\))*\))?/i,lookbehind:!0,inside:{keyword:{pattern:/^#@?(?:[a-z][\w-]*|\{[a-z][\w-]*\})|\bin\b/,inside:{punctuation:/[{}]/}},rest:tt}},variable:tt.variable}),Ye.languages.velocity.tag.inside["attr-value"].inside.rest=Ye.languages.velocity})(t)}return velocity_1}var verilog_1,hasRequiredVerilog;function requireVerilog(){if(hasRequiredVerilog)return verilog_1;hasRequiredVerilog=1,verilog_1=e,e.displayName="verilog",e.aliases=[];function e(t){t.languages.verilog={comment:{pattern:/\/\/.*|\/\*[\s\S]*?\*\//,greedy:!0},string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},"kernel-function":{pattern:/\B\$\w+\b/,alias:"property"},constant:/\B`\w+\b/,function:/\b\w+(?=\()/,keyword:/\b(?:alias|and|assert|assign|assume|automatic|before|begin|bind|bins|binsof|bit|break|buf|bufif0|bufif1|byte|case|casex|casez|cell|chandle|class|clocking|cmos|config|const|constraint|context|continue|cover|covergroup|coverpoint|cross|deassign|default|defparam|design|disable|dist|do|edge|else|end|endcase|endclass|endclocking|endconfig|endfunction|endgenerate|endgroup|endinterface|endmodule|endpackage|endprimitive|endprogram|endproperty|endsequence|endspecify|endtable|endtask|enum|event|expect|export|extends|extern|final|first_match|for|force|foreach|forever|fork|forkjoin|function|generate|genvar|highz0|highz1|if|iff|ifnone|ignore_bins|illegal_bins|import|incdir|include|initial|inout|input|inside|instance|int|integer|interface|intersect|join|join_any|join_none|large|liblist|library|local|localparam|logic|longint|macromodule|matches|medium|modport|module|nand|negedge|new|nmos|nor|noshowcancelled|not|notif0|notif1|null|or|output|package|packed|parameter|pmos|posedge|primitive|priority|program|property|protected|pull0|pull1|pulldown|pullup|pulsestyle_ondetect|pulsestyle_onevent|pure|rand|randc|randcase|randsequence|rcmos|real|realtime|ref|reg|release|repeat|return|rnmos|rpmos|rtran|rtranif0|rtranif1|scalared|sequence|shortint|shortreal|showcancelled|signed|small|solve|specify|specparam|static|string|strong0|strong1|struct|super|supply0|supply1|table|tagged|task|this|throughout|time|timeprecision|timeunit|tran|tranif0|tranif1|tri|tri0|tri1|triand|trior|trireg|type|typedef|union|unique|unsigned|use|uwire|var|vectored|virtual|void|wait|wait_order|wand|weak0|weak1|while|wildcard|wire|with|within|wor|xnor|xor)\b/,important:/\b(?:always|always_comb|always_ff|always_latch)\b(?: *@)?/,number:/\B##?\d+|(?:\b\d+)?'[odbh] ?[\da-fzx_?]+|\b(?:\d*[._])?\d+(?:e[-+]?\d+)?/i,operator:/[-+{}^~%*\/?=!<>&|]+/,punctuation:/[[\];(),.:]/}}return verilog_1}var vhdl_1,hasRequiredVhdl;function requireVhdl(){if(hasRequiredVhdl)return vhdl_1;hasRequiredVhdl=1,vhdl_1=e,e.displayName="vhdl",e.aliases=[];function e(t){t.languages.vhdl={comment:/--.+/,"vhdl-vectors":{pattern:/\b[oxb]"[\da-f_]+"|"[01uxzwlh-]+"/i,alias:"number"},"quoted-function":{pattern:/"\S+?"(?=\()/,alias:"function"},string:/"(?:[^\\"\r\n]|\\(?:\r\n|[\s\S]))*"/,constant:/\b(?:library|use)\b/i,keyword:/\b(?:'active|'ascending|'base|'delayed|'driving|'driving_value|'event|'high|'image|'instance_name|'last_active|'last_event|'last_value|'left|'leftof|'length|'low|'path_name|'pos|'pred|'quiet|'range|'reverse_range|'right|'rightof|'simple_name|'stable|'succ|'transaction|'val|'value|access|after|alias|all|architecture|array|assert|attribute|begin|block|body|buffer|bus|case|component|configuration|constant|disconnect|downto|else|elsif|end|entity|exit|file|for|function|generate|generic|group|guarded|if|impure|in|inertial|inout|is|label|library|linkage|literal|loop|map|new|next|null|of|on|open|others|out|package|port|postponed|procedure|process|pure|range|record|register|reject|report|return|select|severity|shared|signal|subtype|then|to|transport|type|unaffected|units|until|use|variable|wait|when|while|with)\b/i,boolean:/\b(?:false|true)\b/i,function:/\w+(?=\()/,number:/'[01uxzwlh-]'|\b(?:\d+#[\da-f_.]+#|\d[\d_.]*)(?:e[-+]?\d+)?/i,operator:/[<>]=?|:=|[-+*/&=]|\b(?:abs|and|mod|nand|nor|not|or|rem|rol|ror|sla|sll|sra|srl|xnor|xor)\b/i,punctuation:/[{}[\];(),.:]/}}return vhdl_1}var vim_1,hasRequiredVim;function requireVim(){if(hasRequiredVim)return vim_1;hasRequiredVim=1,vim_1=e,e.displayName="vim",e.aliases=[];function e(t){t.languages.vim={string:/"(?:[^"\\\r\n]|\\.)*"|'(?:[^'\r\n]|'')*'/,comment:/".*/,function:/\b\w+(?=\()/,keyword:/\b(?:N|Next|P|Print|X|XMLent|XMLns|ab|abbreviate|abc|abclear|abo|aboveleft|al|all|ar|arga|argadd|argd|argdelete|argdo|arge|argedit|argg|argglobal|argl|arglocal|args|argu|argument|as|ascii|b|bN|bNext|ba|bad|badd|ball|bd|bdelete|be|bel|belowright|bf|bfirst|bl|blast|bm|bmodified|bn|bnext|bo|botright|bp|bprevious|br|brea|break|breaka|breakadd|breakd|breakdel|breakl|breaklist|brewind|bro|browse|bufdo|buffer|buffers|bun|bunload|bw|bwipeout|c|cN|cNext|cNfcNfile|ca|cabbrev|cabc|cabclear|cad|caddb|caddbuffer|caddexpr|caddf|caddfile|cal|call|cat|catch|cb|cbuffer|cc|ccl|cclose|cd|ce|center|cex|cexpr|cf|cfile|cfir|cfirst|cg|cgetb|cgetbuffer|cgete|cgetexpr|cgetfile|change|changes|chd|chdir|che|checkpath|checkt|checktime|cl|cla|clast|clist|clo|close|cmapc|cmapclear|cn|cnew|cnewer|cnext|cnf|cnfile|cnorea|cnoreabbrev|co|col|colder|colo|colorscheme|comc|comclear|comp|compiler|con|conf|confirm|continue|cope|copen|copy|cp|cpf|cpfile|cprevious|cq|cquit|cr|crewind|cu|cuna|cunabbrev|cunmap|cw|cwindow|d|debugg|debuggreedy|delc|delcommand|delete|delf|delfunction|delm|delmarks|di|diffg|diffget|diffoff|diffpatch|diffpu|diffput|diffsplit|diffthis|diffu|diffupdate|dig|digraphs|display|dj|djump|dl|dlist|dr|drop|ds|dsearch|dsp|dsplit|e|earlier|echoe|echoerr|echom|echomsg|echon|edit|el|else|elsei|elseif|em|emenu|en|endf|endfo|endfor|endfun|endfunction|endif|endt|endtry|endw|endwhile|ene|enew|ex|exi|exit|exu|exusage|f|file|files|filetype|fin|fina|finally|find|fini|finish|fir|first|fix|fixdel|fo|fold|foldc|foldclose|foldd|folddoc|folddoclosed|folddoopen|foldo|foldopen|for|fu|fun|function|go|goto|gr|grep|grepa|grepadd|h|ha|hardcopy|help|helpf|helpfind|helpg|helpgrep|helpt|helptags|hid|hide|his|history|ia|iabbrev|iabc|iabclear|if|ij|ijump|il|ilist|imapc|imapclear|in|inorea|inoreabbrev|isearch|isp|isplit|iu|iuna|iunabbrev|iunmap|j|join|ju|jumps|k|kee|keepalt|keepj|keepjumps|keepmarks|l|lN|lNext|lNf|lNfile|la|lad|laddb|laddbuffer|laddexpr|laddf|laddfile|lan|language|last|later|lb|lbuffer|lc|lcd|lch|lchdir|lcl|lclose|left|lefta|leftabove|let|lex|lexpr|lf|lfile|lfir|lfirst|lg|lgetb|lgetbuffer|lgete|lgetexpr|lgetfile|lgr|lgrep|lgrepa|lgrepadd|lh|lhelpgrep|list|ll|lla|llast|lli|llist|lm|lmak|lmake|lmap|lmapc|lmapclear|ln|lne|lnew|lnewer|lnext|lnf|lnfile|lnoremap|lo|loadview|loc|lockmarks|lockv|lockvar|lol|lolder|lop|lopen|lp|lpf|lpfile|lprevious|lr|lrewind|ls|lt|ltag|lu|lunmap|lv|lvimgrep|lvimgrepa|lvimgrepadd|lw|lwindow|m|ma|mak|make|mark|marks|mat|match|menut|menutranslate|mk|mkexrc|mks|mksession|mksp|mkspell|mkv|mkvie|mkview|mkvimrc|mod|mode|move|mz|mzf|mzfile|mzscheme|n|nbkey|new|next|nmapc|nmapclear|noh|nohlsearch|norea|noreabbrev|nu|number|nun|nunmap|o|omapc|omapclear|on|only|open|opt|options|ou|ounmap|p|pc|pclose|pe|ped|pedit|perl|perld|perldo|po|pop|popu|popup|pp|ppop|pre|preserve|prev|previous|print|prof|profd|profdel|profile|promptf|promptfind|promptr|promptrepl|ps|psearch|ptN|ptNext|pta|ptag|ptf|ptfirst|ptj|ptjump|ptl|ptlast|ptn|ptnext|ptp|ptprevious|ptr|ptrewind|pts|ptselect|pu|put|pw|pwd|py|pyf|pyfile|python|q|qa|qall|quit|quita|quitall|r|read|rec|recover|red|redi|redir|redo|redr|redraw|redraws|redrawstatus|reg|registers|res|resize|ret|retab|retu|return|rew|rewind|ri|right|rightb|rightbelow|ru|rub|ruby|rubyd|rubydo|rubyf|rubyfile|runtime|rv|rviminfo|sN|sNext|sa|sal|sall|san|sandbox|sargument|sav|saveas|sb|sbN|sbNext|sba|sball|sbf|sbfirst|sbl|sblast|sbm|sbmodified|sbn|sbnext|sbp|sbprevious|sbr|sbrewind|sbuffer|scrip|scripte|scriptencoding|scriptnames|se|set|setf|setfiletype|setg|setglobal|setl|setlocal|sf|sfind|sfir|sfirst|sh|shell|sign|sil|silent|sim|simalt|sl|sla|slast|sleep|sm|smagic|smap|smapc|smapclear|sme|smenu|sn|snext|sni|sniff|sno|snomagic|snor|snoremap|snoreme|snoremenu|so|sor|sort|source|sp|spe|spelld|spelldump|spellgood|spelli|spellinfo|spellr|spellrepall|spellu|spellundo|spellw|spellwrong|split|spr|sprevious|sre|srewind|st|sta|stag|star|startg|startgreplace|startinsert|startr|startreplace|stj|stjump|stop|stopi|stopinsert|sts|stselect|sun|sunhide|sunm|sunmap|sus|suspend|sv|sview|syncbind|t|tN|tNext|ta|tab|tabN|tabNext|tabc|tabclose|tabd|tabdo|tabe|tabedit|tabf|tabfind|tabfir|tabfirst|tabl|tablast|tabm|tabmove|tabn|tabnew|tabnext|tabo|tabonly|tabp|tabprevious|tabr|tabrewind|tabs|tag|tags|tc|tcl|tcld|tcldo|tclf|tclfile|te|tearoff|tf|tfirst|th|throw|tj|tjump|tl|tlast|tm|tmenu|tn|tnext|to|topleft|tp|tprevious|tr|trewind|try|ts|tselect|tu|tunmenu|u|una|unabbreviate|undo|undoj|undojoin|undol|undolist|unh|unhide|unlet|unlo|unlockvar|unm|unmap|up|update|ve|verb|verbose|version|vert|vertical|vi|vie|view|vim|vimgrep|vimgrepa|vimgrepadd|visual|viu|viusage|vmapc|vmapclear|vne|vnew|vs|vsplit|vu|vunmap|w|wN|wNext|wa|wall|wh|while|win|winc|wincmd|windo|winp|winpos|winsize|wn|wnext|wp|wprevious|wq|wqa|wqall|write|ws|wsverb|wv|wviminfo|x|xa|xall|xit|xm|xmap|xmapc|xmapclear|xme|xmenu|xn|xnoremap|xnoreme|xnoremenu|xu|xunmap|y|yank)\b/,builtin:/\b(?:acd|ai|akm|aleph|allowrevins|altkeymap|ambiwidth|ambw|anti|antialias|arab|arabic|arabicshape|ari|arshape|autochdir|autocmd|autoindent|autoread|autowrite|autowriteall|aw|awa|background|backspace|backup|backupcopy|backupdir|backupext|backupskip|balloondelay|ballooneval|balloonexpr|bdir|bdlay|beval|bex|bexpr|bg|bh|bin|binary|biosk|bioskey|bk|bkc|bomb|breakat|brk|browsedir|bs|bsdir|bsk|bt|bufhidden|buflisted|buftype|casemap|ccv|cdpath|cedit|cfu|ch|charconvert|ci|cin|cindent|cink|cinkeys|cino|cinoptions|cinw|cinwords|clipboard|cmdheight|cmdwinheight|cmp|cms|columns|com|comments|commentstring|compatible|complete|completefunc|completeopt|consk|conskey|copyindent|cot|cpo|cpoptions|cpt|cscopepathcomp|cscopeprg|cscopequickfix|cscopetag|cscopetagorder|cscopeverbose|cspc|csprg|csqf|cst|csto|csverb|cuc|cul|cursorcolumn|cursorline|cwh|debug|deco|def|define|delcombine|dex|dg|dict|dictionary|diff|diffexpr|diffopt|digraph|dip|dir|directory|dy|ea|ead|eadirection|eb|ed|edcompatible|ef|efm|ei|ek|enc|encoding|endofline|eol|ep|equalalways|equalprg|errorbells|errorfile|errorformat|esckeys|et|eventignore|expandtab|exrc|fcl|fcs|fdc|fde|fdi|fdl|fdls|fdm|fdn|fdo|fdt|fen|fenc|fencs|fex|ff|ffs|fileencoding|fileencodings|fileformat|fileformats|fillchars|fk|fkmap|flp|fml|fmr|foldcolumn|foldenable|foldexpr|foldignore|foldlevel|foldlevelstart|foldmarker|foldmethod|foldminlines|foldnestmax|foldtext|formatexpr|formatlistpat|formatoptions|formatprg|fp|fs|fsync|ft|gcr|gd|gdefault|gfm|gfn|gfs|gfw|ghr|gp|grepformat|grepprg|gtl|gtt|guicursor|guifont|guifontset|guifontwide|guiheadroom|guioptions|guipty|guitablabel|guitabtooltip|helpfile|helpheight|helplang|hf|hh|hi|hidden|highlight|hk|hkmap|hkmapp|hkp|hl|hlg|hls|hlsearch|ic|icon|iconstring|ignorecase|im|imactivatekey|imak|imc|imcmdline|imd|imdisable|imi|iminsert|ims|imsearch|inc|include|includeexpr|incsearch|inde|indentexpr|indentkeys|indk|inex|inf|infercase|insertmode|invacd|invai|invakm|invallowrevins|invaltkeymap|invanti|invantialias|invar|invarab|invarabic|invarabicshape|invari|invarshape|invautochdir|invautoindent|invautoread|invautowrite|invautowriteall|invaw|invawa|invbackup|invballooneval|invbeval|invbin|invbinary|invbiosk|invbioskey|invbk|invbl|invbomb|invbuflisted|invcf|invci|invcin|invcindent|invcompatible|invconfirm|invconsk|invconskey|invcopyindent|invcp|invcscopetag|invcscopeverbose|invcst|invcsverb|invcuc|invcul|invcursorcolumn|invcursorline|invdeco|invdelcombine|invdg|invdiff|invdigraph|invdisable|invea|inveb|inved|invedcompatible|invek|invendofline|inveol|invequalalways|inverrorbells|invesckeys|invet|invex|invexpandtab|invexrc|invfen|invfk|invfkmap|invfoldenable|invgd|invgdefault|invguipty|invhid|invhidden|invhk|invhkmap|invhkmapp|invhkp|invhls|invhlsearch|invic|invicon|invignorecase|invim|invimc|invimcmdline|invimd|invincsearch|invinf|invinfercase|invinsertmode|invis|invjoinspaces|invjs|invlazyredraw|invlbr|invlinebreak|invlisp|invlist|invloadplugins|invlpl|invlz|invma|invmacatsui|invmagic|invmh|invml|invmod|invmodeline|invmodifiable|invmodified|invmore|invmousef|invmousefocus|invmousehide|invnu|invnumber|invodev|invopendevice|invpaste|invpi|invpreserveindent|invpreviewwindow|invprompt|invpvw|invreadonly|invremap|invrestorescreen|invrevins|invri|invrightleft|invrightleftcmd|invrl|invrlc|invro|invrs|invru|invruler|invsb|invsc|invscb|invscrollbind|invscs|invsecure|invsft|invshellslash|invshelltemp|invshiftround|invshortname|invshowcmd|invshowfulltag|invshowmatch|invshowmode|invsi|invsm|invsmartcase|invsmartindent|invsmarttab|invsmd|invsn|invsol|invspell|invsplitbelow|invsplitright|invspr|invsr|invssl|invsta|invstartofline|invstmp|invswapfile|invswf|invta|invtagbsearch|invtagrelative|invtagstack|invtbi|invtbidi|invtbs|invtermbidi|invterse|invtextauto|invtextmode|invtf|invtgst|invtildeop|invtimeout|invtitle|invto|invtop|invtr|invttimeout|invttybuiltin|invttyfast|invtx|invvb|invvisualbell|invwa|invwarn|invwb|invweirdinvert|invwfh|invwfw|invwildmenu|invwinfixheight|invwinfixwidth|invwiv|invwmnu|invwrap|invwrapscan|invwrite|invwriteany|invwritebackup|invws|isf|isfname|isi|isident|isk|iskeyword|isprint|joinspaces|js|key|keymap|keymodel|keywordprg|km|kmp|kp|langmap|langmenu|laststatus|lazyredraw|lbr|lcs|linebreak|lines|linespace|lisp|lispwords|listchars|loadplugins|lpl|lsp|lz|macatsui|magic|makeef|makeprg|matchpairs|matchtime|maxcombine|maxfuncdepth|maxmapdepth|maxmem|maxmempattern|maxmemtot|mco|mef|menuitems|mfd|mh|mis|mkspellmem|ml|mls|mm|mmd|mmp|mmt|modeline|modelines|modifiable|modified|more|mouse|mousef|mousefocus|mousehide|mousem|mousemodel|mouses|mouseshape|mouset|mousetime|mp|mps|msm|mzq|mzquantum|nf|noacd|noai|noakm|noallowrevins|noaltkeymap|noanti|noantialias|noar|noarab|noarabic|noarabicshape|noari|noarshape|noautochdir|noautoindent|noautoread|noautowrite|noautowriteall|noaw|noawa|nobackup|noballooneval|nobeval|nobin|nobinary|nobiosk|nobioskey|nobk|nobl|nobomb|nobuflisted|nocf|noci|nocin|nocindent|nocompatible|noconfirm|noconsk|noconskey|nocopyindent|nocp|nocscopetag|nocscopeverbose|nocst|nocsverb|nocuc|nocul|nocursorcolumn|nocursorline|nodeco|nodelcombine|nodg|nodiff|nodigraph|nodisable|noea|noeb|noed|noedcompatible|noek|noendofline|noeol|noequalalways|noerrorbells|noesckeys|noet|noex|noexpandtab|noexrc|nofen|nofk|nofkmap|nofoldenable|nogd|nogdefault|noguipty|nohid|nohidden|nohk|nohkmap|nohkmapp|nohkp|nohls|noic|noicon|noignorecase|noim|noimc|noimcmdline|noimd|noincsearch|noinf|noinfercase|noinsertmode|nois|nojoinspaces|nojs|nolazyredraw|nolbr|nolinebreak|nolisp|nolist|noloadplugins|nolpl|nolz|noma|nomacatsui|nomagic|nomh|noml|nomod|nomodeline|nomodifiable|nomodified|nomore|nomousef|nomousefocus|nomousehide|nonu|nonumber|noodev|noopendevice|nopaste|nopi|nopreserveindent|nopreviewwindow|noprompt|nopvw|noreadonly|noremap|norestorescreen|norevins|nori|norightleft|norightleftcmd|norl|norlc|noro|nors|noru|noruler|nosb|nosc|noscb|noscrollbind|noscs|nosecure|nosft|noshellslash|noshelltemp|noshiftround|noshortname|noshowcmd|noshowfulltag|noshowmatch|noshowmode|nosi|nosm|nosmartcase|nosmartindent|nosmarttab|nosmd|nosn|nosol|nospell|nosplitbelow|nosplitright|nospr|nosr|nossl|nosta|nostartofline|nostmp|noswapfile|noswf|nota|notagbsearch|notagrelative|notagstack|notbi|notbidi|notbs|notermbidi|noterse|notextauto|notextmode|notf|notgst|notildeop|notimeout|notitle|noto|notop|notr|nottimeout|nottybuiltin|nottyfast|notx|novb|novisualbell|nowa|nowarn|nowb|noweirdinvert|nowfh|nowfw|nowildmenu|nowinfixheight|nowinfixwidth|nowiv|nowmnu|nowrap|nowrapscan|nowrite|nowriteany|nowritebackup|nows|nrformats|numberwidth|nuw|odev|oft|ofu|omnifunc|opendevice|operatorfunc|opfunc|osfiletype|pa|para|paragraphs|paste|pastetoggle|patchexpr|patchmode|path|pdev|penc|pex|pexpr|pfn|ph|pheader|pi|pm|pmbcs|pmbfn|popt|preserveindent|previewheight|previewwindow|printdevice|printencoding|printexpr|printfont|printheader|printmbcharset|printmbfont|printoptions|prompt|pt|pumheight|pvh|pvw|qe|quoteescape|readonly|remap|report|restorescreen|revins|rightleft|rightleftcmd|rl|rlc|ro|rs|rtp|ruf|ruler|rulerformat|runtimepath|sbo|sc|scb|scr|scroll|scrollbind|scrolljump|scrolloff|scrollopt|scs|sect|sections|secure|sel|selection|selectmode|sessionoptions|sft|shcf|shellcmdflag|shellpipe|shellquote|shellredir|shellslash|shelltemp|shelltype|shellxquote|shiftround|shiftwidth|shm|shortmess|shortname|showbreak|showcmd|showfulltag|showmatch|showmode|showtabline|shq|si|sidescroll|sidescrolloff|siso|sj|slm|smartcase|smartindent|smarttab|smc|smd|softtabstop|sol|spc|spell|spellcapcheck|spellfile|spelllang|spellsuggest|spf|spl|splitbelow|splitright|sps|sr|srr|ss|ssl|ssop|stal|startofline|statusline|stl|stmp|su|sua|suffixes|suffixesadd|sw|swapfile|swapsync|swb|swf|switchbuf|sws|sxq|syn|synmaxcol|syntax|t_AB|t_AF|t_AL|t_CS|t_CV|t_Ce|t_Co|t_Cs|t_DL|t_EI|t_F1|t_F2|t_F3|t_F4|t_F5|t_F6|t_F7|t_F8|t_F9|t_IE|t_IS|t_K1|t_K3|t_K4|t_K5|t_K6|t_K7|t_K8|t_K9|t_KA|t_KB|t_KC|t_KD|t_KE|t_KF|t_KG|t_KH|t_KI|t_KJ|t_KK|t_KL|t_RI|t_RV|t_SI|t_Sb|t_Sf|t_WP|t_WS|t_ZH|t_ZR|t_al|t_bc|t_cd|t_ce|t_cl|t_cm|t_cs|t_da|t_db|t_dl|t_fs|t_k1|t_k2|t_k3|t_k4|t_k5|t_k6|t_k7|t_k8|t_k9|t_kB|t_kD|t_kI|t_kN|t_kP|t_kb|t_kd|t_ke|t_kh|t_kl|t_kr|t_ks|t_ku|t_le|t_mb|t_md|t_me|t_mr|t_ms|t_nd|t_op|t_se|t_so|t_sr|t_te|t_ti|t_ts|t_ue|t_us|t_ut|t_vb|t_ve|t_vi|t_vs|t_xs|tabline|tabpagemax|tabstop|tagbsearch|taglength|tagrelative|tagstack|tal|tb|tbi|tbidi|tbis|tbs|tenc|term|termbidi|termencoding|terse|textauto|textmode|textwidth|tgst|thesaurus|tildeop|timeout|timeoutlen|title|titlelen|titleold|titlestring|toolbar|toolbariconsize|top|tpm|tsl|tsr|ttimeout|ttimeoutlen|ttm|tty|ttybuiltin|ttyfast|ttym|ttymouse|ttyscroll|ttytype|tw|tx|uc|ul|undolevels|updatecount|updatetime|ut|vb|vbs|vdir|verbosefile|vfile|viewdir|viewoptions|viminfo|virtualedit|visualbell|vop|wak|warn|wb|wc|wcm|wd|weirdinvert|wfh|wfw|whichwrap|wi|wig|wildchar|wildcharm|wildignore|wildmenu|wildmode|wildoptions|wim|winaltkeys|window|winfixheight|winfixwidth|winheight|winminheight|winminwidth|winwidth|wiv|wiw|wm|wmh|wmnu|wmw|wop|wrap|wrapmargin|wrapscan|writeany|writebackup|writedelay|ww)\b/,number:/\b(?:0x[\da-f]+|\d+(?:\.\d+)?)\b/i,operator:/\|\||&&|[-+.]=?|[=!](?:[=~][#?]?)?|[<>]=?[#?]?|[*\/%?]|\b(?:is(?:not)?)\b/,punctuation:/[{}[\](),;:]/}}return vim_1}var visualBasic_1,hasRequiredVisualBasic;function requireVisualBasic(){if(hasRequiredVisualBasic)return visualBasic_1;hasRequiredVisualBasic=1,visualBasic_1=e,e.displayName="visualBasic",e.aliases=[];function e(t){t.languages["visual-basic"]={comment:{pattern:/(?:['‘’]|REM\b)(?:[^\r\n_]|_(?:\r\n?|\n)?)*/i,inside:{keyword:/^REM/i}},directive:{pattern:/#(?:Const|Else|ElseIf|End|ExternalChecksum|ExternalSource|If|Region)(?:\b_[ \t]*(?:\r\n?|\n)|.)+/i,alias:"property",greedy:!0},string:{pattern:/\$?["“”](?:["“”]{2}|[^"“”])*["“”]C?/i,greedy:!0},date:{pattern:/#[ \t]*(?:\d+([/-])\d+\1\d+(?:[ \t]+(?:\d+[ \t]*(?:AM|PM)|\d+:\d+(?::\d+)?(?:[ \t]*(?:AM|PM))?))?|\d+[ \t]*(?:AM|PM)|\d+:\d+(?::\d+)?(?:[ \t]*(?:AM|PM))?)[ \t]*#/i,alias:"number"},number:/(?:(?:\b\d+(?:\.\d+)?|\.\d+)(?:E[+-]?\d+)?|&[HO][\dA-F]+)(?:[FRD]|U?[ILS])?/i,boolean:/\b(?:False|Nothing|True)\b/i,keyword:/\b(?:AddHandler|AddressOf|Alias|And(?:Also)?|As|Boolean|ByRef|Byte|ByVal|Call|Case|Catch|C(?:Bool|Byte|Char|Date|Dbl|Dec|Int|Lng|Obj|SByte|Short|Sng|Str|Type|UInt|ULng|UShort)|Char|Class|Const|Continue|Currency|Date|Decimal|Declare|Default|Delegate|Dim|DirectCast|Do|Double|Each|Else(?:If)?|End(?:If)?|Enum|Erase|Error|Event|Exit|Finally|For|Friend|Function|Get(?:Type|XMLNamespace)?|Global|GoSub|GoTo|Handles|If|Implements|Imports|In|Inherits|Integer|Interface|Is|IsNot|Let|Lib|Like|Long|Loop|Me|Mod|Module|Must(?:Inherit|Override)|My(?:Base|Class)|Namespace|Narrowing|New|Next|Not(?:Inheritable|Overridable)?|Object|Of|On|Operator|Option(?:al)?|Or(?:Else)?|Out|Overloads|Overridable|Overrides|ParamArray|Partial|Private|Property|Protected|Public|RaiseEvent|ReadOnly|ReDim|RemoveHandler|Resume|Return|SByte|Select|Set|Shadows|Shared|short|Single|Static|Step|Stop|String|Structure|Sub|SyncLock|Then|Throw|To|Try|TryCast|Type|TypeOf|U(?:Integer|Long|Short)|Until|Using|Variant|Wend|When|While|Widening|With(?:Events)?|WriteOnly|Xor)\b/i,operator:/[+\-*/\\^<=>&#@$%!]|\b_(?=[ \t]*[\r\n])/,punctuation:/[{}().,:?]/},t.languages.vb=t.languages["visual-basic"],t.languages.vba=t.languages["visual-basic"]}return visualBasic_1}var warpscript_1,hasRequiredWarpscript;function requireWarpscript(){if(hasRequiredWarpscript)return warpscript_1;hasRequiredWarpscript=1,warpscript_1=e,e.displayName="warpscript",e.aliases=[];function e(t){t.languages.warpscript={comment:/#.*|\/\/.*|\/\*[\s\S]*?\*\//,string:{pattern:/"(?:[^"\\\r\n]|\\.)*"|'(?:[^'\\\r\n]|\\.)*'|<'(?:[^\\']|'(?!>)|\\.)*'>/,greedy:!0},variable:/\$\S+/,macro:{pattern:/@\S+/,alias:"property"},keyword:/\b(?:BREAK|CHECKMACRO|CONTINUE|CUDF|DEFINED|DEFINEDMACRO|EVAL|FAIL|FOR|FOREACH|FORSTEP|IFT|IFTE|MSGFAIL|NRETURN|RETHROW|RETURN|SWITCH|TRY|UDF|UNTIL|WHILE)\b/,number:/[+-]?\b(?:NaN|Infinity|\d+(?:\.\d*)?(?:[Ee][+-]?\d+)?|0x[\da-fA-F]+|0b[01]+)\b/,boolean:/\b(?:F|T|false|true)\b/,punctuation:/<%|%>|[{}[\]()]/,operator:/==|&&?|\|\|?|\*\*?|>>>?|<<|[<>!~]=?|[-/%^]|\+!?|\b(?:AND|NOT|OR)\b/}}return warpscript_1}var wasm_1,hasRequiredWasm;function requireWasm(){if(hasRequiredWasm)return wasm_1;hasRequiredWasm=1,wasm_1=e,e.displayName="wasm",e.aliases=[];function e(t){t.languages.wasm={comment:[/\(;[\s\S]*?;\)/,{pattern:/;;.*/,greedy:!0}],string:{pattern:/"(?:\\[\s\S]|[^"\\])*"/,greedy:!0},keyword:[{pattern:/\b(?:align|offset)=/,inside:{operator:/=/}},{pattern:/\b(?:(?:f32|f64|i32|i64)(?:\.(?:abs|add|and|ceil|clz|const|convert_[su]\/i(?:32|64)|copysign|ctz|demote\/f64|div(?:_[su])?|eqz?|extend_[su]\/i32|floor|ge(?:_[su])?|gt(?:_[su])?|le(?:_[su])?|load(?:(?:8|16|32)_[su])?|lt(?:_[su])?|max|min|mul|neg?|nearest|or|popcnt|promote\/f32|reinterpret\/[fi](?:32|64)|rem_[su]|rot[lr]|shl|shr_[su]|sqrt|store(?:8|16|32)?|sub|trunc(?:_[su]\/f(?:32|64))?|wrap\/i64|xor))?|memory\.(?:grow|size))\b/,inside:{punctuation:/\./}},/\b(?:anyfunc|block|br(?:_if|_table)?|call(?:_indirect)?|data|drop|elem|else|end|export|func|get_(?:global|local)|global|if|import|local|loop|memory|module|mut|nop|offset|param|result|return|select|set_(?:global|local)|start|table|tee_local|then|type|unreachable)\b/],variable:/\$[\w!#$%&'*+\-./:<=>?@\\^`|~]+/,number:/[+-]?\b(?:\d(?:_?\d)*(?:\.\d(?:_?\d)*)?(?:[eE][+-]?\d(?:_?\d)*)?|0x[\da-fA-F](?:_?[\da-fA-F])*(?:\.[\da-fA-F](?:_?[\da-fA-D])*)?(?:[pP][+-]?\d(?:_?\d)*)?)\b|\binf\b|\bnan(?::0x[\da-fA-F](?:_?[\da-fA-D])*)?\b/,punctuation:/[()]/}}return wasm_1}var webIdl_1,hasRequiredWebIdl;function requireWebIdl(){if(hasRequiredWebIdl)return webIdl_1;hasRequiredWebIdl=1,webIdl_1=e,e.displayName="webIdl",e.aliases=[];function e(t){(function(Ye){var tt=/(?:\B-|\b_|\b)[A-Za-z][\w-]*(?![\w-])/.source,rt="(?:"+/\b(?:unsigned\s+)?long\s+long(?![\w-])/.source+"|"+/\b(?:unrestricted|unsigned)\s+[a-z]+(?![\w-])/.source+"|"+/(?!(?:unrestricted|unsigned)\b)/.source+tt+/(?:\s*<(?:[^<>]|<[^<>]*>)*>)?/.source+")"+/(?:\s*\?)?/.source,nt={};Ye.languages["web-idl"]={comment:{pattern:/\/\/.*|\/\*[\s\S]*?\*\//,greedy:!0},string:{pattern:/"[^"]*"/,greedy:!0},namespace:{pattern:RegExp(/(\bnamespace\s+)/.source+tt),lookbehind:!0},"class-name":[{pattern:/(^|[^\w-])(?:iterable|maplike|setlike)\s*<(?:[^<>]|<[^<>]*>)*>/,lookbehind:!0,inside:nt},{pattern:RegExp(/(\b(?:attribute|const|deleter|getter|optional|setter)\s+)/.source+rt),lookbehind:!0,inside:nt},{pattern:RegExp("("+/\bcallback\s+/.source+tt+/\s*=\s*/.source+")"+rt),lookbehind:!0,inside:nt},{pattern:RegExp(/(\btypedef\b\s*)/.source+rt),lookbehind:!0,inside:nt},{pattern:RegExp(/(\b(?:callback|dictionary|enum|interface(?:\s+mixin)?)\s+)(?!(?:interface|mixin)\b)/.source+tt),lookbehind:!0},{pattern:RegExp(/(:\s*)/.source+tt),lookbehind:!0},RegExp(tt+/(?=\s+(?:implements|includes)\b)/.source),{pattern:RegExp(/(\b(?:implements|includes)\s+)/.source+tt),lookbehind:!0},{pattern:RegExp(rt+"(?="+/\s*(?:\.{3}\s*)?/.source+tt+/\s*[(),;=]/.source+")"),inside:nt}],builtin:/\b(?:ArrayBuffer|BigInt64Array|BigUint64Array|ByteString|DOMString|DataView|Float32Array|Float64Array|FrozenArray|Int16Array|Int32Array|Int8Array|ObservableArray|Promise|USVString|Uint16Array|Uint32Array|Uint8Array|Uint8ClampedArray)\b/,keyword:[/\b(?:async|attribute|callback|const|constructor|deleter|dictionary|enum|getter|implements|includes|inherit|interface|mixin|namespace|null|optional|or|partial|readonly|required|setter|static|stringifier|typedef|unrestricted)\b/,/\b(?:any|bigint|boolean|byte|double|float|iterable|long|maplike|object|octet|record|sequence|setlike|short|symbol|undefined|unsigned|void)\b/],boolean:/\b(?:false|true)\b/,number:{pattern:/(^|[^\w-])-?(?:0x[0-9a-f]+|(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?|NaN|Infinity)(?![\w-])/i,lookbehind:!0},operator:/\.{3}|[=:?<>-]/,punctuation:/[(){}[\].,;]/};for(var at in Ye.languages["web-idl"])at!=="class-name"&&(nt[at]=Ye.languages["web-idl"][at]);Ye.languages.webidl=Ye.languages["web-idl"]})(t)}return webIdl_1}var wiki_1,hasRequiredWiki;function requireWiki(){if(hasRequiredWiki)return wiki_1;hasRequiredWiki=1,wiki_1=e,e.displayName="wiki",e.aliases=[];function e(t){t.languages.wiki=t.languages.extend("markup",{"block-comment":{pattern:/(^|[^\\])\/\*[\s\S]*?\*\//,lookbehind:!0,alias:"comment"},heading:{pattern:/^(=+)[^=\r\n].*?\1/m,inside:{punctuation:/^=+|=+$/,important:/.+/}},emphasis:{pattern:/('{2,5}).+?\1/,inside:{"bold-italic":{pattern:/(''''').+?(?=\1)/,lookbehind:!0,alias:["bold","italic"]},bold:{pattern:/(''')[^'](?:.*?[^'])?(?=\1)/,lookbehind:!0},italic:{pattern:/('')[^'](?:.*?[^'])?(?=\1)/,lookbehind:!0},punctuation:/^''+|''+$/}},hr:{pattern:/^-{4,}/m,alias:"punctuation"},url:[/ISBN +(?:97[89][ -]?)?(?:\d[ -]?){9}[\dx]\b|(?:PMID|RFC) +\d+/i,/\[\[.+?\]\]|\[.+?\]/],variable:[/__[A-Z]+__/,/\{{3}.+?\}{3}/,/\{\{.+?\}\}/],symbol:[/^#redirect/im,/~{3,5}/],"table-tag":{pattern:/((?:^|[|!])[|!])[^|\r\n]+\|(?!\|)/m,lookbehind:!0,inside:{"table-bar":{pattern:/\|$/,alias:"punctuation"},rest:t.languages.markup.tag.inside}},punctuation:/^(?:\{\||\|\}|\|-|[*#:;!|])|\|\||!!/m}),t.languages.insertBefore("wiki","tag",{nowiki:{pattern:/<(nowiki|pre|source)\b[^>]*>[\s\S]*?<\/\1>/i,inside:{tag:{pattern:/<(?:nowiki|pre|source)\b[^>]*>|<\/(?:nowiki|pre|source)>/i,inside:t.languages.markup.tag.inside}}}})}return wiki_1}var wolfram_1,hasRequiredWolfram;function requireWolfram(){if(hasRequiredWolfram)return wolfram_1;hasRequiredWolfram=1,wolfram_1=e,e.displayName="wolfram",e.aliases=["mathematica","wl","nb"];function e(t){t.languages.wolfram={comment:/\(\*(?:\(\*(?:[^*]|\*(?!\)))*\*\)|(?!\(\*)[\s\S])*?\*\)/,string:{pattern:/"(?:\\.|[^"\\\r\n])*"/,greedy:!0},keyword:/\b(?:Abs|AbsArg|Accuracy|Block|Do|For|Function|If|Manipulate|Module|Nest|NestList|None|Return|Switch|Table|Which|While)\b/,context:{pattern:/\b\w+`+\w*/,alias:"class-name"},blank:{pattern:/\b\w+_\b/,alias:"regex"},"global-variable":{pattern:/\$\w+/,alias:"variable"},boolean:/\b(?:False|True)\b/,number:/(?:\b(?=\d)|\B(?=\.))(?:0[bo])?(?:(?:\d|0x[\da-f])[\da-f]*(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?j?\b/i,operator:/\/\.|;|=\.|\^=|\^:=|:=|<<|>>|<\||\|>|:>|\|->|->|<-|@@@|@@|@|\/@|=!=|===|==|=|\+|-|\^|\[\/-+%=\]=?|!=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,punctuation:/[{}[\];(),.:]/},t.languages.mathematica=t.languages.wolfram,t.languages.wl=t.languages.wolfram,t.languages.nb=t.languages.wolfram}return wolfram_1}var wren_1,hasRequiredWren;function requireWren(){if(hasRequiredWren)return wren_1;hasRequiredWren=1,wren_1=e,e.displayName="wren",e.aliases=[];function e(t){t.languages.wren={comment:[{pattern:/\/\*(?:[^*/]|\*(?!\/)|\/(?!\*)|\/\*(?:[^*/]|\*(?!\/)|\/(?!\*)|\/\*(?:[^*/]|\*(?!\/)|\/(?!\*))*\*\/)*\*\/)*\*\//,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],"triple-quoted-string":{pattern:/"""[\s\S]*?"""/,greedy:!0,alias:"string"},"string-literal":null,hashbang:{pattern:/^#!\/.+/,greedy:!0,alias:"comment"},attribute:{pattern:/#!?[ \t\u3000]*\w+/,alias:"keyword"},"class-name":[{pattern:/(\bclass\s+)\w+/,lookbehind:!0},/\b[A-Z][a-z\d_]*\b/],constant:/\b[A-Z][A-Z\d_]*\b/,null:{pattern:/\bnull\b/,alias:"keyword"},keyword:/\b(?:as|break|class|construct|continue|else|for|foreign|if|import|in|is|return|static|super|this|var|while)\b/,boolean:/\b(?:false|true)\b/,number:/\b(?:0x[\da-f]+|\d+(?:\.\d+)?(?:e[+-]?\d+)?)\b/i,function:/\b[a-z_]\w*(?=\s*[({])/i,operator:/<<|>>|[=!<>]=?|&&|\|\||[-+*/%~^&|?:]|\.{2,3}/,punctuation:/[\[\](){}.,;]/},t.languages.wren["string-literal"]={pattern:/(^|[^\\"])"(?:[^\\"%]|\\[\s\S]|%(?!\()|%\((?:[^()]|\((?:[^()]|\([^)]*\))*\))*\))*"/,lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)%\((?:[^()]|\((?:[^()]|\([^)]*\))*\))*\)/,lookbehind:!0,inside:{expression:{pattern:/^(%\()[\s\S]+(?=\)$)/,lookbehind:!0,inside:t.languages.wren},"interpolation-punctuation":{pattern:/^%\(|\)$/,alias:"punctuation"}}},string:/[\s\S]+/}}}return wren_1}var xeora_1,hasRequiredXeora;function requireXeora(){if(hasRequiredXeora)return xeora_1;hasRequiredXeora=1,xeora_1=e,e.displayName="xeora",e.aliases=["xeoracube"];function e(t){(function(Ye){Ye.languages.xeora=Ye.languages.extend("markup",{constant:{pattern:/\$(?:DomainContents|PageRenderDuration)\$/,inside:{punctuation:{pattern:/\$/}}},variable:{pattern:/\$@?(?:#+|[-+*~=^])?[\w.]+\$/,inside:{punctuation:{pattern:/[$.]/},operator:{pattern:/#+|[-+*~=^@]/}}},"function-inline":{pattern:/\$F:[-\w.]+\?[-\w.]+(?:,(?:(?:@[-#]*\w+\.[\w+.]\.*)*\|)*(?:(?:[\w+]|[-#*.~^]+[\w+]|=\S)(?:[^$=]|=+[^=])*=*|(?:@[-#]*\w+\.[\w+.]\.*)+(?:(?:[\w+]|[-#*~^][-#*.~^]*[\w+]|=\S)(?:[^$=]|=+[^=])*=*)?)?)?\$/,inside:{variable:{pattern:/(?:[,|])@?(?:#+|[-+*~=^])?[\w.]+/,inside:{punctuation:{pattern:/[,.|]/},operator:{pattern:/#+|[-+*~=^@]/}}},punctuation:{pattern:/\$\w:|[$:?.,|]/}},alias:"function"},"function-block":{pattern:/\$XF:\{[-\w.]+\?[-\w.]+(?:,(?:(?:@[-#]*\w+\.[\w+.]\.*)*\|)*(?:(?:[\w+]|[-#*.~^]+[\w+]|=\S)(?:[^$=]|=+[^=])*=*|(?:@[-#]*\w+\.[\w+.]\.*)+(?:(?:[\w+]|[-#*~^][-#*.~^]*[\w+]|=\S)(?:[^$=]|=+[^=])*=*)?)?)?\}:XF\$/,inside:{punctuation:{pattern:/[$:{}?.,|]/}},alias:"function"},"directive-inline":{pattern:/\$\w(?:#\d+\+?)?(?:\[[-\w.]+\])?:[-\/\w.]+\$/,inside:{punctuation:{pattern:/\$(?:\w:|C(?:\[|#\d))?|[:{[\]]/,inside:{tag:{pattern:/#\d/}}}},alias:"function"},"directive-block-open":{pattern:/\$\w+:\{|\$\w(?:#\d+\+?)?(?:\[[-\w.]+\])?:[-\w.]+:\{(?:![A-Z]+)?/,inside:{punctuation:{pattern:/\$(?:\w:|C(?:\[|#\d))?|[:{[\]]/,inside:{tag:{pattern:/#\d/}}},attribute:{pattern:/![A-Z]+$/,inside:{punctuation:{pattern:/!/}},alias:"keyword"}},alias:"function"},"directive-block-separator":{pattern:/\}:[-\w.]+:\{/,inside:{punctuation:{pattern:/[:{}]/}},alias:"function"},"directive-block-close":{pattern:/\}:[-\w.]+\$/,inside:{punctuation:{pattern:/[:{}$]/}},alias:"function"}}),Ye.languages.insertBefore("inside","punctuation",{variable:Ye.languages.xeora["function-inline"].inside.variable},Ye.languages.xeora["function-block"]),Ye.languages.xeoracube=Ye.languages.xeora})(t)}return xeora_1}var xmlDoc_1,hasRequiredXmlDoc;function requireXmlDoc(){if(hasRequiredXmlDoc)return xmlDoc_1;hasRequiredXmlDoc=1,xmlDoc_1=e,e.displayName="xmlDoc",e.aliases=[];function e(t){(function(Ye){function tt(it,ot){Ye.languages[it]&&Ye.languages.insertBefore(it,"comment",{"doc-comment":ot})}var rt=Ye.languages.markup.tag,nt={pattern:/\/\/\/.*/,greedy:!0,alias:"comment",inside:{tag:rt}},at={pattern:/'''.*/,greedy:!0,alias:"comment",inside:{tag:rt}};tt("csharp",nt),tt("fsharp",nt),tt("vbnet",at)})(t)}return xmlDoc_1}var xojo_1,hasRequiredXojo;function requireXojo(){if(hasRequiredXojo)return xojo_1;hasRequiredXojo=1,xojo_1=e,e.displayName="xojo",e.aliases=[];function e(t){t.languages.xojo={comment:{pattern:/(?:'|\/\/|Rem\b).+/i,greedy:!0},string:{pattern:/"(?:""|[^"])*"/,greedy:!0},number:[/(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:E[+-]?\d+)?/i,/&[bchou][a-z\d]+/i],directive:{pattern:/#(?:Else|ElseIf|Endif|If|Pragma)\b/i,alias:"property"},keyword:/\b(?:AddHandler|App|Array|As(?:signs)?|Auto|Boolean|Break|By(?:Ref|Val)|Byte|Call|Case|Catch|CFStringRef|CGFloat|Class|Color|Const|Continue|CString|Currency|CurrentMethodName|Declare|Delegate|Dim|Do(?:uble|wnTo)?|Each|Else(?:If)?|End|Enumeration|Event|Exception|Exit|Extends|False|Finally|For|Function|Get|GetTypeInfo|Global|GOTO|If|Implements|In|Inherits|Int(?:8|16|32|64|eger|erface)?|Lib|Loop|Me|Module|Next|Nil|Object|Optional|OSType|ParamArray|Private|Property|Protected|PString|Ptr|Raise(?:Event)?|ReDim|RemoveHandler|Return|Select(?:or)?|Self|Set|Shared|Short|Single|Soft|Static|Step|String|Sub|Super|Text|Then|To|True|Try|Ubound|UInt(?:8|16|32|64|eger)?|Until|Using|Var(?:iant)?|Wend|While|WindowPtr|WString)\b/i,operator:/<[=>]?|>=?|[+\-*\/\\^=]|\b(?:AddressOf|And|Ctype|IsA?|Mod|New|Not|Or|WeakAddressOf|Xor)\b/i,punctuation:/[.,;:()]/}}return xojo_1}var xquery_1,hasRequiredXquery;function requireXquery(){if(hasRequiredXquery)return xquery_1;hasRequiredXquery=1,xquery_1=e,e.displayName="xquery",e.aliases=[];function e(t){(function(Ye){Ye.languages.xquery=Ye.languages.extend("markup",{"xquery-comment":{pattern:/\(:[\s\S]*?:\)/,greedy:!0,alias:"comment"},string:{pattern:/(["'])(?:\1\1|(?!\1)[\s\S])*\1/,greedy:!0},extension:{pattern:/\(#.+?#\)/,alias:"symbol"},variable:/\$[-\w:]+/,axis:{pattern:/(^|[^-])(?:ancestor(?:-or-self)?|attribute|child|descendant(?:-or-self)?|following(?:-sibling)?|parent|preceding(?:-sibling)?|self)(?=::)/,lookbehind:!0,alias:"operator"},"keyword-operator":{pattern:/(^|[^:-])\b(?:and|castable as|div|eq|except|ge|gt|idiv|instance of|intersect|is|le|lt|mod|ne|or|union)\b(?=$|[^:-])/,lookbehind:!0,alias:"operator"},keyword:{pattern:/(^|[^:-])\b(?:as|ascending|at|base-uri|boundary-space|case|cast as|collation|construction|copy-namespaces|declare|default|descending|else|empty (?:greatest|least)|encoding|every|external|for|function|if|import|in|inherit|lax|let|map|module|namespace|no-inherit|no-preserve|option|order(?: by|ed|ing)?|preserve|return|satisfies|schema|some|stable|strict|strip|then|to|treat as|typeswitch|unordered|validate|variable|version|where|xquery)\b(?=$|[^:-])/,lookbehind:!0},function:/[\w-]+(?::[\w-]+)*(?=\s*\()/,"xquery-element":{pattern:/(element\s+)[\w-]+(?::[\w-]+)*/,lookbehind:!0,alias:"tag"},"xquery-attribute":{pattern:/(attribute\s+)[\w-]+(?::[\w-]+)*/,lookbehind:!0,alias:"attr-name"},builtin:{pattern:/(^|[^:-])\b(?:attribute|comment|document|element|processing-instruction|text|xs:(?:ENTITIES|ENTITY|ID|IDREFS?|NCName|NMTOKENS?|NOTATION|Name|QName|anyAtomicType|anyType|anyURI|base64Binary|boolean|byte|date|dateTime|dayTimeDuration|decimal|double|duration|float|gDay|gMonth|gMonthDay|gYear|gYearMonth|hexBinary|int|integer|language|long|negativeInteger|nonNegativeInteger|nonPositiveInteger|normalizedString|positiveInteger|short|string|time|token|unsigned(?:Byte|Int|Long|Short)|untyped(?:Atomic)?|yearMonthDuration))\b(?=$|[^:-])/,lookbehind:!0},number:/\b\d+(?:\.\d+)?(?:E[+-]?\d+)?/,operator:[/[+*=?|@]|\.\.?|:=|!=|<[=<]?|>[=>]?/,{pattern:/(\s)-(?=\s)/,lookbehind:!0}],punctuation:/[[\](){},;:/]/}),Ye.languages.xquery.tag.pattern=/<\/?(?!\d)[^\s>\/=$<%]+(?:\s+[^\s>\/=]+(?:=(?:("|')(?:\\[\s\S]|\{(?!\{)(?:\{(?:\{[^{}]*\}|[^{}])*\}|[^{}])+\}|(?!\1)[^\\])*\1|[^\s'">=]+))?)*\s*\/?>/,Ye.languages.xquery.tag.inside["attr-value"].pattern=/=(?:("|')(?:\\[\s\S]|\{(?!\{)(?:\{(?:\{[^{}]*\}|[^{}])*\}|[^{}])+\}|(?!\1)[^\\])*\1|[^\s'">=]+)/,Ye.languages.xquery.tag.inside["attr-value"].inside.punctuation=/^="|"$/,Ye.languages.xquery.tag.inside["attr-value"].inside.expression={pattern:/\{(?!\{)(?:\{(?:\{[^{}]*\}|[^{}])*\}|[^{}])+\}/,inside:Ye.languages.xquery,alias:"language-xquery"};var tt=function(nt){return typeof nt=="string"?nt:typeof nt.content=="string"?nt.content:nt.content.map(tt).join("")},rt=function(nt){for(var at=[],it=0;it<nt.length;it++){var ot=nt[it],ct=!1;if(typeof ot!="string"&&(ot.type==="tag"&&ot.content[0]&&ot.content[0].type==="tag"?ot.content[0].content[0].content==="</"?at.length>0&&at[at.length-1].tagName===tt(ot.content[0].content[1])&&at.pop():ot.content[ot.content.length-1].content==="/>"||at.push({tagName:tt(ot.content[0].content[1]),openedBraces:0}):at.length>0&&ot.type==="punctuation"&&ot.content==="{"&&(!nt[it+1]||nt[it+1].type!=="punctuation"||nt[it+1].content!=="{")&&(!nt[it-1]||nt[it-1].type!=="plain-text"||nt[it-1].content!=="{")?at[at.length-1].openedBraces++:at.length>0&&at[at.length-1].openedBraces>0&&ot.type==="punctuation"&&ot.content==="}"?at[at.length-1].openedBraces--:ot.type!=="comment"&&(ct=!0)),(ct||typeof ot=="string")&&at.length>0&&at[at.length-1].openedBraces===0){var At=tt(ot);it<nt.length-1&&(typeof nt[it+1]=="string"||nt[it+1].type==="plain-text")&&(At+=tt(nt[it+1]),nt.splice(it+1,1)),it>0&&(typeof nt[it-1]=="string"||nt[it-1].type==="plain-text")&&(At=tt(nt[it-1])+At,nt.splice(it-1,1),it--),/^\s+$/.test(At)?nt[it]=At:nt[it]=new Ye.Token("plain-text",At,null,At)}ot.content&&typeof ot.content!="string"&&rt(ot.content)}};Ye.hooks.add("after-tokenize",function(nt){nt.language==="xquery"&&rt(nt.tokens)})})(t)}return xquery_1}var yang_1,hasRequiredYang;function requireYang(){if(hasRequiredYang)return yang_1;hasRequiredYang=1,yang_1=e,e.displayName="yang",e.aliases=[];function e(t){t.languages.yang={comment:/\/\*[\s\S]*?\*\/|\/\/.*/,string:{pattern:/"(?:[^\\"]|\\.)*"|'[^']*'/,greedy:!0},keyword:{pattern:/(^|[{};\r\n][ \t]*)[a-z_][\w.-]*/i,lookbehind:!0},namespace:{pattern:/(\s)[a-z_][\w.-]*(?=:)/i,lookbehind:!0},boolean:/\b(?:false|true)\b/,operator:/\+/,punctuation:/[{};:]/}}return yang_1}var zig_1,hasRequiredZig;function requireZig(){if(hasRequiredZig)return zig_1;hasRequiredZig=1,zig_1=e,e.displayName="zig",e.aliases=[];function e(t){(function(Ye){function tt(At){return function(){return At}}var rt=/\b(?:align|allowzero|and|anyframe|anytype|asm|async|await|break|cancel|catch|comptime|const|continue|defer|else|enum|errdefer|error|export|extern|fn|for|if|inline|linksection|nakedcc|noalias|nosuspend|null|or|orelse|packed|promise|pub|resume|return|stdcallcc|struct|suspend|switch|test|threadlocal|try|undefined|union|unreachable|usingnamespace|var|volatile|while)\b/,nt="\\b(?!"+rt.source+")(?!\\d)\\w+\\b",at=/align\s*\((?:[^()]|\([^()]*\))*\)/.source,it=/(?:\?|\bpromise->|(?:\[[^[\]]*\]|\*(?!\*)|\*\*)(?:\s*<ALIGN>|\s*const\b|\s*volatile\b|\s*allowzero\b)*)/.source.replace(/<ALIGN>/g,tt(at)),ot=/(?:\bpromise\b|(?:\berror\.)?<ID>(?:\.<ID>)*(?!\s+<ID>))/.source.replace(/<ID>/g,tt(nt)),ct="(?!\\s)(?:!?\\s*(?:"+it+"\\s*)*"+ot+")+";Ye.languages.zig={comment:[{pattern:/\/\/[/!].*/,alias:"doc-comment"},/\/{2}.*/],string:[{pattern:/(^|[^\\@])c?"(?:[^"\\\r\n]|\\.)*"/,lookbehind:!0,greedy:!0},{pattern:/([\r\n])([ \t]+c?\\{2}).*(?:(?:\r\n?|\n)\2.*)*/,lookbehind:!0,greedy:!0}],char:{pattern:/(^|[^\\])'(?:[^'\\\r\n]|[\uD800-\uDFFF]{2}|\\(?:.|x[a-fA-F\d]{2}|u\{[a-fA-F\d]{1,6}\}))'/,lookbehind:!0,greedy:!0},builtin:/\B@(?!\d)\w+(?=\s*\()/,label:{pattern:/(\b(?:break|continue)\s*:\s*)\w+\b|\b(?!\d)\w+\b(?=\s*:\s*(?:\{|while\b))/,lookbehind:!0},"class-name":[/\b(?!\d)\w+(?=\s*=\s*(?:(?:extern|packed)\s+)?(?:enum|struct|union)\s*[({])/,{pattern:RegExp(/(:\s*)<TYPE>(?=\s*(?:<ALIGN>\s*)?[=;,)])|<TYPE>(?=\s*(?:<ALIGN>\s*)?\{)/.source.replace(/<TYPE>/g,tt(ct)).replace(/<ALIGN>/g,tt(at))),lookbehind:!0,inside:null},{pattern:RegExp(/(\)\s*)<TYPE>(?=\s*(?:<ALIGN>\s*)?;)/.source.replace(/<TYPE>/g,tt(ct)).replace(/<ALIGN>/g,tt(at))),lookbehind:!0,inside:null}],"builtin-type":{pattern:/\b(?:anyerror|bool|c_u?(?:int|long|longlong|short)|c_longdouble|c_void|comptime_(?:float|int)|f(?:16|32|64|128)|[iu](?:8|16|32|64|128|size)|noreturn|type|void)\b/,alias:"keyword"},keyword:rt,function:/\b(?!\d)\w+(?=\s*\()/,number:/\b(?:0b[01]+|0o[0-7]+|0x[a-fA-F\d]+(?:\.[a-fA-F\d]*)?(?:[pP][+-]?[a-fA-F\d]+)?|\d+(?:\.\d*)?(?:[eE][+-]?\d+)?)\b/,boolean:/\b(?:false|true)\b/,operator:/\.[*?]|\.{2,3}|[-=]>|\*\*|\+\+|\|\||(?:<<|>>|[-+*]%|[-+*/%^&|<>!=])=?|[?~]/,punctuation:/[.:,;(){}[\]]/},Ye.languages.zig["class-name"].forEach(function(At){At.inside===null&&(At.inside=Ye.languages.zig)})})(t)}return zig_1}var refractor_1,hasRequiredRefractor;function requireRefractor(){if(hasRequiredRefractor)return refractor_1;hasRequiredRefractor=1;var e=requireCore$2();return refractor_1=e,e.register(requireAbap()),e.register(requireAbnf()),e.register(requireActionscript()),e.register(requireAda()),e.register(requireAgda()),e.register(requireAl()),e.register(requireAntlr4()),e.register(requireApacheconf()),e.register(requireApex()),e.register(requireApl()),e.register(requireApplescript()),e.register(requireAql()),e.register(requireArduino()),e.register(requireArff()),e.register(requireAsciidoc()),e.register(requireAsm6502()),e.register(requireAsmatmel()),e.register(requireAspnet()),e.register(requireAutohotkey()),e.register(requireAutoit()),e.register(requireAvisynth()),e.register(requireAvroIdl()),e.register(requireBash()),e.register(requireBasic()),e.register(requireBatch()),e.register(requireBbcode()),e.register(requireBicep()),e.register(requireBirb()),e.register(requireBison()),e.register(requireBnf()),e.register(requireBrainfuck()),e.register(requireBrightscript()),e.register(requireBro()),e.register(requireBsl()),e.register(requireC()),e.register(requireCfscript()),e.register(requireChaiscript()),e.register(requireCil()),e.register(requireClojure()),e.register(requireCmake()),e.register(requireCobol()),e.register(requireCoffeescript()),e.register(requireConcurnas()),e.register(requireCoq()),e.register(requireCpp()),e.register(requireCrystal()),e.register(requireCsharp()),e.register(requireCshtml()),e.register(requireCsp()),e.register(requireCssExtras()),e.register(requireCsv()),e.register(requireCypher()),e.register(requireD()),e.register(requireDart()),e.register(requireDataweave()),e.register(requireDax()),e.register(requireDhall()),e.register(requireDiff()),e.register(requireDjango()),e.register(requireDnsZoneFile()),e.register(requireDocker()),e.register(requireDot()),e.register(requireEbnf()),e.register(requireEditorconfig()),e.register(requireEiffel()),e.register(requireEjs()),e.register(requireElixir()),e.register(requireElm()),e.register(requireErb()),e.register(requireErlang()),e.register(requireEtlua()),e.register(requireExcelFormula()),e.register(requireFactor()),e.register(require_false()),e.register(requireFirestoreSecurityRules()),e.register(requireFlow()),e.register(requireFortran()),e.register(requireFsharp()),e.register(requireFtl()),e.register(requireGap()),e.register(requireGcode()),e.register(requireGdscript()),e.register(requireGedcom()),e.register(requireGherkin()),e.register(requireGit()),e.register(requireGlsl()),e.register(requireGml()),e.register(requireGn()),e.register(requireGoModule()),e.register(requireGo()),e.register(requireGraphql()),e.register(requireGroovy()),e.register(requireHaml()),e.register(requireHandlebars()),e.register(requireHaskell()),e.register(requireHaxe()),e.register(requireHcl()),e.register(requireHlsl()),e.register(requireHoon()),e.register(requireHpkp()),e.register(requireHsts()),e.register(requireHttp()),e.register(requireIchigojam()),e.register(requireIcon()),e.register(requireIcuMessageFormat()),e.register(requireIdris()),e.register(requireIecst()),e.register(requireIgnore()),e.register(requireInform7()),e.register(requireIni()),e.register(requireIo()),e.register(requireJ()),e.register(requireJava()),e.register(requireJavadoc()),e.register(requireJavadoclike()),e.register(requireJavastacktrace()),e.register(requireJexl()),e.register(requireJolie()),e.register(requireJq()),e.register(requireJsExtras()),e.register(requireJsTemplates()),e.register(requireJsdoc()),e.register(requireJson$1()),e.register(requireJson5()),e.register(requireJsonp()),e.register(requireJsstacktrace()),e.register(requireJsx()),e.register(requireJulia()),e.register(requireKeepalived()),e.register(requireKeyman()),e.register(requireKotlin()),e.register(requireKumir()),e.register(requireKusto()),e.register(requireLatex()),e.register(requireLatte()),e.register(requireLess()),e.register(requireLilypond()),e.register(requireLiquid()),e.register(requireLisp()),e.register(requireLivescript()),e.register(requireLlvm()),e.register(requireLog()),e.register(requireLolcode()),e.register(requireLua()),e.register(requireMagma()),e.register(requireMakefile()),e.register(requireMarkdown()),e.register(requireMarkupTemplating()),e.register(requireMatlab()),e.register(requireMaxscript()),e.register(requireMel()),e.register(requireMermaid()),e.register(requireMizar()),e.register(requireMongodb()),e.register(requireMonkey()),e.register(requireMoonscript()),e.register(requireN1ql()),e.register(requireN4js()),e.register(requireNand2tetrisHdl()),e.register(requireNaniscript()),e.register(requireNasm()),e.register(requireNeon()),e.register(requireNevod()),e.register(requireNginx()),e.register(requireNim()),e.register(requireNix()),e.register(requireNsis()),e.register(requireObjectivec()),e.register(requireOcaml()),e.register(requireOpencl()),e.register(requireOpenqasm()),e.register(requireOz()),e.register(requireParigp()),e.register(requireParser()),e.register(requirePascal()),e.register(requirePascaligo()),e.register(requirePcaxis()),e.register(requirePeoplecode()),e.register(requirePerl()),e.register(requirePhpExtras()),e.register(requirePhp()),e.register(requirePhpdoc()),e.register(requirePlsql()),e.register(requirePowerquery()),e.register(requirePowershell()),e.register(requireProcessing()),e.register(requireProlog()),e.register(requirePromql()),e.register(requireProperties$2()),e.register(requireProtobuf()),e.register(requirePsl()),e.register(requirePug()),e.register(requirePuppet()),e.register(requirePure()),e.register(requirePurebasic()),e.register(requirePurescript()),e.register(requirePython()),e.register(requireQ()),e.register(requireQml()),e.register(requireQore()),e.register(requireQsharp()),e.register(requireR()),e.register(requireRacket()),e.register(requireReason()),e.register(requireRegex()),e.register(requireRego()),e.register(requireRenpy()),e.register(requireRest()),e.register(requireRip()),e.register(requireRoboconf()),e.register(requireRobotframework()),e.register(requireRuby()),e.register(requireRust()),e.register(requireSas()),e.register(requireSass()),e.register(requireScala()),e.register(requireScheme()),e.register(requireScss()),e.register(requireShellSession()),e.register(requireSmali()),e.register(requireSmalltalk()),e.register(requireSmarty()),e.register(requireSml()),e.register(requireSolidity()),e.register(requireSolutionFile()),e.register(requireSoy()),e.register(requireSparql()),e.register(requireSplunkSpl()),e.register(requireSqf()),e.register(requireSql()),e.register(requireSquirrel()),e.register(requireStan()),e.register(requireStylus()),e.register(requireSwift()),e.register(requireSystemd()),e.register(requireT4Cs()),e.register(requireT4Templating()),e.register(requireT4Vb()),e.register(requireTap()),e.register(requireTcl()),e.register(requireTextile()),e.register(requireToml()),e.register(requireTremor()),e.register(requireTsx()),e.register(requireTt2()),e.register(requireTurtle()),e.register(requireTwig()),e.register(requireTypescript()),e.register(requireTyposcript()),e.register(requireUnrealscript()),e.register(requireUorazor()),e.register(requireUri$1()),e.register(requireV()),e.register(requireVala()),e.register(requireVbnet()),e.register(requireVelocity()),e.register(requireVerilog()),e.register(requireVhdl()),e.register(requireVim()),e.register(requireVisualBasic()),e.register(requireWarpscript()),e.register(requireWasm()),e.register(requireWebIdl()),e.register(requireWiki()),e.register(requireWolfram()),e.register(requireWren()),e.register(requireXeora()),e.register(requireXmlDoc()),e.register(requireXojo()),e.register(requireXquery()),e.register(requireYaml()),e.register(requireYang()),e.register(requireZig()),refractor_1}var refractorExports=requireRefractor();const refractor=getDefaultExportFromCjs(refractorExports);var highlighter=highlight(refractor,defaultStyle);highlighter.supportedLanguages=supportedLanguages;const oneDark={'code[class*="language-"]':{background:"hsl(220, 13%, 18%)",color:"hsl(220, 14%, 71%)",textShadow:"0 1px rgba(0, 0, 0, 0.3)",fontFamily:'"Fira Code", "Fira Mono", Menlo, Consolas, "DejaVu Sans Mono", monospace',direction:"ltr",textAlign:"left",whiteSpace:"pre",wordSpacing:"normal",wordBreak:"normal",lineHeight:"1.5",MozTabSize:"2",OTabSize:"2",tabSize:"2",WebkitHyphens:"none",MozHyphens:"none",msHyphens:"none",hyphens:"none"},'pre[class*="language-"]':{background:"hsl(220, 13%, 18%)",color:"hsl(220, 14%, 71%)",textShadow:"0 1px rgba(0, 0, 0, 0.3)",fontFamily:'"Fira Code", "Fira Mono", Menlo, Consolas, "DejaVu Sans Mono", monospace',direction:"ltr",textAlign:"left",whiteSpace:"pre",wordSpacing:"normal",wordBreak:"normal",lineHeight:"1.5",MozTabSize:"2",OTabSize:"2",tabSize:"2",WebkitHyphens:"none",MozHyphens:"none",msHyphens:"none",hyphens:"none",padding:"1em",margin:"0.5em 0",overflow:"auto",borderRadius:"0.3em"},'code[class*="language-"]::-moz-selection':{background:"hsl(220, 13%, 28%)",color:"inherit",textShadow:"none"},'code[class*="language-"] *::-moz-selection':{background:"hsl(220, 13%, 28%)",color:"inherit",textShadow:"none"},'pre[class*="language-"] *::-moz-selection':{background:"hsl(220, 13%, 28%)",color:"inherit",textShadow:"none"},'code[class*="language-"]::selection':{background:"hsl(220, 13%, 28%)",color:"inherit",textShadow:"none"},'code[class*="language-"] *::selection':{background:"hsl(220, 13%, 28%)",color:"inherit",textShadow:"none"},'pre[class*="language-"] *::selection':{background:"hsl(220, 13%, 28%)",color:"inherit",textShadow:"none"},':not(pre) > code[class*="language-"]':{padding:"0.2em 0.3em",borderRadius:"0.3em",whiteSpace:"normal"},comment:{color:"hsl(220, 10%, 40%)",fontStyle:"italic"},prolog:{color:"hsl(220, 10%, 40%)"},cdata:{color:"hsl(220, 10%, 40%)"},doctype:{color:"hsl(220, 14%, 71%)"},punctuation:{color:"hsl(220, 14%, 71%)"},entity:{color:"hsl(220, 14%, 71%)",cursor:"help"},"attr-name":{color:"hsl(29, 54%, 61%)"},"class-name":{color:"hsl(29, 54%, 61%)"},boolean:{color:"hsl(29, 54%, 61%)"},constant:{color:"hsl(29, 54%, 61%)"},number:{color:"hsl(29, 54%, 61%)"},atrule:{color:"hsl(29, 54%, 61%)"},keyword:{color:"hsl(286, 60%, 67%)"},property:{color:"hsl(355, 65%, 65%)"},tag:{color:"hsl(355, 65%, 65%)"},symbol:{color:"hsl(355, 65%, 65%)"},deleted:{color:"hsl(355, 65%, 65%)"},important:{color:"hsl(355, 65%, 65%)"},selector:{color:"hsl(95, 38%, 62%)"},string:{color:"hsl(95, 38%, 62%)"},char:{color:"hsl(95, 38%, 62%)"},builtin:{color:"hsl(95, 38%, 62%)"},inserted:{color:"hsl(95, 38%, 62%)"},regex:{color:"hsl(95, 38%, 62%)"},"attr-value":{color:"hsl(95, 38%, 62%)"},"attr-value > .token.punctuation":{color:"hsl(95, 38%, 62%)"},variable:{color:"hsl(207, 82%, 66%)"},operator:{color:"hsl(207, 82%, 66%)"},function:{color:"hsl(207, 82%, 66%)"},url:{color:"hsl(187, 47%, 55%)"},"attr-value > .token.punctuation.attr-equals":{color:"hsl(220, 14%, 71%)"},"special-attr > .token.attr-value > .token.value.css":{color:"hsl(220, 14%, 71%)"},".language-css .token.selector":{color:"hsl(355, 65%, 65%)"},".language-css .token.property":{color:"hsl(220, 14%, 71%)"},".language-css .token.function":{color:"hsl(187, 47%, 55%)"},".language-css .token.url > .token.function":{color:"hsl(187, 47%, 55%)"},".language-css .token.url > .token.string.url":{color:"hsl(95, 38%, 62%)"},".language-css .token.important":{color:"hsl(286, 60%, 67%)"},".language-css .token.atrule .token.rule":{color:"hsl(286, 60%, 67%)"},".language-javascript .token.operator":{color:"hsl(286, 60%, 67%)"},".language-javascript .token.template-string > .token.interpolation > .token.interpolation-punctuation.punctuation":{color:"hsl(5, 48%, 51%)"},".language-json .token.operator":{color:"hsl(220, 14%, 71%)"},".language-json .token.null.keyword":{color:"hsl(29, 54%, 61%)"},".language-markdown .token.url":{color:"hsl(220, 14%, 71%)"},".language-markdown .token.url > .token.operator":{color:"hsl(220, 14%, 71%)"},".language-markdown .token.url-reference.url > .token.string":{color:"hsl(220, 14%, 71%)"},".language-markdown .token.url > .token.content":{color:"hsl(207, 82%, 66%)"},".language-markdown .token.url > .token.url":{color:"hsl(187, 47%, 55%)"},".language-markdown .token.url-reference.url":{color:"hsl(187, 47%, 55%)"},".language-markdown .token.blockquote.punctuation":{color:"hsl(220, 10%, 40%)",fontStyle:"italic"},".language-markdown .token.hr.punctuation":{color:"hsl(220, 10%, 40%)",fontStyle:"italic"},".language-markdown .token.code-snippet":{color:"hsl(95, 38%, 62%)"},".language-markdown .token.bold .token.content":{color:"hsl(29, 54%, 61%)"},".language-markdown .token.italic .token.content":{color:"hsl(286, 60%, 67%)"},".language-markdown .token.strike .token.content":{color:"hsl(355, 65%, 65%)"},".language-markdown .token.strike .token.punctuation":{color:"hsl(355, 65%, 65%)"},".language-markdown .token.list.punctuation":{color:"hsl(355, 65%, 65%)"},".language-markdown .token.title.important > .token.punctuation":{color:"hsl(355, 65%, 65%)"},bold:{fontWeight:"bold"},italic:{fontStyle:"italic"},namespace:{Opacity:"0.8"},"token.tab:not(:empty):before":{color:"hsla(220, 14%, 71%, 0.15)",textShadow:"none"},"token.cr:before":{color:"hsla(220, 14%, 71%, 0.15)",textShadow:"none"},"token.lf:before":{color:"hsla(220, 14%, 71%, 0.15)",textShadow:"none"},"token.space:before":{color:"hsla(220, 14%, 71%, 0.15)",textShadow:"none"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item":{marginRight:"0.4em"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > button":{background:"hsl(220, 13%, 26%)",color:"hsl(220, 9%, 55%)",padding:"0.1em 0.4em",borderRadius:"0.3em"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > a":{background:"hsl(220, 13%, 26%)",color:"hsl(220, 9%, 55%)",padding:"0.1em 0.4em",borderRadius:"0.3em"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > span":{background:"hsl(220, 13%, 26%)",color:"hsl(220, 9%, 55%)",padding:"0.1em 0.4em",borderRadius:"0.3em"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > button:hover":{background:"hsl(220, 13%, 28%)",color:"hsl(220, 14%, 71%)"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > button:focus":{background:"hsl(220, 13%, 28%)",color:"hsl(220, 14%, 71%)"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > a:hover":{background:"hsl(220, 13%, 28%)",color:"hsl(220, 14%, 71%)"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > a:focus":{background:"hsl(220, 13%, 28%)",color:"hsl(220, 14%, 71%)"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > span:hover":{background:"hsl(220, 13%, 28%)",color:"hsl(220, 14%, 71%)"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > span:focus":{background:"hsl(220, 13%, 28%)",color:"hsl(220, 14%, 71%)"},".line-highlight.line-highlight":{background:"hsla(220, 100%, 80%, 0.04)"},".line-highlight.line-highlight:before":{background:"hsl(220, 13%, 26%)",color:"hsl(220, 14%, 71%)",padding:"0.1em 0.6em",borderRadius:"0.3em",boxShadow:"0 2px 0 0 rgba(0, 0, 0, 0.2)"},".line-highlight.line-highlight[data-end]:after":{background:"hsl(220, 13%, 26%)",color:"hsl(220, 14%, 71%)",padding:"0.1em 0.6em",borderRadius:"0.3em",boxShadow:"0 2px 0 0 rgba(0, 0, 0, 0.2)"},"pre[id].linkable-line-numbers.linkable-line-numbers span.line-numbers-rows > span:hover:before":{backgroundColor:"hsla(220, 100%, 80%, 0.04)"},".line-numbers.line-numbers .line-numbers-rows":{borderRightColor:"hsla(220, 14%, 71%, 0.15)"},".command-line .command-line-prompt":{borderRightColor:"hsla(220, 14%, 71%, 0.15)"},".line-numbers .line-numbers-rows > span:before":{color:"hsl(220, 14%, 45%)"},".command-line .command-line-prompt > span:before":{color:"hsl(220, 14%, 45%)"},".rainbow-braces .token.token.punctuation.brace-level-1":{color:"hsl(355, 65%, 65%)"},".rainbow-braces .token.token.punctuation.brace-level-5":{color:"hsl(355, 65%, 65%)"},".rainbow-braces .token.token.punctuation.brace-level-9":{color:"hsl(355, 65%, 65%)"},".rainbow-braces .token.token.punctuation.brace-level-2":{color:"hsl(95, 38%, 62%)"},".rainbow-braces .token.token.punctuation.brace-level-6":{color:"hsl(95, 38%, 62%)"},".rainbow-braces .token.token.punctuation.brace-level-10":{color:"hsl(95, 38%, 62%)"},".rainbow-braces .token.token.punctuation.brace-level-3":{color:"hsl(207, 82%, 66%)"},".rainbow-braces .token.token.punctuation.brace-level-7":{color:"hsl(207, 82%, 66%)"},".rainbow-braces .token.token.punctuation.brace-level-11":{color:"hsl(207, 82%, 66%)"},".rainbow-braces .token.token.punctuation.brace-level-4":{color:"hsl(286, 60%, 67%)"},".rainbow-braces .token.token.punctuation.brace-level-8":{color:"hsl(286, 60%, 67%)"},".rainbow-braces .token.token.punctuation.brace-level-12":{color:"hsl(286, 60%, 67%)"},"pre.diff-highlight > code .token.token.deleted:not(.prefix)":{backgroundColor:"hsla(353, 100%, 66%, 0.15)"},"pre > code.diff-highlight .token.token.deleted:not(.prefix)":{backgroundColor:"hsla(353, 100%, 66%, 0.15)"},"pre.diff-highlight > code .token.token.deleted:not(.prefix)::-moz-selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre.diff-highlight > code .token.token.deleted:not(.prefix) *::-moz-selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre > code.diff-highlight .token.token.deleted:not(.prefix)::-moz-selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre > code.diff-highlight .token.token.deleted:not(.prefix) *::-moz-selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre.diff-highlight > code .token.token.deleted:not(.prefix)::selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre.diff-highlight > code .token.token.deleted:not(.prefix) *::selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre > code.diff-highlight .token.token.deleted:not(.prefix)::selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre > code.diff-highlight .token.token.deleted:not(.prefix) *::selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre.diff-highlight > code .token.token.inserted:not(.prefix)":{backgroundColor:"hsla(137, 100%, 55%, 0.15)"},"pre > code.diff-highlight .token.token.inserted:not(.prefix)":{backgroundColor:"hsla(137, 100%, 55%, 0.15)"},"pre.diff-highlight > code .token.token.inserted:not(.prefix)::-moz-selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre.diff-highlight > code .token.token.inserted:not(.prefix) *::-moz-selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre > code.diff-highlight .token.token.inserted:not(.prefix)::-moz-selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre > code.diff-highlight .token.token.inserted:not(.prefix) *::-moz-selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre.diff-highlight > code .token.token.inserted:not(.prefix)::selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre.diff-highlight > code .token.token.inserted:not(.prefix) *::selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre > code.diff-highlight .token.token.inserted:not(.prefix)::selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre > code.diff-highlight .token.token.inserted:not(.prefix) *::selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},".prism-previewer.prism-previewer:before":{borderColor:"hsl(224, 13%, 17%)"},".prism-previewer-gradient.prism-previewer-gradient div":{borderColor:"hsl(224, 13%, 17%)",borderRadius:"0.3em"},".prism-previewer-color.prism-previewer-color:before":{borderRadius:"0.3em"},".prism-previewer-easing.prism-previewer-easing:before":{borderRadius:"0.3em"},".prism-previewer.prism-previewer:after":{borderTopColor:"hsl(224, 13%, 17%)"},".prism-previewer-flipped.prism-previewer-flipped.after":{borderBottomColor:"hsl(224, 13%, 17%)"},".prism-previewer-angle.prism-previewer-angle:before":{background:"hsl(219, 13%, 22%)"},".prism-previewer-time.prism-previewer-time:before":{background:"hsl(219, 13%, 22%)"},".prism-previewer-easing.prism-previewer-easing":{background:"hsl(219, 13%, 22%)"},".prism-previewer-angle.prism-previewer-angle circle":{stroke:"hsl(220, 14%, 71%)",strokeOpacity:"1"},".prism-previewer-time.prism-previewer-time circle":{stroke:"hsl(220, 14%, 71%)",strokeOpacity:"1"},".prism-previewer-easing.prism-previewer-easing circle":{stroke:"hsl(220, 14%, 71%)",fill:"transparent"},".prism-previewer-easing.prism-previewer-easing path":{stroke:"hsl(220, 14%, 71%)"},".prism-previewer-easing.prism-previewer-easing line":{stroke:"hsl(220, 14%, 71%)"}},oneLight={'code[class*="language-"]':{background:"hsl(230, 1%, 98%)",color:"hsl(230, 8%, 24%)",fontFamily:'"Fira Code", "Fira Mono", Menlo, Consolas, "DejaVu Sans Mono", monospace',direction:"ltr",textAlign:"left",whiteSpace:"pre",wordSpacing:"normal",wordBreak:"normal",lineHeight:"1.5",MozTabSize:"2",OTabSize:"2",tabSize:"2",WebkitHyphens:"none",MozHyphens:"none",msHyphens:"none",hyphens:"none"},'pre[class*="language-"]':{background:"hsl(230, 1%, 98%)",color:"hsl(230, 8%, 24%)",fontFamily:'"Fira Code", "Fira Mono", Menlo, Consolas, "DejaVu Sans Mono", monospace',direction:"ltr",textAlign:"left",whiteSpace:"pre",wordSpacing:"normal",wordBreak:"normal",lineHeight:"1.5",MozTabSize:"2",OTabSize:"2",tabSize:"2",WebkitHyphens:"none",MozHyphens:"none",msHyphens:"none",hyphens:"none",padding:"1em",margin:"0.5em 0",overflow:"auto",borderRadius:"0.3em"},'code[class*="language-"]::-moz-selection':{background:"hsl(230, 1%, 90%)",color:"inherit"},'code[class*="language-"] *::-moz-selection':{background:"hsl(230, 1%, 90%)",color:"inherit"},'pre[class*="language-"] *::-moz-selection':{background:"hsl(230, 1%, 90%)",color:"inherit"},'code[class*="language-"]::selection':{background:"hsl(230, 1%, 90%)",color:"inherit"},'code[class*="language-"] *::selection':{background:"hsl(230, 1%, 90%)",color:"inherit"},'pre[class*="language-"] *::selection':{background:"hsl(230, 1%, 90%)",color:"inherit"},':not(pre) > code[class*="language-"]':{padding:"0.2em 0.3em",borderRadius:"0.3em",whiteSpace:"normal"},comment:{color:"hsl(230, 4%, 64%)",fontStyle:"italic"},prolog:{color:"hsl(230, 4%, 64%)"},cdata:{color:"hsl(230, 4%, 64%)"},doctype:{color:"hsl(230, 8%, 24%)"},punctuation:{color:"hsl(230, 8%, 24%)"},entity:{color:"hsl(230, 8%, 24%)",cursor:"help"},"attr-name":{color:"hsl(35, 99%, 36%)"},"class-name":{color:"hsl(35, 99%, 36%)"},boolean:{color:"hsl(35, 99%, 36%)"},constant:{color:"hsl(35, 99%, 36%)"},number:{color:"hsl(35, 99%, 36%)"},atrule:{color:"hsl(35, 99%, 36%)"},keyword:{color:"hsl(301, 63%, 40%)"},property:{color:"hsl(5, 74%, 59%)"},tag:{color:"hsl(5, 74%, 59%)"},symbol:{color:"hsl(5, 74%, 59%)"},deleted:{color:"hsl(5, 74%, 59%)"},important:{color:"hsl(5, 74%, 59%)"},selector:{color:"hsl(119, 34%, 47%)"},string:{color:"hsl(119, 34%, 47%)"},char:{color:"hsl(119, 34%, 47%)"},builtin:{color:"hsl(119, 34%, 47%)"},inserted:{color:"hsl(119, 34%, 47%)"},regex:{color:"hsl(119, 34%, 47%)"},"attr-value":{color:"hsl(119, 34%, 47%)"},"attr-value > .token.punctuation":{color:"hsl(119, 34%, 47%)"},variable:{color:"hsl(221, 87%, 60%)"},operator:{color:"hsl(221, 87%, 60%)"},function:{color:"hsl(221, 87%, 60%)"},url:{color:"hsl(198, 99%, 37%)"},"attr-value > .token.punctuation.attr-equals":{color:"hsl(230, 8%, 24%)"},"special-attr > .token.attr-value > .token.value.css":{color:"hsl(230, 8%, 24%)"},".language-css .token.selector":{color:"hsl(5, 74%, 59%)"},".language-css .token.property":{color:"hsl(230, 8%, 24%)"},".language-css .token.function":{color:"hsl(198, 99%, 37%)"},".language-css .token.url > .token.function":{color:"hsl(198, 99%, 37%)"},".language-css .token.url > .token.string.url":{color:"hsl(119, 34%, 47%)"},".language-css .token.important":{color:"hsl(301, 63%, 40%)"},".language-css .token.atrule .token.rule":{color:"hsl(301, 63%, 40%)"},".language-javascript .token.operator":{color:"hsl(301, 63%, 40%)"},".language-javascript .token.template-string > .token.interpolation > .token.interpolation-punctuation.punctuation":{color:"hsl(344, 84%, 43%)"},".language-json .token.operator":{color:"hsl(230, 8%, 24%)"},".language-json .token.null.keyword":{color:"hsl(35, 99%, 36%)"},".language-markdown .token.url":{color:"hsl(230, 8%, 24%)"},".language-markdown .token.url > .token.operator":{color:"hsl(230, 8%, 24%)"},".language-markdown .token.url-reference.url > .token.string":{color:"hsl(230, 8%, 24%)"},".language-markdown .token.url > .token.content":{color:"hsl(221, 87%, 60%)"},".language-markdown .token.url > .token.url":{color:"hsl(198, 99%, 37%)"},".language-markdown .token.url-reference.url":{color:"hsl(198, 99%, 37%)"},".language-markdown .token.blockquote.punctuation":{color:"hsl(230, 4%, 64%)",fontStyle:"italic"},".language-markdown .token.hr.punctuation":{color:"hsl(230, 4%, 64%)",fontStyle:"italic"},".language-markdown .token.code-snippet":{color:"hsl(119, 34%, 47%)"},".language-markdown .token.bold .token.content":{color:"hsl(35, 99%, 36%)"},".language-markdown .token.italic .token.content":{color:"hsl(301, 63%, 40%)"},".language-markdown .token.strike .token.content":{color:"hsl(5, 74%, 59%)"},".language-markdown .token.strike .token.punctuation":{color:"hsl(5, 74%, 59%)"},".language-markdown .token.list.punctuation":{color:"hsl(5, 74%, 59%)"},".language-markdown .token.title.important > .token.punctuation":{color:"hsl(5, 74%, 59%)"},bold:{fontWeight:"bold"},italic:{fontStyle:"italic"},namespace:{Opacity:"0.8"},"token.tab:not(:empty):before":{color:"hsla(230, 8%, 24%, 0.2)"},"token.cr:before":{color:"hsla(230, 8%, 24%, 0.2)"},"token.lf:before":{color:"hsla(230, 8%, 24%, 0.2)"},"token.space:before":{color:"hsla(230, 8%, 24%, 0.2)"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item":{marginRight:"0.4em"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > button":{background:"hsl(230, 1%, 90%)",color:"hsl(230, 6%, 44%)",padding:"0.1em 0.4em",borderRadius:"0.3em"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > a":{background:"hsl(230, 1%, 90%)",color:"hsl(230, 6%, 44%)",padding:"0.1em 0.4em",borderRadius:"0.3em"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > span":{background:"hsl(230, 1%, 90%)",color:"hsl(230, 6%, 44%)",padding:"0.1em 0.4em",borderRadius:"0.3em"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > button:hover":{background:"hsl(230, 1%, 78%)",color:"hsl(230, 8%, 24%)"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > button:focus":{background:"hsl(230, 1%, 78%)",color:"hsl(230, 8%, 24%)"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > a:hover":{background:"hsl(230, 1%, 78%)",color:"hsl(230, 8%, 24%)"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > a:focus":{background:"hsl(230, 1%, 78%)",color:"hsl(230, 8%, 24%)"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > span:hover":{background:"hsl(230, 1%, 78%)",color:"hsl(230, 8%, 24%)"},"div.code-toolbar > .toolbar.toolbar > .toolbar-item > span:focus":{background:"hsl(230, 1%, 78%)",color:"hsl(230, 8%, 24%)"},".line-highlight.line-highlight":{background:"hsla(230, 8%, 24%, 0.05)"},".line-highlight.line-highlight:before":{background:"hsl(230, 1%, 90%)",color:"hsl(230, 8%, 24%)",padding:"0.1em 0.6em",borderRadius:"0.3em",boxShadow:"0 2px 0 0 rgba(0, 0, 0, 0.2)"},".line-highlight.line-highlight[data-end]:after":{background:"hsl(230, 1%, 90%)",color:"hsl(230, 8%, 24%)",padding:"0.1em 0.6em",borderRadius:"0.3em",boxShadow:"0 2px 0 0 rgba(0, 0, 0, 0.2)"},"pre[id].linkable-line-numbers.linkable-line-numbers span.line-numbers-rows > span:hover:before":{backgroundColor:"hsla(230, 8%, 24%, 0.05)"},".line-numbers.line-numbers .line-numbers-rows":{borderRightColor:"hsla(230, 8%, 24%, 0.2)"},".command-line .command-line-prompt":{borderRightColor:"hsla(230, 8%, 24%, 0.2)"},".line-numbers .line-numbers-rows > span:before":{color:"hsl(230, 1%, 62%)"},".command-line .command-line-prompt > span:before":{color:"hsl(230, 1%, 62%)"},".rainbow-braces .token.token.punctuation.brace-level-1":{color:"hsl(5, 74%, 59%)"},".rainbow-braces .token.token.punctuation.brace-level-5":{color:"hsl(5, 74%, 59%)"},".rainbow-braces .token.token.punctuation.brace-level-9":{color:"hsl(5, 74%, 59%)"},".rainbow-braces .token.token.punctuation.brace-level-2":{color:"hsl(119, 34%, 47%)"},".rainbow-braces .token.token.punctuation.brace-level-6":{color:"hsl(119, 34%, 47%)"},".rainbow-braces .token.token.punctuation.brace-level-10":{color:"hsl(119, 34%, 47%)"},".rainbow-braces .token.token.punctuation.brace-level-3":{color:"hsl(221, 87%, 60%)"},".rainbow-braces .token.token.punctuation.brace-level-7":{color:"hsl(221, 87%, 60%)"},".rainbow-braces .token.token.punctuation.brace-level-11":{color:"hsl(221, 87%, 60%)"},".rainbow-braces .token.token.punctuation.brace-level-4":{color:"hsl(301, 63%, 40%)"},".rainbow-braces .token.token.punctuation.brace-level-8":{color:"hsl(301, 63%, 40%)"},".rainbow-braces .token.token.punctuation.brace-level-12":{color:"hsl(301, 63%, 40%)"},"pre.diff-highlight > code .token.token.deleted:not(.prefix)":{backgroundColor:"hsla(353, 100%, 66%, 0.15)"},"pre > code.diff-highlight .token.token.deleted:not(.prefix)":{backgroundColor:"hsla(353, 100%, 66%, 0.15)"},"pre.diff-highlight > code .token.token.deleted:not(.prefix)::-moz-selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre.diff-highlight > code .token.token.deleted:not(.prefix) *::-moz-selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre > code.diff-highlight .token.token.deleted:not(.prefix)::-moz-selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre > code.diff-highlight .token.token.deleted:not(.prefix) *::-moz-selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre.diff-highlight > code .token.token.deleted:not(.prefix)::selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre.diff-highlight > code .token.token.deleted:not(.prefix) *::selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre > code.diff-highlight .token.token.deleted:not(.prefix)::selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre > code.diff-highlight .token.token.deleted:not(.prefix) *::selection":{backgroundColor:"hsla(353, 95%, 66%, 0.25)"},"pre.diff-highlight > code .token.token.inserted:not(.prefix)":{backgroundColor:"hsla(137, 100%, 55%, 0.15)"},"pre > code.diff-highlight .token.token.inserted:not(.prefix)":{backgroundColor:"hsla(137, 100%, 55%, 0.15)"},"pre.diff-highlight > code .token.token.inserted:not(.prefix)::-moz-selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre.diff-highlight > code .token.token.inserted:not(.prefix) *::-moz-selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre > code.diff-highlight .token.token.inserted:not(.prefix)::-moz-selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre > code.diff-highlight .token.token.inserted:not(.prefix) *::-moz-selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre.diff-highlight > code .token.token.inserted:not(.prefix)::selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre.diff-highlight > code .token.token.inserted:not(.prefix) *::selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre > code.diff-highlight .token.token.inserted:not(.prefix)::selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},"pre > code.diff-highlight .token.token.inserted:not(.prefix) *::selection":{backgroundColor:"hsla(135, 73%, 55%, 0.25)"},".prism-previewer.prism-previewer:before":{borderColor:"hsl(0, 0, 95%)"},".prism-previewer-gradient.prism-previewer-gradient div":{borderColor:"hsl(0, 0, 95%)",borderRadius:"0.3em"},".prism-previewer-color.prism-previewer-color:before":{borderRadius:"0.3em"},".prism-previewer-easing.prism-previewer-easing:before":{borderRadius:"0.3em"},".prism-previewer.prism-previewer:after":{borderTopColor:"hsl(0, 0, 95%)"},".prism-previewer-flipped.prism-previewer-flipped.after":{borderBottomColor:"hsl(0, 0, 95%)"},".prism-previewer-angle.prism-previewer-angle:before":{background:"hsl(0, 0%, 100%)"},".prism-previewer-time.prism-previewer-time:before":{background:"hsl(0, 0%, 100%)"},".prism-previewer-easing.prism-previewer-easing":{background:"hsl(0, 0%, 100%)"},".prism-previewer-angle.prism-previewer-angle circle":{stroke:"hsl(230, 8%, 24%)",strokeOpacity:"1"},".prism-previewer-time.prism-previewer-time circle":{stroke:"hsl(230, 8%, 24%)",strokeOpacity:"1"},".prism-previewer-easing.prism-previewer-easing circle":{stroke:"hsl(230, 8%, 24%)",fill:"transparent"},".prism-previewer-easing.prism-previewer-easing path":{stroke:"hsl(230, 8%, 24%)"},".prism-previewer-easing.prism-previewer-easing line":{stroke:"hsl(230, 8%, 24%)"}};var toggleSelection,hasRequiredToggleSelection;function requireToggleSelection(){return hasRequiredToggleSelection||(hasRequiredToggleSelection=1,toggleSelection=function(){var e=document.getSelection();if(!e.rangeCount)return function(){};for(var t=document.activeElement,Ye=[],tt=0;tt<e.rangeCount;tt++)Ye.push(e.getRangeAt(tt));switch(t.tagName.toUpperCase()){case"INPUT":case"TEXTAREA":t.blur();break;default:t=null;break}return e.removeAllRanges(),function(){e.type==="Caret"&&e.removeAllRanges(),e.rangeCount||Ye.forEach(function(rt){e.addRange(rt)}),t&&t.focus()}}),toggleSelection}var copyToClipboard,hasRequiredCopyToClipboard;function requireCopyToClipboard(){if(hasRequiredCopyToClipboard)return copyToClipboard;hasRequiredCopyToClipboard=1;var e=requireToggleSelection(),t={"text/plain":"Text","text/html":"Url",default:"Text"},Ye="Copy to clipboard: #{key}, Enter";function tt(nt){var at=(/mac os x/i.test(navigator.userAgent)?"⌘":"Ctrl")+"+C";return nt.replace(/#{\s*key\s*}/g,at)}function rt(nt,at){var it,ot,ct,At,Rt,qt,Ft=!1;at||(at={}),it=at.debug||!1;try{ct=e(),At=document.createRange(),Rt=document.getSelection(),qt=document.createElement("span"),qt.textContent=nt,qt.ariaHidden="true",qt.style.all="unset",qt.style.position="fixed",qt.style.top=0,qt.style.clip="rect(0, 0, 0, 0)",qt.style.whiteSpace="pre",qt.style.webkitUserSelect="text",qt.style.MozUserSelect="text",qt.style.msUserSelect="text",qt.style.userSelect="text",qt.addEventListener("copy",function(Ht){if(Ht.stopPropagation(),at.format)if(Ht.preventDefault(),typeof Ht.clipboardData>"u"){it&&console.warn("unable to use e.clipboardData"),it&&console.warn("trying IE specific stuff"),window.clipboardData.clearData();var zt=t[at.format]||t.default;window.clipboardData.setData(zt,nt)}else Ht.clipboardData.clearData(),Ht.clipboardData.setData(at.format,nt);at.onCopy&&(Ht.preventDefault(),at.onCopy(Ht.clipboardData))}),document.body.appendChild(qt),At.selectNodeContents(qt),Rt.addRange(At);var Ut=document.execCommand("copy");if(!Ut)throw new Error("copy command was unsuccessful");Ft=!0}catch(Ht){it&&console.error("unable to copy using execCommand: ",Ht),it&&console.warn("trying IE specific stuff");try{window.clipboardData.setData(at.format||"text",nt),at.onCopy&&at.onCopy(window.clipboardData),Ft=!0}catch(zt){it&&console.error("unable to copy using clipboardData: ",zt),it&&console.error("falling back to prompt"),ot=tt("message"in at?at.message:Ye),window.prompt(ot,nt)}}finally{Rt&&(typeof Rt.removeRange=="function"?Rt.removeRange(At):Rt.removeAllRanges()),qt&&document.body.removeChild(qt),ct()}return Ft}return copyToClipboard=rt,copyToClipboard}var copyToClipboardExports=requireCopyToClipboard();const copy=getDefaultExportFromCjs(copyToClipboardExports),CodeBlockContext$1=reactExports.createContext({code:""}),CodeBlock$1=({code:e,language:t,showLineNumbers:Ye=!1,className:tt,children:rt,...nt})=>jsxRuntimeExports.jsx(CodeBlockContext$1.Provider,{value:{code:e},children:jsxRuntimeExports.jsx("div",{className:cn$2("relative w-full overflow-hidden rounded-md border bg-background text-foreground",tt),...nt,children:jsxRuntimeExports.jsxs("div",{className:"relative",children:[jsxRuntimeExports.jsx(highlighter,{className:"overflow-hidden dark:hidden",codeTagProps:{className:"font-mono text-sm"},customStyle:{margin:0,padding:"1rem",fontSize:"0.875rem",background:"hsl(var(--background))",color:"hsl(var(--foreground))"},language:t,lineNumberStyle:{color:"hsl(var(--muted-foreground))",paddingRight:"1rem",minWidth:"2.5rem"},showLineNumbers:Ye,style:oneLight,children:e}),jsxRuntimeExports.jsx(highlighter,{className:"hidden overflow-hidden dark:block",codeTagProps:{className:"font-mono text-sm"},customStyle:{margin:0,padding:"1rem",fontSize:"0.875rem",background:"hsl(var(--background))",color:"hsl(var(--foreground))"},language:t,lineNumberStyle:{color:"hsl(var(--muted-foreground))",paddingRight:"1rem",minWidth:"2.5rem"},showLineNumbers:Ye,style:oneDark,children:e}),rt&&jsxRuntimeExports.jsx("div",{className:"absolute top-2 right-2 flex items-center gap-2",children:rt})]})})}),HumanInTheLoopControls=({tool:e})=>{const t=e.getHumanInTheLoopData();if(!t)return null;const Ye=t.reviewConfig,tt=t.actionRequest;return Ye?jsxRuntimeExports.jsx("div",{className:"flex gap-2",children:Ye.allowedDecisions.map(rt=>rt==="approve"?jsxRuntimeExports.jsx("button",{className:"px-3 py-1 text-xs font-medium text-green-700 bg-green-50 border border-green-200 rounded-lg hover:bg-green-100 transition-colors cursor-pointer",onClick:()=>e.sendResumeData({type:"approve"}),children:"Approve"},rt):rt==="reject"?jsxRuntimeExports.jsx("button",{className:"px-3 py-1 text-xs font-medium text-red-700 bg-red-50 border border-red-200 rounded-lg hover:bg-red-100 transition-colors cursor-pointer",onClick:()=>{const nt=window.prompt("Please enter rejection reason:");nt!==null&&e.sendResumeData({type:"reject",message:nt||void 0})},children:"Reject"},rt):rt==="edit"?jsxRuntimeExports.jsx("button",{className:"px-3 py-1 text-xs font-medium text-blue-700 bg-blue-50 border border-blue-200 rounded-lg hover:bg-blue-100 transition-colors cursor-pointer",onClick:()=>{const nt=JSON.stringify(tt.args),at=window.prompt("Edit tool arguments (JSON):",nt);if(at!==null)try{const it=JSON.parse(at);e.sendResumeData({type:"edit",edited_action:{name:tt.name,args:it}})}catch{alert("Invalid JSON")}},children:"Edit"},rt):rt==="respond"?jsxRuntimeExports.jsx("button",{className:"px-3 py-1 text-xs font-medium text-purple-700 bg-purple-50 border border-purple-200 rounded-lg hover:bg-purple-100 transition-colors cursor-pointer",onClick:()=>{const nt=window.prompt("Please enter response message:");nt!==null&&e.sendResumeData({type:"respond",message:nt||void 0})},children:"Respond"},rt):null)}):null},getStatusColor=e=>{switch(e){case"done":return"text-green-600 bg-green-50 border-green-200";case"loading":return"text-blue-600 bg-blue-50 border-blue-200";case"processing":return"text-orange-600 bg-orange-50 border-orange-200";case"idle":default:return"text-gray-600 bg-gray-50 border-gray-200"}},getStatusIcon=e=>{switch(e){case"done":return"✓";case"loading":return"⟳";case"processing":return"⋯";case"idle":default:return"○"}},TOOL_COLORS=["bg-white","bg-white","bg-white","bg-white","bg-white","bg-white","bg-white"],getToolColorClass=(e="")=>{let t=0;for(let tt=0;tt<e.length;tt++)t=e.charCodeAt(tt)+((t<<5)-t);const Ye=Math.abs(t%TOOL_COLORS.length);return TOOL_COLORS[Ye]},MessageTool=({message:e})=>{var ot,ct;const[t,Ye]=reactExports.useState(!1),{getToolUIRender:tt,client:rt}=useChat(),nt=tt(e.name||""),at=getToolColorClass(e.name||""),it=new ToolRenderData(e,rt);return jsxRuntimeExports.jsxs("div",{className:"flex flex-col w-full",children:[nt?nt(e):jsxRuntimeExports.jsxs("div",{className:`flex flex-col w-full ${at} rounded-2xl overflow-hidden`,children:[jsxRuntimeExports.jsxs("div",{className:"flex items-center justify-between px-5 py-3 cursor-pointer hover:bg-gray-100 transition-colors",onClick:()=>Ye(!t),children:[jsxRuntimeExports.jsxs("div",{className:"text-xs font-medium text-gray-600",onClick:()=>console.log(e),children:[e.node_name," | ",e.name]}),jsxRuntimeExports.jsxs("div",{className:"flex gap-2",children:[it.state==="interrupted"?jsxRuntimeExports.jsx(HumanInTheLoopControls,{tool:it}):null,jsxRuntimeExports.jsxs("div",{className:`inline-flex items-center gap-1 px-2 py-1 text-xs font-medium rounded-md border ${getStatusColor(it.state)}`,children:[jsxRuntimeExports.jsx("span",{children:getStatusIcon(it.state)}),jsxRuntimeExports.jsx("span",{children:it.state})]})]})]}),!t&&jsxRuntimeExports.jsxs("div",{className:"flex flex-col gap-4 px-5 pb-4",children:[(ot=e.additional_kwargs)!=null&&ot.reasoning_content?jsxRuntimeExports.jsx(Reasoning,{message:e}):null,jsxRuntimeExports.jsx(Previewer,{content:JSON.stringify(it.getInputRepaired(),null,2)||"",mode:"json"}),jsxRuntimeExports.jsx(Previewer,{content:getMessageContent(e.content)}),jsxRuntimeExports.jsx(UsageMetadata,{response_metadata:e.response_metadata,usage_metadata:e.usage_metadata||{},spend_time:e.spend_time,id:e.id,tool_call_id:e.tool_call_id})]})]}),(ct=e.sub_messages)!=null&&ct.length?jsxRuntimeExports.jsx("div",{className:"flex flex-col pl-6 py-3 ml-4 border-l-2 border-gray-200",children:jsxRuntimeExports.jsx(MessagesBox,{renderMessages:e.sub_messages})}):null]})},Previewer=({content:e,mode:t})=>{const Ye=()=>{try{return JSON.parse(e),!0}catch{return!1}},tt=t==="json"||e.startsWith("{")&&e.endsWith("}")&&Ye(),rt=t==="markdown"||e.includes("#")||e.includes("```")||e.includes("*"),[nt,at]=reactExports.useState(tt),[it,ot]=reactExports.useState(!1),ct=()=>{copy(e)};return jsxRuntimeExports.jsxs("div",{className:"flex flex-col",children:[jsxRuntimeExports.jsxs("div",{className:"flex gap-2 mb-2",children:[jsxRuntimeExports.jsx("button",{onClick:ct,className:"px-3 py-1 text-xs font-medium text-gray-700 bg-white border border-gray-200 rounded-lg hover:bg-gray-100 transition-colors",children:"copy"}),tt&&jsxRuntimeExports.jsx("button",{onClick:()=>at(!nt),className:"px-3 py-1 text-xs font-medium text-gray-700 bg-white border border-gray-200 rounded-lg hover:bg-gray-100 transition-colors",children:"json"}),rt&&jsxRuntimeExports.jsx("button",{onClick:()=>ot(!it),className:"px-3 py-1 text-xs font-medium text-gray-700 bg-white border border-gray-200 rounded-lg hover:bg-gray-100 transition-colors",children:"markdown"})]}),jsxRuntimeExports.jsx("div",{className:"flex flex-col max-h-[300px] bg-white border border-gray-200 rounded-xl p-3 w-full text-xs font-mono",children:jsxRuntimeExports.jsx("div",{className:"overflow-auto max-h-full",children:nt&&tt?jsxRuntimeExports.jsx("div",{className:"overflow-visible",children:jsxRuntimeExports.jsx(CodeBlock$1,{code:JSON.stringify(JSON.parse(e),null,2),language:"json"})}):it&&rt?jsxRuntimeExports.jsx("div",{className:"whitespace-pre-wrap",children:jsxRuntimeExports.jsx(Response$1,{children:e})}):jsxRuntimeExports.jsx("pre",{className:" whitespace-pre-wrap",style:{overflowWrap:"break-word"},children:jsxRuntimeExports.jsx("code",{className:"whitespace-pre-wrap",children:e})})})})]})},MessagesBox=({renderMessages:e})=>{const[t,Ye]=reactExports.useState(new Map),tt=reactExports.useRef(new Map),rt=reactExports.useCallback((it,ot)=>{Ye(ct=>{const At=new Map(ct),Rt=At.get(it)||{showDetail:!1,showContextMenu:!1,contextMenuPosition:{x:0,y:0}};return At.set(it,{...Rt,...ot}),At})},[]),nt=reactExports.useCallback((it,ot)=>{it.preventDefault(),rt(ot,{contextMenuPosition:{x:it.clientX,y:it.clientY},showContextMenu:!0})},[rt]),at=reactExports.useCallback(it=>{rt(it,{showContextMenu:!1})},[rt]);return reactExports.useEffect(()=>{const it=ot=>{t.forEach((ct,At)=>{if(ct.showContextMenu){const Rt=tt.current.get(At);Rt&&!Rt.contains(ot.target)&&at(At)}})};return Array.from(t.values()).some(ot=>ot.showContextMenu)&&document.addEventListener("click",it),()=>{document.removeEventListener("click",it)}},[t,at]),jsxRuntimeExports.jsx("div",{className:"flex flex-col gap-5 w-full",children:e.map((it,ot)=>{const ct=it.unique_id||`message-${ot}`,At=t.get(ct)||{showDetail:!1};return jsxRuntimeExports.jsxs("div",{ref:Rt=>{Rt&&tt.current.set(ct,Rt)},onContextMenu:Rt=>nt(Rt,ct),children:[it.type==="human"?jsxRuntimeExports.jsx(MessageHuman,{message:it,content:it.content}):it.type==="tool"?jsxRuntimeExports.jsx(MessageTool,{message:it}):jsxRuntimeExports.jsx(MessageAI,{message:it}),At.showDetail&&jsxRuntimeExports.jsx(CodeBlock$1,{code:JSON.stringify(it,null,2),language:"json"})]},ct)})})},HistoryList=({onClose:e})=>{const{historyList:t,currentChatId:Ye,refreshHistoryList:tt,createNewChat:rt,deleteHistoryChat:nt,toHistoryChat:at}=useChat();return jsxRuntimeExports.jsxs("section",{className:"bg-white h-full flex flex-col ",children:[jsxRuntimeExports.jsxs("div",{className:"px-5 flex justify-between items-center py-6",children:[jsxRuntimeExports.jsx("div",{className:"flex items-center gap-3",children:jsxRuntimeExports.jsx("h3",{className:"m-0 text-base font-semibold text-gray-700",children:"历史记录"})}),jsxRuntimeExports.jsx("button",{className:"p-2 rounded-lg bg-gray-100 hover:bg-gray-300 transition-colors flex items-center justify-center group",onClick:tt,title:"刷新列表",children:jsxRuntimeExports.jsx(RefreshCw$1,{className:"w-4 h-4 text-gray-600 group-hover:rotate-180 transition-transform duration-300"})}),jsxRuntimeExports.jsx("button",{className:"p-2 rounded-lg bg-gray-100 hover:bg-gray-300 transition-colors flex items-center justify-center group",onClick:e,title:"关闭",children:jsxRuntimeExports.jsx(X$6,{className:"w-4 h-4 text-red-500"})})]}),jsxRuntimeExports.jsxs("div",{className:"flex-1 overflow-y-auto px-4 py-2",children:[jsxRuntimeExports.jsx("div",{className:"cursor-pointer mb-3",onClick:()=>{rt()},children:jsxRuntimeExports.jsx("div",{className:"flex justify-between items-center px-4 py-3 rounded-xl bg-blue-50/80 hover:bg-blue-200/80 transition-colors",children:jsxRuntimeExports.jsx("div",{className:"text-sm text-gray-700 font-medium truncate",children:"New Chat"})})}),t.length===0?jsxRuntimeExports.jsx("div",{className:"text-center text-gray-400 py-10 text-sm",children:"暂无历史记录"}):jsxRuntimeExports.jsx("div",{className:"flex flex-col gap-2",children:t.sort((it,ot)=>new Date(ot.created_at).getTime()-new Date(it.created_at).getTime()).map(it=>jsxRuntimeExports.jsxs("div",{className:`flex justify-between items-center px-4 py-3 rounded-xl transition-colors ${it.thread_id===Ye?"bg-blue-50/80":"bg-gray-50/60 hover:bg-gray-200/80"}`,children:[jsxRuntimeExports.jsxs("div",{className:"flex-1 min-w-0 mr-2",onClick:()=>{at(it)},children:[jsxRuntimeExports.jsx("div",{className:"text-sm text-gray-700 mb-1 truncate max-w-[180px]",children:getHistoryContent(it)}),jsxRuntimeExports.jsxs("div",{className:"flex gap-3 text-xs text-gray-400",children:[jsxRuntimeExports.jsx("span",{className:"truncate max-w-[100px]",children:formatTime(new Date(it.created_at))}),jsxRuntimeExports.jsx("span",{className:"truncate max-w-[60px]",children:it.status})]})]}),jsxRuntimeExports.jsxs("div",{className:"flex gap-1.5 shrink-0",children:[jsxRuntimeExports.jsx("button",{className:"p-2 rounded-lg bg-white/60 hover:bg-gray-200 transition-colors flex items-center justify-center group",onClick:()=>{at(it)},title:"恢复对话",children:jsxRuntimeExports.jsx(RotateCcw,{className:"w-3.5 h-3.5 text-gray-600 group-hover:-rotate-180 transition-transform duration-300"})}),jsxRuntimeExports.jsx("button",{className:"p-2 rounded-lg bg-white/60 hover:bg-gray-200 transition-colors flex items-center justify-center group",onClick:async()=>{await nt(it)},title:"删除对话",children:jsxRuntimeExports.jsx(Trash2,{className:"w-3.5 h-3.5 text-red-500"})})]})]},it.thread_id))})]})]})};class FileUploadClient{constructor(t={}){Cr(this,"apiUrl");this.apiUrl=t.apiUrl||""}createFormData(t,Ye){const tt=new FormData;if(typeof t=="string"){const rt=new Blob([t],{type:"text/plain"});tt.append("file",rt,Ye||"file.txt")}else tt.append("file",t,Ye||(t instanceof File?t.name:"file"));return tt}async upload(t,Ye={}){const rt={method:"POST",body:this.createFormData(t,Ye.filename)};Ye.signal&&(rt.signal=Ye.signal);try{const nt=await fetch(`${this.apiUrl}${this.getUploadEndpoint()}`,rt);if(!nt.ok)throw new Error(`Upload failed with status: ${nt.status}`);const at=await nt.json();return this.processResponse(at)}catch(nt){throw new Error(`File upload failed: ${nt instanceof Error?nt.message:String(nt)}`)}}}class TmpFilesClient extends FileUploadClient{constructor(t={}){super({apiUrl:t.apiUrl||"https://tmpfiles.org/api/v1"})}getUploadEndpoint(){return"/upload"}processResponse(t){var Ye;return(Ye=t.data)!=null&&Ye.url&&(t.data.url=t.data.url.replace("//tmpfiles.org/","//tmpfiles.org/dl/")),t}}const FileListContext=reactExports.createContext(void 0),useFileList=()=>{const e=reactExports.useContext(FileListContext);if(!e)throw new Error("useFileList must be used within a FileListProvider");return e},FileListProvider=({children:e})=>{const[t,Ye]=reactExports.useState([]),[tt,rt]=reactExports.useState([]),[nt,at]=reactExports.useState({image:!1,video:!1,audio:!1,other:!0}),it=3,ot=new TmpFilesClient,ct=reactExports.useCallback((Ut,Ht)=>{Ht==="image"?rt(zt=>[...zt,{type:"image_url",image_url:{url:Ut},fileType:Ht}]):Ht==="video"?rt(zt=>[...zt,{type:"video_url",video_url:{url:Ut},fileType:Ht}]):Ht==="audio"?rt(zt=>[...zt,{type:"audio_url",audio_url:{url:Ut},fileType:Ht}]):Ht==="other"&&rt(zt=>[...zt,{type:"file_url",file_url:{url:Ut},fileType:Ht}])},[]),At=reactExports.useCallback((Ut,Ht)=>{rt(zt=>zt.filter(Yt=>{var Vt,Zt,Xt,Qt;return(((Vt=Yt.image_url)==null?void 0:Vt.url)||((Zt=Yt.video_url)==null?void 0:Zt.url)||((Xt=Yt.audio_url)==null?void 0:Xt.url)||((Qt=Yt.file_url)==null?void 0:Qt.url))!==Ut}))},[]),Rt=reactExports.useCallback(async Ut=>{var Yt;const zt=Array.from(Ut.target.files||[]);if(t.length+zt.length>it){alert(`最多只能上传${it}个文件`),Ut.target.value="";return}for(const Gt of zt)try{const Vt=await ot.upload(Gt);if((Yt=Vt.data)!=null&&Yt.url){const Zt=getFileType(Gt);if(Zt){const Xt={file:Gt,url:Vt.data.url,type:Zt};Ye(Qt=>[...Qt,Xt]),ct(Vt.data.url,Zt)}}}catch(Vt){console.error("Upload failed:",Vt)}Ut.target.value=""},[t.length,ct]),qt=reactExports.useCallback(Ut=>{const Ht=t[Ut];Ht&&(Ye(zt=>zt.filter((Yt,Gt)=>Gt!==Ut)),At(Ht.url,Ht.type))},[t,At]),Ft={uploadedFiles:t,mediaUrls:tt,isFileTextMode:nt,setIsFileTextMode:at,handleFileUploaded:ct,handleFileRemoved:At,handleFileChange:Rt,removeFile:qt,MAX_FILES:it};return jsxRuntimeExports.jsx(FileListContext.Provider,{value:Ft,children:e})},getFileType=e=>e.type.startsWith("image/")?"image":e.type==="video/mp4"?"video":e.type.startsWith("audio/")?"audio":"other",FileList=()=>{const{uploadedFiles:e,removeFile:t,mediaUrls:Ye,setIsFileTextMode:tt,isFileTextMode:rt}=useFileList();return jsxRuntimeExports.jsxs("div",{children:[Ye.length>0&&jsxRuntimeExports.jsxs("div",{className:"flex items-center gap-2 text-xs text-gray-600 mb-3",title:"文本传输将会把多模态文件转为 XML + URL 的格式传递给大模型",children:[jsxRuntimeExports.jsx("span",{children:"启动文本传输:"}),jsxRuntimeExports.jsx("button",{onClick:()=>tt(nt=>({...nt,image:!nt.image})),className:`px-2 py-1 rounded ${rt.image?"bg-blue-100 text-blue-700":"bg-gray-100 text-gray-500"}`,children:"图片"}),jsxRuntimeExports.jsx("button",{onClick:()=>tt(nt=>({...nt,video:!nt.video})),className:`px-2 py-1 rounded ${rt.video?"bg-blue-100 text-blue-700":"bg-gray-100 text-gray-500"}`,children:"视频"}),jsxRuntimeExports.jsx("button",{onClick:()=>tt(nt=>({...nt,audio:!nt.audio})),className:`px-2 py-1 rounded ${rt.audio?"bg-blue-100 text-blue-700":"bg-gray-100 text-gray-500"}`,children:"音频"}),jsxRuntimeExports.jsx("button",{onClick:()=>tt(nt=>({...nt,other:!nt.other})),className:`px-2 py-1 rounded ${rt.other?"bg-blue-100 text-blue-700":"bg-gray-100 text-gray-500"}`,children:"其他"})]}),jsxRuntimeExports.jsx("div",{className:"flex flex-wrap gap-2",children:e.map((nt,at)=>{const{file:it,type:ot,url:ct}=nt;return jsxRuntimeExports.jsxs("div",{className:"relative w-20 h-20 rounded-xl overflow-hidden border border-gray-200",children:[ot==="image"?jsxRuntimeExports.jsx("img",{src:URL.createObjectURL(it),alt:it.name,className:"w-full h-full object-cover"}):ot==="video"?jsxRuntimeExports.jsx("video",{src:URL.createObjectURL(it),className:"w-full h-full object-cover"}):ot==="audio"?jsxRuntimeExports.jsx("div",{className:"w-full h-full bg-gray-100 flex items-center justify-center",children:jsxRuntimeExports.jsx("svg",{viewBox:"0 0 24 24",width:"24",height:"24",fill:"currentColor",className:"text-gray-500",children:jsxRuntimeExports.jsx("path",{d:"M12 3v10.55c-.59-.34-1.27-.55-2-.55-2.21 0-4 1.79-4 4s1.79 4 4 4 4-1.79 4-4V7h4V3h-6z"})})}):ot==="other"?jsxRuntimeExports.jsx("div",{className:"w-full h-full bg-gray-100 flex items-center justify-center",children:jsxRuntimeExports.jsx("svg",{viewBox:"0 0 24 24",width:"24",height:"24",fill:"currentColor",className:"text-gray-500",children:jsxRuntimeExports.jsx("path",{d:"M14,2H6A2,2 0 0,0 4,4V20A2,2 0 0,0 6,22H18A2,2 0 0,0 20,20V8L14,2M18,20H6V4H13V9H18V20Z"})})}):null,jsxRuntimeExports.jsx("button",{className:"absolute top-1 right-1 w-5 h-5 bg-red-500/90 text-white rounded-full flex items-center justify-center text-sm leading-none hover:bg-red-600 transition-colors backdrop-blur-sm",onClick:()=>t(at),children:"×"})]},at)})})," "]})},LOCAL_STORAGE_KEY="json-editor-presets",ACTIVE_TAB_STORAGE_KEY="json-editor-active-tab",JsonEditorPopup=({isOpen:e,initialJson:t,onClose:Ye,onSave:tt,title:rt,description:nt})=>{const[at,it]=reactExports.useState([]),[ot,ct]=reactExports.useState(0),[At,Rt]=reactExports.useState(""),[qt,Ft]=reactExports.useState(null),[Ut,Ht]=reactExports.useState(null),[zt,Yt]=reactExports.useState("");if(reactExports.useEffect(()=>{if(e){let er=[];try{const ar=localStorage.getItem(LOCAL_STORAGE_KEY);er=ar?JSON.parse(ar):[]}catch(ar){console.error("Failed to parse presets from localStorage",ar),er=[]}er.length===0&&(er=[{name:"Default",data:t}]),it(er);let nr=0;try{const ar=localStorage.getItem(ACTIVE_TAB_STORAGE_KEY);if(ar){const sr=parseInt(ar,10);sr>=0&&sr<er.length&&(nr=sr)}}catch(ar){console.error("Failed to parse active tab from localStorage",ar)}ct(nr),Ft(null)}},[e,t]),reactExports.useEffect(()=>{e&&at.length>0&&at[ot]&&(Rt(JSON.stringify(at[ot].data,null,2)),Ft(null))},[ot,at,e]),reactExports.useEffect(()=>{e&&localStorage.setItem(ACTIVE_TAB_STORAGE_KEY,ot.toString())},[ot,e]),!e)return null;const Gt=er=>{it(er),localStorage.setItem(LOCAL_STORAGE_KEY,JSON.stringify(er))},Vt=()=>{const er={name:`Preset ${at.length+1}`,data:{}},nr=[...at,er];Gt(nr),ct(nr.length-1)},Zt=er=>{let nr=at.filter((ar,sr)=>sr!==er);nr.length===0&&(nr=[{name:"Default",data:t}]),Gt(nr),ot>=er&&ot>0?ct(ot-1):ot>=nr.length&&ct(nr.length-1)},Xt=()=>{try{const er=JSON.parse(At),nr=at.map((ar,sr)=>sr===ot?{...ar,data:er}:ar);Gt(nr),tt(er),Ye()}catch(er){Ft("JSON 格式无效,请检查后重试。"),console.error("Invalid JSON format:",er)}},Qt=er=>{if(zt.trim()!==""){const nr=at.map((ar,sr)=>sr===er?{...ar,name:zt.trim()}:ar);Gt(nr),Ht(null)}};return jsxRuntimeExports.jsx("div",{className:"fixed inset-0 bg-black/30 backdrop-blur-sm flex items-center justify-center z-50",children:jsxRuntimeExports.jsxs("div",{className:"bg-white rounded-2xl w-full max-w-2xl mx-4 flex flex-col overflow-hidden",style:{height:"80vh"},children:[jsxRuntimeExports.jsx("div",{className:"px-6 py-5 bg-white/80 backdrop-blur-sm",children:jsxRuntimeExports.jsx("h2",{className:"text-lg font-semibold text-gray-800",children:rt})}),jsxRuntimeExports.jsx("div",{className:"px-6 py-4 text-sm text-gray-500",children:nt}),jsxRuntimeExports.jsxs("nav",{className:"flex-grow px-6 py-4 overflow-y-auto",children:[jsxRuntimeExports.jsxs("div",{className:"flex items-center mb-4 gap-2",children:[at.map((er,nr)=>jsxRuntimeExports.jsxs("div",{className:`flex items-center px-4 py-2 rounded-xl cursor-pointer text-sm font-medium transition-colors ${ot===nr?"bg-blue-50 text-blue-600":"bg-gray-50 text-gray-600 hover:bg-gray-100"}`,onDoubleClick:()=>{Ht(nr),Yt(er.name)},onClick:()=>ct(nr),children:[Ut===nr?jsxRuntimeExports.jsx("input",{type:"text",value:zt,onChange:ar=>Yt(ar.target.value),onBlur:()=>Qt(nr),onKeyDown:ar=>ar.key==="Enter"&&Qt(nr),className:"text-sm p-0 border-none focus:ring-0 bg-transparent",autoFocus:!0}):jsxRuntimeExports.jsx("span",{children:er.name}),jsxRuntimeExports.jsx("button",{onClick:ar=>{ar.stopPropagation(),Zt(nr)},className:"ml-2 text-gray-400 hover:text-gray-600 w-4 h-4 flex items-center justify-center transition-colors",children:"×"})]},nr)),jsxRuntimeExports.jsx("button",{onClick:Vt,className:"px-3 py-2 text-sm text-gray-500 hover:text-gray-700 bg-gray-50 rounded-xl hover:bg-gray-100 transition-colors",children:"+"})]}),jsxRuntimeExports.jsx("textarea",{value:At,onChange:er=>{Rt(er.target.value),Ft(null)},className:"w-full h-full px-4 py-3 bg-gray-50 rounded-xl font-mono text-sm focus:outline-none focus:bg-gray-100 transition-colors"}),qt&&jsxRuntimeExports.jsx("p",{className:"mt-2 text-sm text-red-600",children:qt})]}),jsxRuntimeExports.jsxs("div",{className:"flex justify-end gap-3 px-6 py-5 bg-gray-50/50",children:[jsxRuntimeExports.jsx("button",{onClick:Ye,className:"px-5 py-2.5 text-sm font-medium text-gray-700 bg-white rounded-xl hover:bg-gray-100 focus:outline-none transition-colors",children:"取消"}),jsxRuntimeExports.jsx("button",{onClick:Xt,className:"px-5 py-2.5 text-sm font-medium text-white bg-blue-500 rounded-xl hover:bg-blue-600 focus:outline-none transition-colors",children:"保存并使用"})]})]})})};function cc(e){if(typeof e=="string"||typeof e=="number")return""+e;let t="";if(Array.isArray(e))for(let Ye=0,tt;Ye<e.length;Ye++)(tt=cc(e[Ye]))!==""&&(t+=(t&&" ")+tt);else for(let Ye in e)e[Ye]&&(t+=(t&&" ")+Ye);return t}var noop$1={value:()=>{}};function dispatch(){for(var e=0,t=arguments.length,Ye={},tt;e<t;++e){if(!(tt=arguments[e]+"")||tt in Ye||/[\s.]/.test(tt))throw new Error("illegal type: "+tt);Ye[tt]=[]}return new Dispatch(Ye)}function Dispatch(e){this._=e}function parseTypenames$1(e,t){return e.trim().split(/^|\s+/).map(function(Ye){var tt="",rt=Ye.indexOf(".");if(rt>=0&&(tt=Ye.slice(rt+1),Ye=Ye.slice(0,rt)),Ye&&!t.hasOwnProperty(Ye))throw new Error("unknown type: "+Ye);return{type:Ye,name:tt}})}Dispatch.prototype=dispatch.prototype={constructor:Dispatch,on:function(e,t){var Ye=this._,tt=parseTypenames$1(e+"",Ye),rt,nt=-1,at=tt.length;if(arguments.length<2){for(;++nt<at;)if((rt=(e=tt[nt]).type)&&(rt=get$2(Ye[rt],e.name)))return rt;return}if(t!=null&&typeof t!="function")throw new Error("invalid callback: "+t);for(;++nt<at;)if(rt=(e=tt[nt]).type)Ye[rt]=set$2(Ye[rt],e.name,t);else if(t==null)for(rt in Ye)Ye[rt]=set$2(Ye[rt],e.name,null);return this},copy:function(){var e={},t=this._;for(var Ye in t)e[Ye]=t[Ye].slice();return new Dispatch(e)},call:function(e,t){if((rt=arguments.length-2)>0)for(var Ye=new Array(rt),tt=0,rt,nt;tt<rt;++tt)Ye[tt]=arguments[tt+2];if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(nt=this._[e],tt=0,rt=nt.length;tt<rt;++tt)nt[tt].value.apply(t,Ye)},apply:function(e,t,Ye){if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(var tt=this._[e],rt=0,nt=tt.length;rt<nt;++rt)tt[rt].value.apply(t,Ye)}};function get$2(e,t){for(var Ye=0,tt=e.length,rt;Ye<tt;++Ye)if((rt=e[Ye]).name===t)return rt.value}function set$2(e,t,Ye){for(var tt=0,rt=e.length;tt<rt;++tt)if(e[tt].name===t){e[tt]=noop$1,e=e.slice(0,tt).concat(e.slice(tt+1));break}return Ye!=null&&e.push({name:t,value:Ye}),e}var xhtml="http://www.w3.org/1999/xhtml";const namespaces={svg:"http://www.w3.org/2000/svg",xhtml,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function namespace(e){var t=e+="",Ye=t.indexOf(":");return Ye>=0&&(t=e.slice(0,Ye))!=="xmlns"&&(e=e.slice(Ye+1)),namespaces.hasOwnProperty(t)?{space:namespaces[t],local:e}:e}function creatorInherit(e){return function(){var t=this.ownerDocument,Ye=this.namespaceURI;return Ye===xhtml&&t.documentElement.namespaceURI===xhtml?t.createElement(e):t.createElementNS(Ye,e)}}function creatorFixed(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function creator(e){var t=namespace(e);return(t.local?creatorFixed:creatorInherit)(t)}function none(){}function selector(e){return e==null?none:function(){return this.querySelector(e)}}function selection_select(e){typeof e!="function"&&(e=selector(e));for(var t=this._groups,Ye=t.length,tt=new Array(Ye),rt=0;rt<Ye;++rt)for(var nt=t[rt],at=nt.length,it=tt[rt]=new Array(at),ot,ct,At=0;At<at;++At)(ot=nt[At])&&(ct=e.call(ot,ot.__data__,At,nt))&&("__data__"in ot&&(ct.__data__=ot.__data__),it[At]=ct);return new Selection$1(tt,this._parents)}function array(e){return e==null?[]:Array.isArray(e)?e:Array.from(e)}function empty(){return[]}function selectorAll(e){return e==null?empty:function(){return this.querySelectorAll(e)}}function arrayAll(e){return function(){return array(e.apply(this,arguments))}}function selection_selectAll(e){typeof e=="function"?e=arrayAll(e):e=selectorAll(e);for(var t=this._groups,Ye=t.length,tt=[],rt=[],nt=0;nt<Ye;++nt)for(var at=t[nt],it=at.length,ot,ct=0;ct<it;++ct)(ot=at[ct])&&(tt.push(e.call(ot,ot.__data__,ct,at)),rt.push(ot));return new Selection$1(tt,rt)}function matcher(e){return function(){return this.matches(e)}}function childMatcher(e){return function(t){return t.matches(e)}}var find=Array.prototype.find;function childFind(e){return function(){return find.call(this.children,e)}}function childFirst(){return this.firstElementChild}function selection_selectChild(e){return this.select(e==null?childFirst:childFind(typeof e=="function"?e:childMatcher(e)))}var filter=Array.prototype.filter;function children$1(){return Array.from(this.children)}function childrenFilter(e){return function(){return filter.call(this.children,e)}}function selection_selectChildren(e){return this.selectAll(e==null?children$1:childrenFilter(typeof e=="function"?e:childMatcher(e)))}function selection_filter(e){typeof e!="function"&&(e=matcher(e));for(var t=this._groups,Ye=t.length,tt=new Array(Ye),rt=0;rt<Ye;++rt)for(var nt=t[rt],at=nt.length,it=tt[rt]=[],ot,ct=0;ct<at;++ct)(ot=nt[ct])&&e.call(ot,ot.__data__,ct,nt)&&it.push(ot);return new Selection$1(tt,this._parents)}function sparse(e){return new Array(e.length)}function selection_enter(){return new Selection$1(this._enter||this._groups.map(sparse),this._parents)}function EnterNode(e,t){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=t}EnterNode.prototype={constructor:EnterNode,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,t){return this._parent.insertBefore(e,t)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}};function constant$4(e){return function(){return e}}function bindIndex(e,t,Ye,tt,rt,nt){for(var at=0,it,ot=t.length,ct=nt.length;at<ct;++at)(it=t[at])?(it.__data__=nt[at],tt[at]=it):Ye[at]=new EnterNode(e,nt[at]);for(;at<ot;++at)(it=t[at])&&(rt[at]=it)}function bindKey(e,t,Ye,tt,rt,nt,at){var it,ot,ct=new Map,At=t.length,Rt=nt.length,qt=new Array(At),Ft;for(it=0;it<At;++it)(ot=t[it])&&(qt[it]=Ft=at.call(ot,ot.__data__,it,t)+"",ct.has(Ft)?rt[it]=ot:ct.set(Ft,ot));for(it=0;it<Rt;++it)Ft=at.call(e,nt[it],it,nt)+"",(ot=ct.get(Ft))?(tt[it]=ot,ot.__data__=nt[it],ct.delete(Ft)):Ye[it]=new EnterNode(e,nt[it]);for(it=0;it<At;++it)(ot=t[it])&&ct.get(qt[it])===ot&&(rt[it]=ot)}function datum(e){return e.__data__}function selection_data(e,t){if(!arguments.length)return Array.from(this,datum);var Ye=t?bindKey:bindIndex,tt=this._parents,rt=this._groups;typeof e!="function"&&(e=constant$4(e));for(var nt=rt.length,at=new Array(nt),it=new Array(nt),ot=new Array(nt),ct=0;ct<nt;++ct){var At=tt[ct],Rt=rt[ct],qt=Rt.length,Ft=arraylike(e.call(At,At&&At.__data__,ct,tt)),Ut=Ft.length,Ht=it[ct]=new Array(Ut),zt=at[ct]=new Array(Ut),Yt=ot[ct]=new Array(qt);Ye(At,Rt,Ht,zt,Yt,Ft,t);for(var Gt=0,Vt=0,Zt,Xt;Gt<Ut;++Gt)if(Zt=Ht[Gt]){for(Gt>=Vt&&(Vt=Gt+1);!(Xt=zt[Vt])&&++Vt<Ut;);Zt._next=Xt||null}}return at=new Selection$1(at,tt),at._enter=it,at._exit=ot,at}function arraylike(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function selection_exit(){return new Selection$1(this._exit||this._groups.map(sparse),this._parents)}function selection_join(e,t,Ye){var tt=this.enter(),rt=this,nt=this.exit();return typeof e=="function"?(tt=e(tt),tt&&(tt=tt.selection())):tt=tt.append(e+""),t!=null&&(rt=t(rt),rt&&(rt=rt.selection())),Ye==null?nt.remove():Ye(nt),tt&&rt?tt.merge(rt).order():rt}function selection_merge(e){for(var t=e.selection?e.selection():e,Ye=this._groups,tt=t._groups,rt=Ye.length,nt=tt.length,at=Math.min(rt,nt),it=new Array(rt),ot=0;ot<at;++ot)for(var ct=Ye[ot],At=tt[ot],Rt=ct.length,qt=it[ot]=new Array(Rt),Ft,Ut=0;Ut<Rt;++Ut)(Ft=ct[Ut]||At[Ut])&&(qt[Ut]=Ft);for(;ot<rt;++ot)it[ot]=Ye[ot];return new Selection$1(it,this._parents)}function selection_order(){for(var e=this._groups,t=-1,Ye=e.length;++t<Ye;)for(var tt=e[t],rt=tt.length-1,nt=tt[rt],at;--rt>=0;)(at=tt[rt])&&(nt&&at.compareDocumentPosition(nt)^4&&nt.parentNode.insertBefore(at,nt),nt=at);return this}function selection_sort(e){e||(e=ascending);function t(Rt,qt){return Rt&&qt?e(Rt.__data__,qt.__data__):!Rt-!qt}for(var Ye=this._groups,tt=Ye.length,rt=new Array(tt),nt=0;nt<tt;++nt){for(var at=Ye[nt],it=at.length,ot=rt[nt]=new Array(it),ct,At=0;At<it;++At)(ct=at[At])&&(ot[At]=ct);ot.sort(t)}return new Selection$1(rt,this._parents).order()}function ascending(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}function selection_call(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this}function selection_nodes(){return Array.from(this)}function selection_node(){for(var e=this._groups,t=0,Ye=e.length;t<Ye;++t)for(var tt=e[t],rt=0,nt=tt.length;rt<nt;++rt){var at=tt[rt];if(at)return at}return null}function selection_size(){let e=0;for(const t of this)++e;return e}function selection_empty(){return!this.node()}function selection_each(e){for(var t=this._groups,Ye=0,tt=t.length;Ye<tt;++Ye)for(var rt=t[Ye],nt=0,at=rt.length,it;nt<at;++nt)(it=rt[nt])&&e.call(it,it.__data__,nt,rt);return this}function attrRemove$1(e){return function(){this.removeAttribute(e)}}function attrRemoveNS$1(e){return function(){this.removeAttributeNS(e.space,e.local)}}function attrConstant$1(e,t){return function(){this.setAttribute(e,t)}}function attrConstantNS$1(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function attrFunction$1(e,t){return function(){var Ye=t.apply(this,arguments);Ye==null?this.removeAttribute(e):this.setAttribute(e,Ye)}}function attrFunctionNS$1(e,t){return function(){var Ye=t.apply(this,arguments);Ye==null?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,Ye)}}function selection_attr(e,t){var Ye=namespace(e);if(arguments.length<2){var tt=this.node();return Ye.local?tt.getAttributeNS(Ye.space,Ye.local):tt.getAttribute(Ye)}return this.each((t==null?Ye.local?attrRemoveNS$1:attrRemove$1:typeof t=="function"?Ye.local?attrFunctionNS$1:attrFunction$1:Ye.local?attrConstantNS$1:attrConstant$1)(Ye,t))}function defaultView(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function styleRemove$1(e){return function(){this.style.removeProperty(e)}}function styleConstant$1(e,t,Ye){return function(){this.style.setProperty(e,t,Ye)}}function styleFunction$1(e,t,Ye){return function(){var tt=t.apply(this,arguments);tt==null?this.style.removeProperty(e):this.style.setProperty(e,tt,Ye)}}function selection_style(e,t,Ye){return arguments.length>1?this.each((t==null?styleRemove$1:typeof t=="function"?styleFunction$1:styleConstant$1)(e,t,Ye??"")):styleValue(this.node(),e)}function styleValue(e,t){return e.style.getPropertyValue(t)||defaultView(e).getComputedStyle(e,null).getPropertyValue(t)}function propertyRemove(e){return function(){delete this[e]}}function propertyConstant(e,t){return function(){this[e]=t}}function propertyFunction(e,t){return function(){var Ye=t.apply(this,arguments);Ye==null?delete this[e]:this[e]=Ye}}function selection_property(e,t){return arguments.length>1?this.each((t==null?propertyRemove:typeof t=="function"?propertyFunction:propertyConstant)(e,t)):this.node()[e]}function classArray(e){return e.trim().split(/^|\s+/)}function classList$1(e){return e.classList||new ClassList(e)}function ClassList(e){this._node=e,this._names=classArray(e.getAttribute("class")||"")}ClassList.prototype={add:function(e){var t=this._names.indexOf(e);t<0&&(this._names.push(e),this._node.setAttribute("class",this._names.join(" ")))},remove:function(e){var t=this._names.indexOf(e);t>=0&&(this._names.splice(t,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(e){return this._names.indexOf(e)>=0}};function classedAdd(e,t){for(var Ye=classList$1(e),tt=-1,rt=t.length;++tt<rt;)Ye.add(t[tt])}function classedRemove(e,t){for(var Ye=classList$1(e),tt=-1,rt=t.length;++tt<rt;)Ye.remove(t[tt])}function classedTrue(e){return function(){classedAdd(this,e)}}function classedFalse(e){return function(){classedRemove(this,e)}}function classedFunction(e,t){return function(){(t.apply(this,arguments)?classedAdd:classedRemove)(this,e)}}function selection_classed(e,t){var Ye=classArray(e+"");if(arguments.length<2){for(var tt=classList$1(this.node()),rt=-1,nt=Ye.length;++rt<nt;)if(!tt.contains(Ye[rt]))return!1;return!0}return this.each((typeof t=="function"?classedFunction:t?classedTrue:classedFalse)(Ye,t))}function textRemove(){this.textContent=""}function textConstant$1(e){return function(){this.textContent=e}}function textFunction$1(e){return function(){var t=e.apply(this,arguments);this.textContent=t??""}}function selection_text(e){return arguments.length?this.each(e==null?textRemove:(typeof e=="function"?textFunction$1:textConstant$1)(e)):this.node().textContent}function htmlRemove(){this.innerHTML=""}function htmlConstant(e){return function(){this.innerHTML=e}}function htmlFunction(e){return function(){var t=e.apply(this,arguments);this.innerHTML=t??""}}function selection_html(e){return arguments.length?this.each(e==null?htmlRemove:(typeof e=="function"?htmlFunction:htmlConstant)(e)):this.node().innerHTML}function raise(){this.nextSibling&&this.parentNode.appendChild(this)}function selection_raise(){return this.each(raise)}function lower(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function selection_lower(){return this.each(lower)}function selection_append(e){var t=typeof e=="function"?e:creator(e);return this.select(function(){return this.appendChild(t.apply(this,arguments))})}function constantNull(){return null}function selection_insert(e,t){var Ye=typeof e=="function"?e:creator(e),tt=t==null?constantNull:typeof t=="function"?t:selector(t);return this.select(function(){return this.insertBefore(Ye.apply(this,arguments),tt.apply(this,arguments)||null)})}function remove(){var e=this.parentNode;e&&e.removeChild(this)}function selection_remove(){return this.each(remove)}function selection_cloneShallow(){var e=this.cloneNode(!1),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function selection_cloneDeep(){var e=this.cloneNode(!0),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function selection_clone(e){return this.select(e?selection_cloneDeep:selection_cloneShallow)}function selection_datum(e){return arguments.length?this.property("__data__",e):this.node().__data__}function contextListener(e){return function(t){e.call(this,t,this.__data__)}}function parseTypenames(e){return e.trim().split(/^|\s+/).map(function(t){var Ye="",tt=t.indexOf(".");return tt>=0&&(Ye=t.slice(tt+1),t=t.slice(0,tt)),{type:t,name:Ye}})}function onRemove(e){return function(){var t=this.__on;if(t){for(var Ye=0,tt=-1,rt=t.length,nt;Ye<rt;++Ye)nt=t[Ye],(!e.type||nt.type===e.type)&&nt.name===e.name?this.removeEventListener(nt.type,nt.listener,nt.options):t[++tt]=nt;++tt?t.length=tt:delete this.__on}}}function onAdd(e,t,Ye){return function(){var tt=this.__on,rt,nt=contextListener(t);if(tt){for(var at=0,it=tt.length;at<it;++at)if((rt=tt[at]).type===e.type&&rt.name===e.name){this.removeEventListener(rt.type,rt.listener,rt.options),this.addEventListener(rt.type,rt.listener=nt,rt.options=Ye),rt.value=t;return}}this.addEventListener(e.type,nt,Ye),rt={type:e.type,name:e.name,value:t,listener:nt,options:Ye},tt?tt.push(rt):this.__on=[rt]}}function selection_on(e,t,Ye){var tt=parseTypenames(e+""),rt,nt=tt.length,at;if(arguments.length<2){var it=this.node().__on;if(it){for(var ot=0,ct=it.length,At;ot<ct;++ot)for(rt=0,At=it[ot];rt<nt;++rt)if((at=tt[rt]).type===At.type&&at.name===At.name)return At.value}return}for(it=t?onAdd:onRemove,rt=0;rt<nt;++rt)this.each(it(tt[rt],t,Ye));return this}function dispatchEvent(e,t,Ye){var tt=defaultView(e),rt=tt.CustomEvent;typeof rt=="function"?rt=new rt(t,Ye):(rt=tt.document.createEvent("Event"),Ye?(rt.initEvent(t,Ye.bubbles,Ye.cancelable),rt.detail=Ye.detail):rt.initEvent(t,!1,!1)),e.dispatchEvent(rt)}function dispatchConstant(e,t){return function(){return dispatchEvent(this,e,t)}}function dispatchFunction(e,t){return function(){return dispatchEvent(this,e,t.apply(this,arguments))}}function selection_dispatch(e,t){return this.each((typeof t=="function"?dispatchFunction:dispatchConstant)(e,t))}function*selection_iterator(){for(var e=this._groups,t=0,Ye=e.length;t<Ye;++t)for(var tt=e[t],rt=0,nt=tt.length,at;rt<nt;++rt)(at=tt[rt])&&(yield at)}var root$1=[null];function Selection$1(e,t){this._groups=e,this._parents=t}function selection(){return new Selection$1([[document.documentElement]],root$1)}function selection_selection(){return this}Selection$1.prototype=selection.prototype={constructor:Selection$1,select:selection_select,selectAll:selection_selectAll,selectChild:selection_selectChild,selectChildren:selection_selectChildren,filter:selection_filter,data:selection_data,enter:selection_enter,exit:selection_exit,join:selection_join,merge:selection_merge,selection:selection_selection,order:selection_order,sort:selection_sort,call:selection_call,nodes:selection_nodes,node:selection_node,size:selection_size,empty:selection_empty,each:selection_each,attr:selection_attr,style:selection_style,property:selection_property,classed:selection_classed,text:selection_text,html:selection_html,raise:selection_raise,lower:selection_lower,append:selection_append,insert:selection_insert,remove:selection_remove,clone:selection_clone,datum:selection_datum,on:selection_on,dispatch:selection_dispatch,[Symbol.iterator]:selection_iterator};function select(e){return typeof e=="string"?new Selection$1([[document.querySelector(e)]],[document.documentElement]):new Selection$1([[e]],root$1)}function sourceEvent(e){let t;for(;t=e.sourceEvent;)e=t;return e}function pointer(e,t){if(e=sourceEvent(e),t===void 0&&(t=e.currentTarget),t){var Ye=t.ownerSVGElement||t;if(Ye.createSVGPoint){var tt=Ye.createSVGPoint();return tt.x=e.clientX,tt.y=e.clientY,tt=tt.matrixTransform(t.getScreenCTM().inverse()),[tt.x,tt.y]}if(t.getBoundingClientRect){var rt=t.getBoundingClientRect();return[e.clientX-rt.left-t.clientLeft,e.clientY-rt.top-t.clientTop]}}return[e.pageX,e.pageY]}const nonpassive={passive:!1},nonpassivecapture={capture:!0,passive:!1};function nopropagation$1(e){e.stopImmediatePropagation()}function noevent$1(e){e.preventDefault(),e.stopImmediatePropagation()}function dragDisable(e){var t=e.document.documentElement,Ye=select(e).on("dragstart.drag",noevent$1,nonpassivecapture);"onselectstart"in t?Ye.on("selectstart.drag",noevent$1,nonpassivecapture):(t.__noselect=t.style.MozUserSelect,t.style.MozUserSelect="none")}function yesdrag(e,t){var Ye=e.document.documentElement,tt=select(e).on("dragstart.drag",null);t&&(tt.on("click.drag",noevent$1,nonpassivecapture),setTimeout(function(){tt.on("click.drag",null)},0)),"onselectstart"in Ye?tt.on("selectstart.drag",null):(Ye.style.MozUserSelect=Ye.__noselect,delete Ye.__noselect)}const constant$3=e=>()=>e;function DragEvent(e,{sourceEvent:t,subject:Ye,target:tt,identifier:rt,active:nt,x:at,y:it,dx:ot,dy:ct,dispatch:At}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},subject:{value:Ye,enumerable:!0,configurable:!0},target:{value:tt,enumerable:!0,configurable:!0},identifier:{value:rt,enumerable:!0,configurable:!0},active:{value:nt,enumerable:!0,configurable:!0},x:{value:at,enumerable:!0,configurable:!0},y:{value:it,enumerable:!0,configurable:!0},dx:{value:ot,enumerable:!0,configurable:!0},dy:{value:ct,enumerable:!0,configurable:!0},_:{value:At}})}DragEvent.prototype.on=function(){var e=this._.on.apply(this._,arguments);return e===this._?this:e};function defaultFilter$1(e){return!e.ctrlKey&&!e.button}function defaultContainer(){return this.parentNode}function defaultSubject(e,t){return t??{x:e.x,y:e.y}}function defaultTouchable$1(){return navigator.maxTouchPoints||"ontouchstart"in this}function drag(){var e=defaultFilter$1,t=defaultContainer,Ye=defaultSubject,tt=defaultTouchable$1,rt={},nt=dispatch("start","drag","end"),at=0,it,ot,ct,At,Rt=0;function qt(Zt){Zt.on("mousedown.drag",Ft).filter(tt).on("touchstart.drag",zt).on("touchmove.drag",Yt,nonpassive).on("touchend.drag touchcancel.drag",Gt).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function Ft(Zt,Xt){if(!(At||!e.call(this,Zt,Xt))){var Qt=Vt(this,t.call(this,Zt,Xt),Zt,Xt,"mouse");Qt&&(select(Zt.view).on("mousemove.drag",Ut,nonpassivecapture).on("mouseup.drag",Ht,nonpassivecapture),dragDisable(Zt.view),nopropagation$1(Zt),ct=!1,it=Zt.clientX,ot=Zt.clientY,Qt("start",Zt))}}function Ut(Zt){if(noevent$1(Zt),!ct){var Xt=Zt.clientX-it,Qt=Zt.clientY-ot;ct=Xt*Xt+Qt*Qt>Rt}rt.mouse("drag",Zt)}function Ht(Zt){select(Zt.view).on("mousemove.drag mouseup.drag",null),yesdrag(Zt.view,ct),noevent$1(Zt),rt.mouse("end",Zt)}function zt(Zt,Xt){if(e.call(this,Zt,Xt)){var Qt=Zt.changedTouches,er=t.call(this,Zt,Xt),nr=Qt.length,ar,sr;for(ar=0;ar<nr;++ar)(sr=Vt(this,er,Zt,Xt,Qt[ar].identifier,Qt[ar]))&&(nopropagation$1(Zt),sr("start",Zt,Qt[ar]))}}function Yt(Zt){var Xt=Zt.changedTouches,Qt=Xt.length,er,nr;for(er=0;er<Qt;++er)(nr=rt[Xt[er].identifier])&&(noevent$1(Zt),nr("drag",Zt,Xt[er]))}function Gt(Zt){var Xt=Zt.changedTouches,Qt=Xt.length,er,nr;for(At&&clearTimeout(At),At=setTimeout(function(){At=null},500),er=0;er<Qt;++er)(nr=rt[Xt[er].identifier])&&(nopropagation$1(Zt),nr("end",Zt,Xt[er]))}function Vt(Zt,Xt,Qt,er,nr,ar){var sr=nt.copy(),lr=pointer(ar||Qt,Xt),fr,gr,dr;if((dr=Ye.call(Zt,new DragEvent("beforestart",{sourceEvent:Qt,target:qt,identifier:nr,active:at,x:lr[0],y:lr[1],dx:0,dy:0,dispatch:sr}),er))!=null)return fr=dr.x-lr[0]||0,gr=dr.y-lr[1]||0,function vr(mr,Er,_r){var Tr=lr,ur;switch(mr){case"start":rt[nr]=vr,ur=at++;break;case"end":delete rt[nr],--at;case"drag":lr=pointer(_r||Er,Xt),ur=at;break}sr.call(mr,Zt,new DragEvent(mr,{sourceEvent:Er,subject:dr,target:qt,identifier:nr,active:ur,x:lr[0]+fr,y:lr[1]+gr,dx:lr[0]-Tr[0],dy:lr[1]-Tr[1],dispatch:sr}),er)}}return qt.filter=function(Zt){return arguments.length?(e=typeof Zt=="function"?Zt:constant$3(!!Zt),qt):e},qt.container=function(Zt){return arguments.length?(t=typeof Zt=="function"?Zt:constant$3(Zt),qt):t},qt.subject=function(Zt){return arguments.length?(Ye=typeof Zt=="function"?Zt:constant$3(Zt),qt):Ye},qt.touchable=function(Zt){return arguments.length?(tt=typeof Zt=="function"?Zt:constant$3(!!Zt),qt):tt},qt.on=function(){var Zt=nt.on.apply(nt,arguments);return Zt===nt?qt:Zt},qt.clickDistance=function(Zt){return arguments.length?(Rt=(Zt=+Zt)*Zt,qt):Math.sqrt(Rt)},qt}function define(e,t,Ye){e.prototype=t.prototype=Ye,Ye.constructor=e}function extend(e,t){var Ye=Object.create(e.prototype);for(var tt in t)Ye[tt]=t[tt];return Ye}function Color(){}var darker=.7,brighter=1/darker,reI="\\s*([+-]?\\d+)\\s*",reN="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",reP="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",reHex=/^#([0-9a-f]{3,8})$/,reRgbInteger=new RegExp(`^rgb\\(${reI},${reI},${reI}\\)$`),reRgbPercent=new RegExp(`^rgb\\(${reP},${reP},${reP}\\)$`),reRgbaInteger=new RegExp(`^rgba\\(${reI},${reI},${reI},${reN}\\)$`),reRgbaPercent=new RegExp(`^rgba\\(${reP},${reP},${reP},${reN}\\)$`),reHslPercent=new RegExp(`^hsl\\(${reN},${reP},${reP}\\)$`),reHslaPercent=new RegExp(`^hsla\\(${reN},${reP},${reP},${reN}\\)$`),named={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};define(Color,color,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:color_formatHex,formatHex:color_formatHex,formatHex8:color_formatHex8,formatHsl:color_formatHsl,formatRgb:color_formatRgb,toString:color_formatRgb});function color_formatHex(){return this.rgb().formatHex()}function color_formatHex8(){return this.rgb().formatHex8()}function color_formatHsl(){return hslConvert(this).formatHsl()}function color_formatRgb(){return this.rgb().formatRgb()}function color(e){var t,Ye;return e=(e+"").trim().toLowerCase(),(t=reHex.exec(e))?(Ye=t[1].length,t=parseInt(t[1],16),Ye===6?rgbn(t):Ye===3?new Rgb(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):Ye===8?rgba(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):Ye===4?rgba(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=reRgbInteger.exec(e))?new Rgb(t[1],t[2],t[3],1):(t=reRgbPercent.exec(e))?new Rgb(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=reRgbaInteger.exec(e))?rgba(t[1],t[2],t[3],t[4]):(t=reRgbaPercent.exec(e))?rgba(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=reHslPercent.exec(e))?hsla(t[1],t[2]/100,t[3]/100,1):(t=reHslaPercent.exec(e))?hsla(t[1],t[2]/100,t[3]/100,t[4]):named.hasOwnProperty(e)?rgbn(named[e]):e==="transparent"?new Rgb(NaN,NaN,NaN,0):null}function rgbn(e){return new Rgb(e>>16&255,e>>8&255,e&255,1)}function rgba(e,t,Ye,tt){return tt<=0&&(e=t=Ye=NaN),new Rgb(e,t,Ye,tt)}function rgbConvert(e){return e instanceof Color||(e=color(e)),e?(e=e.rgb(),new Rgb(e.r,e.g,e.b,e.opacity)):new Rgb}function rgb(e,t,Ye,tt){return arguments.length===1?rgbConvert(e):new Rgb(e,t,Ye,tt??1)}function Rgb(e,t,Ye,tt){this.r=+e,this.g=+t,this.b=+Ye,this.opacity=+tt}define(Rgb,rgb,extend(Color,{brighter(e){return e=e==null?brighter:Math.pow(brighter,e),new Rgb(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?darker:Math.pow(darker,e),new Rgb(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new Rgb(clampi(this.r),clampi(this.g),clampi(this.b),clampa(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:rgb_formatHex,formatHex:rgb_formatHex,formatHex8:rgb_formatHex8,formatRgb:rgb_formatRgb,toString:rgb_formatRgb}));function rgb_formatHex(){return`#${hex(this.r)}${hex(this.g)}${hex(this.b)}`}function rgb_formatHex8(){return`#${hex(this.r)}${hex(this.g)}${hex(this.b)}${hex((isNaN(this.opacity)?1:this.opacity)*255)}`}function rgb_formatRgb(){const e=clampa(this.opacity);return`${e===1?"rgb(":"rgba("}${clampi(this.r)}, ${clampi(this.g)}, ${clampi(this.b)}${e===1?")":`, ${e})`}`}function clampa(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function clampi(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function hex(e){return e=clampi(e),(e<16?"0":"")+e.toString(16)}function hsla(e,t,Ye,tt){return tt<=0?e=t=Ye=NaN:Ye<=0||Ye>=1?e=t=NaN:t<=0&&(e=NaN),new Hsl(e,t,Ye,tt)}function hslConvert(e){if(e instanceof Hsl)return new Hsl(e.h,e.s,e.l,e.opacity);if(e instanceof Color||(e=color(e)),!e)return new Hsl;if(e instanceof Hsl)return e;e=e.rgb();var t=e.r/255,Ye=e.g/255,tt=e.b/255,rt=Math.min(t,Ye,tt),nt=Math.max(t,Ye,tt),at=NaN,it=nt-rt,ot=(nt+rt)/2;return it?(t===nt?at=(Ye-tt)/it+(Ye<tt)*6:Ye===nt?at=(tt-t)/it+2:at=(t-Ye)/it+4,it/=ot<.5?nt+rt:2-nt-rt,at*=60):it=ot>0&&ot<1?0:at,new Hsl(at,it,ot,e.opacity)}function hsl(e,t,Ye,tt){return arguments.length===1?hslConvert(e):new Hsl(e,t,Ye,tt??1)}function Hsl(e,t,Ye,tt){this.h=+e,this.s=+t,this.l=+Ye,this.opacity=+tt}define(Hsl,hsl,extend(Color,{brighter(e){return e=e==null?brighter:Math.pow(brighter,e),new Hsl(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?darker:Math.pow(darker,e),new Hsl(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,Ye=this.l,tt=Ye+(Ye<.5?Ye:1-Ye)*t,rt=2*Ye-tt;return new Rgb(hsl2rgb(e>=240?e-240:e+120,rt,tt),hsl2rgb(e,rt,tt),hsl2rgb(e<120?e+240:e-120,rt,tt),this.opacity)},clamp(){return new Hsl(clamph(this.h),clampt(this.s),clampt(this.l),clampa(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=clampa(this.opacity);return`${e===1?"hsl(":"hsla("}${clamph(this.h)}, ${clampt(this.s)*100}%, ${clampt(this.l)*100}%${e===1?")":`, ${e})`}`}}));function clamph(e){return e=(e||0)%360,e<0?e+360:e}function clampt(e){return Math.max(0,Math.min(1,e||0))}function hsl2rgb(e,t,Ye){return(e<60?t+(Ye-t)*e/60:e<180?Ye:e<240?t+(Ye-t)*(240-e)/60:t)*255}const constant$2=e=>()=>e;function linear(e,t){return function(Ye){return e+Ye*t}}function exponential(e,t,Ye){return e=Math.pow(e,Ye),t=Math.pow(t,Ye)-e,Ye=1/Ye,function(tt){return Math.pow(e+tt*t,Ye)}}function hue(e,t){var Ye=t-e;return Ye?linear(e,Ye>180||Ye<-180?Ye-360*Math.round(Ye/360):Ye):constant$2(isNaN(e)?t:e)}function gamma(e){return(e=+e)==1?nogamma:function(t,Ye){return Ye-t?exponential(t,Ye,e):constant$2(isNaN(t)?Ye:t)}}function nogamma(e,t){var Ye=t-e;return Ye?linear(e,Ye):constant$2(isNaN(e)?t:e)}const interpolateRgb=function e(t){var Ye=gamma(t);function tt(rt,nt){var at=Ye((rt=rgb(rt)).r,(nt=rgb(nt)).r),it=Ye(rt.g,nt.g),ot=Ye(rt.b,nt.b),ct=nogamma(rt.opacity,nt.opacity);return function(At){return rt.r=at(At),rt.g=it(At),rt.b=ot(At),rt.opacity=ct(At),rt+""}}return tt.gamma=e,tt}(1);function interpolateNumber(e,t){return e=+e,t=+t,function(Ye){return e*(1-Ye)+t*Ye}}var reA=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,reB=new RegExp(reA.source,"g");function zero(e){return function(){return e}}function one(e){return function(t){return e(t)+""}}function interpolateString(e,t){var Ye=reA.lastIndex=reB.lastIndex=0,tt,rt,nt,at=-1,it=[],ot=[];for(e=e+"",t=t+"";(tt=reA.exec(e))&&(rt=reB.exec(t));)(nt=rt.index)>Ye&&(nt=t.slice(Ye,nt),it[at]?it[at]+=nt:it[++at]=nt),(tt=tt[0])===(rt=rt[0])?it[at]?it[at]+=rt:it[++at]=rt:(it[++at]=null,ot.push({i:at,x:interpolateNumber(tt,rt)})),Ye=reB.lastIndex;return Ye<t.length&&(nt=t.slice(Ye),it[at]?it[at]+=nt:it[++at]=nt),it.length<2?ot[0]?one(ot[0].x):zero(t):(t=ot.length,function(ct){for(var At=0,Rt;At<t;++At)it[(Rt=ot[At]).i]=Rt.x(ct);return it.join("")})}var degrees=180/Math.PI,identity$3={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function decompose(e,t,Ye,tt,rt,nt){var at,it,ot;return(at=Math.sqrt(e*e+t*t))&&(e/=at,t/=at),(ot=e*Ye+t*tt)&&(Ye-=e*ot,tt-=t*ot),(it=Math.sqrt(Ye*Ye+tt*tt))&&(Ye/=it,tt/=it,ot/=it),e*tt<t*Ye&&(e=-e,t=-t,ot=-ot,at=-at),{translateX:rt,translateY:nt,rotate:Math.atan2(t,e)*degrees,skewX:Math.atan(ot)*degrees,scaleX:at,scaleY:it}}var svgNode;function parseCss(e){const t=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(e+"");return t.isIdentity?identity$3:decompose(t.a,t.b,t.c,t.d,t.e,t.f)}function parseSvg(e){return e==null||(svgNode||(svgNode=document.createElementNS("http://www.w3.org/2000/svg","g")),svgNode.setAttribute("transform",e),!(e=svgNode.transform.baseVal.consolidate()))?identity$3:(e=e.matrix,decompose(e.a,e.b,e.c,e.d,e.e,e.f))}function interpolateTransform(e,t,Ye,tt){function rt(ct){return ct.length?ct.pop()+" ":""}function nt(ct,At,Rt,qt,Ft,Ut){if(ct!==Rt||At!==qt){var Ht=Ft.push("translate(",null,t,null,Ye);Ut.push({i:Ht-4,x:interpolateNumber(ct,Rt)},{i:Ht-2,x:interpolateNumber(At,qt)})}else(Rt||qt)&&Ft.push("translate("+Rt+t+qt+Ye)}function at(ct,At,Rt,qt){ct!==At?(ct-At>180?At+=360:At-ct>180&&(ct+=360),qt.push({i:Rt.push(rt(Rt)+"rotate(",null,tt)-2,x:interpolateNumber(ct,At)})):At&&Rt.push(rt(Rt)+"rotate("+At+tt)}function it(ct,At,Rt,qt){ct!==At?qt.push({i:Rt.push(rt(Rt)+"skewX(",null,tt)-2,x:interpolateNumber(ct,At)}):At&&Rt.push(rt(Rt)+"skewX("+At+tt)}function ot(ct,At,Rt,qt,Ft,Ut){if(ct!==Rt||At!==qt){var Ht=Ft.push(rt(Ft)+"scale(",null,",",null,")");Ut.push({i:Ht-4,x:interpolateNumber(ct,Rt)},{i:Ht-2,x:interpolateNumber(At,qt)})}else(Rt!==1||qt!==1)&&Ft.push(rt(Ft)+"scale("+Rt+","+qt+")")}return function(ct,At){var Rt=[],qt=[];return ct=e(ct),At=e(At),nt(ct.translateX,ct.translateY,At.translateX,At.translateY,Rt,qt),at(ct.rotate,At.rotate,Rt,qt),it(ct.skewX,At.skewX,Rt,qt),ot(ct.scaleX,ct.scaleY,At.scaleX,At.scaleY,Rt,qt),ct=At=null,function(Ft){for(var Ut=-1,Ht=qt.length,zt;++Ut<Ht;)Rt[(zt=qt[Ut]).i]=zt.x(Ft);return Rt.join("")}}}var interpolateTransformCss=interpolateTransform(parseCss,"px, ","px)","deg)"),interpolateTransformSvg=interpolateTransform(parseSvg,", ",")",")"),epsilon2=1e-12;function cosh(e){return((e=Math.exp(e))+1/e)/2}function sinh(e){return((e=Math.exp(e))-1/e)/2}function tanh(e){return((e=Math.exp(2*e))-1)/(e+1)}const interpolateZoom=function e(t,Ye,tt){function rt(nt,at){var it=nt[0],ot=nt[1],ct=nt[2],At=at[0],Rt=at[1],qt=at[2],Ft=At-it,Ut=Rt-ot,Ht=Ft*Ft+Ut*Ut,zt,Yt;if(Ht<epsilon2)Yt=Math.log(qt/ct)/t,zt=function(er){return[it+er*Ft,ot+er*Ut,ct*Math.exp(t*er*Yt)]};else{var Gt=Math.sqrt(Ht),Vt=(qt*qt-ct*ct+tt*Ht)/(2*ct*Ye*Gt),Zt=(qt*qt-ct*ct-tt*Ht)/(2*qt*Ye*Gt),Xt=Math.log(Math.sqrt(Vt*Vt+1)-Vt),Qt=Math.log(Math.sqrt(Zt*Zt+1)-Zt);Yt=(Qt-Xt)/t,zt=function(er){var nr=er*Yt,ar=cosh(Xt),sr=ct/(Ye*Gt)*(ar*tanh(t*nr+Xt)-sinh(Xt));return[it+sr*Ft,ot+sr*Ut,ct*ar/cosh(t*nr+Xt)]}}return zt.duration=Yt*1e3*t/Math.SQRT2,zt}return rt.rho=function(nt){var at=Math.max(.001,+nt),it=at*at,ot=it*it;return e(at,it,ot)},rt}(Math.SQRT2,2,4);var frame=0,timeout$1=0,interval=0,pokeDelay=1e3,taskHead,taskTail,clockLast=0,clockNow=0,clockSkew=0,clock=typeof performance=="object"&&performance.now?performance:Date,setFrame=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function now(){return clockNow||(setFrame(clearNow),clockNow=clock.now()+clockSkew)}function clearNow(){clockNow=0}function Timer(){this._call=this._time=this._next=null}Timer.prototype=timer.prototype={constructor:Timer,restart:function(e,t,Ye){if(typeof e!="function")throw new TypeError("callback is not a function");Ye=(Ye==null?now():+Ye)+(t==null?0:+t),!this._next&&taskTail!==this&&(taskTail?taskTail._next=this:taskHead=this,taskTail=this),this._call=e,this._time=Ye,sleep()},stop:function(){this._call&&(this._call=null,this._time=1/0,sleep())}};function timer(e,t,Ye){var tt=new Timer;return tt.restart(e,t,Ye),tt}function timerFlush(){now(),++frame;for(var e=taskHead,t;e;)(t=clockNow-e._time)>=0&&e._call.call(void 0,t),e=e._next;--frame}function wake(){clockNow=(clockLast=clock.now())+clockSkew,frame=timeout$1=0;try{timerFlush()}finally{frame=0,nap(),clockNow=0}}function poke(){var e=clock.now(),t=e-clockLast;t>pokeDelay&&(clockSkew-=t,clockLast=e)}function nap(){for(var e,t=taskHead,Ye,tt=1/0;t;)t._call?(tt>t._time&&(tt=t._time),e=t,t=t._next):(Ye=t._next,t._next=null,t=e?e._next=Ye:taskHead=Ye);taskTail=e,sleep(tt)}function sleep(e){if(!frame){timeout$1&&(timeout$1=clearTimeout(timeout$1));var t=e-clockNow;t>24?(e<1/0&&(timeout$1=setTimeout(wake,e-clock.now()-clockSkew)),interval&&(interval=clearInterval(interval))):(interval||(clockLast=clock.now(),interval=setInterval(poke,pokeDelay)),frame=1,setFrame(wake))}}function timeout(e,t,Ye){var tt=new Timer;return t=t==null?0:+t,tt.restart(rt=>{tt.stop(),e(rt+t)},t,Ye),tt}var emptyOn=dispatch("start","end","cancel","interrupt"),emptyTween=[],CREATED=0,SCHEDULED=1,STARTING=2,STARTED=3,RUNNING=4,ENDING=5,ENDED=6;function schedule(e,t,Ye,tt,rt,nt){var at=e.__transition;if(!at)e.__transition={};else if(Ye in at)return;create(e,Ye,{name:t,index:tt,group:rt,on:emptyOn,tween:emptyTween,time:nt.time,delay:nt.delay,duration:nt.duration,ease:nt.ease,timer:null,state:CREATED})}function init(e,t){var Ye=get$1(e,t);if(Ye.state>CREATED)throw new Error("too late; already scheduled");return Ye}function set$1(e,t){var Ye=get$1(e,t);if(Ye.state>STARTED)throw new Error("too late; already running");return Ye}function get$1(e,t){var Ye=e.__transition;if(!Ye||!(Ye=Ye[t]))throw new Error("transition not found");return Ye}function create(e,t,Ye){var tt=e.__transition,rt;tt[t]=Ye,Ye.timer=timer(nt,0,Ye.time);function nt(ct){Ye.state=SCHEDULED,Ye.timer.restart(at,Ye.delay,Ye.time),Ye.delay<=ct&&at(ct-Ye.delay)}function at(ct){var At,Rt,qt,Ft;if(Ye.state!==SCHEDULED)return ot();for(At in tt)if(Ft=tt[At],Ft.name===Ye.name){if(Ft.state===STARTED)return timeout(at);Ft.state===RUNNING?(Ft.state=ENDED,Ft.timer.stop(),Ft.on.call("interrupt",e,e.__data__,Ft.index,Ft.group),delete tt[At]):+At<t&&(Ft.state=ENDED,Ft.timer.stop(),Ft.on.call("cancel",e,e.__data__,Ft.index,Ft.group),delete tt[At])}if(timeout(function(){Ye.state===STARTED&&(Ye.state=RUNNING,Ye.timer.restart(it,Ye.delay,Ye.time),it(ct))}),Ye.state=STARTING,Ye.on.call("start",e,e.__data__,Ye.index,Ye.group),Ye.state===STARTING){for(Ye.state=STARTED,rt=new Array(qt=Ye.tween.length),At=0,Rt=-1;At<qt;++At)(Ft=Ye.tween[At].value.call(e,e.__data__,Ye.index,Ye.group))&&(rt[++Rt]=Ft);rt.length=Rt+1}}function it(ct){for(var At=ct<Ye.duration?Ye.ease.call(null,ct/Ye.duration):(Ye.timer.restart(ot),Ye.state=ENDING,1),Rt=-1,qt=rt.length;++Rt<qt;)rt[Rt].call(e,At);Ye.state===ENDING&&(Ye.on.call("end",e,e.__data__,Ye.index,Ye.group),ot())}function ot(){Ye.state=ENDED,Ye.timer.stop(),delete tt[t];for(var ct in tt)return;delete e.__transition}}function interrupt(e,t){var Ye=e.__transition,tt,rt,nt=!0,at;if(Ye){t=t==null?null:t+"";for(at in Ye){if((tt=Ye[at]).name!==t){nt=!1;continue}rt=tt.state>STARTING&&tt.state<ENDING,tt.state=ENDED,tt.timer.stop(),tt.on.call(rt?"interrupt":"cancel",e,e.__data__,tt.index,tt.group),delete Ye[at]}nt&&delete e.__transition}}function selection_interrupt(e){return this.each(function(){interrupt(this,e)})}function tweenRemove(e,t){var Ye,tt;return function(){var rt=set$1(this,e),nt=rt.tween;if(nt!==Ye){tt=Ye=nt;for(var at=0,it=tt.length;at<it;++at)if(tt[at].name===t){tt=tt.slice(),tt.splice(at,1);break}}rt.tween=tt}}function tweenFunction(e,t,Ye){var tt,rt;if(typeof Ye!="function")throw new Error;return function(){var nt=set$1(this,e),at=nt.tween;if(at!==tt){rt=(tt=at).slice();for(var it={name:t,value:Ye},ot=0,ct=rt.length;ot<ct;++ot)if(rt[ot].name===t){rt[ot]=it;break}ot===ct&&rt.push(it)}nt.tween=rt}}function transition_tween(e,t){var Ye=this._id;if(e+="",arguments.length<2){for(var tt=get$1(this.node(),Ye).tween,rt=0,nt=tt.length,at;rt<nt;++rt)if((at=tt[rt]).name===e)return at.value;return null}return this.each((t==null?tweenRemove:tweenFunction)(Ye,e,t))}function tweenValue(e,t,Ye){var tt=e._id;return e.each(function(){var rt=set$1(this,tt);(rt.value||(rt.value={}))[t]=Ye.apply(this,arguments)}),function(rt){return get$1(rt,tt).value[t]}}function interpolate(e,t){var Ye;return(typeof t=="number"?interpolateNumber:t instanceof color?interpolateRgb:(Ye=color(t))?(t=Ye,interpolateRgb):interpolateString)(e,t)}function attrRemove(e){return function(){this.removeAttribute(e)}}function attrRemoveNS(e){return function(){this.removeAttributeNS(e.space,e.local)}}function attrConstant(e,t,Ye){var tt,rt=Ye+"",nt;return function(){var at=this.getAttribute(e);return at===rt?null:at===tt?nt:nt=t(tt=at,Ye)}}function attrConstantNS(e,t,Ye){var tt,rt=Ye+"",nt;return function(){var at=this.getAttributeNS(e.space,e.local);return at===rt?null:at===tt?nt:nt=t(tt=at,Ye)}}function attrFunction(e,t,Ye){var tt,rt,nt;return function(){var at,it=Ye(this),ot;return it==null?void this.removeAttribute(e):(at=this.getAttribute(e),ot=it+"",at===ot?null:at===tt&&ot===rt?nt:(rt=ot,nt=t(tt=at,it)))}}function attrFunctionNS(e,t,Ye){var tt,rt,nt;return function(){var at,it=Ye(this),ot;return it==null?void this.removeAttributeNS(e.space,e.local):(at=this.getAttributeNS(e.space,e.local),ot=it+"",at===ot?null:at===tt&&ot===rt?nt:(rt=ot,nt=t(tt=at,it)))}}function transition_attr(e,t){var Ye=namespace(e),tt=Ye==="transform"?interpolateTransformSvg:interpolate;return this.attrTween(e,typeof t=="function"?(Ye.local?attrFunctionNS:attrFunction)(Ye,tt,tweenValue(this,"attr."+e,t)):t==null?(Ye.local?attrRemoveNS:attrRemove)(Ye):(Ye.local?attrConstantNS:attrConstant)(Ye,tt,t))}function attrInterpolate(e,t){return function(Ye){this.setAttribute(e,t.call(this,Ye))}}function attrInterpolateNS(e,t){return function(Ye){this.setAttributeNS(e.space,e.local,t.call(this,Ye))}}function attrTweenNS(e,t){var Ye,tt;function rt(){var nt=t.apply(this,arguments);return nt!==tt&&(Ye=(tt=nt)&&attrInterpolateNS(e,nt)),Ye}return rt._value=t,rt}function attrTween(e,t){var Ye,tt;function rt(){var nt=t.apply(this,arguments);return nt!==tt&&(Ye=(tt=nt)&&attrInterpolate(e,nt)),Ye}return rt._value=t,rt}function transition_attrTween(e,t){var Ye="attr."+e;if(arguments.length<2)return(Ye=this.tween(Ye))&&Ye._value;if(t==null)return this.tween(Ye,null);if(typeof t!="function")throw new Error;var tt=namespace(e);return this.tween(Ye,(tt.local?attrTweenNS:attrTween)(tt,t))}function delayFunction(e,t){return function(){init(this,e).delay=+t.apply(this,arguments)}}function delayConstant(e,t){return t=+t,function(){init(this,e).delay=t}}function transition_delay(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?delayFunction:delayConstant)(t,e)):get$1(this.node(),t).delay}function durationFunction(e,t){return function(){set$1(this,e).duration=+t.apply(this,arguments)}}function durationConstant(e,t){return t=+t,function(){set$1(this,e).duration=t}}function transition_duration(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?durationFunction:durationConstant)(t,e)):get$1(this.node(),t).duration}function easeConstant(e,t){if(typeof t!="function")throw new Error;return function(){set$1(this,e).ease=t}}function transition_ease(e){var t=this._id;return arguments.length?this.each(easeConstant(t,e)):get$1(this.node(),t).ease}function easeVarying(e,t){return function(){var Ye=t.apply(this,arguments);if(typeof Ye!="function")throw new Error;set$1(this,e).ease=Ye}}function transition_easeVarying(e){if(typeof e!="function")throw new Error;return this.each(easeVarying(this._id,e))}function transition_filter(e){typeof e!="function"&&(e=matcher(e));for(var t=this._groups,Ye=t.length,tt=new Array(Ye),rt=0;rt<Ye;++rt)for(var nt=t[rt],at=nt.length,it=tt[rt]=[],ot,ct=0;ct<at;++ct)(ot=nt[ct])&&e.call(ot,ot.__data__,ct,nt)&&it.push(ot);return new Transition$1(tt,this._parents,this._name,this._id)}function transition_merge(e){if(e._id!==this._id)throw new Error;for(var t=this._groups,Ye=e._groups,tt=t.length,rt=Ye.length,nt=Math.min(tt,rt),at=new Array(tt),it=0;it<nt;++it)for(var ot=t[it],ct=Ye[it],At=ot.length,Rt=at[it]=new Array(At),qt,Ft=0;Ft<At;++Ft)(qt=ot[Ft]||ct[Ft])&&(Rt[Ft]=qt);for(;it<tt;++it)at[it]=t[it];return new Transition$1(at,this._parents,this._name,this._id)}function start(e){return(e+"").trim().split(/^|\s+/).every(function(t){var Ye=t.indexOf(".");return Ye>=0&&(t=t.slice(0,Ye)),!t||t==="start"})}function onFunction(e,t,Ye){var tt,rt,nt=start(t)?init:set$1;return function(){var at=nt(this,e),it=at.on;it!==tt&&(rt=(tt=it).copy()).on(t,Ye),at.on=rt}}function transition_on(e,t){var Ye=this._id;return arguments.length<2?get$1(this.node(),Ye).on.on(e):this.each(onFunction(Ye,e,t))}function removeFunction(e){return function(){var t=this.parentNode;for(var Ye in this.__transition)if(+Ye!==e)return;t&&t.removeChild(this)}}function transition_remove(){return this.on("end.remove",removeFunction(this._id))}function transition_select(e){var t=this._name,Ye=this._id;typeof e!="function"&&(e=selector(e));for(var tt=this._groups,rt=tt.length,nt=new Array(rt),at=0;at<rt;++at)for(var it=tt[at],ot=it.length,ct=nt[at]=new Array(ot),At,Rt,qt=0;qt<ot;++qt)(At=it[qt])&&(Rt=e.call(At,At.__data__,qt,it))&&("__data__"in At&&(Rt.__data__=At.__data__),ct[qt]=Rt,schedule(ct[qt],t,Ye,qt,ct,get$1(At,Ye)));return new Transition$1(nt,this._parents,t,Ye)}function transition_selectAll(e){var t=this._name,Ye=this._id;typeof e!="function"&&(e=selectorAll(e));for(var tt=this._groups,rt=tt.length,nt=[],at=[],it=0;it<rt;++it)for(var ot=tt[it],ct=ot.length,At,Rt=0;Rt<ct;++Rt)if(At=ot[Rt]){for(var qt=e.call(At,At.__data__,Rt,ot),Ft,Ut=get$1(At,Ye),Ht=0,zt=qt.length;Ht<zt;++Ht)(Ft=qt[Ht])&&schedule(Ft,t,Ye,Ht,qt,Ut);nt.push(qt),at.push(At)}return new Transition$1(nt,at,t,Ye)}var Selection=selection.prototype.constructor;function transition_selection(){return new Selection(this._groups,this._parents)}function styleNull(e,t){var Ye,tt,rt;return function(){var nt=styleValue(this,e),at=(this.style.removeProperty(e),styleValue(this,e));return nt===at?null:nt===Ye&&at===tt?rt:rt=t(Ye=nt,tt=at)}}function styleRemove(e){return function(){this.style.removeProperty(e)}}function styleConstant(e,t,Ye){var tt,rt=Ye+"",nt;return function(){var at=styleValue(this,e);return at===rt?null:at===tt?nt:nt=t(tt=at,Ye)}}function styleFunction(e,t,Ye){var tt,rt,nt;return function(){var at=styleValue(this,e),it=Ye(this),ot=it+"";return it==null&&(ot=it=(this.style.removeProperty(e),styleValue(this,e))),at===ot?null:at===tt&&ot===rt?nt:(rt=ot,nt=t(tt=at,it))}}function styleMaybeRemove(e,t){var Ye,tt,rt,nt="style."+t,at="end."+nt,it;return function(){var ot=set$1(this,e),ct=ot.on,At=ot.value[nt]==null?it||(it=styleRemove(t)):void 0;(ct!==Ye||rt!==At)&&(tt=(Ye=ct).copy()).on(at,rt=At),ot.on=tt}}function transition_style(e,t,Ye){var tt=(e+="")=="transform"?interpolateTransformCss:interpolate;return t==null?this.styleTween(e,styleNull(e,tt)).on("end.style."+e,styleRemove(e)):typeof t=="function"?this.styleTween(e,styleFunction(e,tt,tweenValue(this,"style."+e,t))).each(styleMaybeRemove(this._id,e)):this.styleTween(e,styleConstant(e,tt,t),Ye).on("end.style."+e,null)}function styleInterpolate(e,t,Ye){return function(tt){this.style.setProperty(e,t.call(this,tt),Ye)}}function styleTween(e,t,Ye){var tt,rt;function nt(){var at=t.apply(this,arguments);return at!==rt&&(tt=(rt=at)&&styleInterpolate(e,at,Ye)),tt}return nt._value=t,nt}function transition_styleTween(e,t,Ye){var tt="style."+(e+="");if(arguments.length<2)return(tt=this.tween(tt))&&tt._value;if(t==null)return this.tween(tt,null);if(typeof t!="function")throw new Error;return this.tween(tt,styleTween(e,t,Ye??""))}function textConstant(e){return function(){this.textContent=e}}function textFunction(e){return function(){var t=e(this);this.textContent=t??""}}function transition_text(e){return this.tween("text",typeof e=="function"?textFunction(tweenValue(this,"text",e)):textConstant(e==null?"":e+""))}function textInterpolate(e){return function(t){this.textContent=e.call(this,t)}}function textTween(e){var t,Ye;function tt(){var rt=e.apply(this,arguments);return rt!==Ye&&(t=(Ye=rt)&&textInterpolate(rt)),t}return tt._value=e,tt}function transition_textTween(e){var t="text";if(arguments.length<1)return(t=this.tween(t))&&t._value;if(e==null)return this.tween(t,null);if(typeof e!="function")throw new Error;return this.tween(t,textTween(e))}function transition_transition(){for(var e=this._name,t=this._id,Ye=newId(),tt=this._groups,rt=tt.length,nt=0;nt<rt;++nt)for(var at=tt[nt],it=at.length,ot,ct=0;ct<it;++ct)if(ot=at[ct]){var At=get$1(ot,t);schedule(ot,e,Ye,ct,at,{time:At.time+At.delay+At.duration,delay:0,duration:At.duration,ease:At.ease})}return new Transition$1(tt,this._parents,e,Ye)}function transition_end(){var e,t,Ye=this,tt=Ye._id,rt=Ye.size();return new Promise(function(nt,at){var it={value:at},ot={value:function(){--rt===0&&nt()}};Ye.each(function(){var ct=set$1(this,tt),At=ct.on;At!==e&&(t=(e=At).copy(),t._.cancel.push(it),t._.interrupt.push(it),t._.end.push(ot)),ct.on=t}),rt===0&&nt()})}var id$1=0;function Transition$1(e,t,Ye,tt){this._groups=e,this._parents=t,this._name=Ye,this._id=tt}function newId(){return++id$1}var selection_prototype=selection.prototype;Transition$1.prototype={constructor:Transition$1,select:transition_select,selectAll:transition_selectAll,selectChild:selection_prototype.selectChild,selectChildren:selection_prototype.selectChildren,filter:transition_filter,merge:transition_merge,selection:transition_selection,transition:transition_transition,call:selection_prototype.call,nodes:selection_prototype.nodes,node:selection_prototype.node,size:selection_prototype.size,empty:selection_prototype.empty,each:selection_prototype.each,on:transition_on,attr:transition_attr,attrTween:transition_attrTween,style:transition_style,styleTween:transition_styleTween,text:transition_text,textTween:transition_textTween,remove:transition_remove,tween:transition_tween,delay:transition_delay,duration:transition_duration,ease:transition_ease,easeVarying:transition_easeVarying,end:transition_end,[Symbol.iterator]:selection_prototype[Symbol.iterator]};function cubicInOut(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}var defaultTiming={time:null,delay:0,duration:250,ease:cubicInOut};function inherit(e,t){for(var Ye;!(Ye=e.__transition)||!(Ye=Ye[t]);)if(!(e=e.parentNode))throw new Error(`transition ${t} not found`);return Ye}function selection_transition(e){var t,Ye;e instanceof Transition$1?(t=e._id,e=e._name):(t=newId(),(Ye=defaultTiming).time=now(),e=e==null?null:e+"");for(var tt=this._groups,rt=tt.length,nt=0;nt<rt;++nt)for(var at=tt[nt],it=at.length,ot,ct=0;ct<it;++ct)(ot=at[ct])&&schedule(ot,e,t,ct,at,Ye||inherit(ot,t));return new Transition$1(tt,this._parents,e,t)}selection.prototype.interrupt=selection_interrupt;selection.prototype.transition=selection_transition;const constant$1=e=>()=>e;function ZoomEvent(e,{sourceEvent:t,target:Ye,transform:tt,dispatch:rt}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},target:{value:Ye,enumerable:!0,configurable:!0},transform:{value:tt,enumerable:!0,configurable:!0},_:{value:rt}})}function Transform(e,t,Ye){this.k=e,this.x=t,this.y=Ye}Transform.prototype={constructor:Transform,scale:function(e){return e===1?this:new Transform(this.k*e,this.x,this.y)},translate:function(e,t){return e===0&t===0?this:new Transform(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};var identity$2=new Transform(1,0,0);transform$1.prototype=Transform.prototype;function transform$1(e){for(;!e.__zoom;)if(!(e=e.parentNode))return identity$2;return e.__zoom}function nopropagation(e){e.stopImmediatePropagation()}function noevent(e){e.preventDefault(),e.stopImmediatePropagation()}function defaultFilter(e){return(!e.ctrlKey||e.type==="wheel")&&!e.button}function defaultExtent(){var e=this;return e instanceof SVGElement?(e=e.ownerSVGElement||e,e.hasAttribute("viewBox")?(e=e.viewBox.baseVal,[[e.x,e.y],[e.x+e.width,e.y+e.height]]):[[0,0],[e.width.baseVal.value,e.height.baseVal.value]]):[[0,0],[e.clientWidth,e.clientHeight]]}function defaultTransform(){return this.__zoom||identity$2}function defaultWheelDelta(e){return-e.deltaY*(e.deltaMode===1?.05:e.deltaMode?1:.002)*(e.ctrlKey?10:1)}function defaultTouchable(){return navigator.maxTouchPoints||"ontouchstart"in this}function defaultConstrain(e,t,Ye){var tt=e.invertX(t[0][0])-Ye[0][0],rt=e.invertX(t[1][0])-Ye[1][0],nt=e.invertY(t[0][1])-Ye[0][1],at=e.invertY(t[1][1])-Ye[1][1];return e.translate(rt>tt?(tt+rt)/2:Math.min(0,tt)||Math.max(0,rt),at>nt?(nt+at)/2:Math.min(0,nt)||Math.max(0,at))}function zoom(){var e=defaultFilter,t=defaultExtent,Ye=defaultConstrain,tt=defaultWheelDelta,rt=defaultTouchable,nt=[0,1/0],at=[[-1/0,-1/0],[1/0,1/0]],it=250,ot=interpolateZoom,ct=dispatch("start","zoom","end"),At,Rt,qt,Ft=500,Ut=150,Ht=0,zt=10;function Yt(dr){dr.property("__zoom",defaultTransform).on("wheel.zoom",nr,{passive:!1}).on("mousedown.zoom",ar).on("dblclick.zoom",sr).filter(rt).on("touchstart.zoom",lr).on("touchmove.zoom",fr).on("touchend.zoom touchcancel.zoom",gr).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}Yt.transform=function(dr,vr,mr,Er){var _r=dr.selection?dr.selection():dr;_r.property("__zoom",defaultTransform),dr!==_r?Xt(dr,vr,mr,Er):_r.interrupt().each(function(){Qt(this,arguments).event(Er).start().zoom(null,typeof vr=="function"?vr.apply(this,arguments):vr).end()})},Yt.scaleBy=function(dr,vr,mr,Er){Yt.scaleTo(dr,function(){var _r=this.__zoom.k,Tr=typeof vr=="function"?vr.apply(this,arguments):vr;return _r*Tr},mr,Er)},Yt.scaleTo=function(dr,vr,mr,Er){Yt.transform(dr,function(){var _r=t.apply(this,arguments),Tr=this.__zoom,ur=mr==null?Zt(_r):typeof mr=="function"?mr.apply(this,arguments):mr,cr=Tr.invert(ur),yr=typeof vr=="function"?vr.apply(this,arguments):vr;return Ye(Vt(Gt(Tr,yr),ur,cr),_r,at)},mr,Er)},Yt.translateBy=function(dr,vr,mr,Er){Yt.transform(dr,function(){return Ye(this.__zoom.translate(typeof vr=="function"?vr.apply(this,arguments):vr,typeof mr=="function"?mr.apply(this,arguments):mr),t.apply(this,arguments),at)},null,Er)},Yt.translateTo=function(dr,vr,mr,Er,_r){Yt.transform(dr,function(){var Tr=t.apply(this,arguments),ur=this.__zoom,cr=Er==null?Zt(Tr):typeof Er=="function"?Er.apply(this,arguments):Er;return Ye(identity$2.translate(cr[0],cr[1]).scale(ur.k).translate(typeof vr=="function"?-vr.apply(this,arguments):-vr,typeof mr=="function"?-mr.apply(this,arguments):-mr),Tr,at)},Er,_r)};function Gt(dr,vr){return vr=Math.max(nt[0],Math.min(nt[1],vr)),vr===dr.k?dr:new Transform(vr,dr.x,dr.y)}function Vt(dr,vr,mr){var Er=vr[0]-mr[0]*dr.k,_r=vr[1]-mr[1]*dr.k;return Er===dr.x&&_r===dr.y?dr:new Transform(dr.k,Er,_r)}function Zt(dr){return[(+dr[0][0]+ +dr[1][0])/2,(+dr[0][1]+ +dr[1][1])/2]}function Xt(dr,vr,mr,Er){dr.on("start.zoom",function(){Qt(this,arguments).event(Er).start()}).on("interrupt.zoom end.zoom",function(){Qt(this,arguments).event(Er).end()}).tween("zoom",function(){var _r=this,Tr=arguments,ur=Qt(_r,Tr).event(Er),cr=t.apply(_r,Tr),yr=mr==null?Zt(cr):typeof mr=="function"?mr.apply(_r,Tr):mr,ir=Math.max(cr[1][0]-cr[0][0],cr[1][1]-cr[0][1]),or=_r.__zoom,hr=typeof vr=="function"?vr.apply(_r,Tr):vr,Sr=ot(or.invert(yr).concat(ir/or.k),hr.invert(yr).concat(ir/hr.k));return function(wr){if(wr===1)wr=hr;else{var Ir=Sr(wr),kr=ir/Ir[2];wr=new Transform(kr,yr[0]-Ir[0]*kr,yr[1]-Ir[1]*kr)}ur.zoom(null,wr)}})}function Qt(dr,vr,mr){return!mr&&dr.__zooming||new er(dr,vr)}function er(dr,vr){this.that=dr,this.args=vr,this.active=0,this.sourceEvent=null,this.extent=t.apply(dr,vr),this.taps=0}er.prototype={event:function(dr){return dr&&(this.sourceEvent=dr),this},start:function(){return++this.active===1&&(this.that.__zooming=this,this.emit("start")),this},zoom:function(dr,vr){return this.mouse&&dr!=="mouse"&&(this.mouse[1]=vr.invert(this.mouse[0])),this.touch0&&dr!=="touch"&&(this.touch0[1]=vr.invert(this.touch0[0])),this.touch1&&dr!=="touch"&&(this.touch1[1]=vr.invert(this.touch1[0])),this.that.__zoom=vr,this.emit("zoom"),this},end:function(){return--this.active===0&&(delete this.that.__zooming,this.emit("end")),this},emit:function(dr){var vr=select(this.that).datum();ct.call(dr,this.that,new ZoomEvent(dr,{sourceEvent:this.sourceEvent,target:Yt,transform:this.that.__zoom,dispatch:ct}),vr)}};function nr(dr,...vr){if(!e.apply(this,arguments))return;var mr=Qt(this,vr).event(dr),Er=this.__zoom,_r=Math.max(nt[0],Math.min(nt[1],Er.k*Math.pow(2,tt.apply(this,arguments)))),Tr=pointer(dr);if(mr.wheel)(mr.mouse[0][0]!==Tr[0]||mr.mouse[0][1]!==Tr[1])&&(mr.mouse[1]=Er.invert(mr.mouse[0]=Tr)),clearTimeout(mr.wheel);else{if(Er.k===_r)return;mr.mouse=[Tr,Er.invert(Tr)],interrupt(this),mr.start()}noevent(dr),mr.wheel=setTimeout(ur,Ut),mr.zoom("mouse",Ye(Vt(Gt(Er,_r),mr.mouse[0],mr.mouse[1]),mr.extent,at));function ur(){mr.wheel=null,mr.end()}}function ar(dr,...vr){if(qt||!e.apply(this,arguments))return;var mr=dr.currentTarget,Er=Qt(this,vr,!0).event(dr),_r=select(dr.view).on("mousemove.zoom",yr,!0).on("mouseup.zoom",ir,!0),Tr=pointer(dr,mr),ur=dr.clientX,cr=dr.clientY;dragDisable(dr.view),nopropagation(dr),Er.mouse=[Tr,this.__zoom.invert(Tr)],interrupt(this),Er.start();function yr(or){if(noevent(or),!Er.moved){var hr=or.clientX-ur,Sr=or.clientY-cr;Er.moved=hr*hr+Sr*Sr>Ht}Er.event(or).zoom("mouse",Ye(Vt(Er.that.__zoom,Er.mouse[0]=pointer(or,mr),Er.mouse[1]),Er.extent,at))}function ir(or){_r.on("mousemove.zoom mouseup.zoom",null),yesdrag(or.view,Er.moved),noevent(or),Er.event(or).end()}}function sr(dr,...vr){if(e.apply(this,arguments)){var mr=this.__zoom,Er=pointer(dr.changedTouches?dr.changedTouches[0]:dr,this),_r=mr.invert(Er),Tr=mr.k*(dr.shiftKey?.5:2),ur=Ye(Vt(Gt(mr,Tr),Er,_r),t.apply(this,vr),at);noevent(dr),it>0?select(this).transition().duration(it).call(Xt,ur,Er,dr):select(this).call(Yt.transform,ur,Er,dr)}}function lr(dr,...vr){if(e.apply(this,arguments)){var mr=dr.touches,Er=mr.length,_r=Qt(this,vr,dr.changedTouches.length===Er).event(dr),Tr,ur,cr,yr;for(nopropagation(dr),ur=0;ur<Er;++ur)cr=mr[ur],yr=pointer(cr,this),yr=[yr,this.__zoom.invert(yr),cr.identifier],_r.touch0?!_r.touch1&&_r.touch0[2]!==yr[2]&&(_r.touch1=yr,_r.taps=0):(_r.touch0=yr,Tr=!0,_r.taps=1+!!At);At&&(At=clearTimeout(At)),Tr&&(_r.taps<2&&(Rt=yr[0],At=setTimeout(function(){At=null},Ft)),interrupt(this),_r.start())}}function fr(dr,...vr){if(this.__zooming){var mr=Qt(this,vr).event(dr),Er=dr.changedTouches,_r=Er.length,Tr,ur,cr,yr;for(noevent(dr),Tr=0;Tr<_r;++Tr)ur=Er[Tr],cr=pointer(ur,this),mr.touch0&&mr.touch0[2]===ur.identifier?mr.touch0[0]=cr:mr.touch1&&mr.touch1[2]===ur.identifier&&(mr.touch1[0]=cr);if(ur=mr.that.__zoom,mr.touch1){var ir=mr.touch0[0],or=mr.touch0[1],hr=mr.touch1[0],Sr=mr.touch1[1],wr=(wr=hr[0]-ir[0])*wr+(wr=hr[1]-ir[1])*wr,Ir=(Ir=Sr[0]-or[0])*Ir+(Ir=Sr[1]-or[1])*Ir;ur=Gt(ur,Math.sqrt(wr/Ir)),cr=[(ir[0]+hr[0])/2,(ir[1]+hr[1])/2],yr=[(or[0]+Sr[0])/2,(or[1]+Sr[1])/2]}else if(mr.touch0)cr=mr.touch0[0],yr=mr.touch0[1];else return;mr.zoom("touch",Ye(Vt(ur,cr,yr),mr.extent,at))}}function gr(dr,...vr){if(this.__zooming){var mr=Qt(this,vr).event(dr),Er=dr.changedTouches,_r=Er.length,Tr,ur;for(nopropagation(dr),qt&&clearTimeout(qt),qt=setTimeout(function(){qt=null},Ft),Tr=0;Tr<_r;++Tr)ur=Er[Tr],mr.touch0&&mr.touch0[2]===ur.identifier?delete mr.touch0:mr.touch1&&mr.touch1[2]===ur.identifier&&delete mr.touch1;if(mr.touch1&&!mr.touch0&&(mr.touch0=mr.touch1,delete mr.touch1),mr.touch0)mr.touch0[1]=this.__zoom.invert(mr.touch0[0]);else if(mr.end(),mr.taps===2&&(ur=pointer(ur,this),Math.hypot(Rt[0]-ur[0],Rt[1]-ur[1])<zt)){var cr=select(this).on("dblclick.zoom");cr&&cr.apply(this,arguments)}}}return Yt.wheelDelta=function(dr){return arguments.length?(tt=typeof dr=="function"?dr:constant$1(+dr),Yt):tt},Yt.filter=function(dr){return arguments.length?(e=typeof dr=="function"?dr:constant$1(!!dr),Yt):e},Yt.touchable=function(dr){return arguments.length?(rt=typeof dr=="function"?dr:constant$1(!!dr),Yt):rt},Yt.extent=function(dr){return arguments.length?(t=typeof dr=="function"?dr:constant$1([[+dr[0][0],+dr[0][1]],[+dr[1][0],+dr[1][1]]]),Yt):t},Yt.scaleExtent=function(dr){return arguments.length?(nt[0]=+dr[0],nt[1]=+dr[1],Yt):[nt[0],nt[1]]},Yt.translateExtent=function(dr){return arguments.length?(at[0][0]=+dr[0][0],at[1][0]=+dr[1][0],at[0][1]=+dr[0][1],at[1][1]=+dr[1][1],Yt):[[at[0][0],at[0][1]],[at[1][0],at[1][1]]]},Yt.constrain=function(dr){return arguments.length?(Ye=dr,Yt):Ye},Yt.duration=function(dr){return arguments.length?(it=+dr,Yt):it},Yt.interpolate=function(dr){return arguments.length?(ot=dr,Yt):ot},Yt.on=function(){var dr=ct.on.apply(ct,arguments);return dr===ct?Yt:dr},Yt.clickDistance=function(dr){return arguments.length?(Ht=(dr=+dr)*dr,Yt):Math.sqrt(Ht)},Yt.tapDistance=function(dr){return arguments.length?(zt=+dr,Yt):zt},Yt}const errorMessages={error001:()=>"[React Flow]: Seems like you have not used zustand provider as an ancestor. Help: https://reactflow.dev/error#001",error002:()=>"It looks like you've created a new nodeTypes or edgeTypes object. If this wasn't on purpose please define the nodeTypes/edgeTypes outside of the component or memoize them.",error003:e=>`Node type "${e}" not found. Using fallback type "default".`,error004:()=>"The React Flow parent container needs a width and a height to render the graph.",error005:()=>"Only child nodes can use a parent extent.",error006:()=>"Can't create edge. An edge needs a source and a target.",error007:e=>`The old edge with id=${e} does not exist.`,error009:e=>`Marker type "${e}" doesn't exist.`,error008:(e,{id:t,sourceHandle:Ye,targetHandle:tt})=>`Couldn't create edge for ${e} handle id: "${e==="source"?Ye:tt}", edge id: ${t}.`,error010:()=>"Handle: No node id found. Make sure to only use a Handle inside a custom Node.",error011:e=>`Edge type "${e}" not found. Using fallback type "default".`,error012:e=>`Node with id "${e}" does not exist, it may have been removed. This can happen when a node is deleted before the "onNodeClick" handler is called.`,error013:(e="react")=>`It seems that you haven't loaded the styles. Please import '@xyflow/${e}/dist/style.css' or base.css to make sure everything is working properly.`,error014:()=>"useNodeConnections: No node ID found. Call useNodeConnections inside a custom Node or provide a node ID.",error015:()=>"It seems that you are trying to drag a node that is not initialized. Please use onNodesChange as explained in the docs."},infiniteExtent=[[Number.NEGATIVE_INFINITY,Number.NEGATIVE_INFINITY],[Number.POSITIVE_INFINITY,Number.POSITIVE_INFINITY]],elementSelectionKeys=["Enter"," ","Escape"];var ConnectionMode;(function(e){e.Strict="strict",e.Loose="loose"})(ConnectionMode||(ConnectionMode={}));var PanOnScrollMode;(function(e){e.Free="free",e.Vertical="vertical",e.Horizontal="horizontal"})(PanOnScrollMode||(PanOnScrollMode={}));var SelectionMode;(function(e){e.Partial="partial",e.Full="full"})(SelectionMode||(SelectionMode={}));const initialConnection={inProgress:!1,isValid:null,from:null,fromHandle:null,fromPosition:null,fromNode:null,to:null,toHandle:null,toPosition:null,toNode:null};var ConnectionLineType;(function(e){e.Bezier="default",e.Straight="straight",e.Step="step",e.SmoothStep="smoothstep",e.SimpleBezier="simplebezier"})(ConnectionLineType||(ConnectionLineType={}));var MarkerType;(function(e){e.Arrow="arrow",e.ArrowClosed="arrowclosed"})(MarkerType||(MarkerType={}));var Position;(function(e){e.Left="left",e.Top="top",e.Right="right",e.Bottom="bottom"})(Position||(Position={}));const oppositePosition={[Position.Left]:Position.Right,[Position.Right]:Position.Left,[Position.Top]:Position.Bottom,[Position.Bottom]:Position.Top};function getConnectionStatus(e){return e===null?null:e?"valid":"invalid"}const isEdgeBase=e=>"id"in e&&"source"in e&&"target"in e,isNodeBase=e=>"id"in e&&"position"in e&&!("source"in e)&&!("target"in e),isInternalNodeBase=e=>"id"in e&&"internals"in e&&!("source"in e)&&!("target"in e),getNodePositionWithOrigin=(e,t=[0,0])=>{const{width:Ye,height:tt}=getNodeDimensions(e),rt=e.origin??t,nt=Ye*rt[0],at=tt*rt[1];return{x:e.position.x-nt,y:e.position.y-at}},getNodesBounds=(e,t={nodeOrigin:[0,0]})=>{if(e.length===0)return{x:0,y:0,width:0,height:0};const Ye=e.reduce((tt,rt)=>{const nt=typeof rt=="string";let at=!t.nodeLookup&&!nt?rt:void 0;t.nodeLookup&&(at=nt?t.nodeLookup.get(rt):isInternalNodeBase(rt)?rt:t.nodeLookup.get(rt.id));const it=at?nodeToBox(at,t.nodeOrigin):{x:0,y:0,x2:0,y2:0};return getBoundsOfBoxes(tt,it)},{x:1/0,y:1/0,x2:-1/0,y2:-1/0});return boxToRect(Ye)},getInternalNodesBounds=(e,t={})=>{if(e.size===0)return{x:0,y:0,width:0,height:0};let Ye={x:1/0,y:1/0,x2:-1/0,y2:-1/0};return e.forEach(tt=>{if(t.filter===void 0||t.filter(tt)){const rt=nodeToBox(tt);Ye=getBoundsOfBoxes(Ye,rt)}}),boxToRect(Ye)},getNodesInside=(e,t,[Ye,tt,rt]=[0,0,1],nt=!1,at=!1)=>{const it={...pointToRendererPoint(t,[Ye,tt,rt]),width:t.width/rt,height:t.height/rt},ot=[];for(const ct of e.values()){const{measured:At,selectable:Rt=!0,hidden:qt=!1}=ct;if(at&&!Rt||qt)continue;const Ft=At.width??ct.width??ct.initialWidth??null,Ut=At.height??ct.height??ct.initialHeight??null,Ht=getOverlappingArea(it,nodeToRect(ct)),zt=(Ft??0)*(Ut??0),Yt=nt&&Ht>0;(!ct.internals.handleBounds||Yt||Ht>=zt||ct.dragging)&&ot.push(ct)}return ot},getConnectedEdges=(e,t)=>{const Ye=new Set;return e.forEach(tt=>{Ye.add(tt.id)}),t.filter(tt=>Ye.has(tt.source)||Ye.has(tt.target))};function getFitViewNodes(e,t){const Ye=new Map,tt=t!=null&&t.nodes?new Set(t.nodes.map(rt=>rt.id)):null;return e.forEach(rt=>{rt.measured.width&&rt.measured.height&&((t==null?void 0:t.includeHiddenNodes)||!rt.hidden)&&(!tt||tt.has(rt.id))&&Ye.set(rt.id,rt)}),Ye}async function fitViewport({nodes:e,width:t,height:Ye,panZoom:tt,minZoom:rt,maxZoom:nt},at){if(e.size===0)return Promise.resolve(!0);const it=getFitViewNodes(e,at),ot=getInternalNodesBounds(it),ct=getViewportForBounds(ot,t,Ye,(at==null?void 0:at.minZoom)??rt,(at==null?void 0:at.maxZoom)??nt,(at==null?void 0:at.padding)??.1);return await tt.setViewport(ct,{duration:at==null?void 0:at.duration}),Promise.resolve(!0)}function calculateNodePosition({nodeId:e,nextPosition:t,nodeLookup:Ye,nodeOrigin:tt=[0,0],nodeExtent:rt,onError:nt}){const at=Ye.get(e),it=at.parentId?Ye.get(at.parentId):void 0,{x:ot,y:ct}=it?it.internals.positionAbsolute:{x:0,y:0},At=at.origin??tt;let Rt=rt;if(at.extent==="parent"&&!at.expandParent)if(!it)nt==null||nt("005",errorMessages.error005());else{const Ft=it.measured.width,Ut=it.measured.height;Ft&&Ut&&(Rt=[[ot,ct],[ot+Ft,ct+Ut]])}else it&&isCoordinateExtent(at.extent)&&(Rt=[[at.extent[0][0]+ot,at.extent[0][1]+ct],[at.extent[1][0]+ot,at.extent[1][1]+ct]]);const qt=isCoordinateExtent(Rt)?clampPosition(t,Rt,at.measured):t;return(at.measured.width===void 0||at.measured.height===void 0)&&(nt==null||nt("015",errorMessages.error015())),{position:{x:qt.x-ot+(at.measured.width??0)*At[0],y:qt.y-ct+(at.measured.height??0)*At[1]},positionAbsolute:qt}}async function getElementsToRemove({nodesToRemove:e=[],edgesToRemove:t=[],nodes:Ye,edges:tt,onBeforeDelete:rt}){const nt=new Set(e.map(qt=>qt.id)),at=[];for(const qt of Ye){if(qt.deletable===!1)continue;const Ft=nt.has(qt.id),Ut=!Ft&&qt.parentId&&at.find(Ht=>Ht.id===qt.parentId);(Ft||Ut)&&at.push(qt)}const it=new Set(t.map(qt=>qt.id)),ot=tt.filter(qt=>qt.deletable!==!1),At=getConnectedEdges(at,ot);for(const qt of ot)it.has(qt.id)&&!At.find(Ut=>Ut.id===qt.id)&&At.push(qt);if(!rt)return{edges:At,nodes:at};const Rt=await rt({nodes:at,edges:At});return typeof Rt=="boolean"?Rt?{edges:At,nodes:at}:{edges:[],nodes:[]}:Rt}const clamp=(e,t=0,Ye=1)=>Math.min(Math.max(e,t),Ye),clampPosition=(e={x:0,y:0},t,Ye)=>({x:clamp(e.x,t[0][0],t[1][0]-((Ye==null?void 0:Ye.width)??0)),y:clamp(e.y,t[0][1],t[1][1]-((Ye==null?void 0:Ye.height)??0))});function clampPositionToParent(e,t,Ye){const{width:tt,height:rt}=getNodeDimensions(Ye),{x:nt,y:at}=Ye.internals.positionAbsolute;return clampPosition(e,[[nt,at],[nt+tt,at+rt]],t)}const calcAutoPanVelocity=(e,t,Ye)=>e<t?clamp(Math.abs(e-t),1,t)/t:e>Ye?-clamp(Math.abs(e-Ye),1,t)/t:0,calcAutoPan=(e,t,Ye=15,tt=40)=>{const rt=calcAutoPanVelocity(e.x,tt,t.width-tt)*Ye,nt=calcAutoPanVelocity(e.y,tt,t.height-tt)*Ye;return[rt,nt]},getBoundsOfBoxes=(e,t)=>({x:Math.min(e.x,t.x),y:Math.min(e.y,t.y),x2:Math.max(e.x2,t.x2),y2:Math.max(e.y2,t.y2)}),rectToBox=({x:e,y:t,width:Ye,height:tt})=>({x:e,y:t,x2:e+Ye,y2:t+tt}),boxToRect=({x:e,y:t,x2:Ye,y2:tt})=>({x:e,y:t,width:Ye-e,height:tt-t}),nodeToRect=(e,t=[0,0])=>{var rt,nt;const{x:Ye,y:tt}=isInternalNodeBase(e)?e.internals.positionAbsolute:getNodePositionWithOrigin(e,t);return{x:Ye,y:tt,width:((rt=e.measured)==null?void 0:rt.width)??e.width??e.initialWidth??0,height:((nt=e.measured)==null?void 0:nt.height)??e.height??e.initialHeight??0}},nodeToBox=(e,t=[0,0])=>{var rt,nt;const{x:Ye,y:tt}=isInternalNodeBase(e)?e.internals.positionAbsolute:getNodePositionWithOrigin(e,t);return{x:Ye,y:tt,x2:Ye+(((rt=e.measured)==null?void 0:rt.width)??e.width??e.initialWidth??0),y2:tt+(((nt=e.measured)==null?void 0:nt.height)??e.height??e.initialHeight??0)}},getBoundsOfRects=(e,t)=>boxToRect(getBoundsOfBoxes(rectToBox(e),rectToBox(t))),getOverlappingArea=(e,t)=>{const Ye=Math.max(0,Math.min(e.x+e.width,t.x+t.width)-Math.max(e.x,t.x)),tt=Math.max(0,Math.min(e.y+e.height,t.y+t.height)-Math.max(e.y,t.y));return Math.ceil(Ye*tt)},isRectObject=e=>isNumeric(e.width)&&isNumeric(e.height)&&isNumeric(e.x)&&isNumeric(e.y),isNumeric=e=>!isNaN(e)&&isFinite(e),devWarn=(e,t)=>{},snapPosition=(e,t=[1,1])=>({x:t[0]*Math.round(e.x/t[0]),y:t[1]*Math.round(e.y/t[1])}),pointToRendererPoint=({x:e,y:t},[Ye,tt,rt],nt=!1,at=[1,1])=>{const it={x:(e-Ye)/rt,y:(t-tt)/rt};return nt?snapPosition(it,at):it},rendererPointToPoint=({x:e,y:t},[Ye,tt,rt])=>({x:e*rt+Ye,y:t*rt+tt});function parsePadding(e,t){if(typeof e=="number")return Math.floor((t-t/(1+e))*.5);if(typeof e=="string"&&e.endsWith("px")){const Ye=parseFloat(e);if(!Number.isNaN(Ye))return Math.floor(Ye)}if(typeof e=="string"&&e.endsWith("%")){const Ye=parseFloat(e);if(!Number.isNaN(Ye))return Math.floor(t*Ye*.01)}return console.error(`[React Flow] The padding value "${e}" is invalid. Please provide a number or a string with a valid unit (px or %).`),0}function parsePaddings(e,t,Ye){if(typeof e=="string"||typeof e=="number"){const tt=parsePadding(e,Ye),rt=parsePadding(e,t);return{top:tt,right:rt,bottom:tt,left:rt,x:rt*2,y:tt*2}}if(typeof e=="object"){const tt=parsePadding(e.top??e.y??0,Ye),rt=parsePadding(e.bottom??e.y??0,Ye),nt=parsePadding(e.left??e.x??0,t),at=parsePadding(e.right??e.x??0,t);return{top:tt,right:at,bottom:rt,left:nt,x:nt+at,y:tt+rt}}return{top:0,right:0,bottom:0,left:0,x:0,y:0}}function calculateAppliedPaddings(e,t,Ye,tt,rt,nt){const{x:at,y:it}=rendererPointToPoint(e,[t,Ye,tt]),{x:ot,y:ct}=rendererPointToPoint({x:e.x+e.width,y:e.y+e.height},[t,Ye,tt]),At=rt-ot,Rt=nt-ct;return{left:Math.floor(at),top:Math.floor(it),right:Math.floor(At),bottom:Math.floor(Rt)}}const getViewportForBounds=(e,t,Ye,tt,rt,nt)=>{const at=parsePaddings(nt,t,Ye),it=(t-at.x)/e.width,ot=(Ye-at.y)/e.height,ct=Math.min(it,ot),At=clamp(ct,tt,rt),Rt=e.x+e.width/2,qt=e.y+e.height/2,Ft=t/2-Rt*At,Ut=Ye/2-qt*At,Ht=calculateAppliedPaddings(e,Ft,Ut,At,t,Ye),zt={left:Math.min(Ht.left-at.left,0),top:Math.min(Ht.top-at.top,0),right:Math.min(Ht.right-at.right,0),bottom:Math.min(Ht.bottom-at.bottom,0)};return{x:Ft-zt.left+zt.right,y:Ut-zt.top+zt.bottom,zoom:At}},isMacOs=()=>{var e;return typeof navigator<"u"&&((e=navigator==null?void 0:navigator.userAgent)==null?void 0:e.indexOf("Mac"))>=0};function isCoordinateExtent(e){return e!==void 0&&e!=="parent"}function getNodeDimensions(e){var t,Ye;return{width:((t=e.measured)==null?void 0:t.width)??e.width??e.initialWidth??0,height:((Ye=e.measured)==null?void 0:Ye.height)??e.height??e.initialHeight??0}}function nodeHasDimensions(e){var t,Ye;return(((t=e.measured)==null?void 0:t.width)??e.width??e.initialWidth)!==void 0&&(((Ye=e.measured)==null?void 0:Ye.height)??e.height??e.initialHeight)!==void 0}function evaluateAbsolutePosition(e,t={width:0,height:0},Ye,tt,rt){const nt={...e},at=tt.get(Ye);if(at){const it=at.origin||rt;nt.x+=at.internals.positionAbsolute.x-(t.width??0)*it[0],nt.y+=at.internals.positionAbsolute.y-(t.height??0)*it[1]}return nt}function areSetsEqual(e,t){if(e.size!==t.size)return!1;for(const Ye of e)if(!t.has(Ye))return!1;return!0}function withResolvers(){let e,t;return{promise:new Promise((tt,rt)=>{e=tt,t=rt}),resolve:e,reject:t}}function getPointerPosition(e,{snapGrid:t=[0,0],snapToGrid:Ye=!1,transform:tt,containerBounds:rt}){const{x:nt,y:at}=getEventPosition(e),it=pointToRendererPoint({x:nt-((rt==null?void 0:rt.left)??0),y:at-((rt==null?void 0:rt.top)??0)},tt),{x:ot,y:ct}=Ye?snapPosition(it,t):it;return{xSnapped:ot,ySnapped:ct,...it}}const getDimensions=e=>({width:e.offsetWidth,height:e.offsetHeight}),getHostForElement=e=>{var t;return((t=e==null?void 0:e.getRootNode)==null?void 0:t.call(e))||(window==null?void 0:window.document)},inputTags=["INPUT","SELECT","TEXTAREA"];function isInputDOMNode(e){var tt,rt;const t=((rt=(tt=e.composedPath)==null?void 0:tt.call(e))==null?void 0:rt[0])||e.target;return(t==null?void 0:t.nodeType)!==1?!1:inputTags.includes(t.nodeName)||t.hasAttribute("contenteditable")||!!t.closest(".nokey")}const isMouseEvent=e=>"clientX"in e,getEventPosition=(e,t)=>{var nt,at;const Ye=isMouseEvent(e),tt=Ye?e.clientX:(nt=e.touches)==null?void 0:nt[0].clientX,rt=Ye?e.clientY:(at=e.touches)==null?void 0:at[0].clientY;return{x:tt-((t==null?void 0:t.left)??0),y:rt-((t==null?void 0:t.top)??0)}},getHandleBounds=(e,t,Ye,tt,rt)=>{const nt=t.querySelectorAll(`.${e}`);return!nt||!nt.length?null:Array.from(nt).map(at=>{const it=at.getBoundingClientRect();return{id:at.getAttribute("data-handleid"),type:e,nodeId:rt,position:at.getAttribute("data-handlepos"),x:(it.left-Ye.left)/tt,y:(it.top-Ye.top)/tt,...getDimensions(at)}})};function getBezierEdgeCenter({sourceX:e,sourceY:t,targetX:Ye,targetY:tt,sourceControlX:rt,sourceControlY:nt,targetControlX:at,targetControlY:it}){const ot=e*.125+rt*.375+at*.375+Ye*.125,ct=t*.125+nt*.375+it*.375+tt*.125,At=Math.abs(ot-e),Rt=Math.abs(ct-t);return[ot,ct,At,Rt]}function calculateControlOffset(e,t){return e>=0?.5*e:t*25*Math.sqrt(-e)}function getControlWithCurvature({pos:e,x1:t,y1:Ye,x2:tt,y2:rt,c:nt}){switch(e){case Position.Left:return[t-calculateControlOffset(t-tt,nt),Ye];case Position.Right:return[t+calculateControlOffset(tt-t,nt),Ye];case Position.Top:return[t,Ye-calculateControlOffset(Ye-rt,nt)];case Position.Bottom:return[t,Ye+calculateControlOffset(rt-Ye,nt)]}}function getBezierPath({sourceX:e,sourceY:t,sourcePosition:Ye=Position.Bottom,targetX:tt,targetY:rt,targetPosition:nt=Position.Top,curvature:at=.25}){const[it,ot]=getControlWithCurvature({pos:Ye,x1:e,y1:t,x2:tt,y2:rt,c:at}),[ct,At]=getControlWithCurvature({pos:nt,x1:tt,y1:rt,x2:e,y2:t,c:at}),[Rt,qt,Ft,Ut]=getBezierEdgeCenter({sourceX:e,sourceY:t,targetX:tt,targetY:rt,sourceControlX:it,sourceControlY:ot,targetControlX:ct,targetControlY:At});return[`M${e},${t} C${it},${ot} ${ct},${At} ${tt},${rt}`,Rt,qt,Ft,Ut]}function getEdgeCenter({sourceX:e,sourceY:t,targetX:Ye,targetY:tt}){const rt=Math.abs(Ye-e)/2,nt=Ye<e?Ye+rt:Ye-rt,at=Math.abs(tt-t)/2,it=tt<t?tt+at:tt-at;return[nt,it,rt,at]}function getElevatedEdgeZIndex({sourceNode:e,targetNode:t,selected:Ye=!1,zIndex:tt=0,elevateOnSelect:rt=!1}){if(!rt)return tt;const nt=Ye||t.selected||e.selected,at=Math.max(e.internals.z||0,t.internals.z||0,1e3);return tt+(nt?at:0)}function isEdgeVisible({sourceNode:e,targetNode:t,width:Ye,height:tt,transform:rt}){const nt=getBoundsOfBoxes(nodeToBox(e),nodeToBox(t));nt.x===nt.x2&&(nt.x2+=1),nt.y===nt.y2&&(nt.y2+=1);const at={x:-rt[0]/rt[2],y:-rt[1]/rt[2],width:Ye/rt[2],height:tt/rt[2]};return getOverlappingArea(at,boxToRect(nt))>0}const getEdgeId=({source:e,sourceHandle:t,target:Ye,targetHandle:tt})=>`xy-edge__${e}${t||""}-${Ye}${tt||""}`,connectionExists=(e,t)=>t.some(Ye=>Ye.source===e.source&&Ye.target===e.target&&(Ye.sourceHandle===e.sourceHandle||!Ye.sourceHandle&&!e.sourceHandle)&&(Ye.targetHandle===e.targetHandle||!Ye.targetHandle&&!e.targetHandle)),addEdge=(e,t)=>{if(!e.source||!e.target)return t;let Ye;return isEdgeBase(e)?Ye={...e}:Ye={...e,id:getEdgeId(e)},connectionExists(Ye,t)?t:(Ye.sourceHandle===null&&delete Ye.sourceHandle,Ye.targetHandle===null&&delete Ye.targetHandle,t.concat(Ye))};function getStraightPath({sourceX:e,sourceY:t,targetX:Ye,targetY:tt}){const[rt,nt,at,it]=getEdgeCenter({sourceX:e,sourceY:t,targetX:Ye,targetY:tt});return[`M ${e},${t}L ${Ye},${tt}`,rt,nt,at,it]}const handleDirections={[Position.Left]:{x:-1,y:0},[Position.Right]:{x:1,y:0},[Position.Top]:{x:0,y:-1},[Position.Bottom]:{x:0,y:1}},getDirection=({source:e,sourcePosition:t=Position.Bottom,target:Ye})=>t===Position.Left||t===Position.Right?e.x<Ye.x?{x:1,y:0}:{x:-1,y:0}:e.y<Ye.y?{x:0,y:1}:{x:0,y:-1},distance=(e,t)=>Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2));function getPoints({source:e,sourcePosition:t=Position.Bottom,target:Ye,targetPosition:tt=Position.Top,center:rt,offset:nt}){const at=handleDirections[t],it=handleDirections[tt],ot={x:e.x+at.x*nt,y:e.y+at.y*nt},ct={x:Ye.x+it.x*nt,y:Ye.y+it.y*nt},At=getDirection({source:ot,sourcePosition:t,target:ct}),Rt=At.x!==0?"x":"y",qt=At[Rt];let Ft=[],Ut,Ht;const zt={x:0,y:0},Yt={x:0,y:0},[Gt,Vt,Zt,Xt]=getEdgeCenter({sourceX:e.x,sourceY:e.y,targetX:Ye.x,targetY:Ye.y});if(at[Rt]*it[Rt]===-1){Ut=rt.x??Gt,Ht=rt.y??Vt;const er=[{x:Ut,y:ot.y},{x:Ut,y:ct.y}],nr=[{x:ot.x,y:Ht},{x:ct.x,y:Ht}];at[Rt]===qt?Ft=Rt==="x"?er:nr:Ft=Rt==="x"?nr:er}else{const er=[{x:ot.x,y:ct.y}],nr=[{x:ct.x,y:ot.y}];if(Rt==="x"?Ft=at.x===qt?nr:er:Ft=at.y===qt?er:nr,t===tt){const gr=Math.abs(e[Rt]-Ye[Rt]);if(gr<=nt){const dr=Math.min(nt-1,nt-gr);at[Rt]===qt?zt[Rt]=(ot[Rt]>e[Rt]?-1:1)*dr:Yt[Rt]=(ct[Rt]>Ye[Rt]?-1:1)*dr}}if(t!==tt){const gr=Rt==="x"?"y":"x",dr=at[Rt]===it[gr],vr=ot[gr]>ct[gr],mr=ot[gr]<ct[gr];(at[Rt]===1&&(!dr&&vr||dr&&mr)||at[Rt]!==1&&(!dr&&mr||dr&&vr))&&(Ft=Rt==="x"?er:nr)}const ar={x:ot.x+zt.x,y:ot.y+zt.y},sr={x:ct.x+Yt.x,y:ct.y+Yt.y},lr=Math.max(Math.abs(ar.x-Ft[0].x),Math.abs(sr.x-Ft[0].x)),fr=Math.max(Math.abs(ar.y-Ft[0].y),Math.abs(sr.y-Ft[0].y));lr>=fr?(Ut=(ar.x+sr.x)/2,Ht=Ft[0].y):(Ut=Ft[0].x,Ht=(ar.y+sr.y)/2)}return[[e,{x:ot.x+zt.x,y:ot.y+zt.y},...Ft,{x:ct.x+Yt.x,y:ct.y+Yt.y},Ye],Ut,Ht,Zt,Xt]}function getBend(e,t,Ye,tt){const rt=Math.min(distance(e,t)/2,distance(t,Ye)/2,tt),{x:nt,y:at}=t;if(e.x===nt&&nt===Ye.x||e.y===at&&at===Ye.y)return`L${nt} ${at}`;if(e.y===at){const ct=e.x<Ye.x?-1:1,At=e.y<Ye.y?1:-1;return`L ${nt+rt*ct},${at}Q ${nt},${at} ${nt},${at+rt*At}`}const it=e.x<Ye.x?1:-1,ot=e.y<Ye.y?-1:1;return`L ${nt},${at+rt*ot}Q ${nt},${at} ${nt+rt*it},${at}`}function getSmoothStepPath({sourceX:e,sourceY:t,sourcePosition:Ye=Position.Bottom,targetX:tt,targetY:rt,targetPosition:nt=Position.Top,borderRadius:at=5,centerX:it,centerY:ot,offset:ct=20}){const[At,Rt,qt,Ft,Ut]=getPoints({source:{x:e,y:t},sourcePosition:Ye,target:{x:tt,y:rt},targetPosition:nt,center:{x:it,y:ot},offset:ct});return[At.reduce((zt,Yt,Gt)=>{let Vt="";return Gt>0&&Gt<At.length-1?Vt=getBend(At[Gt-1],Yt,At[Gt+1],at):Vt=`${Gt===0?"M":"L"}${Yt.x} ${Yt.y}`,zt+=Vt,zt},""),Rt,qt,Ft,Ut]}function isNodeInitialized(e){var t;return e&&!!(e.internals.handleBounds||(t=e.handles)!=null&&t.length)&&!!(e.measured.width||e.width||e.initialWidth)}function getEdgePosition(e){var Rt;const{sourceNode:t,targetNode:Ye}=e;if(!isNodeInitialized(t)||!isNodeInitialized(Ye))return null;const tt=t.internals.handleBounds||toHandleBounds(t.handles),rt=Ye.internals.handleBounds||toHandleBounds(Ye.handles),nt=getHandle$1((tt==null?void 0:tt.source)??[],e.sourceHandle),at=getHandle$1(e.connectionMode===ConnectionMode.Strict?(rt==null?void 0:rt.target)??[]:((rt==null?void 0:rt.target)??[]).concat((rt==null?void 0:rt.source)??[]),e.targetHandle);if(!nt||!at)return(Rt=e.onError)==null||Rt.call(e,"008",errorMessages.error008(nt?"target":"source",{id:e.id,sourceHandle:e.sourceHandle,targetHandle:e.targetHandle})),null;const it=(nt==null?void 0:nt.position)||Position.Bottom,ot=(at==null?void 0:at.position)||Position.Top,ct=getHandlePosition(t,nt,it),At=getHandlePosition(Ye,at,ot);return{sourceX:ct.x,sourceY:ct.y,targetX:At.x,targetY:At.y,sourcePosition:it,targetPosition:ot}}function toHandleBounds(e){if(!e)return null;const t=[],Ye=[];for(const tt of e)tt.width=tt.width??1,tt.height=tt.height??1,tt.type==="source"?t.push(tt):tt.type==="target"&&Ye.push(tt);return{source:t,target:Ye}}function getHandlePosition(e,t,Ye=Position.Left,tt=!1){const rt=((t==null?void 0:t.x)??0)+e.internals.positionAbsolute.x,nt=((t==null?void 0:t.y)??0)+e.internals.positionAbsolute.y,{width:at,height:it}=t??getNodeDimensions(e);if(tt)return{x:rt+at/2,y:nt+it/2};switch((t==null?void 0:t.position)??Ye){case Position.Top:return{x:rt+at/2,y:nt};case Position.Right:return{x:rt+at,y:nt+it/2};case Position.Bottom:return{x:rt+at/2,y:nt+it};case Position.Left:return{x:rt,y:nt+it/2}}}function getHandle$1(e,t){return e&&(t?e.find(Ye=>Ye.id===t):e[0])||null}function getMarkerId(e,t){return e?typeof e=="string"?e:`${t?`${t}__`:""}${Object.keys(e).sort().map(tt=>`${tt}=${e[tt]}`).join("&")}`:""}function createMarkerIds(e,{id:t,defaultColor:Ye,defaultMarkerStart:tt,defaultMarkerEnd:rt}){const nt=new Set;return e.reduce((at,it)=>([it.markerStart||tt,it.markerEnd||rt].forEach(ot=>{if(ot&&typeof ot=="object"){const ct=getMarkerId(ot,t);nt.has(ct)||(at.push({id:ct,color:ot.color||Ye,...ot}),nt.add(ct))}}),at),[]).sort((at,it)=>at.id.localeCompare(it.id))}const defaultOptions={nodeOrigin:[0,0],nodeExtent:infiniteExtent,elevateNodesOnSelect:!0,defaults:{}},adoptUserNodesDefaultOptions={...defaultOptions,checkEquality:!0};function mergeObjects$1(e,t){const Ye={...e};for(const tt in t)t[tt]!==void 0&&(Ye[tt]=t[tt]);return Ye}function updateAbsolutePositions(e,t,Ye){const tt=mergeObjects$1(defaultOptions,Ye);for(const rt of e.values())if(rt.parentId)updateChildNode(rt,e,t,tt);else{const nt=getNodePositionWithOrigin(rt,tt.nodeOrigin),at=isCoordinateExtent(rt.extent)?rt.extent:tt.nodeExtent,it=clampPosition(nt,at,getNodeDimensions(rt));rt.internals.positionAbsolute=it}}function adoptUserNodes(e,t,Ye,tt){var ot,ct;const rt=mergeObjects$1(adoptUserNodesDefaultOptions,tt);let nt=e.length>0;const at=new Map(t),it=rt!=null&&rt.elevateNodesOnSelect?1e3:0;t.clear(),Ye.clear();for(const At of e){let Rt=at.get(At.id);if(rt.checkEquality&&At===(Rt==null?void 0:Rt.internals.userNode))t.set(At.id,Rt);else{const qt=getNodePositionWithOrigin(At,rt.nodeOrigin),Ft=isCoordinateExtent(At.extent)?At.extent:rt.nodeExtent,Ut=clampPosition(qt,Ft,getNodeDimensions(At));Rt={...rt.defaults,...At,measured:{width:(ot=At.measured)==null?void 0:ot.width,height:(ct=At.measured)==null?void 0:ct.height},internals:{positionAbsolute:Ut,handleBounds:At.measured?Rt==null?void 0:Rt.internals.handleBounds:void 0,z:calculateZ(At,it),userNode:At}},t.set(At.id,Rt)}(Rt.measured===void 0||Rt.measured.width===void 0||Rt.measured.height===void 0)&&!Rt.hidden&&(nt=!1),At.parentId&&updateChildNode(Rt,t,Ye,tt)}return nt}function updateParentLookup(e,t){if(!e.parentId)return;const Ye=t.get(e.parentId);Ye?Ye.set(e.id,e):t.set(e.parentId,new Map([[e.id,e]]))}function updateChildNode(e,t,Ye,tt){const{elevateNodesOnSelect:rt,nodeOrigin:nt,nodeExtent:at}=mergeObjects$1(defaultOptions,tt),it=e.parentId,ot=t.get(it);if(!ot){console.warn(`Parent node ${it} not found. Please make sure that parent nodes are in front of their child nodes in the nodes array.`);return}updateParentLookup(e,Ye);const ct=rt?1e3:0,{x:At,y:Rt,z:qt}=calculateChildXYZ(e,ot,nt,at,ct),{positionAbsolute:Ft}=e.internals,Ut=At!==Ft.x||Rt!==Ft.y;(Ut||qt!==e.internals.z)&&t.set(e.id,{...e,internals:{...e.internals,positionAbsolute:Ut?{x:At,y:Rt}:Ft,z:qt}})}function calculateZ(e,t){return(isNumeric(e.zIndex)?e.zIndex:0)+(e.selected?t:0)}function calculateChildXYZ(e,t,Ye,tt,rt){const{x:nt,y:at}=t.internals.positionAbsolute,it=getNodeDimensions(e),ot=getNodePositionWithOrigin(e,Ye),ct=isCoordinateExtent(e.extent)?clampPosition(ot,e.extent,it):ot;let At=clampPosition({x:nt+ct.x,y:at+ct.y},tt,it);e.extent==="parent"&&(At=clampPositionToParent(At,it,t));const Rt=calculateZ(e,rt),qt=t.internals.z??0;return{x:At.x,y:At.y,z:qt>Rt?qt:Rt}}function handleExpandParent(e,t,Ye,tt=[0,0]){var at;const rt=[],nt=new Map;for(const it of e){const ot=t.get(it.parentId);if(!ot)continue;const ct=((at=nt.get(it.parentId))==null?void 0:at.expandedRect)??nodeToRect(ot),At=getBoundsOfRects(ct,it.rect);nt.set(it.parentId,{expandedRect:At,parent:ot})}return nt.size>0&&nt.forEach(({expandedRect:it,parent:ot},ct)=>{var Vt;const At=ot.internals.positionAbsolute,Rt=getNodeDimensions(ot),qt=ot.origin??tt,Ft=it.x<At.x?Math.round(Math.abs(At.x-it.x)):0,Ut=it.y<At.y?Math.round(Math.abs(At.y-it.y)):0,Ht=Math.max(Rt.width,Math.round(it.width)),zt=Math.max(Rt.height,Math.round(it.height)),Yt=(Ht-Rt.width)*qt[0],Gt=(zt-Rt.height)*qt[1];(Ft>0||Ut>0||Yt||Gt)&&(rt.push({id:ct,type:"position",position:{x:ot.position.x-Ft+Yt,y:ot.position.y-Ut+Gt}}),(Vt=Ye.get(ct))==null||Vt.forEach(Zt=>{e.some(Xt=>Xt.id===Zt.id)||rt.push({id:Zt.id,type:"position",position:{x:Zt.position.x+Ft,y:Zt.position.y+Ut}})})),(Rt.width<it.width||Rt.height<it.height||Ft||Ut)&&rt.push({id:ct,type:"dimensions",setAttributes:!0,dimensions:{width:Ht+(Ft?qt[0]*Ft-Yt:0),height:zt+(Ut?qt[1]*Ut-Gt:0)}})}),rt}function updateNodeInternals(e,t,Ye,tt,rt,nt){const at=tt==null?void 0:tt.querySelector(".xyflow__viewport");let it=!1;if(!at)return{changes:[],updatedInternals:it};const ot=[],ct=window.getComputedStyle(at),{m22:At}=new window.DOMMatrixReadOnly(ct.transform),Rt=[];for(const qt of e.values()){const Ft=t.get(qt.id);if(!Ft)continue;if(Ft.hidden){t.set(Ft.id,{...Ft,internals:{...Ft.internals,handleBounds:void 0}}),it=!0;continue}const Ut=getDimensions(qt.nodeElement),Ht=Ft.measured.width!==Ut.width||Ft.measured.height!==Ut.height;if(!!(Ut.width&&Ut.height&&(Ht||!Ft.internals.handleBounds||qt.force))){const Yt=qt.nodeElement.getBoundingClientRect(),Gt=isCoordinateExtent(Ft.extent)?Ft.extent:nt;let{positionAbsolute:Vt}=Ft.internals;Ft.parentId&&Ft.extent==="parent"?Vt=clampPositionToParent(Vt,Ut,t.get(Ft.parentId)):Gt&&(Vt=clampPosition(Vt,Gt,Ut));const Zt={...Ft,measured:Ut,internals:{...Ft.internals,positionAbsolute:Vt,handleBounds:{source:getHandleBounds("source",qt.nodeElement,Yt,At,Ft.id),target:getHandleBounds("target",qt.nodeElement,Yt,At,Ft.id)}}};t.set(Ft.id,Zt),Ft.parentId&&updateChildNode(Zt,t,Ye,{nodeOrigin:rt}),it=!0,Ht&&(ot.push({id:Ft.id,type:"dimensions",dimensions:Ut}),Ft.expandParent&&Ft.parentId&&Rt.push({id:Ft.id,parentId:Ft.parentId,rect:nodeToRect(Zt,rt)}))}}if(Rt.length>0){const qt=handleExpandParent(Rt,t,Ye,rt);ot.push(...qt)}return{changes:ot,updatedInternals:it}}async function panBy({delta:e,panZoom:t,transform:Ye,translateExtent:tt,width:rt,height:nt}){if(!t||!e.x&&!e.y)return Promise.resolve(!1);const at=await t.setViewportConstrained({x:Ye[0]+e.x,y:Ye[1]+e.y,zoom:Ye[2]},[[0,0],[rt,nt]],tt),it=!!at&&(at.x!==Ye[0]||at.y!==Ye[1]||at.k!==Ye[2]);return Promise.resolve(it)}function addConnectionToLookup(e,t,Ye,tt,rt,nt){let at=rt;const it=tt.get(at)||new Map;tt.set(at,it.set(Ye,t)),at=`${rt}-${e}`;const ot=tt.get(at)||new Map;if(tt.set(at,ot.set(Ye,t)),nt){at=`${rt}-${e}-${nt}`;const ct=tt.get(at)||new Map;tt.set(at,ct.set(Ye,t))}}function updateConnectionLookup(e,t,Ye){e.clear(),t.clear();for(const tt of Ye){const{source:rt,target:nt,sourceHandle:at=null,targetHandle:it=null}=tt,ot={edgeId:tt.id,source:rt,target:nt,sourceHandle:at,targetHandle:it},ct=`${rt}-${at}--${nt}-${it}`,At=`${nt}-${it}--${rt}-${at}`;addConnectionToLookup("source",ot,At,e,rt,at),addConnectionToLookup("target",ot,ct,e,nt,it),t.set(tt.id,tt)}}function isParentSelected(e,t){if(!e.parentId)return!1;const Ye=t.get(e.parentId);return Ye?Ye.selected?!0:isParentSelected(Ye,t):!1}function hasSelector(e,t,Ye){var rt;let tt=e;do{if((rt=tt==null?void 0:tt.matches)!=null&&rt.call(tt,t))return!0;if(tt===Ye)return!1;tt=tt==null?void 0:tt.parentElement}while(tt);return!1}function getDragItems(e,t,Ye,tt){const rt=new Map;for(const[nt,at]of e)if((at.selected||at.id===tt)&&(!at.parentId||!isParentSelected(at,e))&&(at.draggable||t&&typeof at.draggable>"u")){const it=e.get(nt);it&&rt.set(nt,{id:nt,position:it.position||{x:0,y:0},distance:{x:Ye.x-it.internals.positionAbsolute.x,y:Ye.y-it.internals.positionAbsolute.y},extent:it.extent,parentId:it.parentId,origin:it.origin,expandParent:it.expandParent,internals:{positionAbsolute:it.internals.positionAbsolute||{x:0,y:0}},measured:{width:it.measured.width??0,height:it.measured.height??0}})}return rt}function getEventHandlerParams({nodeId:e,dragItems:t,nodeLookup:Ye,dragging:tt=!0}){var at,it,ot;const rt=[];for(const[ct,At]of t){const Rt=(at=Ye.get(ct))==null?void 0:at.internals.userNode;Rt&&rt.push({...Rt,position:At.position,dragging:tt})}if(!e)return[rt[0],rt];const nt=(it=Ye.get(e))==null?void 0:it.internals.userNode;return[nt?{...nt,position:((ot=t.get(e))==null?void 0:ot.position)||nt.position,dragging:tt}:rt[0],rt]}function XYDrag({onNodeMouseDown:e,getStoreItems:t,onDragStart:Ye,onDrag:tt,onDragStop:rt}){let nt={x:null,y:null},at=0,it=new Map,ot=!1,ct={x:0,y:0},At=null,Rt=!1,qt=null,Ft=!1;function Ut({noDragClassName:zt,handleSelector:Yt,domNode:Gt,isSelectable:Vt,nodeId:Zt,nodeClickDistance:Xt=0}){qt=select(Gt);function Qt({x:sr,y:lr},fr){const{nodeLookup:gr,nodeExtent:dr,snapGrid:vr,snapToGrid:mr,nodeOrigin:Er,onNodeDrag:_r,onSelectionDrag:Tr,onError:ur,updateNodePositions:cr}=t();nt={x:sr,y:lr};let yr=!1,ir={x:0,y:0,x2:0,y2:0};if(it.size>1&&dr){const or=getInternalNodesBounds(it);ir=rectToBox(or)}for(const[or,hr]of it){if(!gr.has(or))continue;let Sr={x:sr-hr.distance.x,y:lr-hr.distance.y};mr&&(Sr=snapPosition(Sr,vr));let wr=[[dr[0][0],dr[0][1]],[dr[1][0],dr[1][1]]];if(it.size>1&&dr&&!hr.extent){const{positionAbsolute:Mr}=hr.internals,Ar=Mr.x-ir.x+dr[0][0],Rr=Mr.x+hr.measured.width-ir.x2+dr[1][0],Dr=Mr.y-ir.y+dr[0][1],Lr=Mr.y+hr.measured.height-ir.y2+dr[1][1];wr=[[Ar,Dr],[Rr,Lr]]}const{position:Ir,positionAbsolute:kr}=calculateNodePosition({nodeId:or,nextPosition:Sr,nodeLookup:gr,nodeExtent:wr,nodeOrigin:Er,onError:ur});yr=yr||hr.position.x!==Ir.x||hr.position.y!==Ir.y,hr.position=Ir,hr.internals.positionAbsolute=kr}if(yr&&(cr(it,!0),fr&&(tt||_r||!Zt&&Tr))){const[or,hr]=getEventHandlerParams({nodeId:Zt,dragItems:it,nodeLookup:gr});tt==null||tt(fr,it,or,hr),_r==null||_r(fr,or,hr),Zt||Tr==null||Tr(fr,hr)}}async function er(){if(!At)return;const{transform:sr,panBy:lr,autoPanSpeed:fr,autoPanOnNodeDrag:gr}=t();if(!gr){ot=!1,cancelAnimationFrame(at);return}const[dr,vr]=calcAutoPan(ct,At,fr);(dr!==0||vr!==0)&&(nt.x=(nt.x??0)-dr/sr[2],nt.y=(nt.y??0)-vr/sr[2],await lr({x:dr,y:vr})&&Qt(nt,null)),at=requestAnimationFrame(er)}function nr(sr){var yr;const{nodeLookup:lr,multiSelectionActive:fr,nodesDraggable:gr,transform:dr,snapGrid:vr,snapToGrid:mr,selectNodesOnDrag:Er,onNodeDragStart:_r,onSelectionDragStart:Tr,unselectNodesAndEdges:ur}=t();Rt=!0,(!Er||!Vt)&&!fr&&Zt&&((yr=lr.get(Zt))!=null&&yr.selected||ur()),Vt&&Er&&Zt&&(e==null||e(Zt));const cr=getPointerPosition(sr.sourceEvent,{transform:dr,snapGrid:vr,snapToGrid:mr,containerBounds:At});if(nt=cr,it=getDragItems(lr,gr,cr,Zt),it.size>0&&(Ye||_r||!Zt&&Tr)){const[ir,or]=getEventHandlerParams({nodeId:Zt,dragItems:it,nodeLookup:lr});Ye==null||Ye(sr.sourceEvent,it,ir,or),_r==null||_r(sr.sourceEvent,ir,or),Zt||Tr==null||Tr(sr.sourceEvent,or)}}const ar=drag().clickDistance(Xt).on("start",sr=>{const{domNode:lr,nodeDragThreshold:fr,transform:gr,snapGrid:dr,snapToGrid:vr}=t();At=(lr==null?void 0:lr.getBoundingClientRect())||null,Ft=!1,fr===0&&nr(sr),nt=getPointerPosition(sr.sourceEvent,{transform:gr,snapGrid:dr,snapToGrid:vr,containerBounds:At}),ct=getEventPosition(sr.sourceEvent,At)}).on("drag",sr=>{const{autoPanOnNodeDrag:lr,transform:fr,snapGrid:gr,snapToGrid:dr,nodeDragThreshold:vr,nodeLookup:mr}=t(),Er=getPointerPosition(sr.sourceEvent,{transform:fr,snapGrid:gr,snapToGrid:dr,containerBounds:At});if((sr.sourceEvent.type==="touchmove"&&sr.sourceEvent.touches.length>1||Zt&&!mr.has(Zt))&&(Ft=!0),!Ft){if(!ot&&lr&&Rt&&(ot=!0,er()),!Rt){const _r=Er.xSnapped-(nt.x??0),Tr=Er.ySnapped-(nt.y??0);Math.sqrt(_r*_r+Tr*Tr)>vr&&nr(sr)}(nt.x!==Er.xSnapped||nt.y!==Er.ySnapped)&&it&&Rt&&(ct=getEventPosition(sr.sourceEvent,At),Qt(Er,sr.sourceEvent))}}).on("end",sr=>{if(!(!Rt||Ft)&&(ot=!1,Rt=!1,cancelAnimationFrame(at),it.size>0)){const{nodeLookup:lr,updateNodePositions:fr,onNodeDragStop:gr,onSelectionDragStop:dr}=t();if(fr(it,!1),rt||gr||!Zt&&dr){const[vr,mr]=getEventHandlerParams({nodeId:Zt,dragItems:it,nodeLookup:lr,dragging:!1});rt==null||rt(sr.sourceEvent,it,vr,mr),gr==null||gr(sr.sourceEvent,vr,mr),Zt||dr==null||dr(sr.sourceEvent,mr)}}}).filter(sr=>{const lr=sr.target;return!sr.button&&(!zt||!hasSelector(lr,`.${zt}`,Gt))&&(!Yt||hasSelector(lr,Yt,Gt))});qt.call(ar)}function Ht(){qt==null||qt.on(".drag",null)}return{update:Ut,destroy:Ht}}function getNodesWithinDistance(e,t,Ye){const tt=[],rt={x:e.x-Ye,y:e.y-Ye,width:Ye*2,height:Ye*2};for(const nt of t.values())getOverlappingArea(rt,nodeToRect(nt))>0&&tt.push(nt);return tt}const ADDITIONAL_DISTANCE=250;function getClosestHandle(e,t,Ye,tt){var it,ot;let rt=[],nt=1/0;const at=getNodesWithinDistance(e,Ye,t+ADDITIONAL_DISTANCE);for(const ct of at){const At=[...((it=ct.internals.handleBounds)==null?void 0:it.source)??[],...((ot=ct.internals.handleBounds)==null?void 0:ot.target)??[]];for(const Rt of At){if(tt.nodeId===Rt.nodeId&&tt.type===Rt.type&&tt.id===Rt.id)continue;const{x:qt,y:Ft}=getHandlePosition(ct,Rt,Rt.position,!0),Ut=Math.sqrt(Math.pow(qt-e.x,2)+Math.pow(Ft-e.y,2));Ut>t||(Ut<nt?(rt=[{...Rt,x:qt,y:Ft}],nt=Ut):Ut===nt&&rt.push({...Rt,x:qt,y:Ft}))}}if(!rt.length)return null;if(rt.length>1){const ct=tt.type==="source"?"target":"source";return rt.find(At=>At.type===ct)??rt[0]}return rt[0]}function getHandle(e,t,Ye,tt,rt,nt=!1){var ct,At,Rt;const at=tt.get(e);if(!at)return null;const it=rt==="strict"?(ct=at.internals.handleBounds)==null?void 0:ct[t]:[...((At=at.internals.handleBounds)==null?void 0:At.source)??[],...((Rt=at.internals.handleBounds)==null?void 0:Rt.target)??[]],ot=(Ye?it==null?void 0:it.find(qt=>qt.id===Ye):it==null?void 0:it[0])??null;return ot&&nt?{...ot,...getHandlePosition(at,ot,ot.position,!0)}:ot}function getHandleType(e,t){return e||(t!=null&&t.classList.contains("target")?"target":t!=null&&t.classList.contains("source")?"source":null)}function isConnectionValid(e,t){let Ye=null;return t?Ye=!0:e&&!t&&(Ye=!1),Ye}const alwaysValid=()=>!0;function onPointerDown(e,{connectionMode:t,connectionRadius:Ye,handleId:tt,nodeId:rt,edgeUpdaterType:nt,isTarget:at,domNode:it,nodeLookup:ot,lib:ct,autoPanOnConnect:At,flowId:Rt,panBy:qt,cancelConnection:Ft,onConnectStart:Ut,onConnect:Ht,onConnectEnd:zt,isValidConnection:Yt=alwaysValid,onReconnectEnd:Gt,updateConnection:Vt,getTransform:Zt,getFromHandle:Xt,autoPanSpeed:Qt}){const er=getHostForElement(e.target);let nr=0,ar;const{x:sr,y:lr}=getEventPosition(e),fr=er==null?void 0:er.elementFromPoint(sr,lr),gr=getHandleType(nt,fr),dr=it==null?void 0:it.getBoundingClientRect();if(!dr||!gr)return;const vr=getHandle(rt,gr,tt,ot,t);if(!vr)return;let mr=getEventPosition(e,dr),Er=!1,_r=null,Tr=!1,ur=null;function cr(){if(!At||!dr)return;const[kr,Mr]=calcAutoPan(mr,dr,Qt);qt({x:kr,y:Mr}),nr=requestAnimationFrame(cr)}const yr={...vr,nodeId:rt,type:gr,position:vr.position},ir=ot.get(rt),hr={inProgress:!0,isValid:null,from:getHandlePosition(ir,yr,Position.Left,!0),fromHandle:yr,fromPosition:yr.position,fromNode:ir,to:mr,toHandle:null,toPosition:oppositePosition[yr.position],toNode:null};Vt(hr);let Sr=hr;Ut==null||Ut(e,{nodeId:rt,handleId:tt,handleType:gr});function wr(kr){if(!Xt()||!yr){Ir(kr);return}const Mr=Zt();mr=getEventPosition(kr,dr),ar=getClosestHandle(pointToRendererPoint(mr,Mr,!1,[1,1]),Ye,ot,yr),Er||(cr(),Er=!0);const Ar=isValidHandle(kr,{handle:ar,connectionMode:t,fromNodeId:rt,fromHandleId:tt,fromType:at?"target":"source",isValidConnection:Yt,doc:er,lib:ct,flowId:Rt,nodeLookup:ot});ur=Ar.handleDomNode,_r=Ar.connection,Tr=isConnectionValid(!!ar,Ar.isValid);const Rr={...Sr,isValid:Tr,to:Ar.toHandle&&Tr?rendererPointToPoint({x:Ar.toHandle.x,y:Ar.toHandle.y},Mr):mr,toHandle:Ar.toHandle,toPosition:Tr&&Ar.toHandle?Ar.toHandle.position:oppositePosition[yr.position],toNode:Ar.toHandle?ot.get(Ar.toHandle.nodeId):null};Tr&&ar&&Sr.toHandle&&Rr.toHandle&&Sr.toHandle.type===Rr.toHandle.type&&Sr.toHandle.nodeId===Rr.toHandle.nodeId&&Sr.toHandle.id===Rr.toHandle.id&&Sr.to.x===Rr.to.x&&Sr.to.y===Rr.to.y||(Vt(Rr),Sr=Rr)}function Ir(kr){(ar||ur)&&_r&&Tr&&(Ht==null||Ht(_r));const{inProgress:Mr,...Ar}=Sr,Rr={...Ar,toPosition:Sr.toHandle?Sr.toPosition:null};zt==null||zt(kr,Rr),nt&&(Gt==null||Gt(kr,Rr)),Ft(),cancelAnimationFrame(nr),Er=!1,Tr=!1,_r=null,ur=null,er.removeEventListener("mousemove",wr),er.removeEventListener("mouseup",Ir),er.removeEventListener("touchmove",wr),er.removeEventListener("touchend",Ir)}er.addEventListener("mousemove",wr),er.addEventListener("mouseup",Ir),er.addEventListener("touchmove",wr),er.addEventListener("touchend",Ir)}function isValidHandle(e,{handle:t,connectionMode:Ye,fromNodeId:tt,fromHandleId:rt,fromType:nt,doc:at,lib:it,flowId:ot,isValidConnection:ct=alwaysValid,nodeLookup:At}){const Rt=nt==="target",qt=t?at.querySelector(`.${it}-flow__handle[data-id="${ot}-${t==null?void 0:t.nodeId}-${t==null?void 0:t.id}-${t==null?void 0:t.type}"]`):null,{x:Ft,y:Ut}=getEventPosition(e),Ht=at.elementFromPoint(Ft,Ut),zt=Ht!=null&&Ht.classList.contains(`${it}-flow__handle`)?Ht:qt,Yt={handleDomNode:zt,isValid:!1,connection:null,toHandle:null};if(zt){const Gt=getHandleType(void 0,zt),Vt=zt.getAttribute("data-nodeid"),Zt=zt.getAttribute("data-handleid"),Xt=zt.classList.contains("connectable"),Qt=zt.classList.contains("connectableend");if(!Vt||!Gt)return Yt;const er={source:Rt?Vt:tt,sourceHandle:Rt?Zt:rt,target:Rt?tt:Vt,targetHandle:Rt?rt:Zt};Yt.connection=er;const ar=Xt&&Qt&&(Ye===ConnectionMode.Strict?Rt&&Gt==="source"||!Rt&&Gt==="target":Vt!==tt||Zt!==rt);Yt.isValid=ar&&ct(er),Yt.toHandle=getHandle(Vt,Gt,Zt,At,Ye,!0)}return Yt}const XYHandle={onPointerDown,isValid:isValidHandle};function XYMinimap({domNode:e,panZoom:t,getTransform:Ye,getViewScale:tt}){const rt=select(e);function nt({translateExtent:it,width:ot,height:ct,zoomStep:At=10,pannable:Rt=!0,zoomable:qt=!0,inversePan:Ft=!1}){const Ut=Vt=>{const Zt=Ye();if(Vt.sourceEvent.type!=="wheel"||!t)return;const Xt=-Vt.sourceEvent.deltaY*(Vt.sourceEvent.deltaMode===1?.05:Vt.sourceEvent.deltaMode?1:.002)*At,Qt=Zt[2]*Math.pow(2,Xt);t.scaleTo(Qt)};let Ht=[0,0];const zt=Vt=>{(Vt.sourceEvent.type==="mousedown"||Vt.sourceEvent.type==="touchstart")&&(Ht=[Vt.sourceEvent.clientX??Vt.sourceEvent.touches[0].clientX,Vt.sourceEvent.clientY??Vt.sourceEvent.touches[0].clientY])},Yt=Vt=>{const Zt=Ye();if(Vt.sourceEvent.type!=="mousemove"&&Vt.sourceEvent.type!=="touchmove"||!t)return;const Xt=[Vt.sourceEvent.clientX??Vt.sourceEvent.touches[0].clientX,Vt.sourceEvent.clientY??Vt.sourceEvent.touches[0].clientY],Qt=[Xt[0]-Ht[0],Xt[1]-Ht[1]];Ht=Xt;const er=tt()*Math.max(Zt[2],Math.log(Zt[2]))*(Ft?-1:1),nr={x:Zt[0]-Qt[0]*er,y:Zt[1]-Qt[1]*er},ar=[[0,0],[ot,ct]];t.setViewportConstrained({x:nr.x,y:nr.y,zoom:Zt[2]},ar,it)},Gt=zoom().on("start",zt).on("zoom",Rt?Yt:null).on("zoom.wheel",qt?Ut:null);rt.call(Gt,{})}function at(){rt.on("zoom",null)}return{update:nt,destroy:at,pointer}}const viewChanged=(e,t)=>e.x!==t.x||e.y!==t.y||e.zoom!==t.k,transformToViewport=e=>({x:e.x,y:e.y,zoom:e.k}),viewportToTransform=({x:e,y:t,zoom:Ye})=>identity$2.translate(e,t).scale(Ye),isWrappedWithClass=(e,t)=>e.target.closest(`.${t}`),isRightClickPan=(e,t)=>t===2&&Array.isArray(e)&&e.includes(2),getD3Transition=(e,t=0,Ye=()=>{})=>{const tt=typeof t=="number"&&t>0;return tt||Ye(),tt?e.transition().duration(t).on("end",Ye):e},wheelDelta=e=>{const t=e.ctrlKey&&isMacOs()?10:1;return-e.deltaY*(e.deltaMode===1?.05:e.deltaMode?1:.002)*t};function createPanOnScrollHandler({zoomPanValues:e,noWheelClassName:t,d3Selection:Ye,d3Zoom:tt,panOnScrollMode:rt,panOnScrollSpeed:nt,zoomOnPinch:at,onPanZoomStart:it,onPanZoom:ot,onPanZoomEnd:ct}){return At=>{if(isWrappedWithClass(At,t))return!1;At.preventDefault(),At.stopImmediatePropagation();const Rt=Ye.property("__zoom").k||1;if(At.ctrlKey&&at){const zt=pointer(At),Yt=wheelDelta(At),Gt=Rt*Math.pow(2,Yt);tt.scaleTo(Ye,Gt,zt,At);return}const qt=At.deltaMode===1?20:1;let Ft=rt===PanOnScrollMode.Vertical?0:At.deltaX*qt,Ut=rt===PanOnScrollMode.Horizontal?0:At.deltaY*qt;!isMacOs()&&At.shiftKey&&rt!==PanOnScrollMode.Vertical&&(Ft=At.deltaY*qt,Ut=0),tt.translateBy(Ye,-(Ft/Rt)*nt,-(Ut/Rt)*nt,{internal:!0});const Ht=transformToViewport(Ye.property("__zoom"));clearTimeout(e.panScrollTimeout),e.isPanScrolling||(e.isPanScrolling=!0,it==null||it(At,Ht)),e.isPanScrolling&&(ot==null||ot(At,Ht),e.panScrollTimeout=setTimeout(()=>{ct==null||ct(At,Ht),e.isPanScrolling=!1},150))}}function createZoomOnScrollHandler({noWheelClassName:e,preventScrolling:t,d3ZoomHandler:Ye}){return function(tt,rt){const nt=tt.type==="wheel",at=!t&&nt&&!tt.ctrlKey,it=isWrappedWithClass(tt,e);if(tt.ctrlKey&&nt&&it&&tt.preventDefault(),at||it)return null;tt.preventDefault(),Ye.call(this,tt,rt)}}function createPanZoomStartHandler({zoomPanValues:e,onDraggingChange:t,onPanZoomStart:Ye}){return tt=>{var nt,at,it;if((nt=tt.sourceEvent)!=null&&nt.internal)return;const rt=transformToViewport(tt.transform);e.mouseButton=((at=tt.sourceEvent)==null?void 0:at.button)||0,e.isZoomingOrPanning=!0,e.prevViewport=rt,((it=tt.sourceEvent)==null?void 0:it.type)==="mousedown"&&t(!0),Ye&&(Ye==null||Ye(tt.sourceEvent,rt))}}function createPanZoomHandler({zoomPanValues:e,panOnDrag:t,onPaneContextMenu:Ye,onTransformChange:tt,onPanZoom:rt}){return nt=>{var at,it;e.usedRightMouseButton=!!(Ye&&isRightClickPan(t,e.mouseButton??0)),(at=nt.sourceEvent)!=null&&at.sync||tt([nt.transform.x,nt.transform.y,nt.transform.k]),rt&&!((it=nt.sourceEvent)!=null&&it.internal)&&(rt==null||rt(nt.sourceEvent,transformToViewport(nt.transform)))}}function createPanZoomEndHandler({zoomPanValues:e,panOnDrag:t,panOnScroll:Ye,onDraggingChange:tt,onPanZoomEnd:rt,onPaneContextMenu:nt}){return at=>{var it;if(!((it=at.sourceEvent)!=null&&it.internal)&&(e.isZoomingOrPanning=!1,nt&&isRightClickPan(t,e.mouseButton??0)&&!e.usedRightMouseButton&&at.sourceEvent&&nt(at.sourceEvent),e.usedRightMouseButton=!1,tt(!1),rt&&viewChanged(e.prevViewport,at.transform))){const ot=transformToViewport(at.transform);e.prevViewport=ot,clearTimeout(e.timerId),e.timerId=setTimeout(()=>{rt==null||rt(at.sourceEvent,ot)},Ye?150:0)}}}function createFilter({zoomActivationKeyPressed:e,zoomOnScroll:t,zoomOnPinch:Ye,panOnDrag:tt,panOnScroll:rt,zoomOnDoubleClick:nt,userSelectionActive:at,noWheelClassName:it,noPanClassName:ot,lib:ct}){return At=>{var Ut;const Rt=e||t,qt=Ye&&At.ctrlKey;if(At.button===1&&At.type==="mousedown"&&(isWrappedWithClass(At,`${ct}-flow__node`)||isWrappedWithClass(At,`${ct}-flow__edge`)))return!0;if(!tt&&!Rt&&!rt&&!nt&&!Ye||at||isWrappedWithClass(At,it)&&At.type==="wheel"||isWrappedWithClass(At,ot)&&(At.type!=="wheel"||rt&&At.type==="wheel"&&!e)||!Ye&&At.ctrlKey&&At.type==="wheel")return!1;if(!Ye&&At.type==="touchstart"&&((Ut=At.touches)==null?void 0:Ut.length)>1)return At.preventDefault(),!1;if(!Rt&&!rt&&!qt&&At.type==="wheel"||!tt&&(At.type==="mousedown"||At.type==="touchstart")||Array.isArray(tt)&&!tt.includes(At.button)&&At.type==="mousedown")return!1;const Ft=Array.isArray(tt)&&tt.includes(At.button)||!At.button||At.button<=1;return(!At.ctrlKey||At.type==="wheel")&&Ft}}function XYPanZoom({domNode:e,minZoom:t,maxZoom:Ye,paneClickDistance:tt,translateExtent:rt,viewport:nt,onPanZoom:at,onPanZoomStart:it,onPanZoomEnd:ot,onDraggingChange:ct}){const At={isZoomingOrPanning:!1,usedRightMouseButton:!1,prevViewport:{x:0,y:0,zoom:0},mouseButton:0,timerId:void 0,panScrollTimeout:void 0,isPanScrolling:!1},Rt=e.getBoundingClientRect(),qt=zoom().clickDistance(!isNumeric(tt)||tt<0?0:tt).scaleExtent([t,Ye]).translateExtent(rt),Ft=select(e).call(qt);Vt({x:nt.x,y:nt.y,zoom:clamp(nt.zoom,t,Ye)},[[0,0],[Rt.width,Rt.height]],rt);const Ut=Ft.on("wheel.zoom"),Ht=Ft.on("dblclick.zoom");qt.wheelDelta(wheelDelta);function zt(fr,gr){return Ft?new Promise(dr=>{qt==null||qt.transform(getD3Transition(Ft,gr==null?void 0:gr.duration,()=>dr(!0)),fr)}):Promise.resolve(!1)}function Yt({noWheelClassName:fr,noPanClassName:gr,onPaneContextMenu:dr,userSelectionActive:vr,panOnScroll:mr,panOnDrag:Er,panOnScrollMode:_r,panOnScrollSpeed:Tr,preventScrolling:ur,zoomOnPinch:cr,zoomOnScroll:yr,zoomOnDoubleClick:ir,zoomActivationKeyPressed:or,lib:hr,onTransformChange:Sr}){vr&&!At.isZoomingOrPanning&&Gt();const Ir=mr&&!or&&!vr?createPanOnScrollHandler({zoomPanValues:At,noWheelClassName:fr,d3Selection:Ft,d3Zoom:qt,panOnScrollMode:_r,panOnScrollSpeed:Tr,zoomOnPinch:cr,onPanZoomStart:it,onPanZoom:at,onPanZoomEnd:ot}):createZoomOnScrollHandler({noWheelClassName:fr,preventScrolling:ur,d3ZoomHandler:Ut});if(Ft.on("wheel.zoom",Ir,{passive:!1}),!vr){const Mr=createPanZoomStartHandler({zoomPanValues:At,onDraggingChange:ct,onPanZoomStart:it});qt.on("start",Mr);const Ar=createPanZoomHandler({zoomPanValues:At,panOnDrag:Er,onPaneContextMenu:!!dr,onPanZoom:at,onTransformChange:Sr});qt.on("zoom",Ar);const Rr=createPanZoomEndHandler({zoomPanValues:At,panOnDrag:Er,panOnScroll:mr,onPaneContextMenu:dr,onPanZoomEnd:ot,onDraggingChange:ct});qt.on("end",Rr)}const kr=createFilter({zoomActivationKeyPressed:or,panOnDrag:Er,zoomOnScroll:yr,panOnScroll:mr,zoomOnDoubleClick:ir,zoomOnPinch:cr,userSelectionActive:vr,noPanClassName:gr,noWheelClassName:fr,lib:hr});qt.filter(kr),ir?Ft.on("dblclick.zoom",Ht):Ft.on("dblclick.zoom",null)}function Gt(){qt.on("zoom",null)}async function Vt(fr,gr,dr){const vr=viewportToTransform(fr),mr=qt==null?void 0:qt.constrain()(vr,gr,dr);return mr&&await zt(mr),new Promise(Er=>Er(mr))}async function Zt(fr,gr){const dr=viewportToTransform(fr);return await zt(dr,gr),new Promise(vr=>vr(dr))}function Xt(fr){if(Ft){const gr=viewportToTransform(fr),dr=Ft.property("__zoom");(dr.k!==fr.zoom||dr.x!==fr.x||dr.y!==fr.y)&&(qt==null||qt.transform(Ft,gr,null,{sync:!0}))}}function Qt(){const fr=Ft?transform$1(Ft.node()):{x:0,y:0,k:1};return{x:fr.x,y:fr.y,zoom:fr.k}}function er(fr,gr){return Ft?new Promise(dr=>{qt==null||qt.scaleTo(getD3Transition(Ft,gr==null?void 0:gr.duration,()=>dr(!0)),fr)}):Promise.resolve(!1)}function nr(fr,gr){return Ft?new Promise(dr=>{qt==null||qt.scaleBy(getD3Transition(Ft,gr==null?void 0:gr.duration,()=>dr(!0)),fr)}):Promise.resolve(!1)}function ar(fr){qt==null||qt.scaleExtent(fr)}function sr(fr){qt==null||qt.translateExtent(fr)}function lr(fr){const gr=!isNumeric(fr)||fr<0?0:fr;qt==null||qt.clickDistance(gr)}return{update:Yt,destroy:Gt,setViewport:Zt,setViewportConstrained:Vt,getViewport:Qt,scaleTo:er,scaleBy:nr,setScaleExtent:ar,setTranslateExtent:sr,syncViewport:Xt,setClickDistance:lr}}var ResizeControlVariant;(function(e){e.Line="line",e.Handle="handle"})(ResizeControlVariant||(ResizeControlVariant={}));function getResizeDirection({width:e,prevWidth:t,height:Ye,prevHeight:tt,affectsX:rt,affectsY:nt}){const at=e-t,it=Ye-tt,ot=[at>0?1:at<0?-1:0,it>0?1:it<0?-1:0];return at&&rt&&(ot[0]=ot[0]*-1),it&&nt&&(ot[1]=ot[1]*-1),ot}function getControlDirection(e){const t=e.includes("right")||e.includes("left"),Ye=e.includes("bottom")||e.includes("top"),tt=e.includes("left"),rt=e.includes("top");return{isHorizontal:t,isVertical:Ye,affectsX:tt,affectsY:rt}}function getLowerExtentClamp(e,t){return Math.max(0,t-e)}function getUpperExtentClamp(e,t){return Math.max(0,e-t)}function getSizeClamp(e,t,Ye){return Math.max(0,t-e,e-Ye)}function xor(e,t){return e?!t:t}function getDimensionsAfterResize(e,t,Ye,tt,rt,nt,at,it){let{affectsX:ot,affectsY:ct}=t;const{isHorizontal:At,isVertical:Rt}=t,qt=At&&Rt,{xSnapped:Ft,ySnapped:Ut}=Ye,{minWidth:Ht,maxWidth:zt,minHeight:Yt,maxHeight:Gt}=tt,{x:Vt,y:Zt,width:Xt,height:Qt,aspectRatio:er}=e;let nr=Math.floor(At?Ft-e.pointerX:0),ar=Math.floor(Rt?Ut-e.pointerY:0);const sr=Xt+(ot?-nr:nr),lr=Qt+(ct?-ar:ar),fr=-nt[0]*Xt,gr=-nt[1]*Qt;let dr=getSizeClamp(sr,Ht,zt),vr=getSizeClamp(lr,Yt,Gt);if(at){let _r=0,Tr=0;ot&&nr<0?_r=getLowerExtentClamp(Vt+nr+fr,at[0][0]):!ot&&nr>0&&(_r=getUpperExtentClamp(Vt+sr+fr,at[1][0])),ct&&ar<0?Tr=getLowerExtentClamp(Zt+ar+gr,at[0][1]):!ct&&ar>0&&(Tr=getUpperExtentClamp(Zt+lr+gr,at[1][1])),dr=Math.max(dr,_r),vr=Math.max(vr,Tr)}if(it){let _r=0,Tr=0;ot&&nr>0?_r=getUpperExtentClamp(Vt+nr,it[0][0]):!ot&&nr<0&&(_r=getLowerExtentClamp(Vt+sr,it[1][0])),ct&&ar>0?Tr=getUpperExtentClamp(Zt+ar,it[0][1]):!ct&&ar<0&&(Tr=getLowerExtentClamp(Zt+lr,it[1][1])),dr=Math.max(dr,_r),vr=Math.max(vr,Tr)}if(rt){if(At){const _r=getSizeClamp(sr/er,Yt,Gt)*er;if(dr=Math.max(dr,_r),at){let Tr=0;!ot&&!ct||ot&&!ct&&qt?Tr=getUpperExtentClamp(Zt+gr+sr/er,at[1][1])*er:Tr=getLowerExtentClamp(Zt+gr+(ot?nr:-nr)/er,at[0][1])*er,dr=Math.max(dr,Tr)}if(it){let Tr=0;!ot&&!ct||ot&&!ct&&qt?Tr=getLowerExtentClamp(Zt+sr/er,it[1][1])*er:Tr=getUpperExtentClamp(Zt+(ot?nr:-nr)/er,it[0][1])*er,dr=Math.max(dr,Tr)}}if(Rt){const _r=getSizeClamp(lr*er,Ht,zt)/er;if(vr=Math.max(vr,_r),at){let Tr=0;!ot&&!ct||ct&&!ot&&qt?Tr=getUpperExtentClamp(Vt+lr*er+fr,at[1][0])/er:Tr=getLowerExtentClamp(Vt+(ct?ar:-ar)*er+fr,at[0][0])/er,vr=Math.max(vr,Tr)}if(it){let Tr=0;!ot&&!ct||ct&&!ot&&qt?Tr=getLowerExtentClamp(Vt+lr*er,it[1][0])/er:Tr=getUpperExtentClamp(Vt+(ct?ar:-ar)*er,it[0][0])/er,vr=Math.max(vr,Tr)}}}ar=ar+(ar<0?vr:-vr),nr=nr+(nr<0?dr:-dr),rt&&(qt?sr>lr*er?ar=(xor(ot,ct)?-nr:nr)/er:nr=(xor(ot,ct)?-ar:ar)*er:At?(ar=nr/er,ct=ot):(nr=ar*er,ot=ct));const mr=ot?Vt+nr:Vt,Er=ct?Zt+ar:Zt;return{width:Xt+(ot?-nr:nr),height:Qt+(ct?-ar:ar),x:nt[0]*nr*(ot?-1:1)+mr,y:nt[1]*ar*(ct?-1:1)+Er}}const initPrevValues$1={width:0,height:0,x:0,y:0},initStartValues={...initPrevValues$1,pointerX:0,pointerY:0,aspectRatio:1};function nodeToParentExtent(e){return[[0,0],[e.measured.width,e.measured.height]]}function nodeToChildExtent(e,t,Ye){const tt=t.position.x+e.position.x,rt=t.position.y+e.position.y,nt=e.measured.width??0,at=e.measured.height??0,it=Ye[0]*nt,ot=Ye[1]*at;return[[tt-it,rt-ot],[tt+nt-it,rt+at-ot]]}function XYResizer({domNode:e,nodeId:t,getStoreItems:Ye,onChange:tt,onEnd:rt}){const nt=select(e);function at({controlPosition:ot,boundaries:ct,keepAspectRatio:At,resizeDirection:Rt,onResizeStart:qt,onResize:Ft,onResizeEnd:Ut,shouldResize:Ht}){let zt={...initPrevValues$1},Yt={...initStartValues};const Gt=getControlDirection(ot);let Vt,Zt=null,Xt=[],Qt,er,nr;const ar=drag().on("start",sr=>{const{nodeLookup:lr,transform:fr,snapGrid:gr,snapToGrid:dr,nodeOrigin:vr,paneDomNode:mr}=Ye();if(Vt=lr.get(t),!Vt)return;Zt=(mr==null?void 0:mr.getBoundingClientRect())??null;const{xSnapped:Er,ySnapped:_r}=getPointerPosition(sr.sourceEvent,{transform:fr,snapGrid:gr,snapToGrid:dr,containerBounds:Zt});zt={width:Vt.measured.width??0,height:Vt.measured.height??0,x:Vt.position.x??0,y:Vt.position.y??0},Yt={...zt,pointerX:Er,pointerY:_r,aspectRatio:zt.width/zt.height},Qt=void 0,Vt.parentId&&(Vt.extent==="parent"||Vt.expandParent)&&(Qt=lr.get(Vt.parentId),er=Qt&&Vt.extent==="parent"?nodeToParentExtent(Qt):void 0),Xt=[],nr=void 0;for(const[Tr,ur]of lr)if(ur.parentId===t&&(Xt.push({id:Tr,position:{...ur.position},extent:ur.extent}),ur.extent==="parent"||ur.expandParent)){const cr=nodeToChildExtent(ur,Vt,ur.origin??vr);nr?nr=[[Math.min(cr[0][0],nr[0][0]),Math.min(cr[0][1],nr[0][1])],[Math.max(cr[1][0],nr[1][0]),Math.max(cr[1][1],nr[1][1])]]:nr=cr}qt==null||qt(sr,{...zt})}).on("drag",sr=>{const{transform:lr,snapGrid:fr,snapToGrid:gr,nodeOrigin:dr}=Ye(),vr=getPointerPosition(sr.sourceEvent,{transform:lr,snapGrid:fr,snapToGrid:gr,containerBounds:Zt}),mr=[];if(!Vt)return;const{x:Er,y:_r,width:Tr,height:ur}=zt,cr={},yr=Vt.origin??dr,{width:ir,height:or,x:hr,y:Sr}=getDimensionsAfterResize(Yt,Gt,vr,ct,At,yr,er,nr),wr=ir!==Tr,Ir=or!==ur,kr=hr!==Er&&wr,Mr=Sr!==_r&&Ir;if(!kr&&!Mr&&!wr&&!Ir)return;if((kr||Mr||yr[0]===1||yr[1]===1)&&(cr.x=kr?hr:zt.x,cr.y=Mr?Sr:zt.y,zt.x=cr.x,zt.y=cr.y,Xt.length>0)){const Lr=hr-Er,Ur=Sr-_r;for(const Wr of Xt)Wr.position={x:Wr.position.x-Lr+yr[0]*(ir-Tr),y:Wr.position.y-Ur+yr[1]*(or-ur)},mr.push(Wr)}if((wr||Ir)&&(cr.width=wr&&(!Rt||Rt==="horizontal")?ir:zt.width,cr.height=Ir&&(!Rt||Rt==="vertical")?or:zt.height,zt.width=cr.width,zt.height=cr.height),Qt&&Vt.expandParent){const Lr=yr[0]*(cr.width??0);cr.x&&cr.x<Lr&&(zt.x=Lr,Yt.x=Yt.x-(cr.x-Lr));const Ur=yr[1]*(cr.height??0);cr.y&&cr.y<Ur&&(zt.y=Ur,Yt.y=Yt.y-(cr.y-Ur))}const Ar=getResizeDirection({width:zt.width,prevWidth:Tr,height:zt.height,prevHeight:ur,affectsX:Gt.affectsX,affectsY:Gt.affectsY}),Rr={...zt,direction:Ar};(Ht==null?void 0:Ht(sr,Rr))!==!1&&(Ft==null||Ft(sr,Rr),tt(cr,mr))}).on("end",sr=>{Ut==null||Ut(sr,{...zt}),rt==null||rt({...zt})});nt.call(ar)}function it(){nt.on(".drag",null)}return{update:at,destroy:it}}var withSelector={exports:{}},withSelector_production={},shim={exports:{}},useSyncExternalStoreShim_production={};/**
815
815
  * @license React
816
816
  * use-sync-external-store-shim.production.js
817
817
  *
@@ -893,7 +893,7 @@ ${lr}`}return nr.codeframe&&(sr+=`
893
893
  || ${nr} === "boolean" || ${Qt} === null`).assign(ar,(0,tt._)`[${Qt}]`)}}}function qt({gen:Gt,parentData:Vt,parentDataProperty:Zt},Xt){Gt.if((0,tt._)`${Vt} !== undefined`,()=>Gt.assign((0,tt._)`${Vt}[${Zt}]`,Xt))}function Ft(Gt,Vt,Zt,Xt=nt.Correct){const Qt=Xt===nt.Correct?tt.operators.EQ:tt.operators.NEQ;let er;switch(Gt){case"null":return(0,tt._)`${Vt} ${Qt} null`;case"array":er=(0,tt._)`Array.isArray(${Vt})`;break;case"object":er=(0,tt._)`${Vt} && typeof ${Vt} == "object" && !Array.isArray(${Vt})`;break;case"integer":er=nr((0,tt._)`!(${Vt} % 1) && !isNaN(${Vt})`);break;case"number":er=nr();break;default:return(0,tt._)`typeof ${Vt} ${Qt} ${Gt}`}return Xt===nt.Correct?er:(0,tt.not)(er);function nr(ar=tt.nil){return(0,tt.and)((0,tt._)`typeof ${Vt} == "number"`,ar,Zt?(0,tt._)`isFinite(${Vt})`:tt.nil)}}dataType.checkDataType=Ft;function Ut(Gt,Vt,Zt,Xt){if(Gt.length===1)return Ft(Gt[0],Vt,Zt,Xt);let Qt;const er=(0,rt.toHash)(Gt);if(er.array&&er.object){const nr=(0,tt._)`typeof ${Vt} != "object"`;Qt=er.null?nr:(0,tt._)`!${Vt} || ${nr}`,delete er.null,delete er.array,delete er.object}else Qt=tt.nil;er.number&&delete er.integer;for(const nr in er)Qt=(0,tt.and)(Qt,Ft(nr,Vt,Zt,Xt));return Qt}dataType.checkDataTypes=Ut;const Ht={message:({schema:Gt})=>`must be ${Gt}`,params:({schema:Gt,schemaValue:Vt})=>typeof Gt=="string"?(0,tt._)`{type: ${Gt}}`:(0,tt._)`{type: ${Vt}}`};function zt(Gt){const Vt=Yt(Gt);(0,Ye.reportError)(Vt,Ht)}dataType.reportTypeError=zt;function Yt(Gt){const{gen:Vt,data:Zt,schema:Xt}=Gt,Qt=(0,rt.schemaRefOrVal)(Gt,Xt,"type");return{gen:Vt,keyword:"type",data:Zt,schema:Xt.type,schemaCode:Qt,schemaValue:Qt,parentSchema:Xt,params:{},it:Gt}}return dataType}var defaults={},hasRequiredDefaults;function requireDefaults(){if(hasRequiredDefaults)return defaults;hasRequiredDefaults=1,Object.defineProperty(defaults,"__esModule",{value:!0}),defaults.assignDefaults=void 0;const e=requireCodegen(),t=requireUtil();function Ye(rt,nt){const{properties:at,items:it}=rt.schema;if(nt==="object"&&at)for(const ot in at)tt(rt,ot,at[ot].default);else nt==="array"&&Array.isArray(it)&&it.forEach((ot,ct)=>tt(rt,ct,ot.default))}defaults.assignDefaults=Ye;function tt(rt,nt,at){const{gen:it,compositeRule:ot,data:ct,opts:At}=rt;if(at===void 0)return;const Rt=(0,e._)`${ct}${(0,e.getProperty)(nt)}`;if(ot){(0,t.checkStrictMode)(rt,`default is ignored for: ${Rt}`);return}let qt=(0,e._)`${Rt} === undefined`;At.useDefaults==="empty"&&(qt=(0,e._)`${qt} || ${Rt} === null || ${Rt} === ""`),it.if(qt,(0,e._)`${Rt} = ${(0,e.stringify)(at)}`)}return defaults}var keyword={},code={},hasRequiredCode;function requireCode(){if(hasRequiredCode)return code;hasRequiredCode=1,Object.defineProperty(code,"__esModule",{value:!0}),code.validateUnion=code.validateArray=code.usePattern=code.callValidateCode=code.schemaProperties=code.allSchemaProperties=code.noPropertyInData=code.propertyInData=code.isOwnProperty=code.hasPropFunc=code.reportMissingProp=code.checkMissingProp=code.checkReportMissingProp=void 0;const e=requireCodegen(),t=requireUtil(),Ye=requireNames(),tt=requireUtil();function rt(Gt,Vt){const{gen:Zt,data:Xt,it:Qt}=Gt;Zt.if(At(Zt,Xt,Vt,Qt.opts.ownProperties),()=>{Gt.setParams({missingProperty:(0,e._)`${Vt}`},!0),Gt.error()})}code.checkReportMissingProp=rt;function nt({gen:Gt,data:Vt,it:{opts:Zt}},Xt,Qt){return(0,e.or)(...Xt.map(er=>(0,e.and)(At(Gt,Vt,er,Zt.ownProperties),(0,e._)`${Qt} = ${er}`)))}code.checkMissingProp=nt;function at(Gt,Vt){Gt.setParams({missingProperty:Vt},!0),Gt.error()}code.reportMissingProp=at;function it(Gt){return Gt.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,e._)`Object.prototype.hasOwnProperty`})}code.hasPropFunc=it;function ot(Gt,Vt,Zt){return(0,e._)`${it(Gt)}.call(${Vt}, ${Zt})`}code.isOwnProperty=ot;function ct(Gt,Vt,Zt,Xt){const Qt=(0,e._)`${Vt}${(0,e.getProperty)(Zt)} !== undefined`;return Xt?(0,e._)`${Qt} && ${ot(Gt,Vt,Zt)}`:Qt}code.propertyInData=ct;function At(Gt,Vt,Zt,Xt){const Qt=(0,e._)`${Vt}${(0,e.getProperty)(Zt)} === undefined`;return Xt?(0,e.or)(Qt,(0,e.not)(ot(Gt,Vt,Zt))):Qt}code.noPropertyInData=At;function Rt(Gt){return Gt?Object.keys(Gt).filter(Vt=>Vt!=="__proto__"):[]}code.allSchemaProperties=Rt;function qt(Gt,Vt){return Rt(Vt).filter(Zt=>!(0,t.alwaysValidSchema)(Gt,Vt[Zt]))}code.schemaProperties=qt;function Ft({schemaCode:Gt,data:Vt,it:{gen:Zt,topSchemaRef:Xt,schemaPath:Qt,errorPath:er},it:nr},ar,sr,lr){const fr=lr?(0,e._)`${Gt}, ${Vt}, ${Xt}${Qt}`:Vt,gr=[[Ye.default.instancePath,(0,e.strConcat)(Ye.default.instancePath,er)],[Ye.default.parentData,nr.parentData],[Ye.default.parentDataProperty,nr.parentDataProperty],[Ye.default.rootData,Ye.default.rootData]];nr.opts.dynamicRef&&gr.push([Ye.default.dynamicAnchors,Ye.default.dynamicAnchors]);const dr=(0,e._)`${fr}, ${Zt.object(...gr)}`;return sr!==e.nil?(0,e._)`${ar}.call(${sr}, ${dr})`:(0,e._)`${ar}(${dr})`}code.callValidateCode=Ft;const Ut=(0,e._)`new RegExp`;function Ht({gen:Gt,it:{opts:Vt}},Zt){const Xt=Vt.unicodeRegExp?"u":"",{regExp:Qt}=Vt.code,er=Qt(Zt,Xt);return Gt.scopeValue("pattern",{key:er.toString(),ref:er,code:(0,e._)`${Qt.code==="new RegExp"?Ut:(0,tt.useFunc)(Gt,Qt)}(${Zt}, ${Xt})`})}code.usePattern=Ht;function zt(Gt){const{gen:Vt,data:Zt,keyword:Xt,it:Qt}=Gt,er=Vt.name("valid");if(Qt.allErrors){const ar=Vt.let("valid",!0);return nr(()=>Vt.assign(ar,!1)),ar}return Vt.var(er,!0),nr(()=>Vt.break()),er;function nr(ar){const sr=Vt.const("len",(0,e._)`${Zt}.length`);Vt.forRange("i",0,sr,lr=>{Gt.subschema({keyword:Xt,dataProp:lr,dataPropType:t.Type.Num},er),Vt.if((0,e.not)(er),ar)})}}code.validateArray=zt;function Yt(Gt){const{gen:Vt,schema:Zt,keyword:Xt,it:Qt}=Gt;if(!Array.isArray(Zt))throw new Error("ajv implementation error");if(Zt.some(sr=>(0,t.alwaysValidSchema)(Qt,sr))&&!Qt.opts.unevaluated)return;const nr=Vt.let("valid",!1),ar=Vt.name("_valid");Vt.block(()=>Zt.forEach((sr,lr)=>{const fr=Gt.subschema({keyword:Xt,schemaProp:lr,compositeRule:!0},ar);Vt.assign(nr,(0,e._)`${nr} || ${ar}`),Gt.mergeValidEvaluated(fr,ar)||Vt.if((0,e.not)(nr))})),Gt.result(nr,()=>Gt.reset(),()=>Gt.error(!0))}return code.validateUnion=Yt,code}var hasRequiredKeyword;function requireKeyword(){if(hasRequiredKeyword)return keyword;hasRequiredKeyword=1,Object.defineProperty(keyword,"__esModule",{value:!0}),keyword.validateKeywordUsage=keyword.validSchemaType=keyword.funcKeywordCode=keyword.macroKeywordCode=void 0;const e=requireCodegen(),t=requireNames(),Ye=requireCode(),tt=requireErrors();function rt(qt,Ft){const{gen:Ut,keyword:Ht,schema:zt,parentSchema:Yt,it:Gt}=qt,Vt=Ft.macro.call(Gt.self,zt,Yt,Gt),Zt=ct(Ut,Ht,Vt);Gt.opts.validateSchema!==!1&&Gt.self.validateSchema(Vt,!0);const Xt=Ut.name("valid");qt.subschema({schema:Vt,schemaPath:e.nil,errSchemaPath:`${Gt.errSchemaPath}/${Ht}`,topSchemaRef:Zt,compositeRule:!0},Xt),qt.pass(Xt,()=>qt.error(!0))}keyword.macroKeywordCode=rt;function nt(qt,Ft){var Ut;const{gen:Ht,keyword:zt,schema:Yt,parentSchema:Gt,$data:Vt,it:Zt}=qt;ot(Zt,Ft);const Xt=!Vt&&Ft.compile?Ft.compile.call(Zt.self,Yt,Gt,Zt):Ft.validate,Qt=ct(Ht,zt,Xt),er=Ht.let("valid");qt.block$data(er,nr),qt.ok((Ut=Ft.valid)!==null&&Ut!==void 0?Ut:er);function nr(){if(Ft.errors===!1)lr(),Ft.modifying&&at(qt),fr(()=>qt.error());else{const gr=Ft.async?ar():sr();Ft.modifying&&at(qt),fr(()=>it(qt,gr))}}function ar(){const gr=Ht.let("ruleErrs",null);return Ht.try(()=>lr((0,e._)`await `),dr=>Ht.assign(er,!1).if((0,e._)`${dr} instanceof ${Zt.ValidationError}`,()=>Ht.assign(gr,(0,e._)`${dr}.errors`),()=>Ht.throw(dr))),gr}function sr(){const gr=(0,e._)`${Qt}.errors`;return Ht.assign(gr,null),lr(e.nil),gr}function lr(gr=Ft.async?(0,e._)`await `:e.nil){const dr=Zt.opts.passContext?t.default.this:t.default.self,vr=!("compile"in Ft&&!Vt||Ft.schema===!1);Ht.assign(er,(0,e._)`${gr}${(0,Ye.callValidateCode)(qt,Qt,dr,vr)}`,Ft.modifying)}function fr(gr){var dr;Ht.if((0,e.not)((dr=Ft.valid)!==null&&dr!==void 0?dr:er),gr)}}keyword.funcKeywordCode=nt;function at(qt){const{gen:Ft,data:Ut,it:Ht}=qt;Ft.if(Ht.parentData,()=>Ft.assign(Ut,(0,e._)`${Ht.parentData}[${Ht.parentDataProperty}]`))}function it(qt,Ft){const{gen:Ut}=qt;Ut.if((0,e._)`Array.isArray(${Ft})`,()=>{Ut.assign(t.default.vErrors,(0,e._)`${t.default.vErrors} === null ? ${Ft} : ${t.default.vErrors}.concat(${Ft})`).assign(t.default.errors,(0,e._)`${t.default.vErrors}.length`),(0,tt.extendErrors)(qt)},()=>qt.error())}function ot({schemaEnv:qt},Ft){if(Ft.async&&!qt.$async)throw new Error("async keyword in sync schema")}function ct(qt,Ft,Ut){if(Ut===void 0)throw new Error(`keyword "${Ft}" failed to compile`);return qt.scopeValue("keyword",typeof Ut=="function"?{ref:Ut}:{ref:Ut,code:(0,e.stringify)(Ut)})}function At(qt,Ft,Ut=!1){return!Ft.length||Ft.some(Ht=>Ht==="array"?Array.isArray(qt):Ht==="object"?qt&&typeof qt=="object"&&!Array.isArray(qt):typeof qt==Ht||Ut&&typeof qt>"u")}keyword.validSchemaType=At;function Rt({schema:qt,opts:Ft,self:Ut,errSchemaPath:Ht},zt,Yt){if(Array.isArray(zt.keyword)?!zt.keyword.includes(Yt):zt.keyword!==Yt)throw new Error("ajv implementation error");const Gt=zt.dependencies;if(Gt!=null&&Gt.some(Vt=>!Object.prototype.hasOwnProperty.call(qt,Vt)))throw new Error(`parent schema must have dependencies of ${Yt}: ${Gt.join(",")}`);if(zt.validateSchema&&!zt.validateSchema(qt[Yt])){const Zt=`keyword "${Yt}" value is invalid at path "${Ht}": `+Ut.errorsText(zt.validateSchema.errors);if(Ft.validateSchema==="log")Ut.logger.error(Zt);else throw new Error(Zt)}}return keyword.validateKeywordUsage=Rt,keyword}var subschema={},hasRequiredSubschema;function requireSubschema(){if(hasRequiredSubschema)return subschema;hasRequiredSubschema=1,Object.defineProperty(subschema,"__esModule",{value:!0}),subschema.extendSubschemaMode=subschema.extendSubschemaData=subschema.getSubschema=void 0;const e=requireCodegen(),t=requireUtil();function Ye(nt,{keyword:at,schemaProp:it,schema:ot,schemaPath:ct,errSchemaPath:At,topSchemaRef:Rt}){if(at!==void 0&&ot!==void 0)throw new Error('both "keyword" and "schema" passed, only one allowed');if(at!==void 0){const qt=nt.schema[at];return it===void 0?{schema:qt,schemaPath:(0,e._)`${nt.schemaPath}${(0,e.getProperty)(at)}`,errSchemaPath:`${nt.errSchemaPath}/${at}`}:{schema:qt[it],schemaPath:(0,e._)`${nt.schemaPath}${(0,e.getProperty)(at)}${(0,e.getProperty)(it)}`,errSchemaPath:`${nt.errSchemaPath}/${at}/${(0,t.escapeFragment)(it)}`}}if(ot!==void 0){if(ct===void 0||At===void 0||Rt===void 0)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:ot,schemaPath:ct,topSchemaRef:Rt,errSchemaPath:At}}throw new Error('either "keyword" or "schema" must be passed')}subschema.getSubschema=Ye;function tt(nt,at,{dataProp:it,dataPropType:ot,data:ct,dataTypes:At,propertyName:Rt}){if(ct!==void 0&&it!==void 0)throw new Error('both "data" and "dataProp" passed, only one allowed');const{gen:qt}=at;if(it!==void 0){const{errorPath:Ut,dataPathArr:Ht,opts:zt}=at,Yt=qt.let("data",(0,e._)`${at.data}${(0,e.getProperty)(it)}`,!0);Ft(Yt),nt.errorPath=(0,e.str)`${Ut}${(0,t.getErrorPath)(it,ot,zt.jsPropertySyntax)}`,nt.parentDataProperty=(0,e._)`${it}`,nt.dataPathArr=[...Ht,nt.parentDataProperty]}if(ct!==void 0){const Ut=ct instanceof e.Name?ct:qt.let("data",ct,!0);Ft(Ut),Rt!==void 0&&(nt.propertyName=Rt)}At&&(nt.dataTypes=At);function Ft(Ut){nt.data=Ut,nt.dataLevel=at.dataLevel+1,nt.dataTypes=[],at.definedProperties=new Set,nt.parentData=at.data,nt.dataNames=[...at.dataNames,Ut]}}subschema.extendSubschemaData=tt;function rt(nt,{jtdDiscriminator:at,jtdMetadata:it,compositeRule:ot,createErrors:ct,allErrors:At}){ot!==void 0&&(nt.compositeRule=ot),ct!==void 0&&(nt.createErrors=ct),At!==void 0&&(nt.allErrors=At),nt.jtdDiscriminator=at,nt.jtdMetadata=it}return subschema.extendSubschemaMode=rt,subschema}var resolve={},fastDeepEqual,hasRequiredFastDeepEqual;function requireFastDeepEqual(){return hasRequiredFastDeepEqual||(hasRequiredFastDeepEqual=1,fastDeepEqual=function e(t,Ye){if(t===Ye)return!0;if(t&&Ye&&typeof t=="object"&&typeof Ye=="object"){if(t.constructor!==Ye.constructor)return!1;var tt,rt,nt;if(Array.isArray(t)){if(tt=t.length,tt!=Ye.length)return!1;for(rt=tt;rt--!==0;)if(!e(t[rt],Ye[rt]))return!1;return!0}if(t.constructor===RegExp)return t.source===Ye.source&&t.flags===Ye.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===Ye.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===Ye.toString();if(nt=Object.keys(t),tt=nt.length,tt!==Object.keys(Ye).length)return!1;for(rt=tt;rt--!==0;)if(!Object.prototype.hasOwnProperty.call(Ye,nt[rt]))return!1;for(rt=tt;rt--!==0;){var at=nt[rt];if(!e(t[at],Ye[at]))return!1}return!0}return t!==t&&Ye!==Ye}),fastDeepEqual}var jsonSchemaTraverse={exports:{}},hasRequiredJsonSchemaTraverse;function requireJsonSchemaTraverse(){if(hasRequiredJsonSchemaTraverse)return jsonSchemaTraverse.exports;hasRequiredJsonSchemaTraverse=1;var e=jsonSchemaTraverse.exports=function(tt,rt,nt){typeof rt=="function"&&(nt=rt,rt={}),nt=rt.cb||nt;var at=typeof nt=="function"?nt:nt.pre||function(){},it=nt.post||function(){};t(rt,at,it,tt,"",tt)};e.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0},e.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0},e.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0},e.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0};function t(tt,rt,nt,at,it,ot,ct,At,Rt,qt){if(at&&typeof at=="object"&&!Array.isArray(at)){rt(at,it,ot,ct,At,Rt,qt);for(var Ft in at){var Ut=at[Ft];if(Array.isArray(Ut)){if(Ft in e.arrayKeywords)for(var Ht=0;Ht<Ut.length;Ht++)t(tt,rt,nt,Ut[Ht],it+"/"+Ft+"/"+Ht,ot,it,Ft,at,Ht)}else if(Ft in e.propsKeywords){if(Ut&&typeof Ut=="object")for(var zt in Ut)t(tt,rt,nt,Ut[zt],it+"/"+Ft+"/"+Ye(zt),ot,it,Ft,at,zt)}else(Ft in e.keywords||tt.allKeys&&!(Ft in e.skipKeywords))&&t(tt,rt,nt,Ut,it+"/"+Ft,ot,it,Ft,at)}nt(at,it,ot,ct,At,Rt,qt)}}function Ye(tt){return tt.replace(/~/g,"~0").replace(/\//g,"~1")}return jsonSchemaTraverse.exports}var hasRequiredResolve;function requireResolve(){if(hasRequiredResolve)return resolve;hasRequiredResolve=1,Object.defineProperty(resolve,"__esModule",{value:!0}),resolve.getSchemaRefs=resolve.resolveUrl=resolve.normalizeId=resolve._getFullPath=resolve.getFullPath=resolve.inlineRef=void 0;const e=requireUtil(),t=requireFastDeepEqual(),Ye=requireJsonSchemaTraverse(),tt=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function rt(Ht,zt=!0){return typeof Ht=="boolean"?!0:zt===!0?!at(Ht):zt?it(Ht)<=zt:!1}resolve.inlineRef=rt;const nt=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function at(Ht){for(const zt in Ht){if(nt.has(zt))return!0;const Yt=Ht[zt];if(Array.isArray(Yt)&&Yt.some(at)||typeof Yt=="object"&&at(Yt))return!0}return!1}function it(Ht){let zt=0;for(const Yt in Ht){if(Yt==="$ref")return 1/0;if(zt++,!tt.has(Yt)&&(typeof Ht[Yt]=="object"&&(0,e.eachItem)(Ht[Yt],Gt=>zt+=it(Gt)),zt===1/0))return 1/0}return zt}function ot(Ht,zt="",Yt){Yt!==!1&&(zt=Rt(zt));const Gt=Ht.parse(zt);return ct(Ht,Gt)}resolve.getFullPath=ot;function ct(Ht,zt){return Ht.serialize(zt).split("#")[0]+"#"}resolve._getFullPath=ct;const At=/#\/?$/;function Rt(Ht){return Ht?Ht.replace(At,""):""}resolve.normalizeId=Rt;function qt(Ht,zt,Yt){return Yt=Rt(Yt),Ht.resolve(zt,Yt)}resolve.resolveUrl=qt;const Ft=/^[a-z_][-a-z0-9._]*$/i;function Ut(Ht,zt){if(typeof Ht=="boolean")return{};const{schemaId:Yt,uriResolver:Gt}=this.opts,Vt=Rt(Ht[Yt]||zt),Zt={"":Vt},Xt=ot(Gt,Vt,!1),Qt={},er=new Set;return Ye(Ht,{allKeys:!0},(sr,lr,fr,gr)=>{if(gr===void 0)return;const dr=Xt+lr;let vr=Zt[gr];typeof sr[Yt]=="string"&&(vr=mr.call(this,sr[Yt])),Er.call(this,sr.$anchor),Er.call(this,sr.$dynamicAnchor),Zt[lr]=vr;function mr(_r){const Tr=this.opts.uriResolver.resolve;if(_r=Rt(vr?Tr(vr,_r):_r),er.has(_r))throw ar(_r);er.add(_r);let ur=this.refs[_r];return typeof ur=="string"&&(ur=this.refs[ur]),typeof ur=="object"?nr(sr,ur.schema,_r):_r!==Rt(dr)&&(_r[0]==="#"?(nr(sr,Qt[_r],_r),Qt[_r]=sr):this.refs[_r]=dr),_r}function Er(_r){if(typeof _r=="string"){if(!Ft.test(_r))throw new Error(`invalid anchor "${_r}"`);mr.call(this,`#${_r}`)}}}),Qt;function nr(sr,lr,fr){if(lr!==void 0&&!t(sr,lr))throw ar(fr)}function ar(sr){return new Error(`reference "${sr}" resolves to more than one schema`)}}return resolve.getSchemaRefs=Ut,resolve}var hasRequiredValidate;function requireValidate(){if(hasRequiredValidate)return validate;hasRequiredValidate=1,Object.defineProperty(validate,"__esModule",{value:!0}),validate.getData=validate.KeywordCxt=validate.validateFunctionCode=void 0;const e=requireBoolSchema(),t=requireDataType(),Ye=requireApplicability(),tt=requireDataType(),rt=requireDefaults(),nt=requireKeyword(),at=requireSubschema(),it=requireCodegen(),ot=requireNames(),ct=requireResolve(),At=requireUtil(),Rt=requireErrors();function qt(Ar){if(Xt(Ar)&&(er(Ar),Zt(Ar))){zt(Ar);return}Ft(Ar,()=>(0,e.topBoolOrEmptySchema)(Ar))}validate.validateFunctionCode=qt;function Ft({gen:Ar,validateName:Rr,schema:Dr,schemaEnv:Lr,opts:Ur},Wr){Ur.code.es5?Ar.func(Rr,(0,it._)`${ot.default.data}, ${ot.default.valCxt}`,Lr.$async,()=>{Ar.code((0,it._)`"use strict"; ${Gt(Dr,Ur)}`),Ht(Ar,Ur),Ar.code(Wr)}):Ar.func(Rr,(0,it._)`${ot.default.data}, ${Ut(Ur)}`,Lr.$async,()=>Ar.code(Gt(Dr,Ur)).code(Wr))}function Ut(Ar){return(0,it._)`{${ot.default.instancePath}="", ${ot.default.parentData}, ${ot.default.parentDataProperty}, ${ot.default.rootData}=${ot.default.data}${Ar.dynamicRef?(0,it._)`, ${ot.default.dynamicAnchors}={}`:it.nil}}={}`}function Ht(Ar,Rr){Ar.if(ot.default.valCxt,()=>{Ar.var(ot.default.instancePath,(0,it._)`${ot.default.valCxt}.${ot.default.instancePath}`),Ar.var(ot.default.parentData,(0,it._)`${ot.default.valCxt}.${ot.default.parentData}`),Ar.var(ot.default.parentDataProperty,(0,it._)`${ot.default.valCxt}.${ot.default.parentDataProperty}`),Ar.var(ot.default.rootData,(0,it._)`${ot.default.valCxt}.${ot.default.rootData}`),Rr.dynamicRef&&Ar.var(ot.default.dynamicAnchors,(0,it._)`${ot.default.valCxt}.${ot.default.dynamicAnchors}`)},()=>{Ar.var(ot.default.instancePath,(0,it._)`""`),Ar.var(ot.default.parentData,(0,it._)`undefined`),Ar.var(ot.default.parentDataProperty,(0,it._)`undefined`),Ar.var(ot.default.rootData,ot.default.data),Rr.dynamicRef&&Ar.var(ot.default.dynamicAnchors,(0,it._)`{}`)})}function zt(Ar){const{schema:Rr,opts:Dr,gen:Lr}=Ar;Ft(Ar,()=>{Dr.$comment&&Rr.$comment&&gr(Ar),sr(Ar),Lr.let(ot.default.vErrors,null),Lr.let(ot.default.errors,0),Dr.unevaluated&&Yt(Ar),nr(Ar),dr(Ar)})}function Yt(Ar){const{gen:Rr,validateName:Dr}=Ar;Ar.evaluated=Rr.const("evaluated",(0,it._)`${Dr}.evaluated`),Rr.if((0,it._)`${Ar.evaluated}.dynamicProps`,()=>Rr.assign((0,it._)`${Ar.evaluated}.props`,(0,it._)`undefined`)),Rr.if((0,it._)`${Ar.evaluated}.dynamicItems`,()=>Rr.assign((0,it._)`${Ar.evaluated}.items`,(0,it._)`undefined`))}function Gt(Ar,Rr){const Dr=typeof Ar=="object"&&Ar[Rr.schemaId];return Dr&&(Rr.code.source||Rr.code.process)?(0,it._)`/*# sourceURL=${Dr} */`:it.nil}function Vt(Ar,Rr){if(Xt(Ar)&&(er(Ar),Zt(Ar))){Qt(Ar,Rr);return}(0,e.boolOrEmptySchema)(Ar,Rr)}function Zt({schema:Ar,self:Rr}){if(typeof Ar=="boolean")return!Ar;for(const Dr in Ar)if(Rr.RULES.all[Dr])return!0;return!1}function Xt(Ar){return typeof Ar.schema!="boolean"}function Qt(Ar,Rr){const{schema:Dr,gen:Lr,opts:Ur}=Ar;Ur.$comment&&Dr.$comment&&gr(Ar),lr(Ar),fr(Ar);const Wr=Lr.const("_errs",ot.default.errors);nr(Ar,Wr),Lr.var(Rr,(0,it._)`${Wr} === ${ot.default.errors}`)}function er(Ar){(0,At.checkUnknownRules)(Ar),ar(Ar)}function nr(Ar,Rr){if(Ar.opts.jtd)return mr(Ar,[],!1,Rr);const Dr=(0,t.getSchemaTypes)(Ar.schema),Lr=(0,t.coerceAndCheckDataType)(Ar,Dr);mr(Ar,Dr,!Lr,Rr)}function ar(Ar){const{schema:Rr,errSchemaPath:Dr,opts:Lr,self:Ur}=Ar;Rr.$ref&&Lr.ignoreKeywordsWithRef&&(0,At.schemaHasRulesButRef)(Rr,Ur.RULES)&&Ur.logger.warn(`$ref: keywords ignored in schema at path "${Dr}"`)}function sr(Ar){const{schema:Rr,opts:Dr}=Ar;Rr.default!==void 0&&Dr.useDefaults&&Dr.strictSchema&&(0,At.checkStrictMode)(Ar,"default is ignored in the schema root")}function lr(Ar){const Rr=Ar.schema[Ar.opts.schemaId];Rr&&(Ar.baseId=(0,ct.resolveUrl)(Ar.opts.uriResolver,Ar.baseId,Rr))}function fr(Ar){if(Ar.schema.$async&&!Ar.schemaEnv.$async)throw new Error("async schema in sync schema")}function gr({gen:Ar,schemaEnv:Rr,schema:Dr,errSchemaPath:Lr,opts:Ur}){const Wr=Dr.$comment;if(Ur.$comment===!0)Ar.code((0,it._)`${ot.default.self}.logger.log(${Wr})`);else if(typeof Ur.$comment=="function"){const Kr=(0,it.str)`${Lr}/$comment`,nn=Ar.scopeValue("root",{ref:Rr.root});Ar.code((0,it._)`${ot.default.self}.opts.$comment(${Wr}, ${Kr}, ${nn}.schema)`)}}function dr(Ar){const{gen:Rr,schemaEnv:Dr,validateName:Lr,ValidationError:Ur,opts:Wr}=Ar;Dr.$async?Rr.if((0,it._)`${ot.default.errors} === 0`,()=>Rr.return(ot.default.data),()=>Rr.throw((0,it._)`new ${Ur}(${ot.default.vErrors})`)):(Rr.assign((0,it._)`${Lr}.errors`,ot.default.vErrors),Wr.unevaluated&&vr(Ar),Rr.return((0,it._)`${ot.default.errors} === 0`))}function vr({gen:Ar,evaluated:Rr,props:Dr,items:Lr}){Dr instanceof it.Name&&Ar.assign((0,it._)`${Rr}.props`,Dr),Lr instanceof it.Name&&Ar.assign((0,it._)`${Rr}.items`,Lr)}function mr(Ar,Rr,Dr,Lr){const{gen:Ur,schema:Wr,data:Kr,allErrors:nn,opts:Jr,self:un}=Ar,{RULES:pn}=un;if(Wr.$ref&&(Jr.ignoreKeywordsWithRef||!(0,At.schemaHasRulesButRef)(Wr,pn))){Ur.block(()=>wr(Ar,"$ref",pn.all.$ref.definition));return}Jr.jtd||_r(Ar,Rr),Ur.block(()=>{for(const rn of pn.rules)Zr(rn);Zr(pn.post)});function Zr(rn){(0,Ye.shouldUseGroup)(Wr,rn)&&(rn.type?(Ur.if((0,tt.checkDataType)(rn.type,Kr,Jr.strictNumbers)),Er(Ar,rn),Rr.length===1&&Rr[0]===rn.type&&Dr&&(Ur.else(),(0,tt.reportTypeError)(Ar)),Ur.endIf()):Er(Ar,rn),nn||Ur.if((0,it._)`${ot.default.errors} === ${Lr||0}`))}}function Er(Ar,Rr){const{gen:Dr,schema:Lr,opts:{useDefaults:Ur}}=Ar;Ur&&(0,rt.assignDefaults)(Ar,Rr.type),Dr.block(()=>{for(const Wr of Rr.rules)(0,Ye.shouldUseRule)(Lr,Wr)&&wr(Ar,Wr.keyword,Wr.definition,Rr.type)})}function _r(Ar,Rr){Ar.schemaEnv.meta||!Ar.opts.strictTypes||(Tr(Ar,Rr),Ar.opts.allowUnionTypes||ur(Ar,Rr),cr(Ar,Ar.dataTypes))}function Tr(Ar,Rr){if(Rr.length){if(!Ar.dataTypes.length){Ar.dataTypes=Rr;return}Rr.forEach(Dr=>{ir(Ar.dataTypes,Dr)||hr(Ar,`type "${Dr}" not allowed by context "${Ar.dataTypes.join(",")}"`)}),or(Ar,Rr)}}function ur(Ar,Rr){Rr.length>1&&!(Rr.length===2&&Rr.includes("null"))&&hr(Ar,"use allowUnionTypes to allow union type keyword")}function cr(Ar,Rr){const Dr=Ar.self.RULES.all;for(const Lr in Dr){const Ur=Dr[Lr];if(typeof Ur=="object"&&(0,Ye.shouldUseRule)(Ar.schema,Ur)){const{type:Wr}=Ur.definition;Wr.length&&!Wr.some(Kr=>yr(Rr,Kr))&&hr(Ar,`missing type "${Wr.join(",")}" for keyword "${Lr}"`)}}}function yr(Ar,Rr){return Ar.includes(Rr)||Rr==="number"&&Ar.includes("integer")}function ir(Ar,Rr){return Ar.includes(Rr)||Rr==="integer"&&Ar.includes("number")}function or(Ar,Rr){const Dr=[];for(const Lr of Ar.dataTypes)ir(Rr,Lr)?Dr.push(Lr):Rr.includes("integer")&&Lr==="number"&&Dr.push("integer");Ar.dataTypes=Dr}function hr(Ar,Rr){const Dr=Ar.schemaEnv.baseId+Ar.errSchemaPath;Rr+=` at "${Dr}" (strictTypes)`,(0,At.checkStrictMode)(Ar,Rr,Ar.opts.strictTypes)}class Sr{constructor(Rr,Dr,Lr){if((0,nt.validateKeywordUsage)(Rr,Dr,Lr),this.gen=Rr.gen,this.allErrors=Rr.allErrors,this.keyword=Lr,this.data=Rr.data,this.schema=Rr.schema[Lr],this.$data=Dr.$data&&Rr.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,At.schemaRefOrVal)(Rr,this.schema,Lr,this.$data),this.schemaType=Dr.schemaType,this.parentSchema=Rr.schema,this.params={},this.it=Rr,this.def=Dr,this.$data)this.schemaCode=Rr.gen.const("vSchema",Mr(this.$data,Rr));else if(this.schemaCode=this.schemaValue,!(0,nt.validSchemaType)(this.schema,Dr.schemaType,Dr.allowUndefined))throw new Error(`${Lr} value must be ${JSON.stringify(Dr.schemaType)}`);("code"in Dr?Dr.trackErrors:Dr.errors!==!1)&&(this.errsCount=Rr.gen.const("_errs",ot.default.errors))}result(Rr,Dr,Lr){this.failResult((0,it.not)(Rr),Dr,Lr)}failResult(Rr,Dr,Lr){this.gen.if(Rr),Lr?Lr():this.error(),Dr?(this.gen.else(),Dr(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(Rr,Dr){this.failResult((0,it.not)(Rr),void 0,Dr)}fail(Rr){if(Rr===void 0){this.error(),this.allErrors||this.gen.if(!1);return}this.gen.if(Rr),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(Rr){if(!this.$data)return this.fail(Rr);const{schemaCode:Dr}=this;this.fail((0,it._)`${Dr} !== undefined && (${(0,it.or)(this.invalid$data(),Rr)})`)}error(Rr,Dr,Lr){if(Dr){this.setParams(Dr),this._error(Rr,Lr),this.setParams({});return}this._error(Rr,Lr)}_error(Rr,Dr){(Rr?Rt.reportExtraError:Rt.reportError)(this,this.def.error,Dr)}$dataError(){(0,Rt.reportError)(this,this.def.$dataError||Rt.keyword$DataError)}reset(){if(this.errsCount===void 0)throw new Error('add "trackErrors" to keyword definition');(0,Rt.resetErrorsCount)(this.gen,this.errsCount)}ok(Rr){this.allErrors||this.gen.if(Rr)}setParams(Rr,Dr){Dr?Object.assign(this.params,Rr):this.params=Rr}block$data(Rr,Dr,Lr=it.nil){this.gen.block(()=>{this.check$data(Rr,Lr),Dr()})}check$data(Rr=it.nil,Dr=it.nil){if(!this.$data)return;const{gen:Lr,schemaCode:Ur,schemaType:Wr,def:Kr}=this;Lr.if((0,it.or)((0,it._)`${Ur} === undefined`,Dr)),Rr!==it.nil&&Lr.assign(Rr,!0),(Wr.length||Kr.validateSchema)&&(Lr.elseIf(this.invalid$data()),this.$dataError(),Rr!==it.nil&&Lr.assign(Rr,!1)),Lr.else()}invalid$data(){const{gen:Rr,schemaCode:Dr,schemaType:Lr,def:Ur,it:Wr}=this;return(0,it.or)(Kr(),nn());function Kr(){if(Lr.length){if(!(Dr instanceof it.Name))throw new Error("ajv implementation error");const Jr=Array.isArray(Lr)?Lr:[Lr];return(0,it._)`${(0,tt.checkDataTypes)(Jr,Dr,Wr.opts.strictNumbers,tt.DataType.Wrong)}`}return it.nil}function nn(){if(Ur.validateSchema){const Jr=Rr.scopeValue("validate$data",{ref:Ur.validateSchema});return(0,it._)`!${Jr}(${Dr})`}return it.nil}}subschema(Rr,Dr){const Lr=(0,at.getSubschema)(this.it,Rr);(0,at.extendSubschemaData)(Lr,this.it,Rr),(0,at.extendSubschemaMode)(Lr,Rr);const Ur={...this.it,...Lr,items:void 0,props:void 0};return Vt(Ur,Dr),Ur}mergeEvaluated(Rr,Dr){const{it:Lr,gen:Ur}=this;Lr.opts.unevaluated&&(Lr.props!==!0&&Rr.props!==void 0&&(Lr.props=At.mergeEvaluated.props(Ur,Rr.props,Lr.props,Dr)),Lr.items!==!0&&Rr.items!==void 0&&(Lr.items=At.mergeEvaluated.items(Ur,Rr.items,Lr.items,Dr)))}mergeValidEvaluated(Rr,Dr){const{it:Lr,gen:Ur}=this;if(Lr.opts.unevaluated&&(Lr.props!==!0||Lr.items!==!0))return Ur.if(Dr,()=>this.mergeEvaluated(Rr,it.Name)),!0}}validate.KeywordCxt=Sr;function wr(Ar,Rr,Dr,Lr){const Ur=new Sr(Ar,Dr,Rr);"code"in Dr?Dr.code(Ur,Lr):Ur.$data&&Dr.validate?(0,nt.funcKeywordCode)(Ur,Dr):"macro"in Dr?(0,nt.macroKeywordCode)(Ur,Dr):(Dr.compile||Dr.validate)&&(0,nt.funcKeywordCode)(Ur,Dr)}const Ir=/^\/(?:[^~]|~0|~1)*$/,kr=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function Mr(Ar,{dataLevel:Rr,dataNames:Dr,dataPathArr:Lr}){let Ur,Wr;if(Ar==="")return ot.default.rootData;if(Ar[0]==="/"){if(!Ir.test(Ar))throw new Error(`Invalid JSON-pointer: ${Ar}`);Ur=Ar,Wr=ot.default.rootData}else{const un=kr.exec(Ar);if(!un)throw new Error(`Invalid JSON-pointer: ${Ar}`);const pn=+un[1];if(Ur=un[2],Ur==="#"){if(pn>=Rr)throw new Error(Jr("property/index",pn));return Lr[Rr-pn]}if(pn>Rr)throw new Error(Jr("data",pn));if(Wr=Dr[Rr-pn],!Ur)return Wr}let Kr=Wr;const nn=Ur.split("/");for(const un of nn)un&&(Wr=(0,it._)`${Wr}${(0,it.getProperty)((0,At.unescapeJsonPointer)(un))}`,Kr=(0,it._)`${Kr} && ${Wr}`);return Kr;function Jr(un,pn){return`Cannot access ${un} ${pn} levels up, current level is ${Rr}`}}return validate.getData=Mr,validate}var validation_error={},hasRequiredValidation_error;function requireValidation_error(){if(hasRequiredValidation_error)return validation_error;hasRequiredValidation_error=1,Object.defineProperty(validation_error,"__esModule",{value:!0});class e extends Error{constructor(Ye){super("validation failed"),this.errors=Ye,this.ajv=this.validation=!0}}return validation_error.default=e,validation_error}var ref_error={},hasRequiredRef_error;function requireRef_error(){if(hasRequiredRef_error)return ref_error;hasRequiredRef_error=1,Object.defineProperty(ref_error,"__esModule",{value:!0});const e=requireResolve();class t extends Error{constructor(tt,rt,nt,at){super(at||`can't resolve reference ${nt} from id ${rt}`),this.missingRef=(0,e.resolveUrl)(tt,rt,nt),this.missingSchema=(0,e.normalizeId)((0,e.getFullPath)(tt,this.missingRef))}}return ref_error.default=t,ref_error}var compile={},hasRequiredCompile;function requireCompile(){if(hasRequiredCompile)return compile;hasRequiredCompile=1,Object.defineProperty(compile,"__esModule",{value:!0}),compile.resolveSchema=compile.getCompilingSchema=compile.resolveRef=compile.compileSchema=compile.SchemaEnv=void 0;const e=requireCodegen(),t=requireValidation_error(),Ye=requireNames(),tt=requireResolve(),rt=requireUtil(),nt=requireValidate();class at{constructor(Yt){var Gt;this.refs={},this.dynamicAnchors={};let Vt;typeof Yt.schema=="object"&&(Vt=Yt.schema),this.schema=Yt.schema,this.schemaId=Yt.schemaId,this.root=Yt.root||this,this.baseId=(Gt=Yt.baseId)!==null&&Gt!==void 0?Gt:(0,tt.normalizeId)(Vt==null?void 0:Vt[Yt.schemaId||"$id"]),this.schemaPath=Yt.schemaPath,this.localRefs=Yt.localRefs,this.meta=Yt.meta,this.$async=Vt==null?void 0:Vt.$async,this.refs={}}}compile.SchemaEnv=at;function it(zt){const Yt=At.call(this,zt);if(Yt)return Yt;const Gt=(0,tt.getFullPath)(this.opts.uriResolver,zt.root.baseId),{es5:Vt,lines:Zt}=this.opts.code,{ownProperties:Xt}=this.opts,Qt=new e.CodeGen(this.scope,{es5:Vt,lines:Zt,ownProperties:Xt});let er;zt.$async&&(er=Qt.scopeValue("Error",{ref:t.default,code:(0,e._)`require("ajv/dist/runtime/validation_error").default`}));const nr=Qt.scopeName("validate");zt.validateName=nr;const ar={gen:Qt,allErrors:this.opts.allErrors,data:Ye.default.data,parentData:Ye.default.parentData,parentDataProperty:Ye.default.parentDataProperty,dataNames:[Ye.default.data],dataPathArr:[e.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:Qt.scopeValue("schema",this.opts.code.source===!0?{ref:zt.schema,code:(0,e.stringify)(zt.schema)}:{ref:zt.schema}),validateName:nr,ValidationError:er,schema:zt.schema,schemaEnv:zt,rootId:Gt,baseId:zt.baseId||Gt,schemaPath:e.nil,errSchemaPath:zt.schemaPath||(this.opts.jtd?"":"#"),errorPath:(0,e._)`""`,opts:this.opts,self:this};let sr;try{this._compilations.add(zt),(0,nt.validateFunctionCode)(ar),Qt.optimize(this.opts.code.optimize);const lr=Qt.toString();sr=`${Qt.scopeRefs(Ye.default.scope)}return ${lr}`,this.opts.code.process&&(sr=this.opts.code.process(sr,zt));const gr=new Function(`${Ye.default.self}`,`${Ye.default.scope}`,sr)(this,this.scope.get());if(this.scope.value(nr,{ref:gr}),gr.errors=null,gr.schema=zt.schema,gr.schemaEnv=zt,zt.$async&&(gr.$async=!0),this.opts.code.source===!0&&(gr.source={validateName:nr,validateCode:lr,scopeValues:Qt._values}),this.opts.unevaluated){const{props:dr,items:vr}=ar;gr.evaluated={props:dr instanceof e.Name?void 0:dr,items:vr instanceof e.Name?void 0:vr,dynamicProps:dr instanceof e.Name,dynamicItems:vr instanceof e.Name},gr.source&&(gr.source.evaluated=(0,e.stringify)(gr.evaluated))}return zt.validate=gr,zt}catch(lr){throw delete zt.validate,delete zt.validateName,sr&&this.logger.error("Error compiling schema, function code:",sr),lr}finally{this._compilations.delete(zt)}}compile.compileSchema=it;function ot(zt,Yt,Gt){var Vt;Gt=(0,tt.resolveUrl)(this.opts.uriResolver,Yt,Gt);const Zt=zt.refs[Gt];if(Zt)return Zt;let Xt=qt.call(this,zt,Gt);if(Xt===void 0){const Qt=(Vt=zt.localRefs)===null||Vt===void 0?void 0:Vt[Gt],{schemaId:er}=this.opts;Qt&&(Xt=new at({schema:Qt,schemaId:er,root:zt,baseId:Yt}))}if(Xt!==void 0)return zt.refs[Gt]=ct.call(this,Xt)}compile.resolveRef=ot;function ct(zt){return(0,tt.inlineRef)(zt.schema,this.opts.inlineRefs)?zt.schema:zt.validate?zt:it.call(this,zt)}function At(zt){for(const Yt of this._compilations)if(Rt(Yt,zt))return Yt}compile.getCompilingSchema=At;function Rt(zt,Yt){return zt.schema===Yt.schema&&zt.root===Yt.root&&zt.baseId===Yt.baseId}function qt(zt,Yt){let Gt;for(;typeof(Gt=this.refs[Yt])=="string";)Yt=Gt;return Gt||this.schemas[Yt]||Ft.call(this,zt,Yt)}function Ft(zt,Yt){const Gt=this.opts.uriResolver.parse(Yt),Vt=(0,tt._getFullPath)(this.opts.uriResolver,Gt);let Zt=(0,tt.getFullPath)(this.opts.uriResolver,zt.baseId,void 0);if(Object.keys(zt.schema).length>0&&Vt===Zt)return Ht.call(this,Gt,zt);const Xt=(0,tt.normalizeId)(Vt),Qt=this.refs[Xt]||this.schemas[Xt];if(typeof Qt=="string"){const er=Ft.call(this,zt,Qt);return typeof(er==null?void 0:er.schema)!="object"?void 0:Ht.call(this,Gt,er)}if(typeof(Qt==null?void 0:Qt.schema)=="object"){if(Qt.validate||it.call(this,Qt),Xt===(0,tt.normalizeId)(Yt)){const{schema:er}=Qt,{schemaId:nr}=this.opts,ar=er[nr];return ar&&(Zt=(0,tt.resolveUrl)(this.opts.uriResolver,Zt,ar)),new at({schema:er,schemaId:nr,root:zt,baseId:Zt})}return Ht.call(this,Gt,Qt)}}compile.resolveSchema=Ft;const Ut=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function Ht(zt,{baseId:Yt,schema:Gt,root:Vt}){var Zt;if(((Zt=zt.fragment)===null||Zt===void 0?void 0:Zt[0])!=="/")return;for(const er of zt.fragment.slice(1).split("/")){if(typeof Gt=="boolean")return;const nr=Gt[(0,rt.unescapeFragment)(er)];if(nr===void 0)return;Gt=nr;const ar=typeof Gt=="object"&&Gt[this.opts.schemaId];!Ut.has(er)&&ar&&(Yt=(0,tt.resolveUrl)(this.opts.uriResolver,Yt,ar))}let Xt;if(typeof Gt!="boolean"&&Gt.$ref&&!(0,rt.schemaHasRulesButRef)(Gt,this.RULES)){const er=(0,tt.resolveUrl)(this.opts.uriResolver,Yt,Gt.$ref);Xt=Ft.call(this,Vt,er)}const{schemaId:Qt}=this.opts;if(Xt=Xt||new at({schema:Gt,schemaId:Qt,root:Vt,baseId:Yt}),Xt.schema!==Xt.root.schema)return Xt}return compile}const $id$1="https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",description="Meta-schema for $data reference (JSON AnySchema extension proposal)",type$1="object",required$1=["$data"],properties$2={$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},additionalProperties$1=!1,require$$9={$id:$id$1,description,type:type$1,required:required$1,properties:properties$2,additionalProperties:additionalProperties$1};var uri={},fastUri={exports:{}},utils,hasRequiredUtils;function requireUtils(){if(hasRequiredUtils)return utils;hasRequiredUtils=1;const e=RegExp.prototype.test.bind(/^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu),t=RegExp.prototype.test.bind(/^(?:(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)$/u);function Ye(qt){let Ft="",Ut=0,Ht=0;for(Ht=0;Ht<qt.length;Ht++)if(Ut=qt[Ht].charCodeAt(0),Ut!==48){if(!(Ut>=48&&Ut<=57||Ut>=65&&Ut<=70||Ut>=97&&Ut<=102))return"";Ft+=qt[Ht];break}for(Ht+=1;Ht<qt.length;Ht++){if(Ut=qt[Ht].charCodeAt(0),!(Ut>=48&&Ut<=57||Ut>=65&&Ut<=70||Ut>=97&&Ut<=102))return"";Ft+=qt[Ht]}return Ft}const tt=RegExp.prototype.test.bind(/[^!"$&'()*+,\-.;=_`a-z{}~]/u);function rt(qt){return qt.length=0,!0}function nt(qt,Ft,Ut){if(qt.length){const Ht=Ye(qt);if(Ht!=="")Ft.push(Ht);else return Ut.error=!0,!1;qt.length=0}return!0}function at(qt){let Ft=0;const Ut={error:!1,address:"",zone:""},Ht=[],zt=[];let Yt=!1,Gt=!1,Vt=nt;for(let Zt=0;Zt<qt.length;Zt++){const Xt=qt[Zt];if(!(Xt==="["||Xt==="]"))if(Xt===":"){if(Yt===!0&&(Gt=!0),!Vt(zt,Ht,Ut))break;if(++Ft>7){Ut.error=!0;break}Zt>0&&qt[Zt-1]===":"&&(Yt=!0),Ht.push(":");continue}else if(Xt==="%"){if(!Vt(zt,Ht,Ut))break;Vt=rt}else{zt.push(Xt);continue}}return zt.length&&(Vt===rt?Ut.zone=zt.join(""):Gt?Ht.push(zt.join("")):Ht.push(Ye(zt))),Ut.address=Ht.join(""),Ut}function it(qt){if(ot(qt,":")<2)return{host:qt,isIPV6:!1};const Ft=at(qt);if(Ft.error)return{host:qt,isIPV6:!1};{let Ut=Ft.address,Ht=Ft.address;return Ft.zone&&(Ut+="%"+Ft.zone,Ht+="%25"+Ft.zone),{host:Ut,isIPV6:!0,escapedHost:Ht}}}function ot(qt,Ft){let Ut=0;for(let Ht=0;Ht<qt.length;Ht++)qt[Ht]===Ft&&Ut++;return Ut}function ct(qt){let Ft=qt;const Ut=[];let Ht=-1,zt=0;for(;zt=Ft.length;){if(zt===1){if(Ft===".")break;if(Ft==="/"){Ut.push("/");break}else{Ut.push(Ft);break}}else if(zt===2){if(Ft[0]==="."){if(Ft[1]===".")break;if(Ft[1]==="/"){Ft=Ft.slice(2);continue}}else if(Ft[0]==="/"&&(Ft[1]==="."||Ft[1]==="/")){Ut.push("/");break}}else if(zt===3&&Ft==="/.."){Ut.length!==0&&Ut.pop(),Ut.push("/");break}if(Ft[0]==="."){if(Ft[1]==="."){if(Ft[2]==="/"){Ft=Ft.slice(3);continue}}else if(Ft[1]==="/"){Ft=Ft.slice(2);continue}}else if(Ft[0]==="/"&&Ft[1]==="."){if(Ft[2]==="/"){Ft=Ft.slice(2);continue}else if(Ft[2]==="."&&Ft[3]==="/"){Ft=Ft.slice(3),Ut.length!==0&&Ut.pop();continue}}if((Ht=Ft.indexOf("/",1))===-1){Ut.push(Ft);break}else Ut.push(Ft.slice(0,Ht)),Ft=Ft.slice(Ht)}return Ut.join("")}function At(qt,Ft){const Ut=Ft!==!0?escape:unescape;return qt.scheme!==void 0&&(qt.scheme=Ut(qt.scheme)),qt.userinfo!==void 0&&(qt.userinfo=Ut(qt.userinfo)),qt.host!==void 0&&(qt.host=Ut(qt.host)),qt.path!==void 0&&(qt.path=Ut(qt.path)),qt.query!==void 0&&(qt.query=Ut(qt.query)),qt.fragment!==void 0&&(qt.fragment=Ut(qt.fragment)),qt}function Rt(qt){const Ft=[];if(qt.userinfo!==void 0&&(Ft.push(qt.userinfo),Ft.push("@")),qt.host!==void 0){let Ut=unescape(qt.host);if(!t(Ut)){const Ht=it(Ut);Ht.isIPV6===!0?Ut=`[${Ht.escapedHost}]`:Ut=qt.host}Ft.push(Ut)}return(typeof qt.port=="number"||typeof qt.port=="string")&&(Ft.push(":"),Ft.push(String(qt.port))),Ft.length?Ft.join(""):void 0}return utils={nonSimpleDomain:tt,recomposeAuthority:Rt,normalizeComponentEncoding:At,removeDotSegments:ct,isIPv4:t,isUUID:e,normalizeIPv6:it,stringArrayToHexStripped:Ye},utils}var schemes,hasRequiredSchemes;function requireSchemes(){if(hasRequiredSchemes)return schemes;hasRequiredSchemes=1;const{isUUID:e}=requireUtils(),t=/([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu,Ye=["http","https","ws","wss","urn","urn:uuid"];function tt(Xt){return Ye.indexOf(Xt)!==-1}function rt(Xt){return Xt.secure===!0?!0:Xt.secure===!1?!1:Xt.scheme?Xt.scheme.length===3&&(Xt.scheme[0]==="w"||Xt.scheme[0]==="W")&&(Xt.scheme[1]==="s"||Xt.scheme[1]==="S")&&(Xt.scheme[2]==="s"||Xt.scheme[2]==="S"):!1}function nt(Xt){return Xt.host||(Xt.error=Xt.error||"HTTP URIs must have a host."),Xt}function at(Xt){const Qt=String(Xt.scheme).toLowerCase()==="https";return(Xt.port===(Qt?443:80)||Xt.port==="")&&(Xt.port=void 0),Xt.path||(Xt.path="/"),Xt}function it(Xt){return Xt.secure=rt(Xt),Xt.resourceName=(Xt.path||"/")+(Xt.query?"?"+Xt.query:""),Xt.path=void 0,Xt.query=void 0,Xt}function ot(Xt){if((Xt.port===(rt(Xt)?443:80)||Xt.port==="")&&(Xt.port=void 0),typeof Xt.secure=="boolean"&&(Xt.scheme=Xt.secure?"wss":"ws",Xt.secure=void 0),Xt.resourceName){const[Qt,er]=Xt.resourceName.split("?");Xt.path=Qt&&Qt!=="/"?Qt:void 0,Xt.query=er,Xt.resourceName=void 0}return Xt.fragment=void 0,Xt}function ct(Xt,Qt){if(!Xt.path)return Xt.error="URN can not be parsed",Xt;const er=Xt.path.match(t);if(er){const nr=Qt.scheme||Xt.scheme||"urn";Xt.nid=er[1].toLowerCase(),Xt.nss=er[2];const ar=`${nr}:${Qt.nid||Xt.nid}`,sr=Zt(ar);Xt.path=void 0,sr&&(Xt=sr.parse(Xt,Qt))}else Xt.error=Xt.error||"URN can not be parsed.";return Xt}function At(Xt,Qt){if(Xt.nid===void 0)throw new Error("URN without nid cannot be serialized");const er=Qt.scheme||Xt.scheme||"urn",nr=Xt.nid.toLowerCase(),ar=`${er}:${Qt.nid||nr}`,sr=Zt(ar);sr&&(Xt=sr.serialize(Xt,Qt));const lr=Xt,fr=Xt.nss;return lr.path=`${nr||Qt.nid}:${fr}`,Qt.skipEscape=!0,lr}function Rt(Xt,Qt){const er=Xt;return er.uuid=er.nss,er.nss=void 0,!Qt.tolerant&&(!er.uuid||!e(er.uuid))&&(er.error=er.error||"UUID is not valid."),er}function qt(Xt){const Qt=Xt;return Qt.nss=(Xt.uuid||"").toLowerCase(),Qt}const Ft={scheme:"http",domainHost:!0,parse:nt,serialize:at},Ut={scheme:"https",domainHost:Ft.domainHost,parse:nt,serialize:at},Ht={scheme:"ws",domainHost:!0,parse:it,serialize:ot},zt={scheme:"wss",domainHost:Ht.domainHost,parse:Ht.parse,serialize:Ht.serialize},Vt={http:Ft,https:Ut,ws:Ht,wss:zt,urn:{scheme:"urn",parse:ct,serialize:At,skipNormalize:!0},"urn:uuid":{scheme:"urn:uuid",parse:Rt,serialize:qt,skipNormalize:!0}};Object.setPrototypeOf(Vt,null);function Zt(Xt){return Xt&&(Vt[Xt]||Vt[Xt.toLowerCase()])||void 0}return schemes={wsIsSecure:rt,SCHEMES:Vt,isValidSchemeName:tt,getSchemeHandler:Zt},schemes}var hasRequiredFastUri;function requireFastUri(){if(hasRequiredFastUri)return fastUri.exports;hasRequiredFastUri=1;const{normalizeIPv6:e,removeDotSegments:t,recomposeAuthority:Ye,normalizeComponentEncoding:tt,isIPv4:rt,nonSimpleDomain:nt}=requireUtils(),{SCHEMES:at,getSchemeHandler:it}=requireSchemes();function ot(zt,Yt){return typeof zt=="string"?zt=qt(Ut(zt,Yt),Yt):typeof zt=="object"&&(zt=Ut(qt(zt,Yt),Yt)),zt}function ct(zt,Yt,Gt){const Vt=Gt?Object.assign({scheme:"null"},Gt):{scheme:"null"},Zt=At(Ut(zt,Vt),Ut(Yt,Vt),Vt,!0);return Vt.skipEscape=!0,qt(Zt,Vt)}function At(zt,Yt,Gt,Vt){const Zt={};return Vt||(zt=Ut(qt(zt,Gt),Gt),Yt=Ut(qt(Yt,Gt),Gt)),Gt=Gt||{},!Gt.tolerant&&Yt.scheme?(Zt.scheme=Yt.scheme,Zt.userinfo=Yt.userinfo,Zt.host=Yt.host,Zt.port=Yt.port,Zt.path=t(Yt.path||""),Zt.query=Yt.query):(Yt.userinfo!==void 0||Yt.host!==void 0||Yt.port!==void 0?(Zt.userinfo=Yt.userinfo,Zt.host=Yt.host,Zt.port=Yt.port,Zt.path=t(Yt.path||""),Zt.query=Yt.query):(Yt.path?(Yt.path[0]==="/"?Zt.path=t(Yt.path):((zt.userinfo!==void 0||zt.host!==void 0||zt.port!==void 0)&&!zt.path?Zt.path="/"+Yt.path:zt.path?Zt.path=zt.path.slice(0,zt.path.lastIndexOf("/")+1)+Yt.path:Zt.path=Yt.path,Zt.path=t(Zt.path)),Zt.query=Yt.query):(Zt.path=zt.path,Yt.query!==void 0?Zt.query=Yt.query:Zt.query=zt.query),Zt.userinfo=zt.userinfo,Zt.host=zt.host,Zt.port=zt.port),Zt.scheme=zt.scheme),Zt.fragment=Yt.fragment,Zt}function Rt(zt,Yt,Gt){return typeof zt=="string"?(zt=unescape(zt),zt=qt(tt(Ut(zt,Gt),!0),{...Gt,skipEscape:!0})):typeof zt=="object"&&(zt=qt(tt(zt,!0),{...Gt,skipEscape:!0})),typeof Yt=="string"?(Yt=unescape(Yt),Yt=qt(tt(Ut(Yt,Gt),!0),{...Gt,skipEscape:!0})):typeof Yt=="object"&&(Yt=qt(tt(Yt,!0),{...Gt,skipEscape:!0})),zt.toLowerCase()===Yt.toLowerCase()}function qt(zt,Yt){const Gt={host:zt.host,scheme:zt.scheme,userinfo:zt.userinfo,port:zt.port,path:zt.path,query:zt.query,nid:zt.nid,nss:zt.nss,uuid:zt.uuid,fragment:zt.fragment,reference:zt.reference,resourceName:zt.resourceName,secure:zt.secure,error:""},Vt=Object.assign({},Yt),Zt=[],Xt=it(Vt.scheme||Gt.scheme);Xt&&Xt.serialize&&Xt.serialize(Gt,Vt),Gt.path!==void 0&&(Vt.skipEscape?Gt.path=unescape(Gt.path):(Gt.path=escape(Gt.path),Gt.scheme!==void 0&&(Gt.path=Gt.path.split("%3A").join(":")))),Vt.reference!=="suffix"&&Gt.scheme&&Zt.push(Gt.scheme,":");const Qt=Ye(Gt);if(Qt!==void 0&&(Vt.reference!=="suffix"&&Zt.push("//"),Zt.push(Qt),Gt.path&&Gt.path[0]!=="/"&&Zt.push("/")),Gt.path!==void 0){let er=Gt.path;!Vt.absolutePath&&(!Xt||!Xt.absolutePath)&&(er=t(er)),Qt===void 0&&er[0]==="/"&&er[1]==="/"&&(er="/%2F"+er.slice(2)),Zt.push(er)}return Gt.query!==void 0&&Zt.push("?",Gt.query),Gt.fragment!==void 0&&Zt.push("#",Gt.fragment),Zt.join("")}const Ft=/^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u;function Ut(zt,Yt){const Gt=Object.assign({},Yt),Vt={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0};let Zt=!1;Gt.reference==="suffix"&&(Gt.scheme?zt=Gt.scheme+":"+zt:zt="//"+zt);const Xt=zt.match(Ft);if(Xt){if(Vt.scheme=Xt[1],Vt.userinfo=Xt[3],Vt.host=Xt[4],Vt.port=parseInt(Xt[5],10),Vt.path=Xt[6]||"",Vt.query=Xt[7],Vt.fragment=Xt[8],isNaN(Vt.port)&&(Vt.port=Xt[5]),Vt.host)if(rt(Vt.host)===!1){const nr=e(Vt.host);Vt.host=nr.host.toLowerCase(),Zt=nr.isIPV6}else Zt=!0;Vt.scheme===void 0&&Vt.userinfo===void 0&&Vt.host===void 0&&Vt.port===void 0&&Vt.query===void 0&&!Vt.path?Vt.reference="same-document":Vt.scheme===void 0?Vt.reference="relative":Vt.fragment===void 0?Vt.reference="absolute":Vt.reference="uri",Gt.reference&&Gt.reference!=="suffix"&&Gt.reference!==Vt.reference&&(Vt.error=Vt.error||"URI is not a "+Gt.reference+" reference.");const Qt=it(Gt.scheme||Vt.scheme);if(!Gt.unicodeSupport&&(!Qt||!Qt.unicodeSupport)&&Vt.host&&(Gt.domainHost||Qt&&Qt.domainHost)&&Zt===!1&&nt(Vt.host))try{Vt.host=URL.domainToASCII(Vt.host.toLowerCase())}catch(er){Vt.error=Vt.error||"Host's domain name can not be converted to ASCII: "+er}(!Qt||Qt&&!Qt.skipNormalize)&&(zt.indexOf("%")!==-1&&(Vt.scheme!==void 0&&(Vt.scheme=unescape(Vt.scheme)),Vt.host!==void 0&&(Vt.host=unescape(Vt.host))),Vt.path&&(Vt.path=escape(unescape(Vt.path))),Vt.fragment&&(Vt.fragment=encodeURI(decodeURIComponent(Vt.fragment)))),Qt&&Qt.parse&&Qt.parse(Vt,Gt)}else Vt.error=Vt.error||"URI can not be parsed.";return Vt}const Ht={SCHEMES:at,normalize:ot,resolve:ct,resolveComponent:At,equal:Rt,serialize:qt,parse:Ut};return fastUri.exports=Ht,fastUri.exports.default=Ht,fastUri.exports.fastUri=Ht,fastUri.exports}var hasRequiredUri;function requireUri(){if(hasRequiredUri)return uri;hasRequiredUri=1,Object.defineProperty(uri,"__esModule",{value:!0});const e=requireFastUri();return e.code='require("ajv/dist/runtime/uri").default',uri.default=e,uri}var hasRequiredCore$1;function requireCore$1(){return hasRequiredCore$1||(hasRequiredCore$1=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CodeGen=e.Name=e.nil=e.stringify=e.str=e._=e.KeywordCxt=void 0;var t=requireValidate();Object.defineProperty(e,"KeywordCxt",{enumerable:!0,get:function(){return t.KeywordCxt}});var Ye=requireCodegen();Object.defineProperty(e,"_",{enumerable:!0,get:function(){return Ye._}}),Object.defineProperty(e,"str",{enumerable:!0,get:function(){return Ye.str}}),Object.defineProperty(e,"stringify",{enumerable:!0,get:function(){return Ye.stringify}}),Object.defineProperty(e,"nil",{enumerable:!0,get:function(){return Ye.nil}}),Object.defineProperty(e,"Name",{enumerable:!0,get:function(){return Ye.Name}}),Object.defineProperty(e,"CodeGen",{enumerable:!0,get:function(){return Ye.CodeGen}});const tt=requireValidation_error(),rt=requireRef_error(),nt=requireRules(),at=requireCompile(),it=requireCodegen(),ot=requireResolve(),ct=requireDataType(),At=requireUtil(),Rt=require$$9,qt=requireUri(),Ft=(ur,cr)=>new RegExp(ur,cr);Ft.code="new RegExp";const Ut=["removeAdditional","useDefaults","coerceTypes"],Ht=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),zt={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."},Yt={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},Gt=200;function Vt(ur){var cr,yr,ir,or,hr,Sr,wr,Ir,kr,Mr,Ar,Rr,Dr,Lr,Ur,Wr,Kr,nn,Jr,un,pn,Zr,rn,fn,mn;const jr=ur.strict,Hr=(cr=ur.code)===null||cr===void 0?void 0:cr.optimize,Yr=Hr===!0||Hr===void 0?1:Hr||0,en=(ir=(yr=ur.code)===null||yr===void 0?void 0:yr.regExp)!==null&&ir!==void 0?ir:Ft,dn=(or=ur.uriResolver)!==null&&or!==void 0?or:qt.default;return{strictSchema:(Sr=(hr=ur.strictSchema)!==null&&hr!==void 0?hr:jr)!==null&&Sr!==void 0?Sr:!0,strictNumbers:(Ir=(wr=ur.strictNumbers)!==null&&wr!==void 0?wr:jr)!==null&&Ir!==void 0?Ir:!0,strictTypes:(Mr=(kr=ur.strictTypes)!==null&&kr!==void 0?kr:jr)!==null&&Mr!==void 0?Mr:"log",strictTuples:(Rr=(Ar=ur.strictTuples)!==null&&Ar!==void 0?Ar:jr)!==null&&Rr!==void 0?Rr:"log",strictRequired:(Lr=(Dr=ur.strictRequired)!==null&&Dr!==void 0?Dr:jr)!==null&&Lr!==void 0?Lr:!1,code:ur.code?{...ur.code,optimize:Yr,regExp:en}:{optimize:Yr,regExp:en},loopRequired:(Ur=ur.loopRequired)!==null&&Ur!==void 0?Ur:Gt,loopEnum:(Wr=ur.loopEnum)!==null&&Wr!==void 0?Wr:Gt,meta:(Kr=ur.meta)!==null&&Kr!==void 0?Kr:!0,messages:(nn=ur.messages)!==null&&nn!==void 0?nn:!0,inlineRefs:(Jr=ur.inlineRefs)!==null&&Jr!==void 0?Jr:!0,schemaId:(un=ur.schemaId)!==null&&un!==void 0?un:"$id",addUsedSchema:(pn=ur.addUsedSchema)!==null&&pn!==void 0?pn:!0,validateSchema:(Zr=ur.validateSchema)!==null&&Zr!==void 0?Zr:!0,validateFormats:(rn=ur.validateFormats)!==null&&rn!==void 0?rn:!0,unicodeRegExp:(fn=ur.unicodeRegExp)!==null&&fn!==void 0?fn:!0,int32range:(mn=ur.int32range)!==null&&mn!==void 0?mn:!0,uriResolver:dn}}class Zt{constructor(cr={}){this.schemas={},this.refs={},this.formats={},this._compilations=new Set,this._loading={},this._cache=new Map,cr=this.opts={...cr,...Vt(cr)};const{es5:yr,lines:ir}=this.opts.code;this.scope=new it.ValueScope({scope:{},prefixes:Ht,es5:yr,lines:ir}),this.logger=fr(cr.logger);const or=cr.validateFormats;cr.validateFormats=!1,this.RULES=(0,nt.getRules)(),Xt.call(this,zt,cr,"NOT SUPPORTED"),Xt.call(this,Yt,cr,"DEPRECATED","warn"),this._metaOpts=sr.call(this),cr.formats&&nr.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),cr.keywords&&ar.call(this,cr.keywords),typeof cr.meta=="object"&&this.addMetaSchema(cr.meta),er.call(this),cr.validateFormats=or}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){const{$data:cr,meta:yr,schemaId:ir}=this.opts;let or=Rt;ir==="id"&&(or={...Rt},or.id=or.$id,delete or.$id),yr&&cr&&this.addMetaSchema(or,or[ir],!1)}defaultMeta(){const{meta:cr,schemaId:yr}=this.opts;return this.opts.defaultMeta=typeof cr=="object"?cr[yr]||cr:void 0}validate(cr,yr){let ir;if(typeof cr=="string"){if(ir=this.getSchema(cr),!ir)throw new Error(`no schema with key or ref "${cr}"`)}else ir=this.compile(cr);const or=ir(yr);return"$async"in ir||(this.errors=ir.errors),or}compile(cr,yr){const ir=this._addSchema(cr,yr);return ir.validate||this._compileSchemaEnv(ir)}compileAsync(cr,yr){if(typeof this.opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");const{loadSchema:ir}=this.opts;return or.call(this,cr,yr);async function or(Mr,Ar){await hr.call(this,Mr.$schema);const Rr=this._addSchema(Mr,Ar);return Rr.validate||Sr.call(this,Rr)}async function hr(Mr){Mr&&!this.getSchema(Mr)&&await or.call(this,{$ref:Mr},!0)}async function Sr(Mr){try{return this._compileSchemaEnv(Mr)}catch(Ar){if(!(Ar instanceof rt.default))throw Ar;return wr.call(this,Ar),await Ir.call(this,Ar.missingSchema),Sr.call(this,Mr)}}function wr({missingSchema:Mr,missingRef:Ar}){if(this.refs[Mr])throw new Error(`AnySchema ${Mr} is loaded but ${Ar} cannot be resolved`)}async function Ir(Mr){const Ar=await kr.call(this,Mr);this.refs[Mr]||await hr.call(this,Ar.$schema),this.refs[Mr]||this.addSchema(Ar,Mr,yr)}async function kr(Mr){const Ar=this._loading[Mr];if(Ar)return Ar;try{return await(this._loading[Mr]=ir(Mr))}finally{delete this._loading[Mr]}}}addSchema(cr,yr,ir,or=this.opts.validateSchema){if(Array.isArray(cr)){for(const Sr of cr)this.addSchema(Sr,void 0,ir,or);return this}let hr;if(typeof cr=="object"){const{schemaId:Sr}=this.opts;if(hr=cr[Sr],hr!==void 0&&typeof hr!="string")throw new Error(`schema ${Sr} must be string`)}return yr=(0,ot.normalizeId)(yr||hr),this._checkUnique(yr),this.schemas[yr]=this._addSchema(cr,ir,yr,or,!0),this}addMetaSchema(cr,yr,ir=this.opts.validateSchema){return this.addSchema(cr,yr,!0,ir),this}validateSchema(cr,yr){if(typeof cr=="boolean")return!0;let ir;if(ir=cr.$schema,ir!==void 0&&typeof ir!="string")throw new Error("$schema must be a string");if(ir=ir||this.opts.defaultMeta||this.defaultMeta(),!ir)return this.logger.warn("meta-schema not available"),this.errors=null,!0;const or=this.validate(ir,cr);if(!or&&yr){const hr="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error(hr);else throw new Error(hr)}return or}getSchema(cr){let yr;for(;typeof(yr=Qt.call(this,cr))=="string";)cr=yr;if(yr===void 0){const{schemaId:ir}=this.opts,or=new at.SchemaEnv({schema:{},schemaId:ir});if(yr=at.resolveSchema.call(this,or,cr),!yr)return;this.refs[cr]=yr}return yr.validate||this._compileSchemaEnv(yr)}removeSchema(cr){if(cr instanceof RegExp)return this._removeAllSchemas(this.schemas,cr),this._removeAllSchemas(this.refs,cr),this;switch(typeof cr){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{const yr=Qt.call(this,cr);return typeof yr=="object"&&this._cache.delete(yr.schema),delete this.schemas[cr],delete this.refs[cr],this}case"object":{const yr=cr;this._cache.delete(yr);let ir=cr[this.opts.schemaId];return ir&&(ir=(0,ot.normalizeId)(ir),delete this.schemas[ir],delete this.refs[ir]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(cr){for(const yr of cr)this.addKeyword(yr);return this}addKeyword(cr,yr){let ir;if(typeof cr=="string")ir=cr,typeof yr=="object"&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),yr.keyword=ir);else if(typeof cr=="object"&&yr===void 0){if(yr=cr,ir=yr.keyword,Array.isArray(ir)&&!ir.length)throw new Error("addKeywords: keyword must be string or non-empty array")}else throw new Error("invalid addKeywords parameters");if(dr.call(this,ir,yr),!yr)return(0,At.eachItem)(ir,hr=>vr.call(this,hr)),this;Er.call(this,yr);const or={...yr,type:(0,ct.getJSONTypes)(yr.type),schemaType:(0,ct.getJSONTypes)(yr.schemaType)};return(0,At.eachItem)(ir,or.type.length===0?hr=>vr.call(this,hr,or):hr=>or.type.forEach(Sr=>vr.call(this,hr,or,Sr))),this}getKeyword(cr){const yr=this.RULES.all[cr];return typeof yr=="object"?yr.definition:!!yr}removeKeyword(cr){const{RULES:yr}=this;delete yr.keywords[cr],delete yr.all[cr];for(const ir of yr.rules){const or=ir.rules.findIndex(hr=>hr.keyword===cr);or>=0&&ir.rules.splice(or,1)}return this}addFormat(cr,yr){return typeof yr=="string"&&(yr=new RegExp(yr)),this.formats[cr]=yr,this}errorsText(cr=this.errors,{separator:yr=", ",dataVar:ir="data"}={}){return!cr||cr.length===0?"No errors":cr.map(or=>`${ir}${or.instancePath} ${or.message}`).reduce((or,hr)=>or+yr+hr)}$dataMetaSchema(cr,yr){const ir=this.RULES.all;cr=JSON.parse(JSON.stringify(cr));for(const or of yr){const hr=or.split("/").slice(1);let Sr=cr;for(const wr of hr)Sr=Sr[wr];for(const wr in ir){const Ir=ir[wr];if(typeof Ir!="object")continue;const{$data:kr}=Ir.definition,Mr=Sr[wr];kr&&Mr&&(Sr[wr]=Tr(Mr))}}return cr}_removeAllSchemas(cr,yr){for(const ir in cr){const or=cr[ir];(!yr||yr.test(ir))&&(typeof or=="string"?delete cr[ir]:or&&!or.meta&&(this._cache.delete(or.schema),delete cr[ir]))}}_addSchema(cr,yr,ir,or=this.opts.validateSchema,hr=this.opts.addUsedSchema){let Sr;const{schemaId:wr}=this.opts;if(typeof cr=="object")Sr=cr[wr];else{if(this.opts.jtd)throw new Error("schema must be object");if(typeof cr!="boolean")throw new Error("schema must be object or boolean")}let Ir=this._cache.get(cr);if(Ir!==void 0)return Ir;ir=(0,ot.normalizeId)(Sr||ir);const kr=ot.getSchemaRefs.call(this,cr,ir);return Ir=new at.SchemaEnv({schema:cr,schemaId:wr,meta:yr,baseId:ir,localRefs:kr}),this._cache.set(Ir.schema,Ir),hr&&!ir.startsWith("#")&&(ir&&this._checkUnique(ir),this.refs[ir]=Ir),or&&this.validateSchema(cr,!0),Ir}_checkUnique(cr){if(this.schemas[cr]||this.refs[cr])throw new Error(`schema with key or id "${cr}" already exists`)}_compileSchemaEnv(cr){if(cr.meta?this._compileMetaSchema(cr):at.compileSchema.call(this,cr),!cr.validate)throw new Error("ajv implementation error");return cr.validate}_compileMetaSchema(cr){const yr=this.opts;this.opts=this._metaOpts;try{at.compileSchema.call(this,cr)}finally{this.opts=yr}}}Zt.ValidationError=tt.default,Zt.MissingRefError=rt.default,e.default=Zt;function Xt(ur,cr,yr,ir="error"){for(const or in ur){const hr=or;hr in cr&&this.logger[ir](`${yr}: option ${or}. ${ur[hr]}`)}}function Qt(ur){return ur=(0,ot.normalizeId)(ur),this.schemas[ur]||this.refs[ur]}function er(){const ur=this.opts.schemas;if(ur)if(Array.isArray(ur))this.addSchema(ur);else for(const cr in ur)this.addSchema(ur[cr],cr)}function nr(){for(const ur in this.opts.formats){const cr=this.opts.formats[ur];cr&&this.addFormat(ur,cr)}}function ar(ur){if(Array.isArray(ur)){this.addVocabulary(ur);return}this.logger.warn("keywords option as map is deprecated, pass array");for(const cr in ur){const yr=ur[cr];yr.keyword||(yr.keyword=cr),this.addKeyword(yr)}}function sr(){const ur={...this.opts};for(const cr of Ut)delete ur[cr];return ur}const lr={log(){},warn(){},error(){}};function fr(ur){if(ur===!1)return lr;if(ur===void 0)return console;if(ur.log&&ur.warn&&ur.error)return ur;throw new Error("logger must implement log, warn and error methods")}const gr=/^[a-z_$][a-z0-9_$:-]*$/i;function dr(ur,cr){const{RULES:yr}=this;if((0,At.eachItem)(ur,ir=>{if(yr.keywords[ir])throw new Error(`Keyword ${ir} is already defined`);if(!gr.test(ir))throw new Error(`Keyword ${ir} has invalid name`)}),!!cr&&cr.$data&&!("code"in cr||"validate"in cr))throw new Error('$data keyword must have "code" or "validate" function')}function vr(ur,cr,yr){var ir;const or=cr==null?void 0:cr.post;if(yr&&or)throw new Error('keyword with "post" flag cannot have "type"');const{RULES:hr}=this;let Sr=or?hr.post:hr.rules.find(({type:Ir})=>Ir===yr);if(Sr||(Sr={type:yr,rules:[]},hr.rules.push(Sr)),hr.keywords[ur]=!0,!cr)return;const wr={keyword:ur,definition:{...cr,type:(0,ct.getJSONTypes)(cr.type),schemaType:(0,ct.getJSONTypes)(cr.schemaType)}};cr.before?mr.call(this,Sr,wr,cr.before):Sr.rules.push(wr),hr.all[ur]=wr,(ir=cr.implements)===null||ir===void 0||ir.forEach(Ir=>this.addKeyword(Ir))}function mr(ur,cr,yr){const ir=ur.rules.findIndex(or=>or.keyword===yr);ir>=0?ur.rules.splice(ir,0,cr):(ur.rules.push(cr),this.logger.warn(`rule ${yr} is not defined`))}function Er(ur){let{metaSchema:cr}=ur;cr!==void 0&&(ur.$data&&this.opts.$data&&(cr=Tr(cr)),ur.validateSchema=this.compile(cr,!0))}const _r={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function Tr(ur){return{anyOf:[ur,_r]}}}(core$1)),core$1}var draft7={},core={},id={},hasRequiredId;function requireId(){if(hasRequiredId)return id;hasRequiredId=1,Object.defineProperty(id,"__esModule",{value:!0});const e={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};return id.default=e,id}var ref={},hasRequiredRef;function requireRef(){if(hasRequiredRef)return ref;hasRequiredRef=1,Object.defineProperty(ref,"__esModule",{value:!0}),ref.callRef=ref.getValidate=void 0;const e=requireRef_error(),t=requireCode(),Ye=requireCodegen(),tt=requireNames(),rt=requireCompile(),nt=requireUtil(),at={keyword:"$ref",schemaType:"string",code(ct){const{gen:At,schema:Rt,it:qt}=ct,{baseId:Ft,schemaEnv:Ut,validateName:Ht,opts:zt,self:Yt}=qt,{root:Gt}=Ut;if((Rt==="#"||Rt==="#/")&&Ft===Gt.baseId)return Zt();const Vt=rt.resolveRef.call(Yt,Gt,Ft,Rt);if(Vt===void 0)throw new e.default(qt.opts.uriResolver,Ft,Rt);if(Vt instanceof rt.SchemaEnv)return Xt(Vt);return Qt(Vt);function Zt(){if(Ut===Gt)return ot(ct,Ht,Ut,Ut.$async);const er=At.scopeValue("root",{ref:Gt});return ot(ct,(0,Ye._)`${er}.validate`,Gt,Gt.$async)}function Xt(er){const nr=it(ct,er);ot(ct,nr,er,er.$async)}function Qt(er){const nr=At.scopeValue("schema",zt.code.source===!0?{ref:er,code:(0,Ye.stringify)(er)}:{ref:er}),ar=At.name("valid"),sr=ct.subschema({schema:er,dataTypes:[],schemaPath:Ye.nil,topSchemaRef:nr,errSchemaPath:Rt},ar);ct.mergeEvaluated(sr),ct.ok(ar)}}};function it(ct,At){const{gen:Rt}=ct;return At.validate?Rt.scopeValue("validate",{ref:At.validate}):(0,Ye._)`${Rt.scopeValue("wrapper",{ref:At})}.validate`}ref.getValidate=it;function ot(ct,At,Rt,qt){const{gen:Ft,it:Ut}=ct,{allErrors:Ht,schemaEnv:zt,opts:Yt}=Ut,Gt=Yt.passContext?tt.default.this:Ye.nil;qt?Vt():Zt();function Vt(){if(!zt.$async)throw new Error("async schema referenced by sync schema");const er=Ft.let("valid");Ft.try(()=>{Ft.code((0,Ye._)`await ${(0,t.callValidateCode)(ct,At,Gt)}`),Qt(At),Ht||Ft.assign(er,!0)},nr=>{Ft.if((0,Ye._)`!(${nr} instanceof ${Ut.ValidationError})`,()=>Ft.throw(nr)),Xt(nr),Ht||Ft.assign(er,!1)}),ct.ok(er)}function Zt(){ct.result((0,t.callValidateCode)(ct,At,Gt),()=>Qt(At),()=>Xt(At))}function Xt(er){const nr=(0,Ye._)`${er}.errors`;Ft.assign(tt.default.vErrors,(0,Ye._)`${tt.default.vErrors} === null ? ${nr} : ${tt.default.vErrors}.concat(${nr})`),Ft.assign(tt.default.errors,(0,Ye._)`${tt.default.vErrors}.length`)}function Qt(er){var nr;if(!Ut.opts.unevaluated)return;const ar=(nr=Rt==null?void 0:Rt.validate)===null||nr===void 0?void 0:nr.evaluated;if(Ut.props!==!0)if(ar&&!ar.dynamicProps)ar.props!==void 0&&(Ut.props=nt.mergeEvaluated.props(Ft,ar.props,Ut.props));else{const sr=Ft.var("props",(0,Ye._)`${er}.evaluated.props`);Ut.props=nt.mergeEvaluated.props(Ft,sr,Ut.props,Ye.Name)}if(Ut.items!==!0)if(ar&&!ar.dynamicItems)ar.items!==void 0&&(Ut.items=nt.mergeEvaluated.items(Ft,ar.items,Ut.items));else{const sr=Ft.var("items",(0,Ye._)`${er}.evaluated.items`);Ut.items=nt.mergeEvaluated.items(Ft,sr,Ut.items,Ye.Name)}}}return ref.callRef=ot,ref.default=at,ref}var hasRequiredCore;function requireCore(){if(hasRequiredCore)return core;hasRequiredCore=1,Object.defineProperty(core,"__esModule",{value:!0});const e=requireId(),t=requireRef(),Ye=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",e.default,t.default];return core.default=Ye,core}var validation={},limitNumber={},hasRequiredLimitNumber;function requireLimitNumber(){if(hasRequiredLimitNumber)return limitNumber;hasRequiredLimitNumber=1,Object.defineProperty(limitNumber,"__esModule",{value:!0});const e=requireCodegen(),t=e.operators,Ye={maximum:{okStr:"<=",ok:t.LTE,fail:t.GT},minimum:{okStr:">=",ok:t.GTE,fail:t.LT},exclusiveMaximum:{okStr:"<",ok:t.LT,fail:t.GTE},exclusiveMinimum:{okStr:">",ok:t.GT,fail:t.LTE}},tt={message:({keyword:nt,schemaCode:at})=>(0,e.str)`must be ${Ye[nt].okStr} ${at}`,params:({keyword:nt,schemaCode:at})=>(0,e._)`{comparison: ${Ye[nt].okStr}, limit: ${at}}`},rt={keyword:Object.keys(Ye),type:"number",schemaType:"number",$data:!0,error:tt,code(nt){const{keyword:at,data:it,schemaCode:ot}=nt;nt.fail$data((0,e._)`${it} ${Ye[at].fail} ${ot} || isNaN(${it})`)}};return limitNumber.default=rt,limitNumber}var multipleOf={},hasRequiredMultipleOf;function requireMultipleOf(){if(hasRequiredMultipleOf)return multipleOf;hasRequiredMultipleOf=1,Object.defineProperty(multipleOf,"__esModule",{value:!0});const e=requireCodegen(),Ye={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:{message:({schemaCode:tt})=>(0,e.str)`must be multiple of ${tt}`,params:({schemaCode:tt})=>(0,e._)`{multipleOf: ${tt}}`},code(tt){const{gen:rt,data:nt,schemaCode:at,it}=tt,ot=it.opts.multipleOfPrecision,ct=rt.let("res"),At=ot?(0,e._)`Math.abs(Math.round(${ct}) - ${ct}) > 1e-${ot}`:(0,e._)`${ct} !== parseInt(${ct})`;tt.fail$data((0,e._)`(${at} === 0 || (${ct} = ${nt}/${at}, ${At}))`)}};return multipleOf.default=Ye,multipleOf}var limitLength={},ucs2length={},hasRequiredUcs2length;function requireUcs2length(){if(hasRequiredUcs2length)return ucs2length;hasRequiredUcs2length=1,Object.defineProperty(ucs2length,"__esModule",{value:!0});function e(t){const Ye=t.length;let tt=0,rt=0,nt;for(;rt<Ye;)tt++,nt=t.charCodeAt(rt++),nt>=55296&&nt<=56319&&rt<Ye&&(nt=t.charCodeAt(rt),(nt&64512)===56320&&rt++);return tt}return ucs2length.default=e,e.code='require("ajv/dist/runtime/ucs2length").default',ucs2length}var hasRequiredLimitLength;function requireLimitLength(){if(hasRequiredLimitLength)return limitLength;hasRequiredLimitLength=1,Object.defineProperty(limitLength,"__esModule",{value:!0});const e=requireCodegen(),t=requireUtil(),Ye=requireUcs2length(),rt={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:{message({keyword:nt,schemaCode:at}){const it=nt==="maxLength"?"more":"fewer";return(0,e.str)`must NOT have ${it} than ${at} characters`},params:({schemaCode:nt})=>(0,e._)`{limit: ${nt}}`},code(nt){const{keyword:at,data:it,schemaCode:ot,it:ct}=nt,At=at==="maxLength"?e.operators.GT:e.operators.LT,Rt=ct.opts.unicode===!1?(0,e._)`${it}.length`:(0,e._)`${(0,t.useFunc)(nt.gen,Ye.default)}(${it})`;nt.fail$data((0,e._)`${Rt} ${At} ${ot}`)}};return limitLength.default=rt,limitLength}var pattern={},hasRequiredPattern;function requirePattern(){if(hasRequiredPattern)return pattern;hasRequiredPattern=1,Object.defineProperty(pattern,"__esModule",{value:!0});const e=requireCode(),t=requireCodegen(),tt={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:{message:({schemaCode:rt})=>(0,t.str)`must match pattern "${rt}"`,params:({schemaCode:rt})=>(0,t._)`{pattern: ${rt}}`},code(rt){const{data:nt,$data:at,schema:it,schemaCode:ot,it:ct}=rt,At=ct.opts.unicodeRegExp?"u":"",Rt=at?(0,t._)`(new RegExp(${ot}, ${At}))`:(0,e.usePattern)(rt,it);rt.fail$data((0,t._)`!${Rt}.test(${nt})`)}};return pattern.default=tt,pattern}var limitProperties={},hasRequiredLimitProperties;function requireLimitProperties(){if(hasRequiredLimitProperties)return limitProperties;hasRequiredLimitProperties=1,Object.defineProperty(limitProperties,"__esModule",{value:!0});const e=requireCodegen(),Ye={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:{message({keyword:tt,schemaCode:rt}){const nt=tt==="maxProperties"?"more":"fewer";return(0,e.str)`must NOT have ${nt} than ${rt} properties`},params:({schemaCode:tt})=>(0,e._)`{limit: ${tt}}`},code(tt){const{keyword:rt,data:nt,schemaCode:at}=tt,it=rt==="maxProperties"?e.operators.GT:e.operators.LT;tt.fail$data((0,e._)`Object.keys(${nt}).length ${it} ${at}`)}};return limitProperties.default=Ye,limitProperties}var required={},hasRequiredRequired;function requireRequired(){if(hasRequiredRequired)return required;hasRequiredRequired=1,Object.defineProperty(required,"__esModule",{value:!0});const e=requireCode(),t=requireCodegen(),Ye=requireUtil(),rt={keyword:"required",type:"object",schemaType:"array",$data:!0,error:{message:({params:{missingProperty:nt}})=>(0,t.str)`must have required property '${nt}'`,params:({params:{missingProperty:nt}})=>(0,t._)`{missingProperty: ${nt}}`},code(nt){const{gen:at,schema:it,schemaCode:ot,data:ct,$data:At,it:Rt}=nt,{opts:qt}=Rt;if(!At&&it.length===0)return;const Ft=it.length>=qt.loopRequired;if(Rt.allErrors?Ut():Ht(),qt.strictRequired){const Gt=nt.parentSchema.properties,{definedProperties:Vt}=nt.it;for(const Zt of it)if((Gt==null?void 0:Gt[Zt])===void 0&&!Vt.has(Zt)){const Xt=Rt.schemaEnv.baseId+Rt.errSchemaPath,Qt=`required property "${Zt}" is not defined at "${Xt}" (strictRequired)`;(0,Ye.checkStrictMode)(Rt,Qt,Rt.opts.strictRequired)}}function Ut(){if(Ft||At)nt.block$data(t.nil,zt);else for(const Gt of it)(0,e.checkReportMissingProp)(nt,Gt)}function Ht(){const Gt=at.let("missing");if(Ft||At){const Vt=at.let("valid",!0);nt.block$data(Vt,()=>Yt(Gt,Vt)),nt.ok(Vt)}else at.if((0,e.checkMissingProp)(nt,it,Gt)),(0,e.reportMissingProp)(nt,Gt),at.else()}function zt(){at.forOf("prop",ot,Gt=>{nt.setParams({missingProperty:Gt}),at.if((0,e.noPropertyInData)(at,ct,Gt,qt.ownProperties),()=>nt.error())})}function Yt(Gt,Vt){nt.setParams({missingProperty:Gt}),at.forOf(Gt,ot,()=>{at.assign(Vt,(0,e.propertyInData)(at,ct,Gt,qt.ownProperties)),at.if((0,t.not)(Vt),()=>{nt.error(),at.break()})},t.nil)}}};return required.default=rt,required}var limitItems={},hasRequiredLimitItems;function requireLimitItems(){if(hasRequiredLimitItems)return limitItems;hasRequiredLimitItems=1,Object.defineProperty(limitItems,"__esModule",{value:!0});const e=requireCodegen(),Ye={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:{message({keyword:tt,schemaCode:rt}){const nt=tt==="maxItems"?"more":"fewer";return(0,e.str)`must NOT have ${nt} than ${rt} items`},params:({schemaCode:tt})=>(0,e._)`{limit: ${tt}}`},code(tt){const{keyword:rt,data:nt,schemaCode:at}=tt,it=rt==="maxItems"?e.operators.GT:e.operators.LT;tt.fail$data((0,e._)`${nt}.length ${it} ${at}`)}};return limitItems.default=Ye,limitItems}var uniqueItems={},equal={},hasRequiredEqual;function requireEqual(){if(hasRequiredEqual)return equal;hasRequiredEqual=1,Object.defineProperty(equal,"__esModule",{value:!0});const e=requireFastDeepEqual();return e.code='require("ajv/dist/runtime/equal").default',equal.default=e,equal}var hasRequiredUniqueItems;function requireUniqueItems(){if(hasRequiredUniqueItems)return uniqueItems;hasRequiredUniqueItems=1,Object.defineProperty(uniqueItems,"__esModule",{value:!0});const e=requireDataType(),t=requireCodegen(),Ye=requireUtil(),tt=requireEqual(),nt={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:{message:({params:{i:at,j:it}})=>(0,t.str)`must NOT have duplicate items (items ## ${it} and ${at} are identical)`,params:({params:{i:at,j:it}})=>(0,t._)`{i: ${at}, j: ${it}}`},code(at){const{gen:it,data:ot,$data:ct,schema:At,parentSchema:Rt,schemaCode:qt,it:Ft}=at;if(!ct&&!At)return;const Ut=it.let("valid"),Ht=Rt.items?(0,e.getSchemaTypes)(Rt.items):[];at.block$data(Ut,zt,(0,t._)`${qt} === false`),at.ok(Ut);function zt(){const Zt=it.let("i",(0,t._)`${ot}.length`),Xt=it.let("j");at.setParams({i:Zt,j:Xt}),it.assign(Ut,!0),it.if((0,t._)`${Zt} > 1`,()=>(Yt()?Gt:Vt)(Zt,Xt))}function Yt(){return Ht.length>0&&!Ht.some(Zt=>Zt==="object"||Zt==="array")}function Gt(Zt,Xt){const Qt=it.name("item"),er=(0,e.checkDataTypes)(Ht,Qt,Ft.opts.strictNumbers,e.DataType.Wrong),nr=it.const("indices",(0,t._)`{}`);it.for((0,t._)`;${Zt}--;`,()=>{it.let(Qt,(0,t._)`${ot}[${Zt}]`),it.if(er,(0,t._)`continue`),Ht.length>1&&it.if((0,t._)`typeof ${Qt} == "string"`,(0,t._)`${Qt} += "_"`),it.if((0,t._)`typeof ${nr}[${Qt}] == "number"`,()=>{it.assign(Xt,(0,t._)`${nr}[${Qt}]`),at.error(),it.assign(Ut,!1).break()}).code((0,t._)`${nr}[${Qt}] = ${Zt}`)})}function Vt(Zt,Xt){const Qt=(0,Ye.useFunc)(it,tt.default),er=it.name("outer");it.label(er).for((0,t._)`;${Zt}--;`,()=>it.for((0,t._)`${Xt} = ${Zt}; ${Xt}--;`,()=>it.if((0,t._)`${Qt}(${ot}[${Zt}], ${ot}[${Xt}])`,()=>{at.error(),it.assign(Ut,!1).break(er)})))}}};return uniqueItems.default=nt,uniqueItems}var _const={},hasRequired_const;function require_const(){if(hasRequired_const)return _const;hasRequired_const=1,Object.defineProperty(_const,"__esModule",{value:!0});const e=requireCodegen(),t=requireUtil(),Ye=requireEqual(),rt={keyword:"const",$data:!0,error:{message:"must be equal to constant",params:({schemaCode:nt})=>(0,e._)`{allowedValue: ${nt}}`},code(nt){const{gen:at,data:it,$data:ot,schemaCode:ct,schema:At}=nt;ot||At&&typeof At=="object"?nt.fail$data((0,e._)`!${(0,t.useFunc)(at,Ye.default)}(${it}, ${ct})`):nt.fail((0,e._)`${At} !== ${it}`)}};return _const.default=rt,_const}var _enum={},hasRequired_enum;function require_enum(){if(hasRequired_enum)return _enum;hasRequired_enum=1,Object.defineProperty(_enum,"__esModule",{value:!0});const e=requireCodegen(),t=requireUtil(),Ye=requireEqual(),rt={keyword:"enum",schemaType:"array",$data:!0,error:{message:"must be equal to one of the allowed values",params:({schemaCode:nt})=>(0,e._)`{allowedValues: ${nt}}`},code(nt){const{gen:at,data:it,$data:ot,schema:ct,schemaCode:At,it:Rt}=nt;if(!ot&&ct.length===0)throw new Error("enum must have non-empty array");const qt=ct.length>=Rt.opts.loopEnum;let Ft;const Ut=()=>Ft??(Ft=(0,t.useFunc)(at,Ye.default));let Ht;if(qt||ot)Ht=at.let("valid"),nt.block$data(Ht,zt);else{if(!Array.isArray(ct))throw new Error("ajv implementation error");const Gt=at.const("vSchema",At);Ht=(0,e.or)(...ct.map((Vt,Zt)=>Yt(Gt,Zt)))}nt.pass(Ht);function zt(){at.assign(Ht,!1),at.forOf("v",At,Gt=>at.if((0,e._)`${Ut()}(${it}, ${Gt})`,()=>at.assign(Ht,!0).break()))}function Yt(Gt,Vt){const Zt=ct[Vt];return typeof Zt=="object"&&Zt!==null?(0,e._)`${Ut()}(${it}, ${Gt}[${Vt}])`:(0,e._)`${it} === ${Zt}`}}};return _enum.default=rt,_enum}var hasRequiredValidation;function requireValidation(){if(hasRequiredValidation)return validation;hasRequiredValidation=1,Object.defineProperty(validation,"__esModule",{value:!0});const e=requireLimitNumber(),t=requireMultipleOf(),Ye=requireLimitLength(),tt=requirePattern(),rt=requireLimitProperties(),nt=requireRequired(),at=requireLimitItems(),it=requireUniqueItems(),ot=require_const(),ct=require_enum(),At=[e.default,t.default,Ye.default,tt.default,rt.default,nt.default,at.default,it.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},ot.default,ct.default];return validation.default=At,validation}var applicator={},additionalItems={},hasRequiredAdditionalItems;function requireAdditionalItems(){if(hasRequiredAdditionalItems)return additionalItems;hasRequiredAdditionalItems=1,Object.defineProperty(additionalItems,"__esModule",{value:!0}),additionalItems.validateAdditionalItems=void 0;const e=requireCodegen(),t=requireUtil(),tt={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:{message:({params:{len:nt}})=>(0,e.str)`must NOT have more than ${nt} items`,params:({params:{len:nt}})=>(0,e._)`{limit: ${nt}}`},code(nt){const{parentSchema:at,it}=nt,{items:ot}=at;if(!Array.isArray(ot)){(0,t.checkStrictMode)(it,'"additionalItems" is ignored when "items" is not an array of schemas');return}rt(nt,ot)}};function rt(nt,at){const{gen:it,schema:ot,data:ct,keyword:At,it:Rt}=nt;Rt.items=!0;const qt=it.const("len",(0,e._)`${ct}.length`);if(ot===!1)nt.setParams({len:at.length}),nt.pass((0,e._)`${qt} <= ${at.length}`);else if(typeof ot=="object"&&!(0,t.alwaysValidSchema)(Rt,ot)){const Ut=it.var("valid",(0,e._)`${qt} <= ${at.length}`);it.if((0,e.not)(Ut),()=>Ft(Ut)),nt.ok(Ut)}function Ft(Ut){it.forRange("i",at.length,qt,Ht=>{nt.subschema({keyword:At,dataProp:Ht,dataPropType:t.Type.Num},Ut),Rt.allErrors||it.if((0,e.not)(Ut),()=>it.break())})}}return additionalItems.validateAdditionalItems=rt,additionalItems.default=tt,additionalItems}var prefixItems={},items={},hasRequiredItems;function requireItems(){if(hasRequiredItems)return items;hasRequiredItems=1,Object.defineProperty(items,"__esModule",{value:!0}),items.validateTuple=void 0;const e=requireCodegen(),t=requireUtil(),Ye=requireCode(),tt={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(nt){const{schema:at,it}=nt;if(Array.isArray(at))return rt(nt,"additionalItems",at);it.items=!0,!(0,t.alwaysValidSchema)(it,at)&&nt.ok((0,Ye.validateArray)(nt))}};function rt(nt,at,it=nt.schema){const{gen:ot,parentSchema:ct,data:At,keyword:Rt,it:qt}=nt;Ht(ct),qt.opts.unevaluated&&it.length&&qt.items!==!0&&(qt.items=t.mergeEvaluated.items(ot,it.length,qt.items));const Ft=ot.name("valid"),Ut=ot.const("len",(0,e._)`${At}.length`);it.forEach((zt,Yt)=>{(0,t.alwaysValidSchema)(qt,zt)||(ot.if((0,e._)`${Ut} > ${Yt}`,()=>nt.subschema({keyword:Rt,schemaProp:Yt,dataProp:Yt},Ft)),nt.ok(Ft))});function Ht(zt){const{opts:Yt,errSchemaPath:Gt}=qt,Vt=it.length,Zt=Vt===zt.minItems&&(Vt===zt.maxItems||zt[at]===!1);if(Yt.strictTuples&&!Zt){const Xt=`"${Rt}" is ${Vt}-tuple, but minItems or maxItems/${at} are not specified or different at path "${Gt}"`;(0,t.checkStrictMode)(qt,Xt,Yt.strictTuples)}}}return items.validateTuple=rt,items.default=tt,items}var hasRequiredPrefixItems;function requirePrefixItems(){if(hasRequiredPrefixItems)return prefixItems;hasRequiredPrefixItems=1,Object.defineProperty(prefixItems,"__esModule",{value:!0});const e=requireItems(),t={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:Ye=>(0,e.validateTuple)(Ye,"items")};return prefixItems.default=t,prefixItems}var items2020={},hasRequiredItems2020;function requireItems2020(){if(hasRequiredItems2020)return items2020;hasRequiredItems2020=1,Object.defineProperty(items2020,"__esModule",{value:!0});const e=requireCodegen(),t=requireUtil(),Ye=requireCode(),tt=requireAdditionalItems(),nt={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:{message:({params:{len:at}})=>(0,e.str)`must NOT have more than ${at} items`,params:({params:{len:at}})=>(0,e._)`{limit: ${at}}`},code(at){const{schema:it,parentSchema:ot,it:ct}=at,{prefixItems:At}=ot;ct.items=!0,!(0,t.alwaysValidSchema)(ct,it)&&(At?(0,tt.validateAdditionalItems)(at,At):at.ok((0,Ye.validateArray)(at)))}};return items2020.default=nt,items2020}var contains={},hasRequiredContains;function requireContains(){if(hasRequiredContains)return contains;hasRequiredContains=1,Object.defineProperty(contains,"__esModule",{value:!0});const e=requireCodegen(),t=requireUtil(),tt={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:{message:({params:{min:rt,max:nt}})=>nt===void 0?(0,e.str)`must contain at least ${rt} valid item(s)`:(0,e.str)`must contain at least ${rt} and no more than ${nt} valid item(s)`,params:({params:{min:rt,max:nt}})=>nt===void 0?(0,e._)`{minContains: ${rt}}`:(0,e._)`{minContains: ${rt}, maxContains: ${nt}}`},code(rt){const{gen:nt,schema:at,parentSchema:it,data:ot,it:ct}=rt;let At,Rt;const{minContains:qt,maxContains:Ft}=it;ct.opts.next?(At=qt===void 0?1:qt,Rt=Ft):At=1;const Ut=nt.const("len",(0,e._)`${ot}.length`);if(rt.setParams({min:At,max:Rt}),Rt===void 0&&At===0){(0,t.checkStrictMode)(ct,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(Rt!==void 0&&At>Rt){(0,t.checkStrictMode)(ct,'"minContains" > "maxContains" is always invalid'),rt.fail();return}if((0,t.alwaysValidSchema)(ct,at)){let Vt=(0,e._)`${Ut} >= ${At}`;Rt!==void 0&&(Vt=(0,e._)`${Vt} && ${Ut} <= ${Rt}`),rt.pass(Vt);return}ct.items=!0;const Ht=nt.name("valid");Rt===void 0&&At===1?Yt(Ht,()=>nt.if(Ht,()=>nt.break())):At===0?(nt.let(Ht,!0),Rt!==void 0&&nt.if((0,e._)`${ot}.length > 0`,zt)):(nt.let(Ht,!1),zt()),rt.result(Ht,()=>rt.reset());function zt(){const Vt=nt.name("_valid"),Zt=nt.let("count",0);Yt(Vt,()=>nt.if(Vt,()=>Gt(Zt)))}function Yt(Vt,Zt){nt.forRange("i",0,Ut,Xt=>{rt.subschema({keyword:"contains",dataProp:Xt,dataPropType:t.Type.Num,compositeRule:!0},Vt),Zt()})}function Gt(Vt){nt.code((0,e._)`${Vt}++`),Rt===void 0?nt.if((0,e._)`${Vt} >= ${At}`,()=>nt.assign(Ht,!0).break()):(nt.if((0,e._)`${Vt} > ${Rt}`,()=>nt.assign(Ht,!1).break()),At===1?nt.assign(Ht,!0):nt.if((0,e._)`${Vt} >= ${At}`,()=>nt.assign(Ht,!0)))}}};return contains.default=tt,contains}var dependencies={},hasRequiredDependencies;function requireDependencies(){return hasRequiredDependencies||(hasRequiredDependencies=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.validateSchemaDeps=e.validatePropertyDeps=e.error=void 0;const t=requireCodegen(),Ye=requireUtil(),tt=requireCode();e.error={message:({params:{property:ot,depsCount:ct,deps:At}})=>{const Rt=ct===1?"property":"properties";return(0,t.str)`must have ${Rt} ${At} when property ${ot} is present`},params:({params:{property:ot,depsCount:ct,deps:At,missingProperty:Rt}})=>(0,t._)`{property: ${ot},
894
894
  missingProperty: ${Rt},
895
895
  depsCount: ${ct},
896
- deps: ${At}}`};const rt={keyword:"dependencies",type:"object",schemaType:"object",error:e.error,code(ot){const[ct,At]=nt(ot);at(ot,ct),it(ot,At)}};function nt({schema:ot}){const ct={},At={};for(const Rt in ot){if(Rt==="__proto__")continue;const qt=Array.isArray(ot[Rt])?ct:At;qt[Rt]=ot[Rt]}return[ct,At]}function at(ot,ct=ot.schema){const{gen:At,data:Rt,it:qt}=ot;if(Object.keys(ct).length===0)return;const Ft=At.let("missing");for(const Ut in ct){const Ht=ct[Ut];if(Ht.length===0)continue;const zt=(0,tt.propertyInData)(At,Rt,Ut,qt.opts.ownProperties);ot.setParams({property:Ut,depsCount:Ht.length,deps:Ht.join(", ")}),qt.allErrors?At.if(zt,()=>{for(const Yt of Ht)(0,tt.checkReportMissingProp)(ot,Yt)}):(At.if((0,t._)`${zt} && (${(0,tt.checkMissingProp)(ot,Ht,Ft)})`),(0,tt.reportMissingProp)(ot,Ft),At.else())}}e.validatePropertyDeps=at;function it(ot,ct=ot.schema){const{gen:At,data:Rt,keyword:qt,it:Ft}=ot,Ut=At.name("valid");for(const Ht in ct)(0,Ye.alwaysValidSchema)(Ft,ct[Ht])||(At.if((0,tt.propertyInData)(At,Rt,Ht,Ft.opts.ownProperties),()=>{const zt=ot.subschema({keyword:qt,schemaProp:Ht},Ut);ot.mergeValidEvaluated(zt,Ut)},()=>At.var(Ut,!0)),ot.ok(Ut))}e.validateSchemaDeps=it,e.default=rt}(dependencies)),dependencies}var propertyNames={},hasRequiredPropertyNames;function requirePropertyNames(){if(hasRequiredPropertyNames)return propertyNames;hasRequiredPropertyNames=1,Object.defineProperty(propertyNames,"__esModule",{value:!0});const e=requireCodegen(),t=requireUtil(),tt={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:{message:"property name must be valid",params:({params:rt})=>(0,e._)`{propertyName: ${rt.propertyName}}`},code(rt){const{gen:nt,schema:at,data:it,it:ot}=rt;if((0,t.alwaysValidSchema)(ot,at))return;const ct=nt.name("valid");nt.forIn("key",it,At=>{rt.setParams({propertyName:At}),rt.subschema({keyword:"propertyNames",data:At,dataTypes:["string"],propertyName:At,compositeRule:!0},ct),nt.if((0,e.not)(ct),()=>{rt.error(!0),ot.allErrors||nt.break()})}),rt.ok(ct)}};return propertyNames.default=tt,propertyNames}var additionalProperties={},hasRequiredAdditionalProperties;function requireAdditionalProperties(){if(hasRequiredAdditionalProperties)return additionalProperties;hasRequiredAdditionalProperties=1,Object.defineProperty(additionalProperties,"__esModule",{value:!0});const e=requireCode(),t=requireCodegen(),Ye=requireNames(),tt=requireUtil(),nt={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:{message:"must NOT have additional properties",params:({params:at})=>(0,t._)`{additionalProperty: ${at.additionalProperty}}`},code(at){const{gen:it,schema:ot,parentSchema:ct,data:At,errsCount:Rt,it:qt}=at;if(!Rt)throw new Error("ajv implementation error");const{allErrors:Ft,opts:Ut}=qt;if(qt.props=!0,Ut.removeAdditional!=="all"&&(0,tt.alwaysValidSchema)(qt,ot))return;const Ht=(0,e.allSchemaProperties)(ct.properties),zt=(0,e.allSchemaProperties)(ct.patternProperties);Yt(),at.ok((0,t._)`${Rt} === ${Ye.default.errors}`);function Yt(){it.forIn("key",At,Qt=>{!Ht.length&&!zt.length?Zt(Qt):it.if(Gt(Qt),()=>Zt(Qt))})}function Gt(Qt){let er;if(Ht.length>8){const nr=(0,tt.schemaRefOrVal)(qt,ct.properties,"properties");er=(0,e.isOwnProperty)(it,nr,Qt)}else Ht.length?er=(0,t.or)(...Ht.map(nr=>(0,t._)`${Qt} === ${nr}`)):er=t.nil;return zt.length&&(er=(0,t.or)(er,...zt.map(nr=>(0,t._)`${(0,e.usePattern)(at,nr)}.test(${Qt})`))),(0,t.not)(er)}function Vt(Qt){it.code((0,t._)`delete ${At}[${Qt}]`)}function Zt(Qt){if(Ut.removeAdditional==="all"||Ut.removeAdditional&&ot===!1){Vt(Qt);return}if(ot===!1){at.setParams({additionalProperty:Qt}),at.error(),Ft||it.break();return}if(typeof ot=="object"&&!(0,tt.alwaysValidSchema)(qt,ot)){const er=it.name("valid");Ut.removeAdditional==="failing"?(Xt(Qt,er,!1),it.if((0,t.not)(er),()=>{at.reset(),Vt(Qt)})):(Xt(Qt,er),Ft||it.if((0,t.not)(er),()=>it.break()))}}function Xt(Qt,er,nr){const ar={keyword:"additionalProperties",dataProp:Qt,dataPropType:tt.Type.Str};nr===!1&&Object.assign(ar,{compositeRule:!0,createErrors:!1,allErrors:!1}),at.subschema(ar,er)}}};return additionalProperties.default=nt,additionalProperties}var properties$1={},hasRequiredProperties;function requireProperties(){if(hasRequiredProperties)return properties$1;hasRequiredProperties=1,Object.defineProperty(properties$1,"__esModule",{value:!0});const e=requireValidate(),t=requireCode(),Ye=requireUtil(),tt=requireAdditionalProperties(),rt={keyword:"properties",type:"object",schemaType:"object",code(nt){const{gen:at,schema:it,parentSchema:ot,data:ct,it:At}=nt;At.opts.removeAdditional==="all"&&ot.additionalProperties===void 0&&tt.default.code(new e.KeywordCxt(At,tt.default,"additionalProperties"));const Rt=(0,t.allSchemaProperties)(it);for(const zt of Rt)At.definedProperties.add(zt);At.opts.unevaluated&&Rt.length&&At.props!==!0&&(At.props=Ye.mergeEvaluated.props(at,(0,Ye.toHash)(Rt),At.props));const qt=Rt.filter(zt=>!(0,Ye.alwaysValidSchema)(At,it[zt]));if(qt.length===0)return;const Ft=at.name("valid");for(const zt of qt)Ut(zt)?Ht(zt):(at.if((0,t.propertyInData)(at,ct,zt,At.opts.ownProperties)),Ht(zt),At.allErrors||at.else().var(Ft,!0),at.endIf()),nt.it.definedProperties.add(zt),nt.ok(Ft);function Ut(zt){return At.opts.useDefaults&&!At.compositeRule&&it[zt].default!==void 0}function Ht(zt){nt.subschema({keyword:"properties",schemaProp:zt,dataProp:zt},Ft)}}};return properties$1.default=rt,properties$1}var patternProperties={},hasRequiredPatternProperties;function requirePatternProperties(){if(hasRequiredPatternProperties)return patternProperties;hasRequiredPatternProperties=1,Object.defineProperty(patternProperties,"__esModule",{value:!0});const e=requireCode(),t=requireCodegen(),Ye=requireUtil(),tt=requireUtil(),rt={keyword:"patternProperties",type:"object",schemaType:"object",code(nt){const{gen:at,schema:it,data:ot,parentSchema:ct,it:At}=nt,{opts:Rt}=At,qt=(0,e.allSchemaProperties)(it),Ft=qt.filter(Zt=>(0,Ye.alwaysValidSchema)(At,it[Zt]));if(qt.length===0||Ft.length===qt.length&&(!At.opts.unevaluated||At.props===!0))return;const Ut=Rt.strictSchema&&!Rt.allowMatchingProperties&&ct.properties,Ht=at.name("valid");At.props!==!0&&!(At.props instanceof t.Name)&&(At.props=(0,tt.evaluatedPropsToName)(at,At.props));const{props:zt}=At;Yt();function Yt(){for(const Zt of qt)Ut&&Gt(Zt),At.allErrors?Vt(Zt):(at.var(Ht,!0),Vt(Zt),at.if(Ht))}function Gt(Zt){for(const Xt in Ut)new RegExp(Zt).test(Xt)&&(0,Ye.checkStrictMode)(At,`property ${Xt} matches pattern ${Zt} (use allowMatchingProperties)`)}function Vt(Zt){at.forIn("key",ot,Xt=>{at.if((0,t._)`${(0,e.usePattern)(nt,Zt)}.test(${Xt})`,()=>{const Qt=Ft.includes(Zt);Qt||nt.subschema({keyword:"patternProperties",schemaProp:Zt,dataProp:Xt,dataPropType:tt.Type.Str},Ht),At.opts.unevaluated&&zt!==!0?at.assign((0,t._)`${zt}[${Xt}]`,!0):!Qt&&!At.allErrors&&at.if((0,t.not)(Ht),()=>at.break())})})}}};return patternProperties.default=rt,patternProperties}var not={},hasRequiredNot;function requireNot(){if(hasRequiredNot)return not;hasRequiredNot=1,Object.defineProperty(not,"__esModule",{value:!0});const e=requireUtil(),t={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(Ye){const{gen:tt,schema:rt,it:nt}=Ye;if((0,e.alwaysValidSchema)(nt,rt)){Ye.fail();return}const at=tt.name("valid");Ye.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},at),Ye.failResult(at,()=>Ye.reset(),()=>Ye.error())},error:{message:"must NOT be valid"}};return not.default=t,not}var anyOf={},hasRequiredAnyOf;function requireAnyOf(){if(hasRequiredAnyOf)return anyOf;hasRequiredAnyOf=1,Object.defineProperty(anyOf,"__esModule",{value:!0});const t={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:requireCode().validateUnion,error:{message:"must match a schema in anyOf"}};return anyOf.default=t,anyOf}var oneOf={},hasRequiredOneOf;function requireOneOf(){if(hasRequiredOneOf)return oneOf;hasRequiredOneOf=1,Object.defineProperty(oneOf,"__esModule",{value:!0});const e=requireCodegen(),t=requireUtil(),tt={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:{message:"must match exactly one schema in oneOf",params:({params:rt})=>(0,e._)`{passingSchemas: ${rt.passing}}`},code(rt){const{gen:nt,schema:at,parentSchema:it,it:ot}=rt;if(!Array.isArray(at))throw new Error("ajv implementation error");if(ot.opts.discriminator&&it.discriminator)return;const ct=at,At=nt.let("valid",!1),Rt=nt.let("passing",null),qt=nt.name("_valid");rt.setParams({passing:Rt}),nt.block(Ft),rt.result(At,()=>rt.reset(),()=>rt.error(!0));function Ft(){ct.forEach((Ut,Ht)=>{let zt;(0,t.alwaysValidSchema)(ot,Ut)?nt.var(qt,!0):zt=rt.subschema({keyword:"oneOf",schemaProp:Ht,compositeRule:!0},qt),Ht>0&&nt.if((0,e._)`${qt} && ${At}`).assign(At,!1).assign(Rt,(0,e._)`[${Rt}, ${Ht}]`).else(),nt.if(qt,()=>{nt.assign(At,!0),nt.assign(Rt,Ht),zt&&rt.mergeEvaluated(zt,e.Name)})})}}};return oneOf.default=tt,oneOf}var allOf={},hasRequiredAllOf;function requireAllOf(){if(hasRequiredAllOf)return allOf;hasRequiredAllOf=1,Object.defineProperty(allOf,"__esModule",{value:!0});const e=requireUtil(),t={keyword:"allOf",schemaType:"array",code(Ye){const{gen:tt,schema:rt,it:nt}=Ye;if(!Array.isArray(rt))throw new Error("ajv implementation error");const at=tt.name("valid");rt.forEach((it,ot)=>{if((0,e.alwaysValidSchema)(nt,it))return;const ct=Ye.subschema({keyword:"allOf",schemaProp:ot},at);Ye.ok(at),Ye.mergeEvaluated(ct)})}};return allOf.default=t,allOf}var _if={},hasRequired_if;function require_if(){if(hasRequired_if)return _if;hasRequired_if=1,Object.defineProperty(_if,"__esModule",{value:!0});const e=requireCodegen(),t=requireUtil(),tt={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:{message:({params:nt})=>(0,e.str)`must match "${nt.ifClause}" schema`,params:({params:nt})=>(0,e._)`{failingKeyword: ${nt.ifClause}}`},code(nt){const{gen:at,parentSchema:it,it:ot}=nt;it.then===void 0&&it.else===void 0&&(0,t.checkStrictMode)(ot,'"if" without "then" and "else" is ignored');const ct=rt(ot,"then"),At=rt(ot,"else");if(!ct&&!At)return;const Rt=at.let("valid",!0),qt=at.name("_valid");if(Ft(),nt.reset(),ct&&At){const Ht=at.let("ifClause");nt.setParams({ifClause:Ht}),at.if(qt,Ut("then",Ht),Ut("else",Ht))}else ct?at.if(qt,Ut("then")):at.if((0,e.not)(qt),Ut("else"));nt.pass(Rt,()=>nt.error(!0));function Ft(){const Ht=nt.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},qt);nt.mergeEvaluated(Ht)}function Ut(Ht,zt){return()=>{const Yt=nt.subschema({keyword:Ht},qt);at.assign(Rt,qt),nt.mergeValidEvaluated(Yt,Rt),zt?at.assign(zt,(0,e._)`${Ht}`):nt.setParams({ifClause:Ht})}}}};function rt(nt,at){const it=nt.schema[at];return it!==void 0&&!(0,t.alwaysValidSchema)(nt,it)}return _if.default=tt,_if}var thenElse={},hasRequiredThenElse;function requireThenElse(){if(hasRequiredThenElse)return thenElse;hasRequiredThenElse=1,Object.defineProperty(thenElse,"__esModule",{value:!0});const e=requireUtil(),t={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:Ye,parentSchema:tt,it:rt}){tt.if===void 0&&(0,e.checkStrictMode)(rt,`"${Ye}" without "if" is ignored`)}};return thenElse.default=t,thenElse}var hasRequiredApplicator;function requireApplicator(){if(hasRequiredApplicator)return applicator;hasRequiredApplicator=1,Object.defineProperty(applicator,"__esModule",{value:!0});const e=requireAdditionalItems(),t=requirePrefixItems(),Ye=requireItems(),tt=requireItems2020(),rt=requireContains(),nt=requireDependencies(),at=requirePropertyNames(),it=requireAdditionalProperties(),ot=requireProperties(),ct=requirePatternProperties(),At=requireNot(),Rt=requireAnyOf(),qt=requireOneOf(),Ft=requireAllOf(),Ut=require_if(),Ht=requireThenElse();function zt(Yt=!1){const Gt=[At.default,Rt.default,qt.default,Ft.default,Ut.default,Ht.default,at.default,it.default,nt.default,ot.default,ct.default];return Yt?Gt.push(t.default,tt.default):Gt.push(e.default,Ye.default),Gt.push(rt.default),Gt}return applicator.default=zt,applicator}var format$1={},format={},hasRequiredFormat$1;function requireFormat$1(){if(hasRequiredFormat$1)return format;hasRequiredFormat$1=1,Object.defineProperty(format,"__esModule",{value:!0});const e=requireCodegen(),Ye={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:{message:({schemaCode:tt})=>(0,e.str)`must match format "${tt}"`,params:({schemaCode:tt})=>(0,e._)`{format: ${tt}}`},code(tt,rt){const{gen:nt,data:at,$data:it,schema:ot,schemaCode:ct,it:At}=tt,{opts:Rt,errSchemaPath:qt,schemaEnv:Ft,self:Ut}=At;if(!Rt.validateFormats)return;it?Ht():zt();function Ht(){const Yt=nt.scopeValue("formats",{ref:Ut.formats,code:Rt.code.formats}),Gt=nt.const("fDef",(0,e._)`${Yt}[${ct}]`),Vt=nt.let("fType"),Zt=nt.let("format");nt.if((0,e._)`typeof ${Gt} == "object" && !(${Gt} instanceof RegExp)`,()=>nt.assign(Vt,(0,e._)`${Gt}.type || "string"`).assign(Zt,(0,e._)`${Gt}.validate`),()=>nt.assign(Vt,(0,e._)`"string"`).assign(Zt,Gt)),tt.fail$data((0,e.or)(Xt(),Qt()));function Xt(){return Rt.strictSchema===!1?e.nil:(0,e._)`${ct} && !${Zt}`}function Qt(){const er=Ft.$async?(0,e._)`(${Gt}.async ? await ${Zt}(${at}) : ${Zt}(${at}))`:(0,e._)`${Zt}(${at})`,nr=(0,e._)`(typeof ${Zt} == "function" ? ${er} : ${Zt}.test(${at}))`;return(0,e._)`${Zt} && ${Zt} !== true && ${Vt} === ${rt} && !${nr}`}}function zt(){const Yt=Ut.formats[ot];if(!Yt){Xt();return}if(Yt===!0)return;const[Gt,Vt,Zt]=Qt(Yt);Gt===rt&&tt.pass(er());function Xt(){if(Rt.strictSchema===!1){Ut.logger.warn(nr());return}throw new Error(nr());function nr(){return`unknown format "${ot}" ignored in schema at path "${qt}"`}}function Qt(nr){const ar=nr instanceof RegExp?(0,e.regexpCode)(nr):Rt.code.formats?(0,e._)`${Rt.code.formats}${(0,e.getProperty)(ot)}`:void 0,sr=nt.scopeValue("formats",{key:ot,ref:nr,code:ar});return typeof nr=="object"&&!(nr instanceof RegExp)?[nr.type||"string",nr.validate,(0,e._)`${sr}.validate`]:["string",nr,sr]}function er(){if(typeof Yt=="object"&&!(Yt instanceof RegExp)&&Yt.async){if(!Ft.$async)throw new Error("async format in sync schema");return(0,e._)`await ${Zt}(${at})`}return typeof Vt=="function"?(0,e._)`${Zt}(${at})`:(0,e._)`${Zt}.test(${at})`}}}};return format.default=Ye,format}var hasRequiredFormat;function requireFormat(){if(hasRequiredFormat)return format$1;hasRequiredFormat=1,Object.defineProperty(format$1,"__esModule",{value:!0});const t=[requireFormat$1().default];return format$1.default=t,format$1}var metadata={},hasRequiredMetadata;function requireMetadata(){return hasRequiredMetadata||(hasRequiredMetadata=1,Object.defineProperty(metadata,"__esModule",{value:!0}),metadata.contentVocabulary=metadata.metadataVocabulary=void 0,metadata.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"],metadata.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]),metadata}var hasRequiredDraft7;function requireDraft7(){if(hasRequiredDraft7)return draft7;hasRequiredDraft7=1,Object.defineProperty(draft7,"__esModule",{value:!0});const e=requireCore(),t=requireValidation(),Ye=requireApplicator(),tt=requireFormat(),rt=requireMetadata(),nt=[e.default,t.default,(0,Ye.default)(),tt.default,rt.metadataVocabulary,rt.contentVocabulary];return draft7.default=nt,draft7}var discriminator={},types={},hasRequiredTypes;function requireTypes(){if(hasRequiredTypes)return types;hasRequiredTypes=1,Object.defineProperty(types,"__esModule",{value:!0}),types.DiscrError=void 0;var e;return function(t){t.Tag="tag",t.Mapping="mapping"}(e||(types.DiscrError=e={})),types}var hasRequiredDiscriminator;function requireDiscriminator(){if(hasRequiredDiscriminator)return discriminator;hasRequiredDiscriminator=1,Object.defineProperty(discriminator,"__esModule",{value:!0});const e=requireCodegen(),t=requireTypes(),Ye=requireCompile(),tt=requireRef_error(),rt=requireUtil(),at={keyword:"discriminator",type:"object",schemaType:"object",error:{message:({params:{discrError:it,tagName:ot}})=>it===t.DiscrError.Tag?`tag "${ot}" must be string`:`value of tag "${ot}" must be in oneOf`,params:({params:{discrError:it,tag:ot,tagName:ct}})=>(0,e._)`{error: ${it}, tag: ${ct}, tagValue: ${ot}}`},code(it){const{gen:ot,data:ct,schema:At,parentSchema:Rt,it:qt}=it,{oneOf:Ft}=Rt;if(!qt.opts.discriminator)throw new Error("discriminator: requires discriminator option");const Ut=At.propertyName;if(typeof Ut!="string")throw new Error("discriminator: requires propertyName");if(At.mapping)throw new Error("discriminator: mapping is not supported");if(!Ft)throw new Error("discriminator: requires oneOf keyword");const Ht=ot.let("valid",!1),zt=ot.const("tag",(0,e._)`${ct}${(0,e.getProperty)(Ut)}`);ot.if((0,e._)`typeof ${zt} == "string"`,()=>Yt(),()=>it.error(!1,{discrError:t.DiscrError.Tag,tag:zt,tagName:Ut})),it.ok(Ht);function Yt(){const Zt=Vt();ot.if(!1);for(const Xt in Zt)ot.elseIf((0,e._)`${zt} === ${Xt}`),ot.assign(Ht,Gt(Zt[Xt]));ot.else(),it.error(!1,{discrError:t.DiscrError.Mapping,tag:zt,tagName:Ut}),ot.endIf()}function Gt(Zt){const Xt=ot.name("valid"),Qt=it.subschema({keyword:"oneOf",schemaProp:Zt},Xt);return it.mergeEvaluated(Qt,e.Name),Xt}function Vt(){var Zt;const Xt={},Qt=nr(Rt);let er=!0;for(let lr=0;lr<Ft.length;lr++){let fr=Ft[lr];if(fr!=null&&fr.$ref&&!(0,rt.schemaHasRulesButRef)(fr,qt.self.RULES)){const dr=fr.$ref;if(fr=Ye.resolveRef.call(qt.self,qt.schemaEnv.root,qt.baseId,dr),fr instanceof Ye.SchemaEnv&&(fr=fr.schema),fr===void 0)throw new tt.default(qt.opts.uriResolver,qt.baseId,dr)}const gr=(Zt=fr==null?void 0:fr.properties)===null||Zt===void 0?void 0:Zt[Ut];if(typeof gr!="object")throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${Ut}"`);er=er&&(Qt||nr(fr)),ar(gr,lr)}if(!er)throw new Error(`discriminator: "${Ut}" must be required`);return Xt;function nr({required:lr}){return Array.isArray(lr)&&lr.includes(Ut)}function ar(lr,fr){if(lr.const)sr(lr.const,fr);else if(lr.enum)for(const gr of lr.enum)sr(gr,fr);else throw new Error(`discriminator: "properties/${Ut}" must have "const" or "enum"`)}function sr(lr,fr){if(typeof lr!="string"||lr in Xt)throw new Error(`discriminator: "${Ut}" values must be unique strings`);Xt[lr]=fr}}}};return discriminator.default=at,discriminator}const $schema="http://json-schema.org/draft-07/schema#",$id="http://json-schema.org/draft-07/schema#",title="Core schema meta-schema",definitions={schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},type=["object","boolean"],properties={$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:!0,readOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:!0},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:!0,enum:{type:"array",items:!0,minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},require$$3={$schema,$id,title,definitions,type,properties,default:!0};var hasRequiredAjv;function requireAjv(){return hasRequiredAjv||(hasRequiredAjv=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.MissingRefError=t.ValidationError=t.CodeGen=t.Name=t.nil=t.stringify=t.str=t._=t.KeywordCxt=t.Ajv=void 0;const Ye=requireCore$1(),tt=requireDraft7(),rt=requireDiscriminator(),nt=require$$3,at=["/properties"],it="http://json-schema.org/draft-07/schema";class ot extends Ye.default{_addVocabularies(){super._addVocabularies(),tt.default.forEach(Ut=>this.addVocabulary(Ut)),this.opts.discriminator&&this.addKeyword(rt.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;const Ut=this.opts.$data?this.$dataMetaSchema(nt,at):nt;this.addMetaSchema(Ut,it,!1),this.refs["http://json-schema.org/schema"]=it}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(it)?it:void 0)}}t.Ajv=ot,e.exports=t=ot,e.exports.Ajv=ot,Object.defineProperty(t,"__esModule",{value:!0}),t.default=ot;var ct=requireValidate();Object.defineProperty(t,"KeywordCxt",{enumerable:!0,get:function(){return ct.KeywordCxt}});var At=requireCodegen();Object.defineProperty(t,"_",{enumerable:!0,get:function(){return At._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return At.str}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return At.stringify}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return At.nil}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return At.Name}}),Object.defineProperty(t,"CodeGen",{enumerable:!0,get:function(){return At.CodeGen}});var Rt=requireValidation_error();Object.defineProperty(t,"ValidationError",{enumerable:!0,get:function(){return Rt.default}});var qt=requireRef_error();Object.defineProperty(t,"MissingRefError",{enumerable:!0,get:function(){return qt.default}})}(ajv,ajv.exports)),ajv.exports}var ajvExports=requireAjv();const Ajv=getDefaultExportFromCjs(ajvExports);var dist={exports:{}},formats={},hasRequiredFormats;function requireFormats(){return hasRequiredFormats||(hasRequiredFormats=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.formatNames=e.fastFormats=e.fullFormats=void 0;function t(ar,sr){return{validate:ar,compare:sr}}e.fullFormats={date:t(nt,at),time:t(ot,ct),"date-time":t(Rt,qt),duration:/^P(?!$)((\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+S)?)?|(\d+W)?)$/,uri:Ht,"uri-reference":/^(?:[a-z][a-z0-9+\-.]*:)?(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'"()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\?(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,"uri-template":/^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?)*\})*$/i,url:/^(?:https?|ftp):\/\/(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)(?:\.(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)*(?:\.(?:[a-z\u{00a1}-\u{ffff}]{2,})))(?::\d{2,5})?(?:\/[^\s]*)?$/iu,email:/^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,hostname:/^(?=.{1,253}\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\.?$/i,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)$/,ipv6:/^((([0-9a-f]{1,4}:){7}([0-9a-f]{1,4}|:))|(([0-9a-f]{1,4}:){6}(:[0-9a-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){5}(((:[0-9a-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){4}(((:[0-9a-f]{1,4}){1,3})|((:[0-9a-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){3}(((:[0-9a-f]{1,4}){1,4})|((:[0-9a-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){2}(((:[0-9a-f]{1,4}){1,5})|((:[0-9a-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){1}(((:[0-9a-f]{1,4}){1,6})|((:[0-9a-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9a-f]{1,4}){1,7})|((:[0-9a-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))$/i,regex:nr,uuid:/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,"json-pointer":/^(?:\/(?:[^~/]|~0|~1)*)*$/,"json-pointer-uri-fragment":/^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i,"relative-json-pointer":/^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/,byte:Yt,int32:{type:"number",validate:Zt},int64:{type:"number",validate:Xt},float:{type:"number",validate:Qt},double:{type:"number",validate:Qt},password:!0,binary:!0},e.fastFormats={...e.fullFormats,date:t(/^\d\d\d\d-[0-1]\d-[0-3]\d$/,at),time:t(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,ct),"date-time":t(/^\d\d\d\d-[0-1]\d-[0-3]\d[t\s](?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,qt),uri:/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/)?[^\s]*$/i,"uri-reference":/^(?:(?:[a-z][a-z0-9+\-.]*:)?\/?\/)?(?:[^\\\s#][^\s#]*)?(?:#[^\\\s]*)?$/i,email:/^[a-z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i},e.formatNames=Object.keys(e.fullFormats);function Ye(ar){return ar%4===0&&(ar%100!==0||ar%400===0)}const tt=/^(\d\d\d\d)-(\d\d)-(\d\d)$/,rt=[0,31,28,31,30,31,30,31,31,30,31,30,31];function nt(ar){const sr=tt.exec(ar);if(!sr)return!1;const lr=+sr[1],fr=+sr[2],gr=+sr[3];return fr>=1&&fr<=12&&gr>=1&&gr<=(fr===2&&Ye(lr)?29:rt[fr])}function at(ar,sr){if(ar&&sr)return ar>sr?1:ar<sr?-1:0}const it=/^(\d\d):(\d\d):(\d\d)(\.\d+)?(z|[+-]\d\d(?::?\d\d)?)?$/i;function ot(ar,sr){const lr=it.exec(ar);if(!lr)return!1;const fr=+lr[1],gr=+lr[2],dr=+lr[3],vr=lr[5];return(fr<=23&&gr<=59&&dr<=59||fr===23&&gr===59&&dr===60)&&(!sr||vr!=="")}function ct(ar,sr){if(!(ar&&sr))return;const lr=it.exec(ar),fr=it.exec(sr);if(lr&&fr)return ar=lr[1]+lr[2]+lr[3]+(lr[4]||""),sr=fr[1]+fr[2]+fr[3]+(fr[4]||""),ar>sr?1:ar<sr?-1:0}const At=/t|\s/i;function Rt(ar){const sr=ar.split(At);return sr.length===2&&nt(sr[0])&&ot(sr[1],!0)}function qt(ar,sr){if(!(ar&&sr))return;const[lr,fr]=ar.split(At),[gr,dr]=sr.split(At),vr=at(lr,gr);if(vr!==void 0)return vr||ct(fr,dr)}const Ft=/\/|:/,Ut=/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i;function Ht(ar){return Ft.test(ar)&&Ut.test(ar)}const zt=/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/gm;function Yt(ar){return zt.lastIndex=0,zt.test(ar)}const Gt=-2147483648,Vt=2**31-1;function Zt(ar){return Number.isInteger(ar)&&ar<=Vt&&ar>=Gt}function Xt(ar){return Number.isInteger(ar)}function Qt(){return!0}const er=/[^\\]\\Z/;function nr(ar){if(er.test(ar))return!1;try{return new RegExp(ar),!0}catch{return!1}}}(formats)),formats}var limit={},hasRequiredLimit;function requireLimit(){return hasRequiredLimit||(hasRequiredLimit=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.formatLimitDefinition=void 0;const t=requireAjv(),Ye=requireCodegen(),tt=Ye.operators,rt={formatMaximum:{okStr:"<=",ok:tt.LTE,fail:tt.GT},formatMinimum:{okStr:">=",ok:tt.GTE,fail:tt.LT},formatExclusiveMaximum:{okStr:"<",ok:tt.LT,fail:tt.GTE},formatExclusiveMinimum:{okStr:">",ok:tt.GT,fail:tt.LTE}},nt={message:({keyword:it,schemaCode:ot})=>Ye.str`should be ${rt[it].okStr} ${ot}`,params:({keyword:it,schemaCode:ot})=>Ye._`{comparison: ${rt[it].okStr}, limit: ${ot}}`};e.formatLimitDefinition={keyword:Object.keys(rt),type:"string",schemaType:"string",$data:!0,error:nt,code(it){const{gen:ot,data:ct,schemaCode:At,keyword:Rt,it:qt}=it,{opts:Ft,self:Ut}=qt;if(!Ft.validateFormats)return;const Ht=new t.KeywordCxt(qt,Ut.RULES.all.format.definition,"format");Ht.$data?zt():Yt();function zt(){const Vt=ot.scopeValue("formats",{ref:Ut.formats,code:Ft.code.formats}),Zt=ot.const("fmt",Ye._`${Vt}[${Ht.schemaCode}]`);it.fail$data(Ye.or(Ye._`typeof ${Zt} != "object"`,Ye._`${Zt} instanceof RegExp`,Ye._`typeof ${Zt}.compare != "function"`,Gt(Zt)))}function Yt(){const Vt=Ht.schema,Zt=Ut.formats[Vt];if(!Zt||Zt===!0)return;if(typeof Zt!="object"||Zt instanceof RegExp||typeof Zt.compare!="function")throw new Error(`"${Rt}": format "${Vt}" does not define "compare" function`);const Xt=ot.scopeValue("formats",{key:Vt,ref:Zt,code:Ft.code.formats?Ye._`${Ft.code.formats}${Ye.getProperty(Vt)}`:void 0});it.fail$data(Gt(Xt))}function Gt(Vt){return Ye._`${Vt}.compare(${ct}, ${At}) ${rt[Rt].fail} 0`}},dependencies:["format"]};const at=it=>(it.addKeyword(e.formatLimitDefinition),it);e.default=at}(limit)),limit}var hasRequiredDist;function requireDist(){return hasRequiredDist||(hasRequiredDist=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});const Ye=requireFormats(),tt=requireLimit(),rt=requireCodegen(),nt=new rt.Name("fullFormats"),at=new rt.Name("fastFormats"),it=(ct,At={keywords:!0})=>{if(Array.isArray(At))return ot(ct,At,Ye.fullFormats,nt),ct;const[Rt,qt]=At.mode==="fast"?[Ye.fastFormats,at]:[Ye.fullFormats,nt],Ft=At.formats||Ye.formatNames;return ot(ct,Ft,Rt,qt),At.keywords&&tt.default(ct),ct};it.get=(ct,At="full")=>{const qt=(At==="fast"?Ye.fastFormats:Ye.fullFormats)[ct];if(!qt)throw new Error(`Unknown format "${ct}"`);return qt};function ot(ct,At,Rt,qt){var Ft,Ut;(Ft=(Ut=ct.opts.code).formats)!==null&&Ft!==void 0||(Ut.formats=rt._`require("ajv-formats/dist/formats").${qt}`);for(const Ht of At)ct.addFormat(Ht,Rt[Ht])}e.exports=t=it,Object.defineProperty(t,"__esModule",{value:!0}),t.default=it}(dist,dist.exports)),dist.exports}var distExports=requireDist();const addFormats=getDefaultExportFromCjs(distExports),AJV_CONFIG={allErrors:!0,multipleOfPrecision:8,strict:!1,verbose:!0,discriminator:!1},COLOR_FORMAT_REGEX=/^(#?([0-9A-Fa-f]{3}){1,2}\b|aqua|black|blue|fuchsia|gray|green|lime|maroon|navy|olive|orange|purple|red|silver|teal|white|yellow|(rgb\(\s*\b([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\b\s*,\s*\b([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\b\s*,\s*\b([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\b\s*\))|(rgb\(\s*(\d?\d%|100%)+\s*,\s*(\d?\d%|100%)+\s*,\s*(\d?\d%|100%)+\s*\)))$/,DATA_URL_FORMAT_REGEX=/^data:([a-z]+\/[a-z0-9-+.]+)?;(?:name=(.*);)?base64,(.*)$/;function createAjvInstance(e,t,Ye={},tt,rt=Ajv){const nt=new rt({...AJV_CONFIG,...Ye});return tt?addFormats(nt,tt):tt!==!1&&addFormats(nt),nt.addFormat("data-url",DATA_URL_FORMAT_REGEX),nt.addFormat("color",COLOR_FORMAT_REGEX),nt.addKeyword(ADDITIONAL_PROPERTY_FLAG),nt.addKeyword(RJSF_ADDITIONAL_PROPERTIES_FLAG),Array.isArray(e)&&nt.addMetaSchema(e),isObject(t)&&Object.keys(t).forEach(at=>{nt.addFormat(at,t[at])}),nt}function transformRJSFValidationErrors(e=[],t){return e.map(Ye=>{var tt;const{instancePath:rt,keyword:nt,params:at,schemaPath:it,parentSchema:ot,...ct}=Ye;let{message:At=""}=ct,Rt=rt.replace(/\//g,"."),qt=`${Rt} ${At}`.trim();const Ft=[...((tt=at.deps)===null||tt===void 0?void 0:tt.split(", "))||[],at.missingProperty,at.property].filter(Ut=>Ut);if(Ft.length>0)Ft.forEach(Ut=>{const Ht=Rt?`${Rt}.${Ut}`:Ut;let zt=getUiOptions(get(t,`${Ht.replace(/^\./,"")}`)).title;if(zt===void 0){const Yt=it.replace(/\/properties\//g,"/").split("/").slice(1,-1).concat([Ut]);zt=getUiOptions(get(t,Yt)).title}if(zt)At=At.replace(`'${Ut}'`,`'${zt}'`);else{const Yt=get(ot,[PROPERTIES_KEY,Ut,"title"]);Yt&&(At=At.replace(`'${Ut}'`,`'${Yt}'`))}}),qt=At;else{const Ut=getUiOptions(get(t,`${Rt.replace(/^\./,"")}`)).title;if(Ut)qt=`'${Ut}' ${At}`.trim();else{const Ht=ot==null?void 0:ot.title;Ht&&(qt=`'${Ht}' ${At}`.trim())}}return"missingProperty"in at&&(Rt=Rt?`${Rt}.${at.missingProperty}`:at.missingProperty),{name:nt,property:Rt,message:At,params:at,stack:qt,schemaPath:it}})}function processRawValidationErrors(e,t,Ye,tt,rt,nt,at){const{validationError:it}=t;let ot=transformRJSFValidationErrors(t.errors,at);it&&(ot=[...ot,{stack:it.message}]),typeof nt=="function"&&(ot=nt(ot,at));let ct=toErrorSchema(ot);if(it&&(ct={...ct,$schema:{__errors:[it.message]}}),typeof rt!="function")return{errors:ot,errorSchema:ct};const At=getDefaultFormState(e,tt,Ye,tt,!0),Rt=rt(At,createErrorHandler(At),at),qt=unwrapErrorHandler(Rt);return validationDataMerge({errors:ot,errorSchema:ct},qt)}class AJV8Validator{constructor(t,Ye){const{additionalMetaSchemas:tt,customFormats:rt,ajvOptionsOverrides:nt,ajvFormatOptions:at,AjvClass:it}=t;this.ajv=createAjvInstance(tt,rt,nt,at,it),this.localizer=Ye}reset(){this.ajv.removeSchema()}toErrorList(t,Ye=[]){return toErrorList(t,Ye)}rawValidation(t,Ye){var tt,rt;let nt,at;t[ID_KEY]&&(at=this.ajv.getSchema(t[ID_KEY]));try{at===void 0&&(at=this.ajv.compile(t)),at(Ye)}catch(ot){nt=ot}let it;return at&&(typeof this.localizer=="function"&&(((tt=at.errors)!==null&&tt!==void 0?tt:[]).forEach(ot=>{var ct;["missingProperty","property"].forEach(At=>{var Rt;!((Rt=ot.params)===null||Rt===void 0)&&Rt[At]&&(ot.params[At]=`'${ot.params[At]}'`)}),!((ct=ot.params)===null||ct===void 0)&&ct.deps&&(ot.params.deps=ot.params.deps.split(", ").map(At=>`'${At}'`).join(", "))}),this.localizer(at.errors),((rt=at.errors)!==null&&rt!==void 0?rt:[]).forEach(ot=>{var ct;["missingProperty","property"].forEach(At=>{var Rt;!((Rt=ot.params)===null||Rt===void 0)&&Rt[At]&&(ot.params[At]=ot.params[At].slice(1,-1))}),!((ct=ot.params)===null||ct===void 0)&&ct.deps&&(ot.params.deps=ot.params.deps.split(", ").map(At=>At.slice(1,-1)).join(", "))})),it=at.errors||void 0,at.errors=null),{errors:it,validationError:nt}}validateFormData(t,Ye,tt,rt,nt){const at=this.rawValidation(Ye,t);return processRawValidationErrors(this,at,t,Ye,tt,rt,nt)}handleSchemaUpdate(t){var Ye,tt;const rt=(Ye=t[ID_KEY])!==null&&Ye!==void 0?Ye:ROOT_SCHEMA_PREFIX;this.ajv.getSchema(rt)===void 0?this.ajv.addSchema(t,rt):deepEquals(t,(tt=this.ajv.getSchema(rt))===null||tt===void 0?void 0:tt.schema)||(this.ajv.removeSchema(rt),this.ajv.addSchema(t,rt))}isValid(t,Ye,tt){var rt;try{this.handleSchemaUpdate(tt);const nt=withIdRefPrefix(t),at=(rt=nt[ID_KEY])!==null&&rt!==void 0?rt:hashForSchema(nt);let it;return it=this.ajv.getSchema(at),it===void 0&&(it=this.ajv.addSchema(nt,at).getSchema(at)||this.ajv.compile(nt)),it(Ye)}catch(nt){return console.warn("Error encountered compiling schema:",nt),!1}}}function customizeValidator(e={},t){return new AJV8Validator(e,t)}const validator=customizeValidator(),CustomTextWidget=e=>{var rt,nt,at,it;const t=(rt=e.options)==null?void 0:rt.minLength,Ye=(nt=e.options)==null?void 0:nt.maxLength,tt=((at=e.value)==null?void 0:at.length)||0;return jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-1",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsx("input",{type:"text",className:"w-full px-3 py-2 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-colors",value:e.value||"",onChange:ot=>e.onChange(ot.target.value),placeholder:e.placeholder,disabled:e.disabled,maxLength:Ye?e.options.maxLength:void 0}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description}),(t||Ye)&&jsxRuntimeExports.jsx("div",{className:"flex justify-end mt-1",children:jsxRuntimeExports.jsx("span",{className:`text-xs ${tt>(((it=e.options)==null?void 0:it.maxLength)||0)?"text-red-500":"text-gray-400"}`,children:t&&Ye?`${tt}/${e.options.maxLength} (最少${e.options.minLength})`:Ye?`${tt}/${e.options.maxLength}`:`最少${e.options.minLength}字符`})})]})},CustomPasswordWidget=e=>{const[t,Ye]=reactExports.useState(!1);return jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-1",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsxs("div",{className:"relative",children:[jsxRuntimeExports.jsx("input",{type:t?"text":"password",className:"w-full px-3 py-2 pr-10 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-colors",value:e.value||"",onChange:tt=>e.onChange(tt.target.value),placeholder:e.placeholder,disabled:e.disabled}),jsxRuntimeExports.jsx("button",{type:"button",className:"absolute right-3 top-1/2 transform -translate-y-1/2 text-gray-400 hover:text-gray-600",onClick:()=>Ye(!t),children:t?jsxRuntimeExports.jsx(EyeOff,{size:16}):jsxRuntimeExports.jsx(Eye$1,{size:16})})]}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description})]})},CustomTextareaWidget=e=>{var rt,nt,at,it,ot;const t=(rt=e.options)==null?void 0:rt.minLength,Ye=(nt=e.options)==null?void 0:nt.maxLength,tt=((at=e.value)==null?void 0:at.length)||0;return jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-1",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsx("textarea",{className:"w-full px-3 py-2 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-colors resize-vertical",value:e.value||"",onChange:ct=>e.onChange(ct.target.value),placeholder:e.placeholder,disabled:e.disabled,rows:((it=e.options)==null?void 0:it.rows)||4,maxLength:Ye?e.options.maxLength:void 0}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description}),(t||Ye)&&jsxRuntimeExports.jsx("div",{className:"flex justify-end mt-1",children:jsxRuntimeExports.jsx("span",{className:`text-xs ${tt>(((ot=e.options)==null?void 0:ot.maxLength)||0)?"text-red-500":"text-gray-400"}`,children:t&&Ye?`${tt}/${e.options.maxLength} (最少${e.options.minLength})`:Ye?`${tt}/${e.options.maxLength}`:`最少${e.options.minLength}字符`})})]})},CustomSelectWidget=e=>{var t,Ye;return jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-1",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsxs("div",{className:"relative",children:[jsxRuntimeExports.jsxs("select",{className:"w-full px-3 py-2 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-colors appearance-none",value:e.value||"",onChange:tt=>e.onChange(tt.target.value),disabled:e.disabled,children:[e.placeholder&&jsxRuntimeExports.jsx("option",{value:"",disabled:!0,children:e.placeholder}),(Ye=(t=e.options)==null?void 0:t.enumOptions)==null?void 0:Ye.map((tt,rt)=>jsxRuntimeExports.jsx("option",{value:tt.value,children:tt.label},rt))]}),jsxRuntimeExports.jsx(ChevronDown$1,{size:16,className:"absolute right-3 top-1/2 transform -translate-y-1/2 text-gray-400 pointer-events-none"})]}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description})]})},CustomCheckboxWidget=e=>{var t,Ye;return jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsx("div",{className:"space-y-2",children:(Ye=(t=e.options)==null?void 0:t.enumOptions)==null?void 0:Ye.map((tt,rt)=>{var nt;return jsxRuntimeExports.jsxs("label",{className:"flex items-center",children:[jsxRuntimeExports.jsx("input",{type:"checkbox",className:"w-4 h-4 text-blue-600 border-gray-300 rounded focus:ring-blue-500 focus:ring-2",checked:((nt=e.value)==null?void 0:nt.includes(tt.value))||!1,onChange:at=>{const it=e.value||[];at.target.checked?e.onChange([...it,tt.value]):e.onChange(it.filter(ot=>ot!==tt.value))},disabled:e.disabled}),jsxRuntimeExports.jsx("span",{className:"ml-2 text-sm text-gray-700",children:tt.label})]},rt)})}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description})]})},CustomRadioWidget=e=>{var t,Ye;return jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsx("div",{className:"space-y-2",children:(Ye=(t=e.options)==null?void 0:t.enumOptions)==null?void 0:Ye.map((tt,rt)=>jsxRuntimeExports.jsxs("label",{className:"flex items-center",children:[jsxRuntimeExports.jsx("input",{type:"radio",name:e.id,className:"w-4 h-4 text-blue-600 border-gray-300 focus:ring-blue-500 focus:ring-2",value:tt.value,checked:e.value===tt.value,onChange:nt=>e.onChange(nt.target.value),disabled:e.disabled}),jsxRuntimeExports.jsx("span",{className:"ml-2 text-sm text-gray-700",children:tt.label})]},rt))}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description})]})},CustomNumberWidget=e=>{var t,Ye,tt;return jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-1",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsx("input",{type:"number",className:"w-full px-3 py-2 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-colors",value:e.value||"",onChange:rt=>e.onChange(Number(rt.target.value)),placeholder:e.placeholder,disabled:e.disabled,min:(t=e.options)==null?void 0:t.min,max:(Ye=e.options)==null?void 0:Ye.max,step:(tt=e.options)==null?void 0:tt.step}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description})]})},CustomRangeWidget=e=>{var t,Ye,tt,rt,nt,at;return jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsxs("div",{className:"px-2",children:[jsxRuntimeExports.jsx("input",{type:"range",className:"w-full h-2 bg-gray-200 rounded-lg appearance-none cursor-pointer slider",value:e.value||((t=e.options)==null?void 0:t.min)||0,onChange:it=>e.onChange(Number(it.target.value)),disabled:e.disabled,min:((Ye=e.options)==null?void 0:Ye.min)||0,max:((tt=e.options)==null?void 0:tt.max)||100,step:((rt=e.options)==null?void 0:rt.step)||1}),jsxRuntimeExports.jsxs("div",{className:"flex justify-between text-xs text-gray-500 mt-1",children:[jsxRuntimeExports.jsx("span",{children:((nt=e.options)==null?void 0:nt.min)||0}),jsxRuntimeExports.jsx("span",{className:"font-medium text-blue-600",children:e.value}),jsxRuntimeExports.jsx("span",{children:((at=e.options)==null?void 0:at.max)||100})]})]}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description})]})},CustomDateWidget=e=>jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-1",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsx("input",{type:"date",className:"w-full px-3 py-2 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-colors",value:e.value||"",onChange:t=>e.onChange(t.target.value),disabled:e.disabled}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description})]}),CustomDateTimeWidget=e=>jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-1",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsx("input",{type:"datetime-local",className:"w-full px-3 py-2 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-colors",value:e.value||"",onChange:t=>e.onChange(t.target.value),disabled:e.disabled}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description})]}),CustomBooleanWidget=e=>jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"flex items-center",children:[jsxRuntimeExports.jsx("input",{type:"checkbox",className:"w-4 h-4 text-blue-600 border-gray-300 rounded focus:ring-blue-500 focus:ring-2 mr-2",checked:e.value||!1,onChange:t=>e.onChange(t.target.checked),disabled:e.disabled}),jsxRuntimeExports.jsxs("span",{className:"text-sm text-gray-700",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]})]}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1 ml-6",children:e.description})]}),CustomFileWidget=e=>{const t=Ye=>{const tt=Ye.target.files;e.multiple?e.onChange(tt):e.onChange((tt==null?void 0:tt[0])||null)};return jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-1",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsx("input",{type:"file",className:"w-full px-3 py-2 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-colors file:mr-3 file:py-1 file:px-3 file:border-0 file:bg-blue-50 file:text-blue-700 file:rounded file:font-medium",onChange:t,disabled:e.disabled,multiple:e.multiple,accept:e.accept}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description})]})},CustomArrayField=e=>jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsxs("div",{className:"space-y-2",children:[e.items.map((t,Ye)=>jsxRuntimeExports.jsxs("div",{className:"flex items-start gap-2 p-3 border border-gray-200 rounded-lg",children:[jsxRuntimeExports.jsx("div",{className:"flex-1",children:t.children}),jsxRuntimeExports.jsx("button",{type:"button",className:"p-1 text-red-500 hover:text-red-700 hover:bg-red-50 rounded",onClick:()=>e.onDropIndexClick(Ye)(),children:jsxRuntimeExports.jsx(X$6,{size:16})})]},Ye)),jsxRuntimeExports.jsxs("button",{type:"button",className:"flex items-center gap-1 px-3 py-1 text-sm bg-gray-100 hover:bg-gray-200 text-gray-700 rounded-lg transition-colors",onClick:()=>e.onAddClick(),children:[jsxRuntimeExports.jsx(Plus,{size:14}),"添加项目"]})]}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description})]}),CustomFieldTemplate=e=>jsxRuntimeExports.jsx("div",{className:`${e.className} mb-4`,children:e.children}),CustomObjectFieldTemplate=e=>jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.title&&jsxRuntimeExports.jsx("h3",{className:"text-sm font-medium text-gray-700 mb-2",children:e.title}),jsxRuntimeExports.jsx("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-4 pl-4 border-l-2 border-gray-200",children:e.properties.map(t=>jsxRuntimeExports.jsx("div",{children:t.content},t.name))}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description})]}),CustomSubmitButton=e=>jsxRuntimeExports.jsx("button",{type:"submit",className:"px-4 py-2 rounded-lg bg-blue-500 hover:bg-blue-600 disabled:bg-gray-300 text-white font-medium focus:outline-none focus:ring-2 focus:ring-blue-400 transition-colors disabled:cursor-not-allowed",disabled:e.disabled,children:e.submitText||"提交"}),show_form=createUITool({name:"show_form",description:"显示动态表单,等待用户填写",parameters:{schema:any()},onlyRender:!1,handler:ToolManager.waitForUIDone,render(e){const t=e.getInputRepaired(),Ye=e.getJSONOutputSafe(),tt=t.schema,rt=ot=>{console.log("Form submitted:",ot),e.response(ot)},nt={text:CustomTextWidget,password:CustomPasswordWidget,textarea:CustomTextareaWidget,select:CustomSelectWidget,checkboxes:CustomCheckboxWidget,radio:CustomRadioWidget,number:CustomNumberWidget,range:CustomRangeWidget,date:CustomDateWidget,datetime:CustomDateTimeWidget,file:CustomFileWidget,boolean:CustomBooleanWidget},at={array:CustomArrayField},it={FieldTemplate:CustomFieldTemplate,ObjectFieldTemplate:CustomObjectFieldTemplate,ButtonTemplates:{SubmitButton:CustomSubmitButton}};return jsxRuntimeExports.jsxs("div",{className:"p-4 bg-white rounded-lg border border-gray-200",children:[jsxRuntimeExports.jsxs("div",{className:"flex items-center gap-1.5 text-gray-700 mb-3 font-bold",children:[jsxRuntimeExports.jsx(FileText,{className:"w-4 h-4 text-blue-500"}),jsxRuntimeExports.jsx("span",{children:"AI 表单"})]}),jsxRuntimeExports.jsx(ErrorBoundary,{children:jsxRuntimeExports.jsx(Form,{readonly:e.state==="done",schema:tt||{},formData:Ye,onSubmit:ot=>rt(ot.formData),validator,onError:ot=>{console.error("表单校验错误:",ot),alert("表单填写有误,请检查后再提交。")},widgets:nt,fields:at,templates:it,className:"custom-form",children:jsxRuntimeExports.jsx("div",{className:"flex gap-2 mt-4",children:jsxRuntimeExports.jsx(CustomSubmitButton,{})})})})]})}}),create_artifacts=createUITool({name:"create_artifacts",description:"创建并保存代码文件到 artifacts 目录",parameters:{},onlyRender:!0,render(e){const t=e.getInputRepaired(),{setCurrentArtifactById:Ye,setShowArtifact:tt}=useChat(),rt=()=>{console.log(t.id,e.message.id),Ye(t.id,e.message.id),tt(!0)};return jsxRuntimeExports.jsxs("div",{className:"p-4 space-y-4",children:[jsxRuntimeExports.jsxs("div",{className:"text-sm text-gray-500",children:["创建文件: ",t.title]}),jsxRuntimeExports.jsx("div",{className:"border rounded-lg p-2 hover:bg-gray-50",children:jsxRuntimeExports.jsx("div",{className:"flex items-center justify-between select-none cursor-pointer",onClick:rt,children:jsxRuntimeExports.jsxs("div",{className:"flex items-center gap-2",children:[jsxRuntimeExports.jsx(File$1,{className:"w-4 h-4"}),jsxRuntimeExports.jsx("span",{className:"font-xs",children:t.title})," version: ",t.id]})})})]})}});function __insertCSS(e){if(typeof document>"u")return;let t=document.head||document.getElementsByTagName("head")[0],Ye=document.createElement("style");Ye.type="text/css",t.appendChild(Ye),Ye.styleSheet?Ye.styleSheet.cssText=e:Ye.appendChild(document.createTextNode(e))}const getAsset=e=>{switch(e){case"success":return SuccessIcon;case"info":return InfoIcon;case"warning":return WarningIcon;case"error":return ErrorIcon;default:return null}},bars=Array(12).fill(0),Loader=({visible:e,className:t})=>React.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},React.createElement("div",{className:"sonner-spinner"},bars.map((Ye,tt)=>React.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${tt}`})))),SuccessIcon=React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},React.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),WarningIcon=React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},React.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),InfoIcon=React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},React.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),ErrorIcon=React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},React.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),CloseIcon=React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},React.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),React.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),useIsDocumentHidden=()=>{const[e,t]=React.useState(document.hidden);return React.useEffect(()=>{const Ye=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",Ye),()=>window.removeEventListener("visibilitychange",Ye)},[]),e};let toastsCounter=1;class Observer{constructor(){this.subscribe=t=>(this.subscribers.push(t),()=>{const Ye=this.subscribers.indexOf(t);this.subscribers.splice(Ye,1)}),this.publish=t=>{this.subscribers.forEach(Ye=>Ye(t))},this.addToast=t=>{this.publish(t),this.toasts=[...this.toasts,t]},this.create=t=>{var Ye;const{message:tt,...rt}=t,nt=typeof(t==null?void 0:t.id)=="number"||((Ye=t.id)==null?void 0:Ye.length)>0?t.id:toastsCounter++,at=this.toasts.find(ot=>ot.id===nt),it=t.dismissible===void 0?!0:t.dismissible;return this.dismissedToasts.has(nt)&&this.dismissedToasts.delete(nt),at?this.toasts=this.toasts.map(ot=>ot.id===nt?(this.publish({...ot,...t,id:nt,title:tt}),{...ot,...t,id:nt,dismissible:it,title:tt}):ot):this.addToast({title:tt,...rt,dismissible:it,id:nt}),nt},this.dismiss=t=>(t?(this.dismissedToasts.add(t),requestAnimationFrame(()=>this.subscribers.forEach(Ye=>Ye({id:t,dismiss:!0})))):this.toasts.forEach(Ye=>{this.subscribers.forEach(tt=>tt({id:Ye.id,dismiss:!0}))}),t),this.message=(t,Ye)=>this.create({...Ye,message:t}),this.error=(t,Ye)=>this.create({...Ye,message:t,type:"error"}),this.success=(t,Ye)=>this.create({...Ye,type:"success",message:t}),this.info=(t,Ye)=>this.create({...Ye,type:"info",message:t}),this.warning=(t,Ye)=>this.create({...Ye,type:"warning",message:t}),this.loading=(t,Ye)=>this.create({...Ye,type:"loading",message:t}),this.promise=(t,Ye)=>{if(!Ye)return;let tt;Ye.loading!==void 0&&(tt=this.create({...Ye,promise:t,type:"loading",message:Ye.loading,description:typeof Ye.description!="function"?Ye.description:void 0}));const rt=Promise.resolve(t instanceof Function?t():t);let nt=tt!==void 0,at;const it=rt.then(async ct=>{if(at=["resolve",ct],React.isValidElement(ct))nt=!1,this.create({id:tt,type:"default",message:ct});else if(isHttpResponse(ct)&&!ct.ok){nt=!1;const Rt=typeof Ye.error=="function"?await Ye.error(`HTTP error! status: ${ct.status}`):Ye.error,qt=typeof Ye.description=="function"?await Ye.description(`HTTP error! status: ${ct.status}`):Ye.description,Ut=typeof Rt=="object"&&!React.isValidElement(Rt)?Rt:{message:Rt};this.create({id:tt,type:"error",description:qt,...Ut})}else if(ct instanceof Error){nt=!1;const Rt=typeof Ye.error=="function"?await Ye.error(ct):Ye.error,qt=typeof Ye.description=="function"?await Ye.description(ct):Ye.description,Ut=typeof Rt=="object"&&!React.isValidElement(Rt)?Rt:{message:Rt};this.create({id:tt,type:"error",description:qt,...Ut})}else if(Ye.success!==void 0){nt=!1;const Rt=typeof Ye.success=="function"?await Ye.success(ct):Ye.success,qt=typeof Ye.description=="function"?await Ye.description(ct):Ye.description,Ut=typeof Rt=="object"&&!React.isValidElement(Rt)?Rt:{message:Rt};this.create({id:tt,type:"success",description:qt,...Ut})}}).catch(async ct=>{if(at=["reject",ct],Ye.error!==void 0){nt=!1;const At=typeof Ye.error=="function"?await Ye.error(ct):Ye.error,Rt=typeof Ye.description=="function"?await Ye.description(ct):Ye.description,Ft=typeof At=="object"&&!React.isValidElement(At)?At:{message:At};this.create({id:tt,type:"error",description:Rt,...Ft})}}).finally(()=>{nt&&(this.dismiss(tt),tt=void 0),Ye.finally==null||Ye.finally.call(Ye)}),ot=()=>new Promise((ct,At)=>it.then(()=>at[0]==="reject"?At(at[1]):ct(at[1])).catch(At));return typeof tt!="string"&&typeof tt!="number"?{unwrap:ot}:Object.assign(tt,{unwrap:ot})},this.custom=(t,Ye)=>{const tt=(Ye==null?void 0:Ye.id)||toastsCounter++;return this.create({jsx:t(tt),id:tt,...Ye}),tt},this.getActiveToasts=()=>this.toasts.filter(t=>!this.dismissedToasts.has(t.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const ToastState=new Observer,toastFunction=(e,t)=>{const Ye=(t==null?void 0:t.id)||toastsCounter++;return ToastState.addToast({title:e,...t,id:Ye}),Ye},isHttpResponse=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",basicToast=toastFunction,getHistory=()=>ToastState.toasts,getToasts=()=>ToastState.getActiveToasts(),toast=Object.assign(basicToast,{success:ToastState.success,info:ToastState.info,warning:ToastState.warning,error:ToastState.error,custom:ToastState.custom,message:ToastState.message,promise:ToastState.promise,dismiss:ToastState.dismiss,loading:ToastState.loading},{getHistory,getToasts});__insertCSS("[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}");function isAction(e){return e.label!==void 0}const VISIBLE_TOASTS_AMOUNT=3,VIEWPORT_OFFSET="24px",MOBILE_VIEWPORT_OFFSET="16px",TOAST_LIFETIME=4e3,TOAST_WIDTH=356,GAP=14,SWIPE_THRESHOLD=45,TIME_BEFORE_UNMOUNT=200;function cn(...e){return e.filter(Boolean).join(" ")}function getDefaultSwipeDirections(e){const[t,Ye]=e.split("-"),tt=[];return t&&tt.push(t),Ye&&tt.push(Ye),tt}const Toast=e=>{var t,Ye,tt,rt,nt,at,it,ot,ct;const{invert:At,toast:Rt,unstyled:qt,interacting:Ft,setHeights:Ut,visibleToasts:Ht,heights:zt,index:Yt,toasts:Gt,expanded:Vt,removeToast:Zt,defaultRichColors:Xt,closeButton:Qt,style:er,cancelButtonStyle:nr,actionButtonStyle:ar,className:sr="",descriptionClassName:lr="",duration:fr,position:gr,gap:dr,expandByDefault:vr,classNames:mr,icons:Er,closeButtonAriaLabel:_r="Close toast"}=e,[Tr,ur]=React.useState(null),[cr,yr]=React.useState(null),[ir,or]=React.useState(!1),[hr,Sr]=React.useState(!1),[wr,Ir]=React.useState(!1),[kr,Mr]=React.useState(!1),[Ar,Rr]=React.useState(!1),[Dr,Lr]=React.useState(0),[Ur,Wr]=React.useState(0),Kr=React.useRef(Rt.duration||fr||TOAST_LIFETIME),nn=React.useRef(null),Jr=React.useRef(null),un=Yt===0,pn=Yt+1<=Ht,Zr=Rt.type,rn=Rt.dismissible!==!1,fn=Rt.className||"",mn=Rt.descriptionClassName||"",jr=React.useMemo(()=>zt.findIndex(sn=>sn.toastId===Rt.id)||0,[zt,Rt.id]),Hr=React.useMemo(()=>{var sn;return(sn=Rt.closeButton)!=null?sn:Qt},[Rt.closeButton,Qt]),Yr=React.useMemo(()=>Rt.duration||fr||TOAST_LIFETIME,[Rt.duration,fr]),en=React.useRef(0),dn=React.useRef(0),Hn=React.useRef(0),kn=React.useRef(null),[Tn,bn]=gr.split("-"),In=React.useMemo(()=>zt.reduce((sn,Nn,Vn)=>Vn>=jr?sn:sn+Nn.height,0),[zt,jr]),Sn=useIsDocumentHidden(),la=Rt.invert||At,Zn=Zr==="loading";dn.current=React.useMemo(()=>jr*dr+In,[jr,In]),React.useEffect(()=>{Kr.current=Yr},[Yr]),React.useEffect(()=>{or(!0)},[]),React.useEffect(()=>{const sn=Jr.current;if(sn){const Nn=sn.getBoundingClientRect().height;return Wr(Nn),Ut(Vn=>[{toastId:Rt.id,height:Nn,position:Rt.position},...Vn]),()=>Ut(Vn=>Vn.filter(ua=>ua.toastId!==Rt.id))}},[Ut,Rt.id]),React.useLayoutEffect(()=>{if(!ir)return;const sn=Jr.current,Nn=sn.style.height;sn.style.height="auto";const Vn=sn.getBoundingClientRect().height;sn.style.height=Nn,Wr(Vn),Ut(ua=>ua.find(Un=>Un.toastId===Rt.id)?ua.map(Un=>Un.toastId===Rt.id?{...Un,height:Vn}:Un):[{toastId:Rt.id,height:Vn,position:Rt.position},...ua])},[ir,Rt.title,Rt.description,Ut,Rt.id,Rt.jsx,Rt.action,Rt.cancel]);const Kn=React.useCallback(()=>{Sr(!0),Lr(dn.current),Ut(sn=>sn.filter(Nn=>Nn.toastId!==Rt.id)),setTimeout(()=>{Zt(Rt)},TIME_BEFORE_UNMOUNT)},[Rt,Zt,Ut,dn]);React.useEffect(()=>{if(Rt.promise&&Zr==="loading"||Rt.duration===1/0||Rt.type==="loading")return;let sn;return Vt||Ft||Sn?(()=>{if(Hn.current<en.current){const ua=new Date().getTime()-en.current;Kr.current=Kr.current-ua}Hn.current=new Date().getTime()})():(()=>{Kr.current!==1/0&&(en.current=new Date().getTime(),sn=setTimeout(()=>{Rt.onAutoClose==null||Rt.onAutoClose.call(Rt,Rt),Kn()},Kr.current))})(),()=>clearTimeout(sn)},[Vt,Ft,Rt,Zr,Sn,Kn]),React.useEffect(()=>{Rt.delete&&(Kn(),Rt.onDismiss==null||Rt.onDismiss.call(Rt,Rt))},[Kn,Rt.delete]);function qn(){var sn;if(Er!=null&&Er.loading){var Nn;return React.createElement("div",{className:cn(mr==null?void 0:mr.loader,Rt==null||(Nn=Rt.classNames)==null?void 0:Nn.loader,"sonner-loader"),"data-visible":Zr==="loading"},Er.loading)}return React.createElement(Loader,{className:cn(mr==null?void 0:mr.loader,Rt==null||(sn=Rt.classNames)==null?void 0:sn.loader),visible:Zr==="loading"})}const xa=Rt.icon||(Er==null?void 0:Er[Zr])||getAsset(Zr);var Xa,Ea;return React.createElement("li",{tabIndex:0,ref:Jr,className:cn(sr,fn,mr==null?void 0:mr.toast,Rt==null||(t=Rt.classNames)==null?void 0:t.toast,mr==null?void 0:mr.default,mr==null?void 0:mr[Zr],Rt==null||(Ye=Rt.classNames)==null?void 0:Ye[Zr]),"data-sonner-toast":"","data-rich-colors":(Xa=Rt.richColors)!=null?Xa:Xt,"data-styled":!(Rt.jsx||Rt.unstyled||qt),"data-mounted":ir,"data-promise":!!Rt.promise,"data-swiped":Ar,"data-removed":hr,"data-visible":pn,"data-y-position":Tn,"data-x-position":bn,"data-index":Yt,"data-front":un,"data-swiping":wr,"data-dismissible":rn,"data-type":Zr,"data-invert":la,"data-swipe-out":kr,"data-swipe-direction":cr,"data-expanded":!!(Vt||vr&&ir),"data-testid":Rt.testId,style:{"--index":Yt,"--toasts-before":Yt,"--z-index":Gt.length-Yt,"--offset":`${hr?Dr:dn.current}px`,"--initial-height":vr?"auto":`${Ur}px`,...er,...Rt.style},onDragEnd:()=>{Ir(!1),ur(null),kn.current=null},onPointerDown:sn=>{sn.button!==2&&(Zn||!rn||(nn.current=new Date,Lr(dn.current),sn.target.setPointerCapture(sn.pointerId),sn.target.tagName!=="BUTTON"&&(Ir(!0),kn.current={x:sn.clientX,y:sn.clientY})))},onPointerUp:()=>{var sn,Nn,Vn;if(kr||!rn)return;kn.current=null;const ua=Number(((sn=Jr.current)==null?void 0:sn.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),ni=Number(((Nn=Jr.current)==null?void 0:Nn.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),Un=new Date().getTime()-((Vn=nn.current)==null?void 0:Vn.getTime()),ga=Tr==="x"?ua:ni,pi=Math.abs(ga)/Un;if(Math.abs(ga)>=SWIPE_THRESHOLD||pi>.11){Lr(dn.current),Rt.onDismiss==null||Rt.onDismiss.call(Rt,Rt),yr(Tr==="x"?ua>0?"right":"left":ni>0?"down":"up"),Kn(),Mr(!0);return}else{var ba,ya;(ba=Jr.current)==null||ba.style.setProperty("--swipe-amount-x","0px"),(ya=Jr.current)==null||ya.style.setProperty("--swipe-amount-y","0px")}Rr(!1),Ir(!1),ur(null)},onPointerMove:sn=>{var Nn,Vn,ua;if(!kn.current||!rn||((Nn=window.getSelection())==null?void 0:Nn.toString().length)>0)return;const Un=sn.clientY-kn.current.y,ga=sn.clientX-kn.current.x;var pi;const ba=(pi=e.swipeDirections)!=null?pi:getDefaultSwipeDirections(gr);!Tr&&(Math.abs(ga)>1||Math.abs(Un)>1)&&ur(Math.abs(ga)>Math.abs(Un)?"x":"y");let ya={x:0,y:0};const Pi=Oa=>1/(1.5+Math.abs(Oa)/20);if(Tr==="y"){if(ba.includes("top")||ba.includes("bottom"))if(ba.includes("top")&&Un<0||ba.includes("bottom")&&Un>0)ya.y=Un;else{const Oa=Un*Pi(Un);ya.y=Math.abs(Oa)<Math.abs(Un)?Oa:Un}}else if(Tr==="x"&&(ba.includes("left")||ba.includes("right")))if(ba.includes("left")&&ga<0||ba.includes("right")&&ga>0)ya.x=ga;else{const Oa=ga*Pi(ga);ya.x=Math.abs(Oa)<Math.abs(ga)?Oa:ga}(Math.abs(ya.x)>0||Math.abs(ya.y)>0)&&Rr(!0),(Vn=Jr.current)==null||Vn.style.setProperty("--swipe-amount-x",`${ya.x}px`),(ua=Jr.current)==null||ua.style.setProperty("--swipe-amount-y",`${ya.y}px`)}},Hr&&!Rt.jsx&&Zr!=="loading"?React.createElement("button",{"aria-label":_r,"data-disabled":Zn,"data-close-button":!0,onClick:Zn||!rn?()=>{}:()=>{Kn(),Rt.onDismiss==null||Rt.onDismiss.call(Rt,Rt)},className:cn(mr==null?void 0:mr.closeButton,Rt==null||(tt=Rt.classNames)==null?void 0:tt.closeButton)},(Ea=Er==null?void 0:Er.close)!=null?Ea:CloseIcon):null,(Zr||Rt.icon||Rt.promise)&&Rt.icon!==null&&((Er==null?void 0:Er[Zr])!==null||Rt.icon)?React.createElement("div",{"data-icon":"",className:cn(mr==null?void 0:mr.icon,Rt==null||(rt=Rt.classNames)==null?void 0:rt.icon)},Rt.promise||Rt.type==="loading"&&!Rt.icon?Rt.icon||qn():null,Rt.type!=="loading"?xa:null):null,React.createElement("div",{"data-content":"",className:cn(mr==null?void 0:mr.content,Rt==null||(nt=Rt.classNames)==null?void 0:nt.content)},React.createElement("div",{"data-title":"",className:cn(mr==null?void 0:mr.title,Rt==null||(at=Rt.classNames)==null?void 0:at.title)},Rt.jsx?Rt.jsx:typeof Rt.title=="function"?Rt.title():Rt.title),Rt.description?React.createElement("div",{"data-description":"",className:cn(lr,mn,mr==null?void 0:mr.description,Rt==null||(it=Rt.classNames)==null?void 0:it.description)},typeof Rt.description=="function"?Rt.description():Rt.description):null),React.isValidElement(Rt.cancel)?Rt.cancel:Rt.cancel&&isAction(Rt.cancel)?React.createElement("button",{"data-button":!0,"data-cancel":!0,style:Rt.cancelButtonStyle||nr,onClick:sn=>{isAction(Rt.cancel)&&rn&&(Rt.cancel.onClick==null||Rt.cancel.onClick.call(Rt.cancel,sn),Kn())},className:cn(mr==null?void 0:mr.cancelButton,Rt==null||(ot=Rt.classNames)==null?void 0:ot.cancelButton)},Rt.cancel.label):null,React.isValidElement(Rt.action)?Rt.action:Rt.action&&isAction(Rt.action)?React.createElement("button",{"data-button":!0,"data-action":!0,style:Rt.actionButtonStyle||ar,onClick:sn=>{isAction(Rt.action)&&(Rt.action.onClick==null||Rt.action.onClick.call(Rt.action,sn),!sn.defaultPrevented&&Kn())},className:cn(mr==null?void 0:mr.actionButton,Rt==null||(ct=Rt.classNames)==null?void 0:ct.actionButton)},Rt.action.label):null)};function getDocumentDirection(){if(typeof window>"u"||typeof document>"u")return"ltr";const e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}function assignOffset(e,t){const Ye={};return[e,t].forEach((tt,rt)=>{const nt=rt===1,at=nt?"--mobile-offset":"--offset",it=nt?MOBILE_VIEWPORT_OFFSET:VIEWPORT_OFFSET;function ot(ct){["top","right","bottom","left"].forEach(At=>{Ye[`${at}-${At}`]=typeof ct=="number"?`${ct}px`:ct})}typeof tt=="number"||typeof tt=="string"?ot(tt):typeof tt=="object"?["top","right","bottom","left"].forEach(ct=>{tt[ct]===void 0?Ye[`${at}-${ct}`]=it:Ye[`${at}-${ct}`]=typeof tt[ct]=="number"?`${tt[ct]}px`:tt[ct]}):ot(it)}),Ye}const Toaster$1=React.forwardRef(function e(t,Ye){const{id:tt,invert:rt,position:nt="bottom-right",hotkey:at=["altKey","KeyT"],expand:it,closeButton:ot,className:ct,offset:At,mobileOffset:Rt,theme:qt="light",richColors:Ft,duration:Ut,style:Ht,visibleToasts:zt=VISIBLE_TOASTS_AMOUNT,toastOptions:Yt,dir:Gt=getDocumentDirection(),gap:Vt=GAP,icons:Zt,containerAriaLabel:Xt="Notifications"}=t,[Qt,er]=React.useState([]),nr=React.useMemo(()=>tt?Qt.filter(ir=>ir.toasterId===tt):Qt.filter(ir=>!ir.toasterId),[Qt,tt]),ar=React.useMemo(()=>Array.from(new Set([nt].concat(nr.filter(ir=>ir.position).map(ir=>ir.position)))),[nr,nt]),[sr,lr]=React.useState([]),[fr,gr]=React.useState(!1),[dr,vr]=React.useState(!1),[mr,Er]=React.useState(qt!=="system"?qt:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),_r=React.useRef(null),Tr=at.join("+").replace(/Key/g,"").replace(/Digit/g,""),ur=React.useRef(null),cr=React.useRef(!1),yr=React.useCallback(ir=>{er(or=>{var hr;return(hr=or.find(Sr=>Sr.id===ir.id))!=null&&hr.delete||ToastState.dismiss(ir.id),or.filter(({id:Sr})=>Sr!==ir.id)})},[]);return React.useEffect(()=>ToastState.subscribe(ir=>{if(ir.dismiss){requestAnimationFrame(()=>{er(or=>or.map(hr=>hr.id===ir.id?{...hr,delete:!0}:hr))});return}setTimeout(()=>{ReactDOM.flushSync(()=>{er(or=>{const hr=or.findIndex(Sr=>Sr.id===ir.id);return hr!==-1?[...or.slice(0,hr),{...or[hr],...ir},...or.slice(hr+1)]:[ir,...or]})})})}),[Qt]),React.useEffect(()=>{if(qt!=="system"){Er(qt);return}if(qt==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?Er("dark"):Er("light")),typeof window>"u")return;const ir=window.matchMedia("(prefers-color-scheme: dark)");try{ir.addEventListener("change",({matches:or})=>{Er(or?"dark":"light")})}catch{ir.addListener(({matches:hr})=>{try{Er(hr?"dark":"light")}catch(Sr){console.error(Sr)}})}},[qt]),React.useEffect(()=>{Qt.length<=1&&gr(!1)},[Qt]),React.useEffect(()=>{const ir=or=>{var hr;if(at.every(Ir=>or[Ir]||or.code===Ir)){var wr;gr(!0),(wr=_r.current)==null||wr.focus()}or.code==="Escape"&&(document.activeElement===_r.current||(hr=_r.current)!=null&&hr.contains(document.activeElement))&&gr(!1)};return document.addEventListener("keydown",ir),()=>document.removeEventListener("keydown",ir)},[at]),React.useEffect(()=>{if(_r.current)return()=>{ur.current&&(ur.current.focus({preventScroll:!0}),ur.current=null,cr.current=!1)}},[_r.current]),React.createElement("section",{ref:Ye,"aria-label":`${Xt} ${Tr}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},ar.map((ir,or)=>{var hr;const[Sr,wr]=ir.split("-");return nr.length?React.createElement("ol",{key:ir,dir:Gt==="auto"?getDocumentDirection():Gt,tabIndex:-1,ref:_r,className:ct,"data-sonner-toaster":!0,"data-sonner-theme":mr,"data-y-position":Sr,"data-x-position":wr,style:{"--front-toast-height":`${((hr=sr[0])==null?void 0:hr.height)||0}px`,"--width":`${TOAST_WIDTH}px`,"--gap":`${Vt}px`,...Ht,...assignOffset(At,Rt)},onBlur:Ir=>{cr.current&&!Ir.currentTarget.contains(Ir.relatedTarget)&&(cr.current=!1,ur.current&&(ur.current.focus({preventScroll:!0}),ur.current=null))},onFocus:Ir=>{Ir.target instanceof HTMLElement&&Ir.target.dataset.dismissible==="false"||cr.current||(cr.current=!0,ur.current=Ir.relatedTarget)},onMouseEnter:()=>gr(!0),onMouseMove:()=>gr(!0),onMouseLeave:()=>{dr||gr(!1)},onDragEnd:()=>gr(!1),onPointerDown:Ir=>{Ir.target instanceof HTMLElement&&Ir.target.dataset.dismissible==="false"||vr(!0)},onPointerUp:()=>vr(!1)},nr.filter(Ir=>!Ir.position&&or===0||Ir.position===ir).map((Ir,kr)=>{var Mr,Ar;return React.createElement(Toast,{key:Ir.id,icons:Zt,index:kr,toast:Ir,defaultRichColors:Ft,duration:(Mr=Yt==null?void 0:Yt.duration)!=null?Mr:Ut,className:Yt==null?void 0:Yt.className,descriptionClassName:Yt==null?void 0:Yt.descriptionClassName,invert:rt,visibleToasts:zt,closeButton:(Ar=Yt==null?void 0:Yt.closeButton)!=null?Ar:ot,interacting:dr,position:ir,style:Yt==null?void 0:Yt.style,unstyled:Yt==null?void 0:Yt.unstyled,classNames:Yt==null?void 0:Yt.classNames,cancelButtonStyle:Yt==null?void 0:Yt.cancelButtonStyle,actionButtonStyle:Yt==null?void 0:Yt.actionButtonStyle,closeButtonAriaLabel:Yt==null?void 0:Yt.closeButtonAriaLabel,removeToast:yr,toasts:nr.filter(Rr=>Rr.position==Ir.position),heights:sr.filter(Rr=>Rr.position==Ir.position),setHeights:lr,expandByDefault:it,gap:Vt,expanded:fr,swipeDirections:t.swipeDirections})})):null}))}),initialLoginSettings={headers:[{key:"authorization",value:""}],withCredentials:!1,apiUrl:"/api/langgraph",defaultAgent:"agent"},apiUrlShortcuts=["/api/langgraph","http://localhost:8123","http://localhost:3000","http://localhost:8000","http://localhost:5000"],LoginSettings=()=>{const[e,t]=reactExports.useState(!1),[Ye,tt]=reactExports.useState(()=>{try{const At=localStorage.getItem("code"),Rt=localStorage.getItem("withCredentials"),qt=localStorage.getItem("apiUrl"),Ft=localStorage.getItem("defaultAgent");let Ut=initialLoginSettings.headers;if(At){const Ht=JSON.parse(At);typeof Ht=="object"&&!Array.isArray(Ht)?Ut=Object.entries(Ht).map(([zt,Yt])=>({key:zt,value:Yt})):Array.isArray(Ht)&&(Ut=Ht)}return{headers:Ut,withCredentials:Rt?JSON.parse(Rt):initialLoginSettings.withCredentials,apiUrl:qt||initialLoginSettings.apiUrl,defaultAgent:Ft||initialLoginSettings.defaultAgent}}catch(At){return console.error("Error reading login settings from localStorage:",At),initialLoginSettings}});reactExports.useEffect(()=>{try{localStorage.setItem("code",JSON.stringify(Ye.headers)),localStorage.setItem("withCredentials",JSON.stringify(Ye.withCredentials)),localStorage.setItem("apiUrl",Ye.apiUrl),localStorage.setItem("defaultAgent",Ye.defaultAgent)}catch(At){console.error("Error writing login settings to localStorage:",At)}},[Ye]),reactExports.useEffect(()=>{const At=Rt=>{const qt=Rt.target;e&&!qt.closest(".api-url-dropdown")&&t(!1)};return document.addEventListener("mousedown",At),()=>{document.removeEventListener("mousedown",At)}},[e]);const rt=reactExports.useCallback(()=>{tt(At=>({...At,headers:[...At.headers,{key:"",value:""}]}))},[]),nt=reactExports.useCallback(At=>{tt(Rt=>({...Rt,headers:Rt.headers.filter((qt,Ft)=>Ft!==At)}))},[]),at=reactExports.useCallback((At,Rt,qt)=>{tt(Ft=>{const Ut=[...Ft.headers];return Ut[At][Rt]=qt,{...Ft,headers:Ut}})},[]),it=reactExports.useCallback(At=>{const{name:Rt,value:qt,type:Ft,checked:Ut}=At.target;tt(Ht=>({...Ht,[Rt]:Ft==="checkbox"?Ut:qt}))},[]);reactExports.useCallback(At=>{const{name:Rt,value:qt}=At.target;tt(Ft=>({...Ft,[Rt]:qt}))},[]);const ot=reactExports.useCallback(At=>{tt(Rt=>({...Rt,apiUrl:At})),t(!1)},[]),ct=()=>{toast.success("配置已保存!重启程序"),setTimeout(()=>{window.location.reload()},500)};return jsxRuntimeExports.jsxs("form",{className:"space-y-6",children:[jsxRuntimeExports.jsxs("div",{children:[jsxRuntimeExports.jsx("label",{htmlFor:"default-agent",className:"block text-sm font-medium text-gray-700 dark:text-gray-300 mb-2",children:"默认 Agent 名称"}),jsxRuntimeExports.jsx("input",{type:"text",id:"defaultAgent",name:"defaultAgent",value:Ye.defaultAgent,onChange:it,placeholder:"例如: assistant",className:"w-full px-4 py-3 border border-gray-300 dark:border-gray-600 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-all bg-white dark:bg-gray-700 text-gray-900 dark:text-white"})]}),jsxRuntimeExports.jsxs("div",{children:[jsxRuntimeExports.jsx("label",{htmlFor:"api-url",className:"block text-sm font-medium text-gray-700 dark:text-gray-300 mb-2",children:"API URL"}),jsxRuntimeExports.jsxs("div",{className:"relative api-url-dropdown",children:[jsxRuntimeExports.jsxs("div",{className:"flex",children:[jsxRuntimeExports.jsx("input",{type:"text",id:"apiUrl",name:"apiUrl",value:Ye.apiUrl,onChange:it,placeholder:"例如: http://localhost:8123",className:"flex-1 px-4 py-3 border border-gray-300 dark:border-gray-600 rounded-l-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-all bg-white dark:bg-gray-700 text-gray-900 dark:text-white"}),jsxRuntimeExports.jsx("button",{type:"button",onClick:()=>t(!e),className:"px-3 py-3 border border-l-0 border-gray-300 dark:border-gray-600 rounded-r-lg bg-gray-50 dark:bg-gray-600 hover:bg-gray-100 dark:hover:bg-gray-500 transition-colors focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent",children:jsxRuntimeExports.jsx("svg",{className:"w-5 h-5 text-gray-600 dark:text-gray-300",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:jsxRuntimeExports.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M19 9l-7 7-7-7"})})})]}),e&&jsxRuntimeExports.jsx("div",{className:"absolute z-10 mt-1 w-full bg-white dark:bg-gray-700 border border-gray-300 dark:border-gray-600 rounded-lg shadow-lg",children:apiUrlShortcuts.map((At,Rt)=>jsxRuntimeExports.jsx("button",{type:"button",onClick:()=>ot(At),className:"w-full px-4 py-2 text-left hover:bg-gray-100 dark:hover:bg-gray-600 transition-colors first:rounded-t-lg last:rounded-b-lg text-gray-900 dark:text-white",children:At},Rt))})]})]}),jsxRuntimeExports.jsxs("div",{children:[jsxRuntimeExports.jsx("label",{className:"block text-sm font-medium text-gray-700 dark:text-gray-300 mb-2",children:"请求头配置"}),jsxRuntimeExports.jsx("div",{className:"space-y-3",children:Ye.headers.map((At,Rt)=>jsxRuntimeExports.jsxs("div",{className:"bg-gray-50 dark:bg-gray-700 rounded-lg p-4 shadow-sm",children:[jsxRuntimeExports.jsxs("div",{className:"grid grid-cols-2 gap-4 mb-3",children:[jsxRuntimeExports.jsx("div",{children:jsxRuntimeExports.jsx("input",{type:"text",id:`header-key-${Rt}`,value:At.key,onChange:qt=>at(Rt,"key",qt.target.value),placeholder:"例如: authorization",required:!0,className:"w-full px-4 py-2 border border-gray-300 dark:border-gray-600 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-all bg-white dark:bg-gray-800 text-gray-900 dark:text-white"})}),jsxRuntimeExports.jsx("div",{children:jsxRuntimeExports.jsx("input",{type:"text",id:`header-value-${Rt}`,value:At.value,onChange:qt=>at(Rt,"value",qt.target.value),placeholder:"例如: Bearer token;无则填 1",required:!0,className:"w-full px-4 py-2 border border-gray-300 dark:border-gray-600 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-all bg-white dark:bg-gray-800 text-gray-900 dark:text-white"})})]}),Rt>0&&jsxRuntimeExports.jsxs("button",{type:"button",onClick:()=>nt(Rt),className:"text-red-600 dark:text-red-400 hover:text-red-700 dark:hover:text-red-500 text-sm font-medium flex items-center space-x-1 transition-colors",children:[jsxRuntimeExports.jsx("svg",{className:"w-4 h-4",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:jsxRuntimeExports.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M19 7l-.867 12.142A2 2 0 0116.138 21H7.862a2 2 0 01-1.995-1.858L5 7m5 4v6m4-6v6m1-10V4a1 1 0 00-1-1h-4a1 1 0 00-1 1v3M4 7h16"})}),jsxRuntimeExports.jsx("span",{children:"删除此请求头"})]})]},Rt))})]}),jsxRuntimeExports.jsxs("div",{className:"flex items-center space-x-3",children:[jsxRuntimeExports.jsx("input",{type:"checkbox",id:"withCredentials",name:"withCredentials",checked:Ye.withCredentials,onChange:it,className:"h-4 w-4 text-blue-600 border-gray-300 rounded focus:ring-blue-500 dark:bg-gray-700 dark:border-gray-600"}),jsxRuntimeExports.jsx("label",{htmlFor:"withCredentials",className:"text-sm text-gray-700 dark:text-gray-300",children:"启用 withCredentials(跨域请求时发送 Cookie)"})]}),jsxRuntimeExports.jsxs("div",{className:"flex flex-col sm:flex-row gap-4 pt-4",children:[jsxRuntimeExports.jsxs("button",{type:"button",onClick:rt,className:"flex-1 px-6 py-3 bg-gray-100 dark:bg-gray-700 text-gray-700 dark:text-gray-200 rounded-lg hover:bg-gray-200 dark:hover:bg-gray-600 transition-colors font-medium flex items-center justify-center space-x-2",children:[jsxRuntimeExports.jsx("svg",{className:"w-5 h-5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:jsxRuntimeExports.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M12 6v6m0 0v6m0-6h6m-6 0H6"})}),jsxRuntimeExports.jsx("span",{children:"添加请求头"})]}),jsxRuntimeExports.jsxs("button",{type:"button",onClick:ct,className:"flex-1 px-6 py-3 bg-blue-600 text-white rounded-lg hover:bg-blue-700 transition-colors font-medium flex items-center justify-center space-x-2",children:[jsxRuntimeExports.jsx("svg",{className:"w-5 h-5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:jsxRuntimeExports.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M5 13l4 4L19 7"})}),jsxRuntimeExports.jsx("span",{children:"保存配置"})]})]})]})},initialConsoleSettings={},ConsoleSettings=()=>{const[e,t]=reactExports.useState(()=>{try{const Ye=localStorage.getItem("consoleSettings");return Ye?JSON.parse(Ye):initialConsoleSettings}catch(Ye){return console.error("Error reading console settings from localStorage:",Ye),initialConsoleSettings}});return reactExports.useEffect(()=>{try{localStorage.setItem("consoleSettings",JSON.stringify(e))}catch(Ye){console.error("Error writing console settings to localStorage:",Ye)}},[e]),jsxRuntimeExports.jsxs("form",{className:"space-y-6",children:[jsxRuntimeExports.jsxs("div",{className:"bg-blue-50 dark:bg-blue-900/20 p-4 rounded-lg border border-blue-200 dark:border-blue-800",children:[jsxRuntimeExports.jsx("h4",{className:"text-sm font-medium text-blue-900 dark:text-blue-100 mb-2",children:"控制台说明"}),jsxRuntimeExports.jsx("p",{className:"text-sm text-blue-800 dark:text-blue-200 leading-relaxed",children:"控制台用于监控应用程序的运行状态。我们的控制台提供一个兼容 LangChain 的数据上报接口,您可以通过下面的配置来启用控制台输出。"})]}),jsxRuntimeExports.jsxs("ol",{children:[jsxRuntimeExports.jsx("li",{children:"请在 LangGraph 或者 LangChain 项目中使用以下环境变量来启用控制台输出:"}),jsxRuntimeExports.jsxs("li",{children:["LANGSMITH_TRACING=true",jsxRuntimeExports.jsx("br",{}),"LANGSMITH_ENDPOINT= ",new URL("/api/open-smith",window.location.origin).toString()]}),jsxRuntimeExports.jsx("li",{children:"然后可以在主面板的 控制台 按钮中查看控制台输出。"})]})]})},SettingPanel=({isOpen:e,onClose:t,tabs:Ye})=>{var it,ot;const tt=[{id:"server-login",title:"服务器",component:jsxRuntimeExports.jsx(LoginSettings,{})},{id:"console",title:"控制台",component:jsxRuntimeExports.jsx(ConsoleSettings,{})}],rt=Ye?[...tt,...Ye]:tt,[nt,at]=reactExports.useState("general");return reactExports.useEffect(()=>{rt.length>0&&!rt.find(ct=>ct.id===nt)&&at(rt[0].id)},[rt,nt]),e?jsxRuntimeExports.jsx("div",{className:"fixed inset-0 bg-opacity-50 flex items-center justify-center z-50 backdrop-blur-sm",children:jsxRuntimeExports.jsxs("div",{className:"bg-white dark:bg-gray-800 rounded-lg shadow-xl w-full max-w-2xl h-[80vh] flex flex-col relative overflow-hidden ring-1 ring-gray-900/5 dark:ring-white/10",children:[jsxRuntimeExports.jsx("button",{className:"absolute top-3 right-3 text-gray-400 hover:text-gray-600 dark:hover:text-gray-300 z-10 p-1 rounded-full hover:bg-gray-100 dark:hover:bg-gray-700 transition-colors",onClick:t,"aria-label":"关闭设置",children:jsxRuntimeExports.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",className:"h-5 w-5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:jsxRuntimeExports.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 18L18 6M6 6l12 12"})})}),jsxRuntimeExports.jsxs("div",{className:"flex flex-1",children:[jsxRuntimeExports.jsxs("div",{className:"w-1/4 border-r border-gray-200 dark:border-gray-700 p-4 flex flex-col",children:[jsxRuntimeExports.jsx("h2",{className:"text-2xl font-bold mb-6 text-gray-900 dark:text-white",children:"设置"}),jsxRuntimeExports.jsx("nav",{className:"flex-1",children:jsxRuntimeExports.jsx("ul",{children:rt.map(ct=>jsxRuntimeExports.jsx("li",{children:jsxRuntimeExports.jsx("button",{id:ct.id+"-button",className:`flex items-center w-full text-left py-2 px-3 rounded-md mb-2 text-base
896
+ deps: ${At}}`};const rt={keyword:"dependencies",type:"object",schemaType:"object",error:e.error,code(ot){const[ct,At]=nt(ot);at(ot,ct),it(ot,At)}};function nt({schema:ot}){const ct={},At={};for(const Rt in ot){if(Rt==="__proto__")continue;const qt=Array.isArray(ot[Rt])?ct:At;qt[Rt]=ot[Rt]}return[ct,At]}function at(ot,ct=ot.schema){const{gen:At,data:Rt,it:qt}=ot;if(Object.keys(ct).length===0)return;const Ft=At.let("missing");for(const Ut in ct){const Ht=ct[Ut];if(Ht.length===0)continue;const zt=(0,tt.propertyInData)(At,Rt,Ut,qt.opts.ownProperties);ot.setParams({property:Ut,depsCount:Ht.length,deps:Ht.join(", ")}),qt.allErrors?At.if(zt,()=>{for(const Yt of Ht)(0,tt.checkReportMissingProp)(ot,Yt)}):(At.if((0,t._)`${zt} && (${(0,tt.checkMissingProp)(ot,Ht,Ft)})`),(0,tt.reportMissingProp)(ot,Ft),At.else())}}e.validatePropertyDeps=at;function it(ot,ct=ot.schema){const{gen:At,data:Rt,keyword:qt,it:Ft}=ot,Ut=At.name("valid");for(const Ht in ct)(0,Ye.alwaysValidSchema)(Ft,ct[Ht])||(At.if((0,tt.propertyInData)(At,Rt,Ht,Ft.opts.ownProperties),()=>{const zt=ot.subschema({keyword:qt,schemaProp:Ht},Ut);ot.mergeValidEvaluated(zt,Ut)},()=>At.var(Ut,!0)),ot.ok(Ut))}e.validateSchemaDeps=it,e.default=rt}(dependencies)),dependencies}var propertyNames={},hasRequiredPropertyNames;function requirePropertyNames(){if(hasRequiredPropertyNames)return propertyNames;hasRequiredPropertyNames=1,Object.defineProperty(propertyNames,"__esModule",{value:!0});const e=requireCodegen(),t=requireUtil(),tt={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:{message:"property name must be valid",params:({params:rt})=>(0,e._)`{propertyName: ${rt.propertyName}}`},code(rt){const{gen:nt,schema:at,data:it,it:ot}=rt;if((0,t.alwaysValidSchema)(ot,at))return;const ct=nt.name("valid");nt.forIn("key",it,At=>{rt.setParams({propertyName:At}),rt.subschema({keyword:"propertyNames",data:At,dataTypes:["string"],propertyName:At,compositeRule:!0},ct),nt.if((0,e.not)(ct),()=>{rt.error(!0),ot.allErrors||nt.break()})}),rt.ok(ct)}};return propertyNames.default=tt,propertyNames}var additionalProperties={},hasRequiredAdditionalProperties;function requireAdditionalProperties(){if(hasRequiredAdditionalProperties)return additionalProperties;hasRequiredAdditionalProperties=1,Object.defineProperty(additionalProperties,"__esModule",{value:!0});const e=requireCode(),t=requireCodegen(),Ye=requireNames(),tt=requireUtil(),nt={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:{message:"must NOT have additional properties",params:({params:at})=>(0,t._)`{additionalProperty: ${at.additionalProperty}}`},code(at){const{gen:it,schema:ot,parentSchema:ct,data:At,errsCount:Rt,it:qt}=at;if(!Rt)throw new Error("ajv implementation error");const{allErrors:Ft,opts:Ut}=qt;if(qt.props=!0,Ut.removeAdditional!=="all"&&(0,tt.alwaysValidSchema)(qt,ot))return;const Ht=(0,e.allSchemaProperties)(ct.properties),zt=(0,e.allSchemaProperties)(ct.patternProperties);Yt(),at.ok((0,t._)`${Rt} === ${Ye.default.errors}`);function Yt(){it.forIn("key",At,Qt=>{!Ht.length&&!zt.length?Zt(Qt):it.if(Gt(Qt),()=>Zt(Qt))})}function Gt(Qt){let er;if(Ht.length>8){const nr=(0,tt.schemaRefOrVal)(qt,ct.properties,"properties");er=(0,e.isOwnProperty)(it,nr,Qt)}else Ht.length?er=(0,t.or)(...Ht.map(nr=>(0,t._)`${Qt} === ${nr}`)):er=t.nil;return zt.length&&(er=(0,t.or)(er,...zt.map(nr=>(0,t._)`${(0,e.usePattern)(at,nr)}.test(${Qt})`))),(0,t.not)(er)}function Vt(Qt){it.code((0,t._)`delete ${At}[${Qt}]`)}function Zt(Qt){if(Ut.removeAdditional==="all"||Ut.removeAdditional&&ot===!1){Vt(Qt);return}if(ot===!1){at.setParams({additionalProperty:Qt}),at.error(),Ft||it.break();return}if(typeof ot=="object"&&!(0,tt.alwaysValidSchema)(qt,ot)){const er=it.name("valid");Ut.removeAdditional==="failing"?(Xt(Qt,er,!1),it.if((0,t.not)(er),()=>{at.reset(),Vt(Qt)})):(Xt(Qt,er),Ft||it.if((0,t.not)(er),()=>it.break()))}}function Xt(Qt,er,nr){const ar={keyword:"additionalProperties",dataProp:Qt,dataPropType:tt.Type.Str};nr===!1&&Object.assign(ar,{compositeRule:!0,createErrors:!1,allErrors:!1}),at.subschema(ar,er)}}};return additionalProperties.default=nt,additionalProperties}var properties$1={},hasRequiredProperties;function requireProperties(){if(hasRequiredProperties)return properties$1;hasRequiredProperties=1,Object.defineProperty(properties$1,"__esModule",{value:!0});const e=requireValidate(),t=requireCode(),Ye=requireUtil(),tt=requireAdditionalProperties(),rt={keyword:"properties",type:"object",schemaType:"object",code(nt){const{gen:at,schema:it,parentSchema:ot,data:ct,it:At}=nt;At.opts.removeAdditional==="all"&&ot.additionalProperties===void 0&&tt.default.code(new e.KeywordCxt(At,tt.default,"additionalProperties"));const Rt=(0,t.allSchemaProperties)(it);for(const zt of Rt)At.definedProperties.add(zt);At.opts.unevaluated&&Rt.length&&At.props!==!0&&(At.props=Ye.mergeEvaluated.props(at,(0,Ye.toHash)(Rt),At.props));const qt=Rt.filter(zt=>!(0,Ye.alwaysValidSchema)(At,it[zt]));if(qt.length===0)return;const Ft=at.name("valid");for(const zt of qt)Ut(zt)?Ht(zt):(at.if((0,t.propertyInData)(at,ct,zt,At.opts.ownProperties)),Ht(zt),At.allErrors||at.else().var(Ft,!0),at.endIf()),nt.it.definedProperties.add(zt),nt.ok(Ft);function Ut(zt){return At.opts.useDefaults&&!At.compositeRule&&it[zt].default!==void 0}function Ht(zt){nt.subschema({keyword:"properties",schemaProp:zt,dataProp:zt},Ft)}}};return properties$1.default=rt,properties$1}var patternProperties={},hasRequiredPatternProperties;function requirePatternProperties(){if(hasRequiredPatternProperties)return patternProperties;hasRequiredPatternProperties=1,Object.defineProperty(patternProperties,"__esModule",{value:!0});const e=requireCode(),t=requireCodegen(),Ye=requireUtil(),tt=requireUtil(),rt={keyword:"patternProperties",type:"object",schemaType:"object",code(nt){const{gen:at,schema:it,data:ot,parentSchema:ct,it:At}=nt,{opts:Rt}=At,qt=(0,e.allSchemaProperties)(it),Ft=qt.filter(Zt=>(0,Ye.alwaysValidSchema)(At,it[Zt]));if(qt.length===0||Ft.length===qt.length&&(!At.opts.unevaluated||At.props===!0))return;const Ut=Rt.strictSchema&&!Rt.allowMatchingProperties&&ct.properties,Ht=at.name("valid");At.props!==!0&&!(At.props instanceof t.Name)&&(At.props=(0,tt.evaluatedPropsToName)(at,At.props));const{props:zt}=At;Yt();function Yt(){for(const Zt of qt)Ut&&Gt(Zt),At.allErrors?Vt(Zt):(at.var(Ht,!0),Vt(Zt),at.if(Ht))}function Gt(Zt){for(const Xt in Ut)new RegExp(Zt).test(Xt)&&(0,Ye.checkStrictMode)(At,`property ${Xt} matches pattern ${Zt} (use allowMatchingProperties)`)}function Vt(Zt){at.forIn("key",ot,Xt=>{at.if((0,t._)`${(0,e.usePattern)(nt,Zt)}.test(${Xt})`,()=>{const Qt=Ft.includes(Zt);Qt||nt.subschema({keyword:"patternProperties",schemaProp:Zt,dataProp:Xt,dataPropType:tt.Type.Str},Ht),At.opts.unevaluated&&zt!==!0?at.assign((0,t._)`${zt}[${Xt}]`,!0):!Qt&&!At.allErrors&&at.if((0,t.not)(Ht),()=>at.break())})})}}};return patternProperties.default=rt,patternProperties}var not={},hasRequiredNot;function requireNot(){if(hasRequiredNot)return not;hasRequiredNot=1,Object.defineProperty(not,"__esModule",{value:!0});const e=requireUtil(),t={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(Ye){const{gen:tt,schema:rt,it:nt}=Ye;if((0,e.alwaysValidSchema)(nt,rt)){Ye.fail();return}const at=tt.name("valid");Ye.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},at),Ye.failResult(at,()=>Ye.reset(),()=>Ye.error())},error:{message:"must NOT be valid"}};return not.default=t,not}var anyOf={},hasRequiredAnyOf;function requireAnyOf(){if(hasRequiredAnyOf)return anyOf;hasRequiredAnyOf=1,Object.defineProperty(anyOf,"__esModule",{value:!0});const t={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:requireCode().validateUnion,error:{message:"must match a schema in anyOf"}};return anyOf.default=t,anyOf}var oneOf={},hasRequiredOneOf;function requireOneOf(){if(hasRequiredOneOf)return oneOf;hasRequiredOneOf=1,Object.defineProperty(oneOf,"__esModule",{value:!0});const e=requireCodegen(),t=requireUtil(),tt={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:{message:"must match exactly one schema in oneOf",params:({params:rt})=>(0,e._)`{passingSchemas: ${rt.passing}}`},code(rt){const{gen:nt,schema:at,parentSchema:it,it:ot}=rt;if(!Array.isArray(at))throw new Error("ajv implementation error");if(ot.opts.discriminator&&it.discriminator)return;const ct=at,At=nt.let("valid",!1),Rt=nt.let("passing",null),qt=nt.name("_valid");rt.setParams({passing:Rt}),nt.block(Ft),rt.result(At,()=>rt.reset(),()=>rt.error(!0));function Ft(){ct.forEach((Ut,Ht)=>{let zt;(0,t.alwaysValidSchema)(ot,Ut)?nt.var(qt,!0):zt=rt.subschema({keyword:"oneOf",schemaProp:Ht,compositeRule:!0},qt),Ht>0&&nt.if((0,e._)`${qt} && ${At}`).assign(At,!1).assign(Rt,(0,e._)`[${Rt}, ${Ht}]`).else(),nt.if(qt,()=>{nt.assign(At,!0),nt.assign(Rt,Ht),zt&&rt.mergeEvaluated(zt,e.Name)})})}}};return oneOf.default=tt,oneOf}var allOf={},hasRequiredAllOf;function requireAllOf(){if(hasRequiredAllOf)return allOf;hasRequiredAllOf=1,Object.defineProperty(allOf,"__esModule",{value:!0});const e=requireUtil(),t={keyword:"allOf",schemaType:"array",code(Ye){const{gen:tt,schema:rt,it:nt}=Ye;if(!Array.isArray(rt))throw new Error("ajv implementation error");const at=tt.name("valid");rt.forEach((it,ot)=>{if((0,e.alwaysValidSchema)(nt,it))return;const ct=Ye.subschema({keyword:"allOf",schemaProp:ot},at);Ye.ok(at),Ye.mergeEvaluated(ct)})}};return allOf.default=t,allOf}var _if={},hasRequired_if;function require_if(){if(hasRequired_if)return _if;hasRequired_if=1,Object.defineProperty(_if,"__esModule",{value:!0});const e=requireCodegen(),t=requireUtil(),tt={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:{message:({params:nt})=>(0,e.str)`must match "${nt.ifClause}" schema`,params:({params:nt})=>(0,e._)`{failingKeyword: ${nt.ifClause}}`},code(nt){const{gen:at,parentSchema:it,it:ot}=nt;it.then===void 0&&it.else===void 0&&(0,t.checkStrictMode)(ot,'"if" without "then" and "else" is ignored');const ct=rt(ot,"then"),At=rt(ot,"else");if(!ct&&!At)return;const Rt=at.let("valid",!0),qt=at.name("_valid");if(Ft(),nt.reset(),ct&&At){const Ht=at.let("ifClause");nt.setParams({ifClause:Ht}),at.if(qt,Ut("then",Ht),Ut("else",Ht))}else ct?at.if(qt,Ut("then")):at.if((0,e.not)(qt),Ut("else"));nt.pass(Rt,()=>nt.error(!0));function Ft(){const Ht=nt.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},qt);nt.mergeEvaluated(Ht)}function Ut(Ht,zt){return()=>{const Yt=nt.subschema({keyword:Ht},qt);at.assign(Rt,qt),nt.mergeValidEvaluated(Yt,Rt),zt?at.assign(zt,(0,e._)`${Ht}`):nt.setParams({ifClause:Ht})}}}};function rt(nt,at){const it=nt.schema[at];return it!==void 0&&!(0,t.alwaysValidSchema)(nt,it)}return _if.default=tt,_if}var thenElse={},hasRequiredThenElse;function requireThenElse(){if(hasRequiredThenElse)return thenElse;hasRequiredThenElse=1,Object.defineProperty(thenElse,"__esModule",{value:!0});const e=requireUtil(),t={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:Ye,parentSchema:tt,it:rt}){tt.if===void 0&&(0,e.checkStrictMode)(rt,`"${Ye}" without "if" is ignored`)}};return thenElse.default=t,thenElse}var hasRequiredApplicator;function requireApplicator(){if(hasRequiredApplicator)return applicator;hasRequiredApplicator=1,Object.defineProperty(applicator,"__esModule",{value:!0});const e=requireAdditionalItems(),t=requirePrefixItems(),Ye=requireItems(),tt=requireItems2020(),rt=requireContains(),nt=requireDependencies(),at=requirePropertyNames(),it=requireAdditionalProperties(),ot=requireProperties(),ct=requirePatternProperties(),At=requireNot(),Rt=requireAnyOf(),qt=requireOneOf(),Ft=requireAllOf(),Ut=require_if(),Ht=requireThenElse();function zt(Yt=!1){const Gt=[At.default,Rt.default,qt.default,Ft.default,Ut.default,Ht.default,at.default,it.default,nt.default,ot.default,ct.default];return Yt?Gt.push(t.default,tt.default):Gt.push(e.default,Ye.default),Gt.push(rt.default),Gt}return applicator.default=zt,applicator}var format$1={},format={},hasRequiredFormat$1;function requireFormat$1(){if(hasRequiredFormat$1)return format;hasRequiredFormat$1=1,Object.defineProperty(format,"__esModule",{value:!0});const e=requireCodegen(),Ye={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:{message:({schemaCode:tt})=>(0,e.str)`must match format "${tt}"`,params:({schemaCode:tt})=>(0,e._)`{format: ${tt}}`},code(tt,rt){const{gen:nt,data:at,$data:it,schema:ot,schemaCode:ct,it:At}=tt,{opts:Rt,errSchemaPath:qt,schemaEnv:Ft,self:Ut}=At;if(!Rt.validateFormats)return;it?Ht():zt();function Ht(){const Yt=nt.scopeValue("formats",{ref:Ut.formats,code:Rt.code.formats}),Gt=nt.const("fDef",(0,e._)`${Yt}[${ct}]`),Vt=nt.let("fType"),Zt=nt.let("format");nt.if((0,e._)`typeof ${Gt} == "object" && !(${Gt} instanceof RegExp)`,()=>nt.assign(Vt,(0,e._)`${Gt}.type || "string"`).assign(Zt,(0,e._)`${Gt}.validate`),()=>nt.assign(Vt,(0,e._)`"string"`).assign(Zt,Gt)),tt.fail$data((0,e.or)(Xt(),Qt()));function Xt(){return Rt.strictSchema===!1?e.nil:(0,e._)`${ct} && !${Zt}`}function Qt(){const er=Ft.$async?(0,e._)`(${Gt}.async ? await ${Zt}(${at}) : ${Zt}(${at}))`:(0,e._)`${Zt}(${at})`,nr=(0,e._)`(typeof ${Zt} == "function" ? ${er} : ${Zt}.test(${at}))`;return(0,e._)`${Zt} && ${Zt} !== true && ${Vt} === ${rt} && !${nr}`}}function zt(){const Yt=Ut.formats[ot];if(!Yt){Xt();return}if(Yt===!0)return;const[Gt,Vt,Zt]=Qt(Yt);Gt===rt&&tt.pass(er());function Xt(){if(Rt.strictSchema===!1){Ut.logger.warn(nr());return}throw new Error(nr());function nr(){return`unknown format "${ot}" ignored in schema at path "${qt}"`}}function Qt(nr){const ar=nr instanceof RegExp?(0,e.regexpCode)(nr):Rt.code.formats?(0,e._)`${Rt.code.formats}${(0,e.getProperty)(ot)}`:void 0,sr=nt.scopeValue("formats",{key:ot,ref:nr,code:ar});return typeof nr=="object"&&!(nr instanceof RegExp)?[nr.type||"string",nr.validate,(0,e._)`${sr}.validate`]:["string",nr,sr]}function er(){if(typeof Yt=="object"&&!(Yt instanceof RegExp)&&Yt.async){if(!Ft.$async)throw new Error("async format in sync schema");return(0,e._)`await ${Zt}(${at})`}return typeof Vt=="function"?(0,e._)`${Zt}(${at})`:(0,e._)`${Zt}.test(${at})`}}}};return format.default=Ye,format}var hasRequiredFormat;function requireFormat(){if(hasRequiredFormat)return format$1;hasRequiredFormat=1,Object.defineProperty(format$1,"__esModule",{value:!0});const t=[requireFormat$1().default];return format$1.default=t,format$1}var metadata={},hasRequiredMetadata;function requireMetadata(){return hasRequiredMetadata||(hasRequiredMetadata=1,Object.defineProperty(metadata,"__esModule",{value:!0}),metadata.contentVocabulary=metadata.metadataVocabulary=void 0,metadata.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"],metadata.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]),metadata}var hasRequiredDraft7;function requireDraft7(){if(hasRequiredDraft7)return draft7;hasRequiredDraft7=1,Object.defineProperty(draft7,"__esModule",{value:!0});const e=requireCore(),t=requireValidation(),Ye=requireApplicator(),tt=requireFormat(),rt=requireMetadata(),nt=[e.default,t.default,(0,Ye.default)(),tt.default,rt.metadataVocabulary,rt.contentVocabulary];return draft7.default=nt,draft7}var discriminator={},types={},hasRequiredTypes;function requireTypes(){if(hasRequiredTypes)return types;hasRequiredTypes=1,Object.defineProperty(types,"__esModule",{value:!0}),types.DiscrError=void 0;var e;return function(t){t.Tag="tag",t.Mapping="mapping"}(e||(types.DiscrError=e={})),types}var hasRequiredDiscriminator;function requireDiscriminator(){if(hasRequiredDiscriminator)return discriminator;hasRequiredDiscriminator=1,Object.defineProperty(discriminator,"__esModule",{value:!0});const e=requireCodegen(),t=requireTypes(),Ye=requireCompile(),tt=requireRef_error(),rt=requireUtil(),at={keyword:"discriminator",type:"object",schemaType:"object",error:{message:({params:{discrError:it,tagName:ot}})=>it===t.DiscrError.Tag?`tag "${ot}" must be string`:`value of tag "${ot}" must be in oneOf`,params:({params:{discrError:it,tag:ot,tagName:ct}})=>(0,e._)`{error: ${it}, tag: ${ct}, tagValue: ${ot}}`},code(it){const{gen:ot,data:ct,schema:At,parentSchema:Rt,it:qt}=it,{oneOf:Ft}=Rt;if(!qt.opts.discriminator)throw new Error("discriminator: requires discriminator option");const Ut=At.propertyName;if(typeof Ut!="string")throw new Error("discriminator: requires propertyName");if(At.mapping)throw new Error("discriminator: mapping is not supported");if(!Ft)throw new Error("discriminator: requires oneOf keyword");const Ht=ot.let("valid",!1),zt=ot.const("tag",(0,e._)`${ct}${(0,e.getProperty)(Ut)}`);ot.if((0,e._)`typeof ${zt} == "string"`,()=>Yt(),()=>it.error(!1,{discrError:t.DiscrError.Tag,tag:zt,tagName:Ut})),it.ok(Ht);function Yt(){const Zt=Vt();ot.if(!1);for(const Xt in Zt)ot.elseIf((0,e._)`${zt} === ${Xt}`),ot.assign(Ht,Gt(Zt[Xt]));ot.else(),it.error(!1,{discrError:t.DiscrError.Mapping,tag:zt,tagName:Ut}),ot.endIf()}function Gt(Zt){const Xt=ot.name("valid"),Qt=it.subschema({keyword:"oneOf",schemaProp:Zt},Xt);return it.mergeEvaluated(Qt,e.Name),Xt}function Vt(){var Zt;const Xt={},Qt=nr(Rt);let er=!0;for(let lr=0;lr<Ft.length;lr++){let fr=Ft[lr];if(fr!=null&&fr.$ref&&!(0,rt.schemaHasRulesButRef)(fr,qt.self.RULES)){const dr=fr.$ref;if(fr=Ye.resolveRef.call(qt.self,qt.schemaEnv.root,qt.baseId,dr),fr instanceof Ye.SchemaEnv&&(fr=fr.schema),fr===void 0)throw new tt.default(qt.opts.uriResolver,qt.baseId,dr)}const gr=(Zt=fr==null?void 0:fr.properties)===null||Zt===void 0?void 0:Zt[Ut];if(typeof gr!="object")throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${Ut}"`);er=er&&(Qt||nr(fr)),ar(gr,lr)}if(!er)throw new Error(`discriminator: "${Ut}" must be required`);return Xt;function nr({required:lr}){return Array.isArray(lr)&&lr.includes(Ut)}function ar(lr,fr){if(lr.const)sr(lr.const,fr);else if(lr.enum)for(const gr of lr.enum)sr(gr,fr);else throw new Error(`discriminator: "properties/${Ut}" must have "const" or "enum"`)}function sr(lr,fr){if(typeof lr!="string"||lr in Xt)throw new Error(`discriminator: "${Ut}" values must be unique strings`);Xt[lr]=fr}}}};return discriminator.default=at,discriminator}const $schema="http://json-schema.org/draft-07/schema#",$id="http://json-schema.org/draft-07/schema#",title="Core schema meta-schema",definitions={schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},type=["object","boolean"],properties={$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:!0,readOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:!0},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:!0,enum:{type:"array",items:!0,minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},require$$3={$schema,$id,title,definitions,type,properties,default:!0};var hasRequiredAjv;function requireAjv(){return hasRequiredAjv||(hasRequiredAjv=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.MissingRefError=t.ValidationError=t.CodeGen=t.Name=t.nil=t.stringify=t.str=t._=t.KeywordCxt=t.Ajv=void 0;const Ye=requireCore$1(),tt=requireDraft7(),rt=requireDiscriminator(),nt=require$$3,at=["/properties"],it="http://json-schema.org/draft-07/schema";class ot extends Ye.default{_addVocabularies(){super._addVocabularies(),tt.default.forEach(Ut=>this.addVocabulary(Ut)),this.opts.discriminator&&this.addKeyword(rt.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;const Ut=this.opts.$data?this.$dataMetaSchema(nt,at):nt;this.addMetaSchema(Ut,it,!1),this.refs["http://json-schema.org/schema"]=it}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(it)?it:void 0)}}t.Ajv=ot,e.exports=t=ot,e.exports.Ajv=ot,Object.defineProperty(t,"__esModule",{value:!0}),t.default=ot;var ct=requireValidate();Object.defineProperty(t,"KeywordCxt",{enumerable:!0,get:function(){return ct.KeywordCxt}});var At=requireCodegen();Object.defineProperty(t,"_",{enumerable:!0,get:function(){return At._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return At.str}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return At.stringify}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return At.nil}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return At.Name}}),Object.defineProperty(t,"CodeGen",{enumerable:!0,get:function(){return At.CodeGen}});var Rt=requireValidation_error();Object.defineProperty(t,"ValidationError",{enumerable:!0,get:function(){return Rt.default}});var qt=requireRef_error();Object.defineProperty(t,"MissingRefError",{enumerable:!0,get:function(){return qt.default}})}(ajv,ajv.exports)),ajv.exports}var ajvExports=requireAjv();const Ajv=getDefaultExportFromCjs(ajvExports);var dist={exports:{}},formats={},hasRequiredFormats;function requireFormats(){return hasRequiredFormats||(hasRequiredFormats=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.formatNames=e.fastFormats=e.fullFormats=void 0;function t(ar,sr){return{validate:ar,compare:sr}}e.fullFormats={date:t(nt,at),time:t(ot,ct),"date-time":t(Rt,qt),duration:/^P(?!$)((\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+S)?)?|(\d+W)?)$/,uri:Ht,"uri-reference":/^(?:[a-z][a-z0-9+\-.]*:)?(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'"()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'"()*+,;=:@]|%[0-9a-f]{2})*)*)?(?:\?(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'"()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i,"uri-template":/^(?:(?:[^\x00-\x20"'<>%\\^`{|}]|%[0-9a-f]{2})|\{[+#./;?&=,!@|]?(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?(?:,(?:[a-z0-9_]|%[0-9a-f]{2})+(?::[1-9][0-9]{0,3}|\*)?)*\})*$/i,url:/^(?:https?|ftp):\/\/(?:\S+(?::\S*)?@)?(?:(?!(?:10|127)(?:\.\d{1,3}){3})(?!(?:169\.254|192\.168)(?:\.\d{1,3}){2})(?!172\.(?:1[6-9]|2\d|3[0-1])(?:\.\d{1,3}){2})(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)(?:\.(?:[a-z0-9\u{00a1}-\u{ffff}]+-)*[a-z0-9\u{00a1}-\u{ffff}]+)*(?:\.(?:[a-z\u{00a1}-\u{ffff}]{2,})))(?::\d{2,5})?(?:\/[^\s]*)?$/iu,email:/^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i,hostname:/^(?=.{1,253}\.?$)[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[-0-9a-z]{0,61}[0-9a-z])?)*\.?$/i,ipv4:/^(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)$/,ipv6:/^((([0-9a-f]{1,4}:){7}([0-9a-f]{1,4}|:))|(([0-9a-f]{1,4}:){6}(:[0-9a-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){5}(((:[0-9a-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9a-f]{1,4}:){4}(((:[0-9a-f]{1,4}){1,3})|((:[0-9a-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){3}(((:[0-9a-f]{1,4}){1,4})|((:[0-9a-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){2}(((:[0-9a-f]{1,4}){1,5})|((:[0-9a-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9a-f]{1,4}:){1}(((:[0-9a-f]{1,4}){1,6})|((:[0-9a-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9a-f]{1,4}){1,7})|((:[0-9a-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))$/i,regex:nr,uuid:/^(?:urn:uuid:)?[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i,"json-pointer":/^(?:\/(?:[^~/]|~0|~1)*)*$/,"json-pointer-uri-fragment":/^#(?:\/(?:[a-z0-9_\-.!$&'()*+,;:=@]|%[0-9a-f]{2}|~0|~1)*)*$/i,"relative-json-pointer":/^(?:0|[1-9][0-9]*)(?:#|(?:\/(?:[^~/]|~0|~1)*)*)$/,byte:Yt,int32:{type:"number",validate:Zt},int64:{type:"number",validate:Xt},float:{type:"number",validate:Qt},double:{type:"number",validate:Qt},password:!0,binary:!0},e.fastFormats={...e.fullFormats,date:t(/^\d\d\d\d-[0-1]\d-[0-3]\d$/,at),time:t(/^(?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)?$/i,ct),"date-time":t(/^\d\d\d\d-[0-1]\d-[0-3]\d[t\s](?:[0-2]\d:[0-5]\d:[0-5]\d|23:59:60)(?:\.\d+)?(?:z|[+-]\d\d(?::?\d\d)?)$/i,qt),uri:/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/)?[^\s]*$/i,"uri-reference":/^(?:(?:[a-z][a-z0-9+\-.]*:)?\/?\/)?(?:[^\\\s#][^\s#]*)?(?:#[^\\\s]*)?$/i,email:/^[a-z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?(?:\.[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?)*$/i},e.formatNames=Object.keys(e.fullFormats);function Ye(ar){return ar%4===0&&(ar%100!==0||ar%400===0)}const tt=/^(\d\d\d\d)-(\d\d)-(\d\d)$/,rt=[0,31,28,31,30,31,30,31,31,30,31,30,31];function nt(ar){const sr=tt.exec(ar);if(!sr)return!1;const lr=+sr[1],fr=+sr[2],gr=+sr[3];return fr>=1&&fr<=12&&gr>=1&&gr<=(fr===2&&Ye(lr)?29:rt[fr])}function at(ar,sr){if(ar&&sr)return ar>sr?1:ar<sr?-1:0}const it=/^(\d\d):(\d\d):(\d\d)(\.\d+)?(z|[+-]\d\d(?::?\d\d)?)?$/i;function ot(ar,sr){const lr=it.exec(ar);if(!lr)return!1;const fr=+lr[1],gr=+lr[2],dr=+lr[3],vr=lr[5];return(fr<=23&&gr<=59&&dr<=59||fr===23&&gr===59&&dr===60)&&(!sr||vr!=="")}function ct(ar,sr){if(!(ar&&sr))return;const lr=it.exec(ar),fr=it.exec(sr);if(lr&&fr)return ar=lr[1]+lr[2]+lr[3]+(lr[4]||""),sr=fr[1]+fr[2]+fr[3]+(fr[4]||""),ar>sr?1:ar<sr?-1:0}const At=/t|\s/i;function Rt(ar){const sr=ar.split(At);return sr.length===2&&nt(sr[0])&&ot(sr[1],!0)}function qt(ar,sr){if(!(ar&&sr))return;const[lr,fr]=ar.split(At),[gr,dr]=sr.split(At),vr=at(lr,gr);if(vr!==void 0)return vr||ct(fr,dr)}const Ft=/\/|:/,Ut=/^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i;function Ht(ar){return Ft.test(ar)&&Ut.test(ar)}const zt=/^(?:[A-Za-z0-9+/]{4})*(?:[A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/gm;function Yt(ar){return zt.lastIndex=0,zt.test(ar)}const Gt=-2147483648,Vt=2**31-1;function Zt(ar){return Number.isInteger(ar)&&ar<=Vt&&ar>=Gt}function Xt(ar){return Number.isInteger(ar)}function Qt(){return!0}const er=/[^\\]\\Z/;function nr(ar){if(er.test(ar))return!1;try{return new RegExp(ar),!0}catch{return!1}}}(formats)),formats}var limit={},hasRequiredLimit;function requireLimit(){return hasRequiredLimit||(hasRequiredLimit=1,function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.formatLimitDefinition=void 0;const t=requireAjv(),Ye=requireCodegen(),tt=Ye.operators,rt={formatMaximum:{okStr:"<=",ok:tt.LTE,fail:tt.GT},formatMinimum:{okStr:">=",ok:tt.GTE,fail:tt.LT},formatExclusiveMaximum:{okStr:"<",ok:tt.LT,fail:tt.GTE},formatExclusiveMinimum:{okStr:">",ok:tt.GT,fail:tt.LTE}},nt={message:({keyword:it,schemaCode:ot})=>Ye.str`should be ${rt[it].okStr} ${ot}`,params:({keyword:it,schemaCode:ot})=>Ye._`{comparison: ${rt[it].okStr}, limit: ${ot}}`};e.formatLimitDefinition={keyword:Object.keys(rt),type:"string",schemaType:"string",$data:!0,error:nt,code(it){const{gen:ot,data:ct,schemaCode:At,keyword:Rt,it:qt}=it,{opts:Ft,self:Ut}=qt;if(!Ft.validateFormats)return;const Ht=new t.KeywordCxt(qt,Ut.RULES.all.format.definition,"format");Ht.$data?zt():Yt();function zt(){const Vt=ot.scopeValue("formats",{ref:Ut.formats,code:Ft.code.formats}),Zt=ot.const("fmt",Ye._`${Vt}[${Ht.schemaCode}]`);it.fail$data(Ye.or(Ye._`typeof ${Zt} != "object"`,Ye._`${Zt} instanceof RegExp`,Ye._`typeof ${Zt}.compare != "function"`,Gt(Zt)))}function Yt(){const Vt=Ht.schema,Zt=Ut.formats[Vt];if(!Zt||Zt===!0)return;if(typeof Zt!="object"||Zt instanceof RegExp||typeof Zt.compare!="function")throw new Error(`"${Rt}": format "${Vt}" does not define "compare" function`);const Xt=ot.scopeValue("formats",{key:Vt,ref:Zt,code:Ft.code.formats?Ye._`${Ft.code.formats}${Ye.getProperty(Vt)}`:void 0});it.fail$data(Gt(Xt))}function Gt(Vt){return Ye._`${Vt}.compare(${ct}, ${At}) ${rt[Rt].fail} 0`}},dependencies:["format"]};const at=it=>(it.addKeyword(e.formatLimitDefinition),it);e.default=at}(limit)),limit}var hasRequiredDist;function requireDist(){return hasRequiredDist||(hasRequiredDist=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0});const Ye=requireFormats(),tt=requireLimit(),rt=requireCodegen(),nt=new rt.Name("fullFormats"),at=new rt.Name("fastFormats"),it=(ct,At={keywords:!0})=>{if(Array.isArray(At))return ot(ct,At,Ye.fullFormats,nt),ct;const[Rt,qt]=At.mode==="fast"?[Ye.fastFormats,at]:[Ye.fullFormats,nt],Ft=At.formats||Ye.formatNames;return ot(ct,Ft,Rt,qt),At.keywords&&tt.default(ct),ct};it.get=(ct,At="full")=>{const qt=(At==="fast"?Ye.fastFormats:Ye.fullFormats)[ct];if(!qt)throw new Error(`Unknown format "${ct}"`);return qt};function ot(ct,At,Rt,qt){var Ft,Ut;(Ft=(Ut=ct.opts.code).formats)!==null&&Ft!==void 0||(Ut.formats=rt._`require("ajv-formats/dist/formats").${qt}`);for(const Ht of At)ct.addFormat(Ht,Rt[Ht])}e.exports=t=it,Object.defineProperty(t,"__esModule",{value:!0}),t.default=it}(dist,dist.exports)),dist.exports}var distExports=requireDist();const addFormats=getDefaultExportFromCjs(distExports),AJV_CONFIG={allErrors:!0,multipleOfPrecision:8,strict:!1,verbose:!0,discriminator:!1},COLOR_FORMAT_REGEX=/^(#?([0-9A-Fa-f]{3}){1,2}\b|aqua|black|blue|fuchsia|gray|green|lime|maroon|navy|olive|orange|purple|red|silver|teal|white|yellow|(rgb\(\s*\b([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\b\s*,\s*\b([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\b\s*,\s*\b([0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])\b\s*\))|(rgb\(\s*(\d?\d%|100%)+\s*,\s*(\d?\d%|100%)+\s*,\s*(\d?\d%|100%)+\s*\)))$/,DATA_URL_FORMAT_REGEX=/^data:([a-z]+\/[a-z0-9-+.]+)?;(?:name=(.*);)?base64,(.*)$/;function createAjvInstance(e,t,Ye={},tt,rt=Ajv){const nt=new rt({...AJV_CONFIG,...Ye});return tt?addFormats(nt,tt):tt!==!1&&addFormats(nt),nt.addFormat("data-url",DATA_URL_FORMAT_REGEX),nt.addFormat("color",COLOR_FORMAT_REGEX),nt.addKeyword(ADDITIONAL_PROPERTY_FLAG),nt.addKeyword(RJSF_ADDITIONAL_PROPERTIES_FLAG),Array.isArray(e)&&nt.addMetaSchema(e),isObject(t)&&Object.keys(t).forEach(at=>{nt.addFormat(at,t[at])}),nt}function transformRJSFValidationErrors(e=[],t){return e.map(Ye=>{var tt;const{instancePath:rt,keyword:nt,params:at,schemaPath:it,parentSchema:ot,...ct}=Ye;let{message:At=""}=ct,Rt=rt.replace(/\//g,"."),qt=`${Rt} ${At}`.trim();const Ft=[...((tt=at.deps)===null||tt===void 0?void 0:tt.split(", "))||[],at.missingProperty,at.property].filter(Ut=>Ut);if(Ft.length>0)Ft.forEach(Ut=>{const Ht=Rt?`${Rt}.${Ut}`:Ut;let zt=getUiOptions(get(t,`${Ht.replace(/^\./,"")}`)).title;if(zt===void 0){const Yt=it.replace(/\/properties\//g,"/").split("/").slice(1,-1).concat([Ut]);zt=getUiOptions(get(t,Yt)).title}if(zt)At=At.replace(`'${Ut}'`,`'${zt}'`);else{const Yt=get(ot,[PROPERTIES_KEY,Ut,"title"]);Yt&&(At=At.replace(`'${Ut}'`,`'${Yt}'`))}}),qt=At;else{const Ut=getUiOptions(get(t,`${Rt.replace(/^\./,"")}`)).title;if(Ut)qt=`'${Ut}' ${At}`.trim();else{const Ht=ot==null?void 0:ot.title;Ht&&(qt=`'${Ht}' ${At}`.trim())}}return"missingProperty"in at&&(Rt=Rt?`${Rt}.${at.missingProperty}`:at.missingProperty),{name:nt,property:Rt,message:At,params:at,stack:qt,schemaPath:it}})}function processRawValidationErrors(e,t,Ye,tt,rt,nt,at){const{validationError:it}=t;let ot=transformRJSFValidationErrors(t.errors,at);it&&(ot=[...ot,{stack:it.message}]),typeof nt=="function"&&(ot=nt(ot,at));let ct=toErrorSchema(ot);if(it&&(ct={...ct,$schema:{__errors:[it.message]}}),typeof rt!="function")return{errors:ot,errorSchema:ct};const At=getDefaultFormState(e,tt,Ye,tt,!0),Rt=rt(At,createErrorHandler(At),at),qt=unwrapErrorHandler(Rt);return validationDataMerge({errors:ot,errorSchema:ct},qt)}class AJV8Validator{constructor(t,Ye){const{additionalMetaSchemas:tt,customFormats:rt,ajvOptionsOverrides:nt,ajvFormatOptions:at,AjvClass:it}=t;this.ajv=createAjvInstance(tt,rt,nt,at,it),this.localizer=Ye}reset(){this.ajv.removeSchema()}toErrorList(t,Ye=[]){return toErrorList(t,Ye)}rawValidation(t,Ye){var tt,rt;let nt,at;t[ID_KEY]&&(at=this.ajv.getSchema(t[ID_KEY]));try{at===void 0&&(at=this.ajv.compile(t)),at(Ye)}catch(ot){nt=ot}let it;return at&&(typeof this.localizer=="function"&&(((tt=at.errors)!==null&&tt!==void 0?tt:[]).forEach(ot=>{var ct;["missingProperty","property"].forEach(At=>{var Rt;!((Rt=ot.params)===null||Rt===void 0)&&Rt[At]&&(ot.params[At]=`'${ot.params[At]}'`)}),!((ct=ot.params)===null||ct===void 0)&&ct.deps&&(ot.params.deps=ot.params.deps.split(", ").map(At=>`'${At}'`).join(", "))}),this.localizer(at.errors),((rt=at.errors)!==null&&rt!==void 0?rt:[]).forEach(ot=>{var ct;["missingProperty","property"].forEach(At=>{var Rt;!((Rt=ot.params)===null||Rt===void 0)&&Rt[At]&&(ot.params[At]=ot.params[At].slice(1,-1))}),!((ct=ot.params)===null||ct===void 0)&&ct.deps&&(ot.params.deps=ot.params.deps.split(", ").map(At=>At.slice(1,-1)).join(", "))})),it=at.errors||void 0,at.errors=null),{errors:it,validationError:nt}}validateFormData(t,Ye,tt,rt,nt){const at=this.rawValidation(Ye,t);return processRawValidationErrors(this,at,t,Ye,tt,rt,nt)}handleSchemaUpdate(t){var Ye,tt;const rt=(Ye=t[ID_KEY])!==null&&Ye!==void 0?Ye:ROOT_SCHEMA_PREFIX;this.ajv.getSchema(rt)===void 0?this.ajv.addSchema(t,rt):deepEquals(t,(tt=this.ajv.getSchema(rt))===null||tt===void 0?void 0:tt.schema)||(this.ajv.removeSchema(rt),this.ajv.addSchema(t,rt))}isValid(t,Ye,tt){var rt;try{this.handleSchemaUpdate(tt);const nt=withIdRefPrefix(t),at=(rt=nt[ID_KEY])!==null&&rt!==void 0?rt:hashForSchema(nt);let it;return it=this.ajv.getSchema(at),it===void 0&&(it=this.ajv.addSchema(nt,at).getSchema(at)||this.ajv.compile(nt)),it(Ye)}catch(nt){return console.warn("Error encountered compiling schema:",nt),!1}}}function customizeValidator(e={},t){return new AJV8Validator(e,t)}const validator=customizeValidator(),CustomTextWidget=e=>{var rt,nt,at,it;const t=(rt=e.options)==null?void 0:rt.minLength,Ye=(nt=e.options)==null?void 0:nt.maxLength,tt=((at=e.value)==null?void 0:at.length)||0;return jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-1",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsx("input",{type:"text",className:"w-full px-3 py-2 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-colors",value:e.value||"",onChange:ot=>e.onChange(ot.target.value),placeholder:e.placeholder,disabled:e.disabled,maxLength:Ye?e.options.maxLength:void 0}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description}),(t||Ye)&&jsxRuntimeExports.jsx("div",{className:"flex justify-end mt-1",children:jsxRuntimeExports.jsx("span",{className:`text-xs ${tt>(((it=e.options)==null?void 0:it.maxLength)||0)?"text-red-500":"text-gray-400"}`,children:t&&Ye?`${tt}/${e.options.maxLength} (最少${e.options.minLength})`:Ye?`${tt}/${e.options.maxLength}`:`最少${e.options.minLength}字符`})})]})},CustomPasswordWidget=e=>{const[t,Ye]=reactExports.useState(!1);return jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-1",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsxs("div",{className:"relative",children:[jsxRuntimeExports.jsx("input",{type:t?"text":"password",className:"w-full px-3 py-2 pr-10 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-colors",value:e.value||"",onChange:tt=>e.onChange(tt.target.value),placeholder:e.placeholder,disabled:e.disabled}),jsxRuntimeExports.jsx("button",{type:"button",className:"absolute right-3 top-1/2 transform -translate-y-1/2 text-gray-400 hover:text-gray-600",onClick:()=>Ye(!t),children:t?jsxRuntimeExports.jsx(EyeOff,{size:16}):jsxRuntimeExports.jsx(Eye$1,{size:16})})]}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description})]})},CustomTextareaWidget=e=>{var rt,nt,at,it,ot;const t=(rt=e.options)==null?void 0:rt.minLength,Ye=(nt=e.options)==null?void 0:nt.maxLength,tt=((at=e.value)==null?void 0:at.length)||0;return jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-1",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsx("textarea",{className:"w-full px-3 py-2 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-colors resize-vertical",value:e.value||"",onChange:ct=>e.onChange(ct.target.value),placeholder:e.placeholder,disabled:e.disabled,rows:((it=e.options)==null?void 0:it.rows)||4,maxLength:Ye?e.options.maxLength:void 0}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description}),(t||Ye)&&jsxRuntimeExports.jsx("div",{className:"flex justify-end mt-1",children:jsxRuntimeExports.jsx("span",{className:`text-xs ${tt>(((ot=e.options)==null?void 0:ot.maxLength)||0)?"text-red-500":"text-gray-400"}`,children:t&&Ye?`${tt}/${e.options.maxLength} (最少${e.options.minLength})`:Ye?`${tt}/${e.options.maxLength}`:`最少${e.options.minLength}字符`})})]})},CustomSelectWidget=e=>{var t,Ye;return jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-1",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsxs("div",{className:"relative",children:[jsxRuntimeExports.jsxs("select",{className:"w-full px-3 py-2 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-colors appearance-none",value:e.value||"",onChange:tt=>e.onChange(tt.target.value),disabled:e.disabled,children:[e.placeholder&&jsxRuntimeExports.jsx("option",{value:"",disabled:!0,children:e.placeholder}),(Ye=(t=e.options)==null?void 0:t.enumOptions)==null?void 0:Ye.map((tt,rt)=>jsxRuntimeExports.jsx("option",{value:tt.value,children:tt.label},rt))]}),jsxRuntimeExports.jsx(ChevronDown$1,{size:16,className:"absolute right-3 top-1/2 transform -translate-y-1/2 text-gray-400 pointer-events-none"})]}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description})]})},CustomCheckboxWidget=e=>{var t,Ye;return jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsx("div",{className:"space-y-2",children:(Ye=(t=e.options)==null?void 0:t.enumOptions)==null?void 0:Ye.map((tt,rt)=>{var nt;return jsxRuntimeExports.jsxs("label",{className:"flex items-center",children:[jsxRuntimeExports.jsx("input",{type:"checkbox",className:"w-4 h-4 text-blue-600 border-gray-300 rounded focus:ring-blue-500 focus:ring-2",checked:((nt=e.value)==null?void 0:nt.includes(tt.value))||!1,onChange:at=>{const it=e.value||[];at.target.checked?e.onChange([...it,tt.value]):e.onChange(it.filter(ot=>ot!==tt.value))},disabled:e.disabled}),jsxRuntimeExports.jsx("span",{className:"ml-2 text-sm text-gray-700",children:tt.label})]},rt)})}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description})]})},CustomRadioWidget=e=>{var t,Ye;return jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsx("div",{className:"space-y-2",children:(Ye=(t=e.options)==null?void 0:t.enumOptions)==null?void 0:Ye.map((tt,rt)=>jsxRuntimeExports.jsxs("label",{className:"flex items-center",children:[jsxRuntimeExports.jsx("input",{type:"radio",name:e.id,className:"w-4 h-4 text-blue-600 border-gray-300 focus:ring-blue-500 focus:ring-2",value:tt.value,checked:e.value===tt.value,onChange:nt=>e.onChange(nt.target.value),disabled:e.disabled}),jsxRuntimeExports.jsx("span",{className:"ml-2 text-sm text-gray-700",children:tt.label})]},rt))}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description})]})},CustomNumberWidget=e=>{var t,Ye,tt;return jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-1",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsx("input",{type:"number",className:"w-full px-3 py-2 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-colors",value:e.value||"",onChange:rt=>e.onChange(Number(rt.target.value)),placeholder:e.placeholder,disabled:e.disabled,min:(t=e.options)==null?void 0:t.min,max:(Ye=e.options)==null?void 0:Ye.max,step:(tt=e.options)==null?void 0:tt.step}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description})]})},CustomRangeWidget=e=>{var t,Ye,tt,rt,nt,at;return jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsxs("div",{className:"px-2",children:[jsxRuntimeExports.jsx("input",{type:"range",className:"w-full h-2 bg-gray-200 rounded-lg appearance-none cursor-pointer slider",value:e.value||((t=e.options)==null?void 0:t.min)||0,onChange:it=>e.onChange(Number(it.target.value)),disabled:e.disabled,min:((Ye=e.options)==null?void 0:Ye.min)||0,max:((tt=e.options)==null?void 0:tt.max)||100,step:((rt=e.options)==null?void 0:rt.step)||1}),jsxRuntimeExports.jsxs("div",{className:"flex justify-between text-xs text-gray-500 mt-1",children:[jsxRuntimeExports.jsx("span",{children:((nt=e.options)==null?void 0:nt.min)||0}),jsxRuntimeExports.jsx("span",{className:"font-medium text-blue-600",children:e.value}),jsxRuntimeExports.jsx("span",{children:((at=e.options)==null?void 0:at.max)||100})]})]}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description})]})},CustomDateWidget=e=>jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-1",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsx("input",{type:"date",className:"w-full px-3 py-2 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-colors",value:e.value||"",onChange:t=>e.onChange(t.target.value),disabled:e.disabled}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description})]}),CustomDateTimeWidget=e=>jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-1",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsx("input",{type:"datetime-local",className:"w-full px-3 py-2 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-colors",value:e.value||"",onChange:t=>e.onChange(t.target.value),disabled:e.disabled}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description})]}),CustomBooleanWidget=e=>jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"flex items-center",children:[jsxRuntimeExports.jsx("input",{type:"checkbox",className:"w-4 h-4 text-blue-600 border-gray-300 rounded focus:ring-blue-500 focus:ring-2 mr-2",checked:e.value||!1,onChange:t=>e.onChange(t.target.checked),disabled:e.disabled}),jsxRuntimeExports.jsxs("span",{className:"text-sm text-gray-700",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]})]}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1 ml-6",children:e.description})]}),CustomFileWidget=e=>{const t=Ye=>{const tt=Ye.target.files;e.multiple?e.onChange(tt):e.onChange((tt==null?void 0:tt[0])||null)};return jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-1",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsx("input",{type:"file",className:"w-full px-3 py-2 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-colors file:mr-3 file:py-1 file:px-3 file:border-0 file:bg-blue-50 file:text-blue-700 file:rounded file:font-medium",onChange:t,disabled:e.disabled,multiple:e.multiple,accept:e.accept}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description})]})},CustomArrayField=e=>jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.label&&jsxRuntimeExports.jsxs("label",{className:"block text-sm font-medium text-gray-700 mb-2",children:[e.label,e.required&&jsxRuntimeExports.jsx("span",{className:"text-red-500 ml-1",children:"*"})]}),jsxRuntimeExports.jsxs("div",{className:"space-y-2",children:[e.items.map((t,Ye)=>jsxRuntimeExports.jsxs("div",{className:"flex items-start gap-2 p-3 border border-gray-200 rounded-lg",children:[jsxRuntimeExports.jsx("div",{className:"flex-1",children:t.children}),jsxRuntimeExports.jsx("button",{type:"button",className:"p-1 text-red-500 hover:text-red-700 hover:bg-red-50 rounded",onClick:()=>e.onDropIndexClick(Ye)(),children:jsxRuntimeExports.jsx(X$6,{size:16})})]},Ye)),jsxRuntimeExports.jsxs("button",{type:"button",className:"flex items-center gap-1 px-3 py-1 text-sm bg-gray-100 hover:bg-gray-200 text-gray-700 rounded-lg transition-colors",onClick:()=>e.onAddClick(),children:[jsxRuntimeExports.jsx(Plus,{size:14}),"添加项目"]})]}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description})]}),CustomFieldTemplate=e=>jsxRuntimeExports.jsx("div",{className:`${e.className} mb-4`,children:e.children}),CustomObjectFieldTemplate=e=>jsxRuntimeExports.jsxs("div",{className:"mb-4",children:[e.title&&jsxRuntimeExports.jsx("h3",{className:"text-sm font-medium text-gray-700 mb-2",children:e.title}),jsxRuntimeExports.jsx("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-4 pl-4 border-l-2 border-gray-200",children:e.properties.map(t=>jsxRuntimeExports.jsx("div",{children:t.content},t.name))}),e.description&&jsxRuntimeExports.jsx("p",{className:"text-xs text-gray-500 mt-1",children:e.description})]}),CustomSubmitButton=e=>jsxRuntimeExports.jsx("button",{type:"submit",className:"px-4 py-2 rounded-lg bg-blue-500 hover:bg-blue-600 disabled:bg-gray-300 text-white font-medium focus:outline-none focus:ring-2 focus:ring-blue-400 transition-colors disabled:cursor-not-allowed",disabled:e.disabled,children:e.submitText||"提交"}),show_form=createUITool({name:"show_form",description:"显示动态表单,等待用户填写",parameters:{schema:any()},onlyRender:!1,handler:ToolManager.waitForUIDone,render(e){const t=e.getInputRepaired(),Ye=e.getJSONOutputSafe(),tt=t.schema,rt=ot=>{console.log("Form submitted:",ot),e.response(ot)},nt={text:CustomTextWidget,password:CustomPasswordWidget,textarea:CustomTextareaWidget,select:CustomSelectWidget,checkboxes:CustomCheckboxWidget,radio:CustomRadioWidget,number:CustomNumberWidget,range:CustomRangeWidget,date:CustomDateWidget,datetime:CustomDateTimeWidget,file:CustomFileWidget,boolean:CustomBooleanWidget},at={array:CustomArrayField},it={FieldTemplate:CustomFieldTemplate,ObjectFieldTemplate:CustomObjectFieldTemplate,ButtonTemplates:{SubmitButton:CustomSubmitButton}};return jsxRuntimeExports.jsxs("div",{className:"p-4 bg-white rounded-lg border border-gray-200",children:[jsxRuntimeExports.jsxs("div",{className:"flex items-center gap-1.5 text-gray-700 mb-3 font-bold",children:[jsxRuntimeExports.jsx(FileText,{className:"w-4 h-4 text-blue-500"}),jsxRuntimeExports.jsx("span",{children:"AI 表单"})]}),jsxRuntimeExports.jsx(ErrorBoundary,{children:jsxRuntimeExports.jsx(Form,{readonly:e.state==="done",schema:tt||{},formData:Ye,onSubmit:ot=>rt(ot.formData),validator,onError:ot=>{console.error("表单校验错误:",ot),alert("表单填写有误,请检查后再提交。")},widgets:nt,fields:at,templates:it,className:"custom-form",children:jsxRuntimeExports.jsx("div",{className:"flex gap-2 mt-4",children:jsxRuntimeExports.jsx(CustomSubmitButton,{})})})})]})}}),create_artifacts=createUITool({name:"create_artifacts",description:"创建并保存代码文件到 artifacts 目录",parameters:{},onlyRender:!0,render(e){const t=e.getInputRepaired(),{setCurrentArtifactById:Ye,setShowArtifact:tt}=useChat(),rt=()=>{Ye(t.id,e.message.id),tt(!0)};return jsxRuntimeExports.jsxs("div",{className:"p-4 space-y-4",children:[jsxRuntimeExports.jsxs("div",{className:"text-sm text-gray-500",children:["创建文件: ",t.title]}),jsxRuntimeExports.jsx("div",{className:"border rounded-lg p-2 hover:bg-gray-50",children:jsxRuntimeExports.jsx("div",{className:"flex items-center justify-between select-none cursor-pointer",onClick:rt,children:jsxRuntimeExports.jsxs("div",{className:"flex items-center gap-2",children:[jsxRuntimeExports.jsx(File$1,{className:"w-4 h-4"}),jsxRuntimeExports.jsx("span",{className:"font-xs",children:t.title})," version: ",t.id]})})})]})}});function __insertCSS(e){if(typeof document>"u")return;let t=document.head||document.getElementsByTagName("head")[0],Ye=document.createElement("style");Ye.type="text/css",t.appendChild(Ye),Ye.styleSheet?Ye.styleSheet.cssText=e:Ye.appendChild(document.createTextNode(e))}const getAsset=e=>{switch(e){case"success":return SuccessIcon;case"info":return InfoIcon;case"warning":return WarningIcon;case"error":return ErrorIcon;default:return null}},bars=Array(12).fill(0),Loader=({visible:e,className:t})=>React.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},React.createElement("div",{className:"sonner-spinner"},bars.map((Ye,tt)=>React.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${tt}`})))),SuccessIcon=React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},React.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),WarningIcon=React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},React.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),InfoIcon=React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},React.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),ErrorIcon=React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},React.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),CloseIcon=React.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},React.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),React.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),useIsDocumentHidden=()=>{const[e,t]=React.useState(document.hidden);return React.useEffect(()=>{const Ye=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",Ye),()=>window.removeEventListener("visibilitychange",Ye)},[]),e};let toastsCounter=1;class Observer{constructor(){this.subscribe=t=>(this.subscribers.push(t),()=>{const Ye=this.subscribers.indexOf(t);this.subscribers.splice(Ye,1)}),this.publish=t=>{this.subscribers.forEach(Ye=>Ye(t))},this.addToast=t=>{this.publish(t),this.toasts=[...this.toasts,t]},this.create=t=>{var Ye;const{message:tt,...rt}=t,nt=typeof(t==null?void 0:t.id)=="number"||((Ye=t.id)==null?void 0:Ye.length)>0?t.id:toastsCounter++,at=this.toasts.find(ot=>ot.id===nt),it=t.dismissible===void 0?!0:t.dismissible;return this.dismissedToasts.has(nt)&&this.dismissedToasts.delete(nt),at?this.toasts=this.toasts.map(ot=>ot.id===nt?(this.publish({...ot,...t,id:nt,title:tt}),{...ot,...t,id:nt,dismissible:it,title:tt}):ot):this.addToast({title:tt,...rt,dismissible:it,id:nt}),nt},this.dismiss=t=>(t?(this.dismissedToasts.add(t),requestAnimationFrame(()=>this.subscribers.forEach(Ye=>Ye({id:t,dismiss:!0})))):this.toasts.forEach(Ye=>{this.subscribers.forEach(tt=>tt({id:Ye.id,dismiss:!0}))}),t),this.message=(t,Ye)=>this.create({...Ye,message:t}),this.error=(t,Ye)=>this.create({...Ye,message:t,type:"error"}),this.success=(t,Ye)=>this.create({...Ye,type:"success",message:t}),this.info=(t,Ye)=>this.create({...Ye,type:"info",message:t}),this.warning=(t,Ye)=>this.create({...Ye,type:"warning",message:t}),this.loading=(t,Ye)=>this.create({...Ye,type:"loading",message:t}),this.promise=(t,Ye)=>{if(!Ye)return;let tt;Ye.loading!==void 0&&(tt=this.create({...Ye,promise:t,type:"loading",message:Ye.loading,description:typeof Ye.description!="function"?Ye.description:void 0}));const rt=Promise.resolve(t instanceof Function?t():t);let nt=tt!==void 0,at;const it=rt.then(async ct=>{if(at=["resolve",ct],React.isValidElement(ct))nt=!1,this.create({id:tt,type:"default",message:ct});else if(isHttpResponse(ct)&&!ct.ok){nt=!1;const Rt=typeof Ye.error=="function"?await Ye.error(`HTTP error! status: ${ct.status}`):Ye.error,qt=typeof Ye.description=="function"?await Ye.description(`HTTP error! status: ${ct.status}`):Ye.description,Ut=typeof Rt=="object"&&!React.isValidElement(Rt)?Rt:{message:Rt};this.create({id:tt,type:"error",description:qt,...Ut})}else if(ct instanceof Error){nt=!1;const Rt=typeof Ye.error=="function"?await Ye.error(ct):Ye.error,qt=typeof Ye.description=="function"?await Ye.description(ct):Ye.description,Ut=typeof Rt=="object"&&!React.isValidElement(Rt)?Rt:{message:Rt};this.create({id:tt,type:"error",description:qt,...Ut})}else if(Ye.success!==void 0){nt=!1;const Rt=typeof Ye.success=="function"?await Ye.success(ct):Ye.success,qt=typeof Ye.description=="function"?await Ye.description(ct):Ye.description,Ut=typeof Rt=="object"&&!React.isValidElement(Rt)?Rt:{message:Rt};this.create({id:tt,type:"success",description:qt,...Ut})}}).catch(async ct=>{if(at=["reject",ct],Ye.error!==void 0){nt=!1;const At=typeof Ye.error=="function"?await Ye.error(ct):Ye.error,Rt=typeof Ye.description=="function"?await Ye.description(ct):Ye.description,Ft=typeof At=="object"&&!React.isValidElement(At)?At:{message:At};this.create({id:tt,type:"error",description:Rt,...Ft})}}).finally(()=>{nt&&(this.dismiss(tt),tt=void 0),Ye.finally==null||Ye.finally.call(Ye)}),ot=()=>new Promise((ct,At)=>it.then(()=>at[0]==="reject"?At(at[1]):ct(at[1])).catch(At));return typeof tt!="string"&&typeof tt!="number"?{unwrap:ot}:Object.assign(tt,{unwrap:ot})},this.custom=(t,Ye)=>{const tt=(Ye==null?void 0:Ye.id)||toastsCounter++;return this.create({jsx:t(tt),id:tt,...Ye}),tt},this.getActiveToasts=()=>this.toasts.filter(t=>!this.dismissedToasts.has(t.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const ToastState=new Observer,toastFunction=(e,t)=>{const Ye=(t==null?void 0:t.id)||toastsCounter++;return ToastState.addToast({title:e,...t,id:Ye}),Ye},isHttpResponse=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",basicToast=toastFunction,getHistory=()=>ToastState.toasts,getToasts=()=>ToastState.getActiveToasts(),toast=Object.assign(basicToast,{success:ToastState.success,info:ToastState.info,warning:ToastState.warning,error:ToastState.error,custom:ToastState.custom,message:ToastState.message,promise:ToastState.promise,dismiss:ToastState.dismiss,loading:ToastState.loading},{getHistory,getToasts});__insertCSS("[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-rich-colors=true][data-sonner-toast][data-styled=true] [data-description]{color:inherit}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast][data-expanded=true]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}");function isAction(e){return e.label!==void 0}const VISIBLE_TOASTS_AMOUNT=3,VIEWPORT_OFFSET="24px",MOBILE_VIEWPORT_OFFSET="16px",TOAST_LIFETIME=4e3,TOAST_WIDTH=356,GAP=14,SWIPE_THRESHOLD=45,TIME_BEFORE_UNMOUNT=200;function cn(...e){return e.filter(Boolean).join(" ")}function getDefaultSwipeDirections(e){const[t,Ye]=e.split("-"),tt=[];return t&&tt.push(t),Ye&&tt.push(Ye),tt}const Toast=e=>{var t,Ye,tt,rt,nt,at,it,ot,ct;const{invert:At,toast:Rt,unstyled:qt,interacting:Ft,setHeights:Ut,visibleToasts:Ht,heights:zt,index:Yt,toasts:Gt,expanded:Vt,removeToast:Zt,defaultRichColors:Xt,closeButton:Qt,style:er,cancelButtonStyle:nr,actionButtonStyle:ar,className:sr="",descriptionClassName:lr="",duration:fr,position:gr,gap:dr,expandByDefault:vr,classNames:mr,icons:Er,closeButtonAriaLabel:_r="Close toast"}=e,[Tr,ur]=React.useState(null),[cr,yr]=React.useState(null),[ir,or]=React.useState(!1),[hr,Sr]=React.useState(!1),[wr,Ir]=React.useState(!1),[kr,Mr]=React.useState(!1),[Ar,Rr]=React.useState(!1),[Dr,Lr]=React.useState(0),[Ur,Wr]=React.useState(0),Kr=React.useRef(Rt.duration||fr||TOAST_LIFETIME),nn=React.useRef(null),Jr=React.useRef(null),un=Yt===0,pn=Yt+1<=Ht,Zr=Rt.type,rn=Rt.dismissible!==!1,fn=Rt.className||"",mn=Rt.descriptionClassName||"",jr=React.useMemo(()=>zt.findIndex(sn=>sn.toastId===Rt.id)||0,[zt,Rt.id]),Hr=React.useMemo(()=>{var sn;return(sn=Rt.closeButton)!=null?sn:Qt},[Rt.closeButton,Qt]),Yr=React.useMemo(()=>Rt.duration||fr||TOAST_LIFETIME,[Rt.duration,fr]),en=React.useRef(0),dn=React.useRef(0),Hn=React.useRef(0),kn=React.useRef(null),[Tn,bn]=gr.split("-"),In=React.useMemo(()=>zt.reduce((sn,Nn,Vn)=>Vn>=jr?sn:sn+Nn.height,0),[zt,jr]),Sn=useIsDocumentHidden(),la=Rt.invert||At,Zn=Zr==="loading";dn.current=React.useMemo(()=>jr*dr+In,[jr,In]),React.useEffect(()=>{Kr.current=Yr},[Yr]),React.useEffect(()=>{or(!0)},[]),React.useEffect(()=>{const sn=Jr.current;if(sn){const Nn=sn.getBoundingClientRect().height;return Wr(Nn),Ut(Vn=>[{toastId:Rt.id,height:Nn,position:Rt.position},...Vn]),()=>Ut(Vn=>Vn.filter(ua=>ua.toastId!==Rt.id))}},[Ut,Rt.id]),React.useLayoutEffect(()=>{if(!ir)return;const sn=Jr.current,Nn=sn.style.height;sn.style.height="auto";const Vn=sn.getBoundingClientRect().height;sn.style.height=Nn,Wr(Vn),Ut(ua=>ua.find(Un=>Un.toastId===Rt.id)?ua.map(Un=>Un.toastId===Rt.id?{...Un,height:Vn}:Un):[{toastId:Rt.id,height:Vn,position:Rt.position},...ua])},[ir,Rt.title,Rt.description,Ut,Rt.id,Rt.jsx,Rt.action,Rt.cancel]);const Kn=React.useCallback(()=>{Sr(!0),Lr(dn.current),Ut(sn=>sn.filter(Nn=>Nn.toastId!==Rt.id)),setTimeout(()=>{Zt(Rt)},TIME_BEFORE_UNMOUNT)},[Rt,Zt,Ut,dn]);React.useEffect(()=>{if(Rt.promise&&Zr==="loading"||Rt.duration===1/0||Rt.type==="loading")return;let sn;return Vt||Ft||Sn?(()=>{if(Hn.current<en.current){const ua=new Date().getTime()-en.current;Kr.current=Kr.current-ua}Hn.current=new Date().getTime()})():(()=>{Kr.current!==1/0&&(en.current=new Date().getTime(),sn=setTimeout(()=>{Rt.onAutoClose==null||Rt.onAutoClose.call(Rt,Rt),Kn()},Kr.current))})(),()=>clearTimeout(sn)},[Vt,Ft,Rt,Zr,Sn,Kn]),React.useEffect(()=>{Rt.delete&&(Kn(),Rt.onDismiss==null||Rt.onDismiss.call(Rt,Rt))},[Kn,Rt.delete]);function qn(){var sn;if(Er!=null&&Er.loading){var Nn;return React.createElement("div",{className:cn(mr==null?void 0:mr.loader,Rt==null||(Nn=Rt.classNames)==null?void 0:Nn.loader,"sonner-loader"),"data-visible":Zr==="loading"},Er.loading)}return React.createElement(Loader,{className:cn(mr==null?void 0:mr.loader,Rt==null||(sn=Rt.classNames)==null?void 0:sn.loader),visible:Zr==="loading"})}const xa=Rt.icon||(Er==null?void 0:Er[Zr])||getAsset(Zr);var Xa,Ea;return React.createElement("li",{tabIndex:0,ref:Jr,className:cn(sr,fn,mr==null?void 0:mr.toast,Rt==null||(t=Rt.classNames)==null?void 0:t.toast,mr==null?void 0:mr.default,mr==null?void 0:mr[Zr],Rt==null||(Ye=Rt.classNames)==null?void 0:Ye[Zr]),"data-sonner-toast":"","data-rich-colors":(Xa=Rt.richColors)!=null?Xa:Xt,"data-styled":!(Rt.jsx||Rt.unstyled||qt),"data-mounted":ir,"data-promise":!!Rt.promise,"data-swiped":Ar,"data-removed":hr,"data-visible":pn,"data-y-position":Tn,"data-x-position":bn,"data-index":Yt,"data-front":un,"data-swiping":wr,"data-dismissible":rn,"data-type":Zr,"data-invert":la,"data-swipe-out":kr,"data-swipe-direction":cr,"data-expanded":!!(Vt||vr&&ir),"data-testid":Rt.testId,style:{"--index":Yt,"--toasts-before":Yt,"--z-index":Gt.length-Yt,"--offset":`${hr?Dr:dn.current}px`,"--initial-height":vr?"auto":`${Ur}px`,...er,...Rt.style},onDragEnd:()=>{Ir(!1),ur(null),kn.current=null},onPointerDown:sn=>{sn.button!==2&&(Zn||!rn||(nn.current=new Date,Lr(dn.current),sn.target.setPointerCapture(sn.pointerId),sn.target.tagName!=="BUTTON"&&(Ir(!0),kn.current={x:sn.clientX,y:sn.clientY})))},onPointerUp:()=>{var sn,Nn,Vn;if(kr||!rn)return;kn.current=null;const ua=Number(((sn=Jr.current)==null?void 0:sn.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),ni=Number(((Nn=Jr.current)==null?void 0:Nn.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),Un=new Date().getTime()-((Vn=nn.current)==null?void 0:Vn.getTime()),ga=Tr==="x"?ua:ni,pi=Math.abs(ga)/Un;if(Math.abs(ga)>=SWIPE_THRESHOLD||pi>.11){Lr(dn.current),Rt.onDismiss==null||Rt.onDismiss.call(Rt,Rt),yr(Tr==="x"?ua>0?"right":"left":ni>0?"down":"up"),Kn(),Mr(!0);return}else{var ba,ya;(ba=Jr.current)==null||ba.style.setProperty("--swipe-amount-x","0px"),(ya=Jr.current)==null||ya.style.setProperty("--swipe-amount-y","0px")}Rr(!1),Ir(!1),ur(null)},onPointerMove:sn=>{var Nn,Vn,ua;if(!kn.current||!rn||((Nn=window.getSelection())==null?void 0:Nn.toString().length)>0)return;const Un=sn.clientY-kn.current.y,ga=sn.clientX-kn.current.x;var pi;const ba=(pi=e.swipeDirections)!=null?pi:getDefaultSwipeDirections(gr);!Tr&&(Math.abs(ga)>1||Math.abs(Un)>1)&&ur(Math.abs(ga)>Math.abs(Un)?"x":"y");let ya={x:0,y:0};const Pi=Oa=>1/(1.5+Math.abs(Oa)/20);if(Tr==="y"){if(ba.includes("top")||ba.includes("bottom"))if(ba.includes("top")&&Un<0||ba.includes("bottom")&&Un>0)ya.y=Un;else{const Oa=Un*Pi(Un);ya.y=Math.abs(Oa)<Math.abs(Un)?Oa:Un}}else if(Tr==="x"&&(ba.includes("left")||ba.includes("right")))if(ba.includes("left")&&ga<0||ba.includes("right")&&ga>0)ya.x=ga;else{const Oa=ga*Pi(ga);ya.x=Math.abs(Oa)<Math.abs(ga)?Oa:ga}(Math.abs(ya.x)>0||Math.abs(ya.y)>0)&&Rr(!0),(Vn=Jr.current)==null||Vn.style.setProperty("--swipe-amount-x",`${ya.x}px`),(ua=Jr.current)==null||ua.style.setProperty("--swipe-amount-y",`${ya.y}px`)}},Hr&&!Rt.jsx&&Zr!=="loading"?React.createElement("button",{"aria-label":_r,"data-disabled":Zn,"data-close-button":!0,onClick:Zn||!rn?()=>{}:()=>{Kn(),Rt.onDismiss==null||Rt.onDismiss.call(Rt,Rt)},className:cn(mr==null?void 0:mr.closeButton,Rt==null||(tt=Rt.classNames)==null?void 0:tt.closeButton)},(Ea=Er==null?void 0:Er.close)!=null?Ea:CloseIcon):null,(Zr||Rt.icon||Rt.promise)&&Rt.icon!==null&&((Er==null?void 0:Er[Zr])!==null||Rt.icon)?React.createElement("div",{"data-icon":"",className:cn(mr==null?void 0:mr.icon,Rt==null||(rt=Rt.classNames)==null?void 0:rt.icon)},Rt.promise||Rt.type==="loading"&&!Rt.icon?Rt.icon||qn():null,Rt.type!=="loading"?xa:null):null,React.createElement("div",{"data-content":"",className:cn(mr==null?void 0:mr.content,Rt==null||(nt=Rt.classNames)==null?void 0:nt.content)},React.createElement("div",{"data-title":"",className:cn(mr==null?void 0:mr.title,Rt==null||(at=Rt.classNames)==null?void 0:at.title)},Rt.jsx?Rt.jsx:typeof Rt.title=="function"?Rt.title():Rt.title),Rt.description?React.createElement("div",{"data-description":"",className:cn(lr,mn,mr==null?void 0:mr.description,Rt==null||(it=Rt.classNames)==null?void 0:it.description)},typeof Rt.description=="function"?Rt.description():Rt.description):null),React.isValidElement(Rt.cancel)?Rt.cancel:Rt.cancel&&isAction(Rt.cancel)?React.createElement("button",{"data-button":!0,"data-cancel":!0,style:Rt.cancelButtonStyle||nr,onClick:sn=>{isAction(Rt.cancel)&&rn&&(Rt.cancel.onClick==null||Rt.cancel.onClick.call(Rt.cancel,sn),Kn())},className:cn(mr==null?void 0:mr.cancelButton,Rt==null||(ot=Rt.classNames)==null?void 0:ot.cancelButton)},Rt.cancel.label):null,React.isValidElement(Rt.action)?Rt.action:Rt.action&&isAction(Rt.action)?React.createElement("button",{"data-button":!0,"data-action":!0,style:Rt.actionButtonStyle||ar,onClick:sn=>{isAction(Rt.action)&&(Rt.action.onClick==null||Rt.action.onClick.call(Rt.action,sn),!sn.defaultPrevented&&Kn())},className:cn(mr==null?void 0:mr.actionButton,Rt==null||(ct=Rt.classNames)==null?void 0:ct.actionButton)},Rt.action.label):null)};function getDocumentDirection(){if(typeof window>"u"||typeof document>"u")return"ltr";const e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}function assignOffset(e,t){const Ye={};return[e,t].forEach((tt,rt)=>{const nt=rt===1,at=nt?"--mobile-offset":"--offset",it=nt?MOBILE_VIEWPORT_OFFSET:VIEWPORT_OFFSET;function ot(ct){["top","right","bottom","left"].forEach(At=>{Ye[`${at}-${At}`]=typeof ct=="number"?`${ct}px`:ct})}typeof tt=="number"||typeof tt=="string"?ot(tt):typeof tt=="object"?["top","right","bottom","left"].forEach(ct=>{tt[ct]===void 0?Ye[`${at}-${ct}`]=it:Ye[`${at}-${ct}`]=typeof tt[ct]=="number"?`${tt[ct]}px`:tt[ct]}):ot(it)}),Ye}const Toaster$1=React.forwardRef(function e(t,Ye){const{id:tt,invert:rt,position:nt="bottom-right",hotkey:at=["altKey","KeyT"],expand:it,closeButton:ot,className:ct,offset:At,mobileOffset:Rt,theme:qt="light",richColors:Ft,duration:Ut,style:Ht,visibleToasts:zt=VISIBLE_TOASTS_AMOUNT,toastOptions:Yt,dir:Gt=getDocumentDirection(),gap:Vt=GAP,icons:Zt,containerAriaLabel:Xt="Notifications"}=t,[Qt,er]=React.useState([]),nr=React.useMemo(()=>tt?Qt.filter(ir=>ir.toasterId===tt):Qt.filter(ir=>!ir.toasterId),[Qt,tt]),ar=React.useMemo(()=>Array.from(new Set([nt].concat(nr.filter(ir=>ir.position).map(ir=>ir.position)))),[nr,nt]),[sr,lr]=React.useState([]),[fr,gr]=React.useState(!1),[dr,vr]=React.useState(!1),[mr,Er]=React.useState(qt!=="system"?qt:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),_r=React.useRef(null),Tr=at.join("+").replace(/Key/g,"").replace(/Digit/g,""),ur=React.useRef(null),cr=React.useRef(!1),yr=React.useCallback(ir=>{er(or=>{var hr;return(hr=or.find(Sr=>Sr.id===ir.id))!=null&&hr.delete||ToastState.dismiss(ir.id),or.filter(({id:Sr})=>Sr!==ir.id)})},[]);return React.useEffect(()=>ToastState.subscribe(ir=>{if(ir.dismiss){requestAnimationFrame(()=>{er(or=>or.map(hr=>hr.id===ir.id?{...hr,delete:!0}:hr))});return}setTimeout(()=>{ReactDOM.flushSync(()=>{er(or=>{const hr=or.findIndex(Sr=>Sr.id===ir.id);return hr!==-1?[...or.slice(0,hr),{...or[hr],...ir},...or.slice(hr+1)]:[ir,...or]})})})}),[Qt]),React.useEffect(()=>{if(qt!=="system"){Er(qt);return}if(qt==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?Er("dark"):Er("light")),typeof window>"u")return;const ir=window.matchMedia("(prefers-color-scheme: dark)");try{ir.addEventListener("change",({matches:or})=>{Er(or?"dark":"light")})}catch{ir.addListener(({matches:hr})=>{try{Er(hr?"dark":"light")}catch(Sr){console.error(Sr)}})}},[qt]),React.useEffect(()=>{Qt.length<=1&&gr(!1)},[Qt]),React.useEffect(()=>{const ir=or=>{var hr;if(at.every(Ir=>or[Ir]||or.code===Ir)){var wr;gr(!0),(wr=_r.current)==null||wr.focus()}or.code==="Escape"&&(document.activeElement===_r.current||(hr=_r.current)!=null&&hr.contains(document.activeElement))&&gr(!1)};return document.addEventListener("keydown",ir),()=>document.removeEventListener("keydown",ir)},[at]),React.useEffect(()=>{if(_r.current)return()=>{ur.current&&(ur.current.focus({preventScroll:!0}),ur.current=null,cr.current=!1)}},[_r.current]),React.createElement("section",{ref:Ye,"aria-label":`${Xt} ${Tr}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},ar.map((ir,or)=>{var hr;const[Sr,wr]=ir.split("-");return nr.length?React.createElement("ol",{key:ir,dir:Gt==="auto"?getDocumentDirection():Gt,tabIndex:-1,ref:_r,className:ct,"data-sonner-toaster":!0,"data-sonner-theme":mr,"data-y-position":Sr,"data-x-position":wr,style:{"--front-toast-height":`${((hr=sr[0])==null?void 0:hr.height)||0}px`,"--width":`${TOAST_WIDTH}px`,"--gap":`${Vt}px`,...Ht,...assignOffset(At,Rt)},onBlur:Ir=>{cr.current&&!Ir.currentTarget.contains(Ir.relatedTarget)&&(cr.current=!1,ur.current&&(ur.current.focus({preventScroll:!0}),ur.current=null))},onFocus:Ir=>{Ir.target instanceof HTMLElement&&Ir.target.dataset.dismissible==="false"||cr.current||(cr.current=!0,ur.current=Ir.relatedTarget)},onMouseEnter:()=>gr(!0),onMouseMove:()=>gr(!0),onMouseLeave:()=>{dr||gr(!1)},onDragEnd:()=>gr(!1),onPointerDown:Ir=>{Ir.target instanceof HTMLElement&&Ir.target.dataset.dismissible==="false"||vr(!0)},onPointerUp:()=>vr(!1)},nr.filter(Ir=>!Ir.position&&or===0||Ir.position===ir).map((Ir,kr)=>{var Mr,Ar;return React.createElement(Toast,{key:Ir.id,icons:Zt,index:kr,toast:Ir,defaultRichColors:Ft,duration:(Mr=Yt==null?void 0:Yt.duration)!=null?Mr:Ut,className:Yt==null?void 0:Yt.className,descriptionClassName:Yt==null?void 0:Yt.descriptionClassName,invert:rt,visibleToasts:zt,closeButton:(Ar=Yt==null?void 0:Yt.closeButton)!=null?Ar:ot,interacting:dr,position:ir,style:Yt==null?void 0:Yt.style,unstyled:Yt==null?void 0:Yt.unstyled,classNames:Yt==null?void 0:Yt.classNames,cancelButtonStyle:Yt==null?void 0:Yt.cancelButtonStyle,actionButtonStyle:Yt==null?void 0:Yt.actionButtonStyle,closeButtonAriaLabel:Yt==null?void 0:Yt.closeButtonAriaLabel,removeToast:yr,toasts:nr.filter(Rr=>Rr.position==Ir.position),heights:sr.filter(Rr=>Rr.position==Ir.position),setHeights:lr,expandByDefault:it,gap:Vt,expanded:fr,swipeDirections:t.swipeDirections})})):null}))}),initialLoginSettings={headers:[{key:"authorization",value:""}],withCredentials:!1,apiUrl:"/api/langgraph",defaultAgent:"agent"},apiUrlShortcuts=["/api/langgraph","http://localhost:8123","http://localhost:3000","http://localhost:8000","http://localhost:5000"],LoginSettings=()=>{const[e,t]=reactExports.useState(!1),[Ye,tt]=reactExports.useState(()=>{try{const At=localStorage.getItem("code"),Rt=localStorage.getItem("withCredentials"),qt=localStorage.getItem("apiUrl"),Ft=localStorage.getItem("defaultAgent");let Ut=initialLoginSettings.headers;if(At){const Ht=JSON.parse(At);typeof Ht=="object"&&!Array.isArray(Ht)?Ut=Object.entries(Ht).map(([zt,Yt])=>({key:zt,value:Yt})):Array.isArray(Ht)&&(Ut=Ht)}return{headers:Ut,withCredentials:Rt?JSON.parse(Rt):initialLoginSettings.withCredentials,apiUrl:qt||initialLoginSettings.apiUrl,defaultAgent:Ft||initialLoginSettings.defaultAgent}}catch(At){return console.error("Error reading login settings from localStorage:",At),initialLoginSettings}});reactExports.useEffect(()=>{try{localStorage.setItem("code",JSON.stringify(Ye.headers)),localStorage.setItem("withCredentials",JSON.stringify(Ye.withCredentials)),localStorage.setItem("apiUrl",Ye.apiUrl),localStorage.setItem("defaultAgent",Ye.defaultAgent)}catch(At){console.error("Error writing login settings to localStorage:",At)}},[Ye]),reactExports.useEffect(()=>{const At=Rt=>{const qt=Rt.target;e&&!qt.closest(".api-url-dropdown")&&t(!1)};return document.addEventListener("mousedown",At),()=>{document.removeEventListener("mousedown",At)}},[e]);const rt=reactExports.useCallback(()=>{tt(At=>({...At,headers:[...At.headers,{key:"",value:""}]}))},[]),nt=reactExports.useCallback(At=>{tt(Rt=>({...Rt,headers:Rt.headers.filter((qt,Ft)=>Ft!==At)}))},[]),at=reactExports.useCallback((At,Rt,qt)=>{tt(Ft=>{const Ut=[...Ft.headers];return Ut[At][Rt]=qt,{...Ft,headers:Ut}})},[]),it=reactExports.useCallback(At=>{const{name:Rt,value:qt,type:Ft,checked:Ut}=At.target;tt(Ht=>({...Ht,[Rt]:Ft==="checkbox"?Ut:qt}))},[]);reactExports.useCallback(At=>{const{name:Rt,value:qt}=At.target;tt(Ft=>({...Ft,[Rt]:qt}))},[]);const ot=reactExports.useCallback(At=>{tt(Rt=>({...Rt,apiUrl:At})),t(!1)},[]),ct=()=>{toast.success("配置已保存!重启程序"),setTimeout(()=>{window.location.reload()},500)};return jsxRuntimeExports.jsxs("form",{className:"space-y-6",children:[jsxRuntimeExports.jsxs("div",{children:[jsxRuntimeExports.jsx("label",{htmlFor:"default-agent",className:"block text-sm font-medium text-gray-700 dark:text-gray-300 mb-2",children:"默认 Agent 名称"}),jsxRuntimeExports.jsx("input",{type:"text",id:"defaultAgent",name:"defaultAgent",value:Ye.defaultAgent,onChange:it,placeholder:"例如: assistant",className:"w-full px-4 py-3 border border-gray-300 dark:border-gray-600 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-all bg-white dark:bg-gray-700 text-gray-900 dark:text-white"})]}),jsxRuntimeExports.jsxs("div",{children:[jsxRuntimeExports.jsx("label",{htmlFor:"api-url",className:"block text-sm font-medium text-gray-700 dark:text-gray-300 mb-2",children:"API URL"}),jsxRuntimeExports.jsxs("div",{className:"relative api-url-dropdown",children:[jsxRuntimeExports.jsxs("div",{className:"flex",children:[jsxRuntimeExports.jsx("input",{type:"text",id:"apiUrl",name:"apiUrl",value:Ye.apiUrl,onChange:it,placeholder:"例如: http://localhost:8123",className:"flex-1 px-4 py-3 border border-gray-300 dark:border-gray-600 rounded-l-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-all bg-white dark:bg-gray-700 text-gray-900 dark:text-white"}),jsxRuntimeExports.jsx("button",{type:"button",onClick:()=>t(!e),className:"px-3 py-3 border border-l-0 border-gray-300 dark:border-gray-600 rounded-r-lg bg-gray-50 dark:bg-gray-600 hover:bg-gray-100 dark:hover:bg-gray-500 transition-colors focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent",children:jsxRuntimeExports.jsx("svg",{className:"w-5 h-5 text-gray-600 dark:text-gray-300",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:jsxRuntimeExports.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M19 9l-7 7-7-7"})})})]}),e&&jsxRuntimeExports.jsx("div",{className:"absolute z-10 mt-1 w-full bg-white dark:bg-gray-700 border border-gray-300 dark:border-gray-600 rounded-lg shadow-lg",children:apiUrlShortcuts.map((At,Rt)=>jsxRuntimeExports.jsx("button",{type:"button",onClick:()=>ot(At),className:"w-full px-4 py-2 text-left hover:bg-gray-100 dark:hover:bg-gray-600 transition-colors first:rounded-t-lg last:rounded-b-lg text-gray-900 dark:text-white",children:At},Rt))})]})]}),jsxRuntimeExports.jsxs("div",{children:[jsxRuntimeExports.jsx("label",{className:"block text-sm font-medium text-gray-700 dark:text-gray-300 mb-2",children:"请求头配置"}),jsxRuntimeExports.jsx("div",{className:"space-y-3",children:Ye.headers.map((At,Rt)=>jsxRuntimeExports.jsxs("div",{className:"bg-gray-50 dark:bg-gray-700 rounded-lg p-4 shadow-sm",children:[jsxRuntimeExports.jsxs("div",{className:"grid grid-cols-2 gap-4 mb-3",children:[jsxRuntimeExports.jsx("div",{children:jsxRuntimeExports.jsx("input",{type:"text",id:`header-key-${Rt}`,value:At.key,onChange:qt=>at(Rt,"key",qt.target.value),placeholder:"例如: authorization",required:!0,className:"w-full px-4 py-2 border border-gray-300 dark:border-gray-600 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-all bg-white dark:bg-gray-800 text-gray-900 dark:text-white"})}),jsxRuntimeExports.jsx("div",{children:jsxRuntimeExports.jsx("input",{type:"text",id:`header-value-${Rt}`,value:At.value,onChange:qt=>at(Rt,"value",qt.target.value),placeholder:"例如: Bearer token;无则填 1",required:!0,className:"w-full px-4 py-2 border border-gray-300 dark:border-gray-600 rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500 focus:border-transparent transition-all bg-white dark:bg-gray-800 text-gray-900 dark:text-white"})})]}),Rt>0&&jsxRuntimeExports.jsxs("button",{type:"button",onClick:()=>nt(Rt),className:"text-red-600 dark:text-red-400 hover:text-red-700 dark:hover:text-red-500 text-sm font-medium flex items-center space-x-1 transition-colors",children:[jsxRuntimeExports.jsx("svg",{className:"w-4 h-4",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:jsxRuntimeExports.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M19 7l-.867 12.142A2 2 0 0116.138 21H7.862a2 2 0 01-1.995-1.858L5 7m5 4v6m4-6v6m1-10V4a1 1 0 00-1-1h-4a1 1 0 00-1 1v3M4 7h16"})}),jsxRuntimeExports.jsx("span",{children:"删除此请求头"})]})]},Rt))})]}),jsxRuntimeExports.jsxs("div",{className:"flex items-center space-x-3",children:[jsxRuntimeExports.jsx("input",{type:"checkbox",id:"withCredentials",name:"withCredentials",checked:Ye.withCredentials,onChange:it,className:"h-4 w-4 text-blue-600 border-gray-300 rounded focus:ring-blue-500 dark:bg-gray-700 dark:border-gray-600"}),jsxRuntimeExports.jsx("label",{htmlFor:"withCredentials",className:"text-sm text-gray-700 dark:text-gray-300",children:"启用 withCredentials(跨域请求时发送 Cookie)"})]}),jsxRuntimeExports.jsxs("div",{className:"flex flex-col sm:flex-row gap-4 pt-4",children:[jsxRuntimeExports.jsxs("button",{type:"button",onClick:rt,className:"flex-1 px-6 py-3 bg-gray-100 dark:bg-gray-700 text-gray-700 dark:text-gray-200 rounded-lg hover:bg-gray-200 dark:hover:bg-gray-600 transition-colors font-medium flex items-center justify-center space-x-2",children:[jsxRuntimeExports.jsx("svg",{className:"w-5 h-5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:jsxRuntimeExports.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M12 6v6m0 0v6m0-6h6m-6 0H6"})}),jsxRuntimeExports.jsx("span",{children:"添加请求头"})]}),jsxRuntimeExports.jsxs("button",{type:"button",onClick:ct,className:"flex-1 px-6 py-3 bg-blue-600 text-white rounded-lg hover:bg-blue-700 transition-colors font-medium flex items-center justify-center space-x-2",children:[jsxRuntimeExports.jsx("svg",{className:"w-5 h-5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:jsxRuntimeExports.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M5 13l4 4L19 7"})}),jsxRuntimeExports.jsx("span",{children:"保存配置"})]})]})]})},initialConsoleSettings={},ConsoleSettings=()=>{const[e,t]=reactExports.useState(()=>{try{const Ye=localStorage.getItem("consoleSettings");return Ye?JSON.parse(Ye):initialConsoleSettings}catch(Ye){return console.error("Error reading console settings from localStorage:",Ye),initialConsoleSettings}});return reactExports.useEffect(()=>{try{localStorage.setItem("consoleSettings",JSON.stringify(e))}catch(Ye){console.error("Error writing console settings to localStorage:",Ye)}},[e]),jsxRuntimeExports.jsxs("form",{className:"space-y-6",children:[jsxRuntimeExports.jsxs("div",{className:"bg-blue-50 dark:bg-blue-900/20 p-4 rounded-lg border border-blue-200 dark:border-blue-800",children:[jsxRuntimeExports.jsx("h4",{className:"text-sm font-medium text-blue-900 dark:text-blue-100 mb-2",children:"控制台说明"}),jsxRuntimeExports.jsx("p",{className:"text-sm text-blue-800 dark:text-blue-200 leading-relaxed",children:"控制台用于监控应用程序的运行状态。我们的控制台提供一个兼容 LangChain 的数据上报接口,您可以通过下面的配置来启用控制台输出。"})]}),jsxRuntimeExports.jsxs("ol",{children:[jsxRuntimeExports.jsx("li",{children:"请在 LangGraph 或者 LangChain 项目中使用以下环境变量来启用控制台输出:"}),jsxRuntimeExports.jsxs("li",{children:["LANGSMITH_TRACING=true",jsxRuntimeExports.jsx("br",{}),"LANGSMITH_ENDPOINT= ",new URL("/api/open-smith",window.location.origin).toString()]}),jsxRuntimeExports.jsx("li",{children:"然后可以在主面板的 控制台 按钮中查看控制台输出。"})]})]})},SettingPanel=({isOpen:e,onClose:t,tabs:Ye})=>{var it,ot;const tt=[{id:"server-login",title:"服务器",component:jsxRuntimeExports.jsx(LoginSettings,{})},{id:"console",title:"控制台",component:jsxRuntimeExports.jsx(ConsoleSettings,{})}],rt=Ye?[...tt,...Ye]:tt,[nt,at]=reactExports.useState("general");return reactExports.useEffect(()=>{rt.length>0&&!rt.find(ct=>ct.id===nt)&&at(rt[0].id)},[rt,nt]),e?jsxRuntimeExports.jsx("div",{className:"fixed inset-0 bg-opacity-50 flex items-center justify-center z-50 backdrop-blur-sm",children:jsxRuntimeExports.jsxs("div",{className:"bg-white dark:bg-gray-800 rounded-lg shadow-xl w-full max-w-2xl h-[80vh] flex flex-col relative overflow-hidden ring-1 ring-gray-900/5 dark:ring-white/10",children:[jsxRuntimeExports.jsx("button",{className:"absolute top-3 right-3 text-gray-400 hover:text-gray-600 dark:hover:text-gray-300 z-10 p-1 rounded-full hover:bg-gray-100 dark:hover:bg-gray-700 transition-colors",onClick:t,"aria-label":"关闭设置",children:jsxRuntimeExports.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",className:"h-5 w-5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",strokeWidth:2,children:jsxRuntimeExports.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 18L18 6M6 6l12 12"})})}),jsxRuntimeExports.jsxs("div",{className:"flex flex-1",children:[jsxRuntimeExports.jsxs("div",{className:"w-1/4 border-r border-gray-200 dark:border-gray-700 p-4 flex flex-col",children:[jsxRuntimeExports.jsx("h2",{className:"text-2xl font-bold mb-6 text-gray-900 dark:text-white",children:"设置"}),jsxRuntimeExports.jsx("nav",{className:"flex-1",children:jsxRuntimeExports.jsx("ul",{children:rt.map(ct=>jsxRuntimeExports.jsx("li",{children:jsxRuntimeExports.jsx("button",{id:ct.id+"-button",className:`flex items-center w-full text-left py-2 px-3 rounded-md mb-2 text-base
897
897
  ${nt===ct.id?"bg-blue-500 text-white font-semibold shadow-sm":"text-gray-700 dark:text-gray-300 hover:bg-gray-100 dark:hover:bg-gray-700"}
898
898
  transition-colors duration-200 ease-in-out`,onClick:()=>at(ct.id),children:ct.title})},ct.id))})})]}),jsxRuntimeExports.jsx("div",{className:"w-3/4 p-6 overflow-y-auto bg-gray-50 dark:bg-gray-900",children:jsxRuntimeExports.jsxs("div",{className:"max-w-md mx-auto",children:[jsxRuntimeExports.jsxs("h3",{className:"text-xl font-semibold mb-4 text-gray-900 dark:text-white",children:[(it=rt.find(ct=>ct.id===nt))==null?void 0:it.title," 设置"]}),(ot=rt.find(ct=>ct.id===nt))==null?void 0:ot.component]})})]})]})}):null};var M=(e,t,Ye,tt,rt,nt,at,it)=>{let ot=document.documentElement,ct=["light","dark"];function At(Ft){(Array.isArray(e)?e:[e]).forEach(Ut=>{let Ht=Ut==="class",zt=Ht&&nt?rt.map(Yt=>nt[Yt]||Yt):rt;Ht?(ot.classList.remove(...zt),ot.classList.add(nt&&nt[Ft]?nt[Ft]:Ft)):ot.setAttribute(Ut,Ft)}),Rt(Ft)}function Rt(Ft){it&&ct.includes(Ft)&&(ot.style.colorScheme=Ft)}function qt(){return window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"}if(tt)At(tt);else try{let Ft=localStorage.getItem(t)||Ye,Ut=at&&Ft==="system"?qt():Ft;At(Ut)}catch{}},x=reactExports.createContext(void 0),U={setTheme:e=>{},themes:[]},z=()=>{var e;return(e=reactExports.useContext(x))!=null?e:U};reactExports.memo(({forcedTheme:e,storageKey:t,attribute:Ye,enableSystem:tt,enableColorScheme:rt,defaultTheme:nt,value:at,themes:it,nonce:ot,scriptProps:ct})=>{let At=JSON.stringify([Ye,t,nt,e,it,at,tt,rt]).slice(1,-1);return reactExports.createElement("script",{...ct,suppressHydrationWarning:!0,nonce:typeof window>"u"?ot:"",dangerouslySetInnerHTML:{__html:`(${M.toString()})(${At})`}})});const Toaster=({...e})=>{const{theme:t="system"}=z();return jsxRuntimeExports.jsx(Toaster$1,{theme:t,className:"toaster group",icons:{success:jsxRuntimeExports.jsx(CircleCheck$1,{className:"size-4"}),info:jsxRuntimeExports.jsx(Info$2,{className:"size-4"}),warning:jsxRuntimeExports.jsx(TriangleAlert,{className:"size-4"}),error:jsxRuntimeExports.jsx(OctagonX,{className:"size-4"}),loading:jsxRuntimeExports.jsx(LoaderCircle$1,{className:"size-4 animate-spin"})},style:{"--normal-bg":"var(--popover)","--normal-text":"var(--popover-foreground)","--normal-border":"var(--border)","--border-radius":"var(--radius)"},...e})},UploadButton=()=>{const{uploadedFiles:e,handleFileChange:t,MAX_FILES:Ye}=useFileList();return jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment,{children:e.length<Ye&&jsxRuntimeExports.jsxs("label",{className:"inline-flex items-center justify-center text-gray-700 bg-white rounded-xl cursor-pointer transition-colors hover:bg-gray-200 w-8 h-8",children:[jsxRuntimeExports.jsx(Plus,{size:20}),jsxRuntimeExports.jsx("input",{type:"file",accept:"*",multiple:!0,onChange:t,className:"hidden"})]})})},__default_tool__=createUITool({name:"__default__",description:"any",parameters:{},onlyRender:!1,handler:ToolManager.waitForUIDone,render(e){e.getInputRepaired();const t=e.client.humanInTheLoop;return console.log(t),jsxRuntimeExports.jsx("div",{className:"p-4 space-y-4"})}}),DebugPanelContext=reactExports.createContext(void 0),useDebugPanel=()=>{const e=reactExports.useContext(DebugPanelContext);if(e===void 0)throw new Error("useDebugPanel must be used within a DebugPanelProvider");return e},DebugPanelProvider=({children:e})=>{const[t,Ye]=reactExports.useState(""),[tt,rt]=reactExports.useState(!1),at={isDebugPanelVisible:tt,setIsDebugPanelVisible:rt,toggleDebugPanel:()=>{rt(it=>!it)},messagesContext:t,setMessagesContext(it){Ye(JSON.stringify(it))}};return jsxRuntimeExports.jsx(DebugPanelContext.Provider,{value:at,children:e})},ChatMessages=()=>{const{renderMessages:e,loading:t,inChatError:Ye,client:tt,collapsedTools:rt,toggleToolCollapse:nt,isFELocking:at}=useChat(),it=reactExports.useRef(null),ot=reactExports.useRef(null),{setMessagesContext:ct}=useDebugPanel(),At=()=>{var Rt;(Rt=it.current)==null||Rt.scrollIntoView({behavior:"instant"})};return reactExports.useEffect(()=>{const Rt=ot.current;if(!Rt)return;const qt=new ResizeObserver(()=>{Rt.scrollHeight-Rt.scrollTop-Rt.clientHeight<100&&At()});return qt.observe(Rt),()=>qt.disconnect()},[]),reactExports.useEffect(()=>{e.length>0&&ot.current&&(t||At(),ct(e))},[e]),jsxRuntimeExports.jsxs("div",{className:"flex-1 overflow-y-auto overflow-x-hidden p-6 bg-gray-100",ref:ot,children:[e.length===0&&!t?jsxRuntimeExports.jsx("div",{className:"flex items-center justify-center h-full",children:jsxRuntimeExports.jsxs("div",{className:"text-center",children:[jsxRuntimeExports.jsx("div",{className:"flex items-center justify-center",children:jsxRuntimeExports.jsx("div",{className:"text-6xl mb-4 w-24 h-24 border border-green-300 rounded-full p-4 bg-green-100",children:"🦜"})}),jsxRuntimeExports.jsx("h1",{className:"text-4xl font-bold text-gray-700 mb-2",children:"LangGraph Console"}),jsxRuntimeExports.jsx("div",{className:"text-lg text-gray-500",children:"AI 助手控制台"})]})}):jsxRuntimeExports.jsx(MessagesBox,{renderMessages:e,collapsedTools:rt,toggleToolCollapse:nt,client:tt}),t&&!at()&&jsxRuntimeExports.jsxs("div",{className:"flex items-center justify-center py-6 text-gray-500",children:[jsxRuntimeExports.jsx("div",{className:"animate-spin rounded-full h-4 w-4 border-2 border-blue-500 border-t-transparent mr-2"}),"正在思考中..."]}),Ye&&jsxRuntimeExports.jsx("div",{className:"px-4 py-3 text-sm text-red-600 bg-white rounded-xl",children:JSON.stringify(Ye)}),jsxRuntimeExports.jsx("div",{ref:it})]})},ChatInput=()=>{const{userInput:e,renderMessages:t,setUserInput:Ye,loading:tt,sendMessage:rt,stopGeneration:nt,currentAgent:at,setCurrentAgent:it,client:ot,currentChatId:ct}=useChat(),{extraParams:At}=useExtraParams(),Rt=useMonitor(),{mediaUrls:qt,isFileTextMode:Ft,setIsFileTextMode:Ut}=useFileList(),Ht=Xt=>{localStorage.setItem("defaultAgent",Xt),it(Xt)},zt=()=>{const Xt=qt.map(er=>{var ar,sr,lr,fr;const nr=er.fileType;if(Ft[nr]){const gr=((ar=er.image_url)==null?void 0:ar.url)||((sr=er.video_url)==null?void 0:sr.url)||((lr=er.audio_url)==null?void 0:lr.url)||((fr=er.file_url)==null?void 0:fr.url);return{type:"text",text:`<file type="${nr}" url="${gr}"></file>`}}else return er}),Qt=[{type:"human",content:[{type:"text",text:e},...Xt]}];rt(Qt,{extraParams:At})},Yt=Xt=>{Xt.key==="Enter"&&!Xt.shiftKey&&(Xt.preventDefault(),zt())},[Gt,Vt]=reactExports.useState(!0),Zt=reactExports.useRef(null);return reactExports.useEffect(()=>{qt.length>0||e&&(e.length>50||e.includes(`
899
899
  `))?Vt(!1):Vt(!0)},[t.length,qt.length,e]),reactExports.useEffect(()=>{Zt.current&&(Zt.current.style.height="auto",Gt||(Zt.current.style.height=Math.min(Zt.current.scrollHeight,96)+"px"))},[e,Gt]),jsxRuntimeExports.jsxs("div",{className:" pb-8 ",children:[jsxRuntimeExports.jsxs("div",{className:"bg-white border border-gray-200 shadow-lg shadow-gray-200 "+(Gt?"rounded-full px-3 py-3":"rounded-[2rem] px-4 py-3"),children:[!Gt&&qt.length>0&&jsxRuntimeExports.jsx("div",{className:"flex items-center justify-between mb-2 border-b border-gray-200 pb-2",children:jsxRuntimeExports.jsx(FileList,{})}),jsxRuntimeExports.jsxs("div",{className:`flex gap-3 ${Gt?"items-center":"items-end"}`,children:[jsxRuntimeExports.jsx(UploadButton,{}),jsxRuntimeExports.jsx("textarea",{ref:Zt,className:`flex-1 text-sm resize-none active:outline-none focus:outline-none ${Gt?"":"py-2"}`,rows:1,value:e,onChange:Xt=>Ye(Xt.target.value),onKeyDown:Yt,placeholder:"请输入消息内容…",disabled:tt,style:{maxHeight:Gt?"2rem":"6rem",fontFamily:"inherit",lineHeight:Gt?"2rem":"inherit"}}),jsxRuntimeExports.jsx("select",{value:at,onChange:Xt=>Ht(Xt.target.value),className:"px-4 py-2 text-sm bg-white/60 dark:bg-gray-800/60 rounded-xl focus:outline-none transition-colors",children:ot==null?void 0:ot.availableAssistants.map(Xt=>jsxRuntimeExports.jsx("option",{value:Xt.graph_id,children:Xt.name},Xt.graph_id))}),jsxRuntimeExports.jsx("button",{className:`w-8 h-8 flex items-center justify-center rounded-full focus:outline-none transition-colors ${tt?"bg-red-500 hover:bg-red-600 text-white":"bg-blue-500 hover:bg-blue-600 text-white disabled:opacity-40 disabled:cursor-not-allowed"}`,onClick:()=>tt?nt():zt(),disabled:!tt&&!e.trim()&&qt.length===0,children:tt?jsxRuntimeExports.jsx("svg",{className:"w-4 h-4",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:jsxRuntimeExports.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})}):jsxRuntimeExports.jsx(Send$1,{className:"w-4 h-4"})})]})]}),jsxRuntimeExports.jsxs("div",{className:"flex gap-2 px-8 pt-4 justify-between items-center "+(t.length?"opacity-100":"opacity-0"),children:[jsxRuntimeExports.jsx(UsageMetadata,{usage_metadata:(ot==null?void 0:ot.tokenCounter)||{}}),jsxRuntimeExports.jsx("div",{className:"flex items-center gap-2",children:!!ct&&jsxRuntimeExports.jsxs("span",{className:"cursor-pointer text-xs text-gray-300 dark:text-gray-500",onClick:()=>Rt==null?void 0:Rt.openMonitorWithChat(ct),children:["会话 ID: ",ct]})})]})]})},Chat=()=>{const[e,t]=reactExports.useState(!1),[Ye,tt]=reactExports.useState(!1),{showHistory:rt,toggleHistoryVisible:nt,showGraph:at,toggleGraphVisible:it,renderMessages:ot,setTools:ct,client:At}=useChat(),{extraParams:Rt,setExtraParams:qt}=useExtraParams(),{showArtifact:Ft,sendMessage:Ut}=useChat(),Ht=useMonitor(),{toggleDebugPanel:zt,isDebugPanelVisible:Yt}=useDebugPanel();return reactExports.useEffect(()=>{ct([show_form,create_artifacts,__default_tool__])},[]),jsxRuntimeExports.jsxs("div",{className:"langgraph-chat-container flex h-full w-full overflow-hidden bg-gray-100",children:[rt&&jsxRuntimeExports.jsx("div",{className:"border-r border-gray-200 min-w-64",children:jsxRuntimeExports.jsx(HistoryList,{onClose:()=>nt()})}),jsxRuntimeExports.jsxs("section",{className:"flex-1 flex flex-col overflow-hidden items-center ",children:[jsxRuntimeExports.jsxs("header",{className:"flex items-center gap-2 px-3 py-2 justify-end h-16 mt-4 max-w-6xl w-full",children:[jsxRuntimeExports.jsxs("button",{className:"px-4 py-2 text-sm font-medium text-gray-700 bg-white border border-gray-200 cursor-pointer rounded-xl hover:bg-gray-100 focus:outline-none transition-colors flex items-center gap-2",onClick:()=>{nt(),setLocalConfig({showHistory:!rt})},children:[jsxRuntimeExports.jsx(History,{className:"w-4 h-4"}),"历史记录"]}),jsxRuntimeExports.jsx("div",{className:"flex-1"}),jsxRuntimeExports.jsxs("button",{onClick:()=>t(!0),className:"px-4 py-2 text-sm font-medium text-gray-700 bg-white border border-gray-200 cursor-pointer rounded-xl hover:bg-gray-100 focus:outline-none transition-colors flex items-center gap-2",children:[jsxRuntimeExports.jsx(FileJson,{className:"w-4 h-4"}),"额外参数"]}),jsxRuntimeExports.jsxs("button",{id:"setting-button",onClick:()=>tt(!0),className:"px-4 py-2 text-sm font-medium text-gray-700 bg-white border border-gray-200 cursor-pointer rounded-xl hover:bg-gray-100 focus:outline-none transition-colors flex items-center gap-2",children:[jsxRuntimeExports.jsx(Settings$1,{className:"w-4 h-4"}),"设置"]}),jsxRuntimeExports.jsxs("button",{className:"px-4 py-2 text-sm font-medium text-gray-700 bg-white border border-gray-200 cursor-pointer rounded-xl hover:bg-gray-100 focus:outline-none transition-colors flex items-center gap-2",onClick:()=>{toast.info("数据已打印到控制台,请 F12 查看"),console.log(At==null?void 0:At.graphState)},children:[jsxRuntimeExports.jsx(Printer,{className:"w-4 h-4"}),"打印 State"]}),jsxRuntimeExports.jsxs("button",{className:"px-4 py-2 text-sm font-medium text-gray-700 bg-white border border-gray-200 cursor-pointer rounded-xl hover:bg-gray-100 focus:outline-none transition-colors flex items-center gap-2",onClick:()=>{Ht==null||Ht.openMonitor("/api/open-smith/ui/index.html")},children:[jsxRuntimeExports.jsx(Terminal,{className:"w-4 h-4"}),"控制台"]}),jsxRuntimeExports.jsxs("button",{onClick:zt,className:`px-4 py-2 text-sm font-medium cursor-pointer rounded-xl focus:outline-none transition-colors flex items-center gap-2 ${Yt?"text-blue-700 bg-blue-50 border border-blue-200 hover:bg-blue-100":"text-gray-700 bg-white border border-gray-200 hover:bg-gray-100"}`,children:[jsxRuntimeExports.jsx(Bug,{className:"w-4 h-4"}),"调试面板"]})]}),jsxRuntimeExports.jsxs("main",{className:"flex-1 overflow-hidden max-w-6xl w-full h-full flex flex-col",children:[jsxRuntimeExports.jsx(ChatMessages,{}),jsxRuntimeExports.jsx(FileListProvider,{children:jsxRuntimeExports.jsx(ChatInput,{})})]}),jsxRuntimeExports.jsx(JsonEditorPopup,{isOpen:e,initialJson:Rt,onClose:()=>t(!1),onSave:qt,title:"编辑额外参数",description:"额外参数用于在发送消息时附加到 LangGraph 的 State 中。"}),jsxRuntimeExports.jsx(SettingPanel,{isOpen:Ye,onClose:()=>tt(!1)})]}),(at||Ft)&&jsxRuntimeExports.jsxs("div",{className:"overflow-hidden flex-1",children:[at&&jsxRuntimeExports.jsx(GraphPanel,{}),Ft&&jsxRuntimeExports.jsx(ArtifactViewer,{onSendBackToAI:Gt=>{Ut([{type:"human",content:[{type:"text",text:`