viba-cli 0.7.0 → 0.8.0
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/.next/BUILD_ID +1 -1
- package/.next/build-manifest.json +2 -2
- package/.next/fallback-build-manifest.json +2 -2
- package/.next/prerender-manifest.json +3 -3
- package/.next/server/app/_global-error.html +2 -2
- package/.next/server/app/_global-error.rsc +1 -1
- package/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
- package/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
- package/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
- package/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/.next/server/app/_not-found.html +1 -1
- package/.next/server/app/_not-found.rsc +1 -1
- package/.next/server/app/_not-found.segments/_full.segment.rsc +1 -1
- package/.next/server/app/_not-found.segments/_head.segment.rsc +1 -1
- package/.next/server/app/_not-found.segments/_index.segment.rsc +1 -1
- package/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
- package/.next/server/app/_not-found.segments/_not-found.segment.rsc +1 -1
- package/.next/server/app/_not-found.segments/_tree.segment.rsc +1 -1
- package/.next/server/app/index.html +1 -1
- package/.next/server/app/index.rsc +2 -2
- package/.next/server/app/index.segments/__PAGE__.segment.rsc +2 -2
- package/.next/server/app/index.segments/_full.segment.rsc +2 -2
- package/.next/server/app/index.segments/_head.segment.rsc +1 -1
- package/.next/server/app/index.segments/_index.segment.rsc +1 -1
- package/.next/server/app/index.segments/_tree.segment.rsc +1 -1
- package/.next/server/app/new/page/server-reference-manifest.json +23 -23
- package/.next/server/app/new/page.js +1 -1
- package/.next/server/app/new/page.js.nft.json +1 -1
- package/.next/server/app/new/page_client-reference-manifest.js +1 -1
- package/.next/server/app/page/server-reference-manifest.json +23 -23
- package/.next/server/app/page.js +1 -1
- package/.next/server/app/page.js.nft.json +1 -1
- package/.next/server/app/page_client-reference-manifest.js +1 -1
- package/.next/server/app/session/[sessionId]/page/server-reference-manifest.json +17 -17
- package/.next/server/app/session/[sessionId]/page.js +1 -1
- package/.next/server/app/session/[sessionId]/page.js.nft.json +1 -1
- package/.next/server/app/session/[sessionId]/page_client-reference-manifest.js +1 -1
- package/.next/server/chunks/ssr/[root-of-the-server]__36769160._.js +3 -0
- package/.next/server/chunks/ssr/[root-of-the-server]__36769160._.js.map +1 -0
- package/.next/server/chunks/ssr/[root-of-the-server]__41b2f23a._.js +1 -1
- package/.next/server/chunks/ssr/[root-of-the-server]__41b2f23a._.js.map +1 -1
- package/.next/server/chunks/ssr/{[root-of-the-server]__d050ef76._.js → [root-of-the-server]__528f3aa4._.js} +2 -2
- package/.next/server/chunks/ssr/{[root-of-the-server]__d050ef76._.js.map → [root-of-the-server]__528f3aa4._.js.map} +1 -1
- package/.next/server/chunks/ssr/[root-of-the-server]__8174ed94._.js +1 -1
- package/.next/server/chunks/ssr/[root-of-the-server]__8174ed94._.js.map +1 -1
- package/.next/server/chunks/ssr/{[root-of-the-server]__fedccef4._.js → [root-of-the-server]__f1bfaf02._.js} +2 -2
- package/.next/server/chunks/ssr/{[root-of-the-server]__fedccef4._.js.map → [root-of-the-server]__f1bfaf02._.js.map} +1 -1
- package/.next/server/chunks/ssr/{_eec59082._.js → _3819cc0f._.js} +3 -3
- package/.next/server/chunks/ssr/{_eec59082._.js.map → _3819cc0f._.js.map} +1 -1
- package/.next/server/chunks/ssr/{_10959ad1._.js → _44154301._.js} +2 -2
- package/.next/server/chunks/ssr/{_10959ad1._.js.map → _44154301._.js.map} +1 -1
- package/.next/server/chunks/ssr/{_26ea44d4._.js → _782ca804._.js} +2 -2
- package/.next/server/chunks/ssr/{_26ea44d4._.js.map → _782ca804._.js.map} +1 -1
- package/.next/server/chunks/ssr/src_app_session_[sessionId]_SessionPageClient_tsx_dab490d7._.js +2 -2
- package/.next/server/chunks/ssr/src_app_session_[sessionId]_SessionPageClient_tsx_dab490d7._.js.map +1 -1
- package/.next/server/chunks/ssr/src_components_GitRepoSelector_tsx_05c81afa._.js +1 -1
- package/.next/server/chunks/ssr/src_components_GitRepoSelector_tsx_05c81afa._.js.map +1 -1
- package/.next/server/pages/404.html +1 -1
- package/.next/server/pages/500.html +2 -2
- package/.next/server/server-reference-manifest.js +1 -1
- package/.next/server/server-reference-manifest.json +36 -36
- package/.next/static/chunks/{51412f0d40e61752.js → 6dfe6be0458c7506.js} +3 -3
- package/.next/static/chunks/{e8ae5f3295b07660.js → 800bdfe84e30a5fa.js} +1 -1
- package/.next/static/chunks/{61955dd121e7694e.js → 8cc2a20e51da8dab.js} +2 -2
- package/.next/static/chunks/d57d32332080776c.js +3 -0
- package/.next/static/chunks/{250a6b7dbee6d40a.js → f61d984b4435e61d.js} +2 -2
- package/README.md +2 -2
- package/bin/viba.mjs +30 -23
- package/package.json +1 -1
- package/.next/server/chunks/ssr/[root-of-the-server]__ef9ee460._.js +0 -3
- package/.next/server/chunks/ssr/[root-of-the-server]__ef9ee460._.js.map +0 -1
- package/.next/static/chunks/2e1f57afdfdadc44.js +0 -3
- /package/.next/static/{lmo2PE5qBiau0B18MyHY0 → Xe9W13zKv2qP1o6wN_YEA}/_buildManifest.js +0 -0
- /package/.next/static/{lmo2PE5qBiau0B18MyHY0 → Xe9W13zKv2qP1o6wN_YEA}/_clientMiddlewareManifest.json +0 -0
- /package/.next/static/{lmo2PE5qBiau0B18MyHY0 → Xe9W13zKv2qP1o6wN_YEA}/_ssgManifest.js +0 -0
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,33525,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"warnOnce",{enumerable:!0,get:function(){return i}});let i=e=>{}},35027,e=>{e.v([{name:"Codex",cli:"codex",description:"OpenAI's specialized models for agentic coding and deep reasoning.",models:[{id:"gpt-5.3-codex",label:"GPT-5.3 Codex",description:"Latest frontier agentic coding model."},{id:"gpt-5.2-codex",label:"GPT-5.2 Codex",description:"Frontier agentic coding model."},{id:"gpt-5.1-codex-max",label:"GPT-5.1 Codex Max",description:"Codex-optimized flagship for deep and fast reasoning."},{id:"gpt-5.2",label:"GPT-5.2",description:"Latest frontier model with improvements across knowledge, reasoning and coding"},{id:"gpt-5.1-codex-mini",label:"GPT-5.1 Codex Mini",description:"Optimized for codex. Cheaper, faster, but less capable."}]},{name:"Gemini",cli:"gemini",description:"Google's powerful multimodal models with large context windows.",models:[{id:"gemini-3-pro-preview",label:"Gemini 3 Pro Preview",description:"Google's most capable model for complex reasoning and coding tasks."},{id:"gemini-3-flash-preview",label:"Gemini 3 Flash Preview",description:"Fast and efficient model optimized for speed and low latency."},{id:"gemini-2.5-pro",label:"Gemini 2.5 Pro",description:"High-performance model with excellent reasoning capabilities."},{id:"gemini-2.5-flash",label:"Gemini 2.5 Flash",description:"Streamlined model for quick responses and iterative tasks."},{id:"gemini-2.5-flash-lite",label:"Gemini 2.5 Flash Lite",description:"Optimized for extreme speed and cost efficiency."}]},{name:"Cursor Agent",cli:"agent",description:"Integrated agentic experience powered by Claude and GPT models.",models:[{id:"auto",label:"Auto"},{id:"composer-1.5",label:"Composer 1.5"},{id:"composer-1",label:"Composer 1"},{id:"gpt-5.3-codex",label:"GPT-5.3 Codex"},{id:"gpt-5.3-codex-low",label:"GPT-5.3 Codex Low"},{id:"gpt-5.3-codex-high",label:"GPT-5.3 Codex High"},{id:"gpt-5.3-codex-xhigh",label:"GPT-5.3 Codex Extra High"},{id:"gpt-5.3-codex-fast",label:"GPT-5.3 Codex Fast"},{id:"gpt-5.3-codex-low-fast",label:"GPT-5.3 Codex Low Fast"},{id:"gpt-5.3-codex-high-fast",label:"GPT-5.3 Codex High Fast"},{id:"gpt-5.3-codex-xhigh-fast",label:"GPT-5.3 Codex Extra High Fast"},{id:"gpt-5.2",label:"GPT-5.2"},{id:"gpt-5.2-codex",label:"GPT-5.2 Codex"},{id:"gpt-5.2-codex-high",label:"GPT-5.2 Codex High"},{id:"gpt-5.2-codex-low",label:"GPT-5.2 Codex Low"},{id:"gpt-5.2-codex-xhigh",label:"GPT-5.2 Codex Extra High"},{id:"gpt-5.2-codex-fast",label:"GPT-5.2 Codex Fast"},{id:"gpt-5.2-codex-high-fast",label:"GPT-5.2 Codex High Fast"},{id:"gpt-5.2-codex-low-fast",label:"GPT-5.2 Codex Low Fast"},{id:"gpt-5.2-codex-xhigh-fast",label:"GPT-5.2 Codex Extra High Fast"},{id:"gpt-5.1-codex-max",label:"GPT-5.1 Codex Max"},{id:"gpt-5.1-codex-max-high",label:"GPT-5.1 Codex Max High"},{id:"opus-4.6-thinking",label:"Claude 4.6 Opus (Thinking) (default)"},{id:"sonnet-4.5-thinking",label:"Claude 4.5 Sonnet (Thinking)"},{id:"gpt-5.2-high",label:"GPT-5.2 High"},{id:"opus-4.6",label:"Claude 4.6 Opus"},{id:"opus-4.5",label:"Claude 4.5 Opus"},{id:"opus-4.5-thinking",label:"Claude 4.5 Opus (Thinking)"},{id:"sonnet-4.5",label:"Claude 4.5 Sonnet"},{id:"gpt-5.1-high",label:"GPT-5.1 High"},{id:"gemini-3-pro",label:"Gemini 3 Pro"},{id:"gemini-3-flash",label:"Gemini 3 Flash"},{id:"grok",label:"Grok"}]}])},75254,e=>{"use strict";var t=e.i(71645);let r=(...e)=>e.filter((e,t,r)=>!!e&&""!==e.trim()&&r.indexOf(e)===t).join(" ").trim(),i=e=>{let t=e.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,t,r)=>r?r.toUpperCase():t.toLowerCase());return t.charAt(0).toUpperCase()+t.slice(1)};var n={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};let a=(0,t.forwardRef)(({color:e="currentColor",size:i=24,strokeWidth:a=2,absoluteStrokeWidth:o,className:l="",children:s,iconNode:d,...c},u)=>(0,t.createElement)("svg",{ref:u,...n,width:i,height:i,stroke:e,strokeWidth:o?24*Number(a)/Number(i):a,className:r("lucide",l),...!s&&!(e=>{for(let t in e)if(t.startsWith("aria-")||"role"===t||"title"===t)return!0;return!1})(c)&&{"aria-hidden":"true"},...c},[...d.map(([e,r])=>(0,t.createElement)(e,r)),...Array.isArray(s)?s:[s]])),o=(e,n)=>{let o=(0,t.forwardRef)(({className:o,...l},s)=>(0,t.createElement)(a,{ref:s,iconNode:n,className:r(`lucide-${i(e).replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()}`,`lucide-${e}`,o),...l}));return o.displayName=i(e),o};e.s(["default",()=>o],75254)},55716,7233,e=>{"use strict";var t=e.i(75254);let r=(0,t.default)("git-branch",[["line",{x1:"6",x2:"6",y1:"3",y2:"15",key:"17qcm7"}],["circle",{cx:"18",cy:"6",r:"3",key:"1h7g24"}],["circle",{cx:"6",cy:"18",r:"3",key:"fqmcym"}],["path",{d:"M18 9a9 9 0 0 1-9 9",key:"n2h4wq"}]]);e.s(["GitBranch",()=>r],55716);let i=(0,t.default)("plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);e.s(["Plus",()=>i],7233)},27612,31343,e=>{"use strict";var t=e.i(75254);let r=(0,t.default)("trash-2",[["path",{d:"M10 11v6",key:"nco0om"}],["path",{d:"M14 11v6",key:"outv1u"}],["path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6",key:"miytrc"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",key:"e791ji"}]]);e.s(["Trash2",()=>r],27612);let i=(0,t.default)("play",[["path",{d:"M5 5a2 2 0 0 1 3.008-1.728l11.997 6.998a2 2 0 0 1 .003 3.458l-12 7A2 2 0 0 1 5 19z",key:"10ikf1"}]]);e.s(["Play",()=>i],31343)},95187,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var i={callServer:function(){return a.callServer},createServerReference:function(){return l.createServerReference},findSourceMapURL:function(){return o.findSourceMapURL}};for(var n in i)Object.defineProperty(r,n,{enumerable:!0,get:i[n]});let a=e.r(32120),o=e.r(92245),l=e.r(35326)},72194,e=>{"use strict";var t=e.i(95187);let r=(0,t.createServerReference)("00ab8a0c236ad9d559b78b2f40023323c37ac6bdd1",t.callServer,void 0,t.findSourceMapURL,"getHomeDirectory");e.s(["getHomeDirectory",()=>r])},27025,e=>{"use strict";let t=(0,e.i(75254).default)("folder",[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]]);e.s(["Folder",()=>t],27025)},71689,e=>{"use strict";let t=(0,e.i(75254).default)("arrow-left",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);e.s(["ArrowLeft",()=>t],71689)},81016,e=>{"use strict";function t(e){return e&&e.replace(/\\/g,"/").split("/").filter(Boolean).pop()||""}function r(e){if(!e)return"";let t=e.replace(/\\/g,"/"),r=t.length>1&&t.endsWith("/")?t.slice(0,-1):t,i=r.lastIndexOf("/");return -1===i?e.includes(":")&&e.length<=3?e:".":0===i?"/":e.includes(":")&&2===i?r.substring(0,3):r.substring(0,i)}e.s(["getBaseName",()=>t,"getDirName",()=>r])},32724,e=>{"use strict";var t=e.i(95187);let r=(0,t.createServerReference)("7f9ee07126919f7ff76d3216d51e1391fffaeac277",t.callServer,void 0,t.findSourceMapURL,"startTtydProcess");e.s(["startTtydProcess",()=>r])},43722,e=>{"use strict";var t=e.i(95187);let r=(0,t.createServerReference)("7f7ae33c4eab367d29219887a5215871af15cf74f5",t.callServer,void 0,t.findSourceMapURL,"saveAttachments");e.s(["saveAttachments",()=>r])},74230,21621,e=>{"use strict";var t=e.i(95187);let r=(0,t.createServerReference)("003f179b879bf486bcea4539d064b0df6354894815",t.callServer,void 0,t.findSourceMapURL,"getConfig");e.s(["getConfig",()=>r],74230);let i=(0,t.createServerReference)("40b60c4c60b29ca628a121c12dd5c6c169cb53475f",t.callServer,void 0,t.findSourceMapURL,"updateConfig");e.s(["updateConfig",()=>i],21621)},18566,(e,t,r)=>{t.exports=e.r(76562)},63671,e=>{"use strict";let t="viba:sessions-updated-at",r="viba:sessions-updated";function i(){try{localStorage.setItem(t,new Date().toISOString())}catch{}window.dispatchEvent(new CustomEvent(r))}e.s(["SESSIONS_UPDATED_EVENT",0,r,"SESSIONS_UPDATED_STORAGE_KEY",0,t,"notifySessionsUpdated",()=>i])},88143,(e,t,r)=>{"use strict";function i({widthInt:e,heightInt:t,blurWidth:r,blurHeight:i,blurDataURL:n,objectFit:a}){let o=r?40*r:e,l=i?40*i:t,s=o&&l?`viewBox='0 0 ${o} ${l}'`:"";return`%3Csvg xmlns='http://www.w3.org/2000/svg' ${s}%3E%3Cfilter id='b' color-interpolation-filters='sRGB'%3E%3CfeGaussianBlur stdDeviation='20'/%3E%3CfeColorMatrix values='1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 100 -1' result='s'/%3E%3CfeFlood x='0' y='0' width='100%25' height='100%25'/%3E%3CfeComposite operator='out' in='s'/%3E%3CfeComposite in2='SourceGraphic'/%3E%3CfeGaussianBlur stdDeviation='20'/%3E%3C/filter%3E%3Cimage width='100%25' height='100%25' x='0' y='0' preserveAspectRatio='${s?"none":"contain"===a?"xMidYMid":"cover"===a?"xMidYMid slice":"none"}' style='filter: url(%23b);' href='${n}'/%3E%3C/svg%3E`}Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"getImageBlurSvg",{enumerable:!0,get:function(){return i}})},87690,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var i={VALID_LOADERS:function(){return a},imageConfigDefault:function(){return o}};for(var n in i)Object.defineProperty(r,n,{enumerable:!0,get:i[n]});let a=["default","imgix","cloudinary","akamai","custom"],o={deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[32,48,64,96,128,256,384],path:"/_next/image",loader:"default",loaderFile:"",domains:[],disableStaticImages:!1,minimumCacheTTL:14400,formats:["image/webp"],maximumRedirects:3,maximumResponseBody:5e7,dangerouslyAllowLocalIP:!1,dangerouslyAllowSVG:!1,contentSecurityPolicy:"script-src 'none'; frame-src 'none'; sandbox;",contentDispositionType:"attachment",localPatterns:void 0,remotePatterns:[],qualities:[75],unoptimized:!1}},8927,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"getImgProps",{enumerable:!0,get:function(){return d}}),e.r(33525);let i=e.r(43369),n=e.r(88143),a=e.r(87690),o=["-moz-initial","fill","none","scale-down",void 0];function l(e){return void 0!==e.default}function s(e){return void 0===e?e:"number"==typeof e?Number.isFinite(e)?e:NaN:"string"==typeof e&&/^[0-9]+$/.test(e)?parseInt(e,10):NaN}function d({src:e,sizes:t,unoptimized:r=!1,priority:d=!1,preload:c=!1,loading:u,className:f,quality:p,width:g,height:m,fill:h=!1,style:b,overrideSrc:y,onLoad:v,onLoadingComplete:x,placeholder:w="empty",blurDataURL:P,fetchPriority:_,decoding:C="async",layout:S,objectFit:O,objectPosition:j,lazyBoundary:E,lazyRoot:R,...M},T){var k;let G,z,I,{imgConf:A,showAltText:L,blurComplete:D,defaultLoader:$}=T,F=A||a.imageConfigDefault;if("allSizes"in F)G=F;else{let e=[...F.deviceSizes,...F.imageSizes].sort((e,t)=>e-t),t=F.deviceSizes.sort((e,t)=>e-t),r=F.qualities?.sort((e,t)=>e-t);G={...F,allSizes:e,deviceSizes:t,qualities:r}}if(void 0===$)throw Object.defineProperty(Error("images.loaderFile detected but the file is missing default export.\nRead more: https://nextjs.org/docs/messages/invalid-images-config"),"__NEXT_ERROR_CODE",{value:"E163",enumerable:!1,configurable:!0});let U=M.loader||$;delete M.loader,delete M.srcSet;let N="__next_img_default"in U;if(N){if("custom"===G.loader)throw Object.defineProperty(Error(`Image with src "${e}" is missing "loader" prop.
|
|
2
|
-
Read more: https://nextjs.org/docs/messages/next-image-missing-loader`),"__NEXT_ERROR_CODE",{value:"E252",enumerable:!1,configurable:!0})}else{let e=U;U=t=>{let{config:r,...i}=t;return e(i)}}if(S){"fill"===S&&(h=!0);let e={intrinsic:{maxWidth:"100%",height:"auto"},responsive:{width:"100%",height:"auto"}}[S];e&&(b={...b,...e});let r={responsive:"100vw",fill:"100vw"}[S];r&&!t&&(t=r)}let H="",q=s(g),B=s(m);if((k=e)&&"object"==typeof k&&(l(k)||void 0!==k.src)){let t=l(e)?e.default:e;if(!t.src)throw Object.defineProperty(Error(`An object should only be passed to the image component src parameter if it comes from a static image import. It must include src. Received ${JSON.stringify(t)}`),"__NEXT_ERROR_CODE",{value:"E460",enumerable:!1,configurable:!0});if(!t.height||!t.width)throw Object.defineProperty(Error(`An object should only be passed to the image component src parameter if it comes from a static image import. It must include height and width. Received ${JSON.stringify(t)}`),"__NEXT_ERROR_CODE",{value:"E48",enumerable:!1,configurable:!0});if(z=t.blurWidth,I=t.blurHeight,P=P||t.blurDataURL,H=t.src,!h)if(q||B){if(q&&!B){let e=q/t.width;B=Math.round(t.height*e)}else if(!q&&B){let e=B/t.height;q=Math.round(t.width*e)}}else q=t.width,B=t.height}let W=!d&&!
|
|
3
|
-
Read more: https://nextjs.org/docs/messages/next-image-unconfigured-localpatterns`),"__NEXT_ERROR_CODE",{value:"E871",enumerable:!1,configurable:!0});let o=(0,i.findClosestQuality)(a,e),l=(0,n.getDeploymentId)();return`${e.path}?url=${encodeURIComponent(t)}&w=${r}&q=${o}${t.startsWith("/")&&l?`&dpl=${l}`:""}`}a.__next_img_default=!0;let o=a},18581,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"useMergedRef",{enumerable:!0,get:function(){return n}});let i=e.r(71645);function n(e,t){let r=(0,i.useRef)(null),n=(0,i.useRef)(null);return(0,i.useCallback)(i=>{if(null===i){let e=r.current;e&&(r.current=null,e());let t=n.current;t&&(n.current=null,t())}else e&&(r.current=a(e,i)),t&&(n.current=a(t,i))},[e,t])}function a(e,t){if("function"!=typeof e)return e.current=t,()=>{e.current=null};{let r=e(t);return"function"==typeof r?r:()=>e(null)}}("function"==typeof r.default||"object"==typeof r.default&&null!==r.default)&&void 0===r.default.__esModule&&(Object.defineProperty(r.default,"__esModule",{value:!0}),Object.assign(r.default,r),t.exports=r.default)},5500,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"Image",{enumerable:!0,get:function(){return x}});let i=e.r(55682),n=e.r(90809),a=e.r(43476),o=n._(e.r(71645)),l=i._(e.r(74080)),s=i._(e.r(25633)),d=e.r(8927),
|
|
1
|
+
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,33525,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"warnOnce",{enumerable:!0,get:function(){return i}});let i=e=>{}},35027,e=>{e.v([{name:"Codex",cli:"codex",description:"OpenAI's specialized models for agentic coding and deep reasoning.",models:[{id:"gpt-5.3-codex",label:"GPT-5.3 Codex",description:"Latest frontier agentic coding model."},{id:"gpt-5.2-codex",label:"GPT-5.2 Codex",description:"Frontier agentic coding model."},{id:"gpt-5.1-codex-max",label:"GPT-5.1 Codex Max",description:"Codex-optimized flagship for deep and fast reasoning."},{id:"gpt-5.2",label:"GPT-5.2",description:"Latest frontier model with improvements across knowledge, reasoning and coding"},{id:"gpt-5.1-codex-mini",label:"GPT-5.1 Codex Mini",description:"Optimized for codex. Cheaper, faster, but less capable."}]},{name:"Gemini",cli:"gemini",description:"Google's powerful multimodal models with large context windows.",models:[{id:"gemini-3-pro-preview",label:"Gemini 3 Pro Preview",description:"Google's most capable model for complex reasoning and coding tasks."},{id:"gemini-3-flash-preview",label:"Gemini 3 Flash Preview",description:"Fast and efficient model optimized for speed and low latency."},{id:"gemini-2.5-pro",label:"Gemini 2.5 Pro",description:"High-performance model with excellent reasoning capabilities."},{id:"gemini-2.5-flash",label:"Gemini 2.5 Flash",description:"Streamlined model for quick responses and iterative tasks."},{id:"gemini-2.5-flash-lite",label:"Gemini 2.5 Flash Lite",description:"Optimized for extreme speed and cost efficiency."}]},{name:"Cursor Agent",cli:"agent",description:"Integrated agentic experience powered by Claude and GPT models.",models:[{id:"auto",label:"Auto"},{id:"composer-1.5",label:"Composer 1.5"},{id:"composer-1",label:"Composer 1"},{id:"gpt-5.3-codex",label:"GPT-5.3 Codex"},{id:"gpt-5.3-codex-low",label:"GPT-5.3 Codex Low"},{id:"gpt-5.3-codex-high",label:"GPT-5.3 Codex High"},{id:"gpt-5.3-codex-xhigh",label:"GPT-5.3 Codex Extra High"},{id:"gpt-5.3-codex-fast",label:"GPT-5.3 Codex Fast"},{id:"gpt-5.3-codex-low-fast",label:"GPT-5.3 Codex Low Fast"},{id:"gpt-5.3-codex-high-fast",label:"GPT-5.3 Codex High Fast"},{id:"gpt-5.3-codex-xhigh-fast",label:"GPT-5.3 Codex Extra High Fast"},{id:"gpt-5.2",label:"GPT-5.2"},{id:"gpt-5.2-codex",label:"GPT-5.2 Codex"},{id:"gpt-5.2-codex-high",label:"GPT-5.2 Codex High"},{id:"gpt-5.2-codex-low",label:"GPT-5.2 Codex Low"},{id:"gpt-5.2-codex-xhigh",label:"GPT-5.2 Codex Extra High"},{id:"gpt-5.2-codex-fast",label:"GPT-5.2 Codex Fast"},{id:"gpt-5.2-codex-high-fast",label:"GPT-5.2 Codex High Fast"},{id:"gpt-5.2-codex-low-fast",label:"GPT-5.2 Codex Low Fast"},{id:"gpt-5.2-codex-xhigh-fast",label:"GPT-5.2 Codex Extra High Fast"},{id:"gpt-5.1-codex-max",label:"GPT-5.1 Codex Max"},{id:"gpt-5.1-codex-max-high",label:"GPT-5.1 Codex Max High"},{id:"opus-4.6-thinking",label:"Claude 4.6 Opus (Thinking) (default)"},{id:"sonnet-4.5-thinking",label:"Claude 4.5 Sonnet (Thinking)"},{id:"gpt-5.2-high",label:"GPT-5.2 High"},{id:"opus-4.6",label:"Claude 4.6 Opus"},{id:"opus-4.5",label:"Claude 4.5 Opus"},{id:"opus-4.5-thinking",label:"Claude 4.5 Opus (Thinking)"},{id:"sonnet-4.5",label:"Claude 4.5 Sonnet"},{id:"gpt-5.1-high",label:"GPT-5.1 High"},{id:"gemini-3-pro",label:"Gemini 3 Pro"},{id:"gemini-3-flash",label:"Gemini 3 Flash"},{id:"grok",label:"Grok"}]}])},75254,e=>{"use strict";var t=e.i(71645);let r=(...e)=>e.filter((e,t,r)=>!!e&&""!==e.trim()&&r.indexOf(e)===t).join(" ").trim(),i=e=>{let t=e.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,t,r)=>r?r.toUpperCase():t.toLowerCase());return t.charAt(0).toUpperCase()+t.slice(1)};var n={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};let a=(0,t.forwardRef)(({color:e="currentColor",size:i=24,strokeWidth:a=2,absoluteStrokeWidth:o,className:l="",children:s,iconNode:d,...u},c)=>(0,t.createElement)("svg",{ref:c,...n,width:i,height:i,stroke:e,strokeWidth:o?24*Number(a)/Number(i):a,className:r("lucide",l),...!s&&!(e=>{for(let t in e)if(t.startsWith("aria-")||"role"===t||"title"===t)return!0;return!1})(u)&&{"aria-hidden":"true"},...u},[...d.map(([e,r])=>(0,t.createElement)(e,r)),...Array.isArray(s)?s:[s]])),o=(e,n)=>{let o=(0,t.forwardRef)(({className:o,...l},s)=>(0,t.createElement)(a,{ref:s,iconNode:n,className:r(`lucide-${i(e).replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()}`,`lucide-${e}`,o),...l}));return o.displayName=i(e),o};e.s(["default",()=>o],75254)},55716,7233,e=>{"use strict";var t=e.i(75254);let r=(0,t.default)("git-branch",[["line",{x1:"6",x2:"6",y1:"3",y2:"15",key:"17qcm7"}],["circle",{cx:"18",cy:"6",r:"3",key:"1h7g24"}],["circle",{cx:"6",cy:"18",r:"3",key:"fqmcym"}],["path",{d:"M18 9a9 9 0 0 1-9 9",key:"n2h4wq"}]]);e.s(["GitBranch",()=>r],55716);let i=(0,t.default)("plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);e.s(["Plus",()=>i],7233)},27612,31343,e=>{"use strict";var t=e.i(75254);let r=(0,t.default)("trash-2",[["path",{d:"M10 11v6",key:"nco0om"}],["path",{d:"M14 11v6",key:"outv1u"}],["path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6",key:"miytrc"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",key:"e791ji"}]]);e.s(["Trash2",()=>r],27612);let i=(0,t.default)("play",[["path",{d:"M5 5a2 2 0 0 1 3.008-1.728l11.997 6.998a2 2 0 0 1 .003 3.458l-12 7A2 2 0 0 1 5 19z",key:"10ikf1"}]]);e.s(["Play",()=>i],31343)},95187,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var i={callServer:function(){return a.callServer},createServerReference:function(){return l.createServerReference},findSourceMapURL:function(){return o.findSourceMapURL}};for(var n in i)Object.defineProperty(r,n,{enumerable:!0,get:i[n]});let a=e.r(32120),o=e.r(92245),l=e.r(35326)},8043,e=>{"use strict";var t=e.i(95187);let r=(0,t.createServerReference)("00b2f585aab02de15106087cb132626fb625c0db26",t.callServer,void 0,t.findSourceMapURL,"getHomeDirectory");e.s(["getHomeDirectory",()=>r])},27025,e=>{"use strict";let t=(0,e.i(75254).default)("folder",[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]]);e.s(["Folder",()=>t],27025)},71689,e=>{"use strict";let t=(0,e.i(75254).default)("arrow-left",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);e.s(["ArrowLeft",()=>t],71689)},81016,e=>{"use strict";function t(e){return e&&e.replace(/\\/g,"/").split("/").filter(Boolean).pop()||""}function r(e){if(!e)return"";let t=e.replace(/\\/g,"/"),r=t.length>1&&t.endsWith("/")?t.slice(0,-1):t,i=r.lastIndexOf("/");return -1===i?e.includes(":")&&e.length<=3?e:".":0===i?"/":e.includes(":")&&2===i?r.substring(0,3):r.substring(0,i)}e.s(["getBaseName",()=>t,"getDirName",()=>r])},56382,e=>{"use strict";var t=e.i(95187);let r=(0,t.createServerReference)("7f76c1c5fa2a2a8ac1ef4cd8262e536b2376830e89",t.callServer,void 0,t.findSourceMapURL,"startTtydProcess");e.s(["startTtydProcess",()=>r])},73708,e=>{"use strict";var t=e.i(95187);let r=(0,t.createServerReference)("7ffb2975f419e7c26bdfb7b886d1a926fa4e634448",t.callServer,void 0,t.findSourceMapURL,"saveAttachments");e.s(["saveAttachments",()=>r])},11607,78669,e=>{"use strict";var t=e.i(95187);let r=(0,t.createServerReference)("003408daf503f563bd7702d8eae85f3b1294f2f284",t.callServer,void 0,t.findSourceMapURL,"getConfig");e.s(["getConfig",()=>r],11607);let i=(0,t.createServerReference)("40146ea4475c4e00f7633055de4ed6516650b2e88c",t.callServer,void 0,t.findSourceMapURL,"updateConfig");e.s(["updateConfig",()=>i],78669)},18566,(e,t,r)=>{t.exports=e.r(76562)},63671,e=>{"use strict";let t="viba:sessions-updated-at",r="viba:sessions-updated";function i(){try{localStorage.setItem(t,new Date().toISOString())}catch{}window.dispatchEvent(new CustomEvent(r))}e.s(["SESSIONS_UPDATED_EVENT",0,r,"SESSIONS_UPDATED_STORAGE_KEY",0,t,"notifySessionsUpdated",()=>i])},88143,(e,t,r)=>{"use strict";function i({widthInt:e,heightInt:t,blurWidth:r,blurHeight:i,blurDataURL:n,objectFit:a}){let o=r?40*r:e,l=i?40*i:t,s=o&&l?`viewBox='0 0 ${o} ${l}'`:"";return`%3Csvg xmlns='http://www.w3.org/2000/svg' ${s}%3E%3Cfilter id='b' color-interpolation-filters='sRGB'%3E%3CfeGaussianBlur stdDeviation='20'/%3E%3CfeColorMatrix values='1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 100 -1' result='s'/%3E%3CfeFlood x='0' y='0' width='100%25' height='100%25'/%3E%3CfeComposite operator='out' in='s'/%3E%3CfeComposite in2='SourceGraphic'/%3E%3CfeGaussianBlur stdDeviation='20'/%3E%3C/filter%3E%3Cimage width='100%25' height='100%25' x='0' y='0' preserveAspectRatio='${s?"none":"contain"===a?"xMidYMid":"cover"===a?"xMidYMid slice":"none"}' style='filter: url(%23b);' href='${n}'/%3E%3C/svg%3E`}Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"getImageBlurSvg",{enumerable:!0,get:function(){return i}})},87690,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var i={VALID_LOADERS:function(){return a},imageConfigDefault:function(){return o}};for(var n in i)Object.defineProperty(r,n,{enumerable:!0,get:i[n]});let a=["default","imgix","cloudinary","akamai","custom"],o={deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[32,48,64,96,128,256,384],path:"/_next/image",loader:"default",loaderFile:"",domains:[],disableStaticImages:!1,minimumCacheTTL:14400,formats:["image/webp"],maximumRedirects:3,maximumResponseBody:5e7,dangerouslyAllowLocalIP:!1,dangerouslyAllowSVG:!1,contentSecurityPolicy:"script-src 'none'; frame-src 'none'; sandbox;",contentDispositionType:"attachment",localPatterns:void 0,remotePatterns:[],qualities:[75],unoptimized:!1}},8927,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"getImgProps",{enumerable:!0,get:function(){return d}}),e.r(33525);let i=e.r(43369),n=e.r(88143),a=e.r(87690),o=["-moz-initial","fill","none","scale-down",void 0];function l(e){return void 0!==e.default}function s(e){return void 0===e?e:"number"==typeof e?Number.isFinite(e)?e:NaN:"string"==typeof e&&/^[0-9]+$/.test(e)?parseInt(e,10):NaN}function d({src:e,sizes:t,unoptimized:r=!1,priority:d=!1,preload:u=!1,loading:c,className:f,quality:p,width:g,height:m,fill:h=!1,style:b,overrideSrc:y,onLoad:v,onLoadingComplete:x,placeholder:w="empty",blurDataURL:P,fetchPriority:_,decoding:C="async",layout:S,objectFit:O,objectPosition:j,lazyBoundary:E,lazyRoot:R,...M},T){var k;let G,z,I,{imgConf:A,showAltText:L,blurComplete:D,defaultLoader:$}=T,F=A||a.imageConfigDefault;if("allSizes"in F)G=F;else{let e=[...F.deviceSizes,...F.imageSizes].sort((e,t)=>e-t),t=F.deviceSizes.sort((e,t)=>e-t),r=F.qualities?.sort((e,t)=>e-t);G={...F,allSizes:e,deviceSizes:t,qualities:r}}if(void 0===$)throw Object.defineProperty(Error("images.loaderFile detected but the file is missing default export.\nRead more: https://nextjs.org/docs/messages/invalid-images-config"),"__NEXT_ERROR_CODE",{value:"E163",enumerable:!1,configurable:!0});let U=M.loader||$;delete M.loader,delete M.srcSet;let N="__next_img_default"in U;if(N){if("custom"===G.loader)throw Object.defineProperty(Error(`Image with src "${e}" is missing "loader" prop.
|
|
2
|
+
Read more: https://nextjs.org/docs/messages/next-image-missing-loader`),"__NEXT_ERROR_CODE",{value:"E252",enumerable:!1,configurable:!0})}else{let e=U;U=t=>{let{config:r,...i}=t;return e(i)}}if(S){"fill"===S&&(h=!0);let e={intrinsic:{maxWidth:"100%",height:"auto"},responsive:{width:"100%",height:"auto"}}[S];e&&(b={...b,...e});let r={responsive:"100vw",fill:"100vw"}[S];r&&!t&&(t=r)}let H="",q=s(g),B=s(m);if((k=e)&&"object"==typeof k&&(l(k)||void 0!==k.src)){let t=l(e)?e.default:e;if(!t.src)throw Object.defineProperty(Error(`An object should only be passed to the image component src parameter if it comes from a static image import. It must include src. Received ${JSON.stringify(t)}`),"__NEXT_ERROR_CODE",{value:"E460",enumerable:!1,configurable:!0});if(!t.height||!t.width)throw Object.defineProperty(Error(`An object should only be passed to the image component src parameter if it comes from a static image import. It must include height and width. Received ${JSON.stringify(t)}`),"__NEXT_ERROR_CODE",{value:"E48",enumerable:!1,configurable:!0});if(z=t.blurWidth,I=t.blurHeight,P=P||t.blurDataURL,H=t.src,!h)if(q||B){if(q&&!B){let e=q/t.width;B=Math.round(t.height*e)}else if(!q&&B){let e=B/t.height;q=Math.round(t.width*e)}}else q=t.width,B=t.height}let W=!d&&!u&&("lazy"===c||void 0===c);(!(e="string"==typeof e?e:H)||e.startsWith("data:")||e.startsWith("blob:"))&&(r=!0,W=!1),G.unoptimized&&(r=!0),N&&!G.dangerouslyAllowSVG&&e.split("?",1)[0].endsWith(".svg")&&(r=!0);let V=s(p),X=Object.assign(h?{position:"absolute",height:"100%",width:"100%",left:0,top:0,right:0,bottom:0,objectFit:O,objectPosition:j}:{},L?{}:{color:"transparent"},b),K=D||"empty"===w?null:"blur"===w?`url("data:image/svg+xml;charset=utf-8,${(0,n.getImageBlurSvg)({widthInt:q,heightInt:B,blurWidth:z,blurHeight:I,blurDataURL:P||"",objectFit:X.objectFit})}")`:`url("${w}")`,Y=o.includes(X.objectFit)?"fill"===X.objectFit?"100% 100%":"cover":X.objectFit,Z=K?{backgroundSize:Y,backgroundPosition:X.objectPosition||"50% 50%",backgroundRepeat:"no-repeat",backgroundImage:K}:{},J=function({config:e,src:t,unoptimized:r,width:n,quality:a,sizes:o,loader:l}){if(r){let e=(0,i.getDeploymentId)();if(t.startsWith("/")&&!t.startsWith("//")&&e){let r=t.includes("?")?"&":"?";t=`${t}${r}dpl=${e}`}return{src:t,srcSet:void 0,sizes:void 0}}let{widths:s,kind:d}=function({deviceSizes:e,allSizes:t},r,i){if(i){let r=/(^|\s)(1?\d?\d)vw/g,n=[];for(let e;e=r.exec(i);)n.push(parseInt(e[2]));if(n.length){let r=.01*Math.min(...n);return{widths:t.filter(t=>t>=e[0]*r),kind:"w"}}return{widths:t,kind:"w"}}return"number"!=typeof r?{widths:e,kind:"w"}:{widths:[...new Set([r,2*r].map(e=>t.find(t=>t>=e)||t[t.length-1]))],kind:"x"}}(e,n,o),u=s.length-1;return{sizes:o||"w"!==d?o:"100vw",srcSet:s.map((r,i)=>`${l({config:e,src:t,quality:a,width:r})} ${"w"===d?r:i+1}${d}`).join(", "),src:l({config:e,src:t,quality:a,width:s[u]})}}({config:G,src:e,unoptimized:r,width:q,quality:V,sizes:t,loader:U}),Q=W?"lazy":c;return{props:{...M,loading:Q,fetchPriority:_,width:q,height:B,decoding:C,className:f,style:{...X,...Z},sizes:J.sizes,srcSet:J.srcSet,src:y||J.src},meta:{unoptimized:r,preload:u||d,placeholder:w,fill:h}}}},98879,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"default",{enumerable:!0,get:function(){return l}});let i=e.r(71645),n="u"<typeof window,a=n?()=>{}:i.useLayoutEffect,o=n?()=>{}:i.useEffect;function l(e){let{headManager:t,reduceComponentsToState:r}=e;function l(){if(t&&t.mountedInstances){let e=i.Children.toArray(Array.from(t.mountedInstances).filter(Boolean));t.updateHead(r(e))}}return n&&(t?.mountedInstances?.add(e.children),l()),a(()=>(t?.mountedInstances?.add(e.children),()=>{t?.mountedInstances?.delete(e.children)})),a(()=>(t&&(t._pendingUpdate=l),()=>{t&&(t._pendingUpdate=l)})),o(()=>(t&&t._pendingUpdate&&(t._pendingUpdate(),t._pendingUpdate=null),()=>{t&&t._pendingUpdate&&(t._pendingUpdate(),t._pendingUpdate=null)})),null}},25633,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var i={default:function(){return m},defaultHead:function(){return c}};for(var n in i)Object.defineProperty(r,n,{enumerable:!0,get:i[n]});let a=e.r(55682),o=e.r(90809),l=e.r(43476),s=o._(e.r(71645)),d=a._(e.r(98879)),u=e.r(42732);function c(){return[(0,l.jsx)("meta",{charSet:"utf-8"},"charset"),(0,l.jsx)("meta",{name:"viewport",content:"width=device-width"},"viewport")]}function f(e,t){return"string"==typeof t||"number"==typeof t?e:t.type===s.default.Fragment?e.concat(s.default.Children.toArray(t.props.children).reduce((e,t)=>"string"==typeof t||"number"==typeof t?e:e.concat(t),[])):e.concat(t)}e.r(33525);let p=["name","httpEquiv","charSet","itemProp"];function g(e){let t,r,i,n;return e.reduce(f,[]).reverse().concat(c().reverse()).filter((t=new Set,r=new Set,i=new Set,n={},e=>{let a=!0,o=!1;if(e.key&&"number"!=typeof e.key&&e.key.indexOf("$")>0){o=!0;let r=e.key.slice(e.key.indexOf("$")+1);t.has(r)?a=!1:t.add(r)}switch(e.type){case"title":case"base":r.has(e.type)?a=!1:r.add(e.type);break;case"meta":for(let t=0,r=p.length;t<r;t++){let r=p[t];if(e.props.hasOwnProperty(r))if("charSet"===r)i.has(r)?a=!1:i.add(r);else{let t=e.props[r],i=n[r]||new Set;("name"!==r||!o)&&i.has(t)?a=!1:(i.add(t),n[r]=i)}}}return a})).reverse().map((e,t)=>{let r=e.key||t;return s.default.cloneElement(e,{key:r})})}let m=function({children:e}){let t=(0,s.useContext)(u.HeadManagerContext);return(0,l.jsx)(d.default,{reduceComponentsToState:g,headManager:t,children:e})};("function"==typeof r.default||"object"==typeof r.default&&null!==r.default)&&void 0===r.default.__esModule&&(Object.defineProperty(r.default,"__esModule",{value:!0}),Object.assign(r.default,r),t.exports=r.default)},18556,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"ImageConfigContext",{enumerable:!0,get:function(){return a}});let i=e.r(55682)._(e.r(71645)),n=e.r(87690),a=i.default.createContext(n.imageConfigDefault)},65856,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"RouterContext",{enumerable:!0,get:function(){return i}});let i=e.r(55682)._(e.r(71645)).default.createContext(null)},70965,(e,t,r)=>{"use strict";function i(e,t){let r=e||75;return t?.qualities?.length?t.qualities.reduce((e,t)=>Math.abs(t-r)<Math.abs(e-r)?t:e,0):r}Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"findClosestQuality",{enumerable:!0,get:function(){return i}})},1948,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"default",{enumerable:!0,get:function(){return o}});let i=e.r(70965),n=e.r(43369);function a({config:e,src:t,width:r,quality:a}){if(t.startsWith("/")&&t.includes("?")&&e.localPatterns?.length===1&&"**"===e.localPatterns[0].pathname&&""===e.localPatterns[0].search)throw Object.defineProperty(Error(`Image with src "${t}" is using a query string which is not configured in images.localPatterns.
|
|
3
|
+
Read more: https://nextjs.org/docs/messages/next-image-unconfigured-localpatterns`),"__NEXT_ERROR_CODE",{value:"E871",enumerable:!1,configurable:!0});let o=(0,i.findClosestQuality)(a,e),l=(0,n.getDeploymentId)();return`${e.path}?url=${encodeURIComponent(t)}&w=${r}&q=${o}${t.startsWith("/")&&l?`&dpl=${l}`:""}`}a.__next_img_default=!0;let o=a},18581,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"useMergedRef",{enumerable:!0,get:function(){return n}});let i=e.r(71645);function n(e,t){let r=(0,i.useRef)(null),n=(0,i.useRef)(null);return(0,i.useCallback)(i=>{if(null===i){let e=r.current;e&&(r.current=null,e());let t=n.current;t&&(n.current=null,t())}else e&&(r.current=a(e,i)),t&&(n.current=a(t,i))},[e,t])}function a(e,t){if("function"!=typeof e)return e.current=t,()=>{e.current=null};{let r=e(t);return"function"==typeof r?r:()=>e(null)}}("function"==typeof r.default||"object"==typeof r.default&&null!==r.default)&&void 0===r.default.__esModule&&(Object.defineProperty(r.default,"__esModule",{value:!0}),Object.assign(r.default,r),t.exports=r.default)},5500,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"Image",{enumerable:!0,get:function(){return x}});let i=e.r(55682),n=e.r(90809),a=e.r(43476),o=n._(e.r(71645)),l=i._(e.r(74080)),s=i._(e.r(25633)),d=e.r(8927),u=e.r(87690),c=e.r(18556);e.r(33525);let f=e.r(65856),p=i._(e.r(1948)),g=e.r(18581),m={deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[32,48,64,96,128,256,384],qualities:[75],path:"/_next/image",loader:"default",dangerouslyAllowSVG:!1,unoptimized:!1};function h(e,t,r,i,n,a,o){let l=e?.src;e&&e["data-loaded-src"]!==l&&(e["data-loaded-src"]=l,("decode"in e?e.decode():Promise.resolve()).catch(()=>{}).then(()=>{if(e.parentElement&&e.isConnected){if("empty"!==t&&n(!0),r?.current){let t=new Event("load");Object.defineProperty(t,"target",{writable:!1,value:e});let i=!1,n=!1;r.current({...t,nativeEvent:t,currentTarget:e,target:e,isDefaultPrevented:()=>i,isPropagationStopped:()=>n,persist:()=>{},preventDefault:()=>{i=!0,t.preventDefault()},stopPropagation:()=>{n=!0,t.stopPropagation()}})}i?.current&&i.current(e)}}))}function b(e){return o.use?{fetchPriority:e}:{fetchpriority:e}}"u"<typeof window&&(globalThis.__NEXT_IMAGE_IMPORTED=!0);let y=(0,o.forwardRef)(({src:e,srcSet:t,sizes:r,height:i,width:n,decoding:l,className:s,style:d,fetchPriority:u,placeholder:c,loading:f,unoptimized:p,fill:m,onLoadRef:y,onLoadingCompleteRef:v,setBlurComplete:x,setShowAltText:w,sizesInput:P,onLoad:_,onError:C,...S},O)=>{let j=(0,o.useCallback)(e=>{e&&(C&&(e.src=e.src),e.complete&&h(e,c,y,v,x,p,P))},[e,c,y,v,x,C,p,P]),E=(0,g.useMergedRef)(O,j);return(0,a.jsx)("img",{...S,...b(u),loading:f,width:n,height:i,decoding:l,"data-nimg":m?"fill":"1",className:s,style:d,sizes:r,srcSet:t,src:e,ref:E,onLoad:e=>{h(e.currentTarget,c,y,v,x,p,P)},onError:e=>{w(!0),"empty"!==c&&x(!0),C&&C(e)}})});function v({isAppRouter:e,imgAttributes:t}){let r={as:"image",imageSrcSet:t.srcSet,imageSizes:t.sizes,crossOrigin:t.crossOrigin,referrerPolicy:t.referrerPolicy,...b(t.fetchPriority)};return e&&l.default.preload?(l.default.preload(t.src,r),null):(0,a.jsx)(s.default,{children:(0,a.jsx)("link",{rel:"preload",href:t.srcSet?void 0:t.src,...r},"__nimg-"+t.src+t.srcSet+t.sizes)})}let x=(0,o.forwardRef)((e,t)=>{let r=(0,o.useContext)(f.RouterContext),i=(0,o.useContext)(c.ImageConfigContext),n=(0,o.useMemo)(()=>{let e=m||i||u.imageConfigDefault,t=[...e.deviceSizes,...e.imageSizes].sort((e,t)=>e-t),r=e.deviceSizes.sort((e,t)=>e-t),n=e.qualities?.sort((e,t)=>e-t);return{...e,allSizes:t,deviceSizes:r,qualities:n,localPatterns:"u"<typeof window?i?.localPatterns:e.localPatterns}},[i]),{onLoad:l,onLoadingComplete:s}=e,g=(0,o.useRef)(l);(0,o.useEffect)(()=>{g.current=l},[l]);let h=(0,o.useRef)(s);(0,o.useEffect)(()=>{h.current=s},[s]);let[b,x]=(0,o.useState)(!1),[w,P]=(0,o.useState)(!1),{props:_,meta:C}=(0,d.getImgProps)(e,{defaultLoader:p.default,imgConf:n,blurComplete:b,showAltText:w});return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(y,{..._,unoptimized:C.unoptimized,placeholder:C.placeholder,fill:C.fill,onLoadRef:g,onLoadingCompleteRef:h,setBlurComplete:x,setShowAltText:P,sizesInput:e.sizes,ref:t}),C.preload?(0,a.jsx)(v,{isAppRouter:!r,imgAttributes:_}):null]})});("function"==typeof r.default||"object"==typeof r.default&&null!==r.default)&&void 0===r.default.__esModule&&(Object.defineProperty(r.default,"__esModule",{value:!0}),Object.assign(r.default,r),t.exports=r.default)},94909,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var i={default:function(){return u},getImageProps:function(){return d}};for(var n in i)Object.defineProperty(r,n,{enumerable:!0,get:i[n]});let a=e.r(55682),o=e.r(8927),l=e.r(5500),s=a._(e.r(1948));function d(e){let{props:t}=(0,o.getImgProps)(e,{defaultLoader:s.default,imgConf:{deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[32,48,64,96,128,256,384],qualities:[75],path:"/_next/image",loader:"default",dangerouslyAllowSVG:!1,unoptimized:!1}});for(let[e,r]of Object.entries(t))void 0===r&&delete t[e];return{props:t}}let u=l.Image},57688,(e,t,r)=>{t.exports=e.r(94909)}]);
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,33525,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"warnOnce",{enumerable:!0,get:function(){return i}});let i=e=>{}},35027,e=>{e.v([{name:"Codex",cli:"codex",description:"OpenAI's specialized models for agentic coding and deep reasoning.",models:[{id:"gpt-5.3-codex",label:"GPT-5.3 Codex",description:"Latest frontier agentic coding model."},{id:"gpt-5.2-codex",label:"GPT-5.2 Codex",description:"Frontier agentic coding model."},{id:"gpt-5.1-codex-max",label:"GPT-5.1 Codex Max",description:"Codex-optimized flagship for deep and fast reasoning."},{id:"gpt-5.2",label:"GPT-5.2",description:"Latest frontier model with improvements across knowledge, reasoning and coding"},{id:"gpt-5.1-codex-mini",label:"GPT-5.1 Codex Mini",description:"Optimized for codex. Cheaper, faster, but less capable."}]},{name:"Gemini",cli:"gemini",description:"Google's powerful multimodal models with large context windows.",models:[{id:"gemini-3-pro-preview",label:"Gemini 3 Pro Preview",description:"Google's most capable model for complex reasoning and coding tasks."},{id:"gemini-3-flash-preview",label:"Gemini 3 Flash Preview",description:"Fast and efficient model optimized for speed and low latency."},{id:"gemini-2.5-pro",label:"Gemini 2.5 Pro",description:"High-performance model with excellent reasoning capabilities."},{id:"gemini-2.5-flash",label:"Gemini 2.5 Flash",description:"Streamlined model for quick responses and iterative tasks."},{id:"gemini-2.5-flash-lite",label:"Gemini 2.5 Flash Lite",description:"Optimized for extreme speed and cost efficiency."}]},{name:"Cursor Agent",cli:"agent",description:"Integrated agentic experience powered by Claude and GPT models.",models:[{id:"auto",label:"Auto"},{id:"composer-1.5",label:"Composer 1.5"},{id:"composer-1",label:"Composer 1"},{id:"gpt-5.3-codex",label:"GPT-5.3 Codex"},{id:"gpt-5.3-codex-low",label:"GPT-5.3 Codex Low"},{id:"gpt-5.3-codex-high",label:"GPT-5.3 Codex High"},{id:"gpt-5.3-codex-xhigh",label:"GPT-5.3 Codex Extra High"},{id:"gpt-5.3-codex-fast",label:"GPT-5.3 Codex Fast"},{id:"gpt-5.3-codex-low-fast",label:"GPT-5.3 Codex Low Fast"},{id:"gpt-5.3-codex-high-fast",label:"GPT-5.3 Codex High Fast"},{id:"gpt-5.3-codex-xhigh-fast",label:"GPT-5.3 Codex Extra High Fast"},{id:"gpt-5.2",label:"GPT-5.2"},{id:"gpt-5.2-codex",label:"GPT-5.2 Codex"},{id:"gpt-5.2-codex-high",label:"GPT-5.2 Codex High"},{id:"gpt-5.2-codex-low",label:"GPT-5.2 Codex Low"},{id:"gpt-5.2-codex-xhigh",label:"GPT-5.2 Codex Extra High"},{id:"gpt-5.2-codex-fast",label:"GPT-5.2 Codex Fast"},{id:"gpt-5.2-codex-high-fast",label:"GPT-5.2 Codex High Fast"},{id:"gpt-5.2-codex-low-fast",label:"GPT-5.2 Codex Low Fast"},{id:"gpt-5.2-codex-xhigh-fast",label:"GPT-5.2 Codex Extra High Fast"},{id:"gpt-5.1-codex-max",label:"GPT-5.1 Codex Max"},{id:"gpt-5.1-codex-max-high",label:"GPT-5.1 Codex Max High"},{id:"opus-4.6-thinking",label:"Claude 4.6 Opus (Thinking) (default)"},{id:"sonnet-4.5-thinking",label:"Claude 4.5 Sonnet (Thinking)"},{id:"gpt-5.2-high",label:"GPT-5.2 High"},{id:"opus-4.6",label:"Claude 4.6 Opus"},{id:"opus-4.5",label:"Claude 4.5 Opus"},{id:"opus-4.5-thinking",label:"Claude 4.5 Opus (Thinking)"},{id:"sonnet-4.5",label:"Claude 4.5 Sonnet"},{id:"gpt-5.1-high",label:"GPT-5.1 High"},{id:"gemini-3-pro",label:"Gemini 3 Pro"},{id:"gemini-3-flash",label:"Gemini 3 Flash"},{id:"grok",label:"Grok"}]}])},88143,(e,t,r)=>{"use strict";function i({widthInt:e,heightInt:t,blurWidth:r,blurHeight:i,blurDataURL:a,objectFit:n}){let o=r?40*r:e,l=i?40*i:t,s=o&&l?`viewBox='0 0 ${o} ${l}'`:"";return`%3Csvg xmlns='http://www.w3.org/2000/svg' ${s}%3E%3Cfilter id='b' color-interpolation-filters='sRGB'%3E%3CfeGaussianBlur stdDeviation='20'/%3E%3CfeColorMatrix values='1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 100 -1' result='s'/%3E%3CfeFlood x='0' y='0' width='100%25' height='100%25'/%3E%3CfeComposite operator='out' in='s'/%3E%3CfeComposite in2='SourceGraphic'/%3E%3CfeGaussianBlur stdDeviation='20'/%3E%3C/filter%3E%3Cimage width='100%25' height='100%25' x='0' y='0' preserveAspectRatio='${s?"none":"contain"===n?"xMidYMid":"cover"===n?"xMidYMid slice":"none"}' style='filter: url(%23b);' href='${a}'/%3E%3C/svg%3E`}Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"getImageBlurSvg",{enumerable:!0,get:function(){return i}})},87690,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var i={VALID_LOADERS:function(){return n},imageConfigDefault:function(){return o}};for(var a in i)Object.defineProperty(r,a,{enumerable:!0,get:i[a]});let n=["default","imgix","cloudinary","akamai","custom"],o={deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[32,48,64,96,128,256,384],path:"/_next/image",loader:"default",loaderFile:"",domains:[],disableStaticImages:!1,minimumCacheTTL:14400,formats:["image/webp"],maximumRedirects:3,maximumResponseBody:5e7,dangerouslyAllowLocalIP:!1,dangerouslyAllowSVG:!1,contentSecurityPolicy:"script-src 'none'; frame-src 'none'; sandbox;",contentDispositionType:"attachment",localPatterns:void 0,remotePatterns:[],qualities:[75],unoptimized:!1}},8927,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"getImgProps",{enumerable:!0,get:function(){return d}}),e.r(33525);let i=e.r(43369),a=e.r(88143),n=e.r(87690),o=["-moz-initial","fill","none","scale-down",void 0];function l(e){return void 0!==e.default}function s(e){return void 0===e?e:"number"==typeof e?Number.isFinite(e)?e:NaN:"string"==typeof e&&/^[0-9]+$/.test(e)?parseInt(e,10):NaN}function d({src:e,sizes:t,unoptimized:r=!1,priority:d=!1,preload:c=!1,loading:u,className:f,quality:p,width:g,height:m,fill:h=!1,style:b,overrideSrc:y,onLoad:v,onLoadingComplete:x,placeholder:w="empty",blurDataURL:P,fetchPriority:_,decoding:C="async",layout:S,objectFit:j,objectPosition:O,lazyBoundary:E,lazyRoot:R,...M},T){var k;let G,z,I,{imgConf:A,showAltText:L,blurComplete:D,defaultLoader:$}=T,N=A||n.imageConfigDefault;if("allSizes"in N)G=N;else{let e=[...N.deviceSizes,...N.imageSizes].sort((e,t)=>e-t),t=N.deviceSizes.sort((e,t)=>e-t),r=N.qualities?.sort((e,t)=>e-t);G={...N,allSizes:e,deviceSizes:t,qualities:r}}if(void 0===$)throw Object.defineProperty(Error("images.loaderFile detected but the file is missing default export.\nRead more: https://nextjs.org/docs/messages/invalid-images-config"),"__NEXT_ERROR_CODE",{value:"E163",enumerable:!1,configurable:!0});let F=M.loader||$;delete M.loader,delete M.srcSet;let U="__next_img_default"in F;if(U){if("custom"===G.loader)throw Object.defineProperty(Error(`Image with src "${e}" is missing "loader" prop.
|
|
2
2
|
Read more: https://nextjs.org/docs/messages/next-image-missing-loader`),"__NEXT_ERROR_CODE",{value:"E252",enumerable:!1,configurable:!0})}else{let e=F;F=t=>{let{config:r,...i}=t;return e(i)}}if(S){"fill"===S&&(h=!0);let e={intrinsic:{maxWidth:"100%",height:"auto"},responsive:{width:"100%",height:"auto"}}[S];e&&(b={...b,...e});let r={responsive:"100vw",fill:"100vw"}[S];r&&!t&&(t=r)}let H="",q=s(g),B=s(m);if((k=e)&&"object"==typeof k&&(l(k)||void 0!==k.src)){let t=l(e)?e.default:e;if(!t.src)throw Object.defineProperty(Error(`An object should only be passed to the image component src parameter if it comes from a static image import. It must include src. Received ${JSON.stringify(t)}`),"__NEXT_ERROR_CODE",{value:"E460",enumerable:!1,configurable:!0});if(!t.height||!t.width)throw Object.defineProperty(Error(`An object should only be passed to the image component src parameter if it comes from a static image import. It must include height and width. Received ${JSON.stringify(t)}`),"__NEXT_ERROR_CODE",{value:"E48",enumerable:!1,configurable:!0});if(z=t.blurWidth,I=t.blurHeight,P=P||t.blurDataURL,H=t.src,!h)if(q||B){if(q&&!B){let e=q/t.width;B=Math.round(t.height*e)}else if(!q&&B){let e=B/t.height;q=Math.round(t.width*e)}}else q=t.width,B=t.height}let W=!d&&!c&&("lazy"===u||void 0===u);(!(e="string"==typeof e?e:H)||e.startsWith("data:")||e.startsWith("blob:"))&&(r=!0,W=!1),G.unoptimized&&(r=!0),U&&!G.dangerouslyAllowSVG&&e.split("?",1)[0].endsWith(".svg")&&(r=!0);let V=s(p),X=Object.assign(h?{position:"absolute",height:"100%",width:"100%",left:0,top:0,right:0,bottom:0,objectFit:j,objectPosition:O}:{},L?{}:{color:"transparent"},b),K=D||"empty"===w?null:"blur"===w?`url("data:image/svg+xml;charset=utf-8,${(0,a.getImageBlurSvg)({widthInt:q,heightInt:B,blurWidth:z,blurHeight:I,blurDataURL:P||"",objectFit:X.objectFit})}")`:`url("${w}")`,Y=o.includes(X.objectFit)?"fill"===X.objectFit?"100% 100%":"cover":X.objectFit,Z=K?{backgroundSize:Y,backgroundPosition:X.objectPosition||"50% 50%",backgroundRepeat:"no-repeat",backgroundImage:K}:{},J=function({config:e,src:t,unoptimized:r,width:a,quality:n,sizes:o,loader:l}){if(r){let e=(0,i.getDeploymentId)();if(t.startsWith("/")&&!t.startsWith("//")&&e){let r=t.includes("?")?"&":"?";t=`${t}${r}dpl=${e}`}return{src:t,srcSet:void 0,sizes:void 0}}let{widths:s,kind:d}=function({deviceSizes:e,allSizes:t},r,i){if(i){let r=/(^|\s)(1?\d?\d)vw/g,a=[];for(let e;e=r.exec(i);)a.push(parseInt(e[2]));if(a.length){let r=.01*Math.min(...a);return{widths:t.filter(t=>t>=e[0]*r),kind:"w"}}return{widths:t,kind:"w"}}return"number"!=typeof r?{widths:e,kind:"w"}:{widths:[...new Set([r,2*r].map(e=>t.find(t=>t>=e)||t[t.length-1]))],kind:"x"}}(e,a,o),c=s.length-1;return{sizes:o||"w"!==d?o:"100vw",srcSet:s.map((r,i)=>`${l({config:e,src:t,quality:n,width:r})} ${"w"===d?r:i+1}${d}`).join(", "),src:l({config:e,src:t,quality:n,width:s[c]})}}({config:G,src:e,unoptimized:r,width:q,quality:V,sizes:t,loader:F}),Q=W?"lazy":u;return{props:{...M,loading:Q,fetchPriority:_,width:q,height:B,decoding:C,className:f,style:{...X,...Z},sizes:J.sizes,srcSet:J.srcSet,src:y||J.src},meta:{unoptimized:r,preload:c||d,placeholder:w,fill:h}}}},98879,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"default",{enumerable:!0,get:function(){return l}});let i=e.r(71645),a="u"<typeof window,n=a?()=>{}:i.useLayoutEffect,o=a?()=>{}:i.useEffect;function l(e){let{headManager:t,reduceComponentsToState:r}=e;function l(){if(t&&t.mountedInstances){let e=i.Children.toArray(Array.from(t.mountedInstances).filter(Boolean));t.updateHead(r(e))}}return a&&(t?.mountedInstances?.add(e.children),l()),n(()=>(t?.mountedInstances?.add(e.children),()=>{t?.mountedInstances?.delete(e.children)})),n(()=>(t&&(t._pendingUpdate=l),()=>{t&&(t._pendingUpdate=l)})),o(()=>(t&&t._pendingUpdate&&(t._pendingUpdate(),t._pendingUpdate=null),()=>{t&&t._pendingUpdate&&(t._pendingUpdate(),t._pendingUpdate=null)})),null}},25633,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var i={default:function(){return m},defaultHead:function(){return u}};for(var a in i)Object.defineProperty(r,a,{enumerable:!0,get:i[a]});let n=e.r(55682),o=e.r(90809),l=e.r(43476),s=o._(e.r(71645)),d=n._(e.r(98879)),c=e.r(42732);function u(){return[(0,l.jsx)("meta",{charSet:"utf-8"},"charset"),(0,l.jsx)("meta",{name:"viewport",content:"width=device-width"},"viewport")]}function f(e,t){return"string"==typeof t||"number"==typeof t?e:t.type===s.default.Fragment?e.concat(s.default.Children.toArray(t.props.children).reduce((e,t)=>"string"==typeof t||"number"==typeof t?e:e.concat(t),[])):e.concat(t)}e.r(33525);let p=["name","httpEquiv","charSet","itemProp"];function g(e){let t,r,i,a;return e.reduce(f,[]).reverse().concat(u().reverse()).filter((t=new Set,r=new Set,i=new Set,a={},e=>{let n=!0,o=!1;if(e.key&&"number"!=typeof e.key&&e.key.indexOf("$")>0){o=!0;let r=e.key.slice(e.key.indexOf("$")+1);t.has(r)?n=!1:t.add(r)}switch(e.type){case"title":case"base":r.has(e.type)?n=!1:r.add(e.type);break;case"meta":for(let t=0,r=p.length;t<r;t++){let r=p[t];if(e.props.hasOwnProperty(r))if("charSet"===r)i.has(r)?n=!1:i.add(r);else{let t=e.props[r],i=a[r]||new Set;("name"!==r||!o)&&i.has(t)?n=!1:(i.add(t),a[r]=i)}}}return n})).reverse().map((e,t)=>{let r=e.key||t;return s.default.cloneElement(e,{key:r})})}let m=function({children:e}){let t=(0,s.useContext)(c.HeadManagerContext);return(0,l.jsx)(d.default,{reduceComponentsToState:g,headManager:t,children:e})};("function"==typeof r.default||"object"==typeof r.default&&null!==r.default)&&void 0===r.default.__esModule&&(Object.defineProperty(r.default,"__esModule",{value:!0}),Object.assign(r.default,r),t.exports=r.default)},18556,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"ImageConfigContext",{enumerable:!0,get:function(){return n}});let i=e.r(55682)._(e.r(71645)),a=e.r(87690),n=i.default.createContext(a.imageConfigDefault)},65856,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"RouterContext",{enumerable:!0,get:function(){return i}});let i=e.r(55682)._(e.r(71645)).default.createContext(null)},70965,(e,t,r)=>{"use strict";function i(e,t){let r=e||75;return t?.qualities?.length?t.qualities.reduce((e,t)=>Math.abs(t-r)<Math.abs(e-r)?t:e,0):r}Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"findClosestQuality",{enumerable:!0,get:function(){return i}})},1948,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"default",{enumerable:!0,get:function(){return o}});let i=e.r(70965),a=e.r(43369);function n({config:e,src:t,width:r,quality:n}){if(t.startsWith("/")&&t.includes("?")&&e.localPatterns?.length===1&&"**"===e.localPatterns[0].pathname&&""===e.localPatterns[0].search)throw Object.defineProperty(Error(`Image with src "${t}" is using a query string which is not configured in images.localPatterns.
|
|
3
|
-
Read more: https://nextjs.org/docs/messages/next-image-unconfigured-localpatterns`),"__NEXT_ERROR_CODE",{value:"E871",enumerable:!1,configurable:!0});let o=(0,i.findClosestQuality)(n,e),l=(0,a.getDeploymentId)();return`${e.path}?url=${encodeURIComponent(t)}&w=${r}&q=${o}${t.startsWith("/")&&l?`&dpl=${l}`:""}`}n.__next_img_default=!0;let o=n},18581,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"useMergedRef",{enumerable:!0,get:function(){return a}});let i=e.r(71645);function a(e,t){let r=(0,i.useRef)(null),a=(0,i.useRef)(null);return(0,i.useCallback)(i=>{if(null===i){let e=r.current;e&&(r.current=null,e());let t=a.current;t&&(a.current=null,t())}else e&&(r.current=n(e,i)),t&&(a.current=n(t,i))},[e,t])}function n(e,t){if("function"!=typeof e)return e.current=t,()=>{e.current=null};{let r=e(t);return"function"==typeof r?r:()=>e(null)}}("function"==typeof r.default||"object"==typeof r.default&&null!==r.default)&&void 0===r.default.__esModule&&(Object.defineProperty(r.default,"__esModule",{value:!0}),Object.assign(r.default,r),t.exports=r.default)},5500,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"Image",{enumerable:!0,get:function(){return x}});let i=e.r(55682),a=e.r(90809),n=e.r(43476),o=a._(e.r(71645)),l=i._(e.r(74080)),s=i._(e.r(25633)),d=e.r(8927),c=e.r(87690),u=e.r(18556);e.r(33525);let f=e.r(65856),p=i._(e.r(1948)),g=e.r(18581),m={deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[32,48,64,96,128,256,384],qualities:[75],path:"/_next/image",loader:"default",dangerouslyAllowSVG:!1,unoptimized:!1};function h(e,t,r,i,a,n,o){let l=e?.src;e&&e["data-loaded-src"]!==l&&(e["data-loaded-src"]=l,("decode"in e?e.decode():Promise.resolve()).catch(()=>{}).then(()=>{if(e.parentElement&&e.isConnected){if("empty"!==t&&a(!0),r?.current){let t=new Event("load");Object.defineProperty(t,"target",{writable:!1,value:e});let i=!1,a=!1;r.current({...t,nativeEvent:t,currentTarget:e,target:e,isDefaultPrevented:()=>i,isPropagationStopped:()=>a,persist:()=>{},preventDefault:()=>{i=!0,t.preventDefault()},stopPropagation:()=>{a=!0,t.stopPropagation()}})}i?.current&&i.current(e)}}))}function b(e){return o.use?{fetchPriority:e}:{fetchpriority:e}}"u"<typeof window&&(globalThis.__NEXT_IMAGE_IMPORTED=!0);let y=(0,o.forwardRef)(({src:e,srcSet:t,sizes:r,height:i,width:a,decoding:l,className:s,style:d,fetchPriority:c,placeholder:u,loading:f,unoptimized:p,fill:m,onLoadRef:y,onLoadingCompleteRef:v,setBlurComplete:x,setShowAltText:w,sizesInput:P,onLoad:_,onError:C,...S},j)=>{let O=(0,o.useCallback)(e=>{e&&(C&&(e.src=e.src),e.complete&&h(e,u,y,v,x,p,P))},[e,u,y,v,x,C,p,P]),E=(0,g.useMergedRef)(j,O);return(0,n.jsx)("img",{...S,...b(c),loading:f,width:a,height:i,decoding:l,"data-nimg":m?"fill":"1",className:s,style:d,sizes:r,srcSet:t,src:e,ref:E,onLoad:e=>{h(e.currentTarget,u,y,v,x,p,P)},onError:e=>{w(!0),"empty"!==u&&x(!0),C&&C(e)}})});function v({isAppRouter:e,imgAttributes:t}){let r={as:"image",imageSrcSet:t.srcSet,imageSizes:t.sizes,crossOrigin:t.crossOrigin,referrerPolicy:t.referrerPolicy,...b(t.fetchPriority)};return e&&l.default.preload?(l.default.preload(t.src,r),null):(0,n.jsx)(s.default,{children:(0,n.jsx)("link",{rel:"preload",href:t.srcSet?void 0:t.src,...r},"__nimg-"+t.src+t.srcSet+t.sizes)})}let x=(0,o.forwardRef)((e,t)=>{let r=(0,o.useContext)(f.RouterContext),i=(0,o.useContext)(u.ImageConfigContext),a=(0,o.useMemo)(()=>{let e=m||i||c.imageConfigDefault,t=[...e.deviceSizes,...e.imageSizes].sort((e,t)=>e-t),r=e.deviceSizes.sort((e,t)=>e-t),a=e.qualities?.sort((e,t)=>e-t);return{...e,allSizes:t,deviceSizes:r,qualities:a,localPatterns:"u"<typeof window?i?.localPatterns:e.localPatterns}},[i]),{onLoad:l,onLoadingComplete:s}=e,g=(0,o.useRef)(l);(0,o.useEffect)(()=>{g.current=l},[l]);let h=(0,o.useRef)(s);(0,o.useEffect)(()=>{h.current=s},[s]);let[b,x]=(0,o.useState)(!1),[w,P]=(0,o.useState)(!1),{props:_,meta:C}=(0,d.getImgProps)(e,{defaultLoader:p.default,imgConf:a,blurComplete:b,showAltText:w});return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(y,{..._,unoptimized:C.unoptimized,placeholder:C.placeholder,fill:C.fill,onLoadRef:g,onLoadingCompleteRef:h,setBlurComplete:x,setShowAltText:P,sizesInput:e.sizes,ref:t}),C.preload?(0,n.jsx)(v,{isAppRouter:!r,imgAttributes:_}):null]})});("function"==typeof r.default||"object"==typeof r.default&&null!==r.default)&&void 0===r.default.__esModule&&(Object.defineProperty(r.default,"__esModule",{value:!0}),Object.assign(r.default,r),t.exports=r.default)},94909,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var i={default:function(){return c},getImageProps:function(){return d}};for(var a in i)Object.defineProperty(r,a,{enumerable:!0,get:i[a]});let n=e.r(55682),o=e.r(8927),l=e.r(5500),s=n._(e.r(1948));function d(e){let{props:t}=(0,o.getImgProps)(e,{defaultLoader:s.default,imgConf:{deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[32,48,64,96,128,256,384],qualities:[75],path:"/_next/image",loader:"default",dangerouslyAllowSVG:!1,unoptimized:!1}});for(let[e,r]of Object.entries(t))void 0===r&&delete t[e];return{props:t}}let c=l.Image},57688,(e,t,r)=>{t.exports=e.r(94909)},75254,e=>{"use strict";var t=e.i(71645);let r=(...e)=>e.filter((e,t,r)=>!!e&&""!==e.trim()&&r.indexOf(e)===t).join(" ").trim(),i=e=>{let t=e.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,t,r)=>r?r.toUpperCase():t.toLowerCase());return t.charAt(0).toUpperCase()+t.slice(1)};var a={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};let n=(0,t.forwardRef)(({color:e="currentColor",size:i=24,strokeWidth:n=2,absoluteStrokeWidth:o,className:l="",children:s,iconNode:d,...c},u)=>(0,t.createElement)("svg",{ref:u,...a,width:i,height:i,stroke:e,strokeWidth:o?24*Number(n)/Number(i):n,className:r("lucide",l),...!s&&!(e=>{for(let t in e)if(t.startsWith("aria-")||"role"===t||"title"===t)return!0;return!1})(c)&&{"aria-hidden":"true"},...c},[...d.map(([e,r])=>(0,t.createElement)(e,r)),...Array.isArray(s)?s:[s]])),o=(e,a)=>{let o=(0,t.forwardRef)(({className:o,...l},s)=>(0,t.createElement)(n,{ref:s,iconNode:a,className:r(`lucide-${i(e).replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()}`,`lucide-${e}`,o),...l}));return o.displayName=i(e),o};e.s(["default",()=>o],75254)},55716,7233,e=>{"use strict";var t=e.i(75254);let r=(0,t.default)("git-branch",[["line",{x1:"6",x2:"6",y1:"3",y2:"15",key:"17qcm7"}],["circle",{cx:"18",cy:"6",r:"3",key:"1h7g24"}],["circle",{cx:"6",cy:"18",r:"3",key:"fqmcym"}],["path",{d:"M18 9a9 9 0 0 1-9 9",key:"n2h4wq"}]]);e.s(["GitBranch",()=>r],55716);let i=(0,t.default)("plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);e.s(["Plus",()=>i],7233)},27612,31343,e=>{"use strict";var t=e.i(75254);let r=(0,t.default)("trash-2",[["path",{d:"M10 11v6",key:"nco0om"}],["path",{d:"M14 11v6",key:"outv1u"}],["path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6",key:"miytrc"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",key:"e791ji"}]]);e.s(["Trash2",()=>r],27612);let i=(0,t.default)("play",[["path",{d:"M5 5a2 2 0 0 1 3.008-1.728l11.997 6.998a2 2 0 0 1 .003 3.458l-12 7A2 2 0 0 1 5 19z",key:"10ikf1"}]]);e.s(["Play",()=>i],31343)},95187,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var i={callServer:function(){return n.callServer},createServerReference:function(){return l.createServerReference},findSourceMapURL:function(){return o.findSourceMapURL}};for(var a in i)Object.defineProperty(r,a,{enumerable:!0,get:i[a]});let n=e.r(32120),o=e.r(92245),l=e.r(35326)},72194,e=>{"use strict";var t=e.i(95187);let r=(0,t.createServerReference)("00ab8a0c236ad9d559b78b2f40023323c37ac6bdd1",t.callServer,void 0,t.findSourceMapURL,"getHomeDirectory");e.s(["getHomeDirectory",()=>r])},27025,e=>{"use strict";let t=(0,e.i(75254).default)("folder",[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]]);e.s(["Folder",()=>t],27025)},71689,e=>{"use strict";let t=(0,e.i(75254).default)("arrow-left",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);e.s(["ArrowLeft",()=>t],71689)},81016,e=>{"use strict";function t(e){return e&&e.replace(/\\/g,"/").split("/").filter(Boolean).pop()||""}function r(e){if(!e)return"";let t=e.replace(/\\/g,"/"),r=t.length>1&&t.endsWith("/")?t.slice(0,-1):t,i=r.lastIndexOf("/");return -1===i?e.includes(":")&&e.length<=3?e:".":0===i?"/":e.includes(":")&&2===i?r.substring(0,3):r.substring(0,i)}e.s(["getBaseName",()=>t,"getDirName",()=>r])},32724,e=>{"use strict";var t=e.i(95187);let r=(0,t.createServerReference)("7f9ee07126919f7ff76d3216d51e1391fffaeac277",t.callServer,void 0,t.findSourceMapURL,"startTtydProcess");e.s(["startTtydProcess",()=>r])},43722,e=>{"use strict";var t=e.i(95187);let r=(0,t.createServerReference)("7f7ae33c4eab367d29219887a5215871af15cf74f5",t.callServer,void 0,t.findSourceMapURL,"saveAttachments");e.s(["saveAttachments",()=>r])},74230,21621,e=>{"use strict";var t=e.i(95187);let r=(0,t.createServerReference)("003f179b879bf486bcea4539d064b0df6354894815",t.callServer,void 0,t.findSourceMapURL,"getConfig");e.s(["getConfig",()=>r],74230);let i=(0,t.createServerReference)("40b60c4c60b29ca628a121c12dd5c6c169cb53475f",t.callServer,void 0,t.findSourceMapURL,"updateConfig");e.s(["updateConfig",()=>i],21621)},18566,(e,t,r)=>{t.exports=e.r(76562)},63671,e=>{"use strict";let t="viba:sessions-updated-at",r="viba:sessions-updated";function i(){try{localStorage.setItem(t,new Date().toISOString())}catch{}window.dispatchEvent(new CustomEvent(r))}e.s(["SESSIONS_UPDATED_EVENT",0,r,"SESSIONS_UPDATED_STORAGE_KEY",0,t,"notifySessionsUpdated",()=>i])},52683,e=>{"use strict";var t=e.i(43476),r=e.i(57688),i=e.i(5951);function a(){return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("a",{href:"https://github.com/m0o0scar/viba",target:"_blank",rel:"noopener noreferrer","aria-label":"Open Viba GitHub repository",className:"fixed top-0 right-0 z-50 h-20 w-20 cursor-pointer border-l border-b border-gray-400 bg-gray-300/95 shadow-sm backdrop-blur-sm transition-colors hover:bg-gray-500/95",style:{clipPath:"polygon(100% 0, 0 0, 100% 100%)"},children:(0,t.jsx)("span",{className:"absolute left-[67%] top-[33%] -translate-x-1/2 -translate-y-1/2",children:(0,t.jsx)(r.default,{src:"/github.png",alt:"GitHub",width:22,height:22,priority:!0,className:"rotate-45"})})}),(0,t.jsx)("main",{className:"flex min-h-screen flex-col items-center justify-center bg-base-100 p-4 md:p-24",children:(0,t.jsx)(i.default,{mode:"home"})})]})}e.s(["default",()=>a])}]);
|
|
3
|
+
Read more: https://nextjs.org/docs/messages/next-image-unconfigured-localpatterns`),"__NEXT_ERROR_CODE",{value:"E871",enumerable:!1,configurable:!0});let o=(0,i.findClosestQuality)(n,e),l=(0,a.getDeploymentId)();return`${e.path}?url=${encodeURIComponent(t)}&w=${r}&q=${o}${t.startsWith("/")&&l?`&dpl=${l}`:""}`}n.__next_img_default=!0;let o=n},18581,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"useMergedRef",{enumerable:!0,get:function(){return a}});let i=e.r(71645);function a(e,t){let r=(0,i.useRef)(null),a=(0,i.useRef)(null);return(0,i.useCallback)(i=>{if(null===i){let e=r.current;e&&(r.current=null,e());let t=a.current;t&&(a.current=null,t())}else e&&(r.current=n(e,i)),t&&(a.current=n(t,i))},[e,t])}function n(e,t){if("function"!=typeof e)return e.current=t,()=>{e.current=null};{let r=e(t);return"function"==typeof r?r:()=>e(null)}}("function"==typeof r.default||"object"==typeof r.default&&null!==r.default)&&void 0===r.default.__esModule&&(Object.defineProperty(r.default,"__esModule",{value:!0}),Object.assign(r.default,r),t.exports=r.default)},5500,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0}),Object.defineProperty(r,"Image",{enumerable:!0,get:function(){return x}});let i=e.r(55682),a=e.r(90809),n=e.r(43476),o=a._(e.r(71645)),l=i._(e.r(74080)),s=i._(e.r(25633)),d=e.r(8927),c=e.r(87690),u=e.r(18556);e.r(33525);let f=e.r(65856),p=i._(e.r(1948)),g=e.r(18581),m={deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[32,48,64,96,128,256,384],qualities:[75],path:"/_next/image",loader:"default",dangerouslyAllowSVG:!1,unoptimized:!1};function h(e,t,r,i,a,n,o){let l=e?.src;e&&e["data-loaded-src"]!==l&&(e["data-loaded-src"]=l,("decode"in e?e.decode():Promise.resolve()).catch(()=>{}).then(()=>{if(e.parentElement&&e.isConnected){if("empty"!==t&&a(!0),r?.current){let t=new Event("load");Object.defineProperty(t,"target",{writable:!1,value:e});let i=!1,a=!1;r.current({...t,nativeEvent:t,currentTarget:e,target:e,isDefaultPrevented:()=>i,isPropagationStopped:()=>a,persist:()=>{},preventDefault:()=>{i=!0,t.preventDefault()},stopPropagation:()=>{a=!0,t.stopPropagation()}})}i?.current&&i.current(e)}}))}function b(e){return o.use?{fetchPriority:e}:{fetchpriority:e}}"u"<typeof window&&(globalThis.__NEXT_IMAGE_IMPORTED=!0);let y=(0,o.forwardRef)(({src:e,srcSet:t,sizes:r,height:i,width:a,decoding:l,className:s,style:d,fetchPriority:c,placeholder:u,loading:f,unoptimized:p,fill:m,onLoadRef:y,onLoadingCompleteRef:v,setBlurComplete:x,setShowAltText:w,sizesInput:P,onLoad:_,onError:C,...S},j)=>{let O=(0,o.useCallback)(e=>{e&&(C&&(e.src=e.src),e.complete&&h(e,u,y,v,x,p,P))},[e,u,y,v,x,C,p,P]),E=(0,g.useMergedRef)(j,O);return(0,n.jsx)("img",{...S,...b(c),loading:f,width:a,height:i,decoding:l,"data-nimg":m?"fill":"1",className:s,style:d,sizes:r,srcSet:t,src:e,ref:E,onLoad:e=>{h(e.currentTarget,u,y,v,x,p,P)},onError:e=>{w(!0),"empty"!==u&&x(!0),C&&C(e)}})});function v({isAppRouter:e,imgAttributes:t}){let r={as:"image",imageSrcSet:t.srcSet,imageSizes:t.sizes,crossOrigin:t.crossOrigin,referrerPolicy:t.referrerPolicy,...b(t.fetchPriority)};return e&&l.default.preload?(l.default.preload(t.src,r),null):(0,n.jsx)(s.default,{children:(0,n.jsx)("link",{rel:"preload",href:t.srcSet?void 0:t.src,...r},"__nimg-"+t.src+t.srcSet+t.sizes)})}let x=(0,o.forwardRef)((e,t)=>{let r=(0,o.useContext)(f.RouterContext),i=(0,o.useContext)(u.ImageConfigContext),a=(0,o.useMemo)(()=>{let e=m||i||c.imageConfigDefault,t=[...e.deviceSizes,...e.imageSizes].sort((e,t)=>e-t),r=e.deviceSizes.sort((e,t)=>e-t),a=e.qualities?.sort((e,t)=>e-t);return{...e,allSizes:t,deviceSizes:r,qualities:a,localPatterns:"u"<typeof window?i?.localPatterns:e.localPatterns}},[i]),{onLoad:l,onLoadingComplete:s}=e,g=(0,o.useRef)(l);(0,o.useEffect)(()=>{g.current=l},[l]);let h=(0,o.useRef)(s);(0,o.useEffect)(()=>{h.current=s},[s]);let[b,x]=(0,o.useState)(!1),[w,P]=(0,o.useState)(!1),{props:_,meta:C}=(0,d.getImgProps)(e,{defaultLoader:p.default,imgConf:a,blurComplete:b,showAltText:w});return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(y,{..._,unoptimized:C.unoptimized,placeholder:C.placeholder,fill:C.fill,onLoadRef:g,onLoadingCompleteRef:h,setBlurComplete:x,setShowAltText:P,sizesInput:e.sizes,ref:t}),C.preload?(0,n.jsx)(v,{isAppRouter:!r,imgAttributes:_}):null]})});("function"==typeof r.default||"object"==typeof r.default&&null!==r.default)&&void 0===r.default.__esModule&&(Object.defineProperty(r.default,"__esModule",{value:!0}),Object.assign(r.default,r),t.exports=r.default)},94909,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var i={default:function(){return c},getImageProps:function(){return d}};for(var a in i)Object.defineProperty(r,a,{enumerable:!0,get:i[a]});let n=e.r(55682),o=e.r(8927),l=e.r(5500),s=n._(e.r(1948));function d(e){let{props:t}=(0,o.getImgProps)(e,{defaultLoader:s.default,imgConf:{deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[32,48,64,96,128,256,384],qualities:[75],path:"/_next/image",loader:"default",dangerouslyAllowSVG:!1,unoptimized:!1}});for(let[e,r]of Object.entries(t))void 0===r&&delete t[e];return{props:t}}let c=l.Image},57688,(e,t,r)=>{t.exports=e.r(94909)},75254,e=>{"use strict";var t=e.i(71645);let r=(...e)=>e.filter((e,t,r)=>!!e&&""!==e.trim()&&r.indexOf(e)===t).join(" ").trim(),i=e=>{let t=e.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,t,r)=>r?r.toUpperCase():t.toLowerCase());return t.charAt(0).toUpperCase()+t.slice(1)};var a={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};let n=(0,t.forwardRef)(({color:e="currentColor",size:i=24,strokeWidth:n=2,absoluteStrokeWidth:o,className:l="",children:s,iconNode:d,...c},u)=>(0,t.createElement)("svg",{ref:u,...a,width:i,height:i,stroke:e,strokeWidth:o?24*Number(n)/Number(i):n,className:r("lucide",l),...!s&&!(e=>{for(let t in e)if(t.startsWith("aria-")||"role"===t||"title"===t)return!0;return!1})(c)&&{"aria-hidden":"true"},...c},[...d.map(([e,r])=>(0,t.createElement)(e,r)),...Array.isArray(s)?s:[s]])),o=(e,a)=>{let o=(0,t.forwardRef)(({className:o,...l},s)=>(0,t.createElement)(n,{ref:s,iconNode:a,className:r(`lucide-${i(e).replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()}`,`lucide-${e}`,o),...l}));return o.displayName=i(e),o};e.s(["default",()=>o],75254)},55716,7233,e=>{"use strict";var t=e.i(75254);let r=(0,t.default)("git-branch",[["line",{x1:"6",x2:"6",y1:"3",y2:"15",key:"17qcm7"}],["circle",{cx:"18",cy:"6",r:"3",key:"1h7g24"}],["circle",{cx:"6",cy:"18",r:"3",key:"fqmcym"}],["path",{d:"M18 9a9 9 0 0 1-9 9",key:"n2h4wq"}]]);e.s(["GitBranch",()=>r],55716);let i=(0,t.default)("plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);e.s(["Plus",()=>i],7233)},27612,31343,e=>{"use strict";var t=e.i(75254);let r=(0,t.default)("trash-2",[["path",{d:"M10 11v6",key:"nco0om"}],["path",{d:"M14 11v6",key:"outv1u"}],["path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6",key:"miytrc"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",key:"e791ji"}]]);e.s(["Trash2",()=>r],27612);let i=(0,t.default)("play",[["path",{d:"M5 5a2 2 0 0 1 3.008-1.728l11.997 6.998a2 2 0 0 1 .003 3.458l-12 7A2 2 0 0 1 5 19z",key:"10ikf1"}]]);e.s(["Play",()=>i],31343)},95187,(e,t,r)=>{"use strict";Object.defineProperty(r,"__esModule",{value:!0});var i={callServer:function(){return n.callServer},createServerReference:function(){return l.createServerReference},findSourceMapURL:function(){return o.findSourceMapURL}};for(var a in i)Object.defineProperty(r,a,{enumerable:!0,get:i[a]});let n=e.r(32120),o=e.r(92245),l=e.r(35326)},8043,e=>{"use strict";var t=e.i(95187);let r=(0,t.createServerReference)("00b2f585aab02de15106087cb132626fb625c0db26",t.callServer,void 0,t.findSourceMapURL,"getHomeDirectory");e.s(["getHomeDirectory",()=>r])},27025,e=>{"use strict";let t=(0,e.i(75254).default)("folder",[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]]);e.s(["Folder",()=>t],27025)},71689,e=>{"use strict";let t=(0,e.i(75254).default)("arrow-left",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);e.s(["ArrowLeft",()=>t],71689)},81016,e=>{"use strict";function t(e){return e&&e.replace(/\\/g,"/").split("/").filter(Boolean).pop()||""}function r(e){if(!e)return"";let t=e.replace(/\\/g,"/"),r=t.length>1&&t.endsWith("/")?t.slice(0,-1):t,i=r.lastIndexOf("/");return -1===i?e.includes(":")&&e.length<=3?e:".":0===i?"/":e.includes(":")&&2===i?r.substring(0,3):r.substring(0,i)}e.s(["getBaseName",()=>t,"getDirName",()=>r])},56382,e=>{"use strict";var t=e.i(95187);let r=(0,t.createServerReference)("7f76c1c5fa2a2a8ac1ef4cd8262e536b2376830e89",t.callServer,void 0,t.findSourceMapURL,"startTtydProcess");e.s(["startTtydProcess",()=>r])},73708,e=>{"use strict";var t=e.i(95187);let r=(0,t.createServerReference)("7ffb2975f419e7c26bdfb7b886d1a926fa4e634448",t.callServer,void 0,t.findSourceMapURL,"saveAttachments");e.s(["saveAttachments",()=>r])},11607,78669,e=>{"use strict";var t=e.i(95187);let r=(0,t.createServerReference)("003408daf503f563bd7702d8eae85f3b1294f2f284",t.callServer,void 0,t.findSourceMapURL,"getConfig");e.s(["getConfig",()=>r],11607);let i=(0,t.createServerReference)("40146ea4475c4e00f7633055de4ed6516650b2e88c",t.callServer,void 0,t.findSourceMapURL,"updateConfig");e.s(["updateConfig",()=>i],78669)},18566,(e,t,r)=>{t.exports=e.r(76562)},63671,e=>{"use strict";let t="viba:sessions-updated-at",r="viba:sessions-updated";function i(){try{localStorage.setItem(t,new Date().toISOString())}catch{}window.dispatchEvent(new CustomEvent(r))}e.s(["SESSIONS_UPDATED_EVENT",0,r,"SESSIONS_UPDATED_STORAGE_KEY",0,t,"notifySessionsUpdated",()=>i])},52683,e=>{"use strict";var t=e.i(43476),r=e.i(57688),i=e.i(5951);function a(){return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("a",{href:"https://github.com/m0o0scar/viba",target:"_blank",rel:"noopener noreferrer","aria-label":"Open Viba GitHub repository",className:"fixed top-0 right-0 z-50 h-20 w-20 cursor-pointer border-l border-b border-gray-400 bg-gray-300/95 shadow-sm backdrop-blur-sm transition-colors hover:bg-gray-500/95",style:{clipPath:"polygon(100% 0, 0 0, 100% 100%)"},children:(0,t.jsx)("span",{className:"absolute left-[67%] top-[33%] -translate-x-1/2 -translate-y-1/2",children:(0,t.jsx)(r.default,{src:"/github.png",alt:"GitHub",width:22,height:22,priority:!0,className:"rotate-45"})})}),(0,t.jsx)("main",{className:"flex min-h-screen flex-col items-center justify-center bg-base-100 p-4 md:p-24",children:(0,t.jsx)(i.default,{mode:"home"})})]})}e.s(["default",()=>a])}]);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,5951,e=>{"use strict";var t=e.i(43476),a=e.i(71645),s=e.i(75254);let r=(0,s.default)("folder-git-2",[["path",{d:"M18 19a5 5 0 0 1-5-5v8",key:"sz5oeg"}],["path",{d:"M9 20H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H20a2 2 0 0 1 2 2v5",key:"1w6njk"}],["circle",{cx:"13",cy:"12",r:"2",key:"1j92g6"}],["circle",{cx:"20",cy:"19",r:"2",key:"1obnsp"}]]);var l=e.i(55716),i=e.i(7233);let n=(0,s.default)("x",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),c=(0,s.default)("chevron-right",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]),o=(0,s.default)("folder-cog",[["path",{d:"M10.3 20H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.98a2 2 0 0 1 1.69.9l.66 1.2A2 2 0 0 0 12 6h8a2 2 0 0 1 2 2v3.3",key:"128dxu"}],["path",{d:"m14.305 19.53.923-.382",key:"3m78fa"}],["path",{d:"m15.228 16.852-.923-.383",key:"npixar"}],["path",{d:"m16.852 15.228-.383-.923",key:"5xggr7"}],["path",{d:"m16.852 20.772-.383.924",key:"dpfhf9"}],["path",{d:"m19.148 15.228.383-.923",key:"1reyyz"}],["path",{d:"m19.53 21.696-.382-.924",key:"1goivc"}],["path",{d:"m20.772 16.852.924-.383",key:"htqkph"}],["path",{d:"m20.772 19.148.924.383",key:"9w9pjp"}],["circle",{cx:"18",cy:"18",r:"3",key:"1xkwt0"}]]),d=(0,s.default)("bot",[["path",{d:"M12 8V4H8",key:"hb8ula"}],["rect",{width:"16",height:"12",x:"4",y:"8",rx:"2",key:"enze0r"}],["path",{d:"M2 14h2",key:"vft8re"}],["path",{d:"M20 14h2",key:"4cs60a"}],["path",{d:"M15 13v2",key:"1xurst"}],["path",{d:"M9 13v2",key:"rq6x2g"}]]),m=(0,s.default)("cpu",[["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M17 20v2",key:"1rnc9c"}],["path",{d:"M17 2v2",key:"11trls"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M2 17h2",key:"7oei6x"}],["path",{d:"M2 7h2",key:"asdhe0"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"M20 17h2",key:"1fpfkl"}],["path",{d:"M20 7h2",key:"1o8tra"}],["path",{d:"M7 20v2",key:"4gnj0m"}],["path",{d:"M7 2v2",key:"1i4yhu"}],["rect",{x:"4",y:"4",width:"16",height:"16",rx:"2",key:"1vbyd7"}],["rect",{x:"8",y:"8",width:"8",height:"8",rx:"1",key:"z9xiuo"}]]);var u=e.i(27612),h=e.i(31343),p=e.i(95187);let x=(0,p.createServerReference)("4047c4346bb861e2383148077a2da70450459e30d3",p.callServer,void 0,p.findSourceMapURL,"checkDirectoryAccessible"),f=(0,p.createServerReference)("4095b399654cd9d1e32df72f6d4d02fcd15eee79fa",p.callServer,void 0,p.findSourceMapURL,"listDirectories");var b=e.i(72194),g=e.i(27025),v=e.i(71689);let y=(0,s.default)("check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);var w=e.i(81016);function j({title:e,initialPath:s,onSelect:r,onCancel:l,checkRepo:i}){let[n,c]=(0,a.useState)(""),[o,d]=(0,a.useState)(""),[m,u]=(0,a.useState)([]),[h,p]=(0,a.useState)(!1),[j,N]=(0,a.useState)(null);(0,a.useEffect)(()=>{let e=!0;return(async()=>{try{let t=await (0,b.getHomeDirectory)();if(!e)return;d(t),c(s||t)}catch(t){if(console.error("Failed to resolve home directory:",t),!e)return;N("Failed to access your home directory."),c(s||"/")}})(),()=>{e=!1}},[s]),(0,a.useEffect)(()=>{if(!n)return;let e=!0;return(async()=>{p(!0),N(null);try{let t=await f(n);if(!e)return;if(0===t.length&&o&&n!==o){let t=await x(n);if(!e)return;if(!t){N(`Could not access "${n}". Showing home directory.`),c(o);return}}let a=t.map(e=>({name:e.name,path:e.path,isDirectory:e.isDirectory,isGitRepo:e.isGitRepo}));u(a)}catch(t){if(console.error(t),!e)return;if(o&&n!==o){N(`Could not access "${n}". Showing home directory.`),c(o);return}u([]),N("Failed to load directory contents")}finally{e&&p(!1)}})(),()=>{e=!1}},[n,o]);let S=async e=>{if(i&&!await i(e)){N("Selected directory is not a valid git repository."),setTimeout(()=>N(null),3e3);return}await r(e)},k=async()=>{await S(n)};return(0,t.jsx)("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/50 backdrop-blur-sm p-4",children:(0,t.jsxs)("div",{className:"bg-base-200 rounded-lg shadow-xl w-full max-w-3xl h-[80vh] flex flex-col",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between p-4 border-b border-base-300",children:[(0,t.jsxs)("h2",{className:"text-xl font-bold flex items-center gap-2",children:[(0,t.jsx)(g.Folder,{className:"w-5 h-5"}),e||"Browse Local Repository"]}),(0,t.jsx)("button",{onClick:l,className:"btn btn-sm btn-ghost btn-circle",children:"✕"})]}),(0,t.jsxs)("div",{className:"flex items-center gap-2 p-3 bg-base-300",children:[(0,t.jsx)("button",{onClick:()=>{let e=(0,w.getDirName)(n);e&&e!==n&&c(e)},className:"btn btn-sm btn-square btn-ghost",title:"Go Up",disabled:"/"===n||!n,children:(0,t.jsx)(v.ArrowLeft,{className:"w-4 h-4"})}),(0,t.jsx)("div",{className:"flex-1 overflow-x-auto whitespace-nowrap px-2 font-mono text-sm",children:n}),(0,t.jsx)("button",{onClick:k,className:"btn btn-sm btn-primary",children:"Select Current Folder"})]}),(0,t.jsx)("div",{className:"flex-1 overflow-y-auto p-2",children:h?(0,t.jsx)("div",{className:"flex justify-center items-center h-full",children:(0,t.jsx)("span",{className:"loading loading-spinner loading-lg"})}):j?(0,t.jsx)("div",{className:"alert alert-error",children:j}):0===m.length?(0,t.jsx)("div",{className:"text-center text-base-content/50 mt-10",children:"Empty directory"}):(0,t.jsx)("div",{className:"grid grid-cols-1 gap-1",children:m.map(e=>(0,t.jsxs)("div",{className:"flex items-center justify-between p-2 hover:bg-base-100 rounded-md cursor-pointer transition-colors",onClick:()=>{c(e.path)},children:[(0,t.jsxs)("div",{className:"flex items-center gap-3 overflow-hidden",children:[(0,t.jsx)(g.Folder,{className:`w-5 h-5 ${e.isGitRepo?"text-primary":"text-base-content/70"}`}),(0,t.jsx)("span",{className:"truncate",children:e.name}),e.isGitRepo&&(0,t.jsx)("span",{className:"badge badge-xs badge-primary",children:"git"})]}),e.isGitRepo&&(0,t.jsxs)("button",{className:"btn btn-xs btn-primary",onClick:t=>{t.stopPropagation(),S(e.path)},title:`Select ${e.name}`,children:[(0,t.jsx)(y,{className:"w-3 h-3"}),"Select"]})]},e.path))})}),(0,t.jsx)("div",{className:"p-3 border-t border-base-300 text-xs text-base-content/50 text-center",children:'Navigate to a folder and click "Select Current Folder" to choose it.'})]})})}let N=(0,p.createServerReference)("408264874ede3ac6d4c0ea65d1fb31e2ab2e4e74af",p.callServer,void 0,p.findSourceMapURL,"checkIsGitRepo"),S=(0,p.createServerReference)("406172e43e0b5adc6925e32b40d2c4ad9e3e002c62",p.callServer,void 0,p.findSourceMapURL,"getBranches"),k=(0,p.createServerReference)("603744c6a6f1812a186c873768b506ad50f8b2e576",p.callServer,void 0,p.findSourceMapURL,"checkoutBranch");var R=e.i(32724);let C=(0,p.createServerReference)("7fe39b9c4688be51bdc4a0ab57659e0f7959dd3785",p.callServer,void 0,p.findSourceMapURL,"getStartupScript"),M=(0,p.createServerReference)("7f9c2c53945538da0d13943166f06f05a488eef871",p.callServer,void 0,p.findSourceMapURL,"getDefaultDevServerScript"),D=(0,p.createServerReference)("7f669dbdb5ea560b8752062c3594a56189db7ebea9",p.callServer,void 0,p.findSourceMapURL,"listRepoFiles");var L=e.i(43722);let E=(0,p.createServerReference)("405480f3067c9cdbe36de30371cca15ac062ade0d7",p.callServer,void 0,p.findSourceMapURL,"checkAgentCliInstalled"),F=(0,p.createServerReference)("40b315600ca709ca663ce338fb735311774a956de3",p.callServer,void 0,p.findSourceMapURL,"installAgentCli"),P=(0,p.createServerReference)("4011152a20180fbb385f93ebb86bd7fe20b0eb54dc",p.callServer,void 0,p.findSourceMapURL,"resolveRepositoryByName"),$=(0,p.createServerReference)("700469d830d4fde2816e6d39c2de48189f59ed0db3",p.callServer,void 0,p.findSourceMapURL,"copySessionAttachments"),U=(0,p.createServerReference)("700603c4aea3d88f3ba7d04f36928ba19e4cca8958",p.callServer,void 0,p.findSourceMapURL,"createSession"),A=(0,p.createServerReference)("40fabb2453b5f94d32cc70c178973f78bff2624265",p.callServer,void 0,p.findSourceMapURL,"deleteSession"),T=(0,p.createServerReference)("40875a5f93c26e7693d4a9cd7eb51cf74ebb29c847",p.callServer,void 0,p.findSourceMapURL,"getSessionPrefillContext"),I=(0,p.createServerReference)("406a426c7539a88960c1ca8a896edf4361198ca1be",p.callServer,void 0,p.findSourceMapURL,"listSessions"),K=(0,p.createServerReference)("60821ae7d20a7942f7225bf61b2b468e134691322c",p.callServer,void 0,p.findSourceMapURL,"saveSessionLaunchContext");var B=e.i(74230),O=e.i(21621);let G=(0,p.createServerReference)("609adbe6e9c89e41912f5632cdd5cc97288df2d36d",p.callServer,void 0,p.findSourceMapURL,"updateRepoSettings");var z=e.i(18566),V=e.i(63671),H=e.i(57688);let _=e.i(35027).default,q="After each round of conversation, if work is completed and files changed, commit all changes with an appropriate git commit message. The commit message must include a clear title and a detailed body describing what changed and why, not just a title. No need to confirm when creating commits.",W={gemini:"gemini",codex:"codex",agent:"agent"},Y={gemini:"Gemini CLI",codex:"Codex CLI",agent:"Cursor Agent CLI"};function J({mode:e="home",repoPath:s=null,fromRepoName:p=null,prefillFromSession:x=null}){let[f,b]=(0,a.useState)(!1),[g,v]=(0,a.useState)(!1),[y,J]=(0,a.useState)(null),[Q,X]=(0,a.useState)(null),Z=(0,z.useRouter)(),[ee,et]=(0,a.useState)([]),[ea,es]=(0,a.useState)(""),[er,el]=(0,a.useState)([]),[ei,en]=(0,a.useState)([]),[ec,eo]=(0,a.useState)(null),[ed,em]=(0,a.useState)(""),[eu,eh]=(0,a.useState)(""),[ep,ex]=(0,a.useState)(""),[ef,eb]=(0,a.useState)(!1),[eg,ev]=(0,a.useState)(""),[ey,ew]=(0,a.useState)(""),[ej,eN]=(0,a.useState)([]),[eS,ek]=(0,a.useState)([]),[eR,eC]=(0,a.useState)(null),[eM,eD]=(0,a.useState)(!1),[eL,eE]=(0,a.useState)(!1),[eF,eP]=(0,a.useState)(null),[e$,eU]=(0,a.useState)(null),[eA,eT]=(0,a.useState)(!1),[eI,eK]=(0,a.useState)(!1),[eB,eO]=(0,a.useState)(!1),[eG,ez]=(0,a.useState)(null),[eV,eH]=(0,a.useState)(!1),[e_,eq]=(0,a.useState)(null),[eW,eY]=(0,a.useState)(""),[eJ,eQ]=(0,a.useState)(!1),[eX,eZ]=(0,a.useState)(null),e0=(0,a.useRef)(null),e2=ec&&ed?`Show Session Setup (${ec.name} / ${ed})`:"Show Session Setup",e1=(0,a.useCallback)(()=>{(0,V.notifySessionsUpdated)()},[]),e3=(0,a.useCallback)(async(e=Q)=>{try{let[t,a]=await Promise.all([I(),e?I(e):Promise.resolve([])]);en(t),e&&el(a)}catch(e){console.error("Failed to refresh sessions",e)}},[Q]),e4=(0,a.useCallback)(e=>"gemini"===e||"codex"===e||"agent"===e?e:null,[]);(0,a.useEffect)(()=>{(async()=>{try{let[e,t]=await Promise.all([(0,B.getConfig)(),I()]);J(e),en(t)}catch(e){console.error("Failed to load data",e)}finally{eK(!0)}})()},[]),(0,a.useEffect)(()=>{let t=()=>{e3("new"===e?Q:null)},a=e=>{e.key===V.SESSIONS_UPDATED_STORAGE_KEY&&t()},s=()=>{t()},r=()=>{t()};return window.addEventListener("storage",a),window.addEventListener("focus",s),window.addEventListener(V.SESSIONS_UPDATED_EVENT,r),()=>{window.removeEventListener("storage",a),window.removeEventListener("focus",s),window.removeEventListener(V.SESSIONS_UPDATED_EVENT,r)}},[e,e3,Q]);let e6=async e=>{X(e),ty([]),await e7(e),await te(e),await e3(e)},e5=async t=>{eE(!0),eU(null);try{if(!await N(t))return eU("Selected directory is not a valid git repository."),!1;let a=[...(y||await (0,B.getConfig)()).recentRepos];a.includes(t)?a=[t,...a.filter(e=>e!==t)]:a.unshift(t);let s=await (0,O.updateConfig)({recentRepos:a});if(J(s),b(!1),"home"===e)return Z.push(`/new?repo=${encodeURIComponent(t)}`),!0;return await e6(t),!0}catch(e){return console.error(e),eU("Failed to open repository."),!1}finally{eE(!1)}},e8=async t=>{if("new"!==e)return;let a=t.target.value;if(!a||a===Q||!await e5(a))return;let s=new URLSearchParams;s.set("repo",a),x&&s.set("prefillFromSession",x),Z.replace(`/new?${s.toString()}`)};(0,a.useEffect)(()=>{if("new"===e){if(!s){X(null),el([]),et([]),es("");return}s!==Q&&e5(s)}},[e,s,Q]),(0,a.useEffect)(()=>{if("new"!==e)return;if(s)return void eT(!1);let t=p?.trim()??"";if(!t)return void eT(!1);let a=!1;return(async()=>{eU(null),eT(!0);let e=await P(t);if(a)return;if(!e.success){eU(e.error||"Failed to search repositories."),eT(!1);return}if(!e.repoPath){eU(`Could not find a matching repository for "${t}".`),eT(!1);return}let s=new URLSearchParams;s.set("repo",e.repoPath),x&&s.set("prefillFromSession",x),Z.replace(`/new?${s.toString()}`)})(),()=>{a=!0}},[p,e,x,s,Z]),(0,a.useEffect)(()=>{eD(!1),ek([]),eC(null)},[x]),(0,a.useEffect)(()=>{if("new"!==e||!Q||!x||eM)return;let t=!1;return(async()=>{let e=await T(x);if(t)return;if(!e.success||!e.context){e.error&&eU(e.error),eD(!0);return}let a=e.context;if(a.repoPath!==Q)return eD(!0);let s=_.find(e=>e.cli===a.agentProvider);s&&(eo(s),a.model&&("auto"===a.model||s.models.some(e=>e.id===a.model))?em(a.model):em("auto")),ew(a.title||""),ev(a.initialMessage||""),ek(a.attachmentNames||[]),eC(a.sourceSessionName),eb(!0),eD(!0)})(),()=>{t=!0}},[eM,e,x,Q]);let e7=async e=>{let t=y||await (0,B.getConfig)();y||J(t);let a=t.repoSettings[e]||{},s=a.agentProvider,r=a.agentModel,l=a.startupScript,i=a.devServerScript;if(s){let e=_.find(e=>e.cli===s);e?(eo(e),r&&("auto"===r||e.models.some(e=>e.id===r))?em(r):em("auto")):(eo(_[0]),em("auto"))}else eo(_[0]),em("auto");null!=l?eh(l):eh(await C(e)),null!=i?ex(i):ex(await M(e))},e9=async e=>{J(await (0,O.updateConfig)({defaultRoot:e})),v(!1)},te=async e=>{try{let t=await S(e);et(t);let a=((y||await (0,B.getConfig)()).repoSettings[e]||{}).lastBranch,s=t.find(e=>e.current)?.name;if(a&&t.some(e=>e.name===a)){if(es(a),a!==s)try{await k(e,a);let t=await S(e);et(t)}catch(e){console.warn("Could not auto-checkout to remembered branch",e),s&&es(s)}}else s&&es(s)}catch(e){console.error("Failed to load branches",e),eU("Failed to load branches.")}},tt=async e=>{let t=e.target.value;if(Q){eE(!0);try{await k(Q,t),es(t);let e=await G(Q,{lastBranch:t});J(e);let a=await S(Q);et(a)}catch{eU(`Failed to checkout branch ${t}`)}finally{eE(!1)}}},ta=async e=>{let t=e.target.value,a=_.find(e=>e.cli===t);if(a&&Q){eo(a);let e="auto";em(e),J(await G(Q,{agentProvider:a.cli,agentModel:e}))}},ts=async e=>{let t=e.target.value;em(t),Q&&J(await G(Q,{agentModel:t}))},tr=async e=>{eh(e.target.value)},tl=async()=>{Q&&J(await G(Q,{startupScript:eu}))},ti=async e=>{Q&&J(await G(Q,{devServerScript:e}))},tn=async()=>{await ti(ep)},tc=(0,a.useCallback)((e,t)=>{if(e.name&&e.name.trim().length>0)return e;let a=e.type&&e.type.split("/")[1]?.split("+")[0]||"bin";return new File([e],`pasted-file-${Date.now()}-${t+1}.${a}`,{type:e.type,lastModified:e.lastModified||Date.now()})},[]),to=(0,a.useCallback)(e=>{0!==e.length&&eN(t=>{let a=new Map(t.map(e=>[e.name,e]));return e.forEach(e=>{a.set(e.name,e)}),Array.from(a.values())})},[]),[td,tm]=(0,a.useState)(!1),[tu,th]=(0,a.useState)([]),[,tp]=(0,a.useState)(""),[tx,tf]=(0,a.useState)(0),[tb,tg]=(0,a.useState)(0),[tv,ty]=(0,a.useState)([]),tw=async e=>{let t=e.target.value,a=e.target.selectionStart;ev(t),tf(a);let s=t.substring(0,a),r=s.lastIndexOf("@");if(-1!==r){let e=s.substring(r+1);if(!/\s/.test(e)){if(tp(e),tm(!0),Q){var l;let t,a=tv;0===tv.length&&ty(a=await D(Q)),l=a,t=e.toLowerCase(),th([...[...ej.map(e=>e.name),...eS].filter(e=>e.toLowerCase().includes(t)),...l.filter(e=>e.toLowerCase().includes(t)).slice(0,20)]),tg(0)}return}}tm(!1)},tj=e=>{let t=eg.substring(0,tx).lastIndexOf("@");if(-1!==t){let a=eg.substring(0,t),s=eg.substring(tx);ev(`${a}@${e} ${s}`),tm(!1)}};(0,a.useEffect)(()=>{if("new"!==e||!Q)return;let t=e=>{let t=e.clipboardData;if(!t)return;let a=Array.from(t.items).filter(e=>"file"===e.kind).map(e=>e.getAsFile()).filter(e=>null!==e),s=(a.length>0?a:Array.from(t.files)).map((e,t)=>tc(e,t));0!==s.length&&(e.preventDefault(),to(s))};return window.addEventListener("paste",t),()=>{window.removeEventListener("paste",t)}},[to,e,tc,Q]);let tN=async(e,t)=>{if(e.stopPropagation(),y){let e=y.recentRepos.filter(e=>e!==t);J(await (0,O.updateConfig)({recentRepos:e}))}},tS=(0,a.useCallback)(()=>{if(!eV||!eW||!e0.current)return;let e=e0.current,t=(a=0)=>{if(a>40)return void eZ("Timed out while waiting for terminal to initialize.");try{let s=e.contentWindow;if(s?.term){s.term.paste(`${eW}\r`),eQ(!0),eZ(null),s.focus();return}setTimeout(()=>t(a+1),300)}catch(e){console.error("Failed to inject login command into terminal iframe:",e),eZ("Could not access ttyd terminal. Ensure ttyd is running and try again.")}};setTimeout(()=>t(),500)},[eV,eW]),tk=(0,a.useCallback)(async()=>{let e=e4(ec?.cli);if(!e)return!0;let t=await E(e);if(!t.success)return eU(t.error||`Failed to verify ${Y[e]} installation status.`),!1;if(t.installed)return!0;eO(!0),ez(e),eU(null);let a=await F(e);if(eO(!1),ez(null),!a.success)return eU(a.error||`Failed to install ${Y[e]}.`),!1;let s=await (0,R.startTtydProcess)();return s.success?(eq(e),eY(W[e]),eQ(!1),eZ(null),eH(!0)):eU(s.error||"Failed to start ttyd"),!1},[ec?.cli,e4]),tR=async(e={})=>{if(Q){eE(!0),eU(null);try{if(!e.skipAgentSetup&&!await tk())return void eE(!1);let t=ep.trim();!t&&(t=await M(Q))&&ex(t),await tl(),await ti(t);let a=await (0,R.startTtydProcess)();if(!a.success){eU(a.error||"Failed to start ttyd"),eE(!1);return}let s=await U(Q,ea||"main",{agent:ec?.cli||"agent",model:ed||"",title:ey,devServerScript:t||void 0});if(s.success&&s.sessionName&&s.worktreePath&&s.branchName){let e=[],t=[];if(ej.length>0){let t=new FormData;ej.forEach(e=>t.append(e.name,e)),e=await (0,L.saveAttachments)(s.worktreePath,t)}if(eR&&eS.length>0){let e=await $(eR,s.worktreePath,eS);if(!e.success){eU(e.error||"Failed to carry over attachments from source session"),eE(!1);return}t=e.copiedAttachmentNames}let a=Array.from(new Set([...e,...t])),r=eg.trim(),l=r;l&&(l.includes(q)||(l=`${l}
|
|
1
|
+
(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,5951,e=>{"use strict";var t=e.i(43476),a=e.i(71645),s=e.i(75254);let r=(0,s.default)("folder-git-2",[["path",{d:"M18 19a5 5 0 0 1-5-5v8",key:"sz5oeg"}],["path",{d:"M9 20H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H20a2 2 0 0 1 2 2v5",key:"1w6njk"}],["circle",{cx:"13",cy:"12",r:"2",key:"1j92g6"}],["circle",{cx:"20",cy:"19",r:"2",key:"1obnsp"}]]);var l=e.i(55716),i=e.i(7233);let n=(0,s.default)("x",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),c=(0,s.default)("chevron-right",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]),o=(0,s.default)("folder-cog",[["path",{d:"M10.3 20H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.98a2 2 0 0 1 1.69.9l.66 1.2A2 2 0 0 0 12 6h8a2 2 0 0 1 2 2v3.3",key:"128dxu"}],["path",{d:"m14.305 19.53.923-.382",key:"3m78fa"}],["path",{d:"m15.228 16.852-.923-.383",key:"npixar"}],["path",{d:"m16.852 15.228-.383-.923",key:"5xggr7"}],["path",{d:"m16.852 20.772-.383.924",key:"dpfhf9"}],["path",{d:"m19.148 15.228.383-.923",key:"1reyyz"}],["path",{d:"m19.53 21.696-.382-.924",key:"1goivc"}],["path",{d:"m20.772 16.852.924-.383",key:"htqkph"}],["path",{d:"m20.772 19.148.924.383",key:"9w9pjp"}],["circle",{cx:"18",cy:"18",r:"3",key:"1xkwt0"}]]),d=(0,s.default)("bot",[["path",{d:"M12 8V4H8",key:"hb8ula"}],["rect",{width:"16",height:"12",x:"4",y:"8",rx:"2",key:"enze0r"}],["path",{d:"M2 14h2",key:"vft8re"}],["path",{d:"M20 14h2",key:"4cs60a"}],["path",{d:"M15 13v2",key:"1xurst"}],["path",{d:"M9 13v2",key:"rq6x2g"}]]),m=(0,s.default)("cpu",[["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M17 20v2",key:"1rnc9c"}],["path",{d:"M17 2v2",key:"11trls"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M2 17h2",key:"7oei6x"}],["path",{d:"M2 7h2",key:"asdhe0"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"M20 17h2",key:"1fpfkl"}],["path",{d:"M20 7h2",key:"1o8tra"}],["path",{d:"M7 20v2",key:"4gnj0m"}],["path",{d:"M7 2v2",key:"1i4yhu"}],["rect",{x:"4",y:"4",width:"16",height:"16",rx:"2",key:"1vbyd7"}],["rect",{x:"8",y:"8",width:"8",height:"8",rx:"1",key:"z9xiuo"}]]);var u=e.i(27612),h=e.i(31343),p=e.i(95187);let f=(0,p.createServerReference)("40e04cf2a2afa6c7d306984663d4883f00455b36c3",p.callServer,void 0,p.findSourceMapURL,"checkDirectoryAccessible"),x=(0,p.createServerReference)("40ffd9754caf8d0c6f363b1ab1c5e87fcb004ac06d",p.callServer,void 0,p.findSourceMapURL,"listDirectories");var b=e.i(8043),g=e.i(27025),v=e.i(71689);let y=(0,s.default)("check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);var w=e.i(81016);function j({title:e,initialPath:s,onSelect:r,onCancel:l,checkRepo:i}){let[n,c]=(0,a.useState)(""),[o,d]=(0,a.useState)(""),[m,u]=(0,a.useState)([]),[h,p]=(0,a.useState)(!1),[j,N]=(0,a.useState)(null);(0,a.useEffect)(()=>{let e=!0;return(async()=>{try{let t=await (0,b.getHomeDirectory)();if(!e)return;d(t),c(s||t)}catch(t){if(console.error("Failed to resolve home directory:",t),!e)return;N("Failed to access your home directory."),c(s||"/")}})(),()=>{e=!1}},[s]),(0,a.useEffect)(()=>{if(!n)return;let e=!0;return(async()=>{p(!0),N(null);try{let t=await x(n);if(!e)return;if(0===t.length&&o&&n!==o){let t=await f(n);if(!e)return;if(!t){N(`Could not access "${n}". Showing home directory.`),c(o);return}}let a=t.map(e=>({name:e.name,path:e.path,isDirectory:e.isDirectory,isGitRepo:e.isGitRepo}));u(a)}catch(t){if(console.error(t),!e)return;if(o&&n!==o){N(`Could not access "${n}". Showing home directory.`),c(o);return}u([]),N("Failed to load directory contents")}finally{e&&p(!1)}})(),()=>{e=!1}},[n,o]);let S=async e=>{if(i&&!await i(e)){N("Selected directory is not a valid git repository."),setTimeout(()=>N(null),3e3);return}await r(e)},k=async()=>{await S(n)};return(0,t.jsx)("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-black/50 backdrop-blur-sm p-4",children:(0,t.jsxs)("div",{className:"bg-base-200 rounded-lg shadow-xl w-full max-w-3xl h-[80vh] flex flex-col",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between p-4 border-b border-base-300",children:[(0,t.jsxs)("h2",{className:"text-xl font-bold flex items-center gap-2",children:[(0,t.jsx)(g.Folder,{className:"w-5 h-5"}),e||"Browse Local Repository"]}),(0,t.jsx)("button",{onClick:l,className:"btn btn-sm btn-ghost btn-circle",children:"✕"})]}),(0,t.jsxs)("div",{className:"flex items-center gap-2 p-3 bg-base-300",children:[(0,t.jsx)("button",{onClick:()=>{let e=(0,w.getDirName)(n);e&&e!==n&&c(e)},className:"btn btn-sm btn-square btn-ghost",title:"Go Up",disabled:"/"===n||!n,children:(0,t.jsx)(v.ArrowLeft,{className:"w-4 h-4"})}),(0,t.jsx)("div",{className:"flex-1 overflow-x-auto whitespace-nowrap px-2 font-mono text-sm",children:n}),(0,t.jsx)("button",{onClick:k,className:"btn btn-sm btn-primary",children:"Select Current Folder"})]}),(0,t.jsx)("div",{className:"flex-1 overflow-y-auto p-2",children:h?(0,t.jsx)("div",{className:"flex justify-center items-center h-full",children:(0,t.jsx)("span",{className:"loading loading-spinner loading-lg"})}):j?(0,t.jsx)("div",{className:"alert alert-error",children:j}):0===m.length?(0,t.jsx)("div",{className:"text-center text-base-content/50 mt-10",children:"Empty directory"}):(0,t.jsx)("div",{className:"grid grid-cols-1 gap-1",children:m.map(e=>(0,t.jsxs)("div",{className:"flex items-center justify-between p-2 hover:bg-base-100 rounded-md cursor-pointer transition-colors",onClick:()=>{c(e.path)},children:[(0,t.jsxs)("div",{className:"flex items-center gap-3 overflow-hidden",children:[(0,t.jsx)(g.Folder,{className:`w-5 h-5 ${e.isGitRepo?"text-primary":"text-base-content/70"}`}),(0,t.jsx)("span",{className:"truncate",children:e.name}),e.isGitRepo&&(0,t.jsx)("span",{className:"badge badge-xs badge-primary",children:"git"})]}),e.isGitRepo&&(0,t.jsxs)("button",{className:"btn btn-xs btn-primary",onClick:t=>{t.stopPropagation(),S(e.path)},title:`Select ${e.name}`,children:[(0,t.jsx)(y,{className:"w-3 h-3"}),"Select"]})]},e.path))})}),(0,t.jsx)("div",{className:"p-3 border-t border-base-300 text-xs text-base-content/50 text-center",children:'Navigate to a folder and click "Select Current Folder" to choose it.'})]})})}let N=(0,p.createServerReference)("400782a3f97715c98c967e2f396d19d693c2041dad",p.callServer,void 0,p.findSourceMapURL,"checkIsGitRepo"),S=(0,p.createServerReference)("40aa54365d229ff47bf5d53b3e4bfdd21ee82193aa",p.callServer,void 0,p.findSourceMapURL,"getBranches"),k=(0,p.createServerReference)("600382d582a4b4cf6c5b442390aacd42b500f83837",p.callServer,void 0,p.findSourceMapURL,"checkoutBranch");var R=e.i(56382);let C=(0,p.createServerReference)("7f9ed5e1e4229c377fd85f4f7524069b137baa5b87",p.callServer,void 0,p.findSourceMapURL,"getStartupScript"),M=(0,p.createServerReference)("7fc47c9eed1b7933ba384f96662dafa0a9b380bd60",p.callServer,void 0,p.findSourceMapURL,"getDefaultDevServerScript"),D=(0,p.createServerReference)("7fccca6ac13459bb9638e3a08cb7913c923227fc5d",p.callServer,void 0,p.findSourceMapURL,"listRepoFiles");var L=e.i(73708);let E=(0,p.createServerReference)("401b05e1609d7de213bdbd2f05ccb4a50355b81c8c",p.callServer,void 0,p.findSourceMapURL,"checkAgentCliInstalled"),F=(0,p.createServerReference)("40f0690e83fc46a0314a2ec86c258299ccb7c986ab",p.callServer,void 0,p.findSourceMapURL,"installAgentCli"),P=(0,p.createServerReference)("40642b5e03d55c14e450b5d9ed00241038d23516fa",p.callServer,void 0,p.findSourceMapURL,"resolveRepositoryByName"),$=(0,p.createServerReference)("70065a92fb1e241bd84f05b4e3b13affa3d1946c02",p.callServer,void 0,p.findSourceMapURL,"copySessionAttachments"),U=(0,p.createServerReference)("7000ceadf25434a3fee9e40e378cdd319c2d1ea8f1",p.callServer,void 0,p.findSourceMapURL,"createSession"),A=(0,p.createServerReference)("4043d0168426852ee7d28bc7b8672390ce05409e35",p.callServer,void 0,p.findSourceMapURL,"deleteSession"),T=(0,p.createServerReference)("405fb3fbd5af2014f0e0bd23a9c24cea6ad6c2c1ac",p.callServer,void 0,p.findSourceMapURL,"getSessionPrefillContext"),I=(0,p.createServerReference)("40950c45c77b1159158894addef799cbfa1868f05c",p.callServer,void 0,p.findSourceMapURL,"listSessions"),K=(0,p.createServerReference)("60a9dccd117bb437e297b227dac6296c048e8a7a0b",p.callServer,void 0,p.findSourceMapURL,"saveSessionLaunchContext");var B=e.i(11607),O=e.i(78669);let G=(0,p.createServerReference)("6001b7cb18e9eda22799a38833b5ada49df5ca199f",p.callServer,void 0,p.findSourceMapURL,"updateRepoSettings");var z=e.i(18566),V=e.i(63671),H=e.i(57688);let _=e.i(35027).default,q="After each round of conversation, if work is completed and files changed, commit all changes with an appropriate git commit message. The commit message must include a clear title and a detailed body describing what changed and why, not just a title. No need to confirm when creating commits.",W={gemini:"gemini",codex:"codex",agent:"agent"},Y={gemini:"Gemini CLI",codex:"Codex CLI",agent:"Cursor Agent CLI"};function J({mode:e="home",repoPath:s=null,fromRepoName:p=null,prefillFromSession:f=null}){let[x,b]=(0,a.useState)(!1),[g,v]=(0,a.useState)(!1),[y,J]=(0,a.useState)(null),[Q,X]=(0,a.useState)(null),Z=(0,z.useRouter)(),[ee,et]=(0,a.useState)([]),[ea,es]=(0,a.useState)(""),[er,el]=(0,a.useState)([]),[ei,en]=(0,a.useState)([]),[ec,eo]=(0,a.useState)(null),[ed,em]=(0,a.useState)(""),[eu,eh]=(0,a.useState)(""),[ep,ef]=(0,a.useState)(""),[ex,eb]=(0,a.useState)(!1),[eg,ev]=(0,a.useState)(""),[ey,ew]=(0,a.useState)(""),[ej,eN]=(0,a.useState)([]),[eS,ek]=(0,a.useState)([]),[eR,eC]=(0,a.useState)(null),[eM,eD]=(0,a.useState)(!1),[eL,eE]=(0,a.useState)(!1),[eF,eP]=(0,a.useState)(null),[e$,eU]=(0,a.useState)(null),[eA,eT]=(0,a.useState)(!1),[eI,eK]=(0,a.useState)(!1),[eB,eO]=(0,a.useState)(!1),[eG,ez]=(0,a.useState)(null),[eV,eH]=(0,a.useState)(!1),[e_,eq]=(0,a.useState)(null),[eW,eY]=(0,a.useState)(""),[eJ,eQ]=(0,a.useState)(!1),[eX,eZ]=(0,a.useState)(null),e0=(0,a.useRef)(null),e2=ec&&ed?`Show Session Setup (${ec.name} / ${ed})`:"Show Session Setup",e1=(0,a.useCallback)(()=>{(0,V.notifySessionsUpdated)()},[]),e3=(0,a.useCallback)(async(e=Q)=>{try{let[t,a]=await Promise.all([I(),e?I(e):Promise.resolve([])]);en(t),e&&el(a)}catch(e){console.error("Failed to refresh sessions",e)}},[Q]),e4=(0,a.useCallback)(e=>"gemini"===e||"codex"===e||"agent"===e?e:null,[]);(0,a.useEffect)(()=>{(async()=>{try{let[e,t]=await Promise.all([(0,B.getConfig)(),I()]);J(e),en(t)}catch(e){console.error("Failed to load data",e)}finally{eK(!0)}})()},[]),(0,a.useEffect)(()=>{let t=()=>{e3("new"===e?Q:null)},a=e=>{e.key===V.SESSIONS_UPDATED_STORAGE_KEY&&t()},s=()=>{t()},r=()=>{t()};return window.addEventListener("storage",a),window.addEventListener("focus",s),window.addEventListener(V.SESSIONS_UPDATED_EVENT,r),()=>{window.removeEventListener("storage",a),window.removeEventListener("focus",s),window.removeEventListener(V.SESSIONS_UPDATED_EVENT,r)}},[e,e3,Q]);let e5=async e=>{X(e),ty([]),await e7(e),await te(e),await e3(e)},e6=async t=>{eE(!0),eU(null);try{if(!await N(t))return eU("Selected directory is not a valid git repository."),!1;let a=[...(y||await (0,B.getConfig)()).recentRepos];a.includes(t)?a=[t,...a.filter(e=>e!==t)]:a.unshift(t);let s=await (0,O.updateConfig)({recentRepos:a});if(J(s),b(!1),"home"===e)return Z.push(`/new?repo=${encodeURIComponent(t)}`),!0;return await e5(t),!0}catch(e){return console.error(e),eU("Failed to open repository."),!1}finally{eE(!1)}},e8=async t=>{if("new"!==e)return;let a=t.target.value;if(!a||a===Q||!await e6(a))return;let s=new URLSearchParams;s.set("repo",a),f&&s.set("prefillFromSession",f),Z.replace(`/new?${s.toString()}`)};(0,a.useEffect)(()=>{if("new"===e){if(!s){X(null),el([]),et([]),es("");return}s!==Q&&e6(s)}},[e,s,Q]),(0,a.useEffect)(()=>{if("new"!==e)return;if(s)return void eT(!1);let t=p?.trim()??"";if(!t)return void eT(!1);let a=!1;return(async()=>{eU(null),eT(!0);let e=await P(t);if(a)return;if(!e.success){eU(e.error||"Failed to search repositories."),eT(!1);return}if(!e.repoPath){eU(`Could not find a matching repository for "${t}".`),eT(!1);return}let s=new URLSearchParams;s.set("repo",e.repoPath),f&&s.set("prefillFromSession",f),Z.replace(`/new?${s.toString()}`)})(),()=>{a=!0}},[p,e,f,s,Z]),(0,a.useEffect)(()=>{eD(!1),ek([]),eC(null)},[f]),(0,a.useEffect)(()=>{if("new"!==e||!Q||!f||eM)return;let t=!1;return(async()=>{let e=await T(f);if(t)return;if(!e.success||!e.context){e.error&&eU(e.error),eD(!0);return}let a=e.context;if(a.repoPath!==Q)return eD(!0);let s=_.find(e=>e.cli===a.agentProvider);s&&(eo(s),a.model&&("auto"===a.model||s.models.some(e=>e.id===a.model))?em(a.model):em("auto")),ew(a.title||""),ev(a.initialMessage||""),ek(a.attachmentNames||[]),eC(a.sourceSessionName),eb(!0),eD(!0)})(),()=>{t=!0}},[eM,e,f,Q]);let e7=async e=>{let t=y||await (0,B.getConfig)();y||J(t);let a=t.repoSettings[e]||{},s=a.agentProvider,r=a.agentModel,l=a.startupScript,i=a.devServerScript;if(s){let e=_.find(e=>e.cli===s);e?(eo(e),r&&("auto"===r||e.models.some(e=>e.id===r))?em(r):em("auto")):(eo(_[0]),em("auto"))}else eo(_[0]),em("auto");null!=l?eh(l):eh(await C(e)),null!=i?ef(i):ef(await M(e))},e9=async e=>{J(await (0,O.updateConfig)({defaultRoot:e})),v(!1)},te=async e=>{try{let t=await S(e);et(t);let a=((y||await (0,B.getConfig)()).repoSettings[e]||{}).lastBranch,s=t.find(e=>e.current)?.name;if(a&&t.some(e=>e.name===a)){if(es(a),a!==s)try{await k(e,a);let t=await S(e);et(t)}catch(e){console.warn("Could not auto-checkout to remembered branch",e),s&&es(s)}}else s&&es(s)}catch(e){console.error("Failed to load branches",e),eU("Failed to load branches.")}},tt=async e=>{let t=e.target.value;if(Q){eE(!0);try{await k(Q,t),es(t);let e=await G(Q,{lastBranch:t});J(e);let a=await S(Q);et(a)}catch{eU(`Failed to checkout branch ${t}`)}finally{eE(!1)}}},ta=async e=>{let t=e.target.value,a=_.find(e=>e.cli===t);if(a&&Q){eo(a);let e="auto";em(e),J(await G(Q,{agentProvider:a.cli,agentModel:e}))}},ts=async e=>{let t=e.target.value;em(t),Q&&J(await G(Q,{agentModel:t}))},tr=async e=>{eh(e.target.value)},tl=async()=>{Q&&J(await G(Q,{startupScript:eu}))},ti=async e=>{Q&&J(await G(Q,{devServerScript:e}))},tn=async()=>{await ti(ep)},tc=(0,a.useCallback)((e,t)=>{if(e.name&&e.name.trim().length>0)return e;let a=e.type&&e.type.split("/")[1]?.split("+")[0]||"bin";return new File([e],`pasted-file-${Date.now()}-${t+1}.${a}`,{type:e.type,lastModified:e.lastModified||Date.now()})},[]),to=(0,a.useCallback)(e=>{0!==e.length&&eN(t=>{let a=new Map(t.map(e=>[e.name,e]));return e.forEach(e=>{a.set(e.name,e)}),Array.from(a.values())})},[]),[td,tm]=(0,a.useState)(!1),[tu,th]=(0,a.useState)([]),[,tp]=(0,a.useState)(""),[tf,tx]=(0,a.useState)(0),[tb,tg]=(0,a.useState)(0),[tv,ty]=(0,a.useState)([]),tw=async e=>{let t=e.target.value,a=e.target.selectionStart;ev(t),tx(a);let s=t.substring(0,a),r=s.lastIndexOf("@");if(-1!==r){let e=s.substring(r+1);if(!/\s/.test(e)){if(tp(e),tm(!0),Q){var l;let t,a=tv;0===tv.length&&ty(a=await D(Q)),l=a,t=e.toLowerCase(),th([...[...ej.map(e=>e.name),...eS].filter(e=>e.toLowerCase().includes(t)),...l.filter(e=>e.toLowerCase().includes(t)).slice(0,20)]),tg(0)}return}}tm(!1)},tj=e=>{let t=eg.substring(0,tf).lastIndexOf("@");if(-1!==t){let a=eg.substring(0,t),s=eg.substring(tf);ev(`${a}@${e} ${s}`),tm(!1)}};(0,a.useEffect)(()=>{if("new"!==e||!Q)return;let t=e=>{let t=e.clipboardData;if(!t)return;let a=Array.from(t.items).filter(e=>"file"===e.kind).map(e=>e.getAsFile()).filter(e=>null!==e),s=(a.length>0?a:Array.from(t.files)).map((e,t)=>tc(e,t));0!==s.length&&(e.preventDefault(),to(s))};return window.addEventListener("paste",t),()=>{window.removeEventListener("paste",t)}},[to,e,tc,Q]);let tN=async(e,t)=>{if(e.stopPropagation(),y){let e=y.recentRepos.filter(e=>e!==t);J(await (0,O.updateConfig)({recentRepos:e}))}},tS=(0,a.useCallback)(()=>{if(!eV||!eW||!e0.current)return;let e=e0.current,t=(a=0)=>{if(a>40)return void eZ("Timed out while waiting for terminal to initialize.");try{let s=e.contentWindow;if(s?.term){s.term.paste(`${eW}\r`),eQ(!0),eZ(null),s.focus();return}setTimeout(()=>t(a+1),300)}catch(e){console.error("Failed to inject login command into terminal iframe:",e),eZ("Could not access ttyd terminal. Ensure ttyd is running and try again.")}};setTimeout(()=>t(),500)},[eV,eW]),tk=(0,a.useCallback)(async()=>{let e=e4(ec?.cli);if(!e)return!0;let t=await E(e);if(!t.success)return eU(t.error||`Failed to verify ${Y[e]} installation status.`),!1;if(t.installed)return!0;eO(!0),ez(e),eU(null);let a=await F(e);if(eO(!1),ez(null),!a.success)return eU(a.error||`Failed to install ${Y[e]}.`),!1;let s=await (0,R.startTtydProcess)();return s.success?(eq(e),eY(W[e]),eQ(!1),eZ(null),eH(!0)):eU(s.error||"Failed to start ttyd"),!1},[ec?.cli,e4]),tR=async(e={})=>{if(Q){eE(!0),eU(null);try{if(!e.skipAgentSetup&&!await tk())return void eE(!1);let t=ep.trim();!t&&(t=await M(Q))&&ef(t),await tl(),await ti(t);let a=await (0,R.startTtydProcess)();if(!a.success){eU(a.error||"Failed to start ttyd"),eE(!1);return}let s=await U(Q,ea||"main",{agent:ec?.cli||"agent",model:ed||"",title:ey,devServerScript:t||void 0});if(s.success&&s.sessionName&&s.worktreePath&&s.branchName){let e=[],t=[];if(ej.length>0){let t=new FormData;ej.forEach(e=>t.append(e.name,e)),e=await (0,L.saveAttachments)(s.worktreePath,t)}if(eR&&eS.length>0){let e=await $(eR,s.worktreePath,eS);if(!e.success){eU(e.error||"Failed to carry over attachments from source session"),eE(!1);return}t=e.copiedAttachmentNames}let a=Array.from(new Set([...e,...t])),r=eg.trim(),l=r;l&&(l.includes(q)||(l=`${l}
|
|
2
2
|
|
|
3
3
|
${q}`)),l=l.replace(/@(\S+)/g,(e,t)=>a.includes(t)?`${s.worktreePath}-attachments/${t}`:t);let i=await K(s.sessionName,{title:ey||void 0,initialMessage:l||void 0,rawInitialMessage:r||void 0,startupScript:eu||void 0,attachmentNames:a,agentProvider:ec?.cli||"agent",model:ed||""});if(!i.success){eU(i.error||"Failed to save session context"),eE(!1);return}let n=`/session/${s.sessionName}`;Z.push(n),eE(!1)}else eU(s.error||"Failed to create session worktree"),eE(!1)}catch(e){console.error(e),eU("Failed to start session"),eE(!1)}}},tC=()=>{tR()},tM=async()=>{eH(!1),eq(null),eY(""),eQ(!1),eZ(null),await tR({skipAgentSetup:!0})},tD=async e=>{if(Q){eE(!0);try{let t=await (0,R.startTtydProcess)();if(!t.success){eU(t.error||"Failed to start ttyd"),eE(!1);return}let a=`/session/${e.sessionName}`;Z.push(a),eE(!1)}catch(e){console.error(e),eU("Failed to resume session"),eE(!1)}}},tL=async e=>{if(Q&&confirm(`Delete session "${e.sessionName}"?
|
|
4
4
|
|
|
5
|
-
This will remove the worktree, branch, and session metadata.`)){eP(e.sessionName),eU(null);try{let t=await A(e.sessionName);if(!t.success)return void eU(t.error||"Failed to delete session");let a=await I(Q);el(a);let s=await I();en(s),e1()}catch(e){console.error(e),eU("Failed to delete session")}finally{eP(null)}}},tE=y?.recentRepos??[],tF=Q?tE.includes(Q)?tE:[Q,...tE]:tE;return(0,t.jsxs)(t.Fragment,{children:["home"===e&&(0,t.jsx)("div",{className:"card w-full max-w-2xl bg-base-200 shadow-xl",children:(0,t.jsxs)("div",{className:"card-body",children:[(0,t.jsxs)("h2",{className:"card-title flex justify-between items-center",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsx)(H.default,{src:"/icon.png",alt:"Viba",width:24,height:24,className:"rounded-sm"}),"Viba"]}),(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsxs)("button",{className:"btn btn-ghost btn-sm gap-2",onClick:()=>v(!0),title:y?.defaultRoot?`Default: ${y.defaultRoot}`:"Set default browsing folder",children:[(0,t.jsx)(o,{className:"w-4 h-4"}),y?.defaultRoot?"Change Default":"Set Default Root"]}),(0,t.jsxs)("button",{className:"btn btn-primary btn-sm gap-2",onClick:()=>b(!0),children:[(0,t.jsx)(i.Plus,{className:"w-4 h-4"})," Open Local Repo"]})]})]}),e$&&(0,t.jsx)("div",{className:"alert alert-error text-sm py-2 px-3 mt-2",children:e$}),(0,t.jsx)("div",{className:"mt-4 space-y-4",children:(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsx)("h3",{className:"text-sm font-semibold opacity-70 uppercase tracking-wide",children:"Recent Repositories"}),eI?y&&0!==y.recentRepos.length?(0,t.jsx)("div",{className:"flex flex-col gap-2",children:y.recentRepos.map(e=>(0,t.jsxs)("div",{onClick:()=>e5(e),className:"flex items-center justify-between p-3 bg-base-100 hover:bg-base-300 rounded-md cursor-pointer group transition-all border border-base-300",children:[(0,t.jsxs)("div",{className:"flex items-center gap-3 overflow-hidden shrink min-w-0",children:[(0,t.jsx)(r,{className:"w-5 h-5 text-secondary shrink-0"}),(0,t.jsxs)("div",{className:"flex flex-col overflow-hidden",children:[(0,t.jsx)("span",{className:"font-medium truncate",children:(0,w.getBaseName)(e)}),(0,t.jsx)("span",{className:"text-xs opacity-50 truncate",children:e})]})]}),(0,t.jsxs)("div",{className:"flex items-center gap-2 shrink-0",children:[(0,t.jsx)("button",{onClick:t=>tN(t,e),className:"btn btn-circle btn-ghost btn-xs opacity-0 group-hover:opacity-100 text-error",title:"Remove from history",children:(0,t.jsx)(n,{className:"w-3 h-3"})}),(0,t.jsx)(c,{className:"w-4 h-4 opacity-30"})]})]},e))}):(0,t.jsx)("div",{className:"text-center py-8 text-base-content/40 italic bg-base-100 rounded-lg",children:"No recent repositories found."}):(0,t.jsx)("div",{className:"flex items-center justify-center py-8 bg-base-100 rounded-lg",children:(0,t.jsx)("span",{className:"loading loading-spinner loading-md"})})]})})]})}),"new"===e&&Q&&(0,t.jsxs)("div",{className:"w-full max-w-6xl space-y-4",children:[e$&&(0,t.jsx)("div",{className:"alert alert-error text-sm py-2 px-3",children:e$}),(0,t.jsxs)("div",{className:"flex flex-col gap-4 w-full",children:[(0,t.jsx)("div",{className:"card w-full bg-base-200 shadow-xl",children:(0,t.jsxs)("div",{className:"card-body",children:[(0,t.jsxs)("h2",{className:"card-title flex justify-between items-center",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsx)(r,{className:"w-6 h-6 text-primary"}),"Git Repository Selector"]}),(0,t.jsx)("button",{className:"btn btn-sm btn-ghost",onClick:()=>Z.push("/"),children:"Change Repo"})]}),(0,t.jsx)("div",{className:"mt-4",children:(0,t.jsxs)("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:[(0,t.jsxs)("div",{className:"bg-base-100 p-4 rounded-lg border border-base-300 space-y-2",children:[(0,t.jsx)("label",{className:"text-xs opacity-50 uppercase tracking-widest",children:"Current Repository"}),(0,t.jsxs)("div",{className:"join w-full",children:[(0,t.jsx)("div",{className:"join-item bg-base-300 flex items-center px-3 border border-base-content/20 border-r-0",children:(0,t.jsx)(r,{className:"w-4 h-4 text-primary"})}),(0,t.jsx)("select",{className:"select select-bordered join-item w-full font-mono focus:outline-none",value:Q,onChange:e=>{e8(e)},disabled:eL||0===tF.length,children:tF.map(e=>(0,t.jsx)("option",{value:e,children:(0,w.getBaseName)(e)},e))})]}),(0,t.jsx)("div",{className:"text-[10px] opacity-50 font-mono truncate px-1",title:Q,children:Q})]}),(0,t.jsxs)("div",{className:"bg-base-100 p-4 rounded-lg border border-base-300 space-y-2",children:[(0,t.jsxs)("div",{className:"flex justify-between items-center",children:[(0,t.jsx)("label",{className:"text-sm font-medium opacity-70 uppercase tracking-widest",children:"Current Branch"}),eL&&(0,t.jsx)("span",{className:"loading loading-spinner loading-xs"})]}),(0,t.jsxs)("div",{className:"join w-full",children:[(0,t.jsx)("div",{className:"join-item bg-base-300 flex items-center px-3 border border-base-content/20 border-r-0",children:(0,t.jsx)(l.GitBranch,{className:"w-4 h-4"})}),(0,t.jsx)("select",{className:"select select-bordered join-item w-full font-mono focus:outline-none",value:ea,onChange:tt,disabled:eL,children:ee.map(e=>(0,t.jsxs)("option",{value:e.name,children:[e.name," ",e.current?"(checked out)":""]},e.name))})]}),(0,t.jsx)("div",{className:"text-[10px] opacity-50 px-1 italic",children:"Switching branches updates the working directory."})]})]})})]})}),er.length>0&&(0,t.jsx)("div",{className:"card w-full bg-base-200 shadow-xl",children:(0,t.jsxs)("div",{className:"card-body",children:[(0,t.jsxs)("h2",{className:"card-title flex items-center gap-2",children:[(0,t.jsx)(h.Play,{className:"w-6 h-6 text-success"}),"Continue Existing Session"]}),(0,t.jsx)("div",{className:"flex flex-col gap-2 mt-4 max-h-64 overflow-y-auto",children:er.map(e=>(0,t.jsx)("div",{className:"flex flex-col gap-2 p-3 bg-base-100 rounded-md border border-base-300",children:(0,t.jsxs)("div",{className:"flex justify-between items-start",children:[(0,t.jsxs)("div",{children:[e.title&&(0,t.jsx)("div",{className:"font-semibold",children:e.title}),(0,t.jsx)("div",{className:"text-xs opacity-60 font-mono",children:e.sessionName}),(0,t.jsxs)("div",{className:"text-xs opacity-60 mt-1",children:["Agent: ",e.agent," • Model: ",e.model]})]}),(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsxs)("button",{className:"btn btn-sm btn-success btn-outline gap-2",onClick:()=>tD(e),disabled:eL||eF===e.sessionName,children:[(0,t.jsx)(h.Play,{className:"w-3 h-3"})," Resume"]}),(0,t.jsxs)("button",{className:"btn btn-sm btn-secondary btn-outline gap-2",onClick:()=>(e=>{if(!Q)return;let t=`/new?repo=${encodeURIComponent(Q)}&prefillFromSession=${encodeURIComponent(e.sessionName)}`;Z.push(t)})(e),disabled:eL||eF===e.sessionName,title:"Start a new attempt prefilled from this session",children:[(0,t.jsx)(i.Plus,{className:"w-3 h-3"})," New Attempt"]}),(0,t.jsxs)("button",{className:"btn btn-sm btn-error btn-outline gap-2",onClick:()=>tL(e),disabled:eL||eF===e.sessionName,children:[(0,t.jsx)(u.Trash2,{className:"w-3 h-3"}),eF===e.sessionName?"Deleting...":"Delete"]})]})]})},e.sessionName))})]})}),(0,t.jsx)("div",{className:"card w-full bg-base-200 shadow-xl",children:(0,t.jsxs)("div",{className:"card-body",children:[(0,t.jsxs)("h2",{className:"card-title flex items-center gap-2",children:[(0,t.jsx)(d,{className:"w-6 h-6 text-secondary"}),"Start New Session"]}),(0,t.jsxs)("div",{className:"mt-4 space-y-6",children:[(0,t.jsxs)("div",{className:"space-y-3",children:[(0,t.jsxs)("button",{type:"button",className:"btn btn-ghost btn-sm px-2 h-auto min-h-0 normal-case justify-start gap-2",onClick:()=>eb(e=>!e),children:[(0,t.jsx)(c,{className:`w-4 h-4 transition-transform ${ef?"rotate-90":""}`}),ef?"Hide Session Setup":e2]}),ef&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:[(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsx)("label",{className:"text-sm font-medium opacity-70",children:"Agent Provider"}),(0,t.jsxs)("div",{className:"join w-full",children:[(0,t.jsx)("div",{className:"join-item bg-base-300 flex items-center px-3 border border-base-content/20 border-r-0",children:(0,t.jsx)(d,{className:"w-4 h-4"})}),(0,t.jsx)("select",{className:"select select-bordered join-item w-full focus:outline-none",value:ec?.cli||"",onChange:ta,disabled:eL,children:_.map(e=>(0,t.jsx)("option",{value:e.cli,children:e.name},e.cli))})]}),ec?.description&&(0,t.jsx)("p",{className:"text-[10px] opacity-60 mt-1 pl-1 italic leading-tight",children:ec.description})]}),(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsx)("label",{className:"text-sm font-medium opacity-70",children:"Model"}),(0,t.jsxs)("div",{className:"join w-full",children:[(0,t.jsx)("div",{className:"join-item bg-base-300 flex items-center px-3 border border-base-content/20 border-r-0",children:(0,t.jsx)(m,{className:"w-4 h-4"})}),(0,t.jsxs)("select",{className:"select select-bordered join-item w-full focus:outline-none",value:ed,onChange:ts,disabled:eL||!ec,children:[(0,t.jsx)("option",{value:"auto",children:"Auto"}),ec?.models.map(e=>(0,t.jsx)("option",{value:e.id,children:e.label},e.id))]})]}),ec?.models.find(e=>e.id===ed)?.description&&(0,t.jsx)("p",{className:"text-[10px] opacity-60 mt-1 pl-1 italic leading-tight",children:ec.models.find(e=>e.id===ed)?.description})]})]}),(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsx)("label",{className:"text-sm font-medium opacity-70",children:"Start up script (Optional)"}),(0,t.jsx)("input",{type:"text",className:"input input-bordered w-full font-mono text-sm",placeholder:"npm i",value:eu,onChange:tr,onBlur:tl,onKeyDown:e=>{(e.metaKey||e.ctrlKey)&&"Enter"===e.key&&(e.preventDefault(),tC())},disabled:eL}),(0,t.jsx)("div",{className:"text-xs opacity-50 px-1",children:"Script to run in the terminal agent iframe upon startup."})]}),(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsx)("label",{className:"text-sm font-medium opacity-70",children:"Dev server script (Optional)"}),(0,t.jsx)("input",{type:"text",className:"input input-bordered w-full font-mono text-sm",placeholder:"npm run dev",value:ep,onChange:e=>{ex(e.target.value)},onBlur:tn,onKeyDown:e=>{(e.metaKey||e.ctrlKey)&&"Enter"===e.key&&(e.preventDefault(),tC())},disabled:eL}),(0,t.jsx)("div",{className:"text-xs opacity-50 px-1",children:"Script for the Session View Start Dev Server button in the right terminal."})]})]})]}),(0,t.jsx)("div",{className:"divider"}),(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsx)("label",{className:"text-sm font-medium opacity-70",children:"Title (Optional)"}),(0,t.jsx)("input",{type:"text",className:"input input-bordered w-full font-mono text-sm",placeholder:"Task Title",value:ey,onChange:e=>ew(e.target.value),onKeyDown:e=>{(e.metaKey||e.ctrlKey)&&"Enter"===e.key&&(e.preventDefault(),tC())},disabled:eL})]}),(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsx)("label",{className:"text-sm font-medium opacity-70",children:"Initial Message (Optional)"}),(0,t.jsxs)("div",{className:"relative",children:[(0,t.jsx)("textarea",{className:"textarea textarea-bordered w-full h-64 font-mono text-sm leading-tight resize-none",placeholder:"Describe what you want the agent to do... Type @ to mention files.",value:eg,onChange:tw,onKeyDown:e=>{if((e.metaKey||e.ctrlKey)&&"Enter"===e.key){e.preventDefault(),tC();return}td&&tu.length>0&&("ArrowUp"===e.key?(e.preventDefault(),tg(e=>e>0?e-1:tu.length-1)):"ArrowDown"===e.key?(e.preventDefault(),tg(e=>e<tu.length-1?e+1:0)):"Enter"===e.key||"Tab"===e.key?(e.preventDefault(),tj(tu[tb])):"Escape"===e.key&&(e.preventDefault(),tm(!1)))},onClick:e=>{tf(e.currentTarget.selectionStart),tm(!1)},onKeyUp:e=>tf(e.currentTarget.selectionStart),disabled:eL}),td&&tu.length>0&&(0,t.jsx)("div",{className:"absolute left-0 right-0 z-50 mt-1 max-h-48 overflow-y-auto bg-base-100 border border-base-300 rounded-md shadow-lg",children:tu.map((e,a)=>(0,t.jsx)("button",{className:`w-full text-left px-3 py-2 text-xs border-b border-base-200 last:border-0 truncate ${a===tb?"bg-primary text-primary-content":"hover:bg-primary/10"}`,onMouseDown:t=>{t.preventDefault(),tj(e)},children:e},e))})]})]}),(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsx)("label",{className:"text-sm font-medium opacity-70",children:"Attachments (Optional)"}),(0,t.jsx)("input",{type:"file",multiple:!0,className:"file-input file-input-bordered w-full",onChange:e=>{e.target.files&&(to(Array.from(e.target.files).map((e,t)=>tc(e,t))),e.target.value="")},disabled:eL}),(0,t.jsx)("div",{className:"text-xs opacity-50 px-1",children:"Paste files from clipboard with Cmd/Ctrl+V anywhere on this page."}),ej.length>0&&(0,t.jsx)("div",{className:"flex flex-wrap gap-2 mt-2",children:ej.map((e,a)=>(0,t.jsxs)("span",{className:"badge badge-neutral gap-2 p-3",children:[e.name,(0,t.jsx)("button",{onClick:()=>{eN(e=>e.filter((e,t)=>t!==a))},className:"btn btn-ghost btn-xs btn-circle text-error",children:(0,t.jsx)(n,{className:"w-3 h-3"})})]},`upload-${a}`))}),eS.length>0&&(0,t.jsx)("div",{className:"flex flex-wrap gap-2 mt-2",children:eS.map((e,a)=>(0,t.jsxs)("span",{className:"badge badge-secondary gap-2 p-3",children:[e,(0,t.jsx)("button",{onClick:()=>{ek(e=>e.filter((e,t)=>t!==a))},className:"btn btn-ghost btn-xs btn-circle text-error",title:"Remove carried attachment",children:(0,t.jsx)(n,{className:"w-3 h-3"})})]},`prefill-${e}-${a}`))})]}),(0,t.jsx)("div",{className:"card-actions justify-end mt-4",children:(0,t.jsx)("button",{className:"btn btn-primary btn-wide shadow-lg",onClick:tC,disabled:eL,children:eL?(0,t.jsx)("span",{className:"loading loading-spinner"}):"Start Session"})})]})]})})]})]}),"new"===e&&!Q&&(0,t.jsx)("div",{className:"card w-full max-w-2xl bg-base-200 shadow-xl",children:(0,t.jsxs)("div",{className:"card-body",children:[e$&&(0,t.jsx)("div",{className:"alert alert-error text-sm py-2 px-3",children:e$}),(0,t.jsx)("h2",{className:"card-title",children:"Select a Repository"}),(0,t.jsx)("p",{className:"opacity-70 text-sm",children:"Choose a repository first, then start or resume a session."}),(0,t.jsx)("div",{className:"card-actions justify-end mt-4",children:(0,t.jsx)("button",{className:"btn btn-primary",onClick:()=>Z.push("/"),children:"Go to Home"})})]})}),"new"===e&&eB&&eG&&(0,t.jsx)("div",{className:"fixed inset-0 z-[1000] flex items-center justify-center bg-base-content/45 px-4",children:(0,t.jsx)("div",{className:"w-full max-w-md rounded-xl border border-base-300 bg-base-100 p-6 shadow-2xl",children:(0,t.jsxs)("div",{className:"flex items-center gap-4",children:[(0,t.jsx)("span",{className:"loading loading-spinner loading-lg text-primary"}),(0,t.jsxs)("div",{className:"space-y-1",children:[(0,t.jsxs)("h3",{className:"text-lg font-semibold",children:["Installing ",Y[eG]]}),(0,t.jsx)("p",{className:"text-sm opacity-70",children:"Please wait while we install the coding agent CLI."})]})]})})}),"new"===e&&eV&&e_&&(0,t.jsx)("div",{className:"fixed inset-0 z-[1001] flex items-center justify-center bg-base-content/60 p-4",children:(0,t.jsx)("div",{className:"w-full max-w-5xl rounded-xl border border-base-300 bg-base-100 shadow-2xl",children:(0,t.jsxs)("div",{className:"space-y-4 p-5 md:p-6",children:[(0,t.jsx)("h3",{className:"text-xl font-semibold",children:"Login Required"}),(0,t.jsxs)("p",{className:"text-sm opacity-80",children:[Y[e_]," has been installed. Complete login in the terminal below, then click Done to continue."]}),(0,t.jsxs)("p",{className:"text-xs opacity-60",children:["Command: ",(0,t.jsx)("span",{className:"font-mono",children:eW})]}),(0,t.jsx)("div",{className:"h-[420px] overflow-hidden rounded-lg border border-base-300 bg-base-200",children:(0,t.jsx)("iframe",{ref:e0,src:"/terminal",className:"h-full w-full border-none",allow:"clipboard-read; clipboard-write",onLoad:tS})}),eX&&(0,t.jsx)("div",{className:"alert alert-error text-sm py-2",children:eX}),!eX&&(0,t.jsx)("div",{className:"text-xs opacity-70",children:eJ?"Login command was sent to the terminal automatically.":"Waiting for terminal to initialize..."}),(0,t.jsx)("div",{className:"flex justify-end",children:(0,t.jsx)("button",{className:"btn btn-primary",onClick:()=>void tM(),disabled:eL,children:"Done"})})]})})}),"new"===e&&!Q&&(!s||!!e$)&&(0,t.jsx)("div",{className:"card w-full max-w-2xl bg-base-200 shadow-xl",children:(0,t.jsxs)("div",{className:"card-body",children:[(0,t.jsxs)("h2",{className:"card-title flex items-center gap-2",children:[(0,t.jsx)(r,{className:"w-6 h-6 text-primary"}),"Git Repository Selector"]}),eA?(0,t.jsxs)("div",{className:"alert text-sm py-2 px-3 mt-2 flex items-center gap-2",children:[(0,t.jsx)("span",{className:"loading loading-spinner loading-sm"}),p?`Searching for repository "${p}"...`:"Searching for repository..."]}):e$?(0,t.jsx)("div",{className:"alert alert-error text-sm py-2 px-3 mt-2",children:e$}):(0,t.jsx)("div",{className:"text-sm opacity-70 mt-2",children:"No repository specified."}),(0,t.jsx)("div",{className:"mt-4",children:(0,t.jsx)("button",{className:"btn btn-primary btn-sm",onClick:()=>Z.push("/"),children:"Choose Repository"})})]})}),"home"===e&&f&&(0,t.jsx)(j,{initialPath:y?.defaultRoot||void 0,onSelect:e5,onCancel:()=>b(!1),checkRepo:N}),"home"===e&&g&&(0,t.jsx)(j,{title:"Default Root Folder",initialPath:y?.defaultRoot||void 0,onSelect:e9,onCancel:()=>v(!1)})]})}e.s(["default",()=>J],5951)}]);
|
|
5
|
+
This will remove the worktree, branch, and session metadata.`)){eP(e.sessionName),eU(null);try{let t=await A(e.sessionName);if(!t.success)return void eU(t.error||"Failed to delete session");let a=await I(Q);el(a);let s=await I();en(s),e1()}catch(e){console.error(e),eU("Failed to delete session")}finally{eP(null)}}},tE=y?.recentRepos??[],tF=Q?tE.includes(Q)?tE:[Q,...tE]:tE;return(0,t.jsxs)(t.Fragment,{children:["home"===e&&(0,t.jsx)("div",{className:"card w-full max-w-2xl bg-base-200 shadow-xl",children:(0,t.jsxs)("div",{className:"card-body",children:[(0,t.jsxs)("h2",{className:"card-title flex justify-between items-center",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsx)(H.default,{src:"/icon.png",alt:"Viba",width:24,height:24,className:"rounded-sm"}),"Viba"]}),(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsxs)("button",{className:"btn btn-ghost btn-sm gap-2",onClick:()=>v(!0),title:y?.defaultRoot?`Default: ${y.defaultRoot}`:"Set default browsing folder",children:[(0,t.jsx)(o,{className:"w-4 h-4"}),y?.defaultRoot?"Change Default":"Set Default Root"]}),(0,t.jsxs)("button",{className:"btn btn-primary btn-sm gap-2",onClick:()=>b(!0),children:[(0,t.jsx)(i.Plus,{className:"w-4 h-4"})," Open Local Repo"]})]})]}),e$&&(0,t.jsx)("div",{className:"alert alert-error text-sm py-2 px-3 mt-2",children:e$}),(0,t.jsx)("div",{className:"mt-4 space-y-4",children:(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsx)("h3",{className:"text-sm font-semibold opacity-70 uppercase tracking-wide",children:"Recent Repositories"}),eI?y&&0!==y.recentRepos.length?(0,t.jsx)("div",{className:"flex flex-col gap-2",children:y.recentRepos.map(e=>(0,t.jsxs)("div",{onClick:()=>e6(e),className:"flex items-center justify-between p-3 bg-base-100 hover:bg-base-300 rounded-md cursor-pointer group transition-all border border-base-300",children:[(0,t.jsxs)("div",{className:"flex items-center gap-3 overflow-hidden shrink min-w-0",children:[(0,t.jsx)(r,{className:"w-5 h-5 text-secondary shrink-0"}),(0,t.jsxs)("div",{className:"flex flex-col overflow-hidden",children:[(0,t.jsx)("span",{className:"font-medium truncate",children:(0,w.getBaseName)(e)}),(0,t.jsx)("span",{className:"text-xs opacity-50 truncate",children:e})]})]}),(0,t.jsxs)("div",{className:"flex items-center gap-2 shrink-0",children:[(0,t.jsx)("button",{onClick:t=>tN(t,e),className:"btn btn-circle btn-ghost btn-xs opacity-0 group-hover:opacity-100 text-error",title:"Remove from history",children:(0,t.jsx)(n,{className:"w-3 h-3"})}),(0,t.jsx)(c,{className:"w-4 h-4 opacity-30"})]})]},e))}):(0,t.jsx)("div",{className:"text-center py-8 text-base-content/40 italic bg-base-100 rounded-lg",children:"No recent repositories found."}):(0,t.jsx)("div",{className:"flex items-center justify-center py-8 bg-base-100 rounded-lg",children:(0,t.jsx)("span",{className:"loading loading-spinner loading-md"})})]})})]})}),"new"===e&&Q&&(0,t.jsxs)("div",{className:"w-full max-w-6xl space-y-4",children:[e$&&(0,t.jsx)("div",{className:"alert alert-error text-sm py-2 px-3",children:e$}),(0,t.jsxs)("div",{className:"flex flex-col gap-4 w-full",children:[(0,t.jsx)("div",{className:"card w-full bg-base-200 shadow-xl",children:(0,t.jsxs)("div",{className:"card-body",children:[(0,t.jsxs)("h2",{className:"card-title flex justify-between items-center",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsx)(r,{className:"w-6 h-6 text-primary"}),"Git Repository Selector"]}),(0,t.jsx)("button",{className:"btn btn-sm btn-ghost",onClick:()=>Z.push("/"),children:"Change Repo"})]}),(0,t.jsx)("div",{className:"mt-4",children:(0,t.jsxs)("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:[(0,t.jsxs)("div",{className:"bg-base-100 p-4 rounded-lg border border-base-300 space-y-2",children:[(0,t.jsx)("label",{className:"text-xs opacity-50 uppercase tracking-widest",children:"Current Repository"}),(0,t.jsxs)("div",{className:"join w-full",children:[(0,t.jsx)("div",{className:"join-item bg-base-300 flex items-center px-3 border border-base-content/20 border-r-0",children:(0,t.jsx)(r,{className:"w-4 h-4 text-primary"})}),(0,t.jsx)("select",{className:"select select-bordered join-item w-full font-mono focus:outline-none",value:Q,onChange:e=>{e8(e)},disabled:eL||0===tF.length,children:tF.map(e=>(0,t.jsx)("option",{value:e,children:(0,w.getBaseName)(e)},e))})]}),(0,t.jsx)("div",{className:"text-[10px] opacity-50 font-mono truncate px-1",title:Q,children:Q})]}),(0,t.jsxs)("div",{className:"bg-base-100 p-4 rounded-lg border border-base-300 space-y-2",children:[(0,t.jsxs)("div",{className:"flex justify-between items-center",children:[(0,t.jsx)("label",{className:"text-sm font-medium opacity-70 uppercase tracking-widest",children:"Current Branch"}),eL&&(0,t.jsx)("span",{className:"loading loading-spinner loading-xs"})]}),(0,t.jsxs)("div",{className:"join w-full",children:[(0,t.jsx)("div",{className:"join-item bg-base-300 flex items-center px-3 border border-base-content/20 border-r-0",children:(0,t.jsx)(l.GitBranch,{className:"w-4 h-4"})}),(0,t.jsx)("select",{className:"select select-bordered join-item w-full font-mono focus:outline-none",value:ea,onChange:tt,disabled:eL,children:ee.map(e=>(0,t.jsxs)("option",{value:e.name,children:[e.name," ",e.current?"(checked out)":""]},e.name))})]}),(0,t.jsx)("div",{className:"text-[10px] opacity-50 px-1 italic",children:"Switching branches updates the working directory."})]})]})})]})}),er.length>0&&(0,t.jsx)("div",{className:"card w-full bg-base-200 shadow-xl",children:(0,t.jsxs)("div",{className:"card-body",children:[(0,t.jsxs)("h2",{className:"card-title flex items-center gap-2",children:[(0,t.jsx)(h.Play,{className:"w-6 h-6 text-success"}),"Continue Existing Session"]}),(0,t.jsx)("div",{className:"flex flex-col gap-2 mt-4 max-h-64 overflow-y-auto",children:er.map(e=>(0,t.jsx)("div",{className:"flex flex-col gap-2 p-3 bg-base-100 rounded-md border border-base-300",children:(0,t.jsxs)("div",{className:"flex justify-between items-start",children:[(0,t.jsxs)("div",{children:[e.title&&(0,t.jsx)("div",{className:"font-semibold",children:e.title}),(0,t.jsx)("div",{className:"text-xs opacity-60 font-mono",children:e.sessionName}),(0,t.jsxs)("div",{className:"text-xs opacity-60 mt-1",children:["Agent: ",e.agent," • Model: ",e.model]})]}),(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsxs)("button",{className:"btn btn-sm btn-success btn-outline gap-2",onClick:()=>tD(e),disabled:eL||eF===e.sessionName,children:[(0,t.jsx)(h.Play,{className:"w-3 h-3"})," Resume"]}),(0,t.jsxs)("button",{className:"btn btn-sm btn-secondary btn-outline gap-2",onClick:()=>(e=>{if(!Q)return;let t=`/new?repo=${encodeURIComponent(Q)}&prefillFromSession=${encodeURIComponent(e.sessionName)}`;Z.push(t)})(e),disabled:eL||eF===e.sessionName,title:"Start a new attempt prefilled from this session",children:[(0,t.jsx)(i.Plus,{className:"w-3 h-3"})," New Attempt"]}),(0,t.jsxs)("button",{className:"btn btn-sm btn-error btn-outline gap-2",onClick:()=>tL(e),disabled:eL||eF===e.sessionName,children:[(0,t.jsx)(u.Trash2,{className:"w-3 h-3"}),eF===e.sessionName?"Deleting...":"Delete"]})]})]})},e.sessionName))})]})}),(0,t.jsx)("div",{className:"card w-full bg-base-200 shadow-xl",children:(0,t.jsxs)("div",{className:"card-body",children:[(0,t.jsxs)("h2",{className:"card-title flex items-center gap-2",children:[(0,t.jsx)(d,{className:"w-6 h-6 text-secondary"}),"Start New Session"]}),(0,t.jsxs)("div",{className:"mt-4 space-y-6",children:[(0,t.jsxs)("div",{className:"space-y-3",children:[(0,t.jsxs)("button",{type:"button",className:"btn btn-ghost btn-sm px-2 h-auto min-h-0 normal-case justify-start gap-2",onClick:()=>eb(e=>!e),children:[(0,t.jsx)(c,{className:`w-4 h-4 transition-transform ${ex?"rotate-90":""}`}),ex?"Hide Session Setup":e2]}),ex&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsxs)("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:[(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsx)("label",{className:"text-sm font-medium opacity-70",children:"Agent Provider"}),(0,t.jsxs)("div",{className:"join w-full",children:[(0,t.jsx)("div",{className:"join-item bg-base-300 flex items-center px-3 border border-base-content/20 border-r-0",children:(0,t.jsx)(d,{className:"w-4 h-4"})}),(0,t.jsx)("select",{className:"select select-bordered join-item w-full focus:outline-none",value:ec?.cli||"",onChange:ta,disabled:eL,children:_.map(e=>(0,t.jsx)("option",{value:e.cli,children:e.name},e.cli))})]}),ec?.description&&(0,t.jsx)("p",{className:"text-[10px] opacity-60 mt-1 pl-1 italic leading-tight",children:ec.description})]}),(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsx)("label",{className:"text-sm font-medium opacity-70",children:"Model"}),(0,t.jsxs)("div",{className:"join w-full",children:[(0,t.jsx)("div",{className:"join-item bg-base-300 flex items-center px-3 border border-base-content/20 border-r-0",children:(0,t.jsx)(m,{className:"w-4 h-4"})}),(0,t.jsxs)("select",{className:"select select-bordered join-item w-full focus:outline-none",value:ed,onChange:ts,disabled:eL||!ec,children:[(0,t.jsx)("option",{value:"auto",children:"Auto"}),ec?.models.map(e=>(0,t.jsx)("option",{value:e.id,children:e.label},e.id))]})]}),ec?.models.find(e=>e.id===ed)?.description&&(0,t.jsx)("p",{className:"text-[10px] opacity-60 mt-1 pl-1 italic leading-tight",children:ec.models.find(e=>e.id===ed)?.description})]})]}),(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsx)("label",{className:"text-sm font-medium opacity-70",children:"Start up script (Optional)"}),(0,t.jsx)("input",{type:"text",className:"input input-bordered w-full font-mono text-sm",placeholder:"npm i",value:eu,onChange:tr,onBlur:tl,onKeyDown:e=>{(e.metaKey||e.ctrlKey)&&"Enter"===e.key&&(e.preventDefault(),tC())},disabled:eL}),(0,t.jsx)("div",{className:"text-xs opacity-50 px-1",children:"Script to run in the terminal agent iframe upon startup."})]}),(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsx)("label",{className:"text-sm font-medium opacity-70",children:"Dev server script (Optional)"}),(0,t.jsx)("input",{type:"text",className:"input input-bordered w-full font-mono text-sm",placeholder:"npm run dev",value:ep,onChange:e=>{ef(e.target.value)},onBlur:tn,onKeyDown:e=>{(e.metaKey||e.ctrlKey)&&"Enter"===e.key&&(e.preventDefault(),tC())},disabled:eL}),(0,t.jsx)("div",{className:"text-xs opacity-50 px-1",children:"Script for the Session View Start Dev Server button in the right terminal."})]})]})]}),(0,t.jsx)("div",{className:"divider"}),(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsx)("label",{className:"text-sm font-medium opacity-70",children:"Title (Optional)"}),(0,t.jsx)("input",{type:"text",className:"input input-bordered w-full font-mono text-sm",placeholder:"Task Title",value:ey,onChange:e=>ew(e.target.value),onKeyDown:e=>{(e.metaKey||e.ctrlKey)&&"Enter"===e.key&&(e.preventDefault(),tC())},disabled:eL})]}),(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsx)("label",{className:"text-sm font-medium opacity-70",children:"Initial Message (Optional)"}),(0,t.jsxs)("div",{className:"relative",children:[(0,t.jsx)("textarea",{className:"textarea textarea-bordered w-full h-64 font-mono text-sm leading-tight resize-none",placeholder:"Describe what you want the agent to do... Type @ to mention files.",value:eg,onChange:tw,onKeyDown:e=>{if((e.metaKey||e.ctrlKey)&&"Enter"===e.key){e.preventDefault(),tC();return}td&&tu.length>0&&("ArrowUp"===e.key?(e.preventDefault(),tg(e=>e>0?e-1:tu.length-1)):"ArrowDown"===e.key?(e.preventDefault(),tg(e=>e<tu.length-1?e+1:0)):"Enter"===e.key||"Tab"===e.key?(e.preventDefault(),tj(tu[tb])):"Escape"===e.key&&(e.preventDefault(),tm(!1)))},onClick:e=>{tx(e.currentTarget.selectionStart),tm(!1)},onKeyUp:e=>tx(e.currentTarget.selectionStart),disabled:eL}),td&&tu.length>0&&(0,t.jsx)("div",{className:"absolute left-0 right-0 z-50 mt-1 max-h-48 overflow-y-auto bg-base-100 border border-base-300 rounded-md shadow-lg",children:tu.map((e,a)=>(0,t.jsx)("button",{className:`w-full text-left px-3 py-2 text-xs border-b border-base-200 last:border-0 truncate ${a===tb?"bg-primary text-primary-content":"hover:bg-primary/10"}`,onMouseDown:t=>{t.preventDefault(),tj(e)},children:e},e))})]})]}),(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsx)("label",{className:"text-sm font-medium opacity-70",children:"Attachments (Optional)"}),(0,t.jsx)("input",{type:"file",multiple:!0,className:"file-input file-input-bordered w-full",onChange:e=>{e.target.files&&(to(Array.from(e.target.files).map((e,t)=>tc(e,t))),e.target.value="")},disabled:eL}),(0,t.jsx)("div",{className:"text-xs opacity-50 px-1",children:"Paste files from clipboard with Cmd/Ctrl+V anywhere on this page."}),ej.length>0&&(0,t.jsx)("div",{className:"flex flex-wrap gap-2 mt-2",children:ej.map((e,a)=>(0,t.jsxs)("span",{className:"badge badge-neutral gap-2 p-3",children:[e.name,(0,t.jsx)("button",{onClick:()=>{eN(e=>e.filter((e,t)=>t!==a))},className:"btn btn-ghost btn-xs btn-circle text-error",children:(0,t.jsx)(n,{className:"w-3 h-3"})})]},`upload-${a}`))}),eS.length>0&&(0,t.jsx)("div",{className:"flex flex-wrap gap-2 mt-2",children:eS.map((e,a)=>(0,t.jsxs)("span",{className:"badge badge-secondary gap-2 p-3",children:[e,(0,t.jsx)("button",{onClick:()=>{ek(e=>e.filter((e,t)=>t!==a))},className:"btn btn-ghost btn-xs btn-circle text-error",title:"Remove carried attachment",children:(0,t.jsx)(n,{className:"w-3 h-3"})})]},`prefill-${e}-${a}`))})]}),(0,t.jsx)("div",{className:"card-actions justify-end mt-4",children:(0,t.jsx)("button",{className:"btn btn-primary btn-wide shadow-lg",onClick:tC,disabled:eL,children:eL?(0,t.jsx)("span",{className:"loading loading-spinner"}):"Start Session"})})]})]})})]})]}),"new"===e&&!Q&&(0,t.jsx)("div",{className:"card w-full max-w-2xl bg-base-200 shadow-xl",children:(0,t.jsxs)("div",{className:"card-body",children:[e$&&(0,t.jsx)("div",{className:"alert alert-error text-sm py-2 px-3",children:e$}),(0,t.jsx)("h2",{className:"card-title",children:"Select a Repository"}),(0,t.jsx)("p",{className:"opacity-70 text-sm",children:"Choose a repository first, then start or resume a session."}),(0,t.jsx)("div",{className:"card-actions justify-end mt-4",children:(0,t.jsx)("button",{className:"btn btn-primary",onClick:()=>Z.push("/"),children:"Go to Home"})})]})}),"new"===e&&eB&&eG&&(0,t.jsx)("div",{className:"fixed inset-0 z-[1000] flex items-center justify-center bg-base-content/45 px-4",children:(0,t.jsx)("div",{className:"w-full max-w-md rounded-xl border border-base-300 bg-base-100 p-6 shadow-2xl",children:(0,t.jsxs)("div",{className:"flex items-center gap-4",children:[(0,t.jsx)("span",{className:"loading loading-spinner loading-lg text-primary"}),(0,t.jsxs)("div",{className:"space-y-1",children:[(0,t.jsxs)("h3",{className:"text-lg font-semibold",children:["Installing ",Y[eG]]}),(0,t.jsx)("p",{className:"text-sm opacity-70",children:"Please wait while we install the coding agent CLI."})]})]})})}),"new"===e&&eV&&e_&&(0,t.jsx)("div",{className:"fixed inset-0 z-[1001] flex items-center justify-center bg-base-content/60 p-4",children:(0,t.jsx)("div",{className:"w-full max-w-5xl rounded-xl border border-base-300 bg-base-100 shadow-2xl",children:(0,t.jsxs)("div",{className:"space-y-4 p-5 md:p-6",children:[(0,t.jsx)("h3",{className:"text-xl font-semibold",children:"Login Required"}),(0,t.jsxs)("p",{className:"text-sm opacity-80",children:[Y[e_]," has been installed. Complete login in the terminal below, then click Done to continue."]}),(0,t.jsxs)("p",{className:"text-xs opacity-60",children:["Command: ",(0,t.jsx)("span",{className:"font-mono",children:eW})]}),(0,t.jsx)("div",{className:"h-[420px] overflow-hidden rounded-lg border border-base-300 bg-base-200",children:(0,t.jsx)("iframe",{ref:e0,src:"/terminal",className:"h-full w-full border-none",allow:"clipboard-read; clipboard-write",onLoad:tS})}),eX&&(0,t.jsx)("div",{className:"alert alert-error text-sm py-2",children:eX}),!eX&&(0,t.jsx)("div",{className:"text-xs opacity-70",children:eJ?"Login command was sent to the terminal automatically.":"Waiting for terminal to initialize..."}),(0,t.jsx)("div",{className:"flex justify-end",children:(0,t.jsx)("button",{className:"btn btn-primary",onClick:()=>void tM(),disabled:eL,children:"Done"})})]})})}),"new"===e&&!Q&&(!s||!!e$)&&(0,t.jsx)("div",{className:"card w-full max-w-2xl bg-base-200 shadow-xl",children:(0,t.jsxs)("div",{className:"card-body",children:[(0,t.jsxs)("h2",{className:"card-title flex items-center gap-2",children:[(0,t.jsx)(r,{className:"w-6 h-6 text-primary"}),"Git Repository Selector"]}),eA?(0,t.jsxs)("div",{className:"alert text-sm py-2 px-3 mt-2 flex items-center gap-2",children:[(0,t.jsx)("span",{className:"loading loading-spinner loading-sm"}),p?`Searching for repository "${p}"...`:"Searching for repository..."]}):e$?(0,t.jsx)("div",{className:"alert alert-error text-sm py-2 px-3 mt-2",children:e$}):(0,t.jsx)("div",{className:"text-sm opacity-70 mt-2",children:"No repository specified."}),(0,t.jsx)("div",{className:"mt-4",children:(0,t.jsx)("button",{className:"btn btn-primary btn-sm",onClick:()=>Z.push("/"),children:"Choose Repository"})})]})}),"home"===e&&x&&(0,t.jsx)(j,{initialPath:y?.defaultRoot||void 0,onSelect:e6,onCancel:()=>b(!1),checkRepo:N}),"home"===e&&g&&(0,t.jsx)(j,{title:"Default Root Folder",initialPath:y?.defaultRoot||void 0,onSelect:e9,onCancel:()=>v(!1)})]})}e.s(["default",()=>J],5951)}]);
|