@tickernelz/wardmote-ui 2026.1108.1 → 2026.1109.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/dist/assets/{CompanyExport-DUnuQia9.js → CompanyExport-CYFxCC1Q.js} +2 -2
- package/dist/assets/{Terminal-D1ruwJKK.js → Terminal-D1sTHQz6.js} +1 -1
- package/dist/assets/{clipboard-oERS_NGj.js → clipboard-CxyEkvoK.js} +2 -2
- package/dist/assets/{dist-B8zM63sM.js → dist-ADmyJC_l.js} +1 -1
- package/dist/assets/{dist-BsvRtKyc.js → dist-B-HzyktT.js} +1 -1
- package/dist/assets/{dist-BIH3XOAA.js → dist-BFga0g2x.js} +1 -1
- package/dist/assets/{dist-BxPHMXlf.js → dist-BaK4o7bx.js} +1 -1
- package/dist/assets/{dist-B6VGqBMw.js → dist-BiCFUZfM.js} +1 -1
- package/dist/assets/{dist-Do3PUu3w.js → dist-CIoBkeiq.js} +1 -1
- package/dist/assets/{dist-8AduNOQx.js → dist-CJbhfiNe.js} +1 -1
- package/dist/assets/{dist-CfUv27eg.js → dist-CZszqimh.js} +1 -1
- package/dist/assets/{dist-CGwpvx3Z.js → dist-CcGiAOx5.js} +1 -1
- package/dist/assets/{dist-DeYTUba7.js → dist-DSh9Dw6X.js} +1 -1
- package/dist/assets/{dist-DTvLpQIg.js → dist-DbicEUjQ.js} +1 -1
- package/dist/assets/{dist-BM1c6ixo.js → dist-DdOpxUxb.js} +1 -1
- package/dist/assets/{dist-C_VeG_Q6.js → dist-DjLR87Xu.js} +1 -1
- package/dist/assets/{dist-Dmjj6qqj.js → dist-DmAaaBQr.js} +1 -1
- package/dist/assets/{dist-DtHqErgw.js → dist-DoyNzsOy.js} +1 -1
- package/dist/assets/{dist-BlthiXtb.js → dist-EhfI7z6A.js} +1 -1
- package/dist/assets/{dist-DMD4VbFv.js → dist-FvdhiKSj.js} +1 -1
- package/dist/assets/{dist-Ca2ao84r.js → dist-SsWiWYLA.js} +1 -1
- package/dist/assets/{dist-DwulSeaC.js → dist-XkY8-Aoh.js} +1 -1
- package/dist/assets/{dist-C518NMMv.js → dist-YRhRUevc.js} +1 -1
- package/dist/assets/{dist-B0W7Yi42.js → dist-r5__r9vw.js} +1 -1
- package/dist/assets/{dist-CcZe9JAO.js → dist-rLXyysom.js} +1 -1
- package/dist/assets/{dist-BOfv8ix1.js → dist-sxtw4GAs.js} +1 -1
- package/dist/assets/{dist-BlfE4iqp.js → dist-vVWPSW6f.js} +1 -1
- package/dist/assets/{index-CKKKBvW4.js → index-Cs83aobu.js} +240 -240
- package/dist/assets/index-DkK79TGw.css +2 -0
- package/dist/assets/{mention-chips-BKRdYPgz.js → mention-chips-s9KWPIZD.js} +1 -1
- package/dist/assets/x-CRY3o83U.js +134 -0
- package/dist/downloads/local-browser-chromium.zip +0 -0
- package/dist/downloads/local-browser-firefox-unsigned.zip +0 -0
- package/dist/downloads/local-browser-firefox.xpi +0 -0
- package/dist/index.html +10 -10
- package/dist/sw.js +1 -1
- package/package.json +1 -1
- package/dist/assets/index-CYb_Lk-W.css +0 -1
- package/dist/assets/x-CzBf9g0R.js +0 -134
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
var Bn=Object.defineProperty;var a=(e,t)=>Bn(e,"name",{value:t,configurable:!0});import{i as Nt}from"./rolldown-runtime-ZpX3ckPj.js";import{Bo as Un,Ct as ce,F as zn,Ha as p,K as V,Lo as Fn,Ro as qn,Ua as Hn,Va as Wn,Wa as Vn,ao as Kn,d as Qn,gt as Jn,i as Gn,ja as Yn,l as Xn,mt as Zn,n as ea,o as ta,r as x,u as ra}from"./x-CzBf9g0R.js";import{t as na}from"./preload-helper-CceJXRIF.js";var i=Nt(Un(),1),He=/^(?:[a-z][a-z0-9+.-]*:|[\\/]{2})/i,Bt=/^[\\/]{2}/;function aa(e,t){return t+e.replace(/\\/g,"/")}a(aa,"normalizeProtocolRelativeUrl");var it="popstate";function lt(e){return typeof e=="object"&&e!=null&&"pathname"in e&&"search"in e&&"hash"in e&&"state"in e&&"key"in e}a(lt,"isLocation");function oa(e={}){function t(n,o){let s=o.state?.masked,{pathname:l,search:u,hash:c}=s||n.location;return Oe("",{pathname:l,search:u,hash:c},o.state&&o.state.usr||null,o.state&&o.state.key||"default",s?{pathname:n.location.pathname,search:n.location.search,hash:n.location.hash}:void 0)}a(t,"createBrowserLocation");function r(n,o){return typeof o=="string"?o:K(o)}return a(r,"createBrowserHref"),ia(t,r,null,e)}a(oa,"createBrowserHistory");function C(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}a(C,"invariant");function T(e,t){if(!e)try{throw new Error(t)}catch{}}a(T,"warning");function sa(){return Math.random().toString(36).substring(2,10)}a(sa,"createKey");function ut(e,t){return{usr:e.state,key:e.key,idx:t,masked:e.mask?{pathname:e.pathname,search:e.search,hash:e.hash}:void 0}}a(ut,"getHistoryState");function Oe(e,t,r=null,n,o){return{pathname:typeof e=="string"?e:e.pathname,search:"",hash:"",...typeof t=="string"?ee(t):t,state:r,key:t&&t.key||n||sa(),mask:o}}a(Oe,"createLocation");function K({pathname:e="/",search:t="",hash:r=""}){return t&&t!=="?"&&(e+=t.charAt(0)==="?"?t:"?"+t),r&&r!=="#"&&(e+=r.charAt(0)==="#"?r:"#"+r),e}a(K,"createPath");function ee(e){let t={};if(e){let r=e.indexOf("#");r>=0&&(t.hash=e.substring(r),e=e.substring(0,r));let n=e.indexOf("?");n>=0&&(t.search=e.substring(n),e=e.substring(0,n)),e&&(t.pathname=e)}return t}a(ee,"parsePath");function ia(e,t,r,n={}){let{window:o=document.defaultView,v5Compat:s=!1}=n,l=o.history,u="POP",c=null,d=f();d==null&&(d=0,l.replaceState({...l.state,idx:d},""));function f(){return(l.state||{idx:null}).idx}a(f,"getIndex");function m(){u="POP";let h=f(),k=h==null?null:h-d;d=h,c&&c({action:u,location:y.location,delta:k})}a(m,"handlePop");function g(h,k){u="PUSH";let w=lt(h)?h:Oe(y.location,h,k);r&&r(w,h),d=f()+1;let I=ut(w,d),$=y.createHref(w.mask||w);try{l.pushState(I,"",$)}catch(E){if(E instanceof DOMException&&E.name==="DataCloneError")throw E;o.location.assign($)}s&&c&&c({action:u,location:y.location,delta:1})}a(g,"push");function v(h,k){u="REPLACE";let w=lt(h)?h:Oe(y.location,h,k);r&&r(w,h),d=f();let I=ut(w,d),$=y.createHref(w.mask||w);l.replaceState(I,"",$),s&&c&&c({action:u,location:y.location,delta:0})}a(v,"replace2");function b(h){return la(o,h)}a(b,"createURL");let y={get action(){return u},get location(){return e(o,l)},listen(h){if(c)throw new Error("A history only accepts one active listener");return o.addEventListener(it,m),c=h,()=>{o.removeEventListener(it,m),c=null}},createHref(h){return t(o,h)},createURL:b,encodeLocation(h){let k=b(h);return{pathname:k.pathname,search:k.search,hash:k.hash}},push:g,replace:v,go(h){return l.go(h)}};return y}a(ia,"getUrlBasedHistory");function la(e,t,r=!1){let n="http://localhost";e&&(n=e.location.origin!=="null"?e.location.origin:e.location.href),C(n,"No window.location.(origin|href) available to create URL");let o=typeof t=="string"?t:K(t);return o=o.replace(/ $/,"%20"),!r&&Bt.test(o)&&(o=n+o),new URL(o,n)}a(la,"createBrowserURLImpl");var ua;ua=new WeakMap;function Ut(e,t,r="/"){return zt(e,t,r,!1)}a(Ut,"matchRoutes");function zt(e,t,r,n,o){let s=F((typeof t=="string"?ee(t):t).pathname||"/",r);if(s==null)return null;let l=o??da(e),u=null,c=wa(s);for(let d=0;u==null&&d<l.length;++d)u=xa(l[d],c,n);return u}a(zt,"matchRoutesImpl");function ca(e,t){let{route:r,pathname:n,params:o}=e;return{id:r.id,pathname:n,params:o,data:t[r.id],loaderData:t[r.id],handle:r.handle}}a(ca,"convertRouteMatchToUiMatch");function da(e){let t=Ft(e);return fa(t),t}a(da,"flattenAndRankRoutes");function Ft(e,t=[],r=[],n="",o=!1){let s=a((l,u,c=o,d)=>{let f={relativePath:d===void 0?l.path||"":d,caseSensitive:l.caseSensitive===!0,childrenIndex:u,route:l};if(f.relativePath.startsWith("/")){if(!f.relativePath.startsWith(n)&&c)return;C(f.relativePath.startsWith(n),`Absolute route path "${f.relativePath}" nested under path "${n}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),f.relativePath=f.relativePath.slice(n.length)}let m=N([n,f.relativePath]),g=r.concat(f);l.children&&l.children.length>0&&(C(l.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${m}".`),Ft(l.children,t,g,m,c)),!(l.path==null&&!l.index)&&t.push({path:m,score:va(m,l.index),routesMeta:g.map((v,b)=>{let[y,h]=Wt(v.relativePath,v.caseSensitive,b===g.length-1);return{...v,matcher:y,compiledParams:h}})})},"flattenRoute");return e.forEach((l,u)=>{if(l.path===""||!l.path?.includes("?"))s(l,u);else for(let c of qt(l.path))s(l,u,!0,c)}),t}a(Ft,"flattenRoutes");function qt(e){let t=e.split("/");if(t.length===0)return[];let[r,...n]=t,o=r.endsWith("?"),s=r.replace(/\?$/,"");if(n.length===0)return o?[s,""]:[s];let l=qt(n.join("/")),u=[];return u.push(...l.map(c=>c===""?s:[s,c].join("/"))),o&&u.push(...l),u.map(c=>e.startsWith("/")&&c===""?"/":c)}a(qt,"explodeOptionalSegments");function fa(e){e.sort((t,r)=>t.score!==r.score?r.score-t.score:ka(t.routesMeta.map(n=>n.childrenIndex),r.routesMeta.map(n=>n.childrenIndex)))}a(fa,"rankRouteBranches");var ma=/^:[\w-]+$/,ha=3,pa=2,ga=1,ya=10,ba=-2,ct=a(e=>e==="*","isSplat");function va(e,t){let r=e.split("/"),n=r.length;return r.some(ct)&&(n+=ba),t&&(n+=pa),r.filter(o=>!ct(o)).reduce((o,s)=>o+(ma.test(s)?ha:s===""?ga:ya),n)}a(va,"computeScore");function ka(e,t){return e.length===t.length&&e.slice(0,-1).every((r,n)=>r===t[n])?e[e.length-1]-t[t.length-1]:0}a(ka,"compareIndexes");function xa(e,t,r=!1){let{routesMeta:n}=e,o={},s="/",l=[];for(let u=0;u<n.length;++u){let c=n[u],d=u===n.length-1,f=s==="/"?t:t.slice(s.length)||"/",m={path:c.relativePath,caseSensitive:c.caseSensitive,end:d},g=c.matcher&&c.compiledParams?Ht(m,f,c.matcher,c.compiledParams):ke(m,f),v=c.route;if(!g&&d&&r&&!n[n.length-1].route.index&&(g=ke({path:c.relativePath,caseSensitive:c.caseSensitive,end:!1},f)),!g)return null;Object.assign(o,g.params),l.push({params:o,pathname:N([s,g.pathname]),pathnameBase:Ea(N([s,g.pathnameBase])),route:v}),g.pathnameBase!=="/"&&(s=N([s,g.pathnameBase]))}return l}a(xa,"matchRouteBranch");function ke(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[r,n]=Wt(e.path,e.caseSensitive,e.end);return Ht(e,t,r,n)}a(ke,"matchPath");function Ht(e,t,r,n){let o=t.match(r);if(!o)return null;let s=o[0],l=X(s,1),u=o.slice(1);return{params:n.reduce((c,{paramName:d,isOptional:f},m)=>{if(d==="*"){let v=u[m]||"";l=X(s.slice(0,s.length-v.length),1)}const g=u[m];return f&&!g?c[d]=void 0:c[d]=(g||"").replace(/%2F/g,"/"),c},{}),pathname:s,pathnameBase:l,pattern:e}}a(Ht,"matchPathImpl");function Wt(e,t=!1,r=!0){T(e==="*"||!e.endsWith("*")||e.endsWith("/*"),`Route path "${e}" will be treated as if it were "${e.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${e.replace(/\*$/,"/*")}".`);let n=[],o="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(s,l,u,c,d)=>{if(n.push({paramName:l,isOptional:u!=null}),u){let f=d.charAt(c+s.length);return f&&f!=="/"?"/([^\\/]*)":"(?:/([^\\/]*))?"}return"/([^\\/]+)"}).replace(/\/([\w-]+)\?(\/|$)/g,"(/$1)?$2");return e.endsWith("*")?(n.push({paramName:"*"}),o+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):r?o+="\\/*$":e!==""&&e!=="/"&&(o+="(?:(?=\\/|$))"),[new RegExp(o,t?void 0:"i"),n]}a(Wt,"compilePath");function wa(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return T(!1,`The URL path "${e}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${t}).`),e}}a(wa,"decodePath");function F(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let r=t.endsWith("/")?t.length-1:t.length,n=e.charAt(r);return n&&n!=="/"?null:e.slice(r)||"/"}a(F,"stripBasename");function Sa(e,t="/"){let{pathname:r,search:n="",hash:o=""}=typeof e=="string"?ee(e):e,s;return r?(r=Vt(r),r.startsWith("/")||r.startsWith("\\")?s=dt(r.substring(1),"/"):s=dt(r,t)):s=t,{pathname:s,search:Ra(n),hash:Ca(o)}}a(Sa,"resolvePath");function dt(e,t){let r=X(t).split("/");return e.split("/").forEach(n=>{n===".."?r.length>1&&r.pop():n!=="."&&r.push(n)}),r.length>1?r.join("/"):"/"}a(dt,"resolvePathname");function Me(e,t,r,n){return`Cannot include a '${e}' character in a manually specified \`to.${t}\` field [${JSON.stringify(n)}]. Please separate it out to the \`to.${r}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}a(Me,"getInvalidPathError");function Ia(e){return e.filter((t,r)=>r===0||t.route.path&&t.route.path.length>0)}a(Ia,"getPathContributingMatches");function We(e){let t=Ia(e);return t.map((r,n)=>n===t.length-1?r.pathname:r.pathnameBase)}a(We,"getResolveToMatches");function Ie(e,t,r,n=!1){let o;typeof e=="string"?o=ee(e):(o={...e},C(!o.pathname||!o.pathname.includes("?"),Me("?","pathname","search",o)),C(!o.pathname||!o.pathname.includes("#"),Me("#","pathname","hash",o)),C(!o.search||!o.search.includes("#"),Me("#","search","hash",o)));let s=e===""||o.pathname==="",l=s?"/":o.pathname,u;if(l==null)u=r;else{let m=t.length-1;if(!n&&l.startsWith("..")){let g=l.split("/");for(;g[0]==="..";)g.shift(),m-=1;o.pathname=g.join("/")}u=m>=0?t[m]:"/"}let c=Sa(o,u),d=l&&l!=="/"&&l.endsWith("/"),f=(s||l===".")&&r.endsWith("/");return!c.pathname.endsWith("/")&&(d||f)&&(c.pathname+="/"),c}a(Ie,"resolveTo$1");var Vt=a(e=>e.replace(/[\\/]{2,}/g,"/"),"removeDoubleSlashes"),N=a(e=>Vt(e.join("/")),"joinPaths");function X(e,t=0){let r=e.length;for(;r>t&&e.charCodeAt(r-1)===47;)r--;return r===e.length?e:e.slice(0,r)}a(X,"removeTrailingSlash");var Ea=a(e=>X(e).replace(/^\/*/,"/"),"normalizePathname"),Ra=a(e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,"normalizeSearch"),Ca=a(e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e,"normalizeHash"),$a=class{static{a(this,"ErrorResponseImpl")}constructor(e,t,r,n=!1){this.status=e,this.statusText=t||"",this.internal=n,r instanceof Error?(this.data=r.toString(),this.error=r):this.data=r}};function Kt(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}a(Kt,"isRouteErrorResponse");function _a(e){return N(e.map(t=>t.route.path).filter(Boolean))||"/"}a(_a,"getRoutePattern");var Qt=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function Jt(e,t){let r=e;if(typeof r!="string"||!He.test(r))return{absoluteURL:void 0,isExternal:!1,to:r};let n=r,o=!1;if(Qt)try{let s=new URL(window.location.href),l=Bt.test(r)?new URL(aa(r,s.protocol)):new URL(r),u=F(l.pathname,t);l.origin===s.origin&&u!=null?r=u+l.search+l.hash:o=!0}catch{T(!1,`<Link to="${r}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}return{absoluteURL:n,isExternal:o,to:r}}a(Jt,"parseToInfo");var ll=Object.getOwnPropertyNames(Object.prototype).sort().join("\0"),ft=new URL("http://localhost");function Ve(e){if(e.createURL)return e.createURL("/");try{return new URL(e.createHref("/"),ft)}catch{return ft}}a(Ve,"getNavigatorCurrentUrl");function Te(e,t){return e.origin===t.origin&&(e.origin!=="null"||e.protocol===t.protocol&&e.host===t.host)}a(Te,"isSameOrigin");function Da(e,t){if(e.startsWith("//"))return!0;let r=t.protocol.toLowerCase();return e.toLowerCase().startsWith(r)?t.host===""||e.slice(r.length).startsWith("//"):!1}a(Da,"isExplicitUrl");function Ke(e,t,r,n){let o=null;try{o=e==null?null:new URL(e,r)}catch{}let s=new URL(t,r),l=o!=null&&!Te(o,r),u=!Te(s,r);if(n==="reject"){if(l||u)throw new Error("External navigation is not allowed")}else if(u&&(o==null||!Da(e,o)||!Te(o,s)))throw new Error("External navigation is not allowed")}a(Ke,"validateNavigationTarget");var Gt=["POST","PUT","PATCH","DELETE"],ul=new Set(Gt),Aa=["GET",...Gt],cl=new Set(Aa),Ma,Ta,Pa,La;Ma=new WeakMap;Ta=new WeakMap;Pa=new WeakMap;La=new WeakMap;var Oa=["about:","blob:","chrome:","chrome-untrusted:","content:","data:","devtools:","file:","filesystem:","javascript:"];function ja(e){try{return Oa.includes(new URL(e).protocol)}catch{return!1}}a(ja,"hasInvalidProtocol");var te=i.createContext(null);te.displayName="DataRouter";var de=i.createContext(null);de.displayName="DataRouterState";var Yt=i.createContext(!1);function Xt(){return i.useContext(Yt)}a(Xt,"useIsRSCRouterContext");var Zt=i.createContext({isTransitioning:!1});Zt.displayName="ViewTransition";var Na=i.createContext(new Map);Na.displayName="Fetchers";var je=i.createContext(null);je.displayName="Await";var A=i.createContext(null);A.displayName="Navigation";var re=i.createContext(null);re.displayName="Location";var O=i.createContext({outlet:null,matches:[],isDataRoute:!1});O.displayName="Route";var Qe=i.createContext(null);Qe.displayName="RouteError";var er="REACT_ROUTER_ERROR",Ba="REDIRECT",Ua="ROUTE_ERROR_RESPONSE";function za(e){if(e.startsWith(`${er}:${Ba}:{`))try{let t=JSON.parse(e.slice(28));if(typeof t=="object"&&t&&typeof t.status=="number"&&typeof t.statusText=="string"&&typeof t.location=="string"&&typeof t.reloadDocument=="boolean"&&typeof t.replace=="boolean")return t}catch{}}a(za,"decodeRedirectErrorDigest");function Fa(e){if(e.startsWith(`${er}:${Ua}:{`))try{let t=JSON.parse(e.slice(40));if(typeof t=="object"&&t&&typeof t.status=="number"&&typeof t.statusText=="string")return new $a(t.status,t.statusText,t.data)}catch{}}a(Fa,"decodeRouteErrorResponseDigest");function qa(e,{relative:t}={}){C(ne(),"useHref() may be used only in the context of a <Router> component.");let{basename:r,navigator:n}=i.useContext(A),{hash:o,pathname:s,search:l}=fe(e,{relative:t}),u=s;return r!=="/"&&(u=s==="/"?r:N([r,s])),n.createHref({pathname:u,search:l,hash:o})}a(qa,"useHref");function ne(){return i.useContext(re)!=null}a(ne,"useInRouterContext");function P(){return C(ne(),"useLocation() may be used only in the context of a <Router> component."),i.useContext(re).location}a(P,"useLocation");function dl(){return i.useContext(re).navigationType}a(dl,"useNavigationType");var tr="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function rr(e){i.useContext(A).static||i.useLayoutEffect(e)}a(rr,"useIsomorphicLayoutEffect");function Ee(){let{isDataRoute:e}=i.useContext(O);return e?oo():Ha()}a(Ee,"useNavigate$1");function Ha(){C(ne(),"useNavigate() may be used only in the context of a <Router> component.");let e=i.useContext(te),{basename:t,navigator:r}=i.useContext(A),{matches:n}=i.useContext(O),{pathname:o}=P(),s=JSON.stringify(We(n)),l=i.useRef(!1);return rr(()=>{l.current=!0}),i.useCallback((u,c={})=>{if(T(l.current,tr),!l.current)return;if(typeof u=="number"){r.go(u);return}let d=Ie(u,JSON.parse(s),o,c.relative==="path");e==null&&t!=="/"&&(d.pathname=d.pathname==="/"?t:N([t,d.pathname])),Ke(typeof u=="string"?u:K(u),r.createHref(d),Ve(r),"reject"),(c.replace?r.replace:r.push)(d,c.state,c)},[t,r,s,o,e])}a(Ha,"useNavigateUnstable");var Wa=i.createContext(null);function Va(e){let t=i.useContext(O).outlet;return i.useMemo(()=>t&&i.createElement(Wa.Provider,{value:e},t),[t,e])}a(Va,"useOutlet");function Ka(){let{matches:e}=i.useContext(O);return e[e.length-1]?.params??{}}a(Ka,"useParams");function fe(e,{relative:t}={}){let{matches:r}=i.useContext(O),{pathname:n}=P(),o=JSON.stringify(We(r));return i.useMemo(()=>Ie(e,JSON.parse(o),n,t==="path"),[e,o,n,t])}a(fe,"useResolvedPath");function Qa(e,t){return nr(e,t)}a(Qa,"useRoutes");function nr(e,t,r){C(ne(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:n}=i.useContext(A),{matches:o}=i.useContext(O),s=o[o.length-1],l=s?s.params:{},u=s?s.pathname:"/",c=s?s.pathnameBase:"/",d=s&&s.route;{let h=d&&d.path||"";sr(u,!d||h.endsWith("*")||h.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${u}" (under <Route path="${h}">) but the parent route path has no trailing "*". This means if you navigate deeper, the parent won't match anymore and therefore the child routes will never render.
|
|
1
|
+
var Bn=Object.defineProperty;var a=(e,t)=>Bn(e,"name",{value:t,configurable:!0});import{i as Nt}from"./rolldown-runtime-ZpX3ckPj.js";import{Aa as Un,Ba as zn,Ct as ce,F as Fn,Fo as qn,Ha as Hn,Io as Wn,K as V,Ro as Vn,Ua as Kn,Va as p,d as Qn,gt as Jn,i as Gn,l as Yn,mt as Xn,n as Zn,o as ea,r as x,ro as ta,u as ra}from"./x-CRY3o83U.js";import{t as na}from"./preload-helper-CceJXRIF.js";var i=Nt(Vn(),1),He=/^(?:[a-z][a-z0-9+.-]*:|[\\/]{2})/i,Bt=/^[\\/]{2}/;function aa(e,t){return t+e.replace(/\\/g,"/")}a(aa,"normalizeProtocolRelativeUrl");var it="popstate";function lt(e){return typeof e=="object"&&e!=null&&"pathname"in e&&"search"in e&&"hash"in e&&"state"in e&&"key"in e}a(lt,"isLocation");function oa(e={}){function t(n,o){let s=o.state?.masked,{pathname:l,search:u,hash:c}=s||n.location;return Oe("",{pathname:l,search:u,hash:c},o.state&&o.state.usr||null,o.state&&o.state.key||"default",s?{pathname:n.location.pathname,search:n.location.search,hash:n.location.hash}:void 0)}a(t,"createBrowserLocation");function r(n,o){return typeof o=="string"?o:K(o)}return a(r,"createBrowserHref"),ia(t,r,null,e)}a(oa,"createBrowserHistory");function C(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}a(C,"invariant");function T(e,t){if(!e)try{throw new Error(t)}catch{}}a(T,"warning");function sa(){return Math.random().toString(36).substring(2,10)}a(sa,"createKey");function ut(e,t){return{usr:e.state,key:e.key,idx:t,masked:e.mask?{pathname:e.pathname,search:e.search,hash:e.hash}:void 0}}a(ut,"getHistoryState");function Oe(e,t,r=null,n,o){return{pathname:typeof e=="string"?e:e.pathname,search:"",hash:"",...typeof t=="string"?ee(t):t,state:r,key:t&&t.key||n||sa(),mask:o}}a(Oe,"createLocation");function K({pathname:e="/",search:t="",hash:r=""}){return t&&t!=="?"&&(e+=t.charAt(0)==="?"?t:"?"+t),r&&r!=="#"&&(e+=r.charAt(0)==="#"?r:"#"+r),e}a(K,"createPath");function ee(e){let t={};if(e){let r=e.indexOf("#");r>=0&&(t.hash=e.substring(r),e=e.substring(0,r));let n=e.indexOf("?");n>=0&&(t.search=e.substring(n),e=e.substring(0,n)),e&&(t.pathname=e)}return t}a(ee,"parsePath");function ia(e,t,r,n={}){let{window:o=document.defaultView,v5Compat:s=!1}=n,l=o.history,u="POP",c=null,d=f();d==null&&(d=0,l.replaceState({...l.state,idx:d},""));function f(){return(l.state||{idx:null}).idx}a(f,"getIndex");function m(){u="POP";let h=f(),k=h==null?null:h-d;d=h,c&&c({action:u,location:y.location,delta:k})}a(m,"handlePop");function g(h,k){u="PUSH";let w=lt(h)?h:Oe(y.location,h,k);r&&r(w,h),d=f()+1;let I=ut(w,d),$=y.createHref(w.mask||w);try{l.pushState(I,"",$)}catch(E){if(E instanceof DOMException&&E.name==="DataCloneError")throw E;o.location.assign($)}s&&c&&c({action:u,location:y.location,delta:1})}a(g,"push");function v(h,k){u="REPLACE";let w=lt(h)?h:Oe(y.location,h,k);r&&r(w,h),d=f();let I=ut(w,d),$=y.createHref(w.mask||w);l.replaceState(I,"",$),s&&c&&c({action:u,location:y.location,delta:0})}a(v,"replace2");function b(h){return la(o,h)}a(b,"createURL");let y={get action(){return u},get location(){return e(o,l)},listen(h){if(c)throw new Error("A history only accepts one active listener");return o.addEventListener(it,m),c=h,()=>{o.removeEventListener(it,m),c=null}},createHref(h){return t(o,h)},createURL:b,encodeLocation(h){let k=b(h);return{pathname:k.pathname,search:k.search,hash:k.hash}},push:g,replace:v,go(h){return l.go(h)}};return y}a(ia,"getUrlBasedHistory");function la(e,t,r=!1){let n="http://localhost";e&&(n=e.location.origin!=="null"?e.location.origin:e.location.href),C(n,"No window.location.(origin|href) available to create URL");let o=typeof t=="string"?t:K(t);return o=o.replace(/ $/,"%20"),!r&&Bt.test(o)&&(o=n+o),new URL(o,n)}a(la,"createBrowserURLImpl");var ua;ua=new WeakMap;function Ut(e,t,r="/"){return zt(e,t,r,!1)}a(Ut,"matchRoutes");function zt(e,t,r,n,o){let s=F((typeof t=="string"?ee(t):t).pathname||"/",r);if(s==null)return null;let l=o??da(e),u=null,c=wa(s);for(let d=0;u==null&&d<l.length;++d)u=xa(l[d],c,n);return u}a(zt,"matchRoutesImpl");function ca(e,t){let{route:r,pathname:n,params:o}=e;return{id:r.id,pathname:n,params:o,data:t[r.id],loaderData:t[r.id],handle:r.handle}}a(ca,"convertRouteMatchToUiMatch");function da(e){let t=Ft(e);return fa(t),t}a(da,"flattenAndRankRoutes");function Ft(e,t=[],r=[],n="",o=!1){let s=a((l,u,c=o,d)=>{let f={relativePath:d===void 0?l.path||"":d,caseSensitive:l.caseSensitive===!0,childrenIndex:u,route:l};if(f.relativePath.startsWith("/")){if(!f.relativePath.startsWith(n)&&c)return;C(f.relativePath.startsWith(n),`Absolute route path "${f.relativePath}" nested under path "${n}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),f.relativePath=f.relativePath.slice(n.length)}let m=N([n,f.relativePath]),g=r.concat(f);l.children&&l.children.length>0&&(C(l.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${m}".`),Ft(l.children,t,g,m,c)),!(l.path==null&&!l.index)&&t.push({path:m,score:va(m,l.index),routesMeta:g.map((v,b)=>{let[y,h]=Wt(v.relativePath,v.caseSensitive,b===g.length-1);return{...v,matcher:y,compiledParams:h}})})},"flattenRoute");return e.forEach((l,u)=>{if(l.path===""||!l.path?.includes("?"))s(l,u);else for(let c of qt(l.path))s(l,u,!0,c)}),t}a(Ft,"flattenRoutes");function qt(e){let t=e.split("/");if(t.length===0)return[];let[r,...n]=t,o=r.endsWith("?"),s=r.replace(/\?$/,"");if(n.length===0)return o?[s,""]:[s];let l=qt(n.join("/")),u=[];return u.push(...l.map(c=>c===""?s:[s,c].join("/"))),o&&u.push(...l),u.map(c=>e.startsWith("/")&&c===""?"/":c)}a(qt,"explodeOptionalSegments");function fa(e){e.sort((t,r)=>t.score!==r.score?r.score-t.score:ka(t.routesMeta.map(n=>n.childrenIndex),r.routesMeta.map(n=>n.childrenIndex)))}a(fa,"rankRouteBranches");var ma=/^:[\w-]+$/,ha=3,pa=2,ga=1,ya=10,ba=-2,ct=a(e=>e==="*","isSplat");function va(e,t){let r=e.split("/"),n=r.length;return r.some(ct)&&(n+=ba),t&&(n+=pa),r.filter(o=>!ct(o)).reduce((o,s)=>o+(ma.test(s)?ha:s===""?ga:ya),n)}a(va,"computeScore");function ka(e,t){return e.length===t.length&&e.slice(0,-1).every((r,n)=>r===t[n])?e[e.length-1]-t[t.length-1]:0}a(ka,"compareIndexes");function xa(e,t,r=!1){let{routesMeta:n}=e,o={},s="/",l=[];for(let u=0;u<n.length;++u){let c=n[u],d=u===n.length-1,f=s==="/"?t:t.slice(s.length)||"/",m={path:c.relativePath,caseSensitive:c.caseSensitive,end:d},g=c.matcher&&c.compiledParams?Ht(m,f,c.matcher,c.compiledParams):ke(m,f),v=c.route;if(!g&&d&&r&&!n[n.length-1].route.index&&(g=ke({path:c.relativePath,caseSensitive:c.caseSensitive,end:!1},f)),!g)return null;Object.assign(o,g.params),l.push({params:o,pathname:N([s,g.pathname]),pathnameBase:Ea(N([s,g.pathnameBase])),route:v}),g.pathnameBase!=="/"&&(s=N([s,g.pathnameBase]))}return l}a(xa,"matchRouteBranch");function ke(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[r,n]=Wt(e.path,e.caseSensitive,e.end);return Ht(e,t,r,n)}a(ke,"matchPath");function Ht(e,t,r,n){let o=t.match(r);if(!o)return null;let s=o[0],l=X(s,1),u=o.slice(1);return{params:n.reduce((c,{paramName:d,isOptional:f},m)=>{if(d==="*"){let v=u[m]||"";l=X(s.slice(0,s.length-v.length),1)}const g=u[m];return f&&!g?c[d]=void 0:c[d]=(g||"").replace(/%2F/g,"/"),c},{}),pathname:s,pathnameBase:l,pattern:e}}a(Ht,"matchPathImpl");function Wt(e,t=!1,r=!0){T(e==="*"||!e.endsWith("*")||e.endsWith("/*"),`Route path "${e}" will be treated as if it were "${e.replace(/\*$/,"/*")}" because the \`*\` character must always follow a \`/\` in the pattern. To get rid of this warning, please change the route path to "${e.replace(/\*$/,"/*")}".`);let n=[],o="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(s,l,u,c,d)=>{if(n.push({paramName:l,isOptional:u!=null}),u){let f=d.charAt(c+s.length);return f&&f!=="/"?"/([^\\/]*)":"(?:/([^\\/]*))?"}return"/([^\\/]+)"}).replace(/\/([\w-]+)\?(\/|$)/g,"(/$1)?$2");return e.endsWith("*")?(n.push({paramName:"*"}),o+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):r?o+="\\/*$":e!==""&&e!=="/"&&(o+="(?:(?=\\/|$))"),[new RegExp(o,t?void 0:"i"),n]}a(Wt,"compilePath");function wa(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return T(!1,`The URL path "${e}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${t}).`),e}}a(wa,"decodePath");function F(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let r=t.endsWith("/")?t.length-1:t.length,n=e.charAt(r);return n&&n!=="/"?null:e.slice(r)||"/"}a(F,"stripBasename");function Sa(e,t="/"){let{pathname:r,search:n="",hash:o=""}=typeof e=="string"?ee(e):e,s;return r?(r=Vt(r),r.startsWith("/")||r.startsWith("\\")?s=dt(r.substring(1),"/"):s=dt(r,t)):s=t,{pathname:s,search:Ra(n),hash:Ca(o)}}a(Sa,"resolvePath");function dt(e,t){let r=X(t).split("/");return e.split("/").forEach(n=>{n===".."?r.length>1&&r.pop():n!=="."&&r.push(n)}),r.length>1?r.join("/"):"/"}a(dt,"resolvePathname");function Me(e,t,r,n){return`Cannot include a '${e}' character in a manually specified \`to.${t}\` field [${JSON.stringify(n)}]. Please separate it out to the \`to.${r}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}a(Me,"getInvalidPathError");function Ia(e){return e.filter((t,r)=>r===0||t.route.path&&t.route.path.length>0)}a(Ia,"getPathContributingMatches");function We(e){let t=Ia(e);return t.map((r,n)=>n===t.length-1?r.pathname:r.pathnameBase)}a(We,"getResolveToMatches");function Ie(e,t,r,n=!1){let o;typeof e=="string"?o=ee(e):(o={...e},C(!o.pathname||!o.pathname.includes("?"),Me("?","pathname","search",o)),C(!o.pathname||!o.pathname.includes("#"),Me("#","pathname","hash",o)),C(!o.search||!o.search.includes("#"),Me("#","search","hash",o)));let s=e===""||o.pathname==="",l=s?"/":o.pathname,u;if(l==null)u=r;else{let m=t.length-1;if(!n&&l.startsWith("..")){let g=l.split("/");for(;g[0]==="..";)g.shift(),m-=1;o.pathname=g.join("/")}u=m>=0?t[m]:"/"}let c=Sa(o,u),d=l&&l!=="/"&&l.endsWith("/"),f=(s||l===".")&&r.endsWith("/");return!c.pathname.endsWith("/")&&(d||f)&&(c.pathname+="/"),c}a(Ie,"resolveTo$1");var Vt=a(e=>e.replace(/[\\/]{2,}/g,"/"),"removeDoubleSlashes"),N=a(e=>Vt(e.join("/")),"joinPaths");function X(e,t=0){let r=e.length;for(;r>t&&e.charCodeAt(r-1)===47;)r--;return r===e.length?e:e.slice(0,r)}a(X,"removeTrailingSlash");var Ea=a(e=>X(e).replace(/^\/*/,"/"),"normalizePathname"),Ra=a(e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,"normalizeSearch"),Ca=a(e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e,"normalizeHash"),$a=class{static{a(this,"ErrorResponseImpl")}constructor(e,t,r,n=!1){this.status=e,this.statusText=t||"",this.internal=n,r instanceof Error?(this.data=r.toString(),this.error=r):this.data=r}};function Kt(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}a(Kt,"isRouteErrorResponse");function _a(e){return N(e.map(t=>t.route.path).filter(Boolean))||"/"}a(_a,"getRoutePattern");var Qt=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function Jt(e,t){let r=e;if(typeof r!="string"||!He.test(r))return{absoluteURL:void 0,isExternal:!1,to:r};let n=r,o=!1;if(Qt)try{let s=new URL(window.location.href),l=Bt.test(r)?new URL(aa(r,s.protocol)):new URL(r),u=F(l.pathname,t);l.origin===s.origin&&u!=null?r=u+l.search+l.hash:o=!0}catch{T(!1,`<Link to="${r}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}return{absoluteURL:n,isExternal:o,to:r}}a(Jt,"parseToInfo");var ll=Object.getOwnPropertyNames(Object.prototype).sort().join("\0"),ft=new URL("http://localhost");function Ve(e){if(e.createURL)return e.createURL("/");try{return new URL(e.createHref("/"),ft)}catch{return ft}}a(Ve,"getNavigatorCurrentUrl");function Te(e,t){return e.origin===t.origin&&(e.origin!=="null"||e.protocol===t.protocol&&e.host===t.host)}a(Te,"isSameOrigin");function Da(e,t){if(e.startsWith("//"))return!0;let r=t.protocol.toLowerCase();return e.toLowerCase().startsWith(r)?t.host===""||e.slice(r.length).startsWith("//"):!1}a(Da,"isExplicitUrl");function Ke(e,t,r,n){let o=null;try{o=e==null?null:new URL(e,r)}catch{}let s=new URL(t,r),l=o!=null&&!Te(o,r),u=!Te(s,r);if(n==="reject"){if(l||u)throw new Error("External navigation is not allowed")}else if(u&&(o==null||!Da(e,o)||!Te(o,s)))throw new Error("External navigation is not allowed")}a(Ke,"validateNavigationTarget");var Gt=["POST","PUT","PATCH","DELETE"],ul=new Set(Gt),Aa=["GET",...Gt],cl=new Set(Aa),Ma,Ta,Pa,La;Ma=new WeakMap;Ta=new WeakMap;Pa=new WeakMap;La=new WeakMap;var Oa=["about:","blob:","chrome:","chrome-untrusted:","content:","data:","devtools:","file:","filesystem:","javascript:"];function ja(e){try{return Oa.includes(new URL(e).protocol)}catch{return!1}}a(ja,"hasInvalidProtocol");var te=i.createContext(null);te.displayName="DataRouter";var de=i.createContext(null);de.displayName="DataRouterState";var Yt=i.createContext(!1);function Xt(){return i.useContext(Yt)}a(Xt,"useIsRSCRouterContext");var Zt=i.createContext({isTransitioning:!1});Zt.displayName="ViewTransition";var Na=i.createContext(new Map);Na.displayName="Fetchers";var je=i.createContext(null);je.displayName="Await";var A=i.createContext(null);A.displayName="Navigation";var re=i.createContext(null);re.displayName="Location";var O=i.createContext({outlet:null,matches:[],isDataRoute:!1});O.displayName="Route";var Qe=i.createContext(null);Qe.displayName="RouteError";var er="REACT_ROUTER_ERROR",Ba="REDIRECT",Ua="ROUTE_ERROR_RESPONSE";function za(e){if(e.startsWith(`${er}:${Ba}:{`))try{let t=JSON.parse(e.slice(28));if(typeof t=="object"&&t&&typeof t.status=="number"&&typeof t.statusText=="string"&&typeof t.location=="string"&&typeof t.reloadDocument=="boolean"&&typeof t.replace=="boolean")return t}catch{}}a(za,"decodeRedirectErrorDigest");function Fa(e){if(e.startsWith(`${er}:${Ua}:{`))try{let t=JSON.parse(e.slice(40));if(typeof t=="object"&&t&&typeof t.status=="number"&&typeof t.statusText=="string")return new $a(t.status,t.statusText,t.data)}catch{}}a(Fa,"decodeRouteErrorResponseDigest");function qa(e,{relative:t}={}){C(ne(),"useHref() may be used only in the context of a <Router> component.");let{basename:r,navigator:n}=i.useContext(A),{hash:o,pathname:s,search:l}=fe(e,{relative:t}),u=s;return r!=="/"&&(u=s==="/"?r:N([r,s])),n.createHref({pathname:u,search:l,hash:o})}a(qa,"useHref");function ne(){return i.useContext(re)!=null}a(ne,"useInRouterContext");function P(){return C(ne(),"useLocation() may be used only in the context of a <Router> component."),i.useContext(re).location}a(P,"useLocation");function dl(){return i.useContext(re).navigationType}a(dl,"useNavigationType");var tr="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function rr(e){i.useContext(A).static||i.useLayoutEffect(e)}a(rr,"useIsomorphicLayoutEffect");function Ee(){let{isDataRoute:e}=i.useContext(O);return e?oo():Ha()}a(Ee,"useNavigate$1");function Ha(){C(ne(),"useNavigate() may be used only in the context of a <Router> component.");let e=i.useContext(te),{basename:t,navigator:r}=i.useContext(A),{matches:n}=i.useContext(O),{pathname:o}=P(),s=JSON.stringify(We(n)),l=i.useRef(!1);return rr(()=>{l.current=!0}),i.useCallback((u,c={})=>{if(T(l.current,tr),!l.current)return;if(typeof u=="number"){r.go(u);return}let d=Ie(u,JSON.parse(s),o,c.relative==="path");e==null&&t!=="/"&&(d.pathname=d.pathname==="/"?t:N([t,d.pathname])),Ke(typeof u=="string"?u:K(u),r.createHref(d),Ve(r),"reject"),(c.replace?r.replace:r.push)(d,c.state,c)},[t,r,s,o,e])}a(Ha,"useNavigateUnstable");var Wa=i.createContext(null);function Va(e){let t=i.useContext(O).outlet;return i.useMemo(()=>t&&i.createElement(Wa.Provider,{value:e},t),[t,e])}a(Va,"useOutlet");function Ka(){let{matches:e}=i.useContext(O);return e[e.length-1]?.params??{}}a(Ka,"useParams");function fe(e,{relative:t}={}){let{matches:r}=i.useContext(O),{pathname:n}=P(),o=JSON.stringify(We(r));return i.useMemo(()=>Ie(e,JSON.parse(o),n,t==="path"),[e,o,n,t])}a(fe,"useResolvedPath");function Qa(e,t){return nr(e,t)}a(Qa,"useRoutes");function nr(e,t,r){C(ne(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:n}=i.useContext(A),{matches:o}=i.useContext(O),s=o[o.length-1],l=s?s.params:{},u=s?s.pathname:"/",c=s?s.pathnameBase:"/",d=s&&s.route;{let h=d&&d.path||"";sr(u,!d||h.endsWith("*")||h.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${u}" (under <Route path="${h}">) but the parent route path has no trailing "*". This means if you navigate deeper, the parent won't match anymore and therefore the child routes will never render.
|
|
2
2
|
|
|
3
3
|
Please change the parent <Route path="${h}"> to <Route path="${h==="/"?"*":`${h}/*`}">.`)}let f=P(),m;if(t){let h=typeof t=="string"?ee(t):t;C(c==="/"||h.pathname?.startsWith(c),`When overriding the location using \`<Routes location>\` or \`useRoutes(routes, location)\`, the location pathname must begin with the portion of the URL pathname that was matched by all parent routes. The current pathname base is "${c}" but pathname "${h.pathname}" was given in the \`location\` prop.`),m=h}else m=f;let g=m.pathname||"/",v=g;if(c!=="/"){let h=c.replace(/^\//,"").split("/");v="/"+g.replace(/^\//,"").split("/").slice(h.length).join("/")}let b=r&&r.state.matches.length?r.state.matches.map(h=>Object.assign(h,{route:r.manifest[h.route.id]||h.route})):Ut(e,{pathname:v});T(d||b!=null,`No routes matched location "${m.pathname}${m.search}${m.hash}" `),T(b==null||b[b.length-1].route.element!==void 0||b[b.length-1].route.Component!==void 0||b[b.length-1].route.lazy!==void 0,`Matched leaf route at location "${m.pathname}${m.search}${m.hash}" does not have an element or Component. This means it will render an <Outlet /> with a null value by default resulting in an "empty" page.`);let y=Za(b&&b.map(h=>Object.assign({},h,{params:Object.assign({},l,h.params),pathname:N([c,n.encodeLocation?n.encodeLocation(h.pathname.replace(/%/g,"%25").replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:h.pathname]),pathnameBase:h.pathnameBase==="/"?c:N([c,n.encodeLocation?n.encodeLocation(h.pathnameBase.replace(/%/g,"%25").replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:h.pathnameBase])})),o,r);return t&&y?i.createElement(re.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",mask:void 0,...m},navigationType:"POP"}},y):y}a(nr,"useRoutesImpl");function Ja(){let e=ao(),t=Kt(e)?`${e.status} ${e.statusText}`:e instanceof Error?e.message:JSON.stringify(e),r=e instanceof Error?e.stack:null,n="rgba(200,200,200, 0.5)",o={padding:"0.5rem",backgroundColor:n},s={padding:"2px 4px",backgroundColor:n},l=null;return l=i.createElement(i.Fragment,null,i.createElement("p",null,"💿 Hey developer 👋"),i.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",i.createElement("code",{style:s},"ErrorBoundary")," or"," ",i.createElement("code",{style:s},"errorElement")," prop on your route.")),i.createElement(i.Fragment,null,i.createElement("h2",null,"Unexpected Application Error!"),i.createElement("h3",{style:{fontStyle:"italic"}},t),r?i.createElement("pre",{style:o},r):null,l)}a(Ja,"DefaultErrorComponent");var Ga=i.createElement(Ja,null),ar=class extends i.Component{static{a(this,"RenderErrorBoundary")}constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location||t.revalidation!=="idle"&&e.revalidation==="idle"?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:e.error!==void 0?e.error:t.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){this.props.onError&&this.props.onError(e,t)}render(){let e=this.state.error;if(this.context&&typeof e=="object"&&e&&"digest"in e&&typeof e.digest=="string"){const r=Fa(e.digest);r&&(e=r)}let t=e!==void 0?i.createElement(O.Provider,{value:this.props.routeContext},i.createElement(Qe.Provider,{value:e,children:this.props.component})):this.props.children;return this.context?i.createElement(Ya,{error:e},t):t}};ar.contextType=Yt;var Pe=new WeakMap;function Ya({children:e,error:t}){let{basename:r,navigator:n}=i.useContext(A);if(typeof t=="object"&&t&&"digest"in t&&typeof t.digest=="string"){let o=za(t.digest);if(o){let s=Pe.get(t);if(s)throw s;let l=Jt(o.location,r),u=l.absoluteURL||l.to;if(Ke(o.location,u,Ve(n),"allow-explicit"),ja(u))throw new Error("Invalid redirect location");if(Qt&&!Pe.get(t))if(l.isExternal||o.reloadDocument)window.location.href=u;else{const c=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(l.to,{replace:o.replace}));throw Pe.set(t,c),c}return i.createElement("meta",{httpEquiv:"refresh",content:`0;url=${u}`})}}return e}a(Ya,"RSCErrorHandler");function Xa({routeContext:e,match:t,children:r}){let n=i.useContext(te);return n&&n.static&&n.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(n.staticContext._deepestRenderedBoundaryId=t.route.id),i.createElement(O.Provider,{value:e},r)}a(Xa,"RenderedRoute");function Za(e,t=[],r){let n=r?.state;if(e==null){if(!n)return null;if(n.errors)e=n.matches;else if(t.length===0&&!n.initialized&&n.matches.length>0)e=n.matches;else return null}let o=e,s=n?.errors;if(s!=null){let f=o.findIndex(m=>m.route.id&&s?.[m.route.id]!==void 0);C(f>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(s).join(",")}`),o=o.slice(0,Math.min(o.length,f+1))}let l=!1,u=-1;if(r&&n){l=n.renderFallback;for(let f=0;f<o.length;f++){let m=o[f];if((m.route.HydrateFallback||m.route.hydrateFallbackElement)&&(u=f),m.route.id){let{loaderData:g,errors:v}=n,b=m.route.loader&&!g.hasOwnProperty(m.route.id)&&(!v||v[m.route.id]===void 0);if(m.route.lazy||b){r.isStatic&&(l=!0),u>=0?o=o.slice(0,u+1):o=[o[0]];break}}}}let c=r?.onError,d=n&&c?(f,m)=>{c(f,{location:n.location,params:n.matches?.[0]?.params??{},pattern:_a(n.matches),errorInfo:m})}:void 0;return o.reduceRight((f,m,g)=>{let v,b=!1,y=null,h=null;n&&(v=s&&m.route.id?s[m.route.id]:void 0,y=m.route.errorElement||Ga,l&&(u<0&&g===0?(sr("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),b=!0,h=null):u===g&&(b=!0,h=m.route.hydrateFallbackElement||null)));let k=t.concat(o.slice(0,g+1)),w=a(()=>{let I;return v?I=y:b?I=h:m.route.Component?I=i.createElement(m.route.Component,null):m.route.element?I=m.route.element:I=f,i.createElement(Xa,{match:m,routeContext:{outlet:f,matches:k,isDataRoute:n!=null},children:I})},"getChildren");return n&&(m.route.ErrorBoundary||m.route.errorElement||g===0)?i.createElement(ar,{location:n.location,revalidation:n.revalidation,component:y,error:v,children:w(),routeContext:{outlet:null,matches:k,isDataRoute:!0},onError:d}):w()},null)}a(Za,"_renderMatches");function Je(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}a(Je,"getDataRouterConsoleError");function eo(e){let t=i.useContext(te);return C(t,Je(e)),t}a(eo,"useDataRouterContext");function Ge(e){let t=i.useContext(de);return C(t,Je(e)),t}a(Ge,"useDataRouterState");function to(e){let t=i.useContext(O);return C(t,Je(e)),t}a(to,"useRouteContext");function Ye(e){let t=to(e),r=t.matches[t.matches.length-1];return C(r.route.id,`${e} can only be used on routes that contain a unique "id"`),r.route.id}a(Ye,"useCurrentRouteId");function ro(){return Ye("useRouteId")}a(ro,"useRouteId");function no(){let e=Ge("useNavigation");return i.useMemo(()=>{let{matches:t,historyAction:r,...n}=e.navigation;return n},[e.navigation])}a(no,"useNavigation");function or(){let{matches:e,loaderData:t}=Ge("useMatches");return i.useMemo(()=>e.map(r=>ca(r,t)),[e,t])}a(or,"useMatches");function ao(){let e=i.useContext(Qe),t=Ge("useRouteError"),r=Ye("useRouteError");return e!==void 0?e:t.errors?.[r]}a(ao,"useRouteError");function oo(){let{router:e}=eo("useNavigate"),t=Ye("useNavigate"),r=i.useRef(!1);return rr(()=>{r.current=!0}),i.useCallback(async(n,o={})=>{T(r.current,tr),r.current&&(typeof n=="number"?await e.navigate(n):await e.navigate(n,{fromRouteId:t,...o}))},[e,t])}a(oo,"useNavigateStable");var mt={};function sr(e,t,r){!t&&!mt[e]&&(mt[e]=!0,T(!1,r))}a(sr,"warningOnce");var ht={};function so(e,t){!e&&!ht[t]&&(ht[t]=!0)}a(so,"warnOnce");var fl=i.memo(io);function io({routes:e,manifest:t,future:r,state:n,isStatic:o,onError:s}){return nr(e,void 0,{manifest:t,state:n,isStatic:o,onError:s,future:r})}a(io,"DataRoutes2");function lo({to:e,replace:t,state:r,relative:n}){C(ne(),"<Navigate> may be used only in the context of a <Router> component.");let{static:o,navigator:s}=i.useContext(A);T(!o,"<Navigate> must not be used on the initial render in a <StaticRouter>. This is a no-op, but you should modify your code so the <Navigate> is only ever rendered in response to some user interaction or state change.");let{matches:l}=i.useContext(O),{pathname:u}=P(),c=Ee(),d=Ie(e,We(l),u,n==="path");Ke(typeof e=="string"?e:K(e),s.createHref(d),Ve(s),"reject");let f=JSON.stringify(d);return i.useEffect(()=>{c(JSON.parse(f),{replace:t,state:r,relative:n})},[c,f,n,t,r]),null}a(lo,"Navigate$1");function ml(e){return Va(e.context)}a(ml,"Outlet");function uo(e){C(!1,"A <Route> is only ever to be used as the child of <Routes> element, never rendered directly. Please wrap your <Route> in a <Routes>.")}a(uo,"Route");function ir({basename:e="/",children:t=null,location:r,navigationType:n="POP",navigator:o,static:s=!1,useTransitions:l}){C(!ne(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let u=e.replace(/^\/*/,"/"),c=i.useMemo(()=>({basename:u,navigator:o,static:s,useTransitions:l,future:{}}),[u,o,s,l]);typeof r=="string"&&(r=ee(r));let{pathname:d="/",search:f="",hash:m="",state:g=null,key:v="default",mask:b}=r,y=i.useMemo(()=>{let h=F(d,u);return h==null?null:{location:{pathname:h,search:f,hash:m,state:g,key:v,mask:b},navigationType:n}},[u,d,f,m,g,v,n,b]);return T(y!=null,`<Router basename="${u}"> is not able to match the URL "${d}${f}${m}" because it does not start with the basename, so the <Router> won't render anything.`),y==null?null:i.createElement(A.Provider,{value:c},i.createElement(re.Provider,{children:t,value:y}))}a(ir,"Router");function hl({children:e,location:t}){return Qa(Ne(e),t)}a(hl,"Routes");var pl=class extends i.Component{static{a(this,"AwaitErrorBoundary")}constructor(e){super(e),this.state={error:null}}static getDerivedStateFromError(e){return{error:e}}componentDidCatch(e,t){this.props.onError&&this.props.onError(e,t)}render(){let{children:e,errorElement:t,resolve:r}=this.props,n=null,o=0;if(!(r instanceof Promise))o=1,n=Promise.resolve(),Object.defineProperty(n,"_tracked",{get:a(()=>!0,"get")}),Object.defineProperty(n,"_data",{get:a(()=>r,"get")});else if(this.state.error){o=2;let s=this.state.error;n=Promise.reject().catch(()=>{}),Object.defineProperty(n,"_tracked",{get:a(()=>!0,"get")}),Object.defineProperty(n,"_error",{get:a(()=>s,"get")})}else r._tracked?(n=r,o="_error"in n?2:"_data"in n?1:0):(o=0,Object.defineProperty(r,"_tracked",{get:a(()=>!0,"get")}),n=r.then(s=>Object.defineProperty(r,"_data",{get:a(()=>s,"get")}),s=>{this.props.onError?.(s),Object.defineProperty(r,"_error",{get:a(()=>s,"get")})}));if(o===2&&!t)throw n._error;if(o===2)return i.createElement(je.Provider,{value:n,children:t});if(o===1)return i.createElement(je.Provider,{value:n,children:e});throw n}};function Ne(e,t=[]){let r=[];return i.Children.forEach(e,(n,o)=>{if(!i.isValidElement(n))return;let s=[...t,o];if(n.type===i.Fragment){r.push.apply(r,Ne(n.props.children,s));return}C(n.type===uo,`[${typeof n.type=="string"?n.type:n.type.name}] is not a <Route> component. All component children of <Routes> must be a <Route> or <React.Fragment>`),C(!n.props.index||!n.props.children,"An index route cannot have child routes.");let l={id:n.props.id||s.join("-"),caseSensitive:n.props.caseSensitive,element:n.props.element,Component:n.props.Component,index:n.props.index,path:n.props.path,middleware:n.props.middleware,loader:n.props.loader,action:n.props.action,hydrateFallbackElement:n.props.hydrateFallbackElement,HydrateFallback:n.props.HydrateFallback,errorElement:n.props.errorElement,ErrorBoundary:n.props.ErrorBoundary,hasErrorBoundary:n.props.hasErrorBoundary===!0||n.props.ErrorBoundary!=null||n.props.errorElement!=null,shouldRevalidate:n.props.shouldRevalidate,handle:n.props.handle,lazy:n.props.lazy};n.props.children&&(l.children=Ne(n.props.children,s)),r.push(l)}),r}a(Ne,"createRoutesFromChildren");var be="get",ve="application/x-www-form-urlencoded";function Re(e){return typeof HTMLElement<"u"&&e instanceof HTMLElement}a(Re,"isHtmlElement");function co(e){return Re(e)&&e.tagName.toLowerCase()==="button"}a(co,"isButtonElement");function fo(e){return Re(e)&&e.tagName.toLowerCase()==="form"}a(fo,"isFormElement");function mo(e){return Re(e)&&e.tagName.toLowerCase()==="input"}a(mo,"isInputElement");function ho(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}a(ho,"isModifiedEvent");function po(e,t){return e.button===0&&(!t||t==="_self")&&!ho(e)}a(po,"shouldProcessLinkClick");function Be(e=""){return new URLSearchParams(typeof e=="string"||Array.isArray(e)||e instanceof URLSearchParams?e:Object.keys(e).reduce((t,r)=>{let n=e[r];return t.concat(Array.isArray(n)?n.map(o=>[r,o]):[[r,n]])},[]))}a(Be,"createSearchParams");function go(e,t){let r=Be(e);return t&&t.forEach((n,o)=>{r.has(o)||t.getAll(o).forEach(s=>{r.append(o,s)})}),r}a(go,"getSearchParamsForLocation");var pe=null;function yo(){if(pe===null)try{new FormData(document.createElement("form"),0),pe=!1}catch{pe=!0}return pe}a(yo,"isFormDataSubmitterSupported");var bo=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function Le(e){return e!=null&&!bo.has(e)?(T(!1,`"${e}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${ve}"`),null):e}a(Le,"getFormEncType");function vo(e,t){let r,n,o,s,l;if(fo(e)){let u=e.getAttribute("action");n=u?F(u,t):null,r=e.getAttribute("method")||be,o=Le(e.getAttribute("enctype"))||ve,s=new FormData(e)}else if(co(e)||mo(e)&&(e.type==="submit"||e.type==="image")){let u=e.form;if(u==null)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let c=e.getAttribute("formaction")||u.getAttribute("action");if(n=c?F(c,t):null,r=e.getAttribute("formmethod")||u.getAttribute("method")||be,o=Le(e.getAttribute("formenctype"))||Le(u.getAttribute("enctype"))||ve,s=new FormData(u,e),!yo()){let{name:d,type:f,value:m}=e;if(f==="image"){let g=d?`${d}.`:"";s.append(`${g}x`,"0"),s.append(`${g}y`,"0")}else d&&s.append(d,m)}}else{if(Re(e))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');r=be,n=null,o=ve,l=e}return s&&o==="text/plain"&&(l=s,s=void 0),{action:n,method:r.toLowerCase(),encType:o,formData:s,body:l}}a(vo,"getFormSubmissionInfo");var gl=Object.getOwnPropertyNames(Object.prototype).sort().join("\0"),ko={"&":"\\u0026",">":"\\u003e","<":"\\u003c","\u2028":"\\u2028","\u2029":"\\u2029"},xo=/[&><\u2028\u2029]/g;function pt(e){return e.replace(xo,t=>ko[t])}a(pt,"escapeHtml");function Ce(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}a(Ce,"invariant2");function lr(e,t,r,n){let o=typeof e=="string"?new URL(e,typeof window>"u"?"server://singlefetch/":window.location.origin):e;return r?o.pathname.endsWith("/")?o.pathname=`${o.pathname}_.${n}`:o.pathname=`${o.pathname}.${n}`:o.pathname==="/"?o.pathname=`_root.${n}`:t&&F(o.pathname,t)==="/"?o.pathname=`${X(t)}/_root.${n}`:o.pathname=`${X(o.pathname)}.${n}`,o}a(lr,"singleFetchUrl");async function wo(e,t){if(e.id in t)return t[e.id];try{let r=await na(()=>import(e.module),[]);return t[e.id]=r,r}catch{return window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise(()=>{})}}a(wo,"loadRouteModule");function So(e){return e!=null&&typeof e.page=="string"}a(So,"isPageLinkDescriptor");function Io(e){return e==null?!1:e.href==null?e.rel==="preload"&&typeof e.imageSrcSet=="string"&&typeof e.imageSizes=="string":typeof e.rel=="string"&&typeof e.href=="string"}a(Io,"isHtmlLinkDescriptor");async function Eo(e,t,r){return $o((await Promise.all(e.map(async n=>{let o=t.routes[n.route.id];if(o){let s=await wo(o,r);return s.links?s.links():[]}return[]}))).flat(1).filter(Io).filter(n=>n.rel==="stylesheet"||n.rel==="preload").map(n=>n.rel==="stylesheet"?{...n,rel:"prefetch",as:"style"}:{...n,rel:"prefetch"}))}a(Eo,"getKeyedPrefetchLinks");function gt(e,t,r,n,o,s){let l=a((c,d)=>r[d]?c.route.id!==r[d].route.id:!0,"isNew"),u=a((c,d)=>r[d].pathname!==c.pathname||r[d].route.path?.endsWith("*")&&r[d].params["*"]!==c.params["*"],"matchPathChanged");return s==="assets"?t.filter((c,d)=>l(c,d)||u(c,d)):s==="data"?t.filter((c,d)=>{let f=n.routes[c.route.id];if(!f||!f.hasLoader)return!1;if(l(c,d)||u(c,d))return!0;if(c.route.shouldRevalidate){let m=c.route.shouldRevalidate({currentUrl:new URL(o.pathname+o.search+o.hash,window.origin),currentParams:r[0]?.params||{},nextUrl:new URL(e,window.origin),nextParams:c.params,defaultShouldRevalidate:!0});if(typeof m=="boolean")return m}return!0}):[]}a(gt,"getNewMatchesForLinks");function ur(e,t,{includeHydrateFallback:r}={}){return Ro(e.map(n=>{let o=t.routes[n.route.id];if(!o)return[];let s=[o.module];return o.clientActionModule&&(s=s.concat(o.clientActionModule)),o.clientLoaderModule&&(s=s.concat(o.clientLoaderModule)),r&&o.hydrateFallbackModule&&(s=s.concat(o.hydrateFallbackModule)),o.imports&&(s=s.concat(o.imports)),s}).flat(1))}a(ur,"getModuleLinkHrefs");function Ro(e){return[...new Set(e)]}a(Ro,"dedupeHrefs");function Co(e){let t={},r=Object.keys(e).sort();for(let n of r)t[n]=e[n];return t}a(Co,"sortKeys");function $o(e,t){let r=new Set,n=new Set(t);return e.reduce((o,s)=>{if(t&&!So(s)&&s.as==="script"&&s.href&&n.has(s.href))return o;let l=JSON.stringify(Co(s));return r.has(l)||(r.add(l),o.push({key:l,link:s})),o},[])}a($o,"dedupeLinkDescriptors");function _o(e,t){return e.mode==="lazy"&&t===!0}a(_o,"isFogOfWarEnabled");function Do({sri:e,...t},r){let n=new Set(r.state.matches.map(u=>u.route.id)),o=r.state.location.pathname.split("/").filter(Boolean),s=["/"];for(o.pop();o.length>0;)s.push(`/${o.join("/")}`),o.pop();s.forEach(u=>{let c=zt(r.routes,u,r.basename||"/",!1,r.branches);c&&c.forEach(d=>n.add(d.route.id))});let l=[...n].reduce((u,c)=>Object.assign(u,{[c]:t.routes[c]}),{});return{...t,routes:l,sri:e?!0:void 0}}a(Do,"getPartialManifest");function $e(){let e=i.useContext(te);return Ce(e,"You must render this element inside a <DataRouterContext.Provider> element"),e}a($e,"useDataRouterContext2");function cr(){let e=i.useContext(de);return Ce(e,"You must render this element inside a <DataRouterStateContext.Provider> element"),e}a(cr,"useDataRouterStateContext");var _e=i.createContext(void 0);_e.displayName="FrameworkContext";function Q(){let e=i.useContext(_e);return Ce(e,"You must render this element inside a <HydratedRouter> element"),e}a(Q,"useFrameworkContext");function Ao(e,t){let r=i.useContext(_e),[n,o]=i.useState(!1),[s,l]=i.useState(!1),{onFocus:u,onBlur:c,onMouseEnter:d,onMouseLeave:f,onTouchStart:m}=t,g=i.useRef(null);i.useEffect(()=>{if(e==="render"&&l(!0),e==="viewport"){let y=a(k=>{k.forEach(w=>{l(w.isIntersecting)})},"callback"),h=new IntersectionObserver(y,{threshold:.5});return g.current&&h.observe(g.current),()=>{h.disconnect()}}},[e]),i.useEffect(()=>{if(n){let y=setTimeout(()=>{l(!0)},100);return()=>{clearTimeout(y)}}},[n]);let v=a(()=>{o(!0)},"setIntent"),b=a(()=>{o(!1),l(!1)},"cancelIntent");return r?e!=="intent"?[s,g,{}]:[s,g,{onFocus:se(u,v),onBlur:se(c,b),onMouseEnter:se(d,v),onMouseLeave:se(f,b),onTouchStart:se(m,v)}]:[!1,g,{}]}a(Ao,"usePrefetchBehavior");function se(e,t){return r=>{e&&e(r),r.defaultPrevented||t(r)}}a(se,"composeEventHandlers");function Mo(e,t,r){if(r&&!xe)return[e[0]];if(t){let n=e.findIndex(o=>t[o.route.id]!==void 0);return e.slice(0,n+1)}return e}a(Mo,"getActiveMatches");function To({page:e,...t}){let r=Xt(),{nonce:n}=Q(),{router:o}=$e(),s=i.useMemo(()=>Ut(o.routes,e,o.basename),[o.routes,e,o.basename]);return s?(t.nonce==null&&n&&(t={...t,nonce:n}),r?i.createElement(Lo,{page:e,matches:s,...t}):i.createElement(Oo,{page:e,matches:s,...t})):null}a(To,"PrefetchPageLinks");function Po(e){let{manifest:t,routeModules:r}=Q(),[n,o]=i.useState([]);return i.useEffect(()=>{let s=!1;return Eo(e,t,r).then(l=>{s||o(l)}),()=>{s=!0}},[e,t,r]),n}a(Po,"useKeyedPrefetchLinks");function Lo({page:e,matches:t,...r}){let n=P(),{future:o}=Q(),{basename:s}=$e(),l=i.useMemo(()=>{if(e===n.pathname+n.search+n.hash)return[];let u=lr(e,s,o.v8_trailingSlashAwareDataRequests,"rsc"),c=!1,d=[];for(let f of t)typeof f.route.shouldRevalidate=="function"?c=!0:d.push(f.route.id);return c&&d.length>0&&u.searchParams.set("_routes",d.join(",")),[u.pathname+u.search]},[s,o.v8_trailingSlashAwareDataRequests,e,n,t]);return i.createElement(i.Fragment,null,l.map(u=>i.createElement("link",{key:u,rel:"prefetch",as:"fetch",href:u,...r})))}a(Lo,"RSCPrefetchPageLinksImpl");function Oo({page:e,matches:t,...r}){let n=P(),{future:o,manifest:s,routeModules:l}=Q(),{basename:u}=$e(),{loaderData:c,matches:d}=cr(),f=i.useMemo(()=>gt(e,t,d,s,n,"data"),[e,t,d,s,n]),m=i.useMemo(()=>gt(e,t,d,s,n,"assets"),[e,t,d,s,n]),g=i.useMemo(()=>{if(e===n.pathname+n.search+n.hash)return[];let y=new Set,h=!1;if(t.forEach(w=>{let I=s.routes[w.route.id];!I||!I.hasLoader||(!f.some($=>$.route.id===w.route.id)&&w.route.id in c&&l[w.route.id]?.shouldRevalidate||I.hasClientLoader?h=!0:y.add(w.route.id))}),y.size===0)return[];let k=lr(e,u,o.v8_trailingSlashAwareDataRequests,"data");return h&&y.size>0&&k.searchParams.set("_routes",t.filter(w=>y.has(w.route.id)).map(w=>w.route.id).join(",")),[k.pathname+k.search]},[u,o.v8_trailingSlashAwareDataRequests,c,n,s,f,t,e,l]),v=i.useMemo(()=>ur(m,s),[m,s]),b=Po(m);return i.createElement(i.Fragment,null,g.map(y=>i.createElement("link",{key:y,rel:"prefetch",as:"fetch",href:y,...r})),v.map(y=>i.createElement("link",{key:y,rel:"modulepreload",href:y,...r})),b.map(({key:y,link:h})=>i.createElement("link",{key:y,nonce:r.nonce,...h,crossOrigin:h.crossOrigin??r.crossOrigin})))}a(Oo,"PrefetchPageLinksImpl");var xe=!1;function jo(){xe=!0}a(jo,"setIsHydrated");function No(e){let{manifest:t,serverHandoffString:r,isSpaMode:n,renderMeta:o,routeDiscovery:s,ssr:l,nonce:u}=Q(),{router:c,static:d,staticContext:f}=$e(),{matches:m}=cr(),g=Xt(),v=_o(s,l);e.nonce==null&&u&&(e={...e,nonce:u}),o&&(o.didRenderScripts=!0);let b=Mo(m,null,n);i.useEffect(()=>{jo()},[]);let y=i.useMemo(()=>{if(g)return null;let w=f?`window.__reactRouterContext = ${r};window.__reactRouterContext.stream = new ReadableStream({start(controller){window.__reactRouterContext.streamController = controller;}}).pipeThrough(new TextEncoderStream());`:" ",I=d?`${t.hmr?.runtime?`import ${JSON.stringify(t.hmr.runtime)};`:""}${v?"":`import ${JSON.stringify(t.url)}`};
|
|
4
4
|
${b.map(($,E)=>{let _=`route${E}`,M=t.routes[$.route.id];Ce(M,`Route ${$.route.id} not found in manifest`);let{clientActionModule:j,clientLoaderModule:D,clientMiddlewareModule:B,hydrateFallbackModule:J,module:L}=M,q=[...j?[{module:j,varName:`${_}_clientAction`}]:[],...D?[{module:D,varName:`${_}_clientLoader`}]:[],...B?[{module:B,varName:`${_}_clientMiddleware`}]:[],...J?[{module:J,varName:`${_}_HydrateFallback`}]:[],{module:L,varName:`${_}_main`}];return q.length===1?`import * as ${_} from ${JSON.stringify(L)};`:[q.map(U=>`import * as ${U.varName} from "${U.module}";`).join(`
|
|
@@ -12,4 +12,4 @@ import(${JSON.stringify(t.entry.module)});`:" ";return i.createElement(i.Fragmen
|
|
|
12
12
|
console.log(
|
|
13
13
|
"💿 Hey developer 👋. You can provide a way better UX than this when your app throws errors. Check out https://reactrouter.com/how-to/error-boundary for more information."
|
|
14
14
|
);
|
|
15
|
-
`}});if(Kt(e))return i.createElement(yt,{title:"Unhandled Thrown Response!"},i.createElement("h1",{style:{fontSize:"24px"}},e.status," ",e.statusText),n);let o;if(e instanceof Error)o=e;else{let s=e==null?"Unknown Error":typeof e=="object"&&"toString"in e?e.toString():JSON.stringify(e);o=new Error(s)}return i.createElement(yt,{title:"Application Error!",isOutsideRemixApp:t},i.createElement("h1",{style:{fontSize:"24px"}},"Application Error"),i.createElement("pre",{style:{padding:"2rem",background:"hsla(10, 50%, 50%, 0.1)",color:"red",overflow:"auto"}},o.stack),n)}a(Uo,"RemixRootDefaultErrorBoundary");function yt({title:e,renderScripts:t,isOutsideRemixApp:r,children:n}){let{routeModules:o}=Q();return o.root?.Layout&&!r?n:i.createElement("html",{lang:"en"},i.createElement("head",null,i.createElement("meta",{charSet:"utf-8"}),i.createElement("meta",{name:"viewport",content:"width=device-width,initial-scale=1,viewport-fit=cover"}),i.createElement("title",null,e)),i.createElement("body",null,i.createElement("main",{style:{fontFamily:"system-ui, sans-serif",padding:"2rem"}},n,t?i.createElement(No,null):null)))}a(yt,"BoundaryShell");var zo=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{zo&&(window.__reactRouterVersion="7.18.4")}catch{}function bl({basename:e,children:t,useTransitions:r,window:n}){let o=i.useRef();o.current==null&&(o.current=oa({window:n,v5Compat:!0}));let s=o.current,[l,u]=i.useState({action:s.action,location:s.location}),c=i.useCallback(d=>{r===!1?u(d):i.startTransition(()=>u(d))},[r]);return i.useLayoutEffect(()=>s.listen(c),[s,c]),i.createElement(ir,{basename:e,children:t,location:l.location,navigationType:l.action,navigator:s,useTransitions:r})}a(bl,"BrowserRouter");function Fo({basename:e,children:t,history:r,useTransitions:n}){let[o,s]=i.useState({action:r.action,location:r.location}),l=i.useCallback(u=>{n===!1?s(u):i.startTransition(()=>s(u))},[n]);return i.useLayoutEffect(()=>r.listen(l),[r,l]),i.createElement(ir,{basename:e,children:t,location:o.location,navigationType:o.action,navigator:r,useTransitions:n})}a(Fo,"HistoryRouter");Fo.displayName="unstable_HistoryRouter";var me=i.forwardRef(a(function({onClick:t,discover:r="render",prefetch:n="none",relative:o,reloadDocument:s,replace:l,mask:u,state:c,target:d,to:f,preventScrollReset:m,viewTransition:g,defaultShouldRevalidate:v,...b},y){let{basename:h,navigator:k,useTransitions:w}=i.useContext(A),I=typeof f=="string"&&He.test(f),$=Jt(f,h);f=$.to;let E=qa(f,{relative:o}),_=P(),M=null;if(u){let z=Ie(u,[],_.mask?_.mask.pathname:"/",!0);h!=="/"&&(z.pathname=z.pathname==="/"?h:N([h,z.pathname])),M=k.createHref(z)}let[j,D,B]=Ao(n,b),J=Vo(f,{replace:l,mask:u,state:c,target:d,preventScrollReset:m,relative:o,viewTransition:g,defaultShouldRevalidate:v,useTransitions:w});function L(z){t&&t(z),z.defaultPrevented||J(z)}a(L,"handleClick");let q=!($.isExternal||s),U=i.createElement("a",{...b,...B,href:(q?M:void 0)||$.absoluteURL||E,onClick:q?L:t,ref:Bo(y,D),target:d,"data-discover":!I&&r==="render"?"true":void 0});return j&&!I?i.createElement(i.Fragment,null,U,i.createElement(To,{page:E})):U},"LinkWithRef"));me.displayName="Link";var dr=i.forwardRef(a(function({"aria-current":t="page",caseSensitive:r=!1,className:n="",end:o=!1,style:s,to:l,viewTransition:u,children:c,...d},f){let m=fe(l,{relative:d.relative}),g=P(),v=i.useContext(de),{navigator:b,basename:y}=i.useContext(A),h=v!=null&&Zo(m)&&u===!0,k=b.encodeLocation?b.encodeLocation(m).pathname:m.pathname,w=g.pathname,I=v&&v.navigation&&v.navigation.location?v.navigation.location.pathname:null;r||(w=w.toLowerCase(),I=I?I.toLowerCase():null,k=k.toLowerCase()),I&&y&&(I=F(I,y)||I);const $=k!=="/"&&k.endsWith("/")?k.length-1:k.length;let E=w===k||!o&&w.startsWith(k)&&w.charAt($)==="/",_=I!=null&&(I===k||!o&&I.startsWith(k)&&I.charAt(k.length)==="/"),M={isActive:E,isPending:_,isTransitioning:h},j=E?t:void 0,D;typeof n=="function"?D=n(M):D=[n,E?"active":null,_?"pending":null,h?"transitioning":null].filter(Boolean).join(" ");let B=typeof s=="function"?s(M):s;return i.createElement(me,{...d,"aria-current":j,className:D,ref:f,style:B,to:l,viewTransition:u},typeof c=="function"?c(M):c)},"NavLinkWithRef"));dr.displayName="NavLink";var qo=i.forwardRef(({discover:e="render",fetcherKey:t,navigate:r,reloadDocument:n,replace:o,state:s,method:l=be,action:u,onSubmit:c,relative:d,preventScrollReset:f,viewTransition:m,defaultShouldRevalidate:g,...v},b)=>{let{useTransitions:y}=i.useContext(A),h=Jo(),k=Go(u,{relative:d}),w=l.toLowerCase()==="get"?"get":"post",I=typeof u=="string"&&He.test(u),$=a(E=>{if(c&&c(E),E.defaultPrevented)return;E.preventDefault();let _=E.nativeEvent.submitter,M=_?.getAttribute("formmethod")||l,j=a(()=>h(_||E.currentTarget,{fetcherKey:t,method:M,navigate:r,replace:o,state:s,relative:d,preventScrollReset:f,viewTransition:m,defaultShouldRevalidate:g}),"doSubmit");y&&r!==!1?i.startTransition(()=>j()):j()},"submitHandler");return i.createElement("form",{ref:b,method:w,action:k,onSubmit:n?c:$,...v,"data-discover":!I&&e==="render"?"true":void 0})});qo.displayName="Form";function Ho({getKey:e,storageKey:t,...r}){let n=i.useContext(_e),{basename:o}=i.useContext(A),s=P(),l=or();Yo({getKey:e,storageKey:t});let u=i.useMemo(()=>{if(!n||!e)return null;let d=ze(s,l,o,e);return d!==s.key?d:null},[]);if(!n||n.isSpaMode)return null;let c=((d,f)=>{if(!window.history.state||!window.history.state.key){let m=Math.random().toString(32).slice(2);window.history.replaceState({key:m},"")}try{let m=JSON.parse(sessionStorage.getItem(d)||"{}")[f||window.history.state.key];typeof m=="number"&&window.scrollTo(0,m)}catch{sessionStorage.removeItem(d)}}).toString();return r.nonce==null&&n?.nonce&&(r.nonce=n.nonce),i.createElement("script",{...r,suppressHydrationWarning:!0,dangerouslySetInnerHTML:{__html:`(${c})(${pt(JSON.stringify(t||Ue))}, ${pt(JSON.stringify(u))})`}})}a(Ho,"ScrollRestoration");Ho.displayName="ScrollRestoration";function fr(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}a(fr,"getDataRouterConsoleError2");function Xe(e){let t=i.useContext(te);return C(t,fr(e)),t}a(Xe,"useDataRouterContext3");function Wo(e){let t=i.useContext(de);return C(t,fr(e)),t}a(Wo,"useDataRouterState2");function Vo(e,{target:t,replace:r,mask:n,state:o,preventScrollReset:s,relative:l,viewTransition:u,defaultShouldRevalidate:c,useTransitions:d}={}){let f=Ee(),m=P(),g=fe(e,{relative:l});return i.useCallback(v=>{if(po(v,t)){v.preventDefault();let b=r!==void 0?r:K(m)===K(g),y=a(()=>f(e,{replace:b,mask:n,state:o,preventScrollReset:s,relative:l,viewTransition:u,defaultShouldRevalidate:c}),"doNavigate");d?i.startTransition(()=>y()):y()}},[m,f,g,r,n,o,t,e,s,l,u,c,d])}a(Vo,"useLinkClickHandler");function vl(e){T(typeof URLSearchParams<"u","You cannot use the `useSearchParams` hook in a browser that does not support the URLSearchParams API. If you need to support Internet Explorer 11, we recommend you load a polyfill such as https://github.com/ungap/url-search-params.");let t=i.useRef(Be(e)),r=i.useRef(!1),n=P(),o=i.useMemo(()=>go(n.search,r.current?null:t.current),[n.search]),s=Ee();return[o,i.useCallback((l,u)=>{const c=Be(typeof l=="function"?l(new URLSearchParams(o)):l);r.current=!0,s("?"+c,u)},[s,o])]}a(vl,"useSearchParams");var Ko=0,Qo=a(()=>`__${String(++Ko)}__`,"getUniqueFetcherId");function Jo(){let{router:e}=Xe("useSubmit"),{basename:t}=i.useContext(A),r=ro(),n=e.fetch,o=e.navigate;return i.useCallback(async(s,l={})=>{let{action:u,method:c,encType:d,formData:f,body:m}=vo(s,t);if(l.navigate===!1){let g=l.fetcherKey||Qo();await n(g,r,l.action||u,{defaultShouldRevalidate:l.defaultShouldRevalidate,preventScrollReset:l.preventScrollReset,formData:f,body:m,formMethod:l.method||c,formEncType:l.encType||d,flushSync:l.flushSync})}else await o(l.action||u,{defaultShouldRevalidate:l.defaultShouldRevalidate,preventScrollReset:l.preventScrollReset,formData:f,body:m,formMethod:l.method||c,formEncType:l.encType||d,replace:l.replace,state:l.state,fromRouteId:r,flushSync:l.flushSync,viewTransition:l.viewTransition})},[n,o,t,r])}a(Jo,"useSubmit");function Go(e,{relative:t}={}){let{basename:r}=i.useContext(A),n=i.useContext(O);C(n,"useFormAction must be used inside a RouteContext");let[o]=n.matches.slice(-1),s={...fe(e||".",{relative:t})},l=P();if(e==null){s.search=l.search;let u=new URLSearchParams(s.search),c=u.getAll("index");if(c.some(d=>d==="")){u.delete("index"),c.filter(f=>f).forEach(f=>u.append("index",f));let d=u.toString();s.search=d?`?${d}`:""}}return(!e||e===".")&&o.route.index&&(s.search=s.search?s.search.replace(/^\?/,"?index&"):"?index"),r!=="/"&&(s.pathname=s.pathname==="/"?r:N([r,s.pathname])),K(s)}a(Go,"useFormAction");var Ue="react-router-scroll-positions",ge={};function ze(e,t,r,n){let o=null;return n&&(r!=="/"?o=n({...e,pathname:F(e.pathname,r)||e.pathname},t):o=n(e,t)),o==null&&(o=e.key),o}a(ze,"getScrollRestorationKey");function Yo({getKey:e,storageKey:t}={}){let{router:r}=Xe("useScrollRestoration"),{restoreScrollPosition:n,preventScrollReset:o}=Wo("useScrollRestoration"),{basename:s}=i.useContext(A),l=P(),u=or(),c=no();i.useEffect(()=>(window.history.scrollRestoration="manual",()=>{window.history.scrollRestoration="auto"}),[]),Xo(i.useCallback(()=>{if(c.state==="idle"){let d=ze(l,u,s,e);ge[d]=window.scrollY}try{sessionStorage.setItem(t||Ue,JSON.stringify(ge))}catch(d){T(!1,`Failed to save scroll positions in sessionStorage, <ScrollRestoration /> will not work properly (${d}).`)}window.history.scrollRestoration="auto"},[c.state,e,s,l,u,t])),typeof document<"u"&&(i.useLayoutEffect(()=>{try{let d=sessionStorage.getItem(t||Ue);d&&(ge=JSON.parse(d))}catch{}},[t]),i.useLayoutEffect(()=>{let d=r?.enableScrollRestoration(ge,()=>window.scrollY,e?(f,m)=>ze(f,m,s,e):void 0);return()=>d&&d()},[r,s,e]),i.useLayoutEffect(()=>{if(n!==!1){if(typeof n=="number"){window.scrollTo(0,n);return}try{if(l.hash){let d=document.getElementById(decodeURIComponent(l.hash.slice(1)));if(d){d.scrollIntoView();return}}}catch{T(!1,`"${l.hash.slice(1)}" is not a decodable element ID. The view will not scroll to it.`)}o!==!0&&window.scrollTo(0,0)}},[l,n,o]))}a(Yo,"useScrollRestoration");function kl(e,t){let{capture:r}=t||{};i.useEffect(()=>{let n=r!=null?{capture:r}:void 0;return window.addEventListener("beforeunload",e,n),()=>{window.removeEventListener("beforeunload",e,n)}},[e,r])}a(kl,"useBeforeUnload");function Xo(e,t){let{capture:r}=t||{};i.useEffect(()=>{let n=r!=null?{capture:r}:void 0;return window.addEventListener("pagehide",e,n),()=>{window.removeEventListener("pagehide",e,n)}},[e,r])}a(Xo,"usePageHide");function Zo(e,{relative:t}={}){let r=i.useContext(Zt);C(r!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:n}=Xe("useViewTransitionState"),o=fe(e,{relative:t});if(!r.isTransitioning)return!1;let s=F(r.currentLocation.pathname,n)||r.currentLocation.pathname,l=F(r.nextLocation.pathname,n)||r.nextLocation.pathname;return ke(o.pathname,l)!=null||ke(o.pathname,s)!=null}a(Zo,"useViewTransitionState");var bt=60,Fe=3600,we=24*Fe,vt=7*we,kt=30*we;function es(e){const t=Date.now(),r=new Date(e).getTime(),n=Math.round((t-r)/1e3);return n<bt?"just now":n<Fe?`${Math.floor(n/bt)}m ago`:n<we?`${Math.floor(n/Fe)}h ago`:n<vt?`${Math.floor(n/we)}d ago`:n<kt?`${Math.floor(n/vt)}w ago`:`${Math.floor(n/kt)}mo ago`}a(es,"timeAgo");var ts=[{label:"My work",views:[{key:"mine",label:"Mine",surface:"inbox",inboxTab:"mine",hint:"Assigned to you or waiting on you"},{key:"unread",label:"Unread",surface:"inbox",inboxTab:"unread",hint:"Tasks you touched with new activity"},{key:"blocked",label:"Blocked",surface:"inbox",inboxTab:"blocked",hint:"Blocked tasks, grouped by blocker"},{key:"recent",label:"Recent",surface:"inbox",inboxTab:"recent",hint:"Everything you touched lately"},{key:"everything",label:"Everything",surface:"inbox",inboxTab:"all",hint:"Tasks, approvals, failed runs and join requests"}]},{label:"Organization",views:[{key:"all",label:"All tasks",surface:"issues",statuses:[],hint:"Every task in the organization"},{key:"active",label:"Active",surface:"issues",statuses:["todo","in_progress","in_review","blocked"],hint:"Open tasks, running or not"},{key:"backlog",label:"Backlog",surface:"issues",statuses:["backlog"],hint:"Not started yet"},{key:"done",label:"Done",surface:"issues",statuses:["done","cancelled"],hint:"Completed and cancelled"}]}],mr=new Map(ts.flatMap(e=>e.views.map(t=>[t.key,t]))),hr="mine",rs="view",ns="paperclip:tasks:last-view";function as(e){return typeof e=="string"&&mr.has(e)}a(as,"isTaskViewKey");function pr(e){return mr.get(e)}a(pr,"taskView");function Ze(e){return as(e)?e:null}a(Ze,"normalizeTaskViewKey");var xt={mine:"mine",unread:"unread",blocked:"blocked",recent:"recent",all:"everything"};function xl(e){return e&&e in xt?xt[e]:hr}a(xl,"taskViewForInboxTab");function wl(){try{return Ze(window.localStorage.getItem("paperclip:tasks:last-view"))??"mine"}catch{return hr}}a(wl,"loadLastTaskView");function Sl(e){try{window.localStorage.setItem(ns,e)}catch{}}a(Sl,"saveLastTaskView");var Il=["assignee","workspace","participantAgentId","q"];function El(e,t,r){const n=Ze(e);return t&&(!n||pr(n).surface==="inbox")?"all":n??r}a(El,"resolveInitialTaskView");var gr="from",yr="fromHref",br="paperclip:issue-detail-breadcrumb:";function vr(e){if(typeof e!="object"||e===null)return!1;const t=e;return typeof t.label=="string"&&typeof t.href=="string"}a(vr,"isIssueDetailBreadcrumb");function kr(e){return e==="issues"||e==="inbox"}a(kr,"isIssueDetailSource");function xr(e){if(typeof e!="object"||e===null)return!1;const t=e,r=t.originKind===void 0||typeof t.originKind=="string",n=t.originId===void 0||t.originId===null||typeof t.originId=="string",o=t.blockerAttention===void 0||typeof t.blockerAttention=="object"&&t.blockerAttention!==null;return typeof t.id=="string"&&(t.identifier===null||typeof t.identifier=="string")&&typeof t.title=="string"&&typeof t.status=="string"&&o&&typeof t.priority=="string"&&(t.projectId===null||typeof t.projectId=="string")&&(t.projectName===null||typeof t.projectName=="string")&&r&&n}a(xr,"isIssueDetailHeaderSeed");function os(e){return{id:e.id,identifier:e.identifier??null,title:e.title,status:e.status,blockerAttention:e.blockerAttention,priority:e.priority,projectId:e.projectId??null,projectName:e.project?.name??null,originKind:e.originKind,originId:e.originId??null}}a(os,"createIssueDetailHeaderSeed");function wr(e,t){const r=os(t);return typeof e!="object"||e===null?{issueDetailHeaderSeed:r}:{...e,issueDetailHeaderSeed:r}}a(wr,"withIssueDetailHeaderSeed");function ss(e){if(typeof e!="object"||e===null)return null;const t=e.issueDetailHeaderSeed;return xr(t)?t:null}a(ss,"readIssueDetailHeaderSeed");function is(e){if(!e)return null;const t=new URLSearchParams(e).get(gr);return kr(t)?t:null}a(is,"readIssueDetailSourceFromSearch");function ls(e){if(!e)return null;const t=new URLSearchParams(e).get(yr);return t&&t.startsWith("/")?t:null}a(ls,"readIssueDetailBreadcrumbHrefFromSearch");function us(e){const t=e.slice(e.indexOf("?")+1);if(!e.includes("?"))return!1;const r=new URLSearchParams(t).get(rs),n=Ze(r);return n!==null&&pr(n).surface==="inbox"}a(us,"isInboxBackedTaskViewHref");function Sr(e,t){return kr(e?.issueDetailSource)?e.issueDetailSource:t?t.href.includes("/inbox")||us(t.href)||t.label==="Inbox"?"inbox":t.label==="Tasks"||t.href.includes("/issues")?"issues":null:null}a(Sr,"inferIssueDetailSource");function wt(e){return e==="inbox"?{label:"Inbox",href:"/inbox"}:{label:"Tasks",href:"/issues"}}a(wt,"breadcrumbForSource");function Rl(e,t,r){return{issueDetailBreadcrumb:{label:e,href:t},issueDetailSource:r}}a(Rl,"createIssueDetailLocationState");function Cl(e){return typeof e!="object"||e===null?{issueDetailInboxQuickArchiveArmed:!0}:{...e,issueDetailInboxQuickArchiveArmed:!0}}a(Cl,"armIssueDetailInboxQuickArchive");function cs(e){if(typeof window>"u"||!window.sessionStorage)return null;const t=window.sessionStorage.getItem(`${br}${e}`);if(!t)return null;try{const r=JSON.parse(t),n=vr(r.issueDetailBreadcrumb)?r.issueDetailBreadcrumb:null,o=Sr(r,n);if(!n||!o)return null;const s=xr(r.issueDetailHeaderSeed)?r.issueDetailHeaderSeed:void 0;return{issueDetailBreadcrumb:n,issueDetailSource:o,issueDetailInboxQuickArchiveArmed:r.issueDetailInboxQuickArchiveArmed===!0,issueDetailHeaderSeed:s}}catch{return null}}a(cs,"readStoredIssueDetailLocationState");function Ir(e,t){if(typeof e=="object"&&e!==null){const o=e.issueDetailBreadcrumb;if(vr(o)){const s=Sr(e,o);if(!s)return null;const l=ss(e)??void 0;return{issueDetailBreadcrumb:o,issueDetailSource:s,issueDetailInboxQuickArchiveArmed:e.issueDetailInboxQuickArchiveArmed===!0,issueDetailHeaderSeed:l}}}const r=is(t),n=ls(t);return r?{issueDetailBreadcrumb:n?{...wt(r),href:n}:wt(r),issueDetailSource:r,issueDetailInboxQuickArchiveArmed:!1}:null}a(Ir,"normalizeIssueDetailLocationState");function $l(e,t,r){if(typeof window>"u"||!window.sessionStorage)return;const n=Ir(t,r);n&&window.sessionStorage.setItem(`${br}${e}`,JSON.stringify(n))}a($l,"rememberIssueDetailLocationState");function ds(e){return`/issues/${e}`}a(ds,"createIssueDetailPath");function _l(e){if(!e)return!1;const t=new URLSearchParams(e);return t.has(gr)||t.has(yr)}a(_l,"hasLegacyIssueDetailQuery");function fs(e,t,r){const n=Ir(t,r);return n||(e?cs(e):null)}a(fs,"readIssueDetailLocationState");function Dl(e,t,r){return fs(e,t,r)?.issueDetailBreadcrumb??null}a(Dl,"readIssueDetailBreadcrumb");var St=class extends Error{static{a(this,"CommentSubmissionUnknownError")}constructor(){super("We couldn’t confirm whether this comment was saved. Review the conversation before starting another draft."),this.name="CommentSubmissionUnknownError"}};function It(e){if(!e||typeof e!="object"||Array.isArray(e))return!1;const t=e,r=/^[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i;return typeof t.id=="string"&&r.test(t.id)&&typeof t.issueId=="string"&&r.test(t.issueId)&&typeof t.body=="string"}a(It,"hasCommentReceipt");async function Et(e,t){try{const r=await e;if(!t(r))throw new St;return r}catch(r){throw r instanceof Wn&&r.status<500?r:new St}}a(Et,"confirmedCommentResponse");function Rt(e){const t=new URLSearchParams;return e?.attention&&t.set("attention",e.attention),e?.status&&t.set("status",e.status),e?.priority&&t.set("priority",e.priority),e?.projectId&&t.set("projectId",e.projectId),e?.parentId&&t.set("parentId",e.parentId),e?.assigneeAgentId&&t.set("assigneeAgentId",e.assigneeAgentId),e?.participantAgentId&&t.set("participantAgentId",e.participantAgentId),e?.assigneeUserId&&t.set("assigneeUserId",e.assigneeUserId),e?.touchedByUserId&&t.set("touchedByUserId",e.touchedByUserId),e?.inboxArchivedByUserId&&t.set("inboxArchivedByUserId",e.inboxArchivedByUserId),e?.unreadForUserId&&t.set("unreadForUserId",e.unreadForUserId),e?.labelId&&t.set("labelId",e.labelId),e?.createdByAgentId&&t.set("createdByAgentId",e.createdByAgentId),e?.createdByUserId&&t.set("createdByUserId",e.createdByUserId),e?.updatedSince&&t.set("updatedSince",e.updatedSince),e?.workspaceId&&t.set("workspaceId",e.workspaceId),e?.executionWorkspaceId&&t.set("executionWorkspaceId",e.executionWorkspaceId),e?.originKind&&t.set("originKind",e.originKind),e?.originKindPrefix&&t.set("originKindPrefix",e.originKindPrefix),e?.originId&&t.set("originId",e.originId),e?.descendantOf&&t.set("descendantOf",e.descendantOf),e?.createdFromIssueId&&t.set("createdFromIssueId",e.createdFromIssueId),e?.includeRoutineExecutions&&t.set("includeRoutineExecutions","true"),e?.includeBlockedBy&&t.set("includeBlockedBy","true"),e?.includeBlockedInboxAttention&&t.set("includeBlockedInboxAttention","true"),e?.includeLiveDescendantSummary&&t.set("includeLiveDescendantSummary","true"),e?.hasPlanDocument!==void 0&&t.set("hasPlanDocument",e.hasPlanDocument?"true":"false"),e?.q&&t.set("q",e.q),e?.limit&&t.set("limit",String(e.limit)),e?.offset!==void 0&&t.set("offset",String(e.offset)),e?.sortField&&t.set("sortField",e.sortField),e?.sortDir&&t.set("sortDir",e.sortDir),e?.afterId&&t.set("afterId",e.afterId),t}a(Rt,"issueListSearchParams");var Y={listAll:a(async(e,t,r)=>{const o=new Map;let s;for(;;){const l=await Y.list(e,{...t,limit:500,sortField:"id",sortDir:"asc",afterId:s},r);for(const u of l)o.set(u.id,u);if(l.length<500)return[...o.values()];s=l[l.length-1].id}},"listAll"),list:a((e,t,r)=>{const n=Rt(t).toString(),o=`/companies/${e}/issues${n?`?${n}`:""}`;return r?p.get(o,r):p.get(o)},"list"),listCompact:a((e,t,r)=>{const n=Rt(t);n.set("view","compact");const o=`/companies/${e}/issues?${n.toString()}`;return r?p.get(o,r):p.get(o)},"listCompact"),count:a((e,t)=>{const r=new URLSearchParams;return r.set("attention",t.attention),t.status&&r.set("status",t.status),t.assigneeAgentId&&r.set("assigneeAgentId",t.assigneeAgentId),t.assigneeUserId&&r.set("assigneeUserId",t.assigneeUserId),t.projectId&&r.set("projectId",t.projectId),t.labelId&&r.set("labelId",t.labelId),t.q&&r.set("q",t.q),p.get(`/companies/${e}/issues/count?${r.toString()}`)},"count"),listLabels:a(e=>p.get(`/companies/${e}/labels`),"listLabels"),createLabel:a((e,t)=>p.post(`/companies/${e}/labels`,t),"createLabel"),deleteLabel:a(e=>p.delete(`/labels/${e}`),"deleteLabel"),get:a((e,t)=>t?p.get(`/issues/${e}`,t):p.get(`/issues/${e}`),"get"),refs:a((e,t)=>p.get(`/companies/${e}/issues/refs?ids=${encodeURIComponent(t.join(","))}`),"refs"),getRunnerGoal:a((e,t)=>{const r=t?`?agentId=${encodeURIComponent(t)}`:"";return p.get(`/issues/${e}/runner-goal${r}`)},"getRunnerGoal"),actOnRunnerGoal:a((e,t)=>p.post(`/issues/${e}/runner-goal/actions`,t),"actOnRunnerGoal"),getModelOverride:a(e=>p.get(`/issues/${e}/model-override`),"getModelOverride"),setModelOverride:a((e,t)=>p.put(`/issues/${e}/model-override`,t),"setModelOverride"),getWatchdog:a(e=>p.get(`/issues/${e}/watchdog`),"getWatchdog"),getAgentTodo:a(e=>p.get(`/issues/${e}/agent-todo`),"getAgentTodo"),upsertWatchdog:a((e,t)=>p.put(`/issues/${e}/watchdog`,t),"upsertWatchdog"),deleteWatchdog:a(e=>p.delete(`/issues/${e}/watchdog`),"deleteWatchdog"),markRead:a(e=>p.post(`/issues/${e}/read`,{}),"markRead"),markUnread:a(e=>p.delete(`/issues/${e}/read`),"markUnread"),archiveFromInbox:a(e=>p.post(`/issues/${e}/inbox-archive`,{}),"archiveFromInbox"),unarchiveFromInbox:a(e=>p.delete(`/issues/${e}/inbox-archive`),"unarchiveFromInbox"),setTitle:a((e,t)=>p.put(`/issues/${e}/title`,t),"setTitle"),create:a((e,t)=>p.post(`/companies/${e}/issues`,t),"create"),update:a((e,t)=>{const r=p.patch(`/issues/${e}`,t);return typeof t.comment=="string"?Et(r,n=>It(n?.comment)):r},"update"),decideStalledReview:a((e,t)=>p.post(`/issues/${e}/stalled-review-decision`,t),"decideStalledReview"),retryWorkspaceExport:a((e,t)=>p.post(`/issues/${e}/recovery-actions/retry-workspace-export`,t),"retryWorkspaceExport"),resolveRecoveryAction:a((e,t)=>p.post(`/issues/${e}/recovery-actions/resolve`,t),"resolveRecoveryAction"),previewTreeControl:a((e,t)=>p.post(`/issues/${e}/tree-control/preview`,t),"previewTreeControl"),createTreeHold:a((e,t)=>p.post(`/issues/${e}/tree-holds`,t),"createTreeHold"),getTreeHold:a((e,t)=>p.get(`/issues/${e}/tree-holds/${t}`),"getTreeHold"),listTreeHolds:a((e,t)=>{const r=new URLSearchParams;t?.status&&r.set("status",t.status),t?.mode&&r.set("mode",t.mode),t?.includeMembers&&r.set("includeMembers","true");const n=r.toString();return p.get(`/issues/${e}/tree-holds${n?`?${n}`:""}`)},"listTreeHolds"),getTreeControlState:a(e=>p.get(`/issues/${e}/tree-control/state`),"getTreeControlState"),releaseTreeHold:a((e,t,r)=>p.post(`/issues/${e}/tree-holds/${t}/release`,r),"releaseTreeHold"),checkMonitorNow:a(e=>p.post(`/issues/${e}/monitor/check-now`,{}),"checkMonitorNow"),retryScheduledRetryNow:a(e=>p.post(`/issues/${e}/scheduled-retry/retry-now`,{}),"retryScheduledRetryNow"),remove:a(e=>p.delete(`/issues/${e}`),"remove"),checkout:a((e,t)=>p.post(`/issues/${e}/checkout`,{agentId:t,expectedStatuses:["todo","backlog","blocked","in_review"]}),"checkout"),release:a(e=>p.post(`/issues/${e}/release`,{}),"release"),listComments:a((e,t)=>{const r=new URLSearchParams;t?.after&&r.set("after",t.after),t?.order&&r.set("order",t.order),t?.limit&&r.set("limit",String(t.limit));const n=r.toString();return p.get(`/issues/${e}/comments${n?`?${n}`:""}`)},"listComments"),getQueuedComments:a(e=>p.get(`/issues/${e}/queued-comments`),"getQueuedComments"),editQueuedComment:a((e,t,r)=>p.patch(`/issues/${e}/queued-comments/${t}`,r),"editQueuedComment"),reorderQueuedComments:a((e,t)=>p.put(`/issues/${e}/queued-comments/order`,t),"reorderQueuedComments"),interruptQueuedComments:a((e,t)=>p.post(`/issues/${e}/queued-comments/interrupt`,t),"interruptQueuedComments"),interruptLatestQueuedComments:a(async(e,t)=>{const r=await Y.getQueuedComments(e);if(!r.queueId||r.targetRunId&&r.targetRunId!==t)throw new Error("The queued messages changed. Refresh and try again.");return Y.interruptQueuedComments(e,{queueId:r.queueId,revision:r.revision,targetRunId:r.targetRunId})},"interruptLatestQueuedComments"),steerQueuedComment:a((e,t,r)=>p.post(`/issues/${e}/queued-comments/${t}/steer`,r),"steerQueuedComment"),discardQueuedComment:a((e,t,r)=>p.delete(`/issues/${e}/queued-comments/${t}`,r),"discardQueuedComment"),listInteractions:a(e=>p.get(`/issues/${e}/interactions`),"listInteractions"),listAcceptedPlanDecompositions:a(e=>p.get(`/issues/${e}/accepted-plan-decompositions`),"listAcceptedPlanDecompositions"),createInteraction:a((e,t)=>p.post(`/issues/${e}/interactions`,t),"createInteraction"),acceptInteraction:a((e,t,r)=>{const{note:n,...o}=r??{};return p.post(`/issues/${e}/interactions/${t}/accept`,n?.trim()?{...o,note:n}:o)},"acceptInteraction"),rejectInteraction:a((e,t,r,n)=>p.post(`/issues/${e}/interactions/${t}/reject`,{...r?{reason:r}:{},...n?.trim()?{note:n}:{}}),"rejectInteraction"),cancelInteraction:a((e,t,r)=>p.post(`/issues/${e}/interactions/${t}/cancel`,r?{reason:r}:{}),"cancelInteraction"),skipInteraction:a((e,t,r)=>p.post(`/issues/${e}/interactions/${t}/skip`,r?{reason:r}:{}),"skipInteraction"),respondToInteraction:a((e,t,r)=>p.post(`/issues/${e}/interactions/${t}/respond`,r),"respondToInteraction"),submitInteractionVerdicts:a((e,t,r)=>p.post(`/issues/${e}/interactions/${t}/verdicts`,{verdicts:r}),"submitInteractionVerdicts"),getComment:a((e,t)=>p.get(`/issues/${e}/comments/${t}`),"getComment"),listFeedbackVotes:a(e=>p.get(`/issues/${e}/feedback-votes`),"listFeedbackVotes"),getCostSummary:a((e,t={})=>{const r=t.excludeRoot?"?excludeRoot=true":"";return p.get(`/issues/${e}/cost-summary${r}`)},"getCostSummary"),listFeedbackTraces:a((e,t)=>{const r=new URLSearchParams;for(const[o,s]of Object.entries(t??{}))s!==void 0&&r.set(o,String(s));const n=r.toString();return p.get(`/issues/${e}/feedback-traces${n?`?${n}`:""}`)},"listFeedbackTraces"),upsertFeedbackVote:a((e,t)=>p.post(`/issues/${e}/feedback-votes`,t),"upsertFeedbackVote"),addComment:a((e,t,r,n,o,s,l)=>Et(p.post(`/issues/${e}/comments`,{body:t,...s?{clientRequestId:s}:{},...r===void 0?{}:{reopen:r},...n===void 0?{}:{interrupt:n},...o?.length?{attachmentIds:o}:{},...l===void 0?{}:{deliver:l}}),It),"addComment"),cancelComment:a((e,t)=>p.delete(`/issues/${e}/comments/${t}?mode=cancel`),"cancelComment"),deleteComment:a((e,t)=>p.delete(`/issues/${e}/comments/${t}`),"deleteComment"),listDocuments:a((e,t)=>p.get(`/issues/${e}/documents${t?.includeSystem?"?includeSystem=true":""}`),"listDocuments"),getDocument:a((e,t)=>p.get(`/issues/${e}/documents/${encodeURIComponent(t)}`),"getDocument"),getDocumentPdf:a((e,t)=>p.getBlob(`/issues/${e}/documents/${encodeURIComponent(t)}/pdf`),"getDocumentPdf"),upsertDocument:a((e,t,r)=>p.put(`/issues/${e}/documents/${encodeURIComponent(t)}`,r),"upsertDocument"),lockDocument:a((e,t)=>p.post(`/issues/${e}/documents/${encodeURIComponent(t)}/lock`,{}),"lockDocument"),unlockDocument:a((e,t)=>p.post(`/issues/${e}/documents/${encodeURIComponent(t)}/unlock`,{}),"unlockDocument"),listDocumentRevisions:a((e,t)=>p.get(`/issues/${e}/documents/${encodeURIComponent(t)}/revisions`),"listDocumentRevisions"),restoreDocumentRevision:a((e,t,r)=>p.post(`/issues/${e}/documents/${encodeURIComponent(t)}/revisions/${r}/restore`,{}),"restoreDocumentRevision"),deleteDocument:a((e,t)=>p.delete(`/issues/${e}/documents/${encodeURIComponent(t)}`),"deleteDocument"),listAttachments:a(e=>p.get(`/issues/${e}/attachments`),"listAttachments"),uploadAttachment:a((e,t,r,n)=>{const o=Vn(r);if(o)return Promise.reject(o);const s=new FormData;return s.append("file",r),n&&s.append("issueCommentId",n),p.postForm(`/companies/${e}/issues/${t}/attachments`,s)},"uploadAttachment"),deleteAttachment:a(e=>p.delete(`/attachments/${e}`),"deleteAttachment"),privacyConstraints:a(e=>p.get(`/issues/${e}/privacy-constraints`),"privacyConstraints"),listAccessGrants:a((e,t)=>t?p.get(`/issues/${e}/access-grants`,t):p.get(`/issues/${e}/access-grants`),"listAccessGrants"),createAccessGrant:a((e,t)=>p.post(`/issues/${e}/access-grants`,t),"createAccessGrant"),revokeAccessGrant:a((e,t)=>p.post(`/issues/${e}/access-grants/${t}/revoke`,{}),"revokeAccessGrant"),setVisibility:a((e,t)=>p.patch(`/issues/${e}`,{visibility:t}),"setVisibility"),listApprovals:a(e=>p.get(`/issues/${e}/approvals`),"listApprovals"),linkApproval:a((e,t)=>p.post(`/issues/${e}/approvals`,{approvalId:t}),"linkApproval"),unlinkApproval:a((e,t)=>p.delete(`/issues/${e}/approvals/${t}`),"unlinkApproval"),listWorkProducts:a((e,t)=>{const r=`/issues/${e}/work-products${t?.refreshPullRequests?"?refreshPullRequests=true":""}`;return t?.fresh&&Hn(r),p.get(r,{signal:t?.signal})},"listWorkProducts"),ensureWorkProductReviewDocument:a((e,t)=>p.post(`/issues/${e}/work-products/${t}/review-document`,{}),"ensureWorkProductReviewDocument"),createWorkProduct:a((e,t)=>p.post(`/issues/${e}/work-products`,t),"createWorkProduct"),updateWorkProduct:a((e,t)=>p.patch(`/work-products/${e}`,t),"updateWorkProduct"),deleteWorkProduct:a(e=>p.delete(`/work-products/${e}`),"deleteWorkProduct")};function Z(e){return new Date(e).getTime()}a(Z,"toTimestamp");function ms(){const e=globalThis.crypto?.randomUUID?.();return e?`optimistic-${e}`:`optimistic-${Date.now()}-${Math.random().toString(36).slice(2,10)}`}a(ms,"createOptimisticCommentId");function et(e){return[...e].sort((t,r)=>{const n=Z(t.createdAt)-Z(r.createdAt);return n!==0?n:t.id.localeCompare(r.id)})}a(et,"sortIssueComments");function Ct(e){return et(e).reverse()}a(Ct,"sortIssueCommentsDesc");function Al(e){const t=new Date,r=ms();return{id:r,clientId:r,companyId:e.companyId,issueId:e.issueId,authorType:"user",authorAgentId:null,authorUserId:e.authorUserId,body:e.body,presentation:null,metadata:null,clientStatus:e.clientStatus??"pending",queueTargetRunId:e.queueTargetRunId??null,createdAt:t,updatedAt:t}}a(Al,"createOptimisticIssueComment");function Ml(e){return e.runId||e.interruptedRunId||e.comment.id&&(e.comment.id===e.activeRunWakeCommentId||e.comment.id===e.activeRunCommentId)||e.comment.authorAgentId&&e.activeRunAgentId&&e.comment.authorAgentId===e.activeRunAgentId?!1:e.comment.clientStatus==="queued"?!0:e.activeRunStartedAt?Z(e.comment.createdAt)>=Z(e.activeRunStartedAt):!1}a(Ml,"isQueuedIssueComment");function Tl(e,t){const r=t.queuedTargetRunId??null;return!r||!t.targetRunIsLive||t.runningRunId&&t.runningRunId!==r?e:{...e,clientStatus:"queued",queueState:"queued",queueTargetRunId:r}}a(Tl,"applyLocalQueuedIssueCommentState");function Pl(e,t){const r=e??[],n=[...r],o=new Set(n.map(l=>l.id)),s=new Set;for(const l of t){if(o.has(l.id))continue;const u=r.find(c=>!s.has(c.id)&&c.issueId===l.issueId&&c.authorType===l.authorType&&c.authorUserId===l.authorUserId&&c.body===l.body&&Math.abs(Z(c.createdAt)-Z(l.createdAt))<=6e4);if(u){s.add(u.id);const c={...u,clientId:l.clientId};n[n.findIndex(d=>d.id===u.id)]=c;continue}n.push(l)}return et(n)}a(Pl,"mergeIssueComments");function Ll(e,t){const r=e.findIndex(n=>n.clientId===t);return r===-1?{comments:e,comment:null}:{comments:e.filter(n=>n.clientId!==t),comment:e[r]??null}}a(Ll,"takeOptimisticIssueComment");function Ol(e){return et((e??[]).flatMap(t=>t))}a(Ol,"flattenIssueCommentPages");function hs(e,t){if(!(!e||e.length<t))return e[e.length-1]?.id}a(hs,"getNextIssueCommentPageParam");function $t(e,t){if(!(!e||e.length<t))return e[e.length-1]?.id}a($t,"getNextPageCursor");async function jl(e){const t=(e.pages??[]).map(l=>[...l]),r=e.pageParams?[...e.pageParams].slice(0,t.length):t.map(()=>null);for(;r.length<t.length;)r.push(null);if(e.pageSize<=0)return{pages:t,pageParams:r};let n=$t(t[t.length-1],e.pageSize);const o=Math.max(0,e.maxPages??Number.POSITIVE_INFINITY),s=new Set;for(;n&&!s.has(n)&&s.size<o;){s.add(n);const l=[...await e.fetchPage(n)];t.push(l),r.push(n),n=$t(l,e.pageSize)}return{pages:t,pageParams:r}}a(jl,"loadRemainingIssueCommentPages");function Nl(e){return e.activeDetailTab!=="chat"||!e.hasOlderComments||e.initialPageLoading||e.olderPageLoading||e.loadedCommentCount===0?!1:e.loadedCommentCount<e.autoLoadLimit}a(Nl,"shouldAutoloadOlderIssueComments");function Bl(e,t){if(!e)return e;const r={...e};return t.reopen===!0&&(e.status==="done"||e.status==="cancelled"||e.status==="blocked")&&(r.status="todo"),t.reassignment&&(r.assigneeAgentId=t.reassignment.assigneeAgentId,r.assigneeUserId=t.reassignment.assigneeUserId),r}a(Bl,"applyOptimisticIssueCommentUpdate");function ps(e,t){if(!e)return e;const r={...e,updatedAt:new Date},n=a(s=>Object.prototype.hasOwnProperty.call(t,s),"hasOwn"),o=a(s=>{n(s)&&(r[s]=t[s])},"assign");if(o("status"),o("priority"),o("assigneeAgentId"),o("assigneeUserId"),o("projectId"),o("parentId"),o("projectWorkspaceId"),o("executionWorkspaceId"),o("executionWorkspacePreference"),o("executionWorkspaceSettings"),o("hiddenAt"),n("labelIds")&&Array.isArray(t.labelIds)){const s=t.labelIds.filter(l=>typeof l=="string");r.labelIds=s,e.labels&&(r.labels=e.labels.filter(l=>s.includes(l.id)))}if(n("blockedByIssueIds")&&Array.isArray(t.blockedByIssueIds)&&e.blockedBy){const s=new Set(t.blockedByIssueIds.filter(l=>typeof l=="string"));r.blockedBy=e.blockedBy.filter(l=>s.has(l.id))}return n("projectId")&&(r.project=e.project?.id===r.projectId?e.project:null),n("parentId")&&(r.ancestors=void 0),n("executionWorkspaceId")&&(r.currentExecutionWorkspace=e.currentExecutionWorkspace?.id===r.executionWorkspaceId?e.currentExecutionWorkspace:null),r}a(ps,"applyOptimisticIssueFieldUpdate");function gs(e,t){const r=t instanceof Set?t:new Set(t);return r.has(e.id)||!!e.identifier&&r.has(e.identifier)}a(gs,"matchesIssueRef$1");function Ul(e,t,r){if(!e)return e;let n=!1;const o=e.map(s=>gs(s,t)?(n=!0,ps(s,r)??s):s);return n?o:e}a(Ul,"applyOptimisticIssueFieldUpdateToCollection");function zl(e,t){if(!e||e.length===0)return[[t]];const r=e.map(n=>[...n]);for(let n=0;n<r.length;n+=1){const o=r[n].findIndex(s=>s.id===t.id);if(o!==-1)return r[n][o]=t,r[n]=Ct(r[n]),r}return r[0]=Ct([...r[0],t]),r}a(zl,"upsertIssueCommentInPages");function Fl(e,t){return!e||e.length===0?[]:e.map(r=>r.filter(n=>n.id!==t)).filter(r=>r.length>0)}a(Fl,"removeIssueCommentFromPages");var ys=["issues","detail"],Er=6e4,bs=3e4;function ie(e){return typeof e=="string"&&e.length>0}a(ie,"isNonEmptyString");function Rr(e,t){const r=new Set;return ie(e)&&r.add(e),ie(t?.id)&&r.add(t.id),ie(t?.identifier)&&r.add(t.identifier),Array.from(r)}a(Rr,"collectIssueRefs");function vs(e,t){const r=t instanceof Set?t:new Set(t);return r.has(e.id)||!!e.identifier&&r.has(e.identifier)}a(vs,"matchesIssueRef");function Se(e){if(typeof e!="object"||e===null)return!1;const t=e;return ie(t.id)&&ie(t.companyId)&&typeof t.title=="string"&&typeof t.status=="string"&&typeof t.workMode=="string"&&typeof t.priority=="string"&&(t.projectId===null||typeof t.projectId=="string")&&(t.parentId===null||typeof t.parentId=="string")&&(t.identifier===null||typeof t.identifier=="string")&&(t.description===null||typeof t.description=="string")&&(t.assigneeAgentId===null||typeof t.assigneeAgentId=="string")&&(t.assigneeUserId===null||typeof t.assigneeUserId=="string")&&(t.executionRunId===null||typeof t.executionRunId=="string")&&(t.issueNumber===null||typeof t.issueNumber=="number")&&typeof t.requestDepth=="number"&&t.createdAt!=null&&t.updatedAt!=null}a(Se,"isCompleteIssueSnapshot");function _t(e,t){return e?{...e,...t}:t}a(_t,"mergeIssueSnapshots");function Cr(e,t,r){const n=Rr(t,r);for(const o of n){const s=e.getQueryData(ce.issues.detail(o));if(Se(s))return s}return e.getQueriesData({queryKey:ys}).map(([,o])=>o).find(o=>Se(o)&&vs(o,n))}a(Cr,"getCachedIssueDetail");function $r(e,t,r){if(!Se(t))return t;const n=Rr(r?.issueRef,t),o=_t(Cr(e,r?.issueRef,t),t);for(const s of n)e.setQueryData(ce.issues.detail(s),l=>_t(l,o));return o}a($r,"seedIssueDetailCache");async function _r(e,t,r){return $r(e,r?await Y.get(t,r):await Y.get(t),{issueRef:t})}a(_r,"fetchIssueDetail");function ks(e,t,r){return{queryKey:ce.issues.detail(t),queryFn:a(({signal:n})=>_r(e,t,{signal:n}),"queryFn"),placeholderData:Cr(e,t,r?.placeholderIssue??void 0)}}a(ks,"getIssueDetailQueryOptions");function xs(e,t,r){return Se(r?.issue)&&$r(e,r.issue,{issueRef:t}),e.prefetchQuery({queryKey:ce.issues.detail(t),queryFn:a(()=>_r(e,t),"queryFn"),staleTime:Er})}a(xs,"prefetchIssueDetail");function ws(e,t){return e.prefetchInfiniteQuery({queryKey:ce.issues.comments(t),queryFn:a(({pageParam:r})=>Y.listComments(t,{order:"desc",limit:50,...r?{after:r}:{}}),"queryFn"),initialPageParam:null,getNextPageParam:a(r=>hs(r,50),"getNextPageParam"),staleTime:bs,pages:1})}a(ws,"prefetchIssueComments");function Ss(e,t,r){return Promise.all([xs(e,t,r),ws(e,r?.issue?.id??t)])}a(Ss,"prefetchIssueDetailForNavigation");var S=Nt(qn(),1);function Is({...e}){return(0,S.jsx)(ra,{"data-slot":"popover",...e})}a(Is,"Popover");function Es({...e}){return(0,S.jsx)(Qn,{"data-slot":"popover-trigger",...e})}a(Es,"PopoverTrigger");function Rs({className:e,align:t="center",sideOffset:r=4,disablePortal:n=!1,...o}){const s=(0,S.jsx)(ta,{"data-slot":"popover-content",align:t,sideOffset:r,className:V("bg-bg-2 text-ink data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 w-72 origin-(--radix-popover-content-transform-origin) rounded-md border p-4 shadow-md outline-hidden",e),...o});return n?s:(0,S.jsx)(Xn,{children:s})}a(Rs,"PopoverContent");function ql({...e}){return(0,S.jsx)(Gn,{"data-slot":"popover-anchor",...e})}a(ql,"PopoverAnchor");function Hl({className:e,...t}){return(0,S.jsx)("div",{"data-slot":"popover-title",className:V("font-medium",e),...t})}a(Hl,"PopoverTitle");function Wl({className:e,...t}){return(0,S.jsx)("p",{"data-slot":"popover-description",className:V("text-ink-3",e),...t})}a(Wl,"PopoverDescription");var Dr={name:"atom",size:24,node:[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["path",{d:"M20.2 20.2c2.04-2.03.02-7.36-4.5-11.9-4.54-4.52-9.87-6.54-11.9-4.5-2.04 2.03-.02 7.36 4.5 11.9 4.54 4.52 9.87 6.54 11.9 4.5Z",key:"1l2ple"}],["path",{d:"M15.7 15.7c4.52-4.54 6.54-9.87 4.5-11.9-2.03-2.04-7.36-.02-11.9 4.5-4.52 4.54-6.54 9.87-4.5 11.9 2.03 2.04 7.36.02 11.9-4.5Z",key:"1wam0m"}]]};Dr.node;var Cs=x(Dr),Ar={name:"ban",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M4.929 4.929 19.07 19.071",key:"196cmz"}]]};Ar.node;var $s=x(Ar),Mr={name:"box",size:24,node:[["path",{d:"M21 8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z",key:"hh9hay"}],["path",{d:"m3.3 7 8.7 5 8.7-5",key:"g66t2b"}],["path",{d:"M12 22V12",key:"d0xqtd"}]]};Mr.node;var _s=x(Mr),Tr={name:"brain",size:24,node:[["path",{d:"M12 18V5",key:"adv99a"}],["path",{d:"M15 13a4.17 4.17 0 0 1-3-4 4.17 4.17 0 0 1-3 4",key:"1e3is1"}],["path",{d:"M17.598 6.5A3 3 0 1 0 12 5a3 3 0 1 0-5.598 1.5",key:"1gqd8o"}],["path",{d:"M17.997 5.125a4 4 0 0 1 2.526 5.77",key:"iwvgf7"}],["path",{d:"M18 18a4 4 0 0 0 2-7.464",key:"efp6ie"}],["path",{d:"M19.967 17.483A4 4 0 1 1 12 18a4 4 0 1 1-7.967-.517",key:"1gq6am"}],["path",{d:"M6 18a4 4 0 0 1-2-7.464",key:"k1g0md"}],["path",{d:"M6.003 5.125a4 4 0 0 0-2.526 5.77",key:"q97ue3"}]]};Tr.node;var Ds=x(Tr),Pr={name:"briefcase",size:24,node:[["path",{d:"M16 20V4a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v16",key:"jecpp"}],["rect",{width:"20",height:"14",x:"2",y:"6",rx:"2",key:"i6l2r4"}]]};Pr.node;var As=x(Pr),Lr={name:"bug",size:24,node:[["path",{d:"M12 20v-9",key:"1qisl0"}],["path",{d:"M14 7a4 4 0 0 1 4 4v3a6 6 0 0 1-12 0v-3a4 4 0 0 1 4-4z",key:"uouzyp"}],["path",{d:"M14.12 3.88 16 2",key:"qol33r"}],["path",{d:"M21 21a4 4 0 0 0-3.81-4",key:"1b0z45"}],["path",{d:"M21 5a4 4 0 0 1-3.55 3.97",key:"5cxbf6"}],["path",{d:"M22 13h-4",key:"1jl80f"}],["path",{d:"M3 21a4 4 0 0 1 3.81-4",key:"1fjd4g"}],["path",{d:"M3 5a4 4 0 0 0 3.55 3.97",key:"1d7oge"}],["path",{d:"M6 13H2",key:"82j7cp"}],["path",{d:"m8 2 1.88 1.88",key:"fmnt4t"}],["path",{d:"M9 7.13V6a3 3 0 1 1 6 0v1.13",key:"1vgav8"}]]};Lr.node;var Ms=x(Lr),Or={name:"check",size:24,node:[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]};Or.node;var Vl=x(Or),jr={name:"chevron-right",size:24,node:[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]};jr.node;var Kl=x(jr),Nr={name:"circle-check",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m16 9-5.5 5.5L8 12",key:"xofnsj"}]],aliases:["check-circle-2"]};Nr.node;var Ts=x(Nr),Br={name:"circle-dashed",size:24,node:[["path",{d:"M10.1 2.182a10 10 0 0 1 3.8 0",key:"5ilxe3"}],["path",{d:"M13.9 21.818a10 10 0 0 1-3.8 0",key:"11zvb9"}],["path",{d:"M17.609 3.721a10 10 0 0 1 2.69 2.7",key:"1iw5b2"}],["path",{d:"M2.182 13.9a10 10 0 0 1 0-3.8",key:"c0bmvh"}],["path",{d:"M20.279 17.609a10 10 0 0 1-2.7 2.69",key:"1ruxm7"}],["path",{d:"M21.818 10.1a10 10 0 0 1 0 3.8",key:"qkgqxc"}],["path",{d:"M3.721 6.391a10 10 0 0 1 2.7-2.69",key:"1mcia2"}],["path",{d:"M6.391 20.279a10 10 0 0 1-2.69-2.7",key:"1fvljs"}]]};Br.node;var Ur=x(Br),zr={name:"circle-dot",size:24,node:[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]};zr.node;var Ps=x(zr),Fr={name:"circle-minus",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M8 12h8",key:"1wcyev"}]],aliases:["minus-circle"]};Fr.node;var Dt=x(Fr),qr={name:"circle",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]};qr.node;var At=x(qr),Hr={name:"code",size:24,node:[["path",{d:"m16 18 6-6-6-6",key:"eg8j8"}],["path",{d:"m8 6-6 6 6 6",key:"ppft3o"}]]};Hr.node;var Ls=x(Hr),Wr={name:"cog",size:24,node:[["path",{d:"M11 10.27 7 3.34",key:"16pf9h"}],["path",{d:"m11 13.73-4 6.93",key:"794ttg"}],["path",{d:"M12 22v-2",key:"1osdcq"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M14 12h8",key:"4f43i9"}],["path",{d:"m17 20.66-1-1.73",key:"eq3orb"}],["path",{d:"m17 3.34-1 1.73",key:"2wel8s"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"m20.66 17-1.73-1",key:"sg0v6f"}],["path",{d:"m20.66 7-1.73 1",key:"1ow05n"}],["path",{d:"m3.34 17 1.73-1",key:"nuk764"}],["path",{d:"m3.34 7 1.73 1",key:"1ulond"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}],["circle",{cx:"12",cy:"12",r:"8",key:"46899m"}]]};Wr.node;var Os=x(Wr),Vr={name:"compass",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m16.24 7.76-1.804 5.411a2 2 0 0 1-1.265 1.265L7.76 16.24l1.804-5.411a2 2 0 0 1 1.265-1.265z",key:"9ktpf1"}]]};Vr.node;var js=x(Vr),Kr={name:"copy",size:24,node:[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]};Kr.node;var Ql=x(Kr),Qr={name:"cpu",size:24,node:[["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"}]]};Qr.node;var Ns=x(Qr),Jr={name:"crown",size:24,node:[["path",{d:"M11.562 3.266a.5.5 0 0 1 .876 0L15.39 8.87a1 1 0 0 0 1.516.294L21.183 5.5a.5.5 0 0 1 .798.519l-2.834 10.246a1 1 0 0 1-.956.734H5.81a1 1 0 0 1-.957-.734L2.02 6.02a.5.5 0 0 1 .798-.519l4.276 3.664a1 1 0 0 0 1.516-.294z",key:"1vdc57"}],["path",{d:"M5 21h14",key:"11awu3"}]]};Jr.node;var Bs=x(Jr),Gr={name:"database",size:24,node:[["ellipse",{cx:"12",cy:"5",rx:"9",ry:"3",key:"msslwz"}],["path",{d:"M3 5V19A9 3 0 0 0 21 19V5",key:"1wlel7"}],["path",{d:"M3 12A9 3 0 0 0 21 12",key:"mv7ke4"}]]};Gr.node;var Us=x(Gr),Yr={name:"file-code",size:24,node:[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10 12.5 8 15l2 2.5",key:"1tg20x"}],["path",{d:"m14 12.5 2 2.5-2 2.5",key:"yinavb"}]]};Yr.node;var zs=x(Yr),Xr={name:"flame",size:24,node:[["path",{d:"M12 3q1 4 4 6.5t3 5.5a1 1 0 0 1-14 0 5 5 0 0 1 1-3 1 1 0 0 0 5 0c0-2-1.5-3-1.5-5q0-2 2.5-4",key:"1slcih"}]]};Xr.node;var Fs=x(Xr),Zr={name:"folder",size:24,node:[["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"}]]};Zr.node;var qs=x(Zr),en={name:"gem",size:24,node:[["path",{d:"M10.5 3 8 9l4 13 4-13-2.5-6",key:"b3dvk1"}],["path",{d:"M17 3a2 2 0 0 1 1.6.8l3 4a2 2 0 0 1 .013 2.382l-7.99 10.986a2 2 0 0 1-3.247 0l-7.99-10.986A2 2 0 0 1 2.4 7.8l2.998-3.997A2 2 0 0 1 7 3z",key:"7w4byz"}],["path",{d:"M2 9h20",key:"16fsjt"}]]};en.node;var Hs=x(en),tn={name:"git-branch",size:24,node:[["path",{d:"M15 6a9 9 0 0 0-9 9V3",key:"1cii5b"}],["circle",{cx:"18",cy:"6",r:"3",key:"1h7g24"}],["circle",{cx:"6",cy:"18",r:"3",key:"fqmcym"}]]};tn.node;var Ws=x(tn),rn={name:"globe",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]]};rn.node;var Vs=x(rn),nn={name:"hammer",size:24,node:[["path",{d:"m15 12-9.373 9.373a1 1 0 0 1-3.001-3L12 9",key:"1hayfq"}],["path",{d:"m18 15 4-4",key:"16gjal"}],["path",{d:"m21.5 11.5-1.914-1.914A2 2 0 0 1 19 8.172v-.344a2 2 0 0 0-.586-1.414l-1.657-1.657A6 6 0 0 0 12.516 3H9l1.243 1.243A6 6 0 0 1 12 8.485V10l2 2h1.172a2 2 0 0 1 1.414.586L18.5 14.5",key:"15ts47"}]]};nn.node;var Ks=x(nn),an={name:"heart",size:24,node:[["path",{d:"M2 9.5a5.5 5.5 0 0 1 9.591-3.676.56.56 0 0 0 .818 0A5.49 5.49 0 0 1 22 9.5c0 2.29-1.5 4-3 5.5l-5.492 5.313a2 2 0 0 1-3 .019L5 15c-1.5-1.5-3-3.2-3-5.5",key:"mvr1a0"}]]};an.node;var Qs=x(an),on={name:"hexagon",size:24,node:[["path",{d:"M21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16z",key:"yt0hxn"}]]};on.node;var Js=x(on),sn={name:"layers",size:24,node:[["path",{d:"M12.83 2.18a2 2 0 0 0-1.66 0L2.6 6.08a1 1 0 0 0 0 1.83l8.58 3.91a2 2 0 0 0 1.66 0l8.58-3.9a1 1 0 0 0 0-1.83z",key:"zw3jo"}],["path",{d:"M2 12a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 12",key:"1wduqc"}],["path",{d:"M2 17a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 17",key:"kqbvx6"}]],aliases:["layers-3"]};sn.node;var Gs=x(sn),ln={name:"lightbulb",size:24,node:[["path",{d:"M15 14c.2-1 .7-1.7 1.5-2.5 1-.9 1.5-2.2 1.5-3.5A6 6 0 0 0 6 8c0 1 .2 2.2 1.5 3.5.7.7 1.3 1.5 1.5 2.5",key:"1gvzjb"}],["path",{d:"M9 18h6",key:"x1upvd"}],["path",{d:"M10 22h4",key:"ceow96"}]]};ln.node;var Ys=x(ln),un={name:"loader-circle",size:24,node:[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]],aliases:["loader-2"]};un.node;var Xs=x(un),cn={name:"lock",size:24,node:[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 10 0v4",key:"fwvmzm"}]]};cn.node;var Zs=x(cn),dn={name:"mail",size:24,node:[["path",{d:"m22 7-8.991 5.727a2 2 0 0 1-2.009 0L2 7",key:"132q7q"}],["rect",{x:"2",y:"4",width:"20",height:"16",rx:"2",key:"izxlao"}]]};dn.node;var ei=x(dn),fn={name:"message-square",size:24,node:[["path",{d:"M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z",key:"18887p"}]]};fn.node;var ti=x(fn),mn={name:"package",size:24,node:[["path",{d:"M11 21.73a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73z",key:"1a0edw"}],["path",{d:"M12 22V12",key:"d0xqtd"}],["polyline",{points:"3.29 7 12 12 20.71 7",key:"ousv84"}],["path",{d:"m7.5 4.27 9 5.15",key:"1c824w"}]]};mn.node;var ri=x(mn),hn={name:"plus",size:24,node:[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]};hn.node;var Jl=x(hn),pn={name:"puzzle",size:24,node:[["path",{d:"M15.39 4.39a1 1 0 0 0 1.68-.474 2.5 2.5 0 1 1 3.014 3.015 1 1 0 0 0-.474 1.68l1.683 1.682a2.414 2.414 0 0 1 0 3.414L19.61 15.39a1 1 0 0 1-1.68-.474 2.5 2.5 0 1 0-3.014 3.015 1 1 0 0 1 .474 1.68l-1.683 1.682a2.414 2.414 0 0 1-3.414 0L8.61 19.61a1 1 0 0 0-1.68.474 2.5 2.5 0 1 1-3.014-3.015 1 1 0 0 0 .474-1.68l-1.683-1.682a2.414 2.414 0 0 1 0-3.414L4.39 8.61a1 1 0 0 1 1.68.474 2.5 2.5 0 1 0 3.014-3.015 1 1 0 0 1-.474-1.68l1.683-1.682a2.414 2.414 0 0 1 3.414 0z",key:"w46dr5"}]]};pn.node;var ni=x(pn),gn={name:"radar",size:24,node:[["path",{d:"M19.07 4.93A10 10 0 0 0 6.99 3.34",key:"z3du51"}],["path",{d:"M4 6h.01",key:"oypzma"}],["path",{d:"M2.29 9.62A10 10 0 1 0 21.31 8.35",key:"qzzz0"}],["path",{d:"M16.24 7.76A6 6 0 1 0 8.23 16.67",key:"1yjesh"}],["path",{d:"M12 18h.01",key:"mhygvu"}],["path",{d:"M17.99 11.66A6 6 0 0 1 15.77 16.67",key:"1u2y91"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}],["path",{d:"m13.41 10.59 5.66-5.66",key:"mhq4k0"}]]};gn.node;var ai=x(gn),yn={name:"rocket",size:24,node:[["path",{d:"M12 15v5s3.03-.55 4-2c1.08-1.62 0-5 0-5",key:"qeys4"}],["path",{d:"M4.5 16.5c-1.5 1.26-2 5-2 5s3.74-.5 5-2c.71-.84.7-2.13-.09-2.91a2.18 2.18 0 0 0-2.91-.09",key:"u4xsad"}],["path",{d:"M9 12a22 22 0 0 1 2-3.95A12.88 12.88 0 0 1 22 2c0 2.72-.78 7.5-6 11a22.4 22.4 0 0 1-4 2z",key:"676m9"}],["path",{d:"M9 12H4s.55-3.03 2-4c1.62-1.08 5 .05 5 .05",key:"92ym6u"}]]};yn.node;var oi=x(yn),bn={name:"search",size:24,node:[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]]};bn.node;var si=x(bn),vn={name:"shield",size:24,node:[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}]]};vn.node;var ii=x(vn),kn={name:"sparkles",size:24,node:[["path",{d:"M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z",key:"1s2grr"}],["path",{d:"M20 2v4",key:"1rf3ol"}],["path",{d:"M22 4h-4",key:"gwowj6"}],["circle",{cx:"4",cy:"20",r:"2",key:"6kqj1y"}]],aliases:["stars"]};kn.node;var li=x(kn),xn={name:"star",size:24,node:[["path",{d:"M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z",key:"r04s7s"}]]};xn.node;var ui=x(xn),wn={name:"target",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["circle",{cx:"12",cy:"12",r:"6",key:"1vlfrh"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}]]};wn.node;var ci=x(wn),Sn={name:"telescope",size:24,node:[["path",{d:"m10.065 12.493-6.18 1.318a.934.934 0 0 1-1.108-.702l-.537-2.15a1.07 1.07 0 0 1 .691-1.265l13.504-4.44",key:"k4qptu"}],["path",{d:"m13.56 11.747 4.332-.924",key:"19l80z"}],["path",{d:"m16 21-3.105-6.21",key:"7oh9d"}],["path",{d:"M16.485 5.94a2 2 0 0 1 1.455-2.425l1.09-.272a1 1 0 0 1 1.212.727l1.515 6.06a1 1 0 0 1-.727 1.213l-1.09.272a2 2 0 0 1-2.425-1.455z",key:"m7xp4m"}],["path",{d:"m6.158 8.633 1.114 4.456",key:"74o979"}],["path",{d:"m8 21 3.105-6.21",key:"1fvxut"}],["circle",{cx:"12",cy:"13",r:"2",key:"1c1ljs"}]]};Sn.node;var di=x(Sn),In={name:"terminal",size:24,node:[["path",{d:"M12 19h8",key:"baeox8"}],["path",{d:"m4 17 6-6-6-6",key:"1yngyt"}]]};In.node;var fi=x(In),En={name:"wrench",size:24,node:[["path",{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.106-3.105c.32-.322.863-.22.983.218a6 6 0 0 1-8.259 7.057l-7.91 7.91a1 1 0 0 1-2.999-3l7.91-7.91a6 6 0 0 1 7.057-8.259c.438.12.54.662.219.984z",key:"1ngwbx"}]]};En.node;var mi=x(En),Rn={name:"zap",size:24,node:[["path",{d:"M15.914 4a1.5 1.5 0 00-2.474-1.561l-9 9A1.5 1.5 0 005.5 14h4.002a.5.5 0 01.471.666L8.086 20a1.5 1.5 0 002.475 1.56l9-9A1.5 1.5 0 0018.5 10h-3.997a.5.5 0 01-.472-.667z",key:"1v7up4"}]]};Rn.node;var hi=x(Rn),Gl={backlog:"text-ink-3 border-ink-3",todo:"text-amber-600 border-amber-600 dark:text-amber-400 dark:border-amber-400",in_progress:"text-blue-600 border-blue-600 dark:text-blue-400 dark:border-blue-400",in_review:"text-violet-600 border-violet-600 dark:text-violet-400 dark:border-violet-400",done:"text-green-600 border-green-600 dark:text-green-400 dark:border-green-400",cancelled:"text-neutral-500 border-neutral-500",blocked:"text-red-600 border-red-600 dark:text-red-400 dark:border-red-400"},Yl="text-ink-3 border-ink-3",Xl={backlog:"text-ink-3",todo:"text-amber-600 dark:text-amber-400",in_progress:"text-blue-600 dark:text-blue-400",in_review:"text-violet-600 dark:text-violet-400",done:"text-green-600 dark:text-green-400",cancelled:"text-neutral-500",blocked:"text-red-600 dark:text-red-400"},Zl="text-ink-3",ye={gray:"bg-[#F5F3F0] text-[#52585D] border-[#A8AEB2] dark:bg-[#6e696024] dark:text-[#9A958A] dark:border-[#9e958a73]",blue:"bg-[#DBEAFE] text-[#1D4ED8] border-[#2563EB] dark:bg-[#2563eb2e] dark:text-[#2563EB] dark:border-[#2563eb73]",amber:"bg-[#FEF3C7] text-[#B45309] border-[#F59E0B] dark:bg-[#f59e0b24] dark:text-[#F59E0B] dark:border-[#f59e0b73]",green:"bg-[#DCFCE7] text-[#188A3C] border-[#22C55E] dark:bg-[#22c55e1f] dark:text-[#22C55E] dark:border-[#22c55e73]",violet:"bg-[#EDE9FE] text-[#5B21B6] border-[#7C3AED] dark:bg-[#7c3aed2e] dark:text-[#7C3AED] dark:border-[#7c3aed73]",red:"bg-[#FEE2E2] text-[#991B1B] border-[#DC2626] dark:bg-[#dc26262e] dark:text-[#DC2626] dark:border-[#dc262673]"},eu={active:`border ${ye.green}`,running:`border ${ye.blue}`,scheduled_retry:"bg-sky-100 text-sky-700 dark:bg-sky-900/50 dark:text-sky-300",paused:`border ${ye.amber}`,idle:`border ${ye.gray}`,archived:"bg-bg-3 text-ink-3",planned:"bg-bg-3 text-ink-3",achieved:"bg-green-100 text-green-700 dark:bg-green-900/50 dark:text-green-300",completed:"bg-green-100 text-green-700 dark:bg-green-900/50 dark:text-green-300",failed:"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300",timed_out:"bg-orange-100 text-orange-700 dark:bg-orange-900/50 dark:text-orange-300",succeeded:"bg-green-100 text-green-700 dark:bg-green-900/50 dark:text-green-300",ok:"bg-green-100 text-green-700 dark:bg-green-900/50 dark:text-green-300",warning:"bg-amber-100 text-amber-700 dark:bg-amber-900/50 dark:text-amber-300",error:"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300",info:"bg-sky-100 text-sky-700 dark:bg-sky-900/50 dark:text-sky-300",terminated:"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300",pending:"bg-yellow-100 text-yellow-700 dark:bg-yellow-900/50 dark:text-yellow-300",queued:"bg-yellow-100 text-yellow-700 dark:bg-yellow-900/50 dark:text-yellow-300",pending_approval:"bg-amber-100 text-amber-700 dark:bg-amber-900/50 dark:text-amber-300",revision_requested:"bg-amber-100 text-amber-700 dark:bg-amber-900/50 dark:text-amber-300",approved:"bg-green-100 text-green-700 dark:bg-green-900/50 dark:text-green-300",rejected:"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300",draft:"bg-bg-3 text-ink-3",backlog:"bg-bg-3 text-ink-3",todo:"bg-amber-100 text-amber-700 dark:bg-amber-900/50 dark:text-amber-300",in_progress:"bg-blue-100 text-blue-700 dark:bg-blue-900/50 dark:text-blue-300",in_review:"bg-violet-100 text-violet-700 dark:bg-violet-900/50 dark:text-violet-300",blocked:"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300",done:"bg-green-100 text-green-700 dark:bg-green-900/50 dark:text-green-300",cancelled:"bg-bg-3 text-ink-3",allowed:"bg-green-100 text-green-700 dark:bg-green-900/50 dark:text-green-300",denied:"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300",block:"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300","require-approval":"bg-amber-100 text-amber-700 dark:bg-amber-900/50 dark:text-amber-300",redacted:"bg-violet-100 text-violet-700 dark:bg-violet-900/50 dark:text-violet-300","rate-limit":"bg-orange-100 text-orange-700 dark:bg-orange-900/50 dark:text-orange-300",deferred:"bg-sky-100 text-sky-700 dark:bg-sky-900/50 dark:text-sky-300",hidden:"bg-bg-3 text-ink-3",quarantined:"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300","runtime-error":"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300",healthy:"bg-green-100 text-green-700 dark:bg-green-900/50 dark:text-green-300",degraded:"bg-amber-100 text-amber-700 dark:bg-amber-900/50 dark:text-amber-300",unchecked:"bg-bg-3 text-ink-3"},tu="bg-bg-3 text-ink-3",ru="text-[#1D4ED8] dark:text-[#2563EB]",nu="bg-blue-500/10 border-blue-500/30 text-blue-600 dark:text-blue-400",au={info:"border-[#2563EB]/40 bg-[#DBEAFE]/50 text-[#1D4ED8] dark:border-[#2563eb59] dark:bg-[#2563eb14] dark:text-[#93C5FD]",warning:"border-[#F59E0B]/50 bg-[#FEF3C7]/60 text-[#B45309] dark:border-[#f59e0b59] dark:bg-[#f59e0b12] dark:text-[#F59E0B]",danger:"border-bad/40 bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300"},ou={idle:"--status-agent-idle",active:"--status-agent-idle",running:"--status-agent-running",paused:"--status-agent-paused",error:"--status-agent-error"},su="--status-agent-idle",iu={idle:"--status-task-backlog",backlog:"--status-task-backlog",todo:"--status-task-todo",in_progress:"--status-task-in_progress",in_review:"--status-task-in_review",done:"--status-task-done",blocked:"--status-task-blocked",cancelled:"--status-task-cancelled"},lu="--status-task-backlog",pi={idle:"--status-task-icon-backlog",backlog:"--status-task-icon-backlog",todo:"--status-task-icon-todo",in_progress:"--status-task-icon-in_progress",in_review:"--status-task-icon-in_review",done:"--status-task-icon-done",blocked:"--status-task-icon-blocked",cancelled:"--status-task-icon-cancelled",in_queue:"--status-task-icon-in_queue"};var uu={running:"bg-blue-400 animate-pulse",active:"bg-green-400",paused:"bg-yellow-400",idle:"bg-yellow-400",pending_approval:"bg-amber-400",error:"bg-red-400",archived:"bg-neutral-400"},cu="bg-neutral-400",du={critical:"text-red-600 dark:text-red-400",high:"text-orange-600 dark:text-orange-400",medium:"text-yellow-600 dark:text-yellow-400",low:"text-blue-600 dark:text-blue-400"},fu="text-yellow-600 dark:text-yellow-400",mu={unknown:"text-ink-3 border-ink-3",open:"text-blue-600 border-blue-600 dark:text-blue-400 dark:border-blue-400",waiting:"text-amber-600 border-amber-600 dark:text-amber-400 dark:border-amber-400",running:"text-blue-600 border-blue-600 dark:text-blue-400 dark:border-blue-400",succeeded:"text-green-600 border-green-600 dark:text-green-400 dark:border-green-400",merged:"text-violet-600 border-violet-600 dark:text-violet-400 dark:border-violet-400",failed:"text-red-600 border-red-600 dark:text-red-400 dark:border-red-400",blocked:"text-red-600 border-red-600 dark:text-red-400 dark:border-red-400",closed:"text-neutral-500 border-neutral-500",archived:"text-neutral-500 border-neutral-500",auth_required:"text-amber-600 border-amber-600 dark:text-amber-400 dark:border-amber-400",unreachable:"text-red-600 border-red-600 dark:text-red-400 dark:border-red-400"},hu="text-ink-3 border-ink-3",pu={unknown:"bg-bg-3 text-ink-3",open:"bg-blue-100 text-blue-700 dark:bg-blue-900/50 dark:text-blue-300",waiting:"bg-amber-100 text-amber-700 dark:bg-amber-900/50 dark:text-amber-300",running:"bg-blue-100 text-blue-700 dark:bg-blue-900/50 dark:text-blue-300",succeeded:"bg-green-100 text-green-700 dark:bg-green-900/50 dark:text-green-300",failed:"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300",blocked:"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300",closed:"bg-bg-3 text-ink-3",archived:"bg-bg-3 text-ink-3",auth_required:"bg-amber-100 text-amber-700 dark:bg-amber-900/50 dark:text-amber-300",unreachable:"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300"},gu="bg-bg-3 text-ink-3",yu={unknown:"",fresh:"",stale:"opacity-70 [border-style:dashed]",auth_required:"[border-style:dashed]",unreachable:"[border-style:dashed]"},gi={sm:14,md:16,lg:20},yi=x("TaskProgressSpinner",[["circle",{cx:"12",cy:"12",r:"10",pathLength:"100",strokeDasharray:"80 20",key:"progress"}]]),bi={idle:At,backlog:Ur,todo:At,in_progress:yi,in_review:Ps,done:Ts,blocked:Dt,cancelled:$s,in_queue:Dt},vi=Ur;function ki({status:e,size:t="md",className:r,title:n}){const o=gi[t],s=bi[e]??vi,l=pi[e]??"--status-task-icon-backlog",u=n?{role:"img","aria-label":n}:{"aria-hidden":!0};return(0,S.jsx)(s,{size:o,className:V("inline-block shrink-0 align-middle",e==="in_progress"&&"motion-safe:animate-spin",r),style:{color:`var(${l})`},...u,children:n?(0,S.jsx)("title",{children:n}):null})}a(ki,"StatusGlyph");var Mt={folder:qs,rocket:oi,code:Ls,terminal:fi,database:Us,globe:Vs,package:ri,boxes:ea,box:_s,layers:Gs,briefcase:As,compass:js,target:ci,flame:Fs,zap:hi,star:ui,bug:Ms,wrench:mi,hammer:Ks,lightbulb:Ys,sparkles:li,shield:ii,lock:Zs,search:si,cog:Os,brain:Ds,cpu:Ns,"git-branch":Ws,"file-code":zs,puzzle:ni,gem:Hs,atom:Cs,heart:Qs,mail:ei,"message-square":ti,crown:Bs,radar:ai,telescope:di,hexagon:Js},xi="folder";function wi(e){return e&&Yn.includes(e)?Mt[e]:Mt[xi]}a(wi,"getProjectIcon");var Si={xs:{box:"h-4 w-4 rounded-sm",icon:"h-2.5 w-2.5"},sm:{box:"h-6 w-6 rounded-md",icon:"h-3.5 w-3.5"},md:{box:"h-7 w-7 rounded-lg",icon:"h-4 w-4"},lg:{box:"h-9 w-9 rounded-lg",icon:"h-5 w-5"}};function Ii({color:e,icon:t,size:r="md",className:n}){const o=Si[r],s=!!e,l=wi(t);return(0,S.jsx)("span",{"aria-hidden":!0,className:V("inline-flex shrink-0 items-center justify-center",o.box,s?"text-white":"bg-bg-3 text-ink-3",n),style:s?{backgroundColor:e??void 0}:void 0,children:(0,S.jsx)(l,{className:o.icon})})}a(Ii,"ProjectTile");var le=null,qe=new Set;function Cn(){for(const e of qe)e()}a(Cn,"emitQuicklookChange");function Tt(e){le!==e&&(le=e,Cn())}a(Tt,"openQuicklookId");function Pt(e){le===e&&(le=null,Cn())}a(Pt,"closeQuicklookId");function Ei(e){return qe.add(e),()=>{qe.delete(e)}}a(Ei,"subscribeQuicklook");function Ri(e){return i.useSyncExternalStore(Ei,()=>le===e,()=>!1)}a(Ri,"useIsQuicklookOpen");var Ci=120,$i=13,_i="w-72 p-3";function Di(e="start"){return e==="start"?-13:e==="end"?$i:0}a(Di,"quicklookAlignOffset");function Ai(e){if(!e)return null;const t=e.replace(/!\[[^\]]*]\([^)]+\)/g," ").replace(/\[([^\]]+)\]\([^)]+\)/g,"$1").replace(/[#>*_`~-]+/g," ").replace(/\s+/g," ").trim();return t?t.length>180?`${t.slice(0,177).trimEnd()}...`:t:null}a(Ai,"summarizeIssueDescription");function Mi({className:e}){return(0,S.jsx)("span",{className:V("text-xs",e),"aria-hidden":!0,children:"·"})}a(Mi,"QuicklookSeparator");function Ti(e){const t=e.replace(/_/g," ");return t.charAt(0).toUpperCase()+t.slice(1)}a(Ti,"statusLabel");function Pi({issue:e,linkTo:t,linkState:r,compact:n=!1}){const o=(0,i.useMemo)(()=>Ai(e.description),[e.description]),s=e.project?.name;return(0,S.jsxs)("div",{className:V("space-y-2",n&&"space-y-1.5"),children:[(0,S.jsxs)("div",{className:"flex items-center gap-1",children:[(0,S.jsxs)("div",{className:"flex min-w-0 flex-1 items-center gap-1",children:[(0,S.jsx)(ki,{status:e.status,size:"md",title:Ti(e.status)}),(0,S.jsx)("span",{className:"shrink-0 font-mono text-(length:--text-micro) text-ink-3",children:e.identifier??e.id.slice(0,8)}),s?(0,S.jsxs)(S.Fragment,{children:[(0,S.jsx)(Mi,{className:"shrink-0 text-ink-3"}),(0,S.jsxs)("span",{className:"flex min-w-0 max-w-(--sz-12rem) flex-1 items-center gap-1 text-(length:--text-micro) text-ink-3",title:s,"data-testid":"quicklook-project",children:[(0,S.jsx)(Ii,{size:"xs"}),(0,S.jsx)("span",{className:"truncate",children:s})]})]}):null]}),(0,S.jsx)("span",{className:"shrink-0 text-(length:--text-micro) text-ink-3",children:es(new Date(e.updatedAt))})]}),(0,S.jsx)(me,{to:t,state:r??wr(null,e),className:"block text-sm font-medium leading-snug hover:underline line-clamp-2",children:e.title}),o?(0,S.jsx)("p",{className:"text-xs leading-5 text-ink-3 [display:-webkit-box] [-webkit-box-orient:vertical] [-webkit-line-clamp:4] overflow-hidden",children:o}):null]})}a(Pi,"IssueQuicklookCard");var Li=i.forwardRef(a(function({issuePathId:t,to:r,children:n,className:o,state:s,disableIssueQuicklook:l=!1,issuePrefetch:u=null,issueQuicklookSide:c="top",issueQuicklookAlign:d="start",onClick:f,onClickCapture:m,onMouseEnter:g,onFocus:v,onBlur:b,onTouchStart:y,...h},k){const w=Fn(),I=i.useMemo(()=>Symbol("issue-quicklook"),[]),$=Ri(I),E=i.useRef(null),_=i.useRef(null),M=i.useRef(null),j=i.useCallback(R=>{_.current=R,typeof k=="function"?k(R):k&&(k.current=R)},[k]),D=i.useCallback(()=>{E.current&&(clearTimeout(E.current),E.current=null)},[]),B=i.useCallback(()=>{D(),Tt(I)},[D,I]),J=i.useCallback(()=>{D(),E.current=setTimeout(()=>{E.current=null,Tt(I)},Ci)},[D,I]),L=i.useCallback(()=>{D(),Pt(I)},[D,I]);i.useEffect(()=>()=>{D(),Pt(I)},[D,I]),i.useEffect(()=>{if(!$)return;const R=12,ot=a((W,oe,G)=>{if(!W)return!1;const H=W.getBoundingClientRect();return oe>=H.left-R&&oe<=H.right+R&&G>=H.top-R&&G<=H.bottom+R},"nearBox"),Nn=a((W,oe)=>{const G=_.current,H=M.current;if(G?.matches(":hover")||H?.matches(":hover")||ot(G,W,oe)||ot(H,W,oe))return!0;const Ae=document.activeElement;return G===Ae||!!H&&!!Ae&&H.contains(Ae)},"stillEngaged"),st=a(W=>{Nn(W.clientX,W.clientY)||L()},"onPointerMove");return document.addEventListener("pointermove",st,{passive:!0}),()=>document.removeEventListener("pointermove",st)},[$,L]);const q=u?wr(s,u):s,{data:U,isLoading:z}=Kn({...ks(w,t,{placeholderIssue:u??void 0}),enabled:$,staleTime:Er}),jn=ds(t),ae=i.useCallback(()=>{Ss(w,t,{issue:u})},[t,u,w]),at=(0,S.jsx)(me,{ref:j,to:r,state:q,className:o,onMouseEnter:a(R=>{ae(),g?.(R)},"onMouseEnter"),onFocus:a(R=>{ae(),B(),v?.(R)},"onFocus"),onBlur:a(R=>{setTimeout(()=>L(),0),b?.(R)},"onBlur"),onTouchStart:a(R=>{ae(),y?.(R)},"onTouchStart"),onClickCapture:a(R=>{ae(),m?.(R)},"onClickCapture"),onClick:a(R=>{L(),f?.(R)},"onClick"),...h,children:n});return l?at:(0,S.jsxs)(Is,{open:$,onOpenChange:a(R=>R?B():L(),"onOpenChange"),children:[(0,S.jsx)(Es,{asChild:!0,onMouseEnter:a(()=>{ae(),J()},"onMouseEnter"),onMouseLeave:L,children:at}),(0,S.jsx)(Rs,{ref:M,"data-quicklook":!0,className:_i,side:c,align:d,alignOffset:Di(d),onMouseEnter:B,onMouseLeave:L,onOpenAutoFocus:a(R=>R.preventDefault(),"onOpenAutoFocus"),onCloseAutoFocus:a(R=>R.preventDefault(),"onCloseAutoFocus"),children:U?(0,S.jsx)(Pi,{issue:U,linkTo:jn,linkState:q,compact:!0}):(0,S.jsxs)("div",{className:"space-y-2",children:[(0,S.jsx)("div",{className:"h-4 w-24 rounded bg-bg-3/50"}),(0,S.jsx)("div",{className:"h-4 w-full rounded bg-bg-3/40"}),(0,S.jsx)("div",{className:"h-4 w-3/4 rounded bg-bg-3/30"}),z?null:(0,S.jsx)("p",{className:"text-xs text-ink-3",children:"Unable to load task preview."})]})})]})},"IssueLinkQuicklookImpl")),$n=new Set(["dashboard","companies","company","skills","teams-catalog","org","agents","chats","apps","projects","workspaces","terminal","execution-workspaces","issues","tasks","routines","goals","artifacts","tools","approvals","costs","usage","activity","audit","decisions","inbox","board-chat","artifacts","u","design-guide","search","settings","timeline"]),tt=new Set(["auth","invite","board-claim","cli-auth","mcp-connect","dot-connect","assistant-connections","docs","instance","s"]);function ue(e){return e.trim().toUpperCase()}a(ue,"normalizeCompanyPrefix");function _n(e){const t=e.match(/^([^?#]*)(\?[^#]*)?(#.*)?$/);return{pathname:t?.[1]??e,search:t?.[2]??"",hash:t?.[3]??""}}a(_n,"splitPath");function Oi(e){return e.split("/").filter(Boolean)[0]??null}a(Oi,"getRootSegment");function ji(e){if(e==="/")return!0;const t=Oi(e);return t?tt.has(t.toLowerCase()):!0}a(ji,"isGlobalPath");function Dn(e){const t=e.split("/").filter(Boolean);if(t.length===0)return null;const r=t[0].toLowerCase();return tt.has(r)||$n.has(r)?null:ue(t[0])}a(Dn,"extractCompanyPrefixFromPath");function Lt(e,t){const{pathname:r,search:n,hash:o}=_n(e);if(!r.startsWith("/")||ji(r)||!t)return e;const s=ue(t);return Dn(r)?e:`/${s}${r}${n}${o}`}a(Lt,"applyCompanyPrefix");function Ni(e,...t){const r=["cases",...t].filter(Boolean).join("/");return e?`/${ue(e)}/${r}`:`/${r}`}a(Ni,"caseHref");function bu(e){const{pathname:t,search:r,hash:n}=_n(e),o=t.split("/").filter(Boolean);if(o.length>=2){const s=o[1].toLowerCase();if(!tt.has(o[0].toLowerCase())&&$n.has(s))return`/${o.slice(1).join("/")}${r}${n}`}return`${t}${r}${n}`}a(bu,"toCompanyRelativePath");var An=/^[A-Z][A-Z0-9]*-\d+$/i,Bi=/^issue:\/\/:?([^?#\s]+)([?#].*)?$/i,Ui=/issue:\/\/:?[^\s<>()]+|https?:\/\/[^\s<>()]+|\/(?:[^\s<>()/]+\/)*issues\/[A-Z][A-Z0-9]*-\d+(?=$|[\s<>)\],.;!?:])|\b[A-Z][A-Z0-9]*-\d+\b/gi;function Mn(e){if(!e)return null;const t=e.trim();if(!t||/^https?:\/\//i.test(t))return null;const r=t.split(/[?#]/,1)[0].split("/").filter(Boolean),n=r.findIndex(s=>s==="issues");if(n===-1||n===r.length-1)return null;const o=decodeURIComponent(r[n+1]??"");return!o||o.startsWith(":")?null:An.test(o)?o.toUpperCase():o}a(Mn,"parseIssuePathIdFromPath");function Tn(e,t){if(!e)return null;const r=e.trim(),n=r.match(Bi);if(n?.[1]){const l=decodeURIComponent(n[1]);return{issuePathId:l,href:`/issues/${encodeURIComponent(l)}${n[2]??""}`}}const o=Mn(e);if(o)return{issuePathId:o,href:`/issues/${encodeURIComponent(o)}${r.match(/[?#].*$/)?.[0]??""}`};if(!An.test(r))return null;const s=r.toUpperCase();if(t&&t.size>0){const l=s.split("-")[0];if(!l||!t.has(l))return null}return{issuePathId:s,href:`/issues/${encodeURIComponent(s)}`}}a(Tn,"parseIssueReferenceFromHref");function zi(e){let t=e,r="";for(;t.length>0;){const n=t.at(-1);if(!n||!/[),.;!?:\]]/.test(n))break;if(n===")"){const o=(t.match(/\(/g)??[]).length;if((t.match(/\)/g)??[]).length<=o)break}if(n==="]"){const o=(t.match(/\[/g)??[]).length;if((t.match(/\]/g)??[]).length<=o)break}r=`${n}${r}`,t=t.slice(0,-1)}return{core:t,trailing:r}}a(zi,"splitTrailingPunctuation");function Pn(e,t,r="text"){return{type:"link",url:t,children:[{type:r,value:e}]}}a(Pn,"createIssueLinkNode");function Fi(e,t){const r=[];let n=0,o=!1;for(const s of e.matchAll(Ui)){const l=s[0];if(!l)continue;const u=s.index??0,c=u+l.length,{core:d,trailing:f}=zi(l),m=Tn(d,t);m&&(o=!0,u>n&&r.push({type:"text",value:e.slice(n,u)}),r.push(Pn(d,m.href)),f&&r.push({type:"text",value:f}),n=c)}return o?(n<e.length&&r.push({type:"text",value:e.slice(n)}),r):null}a(Fi,"linkifyIssueReferencesInText");function Ln(e,t){if(!Array.isArray(e.children)||e.children.length===0||e.type==="link"||e.type==="linkReference"||e.type==="code"||e.type==="definition"||e.type==="html")return;const r=[];for(const n of e.children){if(n.type==="inlineCode"&&typeof n.value=="string"){const o=Tn(n.value,t);if(o){r.push(Pn(n.value,o.href,"inlineCode"));continue}}if(n.type==="text"&&typeof n.value=="string"){const o=Fi(n.value,t);if(o){r.push(...o);continue}}Ln(n,t),r.push(n)}e.children=r}a(Ln,"rewriteMarkdownTree");function vu(e){const t=e?.knownPrefixes&&e.knownPrefixes.length>0?new Set(e.knownPrefixes.map(r=>r.toUpperCase())):void 0;return r=>{Ln(r,t)}}a(vu,"remarkLinkIssueReferences");function De(e,t){if(typeof e=="string")return Lt(e,t);if(e.pathname&&e.pathname.startsWith("/")){const r=Lt(e.pathname,t);if(r!==e.pathname)return{...e,pathname:r}}return e}a(De,"resolveTo");function he(){const{selectedCompany:e}=Jn(),t=Ka(),r=P();if(t.companyPrefix)return ue(t.companyPrefix);const n=Dn(r.pathname);return n||(e?ue(e.issuePrefix):null)}a(he,"useActiveCompanyPrefix");function ku(){const e=he();return i.useCallback((...t)=>Ni(e,...t),[e])}a(ku,"useCaseHref");var xu=i.forwardRef(a(function({to:t,disableIssueQuicklook:r=!1,issuePrefetch:n=null,issueQuicklookSide:o,issueQuicklookAlign:s,...l},u){const c=De(t,he()),d=Mn(typeof c=="string"?c:c.pathname);return d?(0,S.jsx)(Li,{ref:u,to:c,issuePathId:d,disableIssueQuicklook:r,issuePrefetch:n,issueQuicklookSide:o,issueQuicklookAlign:s,...l}):(0,S.jsx)(me,{ref:u,to:c,...l})},"CompanyLink")),wu=i.forwardRef(a(function({to:t,...r},n){const o=he();return(0,S.jsx)(dr,{ref:n,to:De(t,o),...r})},"CompanyNavLink"));function Su({to:e,...t}){const r=he();return(0,S.jsx)(lo,{to:De(e,r),...t})}a(Su,"Navigate");function Iu(){const e=Ee(),t=he();return i.useCallback(((r,n)=>{if(typeof r=="number"){e(r);return}e(De(r,t),n)}),[e,t])}a(Iu,"useNavigate");var Ot=a(e=>typeof e=="boolean"?`${e}`:e===0?"0":e,"falsyToString"),jt=Zn,qi=a((e,t)=>r=>{var n;if(t?.variants==null)return jt(e,r?.class,r?.className);const{variants:o,defaultVariants:s}=t,l=Object.keys(o).map(d=>{const f=r?.[d],m=s?.[d];if(f===null)return null;const g=Ot(f)||Ot(m);return o[d][g]}),u=r&&Object.entries(r).reduce((d,f)=>{let[m,g]=f;return g===void 0||(d[m]=g),d},{}),c=t==null||(n=t.compoundVariants)===null||n===void 0?void 0:n.reduce((d,f)=>{let{class:m,className:g,...v}=f;return Object.entries(v).every(b=>{let[y,h]=b;return Array.isArray(h)?h.includes({...s,...u}[y]):{...s,...u}[y]===h})?[...d,m,g]:d},[]);return jt(e,l,c,r?.class,r?.className)},"cva"),Hi=qi("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md border text-(length:--t-13) font-medium transition-(--tp-color-background-color-border-color-box-shadow-opacity) outline-hidden focus-visible:outline-solid focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-focus disabled:pointer-events-none disabled:border-line-strong disabled:bg-bg-3 disabled:text-ink-3 aria-busy:cursor-progress data-[active=true]:border-accent data-[active=true]:bg-accent-soft data-[active=true]:text-accent [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 shrink-0 [&_svg]:shrink-0 aria-invalid:border-bad",{variants:{variant:{primary:"border-transparent bg-accent text-accent-ink hover:bg-accent-hover active:bg-accent-press",secondary:"border-line-strong bg-bg-2 text-ink hover:bg-bg-3 active:bg-line-soft",ghost:"border-transparent bg-transparent text-ink-2 hover:bg-bg-3 hover:text-ink active:bg-line-soft disabled:border-transparent disabled:bg-transparent data-[active=true]:border-transparent data-[state=open]:bg-bg-3 data-[state=open]:text-ink",danger:"border-line-strong bg-bg-2 text-bad hover:bg-bg-3 active:bg-line-soft",delete:"border-transparent bg-bad text-accent-ink hover:bg-bad-hover active:bg-bad-hover",link:"border-transparent bg-transparent text-accent underline underline-offset-4 hover:text-accent-hover active:text-accent-press disabled:border-transparent disabled:bg-transparent"},size:{default:"h-10 px-4 py-2 has-[>svg]:px-3",xs:"h-6 gap-1 rounded-md px-2 text-xs has-[>svg]:px-1.5 [&_svg:not([class*='size-'])]:size-3",sm:"h-9 rounded-md gap-1.5 px-3 has-[>svg]:px-2.5",lg:"h-10 rounded-md px-6 has-[>svg]:px-4",icon:"size-10","icon-xs":"size-6 rounded-md [&_svg:not([class*='size-'])]:size-3","icon-sm":"size-9","icon-lg":"size-10"}},defaultVariants:{variant:"primary",size:"default"}}),Wi=i.forwardRef(a(function({className:t,variant:r="primary",size:n="default",asChild:o=!1,loading:s=!1,active:l,children:u,onClick:c,...d},f){const m=o?zn:"button",g=s?v=>v.preventDefault():c;return(0,S.jsx)(m,{ref:f,"data-slot":"button","data-variant":r,"data-size":n,"data-active":l||void 0,"aria-busy":s||void 0,"aria-disabled":s||void 0,className:V(Hi({variant:r,size:n,className:t})),onClick:g,...d,children:s&&!o?(0,S.jsxs)(S.Fragment,{children:[(0,S.jsx)(Xs,{"aria-hidden":"true",className:"animate-spin"}),u]}):u})},"Button"));Wi.displayName="Button";var Vi={info:4e3,success:3500,warn:8e3,error:1e4},Ki=1500,Qi=15e3,Ji=5,Gi=3500,Yi=2e4,rt=(0,i.createContext)(null),nt=(0,i.createContext)(null);function Xi(e,t){const r=Vi[t];return typeof e!="number"||!Number.isFinite(e)?r:Math.max(Ki,Math.min(Qi,Math.floor(e)))}a(Xi,"normalizeTtl");function Zi(){return`toast_${Date.now()}_${Math.random().toString(36).slice(2,8)}`}a(Zi,"generateToastId");function Eu({children:e}){const[t,r]=(0,i.useState)([]),n=(0,i.useRef)(new Map),o=(0,i.useRef)(new Map),s=(0,i.useCallback)(f=>{const m=n.current.get(f);m!==void 0&&(window.clearTimeout(m),n.current.delete(f))},[]),l=(0,i.useCallback)(f=>{s(f),r(m=>m.filter(g=>g.id!==f))},[s]),u=(0,i.useCallback)(()=>{for(const f of n.current.values())window.clearTimeout(f);n.current.clear(),r([])},[]),c=(0,i.useCallback)(f=>{const m=Date.now(),g=f.tone??"info",v=Xi(f.ttlMs,g),b=f.dedupeKey??f.id??`${g}|${f.title}|${f.body??""}|${f.action?.href??""}`;for(const[k,w]of o.current.entries())m-w>Yi&&o.current.delete(k);const y=o.current.get(b);if(y&&m-y<Gi)return null;o.current.set(b,m);const h=f.id??Zi();if(s(h),r(k=>[{id:h,title:f.title,body:f.body,tone:g,ttlMs:v,persistent:f.persistent,action:f.action,actor:f.actor,createdAt:m},...k.filter(w=>w.id!==h)].slice(0,Ji)),!f.persistent){const k=window.setTimeout(()=>{l(h)},v);n.current.set(h,k)}return h},[s,l]);(0,i.useEffect)(()=>()=>{for(const f of n.current.values())window.clearTimeout(f);n.current.clear()},[]);const d=(0,i.useMemo)(()=>({pushToast:c,dismissToast:l,clearToasts:u}),[c,l,u]);return(0,S.jsx)(nt.Provider,{value:d,children:(0,S.jsx)(rt.Provider,{value:t,children:e})})}a(Eu,"ToastProvider");function el(){const e=(0,i.useContext)(rt);if(!e)throw new Error("useToastState must be used within a ToastProvider");return e}a(el,"useToastState");function tl(){const e=(0,i.useContext)(nt);if(!e)throw new Error("useToastActions must be used within a ToastProvider");return e}a(tl,"useToastActions");function Ru(){return(0,i.useContext)(nt)}a(Ru,"useOptionalToastActions");function Cu(){return(0,i.useContext)(rt)}a(Cu,"useOptionalToastState");function $u(){const e=el(),t=tl();return(0,i.useMemo)(()=>({toasts:e,...t}),[e,t])}a($u,"useToast");var On=(0,i.createContext)(null);function rl(e,t){if(e===t)return!0;if(e.length!==t.length)return!1;for(let r=0;r<e.length;r+=1)if(e[r]?.label!==t[r]?.label||e[r]?.onClick!==t[r]?.onClick||e[r]?.href!==t[r]?.href||e[r]?.identifier!==t[r]?.identifier||e[r]?.leadingKey!==t[r]?.leadingKey||e[r]?.trailingKey!==t[r]?.trailingKey)return!1;return!0}a(rl,"breadcrumbsEqual");function nl(e,t){const r=e.length===0?[]:[...e].reverse().map(o=>o.label),n=t?.trim()?[t.trim()]:[];return[...r,...n,"Wardmote"].join(" • ")}a(nl,"buildDocumentTitle");function _u({children:e,companyName:t}){const[r,n]=(0,i.useState)([]),[o,s]=(0,i.useState)(null),[l,u]=(0,i.useState)(null),[c,d]=(0,i.useState)(null),f=(0,i.useCallback)(b=>{n(y=>rl(y,b)?y:b)},[]),m=(0,i.useCallback)(b=>{d(b)},[]),g=(0,i.useCallback)(b=>{s(b)},[]),v=(0,i.useCallback)(b=>{u(b)},[]);return(0,i.useEffect)(()=>{document.title=nl(r,t)},[r,t]),(0,S.jsx)(On.Provider,{value:{breadcrumbs:r,setBreadcrumbs:f,breadcrumbToolbar:o,setBreadcrumbToolbar:g,breadcrumbPanelControl:l,setBreadcrumbPanelControl:v,mobileToolbar:c,setMobileToolbar:m},children:e})}a(_u,"BreadcrumbProvider");function Du(){const e=(0,i.useContext)(On);if(!e)throw new Error("useBreadcrumbs must be used within BreadcrumbProvider");return e}a(Du,"useBreadcrumbs");async function Au(){if(typeof navigator>"u"||!navigator.clipboard?.read)return null;try{return await navigator.clipboard.read()}catch{return null}}a(Au,"readClipboardItems");async function Mu(){if(typeof navigator>"u"||!navigator.clipboard?.readText)return"";try{return await navigator.clipboard.readText()}catch{return""}}a(Mu,"readTextFromClipboard");async function Tu(e){if((typeof window>"u"||window.isSecureContext!==!1)&&typeof navigator<"u"&&navigator.clipboard?.writeText)try{await navigator.clipboard.writeText(e);return}catch{}if(typeof document>"u")throw new Error("Clipboard unavailable");const t=document.createElement("textarea");t.value=e,t.setAttribute("aria-hidden","true"),t.tabIndex=-1,t.style.position="fixed",t.style.top="0",t.style.left="-9999px",(document.activeElement?.closest('[role="dialog"]')??document.querySelector('dialog[open], [role="dialog"][data-state="open"]')??document.body).appendChild(t);const r=document.activeElement;try{if(t.focus({preventScroll:!0}),t.select(),t.setSelectionRange(0,e.length),!document.execCommand("copy"))throw new Error("execCommand copy failed")}finally{t.remove(),r!==document.activeElement&&typeof r?.focus=="function"&&r.focus({preventScroll:!0})}}a(Tu,"copyTextToClipboard");export{ru as $,vl as $n,ql as $t,_i as A,fs as An,qs as At,ye as B,pr as Bn,At as Bt,Lt as C,St as Cn,Gs as Ct,bu as D,_l as Dn,Vs as Dt,ue as E,ds as En,Ks as Et,uu as F,rs as Fn,Ns as Ft,hu as G,ml as Gn,Kl as Gt,pu as H,es as Hn,Ps as Ht,cu as I,wl as In,Ql as It,Xl as J,kl as Jn,Ds as Jt,Gl as K,uo as Kn,Vl as Kt,ou as L,Ze as Ln,js as Lt,Ii as M,wr as Mn,zs as Mt,Mt as N,Il as Nn,Us as Nt,Li as O,Dl as On,Ws as Ot,ki as P,ts as Pn,Bs as Pt,fu as Q,Ka as Qn,Is as Qt,su as R,El as Rn,Os as Rt,vu as S,Y as Sn,Ys as St,ji as T,Rl as Tn,Qs as Tt,gu as U,bl as Un,Ur as Ut,yu as V,xl as Vn,Dt as Vt,mu as W,me as Wn,Ts as Wt,nu as X,Ee as Xn,$s as Xt,Zl as Y,P as Yn,_s as Yt,du as Z,dl as Zn,Cs as Zt,Su as _,Pl as _n,ri as _t,Du as a,ks as an,mi as at,Iu as b,Ll as bn,Zs as bt,Cu as c,Bl as cn,ci as ct,el as d,Al as dn,ii as dt,Rs as en,eu as et,Wi as f,Ol as fn,si as ft,wu as g,gs as gn,Jl as gt,xu as h,jl as hn,ni as ht,_u as i,Cr as in,hi as it,Di as j,$l as jn,Fs as jt,Pi as k,ss as kn,Hs as kt,$u as l,ps as ln,ui as lt,qi as m,Ml as mn,ai as mt,Au as n,Hl as nn,iu as nt,Eu as o,Ss as on,fi as ot,Hi as p,hs as pn,oi as pt,Yl as q,hl as qn,Ms as qt,Mu as r,Es as rn,lu as rt,Ru as s,Tl as sn,di as st,Tu as t,Wl as tn,tu as tt,tl as u,Ul as un,li as ut,he as v,Fl as vn,ti as vt,Dn as w,Cl as wn,Js as wt,Tn as x,zl as xn,Xs as xt,ku as y,Nl as yn,ei as yt,au as z,Sl as zn,Ls as zt};
|
|
15
|
+
`}});if(Kt(e))return i.createElement(yt,{title:"Unhandled Thrown Response!"},i.createElement("h1",{style:{fontSize:"24px"}},e.status," ",e.statusText),n);let o;if(e instanceof Error)o=e;else{let s=e==null?"Unknown Error":typeof e=="object"&&"toString"in e?e.toString():JSON.stringify(e);o=new Error(s)}return i.createElement(yt,{title:"Application Error!",isOutsideRemixApp:t},i.createElement("h1",{style:{fontSize:"24px"}},"Application Error"),i.createElement("pre",{style:{padding:"2rem",background:"hsla(10, 50%, 50%, 0.1)",color:"red",overflow:"auto"}},o.stack),n)}a(Uo,"RemixRootDefaultErrorBoundary");function yt({title:e,renderScripts:t,isOutsideRemixApp:r,children:n}){let{routeModules:o}=Q();return o.root?.Layout&&!r?n:i.createElement("html",{lang:"en"},i.createElement("head",null,i.createElement("meta",{charSet:"utf-8"}),i.createElement("meta",{name:"viewport",content:"width=device-width,initial-scale=1,viewport-fit=cover"}),i.createElement("title",null,e)),i.createElement("body",null,i.createElement("main",{style:{fontFamily:"system-ui, sans-serif",padding:"2rem"}},n,t?i.createElement(No,null):null)))}a(yt,"BoundaryShell");var zo=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{zo&&(window.__reactRouterVersion="7.18.4")}catch{}function bl({basename:e,children:t,useTransitions:r,window:n}){let o=i.useRef();o.current==null&&(o.current=oa({window:n,v5Compat:!0}));let s=o.current,[l,u]=i.useState({action:s.action,location:s.location}),c=i.useCallback(d=>{r===!1?u(d):i.startTransition(()=>u(d))},[r]);return i.useLayoutEffect(()=>s.listen(c),[s,c]),i.createElement(ir,{basename:e,children:t,location:l.location,navigationType:l.action,navigator:s,useTransitions:r})}a(bl,"BrowserRouter");function Fo({basename:e,children:t,history:r,useTransitions:n}){let[o,s]=i.useState({action:r.action,location:r.location}),l=i.useCallback(u=>{n===!1?s(u):i.startTransition(()=>s(u))},[n]);return i.useLayoutEffect(()=>r.listen(l),[r,l]),i.createElement(ir,{basename:e,children:t,location:o.location,navigationType:o.action,navigator:r,useTransitions:n})}a(Fo,"HistoryRouter");Fo.displayName="unstable_HistoryRouter";var me=i.forwardRef(a(function({onClick:t,discover:r="render",prefetch:n="none",relative:o,reloadDocument:s,replace:l,mask:u,state:c,target:d,to:f,preventScrollReset:m,viewTransition:g,defaultShouldRevalidate:v,...b},y){let{basename:h,navigator:k,useTransitions:w}=i.useContext(A),I=typeof f=="string"&&He.test(f),$=Jt(f,h);f=$.to;let E=qa(f,{relative:o}),_=P(),M=null;if(u){let z=Ie(u,[],_.mask?_.mask.pathname:"/",!0);h!=="/"&&(z.pathname=z.pathname==="/"?h:N([h,z.pathname])),M=k.createHref(z)}let[j,D,B]=Ao(n,b),J=Vo(f,{replace:l,mask:u,state:c,target:d,preventScrollReset:m,relative:o,viewTransition:g,defaultShouldRevalidate:v,useTransitions:w});function L(z){t&&t(z),z.defaultPrevented||J(z)}a(L,"handleClick");let q=!($.isExternal||s),U=i.createElement("a",{...b,...B,href:(q?M:void 0)||$.absoluteURL||E,onClick:q?L:t,ref:Bo(y,D),target:d,"data-discover":!I&&r==="render"?"true":void 0});return j&&!I?i.createElement(i.Fragment,null,U,i.createElement(To,{page:E})):U},"LinkWithRef"));me.displayName="Link";var dr=i.forwardRef(a(function({"aria-current":t="page",caseSensitive:r=!1,className:n="",end:o=!1,style:s,to:l,viewTransition:u,children:c,...d},f){let m=fe(l,{relative:d.relative}),g=P(),v=i.useContext(de),{navigator:b,basename:y}=i.useContext(A),h=v!=null&&Zo(m)&&u===!0,k=b.encodeLocation?b.encodeLocation(m).pathname:m.pathname,w=g.pathname,I=v&&v.navigation&&v.navigation.location?v.navigation.location.pathname:null;r||(w=w.toLowerCase(),I=I?I.toLowerCase():null,k=k.toLowerCase()),I&&y&&(I=F(I,y)||I);const $=k!=="/"&&k.endsWith("/")?k.length-1:k.length;let E=w===k||!o&&w.startsWith(k)&&w.charAt($)==="/",_=I!=null&&(I===k||!o&&I.startsWith(k)&&I.charAt(k.length)==="/"),M={isActive:E,isPending:_,isTransitioning:h},j=E?t:void 0,D;typeof n=="function"?D=n(M):D=[n,E?"active":null,_?"pending":null,h?"transitioning":null].filter(Boolean).join(" ");let B=typeof s=="function"?s(M):s;return i.createElement(me,{...d,"aria-current":j,className:D,ref:f,style:B,to:l,viewTransition:u},typeof c=="function"?c(M):c)},"NavLinkWithRef"));dr.displayName="NavLink";var qo=i.forwardRef(({discover:e="render",fetcherKey:t,navigate:r,reloadDocument:n,replace:o,state:s,method:l=be,action:u,onSubmit:c,relative:d,preventScrollReset:f,viewTransition:m,defaultShouldRevalidate:g,...v},b)=>{let{useTransitions:y}=i.useContext(A),h=Jo(),k=Go(u,{relative:d}),w=l.toLowerCase()==="get"?"get":"post",I=typeof u=="string"&&He.test(u),$=a(E=>{if(c&&c(E),E.defaultPrevented)return;E.preventDefault();let _=E.nativeEvent.submitter,M=_?.getAttribute("formmethod")||l,j=a(()=>h(_||E.currentTarget,{fetcherKey:t,method:M,navigate:r,replace:o,state:s,relative:d,preventScrollReset:f,viewTransition:m,defaultShouldRevalidate:g}),"doSubmit");y&&r!==!1?i.startTransition(()=>j()):j()},"submitHandler");return i.createElement("form",{ref:b,method:w,action:k,onSubmit:n?c:$,...v,"data-discover":!I&&e==="render"?"true":void 0})});qo.displayName="Form";function Ho({getKey:e,storageKey:t,...r}){let n=i.useContext(_e),{basename:o}=i.useContext(A),s=P(),l=or();Yo({getKey:e,storageKey:t});let u=i.useMemo(()=>{if(!n||!e)return null;let d=ze(s,l,o,e);return d!==s.key?d:null},[]);if(!n||n.isSpaMode)return null;let c=((d,f)=>{if(!window.history.state||!window.history.state.key){let m=Math.random().toString(32).slice(2);window.history.replaceState({key:m},"")}try{let m=JSON.parse(sessionStorage.getItem(d)||"{}")[f||window.history.state.key];typeof m=="number"&&window.scrollTo(0,m)}catch{sessionStorage.removeItem(d)}}).toString();return r.nonce==null&&n?.nonce&&(r.nonce=n.nonce),i.createElement("script",{...r,suppressHydrationWarning:!0,dangerouslySetInnerHTML:{__html:`(${c})(${pt(JSON.stringify(t||Ue))}, ${pt(JSON.stringify(u))})`}})}a(Ho,"ScrollRestoration");Ho.displayName="ScrollRestoration";function fr(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}a(fr,"getDataRouterConsoleError2");function Xe(e){let t=i.useContext(te);return C(t,fr(e)),t}a(Xe,"useDataRouterContext3");function Wo(e){let t=i.useContext(de);return C(t,fr(e)),t}a(Wo,"useDataRouterState2");function Vo(e,{target:t,replace:r,mask:n,state:o,preventScrollReset:s,relative:l,viewTransition:u,defaultShouldRevalidate:c,useTransitions:d}={}){let f=Ee(),m=P(),g=fe(e,{relative:l});return i.useCallback(v=>{if(po(v,t)){v.preventDefault();let b=r!==void 0?r:K(m)===K(g),y=a(()=>f(e,{replace:b,mask:n,state:o,preventScrollReset:s,relative:l,viewTransition:u,defaultShouldRevalidate:c}),"doNavigate");d?i.startTransition(()=>y()):y()}},[m,f,g,r,n,o,t,e,s,l,u,c,d])}a(Vo,"useLinkClickHandler");function vl(e){T(typeof URLSearchParams<"u","You cannot use the `useSearchParams` hook in a browser that does not support the URLSearchParams API. If you need to support Internet Explorer 11, we recommend you load a polyfill such as https://github.com/ungap/url-search-params.");let t=i.useRef(Be(e)),r=i.useRef(!1),n=P(),o=i.useMemo(()=>go(n.search,r.current?null:t.current),[n.search]),s=Ee();return[o,i.useCallback((l,u)=>{const c=Be(typeof l=="function"?l(new URLSearchParams(o)):l);r.current=!0,s("?"+c,u)},[s,o])]}a(vl,"useSearchParams");var Ko=0,Qo=a(()=>`__${String(++Ko)}__`,"getUniqueFetcherId");function Jo(){let{router:e}=Xe("useSubmit"),{basename:t}=i.useContext(A),r=ro(),n=e.fetch,o=e.navigate;return i.useCallback(async(s,l={})=>{let{action:u,method:c,encType:d,formData:f,body:m}=vo(s,t);if(l.navigate===!1){let g=l.fetcherKey||Qo();await n(g,r,l.action||u,{defaultShouldRevalidate:l.defaultShouldRevalidate,preventScrollReset:l.preventScrollReset,formData:f,body:m,formMethod:l.method||c,formEncType:l.encType||d,flushSync:l.flushSync})}else await o(l.action||u,{defaultShouldRevalidate:l.defaultShouldRevalidate,preventScrollReset:l.preventScrollReset,formData:f,body:m,formMethod:l.method||c,formEncType:l.encType||d,replace:l.replace,state:l.state,fromRouteId:r,flushSync:l.flushSync,viewTransition:l.viewTransition})},[n,o,t,r])}a(Jo,"useSubmit");function Go(e,{relative:t}={}){let{basename:r}=i.useContext(A),n=i.useContext(O);C(n,"useFormAction must be used inside a RouteContext");let[o]=n.matches.slice(-1),s={...fe(e||".",{relative:t})},l=P();if(e==null){s.search=l.search;let u=new URLSearchParams(s.search),c=u.getAll("index");if(c.some(d=>d==="")){u.delete("index"),c.filter(f=>f).forEach(f=>u.append("index",f));let d=u.toString();s.search=d?`?${d}`:""}}return(!e||e===".")&&o.route.index&&(s.search=s.search?s.search.replace(/^\?/,"?index&"):"?index"),r!=="/"&&(s.pathname=s.pathname==="/"?r:N([r,s.pathname])),K(s)}a(Go,"useFormAction");var Ue="react-router-scroll-positions",ge={};function ze(e,t,r,n){let o=null;return n&&(r!=="/"?o=n({...e,pathname:F(e.pathname,r)||e.pathname},t):o=n(e,t)),o==null&&(o=e.key),o}a(ze,"getScrollRestorationKey");function Yo({getKey:e,storageKey:t}={}){let{router:r}=Xe("useScrollRestoration"),{restoreScrollPosition:n,preventScrollReset:o}=Wo("useScrollRestoration"),{basename:s}=i.useContext(A),l=P(),u=or(),c=no();i.useEffect(()=>(window.history.scrollRestoration="manual",()=>{window.history.scrollRestoration="auto"}),[]),Xo(i.useCallback(()=>{if(c.state==="idle"){let d=ze(l,u,s,e);ge[d]=window.scrollY}try{sessionStorage.setItem(t||Ue,JSON.stringify(ge))}catch(d){T(!1,`Failed to save scroll positions in sessionStorage, <ScrollRestoration /> will not work properly (${d}).`)}window.history.scrollRestoration="auto"},[c.state,e,s,l,u,t])),typeof document<"u"&&(i.useLayoutEffect(()=>{try{let d=sessionStorage.getItem(t||Ue);d&&(ge=JSON.parse(d))}catch{}},[t]),i.useLayoutEffect(()=>{let d=r?.enableScrollRestoration(ge,()=>window.scrollY,e?(f,m)=>ze(f,m,s,e):void 0);return()=>d&&d()},[r,s,e]),i.useLayoutEffect(()=>{if(n!==!1){if(typeof n=="number"){window.scrollTo(0,n);return}try{if(l.hash){let d=document.getElementById(decodeURIComponent(l.hash.slice(1)));if(d){d.scrollIntoView();return}}}catch{T(!1,`"${l.hash.slice(1)}" is not a decodable element ID. The view will not scroll to it.`)}o!==!0&&window.scrollTo(0,0)}},[l,n,o]))}a(Yo,"useScrollRestoration");function kl(e,t){let{capture:r}=t||{};i.useEffect(()=>{let n=r!=null?{capture:r}:void 0;return window.addEventListener("beforeunload",e,n),()=>{window.removeEventListener("beforeunload",e,n)}},[e,r])}a(kl,"useBeforeUnload");function Xo(e,t){let{capture:r}=t||{};i.useEffect(()=>{let n=r!=null?{capture:r}:void 0;return window.addEventListener("pagehide",e,n),()=>{window.removeEventListener("pagehide",e,n)}},[e,r])}a(Xo,"usePageHide");function Zo(e,{relative:t}={}){let r=i.useContext(Zt);C(r!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:n}=Xe("useViewTransitionState"),o=fe(e,{relative:t});if(!r.isTransitioning)return!1;let s=F(r.currentLocation.pathname,n)||r.currentLocation.pathname,l=F(r.nextLocation.pathname,n)||r.nextLocation.pathname;return ke(o.pathname,l)!=null||ke(o.pathname,s)!=null}a(Zo,"useViewTransitionState");var bt=60,Fe=3600,we=24*Fe,vt=7*we,kt=30*we;function es(e){const t=Date.now(),r=new Date(e).getTime(),n=Math.round((t-r)/1e3);return n<bt?"just now":n<Fe?`${Math.floor(n/bt)}m ago`:n<we?`${Math.floor(n/Fe)}h ago`:n<vt?`${Math.floor(n/we)}d ago`:n<kt?`${Math.floor(n/vt)}w ago`:`${Math.floor(n/kt)}mo ago`}a(es,"timeAgo");var ts=[{label:"My work",views:[{key:"mine",label:"Mine",surface:"inbox",inboxTab:"mine",hint:"Assigned to you or waiting on you"},{key:"unread",label:"Unread",surface:"inbox",inboxTab:"unread",hint:"Tasks you touched with new activity"},{key:"blocked",label:"Blocked",surface:"inbox",inboxTab:"blocked",hint:"Blocked tasks, grouped by blocker"},{key:"recent",label:"Recent",surface:"inbox",inboxTab:"recent",hint:"Everything you touched lately"},{key:"everything",label:"Everything",surface:"inbox",inboxTab:"all",hint:"Tasks, approvals, failed runs and join requests"}]},{label:"Organization",views:[{key:"all",label:"All tasks",surface:"issues",statuses:[],hint:"Every task in the organization"},{key:"active",label:"Active",surface:"issues",statuses:["todo","in_progress","in_review","blocked"],hint:"Open tasks, running or not"},{key:"backlog",label:"Backlog",surface:"issues",statuses:["backlog"],hint:"Not started yet"},{key:"done",label:"Done",surface:"issues",statuses:["done","cancelled"],hint:"Completed and cancelled"}]}],mr=new Map(ts.flatMap(e=>e.views.map(t=>[t.key,t]))),hr="mine",rs="view",ns="paperclip:tasks:last-view";function as(e){return typeof e=="string"&&mr.has(e)}a(as,"isTaskViewKey");function pr(e){return mr.get(e)}a(pr,"taskView");function Ze(e){return as(e)?e:null}a(Ze,"normalizeTaskViewKey");var xt={mine:"mine",unread:"unread",blocked:"blocked",recent:"recent",all:"everything"};function xl(e){return e&&e in xt?xt[e]:hr}a(xl,"taskViewForInboxTab");function wl(){try{return Ze(window.localStorage.getItem("paperclip:tasks:last-view"))??"mine"}catch{return hr}}a(wl,"loadLastTaskView");function Sl(e){try{window.localStorage.setItem(ns,e)}catch{}}a(Sl,"saveLastTaskView");var Il=["assignee","workspace","participantAgentId","q"];function El(e,t,r){const n=Ze(e);return t&&(!n||pr(n).surface==="inbox")?"all":n??r}a(El,"resolveInitialTaskView");var gr="from",yr="fromHref",br="paperclip:issue-detail-breadcrumb:";function vr(e){if(typeof e!="object"||e===null)return!1;const t=e;return typeof t.label=="string"&&typeof t.href=="string"}a(vr,"isIssueDetailBreadcrumb");function kr(e){return e==="issues"||e==="inbox"}a(kr,"isIssueDetailSource");function xr(e){if(typeof e!="object"||e===null)return!1;const t=e,r=t.originKind===void 0||typeof t.originKind=="string",n=t.originId===void 0||t.originId===null||typeof t.originId=="string",o=t.blockerAttention===void 0||typeof t.blockerAttention=="object"&&t.blockerAttention!==null;return typeof t.id=="string"&&(t.identifier===null||typeof t.identifier=="string")&&typeof t.title=="string"&&typeof t.status=="string"&&o&&typeof t.priority=="string"&&(t.projectId===null||typeof t.projectId=="string")&&(t.projectName===null||typeof t.projectName=="string")&&r&&n}a(xr,"isIssueDetailHeaderSeed");function os(e){return{id:e.id,identifier:e.identifier??null,title:e.title,status:e.status,blockerAttention:e.blockerAttention,priority:e.priority,projectId:e.projectId??null,projectName:e.project?.name??null,originKind:e.originKind,originId:e.originId??null}}a(os,"createIssueDetailHeaderSeed");function wr(e,t){const r=os(t);return typeof e!="object"||e===null?{issueDetailHeaderSeed:r}:{...e,issueDetailHeaderSeed:r}}a(wr,"withIssueDetailHeaderSeed");function ss(e){if(typeof e!="object"||e===null)return null;const t=e.issueDetailHeaderSeed;return xr(t)?t:null}a(ss,"readIssueDetailHeaderSeed");function is(e){if(!e)return null;const t=new URLSearchParams(e).get(gr);return kr(t)?t:null}a(is,"readIssueDetailSourceFromSearch");function ls(e){if(!e)return null;const t=new URLSearchParams(e).get(yr);return t&&t.startsWith("/")?t:null}a(ls,"readIssueDetailBreadcrumbHrefFromSearch");function us(e){const t=e.slice(e.indexOf("?")+1);if(!e.includes("?"))return!1;const r=new URLSearchParams(t).get(rs),n=Ze(r);return n!==null&&pr(n).surface==="inbox"}a(us,"isInboxBackedTaskViewHref");function Sr(e,t){return kr(e?.issueDetailSource)?e.issueDetailSource:t?t.href.includes("/inbox")||us(t.href)||t.label==="Inbox"?"inbox":t.label==="Tasks"||t.href.includes("/issues")?"issues":null:null}a(Sr,"inferIssueDetailSource");function wt(e){return e==="inbox"?{label:"Inbox",href:"/inbox"}:{label:"Tasks",href:"/issues"}}a(wt,"breadcrumbForSource");function Rl(e,t,r){return{issueDetailBreadcrumb:{label:e,href:t},issueDetailSource:r}}a(Rl,"createIssueDetailLocationState");function Cl(e){return typeof e!="object"||e===null?{issueDetailInboxQuickArchiveArmed:!0}:{...e,issueDetailInboxQuickArchiveArmed:!0}}a(Cl,"armIssueDetailInboxQuickArchive");function cs(e){if(typeof window>"u"||!window.sessionStorage)return null;const t=window.sessionStorage.getItem(`${br}${e}`);if(!t)return null;try{const r=JSON.parse(t),n=vr(r.issueDetailBreadcrumb)?r.issueDetailBreadcrumb:null,o=Sr(r,n);if(!n||!o)return null;const s=xr(r.issueDetailHeaderSeed)?r.issueDetailHeaderSeed:void 0;return{issueDetailBreadcrumb:n,issueDetailSource:o,issueDetailInboxQuickArchiveArmed:r.issueDetailInboxQuickArchiveArmed===!0,issueDetailHeaderSeed:s}}catch{return null}}a(cs,"readStoredIssueDetailLocationState");function Ir(e,t){if(typeof e=="object"&&e!==null){const o=e.issueDetailBreadcrumb;if(vr(o)){const s=Sr(e,o);if(!s)return null;const l=ss(e)??void 0;return{issueDetailBreadcrumb:o,issueDetailSource:s,issueDetailInboxQuickArchiveArmed:e.issueDetailInboxQuickArchiveArmed===!0,issueDetailHeaderSeed:l}}}const r=is(t),n=ls(t);return r?{issueDetailBreadcrumb:n?{...wt(r),href:n}:wt(r),issueDetailSource:r,issueDetailInboxQuickArchiveArmed:!1}:null}a(Ir,"normalizeIssueDetailLocationState");function $l(e,t,r){if(typeof window>"u"||!window.sessionStorage)return;const n=Ir(t,r);n&&window.sessionStorage.setItem(`${br}${e}`,JSON.stringify(n))}a($l,"rememberIssueDetailLocationState");function ds(e){return`/issues/${e}`}a(ds,"createIssueDetailPath");function _l(e){if(!e)return!1;const t=new URLSearchParams(e);return t.has(gr)||t.has(yr)}a(_l,"hasLegacyIssueDetailQuery");function fs(e,t,r){const n=Ir(t,r);return n||(e?cs(e):null)}a(fs,"readIssueDetailLocationState");function Dl(e,t,r){return fs(e,t,r)?.issueDetailBreadcrumb??null}a(Dl,"readIssueDetailBreadcrumb");var St=class extends Error{static{a(this,"CommentSubmissionUnknownError")}constructor(){super("We couldn’t confirm whether this comment was saved. Review the conversation before starting another draft."),this.name="CommentSubmissionUnknownError"}};function It(e){if(!e||typeof e!="object"||Array.isArray(e))return!1;const t=e,r=/^[0-9a-f]{8}-(?:[0-9a-f]{4}-){3}[0-9a-f]{12}$/i;return typeof t.id=="string"&&r.test(t.id)&&typeof t.issueId=="string"&&r.test(t.issueId)&&typeof t.body=="string"}a(It,"hasCommentReceipt");async function Et(e,t){try{const r=await e;if(!t(r))throw new St;return r}catch(r){throw r instanceof zn&&r.status<500?r:new St}}a(Et,"confirmedCommentResponse");function Rt(e){const t=new URLSearchParams;return e?.attention&&t.set("attention",e.attention),e?.status&&t.set("status",e.status),e?.priority&&t.set("priority",e.priority),e?.projectId&&t.set("projectId",e.projectId),e?.parentId&&t.set("parentId",e.parentId),e?.assigneeAgentId&&t.set("assigneeAgentId",e.assigneeAgentId),e?.participantAgentId&&t.set("participantAgentId",e.participantAgentId),e?.assigneeUserId&&t.set("assigneeUserId",e.assigneeUserId),e?.touchedByUserId&&t.set("touchedByUserId",e.touchedByUserId),e?.inboxArchivedByUserId&&t.set("inboxArchivedByUserId",e.inboxArchivedByUserId),e?.unreadForUserId&&t.set("unreadForUserId",e.unreadForUserId),e?.labelId&&t.set("labelId",e.labelId),e?.createdByAgentId&&t.set("createdByAgentId",e.createdByAgentId),e?.createdByUserId&&t.set("createdByUserId",e.createdByUserId),e?.updatedSince&&t.set("updatedSince",e.updatedSince),e?.workspaceId&&t.set("workspaceId",e.workspaceId),e?.executionWorkspaceId&&t.set("executionWorkspaceId",e.executionWorkspaceId),e?.originKind&&t.set("originKind",e.originKind),e?.originKindPrefix&&t.set("originKindPrefix",e.originKindPrefix),e?.originId&&t.set("originId",e.originId),e?.descendantOf&&t.set("descendantOf",e.descendantOf),e?.createdFromIssueId&&t.set("createdFromIssueId",e.createdFromIssueId),e?.includeRoutineExecutions&&t.set("includeRoutineExecutions","true"),e?.includeBlockedBy&&t.set("includeBlockedBy","true"),e?.includeBlockedInboxAttention&&t.set("includeBlockedInboxAttention","true"),e?.includeLiveDescendantSummary&&t.set("includeLiveDescendantSummary","true"),e?.hasPlanDocument!==void 0&&t.set("hasPlanDocument",e.hasPlanDocument?"true":"false"),e?.q&&t.set("q",e.q),e?.limit&&t.set("limit",String(e.limit)),e?.offset!==void 0&&t.set("offset",String(e.offset)),e?.sortField&&t.set("sortField",e.sortField),e?.sortDir&&t.set("sortDir",e.sortDir),e?.afterId&&t.set("afterId",e.afterId),t}a(Rt,"issueListSearchParams");var Y={listAll:a(async(e,t,r)=>{const o=new Map;let s;for(;;){const l=await Y.list(e,{...t,limit:500,sortField:"id",sortDir:"asc",afterId:s},r);for(const u of l)o.set(u.id,u);if(l.length<500)return[...o.values()];s=l[l.length-1].id}},"listAll"),list:a((e,t,r)=>{const n=Rt(t).toString(),o=`/companies/${e}/issues${n?`?${n}`:""}`;return r?p.get(o,r):p.get(o)},"list"),listCompact:a((e,t,r)=>{const n=Rt(t);n.set("view","compact");const o=`/companies/${e}/issues?${n.toString()}`;return r?p.get(o,r):p.get(o)},"listCompact"),count:a((e,t)=>{const r=new URLSearchParams;return r.set("attention",t.attention),t.status&&r.set("status",t.status),t.assigneeAgentId&&r.set("assigneeAgentId",t.assigneeAgentId),t.assigneeUserId&&r.set("assigneeUserId",t.assigneeUserId),t.projectId&&r.set("projectId",t.projectId),t.labelId&&r.set("labelId",t.labelId),t.q&&r.set("q",t.q),p.get(`/companies/${e}/issues/count?${r.toString()}`)},"count"),listLabels:a(e=>p.get(`/companies/${e}/labels`),"listLabels"),createLabel:a((e,t)=>p.post(`/companies/${e}/labels`,t),"createLabel"),deleteLabel:a(e=>p.delete(`/labels/${e}`),"deleteLabel"),get:a((e,t)=>t?p.get(`/issues/${e}`,t):p.get(`/issues/${e}`),"get"),refs:a((e,t)=>p.get(`/companies/${e}/issues/refs?ids=${encodeURIComponent(t.join(","))}`),"refs"),getRunnerGoal:a((e,t)=>{const r=t?`?agentId=${encodeURIComponent(t)}`:"";return p.get(`/issues/${e}/runner-goal${r}`)},"getRunnerGoal"),actOnRunnerGoal:a((e,t)=>p.post(`/issues/${e}/runner-goal/actions`,t),"actOnRunnerGoal"),getModelOverride:a(e=>p.get(`/issues/${e}/model-override`),"getModelOverride"),setModelOverride:a((e,t)=>p.put(`/issues/${e}/model-override`,t),"setModelOverride"),getWatchdog:a(e=>p.get(`/issues/${e}/watchdog`),"getWatchdog"),getAgentTodo:a(e=>p.get(`/issues/${e}/agent-todo`),"getAgentTodo"),upsertWatchdog:a((e,t)=>p.put(`/issues/${e}/watchdog`,t),"upsertWatchdog"),deleteWatchdog:a(e=>p.delete(`/issues/${e}/watchdog`),"deleteWatchdog"),markRead:a(e=>p.post(`/issues/${e}/read`,{}),"markRead"),markUnread:a(e=>p.delete(`/issues/${e}/read`),"markUnread"),archiveFromInbox:a(e=>p.post(`/issues/${e}/inbox-archive`,{}),"archiveFromInbox"),unarchiveFromInbox:a(e=>p.delete(`/issues/${e}/inbox-archive`),"unarchiveFromInbox"),setTitle:a((e,t)=>p.put(`/issues/${e}/title`,t),"setTitle"),create:a((e,t)=>p.post(`/companies/${e}/issues`,t),"create"),update:a((e,t)=>{const r=p.patch(`/issues/${e}`,t);return typeof t.comment=="string"?Et(r,n=>It(n?.comment)):r},"update"),decideStalledReview:a((e,t)=>p.post(`/issues/${e}/stalled-review-decision`,t),"decideStalledReview"),retryWorkspaceExport:a((e,t)=>p.post(`/issues/${e}/recovery-actions/retry-workspace-export`,t),"retryWorkspaceExport"),resolveRecoveryAction:a((e,t)=>p.post(`/issues/${e}/recovery-actions/resolve`,t),"resolveRecoveryAction"),previewTreeControl:a((e,t)=>p.post(`/issues/${e}/tree-control/preview`,t),"previewTreeControl"),createTreeHold:a((e,t)=>p.post(`/issues/${e}/tree-holds`,t),"createTreeHold"),getTreeHold:a((e,t)=>p.get(`/issues/${e}/tree-holds/${t}`),"getTreeHold"),listTreeHolds:a((e,t)=>{const r=new URLSearchParams;t?.status&&r.set("status",t.status),t?.mode&&r.set("mode",t.mode),t?.includeMembers&&r.set("includeMembers","true");const n=r.toString();return p.get(`/issues/${e}/tree-holds${n?`?${n}`:""}`)},"listTreeHolds"),getTreeControlState:a(e=>p.get(`/issues/${e}/tree-control/state`),"getTreeControlState"),releaseTreeHold:a((e,t,r)=>p.post(`/issues/${e}/tree-holds/${t}/release`,r),"releaseTreeHold"),checkMonitorNow:a(e=>p.post(`/issues/${e}/monitor/check-now`,{}),"checkMonitorNow"),retryScheduledRetryNow:a(e=>p.post(`/issues/${e}/scheduled-retry/retry-now`,{}),"retryScheduledRetryNow"),remove:a(e=>p.delete(`/issues/${e}`),"remove"),checkout:a((e,t)=>p.post(`/issues/${e}/checkout`,{agentId:t,expectedStatuses:["todo","backlog","blocked","in_review"]}),"checkout"),release:a(e=>p.post(`/issues/${e}/release`,{}),"release"),listComments:a((e,t)=>{const r=new URLSearchParams;t?.after&&r.set("after",t.after),t?.order&&r.set("order",t.order),t?.limit&&r.set("limit",String(t.limit));const n=r.toString();return p.get(`/issues/${e}/comments${n?`?${n}`:""}`)},"listComments"),getQueuedComments:a(e=>p.get(`/issues/${e}/queued-comments`),"getQueuedComments"),editQueuedComment:a((e,t,r)=>p.patch(`/issues/${e}/queued-comments/${t}`,r),"editQueuedComment"),reorderQueuedComments:a((e,t)=>p.put(`/issues/${e}/queued-comments/order`,t),"reorderQueuedComments"),interruptQueuedComments:a((e,t)=>p.post(`/issues/${e}/queued-comments/interrupt`,t),"interruptQueuedComments"),interruptLatestQueuedComments:a(async(e,t)=>{const r=await Y.getQueuedComments(e);if(!r.queueId||r.targetRunId&&r.targetRunId!==t)throw new Error("The queued messages changed. Refresh and try again.");return Y.interruptQueuedComments(e,{queueId:r.queueId,revision:r.revision,targetRunId:r.targetRunId})},"interruptLatestQueuedComments"),steerQueuedComment:a((e,t,r)=>p.post(`/issues/${e}/queued-comments/${t}/steer`,r),"steerQueuedComment"),discardQueuedComment:a((e,t,r)=>p.delete(`/issues/${e}/queued-comments/${t}`,r),"discardQueuedComment"),listInteractions:a(e=>p.get(`/issues/${e}/interactions`),"listInteractions"),listAcceptedPlanDecompositions:a(e=>p.get(`/issues/${e}/accepted-plan-decompositions`),"listAcceptedPlanDecompositions"),createInteraction:a((e,t)=>p.post(`/issues/${e}/interactions`,t),"createInteraction"),acceptInteraction:a((e,t,r)=>{const{note:n,...o}=r??{};return p.post(`/issues/${e}/interactions/${t}/accept`,n?.trim()?{...o,note:n}:o)},"acceptInteraction"),rejectInteraction:a((e,t,r,n)=>p.post(`/issues/${e}/interactions/${t}/reject`,{...r?{reason:r}:{},...n?.trim()?{note:n}:{}}),"rejectInteraction"),cancelInteraction:a((e,t,r)=>p.post(`/issues/${e}/interactions/${t}/cancel`,r?{reason:r}:{}),"cancelInteraction"),skipInteraction:a((e,t,r)=>p.post(`/issues/${e}/interactions/${t}/skip`,r?{reason:r}:{}),"skipInteraction"),respondToInteraction:a((e,t,r)=>p.post(`/issues/${e}/interactions/${t}/respond`,r),"respondToInteraction"),submitInteractionVerdicts:a((e,t,r)=>p.post(`/issues/${e}/interactions/${t}/verdicts`,{verdicts:r}),"submitInteractionVerdicts"),getComment:a((e,t)=>p.get(`/issues/${e}/comments/${t}`),"getComment"),listFeedbackVotes:a(e=>p.get(`/issues/${e}/feedback-votes`),"listFeedbackVotes"),getCostSummary:a((e,t={})=>{const r=t.excludeRoot?"?excludeRoot=true":"";return p.get(`/issues/${e}/cost-summary${r}`)},"getCostSummary"),listFeedbackTraces:a((e,t)=>{const r=new URLSearchParams;for(const[o,s]of Object.entries(t??{}))s!==void 0&&r.set(o,String(s));const n=r.toString();return p.get(`/issues/${e}/feedback-traces${n?`?${n}`:""}`)},"listFeedbackTraces"),upsertFeedbackVote:a((e,t)=>p.post(`/issues/${e}/feedback-votes`,t),"upsertFeedbackVote"),addComment:a((e,t,r,n,o,s,l)=>Et(p.post(`/issues/${e}/comments`,{body:t,...s?{clientRequestId:s}:{},...r===void 0?{}:{reopen:r},...n===void 0?{}:{interrupt:n},...o?.length?{attachmentIds:o}:{},...l===void 0?{}:{deliver:l}}),It),"addComment"),cancelComment:a((e,t)=>p.delete(`/issues/${e}/comments/${t}?mode=cancel`),"cancelComment"),deleteComment:a((e,t)=>p.delete(`/issues/${e}/comments/${t}`),"deleteComment"),listDocuments:a((e,t)=>p.get(`/issues/${e}/documents${t?.includeSystem?"?includeSystem=true":""}`),"listDocuments"),getDocument:a((e,t)=>p.get(`/issues/${e}/documents/${encodeURIComponent(t)}`),"getDocument"),getDocumentPdf:a((e,t)=>p.getBlob(`/issues/${e}/documents/${encodeURIComponent(t)}/pdf`),"getDocumentPdf"),upsertDocument:a((e,t,r)=>p.put(`/issues/${e}/documents/${encodeURIComponent(t)}`,r),"upsertDocument"),lockDocument:a((e,t)=>p.post(`/issues/${e}/documents/${encodeURIComponent(t)}/lock`,{}),"lockDocument"),unlockDocument:a((e,t)=>p.post(`/issues/${e}/documents/${encodeURIComponent(t)}/unlock`,{}),"unlockDocument"),listDocumentRevisions:a((e,t)=>p.get(`/issues/${e}/documents/${encodeURIComponent(t)}/revisions`),"listDocumentRevisions"),restoreDocumentRevision:a((e,t,r)=>p.post(`/issues/${e}/documents/${encodeURIComponent(t)}/revisions/${r}/restore`,{}),"restoreDocumentRevision"),deleteDocument:a((e,t)=>p.delete(`/issues/${e}/documents/${encodeURIComponent(t)}`),"deleteDocument"),listAttachments:a(e=>p.get(`/issues/${e}/attachments`),"listAttachments"),uploadAttachment:a((e,t,r,n)=>{const o=Kn(r);if(o)return Promise.reject(o);const s=new FormData;return s.append("file",r),n&&s.append("issueCommentId",n),p.postForm(`/companies/${e}/issues/${t}/attachments`,s)},"uploadAttachment"),deleteAttachment:a(e=>p.delete(`/attachments/${e}`),"deleteAttachment"),privacyConstraints:a(e=>p.get(`/issues/${e}/privacy-constraints`),"privacyConstraints"),listAccessGrants:a((e,t)=>t?p.get(`/issues/${e}/access-grants`,t):p.get(`/issues/${e}/access-grants`),"listAccessGrants"),createAccessGrant:a((e,t)=>p.post(`/issues/${e}/access-grants`,t),"createAccessGrant"),revokeAccessGrant:a((e,t)=>p.post(`/issues/${e}/access-grants/${t}/revoke`,{}),"revokeAccessGrant"),setVisibility:a((e,t)=>p.patch(`/issues/${e}`,{visibility:t}),"setVisibility"),listApprovals:a(e=>p.get(`/issues/${e}/approvals`),"listApprovals"),linkApproval:a((e,t)=>p.post(`/issues/${e}/approvals`,{approvalId:t}),"linkApproval"),unlinkApproval:a((e,t)=>p.delete(`/issues/${e}/approvals/${t}`),"unlinkApproval"),listWorkProducts:a((e,t)=>{const r=`/issues/${e}/work-products${t?.refreshPullRequests?"?refreshPullRequests=true":""}`;return t?.fresh&&Hn(r),p.get(r,{signal:t?.signal})},"listWorkProducts"),ensureWorkProductReviewDocument:a((e,t)=>p.post(`/issues/${e}/work-products/${t}/review-document`,{}),"ensureWorkProductReviewDocument"),createWorkProduct:a((e,t)=>p.post(`/issues/${e}/work-products`,t),"createWorkProduct"),updateWorkProduct:a((e,t)=>p.patch(`/work-products/${e}`,t),"updateWorkProduct"),deleteWorkProduct:a(e=>p.delete(`/work-products/${e}`),"deleteWorkProduct")};function Z(e){return new Date(e).getTime()}a(Z,"toTimestamp");function ms(){const e=globalThis.crypto?.randomUUID?.();return e?`optimistic-${e}`:`optimistic-${Date.now()}-${Math.random().toString(36).slice(2,10)}`}a(ms,"createOptimisticCommentId");function et(e){return[...e].sort((t,r)=>{const n=Z(t.createdAt)-Z(r.createdAt);return n!==0?n:t.id.localeCompare(r.id)})}a(et,"sortIssueComments");function Ct(e){return et(e).reverse()}a(Ct,"sortIssueCommentsDesc");function Al(e){const t=new Date,r=ms();return{id:r,clientId:r,companyId:e.companyId,issueId:e.issueId,authorType:"user",authorAgentId:null,authorUserId:e.authorUserId,body:e.body,presentation:null,metadata:null,clientStatus:e.clientStatus??"pending",queueTargetRunId:e.queueTargetRunId??null,createdAt:t,updatedAt:t}}a(Al,"createOptimisticIssueComment");function Ml(e){return e.runId||e.interruptedRunId||e.comment.id&&(e.comment.id===e.activeRunWakeCommentId||e.comment.id===e.activeRunCommentId)||e.comment.authorAgentId&&e.activeRunAgentId&&e.comment.authorAgentId===e.activeRunAgentId?!1:e.comment.clientStatus==="queued"?!0:e.activeRunStartedAt?Z(e.comment.createdAt)>=Z(e.activeRunStartedAt):!1}a(Ml,"isQueuedIssueComment");function Tl(e,t){const r=t.queuedTargetRunId??null;return!r||!t.targetRunIsLive||t.runningRunId&&t.runningRunId!==r?e:{...e,clientStatus:"queued",queueState:"queued",queueTargetRunId:r}}a(Tl,"applyLocalQueuedIssueCommentState");function Pl(e,t){const r=e??[],n=[...r],o=new Set(n.map(l=>l.id)),s=new Set;for(const l of t){if(o.has(l.id))continue;const u=r.find(c=>!s.has(c.id)&&c.issueId===l.issueId&&c.authorType===l.authorType&&c.authorUserId===l.authorUserId&&c.body===l.body&&Math.abs(Z(c.createdAt)-Z(l.createdAt))<=6e4);if(u){s.add(u.id);const c={...u,clientId:l.clientId};n[n.findIndex(d=>d.id===u.id)]=c;continue}n.push(l)}return et(n)}a(Pl,"mergeIssueComments");function Ll(e,t){const r=e.findIndex(n=>n.clientId===t);return r===-1?{comments:e,comment:null}:{comments:e.filter(n=>n.clientId!==t),comment:e[r]??null}}a(Ll,"takeOptimisticIssueComment");function Ol(e){return et((e??[]).flatMap(t=>t))}a(Ol,"flattenIssueCommentPages");function hs(e,t){if(!(!e||e.length<t))return e[e.length-1]?.id}a(hs,"getNextIssueCommentPageParam");function $t(e,t){if(!(!e||e.length<t))return e[e.length-1]?.id}a($t,"getNextPageCursor");async function jl(e){const t=(e.pages??[]).map(l=>[...l]),r=e.pageParams?[...e.pageParams].slice(0,t.length):t.map(()=>null);for(;r.length<t.length;)r.push(null);if(e.pageSize<=0)return{pages:t,pageParams:r};let n=$t(t[t.length-1],e.pageSize);const o=Math.max(0,e.maxPages??Number.POSITIVE_INFINITY),s=new Set;for(;n&&!s.has(n)&&s.size<o;){s.add(n);const l=[...await e.fetchPage(n)];t.push(l),r.push(n),n=$t(l,e.pageSize)}return{pages:t,pageParams:r}}a(jl,"loadRemainingIssueCommentPages");function Nl(e){return e.activeDetailTab!=="chat"||!e.hasOlderComments||e.initialPageLoading||e.olderPageLoading||e.loadedCommentCount===0?!1:e.loadedCommentCount<e.autoLoadLimit}a(Nl,"shouldAutoloadOlderIssueComments");function Bl(e,t){if(!e)return e;const r={...e};return t.reopen===!0&&(e.status==="done"||e.status==="cancelled"||e.status==="blocked")&&(r.status="todo"),t.reassignment&&(r.assigneeAgentId=t.reassignment.assigneeAgentId,r.assigneeUserId=t.reassignment.assigneeUserId),r}a(Bl,"applyOptimisticIssueCommentUpdate");function ps(e,t){if(!e)return e;const r={...e,updatedAt:new Date},n=a(s=>Object.prototype.hasOwnProperty.call(t,s),"hasOwn"),o=a(s=>{n(s)&&(r[s]=t[s])},"assign");if(o("status"),o("priority"),o("assigneeAgentId"),o("assigneeUserId"),o("projectId"),o("parentId"),o("projectWorkspaceId"),o("executionWorkspaceId"),o("executionWorkspacePreference"),o("executionWorkspaceSettings"),o("hiddenAt"),n("labelIds")&&Array.isArray(t.labelIds)){const s=t.labelIds.filter(l=>typeof l=="string");r.labelIds=s,e.labels&&(r.labels=e.labels.filter(l=>s.includes(l.id)))}if(n("blockedByIssueIds")&&Array.isArray(t.blockedByIssueIds)&&e.blockedBy){const s=new Set(t.blockedByIssueIds.filter(l=>typeof l=="string"));r.blockedBy=e.blockedBy.filter(l=>s.has(l.id))}return n("projectId")&&(r.project=e.project?.id===r.projectId?e.project:null),n("parentId")&&(r.ancestors=void 0),n("executionWorkspaceId")&&(r.currentExecutionWorkspace=e.currentExecutionWorkspace?.id===r.executionWorkspaceId?e.currentExecutionWorkspace:null),r}a(ps,"applyOptimisticIssueFieldUpdate");function gs(e,t){const r=t instanceof Set?t:new Set(t);return r.has(e.id)||!!e.identifier&&r.has(e.identifier)}a(gs,"matchesIssueRef$1");function Ul(e,t,r){if(!e)return e;let n=!1;const o=e.map(s=>gs(s,t)?(n=!0,ps(s,r)??s):s);return n?o:e}a(Ul,"applyOptimisticIssueFieldUpdateToCollection");function zl(e,t){if(!e||e.length===0)return[[t]];const r=e.map(n=>[...n]);for(let n=0;n<r.length;n+=1){const o=r[n].findIndex(s=>s.id===t.id);if(o!==-1)return r[n][o]=t,r[n]=Ct(r[n]),r}return r[0]=Ct([...r[0],t]),r}a(zl,"upsertIssueCommentInPages");function Fl(e,t){return!e||e.length===0?[]:e.map(r=>r.filter(n=>n.id!==t)).filter(r=>r.length>0)}a(Fl,"removeIssueCommentFromPages");var ys=["issues","detail"],Er=6e4,bs=3e4;function ie(e){return typeof e=="string"&&e.length>0}a(ie,"isNonEmptyString");function Rr(e,t){const r=new Set;return ie(e)&&r.add(e),ie(t?.id)&&r.add(t.id),ie(t?.identifier)&&r.add(t.identifier),Array.from(r)}a(Rr,"collectIssueRefs");function vs(e,t){const r=t instanceof Set?t:new Set(t);return r.has(e.id)||!!e.identifier&&r.has(e.identifier)}a(vs,"matchesIssueRef");function Se(e){if(typeof e!="object"||e===null)return!1;const t=e;return ie(t.id)&&ie(t.companyId)&&typeof t.title=="string"&&typeof t.status=="string"&&typeof t.workMode=="string"&&typeof t.priority=="string"&&(t.projectId===null||typeof t.projectId=="string")&&(t.parentId===null||typeof t.parentId=="string")&&(t.identifier===null||typeof t.identifier=="string")&&(t.description===null||typeof t.description=="string")&&(t.assigneeAgentId===null||typeof t.assigneeAgentId=="string")&&(t.assigneeUserId===null||typeof t.assigneeUserId=="string")&&(t.executionRunId===null||typeof t.executionRunId=="string")&&(t.issueNumber===null||typeof t.issueNumber=="number")&&typeof t.requestDepth=="number"&&t.createdAt!=null&&t.updatedAt!=null}a(Se,"isCompleteIssueSnapshot");function _t(e,t){return e?{...e,...t}:t}a(_t,"mergeIssueSnapshots");function Cr(e,t,r){const n=Rr(t,r);for(const o of n){const s=e.getQueryData(ce.issues.detail(o));if(Se(s))return s}return e.getQueriesData({queryKey:ys}).map(([,o])=>o).find(o=>Se(o)&&vs(o,n))}a(Cr,"getCachedIssueDetail");function $r(e,t,r){if(!Se(t))return t;const n=Rr(r?.issueRef,t),o=_t(Cr(e,r?.issueRef,t),t);for(const s of n)e.setQueryData(ce.issues.detail(s),l=>_t(l,o));return o}a($r,"seedIssueDetailCache");async function _r(e,t,r){return $r(e,r?await Y.get(t,r):await Y.get(t),{issueRef:t})}a(_r,"fetchIssueDetail");function ks(e,t,r){return{queryKey:ce.issues.detail(t),queryFn:a(({signal:n})=>_r(e,t,{signal:n}),"queryFn"),placeholderData:Cr(e,t,r?.placeholderIssue??void 0)}}a(ks,"getIssueDetailQueryOptions");function xs(e,t,r){return Se(r?.issue)&&$r(e,r.issue,{issueRef:t}),e.prefetchQuery({queryKey:ce.issues.detail(t),queryFn:a(()=>_r(e,t),"queryFn"),staleTime:Er})}a(xs,"prefetchIssueDetail");function ws(e,t){return e.prefetchInfiniteQuery({queryKey:ce.issues.comments(t),queryFn:a(({pageParam:r})=>Y.listComments(t,{order:"desc",limit:50,...r?{after:r}:{}}),"queryFn"),initialPageParam:null,getNextPageParam:a(r=>hs(r,50),"getNextPageParam"),staleTime:bs,pages:1})}a(ws,"prefetchIssueComments");function Ss(e,t,r){return Promise.all([xs(e,t,r),ws(e,r?.issue?.id??t)])}a(Ss,"prefetchIssueDetailForNavigation");var S=Nt(Wn(),1);function Is({...e}){return(0,S.jsx)(ra,{"data-slot":"popover",...e})}a(Is,"Popover");function Es({...e}){return(0,S.jsx)(Qn,{"data-slot":"popover-trigger",...e})}a(Es,"PopoverTrigger");function Rs({className:e,align:t="center",sideOffset:r=4,disablePortal:n=!1,...o}){const s=(0,S.jsx)(ea,{"data-slot":"popover-content",align:t,sideOffset:r,className:V("bg-bg-2 text-ink data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 w-72 origin-(--radix-popover-content-transform-origin) rounded-md border p-4 shadow-md outline-hidden",e),...o});return n?s:(0,S.jsx)(Yn,{children:s})}a(Rs,"PopoverContent");function ql({...e}){return(0,S.jsx)(Gn,{"data-slot":"popover-anchor",...e})}a(ql,"PopoverAnchor");function Hl({className:e,...t}){return(0,S.jsx)("div",{"data-slot":"popover-title",className:V("font-medium",e),...t})}a(Hl,"PopoverTitle");function Wl({className:e,...t}){return(0,S.jsx)("p",{"data-slot":"popover-description",className:V("text-ink-3",e),...t})}a(Wl,"PopoverDescription");var Dr={name:"atom",size:24,node:[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["path",{d:"M20.2 20.2c2.04-2.03.02-7.36-4.5-11.9-4.54-4.52-9.87-6.54-11.9-4.5-2.04 2.03-.02 7.36 4.5 11.9 4.54 4.52 9.87 6.54 11.9 4.5Z",key:"1l2ple"}],["path",{d:"M15.7 15.7c4.52-4.54 6.54-9.87 4.5-11.9-2.03-2.04-7.36-.02-11.9 4.5-4.52 4.54-6.54 9.87-4.5 11.9 2.03 2.04 7.36.02 11.9-4.5Z",key:"1wam0m"}]]};Dr.node;var Cs=x(Dr),Ar={name:"ban",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M4.929 4.929 19.07 19.071",key:"196cmz"}]]};Ar.node;var $s=x(Ar),Mr={name:"box",size:24,node:[["path",{d:"M21 8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z",key:"hh9hay"}],["path",{d:"m3.3 7 8.7 5 8.7-5",key:"g66t2b"}],["path",{d:"M12 22V12",key:"d0xqtd"}]]};Mr.node;var _s=x(Mr),Tr={name:"brain",size:24,node:[["path",{d:"M12 18V5",key:"adv99a"}],["path",{d:"M15 13a4.17 4.17 0 0 1-3-4 4.17 4.17 0 0 1-3 4",key:"1e3is1"}],["path",{d:"M17.598 6.5A3 3 0 1 0 12 5a3 3 0 1 0-5.598 1.5",key:"1gqd8o"}],["path",{d:"M17.997 5.125a4 4 0 0 1 2.526 5.77",key:"iwvgf7"}],["path",{d:"M18 18a4 4 0 0 0 2-7.464",key:"efp6ie"}],["path",{d:"M19.967 17.483A4 4 0 1 1 12 18a4 4 0 1 1-7.967-.517",key:"1gq6am"}],["path",{d:"M6 18a4 4 0 0 1-2-7.464",key:"k1g0md"}],["path",{d:"M6.003 5.125a4 4 0 0 0-2.526 5.77",key:"q97ue3"}]]};Tr.node;var Ds=x(Tr),Pr={name:"briefcase",size:24,node:[["path",{d:"M16 20V4a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v16",key:"jecpp"}],["rect",{width:"20",height:"14",x:"2",y:"6",rx:"2",key:"i6l2r4"}]]};Pr.node;var As=x(Pr),Lr={name:"bug",size:24,node:[["path",{d:"M12 20v-9",key:"1qisl0"}],["path",{d:"M14 7a4 4 0 0 1 4 4v3a6 6 0 0 1-12 0v-3a4 4 0 0 1 4-4z",key:"uouzyp"}],["path",{d:"M14.12 3.88 16 2",key:"qol33r"}],["path",{d:"M21 21a4 4 0 0 0-3.81-4",key:"1b0z45"}],["path",{d:"M21 5a4 4 0 0 1-3.55 3.97",key:"5cxbf6"}],["path",{d:"M22 13h-4",key:"1jl80f"}],["path",{d:"M3 21a4 4 0 0 1 3.81-4",key:"1fjd4g"}],["path",{d:"M3 5a4 4 0 0 0 3.55 3.97",key:"1d7oge"}],["path",{d:"M6 13H2",key:"82j7cp"}],["path",{d:"m8 2 1.88 1.88",key:"fmnt4t"}],["path",{d:"M9 7.13V6a3 3 0 1 1 6 0v1.13",key:"1vgav8"}]]};Lr.node;var Ms=x(Lr),Or={name:"check",size:24,node:[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]};Or.node;var Vl=x(Or),jr={name:"chevron-right",size:24,node:[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]};jr.node;var Kl=x(jr),Nr={name:"circle-check",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m16 9-5.5 5.5L8 12",key:"xofnsj"}]],aliases:["check-circle-2"]};Nr.node;var Ts=x(Nr),Br={name:"circle-dashed",size:24,node:[["path",{d:"M10.1 2.182a10 10 0 0 1 3.8 0",key:"5ilxe3"}],["path",{d:"M13.9 21.818a10 10 0 0 1-3.8 0",key:"11zvb9"}],["path",{d:"M17.609 3.721a10 10 0 0 1 2.69 2.7",key:"1iw5b2"}],["path",{d:"M2.182 13.9a10 10 0 0 1 0-3.8",key:"c0bmvh"}],["path",{d:"M20.279 17.609a10 10 0 0 1-2.7 2.69",key:"1ruxm7"}],["path",{d:"M21.818 10.1a10 10 0 0 1 0 3.8",key:"qkgqxc"}],["path",{d:"M3.721 6.391a10 10 0 0 1 2.7-2.69",key:"1mcia2"}],["path",{d:"M6.391 20.279a10 10 0 0 1-2.69-2.7",key:"1fvljs"}]]};Br.node;var Ur=x(Br),zr={name:"circle-dot",size:24,node:[["circle",{cx:"12",cy:"12",r:"1",key:"41hilf"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]};zr.node;var Ps=x(zr),Fr={name:"circle-minus",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M8 12h8",key:"1wcyev"}]],aliases:["minus-circle"]};Fr.node;var Dt=x(Fr),qr={name:"circle",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]};qr.node;var At=x(qr),Hr={name:"code",size:24,node:[["path",{d:"m16 18 6-6-6-6",key:"eg8j8"}],["path",{d:"m8 6-6 6 6 6",key:"ppft3o"}]]};Hr.node;var Ls=x(Hr),Wr={name:"cog",size:24,node:[["path",{d:"M11 10.27 7 3.34",key:"16pf9h"}],["path",{d:"m11 13.73-4 6.93",key:"794ttg"}],["path",{d:"M12 22v-2",key:"1osdcq"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M14 12h8",key:"4f43i9"}],["path",{d:"m17 20.66-1-1.73",key:"eq3orb"}],["path",{d:"m17 3.34-1 1.73",key:"2wel8s"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"m20.66 17-1.73-1",key:"sg0v6f"}],["path",{d:"m20.66 7-1.73 1",key:"1ow05n"}],["path",{d:"m3.34 17 1.73-1",key:"nuk764"}],["path",{d:"m3.34 7 1.73 1",key:"1ulond"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}],["circle",{cx:"12",cy:"12",r:"8",key:"46899m"}]]};Wr.node;var Os=x(Wr),Vr={name:"compass",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m16.24 7.76-1.804 5.411a2 2 0 0 1-1.265 1.265L7.76 16.24l1.804-5.411a2 2 0 0 1 1.265-1.265z",key:"9ktpf1"}]]};Vr.node;var js=x(Vr),Kr={name:"copy",size:24,node:[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]};Kr.node;var Ql=x(Kr),Qr={name:"cpu",size:24,node:[["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"}]]};Qr.node;var Ns=x(Qr),Jr={name:"crown",size:24,node:[["path",{d:"M11.562 3.266a.5.5 0 0 1 .876 0L15.39 8.87a1 1 0 0 0 1.516.294L21.183 5.5a.5.5 0 0 1 .798.519l-2.834 10.246a1 1 0 0 1-.956.734H5.81a1 1 0 0 1-.957-.734L2.02 6.02a.5.5 0 0 1 .798-.519l4.276 3.664a1 1 0 0 0 1.516-.294z",key:"1vdc57"}],["path",{d:"M5 21h14",key:"11awu3"}]]};Jr.node;var Bs=x(Jr),Gr={name:"database",size:24,node:[["ellipse",{cx:"12",cy:"5",rx:"9",ry:"3",key:"msslwz"}],["path",{d:"M3 5V19A9 3 0 0 0 21 19V5",key:"1wlel7"}],["path",{d:"M3 12A9 3 0 0 0 21 12",key:"mv7ke4"}]]};Gr.node;var Us=x(Gr),Yr={name:"file-code",size:24,node:[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10 12.5 8 15l2 2.5",key:"1tg20x"}],["path",{d:"m14 12.5 2 2.5-2 2.5",key:"yinavb"}]]};Yr.node;var zs=x(Yr),Xr={name:"flame",size:24,node:[["path",{d:"M12 3q1 4 4 6.5t3 5.5a1 1 0 0 1-14 0 5 5 0 0 1 1-3 1 1 0 0 0 5 0c0-2-1.5-3-1.5-5q0-2 2.5-4",key:"1slcih"}]]};Xr.node;var Fs=x(Xr),Zr={name:"folder",size:24,node:[["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"}]]};Zr.node;var qs=x(Zr),en={name:"gem",size:24,node:[["path",{d:"M10.5 3 8 9l4 13 4-13-2.5-6",key:"b3dvk1"}],["path",{d:"M17 3a2 2 0 0 1 1.6.8l3 4a2 2 0 0 1 .013 2.382l-7.99 10.986a2 2 0 0 1-3.247 0l-7.99-10.986A2 2 0 0 1 2.4 7.8l2.998-3.997A2 2 0 0 1 7 3z",key:"7w4byz"}],["path",{d:"M2 9h20",key:"16fsjt"}]]};en.node;var Hs=x(en),tn={name:"git-branch",size:24,node:[["path",{d:"M15 6a9 9 0 0 0-9 9V3",key:"1cii5b"}],["circle",{cx:"18",cy:"6",r:"3",key:"1h7g24"}],["circle",{cx:"6",cy:"18",r:"3",key:"fqmcym"}]]};tn.node;var Ws=x(tn),rn={name:"globe",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]]};rn.node;var Vs=x(rn),nn={name:"hammer",size:24,node:[["path",{d:"m15 12-9.373 9.373a1 1 0 0 1-3.001-3L12 9",key:"1hayfq"}],["path",{d:"m18 15 4-4",key:"16gjal"}],["path",{d:"m21.5 11.5-1.914-1.914A2 2 0 0 1 19 8.172v-.344a2 2 0 0 0-.586-1.414l-1.657-1.657A6 6 0 0 0 12.516 3H9l1.243 1.243A6 6 0 0 1 12 8.485V10l2 2h1.172a2 2 0 0 1 1.414.586L18.5 14.5",key:"15ts47"}]]};nn.node;var Ks=x(nn),an={name:"heart",size:24,node:[["path",{d:"M2 9.5a5.5 5.5 0 0 1 9.591-3.676.56.56 0 0 0 .818 0A5.49 5.49 0 0 1 22 9.5c0 2.29-1.5 4-3 5.5l-5.492 5.313a2 2 0 0 1-3 .019L5 15c-1.5-1.5-3-3.2-3-5.5",key:"mvr1a0"}]]};an.node;var Qs=x(an),on={name:"hexagon",size:24,node:[["path",{d:"M21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16z",key:"yt0hxn"}]]};on.node;var Js=x(on),sn={name:"layers",size:24,node:[["path",{d:"M12.83 2.18a2 2 0 0 0-1.66 0L2.6 6.08a1 1 0 0 0 0 1.83l8.58 3.91a2 2 0 0 0 1.66 0l8.58-3.9a1 1 0 0 0 0-1.83z",key:"zw3jo"}],["path",{d:"M2 12a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 12",key:"1wduqc"}],["path",{d:"M2 17a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 17",key:"kqbvx6"}]],aliases:["layers-3"]};sn.node;var Gs=x(sn),ln={name:"lightbulb",size:24,node:[["path",{d:"M15 14c.2-1 .7-1.7 1.5-2.5 1-.9 1.5-2.2 1.5-3.5A6 6 0 0 0 6 8c0 1 .2 2.2 1.5 3.5.7.7 1.3 1.5 1.5 2.5",key:"1gvzjb"}],["path",{d:"M9 18h6",key:"x1upvd"}],["path",{d:"M10 22h4",key:"ceow96"}]]};ln.node;var Ys=x(ln),un={name:"loader-circle",size:24,node:[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]],aliases:["loader-2"]};un.node;var Xs=x(un),cn={name:"lock",size:24,node:[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 10 0v4",key:"fwvmzm"}]]};cn.node;var Zs=x(cn),dn={name:"mail",size:24,node:[["path",{d:"m22 7-8.991 5.727a2 2 0 0 1-2.009 0L2 7",key:"132q7q"}],["rect",{x:"2",y:"4",width:"20",height:"16",rx:"2",key:"izxlao"}]]};dn.node;var ei=x(dn),fn={name:"message-square",size:24,node:[["path",{d:"M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z",key:"18887p"}]]};fn.node;var ti=x(fn),mn={name:"package",size:24,node:[["path",{d:"M11 21.73a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73z",key:"1a0edw"}],["path",{d:"M12 22V12",key:"d0xqtd"}],["polyline",{points:"3.29 7 12 12 20.71 7",key:"ousv84"}],["path",{d:"m7.5 4.27 9 5.15",key:"1c824w"}]]};mn.node;var ri=x(mn),hn={name:"plus",size:24,node:[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]};hn.node;var Jl=x(hn),pn={name:"puzzle",size:24,node:[["path",{d:"M15.39 4.39a1 1 0 0 0 1.68-.474 2.5 2.5 0 1 1 3.014 3.015 1 1 0 0 0-.474 1.68l1.683 1.682a2.414 2.414 0 0 1 0 3.414L19.61 15.39a1 1 0 0 1-1.68-.474 2.5 2.5 0 1 0-3.014 3.015 1 1 0 0 1 .474 1.68l-1.683 1.682a2.414 2.414 0 0 1-3.414 0L8.61 19.61a1 1 0 0 0-1.68.474 2.5 2.5 0 1 1-3.014-3.015 1 1 0 0 0 .474-1.68l-1.683-1.682a2.414 2.414 0 0 1 0-3.414L4.39 8.61a1 1 0 0 1 1.68.474 2.5 2.5 0 1 0 3.014-3.015 1 1 0 0 1-.474-1.68l1.683-1.682a2.414 2.414 0 0 1 3.414 0z",key:"w46dr5"}]]};pn.node;var ni=x(pn),gn={name:"radar",size:24,node:[["path",{d:"M19.07 4.93A10 10 0 0 0 6.99 3.34",key:"z3du51"}],["path",{d:"M4 6h.01",key:"oypzma"}],["path",{d:"M2.29 9.62A10 10 0 1 0 21.31 8.35",key:"qzzz0"}],["path",{d:"M16.24 7.76A6 6 0 1 0 8.23 16.67",key:"1yjesh"}],["path",{d:"M12 18h.01",key:"mhygvu"}],["path",{d:"M17.99 11.66A6 6 0 0 1 15.77 16.67",key:"1u2y91"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}],["path",{d:"m13.41 10.59 5.66-5.66",key:"mhq4k0"}]]};gn.node;var ai=x(gn),yn={name:"rocket",size:24,node:[["path",{d:"M12 15v5s3.03-.55 4-2c1.08-1.62 0-5 0-5",key:"qeys4"}],["path",{d:"M4.5 16.5c-1.5 1.26-2 5-2 5s3.74-.5 5-2c.71-.84.7-2.13-.09-2.91a2.18 2.18 0 0 0-2.91-.09",key:"u4xsad"}],["path",{d:"M9 12a22 22 0 0 1 2-3.95A12.88 12.88 0 0 1 22 2c0 2.72-.78 7.5-6 11a22.4 22.4 0 0 1-4 2z",key:"676m9"}],["path",{d:"M9 12H4s.55-3.03 2-4c1.62-1.08 5 .05 5 .05",key:"92ym6u"}]]};yn.node;var oi=x(yn),bn={name:"search",size:24,node:[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]]};bn.node;var si=x(bn),vn={name:"shield",size:24,node:[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}]]};vn.node;var ii=x(vn),kn={name:"sparkles",size:24,node:[["path",{d:"M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z",key:"1s2grr"}],["path",{d:"M20 2v4",key:"1rf3ol"}],["path",{d:"M22 4h-4",key:"gwowj6"}],["circle",{cx:"4",cy:"20",r:"2",key:"6kqj1y"}]],aliases:["stars"]};kn.node;var li=x(kn),xn={name:"star",size:24,node:[["path",{d:"M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z",key:"r04s7s"}]]};xn.node;var ui=x(xn),wn={name:"target",size:24,node:[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["circle",{cx:"12",cy:"12",r:"6",key:"1vlfrh"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}]]};wn.node;var ci=x(wn),Sn={name:"telescope",size:24,node:[["path",{d:"m10.065 12.493-6.18 1.318a.934.934 0 0 1-1.108-.702l-.537-2.15a1.07 1.07 0 0 1 .691-1.265l13.504-4.44",key:"k4qptu"}],["path",{d:"m13.56 11.747 4.332-.924",key:"19l80z"}],["path",{d:"m16 21-3.105-6.21",key:"7oh9d"}],["path",{d:"M16.485 5.94a2 2 0 0 1 1.455-2.425l1.09-.272a1 1 0 0 1 1.212.727l1.515 6.06a1 1 0 0 1-.727 1.213l-1.09.272a2 2 0 0 1-2.425-1.455z",key:"m7xp4m"}],["path",{d:"m6.158 8.633 1.114 4.456",key:"74o979"}],["path",{d:"m8 21 3.105-6.21",key:"1fvxut"}],["circle",{cx:"12",cy:"13",r:"2",key:"1c1ljs"}]]};Sn.node;var di=x(Sn),In={name:"terminal",size:24,node:[["path",{d:"M12 19h8",key:"baeox8"}],["path",{d:"m4 17 6-6-6-6",key:"1yngyt"}]]};In.node;var fi=x(In),En={name:"wrench",size:24,node:[["path",{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.106-3.105c.32-.322.863-.22.983.218a6 6 0 0 1-8.259 7.057l-7.91 7.91a1 1 0 0 1-2.999-3l7.91-7.91a6 6 0 0 1 7.057-8.259c.438.12.54.662.219.984z",key:"1ngwbx"}]]};En.node;var mi=x(En),Rn={name:"zap",size:24,node:[["path",{d:"M15.914 4a1.5 1.5 0 00-2.474-1.561l-9 9A1.5 1.5 0 005.5 14h4.002a.5.5 0 01.471.666L8.086 20a1.5 1.5 0 002.475 1.56l9-9A1.5 1.5 0 0018.5 10h-3.997a.5.5 0 01-.472-.667z",key:"1v7up4"}]]};Rn.node;var hi=x(Rn),Gl={backlog:"text-ink-3 border-ink-3",todo:"text-amber-600 border-amber-600 dark:text-amber-400 dark:border-amber-400",in_progress:"text-blue-600 border-blue-600 dark:text-blue-400 dark:border-blue-400",in_review:"text-violet-600 border-violet-600 dark:text-violet-400 dark:border-violet-400",done:"text-green-600 border-green-600 dark:text-green-400 dark:border-green-400",cancelled:"text-neutral-500 border-neutral-500",blocked:"text-red-600 border-red-600 dark:text-red-400 dark:border-red-400"},Yl="text-ink-3 border-ink-3",Xl={backlog:"text-ink-3",todo:"text-amber-600 dark:text-amber-400",in_progress:"text-blue-600 dark:text-blue-400",in_review:"text-violet-600 dark:text-violet-400",done:"text-green-600 dark:text-green-400",cancelled:"text-neutral-500",blocked:"text-red-600 dark:text-red-400"},Zl="text-ink-3",ye={gray:"bg-[#F5F3F0] text-[#52585D] border-[#A8AEB2] dark:bg-[#6e696024] dark:text-[#9A958A] dark:border-[#9e958a73]",blue:"bg-[#DBEAFE] text-[#1D4ED8] border-[#2563EB] dark:bg-[#2563eb2e] dark:text-[#2563EB] dark:border-[#2563eb73]",amber:"bg-[#FEF3C7] text-[#B45309] border-[#F59E0B] dark:bg-[#f59e0b24] dark:text-[#F59E0B] dark:border-[#f59e0b73]",green:"bg-[#DCFCE7] text-[#188A3C] border-[#22C55E] dark:bg-[#22c55e1f] dark:text-[#22C55E] dark:border-[#22c55e73]",violet:"bg-[#EDE9FE] text-[#5B21B6] border-[#7C3AED] dark:bg-[#7c3aed2e] dark:text-[#7C3AED] dark:border-[#7c3aed73]",red:"bg-[#FEE2E2] text-[#991B1B] border-[#DC2626] dark:bg-[#dc26262e] dark:text-[#DC2626] dark:border-[#dc262673]"},eu={active:`border ${ye.green}`,running:`border ${ye.blue}`,scheduled_retry:"bg-sky-100 text-sky-700 dark:bg-sky-900/50 dark:text-sky-300",paused:`border ${ye.amber}`,idle:`border ${ye.gray}`,archived:"bg-bg-3 text-ink-3",planned:"bg-bg-3 text-ink-3",achieved:"bg-green-100 text-green-700 dark:bg-green-900/50 dark:text-green-300",completed:"bg-green-100 text-green-700 dark:bg-green-900/50 dark:text-green-300",failed:"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300",timed_out:"bg-orange-100 text-orange-700 dark:bg-orange-900/50 dark:text-orange-300",succeeded:"bg-green-100 text-green-700 dark:bg-green-900/50 dark:text-green-300",ok:"bg-green-100 text-green-700 dark:bg-green-900/50 dark:text-green-300",warning:"bg-amber-100 text-amber-700 dark:bg-amber-900/50 dark:text-amber-300",error:"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300",info:"bg-sky-100 text-sky-700 dark:bg-sky-900/50 dark:text-sky-300",terminated:"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300",pending:"bg-yellow-100 text-yellow-700 dark:bg-yellow-900/50 dark:text-yellow-300",queued:"bg-yellow-100 text-yellow-700 dark:bg-yellow-900/50 dark:text-yellow-300",pending_approval:"bg-amber-100 text-amber-700 dark:bg-amber-900/50 dark:text-amber-300",revision_requested:"bg-amber-100 text-amber-700 dark:bg-amber-900/50 dark:text-amber-300",approved:"bg-green-100 text-green-700 dark:bg-green-900/50 dark:text-green-300",rejected:"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300",draft:"bg-bg-3 text-ink-3",backlog:"bg-bg-3 text-ink-3",todo:"bg-amber-100 text-amber-700 dark:bg-amber-900/50 dark:text-amber-300",in_progress:"bg-blue-100 text-blue-700 dark:bg-blue-900/50 dark:text-blue-300",in_review:"bg-violet-100 text-violet-700 dark:bg-violet-900/50 dark:text-violet-300",blocked:"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300",done:"bg-green-100 text-green-700 dark:bg-green-900/50 dark:text-green-300",cancelled:"bg-bg-3 text-ink-3",allowed:"bg-green-100 text-green-700 dark:bg-green-900/50 dark:text-green-300",denied:"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300",block:"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300","require-approval":"bg-amber-100 text-amber-700 dark:bg-amber-900/50 dark:text-amber-300",redacted:"bg-violet-100 text-violet-700 dark:bg-violet-900/50 dark:text-violet-300","rate-limit":"bg-orange-100 text-orange-700 dark:bg-orange-900/50 dark:text-orange-300",deferred:"bg-sky-100 text-sky-700 dark:bg-sky-900/50 dark:text-sky-300",hidden:"bg-bg-3 text-ink-3",quarantined:"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300","runtime-error":"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300",healthy:"bg-green-100 text-green-700 dark:bg-green-900/50 dark:text-green-300",degraded:"bg-amber-100 text-amber-700 dark:bg-amber-900/50 dark:text-amber-300",unchecked:"bg-bg-3 text-ink-3"},tu="bg-bg-3 text-ink-3",ru="text-[#1D4ED8] dark:text-[#2563EB]",nu="bg-blue-500/10 border-blue-500/30 text-blue-600 dark:text-blue-400",au={info:"border-[#2563EB]/40 bg-[#DBEAFE]/50 text-[#1D4ED8] dark:border-[#2563eb59] dark:bg-[#2563eb14] dark:text-[#93C5FD]",warning:"border-[#F59E0B]/50 bg-[#FEF3C7]/60 text-[#B45309] dark:border-[#f59e0b59] dark:bg-[#f59e0b12] dark:text-[#F59E0B]",danger:"border-bad/40 bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300"},ou={idle:"--status-agent-idle",active:"--status-agent-idle",running:"--status-agent-running",paused:"--status-agent-paused",error:"--status-agent-error"},su="--status-agent-idle",iu={idle:"--status-task-backlog",backlog:"--status-task-backlog",todo:"--status-task-todo",in_progress:"--status-task-in_progress",in_review:"--status-task-in_review",done:"--status-task-done",blocked:"--status-task-blocked",cancelled:"--status-task-cancelled"},lu="--status-task-backlog",pi={idle:"--status-task-icon-backlog",backlog:"--status-task-icon-backlog",todo:"--status-task-icon-todo",in_progress:"--status-task-icon-in_progress",in_review:"--status-task-icon-in_review",done:"--status-task-icon-done",blocked:"--status-task-icon-blocked",cancelled:"--status-task-icon-cancelled",in_queue:"--status-task-icon-in_queue"};var uu={running:"bg-blue-400 animate-pulse",active:"bg-green-400",paused:"bg-yellow-400",idle:"bg-yellow-400",pending_approval:"bg-amber-400",error:"bg-red-400",archived:"bg-neutral-400"},cu="bg-neutral-400",du={critical:"text-red-600 dark:text-red-400",high:"text-orange-600 dark:text-orange-400",medium:"text-yellow-600 dark:text-yellow-400",low:"text-blue-600 dark:text-blue-400"},fu="text-yellow-600 dark:text-yellow-400",mu={unknown:"text-ink-3 border-ink-3",open:"text-blue-600 border-blue-600 dark:text-blue-400 dark:border-blue-400",waiting:"text-amber-600 border-amber-600 dark:text-amber-400 dark:border-amber-400",running:"text-blue-600 border-blue-600 dark:text-blue-400 dark:border-blue-400",succeeded:"text-green-600 border-green-600 dark:text-green-400 dark:border-green-400",merged:"text-violet-600 border-violet-600 dark:text-violet-400 dark:border-violet-400",failed:"text-red-600 border-red-600 dark:text-red-400 dark:border-red-400",blocked:"text-red-600 border-red-600 dark:text-red-400 dark:border-red-400",closed:"text-neutral-500 border-neutral-500",archived:"text-neutral-500 border-neutral-500",auth_required:"text-amber-600 border-amber-600 dark:text-amber-400 dark:border-amber-400",unreachable:"text-red-600 border-red-600 dark:text-red-400 dark:border-red-400"},hu="text-ink-3 border-ink-3",pu={unknown:"bg-bg-3 text-ink-3",open:"bg-blue-100 text-blue-700 dark:bg-blue-900/50 dark:text-blue-300",waiting:"bg-amber-100 text-amber-700 dark:bg-amber-900/50 dark:text-amber-300",running:"bg-blue-100 text-blue-700 dark:bg-blue-900/50 dark:text-blue-300",succeeded:"bg-green-100 text-green-700 dark:bg-green-900/50 dark:text-green-300",failed:"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300",blocked:"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300",closed:"bg-bg-3 text-ink-3",archived:"bg-bg-3 text-ink-3",auth_required:"bg-amber-100 text-amber-700 dark:bg-amber-900/50 dark:text-amber-300",unreachable:"bg-red-100 text-red-700 dark:bg-red-900/50 dark:text-red-300"},gu="bg-bg-3 text-ink-3",yu={unknown:"",fresh:"",stale:"opacity-70 [border-style:dashed]",auth_required:"[border-style:dashed]",unreachable:"[border-style:dashed]"},gi={sm:14,md:16,lg:20},yi=x("TaskProgressSpinner",[["circle",{cx:"12",cy:"12",r:"10",pathLength:"100",strokeDasharray:"80 20",key:"progress"}]]),bi={idle:At,backlog:Ur,todo:At,in_progress:yi,in_review:Ps,done:Ts,blocked:Dt,cancelled:$s,in_queue:Dt},vi=Ur;function ki({status:e,size:t="md",className:r,title:n}){const o=gi[t],s=bi[e]??vi,l=pi[e]??"--status-task-icon-backlog",u=n?{role:"img","aria-label":n}:{"aria-hidden":!0};return(0,S.jsx)(s,{size:o,className:V("inline-block shrink-0 align-middle",e==="in_progress"&&"motion-safe:animate-spin",r),style:{color:`var(${l})`},...u,children:n?(0,S.jsx)("title",{children:n}):null})}a(ki,"StatusGlyph");var Mt={folder:qs,rocket:oi,code:Ls,terminal:fi,database:Us,globe:Vs,package:ri,boxes:Zn,box:_s,layers:Gs,briefcase:As,compass:js,target:ci,flame:Fs,zap:hi,star:ui,bug:Ms,wrench:mi,hammer:Ks,lightbulb:Ys,sparkles:li,shield:ii,lock:Zs,search:si,cog:Os,brain:Ds,cpu:Ns,"git-branch":Ws,"file-code":zs,puzzle:ni,gem:Hs,atom:Cs,heart:Qs,mail:ei,"message-square":ti,crown:Bs,radar:ai,telescope:di,hexagon:Js},xi="folder";function wi(e){return e&&Un.includes(e)?Mt[e]:Mt[xi]}a(wi,"getProjectIcon");var Si={xs:{box:"h-4 w-4 rounded-sm",icon:"h-2.5 w-2.5"},sm:{box:"h-6 w-6 rounded-md",icon:"h-3.5 w-3.5"},md:{box:"h-7 w-7 rounded-lg",icon:"h-4 w-4"},lg:{box:"h-9 w-9 rounded-lg",icon:"h-5 w-5"}};function Ii({color:e,icon:t,size:r="md",className:n}){const o=Si[r],s=!!e,l=wi(t);return(0,S.jsx)("span",{"aria-hidden":!0,className:V("inline-flex shrink-0 items-center justify-center",o.box,s?"text-white":"bg-bg-3 text-ink-3",n),style:s?{backgroundColor:e??void 0}:void 0,children:(0,S.jsx)(l,{className:o.icon})})}a(Ii,"ProjectTile");var le=null,qe=new Set;function Cn(){for(const e of qe)e()}a(Cn,"emitQuicklookChange");function Tt(e){le!==e&&(le=e,Cn())}a(Tt,"openQuicklookId");function Pt(e){le===e&&(le=null,Cn())}a(Pt,"closeQuicklookId");function Ei(e){return qe.add(e),()=>{qe.delete(e)}}a(Ei,"subscribeQuicklook");function Ri(e){return i.useSyncExternalStore(Ei,()=>le===e,()=>!1)}a(Ri,"useIsQuicklookOpen");var Ci=120,$i=13,_i="w-72 p-3";function Di(e="start"){return e==="start"?-13:e==="end"?$i:0}a(Di,"quicklookAlignOffset");function Ai(e){if(!e)return null;const t=e.replace(/!\[[^\]]*]\([^)]+\)/g," ").replace(/\[([^\]]+)\]\([^)]+\)/g,"$1").replace(/[#>*_`~-]+/g," ").replace(/\s+/g," ").trim();return t?t.length>180?`${t.slice(0,177).trimEnd()}...`:t:null}a(Ai,"summarizeIssueDescription");function Mi({className:e}){return(0,S.jsx)("span",{className:V("text-xs",e),"aria-hidden":!0,children:"·"})}a(Mi,"QuicklookSeparator");function Ti(e){const t=e.replace(/_/g," ");return t.charAt(0).toUpperCase()+t.slice(1)}a(Ti,"statusLabel");function Pi({issue:e,linkTo:t,linkState:r,compact:n=!1}){const o=(0,i.useMemo)(()=>Ai(e.description),[e.description]),s=e.project?.name;return(0,S.jsxs)("div",{className:V("space-y-2",n&&"space-y-1.5"),children:[(0,S.jsxs)("div",{className:"flex items-center gap-1",children:[(0,S.jsxs)("div",{className:"flex min-w-0 flex-1 items-center gap-1",children:[(0,S.jsx)(ki,{status:e.status,size:"md",title:Ti(e.status)}),(0,S.jsx)("span",{className:"shrink-0 font-mono text-(length:--text-micro) text-ink-3",children:e.identifier??e.id.slice(0,8)}),s?(0,S.jsxs)(S.Fragment,{children:[(0,S.jsx)(Mi,{className:"shrink-0 text-ink-3"}),(0,S.jsxs)("span",{className:"flex min-w-0 max-w-(--sz-12rem) flex-1 items-center gap-1 text-(length:--text-micro) text-ink-3",title:s,"data-testid":"quicklook-project",children:[(0,S.jsx)(Ii,{size:"xs"}),(0,S.jsx)("span",{className:"truncate",children:s})]})]}):null]}),(0,S.jsx)("span",{className:"shrink-0 text-(length:--text-micro) text-ink-3",children:es(new Date(e.updatedAt))})]}),(0,S.jsx)(me,{to:t,state:r??wr(null,e),className:"block text-sm font-medium leading-snug hover:underline line-clamp-2",children:e.title}),o?(0,S.jsx)("p",{className:"text-xs leading-5 text-ink-3 [display:-webkit-box] [-webkit-box-orient:vertical] [-webkit-line-clamp:4] overflow-hidden",children:o}):null]})}a(Pi,"IssueQuicklookCard");var Li=i.forwardRef(a(function({issuePathId:t,to:r,children:n,className:o,state:s,disableIssueQuicklook:l=!1,issuePrefetch:u=null,issueQuicklookSide:c="top",issueQuicklookAlign:d="start",onClick:f,onClickCapture:m,onMouseEnter:g,onFocus:v,onBlur:b,onTouchStart:y,...h},k){const w=qn(),I=i.useMemo(()=>Symbol("issue-quicklook"),[]),$=Ri(I),E=i.useRef(null),_=i.useRef(null),M=i.useRef(null),j=i.useCallback(R=>{_.current=R,typeof k=="function"?k(R):k&&(k.current=R)},[k]),D=i.useCallback(()=>{E.current&&(clearTimeout(E.current),E.current=null)},[]),B=i.useCallback(()=>{D(),Tt(I)},[D,I]),J=i.useCallback(()=>{D(),E.current=setTimeout(()=>{E.current=null,Tt(I)},Ci)},[D,I]),L=i.useCallback(()=>{D(),Pt(I)},[D,I]);i.useEffect(()=>()=>{D(),Pt(I)},[D,I]),i.useEffect(()=>{if(!$)return;const R=12,ot=a((W,oe,G)=>{if(!W)return!1;const H=W.getBoundingClientRect();return oe>=H.left-R&&oe<=H.right+R&&G>=H.top-R&&G<=H.bottom+R},"nearBox"),Nn=a((W,oe)=>{const G=_.current,H=M.current;if(G?.matches(":hover")||H?.matches(":hover")||ot(G,W,oe)||ot(H,W,oe))return!0;const Ae=document.activeElement;return G===Ae||!!H&&!!Ae&&H.contains(Ae)},"stillEngaged"),st=a(W=>{Nn(W.clientX,W.clientY)||L()},"onPointerMove");return document.addEventListener("pointermove",st,{passive:!0}),()=>document.removeEventListener("pointermove",st)},[$,L]);const q=u?wr(s,u):s,{data:U,isLoading:z}=ta({...ks(w,t,{placeholderIssue:u??void 0}),enabled:$,staleTime:Er}),jn=ds(t),ae=i.useCallback(()=>{Ss(w,t,{issue:u})},[t,u,w]),at=(0,S.jsx)(me,{ref:j,to:r,state:q,className:o,onMouseEnter:a(R=>{ae(),g?.(R)},"onMouseEnter"),onFocus:a(R=>{ae(),B(),v?.(R)},"onFocus"),onBlur:a(R=>{setTimeout(()=>L(),0),b?.(R)},"onBlur"),onTouchStart:a(R=>{ae(),y?.(R)},"onTouchStart"),onClickCapture:a(R=>{ae(),m?.(R)},"onClickCapture"),onClick:a(R=>{L(),f?.(R)},"onClick"),...h,children:n});return l?at:(0,S.jsxs)(Is,{open:$,onOpenChange:a(R=>R?B():L(),"onOpenChange"),children:[(0,S.jsx)(Es,{asChild:!0,onMouseEnter:a(()=>{ae(),J()},"onMouseEnter"),onMouseLeave:L,children:at}),(0,S.jsx)(Rs,{ref:M,"data-quicklook":!0,className:_i,side:c,align:d,alignOffset:Di(d),onMouseEnter:B,onMouseLeave:L,onOpenAutoFocus:a(R=>R.preventDefault(),"onOpenAutoFocus"),onCloseAutoFocus:a(R=>R.preventDefault(),"onCloseAutoFocus"),children:U?(0,S.jsx)(Pi,{issue:U,linkTo:jn,linkState:q,compact:!0}):(0,S.jsxs)("div",{className:"space-y-2",children:[(0,S.jsx)("div",{className:"h-4 w-24 rounded bg-bg-3/50"}),(0,S.jsx)("div",{className:"h-4 w-full rounded bg-bg-3/40"}),(0,S.jsx)("div",{className:"h-4 w-3/4 rounded bg-bg-3/30"}),z?null:(0,S.jsx)("p",{className:"text-xs text-ink-3",children:"Unable to load task preview."})]})})]})},"IssueLinkQuicklookImpl")),$n=new Set(["dashboard","companies","company","skills","teams-catalog","org","agents","chats","apps","projects","workspaces","terminal","execution-workspaces","issues","tasks","routines","goals","artifacts","tools","approvals","costs","usage","activity","audit","decisions","inbox","board-chat","artifacts","u","design-guide","search","settings","timeline"]),tt=new Set(["auth","invite","board-claim","cli-auth","mcp-connect","dot-connect","assistant-connections","docs","instance","s"]);function ue(e){return e.trim().toUpperCase()}a(ue,"normalizeCompanyPrefix");function _n(e){const t=e.match(/^([^?#]*)(\?[^#]*)?(#.*)?$/);return{pathname:t?.[1]??e,search:t?.[2]??"",hash:t?.[3]??""}}a(_n,"splitPath");function Oi(e){return e.split("/").filter(Boolean)[0]??null}a(Oi,"getRootSegment");function ji(e){if(e==="/")return!0;const t=Oi(e);return t?tt.has(t.toLowerCase()):!0}a(ji,"isGlobalPath");function Dn(e){const t=e.split("/").filter(Boolean);if(t.length===0)return null;const r=t[0].toLowerCase();return tt.has(r)||$n.has(r)?null:ue(t[0])}a(Dn,"extractCompanyPrefixFromPath");function Lt(e,t){const{pathname:r,search:n,hash:o}=_n(e);if(!r.startsWith("/")||ji(r)||!t)return e;const s=ue(t);return Dn(r)?e:`/${s}${r}${n}${o}`}a(Lt,"applyCompanyPrefix");function Ni(e,...t){const r=["cases",...t].filter(Boolean).join("/");return e?`/${ue(e)}/${r}`:`/${r}`}a(Ni,"caseHref");function bu(e){const{pathname:t,search:r,hash:n}=_n(e),o=t.split("/").filter(Boolean);if(o.length>=2){const s=o[1].toLowerCase();if(!tt.has(o[0].toLowerCase())&&$n.has(s))return`/${o.slice(1).join("/")}${r}${n}`}return`${t}${r}${n}`}a(bu,"toCompanyRelativePath");var An=/^[A-Z][A-Z0-9]*-\d+$/i,Bi=/^issue:\/\/:?([^?#\s]+)([?#].*)?$/i,Ui=/issue:\/\/:?[^\s<>()]+|https?:\/\/[^\s<>()]+|\/(?:[^\s<>()/]+\/)*issues\/[A-Z][A-Z0-9]*-\d+(?=$|[\s<>)\],.;!?:])|\b[A-Z][A-Z0-9]*-\d+\b/gi;function Mn(e){if(!e)return null;const t=e.trim();if(!t||/^https?:\/\//i.test(t))return null;const r=t.split(/[?#]/,1)[0].split("/").filter(Boolean),n=r.findIndex(s=>s==="issues");if(n===-1||n===r.length-1)return null;const o=decodeURIComponent(r[n+1]??"");return!o||o.startsWith(":")?null:An.test(o)?o.toUpperCase():o}a(Mn,"parseIssuePathIdFromPath");function Tn(e,t){if(!e)return null;const r=e.trim(),n=r.match(Bi);if(n?.[1]){const l=decodeURIComponent(n[1]);return{issuePathId:l,href:`/issues/${encodeURIComponent(l)}${n[2]??""}`}}const o=Mn(e);if(o)return{issuePathId:o,href:`/issues/${encodeURIComponent(o)}${r.match(/[?#].*$/)?.[0]??""}`};if(!An.test(r))return null;const s=r.toUpperCase();if(t&&t.size>0){const l=s.split("-")[0];if(!l||!t.has(l))return null}return{issuePathId:s,href:`/issues/${encodeURIComponent(s)}`}}a(Tn,"parseIssueReferenceFromHref");function zi(e){let t=e,r="";for(;t.length>0;){const n=t.at(-1);if(!n||!/[),.;!?:\]]/.test(n))break;if(n===")"){const o=(t.match(/\(/g)??[]).length;if((t.match(/\)/g)??[]).length<=o)break}if(n==="]"){const o=(t.match(/\[/g)??[]).length;if((t.match(/\]/g)??[]).length<=o)break}r=`${n}${r}`,t=t.slice(0,-1)}return{core:t,trailing:r}}a(zi,"splitTrailingPunctuation");function Pn(e,t,r="text"){return{type:"link",url:t,children:[{type:r,value:e}]}}a(Pn,"createIssueLinkNode");function Fi(e,t){const r=[];let n=0,o=!1;for(const s of e.matchAll(Ui)){const l=s[0];if(!l)continue;const u=s.index??0,c=u+l.length,{core:d,trailing:f}=zi(l),m=Tn(d,t);m&&(o=!0,u>n&&r.push({type:"text",value:e.slice(n,u)}),r.push(Pn(d,m.href)),f&&r.push({type:"text",value:f}),n=c)}return o?(n<e.length&&r.push({type:"text",value:e.slice(n)}),r):null}a(Fi,"linkifyIssueReferencesInText");function Ln(e,t){if(!Array.isArray(e.children)||e.children.length===0||e.type==="link"||e.type==="linkReference"||e.type==="code"||e.type==="definition"||e.type==="html")return;const r=[];for(const n of e.children){if(n.type==="inlineCode"&&typeof n.value=="string"){const o=Tn(n.value,t);if(o){r.push(Pn(n.value,o.href,"inlineCode"));continue}}if(n.type==="text"&&typeof n.value=="string"){const o=Fi(n.value,t);if(o){r.push(...o);continue}}Ln(n,t),r.push(n)}e.children=r}a(Ln,"rewriteMarkdownTree");function vu(e){const t=e?.knownPrefixes&&e.knownPrefixes.length>0?new Set(e.knownPrefixes.map(r=>r.toUpperCase())):void 0;return r=>{Ln(r,t)}}a(vu,"remarkLinkIssueReferences");function De(e,t){if(typeof e=="string")return Lt(e,t);if(e.pathname&&e.pathname.startsWith("/")){const r=Lt(e.pathname,t);if(r!==e.pathname)return{...e,pathname:r}}return e}a(De,"resolveTo");function he(){const{selectedCompany:e}=Jn(),t=Ka(),r=P();if(t.companyPrefix)return ue(t.companyPrefix);const n=Dn(r.pathname);return n||(e?ue(e.issuePrefix):null)}a(he,"useActiveCompanyPrefix");function ku(){const e=he();return i.useCallback((...t)=>Ni(e,...t),[e])}a(ku,"useCaseHref");var xu=i.forwardRef(a(function({to:t,disableIssueQuicklook:r=!1,issuePrefetch:n=null,issueQuicklookSide:o,issueQuicklookAlign:s,...l},u){const c=De(t,he()),d=Mn(typeof c=="string"?c:c.pathname);return d?(0,S.jsx)(Li,{ref:u,to:c,issuePathId:d,disableIssueQuicklook:r,issuePrefetch:n,issueQuicklookSide:o,issueQuicklookAlign:s,...l}):(0,S.jsx)(me,{ref:u,to:c,...l})},"CompanyLink")),wu=i.forwardRef(a(function({to:t,...r},n){const o=he();return(0,S.jsx)(dr,{ref:n,to:De(t,o),...r})},"CompanyNavLink"));function Su({to:e,...t}){const r=he();return(0,S.jsx)(lo,{to:De(e,r),...t})}a(Su,"Navigate");function Iu(){const e=Ee(),t=he();return i.useCallback(((r,n)=>{if(typeof r=="number"){e(r);return}e(De(r,t),n)}),[e,t])}a(Iu,"useNavigate");var Ot=a(e=>typeof e=="boolean"?`${e}`:e===0?"0":e,"falsyToString"),jt=Xn,qi=a((e,t)=>r=>{var n;if(t?.variants==null)return jt(e,r?.class,r?.className);const{variants:o,defaultVariants:s}=t,l=Object.keys(o).map(d=>{const f=r?.[d],m=s?.[d];if(f===null)return null;const g=Ot(f)||Ot(m);return o[d][g]}),u=r&&Object.entries(r).reduce((d,f)=>{let[m,g]=f;return g===void 0||(d[m]=g),d},{}),c=t==null||(n=t.compoundVariants)===null||n===void 0?void 0:n.reduce((d,f)=>{let{class:m,className:g,...v}=f;return Object.entries(v).every(b=>{let[y,h]=b;return Array.isArray(h)?h.includes({...s,...u}[y]):{...s,...u}[y]===h})?[...d,m,g]:d},[]);return jt(e,l,c,r?.class,r?.className)},"cva"),Hi=qi("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md border text-(length:--t-13) font-medium transition-(--tp-color-background-color-border-color-box-shadow-opacity) outline-hidden focus-visible:outline-solid focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-focus disabled:pointer-events-none disabled:border-line-strong disabled:bg-bg-3 disabled:text-ink-3 aria-busy:cursor-progress data-[active=true]:border-accent data-[active=true]:bg-accent-soft data-[active=true]:text-accent [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-4 shrink-0 [&_svg]:shrink-0 aria-invalid:border-bad",{variants:{variant:{primary:"border-transparent bg-accent text-accent-ink hover:bg-accent-hover active:bg-accent-press",secondary:"border-line-strong bg-bg-2 text-ink hover:bg-bg-3 active:bg-line-soft",ghost:"border-transparent bg-transparent text-ink-2 hover:bg-bg-3 hover:text-ink active:bg-line-soft disabled:border-transparent disabled:bg-transparent data-[active=true]:border-transparent data-[state=open]:bg-bg-3 data-[state=open]:text-ink",danger:"border-line-strong bg-bg-2 text-bad hover:bg-bg-3 active:bg-line-soft",delete:"border-transparent bg-bad text-accent-ink hover:bg-bad-hover active:bg-bad-hover",link:"border-transparent bg-transparent text-accent underline underline-offset-4 hover:text-accent-hover active:text-accent-press disabled:border-transparent disabled:bg-transparent"},size:{default:"h-10 px-4 py-2 has-[>svg]:px-3",xs:"h-6 gap-1 rounded-md px-2 text-xs has-[>svg]:px-1.5 [&_svg:not([class*='size-'])]:size-3",sm:"h-9 rounded-md gap-1.5 px-3 has-[>svg]:px-2.5",lg:"h-10 rounded-md px-6 has-[>svg]:px-4",icon:"size-10","icon-xs":"size-6 rounded-md [&_svg:not([class*='size-'])]:size-3","icon-sm":"size-9","icon-lg":"size-10"}},defaultVariants:{variant:"primary",size:"default"}}),Wi=i.forwardRef(a(function({className:t,variant:r="primary",size:n="default",asChild:o=!1,loading:s=!1,active:l,children:u,onClick:c,...d},f){const m=o?Fn:"button",g=s?v=>v.preventDefault():c;return(0,S.jsx)(m,{ref:f,"data-slot":"button","data-variant":r,"data-size":n,"data-active":l||void 0,"aria-busy":s||void 0,"aria-disabled":s||void 0,className:V(Hi({variant:r,size:n,className:t})),onClick:g,...d,children:s&&!o?(0,S.jsxs)(S.Fragment,{children:[(0,S.jsx)(Xs,{"aria-hidden":"true",className:"animate-spin"}),u]}):u})},"Button"));Wi.displayName="Button";var Vi={info:4e3,success:3500,warn:8e3,error:1e4},Ki=1500,Qi=15e3,Ji=5,Gi=3500,Yi=2e4,rt=(0,i.createContext)(null),nt=(0,i.createContext)(null);function Xi(e,t){const r=Vi[t];return typeof e!="number"||!Number.isFinite(e)?r:Math.max(Ki,Math.min(Qi,Math.floor(e)))}a(Xi,"normalizeTtl");function Zi(){return`toast_${Date.now()}_${Math.random().toString(36).slice(2,8)}`}a(Zi,"generateToastId");function Eu({children:e}){const[t,r]=(0,i.useState)([]),n=(0,i.useRef)(new Map),o=(0,i.useRef)(new Map),s=(0,i.useCallback)(f=>{const m=n.current.get(f);m!==void 0&&(window.clearTimeout(m),n.current.delete(f))},[]),l=(0,i.useCallback)(f=>{s(f),r(m=>m.filter(g=>g.id!==f))},[s]),u=(0,i.useCallback)(()=>{for(const f of n.current.values())window.clearTimeout(f);n.current.clear(),r([])},[]),c=(0,i.useCallback)(f=>{const m=Date.now(),g=f.tone??"info",v=Xi(f.ttlMs,g),b=f.dedupeKey??f.id??`${g}|${f.title}|${f.body??""}|${f.action?.href??""}`;for(const[k,w]of o.current.entries())m-w>Yi&&o.current.delete(k);const y=o.current.get(b);if(y&&m-y<Gi)return null;o.current.set(b,m);const h=f.id??Zi();if(s(h),r(k=>[{id:h,title:f.title,body:f.body,tone:g,ttlMs:v,persistent:f.persistent,action:f.action,actor:f.actor,createdAt:m},...k.filter(w=>w.id!==h)].slice(0,Ji)),!f.persistent){const k=window.setTimeout(()=>{l(h)},v);n.current.set(h,k)}return h},[s,l]);(0,i.useEffect)(()=>()=>{for(const f of n.current.values())window.clearTimeout(f);n.current.clear()},[]);const d=(0,i.useMemo)(()=>({pushToast:c,dismissToast:l,clearToasts:u}),[c,l,u]);return(0,S.jsx)(nt.Provider,{value:d,children:(0,S.jsx)(rt.Provider,{value:t,children:e})})}a(Eu,"ToastProvider");function el(){const e=(0,i.useContext)(rt);if(!e)throw new Error("useToastState must be used within a ToastProvider");return e}a(el,"useToastState");function tl(){const e=(0,i.useContext)(nt);if(!e)throw new Error("useToastActions must be used within a ToastProvider");return e}a(tl,"useToastActions");function Ru(){return(0,i.useContext)(nt)}a(Ru,"useOptionalToastActions");function Cu(){return(0,i.useContext)(rt)}a(Cu,"useOptionalToastState");function $u(){const e=el(),t=tl();return(0,i.useMemo)(()=>({toasts:e,...t}),[e,t])}a($u,"useToast");var On=(0,i.createContext)(null);function rl(e,t){if(e===t)return!0;if(e.length!==t.length)return!1;for(let r=0;r<e.length;r+=1)if(e[r]?.label!==t[r]?.label||e[r]?.onClick!==t[r]?.onClick||e[r]?.href!==t[r]?.href||e[r]?.identifier!==t[r]?.identifier||e[r]?.leadingKey!==t[r]?.leadingKey||e[r]?.trailingKey!==t[r]?.trailingKey)return!1;return!0}a(rl,"breadcrumbsEqual");function nl(e,t){const r=e.length===0?[]:[...e].reverse().map(o=>o.label),n=t?.trim()?[t.trim()]:[];return[...r,...n,"Wardmote"].join(" • ")}a(nl,"buildDocumentTitle");function _u({children:e,companyName:t}){const[r,n]=(0,i.useState)([]),[o,s]=(0,i.useState)(null),[l,u]=(0,i.useState)(null),[c,d]=(0,i.useState)(null),f=(0,i.useCallback)(b=>{n(y=>rl(y,b)?y:b)},[]),m=(0,i.useCallback)(b=>{d(b)},[]),g=(0,i.useCallback)(b=>{s(b)},[]),v=(0,i.useCallback)(b=>{u(b)},[]);return(0,i.useEffect)(()=>{document.title=nl(r,t)},[r,t]),(0,S.jsx)(On.Provider,{value:{breadcrumbs:r,setBreadcrumbs:f,breadcrumbToolbar:o,setBreadcrumbToolbar:g,breadcrumbPanelControl:l,setBreadcrumbPanelControl:v,mobileToolbar:c,setMobileToolbar:m},children:e})}a(_u,"BreadcrumbProvider");function Du(){const e=(0,i.useContext)(On);if(!e)throw new Error("useBreadcrumbs must be used within BreadcrumbProvider");return e}a(Du,"useBreadcrumbs");async function Au(){if(typeof navigator>"u"||!navigator.clipboard?.read)return null;try{return await navigator.clipboard.read()}catch{return null}}a(Au,"readClipboardItems");async function Mu(){if(typeof navigator>"u"||!navigator.clipboard?.readText)return"";try{return await navigator.clipboard.readText()}catch{return""}}a(Mu,"readTextFromClipboard");async function Tu(e){if((typeof window>"u"||window.isSecureContext!==!1)&&typeof navigator<"u"&&navigator.clipboard?.writeText)try{await navigator.clipboard.writeText(e);return}catch{}if(typeof document>"u")throw new Error("Clipboard unavailable");const t=document.createElement("textarea");t.value=e,t.setAttribute("aria-hidden","true"),t.tabIndex=-1,t.style.position="fixed",t.style.top="0",t.style.left="-9999px",(document.activeElement?.closest('[role="dialog"]')??document.querySelector('dialog[open], [role="dialog"][data-state="open"]')??document.body).appendChild(t);const r=document.activeElement;try{if(t.focus({preventScroll:!0}),t.select(),t.setSelectionRange(0,e.length),!document.execCommand("copy"))throw new Error("execCommand copy failed")}finally{t.remove(),r!==document.activeElement&&typeof r?.focus=="function"&&r.focus({preventScroll:!0})}}a(Tu,"copyTextToClipboard");export{ru as $,vl as $n,ql as $t,_i as A,fs as An,qs as At,ye as B,pr as Bn,At as Bt,Lt as C,St as Cn,Gs as Ct,bu as D,_l as Dn,Vs as Dt,ue as E,ds as En,Ks as Et,uu as F,rs as Fn,Ns as Ft,hu as G,ml as Gn,Kl as Gt,pu as H,es as Hn,Ps as Ht,cu as I,wl as In,Ql as It,Xl as J,kl as Jn,Ds as Jt,Gl as K,uo as Kn,Vl as Kt,ou as L,Ze as Ln,js as Lt,Ii as M,wr as Mn,zs as Mt,Mt as N,Il as Nn,Us as Nt,Li as O,Dl as On,Ws as Ot,ki as P,ts as Pn,Bs as Pt,fu as Q,Ka as Qn,Is as Qt,su as R,El as Rn,Os as Rt,vu as S,Y as Sn,Ys as St,ji as T,Rl as Tn,Qs as Tt,gu as U,bl as Un,Ur as Ut,yu as V,xl as Vn,Dt as Vt,mu as W,me as Wn,Ts as Wt,nu as X,Ee as Xn,$s as Xt,Zl as Y,P as Yn,_s as Yt,du as Z,dl as Zn,Cs as Zt,Su as _,Pl as _n,ri as _t,Du as a,ks as an,mi as at,Iu as b,Ll as bn,Zs as bt,Cu as c,Bl as cn,ci as ct,el as d,Al as dn,ii as dt,Rs as en,eu as et,Wi as f,Ol as fn,si as ft,wu as g,gs as gn,Jl as gt,xu as h,jl as hn,ni as ht,_u as i,Cr as in,hi as it,Di as j,$l as jn,Fs as jt,Pi as k,ss as kn,Hs as kt,$u as l,ps as ln,ui as lt,qi as m,Ml as mn,ai as mt,Au as n,Hl as nn,iu as nt,Eu as o,Ss as on,fi as ot,Hi as p,hs as pn,oi as pt,Yl as q,hl as qn,Ms as qt,Mu as r,Es as rn,lu as rt,Ru as s,Tl as sn,di as st,Tu as t,Wl as tn,tu as tt,tl as u,Ul as un,li as ut,he as v,Fl as vn,ti as vt,Dn as w,Cl as wn,Js as wt,Tn as x,zl as xn,Xs as xt,ku as y,Nl as yn,ei as yt,au as z,Sl as zn,Ls as zt};
|