@jutge.org/toolkit 4.4.24 → 4.4.26
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.
- package/dist/index.js +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -400,7 +400,7 @@ jtk-*
|
|
|
400
400
|
a.out
|
|
401
401
|
__pycache__/
|
|
402
402
|
|
|
403
|
-
`)}var o26=q_.object({title:q_.string(),author:q_.string(),email:q_.string(),model:q_.string().optional(),event:q_.string().optional(),date:q_.string().optional()}),U26=q_.object({title:q_.string(),translator:q_.string(),translator_email:q_.string(),original_language:q_.string(),model:q_.string().optional(),event:q_.string().optional(),date:q_.string().optional()}),GP=q_.union([o26,U26]),Q26=q_.enum(["beautifulsoup4","biopython","matplotlib","more - itertools","networkx","numpy","optilog","pandas","scipy","simpy"]),xH=q_.object({handler:q_.enum(["std","graphic","quiz","circuits","game"]).default("std"),solution:q_.string().default("C++"),source_modifier:q_.enum(["none","no_main","structs"]).default("none"),compilers:q_.string().optional(),func_name:q_.string().optional().meta({description:'Name of the function requested in case the problem only asks for a function (use with source_modifier: "no_main")'}),hide_html:q_.boolean().default(!1).meta({description:"If set to true, the statement will not be shown in HTML in the Jutge.org website; use it sparingly"}),invisible_main:q_.boolean().default(!1).meta({description:"If set to true, the main programs will not be provided to users; use it sparingly"}),checker:q_.enum(["std","loosy","epsilon","elastic","elastic2","external"]).default("std").meta({description:"Checker to use for the problem"}),presentation_error:q_.coerce.boolean().default(!0).meta({description:"Enable presentation error checker"}),tolerance:q_.number().optional().meta({description:"Tolerance for the graphic checker"}),pylibs:q_.array(Q26).default([]).meta({description:"List of enabled Python libraries"}),inspector:q_.enum(["hs"]).optional().meta({description:"Inspector to use for the problem"}),game:q_.object({hide:q_.array(q_.string()).default([])}).optional().meta({description:"Options for the game handler"})}),S8_=q_.array(q_.object({part:q_.string(),prefix:q_.string(),points:q_.number().min(0)})),V$=q_.object({problem_nm:q_.string().default(""),email:q_.string().default(""),passcode:q_.string().default(""),shared_testcases:q_.boolean().default(!1),shared_solutions:q_.boolean().default(!1),created_at:q_.string().default(""),updated_at:q_.string().default("")}),M$=q_.object({name:q_.string().min(1).default("John Doe"),email:q_.string().email().default("john.doe@example.com"),defaultModel:q_.string().default("google/gemini-2.5-flash-lite"),notifications:q_.boolean().default(!1),showPrompts:q_.boolean().default(!1),showAnswers:q_.boolean().default(!1),developer:q_.boolean().default(!1)}),t26=q_.object({title:q_.string().nonempty(),file:q_.string().nonempty(),score:q_.int().min(0).max(100)}),dH=q_.object({title:q_.string().default("Untitled Quiz"),statement:q_.string(),questions:q_.array(t26),shuffle:q_.coerce.boolean().default(!1)}).refine((q)=>q.questions.reduce(($,w)=>$+w.score,0)===100,{message:"Question scores must sum to 100",path:["questions"]}),e26=q_.object({maxlength:q_.int().default(100),placeholder:q_.coerce.string().optional(),correct:q_.coerce.string(),ignorecase:q_.boolean().default(!0),trim:q_.boolean().default(!0),options:q_.array(q_.coerce.string().nonempty()).optional(),partial_answer:q_.coerce.boolean().default(!1)}),s26=q_.object({type:q_.literal("FillIn"),hide_score:q_.coerce.boolean().default(!1),text:q_.coerce.string(),context:q_.coerce.string(),items:q_.record(q_.coerce.string().nonempty(),e26),partial_answer:q_.coerce.boolean().default(!1)}).refine((q)=>{for(let $ of Object.values(q.items))if($.options!==void 0&&$.options.length>0){if(!$.options.includes($.correct))return!1}return!0},{message:"For dropdown items, the correct answer must be in the options list",path:["items"]}),_$6=q_.object({type:q_.literal("Ordering"),hide_score:q_.coerce.boolean().default(!1),text:q_.coerce.string(),label:q_.string().nonempty(),items:q_.array(q_.coerce.string().nonempty()),shuffle:q_.coerce.boolean().default(!0),partial_answer:q_.coerce.boolean().default(!1)}),q$6=q_.object({type:q_.literal("Matching"),hide_score:q_.coerce.boolean().default(!1),text:q_.coerce.string(),labels:q_.array(q_.string().nonempty()),left:q_.array(q_.coerce.string().nonempty()),right:q_.array(q_.coerce.string().nonempty()),shuffle:q_.coerce.boolean().default(!0),partial_answer:q_.coerce.boolean().default(!1)}),$$6=q_.object({type:q_.literal("SingleChoice"),hide_score:q_.coerce.boolean().default(!1),text:q_.coerce.string(),choices:q_.array(q_.object({text:q_.coerce.string(),correct:q_.boolean().optional().default(!1),hint:q_.string().optional()})),shuffle:q_.coerce.boolean().default(!0),partial_answer:q_.coerce.boolean().default(!1)}).refine((q)=>q.choices.filter(($)=>$.correct).length===1,{message:"SingleChoice questions must have exactly one correct answer",path:["choices"]}).refine((q)=>q.choices.map(($)=>$.text).filter(($,w,f)=>f.indexOf($)===w).length===q.choices.length,{message:"SingleChoice questions must have no repeated text choices",path:["choices"]}),w$6=q_.object({type:q_.literal("MultipleChoice"),hide_score:q_.coerce.boolean().default(!1),text:q_.coerce.string(),choices:q_.array(q_.object({text:q_.coerce.string(),correct:q_.boolean().optional().default(!1),hint:q_.string().optional()})),shuffle:q_.coerce.boolean().default(!0),partial_answer:q_.coerce.boolean().default(!1)}),f$6=q_.object({type:q_.literal("OpenQuestion"),hide_score:q_.coerce.boolean().default(!1),text:q_.coerce.string(),placeholder:q_.coerce.string().default(""),partial_answer:q_.coerce.boolean().default(!1)}),iy=q_.discriminatedUnion("type",[s26,_$6,q$6,$$6,w$6,f$6]);var K$6=q_.object({email:q_.string(),user_uid:q_.string(),token:q_.string().optional(),expiration:q_.iso.datetime().optional(),savedPassword:q_.string().optional(),active:q_.boolean().optional()}),m8_=q_.record(q_.string(),K$6);var AP=eJ("jutge",{suffix:"toolkit"});function rH(){return P$6(AP.config,"config.yml")}async function D$6(){await lH(AP.config,{recursive:!0}),await lH(AP.data,{recursive:!0}),await lH(AP.cache,{recursive:!0}),await lH(AP.log,{recursive:!0}),await lH(AP.temp,{recursive:!0})}async function iH(q){return await D$6(),q=M$.parse(q),await C$(rH(),q)}async function py(){let q=await X3(rH());return M$.parse(q)}async function Y$6(){if(!await J$6()){let q=M$.parse({});return q.name=await g8_()||"John Doe",q.email=await b8_()||"john.doe@example.com",await iH(q),q}else return await py()}async function J$6(){return await z$6(rH())}var z8=await Y$6();var yx=z6(M3_(),1);import{execSync as oZ_}from"child_process";import{join as rA6}from"path";var w56=Q4([m_(),u2({url:e_(m_()),email:e_(m_())})]),f56=Q4([m_(),u2({url:m_(),type:e_(m_())}),m4(Q4([m_(),u2({url:m_(),type:e_(m_())})]))]),KS=Q4([m_(),u2({name:m_(),email:e_(m_()),url:e_(m_())})]),K56=Q4([m_(),u2({type:m_(),url:m_(),directory:e_(m_())})]),N3_=u2({name:m_(),version:e_(m_()),onFail:e_(QJ(["ignore","warn","error"]))}),tH=Q4([N3_,m4(N3_)]),z56=u2({cpu:e_(tH),os:e_(tH),libc:e_(tH),runtime:e_(tH),packageManager:e_(tH)}),zS=H0({name:m_(),version:m_(),description:e_(m_()),keywords:e_(m4(m_())),homepage:e_(m_()),bugs:e_(w56),license:e_(m_()),author:e_(KS),contributors:e_(m4(KS)),maintainers:e_(m4(KS)),funding:e_(f56),files:e_(m4(m_())),exports:e_(Q4([aJ(),m_(),m4(m_()),L4(m_(),_q())])),type:e_(QJ(["module","commonjs"])),main:e_(m_()),browser:e_(Q4([m_(),L4(m_(),Q4([m_(),W$()]))])),bin:e_(Q4([m_(),L4(m_(),m_())])),man:e_(Q4([m_(),m4(m_())])),directories:e_(L4(m_(),m_())),repository:e_(K56),scripts:e_(L4(m_(),m_())),config:e_(L4(m_(),_q())),dependencies:e_(L4(m_(),m_())),devDependencies:e_(L4(m_(),m_())),peerDependencies:e_(L4(m_(),m_())),peerDependenciesMeta:e_(L4(m_(),u2({optional:W$()}))),bundleDependencies:e_(Q4([W$(),m4(m_())])),bundledDependencies:e_(Q4([W$(),m4(m_())])),optionalDependencies:e_(L4(m_(),m_())),overrides:e_(L4(m_(),_q())),engines:e_(L4(m_(),m_())),os:e_(m4(m_())),cpu:e_(m4(m_())),libc:e_(m_()),devEngines:e_(z56),private:e_(W$()),publishConfig:e_(L4(m_(),_q())),workspaces:e_(m4(m_())),deprecated:e_(m_()),module:e_(m_()),types:e_(m_()),typings:e_(m_()),typesVersions:e_(L4(m_(),L4(m_(),m4(m_())))),packageManager:e_(m_()),sideEffects:e_(Q4([W$(),m4(m_())])),imports:e_(L4(m_(),_q()))});var eH=(q,$=[])=>q.name==="up"||$.includes("vim")&&q.name==="k"||$.includes("emacs")&&q.ctrl&&q.name==="p",RX=(q,$=[])=>q.name==="down"||$.includes("vim")&&q.name==="j"||$.includes("emacs")&&q.ctrl&&q.name==="n",PS=(q)=>q.name==="space";var DS=(q)=>"1234567890".includes(q.name),YS=(q)=>q.name==="enter"||q.name==="return";class JS extends Error{name="AbortPromptError";message="Prompt was aborted";constructor(q){super();this.cause=q?.cause}}class HS extends Error{name="CancelPromptError";message="Prompt was canceled"}class IX extends Error{name="ExitPromptError"}class ZS extends Error{name="HookError"}class sH extends Error{name="ValidationError"}import{AsyncResource as J56}from"async_hooks";import{AsyncLocalStorage as P56,AsyncResource as D56}from"async_hooks";var h3_=new P56;function Y56(q){return{rl:q,hooks:[],hooksCleanup:[],hooksEffect:[],index:0,handleChange(){}}}function E3_(q,$){let w=Y56(q);return h3_.run(w,()=>{function f(K){w.handleChange=()=>{w.index=0,K()},w.handleChange()}return $(f)})}function zf(){let q=h3_.getStore();if(!q)throw new ZS("[Inquirer] Hook functions can only be called from within a prompt");return q}function kS(){return zf().rl}function OS(q){let $=(...w)=>{let f=zf(),K=!1,z=f.handleChange;f.handleChange=()=>{K=!0};let P=q(...w);if(K)z();return f.handleChange=z,P};return D56.bind($)}function CP(q){let $=zf(),{index:w}=$,f={get(){return $.hooks[w]},set(z){$.hooks[w]=z},initialized:w in $.hooks},K=q(f);return $.index++,K}function g3_(){zf().handleChange()}var Pf={queue(q){let $=zf(),{index:w}=$;$.hooksEffect.push(()=>{$.hooksCleanup[w]?.();let f=q(kS());if(f!=null&&typeof f!=="function")throw new sH("useEffect return value must be a cleanup function or nothing.");$.hooksCleanup[w]=f})},run(){let q=zf();OS(()=>{q.hooksEffect.forEach(($)=>{$()}),q.hooksEffect.length=0})()},clearAll(){let q=zf();q.hooksCleanup.forEach(($)=>{$?.()}),q.hooksEffect.length=0,q.hooksCleanup.length=0}};function g2(q){return CP(($)=>{let w=J56.bind(function(z){if($.get()!==z)$.set(z),g3_()});if($.initialized)return[$.get(),w];let f=typeof q==="function"?q():q;return $.set(f),[f,w]})}function yX(q,$){CP((w)=>{let f=w.get();if(!Array.isArray(f)||$.some((z,P)=>!Object.is(z,f[P])))Pf.queue(q);w.set($)})}import{styleText as b2}from"util";import h$ from"process";function H56(){if(h$.platform!=="win32")return h$.env.TERM!=="linux";return Boolean(h$.env.WT_SESSION)||Boolean(h$.env.TERMINUS_SUBLIME)||h$.env.ConEmuTask==="{cmd::Cmder}"||h$.env.TERM_PROGRAM==="Terminus-Sublime"||h$.env.TERM_PROGRAM==="vscode"||h$.env.TERM==="xterm-256color"||h$.env.TERM==="alacritty"||h$.env.TERMINAL_EMULATOR==="JetBrains-JediTerm"}var b3_={circleQuestionMark:"(?)",questionMarkPrefix:"(?)",square:"\u2588",squareDarkShade:"\u2593",squareMediumShade:"\u2592",squareLightShade:"\u2591",squareTop:"\u2580",squareBottom:"\u2584",squareLeft:"\u258C",squareRight:"\u2590",squareCenter:"\u25A0",bullet:"\u25CF",dot:"\u2024",ellipsis:"\u2026",pointerSmall:"\u203A",triangleUp:"\u25B2",triangleUpSmall:"\u25B4",triangleDown:"\u25BC",triangleDownSmall:"\u25BE",triangleLeftSmall:"\u25C2",triangleRightSmall:"\u25B8",home:"\u2302",heart:"\u2665",musicNote:"\u266A",musicNoteBeamed:"\u266B",arrowUp:"\u2191",arrowDown:"\u2193",arrowLeft:"\u2190",arrowRight:"\u2192",arrowLeftRight:"\u2194",arrowUpDown:"\u2195",almostEqual:"\u2248",notEqual:"\u2260",lessOrEqual:"\u2264",greaterOrEqual:"\u2265",identical:"\u2261",infinity:"\u221E",subscriptZero:"\u2080",subscriptOne:"\u2081",subscriptTwo:"\u2082",subscriptThree:"\u2083",subscriptFour:"\u2084",subscriptFive:"\u2085",subscriptSix:"\u2086",subscriptSeven:"\u2087",subscriptEight:"\u2088",subscriptNine:"\u2089",oneHalf:"\xBD",oneThird:"\u2153",oneQuarter:"\xBC",oneFifth:"\u2155",oneSixth:"\u2159",oneEighth:"\u215B",twoThirds:"\u2154",twoFifths:"\u2156",threeQuarters:"\xBE",threeFifths:"\u2157",threeEighths:"\u215C",fourFifths:"\u2158",fiveSixths:"\u215A",fiveEighths:"\u215D",sevenEighths:"\u215E",line:"\u2500",lineBold:"\u2501",lineDouble:"\u2550",lineDashed0:"\u2504",lineDashed1:"\u2505",lineDashed2:"\u2508",lineDashed3:"\u2509",lineDashed4:"\u254C",lineDashed5:"\u254D",lineDashed6:"\u2574",lineDashed7:"\u2576",lineDashed8:"\u2578",lineDashed9:"\u257A",lineDashed10:"\u257C",lineDashed11:"\u257E",lineDashed12:"\u2212",lineDashed13:"\u2013",lineDashed14:"\u2010",lineDashed15:"\u2043",lineVertical:"\u2502",lineVerticalBold:"\u2503",lineVerticalDouble:"\u2551",lineVerticalDashed0:"\u2506",lineVerticalDashed1:"\u2507",lineVerticalDashed2:"\u250A",lineVerticalDashed3:"\u250B",lineVerticalDashed4:"\u254E",lineVerticalDashed5:"\u254F",lineVerticalDashed6:"\u2575",lineVerticalDashed7:"\u2577",lineVerticalDashed8:"\u2579",lineVerticalDashed9:"\u257B",lineVerticalDashed10:"\u257D",lineVerticalDashed11:"\u257F",lineDownLeft:"\u2510",lineDownLeftArc:"\u256E",lineDownBoldLeftBold:"\u2513",lineDownBoldLeft:"\u2512",lineDownLeftBold:"\u2511",lineDownDoubleLeftDouble:"\u2557",lineDownDoubleLeft:"\u2556",lineDownLeftDouble:"\u2555",lineDownRight:"\u250C",lineDownRightArc:"\u256D",lineDownBoldRightBold:"\u250F",lineDownBoldRight:"\u250E",lineDownRightBold:"\u250D",lineDownDoubleRightDouble:"\u2554",lineDownDoubleRight:"\u2553",lineDownRightDouble:"\u2552",lineUpLeft:"\u2518",lineUpLeftArc:"\u256F",lineUpBoldLeftBold:"\u251B",lineUpBoldLeft:"\u251A",lineUpLeftBold:"\u2519",lineUpDoubleLeftDouble:"\u255D",lineUpDoubleLeft:"\u255C",lineUpLeftDouble:"\u255B",lineUpRight:"\u2514",lineUpRightArc:"\u2570",lineUpBoldRightBold:"\u2517",lineUpBoldRight:"\u2516",lineUpRightBold:"\u2515",lineUpDoubleRightDouble:"\u255A",lineUpDoubleRight:"\u2559",lineUpRightDouble:"\u2558",lineUpDownLeft:"\u2524",lineUpBoldDownBoldLeftBold:"\u252B",lineUpBoldDownBoldLeft:"\u2528",lineUpDownLeftBold:"\u2525",lineUpBoldDownLeftBold:"\u2529",lineUpDownBoldLeftBold:"\u252A",lineUpDownBoldLeft:"\u2527",lineUpBoldDownLeft:"\u2526",lineUpDoubleDownDoubleLeftDouble:"\u2563",lineUpDoubleDownDoubleLeft:"\u2562",lineUpDownLeftDouble:"\u2561",lineUpDownRight:"\u251C",lineUpBoldDownBoldRightBold:"\u2523",lineUpBoldDownBoldRight:"\u2520",lineUpDownRightBold:"\u251D",lineUpBoldDownRightBold:"\u2521",lineUpDownBoldRightBold:"\u2522",lineUpDownBoldRight:"\u251F",lineUpBoldDownRight:"\u251E",lineUpDoubleDownDoubleRightDouble:"\u2560",lineUpDoubleDownDoubleRight:"\u255F",lineUpDownRightDouble:"\u255E",lineDownLeftRight:"\u252C",lineDownBoldLeftBoldRightBold:"\u2533",lineDownLeftBoldRightBold:"\u252F",lineDownBoldLeftRight:"\u2530",lineDownBoldLeftBoldRight:"\u2531",lineDownBoldLeftRightBold:"\u2532",lineDownLeftRightBold:"\u252E",lineDownLeftBoldRight:"\u252D",lineDownDoubleLeftDoubleRightDouble:"\u2566",lineDownDoubleLeftRight:"\u2565",lineDownLeftDoubleRightDouble:"\u2564",lineUpLeftRight:"\u2534",lineUpBoldLeftBoldRightBold:"\u253B",lineUpLeftBoldRightBold:"\u2537",lineUpBoldLeftRight:"\u2538",lineUpBoldLeftBoldRight:"\u2539",lineUpBoldLeftRightBold:"\u253A",lineUpLeftRightBold:"\u2536",lineUpLeftBoldRight:"\u2535",lineUpDoubleLeftDoubleRightDouble:"\u2569",lineUpDoubleLeftRight:"\u2568",lineUpLeftDoubleRightDouble:"\u2567",lineUpDownLeftRight:"\u253C",lineUpBoldDownBoldLeftBoldRightBold:"\u254B",lineUpDownBoldLeftBoldRightBold:"\u2548",lineUpBoldDownLeftBoldRightBold:"\u2547",lineUpBoldDownBoldLeftRightBold:"\u254A",lineUpBoldDownBoldLeftBoldRight:"\u2549",lineUpBoldDownLeftRight:"\u2540",lineUpDownBoldLeftRight:"\u2541",lineUpDownLeftBoldRight:"\u253D",lineUpDownLeftRightBold:"\u253E",lineUpBoldDownBoldLeftRight:"\u2542",lineUpDownLeftBoldRightBold:"\u253F",lineUpBoldDownLeftBoldRight:"\u2543",lineUpBoldDownLeftRightBold:"\u2544",lineUpDownBoldLeftBoldRight:"\u2545",lineUpDownBoldLeftRightBold:"\u2546",lineUpDoubleDownDoubleLeftDoubleRightDouble:"\u256C",lineUpDoubleDownDoubleLeftRight:"\u256B",lineUpDownLeftDoubleRightDouble:"\u256A",lineCross:"\u2573",lineBackslash:"\u2572",lineSlash:"\u2571"},R3_={tick:"\u2714",info:"\u2139",warning:"\u26A0",cross:"\u2718",squareSmall:"\u25FB",squareSmallFilled:"\u25FC",circle:"\u25EF",circleFilled:"\u25C9",circleDotted:"\u25CC",circleDouble:"\u25CE",circleCircle:"\u24DE",circleCross:"\u24E7",circlePipe:"\u24BE",radioOn:"\u25C9",radioOff:"\u25EF",checkboxOn:"\u2612",checkboxOff:"\u2610",checkboxCircleOn:"\u24E7",checkboxCircleOff:"\u24BE",pointer:"\u276F",triangleUpOutline:"\u25B3",triangleLeft:"\u25C0",triangleRight:"\u25B6",lozenge:"\u25C6",lozengeOutline:"\u25C7",hamburger:"\u2630",smiley:"\u32E1",mustache:"\u0DF4",star:"\u2605",play:"\u25B6",nodejs:"\u2B22",oneSeventh:"\u2150",oneNinth:"\u2151",oneTenth:"\u2152"},Z56={tick:"\u221A",info:"i",warning:"\u203C",cross:"\xD7",squareSmall:"\u25A1",squareSmallFilled:"\u25A0",circle:"( )",circleFilled:"(*)",circleDotted:"( )",circleDouble:"( )",circleCircle:"(\u25CB)",circleCross:"(\xD7)",circlePipe:"(\u2502)",radioOn:"(*)",radioOff:"( )",checkboxOn:"[\xD7]",checkboxOff:"[ ]",checkboxCircleOn:"(\xD7)",checkboxCircleOff:"( )",pointer:">",triangleUpOutline:"\u2206",triangleLeft:"\u25C4",triangleRight:"\u25BA",lozenge:"\u2666",lozengeOutline:"\u25CA",hamburger:"\u2261",smiley:"\u263A",mustache:"\u250C\u2500\u2510",star:"\u2736",play:"\u25BA",nodejs:"\u2666",oneSeventh:"1/7",oneNinth:"1/9",oneTenth:"1/10"},k56={...b3_,...R3_},O56={...b3_,...Z56},W56=H56(),v56=W56?k56:O56,F7=v56,aJ8=Object.entries(R3_);var I3_={prefix:{idle:b2("blue","?"),done:b2("green",F7.tick)},spinner:{interval:80,frames:["\u280B","\u2819","\u2839","\u2838","\u283C","\u2834","\u2826","\u2827","\u2807","\u280F"].map((q)=>b2("yellow",q))},style:{answer:(q)=>b2("cyan",q),message:(q)=>b2("bold",q),error:(q)=>b2("red",`> ${q}`),defaultAnswer:(q)=>b2("dim",`(${q})`),help:(q)=>b2("dim",q),highlight:(q)=>b2("cyan",q),key:(q)=>b2("cyan",b2("bold",`<${q}>`))}};function y3_(q){if(typeof q!=="object"||q===null)return!1;let $=q;while(Object.getPrototypeOf($)!==null)$=Object.getPrototypeOf($);return Object.getPrototypeOf(q)===$}function S3_(...q){let $={};for(let w of q)for(let[f,K]of Object.entries(w)){let z=$[f];$[f]=y3_(z)&&y3_(K)?S3_(z,K):K}return $}function _Z(...q){let $=[I3_,...q.filter((w)=>w!=null)];return S3_(...$)}function WS({status:q="idle",theme:$}){let[w,f]=g2(!1),[K,z]=g2(0),{prefix:P,spinner:D}=_Z($);if(yX(()=>{if(q==="loading"){let J,Z=-1,k=setTimeout(()=>{f(!0),J=setInterval(()=>{Z=Z+1,z(Z%D.frames.length)},D.interval)},300);return()=>{clearTimeout(k),clearInterval(J)}}else f(!1)},[q]),w)return D.frames[K];return typeof P==="string"?P:P[q==="loading"?"idle":q]??P.idle}function vS(q,$){return CP((w)=>{let f=w.get();if(!f||f.dependencies.length!==$.length||f.dependencies.some((K,z)=>K!==$[z])){let K=q();return w.set({value:K,dependencies:$}),K}return f.value})}function SX(q){return g2({current:q})[0]}function TS(q){let $=SX(q);$.current=q,yX((w)=>{let f=!1,K=OS((z,P)=>{if(f)return;$.current(P,w)});return w.input.on("keypress",K),()=>{f=!0,w.input.removeListener("keypress",K)}},[])}var Q3_=z6(u5(),1);var L3_=(()=>{let q=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g;return($)=>{let w=0;q.lastIndex=0;while(q.test($))w+=1;return $.length-w}})(),c3_=(q)=>{return q===12288||q>=65281&&q<=65376||q>=65504&&q<=65510},x3_=(q)=>{return q===8987||q===9001||q>=12272&&q<=12287||q>=12289&&q<=12350||q>=12441&&q<=12543||q>=12549&&q<=12591||q>=12593&&q<=12686||q>=12688&&q<=12771||q>=12783&&q<=12830||q>=12832&&q<=12871||q>=12880&&q<=19903||q>=65040&&q<=65049||q>=65072&&q<=65106||q>=65108&&q<=65126||q>=65128&&q<=65131||q>=127488&&q<=127490||q>=127504&&q<=127547||q>=127552&&q<=127560||q>=131072&&q<=196605||q>=196608&&q<=262141};var j56=/[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]|\u001b\]8;[^;]*;.*?(?:\u0007|\u001b\u005c)/y,G56=/[\x00-\x08\x0A-\x1F\x7F-\x9F]{1,1000}/y,d3_=/(?:(?![\uFF61-\uFF9F\uFF00-\uFFEF])[\p{Script=Han}\p{Script=Hiragana}\p{Script=Katakana}\p{Script=Hangul}\p{Script=Tangut}]){1,1000}/yu,A56=/\t{1,1000}/y,l3_=/[\u{1F1E6}-\u{1F1FF}]{2}|\u{1F3F4}[\u{E0061}-\u{E007A}]{2}[\u{E0030}-\u{E0039}\u{E0061}-\u{E007A}]{1,3}\u{E007F}|(?:\p{Emoji}\uFE0F\u20E3?|\p{Emoji_Modifier_Base}\p{Emoji_Modifier}?|\p{Emoji_Presentation})(?:\u200D(?:\p{Emoji_Modifier_Base}\p{Emoji_Modifier}?|\p{Emoji_Presentation}|\p{Emoji}\uFE0F\u20E3?))*/yu,u56=/(?:[\x20-\x7E\xA0-\xFF](?!\uFE0F)){1,1000}/y,C56=/\p{M}+/gu,V56={limit:1/0,ellipsis:""},r3_=(q,$={},w={})=>{let f=$.limit??1/0,K=$.ellipsis??"",z=$?.ellipsisWidth??(K?r3_(K,V56,w).width:0),P=0,D=w.controlWidth??0,Y=w.tabWidth??8,J=w.emojiWidth??2,Z=2,k=w.regularWidth??1,W=w.wideWidth??2,v=[[u56,k],[j56,0],[G56,D],[A56,Y],[l3_,J],[d3_,W]],X=0,j=0,G=q.length,C=0,N=!1,V=G,E=Math.max(0,f-z),b=0,R=0,S=0,p=0;_:while(!0){if(R>b||j>=G&&j>X){let y=q.slice(b,R)||q.slice(X,j);C=0;for(let a of y.replaceAll(C56,"")){let e=a.codePointAt(0)||0;if(c3_(e))p=2;else if(x3_(e))p=W;else p=k;if(S+p>E)V=Math.min(V,Math.max(b,X)+C);if(S+p>f){N=!0;break _}C+=a.length,S+=p}b=R=0}if(j>=G)break _;for(let y=0,a=v.length;y<a;y++){let[e,Q]=v[y];if(e.lastIndex=j,e.test(q)){if(C=e===d3_?L3_(q.slice(j,e.lastIndex)):e===l3_?1:e.lastIndex-j,p=C*Q,S+p>E)V=Math.min(V,j+Math.floor((E-S)/Q));if(S+p>f){N=!0;break _}S+=p,b=X,R=j,j=X=e.lastIndex;continue _}}j+=1}return{width:N?E:S,index:N?V:G,truncated:N,ellipsed:N&&f>=z}},i3_=r3_;var M56={limit:1/0,ellipsis:"",ellipsisWidth:0},N56=(q,$={})=>{return i3_(q,M56,$).width},o7=N56;var mX="\x1B",F3_="\x9B",h56=39,jS="\x07",o3_="[",E56="]",U3_="m",GS=`${E56}8;;`,p3_=new RegExp(`(?:\\${o3_}(?<code>\\d+)m|\\${GS}(?<uri>.*)${jS})`,"y"),n3_=(q)=>{if(q>=30&&q<=37)return 39;if(q>=90&&q<=97)return 39;if(q>=40&&q<=47)return 49;if(q>=100&&q<=107)return 49;if(q===1||q===2)return 22;if(q===3)return 23;if(q===4)return 24;if(q===7)return 27;if(q===8)return 28;if(q===9)return 29;if(q===0)return 0;return},a3_=(q)=>`${mX}${o3_}${q}${U3_}`,B3_=(q)=>`${mX}${GS}${q}${jS}`,XS=(q,$,w)=>{let f=$[Symbol.iterator](),K=!1,z=!1,P=q.at(-1),D=P===void 0?0:o7(P),Y=f.next(),J=f.next(),Z=0;while(!Y.done){let k=Y.value,W=o7(k);if(D+W<=w)q[q.length-1]+=k;else q.push(k),D=0;if(k===mX||k===F3_)K=!0,z=$.startsWith(GS,Z+1);if(K){if(z){if(k===jS)K=!1,z=!1}else if(k===U3_)K=!1}else if(D+=W,D===w&&!J.done)q.push(""),D=0;Y=J,J=f.next(),Z+=k.length}if(P=q.at(-1),!D&&P!==void 0&&P.length&&q.length>1)q[q.length-2]+=q.pop()},g56=(q)=>{let $=q.split(" "),w=$.length;while(w){if(o7($[w-1]))break;w--}if(w===$.length)return q;return $.slice(0,w).join(" ")+$.slice(w).join("")},b56=(q,$,w={})=>{if(w.trim!==!1&&q.trim()==="")return"";let f="",K,z,P=q.split(" "),D=[""],Y=0;for(let k=0;k<P.length;k++){let W=P[k];if(w.trim!==!1){let X=D.at(-1)??"",j=X.trimStart();if(X.length!==j.length)D[D.length-1]=j,Y=o7(j)}if(k!==0){if(Y>=$&&(w.wordWrap===!1||w.trim===!1))D.push(""),Y=0;if(Y||w.trim===!1)D[D.length-1]+=" ",Y++}let v=o7(W);if(w.hard&&v>$){let X=$-Y,j=1+Math.floor((v-X-1)/$);if(Math.floor((v-1)/$)<j)D.push("");XS(D,W,$),Y=o7(D.at(-1)??"");continue}if(Y+v>$&&Y&&v){if(w.wordWrap===!1&&Y<$){XS(D,W,$),Y=o7(D.at(-1)??"");continue}D.push(""),Y=0}if(Y+v>$&&w.wordWrap===!1){XS(D,W,$),Y=o7(D.at(-1)??"");continue}D[D.length-1]+=W,Y+=v}if(w.trim!==!1)D=D.map((k)=>g56(k));let J=D.join(`
|
|
403
|
+
`)}var o26=q_.object({title:q_.string(),author:q_.string(),email:q_.string(),model:q_.string().optional(),event:q_.string().optional(),date:q_.string().optional()}),U26=q_.object({title:q_.string(),translator:q_.string(),translator_email:q_.string(),original_language:q_.string(),model:q_.string().optional(),event:q_.string().optional(),date:q_.string().optional()}),GP=q_.union([o26,U26]),Q26=q_.enum(["beautifulsoup4","biopython","matplotlib","more - itertools","networkx","numpy","optilog","pandas","scipy","simpy"]),xH=q_.object({handler:q_.enum(["std","graphic","quiz","circuits","game"]).default("std"),solution:q_.string().default("C++"),source_modifier:q_.enum(["none","no_main","structs"]).default("none"),compilers:q_.string().optional(),func_name:q_.string().optional().meta({description:'Name of the function requested in case the problem only asks for a function (use with source_modifier: "no_main")'}),hide_html:q_.boolean().default(!1).meta({description:"If set to true, the statement will not be shown in HTML in the Jutge.org website; use it sparingly"}),invisible_main:q_.boolean().default(!1).meta({description:"If set to true, the main programs will not be provided to users; use it sparingly"}),checker:q_.enum(["std","loosy","epsilon","elastic","elastic2","external"]).default("std").meta({description:"Checker to use for the problem"}),separator:q_.string().optional().meta({description:"Separator to use for the elastic checker"}),separator1:q_.string().optional().meta({description:"Separator to use for the elastic2 checker (first separator)"}),separator2:q_.string().optional().meta({description:"Separator to use for the elastic2 checker (second separator)"}),starting:q_.string().optional().meta({description:"Starting string to use for the elastic2 checker"}),ending:q_.string().optional().meta({description:"Ending string to use for the elastic2 checker"}),external_program:q_.string().optional().meta({description:"External program to use for the external checker"}),epsilon:q_.number().optional().meta({description:"Epsilon for the epsilon checker"}),relative:q_.boolean().optional().meta({description:"Relative mode for the epsilon checker"}),presentation_error:q_.coerce.boolean().default(!0).meta({description:"Enable presentation error checker"}),tolerance:q_.number().optional().meta({description:"Tolerance for the graphic checker"}),pylibs:q_.array(Q26).default([]).meta({description:"List of enabled Python libraries"}),inspector:q_.enum(["hs"]).optional().meta({description:"Inspector to use for the problem"}),game:q_.object({hide:q_.array(q_.string()).default([])}).optional().meta({description:"Options for the game handler"})}).refine((q)=>{return!(q.checker==="elastic"&&q.separator===void 0)},{message:"Field 'separator' is required if 'checker' is 'elastic'",path:["checker"]}).refine((q)=>{return!(q.checker==="elastic2"&&(q.separator1===void 0||q.separator2===void 0||q.starting===void 0||q.ending===void 0))},{message:"Fields 'separator1', 'separator2', 'starting' and 'ending' are required if 'checker' is 'elastic2'",path:["checker"]}).refine((q)=>{return!(q.checker==="external"&&q.external_program===void 0)},{message:"Field 'external_program' is required if 'checker' is 'external'",path:["checker"]}).refine((q)=>{return!(q.checker==="epsilon"&&q.epsilon===void 0)},{message:"Field 'epsilon' is required if 'checker' is 'epsilon'",path:["checker"]}),S8_=q_.array(q_.object({part:q_.string(),prefix:q_.string(),points:q_.number().min(0)})),V$=q_.object({problem_nm:q_.string().default(""),email:q_.string().default(""),passcode:q_.string().default(""),shared_testcases:q_.boolean().default(!1),shared_solutions:q_.boolean().default(!1),created_at:q_.string().default(""),updated_at:q_.string().default("")}),M$=q_.object({name:q_.string().min(1).default("John Doe"),email:q_.string().email().default("john.doe@example.com"),defaultModel:q_.string().default("google/gemini-2.5-flash-lite"),notifications:q_.boolean().default(!1),showPrompts:q_.boolean().default(!1),showAnswers:q_.boolean().default(!1),developer:q_.boolean().default(!1)}),t26=q_.object({title:q_.string().nonempty(),file:q_.string().nonempty(),score:q_.int().min(0).max(100)}),dH=q_.object({title:q_.string().default("Untitled Quiz"),statement:q_.string(),questions:q_.array(t26),shuffle:q_.coerce.boolean().default(!1)}).refine((q)=>q.questions.reduce(($,w)=>$+w.score,0)===100,{message:"Question scores must sum to 100",path:["questions"]}),e26=q_.object({maxlength:q_.int().default(100),placeholder:q_.coerce.string().optional(),correct:q_.coerce.string(),ignorecase:q_.boolean().default(!0),trim:q_.boolean().default(!0),options:q_.array(q_.coerce.string().nonempty()).optional(),partial_answer:q_.coerce.boolean().default(!1)}),s26=q_.object({type:q_.literal("FillIn"),hide_score:q_.coerce.boolean().default(!1),text:q_.coerce.string(),context:q_.coerce.string(),items:q_.record(q_.coerce.string().nonempty(),e26),partial_answer:q_.coerce.boolean().default(!1)}).refine((q)=>{for(let $ of Object.values(q.items))if($.options!==void 0&&$.options.length>0){if(!$.options.includes($.correct))return!1}return!0},{message:"For dropdown items, the correct answer must be in the options list",path:["items"]}),_$6=q_.object({type:q_.literal("Ordering"),hide_score:q_.coerce.boolean().default(!1),text:q_.coerce.string(),label:q_.string().nonempty(),items:q_.array(q_.coerce.string().nonempty()),shuffle:q_.coerce.boolean().default(!0),partial_answer:q_.coerce.boolean().default(!1)}),q$6=q_.object({type:q_.literal("Matching"),hide_score:q_.coerce.boolean().default(!1),text:q_.coerce.string(),labels:q_.array(q_.string().nonempty()),left:q_.array(q_.coerce.string().nonempty()),right:q_.array(q_.coerce.string().nonempty()),shuffle:q_.coerce.boolean().default(!0),partial_answer:q_.coerce.boolean().default(!1)}),$$6=q_.object({type:q_.literal("SingleChoice"),hide_score:q_.coerce.boolean().default(!1),text:q_.coerce.string(),choices:q_.array(q_.object({text:q_.coerce.string(),correct:q_.boolean().optional().default(!1),hint:q_.string().optional()})),shuffle:q_.coerce.boolean().default(!0),partial_answer:q_.coerce.boolean().default(!1)}).refine((q)=>q.choices.filter(($)=>$.correct).length===1,{message:"SingleChoice questions must have exactly one correct answer",path:["choices"]}).refine((q)=>q.choices.map(($)=>$.text).filter(($,w,f)=>f.indexOf($)===w).length===q.choices.length,{message:"SingleChoice questions must have no repeated text choices",path:["choices"]}),w$6=q_.object({type:q_.literal("MultipleChoice"),hide_score:q_.coerce.boolean().default(!1),text:q_.coerce.string(),choices:q_.array(q_.object({text:q_.coerce.string(),correct:q_.boolean().optional().default(!1),hint:q_.string().optional()})),shuffle:q_.coerce.boolean().default(!0),partial_answer:q_.coerce.boolean().default(!1)}),f$6=q_.object({type:q_.literal("OpenQuestion"),hide_score:q_.coerce.boolean().default(!1),text:q_.coerce.string(),placeholder:q_.coerce.string().default(""),partial_answer:q_.coerce.boolean().default(!1)}),iy=q_.discriminatedUnion("type",[s26,_$6,q$6,$$6,w$6,f$6]);var K$6=q_.object({email:q_.string(),user_uid:q_.string(),token:q_.string().optional(),expiration:q_.iso.datetime().optional(),savedPassword:q_.string().optional(),active:q_.boolean().optional()}),m8_=q_.record(q_.string(),K$6);var AP=eJ("jutge",{suffix:"toolkit"});function rH(){return P$6(AP.config,"config.yml")}async function D$6(){await lH(AP.config,{recursive:!0}),await lH(AP.data,{recursive:!0}),await lH(AP.cache,{recursive:!0}),await lH(AP.log,{recursive:!0}),await lH(AP.temp,{recursive:!0})}async function iH(q){return await D$6(),q=M$.parse(q),await C$(rH(),q)}async function py(){let q=await X3(rH());return M$.parse(q)}async function Y$6(){if(!await J$6()){let q=M$.parse({});return q.name=await g8_()||"John Doe",q.email=await b8_()||"john.doe@example.com",await iH(q),q}else return await py()}async function J$6(){return await z$6(rH())}var z8=await Y$6();var yx=z6(M3_(),1);import{execSync as oZ_}from"child_process";import{join as rA6}from"path";var w56=Q4([m_(),u2({url:e_(m_()),email:e_(m_())})]),f56=Q4([m_(),u2({url:m_(),type:e_(m_())}),m4(Q4([m_(),u2({url:m_(),type:e_(m_())})]))]),KS=Q4([m_(),u2({name:m_(),email:e_(m_()),url:e_(m_())})]),K56=Q4([m_(),u2({type:m_(),url:m_(),directory:e_(m_())})]),N3_=u2({name:m_(),version:e_(m_()),onFail:e_(QJ(["ignore","warn","error"]))}),tH=Q4([N3_,m4(N3_)]),z56=u2({cpu:e_(tH),os:e_(tH),libc:e_(tH),runtime:e_(tH),packageManager:e_(tH)}),zS=H0({name:m_(),version:m_(),description:e_(m_()),keywords:e_(m4(m_())),homepage:e_(m_()),bugs:e_(w56),license:e_(m_()),author:e_(KS),contributors:e_(m4(KS)),maintainers:e_(m4(KS)),funding:e_(f56),files:e_(m4(m_())),exports:e_(Q4([aJ(),m_(),m4(m_()),L4(m_(),_q())])),type:e_(QJ(["module","commonjs"])),main:e_(m_()),browser:e_(Q4([m_(),L4(m_(),Q4([m_(),W$()]))])),bin:e_(Q4([m_(),L4(m_(),m_())])),man:e_(Q4([m_(),m4(m_())])),directories:e_(L4(m_(),m_())),repository:e_(K56),scripts:e_(L4(m_(),m_())),config:e_(L4(m_(),_q())),dependencies:e_(L4(m_(),m_())),devDependencies:e_(L4(m_(),m_())),peerDependencies:e_(L4(m_(),m_())),peerDependenciesMeta:e_(L4(m_(),u2({optional:W$()}))),bundleDependencies:e_(Q4([W$(),m4(m_())])),bundledDependencies:e_(Q4([W$(),m4(m_())])),optionalDependencies:e_(L4(m_(),m_())),overrides:e_(L4(m_(),_q())),engines:e_(L4(m_(),m_())),os:e_(m4(m_())),cpu:e_(m4(m_())),libc:e_(m_()),devEngines:e_(z56),private:e_(W$()),publishConfig:e_(L4(m_(),_q())),workspaces:e_(m4(m_())),deprecated:e_(m_()),module:e_(m_()),types:e_(m_()),typings:e_(m_()),typesVersions:e_(L4(m_(),L4(m_(),m4(m_())))),packageManager:e_(m_()),sideEffects:e_(Q4([W$(),m4(m_())])),imports:e_(L4(m_(),_q()))});var eH=(q,$=[])=>q.name==="up"||$.includes("vim")&&q.name==="k"||$.includes("emacs")&&q.ctrl&&q.name==="p",RX=(q,$=[])=>q.name==="down"||$.includes("vim")&&q.name==="j"||$.includes("emacs")&&q.ctrl&&q.name==="n",PS=(q)=>q.name==="space";var DS=(q)=>"1234567890".includes(q.name),YS=(q)=>q.name==="enter"||q.name==="return";class JS extends Error{name="AbortPromptError";message="Prompt was aborted";constructor(q){super();this.cause=q?.cause}}class HS extends Error{name="CancelPromptError";message="Prompt was canceled"}class IX extends Error{name="ExitPromptError"}class ZS extends Error{name="HookError"}class sH extends Error{name="ValidationError"}import{AsyncResource as J56}from"async_hooks";import{AsyncLocalStorage as P56,AsyncResource as D56}from"async_hooks";var h3_=new P56;function Y56(q){return{rl:q,hooks:[],hooksCleanup:[],hooksEffect:[],index:0,handleChange(){}}}function E3_(q,$){let w=Y56(q);return h3_.run(w,()=>{function f(K){w.handleChange=()=>{w.index=0,K()},w.handleChange()}return $(f)})}function zf(){let q=h3_.getStore();if(!q)throw new ZS("[Inquirer] Hook functions can only be called from within a prompt");return q}function kS(){return zf().rl}function OS(q){let $=(...w)=>{let f=zf(),K=!1,z=f.handleChange;f.handleChange=()=>{K=!0};let P=q(...w);if(K)z();return f.handleChange=z,P};return D56.bind($)}function CP(q){let $=zf(),{index:w}=$,f={get(){return $.hooks[w]},set(z){$.hooks[w]=z},initialized:w in $.hooks},K=q(f);return $.index++,K}function g3_(){zf().handleChange()}var Pf={queue(q){let $=zf(),{index:w}=$;$.hooksEffect.push(()=>{$.hooksCleanup[w]?.();let f=q(kS());if(f!=null&&typeof f!=="function")throw new sH("useEffect return value must be a cleanup function or nothing.");$.hooksCleanup[w]=f})},run(){let q=zf();OS(()=>{q.hooksEffect.forEach(($)=>{$()}),q.hooksEffect.length=0})()},clearAll(){let q=zf();q.hooksCleanup.forEach(($)=>{$?.()}),q.hooksEffect.length=0,q.hooksCleanup.length=0}};function g2(q){return CP(($)=>{let w=J56.bind(function(z){if($.get()!==z)$.set(z),g3_()});if($.initialized)return[$.get(),w];let f=typeof q==="function"?q():q;return $.set(f),[f,w]})}function yX(q,$){CP((w)=>{let f=w.get();if(!Array.isArray(f)||$.some((z,P)=>!Object.is(z,f[P])))Pf.queue(q);w.set($)})}import{styleText as b2}from"util";import h$ from"process";function H56(){if(h$.platform!=="win32")return h$.env.TERM!=="linux";return Boolean(h$.env.WT_SESSION)||Boolean(h$.env.TERMINUS_SUBLIME)||h$.env.ConEmuTask==="{cmd::Cmder}"||h$.env.TERM_PROGRAM==="Terminus-Sublime"||h$.env.TERM_PROGRAM==="vscode"||h$.env.TERM==="xterm-256color"||h$.env.TERM==="alacritty"||h$.env.TERMINAL_EMULATOR==="JetBrains-JediTerm"}var b3_={circleQuestionMark:"(?)",questionMarkPrefix:"(?)",square:"\u2588",squareDarkShade:"\u2593",squareMediumShade:"\u2592",squareLightShade:"\u2591",squareTop:"\u2580",squareBottom:"\u2584",squareLeft:"\u258C",squareRight:"\u2590",squareCenter:"\u25A0",bullet:"\u25CF",dot:"\u2024",ellipsis:"\u2026",pointerSmall:"\u203A",triangleUp:"\u25B2",triangleUpSmall:"\u25B4",triangleDown:"\u25BC",triangleDownSmall:"\u25BE",triangleLeftSmall:"\u25C2",triangleRightSmall:"\u25B8",home:"\u2302",heart:"\u2665",musicNote:"\u266A",musicNoteBeamed:"\u266B",arrowUp:"\u2191",arrowDown:"\u2193",arrowLeft:"\u2190",arrowRight:"\u2192",arrowLeftRight:"\u2194",arrowUpDown:"\u2195",almostEqual:"\u2248",notEqual:"\u2260",lessOrEqual:"\u2264",greaterOrEqual:"\u2265",identical:"\u2261",infinity:"\u221E",subscriptZero:"\u2080",subscriptOne:"\u2081",subscriptTwo:"\u2082",subscriptThree:"\u2083",subscriptFour:"\u2084",subscriptFive:"\u2085",subscriptSix:"\u2086",subscriptSeven:"\u2087",subscriptEight:"\u2088",subscriptNine:"\u2089",oneHalf:"\xBD",oneThird:"\u2153",oneQuarter:"\xBC",oneFifth:"\u2155",oneSixth:"\u2159",oneEighth:"\u215B",twoThirds:"\u2154",twoFifths:"\u2156",threeQuarters:"\xBE",threeFifths:"\u2157",threeEighths:"\u215C",fourFifths:"\u2158",fiveSixths:"\u215A",fiveEighths:"\u215D",sevenEighths:"\u215E",line:"\u2500",lineBold:"\u2501",lineDouble:"\u2550",lineDashed0:"\u2504",lineDashed1:"\u2505",lineDashed2:"\u2508",lineDashed3:"\u2509",lineDashed4:"\u254C",lineDashed5:"\u254D",lineDashed6:"\u2574",lineDashed7:"\u2576",lineDashed8:"\u2578",lineDashed9:"\u257A",lineDashed10:"\u257C",lineDashed11:"\u257E",lineDashed12:"\u2212",lineDashed13:"\u2013",lineDashed14:"\u2010",lineDashed15:"\u2043",lineVertical:"\u2502",lineVerticalBold:"\u2503",lineVerticalDouble:"\u2551",lineVerticalDashed0:"\u2506",lineVerticalDashed1:"\u2507",lineVerticalDashed2:"\u250A",lineVerticalDashed3:"\u250B",lineVerticalDashed4:"\u254E",lineVerticalDashed5:"\u254F",lineVerticalDashed6:"\u2575",lineVerticalDashed7:"\u2577",lineVerticalDashed8:"\u2579",lineVerticalDashed9:"\u257B",lineVerticalDashed10:"\u257D",lineVerticalDashed11:"\u257F",lineDownLeft:"\u2510",lineDownLeftArc:"\u256E",lineDownBoldLeftBold:"\u2513",lineDownBoldLeft:"\u2512",lineDownLeftBold:"\u2511",lineDownDoubleLeftDouble:"\u2557",lineDownDoubleLeft:"\u2556",lineDownLeftDouble:"\u2555",lineDownRight:"\u250C",lineDownRightArc:"\u256D",lineDownBoldRightBold:"\u250F",lineDownBoldRight:"\u250E",lineDownRightBold:"\u250D",lineDownDoubleRightDouble:"\u2554",lineDownDoubleRight:"\u2553",lineDownRightDouble:"\u2552",lineUpLeft:"\u2518",lineUpLeftArc:"\u256F",lineUpBoldLeftBold:"\u251B",lineUpBoldLeft:"\u251A",lineUpLeftBold:"\u2519",lineUpDoubleLeftDouble:"\u255D",lineUpDoubleLeft:"\u255C",lineUpLeftDouble:"\u255B",lineUpRight:"\u2514",lineUpRightArc:"\u2570",lineUpBoldRightBold:"\u2517",lineUpBoldRight:"\u2516",lineUpRightBold:"\u2515",lineUpDoubleRightDouble:"\u255A",lineUpDoubleRight:"\u2559",lineUpRightDouble:"\u2558",lineUpDownLeft:"\u2524",lineUpBoldDownBoldLeftBold:"\u252B",lineUpBoldDownBoldLeft:"\u2528",lineUpDownLeftBold:"\u2525",lineUpBoldDownLeftBold:"\u2529",lineUpDownBoldLeftBold:"\u252A",lineUpDownBoldLeft:"\u2527",lineUpBoldDownLeft:"\u2526",lineUpDoubleDownDoubleLeftDouble:"\u2563",lineUpDoubleDownDoubleLeft:"\u2562",lineUpDownLeftDouble:"\u2561",lineUpDownRight:"\u251C",lineUpBoldDownBoldRightBold:"\u2523",lineUpBoldDownBoldRight:"\u2520",lineUpDownRightBold:"\u251D",lineUpBoldDownRightBold:"\u2521",lineUpDownBoldRightBold:"\u2522",lineUpDownBoldRight:"\u251F",lineUpBoldDownRight:"\u251E",lineUpDoubleDownDoubleRightDouble:"\u2560",lineUpDoubleDownDoubleRight:"\u255F",lineUpDownRightDouble:"\u255E",lineDownLeftRight:"\u252C",lineDownBoldLeftBoldRightBold:"\u2533",lineDownLeftBoldRightBold:"\u252F",lineDownBoldLeftRight:"\u2530",lineDownBoldLeftBoldRight:"\u2531",lineDownBoldLeftRightBold:"\u2532",lineDownLeftRightBold:"\u252E",lineDownLeftBoldRight:"\u252D",lineDownDoubleLeftDoubleRightDouble:"\u2566",lineDownDoubleLeftRight:"\u2565",lineDownLeftDoubleRightDouble:"\u2564",lineUpLeftRight:"\u2534",lineUpBoldLeftBoldRightBold:"\u253B",lineUpLeftBoldRightBold:"\u2537",lineUpBoldLeftRight:"\u2538",lineUpBoldLeftBoldRight:"\u2539",lineUpBoldLeftRightBold:"\u253A",lineUpLeftRightBold:"\u2536",lineUpLeftBoldRight:"\u2535",lineUpDoubleLeftDoubleRightDouble:"\u2569",lineUpDoubleLeftRight:"\u2568",lineUpLeftDoubleRightDouble:"\u2567",lineUpDownLeftRight:"\u253C",lineUpBoldDownBoldLeftBoldRightBold:"\u254B",lineUpDownBoldLeftBoldRightBold:"\u2548",lineUpBoldDownLeftBoldRightBold:"\u2547",lineUpBoldDownBoldLeftRightBold:"\u254A",lineUpBoldDownBoldLeftBoldRight:"\u2549",lineUpBoldDownLeftRight:"\u2540",lineUpDownBoldLeftRight:"\u2541",lineUpDownLeftBoldRight:"\u253D",lineUpDownLeftRightBold:"\u253E",lineUpBoldDownBoldLeftRight:"\u2542",lineUpDownLeftBoldRightBold:"\u253F",lineUpBoldDownLeftBoldRight:"\u2543",lineUpBoldDownLeftRightBold:"\u2544",lineUpDownBoldLeftBoldRight:"\u2545",lineUpDownBoldLeftRightBold:"\u2546",lineUpDoubleDownDoubleLeftDoubleRightDouble:"\u256C",lineUpDoubleDownDoubleLeftRight:"\u256B",lineUpDownLeftDoubleRightDouble:"\u256A",lineCross:"\u2573",lineBackslash:"\u2572",lineSlash:"\u2571"},R3_={tick:"\u2714",info:"\u2139",warning:"\u26A0",cross:"\u2718",squareSmall:"\u25FB",squareSmallFilled:"\u25FC",circle:"\u25EF",circleFilled:"\u25C9",circleDotted:"\u25CC",circleDouble:"\u25CE",circleCircle:"\u24DE",circleCross:"\u24E7",circlePipe:"\u24BE",radioOn:"\u25C9",radioOff:"\u25EF",checkboxOn:"\u2612",checkboxOff:"\u2610",checkboxCircleOn:"\u24E7",checkboxCircleOff:"\u24BE",pointer:"\u276F",triangleUpOutline:"\u25B3",triangleLeft:"\u25C0",triangleRight:"\u25B6",lozenge:"\u25C6",lozengeOutline:"\u25C7",hamburger:"\u2630",smiley:"\u32E1",mustache:"\u0DF4",star:"\u2605",play:"\u25B6",nodejs:"\u2B22",oneSeventh:"\u2150",oneNinth:"\u2151",oneTenth:"\u2152"},Z56={tick:"\u221A",info:"i",warning:"\u203C",cross:"\xD7",squareSmall:"\u25A1",squareSmallFilled:"\u25A0",circle:"( )",circleFilled:"(*)",circleDotted:"( )",circleDouble:"( )",circleCircle:"(\u25CB)",circleCross:"(\xD7)",circlePipe:"(\u2502)",radioOn:"(*)",radioOff:"( )",checkboxOn:"[\xD7]",checkboxOff:"[ ]",checkboxCircleOn:"(\xD7)",checkboxCircleOff:"( )",pointer:">",triangleUpOutline:"\u2206",triangleLeft:"\u25C4",triangleRight:"\u25BA",lozenge:"\u2666",lozengeOutline:"\u25CA",hamburger:"\u2261",smiley:"\u263A",mustache:"\u250C\u2500\u2510",star:"\u2736",play:"\u25BA",nodejs:"\u2666",oneSeventh:"1/7",oneNinth:"1/9",oneTenth:"1/10"},k56={...b3_,...R3_},O56={...b3_,...Z56},W56=H56(),v56=W56?k56:O56,F7=v56,aJ8=Object.entries(R3_);var I3_={prefix:{idle:b2("blue","?"),done:b2("green",F7.tick)},spinner:{interval:80,frames:["\u280B","\u2819","\u2839","\u2838","\u283C","\u2834","\u2826","\u2827","\u2807","\u280F"].map((q)=>b2("yellow",q))},style:{answer:(q)=>b2("cyan",q),message:(q)=>b2("bold",q),error:(q)=>b2("red",`> ${q}`),defaultAnswer:(q)=>b2("dim",`(${q})`),help:(q)=>b2("dim",q),highlight:(q)=>b2("cyan",q),key:(q)=>b2("cyan",b2("bold",`<${q}>`))}};function y3_(q){if(typeof q!=="object"||q===null)return!1;let $=q;while(Object.getPrototypeOf($)!==null)$=Object.getPrototypeOf($);return Object.getPrototypeOf(q)===$}function S3_(...q){let $={};for(let w of q)for(let[f,K]of Object.entries(w)){let z=$[f];$[f]=y3_(z)&&y3_(K)?S3_(z,K):K}return $}function _Z(...q){let $=[I3_,...q.filter((w)=>w!=null)];return S3_(...$)}function WS({status:q="idle",theme:$}){let[w,f]=g2(!1),[K,z]=g2(0),{prefix:P,spinner:D}=_Z($);if(yX(()=>{if(q==="loading"){let J,Z=-1,k=setTimeout(()=>{f(!0),J=setInterval(()=>{Z=Z+1,z(Z%D.frames.length)},D.interval)},300);return()=>{clearTimeout(k),clearInterval(J)}}else f(!1)},[q]),w)return D.frames[K];return typeof P==="string"?P:P[q==="loading"?"idle":q]??P.idle}function vS(q,$){return CP((w)=>{let f=w.get();if(!f||f.dependencies.length!==$.length||f.dependencies.some((K,z)=>K!==$[z])){let K=q();return w.set({value:K,dependencies:$}),K}return f.value})}function SX(q){return g2({current:q})[0]}function TS(q){let $=SX(q);$.current=q,yX((w)=>{let f=!1,K=OS((z,P)=>{if(f)return;$.current(P,w)});return w.input.on("keypress",K),()=>{f=!0,w.input.removeListener("keypress",K)}},[])}var Q3_=z6(u5(),1);var L3_=(()=>{let q=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g;return($)=>{let w=0;q.lastIndex=0;while(q.test($))w+=1;return $.length-w}})(),c3_=(q)=>{return q===12288||q>=65281&&q<=65376||q>=65504&&q<=65510},x3_=(q)=>{return q===8987||q===9001||q>=12272&&q<=12287||q>=12289&&q<=12350||q>=12441&&q<=12543||q>=12549&&q<=12591||q>=12593&&q<=12686||q>=12688&&q<=12771||q>=12783&&q<=12830||q>=12832&&q<=12871||q>=12880&&q<=19903||q>=65040&&q<=65049||q>=65072&&q<=65106||q>=65108&&q<=65126||q>=65128&&q<=65131||q>=127488&&q<=127490||q>=127504&&q<=127547||q>=127552&&q<=127560||q>=131072&&q<=196605||q>=196608&&q<=262141};var j56=/[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]|\u001b\]8;[^;]*;.*?(?:\u0007|\u001b\u005c)/y,G56=/[\x00-\x08\x0A-\x1F\x7F-\x9F]{1,1000}/y,d3_=/(?:(?![\uFF61-\uFF9F\uFF00-\uFFEF])[\p{Script=Han}\p{Script=Hiragana}\p{Script=Katakana}\p{Script=Hangul}\p{Script=Tangut}]){1,1000}/yu,A56=/\t{1,1000}/y,l3_=/[\u{1F1E6}-\u{1F1FF}]{2}|\u{1F3F4}[\u{E0061}-\u{E007A}]{2}[\u{E0030}-\u{E0039}\u{E0061}-\u{E007A}]{1,3}\u{E007F}|(?:\p{Emoji}\uFE0F\u20E3?|\p{Emoji_Modifier_Base}\p{Emoji_Modifier}?|\p{Emoji_Presentation})(?:\u200D(?:\p{Emoji_Modifier_Base}\p{Emoji_Modifier}?|\p{Emoji_Presentation}|\p{Emoji}\uFE0F\u20E3?))*/yu,u56=/(?:[\x20-\x7E\xA0-\xFF](?!\uFE0F)){1,1000}/y,C56=/\p{M}+/gu,V56={limit:1/0,ellipsis:""},r3_=(q,$={},w={})=>{let f=$.limit??1/0,K=$.ellipsis??"",z=$?.ellipsisWidth??(K?r3_(K,V56,w).width:0),P=0,D=w.controlWidth??0,Y=w.tabWidth??8,J=w.emojiWidth??2,Z=2,k=w.regularWidth??1,W=w.wideWidth??2,v=[[u56,k],[j56,0],[G56,D],[A56,Y],[l3_,J],[d3_,W]],X=0,j=0,G=q.length,C=0,N=!1,V=G,E=Math.max(0,f-z),b=0,R=0,S=0,p=0;_:while(!0){if(R>b||j>=G&&j>X){let y=q.slice(b,R)||q.slice(X,j);C=0;for(let a of y.replaceAll(C56,"")){let e=a.codePointAt(0)||0;if(c3_(e))p=2;else if(x3_(e))p=W;else p=k;if(S+p>E)V=Math.min(V,Math.max(b,X)+C);if(S+p>f){N=!0;break _}C+=a.length,S+=p}b=R=0}if(j>=G)break _;for(let y=0,a=v.length;y<a;y++){let[e,Q]=v[y];if(e.lastIndex=j,e.test(q)){if(C=e===d3_?L3_(q.slice(j,e.lastIndex)):e===l3_?1:e.lastIndex-j,p=C*Q,S+p>E)V=Math.min(V,j+Math.floor((E-S)/Q));if(S+p>f){N=!0;break _}S+=p,b=X,R=j,j=X=e.lastIndex;continue _}}j+=1}return{width:N?E:S,index:N?V:G,truncated:N,ellipsed:N&&f>=z}},i3_=r3_;var M56={limit:1/0,ellipsis:"",ellipsisWidth:0},N56=(q,$={})=>{return i3_(q,M56,$).width},o7=N56;var mX="\x1B",F3_="\x9B",h56=39,jS="\x07",o3_="[",E56="]",U3_="m",GS=`${E56}8;;`,p3_=new RegExp(`(?:\\${o3_}(?<code>\\d+)m|\\${GS}(?<uri>.*)${jS})`,"y"),n3_=(q)=>{if(q>=30&&q<=37)return 39;if(q>=90&&q<=97)return 39;if(q>=40&&q<=47)return 49;if(q>=100&&q<=107)return 49;if(q===1||q===2)return 22;if(q===3)return 23;if(q===4)return 24;if(q===7)return 27;if(q===8)return 28;if(q===9)return 29;if(q===0)return 0;return},a3_=(q)=>`${mX}${o3_}${q}${U3_}`,B3_=(q)=>`${mX}${GS}${q}${jS}`,XS=(q,$,w)=>{let f=$[Symbol.iterator](),K=!1,z=!1,P=q.at(-1),D=P===void 0?0:o7(P),Y=f.next(),J=f.next(),Z=0;while(!Y.done){let k=Y.value,W=o7(k);if(D+W<=w)q[q.length-1]+=k;else q.push(k),D=0;if(k===mX||k===F3_)K=!0,z=$.startsWith(GS,Z+1);if(K){if(z){if(k===jS)K=!1,z=!1}else if(k===U3_)K=!1}else if(D+=W,D===w&&!J.done)q.push(""),D=0;Y=J,J=f.next(),Z+=k.length}if(P=q.at(-1),!D&&P!==void 0&&P.length&&q.length>1)q[q.length-2]+=q.pop()},g56=(q)=>{let $=q.split(" "),w=$.length;while(w){if(o7($[w-1]))break;w--}if(w===$.length)return q;return $.slice(0,w).join(" ")+$.slice(w).join("")},b56=(q,$,w={})=>{if(w.trim!==!1&&q.trim()==="")return"";let f="",K,z,P=q.split(" "),D=[""],Y=0;for(let k=0;k<P.length;k++){let W=P[k];if(w.trim!==!1){let X=D.at(-1)??"",j=X.trimStart();if(X.length!==j.length)D[D.length-1]=j,Y=o7(j)}if(k!==0){if(Y>=$&&(w.wordWrap===!1||w.trim===!1))D.push(""),Y=0;if(Y||w.trim===!1)D[D.length-1]+=" ",Y++}let v=o7(W);if(w.hard&&v>$){let X=$-Y,j=1+Math.floor((v-X-1)/$);if(Math.floor((v-1)/$)<j)D.push("");XS(D,W,$),Y=o7(D.at(-1)??"");continue}if(Y+v>$&&Y&&v){if(w.wordWrap===!1&&Y<$){XS(D,W,$),Y=o7(D.at(-1)??"");continue}D.push(""),Y=0}if(Y+v>$&&w.wordWrap===!1){XS(D,W,$),Y=o7(D.at(-1)??"");continue}D[D.length-1]+=W,Y+=v}if(w.trim!==!1)D=D.map((k)=>g56(k));let J=D.join(`
|
|
404
404
|
`),Z=!1;for(let k=0;k<J.length;k++){let W=J[k];if(f+=W,!Z){if(Z=W>="\uD800"&&W<="\uDBFF",Z)continue}else Z=!1;if(W===mX||W===F3_){p3_.lastIndex=k+1;let X=p3_.exec(J)?.groups;if(X?.code!==void 0){let j=Number.parseFloat(X.code);K=j===h56?void 0:j}else if(X?.uri!==void 0)z=X.uri.length===0?void 0:X.uri}if(J[k+1]===`
|
|
405
405
|
`){if(z)f+=B3_("");let v=K?n3_(K):void 0;if(K&&v)f+=a3_(v)}else if(W===`
|
|
406
406
|
`){if(K&&n3_(K))f+=a3_(K);if(z)f+=B3_(z)}}return f},R56=/\r?\n/;function xq(q,$,w){return String(q).normalize().split(R56).map((f)=>b56(f,$,w)).join(`
|