1const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/NcLanding-DmmPSCay.js","assets/NcClaim-BgZ2IORl.js","assets/NcClaim-TTbVx_ot.css","assets/api-6KvJDcPk.js","assets/mode-DmtHTGIO.js","assets/connectors-CBCAxsnH.js","assets/NcLanding-C12Q_WAZ.css","assets/NcApp-C0NDJ1do.js","assets/record-CNvGJ-nj.js","assets/derive-bv_Ti8c2.js","assets/record-Czs7ARK-.css","assets/ncAuth-CFo234S5.js","assets/NcApp-smO6zVGe.css","assets/NcProfile-D6gGc6j7.js","assets/NcProfile-DtnSJVMj.css","assets/NcAdmin-K4DPP3x5.js","assets/NcAdmin-KklYXdA9.css","assets/NcLegal-D6WvNLwu.js","assets/NcLegal-CMvkJDq_.css","assets/NcDemo-CncGyNBs.js","assets/NcDemo-CRAfXj2K.css"])))=>i.map(i=>d[i]); 2var e=Object.create,t=Object.defineProperty,n=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,o=(e,t)=>()=>(t||(e((t={exports:{}}).exports,t),e=null),t.exports),s=(e,i,o,s)=>{if(i&&typeof i==`object`||typeof i==`function`)for(var c=r(i),l=0,u=c.length,d;l<u;l++)d=c[l],!a.call(e,d)&&d!==o&&t(e,d,{get:(e=>i[e]).bind(null,d),enumerable:!(s=n(i,d))||s.enumerable});return e},c=(n,r,a)=>(a=n==null?{}:e(i(n)),s(r||!n||!n.__esModule?t(a,`default`,{value:n,enumerable:!0}):a,n));(function(){let e=document.createElement(`link`).relList;if(e&&e.supports&&e.supports(`modulepreload`))return;for(let e of document.querySelectorAll(`link[rel="modulepreload"]`))n(e);new MutationObserver(e=>{for(let t of e)if(t.type===`childList`)for(let e of t.addedNodes)e.tagName===`LINK`&&e.rel===`modulepreload`&&n(e)}).observe(document,{childList:!0,subtree:!0});function t(e){let t={};return e.integrity&&(t.integrity=e.integrity),e.referrerPolicy&&(t.referrerPolicy=e.referrerPolicy),e.crossOrigin===`use-credentials`?t.credentials=`include`:e.crossOrigin===`anonymous`?t.credentials=`omit`:t.credentials=`same-origin`,t}function n(e){if(e.ep)return;e.ep=!0;let n=t(e);fetch(e.href,n)}})();var l=o((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.portal`),r=Symbol.for(`react.fragment`),i=Symbol.for(`react.strict_mode`),a=Symbol.for(`react.profiler`),o=Symbol.for(`react.consumer`),s=Symbol.for(`react.context`),c=Symbol.for(`react.forward_ref`),l=Symbol.for(`react.suspense`),u=Symbol.for(`react.memo`),d=Symbol.for(`react.lazy`),f=Symbol.for(`react.activity`),p=Symbol.iterator;function m(e){return typeof e!=`object`||!e?null:(e=p&&e[p]||e[`@@iterator`],typeof e==`function`?e:null)}var h={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},g=Object.assign,_={};function v(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}v.prototype.isReactComponent={},v.prototype.setState=function(e,t){if(typeof e!=`object`&&typeof e!=`function`&&e!=null)throw Error(`takes an object of state variables to update or a function which returns an object of state variables.`);this.updater.enqueueSetState(this,e,t,`setState`)},v.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,`forceUpdate`)};function y(){}y.prototype=v.prototype;function b(e,t,n){this.props=e,this.context=t,this.refs=_,this.updater=n||h}var x=b.prototype=new y;x.constructor=b,g(x,v.prototype),x.isPureReactComponent=!0;var S=Array.isArray;function C(){}var w={H:null,A:null,T:null,S:null},T=Object.prototype.hasOwnProperty;function E(e,n,r){var i=r.ref;return{$$typeof:t,type:e,key:n,ref:i===void 0?null:i,props:r}}function D(e,t){return E(e.type,t,e.props)}function O(e){return typeof e==`object`&&!!e&&e.$$typeof===t}function k(e){var t={"=":`=0`,":":`=2`};return`$`+e.replace(/[=:]/g,function(e){return t[e]})}var A=/\/+/g;function j(e,t){return typeof e==`object`&&e&&e.key!=null?k(``+e.key):t.toString(36)}function ee(e){switch(e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason;default:switch(typeof e.status==`string`?e.then(C,C):(e.status=`pending`,e.then(function(t){e.status===`pending`&&(e.status=`fulfilled`,e.value=t)},function(t){e.status===`pending`&&(e.status=`rejected`,e.reason=t)})),e.status){case`fulfilled`:return e.value;case`rejected`:throw e.reason}}throw e}function te(e,r,i,a,o){var s=typeof e;(s===`undefined`||s===`boolean`)&&(e=null);var c=!1;if(e===null)c=!0;else switch(s){case`bigint`:case`string`:case`number`:c=!0;break;case`object`:switch(e.$$typeof){case t:case n:c=!0;break;case d:return c=e._init,te(c(e._payload),r,i,a,o)}}if(c)return o=o(e),c=a===``?`.`+j(e,0):a,S(o)?(i=``,c!=null&&(i=c.replace(A,`$&/`)+`/`),te(o,r,i,``,function(e){return e})):o!=null&&(O(o)&&(o=D(o,i+(o.key==null||e&&e.key===o.key?``:(``+o.key).replace(A,`$&/`)+`/`)+c)),r.push(o)),1;c=0;var l=a===``?`.`:a+`:`;if(S(e))for(var u=0;u<e.length;u++)a=e[u],s=l+j(a,u),c+=te(a,r,i,s,o);else if(u=m(e),typeof u==`function`)for(e=u.call(e),u=0;!(a=e.next()).done;)a=a.value,s=l+j(a,u++),c+=te(a,r,i,s,o);else if(s===`object`){if(typeof e.then==`function`)return te(ee(e),r,i,a,o);throw r=String(e),Error(`Objects are not valid as a React child (found: `+(r===`[object Object]`?`object with keys {`+Object.keys(e).join(`, `)+`}`:r)+`). If you meant to render a collection of children, use an array instead.`)}return c}function ne(e,t,n){if(e==null)return e;var r=[],i=0;return te(e,r,``,``,function(e){return t.call(n,e,i++)}),r}function re(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(t){(e._status===0||e._status===-1)&&(e._status=1,e._result=t)},function(t){(e._status===0||e._status===-1)&&(e._status=2,e._result=t)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var M=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)},N={map:ne,forEach:function(e,t,n){ne(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return ne(e,function(){t++}),t},toArray:function(e){return ne(e,function(e){return e})||[]},only:function(e){if(!O(e))throw Error(`React.Children.only expected to receive a single React element child.`);return e}};e.Activity=f,e.Children=N,e.Component=v,e.Fragment=r,e.Profiler=a,e.PureComponent=b,e.StrictMode=i,e.Suspense=l,e.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=w,e.__COMPILER_RUNTIME={__proto__:null,c:function(e){return w.H.useMemoCache(e)}},e.cache=function(e){return function(){return e.apply(null,arguments)}},e.cacheSignal=function(){return null},e.cloneElement=function(e,t,n){if(e==null)throw Error(`The argument must be a React element, but you passed `+e+`.`);var r=g({},e.props),i=e.key;if(t!=null)for(a in t.key!==void 0&&(i=``+t.key),t)!T.call(t,a)||a===`key`||a===`__self`||a===`__source`||a===`ref`&&t.ref===void 0||(r[a]=t[a]);var a=arguments.length-2;if(a===1)r.children=n;else if(1<a){for(var o=Array(a),s=0;s<a;s++)o[s]=arguments[s+2];r.children=o}return E(e.type,i,r)},e.createContext=function(e){return e={$$typeof:s,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null},e.Provider=e,e.Consumer={$$typeof:o,_context:e},e},e.createElement=function(e,t,n){var r,i={},a=null;if(t!=null)for(r in t.key!==void 0&&(a=``+t.key),t)T.call(t,r)&&r!==`key`&&r!==`__self`&&r!==`__source`&&(i[r]=t[r]);var o=arguments.length-2;if(o===1)i.children=n;else if(1<o){for(var s=Array(o),c=0;c<o;c++)s[c]=arguments[c+2];i.children=s}if(e&&e.defaultProps)for(r in o=e.defaultProps,o)i[r]===void 0&&(i[r]=o[r]);return E(e,a,i)},e.createRef=function(){return{current:null}},e.forwardRef=function(e){return{$$typeof:c,render:e}},e.isValidElement=O,e.lazy=function(e){return{$$typeof:d,_payload:{_status:-1,_result:e},_init:re}},e.memo=function(e,t){return{$$typeof:u,type:e,compare:t===void 0?null:t}},e.startTransition=function(e){var t=w.T,n={};w.T=n;try{var r=e(),i=w.S;i!==null&&i(n,r),typeof r==`object`&&r&&typeof r.then==`function`&&r.then(C,M)}catch(e){M(e)}finally{t!==null&&n.types!==null&&(t.types=n.types),w.T=t}},e.unstable_useCacheRefresh=function(){return w.H.useCacheRefresh()},e.use=function(e){return w.H.use(e)},e.useActionState=function(e,t,n){return w.H.useActionState(e,t,n)},e.useCallback=function(e,t){return w.H.useCallback(e,t)},e.useContext=function(e){return w.H.useContext(e)},e.useDebugValue=function(){},e.useDeferredValue=function(e,t){return w.H.useDeferredValue(e,t)},e.useEffect=function(e,t){return w.H.useEffect(e,t)},e.useEffectEvent=function(e){return w.H.useEffectEvent(e)},e.useId=function(){return w.H.useId()},e.useImperativeHandle=function(e,t,n){return w.H.useImperativeHandle(e,t,n)},e.useInsertionEffect=function(e,t){return w.H.useInsertionEffect(e,t)},e.useLayoutEffect=function(e,t){return w.H.useLayoutEffect(e,t)},e.useMemo=function(e,t){return w.H.useMemo(e,t)},e.useOptimistic=function(e,t){return w.H.useOptimistic(e,t)},e.useReducer=function(e,t,n){return w.H.useReducer(e,t,n)},e.useRef=function(e){return w.H.useRef(e)},e.useState=function(e){return w.H.useState(e)},e.useSyncExternalStore=function(e,t,n){return w.H.useSyncExternalStore(e,t,n)},e.useTransition=function(){return w.H.useTransition()}
2,e.version=`19.2.7`})),u=o(((e,t)=>{t.exports=l()})),d=o((e=>{function t(e,t){var n=e.length;e.push(t);a:for(;0<n;){var r=n-1>>>1,a=e[r];if(0<i(a,t))e[r]=t,e[n]=a,n=r;else break a}}function n(e){return e.length===0?null:e[0]}function r(e){if(e.length===0)return null;var t=e[0],n=e.pop();if(n!==t){e[0]=n;a:for(var r=0,a=e.length,o=a>>>1;r<o;){var s=2*(r+1)-1,c=e[s],l=s+1,u=e[l];if(0>i(c,n))l<a&&0>i(u,c)?(e[r]=u,e[l]=n,r=l):(e[r]=c,e[s]=n,r=s);else if(l<a&&0>i(u,n))e[r]=u,e[l]=n,r=l;else break a}}return t}function i(e,t){var n=e.sortIndex-t.sortIndex;return n===0?e.id-t.id:n}if(e.unstable_now=void 0,typeof performance==`object`&&typeof performance.now==`function`){var a=performance;e.unstable_now=function(){return a.now()}}else{var o=Date,s=o.now();e.unstable_now=function(){return o.now()-s}}var c=[],l=[],u=1,d=null,f=3,p=!1,m=!1,h=!1,g=!1,_=typeof setTimeout==`function`?setTimeout:null,v=typeof clearTimeout==`function`?clearTimeout:null,y=typeof setImmediate<`u`?setImmediate:null;function b(e){for(var i=n(l);i!==null;){if(i.callback===null)r(l);else if(i.startTime<=e)r(l),i.sortIndex=i.expirationTime,t(c,i);else break;i=n(l)}}function x(e){if(h=!1,b(e),!m)if(n(c)!==null)m=!0,S||(S=!0,O());else{var t=n(l);t!==null&&j(x,t.startTime-e)}}var S=!1,C=-1,w=5,T=-1;function E(){return g?!0:!(e.unstable_now()-T<w)}function D(){if(g=!1,S){var t=e.unstable_now();T=t;var i=!0;try{a:{m=!1,h&&(h=!1,v(C),C=-1),p=!0;var a=f;try{b:{for(b(t),d=n(c);d!==null&&!(d.expirationTime>t&&E());){var o=d.callback;if(typeof o==`function`){d.callback=null,f=d.priorityLevel;var s=o(d.expirationTime<=t);if(t=e.unstable_now(),typeof s==`function`){d.callback=s,b(t),i=!0;break b}d===n(c)&&r(c),b(t)}else r(c);d=n(c)}if(d!==null)i=!0;else{var u=n(l);u!==null&&j(x,u.startTime-t),i=!1}}break a}finally{d=null,f=a,p=!1}i=void 0}}finally{i?O():S=!1}}}var O;if(typeof y==`function`)O=function(){y(D)};else if(typeof MessageChannel<`u`){var k=new MessageChannel,A=k.port2;k.port1.onmessage=D,O=function(){A.postMessage(null)}}else O=function(){_(D,0)};function j(t,n){C=_(function(){t(e.unstable_now())},n)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(e){e.callback=null},e.unstable_forceFrameRate=function(e){0>e||125<e?console.error(`forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported`):w=0<e?Math.floor(1e3/e):5},e.unstable_getCurrentPriorityLevel=function(){return f},e.unstable_next=function(e){switch(f){case 1:case 2:case 3:var t=3;break;default:t=f}var n=f;f=t;try{return e()}finally{f=n}},e.unstable_requestPaint=function(){g=!0},e.unstable_runWithPriority=function(e,t){switch(e){case 1:case 2:case 3:case 4:case 5:break;default:e=3}var n=f;f=e;try{return t()}finally{f=n}},e.unstable_scheduleCallback=function(r,i,a){var o=e.unstable_now();switch(typeof a==`object`&&a?(a=a.delay,a=typeof a==`number`&&0<a?o+a:o):a=o,r){case 1:var s=-1;break;case 2:s=250;break;case 5:s=1073741823;break;case 4:s=1e4;break;default:s=5e3}return s=a+s,r={id:u++,callback:i,priorityLevel:r,startTime:a,expirationTime:s,sortIndex:-1},a>o?(r.sortIndex=a,t(l,r),n(c)===null&&r===n(l)&&(h?(v(C),C=-1):h=!0,j(x,a-o))):(r.sortIndex=s,t(c,r),m||p||(m=!0,S||(S=!0,O()))),r},e.unstable_shouldYield=E,e.unstable_wrapCallback=function(e){var t=f;return function(){var n=f;f=t;try{return e.apply(this,arguments)}finally{f=n}}}})),f=o(((e,t)=>{t.exports=d()})),p=o((e=>{var t=u();function n(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function r(){}var i={d:{f:r,r:function(){throw Error(n(522))},D:r,C:r,L:r,m:r,X:r,S:r,M:r},p:0,findDOMNode:null},a=Symbol.for(`react.portal`);function o(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:a,key:r==null?null:``+r,children:e,containerInfo:t,implementation:n}}var s=t.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE;function c(e,t){if(e===`font`)return``;if(typeof t==`string`)return t===`use-credentials`?t:``}e.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE=i,e.createPortal=function(e,t){var r=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!t||t.nodeType!==1&&t.nodeType!==9&&t.nodeType!==11)throw Error(n(299));return o(e,t,null,r)},e.flushSync=function(e){var t=s.T,n=i.p;try{if(s.T=null,i.p=2,e)return e()}finally{s.T=t,i.p=n,i.d.f()}},e.preconnect=function(e,t){typeof e==`string`&&(t?(t=t.crossOrigin,t=typeof t==`string`?t===`use-credentials`?t:``:void 0):t=null,i.d.C(e,t))},e.prefetchDNS=function(e){typeof e==`string`&&i.d.D(e)},e.preinit=function(e,t){if(typeof e==`string`&&t&&typeof t.as==`string`){var n=t.as,r=c(n,t.crossOrigin),a=typeof t.integrity==`string`?t.integrity:void 0,o=typeof t.fetchPriority==`string`?t.fetchPriority:void 0;n===`style`?i.d.S(e,typeof t.precedence==`string`?t.precedence:void 0,{crossOrigin:r,integrity:a,fetchPriority:o}):n===`script`&&i.d.X(e,{crossOrigin:r,integrity:a,fetchPriority:o,nonce:typeof t.nonce==`string`?t.nonce:void 0})}},e.preinitModule=function(e,t){if(typeof e==`string`)if(typeof t==`object`&&t){if(t.as==null||t.as===`script`){var n=c(t.as,t.crossOrigin);i.d.M(e,{crossOrigin:n,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0})}}else t??i.d.M(e)},e.preload=function(e,t){if(typeof e==`string`&&typeof t==`object`&&t&&typeof t.as==`string`){var n=t.as,r=c(n,t.crossOrigin);i.d.L(e,n,{crossOrigin:r,integrity:typeof t.integrity==`string`?t.integrity:void 0,nonce:typeof t.nonce==`string`?t.nonce:void 0,type:typeof t.type==`string`?t.type:void 0,fetchPriority:typeof t.fetchPriority==`string`?t.fetchPriority:void 0,referrerPolicy:typeof t.referrerPolicy==`string`?t.referrerPolicy:void 0,imageSrcSet:typeof t.imageSrcSet==`string`?t.imageSrcSet:void 0,imageSizes:typeof t.imageSizes==`string`?t.imageSizes:void 0,media:typeof t.media==`string`?t.media:void 0})}},e.preloadModule=function(e,t){if(typeof e==`string`)if(t){var n=c(t.as,t.crossOrigin);i.d.m(e,{as:typeof t.as==`string`&&t.as!==`script`?t.as:void 0,crossOrigin:n,integrity:typeof t.integrity==`string`?t.integrity:void 0})}else i.d.m(e)},e.requestFormReset=function(e){i.d.r(e)},e.unstable_batchedUpdates=function(e,t){return e(t)},e.useFormState=function(e,t,n){return s.H.useFormState(e,t,n)},e.useFormStatus=function(){return s.H.useHostTransitionStatus()}
vendor: 11,608 bytes, lines 2-9
2,e.version=`19.2.7`})),m=o(((e,t)=>{function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>`u`||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=`function`))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=p()})),h=o((e=>{var t=f(),n=u(),r=m();function i(e){var t=`https://react.dev/errors/`+e;if(1<arguments.length){t+=`?args[]=`+encodeURIComponent(arguments[1]);for(var n=2;n<arguments.length;n++)t+=`&args[]=`+encodeURIComponent(arguments[n])}return`Minified React error #`+e+`; visit `+t+` for the full message or use the non-minified dev environment for full errors and additional helpful warnings.`}function a(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function o(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&4098&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function s(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function c(e){if(e.tag===31){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function l(e){if(o(e)!==e)throw Error(i(188))}function d(e){var t=e.alternate;if(!t){if(t=o(e),t===null)throw Error(i(188));return t===e?e:null}for(var n=e,r=t;;){var a=n.return;if(a===null)break;var s=a.alternate;if(s===null){if(r=a.return,r!==null){n=r;continue}break}if(a.child===s.child){for(s=a.child;s;){if(s===n)return l(a),e;if(s===r)return l(a),t;s=s.sibling}throw Error(i(188))}if(n.return!==r.return)n=a,r=s;else{for(var c=!1,u=a.child;u;){if(u===n){c=!0,n=a,r=s;break}if(u===r){c=!0,r=a,n=s;break}u=u.sibling}if(!c){for(u=s.child;u;){if(u===n){c=!0,n=s,r=a;break}if(u===r){c=!0,r=s,n=a;break}u=u.sibling}if(!c)throw Error(i(189))}}if(n.alternate!==r)throw Error(i(190))}if(n.tag!==3)throw Error(i(188));return n.stateNode.current===n?e:t}function p(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e;for(e=e.child;e!==null;){if(t=p(e),t!==null)return t;e=e.sibling}return null}var h=Object.assign,g=Symbol.for(`react.element`),_=Symbol.for(`react.transitional.element`),v=Symbol.for(`react.portal`),y=Symbol.for(`react.fragment`),b=Symbol.for(`react.strict_mode`),x=Symbol.for(`react.profiler`),S=Symbol.for(`react.consumer`),C=Symbol.for(`react.context`),w=Symbol.for(`react.forward_ref`),T=Symbol.for(`react.suspense`),E=Symbol.for(`react.suspense_list`),D=Symbol.for(`react.memo`),O=Symbol.for(`react.lazy`),k=Symbol.for(`react.activity`),A=Symbol.for(`react.memo_cache_sentinel`),j=Symbol.iterator;function ee(e){return typeof e!=`object`||!e?null:(e=j&&e[j]||e[`@@iterator`],typeof e==`function`?e:null)}var te=Symbol.for(`react.client.reference`);function ne(e){if(e==null)return null;if(typeof e==`function`)return e.$$typeof===te?null:e.displayName||e.name||null;if(typeof e==`string`)return e;switch(e){case y:return`Fragment`;case x:return`Profiler`;case b:return`StrictMode`;case T:return`Suspense`;case E:return`SuspenseList`;case k:return`Activity`}if(typeof e==`object`)switch(e.$$typeof){case v:return`Portal`;case C:return e.displayName||`Context`;case S:return(e._context.displayName||`Context`)+`.Consumer`;case w:var t=e.render;return e=e.displayName,e||=(e=t.displayName||t.name||``,e===``?`ForwardRef`:`ForwardRef(`+e+`)`),e;case D:return t=e.displayName||null,t===null?ne(e.type)||`Memo`:t;case O:t=e._payload,e=e._init;try{return ne(e(t))}catch{}}return null}var re=Array.isArray,M=n.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,N=r.__DOM_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE,ie={pending:!1,data:null,method:null,action:null},ae=[],P=-1;function oe(e){return{current:e}}function se(e){0>P||(e.current=ae[P],ae[P]=null,P--)}function ce(e,t){P++,ae[P]=e.current,e.current=t}var le=oe(null),ue=oe(null),de=oe(null),fe=oe(null);function pe(e,t){switch(ce(de,t),ce(ue,e),ce(le,null),t.nodeType){case 9:case 11:e=(e=t.documentElement)&&(e=e.namespaceURI)?$d(e):0;break;default:if(e=t.tagName,t=t.namespaceURI)t=$d(t),e=ef(t,e);else switch(e){case`svg`:e=1;break;case`math`:e=2;break;default:e=0}}se(le),ce(le,e)}function me(){se(le),se(ue),se(de)}function he(e){e.memoizedState!==null&&ce(fe,e);var t=le.current,n=ef(t,e.type);t!==n&&(ce(ue,e),ce(le,n))}function ge(e){ue.current===e&&(se(le),se(ue)),fe.current===e&&(se(fe),up._currentValue=ie)}var _e,ve;function ye(e){if(_e===void 0)try{throw Error()}catch(e){var t=e.stack.trim().match(/\n( *(at )?)/);_e=t&&t[1]||``,ve=-1<e.stack.indexOf(` 3 at`)?` (<anonymous>)`:-1<e.stack.indexOf(`@`)?`@unknown:0:0`:``}return` 4`+_e+e+ve}var be=!1;function xe(e,t){if(!e||be)return``;be=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{var r={DetermineComponentFrameRoot:function(){try{if(t){var n=function(){throw Error()};if(Object.defineProperty(n.prototype,"props",{set:function(){throw Error()}}),typeof Reflect==`object`&&Reflect.construct){try{Reflect.construct(n,[])}catch(e){var r=e}Reflect.construct(e,[],n)}else{try{n.call()}catch(e){r=e}e.call(n.prototype)}}else{try{throw Error()}catch(e){r=e}(n=e())&&typeof n.catch==`function`&&n.catch(function(){})}}catch(e){if(e&&r&&typeof e.stack==`string`)return[e.stack,r.stack]}return[null,null]}};r.DetermineComponentFrameRoot.displayName=`DetermineComponentFrameRoot`;var i=Object.getOwnPropertyDescriptor(r.DetermineComponentFrameRoot,`name`);i&&i.configurable&&Object.defineProperty(r.DetermineComponentFrameRoot,"name",{value:`DetermineComponentFrameRoot`});var a=r.DetermineComponentFrameRoot(),o=a[0],s=a[1];if(o&&s){var c=o.split(` 5`),l=s.split(` 6`);for(i=r=0;r<c.length&&!c[r].includes(`DetermineComponentFrameRoot`);)r++;for(;i<l.length&&!l[i].includes(`DetermineComponentFrameRoot`);)i++;if(r===c.length||i===l.length)for(r=c.length-1,i=l.length-1;1<=r&&0<=i&&c[r]!==l[i];)i--;for(;1<=r&&0<=i;r--,i--)if(c[r]!==l[i]){if(r!==1||i!==1)do if(r--,i--,0>i||c[r]!==l[i]){var u=` 7`+c[r].replace(` at new `,` at `);return e.displayName&&u.includes(`<anonymous>`)&&(u=u.replace(`<anonymous>`,e.displayName)),u}while(1<=r&&0<=i);break}}}finally{be=!1,Error.prepareStackTrace=n}return(n=e?e.displayName||e.name:``)?ye(n):``}function Se(e,t){switch(e.tag){case 26:case 27:case 5:return ye(e.type);case 16:return ye(`Lazy`);case 13:return e.child!==t&&t!==null?ye(`Suspense Fallback`):ye(`Suspense`);case 19:return ye(`SuspenseList`);case 0:case 15:return xe(e.type,!1);case 11:return xe(e.type.render,!1);case 1:return xe(e.type,!0);case 31:return ye(`Activity`);default:return``}}function Ce(e){try{var t=``,n=null;do t+=Se(e,n),n=e,e=e.return;while(e);return t}catch(e){return` 8Error generating stack: `+e.message+` 9`+e.stack}}var we=Object.prototype.hasOwnProperty,Te=t.unstable_scheduleCallback,Ee=t.unstable_cancelCallback,De=t.unstable_shouldYield,Oe=t.unstable_requestPaint,ke=t.unstable_now,Ae=t.unstable_getCurrentPriorityLevel,je=t.unstable_ImmediatePriority,Me=t.unstable_UserBlockingPriority,Ne=t.unstable_NormalPriority,Pe=t.unstable_LowPriority,Fe=t.unstable_IdlePriority,Ie=t.log,Le=t.unstable_setDisableYieldValue,Re=null,ze=null;function Be(e){if(typeof Ie==`function`&&Le(e),ze&&typeof ze.setStrictMode==`function`)try{ze.setStrictMode(Re,e)}catch{}}var Ve=Math.clz32?Math.clz32:We,He=Math.log,Ue=Math.LN2;function We(e){return e>>>=0,e===0?32:31-(He(e)/Ue|0)|0}var Ge=256,Ke=262144,qe=4194304;function Je(e){var t=e&42;if(t!==0)return t;switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:return 64;case 128:return 128;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:return e&261888;case 262144:case 524288:case 1048576:case 2097152:return e&3932160;case 4194304:case 8388608:case 16777216:case 33554432:return e&62914560;case 67108864:return 67108864;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 0;default:return e}}function Ye(e,t,n){var r=e.pendingLanes;if(r===0)return 0;var i=0,a=e.suspendedLanes,o=e.pingedLanes;e=e.warmLanes;var s=r&134217727;return s===0?(s=r&~a,s===0?o===0?n||(n=r&~e,n!==0&&(i=Je(n))):i=Je(o):i=Je(s)):(r=s&~a,r===0?(o&=s,o===0?n||(n=s&~e,n!==0&&(i=Je(n))):i=Je(o)):i=Je(r)),i===0?0:t!==0&&t!==i&&(t&a)===0&&(a=i&-i,n=t&-t,a>=n||a===32&&n&4194048)?t:i}function Xe(e,t){return(e.pendingLanes&~(e.suspendedLanes&~e.pingedLanes)&t)===0}function Ze(e,t){switch(e){case 1:case 2:case 4:case 8:case 64:return t+250;case 16:case 32:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:return-1;case 67108864:case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function Qe(){var e=qe;return qe<<=1,!(qe&62914560)&&(qe=4194304),e}function $e(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function et(e,t){e.pendingLanes|=t,t!==268435456&&(e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0)}function tt(e,t,n,r,i,a){var o=e.pendingLanes;e.pendingLanes=n,e.suspendedLanes=0,e.pingedLanes=0,e.warmLanes=0,e.expiredLanes&=n,e.entangledLanes&=n,e.errorRecoveryDisabledLanes&=n,e.shellSuspendCounter=0;var s=e.entanglements,c=e.expirationTimes,l=e.hiddenUpdates;for(n=o&~n;0<n;){var u=31-Ve(n),d=1<<u;s[u]=0,c[u]=-1;var f=l[u];if(f!==null)for(l[u]=null,u=0;u<f.length;u++){var p=f[u];p!==null&&(p.lane&=-536870913)}n&=~d}r!==0&&nt(e,r,0),a!==0&&i===0&&e.tag!==0&&(e.suspendedLanes|=a&~(o&~t))}function nt(e,t,n){e.pendingLanes|=t,e.suspendedLanes&=~t;var r=31-Ve(t);e.entangledLanes|=t,e.entanglements[r]=e.entanglements[r]|1073741824|n&261930}function rt(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-Ve(n),i=1<<r;i&t|e[r]&t&&(e[r]|=t),n&=~i}}function it(e,t){var n=t&-t;return n=n&42?1:at(n),(n&(e.suspendedLanes|t))===0?n:0}function at(e){switch(e){case 2:e=1;break;case 8:e=4;break;case 32:e=16;break;case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:e=128;break;case 268435456:e=134217728;break;default:e=0}return e}function ot(e){return e&=-e,2<e?8<e?e&134217727?32:268435456:8:2}function st(){var e=N.p;return e===0?(e=window.event,e===void 0?32:Ep(e.type)):e}function ct(e,t){var n=N.p;try{return N.p=e,t()}finally{N.p=n}}var lt=Math.random().toString(36).slice(2),ut=`__reactFiber$`+lt,dt=`__reactProps$`+lt,ft=`__reactContainer$`+lt,pt=`__reactEvents$`+lt,mt=`__reactListeners$`+lt,ht=`__reactHandles$`+lt,gt=`__reactResources$`+lt,_t=`__reactMarker$`+lt;function vt(e){delete e[ut],delete e[dt],delete e[pt],delete e[mt],delete e[ht]}function yt(e){var t=e[ut];if(t)return t;for(var n=e.parentNode;n;){if(t=n[ft]||n[ut]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=Cf(e);e!==null;){if(n=e[ut])return n;e=Cf(e)}return t}e=n,n=e.parentNode}return null}function bt(e){if(e=e[ut]||e[ft]){var t=e.tag;if(t===5||t===6||t===13||t===31||t===26||t===27||t===3)return e}return null}function xt(e){var t=e.tag;if(t===5||t===26||t===27||t===6)return e.stateNode;throw Error(i(33))}function St(e){var t=e[gt];return t||=e[gt]={hoistableStyles:new Map,hoistableScripts:new Map},t}function Ct(e){e[_t]=!0}var wt=new Set,Tt={};function Et(e,t){Dt(e,t),Dt(e+`Capture`,t)}function Dt(e,t){for(Tt[e]=t,e=0;e<t.length;e++)wt.add(t[e])}var Ot=RegExp(`^[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u
9037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD][:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$`),kt={},At={};function jt(e){return we.call(At,e)?!0:we.call(kt,e)?!1:Ot.test(e)?At[e]=!0:(kt[e]=!0,!1)}function Mt(e,t,n){if(jt(t))if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:e.removeAttribute(t);return;case`boolean`:var r=t.toLowerCase().slice(0,5);if(r!==`data-`&&r!==`aria-`){e.removeAttribute(t);return}}e.setAttribute(t,``+n)}}function Nt(e,t,n){if(n===null)e.removeAttribute(t);else{switch(typeof n){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(t);return}e.setAttribute(t,``+n)}}function Pt(e,t,n,r){if(r===null)e.removeAttribute(n);else{switch(typeof r){case`undefined`:case`function`:case`symbol`:case`boolean`:e.removeAttribute(n);return}e.setAttributeNS(t,n,``+r)}}function Ft(e){switch(typeof e){case`bigint`:case`boolean`:case`number`:case`string`:case`undefined`:return e;case`object`:return e;default:return``}}function It(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()===`input`&&(t===`checkbox`||t===`radio`)}function Lt(e,t,n){var r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t);if(!e.hasOwnProperty(t)&&r!==void 0&&typeof r.get==`function`&&typeof r.set==`function`){var i=r.get,a=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(e){n=``+e,a.call(this,e)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(e){n=``+e},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Rt(e){if(!e._valueTracker){var t=It(e)?`checked`:`value`;e._valueTracker=Lt(e,t,``+e[t])}}function zt(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r=``;return e&&(r=It(e)?e.checked?`true`:`false`:e.value),e=r,e===n?!1:(t.setValue(e),!0)}function Bt(e){if(e||=typeof document<`u`?document:void 0,e===void 0)return null;try{return e.activeElement||e.body}catch{return e.body}}var Vt=/[\n"\\]/g;function Ht(e){return e.replace(Vt,function(e){return`\\`+e.charCodeAt(0).toString(16)+` `})}function Ut(e,t,n,r,i,a,o,s){e.name=``,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`?e.type=o:e.removeAttribute(`type`),t==null?o!==`submit`&&o!==`reset`||e.removeAttribute(`value`):o===`number`?(t===0&&e.value===``||e.value!=t)&&(e.value=``+Ft(t)):e.value!==``+Ft(t)&&(e.value=``+Ft(t)),t==null?n==null?r!=null&&e.removeAttribute(`value`):Gt(e,o,Ft(n)):Gt(e,o,Ft(t)),i==null&&a!=null&&(e.defaultChecked=!!a),i!=null&&(e.checked=i&&typeof i!=`function`&&typeof i!=`symbol`),s!=null&&typeof s!=`function`&&typeof s!=`symbol`&&typeof s!=`boolean`?e.name=``+Ft(s):e.removeAttribute(`name`)}function Wt(e,t,n,r,i,a,o,s){if(a!=null&&typeof a!=`function`&&typeof a!=`symbol`&&typeof a!=`boolean`&&(e.type=a),t!=null||n!=null){if(!(a!==`submit`&&a!==`reset`||t!=null)){Rt(e);return}n=n==null?``:``+Ft(n),t=t==null?n:``+Ft(t),s||t===e.value||(e.value=t),e.defaultValue=t}r??=i,r=typeof r!=`function`&&typeof r!=`symbol`&&!!r,e.checked=s?e.checked:!!r,e.defaultChecked=!!r,o!=null&&typeof o!=`function`&&typeof o!=`symbol`&&typeof o!=`boolean`&&(e.name=o),Rt(e)}function Gt(e,t,n){t===`number`&&Bt(e.ownerDocument)===e||e.defaultValue===``+n||(e.defaultValue=``+n)}function Kt(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i<n.length;i++)t[`$`+n[i]]=!0;for(n=0;n<e.length;n++)i=t.hasOwnProperty(`$`+e[n].value),e[n].selected!==i&&(e[n].selected=i),i&&r&&(e[n].defaultSelected=!0)}else{for(n=``+Ft(n),t=null,i=0;i<e.length;i++){if(e[i].value===n){e[i].selected=!0,r&&(e[i].defaultSelected=!0);return}t!==null||e[i].disabled||(t=e[i])}t!==null&&(t.selected=!0)}}function qt(e,t,n){if(t!=null&&(t=``+Ft(t),t!==e.value&&(e.value=t),n==null)){e.defaultValue!==t&&(e.defaultValue=t);return}e.defaultValue=n==null?``:``+Ft(n)}function Jt(e,t,n,r){if(t==null){if(r!=null){if(n!=null)throw Error(i(92));if(re(r)){if(1<r.length)throw Error(i(93));r=r[0]}n=r}n??=``,t=n}
vendor: 87,510 bytes, line 9
9n=Ft(t),e.defaultValue=n,r=e.textContent,r===n&&r!==``&&r!==null&&(e.value=r),Rt(e)}function Yt(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Xt=new Set(`animationIterationCount aspectRatio borderImageOutset borderImageSlice borderImageWidth boxFlex boxFlexGroup boxOrdinalGroup columnCount columns flex flexGrow flexPositive flexShrink flexNegative flexOrder gridArea gridRow gridRowEnd gridRowSpan gridRowStart gridColumn gridColumnEnd gridColumnSpan gridColumnStart fontWeight lineClamp lineHeight opacity order orphans scale tabSize widows zIndex zoom fillOpacity floodOpacity stopOpacity strokeDasharray strokeDashoffset strokeMiterlimit strokeOpacity strokeWidth MozAnimationIterationCount MozBoxFlex MozBoxFlexGroup MozLineClamp msAnimationIterationCount msFlex msZoom msFlexGrow msFlexNegative msFlexOrder msFlexPositive msFlexShrink msGridColumn msGridColumnSpan msGridRow msGridRowSpan WebkitAnimationIterationCount WebkitBoxFlex WebKitBoxFlexGroup WebkitBoxOrdinalGroup WebkitColumnCount WebkitColumns WebkitFlex WebkitFlexGrow WebkitFlexPositive WebkitFlexShrink WebkitLineClamp`.split(` `));function Zt(e,t,n){var r=t.indexOf(`--`)===0;n==null||typeof n==`boolean`||n===``?r?e.setProperty(t,``):t===`float`?e.cssFloat=``:e[t]=``:r?e.setProperty(t,n):typeof n!=`number`||n===0||Xt.has(t)?t===`float`?e.cssFloat=n:e[t]=(``+n).trim():e[t]=n+`px`}function Qt(e,t,n){if(t!=null&&typeof t!=`object`)throw Error(i(62));if(e=e.style,n!=null){for(var r in n)!n.hasOwnProperty(r)||t!=null&&t.hasOwnProperty(r)||(r.indexOf(`--`)===0?e.setProperty(r,``):r===`float`?e.cssFloat=``:e[r]=``);for(var a in t)r=t[a],t.hasOwnProperty(a)&&n[a]!==r&&Zt(e,a,r)}else for(var o in t)t.hasOwnProperty(o)&&Zt(e,o,t[o])}function $t(e){if(e.indexOf(`-`)===-1)return!1;switch(e){case`annotation-xml`:case`color-profile`:case`font-face`:case`font-face-src`:case`font-face-uri`:case`font-face-format`:case`font-face-name`:case`missing-glyph`:return!1;default:return!0}}var en=new Map([[`acceptCharset`,`accept-charset`],[`htmlFor`,`for`],[`httpEquiv`,`http-equiv`],[`crossOrigin`,`crossorigin`],[`accentHeight`,`accent-height`],[`alignmentBaseline`,`alignment-baseline`],[`arabicForm`,`arabic-form`],[`baselineShift`,`baseline-shift`],[`capHeight`,`cap-height`],[`clipPath`,`clip-path`],[`clipRule`,`clip-rule`],[`colorInterpolation`,`color-interpolation`],[`colorInterpolationFilters`,`color-interpolation-filters`],[`colorProfile`,`color-profile`],[`colorRendering`,`color-rendering`],[`dominantBaseline`,`dominant-baseline`],[`enableBackground`,`enable-background`],[`fillOpacity`,`fill-opacity`],[`fillRule`,`fill-rule`],[`floodColor`,`flood-color`],[`floodOpacity`,`flood-opacity`],[`fontFamily`,`font-family`],[`fontSize`,`font-size`],[`fontSizeAdjust`,`font-size-adjust`],[`fontStretch`,`font-stretch`],[`fontStyle`,`font-style`],[`fontVariant`,`font-variant`],[`fontWeight`,`font-weight`],[`glyphName`,`glyph-name`],[`glyphOrientationHorizontal`,`glyph-orientation-horizontal`],[`glyphOrientationVertical`,`glyph-orientation-vertical`],[`horizAdvX`,`horiz-adv-x`],[`horizOriginX`,`horiz-origin-x`],[`imageRendering`,`image-rendering`],[`letterSpacing`,`letter-spacing`],[`lightingColor`,`lighting-color`],[`markerEnd`,`marker-end`],[`markerMid`,`marker-mid`],[`markerStart`,`marker-start`],[`overlinePosition`,`overline-position`],[`overlineThickness`,`overline-thickness`],[`paintOrder`,`paint-order`],[`panose-1`,`panose-1`],[`pointerEvents`,`pointer-events`],[`renderingIntent`,`rendering-intent`],[`shapeRendering`,`shape-rendering`],[`stopColor`,`stop-color`],[`stopOpacity`,`stop-opacity`],[`strikethroughPosition`,`strikethrough-position`],[`strikethroughThickness`,`strikethrough-thickness`],[`strokeDasharray`,`stroke-dasharray`],[`strokeDashoffset`,`stroke-dashoffset`],[`strokeLinecap`,`stroke-linecap`],[`strokeLinejoin`,`stroke-linejoin`],[`strokeMiterlimit`,`stroke-miterlimit`],[`strokeOpacity`,`stroke-opacity`],[`strokeWidth`,`stroke-width`],[`textAnchor`,`text-anchor`],[`textDecoration`,`text-decoration`],[`textRendering`,`text-rendering`],[`transformOrigin`,`transform-origin`],[`underlinePosition`,`underline-position`],[`underlineThickness`,`underline-thickness`],[`unicodeBidi`,`unicode-bidi`],[`unicodeRange`,`unicode-range`],[`unitsPerEm`,`units-per-em`],[`vAlphabetic`,`v-alphabetic`],[`vHanging`,`v-hanging`],[`vIdeographic`,`v-ideographic`],[`vMathematical`,`v-mathematical`],[`vectorEffect`,`vector-effect`],[`vertAdvY`,`vert-adv-y`],[`vertOriginX`,`vert-origin-x`],[`vertOriginY`,`vert-origin-y`],[`wordSpacing`,`word-spacing`],[`writingMode`,`writing-mode`],[`xmlnsXlink`,`xmlns:xlink`],[`xHeight`,`x-height`]]),tn=/^[\u0000-\u001F ]*j[\r\n\t]*a[\r\n\t]*v[\r\n\t]*a[\r\n\t]*s[\r\n\t]*c[\r\n\t]*r[\r\n\t]*i[\r\n\t]*p[\r\n\t]*t[\r\n\t]*:/i;function nn(e){return tn.test(``+e)?`javascript:throw new Error('React has blocked a javascript: URL as a security precaution.')`:e}function rn(){}var an=null;function on(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var sn=null,cn=null;function ln(e){var t=bt(e);if(t&&(e=t.stateNode)){var n=e[dt]||null;a:switch(e=t.stateNode,t.type){case`input`:if(Ut(e,n.value,n.defaultValue,n.defaultValue,n.checked,n.defaultChecked,n.type,n.name),t=n.name,n.type===`radio`&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll(`input[name="`+Ht(``+t)+`"][type="radio"]`),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var a=r[dt]||null;if(!a)throw Error(i(90));Ut(r,a.value,a.defaultValue,a.defaultValue,a.checked,a.defaultChecked,a.type,a.name)}}for(t=0;t<n.length;t++)r=n[t],r.form===e.form&&zt(r)}break a;case`textarea`:qt(e,n.value,n.defaultValue);break a;case`select`:t=n.value,t!=null&&Kt(e,!!n.multiple,t,!1)}}}var un=!1;function dn(e,t,n){if(un)return e(t,n);un=!0;try{return e(t)}finally{if(un=!1,(sn!==null||cn!==null)&&(Au(),sn&&(t=sn,e=cn,cn=sn=null,ln(t),e)))for(t=0;t<e.length;t++)ln(e[t])}}function fn(e,t){var n=e.stateNode;if(n===null)return null;var r=n[dt]||null;if(r===null)return null;n=r[t];a:switch(t){case`onClick`:case`onClickCapture`:case`onDoubleClick`:case`onDoubleClickCapture`:case`onMouseDown`:case`onMouseDownCapture`:case`onMouseMove`:case`onMouseMoveCapture`:case`onMouseUp`:case`onMouseUpCapture`:case`onMouseEnter`:(r=!r.disabled)||(e=e.type,r=!(e===`button`||e===`input`||e===`select`||e===`textarea`)),e=!r;break a;default:e=!1}if(e)return null;if(n&&typeof n!=`function`)throw Error(i(231,t,typeof n));return n}var pn=!(typeof window>`u`||window.document===void 0||window.document.createElement===void 0),mn=!1;if(pn)try{var hn={};Object.defineProperty(hn,"passive",{get:function(){mn=!0}}),window.addEventListener(`test`,hn,hn),window.removeEventListener(`test`,hn,hn)}catch{mn=!1}var gn=null,_n=null,vn=null;function yn(){if(vn)return vn;var e,t=_n,n=t.length,r,i=`value`in gn?gn.value:gn.textContent,a=i.length;for(e=0;e<n&&t[e]===i[e];e++);var o=n-e;for(r=1;r<=o&&t[n-r]===i[a-r];r++);return vn=i.slice(e,1<r?1-r:void 0)}function bn(e){var t=e.keyCode;return`charCode`in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function xn(){return!0}function Sn(){return!1}function Cn(e){function t(t,n,r,i,a){for(var o in this._reactName=t,this._targetInst=r,this.type=n,this.nativeEvent=i,this.target=a,this.currentTarget=null,e)e.hasOwnProperty(o)&&(t=e[o],this[o]=t?t(i):i[o]);return this.isDefaultPrevented=(i.defaultPrevented==null?!1===i.returnValue:i.defaultPrevented)?xn:Sn,this.isPropagationStopped=Sn,this}return h(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var e=this.nativeEvent;e&&(e.preventDefault?e.preventDefault():typeof e.returnValue!=`unknown`&&(e.returnValue=!1),this.isDefaultPrevented=xn)},stopPropagation:function(){var e=this.nativeEvent;e&&(e.stopPropagation?e.stopPropagation():typeof e.cancelBubble!=`unknown`&&(e.cancelBubble=!0),this.isPropagationStopped=xn)},persist:function(){},isPersistent:xn}),t}var wn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},Tn=Cn(wn),En=h({},wn,{view:0,detail:0}),Dn=Cn(En),On,kn,An,jn=h({},En,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Hn,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return`movementX`in e?e.movementX:(e!==An&&(An&&e.type===`mousemove`?(On=e.screenX-An.screenX,kn=e.screenY-An.screenY):kn=On=0,An=e),On)},movementY:function(e){return`movementY`in e?e.movementY:kn}}),Mn=Cn(jn),Nn=Cn(h({},jn,{dataTransfer:0})),Pn=Cn(h({},En,{relatedTarget:0})),Fn=Cn(h({},wn,{animationName:0,elapsedTime:0,pseudoElement:0})),In=Cn(h({},wn,{clipboardData:function(e){return`clipboardData`in e?e.clipboardData:window.clipboardData}})),Ln=Cn(h({},wn,{data:0})),Rn={Esc:`Escape`,Spacebar:` `,Left:`ArrowLeft`,Up:`ArrowUp`,Right:`ArrowRight`,Down:`ArrowDown`,Del:`Delete`,Win:`OS`,Menu:`ContextMenu`,Apps:`ContextMenu`,Scroll:`ScrollLock`,MozPrintableKey:`Unidentified`},zn={8:`Backspace`,9:`Tab`,12:`Clear`,13:`Enter`,16:`Shift`,17:`Control`,18:`Alt`,19:`Pause`,20:`CapsLock`,27:`Escape`,32:` `,33:`PageUp`,34:`PageDown`,35:`End`,36:`Home`,37:`ArrowLeft`,38:`ArrowUp`,39:`ArrowRight`,40:`ArrowDown`,45:`Insert`,46:`Delete`,112:`F1`,113:`F2`,114:`F3`,115:`F4`,116:`F5`,117:`F6`,118:`F7`,119:`F8`,120:`F9`,121:`F10`,122:`F11`,123:`F12`,144:`NumLock`,145:`ScrollLock`,224:`Meta`},Bn={Alt:`altKey`,Control:`ctrlKey`,Meta:`metaKey`,Shift:`shiftKey`};function Vn(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Bn[e])?!!t[e]:!1}function Hn(){return Vn}var Un=Cn(h({},En,{key:function(e){if(e.key){var t=Rn[e.key]||e.key;if(t!==`Unidentified`)return t}return e.type===`keypress`?(e=bn(e),e===13?`Enter`:String.fromCharCode(e)):e.type===`keydown`||e.type===`keyup`?zn[e.keyCode]||`Unidentified`:``},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Hn,charCode:function(e){return e.type===`keypress`?bn(e):0},keyCode:function(e){return e.type===`keydown`||e.type===`keyup`?e.keyCode:0},which:function(e){return e.type===`keypress`?bn(e):e.type===`keydown`||e.type===`keyup`?e.keyCode:0}})),Wn=Cn(h({},jn,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0})),Gn=Cn(h({},En,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Hn})),Kn=Cn(h({},wn,{propertyName:0,elapsedTime:0,pseudoElement:0})),qn=Cn(h({},jn,{deltaX:function(e){return`deltaX`in e?e.deltaX:`wheelDeltaX`in e?-e.wheelDeltaX:0},deltaY:function(e){return`deltaY`in e?e.deltaY:`wheelDeltaY`in e?-e.wheelDeltaY:`wheelDelta`in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0})),Jn=Cn(h({},wn,{newState:0,oldState:0})),Yn=[9,13,27,32],Xn=pn&&`CompositionEvent`in window,Zn=null;pn&&`documentMode`in document&&(Zn=document.documentMode);var Qn=pn&&`TextEvent`in window&&!Zn,$n=pn&&(!Xn||Zn&&8<Zn&&11>=Zn),er=` `,tr=!1;function nr(e,t){switch(e){case`keyup`:return Yn.indexOf(t.keyCode)!==-1;case`keydown`:return t.keyCode!==229;case`keypress`:case`mousedown`:case`focusout`:return!0;default:return!1}}function rr(e){return e=e.detail,typeof e==`object`&&`data`in e?e.data:null}var ir=!1;function ar(e,t){switch(e){case`compositionend`:return rr(t);case`keypress`:return t.which===32?(tr=!0,er):null;case`textInput`:return e=t.data,e===er&&tr?null:e;default:return null}}function or(e,t){if(ir)return e===`compositionend`||!Xn&&nr(e,t)?(e=yn(),vn=_n=gn=null,ir=!1,e):null;switch(e){case`paste`:return null;case`keypress`:if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case`compositionend`:return $n&&t.locale!==`ko`?null:t.data;default:return null}}var sr={color:!0,date:!0,datetime:!0,"datetime-local":!0,email:!0,month:!0,number:!0,password:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0};function cr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t===`input`?!!sr[e.type]:t===`textarea`}function lr(e,t,n,r){sn?cn?cn.push(r):cn=[r]:sn=r,t=Ld(t,`onChange`),0<t.length&&(n=new Tn(`onChange`,`change`,null,n,r),e.push({event:n,listeners:t}))}var ur=null,dr=null;function fr(e){kd(e,0)}function pr(e){if(zt(xt(e)))return e}function mr(e,t){if(e===`change`)return t}var hr=!1;if(pn){var gr;if(pn){var _r=`oninput`in document;if(!_r){var vr=document.createElement(`div`);vr.setAttribute(`oninput`,`return;`),_r=typeof vr.oninput==`function`}gr=_r}else gr=!1;hr=gr&&(!document.documentMode||9<document.documentMode)}function yr(){ur&&(ur.detachEvent(`onpropertychange`,br),dr=ur=null)}function br(e){if(e.propertyName===`value`&&pr(dr)){var t=[];lr(t,dr,e,on(e)),dn(fr,t)}}function xr(e,t,n){e===`focusin`?(yr(),ur=t,dr=n,ur.attachEvent(`onpropertychange`,br)):e===`focusout`&&yr()}function Sr(e){if(e===`selectionchange`||e===`keyup`||e===`keydown`)return pr(dr)}function Cr(e,t){if(e===`click`)return pr(t)}function wr(e,t){if(e===`input`||e===`change`)return pr(t)}function Tr(e,t){return e===t&&(e!==0||1/e==1/t)||e!==e&&t!==t}var Er=typeof Object.is==`function`?Object.is:Tr;function Dr(e,t){if(Er(e,t))return!0;if(typeof e!=`object`||!e||typeof t!=`object`||!t)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var i=n[r];if(!we.call(t,i)||!Er(e[i],t[i]))return!1}return!0}function Or(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function kr(e,t){var n=Or(e);e=0;for(var r;n;){if(n.nodeType===3){if(r=e+n.textContent.length,e<=t&&r>=t)return{node:n,offset:t-e};e=r}a:{for(;n;){if(n.nextSibling){n=n.nextSibling;break a}n=n.parentNode}n=void 0}n=Or(n)}}function Ar(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Ar(e,t.parentNode):`contains`in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function jr(e){e=e!=null&&e.ownerDocument!=null&&e.ownerDocument.defaultView!=null?e.ownerDocument.defaultView:window;for(var t=Bt(e.document);t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href==`string`}catch{n=!1}if(n)e=t.contentWindow;else break;t=Bt(e.document)}return t}function Mr(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t===`input`&&(e.type===`text`||e.type===`search`||e.type===`tel`||e.type===`url`||e.type===`password`)||t===`textarea`||e.contentEditable===`true`)}var Nr=pn&&`documentMode`in document&&11>=document.documentMode,Pr=null,Fr=null,Ir=null,Lr=!1;function Rr(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Lr||Pr==null||Pr!==Bt(r)||(r=Pr,`selectionStart`in r&&Mr(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Ir&&Dr(Ir,r)||(Ir=r,r=Ld(Fr,`onSelect`),0<r.length&&(t=new Tn(`onSelect`,`select`,null,t,n),e.push({event:t,listeners:r}),t.target=Pr)))}function zr(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n[`Webkit`+e]=`webkit`+t,n[`Moz`+e]=`moz`+t,n}var Br={animationend:zr(`Animation`,`AnimationEnd`),animationiteration:zr(`Animation`,`AnimationIteration`),animationstart:zr(`Animation`,`AnimationStart`),transitionrun:zr(`Transition`,`TransitionRun`),transitionstart:zr(`Transition`,`TransitionStart`),transitioncancel:zr(`Transition`,`TransitionCancel`),transitionend:zr(`Transition`,`TransitionEnd`)},Vr={},Hr={};pn&&(Hr=document.createElement(`div`).style,`AnimationEvent`in window||(delete Br.animationend.animation,delete Br.animationiteration.animation,delete Br.animationstart.animation),`TransitionEvent`in window||delete Br.transitionend.transition);function Ur(e){if(Vr[e])return Vr[e];if(!Br[e])return e;var t=Br[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in Hr)return Vr[e]=t[n];return e}var Wr=Ur(`animationend`),Gr=Ur(`animationiteration`),Kr=Ur(`animationstart`),qr=Ur(`transitionrun`),Jr=Ur(`transitionstart`),Yr=Ur(`transitioncancel`),Xr=Ur(`transitionend`),Zr=new Map,Qr=`abort auxClick beforeToggle cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel`.split(` `);Qr.push(`scrollEnd`);function $r(e,t){Zr.set(e,t),Et(t,[e])}var ei=typeof reportError==`function`?reportError:function(e){if(typeof window==`object`&&typeof window.ErrorEvent==`function`){var t=new window.ErrorEvent(`error`,{bubbles:!0,cancelable:!0,message:typeof e==`object`&&e&&typeof e.message==`string`?String(e.message):String(e),error:e});if(!window.dispatchEvent(t))return}else if(typeof process==`object`&&typeof process.emit==`function`){process.emit(`uncaughtException`,e);return}console.error(e)},ti=[],ni=0,ri=0;function ii(){for(var e=ni,t=ri=ni=0;t<e;){var n=ti[t];ti[t++]=null;var r=ti[t];ti[t++]=null;var i=ti[t];ti[t++]=null;var a=ti[t];if(ti[t++]=null,r!==null&&i!==null){var o=r.pending;o===null?i.next=i:(i.next=o.next,o.next=i),r.pending=i}a!==0&&ci(n,i,a)}}function ai(e,t,n,r){ti[ni++]=e,ti[ni++]=t,ti[ni++]=n,ti[ni++]=r,ri|=r,e.lanes|=r,e=e.alternate,e!==null&&(e.lanes|=r)}function oi(e,t,n,r){return ai(e,t,n,r),li(e)}function si(e,t){return ai(e,null,null,t),li(e)}function ci(e,t,n){e.lanes|=n;var r=e.alternate;r!==null&&(r.lanes|=n);for(var i=!1,a=e.return;a!==null;)a.childLanes|=n,r=a.alternate,r!==null&&(r.childLanes|=n),a.tag===22&&(e=a.stateNode,e===null||e._visibility&1||(i=!0)),e=a,a=a.return;return e.tag===3?(a=e.stateNode,i&&t!==null&&(i=31-Ve(n),e=a.hiddenUpdates,r=e[i],r===null?e[i]=[t]:r.push(t),t.lane=n|536870912),a):null}function li(e){if(50<xu)throw xu=0,Su=null,Error(i(185));for(var t=e.return;t!==null;)e=t,t=e.return;return e.tag===3?e.stateNode:null}var ui={};function di(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.refCleanup=this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function fi(e,t,n,r){return new di(e,t,n,r)}function pi(e){return e=e.prototype,!(!e||!e.isReactComponent)}function mi(e,t){var n=e.alternate;return n===null?(n=fi(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&65011712,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n.refCleanup=e.refCleanup,n}function hi(e,t){e.flags&=65011714;var n=e.alternate;return n===null?(e.childLanes=0,e.lanes=t,e.child=null,e.subtreeFlags=0,e.memoizedProps=null,e.memoizedState=null,e.updateQueue=null,e.dependencies=null,e.stateNode=null):(e.childLanes=n.childLanes,e.lanes=n.lanes,e.child=n.child,e.subtreeFlags=0,e.deletions=null,e.memoizedProps=n.memoizedProps,e.memoizedState=n.memoizedState,e.updateQueue=n.updateQueue,e.type=n.type,t=n.dependencies,e.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext}),e}function gi(e,t,n,r,a,o){var s=0;if(r=e,typeof e==`function`)pi(e)&&(s=1);else if(typeof e==`string`)s=tp(e,n,le.current)?26:e===`html`||e===`head`||e===`body`?27:5;else a:switch(e){case k:return e=fi(31,n,t,a),e.elementType=k,e.lanes=o,e;case y:return _i(n.children,a,o,t);case b:s=8,a|=24;break;case x:return e=fi(12,n,t,a|2),e.elementType=x,e.lanes=o,e;case T:return e=fi(13,n,t,a),e.elementType=T,e.lanes=o,e;case E:return e=fi(19,n,t,a),e.elementType=E,e.lanes=o,e;default:if(typeof e==`object`&&e)switch(e.$$typeof){case C:s=10;break a;case S:s=9;break a;case w:s=11;break a;case D:s=14;break a;case O:s=16,r=null;break a}s=29,n=Error(i(130,e===null?`null`:typeof e,``)),r=null}return t=fi(s,n,t,a),t.elementType=e,t.type=r,t.lanes=o,t}function _i(e,t,n,r){return e=fi(7,e,r,t),e.lanes=n,e}function vi(e,t,n){return e=fi(6,e,null,t),e.lanes=n,e}function yi(e){var t=fi(18,null,null,0);return t.stateNode=e,t}function bi(e,t,n){return t=fi(4,e.children===null?[]:e.children,e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}var xi=new WeakMap;function Si(e,t){if(typeof e==`object`&&e){var n=xi.get(e);return n===void 0?(t={value:e,source:t,stack:Ce(t)},xi.set(e,t),t):n}return{value:e,source:t,stack:Ce(t)}}var Ci=[],wi=0,Ti=null,Ei=0,Di=[],Oi=0,ki=null,Ai=1,ji=``;function Mi(e,t){Ci[wi++]=Ei,Ci[wi++]=Ti,Ti=e,Ei=t}function Ni(e,t,n){Di[Oi++]=Ai,Di[Oi++]=ji,Di[Oi++]=ki,ki=e;var r=Ai;e=ji;var i=32-Ve(r)-1;r&=~(1<<i),n+=1;var a=32-Ve(t)+i;if(30<a){var o=i-i%5;a=(r&(1<<o)-1).toString(32),r>>=o,i-=o,Ai=1<<32-Ve(t)+i|n<<i|r,ji=a+e}else Ai=1<<a|n<<i|r,ji=e}function Pi(e){e.return!==null&&(Mi(e,1),Ni(e,1,0))}function Fi(e){for(;e===Ti;)Ti=Ci[--wi],Ci[wi]=null,Ei=Ci[--wi],Ci[wi]=null;for(;e===ki;)ki=Di[--Oi],Di[Oi]=null,ji=Di[--Oi],Di[Oi]=null,Ai=Di[--Oi],Di[Oi]=null}function Ii(e,t){Di[Oi++]=Ai,Di[Oi++]=ji,Di[Oi++]=ki,Ai=t.id,ji=t.overflow,ki=e}var Li=null,Ri=null,zi=!1,Bi=null,Vi=!1,Hi=Error(i(519));function Ui(e){throw Yi(Si(Error(i(418,1<arguments.length&&arguments[1]!==void 0&&arguments[1]?`text`:`HTML`,``)),e)),Hi}function Wi(e){var t=e.stateNode,n=e.type,r=e.memoizedProps;switch(t[ut]=e,t[dt]=r,n){case`dialog`:Ad(`cancel`,t),Ad(`close`,t);break;case`iframe`:case`object`:case`embed`:Ad(`load`,t);break;case`video`:case`audio`:for(n=0;n<Dd.length;n++)Ad(Dd[n],t);break;case`source`:Ad(`error`,t);break;case`img`:case`image`:case`link`:Ad(`error`,t),Ad(`load`,t);break;case`details`:Ad(`toggle`,t);break;case`input`:Ad(`invalid`,t),Wt(t,r.value,r.defaultValue,r.checked,r.defaultChecked,r.type,r.name,!0);break;case`select`:Ad(`invalid`,t);break;case`textarea`:Ad(`invalid`,t),Jt(t,r.value,r.defaultValue,r.children)}n=r.children,typeof n!=`string`&&typeof n!=`number`&&typeof n!=`bigint`||t.textContent===``+n||!0===r.suppressHydrationWarning||Ud(t.textContent,n)?(r.popover!=null&&(Ad(`beforetoggle`,t),Ad(`toggle`,t)),r.onScroll!=null&&Ad(`scroll`,t),r.onScrollEnd!=null&&Ad(`scrollend`,t),r.onClick!=null&&(t.onclick=rn),t=!0):t=!1,t||Ui(e,!0)}function Gi(e){for(Li=e.return;Li;)switch(Li.tag){case 5:case 31:case 13:Vi=!1;return;case 27:case 3:Vi=!0;return;default:Li=Li.return}}function Ki(e){if(e!==Li)return!1;if(!zi)return Gi(e),zi=!0,!1;var t=e.tag,n;if((n=t!==3&&t!==27)&&((n=t===5)&&(n=e.type,n=!(n!==`form`&&n!==`button`)||tf(e.type,e.memoizedProps)),n=!n),n&&Ri&&Ui(e),Gi(e),t===13){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(317));Ri=Sf(e)}else if(t===31){if(e=e.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(317));Ri=Sf(e)}else t===27?(t=Ri,uf(e.type)?(e=xf,xf=null,Ri=e):Ri=t):Ri=Li?bf(e.stateNode.nextSibling):null;return!0}function qi(){Ri=Li=null,zi=!1}function Ji(){var e=Bi;return e!==null&&(su===null?su=e:su.push.apply(su,e),Bi=null),e}function Yi(e){Bi===null?Bi=[e]:Bi.push(e)}var Xi=oe(null),Zi=null,Qi=null;function $i(e,t,n){ce(Xi,t._currentValue),t._currentValue=n}function ea(e){e._currentValue=Xi.current,se(Xi)}function ta(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)===t?r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t):(e.childLanes|=t,r!==null&&(r.childLanes|=t)),e===n)break;e=e.return}}function na(e,t,n,r){var a=e.child;for(a!==null&&(a.return=e);a!==null;){var o=a.dependencies;if(o!==null){var s=a.child;o=o.firstContext;a:for(;o!==null;){var c=o;o=a;for(var l=0;l<t.length;l++)if(c.context===t[l]){o.lanes|=n,c=o.alternate,c!==null&&(c.lanes|=n),ta(o.return,n,e),r||(s=null);break a}o=c.next}}else if(a.tag===18){if(s=a.return,s===null)throw Error(i(341));s.lanes|=n,o=s.alternate,o!==null&&(o.lanes|=n),ta(s,n,e),s=null}else s=a.child;if(s!==null)s.return=a;else for(s=a;s!==null;){if(s===e){s=null;break}if(a=s.sibling,a!==null){a.return=s.return,s=a;break}s=s.return}a=s}}function ra(e,t,n,r){e=null;for(var a=t,o=!1;a!==null;){if(!o){if(a.flags&524288)o=!0;else if(a.flags&262144)break}if(a.tag===10){var s=a.alternate;if(s===null)throw Error(i(387));if(s=s.memoizedProps,s!==null){var c=a.type;Er(a.pendingProps.value,s.value)||(e===null?e=[c]:e.push(c))}}else if(a===fe.current){if(s=a.alternate,s===null)throw Error(i(387));s.memoizedState.memoizedState!==a.memoizedState.memoizedState&&(e===null?e=[up]:e.push(up))}a=a.return}e!==null&&na(t,e,n,r),t.flags|=262144}function ia(e){for(e=e.firstContext;e!==null;){if(!Er(e.context._currentValue,e.memoizedValue))return!0;e=e.next}return!1}function aa(e){Zi=e,Qi=null,e=e.dependencies,e!==null&&(e.firstContext=null)}function oa(e){return ca(Zi,e)}function sa(e,t){return Zi===null&&aa(e),ca(e,t)}function ca(e,t){var n=t._currentValue;if(t={context:t,memoizedValue:n,next:null},Qi===null){if(e===null)throw Error(i(308));Qi=t,e.dependencies={lanes:0,firstContext:t},e.flags|=524288}else Qi=Qi.next=t;return n}var la=typeof AbortController<`u`?AbortController:function(){var e=[],t=this.signal={aborted:!1,addEventListener:function(t,n){e.push(n)}};this.abort=function(){t.aborted=!0,e.forEach(function(e){return e()})}},ua=t.unstable_scheduleCallback,da=t.unstable_NormalPriority,fa={$$typeof:C,Consumer:null,Provider:null,_currentValue:null,_currentValue2:null,_threadCount:0};function pa(){return{controller:new la,data:new Map,refCount:0}}function ma(e){e.refCount--,e.refCount===0&&ua(da,function(){e.controller.abort()})}var ha=null,ga=0,_a=0,va=null;function ya(e,t){if(ha===null){var n=ha=[];ga=0,_a=xd(),va={status:`pending`,value:void 0,then:function(e){n.push(e)}}}return ga++,t.then(ba,ba),t}function ba(){if(--ga===0&&ha!==null){va!==null&&(va.status=`fulfilled`);var e=ha;ha=null,_a=0,va=null;for(var t=0;t<e.length;t++)(0,e[t])()}}function xa(e,t){var n=[],r={status:`pending`,value:null,reason:null,then:function(e){n.push(e)}};return e.then(function(){r.status=`fulfilled`,r.value=t;for(var e=0;e<n.length;e++)(0,n[e])(t)},function(e){for(r.status=`rejected`,r.reason=e,e=0;e<n.length;e++)(0,n[e])(void 0)}),r}var Sa=M.S;M.S=function(e,t){uu=ke(),typeof t==`object`&&t&&typeof t.then==`function`&&ya(e,t),Sa!==null&&Sa(e,t)};var Ca=oe(null);function wa(){var e=Ca.current;return e===null?Gl.pooledCache:e}function Ta(e,t){t===null?ce(Ca,Ca.current):ce(Ca,t.pool)}function Ea(){var e=wa();return e===null?null:{parent:fa._currentValue,pool:e}}var Da=Error(i(460)),Oa=Error(i(474)),ka=Error(i(542)),Aa={then:function(){}};function ja(e){return e=e.status,e===`fulfilled`||e===`rejected`}function Ma(e,t,n){switch(n=e[n],n===void 0?e.push(t):n!==t&&(t.then(rn,rn),t=n),t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,Ia(e),e;default:if(typeof t.status==`string`)t.then(rn,rn);else{if(e=Gl,e!==null&&100<e.shellSuspendCounter)throw Error(i(482));e=t,e.status=`pending`,e.then(function(e){if(t.status===`pending`){var n=t;n.status=`fulfilled`,n.value=e}},function(e){if(t.status===`pending`){var n=t;n.status=`rejected`,n.reason=e}})}switch(t.status){case`fulfilled`:return t.value;case`rejected`:throw e=t.reason,Ia(e),e}throw Pa=t,Da}}function Na(e){try{var t=e._init;return t(e._payload)}catch(e){throw typeof e==`object`&&e&&typeof e.then==`function`?(Pa=e,Da):e}}var Pa=null;function Fa(){if(Pa===null)throw Error(i(459));var e=Pa;return Pa=null,e}function Ia(e){if(e===Da||e===ka)throw Error(i(483))}var La=null,Ra=0;function za(e){var t=Ra;return Ra+=1,La===null&&(La=[]),Ma(La,e,t)}function Ba(e,t){t=t.props.ref,e.ref=t===void 0?null:t}function Va(e,t){throw t.$$typeof===g?Error(i(525)):(e=Object.prototype.toString.call(t),Error(i(31,e===`[object Object]`?`object with keys {`+Object.keys(t).join(`, `)+`}`:e)))}function Ha(e){function t(t,n){if(e){var r=t.deletions;r===null?(t.deletions=[n],t.flags|=16):r.push(n)}}function n(n,r){if(!e)return null;for(;r!==null;)t(n,r),r=r.sibling;return null}function r(e){for(var t=new Map;e!==null;)e.key===null?t.set(e.index,e):t.set(e.key,e),e=e.sibling;return t}function a(e,t){return e=mi(e,t),e.index=0,e.sibling=null,e}function o(t,n,r){return t.index=r,e?(r=t.alternate,r===null?(t.flags|=67108866,n):(r=r.index,r<n?(t.flags|=67108866,n):r)):(t.flags|=1048576,n)}function s(t){return e&&t.alternate===null&&(t.flags|=67108866),t}function c(e,t,n,r){return t===null||t.tag!==6?(t=vi(n,e.mode,r),t.return=e,t):(t=a(t,n),t.return=e,t)}function l(e,t,n,r){var i=n.type;return i===y?d(e,t,n.props.children,r,n.key):t!==null&&(t.elementType===i||typeof i==`object`&&i&&i.$$typeof===O&&Na(i)===t.type)?(t=a(t,n.props),Ba(t,n),t.return=e,t):(t=gi(n.type,n.key,n.props,null,e.mode,r),Ba(t,n),t.return=e,t)}function u(e,t,n,r){return t===null||t.tag!==4||t.stateNode.containerInfo!==n.containerInfo||t.stateNode.implementation!==n.implementation?(t=bi(n,e.mode,r),t.return=e,t):(t=a(t,n.children||[]),t.return=e,t)}function d(e,t,n,r,i){return t===null||t.tag!==7?(t=_i(n,e.mode,r,i),t.return=e,t):(t=a(t,n),t.return=e,t)}function f(e,t,n){if(typeof t==`string`&&t!==``||typeof t==`number`||typeof t==`bigint`)return t=vi(``+t,e.mode,n),t.return=e,t;if(typeof t==`object`&&t){switch(t.$$typeof){case _:return n=gi(t.type,t.key,t.props,null,e.mode,n),Ba(n,t),n.return=e,n;case v:return t=bi(t,e.mode,n),t.return=e,t;case O:return t=Na(t),f(e,t,n)}if(re(t)||ee(t))return t=_i(t,e.mode,n,null),t.return=e,t;if(typeof t.then==`function`)return f(e,za(t),n);if(t.$$typeof===C)return f(e,sa(e,t),n);Va(e,t)}return null}function p(e,t,n,r){var i=t===null?null:t.key;if(typeof n==`string`&&n!==``||typeof n==`number`||typeof n==`bigint`)return i===null?c(e,t,``+n,r):null;if(typeof n==`object`&&n){switch(n.$$typeof){case _:return n.key===i?l(e,t,n,r):null;case v:return n.key===i?u(e,t,n,r):null;case O:return n=Na(n),p(e,t,n,r)}if(re(n)||ee(n))return i===null?d(e,t,n,r,null):null;if(typeof n.then==`function`)return p(e,t,za(n),r);if(n.$$typeof===C)return p(e,t,sa(e,n),r);Va(e,n)}return null}function m(e,t,n,r,i){if(typeof r==`string`&&r!==``||typeof r==`number`||typeof r==`bigint`)return e=e.get(n)||null,c(t,e,``+r,i);if(typeof r==`object`&&r){switch(r.$$typeof){case _:return e=e.get(r.key===null?n:r.key)||null,l(t,e,r,i);case v:return e=e.get(r.key===null?n:r.key)||null,u(t,e,r,i);case O:return r=Na(r),m(e,t,n,r,i)}if(re(r)||ee(r))return e=e.get(n)||null,d(t,e,r,i,null);if(typeof r.then==`function`)return m(e,t,n,za(r),i);if(r.$$typeof===C)return m(e,t,n,sa(t,r),i);Va(t,r)}return null}function h(i,a,s,c){for(var l=null,u=null,d=a,h=a=0,g=null;d!==null&&h<s.length;h++){d.index>h?(g=d,d=null):g=d.sibling;var _=p(i,d,s[h],c);if(_===null){d===null&&(d=g);break}e&&d&&_.alternate===null&&t(i,d),a=o(_,a,h),u===null?l=_:u.sibling=_,u=_,d=g}if(h===s.length)return n(i,d),zi&&Mi(i,h),l;if(d===null){for(;h<s.length;h++)d=f(i,s[h],c),d!==null&&(a=o(d,a,h),u===null?l=d:u.sibling=d,u=d);return zi&&Mi(i,h),l}for(d=r(d);h<s.length;h++)g=m(d,i,h,s[h],c),g!==null&&(e&&g.alternate!==null&&d.delete(g.key===null?h:g.key),a=o(g,a,h),u===null?l=g:u.sibling=g,u=g);return e&&d.forEach(function(e){return t(i,e)}),zi&&Mi(i,h),l}function g(a,s,c,l){if(c==null)throw Error(i(151));for(var u=null,d=null,h=s,g=s=0,_=null,v=c.next();h!==null&&!v.done;g++,v=c.next()){h.index>g?(_=h,h=null):_=h.sibling;var y=p(a,h,v.value,l);if(y===null){h===null&&(h=_);break}e&&h&&y.alternate===null&&t(a,h),s=o(y,s,g),d===null?u=y:d.sibling=y,d=y,h=_}if(v.done)return n(a,h),zi&&Mi(a,g),u;if(h===null){for(;!v.done;g++,v=c.next())v=f(a,v.value,l),v!==null&&(s=o(v,s,g),d===null?u=v:d.sibling=v,d=v);return zi&&Mi(a,g),u}for(h=r(h);!v.done;g++,v=c.next())v=m(h,a,g,v.value,l),v!==null&&(e&&v.alternate!==null&&h.delete(v.key===null?g:v.key),s=o(v,s,g),d===null?u=v:d.sibling=v,d=v);return e&&h.forEach(function(e){return t(a,e)}),zi&&Mi(a,g),u}function b(e,r,o,c){if(typeof o==`object`&&o&&o.type===y&&o.key===null&&(o=o.props.children),typeof o==`object`&&o){switch(o.$$typeof){case _:a:{for(var l=o.key;r!==null;){if(r.key===l){if(l=o.type,l===y){if(r.tag===7){n(e,r.sibling),c=a(r,o.props.children),c.return=e,e=c;break a}}else if(r.elementType===l||typeof l==`object`&&l&&l.$$typeof===O&&Na(l)===r.type){n(e,r.sibling),c=a(r,o.props),Ba(c,o),c.return=e,e=c;break a}n(e,r);break}else t(e,r);r=r.sibling}o.type===y?(c=_i(o.props.children,e.mode,c,o.key),c.return=e,e=c):(c=gi(o.type,o.key,o.props,null,e.mode,c),Ba(c,o),c.return=e,e=c)}return s(e);case v:a:{for(l=o.key;r!==null;){if(r.key===l)if(r.tag===4&&r.stateNode.containerInfo===o.containerInfo&&r.stateNode.implementation===o.implementation){n(e,r.sibling),c=a(r,o.children||[]),c.return=e,e=c;break a}else{n(e,r);break}else t(e,r);r=r.sibling}c=bi(o,e.mode,c),c.return=e,e=c}return s(e);case O:return o=Na(o),b(e,r,o,c)}if(re(o))return h(e,r,o,c);if(ee(o)){if(l=ee(o),typeof l!=`function`)throw Error(i(150));return o=l.call(o),g(e,r,o,c)}if(typeof o.then==`function`)return b(e,r,za(o),c);if(o.$$typeof===C)return b(e,r,sa(e,o),c);Va(e,o)}return typeof o==`string`&&o!==``||typeof o==`number`||typeof o==`bigint`?(o=``+o,r!==null&&r.tag===6?(n(e,r.sibling),c=a(r,o),c.return=e,e=c):(n(e,r),c=vi(o,e.mode,c),c.return=e,e=c),s(e)):n(e,r)}return function(e,t,n,r){try{Ra=0;var i=b(e,t,n,r);return La=null,i}catch(t){if(t===Da||t===ka)throw t;var a=fi(29,t,null,e.mode);return a.lanes=r,a.return=e,a}}}var Ua=Ha(!0),Wa=Ha(!1),Ga=!1;function Ka(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,lanes:0,hiddenCallbacks:null},callbacks:null}}function qa(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,callbacks:null})}function Ja(e){return{lane:e,tag:0,payload:null,callback:null,next:null}}function Ya(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,Wl&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,t=li(e),ci(e,null,n),t}return ai(e,r,t,n),li(e)}function Xa(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,n&4194048)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,rt(e,n)}}function Za(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,a=null;if(n=n.firstBaseUpdate,n!==null){do{var o={lane:n.lane,tag:n.tag,payload:n.payload,callback:null,next:null};a===null?i=a=o:a=a.next=o,n=n.next}while(n!==null);a===null?i=a=t:a=a.next=t}else i=a=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:a,shared:r.shared,callbacks:r.callbacks},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}var Qa=!1;function $a(){if(Qa){var e=va;if(e!==null)throw e}}function eo(e,t,n,r){Qa=!1;var i=e.updateQueue;Ga=!1;var a=i.firstBaseUpdate,o=i.lastBaseUpdate,s=i.shared.pending;if(s!==null){i.shared.pending=null;var c=s,l=c.next;c.next=null,o===null?a=l:o.next=l,o=c;var u=e.alternate;u!==null&&(u=u.updateQueue,s=u.lastBaseUpdate,s!==o&&(s===null?u.firstBaseUpdate=l:s.next=l,u.lastBaseUpdate=c))}if(a!==null){var d=i.baseState;o=0,u=l=c=null,s=a;do{var f=s.lane&-536870913,p=f!==s.lane;if(p?(ql&f)===f:(r&f)===f){f!==0&&f===_a&&(Qa=!0),u!==null&&(u=u.next={lane:0,tag:s.tag,payload:s.payload,callback:null,next:null});a:{var m=e,g=s;f=t;var _=n;switch(g.tag){case 1:if(m=g.payload,typeof m==`function`){d=m.call(_,d,f);break a}d=m;break a;case 3:m.flags=m.flags&-65537|128;case 0:if(m=g.payload,f=typeof m==`function`?m.call(_,d,f):m,f==null)break a;d=h({},d,f);break a;case 2:Ga=!0}}f=s.callback,f!==null&&(e.flags|=64,p&&(e.flags|=8192),p=i.callbacks,p===null?i.callbacks=[f]:p.push(f))}else p={lane:f,tag:s.tag,payload:s.payload,callback:s.callback,next:null},u===null?(l=u=p,c=d):u=u.next=p,o|=f;if(s=s.next,s===null){if(s=i.shared.pending,s===null)break;p=s,s=p.next,p.next=null,i.lastBaseUpdate=p,i.shared.pending=null}}while(1);u===null&&(c=d),i.baseState=c,i.firstBaseUpdate=l,i.lastBaseUpdate=u,a===null&&(i.shared.lanes=0),tu|=o,e.lanes=o,e.memoizedState=d}}function to(e,t){if(typeof e!=`function`)throw Error(i(191,e));e.call(t)}function no(e,t){var n=e.callbacks;if(n!==null)for(e.callbacks=null,e=0;e<n.length;e++)to(n[e],t)}var ro=oe(null),io=oe(0);function ao(e,t){e=$l,ce(io,e),ce(ro,t),$l=e|t.baseLanes}function oo(){ce(io,$l),ce(ro,ro.current)}function so(){$l=io.current,se(ro),se(io)}var co=oe(null),lo=null;function uo(e){var t=e.alternate;ce(go,go.current&1),ce(co,e),lo===null&&(t===null||ro.current!==null||t.memoizedState!==null)&&(lo=e)}function fo(e){ce(go,go.current),ce(co,e),lo===null&&(lo=e)}function po(e){e.tag===22?(ce(go,go.current),ce(co,e),lo===null&&(lo=e)):mo(e)}function mo(){ce(go,go.current),ce(co,co.current)}function ho(e){se(co),lo===e&&(lo=null),se(go)}var go=oe(0);function _o(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||_f(n)||vf(n)))return t}else if(t.tag===19&&(t.memoizedProps.revealOrder===`forwards`||t.memoizedProps.revealOrder===`backwards`||t.memoizedProps.revealOrder===`unstable_legacy-backwards`||t.memoizedProps.revealOrder===`together`)){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var vo=0,yo=null,bo=null,xo=null,So=!1,Co=!1,wo=!1,F=0,To=0,Eo=null,Do=0;function Oo(){throw Error(i(321))}function ko(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!Er(e[n],t[n]))return!1;return!0}function Ao(e,t,n,r,i,a){return vo=a,yo=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,M.H=e===null||e.memoizedState===null?Ks:qs,wo=!1,a=n(r,i),wo=!1,Co&&(a=Mo(t,n,r,i)),jo(e),a}function jo(e){M.H=Gs;var t=bo!==null&&bo.next!==null;if(vo=0,xo=bo=yo=null,So=!1,To=0,Eo=null,t)throw Error(i(300));e===null||uc||(e=e.dependencies,e!==null&&ia(e)&&(uc=!0))}function Mo(e,t,n,r){yo=e;var a=0;do{if(Co&&(Eo=null),To=0,Co=!1,25<=a)throw Error(i(301));if(a+=1,xo=bo=null,e.updateQueue!=null){var o=e.updateQueue;o.lastEffect=null,o.events=null,o.stores=null,o.memoCache!=null&&(o.memoCache.index=0)}M.H=Js,o=t(n,r)}while(Co);return o}function No(){var e=M.H,t=e.useState()[0];return t=typeof t.then==`function`?Bo(t):t,e=e.useState()[0],(bo===null?null:bo.memoizedState)!==e&&(yo.flags|=1024),t}function Po(){var e=F!==0;return F=0,e}function Fo(e,t,n){t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~n}function Io(e){if(So){for(e=e.memoizedState;e!==null;){var t=e.queue;t!==null&&(t.pending=null),e=e.next}So=!1}vo=0,xo=bo=yo=null,Co=!1,To=F=0,Eo=null}function Lo(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return xo===null?yo.memoizedState=xo=e:xo=xo.next=e,xo}function Ro(){if(bo===null){var e=yo.alternate;e=e===null?null:e.memoizedState}else e=bo.next;var t=xo===null?yo.memoizedState:xo.next;if(t!==null)xo=t,bo=e;else{if(e===null)throw yo.alternate===null?Error(i(467)):Error(i(310));bo=e,e={memoizedState:bo.memoizedState,baseState:bo.baseState,baseQueue:bo.baseQueue,queue:bo.queue,next:null},xo===null?yo.memoizedState=xo=e:xo=xo.next=e}return xo}function zo(){return{lastEffect:null,events:null,stores:null,memoCache:null}}function Bo(e){var t=To;return To+=1,Eo===null&&(Eo=[]),e=Ma(Eo,e,t),t=yo,(xo===null?t.memoizedState:xo.next)===null&&(t=t.alternate,M.H=t===null||t.memoizedState===null?Ks:qs),e}function Vo(e){if(typeof e==`object`&&e){if(typeof e.then==`function`)return Bo(e);if(e.$$typeof===C)return oa(e)}throw Error(i(438,String(e)))}function Ho(e){var t=null,n=yo.updateQueue;if(n!==null&&(t=n.memoCache),t==null){var r=yo.alternate;r!==null&&(r=r.updateQueue,r!==null&&(r=r.memoCache,r!=null&&(t={data:r.data.map(function(e){return e.slice()}),index:0})))}if(t??={data:[],index:0},n===null&&(n=zo(),yo.updateQueue=n),n.memoCache=t,n=t.data[t.index],n===void 0)for(n=t.data[t.index]=Array(e),r=0;r<e;r++)n[r]=A;return t.index++,n}function Uo(e,t){return typeof t==`function`?t(e):t}function Wo(e){return Go(Ro(),bo,e)}function Go(e,t,n){var r=e.queue;if(r===null)throw Error(i(311));r.lastRenderedReducer=n;var a=e.baseQueue,o=r.pending;if(o!==null){if(a!==null){var s=a.next;a.next=o.next,o.next=s}t.baseQueue=a=o,r.pending=null}if(o=e.baseState,a===null)e.memoizedState=o;else{t=a.next;var c=s=null,l=null,u=t,d=!1;do{var f=u.lane&-536870913;if(f===u.lane?(vo&f)===f:(ql&f)===f){var p=u.revertLane;if(p===0)l!==null&&(l=l.next={lane:0,revertLane:0,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),f===_a&&(d=!0);else if((vo&p)===p){u=u.next,p===_a&&(d=!0);continue}else f={lane:0,revertLane:u.revertLane,gesture:null,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=f,s=o):l=l.next=f,yo.lanes|=p,tu|=p;f=u.action,wo&&n(o,f),o=u.hasEagerState?u.eagerState:n(o,f)}else p={lane:f,revertLane:u.revertLane,gesture:u.gesture,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null},l===null?(c=l=p,s=o):l=l.next=p,yo.lanes|=f,tu|=f;u=u.next}while(u!==null&&u!==t);if(l===null?s=o:l.next=c,!Er(o,e.memoizedState)&&(uc=!0,d&&(n=va,n!==null)))throw n;e.memoizedState=o,e.baseState=s,e.baseQueue=l,r.lastRenderedState=o}return a===null&&(r.lanes=0),[e.memoizedState,r.dispatch]}function Ko(e){var t=Ro(),n=t.queue;if(n===null)throw Error(i(311));n.lastRenderedReducer=e;var r=n.dispatch,a=n.pending,o=t.memoizedState;if(a!==null){n.pending=null;var s=a=a.next;do o=e(o,s.action),s=s.next;while(s!==a);Er(o,t.memoizedState)||(uc=!0),t.memoizedState=o,t.baseQueue===null&&(t.baseState=o),n.lastRenderedState=o}return[o,r]}function qo(e,t,n){var r=yo,a=Ro(),o=zi;if(o){if(n===void 0)throw Error(i(407));n=n()}else n=t();var s=!Er((bo||a).memoizedState,n);if(s&&(a.memoizedState=n,uc=!0),a=a.queue,vs(Xo.bind(null,r,a,e),[e]),a.getSnapshot!==t||s||xo!==null&&xo.memoizedState.tag&1){if(r.flags|=2048,ps(9,{destroy:void 0},Yo.bind(null,r,a,n,t),null),Gl===null)throw Error(i(349));o||vo&127||Jo(r,t,n)}return n}function Jo(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=yo.updateQueue,t===null?(t=zo(),yo.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function Yo(e,t,n,r){t.value=n,t.getSnapshot=r,Zo(t)&&Qo(e)}function Xo(e,t,n){return n(function(){Zo(t)&&Qo(e)})}function Zo(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!Er(e,n)}catch{return!0}}function Qo(e){var t=si(e,2);t!==null&&Tu(t,e,2)}function $o(e){var t=Lo();if(typeof e==`function`){var n=e;if(e=n(),wo){Be(!0);try{n()}finally{Be(!1)}}}return t.memoizedState=t.baseState=e,t.queue={pending:null,lanes:0,dispatch:null,lastRenderedReducer:Uo,lastRenderedState:e},t}function es(e,t,n,r){return e.baseState=n,Go(e,bo,typeof r==`function`?r:Uo)}function ts(e,t,n,r,a){if(Hs(e))throw Error(i(485));if(e=t.action,e!==null){var o={payload:a,action:e,next:null,isTransition:!0,status:`pending`,value:null,reason:null,listeners:[],then:function(e){o.listeners.push(e)}};M.T===null?o.isTransition=!1:n(!0),r(o),n=t.pending,n===null?(o.next=t.pending=o,ns(t,o)):(o.next=n.next,t.pending=n.next=o)}}function ns(e,t){var n=t.action,r=t.payload,i=e.state;if(t.isTransition){var a=M.T,o={};M.T=o;try{var s=n(i,r),c=M.S;c!==null&&c(o,s),rs(e,t,s)}catch(n){as(e,t,n)}finally{a!==null&&o.types!==null&&(a.types=o.types),M.T=a}}else try{a=n(i,r),rs(e,t,a)}catch(n){as(e,t,n)}}function rs(e,t,n){typeof n==`object`&&n&&typeof n.then==`function`?n.then(function(n){is(e,t,n)},function(n){return as(e,t,n)}):is(e,t,n)}function is(e,t,n){t.status=`fulfilled`,t.value=n,os(t),e.state=n,t=e.pending,t!==null&&(n=t.next,n===t?e.pending=null:(n=n.next,t.next=n,ns(e,n)))}function as(e,t,n){var r=e.pending;if(e.pending=null,r!==null){r=r.next;do t.status=`rejected`,t.reason=n,os(t),t=t.next;while(t!==r)}e.action=null}function os(e){e=e.listeners;for(var t=0;t<e.length;t++)(0,e[t])()}function ss(e,t){return t}function cs(e,t){if(zi){var n=Gl.formState;if(n!==null){a:{var r=yo;if(zi){if(Ri){b:{for(var i=Ri,a=Vi;i.nodeType!==8;){if(!a){i=null;break b}if(i=bf(i.nextSibling),i===null){i=null;break b}}a=i.data,i=a===`F!`||a===`F`?i:null}if(i){Ri=bf(i.nextSibling),r=i.data===`F!`;break a}}Ui(r)}r=!1}r&&(t=n[0])}}return n=Lo(),n.memoizedState=n.baseState=t,r={pending:null,lanes:0,dispatch:null,lastRenderedReducer:ss,lastRenderedState:t},n.queue=r,n=zs.bind(null,yo,r),r.dispatch=n,r=$o(!1),a=Vs.bind(null,yo,!1,r.queue),r=Lo(),i={state:t,dispatch:null,action:e,pending:null},r.queue=i,n=ts.bind(null,yo,i,a,n),i.dispatch=n,r.memoizedState=e,[t,n,!1]}function ls(e){return us(Ro(),bo,e)}function us(e,t,n){if(t=Go(e,t,ss)[0],e=Wo(Uo)[0],typeof t==`object`&&t&&typeof t.then==`function`)try{var r=Bo(t)}catch(e){throw e===Da?ka:e}else r=t;t=Ro();var i=t.queue,a=i.dispatch;return n!==t.memoizedState&&(yo.flags|=2048,ps(9,{destroy:void 0},ds.bind(null,i,n),null)),[r,a,e]}function ds(e,t){e.action=t}function fs(e){var t=Ro(),n=bo;if(n!==null)return us(t,n,e);Ro(),t=t.memoizedState,n=Ro();var r=n.queue.dispatch;return n.memoizedState=e,[t,r,!1]}function ps(e,t,n,r){return e={tag:e,create:n,deps:r,inst:t,next:null},t=yo.updateQueue,t===null&&(t=zo(),yo.updateQueue=t),n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e),e}function ms(){return Ro().memoizedState}function hs(e,t,n,r){var i=Lo();yo.flags|=e,i.memoizedState=ps(1|t,{destroy:void 0},n,r===void 0?null:r)}function gs(e,t,n,r){var i=Ro();r=r===void 0?null:r;var a=i.memoizedState.inst;bo!==null&&r!==null&&ko(r,bo.memoizedState.deps)?i.memoizedState=ps(t,a,n,r):(yo.flags|=e,i.memoizedState=ps(1|t,a,n,r))}function _s(e,t){hs(8390656,8,e,t)}function vs(e,t){gs(2048,8,e,t)}function ys(e){yo.flags|=4;var t=yo.updateQueue;if(t===null)t=zo(),yo.updateQueue=t,t.events=[e];else{var n=t.events;n===null?t.events=[e]:n.push(e)}}function bs(e){var t=Ro().memoizedState;return ys({ref:t,nextImpl:e}),function(){if(Wl&2)throw Error(i(440));return t.impl.apply(void 0,arguments)}}function xs(e,t){return gs(4,2,e,t)}function Ss(e,t){return gs(4,4,e,t)}function Cs(e,t){if(typeof t==`function`){e=e();var n=t(e);return function(){typeof n==`function`?n():t(null)}}if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function ws(e,t,n){n=n==null?null:n.concat([e]),gs(4,4,Cs.bind(null,t,e),n)}function Ts(){}function Es(e,t){var n=Ro();t=t===void 0?null:t;var r=n.memoizedState;return t!==null&&ko(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function Ds(e,t){var n=Ro();t=t===void 0?null:t;var r=n.memoizedState;if(t!==null&&ko(t,r[1]))return r[0];if(r=e(),wo){Be(!0);try{e()}finally{Be(!1)}}return n.memoizedState=[r,t],r}function Os(e,t,n){return n===void 0||vo&1073741824&&!(ql&261930)?e.memoizedState=t:(e.memoizedState=n,e=wu(),yo.lanes|=e,tu|=e,n)}function ks(e,t,n,r){return Er(n,t)?n:ro.current===null?!(vo&42)||vo&1073741824&&!(ql&261930)?(uc=!0,e.memoizedState=n):(e=wu(),yo.lanes|=e,tu|=e,t):(e=Os(e,n,r),Er(e,t)||(uc=!0),e)}function As(e,t,n,r,i){var a=N.p;N.p=a!==0&&8>a?a:8;var o=M.T,s={};M.T=s,Vs(e,!1,t,n);try{var c=i(),l=M.S;l!==null&&l(s,c),typeof c==`object`&&c&&typeof c.then==`function`?Bs(e,t,xa(c,r),Cu(e)):Bs(e,t,r,Cu(e))}catch(n){Bs(e,t,{then:function(){},status:`rejected`,reason:n},Cu())}finally{N.p=a,o!==null&&s.types!==null&&(o.types=s.types),M.T=o}}function js(){}function Ms(e,t,n,r){if(e.tag!==5)throw Error(i(476));var a=Ns(e).queue;As(e,a,t,ie,n===null?js:function(){return Ps(e),n(r)})}function Ns(e){var t=e.memoizedState;if(t!==null)return t;t={memoizedState:ie,baseState:ie,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Uo,lastRenderedState:ie},next:null};var n={};return t.next={memoizedState:n,baseState:n,baseQueue:null,queue:{pending:null,lanes:0,dispatch:null,lastRenderedReducer:Uo,lastRenderedState:n},next:null},e.memoizedState=t,e=e.alternate,e!==null&&(e.memoizedState=t),t}function Ps(e){var t=Ns(e);t.next===null&&(t=e.alternate.memoizedState),Bs(e,t.next.queue,{},Cu())}function I(){return oa(up)}function Fs(){return Ro().memoizedState}function Is(){return Ro().memoizedState}function Ls(e){for(var t=e.return;t!==null;){switch(t.tag){case 24:case 3:var n=Cu();e=Ja(n);var r=Ya(t,e,n);r!==null&&(Tu(r,t,n),Xa(r,t,n)),t={cache:pa()},e.payload=t;return}t=t.return}}function Rs(e,t,n){var r=Cu();n={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null},Hs(e)?Us(t,n):(n=oi(e,t,n,r),n!==null&&(Tu(n,e,r),Ws(n,t,r)))}function zs(e,t,n){Bs(e,t,n,Cu())}function Bs(e,t,n,r){var i={lane:r,revertLane:0,gesture:null,action:n,hasEagerState:!1,eagerState:null,next:null};if(Hs(e))Us(t,i);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var o=t.lastRenderedState,s=a(o,n);if(i.hasEagerState=!0,i.eagerState=s,Er(s,o))return ai(e,t,i,0),Gl===null&&ii(),!1}catch{}if(n=oi(e,t,i,r),n!==null)return Tu(n,e,r),Ws(n,t,r),!0}return!1}function Vs(e,t,n,r){if(r={lane:2,revertLane:xd(),gesture:null,action:r,hasEagerState:!1,eagerState:null,next:null},Hs(e)){if(t)throw Error(i(479))}else t=oi(e,n,r,2),t!==null&&Tu(t,e,2)}function Hs(e){var t=e.alternate;return e===yo||t!==null&&t===yo}function Us(e,t){Co=So=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Ws(e,t,n){if(n&4194048){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,rt(e,n)}}var Gs={readContext:oa,use:Vo,useCallback:Oo,useContext:Oo,useEffect:Oo,useImperativeHandle:Oo,useLayoutEffect:Oo,useInsertionEffect:Oo,useMemo:Oo,useReducer:Oo,useRef:Oo,useState:Oo,useDebugValue:Oo,useDeferredValue:Oo,useTransition:Oo,useSyncExternalStore:Oo,useId:Oo,useHostTransitionStatus:Oo,useFormState:Oo,useActionState:Oo,useOptimistic:Oo,useMemoCache:Oo,useCacheRefresh:Oo};Gs.useEffectEvent=Oo;var Ks={readContext:oa,use:Vo,useCallback:function(e,t){return Lo().memoizedState=[e,t===void 0?null:t],e},useContext:oa,useEffect:_s,useImperativeHandle:function(e,t,n){n=n==null?null:n.concat([e]),hs(4194308,4,Cs.bind(null,t,e),n)},useLayoutEffect:function(e,t){return hs(4194308,4,e,t)},useInsertionEffect:function(e,t){hs(4,2,e,t)},useMemo:function(e,t){var n=Lo();t=t===void 0?null:t;var r=e();if(wo){Be(!0);try{e()}finally{Be(!1)}}return n.memoizedState=[r,t],r},useReducer:function(e,t,n){var r=Lo();if(n!==void 0){var i=n(t);if(wo){Be(!0);try{n(t)}finally{Be(!1)}}}else i=t;return r.memoizedState=r.baseState=i,e={pending:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:i},r.queue=e,e=e.dispatch=Rs.bind(null,yo,e),[r.memoizedState,e]},useRef:function(e){var t=Lo();return e={current:e},t.memoizedState=e},useState:function(e){e=$o(e);var t=e.queue,n=zs.bind(null,yo,t);return t.dispatch=n,[e.memoizedState,n]},useDebugValue:Ts,useDeferredValue:function(e,t){return Os(Lo(),e,t)},useTransition:function(){var e=$o(!1);return e=As.bind(null,yo,e.queue,!0,!1),Lo().memoizedState=e,[!1,e]},useSyncExternalStore:function(e,t,n){var r=yo,a=Lo();if(zi){if(n===void 0)throw Error(i(407));n=n()}else{if(n=t(),Gl===null)throw Error(i(349));ql&127||Jo(r,t,n)}a.memoizedState=n;var o={value:n,getSnapshot:t};return a.queue=o,_s(Xo.bind(null,r,o,e),[e]),r.flags|=2048,ps(9,{destroy:void 0},Yo.bind(null,r,o,n,t),null),n},useId:function(){var e=Lo(),t=Gl.identifierPrefix;if(zi){var n=ji,r=Ai;n=(r&~(1<<32-Ve(r)-1)).toString(32)+n,t=`_`+t+`R_`+n,n=F++,0<n&&(t+=`H`+n.toString(32)),t+=`_`}else n=Do++,t=`_`+t+`r_`+n.toString(32)+`_`;return e.memoizedState=t},useHostTransitionStatus:I,useFormState:cs,useActionState:cs,useOptimistic:function(e){var t=Lo();t.memoizedState=t.baseState=e;var n={pending:null,lanes:0,dispatch:null,lastRenderedReducer:null,lastRenderedState:null};return t.queue=n,t=Vs.bind(null,yo,!0,n),n.dispatch=t,[e,t]},useMemoCache:Ho,useCacheRefresh:function(){return Lo().memoizedState=Ls.bind(null,yo)},useEffectEvent:function(e){var t=Lo(),n={impl:e};return t.memoizedState=n,function(){if(Wl&2)throw Error(i(440));return n.impl.apply(void 0,arguments)}}},qs={readContext:oa,use:Vo,useCallback:Es,useContext:oa,useEffect:vs,useImperativeHandle:ws,useInsertionEffect:xs,useLayoutEffect:Ss,useMemo:Ds,useReducer:Wo,useRef:ms,useState:function(){return Wo(Uo)},useDebugValue:Ts,useDeferredValue:function(e,t){return ks(Ro(),bo.memoizedState,e,t)},useTransition:function(){var e=Wo(Uo)[0],t=Ro().memoizedState;return[typeof e==`boolean`?e:Bo(e),t]},useSyncExternalStore:qo,useId:Fs,useHostTransitionStatus:I,useFormState:ls,useActionState:ls,useOptimistic:function(e,t){return es(Ro(),bo,e,t)},useMemoCache:Ho,useCacheRefresh:Is};qs.useEffectEvent=bs;var Js={readContext:oa,use:Vo,useCallback:Es,useContext:oa,useEffect:vs,useImperativeHandle:ws,useInsertionEffect:xs,useLayoutEffect:Ss,useMemo:Ds,useReducer:Ko,useRef:ms,useState:function(){return Ko(Uo)},useDebugValue:Ts,useDeferredValue:function(e,t){var n=Ro();return bo===null?Os(n,e,t):ks(n,bo.memoizedState,e,t)},useTransition:function(){var e=Ko(Uo)[0],t=Ro().memoizedState;return[typeof e==`boolean`?e:Bo(e),t]},useSyncExternalStore:qo,useId:Fs,useHostTransitionStatus:I,useFormState:fs,useActionState:fs,useOptimistic:function(e,t){var n=Ro();return bo===null?(n.baseState=e,[e,n.queue.dispatch]):es(n,bo,e,t)},useMemoCache:Ho,useCacheRefresh:Is};Js.useEffectEvent=bs;function Ys(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:h({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Xs={enqueueSetState:function(e,t,n){e=e._reactInternals;var r=Cu(),i=Ja(r);i.payload=t,n!=null&&(i.callback=n),t=Ya(e,i,r),t!==null&&(Tu(t,e,r),Xa(t,e,r))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=Cu(),i=Ja(r);i.tag=1,i.payload=t,n!=null&&(i.callback=n),t=Ya(e,i,r),t!==null&&(Tu(t,e,r),Xa(t,e,r))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=Cu(),r=Ja(n);r.tag=2,t!=null&&(r.callback=t),t=Ya(e,r,n),t!==null&&(Tu(t,e,n),Xa(t,e,n))}};function Zs(e,t,n,r,i,a,o){return e=e.stateNode,typeof e.shouldComponentUpdate==`function`?e.shouldComponentUpdate(r,a,o):t.prototype&&t.prototype.isPureReactComponent?!Dr(n,r)||!Dr(i,a):!0}function Qs(e,t,n,r){e=t.state,typeof t.componentWillReceiveProps==`function`&&t.componentWillReceiveProps(n,r),typeof t.UNSAFE_componentWillReceiveProps==`function`&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&Xs.enqueueReplaceState(t,t.state,null)}function $s(e,t){var n=t;if(`ref`in t)for(var r in n={},t)r!==`ref`&&(n[r]=t[r]);if(e=e.defaultProps)for(var i in n===t&&(n=h({},n)),e)n[i]===void 0&&(n[i]=e[i]);return n}function ec(e){ei(e)}function tc(e){console.error(e)}function nc(e){ei(e)}function rc(e,t){try{var n=e.onUncaughtError;n(t.value,{componentStack:t.stack})}catch(e){setTimeout(function(){throw e})}}function ic(e,t,n){try{var r=e.onCaughtError;r(n.value,{componentStack:n.stack,errorBoundary:t.tag===1?t.stateNode:null})}catch(e){setTimeout(function(){throw e})}}function ac(e,t,n){return n=Ja(n),n.tag=3,n.payload={element:null},n.callback=function(){rc(e,t)},n}function oc(e){return e=Ja(e),e.tag=3,e}function sc(e,t,n,r){var i=n.type.getDerivedStateFromError;if(typeof i==`function`){var a=r.value;e.payload=function(){return i(a)},e.callback=function(){ic(t,n,r)}}var o=n.stateNode;o!==null&&typeof o.componentDidCatch==`function`&&(e.callback=function(){ic(t,n,r),typeof i!=`function`&&(pu===null?pu=new Set([this]):pu.add(this));var e=r.stack;this.componentDidCatch(r.value,{componentStack:e===null?``:e})})}function cc(e,t,n,r,a){if(n.flags|=32768,typeof r==`object`&&r&&typeof r.then==`function`){if(t=n.alternate,t!==null&&ra(t,n,a,!0),n=co.current,n!==null){switch(n.tag){case 31:case 13:return lo===null?Lu():n.alternate===null&&eu===0&&(eu=3),n.flags&=-257,n.flags|=65536,n.lanes=a,r===Aa?n.flags|=16384:(t=n.updateQueue,t===null?n.updateQueue=new Set([r]):t.add(r),td(e,r,a)),!1;case 22:return n.flags|=65536,r===Aa?n.flags|=16384:(t=n.updateQueue,t===null?(t={transitions:null,markerInstances:null,retryQueue:new Set([r])},n.updateQueue=t):(n=t.retryQueue,n===null?t.retryQueue=new Set([r]):n.add(r)),td(e,r,a)),!1}throw Error(i(435,n.tag))}return td(e,r,a),Lu(),!1}if(zi)return t=co.current,t===null?(r!==Hi&&(t=Error(i(423),{cause:r}),Yi(Si(t,n))),e=e.current.alternate,e.flags|=65536,a&=-a,e.lanes|=a,r=Si(r,n),a=ac(e.stateNode,r,a),Za(e,a),eu!==4&&(eu=2)):(!(t.flags&65536)&&(t.flags|=256),t.flags|=65536,t.lanes=a,r!==Hi&&(e=Error(i(422),{cause:r}),Yi(Si(e,n)))),!1;var o=Error(i(520),{cause:r});if(o=Si(o,n),ou===null?ou=[o]:ou.push(o),eu!==4&&(eu=2),t===null)return!0;r=Si(r,n),n=t;do{switch(n.tag){case 3:return n.flags|=65536,e=a&-a,n.lanes|=e,e=ac(n.stateNode,r,e),Za(n,e),!1;case 1:if(t=n.type,o=n.stateNode,!(n.flags&128)&&(typeof t.getDerivedStateFromError==`function`||o!==null&&typeof o.componentDidCatch==`function`&&(pu===null||!pu.has(o))))return n.flags|=65536,a&=-a,n.lanes|=a,a=oc(a),sc(a,e,n,r),Za(n,a),!1}n=n.return}while(n!==null);return!1}var lc=Error(i(461)),uc=!1;function dc(e,t,n,r){t.child=e===null?Wa(t,null,n,r):Ua(t,e.child,n,r)}function fc(e,t,n,r,i){n=n.render;var a=t.ref;if(`ref`in r){var o={};for(var s in r)s!==`ref`&&(o[s]=r[s])}else o=r;return aa(t),r=Ao(e,t,n,o,a,i),s=Po(),e!==null&&!uc?(Fo(e,t,i),Ic(e,t,i)):(zi&&s&&Pi(t),t.flags|=1,dc(e,t,r,i),t.child)}function pc(e,t,n,r,i){if(e===null){var a=n.type;return typeof a==`function`&&!pi(a)&&a.defaultProps===void 0&&n.compare===null?(t.tag=15,t.type=a,mc(e,t,a,r,i)):(e=gi(n.type,null,r,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(a=e.child,!Lc(e,i)){var o=a.memoizedProps;if(n=n.compare,n=n===null?Dr:n,n(o,r)&&e.ref===t.ref)return Ic(e,t,i)}return t.flags|=1,e=mi(a,r),e.ref=t.ref,e.return=t,t.child=e}function mc(e,t,n,r,i){if(e!==null){var a=e.memoizedProps;if(Dr(a,r)&&e.ref===t.ref)if(uc=!1,t.pendingProps=r=a,Lc(e,i))e.flags&131072&&(uc=!0);else return t.lanes=e.lanes,Ic(e,t,i)}return Sc(e,t,n,r,i)}function hc(e,t,n,r){var i=r.children,a=e===null?null:e.memoizedState;if(e===null&&t.stateNode===null&&(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),r.mode===`hidden`){if(t.flags&128){if(a=a===null?n:a.baseLanes|n,e!==null){for(r=t.child=e.child,i=0;r!==null;)i=i|r.lanes|r.childLanes,r=r.sibling;r=i&~a}else r=0,t.child=null;return _c(e,t,a,n,r)}if(n&536870912)t.memoizedState={baseLanes:0,cachePool:null},e!==null&&Ta(t,a===null?null:a.cachePool),a===null?oo():ao(t,a),po(t);else return r=t.lanes=536870912,_c(e,t,a===null?n:a.baseLanes|n,n,r)}else a===null?(e!==null&&Ta(t,null),oo(),mo(t)):(Ta(t,a.cachePool),ao(t,a),mo(t),t.memoizedState=null);return dc(e,t,i,n),t.child}function gc(e,t){return e!==null&&e.tag===22||t.stateNode!==null||(t.stateNode={_visibility:1,_pendingMarkers:null,_retryCache:null,_transitions:null}),t.sibling}function _c(e,t,n,r,i){var a=wa();return a=a===null?null:{parent:fa._currentValue,pool:a},t.memoizedState={baseLanes:n,cachePool:a},e!==null&&Ta(t,null),oo(),po(t),e!==null&&ra(e,t,r,!0),t.childLanes=i,null}function vc(e,t){return t=jc({mode:t.mode,children:t.children},e.mode),t.ref=e.ref,e.child=t,t.return=e,t}function yc(e,t,n){return Ua(t,e.child,null,n),e=vc(t,t.pendingProps),e.flags|=2,ho(t),t.memoizedState=null,e}function bc(e,t,n){var r=t.pendingProps,a=(t.flags&128)!=0;if(t.flags&=-129,e===null){if(zi){if(r.mode===`hidden`)return e=vc(t,r),t.lanes=536870912,gc(null,e);if(fo(t),(e=Ri)?(e=gf(e,Vi),e=e!==null&&e.data===`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:ki===null?null:{id:Ai,overflow:ji},retryLane:536870912,hydrationErrors:null},n=yi(e),n.return=t,t.child=n,Li=t,Ri=null)):e=null,e===null)throw Ui(t);return t.lanes=536870912,null}return vc(t,r)}var o=e.memoizedState;if(o!==null){var s=o.dehydrated;if(fo(t),a)if(t.flags&256)t.flags&=-257,t=yc(e,t,n);else if(t.memoizedState!==null)t.child=e.child,t.flags|=128,t=null;else throw Error(i(558));else if(uc||ra(e,t,n,!1),a=(n&e.childLanes)!==0,uc||a){if(r=Gl,r!==null&&(s=it(r,n),s!==0&&s!==o.retryLane))throw o.retryLane=s,si(e,s),Tu(r,e,s),lc;Lu(),t=yc(e,t,n)}else e=o.treeContext,Ri=bf(s.nextSibling),Li=t,zi=!0,Bi=null,Vi=!1,e!==null&&Ii(t,e),t=vc(t,r),t.flags|=4096;return t}return e=mi(e.child,{mode:r.mode,children:r.children}),e.ref=t.ref,t.child=e,e.return=t,e}function xc(e,t){var n=t.ref;if(n===null)e!==null&&e.ref!==null&&(t.flags|=4194816);else{if(typeof n!=`function`&&typeof n!=`object`)throw Error(i(284));(e===null||e.ref!==n)&&(t.flags|=4194816)}}function Sc(e,t,n,r,i){return aa(t),n=Ao(e,t,n,r,void 0,i),r=Po(),e!==null&&!uc?(Fo(e,t,i),Ic(e,t,i)):(zi&&r&&Pi(t),t.flags|=1,dc(e,t,n,i),t.child)}function Cc(e,t,n,r,i,a){return aa(t),t.updateQueue=null,n=Mo(t,r,n,i),jo(e),r=Po(),e!==null&&!uc?(Fo(e,t,a),Ic(e,t,a)):(zi&&r&&Pi(t),t.flags|=1,dc(e,t,n,a),t.child)}function wc(e,t,n,r,i){if(aa(t),t.stateNode===null){var a=ui,o=n.contextType;typeof o==`object`&&o&&(a=oa(o)),a=new n(r,a),t.memoizedState=a.state!==null&&a.state!==void 0?a.state:null,a.updater=Xs,t.stateNode=a,a._reactInternals=t,a=t.stateNode,a.props=r,a.state=t.memoizedState,a.refs={},Ka(t),o=n.contextType,a.context=typeof o==`object`&&o?oa(o):ui,a.state=t.memoizedState,o=n.getDerivedStateFromProps,typeof o==`function`&&(Ys(t,n,o,r),a.state=t.memoizedState),typeof n.getDerivedStateFromProps==`function`||typeof a.getSnapshotBeforeUpdate==`function`||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(o=a.state,typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount(),o!==a.state&&Xs.enqueueReplaceState(a,a.state,null),eo(t,r,a,i),$a(),a.state=t.memoizedState),typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!0}else if(e===null){a=t.stateNode;var s=t.memoizedProps,c=$s(n,s);a.props=c;var l=a.context,u=n.contextType;o=ui,typeof u==`object`&&u&&(o=oa(u));var d=n.getDerivedStateFromProps;u=typeof d==`function`||typeof a.getSnapshotBeforeUpdate==`function`,s=t.pendingProps!==s,u||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(s||l!==o)&&Qs(t,a,r,o),Ga=!1;var f=t.memoizedState;a.state=f,eo(t,r,a,i),$a(),l=t.memoizedState,s||f!==l||Ga?(typeof d==`function`&&(Ys(t,n,d,r),l=t.memoizedState),(c=Ga||Zs(t,n,c,r,f,l,o))?(u||typeof a.UNSAFE_componentWillMount!=`function`&&typeof a.componentWillMount!=`function`||(typeof a.componentWillMount==`function`&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount==`function`&&a.UNSAFE_componentWillMount()),typeof a.componentDidMount==`function`&&(t.flags|=4194308)):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=l),a.props=r,a.state=l,a.context=o,r=c):(typeof a.componentDidMount==`function`&&(t.flags|=4194308),r=!1)}else{a=t.stateNode,qa(e,t),o=t.memoizedProps,u=$s(n,o),a.props=u,d=t.pendingProps,f=a.context,l=n.contextType,c=ui,typeof l==`object`&&l&&(c=oa(l)),s=n.getDerivedStateFromProps,(l=typeof s==`function`||typeof a.getSnapshotBeforeUpdate==`function`)||typeof a.UNSAFE_componentWillReceiveProps!=`function`&&typeof a.componentWillReceiveProps!=`function`||(o!==d||f!==c)&&Qs(t,a,r,c),Ga=!1,f=t.memoizedState,a.state=f,eo(t,r,a,i),$a();var p=t.memoizedState;o!==d||f!==p||Ga||e!==null&&e.dependencies!==null&&ia(e.dependencies)?(typeof s==`function`&&(Ys(t,n,s,r),p=t.memoizedState),(u=Ga||Zs(t,n,u,r,f,p,c)||e!==null&&e.dependencies!==null&&ia(e.dependencies))?(l||typeof a.UNSAFE_componentWillUpdate!=`function`&&typeof a.componentWillUpdate!=`function`||(typeof a.componentWillUpdate==`function`&&a.componentWillUpdate(r,p,c),typeof a.UNSAFE_componentWillUpdate==`function`&&a.UNSAFE_componentWillUpdate(r,p,c)),typeof a.componentDidUpdate==`function`&&(t.flags|=4),typeof a.getSnapshotBeforeUpdate==`function`&&(t.flags|=1024)):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=p),a.props=r,a.state=p,a.context=c,r=u):(typeof a.componentDidUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!=`function`||o===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),r=!1)}return a=r,xc(e,t),r=(t.flags&128)!=0,a||r?(a=t.stateNode,n=r&&typeof n.getDerivedStateFromError!=`function`?null:a.render(),t.flags|=1,e!==null&&r?(t.child=Ua(t,e.child,null,i),t.child=Ua(t,null,n,i)):dc(e,t,n,i),t.memoizedState=a.state,e=t.child):e=Ic(e,t,i),e}function Tc(e,t,n,r){return qi(),t.flags|=256,dc(e,t,n,r),t.child}var Ec={dehydrated:null,treeContext:null,retryLane:0,hydrationErrors:null};function Dc(e){return{baseLanes:e,cachePool:Ea()}}function Oc(e,t,n){return e=e===null?0:e.childLanes&~n,t&&(e|=iu),e}function kc(e,t,n){var r=t.pendingProps,a=!1,o=(t.flags&128)!=0,s;if((s=o)||(s=e!==null&&e.memoizedState===null?!1:(go.current&2)!=0),s&&(a=!0,t.flags&=-129),s=(t.flags&32)!=0,t.flags&=-33,e===null){if(zi){if(a?uo(t):mo(t),(e=Ri)?(e=gf(e,Vi),e=e!==null&&e.data!==`&`?e:null,e!==null&&(t.memoizedState={dehydrated:e,treeContext:ki===null?null:{id:Ai,overflow:ji},retryLane:536870912,hydrationErrors:null},n=yi(e),n.return=t,t.child=n,Li=t,Ri=null)):e=null,e===null)throw Ui(t);return vf(e)?t.lanes=32:t.lanes=536870912,null}var c=r.children;return r=r.fallback,a?(mo(t),a=t.mode,c=jc({mode:`hidden`,children:c},a),r=_i(r,a,n,null),c.return=t,r.return=t,c.sibling=r,t.child=c,r=t.child,r.memoizedState=Dc(n),r.childLanes=Oc(e,s,n),t.memoizedState=Ec,gc(null,r)):(uo(t),Ac(t,c))}var l=e.memoizedState;if(l!==null&&(c=l.dehydrated,c!==null)){if(o)t.flags&256?(uo(t),t.flags&=-257,t=Mc(e,t,n)):t.memoizedState===null?(mo(t),c=r.fallback,a=t.mode,r=jc({mode:`visible`,children:r.children},a),c=_i(c,a,n,null),c.flags|=2,r.return=t,c.return=t,r.sibling=c,t.child=r,Ua(t,e.child,null,n),r=t.child,r.memoizedState=Dc(n),r.childLanes=Oc(e,s,n),t.memoizedState=Ec,t=gc(null,r)):(mo(t),t.child=e.child,t.flags|=128,t=null);else if(uo(t),vf(c)){if(s=c.nextSibling&&c.nextSibling.dataset,s)var u=s.dgst;s=u,r=Error(i(419)),r.stack=``,r.digest=s,Yi({value:r,source:null,stack:null}),t=Mc(e,t,n)}else if(uc||ra(e,t,n,!1),s=(n&e.childLanes)!==0,uc||s){if(s=Gl,s!==null&&(r=it(s,n),r!==0&&r!==l.retryLane))throw l.retryLane=r,si(e,r),Tu(s,e,r),lc;_f(c)||Lu(),t=Mc(e,t,n)}else _f(c)?(t.flags|=192,t.child=e.child,t=null):(e=l.treeContext,Ri=bf(c.nextSibling),Li=t,zi=!0,Bi=null,Vi=!1,e!==null&&Ii(t,e),t=Ac(t,r.children),t.flags|=4096);return t}return a?(mo(t),c=r.fallback,a=t.mode,l=e.child,u=l.sibling,r=mi(l,{mode:`hidden`,children:r.children}),r.subtreeFlags=l.subtreeFlags&65011712,u===null?(c=_i(c,a,n,null),c.flags|=2):c=mi(u,c),c.return=t,r.return=t,r.sibling=c,t.child=r,gc(null,r),r=t.child,c=e.child.memoizedState,c===null?c=Dc(n):(a=c.cachePool,a===null?a=Ea():(l=fa._currentValue,a=a.parent===l?a:{parent:l,pool:l}),c={baseLanes:c.baseLanes|n,cachePool:a}),r.memoizedState=c,r.childLanes=Oc(e,s,n),t.memoizedState=Ec,gc(e.child,r)):(uo(t),n=e.child,e=n.sibling,n=mi(n,{mode:`visible`,children:r.children}),n.return=t,n.sibling=null,e!==null&&(s=t.deletions,s===null?(t.deletions=[e],t.flags|=16):s.push(e)),t.child=n,t.memoizedState=null,n)}function Ac(e,t){return t=jc({mode:`visible`,children:t},e.mode),t.return=e,e.child=t}function jc(e,t){return e=fi(22,e,null,t),e.lanes=0,e}function Mc(e,t,n){return Ua(t,e.child,null,n),e=Ac(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Nc(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),ta(e.return,t,n)}function Pc(e,t,n,r,i,a){var o=e.memoizedState;o===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i,treeForkCount:a}:(o.isBackwards=t,o.rendering=null,o.renderingStartTime=0,o.last=r,o.tail=n,o.tailMode=i,o.treeForkCount=a)}function Fc(e,t,n){var r=t.pendingProps,i=r.revealOrder,a=r.tail;r=r.children;var o=go.current,s=(o&2)!=0;if(s?(o=o&1|2,t.flags|=128):o&=1,ce(go,o),dc(e,t,r,n),r=zi?Ei:0,!s&&e!==null&&e.flags&128)a:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Nc(e,n,t);else if(e.tag===19)Nc(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break a;for(;e.sibling===null;){if(e.return===null||e.return===t)break a;e=e.return}e.sibling.return=e.return,e=e.sibling}switch(i){case`forwards`:for(n=t.child,i=null;n!==null;)e=n.alternate,e!==null&&_o(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),Pc(t,!1,i,n,a,r);break;case`backwards`:case`unstable_legacy-backwards`:for(n=null,i=t.child,t.child=null;i!==null;){if(e=i.alternate,e!==null&&_o(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}Pc(t,!0,n,null,a,r);break;case`together`:Pc(t,!1,null,null,void 0,r);break;default:t.memoizedState=null}return t.child}function Ic(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),tu|=t.lanes,(n&t.childLanes)===0)if(e!==null){if(ra(e,t,n,!1),(n&t.childLanes)===0)return null}else return null;if(e!==null&&t.child!==e.child)throw Error(i(153));if(t.child!==null){for(e=t.child,n=mi(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=mi(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function Lc(e,t){return(e.lanes&t)===0?(e=e.dependencies,!!(e!==null&&ia(e))):!0}function Rc(e,t,n){switch(t.tag){case 3:pe(t,t.stateNode.containerInfo),$i(t,fa,e.memoizedState.cache),qi();break;case 27:case 5:he(t);break;case 4:pe(t,t.stateNode.containerInfo);break;case 10:$i(t,t.type,t.memoizedProps.value);break;case 31:if(t.memoizedState!==null)return t.flags|=128,fo(t),null;break;case 13:var r=t.memoizedState;if(r!==null)return r.dehydrated===null?(n&t.child.childLanes)===0?(uo(t),e=Ic(e,t,n),e===null?null:e.sibling):kc(e,t,n):(uo(t),t.flags|=128,null);uo(t);break;case 19:var i=(e.flags&128)!=0;if(r=(n&t.childLanes)!==0,r||=(ra(e,t,n,!1),(n&t.childLanes)!==0),i){if(r)return Fc(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),ce(go,go.current),r)break;return null;case 22:return t.lanes=0,hc(e,t,n,t.pendingProps);case 24:$i(t,fa,e.memoizedState.cache)}return Ic(e,t,n)}function zc(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps)uc=!0;else{if(!Lc(e,n)&&!(t.flags&128))return uc=!1,Rc(e,t,n);uc=!!(e.flags&131072)}else uc=!1,zi&&t.flags&1048576&&Ni(t,Ei,t.index);switch(t.lanes=0,t.tag){case 16:a:{var r=t.pendingProps;if(e=Na(t.elementType),t.type=e,typeof e==`function`)pi(e)?(r=$s(e,r),t.tag=1,t=wc(null,t,e,r,n)):(t.tag=0,t=Sc(null,t,e,r,n));else{if(e!=null){var a=e.$$typeof;if(a===w){t.tag=11,t=fc(null,t,e,r,n);break a}else if(a===D){t.tag=14,t=pc(null,t,e,r,n);break a}}throw t=ne(e)||e,Error(i(306,t,``))}}return t;case 0:return Sc(e,t,t.type,t.pendingProps,n);case 1:return r=t.type,a=$s(r,t.pendingProps),wc(e,t,r,a,n);case 3:a:{if(pe(t,t.stateNode.containerInfo),e===null)throw Error(i(387));r=t.pendingProps;var o=t.memoizedState;a=o.element,qa(e,t),eo(t,r,null,n);var s=t.memoizedState;if(r=s.cache,$i(t,fa,r),r!==o.cache&&na(t,[fa],n,!0),$a(),r=s.element,o.isDehydrated)if(o={element:r,isDehydrated:!1,cache:s.cache},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){t=Tc(e,t,r,n);break a}else if(r!==a){a=Si(Error(i(424)),t),Yi(a),t=Tc(e,t,r,n);break a}else{switch(e=t.stateNode.containerInfo,e.nodeType){case 9:e=e.body;break;default:e=e.nodeName===`HTML`?e.ownerDocument.body:e}for(Ri=bf(e.firstChild),Li=t,zi=!0,Bi=null,Vi=!0,n=Wa(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling}else{if(qi(),r===a){t=Ic(e,t,n);break a}dc(e,t,r,n)}t=t.child}return t;case 26:return xc(e,t),e===null?(n=Vf(t.type,null,t.pendingProps,null))?t.memoizedState=n:zi||(n=t.type,e=t.pendingProps,r=Qd(de.current).createElement(n),r[ut]=t,r[dt]=e,Kd(r,n,e),Ct(r),t.stateNode=r):t.memoizedState=Vf(t.type,e.memoizedProps,t.pendingProps,e.memoizedState),null;case 27:return he(t),e===null&&zi&&(r=t.stateNode=wf(t.type,t.pendingProps,de.current),Li=t,Vi=!0,a=Ri,uf(t.type)?(xf=a,Ri=bf(r.firstChild)):Ri=a),dc(e,t,t.pendingProps.children,n),xc(e,t),e===null&&(t.flags|=4194304),t.child;case 5:return e===null&&zi&&((a=r=Ri)&&(r=mf(r,t.type,t.pendingProps,Vi),r===null?a=!1:(t.stateNode=r,Li=t,Ri=bf(r.firstChild),Vi=!1,a=!0)),a||Ui(t)),he(t),a=t.type,o=t.pendingProps,s=e===null?null:e.memoizedProps,r=o.children,tf(a,o)?r=null:s!==null&&tf(a,s)&&(t.flags|=32),t.memoizedState!==null&&(a=Ao(e,t,No,null,null,n),up._currentValue=a),xc(e,t),dc(e,t,r,n),t.child;case 6:return e===null&&zi&&((e=n=Ri)&&(n=hf(n,t.pendingProps,Vi),n===null?e=!1:(t.stateNode=n,Li=t,Ri=null,e=!0)),e||Ui(t)),null;case 13:return kc(e,t,n);case 4:return pe(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Ua(t,null,r,n):dc(e,t,r,n),t.child;case 11:return fc(e,t,t.type,t.pendingProps,n);case 7:return dc(e,t,t.pendingProps,n),t.child;case 8:return dc(e,t,t.pendingProps.children,n),t.child;case 12:return dc(e,t,t.pendingProps.children,n),t.child;case 10:return r=t.pendingProps,$i(t,t.type,r.value),dc(e,t,r.children,n),t.child;case 9:return a=t.type._context,r=t.pendingProps.children,aa(t),a=oa(a),r=r(a),t.flags|=1,dc(e,t,r,n),t.child;case 14:return pc(e,t,t.type,t.pendingProps,n);case 15:return mc(e,t,t.type,t.pendingProps,n);case 19:return Fc(e,t,n);case 31:return bc(e,t,n);case 22:return hc(e,t,n,t.pendingProps);case 24:return aa(t),r=oa(fa),e===null?(a=wa(),a===null&&(a=Gl,o=pa(),a.pooledCache=o,o.refCount++,o!==null&&(a.pooledCacheLanes|=n),a=o),t.memoizedState={parent:r,cache:a},Ka(t),$i(t,fa,a)):((e.lanes&n)!==0&&(qa(e,t),eo(t,null,null,n),$a()),a=e.memoizedState,o=t.memoizedState,a.parent===r?(r=o.cache,$i(t,fa,r),r!==a.cache&&na(t,[fa],n,!0)):(a={parent:r,cache:r},t.memoizedState=a,t.lanes===0&&(t.memoizedState=t.updateQueue.baseState=a),$i(t,fa,r))),dc(e,t,t.pendingProps.children,n),t.child;case 29:throw t.pendingProps}throw Error(i(156,t.tag))}function Bc(e){e.flags|=4}function Vc(e,t,n,r,i){if((t=(e.mode&32)!=0)&&(t=!1),t){if(e.flags|=16777216,(i&335544128)===i)if(e.stateNode.complete)e.flags|=8192;else if(Pu())e.flags|=8192;else throw Pa=Aa,Oa}else e.flags&=-16777217}function Hc(e,t){if(t.type!==`stylesheet`||t.state.loading&4)e.flags&=-16777217;else if(e.flags|=16777216,!np(t))if(Pu())e.flags|=8192;else throw Pa=Aa,Oa}function Uc(e,t){t!==null&&(e.flags|=4),e.flags&16384&&(t=e.tag===22?536870912:Qe(),e.lanes|=t,au|=t)}function Wc(e,t){if(!zi)switch(e.tailMode){case`hidden`:t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case`collapsed`:n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function Gc(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags&65011712,r|=i.flags&65011712,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags,r|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function Kc(e,t,n){var r=t.pendingProps;switch(Fi(t),t.tag){case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Gc(t),null;case 1:return Gc(t),null;case 3:return n=t.stateNode,r=null,e!==null&&(r=e.memoizedState.cache),t.memoizedState.cache!==r&&(t.flags|=2048),ea(fa),me(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),(e===null||e.child===null)&&(Ki(t)?Bc(t):e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Ji())),Gc(t),null;case 26:var a=t.type,o=t.memoizedState;return e===null?(Bc(t),o===null?(Gc(t),Vc(t,a,null,r,n)):(Gc(t),Hc(t,o))):o?o===e.memoizedState?(Gc(t),t.flags&=-16777217):(Bc(t),Gc(t),Hc(t,o)):(e=e.memoizedProps,e!==r&&Bc(t),Gc(t),Vc(t,a,e,r,n)),null;case 27:if(ge(t),n=de.current,a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&Bc(t);else{if(!r){if(t.stateNode===null)throw Error(i(166));return Gc(t),null}e=le.current,Ki(t)?Wi(t,e):(e=wf(a,r,n),t.stateNode=e,Bc(t))}return Gc(t),null;case 5:if(ge(t),a=t.type,e!==null&&t.stateNode!=null)e.memoizedProps!==r&&Bc(t);else{if(!r){if(t.stateNode===null)throw Error(i(166));return Gc(t),null}if(o=le.current,Ki(t))Wi(t,o);else{var s=Qd(de.current);switch(o){case 1:o=s.createElementNS(`http://www.w3.org/2000/svg`,a);break;case 2:o=s.createElementNS(`http://www.w3.org/1998/Math/MathML`,a);break;default:switch(a){case`svg`:o=s.createElementNS(`http://www.w3.org/2000/svg`,a);break;case`math`:o=s.createElementNS(`http://www.w3.org/1998/Math/MathML`,a);break;case`script`:o=s.createElement(`div`),o.innerHTML=`<script><\/script>`,o=o.removeChild(o.firstChild);break;case`select`:o=typeof r.is==`string`?s.createElement(`select`,{is:r.is}):s.createElement(`select`),r.multiple?o.multiple=!0:r.size&&(o.size=r.size);break;default:o=typeof r.is==`string`?s.createElement(a,{is:r.is}):s.createElement(a)}}o[ut]=t,o[dt]=r;a:for(s=t.child;s!==null;){if(s.tag===5||s.tag===6)o.appendChild(s.stateNode);else if(s.tag!==4&&s.tag!==27&&s.child!==null){s.child.return=s,s=s.child;continue}if(s===t)break a;for(;s.sibling===null;){if(s.return===null||s.return===t)break a;s=s.return}s.sibling.return=s.return,s=s.sibling}t.stateNode=o;a:switch(Kd(o,a,r),a){case`button`:case`input`:case`select`:case`textarea`:r=!!r.autoFocus;break a;case`img`:r=!0;break a;default:r=!1}r&&Bc(t)}}return Gc(t),Vc(t,t.type,e===null?null:e.memoizedProps,t.pendingProps,n),null;case 6:if(e&&t.stateNode!=null)e.memoizedProps!==r&&Bc(t);else{if(typeof r!=`string`&&t.stateNode===null)throw Error(i(166));if(e=de.current,Ki(t)){if(e=t.stateNode,n=t.memoizedProps,r=null,a=Li,a!==null)switch(a.tag){case 27:case 5:r=a.memoizedProps}e[ut]=t,e=!!(e.nodeValue===n||r!==null&&!0===r.suppressHydrationWarning||Ud(e.nodeValue,n)),e||Ui(t,!0)}else e=Qd(e).createTextNode(r),e[ut]=t,t.stateNode=e}return Gc(t),null;case 31:if(n=t.memoizedState,e===null||e.memoizedState!==null){if(r=Ki(t),n!==null){if(e===null){if(!r)throw Error(i(318));if(e=t.memoizedState,e=e===null?null:e.dehydrated,!e)throw Error(i(557));e[ut]=t}else qi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Gc(t),e=!1}else n=Ji(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=n),e=!0;if(!e)return t.flags&256?(ho(t),t):(ho(t),null);if(t.flags&128)throw Error(i(558))}return Gc(t),null;case 13:if(r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(a=Ki(t),r!==null&&r.dehydrated!==null){if(e===null){if(!a)throw Error(i(318));if(a=t.memoizedState,a=a===null?null:a.dehydrated,!a)throw Error(i(317));a[ut]=t}else qi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Gc(t),a=!1}else a=Ji(),e!==null&&e.memoizedState!==null&&(e.memoizedState.hydrationErrors=a),a=!0;if(!a)return t.flags&256?(ho(t),t):(ho(t),null)}return ho(t),t.flags&128?(t.lanes=n,t):(n=r!==null,e=e!==null&&e.memoizedState!==null,n&&(r=t.child,a=null,r.alternate!==null&&r.alternate.memoizedState!==null&&r.alternate.memoizedState.cachePool!==null&&(a=r.alternate.memoizedState.cachePool.pool),o=null,r.memoizedState!==null&&r.memoizedState.cachePool!==null&&(o=r.memoizedState.cachePool.pool),o!==a&&(r.flags|=2048)),n!==e&&n&&(t.child.flags|=8192),Uc(t,t.updateQueue),Gc(t),null);case 4:return me(),e===null&&Nd(t.stateNode.containerInfo),Gc(t),null;case 10:return ea(t.type),Gc(t),null;case 19:if(se(go),r=t.memoizedState,r===null)return Gc(t),null;if(a=(t.flags&128)!=0,o=r.rendering,o===null)if(a)Wc(r,!1);else{if(eu!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=_o(e),o!==null){for(t.flags|=128,Wc(r,!1),e=o.updateQueue,t.updateQueue=e,Uc(t,e),t.subtreeFlags=0,e=n,n=t.child;n!==null;)hi(n,e),n=n.sibling;return ce(go,go.current&1|2),zi&&Mi(t,r.treeForkCount),t.child}e=e.sibling}r.tail!==null&&ke()>du&&(t.flags|=128,a=!0,Wc(r,!1),t.lanes=4194304)}else{if(!a)if(e=_o(o),e!==null){if(t.flags|=128,a=!0,e=e.updateQueue,t.updateQueue=e,Uc(t,e),Wc(r,!0),r.tail===null&&r.tailMode===`hidden`&&!o.alternate&&!zi)return Gc(t),null}else 2*ke()-r.renderingStartTime>du&&n!==536870912&&(t.flags|=128,a=!0,Wc(r,!1),t.lanes=4194304);r.isBackwards?(o.sibling=t.child,t.child=o):(e=r.last,e===null?t.child=o:e.sibling=o,r.last=o)}return r.tail===null?(Gc(t),null):(e=r.tail,r.rendering=e,r.tail=e.sibling,r.renderingStartTime=ke(),e.sibling=null,n=go.current,ce(go,a?n&1|2:n&1),zi&&Mi(t,r.treeForkCount),e);case 22:case 23:return ho(t),so(),r=t.memoizedState!==null,e===null?r&&(t.flags|=8192):e.memoizedState!==null!==r&&(t.flags|=8192),r?n&536870912&&!(t.flags&128)&&(Gc(t),t.subtreeFlags&6&&(t.flags|=8192)):Gc(t),n=t.updateQueue,n!==null&&Uc(t,n.retryQueue),n=null,e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),r=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(r=t.memoizedState.cachePool.pool),r!==n&&(t.flags|=2048),e!==null&&se(Ca),null;case 24:return n=null,e!==null&&(n=e.memoizedState.cache),t.memoizedState.cache!==n&&(t.flags|=2048),ea(fa),Gc(t),null;case 25:return null;case 30:return null}throw Error(i(156,t.tag))}function qc(e,t){switch(Fi(t),t.tag){case 1:return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return ea(fa),me(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 26:case 27:case 5:return ge(t),null;case 31:if(t.memoizedState!==null){if(ho(t),t.alternate===null)throw Error(i(340));qi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 13:if(ho(t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(i(340));qi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return se(go),null;case 4:return me(),null;case 10:return ea(t.type),null;case 22:case 23:return ho(t),so(),e!==null&&se(Ca),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 24:return ea(fa),null;case 25:return null;default:return null}}function Jc(e,t){switch(Fi(t),t.tag){case 3:ea(fa),me();break;case 26:case 27:case 5:ge(t);break;case 4:me();break;case 31:t.memoizedState!==null&&ho(t);break;case 13:ho(t);break;case 19:se(go);break;case 10:ea(t.type);break;case 22:case 23:ho(t),so(),e!==null&&se(Ca);break;case 24:ea(fa)}}function Yc(e,t){try{var n=t.updateQueue,r=n===null?null:n.lastEffect;if(r!==null){var i=r.next;n=i;do{if((n.tag&e)===e){r=void 0;var a=n.create,o=n.inst;r=a(),o.destroy=r}n=n.next}while(n!==i)}}catch(e){ed(t,t.return,e)}}function Xc(e,t,n){try{var r=t.updateQueue,i=r===null?null:r.lastEffect;if(i!==null){var a=i.next;r=a;do{if((r.tag&e)===e){var o=r.inst,s=o.destroy;if(s!==void 0){o.destroy=void 0,i=t;var c=n,l=s;try{l()}catch(e){ed(i,c,e)}}}r=r.next}while(r!==a)}}catch(e){ed(t,t.return,e)}}function Zc(e){var t=e.updateQueue;if(t!==null){var n=e.stateNode;try{no(t,n)}catch(t){ed(e,e.return,t)}}}function Qc(e,t,n){n.props=$s(e.type,e.memoizedProps),n.state=e.memoizedState;try{n.componentWillUnmount()}catch(n){ed(e,t,n)}}function $c(e,t){try{var n=e.ref;if(n!==null){switch(e.tag){case 26:case 27:case 5:var r=e.stateNode;break;case 30:r=e.stateNode;break;default:r=e.stateNode}typeof n==`function`?e.refCleanup=n(r):n.current=r}}catch(n){ed(e,t,n)}}function el(e,t){var n=e.ref,r=e.refCleanup;if(n!==null)if(typeof r==`function`)try{r()}catch(n){ed(e,t,n)}finally{e.refCleanup=null,e=e.alternate,e!=null&&(e.refCleanup=null)}else if(typeof n==`function`)try{n(null)}catch(n){ed(e,t,n)}else n.current=null}function tl(e){var t=e.type,n=e.memoizedProps,r=e.stateNode;try{a:switch(t){case`button`:case`input`:case`select`:case`textarea`:n.autoFocus&&r.focus();break a;case`img`:n.src?r.src=n.src:n.srcSet&&(r.srcset=n.srcSet)}}catch(t){ed(e,e.return,t)}}function nl(e,t,n){try{var r=e.stateNode;qd(r,e.type,n,t),r[dt]=t}catch(t){ed(e,e.return,t)}}function L(e){return e.tag===5||e.tag===3||e.tag===26||e.tag===27&&uf(e.type)||e.tag===4}function rl(e){a:for(;;){for(;e.sibling===null;){if(e.return===null||L(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.tag===27&&uf(e.type)||e.flags&2||e.child===null||e.tag===4)continue a;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function il(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?(n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n).insertBefore(e,t):(t=n.nodeType===9?n.body:n.nodeName===`HTML`?n.ownerDocument.body:n,t.appendChild(e),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=rn));else if(r!==4&&(r===27&&uf(e.type)&&(n=e.stateNode,t=null),e=e.child,e!==null))for(il(e,t,n),e=e.sibling;e!==null;)il(e,t,n),e=e.sibling}function al(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(r===27&&uf(e.type)&&(n=e.stateNode),e=e.child,e!==null))for(al(e,t,n),e=e.sibling;e!==null;)al(e,t,n),e=e.sibling}function ol(e){var t=e.stateNode,n=e.memoizedProps;try{for(var r=e.type,i=t.attributes;i.length;)t.removeAttributeNode(i[0]);Kd(t,r,n),t[ut]=e,t[dt]=n}catch(t){ed(e,e.return,t)}}var R=!1,sl=!1,cl=!1,ll=typeof WeakSet==`function`?WeakSet:Set,ul=null;function dl(e,t){if(e=e.containerInfo,Xd=yp,e=jr(e),Mr(e)){if(`selectionStart`in e)var n={start:e.selectionStart,end:e.selectionEnd};else a:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var a=r.anchorOffset,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break a}var s=0,c=-1,l=-1,u=0,d=0,f=e,p=null;b:for(;;){for(var m;f!==n||a!==0&&f.nodeType!==3||(c=s+a),f!==o||r!==0&&f.nodeType!==3||(l=s+r),f.nodeType===3&&(s+=f.nodeValue.length),(m=f.firstChild)!==null;)p=f,f=m;for(;;){if(f===e)break b;if(p===n&&++u===a&&(c=s),p===o&&++d===r&&(l=s),(m=f.nextSibling)!==null)break;f=p,p=f.parentNode}f=m}n=c===-1||l===-1?null:{start:c,end:l}}else n=null}n||={start:0,end:0}}else n=null;for(Zd={focusedElem:e,selectionRange:n},yp=!1,ul=t;ul!==null;)if(t=ul,e=t.child,t.subtreeFlags&1028&&e!==null)e.return=t,ul=e;else for(;ul!==null;){switch(t=ul,o=t.alternate,e=t.flags,t.tag){case 0:if(e&4&&(e=t.updateQueue,e=e===null?null:e.events,e!==null))for(n=0;n<e.length;n++)a=e[n],a.ref.impl=a.nextImpl;break;case 11:case 15:break;case 1:if(e&1024&&o!==null){e=void 0,n=t,a=o.memoizedProps,o=o.memoizedState,r=n.stateNode;try{var h=$s(n.type,a);e=r.getSnapshotBeforeUpdate(h,o),r.__reactInternalSnapshotBeforeUpdate=e}catch(e){ed(n,n.return,e)}}break;case 3:if(e&1024){if(e=t.stateNode.containerInfo,n=e.nodeType,n===9)pf(e);else if(n===1)switch(e.nodeName){case`HEAD`:case`HTML`:case`BODY`:pf(e);break;default:e.textContent=``}}break;case 5:case 26:case 27:case 6:case 4:case 17:break;default:if(e&1024)throw Error(i(163))}if(e=t.sibling,e!==null){e.return=t.return,ul=e;break}ul=t.return}}function fl(e,t,n){var r=n.flags;switch(n.tag){case 0:case 11:case 15:El(e,n),r&4&&Yc(5,n);break;case 1:if(El(e,n),r&4)if(e=n.stateNode,t===null)try{e.componentDidMount()}catch(e){ed(n,n.return,e)}else{var i=$s(n.type,t.memoizedProps);t=t.memoizedState;
vendor: 5,404 bytes, line 9
9try{e.componentDidUpdate(i,t,e.__reactInternalSnapshotBeforeUpdate)}catch(e){ed(n,n.return,e)}}r&64&&Zc(n),r&512&&$c(n,n.return);break;case 3:if(El(e,n),r&64&&(e=n.updateQueue,e!==null)){if(t=null,n.child!==null)switch(n.child.tag){case 27:case 5:t=n.child.stateNode;break;case 1:t=n.child.stateNode}try{no(e,t)}catch(e){ed(n,n.return,e)}}break;case 27:t===null&&r&4&&ol(n);case 26:case 5:El(e,n),t===null&&r&4&&tl(n),r&512&&$c(n,n.return);break;case 12:El(e,n);break;case 31:El(e,n),r&4&&_l(e,n);break;case 13:El(e,n),r&4&&vl(e,n),r&64&&(e=n.memoizedState,e!==null&&(e=e.dehydrated,e!==null&&(n=id.bind(null,n),yf(e,n))));break;case 22:if(r=n.memoizedState!==null||R,!r){t=t!==null&&t.memoizedState!==null||sl,i=R;var a=sl;R=r,(sl=t)&&!a?Dl(e,n,(n.subtreeFlags&8772)!=0):El(e,n),R=i,sl=a}break;case 30:break;default:El(e,n)}}function pl(e){var t=e.alternate;t!==null&&(e.alternate=null,pl(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&vt(t)),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}var ml=null,hl=!1;function gl(e,t,n){for(n=n.child;n!==null;)z(e,t,n),n=n.sibling}function z(e,t,n){if(ze&&typeof ze.onCommitFiberUnmount==`function`)try{ze.onCommitFiberUnmount(Re,n)}catch{}switch(n.tag){case 26:sl||el(n,t),gl(e,t,n),n.memoizedState?n.memoizedState.count--:n.stateNode&&(n=n.stateNode,n.parentNode.removeChild(n));break;case 27:sl||el(n,t);var r=ml,i=hl;uf(n.type)&&(ml=n.stateNode,hl=!1),gl(e,t,n),Tf(n.stateNode),ml=r,hl=i;break;case 5:sl||el(n,t);case 6:if(r=ml,i=hl,ml=null,gl(e,t,n),ml=r,hl=i,ml!==null)if(hl)try{(ml.nodeType===9?ml.body:ml.nodeName===`HTML`?ml.ownerDocument.body:ml).removeChild(n.stateNode)}catch(e){ed(n,t,e)}else try{ml.removeChild(n.stateNode)}catch(e){ed(n,t,e)}break;case 18:ml!==null&&(hl?(e=ml,df(e.nodeType===9?e.body:e.nodeName===`HTML`?e.ownerDocument.body:e,n.stateNode),Wp(e)):df(ml,n.stateNode));break;case 4:r=ml,i=hl,ml=n.stateNode.containerInfo,hl=!0,gl(e,t,n),ml=r,hl=i;break;case 0:case 11:case 14:case 15:Xc(2,n,t),sl||Xc(4,n,t),gl(e,t,n);break;case 1:sl||(el(n,t),r=n.stateNode,typeof r.componentWillUnmount==`function`&&Qc(n,t,r)),gl(e,t,n);break;case 21:gl(e,t,n);break;case 22:sl=(r=sl)||n.memoizedState!==null,gl(e,t,n),sl=r;break;default:gl(e,t,n)}}function _l(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null))){e=e.dehydrated;try{Wp(e)}catch(e){ed(t,t.return,e)}}}function vl(e,t){if(t.memoizedState===null&&(e=t.alternate,e!==null&&(e=e.memoizedState,e!==null&&(e=e.dehydrated,e!==null))))try{Wp(e)}catch(e){ed(t,t.return,e)}}function yl(e){switch(e.tag){case 31:case 13:case 19:var t=e.stateNode;return t===null&&(t=e.stateNode=new ll),t;case 22:return e=e.stateNode,t=e._retryCache,t===null&&(t=e._retryCache=new ll),t;default:throw Error(i(435,e.tag))}}function bl(e,t){var n=yl(e);t.forEach(function(t){if(!n.has(t)){n.add(t);var r=ad.bind(null,e,t);t.then(r,r)}})}function xl(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var a=n[r],o=e,s=t,c=s;a:for(;c!==null;){switch(c.tag){case 27:if(uf(c.type)){ml=c.stateNode,hl=!1;break a}break;case 5:ml=c.stateNode,hl=!1;break a;case 3:case 4:ml=c.stateNode.containerInfo,hl=!0;break a}c=c.return}if(ml===null)throw Error(i(160));z(o,s,a),ml=null,hl=!1,o=a.alternate,o!==null&&(o.return=null),a.return=null}if(t.subtreeFlags&13886)for(t=t.child;t!==null;)Cl(t,e),t=t.sibling}var Sl=null;function Cl(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:xl(t,e),wl(e),r&4&&(Xc(3,e,e.return),Yc(3,e),Xc(5,e,e.return));break;case 1:xl(t,e),wl(e),r&512&&(sl||n===null||el(n,n.return)),r&64&&R&&(e=e.updateQueue,e!==null&&(r=e.callbacks,r!==null&&(n=e.shared.hiddenCallbacks,e.shared.hiddenCallbacks=n===null?r:n.concat(r))));break;case 26:var a=Sl;if(xl(t,e),wl(e),r&512&&(sl||n===null||el(n,n.return)),r&4){var o=n===null?null:n.memoizedState;if(r=e.memoizedState,n===null)if(r===null)if(e.stateNode===null){a:{r=e.type,n=e.memoizedProps,a=a.ownerDocument||a;b:switch(r){case`title`:o=a.getElementsByTagName(`title`)[0],(!o||o[_t]||o[ut]||o.namespaceURI===`http://www.w3.org/2000/svg`||o.hasAttribute(`itemprop`))&&(o=a.createElement(r),a.head.insertBefore(o,a.querySelector(`head > title`))),Kd(o,r,n),o[ut]=e,Ct(o),r=o;break a;case`link`:var s=$f(`link`,`href`,a).get(r+(n.href||``));if(s){for(var c=0;c<s.length;c++)if(o=s[c],o.getAttribute(`href`)===(n.href==null||n.href===``?null:n.href)&&o.getAttribute(`rel`)===(n.rel==null?null:n.rel)&&o.getAttribute(`title`)===(n.title==null?null:n.title)&&o.getAttribute(`crossorigin`)===(n.crossOrigin==null?null:n.crossOrigin)){s.splice(c,1);break b}}o=a.createElement(r),Kd(o,r,n),a.head.appendChild(o);break;case`meta`:if(s=$f(`meta`,`content`,a).get(r+(n.content||``))){for(c=0;c<s.length;c++)if(o=s[c],o.getAttribute(`content`)===(n.content==null?null:``+n.content)&&o.getAttribute(`name`)===(n.name==null?null:n.name)&&o.getAttribute(`property`)===(n.property==null?null:n.property)&&o.getAttribute(`http-equiv`)===(n.httpEquiv==null?null:n.httpEquiv)&&o.getAttribute(`charset`)===(n.charSet==null?null:n.charSet)){s.splice(c,1);break b}}o=a.createElement(r),Kd(o,r,n),a.head.appendChild(o);break;default:throw Error(i(468,r))}o[ut]=e,Ct(o),r=o}e.stateNode=r}else ep(a,e.type,e.stateNode);else e.stateNode=Jf(a,r,e.memoizedProps);
vendor: 40,669 bytes, lines 9-10
9else o===r?r===null&&e.stateNode!==null&&nl(e,e.memoizedProps,n.memoizedProps):(o===null?n.stateNode!==null&&(n=n.stateNode,n.parentNode.removeChild(n)):o.count--,r===null?ep(a,e.type,e.stateNode):Jf(a,r,e.memoizedProps))}break;case 27:xl(t,e),wl(e),r&512&&(sl||n===null||el(n,n.return)),n!==null&&r&4&&nl(e,e.memoizedProps,n.memoizedProps);break;case 5:if(xl(t,e),wl(e),r&512&&(sl||n===null||el(n,n.return)),e.flags&32){a=e.stateNode;try{Yt(a,``)}catch(t){ed(e,e.return,t)}}r&4&&e.stateNode!=null&&(a=e.memoizedProps,nl(e,a,n===null?a:n.memoizedProps)),r&1024&&(cl=!0);break;case 6:if(xl(t,e),wl(e),r&4){if(e.stateNode===null)throw Error(i(162));r=e.memoizedProps,n=e.stateNode;try{n.nodeValue=r}catch(t){ed(e,e.return,t)}}break;case 3:if(Qf=null,a=Sl,Sl=Of(t.containerInfo),xl(t,e),Sl=a,wl(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{Wp(t.containerInfo)}catch(t){ed(e,e.return,t)}cl&&(cl=!1,Tl(e));break;case 4:r=Sl,Sl=Of(e.stateNode.containerInfo),xl(t,e),wl(e),Sl=r;break;case 12:xl(t,e),wl(e);break;case 31:xl(t,e),wl(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,bl(e,r)));break;case 13:xl(t,e),wl(e),e.child.flags&8192&&e.memoizedState!==null!=(n!==null&&n.memoizedState!==null)&&(lu=ke()),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,bl(e,r)));break;case 22:a=e.memoizedState!==null;var l=n!==null&&n.memoizedState!==null,u=R,d=sl;if(R=u||a,sl=d||l,xl(t,e),sl=d,R=u,wl(e),r&8192)a:for(t=e.stateNode,t._visibility=a?t._visibility&-2:t._visibility|1,a&&(n===null||l||R||sl||B(e)),n=null,t=e;;){if(t.tag===5||t.tag===26){if(n===null){l=n=t;try{if(o=l.stateNode,a)s=o.style,typeof s.setProperty==`function`?s.setProperty(`display`,`none`,`important`):s.display=`none`;else{c=l.stateNode;var f=l.memoizedProps.style,p=f!=null&&f.hasOwnProperty(`display`)?f.display:null;c.style.display=p==null||typeof p==`boolean`?``:(``+p).trim()}}catch(e){ed(l,l.return,e)}}}else if(t.tag===6){if(n===null){l=t;try{l.stateNode.nodeValue=a?``:l.memoizedProps}catch(e){ed(l,l.return,e)}}}else if(t.tag===18){if(n===null){l=t;try{var m=l.stateNode;a?ff(m,!0):ff(l.stateNode,!1)}catch(e){ed(l,l.return,e)}}}else if((t.tag!==22&&t.tag!==23||t.memoizedState===null||t===e)&&t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break a;for(;t.sibling===null;){if(t.return===null||t.return===e)break a;n===t&&(n=null),t=t.return}n===t&&(n=null),t.sibling.return=t.return,t=t.sibling}r&4&&(r=e.updateQueue,r!==null&&(n=r.retryQueue,n!==null&&(r.retryQueue=null,bl(e,n))));break;case 19:xl(t,e),wl(e),r&4&&(r=e.updateQueue,r!==null&&(e.updateQueue=null,bl(e,r)));break;case 30:break;case 21:break;default:xl(t,e),wl(e)}}function wl(e){var t=e.flags;if(t&2){try{for(var n,r=e.return;r!==null;){if(L(r)){n=r;break}r=r.return}if(n==null)throw Error(i(160));switch(n.tag){case 27:var a=n.stateNode;al(e,rl(e),a);break;case 5:var o=n.stateNode;n.flags&32&&(Yt(o,``),n.flags&=-33),al(e,rl(e),o);break;case 3:case 4:var s=n.stateNode.containerInfo;il(e,rl(e),s);break;default:throw Error(i(161))}}catch(t){ed(e,e.return,t)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function Tl(e){if(e.subtreeFlags&1024)for(e=e.child;e!==null;){var t=e;Tl(t),t.tag===5&&t.flags&1024&&t.stateNode.reset(),e=e.sibling}}function El(e,t){if(t.subtreeFlags&8772)for(t=t.child;t!==null;)fl(e,t.alternate,t),t=t.sibling}function B(e){for(e=e.child;e!==null;){var t=e;switch(t.tag){case 0:case 11:case 14:case 15:Xc(4,t,t.return),B(t);break;case 1:el(t,t.return);var n=t.stateNode;typeof n.componentWillUnmount==`function`&&Qc(t,t.return,n),B(t);break;case 27:Tf(t.stateNode);case 26:case 5:el(t,t.return),B(t);break;case 22:t.memoizedState===null&&B(t);break;case 30:B(t);break;default:B(t)}e=e.sibling}}function Dl(e,t,n){for(n&&=(t.subtreeFlags&8772)!=0,t=t.child;t!==null;){var r=t.alternate,i=e,a=t,o=a.flags;switch(a.tag){case 0:case 11:case 15:Dl(i,a,n),Yc(4,a);break;case 1:if(Dl(i,a,n),r=a,i=r.stateNode,typeof i.componentDidMount==`function`)try{i.componentDidMount()}catch(e){ed(r,r.return,e)}if(r=a,i=r.updateQueue,i!==null){var s=r.stateNode;try{var c=i.shared.hiddenCallbacks;if(c!==null)for(i.shared.hiddenCallbacks=null,i=0;i<c.length;i++)to(c[i],s)}catch(e){ed(r,r.return,e)}}n&&o&64&&Zc(a),$c(a,a.return);break;case 27:ol(a);case 26:case 5:Dl(i,a,n),n&&r===null&&o&4&&tl(a),$c(a,a.return);break;case 12:Dl(i,a,n);break;case 31:Dl(i,a,n),n&&o&4&&_l(i,a);break;case 13:Dl(i,a,n),n&&o&4&&vl(i,a);break;case 22:a.memoizedState===null&&Dl(i,a,n),$c(a,a.return);break;case 30:break;default:Dl(i,a,n)}t=t.sibling}}function Ol(e,t){var n=null;e!==null&&e.memoizedState!==null&&e.memoizedState.cachePool!==null&&(n=e.memoizedState.cachePool.pool),e=null,t.memoizedState!==null&&t.memoizedState.cachePool!==null&&(e=t.memoizedState.cachePool.pool),e!==n&&(e!=null&&e.refCount++,n!=null&&ma(n))}function kl(e,t){e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&ma(e))}function Al(e,t,n,r){if(t.subtreeFlags&10256)for(t=t.child;t!==null;)jl(e,t,n,r),t=t.sibling}function jl(e,t,n,r){var i=t.flags;switch(t.tag){case 0:case 11:case 15:Al(e,t,n,r),i&2048&&Yc(9,t);break;case 1:Al(e,t,n,r);break;case 3:Al(e,t,n,r),i&2048&&(e=null,t.alternate!==null&&(e=t.alternate.memoizedState.cache),t=t.memoizedState.cache,t!==e&&(t.refCount++,e!=null&&ma(e)));break;case 12:if(i&2048){Al(e,t,n,r),e=t.stateNode;try{var a=t.memoizedProps,o=a.id,s=a.onPostCommit;typeof s==`function`&&s(o,t.alternate===null?`mount`:`update`,e.passiveEffectDuration,-0)}catch(e){ed(t,t.return,e)}}else Al(e,t,n,r);break;case 31:Al(e,t,n,r);break;case 13:Al(e,t,n,r);break;case 23:break;case 22:a=t.stateNode,o=t.alternate,t.memoizedState===null?a._visibility&2?Al(e,t,n,r):(a._visibility|=2,Ml(e,t,n,r,(t.subtreeFlags&10256)!=0||!1)):a._visibility&2?Al(e,t,n,r):Nl(e,t),i&2048&&Ol(o,t);break;case 24:Al(e,t,n,r),i&2048&&kl(t.alternate,t);break;default:Al(e,t,n,r)}}function Ml(e,t,n,r,i){for(i&&=(t.subtreeFlags&10256)!=0||!1,t=t.child;t!==null;){var a=e,o=t,s=n,c=r,l=o.flags;switch(o.tag){case 0:case 11:case 15:Ml(a,o,s,c,i),Yc(8,o);break;case 23:break;case 22:var u=o.stateNode;o.memoizedState===null?(u._visibility|=2,Ml(a,o,s,c,i)):u._visibility&2?Ml(a,o,s,c,i):Nl(a,o),i&&l&2048&&Ol(o.alternate,o);break;case 24:Ml(a,o,s,c,i),i&&l&2048&&kl(o.alternate,o);break;default:Ml(a,o,s,c,i)}t=t.sibling}}function Nl(e,t){if(t.subtreeFlags&10256)for(t=t.child;t!==null;){var n=e,r=t,i=r.flags;switch(r.tag){case 22:Nl(n,r),i&2048&&Ol(r.alternate,r);break;case 24:Nl(n,r),i&2048&&kl(r.alternate,r);break;default:Nl(n,r)}t=t.sibling}}var Pl=8192;function Fl(e,t,n){if(e.subtreeFlags&Pl)for(e=e.child;e!==null;)Il(e,t,n),e=e.sibling}function Il(e,t,n){switch(e.tag){case 26:Fl(e,t,n),e.flags&Pl&&e.memoizedState!==null&&rp(n,Sl,e.memoizedState,e.memoizedProps);break;case 5:Fl(e,t,n);break;case 3:case 4:var r=Sl;Sl=Of(e.stateNode.containerInfo),Fl(e,t,n),Sl=r;break;case 22:e.memoizedState===null&&(r=e.alternate,r!==null&&r.memoizedState!==null?(r=Pl,Pl=16777216,Fl(e,t,n),Pl=r):Fl(e,t,n));break;default:Fl(e,t,n)}}function Ll(e){var t=e.alternate;if(t!==null&&(e=t.child,e!==null)){t.child=null;do t=e.sibling,e.sibling=null,e=t;while(e!==null)}}function Rl(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];ul=r,Vl(r,e)}Ll(e)}if(e.subtreeFlags&10256)for(e=e.child;e!==null;)zl(e),e=e.sibling}function zl(e){switch(e.tag){case 0:case 11:case 15:Rl(e),e.flags&2048&&Xc(9,e,e.return);break;case 3:Rl(e);break;case 12:Rl(e);break;case 22:var t=e.stateNode;e.memoizedState!==null&&t._visibility&2&&(e.return===null||e.return.tag!==13)?(t._visibility&=-3,Bl(e)):Rl(e);break;default:Rl(e)}}function Bl(e){var t=e.deletions;if(e.flags&16){if(t!==null)for(var n=0;n<t.length;n++){var r=t[n];ul=r,Vl(r,e)}Ll(e)}for(e=e.child;e!==null;){switch(t=e,t.tag){case 0:case 11:case 15:Xc(8,t,t.return),Bl(t);break;case 22:n=t.stateNode,n._visibility&2&&(n._visibility&=-3,Bl(t));break;default:Bl(t)}e=e.sibling}}function Vl(e,t){for(;ul!==null;){var n=ul;switch(n.tag){case 0:case 11:case 15:Xc(8,n,t);break;case 23:case 22:if(n.memoizedState!==null&&n.memoizedState.cachePool!==null){var r=n.memoizedState.cachePool.pool;r!=null&&r.refCount++}break;case 24:ma(n.memoizedState.cache)}if(r=n.child,r!==null)r.return=n,ul=r;else a:for(n=e;ul!==null;){r=ul;var i=r.sibling,a=r.return;if(pl(r),r===n){ul=null;break a}if(i!==null){i.return=a,ul=i;break a}ul=a}}}var Hl={getCacheForType:function(e){var t=oa(fa),n=t.data.get(e);return n===void 0&&(n=e(),t.data.set(e,n)),n},cacheSignal:function(){return oa(fa).controller.signal}},Ul=typeof WeakMap==`function`?WeakMap:Map,Wl=0,Gl=null,Kl=null,ql=0,Jl=0,Yl=null,Xl=!1,Zl=!1,Ql=!1,$l=0,eu=0,tu=0,nu=0,ru=0,iu=0,au=0,ou=null,su=null,cu=!1,lu=0,uu=0,du=1/0,fu=null,pu=null,mu=0,hu=null,gu=null,_u=0,vu=0,yu=null,bu=null,xu=0,Su=null;function Cu(){return Wl&2&&ql!==0?ql&-ql:M.T===null?st():xd()}function wu(){if(iu===0)if(!(ql&536870912)||zi){var e=Ke;Ke<<=1,!(Ke&3932160)&&(Ke=262144),iu=e}else iu=536870912;return e=co.current,e!==null&&(e.flags|=32),iu}function Tu(e,t,n){(e===Gl&&(Jl===2||Jl===9)||e.cancelPendingCommit!==null)&&(Mu(e,0),ku(e,ql,iu,!1)),et(e,n),(!(Wl&2)||e!==Gl)&&(e===Gl&&(!(Wl&2)&&(nu|=n),eu===4&&ku(e,ql,iu,!1)),pd(e))}function Eu(e,t,n){if(Wl&6)throw Error(i(327));var r=!n&&(t&127)==0&&(t&e.expiredLanes)===0||Xe(e,t),a=r?Bu(e,t):Ru(e,t,!0),o=r;do{if(a===0){Zl&&!r&&ku(e,t,0,!1);break}else{if(n=e.current.alternate,o&&!Ou(n)){a=Ru(e,t,!1),o=!1;continue}if(a===2){if(o=t,e.errorRecoveryDisabledLanes&o)var s=0;else s=e.pendingLanes&-536870913,s=s===0?s&536870912?536870912:0:s;if(s!==0){t=s;a:{var c=e;a=ou;var l=c.current.memoizedState.isDehydrated;if(l&&(Mu(c,s).flags|=256),s=Ru(c,s,!1),s!==2){if(Ql&&!l){c.errorRecoveryDisabledLanes|=o,nu|=o,a=4;break a}o=su,su=a,o!==null&&(su===null?su=o:su.push.apply(su,o))}a=s}if(o=!1,a!==2)continue}}if(a===1){Mu(e,0),ku(e,t,0,!0);break}a:{switch(r=e,o=a,o){case 0:case 1:throw Error(i(345));case 4:if((t&4194048)!==t)break;case 6:ku(r,t,iu,!Xl);break a;case 2:su=null;break;case 3:case 5:break;default:throw Error(i(329))}if((t&62914560)===t&&(a=lu+300-ke(),10<a)){if(ku(r,t,iu,!Xl),Ye(r,0,!0)!==0)break a;_u=t,r.timeoutHandle=af(Du.bind(null,r,n,su,fu,cu,t,iu,nu,au,Xl,o,`Throttled`,-0,0),a);break a}Du(r,n,su,fu,cu,t,iu,nu,au,Xl,o,null,-0,0)}}break}while(1);pd(e)}function Du(e,t,n,r,i,a,o,s,c,l,u,d,f,p){if(e.timeoutHandle=-1,d=t.subtreeFlags,d&8192||(d&16785408)==16785408){d={stylesheets:null,count:0,imgCount:0,imgBytes:0,suspenseyImages:[],waitingForImages:!0,waitingForViewTransition:!1,unsuspend:rn},Il(t,a,d);var m=(a&62914560)===a?lu-ke():(a&4194048)===a?uu-ke():0;if(m=ap(d,m),m!==null){_u=a,e.cancelPendingCommit=m(Ku.bind(null,e,t,a,n,r,i,o,s,c,u,d,null,f,p)),ku(e,a,o,!l);return}}Ku(e,t,a,n,r,i,o,s,c)}function Ou(e){for(var t=e;;){var n=t.tag;if((n===0||n===11||n===15)&&t.flags&16384&&(n=t.updateQueue,n!==null&&(n=n.stores,n!==null)))for(var r=0;r<n.length;r++){var i=n[r],a=i.getSnapshot;i=i.value;try{if(!Er(a(),i))return!1}catch{return!1}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function ku(e,t,n,r){t&=~ru,t&=~nu,e.suspendedLanes|=t,e.pingedLanes&=~t,r&&(e.warmLanes|=t),r=e.expirationTimes;for(var i=t;0<i;){var a=31-Ve(i),o=1<<a;r[a]=-1,i&=~o}n!==0&&nt(e,n,t)}function Au(){return Wl&6?!0:(md(0,!1),!1)}function ju(){if(Kl!==null){if(Jl===0)var e=Kl.return;else e=Kl,Qi=Zi=null,Io(e),La=null,Ra=0,e=Kl;for(;e!==null;)Jc(e.alternate,e),e=e.return;Kl=null}}function Mu(e,t){var n=e.timeoutHandle;n!==-1&&(e.timeoutHandle=-1,of(n)),n=e.cancelPendingCommit,n!==null&&(e.cancelPendingCommit=null,n()),_u=0,ju(),Gl=e,Kl=n=mi(e.current,null),ql=t,Jl=0,Yl=null,Xl=!1,Zl=Xe(e,t),Ql=!1,au=iu=ru=nu=tu=eu=0,su=ou=null,cu=!1,t&8&&(t|=t&32);var r=e.entangledLanes;if(r!==0)for(e=e.entanglements,r&=t;0<r;){var i=31-Ve(r),a=1<<i;t|=e[i],r&=~a}return $l=t,ii(),n}function Nu(e,t){yo=null,M.H=Gs,t===Da||t===ka?(t=Fa(),Jl=3):t===Oa?(t=Fa(),Jl=4):Jl=t===lc?8:typeof t==`object`&&t&&typeof t.then==`function`?6:1,Yl=t,Kl===null&&(eu=1,rc(e,Si(t,e.current)))}function Pu(){var e=co.current;return e===null?!0:(ql&4194048)===ql?lo===null:(ql&62914560)===ql||ql&536870912?e===lo:!1}function Fu(){var e=M.H;return M.H=Gs,e===null?Gs:e}function Iu(){var e=M.A;return M.A=Hl,e}function Lu(){eu=4,Xl||(ql&4194048)!==ql&&co.current!==null||(Zl=!0),!(tu&134217727)&&!(nu&134217727)||Gl===null||ku(Gl,ql,iu,!1)}function Ru(e,t,n){var r=Wl;Wl|=2;var i=Fu(),a=Iu();(Gl!==e||ql!==t)&&(fu=null,Mu(e,t)),t=!1;var o=eu;a:do try{if(Jl!==0&&Kl!==null){var s=Kl,c=Yl;switch(Jl){case 8:ju(),o=6;break a;case 3:case 2:case 9:case 6:co.current===null&&(t=!0);var l=Jl;if(Jl=0,Yl=null,Wu(e,s,c,l),n&&Zl){o=0;break a}break;default:l=Jl,Jl=0,Yl=null,Wu(e,s,c,l)}}zu(),o=eu;break}catch(t){Nu(e,t)}while(1);return t&&e.shellSuspendCounter++,Qi=Zi=null,Wl=r,M.H=i,M.A=a,Kl===null&&(Gl=null,ql=0,ii()),o}function zu(){for(;Kl!==null;)Hu(Kl)}function Bu(e,t){var n=Wl;Wl|=2;var r=Fu(),a=Iu();Gl!==e||ql!==t?(fu=null,du=ke()+500,Mu(e,t)):Zl=Xe(e,t);a:do try{if(Jl!==0&&Kl!==null){t=Kl;var o=Yl;b:switch(Jl){case 1:Jl=0,Yl=null,Wu(e,t,o,1);break;case 2:case 9:if(ja(o)){Jl=0,Yl=null,Uu(t);break}t=function(){Jl!==2&&Jl!==9||Gl!==e||(Jl=7),pd(e)},o.then(t,t);break a;case 3:Jl=7;break a;case 4:Jl=5;break a;case 7:ja(o)?(Jl=0,Yl=null,Uu(t)):(Jl=0,Yl=null,Wu(e,t,o,7));break;case 5:var s=null;switch(Kl.tag){case 26:s=Kl.memoizedState;case 5:case 27:var c=Kl;if(s?np(s):c.stateNode.complete){Jl=0,Yl=null;var l=c.sibling;if(l!==null)Kl=l;else{var u=c.return;u===null?Kl=null:(Kl=u,Gu(u))}break b}}Jl=0,Yl=null,Wu(e,t,o,5);break;case 6:Jl=0,Yl=null,Wu(e,t,o,6);break;case 8:ju(),eu=6;break a;default:throw Error(i(462))}}Vu();break}catch(t){Nu(e,t)}while(1);return Qi=Zi=null,M.H=r,M.A=a,Wl=n,Kl===null?(Gl=null,ql=0,ii(),eu):0}function Vu(){for(;Kl!==null&&!De();)Hu(Kl)}function Hu(e){var t=zc(e.alternate,e,$l);e.memoizedProps=e.pendingProps,t===null?Gu(e):Kl=t}function Uu(e){var t=e,n=t.alternate;switch(t.tag){case 15:case 0:t=Cc(n,t,t.pendingProps,t.type,void 0,ql);break;case 11:t=Cc(n,t,t.pendingProps,t.type.render,t.ref,ql);break;case 5:Io(t);default:Jc(n,t),t=Kl=hi(t,$l),t=zc(n,t,$l)}e.memoizedProps=e.pendingProps,t===null?Gu(e):Kl=t}function Wu(e,t,n,r){Qi=Zi=null,Io(t),La=null,Ra=0;var i=t.return;try{if(cc(e,i,t,n,ql)){eu=1,rc(e,Si(n,e.current)),Kl=null;return}}catch(t){if(i!==null)throw Kl=i,t;eu=1,rc(e,Si(n,e.current)),Kl=null;return}t.flags&32768?(zi||r===1?e=!0:Zl||ql&536870912?e=!1:(Xl=e=!0,(r===2||r===9||r===3||r===6)&&(r=co.current,r!==null&&r.tag===13&&(r.flags|=16384))),V(t,e)):Gu(t)}function Gu(e){var t=e;do{if(t.flags&32768){V(t,Xl);return}e=t.return;var n=Kc(t.alternate,t,$l);if(n!==null){Kl=n;return}if(t=t.sibling,t!==null){Kl=t;return}Kl=t=e}while(t!==null);eu===0&&(eu=5)}function V(e,t){do{var n=qc(e.alternate,e);if(n!==null){n.flags&=32767,Kl=n;return}if(n=e.return,n!==null&&(n.flags|=32768,n.subtreeFlags=0,n.deletions=null),!t&&(e=e.sibling,e!==null)){Kl=e;return}Kl=e=n}while(e!==null);eu=6,Kl=null}function Ku(e,t,n,r,a,o,s,c,l){e.cancelPendingCommit=null;do Zu();while(mu!==0);if(Wl&6)throw Error(i(327));if(t!==null){if(t===e.current)throw Error(i(177));if(o=t.lanes|t.childLanes,o|=ri,tt(e,n,o,s,c,l),e===Gl&&(Kl=Gl=null,ql=0),gu=t,hu=e,_u=n,vu=o,yu=a,bu=r,t.subtreeFlags&10256||t.flags&10256?(e.callbackNode=null,e.callbackPriority=0,od(Ne,function(){return Qu(),null})):(e.callbackNode=null,e.callbackPriority=0),r=(t.flags&13878)!=0,t.subtreeFlags&13878||r){r=M.T,M.T=null,a=N.p,N.p=2,s=Wl,Wl|=4;try{dl(e,t,n)}finally{Wl=s,N.p=a,M.T=r}}mu=1,qu(),Ju(),Yu()}}function qu(){if(mu===1){mu=0;var e=hu,t=gu,n=(t.flags&13878)!=0;if(t.subtreeFlags&13878||n){n=M.T,M.T=null;var r=N.p;N.p=2;var i=Wl;Wl|=4;try{Cl(t,e);var a=Zd,o=jr(e.containerInfo),s=a.focusedElem,c=a.selectionRange;if(o!==s&&s&&s.ownerDocument&&Ar(s.ownerDocument.documentElement,s)){if(c!==null&&Mr(s)){var l=c.start,u=c.end;if(u===void 0&&(u=l),`selectionStart`in s)s.selectionStart=l,s.selectionEnd=Math.min(u,s.value.length);else{var d=s.ownerDocument||document,f=d&&d.defaultView||window;if(f.getSelection){var p=f.getSelection(),m=s.textContent.length,h=Math.min(c.start,m),g=c.end===void 0?h:Math.min(c.end,m);!p.extend&&h>g&&(o=g,g=h,h=o);var _=kr(s,h),v=kr(s,g);if(_&&v&&(p.rangeCount!==1||p.anchorNode!==_.node||p.anchorOffset!==_.offset||p.focusNode!==v.node||p.focusOffset!==v.offset)){var y=d.createRange();y.setStart(_.node,_.offset),p.removeAllRanges(),h>g?(p.addRange(y),p.extend(v.node,v.offset)):(y.setEnd(v.node,v.offset),p.addRange(y))}}}}for(d=[],p=s;p=p.parentNode;)p.nodeType===1&&d.push({element:p,left:p.scrollLeft,top:p.scrollTop});for(typeof s.focus==`function`&&s.focus(),s=0;s<d.length;s++){var b=d[s];b.element.scrollLeft=b.left,b.element.scrollTop=b.top}}yp=!!Xd,Zd=Xd=null}finally{Wl=i,N.p=r,M.T=n}}e.current=t,mu=2}}function Ju(){if(mu===2){mu=0;var e=hu,t=gu,n=(t.flags&8772)!=0;if(t.subtreeFlags&8772||n){n=M.T,M.T=null;var r=N.p;N.p=2;var i=Wl;Wl|=4;try{fl(e,t.alternate,t)}finally{Wl=i,N.p=r,M.T=n}}mu=3}}function Yu(){if(mu===4||mu===3){mu=0,Oe();var e=hu,t=gu,n=_u,r=bu;t.subtreeFlags&10256||t.flags&10256?mu=5:(mu=0,gu=hu=null,Xu(e,e.pendingLanes));var i=e.pendingLanes;if(i===0&&(pu=null),ot(n),t=t.stateNode,ze&&typeof ze.onCommitFiberRoot==`function`)try{ze.onCommitFiberRoot(Re,t,void 0,(t.current.flags&128)==128)}catch{}if(r!==null){t=M.T,i=N.p,N.p=2,M.T=null;try{for(var a=e.onRecoverableError,o=0;o<r.length;o++){var s=r[o];a(s.value,{componentStack:s.stack})}}finally{M.T=t,N.p=i}}_u&3&&Zu(),pd(e),i=e.pendingLanes,n&261930&&i&42?e===Su?xu++:(xu=0,Su=e):xu=0,md(0,!1)}}function Xu(e,t){(e.pooledCacheLanes&=t)===0&&(t=e.pooledCache,t!=null&&(e.pooledCache=null,ma(t)))}function Zu(){return qu(),Ju(),Yu(),Qu()}function Qu(){if(mu!==5)return!1;var e=hu,t=vu;vu=0;var n=ot(_u),r=M.T,a=N.p;try{N.p=32>n?32:n,M.T=null,n=yu,yu=null;var o=hu,s=_u;if(mu=0,gu=hu=null,_u=0,Wl&6)throw Error(i(331));var c=Wl;if(Wl|=4,zl(o.current),jl(o,o.current,s,n),Wl=c,md(0,!1),ze&&typeof ze.onPostCommitFiberRoot==`function`)try{ze.onPostCommitFiberRoot(Re,o)}catch{}return!0}finally{N.p=a,M.T=r,Xu(e,t)}}function $u(e,t,n){t=Si(n,t),t=ac(e.stateNode,t,2),e=Ya(e,t,2),e!==null&&(et(e,2),pd(e))}function ed(e,t,n){if(e.tag===3)$u(e,e,n);else for(;t!==null;){if(t.tag===3){$u(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError==`function`||typeof r.componentDidCatch==`function`&&(pu===null||!pu.has(r))){e=Si(n,e),n=oc(2),r=Ya(t,n,2),r!==null&&(sc(n,r,t,e),et(r,2),pd(r));break}}t=t.return}}function td(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new Ul;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(Ql=!0,i.add(n),e=nd.bind(null,e,t,n),t.then(e,e))}function nd(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),e.pingedLanes|=e.suspendedLanes&n,e.warmLanes&=~n,Gl===e&&(ql&n)===n&&(eu===4||eu===3&&(ql&62914560)===ql&&300>ke()-lu?!(Wl&2)&&Mu(e,0):ru|=n,au===ql&&(au=0)),pd(e)}function rd(e,t){t===0&&(t=Qe()),e=si(e,t),e!==null&&(et(e,t),pd(e))}function id(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),rd(e,n)}function ad(e,t){var n=0;switch(e.tag){case 31:case 13:var r=e.stateNode,a=e.memoizedState;a!==null&&(n=a.retryLane);break;case 19:r=e.stateNode;break;case 22:r=e.stateNode._retryCache;break;default:throw Error(i(314))}r!==null&&r.delete(t),rd(e,n)}function od(e,t){return Te(e,t)}var sd=null,cd=null,ld=!1,ud=!1,dd=!1,fd=0;function pd(e){e!==cd&&e.next===null&&(cd===null?sd=cd=e:cd=cd.next=e),ud=!0,ld||(ld=!0,bd())}function md(e,t){if(!dd&&ud){dd=!0;do for(var n=!1,r=sd;r!==null;){if(!t)if(e!==0){var i=r.pendingLanes;if(i===0)var a=0;else{var o=r.suspendedLanes,s=r.pingedLanes;a=(1<<31-Ve(42|e)+1)-1,a&=i&~(o&~s),a=a&201326741?a&201326741|1:a?a|2:0}a!==0&&(n=!0,yd(r,a))}else a=ql,a=Ye(r,r===Gl?a:0,r.cancelPendingCommit!==null||r.timeoutHandle!==-1),!(a&3)||Xe(r,a)||(n=!0,yd(r,a));r=r.next}while(n);dd=!1}}function hd(){gd()}function gd(){ud=ld=!1;var e=0;fd!==0&&rf()&&(e=fd);for(var t=ke(),n=null,r=sd;r!==null;){var i=r.next,a=_d(r,t);a===0?(r.next=null,n===null?sd=i:n.next=i,i===null&&(cd=n)):(n=r,(e!==0||a&3)&&(ud=!0)),r=i}mu!==0&&mu!==5||md(e,!1),fd!==0&&(fd=0)}function _d(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes&-62914561;0<a;){var o=31-Ve(a),s=1<<o,c=i[o];c===-1?((s&n)===0||(s&r)!==0)&&(i[o]=Ze(s,t)):c<=t&&(e.expiredLanes|=s),a&=~s}if(t=Gl,n=ql,n=Ye(e,e===t?n:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r=e.callbackNode,n===0||e===t&&(Jl===2||Jl===9)||e.cancelPendingCommit!==null)return r!==null&&r!==null&&Ee(r),e.callbackNode=null,e.callbackPriority=0;if(!(n&3)||Xe(e,n)){if(t=n&-n,t===e.callbackPriority)return t;switch(r!==null&&Ee(r),ot(n)){case 2:case 8:n=Me;break;case 32:n=Ne;break;case 268435456:n=Fe;break;default:n=Ne}return r=vd.bind(null,e),n=Te(n,r),e.callbackPriority=t,e.callbackNode=n,t}return r!==null&&r!==null&&Ee(r),e.callbackPriority=2,e.callbackNode=null,2}function vd(e,t){if(mu!==0&&mu!==5)return e.callbackNode=null,e.callbackPriority=0,null;var n=e.callbackNode;if(Zu()&&e.callbackNode!==n)return null;var r=ql;return r=Ye(e,e===Gl?r:0,e.cancelPendingCommit!==null||e.timeoutHandle!==-1),r===0?null:(Eu(e,r,t),_d(e,ke()),e.callbackNode!=null&&e.callbackNode===n?vd.bind(null,e):null)}function yd(e,t){if(Zu())return null;Eu(e,t,!0)}function bd(){cf(function(){Wl&6?Te(je,hd):gd()})}function xd(){if(fd===0){var e=_a;e===0&&(e=Ge,Ge<<=1,!(Ge&261888)&&(Ge=256)),fd=e}return fd}function Sd(e){return e==null||typeof e==`symbol`||typeof e==`boolean`?null:typeof e==`function`?e:nn(``+e)}function Cd(e,t){var n=t.ownerDocument.createElement(`input`);return n.name=t.name,n.value=t.value,e.id&&n.setAttribute(`form`,e.id),t.parentNode.insertBefore(n,t),e=new FormData(e),n.parentNode.removeChild(n),e}function wd(e,t,n,r,i){if(t===`submit`&&n&&n.stateNode===i){var a=Sd((i[dt]||null).action),o=r.submitter;o&&(t=(t=o[dt]||null)?Sd(t.formAction):o.getAttribute(`formAction`),t!==null&&(a=t,o=null));var s=new Tn(`action`,`action`,null,r,i);e.push({event:s,listeners:[{instance:null,listener:function(){if(r.defaultPrevented){if(fd!==0){var e=o?Cd(i,o):new FormData(i);Ms(n,{pending:!0,data:e,method:i.method,action:a},null,e)}}else typeof a==`function`&&(s.preventDefault(),e=o?Cd(i,o):new FormData(i),Ms(n,{pending:!0,data:e,method:i.method,action:a},a,e))},currentTarget:i}]})}}for(var Td=0;Td<Qr.length;Td++){var Ed=Qr[Td];$r(Ed.toLowerCase(),`on`+(Ed[0].toUpperCase()+Ed.slice(1)))}$r(Wr,`onAnimationEnd`),$r(Gr,`onAnimationIteration`),$r(Kr,`onAnimationStart`),$r(`dblclick`,`onDoubleClick`),$r(`focusin`,`onFocus`),$r(`focusout`,`onBlur`),$r(qr,`onTransitionRun`),$r(Jr,`onTransitionStart`),$r(Yr,`onTransitionCancel`),$r(Xr,`onTransitionEnd`),Dt(`onMouseEnter`,[`mouseout`,`mouseover`]),Dt(`onMouseLeave`,[`mouseout`,`mouseover`]),Dt(`onPointerEnter`,[`pointerout`,`pointerover`]),Dt(`onPointerLeave`,[`pointerout`,`pointerover`]),Et(`onChange`,`change click focusin focusout input keydown keyup selectionchange`.split(` `)),Et(`onSelect`,`focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange`.split(` `)),Et(`onBeforeInput`,[`compositionend`,`keypress`,`textInput`,`paste`]),Et(`onCompositionEnd`,`compositionend focusout keydown keypress keyup mousedown`.split(` `)),Et(`onCompositionStart`,`compositionstart focusout keydown keypress keyup mousedown`.split(` `)),Et(`onCompositionUpdate`,`compositionupdate focusout keydown keypress keyup mousedown`.split(` `));var Dd=`abort canplay canplaythrough durationchange emptied encrypted ended error loadeddata loadedmetadata loadstart pause play playing progress ratechange resize seeked seeking stalled suspend timeupdate volumechange waiting`.split(` `),Od=new Set(`beforetoggle cancel close invalid load scroll scrollend toggle`.split(` `).concat(Dd));function kd(e,t){t=(t&4)!=0;for(var n=0;n<e.length;n++){var r=e[n],i=r.event;r=r.listeners;a:{var a=void 0;if(t)for(var o=r.length-1;0<=o;o--){var s=r[o],c=s.instance,l=s.currentTarget;if(s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){ei(e)}i.currentTarget=null,a=c}else for(o=0;o<r.length;o++){if(s=r[o],c=s.instance,l=s.currentTarget,s=s.listener,c!==a&&i.isPropagationStopped())break a;a=s,i.currentTarget=l;try{a(i)}catch(e){ei(e)}i.currentTarget=null,a=c}}}}function Ad(e,t){var n=t[pt];n===void 0&&(n=t[pt]=new Set);var r=e+`__bubble`;n.has(r)||(Pd(t,e,2,!1),n.add(r))}function jd(e,t,n){var r=0;t&&(r|=4),Pd(n,e,r,t)}var Md=`_reactListening`+Math.random().toString(36).slice(2);function Nd(e){if(!e[Md]){e[Md]=!0,wt.forEach(function(t){t!==`selectionchange`&&(Od.has(t)||jd(t,!1,e),jd(t,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Md]||(t[Md]=!0,jd(`selectionchange`,!1,t))}}function Pd(e,t,n,r){switch(Ep(t)){case 2:var i=bp;break;case 8:i=xp;break;default:i=Sp}n=i.bind(null,t,n,e),i=void 0,!mn||t!==`touchstart`&&t!==`touchmove`&&t!==`wheel`||(i=!0),r?i===void 0?e.addEventListener(t,n,!0):e.addEventListener(t,n,{capture:!0,passive:i}):i===void 0?e.addEventListener(t,n,!1):e.addEventListener(t,n,{passive:i})}function Fd(e,t,n,r,i){var a=r;if(!(t&1)&&!(t&2)&&r!==null)a:for(;;){if(r===null)return;var s=r.tag;if(s===3||s===4){var c=r.stateNode.containerInfo;if(c===i)break;if(s===4)for(s=r.return;s!==null;){var l=s.tag;if((l===3||l===4)&&s.stateNode.containerInfo===i)return;s=s.return}for(;c!==null;){if(s=yt(c),s===null)return;if(l=s.tag,l===5||l===6||l===26||l===27){r=a=s;continue a}c=c.parentNode}}r=r.return}dn(function(){var r=a,i=on(n),s=[];a:{var c=Zr.get(e);if(c!==void 0){var l=Tn,u=e;switch(e){case`keypress`:if(bn(n)===0)break a;case`keydown`:case`keyup`:l=Un;break;case`focusin`:u=`focus`,l=Pn;break;case`focusout`:u=`blur`,l=Pn;break;case`beforeblur`:case`afterblur`:l=Pn;break;case`click`:if(n.button===2)break a;case`auxclick`:case`dblclick`:case`mousedown`:case`mousemove`:case`mouseup`:case`mouseout`:case`mouseover`:case`contextmenu`:l=Mn;break;case`drag`:case`dragend`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`dragstart`:case`drop`:l=Nn;break;case`touchcancel`:case`touchend`:case`touchmove`:case`touchstart`:l=Gn;break;case Wr:case Gr:case Kr:l=Fn;break;case Xr:l=Kn;break;case`scroll`:case`scrollend`:l=Dn;break;case`wheel`:l=qn;break;case`copy`:case`cut`:case`paste`:l=In;break;case`gotpointercapture`:case`lostpointercapture`:case`pointercancel`:case`pointerdown`:case`pointermove`:case`pointerout`:case`pointerover`:case`pointerup`:l=Wn;break;case`toggle`:case`beforetoggle`:l=Jn}var d=(t&4)!=0,f=!d&&(e===`scroll`||e===`scrollend`),p=d?c===null?null:c+`Capture`:c;d=[];for(var m=r,h;m!==null;){var g=m;if(h=g.stateNode,g=g.tag,g!==5&&g!==26&&g!==27||h===null||p===null||(g=fn(m,p),g!=null&&d.push(Id(m,g,h))),f)break;m=m.return}0<d.length&&(c=new l(c,u,null,n,i),s.push({event:c,listeners:d}))}}if(!(t&7)){a:{if(c=e===`mouseover`||e===`pointerover`,l=e===`mouseout`||e===`pointerout`,c&&n!==an&&(u=n.relatedTarget||n.fromElement)&&(yt(u)||u[ft]))break a;if((l||c)&&(c=i.window===i?i:(c=i.ownerDocument)?c.defaultView||c.parentWindow:window,l?(u=n.relatedTarget||n.toElement,l=r,u=u?yt(u):null,u!==null&&(f=o(u),d=u.tag,u!==f||d!==5&&d!==27&&d!==6)&&(u=null)):(l=null,u=r),l!==u)){if(d=Mn,g=`onMouseLeave`,p=`onMouseEnter`,m=`mouse`,(e===`pointerout`||e===`pointerover`)&&(d=Wn,g=`onPointerLeave`,p=`onPointerEnter`,m=`pointer`),f=l==null?c:xt(l),h=u==null?c:xt(u),c=new d(g,m+`leave`,l,n,i),c.target=f,c.relatedTarget=h,g=null,yt(i)===r&&(d=new d(p,m+`enter`,u,n,i),d.target=h,d.relatedTarget=f,g=d),f=g,l&&u)b:{for(d=Rd,p=l,m=u,h=0,g=p;g;g=d(g))h++;g=0;for(var _=m;_;_=d(_))g++;for(;0<h-g;)p=d(p),h--;for(;0<g-h;)m=d(m),g--;for(;h--;){if(p===m||m!==null&&p===m.alternate){d=p;break b}p=d(p),m=d(m)}d=null}else d=null;l!==null&&zd(s,c,l,d,!1),u!==null&&f!==null&&zd(s,f,u,d,!0)}}a:{if(c=r?xt(r):window,l=c.nodeName&&c.nodeName.toLowerCase(),l===`select`||l===`input`&&c.type===`file`)var v=mr;else if(cr(c))if(hr)v=wr;else{v=Sr;var y=xr}else l=c.nodeName,!l||l.toLowerCase()!==`input`||c.type!==`checkbox`&&c.type!==`radio`?r&&$t(r.elementType)&&(v=mr):v=Cr;if(v&&=v(e,r)){lr(s,v,n,i);break a}y&&y(e,c,r),e===`focusout`&&r&&c.type===`number`&&r.memoizedProps.value!=null&&Gt(c,`number`,c.value)}switch(y=r?xt(r):window,e){case`focusin`:(cr(y)||y.contentEditable===`true`)&&(Pr=y,Fr=r,Ir=null);break;case`focusout`:Ir=Fr=Pr=null;break;case`mousedown`:Lr=!0;break;case`contextmenu`:case`mouseup`:case`dragend`:Lr=!1,Rr(s,n,i);break;case`selectionchange`:if(Nr)break;case`keydown`:case`keyup`:Rr(s,n,i)}var b;if(Xn)b:{switch(e){case`compositionstart`:var x=`onCompositionStart`;break b;case`compositionend`:x=`onCompositionEnd`;break b;case`compositionupdate`:x=`onCompositionUpdate`;break b}x=void 0}else ir?nr(e,n)&&(x=`onCompositionEnd`):e===`keydown`&&n.keyCode===229&&(x=`onCompositionStart`);x&&($n&&n.locale!==`ko`&&(ir||x!==`onCompositionStart`?x===`onCompositionEnd`&&ir&&(b=yn()):(gn=i,_n=`value`in gn?gn.value:gn.textContent,ir=!0)),y=Ld(r,x),0<y.length&&(x=new Ln(x,e,null,n,i),s.push({event:x,listeners:y}),b?x.data=b:(b=rr(n),b!==null&&(x.data=b)))),(b=Qn?ar(e,n):or(e,n))&&(x=Ld(r,`onBeforeInput`),0<x.length&&(y=new Ln(`onBeforeInput`,`beforeinput`,null,n,i),s.push({event:y,listeners:x}),y.data=b)),wd(s,e,r,n,i)}kd(s,t)})}function Id(e,t,n){return{instance:e,listener:t,currentTarget:n}}function Ld(e,t){for(var n=t+`Capture`,r=[];e!==null;){var i=e,a=i.stateNode;if(i=i.tag,i!==5&&i!==26&&i!==27||a===null||(i=fn(e,n),i!=null&&r.unshift(Id(e,i,a)),i=fn(e,t),i!=null&&r.push(Id(e,i,a))),e.tag===3)return r;e=e.return}return[]}function Rd(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5&&e.tag!==27);return e||null}function zd(e,t,n,r,i){for(var a=t._reactName,o=[];n!==null&&n!==r;){var s=n,c=s.alternate,l=s.stateNode;if(s=s.tag,c!==null&&c===r)break;s!==5&&s!==26&&s!==27||l===null||(c=l,i?(l=fn(n,a),l!=null&&o.unshift(Id(n,l,c))):i||(l=fn(n,a),l!=null&&o.push(Id(n,l,c)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var Bd=/\r\n?/g,Vd=/\u0000|\uFFFD/g;function Hd(e){return(typeof e==`string`?e:``+e).replace(Bd,` 10`).replace(Vd,``)}function Ud(e,t){return t=Hd(t),Hd(e)===t}function Wd(e,t,n,r,a,o){switch(n){case`children`:typeof r==`string`?t===`body`||t===`textarea`&&r===``||Yt(e,r):(typeof r==`number`||typeof r==`bigint`)&&t!==`body`&&Yt(e,``+r);break;case`className`:Nt(e,`class`,r);break;case`tabIndex`:Nt(e,`tabindex`,r);break;case`dir`:case`role`:case`viewBox`:case`width`:case`height`:Nt(e,n,r);break;case`style`:Qt(e,r,o);break;case`data`:if(t!==`object`){Nt(e,`data`,r);break}case`src`:case`href`:if(r===``&&(t!==`a`||n!==`href`)){e.removeAttribute(n);break}if(r==null||typeof r==`function`||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=nn(``+r),e.setAttribute(n,r);break;case`action`:case`formAction`:if(typeof r==`function`){e.setAttribute(n,`javascript:throw new Error('A React form was unexpectedly submitted. If you called form.submit() manually, consider using form.requestSubmit() instead. If you\\'re trying to use event.stopPropagation() in a submit event handler, consider also calling event.preventDefault().')`);break}else typeof o==`function`&&(n===`formAction`?(t!==`input`&&Wd(e,t,`name`,a.name,a,null),Wd(e,t,`formEncType`,a.formEncType,a,null),Wd(e,t,`formMethod`,a.formMethod,a,null),Wd(e,t,`formTarget`,a.formTarget,a,null)):(Wd(e,t,`encType`,a.encType,a,null),Wd(e,t,`method`,a.method,a,null),Wd(e,t,`target`,a.target,a,null)));if(r==null||typeof r==`symbol`||typeof r==`boolean`){e.removeAttribute(n);break}r=nn(``+r),e.setAttribute(n,r);break;case`onClick`:r!=null&&(e.onclick=rn);break;case`onScroll`:r!=null&&Ad(`scroll`,e);break;case`onScrollEnd`:r!=null&&Ad(`scrollend`,e);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(i(61));if(n=r.__html,n!=null){if(a.children!=null)throw Error(i(60));e.innerHTML=n}}break;case`multiple`:e.multiple=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`muted`:e.muted=r&&typeof r!=`function`&&typeof r!=`symbol`;break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`defaultValue`:case`defaultChecked`:case`innerHTML`:case`ref`:break;case`autoFocus`:break;case`xlinkHref`:if(r==null||typeof r==`function`||typeof r==`boolean`||typeof r==`symbol`){e.removeAttribute(`xlink:href`);break}n=nn(``+r),e.setAttributeNS(`http://www.w3.org/1999/xlink`,`xlink:href`,n);break;case`contentEditable`:case`spellCheck`:case`draggable`:case`value`:case`autoReverse`:case`externalResourcesRequired`:case`focusable`:case`preserveAlpha`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``+r):e.removeAttribute(n);break;case`inert`:case`allowFullScreen`:case`async`:case`autoPlay`:case`controls`:case`default`:case`defer`:case`disabled`:case`disablePictureInPicture`:case`disableRemotePlayback`:case`formNoValidate`:case`hidden`:case`loop`:case`noModule`:case`noValidate`:case`open`:case`playsInline`:case`readOnly`:case`required`:case`reversed`:case`scoped`:case`seamless`:case`itemScope`:r&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,``):e.removeAttribute(n);break;case`capture`:case`download`:!0===r?e.setAttribute(n,``):!1!==r&&r!=null&&typeof r!=`function`&&typeof r!=`symbol`?e.setAttribute(n,r):e.removeAttribute(n);break;case`cols`:case`rows`:case`size`:case`span`:r!=null&&typeof r!=`function`&&typeof r!=`symbol`&&!isNaN(r)&&1<=r?e.setAttribute(n,r):e.removeAttribute(n);break;case`rowSpan`:case`start`:r==null||typeof r==`function`||typeof r==`symbol`||isNaN(r)?e.removeAttribute(n):e.setAttribute(n,r);break;case`popover`:Ad(`beforetoggle`,e),Ad(`toggle`,e),Mt(e,`popover`,r);break;case`xlinkActuate`:Pt(e,`http://www.w3.org/1999/xlink`,`xlink:actuate`,r);break;case`xlinkArcrole`:Pt(e,`http://www.w3.org/1999/xlink`,`xlink:arcrole`,r);break;case`xlinkRole`:Pt(e,`http://www.w3.org/1999/xlink`,`xlink:role`,r);break;case`xlinkShow`:Pt(e,`http://www.w3.org/1999/xlink`,`xlink:show`,r);break;case`xlinkTitle`:Pt(e,`http://www.w3.org/1999/xlink`,`xlink:title`,r);break;case`xlinkType`:Pt(e,`http://www.w3.org/1999/xlink`,`xlink:type`,r);break;case`xmlBase`:Pt(e,`http://www.w3.org/XML/1998/namespace`,`xml:base`,r);break;case`xmlLang`:Pt(e,`http://www.w3.org/XML/1998/namespace`,`xml:lang`,r);break;case`xmlSpace`:Pt(e,`http://www.w3.org/XML/1998/namespace`,`xml:space`,r);break;case`is`:Mt(e,`is`,r);break;case`innerText`:case`textContent`:break;default:(!(2<n.length)||n[0]!==`o`&&n[0]!==`O`||n[1]!==`n`&&n[1]!==`N`)&&(n=en.get(n)||n,Mt(e,n,r))}}function Gd(e,t,n,r,a,o){switch(n){case`style`:Qt(e,r,o);break;case`dangerouslySetInnerHTML`:if(r!=null){if(typeof r!=`object`||!(`__html`in r))throw Error(i(61));if(n=r.__html,n!=null){if(a.children!=null)throw Error(i(60));e.innerHTML=n}}break;case`children`:typeof r==`string`?Yt(e,r):(typeof r==`number`||typeof r==`bigint`)&&Yt(e,``+r);break;case`onScroll`:r!=null&&Ad(`scroll`,e);break;case`onScrollEnd`:r!=null&&Ad(`scrollend`,e);break;case`onClick`:r!=null&&(e.onclick=rn);break;case`suppressContentEditableWarning`:case`suppressHydrationWarning`:case`innerHTML`:case`ref`:break;case`innerText`:case`textContent`:break;default:if(!Tt.hasOwnProperty(n))a:{if(n[0]===`o`&&n[1]===`n`&&(a=n.endsWith(`Capture`),t=n.slice(2,a?n.length-7:void 0),o=e[dt]||null,o=o==null?null:o[n],typeof o==`function`&&e.removeEventListener(t,o,a),typeof r==`function`)){typeof o!=`function`&&o!==null&&(n in e?e[n]=null:e.hasAttribute(n)&&e.removeAttribute(n)),e.addEventListener(t,r,a);break a}n in e?e[n]=r:!0===r?e.setAttribute(n,``):Mt(e,n,r)}}}function Kd(e,t,n){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`img`:Ad(`error`,e),Ad(`load`,e);var r=!1,a=!1,o;for(o in n)if(n.hasOwnProperty(o)){var s=n[o];if(s!=null)switch(o){case`src`:r=!0;break;case`srcSet`:a=!0;break;case`children`:case`dangerouslySetInnerHTML`:throw Error(i(137,t));default:Wd(e,t,o,s,n,null)}}a&&Wd(e,t,`srcSet`,n.srcSet,n,null),r&&Wd(e,t,`src`,n.src,n,null);return;case`input`:Ad(`invalid`,e);var c=o=s=a=null,l=null,u=null;for(r in n)if(n.hasOwnProperty(r)){var d=n[r];if(d!=null)switch(r){case`name`:a=d;break;case`type`:s=d;break;case`checked`:l=d;break;case`defaultChecked`:u=d;break;case`value`:o=d;break;case`defaultValue`:c=d;break;case`children`:case`dangerouslySetInnerHTML`:if(d!=null)throw Error(i(137,t));break;default:Wd(e,t,r,d,n,null)}}Wt(e,o,c,l,u,s,a,!1);return;case`select`:for(a in Ad(`invalid`,e),r=s=o=null,n)if(n.hasOwnProperty(a)&&(c=n[a],c!=null))switch(a){case`value`:o=c;break;case`defaultValue`:s=c;break;case`multiple`:r=c;default:Wd(e,t,a,c,n,null)}t=o,n=s,e.multiple=!!r,t==null?n!=null&&Kt(e,!!r,n,!0):Kt(e,!!r,t,!1);return;case`textarea`:for(s in Ad(`invalid`,e),o=a=r=null,n)if(n.hasOwnProperty(s)&&(c=n[s],c!=null))switch(s){case`value`:r=c;break;case`defaultValue`:a=c;break;case`children`:o=c;break;case`dangerouslySetInnerHTML`:if(c!=null)throw Error(i(91));break;default:Wd(e,t,s,c,n,null)}Jt(e,r,a,o);return;case`option`:for(l in n)if(n.hasOwnProperty(l)&&(r=n[l],r!=null))switch(l){case`selected`:e.selected=r&&typeof r!=`function`&&typeof r!=`symbol`;break;default:Wd(e,t,l,r,n,null)}return;case`dialog`:Ad(`beforetoggle`,e),Ad(`toggle`,e),Ad(`cancel`,e),Ad(`close`,e);break;case`iframe`:case`object`:Ad(`load`,e);break;case`video`:case`audio`:for(r=0;r<Dd.length;r++)Ad(Dd[r],e);break;case`image`:Ad(`error`,e),Ad(`load`,e);break;case`details`:Ad(`toggle`,e);break;case`embed`:case`source`:case`link`:Ad(`error`,e),Ad(`load`,e);case`area`:case`base`:case`br`:case`col`:case`hr`:case`keygen`:case`meta`:case`param`:case`track`:case`wbr`:case`menuitem`:for(u in n)if(n.hasOwnProperty(u)&&(r=n[u],r!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:throw Error(i(137,t));default:Wd(e,t,u,r,n,null)}return;default:if($t(t)){for(d in n)n.hasOwnProperty(d)&&(r=n[d],r!==void 0&&Gd(e,t,d,r,n,void 0));return}}for(c in n)n.hasOwnProperty(c)&&(r=n[c],r!=null&&Wd(e,t,c,r,n,null))}function qd(e,t,n,r){switch(t){case`div`:case`span`:case`svg`:case`path`:case`a`:case`g`:case`p`:case`li`:break;case`input`:var a=null,o=null,s=null,c=null,l=null,u=null,d=null;for(m in n){var f=n[m];if(n.hasOwnProperty(m)&&f!=null)switch(m){case`checked`:break;case`value`:break;case`defaultValue`:l=f;default:r.hasOwnProperty(m)||Wd(e,t,m,null,r,f)}}for(var p in r){var m=r[p];if(f=n[p],r.hasOwnProperty(p)&&(m!=null||f!=null))switch(p){case`type`:o=m;break;case`name`:a=m;break;case`checked`:u=m;break;case`defaultChecked`:d=m;break;case`value`:s=m;break;case`defaultValue`:c=m;break;case`children`:case`dangerouslySetInnerHTML`:if(m!=null)throw Error(i(137,t));break;default:m!==f&&Wd(e,t,p,m,r,f)}}Ut(e,s,c,l,u,d,o,a);return;case`select`:for(o in m=s=c=p=null,n)if(l=n[o],n.hasOwnProperty(o)&&l!=null)switch(o){case`value`:break;case`multiple`:m=l;default:r.hasOwnProperty(o)||Wd(e,t,o,null,r,l)}for(a in r)if(o=r[a],l=n[a],r.hasOwnProperty(a)&&(o!=null||l!=null))switch(a){case`value`:p=o;break;case`defaultValue`:c=o;break;case`multiple`:s=o;default:o!==l&&Wd(e,t,a,o,r,l)}t=c,n=s,r=m,p==null?!!r!=!!n&&(t==null?Kt(e,!!n,n?[]:``,!1):Kt(e,!!n,t,!0)):Kt(e,!!n,p,!1);return;case`textarea`:for(c in m=p=null,n)if(a=n[c],n.hasOwnProperty(c)&&a!=null&&!r.hasOwnProperty(c))switch(c){case`value`:break;case`children`:break;default:Wd(e,t,c,null,r,a)}for(s in r)if(a=r[s],o=n[s],r.hasOwnProperty(s)&&(a!=null||o!=null))switch(s){case`value`:p=a;break;case`defaultValue`:m=a;break;case`children`:break;case`dangerouslySetInnerHTML`:if(a!=null)throw Error(i(91));break;default:a!==o&&Wd(e,t,s,a,r,o)}qt(e,p,m);return;case`option`:for(var h in n)if(p=n[h],n.hasOwnProperty(h)&&p!=null&&!r.hasOwnProperty(h))switch(h){case`selected`:e.selected=!1;break;default:Wd(e,t,h,null,r,p)}for(l in r)if(p=r[l],m=n[l],r.hasOwnProperty(l)&&p!==m&&(p!=null||m!=null))switch(l){case`selected`:e.selected=p&&typeof p!=`function`&&typeof p!=`symbol`;break;default:Wd(e,t,l,p,r,m)}return;case`img`:case`link`:case`area`:case`base`:case`br`:case`col`:case`embed`:case`hr`:case`keygen`:case`meta`:case`param`:case`source`:case`track`:case`wbr`:case`menuitem`:for(var g in n)p=n[g],n.hasOwnProperty(g)&&p!=null&&!r.hasOwnProperty(g)&&Wd(e,t,g,null,r,p);for(u in r)if(p=r[u],m=n[u],r.hasOwnProperty(u)&&p!==m&&(p!=null||m!=null))switch(u){case`children`:case`dangerouslySetInnerHTML`:if(p!=null)throw Error(i(137,t));break;default:Wd(e,t,u,p,r,m)}return;default:if($t(t)){for(var _ in n)p=n[_],n.hasOwnProperty(_)&&p!==void 0&&!r.hasOwnProperty(_)&&Gd(e,t,_,void 0,r,p);
vendor: 4,463 bytes, line 10
10for(d in r)p=r[d],m=n[d],!r.hasOwnProperty(d)||p===m||p===void 0&&m===void 0||Gd(e,t,d,p,r,m);return}}for(var v in n)p=n[v],n.hasOwnProperty(v)&&p!=null&&!r.hasOwnProperty(v)&&Wd(e,t,v,null,r,p);for(f in r)p=r[f],m=n[f],!r.hasOwnProperty(f)||p===m||p==null&&m==null||Wd(e,t,f,p,r,m)}function Jd(e){switch(e){case`css`:case`script`:case`font`:case`img`:case`image`:case`input`:case`link`:return!0;default:return!1}}function Yd(){if(typeof performance.getEntriesByType==`function`){for(var e=0,t=0,n=performance.getEntriesByType(`resource`),r=0;r<n.length;r++){var i=n[r],a=i.transferSize,o=i.initiatorType,s=i.duration;if(a&&s&&Jd(o)){for(o=0,s=i.responseEnd,r+=1;r<n.length;r++){var c=n[r],l=c.startTime;if(l>s)break;var u=c.transferSize,d=c.initiatorType;u&&Jd(d)&&(c=c.responseEnd,o+=u*(c<s?1:(s-l)/(c-l)))}if(--r,t+=8*(a+o)/(i.duration/1e3),e++,10<e)break}}if(0<e)return t/e/1e6}return navigator.connection&&(e=navigator.connection.downlink,typeof e==`number`)?e:5}var Xd=null,Zd=null;function Qd(e){return e.nodeType===9?e:e.ownerDocument}function $d(e){switch(e){case`http://www.w3.org/2000/svg`:return 1;case`http://www.w3.org/1998/Math/MathML`:return 2;default:return 0}}function ef(e,t){if(e===0)switch(t){case`svg`:return 1;case`math`:return 2;default:return 0}return e===1&&t===`foreignObject`?0:e}function tf(e,t){return e===`textarea`||e===`noscript`||typeof t.children==`string`||typeof t.children==`number`||typeof t.children==`bigint`||typeof t.dangerouslySetInnerHTML==`object`&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var nf=null;function rf(){var e=window.event;return e&&e.type===`popstate`?e===nf?!1:(nf=e,!0):(nf=null,!1)}var af=typeof setTimeout==`function`?setTimeout:void 0,of=typeof clearTimeout==`function`?clearTimeout:void 0,sf=typeof Promise==`function`?Promise:void 0,cf=typeof queueMicrotask==`function`?queueMicrotask:sf===void 0?af:function(e){return sf.resolve(null).then(e).catch(lf)};function lf(e){setTimeout(function(){throw e})}function uf(e){return e===`head`}function df(e,t){var n=t,r=0;do{var i=n.nextSibling;if(e.removeChild(n),i&&i.nodeType===8)if(n=i.data,n===`/$`||n===`/&`){if(r===0){e.removeChild(i),Wp(t);return}r--}else if(n===`$`||n===`$?`||n===`$~`||n===`$!`||n===`&`)r++;else if(n===`html`)Tf(e.ownerDocument.documentElement);else if(n===`head`){n=e.ownerDocument.head,Tf(n);for(var a=n.firstChild;a;){var o=a.nextSibling,s=a.nodeName;a[_t]||s===`SCRIPT`||s===`STYLE`||s===`LINK`&&a.rel.toLowerCase()===`stylesheet`||n.removeChild(a),a=o}}else n===`body`&&Tf(e.ownerDocument.body);n=i}while(n);Wp(t)}function ff(e,t){var n=e;e=0;do{var r=n.nextSibling;if(n.nodeType===1?t?(n._stashedDisplay=n.style.display,n.style.display=`none`):(n.style.display=n._stashedDisplay||``,n.getAttribute(`style`)===``&&n.removeAttribute(`style`)):n.nodeType===3&&(t?(n._stashedText=n.nodeValue,n.nodeValue=``):n.nodeValue=n._stashedText||``),r&&r.nodeType===8)if(n=r.data,n===`/$`){if(e===0)break;e--}else n!==`$`&&n!==`$?`&&n!==`$~`&&n!==`$!`||e++;n=r}while(n)}function pf(e){var t=e.firstChild;for(t&&t.nodeType===10&&(t=t.nextSibling);t;){var n=t;switch(t=t.nextSibling,n.nodeName){case`HTML`:case`HEAD`:case`BODY`:pf(n),vt(n);continue;case`SCRIPT`:case`STYLE`:continue;case`LINK`:if(n.rel.toLowerCase()===`stylesheet`)continue}e.removeChild(n)}}function mf(e,t,n,r){for(;e.nodeType===1;){var i=n;if(e.nodeName.toLowerCase()!==t.toLowerCase()){if(!r&&(e.nodeName!==`INPUT`||e.type!==`hidden`))break}else if(!r)if(t===`input`&&e.type===`hidden`){var a=i.name==null?null:``+i.name;if(i.type===`hidden`&&e.getAttribute(`name`)===a)return e}else return e;else if(!e[_t])switch(t){case`meta`:if(!e.hasAttribute(`itemprop`))break;return e;case`link`:if(a=e.getAttribute(`rel`),a===`stylesheet`&&e.hasAttribute(`data-precedence`)||a!==i.rel||e.getAttribute(`href`)!==(i.href==null||i.href===``?null:i.href)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin)||e.getAttribute(`title`)!==(i.title==null?null:i.title))break;return e;case`style`:if(e.hasAttribute(`data-precedence`))break;return e;case`script`:if(a=e.getAttribute(`src`),(a!==(i.src==null?null:i.src)||e.getAttribute(`type`)!==(i.type==null?null:i.type)||e.getAttribute(`crossorigin`)!==(i.crossOrigin==null?null:i.crossOrigin))&&a&&e.hasAttribute(`async`)&&!e.hasAttribute(`itemprop`))break;return e;default:return e}if(e=bf(e.nextSibling),e===null)break}return null}function hf(e,t,n){if(t===``)return null;for(;
vendor: 20,904 bytes, line 10
10e.nodeType!==3;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!n||(e=bf(e.nextSibling),e===null))return null;return e}function gf(e,t){for(;e.nodeType!==8;)if((e.nodeType!==1||e.nodeName!==`INPUT`||e.type!==`hidden`)&&!t||(e=bf(e.nextSibling),e===null))return null;return e}function _f(e){return e.data===`$?`||e.data===`$~`}function vf(e){return e.data===`$!`||e.data===`$?`&&e.ownerDocument.readyState!==`loading`}function yf(e,t){var n=e.ownerDocument;if(e.data===`$~`)e._reactRetry=t;else if(e.data!==`$?`||n.readyState!==`loading`)t();else{var r=function(){t(),n.removeEventListener(`DOMContentLoaded`,r)};n.addEventListener(`DOMContentLoaded`,r),e._reactRetry=r}}function bf(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t===`$`||t===`$!`||t===`$?`||t===`$~`||t===`&`||t===`F!`||t===`F`)break;if(t===`/$`||t===`/&`)return null}}return e}var xf=null;function Sf(e){e=e.nextSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`/$`||n===`/&`){if(t===0)return bf(e.nextSibling);t--}else n!==`$`&&n!==`$!`&&n!==`$?`&&n!==`$~`&&n!==`&`||t++}e=e.nextSibling}return null}function Cf(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n===`$`||n===`$!`||n===`$?`||n===`$~`||n===`&`){if(t===0)return e;t--}else n!==`/$`&&n!==`/&`||t++}e=e.previousSibling}return null}function wf(e,t,n){switch(t=Qd(n),e){case`html`:if(e=t.documentElement,!e)throw Error(i(452));return e;case`head`:if(e=t.head,!e)throw Error(i(453));return e;case`body`:if(e=t.body,!e)throw Error(i(454));return e;default:throw Error(i(451))}}function Tf(e){for(var t=e.attributes;t.length;)e.removeAttributeNode(t[0]);vt(e)}var Ef=new Map,Df=new Set;function Of(e){return typeof e.getRootNode==`function`?e.getRootNode():e.nodeType===9?e:e.ownerDocument}var kf=N.d;N.d={f:Af,r:jf,D:Pf,C:Ff,L:If,m:Lf,X:zf,S:Rf,M:Bf};function Af(){var e=kf.f(),t=Au();return e||t}function jf(e){var t=bt(e);t!==null&&t.tag===5&&t.type===`form`?Ps(t):kf.r(e)}var Mf=typeof document>`u`?null:document;function Nf(e,t,n){var r=Mf;if(r&&typeof t==`string`&&t){var i=Ht(t);i=`link[rel="`+e+`"][href="`+i+`"]`,typeof n==`string`&&(i+=`[crossorigin="`+n+`"]`),Df.has(i)||(Df.add(i),e={rel:e,crossOrigin:n,href:t},r.querySelector(i)===null&&(t=r.createElement(`link`),Kd(t,`link`,e),Ct(t),r.head.appendChild(t)))}}function Pf(e){kf.D(e),Nf(`dns-prefetch`,e,null)}function Ff(e,t){kf.C(e,t),Nf(`preconnect`,e,t)}function If(e,t,n){kf.L(e,t,n);var r=Mf;if(r&&e&&t){var i=`link[rel="preload"][as="`+Ht(t)+`"]`;t===`image`&&n&&n.imageSrcSet?(i+=`[imagesrcset="`+Ht(n.imageSrcSet)+`"]`,typeof n.imageSizes==`string`&&(i+=`[imagesizes="`+Ht(n.imageSizes)+`"]`)):i+=`[href="`+Ht(e)+`"]`;var a=i;switch(t){case`style`:a=Hf(e);break;case`script`:a=Kf(e)}Ef.has(a)||(e=h({rel:`preload`,href:t===`image`&&n&&n.imageSrcSet?void 0:e,as:t},n),Ef.set(a,e),r.querySelector(i)!==null||t===`style`&&r.querySelector(Uf(a))||t===`script`&&r.querySelector(qf(a))||(t=r.createElement(`link`),Kd(t,`link`,e),Ct(t),r.head.appendChild(t)))}}function Lf(e,t){kf.m(e,t);var n=Mf;if(n&&e){var r=t&&typeof t.as==`string`?t.as:`script`,i=`link[rel="modulepreload"][as="`+Ht(r)+`"][href="`+Ht(e)+`"]`,a=i;switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:a=Kf(e)}if(!Ef.has(a)&&(e=h({rel:`modulepreload`,href:e},t),Ef.set(a,e),n.querySelector(i)===null)){switch(r){case`audioworklet`:case`paintworklet`:case`serviceworker`:case`sharedworker`:case`worker`:case`script`:if(n.querySelector(qf(a)))return}r=n.createElement(`link`),Kd(r,`link`,e),Ct(r),n.head.appendChild(r)}}}function Rf(e,t,n){kf.S(e,t,n);var r=Mf;if(r&&e){var i=St(r).hoistableStyles,a=Hf(e);t||=`default`;var o=i.get(a);if(!o){var s={loading:0,preload:null};if(o=r.querySelector(Uf(a)))s.loading=5;else{e=h({rel:`stylesheet`,href:e,"data-precedence":t},n),(n=Ef.get(a))&&Xf(e,n);var c=o=r.createElement(`link`);Ct(c),Kd(c,`link`,e),c._p=new Promise(function(e,t){c.onload=e,c.onerror=t}),c.addEventListener(`load`,function(){s.loading|=1}),c.addEventListener(`error`,function(){s.loading|=2}),s.loading|=4,Yf(o,t,r)}o={type:`stylesheet`,instance:o,count:1,state:s},i.set(a,o)}}}function zf(e,t){kf.X(e,t);var n=Mf;if(n&&e){var r=St(n).hoistableScripts,i=Kf(e),a=r.get(i);a||(a=n.querySelector(qf(i)),a||(e=h({src:e,async:!0},t),(t=Ef.get(i))&&Zf(e,t),a=n.createElement(`script`),Ct(a),Kd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Bf(e,t){kf.M(e,t);var n=Mf;if(n&&e){var r=St(n).hoistableScripts,i=Kf(e),a=r.get(i);a||(a=n.querySelector(qf(i)),a||(e=h({src:e,async:!0,type:`module`},t),(t=Ef.get(i))&&Zf(e,t),a=n.createElement(`script`),Ct(a),Kd(a,`link`,e),n.head.appendChild(a)),a={type:`script`,instance:a,count:1,state:null},r.set(i,a))}}function Vf(e,t,n,r){var a=(a=de.current)?Of(a):null;if(!a)throw Error(i(446));switch(e){case`meta`:case`title`:return null;case`style`:return typeof n.precedence==`string`&&typeof n.href==`string`?(t=Hf(n.href),n=St(a).hoistableStyles,r=n.get(t),r||(r={type:`style`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};case`link`:if(n.rel===`stylesheet`&&typeof n.href==`string`&&typeof n.precedence==`string`){e=Hf(n.href);var o=St(a).hoistableStyles,s=o.get(e);if(s||(a=a.ownerDocument||a,s={type:`stylesheet`,instance:null,count:0,state:{loading:0,preload:null}},o.set(e,s),(o=a.querySelector(Uf(e)))&&!o._p&&(s.instance=o,s.state.loading=5),Ef.has(e)||(n={rel:`preload`,as:`style`,href:n.href,crossOrigin:n.crossOrigin,integrity:n.integrity,media:n.media,hrefLang:n.hrefLang,referrerPolicy:n.referrerPolicy},Ef.set(e,n),o||Gf(a,e,n,s.state))),t&&r===null)throw Error(i(528,``));return s}if(t&&r!==null)throw Error(i(529,``));return null;case`script`:return t=n.async,n=n.src,typeof n==`string`&&t&&typeof t!=`function`&&typeof t!=`symbol`?(t=Kf(n),n=St(a).hoistableScripts,r=n.get(t),r||(r={type:`script`,instance:null,count:0,state:null},n.set(t,r)),r):{type:`void`,instance:null,count:0,state:null};default:throw Error(i(444,e))}}function Hf(e){return`href="`+Ht(e)+`"`}function Uf(e){return`link[rel="stylesheet"][`+e+`]`}function Wf(e){return h({},e,{"data-precedence":e.precedence,precedence:null})}function Gf(e,t,n,r){e.querySelector(`link[rel="preload"][as="style"][`+t+`]`)?r.loading=1:(t=e.createElement(`link`),r.preload=t,t.addEventListener(`load`,function(){return r.loading|=1}),t.addEventListener(`error`,function(){return r.loading|=2}),Kd(t,`link`,n),Ct(t),e.head.appendChild(t))}function Kf(e){return`[src="`+Ht(e)+`"]`}function qf(e){return`script[async]`+e}function Jf(e,t,n){if(t.count++,t.instance===null)switch(t.type){case`style`:var r=e.querySelector(`style[data-href~="`+Ht(n.href)+`"]`);if(r)return t.instance=r,Ct(r),r;var a=h({},n,{"data-href":n.href,"data-precedence":n.precedence,href:null,precedence:null});return r=(e.ownerDocument||e).createElement(`style`),Ct(r),Kd(r,`style`,a),Yf(r,n.precedence,e),t.instance=r;case`stylesheet`:a=Hf(n.href);var o=e.querySelector(Uf(a));if(o)return t.state.loading|=4,t.instance=o,Ct(o),o;r=Wf(n),(a=Ef.get(a))&&Xf(r,a),o=(e.ownerDocument||e).createElement(`link`),Ct(o);var s=o;return s._p=new Promise(function(e,t){s.onload=e,s.onerror=t}),Kd(o,`link`,r),t.state.loading|=4,Yf(o,n.precedence,e),t.instance=o;case`script`:return o=Kf(n.src),(a=e.querySelector(qf(o)))?(t.instance=a,Ct(a),a):(r=n,(a=Ef.get(o))&&(r=h({},n),Zf(r,a)),e=e.ownerDocument||e,a=e.createElement(`script`),Ct(a),Kd(a,`link`,r),e.head.appendChild(a),t.instance=a);case`void`:return null;default:throw Error(i(443,t.type))}else t.type===`stylesheet`&&!(t.state.loading&4)&&(r=t.instance,t.state.loading|=4,Yf(r,n.precedence,e));return t.instance}function Yf(e,t,n){for(var r=n.querySelectorAll(`link[rel="stylesheet"][data-precedence],style[data-precedence]`),i=r.length?r[r.length-1]:null,a=i,o=0;o<r.length;o++){var s=r[o];if(s.dataset.precedence===t)a=s;else if(a!==i)break}a?a.parentNode.insertBefore(e,a.nextSibling):(t=n.nodeType===9?n.head:n,t.insertBefore(e,t.firstChild))}function Xf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.title??=t.title}function Zf(e,t){e.crossOrigin??=t.crossOrigin,e.referrerPolicy??=t.referrerPolicy,e.integrity??=t.integrity}var Qf=null;function $f(e,t,n){if(Qf===null){var r=new Map,i=Qf=new Map;i.set(n,r)}else i=Qf,r=i.get(n),r||(r=new Map,i.set(n,r));if(r.has(e))return r;for(r.set(e,null),n=n.getElementsByTagName(e),i=0;i<n.length;i++){var a=n[i];if(!(a[_t]||a[ut]||e===`link`&&a.getAttribute(`rel`)===`stylesheet`)&&a.namespaceURI!==`http://www.w3.org/2000/svg`){var o=a.getAttribute(t)||``;o=e+o;var s=r.get(o);s?s.push(a):r.set(o,[a])}}return r}function ep(e,t,n){e=e.ownerDocument||e,e.head.insertBefore(n,t===`title`?e.querySelector(`head > title`):null)}function tp(e,t,n){if(n===1||t.itemProp!=null)return!1;switch(e){case`meta`:case`title`:return!0;case`style`:if(typeof t.precedence!=`string`||typeof t.href!=`string`||t.href===``)break;return!0;case`link`:if(typeof t.rel!=`string`||typeof t.href!=`string`||t.href===``||t.onLoad||t.onError)break;switch(t.rel){case`stylesheet`:return e=t.disabled,typeof t.precedence==`string`&&e==null;default:return!0}case`script`:if(t.async&&typeof t.async!=`function`&&typeof t.async!=`symbol`&&!t.onLoad&&!t.onError&&t.src&&typeof t.src==`string`)return!0}return!1}function np(e){return!(e.type===`stylesheet`&&!(e.state.loading&3))}function rp(e,t,n,r){if(n.type===`stylesheet`&&(typeof r.media!=`string`||!1!==matchMedia(r.media).matches)&&!(n.state.loading&4)){if(n.instance===null){var i=Hf(r.href),a=t.querySelector(Uf(i));if(a){t=a._p,typeof t==`object`&&t&&typeof t.then==`function`&&(e.count++,e=op.bind(e),t.then(e,e)),n.state.loading|=4,n.instance=a,Ct(a);return}a=t.ownerDocument||t,r=Wf(r),(i=Ef.get(i))&&Xf(r,i),a=a.createElement(`link`),Ct(a);var o=a;o._p=new Promise(function(e,t){o.onload=e,o.onerror=t}),Kd(a,`link`,r),n.instance=a}e.stylesheets===null&&(e.stylesheets=new Map),e.stylesheets.set(n,t),(t=n.state.preload)&&!(n.state.loading&3)&&(e.count++,n=op.bind(e),t.addEventListener(`load`,n),t.addEventListener(`error`,n))}}var ip=0;function ap(e,t){return e.stylesheets&&e.count===0&&cp(e,e.stylesheets),0<e.count||0<e.imgCount?function(n){var r=setTimeout(function(){if(e.stylesheets&&cp(e,e.stylesheets),e.unsuspend){var t=e.unsuspend;e.unsuspend=null,t()}},6e4+t);0<e.imgBytes&&ip===0&&(ip=62500*Yd());var i=setTimeout(function(){if(e.waitingForImages=!1,e.count===0&&(e.stylesheets&&cp(e,e.stylesheets),e.unsuspend)){var t=e.unsuspend;e.unsuspend=null,t()}},(e.imgBytes>ip?50:800)+t);return e.unsuspend=n,function(){e.unsuspend=null,clearTimeout(r),clearTimeout(i)}}:null}function op(){if(this.count--,this.count===0&&(this.imgCount===0||!this.waitingForImages)){if(this.stylesheets)cp(this,this.stylesheets);else if(this.unsuspend){var e=this.unsuspend;this.unsuspend=null,e()}}}var sp=null;function cp(e,t){e.stylesheets=null,e.unsuspend!==null&&(e.count++,sp=new Map,t.forEach(lp,e),sp=null,op.call(e))}function lp(e,t){if(!(t.state.loading&4)){var n=sp.get(e);if(n)var r=n.get(null);else{n=new Map,sp.set(e,n);for(var i=e.querySelectorAll(`link[data-precedence],style[data-precedence]`),a=0;a<i.length;a++){var o=i[a];(o.nodeName===`LINK`||o.getAttribute(`media`)!==`not all`)&&(n.set(o.dataset.precedence,o),r=o)}r&&n.set(null,r)}i=t.instance,o=i.getAttribute(`data-precedence`),a=n.get(o)||r,a===r&&n.set(null,i),n.set(o,i),this.count++,r=op.bind(this),i.addEventListener(`load`,r),i.addEventListener(`error`,r),a?a.parentNode.insertBefore(i,a.nextSibling):(e=e.nodeType===9?e.head:e,e.insertBefore(i,e.firstChild)),t.state.loading|=4}}var up={$$typeof:C,Provider:null,Consumer:null,_currentValue:ie,_currentValue2:ie,_threadCount:0};function dp(e,t,n,r,i,a,o,s,c){this.tag=1,this.containerInfo=e,this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.next=this.pendingContext=this.context=this.cancelPendingCommit=null,this.callbackPriority=0,this.expirationTimes=$e(-1),this.entangledLanes=this.shellSuspendCounter=this.errorRecoveryDisabledLanes=this.expiredLanes=this.warmLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=$e(0),this.hiddenUpdates=$e(null),this.identifierPrefix=r,this.onUncaughtError=i,this.onCaughtError=a,this.onRecoverableError=o,this.pooledCache=null,this.pooledCacheLanes=0,this.formState=c,this.incompleteTransitions=new Map}function fp(e,t,n,r,i,a,o,s,c,l,u,d){return e=new dp(e,t,n,o,c,l,u,d,s),t=1,!0===a&&(t|=24),a=fi(3,null,null,t),e.current=a,a.stateNode=e,t=pa(),t.refCount++,e.pooledCache=t,t.refCount++,a.memoizedState={element:r,isDehydrated:n,cache:t},Ka(a),e}function pp(e){return e?(e=ui,e):ui}function mp(e,t,n,r,i,a){i=pp(i),r.context===null?r.context=i:r.pendingContext=i,r=Ja(t),r.payload={element:n},a=a===void 0?null:a,a!==null&&(r.callback=a),n=Ya(e,r,t),n!==null&&(Tu(n,e,t),Xa(n,e,t))}function hp(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function gp(e,t){hp(e,t),(e=e.alternate)&&hp(e,t)}function _p(e){if(e.tag===13||e.tag===31){var t=si(e,67108864);t!==null&&Tu(t,e,67108864),gp(e,67108864)}}function vp(e){if(e.tag===13||e.tag===31){var t=Cu();t=at(t);var n=si(e,t);n!==null&&Tu(n,e,t),gp(e,t)}}var yp=!0;function bp(e,t,n,r){var i=M.T;M.T=null;var a=N.p;try{N.p=2,Sp(e,t,n,r)}finally{N.p=a,M.T=i}}function xp(e,t,n,r){var i=M.T;M.T=null;var a=N.p;try{N.p=8,Sp(e,t,n,r)}finally{N.p=a,M.T=i}}function Sp(e,t,n,r){if(yp){var i=Cp(r);if(i===null)Fd(e,t,r,wp,n),Fp(e,r);else if(Lp(i,e,t,n,r))r.stopPropagation();else if(Fp(e,r),t&4&&-1<Pp.indexOf(e)){for(;i!==null;){var a=bt(i);if(a!==null)switch(a.tag){case 3:if(a=a.stateNode,a.current.memoizedState.isDehydrated){var o=Je(a.pendingLanes);if(o!==0){var s=a;for(s.pendingLanes|=2,s.entangledLanes|=2;o;){var c=1<<31-Ve(o);s.entanglements[1]|=c,o&=~c}pd(a),!(Wl&6)&&(du=ke()+500,md(0,!1))}}break;case 31:case 13:s=si(a,2),s!==null&&Tu(s,a,2),Au(),gp(a,2)}if(a=Cp(r),a===null&&Fd(e,t,r,wp,n),a===i)break;i=a}i!==null&&r.stopPropagation()}else Fd(e,t,r,null,n)}}function Cp(e){return e=on(e),Tp(e)}var wp=null;function Tp(e){if(wp=null,e=yt(e),e!==null){var t=o(e);if(t===null)e=null;else{var n=t.tag;if(n===13){if(e=s(t),e!==null)return e;e=null}else if(n===31){if(e=c(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null)}}return wp=e,null}function Ep(e){switch(e){case`beforetoggle`:case`cancel`:case`click`:case`close`:case`contextmenu`:case`copy`:case`cut`:case`auxclick`:case`dblclick`:case`dragend`:case`dragstart`:case`drop`:case`focusin`:case`focusout`:case`input`:case`invalid`:case`keydown`:case`keypress`:case`keyup`:case`mousedown`:case`mouseup`:case`paste`:case`pause`:case`play`:case`pointercancel`:case`pointerdown`:case`pointerup`:case`ratechange`:case`reset`:case`resize`:case`seeked`:case`submit`:case`toggle`:case`touchcancel`:case`touchend`:case`touchstart`:case`volumechange`:case`change`:case`selectionchange`:case`textInput`:case`compositionstart`:case`compositionend`:case`compositionupdate`:case`beforeblur`:case`afterblur`:case`beforeinput`:case`blur`:case`fullscreenchange`:case`focus`:case`hashchange`:case`popstate`:case`select`:case`selectstart`:return 2;case`drag`:case`dragenter`:case`dragexit`:case`dragleave`:case`dragover`:case`mousemove`:case`mouseout`:case`mouseover`:case`pointermove`:case`pointerout`:case`pointerover`:case`scroll`:case`touchmove`:case`wheel`:case`mouseenter`:case`mouseleave`:case`pointerenter`:case`pointerleave`:return 8;case`message`:switch(Ae()){case je:return 2;case Me:return 8;case Ne:case Pe:return 32;case Fe:return 268435456;default:return 32}default:return 32}}var Dp=!1,Op=null,kp=null,Ap=null,jp=new Map,Mp=new Map,Np=[],Pp=`mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset`.split(` `);function Fp(e,t){switch(e){case`focusin`:case`focusout`:Op=null;break;case`dragenter`:case`dragleave`:kp=null;break;case`mouseover`:case`mouseout`:Ap=null;break;case`pointerover`:case`pointerout`:jp.delete(t.pointerId);break;case`gotpointercapture`:case`lostpointercapture`:Mp.delete(t.pointerId)}}function Ip(e,t,n,r,i,a){return e===null||e.nativeEvent!==a?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:a,targetContainers:[i]},t!==null&&(t=bt(t),t!==null&&_p(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function Lp(e,t,n,r,i){switch(t){case`focusin`:return Op=Ip(Op,e,t,n,r,i),!0;case`dragenter`:return kp=Ip(kp,e,t,n,r,i),!0;case`mouseover`:return Ap=Ip(Ap,e,t,n,r,i),!0;case`pointerover`:var a=i.pointerId;return jp.set(a,Ip(jp.get(a)||null,e,t,n,r,i)),!0;case`gotpointercapture`:return a=i.pointerId,Mp.set(a,Ip(Mp.get(a)||null,e,t,n,r,i)),!0}return!1}function Rp(e){var t=yt(e.target);if(t!==null){var n=o(t);if(n!==null){if(t=n.tag,t===13){if(t=s(n),t!==null){e.blockedOn=t,ct(e.priority,function(){vp(n)});return}}else if(t===31){if(t=c(n),t!==null){e.blockedOn=t,ct(e.priority,function(){vp(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function zp(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=Cp(e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);an=r,n.target.dispatchEvent(r),an=null}else return t=bt(n),t!==null&&_p(t),e.blockedOn=n,!1;t.shift()}return!0}function Bp(e,t,n){zp(e)&&n.delete(t)}function H(){Dp=!1,Op!==null&&zp(Op)&&(Op=null),kp!==null&&zp(kp)&&(kp=null),Ap!==null&&zp(Ap)&&(Ap=null),jp.forEach(Bp),Mp.forEach(Bp)}function Vp(e,n){e.blockedOn===n&&(e.blockedOn=null,Dp||(Dp=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,H)))}var Hp=null;function Up(e){Hp!==e&&(Hp=e,t.unstable_scheduleCallback(t.unstable_NormalPriority,function(){Hp===e&&(Hp=null);for(var t=0;t<e.length;t+=3){var n=e[t],r=e[t+1],i=e[t+2];if(typeof r!=`function`){if(Tp(r||n)===null)continue;break}var a=bt(n);a!==null&&(e.splice(t,3),t-=3,Ms(a,{pending:!0,data:i,method:n.method,action:r},r,i))}}))}function Wp(e){function t(t){return Vp(t,e)}Op!==null&&Vp(Op,e),kp!==null&&Vp(kp,e),Ap!==null&&Vp(Ap,e),jp.forEach(t),Mp.forEach(t);for(var n=0;n<Np.length;n++){var r=Np[n];r.blockedOn===e&&(r.blockedOn=null)}for(;0<Np.length&&(n=Np[0],n.blockedOn===null);)Rp(n),n.blockedOn===null&&Np.shift();if(n=(e.ownerDocument||e).$$reactFormReplay,n!=null)for(r=0;r<n.length;r+=3){var i=n[r],a=n[r+1],o=i[dt]||null;if(typeof a==`function`)o||Up(n);else if(o){var s=null;if(a&&a.hasAttribute(`formAction`)){if(i=a,o=a[dt]||null)s=o.formAction;else if(Tp(i)!==null)continue}else s=o.action;typeof s==`function`?n[r+1]=s:(n.splice(r,3),r-=3),Up(n)}}}function Gp(){function e(e){e.canIntercept&&e.info===`react-transition`&&e.intercept({handler:function(){return new Promise(function(e){return i=e})},focusReset:`manual`,scroll:`manual`})}function t(){i!==null&&(i(),i=null),r||setTimeout(n,20)}function n(){if(!r&&!navigation.transition){var e=navigation.currentEntry;e&&e.url!=null&&navigation.navigate(e.url,{state:e.getState(),info:`react-transition`,history:`replace`})}}if(typeof navigation==`object`){var r=!1,i=null;return navigation.addEventListener(`navigate`,e),navigation.addEventListener(`navigatesuccess`,t),navigation.addEventListener(`navigateerror`,t),setTimeout(n,100),function(){r=!0,navigation.removeEventListener(`navigate`,e),navigation.removeEventListener(`navigatesuccess`,t),navigation.removeEventListener(`navigateerror`,t),i!==null&&(i(),i=null)}}}function Kp(e){this._internalRoot=e}qp.prototype.render=Kp.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(i(409));var n=t.current;mp(n,Cu(),e,t,null,null)},qp.prototype.unmount=Kp.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;mp(e.current,2,null,e,null,null),Au(),t[ft]=null}};function qp(e){this._internalRoot=e}qp.prototype.unstable_scheduleHydration=function(e){if(e){var t=st();e={blockedOn:null,target:e,priority:t};for(var n=0;n<Np.length&&t!==0&&t<Np[n].priority;n++);Np.splice(n,0,e),n===0&&Rp(e)}};var Jp=n.version;if(Jp!==`19.2.7`)throw Error(i(527,Jp,`19.2.7`));N.findDOMNode=function(e){var t=e._reactInternals;if(t===void 0)throw typeof e.render==`function`?Error(i(188)):(e=Object.keys(e).join(`,`),Error(i(268,e)));return e=d(t),e=e===null?null:p(e),e=e===null?null:e.stateNode,e};var Yp={bundleType:0,version:`19.2.7`,rendererPackageName:`react-dom`,currentDispatcherRef:M,reconcilerVersion:`19.2.7`};
10if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<`u`){var Xp=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Xp.isDisabled&&Xp.supportsFiber)try{Re=Xp.inject(Yp),ze=Xp}catch{}}e.createRoot=function(e,t){if(!a(e))throw Error(i(299));var n=!1,r=``,o=ec,s=tc,c=nc;return t!=null&&(!0===t.unstable_strictMode&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onUncaughtError!==void 0&&(o=t.onUncaughtError),t.onCaughtError!==void 0&&(s=t.onCaughtError),t.onRecoverableError!==void 0&&(c=t.onRecoverableError)),t=fp(e,1,!1,null,null,n,r,null,o,s,c,Gp),e[ft]=t.current,Nd(e),new Kp(t)}})),g=o(((e,t)=>{function n(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>`u`||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!=`function`))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(n)}catch(e){console.error(e)}}n(),t.exports=h()})),_=c(u(),1),v=g(),y=`modulepreload`,b=function(e){return`/`+e},x={},S=function(e,t,n){let r=Promise.resolve();if(t&&t.length>0){let e=document.getElementsByTagName(`link`),i=document.querySelector(`meta[property=csp-nonce]`),a=i?.nonce||i?.getAttribute(`nonce`);function o(e){return Promise.all(e.map(e=>Promise.resolve(e).then(e=>({status:`fulfilled`,value:e}),e=>({status:`rejected`,reason:e}))))}r=o(t.map(t=>{if(t=b(t,n),t in x)return;x[t]=!0;let r=t.endsWith(`.css`),i=r?`[rel="stylesheet"]`:``;if(n)for(let n=e.length-1;n>=0;n--){let i=e[n];if(i.href===t&&(!r||i.rel===`stylesheet`))return}else if(document.querySelector(`link[href="${t}"]${i}`))return;let o=document.createElement(`link`);if(o.rel=r?`stylesheet`:y,r||(o.as=`script`),o.crossOrigin=``,o.href=t,a&&o.setAttribute(`nonce`,a),document.head.appendChild(o),r)return new Promise((e,n)=>{o.addEventListener(`load`,e),o.addEventListener(`error`,()=>n(Error(`Unable to preload CSS for ${t}`)))})}))}function i(e){let t=new Event(`vite:preloadError`,{cancelable:!0});if(t.payload=e,window.dispatchEvent(t),!t.defaultPrevented)throw e}return r.then(t=>{for(let e of t||[])e.status===`rejected`&&i(e.reason);return e().catch(i)})},C=/^(?:[a-z][a-z0-9+.-]*:|[\\/]{2})/i,w=/^[\\/]{2}/;function T(e,t){return t+e.replace(/\\/g,`/`)}var E=`popstate`;function D(e){return typeof e==`object`&&!!e&&`pathname`in e&&`search`in e&&`hash`in e&&`state`in e&&`key`in e}function O(e={}){function t(e,t){let n=t.state?.masked,{pathname:r,search:i,hash:a}=n||e.location;return te(``,{pathname:r,search:i,hash:a},t.state&&t.state.usr||null,t.state&&t.state.key||`default`,n?{pathname:e.location.pathname,search:e.location.search,hash:e.location.hash}:void 0)}function n(e,t){return typeof t==`string`?t:ne(t)}return M(t,n,null,e)}function k(e,t){if(e===!1||e==null)throw Error(t)}function A(e,t){if(!e){typeof console<`u`&&console.warn(t);try{throw Error(t)}catch{}}}function j(){return Math.random().toString(36).substring(2,10)}function ee(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}}function te(e,t,n=null,r,i){return{pathname:typeof e==`string`?e:e.pathname,search:``,hash:``,...typeof t==`string`?re(t):t,state:n,key:t&&t.key||r||j(),mask:i}}function ne({pathname:e=`/`,search:t=``,hash:n=``}){return t&&t!==`?`&&(e+=t.charAt(0)===`?`?t:`?`+t),n&&n!==`#`&&(e+=n.charAt(0)===`#`?n:`#`+n),e}function re(e){let t={};if(e){let n=e.indexOf(`#`);n>=0&&(t.hash=e.substring(n),e=e.substring(0,n));let r=e.indexOf(`?`);r>=0&&(t.search=e.substring(r),e=e.substring(0,r)),e&&(t.pathname=e)}return t}function M(e,t,n,r={}){let{window:i=document.defaultView,v5Compat:a=!1}=r,o=i.history,s=`POP`,c=null,l=u();l??(l=0,o.replaceState({...o.state,idx:l},``));function u(){return(o.state||{idx:null}).idx}function d(){s=`POP`;let e=u(),t=e==null?null:e-l;l=e,c&&c({action:s,location:h.location,delta:t})}function f(e,t){s=`PUSH`;let r=D(e)?e:te(h.location,e,t);n&&n(r,e),l=u()+1;let d=ee(r,l),f=h.createHref(r.mask||r);try{o.pushState(d,``,f)}catch(e){if(e instanceof DOMException&&e.name===`DataCloneError`)throw e;i.location.assign(f)}a&&c&&c({action:s,location:h.location,delta:1})}function p(e,t){s=`REPLACE`;let r=D(e)?e:te(h.location,e,t);n&&n(r,e),l=u();let i=ee(r,l),d=h.createHref(r.mask||r);o.replaceState(i,``,d),a&&c&&c({action:s,location:h.location,delta:0})}function m(e){return N(i,e)}let h={get action(){return s},get location(){return e(i,o)},listen(e){if(c)throw Error(`A history only accepts one active listener`);return i.addEventListener(E,d),c=e,()=>{i.removeEventListener(E,d),c=null}},createHref(e){return t(i,e)},createURL:m,encodeLocation(e){let t=m(e);return{pathname:t.pathname,search:t.search,hash:t.hash}},push:f,replace:p,go(e){return o.go(e)}};return h}function N(e,t,n=!1){let r=`http://localhost`;e&&(r=e.location.origin===`null`?e.location.href:e.location.origin),k(r,`No window.location.(origin|href) available to create URL`);let i=typeof t==`string`?t:ne(t);return i=i.replace(/ $/,`%20`),!n&&w.test(i)&&(i=r+i),new URL(i,r)}function ie(e,t,n=`/`){return ae(e,t,n,!1)}function ae(e,t,n,r,i){let a=we((typeof t==`string`?re(t):t).pathname||`/`,n);if(a==null)return null;let o=i??oe(e),s=null,c=Ce(a);for(let e=0;s==null&&e<o.length;++e)s=ye(o[e],c,r);return s}function P(e,t){let{route:n,pathname:r,params:i}=e;return{id:n.id,pathname:r,params:i,data:t[n.id],loaderData:t[n.id],handle:n.handle}}function oe(e){let t=se(e);return le(t),t}function se(e,t=[],n=[],r=``,i=!1){let a=(e,a,o=i,s)=>{let c={relativePath:s===void 0?e.path||``:s,caseSensitive:e.caseSensitive===!0,childrenIndex:a,route:e};if(c.relativePath.startsWith(`/`)){if(!c.relativePath.startsWith(r)&&o)return;k(c.relativePath.startsWith(r),`Absolute route path "${c.relativePath}" nested under path "${r}
10" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),c.relativePath=c.relativePath.slice(r.length)}let l=Me([r,c.relativePath]),u=n.concat(c);e.children&&e.children.length>0&&(k(e.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${l}".`),se(e.children,t,u,l,o)),!(e.path==null&&!e.index)&&t.push({path:l,score:_e(l,e.index),routesMeta:u.map((e,t)=>{let[n,r]=Se(e.relativePath,e.caseSensitive,t===u.length-1);return{...e,matcher:n,compiledParams:r}})})};return e.forEach((e,t)=>{if(e.path===``||!e.path?.includes(`?`))a(e,t);else for(let n of ce(e.path))a(e,t,!0,n)}),t}function ce(e){let t=e.split(`/`);if(t.length===0)return[];let[n,...r]=t,i=n.endsWith(`?`),a=n.replace(/\?$/,``);if(r.length===0)return i?[a,``]:[a];let o=ce(r.join(`/`)),s=[];return s.push(...o.map(e=>e===``?a:[a,e].join(`/`))),i&&s.push(...o),s.map(t=>e.startsWith(`/`)&&t===``?`/`:t)}function le(e){e.sort((e,t)=>e.score===t.score?ve(e.routesMeta.map(e=>e.childrenIndex),t.routesMeta.map(e=>e.childrenIndex)):t.score-e.score)}var ue=/^:[\w-]+$/,de=3,fe=2,pe=1,me=10,he=-2,ge=e=>e===`*`;function _e(e,t){let n=e.split(`/`),r=n.length;return n.some(ge)&&(r+=he),t&&(r+=fe),n.filter(e=>!ge(e)).reduce((e,t)=>e+(ue.test(t)?de:t===``?pe:me),r)}function ve(e,t){return e.length===t.length&&e.slice(0,-1).every((e,n)=>e===t[n])?e[e.length-1]-t[t.length-1]:0}function ye(e,t,n=!1){let{routesMeta:r}=e,i={},a=`/`,o=[];for(let e=0;e<r.length;++e){let s=r[e],c=e===r.length-1,l=a===`/`?t:t.slice(a.length)||`/`,u={path:s.relativePath,caseSensitive:s.caseSensitive,end:c},d=s.matcher&&s.compiledParams?xe(u,l,s.matcher,s.compiledParams):be(u,l),f=s.route;if(!d&&c&&n&&!r[r.length-1].route.index&&(d=be({path:s.relativePath,caseSensitive:s.caseSensitive,end:!1},l)),!d)return null;
10Object.assign(i,d.params),o.push({params:i,pathname:Me([a,d.pathname]),pathnameBase:Pe(Me([a,d.pathnameBase])),route:f}),d.pathnameBase!==`/`&&(a=Me([a,d.pathnameBase]))}return o}function be(e,t){typeof e==`string`&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=Se(e.path,e.caseSensitive,e.end);return xe(e,t,n,r)}function xe(e,t,n,r){let i=t.match(n);if(!i)return null;let a=i[0],o=a.replace(/(.)\/+$/,`$1`),s=i.slice(1);return{params:r.reduce((e,{paramName:t,isOptional:n},r)=>{if(t===`*`){let e=s[r]||``;o=a.slice(0,a.length-e.length).replace(/(.)\/+$/,`$1`)}let i=s[r];return n&&!i?e[t]=void 0:e[t]=(i||``).replace(/%2F/g,`/`),e},{}),pathname:a,pathnameBase:o,pattern:e}}function Se(e,t=!1,n=!0){A(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 r=[],i=`^`+e.replace(/\/*\*?$/,``).replace(/^\/*/,`/`).replace(/[\\.*+^${}|()[\]]/g,`\\$&`).replace(/\/:([\w-]+)(\?)?/g,(e,t,n,i,a)=>{if(r.push({paramName:t,isOptional:n!=null}),n){let t=a.charAt(i+e.length);return t&&t!==`/`?`/([^\\/]*)`:`(?:/([^\\/]*))?`}return`/([^\\/]+)`}).replace(/\/([\w-]+)\?(\/|$)/g,`(/$1)?$2`);return e.endsWith(`*`)?(r.push({paramName:`*`}),i+=e===`*`||e===`/*`?`(.*)$`:`(?:\\/(.+)|\\/*)$`):n?i+=`\\/*$`:e!==``&&e!==`/`&&(i+=`(?:(?=\\/|$))`),[new RegExp(i,t?void 0:`i`),r]}function Ce(e){try{return e.split(`/`).map(e=>decodeURIComponent(e).replace(/\//g,`%2F`)).join(`/`)}catch(t){return A(!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}}function we(e,t){if(t===`/`)return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith(`/`)?t.length-1:t.length,r=e.charAt(n);return r&&r!==`/`?null:e.slice(n)||`/`}function Te(e,t=`/`){let{pathname:n,search:r=``,hash:i=``}=typeof e==`string`?re(e):e,a;return n?(n=je(n),a=n.startsWith(`/`)?Ee(n.substring(1),`/`):Ee(n,t)):a=t,{pathname:a,search:Fe(r),hash:Ie(i)}}function Ee(e,t){let n=Ne(t).split(`/`);return e.split(`/`).forEach(e=>{e===`..`?n.length>1&&n.pop():e!==`.`&&n.push(e)}),n.length>1?n.join(`/`):`/`}function De(e,t,n,r){return`Cannot include a '${e}' character in a manually specified \`to.${t}\` field [${JSON.stringify(r)}]. Please separate it out to the \`to.${n}\` field. Alternatively you may provide the full path as a string in <Link to="..."> and the router will parse it for you.`}function Oe(e){return e.filter((e,t)=>t===0||e.route.path&&e.route.path.length>0)}function ke(e){let t=Oe(e);return t.map((e,n)=>n===t.length-1?e.pathname:e.pathnameBase)}function Ae(e,t,n,r=!1){let i;typeof e==`string`?i=re(e):(i={...e},k(!i.pathname||!i.pathname.includes(`?`),De(`?`,`pathname`,`search`,i)),k(!i.pathname||!i.pathname.includes(`#`),De(`#`,`pathname`,`hash`,i)),k(!i.search||!i.search.includes(`#`),De(`#`,`search`,`hash`,i)));let a=e===``||i.pathname===``,o=a?`/`:i.pathname,s;if(o==null)s=n;else{let e=t.length-1;if(!r&&o.startsWith(`..`)){let t=o.split(`/`);for(;t[0]===`..`;)t.shift(),--e;i.pathname=t.join(`/`)}s=e>=0?t[e]:`/`}let c=Te(i,s),l=o&&o!==`/`&&o.endsWith(`/`),u=(a||o===`.`)&&n.endsWith(`/`);return!c.pathname.endsWith(`/`)&&(l||u)&&(c.pathname+=`/`),c}var je=e=>e.replace(/[\\/]{2,}/g,`/`),Me=e=>je(e.join(`/`)),Ne=e=>e.replace(/\/+$/,``),Pe=e=>Ne(e).replace(/^\/*/,`/`),Fe=e=>!e||e===`?`?``:e.startsWith(`?`)?e:`?`+e,Ie=e=>!e||e===`#`?``:e.startsWith(`#`)?e:`#`+e,Le=class{constructor(e,t,n,r=!1){this.status=e,this.statusText=t||``,this.internal=r,n instanceof Error?(this.data=n.toString(),this.error=n):this.data=n}};function Re(e){return e!=null&&typeof e.status==`number`&&typeof e.statusText==`string`&&typeof e.internal==`boolean`&&`data`in e}function ze(e){return Me(e.map(e=>e.route.path).filter(Boolean))||`/`}var Be=typeof window<`u`&&window.document!==void 0&&window.document.createElement!==void 0;function Ve(e,t){let n=e;if(typeof n!=`string`||!C.test(n))return{absoluteURL:void 0,isExternal:!1,to:n};let r=n,i=!1;if(Be)try{let e=new URL(window.location.href),r=w.test(n)?new URL(T(n,e.protocol)):new URL(n),a=we(r.pathname,t);r.origin===e.origin&&a!=null?n=a+r.search+r.hash:i=!0}catch{A(!1,`<Link to="${n}">
10 contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}return{absoluteURL:r,isExternal:i,to:n}}Object.getOwnPropertyNames(Object.prototype).sort().join(`\0`);var He=[`POST`,`PUT`,`PATCH`,`DELETE`];new Set(He);var Ue=[`GET`,...He];new Set(Ue);var We=[`about:`,`blob:`,`chrome:`,`chrome-untrusted:`,`content:`,`data:`,`devtools:`,`file:`,`filesystem:`,`javascript:`];function Ge(e){try{return We.includes(new URL(e).protocol)}catch{return!1}}var Ke=_.createContext(null);Ke.displayName=`DataRouter`;var qe=_.createContext(null);qe.displayName=`DataRouterState`;var Je=_.createContext(!1);function Ye(){return _.useContext(Je)}var Xe=_.createContext({isTransitioning:!1});Xe.displayName=`ViewTransition`;var Ze=_.createContext(new Map);Ze.displayName=`Fetchers`;var Qe=_.createContext(null);Qe.displayName=`Await`;var $e=_.createContext(null);$e.displayName=`Navigation`;var et=_.createContext(null);et.displayName=`Location`;var tt=_.createContext({outlet:null,matches:[],isDataRoute:!1});tt.displayName=`Route`;var nt=_.createContext(null);nt.displayName=`RouteError`;var rt=`REACT_ROUTER_ERROR`,it=`REDIRECT`,at=`ROUTE_ERROR_RESPONSE`;function ot(e){if(e.startsWith(`${rt}:${it}:{`))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{}}function st(e){if(e.startsWith(`${rt}:${at}:{`))try{let t=JSON.parse(e.slice(40));if(typeof t==`object`&&t&&typeof t.status==`number`&&typeof t.statusText==`string`)return new Le(t.status,t.statusText,t.data)}catch{}}function ct(e,{relative:t}={}){k(lt(),`useHref() may be used only in the context of a <Router> component.`);let{basename:n,navigator:r}=_.useContext($e),{hash:i,pathname:a,search:o}=yt(e,{relative:t}),s=a;return n!==`/`&&(s=a===`/`?n:Me([n,a])),r.createHref({pathname:s,search:o,hash:i})}function lt(){return _.useContext(et)!=null}function ut(){return k(lt(),`useLocation() may be used only in the context of a <Router> component.`),_.useContext(et).location}var dt=`You should call navigate() in a React.useEffect(), not when your component is first rendered.`;function ft(e){_.useContext($e).static||_.useLayoutEffect(e)}function pt(){let{isDataRoute:e}=_.useContext(tt);return e?Rt():mt()}function mt(){k(lt(),`useNavigate() may be used only in the context of a <Router> component.`);let e=_.useContext(Ke),{basename:t,navigator:n}=_.useContext($e),{matches:r}=_.useContext(tt),{pathname:i}=ut(),a=JSON.stringify(ke(r)),o=_.useRef(!1);return ft(()=>{o.current=!0}),_.useCallback((r,s={})=>{if(A(o.current,dt),!o.current)return;if(typeof r==`number`){n.go(r);return}let c=Ae(r,JSON.parse(a),i,s.relative===`path`);e==null&&t!==`/`&&(c.pathname=c.pathname===`/`?t:Me([t,c.pathname])),(s.replace?n.replace:n.push)(c,s.state,s)},[t,n,a,i,e])}var ht=_.createContext(null);function gt(){return _.useContext(ht)}function _t(e){let t=_.useContext(tt).outlet;return _.useMemo(()=>t&&_.createElement(ht.Provider,{value:e},t),[t,e])}function vt(){let{matches:e}=_.useContext(tt);return e[e.length-1]?.params??{}}function yt(e,{relative:t}={}){let{matches:n}=_.useContext(tt),{pathname:r}=ut(),i=JSON.stringify(ke(n));return _.useMemo(()=>Ae(e,JSON.parse(i),r,t===`path`),[e,i,r,t])}function bt(e,t){return xt(e,t)}function xt(e,t,n){k(lt(),`useRoutes() may be used only in the context of a <Router> component.`);let{navigator:r}=_.useContext($e),{matches:i}=_.useContext(tt),a=i[i.length-1],o=a?a.params:{},s=a?a.pathname:`/`,c=a?a.pathnameBase:`/`,l=a&&a.route;{let e=l&&l.path||``;Bt(s,!l||e.endsWith(`*`)||e.endsWith(`*?`),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${s}" (under <Route path="${e}">) 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. 11 12Please change the parent <Route path="${e}"> to <Route path="${e===`/`?`*`:`${e}/*`}">.`)}let u=ut(),d;if(t){let e=typeof t==`string`?re(t):t;k(c===`/`||e.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 "${e.pathname}" was given in the \`location\` prop.`),d=e}else d=u;let f=d.pathname||`/`,p=f;if(c!==`/`){let e=c.replace(/^\//,``).split(`/`);p=`/`+f.replace(/^\//,``).split(`/`).slice(e.length).join(`/`)}let m=n&&n.state.matches.length?n.state.matches.map(e=>Object.assign(e,{route:n.manifest[e.route.id]||e.route})):ie(e,{pathname:p});A(l||m!=null,`No routes matched location "${d.pathname}${d.search}${d.hash}" `),A(m==null||m[m.length-1].route.element!==void 0||m[m.length-1].route.Component!==void 0||m[m.length-1].route.lazy!==void 0,`Matched leaf route at location "${d.pathname}${d.search}${d.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 h=Ot(m&&m.map(e=>Object.assign({},e,{params:Object.assign({},o,e.params),pathname:Me([c,r.encodeLocation?r.encodeLocation(e.pathname.replace(/%/g,`%25`).replace(/\?/g,`%3F`).replace(/#/g,`%23`)).pathname:e.pathname]),pathnameBase:e.pathnameBase===`/`?c:Me([c,r.encodeLocation?r.encodeLocation(e.pathnameBase.replace(/%/g,`%25`).replace(/\?/g,`%3F`).replace(/#/g,`%23`)).pathname:e.pathnameBase])})),i,n);return t&&h?_.createElement(et.Provider,{value:{location:{pathname:`/`,search:``,hash:``,state:null,key:`default`,mask:void 0,...d},navigationType:`POP`}},h):h}function St(){let e=Lt(),t=Re(e)?`${e.status} ${e.statusText}`:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,r=`rgba(200,200,200, 0.5)`,i={padding:`0.5rem`,backgroundColor:r},a={padding:`2px 4px`,backgroundColor:r},o=null;return console.error(`Error handled by React Router default ErrorBoundary:`,e),o=_.createElement(_.Fragment,null,_.createElement(`p`,null,`ð¿ Hey developer ð`),_.createElement(`p`,null,`You can provide a way better UX than this when your app throws errors by providing your own `,_.createElement(`code`,{style:a},`ErrorBoundary`),` or`,` `,_.createElement(`code`,{style:a},`errorElement`),` prop on your route.`)),_.createElement(_.Fragment,null,_.createElement(`h2`,null,`Unexpected Application
12Error!`),_.createElement(`h3`,{style:{fontStyle:`italic`}},t),n?_.createElement(`pre`,{style:i},n):null,o)}var Ct=_.createElement(St,null),wt=class extends _.Component{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?t.error:e.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){this.props.onError?this.props.onError(e,t):console.error(`React Router caught the following error during render`,e)}render(){let e=this.state.error;if(this.context&&typeof e==`object`&&e&&`digest`in e&&typeof e.digest==`string`){let t=st(e.digest);t&&(e=t)}let t=e===void 0?this.props.children:_.createElement(tt.Provider,{value:this.props.routeContext},_.createElement(nt.Provider,{value:e,children:this.props.component}));return this.context?_.createElement(Et,{error:e},t):t}};wt.contextType=Je;var Tt=new WeakMap;function Et({children:e,error:t}){let{basename:n}=_.useContext($e);if(typeof t==`object`&&t&&`digest`in t&&typeof t.digest==`string`){let e=ot(t.digest);if(e){let r=Tt.get(t);if(r)throw r;let i=Ve(e.location,n),a=i.absoluteURL||i.to;if(Ge(a))throw Error(`Invalid redirect location`);if(Be&&!Tt.get(t))if(i.isExternal||e.reloadDocument)window.location.href=a;else{let n=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(i.to,{replace:e.replace}));throw Tt.set(t,n),n}return _.createElement(`meta`,{httpEquiv:`refresh`,content:`0;url=${a}`})}}return e}function Dt({routeContext:e,match:t,children:n}){let r=_.useContext(Ke);return r&&r.static&&r.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(r.staticContext._deepestRenderedBoundaryId=t.route.id),_.createElement(tt.Provider,{value:e},n)}function Ot(e,t=[],n){let r=n?.state;if(e==null){if(!r)return null;if(r.errors)e=r.matches;else if(t.length===0&&!r.initialized&&r.matches.length>0)e=r.matches;else return null}let i=e,a=r?.errors;if(a!=null){let e=i.findIndex(e=>e.route.id&&a?.[e.route.id]!==void 0);k(e>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(a).join(`,`)}`),i=i.slice(0,Math.min(i.length,e+1))}let o=!1,s=-1;if(n&&r){o=r.renderFallback;for(let e=0;e<i.length;e++){let t=i[e];if((t.route.HydrateFallback||t.route.hydrateFallbackElement)&&(s=e),t.route.id){let{loaderData:e,errors:a}=r,c=t.route.loader&&!e.hasOwnProperty(t.route.id)&&(!a||a[t.route.id]===void 0);if(t.route.lazy||c){n.isStatic&&(o=!0),i=s>=0?i.slice(0,s+1):[i[0]];break}}}}let c=n?.onError,l=r&&c?(e,t)=>{c(e,{location:r.location,params:r.matches?.[0]?.params??{},pattern:ze(r.matches),errorInfo:t})}:void 0;return i.reduceRight((e,n,c)=>{let u,d=!1,f=null,p=null;r&&(u=a&&n.route.id?a[n.route.id]:void 0,f=n.route.errorElement||Ct,o&&(s<0&&c===0?(Bt(`route-fallback`,!1,"No `HydrateFallback` element provided to render during initial hydration"),d=!0,p=null):s===c&&(d=!0,p=n.route.hydrateFallbackElement||null)));let m=t.concat(i.slice(0,c+1)),h=()=>{let t;return t=u?f:d?p:n.route.Component?_.createElement(n.route.Component,null):n.route.element?n.route.element:e,_.createElement(Dt,{match:n,routeContext:{outlet:e,matches:m,isDataRoute:r!=null},children:t})};return r&&(n.route.ErrorBoundary||n.route.errorElement||c===0)?_.createElement(wt,{location:r.location,revalidation:r.revalidation,component:f,error:u,children:h(),routeContext:{outlet:null,matches:m,isDataRoute:!0},onError:l}):h()},null)}function kt(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function At(e){let t=_.useContext(Ke);return k(t,kt(e)),t}function jt(e){let t=_.useContext(qe);return k(t,kt(e)),t}function Mt(e){let t=_.useContext(tt);return k(t,kt(e)),t}function Nt(e){let t=Mt(e),n=t.matches[t.matches.length-1];return k(n.route.id,`${e} can only be used on routes that contain a unique "id"`),n.route.id}function Pt(){return Nt(`useRouteId`)}function Ft(){let e=jt(`useNavigation`);return _.useMemo(()=>{let{matches:t,historyAction:n,...r}=e.navigation;return r},[e.navigation])}function It(){let{matches:e,loaderData:t}=jt(`useMatches`);return _.useMemo(()=>e.map(e=>P(e,t)),[e,t])}function Lt(){let e=_.useContext(nt),t=jt(`useRouteError`),n=Nt(`useRouteError`);return e===void 0?t.errors?.[n]:e}function Rt(){let{router:e}=At(`useNavigate`),t=Nt(`useNavigate`),n=_.useRef(!1);return ft(()=>{n.current=!0}),_.useCallback(async(r,i={})=>{A(n.current,dt),n.current&&(typeof r==`number`?await e.navigate(r):await e.navigate(r,{fromRouteId:t,...i}))},[e,t])}var zt={};function Bt(e,t,n){!t&&!zt[e]&&(zt[e]=!0,A(!1,n))}_.memo(Vt);function Vt({routes:e,manifest:t,future:n,state:r,isStatic:i,onError:a}){return xt(e,void 0,{manifest:t,state:r,isStatic:i,onError:a,future:n})}function Ht({to:e,replace:t,state:n,relative:r}){k(lt(),`<Navigate> may be used only in the context of a <Router> component.`);let{static:i}=_.useContext($e);A(!i,`<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:a}=_.useContext(tt),{pathname:o}=ut(),s=pt(),c=Ae(e,ke(a),o,r===`path`),l=JSON.stringify(c);return _.useEffect(()=>{s(JSON.parse(l),{replace:t,state:n,relative:r})},[s,l,r,t,n]),null}function Ut(e){return _t(e.context)}function Wt(e){k(!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>.`)}function Gt({basename:e=`/`,children:t=null,location:n,navigationType:r=`POP`,navigator:i,static:a=!1,useTransitions:o}){k(!lt(),`You cannot render a <Router> inside another <Router>. You should never have more than one in your app.`);let s=e.replace(/^\/*/,`/`),c=_.useMemo(()=>({basename:s,navigator:i,static:a,useTransitions:o,future:{}}),[s,i,a,o]);typeof n==`string`&&(n=re(n));let{pathname:l=`/`,search:u=``,hash:d=``,state:f=null,key:p=`default`,mask:m}=n,h=_.useMemo(()=>{let e=we(l,s);return e==null?null:{location:{pathname:e,search:u,hash:d,state:f,key:p,mask:m},navigationType:r}},[s,l,u,d,f,p,r,m]);
12return A(h!=null,`<Router basename="${s}"> is not able to match the URL "${l}${u}${d}" because it does not start with the basename, so the <Router> won't render anything.`),h==null?null:_.createElement($e.Provider,{value:c},_.createElement(et.Provider,{children:t,value:h}))}function Kt({children:e,location:t}){return bt(qt(e),t)}_.Component;function qt(e,t=[]){let n=[];return _.Children.forEach(e,(e,r)=>{if(!_.isValidElement(e))return;let i=[...t,r];if(e.type===_.Fragment){n.push.apply(n,qt(e.props.children,i));return}k(e.type===Wt,`[${typeof e.type==`string`?e.type:e.type.name}] is not a <Route> component. All component children of <Routes> must be a <Route> or <React.Fragment>`),k(!e.props.index||!e.props.children,`An index route cannot have child routes.`);let a={id:e.props.id||i.join(`-`),caseSensitive:e.props.caseSensitive,element:e.props.element,Component:e.props.Component,index:e.props.index,path:e.props.path,middleware:e.props.middleware,loader:e.props.loader,action:e.props.action,hydrateFallbackElement:e.props.hydrateFallbackElement,HydrateFallback:e.props.HydrateFallback,errorElement:e.props.errorElement,ErrorBoundary:e.props.ErrorBoundary,hasErrorBoundary:e.props.hasErrorBoundary===!0||e.props.ErrorBoundary!=null||e.props.errorElement!=null,shouldRevalidate:e.props.shouldRevalidate,handle:e.props.handle,lazy:e.props.lazy};e.props.children&&(a.children=qt(e.props.children,i)),n.push(a)}),n}var Jt=`get`,Yt=`application/x-www-form-urlencoded`;function Xt(e){return typeof HTMLElement<`u`&&e instanceof HTMLElement}function Zt(e){return Xt(e)&&e.tagName.toLowerCase()===`button`}function Qt(e){return Xt(e)&&e.tagName.toLowerCase()===`form`}function $t(e){return Xt(e)&&e.tagName.toLowerCase()===`input`}function en(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function tn(e,t){return e.button===0&&(!t||t===`_self`)&&!en(e)}function nn(e=``){return new URLSearchParams(typeof e==`string`||Array.isArray(e)||e instanceof URLSearchParams?e:Object.keys(e).reduce((t,n)=>{let r=e[n];return t.concat(Array.isArray(r)?r.map(e=>[n,e]):[[n,r]])},[]))}function rn(e,t){let n=nn(e);return t&&t.forEach((e,r)=>{n.has(r)||t.getAll(r).forEach(e=>{n.append(r,e)})}),n}var an=null;function on(){if(an===null)try{new FormData(document.createElement(`form`),0),an=!1}catch{an=!0}return an}var sn=new Set([`application/x-www-form-urlencoded`,`multipart/form-data`,`text/plain`]);function cn(e){return e!=null&&!sn.has(e)?(A(!1,`"${e}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${Yt}"`),null):e}function ln(e,t){let n,r,i,a,o;if(Qt(e)){let o=e.getAttribute(`action`);r=o?we(o,t):null,n=e.getAttribute(`method`)||Jt,i=cn(e.getAttribute(`enctype`))||Yt,a=new FormData(e)}else if(Zt(e)||$t(e)&&(e.type===`submit`||e.type===`image`)){let o=e.form;if(o==null)throw Error(`Cannot submit a <button> or <input type="submit"> without a <form>`);let s=e.getAttribute(`formaction`)||o.getAttribute(`action`);if(r=s?we(s,t):null,n=e.getAttribute(`formmethod`)||o.getAttribute(`method`)||Jt,i=cn(e.getAttribute(`formenctype`))||cn(o.getAttribute(`enctype`))||Yt,a=new FormData(o,e),!on()){let{name:t,type:n,value:r}=e;if(n===`image`){let e=t?`${t}.`:``;a.append(`${e}x`,`0`),a.append(`${e}y`,`0`)}else t&&a.append(t,r)}}else if(Xt(e))throw Error(`Cannot submit element that is not <form>, <button>, or <input type="submit|image">`);else n=Jt,r=null,i=Yt,o=e;return a&&i===`text/plain`&&(o=a,a=void 0),{action:r,method:n.toLowerCase(),encType:i,formData:a,body:o}}Object.getOwnPropertyNames(Object.prototype).sort().join(`\0`);var un={"&":`\\u0026`,">":`\\u003e`,"<":`\\u003c`,"\u2028":`\\u2028`,"\u2029":`\\u2029`},dn=/[&><\u2028\u2029]/g;function fn(e){return e.replace(dn,e=>un[e])}function pn(e,t){if(e===!1||e==null)throw Error(t)}function mn(e,t,n,r){let i=typeof e==`string`?new URL(e,typeof window>`u`?`server://singlefetch/`:window.location.origin):e;return n?i.pathname.endsWith(`/`)?i.pathname=`${i.pathname}_.${r}`:i.pathname=`${i.pathname}.${r}`:i.pathname===`/`?i.pathname=`_root.${r}`:t&&we(i.pathname,t)===`/`?i.pathname=`${Ne(t)}/_root.${r}`:i.pathname=`${Ne(i.pathname)}.${r}`,i}async function hn(e,t){if(e.id in t)return t[e.id];try{let n=await S(()=>import(e.module),[]);return t[e.id]=n,n}catch(t){return console.error(`Error loading route module \`${e.module}\`, reloading page...`),console.error(t),window.__reactRouterContext&&window.__reactRouterContext.
12isSpaMode,window.location.reload(),new Promise(()=>{})}}function gn(e){return e!=null&&typeof e.page==`string`}function _n(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`}async function vn(e,t,n){return Cn((await Promise.all(e.map(async e=>{let r=t.routes[e.route.id];if(r){let e=await hn(r,n);return e.links?e.links():[]}return[]}))).flat(1).filter(_n).filter(e=>e.rel===`stylesheet`||e.rel===`preload`).map(e=>e.rel===`stylesheet`?{...e,rel:`prefetch`,as:`style`}:{...e,rel:`prefetch`}))}function yn(e,t,n,r,i,a){let o=(e,t)=>n[t]?e.route.id!==n[t].route.id:!0,s=(e,t)=>n[t].pathname!==e.pathname||n[t].route.path?.endsWith(`*`)&&n[t].params[`*`]!==e.params[`*`];return a===`assets`?t.filter((e,t)=>o(e,t)||s(e,t)):a===`data`?t.filter((t,a)=>{let c=r.routes[t.route.id];if(!c||!c.hasLoader)return!1;if(o(t,a)||s(t,a))return!0;if(t.route.shouldRevalidate){let r=t.route.shouldRevalidate({currentUrl:new URL(i.pathname+i.search+i.hash,window.origin),currentParams:n[0]?.params||{},nextUrl:new URL(e,window.origin),nextParams:t.params,defaultShouldRevalidate:!0});if(typeof r==`boolean`)return r}return!0}):[]}function bn(e,t,{includeHydrateFallback:n}={}){return xn(e.map(e=>{let r=t.routes[e.route.id];if(!r)return[];let i=[r.module];return r.clientActionModule&&(i=i.concat(r.clientActionModule)),r.clientLoaderModule&&(i=i.concat(r.clientLoaderModule)),n&&r.hydrateFallbackModule&&(i=i.concat(r.hydrateFallbackModule)),r.imports&&(i=i.concat(r.imports)),i}).flat(1))}function xn(e){return[...new Set(e)]}function Sn(e){let t={},n=Object.keys(e).sort();for(let r of n)t[r]=e[r];return t}function Cn(e,t){let n=new Set,r=new Set(t);return e.reduce((e,i)=>{if(t&&!gn(i)&&i.as===`script`&&i.href&&r.has(i.href))return e;let a=JSON.stringify(Sn(i));return n.has(a)||(n.add(a),e.push({key:a,link:i})),e},[])}function wn(){let e=_.useContext(Ke);return pn(e,`You must render this element inside a <DataRouterContext.Provider> element`),e}function Tn(){let e=_.useContext(qe);return pn(e,`You must render this element inside a <DataRouterStateContext.Provider> element`),e}var En=_.createContext(void 0);En.displayName=`FrameworkContext`;function Dn(){let e=_.useContext(En);return pn(e,`You must render this element inside a <HydratedRouter> element`),e}function On(e,t){let n=_.useContext(En),[r,i]=_.useState(!1),[a,o]=_.useState(!1),{onFocus:s,onBlur:c,onMouseEnter:l,onMouseLeave:u,onTouchStart:d}=t,f=_.useRef(null);_.useEffect(()=>{if(e===`render`&&o(!0),e===`viewport`){let e=new IntersectionObserver(e=>{e.forEach(e=>{o(e.isIntersecting)})},{threshold:.5});return f.current&&e.observe(f.current),()=>{e.disconnect()}}},[e]),_.useEffect(()=>{if(r){let e=setTimeout(()=>{o(!0)},100);return()=>{clearTimeout(e)}}},[r]);let p=()=>{i(!0)},m=()=>{i(!1),o(!1)};return n?e===`intent`?[a,f,{onFocus:kn(s,p),onBlur:kn(c,m),onMouseEnter:kn(l,p),onMouseLeave:kn(u,m),onTouchStart:kn(d,p)}]:[a,f,{}]:[!1,f,{}]}function kn(e,t){return n=>{e&&e(n),n.defaultPrevented||t(n)}}function An({page:e,...t}){let n=Ye(),{nonce:r}=Dn(),{router:i}=wn(),a=_.useMemo(()=>ie(i.routes,e,i.basename),[i.routes,e,i.basename]);return a?(t.nonce==null&&r&&(t={...t,nonce:r}),n?_.createElement(Mn,{page:e,matches:a,...t}):_.createElement(Nn,{page:e,matches:a,...t})):null}function jn(e){let{manifest:t,routeModules:n}=Dn(),[r,i]=_.useState([]);return _.useEffect(()=>{let r=!1;return vn(e,t,n).then(e=>{r||i(e)}),()=>{r=!0}},[e,t,n]),r}function Mn({page:e,matches:t,...n}){let r=ut(),{future:i}=Dn(),{basename:a}=wn(),o=_.useMemo(()=>{if(e===r.pathname+r.search+r.hash)return[];let n=mn(e,a,i.v8_trailingSlashAwareDataRequests,`rsc`),o=!1,s=[];for(let e of t)typeof e.route.shouldRevalidate==`function`?o=!0:s.push(e.route.id);return o&&s.length>0&&n.searchParams.set(`_routes`,s.join(`,`)),[n.pathname+n.search]},[a,i.v8_trailingSlashAwareDataRequests,e,r,t]);return _.createElement(_.Fragment,null,o.map(e=>_.createElement(`link`,{key:e,rel:`prefetch`,as:`fetch`,href:e,...n})))}function Nn({page:e,matches:t,...n}){let r=ut(),{future:i,manifest:a,routeModules:o}=Dn(),{basename:s}=wn(),{loaderData:c,matches:l}=Tn(),u=_.useMemo(()=>yn(e,t,l,a,r,`data`),[e,t,l,a,r]),d=_.useMemo(()=>yn(e,t,l,a,r,`assets`),[e,t,l,a,r]),f=_.useMemo(()=>
12{if(e===r.pathname+r.search+r.hash)return[];let n=new Set,l=!1;if(t.forEach(e=>{let t=a.routes[e.route.id];!t||!t.hasLoader||(!u.some(t=>t.route.id===e.route.id)&&e.route.id in c&&o[e.route.id]?.shouldRevalidate||t.hasClientLoader?l=!0:n.add(e.route.id))}),n.size===0)return[];let d=mn(e,s,i.v8_trailingSlashAwareDataRequests,`data`);return l&&n.size>0&&d.searchParams.set(`_routes`,t.filter(e=>n.has(e.route.id)).map(e=>e.route.id).join(`,`)),[d.pathname+d.search]},[s,i.v8_trailingSlashAwareDataRequests,c,r,a,u,t,e,o]),p=_.useMemo(()=>bn(d,a),[d,a]),m=jn(d);return _.createElement(_.Fragment,null,f.map(e=>_.createElement(`link`,{key:e,rel:`prefetch`,as:`fetch`,href:e,...n})),p.map(e=>_.createElement(`link`,{key:e,rel:`modulepreload`,href:e,...n})),m.map(({key:e,link:t})=>_.createElement(`link`,{key:e,nonce:n.nonce,...t,crossOrigin:t.crossOrigin??n.crossOrigin})))}function Pn(...e){return t=>{e.forEach(e=>{typeof e==`function`?e(t):e!=null&&(e.current=t)})}}_.Component;var Fn=typeof window<`u`&&window.document!==void 0&&window.document.createElement!==void 0;try{Fn&&(window.__reactRouterVersion=`7.18.2`)}catch{}function In({basename:e,children:t,useTransitions:n,window:r}){let i=_.useRef();i.current??=O({window:r,v5Compat:!0});let a=i.current,[o,s]=_.useState({action:a.action,location:a.location}),c=_.useCallback(e=>{n===!1?s(e):_.startTransition(()=>s(e))},[n]);return _.useLayoutEffect(()=>a.listen(c),[a,c]),_.createElement(Gt,{basename:e,children:t,location:o.location,navigationType:o.action,navigator:a,useTransitions:n})}function Ln({basename:e,children:t,history:n,useTransitions:r}){let[i,a]=_.useState({action:n.action,location:n.location}),o=_.useCallback(e=>{r===!1?a(e):_.startTransition(()=>a(e))},[r]);return _.useLayoutEffect(()=>n.listen(o),[n,o]),_.createElement(Gt,{basename:e,children:t,location:i.location,navigationType:i.action,navigator:n,useTransitions:r})}Ln.displayName=`unstable_HistoryRouter`;var Rn=_.forwardRef(function({onClick:e,discover:t=`render`,prefetch:n=`none`,relative:r,reloadDocument:i,replace:a,mask:o,state:s,target:c,to:l,preventScrollReset:u,viewTransition:d,defaultShouldRevalidate:f,...p},m){let{basename:h,navigator:g,useTransitions:v}=_.useContext($e),y=typeof l==`string`&&C.test(l),b=Ve(l,h);l=b.to;let x=ct(l,{relative:r}),S=ut(),w=null;if(o){let e=Ae(o,[],S.mask?S.mask.pathname:`/`,!0);h!==`/`&&(e.pathname=e.pathname===`/`?h:Me([h,e.pathname])),w=g.createHref(e)}let[T,E,D]=On(n,p),O=Gn(l,{replace:a,mask:o,state:s,target:c,preventScrollReset:u,relative:r,viewTransition:d,defaultShouldRevalidate:f,useTransitions:v});function k(t){e&&e(t),t.defaultPrevented||O(t)}let A=!(b.isExternal||i),j=_.createElement(`a`,{...p,...D,href:(A?w:void 0)||b.absoluteURL||x,onClick:A?k:e,ref:Pn(m,E),target:c,"data-discover":!y&&t===`render`?`true`:void 0});return T&&!y?_.createElement(_.Fragment,null,j,_.createElement(An,{page:x})):j});Rn.displayName=`Link`;var zn=_.forwardRef(function({"aria-current":e=`page`,caseSensitive:t=!1,className:n=``,end:r=!1,style:i,to:a,viewTransition:o,children:s,...c},l){let u=yt(a,{relative:c.relative}),d=ut(),f=_.useContext(qe),{navigator:p,basename:m}=_.useContext($e),h=f!=null&&nr(u)&&o===!0,g=p.encodeLocation?p.encodeLocation(u).pathname:u.pathname,v=d.pathname,y=f&&f.navigation&&f.navigation.location?f.navigation.location.pathname:null;t||(v=v.toLowerCase(),y=y?y.toLowerCase():null,g=g.toLowerCase()),y&&m&&(y=we(y,m)||y);let b=g!==`/`&&g.endsWith(`/`)?g.length-1:g.length,x=v===g||!r&&v.startsWith(g)&&v.charAt(b)===`/`,S=y!=null&&(y===g||!r&&y.startsWith(g)&&y.charAt(g.length)===`/`),C={isActive:x,isPending:S,isTransitioning:h},w=x?e:void 0,T;T=typeof n==`function`?n(C):[n,x?`active`:null,S?`pending`:null,h?`transitioning`:null].filter(Boolean).join(` `);let E=typeof i==`function`?i(C):i;return _.createElement(Rn,{...c,"aria-current":w,className:T,ref:l,style:E,to:a,viewTransition:o},typeof s==`function`?s(C):s)});zn.displayName=`NavLink`;var Bn=_.forwardRef(({discover:e=`render`,fetcherKey:t,navigate:n,reloadDocument:r,replace:i,state:a,method:o=Jt,action:s,onSubmit:c,relative:l,preventScrollReset:u,viewTransition:d,defaultShouldRevalidate:f,...p},m)=>{let{useTransitions:h}=_.useContext($e),g=Yn(),v=Xn(s,{relative:l}),y=o.toLowerCase()===`get`?`get`:`post`,b=typeof s==`string`&&C.test(s);return _.createElement(`form`,{ref:m,method:y,action:v,onSubmit:r?c:e=>{if(c&&c(e),e.defaultPrevented)return;e.preventDefault();let r=e.nativeEvent.submitter,s=r?.getAttribute(`formmethod`)||o,p=()=>g(r||e.currentTarget,{fetcherKey:t,method:s,navigate:n,replace:i,state:a,relative:l,preventScrollReset:u,viewTransition:d,defaultShouldRevalidate:f});h&&n!==!1?_.startTransition(()=>p()):p()},...p,"data-discover":!b&&e===`render`?`true`:void 0})});Bn.displayName=`Form`;function Vn({getKey:e,storageKey:t,...n}){let r=_.useContext(En),{basename:i}=_.useContext($e),a=ut(),o=It();er({getKey:e,storageKey:t});let s=_.useMemo(()=>
12{if(!r||!e)return null;let t=$n(a,o,i,e);return t===a.key?null:t},[]);if(!r||r.isSpaMode)return null;let c=((e,t)=>{if(!window.history.state||!window.history.state.key){let e=Math.random().toString(32).slice(2);window.history.replaceState({key:e},``)}try{let n=JSON.parse(sessionStorage.getItem(e)||`{}`)[t||window.history.state.key];typeof n==`number`&&window.scrollTo(0,n)}catch(t){console.error(t),sessionStorage.removeItem(e)}}).toString();return n.nonce==null&&r?.nonce&&(n.nonce=r.nonce),_.createElement(`script`,{...n,suppressHydrationWarning:!0,dangerouslySetInnerHTML:{__html:`(${c})(${fn(JSON.stringify(t||Zn))}, ${fn(JSON.stringify(s))})`}})}Vn.displayName=`ScrollRestoration`;function Hn(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function Un(e){let t=_.useContext(Ke);return k(t,Hn(e)),t}function Wn(e){let t=_.useContext(qe);return k(t,Hn(e)),t}function Gn(e,{target:t,replace:n,mask:r,state:i,preventScrollReset:a,relative:o,viewTransition:s,defaultShouldRevalidate:c,useTransitions:l}={}){let u=pt(),d=ut(),f=yt(e,{relative:o});return _.useCallback(p=>{if(tn(p,t)){p.preventDefault();let t=n===void 0?ne(d)===ne(f):n,m=()=>u(e,{replace:t,mask:r,state:i,preventScrollReset:a,relative:o,viewTransition:s,defaultShouldRevalidate:c});l?_.startTransition(()=>m()):m()}},[d,u,f,n,r,i,t,e,a,o,s,c,l])}function Kn(e){A(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=_.useRef(nn(e)),n=_.useRef(!1),r=ut(),i=_.useMemo(()=>rn(r.search,n.current?null:t.current),[r.search]),a=pt();return[i,_.useCallback((e,t)=>{let r=nn(typeof e==`function`?e(new URLSearchParams(i)):e);n.current=!0,a(`?`+r,t)},[a,i])]}var qn=0,Jn=()=>`__${String(++qn)}__`;function Yn(){let{router:e}=Un(`useSubmit`),{basename:t}=_.useContext($e),n=Pt(),r=e.fetch,i=e.navigate;return _.useCallback(async(e,a={})=>{let{action:o,method:s,encType:c,formData:l,body:u}=ln(e,t);a.navigate===!1?await r(a.fetcherKey||Jn(),n,a.action||o,{defaultShouldRevalidate:a.defaultShouldRevalidate,preventScrollReset:a.preventScrollReset,formData:l,body:u,formMethod:a.method||s,formEncType:a.encType||c,flushSync:a.flushSync}):await i(a.action||o,{defaultShouldRevalidate:a.defaultShouldRevalidate,preventScrollReset:a.preventScrollReset,formData:l,body:u,formMethod:a.method||s,formEncType:a.encType||c,replace:a.replace,state:a.state,fromRouteId:n,flushSync:a.flushSync,viewTransition:a.viewTransition})},[r,i,t,n])}function Xn(e,{relative:t}={}){let{basename:n}=_.useContext($e),r=_.useContext(tt);k(r,`useFormAction must be used inside a RouteContext`);let[i]=r.matches.slice(-1),a={...yt(e||`.`,{relative:t})},o=ut();if(e==null){a.search=o.search;let e=new URLSearchParams(a.search),t=e.getAll(`index`);if(t.some(e=>e===``)){e.delete(`index`),t.filter(e=>e).forEach(t=>e.append(`index`,t));let n=e.toString();a.search=n?`?${n}`:``}}return(!e||e===`.`)&&i.route.index&&(a.search=a.search?a.search.replace(/^\?/,`?index&`):`?index`),n!==`/`&&(a.pathname=a.pathname===`/`?n:Me([n,a.pathname])),ne(a)}var Zn=`react-router-scroll-positions`,Qn={};function $n(e,t,n,r){let i=null;return r&&(i=r(n===`/`?e:{...e,pathname:we(e.pathname,n)||e.pathname},t)),i??=e.key,i}function er({getKey:e,storageKey:t}={}){let{router:n}=Un(`useScrollRestoration`),{restoreScrollPosition:r,preventScrollReset:i}=Wn(`useScrollRestoration`),{basename:a}=_.useContext($e),o=ut(),s=It(),c=Ft();_.useEffect(()=>(window.history.scrollRestoration=`manual`,()=>{window.history.scrollRestoration=`auto`}),[]),tr(_.useCallback(()=>{if(c.state===`idle`){let t=$n(o,s,a,e);Qn[t]=window.scrollY}try{sessionStorage.setItem(t||Zn,JSON.stringify(Qn))}catch(e){A(!1,`Failed to save scroll positions in sessionStorage, <ScrollRestoration /> will not work properly (${e}).`)}window.history.scrollRestoration=`auto`},[c.state,e,a,o,s,t])),typeof document<`u`&&(_.useLayoutEffect(()=>{try{let e=sessionStorage.getItem(t||Zn);e&&(Qn=JSON.parse(e))}catch{}},[t]),_.useLayoutEffect(()=>{let t=n?.enableScrollRestoration(Qn,()=>window.scrollY,e?(t,n)=>$n(t,n,a,e):void 0);return()=>t&&t()},[n,a,e]),_.useLayoutEffect(()=>{if(r!==!1){if(typeof r==`number`){window.scrollTo(0,r);return}try{if(o.hash){let e=document.getElementById(decodeURIComponent(o.hash.slice(1)));if(e){e.scrollIntoView();return}}}catch{A(!1,`"${o.hash.slice(1)}" is not a decodable element ID. The view will not scroll to it.`)}i!==!0&&window.scrollTo(0,0)}},[o,r,i]))}function tr(e,t){let{capture:n}=t||{};_.useEffect(()=>{let t=n==null?void 0:{capture:n};return window.addEventListener(`pagehide`,e,t),()=>{window.removeEventListener(`pagehide`,e,t)}},[e,n])}function nr(e,{relative:t}={}){let n=_.useContext(Xe);k(n!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:r}=Un(`useViewTransitionState`),i=yt(e,{relative:t});if(!n.isTransitioning)return!1;let a=we(n.currentLocation.pathname,r)||n.currentLocation.pathname,o=we(n.nextLocation.pathname,r)||n.nextLocation.pathname;return be(i.pathname,o)!=null||be(i.pathname,a)!=null}var rr=()=>{window.va||(window.va=function(...e){window.vaq||(window.vaq=[]),window.vaq.push(e)})},ir=`@vercel/analytics`,ar=`2.0.1`;function or(){return typeof window<`u`}function sr(){return`production`}function cr(e=`auto`){if(e===`auto`){window.vam=sr();return}window.vam=e}function lr(){return(or()?window.vam:sr())||`production`}function ur(){return lr()===`development`}function dr(e){return e.scriptSrc?pr(e.scriptSrc):ur()?`https://va.vercel-scripts.com/v1/script.debug.js`:e.basePath?pr(`${e.basePath}
12/insights/script.js`):`/_vercel/insights/script.js`}function fr(e,t){let n=e;if(t)try{n={...JSON.parse(t)?.analytics,...e}}catch{}cr(n.mode);let r={sdkn:ir+(n.framework?`/${n.framework}`:``),sdkv:ar};return n.disableAutoTrack&&(r.disableAutoTrack=`1`),n.viewEndpoint&&(r.viewEndpoint=pr(n.viewEndpoint)),n.eventEndpoint&&(r.eventEndpoint=pr(n.eventEndpoint)),n.sessionEndpoint&&(r.sessionEndpoint=pr(n.sessionEndpoint)),ur()&&n.debug===!1&&(r.debug=`false`),n.dsn&&(r.dsn=n.dsn),n.endpoint?r.endpoint=n.endpoint:n.basePath&&(r.endpoint=pr(`${n.basePath}/insights`)),{beforeSend:n.beforeSend,src:dr(n),dataset:r}}function pr(e){return e.startsWith(`http://`)||e.startsWith(`https://`)||e.startsWith(`/`)?e:`/${e}`}function mr(e={debug:!0},t){var n;if(!or())return;let{beforeSend:r,src:i,dataset:a}=fr(e,t);if(rr(),r&&((n=window.va)==null||n.call(window,`beforeSend`,r)),document.head.querySelector(`script[src*="${i}"]`))return;let o=document.createElement(`script`);o.src=i;for(let[e,t]of Object.entries(a))o.dataset[e]=t;o.defer=!0,o.onerror=()=>{let e=ur()?`Please check if any ad blockers are enabled and try again.`:`Be sure to enable Web Analytics for your project and deploy again. See https://vercel.com/docs/analytics/quickstart for more information.`;console.log(`[Vercel Web Analytics] Failed to load script from ${i}. ${e}`)},document.head.appendChild(o)}function hr({route:e,path:t}){var n;(n=window.va)==null||n.call(window,`pageview`,{route:e,path:t})}function gr(){if(!(typeof process>`u`))return{}.REACT_APP_VERCEL_OBSERVABILITY_BASEPATH}function _r(){if(!(typeof process>`u`))return{}.REACT_APP_VERCEL_OBSERVABILITY_CLIENT_CONFIG}function vr(e){return(0,_.useEffect)(()=>{var t;e.beforeSend&&((t=window.va)==null||t.call(window,`beforeSend`,e.beforeSend))},[e.beforeSend]),(0,_.useEffect)(()=>{mr({framework:e.framework||`react`,basePath:e.basePath??gr(),...e.route!==void 0&&{disableAutoTrack:!0},...e},e.configString??_r())},[]),(0,_.useEffect)(()=>{e.route&&e.path&&hr({route:e.route,path:e.path})},[e.route,e.path]),null}var yr={theme:`crew.theme`,loop:`crew.loop`,waitlist:`crew.waitlist`};function br(e,t){try{let n=localStorage.getItem(e);return n==null?t:JSON.parse(n)}catch{return t}}function xr(e,t){try{localStorage.setItem(e,JSON.stringify(t))}catch{}}var Sr=yr.theme;function Cr(){try{let e=localStorage.getItem(Sr);return e===`dark`||e===`light`?e:null}catch{return null}}function wr(){let e=document.documentElement.getAttribute(`data-theme`);return e===`dark`||e===`light`?e:Cr()??`light`}function Tr(e){document.documentElement.setAttribute(`data-theme`,e);try{localStorage.setItem(Sr,e)}catch{}}function Er(){let e=wr()===`dark`?`light`:`dark`;return Tr(e),e}function Dr(){let e=Cr()??`light`;return Tr(e),e}function Or(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols==`function`)for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}function kr(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||=Promise)(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})}var Ar=e=>e?(...t)=>e(...t):(...e)=>fetch(...e),jr=class extends Error{constructor(e,t=`FunctionsError`,n){super(e),this.name=t,this.context=n}toJSON(){return{name:this.name,message:this.message,context:this.context}}},Mr=class extends jr{constructor(e){super(`Failed to send a request to the Edge Function`,`FunctionsFetchError`,e)}},Nr=class extends jr{constructor(e){super(`Relay Error invoking the Edge Function`,`FunctionsRelayError`,e)}},Pr=class extends jr{constructor(e){super(`Edge Function returned a non-2xx status code`,`FunctionsHttpError`,e)}},Fr;(function(e){e.Any=`any`,e.ApNortheast1=`ap-northeast-1`,e.ApNortheast2=`ap-northeast-2`,e.ApSouth1=`ap-south-1`,e.ApSoutheast1=`ap-southeast-1`,e.ApSoutheast2=`ap-southeast-2`,e.CaCentral1=`ca-central-1`,e.EuCentral1=`eu-central-1`,e.EuWest1=`eu-west-1`,e.EuWest2=`eu-west-2`,e.EuWest3=`eu-west-3`,e.SaEast1=`sa-east-1`,e.UsEast1=`us-east-1`,e.UsWest1=`us-west-1`,e.UsWest2=`us-west-2`})(Fr||={});var Ir=class{constructor(e,{headers:t={},customFetch:n,region:r=Fr.Any}={}){this.url=e,this.headers=t,this.region=r,this.fetch=Ar(n)}setAuth(e){this.headers.Authorization=`Bearer ${e}`}invoke(e){return kr(this,arguments,void 0,function*(e,t={}){let n,r;try{let{headers:i,method:a,body:o,signal:s,timeout:c}=t,l={},{region:u}=t;u||=this.region;let d=new URL(`${this.url}/${e}`);u&&u!==`any`&&(l[`x-region`]=u,d.searchParams.set(`forceFunctionRegion`,u));let f;o&&(i&&!Object.prototype.hasOwnProperty.call(i,`Content-Type`)||!i)?typeof Blob<`u`&&o instanceof Blob||o instanceof ArrayBuffer?(l[`Content-Type`]=`application/octet-stream`,f=o):typeof o==`string`?(l[`Content-Type`]=`text/plain`,f=o):typeof FormData<`u`&&o instanceof FormData?f=o:(l[`Content-Type`]=`application/json`,f=JSON.stringify(o)):f=o&&typeof o!=`string`&&!(typeof Blob<`u`&&o instanceof Blob)&&!(o instanceof ArrayBuffer)&&!(typeof FormData<`u`&&o instanceof FormData)?JSON.stringify(o):o;let p=s;c&&(r=new AbortController,n=setTimeout(()=>r.abort(),c),s?(p=r.signal,s.addEventListener(`abort`,()=>r.abort())):p=r.signal);let m=yield this.fetch(d.toString(),{method:a||`POST`,headers:Object.assign(Object.assign(Object.assign({},l),this.headers),i),body:f,signal:p}).catch(e=>{throw new Mr(e)}),h=m.headers.get(`x-relay-error`);if(h&&h===`true`)throw new Nr(m);if(!m.ok)throw new Pr(m);let g=(m.headers.get(`Content-Type`)??`text/plain`).split(`;`)[0].trim(),_;return _=g===`application/json`?yield m.json():g===`application/octet-stream`||g===`application/pdf`?yield m.blob():g===`text/event-stream`?m:g===`multipart/form-data`?yield m.formData():yield m.text(),{data:_,error:null,response:m}}catch(e){return{data:null,error:e,response:e instanceof Pr||e instanceof Nr?e.context:void 0}}finally{n&&clearTimeout(n)}})}},Lr=3,Rr=e=>Math.min(1e3*2**e,3e4),zr=[520,503],Br=[`GET`,`HEAD`,`OPTIONS`],Vr=class extends
12Error{constructor(e){super(e.message),this.name=`PostgrestError`,this.details=e.details,this.hint=e.hint,this.code=e.code}toJSON(){return{name:this.name,message:this.message,details:this.details,hint:this.hint,code:this.code}}};function Hr(e,t){return new Promise(n=>{if(t?.aborted){n();return}let r=setTimeout(()=>{t?.removeEventListener(`abort`,i),n()},e);function i(){clearTimeout(r),n()}t?.addEventListener(`abort`,i)})}function Ur(e,t,n,r){return!(!r||n>=Lr||!Br.includes(e)||!zr.includes(t))}var Wr=class{constructor(e){this.shouldThrowOnError=!1,this.retryEnabled=!0,this.method=e.method,this.url=e.url,this.headers=new Headers(e.headers),this.schema=e.schema,this.body=e.body,this.shouldThrowOnError=e.shouldThrowOnError??!1,this.signal=e.signal,this.isMaybeSingle=e.isMaybeSingle??!1,this.shouldStripNulls=e.shouldStripNulls??!1,this.urlLengthLimit=e.urlLengthLimit??8e3,this.retryEnabled=e.retry??!0,e.fetch?this.fetch=e.fetch:this.fetch=fetch}throwOnError(){return this.shouldThrowOnError=!0,this}stripNulls(){if(this.headers.get(`Accept`)===`text/csv`)throw Error(`stripNulls() cannot be used with csv()`);return this.shouldStripNulls=!0,this}setHeader(e,t){return this.headers=new Headers(this.headers),this.headers.set(e,t),this}retry(e){return this.retryEnabled=e,this}then(e,t){var n=this;if(this.schema===void 0||([`GET`,`HEAD`].includes(this.method)?this.headers.set(`Accept-Profile`,this.schema):this.headers.set(`Content-Profile`,this.schema)),this.method!==`GET`&&this.method!==`HEAD`&&this.headers.set(`Content-Type`,`application/json`),this.shouldStripNulls){let e=this.headers.get(`Accept`);e===`application/vnd.pgrst.object+json`?this.headers.set(`Accept`,`application/vnd.pgrst.object+json;nulls=stripped`):(!e||e===`application/json`)&&this.headers.set(`Accept`,`application/vnd.pgrst.array+json;nulls=stripped`)}let r=this.fetch,i=(async()=>{let e=0;for(;;){let t={};n.headers.forEach((e,n)=>{t[n]=e}),e>0&&(t[`X-Retry-Count`]=String(e));let i;try{i=await r(n.url.toString(),{method:n.method,headers:t,body:JSON.stringify(n.body,(e,t)=>typeof t==`bigint`?t.toString():t),signal:n.signal})}catch(t){if(t?.name===`AbortError`||t?.code===`ABORT_ERR`||!Br.includes(n.method))throw t;if(n.retryEnabled&&e<Lr){let t=Rr(e);e++,await Hr(t,n.signal);continue}throw t}if(Ur(n.method,i.status,e,n.retryEnabled)){let t=i.headers?.get(`Retry-After`)??null,r=t===null?Rr(e):Math.max(0,parseInt(t,10)||0)*1e3;await i.text(),e++,await Hr(r,n.signal);continue}return await n.processResponse(i)}})();return this.shouldThrowOnError||(i=i.catch(e=>{let t=``,n=``,r=``,i=e?.cause;if(i){let n=i?.message??``,r=i?.code??``;t=`${e?.name??`FetchError`}: ${e?.message}`,t+=`\n\nCaused by: ${i?.name??`Error`}: ${n}`,r&&(t+=` (${r})`),i?.stack&&(t+=`\n${i.stack}`)}else t=e?.stack??``;let a=this.url.toString().length;return e?.name===`AbortError`||e?.code===`ABORT_ERR`?(r=``,n=`Request was aborted (timeout or manual cancellation)`,a>this.urlLengthLimit&&(n+=`. Note: Your request URL is ${a} characters, which may exceed server limits. If selecting many fields, consider using views. If filtering with large arrays (e.g., .in('id', [many IDs])), consider using an RPC function to pass values server-side.`)):(i?.name===`HeadersOverflowError`||i?.code===`UND_ERR_HEADERS_OVERFLOW`)&&(r=``,n=`HTTP headers exceeded server limits (typically 16KB)`,a>this.urlLengthLimit&&(n+=`. Your request URL is ${a} characters. If selecting many fields, consider using views. If filtering with large arrays (e.g., .in('id', [200+ IDs])), consider using an RPC function instead.`)),{success:!1,error:{message:`${e?.name??`FetchError`}: ${e?.message}`,details:t,hint:n,code:r},data:null,count:null,status:0,statusText:``}})),i.then(e,t)}async processResponse(e){var t=this;let n=null,r=null,i=null,a=e.status,o=e.statusText;if(e.ok){if(t.method!==`HEAD`){let i=await e.text();if(i!==``)if(t.headers.get(`Accept`)===`text/csv`)r=i;else if(t.headers.get(`Accept`)&&t.headers.get(`Accept`)?.includes(`application/vnd.pgrst.plan+text`))r=i;else try{r=JSON.parse(i)}catch{if(n={message:i},r=null,t.shouldThrowOnError)throw new Vr({message:i,details:``,hint:``,code:``})}}let s=t.headers.get(`Prefer`)?.match(/count=(exact|planned|estimated)/),c=e.headers.get(`content-range`)?.split(`/`);s&&c&&c.length>1&&(i=parseInt(c[1])),t.isMaybeSingle&&Array.isArray(r)&&(r.length>1?(n={code:`PGRST116`,details:`Results contain ${r.length} rows, application/vnd.pgrst.object+json requires 1 row`,hint:null,message:`JSON object requested, multiple (or no) rows returned`},r=null,i=null,a=406,o=`Not Acceptable`):r=r.length===1?r[0]:null)}else{let i=await e.text();try{n=JSON.parse(i),Array.isArray(n)&&e.status===404&&(r=[],n=null,a=200,o=`OK`)}
vendor: 10,009 bytes, line 12
12catch{e.status===404&&i===``?(a=204,o=`No Content`):n={message:i}}if(n&&t.shouldThrowOnError)throw new Vr(n)}return{success:n===null,error:n,data:r,count:i,status:a,statusText:o}}returns(){return this}overrideTypes(){return this}},Gr=class extends Wr{throwOnError(){return super.throwOnError()}select(e){let t=!1,n=(e??`*`).split(``).map(e=>/\s/.test(e)&&!t?``:(e===`"`&&(t=!t),e)).join(``);return this.url.searchParams.set(`select`,n),this.headers.append(`Prefer`,`return=representation`),this}order(e,{ascending:t=!0,nullsFirst:n,foreignTable:r,referencedTable:i=r}={}){let a=i?`${i}.order`:`order`,o=this.url.searchParams.get(a);return this.url.searchParams.set(a,`${o?`${o},`:``}${e}.${t?`asc`:`desc`}${n===void 0?``:n?`.nullsfirst`:`.nullslast`}`),this}limit(e,{foreignTable:t,referencedTable:n=t}={}){let r=n===void 0?`limit`:`${n}.limit`;return this.url.searchParams.set(r,`${e}`),this}range(e,t,{foreignTable:n,referencedTable:r=n}={}){let i=r===void 0?`offset`:`${r}.offset`,a=r===void 0?`limit`:`${r}.limit`;return this.url.searchParams.set(i,`${e}`),this.url.searchParams.set(a,`${t-e+1}`),this}abortSignal(e){return this.signal=e,this}single(){return this.headers.set(`Accept`,`application/vnd.pgrst.object+json`),this}maybeSingle(){return this.isMaybeSingle=!0,this}csv(){return this.headers.set(`Accept`,`text/csv`),this}geojson(){return this.headers.set(`Accept`,`application/geo+json`),this}explain({analyze:e=!1,verbose:t=!1,settings:n=!1,buffers:r=!1,wal:i=!1,format:a=`text`}={}){let o=[e?`analyze`:null,t?`verbose`:null,n?`settings`:null,r?`buffers`:null,i?`wal`:null].filter(Boolean).join(`|`),s=this.headers.get(`Accept`)??`application/json`;return this.headers.set(`Accept`,`application/vnd.pgrst.plan+${a}; for="${s}"; options=${o};`),this}rollback(){return this.headers.append(`Prefer`,`tx=rollback`),this}returns(){return this}maxAffected(e){return this.headers.append(`Prefer`,`handling=strict`),this.headers.append(`Prefer`,`max-affected=${e}`),this}},Kr=RegExp(`[,()]`),qr=class extends Gr{throwOnError(){return super.throwOnError()}eq(e,t){return this.url.searchParams.append(e,`eq.${t}`),this}neq(e,t){return this.url.searchParams.append(e,`neq.${t}`),this}gt(e,t){return this.url.searchParams.append(e,`gt.${t}`),this}gte(e,t){return this.url.searchParams.append(e,`gte.${t}`),this}lt(e,t){return this.url.searchParams.append(e,`lt.${t}`),this}lte(e,t){return this.url.searchParams.append(e,`lte.${t}`),this}like(e,t){return this.url.searchParams.append(e,`like.${t}`),this}likeAllOf(e,t){return this.url.searchParams.append(e,`like(all).{${t.join(`,`)}}`),this}likeAnyOf(e,t){return this.url.searchParams.append(e,`like(any).{${t.join(`,`)}}`),this}ilike(e,t){return this.url.searchParams.append(e,`ilike.${t}`),this}ilikeAllOf(e,t){return this.url.searchParams.append(e,`ilike(all).{${t.join(`,`)}}`),this}ilikeAnyOf(e,t){return this.url.searchParams.append(e,`ilike(any).{${t.join(`,`)}}`),this}regexMatch(e,t){return this.url.searchParams.append(e,`match.${t}`),this}regexIMatch(e,t){return this.url.searchParams.append(e,`imatch.${t}`),this}is(e,t){return this.url.searchParams.append(e,`is.${t}`),this}isDistinct(e,t){return this.url.searchParams.append(e,`isdistinct.${t}`),this}in(e,t){let n=Array.from(new Set(t)).map(e=>typeof e==`string`&&Kr.test(e)?`"${e}"`:`${e}`).join(`,`);return this.url.searchParams.append(e,`in.(${n})`),this}notIn(e,t){let n=Array.from(new Set(t)).map(e=>typeof e==`string`&&Kr.test(e)?`"${e}"`:`${e}`).join(`,`);return this.url.searchParams.append(e,`not.in.(${n})`),this}contains(e,t){return typeof t==`string`?this.url.searchParams.append(e,`cs.${t}`):Array.isArray(t)?this.url.searchParams.append(e,`cs.{${t.join(`,`)}}`):this.url.searchParams.append(e,`cs.${JSON.stringify(t)}`),this}containedBy(e,t){return typeof t==`string`?this.url.searchParams.append(e,`cd.${t}`):Array.isArray(t)?this.url.searchParams.append(e,`cd.{${t.join(`,`)}}`):this.url.searchParams.append(e,`cd.${JSON.stringify(t)}`),this}rangeGt(e,t){return this.url.searchParams.append(e,`sr.${t}`),this}rangeGte(e,t){return this.url.searchParams.append(e,`nxl.${t}`),this}rangeLt(e,t){return this.url.searchParams.append(e,`sl.${t}`),this}rangeLte(e,t){return this.url.searchParams.append(e,`nxr.${t}`),this}rangeAdjacent(e,t){return this.url.searchParams.append(e,`adj.${t}`),this}overlaps(e,t){return typeof t==`string`?this.url.searchParams.append(e,`ov.${t}`):this.url.searchParams.append(e,`ov.{${t.join(`,`)}}`),this}textSearch(e,t,{config:n,type:r}={}){let i=``;r===`plain`?i=`pl`:r===`phrase`?i=`ph`:r===`websearch`&&(i=`w`);let a=n===void 0?``:`(${n})`;return this.url.searchParams.append(e,`${i}fts${a}.${t}`),this}match(e){return Object.entries(e).filter(([e,t])=>t!==void 0).forEach(([e,t])=>{this.url.searchParams.append(e,`eq.${t}`)}),this}not(e,t,n){return this.url.searchParams.append(e,`not.${t}.${n}`),this}or(e,{foreignTable:t,referencedTable:n=t}={}){let r=n?`${n}.or`:`or`;return this.url.searchParams.append(r,`(${e})`),this}filter(e,t,n){return this.url.searchParams.append(e,`${t}.${n}`),this}},Jr=class{constructor(e,{headers:t={},schema:n,fetch:r,urlLengthLimit:i=8e3,retry:a}){this.url=e,this.headers=new Headers(t),this.schema=n,this.fetch=r,this.urlLengthLimit=i,this.retry=a}cloneRequestState(){return{url:new URL(this.url.toString()),headers:new Headers(this.headers)}}select(e,t){let{head:n=!1,count:r}=t??{},i=n?`HEAD`:`GET`,a=!1,o=(e??`*`).split(``).map(e=>/\s/.test(e)&&!a?``:(e===`"`&&(a=!a),e)).join(``),{url:s,headers:c}=this.cloneRequestState();return s.searchParams.set(`select`,o),r&&c.append(`Prefer`,`count=${r}`),new qr({method:i,url:s,headers:c,schema:this.schema,fetch:this.fetch,urlLengthLimit:this.urlLengthLimit,retry:this.retry})}insert(e,{count:t,defaultToNull:n=!0}={}){let{url:r,headers:i}=this.cloneRequestState();if(t&&i.append(`Prefer`,`count=${t}`),n||i.append(`Prefer`,`missing=default`),Array.isArray(e)){let t=e.reduce((e,t)=>e.concat(Object.keys(t)),[]);if(t.length>0){let e=[...new Set(t)].map(e=>`"${e}"`);r.searchParams.set(`columns`,e.join(`,`))}}return new qr({method:`POST`,url:r,headers:i,schema:this.schema,body:e,fetch:this.fetch??fetch,urlLengthLimit:this.urlLengthLimit,retry:this.retry})}upsert(e,{onConflict:t,ignoreDuplicates:n=!1,count:r,defaultToNull:i=!0}={}){let{url:a,headers:o}=this.cloneRequestState();if(o.append(`Prefer`,`resolution=${n?`ignore`:`merge`}-duplicates`),t!==void 0&&a.searchParams.set(`on_conflict`,t),r&&o.append(`Prefer`,`count=${r}`),i||o.append(`Prefer`,`missing=default`),Array.isArray(e)){let t=e.reduce((e,t)=>e.concat(Object.keys(t)),[]);if(t.length>0){let e=[...new Set(t)].map(e=>`"${e}"`);a.searchParams.set(`columns`,e.join(`,`))}}return new qr({method:`POST`,url:a,headers:o,schema:this.schema,body:e,fetch:this.fetch??fetch,urlLengthLimit:this.urlLengthLimit,retry:this.retry})}update(e,{count:t}={}){let{url:n,headers:r}=this.cloneRequestState();return t&&r.append(`Prefer`,`count=${t}`),new qr({method:`PATCH`,url:n,headers:r,schema:this.schema,body:e,fetch:this.fetch??fetch,urlLengthLimit:this.urlLengthLimit,retry:this.retry})}delete({count:e}={}){let{url:t,headers:n}=this.cloneRequestState();return e&&n.append(`Prefer`,`count=${e}`),new qr({method:`DELETE`,url:t,headers:n,schema:this.schema,fetch:this.fetch??fetch,urlLengthLimit:this.urlLengthLimit,retry:this.retry})}};function Yr(e){"@babel/helpers - typeof";return Yr=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},Yr(e)}function Xr(e,t){if(Yr(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(Yr(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function Zr(e){var t=Xr(e,`string`);return Yr(t)==`symbol`?t:t+``}function Qr(e,t,n){return(t=Zr(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function $r(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function ei(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?$r(Object(n),!0).forEach(function(t){Qr(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$r(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var ti=class e{constructor(e,{headers:t={},schema:n,fetch:r,timeout:i,urlLengthLimit:a=8e3,retry:o}={}){this.url=e,this.headers=new Headers(t),this.schemaName=n,this.urlLengthLimit=a;let s=r??globalThis.fetch;i!==void 0&&i>0?this.fetch=(e,t)=>{let n=new AbortController,r=setTimeout(()=>n.abort(),i),a=t?.signal;if(a){if(a.aborted)return clearTimeout(r),s(e,t);let i=()=>{clearTimeout(r),n.abort()};return a.addEventListener(`abort`,i,{once:!0}),s(e,ei(ei({},t),{},{signal:n.signal})).finally(()=>{clearTimeout(r),a.removeEventListener(`abort`,i)})}return s(e,ei(ei({},t),{},{signal:n.signal})).finally(()=>clearTimeout(r))}:this.fetch=s,this.retry=o}from(e){if(!e||typeof e!=`string`||e.trim()===``)throw Error(`Invalid relation name: relation must be a non-empty string.`);return new Jr(new URL(`${this.url}/${e}`),{headers:new Headers(this.headers),schema:this.schemaName,fetch:this.fetch,urlLengthLimit:this.urlLengthLimit,retry:this.retry})}schema(t){return new e(this.url,{headers:this.headers,schema:t,fetch:this.fetch,urlLengthLimit:this.urlLengthLimit,retry:this.retry})}rpc(e,t={},{head:n=!1,get:r=!1,count:i}={}){let a,o=new URL(`${this.url}/rpc/${e}`),s,c=e=>typeof e==`object`&&!!e&&(!Array.isArray(e)||e.some(c)),l=n&&Object.values(t).some(c);l?(a=`POST`,s=t):n||r?(a=n?`HEAD`:`GET`,Object.entries(t).filter(([e,t])=>t!==void 0).map(([e,t])=>[e,Array.isArray(t)?`{${t.join(`,`)}}`:`${t}
12`]).forEach(([e,t])=>{o.searchParams.append(e,t)})):(a=`POST`,s=t);let u=new Headers(this.headers);return l?u.set(`Prefer`,i?`count=${i},return=minimal`:`return=minimal`):i&&u.set(`Prefer`,`count=${i}`),new qr({method:a,url:o,headers:u,schema:this.schemaName,body:s,fetch:this.fetch??fetch,urlLengthLimit:this.urlLengthLimit,retry:this.retry})}},ni=class{constructor(){}static detectEnvironment(){if(typeof WebSocket<`u`)return{type:`native`,wsConstructor:WebSocket};let e=globalThis;if(typeof globalThis<`u`&&e.WebSocket!==void 0)return{type:`native`,wsConstructor:e.WebSocket};let t=typeof global<`u`?global:void 0;if(t&&t.WebSocket!==void 0)return{type:`native`,wsConstructor:t.WebSocket};if(typeof globalThis<`u`&&e.WebSocketPair!==void 0&&globalThis.WebSocket===void 0)return{type:`cloudflare`,error:`Cloudflare Workers detected. WebSocket clients are not supported in Cloudflare Workers.`,workaround:`Use Cloudflare Workers WebSocket API for server-side WebSocket handling, or deploy to a different runtime.`};if(typeof globalThis<`u`&&e.EdgeRuntime||typeof navigator<`u`&&navigator.userAgent?.includes(`Vercel-Edge`))return{type:`unsupported`,error:`Edge runtime detected (Vercel Edge/Netlify Edge). WebSockets are not supported in edge functions.`,workaround:`Use serverless functions or a different deployment target for WebSocket functionality.`};let n=globalThis.process;if(n){let e=n.versions;if(e&&e.node){let t=e.node,n=parseInt(t.replace(/^v/,``).split(`.`)[0]);return n>=22?globalThis.WebSocket===void 0?{type:`unsupported`,error:`Node.js ${n} detected but native WebSocket not found.`,workaround:`Provide a WebSocket implementation via the transport option.`}:{type:`native`,wsConstructor:globalThis.WebSocket}:{type:`unsupported`,error:`Node.js ${n} detected without native WebSocket support.`,workaround:`For Node.js < 22, install "ws" package and provide it via the transport option: 13import ws from "ws" 14new RealtimeClient(url, { transport: ws })`}}}return{type:`unsupported`,error:`Unknown JavaScript runtime without WebSocket support.`,workaround:`Ensure you're running in a supported environment (browser, Node.js, Deno) or provide a custom WebSocket implementation.`}}static getWebSocketConstructor(){let e=this.detectEnvironment();if(e.wsConstructor)return e.wsConstructor;let t=e.error||`WebSocket not supported in this environment.`;throw e.workaround&&(t+=`\n\nSuggested solution: ${e.workaround}`),Error(t)}static isWebSocketSupported(){try{let e=this.detectEnvironment();return e.type===`native`||e.type===`ws`}catch{return!1}}},ri=`realtime-js/2.108.2`,ii=`1.0.0`,ai=`2.0.0`,oi=ai,si=1e4,ci={closed:`closed`,errored:`errored`,joined:`joined`,joining:`joining`,leaving:`leaving`},li={close:`phx_close`,error:`phx_error`,join:`phx_join`,reply:`phx_reply`,leave:`phx_leave`,access_token:`access_token`},ui={connecting:`connecting`,open:`open`,closing:`closing`,closed:`closed`},di=class{constructor(e){this.HEADER_LENGTH=1,this.USER_BROADCAST_PUSH_META_LENGTH=6,this.KINDS={userBroadcastPush:3,userBroadcast:4},this.BINARY_ENCODING=0,this.JSON_ENCODING=1,this.BROADCAST_EVENT=`broadcast`,this.allowedMetadataKeys=[],this.allowedMetadataKeys=e??[]}encode(e,t){if(e.event===this.BROADCAST_EVENT&&!(e.payload instanceof ArrayBuffer)&&typeof e.payload.event==`string`)return t(this._binaryEncodeUserBroadcastPush(e));let n=[e.join_ref,e.ref,e.topic,e.event,e.payload];return t(JSON.stringify(n))}_binaryEncodeUserBroadcastPush(e){return this._isArrayBuffer(e.payload?.payload)?this._encodeBinaryUserBroadcastPush(e):this._encodeJsonUserBroadcastPush(e)}_encodeBinaryUserBroadcastPush(e){let t=e.payload?.payload??new ArrayBuffer(0);return this._encodeUserBroadcastPush(e,this.BINARY_ENCODING,t)}_encodeJsonUserBroadcastPush(e){let t=e.payload?.payload??{},n=new TextEncoder().encode(JSON.stringify(t)).buffer;return this._encodeUserBroadcastPush(e,this.JSON_ENCODING,n)}_encodeUserBroadcastPush(e,t,n){let r=e.topic,i=e.ref??``,a=e.join_ref??``,o=e.payload.event,s=this.allowedMetadataKeys?this._pick(e.payload,this.allowedMetadataKeys):{},c=Object.keys(s).length===0?``:JSON.stringify(s);if(a.length>255)throw Error(`joinRef length ${a.length} exceeds maximum of 255`);if(i.length>255)throw Error(`ref length ${i.length} exceeds maximum of 255`);if(r.length>255)throw Error(`topic length ${r.length} exceeds maximum of 255`);if(o.length>255)throw Error(`userEvent length ${o.length} exceeds maximum of 255`);if(c.length>255)throw Error(`metadata length ${c.length} exceeds maximum of 255`);let l=this.USER_BROADCAST_PUSH_META_LENGTH+a.length+i.length+r.length+o.length+c.length,u=new ArrayBuffer(this.HEADER_LENGTH+l),d=new DataView(u),f=0;d.setUint8(f++,this.KINDS.userBroadcastPush),d.setUint8(f++,a.length),d.setUint8(f++,i.length),d.setUint8(f++,r.length),d.setUint8(f++,o.length),d.setUint8(f++,c.length),d.setUint8(f++,t),Array.from(a,e=>d.setUint8(f++,e.charCodeAt(0))),Array.from(i,e=>d.setUint8(f++,e.charCodeAt(0))),Array.from(r,e=>d.setUint8(f++,e.charCodeAt(0))),Array.from(o,e=>d.setUint8(f++,e.charCodeAt(0))),Array.from(c,e=>d.setUint8(f++,e.charCodeAt(0)));var p=new Uint8Array(u.byteLength+n.byteLength);return p.set(new Uint8Array(u),0),p.set(new Uint8Array(n),u.byteLength),p.buffer}decode(e,t){if(this._isArrayBuffer(e))return t(this._binaryDecode(e));if(typeof e==`string`){let[n,r,i,a,o]=JSON.parse(e);return t({join_ref:n,ref:r,topic:i,event:a,payload:o})}return t({})}_binaryDecode(e){let t=new DataView(e),n=t.getUint8(0),r=new TextDecoder;switch(n){case this.KINDS.userBroadcast:return this._decodeUserBroadcast(e,t,r)}}_decodeUserBroadcast(e,t,n){let r=t.getUint8(1),i=t.getUint8(2),a=t.getUint8(3),o=t.getUint8(4),s=this.HEADER_LENGTH+4,c=n.decode(e.slice(s,s+r));s+=r;let l=n.decode(e.slice(s,s+i));s+=i;let u=n.decode(e.slice(s,s+a));s+=a;let d=e.slice(s,e.byteLength),f=o===this.JSON_ENCODING?JSON.parse(n.decode(d)):d,p={type:this.BROADCAST_EVENT,event:l,payload:f};return a>0&&(p.meta=JSON.parse(u)),{join_ref:null,ref:null,topic:c,event:this.BROADCAST_EVENT,payload:p}}_isArrayBuffer(e){return e instanceof ArrayBuffer||e?.constructor?.name===`ArrayBuffer`}_pick(e,t){return!e||typeof e!=`object`?{}:Object.fromEntries(Object.entries(e).filter(([e])=>t.includes(e)))}},fi;(function(e){e.abstime=`abstime`,e.bool=`bool`,e.date=`date`,e.daterange=`daterange`,e.float4=`float4`,e.float8=`float8`,e.int2=`int2`,e.int4=`int4`,e.int4range=`int4range`,e.int8=`int8`,e.int8range=`int8range`,e.json=`json`,e.jsonb=`jsonb`,e.money=`money`,e.numeric=`numeric`,e.oid=`oid`,e.reltime=`reltime`,e.text=`text`,e.time=`time`,e.timestamp=`timestamp`,e.timestamptz=`timestamptz`,e.timetz=`timetz`,e.tsrange=`tsrange`,e.tstzrange=`tstzrange`})(fi||={});var pi=(e,t,n={})=>{let r=n.skipTypes??[];return t?Object.keys(t).reduce((n,i)=>(n[i]=mi(i,e,t,r),n),{}):{}},mi=(e,t,n,r)=>{let i=t.find(t=>t.name===e)?.type,a=n[e];return i&&!r.includes(i)?hi(i,a):gi(a)},hi=(e,t)=>{if(e.charAt(0)===`_`)return bi(t,e.slice(1,e.length));switch(e){case fi.bool:return _i(t);case fi.float4:case fi.float8:case fi.int2:case fi.int4:case fi.int8:case fi.numeric:case fi.oid:return vi(t);case fi.json:case fi.jsonb:return yi(t);case fi.timestamp:return xi(t);case fi.abstime:case fi.date:case fi.daterange:case fi.int4range:case fi.int8range:case fi.money:case fi.reltime:case fi.text:case fi.time:case fi.timestamptz:case fi.timetz:case fi.tsrange:case fi.tstzrange:return gi(t);default:return gi(t)}},gi=e=>e,_i=e=>{switch(e){case`t`:return!0;case`f`:return!1;default:return e}},vi=e=>{if(typeof e==`string`){let t=parseFloat(e);
vendor: 9,952 bytes, line 14
14if(!Number.isNaN(t))return t}return e},yi=e=>{if(typeof e==`string`)try{return JSON.parse(e)}catch{return e}return e},bi=(e,t)=>{if(typeof e!=`string`)return e;let n=e.length-1,r=e[n];if(e[0]===`{`&&r===`}`){let r,i=e.slice(1,n);try{r=JSON.parse(`[`+i+`]`)}catch{r=i?i.split(`,`):[]}return r.map(e=>hi(t,e))}return e},xi=e=>typeof e==`string`?e.replace(` `,`T`):e,Si=e=>{let t=new URL(e);return t.protocol=t.protocol.replace(/^ws/i,`http`),t.pathname=t.pathname.replace(/\/+$/,``).replace(/\/socket\/websocket$/i,``).replace(/\/socket$/i,``).replace(/\/websocket$/i,``),t.pathname===``||t.pathname===`/`?t.pathname=`/api/broadcast`:t.pathname+=`/api/broadcast`,t.href},Ci=e=>typeof e==`function`?e:function(){return e},wi=typeof self<`u`?self:null,Ti=typeof window<`u`?window:null,Ei=wi||Ti||globalThis,Di=`2.0.0`,Oi=1e4,ki=1e3,Ai={connecting:0,open:1,closing:2,closed:3},ji={closed:`closed`,errored:`errored`,joined:`joined`,joining:`joining`,leaving:`leaving`},Mi={close:`phx_close`,error:`phx_error`,join:`phx_join`,reply:`phx_reply`,leave:`phx_leave`},Ni={longpoll:`longpoll`,websocket:`websocket`},Pi={complete:4},Fi=`base64url.bearer.phx.`,Ii=class{constructor(e,t,n,r){this.channel=e,this.event=t,this.payload=n||function(){return{}},this.receivedResp=null,this.timeout=r,this.timeoutTimer=null,this.recHooks=[],this.sent=!1,this.ref=void 0}resend(e){this.timeout=e,this.reset(),this.send()}send(){this.hasReceived(`timeout`)||(this.startTimeout(),this.sent=!0,this.channel.socket.push({topic:this.channel.topic,event:this.event,payload:this.payload(),ref:this.ref,join_ref:this.channel.joinRef()}))}receive(e,t){return this.hasReceived(e)&&t(this.receivedResp.response),this.recHooks.push({status:e,callback:t}),this}reset(){this.cancelRefEvent(),this.ref=null,this.refEvent=null,this.receivedResp=null,this.sent=!1}destroy(){this.cancelRefEvent(),this.cancelTimeout()}matchReceive({status:e,response:t,_ref:n}){this.recHooks.filter(t=>t.status===e).forEach(e=>e.callback(t))}cancelRefEvent(){this.refEvent&&this.channel.off(this.refEvent)}cancelTimeout(){clearTimeout(this.timeoutTimer),this.timeoutTimer=null}startTimeout(){this.timeoutTimer&&this.cancelTimeout(),this.ref=this.channel.socket.makeRef(),this.refEvent=this.channel.replyEventName(this.ref),this.channel.on(this.refEvent,e=>{this.cancelRefEvent(),this.cancelTimeout(),this.receivedResp=e,this.matchReceive(e)}),this.timeoutTimer=setTimeout(()=>{this.trigger(`timeout`,{})},this.timeout)}hasReceived(e){return this.receivedResp&&this.receivedResp.status===e}trigger(e,t){this.channel.trigger(this.refEvent,{status:e,response:t})}},Li=class{constructor(e,t){this.callback=e,this.timerCalc=t,this.timer=void 0,this.tries=0}reset(){this.tries=0,clearTimeout(this.timer)}scheduleTimeout(){clearTimeout(this.timer),this.timer=setTimeout(()=>{this.tries+=1,this.callback()},this.timerCalc(this.tries+1))}},Ri=class{constructor(e,t,n){this.state=ji.closed,this.topic=e,this.params=Ci(t||{}),this.socket=n,this.bindings=[],this.bindingRef=0,this.timeout=this.socket.timeout,this.joinedOnce=!1,this.joinPush=new Ii(this,Mi.join,this.params,this.timeout),this.pushBuffer=[],this.stateChangeRefs=[],this.rejoinTimer=new Li(()=>{this.socket.isConnected()&&this.rejoin()},this.socket.rejoinAfterMs),this.stateChangeRefs.push(this.socket.onError(()=>this.rejoinTimer.reset())),this.stateChangeRefs.push(this.socket.onOpen(()=>{this.rejoinTimer.reset(),this.isErrored()&&this.rejoin()})),this.joinPush.receive(`ok`,()=>{this.state=ji.joined,this.rejoinTimer.reset(),this.pushBuffer.forEach(e=>e.send()),this.pushBuffer=[]}),this.joinPush.receive(`error`,e=>{this.state=ji.errored,this.socket.hasLogger()&&this.socket.log(`channel`,`error ${this.topic}`,e),this.socket.isConnected()&&this.rejoinTimer.scheduleTimeout()}),this.onClose(()=>{this.rejoinTimer.reset(),this.socket.hasLogger()&&this.socket.log(`channel`,`close ${this.topic}`),this.state=ji.closed,this.socket.remove(this)}),this.onError(e=>{this.socket.hasLogger()&&this.socket.log(`channel`,`error ${this.topic}`,e),this.isJoining()&&this.joinPush.reset(),this.state=ji.errored,this.socket.isConnected()&&this.rejoinTimer.scheduleTimeout()}),this.joinPush.receive(`timeout`,()=>{this.socket.hasLogger()&&this.socket.log(`channel`,`timeout ${this.topic}`,this.joinPush.timeout),new Ii(this,Mi.leave,Ci({}),this.timeout).send(),this.state=ji.errored,this.joinPush.reset(),this.socket.isConnected()&&this.rejoinTimer.scheduleTimeout()}),this.on(Mi.reply,(e,t)=>{this.trigger(this.replyEventName(t),e)})}join(e=this.timeout){if(this.joinedOnce)throw Error(`tried to join multiple times. 'join' can only be called a single time per channel instance`);return this.timeout=e,this.joinedOnce=!0,this.rejoin(),this.joinPush}teardown(){this.pushBuffer.forEach(e=>e.destroy()),this.pushBuffer=[],this.rejoinTimer.reset(),this.joinPush.destroy(),this.state=ji.closed,this.bindings=[]}onClose(e){this.on(Mi.close,e)}onError(e){return this.on(Mi.error,t=>e(t))}on(e,t){let n=this.bindingRef++;return this.bindings.push({event:e,ref:n,callback:t}),n}off(e,t){this.bindings=this.bindings.filter(n=>!(n.event===e&&(t===void 0||t===n.ref)))}canPush(){return this.socket.isConnected()&&this.isJoined()}push(e,t,n=this.timeout){if(t||={},!this.joinedOnce)throw Error(`tried to push '${e}' to '${this.topic}' before joining. Use channel.join() before pushing events`);let r=new Ii(this,e,function(){return t},n);return this.canPush()?r.send():(r.startTimeout(),this.pushBuffer.push(r)),r}leave(e=this.timeout){this.rejoinTimer.reset(),this.joinPush.cancelTimeout(),this.state=ji.leaving;let t=()=>{this.socket.hasLogger()&&this.socket.log(`channel`,`leave ${this.topic}`),this.trigger(Mi.close,`leave`)},n=new Ii(this,Mi.leave,Ci({}),e);return n.receive(`ok`,()=>t()).receive(`timeout`,()=>t()),n.send(),this.canPush()||n.trigger(`ok`,{}),n}onMessage(e,t,n){return t}filterBindings(e,t,n){return!0}isMember(e,t,n,r){return this.topic===e?r&&r!==this.joinRef()?(this.socket.hasLogger()&&this.socket.log(`channel`,`dropping outdated message`,{topic:e,event:t,payload:n,joinRef:r}),!1):!0:!1}joinRef(){return this.joinPush.ref}rejoin(e=this.timeout){this.isLeaving()||(this.socket.leaveOpenTopic(this.topic),this.state=ji.joining,this.joinPush.resend(e))}trigger(e,t,n,r){let i=this.onMessage(e,t,n,r);if(t&&!i)throw Error(`channel onMessage callbacks must return the payload, modified or unmodified`);let a=this.bindings.filter(r=>r.event===e&&this.filterBindings(r,t,n));for(let e=0;e<a.length;e++)a[e].callback(i,n,r||this.joinRef())}replyEventName(e){return`chan_reply_${e}`}isClosed(){return this.state===ji.closed}isErrored(){return this.state===ji.errored}isJoined(){return this.state===ji.joined}isJoining(){return this.state===ji.joining}isLeaving(){return this.state===ji.leaving}},zi=class{static request(e,t,n,r,i,a,o){if(Ei.XDomainRequest){let n=new Ei.XDomainRequest;return this.xdomainRequest(n,e,t,r,i,a,o)}else if(Ei.XMLHttpRequest){let s=new Ei.XMLHttpRequest;return this.xhrRequest(s,e,t,n,r,i,a,o)}else if(Ei.fetch&&Ei.AbortController)return this.fetchRequest(e,t,n,r,i,a,o);else throw Error(`No suitable XMLHttpRequest implementation found`)}static fetchRequest(e,t,n,r,i,a,o){let s={method:e,headers:n,body:r},c=null;return i&&(c=new AbortController,setTimeout(()=>c.abort(),i),s.signal=c.signal),Ei.fetch(t,s).then(e=>e.text()).then(e=>this.parseJSON(e)).then(e=>o&&o(e)).catch(e=>{e.name===`AbortError`&&a?a():o&&o(null)}),c}static xdomainRequest(e,t,n,r,i,a,o){return e.timeout=i,e.open(t,n),e.onload=()=>{let t=this.parseJSON(e.responseText);o&&o(t)},a&&(e.ontimeout=a),e.onprogress=()=>{},e.send(r),e}static xhrRequest(e,t,n,r,i,a,o,s){e.open(t,n,!0),e.timeout=a;for(let[t,n]of Object.entries(r))e.setRequestHeader(t,n);return e.onerror=()=>s&&s(null),e.onreadystatechange=()=>{e.readyState===Pi.complete&&s&&s(this.parseJSON(e.responseText))},o&&(e.ontimeout=o),e.send(i),e}static parseJSON(e){if(!e||e===``)return null;try{return JSON.parse(e)}catch{return console&&console.log(`failed to parse JSON response`,e),null}}static serialize(e,t){let n=[];for(var r in e){if(!Object.prototype.hasOwnProperty.call(e,r))continue;let i=t?`${t}[${r}]`:r,a=e[r];typeof a==`object`?n.push(this.serialize(a,i)):n.push(encodeURIComponent(i)+`=`+encodeURIComponent(a))}return n.join(`&`)}static appendParams(e,t){return Object.keys(t).length===0?e:`${e}${e.match(/\?/)?`&`:`?`}${this.serialize(t)}`}},Bi=e=>{let t=``,n=new Uint8Array(e),r=n.byteLength;for(let e=0;e<r;e++)t+=String.fromCharCode(n[e]);return btoa(t)},Vi=class{constructor(e,t){t&&t.length===2&&t[1].startsWith(Fi)&&(this.authToken=atob(t[1].slice(Fi.length))),this.endPoint=null,this.token=null,this.skipHeartbeat=!0,this.reqs=new Set,this.awaitingBatchAck=!1,this.currentBatch=null,this.currentBatchTimer=null,this.batchBuffer=[],this.onopen=function(){},this.onerror=function(){},this.onmessage=function(){},this.onclose=function(){},this.pollEndpoint=this.normalizeEndpoint(e),this.readyState=Ai.connecting,setTimeout(()=>this.poll(),0)}normalizeEndpoint(e){return e.replace(`ws://`,`http://`).replace(`wss://`,`https://`).replace(RegExp(`(.*)/`+Ni.websocket),`$1/`+Ni.longpoll)}endpointURL(){return zi.appendParams(this.pollEndpoint,{token:this.token})}closeAndRetry(e,t,n){this.close(e,t,n),this.readyState=Ai.connecting}ontimeout(){this.onerror(`timeout`),this.closeAndRetry(1005,`timeout`,!1)}isActive(){return this.readyState===Ai.open||this.readyState===Ai.connecting}poll(){let e={Accept:`application/json`};this.authToken&&(e[`X-Phoenix-AuthToken`]=this.authToken),this.ajax(`GET`,e,null,()=>this.ontimeout(),e=>{if(e){var{status:t,token:n,messages:r}=e;if(t===410&&this.token!==null){this.onerror(410),this.closeAndRetry(3410,`session_gone`,!1);return}this.token=n}else t=0;switch(t){case 200:r.forEach(e=>{setTimeout(()=>this.onmessage({data:e}),0)}),this.poll();break;case 204:this.poll();break;case 410:this.readyState=Ai.open,this.onopen({}),this.poll();break;
14case 403:this.onerror(403),this.close(1008,`forbidden`,!1);break;case 0:case 500:this.onerror(500),this.closeAndRetry(1011,`internal server error`,500);break;default:throw Error(`unhandled poll status ${t}`)}})}send(e){typeof e!=`string`&&(e=Bi(e)),this.currentBatch?this.currentBatch.push(e):this.awaitingBatchAck?this.batchBuffer.push(e):(this.currentBatch=[e],this.currentBatchTimer=setTimeout(()=>{this.batchSend(this.currentBatch),this.currentBatch=null},0))}batchSend(e){this.awaitingBatchAck=!0,this.ajax(`POST`,{"Content-Type":`application/x-ndjson`},e.join(` 15`),()=>this.onerror(`timeout`),e=>{this.awaitingBatchAck=!1,!e||e.status!==200?(this.onerror(e&&e.status),this.closeAndRetry(1011,`internal server error`,!1)):this.batchBuffer.length>0&&(this.batchSend(this.batchBuffer),this.batchBuffer=[])})}close(e,t,n){for(let e of this.reqs)e.abort();this.readyState=Ai.closed;let r=Object.assign({code:1e3,reason:void 0,wasClean:!0},{code:e,reason:t,wasClean:n});this.batchBuffer=[],clearTimeout(this.currentBatchTimer),this.currentBatchTimer=null,typeof CloseEvent<`u`?this.onclose(new CloseEvent(`close`,r)):this.onclose(r)}ajax(e,t,n,r,i){let a;a=zi.request(e,this.endpointURL(),t,n,this.timeout,()=>{this.reqs.delete(a),r()},e=>{this.reqs.delete(a),this.isActive()&&i(e)}),this.reqs.add(a)}},Hi=class e{constructor(t,n={}){let r=n.events||{state:`presence_state`,diff:`presence_diff`};this.state={},this.pendingDiffs=[],this.channel=t,this.joinRef=null,this.caller={onJoin:function(){},onLeave:function(){},onSync:function(){}},this.channel.on(r.state,t=>{let{onJoin:n,onLeave:r,onSync:i}=this.caller;this.joinRef=this.channel.joinRef(),this.state=e.syncState(this.state,t,n,r),this.pendingDiffs.forEach(t=>{this.state=e.syncDiff(this.state,t,n,r)}),this.pendingDiffs=[],i()}),this.channel.on(r.diff,t=>{let{onJoin:n,onLeave:r,onSync:i}=this.caller;this.inPendingSyncState()?this.pendingDiffs.push(t):(this.state=e.syncDiff(this.state,t,n,r),i())})}onJoin(e){this.caller.onJoin=e}onLeave(e){this.caller.onLeave=e}onSync(e){this.caller.onSync=e}list(t){return e.list(this.state,t)}inPendingSyncState(){return!this.joinRef||this.joinRef!==this.channel.joinRef()}static syncState(e,t,n,r){let i=this.clone(e),a={},o={};return this.map(i,(e,n)=>{t[e]||(o[e]=n)}),this.map(t,(e,t)=>{let n=i[e];if(n){let r=t.metas.map(e=>e.phx_ref),i=n.metas.map(e=>e.phx_ref),s=t.metas.filter(e=>i.indexOf(e.phx_ref)<0),c=n.metas.filter(e=>r.indexOf(e.phx_ref)<0);s.length>0&&(a[e]=t,a[e].metas=s),c.length>0&&(o[e]=this.clone(n),o[e].metas=c)}else a[e]=t}),this.syncDiff(i,{joins:a,leaves:o},n,r)}static syncDiff(e,t,n,r){let{joins:i,leaves:a}=this.clone(t);return n||=function(){},r||=function(){},this.map(i,(t,r)=>{let i=e[t];if(e[t]=this.clone(r),i){let n=e[t].metas.map(e=>e.phx_ref),r=i.metas.filter(e=>n.indexOf(e.phx_ref)<0);e[t].metas.unshift(...r)}n(t,i,r)}),this.map(a,(t,n)=>{let i=e[t];if(!i)return;let a=n.metas.map(e=>e.phx_ref);i.metas=i.metas.filter(e=>a.indexOf(e.phx_ref)<0),r(t,i,n),i.metas.length===0&&delete e[t]}),e}static list(e,t){return t||=function(e,t){return t},this.map(e,(e,n)=>t(e,n))}static map(e,t){return Object.getOwnPropertyNames(e).map(n=>t(n,e[n]))}static clone(e){return JSON.parse(JSON.stringify(e))}},Ui={HEADER_LENGTH:1,META_LENGTH:4,KINDS:{push:0,reply:1,broadcast:2},encode(e,t){if(e.payload.constructor===ArrayBuffer)return t(this.binaryEncode(e));{let n=[e.join_ref,e.ref,e.topic,e.event,e.payload];return t(JSON.stringify(n))}},decode(e,t){if(e.constructor===ArrayBuffer)return t(this.binaryDecode(e));{let[n,r,i,a,o]=JSON.parse(e);return t({join_ref:n,ref:r,topic:i,event:a,payload:o})}},binaryEncode(e){let{join_ref:t,ref:n,event:r,topic:i,payload:a}=e,o=this.META_LENGTH+t.length+n.length+i.length+r.length,s=new ArrayBuffer(this.HEADER_LENGTH+o),c=new DataView(s),l=0;c.setUint8(l++,this.KINDS.push),c.setUint8(l++,t.length),c.setUint8(l++,n.length),c.setUint8(l++,i.length),c.setUint8(l++,r.length),Array.from(t,e=>c.setUint8(l++,e.charCodeAt(0))),Array.from(n,e=>c.setUint8(l++,e.charCodeAt(0))),Array.from(i,e=>c.setUint8(l++,e.charCodeAt(0))),Array.from(r,e=>c.setUint8(l++,e.charCodeAt(0)));var u=new Uint8Array(s.byteLength+a.byteLength);return u.set(new Uint8Array(s),0),u.set(new Uint8Array(a),s.byteLength),u.buffer},binaryDecode(e){let t=new DataView(e),n=t.getUint8(0),r=new TextDecoder;switch(n){case this.KINDS.push:return this.decodePush(e,t,r);case this.KINDS.reply:return this.decodeReply(e,t,r);case this.KINDS.broadcast:return this.decodeBroadcast(e,t,r)}}
vendor: 12,506 bytes, line 15
15,decodePush(e,t,n){let r=t.getUint8(1),i=t.getUint8(2),a=t.getUint8(3),o=this.HEADER_LENGTH+this.META_LENGTH-1,s=n.decode(e.slice(o,o+r));o+=r;let c=n.decode(e.slice(o,o+i));o+=i;let l=n.decode(e.slice(o,o+a));return o+=a,{join_ref:s,ref:null,topic:c,event:l,payload:e.slice(o,e.byteLength)}},decodeReply(e,t,n){let r=t.getUint8(1),i=t.getUint8(2),a=t.getUint8(3),o=t.getUint8(4),s=this.HEADER_LENGTH+this.META_LENGTH,c=n.decode(e.slice(s,s+r));s+=r;let l=n.decode(e.slice(s,s+i));s+=i;let u=n.decode(e.slice(s,s+a));s+=a;let d=n.decode(e.slice(s,s+o));s+=o;let f={status:d,response:e.slice(s,e.byteLength)};return{join_ref:c,ref:l,topic:u,event:Mi.reply,payload:f}},decodeBroadcast(e,t,n){let r=t.getUint8(1),i=t.getUint8(2),a=this.HEADER_LENGTH+2,o=n.decode(e.slice(a,a+r));a+=r;let s=n.decode(e.slice(a,a+i));return a+=i,{join_ref:null,ref:null,topic:o,event:s,payload:e.slice(a,e.byteLength)}}},Wi=class{constructor(e,t={}){this.stateChangeCallbacks={open:[],close:[],error:[],message:[]},this.channels=[],this.sendBuffer=[],this.ref=0,this.fallbackRef=null,this.timeout=t.timeout||Oi,this.transport=t.transport||Ei.WebSocket||Vi,this.conn=void 0,this.primaryPassedHealthCheck=!1,this.longPollFallbackMs=t.longPollFallbackMs,this.fallbackTimer=null;let n=null;try{n=Ei&&Ei.sessionStorage}catch{}this.sessionStore=t.sessionStorage||n,this.establishedConnections=0,this.defaultEncoder=Ui.encode.bind(Ui),this.defaultDecoder=Ui.decode.bind(Ui),this.closeWasClean=!0,this.disconnecting=!1,this.binaryType=t.binaryType||`arraybuffer`,this.connectClock=1,this.pageHidden=!1,this.encode=void 0,this.decode=void 0,this.transport===Vi?(this.encode=this.defaultEncoder,this.decode=this.defaultDecoder):(this.encode=t.encode||this.defaultEncoder,this.decode=t.decode||this.defaultDecoder);let r=null;Ti&&Ti.addEventListener&&(Ti.addEventListener(`pagehide`,e=>{this.conn&&(this.disconnect(),r=this.connectClock)}),Ti.addEventListener(`pageshow`,e=>{r===this.connectClock&&(r=null,this.connect())}),Ti.addEventListener(`visibilitychange`,()=>{document.visibilityState===`hidden`?this.pageHidden=!0:(this.pageHidden=!1,!this.isConnected()&&!this.closeWasClean&&this.teardown(()=>this.connect()))})),this.heartbeatIntervalMs=t.heartbeatIntervalMs||3e4,this.autoSendHeartbeat=t.autoSendHeartbeat??!0,this.heartbeatCallback=t.heartbeatCallback??(()=>{}),this.rejoinAfterMs=e=>t.rejoinAfterMs?t.rejoinAfterMs(e):[1e3,2e3,5e3][e-1]||1e4,this.reconnectAfterMs=e=>t.reconnectAfterMs?t.reconnectAfterMs(e):[10,50,100,150,200,250,500,1e3,2e3][e-1]||5e3,this.logger=t.logger||null,!this.logger&&t.debug&&(this.logger=(e,t,n)=>{console.log(`${e}: ${t}`,n)}),this.longpollerTimeout=t.longpollerTimeout||2e4,this.params=Ci(t.params||{}),this.endPoint=`${e}/${Ni.websocket}`,this.vsn=t.vsn||Di,this.heartbeatTimeoutTimer=null,this.heartbeatTimer=null,this.heartbeatSentAt=null,this.pendingHeartbeatRef=null,this.reconnectTimer=new Li(()=>{if(this.pageHidden){this.log(`Not reconnecting as page is hidden!`),this.teardown();return}this.teardown(async()=>{t.beforeReconnect&&await t.beforeReconnect(),this.connect()})},this.reconnectAfterMs),this.authToken=t.authToken}getLongPollTransport(){return Vi}replaceTransport(e){this.connectClock++,this.closeWasClean=!0,clearTimeout(this.fallbackTimer),this.reconnectTimer.reset(),this.conn&&=(this.conn.close(),null),this.transport=e}protocol(){return location.protocol.match(/^https/)?`wss`:`ws`}endPointURL(){let e=zi.appendParams(zi.appendParams(this.endPoint,this.params()),{vsn:this.vsn});return e.charAt(0)===`/`?e.charAt(1)===`/`?`${this.protocol()}:${e}`:`${this.protocol()}://${location.host}${e}`:e}disconnect(e,t,n){this.connectClock++,this.disconnecting=!0,this.closeWasClean=!0,clearTimeout(this.fallbackTimer),this.reconnectTimer.reset(),this.teardown(()=>{this.disconnecting=!1,e&&e()},t,n)}connect(e){e&&(console&&console.log(`passing params to connect is deprecated. Instead pass :params to the Socket constructor`),this.params=Ci(e)),!(this.conn&&!this.disconnecting)&&(this.longPollFallbackMs&&this.transport!==Vi?this.connectWithFallback(Vi,this.longPollFallbackMs):this.transportConnect())}log(e,t,n){this.logger&&this.logger(e,t,n)}hasLogger(){return this.logger!==null}onOpen(e){let t=this.makeRef();return this.stateChangeCallbacks.open.push([t,e]),t}onClose(e){let t=this.makeRef();return this.stateChangeCallbacks.close.push([t,e]),t}onError(e){let t=this.makeRef();return this.stateChangeCallbacks.error.push([t,e]),t}onMessage(e){let t=this.makeRef();return this.stateChangeCallbacks.message.push([t,e]),t}onHeartbeat(e){this.heartbeatCallback=e}ping(e){if(!this.isConnected())return!1;let t=this.makeRef(),n=Date.now();this.push({topic:`phoenix`,event:`heartbeat`,payload:{},ref:t});let r=this.onMessage(i=>{i.ref===t&&(this.off([r]),e(Date.now()-n))});return!0}transportName(e){switch(e){case Vi:return`LongPoll`;default:return e.name}}transportConnect(){this.connectClock++,this.closeWasClean=!1;let e;this.authToken&&(e=[`phoenix`,`${Fi}${btoa(this.authToken).replace(/=/g,``)}`]),this.conn=new this.transport(this.endPointURL(),e),this.conn.binaryType=this.binaryType,this.conn.timeout=this.longpollerTimeout,this.conn.onopen=()=>this.onConnOpen(),this.conn.onerror=e=>this.onConnError(e),this.conn.onmessage=e=>this.onConnMessage(e),this.conn.onclose=e=>this.onConnClose(e)}getSession(e){return this.sessionStore&&this.sessionStore.getItem(e)}storeSession(e,t){this.sessionStore&&this.sessionStore.setItem(e,t)}connectWithFallback(e,t=2500){clearTimeout(this.fallbackTimer);let n=!1,r=!0,i,a=this.transportName(e),o=t=>{this.log(`transport`,`falling back to ${a}...`,t),this.off([void 0,i]),r=!1,this.replaceTransport(e),this.transportConnect()};if(this.getSession(`phx:fallback:${a}`))return o(`memorized`);this.fallbackTimer=setTimeout(o,t),i=this.onError(e=>{this.log(`transport`,`error`,e),r&&!n&&(clearTimeout(this.fallbackTimer),o(e))}),this.fallbackRef&&this.off([this.fallbackRef]),this.fallbackRef=this.onOpen(()=>{if(n=!0,!r){let t=this.transportName(e);return this.primaryPassedHealthCheck||this.storeSession(`phx:fallback:${t}`,`true`),this.log(`transport`,`established ${t} fallback`)}clearTimeout(this.fallbackTimer),this.fallbackTimer=setTimeout(o,t),this.ping(e=>{this.log(`transport`,`connected to primary after`,e),this.primaryPassedHealthCheck=!0,clearTimeout(this.fallbackTimer)})}),this.transportConnect()}clearHeartbeats(){clearTimeout(this.heartbeatTimer),clearTimeout(this.heartbeatTimeoutTimer)}onConnOpen(){this.hasLogger()&&this.log(`transport`,`connected to ${this.endPointURL()}`),this.closeWasClean=!1,this.disconnecting=!1,this.establishedConnections++,this.flushSendBuffer(),this.reconnectTimer.reset(),this.autoSendHeartbeat&&this.resetHeartbeat(),this.triggerStateCallbacks(`open`)}heartbeatTimeout(){if(this.pendingHeartbeatRef){this.pendingHeartbeatRef=null,this.heartbeatSentAt=null,this.hasLogger()&&this.log(`transport`,`heartbeat timeout. Attempting to re-establish connection`);try{this.heartbeatCallback(`timeout`)}catch(e){this.log(`error`,`error in heartbeat callback`,e)}this.triggerChanError(Error(`heartbeat timeout`)),this.closeWasClean=!1,this.teardown(()=>this.reconnectTimer.scheduleTimeout(),ki,`heartbeat timeout`)}}resetHeartbeat(){this.conn&&this.conn.skipHeartbeat||(this.pendingHeartbeatRef=null,this.clearHeartbeats(),this.heartbeatTimer=setTimeout(()=>this.sendHeartbeat(),this.heartbeatIntervalMs))}teardown(e,t,n){if(!this.conn)return e&&e();let r=this.conn;this.waitForBufferDone(r,()=>{t?r.close(t,n||``):r.close(),this.waitForSocketClosed(r,()=>{this.conn===r&&(this.conn.onopen=function(){},this.conn.onerror=function(){},this.conn.onmessage=function(){},this.conn.onclose=function(){},this.conn=null),e&&e()})})}waitForBufferDone(e,t,n=1){if(n===5||!e.bufferedAmount){t();return}setTimeout(()=>{this.waitForBufferDone(e,t,n+1)},150*n)}waitForSocketClosed(e,t,n=1){if(n===5||e.readyState===Ai.closed){t();return}setTimeout(()=>{this.waitForSocketClosed(e,t,n+1)},150*n)}onConnClose(e){this.conn&&(this.conn.onclose=()=>{}),this.hasLogger()&&this.log(`transport`,`close`,e),this.triggerChanError(e),this.clearHeartbeats(),this.closeWasClean||this.reconnectTimer.scheduleTimeout(),this.triggerStateCallbacks(`close`,e)}onConnError(e){this.hasLogger()&&this.log(`transport`,`error`,e);let t=this.transport,n=this.establishedConnections;this.triggerStateCallbacks(`error`,e,t,n),(t===this.transport||n>0)&&this.triggerChanError(e)}triggerChanError(e){this.channels.forEach(t=>{t.isErrored()||t.isLeaving()||t.isClosed()||t.trigger(Mi.error,e)})}connectionState(){switch(this.conn&&this.conn.readyState){case Ai.connecting:return`connecting`;case Ai.open:return`open`;case Ai.closing:return`closing`;default:return`closed`}}isConnected(){return this.connectionState()===`open`}remove(e){this.off(e.stateChangeRefs),this.channels=this.channels.filter(t=>t!==e)}off(e){for(let t in this.stateChangeCallbacks)this.stateChangeCallbacks[t]=this.stateChangeCallbacks[t].filter(([t])=>e.indexOf(t)===-1)}channel(e,t={}){let n=new Ri(e,t,this);return this.channels.push(n),n}push(e){if(this.hasLogger()){let{topic:t,event:n,payload:r,ref:i,join_ref:a}=e;this.log(`push`,`${t} ${n} (${a}, ${i})`,r)}this.isConnected()?this.encode(e,e=>this.conn.send(e)):this.sendBuffer.push(()=>this.encode(e,e=>this.conn.send(e)))}makeRef(){let e=this.ref+1;return e===this.ref?this.ref=0:this.ref=e,this.ref.toString()}sendHeartbeat(){if(!this.isConnected()){try{this.heartbeatCallback(`disconnected`)}catch(e){this.log(`error`,`error in heartbeat callback`,e)}return}if(this.pendingHeartbeatRef){this.heartbeatTimeout();return}this.pendingHeartbeatRef=this.makeRef(),this.heartbeatSentAt=Date.now(),this.push({topic:`phoenix`,event:`heartbeat`,payload:{},ref:this.pendingHeartbeatRef});try{this.heartbeatCallback(`sent`)}catch(e){this.log(`error`,`error in heartbeat callback`,e)}this.heartbeatTimeoutTimer=setTimeout(()=>this.heartbeatTimeout(),this.heartbeatIntervalMs)}flushSendBuffer(){this.isConnected()&&this.sendBuffer.length>0&&(this.sendBuffer.forEach(e=>e()),this.sendBuffer=[])}onConnMessage(e){this.decode(e.data,e=>{let{topic:t,event:n,payload:r,ref:i,join_ref:a}=e;if(i&&i===this.pendingHeartbeatRef){let e=this.heartbeatSentAt?Date.now()-this.heartbeatSentAt:void 0;this.clearHeartbeats();try{this.heartbeatCallback(r.status===`ok`?`ok`:`error`,e)}catch(e){this.log(`error`,`error in heartbeat callback`,e)}this.pendingHeartbeatRef=null,this.heartbeatSentAt=null,this.autoSendHeartbeat&&(this.heartbeatTimer=setTimeout(()=>this.sendHeartbeat(),this.heartbeatIntervalMs))}this.hasLogger()&&this.log(`receive`,`${r.status||``} ${t} ${n} ${i&&`(`+i+`)`||``}`.trim(),r);for(let e=0;e<this.channels.length;e++){let o=this.channels[e];o.isMember(t,n,r,a)&&o.trigger(n,r,i,a)}this.triggerStateCallbacks(`message`,e)})}triggerStateCallbacks(e,...t){try{this.stateChangeCallbacks[e].forEach(([n,r])=>{try{r(...t)}catch(t){this.log(`error`,`error in ${e} callback`,t)}})}catch(t){this.log(`error`,`error triggering ${e} callbacks`,t)}}leaveOpenTopic(e){let t=this.channels.find(t=>t.topic===e&&(t.isJoined()||t.isJoining()));t&&(this.hasLogger()&&this.log(`transport`,`leaving duplicate topic "${e}"`),t.leave())}},Gi=class e{constructor(t,n){let r=Ji(n);this.presence=new Hi(t.getChannel(),r),this.presence.onJoin((n,r,i)=>{let a=e.onJoinPayload(n,r,i);t.getChannel().trigger(`presence`,a)}),this.presence.onLeave((n,r,i)=>{let a=e.onLeavePayload(n,r,i);t.getChannel().trigger(`presence`,a)}),this.presence.onSync(()=>{t.getChannel().trigger(`presence`,{event:`sync`})})}get state(){return e.transformState(this.presence.state)}static transformState(e){return e=qi(e),Object.getOwnPropertyNames(e).reduce((t,n)=>{let r=e[n];return t[n]=Ki(r),t},{})}static onJoinPayload(e,t,n){return{event:`join`,key:e,currentPresences:Yi(t),newPresences:Ki(n)}}static onLeavePayload(e,t,n){return{event:`leave`,key:e,currentPresences:Yi(t),leftPresences:Ki(n)}}};function Ki(e){return e.metas.map(e=>(e.presence_ref=e.phx_ref,delete e.phx_ref,delete e.phx_ref_prev,e))}function qi(e){return JSON.parse(JSON.stringify(e))}function Ji(e){return e?.events&&{events:e.events}}function Yi(e){return e?.metas?Ki(e):[]}var Xi;(function(e){e.SYNC=`sync`,e.JOIN=`join`,e.LEAVE=`leave`})(Xi||={});var Zi=class{get state(){return this.presenceAdapter.state}constructor(e,t){this.channel=e,this.presenceAdapter=new Gi(this.channel.channelAdapter,t)}};function Qi(e){if(e instanceof Error)return e;if(typeof e==`string`)return Error(e);
15if(e&&typeof e==`object`){let t=e;if(typeof t.code==`number`){let n=typeof t.reason==`string`&&t.reason?` (${t.reason})`:``;return Error(`socket closed: ${t.code}${n}`,{cause:e})}return Error(`channel error: transport failure`,{cause:e})}return Error(`channel error: connection lost`)}var $i=class{constructor(e,t,n){let r=ea(n);this.channel=e.getSocket().channel(t,r),this.socket=e}get state(){return this.channel.state}set state(e){this.channel.state=e}get joinedOnce(){return this.channel.joinedOnce}get joinPush(){return this.channel.joinPush}get rejoinTimer(){return this.channel.rejoinTimer}on(e,t){return this.channel.on(e,t)}off(e,t){this.channel.off(e,t)}subscribe(e){return this.channel.join(e)}unsubscribe(e){return this.channel.leave(e)}teardown(){this.channel.teardown()}onClose(e){this.channel.onClose(e)}onError(e){return this.channel.onError(e)}push(e,t,n){let r;try{r=this.channel.push(e,t,n)}catch{throw Error(`tried to push '${e}' to '${this.channel.topic}' before joining. Use channel.subscribe() before pushing events`)}if(this.channel.pushBuffer.length>100){let e=this.channel.pushBuffer.shift();e.cancelTimeout(),this.socket.log(`channel`,`discarded push due to buffer overflow: ${e.event}`,e.payload())}return r}updateJoinPayload(e){let t=this.channel.joinPush.payload();this.channel.joinPush.payload=()=>Object.assign(Object.assign({},t),e)}canPush(){return this.socket.isConnected()&&this.state===ci.joined}isJoined(){return this.state===ci.joined}isJoining(){return this.state===ci.joining}isClosed(){return this.state===ci.closed}isLeaving(){return this.state===ci.leaving}updateFilterBindings(e){this.channel.filterBindings=e}updatePayloadTransform(e){this.channel.onMessage=e}getChannel(){return this.channel}};function ea(e){return{config:Object.assign({broadcast:{ack:!1,self:!1},presence:{key:``,enabled:!1},private:!1},e.config)}}var ta;(function(e){e.ALL=`*`,e.INSERT=`INSERT`,e.UPDATE=`UPDATE`,e.DELETE=`DELETE`})(ta||={});var na;(function(e){e.BROADCAST=`broadcast`,e.PRESENCE=`presence`,e.POSTGRES_CHANGES=`postgres_changes`,e.SYSTEM=`system`})(na||={});var ra;(function(e){e.SUBSCRIBED=`SUBSCRIBED`,e.TIMED_OUT=`TIMED_OUT`,e.CLOSED=`CLOSED`,e.CHANNEL_ERROR=`CHANNEL_ERROR`})(ra||={});var ia=class e{get state(){return this.channelAdapter.state}set state(e){this.channelAdapter.state=e}get joinedOnce(){return this.channelAdapter.joinedOnce}get timeout(){return this.socket.timeout}get joinPush(){return this.channelAdapter.joinPush}get rejoinTimer(){return this.channelAdapter.rejoinTimer}constructor(e,t={config:{}},n){if(this.topic=e,this.params=t,this.socket=n,this.bindings={},this.subTopic=e.replace(/^realtime:/i,``),this.params.config=Object.assign({broadcast:{ack:!1,self:!1},presence:{key:``,enabled:!1},private:!1},t.config),this.channelAdapter=new $i(this.socket.socketAdapter,e,this.params),this.presence=new Zi(this),this._onClose(()=>{this.socket._remove(this)}),this._updateFilterTransform(),this.broadcastEndpointURL=Si(this.socket.socketAdapter.endPointURL()),this.private=this.params.config.private||!1,!this.private&&this.params.config?.broadcast?.replay)throw Error(`tried to use replay on public channel '${this.topic}'. It must be a private channel.`)}subscribe(e,t=this.timeout){if(this.socket.isConnected()||this.socket.connect(),this.channelAdapter.isClosed()){let{config:{broadcast:n,presence:r,private:i}}=this.params,a=this.bindings.postgres_changes?.map(e=>e.filter)??[],o=!!this.bindings[na.PRESENCE]&&this.bindings[na.PRESENCE].length>0||this.params.config.presence?.enabled===!0,s={},c={broadcast:n,presence:Object.assign(Object.assign({},r),{enabled:o}),postgres_changes:a,private:i};this.socket.accessTokenValue&&(s.access_token=this.socket.accessTokenValue),this._onError(t=>{e?.(ra.CHANNEL_ERROR,Qi(t))}),this._onClose(()=>e?.(ra.CLOSED)),this.updateJoinPayload(Object.assign({config:c},s)),this._updateFilterMessage(),this.channelAdapter.subscribe(t).receive(`ok`,async({postgres_changes:t})=>{if(this.socket._isManualToken()||this.socket.setAuth(),t===void 0){e?.(ra.SUBSCRIBED);return}this._updatePostgresBindings(t,e)}).receive(`error`,t=>{this.state=ci.errored;let n=Object.values(t).join(`, `)||`error`;e?.(ra.CHANNEL_ERROR,Error(n,{cause:t}))}).receive(`timeout`,()=>{e?.(ra.TIMED_OUT)})}return this}_updatePostgresBindings(t,n){let r=this.bindings.postgres_changes,i=r?.length??0,a=[];for(let o=0;o<i;o++){let i=r[o],{filter:{event:s,schema:c,table:l,filter:u}}=i,d=t&&t[o];if(d&&d.event===s&&e.isFilterValueEqual(d.schema,c)&&e.isFilterValueEqual(d.table,l)&&e.isFilterValueEqual(d.filter,u))a.push(Object.assign(Object.assign({},i),{id:d.id}));else{this.unsubscribe(),this.state=ci.errored,n?.(ra.CHANNEL_ERROR,Error(`mismatch between server and client bindings for postgres changes`));return}}this.bindings.postgres_changes=a,this.state!=ci.errored&&n&&n(ra.SUBSCRIBED)}presenceState(){return this.presence.state}async track(e,t={}){return await this.send({type:`presence`,event:`track`,payload:e},t.timeout||this.timeout)}async untrack(e={}){return await this.send({type:`presence`,event:`untrack`},e)}on(e,t,n){let r=this.channelAdapter.isJoined()||this.channelAdapter.isJoining(),i=e===na.PRESENCE||e===na.POSTGRES_CHANGES;if(r&&i)throw this.socket.log(`channel`,`cannot add \`${e}\` callbacks for ${this.topic} after \`subscribe()\`.`),Error(`cannot add \`${e}\` callbacks for ${this.topic} after \`subscribe()\`.`);return this._on(e,t,n)}async httpSend(e,t,n={}){if(t==null)return Promise.reject(Error(`Payload is required for httpSend()`));let r=t instanceof ArrayBuffer||ArrayBuffer.isView(t),i={apikey:this.socket.apiKey?this.socket.apiKey:``,"Content-Type":r?`application/octet-stream`:`application/json`};this.socket.accessTokenValue&&(i.Authorization=`Bearer ${this.socket.accessTokenValue}`);let a=new URL(this.broadcastEndpointURL);a.pathname+=`/${encodeURIComponent(this.subTopic)}/events/${encodeURIComponent(e)}`,this.private&&a.searchParams.set(`private`,`true`);let o={method:`POST`,headers:i,body:r?t:JSON.stringify(t)},s=await this._fetchWithTimeout(a.toString(),o,n.timeout??this.timeout);if(s.status===202)return{success:!0};if(s.status===404)return Promise.reject(Error(`httpSend() requires Realtime server v2.97.0 or newer; the endpoint returned 404. Update your Supabase CLI to a recent version, or upgrade the Realtime server in your self-hosted setup. See https://github.com/supabase/supabase-js/blob/master/packages/core/realt
15ime-js/migrations/httpsend-server-version.md`));let c=s.statusText;try{let e=await s.json();c=e.error||e.message||c}catch{}return Promise.reject(Error(c))}async send(e,t={}){if(!this.channelAdapter.canPush()&&e.type===`broadcast`){console.warn(`Realtime send() is automatically falling back to REST API. This behavior will be deprecated in the future. Please use httpSend() explicitly for REST delivery.`);let{event:n,payload:r}=e,i={apikey:this.socket.apiKey?this.socket.apiKey:``,"Content-Type":`application/json`};this.socket.accessTokenValue&&(i.Authorization=`Bearer ${this.socket.accessTokenValue}`);let a={method:`POST`,headers:i,body:JSON.stringify({messages:[{topic:this.subTopic,event:n,payload:r,private:this.private}]})};try{let e=await this._fetchWithTimeout(this.broadcastEndpointURL,a,t.timeout??this.timeout);return await e.body?.cancel(),e.ok?`ok`:`error`}catch(e){return e instanceof Error&&e.name===`AbortError`?`timed out`:`error`}}else return new Promise(n=>{let r=this.channelAdapter.push(e.type,e,t.timeout||this.timeout);e.type===`broadcast`&&!this.params?.config?.broadcast?.ack&&n(`ok`),r.receive(`ok`,()=>n(`ok`)),r.receive(`error`,()=>n(`error`)),r.receive(`timeout`,()=>n(`timed out`))})}updateJoinPayload(e){this.channelAdapter.updateJoinPayload(e)}async unsubscribe(e=this.timeout){return new Promise(t=>{this.channelAdapter.unsubscribe(e).receive(`ok`,()=>t(`ok`)).receive(`timeout`,()=>t(`timed out`)).receive(`error`,()=>t(`error`))})}teardown(){this.channelAdapter.teardown()}async _fetchWithTimeout(e,t,n){let r=new AbortController,i=setTimeout(()=>r.abort(),n),a=await this.socket.fetch(e,Object.assign(Object.assign({},t),{signal:r.signal}));return clearTimeout(i),a}_on(e,t,n){let r=e.toLocaleLowerCase(),i={type:r,filter:t,callback:n,ref:this.channelAdapter.on(e,n)};return this.bindings[r]?this.bindings[r].push(i):this.bindings[r]=[i],this._updateFilterMessage(),this}_onClose(e){this.channelAdapter.onClose(e)}_onError(e){this.channelAdapter.onError(e)}_updateFilterMessage(){this.channelAdapter.updateFilterBindings((e,t,n)=>{let r=e.event.toLocaleLowerCase();if(this._notThisChannelEvent(r,n))return!1;let i=this.bindings[r]?.find(t=>t.ref===e.ref);if(!i)return!0;if([`broadcast`,`presence`,`postgres_changes`].includes(r))if(`id`in i){let e=i.id,n=i.filter?.event;return e&&t.ids?.includes(e)&&(n===`*`||n?.toLocaleLowerCase()===t.data?.type.toLocaleLowerCase())}else{let e=(i?.filter?.event)?.toLocaleLowerCase();return e===`*`||e===(t?.event)?.toLocaleLowerCase()}else return i.type.toLocaleLowerCase()===r})}_notThisChannelEvent(e,t){let{close:n,error:r,leave:i,join:a}=li;return t&&[n,r,i,a].includes(e)&&t!==this.joinPush.ref}_updateFilterTransform(){this.channelAdapter.updatePayloadTransform((e,t,n)=>{if(typeof t==`object`&&`ids`in t){let e=t.data,{schema:n,table:r,commit_timestamp:i,type:a,errors:o}=e;return Object.assign(Object.assign({},{schema:n,table:r,commit_timestamp:i,eventType:a,new:{},old:{},errors:o}),this._getPayloadRecords(e))}return t})}copyBindings(e){if(this.joinedOnce)throw Error(`cannot copy bindings into joined channel`);for(let t in e.bindings)for(let n of e.bindings[t])this._on(n.type,n.filter,n.callback)}static isFilterValueEqual(e,t){return(e??void 0)===(t??void 0)}_getPayloadRecords(e){let t={new:{},old:{}};return(e.type===`INSERT`||e.type===`UPDATE`)&&(t.new=pi(e.columns,e.record)),(e.type===`UPDATE`||e.type===`DELETE`)&&(t.old=pi(e.columns,e.old_record)),t}},aa=class{constructor(e,t){this.socket=new Wi(e,t)}get timeout(){return this.socket.timeout}get endPoint(){return this.socket.endPoint}get transport(){return this.socket.transport}get heartbeatIntervalMs(){return this.socket.heartbeatIntervalMs}get heartbeatCallback(){return this.socket.heartbeatCallback}set heartbeatCallback(e){this.socket.heartbeatCallback=e}get heartbeatTimer(){return this.socket.heartbeatTimer}get pendingHeartbeatRef(){return this.socket.pendingHeartbeatRef}get reconnectTimer(){return this.socket.reconnectTimer}get vsn(){return this.socket.vsn}get encode(){return this.socket.encode}get decode(){return this.socket.decode}get reconnectAfterMs(){return this.socket.reconnectAfterMs}get sendBuffer(){return this.socket.sendBuffer}get stateChangeCallbacks(){return this.socket.stateChangeCallbacks}connect(){this.socket.connect()}disconnect(e,t,n,r=1e4){return new Promise(i=>{setTimeout(()=>i(`timeout`),r),this.socket.disconnect(()=>{e(),i(`ok`)},t,n)})}push(e){this.socket.push(e)}log(e,t,n){this.socket.log(e,t,n)}makeRef(){return this.socket.makeRef()}onOpen(e){this.socket.onOpen(e)}onClose(e){this.socket.onClose(e)}onError(e){this.socket.onError(e)}onMessage(e){this.socket.onMessage(e)}isConnected(){return this.socket.isConnected()}isConnecting(){return this.socket.connectionState()==ui.connecting}isDisconnecting(){return this.socket.connectionState()==ui.closing}connectionState(){return this.socket.connectionState()}endPointURL(){return this.socket.endPointURL()}sendHeartbeat(){this.socket.sendHeartbeat()}getSocket(){return this.socket}},oa={HEARTBEAT_INTERVAL:25e3,RECONNECT_DELAY:10,HEARTBEAT_TIMEOUT_FALLBACK:100},sa=[1e3,2e3,5e3,1e4],ca=1e4;function la(){let e=new Map;return{get length(){return e.size},clear(){e.clear()},getItem(t){return e.has(t)?e.get(t):null},key(t){return Array.from(e.keys())[t]??null},removeItem(t){e.delete(t)},setItem(t,n){e.set(t,String(n))}}}function ua(){try{if(typeof globalThis<`u`&&globalThis.sessionStorage)return globalThis.sessionStorage}catch{}return la()}var da=` 16 addEventListener("message", (e) => { 17 if (e.data.event === "start") { 18 setInterval(() => postMessage({ event: "keepAlive" }), e.data.interval); 19 } 20 });`,fa=class{get endPoint(){return this.socketAdapter.endPoint}get timeout(){return this.socketAdapter.timeout}get transport(){return this.socketAdapter.transport}get heartbeatCallback(){return this.socketAdapter.heartbeatCallback}get heartbeatIntervalMs(){return this.socketAdapter.heartbeatIntervalMs}get heartbeatTimer(){return this.worker?this._workerHeartbeatTimer:this.socketAdapter.heartbeatTimer}get pendingHeartbeatRef(){return this.worker?this._pendingWorkerHeartbeatRef:this.socketAdapter.pendingHeartbeatRef}get reconnectTimer(){return this.socketAdapter.reconnectTimer}get vsn(){return this.socketAdapter.vsn}get encode(){return this.socketAdapter.encode}get decode(){return this.socketAdapter.decode}get reconnectAfterMs(){return this.socketAdapter.reconnectAfterMs}get sendBuffer(){return this.socketAdapter.sendBuffer}get stateChangeCallbacks(){return this.socketAdapter.stateChangeCallbacks}constructor(e,t){if(this.channels=[],this.accessTokenValue=null,this.accessToken=null,this.apiKey=null,this.httpEndpoint=``,this.headers={},this.params={}
20,this.ref=0,this.serializer=new di,this._manuallySetToken=!1,this._authPromise=null,this._workerHeartbeatTimer=void 0,this._pendingWorkerHeartbeatRef=null,this._pendingDisconnectTimer=null,this._disconnectOnEmptyChannelsAfterMs=0,this._resolveFetch=e=>e?(...t)=>e(...t):(...e)=>fetch(...e),!t?.params?.apikey)throw Error(`API key is required to connect to Realtime`);this.apiKey=t.params.apikey;let n=this._initializeOptions(t);this.socketAdapter=new aa(e,n),this.httpEndpoint=Si(e),this.fetch=this._resolveFetch(t?.fetch)}connect(){if(!(this.isConnecting()||this.isDisconnecting()||this.isConnected())){this.accessToken&&!this._authPromise&&this._setAuthSafely(`connect`),this._setupConnectionHandlers();try{this.socketAdapter.connect()}catch(e){let t=e.message;throw t.includes(`Node.js`)?Error(`${t}\n\nTo use Realtime in Node.js, you need to provide a WebSocket implementation: 21 22Option 1: Use Node.js 22+ which has native WebSocket support 23Option 2: Install and provide the "ws" package: 24 25 npm install ws 26 27 import ws from "ws" 28 const client = new RealtimeClient(url, { 29 ...options, 30 transport: ws 31 })`):Error(`WebSocket not available: ${t}`)}this._handleNodeJsRaceCondition()}}endpointURL(){return this.socketAdapter.endPointURL()}async disconnect(e,t){return this._cancelPendingDisconnect(),this.isDisconnecting()?`ok`:await this.socketAdapter.disconnect(()=>{clearInterval(this._workerHeartbeatTimer),this._terminateWorker()},e,t)}getChannels(){return this.channels}async removeChannel(e){let t=await e.unsubscribe();return t===`ok`&&e.teardown(),t}async removeAllChannels(){let e=this.channels.map(async e=>{let t=await e.unsubscribe();return e.teardown(),t}),t=await Promise.all(e);return await this.disconnect(),t}log(e,t,n){this.socketAdapter.log(e,t,n)}connectionState(){return this.socketAdapter.connectionState()||ui.closed}isConnected(){return this.socketAdapter.isConnected()}isConnecting(){return this.socketAdapter.isConnecting()}isDisconnecting(){return this.socketAdapter.isDisconnecting()}channel(e,t={config:{}}){let n=`realtime:${e}`,r=this.getChannels().find(e=>e.topic===n);if(r)return r;{let n=new ia(`realtime:${e}`,t,this);return this._cancelPendingDisconnect(),this.channels.push(n),n}}push(e){this.socketAdapter.push(e)}async setAuth(e=null){this._authPromise=this._performAuth(e);try{await this._authPromise}finally{this._authPromise=null}}_isManualToken(){return this._manuallySetToken}async sendHeartbeat(){this.socketAdapter.sendHeartbeat()}onHeartbeat(e){this.socketAdapter.heartbeatCallback=this._wrapHeartbeatCallback(e)}_makeRef(){return this.socketAdapter.makeRef()}_remove(e){this.channels=this.channels.filter(t=>t.topic!==e.topic),this.channels.length===0&&(this.log(`transport`,`no channels remaining, scheduling disconnect`),this._schedulePendingDisconnect())}_schedulePendingDisconnect(){if(this._cancelPendingDisconnect(),this._disconnectOnEmptyChannelsAfterMs===0){this.log(`transport`,`disconnecting immediately - no channels`),this.disconnect();return}
31this._pendingDisconnectTimer=setTimeout(()=>{this._pendingDisconnectTimer=null,this.channels.length===0&&(this.log(`transport`,`deferred disconnect fired - no channels, disconnecting`),this.disconnect())},this._disconnectOnEmptyChannelsAfterMs),this.log(`transport`,`deferred disconnect scheduled in ${this._disconnectOnEmptyChannelsAfterMs}ms`)}_cancelPendingDisconnect(){this._pendingDisconnectTimer!==null&&(this.log(`transport`,`pending disconnect cancelled - channel activity detected`),clearTimeout(this._pendingDisconnectTimer),this._pendingDisconnectTimer=null)}async _performAuth(e=null){let t,n=!1;if(e)t=e,n=!0;else if(this.accessToken)try{t=await this.accessToken()}catch(e){this.log(`error`,`Error fetching access token from callback`,e),t=this.accessTokenValue}else t=this.accessTokenValue;n?this._manuallySetToken=!0:this.accessToken&&(this._manuallySetToken=!1),this.accessTokenValue!=t&&(this.accessTokenValue=t,this.channels.forEach(e=>{let n={access_token:t,version:ri};t&&e.updateJoinPayload(n),e.joinedOnce&&e.channelAdapter.isJoined()&&e.channelAdapter.push(li.access_token,{access_token:t})}))}async _waitForAuthIfNeeded(){this._authPromise&&await this._authPromise}_setAuthSafely(e=`general`){this._isManualToken()||this.setAuth().catch(t=>{this.log(`error`,`Error setting auth in ${e}`,t)})}_setupConnectionHandlers(){this.socketAdapter.onOpen(()=>{(this._authPromise||(this.accessToken&&!this.accessTokenValue?this.setAuth():Promise.resolve())).catch(e=>{this.log(`error`,`error waiting for auth on connect`,e)}),this.worker&&!this.workerRef&&this._startWorkerHeartbeat()}),this.socketAdapter.onClose(()=>{this.worker&&this.workerRef&&this._terminateWorker()}),this.socketAdapter.onMessage(e=>{e.ref&&e.ref===this._pendingWorkerHeartbeatRef&&(this._pendingWorkerHeartbeatRef=null)})}_handleNodeJsRaceCondition(){this.socketAdapter.isConnected()&&this.socketAdapter.getSocket().onConnOpen()}_wrapHeartbeatCallback(e){return(t,n)=>{t==`sent`&&this._setAuthSafely(),e&&e(t,n)}}_startWorkerHeartbeat(){this.workerUrl?this.log(`worker`,`starting worker for from ${this.workerUrl}`):this.log(`worker`,`starting default worker`);let e=this._workerObjectUrl(this.workerUrl);this.workerRef=new Worker(e),this.workerRef.onerror=e=>{this.log(`worker`,`worker error`,e.message),this._terminateWorker(),this.disconnect()},this.workerRef.onmessage=e=>{e.data.event===`keepAlive`&&this.sendHeartbeat()},this.workerRef.postMessage({event:`start`,interval:this.heartbeatIntervalMs})}_terminateWorker(){this.workerRef&&=(this.log(`worker`,`terminating worker`),this.workerRef.terminate(),void 0)}_workerObjectUrl(e){let t;if(e)t=e;else{let e=new Blob([da],{type:`application/javascript`});t=URL.createObjectURL(e)}return t}_initializeOptions(e){this.worker=e?.worker??!1,this.accessToken=e?.accessToken??null;let t={};t.timeout=e?.timeout??si,t.heartbeatIntervalMs=e?.heartbeatIntervalMs??oa.HEARTBEAT_INTERVAL,this._disconnectOnEmptyChannelsAfterMs=e?.disconnectOnEmptyChannelsAfterMs??2*(e?.heartbeatIntervalMs??oa.HEARTBEAT_INTERVAL),t.transport=e?.transport??ni.getWebSocketConstructor(),t.params=e?.params,t.logger=e?.logger,t.heartbeatCallback=this._wrapHeartbeatCallback(e?.heartbeatCallback),t.sessionStorage=e?.sessionStorage??ua(),t.reconnectAfterMs=e?.reconnectAfterMs??(e=>sa[e-1]||ca);let n,r,i=e?.vsn??oi;switch(i){case ii:n=(e,t)=>t(JSON.stringify(e)),r=(e,t)=>t(JSON.parse(e));break;case ai:n=this.serializer.encode.bind(this.serializer),r=this.serializer.decode.bind(this.serializer);break;default:throw Error(`Unsupported serializer version: ${t.vsn}`)}if(t.vsn=i,t.encode=e?.encode??n,t.decode=e?.decode??r,t.beforeReconnect=this._reconnectAuth.bind(this),(e?.logLevel||e?.log_level)&&(this.logLevel=e.logLevel||e.log_level,t.params=Object.assign(Object.assign({},t.params),{log_level:this.logLevel})),this.worker){if(typeof window<`u`&&!window.Worker)throw Error(`Web Worker is not supported`);this.workerUrl=e?.workerUrl,t.autoSendHeartbeat=!this.worker}return t}async _reconnectAuth(){await this._waitForAuthIfNeeded(),this.isConnected()||this.connect()}}
vendor: 4,836 bytes, line 31
31,pa=class extends Error{constructor(e,t){super(e),this.name=`IcebergError`,this.status=t.status,this.icebergType=t.icebergType,this.icebergCode=t.icebergCode,this.details=t.details,this.isCommitStateUnknown=t.icebergType===`CommitStateUnknownException`||[500,502,504].includes(t.status)&&t.icebergType?.includes(`CommitState`)===!0}isNotFound(){return this.status===404}isConflict(){return this.status===409}isAuthenticationTimeout(){return this.status===419}};function ma(e,t,n){let r=new URL(t,e);if(n)for(let[e,t]of Object.entries(n))t!==void 0&&r.searchParams.set(e,t);return r.toString()}async function ha(e){return!e||e.type===`none`?{}:e.type===`bearer`?{Authorization:`Bearer ${e.token}`}:e.type===`header`?{[e.name]:e.value}:e.type===`custom`?await e.getHeaders():{}}function ga(e){let t=e.fetchImpl??globalThis.fetch;return{async request({method:n,path:r,query:i,body:a,headers:o}){let s=ma(e.baseUrl,r,i),c=await ha(e.auth),l=await t(s,{method:n,headers:{...a?{"Content-Type":`application/json`}:{},...c,...o},body:a?JSON.stringify(a):void 0}),u=await l.text(),d=(l.headers.get(`content-type`)||``).includes(`application/json`),f=d&&u?JSON.parse(u):u;if(!l.ok){let e=d?f:void 0,t=e?.error;throw new pa(t?.message??`Request failed with status ${l.status}`,{status:l.status,icebergType:t?.type,icebergCode:t?.code,details:e})}return{status:l.status,headers:l.headers,data:f}}}}function _a(e){return e.join(`�`)}var va=class{constructor(e,t=``){this.client=e,this.prefix=t}async listNamespaces(e){let t=e?{parent:_a(e.namespace)}:void 0;return(await this.client.request({method:`GET`,path:`${this.prefix}/namespaces`,query:t})).data.namespaces.map(e=>({namespace:e}))}async createNamespace(e,t){let n={namespace:e.namespace,properties:t?.properties};return(await this.client.request({method:`POST`,path:`${this.prefix}/namespaces`,body:n})).data}async dropNamespace(e){await this.client.request({method:`DELETE`,path:`${this.prefix}/namespaces/${_a(e.namespace)}`})}async loadNamespaceMetadata(e){return{properties:(await this.client.request({method:`GET`,path:`${this.prefix}/namespaces/${_a(e.namespace)}`})).data.properties}}async namespaceExists(e){try{return await this.client.request({method:`HEAD`,path:`${this.prefix}/namespaces/${_a(e.namespace)}`}),!0}catch(e){if(e instanceof pa&&e.status===404)return!1;throw e}}async createNamespaceIfNotExists(e,t){try{return await this.createNamespace(e,t)}catch(e){if(e instanceof pa&&e.status===409)return;throw e}}};function ya(e){return e.join(`�`)}var ba=class{constructor(e,t=``,n){this.client=e,this.prefix=t,this.accessDelegation=n}async listTables(e){return(await this.client.request({method:`GET`,path:`${this.prefix}/namespaces/${ya(e.namespace)}/tables`})).data.identifiers}async createTable(e,t){let n={};return this.accessDelegation&&(n[`X-Iceberg-Access-Delegation`]=this.accessDelegation),(await this.client.request({method:`POST`,path:`${this.prefix}/namespaces/${ya(e.namespace)}/tables`,body:t,headers:n})).data.metadata}async updateTable(e,t){let n=await this.client.request({method:`POST`,path:`${this.prefix}/namespaces/${ya(e.namespace)}/tables/${e.name}`,body:t});return{"metadata-location":n.data[`metadata-location`],metadata:n.data.metadata}}async dropTable(e,t){await this.client.request({method:`DELETE`,path:`${this.prefix}/namespaces/${ya(e.namespace)}/tables/${e.name}`,query:{purgeRequested:String(t?.purge??!1)}})}async loadTable(e){let t={};return this.accessDelegation&&(t[`X-Iceberg-Access-Delegation`]=this.accessDelegation),(await this.client.request({method:`GET`,path:`${this.prefix}/namespaces/${ya(e.namespace)}/tables/${e.name}`,headers:t})).data.metadata}async tableExists(e){let t={};this.accessDelegation&&(t[`X-Iceberg-Access-Delegation`]=this.accessDelegation);try{return await this.client.request({method:`HEAD`,path:`${this.prefix}/namespaces/${ya(e.namespace)}/tables/${e.name}`,headers:t}),!0}catch(e){if(e instanceof pa&&e.status===404)return!1;throw e}}async createTableIfNotExists(e,t){try{return await this.createTable(e,t)}catch(n){if(n instanceof pa&&n.status===409)return await this.loadTable({namespace:e.namespace,name:t.name});throw n}}},xa=class{constructor(e){let t=`v1`;e.catalogName&&(t+=`/${e.catalogName}`);let n=e.baseUrl.endsWith(`/`)?e.baseUrl:`${e.baseUrl}/`;this.client=ga({baseUrl:n,auth:e.auth,fetchImpl:e.fetch}),this.accessDelegation=e.accessDelegation?.join(`,`),this.namespaceOps=new va(this.client,t),this.tableOps=new ba(this.client,t,this.accessDelegation)}async listNamespaces(e){return this.namespaceOps.listNamespaces(e)}async createNamespace(e,t){return this.namespaceOps.createNamespace(e,t)}async dropNamespace(e){await this.namespaceOps.dropNamespace(e)}async loadNamespaceMetadata(e){return this.namespaceOps.loadNamespaceMetadata(e)}async listTables(e){return this.tableOps.listTables(e)}
31async createTable(e,t){return this.tableOps.createTable(e,t)}async updateTable(e,t){return this.tableOps.updateTable(e,t)}async dropTable(e,t){await this.tableOps.dropTable(e,t)}async loadTable(e){return this.tableOps.loadTable(e)}async namespaceExists(e){return this.namespaceOps.namespaceExists(e)}async tableExists(e){return this.tableOps.tableExists(e)}async createNamespaceIfNotExists(e,t){return this.namespaceOps.createNamespaceIfNotExists(e,t)}async createTableIfNotExists(e,t){return this.tableOps.createTableIfNotExists(e,t)}};function Sa(e){"@babel/helpers - typeof";return Sa=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},Sa(e)}function Ca(e,t){if(Sa(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(Sa(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function wa(e){var t=Ca(e,`string`);return Sa(t)==`symbol`?t:t+``}function Ta(e,t,n){return(t=wa(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ea(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function Da(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?Ea(Object(n),!0).forEach(function(t){Ta(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ea(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var Oa=class extends Error{constructor(e,t=`storage`,n,r){super(e),this.__isStorageError=!0,this.namespace=t,this.name=t===`vectors`?`StorageVectorsError`:`StorageError`,this.status=n,this.statusCode=r}toJSON(){return{name:this.name,message:this.message,status:this.status,statusCode:this.statusCode}}};function ka(e){return typeof e==`object`&&!!e&&`__isStorageError`in e}var Aa=class extends Oa{constructor(e,t,n,r=`storage`){super(e,r,t,n),this.name=r===`vectors`?`StorageVectorsApiError`:`StorageApiError`,this.status=t,this.statusCode=n}toJSON(){return Da({},super.toJSON())}},ja=class extends Oa{constructor(e,t,n=`storage`){super(e,n),this.name=n===`vectors`?`StorageVectorsUnknownError`:`StorageUnknownError`,this.originalError=t}};function Ma(e,t,n){let r=Da({},e),i=t.toLowerCase();for(let e of Object.keys(r))e.toLowerCase()===i&&delete r[e];return r[i]=n,r}function Na(e){let t={};for(let[n,r]of Object.entries(e))t[n.toLowerCase()]=r;return t}var Pa=e=>e?(...t)=>e(...t):(...e)=>fetch(...e),Fa=e=>{if(typeof e!=`object`||!e)return!1;let t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},Ia=e=>{if(Array.isArray(e))return e.map(e=>Ia(e));if(typeof e==`function`||e!==Object(e))return e;let t={};return Object.entries(e).forEach(([e,n])=>{let r=e.replace(/([-_][a-z])/gi,e=>e.toUpperCase().replace(/[-_]/g,``));t[r]=Ia(n)}),t},La=e=>!e||typeof e!=`string`||e.length===0||e.length>100||e.trim()!==e||e.includes(`/`)||e.includes(`\\`)?!1:/^[\w!.\*'() &$@=;:+,?-]+$/.test(e),Ra=e=>{if(typeof e==`object`&&e){let t=e;if(typeof t.msg==`string`)return t.msg;if(typeof t.message==`string`)return t.message;if(typeof t.error_description==`string`)return t.error_description;if(typeof t.error==`string`)return t.error;if(typeof t.error==`object`&&t.error!==null){let e=t.error;if(typeof e.message==`string`)return e.message}}return JSON.stringify(e)},za=async(e,t,n,r)=>{if(typeof e==`object`&&e&&`json`in e&&typeof e.json==`function`){let n=e,i=parseInt(String(n.status),10);Number.isFinite(i)||(i=500),n.json().then(e=>{let n=e?.statusCode||e?.code||i+``;t(new Aa(Ra(e),i,n,r))}).catch(()=>{let e=i+``;t(new Aa(n.statusText||`HTTP ${i} error`,i,e,r))})}else t(new ja(Ra(e),e,r))},Ba=(e,t,n,r)=>{let i={method:e,headers:t?.headers||{}};if(e===`GET`||e===`HEAD`||!r)return Da(Da({},i),n);if(Fa(r)){let e=t?.headers||{},n;for(let[t,r]of Object.entries(e))t.toLowerCase()===`content-type`&&(n=r);i.headers=Ma(e,`Content-Type`,n??`application/json`),i.body=JSON.stringify(r)}else i.body=r;return t?.duplex&&(i.duplex=t.duplex),Da(Da({},i),n)};async function Va(e,t,n,r,i,a,o){return new Promise((s,c)=>{e(n,Ba(t,r,i,a)).then(e=>{if(!e.ok)throw e;if(r?.noResolveJson)return e;if(o===`vectors`){let t=e.headers.get(`content-type`);if(e.headers.get(`content-length`)===`0`||e.status===204||!t||!t.includes(`application/json`))return{}}return e.json()}).then(e=>s(e)).catch(e=>za(e,c,r,o))})}function Ha(e=`storage`){return{get:async(t,n,r,i)=>Va(t,`GET`,n,r,i,void 0,e),post:async(t,n,r,i,a)=>Va(t,`POST`,n,i,a,r,e),put:async(t,n,r,i,a)=>Va(t,`PUT`,n,i,a,r,e),head:async(t,n,r,i)=>Va(t,`HEAD`,n,Da(Da({},r),{},{noResolveJson:!0}),i,void 0,e),remove:async(t,n,r,i,a)=>Va(t,`DELETE`,n,i,a,r,e)}}var{get:Ua,post:Wa,put:Ga,head:Ka,remove:qa}=Ha(`storage`),Ja=Ha(`vectors`),Ya=class{constructor(e,t={},n,r=`storage`){this.shouldThrowOnError=!1,this.url=e,this.headers=Na(t),this.fetch=Pa(n),this.namespace=r}throwOnError(){return this.shouldThrowOnError=!0,this}setHeader(e,t){return this.headers=Ma(this.headers,e,t),this}async handleOperation(e){var t=this;try{return{data:await e(),error:null}}catch(e){if(t.shouldThrowOnError)throw e;if(ka(e))return{data:null,error:e};throw e}}},Xa=Symbol.toStringTag,Za=class{constructor(e,t){this.downloadFn=e,this.shouldThrowOnError=t,this[Xa]=`StreamDownloadBuilder`,this.promise=null}
31then(e,t){return this.getPromise().then(e,t)}catch(e){return this.getPromise().catch(e)}finally(e){return this.getPromise().finally(e)}getPromise(){return this.promise||=this.execute(),this.promise}async execute(){var e=this;try{return{data:(await e.downloadFn()).body,error:null}}catch(t){if(e.shouldThrowOnError)throw t;if(ka(t))return{data:null,error:t};throw t}}},Qa=Symbol.toStringTag,$a=class{constructor(e,t){this.downloadFn=e,this.shouldThrowOnError=t,this[Qa]=`BlobDownloadBuilder`,this.promise=null}asStream(){return new Za(this.downloadFn,this.shouldThrowOnError)}then(e,t){return this.getPromise().then(e,t)}catch(e){return this.getPromise().catch(e)}finally(e){return this.getPromise().finally(e)}getPromise(){return this.promise||=this.execute(),this.promise}async execute(){var e=this;try{return{data:await(await e.downloadFn()).blob(),error:null}}catch(t){if(e.shouldThrowOnError)throw t;if(ka(t))return{data:null,error:t};throw t}}},eo={limit:100,offset:0,sortBy:{column:`name`,order:`asc`}},to={cacheControl:`3600`,contentType:`text/plain;charset=UTF-8`,upsert:!1},no=class extends Ya{constructor(e,t={},n,r){super(e,t,r,`storage`),this.bucketId=n}async uploadOrUpdate(e,t,n,r){var i=this;return i.handleOperation(async()=>{let a,o=Da(Da({},to),r),s=Da(Da({},i.headers),e===`POST`&&{"x-upsert":String(o.upsert)}),c=o.metadata;if(typeof Blob<`u`&&n instanceof Blob?(a=new FormData,a.append(`cacheControl`,o.cacheControl),c&&a.append(`metadata`,i.encodeMetadata(c)),a.append(``,n)):typeof FormData<`u`&&n instanceof FormData?(a=n,a.has(`cacheControl`)||a.append(`cacheControl`,o.cacheControl),c&&!a.has(`metadata`)&&a.append(`metadata`,i.encodeMetadata(c))):(a=n,s[`cache-control`]=`max-age=${o.cacheControl}`,s[`content-type`]=o.contentType,c&&(s[`x-metadata`]=i.toBase64(i.encodeMetadata(c))),(typeof ReadableStream<`u`&&a instanceof ReadableStream||a&&typeof a==`object`&&`pipe`in a&&typeof a.pipe==`function`)&&!o.duplex&&(o.duplex=`half`)),r?.headers)for(let[e,t]of Object.entries(r.headers))s=Ma(s,e,t);let l=i._removeEmptyFolders(t),u=i._getFinalPath(l),d=await(e==`PUT`?Ga:Wa)(i.fetch,`${i.url}/object/${u}`,a,Da({headers:s},o?.duplex?{duplex:o.duplex}:{}));return{path:l,id:d.Id,fullPath:d.Key}})}async upload(e,t,n){return this.uploadOrUpdate(`POST`,e,t,n)}async uploadToSignedUrl(e,t,n,r){var i=this;let a=i._removeEmptyFolders(e),o=i._getFinalPath(a),s=new URL(i.url+`/object/upload/sign/${o}`);return s.searchParams.set(`token`,t),i.handleOperation(async()=>{let e,t=Da(Da({},to),r),o=Da(Da({},i.headers),{"x-upsert":String(t.upsert)}),c=t.metadata;if(typeof Blob<`u`&&n instanceof Blob?(e=new FormData,e.append(`cacheControl`,t.cacheControl),c&&e.append(`metadata`,i.encodeMetadata(c)),e.append(``,n)):typeof FormData<`u`&&n instanceof FormData?(e=n,e.has(`cacheControl`)||e.append(`cacheControl`,t.cacheControl),c&&!e.has(`metadata`)&&e.append(`metadata`,i.encodeMetadata(c))):(e=n,o[`cache-control`]=`max-age=${t.cacheControl}`,o[`content-type`]=t.contentType,c&&(o[`x-metadata`]=i.toBase64(i.encodeMetadata(c))),(typeof ReadableStream<`u`&&e instanceof ReadableStream||e&&typeof e==`object`&&`pipe`in e&&typeof e.pipe==`function`)&&!t.duplex&&(t.duplex=`half`)),r?.headers)for(let[e,t]of Object.entries(r.headers))o=Ma(o,e,t);return{path:a,fullPath:(await Ga(i.fetch,s.toString(),e,Da({headers:o},t?.duplex?{duplex:t.duplex}:{}))).Key}})}async createSignedUploadUrl(e,t){var n=this;return n.handleOperation(async()=>{let r=n._getFinalPath(e),i=Da({},n.headers);t?.upsert&&(i[`x-upsert`]=`true`);let a=await Wa(n.fetch,`${n.url}/object/upload/sign/${r}`,{},{headers:i}),o=new URL(n.url+a.url),s=o.searchParams.get(`token`);if(!s)throw new Oa(`No token returned by API`);return{signedUrl:o.toString(),path:e,token:s}})}async update(e,t,n){return this.uploadOrUpdate(`PUT`,e,t,n)}async move(e,t,n){var r=this;return r.handleOperation(async()=>await Wa(r.fetch,`${r.url}/object/move`,{bucketId:r.bucketId,sourceKey:e,destinationKey:t,de
31stinationBucket:n?.destinationBucket},{headers:r.headers}))}async copy(e,t,n){var r=this;return r.handleOperation(async()=>({path:(await Wa(r.fetch,`${r.url}/object/copy`,{bucketId:r.bucketId,sourceKey:e,destinationKey:t,destinationBucket:n?.destinationBucket},{headers:r.headers})).Key}))}async createSignedUrl(e,t,n){var r=this;return r.handleOperation(async()=>{let i=r._getFinalPath(e),a=typeof n?.transform==`object`&&n.transform!==null&&Object.keys(n.transform).length>0,o=await Wa(r.fetch,`${r.url}/object/sign/${i}`,Da({expiresIn:t},a?{transform:n.transform}:{}),{headers:r.headers}),s=new URLSearchParams;n?.download&&s.set(`download`,n.download===!0?``:n.download),n?.cacheNonce!=null&&s.set(`cacheNonce`,String(n.cacheNonce));let c=s.toString();return{signedUrl:encodeURI(`${r.url}${o.signedURL}${c?`&${c}`:``}`)}})}async createSignedUrls(e,t,n){var r=this;return r.handleOperation(async()=>{let i=await Wa(r.fetch,`${r.url}/object/sign/${r.bucketId}`,{expiresIn:t,paths:e},{headers:r.headers}),a=new URLSearchParams;n?.download&&a.set(`download`,n.download===!0?``:n.download),n?.cacheNonce!=null&&a.set(`cacheNonce`,String(n.cacheNonce));let o=a.toString();return i.map(e=>Da(Da({},e),{},{signedUrl:e.signedURL?encodeURI(`${r.url}${e.signedURL}${o?`&${o}`:``}`):null}))})}download(e,t,n){let r=typeof t?.transform==`object`&&t.transform!==null&&Object.keys(t.transform).length>0?`render/image/authenticated`:`object`,i=new URLSearchParams;t?.transform&&this.applyTransformOptsToQuery(i,t.transform),t?.cacheNonce!=null&&i.set(`cacheNonce`,String(t.cacheNonce));let a=i.toString(),o=this._getFinalPath(e);return new $a(()=>Ua(this.fetch,`${this.url}/${r}/${o}${a?`?${a}`:``}`,{headers:this.headers,noResolveJson:!0},n),this.shouldThrowOnError)}async info(e){var t=this;let n=t._getFinalPath(e);return t.handleOperation(async()=>Ia(await Ua(t.fetch,`${t.url}/object/info/${n}`,{headers:t.headers})))}async exists(e){var t=this;let n=t._getFinalPath(e);try{return await Ka(t.fetch,`${t.url}/object/${n}`,{headers:t.headers}),{data:!0,error:null}}catch(e){if(t.shouldThrowOnError)throw e;if(ka(e)){let t=e instanceof Aa?e.status:e instanceof ja?e.originalError?.status:void 0;if(t!==void 0&&[400,404].includes(t))return{data:!1,error:e}}throw e}}getPublicUrl(e,t){let n=this._getFinalPath(e),r=new URLSearchParams;t?.download&&r.set(`download`,t.download===!0?``:t.download),t?.transform&&this.applyTransformOptsToQuery(r,t.transform),t?.cacheNonce!=null&&r.set(`cacheNonce`,String(t.cacheNonce));let i=r.toString(),a=typeof t?.transform==`object`&&t.transform!==null&&Object.keys(t.transform).length>0?`render/image`:`object`;return{data:{publicUrl:encodeURI(`${this.url}/${a}/public/${n}`)+(i?`?${i}`:``)}}}async remove(e){var t=this;return t.handleOperation(async()=>await qa(t.fetch,`${t.url}/object/${t.bucketId}`,{prefixes:e},{headers:t.headers}))}async list(e,t,n){var r=this;return r.handleOperation(async()=>{let i=Da(Da(Da({},eo),t),{},{prefix:e||``});return await Wa(r.fetch,`${r.url}/object/list/${r.bucketId}`,i,{headers:r.headers},n)})}async listV2(e,t){var n=this;return n.handleOperation(async()=>{let r=Da({},e);return await Wa(n.fetch,`${n.url}/object/list-v2/${n.bucketId}`,r,{headers:n.headers},t)})}encodeMetadata(e){return JSON.stringify(e)}toBase64(e){return typeof Buffer<`u`?Buffer.from(e).toString(`base64`):btoa(e)}_getFinalPath(e){return`${this.bucketId}/${e.replace(/^\/+/,``)}`}_removeEmptyFolders(e){return e.replace(/^\/|\/$/g,``).replace(/\/+/g,`/`)}applyTransformOptsToQuery(e,t){return t.width&&e.set(`width`,t.width.toString()),t.height&&e.set(`height`,t.height.toString()),t.resize&&e.set(`resize`,t.resize),t.format&&e.set(`format`,t.format),t.quality&&e.set(`quality`,t.quality.toString()),e}},ro={"X-Client-Info":`storage-js/2.108.2`},io=class extends Ya{constructor(e,t={},n,r){let i=new URL(e);r?.useNewHostname&&/supabase\.(co|in|red)$/.test(i.hostname)&&!i.hostname.includes(`storage.supabase.`)&&(i.hostname=i.hostname.replace(`supabase.`,`storage.supabase.`));let a=i.href.replace(/\/$/,``),o=Da(Da({},ro),t);super(a,o,n,`storage`)}async listBuckets(e){var t=this;return t.handleOperation(async()=>{let n=t.listBucketOptionsToQueryString(e);return await Ua(t.fetch,`${t.url}/bucket${n}`,{headers:t.headers})})}async getBucket(e){var t=this;return t.handleOperation(async()=>await Ua(t.fetch,`${t.url}/bucket/${e}`,{headers:t.headers}))}async createBucket(e,t={public:!1}){var n=this;return n.handleOperation(async()=>await Wa(n.fetch,`${n.url}/bucket`,{id:e,name:e,type:t.type,public:t.public,file_size_limit:t.fileSizeLimit,allowed_mime_types:t.allowedMimeTypes},{headers:n.headers}))}async updateBucket(e,t){var n=this;return n.handleOperation(async()=>await Ga(n.fetch,`${n.url}/bucket/${e}`,{id:e,name:e,public:t.public,file_size_limit:t.fileSizeLimit,allowed_mime_types:t.allowedMimeTypes},{headers:n.headers}))}async emptyBucket(e){var t=this;return t.handleOperation(async()=>await Wa(t.fetch,`${t.url}/bucket/${e}/empty`,{},{headers:t.headers}))}async deleteBucket(e){var t=this;return t.handleOperation(async()=>await qa(t.fetch,`${t.url}/bucket/${e}`,{},{headers:t.headers}))}listBucketOptionsToQueryString(e){let t={};return e&&(`limit`in e&&(t.limit=String(e.limit)),`offset`in e&&(t.offset=String(e.offset)),e.search&&(t.search=e.search),e.sortColumn&&(t.sortColumn=e.sortColumn),e.sortOrder&&(t.sortOrder=e.sortOrder)),Object.keys(t).length>
310?`?`+new URLSearchParams(t).toString():``}},ao=class extends Ya{constructor(e,t={},n){let r=e.replace(/\/$/,``),i=Da(Da({},ro),t);super(r,i,n,`storage`)}async createBucket(e){var t=this;return t.handleOperation(async()=>await Wa(t.fetch,`${t.url}/bucket`,{name:e},{headers:t.headers}))}async listBuckets(e){var t=this;return t.handleOperation(async()=>{let n=new URLSearchParams;e?.limit!==void 0&&n.set(`limit`,e.limit.toString()),e?.offset!==void 0&&n.set(`offset`,e.offset.toString()),e?.sortColumn&&n.set(`sortColumn`,e.sortColumn),e?.sortOrder&&n.set(`sortOrder`,e.sortOrder),e?.search&&n.set(`search`,e.search);let r=n.toString(),i=r?`${t.url}/bucket?${r}`:`${t.url}/bucket`;return await Ua(t.fetch,i,{headers:t.headers})})}async deleteBucket(e){var t=this;return t.handleOperation(async()=>await qa(t.fetch,`${t.url}/bucket/${e}`,{},{headers:t.headers}))}from(e){var t=this;if(!La(e))throw new Oa(`Invalid bucket name: File, folder, and bucket names must follow AWS object key naming guidelines and should avoid the use of any other characters.`);let n=new xa({baseUrl:this.url,catalogName:e,auth:{type:`custom`,getHeaders:async()=>t.headers},fetch:this.fetch}),r=this.shouldThrowOnError;return new Proxy(n,{get(e,t){let n=e[t];return typeof n==`function`?async(...t)=>{try{return{data:await n.apply(e,t),error:null}}catch(e){if(r)throw e;return{data:null,error:e}}}:n}})}},oo=class extends Ya{constructor(e,t={},n){let r=e.replace(/\/$/,``),i=Da(Da({},ro),{},{"Content-Type":`application/json`},t);super(r,i,n,`vectors`)}async createIndex(e){var t=this;return t.handleOperation(async()=>await Ja.post(t.fetch,`${t.url}/CreateIndex`,e,{headers:t.headers})||{})}async getIndex(e,t){var n=this;return n.handleOperation(async()=>await Ja.post(n.fetch,`${n.url}/GetIndex`,{vectorBucketName:e,indexName:t},{headers:n.headers}))}async listIndexes(e){var t=this;return t.handleOperation(async()=>await Ja.post(t.fetch,`${t.url}/ListIndexes`,e,{headers:t.headers}))}async deleteIndex(e,t){var n=this;return n.handleOperation(async()=>await Ja.post(n.fetch,`${n.url}/DeleteIndex`,{vectorBucketName:e,indexName:t},{headers:n.headers})||{})}},so=class extends Ya{constructor(e,t={},n){let r=e.replace(/\/$/,``),i=Da(Da({},ro),{},{"Content-Type":`application/json`},t);super(r,i,n,`vectors`)}async putVectors(e){var t=this;if(e.vectors.length<1||e.vectors.length>500)throw Error(`Vector batch size must be between 1 and 500 items`);return t.handleOperation(async()=>await Ja.post(t.fetch,`${t.url}/PutVectors`,e,{headers:t.headers})||{})}async getVectors(e){var t=this;return t.handleOperation(async()=>await Ja.post(t.fetch,`${t.url}/GetVectors`,e,{headers:t.headers}))}async listVectors(e){var t=this;if(e.segmentCount!==void 0){if(e.segmentCount<1||e.segmentCount>16)throw Error(`segmentCount must be between 1 and 16`);if(e.segmentIndex!==void 0&&(e.segmentIndex<0||e.segmentIndex>=e.segmentCount))throw Error(`segmentIndex must be between 0 and ${e.segmentCount-1}`)}return t.handleOperation(async()=>await Ja.post(t.fetch,`${t.url}/ListVectors`,e,{headers:t.headers}))}async queryVectors(e){var t=this;return t.handleOperation(async()=>await Ja.post(t.fetch,`${t.url}/QueryVectors`,e,{headers:t.headers}))}async deleteVectors(e){var t=this;if(e.keys.length<1||e.keys.length>500)throw Error(`Keys batch size must be between 1 and 500 items`);return t.handleOperation(async()=>await Ja.post(t.fetch,`${t.url}/DeleteVectors`,e,{headers:t.headers})||{})}},co=class extends Ya{constructor(e,t={},n){let r=e.replace(/\/$/,``),i=Da(Da({},ro),{},{"Content-Type":`application/json`},t);super(r,i,n,`vectors`)}async createBucket(e){var t=this;return t.handleOperation(async()=>await Ja.post(t.fetch,`${t.url}/CreateVectorBucket`,{vectorBucketName:e},{headers:t.headers})||{})}async getBucket(e){var t=this;return t.handleOperation(async()=>await Ja.post(t.fetch,`${t.url}/GetVectorBucket`,{vectorBucketName:e},{headers:t.headers}))}async listBuckets(e={}){var t=this;return t.handleOperation(async()=>await Ja.post(t.fetch,`${t.url}/ListVectorBuckets`,e,{headers:t.headers}))}async deleteBucket(e){var t=this;return t.handleOperation(async()=>await Ja.post(t.fetch,`${t.url}/DeleteVectorBucket`,{vectorBucketName:e},{headers:t.headers})||{})}},lo=class extends co{constructor(e,t={}){super(e,t.headers||{},t.fetch)}from(e){return new uo(this.url,this.headers,e,this.fetch)}async createBucket(e){var t=()=>super.createBucket,n=this;return t().call(n,e)}async getBucket(e){var t=()=>super.getBucket,n=this;return t().call(n,e)}async listBuckets(e={}){var t=()=>super.listBuckets,n=this;return t().call(n,e)}async deleteBucket(e){var t=()=>super.deleteBucket,n=this;return t().call(n,e)}},uo=class extends oo{constructor(e,t,n,r){super(e,t,r),this.vectorBucketName=n}async createIndex(e){var t=()=>super.createIndex,n=this;return t().call(n,Da(Da({},e),{},{vectorBucketName:n.vectorBucketName}))}
31async listIndexes(e={}){var t=()=>super.listIndexes,n=this;return t().call(n,Da(Da({},e),{},{vectorBucketName:n.vectorBucketName}))}async getIndex(e){var t=()=>super.getIndex,n=this;return t().call(n,n.vectorBucketName,e)}async deleteIndex(e){var t=()=>super.deleteIndex,n=this;return t().call(n,n.vectorBucketName,e)}index(e){return new fo(this.url,this.headers,this.vectorBucketName,e,this.fetch)}},fo=class extends so{constructor(e,t,n,r,i){super(e,t,i),this.vectorBucketName=n,this.indexName=r}async putVectors(e){var t=()=>super.putVectors,n=this;return t().call(n,Da(Da({},e),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}async getVectors(e){var t=()=>super.getVectors,n=this;return t().call(n,Da(Da({},e),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}async listVectors(e={}){var t=()=>super.listVectors,n=this;return t().call(n,Da(Da({},e),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}async queryVectors(e){var t=()=>super.queryVectors,n=this;return t().call(n,Da(Da({},e),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}async deleteVectors(e){var t=()=>super.deleteVectors,n=this;return t().call(n,Da(Da({},e),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}},po=class extends io{constructor(e,t={},n,r){super(e,t,n,r)}from(e){return new no(this.url,this.headers,e,this.fetch)}get vectors(){return new lo(this.url+`/vector`,{headers:this.headers,fetch:this.fetch})}get analytics(){return new ao(this.url+`/iceberg`,this.headers,this.fetch)}},mo=`2.108.2`,ho=30*1e3,go=3*ho,_o=2*ho,vo=`http://localhost:9999`,yo=`supabase.auth.token`,bo={"X-Client-Info":`gotrue-js/${mo}`},xo=`X-Supabase-Api-Version`,So={"2024-01-01":{timestamp:Date.parse(`2024-01-01T00:00:00.0Z`),name:`2024-01-01`}}
31,Co=/^([a-z0-9_-]{4})*($|[a-z0-9_-]{3}$|[a-z0-9_-]{2}$)$/i,wo=class extends Error{constructor(e,t,n){super(e),this.__isAuthError=!0,this.name=`AuthError`,this.status=t,this.code=n}toJSON(){return{name:this.name,message:this.message,status:this.status,code:this.code}}};function F(e){return typeof e==`object`&&!!e&&`__isAuthError`in e}var To=class extends wo{constructor(e,t,n){super(e,t,n),this.name=`AuthApiError`,this.status=t,this.code=n}};function Eo(e){return F(e)&&e.name===`AuthApiError`}var Do=class extends wo{constructor(e,t){super(e),this.name=`AuthUnknownError`,this.originalError=t}},Oo=class extends wo{constructor(e,t,n,r){super(e,n,r),this.name=t,this.status=n}},ko=class extends Oo{constructor(){super(`Auth session missing!`,`AuthSessionMissingError`,400,void 0)}};function Ao(e){return F(e)&&e.name===`AuthSessionMissingError`}var jo=class extends Oo{constructor(){super(`Auth session or user missing`,`AuthInvalidTokenResponseError`,500,void 0)}},Mo=class extends Oo{constructor(e){super(e,`AuthInvalidCredentialsError`,400,void 0)}},No=class extends Oo{constructor(e,t=null){super(e,`AuthImplicitGrantRedirectError`,500,void 0),this.details=null,this.details=t}toJSON(){return Object.assign(Object.assign({},super.toJSON()),{details:this.details})}};function Po(e){return F(e)&&e.name===`AuthImplicitGrantRedirectError`}var Fo=class extends Oo{constructor(e,t=null){super(e,`AuthPKCEGrantCodeExchangeError`,500,void 0),this.details=null,this.details=t}toJSON(){return Object.assign(Object.assign({},super.toJSON()),{details:this.details})}},Io=class extends Oo{constructor(){super(`PKCE code verifier not found in storage. This can happen if the auth flow was initiated in a different browser or device, or if the storage was cleared. For SSR frameworks (Next.js, SvelteKit, etc.), use @supabase/ssr on both the server and client to store the code verifier in cookies.`,`AuthPKCECodeVerifierMissingError`,400,`pkce_code_verifier_not_found`)}},Lo=class extends Oo{constructor(e,t){super(e,`AuthRetryableFetchError`,t,void 0)}};function Ro(e){return F(e)&&e.name===`AuthRetryableFetchError`}var zo=class extends Oo{constructor(e=`Refresh result discarded: session state changed mid-flight (e.g., concurrent signOut)`){super(e,`AuthRefreshDiscardedError`,409,void 0)}};function Bo(e){return F(e)&&e.name===`AuthRefreshDiscardedError`}var Vo=class extends Oo{constructor(e,t,n){super(e,`AuthWeakPasswordError`,t,`weak_password`),this.reasons=n}toJSON(){return Object.assign(Object.assign({},super.toJSON()),{reasons:this.reasons})}},Ho=class extends Oo{constructor(e){super(e,`AuthInvalidJwtError`,400,`invalid_jwt`)}},Uo=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_`.split(``),Wo=` 32\r=`.split(``),Go=(()=>{let e=Array(128);for(let t=0;t<e.length;t+=1)e[t]=-1;for(let t=0;t<Wo.length;t+=1)e[Wo[t].charCodeAt(0)]=-2;for(let t=0;t<Uo.length;t+=1)e[Uo[t].charCodeAt(0)]=t;return e})();function Ko(e,t,n){if(e!==null)for(t.queue=t.queue<<8|e,t.queuedBits+=8;t.queuedBits>=6;)n(Uo[t.queue>>t.queuedBits-6&63]),t.queuedBits-=6;else if(t.queuedBits>0)for(t.queue<<=6-t.queuedBits,t.queuedBits=6;t.queuedBits>=6;)n(Uo[t.queue>>t.queuedBits-6&63]),t.queuedBits-=6}function qo(e,t,n){let r=Go[e];if(r>-1)for(t.queue=t.queue<<6|r,t.queuedBits+=6;t.queuedBits>=8;)n(t.queue>>t.queuedBits-8&255),t.queuedBits-=8;else if(r===-2)return;else throw Error(`Invalid Base64-URL character "${String.fromCharCode(e)}"`)}function Jo(e){let t=[],n=e=>{t.push(String.fromCodePoint(e))},r={utf8seq:0,codepoint:0},i={queue:0,queuedBits:0},a=e=>{Zo(e,r,n)};for(let t=0;t<e.length;t+=1)qo(e.charCodeAt(t),i,a);return t.join(``)}function Yo(e,t){if(e<=127){t(e);return}else if(e<=2047){t(192|e>>6),t(128|e&63);return}else if(e<=65535){t(224|e>>12),t(128|e>>6&63),t(128|e&63);return}else if(e<=1114111){t(240|e>>18),t(128|e>>12&63),t(128|e>>6&63),t(128|e&63);return}throw Error(`Unrecognized Unicode codepoint: ${e.toString(16)}`)}function Xo(e,t){for(let n=0;n<e.length;n+=1){let r=e.charCodeAt(n);if(r>55295&&r<=56319){let t=(r-55296)*1024&65535;r=(e.charCodeAt(n+1)-56320&65535|t)+65536,n+=1}Yo(r,t)}}
32function Zo(e,t,n){if(t.utf8seq===0){if(e<=127){n(e);return}for(let n=1;n<6;n+=1)if(!(e>>7-n&1)){t.utf8seq=n;break}if(t.utf8seq===2)t.codepoint=e&31;else if(t.utf8seq===3)t.codepoint=e&15;else if(t.utf8seq===4)t.codepoint=e&7;else throw Error(`Invalid UTF-8 sequence`);--t.utf8seq}else if(t.utf8seq>0){if(e<=127)throw Error(`Invalid UTF-8 sequence`);t.codepoint=t.codepoint<<6|e&63,--t.utf8seq,t.utf8seq===0&&n(t.codepoint)}}function Qo(e){let t=[],n={queue:0,queuedBits:0},r=e=>{t.push(e)};for(let t=0;t<e.length;t+=1)qo(e.charCodeAt(t),n,r);return new Uint8Array(t)}function $o(e){let t=[];return Xo(e,e=>t.push(e)),new Uint8Array(t)}function es(e){let t=[],n={queue:0,queuedBits:0},r=e=>{t.push(e)};return e.forEach(e=>Ko(e,n,r)),Ko(null,n,r),t.join(``)}function ts(e){return Math.round(Date.now()/1e3)+e}function ns(){return Symbol(`auth-callback`)}var rs=()=>typeof window<`u`&&typeof document<`u`,is={tested:!1,writable:!1},as=()=>{if(!rs())return!1;try{if(typeof globalThis.localStorage!=`object`)return!1}catch{return!1}if(is.tested)return is.writable;let e=`lswt-${Math.random()}${Math.random()}`;try{globalThis.localStorage.setItem(e,e),globalThis.localStorage.removeItem(e),is.tested=!0,is.writable=!0}catch{is.tested=!0,is.writable=!1}return is.writable};function os(e){let t={},n=new URL(e);if(n.hash&&n.hash[0]===`#`)try{new URLSearchParams(n.hash.substring(1)).forEach((e,n)=>{t[n]=e})}catch{}return n.searchParams.forEach((e,n)=>{t[n]=e}),t}var ss=e=>e?(...t)=>e(...t):(...e)=>fetch(...e),cs=e=>typeof e==`object`&&!!e&&`status`in e&&`ok`in e&&`json`in e&&typeof e.json==`function`,ls=async(e,t,n)=>{await e.setItem(t,JSON.stringify(n))},us=async(e,t)=>{let n=await e.getItem(t);if(!n)return null;try{return JSON.parse(n)}catch{return null}},ds=async(e,t)=>{await e.removeItem(t)},fs=class e{constructor(){this.promise=new e.promiseConstructor((e,t)=>{this.resolve=e,this.reject=t})}};fs.promiseConstructor=Promise;function ps(e){let t=e.split(`.`);if(t.length!==3)throw new Ho(`Invalid JWT structure`);for(let e=0;e<t.length;e++)if(!Co.test(t[e]))throw new Ho(`JWT not in base64url format`);return{header:JSON.parse(Jo(t[0])),payload:JSON.parse(Jo(t[1])),signature:Qo(t[2]),raw:{header:t[0],payload:t[1]}}}async function ms(e){return await new Promise(t=>{setTimeout(()=>t(null),e)})}function hs(e,t){return new Promise((n,r)=>{(async()=>{for(let i=0;i<1/0;i++)try{let r=await e(i);if(!t(i,null,r)){n(r);return}}catch(e){if(!t(i,e)){r(e);return}}})()})}function gs(e){return(`0`+e.toString(16)).substr(-2)}function _s(){let e=new Uint32Array(56);if(typeof crypto>`u`){let e=``;for(let t=0;t<56;t++)e+=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-._~`.charAt(Math.floor(Math.random()*66));return e}return crypto.getRandomValues(e),Array.from(e,gs).join(``)}async function vs(e){let t=new TextEncoder().encode(e),n=await crypto.subtle.digest(`SHA-256`,t),r=new Uint8Array(n);return Array.from(r).map(e=>String.fromCharCode(e)).join(``)}async function ys(e){if(!(typeof crypto<`u`&&crypto.subtle!==void 0&&typeof TextEncoder<`u`))return console.warn(`WebCrypto API is not supported. Code challenge method will default to use plain instead of sha256.`),e;let t=await vs(e);return btoa(t).replace(/\+/g,`-`).replace(/\//g,`_`).replace(/=+$/,``)}async function bs(e,t,n=!1){let r=_s(),i=r;n&&(i+=`/recovery`),await ls(e,`${t}-code-verifier`,i);let a=await ys(r);return[a,r===a?`plain`:`s256`]}var xs=/^2[0-9]{3}-(0[1-9]|1[0-2])-(0[1-9]|1[0-9]|2[0-9]|3[0-1])$/i;function Ss(e){let t=e.headers.get(xo);if(!t||!t.match(xs))return null;try{return new Date(`${t}T00:00:00.0Z`)}catch{return null}}function Cs(e){if(!e)throw Error(`Missing exp claim`);if(e<=Math.floor(Date.now()/1e3))throw Error(`JWT has expired`)}function ws(e){switch(e){case`RS256`:return{name:`RSASSA-PKCS1-v1_5`,hash:{name:`SHA-256`}};case`ES256`:return{name:`ECDSA`,namedCurve:`P-256`,hash:{name:`SHA-256`}};default:throw Error(`Invalid alg claim`)}}var Ts=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/;function Es(e){if(!Ts.test(e))throw Error(`@supabase/auth-js: Expected parameter to be UUID but is not`)}function Ds(e){if(!e.passkey)throw Error("@supabase/auth-js: the passkey API is experimental and disabled by default. Enable it by passing `auth: { experimental: { passkey: true } }` to createClient (or to the GoTrueClient constructor).")}function Os(){return new Proxy({},{get:(e,t)=>{if(t===`__isUserNotAvailableProxy`)return!0;
32if(typeof t==`symbol`){let e=t.toString();if(e===`Symbol(Symbol.toPrimitive)`||e===`Symbol(Symbol.toStringTag)`||e===`Symbol(util.inspect.custom)`)return}throw Error(`@supabase/auth-js: client was created with userStorage option and there was no user stored in the user storage. Accessing the "${t}" property of the session object is not supported. Please use getUser() instead.`)},set:(e,t)=>{throw Error(`@supabase/auth-js: client was created with userStorage option and there was no user stored in the user storage. Setting the "${t}" property of the session object is not supported. Please use getUser() to fetch a user object you can manipulate.`)},deleteProperty:(e,t)=>{throw Error(`@supabase/auth-js: client was created with userStorage option and there was no user stored in the user storage. Deleting the "${t}" property of the session object is not supported. Please use getUser() to fetch a user object you can manipulate.`)}})}function ks(e,t){return new Proxy(e,{get:(e,n,r)=>{if(n===`__isInsecureUserWarningProxy`)return!0;if(typeof n==`symbol`){let t=n.toString();if(t===`Symbol(Symbol.toPrimitive)`||t===`Symbol(Symbol.toStringTag)`||t===`Symbol(util.inspect.custom)`||t===`Symbol(nodejs.util.inspect.custom)`)return Reflect.get(e,n,r)}return!t.value&&typeof n==`string`&&(console.warn(`Using the user object as returned from supabase.auth.getSession() or from some supabase.auth.onAuthStateChange() events could be insecure! This value comes directly from the storage medium (usually cookies on the server) and may not be authentic. Use supabase.auth.getUser() instead which authenticates the data by contacting the Supabase Auth server.`),t.value=!0),Reflect.get(e,n,r)}})}function As(e){return JSON.parse(JSON.stringify(e))}var js=e=>{if(typeof e==`object`&&e){let t=e;if(typeof t.msg==`string`)return t.msg;if(typeof t.message==`string`)return t.message;if(typeof t.error_description==`string`)return t.error_description;if(typeof t.error==`string`)return t.error}return JSON.stringify(e)},Ms=[500,501,502,503,504,520,521,522,523,524,525,526,527,528,529,530];async function Ns(e){if(!cs(e))throw new Lo(js(e),0);if(Ms.includes(e.status))throw new Lo(js(e),e.status);let t;try{t=await e.json()}catch(e){throw new Do(js(e),e)}let n,r=Ss(e);if(r&&r.getTime()>=So[`2024-01-01`].timestamp&&typeof t==`object`&&t&&typeof t.code==`string`?n=t.code:typeof t==`object`&&t&&typeof t.error_code==`string`&&(n=t.error_code),!n){if(typeof t==`object`&&t&&typeof t.weak_password==`object`&&t.weak_password&&Array.isArray(t.weak_password.reasons)&&t.weak_password.reasons.length&&t.weak_password.reasons.reduce((e,t)=>e&&typeof t==`string`,!0))throw new Vo(js(t),e.status,t.weak_password.reasons)}else if(n===`weak_password`)throw new Vo(js(t),e.status,t.weak_password?.reasons||[]);else if(n===`session_not_found`)throw new ko;throw new To(js(t),e.status||500,n)}var Ps=(e,t,n,r)=>{let i={method:e,headers:t?.headers||{}};return e===`GET`?i:(i.headers=Object.assign({"Content-Type":`application/json;charset=UTF-8`},t?.headers),i.body=JSON.stringify(r),Object.assign(Object.assign({},i),n))};async function I(e,t,n,r){let i=Object.assign({},r?.headers);i[`X-Supabase-Api-Version`]||(i[xo]=So[`2024-01-01`].name),r?.jwt&&(i.Authorization=`Bearer ${r.jwt}`);let a=r?.query??{};r?.redirectTo&&(a.redirect_to=r.redirectTo);let o=await Fs(e,t,n+(Object.keys(a).length?`?`+new URLSearchParams(a).toString():``),{headers:i,noResolveJson:r?.noResolveJson},{},r?.body);return r?.xform?r?.xform(o):{data:Object.assign({},o),error:null}}async function Fs(e,t,n,r,i,a){let o=Ps(t,r,i,a),s;try{s=await e(n,Object.assign({},o))}catch(e){throw console.error(e),new Lo(js(e),0)}if(s.ok||await Ns(s),r?.noResolveJson)return s;try{return await s.json()}catch(e){await Ns(e)}}function Is(e){let t=null;Hs(e)&&(t=Object.assign({},e),e.expires_at||(t.expires_at=ts(e.expires_in)));let n=e.user??(typeof e?.id==`string`?e:null);return{data:{session:t,user:n},error:null}}function Ls(e){let t=Is(e);return!t.error&&e.weak_password&&typeof e.weak_password==`object`&&Array.isArray(e.weak_password.reasons)&&e.weak_password.reasons.length&&e.weak_password.message&&typeof e.weak_password.message==`string`&&e.weak_password.reasons.reduce((e,t)=>
32e&&typeof t==`string`,!0)&&(t.data.weak_password=e.weak_password),t}function Rs(e){return{data:{user:e.user??e},error:null}}function zs(e){return{data:e,error:null}}function Bs(e){let{action_link:t,email_otp:n,hashed_token:r,redirect_to:i,verification_type:a}=e,o=Or(e,[`action_link`,`email_otp`,`hashed_token`,`redirect_to`,`verification_type`]);return{data:{properties:{action_link:t,email_otp:n,hashed_token:r,redirect_to:i,verification_type:a},user:Object.assign({},o)},error:null}}function Vs(e){return e}function Hs(e){return!!e.access_token&&!!e.refresh_token&&!!e.expires_in}var Us=[`global`,`local`,`others`],Ws=class{constructor({url:e=``,headers:t={},fetch:n,experimental:r}){this.url=e,this.headers=t,this.fetch=ss(n),this.experimental=r??{},this.mfa={listFactors:this._listFactors.bind(this),deleteFactor:this._deleteFactor.bind(this)},this.oauth={listClients:this._listOAuthClients.bind(this),createClient:this._createOAuthClient.bind(this),getClient:this._getOAuthClient.bind(this),updateClient:this._updateOAuthClient.bind(this),deleteClient:this._deleteOAuthClient.bind(this),regenerateClientSecret:this._regenerateOAuthClientSecret.bind(this)},this.customProviders={listProviders:this._listCustomProviders.bind(this),createProvider:this._createCustomProvider.bind(this),getProvider:this._getCustomProvider.bind(this),updateProvider:this._updateCustomProvider.bind(this),deleteProvider:this._deleteCustomProvider.bind(this)},this.passkey={listPasskeys:this._adminListPasskeys.bind(this),deletePasskey:this._adminDeletePasskey.bind(this)}}async signOut(e,t=Us[0]){if(Us.indexOf(t)<0)throw Error(`@supabase/auth-js: Parameter scope must be one of ${Us.join(`, `)}`);try{return await I(this.fetch,`POST`,`${this.url}/logout?scope=${t}`,{headers:this.headers,jwt:e,noResolveJson:!0}),{data:null,error:null}}catch(e){if(F(e))return{data:null,error:e};throw e}}async inviteUserByEmail(e,t={}){try{return await I(this.fetch,`POST`,`${this.url}/invite`,{body:{email:e,data:t.data},headers:this.headers,redirectTo:t.redirectTo,xform:Rs})}catch(e){if(F(e))return{data:{user:null},error:e};throw e}}async generateLink(e){try{let{options:t}=e,n=Or(e,[`options`]),r=Object.assign(Object.assign({},n),t);return`newEmail`in n&&(r.new_email=n?.newEmail,delete r.newEmail),await I(this.fetch,`POST`,`${this.url}/admin/generate_link`,{body:r,headers:this.headers,xform:Bs,redirectTo:t?.redirectTo})}catch(e){if(F(e))return{data:{properties:null,user:null},error:e};throw e}}async createUser(e){try{return await I(this.fetch,`POST`,`${this.url}/admin/users`,{body:e,headers:this.headers,xform:Rs})}catch(e){if(F(e))return{data:{user:null},error:e};throw e}}async listUsers(e){try{let t={nextPage:null,lastPage:0,total:0},n=await I(this.fetch,`GET`,`${this.url}/admin/users`,{headers:this.headers,noResolveJson:!0,query:{page:(e?.page)?.toString()??``,per_page:(e?.perPage)?.toString()??``},xform:Vs});if(n.error)throw n.error;let r=await n.json(),i=n.headers.get(`x-total-count`)??0,a=n.headers.get(`link`)?.split(`,`)??[];return a.length>0&&(a.forEach(e=>{let n=parseInt(e.split(`;`)[0].split(`=`)[1].substring(0,1)),r=JSON.parse(e.split(`;`)[1].split(`=`)[1]);t[`${r}Page`]=n}),t.total=parseInt(i)),{data:Object.assign(Object.assign({},r),t),error:null}}catch(e){if(F(e))return{data:{users:[]},error:e};throw e}}async getUserById(e){Es(e);try{return await I(this.fetch,`GET`,`${this.url}/admin/users/${e}`,{headers:this.headers,xform:Rs})}catch(e){if(F(e))return{data:{user:null},error:e};throw e}}async updateUserById(e,t){Es(e);try{return await I(this.fetch,`PUT`,`${this.url}/admin/users/${e}`,{body:t,headers:this.headers,xform:Rs})}catch(e){if(F(e))return{data:{user:null},error:e};throw e}}async deleteUser(e,t=!1){Es(e);try{return await I(this.fetch,`DELETE`,`${this.url}/admin/users/${e}`,{headers:this.headers,body:{should_soft_delete:t},xform:Rs})}catch(e){if(F(e))return{data:{user:null},error:e};throw e}}async _listFactors(e){Es(e.userId);try{let{data:t,error:n}=await I(this.fetch,`GET`,`${this.url}/admin/users/${e.userId}/factors`,{headers:this.headers,xform:e=>({data:{factors:e},error:null})});return{data:t,error:n}}catch(e){if(F(e))return{data:null,error:e};throw e}}async _deleteFactor(e){Es(e.userId),Es(e.id);try{return{data:await I(this.fetch,`DELETE`,`${this.url}/admin/users/${e.userId}/factors/${e.id}`,{headers:this.headers}),error:null}}catch(e){if(F(e))return{data:null,error:e};throw e}}async _listOAuthClients(e){try{let t={nextPage:null,lastPage:0,total:0},n=await I(this.fetch,`GET`,`${this.url}/admin/oauth/clients`,{headers:this.headers,noResolveJson:!0,query:{page:(e?.page)?.toString()??``,per_page:(e?.perPage)?.toString()??``},xform:Vs});if(n.error)throw n.error;let r=await n.json(),i=n.headers.get(`x-total-count`)??0,a=n.headers.get(`link`)?.split(`,`)??[];return a.length>
320&&(a.forEach(e=>{let n=parseInt(e.split(`;`)[0].split(`=`)[1].substring(0,1)),r=JSON.parse(e.split(`;`)[1].split(`=`)[1]);t[`${r}Page`]=n}),t.total=parseInt(i)),{data:Object.assign(Object.assign({},r),t),error:null}}catch(e){if(F(e))return{data:{clients:[]},error:e};throw e}}async _createOAuthClient(e){try{return await I(this.fetch,`POST`,`${this.url}/admin/oauth/clients`,{body:e,headers:this.headers,xform:e=>({data:e,error:null})})}catch(e){if(F(e))return{data:null,error:e};throw e}}async _getOAuthClient(e){try{return await I(this.fetch,`GET`,`${this.url}/admin/oauth/clients/${e}`,{headers:this.headers,xform:e=>({data:e,error:null})})}catch(e){if(F(e))return{data:null,error:e};throw e}}async _updateOAuthClient(e,t){try{return await I(this.fetch,`PUT`,`${this.url}/admin/oauth/clients/${e}`,{body:t,headers:this.headers,xform:e=>({data:e,error:null})})}catch(e){if(F(e))return{data:null,error:e};throw e}}async _deleteOAuthClient(e){try{return await I(this.fetch,`DELETE`,`${this.url}/admin/oauth/clients/${e}`,{headers:this.headers,noResolveJson:!0}),{data:null,error:null}}catch(e){if(F(e))return{data:null,error:e};throw e}}async _regenerateOAuthClientSecret(e){try{return await I(this.fetch,`POST`,`${this.url}/admin/oauth/clients/${e}/regenerate_secret`,{headers:this.headers,xform:e=>({data:e,error:null})})}catch(e){if(F(e))return{data:null,error:e};throw e}}async _listCustomProviders(e){try{let t={};return e?.type&&(t.type=e.type),await I(this.fetch,`GET`,`${this.url}/admin/custom-providers`,{headers:this.headers,query:t,xform:e=>({data:{providers:e?.providers??[]},error:null})})}catch(e){if(F(e))return{data:{providers:[]},error:e};throw e}}async _createCustomProvider(e){try{return await I(this.fetch,`POST`,`${this.url}/admin/custom-providers`,{body:e,headers:this.headers,xform:e=>({data:e,error:null})})}catch(e){if(F(e))return{data:null,error:e};throw e}}async _getCustomProvider(e){try{return await I(this.fetch,`GET`,`${this.url}/admin/custom-providers/${e}`,{headers:this.headers,xform:e=>({data:e,error:null})})}catch(e){if(F(e))return{data:null,error:e};throw e}}async _updateCustomProvider(e,t){try{return await I(this.fetch,`PUT`,`${this.url}/admin/custom-providers/${e}`,{body:t,headers:this.headers,xform:e=>({data:e,error:null})})}catch(e){if(F(e))return{data:null,error:e};throw e}}async _deleteCustomProvider(e){try{return await I(this.fetch,`DELETE`,`${this.url}/admin/custom-providers/${e}`,{headers:this.headers,noResolveJson:!0}),{data:null,error:null}}catch(e){if(F(e))return{data:null,error:e};throw e}}async _adminListPasskeys(e){Ds(this.experimental),Es(e.userId);try{return await I(this.fetch,`GET`,`${this.url}/admin/users/${e.userId}/passkeys`,{headers:this.headers,xform:e=>({data:e,error:null})})}catch(e){if(F(e))return{data:null,error:e};throw e}}async _adminDeletePasskey(e){Ds(this.experimental),Es(e.userId),Es(e.passkeyId);try{return await I(this.fetch,`DELETE`,`${this.url}/admin/users/${e.userId}/passkeys/${e.passkeyId}`,{headers:this.headers,noResolveJson:!0}),{data:null,error:null}}catch(e){if(F(e))return{data:null,error:e};throw e}}};function Gs(e={}){return{getItem:t=>e[t]||null,setItem:(t,n)=>{e[t]=n},removeItem:t=>{delete e[t]}}}globalThis&&as()&&globalThis.localStorage&&globalThis.localStorage.getItem(`supabase.gotrue-js.locks.debug`);var Ks=class extends Error{constructor(e){super(e),this.isAcquireTimeout=!0}};function qs(){if(typeof globalThis!=`object`)try{Object.defineProperty(Object.prototype,"__magic__",{get:function(){return this},configurable:!0}),__magic__.globalThis=__magic__,delete Object.prototype.__magic__}catch{typeof self<`u`&&(self.globalThis=self)}}function Js(e){if(!/^0x[a-fA-F0-9]{40}$/.test(e))throw Error(`@supabase/auth-js: Address "${e}" is invalid.`);return e.toLowerCase()}function Ys(e){return parseInt(e,16)}function Xs(e){let t=new TextEncoder().encode(e);return`0x`+Array.from(t,e=>e.toString(16).padStart(2,`0`)).join(``)}function Zs(e){let{chainId:t,domain:n,expirationTime:r,issuedAt:i=new Date,nonce:a,notBefore:o,requestId:s,resources:c,scheme:l,uri:u,version:d}=e;if(!Number.isInteger(t))throw Error(`@supabase/auth-js: Invalid SIWE message field "chainId". Chain ID must be a EIP-155 chain ID. Provided value: ${t}`);if(!n)throw Error(`@supabase/auth-js: Invalid SIWE message field "domain". Domain must be provided.`);if(a&&a.length<8)throw Error(`@supabase/auth-js: Invalid SIWE message field "nonce". Nonce must be at least 8 characters. Provided value: ${a}`);if(!u)throw Error(`@supabase/auth-js: Invalid SIWE message field "uri". URI must be provided.`);if(d!==`1`)throw Error(`@supabase/auth-js: Invalid SIWE message field "version". Version must be '1'. Provided value: ${d}`);if(e.statement?.includes(` 33`))throw Error(`@supabase/auth-js: Invalid SIWE message field "statement". Statement must not include '\\n'. Provided value: ${e.statement}`);let f=Js(e.address),p=`${l?`${l}://${n}`:n} wants you to sign in with your Ethereum account:\n${f}\n\n${e.statement?`${e.statement}\n`:``}`,m=`URI: ${u}\nVersion: ${d}\nChain ID: ${t}${a?`\nNonce: ${a}`:``}\nIssued At: ${i.toISOString()}`;if(r&&(m+=`\nExpiration Time: ${r.toISOString()}`),o&&(m+=`\nNot Before: ${o.toISOString()}`),s&&(m+=`\nRequest ID: ${s}`),c){let e=` 34Resources:`;for(let t of c){if(!t||typeof t!=`string`)throw Error(`@supabase/auth-js: Invalid SIWE message field "resources". Every resource must be a valid string. Provided value: ${t}`);e+=`\n- ${t}`}m+=e}return`${p}\n${m}`}
34var Qs=class extends Error{constructor({message:e,code:t,cause:n,name:r}){super(e,{cause:n}),this.__isWebAuthnError=!0,this.name=r??(n instanceof Error?n.name:void 0)??`Unknown Error`,this.code=t}toJSON(){return{name:this.name,message:this.message,code:this.code}}},$s=class extends Qs{constructor(e,t){super({code:`ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY`,cause:t,message:e}),this.name=`WebAuthnUnknownError`,this.originalError=t}};function ec({error:e,options:t}){let{publicKey:n}=t;if(!n)throw Error(`options was missing required publicKey property`);if(e.name===`AbortError`){if(t.signal instanceof AbortSignal)return new Qs({message:`Registration ceremony was sent an abort signal`,code:`ERROR_CEREMONY_ABORTED`,cause:e})}else if(e.name===`ConstraintError`){if(n.authenticatorSelection?.requireResidentKey===!0)return new Qs({message:`Discoverable credentials were required but no available authenticator supported it`,code:`ERROR_AUTHENTICATOR_MISSING_DISCOVERABLE_CREDENTIAL_SUPPORT`,cause:e});if(t.mediation===`conditional`&&n.authenticatorSelection?.userVerification===`required`)return new Qs({message:`User verification was required during automatic registration but it could not be performed`,code:`ERROR_AUTO_REGISTER_USER_VERIFICATION_FAILURE`,cause:e});if(n.authenticatorSelection?.userVerification===`required`)return new Qs({message:`User verification was required but no available authenticator supported it`,code:`ERROR_AUTHENTICATOR_MISSING_USER_VERIFICATION_SUPPORT`,cause:e})}else if(e.name===`InvalidStateError`)return new Qs({message:`The authenticator was previously registered`,code:`ERROR_AUTHENTICATOR_PREVIOUSLY_REGISTERED`,cause:e});else if(e.name===`NotAllowedError`)return new Qs({message:e.message,code:`ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY`,cause:e});else if(e.name===`NotSupportedError`)return n.pubKeyCredParams.filter(e=>e.type===`public-key`).length===0?new Qs({message:`No entry in pubKeyCredParams was of type "public-key"`,code:`ERROR_MALFORMED_PUBKEYCREDPARAMS`,cause:e}):new Qs({message:`No available authenticator supported any of the specified pubKeyCredParams algorithms`,code:`ERROR_AUTHENTICATOR_NO_SUPPORTED_PUBKEYCREDPARAMS_ALG`,cause:e});else if(e.name===`SecurityError`){let t=window.location.hostname;if(!sc(t))return new Qs({message:`${window.location.hostname} is an invalid domain`,code:`ERROR_INVALID_DOMAIN`,cause:e});if(n.rp.id!==t)return new Qs({message:`The RP ID "${n.rp.id}" is invalid for this domain`,code:`ERROR_INVALID_RP_ID`,cause:e})}else if(e.name===`TypeError`){if(n.user.id.byteLength<1||n.user.id.byteLength>64)return new Qs({message:`User ID was not between 1 and 64 characters`,code:`ERROR_INVALID_USER_ID_LENGTH`,cause:e})}else if(e.name===`UnknownError`)return new Qs({message:`The authenticator was unable to process the specified options, or could not create a new credential`,code:`ERROR_AUTHENTICATOR_GENERAL_ERROR`,cause:e});return new Qs({message:`a Non-Webauthn related error has occurred`,code:`ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY`,cause:e})}function tc({error:e,options:t}){let{publicKey:n}=t;if(!n)throw Error(`options was missing required publicKey property`);if(e.name===`AbortError`){if(t.signal instanceof AbortSignal)return new Qs({message:`Authentication ceremony was sent an abort signal`,code:`ERROR_CEREMONY_ABORTED`,cause:e})}else if(e.name===`NotAllowedError`)return new Qs({message:e.message,code:`ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY`,cause:e});else if(e.name===`SecurityError`){let t=window.location.hostname;if(!sc(t))return new Qs({message:`${window.location.hostname} is an invalid domain`,code:`ERROR_INVALID_DOMAIN`,cause:e});if(n.rpId!==t)return new Qs({message:`The RP ID "${n.rpId}" is invalid for this domain`,code:`ERROR_INVALID_RP_ID`,cause:e})}else if(e.name===`UnknownError`)return new Qs({message:`The authenticator was unable to process the specified options, or could not create a new assertion signature`,code:`ERROR_AUTHENTICATOR_GENERAL_ERROR`,cause:e});return new Qs({message:`a Non-Webauthn related error has occurred`,code:`ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY`,cause:e})}var nc=new class{createNewAbortSignal(){if(this.controller){let e=Error(`Cancelling existing WebAuthn API call for new one`);e.name=`AbortError`,this.controller.abort(e)}let e=new AbortController;return this.controller=e,e.signal}cancelCeremony(){if(this.controller){let e=Error(`Manually cancelling existing WebAuthn API call`);e.name=`AbortError`,this.controller.abort(e),this.controller=void 0}}};function rc(e){if(!e)throw Error(`Credential creation options are required`);if(typeof PublicKeyCredential<`u`&&`parseCreationOptionsFromJSON`in PublicKeyCredential&&typeof PublicKeyCredential.parseCreationOptionsFromJSON==`function`)return PublicKeyCredential.parseCreationOptionsFromJSON(e);let{challenge:t,user:n,excludeCredentials:r}=e,i=Or(e,[`challenge`,`user`,`excludeCredentials`]),a=Qo(t).buffer,o=Object.assign(Object.assign({}
34,n),{id:Qo(n.id).buffer}),s=Object.assign(Object.assign({},i),{challenge:a,user:o});if(r&&r.length>0){s.excludeCredentials=Array(r.length);for(let e=0;e<r.length;e++){let t=r[e];s.excludeCredentials[e]=Object.assign(Object.assign({},t),{id:Qo(t.id).buffer,type:t.type||`public-key`,transports:t.transports})}}return s}function ic(e){if(!e)throw Error(`Credential request options are required`);if(typeof PublicKeyCredential<`u`&&`parseRequestOptionsFromJSON`in PublicKeyCredential&&typeof PublicKeyCredential.parseRequestOptionsFromJSON==`function`)return PublicKeyCredential.parseRequestOptionsFromJSON(e);let{challenge:t,allowCredentials:n}=e,r=Or(e,[`challenge`,`allowCredentials`]),i=Qo(t).buffer,a=Object.assign(Object.assign({},r),{challenge:i});if(n&&n.length>0){a.allowCredentials=Array(n.length);for(let e=0;e<n.length;e++){let t=n[e];a.allowCredentials[e]=Object.assign(Object.assign({},t),{id:Qo(t.id).buffer,type:t.type||`public-key`,transports:t.transports})}}return a}function ac(e){if(`toJSON`in e&&typeof e.toJSON==`function`)return e.toJSON();let t=e;return{id:e.id,rawId:e.id,response:{attestationObject:es(new Uint8Array(e.response.attestationObject)),clientDataJSON:es(new Uint8Array(e.response.clientDataJSON))},type:`public-key`,clientExtensionResults:e.getClientExtensionResults(),authenticatorAttachment:t.authenticatorAttachment??void 0}}function oc(e){if(`toJSON`in e&&typeof e.toJSON==`function`)return e.toJSON();let t=e,n=e.getClientExtensionResults(),r=e.response;return{id:e.id,rawId:e.id,response:{authenticatorData:es(new Uint8Array(r.authenticatorData)),clientDataJSON:es(new Uint8Array(r.clientDataJSON)),signature:es(new Uint8Array(r.signature)),userHandle:r.userHandle?es(new Uint8Array(r.userHandle)):void 0},type:`public-key`,clientExtensionResults:n,authenticatorAttachment:t.authenticatorAttachment??void 0}}function sc(e){return e===`localhost`||/^([a-z0-9]+(-[a-z0-9]+)*\.)+[a-z]{2,}$/i.test(e)}function cc(){return!!(rs()&&`PublicKeyCredential`in window&&window.PublicKeyCredential&&`credentials`in navigator&&typeof(navigator==null?void 0:navigator.credentials)?.create==`function`&&typeof(navigator==null?void 0:navigator.credentials)?.get==`function`)}async function lc(e){try{let t=await navigator.credentials.create(e);return t?t instanceof PublicKeyCredential?{data:t,error:null}:{data:null,error:new $s(`Browser returned unexpected credential type`,t)}:{data:null,error:new $s(`Empty credential response`,t)}}catch(t){return{data:null,error:ec({error:t,options:e})}}}async function uc(e){try{let t=await navigator.credentials.get(e);return t?t instanceof PublicKeyCredential?{data:t,error:null}:{data:null,error:new $s(`Browser returned unexpected credential type`,t)}:{data:null,error:new $s(`Empty credential response`,t)}}catch(t){return{data:null,error:tc({error:t,options:e})}}}var dc={hints:[`security-key`],authenticatorSelection:{authenticatorAttachment:`cross-platform`,requireResidentKey:!1,userVerification:`preferred`,residentKey:`discouraged`},attestation:`direct`},fc={userVerification:`preferred`,hints:[`security-key`],attestation:`direct`};function pc(...e){let t=e=>typeof e==`object`&&!!e&&!Array.isArray(e),n=e=>e instanceof ArrayBuffer||ArrayBuffer.isView(e),r={};for(let i of e)if(i)for(let e in i){let a=i[e];if(a!==void 0)if(Array.isArray(a))r[e]=a;else if(n(a))r[e]=a;else if(t(a)){let n=r[e];t(n)?r[e]=pc(n,a):r[e]=pc(a)}else r[e]=a}return r}function mc(e,t){return pc(dc,e,t||{})}function hc(e,t){return pc(fc,e,t||{})}var gc=class{constructor(e){this.client=e,this.enroll=this._enroll.bind(this),this.challenge=this._challenge.bind(this),this.verify=this._verify.bind(this),this.authenticate=this._authenticate.bind(this),this.register=this._register.bind(this)}async _enroll(e){return this.client.mfa.enroll(Object.assign(Object.assign({},e),{factorType:`webauthn`}))}async _challenge({factorId:e,webauthn:t,friendlyName:n,signal:r},i){try{let{data:a,error:o}=await this.client.mfa.challenge({factorId:e,webauthn:t});if(!a)return{data:null,error:o};let s=r??nc.createNewAbortSignal();if(a.webauthn.type===`create`){let{user:e}=a.webauthn.credential_options.publicKey;if(!e.name){let t=n;if(t)e.name=`${e.id}:${t}`;else{let t=(await this.client.getUser()).data.user,n=t?.user_metadata?.name||t?.email||t?.id||`User`;e.name=`${e.id}:${n}`}}e.displayName||=e.name}switch(a.webauthn.type){case`create`:{let{data:t,error:n}=await lc({publicKey:mc(a.webauthn.credential_options.publicKey,i?.create),signal:s});return t?{data:{factorId:e,challengeId:a.id,webauthn:{type:a.webauthn.type,credential_response:t}},error:null}:{data:null,error:n}}case`request`:{let t=hc(a.webauthn.credential_options.publicKey,i?.request),{data:n,error:r}=await uc(Object.assign(Object.assign({},a.webauthn.credential_options),{publicKey:t,signal:s}));return n?{data:{factorId:e,challengeId:a.id,webauthn:{type:a.webauthn.type,credential_response:n}},error:null}:{data:null,error:r}}}}catch(e){return F(e)?{data:null,error:e}:{data:null,error:new Do(`Unexpected error in challenge`,e)}}}async _verify({challengeId:e,factorId:t,webauthn:n}){return this.client.mfa.verify({factorId:t,challengeId:e,webauthn:n})}async _authenticate({factorId:e,webauthn:{rpId:t=typeof window<`u`?window.location.hostname:void 0,rpOrigins:n=typeof window<`u`?[window.location.origin]:void 0,signal:r}={}},i){if(!t)return{data:null,error:new wo(`rpId is required for WebAuthn authentication`)};try{if(!cc())return{data:null,error:new Do(`Browser does not support WebAuthn`,null)};let{data:a,error:o}=await this.challenge({factorId:e,webauthn:{rpId:t,rpOrigins:n},signal:r},{request:i});if(!a)return{data:null,error:o};let{webauthn:s}=a;return this._verify({factorId:e,challengeId:a.challengeId,webauthn:{type:s.type,rpId:t,rpOrigins:n,credential_response:s.credential_response}})}catch(e){return F(e)?{data:null,error:e}:{data:null,error:new Do(`Unexpected error in authenticate`,e)}}}async _register({friendlyName:e,webauthn:{rpId:t=typeof window<`u`?window.location.hostname:void 0,rpOrigins:n=typeof window<`u`?[window.location.origin]:void 0,signal:r}={}},i){if(!t)return{data:null,error:new wo(`rpId is required for WebAuthn registration`)};try{if(!cc())return{data:null,error:new Do(`Browser does not support WebAuthn`,null)};let{data:a,error:o}=await this._enroll({friendlyName:e});if(!a)return await this.client.mfa.listFactors().then(t=>t.data?.all.find(t=>t.factor_type===`webauthn`&&t.friendly_name===e&&t.status!==`unverified`)).then(e=>e?this.client.mfa.unenroll({factorId:e?.id}):void 0),{data:null,error:o};let{data:s,error:c}=await this._challenge({factorId:a.id,friendlyName:a.friendly_name,webauthn:{rpId:t,rpOrigins:n},signal:r},{create:i});return s?this._verify({factorId:a.id,challengeId:s.challengeId,webauthn:{rpId:t,rpOrigins:n,type:s.webauthn.type,credential_response:s.webauthn.credential_response}}):{data:null,error:c}}catch(e){return F(e)?{data:null,error:e}:{data:null,error:new Do(`Unexpected error in register`,e)}}}};qs();var _c={url:vo,storageKey:yo,autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,headers:bo,flowType:`implicit`,debug:!1,hasCustomAuthorizationHeader:!1,throwOnError:!1,lockAcquireTimeout:5e3,skipAutoInitialize:!1,experimental:{}},vc={}
34,yc=class e{get jwks(){return vc[this.storageKey]?.jwks??{keys:[]}}set jwks(e){vc[this.storageKey]=Object.assign(Object.assign({},vc[this.storageKey]),{jwks:e})}get jwks_cached_at(){return vc[this.storageKey]?.cachedAt??-(2**53-1)}set jwks_cached_at(e){vc[this.storageKey]=Object.assign(Object.assign({},vc[this.storageKey]),{cachedAt:e})}constructor(t){var n;this.userStorage=null,this.memoryStorage=null,this.stateChangeEmitters=new Map,this.autoRefreshTicker=null,this.autoRefreshTickTimeout=null,this.visibilityChangedCallback=null,this.refreshingDeferred=null,this.lastRefreshFailure=null,this._sessionRemovalEpoch=0,this.initializePromise=null,this.detectSessionInUrl=!0,this.hasCustomAuthorizationHeader=!1,this.suppressGetSessionWarning=!1,this.lock=null,this.lockAcquired=!1,this.pendingInLock=[],this.broadcastChannel=null,this.logger=console.log;let r=Object.assign(Object.assign({},_c),t);if(this.storageKey=r.storageKey,this.instanceID=e.nextInstanceID[this.storageKey]??0,e.nextInstanceID[this.storageKey]=this.instanceID+1,this.logDebugMessages=!!r.debug,typeof r.debug==`function`&&(this.logger=r.debug),this.instanceID>0&&rs()){let e=`${this._logPrefix()} Multiple GoTrueClient instances detected in the same browser context. It is not an error, but this should be avoided as it may produce undefined behavior when used concurrently under the same storage key.`;console.warn(e),this.logDebugMessages&&console.trace(e)}if(this.persistSession=r.persistSession,this.autoRefreshToken=r.autoRefreshToken,this.experimental=r.experimental??{},this.admin=new Ws({url:r.url,headers:r.headers,fetch:r.fetch,experimental:this.experimental}),this.url=r.url,this.headers=r.headers,this.fetch=ss(r.fetch),this.detectSessionInUrl=r.detectSessionInUrl,this.flowType=r.flowType,this.hasCustomAuthorizationHeader=r.hasCustomAuthorizationHeader,this.throwOnError=r.throwOnError,this.lockAcquireTimeout=r.lockAcquireTimeout,r.lock!=null&&(this.lock=r.lock),this.jwks||(this.jwks={keys:[]},this.jwks_cached_at=-(2**53-1)),this.mfa={verify:this._verify.bind(this),enroll:this._enroll.bind(this),unenroll:this._unenroll.bind(this),challenge:this._challenge.bind(this),listFactors:this._listFactors.bind(this),challengeAndVerify:this._challengeAndVerify.bind(this),getAuthenticatorAssuranceLevel:this._getAuthenticatorAssuranceLevel.bind(this),webauthn:new gc(this)},this.oauth={getAuthorizationDetails:this._getAuthorizationDetails.bind(this),approveAuthorization:this._approveAuthorization.bind(this),denyAuthorization:this._denyAuthorization.bind(this),listGrants:this._listOAuthGrants.bind(this),revokeGrant:this._revokeOAuthGrant.bind(this)},this.passkey={startRegistration:this._startPasskeyRegistration.bind(this),verifyRegistration:this._verifyPasskeyRegistration.bind(this),startAuthentication:this._startPasskeyAuthentication.bind(this),verifyAuthentication:this._verifyPasskeyAuthentication.bind(this),list:this._listPasskeys.bind(this),update:this._updatePasskey.bind(this),delete:this._deletePasskey.bind(this)},this.persistSession?(r.storage?this.storage=r.storage:as()?this.storage=globalThis.localStorage:(this.memoryStorage={},this.storage=Gs(this.memoryStorage)),r.userStorage&&(this.userStorage=r.userStorage)):(this.memoryStorage={},this.storage=Gs(this.memoryStorage)),rs()&&globalThis.BroadcastChannel&&this.persistSession&&this.storageKey){try{this.broadcastChannel=new globalThis.BroadcastChannel(this.storageKey)}catch(e){console.error(`Failed to create a new BroadcastChannel, multi-tab state changes will not be available`,e)}(n=this.broadcastChannel)==null||n.addEventListener(`message`,async e=>{this._debug(`received broadcast notification from other tab or client`,e),(e.data.event===`TOKEN_REFRESHED`||e.data.event===`SIGNED_IN`)&&(this.lastRefreshFailure=null);try{await this._notifyAllSubscribers(e.data.event,e.data.session,!1)}catch(e){this._debug(`#broadcastChannel`,`error`,e)}})}r.skipAutoInitialize||this.initialize().catch(e=>{this._debug(`#initialize()`,`error`,e)})}isThrowOnErrorEnabled(){return this.throwOnError}_returnResult(e){if(this.throwOnError&&e&&e.error)throw e.error;return e}_logPrefix(){return`GoTrueClient@${this.storageKey}:${this.instanceID} (${mo}) ${new Date().toISOString()}`}_debug(...e){return this.logDebugMessages&&this.logger(this._logPrefix(),...e),this}async initialize(){return this.initializePromise||=(async()=>this.lock==null?await this._initialize():await this._acquireLock(this.lockAcquireTimeout,async()=>await this._initialize()))(),await this.initializePromise}async _initialize(){try{let e={},t=`none`;if(rs()&&(e=os(window.location.href),this._isImplicitGrantCallback(e)?t=`implicit`:await this._isPKCECallback(e)&&(t=`pkce`)),rs()&&this.detectSessionInUrl&&t!==`none`){let{data:n,error:r}=await this._getSessionFromURL(e,t);if(r){if(this._debug(`#_initialize()`,`error detecting session from URL`,r),Po(r)){let e=r.details?.code;if(e===`identity_already_exists`||e===`identity_not_found`||e===`single_identity_not_deletable`)return{error:r}}return{error:r}}let{session:i,redirectType:a}=n;return this._debug(`#_initialize()`,`detected session in URL`,i,`redirect type`,a),await this._saveSession(i),setTimeout(async()=>{a===`recovery`?await this._notifyAllSubscribers(`PASSWORD_RECOVERY`,i):await this._notifyAllSubscribers(`SIGNED_IN`,i)},0),{error:null}}return await this._recoverAndRefresh(),{error:null}}catch(e){return F(e)?this._returnResult({error:e}):this._returnResult({error:new Do(`Unexpected error during initialization`,e)})}finally{await this._handleVisibilityChange(),this._debug(`#_initialize()`,`end`)}}async signInAnonymously(e){try{let{data:t,error:n}=await I(this.fetch,`POST`,`${this.url}/signup`,{headers:this.headers,body:{data:e?.options?.data??{},gotrue_meta_security:{captcha_token:e?.options?.captchaToken}},xform:Is});if(n||!t)return this._returnResult({data:{user:null,session:null},error:n});let r=t.session,i=t.user;return t.session&&(await this._saveSession(t.session),await this._notifyAllSubscribers(`SIGNED_IN`,r)),this._returnResult({data:{user:i,session:r},error:null})}catch(e){if(F(e))return this._returnResult({data:{user:null,session:null},error:e});throw e}}async signUp(e){try{let t;if(`email`in e){let{email:n,password:r,options:i}=e,a=null,o=null;this.flowType===`pkce`&&([a,o]=await bs(this.storage,this.storageKey)),t=await I(this.fetch,`POST`,`${this.url}/signup`,{headers:this.headers,redirectTo:i?.emailRedirectTo,body:{email:n,password:r,data:i?.data??{},gotrue_meta_security:{captcha_token:i?.captchaToken},code_challenge:a,code_challenge_method:o},xform:Is})}else if(`phone`in e){let{phone:n,password:r,options:i}=e;t=await I(this.fetch,`POST`,`${this.url}/signup`,{headers:this.headers,body:{phone:n,password:r,data:i?.data??{},channel:i?.channel??`sms`,gotrue_meta_security:{captcha_token:i?.captchaToken}},xform:Is})}else throw new Mo(`You must provide either an email or phone number and a password`);let{data:n,error:r}=t;if(r||!n)return await ds(this.storage,`${this.storageKey}-code-verifier`),this._returnResult({data:{user:null,session:null},error:r});let i=n.session,a=n.user;return n.session&&(await this._saveSession(n.session),await this._notifyAllSubscribers(`SIGNED_IN`,i)),this._returnResult({data:{user:a,session:i},error:null})}catch(e){if(await ds(this.storage,`${this.storageKey}-code-verifier`),F(e))return this._returnResult({data:{user:null,session:null},error:e});throw e}}async signInWithPassword(e){try{let t;if(`email`in e){let{email:n,password:r,options:i}=e;t=await I(this.fetch,`POST`,`${this.url}/token?grant_type=password`,{headers:this.headers,body:{email:n,password:r,gotrue_meta_security:{captcha_token:i?.captchaToken}},xform:Ls})}else if(`phone`in e){let{phone:n,password:r,options:i}=e;t=await I(this.fetch,`POST`,`${this.url}/token?grant_type=password`,{headers:this.headers,body:{phone:n,password:r,gotrue_meta_security:{captcha_token:i?.captchaToken}},xform:Ls})}else throw new Mo(`You must provide either an email or phone number and a password`);let{data:n,error:r}=t;if(r)return this._returnResult({data:{user:null,session:null},error:r});if(!n||!n.session||!n.user){let e=new jo;return this._returnResult({data:{user:null,session:null},error:e})}return n.session&&(await this._saveSession(n.session),await this._notifyAllSubscribers(`SIGNED_IN`,n.session)),this._returnResult({data:Object.assign({user:n.user,session:n.session},n.weak_password?{weakPassword:n.weak_password}:null),error:r})}catch(e){if(F(e))return this._returnResult({data:{user:null,session:null},error:e});throw e}}async signInWithOAuth(e){return await this._handleProviderSignIn(e.provider,{redirectTo:e.options?.redirectTo,scopes:e.options?.scopes,queryParams:e.options?.queryParams,skipBrowserRedirect:e.options?.skipBrowserRedirect})}async exchangeCodeForSession(e){return await this.initializePromise,this.lock==null?this._exchangeCodeForSession(e):this._acquireLock(this.lockAcquireTimeout,async()=>this._exchangeCodeForSession(e))}async signInWithWeb3(e){let{chain:t}=e;switch(t){case`ethereum`:return await this.signInWithEthereum(e);case`solana`:return await this.signInWithSolana(e);default:throw Error(`@supabase/auth-js: Unsupported chain "${t}"`)}}async signInWithEthereum(e){let t,n;if(`message`in e)t=e.message,n=e.signature;else{let{chain:r,wallet:i,statement:a,options:o}=e,s;if(!rs()){if(typeof i!=`object`||!o?.url)throw Error(`@supabase/auth-js: Both wallet and url must be specified in non-browser environments.`);s=i}else if(typeof i==`object`)s=i;else{let e=window;if(`ethereum`in e&&typeof e.ethereum==`object`&&`request`in e.ethereum&&typeof e.ethereum.request==`function`)s=e.ethereum;else throw Error(`@supabase/auth-js: No compatible Ethereum wallet interface on the window object (window.ethereum) detected. Make sure the user already has a wallet installed and connected for this app. Prefer passing the wallet interface object directly to signInWithWeb3({ chain: 'ethereum', wallet: resolvedUserWallet }) instead.`)}let c=new URL(o?.url??window.location.href),l=await s.request({method:`eth_requestAccounts`}).then(e=>e).catch(()=>{throw Error(`@supabase/auth-js: Wallet method eth_requestAccounts is missing or invalid`)});if(!l||l.length===0)throw Error(`@supabase/auth-js: No accounts available. Please ensure the wallet is connected.`);let u=Js(l[0]),d=o?.signInWithEthereum?.chainId;d||=Ys(await s.request({method:`eth_chainId`})),t=Zs({domain:c.host,address:u,statement:a,uri:c.href,version:`1`,chainId:d,nonce:o?.signInWithEthereum?.nonce,issuedAt:o?.signInWithEthereum?.issuedAt??new Date,expirationTime:o?.signInWithEthereum?.expirationTime,notBefore:o?.signInWithEthereum?.notBefore,requestId:o?.signInWithEthereum?.requestId,resources:o?.signInWithEthereum?.resources}),n=await s.request({method:`personal_sign`,params:[Xs(t),u]})}try{let{data:r,error:i}=await I(this.fetch,`POST`,`${this.url}/token?grant_type=web3`,{headers:this.headers,body:Object.assign({chain:`ethereum`,message:t,signature:n},e.options?.captchaToken?{gotrue_meta_security:{captcha_token:e.options?.captchaToken}}:null),xform:Is});if(i)throw i;if(!r||!r.session||!r.user){let e=new jo;return this._returnResult({data:{user:null,session:null},error:e})}return r.session&&(await this._saveSession(r.session),await this._notifyAllSubscribers(`SIGNED_IN`,r.session)),this._returnResult({data:Object.assign({},r),error:i})}catch(e){if(F(e))return this._returnResult({data:{user:null,session:null},error:e});throw e}}async signInWithSolana(e){let t,n;if(`message`in e)t=e.message,n=e.signature;else{let{chain:r,wallet:i,statement:a,options:o}=e,s;if(!rs()){if(typeof i!=`object`||!o?.url)throw Error(`@supabase/auth-js: Both wallet and url must be specified in non-browser environments.`);s=i}else if(typeof i==`object`)s=i;else{let e=window;if(`solana`in e&&typeof e.solana==`object`&&(`signIn`in e.solana&&typeof e.solana.signIn==`function`||`signMessage`in e.
34solana&&typeof e.solana.signMessage==`function`))s=e.solana;else throw Error(`@supabase/auth-js: No compatible Solana wallet interface on the window object (window.solana) detected. Make sure the user already has a wallet installed and connected for this app. Prefer passing the wallet interface object directly to signInWithWeb3({ chain: 'solana', wallet: resolvedUserWallet }) instead.`)}let c=new URL(o?.url??window.location.href);if(`signIn`in s&&s.signIn){let e=await s.signIn(Object.assign(Object.assign(Object.assign({issuedAt:new Date().toISOString()},o?.signInWithSolana),{version:`1`,domain:c.host,uri:c.href}),a?{statement:a}:null)),r;if(Array.isArray(e)&&e[0]&&typeof e[0]==`object`)r=e[0];else if(e&&typeof e==`object`&&`signedMessage`in e&&`signature`in e)r=e;else throw Error(`@supabase/auth-js: Wallet method signIn() returned unrecognized value`);if(`signedMessage`in r&&`signature`in r&&(typeof r.signedMessage==`string`||r.signedMessage instanceof Uint8Array)&&r.signature instanceof Uint8Array)t=typeof r.signedMessage==`string`?r.signedMessage:new TextDecoder().decode(r.signedMessage),n=r.signature;else throw Error(`@supabase/auth-js: Wallet method signIn() API returned object without signedMessage and signature fields`)}else{if(!(`signMessage`in s)||typeof s.signMessage!=`function`||!(`publicKey`in s)||typeof s!=`object`||!s.publicKey||!(`toBase58`in s.publicKey)||typeof s.publicKey.toBase58!=`function`)throw Error(`@supabase/auth-js: Wallet does not have a compatible signMessage() and publicKey.toBase58() API`);t=[`${c.host} wants you to sign in with your Solana account:`,s.publicKey.toBase58(),...a?[``,a,``]:[``],`Version: 1`,`URI: ${c.href}`,`Issued At: ${o?.signInWithSolana?.issuedAt??new Date().toISOString()}`,...o?.signInWithSolana?.notBefore?[`Not Before: ${o.signInWithSolana.notBefore}`]:[],...o?.signInWithSolana?.expirationTime?[`Expiration Time: ${o.signInWithSolana.expirationTime}`]:[],...o?.signInWithSolana?.chainId?[`Chain ID: ${o.signInWithSolana.chainId}`]:[],...o?.signInWithSolana?.nonce?[`Nonce: ${o.signInWithSolana.nonce}`]:[],...o?.signInWithSolana?.requestId?[`Request ID: ${o.signInWithSolana.requestId}`]:[],...o?.signInWithSolana?.resources?.length?[`Resources`,...o.signInWithSolana.resources.map(e=>`- ${e}`)]:[]].join(` 35`);let e=await s.signMessage(new TextEncoder().encode(t),`utf8`);if(!e||!(e instanceof Uint8Array))throw Error(`@supabase/auth-js: Wallet signMessage() API returned an recognized value`);n=e}}try{let{data:r,error:i}=await I(this.fetch,`POST`,`${this.url}/token?grant_type=web3`,{headers:this.headers,body:Object.assign({chain:`solana`,message:t,signature:es(n)},e.options?.captchaToken?{gotrue_meta_security:{captcha_token:e.options?.captchaToken}}:null),xform:Is});if(i)throw i;if(!r||!r.session||!r.user){let e=new jo;return this._returnResult({data:{user:null,session:null},error:e})}return r.session&&(await this._saveSession(r.session),await this._notifyAllSubscribers(`SIGNED_IN`,r.session)),this._returnResult({data:Object.assign({},r),error:i})}catch(e){if(F(e))return this._returnResult({data:{user:null,session:null},error:e});throw e}}async _exchangeCodeForSession(e){let[t,n]=(await us(this.storage,`${this.storageKey}-code-verifier`)??``).split(`/`);try{if(!t&&this.flowType===`pkce`)throw new Io;let{data:r,error:i}=await I(this.fetch,`POST`,`${this.url}/token?grant_type=pkce`,{headers:this.headers,body:{auth_code:e,code_verifier:t},xform:Is});if(await ds(this.storage,`${this.storageKey}-code-verifier`),i)throw i;if(!r||!r.session||!r.user){let e=new jo;return this._returnResult({data:{user:null,session:null,redirectType:null},error:e})}return r.session&&(await this._saveSession(r.session),await this._notifyAllSubscribers(n===`recovery`?`PASSWORD_RECOVERY`:`SIGNED_IN`,r.session)),this._returnResult({data:Object.assign(Object.assign({},r),{redirectType:n??null}),error:i})}catch(e){if(await ds(this.storage,`${this.storageKey}-code-verifier`),F(e))return this._returnResult({data:{user:null,session:null,redirectType:null},error:e});throw e}}async signInWithIdToken(e){try{let{options:t,provider:n,token:r,access_token:i,nonce:a}=e,{data:o,error:s}=await I(this.fetch,`POST`,`${this.url}/token?grant_type=id_token`,{headers:this.headers,body:{provider:n,id_token:r,access_token:i,nonce:a,gotrue_meta_security:{captcha_token:t?.captchaToken}},xform:Is});if(s)return this._returnResult({data:{user:null,session:null},error:s});if(!o||!o.session||!o.user){let e=new jo;return this._returnResult({data:{user:null,session:null},error:e})}return o.session&&(await this._saveSession(o.session),await this._notifyAllSubscribers(`SIGNED_IN`,o.session)),this._returnResult({data:o,error:s})}catch(e){if(F(e))return this._returnResult({data:{user:null,session:null},error:e});throw e}}async signInWithOtp(e){try{if(`email`in e){let{email:t,options:n}=e,r=null,i=null;this.flowType===`pkce`&&([r,i]=await bs(this.storage,this.storageKey));let{error:a}=await I(this.fetch,`POST`,`${this.url}/otp`,{headers:this.headers,body:{email:t,data:n?.data??{},create_user:n?.shouldCreateUser??!0,gotrue_meta_security:{captcha_token:n?.captchaToken},code_challenge:r,code_challenge_method:i},redirectTo:n?.emailRedirectTo});return this._returnResult({data:{user:null,session:null},error:a})}if(`phone`in e){let{phone:t,options:n}=e,{data:r,error:i}=await I(this.fetch,`POST`,`${this.url}/otp`,{headers:this.headers,body:{phone:t,data:n?.data??{},create_user:n?.shouldCreateUser??!0,gotrue_meta_security:{captcha_token:n?.captchaToken},channel:n?.channel??`sms`}});return this._returnResult({data:{user:null,session:null,messageId:r?.message_id},error:i})}throw new Mo(`You must provide either an email or phone number.`)}catch(e){if(await ds(this.storage,`${this.storageKey}-code-verifier`),F(e))return this._returnResult({data:{user:null,session:null},error:e});throw e}}async verifyOtp(e){try{let t,n;`options`in e&&(t=e.options?.redirectTo,n=e.options?.captchaToken);let{data:r,error:i}=await I(this.fetch,`POST`,`${this.url}/verify`,{headers:this.headers,body:Object.assign(Object.assign({},e),{gotrue_meta_security:{captcha_token:n}}),redirectTo:t,xform:Is});if(i)throw i;if(!r)throw Error(`An error occurred on token verification.`);let a=r.session,o=r.user;return a?.access_token&&(await this._saveSession(a),await this._notifyAllSubscribers(e.type==`recovery`?`PASSWORD_RECOVERY`:`SIGNED_IN`,a)),this._returnResult({data:{user:o,session:a},error:null})}catch(e){if(F(e))return this._returnResult({data:{user:null,session:null},error:e});throw e}}async signInWithSSO(e){try{let t=null,n=null;this.flowType===`pkce`&&([t,n]=await bs(this.storage,this.storageKey));let r=await I(this.fetch,`POST`,`${this.url}/sso`,{body:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},`providerId`in e?{provider_id:e.providerId}:null),`domain`in e?{domain:e.domain}:null),{redirect_to:e.options?.redirectTo??void 0}),e?.options?.captchaToken?{gotrue_meta_security:{captcha_token:e.options.captchaToken}}:null),{skip_http_redirect:!0,code_challenge:t,code_challenge_method:n}),headers:this.headers,xform:zs});return r.data?.url&&rs()&&!e.options?.skipBrowserRedirect&&window.location.assign(r.data.url),this._returnResult(r)}catch(e){if(await ds(this.storage,`${this.storageKey}-code-verifier`),F(e))return this._returnResult({data:null,error:e});throw e}}async reauthenticate(){return await this.initializePromise,this.lock==null?await this._reauthenticate():await this._acquireLock(this.lockAcquireTimeout,async()=>await this._reauthenticate())}async _reauthenticate(){try{return await this._useSession(async e=>{let{data:{session:t},error:n}=e;if(n)throw n;if(!t)throw new ko;let{error:r}=await I(this.fetch,`GET`,`${this.url}/reauthenticate`,{headers:this.headers,jwt:t.access_token});return this._returnResult({data:{user:null,session:null},error:r})})}catch(e){if(F(e))return this._returnResult({data:{user:null,session:null},error:e});throw e}}async resend(e){try{let t=`${this.url}/resend`;if(`email`in e){let{email:n,type:r,options:i}=e,a=null,o=null;this.flowType===`pkce`&&([a,o]=await bs(this.storage,this.storageKey));let{error:s}=await I(this.fetch,`POST`,t,{headers:this.headers,body:{email:n,type:r,gotrue_meta_security:{captcha_token:i?.captchaToken},code_challenge:a,code_challenge_method:o},redirectTo:i?.emailRedirectTo});return s&&await ds(this.storage,`${this.storageKey}-code-verifier`),this._returnResult({data:{user:null,session:null},error:s})}else if(`phone`in e){let{phone:n,type:r,options:i}=e,{data:a,error:o}=await I(this.fetch,`POST`,t,{headers:this.headers,body:{phone:n,type:r,gotrue_meta_security:{captcha_token:i?.captchaToken}}});return this._returnResult({data:{user:null,session:null,messageId:a?.message_id},error:o})}throw new Mo(`You must provide either an email or phone number and a type`)}catch(e){if(await ds(this.storage,`${this.storageKey}-code-verifier`),F(e))return this._returnResult({data:{user:null,session:null},error:e});throw e}}async getSession(){return await this.initializePromise,this.lock==null?await this._useSession(async e=>e):await this._acquireLock(this.lockAcquireTimeout,async()=>this._useSession(async e=>e))}async _acquireLock(e,t){this._debug(`#_acquireLock`,`begin`,e);try{if(this.lockAcquired){let e=this.pendingInLock.length?this.pendingInLock[this.pendingInLock.length-1]:Promise.resolve(),n=(async()=>(await e,await t()))();return this.pendingInLock.push((async()=>{try{await n}catch{}})()),n}return await this.lock(`lock:${this.storageKey}`,e,async()=>{this._debug(`#_acquireLock`,`lock acquired for storage key`,this.storageKey);try{this.lockAcquired=!0;let e=t();for(this.pendingInLock.push((async()=>{try{await e}catch{}})()),await e;this.pendingInLock.length;){let e=[...this.pendingInLock];await Promise.all(e),this.pendingInLock.splice(0,e.length)}return await e}finally{this._debug(`#_acquireLock`,`lock released for storage key`,this.storageKey),this.lockAcquired=!1}})}finally{this._debug(`#_acquireLock`,`end`)}}async _useSession(e){this._debug(`#_useSession`,`begin`);try{return await e(await this.__loadSession())}finally{this._debug(`#_useSession`,`end`)}}async __loadSession(){this._debug(`#__loadSession()`,`begin`),this.lock!=null&&!this.lockAcquired&&this._debug(`#__loadSession()`,`used outside of an acquired lock!`,Error().stack);try{let e=null,t=await us(this.storage,this.storageKey);if(this._debug(`#getSession()`,`session from storage`,t),t!==null&&(this._isValidSession(t)?e=t:(this._debug(`#getSession()`,`session from storage is not val
35id`),await this._removeSession())),!e)return{data:{session:null},error:null};let n=e.expires_at?e.expires_at*1e3-Date.now()<go:!1;if(this._debug(`#__loadSession()`,`session has${n?``:` not`} expired`,`expires_at`,e.expires_at),!n){if(this.userStorage){let t=await us(this.userStorage,this.storageKey+`-user`);t?.user?e.user=t.user:e.user=Os()}if(this.storage.isServer&&e.user&&!e.user.__isUserNotAvailableProxy){let t={value:this.suppressGetSessionWarning};e.user=ks(e.user,t),t.value&&(this.suppressGetSessionWarning=!0)}return{data:{session:e},error:null}}let{data:r,error:i}=await this._callRefreshToken(e.refresh_token);if(i){if(e.expires_at&&e.expires_at*1e3>Date.now()){let t=await us(this.storage,this.storageKey);if(t&&t.refresh_token===e.refresh_token)return this._returnResult({data:{session:e},error:null})}return this._returnResult({data:{session:null},error:i})}return this._returnResult({data:{session:r},error:null})}finally{this._debug(`#__loadSession()`,`end`)}}async getUser(e){if(e)return await this._getUser(e);await this.initializePromise;let t;return t=this.lock==null?await this._getUser():await this._acquireLock(this.lockAcquireTimeout,async()=>await this._getUser()),t.data.user&&(this.suppressGetSessionWarning=!0),t}async _getUser(e){try{return e?await I(this.fetch,`GET`,`${this.url}/user`,{headers:this.headers,jwt:e,xform:Rs}):await this._useSession(async e=>{let{data:t,error:n}=e;if(n)throw n;return!t.session?.access_token&&!this.hasCustomAuthorizationHeader?{data:{user:null},error:new ko}:await I(this.fetch,`GET`,`${this.url}/user`,{headers:this.headers,jwt:t.session?.access_token??void 0,xform:Rs})})}catch(e){if(F(e))return Ao(e)&&(await this._removeSession(),await ds(this.storage,`${this.storageKey}-code-verifier`)),this._returnResult({data:{user:null},error:e});throw e}}async updateUser(e,t={}){return await this.initializePromise,this.lock==null?await this._updateUser(e,t):await this._acquireLock(this.lockAcquireTimeout,async()=>await this._updateUser(e,t))}async _updateUser(e,t={}){try{return await this._useSession(async n=>{let{data:r,error:i}=n;if(i)throw i;if(!r.session)throw new ko;let a=r.session,o=null,s=null;this.flowType===`pkce`&&e.email!=null&&([o,s]=await bs(this.storage,this.storageKey));let{data:c,error:l}=await I(this.fetch,`PUT`,`${this.url}/user`,{headers:this.headers,redirectTo:t?.emailRedirectTo,body:Object.assign(Object.assign({},e),{code_challenge:o,code_challenge_method:s}),jwt:a.access_token,xform:Rs});if(l)throw l;return a.user=c.user,await this._saveSession(a),await this._notifyAllSubscribers(`USER_UPDATED`,a),this._returnResult({data:{user:a.user},error:null})})}catch(e){if(await ds(this.storage,`${this.storageKey}-code-verifier`),F(e))return this._returnResult({data:{user:null},error:e});throw e}}async setSession(e){return await this.initializePromise,this.lock==null?await this._setSession(e):await this._acquireLock(this.lockAcquireTimeout,async()=>await this._setSession(e))}async _setSession(e){try{if(!e.access_token||!e.refresh_token)throw new ko;let t=Date.now()/1e3,n=t,r=!0,i=null,{payload:a}=ps(e.access_token);if(a.exp&&(n=a.exp,r=n<=t),r){let{data:t,error:n}=await this._callRefreshToken(e.refresh_token);if(n)return this._returnResult({data:{user:null,session:null},error:n});if(!t)return{data:{user:null,session:null},error:null};i=t}else{let{data:r,error:a}=await this._getUser(e.access_token);if(a)return this._returnResult({data:{user:null,session:null},error:a});i={access_token:e.access_token,refresh_token:e.refresh_token,user:r.user,token_type:`bearer`,expires_in:n-t,expires_at:n},await this._saveSession(i),await this._notifyAllSubscribers(`SIGNED_IN`,i)}return this._returnResult({data:{user:i.user,session:i},error:null})}catch(e){if(F(e))return this._returnResult({data:{session:null,user:null},error:e});throw e}}async refreshSession(e){return await this.initializePromise,this.lock==null?await this._refreshSession(e):await this._acquireLock(this.lockAcquireTimeout,async()=>await this._refreshSession(e))}async _refreshSession(e){try{return await this._useSession(async t=>{if(!e){let{data:n,error:r}=t;if(r)throw r;e=n.session??void 0}if(!e?.refresh_token)throw new ko;let{data:n,error:r}=await this._callRefreshToken(e.refresh_token);return r?this._returnResult({data:{user:null,session:null},error:r}):n?this._returnResult({data:{user:n.user,session:n},error:null}):this._returnResult({data:{user:null,session:null},error:null})})}catch(e){if(F(e))return this._returnResult({data:{user:null,session:null},error:e});throw e}}async _getSessionFromURL(e,t){try{if(!rs())throw new No(`No browser detected.`);if(e.error||e.error_description||e.error_code)throw new No(e.error_description||`Error in URL with unspecified error_description`,{error:e.error||`unspecified_error`,code:e.error_code||`unspecified_code`});switch(t){case`implicit`:if(this.flowType===`pkce`)throw new Fo(`Not a valid PKCE flow url.`);break;case`pkce`:if(this.flowType===`implicit`)throw new No(`Not a valid implicit grant flow url.`);break;default:}if(t===`pkce`){if(this._debug(`#_initialize()`,`begin`,`is PKCE flow`,!0),!e.code)throw new Fo(`No code detected.`);let{data:t,error:n}=await this._exchangeCodeForSession(e.code);
35if(n)throw n;let r=new URL(window.location.href);return r.searchParams.delete(`code`),window.history.replaceState(window.history.state,``,r.toString()),{data:{session:t.session,redirectType:t.redirectType??null},error:null}}let{provider_token:n,provider_refresh_token:r,access_token:i,refresh_token:a,expires_in:o,expires_at:s,token_type:c}=e;if(!i||!o||!a||!c)throw new No(`No session defined in URL`);let l=Math.round(Date.now()/1e3),u=parseInt(o),d=l+u;s&&(d=parseInt(s));let f=d-l;f*1e3<=3e4&&console.warn(`@supabase/gotrue-js: Session as retrieved from URL expires in ${f}s, should have been closer to ${u}s`);let p=d-u;l-p>=120?console.warn(`@supabase/gotrue-js: Session as retrieved from URL was issued over 120s ago, URL could be stale`,p,d,l):l-p<0&&console.warn(`@supabase/gotrue-js: Session as retrieved from URL was issued in the future? Check the device clock for skew`,p,d,l);let{data:m,error:h}=await this._getUser(i);if(h)throw h;let g={provider_token:n,provider_refresh_token:r,access_token:i,expires_in:u,expires_at:d,refresh_token:a,token_type:c,user:m.user};return window.location.hash=``,this._debug(`#_getSessionFromURL()`,`clearing window.location.hash`),this._returnResult({data:{session:g,redirectType:e.type},error:null})}catch(e){if(F(e))return this._returnResult({data:{session:null,redirectType:null},error:e});throw e}}_isImplicitGrantCallback(e){return typeof this.detectSessionInUrl==`function`?this.detectSessionInUrl(new URL(window.location.href),e):!!(e.access_token||e.error||e.error_description||e.error_code)}async _isPKCECallback(e){let t=await us(this.storage,`${this.storageKey}-code-verifier`);return!!(e.code&&t)}async signOut(e={scope:`global`}){return await this.initializePromise,this.lock==null?await this._signOut(e):await this._acquireLock(this.lockAcquireTimeout,async()=>await this._signOut(e))}async _signOut({scope:e}={scope:`global`}){return await this._useSession(async t=>{let{data:n,error:r}=t;if(r&&!Ao(r))return this._returnResult({error:r});let i=n.session?.access_token;if(i){let{error:t}=await this.admin.signOut(i,e);if(t&&!(Eo(t)&&(t.status===404||t.status===401||t.status===403)||Ao(t)))return this._returnResult({error:t})}return e!==`others`&&(await this._removeSession(),await ds(this.storage,`${this.storageKey}-code-verifier`)),this._returnResult({error:null})})}onAuthStateChange(e){let t=ns(),n={id:t,callback:e,unsubscribe:()=>{this._debug(`#unsubscribe()`,`state change callback with id removed`,t),this.stateChangeEmitters.delete(t)}};return this._debug(`#onAuthStateChange()`,`registered callback with id`,t),this.stateChangeEmitters.set(t,n),(async()=>{await this.initializePromise,this.lock==null?await this._emitInitialSession(t):await this._acquireLock(this.lockAcquireTimeout,async()=>{this._emitInitialSession(t)})})(),{data:{subscription:n}}}async _emitInitialSession(e){return await this._useSession(async t=>{try{let{data:{session:n},error:r}=t;if(r)throw r;await this.stateChangeEmitters.get(e)?.callback(`INITIAL_SESSION`,n),this._debug(`INITIAL_SESSION`,`callback id`,e,`session`,n)}catch(t){await this.stateChangeEmitters.get(e)?.callback(`INITIAL_SESSION`,null),this._debug(`INITIAL_SESSION`,`callback id`,e,`error`,t),Ao(t)?console.warn(t):console.error(t)}})}async resetPasswordForEmail(e,t={}){let n=null,r=null;this.flowType===`pkce`&&([n,r]=await bs(this.storage,this.storageKey,!0));try{return await I(this.fetch,`POST`,`${this.url}/recover`,{body:{email:e,code_challenge:n,code_challenge_method:r,gotrue_meta_security:{captcha_token:t.captchaToken}},headers:this.headers,redirectTo:t.redirectTo})}catch(e){if(await ds(this.storage,`${this.storageKey}-code-verifier`),F(e))return this._returnResult({data:null,error:e});throw e}}async getUserIdentities(){try{let{data:e,error:t}=await this.getUser();if(t)throw t;return this._returnResult({data:{identities:e.user.identities??[]},error:null})}catch(e){if(F(e))return this._returnResult({data:null,error:e});throw e}}async linkIdentity(e){return`token`in e?this.linkIdentityIdToken(e):this.linkIdentityOAuth(e)}async linkIdentityOAuth(e){try{let{data:t,error:n}=await this._useSession(async t=>{let{data:n,error:r}=t;if(r)throw r;let i=await this._getUrlForProvider(`${this.url}/user/identities/authorize`,e.provider,{redirectTo:e.options?.redirectTo,scopes:e.options?.scopes,queryParams:e.options?.queryParams,skipBrowserRedirect:!0});return await I(this.fetch,`GET`,i,{headers:this.headers,jwt:n.session?.access_token??void 0})});if(n)throw n;return rs()&&!e.options?.skipBrowserRedirect&&window.location.assign(t?.url),this._returnResult({data:{provider:e.provider,url:t?.url},error:null})}catch(t){if(F(t))return this._returnResult({data:{provider:e.provider,url:null},error:t});throw t}}async linkIdentityIdToken(e){return await this._useSession(async t=>{try{let{error:n,data:{session:r}}=t;if(n)throw n;let{options:i,provider:a,token:o,access_token:s,nonce:c}=e,{data:l,error:u}=await I(this.fetch,`POST`,`${this.url}/token?grant_type=id_token`,{headers:this.headers,jwt:r?.access_token??void 0,body:{provider:a,id_token:o,access_token:s,nonce:c,link_identity:!0,gotrue_meta_security:{captcha_token:i?.captchaToken}},xform:Is});return u?this._returnResult({data:{user:null,session:null},error:u}):!l||!l.session||!l.user?this._returnResult({data:{user:null,session:null},error:new jo}):(l.session&&(await this._saveSession(l.session),await this._notifyAllSubscribers(`USER_UPDATED`,l.session)),this._returnResult({data:l,error:u}))}catch(e){if(await ds(this.storage,`${this.storageKey}-code-verifier`),F(e))return this._returnResult({data:{user:null,session:null},error:e});throw e}})}async unlinkIdentity(e){try{return await this._useSession(async t=>{let{data:n,error:r}=t;if(r)throw r;return await I(this.fetch,`DELETE`,`${this.url}/user/identities/${e.identity_id}`,{headers:this.headers,jwt:n.session?.access_token??void 0})})}catch(e){if(F(e))return this._returnResult({data:null,error:e});throw e}}async _refreshAccessToken(e){let t=`#_refreshAccessToken()`;this._debug(t,`begin`);try{let n=Date.now();return await hs(async n=>(n>0&&await ms(200*2**(n-1)),this._debug(t,`refreshing attempt`,n),await I(this.fetch,`POST`,`${this.url}/token?grant_type=refresh_token`,{body:{refresh_token:e},headers:this.headers,xform:Is})),(e,t)=>{let r=200*2**e;return t&&Ro(t)&&Date.now()+r-n<3e4})}catch(e){if(this._debug(t,`error`,e),F(e))return this._returnResult({data:{session:null,user:null},error:e});throw e}finally{this._debug(t,`end`)}}_isValidSession(e){return typeof e==`object`&&!!e&&`access_token`in e&&`refresh_token`in e&&`expires_at`in e}async _handleProviderSignIn(e,t){let n=await this._getUrlForProvider(`${this.url}/authorize`,e,{redirectTo:t.redirectTo,scopes:t.scopes,queryParams:t.queryParams});return this._debug(`#_handleProviderSignIn()`,`provider`,e,`options`,t,`url`,n),rs()&&!t.skipBrowserRedirect&&window.location.assign(n),{data:{provider:e,url:n},error:null}}async _recoverAndRefresh(){let e=`#_recoverAndRefresh()`;this._debug(e,`begin`);try{let t=await us(this.storage,this.storageKey);if(t&&this.userStorage){let e=await us(this.userStorage,this.storageKey+`-user`);!this.storage.isServer&&Object.is(this.storage,this.userStorage)&&!e&&(e={user:t.user},await ls(this.userStorage,this.storageKey+`-user`,e)),t.user=e?.user??Os()}else if(t&&!t.user&&!t.user){let e=await us(this.storage,this.storageKey+`-user`);e&&e?.user?(t.user=e.user,await ds(this.storage,this.storageKey+`-user`),await ls(this.storage,this.storageKey,t)):t.user=Os()}if(this._debug(e,`session from storage`,t),!this._isValidSession(t)){this._debug(e,`session is not val
35id`),t!==null&&await this._removeSession();return}let n=(t.expires_at??1/0)*1e3-Date.now()<go;if(this._debug(e,`session has${n?``:` not`} expired with margin of ${go}s`),n){if(this.autoRefreshToken&&t.refresh_token){let{error:n}=await this._callRefreshToken(t.refresh_token);n&&(Bo(n)?this._debug(e,`refresh discarded by commit guard`,n):this._debug(e,`refresh failed`,n))}}else if(t.user&&t.user.__isUserNotAvailableProxy===!0)try{let{data:n,error:r}=await this._getUser(t.access_token);!r&&n?.user?(t.user=n.user,await this._saveSession(t),await this._notifyAllSubscribers(`SIGNED_IN`,t)):this._debug(e,`could not get user data, skipping SIGNED_IN notification`)}catch(t){console.error(`Error getting user data:`,t),this._debug(e,`error getting user data, skipping SIGNED_IN notification`,t)}else await this._notifyAllSubscribers(`SIGNED_IN`,t)}catch(t){this._debug(e,`error`,t),console.error(t);return}finally{this._debug(e,`end`)}}async _callRefreshToken(e){var t,n;if(!e)throw new ko;if(this.refreshingDeferred)return this.refreshingDeferred.promise;if(this.lastRefreshFailure&&this.lastRefreshFailure.refreshToken===e&&Date.now()<this.lastRefreshFailure.expiresAt)return this._debug(`#_callRefreshToken()`,`returning cached failure (cooldown active)`),this.lastRefreshFailure.result;let r=`#_callRefreshToken()`;this._debug(r,`begin`);try{this.refreshingDeferred=new fs;let t=await us(this.storage,this.storageKey),{data:n,error:i}=await this._refreshAccessToken(e);if(i)throw i;if(!n.session)throw new ko;let a=await us(this.storage,this.storageKey);if(t!==null&&(a===null||a.refresh_token!==t.refresh_token)){this._debug(r,`commit guard: storage changed since refresh started, discarding rotated tokens`,{startedWith:`present`,nowHolds:a?`replaced`:`cleared`});let e={data:null,error:new zo};return this.refreshingDeferred.resolve(e),e}let o=this._sessionRemovalEpoch;if(await this._saveSession(n.session),this._sessionRemovalEpoch!==o){this._debug(r,`commit guard (post-save): _removeSession ran during _saveSession, undoing write`),await ds(this.storage,this.storageKey),this.userStorage&&await ds(this.userStorage,this.storageKey+`-user`);let e={data:null,error:new zo};return this.refreshingDeferred.resolve(e),e}await this._notifyAllSubscribers(`TOKEN_REFRESHED`,n.session);let s={data:n.session,error:null};return this.lastRefreshFailure=null,this.refreshingDeferred.resolve(s),s}catch(i){if(this._debug(r,`error`,i),F(i)){let n={data:null,error:i};if(!Ro(i)){let e=await us(this.storage,this.storageKey);e?.expires_at&&e.expires_at*1e3>Date.now()?this._debug(r,`proactive refresh failed, access token still valid â preserving session`):await this._removeSession()}return this.lastRefreshFailure={refreshToken:e,result:n,expiresAt:Date.now()+_o},(t=this.refreshingDeferred)==null||t.resolve(n),n}throw(n=this.refreshingDeferred)==null||n.reject(i),i}finally{this.refreshingDeferred=null,this._debug(r,`end`)}}async _notifyAllSubscribers(e,t,n=!0){let r=`#_notifyAllSubscribers(${e})`;this._debug(r,`begin`,t,`broadcast = ${n}`);try{this.broadcastChannel&&n&&this.broadcastChannel.postMessage({event:e,session:t});let r=[],i=Array.from(this.stateChangeEmitters.values()).map(async n=>{try{await n.callback(e,t)}catch(e){r.push(e)}});if(await Promise.all(i),r.length>0){for(let e=0;e<r.length;e+=1)console.error(r[e]);throw r[0]}}finally{this._debug(r,`end`)}}async _saveSession(e){this._debug(`#_saveSession()`,e),this.suppressGetSessionWarning=!0,await ds(this.storage,`${this.storageKey}-code-verifier`);let t=Object.assign({},e),n=t.user&&t.user.__isUserNotAvailableProxy===!0;if(this.userStorage){!n&&t.user&&await ls(this.userStorage,this.storageKey+`-user`,{user:t.user});let e=Object.assign({},t);delete e.user;let r=As(e);await ls(this.storage,this.storageKey,r)}else{let e=As(t);await ls(this.storage,this.storageKey,e)}}async _removeSession(){this._sessionRemovalEpoch+=1,this._debug(`#_removeSession()`),this.lastRefreshFailure=null,this.suppressGetSessionWarning=!1,await ds(this.storage,this.storageKey),await ds(this.storage,this.storageKey+`-code-verifier`),await ds(this.storage,this.storageKey+`-user`),this.userStorage&&await ds(this.userStorage,this.storageKey+`-user`),await this._notifyAllSubscribers(`SIGNED_OUT`,null)}_removeVisibilityChangedCallback(){this._debug(`#_removeVisibilityChangedCallback()`);let e=this.visibilityChangedCallback;this.visibilityChangedCallback=null;try{e&&rs()&&window!=null&&window.removeEventListener&&window.removeEventListener(`visibilitychange`,e)}
35catch(e){console.error(`removing visibilitychange callback failed`,e)}}async _startAutoRefresh(){await this._stopAutoRefresh(),this._debug(`#_startAutoRefresh()`);let e=setInterval(()=>this._autoRefreshTokenTick(),ho);this.autoRefreshTicker=e,e&&typeof e==`object`&&typeof e.unref==`function`?e.unref():typeof Deno<`u`&&typeof Deno.unrefTimer==`function`&&Deno.unrefTimer(e);let t=setTimeout(async()=>{await this.initializePromise,await this._autoRefreshTokenTick()},0);this.autoRefreshTickTimeout=t,t&&typeof t==`object`&&typeof t.unref==`function`?t.unref():typeof Deno<`u`&&typeof Deno.unrefTimer==`function`&&Deno.unrefTimer(t)}async _stopAutoRefresh(){this._debug(`#_stopAutoRefresh()`);let e=this.autoRefreshTicker;this.autoRefreshTicker=null,e&&clearInterval(e);let t=this.autoRefreshTickTimeout;this.autoRefreshTickTimeout=null,t&&clearTimeout(t)}async startAutoRefresh(){this._removeVisibilityChangedCallback(),await this._startAutoRefresh()}async stopAutoRefresh(){this._removeVisibilityChangedCallback(),await this._stopAutoRefresh()}async dispose(){var e;this._removeVisibilityChangedCallback(),await this._stopAutoRefresh(),(e=this.broadcastChannel)==null||e.close(),this.broadcastChannel=null,this.stateChangeEmitters.clear()}async _autoRefreshTokenTick(){if(this._debug(`#_autoRefreshTokenTick()`,`begin`),this.lock!=null){try{await this._acquireLock(0,async()=>{try{let e=Date.now();try{return await this._useSession(async t=>{let{data:{session:n}}=t;if(!n||!n.refresh_token||!n.expires_at){this._debug(`#_autoRefreshTokenTick()`,`no session`);return}let r=Math.floor((n.expires_at*1e3-e)/ho);this._debug(`#_autoRefreshTokenTick()`,`access token expires in ${r} ticks, a tick lasts ${ho}ms, refresh threshold is 3 ticks`),r<=3&&await this._callRefreshToken(n.refresh_token)})}catch(e){console.error(`Auto refresh tick failed with error. This is likely a transient error.`,e)}}finally{this._debug(`#_autoRefreshTokenTick()`,`end`)}})}catch(e){if(e instanceof Ks)this._debug(`auto refresh token tick lock not available`);else throw e}return}if(this.refreshingDeferred!==null){this._debug(`#_autoRefreshTokenTick()`,`refresh already in flight, skipping`);return}try{let e=Date.now();try{await this._useSession(async t=>{let{data:{session:n}}=t;if(!n||!n.refresh_token||!n.expires_at){this._debug(`#_autoRefreshTokenTick()`,`no session`);return}let r=Math.floor((n.expires_at*1e3-e)/ho);this._debug(`#_autoRefreshTokenTick()`,`access token expires in ${r} ticks, a tick lasts ${ho}ms, refresh threshold is 3 ticks`),r<=3&&await this._callRefreshToken(n.refresh_token)})}catch(e){console.error(`Auto refresh tick failed with error. This is likely a transient error.`,e)}}finally{this._debug(`#_autoRefreshTokenTick()`,`end`)}}async _handleVisibilityChange(){if(this._debug(`#_handleVisibilityChange()`),!rs()||!(window!=null&&window.addEventListener))return this.autoRefreshToken&&this.startAutoRefresh(),!1;try{this.visibilityChangedCallback=async()=>{try{await this._onVisibilityChanged(!1)}catch(e){this._debug(`#visibilityChangedCallback`,`error`,e)}},window==null||window.addEventListener(`visibilitychange`,this.visibilityChangedCallback),await this._onVisibilityChanged(!0)}catch(e){console.error(`_handleVisibilityChange`,e)}}async _onVisibilityChanged(e){let t=`#_onVisibilityChanged(${e})`;if(this._debug(t,`visibilityState`,document.visibilityState),document.visibilityState===`visible`){if(this.autoRefreshToken&&this._startAutoRefresh(),!e)if(await this.initializePromise,this.lock!=null)await this._acquireLock(this.lockAcquireTimeout,async()=>{if(document.visibilityState!==`visible`){this._debug(t,`acquired the lock to recover the session, but the browser visibilityState is no longer visible, aborting`);return}await this._recoverAndRefresh()});else{if(document.visibilityState!==`visible`){this._debug(t,`visibilityState is no longer visible, skipping recovery`);return}await this._recoverAndRefresh()}}else document.visibilityState===`hidden`&&this.autoRefreshToken&&this._stopAutoRefresh()}async _getUrlForProvider(e,t,n){let r=[`provider=${encodeURIComponent(t)}`];if(n?.redirectTo&&r.push(`redirect_to=${encodeURIComponent(n.redirectTo)}`),n?.scopes&&r.push(`scopes=${encodeURIComponent(n.scopes)}`),this.flowType===`pkce`){let[e,t]=await bs(this.storage,this.storageKey),n=new URLSearchParams({code_challenge:`${encodeURIComponent(e)}`,code_challenge_method:`${encodeURIComponent(t)}`});
35r.push(n.toString())}if(n?.queryParams){let e=new URLSearchParams(n.queryParams);r.push(e.toString())}return n?.skipBrowserRedirect&&r.push(`skip_http_redirect=${n.skipBrowserRedirect}`),`${e}?${r.join(`&`)}`}async _unenroll(e){try{return await this._useSession(async t=>{let{data:n,error:r}=t;return r?this._returnResult({data:null,error:r}):await I(this.fetch,`DELETE`,`${this.url}/factors/${e.factorId}`,{headers:this.headers,jwt:n?.session?.access_token})})}catch(e){if(F(e))return this._returnResult({data:null,error:e});throw e}}async _enroll(e){try{return await this._useSession(async t=>{let{data:n,error:r}=t;if(r)return this._returnResult({data:null,error:r});let i=Object.assign({friendly_name:e.friendlyName,factor_type:e.factorType},e.factorType===`phone`?{phone:e.phone}:e.factorType===`totp`?{issuer:e.issuer}:{}),{data:a,error:o}=await I(this.fetch,`POST`,`${this.url}/factors`,{body:i,headers:this.headers,jwt:n?.session?.access_token});return o?this._returnResult({data:null,error:o}):(e.factorType===`totp`&&a.type===`totp`&&a?.totp?.qr_code&&(a.totp.qr_code=`data:image/svg+xml;utf-8,${a.totp.qr_code}`),this._returnResult({data:a,error:null}))})}catch(e){if(F(e))return this._returnResult({data:null,error:e});throw e}}async _verify(e){let t=async()=>{try{return await this._useSession(async t=>{let{data:n,error:r}=t;if(r)return this._returnResult({data:null,error:r});let i=Object.assign({challenge_id:e.challengeId},`webauthn`in e?{webauthn:Object.assign(Object.assign({},e.webauthn),{credential_response:e.webauthn.type===`create`?ac(e.webauthn.credential_response):oc(e.webauthn.credential_response)})}:{code:e.code}),{data:a,error:o}=await I(this.fetch,`POST`,`${this.url}/factors/${e.factorId}/verify`,{body:i,headers:this.headers,jwt:n?.session?.access_token});return o?this._returnResult({data:null,error:o}):(await this._saveSession(Object.assign({expires_at:Math.round(Date.now()/1e3)+a.expires_in},a)),await this._notifyAllSubscribers(`MFA_CHALLENGE_VERIFIED`,a),this._returnResult({data:a,error:o}))})}catch(e){if(F(e))return this._returnResult({data:null,error:e});throw e}};return this.lock==null?t():this._acquireLock(this.lockAcquireTimeout,t)}async _challenge(e){let t=async()=>{try{return await this._useSession(async t=>{let{data:n,error:r}=t;if(r)return this._returnResult({data:null,error:r});let i=await I(this.fetch,`POST`,`${this.url}/factors/${e.factorId}/challenge`,{body:e,headers:this.headers,jwt:n?.session?.access_token});if(i.error)return i;let{data:a}=i;if(a.type!==`webauthn`)return{data:a,error:null};switch(a.webauthn.type){case`create`:return{data:Object.assign(Object.assign({},a),{webauthn:Object.assign(Object.assign({},a.webauthn),{credential_options:Object.assign(Object.assign({},a.webauthn.credential_options),{publicKey:rc(a.webauthn.credential_options.publicKey)})})}),error:null};case`request`:return{data:Object.assign(Object.assign({},a),{webauthn:Object.assign(Object.assign({},a.webauthn),{credential_options:Object.assign(Object.assign({},a.webauthn.credential_options),{publicKey:ic(a.webauthn.credential_options.publicKey)})})}),error:null}}})}catch(e){if(F(e))return this._returnResult({data:null,error:e});throw e}};return this.lock==null?t():this._acquireLock(this.lockAcquireTimeout,t)}async _challengeAndVerify(e){let{data:t,error:n}=await this._challenge({factorId:e.factorId});return n?this._returnResult({data:null,error:n}):await this._verify({factorId:e.factorId,challengeId:t.id,code:e.code})}async _listFactors(){let{data:{user:e},error:t}=await this.getUser();if(t)return{data:null,error:t};let n={all:[],phone:[],totp:[],webauthn:[]};for(let t of e?.factors??[])n.all.push(t),t.status===`verified`&&n[t.factor_type].push(t);return{data:n,error:null}}async _getAuthenticatorAssuranceLevel(e){if(e)try{let{payload:t}=ps(e),n=null;t.aal&&(n=t.aal);let r=n,{data:{user:i},error:a}=await this.getUser(e);if(a)return this._returnResult({data:null,error:a});((i?.factors)?.filter(e=>e.status===`verified`)??[]).length>0&&(r=`aal2`);let o=t.amr||[];return{data:{currentLevel:n,nextLevel:r,currentAuthenticationMethods:o},error:null}}catch(e){if(F(e))return this._returnResult({data:null,error:e});throw e}let{data:{session:t},error:n}
35=await this.getSession();if(n)return this._returnResult({data:null,error:n});if(!t)return{data:{currentLevel:null,nextLevel:null,currentAuthenticationMethods:[]},error:null};let{payload:r}=ps(t.access_token),i=null;r.aal&&(i=r.aal);let a=i;(t.user.factors?.filter(e=>e.status===`verified`)??[]).length>0&&(a=`aal2`);let o=r.amr||[];return{data:{currentLevel:i,nextLevel:a,currentAuthenticationMethods:o},error:null}}async _getAuthorizationDetails(e){try{return await this._useSession(async t=>{let{data:{session:n},error:r}=t;return r?this._returnResult({data:null,error:r}):n?await I(this.fetch,`GET`,`${this.url}/oauth/authorizations/${e}`,{headers:this.headers,jwt:n.access_token,xform:e=>({data:e,error:null})}):this._returnResult({data:null,error:new ko})})}catch(e){if(F(e))return this._returnResult({data:null,error:e});throw e}}async _approveAuthorization(e,t){try{return await this._useSession(async n=>{let{data:{session:r},error:i}=n;if(i)return this._returnResult({data:null,error:i});if(!r)return this._returnResult({data:null,error:new ko});let a=await I(this.fetch,`POST`,`${this.url}/oauth/authorizations/${e}/consent`,{headers:this.headers,jwt:r.access_token,body:{action:`approve`},xform:e=>({data:e,error:null})});return a.data&&a.data.redirect_url&&rs()&&!t?.skipBrowserRedirect&&window.location.assign(a.data.redirect_url),a})}catch(e){if(F(e))return this._returnResult({data:null,error:e});throw e}}async _denyAuthorization(e,t){try{return await this._useSession(async n=>{let{data:{session:r},error:i}=n;if(i)return this._returnResult({data:null,error:i});if(!r)return this._returnResult({data:null,error:new ko});let a=await I(this.fetch,`POST`,`${this.url}/oauth/authorizations/${e}/consent`,{headers:this.headers,jwt:r.access_token,body:{action:`deny`},xform:e=>({data:e,error:null})});return a.data&&a.data.redirect_url&&rs()&&!t?.skipBrowserRedirect&&window.location.assign(a.data.redirect_url),a})}catch(e){if(F(e))return this._returnResult({data:null,error:e});throw e}}async _listOAuthGrants(){try{return await this._useSession(async e=>{let{data:{session:t},error:n}=e;return n?this._returnResult({data:null,error:n}):t?await I(this.fetch,`GET`,`${this.url}/user/oauth/grants`,{headers:this.headers,jwt:t.access_token,xform:e=>({data:e,error:null})}):this._returnResult({data:null,error:new ko})})}catch(e){if(F(e))return this._returnResult({data:null,error:e});throw e}}async _revokeOAuthGrant(e){try{return await this._useSession(async t=>{let{data:{session:n},error:r}=t;return r?this._returnResult({data:null,error:r}):n?(await I(this.fetch,`DELETE`,`${this.url}/user/oauth/grants`,{headers:this.headers,jwt:n.access_token,query:{client_id:e.clientId},noResolveJson:!0}),{data:{},error:null}):this._returnResult({data:null,error:new ko})})}catch(e){if(F(e))return this._returnResult({data:null,error:e});throw e}}async fetchJwk(e,t={keys:[]}){let n=t.keys.find(t=>t.kid===e);if(n)return n;let r=Date.now();if(n=this.jwks.keys.find(t=>t.kid===e),n&&this.jwks_cached_at+6e5>r)return n;let{data:i,error:a}=await I(this.fetch,`GET`,`${this.url}/.well-known/jwks.json`,{headers:this.headers});if(a)throw a;return!i.keys||i.keys.length===0||(this.jwks=i,this.jwks_cached_at=r,n=i.keys.find(t=>t.kid===e),!n)?null:n}async getClaims(e,t={}){try{let n=e;if(!n){let{data:e,error:t}
35=await this.getSession();if(t||!e.session)return this._returnResult({data:null,error:t});n=e.session.access_token}let{header:r,payload:i,signature:a,raw:{header:o,payload:s}}=ps(n);if(!t?.allowExpired)try{Cs(i.exp)}catch(e){throw new Ho(e instanceof Error?e.message:`JWT validation failed`)}let c=!r.alg||r.alg.startsWith(`HS`)||!r.kid||!(`crypto`in globalThis&&`subtle`in globalThis.crypto)?null:await this.fetchJwk(r.kid,t?.keys?{keys:t.keys}:t?.jwks);if(!c){let{error:e}=await this.getUser(n);if(e)throw e;return{data:{claims:i,header:r,signature:a},error:null}}let l=ws(r.alg),u=await crypto.subtle.importKey(`jwk`,c,l,!0,[`verify`]);if(!await crypto.subtle.verify(l,u,a,$o(`${o}.${s}`)))throw new Ho(`Invalid JWT signature`);return{data:{claims:i,header:r,signature:a},error:null}}catch(e){if(F(e))return this._returnResult({data:null,error:e});throw e}}async signInWithPasskey(e){Ds(this.experimental);try{if(!cc())return this._returnResult({data:null,error:new Do(`Browser does not support WebAuthn`,null)});let{data:t,error:n}=await this._startPasskeyAuthentication({options:{captchaToken:e?.options?.captchaToken}});if(n||!t)return this._returnResult({data:null,error:n});let{data:r,error:i}=await uc({publicKey:ic(t.options),signal:e?.options?.signal??nc.createNewAbortSignal()});if(i||!r)return this._returnResult({data:null,error:i??new Do(`WebAuthn ceremony failed`,null)});let a=oc(r);return this._verifyPasskeyAuthentication({challengeId:t.challenge_id,credential:a})}catch(e){if(F(e))return this._returnResult({data:null,error:e});throw e}}async registerPasskey(e){Ds(this.experimental);try{if(!cc())return this._returnResult({data:null,error:new Do(`Browser does not support WebAuthn`,null)});let{data:t,error:n}=await this._startPasskeyRegistration();if(n||!t)return this._returnResult({data:null,error:n});let{data:r,error:i}=await lc({publicKey:rc(t.options),signal:e?.options?.signal??nc.createNewAbortSignal()});if(i||!r)return this._returnResult({data:null,error:i??new Do(`WebAuthn ceremony failed`,null)});let a=ac(r);return this._verifyPasskeyRegistration({challengeId:t.challenge_id,credential:a})}catch(e){if(F(e))return this._returnResult({data:null,error:e});throw e}}async _startPasskeyRegistration(){Ds(this.experimental);try{return await this._useSession(async e=>{let{data:{session:t},error:n}=e;if(n)return this._returnResult({data:null,error:n});if(!t)return this._returnResult({data:null,error:new ko});let{data:r,error:i}=await I(this.fetch,`POST`,`${this.url}/passkeys/registration/options`,{headers:this.headers,jwt:t.access_token,body:{}});return i?this._returnResult({data:null,error:i}):this._returnResult({data:r,error:null})})}catch(e){if(F(e))return this._returnResult({data:null,error:e});throw e}}async _verifyPasskeyRegistration(e){Ds(this.experimental);try{return await this._useSession(async t=>{let{data:{session:n},error:r}=t;if(r)return this._returnResult({data:null,error:r});if(!n)return this._returnResult({data:null,error:new ko});let{data:i,error:a}=await I(this.fetch,`POST`,`${this.url}/passkeys/registration/verify`,{headers:this.headers,jwt:n.access_token,body:{challenge_id:e.challengeId,credential:e.credential}});return a?this._returnResult({data:null,error:a}):this._returnResult({data:i,error:null})})}catch(e){if(F(e))return this._returnResult({data:null,error:e});throw e}}async _startPasskeyAuthentication(e){Ds(this.experimental);try{let{data:t,error:n}=await I(this.fetch,`POST`,`${this.url}/passkeys/authentication/options`,{headers:this.headers,body:{gotrue_meta_security:{captcha_token:e?.options?.captchaToken}}});return n?this._returnResult({data:null,error:n}):this._returnResult({data:t,error:null})}catch(e){if(F(e))return this._returnResult({data:null,error:e});throw e}}async _verifyPasskeyAuthentication(e){Ds(this.experimental);try{let{data:t,error:n}=await I(this.fetch,`POST`,`${this.url}/passkeys/authentication/verify`,{headers:this.headers,body:{challenge_id:e.challengeId,credential:e.credential},xform:Is});return n?this._returnResult({data:null,error:n}):(t.session&&(await this._saveSession(t.session),await this._notifyAllSubscribers(`SIGNED_IN`,t.session)),this._returnResult({data:t,error:null}))}catch(e){if(F(e))return this._returnResult({data:null,error:e});throw e}}async _listPasskeys(){Ds(this.experimental);try{return await this._useSession(async e=>{let{data:{session:t},error:n}=e;if(n)return this._returnResult({data:null,error:n});if(!t)return this._returnResult({data:null,error:new ko});let{data:r,error:i}=await I(this.fetch,`GET`,`${this.url}/passkeys`,{headers:this.headers,jwt:t.access_token,xform:e=>({data:e,error:null})});return i?this._returnResult({data:null,error:i}):this._returnResult({data:r,error:null})})}catch(e){if(F(e))return this._returnResult({data:null,error:e});throw e}}async _updatePasskey(e){Ds(this.experimental);try{return await this._useSession(async t=>{let{data:{session:n},error:r}=t;if(r)return this._returnResult({data:null,error:r});if(!n)return this._returnResult({data:null,error:new ko});let{data:i,error:a}=await I(this.fetch,`PATCH`,`${this.url}/passkeys/${e.passkeyId}`,{headers:this.headers,jwt:n.access_token,body:{friendly_name:e.friendlyName}});return a?this._returnResult({data:null,error:a}):this._returnResult({data:i,error:null})})}catch(e){if(F(e))return this._returnResult({data:null,error:e});throw e}}async _deletePasskey(e){Ds(this.experimental);try{return await this._useSession(async t=>{let{data:{session:n},error:r}=t;if(r)return this._returnResult({data:null,error:r});if(!n)return this._returnResult({data:null,error:new ko});let{error:i}=await I(this.fetch,`DELETE`,`${this.url}/passkeys/${e.passkeyId}`,{headers:this.headers,jwt:n.access_token,noResolveJson:!0});return i?this._returnResult({data:null,error:i}):this._returnResult({data:null,error:null})})}catch(e){if(F(e))return this._returnResult({data:null,error:e});throw e}}};yc.nextInstanceID={};var bc=yc,xc=`2.108.2`,Sc=``,Cc;typeof Deno<`u`?(Sc=`deno`,Cc=Deno.version?.deno):typeof document<`u`?Sc=`web`:typeof navigator<`u`&&navigator.product===`ReactNative`?Sc=`react-native`:(Sc=`node`,Cc=typeof process<`u`?process.version?.replace(/^v/,``):void 0);var wc=[`runtime=${Sc}`];Cc&&wc.push(`runtime-version=${Cc}`);var Tc={headers:{"X-Client-Info":`supabase-js/${xc}; ${wc.join(`; `)}`}},Ec={schema:`public`},Dc={autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,flowType:`implicit`},Oc={},kc={enabled:!1,respectSamplingDecision:!0};function Ac(e,t,n,r){function i(e){return e instanceof n?e:new n(function(t){t(e)})}return new(n||=Promise)(function(n,a){function o(e){try{c(r.next(e))}catch(e){a(e)}}function s(e){try{c(r.throw(e))}catch(e){a(e)}}function c(e){e.done?n(e.value):i(e.value).then(o,s)}c((r=r.apply(e,t||[])).next())})}var jc=null,Mc=`@opentelemetry/api`;function Nc(){return jc===null&&(jc=S(()=>import(Mc),[]).catch(()=>null)),jc}function Pc(){return Ac(this,void 0,void 0,function*(){try{let e=yield Nc();if(!e||!e.propagation||!e.context)return null;let t={};e.propagation.inject(e.context.active(),t);let n=t.traceparent;return n?{traceparent:n,tracestate:t.tracestate,baggage:t.baggage}:null}catch{return null}})}function Fc(e){if(!e||typeof e!=`string`)return null;let t=e.split(`-`);if(t.length!==4)return null;let[n,r,i,a]=t;if(n.length!==2||r.length!==32||i.length!==16||a.length!==2)return null;let o=/^[0-9a-f]+$/i;return!o.test(n)||!o.test(r)||!o.test(i)||!o.test(a)||r===`00000000000000000000000000000000`||i===`0000000000000000`?null:{version:n,traceId:r,parentId:i,traceFlags:a,isSampled:(parseInt(a,16)&1)==1}}function Ic(e,t){if(!e||!t||t.length===0)return!1;let n;if(e instanceof URL)n=e;else try{n=new URL(e)}catch{return!1}for(let e of t)try{if(typeof e==`string`){if(Lc(n.hostname,e))return!0}
35else if(e instanceof RegExp){if(e.test(n.hostname))return!0}else if(typeof e==`function`&&e(n))return!0}catch{continue}return!1}function Lc(e,t){if(t===e)return!0;if(t.startsWith(`*.`)){let n=t.slice(2);if(e.endsWith(n)&&(e===n||e.endsWith(`.`+n)))return!0}return!1}function Rc(e){let t=[];try{let n=new URL(e);t.push(n.hostname)}catch{}return t.push(`*.supabase.co`,`*.supabase.in`),t.push(`localhost`,`127.0.0.1`,`[::1]`),t}function zc(e){"@babel/helpers - typeof";return zc=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},zc(e)}function Bc(e,t){if(zc(e)!=`object`||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||`default`);if(zc(r)!=`object`)return r;throw TypeError(`@@toPrimitive must return a primitive value.`)}return(t===`string`?String:Number)(e)}function Vc(e){var t=Bc(e,`string`);return zc(t)==`symbol`?t:t+``}function Hc(e,t,n){return(t=Vc(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Uc(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function Wc(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?Uc(Object(n),!0).forEach(function(t){Hc(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Uc(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var Gc=e=>e?(...t)=>e(...t):(...e)=>fetch(...e),Kc=()=>Headers,qc=(e,t,n,r,i)=>{let a=Gc(r),o=Kc(),s=i?.enabled===!0,c=i?.respectSamplingDecision!==!1,l=s?Rc(t):null;return async(t,r)=>{let i=await n()??e,s=new o(r?.headers);if(s.has(`apikey`)||s.set(`apikey`,e),s.has(`Authorization`)||s.set(`Authorization`,`Bearer ${i}`),l){let e=await Jc(t,l,c);e&&(e.traceparent&&!s.has(`traceparent`)&&s.set(`traceparent`,e.traceparent),e.tracestate&&!s.has(`tracestate`)&&s.set(`tracestate`,e.tracestate),e.baggage&&!s.has(`baggage`)&&s.set(`baggage`,e.baggage))}return a(t,Wc(Wc({},r),{},{headers:s}))}};async function Jc(e,t,n){if(!Ic(typeof e==`string`||e instanceof URL?e:e.url,t))return null;let r=await Pc();if(!r||!r.traceparent)return null;if(n){let e=Fc(r.traceparent);if(e&&!e.isSampled)return null}return r}function Yc(e){return typeof e==`boolean`?{enabled:e}:e}function Xc(e){return e.endsWith(`/`)?e:e+`/`}function Zc(e,t){let{db:n,auth:r,realtime:i,global:a}=e,{db:o,auth:s,realtime:c,global:l}=t,u=Yc(e.tracePropagation),d=Yc(t.tracePropagation),f={db:Wc(Wc({},o),n),auth:Wc(Wc({},s),r),realtime:Wc(Wc({},c),i),storage:{},global:Wc(Wc(Wc({},l),a),{},{headers:Wc(Wc({},l?.headers??{}),a?.headers??{})}),tracePropagation:{enabled:u?.enabled??d?.enabled??!1,respectSamplingDecision:u?.respectSamplingDecision??d?.respectSamplingDecision??!0},accessToken:async()=>``};return e.accessToken?f.accessToken=e.accessToken:delete f.accessToken,f}function Qc(e){let t=e?.trim();if(!t)throw Error(`supabaseUrl is required.`);if(!t.match(/^https?:\/\//i))throw Error(`Invalid supabaseUrl: Must be a valid HTTP or HTTPS URL.`);try{return new URL(Xc(t))}catch{throw Error(`Invalid supabaseUrl: Provided URL is malformed.`)}}var $c=class extends bc{constructor(e){super(e)}},el=class{constructor(e,t,n){this.supabaseUrl=e,this.supabaseKey=t;let r=Qc(e);if(!t)throw Error(`supabaseKey is required.`);this.realtimeUrl=new URL(`realtime/v1`,r),this.realtimeUrl.protocol=this.realtimeUrl.protocol.replace(`http`,`ws`),this.authUrl=new URL(`auth/v1`,r),this.storageUrl=new URL(`storage/v1`,r),this.functionsUrl=new URL(`functions/v1`,r);let i=`sb-${r.hostname.split(`.`)[0]}-auth-token`,a={db:Ec,realtime:Oc,auth:Wc(Wc({},Dc),{},{storageKey:i}),global:Tc,tracePropagation:kc},o=Zc(n??{},a);this.settings=o,this.storageKey=o.auth.storageKey??``,this.headers=o.global.headers??{},o.accessToken?(this.accessToken=o.accessToken,this.auth=new Proxy({},{get:(e,t)=>{throw Error(`@supabase/supabase-js: Supabase Client is configured with the accessToken option, accessing supabase.auth.${String(t)} is not possible`)}})):this.auth=this._initSupabaseAuthClient(o.auth??{},this.headers,o.global.fetch),this.fetch=qc(t,e,this._getAccessToken.bind(this),o.global.fetch,o.tracePropagation),this.realtime=this._initRealtimeClient(Wc({headers:this.headers,accessToken:this._getAccessToken.bind(this),fetch:this.fetch},o.realtime)),this.accessToken&&Promise.resolve(this.accessToken()).then(e=>this.realtime.setAuth(e)).catch(e=>console.warn(`Failed to set initial Realtime auth token:`,e)),this.rest=new ti(new URL(`rest/v1`,r).href,{headers:this.headers,schema:o.db.schema,fetch:this.fetch,timeout:o.db.timeout,urlLengthLimit:o.db.urlLengthLimit}),this.storage=new po(this.storageUrl.href,this.headers,this.fetch,n?.storage),o.accessToken||this._listenForAuthEvents()}get functions(){return new Ir(this.functionsUrl.href,{headers:this.headers,customFetch:this.fetch})}from(e){return this.rest.from(e)}schema(e){return this.rest.schema(e)}rpc(e,t={},n={head:!1,get:!1,count:void 0}){return this.rest.rpc(e,t,n)}
35channel(e,t={config:{}}){return this.realtime.channel(e,t)}getChannels(){return this.realtime.getChannels()}removeChannel(e){return this.realtime.removeChannel(e)}removeAllChannels(){return this.realtime.removeAllChannels()}async _getAccessToken(){var e=this;if(e.accessToken)return await e.accessToken();let{data:t}=await e.auth.getSession();return t.session?.access_token??e.supabaseKey}_initSupabaseAuthClient({autoRefreshToken:e,persistSession:t,detectSessionInUrl:n,storage:r,userStorage:i,storageKey:a,flowType:o,lock:s,debug:c,throwOnError:l,experimental:u,lockAcquireTimeout:d,skipAutoInitialize:f},p,m){let h={Authorization:`Bearer ${this.supabaseKey}`,apikey:`${this.supabaseKey}`};return new $c({url:this.authUrl.href,headers:Wc(Wc({},h),p),storageKey:a,autoRefreshToken:e,persistSession:t,detectSessionInUrl:n,storage:r,userStorage:i,flowType:o,lock:s,debug:c,throwOnError:l,experimental:u,fetch:m,lockAcquireTimeout:d,skipAutoInitialize:f,hasCustomAuthorizationHeader:Object.keys(this.headers).some(e=>e.toLowerCase()===`authorization`)})}_initRealtimeClient(e){return new fa(this.realtimeUrl.href,Wc(Wc({},e),{},{params:Wc(Wc({},{apikey:this.supabaseKey}),e?.params)}))}_listenForAuthEvents(){return this.auth.onAuthStateChange((e,t)=>{this._handleTokenChanged(e,`CLIENT`,t?.access_token)})}_handleTokenChanged(e,t,n){(e===`TOKEN_REFRESHED`||e===`SIGNED_IN`)&&this.changedAccessToken!==n?(this.changedAccessToken=n,this.realtime.setAuth(n)):e===`SIGNED_OUT`&&(this.realtime.setAuth(),t==`STORAGE`&&this.auth.signOut(),this.changedAccessToken=void 0)}},tl=(e,t,n)=>new el(e,t,n);function nl(){if(typeof window<`u`)return!1;let e=globalThis.process;if(!e)return!1;let t=e.version;if(t==null)return!1;let n=t.match(/^v(\d+)\./);return n?parseInt(n[1],10)<=18:!1}nl()&&console.warn(`â ï¸ Node.js 18 and below are deprecated and will no longer be supported in future versions of @supabase/supabase-js. Please upgrade to Node.js 20 or later. For more information, visit: https://github.com/orgs/supabase/discussions/37217`);var L=tl(`https://zwqymcoehifdzniztfzc.supabase.co`,`sb_publishable_6QWCzHIJSqJQYa0litEekQ_-0Kvihox`,{auth:{persistSession:!0,autoRefreshToken:!0,detectSessionInUrl:!0}});async function rl(e,t,n={}){try{await L.from(`audit_log`).insert({user_id:e,event_type:t,detail:n})}catch{}}async function il(e,t){let{data:{session:n}}=await L.auth.getSession();n&&await rl(n.user.id,t?`connector_connected`:`connector_disconnected`,{provider:e})}var al=o((e=>{var t=Symbol.for(`react.transitional.element`),n=Symbol.for(`react.fragment`);function r(e,n,r){var i=null;if(r!==void 0&&(i=``+r),n.key!==void 0&&(i=``+n.key),`key`in n)for(var a in r={},n)a!==`key`&&(r[a]=n[a]);else r=n;return n=r.ref,{$$typeof:t,type:e,key:i,ref:n===void 0?null:n,props:r}}e.Fragment=n,e.jsx=r,e.jsxs=r})),ol=o(((e,t)=>{t.exports=al()})),R=ol(),sl=(0,_.createContext)({session:null,profile:null,loading:!0,refreshProfile:async()=>{}});function cl({children:e}){let[t,n]=(0,_.useState)(null),[r,i]=(0,_.useState)(null),[a,o]=(0,_.useState)(!0),[s,c]=(0,_.useState)(!1),l=(0,_.useRef)(null),u=(0,_.useCallback)(async e=>{c(!0);let{data:t}=await L.from(`profiles`).select(`*`).eq(`id`,e).single();i(t??null),c(!1)},[]);(0,_.useEffect)(()=>{L.auth.getSession().then(({data:{session:e}})=>{n(e),l.current=e?.user.id??null,e?u(e.user.id).finally(()=>o(!1)):o(!1)});let{data:{subscription:e}}=L.auth.onAuthStateChange((e,t)=>{let r=l.current;n(t),t?u(t.user.id):i(null),e===`SIGNED_IN`&&t&&rl(t.user.id,`login`),e===`SIGNED_OUT`&&r&&rl(r,`logout`),l.current=t?.user.id??null});return()=>e.unsubscribe()},[u]);let d=(0,_.useCallback)(async()=>{t&&await u(t.user.id)},[t,u]),f=!!t&&r===null&&s;return(0,R.jsx)(sl.Provider,{value:{session:t,profile:r,loading:a||f,refreshProfile:d},children:e})}function ll(){return(0,_.useContext)(sl)}function ul(){let{profile:e}=ll();return!!e?.onboarded_at}var dl={"on Telegram · morning, midday and evening":`sur Telegram · matin, midi et soir`,Blog:`Blog`,"the problem":`le problème`,"what it fixes":`ce que ça règle`,"on Telegram · morning and evening":`sur Telegram · matin et soir`,"It plans your day, then checks what you actually shipped.":`Il planifie ta journée, puis vérifie ce que tu as vraiment livré.`,"Sound familiar?":`Ãa te parle ?`,"The day gets decided by whoever emails first.":`Ta journée est décidée par le premier e-mail reçu.`,"The same task moves to tomorrow, four days running.":`La même tâche repoussée à demain, quatre jours de suite.`,"A busy week, and nothing you can point at.":`Une semaine chargée, et rien à montrer.`,"Nobody notices if you quietly stop shipping.":`Personne ne remarque si tu arrêtes discrètement de livrer.`,"THE PLAN":`LE PLAN`,"Lock the day in the morning.":`Verrouille ta journée le matin.`,"THE CO-FOUNDER":`LE CO-FONDATEUR`,"Ask it anything. It knows your business.":`Demande-lui tout. Il connaît ta boîte.`,"THE PROOF":`LA PREUVE`,"One keystroke proves it.":`Une touche et c'est prouvé.`,"THE VERDICT":`LE VERDICT`,"At night, it reads the day back.":`Le soir, il te relit ta journée.`,"THE STREAK":`LA SÃRIE`,"Consistency grows. Miss, and it shows.":`La régularité pousse. Un manque, et ça se voit.`,"THE POD":`LE BINÃME`,"One other founder sees your numbers.":`Un autre fondateur voit tes chiffres.`,CONNECTORS:`CONNECTEURS`,"Your tools close the tasks themselves.":`Tes outils clôturent les tâches eux-mêmes.`,"
35nothing open to import â connect Linear, Notion, Asana, ClickUp or Jira in Settings first.":`rien d'ouvert à importer â connecte Linear, Notion, Asana, ClickUp ou Jira dans les réglages d'abord.`,"reading your toolsâ¦":`lecture de tes outilsâ¦`,"find open work":`trouver le travail ouvert`,"how crew works":`comment crew fonctionne`,"what your company does, how many tasks a day, whether proof is required":`ce que fait ton entreprise, combien de tâches par jour, si la preuve est exigée`,"the tools Crew reads to verify your work":`les outils que Crew lit pour vérifier ton travail`,"when Crew reaches you, and on which channel":`quand Crew te contacte, et sur quel canal`,"switch company, or add another":`changer d'entreprise, ou en ajouter une`,"your name, email, password and language":`ton nom, email, mot de passe et langue`,"your plan, invoices and payment":`ton offre, tes factures et le paiement`,"{n} finished tasks sit outside this number â nothing could prove them, so they neither raise nor lower it.":`{n} tâches terminées sont hors de ce chiffre : rien ne pouvait les prouver, donc elles ne le montent ni ne le baissent.`,"connect a tool to make them count â":`connecte un outil pour qu'elles comptent â`,"couldn't load today â your tasks are safe, this is a read problem.":`impossible de charger aujourd'hui â tes tâches sont intactes, c'est un problème de lecture.`,retry:`réessayer`,"the last {n} days":`les {n} derniers jours`,"nothing resolved yet â lock a day and this fills in.":`rien de résolu pour l'instant â verrouille une journée et ça se remplit.`,"{v} verified · {a} on your word · {m} missed":`{v} vérifiées · {a} sur ta parole · {m} manquées`,"find time":`trouver du temps`,"Crew reads your calendar, finds the gaps, and holds one for each task you have not scheduled.":`Crew lit ton agenda, trouve les créneaux libres, et en réserve un pour chaque tâche non planifiée.`,"reading your calendarâ¦":`lecture de ton agendaâ¦`,"no free time found today.":`aucun créneau libre aujourd'hui.`,"{n} blocks are in your calendar. They are a plan, not proof â Crew still needs real evidence to close the task.":`{n} créneaux sont dans ton agenda. Ce sont des plans, pas des preuves â Crew a toujours besoin de vraies preuves pour clore la tâche.`,"this writes to your real calendar. Crew never counts a block it created as evidence.":`ceci écrit dans ton vrai agenda. Crew ne compte jamais un créneau qu'il a créé comme preuve.`,"hold {n} selected":`réserver {n}`,"holdingâ¦":`réservationâ¦`,"hold this time":`réserver ce créneau`,"remove this block":`retirer ce créneau`,"auto-scheduling is a solo+ feature":`la planification auto est une fonctionnalité solo+`,"Want to see it first?":`Tu veux le voir avant ?`,"Book a 15-minute demo â":`Réserver une démo de 15 min â`,"read-only · Crew never posts, sends or pays as you":`lecture seule · Crew ne publie, n'envoie et ne paie jamais à ta place`,"One decision a day":`Une décision par jour`,"lock it, then work":`verrouille, puis bosse`,"Proof, not vibes":`Des preuves, pas des impressions`,"verified or it is not done":`vérifié ou ce n'est pas fait`,"No status updates":`Zéro rapport à écrire`,"the evening writes itself":`le soir s'écrit tout seul`,"It comes after you":`Il vient te chercher`,"two quiet days and it asks":`deux jours de silence et il demande`,"tasks a day by default":`tâches par jour par défaut`,"connectors needed to start":`connecteur nécessaire pour démarrer`,"until launch":`jusqu'au lancement`,"30 SECONDS":`30 SECONDES`,"What would Crew fix for you?":`Qu'est-ce que Crew réglerait pour toi ?`,"free until launch, no card. invite-only while we onboard one founder at a time.":`gratuit jusqu'au lancement, sans carte. sur invitation, on intègre un fondateur à la fois.`,"tick everything that is true â more than one is normal":`coche tout ce qui est vrai â plusieurs, c'est normal`,"show what Crew fixes â":`voir ce que Crew règle â`,"{a} of {b}":`{a} sur {b}`,"Here is what Crew does about it":`Voici ce que Crew fait pour ça`,"Join the waitlist â get early access":`Rejoindre la liste d'attente â accès anticipé`,"Nothing ticked â so nothing to fix yet.":`Rien de coché â donc rien à régler pour l'instant.`,"Run it again and tick what is actually true.":`Relance et coche ce qui est vraiment vrai.`,"What actually goe
35s wrong with your days?":`Qu'est-ce qui cloche vraiment dans tes journées ?`,"Your day":`Ta journée`,"My day is set by whoever messages me first":`Ma journée est fixée par le premier qui m'écrit`,"Crew pings you at your hour, before the inbox does, and you lock the day first.":`Crew te ping à ton heure, avant ta boîte mail, et tu verrouilles la journée en premier.`,"I plan in my head and forget by noon":`Je planifie dans ma tête et j'oublie à midi`,"The day is locked in writing â in Telegram and the app â so it isn't held in memory.":`La journée est verrouillée par écrit â dans Telegram et l'app â pas dans ta mémoire.`,"I start three things and finish none":`Je commence trois choses et n'en finis aucune`,"Every locked task gets its own verdict at night: shipped, taken on your word, or missed.":`Chaque tâche verrouillée a son verdict le soir : livrée, sur parole, ou manquée.`,"The same task rolls over for days":`La même tâche est reportée pendant des jours`,"Carried three days running, Crew stops accepting it silently and asks what is actually blocking it.":`Reportée trois jours de suite, Crew arrête de l'accepter en silence et demande ce qui bloque.`,"I do the small tasks and dodge the big one":`Je fais les petites tâches et j'évite la grosse`,"At 8:30 it asks about the one you keep pushing, by name.":`à 20 h 30 il te parle de celle que tu repousses, par son nom.`,"Everything on my list is urgent":`Tout sur ma liste est urgent`,"Three tasks by default, ten at most â the cap is the whole mechanism.":`Trois tâches par défaut, dix au maximum â le plafond, c'est tout le mécanisme.`,"Big projects never start because they're too big":`Les gros projets ne démarrent jamais car ils sont trop gros`,"A bigger effort becomes one day at a time, still tracked as one thing.":`Un gros chantier devient un jour à la fois, toujours suivi comme un seul objet.`,"I don't know which task actually serves my goal":`Je ne sais pas quelle tâche sert vraiment mon objectif`,"Ask it, and it proposes one specific task drawn from your goal and your business context.":`Demande-lui : il propose une tâche précise tirée de ton objectif et de ton contexte.`,"What happens to the record of what you did?":`Que devient la trace de ce que tu as fait ?`,"Your record":`Ta trace`,"I tick things off without really finishing them":`Je coche sans vraiment avoir fini`,"Nothing closes without proof â Crew judges it and says so when it does not hold up.":`Rien ne se clôture sans preuve â Crew juge et le dit quand ça ne tient pas.`,"I can't remember what I shipped last week":`Je ne me souviens pas de ce que j'ai livré la semaine dernière`,"Each day keeps its receipts, so the week is already written when you look back.":`Chaque jour garde ses preuves : la semaine est déjà écrite quand tu regardes en arrière.`,"Writing status updates eats my time":`Ãcrire des points d'avancement me bouffe du temps`,"The evening report writes itself from what actually resolved.":`Le rapport du soir s'écrit tout seul à partir de ce qui a été résolu.`,"Someone asks what moved and I improvise":`On me demande ce qui a avancé et j'improvise`,"Verified, self-attested and missed stay three different things, and the badge names the source.":`Vérifié, déclaré et manqué restent trois choses différentes, et le badge nomme la source.`,"My tools know what I did, nothing collects it":`Mes outils savent ce que j'ai fait, rien ne le rassemble`,"GitHub, Vercel, Stripe, Calendly and your calendar close tasks by themselves.":`GitHub, Vercel, Stripe, Calendly et ton agenda clôturent les tâches tout seuls.`,"I finish things nothing digital can prove":`Je finis des choses qu'aucun outil ne peut prouver`,"A screenshot, a photo or a voice note counts â it is judged the same way as a commit.":`Une capture, une photo ou un vocal comptent â jugés comme un commit.`,"I inflate my own progress without meaning to":`Je gonfle mes progrès sans le vouloir`,"You cannot override a verdict. You improve the proof and ask again.":`Tu ne peux pas forcer un verdict. Tu améliores la preuve et tu redemandes.`,"Where does the time actually go?":`Où passe vraiment le temps ?`,"Your hours":`Tes heures`,"Meetings eat the day and I build at night":`Les réunions mangent la journée et je co
35de le soir`,"It reads your calendar and says when the evening is already gone, before you commit to deep work.":`Il lit ton agenda et te dit quand la soirée est déjà prise, avant que tu t'engages.`,"Admin quietly replaces the real work":`L'administratif remplace discrètement le vrai travail`,"Every task is tagged build / sales / ops as you lock it, so the substitution is visible.":`Chaque tâche est étiquetée build / sales / ops au verrouillage : la substitution se voit.`,"My calendar is full but nothing ships":`Mon agenda est plein mais rien ne sort`,"A meeting only closes the task it actually proves â a full calendar never counts as output.":`Une réunion ne clôture que la tâche qu'elle prouve â un agenda plein n'est pas un résultat.`,"I context-switch between two companies":`Je jongle entre deux boîtes`,"Separate workspaces: each company keeps its own tasks, chat and history.":`Des espaces séparés : chaque boîte garde ses tâches, son chat et son historique.`,"I take on more than the hours allow":`J'en prends plus que les heures ne permettent`,"The daily cap holds, and after a break it offers a single task instead of a full load.":`Le plafond tient, et après une pause il propose une seule tâche plutôt qu'une journée pleine.`,"I never protect time for the hard thing":`Je ne protège jamais de temps pour le plus dur`,"Crew argues with the plan when the day cannot hold it, instead of accepting it silently.":`Crew conteste le plan quand la journée ne peut pas le contenir, au lieu de l'accepter en silence.`,"What happens when you drift?":`Que se passe-t-il quand tu décroches ?`,"When you slip":`Quand tu décroches`,"Nobody notices if I stop shipping":`Personne ne remarque si j'arrête de livrer`,"It speaks first when something actually changes, and a blank day is one tap from real tasks â generated from your goal, or pulled straight out of your own Linear, Notion, Asana, ClickUp or Jira.":`Il parle en premier quand quelque chose change vraiment, et une journée vide est à un clic de vraies tâches â générées depuis ton objectif, ou tirées directement de ton Linear, Notion, Asana, ClickUp ou Jira.`,"I break a streak and abandon it completely":`Je casse une série et j'abandonne complètement`,"One miss wilts the plant with a day to revive it; the streak is built to survive a bad day.":`Un manque fait faner la plante avec un jour pour la sauver ; la série survit à une mauvaise journée.`,"I'm accountable to literally no one":`Je ne rends de comptes à absolument personne`,"A pod is one other founder who sees your rate and your streak â never the text of your tasks.":`Un binôme, c'est un autre fondateur qui voit ton taux et ta série â jamais le texte de tes tâches.`,"I go quiet for a week and rationalise it":`Je disparais une semaine et je me trouve des excuses`,"It chases twice, then stops for good â so the nudge still means something when it arrives.":`Il relance deux fois, puis arrête définitivement â pour que la relance garde du sens.`,"Without a deadline nothing happens":`Sans échéance, rien ne se passe`,"One goal with a date, milestones backed by the verified work underneath them, and a straight answer on whether your rate lands in time.":`Un objectif avec une date, des jalons adossés au travail vérifié qui les porte, et une réponse franche sur la capacité de ton rythme à tenir la date.`,"I burn out, then over-correct":`Je m'épuise, puis je surcompense`,"Rest days you set, and travel or crisis weeks you declare, are skipped rather than counted as misses.":`Les jours de repos que tu fixes, et les semaines de voyage ou de crise déclarées, sont ignorés plutôt que comptés comme des manques.`,"I quietly rewrite how the week went":`Je réécris discrètement le déroulé de la semaine`,"A closed day cannot be edited â the record is the one thing you cannot talk around.":`Un jour clôturé ne se modifie pas â la trace est la seule chose que tu ne peux pas contourner.`,"start over":`recommencer`,"Already have a code?":`Tu as déjà un code ?`,"create your account":`crée ton compte`,"free until launch, no card required":`gratuit jusqu'au lancement, sans carte`,"ask for a feature, it ships within 24 hours":`demande une fonctionnalité, elle est livrée en 24 heures`,"support answered in under 24 hours":`un support qui répond en moins de 24 heures`,"While you're early, your feedback runs the roadmap: features you ask for ship within 24 hours, and support answers in under 24.":`Tant que tu es early, ton feedback dirige la roadmap : les fonctionnalités que tu demandes sont livrées en 24 heures, et le support répond en moins de 24 heures.`,"Marking a task done captures this tab once, as proof. Try it.":`Marquer une tâche faite c
35apture cet onglet une fois, comme preuve. Essaie.`,"0 left":`0 restante`,"2 sent emails are on screen in gmail, both to leads. that counts.":`2 emails envoyés sont à l'écran dans gmail, tous deux à des prospects. ça compte.`,replay:`rejouer`,"day {n} · at risk":`jour {n} · en danger`,"broken · was {n}":`cassée · était à {n}`,"click to advance":`clique pour avancer`,"advance the growth demo":`faire avancer la démo de croissance`,"done · on your word":`fait · sur parole`,"The AI co-founder":`Le co-fondateur IA`,"you can't ignore.":`impossible à ignorer.`,"It knows what you are building, watches your calendar and the tools you already work in, and settles by itself every task it can actually prove. The ones it cannot prove, it asks you about, straight out.":`Il sait ce que tu construis, regarde ton agenda et les outils dans lesquels tu travailles déjà , et tranche tout seul chaque tâche qu'il peut réellement prouver. Celles qu'il ne peut pas prouver, il te les demande, franchement.`,"tap for sound":`appuie pour le son`,"install the companion":`installe le companion`,"telegram drives your day; the extension proves it. one keystroke captures the page you're on, Crew matches it to your task and checks it off â instead of you writing an update.":`telegram pilote ta journée ; l'extension la prouve. une touche capture la page où tu es, Crew l'associe à ta tâche et la coche â au lieu que tu écrives un compte-rendu.`,"two minutes to load it: the":`deux minutes pour la charger : le`,"walks you through every click, and the extension itself tells you when an update is out.":`te guide clic par clic, et l'extension te prévient elle-même quand une mise à jour sort.`,"read-only by design: one frame, only when you ask, judged once and never stored. it can never click, type or act as you.":`lecture seule par conception : une image, seulement quand tu le demandes, jugée une fois et jamais stockée. elle ne peut jamais cliquer, taper ou agir à ta place.`,"your morning ping has nowhere to land â connect telegram and the day starts itself.":`ton ping du matin n'a nulle part où atterrir â connecte telegram et la journée se lance toute seule.`,"your tasks are still verified by hand â install the extension and one keystroke does it.":`tes tâches sont encore vérifiées à la main â installe l'extension et une touche s'en charge.`,install:`installer`,later:`plus tard`,"the evening report writes itself â that's the status update you never write again.":`le bilan du soir s'écrit tout seul â c'est le compte-rendu que tu n'écris plus jamais.`,"{n} mornings between you and this":`{n} matins entre toi et ça`,"the other half":`l'autre moitié`,"the evening report writes itself â that's the daily status update you never write again.":`le bilan du soir s'écrit tout seul â c'est le compte-rendu quotidien que tu n'écris plus jamais.`,replan:`replanifier`,"â today":`â aujourd'hui`,"move this task to today":`déplacer cette tâche à aujourd'hui`,"move this task to tomorrow":`déplacer cette tâche à demain`,"move this task to a date you pick":`déplacer cette tâche au jour de ton choix`,"this rewrites a scored day: the task vanishes from the record for good, and the day is re-scored without it.":`ceci réécrit une journée déjà comptée : la tâche disparaît de l'historique pour de bon, et la journée est recomptée sans elle.`,"the task moves to the day you pick, back to pending â the day it leaves is re-scored without it.":`la tâche part vers le jour que tu choisis, de nouveau en attente â le jour qu'elle quitte est recompté sans elle.`,space:`espace`,return:`retour`,"morning, Zack. lock today's 3 â send however many you've actually got (up to 10). reply SKIP to skip.\n\n1. [task 1]\n2. [task 2]\n3. [task 3]":`bonjour, Zack. verrouille tes 3 â envoie autant que tu en as vraiment (jusqu'à 10). réponds SKIP pour passer. 36 371. [tâche 1] 382. [tâche 2] 393. [tâche 3]`,"End of day, Zack.\n\nYour 3:\n1. ship the landing page\n2. email the 2 leads\n3. fix the auth bug\n\nWhat shipped?\n⢠DONE â all of them â \n⢠1,2 â numbers you completed\n⢠NONE â nothing today":`Fin de journée, Zack. 40 41Tes 3 priorités : 421. livrer la landing page 432. envoyer email aux 2 prospects 443. corriger le bug auth 45
46Qu'est-ce qui est fait ? 47⢠DONE â toutes â 48⢠1,2 â les numéros complétés 49⢠NONE â rien aujourd'hui`,"1,2":`1,2`,'nice â before I lock these in, what\'s the proof for "ship the landing page"? (2 to confirm)':`nice â avant de verrouiller, c'est quoi la preuve pour "livrer la landing page" ? (2 à confirmer)`,"watch the real thing · 2 min":`regarde le vrai produit · 2 min`,"meetcrew.app":`meetcrew.app`,"ASK IT ANYTHING":`POSE-LUI UNE QUESTION`,"It answers like someone who was in the room.":`Il répond comme quelqu'un qui était dans la pièce.`,"Crew holds what you are building, what stage you are at, what you said you would do this week, and what your calendar actually looks like tonight. So when you ask it a real question, you get a real answer instead of a generic one.":`Crew garde ce que tu construis, où tu en es, ce que tu as dit que tu ferais cette semaine, et ce qu'il y a vraiment dans ton agenda ce soir. Du coup quand tu lui poses une vraie question, tu as une vraie réponse au lieu d'une réponse générique.`,"your company, stage and focus, from onboarding":`ta boîte, ton stade et ton focus, depuis l'onboarding`,"every day you locked, and how each one resolved":`chaque journée que tu as verrouillée, et comment elle a été tranchée`,"your Google Calendar, so it knows the evening is gone":`ton Google Calendar, pour qu'il sache que la soirée est prise`,"the tools you connected, read-only, never posting as you":`les outils que tu as connectés, en lecture seule, jamais pour publier à ta place`,"You asked":`tu as demandé`,"should I push the launch to next week?":`je repousse le lancement à la semaine prochaine ?`,"your calendar has the investor call thursday 6pm. launch before it and you walk in with something live. push it and you walk in pitching a promise. ship monday.":`ton agenda a le call investisseurs jeudi 18h. lance avant et tu arrives avec quelque chose en ligne. repousse et tu arrives en vendant une promesse. livre lundi.`,"FROM YOUR CALENDAR":`DEPUIS TON AGENDA`,"19:30":`19:30`,"dinner · Stripe partnerships":`dîner · partenariats Stripe`,"Thu 18:00":`jeu 18:00`,"investor call · Series A":`call investisseurs · Série A`,"also, you have dinner at 7:30 tonight. don't lock a deep build task for this evening. you won't touch it, and it'll sit there as a miss tomorrow.":`aussi, tu as un dîner à 19h30 ce soir. ne verrouille pas une grosse tâche de dev pour ce soir. tu n'y toucheras pas, et elle sera comptée manquée demain.`,"your plant died â {n} days lost. plant a new one today.":`ta plante est morte â {n} jours perdus. plantes-en une nouvelle aujourd'hui.`,"your plant's dying â finish ALL of today's tasks to save it.":`ta plante se meurt â termine TOUTES tes tâches d'aujourd'hui pour la sauver.`,"your plant's wilting â you have today to revive it. hit your tasks.":`ta plante se fane â tu as aujourd'hui pour la ranimer. fais tes tâches.`,"rest days":`jours de repos`,"days you don't work. Crew won't ask for tasks and your plant won't wilt on these days.":`les jours où tu ne travailles pas. Crew ne demandera pas de tâches et ta plante ne se fanera pas ces jours-là .`,"recurring days off":`jours de repos récurrents`,"one-off day off":`jour de repos ponctuel`,"reason (optional) â e.g. wedding, sick, travel":`raison (optionnel) â ex. mariage, malade, voyage`,"I'm off today":`je suis en repos aujourd'hui`,"I'm off tomorrow":`je suis en repos demain`,"today: off â":`aujourd'hui : repos â`,"tomorrow: off â":`demain : repos â`,remove:`retirer`,Mon:`lun`,Tue:`mar`,Wed:`mer`,Thu:`jeu`,Fri:`ven`,Sat:`sam`,Sun:`dim`,"share my status":`partager mon statut`,"this week":`cette semaine`,"day streak":`jours de série`,shipped:`livré`,"share on X":`partager sur X`,"share on LinkedIn":`partager sur LinkedIn`,"preparing your linkâ¦":`préparation de ton lienâ¦`,"couldn't create a share link â try again":`impossible de créer un lien de partage â réessaie`,"ð± {s}-day build streak on Crew â {p}% shipped this week building {prod}.":`ð± série de {s} jours sur Crew â {p}% livré cette semaine en construisant {prod}.`,"shipped {p}% of my locked priorities this week building {prod}, tracked on Crew.":`j'ai livré {p}% de mes priorités cette semaine en construisant {prod}, suivi sur Crew.`,"â tomorrow":`â demain`,"carry this to tomorrow instead of missing it":`reporte-la à demain au lieu de la rater`,'tip: make each one checkable but not rigid. add a number so it\'s measurable ("outreach to 10 foun
49ders", not "do some outreach") â but keep it about the outcome, not the exact tool ("outreach to 10 solo founders" rather than "send 10 LinkedIn DMs"). vague-but-numbered beats over-specific.':`astuce : rends chaque tâche vérifiable sans être rigide. mets un nombre pour la rendre mesurable (« contacter 10 fondateurs », pas « faire du démarchage ») â mais reste sur le résultat, pas l'outil exact (« contacter 10 fondateurs solo » plutôt que « envoyer 10 DM LinkedIn »). vague-mais-chiffré vaut mieux que trop précis.`,"download the extension (.zip)":`télécharger lâextension (.zip)`,'Not yet on the Chrome Web Store â download the .zip above and unzip it (you get a "crew-companion" folder), then: chrome://extensions â enable Developer mode â Load unpacked â select the crew-companion folder.':`Pas encore sur le Chrome Web Store â télécharge le .zip ci-dessus et décompresse-le (tu obtiens un dossier « crew-companion »), puis : chrome://extensions â active le mode développeur â Charger lâextension non empaquetée â choisis le dossier crew-companion.`,'unzip it â you\'ll get a "crew-companion" folder.':`décompresse-la â tu obtiens un dossier « crew-companion ».`,"open chrome://extensions (or edge://extensions), turn on Developer mode.":`ouvre chrome://extensions (ou edge://extensions), active le mode développeur.`,'click "Load unpacked" and pick the crew-companion folder.':`clique sur « Charger lâextension non empaquetée » et choisis le dossier crew-companion.`,"not on the Chrome Web Store yet â this is the manual install. works on Chrome, Edge, Brave, and Atlas. you can also do this later from Settings.":`pas encore sur le Chrome Web Store â voici lâinstallation manuelle. fonctionne sur Chrome, Edge, Brave et Atlas. tu peux aussi le faire plus tard depuis les Réglages.`,"your free trial is over":`ton essai gratuit est terminé`,"keep your co-founder on call â real verification, streaks, and unlimited chat.":`garde ton co-fondateur à disposition â vérification réelle, séries, et chat illimité.`,"7-day money-back guarantee â cancel any time.":`garantie satisfait ou remboursé 7 jours â annule quand tu veux.`,"The Crew â pod accountability board":`The Crew â le tableau du pod, sans triche`,Stakes:`Enjeux`,"checkout not configured yet.":`paiement pas encore configuré.`,"subscribe to lock today's priorities and keep your streak going.":`abonne-toi pour verrouiller les priorités du jour et garder ta série.`,"subscribe to keep chatting with your co-founder â unlimited, plus real verification and streaks.":`abonne-toi pour continuer à discuter avec ton co-fondateur â illimité, avec vérification réelle et séries.`,"{n} chats left â message us for a top-up.":`{n} chats restants â écris-nous pour une recharge.`,"chat limit reached â message us and we'll top you up.":`limite de chat atteinte â écris-nous et on te recharge.`,"free trial · chat limit reached â subscribe for unlimited":`essai gratuit · limite de chat atteinte â abonne-toi pour lâillimité`,"free trial â {d} days left.":`essai gratuit â {d} jours restants.`,"{n} co-founder chats left.":`{n} chats avec ton co-fondateur restants.`,"chat limit reached.":`limite de chat atteinte.`,"your free trial is over. subscribe to keep locking tasks and chatting.":`ton essai gratuit est terminé. abonne-toi pour continuer à verrouiller des tâches et discuter.`,"subscribe â":`sâabonner â`,"An AI co-founder · morning, midday and evening":`Un co-fondateur IA · matin, midi et soir`,"Crew checks first.":`Crew vérifie d'abord.`,"then it asks.":`ensuite il demande.`,"Lock a few priorities in the morning. Crew goes and reads the evidence itself â commits, deploys, meetings held, payments taken â and settles the ones it can prove. When nothing can confirm a task, it asks you straight out.":`Verrouille quelques priorités le matin. Crew va lire les preuves lui-même â commits, déploiements, rendez-vous tenus, paiements encaissés â et tranche celles qu'il peut prouver. Quand rien ne peut confirmer une tâche, il te le demande franchement.`,"Your word still counts. It just gets filed as your word.":`Ta parole compte toujours. Elle est simplement enregistrée comme ta parole.`,"priorities you lock each morning by default. set it anywhere from 3 to 10.":`priorités que tu verrouilles chaque matin par défaut. règle-le entre 3 et 10.`,"connectors needed to start. a typed note can be the proof.":`connecteur nécessaire pour démarrer. une note écrite peut suffire comme preuve.`,"until launch â free, no card. $19/month for solo once we launch.":`jusqu'au lancement â gratuit, sans carte. 19 $/mois pour solo après le lancement.`,"Lock it in the morning. Answer for it at night.":`Verrouille le matin. Rends des comptes le soir.`,"Three moments a day, every one of them at an hour you set. All three arrive on Telegram, so you can run the entire loop without opening the app once.":`Trois moments par jour, chacun à l'heure que tu fixes. Les trois arrivent sur Telegram : tu peux mener toute la boucle sans jamais ouvrir l'app.`,"You lock the day.":`Tu verrouilles la journée.`,"Crew messages you before your inbox does. You name the few things that actually move the business and lock them in. Three by default; set it anywhere from three to ten, and move the hour wherever you want it.":`Crew t'écrit avant ta boîte mail. Tu nommes les quelques choses qui font vraiment avancer la boîte, et tu les verrouilles. Trois par défaut ; règle-le entre trois et dix, et déplace l'heure où tu veux.`,"Crew checks itself.":`Crew vérifie tout seul.`,"It re-reads whatever your connected tools have done since this morning and quietly resolves anything already proven. Nothing for you to answer. It exists so the evening is a conversation, not a pile.":`Il relit ce que tes connecteurs ont fait depuis ce matin et clôt sans bruit tout ce qui est déjà prouvé. Rien à répondre. Ãa existe pour que le soir soit une conversation, pas une pile.`,"Crew gives a verdict.":`Crew rend son verdict.`,"It reads the day back task by task: proven, taken on your word, or missed. Where it could not tell, it asks you outright, and then it asks about the one you keep pushing to tomorrow.":`Il te relit la journée tâche par tâche : prouvée, prise sur parole, ou ratée. Là où il n'a pas pu trancher, il te le demande franchement, puis il te parle de celle que tu repousses à demain depuis des jours.`,"Proof is the screen you were just working on.":`La preuve, c'est l'écran sur lequel tu travaillais.`,"The companion extension takes one screenshot of the tab you are on and hands it to Crew, which reads it against the task you locked and answers. That is the entire action: a keystroke and a verdict. Nothing to write up, nothing to file, no link to go and find.":`L'extension companion prend une capture de l'onglet où tu es et la transmet à Crew, qui la lit face à la tâche que tu as verrouillée, puis répond. C'est toute l'action, une touche et un verdict. Rien à rédiger, rien à classer, aucun lien à aller chercher.`,crew:`crew`,result:`résultat`,"Press ââ§C (Alt+C on Windows) on the tab that shows the work. One frame is captured and sent: that tab, that moment, nothing else.":`Appuie sur â¥C sur l'onglet qui montre le travail. Une seule image est capturée et envoyée, cet onglet, cet instant, rien d'autre.`,"Reads the frame against the task, cross-checks it against whatever your connected tools did today, and answers in its own words.":`Lit l'image face à la tâche, la recoupe avec ce que tes connecteurs ont fait aujourd'hui, et répond avec ses propres mots.`,"The task is struck through and recorded as verified. If the screen doesn't show what you claimed, Crew says so and the task stays open. There is no button that records it anyway.":`La tâche est barrée et enregistrée comme vérifiée. Si l'écran ne montre pas ce que tu affirmes, Crew te le dit et la tâche reste ouverte, aucun bouton ne permet de l'enregistrer quand même.`,"The companion is not on the Chrome Web Store yet; it comes with onboarding.":`Le companion n'est pas encore sur le Chrome Web Store ; il arrive avec l'accompagnement de départ.`,"It works with nothing connected.":`Ãa marche sans rien connecter.`,"Type what you did and Crew judges the sentence. Send a screenshot, a PDF, a photo, or a voice note to Telegram. Voice is transcribed and judged exactly like typed proof. Too thin to stand up, and Crew tells you so instead of accepting it.":`Ãcris ce que tu as fait et Crew juge la phrase. Envoie une capture, un PDF, une photo ou un vocal sur Telegram, le vocal est transcrit et jugé exactement comme une preuve écrite. Trop mince pour tenir, et Crew te le dit au lieu de l'accepter.`,"Connect a tool and it checks without you.":`Connecte un outil et il vérifie sans toi.`,"Six ship today: GitHub, Vercel, Google Calendar, Stripe, Calendly and Gmail. They cover commits and merged PRs, real deploys, meetings actually held, payments actually taken, mail actually sent. Every one is read-only: Crew reads, and never posts, sends, replies or changes a thing in your accounts.":`Six connecteurs existent aujourd'hui, GitHub, Vercel, Google Calendar, Stripe, Calendly, Gmail, pour les commits et PR fusionnées, les vrais déploiements, les rendez-vous réellement tenus, les paiements réellement encaissés, les mails réellement envoyés. Tous sont en lecture seule : Crew lit, et ne publie, n'envoie, ne répond ni ne modifie jamais quoi que ce soit dans tes comptes.`,"1 left":`encore 1`,"Marking a task done captures this tab once, as proof.":`Marquer une tâche faite c
49apture cet onglet une fois, comme preuve.`,"Mark done":`C'est fait`,Done:`Fait`,"1/3 steps":`1/3 étapes`,"the deploy log for crew.vercel.app is on screen, dated today. that ships it.":`le journal de déploiement de crew.vercel.app est à l'écran, daté d'aujourd'hui, c'est livré.`,"Proof is on another screen or app â":`La preuve est sur un autre écran ou une autre app â`,"Open Crew":`Ouvrir Crew`,"Crew's morning, midday and evening messages land in Telegram, and everything you can do in the app you can do by replying to them. Plain language, no commands to learn. Some founders never open the web app at all.":`Les messages du matin, de midi et du soir arrivent sur Telegram, et tout ce que tu peux faire dans l'app, tu peux le faire en y répondant. En langage normal, aucune commande à apprendre. Certains fondateurs n'ouvrent jamais l'app web.`,"Send a photo, a screenshot or a voice note as proof. Voice is transcribed and judged exactly the same way":`Envoie une photo, une capture ou un vocal comme preuve, le vocal est transcrit et jugé exactement pareil`,"Say you're done and Crew doesn't tick it off. It asks what the proof is, then judges your answer":`Dis que c'est fait et Crew ne coche rien, il demande quelle est la preuve, puis juge ta réponse`,"Change your ping times, your language or how many tasks you lock, in one sentence":`Change tes heures de rappel, ta langue ou le nombre de tâches que tu verrouilles, en une phrase`,"Take a rest day, or say you're travelling, offline, or in a crisis week. Crew goes quiet and the day doesn't count against you":`Prends un jour de repos, ou dis que tu voyages, que tu es hors ligne ou en semaine de crise, Crew se tait et la journée ne te sera pas comptée`,"Three ways a task can end.":`Trois façons de finir une tâche.`,"Verified means something other than your own word backed it up, and the badge names what did. Self-attested means Crew asked, you said you did it, and nothing could confirm it. The day still counts toward your streak, and never toward your verified record. Missed is missed. Crew keeps the three apart instead of flattening them into a tick.":`Vérifiée veut dire qu'autre chose que ta parole l'a confirmée, et le badge dit quoi. Sur parole veut dire que Crew a demandé, que tu as dit l'avoir fait, et que rien n'a pu le confirmer, la journée compte quand même pour ta série, et jamais pour ton historique vérifié. Ratée, c'est ratée. Crew garde les trois distinctes au lieu de les aplatir en une case cochée.`,"This is the list itself, as it looks on your Today page.":`C'est la liste elle-même, telle qu'elle apparaît sur ta page Aujourd'hui.`,"A day counts when two thirds of it did.":`Une journée compte quand les deux tiers ont compté.`,"The streak is not a login count. A day only counts once at least two thirds of the priorities you locked that morning are resolved done, and every one of those had to get past Crew first. Break it and nothing quietly resets: the plant stays grey at the height it reached, until you start a new one.":`La série n'est pas un compteur de connexions. Une journée ne compte que si au moins deux tiers des priorités verrouillées le matin sont réglées comme faites, et chacune a dû passer devant Crew. Casse-la et rien ne se réinitialise en douce : la plante reste grise à la hauteur atteinte, jusqu'à ce que tu en plantes une nouvelle.`,"a seed on day one, a new leaf every day after, a tree past day ten":`une graine le premier jour, une nouvelle feuille chaque jour ensuite, un arbre après le dixième`,"self-attested days keep the streak alive. they just never count as verified":`les journées sur parole gardent la série en vie, elles ne comptent simplement jamais comme vérifiées`,"rest days you set, and travel or crisis weeks you declare, are skipped rather than counted as misses":`les jours de repos que tu fixes, et les semaines de voyage ou de crise que tu déclares, sont sautés au lieu d'être comptés comme ratés`,"miss once and it wilts with a day to revive it; miss again and every task must clear":`rate une fois et elle se fane, avec un jour pour la ranimer ; rate encore et toutes les tâches devront passer`,"It has a view about your business.":`Il a un avis sur ta boîte.`,"Crew is not a tracker with a chat box bolted on. Every message it sends is composed against your goal, what your business actually is, which tools are live, what you locked today and tomorrow, and what those tools have done since this morning. That is
49why it can propose a task instead of asking you for one.":`Crew n'est pas un tracker avec un chat greffé dessus. Chaque message qu'il envoie est composé à partir de ton objectif, de ce qu'est réellement ta boîte, des connecteurs actifs, de ce que tu as verrouillé aujourd'hui et demain, et de ce que ces outils ont fait depuis ce matin. C'est pour ça qu'il peut te proposer une tâche au lieu de t'en réclamer une.`,"It forms its own view first. Connected-tool data, then a public web check, and only then does it ask you, in that order, every time.":`Il se fait son propre avis d'abord. Les données des connecteurs, puis une vérification publique sur le web, et seulement ensuite il te demande, dans cet ordre, à chaque fois.`,"It argues the verdict. Send proof and Crew tells you in its own words whether it holds up, and names the same-day signals it cross-checked. Thin proof is refused. You improve it, you don't override it.":`Il argumente son verdict. Envoie une preuve et Crew te dit avec ses propres mots si elle tient, et nomme les signaux du jour qu'il a recoupés. Une preuve trop mince est refusée, tu l'améliores, tu ne passes pas outre.`,"It proposes tomorrow. Ask what to work on and it names one specific, measurable thing drawn from your goal and your business context, then waits for a yes before locking anything.":`Il propose demain. Demande-lui sur quoi travailler et il nomme une chose précise et mesurable, tirée de ton objectif et du contexte de ta boîte, pu
49is il attend ton oui avant de verrouiller quoi que ce soit.`,"It renegotiates. The day changed: swap or drop a task with one line of reason, and it reads as changed rather than missed. Twice a day. The third time is a miss.":`Il renégocie. La journée a changé : remplace ou abandonne une tâche avec une ligne d'explication, et ça se lit comme modifiée, pas ratée. Deux fois par jour. La troisième compte comme ratée.`,"It comes after you. Two quiet days and it messages you naming the last thing you left open. Four days and it tries once more, then stops for good rather than nagging you forever.":`Il vient te chercher. Deux jours de silence et il t'écrit en nommant la dernière chose que tu as laissée ouverte. Quatre jours et il tente une dernière fois, puis s'arrête définitivement au lieu de te harceler.`,"It never acts as you. Every connector is read-only. Crew reads your tools; it cannot post, send, reply, pay or change anything in them.":`Il n'agit jamais à ta place. Chaque connecteur est en lecture seule. Crew lit tes outils ; il ne peut ni publier, ni envoyer, ni répondre, ni payer, ni rien y modifier.`,"foun
49der context":`contexte fondateur`,goal:`objectif`,"connected (live)":`connectés (en direct)`,"github activity":`activité github`,calendar:`agenda`,"assembled fresh on every message it sends you.":`reconstruit à neuf à chaque message qu'il t'envoie.`,"500 paying users by December":`500 utilisateurs payants d'ici décembre`,"B2B SaaS, selling to design agencies":`SaaS B2B, vendu aux agences de design`,"1. ship the landing page · 2. email the 2 leads · 3. fix the auth bug":`1. livrer la landing page · 2. écrire aux 2 prospects · 3. corriger le bug auth`,"7 commits · 1 PR merged · 0 on the auth branch":`7 commits · 1 PR fusionnée · 0 sur la branche auth`,"2 calls held · 1 no-show":`2 appels tenus · 1 absence`,"A pod is exactly two people. Your completion rate, your streak and your counts sit on their board every day, and theirs on yours. What never crosses over is the work itself: your card shows your tasks, their card shows numbers.":`Un pod, c'est exactement deux personnes. Ton taux de réussite, ta série et tes compteurs sont sur leur tableau chaque jour, et les leurs sur le tien. Ce qui ne traverse jamais, c'est le travail lui-même, ta carte montre tes tâches, la leur montre des chiffres.`,"A duo, not an audience. A pod refuses a third member outright":`Un duo, pas un public, un pod refuse net un troisième membre`,"They see your rate, your streak and your counts, and never the text of a single task":`Ils voient ton taux, ta série et tes compteurs, et jamais le texte d'une seule tâche`,"Break a long streak and they hear about it. Past 21 days, Crew warns your partner the night it is at risk":`Casse une longue série et ils l'apprennent, au-delà de 21 jours, Crew prévient ton binôme le soir où elle est en danger`,"4 shipped this week · 2 slipped":`4 livrées cette semaine · 2 manquées`,"Nobody notices when a solo founder quietly stops shipping.":`Personne ne remarque quand un fondateur solo arrête discrètement de livrer.`,"That's the whole thing. A co-founder notices, not because they're checking up on you, but because they're in it, and the third week of the same unshipped feature is impossible to miss from the next desk over. Alone, there is no next desk. You can have a productive-feeling month and nobody, you included, will say out loud that nothing moved.":`C'est tout le sujet. Un co-fondateur le remarque, pas parce qu'il te surveille, mais parce qu'il est dedans, et que la troisième semaine sur la même fonctionnalité non livrée est impossible à rater depuis le bureau d'à côté. Seul, il n'y a pas de bureau d'à côté. Tu peux passer un mois qui donne l'impression d'être productif sans que personne, toi compris, ne dise à voix haute que rien n'a bougé.`,"I built Crew because I kept catching myself busy and not moving. So it keeps the one record that can't be talked around: what you said you'd do that morning, and what actually turned up. It reads the commits. It checks the calendar. At 8:30 it asks about the task you've dodged four days running, and it doesn't accept ":`J'ai construit Crew parce que je me surprenais sans arrêt occupé sans avancer. Alors il tient le seul relevé qu'on ne peut pas contourner : ce que tu as dit que tu ferais ce matin-là , et ce qui est réellement arrivé. Il lit les commits. Il regarde l'agenda. à 20h30 il te parle de la tâche que tu évites depuis quatre jours, et il n'accepte pas `,"been busy":`j'étais débordé`," as an answer.":` comme réponse.`,"It isn't here to organise your work. It's here to notice.":`Il n'est pas là pour organiser ton travail. Il est là pour remarquer.`,"Founder · Crew":`Fondateur · Crew`,"free until launch, no card. $19/month once we launch, cancelled from settings whenever you want.":`gratuit jusqu'au lancement, sans carte. 19 $/mois après le lancement, résiliable depuis les réglages quand tu veux.`,"how it works":`comment ça marche`,"the crew":`the crew`,vision:`vision`,"join waitlist":`rejoindre la liste`,"Your accountability co-founder · morning and evening":`Ton co-fondateur qui te demande des comptes · matin et soir`,"Crew doesn't ask":`Crew ne te demande pas`,"if you did it.":`si tu l'as fait.`,"Lock a few priorities in the morning. In the evening Crew checks them against real evidence â a commit, a link, a screenshot, a voice note â and records the day as verified, attested, or missed.":`Verrouille quelques priorités le matin. Le soir, Crew les confronte à de vraies preuves â un commit, un lien, une capture, un vocal â et enregistre la journée : vérifiée, sur parole, ou ratée.`,"Ticking a box is not proof.":`Cocher une case,
49ce n'est pas une preuve.`,"Crew · Evening · 8:30":`Crew · Soir · 20h30`,"THE DAILY LOOP":`LA BOUCLE QUOTIDIENNE`,"Lock in the morning. Answer for it at night.":`Verrouille le matin. Rends des comptes le soir.`,"Three moments a day, all of them at times you choose. You can run the whole thing from Telegram without ever opening the app.":`Trois moments par jour, tous aux heures que tu choisis. Tu peux tout piloter depuis Telegram sans jamais ouvrir l'app.`,"7:30":`7h30`,"13:00":`13h`,"20:30":`20h30`,"Lock the day.":`Verrouille la journée.`,"Crew pings you before your inbox does. You name the few things that actually matter and lock them in. Three by default â set anywhere from three to ten, and move the time wherever you want it.":`Crew te ping avant ta boîte mail. Tu nommes les quelques choses qui comptent vraiment et tu les verrouilles. Trois par défaut â règle-les de trois à dix, et déplace l'heure où tu veux.`,"Midday sweep.":`Passe de midi.`,"Crew re-reads whatever evidence exists and quietly ticks off anything already done. Nothing to answer â it just means the evening isn't a pile.":`Crew relit les preuves disponibles et coche en silence tout ce qui est déjà fait. Rien à répondre â ça évite juste que le soir soit une pile.`,"The verdict.":`Le verdict.`,"Crew reads the day back: what's verified, what you're only attesting to, what was missed. Then it asks about the thing you keep pushing.":`Crew te relit la journée : ce qui est vérifié, ce qui tient seulement sur ta parole, ce qui est raté. Puis il te parle de la chose que tu repousses.`,PROOF:`PREUVES`,"Crew works with zero connectors.":`Crew marche avec zéro connecteur.`,"You don't have to plug Crew into anything. Proof is whatever you can show: a written note, a link Crew opens once to check, a screenshot or a PDF, a photo or a voice note sent to Telegram. Connect a tool only if you'd rather that part happened without you.":`Tu n'es obligé de brancher Crew sur rien. Une preuve, c'est ce que tu peux montrer : une note écrite, un lien que Crew ouvre une fois pour vérifier, une capture ou un PDF, une photo ou un vocal envoyé sur Telegram. Connecte un outil seulement si tu préfères que cette partie se fasse sans toi.`,"Nothing connected":`Sans rien connecter`,"Write what you did â Crew reads it and decides whether it holds up.":`Ãcris ce que tu as fait â Crew le lit et décide si ça tient.`,"Paste a link. Crew opens that exact page once to check it, and nothing else.":`Colle un lien. Crew ouvre exactement cette page, une fois, pour la vérifier â et rien d'autre.`,"Send a screenshot, a PDF, a photo, or a voice note. Voice is transcribed and judged like any other proof.":`Envoie une capture, un PDF, une photo ou un vocal. Le vocal est transcrit puis jugé comme n'importe quelle preuve.`,"Press Option+C in Chrome and the tab you are on becomes the proof.":`Appuie sur Option+C dans Chrome et l'onglet où tu es devient la preuve.`,"If you do connect something":`Si tu connectes quelque chose`,"Six connectors ship today: GitHub, Vercel, Google Calendar, Stripe, Calendly, Gmail.":`Six connecteurs sont livrés aujourd'hui : GitHub, Vercel, Google Agenda, Stripe, Calendly, Gmail.`,"All of them are read-only. Crew reads. It never posts, sends, replies, or changes anything in your tools.":`Tous en lecture seule. Crew lit. Il ne publie rien, n'envoie rien, ne répond à rien et ne modifie rien dans tes outils.`,"Commits and merged PRs, real deploys, meetings actually held, payments actually taken, emails actually sent.":`Commits et PR mergées, vrais déploiements, réunions réellement tenues, paiements réellement encaissés, e-mails réellement envoyés.`,"Disconnect any of them at any time; the work you already recorded stays.":`Déconnecte-les quand tu veux ; le travail déjà enregistré reste.`,"Morning · 7:30":`Matin · 7h30`,"morning. before you open anything else, what are the 3 things that actually move the needle today? not busywork. the 3 that scare you a little.":`bonjour. avant d'ouvrir quoi que ce soit, quelles sont les 3 choses qui font vraiment avancer les choses aujourd'hui ? pas des tâches banales. les 3 qui te font un peu peur.`,"ship the landing page, email the 2 leads, fix the auth bug":`livrer la landing page, envoyer un email aux 2 prospects, corriger le bug auth`,"good. landing page is the one that matters. do it first while your brain is fresh. the auth bug is comfort work, you'll hide in it.":`bien. la landing page est celle qui compte, fais-la en premier pendant que ton cerveau est frais. le bug auth est un travail de confort, tu vas t'y perdre.`,"ship ugly, fix live.":`livre imparfait, corrige en direct.`,"Evening · 8:30":`Soir · 20h30`,"8:30. let's look at what actually happened today.":`20h30. regardons ce qui s'est vraiment passé aujourd'hui.`,"TODAY'S RECEIPTS":`REÃUS DU JOUR`,"ship the landing page":`livrer la landing page`,"3 commits · merged 4:12pm":`3 commits · fusionné 16h12`,"email the 2 leads":`envoyer un email aux 2 prospects`,"47min call · calendar · 3pm":`appel 47min · agenda · 15h`,"fix the auth bug":`corriger le bug auth`,"0 commits · day 4 running":`0 commits · 4e jour consécutif`,"2 of 3. the auth bug is day 4. that's not a backlog item. what's blocking you?":`2 sur 3. le bug auth est au 4e jour, ce n'est pas juste du backlog. qu'est-ce qui te bloque ?`,"honestly scared of breaking prod":`honnêtement, j'ai peur de casser la prod`,"good. that's real. tomorrow it goes first. no hiding.":`bien. c'est réel. demain ça passe en premier. plus de fuite.`,"THE RECORD":`L'HISTORIQUE`,"Three ways a day can end.":`Une journée peut finir de trois façons.`,"Verified means something other than your own word backed it up. Attested means you said you did it and nothing could confirm it â it still counts toward your streak, and never toward your verified record. Missed is missed. Crew keeps the three apart instead of blurring them into a tick.":`Vérifiée : autre chose que ta parole l'a confirmée. Sur parole : tu dis l'avoir fait et rien n'a pu le confirmer â ça compte quand même pour ta série, jamais pour ton historique vérifié. Ratée, c'est ratée. Crew garde les trois distinctes au lieu de tout réduire à une coche.`,"WED JUN 17 · EVENING REVIEW":`MER 17 JUIN · BILAN DU SOIR`,"Today's record":`Historique du jour`,"â² 12-day streak":`â² série de 12 jours`,"1 verified · 1 attested":`1 vérifiée · 1 sur parole`,VERIFIED:`VÃRIFIÃE`,ATTESTED:`SUR PAROLE`,MISSED:`RATÃE`,"call 5 users":`appeler 5 utilisateurs`,"3 commits to main · PR merged 4:12 PM · GitHub":`3 commits sur main · PR mergée 16h12 · GitHub`,'your note: "5 calls, notes in the doc" â nothing could confirm it':`ta note : « 5 appels, notes dans le doc » â rien n'a pu le confirmer`,"no proof given · 4th day carried":`aucune preuve · reportée pour le 4e jour`,"attested days keep your streak. only verified days count toward your verified record.":`les journées sur parole gardent ta série. seules les j
49ournées vérifiées comptent dans ton historique vérifié.`,"MOMENTUM & HABIT":`MOMENTUM & HABITUDE`,"Consistency you can watch grow.":`La régularité que tu regardes pousser.`,"Momentum isn't a feeling â it's a habit you can watch grow. Every day you lock in, your plant grows a little more. Let it slip and it doesn't quietly reset â it wilts, gray, right where it broke, until you plant a new one.":`Le momentum n'est pas un sentiment â c'est une habitude que tu regardes pousser. Chaque jour verrouillé fait grandir ta plante un peu plus. Si tu lâches, elle ne se remet pas discrètement à zéro â elle fane, grise, là où ça a cassé, jusqu'à ce que tu en plantes une nouvelle.`,"starts as a seed on day one â a new leaf every day after":`commence comme une graine le premier jour â une nouvelle feuille chaque jour ensuite`,"past 10 days it stops being a plant and becomes a tree":`passé 10 jours, ce n'est plus une plante â ça devient un arbre`,"turns amber when today's at risk of slipping away":`devient ambre quand la journée risque de t'échapper`,"breaks â and stays broken â if the streak resets":`se brise â et le reste â si la série se réinitialise`,"OUR VISION":`NOTRE VISION`,'"Having a co-founder means having someone to push against â someone who makes you sharper, more honest, and harder to stop. In the age of AI, there\'s no reason a solo founder should have to build without that. We built Crew to be exactly that co-founder."':`« Avoir un co-fondateur, c'est avoir quelqu'un en face â quelqu'un qui te rend plus affûté, plus honnête, plus dur à arrêter. à l'ère de l'IA, aucune raison qu'un fondateur solo construise sans ça. On a créé Crew pour être exactement ce co-fondateur. »`,"CEO & Founder · Crew":`CEO & fondateur · Crew`,"THE CREW · PODS":`THE CREW · PODS`,"One other founder, watching the same board.":`Un autre fondateur, sur le même tableau.`,"A pod is exactly two people. Your completion rate, your streak and your counts appear on their board every day, and theirs on yours. What you never hand over is the work itself.":`Un pod, c'est exactement deux personnes. Ton taux de complétion, ta série et tes compteurs apparaissent chaque jour sur son tableau, et les siens sur le tien. Ce que tu ne donnes jamais, c'est le travail lui-même.`,"A duo, not an audience â a pod refuses a third member":`Un duo, pas un public â un pod refuse un troisième membre`,"They see your rate, your streak and your counts. They never see the text of your tasks":`Il voit ton taux, ta série et tes compteurs. Il ne voit jamais le texte de tes tâches`,"Drift is visible â dodging a task shows up on their side too":`La dérive se voit â esquiver une tâche apparaît aussi de son côté`,"Join with a 6-character invite code. Pods are part of the paid plans":`Rejoins avec un code d'invitation à 6 caractères. Les pods font partie des offres payantes`,you:`toi`,"2 founders":`2 fondateurs`,"write the product spec":`rédiger la spec produit`,"2 of 3 done · task text stays private":`2 sur 3 faites · le texte des tâches reste privé`,TELEGRAM:`TELEGRAM`,"The whole loop fits in a chat.":`Toute la boucle tient dans une conversation.`,"Crew's morning, midday and evening messages land in Telegram â and everything you can do in the app, you can do by replying to them. Plain language, no commands to learn. Some founders never open the web app at all.":`Les messages du matin, de midi et du soir arrivent sur Telegram â et tout ce que tu peux faire dans l'app, tu peux le faire en y répondant. En langage normal, aucune commande à apprendre. Certains fondateurs n'ouvrent jamais l'app web.`,"Lock the day, then add, reword, carry, renegotiate or drop a task by saying so":`Verrouille la journée, puis ajoute, reformule, reporte, renégocie ou abandonne une tâche en le disant`,"Send a photo, a screenshot or a voice note as proof â voice is transcribed and judged the same way":`Envoie une photo, une capture ou un vocal comme preuve â le vocal est transcrit et jugé pareil`,"Change your ping times, your language or how many tasks you lock, in a sentence":`Change tes heures de ping, ta langue ou le nombre de tâches verrouillées, en une phrase`,"Take a rest day, or say y
49ou're travelling, offline, or in a crisis week â Crew goes quiet":`Prends un jour de repos, ou dis que tu voyages, que tu es hors ligne ou en semaine de crise â Crew se tait`,"Flags drift when a task is dodged 2+ days":`Signale la dérive quand une tâche est évitée 2+ jours`,"THE VISION":`LA VISION`,"Built for founders done lying to themselves.":`Pour les fondateurs fatigués de se mentir.`,"I built Crew because I kept catching myself busy but not moving. Productive-feeling weeks that shipped nothing. I needed something that couldn't be lied to â that read the commit history, checked the calendar, and asked the hard question at 8:30 PM: ":`J'ai créé Crew parce que je me retrouvais constamment occupé sans avancer. Des semaines qui semblaient productives mais ne livraient rien. Il me fallait quelque chose à qui on ne pouvait pas mentir â qui lisait l'historique des commits, vérifiait l'agenda, et posait la question difficile à 20h30 : `,"was today enough?":`est-ce que cette journée était suffisante ?`,"Most productivity tools help you organize your work. Crew makes you face it. The co-founder who doesn't let you redefine \"making progress\" to mean opening Notion. The one who noticed you've dodged the same task four days in a row and isn't going to pretend otherwise.":`La plupart des outils de productivité t'aident à organiser ton travail. Crew t'oblige à le regarder en face. Le co-fondateur qui ne te laisse pas redéfinir « avancer » en « ouvrir Notion ». Celui qui a vu que tu esquives la même tâche depuis quatre jours et qui ne va pas faire semblant.`,"The founders who ship aren't the ones with better tools. They're the ones who stopped hiding from the work.":`Les fondateurs qui livrent ne sont pas ceux qui ont de meilleurs outils. Ce sont ceux qui ont arrêté de fuir le travail.`,"\"the difference between a founder who ships and one who doesn't isn't talent â it's the willingness to face the day honestly, every single night.\"":`« la différence entre un fondateur qui livre et un qui ne le fait pas n'est pas le talent â c'est la volonté d'affronter la journée honnêtement, chaque soir. »`,"[email protected]":`[email protected]`,"Get early access":`Obtenir un accès anticipé`,"Join the waitlist":`Rejoindre la liste d'attente`,"Company name":`Nom de ta boîte`,"e.g. Replyflow, Inkforge":`ex. Replyflow, Inkforge`,"Your role":`Ton rôle`,"Select roleâ¦":`Choisis un rôleâ¦`,"e.g. Head of Product, Investorâ¦":`ex. Directeur Produit, Investisseurâ¦`,"How did you hear about Crew?":`Comment as-tu entendu parler de Crew ?`,"Selectâ¦":`Choisisâ¦`,"Tell us whereâ¦":`Dis-nous oùâ¦`,"Phone number":`Numéro de téléphone`,"e.g. +1 415 555 0100":`ex. +33 6 12 34 56 78`,optional:`optionnel`,recommended:`recommandé`,"â back":`â retour`,"Complete signup â":`Finaliser l'inscription â`,"savingâ¦":`enregistrementâ¦`,"that email looks off":`cet email semble incorrect`,"add your company name":`ajoute le nom de ta boîte`,"select your role":`choisis ton rôle`,"please specify your role":`précise ton rôle`,"please specify how you heard about Crew":`précise où tu as entendu parler de Crew`,"something went wrong. try again":`un truc a raté, réessaie`,"you're in.":`c'est bon.`,"morning ping lands at 7:30 tomorrow.":`ton premier ping arrive demain à 7h30.`,"Privacy Policy":`Politique de confidentialité`,"Terms of Service":`Conditions d'utilisation`,Compliance:`Conformité`,"work in claude, chatgpt or cursor?":`tu travailles dans claude, chatgpt ou cursor ?`,"on claude code, add the capture skill so it logs what you commit to, without being asked:":`sur claude code, ajoute le skill de capture pour qu'il enregistre ce sur quoi tu t'engages, sans qu'on lui demande :`,"Your record, inside {client}.":`ton historique, dans {client}.`,"Ask what you shipped this week and get an answer from receipts, not memory. Lock tomorrow without leaving the chat.":`demande ce que tu as livré cette semaine : la réponse vient des preuves, pas de la mémoire. verrouille demain sans quitter la conversation.`,"Choose your assistant":`choisis ton assistant`,"Copy this":`copie ceci`,"Add it to {client}":`ajoute-le à {client}`,"What it can and cannot do":`ce qu'il peut et ne peut pas faire`,"connector URL":`lien du connecteur`,"terminal command":`commande terminal`,"mcp.json":`mcp.json`,"~/.gemini/settings.json":`~/.gemini/settings.json`,".vscode/mcp.json":`.vscode/mcp.json`,"m
49cp_config.json":`mcp_config.json`,"Settings â Connectors â Add custom connector.":`Réglages â Connecteurs â Ajouter un connecteur personnalisé.`,"Paste the URL and click Add.":`colle le lien et clique sur Ajouter.`,"Click Connect, approve the Crew screen, done.":`clique sur Connecter, approuve l'écran Crew, c'est fait.`,"Open Claude connectors":`ouvrir les connecteurs Claude`,"Same in the desktop app and on claude.ai. No token to paste â Crew asks you to sign in.":`identique dans l'app bureau et sur claude.ai. aucun jeton à coller : Crew te demande de te connecter.`,"Run the command in your terminal.":`lance la commande dans ton terminal.`,"Run /mcp to confirm Crew is connected.":`lance /mcp pour vérifier que Crew est connecté.`,"The only client where the capture skill below does anything.":`le seul client où le skill de capture ci-dessous sert à quelque chose.`,"Settings â Apps â turn on Developer mode.":`Réglages â Apps â active le mode développeur.`,"Add a custom connector and paste the URL.":`ajoute un connecteur personnalisé et colle le lien.`,"Approve the Crew screen.":`approuve l'écran Crew.`,"Open ChatGPT":`ouvrir ChatGPT`,"Needs Plus, Pro, Business or Enterprise. On a work account an admin can switch Developer mode off.":`nécessite Plus, Pro, Business ou Enterprise. sur un compte pro, un admin peut désactiver le mode développeur.`,"Add Crew as a remote MCP server in your Codex config.":`ajoute Crew comme serveur MCP distant dans ta config Codex.`,"Approve the Crew screen when it opens.":`approuve l'écran Crew quand il s'ouvre.`,"Codex uses the same remote MCP support as the rest of OpenAI's tooling.":`Codex utilise le même support MCP distant que le reste des outils OpenAI.`,"Settings â MCP â Add new server.":`Réglages â MCP â Ajouter un serveur.`,"Paste the block, or add it to .cursor/mcp.json.":`colle le bloc, ou ajoute-le à .cursor/mcp.json.`,"Open ~/.gemini/settings.json.":`ouvre ~/.gemini/settings.json.`,"Add Crew under mcpServers.":`ajoute Crew sous mcpServers.`,"Restart the CLI; it opens a browser once to approve.":`redémarre le CLI ; il ouvre le navigateur une fois pour l'approbation.`,"Gemini speaks remote MCP through the CLI and the SDKs. The consumer Gemini app does not take custom connectors.":`Gemini parle MCP distant via le CLI et les SDK. l'app grand public Gemini n'accepte pas de connecteurs personnalisés.`,"Create .vscode/mcp.json in your project.":`crée .vscode/mcp.json dans ton projet.`,"Paste the block and reload the window.":`colle le bloc et recharge la fenêtre.`,"Open the MCP settings and edit the config.":`ouvre les réglages MCP et modifie la config.`,"Add Crew, then refresh the server list.":`ajoute Crew, puis rafraîchis la liste des serveurs.`,"Read your tasks, goals, streak and receipts":`lire tes tâches, objectifs, série et preuves`,"Lock tasks, edit them, carry them forward":`verrouiller des tâches, les modifier, les reporter`,"Break a task into steps":`découper une tâche en étapes`,"Mark a past day done â a closed day stays closed":`cocher un jour passé : un jour clos reste clos`,"Write a verdict. Proof goes to the judge":`écrire un verdict. la preuve passe par le juge`,"Touch billing, your plan, or your account":`toucher à la facturation, ton offre ou ton compte`,"Every row it writes is tagged as agent-written, so your record still says who did what. Revoke any time in Settings.":`chaque ligne qu'il écrit est marquée comme écrite par un agent : ton historique dit toujours qui a fait quoi. révocable à tout moment dans les réglages.`,"Claude Code only. It is a file on your machine, not part of the connector â MCP cannot install files, and it should not be able to.":`Claude Code uniquement. c'est un fichier sur ta machine, pas une partie du connecteur : MCP ne peut pas installer de fichiers, et c'est très bien ainsi.`,"read it before you run it":`lis-le avant de le lancer`,"Add the capture skill":`ajoute le skill de capture`,"The connector lets your assistant reach Crew when you ask. The skill is what makes it act without being asked: it notices when you commit to real work mid-conversation and adds it, in one line.":`le connecteur permet à ton assistant d'atteindre Crew quand tu lui demandes. le skill est ce qui le fait agir sans qu'on lui demande : il repère quand tu t'engages sur du vrai travail en pleine conversation et l'ajoute, en une ligne.`,"This is the difference between a tool you remember to use and one that keeps up with you. One command, Claude Code only.":`c'est la différence entre un outil dont tu dois te souvenir et un outil qui te suit. une commande, Claude Code uniquement.`,"how should it check? pick any that fit â you can add more later.":`comment doit-il vérifier ? coche ce qui te correspond, tu pourras en ajouter plus tard.`,"my tools":`mes outils`,"github, stripe, calendar, gmail and 28 more â commits, payments, meetings":`github, stripe, agenda, gmail et 28 autres : commits, paiements, rendez-vous`,"my browser":`mon navigateur`,"the companion extension proves work on pages no API can reach":`l'extension prouve le travail sur des pages qu'aucune API ne voit`,"my ai assistant":`mon assistant ia`,"claude, chatgpt, cursor and others read and update crew directly":`claude, chatgpt, cursor et les autres lisent et mettent à jour crew directement`,"a screenshot, photo or voice note":`une capture, une photo ou un vocal`,"for work nothing digital can prove â judged the same way as a commit":`pour le travail qu'aucun outil ne peut prouver : jugé comme un commit`,"nothing picked yet â crew will still run, it will just take your word until a source exists.":`rien de coché : crew fonctionnera quand même, il te croira sur parole tant qu'aucune source n'existe.`,"Request a demo":`demander une démo`,"api access":`accès api`,"Connect Crew to Claude, ChatGPT or any MCP client. Most people should use the connector link, which handles this for you â mint a token by hand only for a script or a client that cannot do OAuth.":`branche Crew à Claude, ChatGPT ou n'importe quel client MCP. le lien de connexion fait tout ça pour toi : ne crée un jeton à la main que pour un script ou un client incapable de faire de l'OAuth.`,"connector setup":`configurer le connecteur`,"Copy this now. It is stored as a hash and can never be shown again.":`copie-le maintenant. il est stocké sous forme de hash et ne pourra plus jamais être affiché.`,revoked:`révoqué`,"last used":`dernier usage`,"never used":`jamais utilisé`,revoke:`révoquer`,"no tokens yet":`aucun jeton pour le moment`,"new read-only token":`n
49ouveau jeton lecture seule`,"new read/write token":`nouveau jeton lecture/écriture`,"Revoke this token? Anything using it stops working immediately.":`révoquer ce jeton ? tout ce qui l'utilise cesse de fonctionner immédiatement.`,"AI AGENTS":`AGENTS IA`,"Your AI already knows what you shipped.":`ton IA sait déjà ce que tu as livré.`,"Crew speaks MCP, so the assistant you already have open can read your record and lock your day. Ask it what you shipped this week and it answers from receipts, not memory.":`Crew parle MCP : l'assistant que tu as déjà ouvert peut lire ton historique et verrouiller ta journée. demande-lui ce que tu as livré cette semaine, il répond avec des preuves, pas de mémoire.`,"It can lock tasks, carry them and record proof. It cannot mark a past day done, write its own verdict, or touch your billing â and every row it writes is tagged as agent-written.":`il peut verrouiller des tâches, les reporter et enregistrer des preuves. il ne peut pas cocher un jour passé, écrire son propre verdict, ni toucher à ta facturation, et tout ce qu'il écrit est marqué comme écrit par un agent.`,"Set it up â takes a minute":`le brancher, une minute suffit`,"â Crew":`â Crew`,"Put Crew inside the assistant you already use.":`mets Crew dans l'assistant que tu utilises déjà .`,"One link. Your tasks, goals, streak and receipts become tools your assistant can read and write â without leaving the chat you are already in.":`un seul lien. tes tâches, tes objectifs, ta série et tes preuves deviennent des outils que ton assistant peut lire et écrire, sans quitter la conversation.`,"Copy your connector URL":`copie ton lien de connexion`,"The same URL works everywhere. There is nothing to install and no key to paste â Crew asks you to sign in and approve it.":`le même lien marche partout. rien à installer, aucune clé à coller : Crew te demande de te connecter et d'approuver.`,copied:`copié`,"Add it where you work":`ajoute-le là où tu travailles`,"What it can do, and what it will refuse":`ce qu'il peut faire, et ce qu'il refusera`,"Read your tasks, goals, streak, receipts and settings":`lire tes tâches, objectifs, série, preuves et réglages`,"Lock new tasks, edit them, carry them forward":`verrouiller de nouvelles tâches, les modifier, les reporter`,"Break a task into steps and tick them off":`découper une tâche en étapes et les cocher`,"Record proof against a task":`enregistrer une preuve sur une tâche`,"Write a verdict. Proof goes to the judge, always":`écrire un verdict. la preuve passe toujours par le juge`,"Touch billing, your plan, or delete your account":`toucher à la facturation, à ton offre, ou supprimer ton compte`,"Every row an assistant writes is tagged as agent-written, so your record still says who did what. You can revoke access any time in Settings.":`chaque ligne écrite par un assistant est marquée comme telle, donc ton historique dit toujours qui a fait quoi. tu peux révoquer l'accès à tout moment dans les réglages.`,"Optional: capture commitments automatically":`optionnel : capturer les engagements automatiquement`,"This is a separate file, not part of the connector. It teaches Claude Code to notice when you commit to real work in conversation and add it to Crew, in one line, without being asked.":`c'est un fichier séparé, pas une partie du connecteur. il apprend à Claude Code à repérer quand tu t'engages sur du vrai travail et à l'ajouter à Crew, en une ligne, sans qu'on lui demande.`,"Claude Code only. The connector above is what everything else uses.":`Claude Code uniquement. tout le reste passe par le connecteur ci-dessus.`,"read the skill first":`lire d'abord le skill`,"It captures at most three times per conversation, never on questions or brainstorms, and never marks anything done.":`il capture au maximum trois fois par conversation, jamais sur une question ou un brainstorm, et ne coche jamais rien.`,"Stuck? Every step above is reversible, and disconnecting removes access immediately.":`bloqué ? chaque étape ci-dessus est réversible, et se déconnecter coupe l'accès immédiatement.`,"Manage connections in Settings":`gérer les connexions dans les réglages`,"work in claude or chatgpt?":`tu travailles dans claude ou chatgpt ?`,"connect crew there too":`branche crew là aussi`,"â one link, and
49you can lock a day without opening crew at all.":`â un lien, et tu verrouilles ta journée sans même ouvrir crew.`,"Checking your sessionâ¦":`vérification de ta sessionâ¦`,"Sign in to connect":`connecte-toi pour continuer`,"You need to be signed in to Crew before you can connect a client to it.":`tu dois être connecté à Crew avant de pouvoir y brancher un client.`,"Sign in":`se connecter`,"That did not work":`ça n'a pas marché`,"Back to Crew":`retour à Crew`,"This link is missing the parameters an authorisation request needs. Start the connection again from your client.":`il manque à ce lien les paramètres d'une demande d'autorisation. relance la connexion depuis ton client.`,"That client asked for an unsupported security method. Crew only accepts S256.":`ce client demande une méthode de sécurité non supportée. Crew n'accepte que S256.`,"Crew could not issue the code.":`Crew n'a pas pu émettre le code.`,"Connect {client} to Crew?":`connecter {client} à Crew ?`,"It will be able to read your tasks, goals, streak and settings, and to create, edit and carry tasks on your behalf.":`il pourra lire tes tâches, tes objectifs, ta série et tes réglages, et créer, modifier et reporter des tâches en ton nom.`,"It will be able to read your tasks, goals, streak and settings. It cannot change anything.":`il pourra lire tes tâches, tes objectifs, ta série et tes réglages. il ne peut rien modifier.`,"It cannot mark past days done â a closed day stays closed.":`il ne peut pas cocher un jour passé : un jour clos reste clos.`,"It cannot write a verdict. Proof goes to the judge, same as always.":`il ne peut pas écrire de verdict. la preuve passe par le juge, comme toujours.`,"It cannot touch billing, your plan, or delete your account.":`il ne touche ni à la facturation, ni à ton offre, ni à la suppression de ton compte.`,"It cannot see anyone elseâs data.":`il ne voit les données de personne d'autre.`,"Everything it writes is tagged as written by an agent.":`tout ce qu'il écrit est marqué comme écrit par un agent.`,"Connectingâ¦":`connexionâ¦`,Connect:`connecter`,Cancel:`annuler`,"You can revoke this at any time in Settings.":`tu peux révoquer cet accès à tout moment dans les réglages.`,"day where all {n} of you cleared the bar":`jour où vous avez tous les {n} passé la barre`,"days in a row where all {n} of you cleared the bar":`jours d'affilée où vous avez tous les {n} passé la barre`,"one bad day ends it for everyone â that is the point":`un mauvais jour l'arrête pour tout le monde, c'est justement le principe`,"© 2026 Crew":`© 2026 Crew`,Workspace:`Espace de travail`,Dashboard:`Tableau de bord`,Momentum:`Ãlan`,Patterns:`Tendances`,Goals:`Objectifs`,Accountability:`Responsabilité`,Review:`Bilan`,Streak:`Série`,"Co-founder":`Co-fondateur`,Chat:`Chat`,"The Crew":`The Crew`,Activity:`Activité`,Calendar:`Agenda`,Feedback:`Retours`,Settings:`Paramètres`,"Lock today":`Verrouiller aujourd'hui`,"tomorrow â":`demain â`,"start here â lock your 3 tasks for today.":`commence ici â verrouille tes 3 tâches du jour.`,"this is the whole loop: everything else in Crew builds from what you lock in.":`c'est toute la boucle : tout le reste dans crew part de ce que tu verrouilles ici.`,"Search tasks, receiptsâ¦":`Chercher tâches, reçusâ¦`,feedback:`retours`,"got a bug, an idea, or a connector you want?":`un bug, une idée, ou un connecteur que tu veux ?`,"pick a category, say or type it â I'll look at it within 3 days.":`choisis une catégorie, dis-le ou écris-le â je regarde ça sous 3 jours.`,bug:`bug`,"feature idea":`idée de fonctionnalité`,"connector request":`demande de connecteur`,"verification issue":`problème de vérification`,"account & billing":`compte & facturation`,"something else":`autre chose`,"something's broken":`quelque chose est cassé`,"something you want built":`quelque chose que tu veux voir construit`,"an app you want Crew to watch":`une appli que tu veux que Crew surveille`,"Crew got a call wrong":`Crew s'est trompé sur une vérification`,"slow, laggy, unresponsive":`lent, saccadé, qui ne répond pas`,"pings, emails, alerts":`n
49otifications, emails, alertes`,"plan, login, data":`forfait, connexion, données`,"anything that doesn't fit above":`tout ce qui ne rentre pas ci-dessus`,pricing:`prix`,onboarding:`onboarding`,performance:`performance`,other:`autre`,"ui glitch":`bug visuel`,crash:`plantage`,"data or sync issue":`problème de données ou de synchro`,"connector issue":`problème de connecteur`,"new connector":`nouveau connecteur`,automation:`automatisation`,reporting:`rapports`,"mobile / telegram":`mobile / telegram`,github:`github`,vercel:`vercel`,stripe:`stripe`,calendly:`calendly`,gmail:`gmail`,"marked done wrongly":`marqué fait à tort`,"didn't mark done":`pas marqué fait`,"connector not detected":`connecteur non détecté`,"slow to load":`chargement lent`,"laggy typing":`saisie saccadée`,"sync delay":`délai de synchro`,"too many":`trop nombreuses`,"too few":`pas assez`,"wrong channel":`mauvais canal`,"wrong time":`mauvaise heure`,"billing or plan":`facturation ou forfait`,"login or access":`connexion ou accès`,"data or privacy":`données ou confidentialité`,"general feedback":`retour général`,"describe the issue (no essay needed)":`décris le problème (pas besoin d'un roman)`,"how critical?":`à quel point c'est critique ?`,critical:`critique`,high:`élevé`,medium:`moyen`,low:`faible`,"â attach screenshot (optional)":`â joindre une capture (optionnel)`,"speak your feedback":`dicter ton retour`,"listeningâ¦":`écouteâ¦`,"send it":`envoyer`,"got it â I'll try to ship it, fix it, or add it within 3 days.":`reçu â je vais essayer de le livrer, le corriger, ou l'ajouter sous 3 jours.`,"your feedback":`tes retours`,received:`reçu`,"in progress":`en cours`,"won't fix":`ne sera pas corrigé`,trial:`essai`,solo:`solo`,founder:`fondateur`,"upgrade â":`passer au payant â`,"sign out":`se déconnecter`,settings:`paramètres`,account:`compte`,name:`nom`,email:`e-mail`,"product name":`nom du produit`,"save changes":`enregistrer`,saved:`enregistré`,billing:`facturation`,"days left":`jours restants`,"trial expired":`essai expiré`,"trial active":`essai actif`,"â upgrade to keep your streak":`â passe au payant pour garder ta série`,"solo plan · billed via stripe":`formule solo · facturé via stripe`,"founder plan · billed via stripe":`formule fondateur · facturé via stripe`,"manage billing â":`gérer la facturation â`,"loadingâ¦":`chargementâ¦`,activity:`activité`,"nothing here yet â connect a tool in settings and it'll show up here as you work.":`rien pour l'instant â connecte un outil dans les paramètres et ça apparaîtra ici au fil de ton travail.`,"90-day history + export":`Historique 90 jours + export`,"Priority Sonnet AI":`IA Sonnet prioritaire`,"Weekly recap share cards":`Cartes de récap hebdo partageables`,"Multiple goals":`Plusieurs objectifs`,"$19 / month":`19 $ / mois`,"$149 / year":`149 $ / an`,"Everything in solo":`Tout de la formule solo`,"The Crew (pod board)":`The Crew (tableau de pod)`,"Priority support":`Support prioritaire`,"Stakes when live":`Enjeux dès que dispo`,"$39 / month":`39 $ / mois`,"$299 / year":`299 $ / an`,"stripe not configured yet â add VITE_STRIPE_PRICE_* env vars to enable checkout":`stripe non configuré â ajoute les variables VITE_STRIPE_PRICE_* pour activer le paiement`,connectors:`connecteurs`,"companion extension":`extension compagnon`,"A small browser extension that watches only claude.ai (usage) and LinkedIn messaging (sent count) â nothing else, no screenshots â and checks a matching task off automatically.":`Une petite extension de navigateur qui surveille uniquement claude.ai (usage) et la messagerie LinkedIn (messages envoyés) â rien d'autre, aucune capture d'écran â et coche automatiquement la tâche correspondante.`,"Not yet on the Chrome Web Store â for now, load it as an unpacked extension: chrome://extensions â enable Developer mode â Load unpacked â select the extension folder.":`Pas encore sur le Chrome Web Store â pour l'instant, charge-la en extension non empaquetée : chrome://extensions â active le mode développeur â Charger l'extension non empaquetée â choisis le dossier de l'extension.`,"Paste the token below into the extension's setup page.":`Colle le jeton ci-dessous dans la page de configuration de l'extension.`,"That's it â it only watches the two domains listed, and only reacts to today's pending tasks.":`C'est tout â elle ne surveille que les deux domaines listés, et ne réagit qu'aux tâches en attente du jour.`,"connector token":`jeton du connecteur`,reveal:`afficher`,hide:`masquer`,copy:`copier`,rotate:`régénérer`,"This invali
49dates the old token â the extension will stop working until you paste the new one in its settings. Continue?":`Ãa invalide l'ancien jeton â l'extension cessera de fonctionner jusqu'à ce que tu colles le nouveau dans ses réglages. Continuer ?`,"commits, PRs, deploy receipts":`commits, PRs, reçus de déploiement`,connect:`connecter`,connected:`connecté`,"not connected":`non connecté`,disconnect:`déconnecter`,"not configured":`non configuré`,"coming soon":`bientôt disponible`,details:`détails`,close:`fermer`,"all connectors":`tous les connecteurs`,never:`jamais`,"connected since":`connecté depuis`,"permissions granted":`permissions accordées`,"yes â crew never posts or sends on your behalf":`oui â crew ne publie ni n'envoie jamais en ton nom`,"Connect your workflow tools so Crew can verify task completion automatically â closed tickets, merged PRs, sent messages, and more.":`Connecte tes outils pour que crew vérifie tout seul les tâches faites â tickets fermés, PRs fusionnées, messages envoyés, et plus.`,"Search appsâ¦":`Rechercher des appsâ¦`,"view all {n} apps â":`voir les {n} apps â`,"show less â":`afficher moins â`,"your own recent posts":`tes publications récentes`,"a channel you point the bot at":`un canal que tu désignes au bot`,"pick a channel to watch":`choisir un canal à surveiller`,"sync events alongside your priorities":`synchronise les événements avec tes priorités`,"docs & databases":`documents et bases de données`,"events & schedules":`événements et plannings`,"sent emails â outreach proof":`e-mails envoyés â preuve de prospection`,"All connectors (15 total)":`Tous les connecteurs (15 au total)`,"add VITE_GOOGLE_CLIENT_ID to enable":`ajoute VITE_GOOGLE_CLIENT_ID pour activer`,"pick a repo to track":`choisir un dépôt à suivre`,"pick a calendar to sync":`choisir un agenda à synchroniser`,"sync now":`synchroniser`,"syncingâ¦":`synchronisationâ¦`,"real deploys â shipped, not just committed":`déploiements réels â livré, pas seulement commité`,"paste your Vercel access token":`colle ton jeton d'accès Vercel`,"team ID (optional, for team accounts)":`ID d'équipe (facultatif, pour les comptes équipe)`,"connectingâ¦":`connexionâ¦`,"add a task":`ajouter une tâche`,"remove this task":`retirer cette tâche`,"pick a category":`choisis une catégorie`,"addingâ¦":`ajoutâ¦`,notifications:`notifications`,"morning lock-in":`verrouillage du matin`,"crew reminds you to lock in your {n} for the day":`crew te rappelle de verrouiller tes {n} du jour`,"midday verify check":`vérification de mi-journée`,"crew checks your connected tools during the day â anything it can confirm gets marked done and pinged to you automatically":`crew vérifie tes outils connectés dans la journée â tout ce qu'il peut confirmer passe en fait, et tu es prévenu automatiquement`,"evening check-in":`bilan du soir`,"crew reconciles what shipped vs what slipped":`crew fait le bilan de ce qui a été livré et ce qui a glissé`,"receive morning & evening pings via Telegram â free, no phone number needed":`reçois tes pings matin et soir sur Telegram â gratuit, sans numéro de téléphone`,"openingâ¦":`ouvertureâ¦`,"waitingâ¦":`en attenteâ¦`,"save notifications":`enregistrer les notifications`,timezone:`fuseau horaire`,"used for your morning and evening pings":`utilisé pour tes pings du matin et du soir`,"business context":`contexte d'activité`,community:`communauté`,"public profile":`profil public`,"appear on the leaderboard and in discover â your shipped tasks and streak become visible to other founders":`apparaître sur le classement et dans découvrir â tes tâches livrées et ta série deviennent visibles pour les autres fondateurs`,stage:`étape`,focus:`focus`,save:`enregistrer`,"what crew knows about your business":`ce que crew sait de ton activité`,"paste a short description â what you build, who buys it, your current traction. crew uses this to give you sharper daily nudges.":`colle une courte description â ce que tu construis, qui l'achète, ta traction actuelle. crew s'en sert pour te pousser plus juste au quotidien.`,"save context":`enregistrer le contexte`,"daily priorities":`priorités quotidiennes`,"how many tasks do you lock in each day? between 3 and 10.":`combien de tâches tu verrouilles chaque jour ? entre 3 et 10.`,"fewer tasks":`moins de tâches`,"more tasks":`plus de tâches`,language:`langue`,English:`Anglais`,French:`Français`,"step 1 of 3":`étape 1 sur 3`,"step 2 of 3":`étape 2 sur 3`,"step 3 of 3":`étape 3 sur 3`,"two questions, then you're in. crew tracks your execution against what you commit to ship.":`deux questions, et tu y es. crew suit ton exécution par rapport à ce que tu t'engages à livrer.`,morning:`matin`,evening:`soir`,"you lock in a few real tasks for today":`tu verrouilles quelques vraies tâches pour aujourd'hui`,"crew collects the evidence â commits, deploys, proof you send":`crew récolte les preuves â commits, déploiements, ce que tu envoies`,"crew reads it back: shipped or dodged, no self-reporting":`crew te le relit : livré ou esquivé, rien que tu déclares toi-même`,"your tasks for today come next â you'll lock those in the moment you're inside crew. crew keeps them pointed at this goal.":`tes tâches du jour arrivent juste après â tu les verrouilles dès que tu es dans crew. crew les garde point
49ées sur cet objectif.`,"get your morning ping":`reçois ton ping du matin`,"crew pings you in telegram to lock in the day, and again in the evening. reply in plain english to add a task or send proof â no app needed.":`crew te ping sur telegram pour verrouiller la journée, et repasse le soir. réponds normalement pour ajouter une tâche ou envoyer une preuve â pas besoin d'app.`,"connect telegram":`connecter telegram`,"opening telegramâ¦":`ouverture de telegramâ¦`,"waiting for telegramâ¦":`en attente de telegramâ¦`,"telegram connected â crew will ping you tomorrow morning.":`telegram connecté â crew te ping demain matin.`,"one click â it links your account automatically. no phone app required: if telegram isn't installed, it just opens in your browser.":`un clic â ton compte est lié automatiquement. aucune app à installer sur ton téléphone : si telegram n'est pas installé, ça s'ouvre dans ton navigateur.`,"finished in telegram? come back to this tab â it updates on its own.":`c'est fait sur telegram ? reviens sur cet onglet â il se met à jour tout seul.`,"the daily loop IS the product â it lives in telegram. browser-only exists in settings, but the founders who connect are the ones whose days close.":`la boucle quotidienne EST le produit â elle vit dans telegram. le mode navigateur seul existe dans les réglages, mais les fondateurs qui connectent sont ceux dont les journées se terminent.`,"the extension verifies a task from the page you're on â one keystroke instead of writing an update.":`l'extension vérifie une tâche depuis la page où tu es â une touche au lieu d'écrire un compte-rendu.`,"install guide":`guide d'installation`,"couldn't reach telegram just now â try again in a second":`impossible de joindre telegram là â réessaie dans une seconde`,"having trouble?":`un souci ?`,"nothing opened? open this link yourself:":`rien ne s'est ouvert ? ouvre ce lien toi-même :`,"still stuck? search for the bot in telegram and send it this message:":`toujours bloqué ? cherche le bot dans telegram et envoie-lui ce message :`,"this code expires in 15 minutes â click connect again for a fresh one.":`ce code expire dans 15 minutes â reclique sur connecter pour en avoir un nouveau.`,"copied â":`copié â`,"install crew companion":`installer crew companion`,"the browser extension that verifies a task from the page you're already on â one click, no self-reporting. read-only: it never posts, sends, or acts as you.":`l'extension navigateur qui vérifie une tâche depuis la page où tu es déjà â un clic, rien à déclarer toi-même. lecture seule : elle ne publie rien, n'envoie rien, et n'agit jamais à ta place.`,"1. get the extension":`1. récupère l'extension`,"add to chrome â one click":`ajouter à chrome â un clic`,"installs from the chrome web store and keeps itself updated. nothing else to do â skip to step 3.":`s'installe depuis le chrome web store et se met à jour tout seul. rien d'autre à faire â passe à l'étape 3.`,"or install it by hand:":`ou installe-la à la main :`,"not on the chrome web store yet, so this is the manual install â two minutes, once.":`pas encore sur le chrome web store, donc voici l'installation manuelle â deux minutes, une seule fois.`,"version {v} · chrome, edge, brave, arc, atlas":`version {v} · chrome, edge, brave, arc, atlas`,"2. load it into your browser":`2. charge-la dans ton navigateur`,'unzip the file you just downloaded â you get a folder called "crew-companion".':`décompresse le fichier que tu viens de télécharger â tu obtiens un dossier « crew-companion ».`,"copy this address, paste it into your browser's address bar, and press enter:":`copie cette adresse, colle-la dans la barre d'adresse de ton navigateur, puis appuie sur entrée :`,"this one can't be a clickable link â chrome blocks web pages from opening chrome:// addresses, so it has to be pasted by hand. on edge it's edge://extensions, on brave brave://extensions.":`celle-là ne peut pas être un lien cliquable â chrome empêche une page web d'ouvrir une adresse chrome://, il faut donc la coller à la main. sur edge c'est edge://extensions, sur brave brave://extensions.`,'turn on "Developer mode" â the switch in the top-right corner of that page.':`active le « mode développeur » â l'interrupteur en haut à droite de cette page.`,'click "Load unpacked" â top-left, it only appears once developer mode is on.':`clique sur « Charger l'extension non empaquetée » â en haut à gauche, elle n'apparaît qu'une fois le mode développeur activé.`,'pick the "crew-companion" folder â the one with manifest.json inside it. the extension now shows up in your extensions list.':`choisis le dossier « crew-companion » â celui qui contient manifest.json. l'extension apparaît maintenant dans ta liste d'extensions.`,"3. connect it to your account":`3. connecte-la à ton compte`,"open the extension's options page, paste your connector token in, and hit save. the token â with a copy button â lives in":`ouvre la page d'options de l'extension, colle ton jeton de connecteur, et enregistre. le jeton â avec un bouton copier â se trouve dans`,"settings â connectors":`réglages â connecteurs`,"that token is the only thing connecting the extension to your account. it stays in this browser's local storage, is never synced, and you can regenerate it any time from settings.":`ce jeton est la seule chose qui relie l'extension à ton compte. il reste dans le stockage local de ce navigateur, n'est jamais synchronisé, et tu peux le régénérer à tout moment depuis les réglages.`,"â back to crew":`â
49 retour à crew`,"this is what connects the extension to your account â nothing else about you is exposed to it. copy it, open the extension's options page, paste it in, and hit save. treat it like a password.":`c'est ce qui relie l'extension à ton compte â rien d'autre te concernant ne lui est exposé. copie-le, ouvre la page d'options de l'extension, colle-le, et enregistre. traite-le comme un mot de passe.`,"copy token":`copier le jeton`,regenerate:`régénérer`,"copied â now paste it into the extension's options page and hit save.":`copié â colle-le maintenant dans la page d'options de l'extension et enregistre.`,"your browser blocked the clipboard â the token is shown above, select and copy it by hand.":`ton navigateur a bloqué le presse-papiers â le jeton est affiché ci-dessus, sélectionne-le et copie-le à la main.`,"extension last checked in on {d}.":`dernier signe de vie de l'extension le {d}.`,"no check-in from the extension yet â it shows up here the first time the extension verifies a task.":`aucun signe de vie de l'extension pour l'instant â ça s'affichera ici la première fois qu'elle vérifie une tâche.`,"regenerating invalidates the old token immediately: the extension stops working until you paste the new one in. that's how you revoke access from a browser you no longer have.":`régénérer invalide immédiatement l'ancien jeton : l'extension cesse de fonctionner tant que tu n'as pas collé le nouveau. c'est comme ça qu'on révoque l'accès depuis un navigateur que tu n'as plus.`,"welcome to crew":`bienvenue sur crew`,"here's what changes once you're set up:":`voici ce qui change une fois installé :`,"lock in your daily tasks":`verrouille tes tâches du jour`,"pick a few real things to ship today â no vague to-do list.":`choisis quelques tâches concrètes à livrer aujourd'hui â pas de liste vague.`,"crew verifies, you don't self-report":`crew vérifie, tu ne déclares rien`,"connect your tools, submit proof, or let the browser extension watch â crew judges what actually happened.":`connecte tes outils, envoie une preuve, ou laisse l'extension regarder â crew juge ce qui s'est vraiment passé.`,"keep your streak alive":`garde ta série en vie`,"daily accountability with a catch-up mechanic for the days you miss.":`une responsabilisation quotidienne avec un mécanisme de rattrapage pour les jours manqués.`,"reach crew wherever you already are":`parle à crew là où tu es déjà `,"telegram, web push, or email â your call.":`telegram, notifications web ou e-mail â à toi de voir.`,"a community of founders, not just a bot":`une communauté de fondateurs, pas juste un bot`,"browse public profiles, see who's in a similar stage, message them directly.":`parcours les profils publics, vois qui est au même stade, écris-leur en direct.`,"connect your calendar":`connecte ton agenda`,"crew checks your calendar so it knows what was a meeting vs what was actually shipped. connect more anytime in settings.":`crew lit ton agenda pour distinguer les réunions de ce qui a vraiment été livré. connecte d'autres outils quand tu veux dans les paramètres.`,"google calendar":`google agenda`,"meetings vs. real work":`réunions vs travail réel`,"more connectors (GitHub, Google Calendar, Vercel, X, Discord, Gmailâ¦) in Settings":`plus de connecteurs (GitHub, Google Agenda, Vercel, X, Discord, Gmailâ¦) dans les paramètres`,"get notified":`sois prévenu`,"get your morning and evening pings wherever you already check messages. you can also connect later in settings.":`reçois tes pings matin et soir là où tu lis déjà tes messages. tu pourras aussi le faire plus tard dans les paramètres.`,"free, no phone number needed":`gratuit, sans numéro de téléphone`,"standard message rates may apply":`tarifs sms/data standards applicables`,"enter a full number with country code, e.g. +14155550123":`entre un numéro complet avec l'indicatif pays, ex. +33612345678`,enable:`activer`,"crew companion (browser extension)":`crew companion (extension navigateur)`,"the extension is the closest thing to zero self-reporting â it checks tasks off as it sees you do them.":`l'extension est ce qui se rapproche le plus du zéro auto-déclaration â elle coche tes tâches au fur et à mesure qu'elle te voit les faire.`,"watches whatever site you're on and matches it against your locked-in tasks â entirely on your own device.":`observe le site où tu es et le compare à tes tâches verrouillées â entièrement sur ton appareil.`,"only takes a screenshot when it finds a plausible match â an unrelated page is never captured.":`ne prend une capture que quand elle trouve une correspondance plausible â une page sans rapport n'est jamais capturée.`,"screenshots go straight to crew's AI reviewer and are never written to a file anywhere â not on your device, not on our servers.":`les captures vont directement à l'IA de crew et ne sont jamais écrites dans un fichier â ni sur ton appareil, ni sur nos serveurs.`,"set it up anytime from Settings â install instructions are there once you're in.":`installe-la quand tu veux depuis les paramètres â les instructions y sont une fois connecté.`,"give crew your context":`donne ton contexte à crew`,"crew gives sharper feedback when it knows your business. paste this prompt into your AI (Claude, ChatGPTâ¦), then paste the response below.":`crew tape plus juste quand il connaît ton activité. colle ce prompt dans ton IA (Claude, ChatGPTâ¦), puis colle la réponse ci-dessous.`,"AI PROMPT â COPY & PASTE":`PROMPT IA â COPIER & COLLER`,"copy prompt":`copier le prompt`,"copied!":`copié !`,"paste your AI's response hereâ¦":`colle ici la réponse de ton IAâ¦`,"get your morning and evening pings on telegram â free, no phone number needed. you can also connect later in settings.":`reç
49ois tes pings matin et soir sur telegram â gratuit, sans numéro de téléphone. tu pourras aussi le faire plus tard dans les paramètres.`,"get your morning and evening pings on telegram â free, no phone number needed. this is how Crew actually reaches you, so it's worth the 10 seconds. you can also connect later in settings.":`reçois tes pings matin et soir sur telegram â gratuit, sans numéro de téléphone. c'est comme ça que crew te joint vraiment, ça vaut les 10 secondes. tu pourras aussi le faire plus tard dans les paramètres.`,"recommended: pair this with Telegram":`recommandé : associe ça à Telegram`,"that's what actually pings you the instant the extension checks something off, instead of you finding out at the evening review.":`c'est ce qui te ping à l'instant où l'extension coche quelque chose, au lieu de le découvrir au bilan du soir.`,"the extension is the closest thing to zero self-reporting â it checks tasks off as it sees you do them. this is what makes Crew feel effortless, so it's worth the one-minute install.":`l'extension est ce qui se rapproche le plus du zéro auto-déclaration â elle coche tes tâches au fur et à mesure qu'elle te voit les faire. c'est ce qui rend crew sans effort, ça vaut l'installation d'une minute.`,"how the day runs":`comment se déroule la journée`,"three pings, one loop. this is the rhythm you're signing up for:":`trois pings, une boucle. voici le rythme dans lequel tu t'engages :`,"7:30 AM":`7h30`,"all day":`toute la journée`,"8:30 PM":`20h30`,"All day":`Toute la journée`,"lock in the 3 that matter":`verrouille les 3 qui comptent`,"crew pings you before your inbox. you commit to three real priorities â not a list, a declaration.":`crew te ping avant ta boîte mail. tu t'engages sur trois vraies priorités â pas une liste, une déclaration.`,"evidence builds itself":`les preuves se construisent seules`,"commits, deploys, sent messages, calendar events â from your connected tools, the extension, or a screenshot you submit. crew reads the real signal.":`commits, déploiements, messages envoyés, événements d'agenda â depuis tes outils connectés, l'extension, ou une capture que tu envoies. crew lit le vrai signal.`,"face the day, honestly":`affronte la journée, honnêtement`,"crew reads your receipts back â what you shipped, what you dodged, what pattern is forming. no comfort, just the truth.":`crew te relit tes reçus â ce que tu as livré, ce que tu as esquivé, le schéma qui se forme. pas de réconfort, juste la vérité.`,"what you'll have in 30 days":`ce que tu auras dans 30 jours`,"stick with the loop and here's where {product} â and you â end up:":`tiens la boucle, et voici où {product} â et toi â vous en serez :`,"stick with the loop, {who}, and here's where you end up:":`tiens la boucle, {who}, et voici où tu en seras :`,"a shipping habit that compounds":`une habitude de livraison qui fait boule de neige`,"a visible streak and a plant that grows as you keep showing up. missing a day actually costs something now.":`une série visible et une plante qui pousse tant que tu es au rendez-vous. rater un jour coûte enfin quelque chose.`,"honest data on what you really do":`des données honnêtes sur ce que tu fais vraiment`,"a dashboard of what you shipped vs. dodged over time â the patterns you can't see from inside the week.":`un tableau de bord de ce que tu as livré vs esquivé dans le temps â les schémas qu'on ne voit pas de l'intérieur de la semaine.`,'no more "i was busy"':`fini le « j'étais occupé »`,'every task is verified against real evidence, so "done" means done. the self-delusion is gone.':`chaque tâche est confrontée à de vraies preuves, donc « fait » veut dire fait. fini de se raconter des histoires.`,"steady progress toward your one goal":`des progrès réguliers vers ton objectif unique`,"crew keeps every day pointed at the number you set â not busywork that feels like motion.":`crew garde chaque journée braquée sur le chiffre que tu t'es fixé â pas de l'agitation qui donne l'illusion d'avancer.`,"what are you building?":`qu'est-ce que tu construis ?`,"crew tracks your execution against what you've committed to ship.":`crew suit ton exécution par rapport à ce que tu t'es engagé à livrer.`,"your name":`ton nom`,"product name (input)":`nom du produit`,"e.g. Ledgerline, Replyflow, Inkforge":`ex. Ledgerline, Replyflow, Inkforge`,"connect github":`connecter github`,"crew reads your commits and PRs to generate receipts â so there's no self-reporting. you can connect later in settings.":`crew lit tes commits et tes PRs pour générer des reçus â zéro auto-déclaration. tu pourras connecter plus tard dans les paramètres.`,"connect calendar":`connecter l'agenda`,"crew checks your calendar so it knows what was a meeting vs what was actually shipped. connect it later in settings.":`crew lit ton agenda pour distinguer les réunions de ce qui a vraiment été livré. connecte-le plus tard dans les paramètres.`,"calendar sync coming soon":`synchronisation agenda bientôt disponible`,"your one goal":`ton objectif unique`,"one goal, one number, one date. crew holds you to this every day.":`un objectif, un chiffre, une date. crew t'y tient chaque jour.`,"the goal":`l'objectif`,"e.g. lau
49nch v1 and get 3 paying customers":`ex. lancer v1 et obtenir 3 clients payants`,"target date (optional)":`date cible (optionnel)`,continue:`continuer`,"skip for now":`passer pour l'instant`,"open crew":`ouvrir crew`,"enter your name":`entre ton nom`,"enter what you're building":`entre ce que tu construis`,"enter your one goal":`entre ton objectif unique`,"no active session â try signing in again":`aucune session active â reconnecte-toi`,"connect google calendar":`connecter google agenda`,"sign in":`se connecter`,"create account":`créer un compte`,"continue with github":`continuer avec github`,"continue with google":`continuer avec google`,or:`ou`,password:`mot de passe`,"forgot password?":`mot de passe oublié ?`,"by continuing, you agree to crew's":`en continuant, tu acceptes les`,terms:`conditions`,and:`et la`,"privacy policy":`politique de confidentialité`,"reset password":`réinitialiser le mot de passe`,"back to sign in":`retour à la connexion`,"send reset link":`envoyer le lien`,"check your email":`vérifie tes e-mails`,"check your inbox":`vérifie ta boîte mail`,"enter your email":`entre ton e-mail`,"enter your password":`entre ton mot de passe`,"signing inâ¦":`connexion en coursâ¦`,"creating accountâ¦":`création du compteâ¦`,"sendingâ¦":`envoi en coursâ¦`,"cancel this feedback? this can't be undone.":`annuler ce retour ? cette action est irréversible.`,"cancel this feedback":`annuler ce retour`,"min 8 characters":`min 8 caractères`,"[email protected]":`[email protected]`,"back to home":`retour à l'accueil`,"sign in or create account":`se connecter ou créer un compte`,"crew is invite-only for now":`crew est sur invitation pour l'instant`,"early access runs on invite codes so we can onboard founders one at a time. your code is in the invite email or DM you got from us â it is short, and it is not your password.":`l'accès anticipé fonctionne avec des codes d'invitation, pour qu'on accompagne les fondateurs un par un. ton code est dans l'e-mail ou le message qu'on t'a envoyé â il est court, et ce n'est pas ton mot de passe.`,"invite code":`code d'invitation`,"e.g. 1234":`ex. 1234`,"checkingâ¦":`vérificationâ¦`,"unlock signup â":`débloquer l'inscription â`,"don't have a code?":`pas de code ?`,"join the waitlist â":`rejoindre la liste d'attente â`,"already have an account?":`tu as déjà un compte ?`,"sign in instead":`connecte-toi plutôt`,"enter the invite code you were given.":`entre le code d'invitation qu'on t'a donné.`,"too many tries from this network. wait 10 minutes and try again â the code still works.":`trop d'essais depuis ce réseau. attends 10 minutes et réessaie â le code reste valable.`,"that code isn't valid. check it character by character â it's the code from your invite email or DM.":`ce code n'est pas valable. vérifie-le caractère par caractère â c'est celui de ton e-mail ou message d'invitation.`,"something went wrong on our side. try again in a moment.":`un problème de notre côté. réessaie dans un instant.`,"invite accepted. pick any way to create your account below.":`invitation acceptée. choisis ci-dessous comment créer ton compte.`,"that google or github account is new here, and crew is invite-only. enter your invite code below, then sign up with the same account â it takes 20 seconds.":`ce compte google ou github est nouveau ici, et crew est sur invitation. entre ton code d'invitation ci-dessous, puis inscris-toi avec le même compte â ça prend 20 secondes.`,"enter your invite code once more to continue.":`entre ton code d'invitation encore une fois pour continuer.`,"your invite code needs re-entering â put it in below and try again.":`ton code d'invitation doit être ressaisi â entre-le ci-dessous et réessaie.`,"sign up with google":`s'inscrire avec google`,"sign up with github":`s'inscrire avec github`,"opening googleâ¦":`ouverture de googleâ¦`,"opening githubâ¦":`ouverture de githubâ¦`,"or use an email and password":`ou utilise un e-mail et un mot de passe`,"at least 8 characters":`au moins 8 caractères`,"at least 8 characters. nothing else required â no symbol quotas.":`au moins 8 caractères. rien d'autre â pas de quota de symboles.`,"show password":`afficher le mot de passe`,"hide password":`masquer le mot de passe`,"free until launch. no card needed.":`gratuit jusqu'au lancement. pas de carte.`,"almost there â open the confirmation link
49we just emailed you, then come back and sign in.":`presque â ouvre le lien de confirmation qu'on vient de t'envoyer par e-mail, puis reviens te connecter.`,"that email and password don't match an account. check the password, or use âforgot password?â to reset it.":`cet e-mail et ce mot de passe ne correspondent à aucun compte. vérifie le mot de passe, ou utilise « mot de passe oublié ? » pour le réinitialiser.`,"confirm your email first â open the link we sent you, then sign in.":`confirme d'abord ton e-mail â ouvre le lien qu'on t'a envoyé, puis connecte-toi.`,"that email already has an account â switch to sign in.":`cet e-mail a déjà un compte â passe sur « se connecter ».`,"crew is invite-only right now. enter your invite code above before creating an account â or join the waitlist.":`crew est sur invitation en ce moment. entre ton code d'invitation ci-dessus avant de créer un compte â ou rejoins la liste d'attente.`,"password needs at least 8 characters.":`le mot de passe doit faire au moins 8 caractères.`,"too many attempts. wait about a minute, then try again.":`trop de tentatives. attends environ une minute, puis réessaie.`,"couldn't reach crew. check your connection and try again.":`impossible de joindre crew. vérifie ta connexion et réessaie.`,"that email address looks wrong â check it for typos.":`cette adresse e-mail semble incorrecte â vérifie les fautes de frappe.`,"enter your email and we'll send a link to set a new password.":`entre ton e-mail et on t'envoie un lien pour définir un nouveau mot de passe.`,"we sent a reset link to":`on a envoyé un lien à `,"click it to set a new password.":`clique dessus pour définir un nouveau mot de passe.`,"lock in your 3":`verrouille tes 3`,"what are the 3 things that move the needle today?":`quelles sont les 3 choses qui font vraiment avancer aujourd'hui ?`,tomorrow:`demain`,done:`terminé`,skipped:`passé`,pending:`en attente`,"lock the {n}":`verrouiller les {n}`,"mark today done":`marquer la journée comme faite`,"â dashboard":`â tableau de bord`,today:`aujourd'hui`,Today:`Aujourd'hui`,More:`Plus`,"more pages":`autres pages`,primary:`principale`,Tomorrow:`Demain`,"other day":`autre jour`,"pick another day":`choisir un autre jour`,"nothing locked yet. what are the {n} things that actually move the needle today?":`rien de verrouillé. quelles sont les {n} choses qui font vraiment avancer aujourd'hui ?`,"prep tomorrow before you sleep â lock the {n} that actually matter.":`prépare demain avant de dormir â verrouille les {n} qui comptent vraiment.`,"nothing locked for this day yet.":`rien de verrouillé ce jour-là pour l'instant.`,"catch up: yesterday slipped â lock in {n} today to get back on track.":`rattrapage : hier a sauté â verrouille {n} aujourd'hui pour te remettre en selle.`,"just my usual {n}":`juste mes {n} habituelles`,"{n} day streak":`série de {n} jours`,"the run ended. {n} days went unverified. plant today to grow again.":`la série s'arrête ici. {n} jours non vérifiés. plante aujourd'hui pour repartir.`,"today isn't locked in â lock in before it blows away.":`la journée n'est pas verrouillée â verrouille avant que tout s'envole.`,"today's still growing â lock in the rest to keep it.":`la journée pousse encore â verrouille le reste pour la garder.`,"plant your first day.":`plante ton premier jour.`,"a seed no more â day one.":`ce n'est plus une graine â jour un.`,"{n} days growing.":`{n} jours de croissance.`,"{done} of {total} locked priorities":`{done} sur {total} priorités verrouillées`,"locked this morning. Crew accounts for them tonight.":`verrouillées ce matin. Crew en fait le bilan ce soir.`,"do this next":`à faire maintenant`,"up next":`à suivre`,"not started":`pas commencé`,"start â mark in progress":`commencer â marquer en cours`,"put back to not started":`remettre en pas commencé`,"add another repo":`ajouter un autre dépôt`,"stop tracking {repo}":`ne plus suivre {repo}`,"day clear.":`journée bouclée.`,"that's one.":`une de faite.`,"all {n} done â proven, not claimed.":`les {n} sont faites â prouvées, pas déclarées.`,"{done} of {total} done · {left} to go":`{done} sur {total} · encore {left}`,dictate:`dicter`,"stop and transcribe":`arrêter et transcrire`,"transcribingâ¦":`transcriptionâ¦`,"no microphone found":`aucun micro détecté`,"couldn't transcribe that â try again":`transcription impossible â réessaie`,"stop dictating":`arrêter la dictée`,"microphone blocked â allow it for this site in your browser":`micro bloqué â autorise-le pour ce site dans ton navigateur`,"this page isn't allowed to use the microphone":`cette page n'a pas le droit d'utiliser le micro`,"didn't catch that â try again":`je n'ai pas saisi â réessaie`,"dictation needs a connection â check your network":`la dictée a besoin d'une connexion â vérifie ton réseau`,"dictation failed â type instead":`la dictée a échoué â écris plutôt`,"enter to send · shift + enter for a new line":`entrée pour envoyer · maj + entrée pour un saut de ligne`,finished:`terminé`,"task options":`options de la tâche`,"task verification":`vérification des tâches`,"crew checks your work before a task counts as done â auto-verify, then proof if needed.":`crew vérifie votre travail avant de compter une tâche comme faite â vérification auto, puis preuve si besoin.`,"turning this off means one click marks a task done. it will count as self-reported, not verified â on your streak, your records, and anything you share.":`en désactivant ceci, un clic suffit à marquer une tâche faite. elle comptera comme déclarée, pas vérifiée â sur votre streak, vos re
49cords et tout ce que vous partagez.`,"turn off anyway":`désactiver quand même`,"keep verification on":`garder la vérification`,"verification is off â tasks count as self-reported.":`vérification désactivée â les tâches comptent comme déclarées.`,"all clear":`tout est clair`,"all {n} locked priorities done.":`les {n} priorités verrouillées sont faites.`,"DRIFT · skipped {n} days running â Crew's watching this one":`DÃRIVE · ignorée {n} jours d'affilée â Crew surveille celle-ci`,"Crew checkingâ¦":`Crew vérifieâ¦`,"let Crew verify":`laisser Crew vérifier`,edit:`modifier`,delete:`supprimer`,cancel:`annuler`,'delete "{task}"? this can\'t be undone.':`supprimer « {task} » ? cette action est irréversible.`,'type "{name}" to confirm':`tape « {name} » pour confirmer`,breakdown:`découpage`,"hide breakdown":`masquer le découpage`,"add a stepâ¦":`ajouter une étapeâ¦`,add:`ajouter`,"that one's been dodged before. close it out before tonight's check-in.":`celle-ci a déjà été esquivée. règle-la avant le bilan de ce soir.`,"â today's logged":`â journée enregistrée`,undo:`annuler`,"Mark today done":`Marquer la journée comme faite`,"what actually moves the needle?":`qu'est-ce qui fait vraiment avancer ?`,"fill in all {n}":`remplis les {n}`,"pick a category for every task":`choisis une catégorie pour chaque tâche`,build:`build`,sales:`sales`,ops:`ops`,"lockingâ¦":`verrouillageâ¦`,"prove it":`prouve-le`,"Crew is checking your connected toolsâ¦":`Crew vérifie tes outils connectésâ¦`,"â Crew found matching activity in {app}.":`â Crew a trouvé une activité correspondante dans {app}.`,"mark done â verified":`marquer fait â vérifié`,"add my own proof instead":`ajouter ma propre preuve`,"does this actually prove it? if not, add your own proof.":`est-ce que ça le prouve vraiment ? sinon, ajoute ta propre preuve.`,"Crew couldn't auto-verify this. Show something concrete â a link/screenshot, or a specific note if there's nothing to show for it.":`Crew n'a pas pu vérifier automatiquement. Montre du concret â un lien/une capture, ou une note précise si tu n'as rien à montrer.`,"what's the proof? (link, what you didâ¦)":`c'est quoi la preuve ? (lien, ce que tu as faitâ¦)`,"â attach screenshot / file":`â joindre une capture / un fichier`,"uploadingâ¦":`téléversementâ¦`,"mark done":`marquer fait`,"I can't show proof":`je ne peux pas montrer de preuve`,"â I do have proof":`â j'ai une preuve`,"why can't you show proof? (e.g. confidential client work)":`pourquoi pas de preuve ? (ex. travail client confidentiel)`,"Crew couldn't auto-verify this.":`Crew n'a pas pu vérifier automatiquement.`,"I can add proof":`je peux ajouter une preuve`,"I couldn't do it":`je n'ai pas pu le faire`,"couldn't do it":`pas pu le faire`,"show something concrete â a link/screenshot, or a specific note if there's nothing to show for it.":`montre du concret â un lien/une capture, ou une note précise si tu n'as rien à montrer.`,"for this one: add a screenshot showing it, or just tell me what you did â doesn't need to be perfect, just enough for me to see it's real.":`pour celle-ci : ajoute une capture qui le montre, ou dis-moi juste ce que tu as fait â pas besoin d'être parfait, juste assez pour que je voie que c'est réel.`,"a link, a quick note, whatever's easiestâ¦":`un lien, une note rapide, ce qui est le plus simpleâ¦`,"â or attach a screenshot":`â ou joindre une capture`,"I'm not actually connected anywhere I could check this automatically â share a direct link or a screenshot and I'll verify it right away.":`je ne suis en fait connecté nulle part où je pourrais vérifier ça automatiquement â envoie un lien direct ou une capture et je vérifie tout de suite.`,"I checked your connected tools but couldn't find anything matching this â share a direct link or a screenshot and I'll verify it right away.":`j'ai vérifié tes outils connectés mais rien ne correspond â envoie un lien direct ou une capture et je vérifie tout de suite.`,"what actually happened? a genuine, specific reason â Crew checks it, so a vague one gets sent back.":`qu'est-ce qui s'est vraiment passé ? une raison précise et sincère â crew la vérifie, une raison vague sera renvoyée.`,"what happened? (e.g. call got pushed, blocked on Xâ¦)":`que s'est-il passé ? (ex. appel reporté, bloqué par Xâ¦)`,"mark not done":`marquer non fait`,"privacy & data":`confidentialité & données`,"everything Crew reads is read-only and revocable. here's exactly what's connected and when it was last read.":`tout ce que crew lit est en lecture seule et révocable. voici exactement ce qui est connecté et quand ça a été lu pour la dernière fois.`,"nothing connected.":`rien de connecté.`,"read-only":`lecture seule`,"last read":`dernière lecture`,reads:`lit`,why:`pourquoi`,"export my data (JSON)":`exporter mes données (JSON)`,"preparingâ¦":`préparationâ¦`,"downloaded â check your files.":`téléchargé â regarde tes fichiers.`,"type DELETE to confirm":`tape DELETE pour confirmer`,"delete my account":`supprimer mon compte`,"deletingâ¦":`suppressionâ¦`,subprocessors:`sous-traitants`,"notification channels":`canaux de notification`,"choose how Crew reaches you â Telegram is no longer required.":`choisis comment crew te joint â Telegram n'est plus obligatoire.`,telegram:`telegram`,"web push (this device)":`notifications web (cet appareil)`,"not supported here":`non pris en charge ici`,"an opt-in page showing your Crew-verified execution â aggregates only, never task contents unless you choose.":`une page opt-in qui montre ton exécution vérifiée par crew â des agrégats uniquement, jamais le contenu des tâches sauf si tu le choisis.`,"handle: 3â30 chars, aâz 0â9 _":`identifiant : 3â30 caractères, aâz 0â9 _`,"that handle is taken":`cet identifiant est déjà pris`,"could not save":`impossible d'enregistrer`,"make my profile public":`rendre mon profil public`,"show streak":`afficher la série`,"show completion rate":`afficher le taux de complétion`,"show category breakdown":`afficher la répartition par catégorie`,"show shipped task titles":`afficher les titres des tâches livrées`,"put something on the line":`mets quelque chose en jeu`,"on the line":`en jeu`,"the pledge went unkept":`l'engagement n'a pas tenu`,"book a 15-min call":`réserver un appel de 15 min`,chat:`chat`,"what's my priority right now?":`quelle est ma priorité en ce moment ?`,"show my week":`montre ma semaine`,"where am i slipping?":`où est-ce que je décroche ?`,"plan tomorrow's 3":`planifier les 3 de demain`,"am i on track for my goal?":`je suis sur la bonne voie pour mon objectif ?`,"what pattern do you see?":`quel pattern tu vois ?`,"Remove image":`Retirer l'image`,"Attach proof":`Joindre une preuve`,"Attach screenshot as proof":`Joindre une capture d'écran comme preuve`,"add a note or just hit sendâ¦":`ajoute une note ou envoie directementâ¦`,"ask crew anythingâ¦":`demande n'importe quoi à crewâ¦`,Send:`Envoyer`,"proof preview":`aperçu de la preuve`,'before we move on â did
49you actually ship "{task}"? I couldn\'t verify it automatically last night.':`avant d'avancer â tu as vraiment livré « {task} » ? je n'ai pas pu le vérifier hier soir.`,"yes, shipped it":`oui, livré`,"âï¸ didn't happen":`âï¸ pas fait`,"what's the proof? a link, a screenshot, or just tell me what you did.":`c'est quoi la preuve ? un lien, une capture, ou dis-moi juste ce que tu as fait.`,"what happened?":`que s'est-il passé ?`,"got it â marked as not done. tomorrow's a new day.":`noté â marqué non fait. demain est un nouveau jour.`,"â marked done â nice work.":`â marqué comme fait â bien joué.`,"actually, I couldn't do it":`en fait, je n'ai pas pu le faire`,"{done}/{total} done today.":`{done}/{total} fait aujourd'hui.`,"nothing locked yet today.":`rien de verrouillé aujourd'hui.`,"{n}-day streak â that's momentum. {status} what's next?":`série de {n} jours â c'est du momentum. {status} et ensuite ?`,"{n} days straight at {pct}% last week. {status} keep it going.":`{n} jours d'affilée à {pct}% la semaine dernière. {status} continue comme ça.`,"{n} days in. {pct}% last week. {status} what are you working on?":`{n} jours en cours. {pct}% la semaine dernière. {status} sur quoi tu travailles ?`,"{pct}% last week â solid. streak reset but the consistency is real. {status}":`{pct}% la semaine dernière â solide. la série est repartie à zéro mais la régularité est réelle. {status}`,"{pct}% last week, {pct30}% over 30 days. {status} what do you want to dig into?":`{pct}% la semaine dernière, {pct30}% sur 30 jours. {status} sur quoi veux-tu creuser ?`,"let's start. what are the {count} things that have to happen today?":`on commence. quelles sont les {count} choses qui doivent se passer aujourd'hui ?`,"{pct}% last week. more misses than hits. {status} what's actually blocking you?":`{pct}% la semaine dernière. plus de ratés que de réussites. {status} qu'est-ce qui te bloque vraiment ?`,"weekly review":`bilan de la semaine`,"no weeks to review yet â lock a few days on the Today page first.":`aucune semaine à passer en revue â verrouille d'abord quelques jours sur la page aujourd'hui.`,"{pct}% · {done} of {total}":`{pct}% · {done} sur {total}`,"adherence {n}%":`parole tenue {n}%`,"output · {n} done":`production · {n} faits`,"share week â":`partager la semaine â`,"week completion":`progression de la semaine`,"nothing shipped this week yet.":`rien de livré cette semaine pour l'instant.`,"in progress · not counted yet":`en cours · pas encore compté`,"carried forward":`reporté`,"you moved these to a later day, so they don't count against the day you moved them from. after 3 days they count as missed again.":`tu les as déplacées à un jour ultérieur, donc elles ne comptent pas contre le jour d'origine. après 3 jours, elles comptent à nouveau comme ratées.`,"what will prove this?":`qu'est-ce qui le prouvera ?`,"PR merged":`PR mergée`,"file changed":`fichier modifié`,"meeting held":`réunion tenue`,"invoice sent":`facture envoyée`,"nothing will prove this":`rien ne le prouvera`,"when?":`quand ?`,"after standup · optional":`après le point d'équipe · optionnel`,"where the week went":`où est passée la semaine`,"{d} of {n}":`{d} sur {n}`,adherence:`adhérence`,"of what you committed to":`de ce que tu avais pris`,output:`production`,"finished, planned or not":`terminé, prévu ou non`,"of the list":`de la liste`,"{d} of {n} locked tasks":`{d} sur {n} tâches verrouillées`,"should crew verify your work?":`crew doit-il vérifier ton travail ?`,"with verification on, finishing a task means crew looks for real evidence in your connected tools. it labels each one verified, or taken on your word when nothing could confirm it.":`avec la vérification activée, terminer une tâche déclenche une recherche de preuves réelles dans tes outils connectés. chaque tâche est étiquetée vérifiée, ou sur ta parole quand rien n'a pu la confirmer.`,"yes, verify my work":`oui, vérifie mon travail`,"the default. this is what crew is for.":`par défaut. c'est la raison d'être de crew.`,"no, i will mark my own tasks done":`non, je marquerai mes tâches moi-même`,"one click marks a task done, no evidence needed.":`un clic marque une tâche comme faite, sans preuve.`,"worth being straight with you: verification is the whole product.":`autant être direct : la vérification, c'est tout le produit.`,"without it, crew is a checklist you tick yourself, which is the thing it exists to replace. every task counts as self-reported, on your streak, your records, and anything you share. nothing will say it was proven, because nothing checked.":`sans elle, crew est une liste que tu coches toi-même, exactement ce qu'il existe pour remplacer. chaque tâche compte comme auto-déclarée, sur ta série, tes archives et tout ce que tu partages. rien ne dira que c'était prouvé, parce que rien n'a vérifié.`,"it is your account. you can leave it off, and you can change this any time in settings.":`c'est ton compte. tu peux la laisser désactivée, et changer d'avis quand tu veux dans les paramètres.`,"Next week: put the leads first, not last. Send the emails before you open any code.":`La semaine prochaine : les leads en premier, pas en dernier. Envoie les emails avant d'ouvrir le code.`,"This day is closed. A task can be backfilled up to noon the next day; after that the day stands as it is.":`Ce jour est clos. Une tâche peut être complétée jusqu'à midi le lendemain ; après ça, le jour reste tel quel.`,"Nothing locked this week, so there is nothing to review yet.":`Rien de verrouillé cette semaine, il n'y a donc rien à passer en revue.`,"Down {d} points on last week, {prev}% to {cur}%. What changed?":`En baisse de {d} points sur la semaine dernière, {prev}% à {cur}%. Qu'est-ce qui a changé ?`,"{cat} is the engine. {n} shipped this week.":`{cat} est le moteur. {n} livrées cette semaine.`,"{cat} is where it leaks. {n} slipped, and that is the one to fix.":`{cat} est la fuite. {n} ratées, et c'est celle-là qu'il faut corriger.`,"Only {days} this week. Consistency beats intensity.":`Seulement {days} cette semaine. La régularité bat l'intensité.`,"Plenty got done, just not what you planned.":`Beaucoup a été fait, mais pas ce qui était prévu.`,"Nothing matched automatically. What is the proof this happened?":`Rien n'a correspondu automatiquement. Quelle est la preuve que c'est arrivé ?`,"Deep 1:1":`Point 1:1`,"written {d}":`écrit le {d}`,"What held":`Ce qui a tenu`,"What you're steering around":`Ce que tu contournes`,"The call":`L'appel`,"The Deep 1:1 comes with the Founder plan. It is a written read on your week: what held, what you are steering around, and one call for next week. Change your plan in settings.":`Le point 1:1 vient avec le plan Founder. C'est une lecture écrite de ta semaine : ce qui a tenu, ce que tu contournes, et un appel pour la semaine prochaine. Change de plan dans les paramètres.`,"Your first one is written on Sunday, with the week. You can also ask for it now.":`Le premier est écrit dimanche, avec la semaine. Tu peux aussi le demander maintenant.`,"Reading your weekâ¦":`Lecture de ta semaineâ¦`,"Write it again":`Réécris-le`,"Write it now":`Ãcris-le maintenant`,"1 day off kept this run alive":`1 jour de repos a maintenu cette série`,"{n} days off kept this run alive":`{n} jours de repos ont maintenu cette série`,"+ proof, timing, multi-day":`+ preuve, horaire, multi-jours`,"multi-day":`multi-jours`,"Every milestone is closed.":`Toutes les étapes sont bouclées.`,"No target date, so there is no pace to measure.":`Pas de date cible, donc pas de rythme à mesurer.`,"Nothing closed yet, so there is no pace to measure.":`Rien de bouclé encore, donc pas de rythme à mesurer.`,"At this rate you finish with room to spare.":`à ce rythme, tu finis avec de la marge.`,"At this rate you land almost exactly on the date.":`à ce rythme, tu arrives presque pile à la date.`,"At this rate you are {n} days late. Something has to change.":`à ce rythme, tu as {n} jours de retard. Il faut changer quelque chose.`,"{n} days past the date":`{n} jours après la date`,"work behind this goal":`le travail derrière cet objectif`,"{v} verified · {a} on your word · {n} committed":`{v} vérifiées · {a} sur ta parole · {n} engagées`,"{v} verified, {a} on your word, of {n} committed":`{v} vérifiées, {a} sur ta parole, sur {n} engagées`,"{n} milestones have no work attached yet":`{n} étapes n'ont encore aucun travail rattaché`,"1 milestone has no work attached yet":`1 étape n'a encore aucun travail rattaché`,"on your word":`sur ta parole`,"{n} committed":`{n} engagées`,"no work attached yet":`aucun travail rattaché`,"attach work":`rattacher du travail`,"no tasks in the last 30 days.":`aucune tâche sur les 30 derniers jours.`,"already attached to another milestone":`déjà rattachée à une autre étape`,"the week":`la semaine`,"nothing locked this week.":`rien de verrouillé cette semaine.`,carried:`reportée`,open:`en cours`,"evidence mix":`part vérifiée`,"verified by a connector":`vérifiées par un connecteur`,"taken on your word":`sur ta parole`,"{v} verified, {a} on your word":`{v} vérifiées, {a} sur ta parole`,"nothing slipped this week.":`rien n'a glissé cette semaine.`,"actually got this done? mark it done with proof":`tu l'as fait finalement ? marque-la faite avec une preuve`,"View receipt for {task}":`voir le reçu de {task}`,"crew's read":`l'analyse de crew`,insights:`observations`,"next week":`la semaine prochaine`,"4-week trend":`tendance sur 4 semaines`,"ask crew about this week":`demande à crew à propos de cette semaine`,"thinkingâ¦":`réflexionâ¦`,"ask anything about this weekâ¦":`demande ce que tu veux sur cette semaineâ¦`,Ask:`Demander`,"where did I leak time this week?":`où j'ai perdu du temps cette semaine ?`,"what should I change next week?":`qu'est-ce que je devrais changer la semaine prochaine ?`,"am I improving?":`est-ce que je progresse ?`,"nothing locked this week yet â there's nothing to review.":`rien de verrouillé cette semaine â il n'y a rien à passer en revue.`,"{n} time":`{n} fois`,"{n} times":`{n} fois`,"{pct}% this week. Sales went untouched {times} days in 7, and that gap is widening.":`{pct}% cette semaine. Sales est resté intouché {times} jours sur 7, et cet écart se creuse.`,"{pct}% this week, solid across the board.":`{pct}% cette semaine, solide sur toute la ligne.`,"this week: put the leads first, not last. send emails before you open any code. flip the order.":`cette semaine : les prospects d'abord, pas en dernier. envoie tes emails avant d'ouvrir le moindre code. inverse l'ordre.`,"Next week: keep the same order. Whatever you did, repeat it.":`La semaine prochaine : garde le même ordre. Ce que tu as fait, refais-le.`,"Up {d} points on last week, {prev}% to {cur}%.":`En hausse de {d} points sur la semaine dernière, {prev}% à {cur}%.`,"down {d} pts vs last week ({prev}% â {cur}%). what changed?":`en baisse de {d} pts vs la semaine dernière ({prev}% â {cur}%). qu'est-ce qui a changé ?`,"Flat on last week at {cur}%. Steady, no gain.":`Stable à {cur}% comme la semaine dernière. Constant, sans progression.`,"{cat} is your engine â {n} shipped this week.":`{cat}, c'est ton moteur â {n} livrés cette semaine.`,"{cat} is where it leaks â {n} slipped. that's the one to fix.":`{cat}, c'est là que ça fuit â {n} manqués. c'est celui-là qu'il faut régler.`,"{n} active day":`{n} jour actif`,"{n} active days":`{n} jours actifs`,"only {days} this week â consistency beats intensity.":`seulement {days} cette semaine â la régularité l'emporte sur l'intensité.`,"lots got done â just not what you planned.":`il s'est fait beaucoup de choses â juste pas celles que tu avais prévues.`,"{done} of {total} done. Lock more days and the patterns show up.":`{done} sur {total} faites. Verrouille plus de jours et les tendances apparaîtront.`,"checking your connected toolsâ¦":`vérification de tes outils connectésâ¦`,"this day is closed â you can only backfill a task up to noon the next day. after that, the day's locked in as it stands.":`ce jour est clôturé â tu ne peux rattraper une tâche que jusqu'à midi le lendemain. après ça, le jour reste figé tel quel.`,"Found a match in {app}: {evidence}":`Correspondance trouvée dans {app} : {evidence}`,"markingâ¦":`marquageâ¦`,"nothing matched automatically â what's the proof this actually happened?":`rien n'a correspondu automatiquement â quelle est la preuve que c'est bien arrivé ?`,"e.g. sent 12 emails via Gmail that day (screenshot on file)":`ex. 12 emails envoyés via Gmail ce jour-là (capture à l'appui)`,"{pct}% of my locked priorities done this week building {prod} â tracked on Crew.":`{pct}% de mes priorités verrouillées faites cette semaine en construisant {prod} â suivi sur Crew.`,"loading momentumâ¦":`chargement de l'élanâ¦`,"no days locked yet. set today's 3 on the Today page to start building momentum.":`aucun jour verrouillé pour l'instant. verrouille tes 3 du jour sur la page Aujourd'hui pour lancer l'élan.`,"lock today's tasks":`verrouiller les tâches du jour`,"open today":`ouvrir aujourd'hui`,"nothing locked in yet today.":`rien de verrouillé aujourd'hui pour l'instant.`,"Current streak":`série en cours`,days:`jours`,best:`record`,"locked by 9am":`verrouillé avant 9h`,"crew read":`lecture crew`,"This week":`cette semaine`,DONE:`FAIT`,"tasks shipped":`tâches livrées`,"on track":`sur la bonne voie`,"best streak":`record de série`,"Output over time":`production dans le temps`,"Cumulative tasks done":`tâches faites cumulées`,"Tasks done":`tâches faites`,All:`tout`,Day:`jour`,Week:`semaine`,Month:`mois`,"Recent activity":`activité récente`,"View all ({n})":`tout voir ({n})`,"Show less":`voir moins`,"nothing logged yet.":`rien d'enregistré pour l'instant.`,"you ship most the builds â but sales tasks slip *{n}à in {days} days.* flip the order.":`tu livres la plupart des builds â mais les tâches sales glissent *{n}à en {days} jours.* inverse l'ordre.`,"no tasks logged in the last 7 days. *lock today's 3* to restart momentum.":`aucune tâche enregistrée ces 7 derniers jours. *verrouille tes 3 du jour* pour relancer l'élan.`,"you locked {total} tasks this week but *shipped none.* nothing's moving â pick one and close it today.":`tu as verrouillé {total} tâches cette semaine mais *aucune livrée.* rien ne bouge â prends-en une et boucle-la aujourd'hui.`,"only *{pct}% done this week* ({done}/{total}). you're locking tasks but not closing them.":`seulement *{pct}% fait cette semaine* ({done}/{total}). tu verrouilles des tâches mais tu ne les boucles pas.`,"*{pct}% completion* this week ({done}/{total}) â {slip} slipped. tighten it.":`*{pct}% de complétion* cette semaine ({done}/{total}) â {slip} manquées. resserre.`,"steady execution â *{pct}
49% done* across the week. keep the cadence.":`exécution régulière â *{pct}% fait* sur la semaine. garde le rythme.`,staged:`planifiées`,"stage a task for this dayâ¦":`planifier une tâche pour ce jourâ¦`,sync:`synchro`,events:`événements`,event:`événement`,"open in google calendar â":`ouvrir dans google agenda â`,more:`plus`,"error: {e}":`erreur : {e}`,"synced {n} events":`{n} événements synchronisés`,"previous month":`mois précédent`,"next month":`mois suivant`,"loading calendarâ¦":`chargement de l'agendaâ¦`,"crisis day":`jour de crise`,"deep work":`concentration`,"travel day":`jour de voyage`,offline:`hors ligne`,"one task is enough â no streak hit":`une tâche suffit â la série reste intacte`,"Crew goes quiet â one evening check only":`Crew se fait discret â un seul point le soir`,"light load, attestation ok":`charge légère, attestation ok`,"no pings, today won't count against you":`pas de pings, aujourd'hui ne te sera pas compté`,"you've used both crisis days this month â go easy, not off":`tu as utilisé tes deux jours de crise ce mois-ci â lève le pied, sans t'arrêter`,"rough day?":`journée difficile ?`,"never mind":`laisse tomber`,"import from your tools":`importer depuis tes outils`,"no open items found in your connected tools.":`aucun élément ouvert trouvé dans tes outils connectés.`,"part of: {p}":`partie de : {p}`,"day {n}":`jour {n}`,change:`modifier`,"swap or drop this with a reason â counts as changed, not missed":`échange ou abandonne avec une raison â compté comme modifié, pas raté`,"you've used your 2 changes today â this one counts as a miss.":`tu as utilisé tes 2 changements du jour â celui-ci compte comme un raté.`,"renegotiate this task â it'll read as changed, not missed. ({n} left today)":`renégocie cette tâche â elle sera lue comme modifiée, pas ratée. ({n} restant(s) aujourd'hui)`,"swap for⦠(leave as-is to just drop it)":`échanger contre⦠(laisse tel quel pour juste l'abandonner)`,"why? (one line)":`pourquoi ? (une ligne)`,swap:`échanger`,"drop (miss)":`abandonner (raté)`,drop:`abandonner`,"back at it â just lock in one to start. add more if you feel it.":`de retour â verrouille-en juste une pour commencer. ajoutes-en si tu le sens.`,"start with my usual {n}":`commencer avec mes {n} habituelles`,"+ one day of a bigger effort":`+ un jour d'un effort plus large`,"the bigger goal this is one day ofâ¦":`l'objectif plus large dont c'est un jourâ¦`,"not multi-day":`pas multi-jours`,"{n} still pending â mark today done anyway? they'll count as skipped, and any active pledge breaks.":`{n} encore en attente â marquer la journée comme faite quand même ? elles compteront comme passées, et tout engagement actif est rompu.`,"mark done anyway":`marquer fait quand même`,streak:`série`,"share streak â":`partager la série â`,"recover your streak":`récupérer ta série`,"1-day window · until midnight tomorrow":`fenêtre de 24 h · jusqu'à minuit demain`,"the run broke. three ways back, one day to use them.":`la série est rompue. trois façons de revenir, un jour pour les utiliser.`,"add late proof":`ajouter une preuve tardive`,"evidence you shipped but never logged. unlimited.":`des preuves de ce que tu as livré sans jamais l'enregistrer. illimité.`,"go to review â":`aller au bilan â`,"double day":`journée double`,"tomorrow's full set + yesterday's misses, all verified.":`toutes les tâches de demain + les ratés d'hier, toutes vérifiées.`,"used this month":`utilisé ce mois-ci`,"book it · once / month":`réserver · une fois / mois`,"pod vouch":`garantie du pod`,"{name} confirms you worked â their name stays on the record.":`{name} confirme que tu as travaillé â son nom reste au dossier.`,"used this quarter":`utilisé ce trimestre`,"{name} vouches · once / quarter":`{name} se porte garant · une fois / trimestre`,"needs an active pod â no partner yet.":`nécessite un pod actif â pas encore de partenaire.`,"double day already used this month":`journée double déjà utilisée ce mois-ci`,"booked â finish tomorrow's set + yesterday's misses, all verified":`réservé â termine les tâches de demain + les ratés d'hier, toutes vérifiées`,"pod vouch already used this quarter":`garantie du pod déjà utilisée ce trimestre`,"{name} vouched â recorded for good":`{name} s'est porté garant â enregistré pour de bon`,"current streak":`série actuelle`,"days ·
49since {date}":`jours · depuis le {date}`,"lock today's 3 to start one":`verrouille tes 3 du jour pour en démarrer une`,"next milestone: {n} days · {d} to go":`prochain palier : {n} jours · {d} restant(s)`,"best ever":`record`,"no streak yet":`pas encore de série`,"you're living it right now":`tu es en train de le vivre`,"{n} days to beat it":`{n} jours pour le battre`,"last {range}":`période : {range}`,"last week":`la semaine écoulée`,"last 14 days":`les 14 derniers jours`,"last month":`le mois écoulé`,"last year":`l'année écoulée`,week:`semaine`,"14 days":`14 jours`,month:`mois`,year:`année`,"no days locked yet.":`aucun jour verrouillé pour l'instant.`,less:`moins`,"+{n} more":`+{n} de plus`,"carry from yesterday":`reprendre d'hier`,"dismiss tip":`masquer l'astuce`,"these pings get sharper once crew knows your business â you haven't added your context yet.":`ces notifications deviennent plus précises quand crew connaît ton activité â tu n'as pas encore ajouté ton contexte.`,"add it â":`ajouter â`,"go to dashboard":`aller au tableau de bord`,"set today's tasks":`définir tes tâches du jour`,"new password":`nouveau mot de passe`,"confirm new password":`confirme le nouveau mot de passe`,"min 8 characters. signed up with Google or GitHub? this sets a password you can also use to log in.":`8 caractères minimum. inscrit avec Google ou GitHub ? ça crée un mot de passe que tu pourras aussi utiliser pour te connecter.`,"update password":`mettre à jour le mot de passe`,"updatingâ¦":`mise à jourâ¦`,"password updated":`mot de passe mis à jour`,"password must be at least 8 characters.":`le mot de passe doit faire au moins 8 caractères.`,"the two passwords don't match.":`les deux mots de passe ne correspondent pas.`,"could not update your password. try again.":`impossible de mettre à jour ton mot de passe. réessaie.`,"tag each one: build = the product itself · sales = customers · ops = keeps the business running":`classe chacune : build = le produit · sales = les clients · ops = ce qui fait tourner la boîte`,"build â the product itself: code, design, the thing you're making":`build â le produit lui-même : code, design, ce que tu construis`,"sales â getting or talking to customers: outreach, demos, follow-ups, marketing":`sales â trouver et parler aux clients : prospection, démos, relances, marketing`,"ops â keeps the business running: admin, finance, hiring, legal, support":`ops â ce qui fait tourner la boîte : admin, finance, recrutement, juridique, support`,"lock in today's 3 tasks":`verrouille tes 3 tâches du jour`,"crew pings you before your inbox. you commit to three real tasks for today, each one a step toward your one big goal.":`crew te ping avant ta boîte mail. tu t'engages sur trois vraies tâches pour aujourd'hui, chacune un pas vers ton grand objectif.`,"steady progress toward your one big goal":`une progression régulière vers ton grand objectif`,"every day's 3 tasks stay pointed at the number you just set â not busywork that feels like motion.":`les 3 tâches de chaque journée restent braquées sur le chiffre que tu viens de fixer â pas de l'agitation qui donne l'illusion d'avancer.`,"read-only. crew reads your events and busy blocks so it can tell a meeting from real work. it never creates, edits, or sends anything on your behalf.":`lecture seule. crew lit tes événements et tes créneaux occupés pour distinguer une réunion d'un vrai travail. il ne crée, ne modifie et n'envoie jamais rien en ton nom.`,"more connectors (GitHub, Google Calendar, Vercel, X, Discord, Gmailâ¦) in Settings â all read-only":`plus de connecteurs (GitHub, Google Agenda, Vercel, X, Discord, Gmailâ¦) dans Réglages â tous en lecture seule`,"skipping is genuinely fine â crew works without this. connect it later from settings once you've seen what crew does.":`passer cette étape ne pose vraiment aucun problème â crew fonctionne sans. tu pourras le connecter plus tard depuis les réglages, une fois que tu auras vu ce que crew fait.`,"your morning and evening pings land in telegram â free, no phone number needed. it's a one-way channel out to you, plus whatever you reply back to crew. crew reads nothing else on telegram.":`tes pings du matin et du soir arrivent sur telegram â gratuit, sans numéro de téléphone. c'est un canal à sens unique vers toi, plus ce que tu réponds à crew. crew ne lit rien d'autre sur telegram.`,"skipping is genuinely fine â crew still runs in the browser. you can connect telegram later from settings.":`passer cette étape ne pose vraiment aucun problème â crew tourne aussi dans le navigateur. tu pourras connecter telegram plus tard depuis les réglages.`,'it only screenshots when you click "check" â automatic mode stays off unless you turn it on yourself.':`il ne prend une capture que quand tu cliques sur « check » â le mode automatique reste désactivé tant que tu ne l'actives pas toi-même.`,"a screenshot is sent once to Anthropic for that single review, and is never written to a file anywhere â not on your device, not on crew's servers.":`une capture est envoyée une seule fois à Anthropic pour cette vérification, et n'est jamais écrite dans un fichier où que ce soit â ni sur ton appareil, ni sur les serveurs de crew.`,"only the resulting done / not-done decision is kept.":`seule la décision fait / pas fait est conservée.`,"read-only, like everything else here: it looks at a page to verify a task, and never posts, sends, or acts as you. it's the closest thing to zero self-reporting.":`en lecture seule, comme tout le reste ici : il regarde une page pour vérifier une tâche, et ne publie, n'envoie et n'agit jamais à ta place. c'est ce qui se rapproche le plus du zéro auto-déclaration.`,"not on the Chrome Web Store yet â this is the manual install. works on Chrome, Edge, Brave, and Atlas. skipping is genuinely fine â you can install it later from settings.":`pas encore sur le Chrome Web Store â c'est l'installation manuelle. fonctionne sur Chrome, Edge, Brave et Atlas. passer cette étape ne pose vraiment aucun problème â tu pourras l'installer plus tard depuis les réglages.`,"your one big goal":`ton grand objectif`,"this is not today's to-do list. it's the single outcome you're driving at over the next 30 to 90 days â one goal, one number, one date.":`ce n'est pas ta liste de tâches du jour. c'est le seul résultat que tu vises sur les 30 à 90 proch
49ains jours â un objectif, un chiffre, une date.`,"the one outcome (30â90 days)":`le résultat unique (30â90 jours)`,"e.g. 3 paying customers on the paid plan":`ex. 3 clients payants sur l'offre payante`,"your 3 tasks for today come next â you'll set those on the today page once you're inside crew. crew keeps them pointed at this goal.":`tes 3 tâches du jour viennent juste après â tu les définiras sur la page aujourd'hui une fois dans crew. crew les garde pointées sur cet objectif.`,"could not read that image":`impossible de lire cette image`,"could not capture this page":`impossible de capturer cette page`,"press âV to paste a screenshot, or attach one":`fais âV pour coller une capture, ou joins-en une`,"could not send â try again":`envoi impossible â réessaie`,"Share feedback on this page":`donner un retour sur cette page`,"Send feedback":`envoyer un retour`,"circle what you mean":`entoure ce que tu veux montrer`,"tell us about it":`raconte`,"capture what i see":`capturer ce que je vois`,"this screen as it looks now â then point at anything":`cet écran tel quel â puis pointe ce que tu veux`,"attach a screenshot":`joindre une capture`,"or just press âV to paste one":`ou fais âV pour en coller une`,"just tell us":`juste vous le dire`,"an idea, a nitpick, anything":`une idée, un détail, n'importe quoi`,"Clear marks":`effacer les annotations`,back:`retour`,"next â":`suivant â`,"{n} marks â edit":`{n} annotations â modifier`,"screenshot attached â add marks":`capture jointe â annote-la`,"what's this about?":`c'est à propos de quoi ?`,"how bad is it?":`c'est grave comment ?`,"what's on your mind?":`qu'est-ce que tu as en tête ?`,"whatever's on your mind â an idea, something confusing, something broken":`ce que tu as en tête â une idée, un truc pas clair, un truc cassé`,"got it â thank you.":`reçu â merci.`,"capturingâ¦":`captureâ¦`,"still workingâ¦":`encore un instantâ¦`,"one more tryâ¦":`dernier essaiâ¦`,"something is broken":`quelque chose est cassé`,"i want something":`je veux un truc`,"a connector":`un connecteur`,"a verdict was wrong":`un verdict était faux`,"slow or janky":`lent ou saccadé`,"account or billing":`compte ou facturation`,"ONE LINE FOR YOUR HEAD":`UNE LIGNE à GARDER EN TÃTE`,"LOCKED FOR TODAY":`VERROUILLà POUR AUJOURD'HUI`,"switch to dark mode":`passer en mode sombre`,"switch to light mode":`passer en mode clair`,You:`Toi`,proof:`preuve`,"Crew is typing":`Crew écrit`,"before you go":`avant de partir`,"you've verified {v} tasks across {d} shipped days. this record â your proof of execution â deletes with you.":`tu as vérifié {v} tâches sur {d} jours livrés. cet historique vérifié â ta preuve d'exécution â disparaît avec toi.`,"this is your verified execution record â proof of what you actually shipped.":`c'est ton historique d'exécution vérifié â la preuve de ce que tu as vraiment livré.`,"need a break? take a":`besoin d'une pause ? prends un`,"30-day freeze":`gel de 30 jours`,"instead: streak and history stay intact, no pings, pick up exactly where you left off.":`à la place : série et historique intacts, zéro ping, tu reprends exactement où tu t'es arrêté.`,"continue to cancel":`continuer vers l'annulation`,"pausingâ¦":`mise en pauseâ¦`,"pause 30 days":`geler 30 jours`,"deep 1:1 · founder":`1:1 approfondi · founder`,"wins:":`victoires :`,"next week:":`la semaine prochaine :`,"the weekly Deep 1:1 is a Founder feature â a real co-founder review of your patterns, avoidance, and next week's call. upgrade in settings to unlock it.":`le 1:1 approfondi hebdo est réservé à la formule founder â une vraie revue de co-fondateur sur tes schémas, tes évitements et le pari de la semaine à venir. passe au payant dans les paramètres pour le débloquer.`,"generate your weekly co-founder review â patterns, avoidance analysis, and next week's one call.":`génère ta revue hebdo de co-fondateur â schémas, analyse des évitements, et le pari unique de la semaine prochaine.`,"regenerate â":`régénérer â`,"generate weekly review â":`générer la revue hebdo â`,"your last 7 days · verified by crew":`tes 7 derniers jours · vérifiés par crew`,"receipts, not self-reports":`des reçus, pas des déclarations`,"shipped across":`livrés sur`,"day â pulled straight from your commits.":`jour â tirés direct de tes commits.`,"days â pulled straight from your commits.":`jours â tirés direct de tes commits.`,"you're in passive mode â Crew's watching and will nudge you. lock in your daily 3 whenever you're ready.":`tu es en mode passif â crew regarde et te relancera. verrouille tes 3 du jour quand tu es prêt.`,"just now":`à l'instant`,"{n}m ago":`il y a {n} min`,"{n}h ago":`il y a {n} h`,"{n}d ago":`il y a {n} j`,"mark all read":`tout marquer lu`,"nothing yet. Crew will reach out when something needs you.":`rien pour l'instant. crew te fera signe quand quelque chose aura besoin de toi.`,"{name} needs reconnecting â Crew can't verify tasks from it until you do.":`{name} doit être reconnecté â d'ici là , crew ne peut plus vérifier tes tâches via cet outil.`,"{n} connectors need reconnecting ({names}) â Crew can't verify tasks from them until you do.":`{n}
49 connecteurs à reconnecter ({names}) â d'ici là , crew ne peut plus vérifier tes tâches via ces outils.`,"reconnect â":`reconnecter â`,dismiss:`masquer`,"Task receipt":`reçu de la tâche`,receipt:`reçu`,"no receipt attached":`aucun reçu joint`,"real-time receipts from GitHub + calendar once integrations are connected":`des reçus en temps réel depuis GitHub + l'agenda une fois les intégrations connectées`,"why this matters":`pourquoi c'est important`,"rolled on":`reportée le`,"is an avoidance pattern":`est un schéma d'évitement`,"tasks skipped 3+ times in a row are flagged as drift â crew will ask about this":`une tâche passée 3 fois d'affilée ou plus est marquée en dérive â crew t'en parlera`,"live link â updates automatically":`lien live â se met à jour tout seul`,"make it a live link":`en faire un lien live`,"the link + X post show your current stats and refresh as you ship. the downloaded image is always a snapshot.":`le lien + le post X montrent tes stats du moment et se rafraîchissent au fil de tes livraisons. l'image téléchargée reste un instantané.`,"off: a snapshot of right now. on: a link that stays up to date.":`désactivé : un instantané de maintenant. activé : un lien qui reste à jour.`,"share on ð":`partager sur ð`,"link copied â":`lien copié â`,"copy link":`copier le lien`,"renderingâ¦":`renduâ¦`,"download image":`télécharger l'image`,"meetcrew.app · accountability for founders":`meetcrew.app · l'exécution vérifiée, pour fondateurs`,"all-time follow-through":`parole tenue, depuis le début`,"current mode":`mode actuel`,"building like":`construit comme`,"days locked in a row":`jours verrouillés d'affilée`,"every day I lock in my priorities and ship them, the plant grows.":`chaque jour où je verrouille mes priorités et je les livre, la plante pousse.`,"one lost day resets it to a seed.":`un jour perdu la ramène à la graine.`,"miss a day and it wilts.":`rate un jour et elle fane.`,"personal best, right now":`record personnel, en ce moment même`,day:`jour`,"lock today to plant it":`verrouille aujourd'hui pour la planter`,"weekly receipt":`reçu de la semaine`,completed:`complété`,"shipped this week":`livré cette semaine`,"Verified after its day":`vérifiée après son jour`,"Verified against evidence":`vérifiée sur preuves`,verified:`vérifiée`,late:`en retard`,"You said you did it â no tool could prove it":`tu dis l'avoir fait â aucun outil n'a pu le prouver`,"self-attested":`sur parole`,"via Claude":`via Claude`,"via extension":`via l'extension`,"via admin":`via admin`,"This row was written by an agent, not typed by you":`cette ligne a été écrite par un agent, pas tapée par toi`,"Not done":`non faite`,missed:`ratée`,"all time":`depuis le début`,"this week's follow-through":`parole tenue, cette semaine`,"my startup":`ma startup`,"all-time":`depuis le début`,"proof rate":`taux de preuve`,"Share your proof rate":`partager ton taux de preuve`,"share â":`partager â`,"I'm {pct}% locked-in on {who} {span} â building the habit with Crew.":`je tiens parole à {pct}% sur {who} {span} â l'habitude se construit avec Crew.`,"I'm in {mode} â shipping like {founder} ({tag}), {pct}% {span} follow-through on {who}, tracked with Crew.":`je suis en {mode} â je livre comme {founder} ({tag}), {pct}% de parole tenue {span} sur {who}, suivi avec Crew.`,"connector-verified":`vérifié par connecteur`,"self-reported":`déclaré sur parole`,slipped:`manqué`,"{n} shipped this week":`{n} livrées cette semaine`,"{n} slipped":`{n} manquées`,"lock your 3 on the today page to appear here.":`verrouille tes 3 sur la page aujourd'hui pour apparaître ici.`,"no messages yet â say something to the pod.":`pas encore de messages â dis quelque chose au pod.`,"message the podâ¦":`écris au podâ¦`,"enter a pod name":`donne un nom au pod`,"something went wrong":`un truc a raté`,"enter an invite code":`entre un code d'invitation`,"leave this pod? you can rejoin with the invite code.":`quitter ce pod ? tu peux revenir avec le code d'invitation.`,"your pod":`ton pod`,"pods are a solo+ feature":`les pods se débloquent à partir de solo`,"a pod is a private duo â you and one other founder see each other's verified receipts every day and week â no self-reporting, pulled from connected tools.":`un pod est un duo privé â toi et un autre fondateur voyez vos reçus vérifiés chaque jour et chaque semaine â zéro déclaration sur parole, tout vient des outils connectés.`,"{n} days left on trial":`{n} jours d'essai restants`,"upgrade in settings â":`passer au payant dans les paramètres â`,"a private duo â you + one other founder â seeing each other's verified receipts. done / skipped comes from Crew's verified verdicts â never self-reported.":`un duo privé â toi + un autre fondateur â qui voyez vos reçus vérifiés. fait / passé vient des verdicts vérifiés de crew â jamais d'auto-déclaration.`,"start a pod":`créer un pod`,"name your pod":`nomme ton pod`,"creatingâ¦":`créationâ¦`,"create pod â":`créer le pod â`,"join a pod":`rejoindre un pod`,"joiningâ¦":`on t'ajouteâ¦`,"join â":`rejoindre â`,Board:`Tableau`,"Pod Chat":`Chat du pod`,"{n} member":`{n} membre`,"{n} members":`{n} membres`,"duo complete":`duo au complet`,"invite link":`lien d'invitation`,"link copied!":`lien copié !`,"copy invite link":`copier le lien d'invitation`,leave:`quitter`,"loading boardâ¦":`chargement du tableauâ¦`,"copy your":`copie ton`,"(top right) and send it to one founder â clicking it forms your duo instantly.":`(en haut à droite) et envoie-le à un fondateur â un clic et votre duo est formé.`,"the board unlocks the moment they join.":`le tableau se débloque dès qu'il rejoint.`,goals:`objectifs`,"no goal for {name} yet.":`pas encore d'objectif pour {name}.`,"this company":`cette boîte`,"set your one goal for this companyâ¦":`fixe ton objectif unique pour cette boîteâ¦`,"set goal":`fixer l'objectif`,"no goal set yet â finish onboarding to lock your one goal.":`pas encore d'objectif â termine l'onboarding pour verrouiller ton objectif unique.`,"every milestone done. what gets locked in next?":`tous les jalons sont faits. on verrouille quoi ensuite ?`,"no milestones checked off yet. pick the smallest one and ship it today.":`aucun jalon coché pour l'instant. prends le plus petit et livre-le aujourd'hui.`,"{done} of {total} done. keep the momentum â don't let the streak break here.":`{done} sur {total} faits. garde l'élan â ne laisse pas la série casser ici.`,"{n} days left":`{n} jours restants`,"no milestones yet â break the goal down below.":`pas encore de jalons â découpe l'objectif ci-dessous.`,overdue:`en retard`,"Move up":`monter`,"Move down":`desce
49ndre`,"Delete milestone":`supprimer le jalon`,due:`échéance`,"en-US":`fr-FR`,"add a milestone":`ajouter un jalon`,completion:`complétion`,"milestones done":`jalons faits`,work:`travail`,time:`temps`,patterns:`tendances`,"avoidance pattern":`schéma d'évitement`,"nothing is slipping right now â every category is landing. keep the pressure on.":`rien ne glisse en ce moment â toutes les catégories atterrissent. garde la pression.`,"{cat} tasks slip {pct}% of the time â your weakest category. it's the same work getting pushed. not a time problem.":`les tâches {cat} glissent {pct}% du temps â ta catégorie la plus faible. c'est le même travail qui se fait repousser. pas un problème de temps.`,"{skipped} of {total} {cat} tasks skipped":`{skipped} tâches {cat} passées sur {total}`,"weekend edge":`avantage week-end`,"you complete {we}% of tasks on weekends vs {wd}% on weekdays{lift}. whatever's different on saturdays, replicate it.":`tu termines {we}% des tâches le week-end contre {wd}% en semaine{lift}. ce qui change le samedi, reproduis-le.`," â a {n}% lift":` â +{n}% d'écart`,"sat/sun: {we}% · monâfri: {wd}%":`sam/dim : {we}% · lunâven : {wd}%`,"where you're disciplined":`là où tu es discipliné`,"{cat} tasks: 0% slip across all {total}. you never let this one wait â that's your anchor habit.":`tâches {cat} : 0% de glissement sur les {total}. tu ne laisses jamais celle-là attendre â c'est ton habitude d'ancrage.`,"{cat} is your strongest category at {pct}% completion. lean on it.":`{cat} est ta catégorie la plus solide, {pct}% de complétion. appuie-toi dessus.`,"{done} of {total} {cat} done":`{done} {cat} faits sur {total}`,"strongest day":`meilleur jour`,"not enough days locked yet to find your strongest day.":`pas assez de jours verrouillés pour trouver ton meilleur jour.`,"{day} is your best day â {pct}% completion. put the work that matters most there.":`{day} est ton meilleur jour â {pct}% de complétion. mets-y le travail qui compte le plus.`,"{done} of {total} tasks done":`{done} tâches faites sur {total}`,'unstick "{task}"':`débloque « {task} »`,"it's slipped {n} days running. do it first thing tomorrow, or cut it â a task you keep dodging is costing you a slot every day.":`elle glisse depuis {n} jours d'affilée. fais-la en premier demain, ou coupe-la â une tâche que tu esquives te coûte une place chaque jour.`,"lock only one {cat} task tomorrow":`ne verrouille qu'une seule tâche {cat} demain`,"{cat} slips {pct}% of the time. stop batching it â commit to a single {cat} task and do it before anything else.":`{cat} glisse {pct}% du temps. arrête d'en empiler â engage-toi sur une seule tâche {cat} et fais-la avant tout le reste.`,"move your hardest task to the weekend":`déplace ta tâche la plus dure au week-end`,"you finish {we}% on weekends vs {wd}% on weekdays. put the task you most want to avoid on saturday morning.":`tu termines {we}% le week-end contre {wd}% en semaine. mets la tâche que tu veux le plus éviter le samedi matin.`,"put the work that matters most on {day}":`mets le travail qui compte le plus le {day}`,"you hit {pct}% on {day}s. deliberately schedule the work that moves your goal most on that day.":`tu es à {pct}% le {day}. programme délibérément ce jour-là le travail qui fait le plus avancer ton objectif.`,"rebuild your streak with 3 realistic tasks":`reconstruis ta série avec 3 tâches réalistes`,"your streak is broken. tomorrow, lock 3 tasks you're 90% sure you'll finish â momentum first, ambition second.":`ta série est cassée. demain, verrouille 3 tâches que tu es sûr à 90% de finir â l'élan d'abord, l'ambition ensuite.`,"what the last {n} tracked days say about how you actually work.":`ce que les {n} derniers jours suivis disent de ta vraie façon de travailler.`,"lock a few days to start seeing patterns.":`verrouille quelques jours pour voir apparaître des tendances.`,"no data yet â set today's 3 on the Today page. patterns appear after a few days.":`pas encore de données â fixe tes 3 du jour sur la page aujourd'hui. les tendances apparaissent après quelques jours.`,"{n}d":`{n} j`,"best {n}d":`record {n} j`,"last 7 days":`7 derniers jours`,"last 30 days":`30 derniers jours`,"days tracked":`jours suivis`,"what to do about it":`quoi faire maintenant`,"ranked by impact":`classé par impact`,now:`maintenant`,soon:`bientôt`,"ask about your patterns":`interroge tes tendances`,"crew has your real numbers â ask anything":`crew a tes vrais chiffres â demande ce que tu veux`,"dig into what's driving these numbers.":`creuse ce qui fait bouger ces chiffres.`,"ask about your patternsâ¦":`pose une question sur tes tendancesâ¦`,"what should i change this week?":`qu'est-ce que je change cette semaine ?`,"why do i keep slipping?":`pourquoi je glisse tout le temps ?`,"what's my biggest risk right now?":`c'est quoi mon plus gros risque, là ?`,Monday:`lundi`,Tuesday:`mardi`,Wednesday:`mercredi`,Thursday:`jeudi`,Friday:`vendredi`,Saturday:`samedi`,Sunday:`dimanche`,"The daily loop":`La boucle quotidienne`,"One day, accounted for.":`Une journée, tout est compté.`,"Crew pings at 7:30, locks your top 3, hands you one line of clarity â then at 8:30 it accounts for what you actually did and calls out the drift.":`Crew te ping à 7h30, verrouille ton top 3, te tend une ligne de clarté â puis à 20h30 il fait les comptes de ce que tu as vraiment fait et pointe la dérive.`,"01 · the ping":`01 · le ping`,"it lands on your lock screen. morning to set the 3, evening to account for them.":`il atterrit sur ton écran verrouillé. le matin pour fixer les 3, le soir pour en rendre compte.`,"02 · the thread":`02 · le fil`,"the whole day, start to finish. play it.":`la journée entière, du début à la fin. lance-la.`,"03 · the evening reply":`03 · la réponse du soir`,"tap what actually got done. Crew accounts for it."
49:`touche ce qui a vraiment été fait. crew en fait les comptes.`,"Ping time":`moment du ping`,Morning:`Matin`,Evening:`Soir`,"Tuesday, June 9":`mardi 9 juin`,"playingâ¦":`lectureâ¦`,"â» replay the day":`â» rejouer la journée`,"â¶ play the day":`â¶ lancer la journée`,"tap your answer":`touche ta réponse`,"DRIFT â 3 days":`DÃRIVE â 3 jours`,"â» try another answer":`â» essayer une autre réponse`,"end of day. what actually got done?":`fin de journée. qu'est-ce qui a vraiment été fait ?`,"landing page's live, fixed the bug. didn't email the leads":`la landing est en ligne, bug corrigé. pas envoyé les emails aux prospects`,"landing's shipped â that's the big one, respect. but the leads? that's 3 days now you've dodged the exact same task. that's not \"no time\", it's avoidance. it's 2 emails. you're scared of the reply. send them before you sleep or it becomes tomorrow's number 1 â and we talk about why.":`la landing est livrée â c'est la grosse, respect. mais les prospects ? ça fait 3 jours que tu esquives exactement la même tâche. ce n'est pas « pas le temps », c'est de l'évitement. c'est 2 emails. tu as peur de la réponse. envoie-les avant de dormir ou ça devient le numéro 1 de demain â et on parlera du pourquoi.`,"all three. even the leads.":`les trois. même les prospects.`,"all three â even the leads. respect, that's the streak unbroken. don't get cocky on me: same again tomorrow.":`les trois â même les prospects. respect, la série tient. ne prends pas la grosse tête : pareil demain.`,"rough day. just the bug.":`journée dure. juste le bug.`,"the bug was comfort work and you know it. the leads are still sitting there. one email tonight, before you sleep â then we're even.":`le bug, c'était du travail de confort et tu le sais. les prospects sont toujours là . un email ce soir, avant de dormir â et on est quittes.`,"this card has expired or doesn't exist.":`cette carte a expiré ou n'existe pas.`,"what is crew? â":`c'est quoi crew ? â`,"built with crew â accountability for founders â":`fait avec crew â le co-fondateur qui vérifie â`,"â Back":`â Retour`,"FREE · no signup":`GRATUIT · sans inscription`,"What did you actually ship last week?":`Qu'as-tu vraiment livré la semaine dernière ?`,"Connect GitHub (read-only) and get a one-page retro of your real output â commits, PRs, and where the work went. Takes under a minute.":`Connecte GitHub (lecture seule) et reçois une rétro d'une page sur ta vraie production â commits, PRs, et où est passé le travail. Moins d'une minute.`,"Connect GitHub â get your retro":`Connecter GitHub â recevoir ta rétro`,"Read-only. We never write to your repos, and the token stays server-side.":`Lecture seule. On n'écrit jamais dans tes dépôts, et le jeton reste côté serveur.`,"Sending you to GitHubâ¦":`Direction GitHubâ¦`,"Reading last week from GitHubâ¦":`Lecture de ta semaine sur GitHubâ¦`,"Couldn't build your retro.":`Impossible de construire ta rétro.`,"Try again":`Réessayer`,"YOUR LAST 7 DAYS":`TES 7 DERNIERS JOURS`,", here's the receipt.":`, voilà le reçu.`,"No commits or PRs authored in the last 7 days on the repos we can see. That's the honest answer â sometimes a quiet week is a quiet week.":`Aucun commit ni PR sur les 7 derniers jours dans les dépôts visibles. C'est la réponse honnête â parfois une semaine calme est juste une semaine calme.`,commits:`commits`,"PRs opened":`PRs ouvertes`,"PRs merged":`PRs fusionnées`,"repo touched":`dépôt touché`,"repos touched":`dépôts touchés`,"Where the output went":`Où est allée la production`,"Everything here came from GitHub, so it's all build. Honest label, not a spun one.":`Tout ici vient de GitHub, donc c'est du build. Une étiquette honnête, pas enjolivée.`,"Repos you touched":`Les dépôts que tu as touchés`,commit:`commit`,"This is what you did.":`Voilà ce que tu as fait.`,"Crew is what happens when you say what you'll do":`Crew, c'est ce qui se passe quand tu annonces ce que tu vas faire`,first:`d'abord`,"Your task manager doesn't care if you lied to it. Crew checks the receipts.":`Ton gestionnaire de tâches se fiche que tu lui aies menti. Crew vérifie les reçus.`,"Get on the waitlist â":`Rejoindre la liste d'attente â`,"LIVE DEMO · no signup":`DÃMO LIVE · sans inscription`,"This is what the evening reconcile feels like.":`Voilà ce que fait le bilan du soir.`,"You committed to 3 things this morning. Crew checks the receipts â it doesn't take your word for it."
49:`Tu t'es engagé sur 3 choses ce matin. Crew vérifie les reçus â il ne te croit pas sur parole.`,"tonight · alex's 3":`ce soir · les 3 d'alex`,"run the reconcile â":`lancer le bilan â`,"Crew is checking connected toolsâ¦":`Crew vérifie les outils connectésâ¦`,"verdicts in":`verdicts rendus`,"ship the pricing page":`livrer la page de tarifs`,"email the 3 investor leads":`écrire aux 3 investisseurs`,"write the launch blog post":`écrire l'article de lancement`,"verified â":`vérifié â`,"you confirmed it shipped":`tu as confirmé que c'est livré`,"Crew couldn't verify this â did you ship it?":`Crew n'a pas pu vérifier â tu l'as livré ?`,skip:`passer`,"no evidence â logged as skipped":`aucune preuve â enregistré comme passé`,"every verdict is logged with a confidence score. below 0.75, Crew never asserts â it asks. that's the whole product: it can't be fooled, and it won't fool you.":`chaque verdict est enregistré avec un score de confiance. sous 0,75, crew n'affirme jamais â il demande. c'est tout le produit : on ne peut pas le berner, et il ne te bernera pas.`,"start your own â free â":`lance le tien â gratuit â`,"connect GitHub, lock your 3, get your first verified receipt in minutes.":`connecte GitHub, verrouille tes 3, reçois ton premier reçu vérifié en quelques minutes.`,LEGAL:`LÃGAL`,"Effective date: July 7, 2026 · Last updated: July 19, 2026":`Date d'entrée en vigueur : 7 juillet 2026 · Dernière mise à jour : 19 juillet 2026`,"Effective date: June 17, 2026 · Last updated: June 17, 2026":`Date d'entrée en vigueur : 17 juin 2026 · Dernière mise à jour : 17 juin 2026`,"â Back to Crew":`â Retour sur Crew`,INTERNAL:`INTERNE`,"Compliance & Data Flow":`Conformité & flux de données`,"Working document â scopes, justification, data flow, retention. Not user-facing.":`Document de travail â scopes, justification, flux de données, conservation. Non destiné aux utilisateurs.`,Subprocessors:`Sous-traitants`,"â Privacy":`â Confidentialité`,"â Privacy Policy":`â Politique de confidentialité`,"The third parties that process data on Crew's behalf. The providers that hold data are listed first and are bound by a data-processing agreement; the last three â Brave Search, Jina, and unavatar.io â are per-request lookup calls that store nothing, described under the table.":`Les tiers qui traitent des données pour le compte de Crew. Les prestataires qui détiennent des données sont listés en premier et liés par un accord de traitement des données ; les trois derniers â Brave Search, Jina et unavatar.io â sont des appels ponctuels qui ne stockent rien, décrits sous le tableau.`,"Crew shares data only with the service providers below, strictly to operate the product. We do not sell your data and we do not use it for advertising.":`Crew ne partage des données qu'avec les prestataires ci-dessous, strictement pour faire tourner le produit. On ne vend pas tes données et on ne les utilise pas pour de la publicité.`,Provider:`Prestataire`,Purpose:`Rôle`,"Data processed":`Données traitées`,Region:`Région`,"Database, authentication, storage, edge functions":`Base de données, authentification, stockage, fonctions edge`,"All account + app data (RLS-isolated); OAuth tokens encrypted in Vault":`Toutes les données de compte + d'app (isolées par RLS) ; jetons OAuth chiffrés dans Vault`,"AWS, USA / EU":`AWS, Ãtats-Unis / UE`,"Web app hosting + CDN + privacy-friendly analytics":`Hébergement de l'app web + CDN + analytique respectueuse de la vie privée`,"Static assets, server logs (IP, user agent), aggregate page-view/feature-usage events (no cookies, no cross-site tracking)":`Ressources statiques, journaux serveur (IP, user-agent), événements agrégés de pages vues et d'usage (sans cookies, sans suivi inter-sites)`,"USA / global edge":`Ãtats-Unis / edge mondial`,"AI co-founder reasoning + verification judgments":`Raisonnement du co-fondateur IA + verdicts de vérification`,"Task text, connected-tool evidence summaries, chat messages â sent per request, not used for training":`Texte des tâches, résumés de preuves des out
49ils connectés, messages de chat â envoyés à la requête, pas utilisés pour l'entraînement`,USA:`Ãtats-Unis`,"Read-only connector OAuth + data access (Stripe, Calendly, Gmail â GitHub, Vercel and Google Calendar connect directly to Crew instead)":`OAuth et accès aux données des connecteurs en lecture seule (Stripe, Calendly, Gmail â GitHub, Vercel et Google Agenda se connectent directement à Crew)`,"Connector OAuth tokens (held by Composio) + read-only item metadata":`Jetons OAuth des connecteurs (détenus par Composio) + métadonnées d'éléments en lecture seule`,"Subscription billing":`Facturation des abonnements`,"Email, payment method (held by Stripe â Crew never sees card data), subscription status":`E-mail, moyen de paiement (détenu par Stripe â Crew ne voit jamais les données de carte), statut d'abonnement`,"USA / global":`Ãtats-Unis / mondial`,"Transactional + accountability emails":`E-mails transactionnels + pings de responsabilisation`,"Email address, message content of morning/evening pings":`Adresse e-mail, contenu des pings du matin et du soir`,"Optional accountability messaging channel":`Canal de messagerie optionnel`,"Telegram chat id + message content (only if you connect Telegram)":`Identifiant de conversation Telegram + contenu des messages (seulement si tu connectes Telegram)`,global:`mondial`,"Optional read-only connector â Crew reads the channel you pick to look for evidence a task got done":`Connecteur optionnel en lecture seule â Crew lit le canal que tu choisis pour chercher la preuve qu'une tâche a été faite`,"Your Discord account id + messages in the channel you select; Crew stores a short excerpt (first 200 characters) of a matching message as evidence (only if you connect Discord)":`Ton identifiant de compte Discord + les messages du canal que tu sélectionnes ; Crew stocke un court extrait (200 premiers caractères) d'un message correspondant comme preuve (seulement si tu connectes Discord)`,"Web search when your Crew searches during a chat":`Recherche web quand ton Crew cherche pendant un chat`,"The search terms Crew composes for that search â sent per request, with no account identifier":`Les termes de recherche composés par Crew â envoyés à la requête, sans identifiant de compte`,'Reading the public content of a URL (chat "read this link", links you paste as proof); also the fallback web search when Brave returns nothing':`Lecture du contenu public d'une URL (« lis ce lien » en chat, liens collés comme preuve) ; aussi la recherche de secours quand Brave ne renvoie rien`,"The URL being read, or the search terms when it is the search fallback â sent per request, with no account identifier":`L'URL lue, ou les termes de recherche en cas de recours au secours â envoyés à la requête, sans identifiant de compte`,"Fetching the public profile picture of the well-known founder shown on a stat card or share card":`Récupération de la photo de profil publique du fondateur connu affiché sur une carte de stats ou de partage`,"That founder's public social handle (never yours) â and, when your browser loads the picture directly, your IP address and browser user-agent; no account identifier is ever sent":`Le pseudo public de ce fondateur (jamais le tien) â et, quand ton navigateur charge l'image directement, ton adresse IP et ton user-agent ; aucun identifiant de compte n'est jamais envoyé`,"Lookup calls (Brave Search, Jina, unavatar.io)":`Appels ponctuels (Brave Search, Jina, unavatar.io)`,"These three are not stores of your data â they are single, read-only calls. Brave Search is called from our servers only when your Crew decides to search the web during a chat, and receives only the search terms it composed. Jina is called to read a specific URL â one Crew was asked to read in chat, or one you pasted into a proof note â and also receives the search terms when a web search through Brave fails or returns nothing. Neither call carries your user id, email, or any other account identifier.":`Ces trois-là ne stockent pas tes données â ce sont des appels uniques, en lecture seule. Brave Search est appelé depuis nos serveurs seulement quand ton Crew décide de chercher sur le web pendant un chat, et ne reçoit que les termes de recherche qu'il a composés. Jina est appelé pour lire une URL précise â demandée en chat, ou collée dans une note de preuve â et reçoit aussi les termes de recherche quand une recherche via Brave échoue ou ne renvoie rien. Aucun de ces appels ne porte ton identifiant utilisateur, ton e-mail ni aucun autre identifiant de compte.`,"unavatar.io is an avatar-lookup service. Crew's stat cards and share cards show the face of a well-known foun
49der (for example the one whose completion rate your week most resembles), and unavatar.io resolves that founder's public social handle to their public profile picture. The handle sent is always that public figure's, never yours, and no account identifier is attached. On share cards the picture is fetched through Crew's own server, so unavatar.io sees only our server. On the in-app proof rate badge your browser loads the picture directly, which means unavatar.io sees your IP address and browser user-agent, the same as any image loaded from another domain.":`unavatar.io est un service de résolution d'avatars. Les cartes de stats et de partage de Crew montrent le visage d'un fondateur connu (par exemple celui dont le taux de complétion ressemble le plus à ta semaine), et unavatar.io résout le pseudo public de ce fondateur vers sa photo de profil publique. Le pseudo envoyé est toujours celui de cette personnalité publique, jamais le tien, et aucun identifiant de compte n'est joint. Sur les cartes de partage, l'image passe par le serveur de Crew, donc unavatar.io ne voit que notre serveur. Sur le badge de palier fondateur dans l'app, ton navigateur charge l'image directement, donc unavatar.io voit ton adresse IP et ton user-agent, comme pour toute image chargée depuis un autre domaine.`,Changes:`Modifications`,"We notify account holders by email at least 14 days before adding or replacing a subprocessor that handles personal data. Questions:":`Nous prévenons les titulaires de compte par e-mail au moins 14 jours avant d'ajouter ou de remplacer un sous-traitant qui traite des données personnelles. Questions :`,"32 read paths, re-checked against the live APIs every week. A dead one is caught by the check, not by your task failing to close.":`32 chemins de lecture, re-vérifiés chaque semaine sur les API réelles. Un lien mort est repéré par la vérification, pas par ta tâche qui ne se clôt pas.`,"priorities locked each morning by default â set anywhere from 3 to 10":`priorités verrouillées chaque matin par défaut â règle-les de 3 à 10`,"connectors required. proof can be a note, a link, a screenshot, or a voice message":`connecteur requis. une preuve, ça peut être une note, un lien, une capture ou un vocal`,"days free to start, no card. connect a tool later, or never":`jours gratuits pour commencer, sans carte. tu connecteras un outil plus tard, ou jamais`,"CREW COMPANION · CHROME EXTENSION":`CREW COMPANION · EXTENSION CHROME`,"Proof from the tab you are already on.":`La preuve, depuis l'onglet où tu es déjà .`,"Crew Companion is on the Chrome Web Store. Press Option+C on any tab and that screen becomes the proof for the task you locked â no screenshot folder, no upload, no describing it afterwards. It also works on Edge, Brave, Arc and Atlas.":`Crew Companion est sur le Chrome Web Store. Appuie sur Option+C dans n'importe quel onglet et cet écran devient la preuve de la tâche que tu as verrouillée â pas de dossier de captures, pas de téléversement, rien à raconter après coup. Marche aussi sur Edge, Brave, Arc et Atlas.`,"Option+C captures the current tab and files it against the right task":`Option+C capture l'onglet en cours et le classe sur la bonne tâche`,"Automatic detection exists, and stays off until you switch it on yourself":`La détection automatique existe, et reste désactivée tant que tu ne l'actives pas toi-même`,"Banking, webmail, private messaging, health, payroll and password managers are hard-blocked â it will not read them":`Banque, webmail, messageries privées, santé, paie et gestionnaires de mots de passe sont bloqués en dur â elle ne les lit pas`,"No host permissions are requested at install; the extension asks only if you turn automatic mode on":`Aucune permission de site n'est demandée à l'installation ; l'extension ne demande que si tu actives le mode automatique`,"install the extension â":`installer l'extension â`,"2 left today":`2 restantes aujourd'hui`,"captured with â¥C · verified":`capturé avec â¥C · vérifiée`,"press â¥C on the tab that proves it":`appuie sur â¥C dans l'onglet qui le prouve`,"EARLY ACCESS · INVITE ONLY":`ACCÃS ANTICIPà · SUR INVITATION`,"Lock your first day tomorrow morning.":`Verrouille ta première journée demain matin.`,"Crew is invite-only while we onboard founders one at a time. Join the waitlist and we send you a code and a 1:1 setup call.":`Crew est sur invitation le temps qu'on accompagne les fondateurs un par un. Rejoins la liste et on t'envoie un code et un appel de mise en route en 1:1.`,"free until launch":`gratuit jusqu'au lancement`,"1:1 onboarding call":`Appel d'onboarding en 1:1`,"No connectors needed":`Aucun connecteur requis`,"No credit card · no spam · leave anytime · takes 20 seconds":`Pas de carte · pas de spam · pars quand tu veux · 20 secondes`,"Already have an invite code?":`Tu as déjà un code d'invitation ?`,"create your account â":`crée ton compte â`,added:`ajoutée`,"clear today's mode":`retirer le mode du jour`,"Crew is reviewing your proofâ¦":`Crew examine ta preuveâ¦`,"â backed by same-day activity: ":`â appuyé par l'activité du jour : `,"add more detail or a better screenshot, then check again.":`ajoute du détail ou une meilleure capture, puis relance la vérification.`,"reviewingâ¦":`vérificationâ¦`,"recheck proof":`revérifier la preuve`,"check proof & mark done":`vérifier la preuve et marquer faite`,"your name, email, and language":`ton nom, ton e-mail et ta langue`,companies:`entreprises`,"companies, business context, daily priorities":`entreprises, contexte business, priorités du jour`,"your plan, invoices, and payment":`ta formule, tes factures et ton paiement`,"tools Crew reads for evidence + the extension":`les outils que Crew lit pour les preuves + l'extension`,"morning / midday / evening pings + rest days":`pings du matin / midi / soir + jours de repos`,"A small browser extension that watches only claude.ai (usage) and LinkedIn messaging (sent count) â nothing else â and checks a matching task off automatically. On a likely match it also takes a screenshot of that page as supp
49orting evidence; an unrelated page's screenshot is never even captured for review. Click the extension icon anytime to manually check a task against whatever page you're currently on.":`Une petite extension de navigateur qui surveille uniquement claude.ai (usage) et la messagerie LinkedIn (nombre de messages envoyés) â rien d'autre â et coche automatiquement une tâche qui correspond. En cas de correspondance probable, elle prend aussi une capture de cette page comme preuve à l'appui ; la capture d'une page sans rapport n'est même jamais prise. Clique sur l'icône de l'extension quand tu veux pour vérifier manuellement une tâche à partir de la page que tu consultes.`,"Automatic mode only watches the two domains listed; manual mode (click the icon) works on any page you're viewing, only when you ask it to.":`Le mode automatique ne surveille que les deux domaines listés ; le mode manuel (clic sur l'icône) marche sur n'importe quelle page que tu consultes, uniquement quand tu le demandes.`,"admin mode":`mode admin`,on:`activé`,off:`désactivé`,"correct a verdict crew got wrong on a past day â for fixing test runs, not for real streak history.":`corrige un verdict que crew a raté sur un jour passé â pour réparer des tests, pas pour retoucher une vraie série.`,yesterday:`hier`,"no tasks locked for this day.":`aucune tâche verrouillée pour ce jour.`,"crew judged":`crew a jugé`,"pair up with one other founder":`fais équipe avec un autre fondateur`,"a private accountability pod â you both see each other's verified receipts, every day.":`un pod privé â vous voyez chacun les reçus vérifiés de l'autre, tous les jours.`,"nothing locked this week yet.":`rien de verrouillé cette semaine pour l'instant.`,Pod:`Pod`,"+ add company":`+ ajouter une entreprise`,"Add a company to keep priorities, goals, and context separate per project.":`Ajoute une entreprise pour garder priorités, objectifs et contexte séparés par projet.`,switch:`basculer`,rename:`renommer`,"Company or project nameâ¦":`Nom de l'entreprise ou du projetâ¦`,"Company nameâ¦":`Nom de l'entrepriseâ¦`,"clear selection":`tout désélectionner`,"switch company":`changer d'entreprise`,"all companies":`toutes les entreprises`,"delete company":`supprimer l'entreprise`,"crew name":`nom du crew`,"how your AI co-founder signs off in Telegram":`la signature de ton co-fondateur IA sur Telegram`,"morning ping time":`heure du ping du matin`,"midday verify check time":`heure de la vérification de midi`,"evening ping time":`heure du ping du soir`,current:`actuel`,"you'll be redirected to a secure":`tu vas être redirigé vers un écran OAuth`,"OAuth screen to authorise the connection. crew never sees your passwords or credentials â composio manages it end-to-end.":`sécurisé pour autoriser la connexion. crew ne voit jamais tes mots de passe ni tes identifiants â composio gère tout de bout en bout.`,"connect â":`connecter â`,"command center navigation":`navigation du centre de commande`,"account navigation":`navigation du compte`,"prep tomorrow's 3 tasks":`prépare tes 3 tâches de demain`,"country code":`indicatif pays`,"email address":`adresse e-mail`,"today's tasks":`les tâches du jour`,"dashboard hero":`en-tête du tableau de bord`,"my history":`mon historique`,"your own record, day by day":`ton propre registre, jour après jour`,"{a} days locked · {e} with nothing locked · {d}/{l} tasks done":`{a} jours verrouillés · {e} sans rien de verrouillé · {d}/{l} tâches faites`,"a closed day keeps its count. a task you regret can be retracted â labelled, explained, still counted â because a delete that made a past day look better would make the whole record worthless. only days that have not happened yet can be deleted outright.":`un jour clos garde son compte. une tâche que tu regrettes peut être retirée â marquée, expliquée, toujours comptée â parce qu'une suppression qui embellirait un jour passé rendrait tout le registre sans valeur. seuls les jours qui n'ont pas encore eu lieu peuvent être supprimés pour de bon.`,previous:`précédent`,next:`suivant`,"failed to load":`chargement impossible`,"nothing here yet":`rien ici pour l'instant`,"nothing locked":`rien de verrouillé`,"nothing done":`rien de fait`,"good day":`bonne journée`,partial:`partielle`,upcoming:`à venir`,attested:`sur parole`,unplanned:`hors plan`,retracted:`retirée`,"retracted:":`retirée :`,"still counted in this day":`toujours comptée dans cette journée`,"still open â change it on the Today screen":`encore ouverte â change-la depuis l'écran Aujourd'hui`,retract:`retirer`,"retract it":`retirer la tâche`,"delete for good":`supprimer définitivement`,"why? one line.":`pourquoi ? une ligne.`,"this day hasn't happened yet, so nothing is scored â the task goes for good.":`ce jour n'a pas encore eu lieu, rien n'est compté â la tâche part pour de bon.`,"the task stays in this day's count. only its label changes, so the day can't
49come out better than you lived it.":`la tâche reste dans le compte de cette journée. seule son étiquette change, pour que le jour ne puisse pas ressortir meilleur que tu ne l'as vécu.`,"that day is already counted. retract the task instead â the day keeps its score either way.":`ce jour est déjà compté. retire la tâche plutôt â le score du jour ne bouge pas dans les deux cas.`,"that day isn't closed yet. change today's list on the Today screen, not here.":`ce jour n'est pas encore clos. change la liste du jour depuis l'écran Aujourd'hui, pas ici.`,"you finished it. a completed task stays in the record.":`tu l'as terminée. une tâche faite reste dans le registre.`,"that task isn't there anymore.":`cette tâche n'existe plus.`,"say why in one line.":`dis pourquoi en une ligne.`,"that didn't go through ({code})":`ça n'est pas passé ({code})`,send:`envoyer`,"access code":`code d'accès`,LIVE:`EN DIRECT`},fl=(0,_.createContext)({lang:`en`,setLang:()=>{}});function pl({children:e}){let[t,n]=(0,_.useState)(()=>{try{let e=localStorage.getItem(`crew.lang`);return e===`fr`||e===`en`?e:`en`}catch{return`en`}});function r(e){n(e);try{localStorage.setItem(`crew.lang`,e)}catch{}}return(0,R.jsx)(fl.Provider,{value:{lang:t,setLang:r},children:e})}function ml(){return(0,_.useContext)(fl)}function hl(){let{profile:e}=ll(),{lang:t,setLang:n}=ml();return(0,_.useEffect)(()=>{let r=e?.language;(r===`en`||r===`fr`)&&r!==t&&n(r)},[e?.language]),null}async function gl(e,t){await L.from(`profiles`).update({language:t}).eq(`id`,e)}function z(){let{lang:e}=ml();return t=>e===`fr`?dl[t]??t:t}async function _l(e){return L.from(`workspaces`).select(`*`).eq(`user_id`,e).order(`created_at`,{ascending:!0})}async function vl(e,t){return L.from(`workspaces`).insert({user_id:e,name:t}).select().single()}async function yl(e,t){return L.from(`workspaces`).update(t).eq(`id`,e)}async function bl(e){return L.from(`workspaces`).delete().eq(`id`,e)}var xl=(0,_.createContext)({workspaces:[],active:null,firstWorkspaceId:null,setActive:()=>{},create:async()=>null,rename:async()=>{},remove:async()=>{},loading:!1,refresh:async()=>{}}),Sl=`crew.activeWorkspace`;function Cl({children:e}){let{session:t}=ll(),n=t?.user.id,[r,i]=(0,_.useState)([]),[a,o]=(0,_.useState)(()=>{try{return localStorage.getItem(Sl)??null}catch{return null}}),[s,c]=(0,_.useState)(!1),l=(0,_.useCallback)(async()=>{if(!n){i([]);return}c(!0);let{data:e}=await _l(n);i(e??[]),c(!1)},[n]);(0,_.useEffect)(()=>
49{l()},[l]);function u(e){o(e);try{e?localStorage.setItem(Sl,e):localStorage.removeItem(Sl)}catch{}}async function d(e){if(!n)return null;let{data:t}=await vl(n,e.trim());return t&&(i(e=>[...e,t]),u(t.id)),t??null}async function f(e,t){await yl(e,{name:t.trim()}),i(n=>n.map(n=>n.id===e?{...n,name:t.trim()}:n))}async function p(e){await bl(e),i(t=>t.filter(t=>t.id!==e)),a===e&&u(null)}let m=r.find(e=>e.id===a)??null,h=r[0]?.id??null;return(0,R.jsx)(xl.Provider,{value:{workspaces:r,active:m,firstWorkspaceId:h,setActive:u,create:d,rename:f,remove:p,loading:s,refresh:l},children:e})}function wl(){return(0,_.useContext)(xl)}var Tl={wordmark:`_wordmark_rm9ec_5`,caret:`_caret_rm9ec_17`,"crew-caret":`_crew-caret_rm9ec_1`};function El({size:e=46,className:t}){return(0,R.jsxs)(`span`,{className:t?`${Tl.wordmark} ${t}`:Tl.wordmark,style:{"--size":`${e}px`},"aria-label":`crew`,children:[`crew`,(0,R.jsx)(`span`,{"aria-hidden":!0,className:Tl.caret})]})}function B(...e){return e.filter(Boolean).join(` `)}var Dl={row:`_row_7c0og_6`,crew:`_crew_7c0og_11`,user:`_user_7c0og_15`,bubbleWrap:`_bubbleWrap_7c0og_19`,label:`_label_7c0og_26`,bubble:`_bubble_7c0og_19`,crewBubble:`_crewBubble_7c0og_46`,userBubble:`_userBubble_7c0og_52`,proofImage:`_proofImage_7c0og_58`,bullet:`_bullet_7c0og_69`,spacer:`_spacer_7c0og_81`,chartsWrap:`_chartsWrap_7c0og_85`,chartCard:`_chartCard_7c0og_93`,chartHeader:`_chartHeader_7c0og_103`,chartTitle:`_chartTitle_7c0og_110`,chartTitleValue:`_chartTitleValue_7c0og_118`,chartSubtitle:`_chartSubtitle_7c0og_125`,barList:`_barList_7c0og_134`,barRow:`_barRow_7c0og_141`,barLabel:`_barLabel_7c0og_148`,barTrack:`_barTrack_7c0og_158`,barFill:`_barFill_7c0og_165`,barFillHighlight:`_barFillHighlight_7c0og_173`,barValue:`_barValue_7c0og_178`,barValueHighlight:`_barValueHighlight_7c0og_185`,progressTrack:`_progressTrack_7c0og_192`,progressFill:`_progressFill_7c0og_200`};function Ol(e){return e.split(/(\*\*[^*]+\*\*)/).map((e,t)=>e.startsWith(`**`)&&e.endsWith(`**`)?(0,R.jsx)(`strong`,{children:e.slice(2,-2)},t):e)}function kl({text:e}){return(0,R.jsx)(R.Fragment,{children:e.split(` 50`).map((e,t)=>e.startsWith(`- `)||e.startsWith(`⢠`)?(0,R.jsx)(`div`,{className:Dl.bullet,children:Ol(e.slice(2))},t):e.trim()?(0,R.jsx)(`div`,{children:Ol(e)},t):(0,R.jsx)(`div`,{className:Dl.spacer},t))})}function Al({from:e,children:t,imageUrl:n,className:r}){let i=z(),a=e===`crew`;return(0,R.jsx)(`div`,{className:B(Dl.row,a?Dl.crew:Dl.user),children:(0,R.jsxs)(`div`,{className:Dl.bubbleWrap,children:[(0,R.jsx)(`span`,{className:Dl.label,children:a?`Crew`:i(`You`)}),(0,R.jsxs)(`div`,{className:B(Dl.bubble,a?Dl.crewBubble:Dl.userBubble,r),children:[n&&(0,R.jsx)(`img`,{src:n,alt:i(`proof`),className:Dl.proofImage}),a?(0,R.jsx)(kl,{text:String(t)}):t]})]})})}var jl={card:`_card_3qcaf_6`,header:`_header_3qcaf_16`,list:`_list_3qcaf_24`,item:`_item_3qcaf_33`,num:`_num_3qcaf_39`,task:`_task_3qcaf_47`};function Ml({priorities:e,className:t}){let n=z();return(0,R.jsxs)(`div`,{className:B(jl.card,t),children:[(0,R.jsx)(`span`,{className:jl.header,children:n(`LOCKED FOR TODAY`)}),(0,R.jsx)(`ol`,{className:jl.list,children:e.map((e,t)=>(0,R.jsxs)(`li`,{className:jl.item,children:[(0,R.jsx)(`span`,{className:jl.num,children:t+1}),(0,R.jsx)(`span`,{className:jl.task,children:e})]},t))})]})}var Nl={badge:`_badge_n58qk_5`,sm:`_sm_n58qk_21`,md:`_md_n58qk_25`,glyph:`_glyph_n58qk_31`,label:`_label_n58qk_37`,sep:`_sep_n58qk_41`,source:`_source_n58qk_46`,late:`_late_n58qk_51`,verified:`_verified_n58qk_58`,verifiedLate:`_verifiedLate_n58qk_65`,attested:`_attested_n58qk_72`,missed:`_missed_n58qk_79`,actor:`_actor_n58qk_85`},Pl={claude_mcp:`via Claude`,extension:`via extension`,admin:`via admin`},Fl={github:`GitHub`,google_calendar:`Calendar`,gmail:`Gmail`,slack:`Slack`,notion:`Notion`,linear:`Linear`,vercel:`Vercel`,x:`X`,discord:`Discord`,"user-proof":`your proof`};function Il(e){return e.split(/[\s_-]+/).filter(Boolean).map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join(` `)}function Ll(e){let t=e.trim();return t?Fl[t]??Fl[t.toLowerCase()]??Il(t):``}var Rl=`·`;function zl({resolution:e,source:t,late:n,actor:r,size:i=`sm`}){let a=z();if(!e)return null;let o=i===`md`?Nl.md:Nl.sm,s=r?Pl[r]:void 0,c=s?(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`span`,{className:Nl.sep,"aria-hidden":`true`,children:Rl}),(0,R.jsx)(`span`,{className:Nl.actor,title:a(`This row was written by an agent, not typed by you`),children:a(s)})]}):null;if(e===`verified`){let e=t?Ll(t):``;return(0,R.jsxs)(`span`,{className:[Nl.badge,o,n?Nl.verifiedLate:Nl.verified].join(` `),title:a(n?`Verified after its day`:`Verified against evidence`),children:[(0,R.jsx)(`span`,{className:Nl.glyph,"aria-hidden":`true`,children:`â`}),(0,R.jsx)(`span`,{className:Nl.label,children:a(`verified`)}),e&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`span`,{className:Nl.sep,"aria-hidden":`true`,children:Rl}),(0,R.jsx)(`span`,{className:Nl.source,children:e})]}),n&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`span`,{className:Nl.sep,"aria-hidden":`true`,children:Rl}),(0,R.jsx)(`span`,{className:Nl.late,children:a(`late`)})]}),c]})}return e===`attested`?(0,R.jsxs)(`span`,{className:[Nl.badge,o,Nl.attested].join(` `),title:a(`You said you did it â no tool could prove it`),children:[(0,R.jsx)(`span`,{className:Nl.label,children:a(`self-attested`)}),c]}):(0,R.jsxs)(`span`,{className:[Nl.badge,o,Nl.missed].join(` `),title:a(`Not done`),children:[(0,R.jsx)(`span`,{className:Nl.label,children:a(`missed`)}),c]})}var Bl={box:`_box_1alb6_4`,checked:`_checked_1alb6_20`,check:`_check_1alb6_20`,loading:`_loading_1alb6_46`,pulse:`_pulse_1alb6_1`};function Vl({checked:e,onChange:t,label:n,id:r,className:i,loading:a}){return(0,R.jsx)(`button`,{type:`button`,id:r,role:`checkbox`,"aria-checked":e,"aria-busy":a||void 0,"aria-label":n,disabled:a,className:B(Bl.box,e&&Bl.checked,a&&Bl.loading,i),onClick:()=>t(!e),children:(0,R.jsx)(`svg`,{className:Bl.check,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`3.5`,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":!0,
50children:(0,R.jsx)(`path`,{d:`M5 13l4 4L19 7`})})})}function Hl(){return typeof window<`u`}function Ul(){return`production`}function Wl(){return(Hl()?window.vam:Ul())||`production`}function Gl(){return Wl()===`production`}function Kl(){return Wl()===`development`}function ql(e,{[e]:t,...n}){return n}function Jl(e,t){if(!e)return;let n=e,r=[];for(let[i,a]of Object.entries(e))typeof a==`object`&&a&&(t.strip?n=ql(i,n):r.push(i));if(r.length>0&&!t.strip)throw Error(`The following properties are not valid: ${r.join(`, `)}. Only strings, numbers, booleans, and null are allowed.`);return n}function Yl(e,t,n){var r,i;if(!Hl()){let e="[Vercel Web Analytics] Please import `track` from `@vercel/analytics/server` when using this function in a server environment";if(Gl())console.warn(e);else throw Error(e);return}if(!t){(r=window.va)==null||r.call(window,`event`,{name:e,options:n});return}try{let r=Jl(t,{strip:Gl()});(i=window.va)==null||i.call(window,`event`,{name:e,data:r,options:n})}catch(e){e instanceof Error&&Kl()&&console.error(e)}}async function Xl(e){let t=br(yr.waitlist,[]);t.some(t=>t.email===e.email)||(t.push({...e,ts:Date.now()}),xr(yr.waitlist,t));let n={email:e.email,company:e.company,role:e.role,referral:e.referral??null};e.phone&&(n.phone=e.phone),e.wantsDemo&&(n.wants_demo=!0,e.demoNote&&(n.demo_note=e.demoNote.slice(0,400)));let{error:r}=await L.from(`waitlist_entries`).insert(n);return r?r.code===`23505`?{ok:!0}:(console.error(`[waitlist] insert failed:`,r.message,r.code),{ok:!1}):(Yl(`Waitlist Signup`,{referral:e.referral??`organic`}),{ok:!0})}function Zl(e=.12){let t=(0,_.useRef)(null),[n,r]=(0,_.useState)(!1);return(0,_.useEffect)(()=>{let n=t.current;if(!n)return;let i=new IntersectionObserver(([e])=>{e.isIntersecting&&(r(!0),i.disconnect())},{threshold:e});return i.observe(n),()=>i.disconnect()},[e]),[t,n]}var Ql=L;async function $l(e,t={}){try{let{data:{session:n}}=await L.auth.getSession();await Ql.from(`product_events`).insert({user_id:n?.user?.id??null,event:e,props:t})}catch{}}var eu={you:1,goal:2,verification:3,telegram:4,extension:5,lock_form:6,first_lock:7};function tu(e){try{let t=`crew.ob.${e}`;if(sessionStorage.getItem(t))return;sessionStorage.setItem(t,`1`)}catch{}$l(`onboarding_step`,{step:eu[e],name:e})}var nu=null;function ru(){return nu||(nu=sessionStorage.getItem(`crew.sid`)??``,nu||(nu=Math.random().toString(36).slice(2)+Math.random().toString(36).slice(2),sessionStorage.setItem(`crew.sid`,nu))),nu}async function iu(){try{let{data:{session:e}}=await L.auth.getSession();return e?.user?.id??null}catch{return null}}function au(){let e=window.innerWidth;return e<=768?`mobile`:e<=1024?`tablet`:`desktop`}function ou(){let e=document.referrer;if(!e)return`direct`;try{return new URL(e).hostname}catch{return e.slice(0,80)}}async function su(e){try{let{data:{session:t}}=await L.auth.getSession();if(!t)return;await Ql.from(`product_events`).insert({user_id:t.user.id,event:`app_view`,props:{path:e}})}catch{}}async function cu(e){try{await L.from(`page_events`).insert({user_id:await iu(),session_id:ru(),page:e,event_type:`view`,referrer:ou(),user_agent:navigator.userAgent.
50slice(0,200),device_type:au()})}catch{}}async function lu(e,t,n){try{let r=t/window.innerWidth*100,i=(window.scrollY+n)/Math.max(document.body.scrollHeight,1)*100;await L.from(`page_events`).insert({user_id:await iu(),session_id:ru(),page:`/`,event_type:`click`,element:e,x_pct:r,y_pct:i,device_type:au()})}catch{}}async function uu(e){try{await L.from(`page_events`).insert({user_id:await iu(),session_id:ru(),page:`/`,event_type:`scroll`,scroll_pct:e,device_type:au()})}catch{}}function du(){let e=[25,50,75,100],t=new Set;function n(){let n=(window.scrollY+window.innerHeight)/Math.max(document.body.scrollHeight,1)*100;for(let r of e)n>=r&&!t.has(r)&&(t.add(r),uu(r))}return window.addEventListener(`scroll`,n,{passive:!0}),()=>window.removeEventListener(`scroll`,n)}var fu=`(prefers-reduced-motion: reduce)`;function pu(){let[e,t]=(0,_.useState)(()=>typeof window<`u`&&typeof window.matchMedia==`function`?window.matchMedia(fu).matches:!1);return(0,_.useEffect)(()=>{if(typeof window.matchMedia!=`function`)return;let e=window.matchMedia(fu),n=()=>t(e.matches);return e.addEventListener(`change`,n),()=>e.removeEventListener(`change`,n)},[]),e}var mu={wrap:`_wrap_186da_1`,groundShadow:`_groundShadow_186da_11`,potRim:`_potRim_186da_12`,soilFleck:`_soilFleck_186da_13`,seed:`_seed_186da_15`,inProgress:`_inProgress_186da_19`,foliage:`_foliage_186da_24`,leaf:`_leaf_186da_25`,foliageHi:`_foliageHi_186da_28`,foliageLo:`_foliageLo_186da_29`,clumpHi:`_clumpHi_186da_31`,leafVein:`_leafVein_186da_33`,barkLine:`_barkLine_186da_35`,healthy:`_healthy_186da_37`,atRisk:`_atRisk_186da_38`,critical:`_critical_186da_41`,broken:`_broken_186da_42`,fallenLeaf:`_fallenLeaf_186da_46`,caption:`_caption_186da_48`,captionBroken:`_captionBroken_186da_57`,captionRisk:`_captionRisk_186da_58`,animSway:`_animSway_186da_74`,plantSway:`_plantSway_186da_1`,animWind:`_animWind_186da_75`,plantWind:`_plantWind_186da_1`,flyLeaf:`_flyLeaf_186da_80`,fallWrap:`_fallWrap_186da_80`,leafFlyoff:`_leafFlyoff_186da_1`,gust:`_gust_186da_96`,gustDrift:`_gustDrift_186da_1`,leafFall:`_leafFall_186da_1`,leafFlutter:`_leafFlutter_186da_1`},hu=10,gu=50;function _u(e){return e<=0?`seed`:e<=hu?`plant`:`tree`}var vu=80,yu=152;function bu(e,t,n){return e+(t-e)*n}function xu(e){return Math.max(0,Math.min(1,e))}function Su(e,t,n,r){let i=1-e;return[i*i*t[0]+2*i*e*n[0]+e*e*r[0],i*i*t[1]+2*i*e*n[1]+e*e*r[1]]}function Cu(e,t,n,r){let i=2*(1-e)*(n[0]-t[0])+2*e*(r[0]-n[0]),a=2*(1-e)*(n[1]-t[1])+2*e*(r[1]-n[1]),o=Math.hypot(i,a)||1;return[i/o,a/o]}function wu(e,t,n,r,i){let a=[],o=[];for(let s=0;s<=16;s++){let c=s/16,[l,u]=Su(c,e,t,n),[d,f]=Cu(c,e,t,n),p=-f,m=d,h=bu(r,i,c**.85);a.push([l+p*h,u+m*h]),o.push([l-p*h,u-m*h])}return`M ${[...a,...o.reverse()].map(e=>`${e[0].toFixed(1)} ${e[1].toFixed(1)}`).join(` L `)} Z`}function Tu(e){let t=e.length,n=`M ${e[0][0].toFixed(1)} ${e[0][1].toFixed(1)} `;for(let r=0;r<t;r++){let i=e[(r-1+t)%t],a=e[r],o=e[(r+1)%t],s=e[(r+2)%t],c=a[0]+(o[0]-i[0])/6,l=a[1]+(o[1]-i[1])/6,u=o[0]-(s[0]-a[0])/6,d=o[1]-(s[1]-a[1])/6;n+=`C ${c.toFixed(1)} ${l.toFixed(1)}, ${u.toFixed(1)} ${d.toFixed(1)}, ${o[0].toFixed(1)} ${o[1].toFixed(1)} `}return n+`Z`}var Eu={a:[.5,.9,.35,.75,.45,.85,.3,.7],b:[.7,.4,.85,.5,.75,.35,.65,.55],c:[.55,.8,.4,.7,.6,.45,.8,.5],d:[.6,.5,.75,.45,.7,.55,.5,.65],e:[.42,.68,.5,.82,.58,.72],hi:[.6,.75,.5,.7,.55,.65]};function Du(e,t,n,r,i=1,a=.16){let o=r.length,s=[];for(let c=0;c<o;c++){let l=c/o*Math.PI*2-Math.PI/2,u=n*(1-a/2+r[c]*a);s.push([e+Math.cos(l)*u,t+Math.sin(l)*u*i])}return Tu(s)}function Ou(e,t){return`M 0 0 Q ${e*.34} ${-t} ${e} 0 Q ${e*.34} ${t} 0 0 Z`}function ku(e){return`M ${(e*.08).toFixed(1)} 0 Q ${(e*.5).toFixed(1)} 0 ${(e*.9).toFixed(1)} 0`}var Au=[-140,-40],ju=[140,38];function Mu(e,t){let n=t?yu-e*.82:yu-e;return{p0:[vu,yu],p1:t?[vu+e*.5,yu-e*.35]:[vu-e*.15,yu-e*.55],p2:t?[vu+e*.6,n]:[vu,n]}}function Nu(e,t){let n=Math.max(1,Math.min(hu,e)),r=13+(n-1)*5.2,i=12+(n-1)*1.5,{p0:a,p1:o,p2:s}=Mu(r,t),c=wu(a,o,s,(t?3:2.4)+(n-1)*.12,.8),l=t?ju:Au;return{stem:c,leaves:Array.from({length:n},(e,t)=>{let[r,c]=Su(n===1?.62:.34+t/(n-1)*.6,a,o,s),u=.7+.3*(n===1?1:t/(n-1));return{x:r,y:c,angle:l[t%2],len:i*u}})}}var Pu=[{dx:0,dy:.18,r:.98,s:Eu.d},{dx:-.58,dy:.06,r:.64,s:Eu.a},{dx:.58,dy:.03,r:.64,s:Eu.b},{dx:-.3,dy:-.34,r:.66,s:Eu.c},{dx:.32,dy:-.36,r:.62,s:Eu.e},{dx:.02,dy:-.6,r:.56,s:Eu.a},{dx:-.62,dy:-.26,r:.46,s:Eu.b},{dx:.62,dy:-.24,r:.48,s:Eu.c}];function Fu(e){let t=xu((e-hu)/(gu-hu)),n=bu(58,86,t),r=yu-n*.5,i=yu-n,a=bu(4.2,8.5,t),o=[vu,yu],s=[vu-n*.05,yu-n*.28],c=[vu,r],l=wu(o,s,c,a,a*.62),u=[-.35,.15,.5].map(e=>{let t=[];for(let n=1;n<=5;n++){let r=n/6,[i,l]=Su(r,o,s,c),[,u]=Cu(r,o,s,c),d=-u;
50t.push(`${(i+d*a*e).toFixed(1)} ${l.toFixed(1)}`)}return`M `+t.join(` L `)}),d=bu(11,20,t),f=a*.55,p=[wu(c,[vu-d*.5,r-n*.14],[vu-d,i+n*.06],f,1.1),wu(c,[vu+d*.5,r-n*.12],[vu+d*.92,i+n*.1],f,1.1),wu(c,[vu+n*.02,r-n*.2],[82,i-n*.02],f*.9,1)],m=vu,h=i-bu(3,7,t),g=bu(19,33,t),_=t>.35?Pu.length:6,v=[];for(let e=0;e<_;e++){let t=Pu[e],n=m+t.dx*g,r=h+t.dy*g,i=t.r*g*.62;v.push({base:Du(n,r,i,t.s,1,.2),hi:Du(n-i*.3,r-i*.34,i*.42,Eu.hi,1,.2)})}return{trunk:l,barks:u,branches:p,clumps:v,shade:Du(m+g*.3,h+g*.6,g*.85,Eu.b,.7,.14),hi:Du(m-g*.4,h-g*.4,g*.5,Eu.hi,1,.2),crown:{cx:m,cy:h,R:g}}}function Iu(e){return e.map(([e,t],n)=>({x:e,y:t,size:4.5+n%3,style:{"--tx":`${46+n*9}px`,"--ty":`${-18+n%3*15}px`,"--r":`${150+n*55}deg`,"--delay":`${(n*.18).toFixed(2)}s`,"--dur":`${(1.2+n*.1).toFixed(2)}s`}}))}function Lu(e){return e.map(([e,t],n)=>({x:e,y:t,size:4.5+n%3,style:{"--tx":`${(n%2?1:-1)*(4+n*2)}px`,"--ty":`${78+n*7}px`,"--delay":`${(n*.26).toFixed(2)}s`,"--dur":`${(2.1+n*.14).toFixed(2)}s`}}))}function Ru(e,t){return Array.from({length:t},(n,r)=>[e.cx+(-.4+r/(t-1)*.9)*e.R,e.cy+(-.55+r*41%100/100*1.1)*e.R])}function zu(e,t){return Array.from({length:t},(n,r)=>{let i=r/t*Math.PI*2;return[e.cx+Math.cos(i)*e.R*.55,e.cy+Math.sin(i)*e.R*.45]})}function Bu(e){return[[-.2,-.3],[.1,.1],[-.1,.4]].map((t,n)=>{let r=e.cx+t[0]*e.R,i=e.cy+t[1]*e.R;return{d:`M ${r.toFixed(1)} ${i.toFixed(1)} q 18 -3 34 1 q 10 3 20 0`,delay:n*.3}})}function Vu(e,t,n,r,i,a,o){return o===`dead`?e(`your plant died â {n} days lost. plant a new one today.`).replace(`{n}`,String(n)):o===`critical`?e(`your plant's dying â finish ALL of today's tasks to save it.`):o===`wilting`?e(`your plant's wilting â you have today to revive it. hit your tasks.`):r?e(`the run ended. {n} days went unverified. plant today to grow again.`).replace(`{n}`,String(n)):i?e(`today isn't locked in â lock in before it blows away.`):a?e(`today's still growing â lock in the rest to keep it.`):t<=0?e(`plant your first day.`):t===1?e(`a seed no more â day one.`):e(`{n} days growing.`).replace(`{n}`,String(t))}function Hu({streak:e,longestStreak:t,atRisk:n=!1,inProgress:r=!1,health:i,size:a=140,showCaption:o=!0,className:s}){let c=z(),l=pu(),u=(0,_.useId)().replace(/:/g,``),d=i===`wilting`,f=i===`critical`,p=i?i===`dead`:e<=0&&t>0;n=i?d||f:n,r=i?i===`in-progress`:r;let m=p?t:e,h=_u(m),g=Vu(c,e,t,p,n,r,i),v=p?mu.broken:f?B(mu.atRisk,mu.critical):n?mu.atRisk:r?mu.inProgress:mu.healthy,y=l||p||h===`seed`&&!r?``:n?mu.animWind:mu.animSway,b=h===`plant`?Nu(m,p||f):null,x=h===`tree`?Fu(m):null,S=b?b.leaves.map(e=>[e.x,e.y]):[],C=!l&&h!==`seed`&&(n||p),w=x?Ru(x.crown,9):S,T=x?zu(x.crown,7):S,E=C?n?Iu(w):Lu(T):[],D=n?mu.flyLeaf:mu.fallWrap,O=C&&n&&x?Bu(x.crown):[];return(0,R.jsxs)(`div`,{className:B(mu.wrap,s),style:{width:a},children:[(0,R.jsxs)(`svg`,{viewBox:`0 0 160 190`,width:`100%`,role:`img`,"aria-label":g,children:[(0,R.jsxs)(`defs`,{children:[(0,R.jsxs)(`linearGradient`,{id:`pot-${u}`,x1:`0`,y1:`0`,x2:`0`,y2:`1`,children:[(0,R.jsx)(`stop`,{offset:`0%`,stopColor:`#b8815c`}),(0,R.jsx)(`stop`,{offset:`100%`,stopColor:`#8f5c3d`})]}),(0,R.jsxs)(`linearGradient`,{id:`soil-${u}`,x1:`0`,y1:`0`,x2:`0`,y2:`1`,children:[(0,R.jsx)(`stop`,{offset:`0%`,stopColor:`#5b4636`}),(0,R.jsx)(`stop`,{offset:`100%`,stopColor:`#3e2f24`})]}),(0,R.jsxs)(`linearGradient`,{id:`bark-${u}`,x1:`0`,y1:`1`,x2:`0.25`,y2:`0`,children:[(0,R.jsx)(`stop`,{offset:`0%`,stopColor:`#5c3a1e`}),(0,R.jsx)(`stop`,{offset:`60%`,stopColor:`#7a5230`}),(0,R.jsx)(`stop`,{offset:`100%`,stopColor:`#8a6038`})]}),(0,R.jsxs)(`linearGradient`,{id:`barkB-${u}`,x1:`0`,y1:`1`,x2:`0.3`,y2:`0`,children:[(0,R.jsx)(`stop`,{offset:`0%`,stopColor:`#6b4526`}),(0,R.jsx)(`stop`,{offset:`100%`,stopColor:`#8a6038`})]}),(0,R.jsx)(`filter`,{id:`soft-${u}`,x:`-50%`,y:`-50%`,width:`200%`,height:`200%`,children:(0,R.jsx)(`feGaussianBlur`,{stdDeviation:`2.2`})})]}),(0,R.jsx)(`ellipse`,{className:mu.groundShadow,cx:vu,cy:`184`,rx:`30`,ry:`4.5`}),(0,R.jsx)(`path`,{fill:`url(#pot-${u})`,d:`M50 150 L110 150 L101 184 L59 184 Z`}),(0,R.jsx)(`path`,{className:mu.potRim,d:`M47 149 L113 149 L109 156 L51 156 Z`}),(0,R.jsx)(`ellipse`,{fill:`url(#soil-${u})`,cx:vu,cy:yu-2,rx:`27.5`,ry:`6.8`}
50),(0,R.jsx)(`ellipse`,{className:mu.soilFleck,cx:vu-10,cy:yu-3,rx:`2`,ry:`1`}),(0,R.jsx)(`ellipse`,{className:mu.soilFleck,cx:88,cy:yu-1,rx:`1.6`,ry:`0.9`}),(0,R.jsxs)(`g`,{className:B(v,y),style:{transformOrigin:`${vu}px ${yu}px`},children:[h===`seed`&&(0,R.jsx)(`ellipse`,{className:mu.seed,cx:vu,cy:yu-5,rx:`6.5`,ry:`5`}),b&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`path`,{className:mu.foliage,d:b.stem}),b.leaves.map((e,t)=>(0,R.jsxs)(`g`,{transform:`translate(${e.x.toFixed(1)} ${e.y.toFixed(1)}) rotate(${e.angle})`,children:[(0,R.jsx)(`path`,{className:mu.leaf,d:Ou(e.len,e.len*.4)}),(0,R.jsx)(`path`,{className:mu.leafVein,d:ku(e.len)})]},t))]}),x&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`path`,{fill:`url(#bark-${u})`,d:x.trunk}),x.barks.map((e,t)=>(0,R.jsx)(`path`,{className:mu.barkLine,d:e},`bk${t}`)),x.branches.map((e,t)=>(0,R.jsx)(`path`,{fill:`url(#barkB-${u})`,d:e},`br${t}`)),x.clumps.map((e,t)=>(0,R.jsx)(`path`,{className:mu.foliage,d:e.base},`cl${t}`)),(0,R.jsx)(`path`,{className:mu.foliageLo,filter:`url(#soft-${u})`,d:x.shade}),x.clumps.map((e,t)=>(0,R.jsx)(`path`,{className:mu.clumpHi,filter:`url(#soft-${u})`,d:e.hi},`ch${t}`)),(0,R.jsx)(`path`,{className:mu.foliageHi,filter:`url(#soft-${u})`,d:x.hi})]}),p&&h!==`seed`&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`path`,{className:mu.fallenLeaf,d:Ou(11,4.4),transform:`translate(60 156) rotate(158)`}),(0,R.jsx)(`path`,{className:mu.fallenLeaf,d:Ou(9,3.8),transform:`translate(98 158) rotate(20)`})]})]}),(E.length>0||O.length>0)&&(0,R.jsxs)(`g`,{className:v,children:[O.map((e,t)=>(0,R.jsx)(`path`,{className:mu.gust,style:{"--delay":`${e.delay}s`},d:e.d},`g${t}`)),E.map((e,t)=>(0,R.jsx)(`g`,{transform:`translate(${e.x.toFixed(1)} ${e.y.toFixed(1)})`,children:(0,R.jsx)(`g`,{className:D,style:e.style,children:(0,R.jsx)(`path`,{className:mu.leaf,d:Ou(e.size,e.size*.42)})})},t))]})]}),o&&(0,R.jsx)(`p`,{className:B(mu.caption,p&&mu.captionBroken,n&&mu.captionRisk),children:g})]})}var Uu={quiz:`_quiz_1ed8r_4`,progress:`_progress_1ed8r_20`,pip:`_pip_1ed8r_27`,pipOn:`_pipOn_1ed8r_34`,question:`_question_1ed8r_36`,options:`_options_1ed8r_48`,option:`_option_1ed8r_48`,result:`_result_1ed8r_78`,resultIn:`_resultIn_1ed8r_1`,reads:`_reads_1ed8r_91`,answer:`_answer_1ed8r_100`,does:`_does_1ed8r_111`,doesItem:`_doesItem_1ed8r_120`,doesDot:`_doesDot_1ed8r_129`,resultActions:`_resultActions_1ed8r_138`,resultCta:`_resultCta_1ed8r_145`,retake:`_retake_1ed8r_160`,resultFoot:`_resultFoot_1ed8r_173`,resultFootLink:`_resultFootLink_1ed8r_179`,hint:`_hint_1ed8r_195`,check:`_check_1ed8r_204`,optionOn:`_optionOn_1ed8r_214`,stepActions:`_stepActions_1ed8r_230`,next:`_next_1ed8r_238`,stepCount:`_stepCount_1ed8r_253`,bullet:`_bullet_1ed8r_261`,bulletTheme:`_bulletTheme_1ed8r_270`,bulletPain:`_bulletPain_1ed8r_278`,bulletFix:`_bulletFix_1ed8r_286`},Wu=[{q:`What actually goes wrong with your days?`,theme:`Your day`,options:[{label:`My day is set by whoever messages me first`,fix:`Crew pings you at your hour, before the inbox does, and you lock the day first.`},{label:`I plan in my head and forget by noon`,fix:`The day is locked in writing â in Telegram and the app â so it isn't held in memory.`},{label:`I start three things and finish none`,fix:`Every locked task gets its own verdict at night: shipped, taken on your word, or missed.`},{label:`The same task rolls over for days`,fix:`Carried three days running, Crew stops accepting it silently and asks what is actually blocking it.`},{label:`I do the small tasks and dodge the big one`,fix:`At 8:30 it asks about the one you keep pushing, by name.`},{label:`Everything on my list is urgent`,fix:`Three tasks by default, ten at most â the cap is the whole mechanism.`},{label:`Big projects never start because they're too big`,fix:`A bigger effort becomes one day at a time, still tracked as one thing.`},{label:`I don't know which task actually serves my goal`,fix:`Ask it, and it proposes one specific task drawn from your goal and your business context.`}]},{q:`What happens to the record of what you did?`,theme:`Your record`,options:[{label:`I tick things off without really finishing them`,fix:`Nothing closes without proof â Crew judges it and says so when it does not hold up.`},{label:`I can't remember what I shipped last week`,fix:`Each day keeps its receipts, so the week is already written when you look back.`},{label:`Writing status updates eats my time`,fix:`The evening report writes itself from what actually resolved.`},{label:`Someone asks what moved and I improvise`,fix:`Verified, self-attested and missed stay three different things, and the badge names the source.`}
50,{label:`My tools know what I did, nothing collects it`,fix:`GitHub, Vercel, Stripe, Calendly and your calendar close tasks by themselves.`},{label:`I finish things nothing digital can prove`,fix:`A screenshot, a photo or a voice note counts â it is judged the same way as a commit.`},{label:`I inflate my own progress without meaning to`,fix:`You cannot override a verdict. You improve the proof and ask again.`}]},{q:`Where does the time actually go?`,theme:`Your hours`,options:[{label:`Meetings eat the day and I build at night`,fix:`It reads your calendar and says when the evening is already gone, before you commit to deep work.`},{label:`Admin quietly replaces the real work`,fix:`Every task is tagged build / sales / ops as you lock it, so the substitution is visible.`},{label:`My calendar is full but nothing ships`,fix:`A meeting only closes the task it actually proves â a full calendar never counts as output.`},{label:`I context-switch between two companies`,fix:`Separate workspaces: each company keeps its own tasks, chat and history.`},{label:`I take on more than the hours allow`,fix:`The daily cap holds, and after a break it offers a single task instead of a full load.`},{label:`I never protect time for the hard thing`,fix:`Crew argues with the plan when the day cannot hold it, instead of accepting it silently.`}]},{q:`What happens when you drift?`,theme:`When you slip`,options:[{label:`Nobody notices if I stop shipping`,fix:`It speaks first when something actually changes, and a blank day is one tap from real tasks â generated from your goal, or pulled straight out of your own Linear, Notion, Asana, ClickUp or Jira.`},{label:`I break a streak and abandon it completely`,fix:`One miss wilts the plant with a day to revive it; the streak is built to survive a bad day.`},{label:`I'm accountable to literally no one`,fix:`A pod is one other founder who sees your rate and your streak â never the text of your tasks.`},{label:`I go quiet for a week and rationalise it`,fix:`It chases twice, then stops for good â so the nudge still means something when it arrives.`},{label:`Without a deadline nothing happens`,fix:`One goal with a date, milestones backed by the verified work underneath them, and a straight answer on whether your rate lands in time.`},{label:`I burn out, then over-correct`,fix:`Rest days you set, and travel or crisis weeks you declare, are skipped rather than counted as misses.`},{label:`I quietly rewrite how the week went`,fix:`A closed day cannot be edited â the record is the one thing you cannot talk around.`}]}];function Gu(){let e=z(),[t,n]=(0,_.useState)(0),[r,i]=(0,_.useState)(()=>Wu.map(()=>[])),[a,o]=(0,_.useState)(!1),s=Wu[t],c=r[t]??[];function l(e){i(n=>{let r=n.map(e=>[...e]),i=r[t].indexOf(e);return i===-1?r[t].push(e):r[t].splice(i,1),r})}function u(){if(t<Wu.length-1){n(t+1);return}o(!0),$l(`landing_quiz`,{picks:Wu.reduce((e,t,n)=>(e[t.theme]=(r[n]??[]).map(e=>t.options[e].label),e),{})})}function d(){i(Wu.map(()=>[])),n(0),o(!1)}let f=Wu.map((e,t)=>{let n=(r[t]??[]).slice(0,2).map(t=>e.options[t]);return n.length===0?null:{theme:e.theme,pains:n.map(e=>e.label),fixes:n.map(e=>e.fix)}}).filter(Boolean);return a?(0,R.jsx)(`div`,{className:Uu.quiz,children:(0,R.jsx)(`div`,{className:Uu.result,children:f.length===0?(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`p`,{className:Uu.answer,children:e(`Nothing ticked â so nothing to fix yet.`)}),(0,R.jsx)(`p`,{className:Uu.resultFoot,children:e(`Run it again and tick what is actually true.`)}),(0,R.jsx)(`div`,{className:Uu.resultActions,children:(0,R.jsx)(`button`,{type:`button`,className:Uu.retake,onClick:d,children:e(`start over`)})})]}):(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`p`,{className:Uu.reads,children:e(`Here is what Crew does about it`)}),(0,R.jsx)(`ul`,{className:Uu.does,children:f.map(t=>(0,R.jsxs)(`li`,{className:Uu.bullet,children:[(0,R.jsx)(`span`,{className:Uu.bulletTheme,children:e(t.theme)}),(0,R.jsx)(`span`,{className:Uu.bulletPain,children:t.pains.map(t=>e(t)).join(` · `)}),t.fixes.map(t=>(0,R.jsxs)(`span`,{className:Uu.bulletFix,children:[(0,R.jsx)(`span`,{className:Uu.doesDot,"aria-hidden":!0}),e(t)]},t))]},t.theme))}),(0,R.jsxs)(`div`,{className:Uu.resultActions,children:[(0,R.jsx)(`a`,{href:`#waitlist`,className:Uu.resultCta,children:e(`Join the waitlist â get early access`)}),(0,R.jsx)(`button`,{type:`button`,className:Uu.retake,onClick:d,children:e(`start over`)})]})]})})}):(0,R.jsxs)(`div`,{className:Uu.quiz,children:[(0,R.jsx)(`div`,{className:Uu.progress,"aria-hidden":!0,
50children:Wu.map((e,n)=>(0,R.jsx)(`span`,{className:B(Uu.pip,n<=t&&Uu.pipOn)},n))}),(0,R.jsx)(`p`,{className:Uu.question,children:e(s.q)}),(0,R.jsx)(`p`,{className:Uu.hint,children:e(`tick everything that is true â more than one is normal`)}),(0,R.jsx)(`div`,{className:Uu.options,children:s.options.map((t,n)=>(0,R.jsxs)(`button`,{type:`button`,className:B(Uu.option,c.includes(n)&&Uu.optionOn),"aria-pressed":c.includes(n),onClick:()=>l(n),children:[(0,R.jsx)(`span`,{className:Uu.check,"aria-hidden":!0}),e(t.label)]},t.label))}),(0,R.jsxs)(`div`,{className:Uu.stepActions,children:[(0,R.jsx)(`button`,{type:`button`,className:Uu.next,onClick:u,children:t<Wu.length-1?e(`next â`):e(`show what Crew fixes â`)}),(0,R.jsx)(`span`,{className:Uu.stepCount,children:e(`{a} of {b}`).replace(`{a}`,String(t+1)).replace(`{b}`,String(Wu.length))})]})]})}var V={page:`_page_1a2lo_3`,stickyNav:`_stickyNav_1a2lo_18`,stickyNavScrolled:`_stickyNavScrolled_1a2lo_26`,navInner:`_navInner_1a2lo_34`,navLinks:`_navLinks_1a2lo_43`,navLink:`_navLink_1a2lo_43`,navRight:`_navRight_1a2lo_64`,navSignIn:`_navSignIn_1a2lo_69`,langToggle:`_langToggle_1a2lo_79`,langBtn:`_langBtn_1a2lo_87`,langBtnActive:`_langBtnActive_1a2lo_102`,stickyNavMenuOpen:`_stickyNavMenuOpen_1a2lo_104`,mobileMenuBtn:`_mobileMenuBtn_1a2lo_112`,burgerIcon:`_burgerIcon_1a2lo_125`,burgerIconOpen:`_burgerIconOpen_1a2lo_148`,mobileMenuPanel:`_mobileMenuPanel_1a2lo_165`,mobileMenuLink:`_mobileMenuLink_1a2lo_177`,hero:`_hero_1a2lo_207`,heroInner:`_heroInner_1a2lo_211`,heroLeft:`_heroLeft_1a2lo_220`,eyebrow:`_eyebrow_1a2lo_229`,fadeUp:`_fadeUp_1a2lo_1`,headline:`_headline_1a2lo_242`,headClip:`_headClip_1a2lo_262`,clipReveal:`_clipReveal_1a2lo_1`,headAccent:`_headAccent_1a2lo_274`,subline:`_subline_1a2lo_285`,emailForm:`_emailForm_1a2lo_296`,emailRow:`_emailRow_1a2lo_302`,emailInput:`_emailInput_1a2lo_306`,emailInputError:`_emailInputError_1a2lo_324`,emailInputInv:`_emailInputInv_1a2lo_325`,emailSubmit:`_emailSubmit_1a2lo_333`,emailSubmitInv:`_emailSubmitInv_1a2lo_351`,detailsForm:`_detailsForm_1a2lo_360`,detailsGrid:`_detailsGrid_1a2lo_366`,detailField:`_detailField_1a2lo_371`,fieldLabel:`_fieldLabel_1a2lo_376`,fieldLabelInv:`_fieldLabelInv_1a2lo_381`,optional:`_optional_1a2lo_382`,fieldInput:`_fieldInput_1a2lo_387`,fieldInputInv:`_fieldInputInv_1a2lo_404`,phoneRow:`_phoneRow_1a2lo_411`,countrySelect:`_countrySelect_1a2lo_416`,countrySelectInv:`_countrySelectInv_1a2lo_437`,phoneInput:`_phoneInput_1a2lo_445`,detailsActions:`_detailsActions_1a2lo_447`,backBtn:`_backBtn_1a2lo_452`,backBtnInv:`_backBtnInv_1a2lo_462`,submitBtn:`_submitBtn_1a2lo_465`,submitBtnInv:`_submitBtnInv_1a2lo_480`,formError:`_formError_1a2lo_486`,formErrorInv:`_formErrorInv_1a2lo_491`,successMsg:`_successMsg_1a2lo_495`,successMsgInv:`_successMsgInv_1a2lo_508`,successDot:`_successDot_1a2lo_513`,successSub:`_successSub_1a2lo_522`,perks:`_perks_1a2lo_528`,perk:`_perk_1a2lo_528`,perkDot:`_perkDot_1a2lo_545`,heroInvite:`_heroInvite_1a2lo_554`,heroInviteLink:`_heroInviteLink_1a2lo_560`,quote:`_quote_1a2lo_568`,quoteText:`_quoteText_1a2lo_576`,quoteTag:`_quoteTag_1a2lo_583`,heroRight:`_heroRight_1a2lo_593`,slideFromRight:`_slideFromRight_1a2lo_1`,phone:`_phone_1a2lo_411`,screen:`_screen_1a2lo_643`,statusBar:`_statusBar_1a2lo_661`,statusTime:`_statusTime_1a2lo_672`,statusIcons:`_statusIcons_1a2lo_679`,statusGlyph:`_statusGlyph_1a2lo_680`,thread:`_thread_1a2lo_681`,threadTag:`_threadTag_1a2lo_682`,phoneLocked:`_phoneLocked_1a2lo_691`,phoneClarity:`_phoneClarity_1a2lo_691`,phoneDock:`_phoneDock_1a2lo_695`,phoneInputBar:`_phoneInputBar_1a2lo_703`,phoneKb:`_phoneKb_1a2lo_710`,phoneKbRow:`_phoneKbRow_1a2lo_715`,phoneKey:`_phoneKey_1a2lo_720`,phoneKeyMod:`_phoneKeyMod_1a2lo_733`,phoneKeyAlt:`_phoneKeyAlt_1a2lo_734`,phoneKeySpace:`_phoneKeySpace_1a2lo_735`,phoneInputIcon:`_phoneInputIcon_1a2lo_736`,phoneInputField:`_phoneInputField_1a2lo_737`,receiptCard:`_receiptCard_1a2lo_749`,receiptCardLabel:`_receiptCardLabel_1a2lo_759`,receiptRow:`_receiptRow_1a2lo_769`,receiptDone:`_receiptDone_1a2lo_774`,receiptSkip:`_receiptSkip_1a2lo_782`,receiptInfo:`_receiptInfo_1a2lo_789`,receiptTask:`_receiptTask_1a2lo_794`,receiptTaskMissed:`_receiptTaskMissed_1a2lo_800`,receiptProof:`_receiptProof_1a2lo_804`,receiptProofDrift:`_receiptProofDrift_1a2lo_810`,stats:`_stats_1a2lo_816`,statsVisible:`_statsVisible_1a2lo_824`,statsInner:`_statsInner_1a2lo_826`,stat:`_stat_1a2lo_661`,statDivider:`_statDivider_1a2lo_844`,statNum:`_statNum_1a2lo_851`,statLabel:`_statLabel_1
50a2lo_862`,sectionInner:`_sectionInner_1a2lo_871`,sectionHead:`_sectionHead_1a2lo_876`,howVisible:`_howVisible_1a2lo_890`,proofVisible:`_proofVisible_1a2lo_891`,eveningVisible:`_eveningVisible_1a2lo_892`,receiptsVisible:`_receiptsVisible_1a2lo_893`,tag:`_tag_1a2lo_895`,tagLight:`_tagLight_1a2lo_901`,sectionTitle:`_sectionTitle_1a2lo_908`,sectionSub:`_sectionSub_1a2lo_916`,how:`_how_1a2lo_890`,steps:`_steps_1a2lo_936`,stepCard:`_stepCard_1a2lo_942`,stepTime:`_stepTime_1a2lo_957`,stepTitle:`_stepTitle_1a2lo_964`,stepBody:`_stepBody_1a2lo_971`,proofSection:`_proofSection_1a2lo_979`,eveningSection:`_eveningSection_1a2lo_990`,demoInner:`_demoInner_1a2lo_1000`,demoPhone:`_demoPhone_1a2lo_1009`,demoText:`_demoText_1a2lo_1014`,featureList:`_featureList_1a2lo_1020`,featureDot:`_featureDot_1a2lo_1039`,receiptsSection:`_receiptsSection_1a2lo_1050`,growSection:`_growSection_1a2lo_1062`,growVisible:`_growVisible_1a2lo_1070`,growDemo:`_growDemo_1a2lo_1072`,growCaption:`_growCaption_1a2lo_1079`,growHint:`_growHint_1a2lo_1090`,crewSection:`_crewSection_1a2lo_1111`,crewVisible:`_crewVisible_1a2lo_1119`,crewInner:`_crewInner_1a2lo_1121`,crewText:`_crewText_1a2lo_1130`,crewDemoWrap:`_crewDemoWrap_1a2lo_1136`,podYouBadge:`_podYouBadge_1a2lo_1141`,vision:`_vision_1a2lo_1156`,visionVisible:`_visionVisible_1a2lo_1164`,visionGrid:`_visionGrid_1a2lo_1166`,visionLeft:`_visionLeft_1a2lo_1172`,visionTitle:`_visionTitle_1a2lo_1177`,visionBody:`_visionBody_1a2lo_1185`,visionRight:`_visionRight_1a2lo_1192`,waitSection:`_waitSection_1a2lo_1199`,waitVisible:`_waitVisible_1a2lo_1209`,waitInner:`_waitInner_1a2lo_1211`,waitTitle:`_waitTitle_1a2lo_1223`,waitSub:`_waitSub_1a2lo_1231`,footer:`_footer_1a2lo_1245`,footerInner:`_footerInner_1a2lo_1250`,footerCopy:`_footerCopy_1a2lo_1257`,footerRight:`_footerRight_1a2lo_1263`,footerLink:`_footerLink_1a2lo_1268`,waitBadge:`_waitBadge_1a2lo_1294`,waitTrust:`_waitTrust_1a2lo_1305`,waitInvite:`_waitInvite_1a2lo_1311`,waitInviteLink:`_waitInviteLink_1a2lo_1316`,proofSplit:`_proofSplit_1a2lo_1332`,proofSteps:`_proofSteps_1a2lo_1339`,proofStep:`_proofStep_1a2lo_1339`,proofStepK:`_proofStepK_1a2lo_1356`,proofStepV:`_proofStepV_1a2lo_1363`,proofNote:`_proofNote_1a2lo_1369`,proofVisual:`_proofVisual_1a2lo_1379`,proofFacts:`_proofFacts_1a2lo_1384`,proofFact:`_proofFact_1a2lo_1384`,proofFactTitle:`_proofFactTitle_1a2lo_1400`,proofFactBody:`_proofFactBody_1a2lo_1407`,pop:`_pop_1a2lo_1418`,popHead:`_popHead_1a2lo_1430`,popMark:`_popMark_1a2lo_1435`,popCaret:`_popCaret_1a2lo_1443`,popCount:`_popCount_1a2lo_1452`,popHint:`_popHint_1a2lo_1457`,popTasks:`_popTasks_1a2lo_1464`,popTask:`_popTask_1a2lo_1464`,popTaskFirst:`_popTaskFirst_1a2lo_1473`,popTaskSpent:`_popTaskSpent_1a2lo_1475`,popTaskBody:`_popTaskBody_1a2lo_1477`,popTaskText:`_popTaskText_1a2lo_1484`,popStruck:`_popStruck_1a2lo_1489`,popTaskMeta:`_popTaskMeta_1a2lo_1493`,popMark2:`_popMark2_1a2lo_1499`,popMarkPrimary:`_popMarkPrimary_1a2lo_1512`,popMarkSpent:`_popMarkSpent_1a2lo_1517`,popResult:`_popResult_1a2lo_1520`,popFlash:`_popFlash_1a2lo_1529`,popCapturing:`_popCapturing_1a2lo_1537`,popBtn:`_popBtn_1a2lo_1542`,popMarkChecking:`_popMarkChecking_1a2lo_1550`,checkingPulse:`_checkingPulse_1a2lo_1`,popReplay:`_popReplay_1a2lo_1556`,popFoot:`_popFoot_1a2lo_1567`,popQuiet:`_popQuiet_1a2lo_1575`,popLinks:`_popLinks_1a2lo_1580`,recWrap:`_recWrap_1a2lo_1590`,recList:`_recList_1a2lo_1594`,recRow:`_recRow_1a2lo_1602`,recBody:`_recBody_1a2lo_1610`,recTop:`_recTop_1a2lo_1617`,recNum:`_recNum_1a2lo_1622`,recTask:`_recTask_1a2lo_1627`,recTaskDone:`_recTaskDone_1a2lo_1632`,recMeta:`_recMeta_1a2lo_1636`,recNote:`_recNote_1a2lo_1642`,recCaption:`_recCaption_1a2lo_1647`,cofSection:`_cofSection_1a2lo_1659`,cofVisible:`_cofVisible_1a2lo_1667`,cofInner:`_cofInner_1a2lo_1669`,cofText:`_cofText_1a2lo_1677`,cofVisual:`_cofVisual_1a2lo_1682`,ctxPanel:`_ctxPanel_1a2lo_1688`,ctxHead:`_ctxHead_1a2lo_1698`,ctxRows:`_ctxRows_1a2lo_1706`,ctxRow:`_ctxRow_1a2lo_1706`,ctxKey:`_ctxKey_1a2lo_1718`,ctxVal:`_ctxVal_1a2lo_1724`,ctxFoot:`_ctxFoot_1a2lo_1731`,podBoard:`_podBoard_1a2lo_1742`,podCard:`_podCard_1a2lo_1749`,podCardMe:`_podCardMe_1a2lo_1758`,podCardHead:`_podCardHead_1a2lo_1762`,podIdent:`_podIdent_1a2lo_1769`,podName:`_podName_1a2lo_1774`,podProduct:`_podProduct_1a2lo_1782`,podChips:`_podChips_1a2lo_1786`,podChip:`_podChip_1a2lo_1786`,podBlock:`_podBlock_1a2lo_1814`,podBlockLabel:`_podBlockLabel_1a2lo_1821`,podItem:`_podItem_1a2lo_1829`,podDot:`_podDot_1a2lo_1834`,podDotSelf:`_podDotSelf_1a2lo_1843`,podItemText:`_podItemText_1a2lo_1844`,podItemBtn:`_podItemBtn_1a2lo_1850`,podDotOpen:`_podDotOpen_1a2lo_1861`,podItemOpen:`_podItemOpen_1a2lo_1865`,podItemProof:`_podItemProof_1a2lo_1867`,visionAttrib:`_visionAttrib_1a2lo_1877`,visionInitials:`_visionInitials_1a2lo_1882`,visionWho:`_visionWho_1a2lo_1898`,visionName:`_visionName_1a2lo_1903`,visionRole:`_visionRole_1a2lo_1908`,eveningPhone:`_eveningPhone_1a2lo_1954`,heroAura:`_heroAura_1a2lo_2009`,auraA:`_auraA_1a2lo_2027`,auraDriftA:`_auraDriftA_1a2lo_1`,auraB:`_auraB_1a2lo_2035`,auraDriftB:`_auraDriftB_1a2lo_1`,tiltWrap:`_tiltWrap_1a2lo_2059`,tiltInner:`_tiltInner_1a2lo_2063`,phoneFloat:`_phoneFloat_1a2lo_1`,tiltGlare:`_tiltGlare_1a2lo_2085`,bubbleIn:`_bubbleIn_1a2lo_1`,digitWipe:`_digitWipe_1a2lo_1`,glowHost:`_glowHost_1a2lo_2144`,videoSection:`_videoSection_1a2lo_2178`,videoVisible:`_videoVisible_1a2lo_2186`,sectionHeadCentred:`_sectionHeadCentred_1a2lo_2192`,videoFrame:`_videoFrame_1a2lo_2203`,videoChrome:`_videoChrome_1a2lo_2221`,videoChromeBar:`_videoChromeBar_1a2lo_2235`,videoStage:`_videoStage_1
50a2lo_2250`,videoEl:`_videoEl_1a2lo_2258`,videoUnmute:`_videoUnmute_1a2lo_2269`,videoStandby:`_videoStandby_1a2lo_2301`,videoPlayDot:`_videoPlayDot_1a2lo_2311`,videoLabel:`_videoLabel_1a2lo_2323`,askSection:`_askSection_1a2lo_2335`,askVisible:`_askVisible_1a2lo_2343`,askInner:`_askInner_1a2lo_2345`,askCopy:`_askCopy_1a2lo_2353`,askPhone:`_askPhone_1a2lo_2362`,askList:`_askList_1a2lo_2367`,askItem:`_askItem_1a2lo_2375`,askDot:`_askDot_1a2lo_2383`,calCard:`_calCard_1a2lo_2393`,calCardLabel:`_calCardLabel_1a2lo_2403`,calRow:`_calRow_1a2lo_2410`,calTime:`_calTime_1a2lo_2416`,calEvent:`_calEvent_1a2lo_2423`,problem:`_problem_1a2lo_2468`,problemTitle:`_problemTitle_1a2lo_2472`,problemList:`_problemList_1a2lo_2483`,problemItem:`_problemItem_1a2lo_2492`,features:`_features_1a2lo_2505`,feat:`_feat_1a2lo_1020`,featFlip:`_featFlip_1a2lo_2528`,featCopy:`_featCopy_1a2lo_2528`,featVisual:`_featVisual_1a2lo_2529`,featTag:`_featTag_1a2lo_2538`,featTitle:`_featTitle_1a2lo_2546`,featAside:`_featAside_1a2lo_2563`,connectors:`_connectors_1a2lo_2571`,connectorMarquee:`_connectorMarquee_1a2lo_2593`,connectorTrack:`_connectorTrack_1a2lo_2614`,connectorScroll:`_connectorScroll_1a2lo_1`,connectorRow:`_connectorRow_1a2lo_2651`,connectorChip:`_connectorChip_1a2lo_2661`,connectorLogo:`_connectorLogo_1a2lo_2676`,srOnly:`_srOnly_1a2lo_2696`,connectorNote:`_connectorNote_1a2lo_2707`,benefits:`_benefits_1a2lo_2715`,benefitGrid:`_benefitGrid_1a2lo_2719`,benefit:`_benefit_1a2lo_2715`,benefitK:`_benefitK_1a2lo_2738`,benefitV:`_benefitV_1a2lo_2746`,statsInline:`_statsInline_1a2lo_2751`,quizSection:`_quizSection_1a2lo_2792`,quizHead:`_quizHead_1a2lo_2799`,demoCheck:`_demoCheck_1a2lo_2827`,demoCheckInv:`_demoCheckInv_1a2lo_2837`,demoBox:`_demoBox_1a2lo_2839`,featSub:`_featSub_1a2lo_2869`,heroDemo:`_heroDemo_1a2lo_2881`,heroDemoLink:`_heroDemoLink_1a2lo_2887`,mcp:`_mcp_1a2lo_2913`,mcpCta:`_mcpCta_1a2lo_2920`,agentGrid:`_agentGrid_1a2lo_2935`,agentTile:`_agentTile_1a2lo_2942`,agentLogo:`_agentLogo_1a2lo_2953`,agentName:`_agentName_1a2lo_2965`},Ku=/^[^@\s]+@[^@\s]+\.[^@\s]+$/,qu=()=>{};function Ju(e){let t=e.currentTarget,n=t.getBoundingClientRect();t.style.setProperty(`--mx`,`${e.clientX-n.left}px`),t.style.setProperty(`--my`,`${e.clientY-n.top}px`)}function Yu({children:e,max:t=9}){let n=(0,_.useRef)(null),r=pu();function i(e){let i=n.current;if(!i||r)return;let a=i.getBoundingClientRect(),o=(e.clientX-a.left)/a.width-.5,s=(e.clientY-a.top)/a.height-.5;i.style.setProperty(`--rx`,`${(-s*t).toFixed(2)}deg`),i.style.setProperty(`--ry`,`${(o*t).toFixed(2)}deg`),i.style.setProperty(`--gx`,`${((o+.5)*100).toFixed(1)}%`),i.style.setProperty(`--gy`,`${((s+.5)*100).toFixed(1)}%`),i.style.setProperty(`--glare`,`1`)}function a(){let e=n.current;e&&(e.style.setProperty(`--rx`,`0deg`),e.style.setProperty(`--ry`,`0deg`),e.style.setProperty(`--glare`,`0`))}return r?(0,R.jsx)(`div`,{className:V.tiltWrap,children:e}):(0,R.jsx)(`div`,{ref:n,className:V.tiltWrap,onMouseMove:i,onMouseLeave:a,children:(0,R.jsxs)(`div`,{className:V.tiltInner,children:[e,(0,R.jsx)(`span`,{className:V.tiltGlare,"aria-hidden":!0})]})})}function Xu(){let[e,t]=(0,_.useState)(!1),[n,r]=(0,_.useState)(!1),{lang:i,setLang:a}=ml(),o=z();(0,_.useEffect)(()=>{let e=()=>t(window.scrollY>80);return window.addEventListener(`scroll`,e,{passive:!0}),()=>window.removeEventListener(`scroll`,e)},[]),(0,_.useEffect)(()=>{if(n)return document.body.style.overflow=`hidden`,()=>{document.body.style.overflow=``}},[n]);function s(e){r(!1),document.getElementById(e)?.scrollIntoView({behavior:`smooth`})}let c=(0,R.jsxs)(`div`,{className:V.langToggle,children:[(0,R.jsx)(`button`,{className:B(V.langBtn,i===`en`&&V.langBtnActive),onClick:()=>a(`en`),children:`EN`}),(0,R.jsx)(`span`,{style:{opacity:.25,fontSize:`10px`},children:`|`}),(0,R.jsx)(`button`,{className:B(V.langBtn,i===`fr`&&V.langBtnActive),onClick:()=>a(`fr`),children:`FR`})]});
50return(0,R.jsxs)(`nav`,{className:B(V.stickyNav,e&&V.stickyNavScrolled,n&&V.stickyNavMenuOpen),children:[(0,R.jsxs)(`div`,{className:V.navInner,children:[(0,R.jsx)(El,{size:20}),(0,R.jsxs)(`div`,{className:V.navLinks,children:[(0,R.jsx)(`button`,{className:V.navLink,onClick:()=>s(`problem`),children:o(`the problem`)}),(0,R.jsx)(`button`,{className:V.navLink,onClick:()=>s(`how`),children:o(`how it works`)}),(0,R.jsx)(`button`,{className:V.navLink,onClick:()=>s(`fit`),children:o(`what it fixes`)}),(0,R.jsx)(`button`,{className:V.navLink,onClick:()=>s(`waitlist`),children:o(`join waitlist`)}),(0,R.jsx)(Rn,{to:`/auth`,className:V.navSignIn,onClick:e=>lu(`nav_sign_in`,e.clientX,e.clientY),children:o(`sign in`)}),c]}),(0,R.jsx)(`button`,{type:`button`,className:V.mobileMenuBtn,onClick:()=>r(e=>!e),"aria-label":n?`Close menu`:`Open menu`,"aria-expanded":n,children:(0,R.jsx)(`span`,{className:B(V.burgerIcon,n&&V.burgerIconOpen),"aria-hidden":!0})})]}),n&&(0,R.jsxs)(`div`,{className:V.mobileMenuPanel,children:[(0,R.jsx)(`button`,{className:V.mobileMenuLink,onClick:()=>s(`problem`),children:o(`the problem`)}),(0,R.jsx)(`button`,{className:V.mobileMenuLink,onClick:()=>s(`how`),children:o(`how it works`)}),(0,R.jsx)(`button`,{className:V.mobileMenuLink,onClick:()=>s(`fit`),children:o(`what it fixes`)}),(0,R.jsx)(`button`,{className:V.mobileMenuLink,onClick:()=>s(`waitlist`),children:o(`join waitlist`)}),(0,R.jsx)(Rn,{to:`/auth`,className:V.mobileMenuLink,onClick:e=>{lu(`nav_sign_in`,e.clientX,e.clientY),r(!1)},children:o(`sign in`)}),c]})]})}var Zu=[`Founder`,`Co-founder`,`CEO`,`CTO`,`Other`],Qu=[`YouTube`,`LinkedIn`,`Twitter / X`,`Friend or colleague`,`Google`,`Product Hunt`,`Other`],$u=[{flag:`ðºð¸`,iso:`US`,dial:`+1`},{flag:`ð¬ð§`,iso:`GB`,dial:`+44`},{flag:`ð«ð·`,iso:`FR`,dial:`+33`},{flag:`ð¨ð¦`,iso:`CA`,dial:`+1`},{flag:`ð¦ðº`,iso:`AU`,dial:`+61`},{flag:`ð©ðª`,iso:`DE`,dial:`+49`},{flag:`ð³ð±`,iso:`NL`,dial:`+31`},{flag:`ð§ðª`,iso:`BE`,dial:`+32`},{flag:`ð¨ð`,iso:`CH`,dial:`+41`},{flag:`ð®ð¹`,iso:`IT`,dial:`+39`},{flag:`ðªð¸`,iso:`ES`,dial:`+34`},{flag:`ðµð¹`,iso:`PT`,dial:`+351`},{flag:`ð¸ðª`,iso:`SE`,dial:`+46`},{flag:`ð©ð°`,iso:`DK`,dial:`+45`},{flag:`ð³ð´`,iso:`NO`,dial:`+47`},{flag:`ð«ð®`,iso:`FI`,dial:`+358`},{flag:`ð®ðª`,iso:`IE`,dial:`+353`},{flag:`ð¦ð¹`,iso:`AT`,dial:`+43`},{flag:`ðµð±`,iso:`PL`,dial:`+48`},{flag:`ð±ðº`,iso:`LU`,dial:`+352`},{flag:`ð¨ð¿`,iso:`CZ`,dial:`+420`},{flag:`ððº`,iso:`HU`,dial:`+36`},{flag:`ð·ð´`,iso:`RO`,dial:`+40`},{flag:`ð¬ð·`,iso:`GR`,dial:`+30`},{flag:`ð¦ðª`,iso:`AE`,dial:`+971`},{flag:`ð¸ð¦`,iso:`SA`,dial:`+966`},{flag:`ð®ð±`,iso:`IL`,dial:`+972`},{flag:`ð¹ð·`,iso:`TR`,dial:`+90`},{flag:`ð®ð³`,iso:`IN`,dial:`+91`},{flag:`ð¸ð¬`,iso:`SG`,dial:`+65`},{flag:`ð¯ðµ`,iso:`JP`,dial:`+81`},{flag:`ð°ð·`,iso:`KR`,dial:`+82`},{flag:`ð¨ð³`,iso:`CN`,dial:`+86`},{flag:`ðð°`,iso:`HK`,dial:`+852`},{flag:`ð³ð¿`,iso:`NZ`,dial:`+64`},{flag:`ð§ð·`,iso:`BR`,dial:`+55`},{flag:`ð²ð½`,iso:`MX`,dial:`+52`},{flag:`ð¦ð·`,iso:`AR`,dial:`+54`},{flag:`ð¨ð±`,iso:`CL`,dial:`+56`},{flag:`ð¨ð´`,iso:`CO`,dial:`+57`},{flag:`ð¿ð¦`,iso:`ZA`,dial:`+27`},{flag:`ð³ð¬`,iso:`NG`,dial:`+234`},{flag:`ð°ðª`,iso:`KE`,dial:`+254`},{flag:`ðªð¬`,iso:`EG`,dial:`+20`},{flag:`ð²ð¦`,iso:`MA`,dial:`+212`},{flag:`ð·ðº`,iso:`RU`,dial:`+7`},{flag:`ðºð¦`,iso:`UA`,dial:`+380`},{flag:`ðµð`,iso:`PH`,dial:`+63`},{flag:`ð®ð©`,iso:`ID`,dial:`+62`},{flag:`ð¹ð`,iso:`TH`,dial:`+66`},{flag:`ð»ð³`,iso:`VN`,dial:`+84`},{flag:`ðµð°`,iso:`PK`,dial:`+92`}];function ed({inverted:e=!1}){let t=z(),{lang:n}=ml(),[r,i]=(0,_.useState)(`email`),[a,o]=(0,_.useState)(``),[s,c]=(0,_.useState)(``),[l,u]=(0,_.useState)(``),[d,f]=(0,_.useState)(``),[p,m]=(0,_.useState)(``),[h,g]=(0,_.useState)(``),[v,y]=(0,_.useState)(``),[b,x]=(0,_.useState)(`+1`),[S,C]=(0,_.useState)(``),[w,T]=(0,_.useState)(!1),E=l===`Other`?d.trim():l,D=p===`Other`?h.trim():p;function O(e){if(e.preventDefault(),!Ku.test(a.trim())){C(t(`that email looks off`));return}C(``),i(`details`)}async function k(e){if(e.preventDefault(),!s.trim()){C(t(`add your company name`));return}if(!l){C(t(`select your role`));return}if(l===`Other`&&!d.trim()){C(t(`please specify your role`));return}if(p===`Other`&&!h.trim()){C(t(`please specify how you heard about Crew`));return}C(``),T(!0);let n=v.trim()?`${b} ${v.trim()}`:void 0,r=await Xl({email:a.trim(),company:s.trim(),role:E,referral:D||void 0,phone:n});T(!1),r.ok?i(`success`):C(t(`something went wrong. try again`))}return r===`success`?(0,R.jsxs)(`div`,{className:B(V.successMsg,e&&V.successMsgInv),children:[(0,R.jsx)(`span`,{className:V.successDot}),(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`strong`,{children:n===`fr`?`vous êtes sur la liste.`:`you're on the list.`}),(0,R.jsx)(`br`,{}),(0,R.jsx)(`span`,{className:V.successSub,children:n===`fr`?`nous vous tiendrons informé à ${a} â vous pourriez obtenir un accès anticipé.`:`we'll keep you updated at ${a} â you may get early access.`})]})]}):r===`details`?(0,R.jsxs)(`form`,{className:V.detailsForm,onSubmit:k,noValidate:!0,children:[(0,R.jsxs)(`div`,{className:V.detailsGrid,children:[(0,R.jsxs)(`div`,{className:V.detailField,children:[(0,R.jsx)(`label`,{className:B(V.fieldLabel,e&&V.fieldLabelInv),children:t(`Company name`)}),(0,R.jsx)(`input`,{className:B(V.fieldInput,e&&V.fieldInputInv),type:`text`,placeholder:t(`e.g. Replyflow, Inkforge`),value:s,onChange:e=>{c(e.target.value),C(``)},autoFocus:!0})]}),(0,R.jsxs)(`div`,{className:V.detailField,children:[(0,R.jsx)(`label`,{className:B(V.fieldLabel,e&&V.fieldLabelInv),children:t(`Your role`)}),(0,R.jsxs)(`select`,{className:B(V.fieldInput,e&&V.fieldInputInv),value:l,onCh
50ange:e=>{u(e.target.value),f(``),C(``)},children:[(0,R.jsx)(`option`,{value:``,children:t(`Select roleâ¦`)}),Zu.map(e=>(0,R.jsx)(`option`,{value:e,children:e},e))]}),l===`Other`&&(0,R.jsx)(`input`,{className:B(V.fieldInput,e&&V.fieldInputInv),type:`text`,placeholder:t(`e.g. Head of Product, Investorâ¦`),value:d,onChange:e=>{f(e.target.value),C(``)},autoFocus:!0})]}),(0,R.jsxs)(`div`,{className:V.detailField,children:[(0,R.jsx)(`label`,{className:B(V.fieldLabel,e&&V.fieldLabelInv),children:t(`How did you hear about Crew?`)}),(0,R.jsxs)(`select`,{className:B(V.fieldInput,e&&V.fieldInputInv),value:p,onChange:e=>{m(e.target.value),g(``),C(``)},children:[(0,R.jsx)(`option`,{value:``,children:t(`Selectâ¦`)}),Qu.map(e=>(0,R.jsx)(`option`,{value:e,children:e},e))]}),p===`Other`&&(0,R.jsx)(`input`,{className:B(V.fieldInput,e&&V.fieldInputInv),type:`text`,placeholder:t(`Tell us whereâ¦`),value:h,onChange:e=>{g(e.target.value),C(``)}})]}),(0,R.jsxs)(`div`,{className:V.detailField,children:[(0,R.jsxs)(`label`,{className:B(V.fieldLabel,e&&V.fieldLabelInv),children:[t(`Phone number`),` `,(0,R.jsxs)(`span`,{className:V.optional,children:[`(`,t(`optional`),`)`]})]}),(0,R.jsxs)(`div`,{className:V.phoneRow,children:[(0,R.jsx)(`select`,{className:B(V.countrySelect,e&&V.countrySelectInv),value:b+`_`+$u.findIndex(e=>e.dial===b),onChange:e=>{x($u[parseInt(e.target.value.split(`_`)[1],10)].dial)},"aria-label":t(`country code`),children:$u.map((e,t)=>(0,R.jsxs)(`option`,{value:`${e.dial}_${t}`,children:[e.flag,` `,e.iso,` `,e.dial]},t))}),(0,R.jsx)(`input`,{className:B(V.fieldInput,V.phoneInput,e&&V.fieldInputInv),type:`tel`,inputMode:`tel`,placeholder:`415 555 0100`,value:v,onChange:e=>y(e.target.value)})]})]})]}),S&&(0,R.jsx)(`p`,{className:B(V.formError,e&&V.formErrorInv),role:`alert`,children:S}),(0,R.jsxs)(`div`,{className:V.detailsActions,children:[(0,R.jsx)(`button`,{type:`button`,className:B(V.backBtn,e&&V.backBtnInv),onClick:()=>{i(`email`),C(``)},children:t(`â back`)}),(0,R.jsx)(`button`,{type:`submit`,className:B(V.submitBtn,e&&V.submitBtnInv),disabled:w,children:t(w?`savingâ¦`:`Complete signup â`)})]})]}):(0,R.jsxs)(`form`,{className:V.emailForm,onSubmit:O,noValidate:!0,children:[(0,R.jsxs)(`div`,{className:V.emailRow,children:[(0,R.jsx)(`input`,{className:B(V.emailInput,e&&V.emailInputInv,S&&V.emailInputError),type:`email`,inputMode:`email`,autoComplete:`email`,placeholder:t(`[email protected]`),"aria-label":t(`email address`),value:a,onChange:e=>{o(e.target.value),C(``)}}),(0,R.jsx)(`button`,{type:`submit`,className:B(V.emailSubmit,e&&V.emailSubmitInv),children:t(`Join the waitlist`)})]}),S&&(0,R.jsx)(`p`,{className:B(V.formError,e&&V.formErrorInv),role:`alert`,children:S})]})}function td({time:e=`7:30`}){return(0,R.jsxs)(`div`,{className:V.statusBar,children:[(0,R.jsx)(`span`,{className:V.statusTime,children:e}),(0,R.jsxs)(`span`,{className:V.statusIcons,"aria-hidden":!0,children:[(0,R.jsxs)(`svg`,{viewBox:`0 0 18 12`,width:`17`,height:`11`,className:V.statusGlyph,children:[(0,R.jsx)(`rect`,{x:`0`,y:`8`,width:`3`,height:`4`,rx:`0.8`}),(0,R.jsx)(`rect`,{x:`4.5`,y:`5.5`,width:`3`,height:`6.5`,rx:`0.8`}),(0,R.jsx)(`rect`,{x:`9`,y:`3`,width:`3`,height:`9`,rx:`0.8`}),(0,R.jsx)(`rect`,{x:`13.5`,y:`0.5`,width:`3`,height:`11.5`,rx:`0.8`})]}),(0,R.jsxs)(`svg`,{viewBox:`0 0 16 12`,width:`15`,height:`11`,className:V.statusGlyph,children:[(0,R.jsx)(`path`,{d:`M8 10.6l1.6-2a2 2 0 0 0-3.2 0l1.6 2z`}),(0,R.jsx)(`path`,{d:`M3.9 5.6a6.2 6.2 0 0 1 8.2 0`,fill:`none`,strokeWidth:`1.5`,stroke:`currentColor`,strokeLinecap:`round`}),(0,R.jsx)(`path`,{d:`M1.6 3.1a9.6 9.6 0 0 1 12.8 0`,fill:`none`,strokeWidth:`1.5`,stroke:`currentColor`,strokeLinecap:`round`})]}),(0,R.jsxs)(`svg`,{viewBox:`0 0 27 12`,width:`25`,height:`11`,className:V.statusGlyph,children:[(0,R.jsx)(`rect`,{x:`0.6`,y:`0.6`,width:`22`,height:`10.8`,rx:`3`,fill:`none`,stroke:`currentColor`,strokeWidth:`1.2`,opacity:`0.45`}),(0,R.jsx)(`rect`,{x:`2.2`,y:`2.2`,width:`16`,height:`7.6`,rx:`1.8`}),(0,R.jsx)(`path`,{d:`M24.4 4.2v3.6a2 2 0 0 0 0-3.6z`,opacity:`0.45`})]})]})]})}var nd=`https://tidycal.com/zackguerrand`,rd=[`qwertyuiop`,`asdfghjkl`,`zxcvbnm`];function id({kb:e=!0}){let t=z();
50return(0,R.jsxs)(`div`,{className:V.phoneDock,"aria-hidden":!0,children:[(0,R.jsxs)(`div`,{className:V.phoneInputBar,children:[(0,R.jsx)(`svg`,{viewBox:`0 0 24 24`,width:`19`,height:`19`,className:V.phoneInputIcon,children:(0,R.jsx)(`path`,{d:`M21 12.5l-8.5 8.5a6 6 0 01-8.5-8.5L12.5 4a4 4 0 015.7 5.7l-8.5 8.5a2 2 0 01-2.8-2.8l7.8-7.8`,fill:`none`,stroke:`currentColor`,strokeWidth:`1.6`,strokeLinecap:`round`})}),(0,R.jsx)(`span`,{className:V.phoneInputField,children:t(`Message`)}),(0,R.jsxs)(`svg`,{viewBox:`0 0 24 24`,width:`19`,height:`19`,className:V.phoneInputIcon,children:[(0,R.jsx)(`rect`,{x:`9`,y:`3`,width:`6`,height:`12`,rx:`3`,fill:`none`,stroke:`currentColor`,strokeWidth:`1.6`}),(0,R.jsx)(`path`,{d:`M5.5 11.5a6.5 6.5 0 0013 0M12 18v3`,fill:`none`,stroke:`currentColor`,strokeWidth:`1.6`,strokeLinecap:`round`})]})]}),e&&(0,R.jsxs)(`div`,{className:V.phoneKb,children:[rd.map((e,t)=>(0,R.jsxs)(`div`,{className:V.phoneKbRow,children:[t===2&&(0,R.jsx)(`span`,{className:B(V.phoneKey,V.phoneKeyMod),children:`â§`}),[...e].map(e=>(0,R.jsx)(`span`,{className:V.phoneKey,children:e},e)),t===2&&(0,R.jsx)(`span`,{className:B(V.phoneKey,V.phoneKeyMod),children:`â«`})]},e)),(0,R.jsxs)(`div`,{className:V.phoneKbRow,children:[(0,R.jsx)(`span`,{className:B(V.phoneKey,V.phoneKeyAlt),children:`123`}),(0,R.jsx)(`span`,{className:B(V.phoneKey,V.phoneKeySpace),children:t(`space`)}),(0,R.jsx)(`span`,{className:B(V.phoneKey,V.phoneKeyAlt),children:t(`return`)})]})]})]})}function ad(){let e=z(),{lang:t}=ml(),n=t===`fr`?[`livrer la landing page`,`envoyer email aux 2 prospects`,`corriger le bug auth`]:[`ship the landing page`,`email the 2 leads`,`fix the auth bug`];return(0,R.jsx)(`div`,{className:V.phone,children:(0,R.jsxs)(`div`,{className:V.screen,children:[(0,R.jsx)(td,{time:`7:30`}),(0,R.jsxs)(`div`,{className:V.thread,children:[(0,R.jsx)(`span`,{className:V.threadTag,children:e(`Morning · 7:30`)}),(0,R.jsx)(Al,{from:`crew`,children:e(`morning, Zack. lock today's 3 â send however many you've actually got (up to 10). reply SKIP to skip. 51 521. [task 1] 532. [task 2] 543. [task 3]`)}),(0,R.jsx)(Al,{from:`user`,children:e(`ship the landing page, email the 2 leads, fix the auth bug`)}),(0,R.jsx)(Ml,{className:V.phoneLocked,priorities:n})]}),(0,R.jsx)(id,{})]})})}function od(){let e=z();return(0,R.jsx)(`div`,{className:V.phone,children:(0,R.jsxs)(`div`,{className:V.screen,children:[(0,R.jsx)(td,{time:`20:30`}),(0,R.jsxs)(`div`,{className:V.thread,children:[(0,R.jsx)(`span`,{className:V.threadTag,children:e(`Evening · 8:30`)}),(0,R.jsx)(Al,{from:`crew`,children:e(`End of day, Zack. 55 56Your 3: 571. ship the landing page 582. email the 2 leads 593. fix the auth bug 60 61What shipped? 62⢠DONE â all of them â 63⢠1,2 â numbers you completed 64⢠NONE â nothing today`)}),(0,R.jsx)(Al,{from:`user`,children:e(`1,2`)}),(0,R.jsx)(Al,{from:`crew`,children:e(`nice â before I lock these in, what's the proof for "ship the landing page"? (2 to confirm)`)}),(0,R.jsxs)(`div`,{className:V.receiptCard,children:[(0,R.jsx)(`span`,{className:V.receiptCardLabel,children:e(`TODAY'S RECEIPTS`)}),(0,R.jsxs)(`div`,{className:V.receiptRow,children:[(0,R.jsx)(`span`,{className:V.receiptDone,children:`â`}),(0,R.jsxs)(`div`,{className:V.receiptInfo,children:[(0,R.jsx)(`span`,{className:V.receiptTask,children:e(`ship the landing page`)}),(0,R.jsx)(`span`,{className:V.receiptProof,children:e(`3 commits · merged 4:12pm`)})]})]}),(0,R.jsxs)(`div`,{className:V.receiptRow,children:[(0,R.jsx)(`span`,{className:V.receiptDone,children:`â`}),(0,R.jsxs)(`div`,{className:V.receiptInfo,children:[(0,R.jsx)(`span`,{className:V.receiptTask,children:e(`email the 2 leads`)}),(0,R.jsx)(`span`,{className:V.receiptProof,children:e(`47min call · calendar · 3pm`)})]})]}),(0,R.jsxs)(`div`,{className:V.receiptRow,children:[(0,R.jsx)(`span`,{className:V.receiptSkip,children:`â`}),(0,R.jsxs)(`div`,{className:V.receiptInfo,children:[(0,R.jsx)(`span`,{className:B(V.receiptTask,V.receiptTaskMissed),children:e(`fix the auth bug`)}),(0,R.jsx)(`span`,{className:B(V.receiptProof,V.receiptProofDrift),children:e(`0 commits · day 4 running`)})]})]})]})]}),(0,R.jsx)(id,{kb:!1})]})})}function sd(){let e=z();return(0,R.jsx)(`div`,{className:V.phone,children:(0,R.jsxs)(`div`,{className:V.screen,children:[(0,R.jsx)(td,{time:`18:04`}),(0,R.jsxs)(`div`,{className:V.thread,children:[(0,R.jsx)(`span`,{className:V.threadTag,children:e(`You asked`)}),(0,R.jsx)(Al,{from:`user`,children:e(`should I push the launch to next week?`)}),(0,R.jsx)(Al,{from:`crew`,children:e(`your calendar has the investor call thursday 6pm. launch before it and you walk in with something live. push it and
64you walk in pitching a promise. ship monday.`)}),(0,R.jsxs)(`div`,{className:V.calCard,children:[(0,R.jsx)(`span`,{className:V.calCardLabel,children:e(`FROM YOUR CALENDAR`)}),(0,R.jsxs)(`div`,{className:V.calRow,children:[(0,R.jsx)(`span`,{className:V.calTime,children:e(`19:30`)}),(0,R.jsx)(`span`,{className:V.calEvent,children:e(`dinner · Stripe partnerships`)})]}),(0,R.jsxs)(`div`,{className:V.calRow,children:[(0,R.jsx)(`span`,{className:V.calTime,children:e(`Thu 18:00`)}),(0,R.jsx)(`span`,{className:V.calEvent,children:e(`investor call · Series A`)})]})]}),(0,R.jsx)(Al,{from:`crew`,children:e(`also, you have dinner at 7:30 tonight. don't lock a deep build task for this evening. you won't touch it, and it'll sit there as a miss tomorrow.`)})]}),(0,R.jsx)(id,{})]})})}function cd({active:e}){let t=z(),[n,r]=(0,_.useState)(!1),[i,a]=(0,_.useState)(!1),o=(0,_.useRef)(null),s=e||n;(0,_.useEffect)(()=>{let e=o.current;!e||!s||(e.muted=!1,e.play().catch(()=>{e.muted=!0,a(!0),e.play().catch(()=>{})}))},[s]),(0,_.useEffect)(()=>{let e=o.current;if(!e||!s)return;let t=()=>{e.paused||e.pause()},n=()=>{e.play().catch(()=>{})},r=()=>{let t=e.getBoundingClientRect(),n=window.innerHeight||document.documentElement.clientHeight,r=Math.min(t.bottom,n)-Math.max(t.top,0);return t.height>0&&r/t.height>=.5},i=()=>{r()?n():t()},a=new IntersectionObserver(([e])=>{e.isIntersecting?n():t()},{threshold:.5});a.observe(e),window.addEventListener(`scroll`,i,{passive:!0}),window.addEventListener(`resize`,i,{passive:!0});let c=()=>{document.hidden&&t()};return document.addEventListener(`visibilitychange`,c),()=>{a.disconnect(),window.removeEventListener(`scroll`,i),window.removeEventListener(`resize`,i),document.removeEventListener(`visibilitychange`,c)}},[s]);function c(){let e=o.current;e&&(e.muted=!1,a(!1))}return(0,_.useEffect)(()=>{if(!i)return;let e=async()=>{let e=o.current;if(e){e.muted=!1;try{await e.play(),a(!1)}catch{e.muted=!0}}};return window.addEventListener(`pointerup`,e),()=>window.removeEventListener(`pointerup`,e)},[i]),(0,R.jsxs)(`div`,{className:V.videoFrame,children:[(0,R.jsxs)(`div`,{className:V.videoChrome,"aria-hidden":!0,children:[(0,R.jsx)(`span`,{}),(0,R.jsx)(`span`,{}),(0,R.jsx)(`span`,{}),(0,R.jsx)(`span`,{className:V.videoChromeBar,children:t(`meetcrew.app`)})]}),(0,R.jsx)(`div`,{className:V.videoStage,children:s?(0,R.jsxs)(R.Fragment,{children:[(0,R.jsxs)(`video`,{ref:o,className:V.videoEl,autoPlay:!0,muted:!0,controls:!0,playsInline:!0,preload:`auto`,poster:`/crew-demo-poster.jpg`,children:[(0,R.jsx)(`source`,{src:`/crew-demo-hevc.mp4`,type:`video/mp4; codecs="hvc1"`}),(0,R.jsx)(`source`,{src:`/crew-demo.mp4`,type:`video/mp4`})]}),i&&(0,R.jsx)(`button`,{type:`button`,className:V.videoUnmute,onClick:c,children:t(`tap for sound`)})]}):(0,R.jsxs)(`button`,{type:`button`,className:V.videoStandby,onClick:()=>{r(!0),lu(`demo_video_play`,0,0)},children:[(0,R.jsx)(`span`,{className:V.videoPlayDot,"aria-hidden":!0,children:(0,R.jsx)(`svg`,{viewBox:`0 0 24 24`,width:`20`,height:`20`,children:(0,R.jsx)(`path`,{d:`M8 5.5v13l11-6.5z`,fill:`currentColor`})})}),(0,R.jsx)(`span`,{className:V.videoLabel,children:t(`watch the real thing · 2 min`)})]})})]})}function ld(){let e=z(),t=[{res:`verified`,source:`github`,text:e(`ship the landing page`),cat:`build`},{res:`attested`,text:e(`call 5 users`),cat:`sales`},{res:`missed`,text:e(`fix the auth bug`),cat:`build`}];return(0,R.jsx)(`div`,{className:V.recWrap,children:(0,R.jsx)(`ul`,{className:V.recList,children:t.map((e,t)=>{let n=e.res!==`missed`;return(0,R.jsxs)(`li`,{className:V.recRow,children:[(0,R.jsx)(Vl,{checked:n,onChange:qu,label:e.text}),(0,R.jsxs)(`div`,{className:V.recBody,children:[(0,R.jsxs)(`div`,{className:V.recTop,children:[(0,R.jsx)(`span`,{className:V.recNum,children:t+1}),(0,R.jsx)(`span`,{className:B(V.recTask,n&&V.recTaskDone),children:e.text})]}),(0,R.jsxs)(`span`,{className:V.recMeta,children:[(0,R.jsx)(`span`,{className:V.recNote,children:e.cat}),(0,R.jsx)(zl,{resolution:e.res,source:e.source,size:`sm`})]})]})]},e.text)})})})}function ud(){let e=z(),[t,n]=(0,_.useState)(`idle`);return(0,_.useEffect)(()=>
64{if(t!==`checking`)return;let e=setTimeout(()=>n(`done`),1100);return()=>clearTimeout(e)},[t]),(0,R.jsxs)(`div`,{className:B(V.pop,t===`checking`&&V.popCapturing),children:[(0,R.jsxs)(`div`,{className:V.popHead,children:[(0,R.jsxs)(`span`,{className:V.popMark,children:[`crew`,(0,R.jsx)(`span`,{className:V.popCaret,"aria-hidden":!0})]}),(0,R.jsx)(`span`,{className:V.popCount,children:e(t===`done`?`0 left`:`1 left`)})]}),(0,R.jsx)(`p`,{className:V.popHint,children:e(`Marking a task done captures this tab once, as proof. Try it.`)}),(0,R.jsxs)(`div`,{className:V.popTasks,children:[(0,R.jsxs)(`div`,{className:B(V.popTask,V.popTaskFirst,V.popTaskSpent),children:[(0,R.jsx)(`span`,{className:V.popTaskBody,children:(0,R.jsx)(`span`,{className:B(V.popTaskText,V.popStruck),children:e(`ship the landing page`)})}),(0,R.jsx)(`span`,{className:B(V.popMark2,V.popMarkSpent),children:e(`Done`)})]}),(0,R.jsx)(`p`,{className:V.popResult,children:e(`the deploy log for crew.vercel.app is on screen, dated today. that ships it.`)}),(0,R.jsxs)(`div`,{className:B(V.popTask,t===`done`&&V.popTaskSpent),children:[(0,R.jsxs)(`span`,{className:V.popTaskBody,children:[(0,R.jsx)(`span`,{className:B(V.popTaskText,t===`done`&&V.popStruck),children:e(`email the 2 leads`)}),t!==`done`&&(0,R.jsx)(`span`,{className:V.popTaskMeta,children:e(`1/3 steps`)})]}),t===`idle`&&(0,R.jsx)(`button`,{type:`button`,className:B(V.popMark2,V.popMarkPrimary,V.popBtn),onClick:()=>n(`checking`),children:e(`Mark done`)}),t===`checking`&&(0,R.jsx)(`span`,{className:B(V.popMark2,V.popMarkChecking),children:e(`checkingâ¦`)}),t===`done`&&(0,R.jsx)(`span`,{className:B(V.popMark2,V.popMarkSpent),children:e(`Done`)})]}),t===`done`&&(0,R.jsx)(`p`,{className:V.popResult,children:e(`2 sent emails are on screen in gmail, both to leads. that counts.`)})]}),(0,R.jsxs)(`div`,{className:V.popFoot,children:[t===`done`?(0,R.jsx)(`button`,{type:`button`,className:V.popReplay,onClick:()=>n(`idle`),children:e(`replay`)}):(0,R.jsx)(`span`,{className:V.popQuiet,children:e(`Proof is on another screen or app â`)}),(0,R.jsxs)(`span`,{className:V.popLinks,children:[(0,R.jsx)(`span`,{children:e(`Open Crew`)}),(0,R.jsx)(`span`,{children:e(`Settings`)})]})]}),(0,R.jsx)(`span`,{className:V.popFlash,"aria-hidden":!0})]})}var dd=[{streak:0,longestStreak:0,atRisk:!1},{streak:1,longestStreak:1,atRisk:!1},{streak:5,longestStreak:5,atRisk:!1},{streak:10,longestStreak:10,atRisk:!1},{streak:11,longestStreak:11,atRisk:!1},{streak:25,longestStreak:25,atRisk:!1},{streak:50,longestStreak:50,atRisk:!1},{streak:50,longestStreak:50,atRisk:!0},{streak:0,longestStreak:50,atRisk:!1}];function fd(){let e=z(),t=pu(),[n,r]=(0,_.useState)(0),[i,a]=(0,_.useState)(0);(0,_.useEffect)(()=>{if(t)return;let e=setInterval(()=>{Date.now()<i||r(e=>(e+1)%dd.length)},1700);return()=>clearInterval(e)},[t,i]);function o(){r(e=>(e+1)%dd.length),a(Date.now()+6e3)}let s=dd[t?4:n],c=s.atRisk?e(`day {n} · at risk`).replace(`{n}`,String(s.streak)):s.streak===0&&s.longestStreak>0?e(`broken · was {n}`).replace(`{n}`,String(s.longestStreak)):e(`day {n}`).replace(`{n}`,String(s.streak));return(0,R.jsxs)(`button`,{type:`button`,className:V.growDemo,onClick:o,"aria-label":e(`advance the growth demo`),children:[(0,R.jsx)(Hu,{streak:s.streak,longestStreak:s.longestStreak,atRisk:s.atRisk,size:180}),(0,R.jsxs)(`span`,{className:V.growCaption,children:[c,(0,R.jsx)(`i`,{className:V.growHint,children:e(`click to advance`)})]})]})}function pd({value:e,label:t}){return(0,R.jsxs)(`div`,{className:V.stat,children:[(0,R.jsx)(`span`,{className:V.statNum,children:e}),(0,R.jsx)(`span`,{className:V.statLabel,children:t})]})}function md(){let e=z(),t=[{k:e(`goal`),v:e(`500 paying users by December`)},{k:e(`business context`),v:e(`B2B SaaS, selling to design agencies`)},{k:e(`connected (live)`),v:`github, google_calendar, stripe`},{k:e(`today's tasks`),v:e(`1. ship the landing page · 2. email the 2 leads · 3. fix the auth bug`)},{k:e(`github activity`),v:e(`7 commits · 1 PR merged · 0 on the auth branch`)},{k:e(`calendar`),v:e(`2 calls held · 1 no-show`)}];return(0,R.jsxs)(`div`,{className:V.ctxPanel,children:[(0,R.jsx)(`span`,{className:V.ctxHead,children:e(`founder context`)}),(0,R.jsx)(`dl`,{className:V.ctxRows,children:t.map(e=>(0,R.jsxs)(`div`,{className:V.ctxRow,children:[(0,R.jsxs)(`dt`,{className:V.ctxKey,children:[e.k,`:`]}),(0,R.jsx)(`dd`,{className:V.ctxVal,children:e.v})]},e.k))}),(0,R.jsx)(`span`,{className:V.ctxFoot,children:e(`assembled fresh on every message it sends you.`)})]})}function hd(){let e=z(),[t,n]=(0,_.useState)(!1);return(0,R.jsxs)(`div`,{className:V.podBoard,children:[(0,R.jsxs)(`div`,{className:B(V.podCard,V.podCardMe),children:[(0,R.jsxs)(`div`,{className:V.podCardHead,children:[(0,R.jsxs)(`span`,{className:V.podIdent,children:[(0,R.jsx)(`span`,{className:V.podName,children:e(`You`)}),(0,R.jsx)(`span`,{className:V.podProduct,children:`Inkforge`})]}),(0,R.jsxs)(`span`,{className:V.podChips,children:[(0,R.jsxs)(`span`,{className:V.podChip,children:[(0,R.jsx)(`b`,{children:t?`100%`:`50%`}),(0,R.jsx)(`i`,{children:e(`done`)})]}),(0,R.jsxs)(`span`,{className:V.podChip,children:[(0,R.jsx)(`b`,{children:`8`}),(0,R.jsx)(`i`,{children:e(`streak`)})]}),(0,R.jsxs)(`span`,{className:V.podChip,children:[(0,R.jsx)(`b`,{children:`5`}),(0,R.jsx)(`i`,{children:e(`commits`)})]})]})]}
64),(0,R.jsxs)(`div`,{className:V.podBlock,children:[(0,R.jsx)(`span`,{className:V.podBlockLabel,children:e(`shipped`)}),(0,R.jsxs)(`span`,{className:V.podItem,children:[(0,R.jsx)(`i`,{className:V.podDot}),(0,R.jsx)(`span`,{className:V.podItemText,children:e(`fix the auth bug`)}),(0,R.jsx)(`span`,{className:V.podItemProof,children:`3 commits`})]}),(0,R.jsxs)(`button`,{type:`button`,className:B(V.podItem,V.podItemBtn),onClick:()=>n(e=>!e),children:[(0,R.jsx)(`i`,{className:B(V.podDot,t?V.podDotSelf:V.podDotOpen)}),(0,R.jsx)(`span`,{className:B(V.podItemText,!t&&V.podItemOpen),children:e(`write the product spec`)}),(0,R.jsx)(`span`,{className:V.podItemProof,children:e(t?`done · on your word`:`mark done`)})]})]})]}),(0,R.jsxs)(`div`,{className:V.podCard,children:[(0,R.jsxs)(`div`,{className:V.podCardHead,children:[(0,R.jsxs)(`span`,{className:V.podIdent,children:[(0,R.jsx)(`span`,{className:V.podName,children:`Sarah K.`}),(0,R.jsx)(`span`,{className:V.podProduct,children:`Replyflow`})]}),(0,R.jsxs)(`span`,{className:V.podChips,children:[(0,R.jsxs)(`span`,{className:V.podChip,children:[(0,R.jsx)(`b`,{children:`67%`}),(0,R.jsx)(`i`,{children:e(`done`)})]}),(0,R.jsxs)(`span`,{className:V.podChip,children:[(0,R.jsx)(`b`,{children:`14`}),(0,R.jsx)(`i`,{children:e(`streak`)})]})]})]}),(0,R.jsx)(`div`,{className:V.podBlock,children:(0,R.jsx)(`span`,{className:V.podBlockLabel,children:e(`4 shipped this week · 2 slipped`)})})]})]})}function gd(){let e=z(),[t,n]=Zl(.12);(0,_.useEffect)(()=>{cu(`/`)},[]),(0,_.useEffect)(()=>du(),[]),(0,_.useEffect)(()=>{let e=window.location.hash.replace(`#`,``);if(!e)return;let t=setTimeout(()=>{document.getElementById(e)?.scrollIntoView({behavior:`smooth`})},80);return()=>clearTimeout(t)},[]);function r(e){let t=e.target,n=t.closest(`button`),r=t.closest(`a`);n?lu(n.textContent?.trim().slice(0,60)??`button`,e.clientX,e.clientY):r&&lu(r.href?.split(`/`).pop()||r.textContent?.trim().slice(0,60)||`link`,e.clientX,e.clientY)}let i=[e(`The day gets decided by whoever emails first.`),e(`The same task moves to tomorrow, four days running.`),e(`A busy week, and nothing you can point at.`),e(`Nobody notices if you quietly stop shipping.`)],a=[{k:e(`One decision a day`),v:e(`lock it, then work`)},{k:e(`Proof, not vibes`),v:e(`verified or it is not done`)},{k:e(`No status updates`),v:e(`the evening writes itself`)},{k:e(`It comes after you`),v:e(`two quiet days and it asks`)}],o=[{name:`Claude`,slug:`claude`,hex:`D97757`},{name:`Claude Code`,slug:`anthropic`,hex:`181818`},{name:`ChatGPT`,slug:`openai`,hex:`412991`},{name:`Codex`,slug:`openai`,hex:`412991`},{name:`Cursor`,slug:`cursor`,hex:`000000`},{name:`Copilot`,slug:`githubcopilot`,hex:`000000`},{name:`Gemini`,slug:`googlegemini`,hex:`8E75B2`},{name:`VS Code`,slug:`visualstudiocode`,hex:`007ACC`},{name:`Windsurf`,slug:`windsurf`,hex:`58B6A5`},{name:`Perplexity`,slug:`perplexity`,hex:`1FB8CD`}],s=[{name:`GitHub`,slug:`github`,hex:`181717`},{name:`Stripe`,slug:`stripe`,hex:`635BFF`},{name:`Linear`,slug:`linear`,hex:`5E6AD2`},{name:`Notion`,slug:`notion`,hex:`000000`},{name:`Slack`,slug:`slack`,hex:`4A154B`},{name:`Jira`,slug:`jira`,hex:`0052CC`},{name:`Gmail`,slug:`gmail`,hex:`EA4335`},{name:`Google Calendar`,slug:`googlecalendar`,hex:`4285F4`},{name:`Vercel`,slug:`vercel`,hex:`000000`},{name:`Zoom`,slug:`zoom`,hex:`0B5CFF`},{name:`Google Meet`,slug:`googlemeet`,hex:`00897B`},{name:`Calendly`,slug:`calendly`,hex:`006BFF`},{name:`HubSpot`,slug:`hubspot`,hex:`FF7A59`},{name:`Salesforce`,slug:`salesforce`,hex:`00A1E0`},{name:`Intercom`,slug:`intercom`,hex:`1F8DED`},{name:`Zendesk`,slug:`zendesk`,hex:`03363D`},{name:`GitLab`,slug:`gitlab`,hex:`FC6D26`},{name:`Bitbucket`,slug:`bitbucket`,hex:`0052CC`},{name:`Asana`,slug:`asana`,hex:`F06A6A`},{name:`ClickUp`,slug:`clickup`,hex:`7B68EE`},{name:`Trello`,slug:`trello`,hex:`0052CC`},{name:`Confluence`,slug:`confluence`,hex:`172B4D`},{name:`Google Docs`,slug:`googledocs`,hex:`4285F4`},{name:`Sheets`,slug:`googlesheets`,hex:`34A853`},{name:`Drive`,slug:`googledrive`,hex:`4285F4`},{name:`Dropbox`,slug:`dropbox`,hex:`0061FF`},{name:`Outlook`,slug:`microsoftoutlook`,hex:`0078D4`},{name:`Canva`,slug:`canva`,hex:`00C4CC`},{name:`Miro`,slug:`miro`,hex:`FFD02F`},{name:`YouTube`,slug:`youtube`,hex:`FF0000`},{name:`Instagram`,slug:`instagram`,hex:`E4405F`},{name:`Mailchimp`,slug:`mailchimp`,hex:`FFE01B`},{name:`Typeform`,slug:`typeform`,hex:`262627`}],c=e=>({"--lurl":`url('https://cdn.jsdelivr.net/npm/simple-icons@latest/icons/${e.slug}.svg')`,"--lclr":`#${e.hex}`});return(0,R.jsxs)(`div`,{className:V.page,"data-theme":`light`,onClick:r,children:[(0,R.jsx)(Xu,{}),(0,R.jsxs)(`section`,{className:V.hero,children:[(0,R.jsxs)(`div`,{className:V.heroAura,"aria-hidden":!0,
64children:[(0,R.jsx)(`span`,{className:V.auraA}),(0,R.jsx)(`span`,{className:V.auraB})]}),(0,R.jsxs)(`div`,{className:V.heroInner,children:[(0,R.jsxs)(`div`,{className:V.heroLeft,children:[(0,R.jsx)(`span`,{className:V.eyebrow,children:e(`on Telegram · morning and evening`)}),(0,R.jsxs)(`h1`,{className:V.headline,children:[(0,R.jsx)(`span`,{className:V.headClip,style:{"--d":`0.16s`},children:e(`The AI co-founder`)}),(0,R.jsx)(`span`,{className:B(V.headClip,V.headAccent),style:{"--d":`0.32s`},children:e(`you can't ignore.`)})]}),(0,R.jsx)(`p`,{className:V.subline,children:e(`It plans your day, then checks what you actually shipped.`)}),(0,R.jsx)(ed,{}),(0,R.jsxs)(`p`,{className:V.heroDemo,children:[e(`Want to see it first?`),` `,(0,R.jsx)(`a`,{className:V.heroDemoLink,href:nd,target:`_blank`,rel:`noopener noreferrer`,children:e(`Book a 15-minute demo â`)})]}),(0,R.jsxs)(`ul`,{className:V.perks,children:[(0,R.jsxs)(`li`,{className:V.perk,children:[(0,R.jsx)(`span`,{className:V.perkDot,"aria-hidden":!0}),e(`free until launch, no card required`)]}),(0,R.jsxs)(`li`,{className:V.perk,children:[(0,R.jsx)(`span`,{className:V.perkDot,"aria-hidden":!0}),e(`ask for a feature, it ships within 24 hours`)]})]}),(0,R.jsxs)(`p`,{className:V.heroInvite,children:[e(`Already have an invite code?`),` `,(0,R.jsx)(Rn,{to:`/auth`,className:V.heroInviteLink,onClick:e=>lu(`hero_create_account`,e.clientX,e.clientY),children:e(`create your account â`)})]})]}),(0,R.jsx)(`div`,{className:V.heroRight,children:(0,R.jsx)(Yu,{max:10,children:(0,R.jsx)(ad,{})})})]})]}),(0,R.jsx)(`section`,{ref:t,className:B(V.videoSection,n&&V.videoVisible),children:(0,R.jsx)(`div`,{className:V.sectionInner,children:(0,R.jsx)(cd,{active:n})})}),(0,R.jsx)(`section`,{id:`problem`,className:V.problem,children:(0,R.jsxs)(`div`,{className:V.sectionInner,children:[(0,R.jsx)(`h2`,{className:V.problemTitle,children:e(`Sound familiar?`)}),(0,R.jsx)(`ul`,{className:V.problemList,children:i.map(e=>(0,R.jsx)(`li`,{className:V.problemItem,children:e},e))})]})}),(0,R.jsxs)(`section`,{id:`how`,className:V.features,children:[(0,R.jsxs)(`div`,{className:V.feat,children:[(0,R.jsxs)(`div`,{className:V.featCopy,children:[(0,R.jsx)(`span`,{className:V.featTag,children:e(`THE PLAN`)}),(0,R.jsx)(`h2`,{className:V.featTitle,children:e(`Lock the day in the morning.`)}),(0,R.jsx)(`p`,{className:V.featSub,children:e(`You pick up to three things. Once locked, they cannot be quietly rewritten later.`)})]}),(0,R.jsx)(`div`,{className:V.featVisual,children:(0,R.jsx)(ld,{})})]}),(0,R.jsxs)(`div`,{className:B(V.feat,V.featFlip),children:[(0,R.jsxs)(`div`,{className:V.featCopy,children:[(0,R.jsx)(`span`,{className:V.featTag,children:e(`THE CO-FOUNDER`)}),(0,R.jsx)(`h2`,{className:V.featTitle,children:e(`Ask it anything. It knows your business.`)}),(0,R.jsx)(`p`,{className:V.featSub,children:e(`It has read your goal, your last month of work, and what you keep avoiding.`)})]}),(0,R.jsx)(`div`,{className:V.featVisual,children:(0,R.jsx)(Yu,{max:8,children:(0,R.jsx)(sd,{})})})]}),(0,R.jsx)(`div`,{className:V.featAside,children:(0,R.jsx)(md,{})}),(0,R.jsxs)(`div`,{className:V.feat,children:[(0,R.jsxs)(`div`,{className:V.featCopy,children:[(0,R.jsx)(`span`,{className:V.featTag,children:e(`THE PROOF`)}),(0,R.jsx)(`h2`,{className:V.featTitle,children:e(`One keystroke proves it.`)}),(0,R.jsx)(`p`,{className:V.featSub,children:e(`Send a screenshot, a photo or a link. Work no tool can see still counts.`)})]}),(0,R.jsx)(`div`,{className:V.featVisual,children:(0,R.jsx)(ud,{})})]}),(0,R.jsxs)(`div`,{className:B(V.feat,V.featFlip),children:[(0,R.jsxs)(`div`,{className:V.featCopy,children:[(0,R.jsx)(`span`,{className:V.featTag,children:e(`THE VERDICT`)}),(0,R.jsx)(`h2`,{className:V.featTitle,children:e(`At night, it reads the day back.`)}),(0,R.jsx)(`p`,{className:V.featSub,children:e(`Each task gets one of three answers: proven, taken on your word, or missed.`)})]}),(0,R.jsx)(`div`,{className:V.featVisual,children:(0,R.jsx)(Yu,{max:8,children:(0,R.jsx)(od,{})})})]}),(0,R.jsxs)(`div`,{className:V.feat,children:[(0,R.jsxs)(`div`,{className:V.featCopy,children:[(0,R.jsx)(`span`,{className:V.featTag,children:e(`THE STREAK`)}),(0,R.jsx)(`h2`,{className:V.featTitle,children:e(`Consistency grows. Miss, and it shows.`)}),(0,R.jsx)(`p`,{className:V.featSub,children:e(`A plant that grows with your streak. One bad day wilts it; it does not kill it.`)})]}),(0,R.jsx)(`div`,{className:V.featVisual,children:(0,R.jsx)(fd,{})})]}),(0,R.jsxs)(`div`,{className:B(V.feat,V.featFlip),children:[(0,R.jsxs)(`div`,{className:V.featCopy,children:[(0,R.jsx)(`span`,{className:V.featTag,children:e(`THE POD`)}),(0,R.jsx)(`h2`,{className:V.featTitle,children:e(`One other founder sees your numbers.`)}),(0,R.jsx)(`p`,{className:V.featSub,children:e(`They see your rate and your streak. They never see what you are working on.`)})]}),(0,R.jsx)(`div`,{className:V.featVisual,children:(0,R.jsx)(hd,{})})]}),(0,R.jsxs)(`div`,{className:V.mcp,children:[(0,R.jsx)(`span`,{className:V.featTag,children:e(`AI AGENTS`)}),(0,R.jsx)(`h2`,{className:V.featTitle,children:e(`Your AI already knows what you shipped.`)}),(0,R.jsx)(`p`,{className:V.featSub,children:e(`Crew speaks MCP, so the assistant you already have open can read your record and lock your day. Ask it what you shipped this week and it answers from receipts, not memory.`)}),(0,R.jsx)(`div`,{className:V.agentGrid,children:o.map(e=>(0,R.jsxs)(`span`,{className:V.agentTile,style:c({slug:e.slug,hex:e.hex}),children:[(0,R.jsx)(`span`,{className:V.agentLogo,"aria-hidden":!0}),(0,R.jsx)(`span`,{className:V.agentName,children:e.name})]},e.name))}),(0,R.jsx)(`p`,{className:V.featSub,children:e(`It can lock tasks, carry them and record proof. It cannot mark a past day done, write its own verdict, or touch your billing â and every row it writes is tagged as agent-written.`)}),(0,R.jsxs)(`a`,{className:V.mcpCta,href:nd,target:`_blank`,rel:`noopener noreferrer`,children:[e(`Request a demo`),` â`]})]}),(0,R.jsxs)(`div`,{className:V.connectors,children:[(0,R.jsx)(`span`,{className:V.featTag,children:e(`CONNECTORS`)}),(0,R.jsx)(`h2`,{className:V.featTitle,children:e(`Your tools close the tasks themselves.`)}),(0,R.jsx)(`p`,{className:V.featSub,children:e(`Connect GitHub or Stripe and shipping something ticks it off without you saying so.`)}),(0,R.jsx)(`p`,{className:V.featSub,children:e(`32 read paths, re-checked against the live APIs every week. A dead one is caught by the check, not by your task failing to close.`)}),(0,R.jsx)(`div`,{className:V.connectorMarquee,children:(0,R.jsxs)(`ul`,{className:V.connectorTrack,children:[s.map(e=>(0,R.jsxs)(`li`,{className:V.connectorChip,children:[(0,R.jsx)(`span`,{className:V.connectorLogo,style:c(e)}),(0,R.jsx)(`span`,{className:V.srOnly,children:e.name})]},e.slug)),s.map(e=>(0,R.jsx)(`li`,{className:V.connectorChip,"aria-hidden":`true`,children:(0,R.jsx)(`span`,{className:V.connectorLogo,style:c(e)})},`dup-${e.slug}`))]})}),(0,R.jsx)(`p`,{className:V.connectorNote,children:e(`read-only · Crew never posts, sends or pays as you`)})]})]}),(0,R.jsx)(`section`,{className:V.benefits,children:(0,R.jsxs)(`div`,{className:V.sectionInner,children:[(0,R.jsx)(`ul`,{className:V.benefitGrid,children:a.map(e=>(0,R.jsxs)(`li`,{className:V.benefit,children:[(0,R.jsx)(`span`,{className:V.benefitK,children:e.k}),(0,R.jsx)(`span`,{className:V.benefitV,children:e.v})]},e.k))}),(0,R.jsxs)(`div`,{className:V.statsInline,children:[(0,R.jsx)(pd,{value:`3`,label:e(`tasks a day by default`)}),(0,R.jsx)(`div`,{className:V.statDivider}),(0,R.jsx)(pd,{value:`0`,label:e(`connectors needed to start`)}),(0,R.jsx)(`div`,{className:V.statDivider}),(0,R.jsx)(pd,{value:`$0`,label:e(`until launch`)}
64)]})]})}),(0,R.jsx)(`section`,{id:`fit`,className:V.quizSection,children:(0,R.jsxs)(`div`,{className:V.sectionInner,children:[(0,R.jsxs)(`div`,{className:V.quizHead,children:[(0,R.jsx)(`span`,{className:V.featTag,children:e(`30 SECONDS`)}),(0,R.jsx)(`h2`,{className:V.featTitle,children:e(`What would Crew fix for you?`)})]}),(0,R.jsx)(Gu,{})]})}),(0,R.jsx)(`section`,{id:`waitlist`,onMouseMove:Ju,className:B(V.waitSection,V.glowHost,V.waitVisible),children:(0,R.jsxs)(`div`,{className:V.waitInner,children:[(0,R.jsx)(`span`,{className:V.waitBadge,children:e(`EARLY ACCESS · INVITE ONLY`)}),(0,R.jsx)(`h2`,{className:V.waitTitle,children:e(`Lock your first day tomorrow morning.`)}),(0,R.jsx)(ed,{inverted:!0}),(0,R.jsx)(`p`,{className:V.waitTrust,children:e(`free until launch, no card. invite-only while we onboard one founder at a time.`)}),(0,R.jsx)(`p`,{className:V.waitInvite,children:(0,R.jsx)(`a`,{className:V.waitInviteLink,href:nd,target:`_blank`,rel:`noopener noreferrer`,children:e(`Book a 15-minute demo â`)})}),(0,R.jsxs)(`p`,{className:V.waitInvite,children:[e(`Already have an invite code?`),` `,(0,R.jsx)(Rn,{to:`/auth`,className:V.waitInviteLink,onClick:e=>lu(`cta_create_account`,e.clientX,e.clientY),children:e(`create your account â`)})]})]})}),(0,R.jsx)(`footer`,{className:V.footer,children:(0,R.jsxs)(`div`,{className:V.footerInner,children:[(0,R.jsx)(El,{size:15}),(0,R.jsx)(`span`,{className:V.footerCopy,children:e(`© 2026 Crew`)}),(0,R.jsxs)(`div`,{className:V.footerRight,children:[(0,R.jsx)(`a`,{href:`/blog`,className:V.footerLink,children:e(`Blog`)}),(0,R.jsx)(Rn,{to:`/privacy`,className:V.footerLink,children:e(`Privacy Policy`)}),(0,R.jsx)(Rn,{to:`/terms`,className:V.footerLink,children:e(`Terms of Service`)}),(0,R.jsx)(Rn,{to:`/compliance`,className:V.footerLink,children:e(`Compliance`)})]})]})})]})}var _d={page:`_page_1x37x_3`,card:`_card_1x37x_10`,mark:`_mark_1x37x_18`,title:`_title_1x37x_19`,body:`_body_1x37x_20`,limits:`_limits_1x37x_21`,actions:`_actions_1x37x_30`,primary:`_primary_1x37x_31`,secondary:`_secondary_1x37x_31`,foot:`_foot_1x37x_38`},vd=`mcp-oauth`;function yd(){let e=z(),[t,n]=(0,_.useState)(`checking`),[r,i]=(0,_.useState)(``),[a,o]=(0,_.useState)(`An MCP client`),s=new URLSearchParams(window.location.search),c=s.get(`client_id`)??``,l=s.get(`redirect_uri`)??``,u=s.get(`state`)??``,d=s.get(`code_challenge`)??``,f=s.get(`code_challenge_method`)??``,p=s.get(`scope`)?.includes(`read`)&&!s.get(`scope`)?.includes(`write`)?`read`:`write`;(0,_.useEffect)(()=>{(async()=>{if(!c||!l||!d){n(`error`),i(e(`This link is missing the parameters an authorisation request needs. Start the connection again from your client.`));return}if(f&&f!==`S256`){n(`error`),i(e(`That client asked for an unsupported security method. Crew only accepts S256.`));return}let{data:t}=await L.auth.getSession();if(!t.session){n(`signin`);return}o(s.get(`client_name`)||`An MCP client`),n(`ready`)})()},[]);async function m(){n(`working`);let{data:t}=await L.auth.getSession(),r=t.session?.access_token;if(!r){n(`signin`);return}let a=await fetch(`https://zwqymcoehifdzniztfzc.supabase.co/functions/v1/${vd}?p=grant`,{method:`POST`,headers:{Authorization:`Bearer ${r}`,"Content-Type":`application/json`},body:JSON.stringify({client_id:c,redirect_uri:l,code_challenge:d,scope:p})}),o=await a.json().catch(()=>({}));if(!a.ok||!o.code){n(`error`),i(o.error??e(`Crew could not issue the code.`));return}let s=new URL(l);s.searchParams.set(`code`,o.code),u&&s.searchParams.set(`state`,u),window.location.href=s.toString()}function h(){if(!l){window.location.href=`/app`;return}let e=new URL(l);e.searchParams.set(`error`,`access_denied`),u&&e.searchParams.set(`state`,u),window.location.href=e.toString()}return(0,R.jsx)(`div`,{className:_d.page,children:(0,R.jsxs)(`div`,{className:_d.card,children:[(0,R.jsx)(`div`,{className:_d.mark,"aria-hidden":!0,children:`â`}),t===`checking`&&(0,R.jsx)(`p`,{className:_d.body,children:e(`Checking your sessionâ¦`)}),t===`signin`&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`h1`,{className:_d.title,children:e(`Sign in to connect`)}),(0,R.jsx)(`p`,{className:_d.body,children:e(`You need to be signed in to Crew before you can connect a client to it.`)}),(0,R.jsx)(`a`,{className:_d.primary,href:`/auth?next=${encodeURIComponent(window.location.pathname+window.location.search)}`,children:e(`Sign in`)})]}),t===`error`&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`h1`,{className:_d.title,children:e(`That did not work`)}),(0,R.jsx)(`p`,{className:_d.body,children:r}),(0,R.jsx)(`a`,{className:_d.secondary,href:`/app`,children:e(`Back to Crew`)})]}),(t===`ready`||t===`working`)&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`h1`,{className:_d.title,children:e(`Connect {client} to Crew?`).replace(`{client}`,a)}),(0,R.jsx)(`p`,{className:_d.body,children:e(p===`write`?`It will be able to read your tasks, goals, streak and settings, and to create, edit and carry tasks on your behalf.`:`It will be able to read your tasks, goals, streak and settings. It c
64annot change anything.`)}),(0,R.jsxs)(`ul`,{className:_d.limits,children:[(0,R.jsx)(`li`,{children:e(`It cannot mark past days done â a closed day stays closed.`)}),(0,R.jsx)(`li`,{children:e(`It cannot write a verdict. Proof goes to the judge, same as always.`)}),(0,R.jsx)(`li`,{children:e(`It cannot touch billing, your plan, or delete your account.`)}),(0,R.jsx)(`li`,{children:e(`It cannot see anyone elseâs data.`)}),(0,R.jsx)(`li`,{children:e(`Everything it writes is tagged as written by an agent.`)})]}),(0,R.jsxs)(`div`,{className:_d.actions,children:[(0,R.jsx)(`button`,{className:_d.primary,onClick:m,disabled:t===`working`,children:e(t===`working`?`Connectingâ¦`:`Connect`)}),(0,R.jsx)(`button`,{className:_d.secondary,onClick:h,disabled:t===`working`,children:e(`Cancel`)})]}),(0,R.jsx)(`p`,{className:_d.foot,children:e(`You can revoke this at any time in Settings.`)})]})]})})}var bd={page:`_page_dyopk_7`,back:`_back_dyopk_14`,hero:`_hero_dyopk_18`,lockup:`_lockup_dyopk_19`,times:`_times_dyopk_20`,clientMark:`_clientMark_dyopk_21`,clientName:`_clientName_dyopk_32`,title:`_title_dyopk_38`,lede:`_lede_dyopk_44`,clientBar:`_clientBar_dyopk_47`,clientBtn:`_clientBtn_dyopk_52`,clientBtnMark:`_clientBtnMark_dyopk_62`,clientBtnOn:`_clientBtnOn_dyopk_70`,step:`_step_dyopk_73`,skillStep:`_skillStep_dyopk_77`,stepNum:`_stepNum_dyopk_78`,h2:`_h2_dyopk_84`,hint:`_hint_dyopk_85`,copyRow:`_copyRow_dyopk_87`,code:`_code_dyopk_88`,copyBtn:`_copyBtn_dyopk_96`,copyBtnDone:`_copyBtnDone_dyopk_101`,steps:`_steps_dyopk_103`,cta:`_cta_dyopk_107`,ghost:`_ghost_dyopk_107`,note:`_note_dyopk_114`,cols:`_cols_dyopk_116`,can:`_can_dyopk_117`,cannot:`_cannot_dyopk_117`,recommended:`_recommended_dyopk_127`,foot:`_foot_dyopk_136`},xd=`https://www.meetcrew.app/api/mcp`,Sd=`curl -fsSL https://www.meetcrew.app/install/crew-skill.sh | bash`,Cd=`https://www.meetcrew.app/install/crew-capture-SKILL.md`,wd=e=>`url('https://cdn.jsdelivr.net/npm/simple-icons@latest/icons/${e}.svg')`,Td=[{key:`claude`,name:`Claude`,slug:`claude`,hex:`D97757`,snippet:xd,snippetLabel:`connector URL`,href:`https://claude.ai/settings/connectors`,hrefLabel:`Open Claude connectors`,steps:[`Settings â Connectors â Add custom connector.`,`Paste the URL and click Add.`,`Click Connect, approve the Crew screen, done.`],note:`Same in the desktop app and on claude.ai. No token to paste â Crew asks you to sign in.`},{key:`claude-code`,name:`Claude Code`,slug:`anthropic`,hex:`181818`,snippet:`claude mcp add --transport http crew ${xd}`,snippetLabel:`terminal command`,steps:[`Run the command in your terminal.`,`Run /mcp to confirm Crew is connected.`],note:`The only client where the capture skill below does anything.`,skill:!0},{key:`chatgpt`,name:`ChatGPT`,slug:`openai`,hex:`412991`,snippet:xd,snippetLabel:`connector URL`,href:`https://chatgpt.com`,hrefLabel:`Open ChatGPT`,steps:[`Settings â Apps â turn on Developer mode.`,`Add a custom connector and paste the URL.`,`Approve the Crew screen.`],note:`Needs Plus, Pro, Business or Enterprise. On a work account an admin can switch Developer mode off.`},{key:`codex`,name:`Codex`,slug:`openai`,hex:`412991`,snippet:xd,snippetLabel:`connector URL`,steps:[`Add Crew as a remote MCP server in your Codex config.`,`Approve the Crew screen when it opens.`],note:`Codex uses the same remote MCP support as the rest of OpenAI's tooling.`},{key:`cursor`,name:`Cursor`,slug:`cursor`,hex:`000000`,snippet:`{\n "mcpServers": {\n "crew": { "url": "${xd}" }\n }\n}`,snippetLabel:`mcp.json`,steps:[`Settings â MCP â Add new server.`,`Paste the block, or add it to .cursor/mcp.json.`,`Approve the Crew screen.`]},{key:`gemini`,name:`Gemini CLI`,slug:`googlegemini`,hex:`8E75B2`,snippet:`{\n "mcpServers": {\n "crew": { "httpUrl": "${xd}" }\n }\n}`,snippetLabel:`~/.gemini/settings.json`,steps:[`Open ~/.gemini/settings.json.`,`Add Crew under mcpServers.`,`Restart the CLI; it opens a browser once to approve.`],note:`Gemini speaks remote MCP through the CLI and the SDKs. The consumer Gemini app does not take custom connectors.`},{key:`copilot`,name:`Copilot`,slug:`githubcopilot`,hex:`000000`,snippet:`{\n "servers": {\n "crew": { "type": "http", "url": "${xd}" }\n }\n}`,snippetLabel:`.vscode/mcp.json`,steps:[`Create .vscode/mcp.json in your project.`,`Paste the block and reload the window.`,`Approve the Crew screen.`]},{key:`windsurf`,name:`Windsurf`,slug:`windsurf`,hex:`58B6A5`,snippet:`{\n "mcpServers": {\n "crew": { "serverUrl": "${xd}" }\n }\n}`,snippetLabel:`mcp_config.json`,steps:[`Open the MCP settings and edit the config.`,`Add Crew, then refresh the server list.`,`Approve the Crew screen.`]}];function Ed({value:e}){let t=z(),[n,r]=(0,_.useState)(!1);return(0,R.jsxs)(`div`,{className:bd.copyRow,children:[(0,R.jsx)(`pre`,{className:bd.code,children:(0,R.jsx)(`code`,{children:e})}),(0,R.jsx)(`button`,{className:B(bd.copyBtn,n&&bd.copyBtnDone),onClick:()=>navigator.clipboard.writeText(e).then(()=>{r(!0),setTimeout(()=>r(!1),1600)}),children:t(n?`copied`:`copy`)})]})}function Dd(){let e=z(),[t,n]=(0,_.useState)(`claude`),r=Td.find(e=>e.key===t)??Td[0];return(0,R.jsxs)(`div`,{className:bd.page,style:{"--client":`#${r.hex}`}
64,children:[(0,R.jsx)(Rn,{to:`/`,className:bd.back,children:e(`â Crew`)}),(0,R.jsxs)(`header`,{className:bd.hero,children:[(0,R.jsxs)(`div`,{className:bd.lockup,children:[(0,R.jsx)(El,{size:34}),(0,R.jsx)(`span`,{className:bd.times,"aria-hidden":!0,children:`Ã`}),(0,R.jsx)(`span`,{className:bd.clientMark,style:{"--mask-url":wd(r.slug)},"aria-hidden":!0}),(0,R.jsx)(`span`,{className:bd.clientName,children:r.name})]}),(0,R.jsx)(`h1`,{className:bd.title,children:e(`Your record, inside {client}.`).replace(`{client}`,r.name)}),(0,R.jsx)(`p`,{className:bd.lede,children:e(`Ask what you shipped this week and get an answer from receipts, not memory. Lock tomorrow without leaving the chat.`)})]}),(0,R.jsx)(`div`,{className:bd.clientBar,role:`tablist`,"aria-label":e(`Choose your assistant`),children:Td.map(e=>(0,R.jsxs)(`button`,{role:`tab`,"aria-selected":e.key===t,className:B(bd.clientBtn,e.key===t&&bd.clientBtnOn),style:{"--mask-url":wd(e.slug),"--brand":`#${e.hex}`},onClick:()=>n(e.key),children:[(0,R.jsx)(`span`,{className:bd.clientBtnMark,"aria-hidden":!0}),e.name]},e.key))}),(0,R.jsxs)(`section`,{className:bd.step,children:[(0,R.jsx)(`span`,{className:bd.stepNum,children:`1`}),(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`h2`,{className:bd.h2,children:e(`Copy this`)}),(0,R.jsx)(`p`,{className:bd.hint,children:e(r.snippetLabel)}),(0,R.jsx)(Ed,{value:r.snippet})]})]}),(0,R.jsxs)(`section`,{className:bd.step,children:[(0,R.jsx)(`span`,{className:bd.stepNum,children:`2`}),(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`h2`,{className:bd.h2,children:e(`Add it to {client}`).replace(`{client}`,r.name)}),(0,R.jsx)(`ol`,{className:bd.steps,children:r.steps.map(t=>(0,R.jsx)(`li`,{children:e(t)},t))}),r.href&&(0,R.jsxs)(`a`,{className:bd.cta,href:r.href,target:`_blank`,rel:`noopener noreferrer`,children:[e(r.hrefLabel??`Open`),` â`]}),r.note&&(0,R.jsx)(`p`,{className:bd.note,children:e(r.note)})]})]}),(0,R.jsxs)(`section`,{className:bd.step,children:[(0,R.jsx)(`span`,{className:bd.stepNum,children:`3`}),(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`h2`,{className:bd.h2,children:e(`What it can and cannot do`)}),(0,R.jsxs)(`div`,{className:bd.cols,children:[(0,R.jsxs)(`ul`,{className:bd.can,children:[(0,R.jsx)(`li`,{children:e(`Read your tasks, goals, streak and receipts`)}),(0,R.jsx)(`li`,{children:e(`Lock tasks, edit them, carry them forward`)}),(0,R.jsx)(`li`,{children:e(`Break a task into steps`)}),(0,R.jsx)(`li`,{children:e(`Record proof against a task`)})]}),(0,R.jsxs)(`ul`,{className:bd.cannot,children:[(0,R.jsx)(`li`,{children:e(`Mark a past day done â a closed day stays closed`)}),(0,R.jsx)(`li`,{children:e(`Write a verdict. Proof goes to the judge`)}),(0,R.jsx)(`li`,{children:e(`Touch billing, your plan, or your account`)}),(0,R.jsx)(`li`,{children:e(`See anyone elseâs data`)})]})]}),(0,R.jsx)(`p`,{className:bd.note,children:e(`Every row it writes is tagged as agent-written, so your record still says who did what. Revoke any time in Settings.`)})]})]}),(0,R.jsxs)(`section`,{className:B(bd.step,bd.skillStep),children:[(0,R.jsx)(`span`,{className:bd.stepNum,children:`+`}),(0,R.jsxs)(`div`,{children:[(0,R.jsxs)(`h2`,{className:bd.h2,children:[e(`Add the capture skill`),(0,R.jsx)(`span`,{className:bd.recommended,children:e(`recommended`)})]}),(0,R.jsx)(`p`,{className:bd.hint,children:e(`The connector lets your assistant reach Crew when you ask. The skill is what makes it act without being asked: it notices when you commit to real work mid-conversation and adds it, in one line.`)}),!r.skill&&(0,R.jsx)(`p`,{className:bd.note,children:e(`Claude Code only. It is a file on your machine, not part of the connector â MCP cannot install files, and it should not be able to.`)}),(0,R.jsx)(Ed,{value:Sd}),(0,R.jsxs)(`a`,{className:bd.ghost,href:Cd,target:`_blank`,rel:`noopener noreferrer`,children:[e(`read it before you run it`),` â`]})]})]}),(0,R.jsx)(`footer`,{className:bd.foot,children:(0,R.jsx)(Rn,{to:`/app/settings`,className:bd.ghost,children:e(`Manage connections in Settings`)})})]})}var Od=`hk460xg0qt`,kd=`/${Od}`,Ad={wall:`_wall_x2ty7_1`,box:`_box_x2ty7_2`,mark:`_mark_x2ty7_5`,note:`_note_x2ty7_7`,input:`_input_x2ty7_8`,go:`_go_x2ty7_14`,err:`_err_x2ty7_20`},jd={name:`Prooven Founder`,domain:`proovenfounder.com`,shortHost:`fndr.page`,liveOrigin:`https://www.meetcrew.app`,contact:`[email protected]`},Md=`#000000`,Nd=`#2D5BFF`,Pd={size:1046,ink:`M68.7 919.0C58.8 916.5 50.0 908.5 44.7 897.2C41.7 890.9 41.5 889.9 41.5 879.0C41.5 864.5 43.3 858.9 49.7 852.6C57.5 844.8 64.7 842.5 84.0 841.5C97.9 840.7 102.0 839.5 104.7 835.4C106.4 832.7 106.5 823.6 106.8 609.3C107.0 406.2 106.9 385.8 105.4 383.5C103.2 380.1 99.4 379.2 83.8 378.1C63.5 376.6 54.0 372.6 47.3 362.6C42.7 355.8 41.5 351.0 41.5 339.0C4
641.5 329.2 41.7 328.0 44.7 322.0C48.7 313.8 55.9 306.5 62.9 303.4C66.1 302.0 75.5 299.7 85.3 297.9C113.0 293.1 127.8 289.5 152.5 281.8C173.6 275.3 190.2 271.0 194.5 271.0C212.2 271.1 227.5 284.4 231.1 303.0C231.8 306.6 232.5 309.7 232.6 309.9C232.8 310.1 235.6 308.6 238.9 306.5C248.5 300.7 272.5 289.5 283.9 285.6C342.0 265.4 412.5 277.9 463.0 317.3C530.7 370.2 562.4 472.6 540.9 569.3C523.5 648.0 459.7 714.9 381.3 737.0C349.7 745.9 306.0 747.7 273.2 741.4C265.1 739.9 244.6 734.0 238.6 731.5C236.7 730.7 234.6 730.0 233.9 730.0C232.4 730.0 233.2 826.0 234.9 831.1C235.5 833.0 237.3 835.9 238.9 837.4C241.8 840.1 242.4 840.3 255.7 841.1C270.8 842.1 276.3 843.1 282.1 846.0C296.7 853.5 303.6 874.4 297.6 893.4C293.6 906.0 288.2 912.3 277.4 917.2C271.3 919.9 267.8 920.0 210.5 918.2C170.4 916.9 143.9 917.2 84.5 919.5C77.9 919.7 70.8 919.5 68.7 919.0ZM338.5 667.0C362.1 659.5 376.9 645.4 389.9 617.9C406.0 584.1 412.9 548.3 411.7 505.0C410.7 470.6 405.0 446.1 391.9 419.7C372.8 381.6 346.1 365.0 303.5 365.0C280.6 365.0 259.3 374.0 239.8 392.0L233.0 398.2L233.0 510.5L233.0 622.9L236.6 629.1C244.8 643.0 262.5 657.8 278.5 663.9C285.4 666.6 288.8 667.5 300.0 669.4C307.4
64670.7 331.7 669.2 338.5 667.0Z`,blue:`M579.2 734.9C569.4 731.0 559.8 718.9 557.1 706.9C554.8 696.9 556.2 681.5 560.3 673.5C567.1 660.0 574.6 656.6 601.1 654.6C627.9 652.5 631.0 650.2 634.1 629.5C635.3 622.1 635.5 586.0 635.5 430.0C635.5 252.2 635.4 238.9 633.7 230.2C631.3 217.3 630.2 215.4 622.4 211.8C616.5 209.0 614.8 208.8 599.6 208.0C578.8 206.9 576.6 206.3 568.1 199.0C560.1 192.1 558.3 188.5 556.7 175.7C554.2 155.8 562.2 136.6 576.0 129.5C583.8 125.5 589.7 124.9 609.0 126.1C619.8 126.8 691.0 127.3 794.5 127.6C909.2 127.9 964.4 128.4 968.5 129.1C984.9 132.1 997.5 144.1 1000.9 159.9C1002.5 167.5 1005.3 297.0 1004.0 303.9C998.8 331.4 960.7 344.5 929.6 329.6C914.3 322.2 910.4 315.5 906.1 289.0C897.1 234.6 887.9 216.8 866.0 211.2C855.7 208.5 846.6 208.0 808.8 208.0L769.0 208.0L769.0 301.5L769.0 394.9L840.8 395.2L912.5 395.5L919.1 398.7C933.3 405.7 940.8 417.5 941.7 434.6C942.6 449.8 939.1 459.9 930.1 468.3C919.6 478.1 925.8 477.5 842.2 477.8L769.0 478.1L769.0 545.3C769.0 629.1 769.8 639.8 776.8 647.4C781.3 652.2 785.2 653.2 804.7 654.5C821.9 655.7 823.2 656.0 829.5 659.1C840.6 664.6 845.8 672.7 848.2 688.7C851.1 708.3 842.6 725.6 826.1 733.7C819.6 736.9 820.8 736.9 743.0 735.4C702.7 734.5 660.7 734.9 608.0 736.4C585.5 737.0 584.3 737.0 579.2 734.9Z`},Fd={width:1660,height:187,ink:`M274.0 177.3C229.5 169.9 212.9 113.8 245.5 81.5C280.8 46.5 338.5 71.1 338.4 121.0C338.3 137.3 333.2 149.8 321.9 161.2C309.3 173.8 290.6 180.1 274.0 177.3ZM388.3 176.5C353.0 168.8 335.2 128.0 352.7 94.7C362.6 76.0 383.9 63.9 404.6 65.3C452.8 68.7 473.7 126.7 439.1 161.0C424.8 175.2 407.2 180.6 388.3 176.5ZM611.0 176.4C568.6 167.3 554.6 110.9 587.0 79.3C605.7 61.0 639.0 60.1 656.3 77.5C664.8 85.9 670.5 102.7 668.1 111.7C665.1 122.8 661.0 124.0 627.2 124.0L601.8 124.0L602.5 129.2C605.0 147.3 614.2 156.1 630.6 156.1C639.7 156.1 645.0 153.4 650.4 145.9C655.4 138.9 658.4 137.3 663.4 139.0C670.5 141.3 672.2 148.7 667.1 155.6C653.9 173.8 633.6 181.3 611.0 176.4ZM501.6 171.1C500.2 167.9 494.0 152.5 487.9 136.9C481.9 121.3 474.7 104.0 472.0 98.4C466.8 87.7 465.9 86.9 457.9 85.6C452.8 84.7 450.7 82.0 450.7 76.3C450.7 72.5 451.1 71.3 453.5 69.2C456.2 66.9 456.9 66.8 467.4 67.2C477.1 67.5 479.2 67.9 484.2 70.3C494.8 75.5 497.9 80.4 510.5 112.3C514.8 123.1 518.7 131.7 519.0 131.3C519.4 130.8 523.1 121.3 527.3 110.0C531.5 98.7 535.2 88.7 535.5 87.8C536.1 86.3 535.7 86.0 533.2 86.0C525.3 86.0 520.8 80.3 523.0 73.4C525.0 67.4 526.1 67.2 550.0 67.2C561.8 67.3 572.3 67.7 573.2 68.2C576.1 69.6 578.3 74.8 577.6 78.5C576.7 83.1 574.0 85.1 567.3 85.9C560.0 86.8 557.7 88.1 555.7 92.2C552.9 98.4 532.9 148.1 528.4 160.3C522.6 176.2 521.8 177.0 512.0 177.0L504.3 177.0L501.6 171.1ZM11.8 172.9C8.1 169.3 7.9 163.3 11.3 159.4C13.1 157.3 14.7 156.6 19.1 156.2C28.7 155.4 28.0 159.6 28.0 102.6C28.0 74.6 27.6 51.9 27.1 51.1C26.5 50.2 23.5 49.3 19.9 48.9C12.1 48.0 9.0 45.2 9.0 38.9C9.0 35.7 9.7 34.2 12.0 31.8L15.1 28.8L51.8 29.3C87.4 29.7 88.8 29.8 98.5 32.4C122.6 38.7 132.8 49.0 134.6 68.8C136.7 91.3 121.7 111.3 96.4 119.6C88.8 122.1 85.9 122.5 76.5 122.5C70.4 122.5 64.2 122.1 62.7 121.7L59.8 120.9L60.2 137.0C60.5 155.5 60.8 156.0 69.0 156.0C71.5 156.0 74.5 156.7 75.7 157.5C78.1 159.2 80.2 165.1 79.3 167.8C78.2 171.4 76.6 173.9 75.1 174.6C74.2 175.0 60.2 175.4 44.0 175.5L14.5 175.6L11.8 172.9ZM141.2 174.7C136.7 172.7 135.3 164.3 138.8 160.0C140.0 158.5 142.1 157.6 146.0 157.2C150.7 156.6 151.5 156.2 152.1 154.0C153.0 150.9 153.2 98.8 152.4 93.8C151.9 90.7 151.3 90.0 149.5 90.0C141.1 90.0 137.0 86.9 137.0 80.6C137.0 73.6 138.8 72.3 151.5 69.5C157.6 68.2 164.5 66.5 166.9 65.6C173.3 63.3 176.7 63.6 179.5 66.6C180.9 68.1 182.0 70.3 182.0 71.5C182.0 75.0 182.8 75.0 188.8 71.4C198.4 65.6 206.4 63.9 213.1 66.2C234.6 73.5 231.1 108.0 208.9 108.0C198.5 108.0 193.1 102.0 197.6 95.4C203.5 86.8 196.2 86.9 185.2 95.7L183.0 97.5L183.2 127.0L183.5 156.5L188.7 157.0C195.7 157.7 198.5 160.4 198.5 166.5C198.5 169.8 197.9 171.5 196.2 173.2C194.0 175.5 193.6 175.5 168.6 175.5C154.6 175.5 142.3 175.2 141.2 174.7ZM679.5 174.8C676.9 173.3 674.8 168.0 675.4 164.5C676.3 160.0 679.0 157.9 685.2 157.1L690.5 156.5L690.5 123.5L690.5 90.5L688.0 90.2C678.5 89.2 674.2 85.2 675.4 78.4C676.3 73.7 679.9 71.4 688.1 70.0C692.0 69.3 698.6 67.7 702.7 66.4C706.9 65.1 711.4 64.0 712.7 64.0C716.0 64.0 721.0 69.1 721.0 72.4C721.0 75.6 721.0 75.6 726.2 72.1C734.0 67.0 739.5 65.5 751.0 65.5C760.9 65.5 762.0 65.7 768.2 68.8C775.9 72.6 781.2 78.0 784.9 85.9L787.5 91.5L787.8 123.0C788.0 143.2 788.5 154.9 789.2 155.7C789.8 156.4 791.7 157.0 793.6 157.0C802.8 157.0 807.4 166.0 801.6 172.7L799.2 175.5L773.4 175.5L747.5 175.6L744.8 172.9C738.4 166.6 743.0 157.0 752.3 157.0C758.0 157.0 758.0 157.1 758.0 126.5C758.0 101.3 757.8 98.1 756.2 95.1C750.9 85.2 732.9 85.5 724.0 95.6L721.0 99.1L721.1 123.8C721.1 137.4 721.4 150.3 721.8 152.5C722.5 156.5 722.6 156.5 727.9 157.2C730.8 157.5 733.9 158.4 734.6 159.2C738.4 162.9 737.8 171.9 733.7 174.2C731.1 175.7 682.0 176.2 679.5 174.8ZM292.9 156.9C300.7 152.6 305.0 141.7 305.7 124.5C306.6 105.3 302.1 91.5 293.4 86.4C287.8 83.1 276.9 83.2 272.3 86.6C260.0 95.6 256.9 131.7 266.9 149.5C272.0 158.6 283.9 162.0 292.9 156.9ZM412.4 155.7C426.1 145.2 427.6 103.1 414.7 89.1C410.1 84.2 398.3 82.2 392.1 85.5C373.5 95.1 373.8 149.0 392.5 157.6C397.6 160.0 408.0 159.0 412.4 155.7ZM636.8 101.1C638.0 89.0 628.8 80.6 617.9 83.9C610.8 86.0 605.7 92.0 603.2 101.3L602.1 105.0L619.3 104.8L636.5 104.5L636.8 101.1ZM81.8 100.4C85.8 99.3 88.5 97.6 92.5 93.7C99.0 87.4 100.4 83.0 99.8 71.4C99.2 59.1 96.0 55.0 84.5 50.9C77.8 48.5 64.3 47.3 62.0 48.9C60.7 49.8 60.5 54.2
6460.2 75.9L59.9 101.9L64.2 102.2C69.9 102.7 75.3 102.2 81.8 100.4Z`,blue:`M999.3 176.6C969.5 169.8 951.1 138.3 959.0 107.6C961.8 96.7 965.3 90.7 974.0 81.9C988.7 67.1 1006.7 61.9 1026.4 67.0C1046.2 72.0 1061.7 88.1 1066.0 108.1C1067.8 116.2 1066.8 132.9 1064.1 140.5C1054.8 166.5 1025.8 182.6 999.3 176.6ZM1111.2 176.5C1102.2 174.0 1096.5 170.1 1091.9 163.3C1085.9 154.6 1085.6 153.1 1085.0 121.5L1084.5 92.5L1079.0 91.8C1072.4 91.0 1069.0 87.8 1069.0 82.5C1069.0 76.5 1072.2 74.1 1083.1 71.9C1088.3 70.9 1095.2 69.1 1098.5 68.0C1106.0 65.4 1108.3 65.5 1111.7 68.4L1114.5 70.8L1115.0 108.2C1115.5 142.0 1115.7 145.9 1117.3 148.3C1120.3 152.8 1124.8 155.0 1131.3 155.0C1138.3 155.0 1142.5 153.4 1147.9 148.5L1152.0 144.8L1152.0 119.6C1152.0 105.8 1151.6 94.0 1151.2 93.4C1150.8 92.8 1148.3 92.1 1145.7 91.8C1139.1 91.0 1136.0 88.0 1136.0 82.5C1136.0 76.3 1138.8 74.2 1150.2 71.9C1155.3 70.8 1162.1 69.1 1165.3 68.0C1172.7 65.4 1175.3 65.5 1178.7 68.4L1181.5 70.8L1182.0 112.7C1182.3 135.7 1182.7 154.6 1182.8 154.7C1184.2 155.6 1190.1 157.0 1193.0 157.0C1195.3 157.0 1197.4 157.8 1198.9 159.1C1201.0 161.1 1201.2 161.1 1203.0 159.5C1204.0 158.6 1207.3 157.5 1210.2 157.1L1215.5 156.5L1215.5 123.5L1215.5 90.5L1213.0 90.2C1203.5 89.2 1199.2 85.2 1200.4 78.4C1201.3 73.7 1204.9 71.4 1213.1 70.0C1217.0 69.3 1223.6 67.7 1227.7 66.4C1231.9 65.1 1236.3 64.0 1237.6 64.0C1240.8 64.0 1245.0 67.9 1245.8 71.8L1246.5 75.0L1251.0 72.0C1258.5 67.0 1264.3 65.5 1276.0 65.5C1285.3 65.5 1287.2 65.8 1292.1 68.1C1300.0 71.8 1305.4 77.1 1309.2 84.8L1312.5 91.5L1312.8 123.0C1313.0 143.1 1313.5 154.9 1314.2 155.7C1314.8 156.4 1316.7 157.0 1318.6 157.0C1328.0 157.0 1332.6 166.5 1326.2 172.9L1323.5 175.6L1297.7 175.6L1271.8 175.5L1269.4 172.7C1263.6 166.0 1268.2 157.0 1277.4 157.0C1279.3 157.0 1281.3 156.4 1281.9 155.6C1283.7 153.4 1283.0 97.2 1281.2 94.5C1278.3 90.3 1274.7 88.5 1267.8 88.2C1259.8 87.7 1253.9 90.1 1249.0 95.6L1246.0 99.1L1246.1 123.3C1246.1 136.6 1246.5 149.5 1246.8 152.0L1247.5 156.5L1252.9 157.2C1255.8 157.5 1258.9 158.4 1259.6 159.2C1261.7 161.3 1262.8 166.1 1261.8 169.6C1260.3 175.5 1259.2 175.7 1230.6 175.6C1205.6 175.5 1204.7 175.4 1203.1 173.4C1201.5 171.3 1201.5 171.3 1198.9 173.2C1196.8 174.8 1193.0 175.4 1176.9 176.5C1158.4 177.9 1157.4 177.9 1155.0 176.1C1153.5 175.0 1152.4 173.1 1152.2 171.2L1151.9 168.1L1148.1 170.6C1138.4 177.0 1122.2 179.6 1111.2 176.5ZM1368.3 176.5C1329.5 166.0 1316.3 111.6 1345.3 82.0C1355.3 71.7 1366.5 66.4 1380.1 65.3C1386.8 64.8 1398.2 66.0 1402.5 67.6C1403.8 68.1 1404.0 66.0 1404.0 51.7L1404.0 35.2L1400.9 34.6C1399.2 34.3 1396.8 34.0 1395.5 34.0C1392.0 34.0 1388.5 29.5 1388.5 25.0C1388.5 18.8 1391.5 16.5 1401.9 14.6C1406.6 13.8 1413.2 12.1 1416.4 11.0C1426.4 7.6 1431.1 8.6 1433.6 14.5C1434.8 17.4 1435.0 29.5 1435.0 85.8C1435.0 163.2 1434.1 156.4 1444.2 157.6C1452.5 158.6 1456.8 163.7 1454.2 169.5C1452.0 174.3 1449.1 175.2 1429.4 176.6C1409.3 178.0 1406.4 177.6 1405.4 173.3C1404.7 170.5 1404.1 170.5 1399.1 173.1C1389.9 177.9 1378.3 179.2 1368.3 176.5ZM1495.0 176.5C1470.0 170.8 1454.0 149.3 1454.0 121.5C1454.0 89.9 1477.2 65.0 1506.5 65.0C1529.5 65.0 1545.0 75.5 1551.1 95.1C1555.1 107.8 1553.0 116.8 1545.0 121.4C1541.7 123.4 1539.6 123.5 1514.2 123.8L1487.0 124.1L1487.0 127.5C1487.0 133.5 1490.9 143.9 1494.8 148.2C1500.0 154.0 1504.9 156.0 1514.0 156.0C1523.5 156.0 1528.3 153.9 1533.6 147.5C1541.5 137.9 1541.8 137.7 1545.7 138.3C1550.0 139.0 1553.7 142.2 1554.5 146.0C1556.3 154.3 1541.3 169.8 1526.2 175.1C1518.6 177.8 1503.7 178.5 1495.0 176.5ZM857.0 174.3C853.8 172.0 852.5 166.1 854.4 161.7C856.1 157.6 859.0 156.0 864.8 156.0C869.9 156.0 871.1 154.9 872.1 149.9C873.2 144.2 873.2 60.8 872.1 55.2C871.0 49.7 871.1 49.8 863.9 48.9C854.9 47.9 851.9 43.7 854.1 35.6C856.0 28.7 854.5 28.9 906.6 29.2C943.4 29.4 954.0 29.8 955.8 30.8C960.1 33.3 961.0 37.5 961.0 56.3C961.0 73.1 960.9 73.7 958.7 75.8C955.1 79.2 950.8 80.3 946.1 79.0C940.7 77.6 938.5 74.5 937.1 66.0C935.7 57.3 932.8 51.2 929.4 50.0C928.0 49.4 921.9 49.0 915.9 49.0L905.0 49.0L905.0 71.5L905.0 94.0L922.9 94.0L940.8 94.0L943.4 97.1C946.9 101.2 946.9 106.8 943.6 110.7L941.2 113.5L923.1 113.8L905.0 114.1L905.0 133.4C905.0 155.6 905.2 156.0 913.2 156.0C918.9 156.0 922.7 158.8 923.6 163.6C924.3 167.3 922.8 172.1 920.2 174.2C917.9 176.2 859.8 176.2 857.0 174.3ZM1562.6 173.3C1559.8 170.5 1559.1 167.6 1560.2 163.4C1561.3 159.1 1563.1 157.9 1569.2 157.1C1574.1 156.6 1574.5 156.3 1575.1 153.5C1576.0 149.5 1576.2 100.6 1575.4 94.6C1574.8 90.2 1574.6 90.0 1571.5 90.0C1563.5 90.0 1560.0 87.0 1560.0 80.2C1560.0 73.7 1562.0 72.2 1574.5 69.5C1580.6 68.2 1587.5 66.5 1589.9 65.6C1598.4 62.5 1603.2 64.2 1605.0 71.1C1606.0 74.8 1606.3 75.1 1607.8 73.8C1613.7 68.8 1626.0 64.5 1632.0 65.3C1641.3 66.5 1648.0 73.0 1650.0 82.7C1652.8 96.2 1644.5 108.1 1632.1 108.2C1621.6 108.2 1616.1 102.1 1620.6 95.4C1626.5 86.8 1619.2 86.9 1608.2 95.7L1606.0 97.5L1606.2 127.0L1606.5 156.5L1611.7 157.0C1618.7 157.7 1621.5 160.4 1621.5 166.5C1621.5 169.8 1620.9 171.5 1619.2 173.2C1617.0 175.5 1616.6 175.5 1590.9 175.6C1564.9 175.6 1564.9 175.6 1562.6 173.3ZM1022.7 156.4C1030.5 150.6 1034.5 138.8 1034.5 121.0C1034.5 94.9 1026.5 83.0 1009.9 84.2C998.1 85.1 991.7 94.7 990.2 114.0C988.4 135.9 993.4 152.4 1003.1 157.3C1007.9 159.8 1018.9 159.2 1022.7 156.4ZM1399.8 152.6L1404.0 149.7L1404.0 121.9L1404.0 94.1L1400.9 90.5C1392.2 80.7 1377.9 81.6 1370.2 92.4C1359.2 108.1 1359.6 136.4 1371.1 149.4C1375.8 154.9 1379.1 156.1 1388.1 155.8C1394.6 155.5 1396.3 155.1 1399.8 152.6ZM1520.8 103.8C1523.9 100.7 1520.2 89.6 1514.7 85.6C1510.4 82.4 1502.4 82.8 1497.0 86.4C1492.9 89.1 1489.1 95.3 1487.5 102.2L1486.8 105.0L1503.2 105.0C1514.6 105.0 1520.0 104.6 1520.8 103.8Z`};
64function Id(e,t,n){return`<g transform="translate(${e} ${t}) scale(${(n/Pd.size).toFixed(5)})"><path fill="${Md}" fill-rule="evenodd" d="${Pd.ink}"/><path fill="${Nd}" fill-rule="evenodd" d="${Pd.blue}"/></g>`}function Ld({size:e=24,className:t}){return(0,R.jsxs)(`svg`,{className:t,width:e,height:e,viewBox:`0 0 ${Pd.size} ${Pd.size}`,role:`img`,"aria-label":jd.name,focusable:`false`,style:{display:`block`,flex:`none`},children:[(0,R.jsx)(`path`,{fill:Md,fillRule:`evenodd`,d:Pd.ink}),(0,R.jsx)(`path`,{fill:Nd,fillRule:`evenodd`,d:Pd.blue})]})}function Rd({height:e=26,className:t}){return(0,R.jsxs)(`svg`,{className:t,height:e,width:Math.round(e*Fd.width/Fd.height),viewBox:`0 0 ${Fd.width} ${Fd.height}`,role:`img`,"aria-label":jd.name,focusable:`false`,style:{display:`block`,flex:`none`},children:[(0,R.jsx)(`path`,{fill:Md,fillRule:`evenodd`,d:Fd.ink}),(0,R.jsx)(`path`,{fill:Nd,fillRule:`evenodd`,d:Fd.blue})]})}function zd({variant:e=`icon`,className:t}){return e===`wordmark`?(0,R.jsx)(Rd,{className:t,height:26}):(0,R.jsx)(Ld,{className:t,size:28})}var Bd=`/api/nc-gate`;function Vd({children:e}){let[t,n]=(0,_.useState)(`checking`),[r,i]=(0,_.useState)(``),[a,o]=(0,_.useState)(``),[s,c]=(0,_.useState)(!1);(0,_.useEffect)(()=>{fetch(Bd,{credentials:`include`}).then(e=>e.json()).then(e=>n(e.ok?`open`:`locked`)).catch(()=>n(`locked`))},[]),(0,_.useEffect)(()=>{let e=document.createElement(`meta`);e.name=`robots`,e.content=`noindex,nofollow`,document.head.appendChild(e);let t=document.querySelector(`link[rel="icon"]`),n=t?.getAttribute(`href`)??null;return t?.setAttribute(`href`,`data:image/svg+xml,${encodeURIComponent(`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 ${Pd.size} ${Pd.size}"><path fill="${Md}" fill-rule="evenodd" d="${Pd.ink}"/><path fill="${Nd}" fill-rule="evenodd" d="${Pd.blue}"/></svg>`)}`),()=>{e.remove(),t&&n&&t.setAttribute(`href`,n)}},[]);async function l(e){e.preventDefault(),c(!0),o(``);try{let e=await(await fetch(Bd,{method:`POST`,credentials:`include`,headers:{"Content-Type":`application/json`},body:JSON.stringify({password:r})})).json().catch(()=>({}));if(e.ok){n(`open`);return}o(e.error===`gate not configured`?`the gate has no password set on the server yet.`:`wrong password.`)}catch{o(`could not reach the gate.`)}finally{c(!1)}}return t===`checking`?(0,R.jsx)(`div`,{className:`nc ${Ad.wall}`}):t===`open`?(0,R.jsx)(R.Fragment,{children:e}):(0,R.jsx)(`div`,{className:`nc ${Ad.wall}`,children:(0,R.jsxs)(`form`,{className:Ad.box,onSubmit:l,children:[(0,R.jsx)(`span`,{className:Ad.mark,children:(0,R.jsx)(Ld,{size:34})}),(0,R.jsx)(`p`,{className:Ad.note,children:`not public yet.`}),(0,R.jsx)(`input`,{className:Ad.input,type:`password`,value:r,autoFocus:!0,onChange:e=>i(e.target.value),placeholder:`password`,"aria-label":`password`}),(0,R.jsx)(`button`,{className:Ad.go,disabled:s||!r,children:s?`â¦`:`enter`}),a&&(0,R.jsx)(`p`,{className:Ad.err,children:a})]})})}async function Hd(e){let{data:t,error:n}=await L.rpc(`get_share_card`,{p_token:e});return{data:Array.isArray(t)?t[0]??null:t??null,error:n}}function Ud(e){let t=rf(),n=new Map;for(let r of e){if(r.date>t)continue;let e=n.get(r.date);e||(e={date:r.date,priorities:[]},n.set(r.date,e)),e.priorities.push({id:r.id,text:r.text,category:r.category,status:r.status,proof:r.proof??``,resolution:r.resolution??null,resolvedLate:r.resolved_late??!1,unplanned:r.unplanned??!1,parentId:r.parent_id??null,carryCount:r.carry_count??0,receiptKind:r.receipt_kind??null,planWhen:r.plan_when??null,actor:r.actor??`user`})}return[...n.values()].sort((e,t)=>e.date.localeCompare(t.date))}async function Wd(e,t,n){let r=L.from(`priorities`).select(`*`).eq(`user_id`,e).order(`date`,{ascending:!0});return t&&(r=n?r.or(`workspace_id.eq.${t},workspace_id.is.null`):r.eq(`workspace_id`,t)),r}async function Gd(e,t,n,r){let i=L.from(`priorities`).select(`*`).eq(`user_id`,e).eq(`date`,t).order(`created_at`,{ascending:!0});return n&&(i=r?i.or(`workspace_id.eq.${n},workspace_id.is.null`):i.eq(`workspace_id`,n)),i}async function Kd(e,t,n,r,i=`pending`){let a=[];for(let o of n){let n=o.parentId??null;if(o.parentTitle?.trim()){let{data:t}=await L.from(`task_parents`).insert({user_id:e,workspace_id:r??null,title:o.parentTitle.trim(),category:o.category}).select(`id`).single();n=t?.id??null}else if(!n&&o.carrySourceId){let{data:t}=await L.from(`task_parents`).insert({user_id:e,workspace_id:r??null,title:o.text.trim(),category:o.category}).select(`id`).maybeSingle();
64n=t?.id??null,n&&await L.from(`priorities`).update({parent_id:n}).eq(`id`,o.carrySourceId).eq(`user_id`,e)}a.push({user_id:e,date:t,text:o.text,category:o.category,status:i,workspace_id:r??null,parent_id:n,carry_count:o.carryCount??0,receipt_kind:o.receiptKind??null,plan_when:o.planWhen?.trim()?o.planWhen.trim().slice(0,60):null})}return L.from(`priorities`).insert(a).select()}async function qd(e){let t=[...new Set(e.filter(Boolean))];if(t.length===0)return{};let{data:n}=await L.from(`task_parents`).select(`id, title`).in(`id`,t),r={};for(let e of n??[])r[e.id]=e.title;return r}async function Jd(e,t,n){return L.from(`priorities`).update(n===void 0?{status:t}:{status:t,proof:n}).eq(`id`,e)}async function Yd(e,t){return L.from(`priorities`).update({started_at:t?new Date().toISOString():null}).eq(`id`,e)}async function Xd(e,t){return L.from(`priorities`).update({text:t}).eq(`id`,e)}var Zd=`day_already_counted`;async function Qd(e){let{data:t}=await L.from(`priorities`).select(`date`).eq(`id`,e).maybeSingle(),n=t?.date;if(n&&n<rf())return{error:{message:Zd}};let{error:r}=await L.from(`priorities`).delete().eq(`id`,e);return{error:r?{message:r.message}:null}}async function $d(e,t){let{data:n}=await L.from(`priorities`).select(`carry_count, date`).eq(`id`,e).maybeSingle(),r=n,i=rf();if(r?.date&&r.date<i||t<i)return{error:{message:Zd}};let a=(r?.carry_count??0)+1,{error:o}=await L.from(`priorities`).update({date:t,status:`pending`,carry_count:a}).eq(`id`,e);return{error:o?{message:o.message}:null}}async function ef(e,t){let{count:n}=await L.from(`task_changes`).select(`id`,{count:`exact`,head:!0}).eq(`user_id`,e).eq(`date`,t);return n??0}async function tf(e,t){if(await L.from(`task_changes`).insert({user_id:t.userId,workspace_id:t.workspaceId??null,date:e.date,kind:t.kind,from_text:e.text,to_text:t.kind===`swap`?t.newText??null:null,reason:t.reason}),t.overCap){await L.from(`priorities`).update({status:`skipped`}).eq(`id`,e.id);return}t.kind===`swap`&&t.newText?.trim()?await L.from(`priorities`).update({text:t.newText.trim(),carry_count:0}).eq(`id`,e.id):e.date<rf()?await L.from(`priorities`).update({status:`skipped`}).eq(`id`,e.id):await L.from(`priorities`).delete().eq(`id`,e.id)}function nf(e,t,n){let[r,i]=(0,_.useState)([]),[a,o]=(0,_.useState)(!0),s=(0,_.useCallback)(async()=>{if(!e){i([]),o(!1);return}o(!0);let{data:r}=await Wd(e,t,n);i(Ud(r??[])),o(!1)},[e,t,n]);return(0,_.useEffect)(()=>{s()},[s]),{entries:r,loading:a,refresh:s}}function rf(){return new Date().toLocaleDateString(`en-CA`)}var af=[{id:`aurora`,label:`aurora`},{id:`sunset`,label:`sunset`},{id:`light`,label:`light`}];function of(e){return`https://zwqymcoehifdzniztfzc.supabase.co/functions/v1/avatar?u=${encodeURIComponent(e)}`}async function sf(e,t){let n=t.kind===`weekly`?t.week_start:rf(),{data:r,error:i}=await L.from(`share_cards`).insert({user_id:e,week_start:n,data:t}).select(`token`).single();return{token:r?.token??null,error:i}}var cf={card:`_card_auren_5`,aurora:`_aurora_auren_24`,sunset:`_sunset_auren_37`,light:`_light_auren_50`,glow:`_glow_auren_64`,brand:`_brand_auren_75`,liveBadge:`_liveBadge_auren_85`,liveBadgeDot:`_liveBadgeDot_auren_103`,hero:`_hero_auren_110`,heroNum:`_heroNum_auren_111`,heroSign:`_heroSign_auren_122`,flame:`_flame_auren_123`,heroLabel:`_heroLabel_auren_124`,subject:`_subject_auren_133`,subjectCenter:`_subjectCenter_auren_134`,subjectText:`_subjectText_auren_135`,subjectLead:`_subjectLead_auren_136`,subjectName:`_subjectName_auren_143`,subjectTag:`_subjectTag_auren_144`,plantWrap:`_plantWrap_auren_147`,meaning:`_meaning_auren_148`,avatar:`_avatar_auren_157`,avatarImg:`_avatarImg_auren_170`,avatarEmoji:`_avatarEmoji_auren_171`,track:`_track_auren_174`,fill:`_fill_auren_182`,gapHint:`_gapHint_auren_190`,footer:`_footer_auren_201`,weeklyHead:`_weeklyHead_auren_210`,weeklyPill:`_weeklyPill_auren_211`,weeklyId:`_weeklyId_auren_221`,weeklyName:`_weeklyName_auren_222`,weeklyProduct:`_weeklyProduct_auren_223`,weeklyPeriod:`_weeklyPeriod_auren_224`,weeklyStats:`_weeklyStats_auren_232`,weeklyStat:`_weeklyStat_auren_232`,weeklyStatNum:`_weeklyStatNum_auren_234`,weeklyStatLabel:`_weeklyStatLabel_auren_243`,weeklyDivider:`_weeklyDivider_auren_244`,weeklyList:`_weeklyList_auren_245`,weeklyListLabel:`_weeklyListLabel_auren_246`,weeklyItem:`_weeklyItem_auren_247`,weeklyDot:`_weeklyDot_auren_248`};function lf(e){return e===`light`?cf.light:e===`sunset`?cf.sunset:cf.aurora}function uf({photo:e,emoji:t,name:n}){let[r,i]=(0,_.useState)(!1),a=!!e&&!r;return(0,R.jsx)(`span`,{className:cf.avatar,children:a?(0,R.jsx)(`img`,{className:cf.avatarImg,src:of(e),alt:n,crossOrigin:`anonymous`,onError:()=>i(!0)}
64):(0,R.jsx)(`span`,{className:cf.avatarEmoji,"aria-hidden":!0,children:t??`ð`})})}function df(){return(0,R.jsx)(`span`,{className:cf.brand,children:`CREW`})}function ff({on:e}){let t=z();return e?(0,R.jsxs)(`span`,{className:cf.liveBadge,children:[(0,R.jsx)(`span`,{className:cf.liveBadgeDot,"aria-hidden":!0}),t(`LIVE`)]}):null}function pf(){let e=z();return(0,R.jsx)(`span`,{className:cf.footer,children:e(`meetcrew.app · accountability for founders`)})}function mf({data:e}){let t=z(),n=Math.max(0,Math.min(100,Math.round(e.pct)));return(0,R.jsxs)(`div`,{className:`${cf.card} ${lf(e.design)}`,children:[(0,R.jsx)(`div`,{className:cf.glow,"aria-hidden":!0}),(0,R.jsx)(ff,{on:e.live}),(0,R.jsx)(df,{}),(0,R.jsxs)(`div`,{className:cf.hero,children:[(0,R.jsxs)(`span`,{className:cf.heroNum,children:[n,(0,R.jsx)(`span`,{className:cf.heroSign,children:`%`})]}),(0,R.jsx)(`span`,{className:cf.heroLabel,children:e.periodLabel??t(`all-time follow-through`)})]}),(0,R.jsxs)(`div`,{className:cf.subject,children:[(0,R.jsx)(uf,{photo:e.founderPhoto,emoji:e.founderEmoji,name:e.founderName}),(0,R.jsxs)(`div`,{className:cf.subjectText,children:[(0,R.jsx)(`span`,{className:cf.subjectLead,children:e.generic?t(`current mode`):e.modeName??t(`building like`)}),(0,R.jsx)(`span`,{className:cf.subjectName,children:e.generic?e.modeName??e.founderName:e.founderName}),(0,R.jsx)(`span`,{className:cf.subjectTag,children:e.founderTag})]})]}),(0,R.jsx)(`div`,{className:cf.track,children:(0,R.jsx)(`div`,{className:cf.fill,style:{width:`${n}%`}})}),e.gapHint&&(0,R.jsx)(`span`,{className:cf.gapHint,children:e.gapHint}),(0,R.jsx)(pf,{})]})}function hf({data:e}){let t=z(),n=Math.max(0,Math.round(e.streak)),r=Math.max(0,Math.round(e.best)),i=n>0&&n>=r;return(0,R.jsxs)(`div`,{className:`${cf.card} ${lf(e.design)}`,children:[(0,R.jsx)(`div`,{className:cf.glow,"aria-hidden":!0}),(0,R.jsx)(ff,{on:e.live}),(0,R.jsx)(df,{}),(0,R.jsx)(`div`,{className:cf.plantWrap,children:(0,R.jsx)(Hu,{streak:n,longestStreak:r,size:128,showCaption:!1})}),(0,R.jsxs)(`div`,{className:cf.hero,children:[(0,R.jsxs)(`span`,{className:cf.heroNum,children:[(0,R.jsx)(`span`,{className:cf.flame,"aria-hidden":!0,children:`ð¥`}),n]}),(0,R.jsx)(`span`,{className:cf.heroLabel,children:t(`days locked in a row`)})]}),(0,R.jsxs)(`p`,{className:cf.meaning,children:[t(`every day I lock in my priorities and ship them, the plant grows.`),` `,t(n===0?`one lost day resets it to a seed.`:`miss a day and it wilts.`)]}),(0,R.jsx)(`span`,{className:cf.subjectTag,children:i?t(`personal best, right now`):r>0?`${t(`best ever`)} · ${r} ${t(r===1?`day`:`days`)}`:t(`lock today to plant it`)}),(0,R.jsx)(`div`,{className:cf.track,children:(0,R.jsx)(`div`,{className:cf.fill,style:{width:`${r>0?Math.min(100,Math.round(n/r*100)):n>0?100:4}%`}})}),(0,R.jsx)(pf,{})]})}function gf({data:e}){let t=z(),n=Math.max(0,Math.min(100,Math.round(e.completion_pct))),r=e=>new Date(e+`T12:00:00Z`).toLocaleDateString(`en-US`,{month:`short`,day:`numeric`,timeZone:`UTC`});return(0,R.jsxs)(`div`,{className:`${cf.card} ${lf(e.design)}`,children:[(0,R.jsx)(`div`,{className:cf.glow,"aria-hidden":!0}),(0,R.jsx)(ff,{on:e.live}),(0,R.jsxs)(`div`,{className:cf.weeklyHead,children:[(0,R.jsx)(df,{}),(0,R.jsx)(`span`,{className:cf.weeklyPill,children:t(`weekly receipt`)})]}),(e.name||e.product)&&(0,R.jsxs)(`div`,{className:cf.weeklyId,children:[e.name&&(0,R.jsx)(`span`,{className:cf.weeklyName,children:e.name}),e.product&&(0,R.jsx)(`span`,{className:cf.weeklyProduct,children:e.product})]}),(0,R.jsxs)(`span`,{className:cf.weeklyPeriod,children:[r(e.week_start),` â `,r(e.week_end)]}),(0,R.jsxs)(`div`,{className:cf.weeklyStats,children:[(0,R.jsxs)(`div`,{className:cf.weeklyStat,children:[(0,R.jsxs)(`span`,{className:cf.weeklyStatNum,children:[n,(0,R.jsx)(`span`,{className:cf.heroSign,children:`%`})]}),(0,R.jsx)(`span`,{className:cf.weeklyStatLabel,children:t(`completed`)})]}),(0,R.jsx)(`div`,{className:cf.weeklyDivider}),(0,R.jsxs)(`div`,{className:cf.weeklyStat,children:[(0,R.jsx)(`span`,{className:cf.weeklyStatNum,children:Math.max(0,Math.round(e.streak))}),(0,R.jsx)(`span`,{className:cf.weeklyStatLabel,children:t(`day streak`)})]}),(0,R.jsx)(`div`,{className:cf.weeklyDivider}),(0,R.jsxs)(`div`,{className:cf.weeklyStat,children:[(0,R.jsx)(`span`,{className:cf.weeklyStatNum,children:e.shipped.length}),(0,R.jsx)(`span`,{className:cf.weeklyStatLabel,children:t(`shipped`)})]})]}),e.shipped.length>0&&(0,R.jsxs)(`div`,{className:cf.weeklyList,children:[(0,R.jsx)(`span`,{className:cf.weeklyListLabel,children:t(`shipped this week`)}),e.shipped.slice(0,4).map((e,t)=>(0,R.jsxs)(`span`,{className:cf.weeklyItem,children:[(0,R.jsx)(`span`,{className:cf.weeklyDot,"aria-hidden":!0}),e]},t))]}
vendor: 5,304 bytes, line 64
64),(0,R.jsx)(`div`,{className:cf.track,children:(0,R.jsx)(`div`,{className:cf.fill,style:{width:`${n}%`}})}),(0,R.jsx)(pf,{})]})}function _f(e,t){if(e.match(/^[a-z]+:\/\//i))return e;if(e.match(/^\/\//))return window.location.protocol+e;if(e.match(/^[a-z]+:/i))return e;let n=document.implementation.createHTMLDocument(),r=n.createElement(`base`),i=n.createElement(`a`);return n.head.appendChild(r),n.body.appendChild(i),t&&(r.href=t),i.href=e,i.href}var vf=(()=>{let e=0,t=()=>`0000${(Math.random()*36**4<<0).toString(36)}`.slice(-4);return()=>(e+=1,`u${t()}${e}`)})();function yf(e){let t=[];for(let n=0,r=e.length;n<r;n++)t.push(e[n]);return t}var bf=null;function xf(e={}){return bf||(e.includeStyleProperties?(bf=e.includeStyleProperties,bf):(bf=yf(window.getComputedStyle(document.documentElement)),bf))}function Sf(e,t){let n=(e.ownerDocument.defaultView||window).getComputedStyle(e).getPropertyValue(t);return n?parseFloat(n.replace(`px`,``)):0}function Cf(e){let t=Sf(e,`border-left-width`),n=Sf(e,`border-right-width`);return e.clientWidth+t+n}function wf(e){let t=Sf(e,`border-top-width`),n=Sf(e,`border-bottom-width`);return e.clientHeight+t+n}function Tf(e,t={}){return{width:t.width||Cf(e),height:t.height||wf(e)}}function Ef(){let e,t;try{t=process}catch{}let n=t&&t.env?t.env.devicePixelRatio:null;return n&&(e=parseInt(n,10),Number.isNaN(e)&&(e=1)),e||window.devicePixelRatio||1}var Df=16384;function Of(e){(e.width>Df||e.height>Df)&&(e.width>Df&&e.height>Df?e.width>e.height?(e.height*=Df/e.width,e.width=Df):(e.width*=Df/e.height,e.height=Df):e.width>Df?(e.height*=Df/e.width,e.width=Df):(e.width*=Df/e.height,e.height=Df))}function kf(e){return new Promise((t,n)=>{let r=new Image;r.onload=()=>{r.decode().then(()=>{requestAnimationFrame(()=>t(r))})},r.onerror=n,r.crossOrigin=`anonymous`,r.decoding=`async`,r.src=e})}async function Af(e){return Promise.resolve().then(()=>new XMLSerializer().serializeToString(e)).then(encodeURIComponent).then(e=>`data:image/svg+xml;charset=utf-8,${e}`)}async function jf(e,t,n){let r=`http://www.w3.org/2000/svg`,i=document.createElementNS(r,`svg`),a=document.createElementNS(r,`foreignObject`);return i.setAttribute(`width`,`${t}`),i.setAttribute(`height`,`${n}`),i.setAttribute(`viewBox`,`0 0 ${t} ${n}`),a.setAttribute(`width`,`100%`),a.setAttribute(`height`,`100%`),a.setAttribute(`x`,`0`),a.setAttribute(`y`,`0`),a.setAttribute(`externalResourcesRequired`,`true`),i.appendChild(a),a.appendChild(e),Af(i)}var Mf=(e,t)=>{if(e instanceof t)return!0;let n=Object.getPrototypeOf(e);return n===null?!1:n.constructor.name===t.name||Mf(n,t)};function Nf(e){let t=e.getPropertyValue(`content`);return`${e.cssText} content: '${t.replace(/'|"/g,``)}';`}function Pf(e,t){return xf(t).map(t=>`${t}: ${e.getPropertyValue(t)}${e.getPropertyPriority(t)?` !important`:``};`).join(` `)}function Ff(e,t,n,r){let i=`.${e}:${t}`,a=n.cssText?Nf(n):Pf(n,r);return document.createTextNode(`${i}{${a}}`)}function If(e,t,n,r){let i=window.getComputedStyle(e,n),a=i.getPropertyValue(`content`);if(a===``||a===`none`)return;let o=vf();try{t.className=`${t.className} ${o}`}catch{return}let s=document.createElement(`style`);s.appendChild(Ff(o,n,i,r)),t.appendChild(s)}function Lf(e,t,n){If(e,t,`:before`,n),If(e,t,`:after`,n)}var Rf=`application/font-woff`,zf=`image/jpeg`,Bf={woff:Rf,woff2:Rf,ttf:`application/font-truetype`,eot:`application/vnd.ms-fontobject`,png:`image/png`,jpg:zf,jpeg:zf,gif:`image/gif`,tiff:`image/tiff`,svg:`image/svg+xml`,webp:`image/webp`};function Vf(e){let t=/\.([^./]*?)$/g.exec(e);return t?t[1]:``}function Hf(e){return Bf[Vf(e).toLowerCase()]||``}function Uf(e){return e.split(/,/)[1]}function Wf(e){return e.search(/^(data:)/)!==-1}function Gf(e,t){return`data:${t};base64,${e}`}async function Kf(e,t,n){let r=await fetch(e,t);if(r.status===404)throw Error(`Resource "${r.url}" not found`);let i=await r.blob();return new Promise((e,t)=>{let a=new FileReader;a.onerror=t,a.onloadend=()=>{try{e(n({res:r,result:a.result}))}catch(e){t(e)}},a.readAsDataURL(i)})}var qf={};function Jf(e,t,n){let r=e.replace(/\?.*/,``);return n&&(r=e),/ttf|otf|eot|woff2?/i.test(r)&&(r=r.replace(/.*\//,``)),t?`[${t}]${r}`:r}async function Yf(e,t,n){let r=Jf(e,t,n.includeQueryParams);if(qf[r]!=null)return qf[r];n.cacheBust&&(e+=(/\?/.test(e)?`&`:`?`)+new Date().getTime());let i;try{i=Gf(await Kf(e,n.fetchRequestInit,({res:e,result:n})=>(t||=e.headers.get(`Content-Type`)||``,Uf(n))),t)}catch(t){i=n.imagePlaceholder||``;let r=`Failed to fetch resource: ${e}`;t&&(r=typeof t==`string`?t:t.message),r&&console.warn(r)}return qf[r]=i,i}async function Xf(e){let t=e.toDataURL();return t===`data:,`?e.cloneNode(!1):kf(t)}async function Zf(e,t){if(e.currentSrc){let t=document.createElement(`canvas`),n=t.getContext(`2d`);return t.width=e.clientWidth,t.height=e.clientHeight,n?.drawImage(e,0,0,t.width,t.height),kf(t.toDataURL())}let n=e.poster;return kf(await Yf(n,Hf(n),t))}async function Qf(e,t){try{if(e?.contentDocument?.body)return await cp(e.contentDocument.body,t,!0)}catch{}return e.cloneNode(!1)}async function $f(e,t){return Mf(e,HTMLCanvasElement)?Xf(e):Mf(e,HTMLVideoElement)?Zf(e,t):Mf(e,HTMLIFrameElement)?Qf(e,t):e.cloneNode(tp(e))}var ep=e=>e.tagName!=null&&e.tagName.toUpperCase()===`SLOT`,tp=e=>e.tagName!=null&&e.tagName.toUpperCase()===`SVG`;
64async function np(e,t,n){if(tp(t))return t;let r=[];return r=ep(e)&&e.assignedNodes?yf(e.assignedNodes()):Mf(e,HTMLIFrameElement)&&e.contentDocument?.body?yf(e.contentDocument.body.childNodes):yf((e.shadowRoot??e).childNodes),r.length===0||Mf(e,HTMLVideoElement)||await r.reduce((e,r)=>e.then(()=>cp(r,n)).then(e=>{e&&t.appendChild(e)}),Promise.resolve()),t}function rp(e,t,n){let r=t.style;if(!r)return;let i=window.getComputedStyle(e);i.cssText?(r.cssText=i.cssText,r.transformOrigin=i.transformOrigin):xf(n).forEach(n=>{let a=i.getPropertyValue(n);n===`font-size`&&a.endsWith(`px`)&&(a=`${Math.floor(parseFloat(a.substring(0,a.length-2)))-.1}px`),Mf(e,HTMLIFrameElement)&&n===`display`&&a===`inline`&&(a=`block`),n===`d`&&t.getAttribute(`d`)&&(a=`path(${t.getAttribute(`d`)})`),r.setProperty(n,a,i.getPropertyPriority(n))})}function ip(e,t){Mf(e,HTMLTextAreaElement)&&(t.innerHTML=e.value),Mf(e,HTMLInputElement)&&t.setAttribute(`value`,e.value)}function ap(e,t){if(Mf(e,HTMLSelectElement)){let n=t,r=Array.from(n.children).find(t=>e.value===t.getAttribute(`value`));r&&r.setAttribute(`selected`,``)}}function op(e,t,n){return Mf(t,Element)&&(rp(e,t,n),Lf(e,t,n),ip(e,t),ap(e,t)),t}async function sp(e,t){let n=e.querySelectorAll?e.querySelectorAll(`use`):[];if(n.length===0)return e;let r={};for(let i=0;i<n.length;i++){let a=n[i].getAttribute(`xlink:href`);if(a){let n=e.querySelector(a),i=document.querySelector(a);!n&&i&&!r[a]&&(r[a]=await cp(i,t,!0))}}let i=Object.values(r);if(i.length){let t=`http://www.w3.org/1999/xhtml`,n=document.createElementNS(t,`svg`);n.setAttribute(`xmlns`,t),n.style.position=`absolute`,n.style.width=`0`,n.style.height=`0`,n.style.overflow=`hidden`,n.style.display=`none`;let r=document.createElementNS(t,`defs`);n.appendChild(r);for(let e=0;e<i.length;e++)r.appendChild(i[e]);e.appendChild(n)}return e}async function cp(e,t,n){return!n&&t.filter&&!t.filter(e)?null:Promise.resolve(e).then(e=>$f(e,t)).then(n=>np(e,n,t)).then(n=>op(e,n,t)).then(e=>sp(e,t))}var lp=/url\((['"]?)([^'"]+?)\1\)/g,up=/url\([^)]+\)\s*format\((["']?)([^"']+)\1\)/g,dp=/src:\s*(?:url\([^)]+\)\s*format\([^)]+\)[,;]\s*)+/g;function fp(e){let t=e.replace(/([.*+?^${}()|\[\]\/\\])/g,`\\$1`);return RegExp(`(url\\(['"]?)(${t})(['"]?\\))`,`g`)}function pp(e){let t=[];return e.replace(lp,(e,n,r)=>(t.push(r),e)),t.filter(e=>!Wf(e))}async function mp(e,t,n,r,i){try{let a=n?_f(t,n):t,o=Hf(t),s;return s=i?Gf(await i(a),o):await Yf(a,o,r),e.replace(fp(t),`$1${s}$3`)}catch{}return e}function hp(e,{preferredFontFormat:t}){return t?e.replace(dp,e=>{for(;;){let[n,,r]=up.exec(e)||[];if(!r)return``;if(r===t)return`src: ${n};`}}):e}function gp(e){return e.search(lp)!==-1}async function _p(e,t,n){if(!gp(e))return e;let r=hp(e,n);return pp(r).reduce((e,r)=>e.then(e=>mp(e,r,t,n)),Promise.resolve(r))}async function vp(e,t,n){let r=t.style?.getPropertyValue(e);if(r){let i=await _p(r,null,n);return t.style.setProperty(e,i,t.style.getPropertyPriority(e)),!0}return!1}async function yp(e,t){await vp(`background`,e,t)||await vp(`background-image`,e,t),await vp(`mask`,e,t)||await vp(`-webkit-mask`,e,t)||await vp(`mask-image`,e,t)||await vp(`-webkit-mask-image`,e,t)}async function bp(e,t){let n=Mf(e,HTMLImageElement);if(!(n&&!Wf(e.src))&&!(Mf(e,SVGImageElement)&&!Wf(e.href.baseVal)))return;let r=n?e.src:e.href.baseVal,i=await Yf(r,Hf(r),t);await new Promise((r,a)=>{e.onload=r,e.onerror=t.onImageErrorHandler?(...e)=>{try{r(t.onImageErrorHandler(...e))}catch(e){a(e)}}:a;let o=e;o.decode&&=r,o.loading===`lazy`&&(o.loading=`eager`),n?(e.srcset=``,e.src=i):e.href.baseVal=i})}async function xp(e,t){let n=yf(e.childNodes).map(e=>Sp(e,t));await Promise.all(n).then(()=>e)}async function Sp(e,t){Mf(e,Element)&&(await yp(e,t),await bp(e,t),await xp(e,t))}function Cp(e,t){let{style:n}=e;t.backgroundColor&&(n.backgroundColor=t.backgroundColor),t.width&&(n.width=`${t.width}px`),t.height&&(n.height=`${t.height}px`);let r=t.style;return r!=null&&Object.keys(r).forEach(e=>{n[e]=r[e]}),e}var wp={};async function Tp(e){let t=wp[e];return t??(t={url:e,cssText:await(await fetch(e)).text()},wp[e]=t,t)}async function Ep(e,t){let n=e.cssText,r=/url\(["']?([^"')]+)["']?\)/g,i=(n.match(/url\([^)]+\)/g)||[]).map(async i=>{let a=i.replace(r,`$1`);return a.startsWith(`https://`)||(a=new URL(a,e.url).href),Kf(a,t.fetchRequestInit,({result:e})=>(n=n.replace(i,`url(${e})`),[i,e]))});return Promise.all(i).then(()=>n)}function Dp(e){if(e==null)return[];let t=[],n=e.replace(/(\/\*[\s\S]*?\*\/)/gi,``),r=RegExp(`((@.*?keyframes [\\s\\S]*?){([\\s\\S]*?}\\s*?)}
64)`,`gi`);for(;;){let e=r.exec(n);if(e===null)break;t.push(e[0])}n=n.replace(r,``);let i=/@import[\s\S]*?url\([^)]*\)[\s\S]*?;/gi,a=RegExp(`((\\s*?(?:\\/\\*[\\s\\S]*?\\*\\/)?\\s*?@media[\\s\\S]*?){([\\s\\S]*?)}\\s*?})|(([\\s\\S]*?){([\\s\\S]*?)})`,`gi`);for(;;){let e=i.exec(n);if(e===null){if(e=a.exec(n),e===null)break;i.lastIndex=a.lastIndex}else a.lastIndex=i.lastIndex;t.push(e[0])}return t}async function Op(e,t){let n=[],r=[];return e.forEach(n=>{if(`cssRules`in n)try{yf(n.cssRules||[]).forEach((e,i)=>{if(e.type===CSSRule.IMPORT_RULE){let a=i+1,o=e.href,s=Tp(o).then(e=>Ep(e,t)).then(e=>Dp(e).forEach(e=>{try{n.insertRule(e,e.startsWith(`@import`)?a+=1:n.cssRules.length)}catch(t){console.error(`Error inserting rule from remote css`,{rule:e,error:t})}})).catch(e=>{console.error(`Error loading remote css`,e.toString())});r.push(s)}})}catch(i){let a=e.find(e=>e.href==null)||document.styleSheets[0];n.href!=null&&r.push(Tp(n.href).then(e=>Ep(e,t)).then(e=>Dp(e).forEach(e=>{a.insertRule(e,a.cssRules.length)})).catch(e=>{console.error(`Error loading remote stylesheet`,e)})),console.error(`Error inlining remote css file`,i)}}),Promise.all(r).then(()=>(e.forEach(e=>{if(`cssRules`in e)try{yf(e.cssRules||[]).forEach(e=>{n.push(e)})}catch(t){console.error(`Error while reading CSS rules from ${e.href}`,t)}}),n))}function kp(e){return e.filter(e=>e.type===CSSRule.FONT_FACE_RULE).filter(e=>gp(e.style.getPropertyValue(`src`)))}async function Ap(e,t){if(e.ownerDocument==null)throw Error(`Provided element is not within a Document`);return kp(await Op(yf(e.ownerDocument.styleSheets),t))}function jp(e){return e.trim().replace(/["']/g,``)}function Mp(e){let t=new Set;function n(e){(e.style.fontFamily||getComputedStyle(e).fontFamily).split(`,`).forEach(e=>{t.add(jp(e))}),Array.from(e.children).forEach(e=>{e instanceof HTMLElement&&n(e)})}return n(e),t}async function Np(e,t){let n=await Ap(e,t),r=Mp(e);return(await Promise.all(n.filter(e=>r.has(jp(e.style.fontFamily))).map(e=>{let n=e.parentStyleSheet?e.parentStyleSheet.href:null;return _p(e.cssText,n,t)}))).join(` 65`)}async function Pp(e,t){let n=t.fontEmbedCSS==null?t.skipFonts?null:await Np(e,t):t.fontEmbedCSS;if(n){let t=document.createElement(`style`),r=document.createTextNode(n);t.appendChild(r),e.firstChild?e.insertBefore(t,e.firstChild):e.appendChild(t)}}async function Fp(e,t={}){let{width:n,height:r}=Tf(e,t),i=await cp(e,t,!0);return await Pp(i,t),await Sp(i,t),Cp(i,t),await jf(i,n,r)}async function Ip(e,t={}){let{width:n,height:r}=Tf(e,t),i=await kf(await Fp(e,t)),a=document.createElement(`canvas`),o=a.getContext(`2d`),s=t.pixelRatio||Ef(),c=t.canvasWidth||n,l=t.canvasHeight||r;return a.width=c*s,a.height=l*s,t.skipAutoScale||Of(a),a.style.width=`${c}`,a.style.height=`${l}`,t.backgroundColor&&(o.fillStyle=t.backgroundColor,o.fillRect(0,0,a.width,a.height)),o.drawImage(i,0,0,a.width,a.height),a}async function Lp(e,t={}){return(await Ip(e,t)).toDataURL()}async function Rp(e,t){let n=await Lp(e,{pixelRatio:2,cacheBust:!0,skipFonts:!1}),r=document.createElement(`a`);r.download=t.endsWith(`.png`)?t:`${t}.png`,r.href=n,r.click()}var zp={page:`_page_129nn_1`,cardHost:`_cardHost_129nn_12`,actions:`_actions_129nn_14`,actionBtn:`_actionBtn_129nn_15`,fallback:`_fallback_129nn_30`,wordmark:`_wordmark_129nn_38`,crewLink:`_crewLink_129nn_45`,meta:`_meta_129nn_52`};function Bp(){let e=z(),{token:t}=vt(),[n,r]=(0,_.useState)(null),[i,a]=(0,_.useState)(!0),[o,s]=(0,_.useState)(!1),[c,l]=(0,_.useState)(!1),u=(0,_.useRef)(null);(0,_.useEffect)(()=>{if(!t){s(!0),a(!1);return}Hd(t).then(({data:e,error:t})=>{if(t||!e?.data)s(!0);else{let t=e.data,n=t.kind??`weekly`;r({...t,kind:n})}a(!1)})},[t]);function d(){navigator.clipboard.writeText(window.location.href).then(()=>{l(!0),setTimeout(()=>l(!1),2500)})}async function f(){if(u.current)try{await Rp(u.current,`crew-${n?.kind??`card`}`)}catch{}}return i?(0,R.jsx)(`div`,{className:zp.page,children:(0,R.jsx)(`span`,{className:zp.meta,children:e(`loadingâ¦`)})}):o||!n?(0,R.jsx)(`div`,{className:zp.page,children:(0,R.jsxs)(`div`,{className:zp.fallback,children:[(0,R.jsx)(`div`,{className:zp.wordmark,children:`crew`}),(0,R.jsx)(`p`,{className:zp.meta,children:e(`this card has expired or doesn't exist.`)}),(0,R.jsx)(`a`,{href:`/`,className:zp.crewLink,children:e(`what is crew? â`)})]})}):(0,R.jsxs)(`div`,{className:zp.page,children:[(0,R.jsxs)(`div`,{ref:u,className:zp.cardHost,children:[n.kind===`foun
65der`&&(0,R.jsx)(mf,{data:n}),n.kind===`streak`&&(0,R.jsx)(hf,{data:n}),n.kind===`weekly`&&(0,R.jsx)(gf,{data:n})]}),(0,R.jsxs)(`div`,{className:zp.actions,children:[(0,R.jsx)(`button`,{className:zp.actionBtn,onClick:d,children:e(c?`link copied â`:`copy link`)}),(0,R.jsx)(`button`,{className:zp.actionBtn,onClick:f,children:e(`download image`)})]}),(0,R.jsx)(`a`,{href:`/`,className:zp.crewLink,children:e(`built with crew â accountability for founders â`)})]})}var H={page:`_page_4dy6n_3`,nav:`_nav_4dy6n_12`,back:`_back_4dy6n_22`,main:`_main_4dy6n_32`,header:`_header_4dy6n_39`,tag:`_tag_4dy6n_48`,title:`_title_4dy6n_56`,meta:`_meta_4dy6n_65`,body:`_body_4dy6n_74`,lead:`_lead_4dy6n_80`,section:`_section_4dy6n_88`,sectionTitle:`_sectionTitle_4dy6n_94`,sectionBody:`_sectionBody_4dy6n_102`,footer:`_footer_4dy6n_141`,footerLink:`_footerLink_4dy6n_151`};function Vp(){let{lang:e}=ml(),t=z();return(0,R.jsxs)(`div`,{className:H.page,children:[(0,R.jsxs)(`nav`,{className:H.nav,children:[(0,R.jsx)(Rn,{to:`/`,className:H.back,children:t(`â Back`)}),(0,R.jsx)(El,{size:18}),(0,R.jsx)(`div`,{})]}),(0,R.jsxs)(`main`,{className:H.main,children:[(0,R.jsxs)(`header`,{className:H.header,children:[(0,R.jsx)(`span`,{className:H.tag,children:t(`LEGAL`)}),(0,R.jsx)(`h1`,{className:H.title,children:t(`Privacy Policy`)}),(0,R.jsx)(`p`,{className:H.meta,children:t(`Effective date: July 7, 2026 · Last updated: July 19, 2026`)})]}),e===`fr`?(0,R.jsx)(Up,{}):(0,R.jsx)(Hp,{})]}),(0,R.jsxs)(`footer`,{className:H.footer,children:[(0,R.jsx)(Rn,{to:`/`,className:H.footerLink,children:t(`â Back to Crew`)}),(0,R.jsx)(Rn,{to:`/terms`,className:H.footerLink,children:t(`Terms of Service`)})]})]})}function Hp(){return(0,R.jsxs)(`div`,{className:H.body,children:[(0,R.jsx)(`p`,{className:H.lead,children:`Crew is an accountability tool for founders. We collect only what we need to make it work. We do not sell your data. We never will.`}),(0,R.jsx)(Wp,{title:`1. Who we are`,children:(0,R.jsxs)(`p`,{children:[`Crew ("`,(0,R.jsx)(`strong`,{children:`Crew`}),`", "`,(0,R.jsx)(`strong`,{children:`we`}),`", "`,(0,R.jsx)(`strong`,{children:`us`}),`", "`,(0,R.jsx)(`strong`,{children:`our`}),`") is an AI-powered accountability assistant for founders and solo builders. We operate the Crew web application at `,(0,R.jsx)(`a`,{href:`https://www.meetcrew.app`,children:`www.meetcrew.app`}),` and any associated services. Questions? `,(0,R.jsx)(`a`,{href:`mailto:[email protected]`,children:`[email protected]`}),`.`]})}),(0,R.jsxs)(Wp,{title:`2. What we collect`,children:[(0,R.jsx)(`p`,{children:`We collect the following categories of data when you use Crew:`}),(0,R.jsxs)(`ul`,{children:[(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Account data`}),` â your email address, name, company name, and (if provided) phone number, from signup and onboarding.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Daily priorities`}),` â the tasks you lock in for today or any date, along with their status (pending, done, skipped) and category.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Proof you submit`}),` â screenshots, files, links, or written notes you upload to prove a task was done. Files are stored in encrypted cloud storage; links you submit as proof may be read by Crew (their public content only) to confirm they match your claim â the fetch is made through Jina, a third-party reader service, so the URL you paste is sent to Jina.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Connected-tool data`}),` â Settings offers six connectors: GitHub, Vercel, and Google Calendar (connected directly to Crew), plus Stripe, Calendly, and Gmail (connected through Composio). We read only recent items from them, and only what is needed to check your stated priorities â commit messages and dates, pull-request titles and state, CI pass/fail results, deploy records, calendar event titles and times, Stripe charge records, Calendly meetings, and records of emails you sent. We never read GitHub source code. For each item we keep a short reference: the source, the item's id, its date, and up to the first 200 characters of the item's own text. For an email, those 200 characters can be the opening of the message rather than only the subject line. If you connected a tool before we stopped offering it, that c
65onnection stays live and we keep reading it â and Settings may no longer show a row for it, in which case email `,(0,R.jsx)(`a`,{href:`mailto:[email protected]`,children:`[email protected]`}),` and we will remove it.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Messaging-channel data`}),` â if you opt in to Telegram, your Telegram chat ID and message content, including messages you send to set or categorize your daily tasks. This is opt-in and off by default.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Browser extension data`}),` â if you install the optional Crew Companion extension: in `,(0,R.jsx)(`em`,{children:`automatic`}),` mode, it reads a page's title as you browse and checks it, entirely on your own device, against your locked-in tasks. An unrelated page (your email, your bank, anything not plausibly related to a task) stops right there â nothing further is read, captured, or sent, and nothing about it ever reaches our servers. Only when a title is a maybe-but-not-sure match does it take one more on-device look, at a short snippet of that page's own visible text (never anything you type, never a full page) â and only if that also confirms a match does it take a screenshot of that one page as supporting evidence for Crew's AI reviewer, and only that screenshot (never the text snippet itself) is sent to us. claude.ai and LinkedIn get a more precise version of this same check (real usage percentages, real message counts) instead of just the page title. In `,(0,R.jsx)(`em`,{children:`manual`}),` mode, invoked only when you click the extension icon or use its keyboard shortcut, it captures a screenshot of whatever page you're currently viewing (any site) to check a specific task you select. Screenshots are sent to Anthropic (our AI provider) for a single review and are never written to a file anywhere â not on your device, not on our servers. A page your device rules out never reaches us at all. When the extension does send a check, we store one row recording that it happened â which source fired, which of your tasks it matched (or none), and the time. That row holds no URL, no domain, and no page text, and it is deleted automatically after 90 days. If the check resolves a task as done, we additionally keep the page title or text snippet that was used, as the evidence reference on that verification decision and as the proof note on the task, and the site's domain appears in the "we saw it" notification we store for you.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Billing data`}),` â if you subscribe to a paid plan, Stripe processes your payment method. We store only your Stripe customer/subscription ID and plan status â we never see or store your card details.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Public profile data`}),` â if you choose to make your profile public (opt-in, off by default), the streak, completion rate, category data, profile photo, and LinkedIn/X links you choose to display.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Usage data`}),` â standard server logs (IP address, browser type, pages visited, timestamps) for security and performance, plus the landing-page and in-app analytics events described in Section 7. The in-app events are linked to your account. The landing-page events are not, unless you were signed in when they were recorded â in that case we attach your account id, purely so that deleting your account deletes them too.`]})]})]}),(0,R.jsxs)(Wp,{title:`3. How we use your data`,children:[(0,R.jsx)(`p`,{children:`We use collected data exclusively to:`}),(0,R.jsxs)(`ul`,{children:[(0,R.jsx)(`li`,{children:`Deliver your morning priority lock-in and evening check-in experiences`}),(0,R.jsx)(`li`,{children:`Cross-reference your connected tools to generate accurate, evidence-based receipts`}),(0,R.jsx)(`li`,{children:`Judge proof you submit for tasks with no connector coverage â evidence always comes from what you upload or a link you give us, never from Crew searching on its own`}),(0,R.jsx)(`li`,{children:`Review browser-extension screenshots (if installed) against your locked-in tasks â automatic mode only ever takes a screenshot after an on-device check finds a page plausibly related to one of your tasks; manual mode only ever sees the one page you actively choose to check`}),(0,R.jsx)(`li`,{children:`Detect drift patterns (tasks avoided 2+ consecutive days) and surface them to you`}),(0,R.jsx)(`li`,{children:`Maintain your streak and accountability history`}),(0,R.jsx)(`li`,{children:`Send Telegram, web push, or email messages that are part of the Crew loop (only for channels you opt in to)`}),(0,R.jsx)(`li`,{children:`Process billing through Stripe if you're on a paid plan`}),(0,R.jsx)(`li`,{children:`Improve the product based on usage patterns â Section 7 lists exactly which anal
65ytics events we record and which are linked to your account`})]}),(0,R.jsx)(`p`,{children:`We do not use your data to train AI models sold to third parties. We do not profile you for advertising.`})]}),(0,R.jsxs)(Wp,{title:`4. How we store your data`,children:[(0,R.jsx)(`p`,{children:`All data is stored in Supabase (PostgreSQL), hosted on AWS infrastructure in the United States. Row-level security (RLS) is enforced on all tables â your data is isolated at the database level and is inaccessible to other users.`}),(0,R.jsx)(`p`,{children:`All data in transit is encrypted via TLS 1.2 or higher. Data at rest is encrypted using AES-256.`}),(0,R.jsx)(`p`,{children:`Credentials and API keys are never stored client-side. Third-party OAuth tokens (GitHub, Google) are stored encrypted in Supabase Vault.`})]}),(0,R.jsxs)(Wp,{title:`5. Data sharing`,children:[(0,R.jsx)(`p`,{children:`We do not sell, rent, or trade your personal data. We share data only in the following limited circumstances:`}),(0,R.jsxs)(`ul`,{children:[(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Service providers`}),` â Supabase (database/auth/storage), Vercel (hosting + privacy-friendly analytics), Anthropic (AI reasoning), Composio (read-only connectors), Stripe (billing), Resend (email). These process data only on our behalf and are contractually bound to protect it. See our full `,(0,R.jsx)(Rn,{to:`/subprocessors`,children:`subprocessor list`}),`.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Lookup services`}),` â two further providers are called per request from our servers, without your account identifiers: `,(0,R.jsx)(`strong`,{children:`Brave Search`}),` receives the search terms Crew composes when it searches the web during a chat, and `,(0,R.jsx)(`strong`,{children:`Jina`}),` receives any URL Crew is asked to read â including a link you paste as proof â and returns that page's public content. Jina also receives the search terms when a Brave search fails or returns nothing.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Legal requirements`}),` â if required by a valid court order, subpoena, or applicable law. We will notify you when legally permitted to do so.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Business transfers`}),` â if Crew is acquired or merged, your data may be transferred. You will be notified by email at least 30 days in advance.`]})]})]}),(0,R.jsxs)(Wp,{title:`6. Data retention`,children:[(0,R.jsx)(`p`,{children:`We retain your account data and priority history for as long as your account is active. You can request deletion at any time (see Section 8). Upon deletion:`}),(0,R.jsxs)(`ul`,{children:[(0,R.jsx)(`li`,{children:`Your account and all associated data are deleted within 30 days`}),(0,R.jsx)(`li`,{children:`Anonymized aggregate statistics (e.g. total tasks completed) may be retained`}),(0,R.jsx)(`li`,{children:`Backups containing your data are purged within 90 days`})]})]}),(0,R.jsxs)(Wp,{title:`7. Cookies and tracking`,children:[(0,R.jsx)(`p`,{children:`We use only functional cookies required to maintain your authenticated session â no third-party advertising or cross-site tracking cookies, and no Google Analytics.`}),(0,R.jsxs)(`p`,{children:[`We do use Vercel Analytics, a privacy-friendly, cookie-less analytics tool, to see aggregate page views and which features get used. It does not use cookies, does not track you across other sites, and does not build an advertising profile of you. You can see exactly what it collects on `,(0,R.jsx)(`a`,{href:`https://vercel.com/docs/analytics/privacy-policy`,target:`_blank`,rel:`noreferrer`,children:`Vercel's analytics privacy page`}),`.`]}),(0,R.jsx)(`p`,{children:`Separately from Vercel, Crew records its own analytics in our own Supabase database. Two streams:`}),(0,R.jsxs)(`ul`,{children:[(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Landing-page events`}),` (`,(0,R.jsx)(`code`,{children:`page_events`}),`) â recorded on our public marketing pages, whether or not you have an account. If you are signed out â the usual case â the event is not linked to any account. If you happen to be signed in when it is recorded, we attach your account id to it, for one reason: without it these rows would be unreachable by a deletion request, because nothing in them identifies you. Per event we store: a random id generated in your browser and kept only for that browser session; the page; the event type (view, click, or scroll); for clicks, a label for the element you clicked and its horizontal and vertical position as a percentage of the page â that is, a click heatmap; for scrolls, how far down the page you reached (25/50/75/100%); the hostname of the site you arrived from; the first 200 characters of your browser's user-agent string; and a coarse device type (mobile, tablet, or desktop).`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`In-app events`}),` (`,(0,R.jsx)(`code`,{children:`product_events`}),`) â recorded once you're signed in and linked to your user id. This covers named product events (for example: an onboarding step, locking in your day, adding a task, confirming a check-in, generating a review, submitting feedback), and an `,(0,R.jsx)(`code`,{children:`app_view`}),` event holding the route path (e.g. `,(0,R.jsx)(`code`,{children:`/app/today`}),`) on every page change while you're signed in. We use these to see activation, retention, and how long sessions run.`]})]}),(0,R.jsxs)(`p`,{children:[(0,R.jsx)(`code`,{children:`page_events`}),` and `,(0,R.jsx)(`code`,{children:`activity`}),` (raw items read from your connected tools) are deleted automatically 90 days after they are recorded, by a daily job; extension check records are deleted on the same 90-day schedule. Any `,(0,R.jsx)(`code`,{children:`page_events`}),` row carrying your account id is also deleted immediately when you delete your account, and is included in a data export. `,(0,R.jsx)(`code`,{children:`product_events`}),` is not on an automatic retention schedule today â those rows are kept until you delete your account, and are deleted with it.`]})]}),(0,R.jsxs)(Wp,{title:`8. Your rights`,children:[(0,R.jsx)(`p`,{children:`You have the right to:`}),(0,R.jsxs)(`ul`,{children:[(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Access`}),` â request a copy of all personal data we hold about you`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Correction`}),` â request correction of inaccurate data`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Deletion`}
65),` â request deletion of your account and all associated data`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Portability`}),` â request your priority history and account data in a machine-readable format (JSON)`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Opt-out`}),` â withdraw consent for Telegram, web push, or email messaging at any time via Settings`]})]}),(0,R.jsxs)(`p`,{children:[`To exercise any of these rights, email `,(0,R.jsx)(`a`,{href:`mailto:[email protected]`,children:`[email protected]`}),`. We respond within 30 days.`]})]}),(0,R.jsx)(Wp,{title:`9. Changes to this policy`,children:(0,R.jsx)(`p`,{children:`We may update this policy as the product evolves. Material changes will be communicated by email at least 14 days before they take effect. Your continued use of Crew after that date constitutes acceptance of the updated policy.`})}),(0,R.jsx)(Wp,{title:`10. Contact`,children:(0,R.jsxs)(`p`,{children:[`For privacy questions, contact us at `,(0,R.jsx)(`a`,{href:`mailto:[email protected]`,children:`[email protected]`}),`. For general support, use the in-app chat or email `,(0,R.jsx)(`a`,{href:`mailto:[email protected]`,children:`[email protected]`}),`.`]})})]})}function Up(){return(0,R.jsxs)(`div`,{className:H.body,children:[(0,R.jsx)(`p`,{className:H.lead,children:`Crew est un outil de responsabilisation pour fondateurs. On ne collecte que ce qui est nécessaire à son fonctionnement. On ne vend pas tes données. On ne le fera jamais.`}),(0,R.jsx)(Wp,{title:`1. Qui nous sommes`,children:(0,R.jsxs)(`p`,{children:[`Crew (« `,(0,R.jsx)(`strong`,{children:`Crew`}),` », « `,(0,R.jsx)(`strong`,{children:`nous`}),` », « `,(0,R.jsx)(`strong`,{children:`notre`}),` ») est un assistant de responsabilisation propulsé par l'IA, pour les fondateurs et les solo builders. Nous exploitons l'application web Crew sur `,(0,R.jsx)(`a`,{href:`https://www.meetcrew.app`,children:`www.meetcrew.app`}),` ainsi que les services associés. Une question ? `,(0,R.jsx)(`a`,{href:`mailto:[email protected]`,children:`[email protected]`}),`.`]})}),(0,R.jsxs)(Wp,{title:`2. Ce que nous collectons`,children:[(0,R.jsx)(`p`,{children:`Nous collectons les catégories de données suivantes quand tu utilises Crew :`}),(0,R.jsxs)(`ul`,{children:[(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Données de compte`}),` â ton adresse e-mail, ton nom, le nom de ta société et (si tu l'as fourni) ton numéro de téléphone, issus de l'inscription et de l'onboarding.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Priorités quotidiennes`}),` â les tâches que tu verrouilles pour aujourd'hui ou une autre date, avec leur statut (en attente, faite, passée) et leur catégorie.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Preuves que tu soumets`}),` â captures d'écran, fichiers, liens ou notes que tu téléverses pour prouver qu'une tâche a été faite. Les fichiers sont stockés dans un espace cloud chiffré ; les liens soumis comme preuve peuvent être lus par Crew (leur contenu public uniquement) pour confirmer qu'ils correspondent à ce que tu affirmes â la lecture passe par Jina, un service de lecture tiers, donc l'URL que tu colles est transmise à Jina.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Données des outils connectés`}),` â les Paramètres proposent six connecteurs : GitHub, Vercel et Google Agenda (connectés directement à Crew), plus Stripe, Calendly et Gmail (connectés via Composio). Nous ne lisons que les éléments récents, et uniquement ce qui est nécessaire pour vérifier tes priorités déclarées â messages et dates de commits, titres et états de pull requests, résultats de CI (succès/échec), historique de déploiements, titres et horaires d'événements d'agenda, paiements Stripe, rendez-vous Calendly, et traces des e-mails que tu as envoyés. Nous ne lisons jamais ton code source GitHub. Pour chaque élément, nous conservons une courte référence : la source, l'identifiant de l'élément, sa date et au plus les 200 premiers caractères de son texte. Pour un e-mail, ces 200 caractères peuvent être le début du message plutôt que le seul objet. Si tu avais connecté un outil avant que nous cessions de le proposer, cette c
65onnexion reste active et nous continuons de la lire â et il se peut que les Paramètres n'affichent plus de ligne pour cet outil ; dans ce cas, écris à `,(0,R.jsx)(`a`,{href:`mailto:[email protected]`,children:`[email protected]`}),` et nous la supprimerons.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Données de messagerie`}),` â si tu actives Telegram, ton identifiant de conversation Telegram et le contenu des messages, y compris ceux que tu envoies pour définir ou catégoriser tes tâches du jour. C'est optionnel et désactivé par défaut.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Données de l'extension navigateur`}),` â si tu installes l'extension facultative Crew Companion : en mode `,(0,R.jsx)(`em`,{children:`automatique`}),`, elle lit le titre des pages pendant que tu navigues et le compare, entièrement sur ton propre appareil, à tes tâches verrouillées. Une page sans rapport (tes e-mails, ta banque, tout ce qui n'est pas plausiblement lié à une tâche) s'arrête là â rien de plus n'est lu, capturé ou envoyé, et rien à son sujet n'atteint jamais nos serveurs. Ce n'est que lorsqu'un titre est une correspondance possible mais incertaine qu'elle effectue une vérification supplémentaire sur l'appareil, sur un court extrait du texte visible de cette page (jamais ce que tu tapes, jamais une page entière) â et ce n'est que si cet extrait confirme aussi la correspondance qu'elle prend une capture d'écran de cette seule page comme élément de preuve pour l'IA de Crew ; seule cette capture (jamais l'extrait de texte lui-même) nous est envoyée. claude.ai et LinkedIn bénéficient d'une version plus précise de cette même vérification (pourcentages d'usage réels, nombre réel de messages envoyés) au lieu du seul titre de page. En mode `,(0,R.jsx)(`em`,{children:`manuel`}),`, déclenché uniquement quand tu cliques sur l'icône de l'extension ou utilises son raccourci clavier, elle capture la page que tu es en train de consulter (n'importe quel site) pour vérifier une tâche précise que tu sélectionnes. Les captures sont envoyées à Anthropic (notre fournisseur d'IA) pour une seule analyse et ne sont jamais écrites dans un fichier, où que ce soit â ni sur ton appareil, ni sur nos serveurs. Une page écartée par ton appareil ne nous parvient jamais. Quand l'extension envoie effectivement une vérification, nous enregistrons une ligne attestant qu'elle a eu lieu â quelle source s'est déclenchée, quelle tâche a été rapprochée (ou aucune), et l'heure. Cette ligne ne contient ni URL, ni domaine, ni texte de page, et elle est supprimée automatiquement après 90 jours. Si la vérification conclut qu'une tâche est faite, nous conservons en plus le titre de page ou l'extrait de texte utilisé, comme référence de preuve sur cette décision de vérification et comme note de preuve sur la tâche, et le domaine du site apparaît dans la notification « on l'a vu » que nous conservons pour toi.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Données de facturation`}),` â si tu prends un abonnement payant, Stripe traite ton moyen de paiement. Nous ne stockons que ton identifiant client/abonnement Stripe et le statut de ta formule â nous ne voyons ni ne stockons jamais les données de ta carte.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Données de profil public`}),` â si tu choisis de rendre ton profil public (optionnel, désactivé par défaut) : la série, le taux de complétion, les données par catégorie, la photo de profil et les liens LinkedIn/X que tu choisis d'afficher.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Données d'usage`}),` â les journaux serveur standards (adresse IP, type de navigateur, pages visitées, horodatages) pour la sécurité et la performance, plus les événements d'analytique de la page d'accueil et de l'application décrits à la section 7. Les événements dans l'application sont liés à ton compte. Ceux de la page d'accueil ne le sont pas, sauf si tu étais connecté au moment de leur enregistrement â dans ce cas nous y attachons ton identifiant de compte, uniquement pour que la suppression de ton compte les supprime aussi.`]})]})]}),(0,R.jsxs)(Wp,{title:`3. Comment nous utilisons tes données`,children:[(0,R.jsx)(`p`,{children:`Nous utilisons les données collectées exclusivement pour :`}),(0,R.jsxs)(`ul`,{children:[(0,R.jsx)(`li`,{children:`Assurer ton verrouillage de priorités du matin et ton bilan du soir`}),(0,R.jsx)(`li`,{children:`Recouper tes outils connectés afin de produire des reçus exacts, fondés sur des preuves`}),(0,R.jsx)(`li`,{children:`Ãvaluer les preuves que tu soumets pour les tâches sans couverture par un connecteur â la preuve vient toujours de ce que tu téléverses ou d'un lien que tu nous donnes, jamais d'une recherche que Crew lancerait de lui-même`}),(0,R.jsx)(`li`,{children:`Analyser les captures d'écran de l'extension navigateur (si elle est installée) au regard de tes tâches verrouillées â le mode automatique ne prend une capture qu'après qu'une vérification sur ton appareil a trouvé une page plausiblement liée à l'une de tes tâches ; le mode manuel ne voit que la seule page que tu choisis activement de vérifier`}),(0,R.jsx)(`li`,{children:`Détecter les schémas de dérive (tâches évitées 2 jours consécutifs ou plus) et te les signaler`}),(0,R.jsx)(`li`,{children:`Tenir ta série et ton historique de responsabilisation`}),(0,R.jsx)(`li`,{children:`Envoyer les messages Telegram, notifications web ou e-mails qui font partie de la boucle Crew (uniquement sur les canaux que tu as activés)`}),(0,R.jsx)(`li`,{children:`Traiter la facturation via Stripe si tu es sur une formule payante`}),(0,R.jsx)(`li`,{children:`Améliorer le produit à partir des usages â la section 7 liste exactement quels événements d'analytique nous enregistrons et lesquels sont liés à ton compte`})]}),(0,R.jsx)(`p`,{children:`Nous n'utilisons pas tes données pour entraîner des modèles d'IA vendus à des tiers. Nous ne te profilons pas à des fins publicitaires.`})]}),(0,R.jsxs)(Wp,{title:`4. Comment nous stockons tes données`,children:[(0,R.jsx)(`p`,{children:`Toutes les données sont stockées dans Supabase (PostgreSQL), hébergé sur une infrastru
65cture AWS aux Ãtats-Unis. La sécurité au niveau des lignes (RLS) est appliquée sur toutes les tables â tes données sont isolées au niveau de la base et inaccessibles aux autres utilisateurs.`}),(0,R.jsx)(`p`,{children:`Toutes les données en transit sont chiffrées via TLS 1.2 ou supérieur. Les données au repos sont chiffrées en AES-256.`}),(0,R.jsx)(`p`,{children:`Les identifiants et clés d'API ne sont jamais stockés côté client. Les jetons OAuth tiers (GitHub, Google) sont stockés chiffrés dans Supabase Vault.`})]}),(0,R.jsxs)(Wp,{title:`5. Partage des données`,children:[(0,R.jsx)(`p`,{children:`Nous ne vendons, ne louons ni n'échangeons tes données personnelles. Nous ne partageons des données que dans les cas limités suivants :`}),(0,R.jsxs)(`ul`,{children:[(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Prestataires de services`}),` â Supabase (base de données/authentification/stockage), Vercel (hébergement + analytique respectueuse de la vie privée), Anthropic (raisonnement IA), Composio (connecteurs en lecture seule), Stripe (facturation), Resend (e-mail). Ils ne traitent les données que pour notre compte et sont contractuellement tenus de les protéger. Voir la `,(0,R.jsx)(Rn,{to:`/subprocessors`,children:`liste complète des sous-traitants`}),`.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Services de consultation ponctuelle`}),` â deux autres prestataires sont appelés à la requête depuis nos serveurs, sans tes identifiants de compte : `,(0,R.jsx)(`strong`,{children:`Brave Search`}),` reçoit les termes de recherche que Crew compose quand il cherche sur le web pendant un chat, et `,(0,R.jsx)(`strong`,{children:`Jina`}),` reçoit toute URL que Crew doit lire â y compris un lien que tu colles comme preuve â et renvoie le contenu public de cette page. Jina reçoit aussi les termes de recherche quand une recherche Brave échoue ou ne renvoie rien.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Obligations légales`}),` â si une décision de justice valide, une assignation ou la loi applicable l'exige. Nous t'en informerons lorsque la loi le permet.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Transferts d'entreprise`}),` â si Crew est racheté ou fusionné, tes données pourront être transférées. Tu en seras informé par e-mail au moins 30 jours à l'avance.`]})]})]}),(0,R.jsxs)(Wp,{title:`6. Conservation des données`,children:[(0,R.jsx)(`p`,{children:`Nous conservons tes données de compte et ton historique de priorités tant que ton compte est actif. Tu peux demander la suppression à tout moment (voir section 8). Après suppression :`}),(0,R.jsxs)(`ul`,{children:[(0,R.jsx)(`li`,{children:`Ton compte et toutes les données associées sont supprimés sous 30 jours`}),(0,R.jsx)(`li`,{children:`Des statistiques agrégées anonymisées (ex. nombre total de tâches accomplies) peuvent être conservées`}),(0,R.jsx)(`li`,{children:`Les sauvegardes contenant tes données sont purgées sous 90 jours`})]})]}),(0,R.jsxs)(Wp,{title:`7. Cookies et suivi`,children:[(0,R.jsx)(`p`,{children:`Nous n'utilisons que les cookies fonctionnels nécessaires au maintien de ta session authentifiée â pas de cookies publicitaires tiers ni de suivi inter-sites, et pas de Google Analytics.`}),(0,R.jsxs)(`p`,{children:[`Nous utilisons Vercel Analytics, un outil d'analytique sans cookies et respectueux de la vie privée, pour voir les pages vues agrégées et les fonctionnalités utilisées. Il n'utilise pas de cookies, ne te suit pas sur d'autres sites et ne construit aucun profil publicitaire de toi. Tu peux voir exactement ce qu'il collecte sur `,(0,R.jsx)(`a`,{href:`https://vercel.com/docs/analytics/privacy-policy`,target:`_blank`,rel:`noreferrer`,children:`la page vie privée de Vercel Analytics`}),`.`]}),(0,R.jsx)(`p`,{children:`Indépendamment de Vercel, Crew enregistre sa propre analytique dans notre base Supabase. Deux flux :`}),(0,R.jsxs)(`ul`,{children:[(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Ãvénements de la page d'accueil`}),` (`,(0,R.jsx)(`code`,{children:`page_events`}),`) â enregistrés sur nos pages marketing publiques, que tu aies un compte ou non. Si tu es déconnecté â le cas habituel â l'événement n'est lié à aucun compte. S'il se trouve que tu es connecté au moment de l'enregistrement, nous y attachons ton identifiant de compte, pour une seule raison : sans cela, ces lignes seraient hors de portée d'une demande de suppression, car rien en elles ne t'identifie. Par événement, nous stockons : un identifiant aléatoire généré dans ton navigateur et conservé seulement pour cette session de navigation ; la page ; le type d'événement (vue, clic ou défilement) ; pour les clics, un libellé de l'élément cliqué et sa position horizontale et verticale en pourcentage de la page â autrement dit une carte de chaleur des clics ;
65 pour les défilements, jusqu'où tu es descendu dans la page (25/50/75/100 %) ; le nom d'hôte du site d'où tu arrivais ; les 200 premiers caractères de la chaîne user-agent de ton navigateur ; et un type d'appareil approximatif (mobile, tablette ou ordinateur).`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Ãvénements dans l'application`}),` (`,(0,R.jsx)(`code`,{children:`product_events`}),`) â enregistrés une fois connecté et liés à ton identifiant utilisateur. Cela couvre des événements produit nommés (par exemple : une étape d'onboarding, le verrouillage de ta journée, l'ajout d'une tâche, la confirmation d'un bilan, la génération d'une revue, l'envoi d'un retour), et un événement `,(0,R.jsx)(`code`,{children:`app_view`}),` contenant le chemin de la page (ex. `,(0,R.jsx)(`code`,{children:`/app/today`}),`) à chaque changement de page pendant que tu es connecté. Nous les utilisons pour mesurer l'activation, la rétention et la durée des sessions.`]})]}),(0,R.jsxs)(`p`,{children:[(0,R.jsx)(`code`,{children:`page_events`}),` et `,(0,R.jsx)(`code`,{children:`activity`}),` (éléments bruts lus depuis tes outils connectés) sont supprimés automatiquement 90 jours après leur enregistrement, par un traitement quotidien ; les enregistrements de vérification de l'extension sont supprimés selon le même calendrier de 90 jours. Toute ligne `,(0,R.jsx)(`code`,{children:`page_events`}),` portant ton identifiant de compte est aussi supprimée immédiatement quand tu supprimes ton compte, et est incluse dans un export de données. `,(0,R.jsx)(`code`,{children:`product_events`}),` n'est pas soumis à un calendrier de suppression automatique aujourd'hui â ces lignes sont conservées jusqu'à la suppression de ton compte, et supprimées avec lui.`]})]}),(0,R.jsxs)(Wp,{title:`8. Tes droits`,children:[(0,R.jsx)(`p`,{children:`Tu as le droit de :`}),(0,R.jsxs)(`ul`,{children:[(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Accès`}),` â demander une copie de toutes les données personnelles que nous détenons sur toi`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Rectification`}),` â demander la correction de données inexactes`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Suppression`}),` â demander la suppression de ton compte et de toutes les données associées`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Portabilité`}),` â demander ton historique de priorités et tes données de compte dans un format lisible par machine (JSON)`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Retrait du consentement`}),` â retirer à tout moment ton consentement aux messages Telegram, notifications web ou e-mails via les Paramètres`]})]}),(0,R.jsxs)(`p`,{children:[`Pour exercer l'un de ces droits, écris à `,(0,R.jsx)(`a`,{href:`mailto:[email protected]`,children:`[email protected]`}),`. Nous répondons sous 30 jours.`]})]}),(0,R.jsx)(Wp,{title:`9. Modifications de cette politique`,children:(0,R.jsx)(`p`,{children:`Nous pouvons mettre à jour cette politique à mesure que le produit évolue. Les changements substantiels seront communiqués par e-mail au moins 14 jours avant leur entrée en vigueur. La poursuite de ton utilisation de Crew après cette date vaut acceptation de la politique mise à jour.`})}),(0,R.jsx)(Wp,{title:`10. Contact`,children:(0,R.jsxs)(`p`,{children:[`Pour toute question de confidentialité, écris-nous à `,(0,R.jsx)(`a`,{href:`mailto:[email protected]`,children:`[email protected]`}),`. Pour le support général, utilise le chat dans l'application ou écris à `,(0,R.jsx)(`a`,{href:`mailto:[email protected]`,children:`[email protected]`}),`.`]})})]})}function Wp({title:e,children:t}){return(0,R.jsxs)(`section`,{className:H.section,children:[(0,R.jsx)(`h2`,{className:H.sectionTitle,children:e}),(0,R.jsx)(`div`,{className:H.sectionBody,children:t})]})}var Gp=[{name:`Supabase`,purpose:`Database, authentication, storage, edge functions`,data:`All account + app data (RLS-isolated); OAuth tokens encrypted in Vault`,location:`AWS, USA / EU`},{name:`Vercel`,purpose:`Web app hosting + CDN + privacy-friendly analytics`,data:`Static assets, server logs (IP, user agent), aggregate page-view/feature-usage events (no cookies, no cross-site tracking)`,location:`USA / global edge`},{name:`Anthropic (Claude)`,purpose:`AI co-founder reasoning + verification judgments`,data:`Task text, connected-tool evidence summaries, chat messages â sent per request, not used for training`,location:`USA`},{name:`Composio`,purpose:`Read-only connector OAuth + data access (Stripe, Calendly, Gmail â GitHub, Vercel and Google Calendar connect directly to Crew instead)`,data:`Connector OAuth tokens (held by Composio) + read-only item metadata`,location:`USA`},{name:`Stripe`,purpose:`Subscription billing`,data:`Email, payment method (held by Stripe â Crew never sees card data), subscription status`,location:`USA / global`},{name:`Resend`,purpose:`Transactional + accountability emails`,data:`Email address, message content of morning/evening pings`,location:`USA`},{name:`Telegram`,purpose:`Optional accountability messaging channel`,data:`Telegram chat id + message content (only if you connect Telegram)`,location:`global`},{name:`Discord`,purpose:`Optional read-only connector â Crew reads the channel you pick to look for evidence a task got done`,data:`Your Discord account id + messages in the channel you select; Crew stores a short excerpt (first 200 characters) of a matching message as evidence (only if you connect Discord)`,location:`USA / global`},{name:`Brave Search`,purpose:`Web search when your Crew searches during a chat`,data:`The search terms Crew composes for that search â sent per request, with no account identifier`,location:`USA`},{name:`Jina`,purpose:`Reading the public content of a URL (chat "read this link", links you paste as proof); also the fallback web search when Brave returns nothing`,data:`The URL being read, or the search terms when it is the search fallback â sent per request, with no account identifier`,location:`USA / global`},{name:`unavatar.io`,purpose:`Fetching the public profile picture of the well-known foun
65der shown on a stat card or share card`,data:`That founder's public social handle (never yours) â and, when your browser loads the picture directly, your IP address and browser user-agent; no account identifier is ever sent`,location:`global`}];function Kp(){let e=z();return(0,R.jsxs)(`div`,{className:H.page,children:[(0,R.jsxs)(`nav`,{className:H.nav,children:[(0,R.jsx)(Rn,{to:`/privacy`,className:H.back,children:e(`â Privacy`)}),(0,R.jsx)(El,{size:18}),(0,R.jsx)(`div`,{})]}),(0,R.jsxs)(`main`,{className:H.main,children:[(0,R.jsxs)(`header`,{className:H.header,children:[(0,R.jsx)(`span`,{className:H.tag,children:e(`LEGAL`)}),(0,R.jsx)(`h1`,{className:H.title,children:e(`Subprocessors`)}),(0,R.jsx)(`p`,{className:H.meta,children:e(`The third parties that process data on Crew's behalf. The providers that hold data are listed first and are bound by a data-processing agreement; the last three â Brave Search, Jina, and unavatar.io â are per-request lookup calls that store nothing, described under the table.`)})]}),(0,R.jsxs)(`div`,{className:H.body,children:[(0,R.jsx)(`p`,{className:H.lead,children:e(`Crew shares data only with the service providers below, strictly to operate the product. We do not sell your data and we do not use it for advertising.`)}),(0,R.jsx)(`section`,{className:H.section,children:(0,R.jsx)(`div`,{className:H.sectionBody,children:(0,R.jsxs)(`table`,{style:{width:`100%`,borderCollapse:`collapse`,fontSize:`0.9rem`},children:[(0,R.jsx)(`thead`,{children:(0,R.jsxs)(`tr`,{style:{textAlign:`left`,borderBottom:`1px solid var(--border)`},children:[(0,R.jsx)(`th`,{style:{padding:`8px 6px`},children:e(`Provider`)}),(0,R.jsx)(`th`,{style:{padding:`8px 6px`},children:e(`Purpose`)}),(0,R.jsx)(`th`,{style:{padding:`8px 6px`},children:e(`Data processed`)}),(0,R.jsx)(`th`,{style:{padding:`8px 6px`},children:e(`Region`)})]})}),(0,R.jsx)(`tbody`,{children:Gp.map(t=>(0,R.jsxs)(`tr`,{style:{borderBottom:`1px solid var(--border-subtle)`,verticalAlign:`top`},children:[(0,R.jsx)(`td`,{style:{padding:`10px 6px`,fontWeight:600},children:t.name}),(0,R.jsx)(`td`,{style:{padding:`10px 6px`},children:e(t.purpose)}),(0,R.jsx)(`td`,{style:{padding:`10px 6px`,color:`var(--text-dim)`},children:e(t.data)}),(0,R.jsx)(`td`,{style:{padding:`10px 6px`,color:`var(--text-faint)`},children:e(t.location)})]},t.name))})]})})}),(0,R.jsxs)(`section`,{className:H.section,children:[(0,R.jsx)(`h2`,{className:H.sectionTitle,children:e(`Lookup calls (Brave Search, Jina, unavatar.io)`)}),(0,R.jsxs)(`div`,{className:H.sectionBody,children:[(0,R.jsx)(`p`,{children:e(`These three are not stores of your data â they are single, read-only calls. Brave Search is called from our servers only when your Crew decides to search the web during a chat, and receives only the search terms it composed. Jina is called to read a specific URL â one Crew was asked to read in chat, or one you pasted into a proof note â and also receives the search terms when a web search through Brave fails or returns nothing. Neither call carries your user id, email, or any other account identifier.`)}),(0,R.jsx)(`p`,{children:e(`unavatar.io is an avatar-lookup service. Crew's stat cards and share cards show the face of a well-known founder (for example the one whose completion rate your week most resembles), and unavatar.io resolves that founder's public social handle to their public profile picture. The handle sent is always that public figure's, never yours, and no account identifier is attached. On share cards the picture is fetched through Crew's own server, so unavatar.io sees only our server. On the in-app proof rate badge your browser loads the picture directly, which means unavatar.io sees your IP address and browser user-agent, the same as any image loaded from another domain.`)})]})]}),(0,R.jsxs)(`section`,{className:H.section,children:[(0,R.jsx)(`h2`,{className:H.sectionTitle,children:e(`Changes`)}),(0,R.jsx)(`div`,{className:H.sectionBody,children:(0,R.jsxs)(`p`,{children:[e(`We notify account holders by email at least 14 days before adding or replacing a subprocessor that handles personal data. Questions:`),` `,(0,R.jsx)(`a`,{href:`mailto:[email protected]`,children:`[email protected]`}),`.`]})})]})]})]}),(0,R.jsxs)(`footer`,{className:H.footer,children:[(0,R.jsx)(Rn,{to:`/privacy`,className:H.footerLink,children:e(`â Privacy Policy`)}),(0,R.jsx)(Rn,{to:`/terms`,className:H.footerLink,children:e(`Terms of Service`)})]})]})}function qp(){let{lang:e}=ml(),t=z();return(0,R.jsxs)(`div`,{className:H.page,children:[(0,R.jsxs)(`nav`,{className:H.nav,children:[(0,R.jsx)(Rn,{to:`/`,className:H.back,children:t(`â Back`)}),(0,R.jsx)(El,{size:18}),(0,R.jsx)(`div`,{})]}),(0,R.jsxs)(`main`,{className:H.main,children:[(0,R.jsxs)(`header`,{className:H.header,children:[(0,R.jsx)(`span`,{className:H.tag,children:t(`INTERNAL`)}),(0,R.jsx)(`h1`,{className:H.title,children:t(`Compliance & Data Flow`)}),(0,R.jsx)(`p`,{className:H.meta,children:t(`Working document â scopes, justification, data flow, retention. Not user-facing.`)})]}),e===`fr`?(0,R.jsx)(Yp,{}):(0,R.jsx)(Jp,{})]}),(0,R.jsxs)(`footer`,{className:H.footer,children:[(0,R.jsx)(Rn,{to:`/privacy`,className:H.footerLink,children:t(`Privacy Policy`)}),(0,R.jsx)(Rn,{to:`/subprocessors`,className:H.footerLink,children:t(`Subprocessors`)})]})]})}function Jp(){return(0,R.jsxs)(`div`,{className:H.body,children:[(0,R.jsx)(Xp,{title:`1. OAuth scopes in use (native)`,children:(0,R.jsxs)(`ul`,{children:[(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`GitHub`}),` â `,(0,R.jsx)(`code`,{children:`repo`}),` metadata / `,(0,R.jsx)(`code`,{children:`read:user`}),`. Read commit + PR metadata only (never source contents). Token in Supabase Vault.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Google Calendar`}),` â `,(0,R.jsx)(`code`,{children:`calendar.events`}),`. Read event titles/times to distinguish meetings from shipped work, and create time blocks for tasks you explicitly confirm. Crew never edits or deletes an event it did not create, and blocks it created are excluded from evidence. Refresh token in Vault.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Vercel`}),` â no OAuth app: a user-supplied personal access token, stored in Vault the same way. Read-only deployment records.`]})]})}),(0,R.jsxs)(Xp,{title:`2. Gmail â NOT ENABLED (pending verification)`,children:[(0,R.jsxs)(`p`,{children:[`Reading Gmail evidence is gated on `,(0,R.jsx)(`code`,{children:`GMAIL_ENABLED`}),`: `,(0,R.jsx)(`code`,{children:`gatherEvidence()`}),` in `,(0,R.jsx)(`code`,{children:`_shared/providers.ts`}),` skips any `,(0,R.jsx)(`code`,{children:`gmail`}),` integration unless that env var is exactly `,(0,R.jsx)(`code`,{children:`'true'`}),`. The flag's production value is set in the Supabase function environment and is not visible in this repo.`]}),(0,R.jsxs)(`p`,{children:[(0,R.jsx)(`strong`,{children:`Drift to resolve:`}),` Settings does now offer a Gmail connect button (`,(0,R.jsx)(`code`,{children:`CURATED_APPS`}),` in `,(0,R.jsx)(`code`,{children:`src/routes/app/Settings.tsx`}
65),`), via Composio's managed Google auth rather than a native Crew OAuth app. The read path used is `,(0,R.jsx)(`code`,{children:`GMAIL_FETCH_EMAILS`}),` with `,(0,R.jsx)(`code`,{children:`query: 'in:sent'`}),` â Composio's scopes, not the `,(0,R.jsx)(`code`,{children:`gmail.metadata`}),` scope described below. This section's "must not be offered" rule and the scope table below therefore no longer describe the shipped product.`]}),(0,R.jsx)(`p`,{children:(0,R.jsx)(`strong`,{children:`Requested scope (narrowest first):`})}),(0,R.jsx)(`ul`,{children:(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`code`,{children:`gmail.metadata`}),` â sent-message metadata only (subject, recipient, timestamp). NOT message bodies.`]})}),(0,R.jsxs)(`p`,{children:[(0,R.jsx)(`strong`,{children:`Justification:`}),` verify that outreach/sales tasks ("email the 3 leads") were actually sent, by matching sent-message metadata to the task. Read-only, no storage of bodies, no human review of content.`]}),(0,R.jsxs)(`p`,{children:[(0,R.jsx)(`strong`,{children:`What is actually stored today:`}),` `,(0,R.jsx)(`code`,{children:`judgments.evidence_refs`}),` holds one normalized item per evidence hit â `,(0,R.jsx)(`code`,{children:`{source, id, title, date}`}),` â not a boolean. No bulk mailbox copy is ever taken, and no full message body is stored, but `,(0,R.jsx)(`code`,{children:`title`}),` is not guaranteed to be a subject line: `,(0,R.jsx)(`code`,{children:`itemTitle()`}),` (`,(0,R.jsx)(`code`,{children:`_shared/providers.ts`}),`) picks the first present field from `,(0,R.jsx)(`code`,{children:`title, name, text, subject, summary, message, snippet, headline`}),`, so `,(0,R.jsx)(`code`,{children:`text`}),` is preferred over `,(0,R.jsx)(`code`,{children:`subject`}),` and a Gmail item can be stored as the opening of the message rather than its subject. The stored string is capped at 200 characters. The Discord provider (same file) stores `,(0,R.jsx)(`code`,{children:`m.content.slice(0, 200)`}),` â the first 200 characters of the raw message. Treat the commitment as: no bulk copies, no full bodies, at most a 200-character excerpt of the item, which may be body text.`]})]}),(0,R.jsx)(Xp,{title:`3. Data flow (per verification decision)`,children:(0,R.jsxs)(`ul`,{children:[(0,R.jsxs)(`li`,{children:[`Connector token (Vault) â read-only "recent items" call via provider (Composio or native) â normalized to `,(0,R.jsx)(`code`,{children:`{source, id, title, date}`}),`.`]}),(0,R.jsx)(`li`,{children:`Task + normalized evidence â Anthropic (Claude) judge â verdict + confidence + evidence indices.`}),(0,R.jsxs)(`li`,{children:[`Decision logged to `,(0,R.jsx)(`code`,{children:`judgments`}),`: verdict, confidence, reasoning, model, and `,(0,R.jsx)(`code`,{children:`evidence_refs`}),` â the normalized items above, each capped at a 200-character `,(0,R.jsx)(`code`,{children:`title`}),`. The raw connector API payload is NOT persisted in the judgment path.`]}),(0,R.jsxs)(`li`,{children:[`User correction â `,(0,R.jsx)(`code`,{children:`judgment_feedback`}),`. Aggregates power the calibration report.`]})]})}),(0,R.jsx)(Xp,{title:`4. Retention`,children:(0,R.jsxs)(`ul`,{children:[(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`code`,{children:`activity`}),` (raw connector items) and `,(0,R.jsx)(`code`,{children:`page_events`}),` (landing-page analytics): auto-pruned after `,(0,R.jsx)(`strong`,{children:`90 days`}),` (daily cron `,(0,R.jsx)(`code`,{children:`crew-retention-prune`}),`, migration 023). `,(0,R.jsx)(`code`,{children:`page_events`}),` carried no account key until migration 089, so erasure could not reach it; it now has a nullable `,(0,R.jsx)(`code`,{children:`user_id`}),` with `,(0,R.jsx)(`code`,{children:`on delete cascade`}),`, stamped only when the visitor was signed in. Rows written before 089 stay anonymous and age out on the 90-day schedule.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`code`,{children:`extension_events`}),`: auto-pruned after `,(0,R.jsx)(`strong`,{children:`90 days`}),` (daily cron `,(0,R.jsx)(`code`,{children:`crew-extension-events-prune`}),`, migration 085, which also dropped the `,(0,R.jsx)(`code`,{children:`domain`}),` and `,(0,R.jsx)(`code`,{children:`text`}),` columns).`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`code`,{children:`product_events`}),` (in-app analytics, `,(0,R.jsx)(`code`,{children:`user_id`}),`-linked, includes an `,(0,R.jsx)(`code`,{children:`app_view`}),` row per authenticated route change): `,(0,R.jsx)(`strong`,{children:`no retention job exists`}),` â rows persist until the account is deleted, then go via the `,(0,R.jsx)(`code`,{children:`on delete cascade`}),` FK. Open item.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`code`,{children:`priorities`}),`, `,(0,R.jsx)(`code`,{children:`judgments`}),`, `,(0,R.jsx)(`code`,{children:`judgment_feedback`}),`: retained as the user's execution record + calibration data.`]}
65),(0,R.jsxs)(`li`,{children:[`On account deletion: full cascade incl. storage objects; Vault tokens purged by trigger on `,(0,R.jsx)(`code`,{children:`integrations`}),` delete.`]})]})}),(0,R.jsx)(Xp,{title:`5. Token storage`,children:(0,R.jsxs)(`p`,{children:[`No plaintext OAuth tokens are stored. Native tokens live encrypted in Supabase Vault (`,(0,R.jsx)(`code`,{children:`integrations.vault_secret_id`}),`, via `,(0,R.jsx)(`code`,{children:`set_integration_token`}),`/`,(0,R.jsx)(`code`,{children:`get_integration_token`}),`, service-role only). Composio holds connector tokens on its side; Crew only stores a connected-account id.`]})})]})}function Yp(){return(0,R.jsxs)(`div`,{className:H.body,children:[(0,R.jsx)(Xp,{title:`1. Scopes OAuth utilisés (natif)`,children:(0,R.jsxs)(`ul`,{children:[(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`GitHub`}),` â métadonnées `,(0,R.jsx)(`code`,{children:`repo`}),` / `,(0,R.jsx)(`code`,{children:`read:user`}),`. Lecture des métadonnées de commits + PRs uniquement (jamais le contenu du code source). Jeton dans Supabase Vault.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Google Agenda`}),` â `,(0,R.jsx)(`code`,{children:`calendar.events`}),`. Lecture des titres/horaires d'événements pour distinguer les réunions du travail livré, et création de créneaux pour les tâches que tu confirmes. Crew ne modifie ni ne supprime jamais un événement qu'il n'a pas créé, et les créneaux qu'il crée sont exclus des preuves. Jeton de rafraîchissement dans Vault.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`strong`,{children:`Vercel`}),` â pas d'app OAuth : un jeton d'accès personnel fourni par l'utilisateur, stocké dans Vault de la même façon. Historique de déploiements en lecture seule.`]})]})}),(0,R.jsxs)(Xp,{title:`2. Gmail â NON ACTIVà (vérification en attente)`,children:[(0,R.jsxs)(`p`,{children:[`La lecture de preuves Gmail est conditionnée à `,(0,R.jsx)(`code`,{children:`GMAIL_ENABLED`}),` : `,(0,R.jsx)(`code`,{children:`gatherEvidence()`}),` dans `,(0,R.jsx)(`code`,{children:`_shared/providers.ts`}),` ignore toute intégration `,(0,R.jsx)(`code`,{children:`gmail`}),` tant que cette variable d'environnement ne vaut pas exactement `,(0,R.jsx)(`code`,{children:`'true'`}),`. La valeur en production est définie dans l'environnement des fonctions Supabase et n'est pas visible dans ce dépôt.`]}),(0,R.jsxs)(`p`,{children:[(0,R.jsx)(`strong`,{children:`Ãcart à résoudre :`}),` les Paramètres proposent désormais un bouton de connexion Gmail (`,(0,R.jsx)(`code`,{children:`CURATED_APPS`}),` dans `,(0,R.jsx)(`code`,{children:`src/routes/app/Settings.tsx`}),`), via l'authentification Google gérée par Composio plutôt qu'une app OAuth native de Crew. Le chemin de lecture utilisé est `,(0,R.jsx)(`code`,{children:`GMAIL_FETCH_EMAILS`}),` avec `,(0,R.jsx)(`code`,{children:`query: 'in:sent'`}),` â les scopes de Composio, pas le scope `,(0,R.jsx)(`code`,{children:`gmail.metadata`}),` décrit ci-dessous. La règle « ne doit pas être proposé » de cette section et le tableau de scopes ci-dessous ne décrivent donc plus le produit livré.`]}),(0,R.jsx)(`p`,{children:(0,R.jsx)(`strong`,{children:`Scope demandé (du plus restreint d'abord) :`})}),(0,R.jsx)(`ul`,{children:(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`code`,{children:`gmail.metadata`}),` â métadonnées des messages envoyés uniquement (objet, destinataire, horodatage). PAS le corps des messages.`]})}),(0,R.jsxs)(`p`,{children:[(0,R.jsx)(`strong`,{children:`Justification :`}),` vérifier que les tâches de prospection/vente (« envoyer un e-mail aux 3 prospects ») ont réellement été envoyées, en rapprochant les métadonnées des messages envoyés de la tâche. Lecture seule, aucun stockage de corps de message, aucune revue humaine du contenu.`]}),(0,R.jsxs)(`p`,{children:[(0,R.jsx)(`strong`,{children:`Ce qui est réellement stocké aujourd'hui :`}),` `,(0,R.jsx)(`code`,{children:`judgments.evidence_refs`}),` contient un élément normalisé par preuve trouvée â `,(0,R.jsx)(`code`,{children:`{source, id, title, date}`}),` â pas un booléen. Aucune copie en masse de la boîte mail n'est jamais faite, et aucun corps de message complet n'est stocké, mais `,(0,R.jsx)(`code`,{children:`title`}),` n'est pas garanti d'être un objet de message : `,(0,R.jsx)(`code`,{children:`itemTitle()`}),` (`,(0,R.jsx)(`code`,{children:`_shared/providers.ts`}),`) prend le premier champ présent parmi `,(0,R.jsx)(`code`,{children:`title, name, text, subject, summary, message, snippet, headline`}),`, donc `,(0,R.jsx)(`code`,{children:`text`}),` est préféré à `,(0,R.jsx)(`code`,{children:`subject`}),` et un élément Gmail peut être stocké comme le début du message plutôt que son objet. La chaîne stockée est plafonnée à 200 caractères. Le fournisseur Discord (même fichier) stocke `,(0,R.jsx)(`code`,{children:`m.content.slice(0, 200)`}),` â les 200 premiers caractères du message brut. L'engagement à retenir : pas de copies en masse, pas de corps complets, au plus un extrait de 200 caractères de l'élément, qui peut être du texte de corps.`]})]}),(0,R.jsx)(Xp,{title:`3. Flux de données (par décision de vérification)`,children:(0,R.jsxs)(`ul`,{children:[(0,R.jsxs)(`li`,{children:[`Jeton du connecteur (Vault) â appel en lecture seule « éléments récents » via le fournisseur (Composio ou natif) â normalisé en `,(0,R.jsx)(`code`,{children:`{source, id, title, date}`}),`.`]}),(0,R.jsx)(`li`,{children:`Tâche + preuves normalisées â juge Anthropic (Claude) â verdict
65+ confiance + indices de preuve.`}),(0,R.jsxs)(`li`,{children:[`Décision consignée dans `,(0,R.jsx)(`code`,{children:`judgments`}),` : verdict, confiance, raisonnement, modèle, et `,(0,R.jsx)(`code`,{children:`evidence_refs`}),` â les éléments normalisés ci-dessus, chacun plafonné à un `,(0,R.jsx)(`code`,{children:`title`}),` de 200 caractères. La charge utile brute de l'API du connecteur n'est PAS conservée dans le chemin de jugement.`]}),(0,R.jsxs)(`li`,{children:[`Correction utilisateur â `,(0,R.jsx)(`code`,{children:`judgment_feedback`}),`. Les agrégats alimentent le rapport de calibration.`]})]})}),(0,R.jsx)(Xp,{title:`4. Conservation`,children:(0,R.jsxs)(`ul`,{children:[(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`code`,{children:`activity`}),` (éléments bruts des connecteurs) et `,(0,R.jsx)(`code`,{children:`page_events`}),` (analytique de la page d'accueil) : purge automatique après `,(0,R.jsx)(`strong`,{children:`90 jours`}),` (cron quotidien `,(0,R.jsx)(`code`,{children:`crew-retention-prune`}),`, migration 023). `,(0,R.jsx)(`code`,{children:`page_events`}),` ne portait aucune clé de compte avant la migration 089, l'effacement ne pouvait donc pas l'atteindre ; la table a désormais un `,(0,R.jsx)(`code`,{children:`user_id`}),` nullable avec `,(0,R.jsx)(`code`,{children:`on delete cascade`}),`, renseigné uniquement quand le visiteur était connecté. Les lignes écrites avant la 089 restent anonymes et expirent sur le calendrier de 90 jours.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`code`,{children:`extension_events`}),` : purge automatique après `,(0,R.jsx)(`strong`,{children:`90 jours`}),` (cron quotidien `,(0,R.jsx)(`code`,{children:`crew-extension-events-prune`}),`, migration 085, qui a aussi supprimé les colonnes `,(0,R.jsx)(`code`,{children:`domain`}),` et `,(0,R.jsx)(`code`,{children:`text`}),`).`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`code`,{children:`product_events`}),` (analytique in-app, liée au `,(0,R.jsx)(`code`,{children:`user_id`}),`, incluant une ligne `,(0,R.jsx)(`code`,{children:`app_view`}),` par changement de page authentifié) : `,(0,R.jsx)(`strong`,{children:`aucun traitement de purge n'existe`}),` â les lignes persistent jusqu'à la suppression du compte, puis partent via la FK `,(0,R.jsx)(`code`,{children:`on delete cascade`}),`. Point ouvert.`]}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`code`,{children:`priorities`}),`, `,(0,R.jsx)(`code`,{children:`judgments`}),`, `,(0,R.jsx)(`code`,{children:`judgment_feedback`}),` : conservés comme historique d'exécution de l'utilisateur + données de calibration.`]}),(0,R.jsxs)(`li`,{children:[`à la suppression du compte : cascade complète y compris les objets de stockage ; jetons Vault purgés par déclencheur à la suppression dans `,(0,R.jsx)(`code`,{children:`integrations`}),`.`]})]})}),(0,R.jsx)(Xp,{title:`5. Stockage des jetons`,children:(0,R.jsxs)(`p`,{children:[`Aucun jeton OAuth n'est stocké en clair. Les jetons natifs vivent chiffrés dans Supabase Vault (`,(0,R.jsx)(`code`,{children:`integrations.vault_secret_id`}),`, via `,(0,R.jsx)(`code`,{children:`set_integration_token`}),`/`,(0,R.jsx)(`code`,{children:`get_integration_token`}),`, rôle service uniquement). Composio détient les jetons des connecteurs de son côté ; Crew ne stocke qu'un identifiant de compte connecté.`]})})]})}function Xp({title:e,children:t}){return(0,R.jsxs)(`section`,{className:H.section,children:[(0,R.jsx)(`h2`,{className:H.sectionTitle,children:e}),(0,R.jsx)(`div`,{className:H.sectionBody,children:t})]})}var Zp={page:`_page_1oivd_1`,nav:`_nav_1oivd_2`,back:`_back_1oivd_7`,main:`_main_1oivd_9`,tag:`_tag_1oivd_10`,title:`_title_1oivd_11`,sub:`_sub_1oivd_12`,card:`_card_1oivd_14`,cardHead:`_cardHead_1oivd_18`,cardTitle:`_cardTitle_1oivd_19`,runBtn:`_runBtn_1oivd_20`,checking:`_checking_1oivd_21`,verdictLabel:`_verdictLabel_1oivd_22`,tasks:`_tasks_1oivd_24`,task:`_task_1oivd_24`,dot:`_dot_1oivd_27`,dotIdle:`_dotIdle_1oivd_28`,dot_verified:`_dot_verified_1oivd_29`,dot_confirmed:`_dot_confirmed_1oivd_29`,dot_uncertain:`_dot_uncertain_1oivd_30`,dot_skipped:`_dot_skipped_1oivd_31`,taskBody:`_taskBody_1oivd_32`,taskText:`_taskText_1oivd_33`,receipt:`_receipt_1oivd_34`,receiptOk:`_receiptOk_1oivd_34`,receiptMiss:`_receiptMiss_1oivd_35`,conf:`_conf_1oivd_36`,askRow:`_askRow_1oivd_38`,askText:`_askText_1oivd_39`,askBtns:`_askBtns_1oivd_40`,askYes:`_askYes_1oivd_41`,askNo:`_askNo_1oivd_41`,footNote:`_footNote_1oivd_44`,cta:`_cta_1oivd_46`,ctaBtn:`_ctaBtn_1oivd_47`,ctaNote:`_ctaNote_1oivd_48`},Qp=[{text:`ship the pricing page`,verdict:`verified`,conf:.93,evidence:`github · "feat: pricing page live + stripe links"`},{text:`email the 3 investor leads`,verdict:`uncertain`,conf:.35}
65,{text:`write the launch blog post`,verdict:`skipped`,conf:.1}];function $p(){let e=z(),[t,n]=(0,_.useState)(`idle`),[r,i]=(0,_.useState)({});function a(){n(`running`),setTimeout(()=>n(`done`),1600)}return(0,R.jsxs)(`div`,{className:Zp.page,children:[(0,R.jsxs)(`nav`,{className:Zp.nav,children:[(0,R.jsx)(Rn,{to:`/`,className:Zp.back,children:`â Crew`}),(0,R.jsx)(El,{size:18}),(0,R.jsx)(`div`,{})]}),(0,R.jsxs)(`main`,{className:Zp.main,children:[(0,R.jsx)(`span`,{className:Zp.tag,children:e(`LIVE DEMO · no signup`)}),(0,R.jsx)(`h1`,{className:Zp.title,children:e(`This is what the evening reconcile feels like.`)}),(0,R.jsx)(`p`,{className:Zp.sub,children:e(`You committed to 3 things this morning. Crew checks the receipts â it doesn't take your word for it.`)}),(0,R.jsxs)(`div`,{className:Zp.card,children:[(0,R.jsxs)(`div`,{className:Zp.cardHead,children:[(0,R.jsx)(`span`,{className:Zp.cardTitle,children:e(`tonight · alex's 3`)}),t===`idle`&&(0,R.jsx)(`button`,{className:Zp.runBtn,onClick:a,children:e(`run the reconcile â`)}),t===`running`&&(0,R.jsx)(`span`,{className:Zp.checking,children:e(`Crew is checking connected toolsâ¦`)}),t===`done`&&(0,R.jsx)(`span`,{className:Zp.verdictLabel,children:e(`verdicts in`)})]}),(0,R.jsx)(`ul`,{className:Zp.tasks,children:Qp.map((n,a)=>{let o=t===`done`,s=r[a],c=s?s===`done`?`confirmed`:`skipped`:n.verdict;return(0,R.jsxs)(`li`,{className:Zp.task,children:[(0,R.jsx)(`span`,{className:`${Zp.dot} ${o?Zp[`dot_${c}`]:Zp.dotIdle}`}),(0,R.jsxs)(`div`,{className:Zp.taskBody,children:[(0,R.jsx)(`span`,{className:Zp.taskText,children:e(n.text)}),o&&c===`verified`&&(0,R.jsxs)(`span`,{className:Zp.receipt,children:[`â `,e(`verified â`),` `,n.evidence]}),o&&c===`confirmed`&&(0,R.jsxs)(`span`,{className:Zp.receiptOk,children:[`â `,e(`you confirmed it shipped`)]}),o&&c===`uncertain`&&!s&&(0,R.jsxs)(`div`,{className:Zp.askRow,children:[(0,R.jsx)(`span`,{className:Zp.askText,children:e(`Crew couldn't verify this â did you ship it?`)}),(0,R.jsxs)(`div`,{className:Zp.askBtns,children:[(0,R.jsxs)(`button`,{className:Zp.askYes,onClick:()=>i(e=>({...e,[a]:`done`})),children:[`â
`,e(`shipped`)]}),(0,R.jsxs)(`button`,{className:Zp.askNo,onClick:()=>i(e=>({...e,[a]:`skipped`})),children:[`âï¸ `,e(`skip`)]})]})]}),o&&c===`skipped`&&(0,R.jsx)(`span`,{className:Zp.receiptMiss,children:e(`no evidence â logged as skipped`)})]}),o&&c!==`uncertain`&&(0,R.jsxs)(`span`,{className:Zp.conf,children:[Math.round(n.conf*100),`%`]})]},a)})}),t===`done`&&(0,R.jsx)(`p`,{className:Zp.footNote,children:e(`every verdict is logged with a confidence score. below 0.75, Crew never asserts â it asks. that's the whole product: it can't be fooled, and it won't fool you.`)})]}),(0,R.jsxs)(`div`,{className:Zp.cta,children:[(0,R.jsx)(Rn,{to:`/`,className:Zp.ctaBtn,children:e(`start your own â free â`)}),(0,R.jsx)(`span`,{className:Zp.ctaNote,children:e(`connect GitHub, lock your 3, get your first verified receipt in minutes.`)})]})]})]})}var em={page:`_page_1csps_5`,nav:`_nav_1csps_11`,back:`_back_1csps_21`,main:`_main_1csps_29`,header:`_header_1csps_40`,tag:`_tag_1csps_47`,title:`_title_1csps_55`,sub:`_sub_1csps_65`,center:`_center_1csps_76`,connectBtn:`_connectBtn_1csps_84`,ghMark:`_ghMark_1csps_102`,reassure:`_reassure_1csps_107`,spinner:`_spinner_1csps_115`,spin:`_spin_1csps_115`,loadingText:`_loadingText_1csps_125`,errText:`_errText_1csps_132`,errDetail:`_errDetail_1csps_138`,report:`_report_1csps_147`,reportHead:`_reportHead_1csps_153`,reportTitle:`_reportTitle_1csps_159`,at:`_at_1csps_168`,emptyNote:`_emptyNote_1csps_170`,stats:`_stats_1csps_180`,stat:`_stat_1csps_180`,statValue:`_statValue_1csps_194`,statLabel:`_statLabel_1csps_201`,section:`_section_1csps_210`,sectionLabel:`_sectionLabel_1csps_215`,allocBar:`_allocBar_1csps_225`,allocFill:`_allocFill_1csps_234`,allocList:`_allocList_1csps_238`,allocItem:`_allocItem_1csps_246`,allocDot:`_allocDot_1csps_254`,allocName:`_allocName_1csps_261`,allocPct:`_allocPct_1csps_262`,allocNote:`_allocNote_1csps_267`,repoList:`_repoList_1csps_275`,repoItem:`_repoItem_1csps_282`,repoName:`_repoName_1csps_291`,repoCount:`_repoCount_1cs
65ps_299`,closer:`_closer_1csps_307`,closerLine:`_closerLine_1csps_314`,closerSub:`_closerSub_1csps_326`,waitlist:`_waitlist_1csps_332`},tm=`crew_retro_session`;async function nm(e,t={}){let{data:n,error:r}=await L.functions.invoke(`crew-retro`,{body:{action:e,...t}});if(r)throw Error(r.message);if(n?.error)throw Error(n.error);return n}function rm(e){return new Date(`${e}T00:00:00`).toLocaleDateString(void 0,{month:`short`,day:`numeric`})}function im(){let e=z(),[t,n]=(0,_.useState)(`idle`),[r,i]=(0,_.useState)(null),[a,o]=(0,_.useState)(``),s=(0,_.useRef)(!1);(0,_.useEffect)(()=>{if(s.current)return;let e=new URL(window.location.href),t=e.searchParams.get(`code`),r=e.searchParams.get(`state`);if(!t||!r)return;s.current=!0;let a=localStorage.getItem(tm)||r;window.history.replaceState({},``,`/retro`),(async()=>{n(`generating`);try{await nm(`callback`,{sessionId:a,code:t});let{report:e}=await nm(`report`,{sessionId:a});i(e),n(`done`),localStorage.removeItem(tm)}catch(e){o(e.message),n(`error`)}})()},[]);let c=(0,_.useCallback)(async()=>{n(`redirecting`);try{let{sessionId:e,authorizeUrl:t}=await nm(`start`);localStorage.setItem(tm,e),window.location.href=t}catch(e){o(e.message),n(`error`)}},[]);return(0,R.jsxs)(`div`,{className:em.page,children:[(0,R.jsxs)(`nav`,{className:em.nav,children:[(0,R.jsx)(Rn,{to:`/`,className:em.back,children:`â Crew`}),(0,R.jsx)(El,{size:18}),(0,R.jsx)(`div`,{})]}),(0,R.jsxs)(`main`,{className:em.main,children:[t!==`done`&&(0,R.jsxs)(`header`,{className:em.header,children:[(0,R.jsx)(`span`,{className:em.tag,children:e(`FREE · no signup`)}),(0,R.jsx)(`h1`,{className:em.title,children:e(`What did you actually ship last week?`)}),(0,R.jsx)(`p`,{className:em.sub,children:e(`Connect GitHub (read-only) and get a one-page retro of your real output â commits, PRs, and where the work went. Takes under a minute.`)})]}),t===`idle`&&(0,R.jsxs)(`div`,{className:em.center,children:[(0,R.jsxs)(`button`,{className:em.connectBtn,onClick:c,children:[(0,R.jsx)(`span`,{className:em.ghMark,"aria-hidden":!0,children:`â`}),e(`Connect GitHub â get your retro`)]}),(0,R.jsx)(`p`,{className:em.reassure,children:e(`Read-only. We never write to your repos, and the token stays server-side.`)})]}),(t===`redirecting`||t===`generating`)&&(0,R.jsxs)(`div`,{className:em.center,children:[(0,R.jsx)(`div`,{className:em.spinner,"aria-hidden":!0}),(0,R.jsx)(`p`,{className:em.loadingText,children:e(t===`redirecting`?`Sending you to GitHubâ¦`:`Reading last week from GitHubâ¦`)})]}),t===`error`&&(0,R.jsxs)(`div`,{className:em.center,children:[(0,R.jsx)(`p`,{className:em.errText,children:e(`Couldn't build your retro.`)}),(0,R.jsx)(`p`,{className:em.errDetail,children:a}),(0,R.jsx)(`button`,{className:em.connectBtn,onClick:c,children:e(`Try again`)})]}),t===`done`&&r&&(0,R.jsx)(am,{report:r})]})]})}function am({report:e}){let t=z(),n=e.commits===0&&e.prs===0&&e.mergedPrs===0,r=e.repos.slice(0,6);return(0,R.jsxs)(`div`,{className:em.report,children:[(0,R.jsxs)(`header`,{className:em.reportHead,children:[(0,R.jsxs)(`span`,{className:em.tag,children:[t(`YOUR LAST 7 DAYS`),` · `,rm(e.since),` â `,rm(e.until)]}),(0,R.jsxs)(`h1`,{className:em.reportTitle,children:[(0,R.jsx)(`span`,{className:em.at,children:`@`}),e.login,t(`, here's the receipt.`)]})]}),n?(0,R.jsx)(`p`,{className:em.emptyNote,children:t(`No commits or PRs authored in the last 7 days on the repos we can see. That's the honest answer â sometimes a quiet week is a quiet week.`)}):(0,R.jsxs)(R.Fragment,{children:[(0,R.jsxs)(`div`,{className:em.stats,children:[(0,R.jsx)(om,{value:e.commits,label:t(`commits`)}),(0,R.jsx)(om,{value:e.prs,label:t(`PRs opened`)}),(0,R.jsx)(om,{value:e.mergedPrs,label:t(`PRs merged`)}),(0,R.jsx)(om,{value:e.repos.length,label:e.repos.length===1?t(`repo touched`):t(`repos touched`)})]}),e.byCategory.length>0&&(0,R.jsxs)(`section`,{className:em.section,children:[(0,R.jsx)(`h2`,{className:em.sectionLabel,children:t(`Where the output went`)}),(0,R.jsx)(`div`,{className:em.allocBar,children:e.byCategory.map(e=>(0,R.jsx)(`div`,{className:em.allocFill,style:{width:`${Math.round(e.share*100)}%`}},e.category))}),(0,R.jsx)(`ul`,{className:em.allocList,children:e.byCategory.map(e=>(0,R.jsxs)(`li`,{className:em.allocItem,children:[(0,R.jsx)(`span`,{className:em.allocDot,"aria-hidden":!0}),(0,R.jsx)(`span`,{className:em.allocName,children:e.category}),(0,R.jsxs)(`span`,{className:em.allocPct,children:[Math.round(e.share*100),`%`]})]},e.category))}),(0,R.jsx)(`p`,{className:em.allocNote,children:t(`Everything here came from GitHub, so it's all build. Honest label, not a spun one.`)})]}),r.length>0&&(0,R.jsxs)(`section`,{className:em.section,children:[(0,R.jsx)(`h2`,{className:em.sectionLabel,children:t(`Repos you touched`)}),(0,R.jsx)(`ul`,{className:em.repoList,children:r.map(e=>(0,R.jsxs)(`li`,{className:em.repoItem,children:[(0,R.jsx)(`span`,{className:em.repoName,children:e.name}),e.commits>0&&(0,R.jsxs)(`span`,{className:em.repoCount,children:[e.commits,` `,e.commits===1?t(`commit`):t(`commits`)]})]},e.name))})]})]}),(0,R.jsxs)(`footer`,{className:em.closer,children:[(0,R.jsx)(`p`,{className:em.closerLine,children:t(`This is what you did.`)}),(0,R.jsxs)(`p`,{className:em.closerLine,children:[t(`Crew is what happens when you say
65what you'll do`),` `,(0,R.jsx)(`em`,{children:t(`first`)}),`.`]}),(0,R.jsx)(`p`,{className:em.closerSub,children:t(`Your task manager doesn't care if you lied to it. Crew checks the receipts.`)}),(0,R.jsx)(Rn,{to:`/auth`,className:em.waitlist,children:t(`Get on the waitlist â`)})]})]})}function om({value:e,label:t}){return(0,R.jsxs)(`div`,{className:em.stat,children:[(0,R.jsx)(`span`,{className:em.statValue,children:e}),(0,R.jsx)(`span`,{className:em.statLabel,children:t})]})}function sm(){let{lang:e}=ml(),t=z();return(0,R.jsxs)(`div`,{className:H.page,children:[(0,R.jsxs)(`nav`,{className:H.nav,children:[(0,R.jsx)(Rn,{to:`/`,className:H.back,children:t(`â Back`)}),(0,R.jsx)(El,{size:18}),(0,R.jsx)(`div`,{})]}),(0,R.jsxs)(`main`,{className:H.main,children:[(0,R.jsxs)(`header`,{className:H.header,children:[(0,R.jsx)(`span`,{className:H.tag,children:t(`LEGAL`)}),(0,R.jsx)(`h1`,{className:H.title,children:t(`Terms of Service`)}),(0,R.jsx)(`p`,{className:H.meta,children:t(`Effective date: June 17, 2026 · Last updated: June 17, 2026`)})]}),e===`fr`?(0,R.jsx)(lm,{}):(0,R.jsx)(cm,{})]}),(0,R.jsxs)(`footer`,{className:H.footer,children:[(0,R.jsx)(Rn,{to:`/`,className:H.footerLink,children:t(`â Back to Crew`)}),(0,R.jsx)(Rn,{to:`/privacy`,className:H.footerLink,children:t(`Privacy Policy`)})]})]})}function cm(){return(0,R.jsxs)(`div`,{className:H.body,children:[(0,R.jsx)(`p`,{className:H.lead,children:`By using Crew you agree to these terms. They're written to be readable, not to trap you. If something seems off, email us.`}),(0,R.jsxs)(um,{title:`1. Acceptance`,children:[(0,R.jsxs)(`p`,{children:[`These Terms of Service ("`,(0,R.jsx)(`strong`,{children:`Terms`}),`") govern your use of the Crew web application and services (collectively, "`,(0,R.jsx)(`strong`,{children:`Crew`}),`", "`,(0,R.jsx)(`strong`,{children:`Service`}),`"), operated by Crew ("`,(0,R.jsx)(`strong`,{children:`we`}),`", "`,(0,R.jsx)(`strong`,{children:`us`}),`"). By creating an account or using the Service, you agree to these Terms and our `,(0,R.jsx)(Rn,{to:`/privacy`,children:`Privacy Policy`}),`.`]}),(0,R.jsx)(`p`,{children:`If you are using Crew on behalf of a company or organization, you represent that you have authority to bind that entity to these Terms.`})]}),(0,R.jsx)(um,{title:`2. Eligibility`,children:(0,R.jsx)(`p`,{children:`You must be at least 18 years old to use Crew. By using the Service, you confirm that you meet this requirement.`})}),(0,R.jsxs)(um,{title:`3. Your account`,children:[(0,R.jsx)(`p`,{children:`You are responsible for maintaining the security of your account credentials. Do not share your password. You are responsible for all activity that occurs under your account.`}),(0,R.jsx)(`p`,{children:`You may create one account per person. Creating duplicate or impersonating accounts is not permitted.`}),(0,R.jsx)(`p`,{children:`We reserve the right to suspend or terminate accounts that violate these Terms, engage in fraud, or are inactive for more than 24 months.`})]}),(0,R.jsxs)(um,{title:`4. Acceptable use`,children:[(0,R.jsx)(`p`,{children:`You may use Crew only for lawful purposes consistent with its intended use as a personal accountability and productivity tool. You agree not to:`}),(0,R.jsxs)(`ul`,{children:[(0,R.jsx)(`li`,{children:`Use the Service to harass, defame, or threaten any person`}),(0,R.jsx)(`li`,{children:`Attempt to gain unauthorized access to other users' accounts or to our systems`}),(0,R.jsx)(`li`,{children:`Scrape, crawl, or extract data from Crew in an automated manner without our written permission`}),(0,R.jsx)(`li`,{children:`Use the Service in any manner that could damage, overburden, or impair it`}),(0,R.jsx)(`li`,{children:`Reverse engineer or attempt to extract source code from the Service`}),(0,R.jsx)(`li`,{children:`Use the Service to develop a competing product`})]})]}),(0,R.jsxs)(um,{title:`5. Integrations (GitHub, Google Calendar)`,children:[(0,R.jsxs)(`p`,{children:[`Crew can connect to third-party services including GitHub and Google Calendar. By connecting these integrations, you authorize Crew to read the data described
65in our `,(0,R.jsx)(Rn,{to:`/privacy`,children:`Privacy Policy`}),` (commit metadata, calendar event titles and times).`]}),(0,R.jsx)(`p`,{children:`You can revoke these integrations at any time in Settings. We are not responsible for changes to third-party APIs that affect integration functionality.`})]}),(0,R.jsxs)(um,{title:`6. AI-generated content`,children:[(0,R.jsx)(`p`,{children:`Crew uses AI models to generate messages, insights, and accountability prompts. These outputs are for informational and motivational purposes only. They do not constitute professional business, financial, legal, medical, or psychological advice.`}),(0,R.jsxs)(`p`,{children:[`AI outputs may occasionally be inaccurate, inappropriate, or irrelevant. You are responsible for any decisions you make based on them. If an AI output is problematic, please report it at `,(0,R.jsx)(`a`,{href:`mailto:[email protected]`,children:`[email protected]`}),`.`]})]}),(0,R.jsxs)(um,{title:`7. Intellectual property`,children:[(0,R.jsx)(`p`,{children:`The Crew name, logo, visual design, and software are owned by us and protected by copyright and trademark law. You may not use these without our written permission.`}),(0,R.jsx)(`p`,{children:`Your data â your priorities, notes, and any content you create in Crew â belongs to you. We claim no ownership over it. You grant us a limited license to process and display it solely for the purpose of operating the Service.`})]}),(0,R.jsxs)(um,{title:`8. Payment and billing`,children:[(0,R.jsx)(`p`,{children:`Crew offers a free trial period, after which continued use requires a paid subscription. Subscriptions are billed in advance on a recurring basis (monthly or annual, as selected) via Stripe and renew automatically until cancelled.`}),(0,R.jsx)(`p`,{children:`You can cancel anytime in Settings; cancellation takes effect at the end of your current billing period. We reserve the right to change pricing with at least 30 days' notice before it affects your account. Prepaid amounts are non-refundable except where required by applicable law.`})]}),(0,R.jsxs)(um,{title:`9. Disclaimers`,children:[(0,R.jsxs)(`p`,{children:[`The Service is provided "`,(0,R.jsx)(`strong`,{children:`as is`}),`" and "`,(0,R.jsx)(`strong`,{children:`as available`}),`" without warranties of any kind, express or implied. We do not warrant that the Service will be uninterrupted, error-free, or free of harmful components.`]}),(0,R.jsx)(`p`,{children:`We are not responsible for decisions you make based on Crew's outputs, integrations, or accountability data.`})]}),(0,R.jsxs)(um,{title:`10. Limitation of liability`,children:[(0,R.jsx)(`p`,{children:`To the maximum extent permitted by law, Crew shall not be liable for any indirect, incidental, special, consequential, or punitive damages, including loss of profits, data, or goodwill.`}),(0,R.jsx)(`p`,{children:`Our total liability to you for any claims arising from the Service shall not exceed the amount you paid us in the 12 months preceding the claim, or $100, whichever is greater.`})]}),(0,R.jsxs)(um,{title:`11. Termination`,children:[(0,R.jsxs)(`p`,{children:[`You may delete your account at any time in Settings or by emailing `,(0,R.jsx)(`a`,{href:`mailto:[email protected]`,children:`[email protected]`}),`. Upon deletion, your data is removed per our Privacy Policy.`]}),(0,R.jsx)(`p`,{children:`We may suspend or terminate your account immediately if you violate these Terms. We will make reasonable efforts to notify you in advance except where prohibited by law or necessary to prevent harm.`})]}),(0,R.jsx)(um,{title:`12. Governing law`,children:(0,R.jsx)(`p`,{children:`These Terms are governed by the laws of the State of Delaware, United States, without regard to its conflict-of-law provisions. Any disputes shall be resolved in the courts of Delaware.`})}),(0,R.jsx)(um,{title:`13. Changes to these terms`,children:(0,R.jsx)(`p`,{children:`We may update these Terms as the product evolves. Material changes will be communicated by email at least 14 days before they take effect. Your continued use of Crew after that date constitutes acceptance of the updated Terms.`})}),(0,R.jsx)(um,{title:`14. Contact`,children:(0,R.jsxs)(`p`,{children:[`Questions about these Terms? Email `,(0,R.jsx)(`a`,{href:`mailto:[email protected]`,children:`[email protected]`}),` or write to us at the address on file. We aim to respond within 5 business days.`]})})]})}function lm(){return(0,R.jsxs)(`div`,{className:H.body,children:[(0,R.jsx)(`p`,{className:H.lead,children:`En utilisant Crew, tu acceptes ces conditions. Elles sont écrites pour être lisibles, pas pour te piéger. Si quelque chose te semble anormal, écris-nous.`}),(0,R.jsxs)(um,{title:`1. Acceptation`,children:[(0,R.jsxs)(`p`,{children:[`Les présentes Conditions d'utilisation (« `,(0,R.jsx)(`strong`,{children:`Conditions`}),` ») régissent ton usage de l'application web et des services Crew (collectivement « `,(0,R.jsx)(`strong`,{children:`Crew`}),` », le « `,(0,R.jsx)(`strong`,{children:`Service`}),` »), exploités par Crew (« `,(0,R.jsx)(`strong`,{children:`nous`}),` »). En créant un compte ou en utilisant le Service, tu acceptes ces Conditions ainsi que notre `,(0,R.jsx)(Rn,{to:`/privacy`,children:`Politique de confidentialité`}),`.`]}),(0,R.jsx)(`p`,{children:`Si tu utilises Crew pour le compte d'une société ou d'une organisation, tu déclares avoir l'autorité d'engager cette entité aux présentes Conditions.`})]}),(0,R.jsx)(um,{title:`2. Conditions d'accès`,children:(0,R.jsx)(`p`,{children:`Tu dois avoir au moins 18 ans pour utiliser Crew. En utilisant le Service, tu confirmes remplir cette c
65ondition.`})}),(0,R.jsxs)(um,{title:`3. Ton compte`,children:[(0,R.jsx)(`p`,{children:`Tu es responsable de la sécurité de tes identifiants de compte. Ne partage pas ton mot de passe. Tu es responsable de toute activité effectuée depuis ton compte.`}),(0,R.jsx)(`p`,{children:`Tu peux créer un compte par personne. Créer des comptes en double ou usurpant une identité n'est pas autorisé.`}),(0,R.jsx)(`p`,{children:`Nous nous réservons le droit de suspendre ou de résilier les comptes qui violent ces Conditions, commettent une fraude, ou restent inactifs plus de 24 mois.`})]}),(0,R.jsxs)(um,{title:`4. Usage acceptable`,children:[(0,R.jsx)(`p`,{children:`Tu ne peux utiliser Crew qu'à des fins licites, conformes à sa vocation d'outil personnel de responsabilisation et de productivité. Tu t'engages à ne pas :`}),(0,R.jsxs)(`ul`,{children:[(0,R.jsx)(`li`,{children:`Utiliser le Service pour harceler, diffamer ou menacer quiconque`}),(0,R.jsx)(`li`,{children:`Tenter d'accéder sans autorisation aux comptes d'autres utilisateurs ou à nos systèmes`}),(0,R.jsx)(`li`,{children:`Extraire des données de Crew de manière automatisée (scraping, crawling) sans notre autorisation écrite`}),(0,R.jsx)(`li`,{children:`Utiliser le Service d'une manière qui pourrait l'endommager, le surcharger ou le dégrader`}),(0,R.jsx)(`li`,{children:`Faire de l'ingénierie inverse ou tenter d'extraire le code source du Service`}),(0,R.jsx)(`li`,{children:`Utiliser le Service pour développer un produit concurrent`})]})]}),(0,R.jsxs)(um,{title:`5. Intégrations (GitHub, Google Agenda)`,children:[(0,R.jsxs)(`p`,{children:[`Crew peut se connecter à des services tiers, notamment GitHub et Google Agenda. En connectant ces intégrations, tu autorises Crew à lire les données décrites dans notre `,(0,R.jsx)(Rn,{to:`/privacy`,children:`Politique de confidentialité`}),` (métadonnées de commits, titres et horaires d'événements d'agenda).`]}),(0,R.jsx)(`p`,{children:`Tu peux révoquer ces intégrations à tout moment dans les Paramètres. Nous ne sommes pas responsables des changements apportés aux API tierces qui affecteraient le fonctionnement des intégrations.`})]}),(0,R.jsxs)(um,{title:`6. Contenu généré par IA`,children:[(0,R.jsx)(`p`,{children:`Crew utilise des modèles d'IA pour générer des messages, des analyses et des rappels de responsabilisation. Ces contenus ont un but purement informatif et motivationnel. Ils ne constituent pas un conseil professionnel â ni commercial, ni financier, ni juridique, ni médical, ni psychologique.`}),(0,R.jsxs)(`p`,{children:[`Les productions de l'IA peuvent parfois être inexactes, inappropriées ou hors sujet. Tu es responsable des décisions que tu prends sur leur base. Si une production de l'IA pose problème, signale-la à `,(0,R.jsx)(`a`,{href:`mailto:[email protected]`,children:`[email protected]`}),`.`]})]}),(0,R.jsxs)(um,{title:`7. Propriété intellectuelle`,children:[(0,R.jsx)(`p`,{children:`Le nom Crew, le logo, l'identité visuelle et le logiciel nous appartiennent et sont protégés par le droit d'auteur et le droit des marques. Tu ne peux pas les utiliser sans notre autorisation écrite.`}),(0,R.jsx)(`p`,{children:`Tes données â tes priorités, tes notes et tout contenu que tu crées dans Crew â t'appartiennent. Nous n'en revendiquons aucune propriété. Tu nous accordes une licence limitée pour les traiter et les afficher, uniquement aux fins d'exploitation du Service.`})]}),(0,R.jsxs)(um,{title:`8. Paiement et facturation`,children:[(0,R.jsx)(`p`,{children:`Crew propose une période d'essai gratuite, après laquelle l'utilisation nécessite un abonnement payant. Les abonnements sont facturés d'avance, de façon récurrente (mensuelle ou annuelle, selon ton choix) via Stripe, et se renouvellent automatiquement jusqu'à résiliation.`}),(0,R.jsx)(`p`,{children:`Tu peux annuler à tout moment dans les Paramètres ; l'annulation prend effet à la fin de ta période de facturation en cours. Nous nous réservons le droit de modifier les tarifs avec un préavis d'au moins 30 jours avant que cela n'affecte ton compte. Les montants prépayés ne sont pas remboursables, sauf lorsque la loi applicable l'exige.`})]}),(0,R.jsxs)(um,{title:`9. Exclusions de garantie`,children:[(0,R.jsxs)(`p`,{children:[`Le Service est fourni « `,(0,R.jsx)(`strong`,{children:`en l'état`}),` » et « `,(0,R.jsx)(`strong`,{children:`selon disponibilité`}),` », sans garantie d'aucune sorte, expresse ou implicite. Nous ne garantissons pas que le Service sera ininterrompu, exempt d'erreurs ou de composants nuisibles.`]}),(0,R.jsx)(`p`,{children:`Nous ne sommes pas responsables des décisions que tu prends sur la base des contenus, intégrations ou données de responsabilisation de Crew.`})]}),(0,R.jsxs)(um,{title:`10. Limitation de responsabilité`,children:[(0,R.jsx)(`p`,{children:`Dans la mesure maximale permise par la loi, Crew ne saurait être tenu responsable des dommages indirects, accessoires, spéciaux, c
65onsécutifs ou punitifs, y compris la perte de profits, de données ou de clientèle.`}),(0,R.jsx)(`p`,{children:`Notre responsabilité totale envers toi pour toute réclamation liée au Service ne saurait excéder le montant que tu nous as payé au cours des 12 mois précédant la réclamation, ou 100 $, si ce montant est supérieur.`})]}),(0,R.jsxs)(um,{title:`11. Résiliation`,children:[(0,R.jsxs)(`p`,{children:[`Tu peux supprimer ton compte à tout moment dans les Paramètres ou en écrivant à `,(0,R.jsx)(`a`,{href:`mailto:[email protected]`,children:`[email protected]`}),`. Après suppression, tes données sont retirées conformément à notre Politique de confidentialité.`]}),(0,R.jsx)(`p`,{children:`Nous pouvons suspendre ou résilier ton compte immédiatement si tu violes ces Conditions. Nous ferons des efforts raisonnables pour te prévenir à l'avance, sauf lorsque la loi l'interdit ou qu'il est nécessaire d'agir pour prévenir un préjudice.`})]}),(0,R.jsx)(um,{title:`12. Droit applicable`,children:(0,R.jsx)(`p`,{children:`Ces Conditions sont régies par les lois de l'Ãtat du Delaware, Ãtats-Unis, sans égard à ses règles de conflit de lois. Tout litige sera porté devant les tribunaux du Delaware.`})}),(0,R.jsx)(um,{title:`13. Modifications de ces conditions`,children:(0,R.jsx)(`p`,{children:`Nous pouvons mettre à jour ces Conditions à mesure que le produit évolue. Les changements substantiels seront communiqués par e-mail au moins 14 jours avant leur entrée en vigueur. La poursuite de ton utilisation de Crew après cette date vaut acceptation des Conditions mises à jour.`})}),(0,R.jsx)(um,{title:`14. Contact`,children:(0,R.jsxs)(`p`,{children:[`Une question sur ces Conditions ? Ãcris à `,(0,R.jsx)(`a`,{href:`mailto:[email protected]`,children:`[email protected]`}),` ou à l'adresse postale enregistrée. Nous visons une réponse sous 5 jours ouvrés.`]})})]})}function um({title:e,children:t}){return(0,R.jsxs)(`section`,{className:H.section,children:[(0,R.jsx)(`h2`,{className:H.sectionTitle,children:e}),(0,R.jsx)(`div`,{className:H.sectionBody,children:t})]})}var dm={toggle:`_toggle_1akgb_1`,icon:`_icon_1akgb_20`};function fm(){let e=z(),[t,n]=(0,_.useState)(()=>wr()),r=t===`dark`?`light`:`dark`;return(0,R.jsx)(`button`,{type:`button`,className:dm.toggle,onClick:()=>n(Er()),"aria-label":e(r===`dark`?`switch to dark mode`:`switch to light mode`),title:e(r===`dark`?`switch to dark mode`:`switch to light mode`),children:t===`dark`?(0,R.jsx)(mm,{}):(0,R.jsx)(pm,{})})}function pm(){return(0,R.jsx)(`svg`,{className:dm.icon,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`1.8`,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":!0,children:(0,R.jsx)(`path`,{d:`M21 12.8A9 9 0 1 1 11.2 3a7 7 0 0 0 9.8 9.8z`})})}function mm(){return(0,R.jsxs)(`svg`,{className:dm.icon,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`1.8`,strokeLinecap:`round`,strokeLinejoin:`round`,"aria-hidden":!0,children:[(0,R.jsx)(`circle`,{cx:`12`,cy:`12`,r:`4`}),(0,R.jsx)(`path`,{d:`M12 2v2M12 20v2M4.9 4.9l1.4 1.4M17.7 17.7l1.4 1.4M2 12h2M20 12h2M4.9 19.1l1.4-1.4M17.7 6.3l1.4-1.4`})]})}var hm={block:`_block_11vbq_5`,kicker:`_kicker_11vbq_15`,line:`_line_11vbq_24`};function gm({line:e,className:t}){let n=z();return(0,R.jsxs)(`div`,{className:B(hm.block,t),children:[(0,R.jsx)(`span`,{className:hm.kicker,children:n(`ONE LINE FOR YOUR HEAD`)}),(0,R.jsx)(`span`,{className:hm.line,children:e})]})}var _m={flag:`_flag_3cuhi_7`,diamond:`_diamond_3cuhi_22`};function vm({children:e,className:t}){return(0,R.jsxs)(`span`,{className:B(_m.flag,t),children:[(0,R.jsx)(`span`,{"aria-hidden":!0,className:_m.diamond,children:`â`}),e]})}var ym={row:`_row_ux5n6_5`,bubble:`_bubble_ux5n6_11`,dot:`_dot_ux5n6_20`,"crew-typing":`_crew-typing_ux5n6_1`};function bm(){let e=z();return(0,R.jsx)(`div`,{className:ym.row,role:`status`,"aria-label":e(`Crew is typing`),children:(0,R.jsxs)(`div`,{className:ym.bubble,children:[(0,R.jsx)(`span`,{className:ym.dot}),(0,R.jsx)(`span`,{className:ym.dot}),(0,R.jsx)(`span`,{className:ym.dot})]})})}var xm={btn:`_btn_15vac_4`,primary:`_primary_15vac_27`,ghost:`_ghost_15vac_37`};function Sm({variant:e=`primary`,type:t=`button`,className:n,...r}){return(0,R.jsx)(`button`,{type:t,className:B(xm.btn,xm[e],n),...r})}var Cm={page:`_page_1h2j9_5`,nav:`_nav_1h2j9_11`,header:`_header_1h2j9_21`,eyebrow:`_eyebrow_1h2j9_30`,title:`_title_1h2j9_38`,subline:`_subline_1h2j9_46`,sections:`_sections_1h2j9_56`,section:`_section_1h2j9_56`,sectionHead:`_sectionHead_1h2j9_71`,sectionLabel:`_sectionLabel_1h2j9_77`,sectionNote:`_sectionNote_1h2j9_85`,center:`_center_1h2j9_91`,lockWrap:`_lockWrap_1h2j9_100`,segmented:`_segmented_1h2j9_107`,segment:`_segment_1h2j9_107`,segmentActive:`_segmentActive_1h2j9_127`,lockScreen:`_lockScreen_1h2j9_132`,lockEvening:`_lockEvening_1h2j9_151`,lockTop:`_lockTop_1h2j9_157`,lockDate:`_lockDate_1h2j9_164`,lockTime:`_lockTime_1h2j9_170`,notif:`_notif_1h2j9_178`,notifIcon:`_notifIcon_1h2j9_190`,notifCaret:`_notifCaret_1h2j9_201`,notifBody:`_notifBody_1h2j9_208`,notifHead:`_notifHead_1h2j9_215`,notifApp:`_notifApp_1h2j9_222`,notifTime:`_notifTime_1h2j9_230`,notifText:`_notifText_1h2j9_237`,threadWrap:`_threadWrap_1h2j9_246`,phone:`_phone_1h2j9_253`,screen:`_screen_1h2j9_263`,threadHeader:`_threadHeader_1h2j9_273`,thread:`_thread_1h2j9_246`,divider:`_divider_1h2j9_288`,driftRow:`_driftRow_1h2j9_308`,controls:`_controls_1h2j9_314`,qr:`_qr_1h2j9_321`,chips:`_chips_1h2j9_334`,chipsLabel:`_chipsLabel_1h2j9_341`,chip:`_chip_1h2j9_334`,reset:`_reset_1h2j9_368`},wm=`morning. before you open anything else â what are the 3 things that actually move the needle today? not busywork. the 3 that scare you a little.`,Tm=`ship the landing page, email the 2 leads, fix the auth bug`,Em=`good. landing page is the one that matters â do it first while your brain is fresh. the auth bug is comfort work, you'll hide in it.`,Dm=[`ship the landing page`,`email the 2 leads`,`fix the auth bug`],Om=`ship ugly, fix live.`,km=`end of day. what actually got done?`,Am=`landing page's live, fixed the bug. didn't email the leads`,jm=`landing's shipped â that's the big one, respect. but the leads? that's 3 days now you've dodged the exact same task. that's not "no time", it's avoidance. it's 2 emails. you're scared of the reply. send them before you sleep or it becomes tomorrow's number 1 â and we talk about why.`,Mm=[{kind:`bubble`,from:`crew`,text:wm},{kind:`bubble`,from:`user`,text:Tm},{kind:`bubble`,from:`crew`,text:Em},{kind:`locked`,priorities:Dm},{kind:`clarity`,line:Om},{kind:`divider`,label:`8:30 PM`},{kind:`bubble`,from:`crew`,text:km},{kind:`bubble`,from:`user`,text:Am},{kind:`drift`,tag:`DRIFT â 3 days`},{kind:`bubble`,from:`crew`,text:jm}],Nm=[{id:`skipped`,label:Am,reply:jm,drift:!0},{id:`allthree`,label:`all three. even the leads.`,reply:`all three â even the leads. respect, that's the streak unbroken. don't get cocky on me: same again tomorrow.`,drift:!1},{id:`rough`,label:`rough day. just the bug.`,reply:`the bug was comfort work and you know it. the leads are still sitting there. one email tonight, before you sleep â then we're even.`,drift:!0}],Pm=950,Fm=420,Im=620,Lm={pingMode:`morning`,threadComplete:!1,replyId:null};function Rm(){let e=z(),t=pu(),[n,r]=(0,_.useState)(()=>br(yr.loop,Lm));return(0,_.useEffect)(()=>{xr(yr.loop,n)},[n]),(0,R.jsxs)(`div`,{className:Cm.page,children:[(0,R.jsxs)(`nav`,{className:Cm.nav,children:[(0,R.jsx)(El,{size:24}),(0,R.jsx)(fm,{})]}),(0,R.jsxs)(`header`,{className:Cm.header,children:[(0,R.jsx)(`span`,{className:Cm.eyebrow,children:e(`The daily loop`)}),(0,R.jsx)(`h1`,{className:Cm.title,children:e(`One day, accounted for.`)}),(0,R.jsx)(`p`,{className:Cm.subline,children:e(`Crew pings at 7:30, locks your top 3, hands you one line of clarity â then at 8:30 it accounts for what you actually did and calls out the drift.`)})]}),(0,R.jsxs)(`div`,{className:Cm.sections,children:[(0,R.jsxs)(`section`,{className:Cm.section,children:[(0,R.jsxs)(`div`,{className:Cm.sectionHead,children:[(0,R.jsx)(`span`,{className:Cm.sectionLabel,children:e(`01 · the ping`)}),(0,R.jsx)(`span`,{className:Cm.sectionNote,children:e(`it lands on your lock screen. morning to set the 3, evening to account for them.`)})]}),(0,R.jsx)(zm,{mode:n.pingMode,onMode:e=>r(t=>({...t,pingMode:e}))})]}),(0,R.jsxs)(`section`,{className:Cm.section,children:[(0,R.jsxs)(`div`,{className:Cm.sectionHead,children:[(0,R.jsx)(`span`,{className:Cm.sectionLabel,children:e(`02 · the thread`)}),(0,R.jsx)(`span`,{className:Cm.sectionNote,children:e(`the whole day, start to finish. play it.`)})]}),(0,R.jsx)(Bm,{reduced:t,complete:n.threadComplete,onComplete:()=>r(e=>e.threadComplete?e:{...e,threadComplete:!0})})]}),(0,R.jsxs)(`section`,{className:Cm.section,children:[(0,R.jsxs)(`div`,{className:Cm.sectionHead,children:[(0,R.jsx)(`span`,{className:Cm.sectionLabel,children:e(`03 · the evening reply`)}),(0,R.jsx)(`span`,{className:Cm.sectionNote,children:e(`tap what actually got done. Crew accounts for it.`)})]}),(0,R.jsx)(Hm,{reduced:t,replyId:n.replyId,onReply:e=>r(t=>({...t,replyId:e}))})]})]})]})}function zm({mode:e,onMode:t}
65){let n=z(),r=e===`morning`;return(0,R.jsxs)(`div`,{className:Cm.lockWrap,children:[(0,R.jsxs)(`div`,{className:Cm.segmented,role:`tablist`,"aria-label":n(`Ping time`),children:[(0,R.jsx)(`button`,{type:`button`,role:`tab`,"aria-selected":r,className:B(Cm.segment,r&&Cm.segmentActive),onClick:()=>t(`morning`),children:n(`Morning`)}),(0,R.jsx)(`button`,{type:`button`,role:`tab`,"aria-selected":!r,className:B(Cm.segment,!r&&Cm.segmentActive),onClick:()=>t(`evening`),children:n(`Evening`)})]}),(0,R.jsxs)(`div`,{className:B(Cm.lockScreen,!r&&Cm.lockEvening),children:[(0,R.jsxs)(`div`,{className:Cm.lockTop,children:[(0,R.jsx)(`span`,{className:Cm.lockDate,children:n(`Tuesday, June 9`)}),(0,R.jsx)(`span`,{className:Cm.lockTime,children:r?`7:30`:`8:30`})]}),(0,R.jsxs)(`div`,{className:Cm.notif,children:[(0,R.jsx)(`div`,{className:Cm.notifIcon,"aria-hidden":!0,children:(0,R.jsx)(`span`,{className:Cm.notifCaret})}),(0,R.jsxs)(`div`,{className:Cm.notifBody,children:[(0,R.jsxs)(`div`,{className:Cm.notifHead,children:[(0,R.jsx)(`span`,{className:Cm.notifApp,children:`crew`}),(0,R.jsx)(`span`,{className:Cm.notifTime,children:n(r?`7:30 AM`:`8:30 PM`)})]}),(0,R.jsx)(`span`,{className:Cm.notifText,children:n(r?wm:km)})]})]})]})]})}function Bm({reduced:e,complete:t,onComplete:n}){let r=z(),i=Mm,[a,o]=(0,_.useState)(e||t?i.length:0),[s,c]=(0,_.useState)(!1),[l,u]=(0,_.useState)(!1),d=(0,_.useRef)([]),f=()=>{d.current.forEach(e=>clearTimeout(e)),d.current=[]},p=()=>{if(f(),e){o(i.length),c(!1),u(!1),n();return}u(!0),c(!1),o(0);let t=0,r=()=>{if(t>=i.length){u(!1),c(!1),n();return}let e=i[t];if(e.kind===`bubble`&&e.from===`crew`)c(!0),d.current.push(window.setTimeout(()=>{c(!1),o(t+1),t+=1,d.current.push(window.setTimeout(r,Fm))},Pm));else{o(t+1),t+=1;let n=e.kind===`bubble`?Im:Fm;d.current.push(window.setTimeout(r,n))}};d.current.push(window.setTimeout(r,350))};(0,_.useEffect)(()=>(!e&&!t&&p(),f),[]);let m=a>=i.length&&!l;return(0,R.jsxs)(`div`,{className:Cm.threadWrap,children:[(0,R.jsx)(`div`,{className:Cm.phone,children:(0,R.jsxs)(`div`,{className:Cm.screen,children:[(0,R.jsx)(`div`,{className:Cm.threadHeader,children:(0,R.jsx)(El,{size:18})}),(0,R.jsxs)(`div`,{className:Cm.thread,children:[i.slice(0,a).map((e,t)=>(0,R.jsx)(Vm,{item:e},t)),s&&(0,R.jsx)(bm,{})]})]})}),(0,R.jsx)(`div`,{className:Cm.controls,children:(0,R.jsx)(Sm,{variant:`primary`,onClick:p,disabled:l,children:r(l?`playingâ¦`:m?`â» replay the day`:`â¶ play the day`)})})]})}function Vm({item:e}){let t=z();switch(e.kind){case`bubble`:return(0,R.jsx)(Al,{from:e.from,children:t(e.text)});case`locked`:return(0,R.jsx)(Ml,{priorities:e.priorities.map(t)});case`clarity`:return(0,R.jsx)(gm,{line:t(e.line)});case`divider`:return(0,R.jsx)(`div`,{className:Cm.divider,children:t(e.label)});case`drift`:return(0,R.jsx)(`div`,{className:Cm.driftRow,children:(0,R.jsx)(vm,{children:t(e.tag)})})}}function Hm({reduced:e,replyId:t,onReply:n}){let r=z(),i=Nm.find(e=>e.id===t)??null,[a,o]=(0,_.useState)(!1),[s,c]=(0,_.useState)(!!t),l=(0,_.useRef)(void 0);(0,_.useEffect)(()=>()=>{l.current&&clearTimeout(l.current)},[]);let u=t=>{if(l.current&&clearTimeout(l.current),n(t),e){o(!1),c(!0);return}c(!1),o(!0),l.current=window.setTimeout(()=>{o(!1),c(!0)},Pm)};return(0,R.jsxs)(`div`,{className:Cm.qr,children:[(0,R.jsx)(Al,{from:`crew`,children:r(km)}),i?(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(Al,{from:`user`,children:r(i.label)}),a&&(0,R.jsx)(bm,{}),s&&(0,R.jsxs)(R.Fragment,{children:[i.drift&&(0,R.jsx)(`div`,{className:Cm.driftRow,children:(0,R.jsx)(vm,{children:r(`DRIFT â 3 days`)})}),(0,R.jsx)(Al,{from:`crew`,children:r(i.reply)}),(0,R.jsx)(`button`,{type:`button`,className:Cm.reset,onClick:()=>{l.current&&clearTimeout(l.current),o(!1),c(!1),n(null)},children:r(`â» try another answer`)})]})]}):(0,R.jsxs)(`div`,{className:Cm.chips,children:[(0,R.jsx)(`span`,{className:Cm.chipsLabel,children:r(`tap your answer`)}),Nm.map(e=>(0,R.jsx)(`button`,{type:`button`,className:Cm.chip,onClick:()=>u(e.id),children:r(e.label)},e.id))]})]})}var Um={activity:`M22 12h-4l-3 9L9 3l-3 9H2`,grid:`M3 3h7v7H3z M14 3h7v7h-7z M14 14h7v7h-7z M3 14h7v7H3z`,target:`M12 22a10 10 0 1 0 0-20 10 10 0 0 0 0 20z M12 18a6 6 0 1 0 0-12 6 6 0 0 0 0 12z M12 14a2 2 0 1 0 0-4 2 2 0 0 0 0 4z`,layers:`M12 2 2 7l10 5 10-5-10-5z M2 17l10 5 10-5 M2 12l10 5 10-5`,flame:`M8.5 14.5A2.5 2.5 0 0 0 11 12c0-1.38-.5-2-1-3-1.072-2.143-.224-4.054 2-6 .5 2.5 2 4.9 4 6.5 2 1.6 3 3.5 3 5.5a7 7 0 1 1-14 0c0-1.153.433-2.294 1-3a2.5 2.5 0 0 0 2.5 2.5z`,chat:`M7.9 20A9 9 0 1 0 4 16.1L2 22z`,settings:`M12 15a3 3 0 1 0 0-6 3 3 0 0 0 0 6z M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z`,search:`M11 3a8 8 0 1 0 0 16 8 8 0 0 0 0-16z M21 21l-4.35-4.35`,lock:`M19 11H5a2 2 0 0 0-2 2v7a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7a2 2 0 0 0-2-2z M7 11V7a5 5 0 0 1 10 0v4`,bell:`M18 8A6 6 0 0 0 6 8c0 7-3 9-3 9h18s-3-2-3-9 M13.73 21a2 2 0 0 1-3.46 0`,chevronRight:`M9 18l6-6-6-6`,chevronDown:`M6 9l6 6 6-6`,x:`M18 6 6 18 M6 6l12 12`,check:`M20 6 9 17l-5-5`,arrowRight:`M5 12h14 M12 5l7 7-7 7`,github:`M9 19c-5 1.5-5-2.5-7-3m14 6v-3.87a3.37 3.37 0 0 0-.94-2.61c3.14-.35 6.44-1.54 6.44-7A5.44 5.44 0 0 0 20 4.77 5.07 5.07 0 0 0 19.91 1S18.73.65 16 2.48a13.38 13.38 0 0 0-7 0C6.27.65 5.09 1 5.09 1A5.07 5.07 0 0 0 5 4.77a5.44 5.44 0 0 0-1.5 3.78c0 5.42 3.3 6.61 6.44 7A3.37 3.37 0 0 0 9 18.13V22`,calendar:`M8 2v4 M16 2v4 M3 8h18 M5 4h14a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2z`,zap:`M13 2 3 14h9l-1 8 10-12h-9l1-8z`,trendDown:`M23 18l-9.5-9.5-5 5L1 6`,trendUp:`M23 6l-9.5 9.5-5-5L1 18`,arrowUp:`M12 19V5 M5 12l7-7 7 7`,arrowDown:`M12 5v14 M19 12l-7 7-7-7`,xCircle:`M12 22a10 10 0 1 0 0-20 10 10 0 0 0 0 20z M15 9l-6 6 M9 9l6 6`,minus:`M5 12h14`,plus:`M12 5v14 M5 12h14`,user:`M20 21v-2a4 4 0 0 0-4-4H8a4 4 0 0 0-4 4v2 M12 11a4 4 0 1 0 0-8 4 4 0 0 0 0 8z`,eye:`M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z M12 15a3 3 0 1 0 0-6 3 3 0 0 0 0 6z`,eyeOff:`M17.94 17.94A10.07 10.07 0 0 1 12 20c-7 0-11-8-11-8a18.45 18.45 0 0 1 5.06-5.94 M9.9 4.24A9.12 9.12 0 0 1 12 4c7 0 11 8 11 8a18.5 18.5 0 0 1-2.16 3.19m-6.72-1.07a3 3 0 1 1-4.24-4.24 M1 1l22 22`,git:`M6 3v12 M18 9a3 3 0 1 0 0-6 3 3 0 0 0 0 6z M6 21a3 3 0 1 0 0-6 3 3 0 0 0 0 6z M15 6a9 9 0 0 1-9 9`,gitCommit:`M16 12a4 4 0 0 1-8 0 4 4 0 0 1 8 0z M1.05 12H7 M17.01 12h5.95`,deploy:`M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4 M17 8l-5-5-
655 5 M12 3v12`,clock:`M12 22a10 10 0 1 0 0-20 10 10 0 0 0 0 20z M12 6v6l4 2`,refresh:`M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8 M21 3v5h-5 M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16 M8 16H3v5`,externalLink:`M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h3 M15 3h6v6 M10 14L21 3`,move:`M5 9l-3 3 3 3 M9 5l3-3 3 3 M15 19l-3 3-3-3 M19 9l3 3-3 3 M2 12h20 M12 2v20`,slash:`M22 2 2 22`,skipForward:`M5 4l10 8-10 8V4z M19 5v14`,users:`M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2 M13 7a4 4 0 1 1-8 0 4 4 0 0 1 8 0 M22 21v-2a4 4 0 0 0-3-3.87 M16 3.13a4 4 0 0 1 0 7.75`,edit:`M11 4H4a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7 M18.5 2.5a2.12 2.12 0 0 1 3 3L12 15l-4 1 1-4z`,mic:`M12 1a3 3 0 0 0-3 3v8a3 3 0 0 0 6 0V4a3 3 0 0 0-3-3z M19 10v2a7 7 0 0 1-14 0v-2 M12 19v4 M8 23h8`,bug:`M9 21v-4 M15 21v-4 M8 9h8a4 4 0 0 1 4 4v2a6 6 0 0 1-12 0v-2a4 4 0 0 1 4-4z M4 12h4 M16 12h4 M7 6l-2-2 M17 6l2-2 M12 9V6a2 2 0 0 1 2-2h0a2 2 0 0 1 2 2`};function Wm({name:e,size:t=16,className:n,"aria-hidden":r=!0}){return(0,R.jsx)(`svg`,{width:t,height:t,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:1.75,strokeLinecap:`round`,strokeLinejoin:`round`,className:n,"aria-hidden":r,children:(0,R.jsx)(`path`,{d:Um[e]??``})})}var Gm={page:`_page_jo42d_1`,header:`_header_jo42d_8`,brand:`_brand_jo42d_18`,headerLink:`_headerLink_jo42d_20`,main:`_main_jo42d_27`,title:`_title_jo42d_36`,lede:`_lede_jo42d_43`,card:`_card_jo42d_50`,cardTitle:`_cardTitle_jo42d_60`,primaryBtn:`_primaryBtn_jo42d_67`,secondaryBtn:`_secondaryBtn_jo42d_68`,subLabel:`_subLabel_jo42d_98`,divider:`_divider_jo42d_105`,note:`_note_jo42d_107`,meta:`_meta_jo42d_114`,steps:`_steps_jo42d_121`,stepText:`_stepText_jo42d_133`,copyRow:`_copyRow_jo42d_138`,address:`_address_jo42d_146`,copyBtn:`_copyBtn_jo42d_157`,warn:`_warn_jo42d_170`,link:`_link_jo42d_180`,footer:`_footer_jo42d_183`},Km={version:`0.9.20`,page:`https://www.meetcrew.app/extension`,zip:`https://www.meetcrew.app/crew-companion.zip`}.version,qm=`/crew-companion.zip`;function Jm(){let e=z(),[t,n]=(0,_.useState)(!1);async function r(){try{await navigator.clipboard.writeText(`chrome://extensions`),n(!0),setTimeout(()=>n(!1),2e3)}catch{}}let i=(0,R.jsxs)(`a`,{className:Gm.primaryBtn,href:qm,download:!0,children:[(0,R.jsx)(Wm,{name:`arrowDown`,size:15}),e(`download the extension (.zip)`)]});return(0,R.jsxs)(`div`,{className:Gm.page,children:[(0,R.jsxs)(`header`,{className:Gm.header,children:[(0,R.jsx)(Rn,{to:`/`,className:Gm.brand,children:(0,R.jsx)(El,{size:20})}),(0,R.jsx)(Rn,{to:`/app/settings`,className:Gm.headerLink,children:e(`settings`)})]}),(0,R.jsxs)(`main`,{className:Gm.main,children:[(0,R.jsx)(`h1`,{className:Gm.title,children:e(`install crew companion`)}),(0,R.jsx)(`p`,{className:Gm.lede,children:e(`the browser extension that verifies a task from the page you're already on â one click, no self-reporting. read-only: it never posts, sends, or acts as you.`)}),(0,R.jsxs)(`section`,{className:Gm.card,children:[(0,R.jsx)(`h2`,{className:Gm.cardTitle,children:e(`1. get the extension`)}),(0,R.jsxs)(R.Fragment,{children:[i,(0,R.jsx)(`p`,{className:Gm.note,children:e(`not on the chrome web store yet, so this is the manual install â two minutes, once.`)})]}),(0,R.jsx)(`p`,{className:Gm.meta,children:e(`version {v} · chrome, edge, brave, arc, atlas`).replace(`{v}`,Km)})]}),(0,R.jsxs)(`section`,{className:Gm.card,children:[(0,R.jsx)(`h2`,{className:Gm.cardTitle,children:e(`2. load it into your browser`)}),(0,R.jsxs)(`ol`,{className:Gm.steps,children:[(0,R.jsx)(`li`,{children:(0,R.jsx)(`span`,{className:Gm.stepText,children:e(`unzip the file you just downloaded â you get a folder called "crew-companion".`)})}),(0,R.jsxs)(`li`,{children:[(0,R.jsx)(`span`,{className:Gm.stepText,children:e(`copy this address, paste it into your browser's address bar, and press enter:`)}),(0,R.jsxs)(`div`,{className:Gm.copyRow,children:[(0,R.jsx)(`code`,{className:Gm.address,children:`chrome://extensions`}),(0,R.jsx)(`button`,{type:`button`,className:Gm.copyBtn,onClick:r,children:e(t?`copied â`:`copy`)})]}),(0,R.jsx)(`span`,{className:Gm.warn,children:e(`this one can't be a clickable link â chrome blocks web pages from opening chrome:// addresses, so it has to be pasted by hand. on edge it's edge://extensions, on brave brave://extensions.`)})]}),(0,R.jsx)(`li`,{children:(0,R.jsx)(`span`,{className:Gm.stepText,children:e(`turn on "Developer mode" â the switch in the top-right corner of that page.`)})}),(0,R.jsx)(`li`,{children:(0,R.jsx)(`span`,{className:Gm.stepText,children:e(`click "Load unpacked" â top-left, it only appears once developer mode is on.`)})}),(0,R.jsx)(`li`,{children:(0,R.jsx)(`span`,{className:Gm.stepText,children:e(`pick the "crew-companion" folder â the one with manifest.json inside it. the extension now shows up in your extensions list.`)})})]})]}),(0,R.jsxs)(`section`,{className:Gm.card,children:[(0,R.jsx)(`h2`,{className:Gm.cardTitle,children:e(`3. connect it to your account`)}),(0,R.jsxs)(`p`,{className:Gm.note,children:[e(`open the extension's options page, paste your connector token in, and hit save. the token â with a copy button â lives in`),` `,(0,R.jsx)(Rn,{className:Gm.link,to:`/app/sett
65ings`,children:e(`settings â connectors`)}),`.`]}),(0,R.jsx)(`p`,{className:Gm.meta,children:e(`that token is the only thing connecting the extension to your account. it stays in this browser's local storage, is never synced, and you can regenerate it any time from settings.`)})]}),(0,R.jsxs)(`section`,{className:Gm.card,children:[(0,R.jsx)(`h2`,{className:Gm.cardTitle,children:e(`4. optional: check from ANY app (mac)`)}),(0,R.jsx)(`p`,{className:Gm.note,children:e(`a browser shortcut only works while the browser has focus â that's a browser rule no extension can break. the Shortcuts app breaks it for us: a system-wide hotkey that captures with macOS's own picker (click any window, of any app) and sends it straight to Crew's judge. build it once:`)}),(0,R.jsxs)(`ol`,{className:Gm.steps,children:[(0,R.jsx)(`li`,{children:(0,R.jsx)(`span`,{className:Gm.stepText,children:e(`open the Shortcuts app â new shortcut â name it "Crew Check".`)})}),(0,R.jsx)(`li`,{children:(0,R.jsx)(`span`,{className:Gm.stepText,children:e(`add the action "Take Screenshot" â Show More â pick "Interactive". (while capturing, press Space to switch to window mode and click any app's window.)`)})}),(0,R.jsx)(`li`,{children:(0,R.jsx)(`span`,{className:Gm.stepText,children:e(`add "Base64 Encode" â its input is the screenshot.`)})}),(0,R.jsx)(`li`,{children:(0,R.jsx)(`span`,{className:Gm.stepText,children:e(`add "Dictionary" with 4 entries: token = your connector token (Text) · auto = true (Boolean) · imageBase64 = the Base64 Encoded result (Text, pick the variable) · mediaType = image/png (Text).`)})}),(0,R.jsx)(`li`,{children:(0,R.jsxs)(`span`,{className:Gm.stepText,children:[e(`add "Get Contents of URL": method POST, request body JSON = the Dictionary, URL:`),` `,(0,R.jsx)(`code`,{className:Gm.code,children:`https://zwqymcoehifdzniztfzc.supabase.co/functions/v1/extension-manual-check`})]})}),(0,R.jsx)(`li`,{children:(0,R.jsx)(`span`,{className:Gm.stepText,children:e(`add "Get Dictionary Value" for the key "notification", then "Show Notification" with that value.`)})}),(0,R.jsx)(`li`,{children:(0,R.jsx)(`span`,{className:Gm.stepText,children:e(`open the shortcut's details (â) â "Add Keyboard Shortcut" â pick one, e.g. ââ§V. it now works from ANY app.`)})})]}),(0,R.jsx)(`p`,{className:Gm.meta,children:e(`press the hotkey in any app, click the window that shows your work, and the verdict arrives as a notification: â with the reason, â with what was missing, or ? when Crew can't tell which task it proves. macOS will ask once for Screen Recording permission for Shortcuts â that's the OS, and it's the only ask.`)})]}),(0,R.jsx)(`p`,{className:Gm.footer,children:(0,R.jsx)(Rn,{className:Gm.link,to:`/app/settings`,children:e(`â back to crew`)})})]})]})}async function Ym(e,t){let{data:n,error:r}=await L.functions.invoke(e,t?{body:t}:void 0);if(!r)return{data:n};let i=r.context;try{let e=await i?.clone().json(),t=e?.error??e?.message;if(t)return{error:t,status:i?.status}}catch{}return{error:r.message??String(r),status:i?.status}}async function Xm(e){return Ym(`crew-propose`,{scope:`day`,count:e})}async function Zm(e,t){return Ym(`crew-propose`,{scope:`milestone`,milestoneId:e,count:t})}async function Qm(){let e=await Ym(`composio`,{action:`import_candidates`});if(e.error)return{error:e.error};let t=e.data?.candidates??[];return{data:{proposals:t.map(e=>({text:e.text,category:`build`})),sources:t.map(e=>e.source),connected:e.data?.connected??[],scope:`import`,objective:``,basedOn:{recentTasks:0,connectors:e.data?.connected??[],avoiding:[]}}}}var $m={wrap:`_wrap_1ds5a_5`,trigger:`_trigger_1ds5a_7`,triggerOpen:`_triggerOpen_1ds5a_23`,triggerCompact:`_triggerCompact_1ds5a_27`,triggerLabel:`_triggerLabel_1ds5a_29`,icon:`_icon_1ds5a_30`,panel:`_panel_1ds5a_32`,controls:`_controls_1ds5a_48`,ctrlLabel:`_ctrlLabel_1ds5a_49`,counts:`_counts_1ds5a_58`,chip:`_chip_1ds5a_60`,chipOn:`_chipOn_1ds5a_71`,genBtn:`_genBtn_1ds5a_73`,addBtn:`_addBtn_1ds5a_73`,list:`_list_1ds5a_87`,item:`_item_1ds5a_97`,pick:`_pick_1ds5a_99`,pickOn:`_pickOn_1ds5a_110`,itemText:`_itemText_1ds5a_112`,basis:`_basis_1ds5a_120`,error:`_error_1ds5a_127`,itemCat:`_itemCat_1ds5a_143`};function eh({scope:e,milestoneId:t,defaultCount:n=3,label:r,compact:i,onAccept:a,mode:o=`generate`}
65){let s=z(),c=(0,_.useId)(),l=(0,_.useRef)(null),[u,d]=(0,_.useState)(!1),[f,p]=(0,_.useState)(n),[m,h]=(0,_.useState)(`today`),[g,v]=(0,_.useState)(!1),[y,b]=(0,_.useState)(``),[x,S]=(0,_.useState)(null),[C,w]=(0,_.useState)(new Set),[T,E]=(0,_.useState)(!1);async function D(){v(!0),b(``),S(null),w(new Set);let n=o===`import`?await Qm():e===`milestone`&&t?await Zm(t,f):await Xm(f);if(v(!1),n.error){b(n.error);return}if(!n.data||n.data.proposals.length===0){b(s(o===`import`?`nothing open to import â connect Linear, Notion, Asana, ClickUp or Jira in Settings first.`:`nothing to propose yet â set a goal first, or lock a few days so there is a pattern to build on.`));return}S(n.data),w(new Set)}async function O(){if(!(!x||C.size===0)){E(!0);try{await a([...C].sort((e,t)=>e-t).map(e=>x.proposals[e]),m),d(!1),S(null),w(new Set)}catch(e){b(e instanceof Error?e.message:String(e))}finally{E(!1)}}}(0,_.useEffect)(()=>{if(!u)return;let e=e=>{e.detail!==c&&d(!1)},t=e=>{l.current?.contains(e.target)||d(!1)},n=e=>{e.key===`Escape`&&d(!1)};return window.dispatchEvent(new CustomEvent(`crew:propose-open`,{detail:c})),window.addEventListener(`crew:propose-open`,e),document.addEventListener(`mousedown`,t),document.addEventListener(`keydown`,n),()=>{window.removeEventListener(`crew:propose-open`,e),document.removeEventListener(`mousedown`,t),document.removeEventListener(`keydown`,n)}},[u,c]);function k(e){w(t=>{let n=new Set(t);return n.has(e)?n.delete(e):n.add(e),n})}return(0,R.jsxs)(`div`,{className:$m.wrap,ref:l,children:[(0,R.jsxs)(`button`,{type:`button`,className:B($m.trigger,i&&$m.triggerCompact,u&&$m.triggerOpen),"aria-expanded":u,title:s(o===`import`?`import from your tools`:e===`milestone`?`generate tasks for this milestone`:`generate tasks`),onClick:()=>{d(e=>!e),b(``)},children:[(0,R.jsx)(th,{}),r&&(0,R.jsx)(`span`,{className:$m.triggerLabel,children:r})]}),u&&(0,R.jsxs)(`div`,{className:$m.panel,role:`dialog`,children:[o!==`import`&&(0,R.jsxs)(`div`,{className:$m.controls,children:[(0,R.jsx)(`span`,{className:$m.ctrlLabel,children:s(`how many`)}),(0,R.jsx)(`div`,{className:$m.counts,children:[1,2,3,5,7].map(e=>(0,R.jsx)(`button`,{type:`button`,className:B($m.chip,f===e&&$m.chipOn),onClick:()=>p(e),children:e},e))})]}),(0,R.jsxs)(`div`,{className:$m.controls,children:[(0,R.jsx)(`span`,{className:$m.ctrlLabel,children:s(`for`)}),(0,R.jsx)(`div`,{className:$m.counts,children:[`today`,`tomorrow`].map(e=>(0,R.jsx)(`button`,{type:`button`,className:B($m.chip,m===e&&$m.chipOn),onClick:()=>h(e),children:s(e)},e))})]}),(0,R.jsx)(`button`,{type:`button`,className:$m.genBtn,onClick:D,disabled:g,children:s(g?o===`import`?`reading your toolsâ¦`:`thinkingâ¦`:x?`try again`:o===`import`?`find open work`:`generate tasks`)}),y&&(0,R.jsx)(`p`,{className:$m.error,children:y}),x&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`ul`,{className:$m.list,children:x.proposals.map((e,t)=>(0,R.jsxs)(`li`,{className:$m.item,children:[(0,R.jsx)(`button`,{type:`button`,className:B($m.pick,C.has(t)&&$m.pickOn),onClick:()=>k(t),"aria-pressed":C.has(t),children:C.has(t)?`â`:`+`}),(0,R.jsxs)(`span`,{className:$m.itemText,children:[(0,R.jsx)(`span`,{className:$m.itemCat,children:e.category}),e.text]})]},t))}),(0,R.jsxs)(`p`,{className:$m.basis,children:[s(`from your goal, your last {n} tasks`).replace(`{n}`,String(x.basedOn.recentTasks)),x.basedOn.connectors.length>0?s(`, and what {c} can verify`).replace(`{c}`,x.basedOn.connectors.join(`, `)):s(`, and no connected tools yet`),x.basedOn.avoiding.length>0&&s(` · it knows what you have been skipping`)]}),(0,R.jsx)(`button`,{type:`button`,className:$m.addBtn,onClick:O,disabled:C.size===0||T,children:T?s(`addingâ¦`):C.size===0?s(`pick the ones you want`):s(`add {n} to {when}`).replace(`{n}`,String(C.size)).replace(`{when}`,s(m))})]})]})]})}function th(){return(0,R.jsxs)(`svg`,{viewBox:`0 0 16 16`,width:`13`,height:`13`,"aria-hidden":!0,className:$m.icon,children:[(0,R.jsx)(`path`,{d:`M8 1.5l1.3 3.6 3.6 1.3-3.6 1.3L8 11.3 6.7 7.7 3.1 6.4l3.6-1.3z`,fill:`currentColor`}),(0,R.jsx)(`path`,{d:`M12.6 10.2l.6 1.6 1.6.6-1.6.6-.6 1.6-.6-1.6-1.6-.
656 1.6-.6z`,fill:`currentColor`,opacity:`0.65`})]})}async function nh(e,t){return L.auth.signInWithPassword({email:e,password:t})}async function rh(e,t){let n=await L.auth.signUp({email:e,password:t});return n.error||(Yl(`Signup`,{method:`email`}),n.data.user&&rl(n.data.user.id,`signup`,{method:`email`})),n}async function ih(){let e=window.location.origin;return Yl(`Signup`,{method:`github`}),L.auth.signInWithOAuth({provider:`github`,options:{redirectTo:`${e}/app`,scopes:`read:user user:email`}})}async function ah(){let e=window.location.origin;return Yl(`Signup`,{method:`google`}),L.auth.signInWithOAuth({provider:`google`,options:{redirectTo:`${e}/app`}})}async function oh(){return L.auth.signOut()}async function sh(e){return L.auth.resetPasswordForEmail(e,{redirectTo:`${window.location.origin}/auth/reset`})}async function ch(e,t){let n=await L.from(`profiles`).update({...t,onboarded_at:new Date().toISOString(),updated_at:new Date().toISOString()}).eq(`id`,e);return n.error||rl(e,`profile_updated`,{fields:[...Object.keys(t),`onboarded_at`]}),n}var lh={bar:`_bar_5vcm5_5`,tab:`_tab_5vcm5_21`,tabActive:`_tabActive_5vcm5_43`,sheetBackdrop:`_sheetBackdrop_5vcm5_47`,sheet:`_sheet_5vcm5_47`,sheetUp:`_sheetUp_5vcm5_1`,sheetHandle:`_sheetHandle_5vcm5_74`,sheetItem:`_sheetItem_5vcm5_83`,sheetItemActive:`_sheetItemActive_5vcm5_98`,sheetSignOut:`_sheetSignOut_5vcm5_100`},uh=[{to:`/app/goals`,icon:`target`,label:`Goals`},{to:`/app/review`,icon:`layers`,label:`Review`},{to:`/app/calendar`,icon:`calendar`,label:`Calendar`},{to:`/app/crew`,icon:`users`,label:`Pod`},{to:`/app/feedback`,icon:`bug`,label:`Feedback`},{to:`/app/settings`,icon:`settings`,label:`Settings`}];function dh(){let e=z(),t=ut(),n=pt(),[r,i]=(0,_.useState)(!1);async function a(){i(!1),await oh(),n(`/`,{replace:!0})}(0,_.useEffect)(()=>{i(!1)},[t.pathname]);let o=uh.some(e=>t.pathname.startsWith(e.to)),s=(e,t,n)=>(0,R.jsxs)(zn,{to:e,className:({isActive:e})=>B(lh.tab,e&&lh.tabActive),onClick:()=>i(!1),children:[(0,R.jsx)(Wm,{name:t,size:20}),(0,R.jsx)(`span`,{children:n})]});return(0,R.jsxs)(R.Fragment,{children:[r&&(0,R.jsx)(`div`,{className:lh.sheetBackdrop,onClick:()=>i(!1),children:(0,R.jsxs)(`nav`,{className:lh.sheet,onClick:e=>e.stopPropagation(),"aria-label":e(`more pages`),children:[(0,R.jsx)(`span`,{className:lh.sheetHandle,"aria-hidden":!0}),uh.map(n=>(0,R.jsxs)(Rn,{to:n.to,className:B(lh.sheetItem,t.pathname.startsWith(n.to)&&lh.sheetItemActive),children:[(0,R.jsx)(Wm,{name:n.icon,size:18}),e(n.label)]},n.to)),(0,R.jsxs)(`button`,{type:`button`,className:B(lh.sheetItem,lh.sheetSignOut),onClick:a,children:[(0,R.jsx)(Wm,{name:`arrowRight`,size:18}),e(`sign out`)]})]})}),(0,R.jsxs)(`nav`,{className:lh.bar,"aria-label":e(`primary`),children:[s(`/today`,`lock`,e(`Today`)),s(`/app/dashboard`,`activity`,e(`Dashboard`)),s(`/app/chat`,`chat`,e(`Chat`)),s(`/app/streak`,`flame`,e(`Streak`)),(0,R.jsxs)(`button`,{type:`button`,className:B(lh.tab,(r||o)&&lh.tabActive),onClick:()=>i(e=>!e),"aria-expanded":r,children:[(0,R.jsx)(Wm,{name:`grid`,size:20}),(0,R.jsx)(`span`,{children:e(`More`)})]})]})]})}async function fh(e){return L.from(`priority_steps`).select(`*`).eq(`priority_id`,e).order(`position`,{ascending:!0})}async function ph(e){let t={};if(e.length===0)return t;let{data:n}=await L.from(`priority_steps`).select(`priority_id, done`).in(`priority_id`,e);for(let e of n??[]){let n=t[e.priority_id]??(t[e.priority_id]={total:0,done:0});n.total+=1,e.done&&(n.done+=1)}return t}async function mh(e,t,n){return L.from(`priority_steps`).insert({priority_id:e,text:t,position:n}).select().single()}async function hh(e,t){return L.from(`priority_steps`).update({done:t}).eq(`id`,e)}async function gh(e){return L.from(`priority_steps`).delete().eq(`id`,e)}async function _h(e){let t=L,[{data:n},{data:r},{data:i}]=await Promise.all([t.from(`profiles`).select(`rest_weekdays`).eq(`id`,e).maybeSingle(),t.from(`rest_days`).select(`id, date, reason`).eq(`user_id`,e).order(`date`,{ascending:!0}),t.from(`scenario_days`).select(`date, mode`).eq(`user_id`,e).in(`mode`,[`crisis`,`offline`,`travel`])]),a=n?.rest_weekdays??[],o=r??[],s=(i??[]).map(e=>e.date);return{cfg:{weekdays:a,dates:[...new Set([...o.map(e=>e.date),...s])]},weekdays:a,oneOffs:o}}async function vh(e,t){return L.from(`profiles`).update({rest_weekdays:t}).eq(`id`,e)}
65async function yh(e,t,n){return L.from(`rest_days`).upsert({user_id:e,date:t,reason:n},{onConflict:`user_id,date`})}async function bh(e){return L.from(`rest_days`).delete().eq(`id`,e)}function xh(e){let[t,n]=(0,_.useState)({weekdays:[],dates:[]}),[r,i]=(0,_.useState)([]),[a,o]=(0,_.useState)([]),[s,c]=(0,_.useState)(!0),l=(0,_.useCallback)(async()=>{if(!e){n({weekdays:[],dates:[]}),c(!1);return}let t=await _h(e);n(t.cfg),i(t.weekdays),o(t.oneOffs),c(!1)},[e]);return(0,_.useEffect)(()=>{l()},[l]),{cfg:t,weekdays:r,oneOffs:a,loading:s,refresh:l}}async function Sh(e){let{data:t,error:n}=await L.functions.invoke(`composio`,{body:e});if(n)try{let e=await n.context.json();return{error:e.error??n.message,detail:e.detail??e}}catch{return{error:n.message??String(n)}}return t??{}}async function Ch(e,t,n,r){let i=await Sh({action:`verify`,task:e,...t?{category:t}:{},...n?{priorityId:n}:{},...r?{date:r}:{}});return i.ok&&i.matched===!0?{verified:!0,app:i.app||``,evidence:i.evidence||``}:{verified:!1,reason:i.error||`no matching activity found in connected tools`}}async function wh(e){let{data:t,error:n}=await L.functions.invoke(`crew-judge-proof`,{body:e});if(n||!t)return null;let r=t;return r.proofClass?{proofClass:r.proofClass,confidence:typeof r.confidence==`number`?r.confidence:0,message:r.message??``,corroboration:Array.isArray(r.corroboration)?r.corroboration:[],judgmentId:r.judgmentId??null}:null}var Th=L;async function Eh(){let{data:e,error:t}=await L.functions.invoke(`crew-review`,{body:{}}),n=e;return t||n?.error?{content:null,upgrade:n?.upgrade,error:n?.error??`failed`}:{content:n?.content??null}}async function Dh(e){let{data:t}=await Th.from(`reports`).select(`period, period_start, content, created_at`).eq(`user_id`,e).eq(`period`,`weekly`).order(`created_at`,{ascending:!1}).limit(1).maybeSingle();return t??null}var Oh={public_slip:`a public slip on your profile`,pod_notify:`your pod gets notified`,streak_reset_2x:`your streak resets Ã2`};async function kh(e,t,n){return Th.from(`commitments`).upsert({user_id:e,date:t,consequence:n,status:`active`},{onConflict:`user_id,date`})}async function Ah(e,t){let{data:n}=await Th.from(`commitments`).select(`consequence, status`).eq(`user_id`,e).eq(`date`,t).maybeSingle();return n??null}async function jh(e,t){return Th.from(`commitments`).update({status:`broken`}).eq(`user_id`,e).eq(`date`,t).eq(`status`,`active`)}async function Mh(e,t){return Th.from(`commitments`).update({status:`kept`}).eq(`user_id`,e).eq(`date`,t).eq(`status`,`active`)}async function Nh(e,t=30){let n=new Date(Date.now()+t*864e5).toISOString();return Th.from(`profiles`).update({paused_until:n}).eq(`id`,e)}async function Ph(e){let{count:t}=await Th.from(`judgments`).select(`id`,{count:`exact`,head:!0}).eq(`user_id`,e).eq(`verdict`,`done`),{count:n}=await Th.from(`priorities`).select(`date`,{count:`exact`,head:!0}).eq(`user_id`,e).eq(`status`,`done`);return{verified:t??0,days:n??0}}function Fh(e,t,n){return e===`done`?`done`:e===`skipped`?`skipped`:t>n?`upcoming`:t===n?`pending_today`:`missed`}function Ih(e,t,n){let r=Fh(e,t,n);return r===`skipped`||r===`missed`}function Lh(e){let t=0,n=0;for(let r of e)for(let e of r.priorities)e.resolution===`verified`&&!e.resolvedLate?(t++,n++):e.resolution===`missed`&&n++;return n>0?Math.round(t/n*100):0}function Rh(e,t){let n=0,r=0;for(let i of e)if(!(t&&i.date<t))for(let e of i.priorities)e.resolution===`verified`&&!e.resolvedLate?n++:(e.resolution===`attested`||e.resolution===`verified`&&e.resolvedLate)&&r++;let i=n+r;return{verified:n,attested:r,claimed:i,verifiedPct:i>0?Math.round(n/i*100):null}}function zh(e,t){let n=0,r=0,i=0;for(let a of e)if(!(t&&a.date<t))for(let e of a.priorities){if(e.unplanned){e.status===`done`&&i++;continue}r++,e.status===`done`&&(n++,i++)}return{adherence:r>0?Math.round(n/r*100):0,output:i,committedDone:n,committedTotal:r}}function Bh(e){return e.parentId?`p:${e.parentId}`:`t:${$h(e.text)}`}function Vh(e){let t=new Map;for(let n of e)for(let e of n.priorities){let r=Bh(e),i=t.get(r);i?i.push({date:n.date,p:e}):t.set(r,[{date:n.date,p:e}])}let n=new Set;for(let e of t.values()){if(e.length<2)continue;e.sort((e,t)=>
65e.date.localeCompare(t.date));let t=0;for(let r=0;r<e.length-1;r++){let{p:i}=e[r];if(!(i.status===`done`||!i.id)){if(t>=2)break;n.add(i.id),t++}}}return n}function Hh(e){let t=Vh(e);return e.map(e=>{let n=e.priorities.filter(e=>!(e.id&&t.has(e.id))),r=n.filter(e=>e.status===`done`).length,i=n.length;return{date:e.date,done:r,total:i,pct:i>0?r/i:0}})}function Uh(e,t,n){let r=new Map(Hh(e).map(e=>[e.date,e])),i=[],a=new Date(n+`T00:00:00Z`);for(let e=t-1;e>=0;e--){let t=new Date(a);t.setUTCDate(t.getUTCDate()-e);let n=t.toISOString().slice(0,10),o=r.get(n);i.push(o?{...o,hasEntry:!0}:{date:n,done:0,total:0,pct:0,hasEntry:!1})}return i}function Wh(e,t){return Math.round((new Date(e+`T12:00:00Z`).getTime()-new Date(t+`T12:00:00Z`).getTime())/864e5)}var Gh=2/3,Kh=new Set([`pending`,`planned`]);function qh(e){return new Date(e+`T12:00:00Z`).getUTCDay()}function Jh(e,t){return t?!!(t.dates&&t.dates.includes(e)||t.weekdays&&t.weekdays.includes(qh(e))):!1}function Yh(e,t,n){if(!n)return!1;let r=new Date(t+`T12:00:00Z`).getTime()+864e5,i=new Date(e+`T12:00:00Z`).getTime();for(;r<i;){if(!Jh(new Date(r).toISOString().slice(0,10),n))return!1;r+=864e5}return!0}function Xh(e,t){let n=new Date().toLocaleDateString(`en-CA`),r=Vh(e),i=0,a=null;for(let o=e.length-1;o>=0;o--){let{date:s,priorities:c}=e[o],l=c.filter(e=>!(e.id&&r.has(e.id)));if(c.length>0&&l.length===0){a=s;continue}if(l.length===0)break;if(!(s===n&&l.some(e=>Kh.has(e.status)))){if(a!==null&&Wh(a,s)!==1&&!Yh(a,s,t))break;if(Jh(s,t)){a=s;continue}if(l.filter(e=>e.status===`done`).length/l.length>=.6666666666666666)i++,a=s;else break}}return i}function Zh(e){let t=new Date().toLocaleDateString(`en-CA`),n=e.find(e=>e.date===t);return!n||n.priorities.length===0?!1:n.priorities.some(e=>Kh.has(e.status))}function Qh(e,t,n){let r=new Date(new Date(t+`T12:00:00Z`).getTime()-864e5).toISOString().slice(0,10),i=new Date(new Date(t+`T12:00:00Z`).getTime()-2*864e5).toISOString().slice(0,10),a=e.find(e=>e.date===r);return!a||a.priorities.length===0||a.priorities.filter(e=>e.status===`done`).length/a.priorities.length<.6666666666666666?Xh(e.filter(e=>e.date<=i),n)>=2:!1}function $h(e){return e.trim().toLowerCase().replace(/\s+/g,` `)}function eg(e,t,n=[]){let r=new Date(new Date(t+`T12:00:00Z`).getTime()-864e5).toISOString().slice(0,10),i=e.find(e=>e.date===r);if(!i)return[];let a=new Set(n.map(e=>$h(e.text)));return i.priorities.filter(e=>!!e.id&&e.status!==`done`&&!a.has($h(e.text)))}function tg(e,t=new Date,n){let r=t.toLocaleDateString(`en-CA`);if(e>=r)return!0;let i=new Date(r+`T12:00:00`);if(i.setDate(i.getDate()-1),e===i.toLocaleDateString(`en-CA`)&&t.getHours()<12)return!0;if(n?.bookedAt){let i=new Date(n.bookedAt);if(!isNaN(i.getTime())){let n=i.toLocaleDateString(`en-CA`),a=new Date(n+`T00:00:00`);a.setDate(a.getDate()+2);let o=new Date(n+`T00:00:00`);o.setDate(o.getDate()-1);let s=o.toLocaleDateString(`en-CA`);if(t<a&&e>=s&&e<r)return!0}}return!1}function ng(e,t,n){if(!t)return 0;let r=0,i=new Date(t+`T12:00:00Z`).getTime(),a=new Date(n+`T12:00:00Z`).getTime();for(;i<=a;)Jh(new Date(i).toISOString().slice(0,10),e)&&r++,i+=864e5;return r}function rg(e,t){let n=Vh(e),r=0,i=0,a=null;for(let o of e){if(o.priorities.length===0){i=0,a=null;continue}let e=o.priorities.filter(e=>!(e.id&&n.has(e.id)));if(a!==null&&Wh(o.date,a)!==1&&!Yh(o.date,a,t)&&(i=0),Jh(o.date,t)){a=o.date;continue}if(e.length===0){a=o.date;continue}e.filter(e=>e.status===`done`).length/e.length>=.6666666666666666?(i++,r=Math.max(r,i)):i=0,a=o.date}return r}function ig(e,t,n){let r=t.toLocaleDateString(`en-CA`);if(Jh(r,n)||Xh(e,n)===0||t.getHours()<18)return!1;let i=e.find(e=>e.date===r);return!i||i.priorities.length===0?!0:i.priorities.filter(e=>e.status===`done`).length/i.priorities.length<Gh}function ag(e,t,n=new Date){if(e.length===0)return{state:`seed`,missStreak:0,reviveAllRequired:!1};let r=n.toLocaleDateString(`en-CA`),i=e[0].date,a=new Map(e.map(e=>[e.date,e]));function o(e){if(e>r)return null;if(Jh(e,t))return`rest`;let n=a.get(e);if(e===r){if(!n||n.priorities.length===0)return null;if(n.priorities.some(e=>Kh.has(e.status)))return`inprogress`}else if(!n||n.priorities.length===0)return`miss`;return n.priorities.filter(e=>e.status===`done`).length/n.priorities.length>=.6666666666666666?`good`:`miss`}let s=0,c=!1,l=!1,u=new Date(r+`T12:00:00Z`).getTime(),d=new Date(i+`T12:00:00Z`).getTime(),f=!0;for(;u>=d;){let e=o(new Date(u).toISOString().slice(0,10));if(u-=864e5,!(e===`rest`||e===null)){if(e===`inprogress`){l=!0;continue}if(f){if(e===`miss`){s++;continue}f=!1}if(e===`good`){c=!0;break}}}if(!c)return{state:l?`in-progress`:`seed`,missStreak:0,reviveAllRequired:!1};let p;return p=s===0?l?`in-progress`:`thriving`:s<=2?`wilting`:s===3?`critical`:`dead`,{state:p,missStreak:s,reviveAllRequired:p===`critical`}}function og(e){let t={};for(let n of e)for(let e of n.priorities)t[e.category]||(t[e.category]={done:0,total:0}),t[e.category].total++,e.status===`done`&&t[e.category].done++;let n={};for(let[e,r]of Object.entries(t))n[e]={...r,slipRate:r.total>0?(r.total-r.done)/r.total:0};return n}function sg(e){let t=0,n=0,r=0,i=0;for(let a of e){let e=new Date(a.date+`T12:00:00Z`).getUTCDay(),o=a.priorities.filter(e=>e.status===`done`).length,s=a.priorities.length;e===0||e===6?(r+=o,i+=s):(t+=o,n+=s)}return{weekday:n>0?t/n:0,weekend:i>0?r/i:0}}function cg(e){let t=[`sunday`,`monday`,`tuesday`,`wednesday`,`thursday`,`friday`,`saturday`],n=Array.from({length:7},()=>({done:0,total:0}));for(let t of e){let e=new Date(t.date+`T12:00:00Z`).getUTCDay();n[e].done+=t.priorities.filter(e=>e.status===`done`).length,n[e].total+=t.priorities.length}return n.map((e,n)=>({day:t[n],done:e.done,total:e.total,rate:e.total>0?e.done/e.total:0}))}function lg(e){let t={};for(let n of e){let e=new Date(n.date+`T12:00:00Z`),r=e.getUTCDay(),i=new Date(e);i.setUTCDate(e.getUTCDate()-(r===0?6:r-1));let a=i.toISOString().slice(0,10);t[a]||(t[a]={done:0,total:0}),t[a].done+=n.priorities.filter(e=>e.status===`done`).length,t[a].total+=n.priorities.length}return Object.entries(t).sort(([e],[t])=>e.localeCompare(t)).map(([e,t])=>({weekStart:e,...t,pct:t.total>0?t.done/t.total:0}))}function ug(e){if(e.length===0)return[];let t={};for(let n of e){let e=n.date.slice(0,7);t[e]||(t[e]={done:0,total:0}),t[e].done+=n.priorities.filter(e=>e.status===`done`).length,t[e].total+=n.priorities.length}let n=Object.keys(t).sort(),[r,i]=n[0].split(`-`).map(Number),[a,o]=n[n.length-1].split(`-`).map(Number),s=[],c=r,l=i;for(;c<a||c===a&&l<=o;){let e=`${c}
65-${String(l).padStart(2,`0`)}`,n=t[e]??{done:0,total:0};s.push({monthStart:`${e}-01`,done:n.done,total:n.total,pct:n.total>0?n.done/n.total:0}),l++,l>12&&(l=1,c++)}return s}function dg(e,t,n){let r=t.trim().toLowerCase(),i=e.filter(e=>e.date!==n).sort((e,t)=>t.date.localeCompare(e.date)),a=0,o=null;for(let e of i){if(o!==null&&Wh(o,e.date)!==1)break;let t=e.priorities.find(e=>e.text.trim().toLowerCase()===r);if(t&&t.status===`skipped`)a++,o=e.date;else break}return a}function fg(e,t,n=``){let r=Hh(e),i=e=>e.reduce((e,t)=>({done:e.done+t.done,total:e.total+t.total}),{done:0,total:0}),a=({done:e,total:t})=>t>0?Math.round(e/t*100):0,o=i(r.slice(-7)),s=i(r.slice(-30)),c=sg(e),l=og(e),u=Object.entries(l).filter(([,e])=>e.total>=3).map(([e,t])=>({category:e,slipPct:Math.round(t.slipRate*100),samples:t.total})).sort((e,t)=>t.slipPct-e.slipPct).slice(0,3),d=e.length>0?e[e.length-1]:null,f=(d?.priorities??[]).filter(e=>e.status!==`done`).map(t=>({text:t.text,category:t.category,days:dg(e,t.text,d.date)})).filter(e=>e.days>=2).sort((e,t)=>t.days-e.days).slice(0,5),p=r.filter(e=>e.total>0).slice(-14).map(e=>({...e,pct:Math.round(e.pct*100)})),m=lg(e).slice(-4),h=cg(e).filter(e=>e.total>=2).map(e=>({day:e.day,rate:e.rate,total:e.total})),g=Object.entries(l).filter(([,e])=>e.total>=1).map(([e,t])=>({category:e,done:t.done,total:t.total,rate:t.done/t.total})).sort((e,t)=>e.rate-t.rate);return{streak:Xh(e,t),bestStreak:rg(e,t),last7Pct:a(o),last30Pct:a(s),daysTracked:r.filter(e=>e.total>0).length,weekdayPct:Math.round(c.weekday*100),weekendPct:Math.round(c.weekend*100),worstCategories:u,drifting:f,todayLocked:d?.priorities.length??0,todayDone:d?.priorities.filter(e=>e.status===`done`).length??0,businessContext:n.slice(0,1200),dailyData:p,weeklyData:m,dayOfWeekData:h,categoryData:g}}var pg=(e,t)=>`https://unavatar.io/${e}/${t}`,mg={musk:{name:`Elon Musk`,short:`Musk`,emoji:`ð`,photo:pg(`twitter`,`elonmusk`),url:`https://x.com/elonmusk`,tag:`Tesla & SpaceX`},jobs:{name:`Steve Jobs`,short:`Jobs`,emoji:`ð`,photo:`https://upload.wikimedia.org/wikipedia/commons/thumb/b/b9/Steve_Jobs_Headshot_2010-CROP.jpg/250px-Steve_Jobs_Headshot_2010-CROP.jpg`,url:`https://en.wikipedia.org/wiki/Steve_Jobs`,tag:`Apple`},bezos:{name:`Jeff Bezos`,short:`Bezos`,emoji:`ð¦`,photo:pg(`twitter`,`JeffBezos`),url:`https://x.com/JeffBezos`,tag:`Amazon`},gates:{name:`Bill Gates`,short:`Gates`,emoji:`ðª`,photo:pg(`twitter`,`BillGates`),url:`https://x.com/BillGates`,tag:`Microsoft`},zuck:{name:`Mark Zuckerberg`,short:`Zuckerberg`,emoji:`ð`,photo:pg(`instagram`,`zuck`),url:`https://www.instagram.com/zuck`,tag:`Meta`},altman:{name:`Sam Altman`,short:`Altman`,emoji:`ð¤`,photo:pg(`twitter`,`sama`),url:`https://x.com/sama`,tag:`OpenAI`},collison:{name:`Patrick Collison`,short:`Collison`,emoji:`ð³`,photo:pg(`twitter`,`patrickc`),url:`https://x.com/patrickc`,tag:`Stripe`},chesky:{name:`Brian Chesky`,short:`Chesky`,emoji:`ðï¸`,photo:pg(`twitter`,`bchesky`),url:`https://x.com/bchesky`,tag:`Airbnb`}},hg={shipping:{name:`Shipping`,emoji:`ð¢`,tag:`locked in, delivering`,generic:!0},motion:{name:`In motion`,emoji:`ð`,tag:`building momentum`,generic:!0},rhythm:{name:`Finding rhythm`,emoji:`ð¯`,tag:`settling into the habit`,generic:!0},warming:{name:`Warming up`,emoji:`ð±`,tag:`getting the reps in`,generic:!0},reset:{name:`Reset week`,emoji:`â»ï¸`,tag:`fresh start, one lock at a time`,generic:!0}},gg=[{at:95,...mg.musk},{at:90,...mg.jobs},{at:85,...mg.bezos},{at:80,...mg.gates},{at:76,...mg.zuck},{at:73,...mg.altman},{at:70,...mg.collison},{at:63,...hg.shipping},{at:56,...hg.motion},{at:50,...hg.rhythm},{at:25,...hg.warming},{at:0,...hg.reset}];function _g(e){return e>=90?`elite`:e>=70?`strong`:e>=50?`mid`:`low`}function vg(e){return e>=10?`high`:e>=5?`med`:`low`}var yg={elite:{low:mg.jobs,med:mg.zuck,high:mg.musk},strong:{low:mg.chesky,med:mg.altman,high:mg.collison},mid:{low:hg.rhythm,med:hg.motion,high:hg.shipping}};function bg(e){return gg.find(t=>e>=(t.at??0))??gg[gg.length-1]}function xg(e,t){let n=_g(e);return n===`low`?e>=25?hg.warming:hg.reset:yg[n][vg(t)]}function Sg(e){return e.short?`${e.short}
65 mode`:e.name}function Cg(e,t){let n=Math.max(0,Math.min(100,Math.round(e))),r=t==null?bg(n):xg(n,t);return{clamped:n,current:r,next:[...gg].reverse().find(e=>(e.at??0)>n)??null,mode:Sg(r)}}var wg=[50,70,90,100];function Tg(e,t){let n=Math.max(0,Math.min(100,Math.round(e)));if(n>=100)return`spotless â keep it that way.`;if(n>=90)return`elite territory â protect the streak.`;let r=wg.find(e=>e>n),i=t==null?bg(r):xg(r,t),a=i.short?`in ${i.short} mode`:i.name.toLowerCase();if(t&&t>0){let e=Math.round(n/100*t),i=Math.max(1,Math.ceil((r*t-100*e)/(100-r)));return`${i} more verified ${i===1?`day`:`days`} and you're ${a}.`}return`${r-n}% to ${i.short?`${i.short} mode`:i.name.toLowerCase()}.`}function Eg(e,t,n,r,i){let{clamped:a,current:o,mode:s}=Cg(e,i);return{kind:`founder`,pct:a,founderName:o.name,founderTag:o.tag,founderPhoto:o.photo,founderEmoji:o.emoji,generic:o.generic,modeName:s,gapHint:Tg(a,i),volume:i,periodLabel:r,name:t,product:n}}function Dg(e,t,n,r){return{kind:`streak`,streak:e,best:t,name:n,product:r}}function Og(e,t){let n=new Date(e+`T12:00:00Z`);return n.setUTCDate(n.getUTCDate()+t),n.toISOString().slice(0,10)}function kg(e,t,n,r){let i=lg(e);if(i.length===0)return null;let a=i[i.length-1].weekStart,o=Og(a,6),s=rf(),c=e.filter(e=>e.date>=a&&e.date<=o),l=c.flatMap(e=>e.priorities.filter(e=>e.status===`done`).map(e=>e.text)),u=c.flatMap(e=>e.priorities.filter(t=>Ih(t.status,e.date,s)).map(e=>e.text)),d=0,f=0;for(let e of c)for(let t of e.priorities)f++,t.status===`done`&&d++;let p=f>0?Math.round(d/f*100):0;return{kind:`weekly`,name:n??`Founder`,product:r??``,week_start:a,week_end:o,completion_pct:p,streak:t,shipped:l,missed:u}}function Ag(e){return Lh(e)}function jg(e){let t=0;for(let n of e)for(let e of n.priorities)(e.resolution===`verified`&&!e.resolvedLate||e.resolution===`missed`)&&t++;return t}function Mg(e,t,n){let r=0;for(let i of e)if(!(i.date<t||i.date>n))for(let e of i.priorities)(e.resolution===`verified`&&!e.resolvedLate||e.resolution===`missed`)&&r++;return r}function Ng(e){let t=0,n=0;for(let r of e)for(let e of r.priorities)e.resolution===`attested`?t++:(e.resolution===`verified`&&!e.resolvedLate||e.resolution===`missed`)&&n++;let r=t+n,i=r>0?Math.round(t/r*100):0;return{attested:t,counted:n,invisiblePct:i,stalled:t>=3&&i>=25}}async function Pg(e,t,n,r,i){let{data:a}=await L.from(`share_cards`).select(`id, data`).eq(`user_id`,e),o=(a??[]).filter(e=>e.data?.live===!0);if(o.length===0)return;let s=Ag(t),c=jg(t),l=Xh(t,n),u=rg(t,n),d=kg(t,l,r,i);for(let e of o){let n=e.data.kind,a=e.data.design,o=null;if(n===`founder`){let n=!!e.data.periodLabel&&/week/i.test(e.data.periodLabel),a=n&&d?d.completion_pct:s,l=n&&d?Mg(t,d.week_start,d.week_end):c;o=Eg(a,r,i,e.data.periodLabel,l)}else n===`streak`?o=Dg(l,u,r,i):n===`weekly`&&(o=d);o&&await L.from(`share_cards`).update({data:{...o,design:a,live:!0}}).eq(`id`,e.id)}}function Fg(e,t,n,r){let{cfg:i}=xh(e);(0,_.useEffect)(()=>{!e||t.length===0||Pg(e,t,i,n,r).catch(()=>{})},[e,t,i,n,r])}var Ig={solo_monthly:`price_1Tl7YnCQ9zBVx3R35NvUljo6`,solo_annual:`price_1Tl7ZuCQ9zBVx3R3v0i532qn`,founder_monthly:`price_1Tl7cLCQ9zBVx3R3eqI1xpF2`,founder_annual:`price_1Tl7ckCQ9zBVx3R3Nf93II0z`};async function Lg(e){let{data:{session:t}}=await L.auth.getSession();if(!t)return{error:`not signed in`};let n=`${window.location.origin}/app/settings`,{data:r,error:i}=await L.functions.invoke(`stripe-checkout`,{body:{...e,returnUrl:n}});return i?(console.error(`stripe-checkout error`,i),{error:`something went wrong â try again.`}):r}async function Rg(e){if(!e)return{error:`price not configured yet`};let t=await Lg({action:`checkout`,priceId:e});return t.url&&(window.location.href=t.url),t}async function zg(){let e=await Lg({action:`portal`});return e.url&&(window.location.href=e.url),e}function Bg(e){return e?Math.max(0,Math.ceil((new Date(e).getTime()-Date.now())/864e5)):99}var Vg=new Set([`[email protected]`]);function Hg(e,t){let n=e?.plan===`solo`||e?.plan===`founder`,r=!!t&&Vg.has(t.toLowerCase()),i=e?.trial_ends_at??null,a=i?new Date(i).getTime()>Date.now():!0,o=!n&&!r&&a,s=e?.trial_chat_used??0;return{paid:n,trialMode:o,locked:!1,bypass:r,chatUsed:s,chatLimit:200,chatRemaining:Math.max(0,200-s),windowEndsAt:i}}function Ug(){let{profile:e,session:t}=ll();return Hg(e,t?.user?.email)}var Wg={wrap:`_wrap_9v0ys_1`,head:`_head_9v0ys_11`,heading:`_heading_9v0ys_18`,sub:`_sub_9v0ys_28`,guarantee:`_guarantee_9v0ys_35`,guaranteeDot:`_guaranteeDot_9v0ys_50`,grid:`_grid_9v0ys_57`,card:`_card_9v0ys_67`,cardFeatured:`_cardFeatured_9v0ys_77`,cardTop:`_cardTop_9v0ys_81`,name:`_name_9v0ys_87`,price:`_price_9v0ys_95`,features:`_features_9v0ys_107`,btns:`_btns_9v0ys_124`,btn:`_btn_9v0ys_124`,btnAlt:`_btnAlt_9v0ys_145`,error:`_error_9v0ys_160`,note:`_note_9v0ys_166`};function Gg({heading:e,sub:t}
65){let n=z(),[r,i]=(0,_.useState)(null),[a,o]=(0,_.useState)(``),s=!!Ig.solo_monthly;async function c(e){if(r)return;i(e),o(``);let{error:t}=await Rg(Ig[e]);t&&(o(t),i(null))}return(0,R.jsxs)(`div`,{className:Wg.wrap,children:[(0,R.jsxs)(`div`,{className:Wg.head,children:[(0,R.jsx)(`h2`,{className:Wg.heading,children:e??n(`your free trial is over`)}),(0,R.jsx)(`p`,{className:Wg.sub,children:t??n(`keep your co-founder on call â real verification, streaks, and unlimited chat.`)}),(0,R.jsxs)(`span`,{className:Wg.guarantee,children:[(0,R.jsx)(`span`,{className:Wg.guaranteeDot}),n(`7-day money-back guarantee â cancel any time.`)]})]}),(0,R.jsxs)(`div`,{className:Wg.grid,children:[(0,R.jsxs)(`div`,{className:Wg.card,children:[(0,R.jsxs)(`div`,{className:Wg.cardTop,children:[(0,R.jsx)(`span`,{className:Wg.name,children:`solo`}),(0,R.jsxs)(`span`,{className:Wg.price,children:[`$19`,(0,R.jsx)(`span`,{children:`/mo`})]})]}),(0,R.jsxs)(`ul`,{className:Wg.features,children:[(0,R.jsx)(`li`,{children:n(`All connectors (15 total)`)}),(0,R.jsx)(`li`,{children:n(`90-day history + export`)}),(0,R.jsx)(`li`,{children:n(`Priority Sonnet AI`)}),(0,R.jsx)(`li`,{children:n(`Multiple goals`)})]}),(0,R.jsxs)(`div`,{className:Wg.btns,children:[(0,R.jsx)(`button`,{className:Wg.btn,onClick:()=>c(`solo_monthly`),disabled:!!r||!s,children:n(r===`solo_monthly`?`loadingâ¦`:`$19 / month`)}),(0,R.jsx)(`button`,{className:Wg.btnAlt,onClick:()=>c(`solo_annual`),disabled:!!r||!s,children:n(`$149 / year`)})]})]}),(0,R.jsxs)(`div`,{className:`${Wg.card} ${Wg.cardFeatured}`,children:[(0,R.jsxs)(`div`,{className:Wg.cardTop,children:[(0,R.jsx)(`span`,{className:Wg.name,children:`founder`}),(0,R.jsxs)(`span`,{className:Wg.price,children:[`$39`,(0,R.jsx)(`span`,{children:`/mo`})]})]}),(0,R.jsxs)(`ul`,{className:Wg.features,children:[(0,R.jsx)(`li`,{children:n(`Everything in solo`)}),(0,R.jsx)(`li`,{children:n(`The Crew â pod accountability board`)}),(0,R.jsx)(`li`,{children:n(`Stakes`)}),(0,R.jsx)(`li`,{children:n(`Priority support`)})]}),(0,R.jsxs)(`div`,{className:Wg.btns,children:[(0,R.jsx)(`button`,{className:Wg.btn,onClick:()=>c(`founder_monthly`),disabled:!!r||!s,children:n(r===`founder_monthly`?`loadingâ¦`:`$39 / month`)}),(0,R.jsx)(`button`,{className:Wg.btnAlt,onClick:()=>c(`founder_annual`),disabled:!!r||!s,children:n(`$299 / year`)})]})]})]}),a&&(0,R.jsx)(`p`,{className:Wg.error,children:a}),!s&&(0,R.jsx)(`p`,{className:Wg.note,children:n(`checkout not configured yet.`)})]})}async function Kg(e){if(!e)return[];let{data:t,error:n}=await L.from(`connector_health`).select(`provider, healthy, last_error, last_checked_at`).eq(`user_id`,e).eq(`healthy`,!1);return n||!t?[]:t}var qg={github:`GitHub`,google_calendar:`Google Calendar`,gmail:`Gmail`,slack:`Slack`,notion:`Notion`,linear:`Linear`,vercel:`Vercel`,x:`X`,discord:`Discord`};function Jg(e){return qg[e]?qg[e]:e.split(`_`).filter(Boolean).map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join(` `)}var Yg={banner:`_banner_1h2d2_4`,dot:`_dot_1h2d2_18`,text:`_text_1h2d2_26`,link:`_link_1h2d2_31`,dismiss:`_dismiss_1h2d2_39`};function Xg({userId:e}){let t=z(),[n,r]=(0,_.useState)([]),[i,a]=(0,_.useState)(!1);if((0,_.useEffect)(()=>{let t=!0;if(!e){r([]);return}return Kg(e).then(e=>{t&&r(e)}),()=>{t=!1}},[e]),i||n.length===0)return null;let o=n.map(e=>Jg(e.provider)),s=o.slice(0,3),c=o.length===1?t(`{name} needs reconnecting â Crew can't verify tasks from it until you do.`).replace(`{name}`,s[0]):t(`{n} connectors need reconnecting ({names}) â Crew can't verify tasks from them until you do.`).replace(`{n}`,String(o.length)).replace(`{names}`,s.join(`, `)+(o.length>s.length?`, â¦`:``));return(0,R.jsxs)(`div`,{className:Yg.banner,role:`status`,children:[(0,R.jsx)(`span`,{className:Yg.dot,"aria-hidden":!0}),(0,R.jsx)(`span`,{className:Yg.text,children:c}),(0,R.jsx)(`a`,{className:Yg.link,href:`/app/settings#connectors`,children:t(`reconnect â`)}),(0,R.jsx)(`button`,{className:Yg.dismiss,onClick:()=>a(!0),"aria-label":t(`dismiss`),type:`button`,children:`Ã`})]})}var Zg={layer:`_layer_znctb_4`,canvas:`_canvas_znctb_14`,card:`_card_znctb_22`,pop:`_pop_znctb_1`,cardLeaving:`_cardLeaving_znctb_37`,fade:`_fade_znctb_1`,check:`_check_znctb_50`,checkRing:`_checkRing_znctb_56`,checkMark:`_checkMark_znctb_63`,draw:`_draw_znctb_1`,headline:`_headline_znctb_78`,sub:`_sub_znctb_86`},Qg=[`#2D5BFF`,`#0E9F5A`,`#FFB020`,`#FF5D73`,`#7C5CFF`],$g=1300,e_=2400;function t_(e,t,n){let r=e.getContext(`2d`);if(!r)return;let i=Math.min(window.devicePixelRatio||1,2);e.width=window.innerWidth*i,e.height=window.innerHeight*i,r.scale(i,i);let a=Array.from({length:90},()=>({x:t,y:n,vx:(Math.random()-.5)*11,vy:-(4+Math.random()*9),w:5+Math.random()*5,h:3+Math.random()*4,r:Math.random()*Math.PI,vr:(Math.random()-.5)*.35,col:Qg[Math.random()*Qg.length|0]})),o=performance.now();(function e(t){let n=(t-o)/$g;if(r.clearRect(0,0,window.innerWidth,window.innerHeight),!(n>=1)){r.globalAlpha=1-n*n;
65for(let e of a)e.vy+=.32,e.x+=e.vx,e.y+=e.vy,e.r+=e.vr,r.save(),r.translate(e.x,e.y),r.rotate(e.r),r.fillStyle=e.col,r.fillRect(-e.w/2,-e.h/2,e.w,e.h),r.restore();requestAnimationFrame(e)}})(o)}function n_({state:e,onDone:t}){let n=z(),r=(0,_.useRef)(null),[i,a]=(0,_.useState)(!1);if((0,_.useEffect)(()=>{if(!e)return;a(!1),!window.matchMedia(`(prefers-reduced-motion: reduce)`).matches&&r.current&&t_(r.current,window.innerWidth/2,window.innerHeight*.42);try{navigator.vibrate?.([18,40,30])}catch{}let n=setTimeout(()=>a(!0),e_-260),i=setTimeout(t,e_);return()=>{clearTimeout(n),clearTimeout(i)}},[e,t]),!e)return null;let o=e.done>=e.total,s=e.total-e.done;return(0,R.jsxs)(`div`,{className:Zg.layer,role:`status`,"aria-live":`polite`,onClick:t,children:[(0,R.jsx)(`canvas`,{ref:r,className:Zg.canvas,"aria-hidden":!0}),(0,R.jsxs)(`div`,{className:i?`${Zg.card} ${Zg.cardLeaving}`:Zg.card,children:[(0,R.jsxs)(`svg`,{className:Zg.check,viewBox:`0 0 48 48`,"aria-hidden":!0,children:[(0,R.jsx)(`circle`,{className:Zg.checkRing,cx:`24`,cy:`24`,r:`21`}),(0,R.jsx)(`path`,{className:Zg.checkMark,d:`M14 24.5 L21 31 L34 17.5`})]}),(0,R.jsx)(`span`,{className:Zg.headline,children:n(o?`day clear.`:`that's one.`)}),(0,R.jsx)(`span`,{className:Zg.sub,children:o?n(`all {n} done â proven, not claimed.`).replace(`{n}`,String(e.total)):n(`{done} of {total} done · {left} to go`).replace(`{done}`,String(e.done)).replace(`{total}`,String(e.total)).replace(`{left}`,String(s))})]})]})}var r_=6e4;function i_(){for(let e of[`audio/webm;codecs=opus`,`audio/webm`,`audio/mp4`,`audio/ogg;codecs=opus`])if(typeof MediaRecorder<`u`&&MediaRecorder.isTypeSupported?.(e))return e;return``}function a_(e){return e.includes(`mp4`)?`m4a`:e.includes(`ogg`)?`ogg`:`webm`}function o_(){try{let e=document.featurePolicy;if(e?.allowsFeature)return!e.allowsFeature(`microphone`)}catch{}return!1}function s_(e,t){let[n,r]=(0,_.useState)(`idle`),[i,a]=(0,_.useState)(null),o=(0,_.useRef)(null),s=(0,_.useRef)([]),c=(0,_.useRef)(null),l=(0,_.useRef)(e);(0,_.useEffect)(()=>{l.current=e});let u=typeof window<`u`&&typeof MediaRecorder<`u`&&!!navigator.mediaDevices?.getUserMedia,d=(t?.lang??`en-US`).slice(0,2),f=(0,_.useCallback)(()=>{o.current?.stream.getTracks().forEach(e=>e.stop()),o.current=null,c.current&&=(clearTimeout(c.current),null)},[]),p=(0,_.useCallback)(()=>{let e=o.current;e&&e.state!==`inactive`?e.stop():(f(),r(`idle`))},[f]),m=(0,_.useCallback)(async()=>{if(!u){a(`unsupported`);return}a(null);let e;try{e=await navigator.mediaDevices.getUserMedia({audio:!0})}catch(e){let t=e?.name??``;a(t===`NotFoundError`||t===`OverconstrainedError`?`no-mic`:o_()?`blocked-by-policy`:`mic-denied`),r(`idle`);return}let t=i_(),n=new MediaRecorder(e,t?{mimeType:t}:void 0);o.current=n,s.current=[],n.ondataavailable=e=>{e.data.size>0&&s.current.push(e.data)},n.onstop=async()=>{let e=n.mimeType||t||`audio/webm`,i=new Blob(s.current,{type:e});if(s.current=[],f(),i.size<1200){r(`idle`);return}r(`transcribing`);try{let t=new FormData;t.append(`file`,i,`clip.${a_(e)}`),t.append(`language`,d);let{data:n,error:o}=await L.functions.invoke(`transcribe`,{body:t}),s=n?.text?.trim();if(o){a(`failed`),r(`idle`);return}s&&l.current(s),r(`idle`)}catch{a(`failed`),r(`idle`)}},n.start(),r(`recording`),c.current=window.setTimeout(()=>{o.current?.state===`recording`&&o.current.stop()},r_)},[u,d,f]),h=(0,_.useCallback)(()=>{n===`recording`?p():n===`idle`&&m()},[n,m,p]);return(0,_.useEffect)(()=>()=>{o.current?.stream.getTracks().forEach(e=>e.stop()),c.current&&clearTimeout(c.current)},[]),{supported:u,state:n,listening:n===`recording`,transcribing:n===`transcribing`,error:i,start:m,stop:p,toggle:h}}var c_={wrap:`_wrap_th8xb_1`,mic:`_mic_th8xb_8`,micLive:`_micLive_th8xb_26`,stopSquare:`_stopSquare_th8xb_31`,breathe:`_breathe_th8xb_1`,micBusy:`_micBusy_th8xb_44`,spinner:`_spinner_th8xb_46`,spin:`_spin_th8xb_46`,error:`_error_th8xb_62`};function l_({onText:e,className:t,size:n=20}){let r=z(),{lang:i}=ml(),a=s_(e,{lang:i===`fr`?`fr-FR`:`en-US`});if(!a.supported)return null;let o=a.listening?r(`stop and transcribe`):a.transcribing?r(`transcribingâ¦`):r(`dictate`),s=a.error===`mic-denied`?r(`microphone blocked â allow it for this site in your browser`):a.error===`blocked-by-policy`?r(`this page isn't allowed to use the microphone`):a.error===`no-mic`?r(`no microphone found`):a.error===`failed`?r(`couldn't transcribe that â try again`):null;return(0,R.jsxs)(`span`,{className:c_.wrap,children:[(0,R.jsx)(`button`,{type:`button`,className:B(c_.mic,a.listening&&c_.micLive,a.transcribing&&c_.micBusy,t),onClick:a.toggle,"aria-label":o,"aria-pressed":a.listening,title:o,children:a.listening?(0,R.jsx)(`span`,{className:c_.stopSquare,"aria-hidden":!0}):a.transcribing?(0,R.jsx)(`span`,{className:c_.spinner,"aria-hidden":!0}):(0,R.jsxs)(`svg`,{width:n,height:n,viewBox:`0 0 24 24`,fill:`none`,"aria-hidden":!0,
65children:[(0,R.jsx)(`rect`,{x:`9`,y:`3`,width:`6`,height:`11`,rx:`3`,stroke:`currentColor`,strokeWidth:`1.7`}),(0,R.jsx)(`path`,{d:`M5.5 11.5a6.5 6.5 0 0 0 13 0`,stroke:`currentColor`,strokeWidth:`1.7`,strokeLinecap:`round`}),(0,R.jsx)(`path`,{d:`M12 18v3`,stroke:`currentColor`,strokeWidth:`1.7`,strokeLinecap:`round`})]})}),s&&(0,R.jsx)(`span`,{className:c_.error,role:`alert`,children:s})]})}var u_={crisis:`crisis day`,deep_work:`deep work`,travel:`travel day`,offline:`offline`},d_={crisis:`one task is enough â no streak hit`,deep_work:`Crew goes quiet â one evening check only`,travel:`light load, attestation ok`,offline:`no pings, today won't count against you`};async function f_(e,t){let{data:n}=await L.from(`scenario_days`).select(`mode`).eq(`user_id`,e).eq(`date`,t).maybeSingle();return n?.mode??null}async function p_(e,t,n){let{error:r}=await L.from(`scenario_days`).upsert({user_id:e,date:t,mode:n},{onConflict:`user_id,date`});return r?(r.message??``).toLowerCase().includes(`crisis`)?{error:`you've used both crisis days this month â go easy, not off`}:{error:r.message??`could not set today's mode`}:{error:null}}async function m_(e,t){await L.from(`scenario_days`).delete().eq(`user_id`,e).eq(`date`,t)}async function h_(){try{let{data:e,error:t}=await L.functions.invoke(`task-candidates`,{body:{}});if(t)return[];let n=e?.candidates??[];return Array.isArray(n)?n:[]}catch{return[]}}var U={page:`_page_szj6u_5`,nav:`_nav_szj6u_11`,navBack:`_navBack_szj6u_21`,dayToggle:`_dayToggle_szj6u_30`,dayBtn:`_dayBtn_szj6u_43`,dayBtnActive:`_dayBtnActive_szj6u_58`,shell:`_shell_szj6u_64`,dayBar:`_dayBar_szj6u_74`,dayMeta:`_dayMeta_szj6u_84`,streak:`_streak_szj6u_91`,streakIcon:`_streakIcon_szj6u_108`,progress:`_progress_szj6u_112`,progressLabel:`_progressLabel_szj6u_118`,segs:`_segs_szj6u_126`,seg:`_seg_szj6u_126`,segDone:`_segDone_szj6u_139`,segActive:`_segActive_szj6u_143`,main:`_main_szj6u_149`,header:`_header_szj6u_155`,date:`_date_szj6u_161`,title:`_title_szj6u_169`,deck:`_deck_szj6u_182`,card:`_card_szj6u_191`,cardNext:`_cardNext_szj6u_204`,cardActive:`_cardActive_szj6u_211`,cardDone:`_cardDone_szj6u_216`,cardTop:`_cardTop_szj6u_220`,cardNum:`_cardNum_szj6u_226`,cardTag:`_cardTag_szj6u_234`,cardTagActive:`_cardTagActive_szj6u_235`,cardNumActive:`_cardNumActive_szj6u_254`,cardCheck:`_cardCheck_szj6u_256`,cardTask:`_cardTask_szj6u_263`,taskDone:`_taskDone_szj6u_274`,group:`_group_szj6u_281`,groupLabel:`_groupLabel_szj6u_287`,groupCount:`_groupCount_szj6u_296`,kebabWrap:`_kebabWrap_szj6u_303`,kebabBtn:`_kebabBtn_szj6u_308`,kebabMenu:`_kebabMenu_szj6u_325`,kebabItem:`_kebabItem_szj6u_340`,kebabItemDanger:`_kebabItemDanger_szj6u_355`,editInput:`_editInput_szj6u_357`,editActions:`_editActions_szj6u_368`,editActionBtn:`_editActionBtn_szj6u_375`,editIconBtn:`_editIconBtn_szj6u_390`,catChip:`_catChip_szj6u_403`,rowMeta:`_rowMeta_szj6u_415`,sliceChip:`_sliceChip_szj6u_425`,multidayRow:`_multidayRow_szj6u_440`,multidayToggle:`_multidayToggle_szj6u_443`,multidayField:`_multidayField_szj6u_454`,multidayInput:`_multidayInput_szj6u_459`,multidayClear:`_multidayClear_szj6u_471`,renegPanel:`_renegPanel_szj6u_480`,renegLabel:`_renegLabel_szj6u_490`,renegInput:`_renegInput_szj6u_495`,renegActions:`_renegActions_szj6u_506`,renegSwap:`_renegSwap_szj6u_511`,renegDrop:`_renegDrop_szj6u_511`,renegCancel:`_renegCancel_szj6u_511`,crewCheckRow:`_crewCheckRow_szj6u_531`,breakdown:`_breakdown_szj6u_539`,breakdownToggle:`_breakdownToggle_szj6u_543`,breakdownCaret:`_breakdownCaret_szj6u_558`,breakdownToggleOpen:`_breakdownToggleOpen_szj6u_565`,breakdownBody:`_breakdownBody_szj6u_567`,breakdownList:`_breakdownList_szj6u_573`,breakdownItem:`_breakdownItem_szj6u_580`,breakdownStepText:`_breakdownStepText_szj6u_586`,breakdownStepDone:`_breakdownStepDone_szj6u_591`,breakdownDeleteBtn:`_breakdownDeleteBtn_szj6u_596`,breakdownAddRow:`_breakdownAddRow_szj6u_607`,breakdownInput:`_breakdownInput_szj6u_612`,breakdownAddBtn:`_breakdownAddBtn_szj6u_622`,crewCheckBtn:`_crewCheckBtn_szj6u_633`,crewCheckNote:`_crewCheckNote_szj6u_648`,nudge:`_nudge_szj6u_656`,nudgeIcon:`_nudgeIcon_szj6u_666`,nudgeCaret:`_nudgeCaret_szj6u_677`,nudgeBody:`_nudgeBody_szj6u_684`,nudgeLabel:`_nudgeLabel_szj6u_690`,nudgeText:`_nudgeText_szj6u_698`,markRow:`_markRow_szj6u_706`,marked:`_marked_szj6u_713`,markedUndo:`_markedUndo_szj6u_724`,markConfirm:`_markConfirm_szj6u_742`,markConfirmText:`_markConfirmText_szj6u_752`,markConfirmActions:`_markConfirmActions_szj6u_758`,markConfirmCancel:`_markConfirmCancel_szj6u_764`,lockForm:`_lockForm_szj6u_778`,lockTip:`_lockTip_szj6u_789`,lockTipDismiss:`_lockTipDismiss_szj6u_802`,catchUpBanner:`_catchUpBanner_szj6u_816`,catchUpDismiss:`_catchUpDismiss_szj6u_828`,lockRow:`_lockRow_szj6u_841`,lockNum:`_lockNum_szj6u_847`,lockInput
65:`_lockInput_szj6u_854`,catRow:`_catRow_szj6u_870`,catLegend:`_catLegend_szj6u_878`,catBtn:`_catBtn_szj6u_886`,catBtnActive:`_catBtnActive_szj6u_900`,catBtnMissing:`_catBtnMissing_szj6u_907`,lockError:`_lockError_szj6u_913`,lockRemoveBtn:`_lockRemoveBtn_szj6u_919`,loadingNote:`_loadingNote_szj6u_937`,emptyNote:`_emptyNote_szj6u_938`,addTaskBtn:`_addTaskBtn_szj6u_946`,importBox:`_importBox_szj6u_965`,importToggle:`_importToggle_szj6u_971`,importNote:`_importNote_szj6u_987`,importGroups:`_importGroups_szj6u_994`,importGroup:`_importGroup_szj6u_994`,importSourceLabel:`_importSourceLabel_szj6u_1010`,importChips:`_importChips_szj6u_1018`,importChip:`_importChip_szj6u_1018`,importChipUsed:`_importChipUsed_szj6u_1042`,addTaskForm:`_addTaskForm_szj6u_1049`,addTaskInput:`_addTaskInput_szj6u_1060`,addTaskActions:`_addTaskActions_szj6u_1071`,addTaskConfirm:`_addTaskConfirm_szj6u_1077`,addTaskCancel:`_addTaskCancel_szj6u_1091`,stakeCard:`_stakeCard_szj6u_1103`,stakeKept:`_stakeKept_szj6u_1113`,stakeForfeited:`_stakeForfeited_szj6u_1114`,stakeLabel:`_stakeLabel_szj6u_1116`,stakeBlurb:`_stakeBlurb_szj6u_1124`,stakePresets:`_stakePresets_szj6u_1132`,stakePresetBtn:`_stakePresetBtn_szj6u_1138`,stakePresetActive:`_stakePresetActive_szj6u_1151`,stakeCustomInput:`_stakeCustomInput_szj6u_1153`,stakeLockBtn:`_stakeLockBtn_szj6u_1166`,stakeCollectBtn:`_stakeCollectBtn_szj6u_1183`,stakeCollectDisabled:`_stakeCollectDisabled_szj6u_1184`,stakeErr:`_stakeErr_szj6u_1186`,proofBackdrop:`_proofBackdrop_szj6u_1259`,proofModal:`_proofModal_szj6u_1269`,proofHead:`_proofHead_szj6u_1280`,proofKicker:`_proofKicker_szj6u_1285`,proofClose:`_proofClose_szj6u_1292`,proofTask:`_proofTask_szj6u_1301`,proofChecking:`_proofChecking_szj6u_1307`,proofVerified:`_proofVerified_szj6u_1313`,proofHint:`_proofHint_szj6u_1322`,proofReviewMsg:`_proofReviewMsg_szj6u_1328`,proofInsufficient:`_proofInsufficient_szj6u_1334`,proofUncertain:`_proofUncertain_szj6u_1339`,proofCorrob:`_proofCorrob_szj6u_1344`,proofEvidence:`_proofEvidence_szj6u_1351`,proofTextarea:`_proofTextarea_szj6u_1358`,proofFileBtn:`_proofFileBtn_szj6u_1372`,proofActions:`_proofActions_szj6u_1385`,proofChoiceRow:`_proofChoiceRow_szj6u_1393`,proofTextBtn:`_proofTextBtn_szj6u_1399`,proofCantBtn:`_proofCantBtn_szj6u_1399`,commitBar:`_commitBar_szj6u_1412`,commitChain:`_commitChain_szj6u_1421`,commitBroken:`_commitBroken_szj6u_1422`,commitBtn:`_commitBtn_szj6u_1423`,commitOpts:`_commitOpts_szj6u_1434`,commitOpt:`_commitOpt_szj6u_1434`,commitCancel:`_commitCancel_szj6u_1448`,modeRow:`_modeRow_szj6u_1460`,modeTrigger:`_modeTrigger_szj6u_1469`,modeChips:`_modeChips_szj6u_1480`,modeChip:`_modeChip_szj6u_1480`,modeCancel:`_modeCancel_szj6u_1447`,modeActive:`_modeActive_szj6u_1503`,modeBlurb:`_modeBlurb_szj6u_1513`,modeClear:`_modeClear_szj6u_1514`,modeErr:`_modeErr_szj6u_1526`,addTaskInputRow:`_addTaskInputRow_szj6u_1537`,proofFieldWrap:`_proofFieldWrap_szj6u_1547`,fieldMic:`_fieldMic_szj6u_1553`,receiptRow:`_receiptRow_szj6u_1563`,whenRow:`_whenRow_szj6u_1564`,receiptLabel:`_receiptLabel_szj6u_1573`,whenLabel:`_whenLabel_szj6u_1574`,receiptChip:`_receiptChip_szj6u_1582`,receiptChipActive:`_receiptChipActive_szj6u_1595`,receiptChipNone:`_receiptChipNone_szj6u_1602`,whenInput:`_whenInput_szj6u_1608`,rowMore:`_rowMore_szj6u_1626`,rowExtra:`_rowExtra_szj6u_1641`,rowExtraClose:`_rowExtraClose_szj6u_1653`,proposeRow:`_proposeRow_szj6u_1676`,retryBtn:`_retryBtn_szj6u_1684`};function g_(){let e=new Date;return e.setDate(e.getDate()+1),e.toLocaleDateString(`en-CA`)}var __=[`build`,`sales`,`ops`],v_=[{kind:`pr_merged`,label:`PR merged`},{kind:`file_changed`,label:`file changed`},{kind:`meeting_held`,label:`meeting held`},{kind:`invoice_sent`,label:`invoice sent`},{kind:`none`,label:`nothing will prove this`}];function y_(e){return e.trim().toLowerCase().replace(/\s+/g,` `)}function b_(e,t){let n=[];return e.receiptKind&&n.push(t(v_.find(t=>t.kind===e.receiptKind)?.label??``)),e.planWhen?.trim()&&n.push(e.planWhen.trim()),e.parentTitle!==void 0&&n.push(t(`multi-day`)),n.length>0?n.join(` · `):t(`+ proof, timing, multi-day`)}var x_={build:`build â the product itself: code, design, the thing you're making`,sales:`sales â getting or talking to customers: outreach, demos, follow-ups, marketing`,ops:`ops â keeps the business running: admin, finance, hiring, legal, support`};function S_({priorityId:e,t,onChanged:n}){let[r,i]=(0,_.useState)(null),[a,o]=(0,_.useState)(``);(0,_.useEffect)(()=>{r===null&&fh(e).then(({data:e})=>i(e??[]))},[r,e]);async function s(){let t=a.trim();if(!t)return;let{data:s}=await mh(e,t,r?.length??0);s&&i(e=>[...e??[],s]),o(``),n()}async function c(e){await hh(e.id,!e.done),i(t=>(t??[]).map(t=>
65t.id===e.id?{...t,done:!t.done}:t)),n()}async function l(e){await gh(e.id),i(t=>(t??[]).filter(t=>t.id!==e.id)),n()}return(0,R.jsx)(`div`,{className:U.breakdown,children:(0,R.jsxs)(`div`,{className:U.breakdownBody,children:[r===null?null:(0,R.jsx)(`ul`,{className:U.breakdownList,children:r.map(e=>(0,R.jsxs)(`li`,{className:U.breakdownItem,children:[(0,R.jsx)(Vl,{checked:e.done,onChange:()=>c(e),label:e.text}),(0,R.jsx)(`span`,{className:B(U.breakdownStepText,e.done&&U.breakdownStepDone),children:e.text}),(0,R.jsx)(`button`,{type:`button`,className:U.breakdownDeleteBtn,onClick:()=>l(e),"aria-label":t(`delete`),children:`Ã`})]},e.id))}),(0,R.jsxs)(`div`,{className:U.breakdownAddRow,children:[(0,R.jsx)(`input`,{className:U.breakdownInput,type:`text`,placeholder:t(`add a stepâ¦`),value:a,onChange:e=>o(e.target.value),onKeyDown:e=>{e.key===`Enter`&&s()}}),(0,R.jsx)(`button`,{type:`button`,className:U.breakdownAddBtn,onClick:s,children:t(`add`)})]})]})})}function C_(){let e=z(),{lang:t}=ml(),{session:n,profile:r}=ll(),i=Ug(),a=n?.user.id,o=r?.daily_task_count??3,{active:s,firstWorkspaceId:c}=wl(),l=!!s&&s.id===c,[u]=Kn(),[d,f]=(0,_.useState)(u.get(`mode`)===`tomorrow`?`tomorrow`:`today`),p=d===`today`?rf():g_(),{entries:m,loading:h,refresh:g}=nf(a,s?.id,l),{cfg:v}=xh(a);Fg(a,m,r?.name,r?.product_name);let[y,b]=(0,_.useState)(null),[x,S]=(0,_.useState)(``),[C,w]=(0,_.useState)(0),[T,E]=(0,_.useState)(!0),[D,O]=(0,_.useState)(null),[k,A]=(0,_.useState)(null),[j,ee]=(0,_.useState)(``),[te,ne]=(0,_.useState)(null),[re,M]=(0,_.useState)(``),[N,ie]=(0,_.useState)(null),[ae,P]=(0,_.useState)(``),[oe,se]=(0,_.useState)(``),[ce,le]=(0,_.useState)(0),[ue,de]=(0,_.useState)({}),[fe,pe]=(0,_.useState)(!1),[me,he]=(0,_.useState)({}),[ge,_e]=(0,_.useState)(null),[ve,ye]=(0,_.useState)(new Set),be=r?.verify_required!==!1,[xe,Se]=(0,_.useState)(null);(0,_.useEffect)(()=>{a&&(E(!0),Gd(a,p,s?.id,l).then(({data:e,error:t})=>{if(t){S(t.message??String(t)),E(!1);return}S(``);let n=e??[];b(n),E(!1);let r=n.map(e=>e.parent_id).filter(e=>!!e);r.length?qd(r).then(de):de({}),ph(n.map(e=>e.id)).then(he)}))},[a,p,d,s?.id,l,C]);function Ce(){y?.length&&ph(y.map(e=>e.id)).then(he)}(0,_.useEffect)(()=>{if(!ge)return;let e=e=>{e.target?.closest?.(`[data-kebab]`)||_e(null)};return document.addEventListener(`pointerdown`,e),()=>document.removeEventListener(`pointerdown`,e)},[ge]),(0,_.useEffect)(()=>{if(!a){le(0);return}ef(a,p).then(le)},[a,p,y]),(0,_.useEffect)(()=>{d===`today`&&y?.length===0&&!i.locked&&tu(`lock_form`)},[d,y,i.locked]);let we=(0,_.useMemo)(()=>m.filter(e=>e.date<p),[m,p]),Te=Xh(m,v),Ee=d===`today`?Qh(we,p,v):!1,De=(0,_.useMemo)(()=>d===`today`?eg(m,p,y??[]):[],[m,p,d,y]);async function Oe(){if(!a)return;let{data:e}=await Gd(a,p,s?.id,l);b(e??[]),g()}function ke(e){ne(e.id),M(e.text)}function Ae(){ne(null),M(``)}async function je(e){let t=re.trim();if(!t||t===e.text){Ae();return}await Xd(e.id,t),Ae(),Oe()}async function Me(t){confirm(e(`delete "{task}"? this can't be undone.`).replace(`{task}`,t.text))&&(await Qd(t.id),te===t.id&&Ae(),Oe())}async function Ne(e){await $d(e.id,g_()),te===e.id&&Ae(),Oe()}async function Pe(e){await Yd(e.id,!e.started_at),Oe()}async function Fe(e){if(e.status===`done`){await Jd(e.id,`pending`),Oe();return}if(!be){await Ie(e,`marked done â verification off`,`done`);return}A(e.id);try{let t=await Ch(e.text,e.category,e.id,e.date);t.verified?await Ie(e,`â verified via ${t.app.toLowerCase()}${t.evidence?`: ${t.evidence}`:``}`,`done`):(ee(t.reason),O(e))}catch{ee(``),O(e)}finally{A(null)}}async function Ie(e,t,n=`done`){if(await Jd(e.id,n,t),O(null),n===`done`&&y){let t=y.length,n=y.filter(t=>t.id!==e.id&&t.status===`done`).length+1;Se({key:Date.now(),done:n,total:t})}Oe()}function Le(e){ie(e.id),P(``),se(e.text)}async function Re(e,t){let n=ae.trim();if(!n||!a||t===`swap`&&(!oe.trim()||oe.trim()===e.text))return;let r=ce>=2;await tf({id:e.id,text:e.text,date:e.date},{kind:t,reason:n,newText:oe,userId:a,workspaceId:s?.id,overCap:r}),ie(null),P(``),se(``),Oe()}function ze(){if(y){if(y.filter(e=>e.status===`pending`).length>0){pe(!0);return}Be()}}async function Be(){if(!y)return;let e=y.filter(e=>
65e.status===`pending`);await Promise.all(e.map(e=>Jd(e.id,`skipped`))),a&&(e.length>0?await jh(a,p):await Mh(a,p)),pe(!1),Oe()}async function Ve(){y&&(await Promise.all(y.filter(e=>e.status===`skipped`).map(e=>Jd(e.id,`pending`))),Oe())}if(x)return(0,R.jsxs)(`div`,{className:U.page,children:[(0,R.jsx)(w_,{dayMode:d,setDayMode:f}),(0,R.jsx)(`div`,{className:U.shell,children:(0,R.jsxs)(`p`,{className:U.loadingNote,children:[e(`couldn't load today â your tasks are safe, this is a read problem.`),` `,(0,R.jsx)(`button`,{type:`button`,className:U.retryBtn,onClick:()=>{S(``),E(!0),w(e=>e+1)},children:e(`retry`)})]})}),(0,R.jsx)(dh,{})]});if(!a||T||h)return(0,R.jsxs)(`div`,{className:U.page,children:[(0,R.jsx)(w_,{dayMode:d,setDayMode:f}),(0,R.jsx)(`div`,{className:U.shell,children:(0,R.jsx)(`p`,{className:U.loadingNote,children:e(`loadingâ¦`)})}),(0,R.jsx)(dh,{})]});if(y&&y.length===0)return(0,R.jsxs)(`div`,{className:U.page,children:[(0,R.jsx)(w_,{dayMode:d,setDayMode:f}),(0,R.jsx)(`div`,{className:U.shell,children:(0,R.jsxs)(`main`,{className:U.main,children:[(0,R.jsxs)(`header`,{className:U.header,children:[(0,R.jsx)(`span`,{className:U.date,children:T_(p,t)}),(0,R.jsx)(`h1`,{className:U.title,children:e(d===`today`?`Today`:`Tomorrow`)})]}),i.locked?(0,R.jsx)(Gg,{heading:e(`your free trial is over`),sub:e(`subscribe to lock today's priorities and keep your streak going.`)}):(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`p`,{className:U.emptyNote,children:d===`today`?e(`nothing locked yet. what are the {n} things that actually move the needle today?`).replace(`{n}`,String(o)):d===`tomorrow`?e(`prep tomorrow before you sleep â lock the {n} that actually matter.`).replace(`{n}`,String(o)):e(`nothing locked for this day yet.`)}),(0,R.jsxs)(`div`,{className:U.proposeRow,children:[(0,R.jsx)(eh,{scope:`day`,defaultCount:o,label:e(`generate tasks`),onAccept:async(e,t)=>{let n=new Date;t===`tomorrow`&&n.setDate(n.getDate()+1);let{error:r}=await Kd(a,n.toLocaleDateString(`en-CA`),e.map(e=>({text:e.text,category:e.category})),s?.id);if(r)throw Error(r.message??String(r));Oe()}}),(0,R.jsx)(eh,{scope:`day`,mode:`import`,defaultCount:o,label:e(`import from your tools`),onAccept:async(e,t)=>{let n=new Date;t===`tomorrow`&&n.setDate(n.getDate()+1);let{error:r}=await Kd(a,n.toLocaleDateString(`en-CA`),e.map(e=>({text:e.text,category:e.category})),s?.id);if(r)throw Error(r.message??String(r));Oe()}})]}),(0,R.jsx)(E_,{userId:a,date:p,workspaceId:s?.id,taskCount:o,reentry:Ee,carryable:De,onLocked:Oe})]})]})}),(0,R.jsx)(dh,{})]});let He=y??[],Ue=He.length>0&&He.every(e=>e.status!==`pending`),We=He.filter(e=>e.status===`done`).length,Ge=He.filter(e=>e.status===`pending`).length,Ke=e=>e.status===`pending`&&(!!e.started_at||(me[e.id]?.done??0)>0),qe=He.map((e,t)=>({row:e,i:t})),Je=qe.filter(e=>Ke(e.row)),Ye=qe.filter(e=>e.row.status===`pending`&&!Ke(e.row)),Xe=qe.filter(e=>e.row.status!==`pending`),Ze=[{key:`inprogress`,label:e(`in progress`),items:Je},{key:`notstarted`,label:e(`not started`),items:Ye},{key:`finished`,label:e(`finished`),items:Xe}].filter(e=>e.items.length>0),Qe=Je[0]?.row??Ye[0]?.row??null;return(0,R.jsxs)(`div`,{className:U.page,children:[(0,R.jsx)(w_,{dayMode:d,setDayMode:f}),(0,R.jsx)(`div`,{className:U.shell,children:(0,R.jsxs)(`main`,{className:U.main,children:[(0,R.jsxs)(`header`,{className:U.dayBar,children:[(0,R.jsxs)(`div`,{className:U.header,children:[(0,R.jsx)(`span`,{className:U.date,children:T_(p,t)}),(0,R.jsx)(`h1`,{className:U.title,children:d===`today`?e(`Today`):d===`tomorrow`?e(`Tomorrow`):T_(p,t)})]}),(0,R.jsxs)(`div`,{className:U.dayMeta,children:[(0,R.jsxs)(`span`,{className:U.streak,children:[(0,R.jsx)(`span`,{className:U.streakIcon,"aria-hidden":!0,children:`â²`}),e(`{n} day streak`).replace(`{n}`,String(Te))]}),(0,R.jsxs)(`div`,{className:U.progress,children:[(0,R.jsx)(`span`,{className:U.progressLabel,children:Qe?e(`{done} of {total} locked priorities`).replace(`{done}`,String(We)).replace(`{total}`,String(He.length)):e(`all clear`)}),(0,R.jsx)(`div`,{className:U.segs,role:`progressbar`,"aria-valuenow":We,"aria-valuemin":0,"aria-valuemax":He.length,children:He.map(e=>(0,R.jsx)(`span`,{className:B(U.seg,e.status===`done`&&U.segDone,Ke(e)&&U.segActive)},e.id))})]})]})]}),a&&(0,R.jsx)(A_,{userId:a,date:p}),a&&(0,R.jsx)(Xg,{userId:a}),a&&d===`today`&&(0,R.jsx)(k_,{userId:a,date:p}),Ze.map(t=>(0,R.jsxs)(`section`,{className:U.group,children:[(0,R.jsxs)(`h2`,{className:U.groupLabel,children:[t.label,` `,(0,R.jsx)(`span`,{className:U.groupCount,children:t.items.length})]}),(0,R.jsx)(`ol`,{className:U.deck,children:t.items.map(({row:t,i:n})=>{let r=t.status===`done`,i=t.status===`done`?0:dg(we,t.text,p),a=te===t.id,o=Qe?.id===t.id;return(0,R.jsxs)(`li`,{className:B(U.card,o&&U.cardNext,Ke(t)&&U.cardActive,r&&U.cardDone),children:[(0,R.jsxs)(`div`,{className:U.cardTop,children:[(0,R.jsx)(`span`,{className:B(U.cardNum,Ke(t)&&U.cardNumActive),children:String(n+1).padStart(2,`0`)}),Ke(t)?(0,R.jsx)(`span`,{className:U.cardTagActive,children:e(`in progress`)}):o&&(0,R.jsx)(`span`,{className:U.cardTag,children:e(`up next`)}),(0,R.jsxs)(`span`,{className:U.cardCheck,children:[(0,R.jsxs)(`span`,{className:U.kebabWrap,"data-kebab":!0,children:[(0,R.jsx)(`button`,{type:`button`,className:U.kebabBtn,"aria-label":e(`task options`),"aria-expanded":ge===t.id,onClick:()=>_e(e=>e===t.id?null:t.id),children:`â¯`}),ge===t.id&&(0,R.jsxs)(`div`,{className:U.kebabMenu,role:`menu`,children:[!r&&(0,R.jsx)(`button`,{type:`button`,className:U.kebabItem,onClick:()=>{_e(null),Pe(t)},children:t.started_at?e(`put back to not started`):e(`start â mark in progress`)}),(0,R.jsx)(`button`,{type:`button`,className:U.kebabItem,onClick:()=>{_e(null),ke(t)},children:e(`edit`)}),d===`today`&&!r&&(0,R.jsx)(`button`,{type:`button`,className:U.kebabItem,onClick:()=>{_e(null),Ne(t)}
65,title:e(`carry this to tomorrow instead of missing it`),children:e(`â tomorrow`)}),d===`today`&&!r&&(0,R.jsx)(`button`,{type:`button`,className:U.kebabItem,onClick:()=>{_e(null),Le(t)},title:e(`swap or drop this with a reason â counts as changed, not missed`),children:e(`change`)}),(0,R.jsx)(`button`,{type:`button`,className:U.kebabItem,onClick:()=>{_e(null),ye(e=>{let n=new Set(e);return n.has(t.id)?n.delete(t.id):n.add(t.id),n})},children:ve.has(t.id)?e(`hide breakdown`):e(`breakdown`)}),(0,R.jsx)(`button`,{type:`button`,className:B(U.kebabItem,U.kebabItemDanger),onClick:()=>{_e(null),Me(t)},children:e(`delete`)})]})]}),(0,R.jsx)(Vl,{checked:r,onChange:()=>Fe(t),label:t.text,loading:k===t.id})]})]}),a?(0,R.jsx)(`input`,{className:U.editInput,type:`text`,value:re,autoFocus:!0,onChange:e=>M(e.target.value),onKeyDown:e=>{e.key===`Enter`&&je(t),e.key===`Escape`&&Ae()}}):(0,R.jsx)(`p`,{className:B(U.cardTask,r&&U.taskDone),children:t.text}),i>=2?(0,R.jsx)(vm,{children:e(`DRIFT · skipped {n} days running â Crew's watching this one`).replace(`{n}`,String(i))}):(0,R.jsxs)(`span`,{className:U.rowMeta,children:[(0,R.jsx)(`span`,{className:U.catChip,children:e(t.category)}),(0,R.jsx)(zl,{resolution:t.resolution,late:t.resolved_late,size:`sm`}),(()=>{let n=t.parent_id?ue[t.parent_id]:null,r=!!n&&y_(n)===y_(t.text),i=t.carry_count>0?e(`day {n}`).replace(`{n}`,String(t.carry_count+1)):null;return!n&&!i?null:n&&!r?(0,R.jsxs)(`span`,{className:U.sliceChip,title:n,children:[e(`part of: {p}`).replace(`{p}`,n),i?` · ${i}`:``]}):i?(0,R.jsx)(`span`,{className:U.sliceChip,children:i}):null})()]}),N===t.id&&(0,R.jsxs)(`div`,{className:U.renegPanel,children:[(0,R.jsx)(`span`,{className:U.renegLabel,children:ce>=2?e(`you've used your 2 changes today â this one counts as a miss.`):e(`renegotiate this task â it'll read as changed, not missed. ({n} left today)`).replace(`{n}`,String(2-ce))}),(0,R.jsx)(`input`,{className:U.renegInput,type:`text`,value:oe,placeholder:e(`swap for⦠(leave as-is to just drop it)`),onChange:e=>se(e.target.value)}),(0,R.jsx)(`input`,{className:U.renegInput,type:`text`,value:ae,placeholder:e(`why? (one line)`),onChange:e=>P(e.target.value)}),(0,R.jsxs)(`div`,{className:U.renegActions,children:[(0,R.jsx)(`button`,{type:`button`,className:U.renegSwap,disabled:!ae.trim()||!oe.trim()||oe.trim()===t.text,onClick:()=>Re(t,`swap`),children:e(`swap`)}),(0,R.jsx)(`button`,{type:`button`,className:U.renegDrop,disabled:!ae.trim(),onClick:()=>Re(t,`drop`),children:e(ce>=2?`drop (miss)`:`drop`)}),(0,R.jsx)(`button`,{type:`button`,className:U.renegCancel,onClick:()=>ie(null),children:e(`cancel`)})]})]}),a&&(0,R.jsxs)(`span`,{className:U.editActions,children:[(0,R.jsx)(`button`,{type:`button`,className:U.editActionBtn,onClick:()=>je(t),children:e(`save`)}),(0,R.jsx)(`button`,{type:`button`,className:U.editActionBtn,onClick:Ae,children:e(`cancel`)})]}),ve.has(t.id)&&(0,R.jsx)(S_,{priorityId:t.id,t:e,onChanged:Ce})]},t.id)})})]},t.key)),(0,R.jsx)(D_,{userId:a,date:p,workspaceId:s?.id,onAdded:Oe}),He.some(e=>e.status!==`done`&&dg(we,e.text,p)>=2)&&(0,R.jsxs)(`div`,{className:U.nudge,children:[(0,R.jsx)(`span`,{className:U.nudgeIcon,"aria-hidden":!0,children:(0,R.jsx)(`span`,{className:U.nudgeCaret})}),(0,R.jsxs)(`div`,{className:U.nudgeBody,children:[(0,R.jsx)(`span`,{className:U.nudgeLabel,children:`crew`}),(0,R.jsx)(`span`,{className:U.nudgeText,children:e(`that one's been dodged before. close it out before tonight's check-in.`)})]})]}),(0,R.jsx)(`div`,{className:U.markRow,children:Ue?(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`span`,{className:U.marked,children:e(`â today's logged`)}),(0,R.jsx)(`button`,{type:`button`,className:U.markedUndo,onClick:Ve,children:e(`undo`)})]}):fe?(0,R.jsxs)(`div`,{className:U.markConfirm,children:[(0,R.jsx)(`span`,{className:U.markConfirmText,children:e(`{n} still pending â mark today done anyway? they'll count as skipped, and any active pledge breaks.`).replace(`{n}`,String(Ge))}),(0,R.jsxs)(`div`,{className:U.markConfirmActions,children:[(0,R.jsx)(Sm,{onClick:Be,children:e(`mark done anyway`)}),(0,R.jsx)(`button`,{type:`button`,className:U.markConfirmCancel,onClick:()=>pe(!1),children:e(`never mind`)})]})]}):(0,R.jsx)(Sm,{onClick:ze,children:e(`Mark today done`)})})]})}),D&&a&&(0,R.jsx)(j_,{row:D,userId:a,autoVerifyNote:j,onClose:()=>O(null),onDone:(e,t)=>Ie(D,e,t)}),(0,R.jsx)(n_,{state:xe,onDone:()=>Se(null)}),(0,R.jsx)(dh,{})]})}function w_({dayMode:e,setDayMode:t}
65){let n=z(),r=pt();return(0,R.jsxs)(`nav`,{className:U.nav,children:[(0,R.jsx)(Rn,{to:`/app`,className:U.navBack,children:n(`â dashboard`)}),(0,R.jsx)(El,{size:20}),(0,R.jsxs)(`div`,{className:U.dayToggle,children:[(0,R.jsx)(`button`,{className:B(U.dayBtn,e===`today`&&U.dayBtnActive),onClick:()=>t(`today`),children:n(`today`)}),(0,R.jsx)(`button`,{className:B(U.dayBtn,e===`tomorrow`&&U.dayBtnActive),onClick:()=>t(`tomorrow`),children:n(`tomorrow`)}),(0,R.jsx)(`button`,{className:U.dayBtn,onClick:()=>r(`/app/calendar`),"aria-label":n(`pick another day`),children:n(`other day`)})]})]})}function T_(e,t=`en`){return new Date(e+`T12:00:00Z`).toLocaleDateString(t===`fr`?`fr-FR`:`en-US`,{weekday:`long`,month:`short`,day:`numeric`})}function E_({userId:e,date:t,workspaceId:n,taskCount:r=3,reentry:i=!1,carryable:a=[],onLocked:o}){let s=z(),{profile:c}=ll(),l=c,[u,d]=(0,_.useState)(!1),f=i&&!u,p=f?1:r,[m,h]=(0,_.useState)(()=>{try{return localStorage.getItem(`crew.lockTipDismissed`)===`1`}catch{return!1}});function g(){h(!0);try{localStorage.setItem(`crew.lockTipDismissed`,`1`)}catch{}}let[v,y]=(0,_.useState)(()=>Array.from({length:p},()=>({text:``,category:null}))),[b,x]=(0,_.useState)(``),[S,C]=(0,_.useState)(!1),[w,T]=(0,_.useState)(new Set),E=t===rf(),[D,O]=(0,_.useState)(!1),[k,A]=(0,_.useState)(!1),[j,ee]=(0,_.useState)([]),[te,ne]=(0,_.useState)(new Set),re=e=>`${e.source}:${e.text}`;async function M(){O(!0),A(!0),ee(await h_()),A(!1)}function N(e){y(t=>{let n=t.findIndex(e=>!e.text.trim());return n>=0?t.map((t,r)=>r===n?{...t,text:e.text}:t):t.length>=ue?t:[...t,{text:e.text,category:null}]}),ne(t=>new Set(t).add(re(e)))}let[ie,ae]=(0,_.useState)(null),[P,oe]=(0,_.useState)(new Set);function se(e){let t={text:e.text,category:e.category??null,carryCount:(e.carryCount??0)+1,parentId:e.parentId??null,carrySourceId:e.id??null};y(e=>{let n=e.findIndex(e=>!e.text.trim());return n>=0?e.map((e,r)=>r===n?{...e,...t}:e):e.length>=ue?e:[...e,t]}),e.id&&oe(t=>new Set(t).add(e.id))}let ce=(0,_.useMemo)(()=>{let e=[],t={github:`GitHub`,linear:`Linear`,notion:`Notion`};for(let n of j){let r=e.find(e=>e.source===n.source);r||(r={source:n.source,label:t[n.source],items:[]},e.push(r)),r.items.push(n)}return e},[j]);(0,_.useEffect)(()=>{y(e=>{if(e.length===p)return e;if(e.length<p)return[...e,...Array.from({length:p-e.length},()=>({text:``,category:null}))];let t=e;for(;t.length>p&&!t[t.length-1].text.trim();)t=t.slice(0,-1);return t})},[p]);function le(e,t){y(n=>n.map((n,r)=>r===e?{...n,category:t}:n)),T(t=>{if(!t.has(e))return t;let n=new Set(t);return n.delete(e),n})}let ue=12;function de(){v.length>=12||y(e=>[...e,{text:``,category:null}])}function fe(e){v.length<=1||(y(t=>t.filter((t,n)=>n!==e)),T(t=>{if(t.size===0)return t;let n=new Set;for(let r of t)r<e?n.add(r):r>e&&n.add(r-1);return n}))}async function pe(){if(v.some(e=>!e.text.trim())){x(s(`fill in all {n}`).replace(`{n}`,String(v.length)));return}let r=new Set(v.reduce((e,t,n)=>(t.category||e.push(n),e),[]));if(r.size>0){T(r),x(s(`pick a category for every task`));return}T(new Set),x(``),C(!0);let{error:i}=await Kd(e,t,v,n);if(C(!1),i){x(i.message.toLowerCase());return}$l(`day_locked`,{count:v.length,day:t}),l!=null&&l.onboarding_mode!==`active`&&tu(`first_lock`),L.from(`profiles`).update({onboarding_mode:`active`}).eq(`id`,e),o()}return(0,R.jsxs)(`div`,{className:U.lockForm,children:[f&&(0,R.jsxs)(`div`,{className:U.catchUpBanner,children:[(0,R.jsx)(`span`,{children:s(`back at it â just lock in one to start. add more if you feel it.`)}),(0,R.jsx)(`button`,{type:`button`,className:U.catchUpDismiss,onClick:()=>d(!0),children:s(`start with my usual {n}`).replace(`{n}`,String(r))})]}),!m&&(0,R.jsxs)(`p`,{className:U.lockTip,children:[(0,R.jsx)(`span`,{children:s(`tip: make each one checkable but not rigid. add a number so it's measurable ("outreach to 10 founders", not "do some outreach") â but keep it about the outcome, not the exact tool ("outreach to 10 solo founders" rather than "send 10 LinkedIn DMs"). vague-but-numbered beats over-specific.`)}),(0,R.jsx)(`button`,{type:`button`,className:U.lockTipDismiss,onClick:g,"aria-label":s(`dismiss tip`),title:s(`dismiss tip`),children:`Ã`})]}),E&&a.length>0&&(0,R.jsxs)(`div`,{className:U.importBox,children:[(0,R.jsx)(`span`,{className:U.importSourceLabel,children:s(`carry from yesterday`)}),(0,R.jsx)(`div`,{className:U.importChips,children:a.map((e,t)=>{let n=!!e.id&&P.has(e.id);return(0,R.jsxs)(`button`,{type:`button`,className:B(U.importChip,n&&U.importChipUsed),onClick:()=>se(e),disabled:n,title:n?s(`added`):e.text,children:[n?`â `:`â© `,e.text]},e.id??t)})})]}),E&&(0,R.jsx)(`div`,{className:U.importBox,children:D?k?(0,R.jsx)(`p`,{className:U.importNote,children:s(`checking your connected toolsâ¦`)}):j.length===0?(0,R.jsx)(`p`,{className:U.importNote,children:s(`no open items found in your connected tools.`)}):(0,R.jsx)(`div`,{className:U.importGroups,children:ce.map(e=>(0,R.jsxs)(`div`,{className:U.importGroup,children:[(0,R.jsx)(`span`,{className:U.importSourceLabel,children:e.label}),(0,R.jsx)(`div`,{className:U.importChips,children:e.items.map((t,n)=>{let r=te.has(re(t));return(0,R.jsxs)(`button`,{type:`button`,className:B(U.importChip,r&&U.importChipUsed),onClick:()=>N(t),disabled:r,title:r?s(`added`):t.text,children:[r?`â `:`+ `,t.text]},`${e.source}-${n}`)})})]},e.source))}):(0,R.jsxs)(`button`,{type:`button`,className:U.importToggle,onClick:M,children:[`â `,s(`import from your tools`)]})}),(0,R.jsx)(`p`,{className:U.catLegend,children:s(`tag each one: build = the product itself · sales = customers · ops = keeps the business running`)}),v.map((e,t)=>(0,R.jsxs)(`div`,{className:U.lockRow,children:[(0,R.jsx)(`span`,{className:U.lockNum,children:t+1}),(0,R.jsx)(`input`,{className:U.lockInput,type:`text`,placeholder:s(`what actually moves the needle?`),value:e.text,onChange:e=>y(n=>n.map((n,r)=>r===t?{...n,text:e.target.value}:n))}),(0,R.jsx)(l_,{onText:e=>y(n=>n.map((n,r)=>r===t?{...n,text:n.text?`${n.text} ${e}`:e}:n))}),(0,R.jsx)(`div`,{className:U.catRow,children:__.map(n=>(0,R.jsx)(`button`,{type:`button`,className:B(U.catBtn,e.category===n&&U.catBtnActive,w.has(t)&&U.catBtnMissing),onClick:()=>le(t,n),title:s(x_[n]),children:s(n)},n))}),ie===t?(0,R.jsxs)(`div`,{className:U.rowExtra,children:[(0,R.jsxs)(`div`,{className:U.receiptRow,role:`group`,"aria-label":s(`what will prove this?`),children:[(0,R.jsx)(`span`,{className:U.receiptLabel,children:s(`what will prove this?`)}),v_.map(n=>(0,R.jsx)(`button`,{type:`button`,className:B(U.receiptChip,e.receiptKind===n.kind&&U.receiptChipActive,n.kind===`none`&&e.receiptKind===`none`&&U.receiptChipNone),"aria-pressed":e.receiptKind===n.kind,onClick:()=>y(e=>e.map((e,r)=>r===t?{...e,receiptKind:e.receiptKind===n.kind?null:n.kind}:e)),children:s(n.label)},n.kind))]}),(0,R.jsxs)(`div`,{className:U.whenRow,children:[(0,R.jsx)(`span`,{className:U.whenLabel,children:s(`when?`)}),(0,R.jsx)(`input`,{className:U.whenInput,type:`text`,maxLength:60,placeholder:s(`after standup · optional`),value:e.planWhen??``,onChange:e=>y(n=>n.map((n,r)=>r===t?{...n,planWhen:e.target.value}:n))})]}),(0,R.jsx)(`div`,{className:U.multidayRow,children:e.parentTitle===void 0?(0,R.jsx)(`button`,{type:`button`,className:U.multidayToggle,onClick:()=>y(e=>e.map((e,n)=>n===t?{...e,parentTitle:``}:e)),children:s(`+ one day of a bigger effort`)}):(0,R.jsxs)(`div`,{className:U.multidayField,children:[(0,R.jsx)(`input`,{className:U.multidayInput,type:`text`,placeholder:s(`the bigger goal this is one day ofâ¦`),value:e.parentTitle,autoFocus:!0,onChange:e=>y(n=>n.map((n,r)=>r===t?{...n,parentTitle:e.target.value}:n))}),(0,R.jsx)(`button`,{type:`button`,className:U.multidayClear,onClick:()=>y(e=>e.map((e,n)=>n===t?{...e,parentTitle:void 0}:e)),"aria-label":s(`not multi-day`),children:`Ã`})]})}),(0,R.jsx)(`button`,{type:`button`,className:U.rowExtraClose,onClick:()=>ae(null),children:s(`done`)})]}):(0,R.jsx)(`button`,{type:`button`,className:U.rowMore,onClick:()=>ae(t),children:b_(e,s)}),v.length>1&&(0,R.jsx)(`button`,{type:`button`,className:U.lockRemoveBtn,onClick:()=>fe(t),"aria-label":s(`remove this task`),title:s(`remove this task`),children:`Ã`})]},t)),v.length<12&&(0,R.jsxs)(`button`,{type:`button`,className:U.addTaskBtn,onClick:de,children:[`+ `,s(`add a task`)]}),b&&(0,R.jsx)(`p`,{className:U.lockError,children:b}),(0,R.jsx)(Sm,{onClick:pe,disabled:S,children:S?s(`lockingâ¦`):s(`lock the {n}`).replace(`{n}`,String(v.length))})]})}function D_({userId:e,date:t,workspaceId:n,onAdded:r}){let i=z(),[a,o]=(0,_.useState)(!1),[s,c]=(0,_.useState)(``),[l,u]=(0,_.useState)(null),[d,f]=(0,_.useState)(!1),[p,m]=(0,_.useState)(``);async function h(){let a=s.trim();if(!a){m(i(`what actually moves the needle?`));return}if(!l){m(i(`pick a category`));return}m(``),f(!0);let{error:d}=await Kd(e,t,[{text:a,category:l}],n);if(f(!1),d){m(d.message.toLowerCase());return}$l(`task_added`,{day:t}),c(``),u(null),o(!1),r()}return a?(0,R.jsxs)(`div`,{className:U.addTaskForm,children:[(0,R.jsxs)(`div`,{className:U.addTaskInputRow,children:[(0,R.jsx)(`input`,{className:U.addTaskInput,type:`text`,autoFocus:!0,placeholder:i(`what actually moves the needle?`),value:s,onChange:e=>c(e.target.value),onKeyDown:e=>{e.key===`Enter`&&h(),e.key===`Escape`&&(o(!1),m(``))}}),(0,R.jsx)(l_,{onText:e=>c(t=>t?`${t} ${e}`:e)})]}),(0,R.jsx)(`div`,{className:U.catRow,children:__.map(e=>(0,R.jsx)(`button`,{type:`button`,className:B(U.catBtn,l===e&&U.catBtnActive),onClick:()=>u(e),title:i(x_[e]),children:i(e)},e))}),(0,R.jsxs)(`div`,{className:U.addTaskActions,children:[(0,R.jsx)(`button`,{type:`button`,className:U.addTaskConfirm,onClick:h,disabled:d,children:i(d?`addingâ¦`:`add`)}),(0,R.jsx)(`button`,{type:`button`,className:U.addTaskCancel,onClick:()=>{o(!1),m(``)},children:i(`cancel`)})]}),p&&(0,R.jsx)(`p`,{className:U.lockError,children:p})]}):(0,R.jsxs)(`button`,{type:`button`,className:U.addTaskBtn,onClick:()=>o(!0),children:[`+ `,i(`add a task`)]})}var O_=[`crisis`,`deep_work`,`travel`,`offline`];function k_({userId:e,date:t}
65){let n=z(),[r,i]=(0,_.useState)(null),[a,o]=(0,_.useState)(!1),[s,c]=(0,_.useState)(``),[l,u]=(0,_.useState)(!1);(0,_.useEffect)(()=>{let n=!0;return f_(e,t).then(e=>{n&&i(e)}),()=>{n=!1}},[e,t]);async function d(n){u(!0),c(``);let{error:r}=await p_(e,t,n);if(u(!1),r){c(r);return}i(n),o(!1)}async function f(){u(!0),await m_(e,t),u(!1),i(null),c(``)}return r?(0,R.jsxs)(`div`,{className:U.modeRow,children:[(0,R.jsx)(`span`,{className:U.modeActive,children:n(u_[r])}),(0,R.jsx)(`span`,{className:U.modeBlurb,children:n(d_[r])}),(0,R.jsx)(`button`,{type:`button`,className:U.modeClear,onClick:f,disabled:l,"aria-label":n(`clear today's mode`),children:`Ã`})]}):(0,R.jsxs)(`div`,{className:U.modeRow,children:[a?(0,R.jsxs)(`div`,{className:U.modeChips,children:[O_.map(e=>(0,R.jsx)(`button`,{type:`button`,className:U.modeChip,onClick:()=>d(e),disabled:l,children:n(u_[e])},e)),(0,R.jsx)(`button`,{type:`button`,className:U.modeCancel,onClick:()=>{o(!1),c(``)},children:n(`never mind`)})]}):(0,R.jsxs)(`button`,{type:`button`,className:U.modeTrigger,onClick:()=>o(!0),children:[n(`rough day?`),` â`]}),s&&(0,R.jsx)(`span`,{className:U.modeErr,children:n(s)})]})}function A_({userId:e,date:t}){let n=z(),[r,i]=(0,_.useState)(null),[a,o]=(0,_.useState)(!1);(0,_.useEffect)(()=>{Ah(e,t).then(i)},[e,t]);async function s(n){await kh(e,t,n),i({consequence:n,status:`active`}),o(!1)}return r?(0,R.jsxs)(`div`,{className:U.commitBar,children:[(0,R.jsx)(`span`,{className:U.commitChain,children:`â`}),r.status===`broken`?(0,R.jsxs)(`span`,{className:U.commitBroken,children:[n(`the pledge went unkept`),`: `,Oh[r.consequence]]}):(0,R.jsxs)(`span`,{children:[n(`on the line`),`: `,Oh[r.consequence]]})]}):(0,R.jsx)(`div`,{className:U.commitBar,children:a?(0,R.jsxs)(`div`,{className:U.commitOpts,children:[Object.keys(Oh).map(e=>(0,R.jsx)(`button`,{type:`button`,className:U.commitOpt,onClick:()=>s(e),children:Oh[e]},e)),(0,R.jsx)(`button`,{type:`button`,className:U.commitCancel,onClick:()=>o(!1),children:n(`never mind`)})]}):(0,R.jsxs)(`button`,{className:U.commitBtn,onClick:()=>o(!0),children:[`â `,n(`put something on the line`)]})})}function j_({row:e,userId:t,autoVerifyNote:n,onClose:r,onDone:i}){let a=z(),[o,s]=(0,_.useState)(``),[c,l]=(0,_.useState)(!1),[u,d]=(0,_.useState)(``),[f,p]=(0,_.useState)(``),[m,h]=(0,_.useState)(`none`),[g,v]=(0,_.useState)(``),[y,b]=(0,_.useState)(!1),[x,S]=(0,_.useState)(!1),[C,w]=(0,_.useState)(null),[T,E]=(0,_.useState)(``),D=(0,_.useRef)(null);(0,_.useEffect)(()=>{let e=e=>{e.key===`Escape`&&r()};return document.addEventListener(`keydown`,e),()=>document.removeEventListener(`keydown`,e)},[r]);async function O(e){let n=e.target.files?.[0];if(n){l(!0);try{let e=n.name.split(`.`).pop()??`png`,r=`${t}/${Date.now()}.${e}`,{error:i}=await L.storage.from(`proof-uploads`).upload(r,n,{contentType:n.type});i||(d(r),p(n.name),w(null))}finally{l(!1),D.current&&(D.current.value=``)}}}function k(){let e=f?`ð ${f.replace(/[·â¢]/g,`-`)}`:``;return[o.trim(),e].filter(Boolean).join(` · `)}function A(e,t=`done`){b(!0),i(e,t)}async function j(){S(!0);let t=await wh({priorityId:e.id,imagePath:u||void 0,note:o.trim()||void 0});if(S(!1),!t){A(k());return}if(t.proofClass===`verified`){A(`${k()} · â crew reviewed: ${t.message}`);return}w(t),E(`${o.trim()}|${u}`)}function ee(){if(m===`cant`){A(`${a(`couldn't do it`)} â ${g.trim()}`,`skipped`);return}j()}let te=`${o.trim()}|${u}`,ne=C!==null&&te===T,re=m===`cant`?g.trim().length>0:(o.trim().length>0||!!u)&&!ne;return(0,R.jsx)(`div`,{className:U.proofBackdrop,onClick:r,children:(0,R.jsxs)(`div`,{className:U.proofModal,onClick:e=>e.stopPropagation(),children:[(0,R.jsxs)(`div`,{className:U.proofHead,children:[(0,R.jsx)(`span`,{className:U.proofKicker,children:a(`prove it`)}),(0,R.jsx)(`button`,{className:U.proofClose,onClick:r,"aria-label":a(`close`),children:`Ã`})]}),(0,R.jsx)(`p`,{className:U.proofTask,children:e.text}),m===`none`&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`div`,{className:U.proofHint,children:a(n===`no connected tools have any evidence yet for this task`?`I'm not actually connected anywhere I could check this automatically â share a direct link or a screenshot and I'll verify it right away.`:n===`checked your connected tools but found nothing matching this task`?`I checked your connected tools but couldn't find anything matching this â share a direct link or a screenshot and I'll verify it right away.`:`Crew couldn't auto-verify this.`)}),(0,R.jsxs)(`div`,{className:U.proofChoiceRow,children:[(0,R.jsx)(Sm,{onClick:()=>h(`proof`),children:a(`I can add proof`)}),(0,R.jsx)(Sm,{onClick:()=>h(`cant`),children:a(`I couldn't do it`)})]})]}),m!==`none`&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`div`,{className:U.proofHint,children:a(m===`proof`?`for this one: add a screenshot showing it, or just tell me what you did â doesn't need to be perfect, just enough for me to see it's real.`:`what actually happened? a genuine, specific reason â Crew checks it, so a vague one gets sent back.`)}),m===`proof`?(0,R.jsxs)(R.Fragment,{children:[(0,R.jsxs)(`div`,{className:U.proofFieldWrap,children:[(0,R.jsx)(`textarea`,{className:U.proofTextarea,placeholder:a(`a link, a quick note, whatever's easiestâ¦`),value:o,onChange:e=>s(e.target.value)}),(0,R.jsx)(l_,{className:U.fieldMic,onText:e=>s(t=>t?`${t} ${e}`:e)})]}),(0,R.jsx)(`input`,{ref:D,type:`file`,accept:`image/*,application/pdf`,style:{display:`none`},onChange:O}),(0,R.jsx)(`button`,{type:`button`,className:U.proofFileBtn,onClick:()=>
65D.current?.click(),disabled:c,children:c?a(`uploadingâ¦`):f?`â ${f}`:a(`â or attach a screenshot`)})]}):(0,R.jsxs)(`div`,{className:U.proofFieldWrap,children:[(0,R.jsx)(`textarea`,{className:U.proofTextarea,placeholder:a(`what happened? (e.g. call got pushed, blocked on Xâ¦)`),value:g,onChange:e=>v(e.target.value)}),(0,R.jsx)(l_,{className:U.fieldMic,onText:e=>v(t=>t?`${t} ${e}`:e)})]}),x&&(0,R.jsx)(`div`,{className:U.proofChecking,children:a(`Crew is reviewing your proofâ¦`)}),C&&!x&&(0,R.jsxs)(`div`,{className:B(U.proofReviewMsg,C.proofClass===`insufficient`?U.proofInsufficient:U.proofUncertain),children:[C.message,C.corroboration.length>0&&(0,R.jsxs)(`span`,{className:U.proofCorrob,children:[a(`â backed by same-day activity: `),C.corroboration.map(e=>e.title).join(`, `)]}),ne&&(0,R.jsx)(`span`,{className:U.proofCorrob,style:{color:`var(--text-dim)`},children:a(`add more detail or a better screenshot, then check again.`)})]}),(0,R.jsxs)(`div`,{className:U.proofActions,children:[(0,R.jsx)(Sm,{onClick:ee,disabled:!re||y||x,children:a(y?`savingâ¦`:x?`reviewingâ¦`:m===`cant`?`mark not done`:C?`recheck proof`:`check proof & mark done`)}),(0,R.jsx)(`button`,{type:`button`,className:U.proofCantBtn,onClick:()=>{h(`none`),w(null),E(``)},children:a(`â back`)})]})]})]})})}var M_={page:`_page_o0suo_1`,card:`_card_o0suo_9`,logo:`_logo_o0suo_17`,tabs:`_tabs_o0suo_25`,tab:`_tab_o0suo_25`,tabActive:`_tabActive_o0suo_35`,googleBtn:`_googleBtn_o0suo_62`,githubBtn:`_githubBtn_o0suo_84`,divider:`_divider_o0suo_108`,form:`_form_o0suo_126`,field:`_field_o0suo_132`,label:`_label_o0suo_138`,labelRow:`_labelRow_o0suo_146`,forgot:`_forgot_o0suo_152`,input:`_input_o0suo_165`,passwordWrap:`_passwordWrap_o0suo_182`,eyeBtn:`_eyeBtn_o0suo_190`,error:`_error_o0suo_209`,notice:`_notice_o0suo_218`,hint:`_hint_o0suo_230`,gate:`_gate_o0suo_239`,gateTitle:`_gateTitle_o0suo_245`,gateSub:`_gateSub_o0suo_253`,gateHelp:`_gateHelp_o0suo_260`,gateLink:`_gateLink_o0suo_268`,codeInput:`_codeInput_o0suo_281`,submit:`_submit_o0suo_290`,terms:`_terms_o0suo_307`,termsLink:`_termsLink_o0suo_315`,shake:`_shake_o0suo_329`,forgotPanel:`_forgotPanel_o0suo_338`,forgotTitle:`_forgotTitle_o0suo_344`,forgotSub:`_forgotSub_o0suo_352`,forgotBack:`_forgotBack_o0suo_359`},N_=8;function P_(){return(0,R.jsxs)(`svg`,{width:`17`,height:`17`,viewBox:`0 0 24 24`,"aria-hidden":!0,children:[(0,R.jsx)(`path`,{d:`M22.56 12.25c0-.78-.07-1.53-.2-2.25H12v4.26h5.92c-.26 1.37-1.04 2.53-2.21 3.31v2.77h3.57c2.08-1.92 3.28-4.74 3.28-8.09z`,fill:`#4285F4`}),(0,R.jsx)(`path`,{d:`M12 23c2.97 0 5.46-.98 7.28-2.66l-3.57-2.77c-.98.66-2.23 1.06-3.71 1.06-2.86 0-5.29-1.93-6.16-4.53H2.18v2.84C3.99 20.53 7.7 23 12 23z`,fill:`#34A853`}),(0,R.jsx)(`path`,{d:`M5.84 14.09c-.22-.66-.35-1.36-.35-2.09s.13-1.43.35-2.09V7.07H2.18C1.43 8.55 1 10.22 1 12s.43 3.45 1.18 4.93l3.66-2.84z`,fill:`#FBBC05`}),(0,R.jsx)(`path`,{d:`M12 5.38c1.62 0 3.06.56 4.21 1.64l3.15-3.15C17.45 2.09 14.97 1 12 1 7.7 1 3.99 3.47 2.18 7.07l3.66 2.84c.87-2.6 3.3-4.53 6.16-4.53z`,fill:`#EA4335`})]})}function F_(e,t){let n=t.toLowerCase();return n.includes(`invalid login credentials`)||n.includes(`invalid credentials`)?e(`that email and password don't match an account. check the password, or use âforgot password?â to reset it.`):n.includes(`email not confirmed`)?e(`confirm your email first â open the link we sent you, then sign in.`):n.includes(`already registered`)||n.includes(`already been registered`)||n.includes(`user already exists`)?e(`that email already has an account â switch to sign in.`):n.includes(`access code`)||n.includes(`database error saving new user`)||n.includes(`check_violation`)?e(`crew is invite-only right now. enter your invite code above before creating an account â or join the waitlist.`):n.includes(`password`)&&(n.includes(`at least`)||n.includes(`short`)||n.includes(`weak`)||n.includes(`6 characters`))?e(`password needs at least 8 characters.`):n.includes(`rate limit`)||n.includes(`for security purposes`)||n.includes(`too many`)?e(`too many attempts. wait about a minute, then try again.`):n.includes(`failed to fetch`)||n.includes(`networkerror`)||n.includes(`load failed`)?e(`couldn't reach crew. check your connection and try again.`):n.includes(`invali
65d`)&&n.includes(`email`)?e(`that email address looks wrong â check it for typos.`):t}function I_(){let e=pt(),t=z(),{lang:n}=ml(),[r,i]=(0,_.useState)(()=>sessionStorage.getItem(`crew.access`)===`1`),[a,o]=(0,_.useState)(``),[s,c]=(0,_.useState)(!1),[l,u]=(0,_.useState)(!1),[d,f]=(0,_.useState)(``),[p,m]=(0,_.useState)(!1),h=(0,_.useRef)(null),[g,v]=(0,_.useState)(`signin`),[y,b]=(0,_.useState)(``),[x,S]=(0,_.useState)(``),[C,w]=(0,_.useState)(!1),[T,E]=(0,_.useState)(!1),[D,O]=(0,_.useState)(null),[k,A]=(0,_.useState)(``),[j,ee]=(0,_.useState)(``),[te,ne]=(0,_.useState)(!1),re=(0,_.useRef)(null),M=(0,_.useRef)(null);(0,_.useEffect)(()=>{let e=new URLSearchParams(window.location.search),n=new URLSearchParams(window.location.hash.replace(/^#/,``)),r=e.get(`error_description`)??n.get(`error_description`),a=e.get(`error`)??n.get(`error`);if(!r&&!a)return;let o=(r??a??``).toLowerCase();o.includes(`database error saving new user`)||o.includes(`access code`)||o.includes(`check_violation`)||o.includes(`unexpected_failure`)?(v(`signup`),sessionStorage.removeItem(`crew.access`),i(!1),f(t(`that google or github account is new here, and crew is invite-only. enter your invite code below, then sign up with the same account â it takes 20 seconds.`)),setTimeout(()=>h.current?.focus(),0)):A(F_(t,r??a??``)),window.history.replaceState(null,``,window.location.pathname)},[]);async function N(e){if(e.preventDefault(),l)return;let n=a.trim();if(!n){f(t(`enter the invite code you were given.`)),h.current?.focus();return}u(!0),f(``);let{data:r,error:o}=await L.functions.invoke(`signup-grant`,{body:{code:n,validateOnly:!0}});if(u(!1),!o&&r?.ok){sessionStorage.setItem(`crew.access`,`1`),sessionStorage.setItem(`crew.accessCode`,n),i(!0),m(!0);return}let s=0,d={},p=o?.context;if(p&&typeof p==`object`&&`status`in p){s=p.status;try{d=await p.clone().json()}catch{}}s===429||(d.error??``).includes(`too many`)?f(t(`too many tries from this network. wait 10 minutes and try again â the code still works.`)):f(t(s===403||s===400?`that code isn't valid. check it character by character â it's the code from your invite email or DM.`:s===0?`couldn't reach crew. check your connection and try again.`:`something went wrong on our side. try again in a moment.`)),c(!0),setTimeout(()=>c(!1),400),h.current?.focus(),h.current?.select()}async function ie(){let e=sessionStorage.getItem(`crew.accessCode`)??``;if(!e)return sessionStorage.removeItem(`crew.access`),i(!1),f(t(`enter your invite code once more to continue.`)),!1;let{data:n,error:r}=await L.functions.invoke(`signup-grant`,{body:{code:e}});return!r&&n?.ok?!0:(sessionStorage.removeItem(`crew.access`),sessionStorage.removeItem(`crew.accessCode`),i(!1),f(t(`your invite code needs re-entering â put it in below and try again.`)),!1)}async function ae(e){if(e.preventDefault(),T)return;if(!y.trim()){A(t(`enter your email`)),re.current?.focus();return}A(``),E(!0);let{error:n}=await sh(y.trim());if(E(!1),n){A(F_(t,n.message));return}ne(!0)}async function P(r){if(r.preventDefault(),T)return;if(!y.trim()){A(t(`enter your email`)),re.current?.focus();return}if(!x){A(t(`enter your password`)),M.current?.focus();return}if(g===`signup`&&x.length<N_){A(t(`password needs at least 8 characters.`)),M.current?.focus();return}if(A(``),ee(``),E(!0),g===`signup`&&!await ie()){E(!1);return}let i=g===`signin`?await nh(y,x):await rh(y,x);if(E(!1),i.error){A(F_(t,i.error.message));return}if(g===`signup`){if(!(`data`in i&&i.data?.session)){ee(t(`almost there â open the confirmation link we just emailed you, then come back and sign in.`));return}let r=`data`in i?i.data?.user?.id:void 0;n===`fr`&&r&&gl(r,`fr`),e(`/onboarding`,{replace:!0})}else e(`/app`,{replace:!0})}async function oe(){if(T||D)return;if(A(``),O(`github`),E(!0),g===`signup`&&!await ie()){E(!1),O(null);return}let{error:e}=await ih();e&&(A(F_(t,e.message)),E(!1),O(null))}async function se(){if(T||D)return;if(A(``),O(`google`),E(!0),g===`signup`&&!await ie()){E(!1),O(null);return}let{error:e}=await ah();e&&(A(F_(t,e.message)),E(!1),O(null))}function ce(e){v(e),A(``),ee(``),ne(!1)}let le=g===`signup`&&!r;return(0,R.jsx)(`div`,{className:M_.page,children:(0,R.jsxs)(`div`,{className:M_.card,children:[(0,R.jsx)(`div`,{className:M_.logo,
65children:(0,R.jsx)(Rn,{to:`/`,"aria-label":t(`back to home`),children:(0,R.jsx)(El,{size:22})})}),(0,R.jsxs)(`div`,{className:M_.tabs,role:`group`,"aria-label":t(`sign in or create account`),children:[(0,R.jsx)(`button`,{type:`button`,className:g===`signin`?M_.tabActive:M_.tab,"aria-pressed":g===`signin`,onClick:()=>ce(`signin`),children:t(`sign in`)}),(0,R.jsx)(`button`,{type:`button`,className:g===`signup`?M_.tabActive:M_.tab,"aria-pressed":g===`signup`,onClick:()=>ce(`signup`),children:t(`create account`)})]}),le&&(0,R.jsxs)(`div`,{className:M_.gate,children:[(0,R.jsx)(`p`,{className:M_.gateTitle,children:t(`crew is invite-only for now`)}),(0,R.jsx)(`p`,{className:M_.gateSub,children:t(`early access runs on invite codes so we can onboard founders one at a time. your code is in the invite email or DM you got from us â it is short, and it is not your password.`)}),(0,R.jsxs)(`form`,{className:M_.form,onSubmit:N,noValidate:!0,children:[(0,R.jsxs)(`div`,{className:M_.field,children:[(0,R.jsx)(`label`,{className:M_.label,htmlFor:`access-code`,children:t(`invite code`)}),(0,R.jsx)(`input`,{id:`access-code`,ref:h,className:`${M_.input} ${M_.codeInput} ${s?M_.shake:``}`,type:`text`,autoComplete:`off`,spellCheck:!1,placeholder:t(`e.g. 1234`),value:a,onChange:e=>{o(e.target.value),f(``)},maxLength:16,autoFocus:!0,disabled:l,"aria-invalid":d?!0:void 0,"aria-describedby":d?`access-error`:void 0})]}),(0,R.jsx)(`p`,{id:`access-error`,className:M_.error,role:`alert`,"aria-live":`assertive`,children:d}),(0,R.jsx)(`button`,{type:`submit`,className:M_.submit,disabled:l,children:t(l?`checkingâ¦`:`unlock signup â`)})]}),(0,R.jsxs)(`p`,{className:M_.gateHelp,children:[t(`don't have a code?`),` `,(0,R.jsx)(Rn,{to:`/#waitlist`,className:M_.gateLink,children:t(`join the waitlist â`)}),(0,R.jsx)(`br`,{}),t(`already have an account?`),` `,(0,R.jsx)(`button`,{type:`button`,className:M_.gateLink,onClick:()=>ce(`signin`),children:t(`sign in instead`)})]})]}),g===`forgot`&&(0,R.jsx)(`div`,{className:M_.forgotPanel,children:te?(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`p`,{className:M_.forgotTitle,children:t(`check your inbox`)}),(0,R.jsxs)(`p`,{className:M_.forgotSub,children:[t(`we sent a reset link to`),` `,(0,R.jsx)(`strong`,{children:y}),`. `,t(`click it to set a new password.`)]}),(0,R.jsxs)(`button`,{type:`button`,className:M_.forgotBack,onClick:()=>{ce(`signin`)},children:[`â `,t(`back to sign in`)]})]}):(0,R.jsxs)(`form`,{onSubmit:ae,noValidate:!0,children:[(0,R.jsx)(`p`,{className:M_.forgotTitle,children:t(`reset password`)}),(0,R.jsx)(`p`,{className:M_.forgotSub,children:t(`enter your email and we'll send a link to set a new password.`)}),(0,R.jsx)(`input`,{ref:re,className:M_.input,type:`email`,placeholder:t(`[email protected]`),value:y,onChange:e=>{b(e.target.value),A(``)},autoFocus:!0,autoComplete:`email`,"aria-label":t(`email`),"aria-invalid":k?!0:void 0}),(0,R.jsx)(`p`,{className:M_.error,role:`alert`,"aria-live":`assertive`,children:k}),(0,R.jsx)(`button`,{type:`submit`,className:M_.submit,disabled:T,children:t(T?`sendingâ¦`:`send reset link`)}),(0,R.jsxs)(`button`,{type:`button`,className:M_.forgotBack,onClick:()=>ce(`signin`),children:[`â `,t(`sign in`)]})]})}),g!==`forgot`&&!le&&(0,R.jsxs)(R.Fragment,{children:[p&&g===`signup`&&(0,R.jsx)(`p`,{className:M_.notice,role:`status`,children:t(`invite accepted. pick any way to create your account below.`)}),(0,R.jsxs)(`button`,{type:`button`,className:M_.googleBtn,onClick:se,disabled:T,children:[(0,R.jsx)(P_,{}),t(D===`google`?`opening googleâ¦`:g===`signup`?`sign up with google`:`continue with google`)]}),(0,R.jsxs)(`button`,{type:`button`,className:M_.githubBtn,onClick:oe,disabled:T,children:[(0,R.jsx)(Wm,{name:`github`,size:15}),t(D===`github`?`opening githubâ¦`:g===`signup`?`sign up with github`:`continue with github`)]}),(0,R.jsx)(`div`,{className:M_.divider,children:(0,R.jsx)(`span`,{children:t(g===`signup`?`or use an email and password`:`or`)})}),(0,R.jsxs)(`form`,{className:M_.form,onSubmit:P,noValidate:!0,children:[(0,R.jsxs)(`div`,{className:M_.field,children:[(0,R.jsx)(`label`,{className:M_.label,htmlFor:`email`,children:t(`email`)}),(0,R.jsx)(`input`,{id:`email`,ref:re,className:M_.input,type:`email`,inputMode:`email`,placeholder:t(`you@y
65ourproduct.com`),value:y,onChange:e=>{b(e.target.value),A(``)},autoComplete:g===`signup`?`email`:`username`,autoFocus:!0,"aria-invalid":k?!0:void 0,"aria-describedby":k?`auth-error`:void 0})]}),(0,R.jsxs)(`div`,{className:M_.field,children:[(0,R.jsxs)(`div`,{className:M_.labelRow,children:[(0,R.jsx)(`label`,{className:M_.label,htmlFor:`password`,children:t(`password`)}),g===`signin`&&(0,R.jsx)(`button`,{type:`button`,className:M_.forgot,onClick:()=>ce(`forgot`),children:t(`forgot password?`)})]}),(0,R.jsxs)(`div`,{className:M_.passwordWrap,children:[(0,R.jsx)(`input`,{id:`password`,ref:M,className:M_.input,type:C?`text`:`password`,placeholder:g===`signup`?t(`at least 8 characters`):`â¢â¢â¢â¢â¢â¢â¢â¢`,value:x,onChange:e=>{S(e.target.value),A(``)},autoComplete:g===`signup`?`new-password`:`current-password`,minLength:g===`signup`?N_:void 0,"aria-describedby":g===`signup`?`pw-hint`:void 0,"aria-invalid":k?!0:void 0}),(0,R.jsx)(`button`,{type:`button`,className:M_.eyeBtn,onClick:()=>w(e=>!e),"aria-label":t(C?`hide password`:`show password`),children:(0,R.jsx)(Wm,{name:C?`eyeOff`:`eye`,size:14})})]}),g===`signup`&&(0,R.jsx)(`p`,{id:`pw-hint`,className:M_.hint,children:t(`at least 8 characters. nothing else required â no symbol quotas.`)})]}),(0,R.jsx)(`p`,{id:`auth-error`,className:M_.error,role:`alert`,"aria-live":`assertive`,children:k}),j&&(0,R.jsx)(`p`,{className:M_.notice,role:`status`,children:j}),(0,R.jsx)(`button`,{type:`submit`,className:M_.submit,disabled:T,children:t(T?g===`signin`?`signing inâ¦`:`creating accountâ¦`:g===`signin`?`sign in`:`create account`)})]}),g===`signup`&&(0,R.jsx)(`p`,{className:M_.gateHelp,children:t(`free until launch. no card needed.`)}),(0,R.jsxs)(`p`,{className:M_.terms,children:[t(`by continuing, you agree to crew's`),` `,(0,R.jsx)(Rn,{to:`/terms`,className:M_.termsLink,children:t(`terms`)}),` `,t(`and`),` `,(0,R.jsx)(Rn,{to:`/privacy`,className:M_.termsLink,children:t(`privacy policy`)}),`.`]})]})]})})}var L_={trouble:`_trouble_x9gr3_1`,troubleSummary:`_troubleSummary_x9gr3_7`,troubleBody:`_troubleBody_x9gr3_19`,troubleLine:`_troubleLine_x9gr3_30`,troubleLink:`_troubleLink_x9gr3_37`,troubleBot:`_troubleBot_x9gr3_39`,codeRow:`_codeRow_x9gr3_44`,code:`_code_x9gr3_44`,copyBtn:`_copyBtn_x9gr3_62`,troubleNote:`_troubleNote_x9gr3_75`};function R_({size:e=18}){return(0,R.jsx)(`svg`,{width:e,height:e,viewBox:`0 0 24 24`,fill:`currentColor`,"aria-hidden":!0,children:(0,R.jsx)(`path`,{d:`M11.944 0A12 12 0 0 0 0 12a12 12 0 0 0 12 12 12 12 0 0 0 12-12A12 12 0 0 0 12 0a12 12 0 0 0-.056 0zm4.962 7.224c.1-.002.321.023.465.14a.506.506 0 0 1 .171.325c.016.093.036.306.02.472-.18 1.898-.962 6.502-1.36 8.627-.168.9-.499 1.201-.82 1.23-.696.065-1.225-.46-1.9-.902-1.056-.693-1.653-1.124-2.678-1.8-1.185-.78-.417-1.21.258-1.91.177-.184 3.247-2.977 3.307-3.23.007-.032.014-.15-.056-.212s-.174-.041-.249-.024c-.106.024-1.793 1.14-5.061 3.345-.48.33-.913.49-1.302.48-.428-.008-1.252-.241-1.865-.44-.752-.245-1.349-.374-1.297-.789.027-.216.325-.437.893-.663 3.498-1.524 5.83-2.529 6.998-3.014 3.332-1.386 4.025-1.627 4.476-1.635z`})})}function z_({state:e}){let t=z(),[n,r]=(0,_.useState)(!1);if(e.connected||!e.url)return null;let i=(()=>{try{return new URL(e.url).pathname.replace(`/`,``)}catch{return``}})();async function a(){try{await navigator.clipboard.writeText(`/start ${e.code}`),r(!0),setTimeout(()=>r(!1),2e3)}catch{}}return(0,R.jsxs)(`details`,{className:L_.trouble,children:[(0,R.jsx)(`summary`,{className:L_.troubleSummary,children:t(`having trouble?`)}),(0,R.jsxs)(`div`,{className:L_.troubleBody,children:[(0,R.jsxs)(`p`,{className:L_.troubleLine,children:[t(`nothing opened? open this link yourself:`),` `,(0,R.jsx)(`a`,{className:L_.troubleLink,href:e.url,target:`_blank`,rel:`noreferrer`,children:e.url})]}),(0,R.jsxs)(`p`,{className:L_.troubleLine,children:[t(`still stuck? search for the bot in telegram and send it this message:`),i&&(0,R.jsxs)(R.Fragment,{children:[` `,(0,R.jsxs)(`span`,{className:L_.troubleBot,children:[`@`,i]})]})]}),(0,R.jsxs)(`div`,{className:L_.codeRow,children:[(0,R.jsxs)(`code`,{className:L_.code,children:[`/start `,e.code]}),(0,R.jsx)(`button`,{type:`button`,className:L_.copyBtn,onClick:a,children:t(n?`copied â`:`copy`)})]}),(0,R.jsx)(`p`,{className:L_.troubleNote,children:t(`this code expires in 15 minutes â click connect again for a fresh one.`)})]})]})}var B_=2e3,V_=180*1e3;
65function H_(e,t=!1){let n=z(),[r,i]=(0,_.useState)(t),[a,o]=(0,_.useState)(!1),[s,c]=(0,_.useState)(!1),[l,u]=(0,_.useState)(``),[d,f]=(0,_.useState)(``),[p,m]=(0,_.useState)(``),h=(0,_.useRef)(null),g=(0,_.useRef)(null),v=(0,_.useCallback)(()=>{h.current&&=(clearInterval(h.current),null),g.current&&=(clearTimeout(g.current),null),c(!1)},[]),y=(0,_.useCallback)(async()=>{if(!e)return!1;let{data:t}=await L.from(`profiles`).select(`telegram_chat_id`).eq(`id`,e).maybeSingle();return t?.telegram_chat_id?(i(!0),v(),!0):!1},[e,v]);return(0,_.useEffect)(()=>{if(!s)return;let e=()=>{y()};return window.addEventListener(`focus`,e),document.addEventListener(`visibilitychange`,e),()=>{window.removeEventListener(`focus`,e),document.removeEventListener(`visibilitychange`,e)}},[s,y]),(0,_.useEffect)(()=>v,[v]),{connected:r,linking:a,polling:s,code:l,url:d,error:p,start:(0,_.useCallback)(async()=>{if(!e)return;m(``);let t=window.open(``,`_blank`);o(!0);let{data:r,error:i}=await L.functions.invoke(`telegram-connect`);o(!1);let a=r?.url;if(i||!a){t?.close(),m(n(`couldn't reach telegram just now â try again in a second`));return}f(a),u(r.code??``),t&&(t.location.href=a),c(!0),h.current=setInterval(()=>{y()},B_),g.current=setTimeout(v,V_)},[e,y,v,n]),disconnect:(0,_.useCallback)(async()=>{e&&(await L.from(`profiles`).update({telegram_chat_id:null}).eq(`id`,e),i(!1))},[e]),setConnected:i}}var W={page:`_page_1uzjq_6`,card:`_card_1uzjq_14`,logoRow:`_logoRow_1uzjq_22`,progress:`_progress_1uzjq_30`,dot:`_dot_1uzjq_36`,dotFilled:`_dotFilled_1uzjq_44`,stepLabel:`_stepLabel_1uzjq_56`,stepBody:`_stepBody_1uzjq_67`,stepTitle:`_stepTitle_1uzjq_73`,stepSub:`_stepSub_1uzjq_83`,fields:`_fields_1uzjq_90`,field:`_field_1uzjq_90`,fieldLabel:`_fieldLabel_1uzjq_102`,input:`_input_1uzjq_110`,error:`_error_1uzjq_131`,actions:`_actions_1uzjq_137`,nextBtn:`_nextBtn_1uzjq_143`,backBtn:`_backBtn_1uzjq_163`,recommendedBadge:`_recommendedBadge_1uzjq_181`,loopStrip:`_loopStrip_1uzjq_200`,loopStripRow:`_loopStripRow_1uzjq_212`,loopBadge:`_loopBadge_1uzjq_218`,featureDesc:`_featureDesc_1uzjq_237`,tgBtn:`_tgBtn_1uzjq_245`,tgHint:`_tgHint_1uzjq_265`,tgDone:`_tgDone_1uzjq_272`,privacyNote:`_privacyNote_1uzjq_285`,goalNote:`_goalNote_1uzjq_297`,extLink:`_extLink_1uzjq_308`,extLinkText:`_extLinkText_1uzjq_318`,extLinkBtn:`_extLinkBtn_1uzjq_326`,stepEnter:`_stepEnter_1uzjq_348`,obStepIn:`_obStepIn_1uzjq_1`,roiLine:`_roiLine_1uzjq_357`,daysChip:`_daysChip_1uzjq_368`,obChipIn:`_obChipIn_1uzjq_1`,extEssential:`_extEssential_1uzjq_388`,verifyChoice:`_verifyChoice_1uzjq_406`,verifyOption:`_verifyOption_1uzjq_413`,verifyOptionOn:`_verifyOptionOn_1uzjq_428`,verifyOptionOff:`_verifyOptionOff_1uzjq_431`,verifyOptionTitle:`_verifyOptionTitle_1uzjq_433`,verifyOptionSub:`_verifyOptionSub_1uzjq_439`,verifyWarnBox:`_verifyWarnBox_1uzjq_441`,verifyWarnLead:`_verifyWarnLead_1uzjq_451`,verifyWarnBody:`_verifyWarnBody_1uzjq_457`,verifyMethods:`_verifyMethods_1uzjq_467`,verifyMethodsLead:`_verifyMethodsLead_1uzjq_468`,methodOption:`_methodOption_1uzjq_469`,methodOptionOn:`_methodOptionOn_1uzjq_478`,methodCheck:`_methodCheck_1uzjq_479`,methodTitle:`_methodTitle_1uzjq_488`,methodSub:`_methodSub_1uzjq_489`,methodHint:`_methodHint_1uzjq_490`,assistantBlock:`_assistantBlock_1uzjq_496`,skillCopy:`_skillCopy_1uzjq_501`,skillCopyLabel:`_skillCopyLabel_1uzjq_513`},U_=`crew.onboardingDraft`,W_=5,G_={1:`you`,2:`goal`,3:`verification`,4:`telegram`,5:`extension`};function K_(){try{let e=sessionStorage.getItem(U_);return e?JSON.parse(e):null}catch{return null}}function q_(){let e=pt(),{session:t,refreshProfile:n}=ll(),r=z(),i=K_(),[a,o]=(0,_.useState)(()=>{let e=i?.step??1;return e>=1&&e<=W_?e:1}),[s,c]=(0,_.useState)(i?.name??``),[l,u]=(0,_.useState)(i?.product??``),[d,f]=(0,_.useState)(i?.goal??``),[p,m]=(0,_.useState)(i?.goalDate??``),[h,g]=(0,_.useState)(i?.verifyOn??!0),[v,y]=(0,_.useState)(i?.verifyMethods??[]),[b,x]=(0,_.useState)(!1),[S,C]=(0,_.useState)(``),w=H_(t?.user?.id);(0,_.useEffect)(()=>{sessionStorage.setItem(U_,JSON.stringify({step:a,name:s,product:l,goal:d,goalDate:p,verifyOn:h,verifyMethods:v}))},[a,s,l,d,p,h,v]),(0,_.useEffect)(()=>{tu(G_[a])},[a]),(0,_.useEffect)(()=>{t?.user&&L.from(`profiles`).select(`telegram_chat_id`).eq(`id`,t.user.id).maybeSingle().then(({data:e})=>{e?.telegram_chat_id&&w.setConnected(!0)})},[t?.user?.id]);async function T(){if(!t?.user){C(r(`no active session â try signing in again`));return}x(!0);let{error:i}=await ch(t.user.id,{name:s,product_name:l,goal:d,goal_date:p.trim()===``?null:p});if(!i&&!h&&await L.from(`profiles`).update({verify_required:!1}).eq(`id`,t.user.id),i){x(!1),C(i.message?.toLowerCase()??`something went wrong`);return}await n(),x(!1),sessionStorage.removeItem(U_),$l(`onboarding_complete`,{}),e(`/today`,{replace:!0})}
65async function E(){if(C(``),a===1){if(!s.trim()){C(r(`enter your name`));return}if(!l.trim()){C(r(`enter what you're building`));return}}if(a===2&&!d.trim()){C(r(`enter your one goal`));return}if(a===W_){await T();return}o(a+1)}let D=a===W_;return(0,R.jsx)(`div`,{className:W.page,children:(0,R.jsxs)(`div`,{className:W.card,children:[(0,R.jsx)(`div`,{className:W.logoRow,children:(0,R.jsx)(El,{size:20})}),(0,R.jsx)(`div`,{className:W.progress,children:[1,2,3,4].map(e=>(0,R.jsx)(`div`,{className:a>=e?W.dotFilled:W.dot},e))}),(0,R.jsx)(`div`,{className:W.stepLabel,children:r(`step ${a} of ${W_}`)}),(0,R.jsxs)(`div`,{className:W.stepEnter,children:[a===1&&(0,R.jsx)(X_,{name:s,product:l,setName:c,setProduct:u}),a===2&&(0,R.jsx)(Z_,{goal:d,goalDate:p,setGoal:f,setGoalDate:m}),a===3&&(0,R.jsx)(Y_,{verifyOn:h,setVerifyOn:g,methods:v,setMethods:y}),a===4&&(0,R.jsx)(ev,{tg:w}),a===5&&(0,R.jsx)($_,{})]},a),S&&(0,R.jsx)(`p`,{className:W.error,children:S}),(0,R.jsx)(`div`,{className:W.actions,children:(0,R.jsxs)(`button`,{className:W.nextBtn,onClick:E,disabled:b,children:[r(b?`savingâ¦`:D?`open crew`:`continue`),!b&&(0,R.jsx)(Wm,{name:`arrowRight`,size:14})]})}),a>1&&(0,R.jsx)(`button`,{className:W.backBtn,onClick:()=>o(a-1),children:r(`â back`)})]})})}var J_=[{key:`connectors`,title:`my tools`,sub:`github, stripe, calendar, gmail and 28 more â commits, payments, meetings`},{key:`extension`,title:`my browser`,sub:`the companion extension proves work on pages no API can reach`},{key:`assistant`,title:`my ai assistant`,sub:`claude, chatgpt, cursor and others read and update crew directly`},{key:`manual`,title:`a screenshot, photo or voice note`,sub:`for work nothing digital can prove â judged the same way as a commit`}];function Y_({verifyOn:e,setVerifyOn:t,methods:n,setMethods:r}){let i=z();return(0,R.jsxs)(`div`,{className:W.stepBody,children:[(0,R.jsx)(`h2`,{className:W.stepTitle,children:i(`should crew verify your work?`)}),(0,R.jsx)(`p`,{className:W.stepSub,children:i(`with verification on, finishing a task means crew looks for real evidence in your connected tools. it labels each one verified, or taken on your word when nothing could confirm it.`)}),(0,R.jsxs)(`div`,{className:W.verifyChoice,role:`radiogroup`,"aria-label":i(`should crew verify your work?`),children:[(0,R.jsxs)(`button`,{type:`button`,role:`radio`,"aria-checked":e,className:B(W.verifyOption,e&&W.verifyOptionOn),onClick:()=>t(!0),children:[(0,R.jsx)(`span`,{className:W.verifyOptionTitle,children:i(`yes, verify my work`)}),(0,R.jsx)(`span`,{className:W.verifyOptionSub,children:i(`the default. this is what crew is for.`)})]}),(0,R.jsxs)(`button`,{type:`button`,role:`radio`,"aria-checked":!e,className:B(W.verifyOption,!e&&W.verifyOptionOff),onClick:()=>t(!1),children:[(0,R.jsx)(`span`,{className:W.verifyOptionTitle,children:i(`no, i will mark my own tasks done`)}),(0,R.jsx)(`span`,{className:W.verifyOptionSub,children:i(`one click marks a task done, no evidence needed.`)})]})]}),e&&(0,R.jsxs)(`div`,{className:W.verifyMethods,children:[(0,R.jsx)(`p`,{className:W.verifyMethodsLead,children:i(`how should it check? pick any that fit â you can add more later.`)}),J_.map(e=>{let t=n.includes(e.key);return(0,R.jsxs)(`button`,{type:`button`,role:`checkbox`,"aria-checked":t,className:B(W.methodOption,t&&W.methodOptionOn),onClick:()=>r(t?n.filter(t=>t!==e.key):[...n,e.key]),children:[(0,R.jsx)(`span`,{className:W.methodCheck,"aria-hidden":!0}),(0,R.jsxs)(`span`,{children:[(0,R.jsx)(`span`,{className:W.methodTitle,children:i(e.title)}),(0,R.jsx)(`span`,{className:W.methodSub,children:i(e.sub)})]})]},e.key)}),n.length===0&&(0,R.jsx)(`p`,{className:W.methodHint,children:i(`nothing picked yet â crew will still run, it will just take your word until a source exists.`)})]}),!e&&(0,R.jsxs)(`div`,{className:W.verifyWarnBox,role:`alert`,children:[(0,R.jsx)(`p`,{className:W.verifyWarnLead,children:i(`worth being straight with you: verification is the whole product.`)}),(0,R.jsx)(`p`,{className:W.verifyWarnBody,children:i(`without it, crew is a checklist you tick yourself, which is the thing it exists to replace. every task counts as self-reported, on your streak, your records, and anything you share. nothing will say it was proven, because nothing checked.`)}),(0,R.jsx)(`p`,{className:W.verifyWarnBody,children:i(`it is your account. you can leave it off, and you can change this any time in settings.`)})]})]})}function X_({name:e,product:t,setName:n,setProduct:r}){let i=z(),a=[{badge:i(`morning`),text:i(`you lock in a few real tasks for today`)},{badge:i(`all day`),text:i(`crew collects the evidence â commits, deploys, proof you send`)},{badge:i(`evening`),text:i(`crew reads it back: shipped or dodged, no self-reporting`)}];return(0,R.jsxs)(`div`,{className:W.stepBody,children:[(0,R.jsx)(`h2`,{className:W.stepTitle,children:i(`what are you building?`)}
65),(0,R.jsx)(`p`,{className:W.stepSub,children:i(`two questions, then you're in. crew tracks your execution against what you commit to ship.`)}),(0,R.jsxs)(`div`,{className:W.fields,children:[(0,R.jsxs)(`div`,{className:W.field,children:[(0,R.jsx)(`label`,{className:W.fieldLabel,htmlFor:`ob-name`,children:i(`your name`)}),(0,R.jsx)(`input`,{id:`ob-name`,className:W.input,type:`text`,placeholder:i(`your name`),value:e,onChange:e=>n(e.target.value),autoFocus:!0})]}),(0,R.jsxs)(`div`,{className:W.field,children:[(0,R.jsx)(`label`,{className:W.fieldLabel,htmlFor:`ob-product`,children:i(`product name`)}),(0,R.jsx)(`input`,{id:`ob-product`,className:W.input,type:`text`,placeholder:i(`e.g. Ledgerline, Replyflow, Inkforge`),value:t,onChange:e=>r(e.target.value)})]})]}),(0,R.jsx)(`ul`,{className:W.loopStrip,children:a.map(e=>(0,R.jsxs)(`li`,{className:W.loopStripRow,children:[(0,R.jsx)(`span`,{className:W.loopBadge,children:e.badge}),(0,R.jsx)(`span`,{className:W.featureDesc,children:e.text})]},e.badge))}),(0,R.jsx)(`p`,{className:W.roiLine,children:i(`the evening report writes itself â that's the status update you never write again.`)})]})}function Z_({goal:e,goalDate:t,setGoal:n,setGoalDate:r}){let i=z();return(0,R.jsxs)(`div`,{className:W.stepBody,children:[(0,R.jsx)(`h2`,{className:W.stepTitle,children:i(`your one big goal`)}),(0,R.jsx)(`p`,{className:W.stepSub,children:i(`this is not today's to-do list. it's the single outcome you're driving at over the next 30 to 90 days â one goal, one number, one date.`)}),(0,R.jsxs)(`div`,{className:W.fields,children:[(0,R.jsxs)(`div`,{className:W.field,children:[(0,R.jsx)(`label`,{className:W.fieldLabel,htmlFor:`ob-goal`,children:i(`the one outcome (30â90 days)`)}),(0,R.jsx)(`input`,{id:`ob-goal`,className:W.input,type:`text`,placeholder:i(`e.g. 3 paying customers on the paid plan`),value:e,onChange:e=>n(e.target.value),autoFocus:!0})]}),(0,R.jsxs)(`div`,{className:W.field,children:[(0,R.jsx)(`label`,{className:W.fieldLabel,htmlFor:`ob-date`,children:i(`target date (optional)`)}),(0,R.jsx)(`input`,{id:`ob-date`,className:W.input,type:`date`,value:t,onChange:e=>r(e.target.value)}),(()=>{if(!t)return null;let e=Math.ceil((new Date(t+`T12:00:00`).getTime()-Date.now())/864e5);return!Number.isFinite(e)||e<0?null:(0,R.jsx)(`span`,{className:W.daysChip,children:i(`{n} mornings between you and this`).replace(`{n}`,String(e))},e)})()]})]}),(0,R.jsx)(`p`,{className:W.goalNote,children:i(`your tasks for today come next â you'll lock those in the moment you're inside crew. crew keeps them pointed at this goal.`)})]})}var Q_=`curl -fsSL https://www.meetcrew.app/install/crew-skill.sh | bash`;function $_(){let e=z(),[t,n]=(0,_.useState)(!1);return(0,R.jsxs)(`div`,{className:W.stepBody,children:[(0,R.jsxs)(`h2`,{className:W.stepTitle,children:[e(`install the companion`),(0,R.jsx)(`span`,{className:W.recommendedBadge,children:e(`recommended`)})]}),(0,R.jsx)(`p`,{className:W.stepSub,children:e(`telegram drives your day; the extension proves it. one keystroke captures the page you're on, Crew matches it to your task and checks it off â instead of you writing an update.`)}),(0,R.jsx)(`a`,{className:W.tgBtn,href:`/crew-companion.zip`,download:!0,children:e(`download the extension (.zip)`)}),(0,R.jsxs)(`p`,{className:W.tgHint,children:[e(`two minutes to load it: the`),` `,(0,R.jsx)(Rn,{className:W.extLinkBtn,to:`/extension`,target:`_blank`,rel:`noreferrer`,children:e(`install guide`)}),` `,e(`walks you through every click, and the extension itself tells you when an update is out.`)]}),(0,R.jsx)(`p`,{className:W.roiLine,children:e(`read-only by design: one frame, only when you ask, judged once and never stored. it can never click, type or act as you.`)}),(0,R.jsxs)(`div`,{className:W.assistantBlock,children:[(0,R.jsxs)(`p`,{className:W.tgHint,children:[e(`work in claude, chatgpt or cursor?`),` `,(0,R.jsx)(Rn,{className:W.extLinkBtn,to:`/connect`,target:`_blank`,rel:`noreferrer`,children:e(`connect crew there too`)}),` `,e(`â one link, and you can lock a day without opening crew at all.`)]}),(0,R.jsx)(`p`,{className:W.tgHint,children:e(`on claude code, add the capture skill so it logs what you commit to, without being asked:`)}),(0,R.jsxs)(`button`,{type:`button`,className:W.skillCopy,onClick:()=>{navigator.clipboard.writeText(Q_).then(()=>{n(!0),setTimeout(()=>n(!1),1800)})},children:[(0,R.jsx)(`code`,{children:Q_}),(0,R.jsx)(`span`,{className:W.skillCopyLabel,children:e(t?`copied`:`copy`)})]})]})]})}function ev({tg:e}){let t=z();return(0,R.jsxs)(`div`,{className:W.stepBody,children:[(0,R.jsxs)(`h2`,{className:W.stepTitle,children:[t(`get your morning ping`),(0,R.jsx)(`span`,{className:W.recommendedBadge,children:t(`recommended`)})]}),(0,R.jsx)(`p`,{className:W.stepSub,children:t(`crew pings you in telegram to lock in the day, and again in the evening. reply in plain english to add a task or send proof â no app needed.`)}),e.connected?(0,R.jsxs)(`div`,{className:W.tgDone,children:[(0,R.jsx)(Wm,{name:`check`,size:16}),t(`telegram connected â crew will ping you tomorrow morning.`)]}):(0,R.jsxs)(R.Fragment,{children:[(0,R.jsxs)(`button`,{type:`button`,className:W.tgBtn,onClick:e.start,disabled:e.linking||e.polling,children:[(0,R.jsx)(R_,{size:18}),e.linking?t(`opening telegramâ¦`):e.polling?t(`waiting for telegramâ¦`):t(`connect telegram`)]}),(0,R.jsx)(`p`,{className:W.tgHint,children:t(`one click â it links your account automatically. no phone app required: if telegram isn't installed, it just opens in your browser.`)}),e.polling&&(0,R.jsx)(`p`,{className:W.tgHint,children:t(`finished in telegram? come back to this tab â it updates on its own.`)}),e.error&&(0,R.jsx)(`p`,{className:W.error,children:e.error}),(0,R.jsx)(z_,{state:e})]}),(0,R.jsx)(`p`,{className:W.privacyNote,children:t(`the daily loop IS the product â it lives in telegram. browser-only exists in settings, but the founders who connect are the ones whose days close.`)})]})}
65async function tv(e,t=20){let{data:n,error:r}=await L.from(`notifications`).select(`id, kind, title, body, action_url, read, created_at`).eq(`user_id`,e).order(`created_at`,{ascending:!1}).limit(t);return r?[]:n??[]}async function nv(e){await L.from(`notifications`).update({read:!0}).eq(`id`,e)}async function rv(e){await L.from(`notifications`).update({read:!0}).eq(`user_id`,e).eq(`read`,!1)}var iv={wrap:`_wrap_1sf58_1`,bellBtn:`_bellBtn_1sf58_3`,dot:`_dot_1sf58_18`,panel:`_panel_1sf58_36`,panelHead:`_panelHead_1sf58_52`,panelTitle:`_panelTitle_1sf58_59`,markAll:`_markAll_1sf58_66`,empty:`_empty_1sf58_76`,emptyText:`_emptyText_1sf58_77`,list:`_list_1sf58_79`,item:`_item_1sf58_81`,itemUnread:`_itemUnread_1sf58_97`,itemIcon:`_itemIcon_1sf58_99`,kind_task_done:`_kind_task_done_1sf58_108`,kind_urgent:`_kind_urgent_1sf58_109`,kind_question:`_kind_question_1sf58_110`,kind_nudge:`_kind_nudge_1sf58_111`,itemBody:`_itemBody_1sf58_113`,itemTitle:`_itemTitle_1sf58_114`,itemText:`_itemText_1sf58_115`,itemTime:`_itemTime_1sf58_116`,unreadDot:`_unreadDot_1sf58_118`},av={task_done:`check`,urgent:`flame`,question:`chat`,nudge:`activity`};function ov(e,t){let n=Date.now()-new Date(e).getTime(),r=Math.floor(n/6e4);if(r<1)return t(`just now`);if(r<60)return t(`{n}m ago`).replace(`{n}`,String(r));let i=Math.floor(r/60);return i<24?t(`{n}h ago`).replace(`{n}`,String(i)):t(`{n}d ago`).replace(`{n}`,String(Math.floor(i/24)))}function sv(){let e=z(),{session:t}=ll(),n=t?.user.id,r=pt(),[i,a]=(0,_.useState)(!1),[o,s]=(0,_.useState)([]),c=(0,_.useRef)(null),l=(0,_.useCallback)(async()=>{n&&s(await tv(n))},[n]);(0,_.useEffect)(()=>{if(!n)return;l();let e=setInterval(l,6e4);return()=>clearInterval(e)},[n,l]),(0,_.useEffect)(()=>{if(!i)return;let e=e=>{c.current&&!c.current.contains(e.target)&&a(!1)};return document.addEventListener(`mousedown`,e),()=>document.removeEventListener(`mousedown`,e)},[i]);let u=o.filter(e=>!e.read).length;async function d(e){e.read||(await nv(e.id),s(t=>t.map(t=>t.id===e.id?{...t,read:!0}:t))),e.action_url&&(a(!1),r(e.action_url))}async function f(){n&&(await rv(n),s(e=>e.map(e=>({...e,read:!0}))))}return(0,R.jsxs)(`div`,{className:iv.wrap,ref:c,children:[(0,R.jsxs)(`button`,{className:iv.bellBtn,onClick:()=>{a(e=>!e),i||l()},title:e(`notifications`),"aria-label":u?`${e(`notifications`)} â ${u}`:e(`notifications`),children:[(0,R.jsx)(Wm,{name:`bell`,size:15}),u>0&&(0,R.jsx)(`span`,{className:iv.dot,children:u>9?`9+`:u})]}),i&&(0,R.jsxs)(`div`,{className:iv.panel,role:`menu`,children:[(0,R.jsxs)(`div`,{className:iv.panelHead,children:[(0,R.jsx)(`span`,{className:iv.panelTitle,children:`Crew`}),u>0&&(0,R.jsx)(`button`,{className:iv.markAll,onClick:f,children:e(`mark all read`)})]}),o.length===0?(0,R.jsx)(`div`,{className:iv.empty,children:(0,R.jsx)(`span`,{className:iv.emptyText,children:e(`nothing yet. Crew will reach out when something needs you.`)})}):(0,R.jsx)(`div`,{className:iv.list,children:o.map(t=>(0,R.jsxs)(`button`,{className:B(iv.item,!t.read&&iv.itemUnread),onClick:()=>d(t),children:[(0,R.jsx)(`span`,{className:B(iv.itemIcon,iv[`kind_${t.kind}`]),children:(0,R.jsx)(Wm,{name:av[t.kind]??`bell`,size:13})}),(0,R.jsxs)(`span`,{className:iv.itemBody,children:[(0,R.jsx)(`span`,{className:iv.itemTitle,children:t.title}),t.body&&(0,R.jsx)(`span`,{className:iv.itemText,children:t.body}),(0,R.jsx)(`span`,{className:iv.itemTime,children:ov(t.created_at,e)})]}),!t.read&&(0,R.jsx)(`span`,{className:iv.unreadDot})]},t.id))})]})]})}async function cv(e){return L.from(`feedback`).insert({user_id:e.userId,type:e.type,text:e.text,subcategory:e.subcategory??null,severity:e.severity??null,attachment_url:e.attachmentUrl??null,device_info:e.deviceInfo??null}).select().single()}async function lv(e){return L.from(`feedback`).select(`*`).eq(`user_id`,e).order(`created_at`,{ascending:!1}).limit(20)}async function uv(e){return L.from(`feedback`).delete().eq(`id`,e)}var dv={root:`_root_13l9b_1`,trigger:`_trigger_13l9b_8`,scrim:`_scrim_13l9b_17`,panel:`_panel_13l9b_19`,panelWide:`_panelWide_13l9b_19`,head:`_head_13l9b_31`,title:`_title_13l9b_32`,close:`_close_13l9b_33`,pathNote:`_pathNote_13l9b_39`,error:`_error_13l9b_45`,menu:`_menu_13l9b_51`,bigOpt:`_bigOpt_13l9b_52`,optLabel:`_optLabel_13l9b_63`,optSub:`_optSub_13l9b_64`,hiddenFile:`_hiddenFile_13l9b_65`,tools:`_tools_13l9b_68`,toolGroup:`_toolGroup_13l9b_72`,tool:`_tool_13l9b_68`,toolOn:`_toolOn_13l9b_74`,swatch:`_swatch_13l9b_85`,swatchOn:`_swatchOn_13l9b_85`,canvasWrap:`_canvasWrap_13l9b_91`,canvas:`_canvas_13l9b_91`,compose:`_compose_13l9b_100`,thumbRow:`_thumbRow_13l9b_102`,thumb:`_thumb_13l9b_102`,thumbNote:`_thumbNote_13l9b_110`,fieldLabel:`_fieldLabel_13l9b_112`,typeGrid:`_typeGrid_13l9b_114`,typeBtn:`_typeBtn_13l9b_115`,typeOn:`_typeOn_13l9b_115`,sevRow:`_sevRow_13l9b_124`,sevBtn:`_sevBtn_13l9b_125`,sevOn:`_sevOn_13l9b_125`,textarea:`_textarea_13l9b_132`,actions:`_actions_13l9b_141`,ghost:`_ghost_13l9b_142`,primary:`_primary_13l9b_142`,state:`_state_13l9b_153`,triggerLabel:`_triggerLabel_13l9b_171`},fv=[`#ef4444`,`#f59e0b`,`#22c55e`,`#2d5bff`],pv=[{key:`bug`,label:`something is broken`},{key:`feature`,label:`i want something`},{key:`connector`,label:`a connector`},{key:`verification`,label:`a verdict was wrong`},{key:`performance`,label:`slow or janky`},{key:`notifications`,label:`notifications`},{key:`account`,label:`account or billing`},{key:`other`,label:`something else`}],mv=[`critical`,`high`,`medium`,`low`];function hv(){let e=z(),{session:t}=ll(),n=ut(),r=t?.user?.id??null,[i,a]=(0,_.useState)(!1),[o,s]=(0,_.useState)(`menu`),[c,l]=(0,_.useState)(``),[u,d]=(0,_.useState)(``),[f,p]=(0,_.useState)(`arrow`),[m,h]=(0,_.useState)(fv[0]),[g,v]=(0,_.useState)([]),[y,b]=(0,_.useState)(null),[x,S]=(0,_.useState)(null),[C,w]=(0,_.useState)(``),[T,E]=(0,_.useState)(`medium`),[D,O]=(0,_.useState)(``),k=(0,_.useRef)(null),A=(0,_.useRef)(null),j=(0,_.useRef)(null),ee=(0,_.useCallback)(()=>{s(`menu`),v([]),b(null),S(null),w(``),E(`medium`),O(``),d(``),l(``)},[]);function te(){let e=k.current;e&&S(e.toDataURL(`image/png`)),s(`compose`)}let ne=(0,_.useCallback)(()=>{a(!1),ee()},[ee]);(0,_.useEffect)(()=>
65{if(!i)return;let e=e=>{e.key===`Escape`&&ne()};return window.addEventListener(`keydown`,e),()=>window.removeEventListener(`keydown`,e)},[i,ne]);function re(t){let n=new Image;n.onload=()=>{b(n),v([]),s(`annotate`),l(``)},n.onerror=()=>{d(e(`could not read that image`)),l(``)},n.src=t}(0,_.useEffect)(()=>{if(!i||o!==`menu`&&o!==`compose`)return;let e=e=>{let t=Array.from(e.clipboardData?.items??[]).find(e=>e.type.startsWith(`image/`));if(!t)return;let n=t.getAsFile();if(!n)return;e.preventDefault();let r=new FileReader;r.onload=()=>re(String(r.result)),r.readAsDataURL(n)};return window.addEventListener(`paste`,e),()=>window.removeEventListener(`paste`,e)},[i,o]);function M(e){return new Promise((t,n)=>{let r=new Image;r.onload=()=>t(r),r.onerror=()=>n(Error(`the rendered page image would not load`)),r.src=e})}async function N(e){let t=getComputedStyle(document.body).backgroundColor||`#ffffff`,n=window.innerWidth,r=window.innerHeight,i=await M(await Fp(document.body,{backgroundColor:t,width:n,height:r,style:{transform:`translate(${-window.scrollX}px, ${-window.scrollY}px)`,transformOrigin:`top left`},skipFonts:e.skipFonts,filter:t=>!(t instanceof HTMLElement&&t.dataset.crewFeedback===`true`||e.dropImages&&/^(IMG|PICTURE|VIDEO|CANVAS|IFRAME)$/.test(t.nodeName))})),a=document.createElement(`canvas`);a.width=n,a.height=r;let o=a.getContext(`2d`);if(!o)throw Error(`no 2d context`);return o.fillStyle=t,o.fillRect(0,0,n,r),o.drawImage(i,0,0,n,r),a.toDataURL(`image/png`)}async function ie(){l(e(`capturingâ¦`)),d(``),s(`menu`),document.body.dataset.crewCapturing=`true`,await new Promise(e=>requestAnimationFrame(()=>requestAnimationFrame(e)));let t=[{opts:{skipFonts:!1,dropImages:!1},note:e(`capturingâ¦`)},{opts:{skipFonts:!0,dropImages:!1},note:e(`still workingâ¦`)},{opts:{skipFonts:!0,dropImages:!0},note:e(`one more tryâ¦`)}],n=[];try{for(let e of t){l(e.note);try{re(await Promise.race([N(e.opts),new Promise((e,t)=>setTimeout(()=>t(Error(`timeout`)),1e4))]));return}catch(t){let r=t instanceof Error?t:Error(String(t));n.push(`${r.name}: ${r.message}`),console.error(`[crew feedback] capture attempt failed`,e.opts,r)}}d(`${e(`could not capture this page`)} (${n[n.length-1]?.slice(0,110)}) â ${e(`press âV to paste a screenshot, or attach one`)}`),l(``)}finally{delete document.body.dataset.crewCapturing}}function ae(e){let t=e.target.files?.[0];if(!t)return;let n=new FileReader;n.onload=()=>re(String(n.result)),n.readAsDataURL(t),A.current&&(A.current.value=``)}let P=(0,_.useCallback)(()=>{let e=k.current;if(!e||!y)return;let t=e.getContext(`2d`);if(!t)return;t.clearRect(0,0,e.width,e.height),t.drawImage(y,0,0,e.width,e.height);let n=Math.max(3,Math.round(e.width/320)),r=j.current?[...g,j.current]:g;for(let e of r)if(t.strokeStyle=e.color,t.fillStyle=e.color,t.lineWidth=n,t.lineCap=`round`,t.lineJoin=`round`,e.tool===`pen`)t.beginPath(),e.pts.forEac
65h((e,n)=>n?t.lineTo(e.x,e.y):t.moveTo(e.x,e.y)),t.stroke();else if(e.tool===`rect`)t.strokeRect(e.x1,e.y1,e.x2-e.x1,e.y2-e.y1);else{let{x1:r,y1:i,x2:a,y2:o}=e,s=Math.atan2(o-i,a-r),c=Math.max(14,n*4);t.beginPath(),t.moveTo(r,i),t.lineTo(a,o),t.stroke(),t.beginPath(),t.moveTo(a,o),t.lineTo(a-c*Math.cos(s-Math.PI/6),o-c*Math.sin(s-Math.PI/6)),t.lineTo(a-c*Math.cos(s+Math.PI/6),o-c*Math.sin(s+Math.PI/6)),t.closePath(),t.fill()}},[y,g]);(0,_.useEffect)(()=>{let e=k.current;!e||!y||(e.width=y.naturalWidth,e.height=y.naturalHeight,P())},[y,P]),(0,_.useEffect)(()=>{P()},[g,P]);function oe(e){let t=e.currentTarget,n=t.getBoundingClientRect();return{x:(e.clientX-n.left)*(t.width/n.width),y:(e.clientY-n.top)*(t.height/n.height)}}function se(e){e.currentTarget.setPointerCapture(e.pointerId);let{x:t,y:n}=oe(e);j.current=f===`pen`?{tool:`pen`,color:m,pts:[{x:t,y:n}]}:{tool:f,color:m,x1:t,y1:n,x2:t,y2:n},P()}function ce(e){if(!j.current)return;let{x:t,y:n}=oe(e);j.current.tool===`pen`?j.current.pts.push({x:t,y:n}):(j.current.x2=t,j.current.y2=n),P()}function le(){let e=j.current;if(j.current=null,e){if(e.tool===`pen`?e.pts.length<2:Math.abs(e.x2-e.x1)<4&&Math.abs(e.y2-e.y1)<4){P();return}v(t=>[...t,e])}}async function ue(){if(!(!r||!C||!D.trim())){s(`sending`),d(``);try{let t;if(x){let e=await(await fetch(x)).blob();if(e){let n=`${r}/${Date.now()}.png`,{error:i}=await L.storage.from(`feedback-uploads`).upload(n,e,{contentType:`image/png`});i||(t=n)}}let{error:i}=await cv({userId:r,type:C,text:D.trim(),severity:C===`bug`?T:void 0,attachmentUrl:t,deviceInfo:{path:n.pathname+n.search,viewport:`${window.innerWidth}x${window.innerHeight}`,screen:`${window.screen.width}x${window.screen.height}`,dpr:window.devicePixelRatio,userAgent:navigator.userAgent,language:navigator.language,annotated:g.length>0,capturedAt:new Date().toISOString()}});if(i){d(e(`could not send â try again`)),s(`compose`);return}s(`done`),setTimeout(ne,1600)}catch{d(e(`could not send â try again`)),s(`compose`)}}}return r?(0,R.jsxs)(`div`,{"data-crew-feedback":`true`,className:dv.root,children:[(0,R.jsxs)(`button`,{className:dv.trigger,onClick:()=>i?ne():a(!0),title:e(`Share feedback on this page`),"aria-label":e(`Share feedback on this page`),"aria-expanded":i,children:[(0,R.jsx)(Wm,{name:`chat`,size:16}),(0,R.jsx)(`span`,{className:dv.triggerLabel,children:e(`feedback`)})]}),i&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`div`,{className:dv.scrim,onClick:ne}),(0,R.jsxs)(`div`,{className:o===`annotate`?dv.panelWide:dv.panel,role:`dialog`,"aria-label":e(`Send feedback`),children:[(0,R.jsxs)(`div`,{className:dv.head,children:[(0,R.jsx)(`span`,{className:dv.title,children:e(o===`annotate`?`circle what you mean`:o===`compose`?`tell us about it`:`feedback`)}),(0,R.jsx)(`button`,{className:dv.close,onClick:ne,"aria-label":e(`close`),children:`â`})]}),o!==`done`&&(0,R.jsxs)(`p`,{className:dv.pathNote,children:[(0,R.jsx)(Wm,{name:`target`,size:12}),` `,n.pathname]}),u&&(0,R.jsx)(`p`,{className:dv.error,children:u}),o===`menu`&&(0,R.jsxs)(`div`,{className:dv.menu,children:[(0,R.jsxs)(`button`,{className:dv.bigOpt,onClick:ie,disabled:!!c,children:[(0,R.jsx)(Wm,{name:`target`,size:18}),(0,R.jsx)(`span`,{className:dv.optLabel,children:c||e(`capture what i see`)}),(0,R.jsx)(`span`,{className:dv.optSub,children:e(`this screen as it looks now â then point at anything`)})]}),(0,R.jsxs)(`button`,{className:dv.bigOpt,onClick:()=>A.current?.click(),children:[(0,R.jsx)(Wm,{name:`layers`,size:18}),(0,R.jsx)(`span`,{className:dv.optLabel,children:e(`attach a screenshot`)}),(0,R.jsx)(`span`,{className:dv.optSub,children:e(`or just press âV to paste one`)})]}),(0,R.jsxs)(`button`,{className:dv.bigOpt,onClick:()=>s(`compose`),children:[(0,R.jsx)(Wm,{name:`edit`,size:18}),(0,R.jsx)(`span`,{className:dv.optLabel,children:e(`just tell us`)}),(0,R.jsx)(`span`,{className:dv.optSub,children:e(`an idea, a nitpick, anything`)})]}),(0,R.jsx)(`input`,{ref:A,type:`file`,accept:`image/*`,className:dv.hiddenFile,onChange:ae})]}),o===`annotate`&&y&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsxs)(`div`,{className:dv.tools,children:[(0,R.jsx)(`div`,{className:dv.toolGroup,children:[`arrow`,`pen`,`rect`].map(e=>(0,R.jsx)(`button`,{className:f===e?dv.toolOn:dv.tool,onClick:()=>p(e),title:e,children:(0,R.jsx)(Wm,{name:e===`arrow`?`arrowRight`:e===`pen`?`edit`:`grid`,size:15})},e))}),(0,R.jsx)(`div`,{className:dv.toolGroup,children:fv.map(e=>(0,R.jsx)(`button`,{className:m===e?dv.swatchOn:dv.swatch,style:{background:e},onClick:()=>h(e),"aria-label":`colour ${e}`},e))}),(0,R.jsxs)(`div`,{className:dv.toolGroup,children:[(0,R.jsx)(`button`,{className:dv.tool,onClick:()=>v(e=>e.slice(0,-1)),disabled:g.length===0,title:e(`undo`),children:(0,R.jsx)(Wm,{name:`refresh`,size:15})}),(0,R.jsx)(`button`,{className:dv.tool,onClick:()=>v([]),disabled:g.length===0,title:e(`Clear marks`),children:(0,R.jsx)(Wm,{name:`x`,size:15})})]})]}),(0,R.jsx)(`div`,{className:dv.canvasWrap,children:(0,R.jsx)(`canvas`,{ref:k,className:dv.canvas,onPointerDown:se,onPointerMove:ce,onPointerUp:le,onPointerCancel:le})}),(0,R.jsxs)(`div`,{className:dv.actions,children:[(0,R.jsx)(`button`,{className:dv.ghost,onClick:()=>{b(null),v([]),S(null),s(`menu`)},children:e(`back`)}),(0,R.jsx)(`button`,{className:dv.primary,onClick:te,children:e(`next â`)})]})]}),o===`compose`&&(0,R.jsxs)(`div`,{className:dv.compose,children:[x&&(0,R.jsxs)(`button`,{className:dv.thumbRow,onClick:()=>s(`annotate`),children:[(0,R.jsx)(`img`,{src:x,alt:``,className:dv.thumb}),(0,R.jsx)(`span`,{className:dv.thumbNote,children:g.length>0?e(`{n} marks â edit`).replace(`{n}`,String(g.length)):e(`screenshot attached â add marks`)})]}),(0,R.jsx)(`span`,{className:dv.fieldLabel,children:e(`what's this about?`)}),(0,R.jsx)(`div`,{className:dv.typeGrid,children:pv.map(t=>(0,R.jsx)(`button`,{className:C===t.key?dv.typeOn:dv.typeBtn,onClick:()=>w(t.key),children:e(t.label)},t.key))}),C===`bug`&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`span`,{className:dv.fieldLabel,children:e(`how bad is it?`)}),(0,R.jsx)(`div`,{className:dv.sevRow,children:mv.map(t=>(0,R.jsx)(`button`,{className:T===t?dv.sevOn:dv.sevBtn,onClick:()=>E(t),children:e(t)},t))})]}),(0,R.jsx)(`span`,{className:dv.fieldLabel,children:e(`what's on your mind?`)}),(0,R.jsx)(`textarea`,{className:dv.textarea,value:D,onChange:e=>O(e.target.value),placeholder:e(`whatever's on your mind â an idea, something confusing, something broken`),rows:4,autoF
65ocus:!0}),(0,R.jsxs)(`div`,{className:dv.actions,children:[(0,R.jsx)(`button`,{className:dv.ghost,onClick:()=>s(x?`annotate`:`menu`),children:e(`back`)}),(0,R.jsx)(`button`,{className:dv.primary,onClick:ue,disabled:!C||!D.trim(),children:e(`send`)})]})]}),o===`sending`&&(0,R.jsx)(`p`,{className:dv.state,children:e(`sendingâ¦`)}),o===`done`&&(0,R.jsxs)(`p`,{className:dv.state,children:[(0,R.jsx)(Wm,{name:`check`,size:16}),` `,e(`got it â thank you.`)]})]})]})]}):null}var gv={overlay:`_overlay_1o72s_1`,box:`_box_1o72s_11`,title:`_title_1o72s_24`,body:`_body_1o72s_32`,instruction:`_instruction_1o72s_39`,input:`_input_1o72s_46`,actions:`_actions_1o72s_57`,cancel:`_cancel_1o72s_64`,confirm:`_confirm_1o72s_75`};function _v({title:e,body:t,confirmText:n,onConfirm:r,onCancel:i,busy:a}){let o=z(),[s,c]=(0,_.useState)(``),l=s.trim()===n;return(0,R.jsx)(`div`,{className:gv.overlay,onClick:i,children:(0,R.jsxs)(`div`,{className:gv.box,onClick:e=>e.stopPropagation(),children:[(0,R.jsx)(`h3`,{className:gv.title,children:e}),(0,R.jsx)(`p`,{className:gv.body,children:t}),(0,R.jsx)(`p`,{className:gv.instruction,children:o(`type "{name}" to confirm`).replace(`{name}`,n)}),(0,R.jsx)(`input`,{className:gv.input,value:s,onChange:e=>c(e.target.value),placeholder:n,autoFocus:!0}),(0,R.jsxs)(`div`,{className:gv.actions,children:[(0,R.jsx)(`button`,{type:`button`,className:gv.cancel,onClick:i,children:o(`cancel`)}),(0,R.jsx)(`button`,{type:`button`,className:gv.confirm,disabled:!l||a,onClick:r,children:o(a?`deletingâ¦`:`delete`)})]})]})})}var G={shell:`_shell_dh6lr_3`,sidebar:`_sidebar_dh6lr_12`,wordmarkRow:`_wordmarkRow_dh6lr_25`,sideSearchBtn:`_sideSearchBtn_dh6lr_33`,wsWrap:`_wsWrap_dh6lr_46`,wsBtn:`_wsBtn_dh6lr_52`,wsDot:`_wsDot_dh6lr_67`,wsDotActive:`_wsDotActive_dh6lr_74`,wsName:`_wsName_dh6lr_76`,wsChev:`_wsChev_dh6lr_86`,wsChevOpen:`_wsChevOpen_dh6lr_91`,wsDropdown:`_wsDropdown_dh6lr_93`,wsOptionRow:`_wsOptionRow_dh6lr_106`,wsOption:`_wsOption_dh6lr_106`,wsOptionActive:`_wsOptionActive_dh6lr_131`,wsDeleteBtn:`_wsDeleteBtn_dh6lr_134`,wsDivider:`_wsDivider_dh6lr_150`,wsAddTrigger:`_wsAddTrigger_dh6lr_152`,wsAddForm:`_wsAddForm_dh6lr_168`,wsAddInput:`_wsAddInput_dh6lr_174`,wsAddBtn:`_wsAddBtn_dh6lr_187`,nav:`_nav_dh6lr_202`,navScroll:`_navScroll_dh6lr_216`,n
65avGroup:`_navGroup_dh6lr_218`,navGroupLabel:`_navGroupLabel_dh6lr_221`,navItem:`_navItem_dh6lr_232`,navIcon:`_navIcon_dh6lr_252`,navLabel:`_navLabel_dh6lr_262`,navItemActive:`_navItemActive_dh6lr_264`,navCount:`_navCount_dh6lr_271`,navBadge:`_navBadge_dh6lr_279`,accountNav:`_accountNav_dh6lr_213`,sideFooter:`_sideFooter_dh6lr_306`,profile:`_profile_dh6lr_313`,profileMenu:`_profileMenu_dh6lr_330`,menuTop:`_menuTop_dh6lr_343`,menuAvatar:`_menuAvatar_dh6lr_350`,menuIdentity:`_menuIdentity_dh6lr_370`,menuName:`_menuName_dh6lr_377`,menuEmail:`_menuEmail_dh6lr_386`,menuDivider:`_menuDivider_dh6lr_395`,menuPlanRow:`_menuPlanRow_dh6lr_400`,menuPlanBadge:`_menuPlanBadge_dh6lr_407`,menuPlanBadgePaid:`_menuPlanBadgePaid_dh6lr_424`,menuPlanNote:`_menuPlanNote_dh6lr_430`,menuUpgradeLink:`_menuUpgradeLink_dh6lr_436`,menuAction:`_menuAction_dh6lr_447`,menuActionSignOut:`_menuActionSignOut_dh6lr_465`,profileChev:`_profileChev_dh6lr_468`,profileChevOpen:`_profileChevOpen_dh6lr_476`,avatar:`_avatar_dh6lr_478`,profileInfo:`_profileInfo_dh6lr_499`,profileName:`_profileName_dh6lr_507`,profileSub:`_profileSub_dh6lr_517`,main:`_main_dh6lr_525`,topbar:`_topbar_dh6lr_532`,topbarLeft:`_topbarLeft_dh6lr_551`,topbarTitle:`_topbarTitle_dh6lr_559`,topbarDate:`_topbarDate_dh6lr_569`,topbarRight:`_topbarRight_dh6lr_576`,searchTrigger:`_searchTrigger_dh6lr_583`,searchIcon:`_searchIcon_dh6lr_601`,searchPlaceholder:`_searchPlaceholder_dh6lr_602`,searchKbd:`_searchKbd_dh6lr_604`,lockBtn:`_lockBtn_dh6lr_616`,lockGroup:`_lockGroup_dh6lr_636`,coachmark:`_coachmark_dh6lr_647`,coachmarkIn:`_coachmarkIn_dh6lr_1`,coachmarkClose:`_coachmarkClose_dh6lr_672`,coachmarkText:`_coachmarkText_dh6lr_685`,coachmarkSub:`_coachmarkSub_dh6lr_692`,lockBtnTomorrow:`_lockBtnTomorrow_dh6lr_703`,iconBtn:`_iconBtn_dh6lr_724`,content:`_content_dh6lr_737`,founderBanner:`_founderBanner_dh6lr_743`,founderBannerLocked:`_founderBannerLocked_dh6lr_758`,founderBannerDot:`_founderBannerDot_dh6lr_763`,founderBannerLink:`_founderBannerLink_dh6lr_772`,loopNag:`_loopNag_dh6lr_785`,loopNagText:`_loopNagText_dh6lr_795`,loopNagLink:`_loopNagLink_dh6lr_796`,loopNagLater:`_loopNagLater_dh6lr_797`,desktopOnly:`_desktopOnly_dh6lr_848`};function vv(e){return[{section:e(`Workspace`),items:[{label:e(`Dashboard`),to:`/app/dashboard`,icon:`activity`},{label:e(`Goals`),to:`/app/goals`,icon:`target`,count:`3`}]},{section:e(`Accountability`),items:[{label:e(`Review`),to:`/app/review`,icon:`layers`,badge:`due`},{label:e(`Streak`),to:`/app/streak`,icon:`flame`}]},{section:e(`Co-founder`),items:[{label:e(`Chat`),to:`/app/chat`,icon:`chat`,count:`2`},{label:e(`Pod`),to:`/app/crew`,icon:`users`},{label:e(`Calendar`),to:`/app/calendar`,icon:`calendar`}]}]}function yv(e){return{"/app/dashboard":e(`Dashboard`),"/app/goals":e(`Goals`),"/app/review":e(`Review`),"/app/streak":e(`Streak`),"/app/chat":e(`Chat`),"/app/crew":e(`Pod`),"/app/calendar":e(`Calendar`),"/app/feedback":e(`Feedback`),"/app/settings":e(`Settings`)}}function bv(e){let t=new Date,n=e===`fr`?`fr-FR`:`en-US`;return`${t.toLocaleDateString(n,{weekday:`short`,month:`short`,day:`numeric`}).toUpperCase().replace(`,`,``)} · ${t.toLocaleTimeString(n,{hour:`numeric`,minute:`2-digit`})}`}function xv(e){let t=e.trim().split(/\s+/).filter(Boolean);return t.length===0?`?`:t.length===1?t[0][0].toUpperCase():(t[0][0]+t[t.length-1][0]).toUpperCase()}function Sv(){let e=ut(),t=pt(),{profile:n,session:r}=ll(),i=Ug(),a=z(),{lang:o}=ml(),s=n?.name??`You`,c=n?.product_name??`your product`,l=n?.plan??`trial`,u=r?.user.email??``;Bg(n?.trial_ends_at??null);let d=xv(s),f=vv(a),p=yv(a)[e.pathname]??a(`Dashboard`),{workspaces:m,active:h,setActive:g,create:v,remove:y}=wl(),[b,x]=(0,_.useState)(()=>sessionStorage.getItem(`crew.justOnboarded`)===`1`),[S,C]=(0,_.useState)(null);(0,_.useEffect)(()=>{let e=Number(localStorage.getItem(`crew.loopNagUntil`)||0);Date.now()<e||(async()=>{let{data:{user:e}}=await L.auth.getUser();if(!e)return;let[{data:t},{data:n}]=await Promise.all([L.from(`profiles`).select(`telegram_chat_id`).eq(`id`,e.id).maybeSingle(),L.from(`extension_tokens`).select(`last_seen_at`).eq(`user_id`,e.id).maybeSingle()]);t?.telegram_chat_id?n?.last_seen_at||C(`extension`):C(`telegram`)})().catch(()=>{})},[]);function w(){localStorage.setItem(`crew.loopNagUntil`,String(Date.now()+3*864e5)),C(null)}function T(){x(!1),sessionStorage.removeItem(`crew.justOnboarded`)}let[E,D]=(0,_.useState)(!1),[O,k]=(0,_.useState)(!1),[A,j]=(0,_.useState)(!1),[ee,te]=(0,_.useState)(!1),[ne,re]=(0,_.useState)(``),[M,N]=(0,_.useState)(null),[ie,ae]=(0,_.useState)(!1),P=(0,_.useRef)(null),oe=(0,_.useRef)(null);(0,_.useEffect)(()=>{r&&su(e.pathname)},[e.pathname,r]),(0,_.useEffect)(()=>
65{if(!O)return;let e=e=>{P.current&&!P.current.contains(e.target)&&k(!1)};return document.addEventListener(`mousedown`,e),()=>document.removeEventListener(`mousedown`,e)},[O]),(0,_.useEffect)(()=>{if(!A)return;let e=e=>{oe.current&&!oe.current.contains(e.target)&&(j(!1),te(!1))};return document.addEventListener(`mousedown`,e),()=>document.removeEventListener(`mousedown`,e)},[A]);async function se(e){e.preventDefault(),ne.trim()&&(await v(ne.trim()),re(``),te(!1),j(!1))}function ce(e,t){N({id:e,name:t})}async function le(){M&&(ae(!0),await y(M.id),ae(!1),N(null))}async function ue(){k(!1),await oh(),t(`/`,{replace:!0})}return(0,R.jsxs)(`div`,{className:G.shell,children:[(0,R.jsxs)(`aside`,{className:G.sidebar,children:[(0,R.jsx)(`div`,{className:G.wordmarkRow,children:(0,R.jsx)(Rn,{to:`/app/dashboard`,"aria-label":a(`go to dashboard`),title:a(`go to dashboard`),style:{display:`inline-flex`,alignItems:`center`,cursor:`pointer`,textDecoration:`none`,color:`inherit`,opacity:E?.72:1,transition:`opacity 0.12s ease`},onMouseEnter:()=>D(!0),onMouseLeave:()=>D(!1),onFocus:()=>D(!0),onBlur:()=>D(!1),children:(0,R.jsx)(El,{size:16})})}),(0,R.jsxs)(`div`,{className:G.wsWrap,ref:oe,children:[(0,R.jsxs)(`button`,{className:G.wsBtn,onClick:()=>{j(e=>!e),te(!1)},title:a(`switch company`),children:[(0,R.jsx)(`span`,{className:B(G.wsDot,h&&G.wsDotActive)}),(0,R.jsx)(`span`,{className:G.wsName,children:h?.name??a(`all companies`)}),(0,R.jsx)(Wm,{name:`chevronDown`,size:11,className:B(G.wsChev,A&&G.wsChevOpen)})]}),A&&(0,R.jsxs)(`div`,{className:G.wsDropdown,children:[(0,R.jsx)(`button`,{className:B(G.wsOption,!h&&G.wsOptionActive),onClick:()=>{g(null),j(!1)},children:a(`all companies`)}),m.map(e=>(0,R.jsxs)(`div`,{className:G.wsOptionRow,children:[(0,R.jsx)(`button`,{className:B(G.wsOption,h?.id===e.id&&G.wsOptionActive),onClick:()=>{g(e.id),j(!1)},children:e.name}),(0,R.jsx)(`button`,{className:G.wsDeleteBtn,onClick:t=>{t.stopPropagation(),ce(e.id,e.name)},"aria-label":`${a(`delete`)} ${e.name}`,title:a(`delete company`),children:a(`delete`)})]},e.id)),(0,R.jsx)(`div`,{className:G.wsDivider}),ee?(0,R.jsxs)(`form`,{className:G.wsAddForm,onSubmit:se,children:[(0,R.jsx)(`input`,{autoFocus:!0,className:G.wsAddInput,placeholder:a(`Company nameâ¦`),value:ne,onChange:e=>re(e.target.value),onKeyDown:e=>e.key===`Escape`&&te(!1)}),(0,R.jsx)(`button`,{type:`submit`,className:G.wsAddBtn,disabled:!ne.trim(),children:a(`add`)})]}):(0,R.jsx)(`button`,{className:G.wsAddTrigger,onClick:()=>te(!0),children:a(`+ add company`)})]})]}),(0,R.jsxs)(`div`,{className:G.navScroll,children:[(0,R.jsx)(`nav`,{className:G.nav,"aria-label":a(`command center navigation`),children:f.map(e=>(0,R.jsxs)(`div`,{className:G.navGroup,children:[(0,R.jsx)(`span`,{className:G.navGroupLabel,children:e.section}),e.items.map(e=>(0,R.jsxs)(zn,{to:e.to,className:({isActive:e})=>B(G.navItem,e&&G.navItemActive),children:[(0,R.jsx)(Wm,{name:e.icon,size:17,className:G.navIcon}),(0,R.jsx)(`span`,{className:G.navLabel,children:e.label}),e.count&&(0,R.jsx)(`span`,{className:G.navCount,children:e.count}),e.badge&&(0,R.jsx)(`span`,{className:G.navBadge,children:e.badge})]},e.to))]},e.section))}),(0,R.jsx)(`nav`,{className:G.accountNav,"aria-label":a(`account navigation`),children:[{label:a(`Feedback`),to:`/app/feedback`,icon:`bug`},{label:a(`Settings`),to:`/app/settings`,icon:`settings`}].map(e=>(0,R.jsxs)(zn,{to:e.to,className:({isActive:e})=>B(G.navItem,e&&G.navItemActive),children:[(0,R.jsx)(Wm,{name:e.icon,size:17,className:G.navIcon}),(0,R.jsx)(`span`,{className:G.navLabel,children:e.label})]},e.to))})]}),(0,R.jsxs)(`div`,{className:G.sideFooter,ref:P,children:[O&&(0,R.jsxs)(`div`,{className:G.profileMenu,role:`menu`,children:[(0,R.jsxs)(`div`,{className:G.menuTop,children:[(0,R.jsx)(`div`,{className:G.menuAvatar,children:d}),(0,R.jsxs)(`div`,{className:G.menuIdentity,children:[(0,R.jsx)(`span`,{className:G.menuName,children:s}),(0,R.jsx)(`span`,{className:G.menuEmail,children:u})]})]}),(0,R.jsx)(`div`,{className:G.menuDivider}),(0,R.jsxs)(`div`,{className:G.menuPlanRow,children:[(0,R.jsx)(`span`,{className:B(G.menuPlanBadge,l!==`trial`&&G.menuPlanBadgePaid),children:l}),l===`trial`&&(0,R.jsx)(`span`,{className:G.menuPlanNote,children:a(`free until launch`)}
65),l===`trial`&&(0,R.jsx)(Rn,{to:`/app/settings`,className:G.menuUpgradeLink,onClick:()=>k(!1),children:a(`upgrade â`)})]}),(0,R.jsx)(`div`,{className:G.menuDivider}),(0,R.jsxs)(Rn,{to:`/app/settings`,className:G.menuAction,onClick:()=>k(!1),role:`menuitem`,children:[(0,R.jsx)(Wm,{name:`settings`,size:13}),a(`settings`)]}),(0,R.jsxs)(`button`,{className:B(G.menuAction,G.menuActionSignOut),onClick:ue,role:`menuitem`,children:[(0,R.jsx)(Wm,{name:`arrowRight`,size:13}),a(`sign out`)]})]}),(0,R.jsxs)(`button`,{className:G.profile,onClick:()=>k(e=>!e),"aria-expanded":O,"aria-haspopup":`menu`,children:[(0,R.jsx)(`div`,{className:G.avatar,children:d}),(0,R.jsxs)(`div`,{className:G.profileInfo,children:[(0,R.jsx)(`span`,{className:G.profileName,children:s}),(0,R.jsxs)(`span`,{className:G.profileSub,children:[c,` · `,l]})]}),(0,R.jsx)(Wm,{name:`chevronDown`,size:15,className:B(G.profileChev,O&&G.profileChevOpen)})]})]})]}),(0,R.jsxs)(`div`,{className:G.main,children:[(0,R.jsxs)(`header`,{className:G.topbar,children:[(0,R.jsxs)(`div`,{className:G.topbarLeft,children:[(0,R.jsx)(`h1`,{className:G.topbarTitle,children:p}),(0,R.jsx)(`span`,{className:G.topbarDate,children:bv(o)})]}),(0,R.jsxs)(`div`,{className:G.topbarRight,children:[(0,R.jsxs)(`div`,{className:G.lockGroup,children:[(0,R.jsxs)(`button`,{className:G.lockBtn,onClick:()=>{T(),t(`/today`)},children:[(0,R.jsx)(Wm,{name:`lock`,size:13}),a(`Lock today`)]}),(0,R.jsx)(`button`,{className:G.lockBtnTomorrow,onClick:()=>t(`/today?mode=tomorrow`),title:a(`prep tomorrow's 3 tasks`),children:a(`tomorrow â`)}),b&&(0,R.jsxs)(`div`,{className:G.coachmark,role:`tooltip`,children:[(0,R.jsx)(`button`,{className:G.coachmarkClose,onClick:T,"aria-label":a(`dismiss`),children:`Ã`}),(0,R.jsx)(`p`,{className:G.coachmarkText,children:a(`start here â lock your 3 tasks for today.`)}),(0,R.jsx)(`p`,{className:G.coachmarkSub,children:a(`this is the whole loop: everything else in Crew builds from what you lock in.`)})]})]}),(0,R.jsx)(`span`,{className:G.desktopOnly,children:(0,R.jsx)(hv,{})}),(0,R.jsx)(sv,{})]})]}),(0,R.jsxs)(`main`,{className:G.content,children:[S&&(0,R.jsxs)(`div`,{className:G.loopNag,children:[(0,R.jsx)(`span`,{className:G.loopNagText,children:a(S===`telegram`?`your morning ping has nowhere to land â connect telegram and the day starts itself.`:`your tasks are still verified by hand â install the extension and one keystroke does it.`)}),S===`telegram`?(0,R.jsx)(Rn,{to:`/app/settings`,className:G.loopNagLink,children:a(`connect`)}):(0,R.jsx)(Rn,{to:`/extension`,target:`_blank`,className:G.loopNagLink,children:a(`install`)}),(0,R.jsx)(`button`,{onClick:w,className:G.loopNagLater,children:a(`later`)})]}),!1,i.locked&&(0,R.jsxs)(`div`,{className:B(G.founderBanner,G.founderBannerLocked),children:[(0,R.jsx)(`span`,{className:G.founderBannerDot}),(0,R.jsx)(`span`,{children:a(`your free trial is over. subscribe to keep locking tasks and chatting.`)}),(0,R.jsx)(Rn,{to:`/app/settings`,className:G.founderBannerLink,children:a(`subscribe â`)})]}),(0,R.jsx)(Ut,{})]})]}),(0,R.jsx)(dh,{}),M&&(0,R.jsx)(_v,{title:`delete "${M.name}"?`,body:`this can't be undone. tasks locked under it aren't deleted â they'll show up under 'all companies' instead.`,confirmText:M.name,busy:ie,onConfirm:le,onCancel:()=>N(null)})]})}var Cv=`Ov23lizfy1diXZJyCrAX`;function wv(){return!0}async function Tv(e=`/app/settings`){let{data:t,error:n}=await L.functions.invoke(`github-oauth-start`,{body:{returnTo:e}});if(n||!t?.state)return;let r=new URLSearchParams({client_id:Cv,redirect_uri:`https://zwqymcoehifdzniztfzc.supabase.co/functions/v1/github-oauth-callback`,scope:`repo`,state:t.state});window.location.href=`https://github.com/login/oauth/authorize?${r.toString()}`}async function Ev(e){return L.from(`integrations`).select(`*`).eq(`user_id`,e).eq(`provider`,`github`).maybeSingle()}async function Dv(){let{data:e,error:t}=await Ym(`github-repos`);return t?{error:t}:e??{}}async function Ov(e){return L.from(`integrations`).update({repo_full_names:e,repo_full_name:e[0]??null}).eq(`provider`,`github`)}async function kv(){let{data:e,error:t}=await L.functions.invoke(`github-sync`);return t?{error:t.message}:e}async function Av(){let e=await L.rpc(`disconnect_integration`,{p_provider:`github`});return e.error||il(`github`,!1),e}var jv={card:`_card_1d8pf_1`,head:`_head_1d8pf_11`,kicker:`_kicker_1d8pf_12`,badge:`_badge_1d8pf_13`,headline:`_headline_1d8pf_14`,list:`_list_1d8pf_16`,row:`_row_1d8pf_17`,dot:`_dot_1d8pf_18`,msg:`_msg_1d8pf_19`,date:`_date_1d8pf_20`,foot:`_foot_1d8pf_21`};function Mv({userId:e}){let t=z(),[n,r]=(0,_.useState)(!1),[i,a]=(0,_.useState)([]);if((0,_.useEffect)(()=>{let t=!1;return(async()=>{let{data:n}=await L.from(`profiles`).select(`onboarding_mode`).eq(`id`,e).maybeSingle();if(n?.onboarding_mode!==`passive`)return;let i=new Date(Date.now()-7*864e5).toISOString().slice(0,10);async function o(){let{data:t}=await L.from(`activity`).select(`date, summary`).eq(`user_id`,e).eq(`provider`,`github`).gte(`date`,i).order(`date`,{ascending:!1}).limit(12);return t??[]}let s=await o();s.length===0&&(await kv().catch(()=>{}),s=await o()),!(t||s.length===0)&&(a(s),r(!0),$l(`first_verified_receipt`,{count:s.length,source:`github`}))})(),()=>{t=!0}},[e,!1]),!n)return null;let o=new Set(i.map(e=>e.date)).size;return(0,R.jsxs)(`div`,{className:jv.card,children:[(0,R.jsxs)(`div`,{className:jv.head,children:[(0,R.jsx)(`span`,{className:jv.kicker,children:t(`your last 7 days · verified by crew`)}),(0,R.jsxs)(`span`,{className:jv.badge,children:[`â `,t(`receipts, not self-reports`)]})]}),(0,R.jsxs)(`p`,{className:jv.headline,children:[(0,R.jsx)(`strong`,{children:i.length}),` `,t(`shipped across`),` `,(0,R.jsx)(`strong`,{children:o}),` `,t(o===1?`day â pulled straight from your commits.`:`days â pulled straight from your commits.`)]}),(0,R.jsx)(`ul`,{className:jv.list,children:i.slice(0,6).map((e,t)=>(0,R.jsxs)(`li`,{className:jv.row,children:[(0,R.jsx)(`span`,{className:jv.dot}),(0,R.jsx)(`span`,{className:jv.msg,children:e.summary}),(0,R.jsx)(`span`,{className:jv.date,children:e.date.slice(5)})]},t))}),(0,R.jsx)(`p`,{className:jv.foot,children:t(`you're in passive mode â Crew's watching and will nudge you. lock in your daily 3 whenever you're ready.`)})]})}
65var Nv=[{en:`Nobody checks a solo founder. That is the whole problem.`,fr:`Personne ne vérifie un fondateur solo. C'est tout le problème.`},{en:`Motivation picks the day. Discipline picks the week.`,fr:`La motivation choisit la journée. La discipline choisit la semaine.`},{en:`The work you keep moving is the work you are avoiding.`,fr:`Le travail que tu repousses est le travail que tu évites.`},{en:`Three finished beats ten started.`,fr:`Trois terminées valent mieux que dix commencées.`},{en:`A record you can edit is a record you will edit.`,fr:`Un historique modifiable est un historique que tu modifieras.`},{en:`You will always find time for the work that is easy to prove.`,fr:`Tu trouveras toujours du temps pour le travail facile à prouver.`},{en:`The day is the unit. The week is the verdict.`,fr:`La journée est l'unité. La semaine est le verdict.`},{en:`Consistency beats intensity, and it is not close.`,fr:`La régularité bat l'intensité, et ce n'est pas serré.`},{en:`The category you skip is the one the company needs most.`,fr:`La catégorie que tu sautes est celle dont l'entreprise a le plus besoin.`},{en:`Plans are cheap. Evidence is not.`,fr:`Les plans ne coûtent rien. Les preuves, si.`},{en:`If it took a week and nothing shows, it did not take a week.`,fr:`Si ça a pris une semaine et que rien ne le montre, ça n'a pas pris une semaine.`},{en:`You cannot audit yourself with the brain that made the excuse.`,fr:`Tu ne peux pas t'auditer avec le cerveau qui a inventé l'excuse.`},{en:`A week you cannot describe is a week you did not plan.`,fr:`Une semaine que tu ne sais pas décrire est une semaine que tu n'as pas planifiée.`},{en:`Busy is not a result. Shipped is.`,fr:`Ãtre occupé n'est pas un résultat. Livrer, si.`},{en:`Start smaller than feels serious. Then do it every day.`,fr:`Commence plus petit que ce qui semble sérieux. Puis fais-le tous les jours.`}];function Pv(e,t){let n=0;for(let t=0;t<e.length;t++)n=n*31+e.charCodeAt(t)>>>0;let r=Nv[n%Nv.length];return t===`fr`?r.fr:r.en}var Fv={overlay:`_overlay_ykbws_1`,shareFadeIn:`_shareFadeIn_ykbws_1`,modal:`_modal_ykbws_15`,cardHost:`_cardHost_ykbws_25`,designs:`_designs_ykbws_27`,designChip:`_designChip_ykbws_28`,designChipOn:`_designChipOn_ykbws_41`,liveToggle:`_liveToggle_ykbws_47`,liveToggleOn:`_liveToggleOn_ykbws_60`,liveDot:`_liveDot_ykbws_61`,liveLabel:`_liveLabel_ykbws_67`,liveTrack:`_liveTrack_ykbws_75`,liveKnob:`_liveKnob_ykbws_82`,liveHint:`_liveHint_ykbws_89`,actions:`_actions_ykbws_97`,x:`_x_ykbws_98`,ghost:`_ghost_ykbws_98`,close:`_close_ykbws_115`};function Iv({card:e,userId:t,xLine:n,filename:r,onClose:i}){let a=z(),[o,s]=(0,_.useState)(e.design??`aurora`),[c,l]=(0,_.useState)(e.live??!1),[u,d]=(0,_.useState)(null),[f,p]=(0,_.useState)(null),[m,h]=(0,_.useState)(null),[g,v]=(0,_.useState)(!1),y=(0,_.useRef)(null),b=(0,_.useMemo)(()=>({...e,design:o,live:c}),[e,o,c]),x=`${o}|${c}`;function S(){switch(b.kind){case`founder`:return(0,R.jsx)(mf,{data:b});case`streak`:return(0,R.jsx)(hf,{data:b});case`weekly`:return(0,R.jsx)(gf,{data:b})}}async function C(){if(u&&f===x)return`${window.location.origin}/s/${u}`;if(!t)return null;let{token:n}=await sf(t,{...e,design:o,live:c});return n?(d(n),p(x),`${window.location.origin}/s/${n}`):null}async function w(){h(`link`);let e=await C()??`https://www.meetcrew.app`;h(null);let t=`https://twitter.com/intent/tweet?text=${encodeURIComponent(n)}&url=${encodeURIComponent(e)}`;window.open(t,`_blank`,`noopener,noreferrer`)}async function T(){h(`link`);let e=await C();h(null),e&&navigator.clipboard.writeText(e).then(()=>{v(!0),setTimeout(()=>v(!1),2200)})}async function E(){if(y.current){h(`png`);try{await Rp(y.current,r)}catch{}h(null)}}return(0,R.jsx)(`div`,{className:Fv.overlay,role:`dialog`,"aria-modal":`true`,onClick:i,children:(0,R.jsxs)(`div`,{className:Fv.modal,onClick:e=>e.stopPropagation(),children:[(0,R.jsx)(`div`,{ref:y,className:Fv.cardHost,children:S()}),(0,R.jsx)(`div`,{className:Fv.designs,children:af.map(e=>(0,R.jsx)(`button`,{className:`${Fv.designChip} ${o===e.id?Fv.designChipOn:``}`,onClick:()=>s(e.id),children:e.label},e.id))}),(0,R.jsxs)(`button`,{className:`${Fv.liveToggle} ${c?Fv.liveToggleOn:``}`,onClick:()=>l(e=>!e),role:`switch`,"aria-checked":c,children:[(0,R.jsx)(`span`,{className:Fv.liveDot,"data-on":c,"aria-hidden":!0}),(0,R.jsx)(`span`,{className:Fv.liveLabel,children:a(c?`live link â updates automatically`:`make it a live link`)}),(0,R.jsx)(`span`,{className:Fv.liveTrack,children:(0,R.jsx)(`span`,{className:Fv.liveKnob})})]}),(0,R.jsx)(`span`,{className:Fv.liveHint,children:a(c?`the link + X post show your current stats and refresh as you ship. the downloaded image is always a snapshot.`:`off: a snapshot of right now. on: a link that stays up to date.`)}),(0,R.jsxs)(`div`,{className:Fv.actions,children:[(0,R.jsx)(`button`,{className:Fv.x,onClick:w,disabled:m===`link`,children:m===`link`?`â¦`:a(`share on ð`)}),(0,R.jsx)(`button`,{className:Fv.ghost,onClick:T,disabled:m===`link`||!t,children:a(g?`link copied â`:`copy link`)}),(0,R.jsx)(`button`,{className:Fv.ghost,onClick:E,disabled:m===`png`,children:a(m===`png`?`renderingâ¦`:`download image`)})]}),(0,R.jsx)(`button`,{className:Fv.close,onClick:i,"aria-label":a(`close`),children:`â`})]})})}var Lv={card:`_card_l4air_2`,head:`_head_l4air_12`,kicker:`_kicker_l4air_17`,pctBig:`_pctBig_l4air_25`,pctSign:`_pctSign_l4air_32`,allTime:`_allTime_l4air_33`,shareMini:`_shareMini_l4air_44`,track:`_track_l4air_62`,fill:`_fill_l4air_69`,row:`_row_l4air_78`,avatar:`_avatar_l4air_90`,avatarImg:`_avatarImg_l4air_102`,avatarEmoji:`_avatarEmoji_l4air_103`,rowBody:`_rowBody_l4air_105`,rowLead:`_rowLead_l4air_106`,rowName:`_rowName_l4air_113`,rowTag:`_rowTag_l4air_119`,rowLink:`_rowLink_l4air_120`,gapHint:`_gapHint_l4air_123`,blindSpot:`_blindSpot_l4air_134`,blindSpotLink:`_blindSpotLink_l4air_142`};function Rv({tier:e}){let[t,n]=(0,_.useState)(!1),r=!!e.photo&&!t;return(0,R.jsx)(`span`,{className:Lv.avatar,children:r?(0,R.jsx)(`img`,{className:Lv.avatarImg,src:e.photo,alt:e.name,loading:`lazy`,referrerPolicy:`no-referrer`,onError:()=>n(!0)}
65):(0,R.jsx)(`span`,{className:Lv.avatarEmoji,"aria-hidden":!0,children:e.emoji})})}function zv({pct:e,name:t,product:n,userId:r,period:i=`all-time`,volume:a,blindSpot:o}){let s=z(),{clamped:c,current:l,mode:u}=Cg(e,a),d=Tg(e,a),[f,p]=(0,_.useState)(!1),m=s(i===`weekly`?`this week`:`all time`),h=s(i===`weekly`?`this week's follow-through`:`all-time follow-through`),g=n&&n.trim()||t&&t.trim()||s(`my startup`),v=s(i===`weekly`?`this week`:`all-time`),y=l.generic?s(`I'm {pct}% locked-in on {who} {span} â building the habit with Crew.`).replace(`{pct}`,String(c)).replace(`{who}`,g).replace(`{span}`,v):s(`I'm in {mode} â shipping like {founder} ({tag}), {pct}% {span} follow-through on {who}, tracked with Crew.`).replace(`{mode}`,u).replace(`{founder}`,l.name).replace(`{tag}`,l.tag).replace(`{pct}`,String(c)).replace(`{span}`,v).replace(`{who}`,g),b=Eg(c,t,n,h,a),x=(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(Rv,{tier:l}),(0,R.jsxs)(`span`,{className:Lv.rowBody,children:[(0,R.jsx)(`span`,{className:Lv.rowLead,children:l.generic?s(`current mode`):u}),(0,R.jsxs)(`span`,{className:Lv.rowName,children:[l.name,(0,R.jsxs)(`span`,{className:Lv.rowTag,children:[` · `,l.tag]}),l.url&&(0,R.jsx)(`span`,{className:Lv.rowLink,children:` â`})]})]})]});return(0,R.jsxs)(`div`,{className:Lv.card,children:[(0,R.jsxs)(`div`,{className:Lv.head,children:[(0,R.jsx)(`span`,{className:Lv.kicker,children:s(`proof rate`)}),(0,R.jsxs)(`span`,{className:Lv.pctBig,children:[c,(0,R.jsx)(`span`,{className:Lv.pctSign,children:`%`})]}),(0,R.jsx)(`span`,{className:Lv.allTime,children:m}),(0,R.jsx)(`button`,{className:Lv.shareMini,onClick:()=>p(!0),"aria-label":s(`Share your proof rate`),children:s(`share â`)})]}),(0,R.jsx)(`div`,{className:Lv.track,role:`progressbar`,"aria-valuenow":c,"aria-valuemin":0,"aria-valuemax":100,children:(0,R.jsx)(`div`,{className:Lv.fill,style:{width:`${c}%`}})}),l.url?(0,R.jsx)(`a`,{className:Lv.row,href:l.url,target:`_blank`,rel:`noopener noreferrer`,children:x}):(0,R.jsx)(`div`,{className:Lv.row,children:x}),d&&(0,R.jsx)(`span`,{className:Lv.gapHint,children:d}),o?.stalled&&(0,R.jsxs)(`span`,{className:Lv.blindSpot,children:[s(`{n} finished tasks sit outside this number â nothing could prove them, so they neither raise nor lower it.`).replace(`{n}`,String(o.attested)),` `,(0,R.jsx)(Rn,{to:`/app/settings#connectors`,className:Lv.blindSpotLink,children:s(`connect a tool to make them count â`)})]}),f&&(0,R.jsx)(Iv,{card:b,userId:r,xLine:y,filename:`crew-founder-tier-${c}pct`,onClose:()=>p(!1)})]})}var Bv={embedded:`_embedded_1ef8m_6`,head:`_head_1ef8m_12`,heading:`_heading_1ef8m_14`,subhead:`_subhead_1ef8m_21`,empty:`_empty_1ef8m_27`,layout:`_layout_1ef8m_35`,main:`_main_1ef8m_41`,statStrip:`_statStrip_1ef8m_49`,stat:`_stat_1ef8m_49`,statLabel:`_statLabel_1ef8m_66`,statValue:`_statValue_1ef8m_73`,statSub:`_statSub_1ef8m_80`,grid:`_grid_1ef8m_87`,card:`_card_1ef8m_92`,cardKicker:`_cardKicker_1ef8m_103`,"accent-danger":`_accent-danger_1ef8m_113`,cardPrefix:`_cardPrefix_1ef8m_113`,"accent-primary":`_accent-primary_1ef8m_114`,"accent-success":`_accent-success_1ef8m_115`,"accent-secondary":`_accent-secondary_1ef8m_116`,cardBody:`_cardBody_1ef8m_118`,cardStat:`_cardStat_1ef8m_125`,recs:`_recs_1ef8m_134`,recsHead:`_recsHead_1ef8m_144`,recsKicker:`_recsKicker_1ef8m_150`,recsSub:`_recsSub_1ef8m_157`,rec:`_rec_1ef8m_134`,recBadge:`_recBadge_1ef8m_170`,recBadgeHot:`_recBadgeHot_1ef8m_182`,recText:`_recText_1ef8m_186`,recTitle:`_recTitle_1ef8m_187`,recBody:`_recBody_1ef8m_193`,chatPanel:`_chatPanel_1ef8m_201`,chatPanelEmbedded:`_chatPanelEmbedded_1ef8m_222`,chatHead:`_chatHead_1ef8m_228`,chatKicker:`_chatKicker_1ef8m_235`,chatSub:`_chatSub_1ef8m_242`,chatBody:`_chatBody_1ef8m_247`,chatEmpty:`_chatEmpty_1ef8m_255`,chatEmptyText:`_chatEmptyText_1ef8m_261`,starterChips:`_starterChips_1ef8m_268`,starterChip:`_starterChip_1ef8m_268`,typingWrap:`_typingWrap_1ef8m_286`,chatInputRow:`_chatInputRow_1ef8m_287`,chatInput:`_chatInput_1ef8m_287`,chatSend:`_chatSend_1ef8m_304`,chatSendActive:`_chatSendActive_1ef8m_315`,page:`_page_1ef8m_324`,simple:`_simple_1ef8m_336`,findings:`_findings_1ef8m_342`,finding:`_finding_1ef8m_342`,findingKicker:`_findingKicker_
651ef8m_360`,findingBody:`_findingBody_1ef8m_368`,findingStat:`_findingStat_1ef8m_378`};function Vv(){let e=z(),{session:t}=ll(),{active:n,firstWorkspaceId:r}=wl(),i=!!n&&n.id===r,{entries:a,loading:o}=nf(t?.user.id,n?.id,i),{cfg:s}=xh(t?.user.id),c=e=>Math.round(e*100),l=(0,_.useMemo)(()=>{let e=Hh(a),t=e.filter(e=>e.total>0).length,n=e=>e.reduce((e,t)=>({done:e.done+t.done,total:e.total+t.total}),{done:0,total:0}),r=n(e.slice(-7)),i=n(e.slice(-30)),o=[...cg(a).filter(e=>e.total>=2)].sort((e,t)=>t.rate-e.rate)[0];return{streak:Xh(a,s),best:rg(a,s),last7Pct:r.total?c(r.done/r.total):0,last30Pct:i.total?c(i.done/i.total):0,daysTracked:t,bestDay:o?o.day:null,bestDayPct:o?c(o.rate):0}},[a,s]),u=(0,_.useMemo)(()=>{if(a.length===0)return[];let t=og(a),n=Object.entries(t).filter(([,e])=>e.total>=1),r=[...n].sort((e,t)=>t[1].slipRate-e[1].slipRate)[0],i=[...n].sort((e,t)=>e[1].slipRate-t[1].slipRate)[0],o=sg(a),s=c(o.weekend),l=c(o.weekday),u=o.weekday>0?Math.round((o.weekend/o.weekday-1)*100):0,d=[...cg(a)].sort((e,t)=>t.rate-e.rate)[0],f=[];if(r){let[t,n]=r,i=n.total-n.done;f.push({accent:`danger`,prefix:`â`,kicker:e(`avoidance pattern`),body:n.slipRate===0?e(`nothing is slipping right now â every category is landing. keep the pressure on.`):e(`{cat} tasks slip {pct}% of the time â your weakest category. it's the same work getting pushed. not a time problem.`).replace(`{cat}`,t).replace(`{pct}`,String(c(n.slipRate))),stat:e(`{skipped} of {total} {cat} tasks skipped`).replace(`{skipped}`,String(i)).replace(`{total}`,String(n.total)).replace(`{cat}`,t)})}if(f.push({accent:`primary`,prefix:`â`,kicker:e(`weekend edge`),body:e(`you complete {we}% of tasks on weekends vs {wd}% on weekdays{lift}. whatever's different on saturdays, replicate it.`).replace(`{we}`,String(s)).replace(`{wd}`,String(l)).replace(`{lift}`,u>0?e(` â a {n}% lift`).replace(`{n}`,String(u)):``),stat:e(`sat/sun: {we}% · monâfri: {wd}%`).replace(`{we}`,String(s)).replace(`{wd}`,String(l))}),i){let[t,n]=i;f.push({accent:`success`,prefix:`â`,kicker:e(`where you're disciplined`),body:n.slipRate===0?e(`{cat} tasks: 0% slip across all {total}. you never let this one wait â that's your anchor habit.`).replace(`{cat}`,t).replace(`{total}`,String(n.total)):e(`{cat} is your strongest category at {pct}% completion. lean on it.`).replace(`{cat}`,t).replace(`{pct}`,String(c(1-n.slipRate))),stat:e(`{done} of {total} {cat} done`).replace(`{done}`,String(n.done)).replace(`{total}`,String(n.total)).replace(`{cat}`,t)})}return f.push({accent:`secondary`,prefix:`â`,kicker:e(`strongest day`),body:!d||d.total===0?e(`not enough days locked yet to find your strongest day.`):e(`{day} is your best day â {pct}% completion. put the work that matters most there.`).replace(`{day}`,e(d.day)).replace(`{pct}`,String(c(d.rate))),stat:d?e(`{done} of {total} tasks done`).replace(`{done}`,String(d.done)).replace(`{total}`,String(d.total)):`â`}),f},[a]),d=(0,_.useMemo)(()=>{if(a.length===0)return[];let t=[],n=og(a),r=[...Object.entries(n).filter(([,e])=>e.total>=2)].sort((e,t)=>t[1].slipRate-e[1].slipRate)[0],i=sg(a),o=[...cg(a).filter(e=>e.total>=2)].sort((e,t)=>t.rate-e.rate)[0],s=a[a.length-1],u=(s?.priorities??[]).filter(e=>e.status!==`done`).map(e=>({text:e.text,days:dg(a,e.text,s.date)})).filter(e=>e.days>=2).sort((e,t)=>t.days-e.days)[0];return u&&t.push({priority:1,title:e(`unstick "{task}"`).replace(`{task}`,u.text.length>40?u.text.slice(0,40)+`â¦`:u.text),body:e(`it's slipped {n} days running. do it first thing tomorrow, or cut it â a task you keep dodging is costing you a slot every day.`).replace(`{n}`,String(u.days))}),r&&r[1].slipRate>=.4&&t.push({priority:1,title:e(`lock only one {cat} task tomorrow`).replace(`{cat}`,r[0]),body:e(`{cat} slips {pct}% of the time. stop batching it â commit to a single {cat} task and do it before anything else.`).replace(`{pct}`,String(c(r[1].slipRate))).replaceAll(`{cat}`,r[0])}),i.weekday>0&&i.weekend/i.weekday>=1.2&&t.push({priority:2,title:e(`move your hardest task to the weekend`),body:e(`you finish {we}% on weekends vs {wd}% on weekdays. put the task you most want to avoid on saturday morning.`).replace(`{we}`,String(c(i.weekend))).replace(`{wd}`,String(c(i.weekday)))}),o&&o.rate>=.7&&t.push({priority:2,title:e(`put the work that matters most on {day}`).replace(`{day}`,e(o.day)),body:e(`you hit {pct}% on {day}s. deliberately schedule the work that moves your goal most on that day.`).replace(`{pct}`,String(c(o.rate))).replace(`{day}`,e(o.day))}),l.streak===0&&l.daysTracked>=2&&t.push({priority:1,title:e(`rebuild your streak with 3 realistic tasks`),body:e(`your streak
65is broken. tomorrow, lock 3 tasks you're 90% sure you'll finish â momentum first, ambition second.`)}),t.sort((e,t)=>e.priority-t.priority).slice(0,4)},[a,l]);return(0,R.jsxs)(`div`,{className:Bv.embedded,children:[(0,R.jsxs)(`div`,{className:Bv.head,children:[(0,R.jsx)(`span`,{className:Bv.heading,children:e(`patterns`)}),(0,R.jsx)(`p`,{className:Bv.subhead,children:a.length>0?e(`what the last {n} tracked days say about how you actually work.`).replace(`{n}`,String(l.daysTracked)):e(`lock a few days to start seeing patterns.`)})]}),o?(0,R.jsx)(`p`,{className:Bv.subhead,children:e(`loadingâ¦`)}):a.length===0?(0,R.jsx)(`p`,{className:Bv.empty,children:e(`No data yet. Set today's three on the Today page; patterns appear after a few days.`)}):(0,R.jsxs)(`div`,{className:Bv.simple,children:[(0,R.jsx)(`ul`,{className:Bv.findings,children:u.map(e=>(0,R.jsxs)(`li`,{className:Bv.finding,children:[(0,R.jsx)(`span`,{className:Bv.findingKicker,children:e.kicker}),(0,R.jsx)(`p`,{className:Bv.findingBody,children:e.body}),(0,R.jsx)(`span`,{className:Bv.findingStat,children:e.stat})]},e.kicker))}),d.length>0&&(0,R.jsxs)(`div`,{className:Bv.recs,children:[(0,R.jsxs)(`div`,{className:Bv.recsHead,children:[(0,R.jsx)(`span`,{className:Bv.recsKicker,children:e(`what to do about it`)}),(0,R.jsx)(`span`,{className:Bv.recsSub,children:e(`ranked by impact`)})]}),d.map((t,n)=>(0,R.jsxs)(`div`,{className:Bv.rec,children:[(0,R.jsx)(`span`,{className:B(Bv.recBadge,t.priority===1&&Bv.recBadgeHot),children:t.priority===1?e(`now`):e(`soon`)}),(0,R.jsxs)(`div`,{className:Bv.recText,children:[(0,R.jsx)(`span`,{className:Bv.recTitle,children:t.title}),(0,R.jsx)(`span`,{className:Bv.recBody,children:t.body})]})]},n))]})]})]})}var K={page:`_page_1w94v_3`,wrap:`_wrap_1w94v_9`,hero:`_hero_1w94v_19`,hStreak:`_hStreak_1w94v_29`,hClarity:`_hClarity_1w94v_30`,hWeek:`_hWeek_1w94v_31`,eyebrow:`_eyebrow_1w94v_53`,plantHero:`_plantHero_1w94v_66`,streakMetaSmall:`_streakMetaSmall_1w94v_72`,metaDot:`_metaDot_1w94v_90`,clarityLine:`_clarityLine_1w94v_94`,clarityHl:`_clarityHl_1w94v_104`,weekRing:`_weekRing_1w94v_108`,ringWrap:`_ringWrap_1w94v_115`,ringCenter:`_ringCenter_1w94v_122`,ringPct:`_ringPct_1w94v_131`,ringCap:`_ringCap_1w94v_141`,weekCount:`_weekCount_1w94v_150`,weekCountOf:`_weekCountOf_1w94v_159`,weekLabel:`_weekLabel_1w94v_165`,onTrackBadge:`_onTrackBadge_1w94v_171`,dot:`_dot_1w94v_187`,tiles:`_tiles_1w94v_197`,tile:`_tile_1w94v_197`,tileTop:`_tileTop_1w94v_215`,tileLabel:`_tileLabel_1w94v_222`,tileIcon:`_tileIcon_1w94v_231`,tileVal:`_tileVal_1w94v_243`,tileUnit:`_tileUnit_1w94v_253`,tileFoot:`_tileFoot_1w94v_260`,tileSub:`_tileSub_1w94v_266`,todayCard:`_todayCard_1w94v_277`,todayPanelHead:`_todayPanelHead_1w94v_281`,todayPanelTitle:`_todayPanelTitle_1w94v_290`,todayViewAllBtn:`_todayViewAllBtn_1w94v_298`,todayEmpty:`_todayEmpty_1w94v_312`,todayList:`_todayList_1w94v_319`,todayItem:`_todayItem_1w94v_327`,todayDotDone:`_todayDotDone_1w94v_336`,todayDotPending:`_todayDotPending_1w94v_336`,todayDotSkipped:`_todayDotSkipped_1w94v_336`,todayDotNotStarted:`_todayDotNotStarted_1w94v_336`,todayText:`_todayText_1w94v_348`,todayTextDone:`_todayTextDone_1w94v_354`,todayStatus:`_todayStatus_1w94v_362`,todayStatusProgress:`_todayStatusProgress_1w94v_373`,patternsSection:`_patternsSection_1w94v_381`,deltaUp:`_deltaUp_1w94v_390`,deltaDown:`_deltaDown_1w94v_400`,deltaFlat:`_deltaFlat_1w94v_410`,spark:`_spark_1w94v_420`,cols:`_cols_1w94v_428`,card:`_card_1w94v_436`,panelHead:`_panelHead_1w94v_275`,panelTitle:`_panelTitle_1w94v_275`,legend:`_legend_1w94v_468`,legendItem:`_legendItem_1w94v_475`,legendSw:`_legendSw_1w94v_484`,legendSwDash:`_legendSwDash_1w94v_491`,seg:`_seg_1w94v_498`,segBtn:`_segBtn_1w94v_508`,segActive:`_segActive_1w94v_521`,chartBox:`_chartBox_1w94v_533`,chartWrap:`_chartWrap_1w94v_541`,chartTooltip:`_chartTooltip_1w94v_563`,chartTooltipVal:`_chartTooltipVal_1w94v_581`,chartTooltipLabel:`_chartTooltipLabel_1w94v_585`,viewAllBtn:`_viewAllBtn_1w94v_592`,feed:`_feed_1w94v_606`,feedItem:`_feedItem_1w94v_617`,feedIc:`_feedIc_1w94v_626`,feedIc_done:`_feedIc_done_1w94v_639`,feedIc_drift:`_feedIc_drift_1w94v_645`,feedIc_blue:`_feedIc_blue_1w94v_651`,feedMain:`_feedMain_1w94v_657`,feedTitle:`_feedTitle_1w94v_662`,feedSub:`_feedSub_1w94v_669`,feedTime:`_feedTime_1w94v_677`,receipt:`_receipt_1w94v_686`,badgeGreen:`_badgeGreen_1w94v_708`,badgeRed:`_badgeRed_1w94v_723`,mixBody:`_mixBody_1w94v_775`,mixFigure:`_mixFigure_1w94v_783`,mixTrack:`_mixTrack_1w94v_792`,mixVerified:`_mixVerified_1w94v_802`,mixAttested:`_mixAttested_1w94v_805`,mixLegend:`_mixLegend_1w94v_807`,clarityAside:`_clarityAside_1w94v_818`};function Hv(e){let t=e.match(/(\d+)\s*commit/);return t?parseInt(t[1],10):0}function Uv(e,t){return e.split(t).map((e,t)=>t%2==1?(0,R.jsx)(`b`,{children:e},t):e)}function Wv(e){return e.split(`*`).map((e,t)=>t%2==1?(0,R.jsx)(`span`,{className:K.clarityHl,children:e},t):e)}function Gv(){let e=(0,_.useRef)(null),[t,n]=(0,_.useState)(0);return(0,_.useEffect)(()=>{let t=e.current;if(!t)return;let r=new ResizeObserver(e=>{let t=e[0]?.contentRect.width;t&&n(t)});return r.observe(t),()=>r.disconnect()},[]),[e,t]}function Kv(e,t){let n=t||560,r=Math.max(2,Math.floor(n/58)),i=Math.max(1,Math.ceil(e/r)),a=n/560;return{step:i,fontSize:Math.max(7,Math.min(15,10/a))}}function qv({pct:e,size:t=92,stroke:n=8}){let r=(t-n)/2,i=2*Math.PI*r,a=i*(1-e/100),o=t/2;return(0,R.jsxs)(`svg`,{width:t,height:t,viewBox:`0 0 ${t} ${t}`,style:{transform:`rotate(-90deg)`}
65,"aria-hidden":!0,children:[(0,R.jsx)(`circle`,{cx:o,cy:o,r,fill:`none`,stroke:`var(--surface-inset)`,strokeWidth:n}),(0,R.jsx)(`circle`,{cx:o,cy:o,r,fill:`none`,stroke:`var(--electric)`,strokeWidth:n,strokeDasharray:i,strokeDashoffset:a,strokeLinecap:`round`})]})}function Jv({data:e}){let t={t:12,r:8,b:32,l:8},n=560-t.l-t.r,r=200-t.t-t.b,i=e.length,a=Math.max(...e.map(e=>e.v),1),o=n/i,s=[0,.5,1].map(e=>Math.round(e*a));function c(e){return t.l+o*e+o/2}function l(e){return t.t+(1-e/a)*r}let[u,d]=Gv(),{step:f,fontSize:p}=Kv(i,d),[m,h]=(0,_.useState)(null);function g(e,t){let n=(e-t.left)/t.width*560,r=0,a=1/0;for(let e=0;e<i;e++){let t=Math.abs(c(e)-n);t<a&&(a=t,r=e)}return r}let v=m===null?null:c(m)/560*100,y=e.map((e,t)=>`${c(t).toFixed(1)},${l(e.v).toFixed(1)}`).join(` `);return(0,R.jsxs)(`div`,{ref:u,className:K.chartWrap,onPointerDown:e=>h(g(e.clientX,e.currentTarget.getBoundingClientRect())),onPointerMove:e=>h(g(e.clientX,e.currentTarget.getBoundingClientRect())),onPointerLeave:()=>h(null),children:[(0,R.jsxs)(`svg`,{viewBox:`0 0 560 200`,width:`100%`,preserveAspectRatio:`xMidYMid meet`,"aria-hidden":!0,style:{display:`block`,height:`auto`,overflow:`visible`},children:[s.map((e,r)=>(0,R.jsxs)(`g`,{children:[(0,R.jsx)(`line`,{x1:t.l,y1:l(e),x2:t.l+n,y2:l(e),stroke:`var(--border-2)`,strokeWidth:`1`,strokeDasharray:r===0?void 0:`2 5`}),(0,R.jsx)(`text`,{x:t.l+2,y:l(e)-3,fill:`var(--faint)`,fontSize:p,fontFamily:`var(--font-mono)`,style:{fontVariantNumeric:`tabular-nums`},children:e})]},`g-${r}`)),(0,R.jsx)(`polyline`,{points:y,fill:`none`,stroke:`var(--electric)`,strokeWidth:`2`,strokeLinejoin:`round`,strokeLinecap:`round`}),e.map((e,t)=>t!==i-1&&(0,R.jsx)(`circle`,{cx:c(t),cy:l(e.v),r:`1.8`,fill:`var(--electric)`,opacity:`0.35`},`pt-${t}`)),i>0&&(0,R.jsxs)(`g`,{children:[(0,R.jsx)(`circle`,{cx:c(i-1),cy:l(e[i-1].v),r:`7`,fill:`var(--electric)`,opacity:`0.14`}),(0,R.jsx)(`circle`,{cx:c(i-1),cy:l(e[i-1].v),r:`3.5`,fill:`var(--electric)`,stroke:`var(--surface)`,strokeWidth:`1.5`})]}),m!==null&&(0,R.jsx)(`circle`,{cx:c(m),cy:l(e[m].v),r:`4.5`,fill:`var(--electric)`}),e.map((e,t)=>t%f===0&&(0,R.jsx)(`text`,{x:c(t),y:194,textAnchor:`middle`,fill:`var(--faint)`,fontSize:p,fontFamily:`var(--font-mono)`,style:{fontVariantNumeric:`tabular-nums`},children:e.l},`l-${t}`)),m!==null&&(0,R.jsx)(`line`,{x1:c(m),y1:t.t,x2:c(m),y2:t.t+r,stroke:`var(--electric)`,strokeOpacity:`0.25`,strokeWidth:`1`,strokeDasharray:`3 3`})]}),m!==null&&v!==null&&(0,R.jsxs)(`div`,{className:K.chartTooltip,style:{left:`${Math.min(Math.max(v,10),90)}%`},children:[(0,R.jsx)(`span`,{className:K.chartTooltipVal,children:e[m].v}),(0,R.jsx)(`span`,{className:K.chartTooltipLabel,children:e[m].l})]})]})}function Yv(e,t=6){let n=[];if(e.length===0)return n;let r=e.slice().reverse(),i=e[e.length-1].date;for(let e of r){let r=(new Date(i).getTime()-new Date(e.date).getTime())/864e5,a=r===0?`today`:r===1?`yest`:`${Math.round(r)}d ago`;for(let r of e.priorities){if(r.status===`done`){let e=r.proof?r.proof.split(/\s[·â¢]\s/):[];n.push({icon:r.category===`build`?`deploy`:r.category===`sales`?`zap`:`check`,kind:`done`,title:r.text.charAt(0).toUpperCase()+r.text.slice(1),receipt:e.map(e=>({icon:e.match(/commit/i)?`commit`:e.match(/deploy|live|shipped/i)?`deploy`:`clock`,text:e.length>70?`${e.slice(0,70).trim()}â¦`:e})),badge:{text:`done`,kind:`green`},ago:a})}else r.status===`skipped`&&n.push({icon:`xCircle`,kind:`drift`,title:`Skipped: ${r.text}`,receipt:[],badge:{text:`drift`,kind:`red`},ago:a});if(n.length>=t)break}if(n.length>=t)break}return n}function Xv(){let[e,t]=(0,_.useState)(!1),{session:n,profile:r}=ll(),{active:i,firstWorkspaceId:a}=wl(),o=!!i&&i.id===a,{entries:s,loading:c}=nf(n?.user.id,i?.id,o);Fg(n?.user.id,s,r?.name,r?.product_name);let{cfg:l}=xh(n?.user.id),[u,d]=(0,_.useState)(`cumulative`),f=z(),{lang:p}=ml(),m=(()=>{let e=new Date,t=(e.getDay()+6)%7;return e.setDate(e.getDate()-t),e.toLocaleDateString(`en-CA`)})(),[h,g]=(0,_.useState)(null),[v,y]=(0,_.useState)({});(0,_.useEffect)(()=>{n?.user.id&&Gd(n.user.id,rf(),i?.id,o).then(({data:e})=>{let t=e??[];g(t),ph(t.map(e=>e.id)).then(y)})},[n?.user.id,i?.id,o]);let b=e=>
65e.status===`pending`&&(!!e.started_at||(v[e.id]?.done??0)>0),x=(0,_.useMemo)(()=>{let e=Hh(s),t=e.slice(-7),n=e.slice(-14,-7),r=t.reduce((e,t)=>e+t.done,0),i=t.reduce((e,t)=>e+t.total,0),a=n.reduce((e,t)=>e+t.done,0),o=n.reduce((e,t)=>e+t.total,0),c=i>0?Math.round(r/i*100):0,u=o>0?Math.round(a/o*100):0,d=s.slice(-7),f=s.slice(-14,-7),p=d.flatMap(e=>e.priorities).reduce((e,t)=>e+Hv(t.proof),0),m=f.flatMap(e=>e.priorities).reduce((e,t)=>e+Hv(t.proof),0),h=t.filter(e=>e.total>0&&e.pct<1).length,g=n.filter(e=>e.total>0&&e.pct<1).length,_=Xh(s,l),v=rg(s,l),y=_>0?s.slice(-_).filter(e=>e.priorities.some(e=>/\b([6-9]|10):?\d*\s*am\b/i.test(e.proof))).length:0,b=s.filter(e=>e.priorities.some(e=>e.category===`sales`&&e.status===`skipped`)).length,x=Hh(s).slice(-30),S=lg(s).slice(-16),C=ug(s),w=x.map(e=>({l:new Date(e.date+`T12:00:00Z`).toLocaleDateString(`en-US`,{month:`short`,day:`numeric`,timeZone:`UTC`}),v:e.done})),T=S.map(e=>({l:new Date(e.weekStart+`T12:00:00Z`).toLocaleDateString(`en-US`,{month:`short`,day:`numeric`,timeZone:`UTC`}),v:e.done})),E=C.map(e=>({l:new Date(e.monthStart+`T12:00:00Z`).toLocaleDateString(`en-US`,{month:`short`,timeZone:`UTC`}),v:e.done})),D=0,O=Hh(s).map(e=>(D+=e.done,{l:new Date(e.date+`T12:00:00Z`).toLocaleDateString(`en-US`,{month:`short`,day:`numeric`,timeZone:`UTC`}),v:D}));return{last7Pct:c,prior7Pct:u,completionDelta:c-u,weekPct:c,weekDone:r,weekTotal:i,commitsLast7:p,commitsDelta:p-m,driftLast7:h,driftDelta:h-g,completionSpark:t.map(e=>Math.round(e.pct*100)),shippedSpark:d.map(e=>e.priorities.filter(e=>e.status===`done`).length),driftSpark:t.map(e=>+(e.total>0&&e.pct<1)),commitSpark:d.map(e=>e.priorities.reduce((e,t)=>e+Hv(t.proof),0)),streak:_,best:v,lockedBy9:y,salesSlipped:b,dailyData:w,weeklyData:T,monthlyData:E,cumulativeData:O,feedItems:Yv(s,1/0)}},[s,l]);if(c)return(0,R.jsx)(`div`,{className:K.page,children:(0,R.jsx)(`div`,{className:K.wrap,children:(0,R.jsx)(`p`,{children:f(`loading momentumâ¦`)})})});if(s.length===0)return(0,R.jsx)(`div`,{className:K.page,children:(0,R.jsx)(`div`,{className:K.wrap,children:(0,R.jsx)(`section`,{className:K.card,style:{padding:`var(--s-8)`,textAlign:`center`},children:(0,R.jsx)(`p`,{children:f(`no days locked yet. set today's 3 on the Today page to start building momentum.`)})})})});let{weekPct:S,weekDone:C,weekTotal:w,streak:T,best:E,lockedBy9:D,salesSlipped:O,dailyData:k,weeklyData:A,monthlyData:j,cumulativeData:ee,feedItems:te}=x,ne=O>0?f(`you ship most the builds â but sales tasks slip *{n}à in {days} days.* flip the order.`).replace(`{n}`,String(O)).replace(`{days}`,String(s.length)):w===0?f(`no tasks logged in the last 7 days. *lock today's 3* to restart momentum.`):S===0?f(`you locked {total} tasks this week but *shipped none.* nothing's moving â pick one and close it today.`).replace(`{total}`,String(w)):S<40?f(`only *{pct}% done this week* ({done}/{total}). you're locking tasks but not closing them.`).replace(`{pct}`,String(S)).replace(`{done}`,String(C)).replace(`{total}`,String(w)):S<80?f(`*{pct}% completion* this week ({done}/{total}) â {slip} slipped. tighten it.`).replace(`{pct}`,String(S)).replace(`{done}`,String(C)).replace(`{total}`,String(w)).replace(`{slip}`,String(w-C)):f(`steady execution â *{pct}% done* across the week. keep the cadence.`).replace(`{pct}`,String(S)),re=u===`cumulative`?ee:u===`D`?k:u===`W`?A:j,M=Rh(s),N=T>=E&&T>0,ie=ig(s,new Date,l),ae=Zh(s),P=ag(s,l).state;return(0,R.jsx)(`div`,{className:K.page,children:(0,R.jsxs)(`div`,{className:K.wrap,children:[n?.user?.id&&(0,R.jsx)(Mv,{userId:n.user.id}),M.claimed>0&&(0,R.jsxs)(`section`,{className:K.card,"aria-label":f(`evidence mix`),children:[(0,R.jsx)(`div`,{className:K.todayPanelHead,children:(0,R.jsx)(`div`,{className:K.todayPanelTitle,children:f(`evidence mix`)})}),(0,R.jsxs)(`div`,{className:K.mixBody,children:[(0,R.jsxs)(`span`,{className:K.mixFigure,children:[M.verifiedPct,`%`]}),(0,R.jsxs)(`span`,{className:K.mixTrack,role:`img`,"aria-label":f(`{v} verified, {a} on your word`).replace(`{v}`,String(M.verified)).replace(`{a}`,String(M.attested)),children:[(0,R.jsx)(`span`,{className:K.mixVerified,style:{width:`${M.verifiedPct}%`}}),(0,R.jsx)(`span`,{className:K.mixAttested,style:{width:`${100-(M.verifiedPct??0)}%`}})]}),(0,R.jsxs)(`p`,{className:K.mixLegend,children:[(0,R.jsx)(`b`,{children:M.verified}),` `,f(`verified by a connector`),` · `,(0,R.jsx)(`b`,{children:M.attested}),` `,f(`taken on your word`)]})]})]}),h!==null&&(0,R.jsxs)(`section`,{className:B(K.card,K.todayCard),"aria-label":f(`today's tasks`),children:[(0,R.jsxs)(`div`,{className:K.todayPanelHead,children:[(0,R.jsx)(`div`,{className:K.todayPanelTitle,children:f(`Today`)}),(0,R.jsxs)(Rn,{to:`/today`,className:K.todayViewAllBtn,children:[h.length===0?f(`set today's tasks`):f(`open today`),` `,(0,R.jsx)(Wm,{name:`chevronRight`,size:11})]})]}),h.length===0?(0,R.jsx)(`p`,{className:K.todayEmpty,children:f(`nothing locked in yet today.`)}):(0,R.jsx)(`ul`,{className:K.todayList,children:h.map(e=>(0,R.jsxs)(`li`,{className:K.todayItem,children:[(0,R.jsx)(`span`,{className:e.status===`done`?K.todayDotDone:e.status===`skipped`?K.todayDotSkipped:b(e)?K.todayDotPending:K.todayDotNotStarted,"aria-hidden":!0}),(0,R.jsx)(`span`,{className:e.status===`done`?K.todayTextDone:K.todayText,children:e.text}),(0,R.jsx)(`span`,{className:B(K.todayStatus,b(e)&&K.todayStatusProgress),children:e.status===`done`?f(`done`):e.status===`skipped`?f(`skipped`):b(e)?f(`in progress`):f(`not started`)})]},e.id))})]}),(0,R.jsxs)(`section`,{className:K.hero,"aria-label":f(`dashboard hero`),children:[(0,R.jsxs)(`div`,{className:K.hStreak,children:[(0,R.jsx)(`span`,{className:K.eyebrow,children:f(`Current streak`)}),(0,R.jsx)(`div`,{className:K.plantHero,children:(0,R.jsx)(Hu,{streak:T,longestStreak:E,atRisk:ie,inProgress:ae,health:P,size:104,showCaption:!1})}),(0,R.jsxs)(`div`,{className:K.streakMetaSmall,children:[(0,R.jsxs)(`span`,{children:[(0,R.jsx)(`b`,{children:T}),` `,f(`days`)]}),(0,R.jsx)(`span`,{className:K.metaDot,children:`·`}),(0,R.jsxs)(`span`,{children:[f(`best`),` `,(0,R.jsx)(`b`,{children:E})]}),(0,R.jsx)(`span`,{className:K.metaDot,children:`·`}),(0,R.jsxs)(`span`,{children:[f(`locked by 9am`),` `,(0,R.jsx)(`b`,{children:T>0?`${D}/${T}`:`â`})]})]})]}),(0,R.jsxs)(`div`,{className:K.hClarity,children:[(0,R.jsx)(`span`,{className:K.eyebrow,children:f(`crew read`)}),(0,R.jsx)(`p`,{className:K.clarityLine,children:Wv(ne)}),(0,R.jsx)(`p`,{className:K.clarityAside,children:Pv(m,p)})]}),(0,R.jsxs)(`div`,{className:K.hWeek,children:[(0,R.jsx)(`span`,{className:K.eyebrow,children:f(`This week`)}),(0,R.jsxs)(`div`,{className:K.weekRing,children:[(0,R.jsxs)(`div`,{className:K.ringWrap,children:[(0,R.jsx)(qv,{pct:S}),(0,R.jsxs)(`div`,{className:K.ringCenter,children:[(0,R.jsxs)(`span`,{className:K.ringPct,children:[S,`%`]}),(0,R.jsx)(`span`,{className:K.ringCap,children:f(`DONE`)})]})]}),(0,R.jsxs)(`div`,{children:[(0,R.jsxs)(`div`,{className:K.weekCount,children:[C,` `,(0,R.jsxs)(`span`,{className:K.weekCountOf,children:[`/ `,w]})]}),(0,R.jsx)(`div`,{className:K.weekLabel,children:f(`tasks shipped`)}),(0,R.jsxs)(`div`,{className:K.onTrackBadge,children:[(0,R.jsx)(`span`,{className:K.dot}),f(N?`best streak`:`on track`)]})]})]})]})]}),(0,R.jsx)(zv,{pct:Lh(s),volume:jg(s),blindSpot:Ng(s),userId:n?.user.id,name:r?.name,product:r?.product_name}),(0,R.jsxs)(`section`,{className:K.cols,children:[(0,R.jsxs)(`div`,{className:K.card,children:[(0,R.jsxs)(`div`,{className:K.panelHead,children:[(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`div`,{className:K.panelTitle,children:f(`Output over time`)}),(0,R.jsx)(`div`,{className:K.legend,children:(0,R.jsxs)(`span`,{className:K.legendItem,children:[(0,R.jsx)(`span`,{className:K.legendSw,style:{background:`var(--electric)`}}),f(u===`cumulative`?`Cumulative tasks done`:`Tasks done`)]})})]}),(0,R.jsx)(`div`,{className:K.seg,children:[`cumulative`,`D`,`W`,`M`].map(e=>(0,R.jsx)(`button`,{className:u===e?K.segActive:K.segBtn,onClick:()=>d(e),children:f(e===`cumulative`?`All`:e===`D`?`Day`:e===`W`?`Week`:`Month`)},e))})]}),(0,R.jsx)(`div`,{className:K.chartBox,children:(0,R.jsx)(Jv,{data:re})})]}),(0,R.jsxs)(`div`,{className:K.card,children:[(0,R.jsxs)(`div`,{className:K.panelHead,children:[(0,R.jsx)(`div`,{className:K.panelTitle,children:f(`Recent activity`)}),te.length>6&&(0,R.jsxs)(`button`,{className:K.viewAllBtn,onClick:()=>t(e=>!e),children:[e?f(`Show less`):f(`View all ({n})`).replace(`{n}`,String(te.length)),` `,(0,R.jsx)(Wm,{name:`chevronRight`,size:13})]})]}),(0,R.jsxs)(`div`,{className:K.feed,children:[te.length===0&&(0,R.jsx)(`p`,{className:K.tileSub,children:f(`nothing logged yet.`)}),(e?te:te.slice(0,6)).map((e,t)=>(0,R.jsxs)(`div`,{className:K.feedItem,children:[(0,R.jsx)(`div`,{className:`${K.feedIc} ${K[`feedIc_${e.kind}`]}`,children:(0,R.jsx)(Wm,{name:e.icon,size:13})}),(0,R.jsxs)(`div`,{className:K.feedMain,children:[(0,R.jsx)(`div`,{className:K.feedTitle,children:e.title}),(0,R.jsxs)(`div`,{className:K.feedSub,children:[e.receipt.map((e,t)=>(0,R.jsxs)(`span`,{className:K.receipt,children:[(0,R.jsx)(Wm,{name:e.icon,size:11}
65),(0,R.jsx)(`span`,{children:Uv(e.text,/\b(\d+\s*(?:commit|am|pm|:)[\w\s]*)\b/gi)})]},t)),e.badge&&(0,R.jsxs)(`span`,{className:e.badge.kind===`green`?K.badgeGreen:K.badgeRed,children:[(0,R.jsx)(`span`,{className:K.dot}),e.badge.text]})]})]}),(0,R.jsx)(`span`,{className:K.feedTime,children:e.ago})]},t))]})]})]}),(0,R.jsx)(`section`,{className:K.patternsSection,"aria-label":f(`patterns`),children:(0,R.jsx)(Vv,{})})]})})}async function Zv(e,t=null){let n=L.from(`goals`).select(`*`).eq(`user_id`,e).order(`created_at`,{ascending:!0}).limit(1);return(t?n.eq(`workspace_id`,t):n.is(`workspace_id`,null)).maybeSingle()}async function Qv(e,t,n,r=null){return L.from(`goals`).insert({user_id:e,title:t,target_date:n,workspace_id:r}).select().single()}async function $v(e){return L.from(`milestones`).select(`*`).eq(`goal_id`,e).order(`created_at`,{ascending:!0})}async function ey(e,t,n,r){return L.from(`milestones`).insert({user_id:e,goal_id:t,title:n,target_date:r}).select().single()}async function ty(e,t){return L.from(`milestones`).update({done:t}).eq(`id`,e)}async function ny(e){return L.from(`milestones`).delete().eq(`id`,e)}async function ry(e){let t={};if(e.length===0)return t;let{data:n}=await L.from(`priorities`).select(`milestone_id, status, resolution, resolved_late`).in(`milestone_id`,e);for(let e of n??[]){let n=t[e.milestone_id]??{total:0,done:0,verified:0,attested:0};n.total++,e.status===`done`&&(n.done++,e.resolution===`verified`&&!e.resolved_late?n.verified++:n.attested++),t[e.milestone_id]=n}return t}async function iy(e,t,n=40){let r=new Date(Date.now()-30*864e5).toISOString().slice(0,10),i=L.from(`priorities`).select(`id, text, date, status, resolution, resolved_late, milestone_id`).eq(`user_id`,e).gte(`date`,r).order(`date`,{ascending:!1}).limit(n);return t?i.eq(`workspace_id`,t):i}async function ay(e,t,n){return L.from(`priorities`).update({milestone_id:n}).eq(`id`,e).eq(`user_id`,t)}var q={page:`_page_1f9id_3`,twoCol:`_twoCol_1f9id_16`,statsPanel:`_statsPanel_1f9id_25`,statCard:`_statCard_1f9id_33`,statCardKicker:`_statCardKicker_1f9id_43`,statRing:`_statRing_1f9id_51`,ringTrack:`_ringTrack_1f9id_57`,ringCenter:`_ringCenter_1f9id_64`,ringPct:`_ringPct_1f9id_73`,ringCap:`_ringCap_1f9id_82`,ringMeta:`_ringMeta_1f9id_91`,ringMetaVal:`_ringMetaVal_1f9id_97`,ringMetaLabel:`_ringMetaLabel_1f9id_106`,daysBar:`_daysBar_1f9id_111`,daysBarTrack:`_daysBarTrack_1f9id_117`,daysBarFill:`_daysBarFill_1f9id_124`,daysBarLabels:`_daysBarLabels_1f9id_131`,daysBarLabel:`_daysBarLabel_1f9id_131`,crewNudge:`_crewNudge_1f9id_142`,crewNudgeLabel:`_crewNudgeLabel_1f9id_151`,crewNudgeText:`_crewNudgeText_1f9id_159`,heading:`_heading_1f9id_167`,goalHeader:`_goalHeader_1f9id_177`,goalTitle:`_goalTitle_1f9id_184`,goalMeta:`_goalMeta_1f9id_193`,goalDate:`_goalDate_1f9id_199`,goalDays:`_goalDays_1f9id_206`,ladder:`_ladder_1f9id_219`,rung:`_rung_1f9id_226`,line:`_line_1f9id_236`,lineDone:`_lineDone_1f9id_246`,node:`_node_1f9id_252`,"node-done":`_node-done_1f9id_266`,"node-progress":`_node-progress_1f9id_272`,"node-gap":`_node-gap_1f9id_277`,nodeCheck:`_nodeCheck_1f9id_282`,nodePct:`_nodePct_1f9id_287`,rungContent:`_rungContent_1f9id_301`,rungHeader:`_rungHeader_1f9id_310`,rungActions:`_rungActions_1f9id_317`,rungActionBtn:`_rungActionBtn_1f9id_330`,rungDeleteBtn:`_rungDeleteBtn_1f9id_353`,rungLabel:`_rungLabel_1f9id_358`,rungBadge:`_rungBadge_1f9id_365`,"badge-done":`_badge-done_1f9id_374`,"badge-progress":`_badge-progress_1f9id_379`,"badge-gap":`_badge-gap_1f9id_384`,rungDetail:`_rungDetail_1f9id_389`,rungProof:`_rungProof_1f9id_397`,addRow:`_addRow_1f9id_407`,addInput:`_addInput_1f9id_414`,addBtn:`_addBtn_1f9id_430`,nodeBtn:`_nodeBtn_1f9id_446`,emptyNote:`_emptyNote_1f9id_452`,createGoalForm:`_createGoalForm_1f9id_458`,pace:`_pace_1f9id_479`,paceDot:`_paceDot_1f9id_488`,paceLine:`_paceLine_1f9id_492`,paceDays:`_paceDays_1f9id_493`,backing:`_backing_1f9id_505`,gap:`_gap_1f9id_511`,gapRow:`_gapRow_1f9id_518`,gapKey:`_gapKey_1f9id_519`,gapTrack:`_gapTrack_1f9id_528`,gapWork:`_gapWork_1f9id_536`,gapTime:`_gapTime_1f9id_537`,gapVal:`_gapVal_1f9id_538`,backingBar:`_backingBar_1f9id_547`,backingVerified:`_backingVerified_1f9id_554`,backingAttested:`_backingAttested_1f9id_555`,backingCounts:`_backingCounts_1f9id_556`,backingGap:`_backingGap_1f9id_562`,evidence:`_evidence_1f9id_565`,evidenceCounts:`_evidenceCounts_1f9id_572`,evVerified:`_evVerified_1f9id_573`,evAttested:`_evAttested_1f9id_574`,evSep:`_evSep_1f9id_575`,evidenceNone:`_evidenceNone_1f9id_576`,evidenceBtn:`_evidenceBtn_1f9id_577`,attachList:`_attachList_1f9id_590`,attachRow:`_attachRow_1f9id_603`,attachPick:`_attachPick_1f9id_604`,attachPickOn:`_attachPickOn_1f9id_614`,attachText:`_attachText_1f9id_616`,attachDate:`_attachDate_1f9id_622`,attachEmpty:`_attachEmpty_1f9id_623`,attachError:`_attachError_1f9id_626`};function oy(e){return e.done?`done`:e.target_date&&e.target_date<new Date().toLocaleDateString(`en-CA`)?`gap`:`progress`}function sy(){let e=z(),{session:t,profile:n}=ll(),r=t?.user.id,{active:i,firstWorkspaceId:a}=wl(),o=i&&i.id!==a?i.id:null,[s,c]=(0,_.useState)(null),[l,u]=(0,_.useState)([]),[d,f]=(0,_.useState)(!0),[p,m]=(0,_.useState)(``),[h,g]=(0,_.useState)(``),[v,y]=(0,_.useState)({}),[b,x]=(0,_.useState)(null),[S,C]=(0,_.useState)([]),[w,T]=(0,_.useState)(``);(0,_.useEffect)(()=>{r&&(async()=>{f(!0);let{data:e}=await Zv(r,o);if(!e&&!o&&n?.goal){let{data:t}=await Qv(r,n.goal,n.goal_date??null,null);e=t??null}if(c(e),e){let{data:t}=await $v(e.id);u(t??[]),y(await ry((t??[]).map(e=>e.id)))}f(!1)})()},[r,n?.goal,n?.goal_date,o]);async function E(e){if(e.preventDefault(),!r||!h.trim())return;let{data:t}=await Qv(r,h.trim(),null,o);t&&(c(t),u([]),g(``))}async function D(){if(!r||!s||!p.trim())return;let{data:e}=await ey(r,s.id,p.trim(),null);e&&u(t=>[...t,e]),m(``)}async function O(e){await ty(e.id,!e.done),u(t=>t.map(t=>
65t.id===e.id?{...t,done:!e.done}:t))}async function k(e){await ny(e),u(t=>t.filter(t=>t.id!==e))}function A(e){e!==0&&u(t=>{let n=[...t];return[n[e-1],n[e]]=[n[e],n[e-1]],n})}function j(e){u(t=>{if(e>=t.length-1)return t;let n=[...t];return[n[e],n[e+1]]=[n[e+1],n[e]],n})}async function ee(e){if(!r)return;if(b===e){x(null);return}x(e),T(``);let{data:t,error:n}=await iy(r,o);if(n){T(n.message),C([]);return}C(t??[])}async function te(e,t){if(!r||!s)return;let{error:n}=await ay(e,r,t);if(n){T(n.message);return}T(``),C(n=>n.map(n=>n.id===e?{...n,milestone_id:t}:n));let{data:i}=await $v(s.id);u(i??[]),y(await ry((i??[]).map(e=>e.id)))}async function ne(e,t,n){if(!r||e.length===0)return;let i=new Date;t===`tomorrow`&&i.setDate(i.getDate()+1);let a=i.toLocaleDateString(`en-CA`),{error:c}=await Kd(r,a,e.map(e=>({text:e.text,category:e.category})),o);if(c)throw Error(c.message??String(c));if(n){let{data:t}=await iy(r,o),i=new Set(e.map(e=>e.text));for(let e of t??[])e.date===a&&i.has(e.text)&&!e.milestone_id&&await ay(e.id,r,n);if(s){let{data:e}=await $v(s.id);y(await ry((e??[]).map(e=>e.id)))}}}let re=s?.target_date?Math.ceil((new Date(s.target_date+`T12:00:00Z`).getTime()-Date.now())/864e5):null;if(d)return(0,R.jsxs)(`div`,{className:q.page,children:[(0,R.jsx)(`span`,{className:q.heading,children:e(`goals`)}),(0,R.jsx)(`p`,{className:q.emptyNote,children:e(`loadingâ¦`)})]});if(!s)return(0,R.jsxs)(`div`,{className:q.page,children:[(0,R.jsx)(`span`,{className:q.heading,children:e(`goals`)}),o?(0,R.jsxs)(`form`,{className:q.createGoalForm,onSubmit:E,children:[(0,R.jsx)(`p`,{className:q.emptyNote,children:e(`no goal for {name} yet.`).replace(`{name}`,i?.name??e(`this company`))}),(0,R.jsx)(`input`,{className:q.addInput,type:`text`,placeholder:e(`set your one goal for this companyâ¦`),value:h,onChange:e=>g(e.target.value),autoFocus:!0}),(0,R.jsx)(`button`,{type:`submit`,className:q.addBtn,disabled:!h.trim(),children:e(`set goal`)})]}):(0,R.jsx)(`p`,{className:q.emptyNote,children:e(`no goal set yet â finish onboarding to lock your one goal.`)})]});let M=l.filter(e=>e.done).length,N=l.length,ie=N>0?Math.round(M/N*100):0,ae=s.target_date?Math.ceil((new Date(s.target_date+`T12:00:00Z`).getTime()-new Date(s.created_at).getTime())/864e5):null,P=ae&&re!==null?Math.max(0,Math.min(100,Math.round((ae-re)/ae*100))):null,oe=l.reduce((e,t)=>{let n=v[t.id];return n?{total:e.total+n.total,done:e.done+n.done,verified:e.verified+n.verified,attested:e.attested+n.attested}:e},{total:0,done:0,verified:0,attested:0}),se=l.filter(e=>(v[e.id]?.total??0)>0).length,ce=M/Math.max(1,Math.ceil((Date.now()-new Date(s.created_at).getTime())/864e5)),le=N-M,ue=ce>0?Math.ceil(le/ce):null,de=le===0?{state:`ahead`,line:e(`Every milestone is closed.`)}:re===null?{state:`unknown`,line:e(`No target date, so there is no pace to measure.`)}:ue===null?{state:`unknown`,line:e(`Nothing closed yet, so there is no pace to measure.`)}:ue<=re*.8?{state:`ahead`,line:e(`At this rate you finish with room to spare.`)}:ue<=re?{state:`tight`,line:e(`At this rate you land almost exactly on the date.`)}:{state:`behind`,line:e(`At this rate you are {n} days late. Something has to change.`).replace(`{n}`,String(ue-re))},fe=ie===100?e(`every milestone done. what gets locked in next?`):M===0?e(`no milestones checked off yet. pick the smallest one and ship it today.`):e(`{done} of {total} done. keep the momentum, don't let the streak break here.`).replace(`{done}`,String(M)).replace(`{total}`,String(N));return(0,R.jsxs)(`div`,{className:q.page,children:[(0,R.jsx)(`span`,{className:q.heading,children:e(`goals`)}),(0,R.jsxs)(`div`,{className:q.goalHeader,children:[(0,R.jsx)(`div`,{className:q.goalTitle,children:s.title}),(0,R.jsxs)(`div`,{className:q.goalMeta,children:[s.target_date&&(0,R.jsx)(`span`,{className:q.goalDate,children:new Date(s.target_date+`T12:00:00Z`).toLocaleDateString(e(`en-US`),{month:`short`,day:`numeric`,year:`numeric`})}),re!==null&&(0,R.jsx)(`span`,{className:q.goalDays,children:e(`{n} days left`).replace(`{n}`,String(re))})]})]}),(0,R.jsxs)(`div`,{className:q.pace,"data-state":de.state,children:[(0,R.jsx)(`span`,{className:q.paceDot,"aria-hidden":!0}),(0,R.jsx)(`p`,{className:q.paceLine,children:de.line}),re!==null&&re<0&&(0,R.jsx)(`span`,{className:q.paceDays,children:e(`{n} days past the date`).replace(`{n}`,String(Math.abs(re)))})]}),(0,R.jsxs)(`div`,{className:q.twoCol,children:[(0,R.jsxs)(`div`,{children:[l.length===0?(0,R.jsx)(`p`,{className:q.emptyNote,children:e(`no milestones yet â break the goal down below.`)}):(0,R.jsx)(`div`,{className:q.ladder,children:l.map((t,n)=>{let r=oy(t),i=n===l.length-1;return(0,R.jsxs)(`div`,{className:q.rung,children:[!i&&(0,R.jsx)(`div`,{className:B(q.line,r===`done`&&q.lineDone)}),(0,R.jsx)(`button`,{type:`button`,className:B(q.node,q[`node-${r}`],q.nodeBtn),onClick:()=>O(t),"aria-label":t.done?e(`mark not done`):e(`mark done`),children:t.done?(0,R.jsx)(`svg`,{viewB
65ox:`0 0 12 12`,"aria-hidden":!0,className:q.nodeCheck,children:(0,R.jsx)(`path`,{d:`M2 6l3 3 5-5`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,fill:`none`})}):(0,R.jsx)(`span`,{className:q.nodePct})}),(0,R.jsxs)(`div`,{className:q.rungContent,children:[(0,R.jsxs)(`div`,{className:q.rungHeader,children:[(0,R.jsx)(`span`,{className:q.rungLabel,children:t.title}),(0,R.jsx)(`span`,{className:B(q.rungBadge,q[`badge-${r}`]),children:e(r===`done`?`done`:r===`gap`?`overdue`:`in progress`)}),(0,R.jsxs)(`div`,{className:q.rungActions,children:[(0,R.jsx)(`button`,{type:`button`,className:q.rungActionBtn,onClick:()=>A(n),disabled:n===0,"aria-label":e(`Move up`),title:e(`Move up`),children:`â`}),(0,R.jsx)(`button`,{type:`button`,className:q.rungActionBtn,onClick:()=>j(n),disabled:i,"aria-label":e(`Move down`),title:e(`Move down`),children:`â`}),(0,R.jsx)(`button`,{type:`button`,className:B(q.rungActionBtn,q.rungDeleteBtn),onClick:()=>k(t.id),"aria-label":e(`Delete milestone`),title:e(`delete`),children:`â`})]})]}),t.target_date&&(0,R.jsxs)(`span`,{className:q.rungProof,children:[e(`due`),` `,new Date(t.target_date+`T12:00:00Z`).toLocaleDateString(e(`en-US`),{month:`short`,day:`numeric`})]}),(0,R.jsxs)(`div`,{className:q.evidence,children:[(v[t.id]?.total??0)>0?(0,R.jsxs)(`span`,{className:q.evidenceCounts,children:[(0,R.jsx)(`span`,{className:q.evVerified,children:v[t.id].verified}),` `,e(`verified`),(0,R.jsx)(`span`,{className:q.evSep,children:`·`}),(0,R.jsx)(`span`,{className:q.evAttested,children:v[t.id].attested}),` `,e(`on your word`),(0,R.jsx)(`span`,{className:q.evSep,children:`·`}),e(`{n} committed`).replace(`{n}`,String(v[t.id].total))]}):(0,R.jsx)(`span`,{className:q.evidenceNone,children:e(`no work attached yet`)}),(0,R.jsx)(`button`,{type:`button`,className:q.evidenceBtn,onClick:()=>ee(t.id),children:b===t.id?e(`close`):e(`attach work`)}),(0,R.jsx)(eh,{scope:`milestone`,milestoneId:t.id,defaultCount:3,compact:!0,onAccept:(e,n)=>ne(e,n,t.id)})]}),b===t.id&&(0,R.jsxs)(`ul`,{className:q.attachList,children:[w&&(0,R.jsx)(`li`,{className:q.attachError,children:w}),S.length===0&&!w&&(0,R.jsx)(`li`,{className:q.attachEmpty,children:e(`no tasks in the last 30 days.`)}),[...S].sort((e,n)=>{let r=!!e.milestone_id&&e.milestone_id!==t.id,i=!!n.milestone_id&&n.milestone_id!==t.id;return Number(r)-Number(i)}).map(n=>{let r=n.milestone_id===t.id,i=!!n.milestone_id&&!r;return(0,R.jsxs)(`li`,{className:q.attachRow,children:[(0,R.jsx)(`button`,{type:`button`,className:B(q.attachPick,r&&q.attachPickOn),disabled:i,title:i?e(`already attached to another milestone`):void 0,onClick:()=>te(n.id,r?null:t.id),children:r?`â`:`+`}),(0,R.jsx)(`span`,{className:q.attachText,children:n.text}),(0,R.jsx)(`span`,{className:q.attachDate,children:n.date.slice(5)})]},n.id)})]})]})]},t.id)})}),(0,R.jsxs)(`div`,{className:q.addRow,children:[(0,R.jsx)(`input`,{className:q.addInput,type:`text`,placeholder:e(`add a milestone`),value:p,onChange:e=>m(e.target.value),onKeyDown:e=>e.key===`Enter`&&D()}),(0,R.jsx)(`button`,{type:`button`,className:q.addBtn,onClick:D,children:e(`add`)})]})]}),(0,R.jsxs)(`div`,{className:q.statsPanel,children:[oe.total>0&&(0,R.jsxs)(`div`,{className:B(q.statCard,q.backing),children:[(0,R.jsx)(`span`,{className:q.statCardKicker,children:e(`work behind this goal`)}),(0,R.jsxs)(`div`,{className:q.backingBar,role:`img`,"aria-label":e(`{v} verified, {a} on your word, of {n} committed`).replace(`{v}`,String(oe.verified)).replace(`{a}`,String(oe.attested)).replace(`{n}`,String(oe.total)),children:[(0,R.jsx)(`span`,{className:q.backingVerified,style:{width:`${oe.verified/oe.total*100}%`}}),(0,R.jsx)(`span`,{className:q.backingAttested,style:{width:`${oe.attested/oe.total*100}%`}})]}),(0,R.jsx)(`span`,{className:q.backingCounts,children:e(`{v} verified · {a} on your word · {n} committed`).replace(`{v}`,String(oe.verified)).replace(`{a}`,String(oe.attested)).replace(`{n}`,String(oe.total))}),se<N&&(0,R.jsx)(`span`,{className:q.backingGap,children:N-se===1?e(`1 milestone has no work attached yet`):e(`{n} milestones have no work attached yet`).replace(`{n}`,String(N-se))})]}),N>0&&(0,R.jsxs)(`div`,{className:q.statCard,children:[(0,R.jsx)(`span`,{className:q.statCardKicker,children:e(`completion`)}),(0,R.jsxs)(`div`,{className:q.statRing,children:[(0,R.jsxs)(`div`,{className:q.ringTrack,children:[(0,R.jsxs)(`svg`,{viewB
65ox:`0 0 72 72`,width:`72`,height:`72`,children:[(0,R.jsx)(`circle`,{cx:`36`,cy:`36`,r:`30`,fill:`none`,stroke:`var(--surface)`,strokeWidth:`6`}),(0,R.jsx)(`circle`,{cx:`36`,cy:`36`,r:`30`,fill:`none`,stroke:`var(--primary)`,strokeWidth:`6`,strokeDasharray:`${2*Math.PI*30}`,strokeDashoffset:`${2*Math.PI*30*(1-ie/100)}`,strokeLinecap:`round`,transform:`rotate(-90 36 36)`,style:{transition:`stroke-dashoffset 0.6s ease`}})]}),(0,R.jsx)(`div`,{className:q.ringCenter,children:(0,R.jsxs)(`span`,{className:q.ringPct,children:[ie,`%`]})})]}),(0,R.jsxs)(`div`,{className:q.ringMeta,children:[(0,R.jsxs)(`span`,{className:q.ringMetaVal,children:[M,` / `,N]}),(0,R.jsx)(`span`,{className:q.ringMetaLabel,children:e(`milestones done`)})]})]}),P!==null&&(0,R.jsxs)(`div`,{className:q.gap,children:[(0,R.jsxs)(`div`,{className:q.gapRow,children:[(0,R.jsx)(`span`,{className:q.gapKey,children:e(`work`)}),(0,R.jsx)(`div`,{className:q.gapTrack,children:(0,R.jsx)(`div`,{className:q.gapWork,style:{width:`${ie}%`}})}),(0,R.jsxs)(`span`,{className:q.gapVal,children:[ie,`%`]})]}),(0,R.jsxs)(`div`,{className:q.gapRow,children:[(0,R.jsx)(`span`,{className:q.gapKey,children:e(`time`)}),(0,R.jsx)(`div`,{className:q.gapTrack,children:(0,R.jsx)(`div`,{className:q.gapTime,style:{width:`${P}%`}})}),(0,R.jsxs)(`span`,{className:q.gapVal,children:[P,`%`]})]})]})]}),(0,R.jsxs)(`div`,{className:q.crewNudge,children:[(0,R.jsx)(`span`,{className:q.crewNudgeLabel,children:`crew`}),(0,R.jsx)(`p`,{className:q.crewNudgeText,children:fe})]})]})]})]})}async function cy(e){let{data:t}=await L.from(`pod_members`).select(`role, pods(id, name, invite_code, created_by, created_at)`).eq(`user_id`,e).maybeSingle();return t?{pod:t.pods??null,role:t.role}:{pod:null,role:null}}async function ly(e,t){let{data:n,error:r}=await L.rpc(`create_pod`,{p_name:e.trim(),p_workspace_id:t??null});return r||!n?{pod:null,error:r}:{pod:n,error:null}}async function uy(e){let{data:t,error:n}=await L.rpc(`join_pod`,{p_invite_code:e.trim().toUpperCase()});return n||!t?{pod:null,error:Error(n?.message??`pod not found â check the code`)}:{pod:t,error:null}}async function dy(e,t){return L.from(`pod_members`).delete().eq(`pod_id`,e).eq(`user_id`,t)}async function fy(e){let{data:t,error:n}=await L.functions.invoke(`pod-board`,{body:{podId:e}});return n?{board:null,podStreak:0,podSize:0,error:n.message}:{board:t?.board??null,podStreak:Number(t?.pod_streak??0),podSize:Number(t?.pod_size??0),error:null}}async function py(e){let{data:t}=await L.from(`pod_members`).select(`pod_id`).eq(`user_id`,e).maybeSingle();if(!t?.pod_id)return null;let{data:n}=await L.from(`pod_members`).select(`user_id`).eq(`pod_id`,t.pod_id).neq(`user_id`,e),r=(n??[])[0];if(!r)return null;let{data:i}=await L.from(`profiles`).select(`name`).eq(`id`,r.user_id).maybeSingle();return{pod_id:t.pod_id,user_id:r.user_id,name:i?.name??`your pod partner`}}function my(e=new Date){return`${e.getFullYear()}-${String(e.getMonth()+1).padStart(2,`0`)}`}function hy(e=new Date){return`${e.getFullYear()}-Q${Math.floor(e.getMonth()/3)+1}`}async function gy(e,t=new Date){let n=my(t),r=hy(t),{data:i}=await L.from(`streak_recoveries`).select(`kind, period_key, created_at`).eq(`user_id`,e).in(`period_key`,[n,r]),a=i??[],o=a.find(e=>e.kind===`double_day`&&e.period_key===n);return{doubleDayUsed:!!o,podVouchUsed:a.some(e=>e.kind===`pod_vouch`&&e.period_key===r),doubleDayBookedAt:o?.created_at??null,monthKey:n,quarterKey:r}}async function _y(e,t=new Date){let{error:n}=await L.from(`streak_recoveries`).insert({user_id:e,kind:`double_day`,period_key:my(t)});return{error:n?Error(n.message):null}}async function vy(e,t,n,r=new Date){let{error:i}=await L.from(`streak_recoveries`).insert({user_id:e,kind:`pod_vouch`,period_key:hy(r),voucher_user_id:t,voucher_name:n});return{error:i?Error(i.message):null}}async function yy(e){let{data:{session:t}}=await L.auth.getSession();if(!t)return{reply:`not signed in.`};let{data:n,error:r}=await L.functions.invoke(`crew-chat`,{body:e});return r?(console.error(`crew-chat error`,r),{reply:`hit a snag. try again.`}):{reply:n.reply??`no response.`}}var by={backdrop:`_backdrop_1tdt0_1`,panel:`_panel_1tdt0_8`,open:`_open_1tdt0_25`,header:`_header_1tdt0_35`,headerLeft:`_headerLeft_1tdt0_44`,statusDot:`_statusDot_1tdt0_50`,"status-done":`_status-done_1tdt0_57`,"status-skipped":`_status-skipped_1tdt0_58`,date:`_date_1tdt0_60`,close:`_close_1tdt0_68`,body:`_body_1tdt0_88`,task:`_task_1tdt0_97`,meta:`_meta_1tdt0_107`,catBadge:`_catBadge_1tdt0_113`,"cat-build":`_cat-build_1tdt0_124`,"cat-sales":`_cat-sales_1tdt0_125`,"cat-ops":`_cat-ops_1tdt0_126`,statusBadge:`_statusBadge_1tdt0_128`,"status-badge-done":`_status-badge-done_1tdt0_139`,"status-badge-skipped":`_status-badge-skipped_1tdt0_140`,divi
65der:`_divider_1tdt0_142`,receipt:`_receipt_1tdt0_149`,receiptLabel:`_receiptLabel_1tdt0_155`,receiptItems:`_receiptItems_1tdt0_163`,receiptRow:`_receiptRow_1tdt0_173`,receiptIcon:`_receiptIcon_1tdt0_179`,receiptIconRed:`_receiptIconRed_1tdt0_184`,receiptText:`_receiptText_1tdt0_189`,receiptNote:`_receiptNote_1tdt0_195`,noReceipt:`_noReceipt_1tdt0_202`,skippedBody:`_skippedBody_1tdt0_208`,skippedRow:`_skippedRow_1tdt0_218`,skippedText:`_skippedText_1tdt0_224`},xy={build:`build`,sales:`sales`,ops:`ops`};function Sy({item:e,onClose:t}){let n=z();return(0,_.useEffect)(()=>{if(!e)return;let n=e=>{e.key===`Escape`&&t()};return document.addEventListener(`keydown`,n),()=>document.removeEventListener(`keydown`,n)},[e,t]),(0,R.jsxs)(R.Fragment,{children:[e&&(0,R.jsx)(`div`,{className:by.backdrop,onClick:t,"aria-hidden":!0}),(0,R.jsx)(`div`,{className:B(by.panel,e&&by.open),role:`dialog`,"aria-modal":!0,"aria-label":n(`Task receipt`),children:e&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsxs)(`div`,{className:by.header,children:[(0,R.jsxs)(`div`,{className:by.headerLeft,children:[(0,R.jsx)(`span`,{className:B(by.statusDot,by[`status-${e.status}`]),"aria-hidden":!0}),(0,R.jsx)(`span`,{className:by.date,children:Ey(e.date)})]}),(0,R.jsx)(`button`,{className:by.close,onClick:t,"aria-label":n(`close`),children:(0,R.jsx)(Wm,{name:`x`,size:15})})]}),(0,R.jsxs)(`div`,{className:by.body,children:[(0,R.jsx)(`h2`,{className:by.task,children:e.task}),(0,R.jsxs)(`div`,{className:by.meta,children:[(0,R.jsx)(`span`,{className:B(by.catBadge,by[`cat-${e.category}`]),children:xy[e.category]}),(0,R.jsx)(`span`,{className:B(by.statusBadge,by[`status-badge-${e.status}`]),children:e.status===`done`?`â ${n(`done`)}`:`â ${n(`skipped`)}`})]}),(0,R.jsx)(`div`,{className:by.divider}),e.status===`done`?(0,R.jsx)(Cy,{proof:e.proof}):(0,R.jsx)(wy,{task:e.task,date:e.date})]})]})})]})}function Cy({proof:e}){let t=z(),n=e?e.split(` · `):[];return(0,R.jsxs)(`div`,{className:by.receipt,children:[(0,R.jsx)(`span`,{className:by.receiptLabel,children:t(`receipt`)}),n.length>0?(0,R.jsx)(`div`,{className:by.receiptItems,children:n.map((e,t)=>(0,R.jsxs)(`div`,{className:by.receiptRow,children:[(0,R.jsx)(Wm,{name:Ty(e),size:13,className:by.receiptIcon}),(0,R.jsx)(`span`,{className:by.receiptText,children:e})]},t))}):(0,R.jsx)(`p`,{className:by.noReceipt,children:t(`no receipt attached`)}),(0,R.jsx)(`div`,{className:by.receiptNote,children:t(`real-time receipts from GitHub + calendar once integrations are connected`)})]})}function wy({task:e,date:t}){let n=z();return(0,R.jsxs)(`div`,{className:by.receipt,children:[(0,R.jsx)(`span`,{className:by.receiptLabel,children:n(`why this matters`)}),(0,R.jsxs)(`div`,{className:by.skippedBody,children:[(0,R.jsxs)(`div`,{className:by.skippedRow,children:[(0,R.jsx)(Wm,{name:`skipForward`,size:13,className:by.receiptIconRed}),(0,R.jsxs)(`span`,{className:by.skippedText,children:[n(`rolled on`),` `,Ey(t)]})]}),(0,R.jsxs)(`div`,{className:by.skippedRow,children:[(0,R.jsx)(Wm,{name:`slash`,size:13,className:by.receiptIconRed}),(0,R.jsxs)(`span`,{className:by.skippedText,children:[`« `,e,` » `,n(`is an avoidance pattern`)]})]})]}),(0,R.jsx)(`div`,{className:by.receiptNote,children:n(`tasks skipped 3+ times in a row are flagged as drift â crew will ask about this`)})]})}function Ty(e){return/commit|push/i.test(e)?`gitCommit`:/deploy|ship/i.test(e)?`deploy`:/sent|email|reply/i.test(e)?`zap`:/pm|am/i.test(e)?`clock`:`check`}function Ey(e){return new Date(e+`T12:00:00Z`).toLocaleDateString(`en-US`,{month:`short`,day:`numeric`,timeZone:`UTC`})}var J={page:`_page_o261p_3`,heading:`_heading_o261p_14`,period:`_period_o261p_24`,periodLabel:`_periodLabel_o261p_31`,periodBadge:`_periodBadge_o261p_39`,weekBar:`_weekBar_o261p_58`,weekBarFill:`_weekBarFill_o261p_65`,shareBtn:`_shareBtn_o261p_77`,sharePanel:`_sharePanel_o261p_92`,shareUrl:`_shareUrl_o261p_102`,shareCopyBtn:`_shareCopyBtn_o261p_112`,shareDismiss:`_shareDismiss_o261p_128`,body:`_body_o261p_145`,lists:`_lists_o261p_153`,section:`_section_o261p_159`,sectionHead:`_sectionHead_o261p_165`,sectionDot:`_sectionDot_o261p_178`,taskList:`_taskList_o261p_189`,taskItem:`_taskItem_o261p_198`,taskText:`_taskText_o261p_214`,emptyNote:`_emptyNote_o261p_222`,taskProof:`_taskProof_o261p_229`,taskCat:`_taskCat_o261p_236`,dateGroups:`_dateGroups_o261p_249`,dateGroup:`_dateGroup_o261p_249`,dateGroupLabel:`_dateGroupLabel_o261p_261`,taskItemRow:`_taskItemRow_o261p_269`,retroTrigger:`_retroTrigger_o261p_276`,retroOverlay:`_retroOverlay_o261p_294`,retroModal:`_retroModal_o261p_305`,retroDate:`_retroDate_o261p_318`,retroTask:`_retroTask_o261p_326`,retroNote:`_retroNote_o261p_334`,retroInput:`_retroInput_o261p_341`,retroActions:`_retroActions_o261p_353`,retroConfirm:`_retroConfirm_o261p_359`,retroCancel:`_retroCancel_o261p_373`,right:`_right_o261p_385`,crewCard:`_crewCard_o261p_393`,crewKicker:`_crewKicker_o261p_402`,crewText:`_crewText_o261p_410`,nextCard:`_nextCard_o261p_419`,nextKicker:`_nextKicker_o261p_429`,nextText:`_nextText_o261p_437`,insightsCard:`_insightsCard_o261p_447`,askCard:`_askCard_o261p_447`,insightList:`_insightList_o261p_458`,insightItem:`_insightItem_o261p_459`,askThread:`_askThread_o261p_478`,askMsgUser:`_askMsgUser_o261p_479`,askMsgCrew:`_askMsgCrew_o261p_484`,askChips:`_askChips_o261p_490`,askChip:`_askChip_o261
65p_490`,askRow:`_askRow_o261p_499`,askInput:`_askInput_o261p_500`,askSend:`_askSend_o261p_506`,historyCard:`_historyCard_o261p_514`,historyKicker:`_historyKicker_o261p_524`,historyBars:`_historyBars_o261p_532`,historyBar:`_historyBar_o261p_532`,historyTrack:`_historyTrack_o261p_548`,historyFill:`_historyFill_o261p_558`,historyPct:`_historyPct_o261p_565`,statement:`_statement_o261p_594`,statementLead:`_statementLead_o261p_604`,mirror:`_mirror_o261p_616`,mirrorRow:`_mirrorRow_o261p_618`,mirrorCat:`_mirrorCat_o261p_625`,mirrorTrack:`_mirrorTrack_o261p_633`,mirrorVerified:`_mirrorVerified_o261p_640`,mirrorAttested:`_mirrorAttested_o261p_643`,mirrorCount:`_mirrorCount_o261p_645`,statNums:`_statNums_o261p_653`,statNum:`_statNum_o261p_653`,statVal:`_statVal_o261p_661`,statKey:`_statKey_o261p_669`,statNote:`_statNote_o261p_674`,ledger:`_ledger_o261p_679`,ledgerHead:`_ledgerHead_o261p_686`,ledgerTitle:`_ledgerTitle_o261p_694`,trend:`_trend_o261p_704`,trendBar:`_trendBar_o261p_705`,ledgerDay:`_ledgerDay_o261p_708`,ledgerDate:`_ledgerDate_o261p_711`,ledgerRows:`_ledgerRows_o261p_721`,ledgerRow:`_ledgerRow_o261p_721`,ledgerMark:`_ledgerMark_o261p_732`,ledgerText:`_ledgerText_o261p_741`,ledgerCat:`_ledgerCat_o261p_757`,ledgerState:`_ledgerState_o261p_758`,readout:`_readout_o261p_769`,readList:`_readList_o261p_776`,readItem:`_readItem_o261p_777`,readNext:`_readNext_o261p_778`,deep:`_deep_o261p_784`,deepHead:`_deepHead_o261p_794`,deepTitle:`_deepTitle_o261p_800`,deepWhen:`_deepWhen_o261p_807`,deepBody:`_deepBody_o261p_809`,deepHeadline:`_deepHeadline_o261p_813`,deepBlock:`_deepBlock_o261p_825`,deepLabel:`_deepLabel_o261p_827`,deepList:`_deepList_o261p_835`,deepItem:`_deepItem_o261p_836`,deepText:`_deepText_o261p_854`,deepCall:`_deepCall_o261p_858`,deepCallText:`_deepCallText_o261p_865`,deepBtn:`_deepBtn_o261p_874`,readLine:`_readLine_o261p_891`};function Dy(){let e=z(),{session:t}=ll(),n=t?.user.id,[r,i]=(0,_.useState)(null),[a,o]=(0,_.useState)(null),[s,c]=(0,_.useState)(!1),[l,u]=(0,_.useState)(!1);(0,_.useEffect)(()=>{n&&Dh(n).then(e=>{e&&(i(e.content),o(e.created_at))})},[n]);async function d(){c(!0);let{content:e,upgrade:t}=await Eh();if(c(!1),t){u(!0),$l(`review_upgrade_prompt`,{});return}e&&(i(e),o(new Date().toISOString()),$l(`review_generated`,{period:`weekly`}))}let f=a?new Date(a).toLocaleDateString(void 0,{month:`short`,day:`numeric`}):null;return(0,R.jsxs)(`section`,{className:J.deep,"aria-label":e(`Deep 1:1`),children:[(0,R.jsxs)(`div`,{className:J.deepHead,children:[(0,R.jsx)(`span`,{className:J.deepTitle,children:e(`Deep 1:1`)}),f&&(0,R.jsx)(`span`,{className:J.deepWhen,children:e(`written {d}`).replace(`{d}`,f)})]}),r?(0,R.jsxs)(`div`,{className:J.deepBody,children:[(0,R.jsx)(`p`,{className:J.deepHeadline,children:r.headline}),r.wins?.length>0&&(0,R.jsxs)(`div`,{className:J.deepBlock,children:[(0,R.jsx)(`span`,{className:J.deepLabel,children:e(`What held`)}),(0,R.jsx)(`ul`,{className:J.deepList,children:r.wins.map((e,t)=>(0,R.jsx)(`li`,{className:J.deepItem,children:e},t))})]}),r.avoidance&&(0,R.jsxs)(`div`,{className:J.deepBlock,children:[(0,R.jsx)(`span`,{className:J.deepLabel,children:e(`What you're steering around`)}),(0,R.jsx)(`p`,{className:J.deepText,children:r.avoidance})]}),r.next_call&&(0,R.jsxs)(`div`,{className:J.deepCall,children:[(0,R.jsx)(`span`,{className:J.deepLabel,children:e(`The call`)}),(0,R.jsx)(`p`,{className:J.deepCallText,children:r.next_call})]})]}):l?(0,R.jsx)(`p`,{className:J.deepText,children:e(`The Deep 1:1 comes with the Founder plan. It is a written read on your week: what held, what you are steering around, and one call for next week. Change your plan in settings.`)}):(0,R.jsx)(`p`,{className:J.deepText,children:e(`Your first one is written on Sunday, with the week. You can also ask for it now.`)}),!l&&(0,R.jsx)(`button`,{className:J.deepBtn,onClick:d,disabled:s,children:e(s?`Reading your weekâ¦`:r?`Write it again`:`Write it now`)})]})}function Oy(e){return new Date(e+`T12:00:00Z`).toLocaleDateString(`en-US`,{month:`short`,day:`numeric`,timeZone:`UTC`})}function ky(e,t){let n=new Date(e+`T12:00:00Z`);return n.setUTCDate(n.getUTCDate()+t),n.toISOString().slice(0,10)}function Ay({item:e,backfillWindow:t,onClose:n,onDone:r}){let i=z(),a=tg(e.date,new Date,t),[o,s]=(0,_.useState)(a?`checking`:`closed`),[c,l]=(0,_.useState)(``),[u,d]=(0,_.useState)(``),[f,p]=(0,_.useState)(``),[m,h]=(0,_.useState)(!1);(0,_.useEffect)(()=>
65{if(!a){s(`closed`);return}s(`checking`);let t=!1;return Ch(e.text,e.category,e.id,e.date).then(e=>{t||(e.verified?(l(e.app),d(e.evidence),s(`verified`)):s(`manual`))}).catch(()=>{t||s(`manual`)}),()=>{t=!0}},[e,a]);async function g(){e.id&&(h(!0),await Jd(e.id,`done`,`verified: ${u}`),h(!1),r())}async function v(){!e.id||!f.trim()||(h(!0),await Jd(e.id,`done`,f.trim()),h(!1),r())}return(0,R.jsx)(`div`,{className:J.retroOverlay,role:`dialog`,"aria-modal":`true`,onClick:n,children:(0,R.jsxs)(`div`,{className:J.retroModal,onClick:e=>e.stopPropagation(),children:[(0,R.jsx)(`span`,{className:J.retroDate,children:Oy(e.date)}),(0,R.jsx)(`p`,{className:J.retroTask,children:e.text}),o===`checking`&&(0,R.jsx)(`p`,{className:J.retroNote,children:i(`checking your connected toolsâ¦`)}),o===`closed`&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`p`,{className:J.retroNote,children:i(`This day is closed. A task can be backfilled up to noon the next day; after that the day stands as it is.`)}),(0,R.jsx)(`div`,{className:J.retroActions,children:(0,R.jsx)(`button`,{className:J.retroCancel,onClick:n,children:i(`close`)})})]}),o===`verified`&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`p`,{className:J.retroNote,children:i(`Found a match in {app}: {evidence}`).replace(`{app}`,c).replace(`{evidence}`,u)}),(0,R.jsxs)(`div`,{className:J.retroActions,children:[(0,R.jsx)(`button`,{className:J.retroConfirm,onClick:g,disabled:m,children:i(m?`markingâ¦`:`mark done`)}),(0,R.jsx)(`button`,{className:J.retroCancel,onClick:n,children:i(`cancel`)})]})]}),o===`manual`&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`p`,{className:J.retroNote,children:i(`Nothing matched automatically. What is the proof this happened?`)}),(0,R.jsx)(`textarea`,{className:J.retroInput,placeholder:i(`e.g. sent 12 emails via Gmail that day (screenshot on file)`),value:f,onChange:e=>p(e.target.value),rows:3}),(0,R.jsxs)(`div`,{className:J.retroActions,children:[(0,R.jsx)(`button`,{className:J.retroConfirm,onClick:v,disabled:m||!f.trim(),children:i(m?`markingâ¦`:`mark done`)}),(0,R.jsx)(`button`,{className:J.retroCancel,onClick:n,children:i(`cancel`)})]})]})]})})}function jy(){let e=z(),{lang:t}=ml(),{session:n,profile:r}=ll(),{active:i,firstWorkspaceId:a}=wl(),o=!!i&&i.id===a,{entries:s,loading:c,refresh:l}=nf(n?.user.id,i?.id,o),{cfg:u}=xh(n?.user.id);Fg(n?.user.id,s,r?.name,r?.product_name);let[d,f]=(0,_.useState)(null),[p,m]=(0,_.useState)(!1),[h,g]=(0,_.useState)(null),[v,y]=(0,_.useState)(null);(0,_.useEffect)(()=>{let e=n?.user.id;if(!e)return;let t=!1;return gy(e).then(e=>{t||y(e.doubleDayBookedAt?{bookedAt:e.doubleDayBookedAt}:null)}).catch(()=>{t||y(null)}),()=>{t=!0}},[n?.user.id]);let b=(0,_.useMemo)(()=>{let e=lg(s);if(e.length===0)return null;let t=e[e.length-1].weekStart,n=ky(t,6),r=s.filter(e=>e.date>=t&&e.date<=n),i=rf(),a=r.flatMap(e=>e.priorities.filter(e=>e.status===`done`).map(t=>({...t,date:e.date}))),o=Vh(s),c=r.flatMap(e=>e.priorities.filter(t=>Ih(t.status,e.date,i)&&!(t.id&&o.has(t.id))).map(t=>({...t,date:e.date}))),l=r.flatMap(e=>e.priorities.filter(e=>e.id&&o.has(e.id)).map(t=>({...t,date:e.date}))),u=r.flatMap(e=>e.priorities.filter(t=>{let n=Fh(t.status,e.date,i);return n===`pending_today`||n===`upcoming`}).map(t=>({...t,date:e.date}))),d=e=>e.filter(e=>!(e.id&&o.has(e.id))),f=r.reduce((e,t)=>e+d(t.priorities).filter(e=>e.status===`done`).length,0),p=r.reduce((e,t)=>e+d(t.priorities).length,0),m=p>0?Math.round(f/p*100):0,{adherence:h,output:g,committedDone:_}=zh(s,t),v=c.filter(e=>e.category===`sales`).length,y=e.length>=2?Math.round(e[e.length-2].pct*100):null,b=y===null?null:m-y,x={};for(let e of c)x[e.category]=(x[e.category]??0)+1;let S=Object.entries(x).sort((e,t)=>t[1]-e[1])[0]??null,C={};for(let e of a)C[e.category]=(C[e.category]??0)+1;let w=Object.entries(C).sort((e,t)=>t[1]-e[1])[0]??null,T=r.filter(e=>e.priorities.length>0).length,E=[`build`,`sales`,`ops`].map(e=>{let t=r.flatMap(t=>d(t.priorities).filter(t=>t.category===e)),n=t.filter(e=>e.resolution===`verified`&&!e.resolvedLate).length,i=t.filter(e=>e.resolution===`attested`||e.resolution===`verified`&&e.resolvedLate).length;return{cat:e,total:t.length,done:t.filter(e=>e.status===`done`).length,verified:n,attested:i}}).filter(e=>e.total>0),D=(e,t)=>{if(e.id&&o.has(e.id))return`carried`;if(e.status===`done`)return e.resolution===`verified`&&!e.resolvedLate?`verified`:`attested`;let n=Fh(e.status,t,i);
65return n===`pending_today`||n===`upcoming`?`open`:`missed`};return{ledger:r.filter(e=>e.priorities.length>0).map(e=>({date:e.date,items:e.priorities.map(t=>({...t,date:e.date,state:D(t,e.date)}))})).sort((e,t)=>e.date.localeCompare(t.date)),mirror:E,periodStart:t,periodEnd:n,shipped:a,slipped:c,carried:l,inProgress:u,weekDone:f,weekTotal:p,weekPct:m,adherence:h,output:g,committedDone:_,salesSlipped:v,prevPct:y,wowDelta:b,topShip:w,topSlip:S,activeDays:T,history:e.slice(-4)}},[s]),[x,S]=(0,_.useState)([]),[C,w]=(0,_.useState)(``),[T,E]=(0,_.useState)(!1),D=(0,_.useRef)(null);(0,_.useEffect)(()=>{D.current?.scrollIntoView({behavior:`smooth`})},[x,T]);async function O(e){let t=e.trim();if(!t||T||!b)return;let n=x.map(e=>({role:e.from,text:e.text}));S(e=>[...e,{from:`user`,text:t}]),w(``),E(!0);let r=``;try{r=localStorage.getItem(`crew.businessContext`)??``}catch{}let i=fg(s,u,r),{reply:a}=await yy({userMessage:`(About my week ${b.periodStart} to ${b.periodEnd}) ${t}`,history:n,useHaiku:!1,context:i});S(e=>[...e,{from:`crew`,text:a}]),E(!1)}let k=b?{kind:`weekly`,name:r?.name??`Founder`,product:r?.product_name??``,week_start:b.periodStart,week_end:ky(b.periodStart,6),completion_pct:b.weekPct,streak:Xh(s,u),shipped:b.shipped.map(e=>e.text),missed:b.slipped.map(e=>e.text)}:null;if(c)return(0,R.jsx)(`div`,{className:J.page,children:(0,R.jsx)(`span`,{className:J.heading,children:e(`weekly review`)})});if(!b)return(0,R.jsxs)(`div`,{className:J.page,children:[(0,R.jsx)(`span`,{className:J.heading,children:e(`weekly review`)}),(0,R.jsx)(`p`,{className:J.emptyNote,children:e(`no weeks to review yet â lock a few days on the Today page first.`)})]});let{ledger:A,mirror:j,periodStart:ee,periodEnd:te,weekDone:ne,weekTotal:re,weekPct:M,adherence:N,output:ie,committedDone:ae,salesSlipped:P,prevPct:oe,wowDelta:se,topShip:ce,topSlip:le,activeDays:ue,history:de}=b,fe=P===1?e(`{n} time`).replace(`{n}`,`1`):e(`{n} times`).replace(`{n}`,String(P)),pe=re===0?e(`Nothing locked this week, so there is nothing to review yet.`):P>0?e(`{pct}% this week. Sales went untouched {times} days in 7, and that gap is widening.`).replace(`{pct}`,String(M)).replace(`{times}`,fe):e(`{pct}% this week, solid across the board.`).replace(`{pct}`,String(M)),me=e(P>0?`Next week: put the leads first, not last. Send the emails before you open any code.`:`Next week: keep the same order. Whatever you did, repeat it.`),he=[];if(se!==null&&oe!==null&&he.push(se>0?e(`Up {d} points on last week, {prev}% to {cur}%.`).replace(`{d}`,String(se)).replace(`{prev}`,String(oe)).replace(`{cur}`,String(M)):se<0?e(`Down {d} points on last week, {prev}% to {cur}%. What changed?`).replace(`{d}`,String(Math.abs(se))).replace(`{prev}`,String(oe)).replace(`{cur}`,String(M)):e(`Flat on last week at {cur}%. Steady, no gain.`).replace(`{cur}`,String(M))),ce&&he.push(e(`{cat} is the engine. {n} shipped this week.`).replace(`{cat}`,e(ce[0])).replace(`{n}`,String(ce[1]))),le&&he.push(e(`{cat} is where it leaks. {n} slipped, and that is the one to fix.`).replace(`{cat}`,e(le[0])).replace(`{n}`,String(le[1]))),ue>0&&ue<5){let t=ue===1?e(`{n} active day`).replace(`{n}`,`1`):e(`{n} active days`).replace(`{n}`,String(ue));he.push(e(`Only {days} this week. Consistency beats intensity.`).replace(`{days}`,t))}ie>ae&&N<60&&he.push(e(`Plenty got done, just not what you planned.`)),he.length===0&&re>0&&he.push(e(`{done} of {total} done. Lock more days and the patterns show up.`).replace(`{done}`,String(ne)).replace(`{total}`,String(re)));let ge=[e(`where did I leak time this week?`),e(`what should I change next week?`),e(`am I improving?`)];return(0,R.jsxs)(`div`,{className:J.page,children:[(0,R.jsx)(`span`,{className:J.heading,children:e(`weekly review`)}),re>0&&(0,R.jsxs)(`section`,{className:J.statement,"aria-label":e(`where the week went`),children:[(0,R.jsx)(`p`,{className:J.statementLead,children:pe}),(0,R.jsx)(`div`,{className:J.mirror,children:j.map(t=>(0,R.jsxs)(`div`,{className:J.mirrorRow,children:[(0,R.jsx)(`span`,{className:J.mirrorCat,children:e(t.cat)}
65),(0,R.jsxs)(`span`,{className:J.mirrorTrack,"aria-hidden":!0,children:[(0,R.jsx)(`span`,{className:J.mirrorVerified,style:{width:`${t.verified/t.total*100}%`}}),(0,R.jsx)(`span`,{className:J.mirrorAttested,style:{width:`${t.attested/t.total*100}%`}})]}),(0,R.jsx)(`span`,{className:J.mirrorCount,children:e(`{d} of {n}`).replace(`{d}`,String(t.done)).replace(`{n}`,String(t.total))})]},t.cat))}),(0,R.jsxs)(`div`,{className:J.statNums,children:[(0,R.jsxs)(`div`,{className:J.statNum,children:[(0,R.jsxs)(`span`,{className:J.statVal,children:[N,`%`]}),(0,R.jsx)(`span`,{className:J.statKey,children:e(`adherence`)}),(0,R.jsx)(`span`,{className:J.statNote,children:e(`of what you committed to`)})]}),(0,R.jsxs)(`div`,{className:J.statNum,children:[(0,R.jsx)(`span`,{className:J.statVal,children:ie}),(0,R.jsx)(`span`,{className:J.statKey,children:e(`output`)}),(0,R.jsx)(`span`,{className:J.statNote,children:e(`finished, planned or not`)})]}),(0,R.jsxs)(`div`,{className:J.statNum,children:[(0,R.jsxs)(`span`,{className:J.statVal,children:[M,`%`]}),(0,R.jsx)(`span`,{className:J.statKey,children:e(`of the list`)}),(0,R.jsx)(`span`,{className:J.statNote,children:e(`{d} of {n} locked tasks`).replace(`{d}`,String(ne)).replace(`{n}`,String(re))})]})]})]}),(0,R.jsxs)(`div`,{className:J.period,children:[(0,R.jsxs)(`span`,{className:J.periodLabel,children:[Oy(ee),` â `,Oy(te)]}),(0,R.jsx)(`button`,{className:J.shareBtn,onClick:()=>m(!0),children:e(`share week â`)})]}),(0,R.jsx)(`div`,{className:J.weekBar,role:`progressbar`,"aria-valuenow":M,"aria-valuemin":0,"aria-valuemax":100,"aria-label":e(`week completion`),children:(0,R.jsx)(`div`,{className:J.weekBarFill,style:{width:`${M}%`},"data-strong":M>=67?`true`:`false`})}),p&&k&&(0,R.jsx)(Iv,{card:k,userId:n?.user.id,xLine:e(`{pct}% of my locked priorities done this week building {prod} â tracked on Crew.`).replace(`{pct}`,String(k.completion_pct)).replace(`{prod}`,k.product||`my startup`),filename:`crew-week-${b.periodStart}`,onClose:()=>m(!1)}),(0,R.jsx)(zv,{pct:M,period:`weekly`,userId:n?.user.id,name:r?.name,product:r?.product_name}),(0,R.jsxs)(`section`,{className:J.ledger,"aria-label":e(`the week`),children:[(0,R.jsxs)(`div`,{className:J.ledgerHead,children:[(0,R.jsx)(`span`,{className:J.ledgerTitle,children:e(`the week`)}),de.length>1&&(0,R.jsx)(`span`,{className:J.trend,title:e(`4-week trend`),children:de.map(e=>(0,R.jsx)(`span`,{className:J.trendBar,style:{height:`${Math.max(3,Math.round(e.pct*100)*.2)}px`}},e.weekStart))})]}),A.length===0?(0,R.jsx)(`p`,{className:J.emptyNote,children:e(`nothing locked this week.`)}):A.map(t=>(0,R.jsxs)(`div`,{className:J.ledgerDay,children:[(0,R.jsx)(`span`,{className:J.ledgerDate,children:Oy(t.date)}),(0,R.jsx)(`ul`,{className:J.ledgerRows,children:t.items.map((t,n)=>(0,R.jsxs)(`li`,{className:J.ledgerRow,children:[(0,R.jsx)(`span`,{className:J.ledgerMark,"data-state":t.state,"aria-hidden":!0}),(0,R.jsx)(`button`,{type:`button`,className:J.ledgerText,onClick:()=>f({task:t.text,category:t.category,status:t.status,proof:t.proof,date:t.date}),"aria-label":e(`View receipt for {task}`).replace(`{task}`,t.text),children:t.text}),(0,R.jsx)(`span`,{className:J.ledgerCat,children:e(t.category)}),(0,R.jsx)(`span`,{className:J.ledgerState,"data-state":t.state,children:e(t.state)}),t.state===`missed`&&t.id&&(0,R.jsx)(`button`,{type:`button`,className:J.retroTrigger,onClick:()=>g(t),title:e(`actually got this done? mark it done with proof`),children:e(`mark done`)})]},n))})]},t.date))]}),(he.length>0||re>0)&&(0,R.jsxs)(`section`,{className:J.readout,"aria-label":e(`crew's read`),children:[he.length>0&&(0,R.jsx)(`ul`,{className:J.readList,children:he.map((e,t)=>(0,R.jsx)(`li`,{className:J.readItem,children:e},t))}),(0,R.jsx)(`p`,{className:J.readNext,children:me}),(0,R.jsx)(`p`,{className:J.readLine,children:Pv(ee,t)})]}),(0,R.jsx)(Dy,{}),(0,R.jsxs)(`div`,{className:J.askCard,children:[(0,R.jsx)(`span`,{className:J.crewKicker,children:e(`ask crew about this week`)}),x.length>0&&(0,R.jsxs)(`div`,{className:J.askThread,children:[x.map((e,t)=>(0,R.jsx)(`div`,{className:e.from===`user`?J.askMsgUser:J.askMsgCrew,children:e.text},t)),T&&(0,R.jsx)(`div`,{className:J.askMsgCrew,children:e(`thinkingâ¦`)}),(0,R.jsx)(`div`,{ref:D})]}),x.length===0&&(0,R.jsx)(`div`,{className:J.askChips,children:ge.map(e=>(0,R.jsx)(`button`,{className:J.askChip,onClick:()=>O(e),disabled:T,children:e},e))}),(0,R.jsxs)(`div`,{className:J.askRow,children:[(0,R.jsx)(`input`,{className:J.askInput,type:`text`,placeholder:e(`ask anything about this weekâ¦`),value:C,onChange:e=>w(e.target.value),onKeyDown:e=>{e.key===`Enter`&&O(C)},disabled:T}),(0,R.jsx)(`button`,{className:J.askSend,onClick:()=>O(C),disabled:T||!C.trim(),"aria-label":e(`Ask`),children:`â`})]})]}),(0,R.jsx)(Sy,{item:d,onClose:()=>f(null)}),h&&(0,R.jsx)(Ay,{item:h,backfillWindow:v,onClose:()=>g(null),onDone:()=>{g(null),l()}})]})}var My={card:`_card_79l8q_4`,head:`_head_79l8q_14`,kicker:`_kicker_79l8q_22`,readout:`_readout_79l8q_32`,plot:`_plot_79l8q_39`,col:`_col_79l8q_46`,stack:`_stack_79l8q_60`,verified:`_verified_79l8q_69`,attested:`_attested_79l8q_73`,missed:`_missed_79l8q_74`,none:`_none_79l8q_78`,rest:`_rest_79l8q_86`,legend:`_legend_79l8q_95`,legendItem:`_legendItem_79l8q_101`,dot:`_dot_79l8q_109`,restDot:`_restDot_79l8q_115`,empty:`_empty_79l8q_119`};function Ny({entries:e,restCfg:t,days:n=60}){let r=z(),[i,a]=(0,_.useState)(null),o=(0,_.useMemo)(()=>{let r=new Map(e.map(e=>[e.date,e])),i=e.length>0?e[0].date:null,a=i?Math.ceil((Date.now()-new Date(i+`T12:00:00Z`).getTime())/864e5)+1:n,o=Math.max(14,Math.min(n,a)),s=[],c=new Date;for(let e=o-1;e>=0;e--){let n=new Date(c);n.setDate(n.getDate()-e);let i=n.toLocaleDateString(`en-CA`),a=r.get(i)?.priorities??[],o=0,l=0,u=0;for(let e of a)e.resolution===`verified`&&!e.resolvedLate?o++:e.resolution===`attested`||e.resolution===`verified`&&e.resolvedLate?l++:e.resolution===`missed`&&u++;s.push({date:i,verified:o,attested:l,missed:u,total:o+l+u,rest:Jh(i,t),empty:a.length===0})}return s},[e,t,n]),s=Math.max(1,...o.map(e=>e.total)),c=o.length,l=i===null?null:o[i],u=o.reduce((e,t)=>
65({verified:e.verified+t.verified,attested:e.attested+t.attested,missed:e.missed+t.missed}),{verified:0,attested:0,missed:0});return u.verified+u.attested+u.missed===0?(0,R.jsxs)(`div`,{className:My.card,children:[(0,R.jsx)(`span`,{className:My.kicker,children:r(`the last {n} days`).replace(`{n}`,String(c))}),(0,R.jsx)(`p`,{className:My.empty,children:r(`nothing resolved yet â lock a day and this fills in.`)})]}):(0,R.jsxs)(`div`,{className:My.card,children:[(0,R.jsxs)(`div`,{className:My.head,children:[(0,R.jsx)(`span`,{className:My.kicker,children:r(`the last {n} days`).replace(`{n}`,String(c))}),(0,R.jsx)(`span`,{className:My.readout,children:l?l.rest?`${l.date} · ${r(`rest day`)}`:l.total===0?`${l.date} · ${r(`nothing locked`)}`:`${l.date} · ${l.verified}â ${l.attested}~ ${l.missed}â`:r(`{v} verified · {a} on your word · {m} missed`).replace(`{v}`,String(u.verified)).replace(`{a}`,String(u.attested)).replace(`{m}`,String(u.missed))})]}),(0,R.jsx)(`div`,{className:My.plot,onMouseLeave:()=>a(null),children:o.map((e,t)=>(0,R.jsx)(`button`,{type:`button`,className:My.col,onMouseEnter:()=>a(t),onFocus:()=>a(t),"aria-label":`${e.date}: ${e.verified} verified, ${e.attested} on your word, ${e.missed} missed`,children:e.rest?(0,R.jsx)(`span`,{className:My.rest}):e.total===0?(0,R.jsx)(`span`,{className:My.none}):(0,R.jsxs)(`span`,{className:My.stack,style:{height:`${e.total/s*100}%`},children:[e.missed>0&&(0,R.jsx)(`span`,{className:My.missed,style:{flexGrow:e.missed}}),e.attested>0&&(0,R.jsx)(`span`,{className:My.attested,style:{flexGrow:e.attested}}),e.verified>0&&(0,R.jsx)(`span`,{className:My.verified,style:{flexGrow:e.verified}})]})},e.date))}),(0,R.jsxs)(`div`,{className:My.legend,children:[(0,R.jsxs)(`span`,{className:My.legendItem,children:[(0,R.jsx)(`span`,{className:`${My.dot} ${My.verified}`}),r(`verified`)]}),(0,R.jsxs)(`span`,{className:My.legendItem,children:[(0,R.jsx)(`span`,{className:`${My.dot} ${My.attested}`}),r(`on your word`)]}),(0,R.jsxs)(`span`,{className:My.legendItem,children:[(0,R.jsx)(`span`,{className:`${My.dot} ${My.missed}`}),r(`missed`)]}),(0,R.jsxs)(`span`,{className:My.legendItem,children:[(0,R.jsx)(`span`,{className:`${My.dot} ${My.restDot}`}),r(`rest day`)]})]})]})}var Y={page:`_page_e95yt_3`,heading:`_heading_e95yt_14`,statsRow:`_statsRow_e95yt_26`,statCard:`_statCard_e95yt_32`,statKicker:`_statKicker_e95yt_43`,statNum:`_statNum_e95yt_51`,statCaret:`_statCaret_e95yt_63`,statNumBest:`_statNumBest_e95yt_69`,statNumGood:`_statNumGood_e95yt_73`,statNumWarn:`_statNumWarn_e95yt_77`,statUnit:`_statUnit_e95yt_81`,statTarget:`_statTarget_e95yt_89`,targetBar:`_targetBar_e95yt_100`,targetTrack:`_targetTrack_e95yt_107`,targetFill:`_targetFill_e95yt_115`,targetFillGood:`_targetFillGood_e95yt_122`,targetMark:`_targetMark_e95yt_126`,targetLabel:`_targetLabel_e95yt_136`,statSub:`_statSub_e95yt_144`,plantCard:`_plantCard_e95yt_154`,shareRow:`_shareRow_e95yt_166`,shareStreakBtn:`_shareStreakBtn_e95yt_171`,heatCard:`_heatCard_e95yt_190`,heatKicker:`_heatKicker_e95yt_200`,heatHeader:`_heatHeader_e95yt_208`,heatTabs:`_heatTabs_e95yt_216`,heatTab:`_heatTab_e95yt_216`,heatTabActive:`_heatTabActive_e95yt_237`,"heat-full":`_heat-full_e95yt_244`,"heat-mid":`_heat-mid_e95yt_245`,"heat-low":`_heat-low_e95yt_246`,"heat-zero":`_heat-zero_e95yt_247`,"heat-empty":`_heat-empty_e95yt_251`,dotRow:`_dotRow_e95yt_254`,dotCol:`_dotCol_e95yt_261`,dotWeekday:`_dotWeekday_e95yt_267`,dotDate:`_dotDate_e95yt_267`,dot:`_dot_e95yt_254`,gridScroll:`_gridScroll_e95yt_282`,gridBody:`_gridBody_e95yt_286`,gridMonthRow:`_gridMonthRow_e95yt_290`,gridMonthLabel:`_gridMonthLabel_e95yt_297`,gridWeekdayCol:`_gridWeekdayCol_e95yt_305`,gridWeekdayLabel:`_gridWeekdayLabel_e95yt_311`,gridCols:`_gridCols_e95yt_320`,gridCol:`_gridCol_e95yt_320`,gridDot:`_gridDot_e95yt_329`,gridDotEmpty:`_gridDotEmpty_e95yt_329`,heatLegend:`_heatLegend_e95yt_336`,legendDots:`_legendDots_e95yt_348`,legendDot:`_legendDot_e95yt_348`,stakesCard:`_stakesCard_e95yt_353`,stakesHeader:`_stakesHeader_e95yt_364`,stakesKicker:`_stakesKicker_e95yt_370`,stakesSub:`_stakesSub_e95yt_378`,lockedStakes:`_lockedStakes_e95yt_385`,lockedAmount:`_lockedAmount_e95yt_391`,lockedSymbol:`_lockedSymbol_e95yt_402`,lockedWhat:`_lockedWhat_e95yt_407`,lockedTag:`_lockedTag_e95yt_414`,clearBtn:`_clearBtn_e95yt_422`,stakesForm:`_stakesForm_e95yt_440`,fieldRow:`_fieldRow_e95yt_446`,amountWrap:`_amountWrap_e95yt_452`,dollarSign:`_dollarSign_e95yt_462`,amountInput:`_amountInput_e95yt_468`,whatInput:`_whatInput_e95yt_482`,formError:`_formError_e95yt_504`,lockBtn:`_lockBtn_e95yt_510`,tierRow:`_tierRow_e95yt_516`,tierBtn:`_tierBtn_e95yt_522`,tierBtnActive:`_tierBtnActive_e95yt_540`,tierBtnLabel:`_tierBtnLabel_e95yt_545`,tierBtnSub:`_tierBtnSub_e95yt_557`,betRow:`_betRow_e95yt_565`,betInputWrap:`_betInputWrap_e95yt_571`,betSymbol:`_betSymbol_e95yt_587`,betInput:`_betInput_e95yt_571`,betNote:`_betNote_e95yt_607`,lockStakeBtn:`_lockStakeBtn_e95yt_617`,lockedMeta:`_lockedMeta_e95yt_641`,lockedTierBadge:`_lockedTierBadge_e95yt_647`,lockedBetBadge:`_lockedBetBadge_e95yt_658`,lockedBarRow:`_lockedBarRow_e95yt_669`,lockedBarSegment:`_lockedBarSegment_e95yt_676`,lockedBarSegmentActive:`_lockedBarSegmentActive_e95yt_690`,lockedBarLabel:`_lockedBarLabel_e95yt_696`,stakeNote:`_stakeNote_e95yt_705`,verifyRow:`_verifyRow_e95yt_715`,verifyBtn:`_verifyBtn_e95yt_722`,verifyResult:`_verifyResult_e95yt_743`,verifyOk:`_verifyOk_e95yt_749`,verifyFail:`_verifyFail_e95yt_750`,verifyPending:`_verifyPending_e95yt_752`,analysisCard:`_analysisCard_e95yt_762`,analysisHeadline:`_analysisHeadline_e95yt_773`,analysisTotal:`_analysisTotal_e95yt_780`,analysisBig:`_analysisBig_e95yt_786`,analysisApprox:`_analysisApprox_e95yt_795`,analysisUnit:`_analysisUnit_e95yt_805`,analysisSub:`_analysisSub_e95yt_819`,analysisBreakdown:`_analysisBreakdown_e95yt_830`,breakdownRow:`_breakdownRow_e95yt_840`,breakdownLabel:`_breakdownLabel_e95yt_847`,breakdownCalc:`_breakdownCalc_e95yt_853`,breakdownVal:`_breakdownVal_e95yt_860`,breakdownTotal:`_breakdownTotal_e95yt_869`,breakdownNote:`_breakdownNote_e95yt_882`,catSection:`_catSection_e95yt_892`,catTitle:`_catTitle_e95yt_898`,catRow:`_catRow_e95yt_906`,catName:`_catName_e95yt_913`,catBarTrack:`_catBarTrack_e95yt_921`,catBarFill:`_catBarFill_e95yt_929`,catPct:`_catPct_e95yt_936`,catCount:`_catCount_e95yt_944`,catInsight:`_catInsight_e95yt_951`,trendRow:`_trendRow_e95yt_961`,trendArrow:`_trendArrow_e95yt_967`,trendUp:`_trendUp_e95yt_974`,trendDown:`_trendDown_e95yt_975`,trendLabel:`_trendLabel_e95yt_977`,recoverCard:`_recoverCard_e95yt_1016`,recoverHeader:`_recoverHeader_e95yt_1027`,recoverKicker:`_recoverKicker_e95yt_1035`,recoverWindow:`_recoverWindow_e95yt_1043`,recoverLede:`_recoverLede_e95yt_1051`,recoverOptions:`_recoverOptions_e95yt_1058`,recoverOption:`_recoverOption_e95yt_1058`,recoverOptTitle:`_recoverOptTitle_e95yt_1081`,recoverOptSub:`_recoverOptSub_e95yt_1089`,recoverOptGo:`_recoverOptGo_e95yt_1096`,recoverOptUsed:`_recoverOptUsed_e95yt_1105`,recoverOptBtn:`_recoverOptBtn_e95yt_1114`,recoverMsg:`_recoverMsg_e95yt_1132`,statFreeze:`_statFreeze_e95yt_1141`},Py={week:7,"14d":14,month:30,year:365},Fy={week:`week`,"14d":`14 days`,month:`month`,year:`year`},Iy={week:`last week`,"14d":`last 14 days`,month:`last month`,year:`last year`},Ly=[`S`,`M`,`T`,`W`,`T`,`F`,`S`],Ry=[`Jan`,`Feb`,`Mar`,`Apr`,`May`,`Jun`,`Jul`,`Aug`,`Sep`,`Oct`,`Nov`,`Dec`];function zy(e){return e.hasEntry?e.pct===1?`full`:e.pct>=.5?`mid`:e.pct>0?`low`:`zero`:`empty`}function By(e){let t=[],n=Array(7).fill(null);for(let r of e){let e=new Date(r.date+`T12:00:00Z`).getUTCDay();n[e]=r,e===6&&(t.push(n),n=Array(7).fill(null))}return n.some(Boolean)&&t.push(n),t}function Vy(e){let t=-1;return e.map(e=>{let n=e.find(Boolean);if(!n)return null;let r=new Date(n.date+`T12:00:00Z`).getUTCMonth();return r===t?null:(t=r,Ry[r])})}var Hy=new Set([`pending`,`planned`]);function Uy(e,t){return Math.round((new Date(e+`T12:00:00Z`).getTime()-new Date(t+`T12:00:00Z`).getTime())/864e5)}function Wy(e,t,n){let r=new Date(t+`T12:00:00Z`).getTime()+864e5,i=new Date(e+`T12:00:00Z`).getTime();for(;r<i;){if(!Jh(new Date(r).toISOString().slice(0,10),n))return!1;r+=864e5}return!0}function Gy(e,t){let n=new Date().toLocaleDateString(`en-CA`),r=null,i=null;for(let a=e.length-1;a>=0;a--){let{date:o,priorities:s}=e[a];if(s.length===0)break;if(!(o===n&&s.some(e=>Hy.has(e.status)))){if(i!==null&&Uy(i,o)!==1&&!Wy(i,o,t))break;if(Jh(o,t)){i=o;continue}if(s.filter(e=>e.status===`done`).length/s.length>=.6666666666666666)r=o,i=o;else break}}return r}function Ky(){let e=z(),{lang:t}=ml(),{session:n,profile:r}=ll(),i=n?.user.id,{active:a,firstWorkspaceId:o}=wl(),s=!!a&&a.id===o,{entries:c,loading:l}=nf(i,a?.id,s),{cfg:u}=xh(i),d=Xh(c,u),f=rg(c,u),p=ig(c,new Date,u),m=Zh(c),h=ag(c,u).state,g=d>0?Gy(c,u):null,v=ng(u,g,new Date().toLocaleDateString(`en-CA`)),y=g?new Date(g+`T12:00:00Z`).toLocaleDateString(t===`fr`?`fr-FR`:`en-US`,{month:`short`,day:`numeric`,timeZone:`UTC`}):null,[b,x]=(0,_.useState)(!1),[S,C]=(0,_.useState)(`month`),w=h===`critical`||h===`dead`,[T,
65E]=(0,_.useState)(null),[D,O]=(0,_.useState)(null),[k,A]=(0,_.useState)(null),[j,ee]=(0,_.useState)(!1);(0,_.useEffect)(()=>{if(!w||!i)return;let e=!1;return(async()=>{let[t,n]=await Promise.all([gy(i),py(i)]);e||(E(t),O(n))})(),()=>{e=!0}},[w,i]);async function te(){if(!i||j)return;ee(!0);let{error:t}=await _y(i);t?A(e(`double day already used this month`)):(A(e(`booked â finish tomorrow's set + yesterday's misses, all verified`)),E(e=>e&&{...e,doubleDayUsed:!0})),ee(!1)}async function ne(){if(!i||!D||j)return;ee(!0);let{error:t}=await vy(i,D.user_id,D.name);t?A(e(`pod vouch already used this quarter`)):(A(e(`{name} vouched â recorded for good`).replace(`{name}`,D.name)),E(e=>e&&{...e,podVouchUsed:!0})),ee(!1)}Fg(i,c,r?.name,r?.product_name);let re=Uh(c,Py[S],rf()),M=S===`week`||S===`14d`,N=d<3?3:d<7?7:d<14?14:d<30?30:d<60?60:100;return l?(0,R.jsx)(`div`,{className:Y.page,children:(0,R.jsx)(`span`,{className:Y.heading,children:e(`streak`)})}):(0,R.jsxs)(`div`,{className:Y.page,children:[(0,R.jsx)(`span`,{className:Y.heading,children:e(`streak`)}),(0,R.jsxs)(`div`,{className:Y.plantCard,children:[(0,R.jsx)(Hu,{streak:d,longestStreak:f,atRisk:p,inProgress:m,health:h,size:168}),(0,R.jsx)(`div`,{className:Y.shareRow,children:(0,R.jsx)(`button`,{type:`button`,className:Y.shareStreakBtn,onClick:()=>x(!0),children:e(`share streak â`)})})]}),b&&(0,R.jsx)(Iv,{card:{kind:`streak`,streak:d,best:f,name:r?.name,product:r?.product_name},userId:i,xLine:d>0?`${d}-day build streak on Crew ð¥ â showing up for ${r?.product_name||`my startup`} every day.`:`Starting my build streak on Crew â accountability for founders.`,filename:`crew-streak-${d}`,onClose:()=>x(!1)}),w&&(0,R.jsxs)(`div`,{className:Y.recoverCard,children:[(0,R.jsxs)(`div`,{className:Y.recoverHeader,children:[(0,R.jsx)(`span`,{className:Y.recoverKicker,children:e(`recover your streak`)}),(0,R.jsx)(`span`,{className:Y.recoverWindow,children:e(`1-day window · until midnight tomorrow`)})]}),(0,R.jsx)(`p`,{className:Y.recoverLede,children:e(`the run broke. three ways back, one day to use them.`)}),(0,R.jsxs)(`div`,{className:Y.recoverOptions,children:[(0,R.jsxs)(Rn,{to:`/app/review`,className:Y.recoverOption,children:[(0,R.jsx)(`span`,{className:Y.recoverOptTitle,children:e(`add late proof`)}),(0,R.jsx)(`span`,{className:Y.recoverOptSub,children:e(`evidence you shipped but never logged. unlimited.`)}),(0,R.jsx)(`span`,{className:Y.recoverOptGo,children:e(`go to review â`)})]}),(0,R.jsxs)(`div`,{className:Y.recoverOption,children:[(0,R.jsx)(`span`,{className:Y.recoverOptTitle,children:e(`double day`)}),(0,R.jsx)(`span`,{className:Y.recoverOptSub,children:e(`tomorrow's full set + yesterday's misses, all verified.`)}),T?.doubleDayUsed?(0,R.jsx)(`span`,{className:Y.recoverOptUsed,children:e(`used this month`)}):(0,R.jsx)(`button`,{type:`button`,className:Y.recoverOptBtn,onClick:te,disabled:j,children:e(`book it · once / month`)})]}),(0,R.jsxs)(`div`,{className:Y.recoverOption,children:[(0,R.jsx)(`span`,{className:Y.recoverOptTitle,children:e(`pod vouch`)}),D?(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`span`,{className:Y.recoverOptSub,children:e(`{name} confirms you worked â their name stays on the record.`).replace(`{name}`,D.name)}),T?.podVouchUsed?(0,R.jsx)(`span`,{className:Y.recoverOptUsed,children:e(`used this quarter`)}):(0,R.jsx)(`button`,{type:`button`,className:Y.recoverOptBtn,onClick:ne,disabled:j,children:e(`{name} vouches · once / quarter`).replace(`{name}`,D.name)})]}):(0,R.jsx)(`span`,{className:Y.recoverOptSub,children:e(`needs an active pod â no partner yet.`)})]})]}),k&&(0,R.jsx)(`span`,{className:Y.recoverMsg,children:k})]}),(0,R.jsx)(Ny,{entries:c,restCfg:u}),(0,R.jsx)(zv,{pct:Lh(c),volume:jg(c),blindSpot:Ng(c),userId:i,name:r?.name,product:r?.product_name}),(0,R.jsxs)(`div`,{className:Y.statsRow,children:[(0,R.jsxs)(`div`,{className:Y.statCard,children:[(0,R.jsx)(`span`,{className:Y.statKicker,children:e(`current streak`)}),(0,R.jsxs)(`div`,{className:Y.statNum,children:[(0,R.jsx)(`span`,{className:Y.statCaret,"aria-hidden":!0,children:`â²`}),d]}
65),(0,R.jsx)(`span`,{className:Y.statSub,children:y?e(`days · since {date}`).replace(`{date}`,y):e(`lock today's 3 to start one`)}),d>0&&d<N&&(0,R.jsx)(`span`,{className:Y.statTarget,children:e(`next milestone: {n} days · {d} to go`).replace(`{n}`,String(N)).replace(`{d}`,String(N-d))}),v>0&&(0,R.jsx)(`span`,{className:Y.statFreeze,children:v===1?e(`1 day off kept this run alive`):e(`{n} days off kept this run alive`).replace(`{n}`,String(v))})]}),(0,R.jsxs)(`div`,{className:Y.statCard,children:[(0,R.jsx)(`span`,{className:Y.statKicker,children:e(`best ever`)}),(0,R.jsx)(`div`,{className:B(Y.statNum,Y.statNumBest),children:f}),(0,R.jsx)(`span`,{className:Y.statSub,children:f===0?e(`no streak yet`):d>=f?e(`you're living it right now`):e(`{n} days to beat it`).replace(`{n}`,String(f-d))})]})]}),(0,R.jsxs)(`div`,{className:Y.heatCard,children:[(0,R.jsxs)(`div`,{className:Y.heatHeader,children:[(0,R.jsx)(`span`,{className:Y.heatKicker,children:e(Iy[S])}),(0,R.jsx)(`div`,{className:Y.heatTabs,children:[`week`,`14d`,`month`,`year`].map(t=>(0,R.jsx)(`button`,{className:B(Y.heatTab,S===t&&Y.heatTabActive),onClick:()=>C(t),children:e(Fy[t])},t))})]}),c.length===0?(0,R.jsx)(`p`,{className:Y.statSub,children:e(`no days locked yet.`)}):M?(0,R.jsx)(`div`,{className:Y.dotRow,children:re.map(e=>{let t=new Date(e.date+`T12:00:00Z`);return(0,R.jsxs)(`div`,{className:Y.dotCol,children:[(0,R.jsx)(`span`,{className:Y.dotWeekday,children:Ly[t.getUTCDay()]}),(0,R.jsx)(`div`,{className:B(Y.dot,Y[`heat-${zy(e)}`]),title:e.hasEntry?`${e.date}: ${Math.round(e.pct*100)}% (${e.done}/${e.total})`:`${e.date}: no tasks`}),(0,R.jsx)(`span`,{className:Y.dotDate,children:t.getUTCDate()})]},e.date)})}):(()=>{let e=By(re),t=Vy(e);return(0,R.jsxs)(`div`,{className:Y.gridScroll,children:[(0,R.jsx)(`div`,{className:Y.gridMonthRow,children:t.map((e,t)=>(0,R.jsx)(`span`,{className:Y.gridMonthLabel,children:e??``},t))}),(0,R.jsxs)(`div`,{className:Y.gridBody,children:[(0,R.jsx)(`div`,{className:Y.gridWeekdayCol,children:Ly.map((e,t)=>(0,R.jsx)(`span`,{className:Y.gridWeekdayLabel,children:t%2==1?e:``},t))}),(0,R.jsx)(`div`,{className:Y.gridCols,children:e.map((e,t)=>(0,R.jsx)(`div`,{className:Y.gridCol,children:e.map((e,t)=>e?(0,R.jsx)(`div`,{className:B(Y.gridDot,Y[`heat-${zy(e)}`]),title:e.hasEntry?`${e.date}: ${Math.round(e.pct*100)}% (${e.done}/${e.total})`:`${e.date}: no tasks`},t):(0,R.jsx)(`div`,{className:Y.gridDotEmpty},t))},t))})]})]})})(),c.length>0&&(0,R.jsxs)(`div`,{className:Y.heatLegend,children:[(0,R.jsx)(`span`,{children:e(`less`)}),(0,R.jsxs)(`div`,{className:Y.legendDots,children:[(0,R.jsx)(`span`,{className:B(Y.legendDot,Y[`heat-zero`])}),(0,R.jsx)(`span`,{className:B(Y.legendDot,Y[`heat-low`])}),(0,R.jsx)(`span`,{className:B(Y.legendDot,Y[`heat-mid`])}),(0,R.jsx)(`span`,{className:B(Y.legendDot,Y[`heat-full`])})]}),(0,R.jsx)(`span`,{children:e(`more`)})]})]})]})}async function qy(e,t,n,r){let i=L.from(`messages`).select(`*`).eq(`user_id`,e).eq(`surface`,t);return n&&(i=r?i.or(`workspace_id.eq.${n},workspace_id.is.null`):i.eq(`workspace_id`,n)),i.order(`created_at`,{ascending:!0})}async function Jy(e,t,n,r,i){return L.from(`messages`).insert({user_id:e,role:t,surface:n,body:r,...i?{workspace_id:i}:{}}).select().single()}var Yy=L,Xy=3;async function Zy(e){let t=new Date(Date.now()-2*864e5).toISOString().slice(0,10),{data:n,error:r}=await Yy.from(`judgments`).select(`id, priority_id, evidence_refs, asked_at, priorities!inner(text, status)`).eq(`user_id`,e).eq(`verdict`,`uncertain`).eq(`priorities.status`,`pending`).gte(`date`,t).order(`created_at`,{ascending:!1});if(r||!n)return[];let i=n,a=new Map;for(let e of i)e.asked_at&&!a.has(e.priority_id)&&a.set(e.priority_id,e.asked_at);let o=new Set;return i.filter(e=>o.has(e.priority_id)?!1:(o.add(e.priority_id),!0)).slice(0,Xy).map(e=>({id:e.id,priority_id:e.priority_id,task:e.priorities?.text??``,evidence:(e.evidence_refs??[]).map(e=>({source:e.source??``,title:e.title??``})),asked_at:a.get(e.priority_id)??null}))}async function Qy(e,t){await Yy.from(`judgments`).update({asked_at:new Date().toISOString()}).eq(`user_id`,e).eq(`priority_id`,t).eq(`verdict`,`uncertain`)}async function $y(e,t,n,r,i){let a=r===`done`?`overturned_done`:`overturned_skipped`;await Yy.from(`judgment_feedback`).insert({judgment_id:e,user_id:t,correction:a}),await L.from(`priorities`).update({status:r,proof:i}).eq(`id`,n)}async function eb(e,t){let{data:n}=await L.from(`priorities`).select(`id, text, status`).eq(`user_id`,e).eq(`date`,t).order(`created_at`,{ascending:!0});if(!n||n.length===0)return[];let{data:r}=await Yy.from(`judgments`).select(`id, priority_id, verdict, confidence, created_at`).eq(`user_id`,e).eq(`date`,t).order(`created_at`,{ascending:!1}),i=new Map;for(let e of r??[])i.has(e.priority_id)||i.set(e.priority_id,e);return n.map(e=>{let t=i.get(e.id);return{priorityId:e.id,text:e.text,status:e.status,judgmentId:t?.id??null,verdict:t?.verdict??null,confidence:t?.confidence??null}})}async function tb(e,t,n,r){if(n&&(r===`done`||r===`skipped`)){let t=r===`done`?`overturned_done`:`overturned_skipped`;await Yy.from(`judgment_feedback`).insert({judgment_id:n,user_id:e,correction:t})}await L.from(`priorities`).update({status:r}).eq(`id`,t)}var nb={page:`_page_1pgge_3`,heading:`_heading_1pgge_17`,chatWrap:`_chatWrap_1pgge_28`,thread:`_thread_1pgge_36`,crewTurn:`_crewTurn_1pgge_64`,crewTurnRun:`_crewTurnRun_1pgge_74`,crewName:`_crewName_1pgge_79`,crewBody:`_crewBody_1pgge_87`,userTurn:`_userTurn_1pgge_94`,userBubble:`_userBubble_1pgge_100`,userImage:`_userImage_1pgge_113`,para:`_para_1pgge_122`,bullet:`_bullet_1pgge_125`,gap:`_gap_1pgge_141`,chips:`_chips_1pgge_145`,chip:`_chip_1pgge_145`,inputArea:`_inputArea_1pgge_173`,founderNote:`_founderNote_1pgge_181`,composer:`_composer_1pgge_193`,composerHint:`_composerHint_1pgge_210`,iconBtn:`_iconBtn_1pgge_219`,fileInput:`_fileInput_1pgge_236`,uploadBtn:`_uploadBtn_1pgge_240`,uploadBtnLoading:`_uploadBtnLoading_1pgge_262`,proofPreviewWrap:`_proofPreviewWrap_1pgge_268`,proofPreviewImg:`_proofPreviewImg_1pgge_274`,proofRemoveBtn:`_proofRemoveBtn_1pgge_283`,grow:`_grow_1pgge_305`,input:`_input_1pgge_173`,sendBtn:`_sendBtn_1pgge_346`,sendBtnActive:`_sendBtnActive_1pgge_362`,daySep:`_daySep_1pgge_394`};function rb(e){return e.split(/(\*\*[^*]+\*\*)/).map((e,t)=>e.startsWith(`**`)&&e.endsWith(`**`)?(0,R.jsx)(`strong`,{children:e.slice(2,-2)},t):e)}function ib({text:e}){return(0,R.jsx)(R.Fragment,{children:e.split(` 66`).map((e,t)=>e.startsWith(`- `)||e.startsWith(`⢠`)?(0,R.jsx)(`p`,{className:nb.bullet,children:rb(e.slice(2))},t):e.trim()?(0,R.jsx)(`p`,{className:nb.para,children:rb(e)},t):(0,R.jsx)(`span`,{className:nb.gap},t))})}var ab=1080*60*1e3;function ob(e){let t=Date.now()-ab;return e.filter(e=>!e.at||new Date(e.at).getTime()>=t)}
66function sb(e){return e?e.slice(0,10):new Date().toLocaleDateString(`en-CA`)}function cb(e,t,n){let r=sb(e),i=new Date().toLocaleDateString(`en-CA`),a=new Date(Date.now()-864e5).toLocaleDateString(`en-CA`);return r===i?t(`today`):r===a?t(`yesterday`):new Date(r+`T12:00:00Z`).toLocaleDateString(n===`fr`?`fr-FR`:`en-US`,{month:`short`,day:`numeric`})}function lb(e,t,n,r,i,a,o){let s=a>0?e(`{done}/{total} done today.`).replace(`{done}`,String(i)).replace(`{total}`,String(a)):e(`nothing locked yet today.`);return t>=10?e(`{n}-day streak â that's momentum. {status} what's next?`).replace(`{n}`,String(t)).replace(`{status}`,s):t>=5?e(`{n} days straight at {pct}% last week. {status} keep it going.`).replace(`{n}`,String(t)).replace(`{pct}`,String(n)).replace(`{status}`,s):t>=2?e(`{n} days in. {pct}% last week. {status} what are you working on?`).replace(`{n}`,String(t)).replace(`{pct}`,String(n)).replace(`{status}`,s):n>=75?e(`{pct}% last week â solid. streak reset but the consistency is real. {status}`).replace(`{pct}`,String(n)).replace(`{status}`,s):n>=50?e(`{pct}% last week, {pct30}% over 30 days. {status} what do you want to dig into?`).replace(`{pct}`,String(n)).replace(`{pct30}`,String(r)).replace(`{status}`,s):a===0?e(`let's start. what are the {count} things that have to happen today?`).replace(`{count}`,String(o)):e(`{pct}% last week. more misses than hits. {status} what's actually blocking you?`).replace(`{pct}`,String(n)).replace(`{status}`,s)}function ub(){let e=z(),{lang:t}=ml(),n=[{id:`today`,label:e(`what's my priority right now?`),haiku:!0},{id:`week`,label:e(`show my week`),haiku:!0},{id:`slipping`,label:e(`where am i slipping?`),haiku:!0}],r=[{id:`tomorrow`,label:e(`plan tomorrow's 3`)},{id:`goal`,label:e(`am i on track for my goal?`),haiku:!0},{id:`pattern`,label:e(`what pattern do you see?`),haiku:!0}],i=pu(),{session:a,profile:o}=ll(),s=o?.daily_task_count??3,c=a?.user.id,{active:l,firstWorkspaceId:u}=wl(),d=!!l&&l.id===u,{entries:f}=nf(c,l?.id,d),{cfg:p}=xh(c),m=(0,_.useMemo)(()=>{let e=og(f),t=sg(f),n=Hh(f),r=n.slice(-7),i=n.slice(-30),a=r.reduce((e,t)=>e+t.done,0),o=r.reduce((e,t)=>e+t.total,0),s=i.reduce((e,t)=>e+t.done,0),c=i.reduce((e,t)=>e+t.total,0),l=n.length>0?n[n.length-1]:null;return{streak:Xh(f,p),weekPct:o>0?Math.round(a/o*100):0,last30Pct:c>0?Math.round(s/c*100):0,salesSlipPct:Math.round((e.sales?.slipRate??0)*100),weekendPct:Math.round(t.weekend*100),weekdayPct:Math.round(t.weekday*100),todayDone:l?.done??0,todayLocked:l?.total??0}},[f,p]),h=Ug(),[g,v]=(0,_.useState)([]),[y,b]=(0,_.useState)([]),[x,S]=(0,_.useState)(!1),[C,w]=(0,_.useState)(``),[T,E]=(0,_.useState)(`initial`),[D,O]=(0,_.useState)(!1),[k,A]=(0,_.useState)(null),[j,ee]=(0,_.useState)(null),[te,ne]=(0,_.useState)(!1),re=(0,_.useRef)(null),M=(0,_.useRef)(null),[N,ie]=(0,_.useState)([]),[ae,P]=(0,_.useState)(null),[oe,se]=(0,_.useState)(null),ce=(0,_.useRef)(!1);(0,_.useEffect)(()=>{if(!c)return;let t=!1;return qy(c,`chat`,l?.id,d).then(async({data:r})=>{if(!t){if(r&&r.length>0)v(r.map(e=>({from:e.role,text:e.body,at:e.created_at}))),E(`open`),b([]);else{let t=lb(e,m.streak,m.weekPct,m.last30Pct,m.todayDone,m.todayLocked,s);v([{from:`crew`,text:t}]),b(n),await Jy(c,`crew`,`chat`,t,l?.id)}t||O(!0)}}),()=>{t=!0}},[c,l?.id]),(0,_.useEffect)(()=>{re.current?.scrollIntoView({behavior:`smooth`})},[g,x]),(0,_.useEffect)(()=>{!D||!c||ce.current||(ce.current=!0,Zy(c).then(e=>{e.length!==0&&(ie(e.slice(1)),le(e[0]))}))},[D,c]);async function le(t){P(t),se(null);let n=e(`before we move on â did you actually ship "{task}"? I couldn't verify it automatically last night.`).replace(`{task}`,t.task),r=g.some(e=>e.from===`crew`&&e.text===n);!t.asked_at&&!r&&(v(e=>[...e,{from:`crew`,text:n}]),await Jy(c,`crew`,`chat`,n,l?.id),await Qy(c,t.priority_id)),E(`open`),b([{id:`judgment-yes`,label:e(`yes, shipped it`)},{id:`judgment-no`,label:e(`didn't happen`)}])}async function ue(t){if(!c||!ae)return;se(t),b([]);let n=e(t===`done`?`what's the proof? a link, a screenshot, or just tell me what you did.`:`what happened?`);v(e=>[...e,{from:`crew`,text:n}]),await Jy(c,`crew`,`chat`,n,l?.id)}async function de(e){if(b([]),v(t=>[...t,{from:`crew`,text:e}]),await Jy(c,`crew`,`chat`,e,l?.id),P(null),se(null),N.length>0){let[e,...t]=N;ie(t),await le(e)}}async function fe(t,n){let r=ae;if(oe===`skipped`){await $y(r.id,c,r.priority_id,`skipped`,`couldn't do it â ${t}`),$l(`reconcile_confirm`,{answer:`skipped`}
66),await de(e(`got it â marked as not done. tomorrow's a new day.`));return}S(!0),i||await new Promise(e=>setTimeout(e,400));let a=await wh({priorityId:r.priority_id,note:t,imagePath:n??void 0});if(S(!1),!a||a.proofClass===`verified`){await $y(r.id,c,r.priority_id,`done`,a?`${t} · â crew reviewed: ${a.message}`:t),$l(`reconcile_confirm`,{answer:`done`}),await de(a?`â ${a.message}`:e(`â marked done â nice work.`));return}v(e=>[...e,{from:`crew`,text:a.message}]),await Jy(c,`crew`,`chat`,a.message,l?.id),b([{id:`judgment-giveup`,label:e(`actually, I couldn't do it`)}])}async function pe(e){let t=e.target.files?.[0];if(!(!t||!c)){ne(!0);try{let e=t.name.split(`.`).pop()??`png`,n=`${c}/${Date.now()}.${e}`,{error:r}=await L.storage.from(`proof-uploads`).upload(n,t,{contentType:t.type});if(r){console.error(`upload error`,r);return}ee(n),A(URL.createObjectURL(t)),E(`open`)}finally{ne(!1),M.current&&(M.current.value=``)}}}function me(){k&&URL.revokeObjectURL(k),ee(null),A(null)}async function he(e){try{let{data:t}=await L.storage.from(`proof-uploads`).createSignedUrl(e,300);if(t?.signedUrl)return t.signedUrl}catch{}let{data:{publicUrl:t}}=L.storage.from(`proof-uploads`).getPublicUrl(e);return t||void 0}async function ge(e,t,n=!1,r){if(!c)return;S(!0),i||await new Promise(e=>setTimeout(e,400));let a=``;try{a=localStorage.getItem(`crew.businessContext`)??``}catch{}let o=fg(f,p,a),{reply:s}=await yy({userMessage:e,history:ob(t).slice(-12).map(e=>({role:e.from,text:e.text})),useHaiku:n,context:o,imageUrl:r});S(!1),v(e=>[...e,{from:`crew`,text:s}]),await Jy(c,`crew`,`chat`,s,l?.id)}async function _e(e){if(!c||x)return;if(e.id===`judgment-yes`||e.id===`judgment-no`||e.id===`judgment-giveup`){let t=e.label;v(e=>[...e,{from:`user`,text:t}]),await Jy(c,`user`,`chat`,t,l?.id),await ue(e.id===`judgment-yes`?`done`:`skipped`);return}let t=[...g,{from:`user`,text:e.label}];v(t),b([]),await Jy(c,`user`,`chat`,e.label,l?.id),await ge(e.label,t,e.haiku??!1),T===`initial`?(E(`followup`),b(r)):(E(`open`),b([]))}async function ve(){if(!c||x)return;let e=C.trim();if(!e&&!j)return;let t=j,n=e||`here is my proof`,r=[...g,{from:`user`,text:n,imageUrl:k??void 0}];if(v(r),w(``),ee(null),A(null),await Jy(c,`user`,`chat`,n,l?.id),E(`open`),ae&&oe){await fe(n,t);return}await ge(n,r,!1,t?await he(t):void 0)}return D?(0,R.jsx)(`div`,{className:nb.page,children:(0,R.jsxs)(`div`,{className:nb.chatWrap,children:[(0,R.jsxs)(`div`,{className:nb.thread,children:[g.map((n,r)=>{let i=r===0||sb(n.at)!==sb(g[r-1]?.at);return(0,R.jsxs)(`div`,{children:[i&&(0,R.jsx)(`div`,{className:nb.daySep,children:(0,R.jsx)(`span`,{children:cb(n.at,e,t)})}),n.from===`crew`?(0,R.jsxs)(`div`,{className:B(nb.crewTurn,!i&&g[r-1]?.from===`crew`&&nb.crewTurnRun),children:[(i||g[r-1]?.from!==`crew`)&&(0,R.jsx)(`span`,{className:nb.crewName,children:e(`crew`)}),(0,R.jsx)(`div`,{className:nb.crewBody,children:(0,R.jsx)(ib,{text:n.text})})]}):(0,R.jsx)(`div`,{className:nb.userTurn,children:(0,R.jsxs)(`div`,{className:nb.userBubble,children:[n.imageUrl&&(0,R.jsx)(`img`,{src:n.imageUrl,alt:``,className:nb.userImage}),(0,R.jsx)(ib,{text:n.text})]})})]},r)}),x&&(0,R.jsxs)(`div`,{className:nb.crewTurn,children:[(0,R.jsx)(`span`,{className:nb.crewName,children:e(`crew`)}),(0,R.jsx)(`div`,{className:nb.crewBody,children:(0,R.jsx)(bm,{})})]}),(0,R.jsx)(`div`,{ref:re})]}),y.length>0&&!x&&(0,R.jsx)(`div`,{className:nb.chips,children:y.map(e=>(0,R.jsx)(`button`,{className:nb.chip,onClick:()=>_e(e),children:e.label},e.id))}),h.locked&&(0,R.jsx)(Gg,{heading:e(`your free trial is over`),sub:e(`subscribe to keep chatting with your co-founder â unlimited, plus real verification and streaks.`)}),!h.locked&&(0,R.jsxs)(`div`,{className:nb.inputArea,children:[h.trialMode&&h.chatRemaining<=50&&(0,R.jsx)(`p`,{className:nb.founderNote,children:h.chatRemaining>0?e(`{n} chats left â message us for a top-up.`).replace(`{n}`,String(h.chatRemaining)):e(`chat limit reached â message us and we'll top you up.`)}),k&&(0,R.jsxs)(`div`,{className:nb.proofPreviewWrap,children:[(0,R.jsx)(`img`,{src:k,alt:e(`proof preview`),className:nb.proofPreviewImg}),(0,R.jsx)(`button`,{className:nb.proofRemoveBtn,onClick:me,"aria-label":e(`Remove image`),children:`â`})]}),(0,R.jsxs)(`div`,{className:nb.composer,children:[(0,R.jsx)(`input`,{ref:M,type:`file`,accept:`image/*,application/pdf`,className:nb.fileInput,onChange:pe}),(0,R.jsx)(`button`,{className:B(nb.iconBtn,te&&nb.uploadBtnLoading),onClick:()=>M.current?.click(),disabled:te,"aria-label":e(`Attach proof`),title:e(`Attach screenshot as proof`),children:te?`â¦`:(0,R.jsx)(`svg`,{width:`20`,he
66ight:`20`,viewBox:`0 0 24 24`,fill:`none`,"aria-hidden":!0,children:(0,R.jsx)(`path`,{d:`M12 5v14M5 12h14`,stroke:`currentColor`,strokeWidth:`1.7`,strokeLinecap:`round`})})}),(0,R.jsx)(`div`,{className:nb.grow,"data-value":C,children:(0,R.jsx)(`textarea`,{className:nb.input,rows:1,placeholder:e(j?`add a note or just hit sendâ¦`:`ask crew anythingâ¦`),value:C,onChange:e=>w(e.target.value),onKeyDown:e=>{e.key===`Enter`&&!e.shiftKey&&(e.preventDefault(),ve())}})}),(0,R.jsx)(l_,{onText:e=>w(t=>t?`${t} ${e}`:e)}),(0,R.jsx)(`button`,{className:B(nb.sendBtn,(C.trim()||j)&&nb.sendBtnActive),onClick:ve,disabled:!C.trim()&&!j,"aria-label":e(`Send`),children:(0,R.jsx)(`svg`,{width:`16`,height:`16`,viewBox:`0 0 24 24`,fill:`none`,"aria-hidden":!0,children:(0,R.jsx)(`path`,{d:`M12 19V5M12 5l-6 6M12 5l6 6`,stroke:`currentColor`,strokeWidth:`2.2`,strokeLinecap:`round`,strokeLinejoin:`round`})})})]}),(0,R.jsx)(`p`,{className:nb.composerHint,children:e(`enter to send · shift + enter for a new line`)})]})]})}):(0,R.jsx)(`div`,{className:nb.page})}var X={page:`_page_nrb34_1`,heading:`_heading_nrb34_12`,intro:`_intro_nrb34_22`,setupGrid:`_setupGrid_nrb34_32`,setupCard:`_setupCard_nrb34_43`,setupTitle:`_setupTitle_nrb34_53`,setupForm:`_setupForm_nrb34_63`,setupInput:`_setupInput_nrb34_69`,setupInputCode:`_setupInputCode_nrb34_86`,setupError:`_setupError_nrb34_92`,setupBtn:`_setupBtn_nrb34_98`,podHeader:`_podHeader_nrb34_115`,podMeta:`_podMeta_nrb34_126`,podName:`_podName_nrb34_134`,podCount:`_podCount_nrb34_145`,podActions:`_podActions_nrb34_151`,inviteRow:`_inviteRow_nrb34_158`,inviteLabel:`_inviteLabel_nrb34_168`,inviteCode:`_inviteCode_nrb34_176`,copyCodeBtn:`_copyCodeBtn_nrb34_184`,leaveBtn:`_leaveBtn_nrb34_196`,boardStatus:`_boardStatus_nrb34_211`,boardError:`_boardError_nrb34_217`,soloNote:`_soloNote_nrb34_223`,boardGrid:`_boardGrid_nrb34_242`,memberCard:`_memberCard_nrb34_250`,memberCardMe:`_memberCardMe_nrb34_260`,memberHeader:`_memberHeader_nrb34_267`,memberIdentity:`_memberIdentity_nrb34_275`,memberName:`_memberName_nrb34_281`,youTag:`_youTag_nrb34_291`,memberProduct:`_memberProduct_nrb34_304`,memberStats:`_memberStats_nrb34_310`,statChip:`_statChip_nrb34_318`,statChipGit:`_statChipGit_nrb34_328`,statChipNum:`_statChipNum_nrb34_332`,statChipLabel:`_statChipLabel_nrb34_339`,receiptBlock:`_receiptBlock_nrb34_349`,receiptLabel:`_receiptLabel_nrb34_357`,receiptList:`_receiptList_nrb34_366`,receiptItem:`_receiptItem_nrb34_375`,dot:`_dot_nrb34_381`,receiptText:`_receiptText_nrb34_400`,receiptTextMuted:`_receiptTextMuted_nrb34_408`,receiptProof:`_receiptProof_nrb34_412`,receiptCat:`_receiptCat_nrb34_420`,noData:`_noData_nrb34_430`,pageHeader:`_pageHeader_nrb34_440`,tabs:`_tabs_nrb34_448`,tabBtn:`_tabBtn_nrb34_455`,tabBtnActive:`_tabBtnActive_nrb34_473`,podChatWrap:`_podChatWrap_nrb34_480`,podChatThread:`_podChatThread_nrb34_488`,podChatMsg:`_podChatMsg_nrb34_501`,podChatMsgMe:`_podChatMsgMe_nrb34_509`,podChatSender:`_podChatSender_nrb34_514`,podChatBubble:`_podChatBubble_nrb34_522`,podChatBubbleMe:`_podChatBubbleMe_nrb34_533`,podChatInputRow:`_podChatInputRow_nrb34_539`,podChatInput:`_podChatInput_nrb34_539`,podChatEmpty:`_podChatEmpty_nrb34_561`,podChatSendBtn:`_podChatSendBtn_nrb34_573`,podChatSendBtnActive:`_podChatSendBtnActive_nrb34_589`,discoverSection:`_discoverSection_nrb34_597`,discoverSectionLabel:`_discoverSectionLabel_nrb34_603`,discoverWrap:`_discoverWrap_nrb34_611`,discoverSearchRow:`_discoverSearchRow_nrb34_617`,discoverInputWrap:`_discoverInputWrap_nrb34_624`,discoverSearchIcon:`_discoverSearchIcon_nrb34_630`,discoverInput:`_discoverInput_nrb34_624`,discoverFilterGroup:`_discoverFilterGroup_nrb34_656`,discoverFilterGroupLabel:`_discoverFilterGroupLabel_nrb34_663`,discoverPillRow:`_discoverPillRow_nrb34_672`,discoverPill:`_discoverPill_nrb34_672`,discoverPillActive:`_discoverPillActive_nrb34_692`,discoverNote:`_discoverNote_nrb34_699`,discoverGrid:`_discoverGrid_nrb34_706`,discoverCard:`_discoverCard_nrb34_712`,discoverCardTop:`_discoverCardTop_nrb34_724`,discoverAvatar:`_discoverAvatar_nrb34_730`,discoverInfo:`_discoverInfo_nrb34_747`,discoverName:`_discoverName_nrb34_755`,discoverProduct:`_discoverProduct_nrb34_765`,mutualBadge:`_mutualBadge_nrb34_771`,discoverTags:`_discoverTags_nrb34_785`,discoverTag:`_discoverTag_nrb34_785`,discoverTagStreak:`_discoverTagStreak_nrb34_800`,discoverActions:`_discoverActions_nrb34_805`,discoverInviteBtn:`_discoverInviteBtn_nrb34_811`,discoverConnectBtn:`_discoverConnectBtn_nrb34_829`,discoverEmpty:`_discoverEmpty_nrb34_844`,discoverCardMe:`_discoverCardMe_nrb34_853`,discoverConnectedBtn:`_discoverConnectedBtn_nrb34_857`,communitySection:`_communitySection_nrb34_872`,communitySectionLabel:`_communitySectionLabel_nrb34_879`,lbWrap:`_lbWrap_nrb34_889`,lbHeader:`_lbHeader_nrb34_897`,lbColRank:`_lbColRank_nrb34_907`,lbColName:`_lbColName_nrb34_908`,lbColStats:`_lbColStats_nrb34_909`,lbColConnect:`_lbColConnect_nrb34_910`,lbRow:`_lbRow_nrb34_918`,lbRowMe:`_lbRowMe_nrb34_931`,lbRank:`_lbRank_nrb34_936`,lbIdentity:`_lbIdentity_nrb34_944`,lbAvatar:`_lbAvatar_nrb34_951`,lbInfo:`_lbInfo_nrb34_968`,lbName:`_lbName_nrb34_975`,lbProduct:`_lbProduct_nrb34_988`,lbStats:`_lbStats_nrb34_997`,lbStatChip:`_lbStatChip_nrb34_1004`,lbConnectCell:`_lbConnectCell_nrb34_1014`,lbConnectBtn:`_lbConnectBtn_nrb34_1019`,lbConnectedBtn:`_lbConnectedBtn_nrb34_1035`,lbEmpty:`_lbEmpty_nrb34_1048`,profileOverlay:`_profileOverlay_nrb34_1064`,profileModal:`_profileModal_nrb34_1076`,dmModal:`_dmModal_nrb34_1092`,dmHeader:`_dmHeader_nrb34_1105`,dmHeaderName:`_dmHeaderName_nrb34_1113`,dmThread:`_dmThread_nrb34_1121`,dmInputRow:`_dmInputRow_nrb34_1122`,profileClose:`_profileClose_nrb34_1124`,profileHeader:`_profileHeader_nrb34_1144`,profileAvatarLg:`_profileAvatarLg_nrb34_1151`,profileMeta:`_profileMeta_nrb34_1168`,profileName:`_profileName_nrb34_1175`,profileProduct:`_profileProduct_nrb34_1183`,profileGoal:`_profileGoal_nrb34_1190`,profileTags:`_profileTags_nrb34_1199`,profileTag:`_profileTag_nrb34_1199`,profileLinks:`_profileLinks_nrb34_1214`,profileLink:`_profileLink_nrb34_1214`,profileStats:`_profileStats_nrb34_1227`,profileStat:`_profileStat_nrb34_1227`,profileStatNum:`_profileStatNum_nrb34_1246`,profileStatLabel:`_profileStatLabel_nrb34_1254`,profileShipped:`_profileShipped_nrb34_1262`,profileShippedLabel:`_profileShippedLabel_nrb34_1268`,profileActions:`_profileActions_nrb34_1277`,profileConnectBtn:`_profileConnectBtn_nrb34_1284`,profileConnectedBtn:`_profileConnectedBtn_nrb34_1300`,profileMessageBtn:`_profileMessageBtn_nrb34_1315`,profileIsMe:`_profileIsMe_nrb34_1330`,profileEditForm:`_profileEditForm_nrb34_1342`,profileEditLabel:`_profileEditLabel_nrb34_1350`,profileEditRow:`_profileEditRow_nrb34_1358`,avatarEditRow:`_avatarEditRow_nrb34_1363`,avatarUploadBtn:`_avatarUploadBtn_nrb34_1369`,profileEditSelect:`_profileEditSelect_nrb34_1381`,profileEditInput:`_profileEditInput_nrb34_1396`,profileEditPublicRow:`_profileEditPublicRow_nrb34_1411`,profileEditPublicLabel:`_profileEditPublicLabel_nrb34_1416`,profileEditSaveBtn:`_profileEditSaveBtn_nrb34_1426`,upgradePrompt:`_upgradePrompt_nrb34_1452`,upgradePromptTitle:`_upgradePromptTitle_nrb34_1463`,upgradePromptBody:`_upgradePromptBody_nrb34_1473`,upgradePromptTrial:`_upgradePromptTrial_nrb34_1481`,upgradePromptBtn:`_upgradePromptBtn_nrb34_1488`,podStreakBar:`_podStreakBar_nrb34_1507`,podStreakNum:`_podStreakNum_nrb34_1518`,podStreakLabel:`_podStreakLabel_nrb34_1525`,podStreakHint:`_podStreakHint_nrb34_1526`};function db({member:e}){let t=z(),{pct:n,total:r,streak:i,shipped:a,skipped:o,commits:s,prs:c}=e.this_week;return(0,R.jsxs)(`div`,{className:B(X.memberCard,e.is_me&&X.memberCardMe),children:[(0,R.jsxs)(`div`,{className:X.memberHeader,children:[(0,R.jsxs)(`div`,{className:X.memberIdentity,children:[(0,R.jsxs)(`span`,{className:X.memberName,children:[e.name,e.is_me&&(0,R.jsx)(`span`,{className:X.youTag,children:t(`you`)})]}),(0,R.jsx)(`span`,{className:X.memberProduct,children:e.product})]}),(0,R.jsxs)(`div`,{className:X.memberStats,children:[(0,R.jsxs)(`div`,{className:X.statChip,children:[(0,R.jsxs)(`span`,{className:X.statChipNum,children:[n,`%`]}),(0,R.jsx)(`span`,{className:X.statChipLabel,children:t(`done`)})]}),i>0&&(0,R.jsxs)(`div`,{className:X.statChip,children:[(0,R.jsx)(`span`,{className:X.statChipNum,children:i}),(0,R.jsx)(`span`,{className:X.statChipLabel,children:t(`streak`)})]}),s>0&&(0,R.jsxs)(`div`,{className:B(X.statChip,X.statChipGit),children:[(0,R.jsx)(Wm,{name:`gitCommit`,size:11}),(0,R.jsx)(`span`,{className:X.statChipNum,children:s})]}),c>0&&(0,R.jsxs)(`div`,{className:B(X.statChip,X.statChipGit),children:[(0,R.jsx)(Wm,{name:`git`,size:11}),(0,R.jsxs)(`span`,{className:X.statChipNum,children:[c,` pr`,c===1?``:`s`]})]})]})]}),e.is_me?(0,R.jsxs)(R.Fragment,{children:[a.length>0&&(0,R.jsxs)(`div`,{className:X.receiptBlock,children:[(0,R.jsx)(`span`,{className:X.receiptLabel,children:t(`shipped`)}),(0,R.jsx)(`ul`,{className:X.receiptList,children:a.map((e,n)=>(0,R.jsxs)(`li`,{className:X.receiptItem,children:[(0,R.jsx)(`span`,{className:X.dot,"data-done":`true`,"data-verified":e.verified?`true`:`false`,title:e.verified?t(`connector-verified`):t(`self-reported`)}),(0,R.jsx)(`span`,{className:X.receiptText,children:e.text}),e.proof&&(0,R.jsx)(`span`,{className:X.receiptProof,children:e.proof})]},n))})]}),o.length>0&&(0,R.jsxs)(`div`,{className:X.receiptBlock,children:[(0,R.jsx)(`span`,{className:X.receiptLabel,children:t(`slipped`)}),(0,R.jsx)(`ul`,{className:X.receiptList,children:o.map((e,t)=>(0,R.jsxs)(`li`,{className:X.receiptItem,children:[(0,R.jsx)(`span`,{className:X.dot}),(0,R.jsx)(`span`,{className:B(X.receiptText,X.receiptTextMuted),children:e.text}),(0,R.jsx)(`span`,{className:X.receiptCat,children:e.category})]},t))})]})]}):(a.length>0||o.length>0)&&(0,R.jsx)(`div`,{className:X.receiptBlock,children:(0,R.jsxs)(`span`,{className:X.receiptLabel,children:[t(`{n} shipped this week`).replace(`{n}`,String(a.length)),o.length>0?` · ${t(`{n} slipped`).replace(`{n}`,String(o.length))}`:``]})}),r===0&&(0,R.jsx)(`p`,{className:X.noData,children:e.is_me?t(`lock your 3 on the today page to appear here.`):t(`nothing locked this week yet.`)})]})}function fb({pod:e,myUserId:t}
66){let n=z(),[r,i]=(0,_.useState)([]),[a,o]=(0,_.useState)(``),[s,c]=(0,_.useState)(!1),l=(0,_.useRef)(null);(0,_.useEffect)(()=>{L.from(`pod_messages`).select(`id, user_id, body, created_at, profiles(name)`).eq(`pod_id`,e.id).order(`created_at`,{ascending:!0}).limit(100).then(({data:e})=>{e&&i(e.map(e=>({id:e.id,from:e.profiles?.name??`unknown`,text:e.body,ts:e.created_at,isMe:e.user_id===t})))})},[e.id,t]),(0,_.useEffect)(()=>{let n=L.channel(`pod_messages:${e.id}`).on(`postgres_changes`,{event:`INSERT`,schema:`public`,table:`pod_messages`,filter:`pod_id=eq.${e.id}`},async e=>{let n=e.new,{data:r}=await L.from(`profiles`).select(`name`).eq(`id`,n.user_id).maybeSingle();i(e=>e.some(e=>e.id===n.id)?e:[...e,{id:n.id,from:r?.name??`unknown`,text:n.body,ts:n.created_at,isMe:n.user_id===t}])}).subscribe();return()=>{L.removeChannel(n)}},[e.id,t]),(0,_.useEffect)(()=>{l.current?.scrollIntoView({behavior:`smooth`})},[r]);async function u(){let n=a.trim();!n||s||(c(!0),o(``),await L.from(`pod_messages`).insert({pod_id:e.id,user_id:t,body:n}),c(!1))}return(0,R.jsxs)(`div`,{className:X.podChatWrap,children:[(0,R.jsxs)(`div`,{className:X.podChatThread,children:[r.length===0&&(0,R.jsx)(`p`,{className:X.podChatEmpty,children:n(`no messages yet â say something to the pod.`)}),r.map(e=>(0,R.jsxs)(`div`,{className:B(X.podChatMsg,e.isMe&&X.podChatMsgMe),children:[!e.isMe&&(0,R.jsx)(`span`,{className:X.podChatSender,children:e.from}),(0,R.jsx)(`div`,{className:B(X.podChatBubble,e.isMe&&X.podChatBubbleMe),children:e.text})]},e.id)),(0,R.jsx)(`div`,{ref:l})]}),(0,R.jsxs)(`div`,{className:X.podChatInputRow,children:[(0,R.jsx)(`input`,{className:X.podChatInput,placeholder:n(`message the podâ¦`),value:a,onChange:e=>o(e.target.value),onKeyDown:e=>e.key===`Enter`&&u(),disabled:s}),(0,R.jsx)(`button`,{className:B(X.podChatSendBtn,a.trim()&&X.podChatSendBtnActive),onClick:u,"aria-label":n(`Send`),children:`â`})]})]})}function pb(){let e=z(),{session:t,profile:n}=ll(),{active:r}=wl(),i=t?.user.id;n?.plan;let[a,o]=(0,_.useState)(`board`),[s,c]=(0,_.useState)(null),[l,u]=(0,_.useState)(null),[d,f]=(0,_.useState)(0),[p,m]=(0,_.useState)(0),[h,g]=(0,_.useState)(!0),[v,y]=(0,_.useState)(!1),[b,x]=(0,_.useState)(null),[S,C]=(0,_.useState)(``),[w,T]=(0,_.useState)(!1),[E,D]=(0,_.useState)(``),[O,k]=(0,_.useState)(``),[A,j]=(0,_.useState)(!1),[ee,te]=(0,_.useState)(``),[ne,re]=(0,_.useState)(!1),M=(0,_.useCallback)(async e=>{y(!0),x(null);let{board:t,podStreak:n,podSize:r,error:i}=await fy(e);if(f(n),m(r),y(!1),i){x(i);return}u(t)},[]);(0,_.useEffect)(()=>{i&&cy(i).then(async({pod:e})=>{let t=(()=>{try{return localStorage.getItem(`crew.pendingJoin`)}catch{return null}})();if(t)try{localStorage.removeItem(`crew.pendingJoin`)}catch{}let n=new URLSearchParams(window.location.search).get(`join`)??t;if(!e&&n){let{pod:t,error:r}=await uy(n);window.history.replaceState({},``,`/app/crew`),t?e=t:r&&te(r.message)}c(e),g(!1),e&&M(e.id)})},[i,M]);async function N(t){if(t.preventDefault(),!S.trim()){D(e(`enter a pod name`));return}T(!0),D(``);let{pod:n,error:i}=await ly(S.trim(),r?.id);if(T(!1),i||!n){D(i?.message??e(`something went wrong`));return}c(n),o(`board`),M(n.id)}async function ie(t){if(t.preventDefault(),!O.trim()){te(e(`enter an invite code`));return}j(!0),te(``);let{pod:n,error:r}=await uy(O.trim());if(j(!1),r||!n){te(r?.message??e(`something went wrong`));return}c(n),o(`board`),M(n.id)}async function ae(){!s||!i||window.confirm(e(`leave this pod? you can rejoin with the invite code.`))&&(await dy(s.id,i),c(null),u(null),o(`board`))}function P(){if(!s)return;let e=`${window.location.origin}/app/crew?join=${s.invite_code}`;navigator.clipboard.writeText(e).then(()=>{re(!0),setTimeout(()=>re(!1),2e3)})}if(h)return(0,R.jsx)(`div`,{className:X.page,children:(0,R.jsx)(`span`,{className:X.heading,children:e(`your pod`)})});if(!s)return(0,R.jsxs)(`div`,{className:X.page,children:[(0,R.jsxs)(`div`,{className:X.pageHeader,children:[(0,R.jsx)(`span`,{className:X.heading,children:e(`your pod`)}),(0,R.jsx)(`p`,{className:X.intro,children:e(`a private duo â you + one other founder â seeing each other's verified receipts. done / skipped comes from Crew's verified verdicts â never self-reported.`)})]}
66),(0,R.jsxs)(`div`,{className:X.setupGrid,children:[(0,R.jsxs)(`div`,{className:X.setupCard,children:[(0,R.jsx)(`h2`,{className:X.setupTitle,children:e(`start a pod`)}),(0,R.jsxs)(`form`,{className:X.setupForm,onSubmit:N,children:[(0,R.jsx)(`input`,{className:X.setupInput,placeholder:e(`name your pod`),value:S,onChange:e=>{C(e.target.value),D(``)},maxLength:40,autoFocus:!0}),E&&(0,R.jsx)(`span`,{className:X.setupError,children:E}),(0,R.jsx)(`button`,{type:`submit`,className:X.setupBtn,disabled:w,children:e(w?`creatingâ¦`:`create pod â`)})]})]}),(0,R.jsxs)(`div`,{className:X.setupCard,children:[(0,R.jsx)(`h2`,{className:X.setupTitle,children:e(`join a pod`)}),(0,R.jsxs)(`form`,{className:X.setupForm,onSubmit:ie,children:[(0,R.jsx)(`input`,{className:B(X.setupInput,X.setupInputCode),placeholder:`ABC123`,value:O,onChange:e=>{k(e.target.value.toUpperCase()),te(``)},maxLength:8}),ee&&(0,R.jsx)(`span`,{className:X.setupError,children:ee}),(0,R.jsx)(`button`,{type:`submit`,className:X.setupBtn,disabled:A,children:e(A?`joiningâ¦`:`join â`)})]})]})]})]});let oe=(0,R.jsxs)(`div`,{className:X.tabs,children:[(0,R.jsx)(`button`,{className:B(X.tabBtn,a===`board`&&X.tabBtnActive),onClick:()=>o(`board`),children:e(`Board`)}),(0,R.jsx)(`button`,{className:B(X.tabBtn,a===`chat`&&X.tabBtnActive),onClick:()=>o(`chat`),children:e(`Pod Chat`)})]});return(0,R.jsxs)(`div`,{className:X.page,children:[(0,R.jsxs)(`div`,{className:X.podHeader,children:[(0,R.jsxs)(`div`,{className:X.podMeta,children:[(0,R.jsx)(`span`,{className:X.podName,children:s.name}),(0,R.jsx)(`span`,{className:X.podCount,children:(l?.length??1)===1?e(`{n} member`).replace(`{n}`,String(l?.length??1)):e(`{n} members`).replace(`{n}`,String(l?.length??1))})]}),(0,R.jsxs)(`div`,{className:X.podActions,children:[(l?.length??1)>=2?(0,R.jsxs)(`span`,{className:X.inviteLabel,children:[e(`duo complete`),` ð¤`]}):(0,R.jsxs)(`div`,{className:X.inviteRow,children:[(0,R.jsx)(`span`,{className:X.inviteLabel,children:e(`invite link`)}),(0,R.jsx)(`button`,{className:X.copyCodeBtn,onClick:P,children:e(ne?`link copied!`:`copy invite link`)})]}),(0,R.jsx)(`button`,{className:X.leaveBtn,onClick:ae,children:e(`leave`)})]})]}),oe,a===`board`&&(0,R.jsxs)(R.Fragment,{children:[v&&(0,R.jsx)(`p`,{className:X.boardStatus,children:e(`loading boardâ¦`)}),b&&(0,R.jsx)(`p`,{className:X.boardError,children:b}),!v&&l&&l.length>1&&(0,R.jsxs)(`div`,{className:X.podStreakBar,children:[(0,R.jsx)(`span`,{className:X.podStreakNum,children:d}),(0,R.jsx)(`span`,{className:X.podStreakLabel,children:d===1?e(`day where all {n} of you cleared the bar`).replace(`{n}`,String(p)):e(`days in a row where all {n} of you cleared the bar`).replace(`{n}`,String(p))}),d===0&&(0,R.jsx)(`span`,{className:X.podStreakHint,children:e(`one bad day ends it for everyone â that is the point`)})]}),!v&&l&&l.length>0&&(0,R.jsx)(`div`,{className:X.boardGrid,children:l.map(e=>(0,R.jsx)(db,{member:e},e.user_id))}),!v&&(l?.length??0)<=1&&(0,R.jsxs)(`div`,{className:X.soloNote,children:[(0,R.jsxs)(`p`,{children:[e(`copy your`),` `,(0,R.jsx)(`strong`,{children:e(`invite link`)}),` `,e(`(top right) and send it to one founder â clicking it forms your duo instantly.`)]}),(0,R.jsx)(`p`,{children:e(`the board unlocks the moment they join.`)})]})]}),a===`chat`&&(0,R.jsx)(fb,{pod:s,myUserId:i})]})}var mb={detail:`_detail_4jxhl_1`,subLabel:`_subLabel_4jxhl_7`,weekdays:`_weekdays_4jxhl_15`,day:`_day_4jxhl_16`,dayOn:`_dayOn_4jxhl_16`,reasonInput:`_reasonInput_4jxhl_39`,oneOffBtns:`_oneOffBtns_4jxhl_54`,offBtn:`_offBtn_4jxhl_55`,list:`_list_4jxhl_71`,listRow:`_listRow_4jxhl_72`,removeBtn:`_removeBtn_4jxhl_77`},hb=[{i:1,key:`Mon`},{i:2,key:`Tue`},{i:3,key:`Wed`},{i:4,key:`Thu`},{i:5,key:`Fri`},{i:6,key:`Sat`},{i:0,key:`Sun`}];function gb(){return new Date(Date.now()+864e5).toLocaleDateString(`en-CA`)}function _b(e){return new Date(e+`T12:00:00Z`).toLocaleDateString(`en-US`,{weekday:`short`,month:`short`,day:`numeric`,timeZone:`UTC`})}function vb({userId:e}){let t=z(),{weekdays:n,oneOffs:r,refresh:i}=xh(e),[a,o]=(0,_.useState)(n),[s,c]=(0,_.useState)(``),[l,u]=(0,_.useState)(!1);(0,_.useEffect)(()=>{o(n)},[n]);async function d(t){let n=a.includes(t)?a.filter(e=>e!==t):[...a,t].sort();o(n),u(!0),await vh(e,n),u(!1),i()}
66async function f(t){u(!0),await yh(e,t,s.trim()||null),c(``),u(!1),i()}async function p(e){u(!0),await bh(e),u(!1),i()}let m=rf(),h=gb(),g=r.some(e=>e.date===m),v=r.some(e=>e.date===h),y=r.filter(e=>e.date>=m);return(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`p`,{className:mb.detail,children:t(`days you don't work. Crew won't ask for tasks and your plant won't wilt on these days.`)}),(0,R.jsx)(`div`,{className:mb.subLabel,children:t(`recurring days off`)}),(0,R.jsx)(`div`,{className:mb.weekdays,children:hb.map(e=>(0,R.jsx)(`button`,{type:`button`,className:a.includes(e.i)?mb.dayOn:mb.day,onClick:()=>d(e.i),disabled:l,children:t(e.key)},e.i))}),(0,R.jsx)(`div`,{className:mb.subLabel,style:{marginTop:16},children:t(`one-off day off`)}),(0,R.jsx)(`input`,{className:mb.reasonInput,type:`text`,placeholder:t(`reason (optional) â e.g. wedding, sick, travel`),value:s,onChange:e=>c(e.target.value)}),(0,R.jsxs)(`div`,{className:mb.oneOffBtns,children:[(0,R.jsx)(`button`,{type:`button`,className:mb.offBtn,onClick:()=>f(m),disabled:l||g,children:t(g?`today: off â`:`I'm off today`)}),(0,R.jsx)(`button`,{type:`button`,className:mb.offBtn,onClick:()=>f(h),disabled:l||v,children:t(v?`tomorrow: off â`:`I'm off tomorrow`)})]}),y.length>0&&(0,R.jsx)(`ul`,{className:mb.list,children:y.map(e=>(0,R.jsxs)(`li`,{className:mb.listRow,children:[(0,R.jsxs)(`span`,{children:[_b(e.date),e.reason?` â ${e.reason}`:``]}),(0,R.jsx)(`button`,{type:`button`,className:mb.removeBtn,onClick:()=>p(e.id),disabled:l,children:t(`remove`)})]},e.id))})]})}var yb=`830235162870-5al9hqnhicpku86atagnt9n4nv39108k.apps.googleusercontent.com`;function bb(){return!0}async function xb(e=`/app/settings`){let{data:t,error:n}=await L.functions.invoke(`google-oauth-start`,{body:{returnTo:e}});if(n||!t?.state)return;let r=new URLSearchParams({client_id:yb,redirect_uri:`https://zwqymcoehifdzniztfzc.supabase.co/functions/v1/google-oauth-callback`,response_type:`code`,access_type:`offline`,prompt:`consent`,scope:`https://www.googleapis.com/auth/calendar.events`,state:t.state});window.location.href=`https://accounts.google.com/o/oauth2/v2/auth?${r.toString()}`}async function Sb(e){return L.from(`integrations`).select(`*`).eq(`user_id`,e).eq(`provider`,`google_calendar`).maybeSingle()}async function Cb(){let{data:e,error:t}=await L.functions.invoke(`google-calendars`);return t?{error:t.message}:e}async function wb(e){return L.from(`integrations`).update({calendar_id:e}).eq(`provider`,`google_calendar`)}async function Tb(){let{data:e,error:t}=await L.functions.invoke(`google-sync`);return t?{error:t.message}:e}async function Eb(){let e=await L.rpc(`disconnect_integration`,{p_provider:`google_calendar`});return e.error||il(`google_calendar`,!1),e}var Db=`eVZMSjhkX1JKcEFXSFZfZHM3VUw6MTpjaQ`;function Ob(){return!0}async function kb(e=`/app/settings`){let{data:t,error:n}=await L.functions.invoke(`x-oauth-start`,{body:{returnTo:e}});if(n||!t?.state||!t?.codeChallenge)return;let r=new URLSearchParams({response_type:`code`,client_id:Db,redirect_uri:`https://zwqymcoehifdzniztfzc.supabase.co/functions/v1/x-oauth-callback`,scope:`tweet.read users.read offline.access`,state:t.state,code_challenge:t.codeChallenge,code_challenge_method:`S256`});window.location.href=`https://x.com/i/oauth2/authorize?${r.toString()}`}async function Ab(e){return L.from(`integrations`).select(`*`).eq(`user_id`,e).eq(`provider`,`x`).maybeSingle()}async function jb(){let e=await L.rpc(`disconnect_integration`,{p_provider:`x`});return e.error||il(`x`,!1),e}function Mb(){return!1}async function Nb(e=`/app/settings`){}async function Pb(e){return L.from(`integrations`).select(`*`).eq(`user_id`,e).eq(`provider`,`discord`).maybeSingle()}async function Fb(){let{data:e,error:t}=await L.functions.invoke(`discord-channels`);return t?{error:t.message}:e}async function Ib(e){return L.from(`integrations`).update({discord_channel_id:e}).eq(`provider`,`discord`)}
66async function Lb(){let e=await L.rpc(`disconnect_integration`,{p_provider:`discord`});return e.error||il(`discord`,!1),e}async function Rb(e,t){let{data:n,error:r}=await L.functions.invoke(`vercel-connect`,{body:{token:e,teamId:t}});if(r)try{return{ok:!1,error:(await r.context.json()).error??r.message}}catch{return{ok:!1,error:r.message??String(r)}}return n?.ok?(il(`vercel`,!0),{ok:!0,username:n?.username||void 0}):{ok:!1,error:n?.error??`connection failed`}}async function zb(e){return L.from(`integrations`).select(`*`).eq(`user_id`,e).eq(`provider`,`vercel`).maybeSingle()}async function Bb(){let e=await L.rpc(`disconnect_integration`,{p_provider:`vercel`});return e.error||il(`vercel`,!1),e}async function Vb(){let{data:e,error:t}=await L.functions.invoke(`user-data`,{body:{action:`export`}});if(t)return{error:`export failed â try again`};let n=new Blob([JSON.stringify(e,null,2)],{type:`application/json`}),r=URL.createObjectURL(n);return Object.assign(document.createElement(`a`),{href:r,download:`crew-data-${new Date().toISOString().slice(0,10)}.json`}).click(),URL.revokeObjectURL(r),{}}async function Hb(){let{data:e,error:t}=await L.functions.invoke(`user-data`,{body:{action:`delete`}}),n=e;return t||n?.error?{error:n?.error??`deletion failed â try again`}:(await L.auth.signOut(),{})}async function Ub(e){let[t,n,r]=await Promise.all([L.from(`integrations`).select(`provider, scope, connected_at`).eq(`user_id`,e),L.from(`composio_connections`).select(`app_name, connected_account_id, connected_at`).eq(`user_id`,e),L.from(`tool_syncs`).select(`provider, last_synced, item_count`).eq(`user_id`,e)]),i=new Map;for(let e of r.data??[])i.set(e.provider.toLowerCase(),{last:e.last_synced,n:e.item_count});let a=[];for(let e of t.data??[]){let t=i.get(e.provider.toLowerCase());a.push({provider:e.provider,scope:e.scope??``,connectedAt:e.connected_at,lastRead:t?.last??null,itemCount:t?.n??null,kind:`native`})}for(let e of n.data??[]){let t=i.get(e.app_name.toLowerCase());a.push({provider:e.app_name,scope:``,connectedAt:e.connected_at,lastRead:t?.last??null,itemCount:t?.n??null,kind:`composio`,accountId:e.connected_account_id})}return a}var Wb={github:{reads:`your commits, PRs and events`,why:`to verify shipped code against your tasks`},google_calendar:{reads:`event titles and times (read-only)`,why:`to tell meetings apart from shipped work`},notion:{reads:`page titles you can access`,why:`to verify docs/notes tasks`},linear:{reads:`issue titles and states`,why:`to verify tickets marked done`},jira:{reads:`issue summaries and status`,why:`to verify tickets marked done`},hubspot:{reads:`deal names and stages`,why:`to verify sales tasks`},gmail:{reads:`sent-message metadata (subject/recipient)`,why:`to verify outreach â disabled pending Google verification`},x:{reads:`your own recent posts (owned reads only, never search)`,why:`to verify posting/marketing tasks`},discord:{reads:`messages in the one channel you point the bot at`,why:`to verify tasks discussed or logged there`}};function Gb(e){return Wb[e.toLowerCase()]??{reads:`recent activity in this tool`,why:`to verify related tasks`}}var Kb={section:`_section_1aafb_1`,sectionTitle:`_sectionTitle_1aafb_8`,intro:`_intro_1aafb_15`,tools:`_tools_1aafb_23`,empty:`_empty_1aafb_24`,tool:`_tool_1aafb_23`,toolTop:`_toolTop_1aafb_34`,toolName:`_toolName_1aafb_35`,roBadge:`_roBadge_1aafb_42`,lastRead:`_lastRead_1aafb_52`,disc:`_disc_1aafb_53`,consent:`_consent_1aafb_66`,rights:`_rights_1aafb_68`,exportBtn:`_exportBtn_1aafb_69`,deleteWrap:`_deleteWrap_1aafb_81`,delInput:`_delInput_1aafb_82`,deleteBtn:`_deleteBtn_1aafb_92`,msg:`_msg_1aafb_104`,links:`_links_1aafb_105`};function qb(e){if(!e)return`never`;let t=new Date(e);return isNaN(t.getTime())?`never`:t.toLocaleDateString(`en-US`,{month:`short`,day:`numeric`,hour:`2-digit`,minute:`2-digit`})}function Jb({userId:e}){let t=z(),[n,r]=(0,_.useState)([]),[i,a]=(0,_.useState)(null),[o,s]=(0,_.useState)(``),[c,l]=(0,_.useState)(``);async function u(){r(await Ub(e))}(0,_.useEffect)(()=>{u()},[e]);async function d(e){a(e.provider),e.kind===`native`&&e.provider.toLowerCase()===`github`?await Av():e.kind===`native`?await Eb():e.accountId&&await L.functions.invoke(`composio`,{body:{action:`disconnect`,account_id:e.accountId}}),await u(),a(null)}async function f(){a(`export`),s(``);let{error:e}=await Vb();s(e??t(`downloaded â check your files.`)),a(null)}async function p(){a(`delete`),s(``);let{error:e}=await Hb();if(e){s(e),a(null);return}window.location.href=`/`}return(0,R.jsxs)(`section`,{className:Kb.section,children:[(0,R.jsx)(`h2`,{className:Kb.sectionTitle,children:t(`privacy & data`)}),(0,R.jsx)(`p`,{className:Kb.intro,children:t(`everything Crew reads is read-only and revocable. here's exactly what's connected and when it was last read.`)}),(0,R.jsxs)(`div`,{className:Kb.tools,children:[n.length===0&&(0,R.jsx)(`p`,{className:Kb.empty,children:t(`nothing connected.`)}),n.map(e=>{let n=Gb(e.provider);return(0,R.jsxs)(`div`,{className:Kb.tool,children:[(0,R.jsxs)(`div`,{className:Kb.toolTop,children:[(0,R.jsx)(`span`,{className:Kb.toolName,children:e.provider.replace(/_/g,` `)}),(0,R.jsx)(`span`,{className:Kb.roBadge,children:t(`read-only`)}),(0,R.jsxs)(`span`,{className:Kb.lastRead,children:[t(`last read`),`: `,qb(e.lastRead)]}),(0,R.jsx)(`button`,{className:Kb.disc,disabled:i===e.provider,onClick:()=>d(e),children:i===e.provider?`â¦`:t(`disconnect`)})]}),(0,R.jsxs)(`span`,{className:Kb.consent,children:[t(`reads`),`: `,n.reads,`. `,t(`why`),`: `,n.why,`.`]})]},`${e.kind}-${e.provider}`)})]}),(0,R.jsxs)(`div`,{className:Kb.rights,children:[(0,R.jsx)(`button`,{className:Kb.exportBtn,disabled:!!i,onClick:f,children:t(i===`export`?`preparingâ¦`:`export my data (JSON)`)}),(0,R.jsxs)(`div`,{className:Kb.deleteWrap,children:[(0,R.jsx)(`input`,{className:Kb.delInput,placeholder:t(`type DELETE to confirm`),value:c,onChange:e=>l(e.target.value)}),(0,R.jsx)(`button`,{className:Kb.deleteBtn,disabled:i===`delete`||c.trim().toUpperCase()!==`DELETE`,onClick:p,children:t(i===`delete`?`deletingâ¦`:`delete my account`)})]})]}),o&&(0,R.jsx)(`p`,{className:Kb.msg,children:o}),(0,R.jsxs)(`p`,{className:Kb.links,children:[(0,R.jsx)(Rn,{to:`/privacy`,children:t(`privacy policy`)}),` · `,(0,R.jsx)(Rn,{to:`/subprocessors`,children:t(`subprocessors`)}),void 0]})]})}var Yb=`BBZxbEuLMLfzhoRPMHZ9Z8zeViyRs76jdlHMVcS-PMiTZc3FbrnPqPGi1N09miE3AgWvm7qmTY8chYVqsE4l-CY`,Xb=L;function Zb(e){let t=(e+`=`.repeat((4-e.length%4)%4)).replace(/-/g,`+`).replace(/_/g,`/`),n=atob(t),r=new Uint8Array(n.length);for(let e=0;e<n.length;e++)r[e]=n.charCodeAt(e);return r}function Qb(){return typeof navigator<`u`&&`serviceWorker`in navigator&&`PushManager`in window&&!0}async function $b(e){if(!Qb())return{error:`web push isn't available on this browser`};if(await Notification.requestPermission()!==`granted`)return{error:`n
66otifications are blocked â enable them in your browser`};let t=await navigator.serviceWorker.register(`/sw.js`);await navigator.serviceWorker.ready;let n=(await t.pushManager.subscribe({userVisibleOnly:!0,applicationServerKey:Zb(Yb)})).toJSON();if(!n.endpoint||!n.keys?.p256dh||!n.keys?.auth)return{error:`subscription failed`};let{error:r}=await Xb.from(`push_subscriptions`).upsert({user_id:e,endpoint:n.endpoint,p256dh:n.keys.p256dh,auth:n.keys.auth},{onConflict:`user_id,endpoint`,ignoreDuplicates:!0});return r?{error:`could not save subscription`}:{}}async function ex(){try{let e=await(await navigator.serviceWorker.getRegistration())?.pushManager.getSubscription();e&&(await Xb.from(`push_subscriptions`).delete().eq(`endpoint`,e.endpoint),await e.unsubscribe())}catch{}}var tx={section:`_section_1trzn_1`,title:`_title_1trzn_8`,intro:`_intro_1trzn_15`,row:`_row_1trzn_21`,label:`_label_1trzn_31`,note:`_note_1trzn_32`,toggle:`_toggle_1trzn_33`,toggleOn:`_toggleOn_1trzn_33`,msg:`_msg_1trzn_46`,numberRow:`_numberRow_1trzn_47`,numberInput:`_numberInput_1trzn_53`,numberSave:`_numberSave_1trzn_64`},nx=L;function rx({label:e,on:t,onClick:n,disabled:r,note:i}){return(0,R.jsxs)(`div`,{className:tx.row,children:[(0,R.jsxs)(`span`,{className:tx.label,children:[e,i?(0,R.jsxs)(`em`,{className:tx.note,children:[` · `,i]}):null]}),(0,R.jsx)(`button`,{className:t?tx.toggleOn:tx.toggle,onClick:n,disabled:r,children:t?`on`:`off`})]})}function ix({userId:e}){let t=z(),[n,r]=(0,_.useState)(!0),[i,a]=(0,_.useState)(!0),[o,s]=(0,_.useState)(!1),[c,l]=(0,_.useState)(!1),[u,d]=(0,_.useState)(``);(0,_.useEffect)(()=>{nx.from(`profiles`).select(`notify_email, notify_telegram, notify_webpush`).eq(`id`,e).maybeSingle().then(({data:e})=>{e&&(r(e.notify_email??!0),a(e.notify_telegram??!0),s(e.notify_webpush??!1))})},[e]);let f=t=>nx.from(`profiles`).update(t).eq(`id`,e);async function p(){if(l(!0),d(``),o)await ex(),s(!1),await f({notify_webpush:!1});else{let{error:t}=await $b(e);if(t){d(t),l(!1);return}s(!0),await f({notify_webpush:!0})}l(!1)}return(0,R.jsxs)(`section`,{className:tx.section,children:[(0,R.jsx)(`h2`,{className:tx.title,children:t(`notification channels`)}),(0,R.jsx)(`p`,{className:tx.intro,children:t(`choose how Crew reaches you â Telegram is no longer required.`)}),(0,R.jsx)(rx,{label:t(`email`),on:n,onClick:()=>{let e=!n;r(e),f({notify_email:e})}}),(0,R.jsx)(rx,{label:t(`telegram`),on:i,onClick:()=>{let e=!i;a(e),f({notify_telegram:e})}}),(0,R.jsx)(rx,{label:t(`web push (this device)`),on:o,onClick:p,disabled:c||!Qb(),note:Qb()?``:t(`not supported here`)}),u&&(0,R.jsx)(`p`,{className:tx.msg,children:u})]})}var Z={page:`_page_vgjz2_1`,heading:`_heading_vgjz2_12`,catMenu:`_catMenu_vgjz2_22`,catCard:`_catCard_vgjz2_27`,catCardLabel:`_catCardLabel_vgjz2_45`,catCardDesc:`_catCardDesc_vgjz2_52`,catCardArrow:`_catCardArrow_vgjz2_59`,detailHead:`_detailHead_vgjz2_70`,backBtn:`_backBtn_vgjz2_76`,detailTitle:`_detailTitle_vgjz2_93`,catHidden:`_catHidden_vgjz2_104`,section:`_section_vgjz2_101`,sectionTitle:`_sectionTitle_vgjz2_114`,sectionCard:`_sectionCard_vgjz2_123`,fieldRow:`_fieldRow_vgjz2_136`,field:`_field_vgjz2_136`,label:`_label_vgjz2_148`,input:`_input_vgjz2_156`,saveRow:`_saveRow_vgjz2_171`,saveBtn:`_saveBtn_vgjz2_177`,pwHint:`_pwHint_vgjz2_198`,savedMsg:`_savedMsg_vgjz2_205`,integRow:`_integRow_vgjz2_216`,integLogo:`_integLogo_vgjz2_227`,integIcon:`_integIcon_vgjz2_244`,integInfo:`_integInfo_vgjz2_256`,integLabel:`_integLabel_vgjz2_264`,integDetail:`_integDetail_vgjz2_270`,integRight:`_integRight_vgjz2_276`,connectedBadge:`_connectedBadge_vgjz2_283`,connectedDot:`_connectedDot_vgjz2_292`,connectBtn:`_connectBtn_vgjz2_299`,disconnectBtn:`_disconnectBtn_vgjz2_320`,detailsBtn:`_detailsBtn_vgjz2_335`,connectorsGroupLabel:`_connectorsGroupLabel_vgjz2_349`,detailFacts:`_detailFacts_vgjz2_359`,detailFactRow:`_detailFactRow_vgjz2_368`,detailFactLabel:`_detailFactLabel_vgjz2_375`,detailFactVal:`_detailFactVal_vgjz2_376`,detailFactMono:`_detailFactMono_vgjz2_377`,composioLockBtn:`_composioLockBtn_vgjz2_379`,repoSubRow:`_repoSubRow_vgjz2_400`,repoSelect:`_repoSelect_vgjz2_407`,repoName:`_repoName_vgjz2_418`,syncBtn:`_syncBtn_vgjz2_424`,syncNote:`_syncNote_vgjz2_442`,integBanner:`_integBanner_vgjz2_448`,integBannerOk:`_integBannerOk_vgjz2_456`,integBannerErr:`_integBannerErr_vgjz2_461`,pingRow:`_pingRow_vgjz2_468`,divider:`_divider_vgjz2_474`,pingInfo:`_pingInfo_vgjz2_479`,pingLabel:`_pingLabel_vgjz2_486`,pingDetail:`_pingDetail_vgjz2_492`,timeInput:`_timeInput_vgjz2_498`,tzSelect:`_tzSelect_vgjz2_515`,phoneInput:`_phoneInput_vgjz2_535`,themeRow:`_themeRow_vgjz2_554`,planRow:`_planRow_vgjz2_562`,planInfo:`_planInfo_vgjz2_568`,planBadge:`_planBadge_vgjz2_576`,planBadgeTrial:`_planBadgeTrial_vgjz2_590`,planBadgePaid:`_planBadgePaid_vgjz2_596`,planNote:`_planNote_vgjz2_602`,manageBtn:`_manageBtn_vgjz2_608`,upgradeGrid:`_upgradeGrid_vgjz2_623`,upgradeCard:`_upgradeCard_vgjz2_630`,upgradeCardFeatured:`_upgradeCardFeatured_vgjz2_640`,upgradeCardTop:`_upgradeCardTop_vgjz2_645`,upgradeName:`_upgradeName_vgjz2_651`,upgradePrice
66:`_upgradePrice_vgjz2_658`,upgradeFeatures:`_upgradeFeatures_vgjz2_671`,upgradeBtns:`_upgradeBtns_vgjz2_695`,upgradeBtn:`_upgradeBtn_vgjz2_695`,upgradeBtnAlt:`_upgradeBtnAlt_vgjz2_717`,billingError:`_billingError_vgjz2_730`,billingNote:`_billingNote_vgjz2_736`,contextArea:`_contextArea_vgjz2_744`,fieldHint:`_fieldHint_vgjz2_766`,taskCountRow:`_taskCountRow_vgjz2_772`,taskCountBtn:`_taskCountBtn_vgjz2_778`,taskCountValue:`_taskCountValue_vgjz2_792`,langPickerRow:`_langPickerRow_vgjz2_802`,langPickerBtn:`_langPickerBtn_vgjz2_807`,langPickerBtnActive:`_langPickerBtnActive_vgjz2_820`,communityToggle:`_communityToggle_vgjz2_829`,communitySlider:`_communitySlider_vgjz2_845`,companyList:`_companyList_vgjz2_884`,companyRow:`_companyRow_vgjz2_886`,companyRowActive:`_companyRowActive_vgjz2_896`,companyDot:`_companyDot_vgjz2_898`,companyDotActive:`_companyDotActive_vgjz2_904`,companyName:`_companyName_vgjz2_906`,companyActions:`_companyActions_vgjz2_908`,companyEditForm:`_companyEditForm_vgjz2_910`,disconnectBtnDanger:`_disconnectBtnDanger_vgjz2_912`,composioGrid:`_composioGrid_vgjz2_916`,composioCard:`_composioCard_vgjz2_922`,composioIcon:`_composioIcon_vgjz2_934`,composioInfo:`_composioInfo_vgjz2_947`,composioLabel:`_composioLabel_vgjz2_949`,composioDesc:`_composioDesc_vgjz2_955`,composioNote:`_composioNote_vgjz2_963`,composioNoteIcon:`_composioNoteIcon_vgjz2_964`,modalOverlay:`_modalOverlay_vgjz2_967`,modalOverlayNested:`_modalOverlayNested_vgjz2_986`,modalBox:`_modalBox_vgjz2_990`,modalLogo:`_modalLogo_vgjz2_1003`,modalTitle:`_modalTitle_vgjz2_1013`,modalBody:`_modalBody_vgjz2_1022`,modalActions:`_modalActions_vgjz2_1030`,modalCancel:`_modalCancel_vgjz2_1037`,modalConfirm:`_modalConfirm_vgjz2_1050`,toolsHeader:`_toolsHeader_vgjz2_1066`,toolsSearch:`_toolsSearch_vgjz2_1072`,composioLogo:`_composioLogo_vgjz2_1086`,composioLogoMask:`_composioLogoMask_vgjz2_1097`,composioLogoLetter:`_composioLogoLetter_vgjz2_1113`,viewAllBtn:`_viewAllBtn_vgjz2_1122`,connectorsModalBox:`_connectorsModalBox_vgjz2_1140`,connectorsModalHeader:`_connectorsModalHeader_vgjz2_1155`,connectorGrid:`_connectorGrid_vgjz2_1161`,connectorCard:`_connectorCard_vgjz2_1169`,connectorCardIcon:`_connectorCardIcon_vgjz2_1180`,connectorCardLabel:`_connectorCardLabel_vgjz2_1187`,connectorCardDesc:`_connectorCardDesc_vgjz2_1194`,extActions:`_extActions_vgjz2_1211`,extGuideBtn:`_extGuideBtn_vgjz2_1219`,extZipLink:`_extZipLink_vgjz2_1238`,extTokenLabel:`_extTokenLabel_vgjz2_1248`,extSmallBtn:`_extSmallBtn_vgjz2_1254`,extCopyBtn:`_extCopyBtn_vgjz2_1269`,extCopyBtnDone:`_extCopyBtnDone_vgjz2_1270`,extCopyOk:`_extCopyOk_vgjz2_1290`,extStatus:`_extStatus_vgjz2_1297`,tgAside:`_tgAside_vgjz2_1306`,tgError:`_tgError_vgjz2_1313`,ctxReminder:`_ctxReminder_vgjz2_1322`,ctxReminderText:`_ctxReminderText_vgjz2_1333`,ctxReminderBtn:`_ctxReminderBtn_vgjz2_1340`,verifyWarn:`_verifyWarn_vgjz2_1354`,verifyWarnText:`_verifyWarnText_vgjz2_1365`,verifyWarnActions:`_verifyWarnActions_vgjz2_1373`,verifyWarnOff:`_verifyWarnOff_vgjz2_1380`,verifyWarnKeep:`_verifyWarnKeep_vgjz2_1394`,repoChip:`_repoChip_vgjz2_1408`,repoChipRemove:`_repoChipRemove_vgjz2_1421`,tokenReveal:`_tokenReveal_vgjz2_1436`,tokenRevealWarn:`_token
66RevealWarn_vgjz2_1443`,tokenValue:`_tokenValue_vgjz2_1444`,tokenList:`_tokenList_vgjz2_1451`,tokenRow:`_tokenRow_vgjz2_1452`,tokenName:`_tokenName_vgjz2_1457`,tokenMeta:`_tokenMeta_vgjz2_1458`,tokenRevoke:`_tokenRevoke_vgjz2_1459`};function ax({userId:e,onContinue:t,onClose:n,onPaused:r}){let i=z(),[a,o]=(0,_.useState)(null),[s,c]=(0,_.useState)(!1);(0,_.useEffect)(()=>{Ph(e).then(o)},[e]);async function l(){c(!0),await Nh(e,30),c(!1),r()}return(0,R.jsx)(`div`,{className:Z.modalOverlay,onClick:n,children:(0,R.jsxs)(`div`,{className:Z.modalBox,onClick:e=>e.stopPropagation(),children:[(0,R.jsx)(`h3`,{className:Z.modalTitle,children:i(`before you go`)}),(0,R.jsxs)(`p`,{className:Z.modalBody,children:[a?i(`you've verified {v} tasks across {d} shipped days. this record â your proof of execution â deletes with you.`).replace(`{v}`,String(a.verified)).replace(`{d}`,String(a.days)):i(`this is your verified execution record â proof of what you actually shipped.`),` `,i(`need a break? take a`),` `,(0,R.jsx)(`strong`,{children:i(`30-day freeze`)}),` `,i(`instead: streak and history stay intact, no pings, pick up exactly where you left off.`)]}),(0,R.jsxs)(`div`,{className:Z.modalActions,children:[(0,R.jsx)(`button`,{className:Z.modalCancel,onClick:t,children:i(`continue to cancel`)}),(0,R.jsx)(`button`,{className:Z.modalConfirm,onClick:l,disabled:s,children:i(s?`pausingâ¦`:`pause 30 days`)})]})]})})}var ox={section:`_section_5yjyl_1`,titleRow:`_titleRow_5yjyl_8`,title:`_title_5yjyl_8`,intro:`_intro_5yjyl_16`,toggle:`_toggle_5yjyl_18`,toggleOn:`_toggleOn_5yjyl_18`,panel:`_panel_5yjyl_31`,dateRow:`_dateRow_5yjyl_33`,dateInput:`_dateInput_5yjyl_34`,dateBtn:`_dateBtn_5yjyl_44`,empty:`_empty_5yjyl_55`,row:`_row_5yjyl_57`,rowTop:`_rowTop_5yjyl_66`,taskText:`_taskText_5yjyl_67`,verdictNote:`_verdictNote_5yjyl_68`,statusRow:`_statusRow_5yjyl_70`,statusBtn:`_statusBtn_5yjyl_71`,statusBtnActiveDone:`_statusBtnActiveDone_5yjyl_84`,statusBtnActiveSkipped:`_statusBtnActiveSkipped_5yjyl_85`,statusBtnActivePending:`_statusBtnActivePending_5yjyl_86`,msg:`_msg_5yjyl_88`};function sx(){let e=new Date;return e.setDate(e.getDate()-1),e.toLocaleDateString(`en-CA`)}var cx={done:ox.statusBtnActiveDone,skipped:ox.statusBtnActiveSkipped,pending:ox.statusBtnActivePending,planned:ox.statusBtnActivePending};function lx({userId:e}){let t=z(),[n,r]=(0,_.useState)(!1),[i,a]=(0,_.useState)(sx()),[o,s]=(0,_.useState)([]),[c,l]=(0,_.useState)(!1),[u,d]=(0,_.useState)(null);(0,_.useEffect)(()=>{n&&(l(!0),eb(e,i).then(e=>{s(e),l(!1)}))},[n,e,i]);async function f(t,n,r){d(t),await tb(e,t,n,r),s(e=>e.map(e=>e.priorityId===t?{...e,status:r}:e)),d(null)}return(0,R.jsxs)(`section`,{className:ox.section,children:[(0,R.jsxs)(`div`,{className:ox.titleRow,children:[(0,R.jsx)(`h2`,{className:ox.title,children:t(`admin mode`)}),(0,R.jsx)(`button`,{className:n?ox.toggleOn:ox.toggle,onClick:()=>r(e=>!e),children:t(n?`on`:`off`)})]}),n&&(0,R.jsxs)(`div`,{className:ox.panel,children:[(0,R.jsx)(`p`,{className:ox.intro,children:t(`correct a verdict crew got wrong on a past day â for fixing test runs, not for real streak history.`)}),(0,R.jsxs)(`div`,{className:ox.dateRow,children:[(0,R.jsx)(`input`,{type:`date`,className:ox.dateInput,value:i,max:rf(),onChange:e=>a(e.target.value)}),(0,R.jsx)(`button`,{className:ox.dateBtn,onClick:()=>a(sx()),children:t(`yesterday`)}),(0,R.jsx)(`button`,{className:ox.dateBtn,onClick:()=>a(rf()),children:t(`today`)})]}),c&&(0,R.jsx)(`p`,{className:ox.empty,children:t(`loadingâ¦`)}),!c&&o.length===0&&(0,R.jsx)(`p`,{className:ox.empty,children:t(`no tasks locked for this day.`)}),!c&&o.map(e=>(0,R.jsxs)(`div`,{className:ox.row,children:[(0,R.jsxs)(`div`,{className:ox.rowTop,children:[(0,R.jsx)(`span`,{className:ox.taskText,children:e.text}),e.verdict&&(0,R.jsxs)(`span`,{className:ox.verdictNote,children:[t(`crew judged`),`: `,e.verdict,e.confidence==null?``:` (${Math.round(e.confidence*100)}%)`]})]}),(0,R.jsx)(`div`,{className:ox.statusRow,children:[`done`,`skipped`,`pending`].map(n=>(0,R.jsx)(`button`,{className:B(ox.statusBtn,e.status===n&&cx[n]),disabled:u===e.priorityId,onClick:()=>f(e.priorityId,e.judgmentId,n),children:t(n)},n))})]},e.priorityId))]})]})}
66var ux=[{group:`Americas`,zones:[{value:`America/New_York`,label:`Eastern Time (US & Canada)`},{value:`America/Chicago`,label:`Central Time (US & Canada)`},{value:`America/Denver`,label:`Mountain Time (US & Canada)`},{value:`America/Los_Angeles`,label:`Pacific Time (US & Canada)`},{value:`America/Anchorage`,label:`Alaska`},{value:`Pacific/Honolulu`,label:`Hawaii`},{value:`America/Toronto`,label:`Toronto`},{value:`America/Vancouver`,label:`Vancouver`},{value:`America/Montreal`,label:`Montréal`},{value:`America/Mexico_City`,label:`Mexico City`},{value:`America/Bogota`,label:`Bogotá`},{value:`America/Lima`,label:`Lima`},{value:`America/Santiago`,label:`Santiago`},{value:`America/Sao_Paulo`,label:`São Paulo`},{value:`America/Argentina/Buenos_Aires`,label:`Buenos Aires`}]},{group:`Europe`,zones:[{value:`Europe/London`,label:`London (GMT)`},{value:`Europe/Paris`,label:`Paris`},{value:`Europe/Berlin`,label:`Berlin`},{value:`Europe/Madrid`,label:`Madrid`},{value:`Europe/Rome`,label:`Rome`},{value:`Europe/Amsterdam`,label:`Amsterdam`},{value:`Europe/Brussels`,label:`Brussels`},{value:`Europe/Zurich`,label:`Zurich`},{value:`Europe/Stockholm`,label:`Stockholm`},{value:`Europe/Oslo`,label:`Oslo`},{value:`Europe/Helsinki`,label:`Helsinki`},{value:`Europe/Warsaw`,label:`Warsaw`},{value:`Europe/Prague`,label:`Prague`},{value:`Europe/Bucharest`,label:`Bucharest`},{value:`Europe/Athens`,label:`Athens`},{value:`Europe/Istanbul`,label:`Istanbul`},{value:`Europe/Moscow`,label:`Moscow`},{value:`Europe/Kiev`,label:`Kyiv`}]},{group:`Middle East & Africa`,zones:[{value:`Asia/Dubai`,label:`Dubai (GST)`},{value:`Asia/Riyadh`,label:`Riyadh`},{value:`Africa/Cairo`,label:`Cairo`},{value:`Africa/Lagos`,label:`Lagos`},{value:`Africa/Nairobi`,label:`Nairobi`},{value:`Africa/Johannesburg`,label:`Johannesburg`}]},{group:`Asia / Pacific`,zones:[{value:`Asia/Kolkata`,label:`Mumbai / New Delhi (IST)`},{value:`Asia/Dhaka`,label:`Dhaka`},{value:`Asia/Bangkok`,label:`Bangkok`},{value:`Asia/Singapore`,label:`Singapore`},{value:`Asia/Kuala_Lumpur`,label:`Kuala Lumpur`},{value:`Asia/Jakarta`,label:`Jakarta`},{value:`Asia/Manila`,label:`Manila`},{value:`Asia/Hong_Kong`,label:`Hong Kong`},{value:`Asia/Shanghai`,label:`Beijing / Shanghai`},{value:`Asia/Seoul`,label:`Seoul`},{value:`Asia/Tokyo`,label:`Tokyo`},{value:`Australia/Sydney`,label:`Sydney`},{value:`Australia/Melbourne`,label:`Melbourne`},{value:`Australia/Perth`,label:`Perth`},{value:`Pacific/Auckland`,label:`Auckland`}]}],dx=ux.flatMap(e=>e.zones.map(e=>e.value)),fx=`[email protected]`,px=e=>`https://cdn.jsdelivr.net/npm/simple-icons@latest/icons/${e}.svg`,mx=[{name:`STRIPE`,label:`Stripe`,desc:`real charges â paying-customer proof`,logo:px(`stripe`),hex:`635BFF`},{name:`GMAIL`,label:`Gmail`,desc:`sent emails â outreach actually sent`,logo:px(`gmail`),hex:`EA4335`},{name:`OUTLOOK`,label:`Outlook`,desc:`sent mail from your Sent folder`,logo:px(`microsoftoutlook`),hex:`0078D4`},{name:`SLACK`,label:`Slack`,desc:`your own sent messages, never the channel`,logo:px(`slack`),hex:`4A154B`},{name:`CALENDLY`,label:`Calendly`,desc:`meetings actually booked`,logo:px(`calendly`),hex:`006BFF`},{name:`GOOGLEMEET`,label:`Google Meet`,desc:`calls that happened â a record, not an invite`,logo:px(`googlemeet`),hex:`00897B`},{name:`ZOOM`,label:`Zoom`,desc:`recordings â the meeting took place`,logo:px(`zoom`),hex:`0B5CFF`},{name:`HUBSPOT`,label:`HubSpot`,desc:`deals that moved stage`,logo:px(`hubspot`),hex:`FF7A59`},{name:`SALESFORCE`,label:`Salesforce`,desc:`opportunities you actually updated`,logo:px(`salesforce`),hex:`00A1E0`},{name:`INTERCOM`,label:`Intercom`,desc:`conversations you replied to`,logo:px(`intercom`),hex:`1F8DED`},{name:`ZENDESK`,label:`Zendesk`,desc:`tickets you closed`,logo:px(`zendesk`),hex:`03363D`},{name:`GITLAB`,label:`GitLab`,desc:`commits pushed, not branches opened`,logo:px(`gitlab`),hex:`FC6D26`},{name:`BITBUCKET`,label:`Bitbucket`,desc:`pull requests raised`,logo:px(`bitbucket`),hex:`0052CC`},{name:`LINEAR`,label:`Linear`,desc:`issues you moved`,logo:px(`linear`),hex:`5E6AD2`},{name:`JIRA`,label:`Jira`,desc:`issues updated, by you`,logo:px(`jira`),hex:`0052CC`},{name:`ASANA`,label:`Asana`,desc:`tasks completed`,logo:px(`asana`),hex:`F06A6A`},{name:`CLICKUP`,label:`ClickUp`,desc:`tasks closed`,logo:px(`clickup`),hex:`7B68EE`},{name:`TRELLO`,label:`Trello`,desc:`real card activity, not board names`,logo:px(`trello`),hex:`0052CC`},{name:`MONDAY`,label:`Monday`,desc:`items you moved on a board`,logo:``,hex:`FF3D57`,noIcon:!0},{name:`NOTION`,label:`Notion`,desc:`pages you actually edited`,logo:px(`notion`),hex:`000000`},{name:`CONFLUENCE`,label:`Confluence`,desc:`pages published`,logo:px(`confluence`),hex:`172B4D`},{name:`GOOGLEDOCS`,label:`Google Docs`,desc:`documents you edited today`,logo:px(`googledocs`),hex:`4285F4`},{name:`GOOGLESHEETS`,label:`Sheets`,desc:`spreadsheets you touched`,logo:px(`googlesheets`),hex:`34A853`},{name:`GOOGLEDRIVE`,label:`Drive`,desc:`files that appeared â work done off-browser`,logo:px(`googledrive`),hex:`4285F4`},{name:`DROPBOX`,label:`Dropbox`,desc:`files that landed â the desktop-work shadow`,logo:px(`dropbox`),hex:`0061FF`}
66,{name:`CANVA`,label:`Canva`,desc:`designs you published`,logo:px(`canva`),hex:`00C4CC`},{name:`MIRO`,label:`Miro`,desc:`boards you worked on`,logo:px(`miro`),hex:`FFD02F`},{name:`YOUTUBE`,label:`YouTube`,desc:`videos uploaded`,logo:px(`youtube`),hex:`FF0000`},{name:`INSTAGRAM`,label:`Instagram`,desc:`posts published`,logo:px(`instagram`),hex:`E4405F`},{name:`MAILCHIMP`,label:`Mailchimp`,desc:`campaigns sent, not drafted`,logo:px(`mailchimp`),hex:`FFE01B`},{name:`TYPEFORM`,label:`Typeform`,desc:`forms you shipped`,logo:px(`typeform`),hex:`262627`}],hx=[{key:`github`,label:`GitHub`,desc:`commits, PRs, deploy receipts`,logo:px(`github`),hex:`181717`,status:`live`},{key:`vercel`,label:`Vercel`,desc:`real deploys â shipped, not just committed`,logo:px(`vercel`),hex:`000000`,status:`live`},{key:`googlecalendar`,label:`Google Calendar`,desc:`events & schedules`,logo:px(`googlecalendar`),hex:`4285F4`,status:`live`}],gx=[`crew`,`connectors`,`notifications`,`companies`,`account`,`billing`];function _x(){let{session:e,profile:t,refreshProfile:n}=ll(),r=e?.user.id,i=z(),{lang:a,setLang:o}=ml(),[s,c]=(0,_.useState)(()=>{let e=window.location.hash.replace(`#`,``);return gx.includes(e)?e:null});(0,_.useEffect)(()=>{let e=()=>{let e=window.location.hash.replace(`#`,``);c(gx.includes(e)?e:null)};return window.addEventListener(`hashchange`,e),()=>window.removeEventListener(`hashchange`,e)},[]);function l(e){c(e);try{window.history.replaceState(null,``,`#${e}`)}catch{}}function u(){c(null);try{window.history.replaceState(null,``,window.location.pathname+window.location.search)}catch{}}let d=[{id:`crew`,label:i(`how crew works`),desc:i(`what your company does, how many tasks a day, whether proof is required`)},{id:`connectors`,label:i(`connectors`),desc:i(`the tools Crew reads to verify your work`)},{id:`notifications`,label:i(`notifications`),desc:i(`when Crew reaches you, and on which channel`)},{id:`companies`,label:i(`companies`),desc:i(`switch company, or add another`)},{id:`account`,label:i(`account`),desc:i(`your name, email, password and language`)},{id:`billing`,label:i(`billing`),desc:i(`your plan, invoices and payment`)}],f=e=>B(Z.section,s!==e&&Z.catHidden),[p,m]=(0,_.useState)(3);(0,_.useEffect)(()=>{let e=t?.daily_task_count;typeof e==`number`&&m(e)},[t]);async function h(e){let t=Math.max(3,Math.min(10,p+e));t===p||!r||(m(t),await L.from(`profiles`).update({daily_task_count:t}).eq(`id`,r))}let[g,v]=(0,_.useState)(!0),[y,b]=(0,_.useState)(!1);(0,_.useEffect)(()=>{let e=t?.verify_required;v(e!==!1)},[t]);async function x(e){r&&(v(e),b(!1),await L.from(`profiles`).update({verify_required:e}).eq(`id`,r))}let{workspaces:S,active:C,setActive:w,create:T,rename:E,remove:D}=wl(),[O,k]=(0,_.useState)(``),[A,j]=(0,_.useState)(!1),[ee,te]=(0,_.useState)(null),[ne,re]=(0,_.useState)(``),[M,N]=(0,_.useState)(null),[ie,ae]=(0,_.useState)(!1);async function P(e){e.preventDefault(),O.trim()&&(await T(O.trim()),k(``),j(!1))}async function oe(e){e.preventDefault(),!(!ee||!ne.trim())&&(await E(ee,ne.trim()),te(null))}async function se(){M&&(ae(!0),await D(M.id),ae(!1),N(null))}let[ce,le]=(0,_.useState)(null),[ue,de]=(0,_.useState)(!1),[fe,pe]=(0,_.useState)(!1),[me,he]=(0,_.useState)(!1),[ge,_e]=(0,_.useState)(!1),[ve,ye]=(0,_.useState)(null);async function be(){de(!0);let{data:e}=await L.functions.invoke(`extension-token`);if(le(e?.token??null),de(!1),r){let{data:e}=await L.from(`extension_tokens`).select(`last_seen_at`).eq(`user_id`,r).maybeSingle();ye(e?.last_seen_at??null)}}async function xe(){if(ce){_e(!1);try{await navigator.clipboard.writeText(ce),he(!0),setTimeout(()=>he(!1),2500)}catch{pe(!0),_e(!0)}}}async function Se(){if(!confirm(i(`This invalidates the old token â the extension will stop working until you paste the new one in its settings. Continue?`)))return;de(!0);let{data:e}=await L.functions.invoke(`extension-token`,{body:{action:`rotate`}});le(e?.token??null),pe(!0),ye(null),de(!1)}let[Ce,we]=(0,_.useState)([]),[Te,Ee]=(0,_.useState)(!1),[De,Oe]=(0,_.useState)(``),[ke,Ae]=(0,_.useState)(``),[je,Me]=(0,_.useState)(null),Ne=(0,_.useRef)(!1),[Pe,Fe]=(0,_.useState)(``),[Ie,Le]=(0,_.useState)(!1),[Re,ze]=(0,_.useState)([]),[Be,Ve]=(0,_.useState)(``),[He,Ue]=(0,_.useState)(!1);async function We(e){let{data:t,error:n}=await L.functions.invoke(`api-tokens`,{body:e});if(n)throw Error(n.message);return t}let Ge=(0,_.useCallback)(async()=>{try{ze((await We({action:`list`})).tokens??[])}catch{}},[]);(0,_.useEffect)(()=>{Ge()},[Ge]);async function Ke(e){Ue(!0);try{let t=await We({action:`create`,name:e===`write`?`read/write token`:`read-only token`,scope:e});typeof t.plaintext==`string`&&t.plaintext&&Ve(t.plaintext),await Ge()}catch(e){Ve(``),alert(e instanceof Error?e.message:String(e))}finally{Ue(!1)}}async function qe(e){if(confirm(i(`Revoke this token? Anything using it stops working immediately.`)))try{await We({action:`revoke`,id:e}),await Ge()}catch(e){alert(e instanceof Error?e.message:String(e))}}let[Je,Ye]=(0,_.useState)(null);async function Xe(e,t,n,i){Ye({label:e,logo:t,hex:n,provider:i,tool:null}),r&&Ye({label:e,logo:t,hex:n,provider:i,tool:(await Ub(r)).find(e=>e.provider.toLowerCase()===i.toLowerCase())??null})}async function Ze(e){let{data:t,error:n}=await L.functions.invoke(`composio`,{body:e});if(n)try{let e=await n.context.json();
66return{error:e.error??n.message,detail:e.detail??e}}catch{return{error:n.message??String(n)}}return t??{}}async function Qe(){if(!e)return;Ee(!0);let t=await Ze({action:`list`});!t.error&&Array.isArray(t.connections)&&we(t.connections.map(e=>({id:e.id,appName:e.appName??e.app_name,status:e.status??`active`}))),Ee(!1)}let $e=(0,_.useRef)(!1);(0,_.useEffect)(()=>{e&&!$e.current&&($e.current=!0,be())},[e]),(0,_.useEffect)(()=>{e&&!Ne.current&&(Ne.current=!0,Qe())},[e]);async function et(e){Ae(e),Oe(``);let t=await Ze({action:`connect`,app:e,redirect:`${window.location.origin}/app/settings?composio=connected`});if(t.url){window.location.href=t.url;return}else{let n=t.detail;Oe(`${e}: ${t.error??n?.message??`connection failed`}`),Me(null)}Ae(``)}async function tt(e){await Ze({action:`disconnect`,account_id:e}),we(t=>t.filter(t=>t.id!==e))}(0,_.useEffect)(()=>{let e=new URLSearchParams(window.location.search);if(e.get(`composio`)===`connected`){Qe(),e.delete(`composio`);let t=window.location.pathname+(e.toString()?`?${e}`:``);window.history.replaceState({},``,t)}},[]);let nt=t?.plan??`trial`;Bg(t?.trial_ends_at??null);let[rt,it]=(0,_.useState)(t?.name??``),[at,ot]=(0,_.useState)(e?.user.email??``),[st,ct]=(0,_.useState)(t?.product_name??``),[lt,ut]=(0,_.useState)(t?.crew_name??`crew`),[dt,ft]=(0,_.useState)(t?.ping_morning??`07:30`),[pt,mt]=(0,_.useState)(t?.ping_evening??`20:30`),[ht,gt]=(0,_.useState)(t?.ping_verify??`13:00`),[_t,vt]=(0,_.useState)(t?.timezone??Intl.DateTimeFormat().resolvedOptions().timeZone),yt=(0,_.useMemo)(()=>dx.includes(_t)?null:_t,[_t]),[bt,xt]=(0,_.useState)(!1),[St,Ct]=(0,_.useState)(!1),[wt,Tt]=(0,_.useState)(``),[Et,Dt]=(0,_.useState)(``),[Ot,kt]=(0,_.useState)(!1),[At,jt]=(0,_.useState)(!1),[Mt,Nt]=(0,_.useState)(null),Pt=H_(r??void 0,!!t?.telegram_chat_id),Ft=`crew.businessContext`,[It,Lt]=(0,_.useState)(()=>{try{return localStorage.getItem(Ft)??``}catch{return``}}),[Rt,zt]=(0,_.useState)(!1),Bt=(0,_.useRef)(!1);(0,_.useEffect)(()=>{if(Bt.current)return;let e=t?.business_context;if(typeof e==`string`){Bt.current=!0,Lt(e);try{localStorage.setItem(Ft,e)}catch{}}},[t]);async function Vt(){try{localStorage.setItem(Ft,It)}catch{}r&&await L.from(`profiles`).update({business_context:It}).eq(`id`,r),zt(!0),setTimeout(()=>zt(!1),2e3)}let[Ht,Ut]=(0,_.useState)(!1),[Wt,Gt]=(0,_.useState)([]),[Kt,qt]=(0,_.useState)(null),[Jt,Yt]=(0,_.useState)(!1),[Xt,Zt]=(0,_.useState)(null),[Qt,$t]=(0,_.useState)(!1),[en,tn]=(0,_.useState)(null),[nn,rn]=(0,_.useState)(null),[an,on]=(0,_.useState)(!1),[sn,cn]=(0,_.useState)(null),[ln,un]=(0,_.useState)(null),[dn,fn]=(0,_.useState)(!1),[pn,mn]=(0,_.useState)(null),[hn,gn]=(0,_.useState)(null),[_n,vn]=(0,_.useState)(null),[yn,bn]=(0,_.useState)(!1),[xn,Sn]=(0,_.useState)(null),[Cn,wn]=(0,_.useState)(!1),[Tn,En]=(0,_.useState)(``),[Dn,On]=(0,_.useState)(``),[kn,An]=(0,_.useState)(!1),[jn,Mn]=(0,_.useState)(null),[Nn,Pn]=(0,_.useState)(!1),[Fn,In]=(0,_.useState)(null),[Ln,Rn]=(0,_.useState)(null),[zn,Bn]=(0,_.useState)(!1),[Vn,Hn]=(0,_.useState)(null),[Un,Wn]=(0,_.useState)(null),[Gn,Kn]=(0,_.useState)(!1),[qn,Jn]=(0,_.useState)(null),[Yn,Xn]=(0,_.useState)(!1);(0,_.useEffect)(()=>{let e=new URLSearchParams(window.location.search),t=e.get(`github`),n=e.get(`gcal`),r=e.get(`billing`);t===`connected`&&tn({kind:`ok`,text:`github connected.`}),t===`error`&&tn({kind:`err`,text:`couldn't connect github â ${e.get(`reason`)??`unknown`}`}),n===`connected`&&Wn({kind:`ok`,text:`google calendar connected.`}),n===`error`&&Wn({kind:`err`,text:`couldn't connect google calendar â try again.`}),r===`success`&&rn({kind:`ok`,text:`you're subscribed. welcome to the paid plan.`}),r===`cancel`&&rn({kind:`err`,text:`checkout cancelled â still on trial.`});let i=e.get(`x`);i===`connected`&&un({kind:`ok`,text:`x connected.`}),i===`error`&&un({kind:`err`,text:`couldn't connect x â ${e.get(`reason`)??`unknown`}`});let a=e.get(`discord`);if(a===`connected`&&vn({kind:`ok`,text:`discord connected â pick a channel below.`}),a===`error`&&vn({kind:`err`,text:`couldn't connect discord â ${e.get(`reason`)??`unknown`}`}),t||n||r||i||a){e.delete(`github`),e.delete(`gcal`),e.delete(`billing`),e.delete(`x`),e.delete(`discord`),e.delete(`reason`);let t=window.location.pathname+(e.toString()?`?${e}`:``);window.history.replaceState({},``,t)}},[]),(0,_.useEffect)(()=>{r&&Ev(r).then(({data:e})=>{Ut(!!e);let t=e?.repo_full_names;Gt(t?.length?t:e?.repo_full_name?[e.repo_full_name]:[])})},[r]);async function Zn(){await Tv()}async function Qn(){await Av(),Ut(!1),Gt([]),qt(null),Yt(!1),Zt(null)}async function $n(){let{repos:e,error:t}=await Dv();if(t){tn({kind:`err`,text:t});return}qt(e??[])}(0,_.useEffect)(()=>{r&&Ab(r).then(({data:e})=>{on(!!e),cn(e?.x_username??null)})},[r]);async function er(){await kb()}async function tr(){await jb(),on(!1),cn(null)}(0,_.useEffect)(()=>{r&&Pb(r).then(({data:e})=>{fn(!!e),mn(e?.discord_channel_id??null)})},[r]);async function nr(){await Nb()}async function rr(){await Lb(),fn(!1),mn(null),gn(null)}async function ir(){let{channels:e,error:t}=await Fb();if(t){vn({kind:`err`,text:t});return}gn(e??[])}async function ar(e){await Ib(e),mn(e)}(0,_.useEffect)(()=>{r&&zb(r).then(({data:e})=>{bn(!!e),Sn(e?.vercel_username??null)})},[r]);async function or(){if(!Tn.trim())return;An(!0),Mn(null);let{ok:e,error:t,username:n}=await Rb(Tn.trim(),Dn.trim()||void 0);if(An(!1),!e){Mn({kind:`err`,text:t??`connection failed`});return}bn(!0),wn(!1),En(``),On(``),Sn(n||null)}async function sr(){await Bb(),bn(!1),Sn(null)}(0,_.useEffect)(()=>{r&&Sb(r).then(({data:e})=>{Pn(!!e),In(e?.calendar_id??null)})},[r]);async function cr(){await xb()}async function lr(){await Eb(),Pn(!1),In(null),Rn(null),Hn(null)}async function ur(){let{calendars:e,error:t}=await Cb();if(t){Wn({kind:`err`,text:t});return}Rn(e??[])}async function dr(e){await wb(e),In(e)}async function fr(){Bn(!0);let e=await Tb();if(Bn(!1),e.error){Hn(e.error);return}
66Hn(`synced ${e.events??0} events`)}async function pr(e){if(Wt.includes(e))return;let t=[...Wt,e];Gt(t),Yt(!1),await Ov(t)}async function mr(e){let t=Wt.filter(t=>t!==e);Gt(t),await Ov(t)}async function hr(){$t(!0);let e=await kv();if($t(!1),e.error){Zt(e.error);return}Zt(`synced ${e.commits??0} commits, ${e.prs??0} prs`)}async function gr(e){Kn(!0),Jn(null);let{error:t}=await Rg(Ig[e]);t&&(Jn(t),Kn(!1))}async function _r(){Kn(!0);let{error:e}=await zg();e&&(Jn(e),Kn(!1))}async function vr(e){e.preventDefault(),r&&(await L.from(`profiles`).update({name:rt,product_name:st,crew_name:lt||`crew`}).eq(`id`,r),await n(),xt(!0),setTimeout(()=>xt(!1),2e3))}async function yr(e){if(e.preventDefault(),jt(!1),Nt(null),wt.length<8){Nt(i(`password must be at least 8 characters.`));return}if(wt!==Et){Nt(i(`the two passwords don't match.`));return}kt(!0);let{error:t}=await L.auth.updateUser({password:wt});if(kt(!1),t){Nt(t.message||i(`could not update your password. try again.`));return}Tt(``),Dt(``),jt(!0),setTimeout(()=>jt(!1),4e3)}async function br(){r&&(await L.from(`profiles`).update({ping_morning:dt,ping_evening:pt,ping_verify:ht,timezone:_t}).eq(`id`,r),await n(),Ct(!0),setTimeout(()=>Ct(!1),2e3))}let xr=!!Ig.solo_monthly;function Sr(e){switch(e){case`github`:return Ht?(0,R.jsxs)(`div`,{className:Z.integRight,children:[(0,R.jsxs)(`span`,{className:Z.connectedBadge,children:[(0,R.jsx)(`span`,{className:Z.connectedDot}),i(`connected`)]}),(0,R.jsx)(`button`,{className:Z.disconnectBtn,onClick:Qn,children:i(`disconnect`)})]}):wv()?(0,R.jsx)(`button`,{className:Z.connectBtn,onClick:Zn,children:i(`connect`)}):(0,R.jsx)(`span`,{className:Z.integDetail,children:i(`not configured`)});case`x`:return an?(0,R.jsxs)(`div`,{className:Z.integRight,children:[(0,R.jsxs)(`span`,{className:Z.connectedBadge,children:[(0,R.jsx)(`span`,{className:Z.connectedDot}),i(`connected`)]}),(0,R.jsx)(`button`,{className:Z.disconnectBtn,onClick:tr,children:i(`disconnect`)})]}):Ob()?(0,R.jsx)(`button`,{className:Z.connectBtn,onClick:er,children:i(`connect`)}):(0,R.jsx)(`span`,{className:Z.integDetail,children:i(`not configured`)});case`discord`:return dn?(0,R.jsxs)(`div`,{className:Z.integRight,children:[(0,R.jsxs)(`span`,{className:Z.connectedBadge,children:[(0,R.jsx)(`span`,{className:Z.connectedDot}),i(`connected`)]}),(0,R.jsx)(`button`,{className:Z.disconnectBtn,onClick:rr,children:i(`disconnect`)})]}):Mb()?(0,R.jsx)(`button`,{className:Z.connectBtn,onClick:nr,children:i(`connect`)}):(0,R.jsx)(`span`,{className:Z.integDetail,children:i(`not configured`)});case`vercel`:return yn?(0,R.jsxs)(`div`,{className:Z.integRight,children:[(0,R.jsxs)(`span`,{className:Z.connectedBadge,children:[(0,R.jsx)(`span`,{className:Z.connectedDot}),i(`connected`)]}),(0,R.jsx)(`button`,{className:Z.disconnectBtn,onClick:sr,children:i(`disconnect`)})]}):(0,R.jsx)(`button`,{className:Z.connectBtn,onClick:()=>wn(e=>!e),children:i(`connect`)});case`googlecalendar`:return Nn?(0,R.jsxs)(`div`,{className:Z.integRight,children:[(0,R.jsxs)(`span`,{className:Z.connectedBadge,children:[(0,R.jsx)(`span`,{className:Z.connectedDot}),i(`connected`)]}),(0,R.jsx)(`button`,{className:Z.disconnectBtn,onClick:lr,children:i(`disconnect`)})]}):bb()?(0,R.jsx)(`button`,{className:Z.connectBtn,onClick:cr,children:i(`connect`)}):(0,R.jsx)(`span`,{className:Z.integDetail,children:i(`add VITE_GOOGLE_CLIENT_ID to enable`)});case`gmail`:{let e=Ce.find(e=>e.appName?.toUpperCase()===`GMAIL`);return e?(0,R.jsxs)(`div`,{className:Z.integRight,children:[(0,R.jsxs)(`span`,{className:Z.connectedBadge,children:[(0,R.jsx)(`span`,{className:Z.connectedDot}),i(`connected`)]}),(0,R.jsx)(`button`,{className:Z.disconnectBtn,onClick:()=>tt(e.id),children:i(`disconnect`)})]}):(0,R.jsx)(`button`,{className:Z.connectBtn,disabled:!!ke||Te,onClick:()=>{let e=mx.find(e=>e.name===`GMAIL`);if(!e){Le(!0);return}Me({name:`GMAIL`,label:e.label,desc:e.desc,logo:e.logo,hex:e.hex})},children:i(`connect`)})}default:return null}}function Cr(e){return e===`github`&&Ht?(0,R.jsxs)(`div`,{className:Z.repoSubRow,children:[Wt.map(e=>(0,R.jsxs)(`span`,{className:Z.repoChip,children:[e,(0,R.jsx)(`button`,{type:`button`,className:Z.repoChipRemove,onClick:()=>mr(e),"aria-label":i(`stop tracking {repo}`).replace(`{repo}`,e),title:i(`stop tracking {repo}`).replace(`{repo}`,e),children:`Ã`})]},e)),Jt&&Kt?(0,R.jsxs)(`select`,{className:Z.repoSelect,defaultValue:``,onChange:e=>e.target.value&&pr(e.target.value),children:[(0,R.jsx)(`option`,{value:``,disabled:!0,children:Wt.length?
66i(`add another repo`):i(`pick a repo to track`)}),Kt.filter(e=>!Wt.includes(e.full_name)).map(e=>(0,R.jsx)(`option`,{value:e.full_name,children:e.full_name},e.full_name))]}):(0,R.jsx)(`button`,{className:Z.syncBtn,onClick:async()=>{Kt||await $n(),Yt(!0)},children:Wt.length?`+ ${i(`add another repo`)}`:i(`pick a repo to track`)}),Wt.length>0&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`button`,{className:Z.syncBtn,onClick:hr,disabled:Qt,children:i(Qt?`syncingâ¦`:`sync now`)}),Xt&&(0,R.jsx)(`span`,{className:Z.syncNote,children:Xt})]})]}):e===`discord`&&dn?(0,R.jsx)(`div`,{className:Z.repoSubRow,children:pn?(0,R.jsxs)(`span`,{className:Z.repoName,children:[`#`,hn?.find(e=>e.id===pn)?.name??pn]}):hn?(0,R.jsxs)(`select`,{className:Z.repoSelect,defaultValue:``,onChange:e=>e.target.value&&ar(e.target.value),children:[(0,R.jsx)(`option`,{value:``,disabled:!0,children:i(`pick a channel to watch`)}),hn.map(e=>(0,R.jsxs)(`option`,{value:e.id,children:[`#`,e.name]},e.id))]}):(0,R.jsx)(`button`,{className:Z.syncBtn,onClick:ir,children:i(`pick a channel to watch`)})}):e===`vercel`&&Cn&&!yn?(0,R.jsxs)(`div`,{className:Z.repoSubRow,children:[(0,R.jsx)(`input`,{type:`password`,className:Z.repoSelect,placeholder:i(`paste your Vercel access token`),value:Tn,onChange:e=>En(e.target.value)}),(0,R.jsx)(`input`,{type:`text`,className:Z.repoSelect,placeholder:i(`team ID (optional, for team accounts)`),value:Dn,onChange:e=>On(e.target.value)}),(0,R.jsx)(`button`,{className:Z.syncBtn,onClick:or,disabled:kn||!Tn.trim(),children:i(kn?`connectingâ¦`:`connect`)}),jn&&(0,R.jsx)(`span`,{className:Z.syncNote,children:jn.text})]}):e===`vercel`&&yn&&xn?(0,R.jsx)(`div`,{className:Z.repoSubRow,children:(0,R.jsxs)(`span`,{className:Z.repoName,children:[`@`,xn]})}):e===`googlecalendar`&&Nn?(0,R.jsx)(`div`,{className:Z.repoSubRow,children:Fn?(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`span`,{className:Z.repoName,children:Fn}),(0,R.jsx)(`button`,{className:Z.syncBtn,onClick:fr,disabled:zn,children:i(zn?`syncingâ¦`:`sync now`)}),Vn&&(0,R.jsx)(`span`,{className:Z.syncNote,children:Vn})]}):Ln?(0,R.jsxs)(`select`,{className:Z.repoSelect,defaultValue:``,onChange:e=>e.target.value&&dr(e.target.value),children:[(0,R.jsx)(`option`,{value:``,disabled:!0,children:i(`pick a calendar to sync`)}),Ln.map(e=>(0,R.jsxs)(`option`,{value:e.id,children:[e.summary,e.primary?` (primary)`:``]},e.id))]}):(0,R.jsx)(`button`,{className:Z.syncBtn,onClick:ur,children:i(`pick a calendar to sync`)})}):null}function wr(e){switch(e){case`github`:return Ht;case`x`:return an;case`discord`:return dn;case`vercel`:return yn;case`googlecalendar`:return Nn;case`gmail`:return!!Ce.find(e=>e.appName?.toUpperCase()===`GMAIL`)}}function Tr(e){return e===`googlecalendar`?`google_calendar`:e===`gmail`?`GMAIL`:e}let Er=hx.map(e=>{let t=wr(e.key);return{key:`native-${e.key}`,label:e.label,desc:e.desc,logo:e.logo,hex:e.hex,connected:t,effectivelyLive:e.status===`live`||t,comingSoon:e.status===`coming_soon`&&!t,kind:`native`,nativeKey:e.key}}),Dr=mx.map(e=>{let t=Ce.find(t=>t.appName?.toUpperCase()===e.name);return{key:`composio-${e.name}`,label:e.label,desc:e.desc,logo:e.logo,hex:e.hex,connected:!!t,effectivelyLive:!0,comingSoon:!1,kind:`composio`,appDef:e,composioConn:t}}),Or=Pe.trim().toLowerCase(),kr=[...Er,...Dr].filter(e=>!Or||e.label.toLowerCase().includes(Or)||e.desc.toLowerCase().includes(Or)),Ar=kr.filter(e=>e.connected),jr=kr.filter(e=>!e.connected).sort((e,t)=>e.label.localeCompare(t.label)),Mr=jr.slice(0,6);function Nr(e){let t=e.kind===`native`?Tr(e.nativeKey):e.appDef.name;return(0,R.jsxs)(`div`,{children:[(0,R.jsxs)(`div`,{className:Z.integRow,children:[(0,R.jsx)(`div`,{className:Z.integIcon,children:(0,R.jsx)(`div`,{className:Z.integLogo,style:{"--lurl":`url('${e.logo}')`,"--lclr":`#${e.hex}`}})}),(0,R.jsxs)(`div`,{className:Z.integInfo,children:[(0,R.jsx)(`span`,{className:Z.integLabel,children:e.label}),(0,R.jsx)(`span`,{className:Z.integDetail,children:e.nativeKey===`x`&&sn?`@${sn}`:i(e.desc)})]}),e.kind===`native`?e.effectivelyLive?(0,R.jsxs)(`div`,{className:Z.integRight,children:[e.connected&&(0,R.jsx)(`button`,{className:Z.detailsBtn,onClick:()=>Xe(e.label,e.logo,e.hex,t),children:i(`details`)}),Sr(e.nativeKey)]}):(0,R.jsx)(`span`,{className:Z.integDetail,children:i(`coming soon`)}):e.composioConn?(0,R.jsxs)(`div`,{className:Z.integRight,children:[(0,R.jsx)(`button`,{className:Z.detailsBtn,onClick:()=>Xe(e.label,e.logo,e.hex,t),children:i(`details`)}),(0,R.jsxs)(`span`,{className:Z.connectedBadge,children:[(0,R.jsx)(`span`,{className:Z.connectedDot}),i(`connected`)]}),(0,R.jsx)(`button`,{className:Z.disconnectBtn,onClick:()=>tt(e.composioConn.id),children:i(`disconnect`)})]}):(0,R.jsx)(`button`,{className:Z.connectBtn,onClick:()=>Me(e.appDef),disabled:!!ke||Te,children:i(`connect`)})]}),e.kind===`native`&&e.effectivelyLive&&Cr(e.nativeKey)]},e.key)}function Pr(e){let t=e.kind===`native`&&!e.effectivelyLive;return(0,R.jsxs)(`div`,{className:Z.connectorCard,children:[(0,R.jsx)(`div`,{className:Z.connectorCardIcon,children:(0,R.jsx)(`div`,{className:Z.integLogo,style:{"--lurl":`url('${e.logo}')`,"--lclr":`#${e.hex}`}})}),(0,R.jsx)(`span`,{className:Z.connectorCardLabel,children:e.label}),(0,R.jsx)(`span`,{className:Z.connectorCardDesc,children:i(e.desc)}),t?(0,R.jsx)(`span`,{className:Z.integDetail,children:i(`coming soon`)}):e.kind===`native`?Sr(e.nativeKey):(0,R.jsx)(`button`,{className:Z.connectBtn,onClick:()=>Me(e.appDef),disabled:!!ke||Te,children:i(`connect`)})]},e.key)}return(0,R.jsxs)(`div`,{className:Z.page,children:[s?(0,R.jsxs)(`div`,{className:Z.detailHead,children:[(0,R.jsxs)(`button`,{type:`button`,className:Z.backBtn,onClick:u,children:[`â `,i(`settings`)]}),(0,R.jsx)(`span`,{className:Z.detailTitle,children:d.find(e=>e.id===s)?.label})]}):(0,R.jsx)(`span`,{className:Z.heading,children:i(`settings`)}),!s&&(0,R.jsx)(`div`,{className:Z.catMenu,children:d.map(e=>(0,R.jsxs)(`button`,{type:`button`,className:Z.catCard,onClick:()=>l(e.id),children:[(0,R.jsx)(`span`,{className:Z.catCardLabel,children:e.label}),(0,R.jsx)(`span`,{className:Z.catCardDesc,children:e.desc}
66),(0,R.jsx)(`span`,{className:Z.catCardArrow,"aria-hidden":!0,children:`â`})]},e.id))}),(0,R.jsxs)(`section`,{className:f(`companies`),children:[(0,R.jsx)(`h2`,{className:Z.sectionTitle,children:i(`companies`)}),(0,R.jsxs)(`div`,{className:Z.sectionCard,children:[S.length===0&&!A&&(0,R.jsx)(`p`,{className:Z.pingDetail,style:{marginBottom:12},children:i(`Add a company to keep priorities, goals, and context separate per project.`)}),(0,R.jsx)(`div`,{className:Z.companyList,children:S.map(e=>(0,R.jsx)(`div`,{className:B(Z.companyRow,C?.id===e.id&&Z.companyRowActive),children:ee===e.id?(0,R.jsxs)(`form`,{className:Z.companyEditForm,onSubmit:oe,children:[(0,R.jsx)(`input`,{autoFocus:!0,className:Z.input,value:ne,onChange:e=>re(e.target.value),onKeyDown:e=>e.key===`Escape`&&te(null),style:{flex:1}}),(0,R.jsx)(`button`,{type:`submit`,className:Z.saveBtn,style:{padding:`6px 14px`},children:i(`save`)}),(0,R.jsx)(`button`,{type:`button`,className:Z.disconnectBtn,onClick:()=>te(null),children:i(`cancel`)})]}):(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`span`,{className:B(Z.companyDot,C?.id===e.id&&Z.companyDotActive)}),(0,R.jsx)(`span`,{className:Z.companyName,children:e.name}),(0,R.jsxs)(`div`,{className:Z.companyActions,children:[C?.id!==e.id&&(0,R.jsx)(`button`,{className:Z.connectBtn,onClick:()=>w(e.id),children:i(`switch`)}),(0,R.jsx)(`button`,{className:Z.disconnectBtn,onClick:()=>{te(e.id),re(e.name)},children:i(`rename`)}),(0,R.jsx)(`button`,{className:B(Z.disconnectBtn,Z.disconnectBtnDanger),onClick:()=>N({id:e.id,name:e.name}),children:i(`delete`)})]})]})},e.id))}),A?(0,R.jsxs)(`form`,{className:Z.fieldRow,onSubmit:P,style:{marginTop:S.length?12:0},children:[(0,R.jsx)(`input`,{autoFocus:!0,className:Z.input,placeholder:i(`Company or project nameâ¦`),value:O,onChange:e=>k(e.target.value),onKeyDown:e=>e.key===`Escape`&&j(!1)}),(0,R.jsx)(`button`,{type:`submit`,className:Z.saveBtn,disabled:!O.trim(),children:i(`add`)}),(0,R.jsx)(`button`,{type:`button`,className:Z.disconnectBtn,onClick:()=>j(!1),children:i(`cancel`)})]}):(0,R.jsxs)(`div`,{className:Z.saveRow,style:{marginTop:S.length?12:0},children:[(0,R.jsx)(`button`,{type:`button`,className:Z.saveBtn,onClick:()=>j(!0),children:i(`+ add company`)}),C&&(0,R.jsx)(`button`,{type:`button`,className:Z.disconnectBtn,onClick:()=>w(null),children:i(`clear selection`)})]})]})]}),(0,R.jsxs)(`section`,{className:f(`account`),children:[(0,R.jsx)(`h2`,{className:Z.sectionTitle,children:i(`account`)}),(0,R.jsxs)(`form`,{className:Z.sectionCard,onSubmit:vr,children:[(0,R.jsxs)(`div`,{className:Z.fieldRow,children:[(0,R.jsxs)(`div`,{className:Z.field,children:[(0,R.jsx)(`label`,{className:Z.label,htmlFor:`s-name`,children:i(`name`)}),(0,R.jsx)(`input`,{id:`s-name`,className:Z.input,value:rt,onChange:e=>it(e.target.value)})]}),(0,R.jsxs)(`div`,{className:Z.field,children:[(0,R.jsx)(`label`,{className:Z.label,htmlFor:`s-email`,children:i(`email`)}),(0,R.jsx)(`input`,{id:`s-email`,className:Z.input,type:`email`,value:at,onChange:e=>ot(e.target.value)})]})]}),(0,R.jsxs)(`div`,{className:Z.fieldRow,children:[(0,R.jsxs)(`div`,{className:Z.field,children:[(0,R.jsx)(`label`,{className:Z.label,htmlFor:`s-product`,children:i(`product name`)}),(0,R.jsx)(`input`,{id:`s-product`,className:Z.input,value:st,onChange:e=>ct(e.target.value)})]}),(0,R.jsxs)(`div`,{className:Z.field,children:[(0,R.jsx)(`label`,{className:Z.label,htmlFor:`s-crew-name`,children:i(`crew name`)}),(0,R.jsx)(`input`,{id:`s-crew-name`,className:Z.input,value:lt,placeholder:`crew`,onChange:e=>ut(e.target.value)}),(0,R.jsx)(`span`,{className:Z.pingDetail,style:{marginTop:4,display:`block`},children:i(`how your AI co-founder signs off in Telegram`)})]})]}),(0,R.jsxs)(`div`,{className:Z.saveRow,children:[(0,R.jsx)(`button`,{type:`submit`,className:Z.saveBtn,children:i(`save changes`)}),bt&&(0,R.jsxs)(`span`,{className:Z.savedMsg,children:[(0,R.jsx)(Wm,{name:`check`,size:12}),` `,i(`saved`)]})]})]}),(0,R.jsxs)(`form`,{className:Z.sectionCard,onSubmit:yr,children:[(0,R.jsx)(`h3`,{className:Z.sectionTitle,children:i(`password`)}),(0,R.jsxs)(`div`,{className:Z.fieldRow,children:[(0,R.jsxs)(`div`,{className:Z.field,children:[(0,R.jsx)(`label`,{className:Z.label,htmlFor:`s-new-password`,children:i(`new password`)}),(0,R.jsx)(`input`,{id:`s-new-password`,className:Z.input,type:`password`,autoComplete:`new-password`,value:wt,onChange:e=>{Tt(e.target.value),Nt(null)}})]}),(0,R.jsxs)(`div`,{className:Z.field,children:[(0,R.jsx)(`label`,{className:Z.label,htmlFor:`s-confirm-password`,children:i(`confirm new password`)}),(0,R.jsx)(`input`,{id:`s-confirm-password`,className:Z.input,type:`password`,autoComplete:`new-password`,value:Et,onChange:e=>{Dt(e.target.value),Nt(null)}})]})]}),(0,R.jsx)(`span`,{className:Z.pwHint,children:i(`min 8 characters. signed up with Google or GitHub? this sets a password you can also use to log in.`)}),Mt&&(0,R.jsx)(`div`,{className:B(Z.integBanner,Z.integBannerErr),role:`alert`,children:Mt}),(0,R.jsxs)(`div`,{className:Z.saveRow,children:[(0,R.jsx)(`button`,{type:`submit`,className:Z.saveBtn,disabled:Ot||!wt||!Et,children:i(Ot?`updatingâ¦`:`update password`)}),At&&(0,R.jsxs)(`span`,{className:Z.savedMsg,children:[(0,R.jsx)(Wm,{name:`check`,size:12}),` `,i(`password updated`)]})]})]})]}),(0,R.jsxs)(`section`,{className:f(`billing`),children:[(0,R.jsx)(`h2`,{className:Z.sectionTitle,children:i(`billing`)}),(0,R.jsxs)(`div`,{className:Z.sectionCard,children:[nn&&(0,R.jsx)(`div`,{className:B(Z.integBanner,nn.kind===`ok`?Z.integBannerOk:Z.integBannerErr),children:nn.text}),(0,R.jsxs)(`div`,{className:Z.planRow,children:[(0,R.jsxs)(`div`,{className:Z.planInfo,children:[(0,R.jsx)(`span`,{className:B(Z.planBadge,nt===`trial`?Z.planBadgeTrial:Z.planBadgePaid),children:nt}),nt===`trial`&&(0,R.jsx)(`span`,{className:Z.planNote,children:i(`free until launch`)}
66),nt!==`trial`&&(0,R.jsx)(`span`,{className:Z.planNote,children:i(nt===`solo`?`solo plan · billed via stripe`:`founder plan · billed via stripe`)})]}),nt!==`trial`&&(0,R.jsx)(`button`,{className:Z.manageBtn,onClick:()=>Xn(!0),disabled:Gn,children:i(Gn?`loadingâ¦`:`manage billing â`)})]}),nt===`trial`&&(0,R.jsxs)(`div`,{className:Z.upgradeGrid,children:[(0,R.jsxs)(`div`,{className:Z.upgradeCard,children:[(0,R.jsxs)(`div`,{className:Z.upgradeCardTop,children:[(0,R.jsx)(`span`,{className:Z.upgradeName,children:`solo`}),(0,R.jsxs)(`span`,{className:Z.upgradePrice,children:[`$19`,(0,R.jsx)(`span`,{children:`/mo`})]})]}),(0,R.jsxs)(`ul`,{className:Z.upgradeFeatures,children:[(0,R.jsx)(`li`,{children:i(`All connectors (15 total)`)}),(0,R.jsx)(`li`,{children:i(`90-day history + export`)}),(0,R.jsx)(`li`,{children:i(`Priority Sonnet AI`)}),(0,R.jsx)(`li`,{children:i(`Multiple goals`)})]}),(0,R.jsxs)(`div`,{className:Z.upgradeBtns,children:[(0,R.jsx)(`button`,{className:Z.upgradeBtn,onClick:()=>gr(`solo_monthly`),disabled:Gn||!xr,children:i(`$19 / month`)}),(0,R.jsx)(`button`,{className:B(Z.upgradeBtn,Z.upgradeBtnAlt),onClick:()=>gr(`solo_annual`),disabled:Gn||!xr,children:i(`$149 / year`)})]})]}),(0,R.jsxs)(`div`,{className:B(Z.upgradeCard,Z.upgradeCardFeatured),children:[(0,R.jsxs)(`div`,{className:Z.upgradeCardTop,children:[(0,R.jsx)(`span`,{className:Z.upgradeName,children:`founder`}),(0,R.jsxs)(`span`,{className:Z.upgradePrice,children:[`$39`,(0,R.jsx)(`span`,{children:`/mo`})]})]}),(0,R.jsxs)(`ul`,{className:Z.upgradeFeatures,children:[(0,R.jsx)(`li`,{children:i(`Everything in solo`)}),(0,R.jsx)(`li`,{children:i(`The Crew â pod accountability board`)}),(0,R.jsx)(`li`,{children:i(`Stakes`)}),(0,R.jsx)(`li`,{children:i(`Priority support`)})]}),(0,R.jsxs)(`div`,{className:Z.upgradeBtns,children:[(0,R.jsx)(`button`,{className:Z.upgradeBtn,onClick:()=>gr(`founder_monthly`),disabled:Gn||!xr,children:i(`$39 / month`)}),(0,R.jsx)(`button`,{className:B(Z.upgradeBtn,Z.upgradeBtnAlt),onClick:()=>gr(`founder_annual`),disabled:Gn||!xr,children:i(`$299 / year`)})]})]})]}),qn&&(0,R.jsx)(`span`,{className:Z.billingError,children:qn}),!xr&&nt===`trial`&&(0,R.jsx)(`span`,{className:Z.billingNote,children:i(`stripe not configured yet â add VITE_STRIPE_PRICE_* env vars to enable checkout`)})]})]}),(0,R.jsxs)(`section`,{className:f(`connectors`),children:[(0,R.jsx)(`h2`,{className:Z.sectionTitle,children:i(`connectors`)}),(0,R.jsxs)(`div`,{className:Z.sectionCard,children:[(0,R.jsx)(`p`,{className:Z.pingDetail,style:{marginBottom:10},children:i(`Connect your workflow tools so Crew can verify task completion automatically â closed tickets, merged PRs, sent messages, and more.`)}),en&&(0,R.jsx)(`div`,{className:B(Z.integBanner,en.kind===`ok`?Z.integBannerOk:Z.integBannerErr),children:en.text}),ln&&(0,R.jsx)(`div`,{className:B(Z.integBanner,ln.kind===`ok`?Z.integBannerOk:Z.integBannerErr),children:ln.text}),_n&&(0,R.jsx)(`div`,{className:B(Z.integBanner,_n.kind===`ok`?Z.integBannerOk:Z.integBannerErr),children:_n.text}),Un&&(0,R.jsx)(`div`,{className:B(Z.integBanner,Un.kind===`ok`?Z.integBannerOk:Z.integBannerErr),children:Un.text}),De&&(0,R.jsx)(`div`,{className:B(Z.integBanner,Z.integBannerErr),children:De}),(0,R.jsx)(`div`,{className:Z.toolsHeader,children:(0,R.jsx)(`input`,{className:Z.toolsSearch,placeholder:i(`Search appsâ¦`),value:Pe,onChange:e=>Fe(e.target.value)})}),Ar.length>0&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`div`,{className:Z.connectorsGroupLabel,children:i(`connected`)}),Ar.map(Nr)]}),jr.length>0&&(0,R.jsx)(`div`,{className:Z.connectorsGroupLabel,children:i(`not connected`)}),Mr.map(Nr),jr.length>6&&(0,R.jsx)(`button`,{className:Z.viewAllBtn,onClick:()=>Le(!0),children:i(`view all {n} apps â`).replace(`{n}`,String(jr.length))})]})]}),(0,R.jsxs)(`section`,{className:f(`connectors`),children:[(0,R.jsx)(`h2`,{className:Z.sectionTitle,children:i(`api access`)}),(0,R.jsxs)(`div`,{className:Z.sectionCard,children:[(0,R.jsx)(`p`,{className:Z.pingDetail,style:{marginBottom:10},children:i(`Connect Crew to Claude, ChatGPT or any MCP client. Most people should use the connector link, which handles this for you â mint a token by hand only for a script or a client that cannot do OAuth.`)}),(0,R.jsx)(`div`,{className:Z.extActions,children:(0,R.jsxs)(`a`,{className:Z.extGuideBtn,href:`/connect`,target:`_blank`,rel:`noreferrer`,children:[i(`connector setup`),(0,R.jsx)(Wm,{name:`externalLink`,size:13})]})}),Be&&(0,R.jsxs)(`div`,{className:Z.tokenReveal,children:[(0,R.jsx)(`p`,{className:Z.tokenRevealWarn,children:i(`Copy this now. It is stored as a hash and can never be shown again.`)}),(0,R.jsx)(`code`,{className:Z.tokenValue,children:Be}),(0,R.jsx)(`button`,{className:Z.extGuideBtn,onClick:()=>navigator.clipboard.writeText(Be),children:i(`copy`)})]}),(0,R.jsxs)(`ul`,{className:Z.tokenList,children:[Re.map(e=>(0,R.jsxs)(`li`,{className:Z.tokenRow,children:[(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`span`,{className:Z.tokenName,children:e.name}),(0,R.jsxs)(`span`,{className:Z.tokenMeta,children:[e.prefix,`⦠· `,e.scope,e.revoked_at?` · ${i(`revoked`)}`:e.last_used_at?` · ${i(`last used`)} ${e.last_used_at.slice(0,10)}`:` · ${i(`never used`)}`]})]}),!e.revoked_at&&(0,R.jsx)(`button`,{className:Z.tokenRevoke,onClick:()=>qe(e.id),children:i(`revoke`)})]},e.id)),Re.length===0&&(0,R.jsx)(`li`,{className:Z.tokenMeta,children:i(`no tokens yet`)})]}),(0,R.jsxs)(`div`,{className:Z.extActions,children:[(0,R.jsx)(`button`,{className:Z.extGuideBtn,onClick:()=>Ke(`read`),disabled:He,children:i(`new read-only token`)}),(0,R.jsx)(`button`,{className:Z.extGuideBtn,onClick:()=>Ke(`write`),disabled:He,children:i(`new read/write token`)})]})]})]}),(0,R.jsxs)(`section`,{className:f(`connectors`),children:[(0,R.jsx)(`h2`,{className:Z.sectionTitle,children:i(`companion extension`)}),(0,R.jsxs)(`div`,{className:Z.sectionCard,children:[(0,R.jsx)(`p`,{className:Z.pingDetail,style:{marginBottom:10},children:i(`A small browser extension that watches only claude.ai (usage) and LinkedIn messaging (sent count) â nothing else â and checks a matching task off automatically. On a likely match it also takes a screenshot of that page as supp
66orting evidence; an unrelated page's screenshot is never even captured for review. Click the extension icon anytime to manually check a task against whatever page you're currently on.`)}),(0,R.jsxs)(`div`,{className:Z.extActions,children:[(0,R.jsxs)(`a`,{className:Z.extGuideBtn,href:`/extension`,target:`_blank`,rel:`noreferrer`,children:[i(`install guide`),(0,R.jsx)(Wm,{name:`externalLink`,size:13})]}),(0,R.jsxs)(`a`,{className:Z.extZipLink,href:`/crew-companion.zip`,download:!0,children:[(0,R.jsx)(Wm,{name:`arrowDown`,size:13}),i(`download the extension (.zip)`)]})]}),(0,R.jsx)(`div`,{className:Z.extTokenLabel,children:i(`connector token`)}),(0,R.jsx)(`p`,{className:Z.pingDetail,style:{marginBottom:8},children:i(`this is what connects the extension to your account â nothing else about you is exposed to it. copy it, open the extension's options page, paste it in, and hit save. treat it like a password.`)}),(0,R.jsxs)(`div`,{style:{display:`flex`,gap:8,alignItems:`center`,flexWrap:`wrap`},children:[(0,R.jsx)(`code`,{style:{fontFamily:`var(--font-mono)`,fontSize:12,padding:`6px 10px`,background:`var(--surface-inset)`,border:`1px solid var(--border)`,borderRadius:6,userSelect:fe?`text`:`none`,minWidth:180},children:ue?`â¦`:ce?fe?ce:`â¢`.repeat(24):`â`}),ce&&(0,R.jsx)(`button`,{type:`button`,className:me?Z.extCopyBtnDone:Z.extCopyBtn,onClick:xe,children:i(me?`copied â`:`copy token`)}),(0,R.jsx)(`button`,{type:`button`,className:Z.extSmallBtn,onClick:()=>pe(e=>!e),disabled:!ce,children:i(fe?`hide`:`reveal`)}),(0,R.jsx)(`button`,{type:`button`,className:Z.extSmallBtn,onClick:Se,children:i(`regenerate`)})]}),me&&(0,R.jsx)(`p`,{className:Z.extCopyOk,children:i(`copied â now paste it into the extension's options page and hit save.`)}),ge&&(0,R.jsx)(`p`,{className:Z.extCopyOk,children:i(`your browser blocked the clipboard â the token is shown above, select and copy it by hand.`)}),(0,R.jsx)(`p`,{className:Z.extStatus,children:ve?i(`extension last checked in on {d}.`).replace(`{d}`,new Date(ve).toLocaleString()):i(`no check-in from the extension yet â it shows up here the first time the extension verifies a task.`)}),(0,R.jsx)(`p`,{className:Z.pingDetail,children:i(`regenerating invalidates the old token immediately: the extension stops working until you paste the new one in. that's how you revoke access from a browser you no longer have.`)})]})]}),(0,R.jsxs)(`section`,{className:f(`notifications`),children:[(0,R.jsx)(`h2`,{className:Z.sectionTitle,children:i(`notifications`)}),!It.trim()&&(0,R.jsxs)(`div`,{className:Z.ctxReminder,children:[(0,R.jsx)(`span`,{className:Z.ctxReminderText,children:i(`these pings get sharper once crew knows your business â you haven't added your context yet.`)}),(0,R.jsx)(`button`,{type:`button`,className:Z.ctxReminderBtn,onClick:()=>l(`crew`),children:i(`add it â`)})]}),(0,R.jsxs)(`div`,{className:Z.sectionCard,children:[(0,R.jsxs)(`div`,{className:Z.pingRow,children:[(0,R.jsxs)(`div`,{className:Z.pingInfo,children:[(0,R.jsx)(`span`,{className:Z.pingLabel,children:i(`morning lock-in`)}),(0,R.jsx)(`span`,{className:Z.pingDetail,children:i(`crew reminds you to lock in your {n} for the day`).replace(`{n}`,String(p))})]}),(0,R.jsx)(`input`,{className:Z.timeInput,type:`time`,value:dt,onChange:e=>ft(e.target.value),"aria-label":i(`morning ping time`)})]}),(0,R.jsx)(`div`,{className:Z.divider}),(0,R.jsxs)(`div`,{className:Z.pingRow,children:[(0,R.jsxs)(`div`,{className:Z.pingInfo,children:[(0,R.jsx)(`span`,{className:Z.pingLabel,children:i(`midday verify check`)}),(0,R.jsx)(`span`,{className:Z.pingDetail,children:i(`crew checks your connected tools during the day â anything it can confirm gets marked done and pinged to you automatically`)})]}),(0,R.jsx)(`input`,{className:Z.timeInput,type:`time`,value:ht,onChange:e=>gt(e.target.value),"aria-label":i(`midday verify check time`)})]}),(0,R.jsx)(`div`,{className:Z.divider}),(0,R.jsxs)(`div`,{className:Z.pingRow,children:[(0,R.jsxs)(`div`,{className:Z.pingInfo,children:[(0,R.jsx)(`span`,{className:Z.pingLabel,children:i(`evening check-in`)}),(0,R.jsx)(`span`,{className:Z.pingDetail,children:i(`crew reconciles what shipped vs what slipped`)})]}),(0,R.jsx)(`input`,{className:Z.timeInput,type:`time`,value:pt,onChange:e=>mt(e.target.value),"aria-label":i(`evening ping time`)})]}),(0,R.jsx)(`div`,{className:Z.divider}),(0,R.jsxs)(`div`,{className:Z.pingRow,children:[(0,R.jsxs)(`div`,{className:Z.pingInfo,children:[(0,R.jsx)(`span`,{className:Z.pingLabel,children:i(`timezone`)}),(0,R.jsx)(`span`,{className:Z.pingDetail,children:i(`used for your morning and evening pings`)})]}),(0,R.jsxs)(`select`,{className:Z.tzSelect,value:_t,onChange:e=>vt(e.target.value),"aria-label":i(`timezone`),children:[yt&&(0,R.jsx)(`optgroup`,{label:i(`current`),children:(0,R.jsx)(`option`,{value:yt,children:yt})}),ux.map(e=>(0,R.jsx)(`optgroup`,{label:e.group,children:e.zones.map(e=>(0,R.jsx)(`option`,{value:e.value,children:e.label},e.value))},e.group))]})]}),(0,R.jsx)(`div`,{className:Z.divider}),(0,R.jsxs)(`div`,{className:Z.pingRow,children:[(0,R.jsxs)(`div`,{className:Z.pingInfo,children:[(0,R.jsxs)(`span`,{className:Z.pingLabel,children:[(0,R.jsx)(`svg`,{width:`14`,height:`14`,viewBox:`0 0 24 24`,fill:`currentColor`,style:{display:`inline`,marginRight:`6px`,verticalAlign:`text-bottom`,color:`#229ED9`}
66,"aria-hidden":!0,children:(0,R.jsx)(`path`,{d:`M11.944 0A12 12 0 0 0 0 12a12 12 0 0 0 12 12 12 12 0 0 0 12-12A12 12 0 0 0 12 0a12 12 0 0 0-.056 0zm4.962 7.224c.1-.002.321.023.465.14a.506.506 0 0 1 .171.325c.016.093.036.306.02.472-.18 1.898-.962 6.502-1.36 8.627-.168.9-.499 1.201-.82 1.23-.696.065-1.225-.46-1.9-.902-1.056-.693-1.653-1.124-2.678-1.8-1.185-.78-.417-1.21.258-1.91.177-.184 3.247-2.977 3.307-3.23.007-.032.014-.15-.056-.212s-.174-.041-.249-.024c-.106.024-1.793 1.14-5.061 3.345-.48.33-.913.49-1.302.48-.428-.008-1.252-.241-1.865-.44-.752-.245-1.349-.374-1.297-.789.027-.216.325-.437.893-.663 3.498-1.524 5.83-2.529 6.998-3.014 3.332-1.386 4.025-1.627 4.476-1.635z`})}),`telegram`]}),(0,R.jsx)(`span`,{className:Z.pingDetail,children:i(`one click â it links your account automatically. no phone app required: if telegram isn't installed, it just opens in your browser.`)})]}),Pt.connected?(0,R.jsxs)(`div`,{className:Z.integRight,children:[(0,R.jsxs)(`span`,{className:Z.connectedBadge,children:[(0,R.jsx)(`span`,{className:Z.connectedDot}),i(`connected`)]}),(0,R.jsx)(`button`,{className:Z.disconnectBtn,onClick:Pt.disconnect,children:i(`disconnect`)})]}):(0,R.jsx)(`button`,{className:Z.connectBtn,onClick:Pt.start,disabled:Pt.linking||Pt.polling,children:Pt.linking?i(`openingâ¦`):Pt.polling?i(`waitingâ¦`):i(`connect`)})]}),!Pt.connected&&(Pt.polling||Pt.url||Pt.error)&&(0,R.jsxs)(`div`,{className:Z.tgAside,children:[Pt.polling&&(0,R.jsx)(`span`,{className:Z.pingDetail,children:i(`finished in telegram? come back to this tab â it updates on its own.`)}),Pt.error&&(0,R.jsx)(`span`,{className:Z.tgError,children:Pt.error}),(0,R.jsx)(z_,{state:Pt})]}),(0,R.jsxs)(`div`,{className:Z.saveRow,children:[(0,R.jsx)(`button`,{type:`button`,className:Z.saveBtn,onClick:br,children:i(`save notifications`)}),St&&(0,R.jsxs)(`span`,{className:Z.savedMsg,children:[(0,R.jsx)(Wm,{name:`check`,size:12}),` `,i(`saved`)]})]})]})]}),r&&(0,R.jsxs)(`section`,{className:f(`crew`),children:[(0,R.jsx)(`h2`,{className:Z.sectionTitle,children:i(`rest days`)}),(0,R.jsx)(`div`,{className:Z.sectionCard,children:(0,R.jsx)(vb,{userId:r})})]}),(0,R.jsxs)(`section`,{className:f(`crew`),children:[(0,R.jsx)(`h2`,{className:Z.sectionTitle,children:i(`business context`)}),(0,R.jsxs)(`div`,{className:Z.sectionCard,children:[(0,R.jsxs)(`div`,{className:Z.field,children:[(0,R.jsx)(`label`,{className:Z.label,htmlFor:`s-ctx`,children:i(`what crew knows about your business`)}),(0,R.jsx)(`p`,{className:Z.pingDetail,style:{marginBottom:`8px`},children:i(`paste a short description â what you build, who buys it, your current traction. crew uses this to give you sharper daily nudges.`)}),(0,R.jsx)(`textarea`,{id:`s-ctx`,className:Z.contextArea,rows:5,placeholder:`e.g. "We build Replyflow, an AI email tool for e-commerce brands. We're pre-revenue, 3 pilot customers, goal is $5k MRR by Q3. Main blocker: closing pilots into paid accounts."`,value:It,onChange:e=>Lt(e.target.value)})]}),(0,R.jsxs)(`div`,{className:Z.saveRow,children:[(0,R.jsx)(`button`,{type:`button`,className:Z.saveBtn,onClick:Vt,children:i(`save context`)}),Rt&&(0,R.jsxs)(`span`,{className:Z.savedMsg,children:[(0,R.jsx)(Wm,{name:`check`,size:12}),` `,i(`saved`)]})]})]})]}),(0,R.jsxs)(`section`,{className:f(`crew`),children:[(0,R.jsx)(`h2`,{className:Z.sectionTitle,children:i(`daily priorities`)}),(0,R.jsxs)(`div`,{className:Z.sectionCard,children:[(0,R.jsx)(`p`,{className:Z.fieldHint,children:i(`how many tasks do you lock in each day? between 3 and 10.`)}),(0,R.jsxs)(`div`,{className:Z.taskCountRow,children:[(0,R.jsx)(`button`,{type:`button`,className:Z.taskCountBtn,onClick:()=>h(-1),disabled:p<=3,"aria-label":i(`fewer tasks`),children:`â`}),(0,R.jsx)(`span`,{className:Z.taskCountValue,children:p}),(0,R.jsx)(`button`,{type:`button`,className:Z.taskCountBtn,onClick:()=>h(1),disabled:p>=10,"aria-label":i(`more tasks`),children:`+`})]})]})]}),(0,R.jsxs)(`section`,{className:f(`crew`),children:[(0,R.jsx)(`h2`,{className:Z.sectionTitle,children:i(`task verification`)}),(0,R.jsxs)(`div`,{className:Z.sectionCard,children:[(0,R.jsx)(`p`,{className:Z.fieldHint,children:i(`crew checks your work before a task counts as done â auto-verify, then proof if needed.`)}),(0,R.jsxs)(`div`,{className:Z.langPickerRow,children:[(0,R.jsx)(`button`,{type:`button`,className:B(Z.langPickerBtn,g&&Z.langPickerBtnActive),onClick:()=>x(!0),children:i(`on`)}),(0,R.jsx)(`button`,{type:`button`,className:B(Z.langPickerBtn,!g&&Z.langPickerBtnActive),onClick:()=>{g&&b(!0)},children:i(`off`)})]}),y&&g&&(0,R.jsxs)(`div`,{className:Z.verifyWarn,children:[(0,R.jsx)(`p`,{className:Z.verifyWarnText,children:i(`turning this off means one click marks a task done. it will count as self-reported, not verified â on your streak, your records, and anything you share.`)}),(0,R.jsxs)(`div`,{className:Z.verifyWarnActions,children:[(0,R.jsx)(`button`,{type:`button`,className:Z.verifyWarnOff,onClick:()=>x(!1),children:i(`turn off anyway`)}),(0,R.jsx)(`button`,{type:`button`,className:Z.verifyWarnKeep,onClick:()=>b(!1),children:i(`keep verification on`)})]})]}),!g&&(0,R.jsx)(`p`,{className:Z.fieldHint,children:i(`verification is off â tasks count as self-reported.`)})]})]}),(0,R.jsxs)(`section`,{className:f(`account`),children:[(0,R.jsx)(`h2`,{className:Z.sectionTitle,children:i(`language`)}),(0,R.jsx)(`div`,{className:Z.sectionCard,children:(0,R.jsxs)(`div`,{className:Z.langPickerRow,children:[(0,R.jsx)(`button`,{className:B(Z.langPickerBtn,a===`en`&&Z.langPickerBtnActive),onClick:()=>{o(`en`),r&&gl(r,`en`)},children:`English`}),(0,R.jsx)(`button`,{className:B(Z.langPickerBtn,a===`fr`&&Z.langPickerBtnActive),onClick:()=>{o(`fr`),r&&gl(r,`fr`)},children:`Français`})]})})]}),r&&e?.user.email===fx&&(0,R.jsx)(lx,{userId:r}),(0,R.jsx)(`div`,{className:f(`notifications`),children:r&&(0,R.jsx)(ix,{userId:r})}),(0,R.jsx)(`div`,{className:f(`account`),children:r&&(0,R.jsx)(Jb,{userId:r})}),Yn&&r&&(0,R.jsx)(ax,{userId:r,onContinue:()=>{Xn(!1),_r()},onClose:()=>Xn(!1),onPaused:()=>{Xn(!1),rn({kind:`ok`,text:`account paused for 30 days. your streak and history are frozen â welcome back anytime.`})}}),je&&(0,R.jsx)(`div`,{className:B(Z.modalOverlay,Z.modalOverlayNested),onClick:()=>Me(null),children:(0,R.jsxs)(`div`,{className:Z.modalBox,onClick:e=>e.stopPropagation(),children:[(0,R.jsx)(`div`,{className:Z.modalLogo,children:je.n
66oIcon?(0,R.jsx)(`span`,{style:{color:`#${je.hex}`,fontSize:22,fontWeight:700},children:je.label[0]}):(0,R.jsx)(`div`,{className:Z.composioLogoMask,style:{"--lurl":`url('${je.logo}')`,"--lclr":`#${je.hex}`,width:28,height:28}})}),(0,R.jsxs)(`h3`,{className:Z.modalTitle,children:[i(`connect`),` `,je.label]}),(0,R.jsxs)(`p`,{className:Z.modalBody,children:[i(`you'll be redirected to a secure`),` `,(0,R.jsx)(`strong`,{children:`Composio`}),` `,i(`OAuth screen to authorise the connection. crew never sees your passwords or credentials â composio manages it end-to-end.`)]}),(0,R.jsxs)(`div`,{className:Z.modalActions,children:[(0,R.jsx)(`button`,{className:Z.modalCancel,onClick:()=>Me(null),children:i(`cancel`)}),(0,R.jsx)(`button`,{className:Z.modalConfirm,disabled:ke===je.name,onClick:()=>et(je.name),children:ke===je.name?i(`openingâ¦`):i(`connect â`)})]})]})}),Ie&&(0,R.jsx)(`div`,{className:Z.modalOverlay,onClick:()=>Le(!1),children:(0,R.jsxs)(`div`,{className:Z.connectorsModalBox,onClick:e=>e.stopPropagation(),children:[(0,R.jsxs)(`div`,{className:Z.connectorsModalHeader,children:[(0,R.jsx)(`h3`,{className:Z.modalTitle,children:i(`all connectors`)}),(0,R.jsx)(`button`,{className:Z.modalCancel,onClick:()=>Le(!1),children:i(`close`)})]}),(0,R.jsx)(`input`,{className:Z.toolsSearch,placeholder:i(`Search appsâ¦`),value:Pe,onChange:e=>Fe(e.target.value),autoFocus:!0}),(0,R.jsx)(`div`,{className:Z.connectorGrid,children:jr.map(Pr)})]})}),M&&(0,R.jsx)(_v,{title:`delete "${M.name}"?`,body:`this can't be undone. tasks locked under it aren't deleted â they'll show up under 'all companies' instead.`,confirmText:M.name,busy:ie,onConfirm:se,onCancel:()=>N(null)}),Je&&(0,R.jsx)(`div`,{className:Z.modalOverlay,onClick:()=>Ye(null),children:(0,R.jsxs)(`div`,{className:Z.modalBox,onClick:e=>e.stopPropagation(),children:[(0,R.jsx)(`div`,{className:Z.modalLogo,children:(0,R.jsx)(`div`,{className:Z.composioLogoMask,style:{"--lurl":`url('${Je.logo}')`,"--lclr":`#${Je.hex}`,width:28,height:28}})}),(0,R.jsx)(`h3`,{className:Z.modalTitle,children:Je.label}),Je.tool?(0,R.jsxs)(R.Fragment,{children:[(0,R.jsxs)(`p`,{className:Z.modalBody,children:[i(`reads`),`: `,Gb(Je.provider).reads,`.`,(0,R.jsx)(`br`,{}),i(`why`),`: `,Gb(Je.provider).why,`.`]}),(0,R.jsxs)(`div`,{className:Z.detailFacts,children:[(0,R.jsxs)(`div`,{className:Z.detailFactRow,children:[(0,R.jsx)(`span`,{className:Z.detailFactLabel,children:i(`read-only`)}),(0,R.jsx)(`span`,{className:Z.detailFactVal,children:i(`yes â crew never posts or sends on your behalf`)})]}),(0,R.jsxs)(`div`,{className:Z.detailFactRow,children:[(0,R.jsx)(`span`,{className:Z.detailFactLabel,children:i(`connected since`)}),(0,R.jsx)(`span`,{className:Z.detailFactVal,children:Je.tool.connectedAt?new Date(Je.tool.connectedAt).toLocaleDateString():`â`})]}),(0,R.jsxs)(`div`,{className:Z.detailFactRow,children:[(0,R.jsx)(`span`,{className:Z.detailFactLabel,children:i(`last read`)}),(0,R.jsx)(`span`,{className:Z.detailFactVal,children:Je.tool.lastRead?new Date(Je.tool.lastRead).toLocaleString():i(`never`)})]}),Je.tool.scope&&(0,R.jsxs)(`div`,{className:Z.detailFactRow,children:[(0,R.jsx)(`span`,{className:Z.detailFactLabel,children:i(`permissions granted`)}),(0,R.jsx)(`span`,{className:B(Z.detailFactVal,Z.detailFactMono),children:Je.tool.scope})]})]})]}):(0,R.jsx)(`p`,{className:Z.modalBody,children:i(`loadingâ¦`)}),(0,R.jsx)(`div`,{className:Z.modalActions,children:(0,R.jsx)(`button`,{className:Z.modalCancel,onClick:()=>Ye(null),children:i(`close`)})})]})})]})}var vx={page:`_page_693du_1`,heading:`_heading_693du_12`,intro:`_intro_693du_20`,title:`_title_693du_22`,sub:`_sub_693du_30`,categoryGrid:`_categoryGrid_693du_37`,categoryCard:`_categoryCard_693du_43`,categoryCardActive:`_categoryCardActive_693du_58`,categoryLabel:`_categoryLabel_693du_64`,categoryDesc:`_categoryDesc_693du_71`,subcatRow:`_subcatRow_693du_78`,subcatChip:`_subcatChip_693du_84`,subcatChipActive:`_subcatChipActive_693du_95`,inputRow:`_inputRow_693du_101`,micBtn:`_micBtn_693du_107`,micBtnActive:`_micBtnActive_693du_121`,pulse:`_pulse_693du_1`,textarea:`_textarea_693du_133`,voiceHint:`_voiceHint_693du_147`,voiceError:`_voiceError_693du_155`,bugFields:`_bugFields_693du_162`,severityRow:`_severityRow_693du_168`,severityLabel:`_severityLabel_693du_175`,severityChips:`_severityChips_693du_181`,severityChip:`_severityChip_693du_181`,"severity-critical":`_severity-critical_693du_195`,"severity-high":`_severity-high_693du_196`,"severity-medium":`_severity-medium_693du_197`,"severity-low":`_severity-low_693du_198`,severityChipActive:`_severityChipActive_693du_200`,historySeverity:`_historySeverity_693du_205`,attachBtn:`_attachBtn_693du_207`,sentNote:`_sentNote_693du_221`,history:`_history_693du_205`,historyLabel:`_historyLabel_693du_236`,historyRow:`_historyRow_693du_244`,historyIcon:`_historyIcon_693du_251`,historyText:`_historyText_693du_253`,historyStatus:`_historyStatus_693du_260`,historyCancelBtn:`_historyCancelBtn_693du_270`,"status-open":`_status-open_693du_288`,"status-in_progress":`_status-in_progress_693du_292`,"status-shipped":`_status-shipped_693du_296`,"status-wontfix":`_status-wontfix_693du_300`},yx=[{key:`bug`,icon:`bug`,label:`bug`,desc:`something's broken`},{key:`feature`,icon:`zap`,label:`feature idea`,desc:`something you want built`},{key:`connector`,icon:`layers`,label:`connector request`,desc:`an app you want Crew to wat
66ch`},{key:`verification`,icon:`check`,label:`verification issue`,desc:`Crew got a call wrong`},{key:`performance`,icon:`activity`,label:`performance`,desc:`slow, laggy, unresponsive`},{key:`notifications`,icon:`bell`,label:`notifications`,desc:`pings, emails, alerts`},{key:`account`,icon:`settings`,label:`account & billing`,desc:`plan, login, data`},{key:`other`,icon:`chat`,label:`something else`,desc:`anything that doesn't fit above`}],bx={bug:[`ui glitch`,`crash`,`data or sync issue`,`connector issue`,`other`],feature:[`new connector`,`automation`,`reporting`,`mobile / telegram`,`other`],connector:[`github`,`vercel`,`google calendar`,`stripe`,`calendly`,`gmail`,`other`],verification:[`marked done wrongly`,`didn't mark done`,`connector not detected`,`other`],performance:[`slow to load`,`laggy typing`,`sync delay`,`other`],notifications:[`too many`,`too few`,`wrong channel`,`wrong time`,`other`],account:[`billing or plan`,`login or access`,`data or privacy`,`other`],other:[`pricing`,`onboarding`,`general feedback`,`other`]},xx=[{key:`critical`,label:`critical`},{key:`high`,label:`high`},{key:`medium`,label:`medium`},{key:`low`,label:`low`}],Sx={open:`received`,in_progress:`in progress`,shipped:`shipped`,wontfix:`won't fix`};function Cx(){let{session:e}=ll(),t=e?.user.id,n=z(),[r,i]=(0,_.useState)(null),[a,o]=(0,_.useState)(null),[s,c]=(0,_.useState)(``),[l,u]=(0,_.useState)(null),[d,f]=(0,_.useState)(!1),[p,m]=(0,_.useState)(``),[h,g]=(0,_.useState)(``),[v,y]=(0,_.useState)(!1),[b,x]=(0,_.useState)(!1),[S,C]=(0,_.useState)([]),w=(0,_.useRef)(null),T=r===`bug`;(0,_.useEffect)(()=>{t&&lv(t).then(({data:e})=>C(e??[]))},[t]);async function E(e){confirm(n(`cancel this feedback? this can't be undone.`))&&(await uv(e),C(t=>t.filter(t=>t.id!==e)))}function D(e){i(e),o(null)}async function O(e){let n=e.target.files?.[0];if(!(!n||!t)){f(!0);try{let e=n.name.split(`.`).pop()??`png`,r=`${t}/${Date.now()}.${e}`,{error:i}=await L.storage.from(`feedback-uploads`).upload(r,n,{contentType:n.type});i||(m(r),g(n.name))}finally{f(!1),w.current&&(w.current.value=``)}}}async function k(){if(!t||!r||!s.trim()||T&&!l)return;y(!0);let{data:e}=await cv({userId:t,type:r,text:s.trim(),subcategory:a??void 0,severity:T?l??void 0:void 0,attachmentUrl:T&&p||void 0,deviceInfo:{deviceType:au(),platform:navigator.platform,userAgent:navigator.userAgent.
66slice(0,200)}});y(!1),e&&(C(t=>[e,...t]),$l(`feedback_submitted`,{type:r,subcategory:a,severity:l}),i(null),o(null),c(``),u(null),m(``),g(``),x(!0),setTimeout(()=>x(!1),5e3))}let A=!!r&&!!s.trim()&&(!T||!!l)&&!v;return(0,R.jsxs)(`div`,{className:vx.page,children:[(0,R.jsx)(`span`,{className:vx.heading,children:n(`feedback`)}),(0,R.jsxs)(`div`,{className:vx.intro,children:[(0,R.jsx)(`h1`,{className:vx.title,children:n(`got a bug, an idea, or a connector you want?`)}),(0,R.jsx)(`p`,{className:vx.sub,children:n(`pick a category, say or type it â I'll look at it within 3 days.`)})]}),(0,R.jsx)(`div`,{className:vx.categoryGrid,children:yx.map(e=>(0,R.jsxs)(`button`,{type:`button`,className:B(vx.categoryCard,r===e.key&&vx.categoryCardActive),onClick:()=>D(e.key),children:[(0,R.jsx)(Wm,{name:e.icon,size:18}),(0,R.jsx)(`span`,{className:vx.categoryLabel,children:n(e.label)}),(0,R.jsx)(`span`,{className:vx.categoryDesc,children:n(e.desc)})]},e.key))}),r&&(0,R.jsx)(`div`,{className:vx.subcatRow,children:bx[r].map(e=>(0,R.jsx)(`button`,{type:`button`,className:B(vx.subcatChip,a===e&&vx.subcatChipActive),onClick:()=>o(t=>t===e?null:e),children:n(e)},e))}),r&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsxs)(`div`,{className:vx.inputRow,children:[(0,R.jsx)(`textarea`,{className:vx.textarea,placeholder:n(`describe the issue (no essay needed)`),value:s,onChange:e=>c(e.target.value),rows:2}),(0,R.jsx)(l_,{onText:e=>c(t=>t?`${t} ${e}`:e)})]}),T&&(0,R.jsxs)(`div`,{className:vx.bugFields,children:[(0,R.jsxs)(`div`,{className:vx.severityRow,children:[(0,R.jsx)(`span`,{className:vx.severityLabel,children:n(`how critical?`)}),(0,R.jsx)(`div`,{className:vx.severityChips,children:xx.map(e=>(0,R.jsx)(`button`,{type:`button`,className:B(vx.severityChip,vx[`severity-${e.key}`],l===e.key&&vx.severityChipActive),onClick:()=>u(e.key),children:n(e.label)},e.key))})]}),(0,R.jsx)(`input`,{ref:w,type:`file`,accept:`image/*,application/pdf`,style:{display:`none`},onChange:O}),(0,R.jsx)(`button`,{type:`button`,className:vx.attachBtn,onClick:()=>w.current?.click(),disabled:d,children:d?n(`uploadingâ¦`):h?`â ${h}`:n(`â attach screenshot (optional)`)})]}),(0,R.jsx)(Sm,{onClick:k,disabled:!A,children:n(v?`sendingâ¦`:`send it`)})]}),b&&(0,R.jsx)(`p`,{className:vx.sentNote,children:n(`got it â I'll try to ship it, fix it, or add it within 3 days.`)}),S.length>0&&(0,R.jsxs)(`div`,{className:vx.history,children:[(0,R.jsx)(`span`,{className:vx.historyLabel,children:n(`your feedback`)}),S.map(e=>(0,R.jsxs)(`div`,{className:vx.historyRow,children:[(0,R.jsx)(Wm,{name:yx.find(t=>t.key===e.type)?.icon??`chat`,size:14,className:vx.historyIcon}),(0,R.jsx)(`span`,{className:vx.historyText,children:e.text}),e.severity&&(0,R.jsx)(`span`,{className:B(vx.severityChip,vx[`severity-${e.severity}`],vx.historySeverity),children:n(e.severity)}),(0,R.jsx)(`span`,{className:B(vx.historyStatus,vx[`status-${e.status}`]),children:n(Sx[e.status])}),e.status===`open`&&(0,R.jsx)(`button`,{type:`button`,className:vx.historyCancelBtn,onClick:()=>E(e.id),"aria-label":n(`cancel this feedback`),title:n(`cancel this feedback`),children:`Ã`})]},e.id))]})]})}async function wx(e){return Ym(`crew-schedule`,{action:`propose`,date:e})}async function Tx(e){return Ym(`crew-schedule`,{action:`commit`,slots:e})}var Ex={card:`_card_tc98b_1`,head:`_head_tc98b_11`,kicker:`_kicker_tc98b_13`,lead:`_lead_tc98b_21`,findBtn:`_findBtn_tc98b_23`,holdBtn:`_holdBtn_tc98b_23`,list:`_list_tc98b_37`,row:`_row_tc98b_39`,pick:`_pick_tc98b_46`,pickOn:`_pickOn_tc98b_54`,when:`_when_tc98b_56`,text:`_text_tc98b_64`,why:`_why_tc98b_65`,actions:`_actions_tc98b_67`,warn:`_warn_tc98b_70`,error:`_error_tc98b_72`,note:`_note_tc98b_73`};function Dx({date:e,onPlanned:t}){let n=z(),[r,i]=(0,_.useState)(null),[a,o]=(0,_.useState)(new Set),[s,c]=(0,_.useState)(!1),[l,u]=(0,_.useState)(``),[d,f]=(0,_.useState)(``),[p,m]=(0,_.useState)(0);async function h(){c(!0),u(``),f(``),i(null),m(0);let t=await wx(e);if(c(!1),t.error){u(t.error);return}let r=t.data?.slots??[];if(r.length===0){f(t.data?.note??n(`no free time found today.`));return}i(r),o(new Set)}async function g(){if(!r||a.size===0)return;c(!0),u(``);let e=await Tx([...a].sort((e,t)=>
66e-t).map(e=>r[e]));if(c(!1),e.error){u(e.error);return}m(e.data?.written??0),i(null),o(new Set),t?.()}let v=e=>new Date(e).toLocaleTimeString([],{hour:`2-digit`,minute:`2-digit`});return(0,R.jsxs)(`div`,{className:Ex.card,children:[(0,R.jsxs)(`div`,{className:Ex.head,children:[(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`span`,{className:Ex.kicker,children:n(`find time`)}),(0,R.jsx)(`p`,{className:Ex.lead,children:n(`Crew reads your calendar, finds the gaps, and holds one for each task you have not scheduled.`)})]}),(0,R.jsx)(`button`,{className:Ex.findBtn,onClick:h,disabled:s,children:n(s&&!r?`reading your calendarâ¦`:`find time`)})]}),l&&(0,R.jsx)(`p`,{className:Ex.error,children:l}),d&&!l&&(0,R.jsx)(`p`,{className:Ex.note,children:d}),p>0&&(0,R.jsx)(`p`,{className:Ex.note,children:n(`{n} blocks are in your calendar. They are a plan, not proof â Crew still needs real evidence to close the task.`).replace(`{n}`,String(p))}),r&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`ul`,{className:Ex.list,children:r.map((e,t)=>(0,R.jsxs)(`li`,{className:Ex.row,children:[(0,R.jsx)(`button`,{type:`button`,className:B(Ex.pick,a.has(t)&&Ex.pickOn),onClick:()=>o(e=>{let n=new Set(e);return n.has(t)?n.delete(t):n.add(t),n}),"aria-label":a.has(t)?n(`remove this block`):n(`hold this time`),children:a.has(t)?`â`:`+`}),(0,R.jsxs)(`span`,{className:Ex.when,children:[v(e.start),`â`,v(e.end)]}),(0,R.jsx)(`span`,{className:Ex.text,children:e.text}),(0,R.jsx)(`span`,{className:Ex.why,children:e.why})]},e.priorityId))}),(0,R.jsxs)(`div`,{className:Ex.actions,children:[(0,R.jsx)(`span`,{className:Ex.warn,children:n(`this writes to your real calendar. Crew never counts a block it created as evidence.`)}),(0,R.jsx)(`button`,{className:Ex.holdBtn,onClick:g,disabled:s||a.size===0,children:s?n(`holdingâ¦`):n(`hold {n} selected`).replace(`{n}`,String(a.size))})]})]})]})}var Ox={page:`_page_153le_1`,header:`_header_153le_15`,navRow:`_navRow_153le_22`,monthTitle:`_monthTitle_153le_28`,navBtn:`_navBtn_153le_39`,todayBtn:`_todayBtn_153le_55`,headerRight:`_headerRight_153le_70`,syncBtn:`_syncBtn_153le_76`,syncMsg:`_syncMsg_153le_92`,dayLabels:`_dayLabels_153le_101`,dayLabel:`_dayLabel_153le_101`,grid:`_grid_153le_119`,cell:`_cell_153le_132`,cellOut:`_cellOut_153le_144`,dayNumOut:`_dayNumOut_153le_147`,cellToday:`_cellToday_153le_152`,dayNum:`_dayNum_153le_147`,dayNumToday:`_dayNumToday_153le_170`,chips:`_chips_153le_186`,chip:`_chip_153le_186`,chipTime:`_chipTime_153le_211`,chipMore:`_chipMore_153le_219`,panelBackdrop:`_panelBackdrop_153le_236`,panel:`_panel_153le_236`,panelHeader:`_panelHeader_153le_260`,panelTitle:`_panelTitle_153le_268`,panelClose:`_panelClose_153le_276`,panelCount:`_panelCount_153le_293`,panelEvents:`_panelEvents_153le_302`,stagingSection:`_stagingSection_153le_310`,stagingList:`_stagingList_153le_315`,stagingItem:`_stagingItem_153le_323`,stagingText:`_stagingText_153le_331`,stagingRemove:`_stagingRemove_153le_333`,stagingAddRow:`_stagingAddRow_153le_343`,stagingInput:`_stagingInput_153le_349`,stagingAddBtn:`_stagingAddBtn_153le_359`,stagingCatRow:`_stagingCatRow_153le_376`,stagingCatBtn:`_stagingCatBtn_153le_382`,stagingCatBtnActive:`_stagingCatBtnActive_153le_383`,plannedBadge:`_plannedBadge_153le_407`,panelEvent:`_panelEvent_153le_302`,panelEventTime:`_panelEventTime_153le_430`,panelEventTitle:`_panelEventTitle_153le_438`,panelEventLink:`_panelEventLink_153le_446`,loadingMsg:`_loadingMsg_153le_456`},kx=[`build`,`sales`,`ops`],Ax=e=>e===`fr`?`fr-FR`:`en-US`,jx=e=>Array.from({length:7},(t,n)=>new Date(2021,7,1+n).toLocaleDateString(Ax(e),{weekday:`short`}));function Mx(e,t,n){return`${e}-${String(t+1).padStart(2,`0`)}-${String(n).padStart(2,`0`)}`}function Nx(e){if(!e)return`all day`;try{return new Date(e).toLocaleTimeString(`en-US`,{hour:`numeric`,minute:`2-digit`})}catch{return``}}function Px(e){let t=e.raw?.start?.dateTime,n=e.raw?.end?.dateTime;return t?n?`${Nx(t)} â ${Nx(n)}`:Nx(t):`all day`}function Fx(e){return[...e].sort((e,t)=>{let n=e.raw?.start?.dateTime??e.raw?.start?.date??``,r=t.raw?.start?.dateTime??t.raw?.start?.date??``;return n.localeCompare(r)})}function Ix({date:e,events:t,planned:n,dailyTaskCount:r,isPast:i,onClose:a,onStage:o,onUnstage:s}){let c=z(),{lang:l}=ml(),u=new Date(e+`T12:00:00`).toLocaleDateString(Ax(l),{weekday:`long`,month:`long`,day:`numeric`}),d=Fx(t),[f,p]=(0,_.useState)(``),[m,h]=(0,_.useState)(null),[g,v]=(0,_.useState)(!1);(0,_.useEffect)(()=>{let e=e=>{e.key===`Escape`&&a()};
66return document.addEventListener(`keydown`,e),()=>document.removeEventListener(`keydown`,e)},[a]);async function y(){let e=f.trim();!e||!m||n.length>=r||(v(!0),await o(e,m),p(``),h(null),v(!1))}return(0,R.jsx)(`div`,{className:Ox.panelBackdrop,onClick:a,children:(0,R.jsxs)(`div`,{className:Ox.panel,onClick:e=>e.stopPropagation(),children:[(0,R.jsxs)(`div`,{className:Ox.panelHeader,children:[(0,R.jsx)(`span`,{className:Ox.panelTitle,children:u}),(0,R.jsx)(`button`,{className:Ox.panelClose,onClick:a,"aria-label":c(`close`),children:`Ã`})]}),!i&&(0,R.jsxs)(`div`,{className:Ox.stagingSection,children:[(0,R.jsxs)(`div`,{className:Ox.panelCount,children:[n.length,` / `,r,` `,c(`staged`)]}),(0,R.jsx)(`ul`,{className:Ox.stagingList,children:n.map(e=>(0,R.jsxs)(`li`,{className:Ox.stagingItem,children:[(0,R.jsx)(`span`,{className:Ox.stagingText,children:e.text}),(0,R.jsx)(`button`,{className:Ox.stagingRemove,onClick:()=>s(e.id),"aria-label":c(`remove this task`),children:`Ã`})]},e.id))}),n.length<r&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsxs)(`div`,{className:Ox.stagingAddRow,children:[(0,R.jsx)(`input`,{className:Ox.stagingInput,type:`text`,placeholder:c(`stage a task for this dayâ¦`),value:f,onChange:e=>p(e.target.value),onKeyDown:e=>{e.key===`Enter`&&y()},disabled:g,autoFocus:!0}),(0,R.jsx)(`button`,{className:Ox.stagingAddBtn,onClick:y,disabled:g||!f.trim()||!m,children:c(`add`)})]}),(0,R.jsx)(`div`,{className:Ox.stagingCatRow,children:kx.map(e=>(0,R.jsx)(`button`,{type:`button`,className:m===e?Ox.stagingCatBtnActive:Ox.stagingCatBtn,onClick:()=>h(e),children:c(e)},e))})]})]}),(0,R.jsxs)(`div`,{className:Ox.panelCount,children:[t.length,` `,t.length===1?c(`event`):c(`events`)]}),(0,R.jsx)(`div`,{className:Ox.panelEvents,children:d.map(e=>{let t=Px(e);return(0,R.jsxs)(`div`,{className:Ox.panelEvent,children:[(0,R.jsx)(`div`,{className:Ox.panelEventTime,children:t===`all day`?c(`all day`):t}),(0,R.jsx)(`div`,{className:Ox.panelEventTitle,children:e.summary}),e.raw?.url&&(0,R.jsx)(`a`,{className:Ox.panelEventLink,href:e.raw.url,target:`_blank`,rel:`noopener noreferrer`,children:c(`open in google calendar â`)})]},e.id)})})]})})}function Lx(){let{session:e,profile:t}=ll(),n=e?.user.id,{active:r}=wl(),i=z(),{lang:a}=ml(),o=Ax(a),s=(0,_.useMemo)(()=>jx(a),[a]),c=t?.daily_task_count??3,l=new Date,[u,d]=(0,_.useState)(l.getFullYear()),[f,p]=(0,_.useState)(l.getMonth()),[m,h]=(0,_.useState)([]),[g,v]=(0,_.useState)([]),[y,b]=(0,_.useState)(!0),[x,S]=(0,_.useState)(!1),[C,w]=(0,_.useState)(null),[T,E]=(0,_.useState)(null),D=(0,_.useCallback)(async e=>{let{data:t}=await L.from(`activity`).select(`id, date, summary, type, raw`).eq(`user_id`,e).eq(`provider`,`google_calendar`);h(t??[]),b(!1)},[]),O=l.toLocaleDateString(`en-CA`),k=(0,_.useCallback)(async e=>{let{data:t}=await L.from(`priorities`).select(`*`).eq(`user_id`,e).gte(`date`,O);v(t??[])},[O]);(0,_.useEffect)(()=>{n&&(b(!0),D(n).then(()=>{Tb().then(e=>{e.error||D(n)})}),k(n))},[n,D,k]);let A=(0,_.useMemo)(()=>{let e={};for(let t of m)e[t.date]||(e[t.date]=[]),e[t.date].push(t);return e},[m]),j=(0,_.useMemo)(()=>{let e={};for(let t of g)t.status===`planned`&&(e[t.date]||(e[t.date]=[]),e[t.date].push(t));return e},[g]);async function ee(e,t,i){n&&(await Kd(n,e,[{text:t,category:i}],r?.id,`planned`),await k(n))}async function te(e){n&&(await Qd(e),await k(n))}function ne(){f===0?(d(e=>e-1),p(11)):p(e=>e-1)}function re(){f===11?(d(e=>e+1),p(0)):p(e=>e+1)}function M(){d(l.getFullYear()),p(l.getMonth())}async function N(){S(!0),w(null);let e=await Tb();w(e.error?i(`error: {e}`).replace(`{e}`,e.error):i(`synced {n} events`).replace(`{n}`,String(e.events??0))),S(!1),n&&await D(n)}function ie(e,t){E({date:e,events:t})}let ae=Mx(l.getFullYear(),l.getMonth(),l.getDate()),P=new Date(u,f+1,0).getDate(),oe=new Date(u,f,1).getDay(),se=new Date(u,f,0).getDate(),ce=[];for(let e=oe-1;e>=0;e--){let t=se-e,n=f===0?11:f-1,r=f===0?u-1:u;ce.push({day:t,date:Mx(r,n,t),inMonth:!1}
66)}for(let e=1;e<=P;e++)ce.push({day:e,date:Mx(u,f,e),inMonth:!0});for(let e=1;ce.length%7!=0;e++){let t=f===11?0:f+1,n=f===11?u+1:u;ce.push({day:e,date:Mx(n,t,e),inMonth:!1})}return(0,R.jsxs)(`div`,{className:Ox.page,children:[(0,R.jsx)(Dx,{date:ae,onPlanned:()=>{n&&(D(n),k(n))}}),(0,R.jsxs)(`div`,{className:Ox.header,children:[(0,R.jsxs)(`div`,{className:Ox.navRow,children:[(0,R.jsx)(`button`,{className:Ox.navBtn,onClick:ne,"aria-label":i(`previous month`),children:`â`}),(0,R.jsx)(`h2`,{className:Ox.monthTitle,children:new Date(u,f,1).toLocaleDateString(o,{month:`long`,year:`numeric`})}),(0,R.jsx)(`button`,{className:Ox.navBtn,onClick:re,"aria-label":i(`next month`),children:`â`}),(0,R.jsx)(`button`,{className:Ox.todayBtn,onClick:M,children:i(`today`)})]}),(0,R.jsxs)(`div`,{className:Ox.headerRight,children:[C&&(0,R.jsx)(`span`,{className:Ox.syncMsg,children:C}),(0,R.jsx)(`button`,{className:Ox.syncBtn,onClick:N,disabled:x||y,children:i(x?`syncingâ¦`:`sync`)})]})]}),(0,R.jsx)(`div`,{className:Ox.dayLabels,children:s.map(e=>(0,R.jsx)(`div`,{className:Ox.dayLabel,children:e},e))}),y?(0,R.jsx)(`div`,{className:Ox.loadingMsg,children:i(`loading calendarâ¦`)}):(0,R.jsx)(`div`,{className:Ox.grid,children:ce.map(({day:e,date:t,inMonth:n})=>{let r=Fx(A[t]??[]),a=j[t]??[],o=t===ae,s=r.length-3;return(0,R.jsxs)(`div`,{className:`${Ox.cell} ${o?Ox.cellToday:``} ${n?``:Ox.cellOut}`,onClick:()=>ie(t,r),style:{cursor:`pointer`},children:[(0,R.jsx)(`span`,{className:`${Ox.dayNum} ${o?Ox.dayNumToday:``} ${n?``:Ox.dayNumOut}`,children:e}),a.length>0&&(0,R.jsxs)(`div`,{className:Ox.plannedBadge,title:`${a.length} ${i(`staged`)}`,children:[a.length,` `,i(`staged`)]}),(0,R.jsxs)(`div`,{className:Ox.chips,children:[r.slice(0,3).map(e=>(0,R.jsxs)(`div`,{className:Ox.chip,title:e.summary,children:[e.raw?.start?.dateTime&&(0,R.jsx)(`span`,{className:Ox.chipTime,children:Nx(e.raw.start.dateTime)}),e.summary]},e.id)),s>0&&(0,R.jsx)(`button`,{className:Ox.chipMore,onClick:e=>{e.stopPropagation(),ie(t,r)},children:i(`+{n} more`).replace(`{n}`,String(s))})]})]},t)})}),T&&(0,R.jsx)(Ix,{date:T.date,events:T.events,planned:j[T.date]??[],dailyTaskCount:c,isPast:T.date<ae,onClose:()=>E(null),onStage:(e,t)=>ee(T.date,e,t),onUnstage:te})]})}var Rx=class extends _.Component{state={error:null,info:``};static getDerivedStateFromError(e){return{error:e}}componentDidCatch(e,t){console.error(`[crew] render error`,e,t.componentStack),this.setState({info:(t.componentStack??``).split(` 67`).slice(0,6).join(` 68`)})}render(){let{error:e,info:t}=this.state;return e?this.props.inline?(0,R.jsxs)(`div`,{style:{padding:`14px 16px`,margin:`8px 0`,borderRadius:6,border:`1px solid rgba(239,68,68,0.35)`,background:`rgba(239,68,68,0.06)`,color:`#c23`,fontSize:12.5,lineHeight:1.55},children:[(0,R.jsxs)(`strong`,{style:{fontWeight:600},children:[this.props.label??`This section`,` could not render.`]}),` `,`The rest of the page is unaffected.`,(0,R.jsxs)(`div`,{style:{marginTop:6,fontFamily:`ui-monospace, Menlo, monospace`,fontSize:11.5,opacity:.85,wordBreak:`break-word`},children:[e.name,`: `,e.message]}),(0,R.jsx)(`button`,{onClick:()=>this.setState({error:null,info:``}),style:{marginTop:8,padding:`4px 10px`,borderRadius:5,cursor:`pointer`,background:`none`,border:`1px solid rgba(239,68,68,0.35)`,color:`inherit`,font:`inherit`},children:`retry this section`})]}):(0,R.jsx)(`div`,{style:{minHeight:`100vh`,display:`grid`,placeItems:`center`,padding:24,background:`#0b0d10`,color:`#e6e8eb`,fontFamily:`ui-monospace, SFMono-Regular, Menlo, monospace`,fontSize:13},children:(0,R.jsxs)(`div`,{style:{maxWidth:720,width:`100%`,display:`flex`,flexDirection:`column`,gap:14},children:[(0,R.jsxs)(`div`,{style:{fontSize:15,fontWeight:600},children:[this.props.label??`This page`,` hit a render error.`]}),(0,R.jsx)(`p`,{style:{margin:0,color:`#9aa3ad`,lineHeight:1.6},children:`The page stopped instead of going blank. Nothing was saved or changed. Copy the message below and it can be fixed directly.`}),(0,R.jsxs)(`pre`,{style:{margin:0,padding:12,borderRadius:6,overflowX:`auto`,background:`#15181c`,border:`1px solid #262b31`,color:`#ff8f8f`,whiteSpace:`pre-wrap`,wordBreak:`break-word`},children:[e.name,`: `,e.message,t?`\n${t}`:``]}),(0,R.jsxs)(`div`,{style:{display:`flex`,gap:10},children:[(0,R.jsx)(`button`,{onClick:()=>this.setState({error:null,info:``}),style:{padding:`8px 14px`,borderRadius:6,cursor:`pointer`,background:`#2d5bff`,color:`#fff`,border:`none`,font:`inherit`,fontWeight:600},children:`try again`}),(0,R.jsx)(`button`,{onClick:()=>{navigator.clipboard?.writeText(`${e.name}: ${e.message}\n${t}`)},style:{padding:`8px 14px`,borderRadius:6,cursor:`pointer`,background:`none`,color:`#9aa3ad`,border:`1px solid #262b31`,font:`inherit`},children:`copy error`}),(0,R.jsx)(`a`,{href:`/app/dashboard`,style:{padding:`8px 14px`,borderRadius:6,color:`#9aa3ad`,border:`1px solid #262b31`,textDecoration:`none`},children:`back to the app`})]})]})}):this.props.children}},Q={dashboard:`_dashboard_fpubm_48`,gate:`_gate_fpubm_49`,swatch:`_swatch_fpubm_84`,swatchDot:`_swatchDot_fpubm_92`,gateCard:`_gateCard_fpubm_111`,gateMsg:`_gateMsg_fpubm_120`,gateBtn:`_gateBtn_fpubm_128`,gateAlt:`_gateAlt_fpubm_151`,header:`_header_fpubm_181`,headerLeft:`_headerLeft_fpubm_196`,headerRight:`_headerRight_fpubm_197`,tabs:`_tabs_fpubm_205`,tab:`_tab_fpubm_205`,tabActive:`_tabActive_fpubm_237`,tabHint:`_tabHint_fpubm_245`,adminTag:`_adminTag_fpubm_251`,liveWrap:`_liveWrap_fpubm_263`,liveDot:`_liveDot_fpubm_265`,liveDotBusy:`_liveDotBusy_fpubm_273`,liveText:`_liveText_fpubm_275`,newBadge:`_newBadge_fpubm_281`,segmented:`_segmented_fpubm_293`,segmentedBtn:`_segmentedBtn_fpubm_302`,
68segmentedBtnActive:`_segmentedBtnActive_fpubm_317`,ghostBtn:`_ghostBtn_fpubm_320`,dangerBtn:`_dangerBtn_fpubm_337`,deleteBtn:`_deleteBtn_fpubm_354`,select:`_select_fpubm_368`,input:`_input_fpubm_369`,linkBtn:`_linkBtn_fpubm_387`,loadingBar:`_loadingBar_fpubm_404`,slide:`_slide_fpubm_1`,errorBanner:`_errorBanner_fpubm_430`,hourRow:`_hourRow_fpubm_450`,hourCell:`_hourCell_fpubm_457`,hourBar:`_hourBar_fpubm_467`,hourLabel:`_hourLabel_fpubm_473`,okBanner:`_okBanner_fpubm_481`,metricRail:`_metricRail_fpubm_493`,metric:`_metric_fpubm_493`,metricValue:`_metricValue_fpubm_505`,metricLabel:`_metricLabel_fpubm_514`,metricSub:`_metricSub_fpubm_523`,headRail:`_headRail_fpubm_535`,headMetric:`_headMetric_fpubm_545`,headLabel:`_headLabel_fpubm_547`,headValueRow:`_headValueRow_fpubm_555`,headValue:`_headValue_fpubm_555`,headSub:`_headSub_fpubm_566`,headNote:`_headNote_fpubm_568`,spark:`_spark_fpubm_576`,delta:`_delta_fpubm_582`,deltaUp:`_deltaUp_fpubm_591`,deltaDown:`_deltaDown_fpubm_592`,deltaFlat:`_deltaFlat_fpubm_593`,deltaMark:`_deltaMark_fpubm_595`,deltaUpMark:`_deltaUpMark_fpubm_597`,deltaDownMark:`_deltaDownMark_fpubm_604`,deltaFlatMark:`_deltaFlatMark_fpubm_611`,deltaWin:`_deltaWin_fpubm_613`,deviceRow:`_deviceRow_fpubm_617`,stackBar:`_stackBar_fpubm_625`,stackSeg:`_stackSeg_fpubm_639`,compRow:`_compRow_fpubm_641`,compLegend:`_compLegend_fpubm_651`,compItem:`_compItem_fpubm_653`,barList:`_barList_fpubm_658`,barRow:`_barRow_fpubm_660`,barLabel:`_barLabel_fpubm_672`,barTrack:`_barTrack_fpubm_682`,barFill:`_barFill_fpubm_683`,barValue:`_barValue_fpubm_684`,barSub:`_barSub_fpubm_685`,section:`_section_fpubm_689`,sectionHead:`_sectionHead_fpubm_695`,sectionTitle:`_sectionTitle_fpubm_704`,sectionSub:`_sectionSub_fpubm_713`,sectionNote:`_sectionNote_fpubm_722`,sectionActions:`_sectionActions_fpubm_732`,tableWrap:`_tableWrap_fpubm_736`,table:`_table_fpubm_736`,thNum:`_thNum_fpubm_761`,numCell:`_numCell_fpubm_777`,numSub:`_numSub_fpubm_778`,numInline:`_numInline_fpubm_779`,subtleCell:`_subtleCell_fpubm_780`,emailCell:`_emailCell_fpubm_781`,dateCell:`_dateCell_fpubm_782`,refCell:`_refCell_fpubm_783`,sourceList:`_sourceList_fpubm_784`,reportCell:`_reportCell_fpubm_786`,reportText:`_reportText_fpubm_787`,reportMeta:`_reportMeta_fpubm_788`,typeLabel:`_typeLabel_fpubm_797`,severity:`_severity_fpubm_798`,recheckNote:`_recheckNote_fpubm_807`,pagerRow:`_pagerRow_fpubm_817`,pagerLabel:`_pagerLabel_fpubm_825`,toneGood:`_toneGood_fpubm_831`,toneWarn:`_toneWarn_fpubm_832`,toneBad:`_toneBad_fpubm_833`,toneNeutral:`_toneNeutral_fpubm_834`,mark:`_mark_fpubm_838`,markGood:`_markGood_fpubm_839`,markWarn:`_markWarn_fpubm_840`,markBad:`_markBad_fpubm_846`,markNeutral:`_markNeutral_fpubm_847`,badge:`_badge_fpubm_849`,distGrid:`_distGrid_fpubm_860`,dist:`_dist_fpubm_860`,distHead:`_distHead_fpubm_868`,distTitle:`_distTitle_fpubm_877`,distTotal:`_distTotal_fpubm_885`,distNote:`_distNote_fpubm_887`,distRow:`_distRow_fpubm_889`,distLabel:`_distLabel_fpubm_901`,distTrack:`_distTrack_fpubm_911`,distFill:`_distFill_fpubm_918`,distCount:`_distCount_fpubm_925`,distPct:`_distPct_fpubm_926`,chart:`_chart_fpubm_935`,chartHead:`_chartHead_fpubm_937`,chartLegend:`_chartLegend_fpubm_945`,legendItem:`_legendItem_fpubm_947`,legendItemOff:`_legendItemOff_fpubm_963`,legendNum:`_legendNum_fpubm_964`,chartBody:`_chartBody_fpubm_966`,chartYAxis:`_chartYAxis_fpubm_968`,chartYLabel:`_chartYLabel_fpubm_970`,chartPlot:`_chartPlot_fpubm_979`,chartSvg:`_chartSvg_fpubm_982`,chartEnd:`_chartEnd_fpubm_984`,chartPt:`_chartPt_fpubm_985`,chartCross:`_chartCross_fpubm_997`,chartTip:`_chartTip_fpubm_1006`,chartTipDate:`_chartTipDate_fpubm_1022`,chartTipRow:`_chartTipRow_fpubm_1029`,chartTipLabel:`_chartTipLabel_fpubm_1030`,chartTipVal:`_chartTipVal_fpubm_1031`,chartXAxis:`_chartXAxis_fpubm_1033`,chartXLabel:`_chartXLabel_fpubm_1035`,cols:`_cols_fpubm_1046`,colsPlot:`_colsPlot_fpubm_1048`,colsGrid:`_colsGrid_fpubm_1050`,colsMax:`_colsMax_fpubm_1058`,colsTrack:`_colsTrack_fpubm_1067`,col:`_col_fpubm_1046`,colPeak:`_colPeak_fpubm_1092`,colSeg:`_colSeg_fpubm_1094`,colsAxis:`_colsAxis_fpubm_1096`,colsTick:`_colsTick_fpubm_1098`,pagesList:`_pagesList_fpubm_1109`,pagesR
68ow:`_pagesRow_fpubm_1111`,pagesPath:`_pagesPath_fpubm_1123`,pagesBarTrack:`_pagesBarTrack_fpubm_1130`,pagesBarFill:`_pagesBarFill_fpubm_1131`,pagesCount:`_pagesCount_fpubm_1132`,usageVolume:`_usageVolume_fpubm_1136`,usageVolumeHead:`_usageVolumeHead_fpubm_1138`,usageVolumeTitle:`_usageVolumeTitle_fpubm_1147`,usageVolumeCount:`_usageVolumeCount_fpubm_1155`,usageFilters:`_usageFilters_fpubm_1159`,usageFilterRow:`_usageFilterRow_fpubm_1166`,usageFilterLabel:`_usageFilterLabel_fpubm_1173`,usageLegend:`_usageLegend_fpubm_1180`,usageLegendItem:`_usageLegendItem_fpubm_1182`,usageLegendItemOff:`_usageLegendItemOff_fpubm_1198`,usageLegendCount:`_usageLegendCount_fpubm_1199`,usageDowGroup:`_usageDowGroup_fpubm_1201`,usageDowChip:`_usageDowChip_fpubm_1203`,usageDowChipOff:`_usageDowChipOff_fpubm_1214`,usageHourGroup:`_usageHourGroup_fpubm_1216`,usageHourSelect:`_usageHourSelect_fpubm_1218`,usageInput:`_usageInput_fpubm_1229`,usageTzToggle:`_usageTzToggle_fpubm_1243`,usageTzActive:`_usageTzActive_fpubm_1260`,ribbon:`_ribbon_fpubm_1179`,ribbonAxis:`_ribbonAxis_fpubm_1268`,ribbonRow:`_ribbonRow_fpubm_1269`,ribbonAxisName:`_ribbonAxisName_fpubm_1281`,ribbonAxisTrack:`_ribbonAxisTrack_fpubm_1282`,ribbonAxisCell:`_ribbonAxisCell_fpubm_1284`,ribbonAxisTick:`_ribbonAxisTick_fpubm_1286`,ribbonAxisMeta:`_ribbonAxisMeta_fpubm_1296`,ribbonRowQuiet:`_ribbonRowQuiet_fpubm_1311`,ribbonName:`_ribbonName_fpubm_1311`,ribbonCount:`_ribbonCount_fpubm_1312`,ribbonLast:`_ribbonLast_fpubm_1313`,ribbonTrack:`_ribbonTrack_fpubm_1326`,ribbonCell:`_ribbonCell_fpubm_1342`,ribbonDot:`_ribbonDot_fpubm_1179`,ribbonDotSel:`_ribbonDotSel_fpubm_1367`,ribbonFoot:`_ribbonFoot_fpubm_1386`,ribbonFootText:`_ribbonFootText_fpubm_1396`,ribbonFootActions:`_ribbonFootActions_fpubm_1397`,usageDetail:`_usageDetail_fpubm_1403`,usageDetailHead:`_usageDetailHead_fpubm_1409`,usageDetailTitle:`_usageDetailTitle_fpubm_1416`,usageDetailCount:`_usageDetailCount_fpubm_1417`,usageDetailClose:`_usageDetailClose_fpubm_1419`,usageDetailList:`_usageDetailList_fpubm_1432`,usageDetailItem:`_usageDetailItem_fpubm_1434`,usageDetailTime:`_usageDetailTime_fpubm_1445`,usageDetailEvent:`_usageDetailEvent_fpubm_1446`,usageDetailPath:`_usageDetailPath_fpubm_1447`,usageDetailMore:`_usageDetailMore_fpubm_1448`,chipRow:`_chipRow_fpubm_1452`,featureChip:`_featureChip_fpubm_1454`,empty:`_empty_fpubm_1468`,emptyInline:`_emptyInline_fpubm_1474`,drawerBackdrop:`_drawerBackdrop_fpubm_1478`,drawer:`_drawer_fpubm_1478`,drawerHead:`_drawerHead_fpubm_1500`,drawerTitle:`_drawerTitle_fpubm_1507`,drawerSub:`_drawerSub_fpubm_1516`,drawerClose:`_drawerClose_fpubm_1518`,drawerMetaRow:`_drawerMetaRow_fpubm_1531`,drawerSection:`_drawerSection_fpubm_1543`,drawerSectionLabel:`_drawerSectionLabel_fpubm_1545`,defList:`_defList_fpubm_1553`,defRow:`_defRow_fpubm_1555`,defTerm:`_defTerm_fpubm_1565`,defVal:`_defVal_fpubm_1566`,heatmapWrap:`_heatmapWrap_fpubm_1570`,heatmapCol:`_heatmapCol_fpubm_1571`,heatmapCell:`_heatmapCell_fpubm_1572`,heatmapCellEmpty:`_heatmapCellEmpty_fpubm_1573`,auditList:`_auditList_fpubm_1577`,auditRow:`_auditRow_fpubm_1579`,auditEvent:`_auditEvent_fpubm_1591`,auditDetail:`_auditDetail_fpubm_1592`,auditTime:`_auditTime_fpubm_1593`,histMonthLabel:`_histMonthLabel_fpubm_1612`,histGrid:`_histGrid_fpubm_1620`,histDow:`_histDow_fpubm_1628`,histBlank:`_histBlank_fpubm_1636`,histCell:`_histCell_fpubm_1638`,histCellNum:`_histCellNum_fpubm_1651`,histCellDash:`_histCellDash_fpubm_1652`,histCellGood:`_histCellGood_fpubm_1654`,histCellMid:`_histCellMid_fpubm_1655`,histCellBad:`_histCellBad_fpubm_1656`,histCellEmpty:`_histCellEmpty_fpubm_1659`,histCellFuture:`_histCellFuture_fpubm_1660`,histCellBefore:`_histCellBefore_fpubm_1661`,histCellToday:`_histCellToday_fpubm_1662`,histSwatch:`_histSwatch_fpubm_1666`,histLegend:`_histLegend_fpubm_1676`,histDays:`_histDays_fpubm_1687`,histDay:`_histDay_fpubm_1687`,histDayHead:`_histDayHead_fpubm_1691`,histDayDate:`_histDayDate_fpubm_1692`,histDayScore:`_histDayScore_fpubm_1693`,histDayEmpty:`_histDayEmpty_fpubm_1694`,histDayTag:`_histDayTag_fpubm_1696`,histTask:`_histTask_fpubm_1704`,histTaskMain:`_histTaskMain_fpubm_1712`,histTaskText:`_histTaskText_fpubm_1714`,histTaskTextOut:`_histTaskTextOut_fpubm_1715`,histTaskMeta:`_histTaskMeta_fpubm_1719`,histChip:`_histChip_fpubm_1721`,histChipOut:`_histChipOut_fpubm_1722`,histRetractReason:`_histRetractReason_fpubm_1730`,histTaskActions:`_histTaskActions_fpubm_1732`,histConfirm:`_histConfirm_fpubm_1734`,histConfirmMsg:`_histConfirmMsg_fpubm_1747`,histConfirmErr:`_histConfirmErr_fpubm_1748`,histConfirmRow:`_histConfirmRow_fpubm_1749`,histNoAction:`_histNoAction_fpubm_1756`},zx=`[email protected]`,Bx=`https://zwqymcoehifdzniztfzc.supabase.co`,Vx=`sb_publishable_6QWCzHIJSqJQYa0litEekQ_-0Kvihox`,Hx=50,Ux=6e4,Wx=5e3,Gx=``;function Kx(){return{apikey:Vx,Authorization:`Bearer ${Gx}`,"Content-Type":`application/json`}}var qx=e=>Array.isArray(e)?e:[],$=(e,t=0)=>typeof e==`number`&&Number.isFinite(e)?e:t,Jx=e=>e.reduce((e,t)=>
68e+$(t),0),Yx=(e,t=1)=>e.reduce((e,t)=>Number.isFinite(t)&&t>e?t:e,t),Xx=e=>e&&typeof e==`object`&&!Array.isArray(e)?e:{};function Zx(e){let t=Xx(e),n={};for(let[e,r]of Object.entries(t))typeof r==`number`&&Number.isFinite(r)&&(n[e]=r);return n}function Qx(e,t){let n=Xx(e),r=qx(n.rows);return{rows:r,total:$(n.total,r.length),page:$(n.page,0),pageSize:$(n.pageSize,t)||t}}function $x(e){let t=e??{};return{range:t.range??`30d`,topPages:qx(t.topPages),lockTimeHistogram:qx(t.lockTimeHistogram),categoryDistribution:Zx(t.categoryDistribution),statusDistribution:Zx(t.statusDistribution),resolutionDistribution:Zx(t.resolutionDistribution),verdictCounts:Zx(t.verdictCounts),taskVolume:$(t.taskVolume),waitlistCount:$(t.waitlistCount),waitlistEntries:qx(t.waitlistEntries),signupCount:$(t.signupCount),signups:qx(t.signups),uniqueVisitors:$(t.uniqueVisitors),totalPageViews:$(t.totalPageViews),devices:{mobile:$(Xx(t.devices).mobile),tablet:$(Xx(t.devices).tablet),desktop:$(Xx(t.devices).desktop)},dailyFlux:qx(t.dailyFlux).map(e=>({date:String(Xx(e).date??``),visitors:$(Xx(e).visitors),views:$(Xx(e).views)})).filter(e=>e.date!==``),mrr:$(t.mrr),arr:$(t.arr),activeSubscriptions:$(t.activeSubscriptions),trialCount:$(t.trialCount),stripeSubscriptions:qx(t.stripeSubscriptions),wau:$(t.wau),mau:$(t.mau),featureAdoption:{github:$(Xx(t.featureAdoption).github),google_calendar:$(Xx(t.featureAdoption).google_calendar),x:$(Xx(t.featureAdoption).x),discord:$(Xx(t.featureAdoption).discord),telegram:$(Xx(t.featureAdoption).telegram)}}}async function eS(e){let t=await fetch(`${Bx}/functions/v1/admin-stats?range=${e}`,{headers:Kx()});if(!t.ok)throw Error(`${t.status} ${await t.text()}`);return $x(await t.json())}async function tS(){let e=await fetch(`${Bx}/functions/v1/admin-stats?action=blog`,{headers:Kx()});if(!e.ok)throw Error(`${e.status} ${await e.text()}`);let t=Xx(await e.json()),n=Xx(t.health),r=Xx(t.counts);return{posts:Array.isArray(t.posts)?t.posts:[],events:Array.isArray(t.events)?t.events:[],counts:{published:$(r.published),updated:$(r.updated),refused:$(r.refused),failed:$(r.failed)},bySource:Xx(t.bySource),livePosts:$(t.livePosts),health:{broken:n.broken===!0,lastSuccessAt:typeof n.lastSuccessAt==`string`?n.lastSuccessAt:null,lastFailureAt:typeof n.lastFailureAt==`string`?n.lastFailureAt:null,lastFailureDetail:typeof n.lastFailureDetail==`string`?n.lastFailureDetail:``}}}var nS={published:`good`,updated:`good`,refused:`warn`,failed:`bad`};function rS(){let[e,t]=(0,_.useState)(null),[n,r]=(0,_.useState)(null),[i,a]=(0,_.useState)(!0),o=(0,_.useCallback)(async()=>{a(!0);try{t(await tS()),r(null)}catch(e){r(e instanceof Error?e.message:String(e))}finally{a(!1)}},[]);if((0,_.useEffect)(()=>{o()},[o]),i&&!e)return(0,R.jsx)(`section`,{className:Q.section,children:(0,R.jsx)(`div`,{className:Q.empty,children:`loading the blogâ¦`})});if(n)return(0,R.jsx)(`section`,{className:Q.section,children:(0,R.jsxs)(`div`,{className:Q.errorBanner,children:[n,` â `,(0,R.jsx)(`button`,{onClick:()=>void o(),children:`retry`})]})});if(!e)return null;let s=e.counts.published+e.counts.updated+e.counts.refused+e.counts.failed,c=Object.entries(e.bySource).sort((e,t)=>t[1]-e[1]);return(0,R.jsxs)(R.Fragment,{children:[(0,R.jsxs)(`section`,{className:Q.section,children:[(0,R.jsxs)(`div`,{className:Q.sectionHead,children:[(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`h2`,{className:Q.sectionTitle,children:`Publishing`}),(0,R.jsxs)(`p`,{className:Q.sectionSub,children:[e.livePosts,` live `,e.livePosts===1?`post`:`posts`,` · `,s,` recorded `,s===1?`attempt`:`attempts`]}),(0,R.jsx)(`p`,{className:Q.sectionNote,children:`An external writer POSTs to blog-webhook, which commits markdown to the repo and triggers a rebuild. Refusals and credential failures are recorded here too â those never reach the site, which is exactly why they used to go unnoticed.`})]}),(0,R.jsx)(`div`,{className:Q.sectionActions,children:(0,R.jsx)(`button`,{className:Q.ghostBtn,onClick:()=>void o(),disabled:i,children:`refresh`})})]}),(0,R.jsx)(`div`,{className:e.health.broken?Q.errorBanner:Q.okBanner,children:e.health.broken?(0,R.jsxs)(R.Fragment,{children:[`Publishing is failing. Last error: `,e.health.lastFailureDetail||`no detail recorded`]}):(0,R.jsxs)(R.Fragment,{children:[`Publishing is healthy`,e.health.lastSuccessAt?(0,R.jsxs)(R.Fragment,{children:[` â last post committed `,dC(e.health.lastSuccessAt)]}):null,`.`]})}),(0,R.jsxs)(`div`,{className:Q.metricRail,children:[(0,R.jsx)(xS,{label:`live posts`,value:e.livePosts,sub:`latest version of each slug`}),(0,R.jsx)(xS,{label:`published`,value:e.counts.published,sub:`first-time commits`}
68),(0,R.jsx)(xS,{label:`rewritten`,value:e.counts.updated,sub:`same slug, new content`}),(0,R.jsx)(xS,{label:`refused`,value:e.counts.refused,sub:`a claim the product cannot back`}),(0,R.jsx)(xS,{label:`failed`,value:e.counts.failed,sub:`never reached the repo`})]}),c.length>0&&(0,R.jsxs)(`p`,{className:Q.sectionNote,children:[`By writer: `,c.map(([e,t])=>`${e} ${t}`).join(` · `)]})]}),(0,R.jsxs)(`section`,{className:Q.section,children:[(0,R.jsx)(`div`,{className:Q.sectionHead,children:(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`h2`,{className:Q.sectionTitle,children:`Posts`}),(0,R.jsx)(`p`,{className:Q.sectionSub,children:`what is on the site right now`})]})}),e.posts.length===0?(0,R.jsx)(`div`,{className:Q.empty,children:`nothing published yet`}):(0,R.jsx)(`div`,{className:Q.tableWrap,children:(0,R.jsxs)(`table`,{className:Q.table,children:[(0,R.jsx)(`thead`,{children:(0,R.jsxs)(`tr`,{children:[(0,R.jsx)(`th`,{children:`title`}),(0,R.jsx)(`th`,{children:`slug`}),(0,R.jsx)(`th`,{children:`writer`}),(0,R.jsx)(`th`,{className:Q.thNum,children:`revisions`}),(0,R.jsx)(`th`,{children:`date`}),(0,R.jsx)(`th`,{children:`last touched`}),(0,R.jsx)(`th`,{})]})}),(0,R.jsx)(`tbody`,{children:e.posts.map(e=>(0,R.jsxs)(`tr`,{children:[(0,R.jsxs)(`td`,{children:[e.title||`â`,e.draft&&(0,R.jsxs)(R.Fragment,{children:[` `,(0,R.jsx)(WS,{label:`draft`,tone:`warn`})]})]}),(0,R.jsx)(`td`,{className:Q.subtleCell,children:e.slug}),(0,R.jsx)(`td`,{className:Q.subtleCell,children:e.source}),(0,R.jsx)(`td`,{className:Q.numCell,children:e.revisions}),(0,R.jsx)(`td`,{className:Q.dateCell,children:e.postDate??`â`}),(0,R.jsx)(`td`,{className:Q.dateCell,children:dC(e.lastTouched)}),(0,R.jsx)(`td`,{children:e.url?(0,R.jsx)(`a`,{className:Q.linkBtn,href:e.url,target:`_blank`,rel:`noreferrer`,children:`view`}):(0,R.jsx)(`span`,{className:Q.numSub,children:`not live`})})]},e.slug))})]})})]}),(0,R.jsxs)(`section`,{className:Q.section,children:[(0,R.jsx)(`div`,{className:Q.sectionHead,children:(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`h2`,{className:Q.sectionTitle,children:`Attempts`}),(0,R.jsx)(`p`,{className:Q.sectionSub,children:`every call the webhook handled, including the ones that went nowhere`})]})}),e.events.length===0?(0,R.jsx)(`div`,{className:Q.empty,children:`no attempts recorded yet`}):(0,R.jsx)(`div`,{className:Q.tableWrap,children:(0,R.jsxs)(`table`,{className:Q.table,children:[(0,R.jsx)(`thead`,{children:(0,R.jsxs)(`tr`,{children:[(0,R.jsx)(`th`,{children:`when`}),(0,R.jsx)(`th`,{children:`outcome`}),(0,R.jsx)(`th`,{children:`title`}),(0,R.jsx)(`th`,{children:`writer`}),(0,R.jsx)(`th`,{children:`detail`})]})}),(0,R.jsx)(`tbody`,{children:e.events.map(e=>(0,R.jsxs)(`tr`,{children:[(0,R.jsx)(`td`,{className:Q.dateCell,children:dC(e.at)}),(0,R.jsx)(`td`,{children:(0,R.jsx)(WS,{label:e.outcome,tone:nS[e.outcome]??`neutral`})}),(0,R.jsx)(`td`,{children:e.title||e.slug}),(0,R.jsx)(`td`,{className:Q.subtleCell,children:e.source}),(0,R.jsx)(`td`,{className:Q.subtleCell,children:e.detail||`â`})]},e.id))})]})})]})]})}async function iS(){let e=await fetch(`${Bx}/functions/v1/admin-stats?action=proactive`,{headers:Kx()});if(!e.ok)throw Error(`${e.status} ${await e.text()}`);let t=Xx(await e.json()),n=Xx(t.counts);return{events:Array.isArray(t.events)?t.events:[],counts:{total:$(n.total),users:$(n.users)},byKind:Xx(t.byKind),byTrigger:Xx(t.byTrigger),byHour:Xx(t.byHour),landed:{resolved:$(Xx(t.landed).resolved),ignored:$(Xx(t.landed).ignored),moot:$(Xx(t.landed).moot),pending:$(Xx(t.landed).pending)},landedPct:typeof t.landedPct==`number`?t.landedPct:null}}var aS={verified:`good`,connector_broke:`bad`,hollow_milestone:`warn`,pace_slipped:`warn`,day_at_risk:`warn`,drift:`warn`,analysis:`neutral`};function oS({onSelectUser:e}){let[t,n]=(0,_.useState)(null),[r,i]=(0,_.useState)(null),[a,o]=(0,_.useState)(!0),s=(0,_.useCallback)(async()=>{o(!0);try{n(await iS()),i(null)}catch(e){i(e instanceof Error?e.message:String(e))}finally{o(!1)}},[]);if((0,_.useEffect)(()=>{s()},[s]),a&&!t)return(0,R.jsx)(`section`,{className:Q.section,children:(0,R.jsx)(`div`,{className:Q.empty,children:`loadingâ¦`})});if(r)return(0,R.jsx)(`section`,{className:Q.section,children:(0,R.jsxs)(`div`,{className:Q.errorBanner,children:[r,` â `,(0,R.jsx)(`button`,{onClick:()=>void s(),children:`retry`})]})});if(!t)return null;
68let c=Array.from({length:24},(e,n)=>({h:n,n:$(t.byHour[String(n)])})),l=Math.max(1,...c.map(e=>e.n));return(0,R.jsxs)(`section`,{className:Q.section,children:[(0,R.jsxs)(`div`,{className:Q.sectionHead,children:[(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`h2`,{className:Q.sectionTitle,children:`Proactive messages`}),(0,R.jsxs)(`p`,{className:Q.sectionSub,children:[t.counts.total,` sent unprompted to `,t.counts.users,` `,t.counts.users===1?`account`:`accounts`]}),(0,R.jsx)(`p`,{className:Q.sectionNote,children:`Events fire when state changes; an analysis fires at a per-account time derived from the day, so it lands somewhere different each day. Message text is shown for your own account only â some of these quote a founder's own task titles back to them, and that stays theirs.`})]}),(0,R.jsx)(`div`,{className:Q.sectionActions,children:(0,R.jsx)(`button`,{className:Q.ghostBtn,onClick:()=>void s(),disabled:a,children:`refresh`})})]}),t.counts.total===0?(0,R.jsx)(`div`,{className:Q.empty,children:`nothing sent yet`}):(0,R.jsxs)(R.Fragment,{children:[(0,R.jsxs)(`div`,{className:Q.metricRail,children:[Object.entries(t.byKind).sort((e,t)=>t[1]-e[1]).map(([e,t])=>(0,R.jsx)(xS,{label:e.replace(/_/g,` `),value:t},e)),(0,R.jsx)(xS,{label:`from an event`,value:$(t.byTrigger.event),sub:`state changed`}),(0,R.jsx)(xS,{label:`from analysis`,value:$(t.byTrigger.analysis),sub:`no set time`})]}),(0,R.jsxs)(`div`,{className:Q.metricRail,children:[(0,R.jsx)(xS,{label:`landed`,value:t.landedPct===null?`â`:`${t.landedPct}%`,sub:t.landedPct===null?`nothing decided yet`:`${t.landed.resolved} of ${t.landed.resolved+t.landed.ignored} decided`}),(0,R.jsx)(xS,{label:`resolved`,value:t.landed.resolved,sub:`the flagged thing changed`}),(0,R.jsx)(xS,{label:`ignored`,value:t.landed.ignored,sub:`nothing moved`}),(0,R.jsx)(xS,{label:`moot`,value:t.landed.moot,sub:`stopped applying; not scored`}),(0,R.jsx)(xS,{label:`pending`,value:t.landed.pending,sub:`inside the 3-day grace`})]}),(0,R.jsx)(`div`,{className:Q.sectionHead,children:(0,R.jsx)(`div`,{children:(0,R.jsx)(`p`,{className:Q.sectionSub,children:`when they landed, by hour (UTC) â a flat spread is the point`})})}),(0,R.jsx)(`div`,{className:Q.hourRow,children:c.map(({h:e,n:t})=>(0,R.jsxs)(`span`,{className:Q.hourCell,title:`${e}:00 â ${t}`,children:[(0,R.jsx)(`span`,{className:Q.hourBar,style:{height:`${Math.round(t/l*100)}%`}}),(0,R.jsx)(`span`,{className:Q.hourLabel,children:e%6==0?e:``})]},e))}),(0,R.jsx)(`div`,{className:Q.tableWrap,children:(0,R.jsxs)(`table`,{className:Q.table,children:[(0,R.jsx)(`thead`,{children:(0,R.jsxs)(`tr`,{children:[(0,R.jsx)(`th`,{children:`when`}),(0,R.jsx)(`th`,{children:`noticed`}),(0,R.jsx)(`th`,{children:`trigger`}),(0,R.jsx)(`th`,{children:`outcome`}),(0,R.jsx)(`th`,{children:`about`}),(0,R.jsx)(`th`,{children:`message`}),(0,R.jsx)(`th`,{})]})}),(0,R.jsx)(`tbody`,{children:t.events.map(t=>(0,R.jsxs)(`tr`,{children:[(0,R.jsx)(`td`,{className:Q.dateCell,children:dC(t.at)}),(0,R.jsx)(`td`,{children:(0,R.jsx)(WS,{label:t.kind.replace(/_/g,` `),tone:aS[t.kind]??`neutral`})}),(0,R.jsx)(`td`,{className:Q.subtleCell,children:t.trigger}),(0,R.jsxs)(`td`,{children:[t.outcome?(0,R.jsx)(WS,{label:t.outcome,tone:t.outcome===`resolved`?`good`:t.outcome===`ignored`?`bad`:`neutral`}):(0,R.jsx)(`span`,{className:Q.numSub,children:`pending`}),t.outcomeNote&&(0,R.jsx)(`div`,{className:Q.numSub,children:t.outcomeNote})]}),(0,R.jsx)(`td`,{className:Q.subtleCell,children:t.subject||`â`}),(0,R.jsx)(`td`,{children:t.title||(0,R.jsx)(`span`,{className:Q.numSub,children:`hidden (not your account)`})}),(0,R.jsx)(`td`,{children:(0,R.jsx)(`button`,{className:Q.linkBtn,onClick:()=>e(t.userId),children:`account`})})]},t.id))})]})})]})]})}async function sS(e){let t=await fetch(`${Bx}/functions/v1/admin-stats?action=user_detail&id=${e}`,{headers:Kx()});if(!t.ok)throw Error(`${t.status} ${await t.text()}`);let n=Xx(await t.json()),r=n.metrics?Xx(n.metrics):null;return{profile:Xx(n.profile),email:typeof n.email==`string`?n.email:null,lastSignInAt:typeof n.lastSignInAt==`string`?n.lastSignInAt:null,metrics:r?{tasksCreated:$(r.tasksCreated),tasksLocked:$(r.tasksLocked),tasksCompleted:$(r.tasksCompleted),completionRate:$(r.completionRate),currentStreak:$(r.currentStreak),longestStreak:$(r.longestStreak),lastActive:typeof r.lastActive==`string`?r.lastActive:null,totalMessages:$(r.totalMessages),sessionCount:$(r.sessionCount),avgSessionMinutes:$(r.avgSessionMinutes),activeDaysLast7:$(r.activeDaysLast7),activeDaysLast30:$(r.activeDaysLast30),connectors:qx(r.connectors),telegramLinked:r.telegramLinked===!0,consistency:$(r.consistency)}:null,dailyActivity:qx(n.dailyActivity).map(e=>({date:String(Xx(e).date??``),count:$(Xx(e).count)})).filter(e=>e.date!==``),auditLog:qx(n.auditLog).map(e=>{let t=Xx(e);return{id:String(t.id??``),event_type:String(t.event_type??`unknown`),detail:Xx(t.detail),created_at:String(t.created_at??``)}})}}async function cS(e){let t=new URLSearchParams({action:`audit_log`});e.userId&&t.set(`user_id`,e.userId),e.eventType&&t.set(`event_type`,e.eventType),e.search&&t.set(`search`,e.search),e.page&&t.set(`page`,String(e.page));let n=await fetch(`${Bx}/functions/v1/admin-stats?${t}`,{headers:Kx()});if(!n.ok)throw Error(`${n.status} ${await n.text()}`);return Qx(await n.json(),Hx)}async function lS(e){let t=new URLSearchParams({action:`feedback`});e.status&&t.set(`status`,e.status),e.type&&t.set(`type`,e.type),e.page&&t.set(`page`,String(e.page));let n=await fetch(`${Bx}/functions/v1/admin-stats?${t}`,{headers:Kx()});if(!n.ok)throw Error(`${n.status} ${await n.text()}`);return Qx(await n.json(),Hx)}function uS(e){let t=Xx(e);if(Object.keys(t).length!==0)return{total:$(t.total),byLabel:Zx(t.byLabel),byEvidenceSource:Zx(t.byEvidenceSource),withEvidence:$(t.withEvidence),withoutEvidence:$(t.withoutEvidence),avgConfidence:$(t.avgConfidence)}}async function dS(e){let t=new URLSearchParams({action:`verification_records`});e.verdict&&t.set(`verdict`,e.verdict),e.page&&t.set(`page`,String(e.page));let n=await fetch(`${Bx}/functions/v1/admin-stats?${t}`,{headers:Kx()});if(!n.ok)throw Error(`${n.status} ${await n.text()}`);let r=await n.json(),i=Qx(r,Hx);return{...i,rows:i.rows.map(e=>({...e,confidence:$(e.confidence),evidenceCount:$(e.evidenceCount),evidenceSources:qx(e.evidenceSources)})),summary:uS(Xx(r).summary)}}async function fS(e){let t=await fetch(`${Bx}/functions/v1/admin-stats?action=reverify_task&id=${e}`,{headers:Kx()});if(!t.ok)throw Error(await t.text());return t.json()}async function pS(e){let t=await fetch(`${Bx}/functions/v1/admin-stats?action=usage_events&range=${e}`,{headers:Kx()});if(!t.ok)throw Error(`${t.status} ${await t.text()}`);
68let n=Xx(await t.json()),r=qx(n.events).map(e=>{let t=Xx(e);return{at:String(t.at??``),event:String(t.event??`unknown`),path:typeof t.path==`string`?t.path:null,userId:typeof t.userId==`string`?t.userId:null,userName:typeof t.userName==`string`?t.userName:null}}).filter(e=>e.at!==``&&!isNaN(new Date(e.at).getTime()));return{events:r,total:$(n.total,r.length)}}async function mS(e){let t=new URLSearchParams(e).toString(),n=await fetch(`${Bx}/functions/v1/admin-stats?${t}`,{headers:Kx()});if(!n.ok)throw Error(await n.text())}var hS=(e,t=``)=>typeof e==`string`?e:t,gS=e=>typeof e==`string`&&e!==``?e:null;function _S(e,t){let n=Xx(e);return{today:hS(n.today,new Date().toLocaleDateString(`en-CA`)),month:/^\d{4}-\d{2}$/.test(hS(n.month))?hS(n.month):t,firstDate:gS(n.firstDate),months:qx(n.months).map(e=>{let t=Xx(e);return{month:hS(t.month),locked:$(t.locked),done:$(t.done),activeDays:$(t.activeDays),emptyDays:$(t.emptyDays)}}).filter(e=>/^\d{4}-\d{2}$/.test(e.month)),days:qx(n.days).map(e=>{let t=Xx(e),n=$(t.locked);return{date:hS(t.date),isFuture:t.isFuture===!0,isToday:t.isToday===!0,beforeStart:t.beforeStart===!0,locked:n,done:$(t.done),missed:$(t.missed),open:$(t.open),score:typeof t.score==`number`&&Number.isFinite(t.score)?t.score:null,good:typeof t.good==`boolean`?t.good:null,tasks:qx(t.tasks).map(e=>{let t=Xx(e);return{id:hS(t.id),text:hS(t.text,`(no text)`),category:hS(t.category,`build`),status:hS(t.status,`pending`),resolution:gS(t.resolution),resolvedLate:t.resolvedLate===!0,unplanned:t.unplanned===!0,carryCount:$(t.carryCount),lockedAt:gS(t.lockedAt),retracted:t.retracted===!0,retractedReason:gS(t.retractedReason),retractedAt:gS(t.retractedAt)}}).filter(e=>e.id!==``)}}).filter(e=>/^\d{4}-\d{2}-\d{2}$/.test(e.date))}}async function vS(e){let t=await fetch(`${Bx}/functions/v1/admin-stats?action=my_history&month=${e}`,{headers:Kx()});if(!t.ok)throw Error(`${t.status} ${await t.text()}`);return _S(await t.json(),e)}async function yS(e){let t=new URLSearchParams(e).toString(),n=await fetch(`${Bx}/functions/v1/admin-stats?${t}`,{headers:Kx()});if(n.ok)return;let r=`${n.status}`;try{let e=Xx(await n.json());typeof e.error==`string`&&e.error&&(r=e.error)}catch{}throw Error(r)}function bS({status:e}){return(0,R.jsx)(`div`,{className:Q.gate,children:(0,R.jsxs)(`div`,{className:Q.gateCard,children:[(0,R.jsx)(El,{size:20}),e===`loading`&&(0,R.jsx)(`p`,{className:Q.gateMsg,children:`loadingâ¦`}),e===`signed_out`&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`p`,{className:Q.gateMsg,children:`Sign in with the founder account to view this page.`}),(0,R.jsx)(`a`,{href:`/auth`,className:Q.gateBtn,children:`Sign in`})]}),e===`wrong_account`&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`p`,{className:Q.gateMsg,children:`This page isn't available on this account.`}),(0,R.jsx)(`button`,{type:`button`,className:Q.gateBtn,onClick:async()=>{await oh(),window.location.href=`/auth`},children:`Switch account`}),(0,R.jsx)(`a`,{href:`/app`,className:Q.gateAlt,children:`back to the app`})]})]})})}function xS({label:e,value:t,sub:n}){return(0,R.jsxs)(`div`,{className:Q.metric,children:[(0,R.jsx)(`span`,{className:Q.metricValue,children:t}),(0,R.jsx)(`span`,{className:Q.metricLabel,children:e}),n&&(0,R.jsx)(`span`,{className:Q.metricSub,children:n})]})}var SS=6,CS=e=>`var(--ad-c${e%SS+1})`,wS=e=>`var(--ad-c${e%SS+1}-weak)`;function TS(e){if(!Number.isFinite(e))return`0`;let t=Math.abs(e);return t>=1e6?`${(e/1e6).toFixed(1)}M`:t>=1e4?`${Math.round(e/1e3)}k`:t>=1e3?`${(e/1e3).toFixed(1)}k`:Number.isInteger(e)?String(e):e.toFixed(2).replace(/\.?0+$/,``)}function ES(e){if(!Number.isFinite(e)||e<=0)return 1;let t=10**Math.floor(Math.log10(e)),n=e/t;return(n<=1?1:n<=2?2:n<=5?5:10)*t}function DS(e){let t=e>=5&&e%5==0?5:4;return Array.from({length:t+1},(n,r)=>e*r/t)}function OS(e){let t=0;return e.map(e=>t+=e)}function kS(e){if(!Array.isArray(e))return null;let t=e.length,n=Math.floor(t/2);if(n<1)return null;let r=Jx(e.slice(t-n)),i=Jx(e.slice(t-2*n,t-n));if(r===0&&i===0)return null;if(i===0)return{pct:null,dir:`up`,window:n};let a=Math.round((r-i)/i*100);return{pct:a,dir:a>0?`up`:a<0?`down`:`flat`,window:n}}function AS({d:e}){if(!e)return null;let t=e.dir===`up`?Q.deltaUp:e.dir===`down`?Q.deltaDown:Q.deltaFlat,n=e.dir===`up`?Q.deltaUpMark:e.dir===`down`?Q.deltaDownMark:Q.deltaFlatMark,r=e.pct===null?`new`:`${e.pct>0?`+`:``}${e.pct}%`,i=`${e.window} day${e.window===1?``:`s`}`;return(0,R.jsxs)(`span`,{className:`${Q.delta} ${t}`,title:`last ${i} versus the ${i} before`,children:[(0,R.jsx)(`span`,{className:`${Q.deltaMark} ${n}`,"aria-hidden":`true`}),r,(0,R.jsxs)(`span`,{className:Q.deltaWin,children:[`vs prior `,e.window,`d`]})]})}function jS({values:e,ci:t,label:n}){let r=(Array.isArray(e)?e:[]).map(e=>$(e));if(r.length<3)return null;let i=Yx(r),a=r.map((e,t)=>({cx:t/(r.length-1)*111+2.5,cy:27-e/i*22})),{linePath:o,areaPath:s}=lC(a,116,30),c=a[a.length-1];
68return(0,R.jsxs)(`svg`,{width:116,height:30,viewBox:`0 0 116 30`,className:Q.spark,role:`img`,"aria-label":n,children:[s&&(0,R.jsx)(`path`,{d:s,fill:wS(t)}),o&&(0,R.jsx)(`path`,{d:o,fill:`none`,stroke:CS(t),strokeWidth:`1.5`,strokeLinecap:`round`,strokeLinejoin:`round`}),(0,R.jsx)(`circle`,{cx:c.cx,cy:c.cy,r:`2.6`,fill:CS(t)})]})}function MS({label:e,value:t,sub:n,spark:r,ci:i,delta:a}){return(0,R.jsxs)(`div`,{className:Q.headMetric,children:[(0,R.jsx)(`span`,{className:Q.headLabel,children:e}),(0,R.jsxs)(`span`,{className:Q.headValueRow,children:[(0,R.jsx)(`span`,{className:Q.headValue,children:t}),(0,R.jsx)(AS,{d:a??null})]}),r&&(0,R.jsx)(jS,{values:r,ci:i,label:`${e} over the window`}),n&&(0,R.jsx)(`span`,{className:Q.headSub,children:n})]})}function NS({segments:e,ariaLabel:t}){let n=e.reduce((e,t)=>e+t.value,0);return n===0?null:(0,R.jsx)(`div`,{className:Q.stackBar,role:`img`,"aria-label":t,children:e.filter(e=>e.value>0).map(e=>(0,R.jsx)(`span`,{className:Q.stackSeg,style:{width:`${e.value/n*100}%`,background:e.color},title:`${e.label} â ${e.value.toLocaleString()} (${Math.round(e.value/n*100)}%)`},e.key))})}function PS({rows:e,empty:t,max:n}){if(e.length===0)return(0,R.jsx)(`div`,{className:Q.empty,children:t});let r=Math.max(n??0,...e.map(e=>e.value),1);return(0,R.jsx)(`div`,{className:Q.barList,children:e.map(e=>(0,R.jsxs)(`div`,{className:Q.barRow,children:[(0,R.jsxs)(`span`,{className:Q.barLabel,children:[(0,R.jsx)(`span`,{className:Q.swatch,style:{background:e.color},"aria-hidden":`true`}),e.label]}),(0,R.jsx)(`span`,{className:Q.barTrack,children:(0,R.jsx)(`span`,{className:Q.barFill,style:{width:`${e.value/r*100}%`,background:e.color}})}),(0,R.jsx)(`span`,{className:Q.barValue,children:e.display??e.value.toLocaleString()}),(0,R.jsx)(`span`,{className:Q.barSub,children:e.sub??``})]},e.key))})}function FS({bins:e,series:t,ticks:n,height:r=108,ariaLabel:i,tipFor:a}){let o=(Array.isArray(e)?e:[]).map(e=>Array.isArray(e)?e.map(e=>$(e)):[]),s=o.map(e=>Jx(e)),c=ES(Yx(s)),l=s.indexOf(Yx(s,0));return(0,R.jsxs)(`div`,{className:Q.cols,children:[(0,R.jsxs)(`div`,{className:Q.colsPlot,style:{height:r},role:`img`,"aria-label":i,children:[[0,1,2].map(e=>(0,R.jsx)(`span`,{className:Q.colsGrid,style:{bottom:`${(e+1)/3*100}%`}},e)),(0,R.jsx)(`span`,{className:Q.colsMax,children:TS(c)}),(0,R.jsx)(`div`,{className:Q.colsTrack,children:o.map((e,n)=>(0,R.jsx)(`div`,{className:`${Q.col} ${n===l&&s[n]>0?Q.colPeak:``}`,title:a(n,s[n]),children:(Array.isArray(t)?t:[]).map((t,n)=>{let r=$(e[n]);return r<=0?null:(0,R.jsx)(`span`,{className:Q.colSeg,style:{height:`${r/c*100}%`,background:t.color}},t.key)})},n))})]}),(0,R.jsx)(`div`,{className:Q.colsAxis,children:(Array.isArray(n)?n:[]).map(e=>(0,R.jsx)(`span`,{className:Q.colsTick,style:{left:`${o.length<=1?50:(e.at+.5)/o.length*100}%`},children:e.label},e.at))})]})}var IS=.08;function LS({dates:e,series:t,hidden:n,onToggle:r,mode:i,onMode:a}){let[o,s]=(0,_.useState)(null),c=(0,_.useRef)(null),l=(Array.isArray(e)?e:[]).filter(e=>typeof e==`string`),u=l.length,d=(Array.isArray(t)?t:[]).map(e=>({...e,values:Array.from({length:u},(t,n)=>$(e.values?.[n]))})),f=d.filter(e=>!n.has(e.key)),p=f.map(e=>({...e,points:i===`cumulative`?OS(e.values):e.values})),m=ES(Yx(p.flatMap(e=>e.points))),h=e=>u<=1?.5:e/(u-1),g=e=>IS+(1-e/m)*(1-IS),v=1e3,y=Math.max(1,Math.ceil(u/8)),b=DS(m);function x(e){let t=c.current?.getBoundingClientRect();if(!t||t.width===0||u===0)return null;let n=Math.min(1,Math.max(0,(e-t.left)/t.width));return Math.round(n*(u-1))}return(0,R.jsxs)(`div`,{className:Q.chart,children:[(0,R.jsxs)(`div`,{className:Q.chartHead,children:[(0,R.jsx)(`div`,{className:Q.chartLegend,children:d.map(e=>{let t=n.has(e.key),i=e.values.reduce((e,t)=>e+t,0);return(0,R.jsxs)(`button`,{type:`button`,className:`${Q.legendItem} ${t?Q.legendItemOff:``}`,onClick:()=>r(e.key),"aria-pressed":!t,title:t?`show ${e.label}`:`hide ${e.label}`,children:[(0,R.jsx)(`span`,{className:Q.swatchDot,style:{background:CS(e.ci)},"aria-hidden":`true`}),e.label,(0,R.jsx)(`span`,{className:Q.legendNum,children:i.toLocaleStr
68ing()})]},e.key)})}),(0,R.jsx)(`span`,{className:Q.segmented,children:[`cumulative`,`daily`].map(e=>(0,R.jsx)(`button`,{type:`button`,className:`${Q.segmentedBtn} ${i===e?Q.segmentedBtnActive:``}`,onClick:()=>a(e),children:e},e))})]}),(0,R.jsxs)(`div`,{className:Q.chartBody,children:[(0,R.jsx)(`div`,{className:Q.chartYAxis,"aria-hidden":`true`,children:b.map(e=>(0,R.jsx)(`span`,{className:Q.chartYLabel,style:{top:`${g(e)*100}%`},children:TS(e)},e))}),(0,R.jsxs)(`div`,{ref:c,className:Q.chartPlot,role:`img`,tabIndex:0,"aria-label":`${i} ${f.map(e=>e.label).join(`, `)||`no series`} from ${l[0]??`â`} to ${l[u-1]??`â`}. Use the left and right arrow keys to read each day.`,onMouseMove:e=>s(x(e.clientX)),onMouseLeave:()=>s(null),onBlur:()=>s(null),onKeyDown:e=>{e.key===`ArrowRight`&&(e.preventDefault(),s(e=>Math.min(u-1,(e??-1)+1))),e.key===`ArrowLeft`&&(e.preventDefault(),s(e=>Math.max(0,(e??u)-1))),e.key===`Escape`&&s(null)},children:[(0,R.jsxs)(`svg`,{viewBox:`0 0 ${v} 240`,className:Q.chartSvg,preserveAspectRatio:`none`,"aria-hidden":`true`,children:[b.map(e=>(0,R.jsx)(`line`,{x1:`0`,x2:v,y1:g(e)*240,y2:g(e)*240,stroke:e===0?`var(--border-strong)`:`var(--border-2)`,strokeWidth:`1`,vectorEffect:`non-scaling-stroke`},e)),p.map(e=>{let{linePath:t,areaPath:n}=lC(e.points.map((e,t)=>({cx:h(t)*v,cy:g(e)*240})),v,240);return(0,R.jsxs)(`g`,{children:[p.length===1&&n&&(0,R.jsx)(`path`,{d:n,fill:wS(e.ci)}),t&&(0,R.jsx)(`path`,{d:t,fill:`none`,stroke:CS(e.ci),strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,vectorEffect:`non-scaling-stroke`})]},e.key)})]}),p.map(e=>{let t=e.points[u-1]??0;return(0,R.jsx)(`span`,{className:Q.chartEnd,style:{left:`${h(u-1)*100}%`,top:`${g(t)*100}%`,background:CS(e.ci)},"aria-hidden":`true`},e.key)}),o!==null&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`span`,{className:Q.chartCross,style:{left:`${h(o)*100}%`},"aria-hidden":`true`}),p.map(e=>(0,R.jsx)(`span`,{className:Q.chartPt,style:{left:`${h(o)*100}%`,top:`${g(e.points[o]??0)*100}%`,background:CS(e.ci)},"aria-hidden":`true`},e.key))]})]}),o!==null&&l[o]&&(0,R.jsxs)(`div`,{className:Q.chartTip,role:`status`,style:{left:`${h(o)*100}%`,transform:h(o)<.18?`translateX(0)`:h(o)>.82?`translateX(-100%)`:`translateX(-50%)`},children:[(0,R.jsx)(`span`,{className:Q.chartTipDate,children:(e=>new Date(`${e}T12:00:00Z`).toLocaleDateString(`en-US`,{month:`short`,day:`numeric`,timeZone:`UTC`}))(l[o])}),p.map(e=>(0,R.jsxs)(`span`,{className:Q.chartTipRow,children:[(0,R.jsx)(`span`,{className:Q.swatchDot,style:{background:CS(e.ci)},"aria-hidden":`true`}),(0,R.jsx)(`span`,{className:Q.chartTipLabel,children:e.label}),(0,R.jsx)(`span`,{className:Q.chartTipVal,children:(e.points[o]??0).toLocaleString()})]},e.key)),p.length===0&&(0,R.jsx)(`span`,{className:Q.chartTipLabel,children:`no series showing`})]})]}),(0,R.jsx)(`div`,{className:Q.chartXAxis,children:l.map((e,t)=>t%y===0||t===u-1?(0,R.jsx)(`span`,{className:Q.chartXLabel,style:{left:`${h(t)*100}%`},children:e.slice(5)},e):null)})]})}var RS={good:Q.toneGood,warn:Q.toneWarn,bad:Q.toneBad,neutral:Q.toneNeutral},zS={good:Q.markGood,warn:Q.markWarn,bad:Q.markBad,neutral:Q.markNeutral};function BS({tone:e}){return(0,R.jsx)(`span`,{className:`${Q.mark} ${zS[e]}`,"aria-hidden":`true`})}var VS={PASS:`good`,"NEEDS-REVIEW":`warn`,FAIL:`bad`},HS={done:`good`,pending:`neutral`,skipped:`bad`,unknown:`neutral`},US={verified:`good`,attested:`warn`,missed:`bad`,unresolved:`neutral`};function WS({label:e,tone:t}){return(0,R.jsxs)(`span`,{className:`${Q.badge} ${RS[t]}`,children:[(0,R.jsx)(BS,{tone:t}),e]})}function GS({title:e,note:t,dist:n,tones:r,order:i,palette:a}){let o=Object.entries(Zx(n)).filter(([,e])=>e>0),s=o.reduce((e,[,t])=>e+t,0),c=e=>{let t=i?.indexOf(e)??-1;return t===-1?99:t};o.sort((e,t)=>c(e[0])-c(t[0])||t[1]-e[1]);let l=o.map(([e,t],n)=>({key:e,label:e,value:t,color:a?CS(n):`var(--tone-${r?.[e]??`neutral`})`}));return(0,R.jsxs)(`div`,{className:Q.dist,children:[(0,R.jsxs)(`div`,{className:Q.distHead,children:[(0,R.jsx)(`span`,{className:Q.distTitle,children:e}),(0,R.jsx)(`span`,{className:Q.distTotal,children:s.toLocaleStr
68ing()})]}),t&&(0,R.jsx)(`p`,{className:Q.distNote,children:t}),s===0?(0,R.jsx)(`p`,{className:Q.emptyInline,children:`nothing recorded in this range`}):(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(NS,{segments:l,ariaLabel:`${e}: ${o.map(([e,t])=>`${e} ${Math.round(t/s*100)}%`).join(`, `)}`}),o.map(([e,t],n)=>{let i=r?.[e]??`neutral`,o=Math.round(t/s*100);return(0,R.jsxs)(`div`,{className:Q.distRow,children:[(0,R.jsxs)(`span`,{className:Q.distLabel,children:[a?(0,R.jsx)(`span`,{className:Q.swatch,style:{background:CS(n)},"aria-hidden":`true`}):(0,R.jsx)(BS,{tone:i}),e]}),(0,R.jsx)(`span`,{className:Q.distTrack,children:(0,R.jsx)(`span`,{className:`${Q.distFill} ${a?``:RS[i]}`,style:{width:`${t/s*100}%`,...a?{background:CS(n)}:null}})}),(0,R.jsx)(`span`,{className:Q.distCount,children:t.toLocaleString()}),(0,R.jsxs)(`span`,{className:Q.distPct,children:[o,`%`]})]},e)})]})]})}function KS({days:e,max:t}){if(!Array.isArray(e)||e.length===0)return(0,R.jsx)(`div`,{className:Q.empty,children:`no activity recorded yet`});let n=new Date(e[0].date+`T12:00:00Z`).getUTCDay(),r=[...Array(n).fill(null),...e],i=[];for(let e=0;e<r.length;e+=7)i.push(r.slice(e,e+7));return(0,R.jsx)(`div`,{className:Q.heatmapWrap,children:i.map((e,n)=>(0,R.jsx)(`div`,{className:Q.heatmapCol,children:e.map((e,n)=>{if(!e)return(0,R.jsx)(`div`,{className:Q.heatmapCellEmpty},n);let r=t>0?e.count/t:0;return(0,R.jsx)(`div`,{className:Q.heatmapCell,style:{opacity:e.count===0?.08:Math.max(.18,r)},title:`${e.date}: ${e.count}`},e.date)})},n))})}function qS({pages:e}){if(!Array.isArray(e)||e.length===0)return(0,R.jsx)(`div`,{className:Q.empty,children:`no page-view data yet for this range`});let t=Yx(e.map(e=>$(e.count)));return(0,R.jsx)(`div`,{className:Q.pagesList,children:e.map(e=>(0,R.jsxs)(`div`,{className:Q.pagesRow,children:[(0,R.jsx)(`span`,{className:Q.pagesPath,children:e.path}),(0,R.jsx)(`span`,{className:Q.pagesBarTrack,children:(0,R.jsx)(`span`,{className:Q.pagesBarFill,style:{width:`${e.count/t*100}%`}})}),(0,R.jsx)(`span`,{className:Q.pagesCount,children:e.count.toLocaleString()})]},e.path))})}var JS=[{key:`locked`,label:`tasks locked`,color:CS(0)}],YS=[0,3,6,9,12,15,18,21].map(e=>({at:e,label:`${e}:00`}));function XS({hours:e}){let t=Jx(qx(e).map(e=>$(e.count)));return t===0?(0,R.jsx)(`div`,{className:Q.empty,children:`no locked tasks yet for this range`}):(0,R.jsx)(FS,{bins:qx(e).map(e=>[$(e.count)]),series:JS,ticks:YS,height:116,ariaLabel:`tasks locked by hour of day, UTC, across ${t.toLocaleString()} tasks`,tipFor:(e,n)=>`${String(e).padStart(2,`0`)}:00â${String(e).padStart(2,`0`)}:59 UTC â ${n} locked (${Math.round(n/t*100)}%)`})}var ZS={app_view:`viewed a page`,day_locked:`locked in tasks`,onboarding_step:`onboarding step`,onboarding_complete:`finished onboarding`,reconcile_confirm:`confirmed a review`,review_generated:`evening review generated`,feedback_submitted:`submitted feedback`};function QS(e){return ZS[e]??e}function $S(e,t){let n=new Date(e);return t?{hour:n.getHours()+n.getMinutes()/60,dow:n.getDay()}:{hour:n.getUTCHours()+n.getUTCMinutes()/60,dow:n.getUTCDay()}}var eC=[`S`,`M`,`T`,`W`,`T`,`F`,`S`],tC=36e5,nC=864e5;function rC(e,t){let n=new Date;if(t?n.setHours(0,0,0,0):n.setUTCHours(0,0,0,0),e===`today`)return{count:24,ms:tC,startMs:n.getTime(),tickStep:4,grain:`hour`};if(e===`7d`){let e=new Date(n);return t?e.setDate(e.getDate()-6):e.setUTCDate(e.getUTCDate()-6),{count:28,ms:6*tC,startMs:e.getTime(),tickStep:4,grain:`6 hours`}}let r=new Date(n);return t?r.setDate(r.getDate()-29):r.setUTCDate(r.getUTCDate()-29),{count:30,ms:nC,startMs:r.getTime(),tickStep:5,grain:`day`}}function iC(e,t,n){let r=new Date(e),i=n?void 0:`UTC`;return t===`hour`?`${n?r.getHours():r.getUTCHours()}:00`:r.toLocaleDateString(`en-US`,{month:`short`,day:`numeric`,timeZone:i})}function aC(e,t,n){let r=new Date(e),i=n?void 0:`UTC`,a=r.toLocaleDateString(`en-US`,{month:`short`,day:`numeric`,timeZone:i});if(t.ms>=nC)return a;let o=n?r.getHours():r.getUTCHours(),s=o+t.ms/tC;return`${a} ${String(o).padStart(2,`0`)}:00â${String(s%24).padStart(2,`0`)}:00`}function oC({rows:e,plan:t,local:n,maxBin:r,selected:i,onSelect:a,onSelectUser:o}){let s={gridTemplateColumns:`repeat(${t.count}, 1fr)`},c=Array.from({length:t.count},(e,t)=>t).filter(e=>e%t.tickStep===0);return(0,R.jsxs)(`div`,{className:Q.ribbon,children:[(0,R.jsxs)(`div`,{className:Q.ribbonAxis,children:[(0,R.jsx)(`span`,{className:Q.ribbonAxisName}),(0,R.jsx)(`span`,{className:Q.ribbonAxisTrack,style:s,children:Array.from({length:t.count},(e,r)=>(0,R.jsx)(`span`,{className:Q.ribbonAxisCell,children:c.includes(r)&&(0,R.jsx)(`span`,{className:Q.ribbonAxisTick,children:iC(t.startMs+r*t.ms,t.grain,n)})},r))}),(0,R.jsx)(`span`,{className:Q.ribbonAxisMeta,children:`events`}),(0,R.jsx)(`span`,{className:Q.ribbonAxisMeta,children:`last seen`})]}),e.map(e=>(0,R.jsxs)(`div`,{className:`${Q.ribbonRow} ${e.total===0?Q.ribbonRowQuiet:``}`,children:[(0,R.jsx)(`span`,{className:Q.ribbonName,children:e.userId?(0,R.jsx)(`button`,{type:`button`,className:Q.linkBtn,onClick:()=>o(e.userId),title:e.detail,children:e.name}):(0,R.jsx)(`span`,{title:e.detail,children:e.name})}),(0,R.jsx)(`span`,{className:Q.ribbonTrack,style:s,children:Array.from({length:t.count},(o,s)=>{let c=e.bins[s]??0;if(c===0)return(0,R.jsx)(`span`,{className:Q.ribbonCell},s);let l=r>
681?Math.min(1,c/r):1,u=4+Math.round(l*6),d=i?.key===e.key&&i.bin===s,f=aC(t.startMs+s*t.ms,t,n);return(0,R.jsx)(`button`,{type:`button`,className:Q.ribbonCell,onClick:()=>a(e.key,s),"aria-label":`${e.name}, ${f}, ${c} event${c===1?``:`s`}`,title:`${e.name} â ${f} â ${c} event${c===1?``:`s`}`,children:(0,R.jsx)(`span`,{className:`${Q.ribbonDot} ${d?Q.ribbonDotSel:``}`,style:{width:u,height:u,opacity:d?1:.35+l*.6}})},s)})}),(0,R.jsx)(`span`,{className:Q.ribbonCount,children:e.total.toLocaleString()}),(0,R.jsx)(`span`,{className:Q.ribbonLast,children:e.lastAt?_C(new Date(e.lastAt).toISOString()):dC(e.sortAt?new Date(e.sortAt).toISOString():null)})]},e.key))]})}var sC=20;function cC({range:e,signups:t,tick:n,nowTick:r,onSelectUser:i}){let[a,o]=(0,_.useState)([]),[s,c]=(0,_.useState)(0),[l,u]=(0,_.useState)(!0),[d,f]=(0,_.useState)(``),[p,m]=(0,_.useState)(null),[h,g]=(0,_.useState)(new Set),[v,y]=(0,_.useState)(``),[b,x]=(0,_.useState)(new Set),[S,C]=(0,_.useState)(0),[w,T]=(0,_.useState)(23),[E,D]=(0,_.useState)(``),[O,k]=(0,_.useState)(!1),[A,j]=(0,_.useState)(sC),[ee,te]=(0,_.useState)(null),ne=(0,_.useRef)(null);(0,_.useEffect)(()=>{let t=ne.current!==e;ne.current=e;let n=!1;return t&&u(!0),pS(e).then(e=>{n||(o(e.events),c(e.total),m(Date.now()),f(``))}).catch(e=>{n||f(e instanceof Error?e.message:`failed`)}).finally(()=>{n||u(!1)}),()=>{n=!0}},[e,n]);let re=(0,_.useCallback)(()=>{g(new Set),y(``),x(new Set),C(0),T(23),D(``),te(null),j(sC)},[]),M=(0,_.useRef)(!1);(0,_.useEffect)(()=>{if(!M.current){M.current=!0;return}re()},[e,re]);let N=(0,_.useMemo)(()=>rC(e,O),[e,O]),ie=(0,_.useMemo)(()=>{let e={};for(let t of a)e[t.event]=(e[t.event]??0)+1;return e},[a]),ae=(0,_.useMemo)(()=>Object.keys(ie).sort(),[ie]),P=E.trim().toLowerCase(),oe=(0,_.useMemo)(()=>a.filter(e=>{if(h.has(e.event)||P&&!(e.path??``).toLowerCase().includes(P))return!1;let{hour:t,dow:n}=$S(e.at,O);if(b.has(n))return!1;let r=Math.floor(t);return!(r<S||r>w)}
68),[a,h,P,O,b,S,w]),{rows:se,maxBin:ce,binEvents:le}=(0,_.useMemo)(()=>{let e=new Map,n=new Map,r=(t,n,r,i,a)=>{let o=e.get(t);if(o)return o;let s={key:t,userId:n,name:r,detail:i,bins:Array(N.count).fill(0),total:0,lastAt:0,sortAt:a};return e.set(t,s),s};for(let e of qx(t)){let t=e.lastActive??e.last_sign_in_at,n=t?new Date(t.length<=10?`${t}T12:00:00`:t).getTime():0;r(e.id,e.id,e.name||e.email||e.id.slice(0,8),e.email||`(no email on file)`,isNaN(n)?0:n)}for(let e of oe){let t=e.userId??`__anon`,i=e.userId?r(t,e.userId,e.userName||e.userId.slice(0,8)||`unknown`,e.userId,0):r(t,null,`signed-out / pre-account`,`events with no account attached`,0),a=new Date(e.at).getTime(),o=Math.floor((a-N.startMs)/N.ms);if(o<0||o>=N.count)continue;i.bins[o]++,i.total++,a>i.lastAt&&(i.lastAt=a,i.sortAt=Math.max(i.sortAt,a));let s=`${t}|${o}`,c=n.get(s);c?c.push(e):n.set(s,[e])}let i=[...e.values()],a=1;for(let e of i)for(let t of e.bins)t>a&&(a=t);return i.sort((e,t)=>t.lastAt-e.lastAt||t.sortAt-e.sortAt||t.total-e.total||e.name.localeCompare(t.name)),{rows:i,maxBin:a,binEvents:n}},[oe,t,N]),ue=v.trim().toLowerCase(),de=ue?se.filter(e=>e.name.toLowerCase().includes(ue)||e.detail.toLowerCase().includes(ue)):se,fe=de.slice(0,A),pe=de.filter(e=>e.total>0).length,me=h.size>0||ue!==``||b.size>0||S!==0||w!==23||P!==``;function he(e){g(t=>{let n=new Set(t);return n.has(e)?n.delete(e):n.add(e),n})}function ge(e){x(t=>{let n=new Set(t);return n.has(e)?n.delete(e):n.add(e),n})}let _e=ee?se.find(e=>e.key===ee.key)??null:null,ve=ee?le.get(`${ee.key}|${ee.bin}`)??[]:[],ye=O?`local`:`UTC`,be=(0,_.useMemo)(()=>ae.filter(e=>!h.has(e)),[ae,h]),xe=(0,_.useMemo)(()=>be.map(e=>({key:e,label:QS(e),color:CS(ae.indexOf(e))})),[be,ae]),Se=(0,_.useMemo)(()=>{let e=Array.from({length:N.count},()=>Array(be.length).fill(0)),t=new Map(be.map((e,t)=>[e,t]));for(let n of oe){let r=t.get(n.event);if(r===void 0)continue;let i=Math.floor((new Date(n.at).getTime()-N.startMs)/N.ms);i<0||i>=N.count||e[i][r]++}return e},[oe,N,be]),Ce=(0,_.useMemo)(()=>Array.from({length:N.count},(e,t)=>t).filter(e=>e%N.tickStep===0).map(e=>({at:e,label:iC(N.startMs+e*N.ms,N.grain,O)})),[N,O]);return(0,R.jsxs)(`section`,{className:Q.section,children:[(0,R.jsxs)(`div`,{className:Q.sectionHead,children:[(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`h2`,{className:Q.sectionTitle,children:`Activity by user`}),(0,R.jsxs)(`p`,{className:Q.sectionSub,children:[`one row per account · one dot per `,N.grain,` · `,ye,` · `,pe,` of `,de.length,` active in this range`]})]}),(0,R.jsx)(`div`,{className:Q.sectionActions,children:p!==null&&(0,R.jsxs)(`span`,{className:Q.liveWrap,children:[(0,R.jsx)(`span`,{className:Q.liveDot}),(0,R.jsxs)(`span`,{className:Q.liveText,children:[`updated `,vC(r-p)]})]})})]}),d&&(0,R.jsxs)(`div`,{className:Q.empty,children:[`failed to load (`,d,`)`]}),!d&&l&&a.length===0&&(0,R.jsx)(`div`,{className:Q.empty,children:`loadingâ¦`}),!d&&a.length>0&&(0,R.jsxs)(`div`,{className:Q.usageFilters,children:[(0,R.jsx)(`div`,{className:Q.usageLegend,children:ae.map((e,t)=>{let n=h.has(e);return(0,R.jsxs)(`button`,{type:`button`,className:`${Q.usageLegendItem} ${n?Q.usageLegendItemOff:``}`,onClick:()=>he(e),"aria-pressed":!n,title:n?`show ${QS(e)}`:`hide ${QS(e)}`,children:[(0,R.jsx)(`span`,{className:Q.swatchDot,style:{background:CS(t)},"aria-hidden":`true`}),QS(e),(0,R.jsx)(`span`,{className:Q.usageLegendCount,children:ie[e]})]},e)})}),(0,R.jsxs)(`div`,{className:Q.usageFilterRow,children:[(0,R.jsx)(`div`,{className:Q.usageDowGroup,role:`group`,"aria-label":`day of week`,children:eC.map((e,t)=>(0,R.jsx)(`button`,{type:`button`,className:`${Q.usageDowChip} ${b.has(t)?Q.usageDowChipOff:``}`,onClick:()=>ge(t),"aria-pressed":!b.has(t),title:b.has(t)?`show this weekday`:`hide this weekday`,children:e},t))}),(0,R.jsxs)(`label`,{className:Q.usageHourGroup,children:[(0,R.jsx)(`span`,{className:Q.usageFilterLabel,children:`hours`}),(0,R.jsx)(`select`,{className:Q.usageHourSelect,value:S,onChange:e=>C(Math.min(+e.target.value,w)),children:Array.from({length:24},(e,t)=>(0,R.jsxs)(`option`,{value:t,children:[t,`:00`]},t))}),(0,R.jsx)(`span`,{className:Q.usageFilterLabel,children:`â`}),(0,R.jsx)(`select`,{className:Q.usageHourSelect,value:w,onChange:e=>T(Math.max(+e.target.value,S)),children:Array.from({length:24},(e,t)=>(0,R.jsxs)(`option`,{value:t,children:[t,`:59`]},t))})]}),(0,R.jsx)(`input`,{className:Q.usageInput,type:`text`,placeholder:`path containsâ¦`,value:E,onChange:e=>D(e.target.value)}),(0,R.jsx)(`input`,{className:Q.usageInput,type:`text`,placeholder:`find a userâ¦`,value:v,onCh
68ange:e=>{y(e.target.value),j(sC)}}),(0,R.jsxs)(`div`,{className:Q.usageTzToggle,role:`group`,"aria-label":`timezone`,children:[(0,R.jsx)(`button`,{type:`button`,className:O?``:Q.usageTzActive,onClick:()=>k(!1),children:`UTC`}),(0,R.jsx)(`button`,{type:`button`,className:O?Q.usageTzActive:``,onClick:()=>k(!0),children:`local`})]}),me&&(0,R.jsx)(`button`,{type:`button`,className:Q.ghostBtn,onClick:re,children:`reset filters`})]})]}),!d&&oe.length>0&&xe.length>0&&(0,R.jsxs)(`div`,{className:Q.usageVolume,children:[(0,R.jsxs)(`div`,{className:Q.usageVolumeHead,children:[(0,R.jsx)(`span`,{className:Q.usageVolumeTitle,children:`volume across everyone`}),(0,R.jsxs)(`span`,{className:Q.usageVolumeCount,children:[oe.length.toLocaleString(),` event`,oe.length===1?``:`s`,` · one column per `,N.grain]})]}),(0,R.jsx)(FS,{bins:Se,series:xe,ticks:Ce,height:116,ariaLabel:`events per ${N.grain} across all accounts, stacked by event type, ${ye}`,tipFor:(e,t)=>`${aC(N.startMs+e*N.ms,N,O)} ${ye} â ${t} event${t===1?``:`s`}`})]}),!d&&fe.length>0&&(0,R.jsx)(oC,{rows:fe,plan:N,local:O,maxBin:ce,selected:ee,onSelect:(e,t)=>te(n=>n&&n.key===e&&n.bin===t?null:{key:e,bin:t}),onSelectUser:i}),!d&&!l&&fe.length===0&&(0,R.jsx)(`div`,{className:Q.empty,children:`no accounts match this filter`}),de.length>0&&(0,R.jsxs)(`div`,{className:Q.ribbonFoot,children:[(0,R.jsxs)(`span`,{className:Q.ribbonFootText,children:[`showing `,fe.length,` of `,de.length,` account`,de.length===1?``:`s`,`, most recently active first`,s>=Wx&&` · the server returned its ${Wx.toLocaleString()}-event cap for this range, so the newest events may be missing`]}),(0,R.jsxs)(`span`,{className:Q.ribbonFootActions,children:[A<de.length&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsxs)(`button`,{type:`button`,className:Q.ghostBtn,onClick:()=>j(e=>e+sC),children:[`show `,Math.min(sC,de.length-A),` more`]}),(0,R.jsxs)(`button`,{type:`button`,className:Q.ghostBtn,onClick:()=>j(de.length),children:[`show all `,de.length]})]}),A>sC&&(0,R.jsx)(`button`,{type:`button`,className:Q.ghostBtn,onClick:()=>j(sC),children:`collapse`})]})]}),ee&&_e&&(0,R.jsxs)(`div`,{className:Q.usageDetail,children:[(0,R.jsxs)(`div`,{className:Q.usageDetailHead,children:[(0,R.jsxs)(`span`,{className:Q.usageDetailTitle,children:[_e.name,` · `,aC(N.startMs+ee.bin*N.ms,N,O),` `,ye]}),(0,R.jsxs)(`span`,{className:Q.usageDetailCount,children:[ve.length,` event`,ve.length===1?``:`s`]}),(0,R.jsx)(`button`,{type:`button`,className:Q.usageDetailClose,onClick:()=>te(null),"aria-label":`Close`,children:`close`})]}),(0,R.jsx)(`ul`,{className:Q.usageDetailList,children:ve.slice(0,20).map((e,t)=>(0,R.jsxs)(`li`,{className:Q.usageDetailItem,children:[(0,R.jsx)(`span`,{className:Q.usageDetailTime,children:new Date(e.at).toLocaleTimeString(`en-US`,{hour:`2-digit`,minute:`2-digit`,second:`2-digit`,timeZone:O?void 0:`UTC`})}),(0,R.jsx)(`span`,{className:Q.usageDetailEvent,children:QS(e.event)}),(0,R.jsx)(`span`,{className:Q.usageDetailPath,children:e.path??`â`})]},t))}),ve.length>20&&(0,R.jsxs)(`p`,{className:Q.usageDetailMore,children:[`+ `,ve.length-20,` more in this `,N.grain]})]})]})}function lC(e,t,n){if(e.length===0)return{linePath:``,areaPath:``};if(e.length===1)return{linePath:`M${e[0].cx.toFixed(1)},${e[0].cy.toFixed(1)}`,areaPath:``};let r=e.reduce((t,n,r)=>{if(r===0)return`M${n.cx.toFixed(1)},${n.cy.toFixed(1)}`;let i=e[r-1],a=((i.cx+n.cx)/2).toFixed(1);return`${t} C${a},${i.cy.toFixed(1)} ${a},${n.cy.toFixed(1)} ${n.cx.toFixed(1)},${n.cy.toFixed(1)}`},``);return{linePath:r,areaPath:`${r} L${e[e.length-1].cx.toFixed(1)},${n} L${e[0].cx.toFixed(1)},${n} Z`}}function uC(e,t){let n=new Blob([e.map(e=>e.map(e=>`"${String(e??``).replace(/"/g,`""`)}"`).join(`,`)).join(` 69`)],{type:`text/csv`}),r=URL.createObjectURL(n);Object.assign(document.createElement(`a`),{href:r,download:t}).click(),setTimeout(()=>URL.revokeObjectURL(r),1e4)}function dC(e){if(!e)return`â`;let t=new Date(e.length<=10?`${e}T12:00:00`:e);return isNaN(t.getTime())?`â`:t.toLocaleDateString(`en-US`,{month:`short`,day:`numeric`})}function fC(e){return qx(e).map(e=>{let t=Xx(e);return{key:String(t.key??`unknown`),n:$(t.n),accuracy:typeof t.accuracy==`number`&&Number.isFinite(t.accuracy)?t.accuracy:null}})}function pC(e){let t=Xx(e),n=e=>typeof e==`number`&&Number.isFinite(e)?e:null;return{total_judgments:$(t.total_judgments),asserted:$(t.asserted),uncertain:$(t.uncertain),with_feedback:$(t.with_feedback),accuracy_pct:n(t.accuracy_pct),overconfidence_pct:n(t.overconfidence_pct),uncertain_resolved:$(t.uncertain_resolved),per_connector:fC(t.per_connector),per_category:fC(t.per_category)}}function mC(){let[e,t]=(0,_.useState)(null),[n,r]=(0,_.useState)(``);(0,_.useEffect)(()=>{let e=!1;return fetch(`${Bx}/functions/v1/crew-calibration?days=7`,{headers:Kx()}).then(e=>e.ok?e.json():Promise.reject(Error(`${e.status}`))).then(n=>{e||t(pC(n))}).catch(t=>{e||r(t instanceof Error?t.message:String(t))}),()=>{e=!0}},[]);let i=e?[...e.per_connector.map(e=>({key:`conn-${e.key}`,label:`connector · ${e.key}`,value:e.accuracy??0,display:e.accuracy==null?`â`:`${e.accuracy}%`,sub:`n=${e.n}`,color:CS(0)})),...e.per_category.map(e=>({key:`cat-${e.key}`,label:`category · ${e.key}`,value:e.accuracy??0,display:e.accuracy==null?`â`:`${e.accuracy}%`,sub:`n=${e.n}`,color:CS(2)}))]:[];return(0,R.jsxs)(`section`,{className:Q.section,children:[(0,R.jsx)(`div`,{className:Q.sectionHead,children:(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`h2`,{className:Q.sectionTitle,children:`Judgment calibration`}),(0,R.jsx)(`p`,{className:Q.sectionSub,children:`how right Crew's verdicts turn out to be â last 7 days`})]})}),n&&(0,R.jsxs)(`div`,{className:Q.empty,children:[`calibration unavailable (`,n,`)`]}),!e&&!n&&(0,R.jsx)(`div`,{className:Q.empty,children:`loadingâ¦`}),e&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsxs)(`div`,{className:Q.metricRail,children:[(0,R.jsx)(xS,{label:`judgments`,value:e.total_judgments.toLocaleStr
69ing(),sub:`${e.asserted} asserted · ${e.uncertain} uncertain`}),(0,R.jsx)(xS,{label:`accuracy`,value:e.accuracy_pct==null?`â`:`${e.accuracy_pct}%`,sub:`${e.with_feedback} with feedback`}),(0,R.jsx)(xS,{label:`overconfidence`,value:e.overconfidence_pct==null?`â`:`${e.overconfidence_pct}%`,sub:`asserted, then overturned`}),(0,R.jsx)(xS,{label:`under-confident`,value:e.uncertain_resolved,sub:`uncertain, later resolved`})]}),e.asserted+e.uncertain>0&&(0,R.jsxs)(`div`,{className:Q.compRow,children:[(0,R.jsx)(NS,{segments:[{key:`asserted`,label:`asserted`,value:e.asserted,color:CS(0)},{key:`uncertain`,label:`uncertain`,value:e.uncertain,color:CS(1)}],ariaLabel:`${e.asserted} asserted, ${e.uncertain} uncertain`}),(0,R.jsxs)(`span`,{className:Q.compLegend,children:[(0,R.jsxs)(`span`,{className:Q.compItem,children:[(0,R.jsx)(`span`,{className:Q.swatchDot,style:{background:CS(0)},"aria-hidden":`true`}),`asserted`,(0,R.jsx)(`b`,{children:e.asserted.toLocaleString()})]}),(0,R.jsxs)(`span`,{className:Q.compItem,children:[(0,R.jsx)(`span`,{className:Q.swatchDot,style:{background:CS(1)},"aria-hidden":`true`}),`uncertain`,(0,R.jsx)(`b`,{children:e.uncertain.toLocaleString()})]})]})]}),i.length>0&&(0,R.jsx)(PS,{rows:i,max:100,empty:`no breakdown yet`})]})]})}var hC={login:`logged in`,logout:`logged out`,signup:`signed up`,profile_updated:`profile updated`,plan_changed:`plan changed`,account_deleted:`account deleted`,password_reset_requested:`password reset requested`,connector_connected:`connector connected`,connector_disconnected:`connector disconnected`};function gC(e,t){let n=Xx(t);return e===`profile_updated`&&Array.isArray(n.fields)?`fields: ${n.fields.join(`, `)}`:(e===`connector_connected`||e===`connector_disconnected`)&&n.provider?String(n.provider):e===`plan_changed`&&n.plan?`â ${n.plan}${n.by?` (${n.by})`:``}`:e===`signup`&&n.method?String(n.method):``}function _C(e){if(!e)return`â`;let t=new Date(e);return isNaN(t.getTime())?`â`:t.toLocaleString(`en-US`,{month:`short`,day:`numeric`,hour:`numeric`,minute:`2-digit`})}function vC(e){let t=Math.max(0,Math.round(e/1e3));if(t<60)return`${t}s ago`;let n=Math.round(t/60);return n<60?`${n}m ago`:`${Math.round(n/60)}h ago`}var yC=[{key:`timezone`,label:`timezone`},{key:`language`,label:`language`},{key:`focus`,label:`focus`},{key:`stage`,label:`stage`},{key:`onboarding_mode`,label:`onboarding`},{key:`daily_task_count`,label:`tasks / day`},{key:`rest_weekdays`,label:`rest days`},{key:`paused_until`,label:`paused until`},{key:`trial_ends_at`,label:`trial ends`},{key:`is_public`,label:`public profile`}];function bC(e,t){return(e==null||e===``)&&t===`trial_ends_at`?`unlimited (prelaunch)`:e==null||e===``?`â`:typeof e==`boolean`?e?`yes`:`no`:Array.isArray(e)?e.length?e.join(`, `):`â`:String(e)}function xC({userId:e,onClose:t}){let[n,r]=(0,_.useState)(null),[i,a]=(0,_.useState)(!0),[o,s]=(0,_.useState)(``);(0,_.useEffect)(()=>{let t=!1;return a(!0),s(``),sS(e).then(e=>{t||r(e)}).catch(e=>{t||s(e instanceof Error?e.message:`failed`)}).finally(()=>{t||a(!1)}),()=>{t=!0}},[e]),(0,_.useEffect)(()=>{let e=e=>{e.key===`Escape`&&t()};return document.addEventListener(`keydown`,e),()=>document.removeEventListener(`keydown`,e)},[t]);let c=n?.metrics,l=Yx((n?.dailyActivity??[]).map(e=>$(e.count))),u=n?.profile??{},d=yC.filter(e=>e.key in u);return(0,R.jsx)(`div`,{className:Q.drawerBackdrop,onClick:t,children:(0,R.jsxs)(`div`,{className:Q.drawer,onClick:e=>e.stopPropagation(),children:[(0,R.jsxs)(`div`,{className:Q.drawerHead,children:[(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`h2`,{className:Q.drawerTitle,children:u.name||`(no name)`}),(0,R.jsx)(`p`,{className:Q.drawerSub,children:n?.email})]}),(0,R.jsx)(`button`,{className:Q.drawerClose,onClick:t,"aria-label":`Close`,children:`Ã`})]}),i&&(0,R.jsx)(`div`,{className:Q.empty,children:`loadingâ¦`}),o&&(0,R.jsxs)(`div`,{className:Q.empty,children:[`failed to load (`,o,`)`]}),n&&!c&&!i&&!o&&(0,R.jsx)(`div`,{className:Q.empty,children:`this account has no recorded activity yet`}),n&&c&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsxs)(`div`,{className:Q.drawerMetaRow,children:[(0,R.jsxs)(`span`,{children:[`plan `,(0,R.jsx)(`strong`,{children:u.plan??`trial`})]}),(0,R.jsxs)(`span`,{children:[`joined `,_C(u.created_at)]}),(0,R.jsxs)(`span`,{children:[`last sign-in `,n.lastSignInAt?_C(n.lastSignInAt):`â`]})]}),(0,R.jsxs)(`div`,{className:Q.metricRail,children:[(0,R.jsx)(xS,{label:`tasks created`,value:c.tasksCreated,sub:`${c.tasksLocked} locked`}),(0,R.jsx)(xS,{label:`completed`,value:c.tasksCompleted,sub:`${c.completionRate}% rate`}),(0,R.jsx)(xS,{label:`current streak`,value:`${c.currentStreak}d`,sub:`best ${c.longestStreak}d`}),(0,R.jsx)(xS,{label:`messages`,value:c.totalMessages,sub:`sent to Crew`}),(0,R.jsx)(xS,{label:`sessions`,value:c.sessionCount,sub:`${c.avgSessionMinutes}m avg`}),(0,R.jsx)(xS,{label:`active days`,value:c.activeDaysLast7,sub:`${c.activeDaysLast30} in 30d`})]}),(0,R.jsxs)(`div`,{className:Q.drawerSection,children:[(0,R.jsx)(`span`,{className:Q.drawerSectionLabel,children:`connected`}),(0,R.jsxs)(`div`,{className:Q.chipRow,children:[c.connectors.length===0&&!c.telegramLinked&&(0,R.jsx)(`span`,{className:Q.emptyInline,children:`no connectors or channels linked yet`}),c.connectors.map(e=>(0,R.jsx)(`span`,{className:Q.featureChip,children:e},e)),(c.telegramLinked||u.telegramLinked===!0)&&(0,R.jsx)(`span`,{className:Q.featureChip,children:`telegram`})]})]}),d.length>0&&(0,R.jsxs)(`div`,{className:Q.drawerSection,children:[(0,R.jsx)(`span`,{className:Q.drawerSectionLabel,children:`settings`}),(0,R.jsx)(`dl`,{className:Q.defList,children:d.map(e=>(0,R.jsxs)(`div`,{className:Q.defRow,children:[(0,R.jsx)(`dt`,{className:Q.defTerm,children:e.label}),(0,R.jsx)(`dd`,{className:Q.defVal,children:bC(u[e.key],e.key)})]},e.key))})]}),(0,R.jsxs)(`div`,{className:Q.drawerSection,children:[(0,R.jsx)(`span`,{className:Q.drawerSectionLabel,children:`activity â last 30 days`}),(0,R.jsx)(KS,{days:n.dailyActivity,max:l})]}),(0,R.jsxs)(`div`,{className:Q.drawerSection,children:[(0,R.jsx)(`span`,{className:Q.drawerSectionLabel,children:`audit trail`}),n.auditLog.length===0?(0,R.jsx)(`div`,{className:Q.emptyInline,children:`no logged-in activity yet for this account`}):(0,R.jsx)(`div`,{className:Q.auditList,children:n.auditLog.map(e=>
69(0,R.jsxs)(`div`,{className:Q.auditRow,children:[(0,R.jsx)(`span`,{className:Q.auditEvent,children:hC[e.event_type]??e.event_type}),(0,R.jsx)(`span`,{className:Q.auditDetail,children:gC(e.event_type,e.detail)}),(0,R.jsx)(`span`,{className:Q.auditTime,children:_C(e.created_at)})]},e.id))})]})]})]})})}function SC(e){if(!e||typeof e!=`object`)return``;let t=e=>typeof e==`string`&&e.trim()?e.trim():``,n=t(e.platform)||t(e.deviceType),r=t(e.path);return[n,t(e.viewport),r].filter(Boolean).join(` · `)}var CC=[`done`,`skipped`,`uncertain`];function wC({onSelectUser:e}){let[t,n]=(0,_.useState)([]),[r,i]=(0,_.useState)(null),[a,o]=(0,_.useState)(0),[s,c]=(0,_.useState)(0),[l,u]=(0,_.useState)(``),[d,f]=(0,_.useState)(!0),[p,m]=(0,_.useState)(``),[h,g]=(0,_.useState)(Hx),[v,y]=(0,_.useState)(``),[b,x]=(0,_.useState)({}),S=(0,_.useRef)(0),C=(0,_.useCallback)(()=>{let e=++S.current;f(!0),m(``),dS({verdict:l||void 0,page:s}).then(t=>{e===S.current&&(n(t.rows),o(t.total),i(t.summary??null),t.pageSize&&g(t.pageSize))}).catch(t=>{e===S.current&&m(t instanceof Error?t.message:`failed`)}).finally(()=>{e===S.current&&f(!1)})},[l,s]);(0,_.useEffect)(()=>{C()},[C]);function w(e){u(e),c(0)}async function T(e){y(e);try{let t=await fS(e);x(n=>({...n,[e]:t})),C()}catch(e){alert(e instanceof Error?e.message:`the re-check failed`)}finally{y(``)}}let E=Math.max(1,Math.ceil(a/h)),D=r?Object.entries(Zx(r.byEvidenceSource)).sort((e,t)=>t[1]-e[1]):[];return(0,R.jsxs)(`section`,{className:Q.section,children:[(0,R.jsxs)(`div`,{className:Q.sectionHead,children:[(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`h2`,{className:Q.sectionTitle,children:`Verification records`}),(0,R.jsxs)(`p`,{className:Q.sectionSub,children:[`every judgment the pipeline has made â `,a.toLocaleString(),` total`]}),(0,R.jsx)(`p`,{className:Q.sectionNote,children:`Task text, judge reasoning and evidence titles are not in this response â the server drops them before it answers. What a founder writes stays theirs; what the pipeline decided is the product, and that is what this shows.`})]}),(0,R.jsx)(`div`,{className:Q.sectionActions,children:(0,R.jsxs)(`select`,{className:Q.select,value:l,onChange:e=>w(e.target.value),children:[(0,R.jsx)(`option`,{value:``,children:`all verdicts`}),CC.map(e=>(0,R.jsx)(`option`,{value:e,children:e},e))]})})]}),r&&r.total>0&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsxs)(`div`,{className:Q.metricRail,children:[(0,R.jsx)(xS,{label:`pass`,value:r.byLabel.PASS??0,sub:`${Math.round((r.byLabel.PASS??0)/r.total*100)}% of ${r.total}`}),(0,R.jsx)(xS,{label:`needs review`,value:r.byLabel[`NEEDS-REVIEW`]??0,sub:`judge would not assert`}),(0,R.jsx)(xS,{label:`fail`,value:r.byLabel.FAIL??0,sub:`asserted not done`}),(0,R.jsx)(xS,{label:`avg confidence`,value:`${Math.round($(r.avgConfidence)*100)}%`,sub:`across this window`}),(0,R.jsx)(xS,{label:`on evidence`,value:r.withEvidence,sub:`${r.withoutEvidence} on none`})]}),(0,R.jsxs)(`div`,{className:Q.distGrid,children:[(0,R.jsx)(GS,{title:`outcome mix`,note:`what the judge concluded, across this whole window`,dist:r.byLabel,tones:VS,order:[`PASS`,`NEEDS-REVIEW`,`FAIL`]}),(0,R.jsxs)(`div`,{className:Q.dist,children:[(0,R.jsxs)(`div`,{className:Q.distHead,children:[(0,R.jsx)(`span`,{className:Q.distTitle,children:`evidence sources`}),(0,R.jsx)(`span`,{className:Q.distTotal,children:D.reduce((e,[,t])=>e+t,0).toLocaleString()})]}),(0,R.jsx)(`p`,{className:Q.distNote,children:`which connector actually produced the proof`}),(0,R.jsx)(PS,{rows:D.map(([e,t],n)=>({key:e,label:e,value:t,sub:`${Math.round(t/Math.max(1,r.withEvidence)*100)}% of proven`,color:CS(n)})),empty:`no evidence recorded in this window`})]})]})]}),p&&(0,R.jsxs)(`div`,{className:Q.empty,children:[`failed to load (`,p,`)`]}),!p&&d&&t.length===0&&(0,R.jsx)(`div`,{className:Q.empty,children:`loadingâ¦`}),!p&&!d&&t.length===0&&(0,R.jsx)(`div`,{className:Q.empty,children:`no verification records yet`}),t.length>0&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`div`,{className:Q.tableWrap,children:(0,R.jsxs)(`table`,{className:Q.table,children:[(0,R.jsx)(`thead`,{children:(0,R.jsxs)(`tr`,{children:[(0,R.jsx)(`th`,{children:`when`}),(0,R.jsx)(`th`,{children:`who`}),(0,R.jsx)(`th`,{children:`category`}),(0,R.jsx)(`th`,{children:`verdict`}),(0,R.jsx)(`th`,{className:Q.thNum,children:`confidence`}),(0,R.jsx)(`th`,{children:`evidence`}),(0,R.jsx)(`th`,{children:`resolution`}),(0,R.jsx)(`th`,{})]})}),(0,R.jsx)(`tbody`,{children:t.map(t=>{let n=t.priority_id?b[t.priority_id]:void 0;return(0,R.jsxs)(`tr`,{children:[(0,R.jsx)(`td`,{className:Q.dateCell,children:_C(t.created_at)}),(0,R.jsx)(`td`,{children:t.user_id?(0,R.jsx)(`button`,{className:Q.linkBtn,onClick:()=>e(t.user_id),children:t.userName||t.userEmail||t.user_id.slice(0,8)}):(0,R.jsx)(`span`,{className:Q.emptyInline,children:`â`})}),(0,R.jsx)(`td`,{className:Q.subtleCell,children:t.taskCategory??`â`}),(0,R.jsxs)(`td`,{children:[(0,R.jsx)(WS,{label:t.label,tone:VS[t.label]??`neutral`}),n&&(0,R.jsxs)(`span`,{className:Q.recheckNote,children:[`re-checked `,(0,R.jsx)(WS,{label:n.label,tone:VS[n.label]??`neutral`}),` `,Math.round(n.confidence*100),`%`]})]}),(0,R.jsxs)(`td`,{className:Q.numCell,title:`model ${t.model??`â`} · prompt ${t.prompt_version??`â`}`,children:[Math.round(t.confidence*100),`%`]}),(0,R.jsx)(`td`,{className:Q.subtleCell,children:t.evidenceCount===0?(0,R.jsx)(`span`,{className:Q.emptyInline,children:`none`}):(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`span`,{className:Q.numInline,children:t.evidenceCount}),(0,R.jsx)(`span`,{className:Q.sourceList,children:t.evidenceSources.join(` · `)})]})}),(0,R.jsx)(`td`,{children:t.taskResolution?(0,R.jsx)(WS,{label:t.taskResolution,tone:US[t.taskResolution]??`neutral`}):t.taskStatus?(0,R.jsx)(WS,{label:t.taskStatus,tone:HS[t.taskStatus]??`neutral`}):(0,R.jsx)(`span`,{className:Q.emptyInline,children:`â`})}),(0,R.jsx)(`td`,{children:t.priority_id&&(0,R.jsx)(`button`,{className:Q.ghostBtn,disabled:v===t.priority_id,title:`run the real pipeline again against this task and record the result`,onClick:()=>T(t.priority_id),children:v===t.priority_id?`checkingâ¦`:`re-check`})})]},t.id)})})]})}),E>1&&(0,R.jsxs)(`div`,{className:Q.pagerRow,children:[(0,R.jsx)(`button`,{className:Q.ghostBtn,disabled:s===0,onClick:()=>c(s-1),children:`previous`}),(0,R.jsxs)(`span`,{className:Q.pagerLabel,children:[`page `,s+1,` of `,E]}),(0,R.jsx)(`button`,{className:Q.ghostBtn,disabled:s>=E-1,onClick:()=>c(s+1),children:`next`})]})]})]})}var TC=[`open`,`in_progress`,`shipped`,`wontfix`],EC=[`bug`,`feature`,`connector`,`other`],DC={critical:`bad`,high:`bad`,medium:`warn`,low:`neutral`};function OC({onSelectUser:e}){let[t,n]=(0,_.useState)([]),[r,i]=(0,_.useState)(0),[a,o]=(0,_.useState)(0),[s,c]=(0,_.useState)(``),[l,u]=(0,_.useState)(``),[d,f]=(0,_.useState)(!0),[p,m]=(0,_.useState)(``),[h,g]=(0,_.useState)(``),[v,y]=(0,_.useState)(Hx),b=(0,_.useRef)(0),x=(0,_.useCallback)(()=>{let e=++b.current;f(!0),m(``),lS({status:s||void 0,type:l||void 0,page:a}).then(t=>{e===b.current&&(n(t.rows),i(t.total),t.pageSize&&y(t.pageSize))}).catch(t=>{e===b.current&&m(t instanceof Error?t.message:`failed`)}).finally(()=>{e===b.current&&f(!1)})},[s,l,a]);(0,_.useEffect)(()=>{x()},[x]);function S(e){u(e),o(0)}function C(e){c(e),o(0)}async function w(e,r){g(e);let i=t;n(t=>t.map(t=>
69t.id===e?{...t,status:r}:t));try{await mS({action:`set_feedback_status`,id:e,status:r})}catch(e){n(i),alert(e instanceof Error?e.message:`failed to update`)}finally{g(``)}}let T=Math.max(1,Math.ceil(r/v));return(0,R.jsxs)(`section`,{className:Q.section,children:[(0,R.jsxs)(`div`,{className:Q.sectionHead,children:[(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`h2`,{className:Q.sectionTitle,children:`Feedback`}),(0,R.jsxs)(`p`,{className:Q.sectionSub,children:[`bugs, feature requests, connector asks â `,r.toLocaleString(),` total`]}),(0,R.jsx)(`p`,{className:Q.sectionNote,children:`Report text is kept, because it was written to be read here. The attachment is not: a bug screenshot is a picture of whatever else was on screen, so only whether one exists comes through.`})]}),(0,R.jsxs)(`div`,{className:Q.sectionActions,children:[(0,R.jsxs)(`select`,{className:Q.select,value:l,onChange:e=>S(e.target.value),children:[(0,R.jsx)(`option`,{value:``,children:`all types`}),EC.map(e=>(0,R.jsx)(`option`,{value:e,children:e},e))]}),(0,R.jsxs)(`select`,{className:Q.select,value:s,onChange:e=>C(e.target.value),children:[(0,R.jsx)(`option`,{value:``,children:`all statuses`}),TC.map(e=>(0,R.jsx)(`option`,{value:e,children:e},e))]})]})]}),p&&(0,R.jsxs)(`div`,{className:Q.empty,children:[`failed to load (`,p,`)`]}),!p&&d&&t.length===0&&(0,R.jsx)(`div`,{className:Q.empty,children:`loadingâ¦`}),!p&&!d&&t.length===0&&(0,R.jsx)(`div`,{className:Q.empty,children:`no feedback yet`}),t.length>0&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`div`,{className:Q.tableWrap,children:(0,R.jsxs)(`table`,{className:Q.table,children:[(0,R.jsx)(`thead`,{children:(0,R.jsxs)(`tr`,{children:[(0,R.jsx)(`th`,{children:`when`}),(0,R.jsx)(`th`,{children:`type`}),(0,R.jsx)(`th`,{children:`from`}),(0,R.jsx)(`th`,{children:`report`}),(0,R.jsx)(`th`,{children:`status`})]})}),(0,R.jsx)(`tbody`,{children:t.map(t=>(0,R.jsxs)(`tr`,{children:[(0,R.jsx)(`td`,{className:Q.dateCell,children:_C(t.created_at)}),(0,R.jsxs)(`td`,{children:[(0,R.jsx)(`span`,{className:Q.typeLabel,children:t.type}),t.severity&&(0,R.jsxs)(`span`,{className:Q.severity,children:[(0,R.jsx)(BS,{tone:DC[t.severity]??`neutral`}),t.severity]})]}),(0,R.jsx)(`td`,{children:t.user_id?(0,R.jsx)(`button`,{className:Q.linkBtn,onClick:()=>e(t.user_id),children:t.userName||t.userEmail||t.user_id.slice(0,8)}):(0,R.jsx)(`span`,{className:Q.emptyInline,children:`â`})}),(0,R.jsxs)(`td`,{className:Q.reportCell,children:[(0,R.jsx)(`span`,{className:Q.reportText,children:t.text}),(t.subcategory||t.hasAttachment||t.device_info)&&(0,R.jsxs)(`span`,{className:Q.reportMeta,children:[t.subcategory&&(0,R.jsx)(`span`,{children:t.subcategory}),t.hasAttachment&&(0,R.jsx)(`span`,{title:`the file itself never leaves the server â ask the reporter, or mint a signed URL out of band`,children:`attachment on file`}),SC(t.device_info)&&(0,R.jsx)(`span`,{children:SC(t.device_info)})]})]}),(0,R.jsx)(`td`,{children:(0,R.jsx)(`select`,{className:Q.select,value:t.status,disabled:h===t.id,onChange:e=>w(t.id,e.target.value),children:TC.map(e=>(0,R.jsx)(`option`,{value:e,children:e},e))})})]},t.id))})]})}),T>1&&(0,R.jsxs)(`div`,{className:Q.pagerRow,children:[(0,R.jsx)(`button`,{className:Q.ghostBtn,disabled:a===0,onClick:()=>o(e=>e-1),children:`previous`}),(0,R.jsxs)(`span`,{className:Q.pagerLabel,children:[`page `,a+1,` of `,T]}),(0,R.jsx)(`button`,{className:Q.ghostBtn,disabled:a>=T-1,onClick:()=>o(e=>e+1),children:`next`})]})]})]})}var kC=[`login`,`logout`,`signup`,`profile_updated`,`plan_changed`,`account_deleted`,`password_reset_requested`,`connector_connected`,`connector_disconnected`];function AC({onSelectUser:e}){let[t,n]=(0,_.useState)([]),[r,i]=(0,_.useState)(0),[a,o]=(0,_.useState)(0),[s,c]=(0,_.useState)(``),[l,u]=(0,_.useState)(``),[d,f]=(0,_.useState)(!0),[p,m]=(0,_.useState)(``),[h,g]=(0,_.useState)(Hx);(0,_.useEffect)(()=>{let e=!1,t=setTimeout(()=>{f(!0),m(``),cS({search:s||void 0,eventType:l||void 0,page:a}).then(t=>{e||(n(t.rows),i(t.total),t.pageSize&&g(t.pageSize))}).catch(t=>{e||m(t instanceof Error?t.message:`failed`)}).finally(()=>{e||f(!1)})},s?300:0);return()=>{e=!0,clearTimeout(t)}},[s,l,a]);function v(e){c(e),o(0)}function y(e){u(e),o(0)}let b=Math.max(1,Math.ceil(r/h));return(0,R.jsxs)(`section`,{className:Q.section,children:[(0,R.jsxs)(`div`,{className:Q.sectionHead,children:[(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`h2`,{className:Q.sectionTitle,children:`Audit log`}),(0,R.jsxs)(`p`,{className:Q.sectionSub,children:[`who signed in, who changed what â `,r.toLocaleStr
69ing(),` events`]})]}),(0,R.jsxs)(`div`,{className:Q.sectionActions,children:[(0,R.jsx)(`input`,{className:Q.input,type:`text`,placeholder:`search name or emailâ¦`,value:s,onChange:e=>v(e.target.value)}),(0,R.jsxs)(`select`,{className:Q.select,value:l,onChange:e=>y(e.target.value),children:[(0,R.jsx)(`option`,{value:``,children:`all events`}),kC.map(e=>(0,R.jsx)(`option`,{value:e,children:hC[e]??e},e))]})]})]}),p&&(0,R.jsxs)(`div`,{className:Q.empty,children:[`failed to load (`,p,`)`]}),!p&&d&&t.length===0&&(0,R.jsx)(`div`,{className:Q.empty,children:`loadingâ¦`}),!p&&!d&&t.length===0&&(0,R.jsx)(`div`,{className:Q.empty,children:`no matching events`}),t.length>0&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`div`,{className:Q.tableWrap,children:(0,R.jsxs)(`table`,{className:Q.table,children:[(0,R.jsx)(`thead`,{children:(0,R.jsxs)(`tr`,{children:[(0,R.jsx)(`th`,{children:`when`}),(0,R.jsx)(`th`,{children:`event`}),(0,R.jsx)(`th`,{children:`user`}),(0,R.jsx)(`th`,{children:`detail`})]})}),(0,R.jsx)(`tbody`,{children:t.map(t=>(0,R.jsxs)(`tr`,{children:[(0,R.jsx)(`td`,{className:Q.dateCell,children:_C(t.created_at)}),(0,R.jsx)(`td`,{children:hC[t.event_type]??t.event_type}),(0,R.jsx)(`td`,{children:t.user_id?(0,R.jsx)(`button`,{className:Q.linkBtn,onClick:()=>e(t.user_id),children:t.userName||t.userEmail||t.user_id.slice(0,8)}):(0,R.jsx)(`span`,{className:Q.emptyInline,children:`(deleted account)`})}),(0,R.jsx)(`td`,{className:Q.subtleCell,children:gC(t.event_type,t.detail)||`â`})]},t.id))})]})}),b>1&&(0,R.jsxs)(`div`,{className:Q.pagerRow,children:[(0,R.jsx)(`button`,{className:Q.ghostBtn,disabled:a===0,onClick:()=>o(e=>e-1),children:`previous`}),(0,R.jsxs)(`span`,{className:Q.pagerLabel,children:[`page `,a+1,` of `,b]}),(0,R.jsx)(`button`,{className:Q.ghostBtn,disabled:a>=b-1,onClick:()=>o(e=>e+1),children:`next`})]})]})]})}var jC=[`Mon`,`Tue`,`Wed`,`Thu`,`Fri`,`Sat`,`Sun`];function MC(e){return(new Date(`${e}T12:00:00Z`).getUTCDay()+6)%7}function NC(e,t){let n=Number(e.slice(0,4)),r=Number(e.slice(5,7));if(!Number.isFinite(n)||!Number.isFinite(r))return e;let i=new Date(Date.UTC(n,r-1+t,1));return`${i.getUTCFullYear()}-${String(i.getUTCMonth()+1).padStart(2,`0`)}`}function PC(){return new Date().toLocaleDateString(`en-CA`)}function FC(){let e=new Date;return e.setDate(e.getDate()+1),e.toLocaleDateString(`en-CA`)}var IC={day_already_counted:`that day is already counted. retract the task instead â the day keeps its score either way.`,day_not_closed:`that day isn't closed yet. change today's list on the Today screen, not here.`,task_completed:`you finished it. a completed task stays in the record.`,"not found":`that task isn't there anymore.`,"reason required":`say why in one line.`};function LC(){let e=z(),{lang:t}=ml(),[n,r]=(0,_.useState)(()=>new Date().toLocaleDateString(`en-CA`).slice(0,7)),[i,a]=(0,_.useState)(null),[o,s]=(0,_.useState)(!0),[c,l]=(0,_.useState)(``),[u,d]=(0,_.useState)(null),[f,p]=(0,_.useState)(``),[m,h]=(0,_.useState)(``),[g,v]=(0,_.useState)(``),y=(0,_.useRef)(0),b=(0,_.useCallback)(()=>{let e=++y.current;s(!0),l(``),vS(n).then(t=>{e===y.current&&a(t)}).catch(t=>{e===y.current&&l(t instanceof Error?t.message:`failed`)}).finally(()=>{e===y.current&&s(!1)})},[n]);(0,_.useEffect)(()=>{b()},[b]);function x(e,t){d({id:e,kind:t}),p(``),v(``)}function S(){d(null),p(``),v(``)}async function C(t,n,r){h(t.id),v(``);try{n===`delete`?await yS({action:`my_task_delete`,id:t.id,force:`1`}):n===`replan`?await yS({action:`my_task_replan`,id:t.id,date:r??``}):await yS({action:`my_task_retract`,id:t.id,reason:f.trim()}),S(),b()}catch(t){let n=t instanceof Error?t.message:`failed`;v(e(IC[n]??`that didn't go through ({code})`).replace(`{code}`,n))}finally{h(``)}}let w=i&&i.month===n?i:null,T=i?.months??[],E=T.length?T[0].month:n,D=T.length?T[T.length-1].month:n,O=T.find(e=>e.month===n)??null,k=i?.today??new Date().toLocaleDateString(`en-CA`),A=(()=>{let e=new Date(`${n}-01T12:00:00Z`);return isNaN(e.getTime())?n:e.toLocaleDateString(t===`fr`?`fr-FR`:`en-US`,{month:`long`,year:`numeric`,timeZone:`UTC`})})(),j=w?.days??[],ee=j.length?MC(j[0].date):0,te=[...j.filter(e=>!e.beforeStart&&!e.isFuture).reverse(),...j.filter(e=>!e.beforeStart&&e.isFuture&&e.locked>0)];function ne(e){return e.isFuture||e.beforeStart?`neutral`:e.locked===0?`bad`:e.good?`good`:e.done>0?`warn`:`bad`}function re(e){return e.beforeStart?Q.histCellBefore:e.isFuture?Q.histCellFuture:e.locked===0?Q.histCellEmpty:e.good?Q.histCellGood:e.done>0?Q.histCellMid:Q.histCellBad}function M(t,n){return n.status===`done`?{label:e(`done`),tone:`good`}:n.status===`skipped`?{label:e(`missed`),tone:`bad`}:t.date>k?{label:e(`upcoming`),tone:`neutral`}:t.date===k?{label:e(`in progress`),tone:`warn`}:{label:e(`missed`),tone:`bad`}}let N=e=>{let n=new Date(`${e}T12:00:00Z`);return isNaN(n.getTime())?e:n.toLocaleDateString(t===`fr`?`fr-FR`:`en-US`,{weekday:`long`,day:`numeric`,month:`short`,timeZone:`UTC`})};return(0,R.jsxs)(`section`,{className:Q.section,children:[(0,R.jsxs)(`div`,{className:Q.sectionHead,children:[(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`h2`,{className:Q.sectionTitle,children:e(`my history`)}),(0,R.jsx)(`p`,{className:Q.sectionSub,children:O?e(`{a} days locked · {e}
69 with nothing locked · {d}/{l} tasks done`).replace(`{a}`,String(O.activeDays)).replace(`{e}`,String(O.emptyDays)).replace(`{d}`,String(O.done)).replace(`{l}`,String(O.locked)):e(`your own record, day by day`)}),(0,R.jsx)(`p`,{className:Q.sectionNote,children:e(`a closed day keeps its count. a task you regret can be retracted â labelled, explained, still counted â because a delete that made a past day look better would make the whole record worthless. only days that have not happened yet can be deleted outright.`)})]}),(0,R.jsxs)(`div`,{className:Q.sectionActions,children:[(0,R.jsx)(`button`,{className:Q.ghostBtn,disabled:n<=E,onClick:()=>r(e=>NC(e,-1)),children:e(`previous`)}),(0,R.jsx)(`span`,{className:Q.histMonthLabel,children:A}),(0,R.jsx)(`button`,{className:Q.ghostBtn,disabled:n>=D,onClick:()=>r(e=>NC(e,1)),children:e(`next`)})]})]}),c&&(0,R.jsxs)(`div`,{className:Q.empty,children:[e(`failed to load`),` (`,c,`)`]}),!c&&!w&&(0,R.jsx)(`div`,{className:Q.empty,children:e(o?`loadingâ¦`:`nothing here yet`)}),!c&&w&&j.length===0&&(0,R.jsx)(`div`,{className:Q.empty,children:e(`nothing here yet`)}),!c&&j.length>0&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsxs)(`div`,{className:Q.histGrid,role:`group`,"aria-label":A,children:[jC.map(t=>(0,R.jsx)(`div`,{className:Q.histDow,children:e(t)},t)),Array.from({length:ee},(e,t)=>(0,R.jsx)(`div`,{className:Q.histBlank,"aria-hidden":`true`},`blank-${t}`)),j.map(t=>(0,R.jsxs)(`div`,{className:`${Q.histCell} ${re(t)} ${t.isToday?Q.histCellToday:``}`,title:t.beforeStart?N(t.date):t.isFuture?`${N(t.date)} â ${e(`upcoming`)}`:t.locked===0?`${N(t.date)} â ${e(`nothing locked`)}`:`${N(t.date)} â ${t.done}/${t.locked} (${t.score??0}%)`,children:[(0,R.jsx)(`span`,{className:Q.histCellNum,children:Number(t.date.slice(8,10))}),!t.isFuture&&!t.beforeStart&&t.locked===0&&(0,R.jsx)(`span`,{className:Q.histCellDash,"aria-hidden":`true`,children:`·`})]},t.date))]}),(0,R.jsxs)(`div`,{className:Q.histLegend,children:[(0,R.jsxs)(`span`,{children:[(0,R.jsx)(`i`,{className:`${Q.histSwatch} ${Q.histCellGood}`}),e(`good day`)]}),(0,R.jsxs)(`span`,{children:[(0,R.jsx)(`i`,{className:`${Q.histSwatch} ${Q.histCellMid}`}),e(`partial`)]}),(0,R.jsxs)(`span`,{children:[(0,R.jsx)(`i`,{className:`${Q.histSwatch} ${Q.histCellBad}`}),e(`nothing done`)]}),(0,R.jsxs)(`span`,{children:[(0,R.jsx)(`i`,{className:`${Q.histSwatch} ${Q.histCellEmpty}`}),e(`nothing locked`)]}),(0,R.jsxs)(`span`,{children:[(0,R.jsx)(`i`,{className:`${Q.histSwatch} ${Q.histCellFuture}`}),e(`upcoming`)]})]}),g&&!u&&(0,R.jsx)(`div`,{className:Q.histConfirmErr,style:{marginBottom:10},children:g}),(0,R.jsxs)(`div`,{className:Q.histDays,children:[te.length===0&&(0,R.jsx)(`div`,{className:Q.empty,children:e(`nothing here yet`)}),te.map(t=>(0,R.jsxs)(`div`,{className:`${Q.histDay} ${t.locked===0?Q.histDayEmpty:``}`,children:[(0,R.jsxs)(`div`,{className:Q.histDayHead,children:[(0,R.jsx)(BS,{tone:ne(t)}),(0,R.jsx)(`span`,{className:Q.histDayDate,children:N(t.date)}),t.isToday&&(0,R.jsx)(`span`,{className:Q.histDayTag,children:e(`today`)}),t.isToday&&t.locked>0&&(0,R.jsx)(`span`,{className:Q.histChip,children:e(`still open â change it on the Today screen`)}),(0,R.jsx)(`span`,{className:Q.histDayScore,children:t.isFuture?e(`upcoming`):t.locked===0?e(`nothing locked`):`${t.done}/${t.locked}${t.score===null?``:` · ${t.score}%`}`})]}),t.tasks.map(n=>{let r=M(t,n),i=t.date<k&&n.status!==`done`&&!n.retracted,a=n.status!==`done`,o=u?.id===n.id;return(0,R.jsxs)(`div`,{className:Q.histTask,children:[(0,R.jsxs)(`div`,{className:Q.histTaskMain,children:[(0,R.jsx)(`span`,{className:n.retracted?Q.histTaskTextOut:Q.histTaskText,children:n.text}),(0,R.jsxs)(`span`,{className:Q.histTaskMeta,children:[(0,R.jsx)(WS,{label:r.label,tone:r.tone}),(0,R.jsx)(`span`,{className:Q.histChip,children:n.category}),n.resolution&&e(n.resolution)!==r.label&&(0,R.jsx)(WS,{label:e(n.resolution),tone:US[n.resolution]??`neutral`}),n.resolvedLate&&(0,R.jsx)(`span`,{className:Q.histChip,children:e(`late`)}),n.unplanned&&(0,R.jsx)(`span`,{className:Q.histChip,children:e(`unplanned`)}),n.retracted&&(0,R.jsx)(`span`,{className:Q.histChipOut,children:e(`retracted`)})]}),n.retracted&&n.retractedReason&&(0,R.jsxs)(`span`,{className:Q.histRetractReason,children:[e(`retracted:`),` `,n.retractedReason,` â `,e(`still counted in this day`)]})]}
69),(0,R.jsxs)(`div`,{className:Q.histTaskActions,children:[!o&&(0,R.jsx)(`button`,{className:Q.deleteBtn,disabled:!!m,onClick:()=>x(n.id,`delete`),children:e(`delete`)}),!o&&i&&(0,R.jsx)(`button`,{className:Q.ghostBtn,disabled:!!m,onClick:()=>x(n.id,`retract`),children:e(`retract`)}),!o&&a&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(`button`,{className:Q.ghostBtn,disabled:!!m,title:e(`move this task to today`),onClick:()=>C(n,`replan`,PC()),children:e(`â today`)}),(0,R.jsx)(`button`,{className:Q.ghostBtn,disabled:!!m,title:e(`move this task to tomorrow`),onClick:()=>C(n,`replan`,FC()),children:e(`â tomorrow`)}),(0,R.jsx)(`input`,{className:Q.input,type:`date`,disabled:!!m,value:``,title:e(`move this task to a date you pick`),onChange:e=>{e.target.value&&C(n,`replan`,e.target.value)},style:{width:`auto`,padding:`2px 6px`,fontSize:`12px`}})]}),!o&&!1]}),o&&(0,R.jsxs)(`div`,{className:Q.histConfirm,children:[(0,R.jsx)(`p`,{className:Q.histConfirmMsg,children:u.kind===`delete`?t.date>k?e(`this day hasn't happened yet, so nothing is scored â the task goes for good.`):e(`this rewrites a scored day: the task vanishes from the record for good, and the day is re-scored without it.`):e(`the task stays in this day's count. only its label changes, so the day can't come out better than you lived it.`)}),u.kind===`retract`&&(0,R.jsx)(`input`,{className:Q.input,type:`text`,maxLength:280,autoFocus:!0,placeholder:e(`why? one line.`),value:f,onChange:e=>p(e.target.value)}),g&&(0,R.jsx)(`p`,{className:Q.histConfirmErr,children:g}),(0,R.jsxs)(`div`,{className:Q.histConfirmRow,children:[(0,R.jsx)(`button`,{className:Q.dangerBtn,disabled:m===n.id||u.kind===`retract`&&f.trim().length<3,onClick:()=>C(n,u.kind),children:m===n.id?`â¦`:u.kind===`delete`?e(`delete for good`):e(`retract it`)}),(0,R.jsx)(`button`,{className:Q.ghostBtn,disabled:m===n.id,onClick:S,children:e(`cancel`)})]})]})]},n.id)})]},t.date))]})]})]})}var RC=[{key:`overview`,label:`Overview`,hint:`headline numbers, traffic, growth, retention`},{key:`audience`,label:`Audience`,hint:`top pages, when people lock, usage density`},{key:`people`,label:`People`,hint:`accounts, waitlist, subscriptions`},{key:`verification`,label:`Verification`,hint:`judge calibration and every record`},{key:`content`,label:`Content`,hint:`blog posts and publishing health`},{key:`signals`,label:`Signals`,hint:`feedback and the audit log`},{key:`me`,label:`My history`,hint:`the founder's own locked days`}],zC=new Set(RC.map(e=>e.key));function BC(){let e=()=>{let e=window.location.hash.replace(/^#/,``);return zC.has(e)?e:`overview`},[t,n]=(0,_.useState)(e);return(0,_.useEffect)(()=>{let t=()=>n(e());return window.addEventListener(`hashchange`,t),()=>window.removeEventListener(`hashchange`,t)},[]),[t,(0,_.useCallback)(e=>{window.location.hash=e,n(e),window.scrollTo({top:0})},[])]}function VC(){let[e,t]=BC(),[n,r]=(0,_.useState)(`30d`),[i,a]=(0,_.useState)(null),[o,s]=(0,_.useState)(!0),[c,l]=(0,_.useState)(!1),[u,d]=(0,_.useState)(``),[f,p]=(0,_.useState)(``),[m,h]=(0,_.useState)(null),[g,v]=(0,_.useState)(!1),[y,b]=(0,_.useState)(()=>Date.now()),[x,S]=(0,_.useState)(0),C=(0,_.useRef)(null),w=(0,_.useRef)(0),T=(0,_.useRef)(null),[E,D]=(0,_.useState)(`cumulative`),[O,k]=(0,_.useState)(`cumulative`),[A,j]=(0,_.useState)(new Set),[ee,te]=(0,_.useState)(new Set),[ne,re]=(0,_.useState)(null),M=e===`overview`||e===`audience`||e===`people`,N=e=>t=>e(e=>{let n=new Set(e);return n.has(t)?n.delete(t):n.add(t),n}),ie=(0,_.useCallback)(async(e=!1)=>{let t=++w.current;e?l(!0):(s(!0),d(``));try{let e=await eS(n);if(t!==w.current)return;C.current!==null&&e.waitlistCount>C.current&&(v(!0),T.current&&clearTimeout(T.current),T.current=setTimeout(()=>v(!1),5e3)),C.current=e.waitlistCount,a(e),d(``),h(Date.now()),b(Date.now()),S(e=>e+1)}catch(e){if(t!==w.current)return;d(e instanceof Error?e.message:`failed`)}finally{t===w.current&&(s(!1),l(!1))}},[n]);(0,_.useEffect)(()=>{ie()},[ie]),(0,_.useEffect)(()=>{let e=null,t=()=>{e===null&&(e=setInterval(()=>ie(!0),Ux))},n=()=>{e!==null&&(clearInterval(e),e=null)},r=()=>{document.visibilityState===`hidden`?n():(ie(!0),t())};return document.visibilityState!==`hidden`&&t(),document.addEventListener(`visibilitychange`,r),()=>{n(),document.removeEventListener(`visibilitychange`,r)}},[ie]),(0,_.useEffect)(()=>
69{if(m===null)return;let e=setInterval(()=>{document.visibilityState!==`hidden`&&b(Date.now())},5e3);return()=>clearInterval(e)},[m]),(0,_.useEffect)(()=>()=>{T.current&&clearTimeout(T.current)},[]);async function ae(e,t){p(e);try{await mS(t),await ie()}catch(e){alert(e instanceof Error?e.message:`action failed`)}finally{p(``)}}let P=i,oe=n===`today`?1:n===`7d`?7:30;return(0,R.jsxs)(`div`,{className:Q.dashboard,children:[(0,R.jsxs)(`header`,{className:Q.header,children:[(0,R.jsxs)(`div`,{className:Q.headerLeft,children:[(0,R.jsx)(El,{size:18}),(0,R.jsx)(`span`,{className:Q.adminTag,children:`admin`})]}),(0,R.jsx)(`div`,{className:Q.headerRight,children:M&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsxs)(`span`,{className:Q.liveWrap,children:[(0,R.jsx)(`span`,{className:`${Q.liveDot} ${c?Q.liveDotBusy:``}`}),(0,R.jsx)(`span`,{className:Q.liveText,children:c?`refreshing`:m===null?`connecting`:`updated ${vC(y-m)}`})]}),(0,R.jsx)(`div`,{className:Q.segmented,children:[`today`,`7d`,`30d`].map(e=>(0,R.jsx)(`button`,{type:`button`,className:`${Q.segmentedBtn} ${n===e?Q.segmentedBtnActive:``}`,onClick:()=>r(e),children:e===`today`?`today`:e},e))}),(0,R.jsx)(`button`,{className:Q.ghostBtn,onClick:()=>ie(),disabled:o||c,children:`refresh`})]})})]}),(0,R.jsx)(`nav`,{className:Q.tabs,"aria-label":`Admin sections`,children:RC.map(n=>(0,R.jsx)(`button`,{type:`button`,title:n.hint,"aria-current":e===n.key?`page`:void 0,className:`${Q.tab} ${e===n.key?Q.tabActive:``}`,onClick:()=>t(n.key),children:n.label},n.key))}),(0,R.jsx)(`p`,{className:Q.tabHint,children:RC.find(t=>t.key===e)?.hint}),M&&o&&(0,R.jsx)(`div`,{className:Q.loadingBar}),M&&u&&(0,R.jsxs)(`div`,{className:Q.errorBanner,children:[u,` â `,(0,R.jsx)(`button`,{onClick:()=>ie(),children:`retry`})]}),M&&!P&&o&&(0,R.jsx)(`div`,{className:Q.empty,children:`loading the dashboardâ¦`}),M&&!P&&!o&&!!u&&(0,R.jsx)(`div`,{className:Q.empty,children:`couldn't load the dashboard â the error above has the details.`}),P&&(0,R.jsxs)(R.Fragment,{children:[e===`overview`&&(()=>{let e=P.dailyFlux.map(e=>e.date),t=t=>{let n={};for(let e of t){if(typeof e?.created_at!=`string`)continue;let t=e.created_at.slice(0,10);n[t]=(n[t]??0)+1}return e.map(e=>n[e]??0)},r=P.dailyFlux.map(e=>$(e.visitors)),i=P.dailyFlux.map(e=>$(e.views)),a=t(P.signups),o=t(P.waitlistEntries),s=P.devices.mobile+P.devices.tablet+P.devices.desktop||1,c=e=>Math.round(e/s*100),l=Math.round(P.uniqueVisitors/Math.max(1,oe)),u=P.uniqueVisitors>0?(P.totalPageViews/P.uniqueVisitors).toFixed(1):`0`,d=P.mau>0?Math.round(P.wau/P.mau*100):0,f=Jx(a),p=Jx(o),m=n===`today`?`today`:`the last ${n}`,h=[{key:`github`,label:`github`,value:$(P.featureAdoption.github)},{key:`calendar`,label:`calendar`,value:$(P.featureAdoption.google_calendar)},{key:`telegram`,label:`telegram`,value:$(P.featureAdoption.telegram)},{key:`x`,label:`x`,value:$(P.featureAdoption.x)},{key:`discord`,label:`discord`,value:$(P.featureAdoption.discord)}].sort((e,t)=>t.value-e.value).map((e,t)=>({...e,color:CS(t),sub:`${P.signupCount>0?Math.round(e.value/P.signupCount*100):0}% of accounts`})),g={"no activity":0,"1â3 days":0,"4â9 days":0,"10â19 days":0,"20+ days":0},_={"none done":0,"under 50%":0,"50â79%":0,"80â99%":0,"all done":0};for(let e of P.signups){let t=$(e?.activeDaysLast30);g[t<=0?`no activity`:t<=3?`1â3 days`:t<=9?`4â9 days`:t<=19?`10â19 days`:`20+ days`]++;let n=$(e?.completionRate);_[n<=0?`none done`:n<50?`under 50%`:n<80?`50â79%`:n<100?`80â99%`:`all done`]++}return(0,R.jsxs)(R.Fragment,{children:[(0,R.jsxs)(`div`,{className:Q.headRail,children:[(0,R.jsx)(MS,{label:`mrr`,ci:4,value:`$${P.mrr.toLocaleString()}`,sub:`${P.activeSubscriptions} paid · $${P.arr.toLocaleString()} arr`}),(0,R.jsx)(MS,{label:`accounts`,ci:2,value:P.signupCount.toLocaleString(),spark:a,delta:kS(a),sub:`+${f} in ${m} · ${P.trialCount} on trial`}),(0,R.jsx)(MS,{label:`active accounts`,ci:5,value:P.wau.toLocaleString(),sub:`${P.mau} monthly · ${d}% come back weekly`}),(0,R.jsx)(MS,{label:`visitors`,ci:0,value:P.uniqueVisitors.toLocaleString(),spark:r,delta:kS(r),sub:`${l.toLocaleStr
69ing()} / day`}),(0,R.jsx)(MS,{label:`page views`,ci:1,value:P.totalPageViews.toLocaleString(),spark:i,delta:kS(i),sub:`${u} per visitor`}),(0,R.jsx)(MS,{label:`waitlist`,ci:3,value:P.waitlistCount.toLocaleString(),spark:o,delta:kS(o),sub:`+${p} in ${m}`})]}),(0,R.jsx)(`p`,{className:Q.headNote,children:`Every delta compares the most recent half of this window against the half before it â the endpoint answers one window at a time, so there is no earlier period to borrow and none is invented. MRR and active accounts are a live count with no series behind them, so they carry no arrow.`}),P.uniqueVisitors>0&&(0,R.jsxs)(`div`,{className:Q.deviceRow,children:[(0,R.jsx)(NS,{segments:[{key:`desktop`,label:`desktop`,value:P.devices.desktop,color:CS(0)},{key:`mobile`,label:`mobile`,value:P.devices.mobile,color:CS(1)},{key:`tablet`,label:`tablet`,value:P.devices.tablet,color:CS(2)}],ariaLabel:`device split: desktop ${c(P.devices.desktop)}%, mobile ${c(P.devices.mobile)}%, tablet ${c(P.devices.tablet)}%`}),(0,R.jsx)(`span`,{className:Q.compLegend,children:[[`desktop`,P.devices.desktop,0],[`mobile`,P.devices.mobile,1],[`tablet`,P.devices.tablet,2]].map(([e,t,n])=>(0,R.jsxs)(`span`,{className:Q.compItem,children:[(0,R.jsx)(`span`,{className:Q.swatchDot,style:{background:CS(n)},"aria-hidden":`true`}),e,(0,R.jsxs)(`b`,{children:[c(t),`%`]})]},e))})]}),(0,R.jsxs)(`section`,{className:Q.section,children:[(0,R.jsx)(`div`,{className:Q.sectionHead,children:(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`h2`,{className:Q.sectionTitle,children:`Traffic`}),(0,R.jsxs)(`p`,{className:Q.sectionSub,children:[P.uniqueVisitors.toLocaleString(),` unique visitor`,P.uniqueVisitors===1?``:`s`,` and `,P.totalPageViews.toLocaleString(),` view`,P.totalPageViews===1?``:`s`,` in `,m]})]})}),P.dailyFlux.every(e=>e.visitors===0&&e.views===0)?(0,R.jsx)(`div`,{className:Q.empty,children:`no visitor data yet â analytics events will appear here once tracking fires`}):(0,R.jsx)(LS,{dates:e,series:[{key:`visitors`,label:`unique visitors`,ci:0,values:r},{key:`views`,label:`page views`,ci:1,values:i}],hidden:A,onToggle:N(j),mode:E,onMode:D})]}),(0,R.jsxs)(`section`,{className:Q.section,children:[(0,R.jsx)(`div`,{className:Q.sectionHead,children:(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`h2`,{className:Q.sectionTitle,children:`Growth`}),(0,R.jsx)(`p`,{className:Q.sectionSub,children:`accounts and waitlist joins per day â counted from the join dates already in this response, on the same axis as traffic`})]})}),f===0&&p===0?(0,R.jsxs)(`div`,{className:Q.empty,children:[`nobody joined in `,m]}):(0,R.jsx)(LS,{dates:e,series:[{key:`accounts`,label:`new accounts`,ci:2,values:a},{key:`waitlist`,label:`waitlist joins`,ci:3,values:o}],hidden:ee,onToggle:N(te),mode:O,onMode:k})]}),(0,R.jsxs)(`section`,{className:Q.section,children:[(0,R.jsx)(`div`,{className:Q.sectionHead,children:(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`h2`,{className:Q.sectionTitle,children:`Work committed`}),(0,R.jsxs)(`p`,{className:Q.sectionSub,children:[P.taskVolume.toLocaleString(),` task`,P.taskVolume===1?``:`s`,` created in this range â what kind, how they resolved, what the judge concluded`]})]})}),P.taskVolume===0&&Object.keys(P.verdictCounts).length===0?(0,R.jsx)(`div`,{className:Q.empty,children:`no tasks created in this range`}):(0,R.jsxs)(`div`,{className:Q.distGrid,children:[(0,R.jsx)(GS,{title:`category`,note:`what founders commit to`,dist:P.categoryDistribution,palette:!0}),(0,R.jsx)(GS,{title:`status`,note:`whether it got marked done`,dist:P.statusDistribution,tones:HS,order:[`done`,`pending`,`skipped`]}),(0,R.jsx)(GS,{title:`resolution`,note:`how a completion was established`,dist:P.resolutionDistribution,tones:US,order:[`verified`,`attested`,`missed`,`unresolved`]}),(0,R.jsx)(GS,{title:`verdict`,note:`what the judge concluded`,dist:P.verdictCounts,tones:VS,order:[`PASS`,`NEEDS-REVIEW`,`FAIL`]})]})]}),(0,R.jsxs)(`section`,{className:Q.section,children:[(0,R.jsx)(`div`,{className:Q.sectionHead,children:(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`h2`,{className:Q.sectionTitle,children:`Retention`}),(0,R.jsx)(`p`,{className:Q.sectionSub,children:`every account placed in a band, not averaged into one number â an average of 8 active days hides whether that is everyone half-in or half the list gone dark`})]})}),P.signupCount===0?(0,R.jsx)(`div`,{className:Q.empty,children:`no accounts yet`}):(0,R.jsxs)(`div`,{className:Q.distGrid,children:[(0,R.jsx)(GS,{title:`days active â last 30`,n
69ote:`how deep the habit goes`,dist:g,palette:!0,order:[`20+ days`,`10â19 days`,`4â9 days`,`1â3 days`,`no activity`]}),(0,R.jsx)(GS,{title:`completion rate`,note:`of the tasks each account locked`,dist:_,palette:!0,order:[`all done`,`80â99%`,`50â79%`,`under 50%`,`none done`]})]})]}),(0,R.jsxs)(`section`,{className:Q.section,children:[(0,R.jsx)(`div`,{className:Q.sectionHead,children:(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`h2`,{className:Q.sectionTitle,children:`Adoption`}),(0,R.jsxs)(`p`,{className:Q.sectionSub,children:[`which evidence sources and channels are actually connected â against `,P.signupCount.toLocaleString(),` account`,P.signupCount===1?``:`s`]})]})}),(0,R.jsx)(PS,{rows:h,max:P.signupCount,empty:`no connectors linked yet`})]})]})})(),e===`audience`&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsxs)(`section`,{className:Q.section,children:[(0,R.jsx)(`div`,{className:Q.sectionHead,children:(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`h2`,{className:Q.sectionTitle,children:`Top pages`}),(0,R.jsx)(`p`,{className:Q.sectionSub,children:`most-visited authenticated routes, this range`})]})}),(0,R.jsx)(qS,{pages:P.topPages})]}),(0,R.jsxs)(`section`,{className:Q.section,children:[(0,R.jsx)(`div`,{className:Q.sectionHead,children:(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`h2`,{className:Q.sectionTitle,children:`Lock time of day`}),(0,R.jsx)(`p`,{className:Q.sectionSub,children:`when founders actually lock their tasks â hour, UTC`})]})}),(0,R.jsx)(XS,{hours:P.lockTimeHistogram})]}),(0,R.jsx)(Rx,{inline:!0,label:`Usage activity`,children:(0,R.jsx)(cC,{range:n,signups:P.signups,tick:x,nowTick:y,onSelectUser:re})})]}),e===`people`&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsxs)(`section`,{className:Q.section,children:[(0,R.jsxs)(`div`,{className:Q.sectionHead,children:[(0,R.jsxs)(`div`,{children:[(0,R.jsxs)(`h2`,{className:Q.sectionTitle,children:[`Waitlist`,g&&(0,R.jsx)(`span`,{className:Q.newBadge,children:`new`})]}),(0,R.jsxs)(`p`,{className:Q.sectionSub,children:[P.waitlistCount,` `,P.waitlistCount===1?`person`:`people`]})]}),(0,R.jsxs)(`div`,{className:Q.sectionActions,children:[(0,R.jsx)(`button`,{className:Q.ghostBtn,onClick:()=>uC([[`email`,`phone`,`company`,`role`,`referral`,`date`],...P.waitlistEntries.map(e=>[e.email,e.phone??``,e.company??``,e.role??``,e.referral??``,e.created_at.slice(0,10)])],`waitlist-${new Date().toISOString().slice(0,10)}.csv`),children:`export CSV`}),(0,R.jsx)(`button`,{className:Q.dangerBtn,disabled:!!f||P.waitlistEntries.length===0,onClick:()=>confirm(`Delete ALL waitlist entries?`)&&ae(`all_waitlist`,{action:`delete`,type:`all_waitlist`}),children:f===`all_waitlist`?`clearingâ¦`:`clear all`})]})]}),P.waitlistEntries.length===0?(0,R.jsx)(`div`,{className:Q.empty,children:`no waitlist entries yet`}):(0,R.jsx)(`div`,{className:Q.tableWrap,children:(0,R.jsxs)(`table`,{className:Q.table,children:[(0,R.jsx)(`thead`,{children:(0,R.jsxs)(`tr`,{children:[(0,R.jsx)(`th`,{className:Q.thNum,children:`#`}),(0,R.jsx)(`th`,{children:`email`}),(0,R.jsx)(`th`,{children:`phone`}),(0,R.jsx)(`th`,{children:`company`}),(0,R.jsx)(`th`,{children:`role`}),(0,R.jsx)(`th`,{children:`how they found us`}),(0,R.jsx)(`th`,{children:`date`}),(0,R.jsx)(`th`,{})]})}),(0,R.jsx)(`tbody`,{children:P.waitlistEntries.map((e,t)=>(0,R.jsxs)(`tr`,{children:[(0,R.jsx)(`td`,{className:Q.numCell,children:P.waitlistEntries.length-t}),(0,R.jsx)(`td`,{className:Q.emailCell,children:e.email}),(0,R.jsx)(`td`,{className:Q.subtleCell,children:e.phone??`â`}),(0,R.jsx)(`td`,{children:e.company??`â`}),(0,R.jsx)(`td`,{children:e.role??`â`}),(0,R.jsx)(`td`,{className:Q.refCell,children:e.referral??`â`}),(0,R.jsx)(`td`,{className:Q.dateCell,children:new Date(e.created_at).toLocaleDateString(`en-US`,{month:`short`,day:`numeric`,year:`numeric`})}),(0,R.jsx)(`td`,{children:(0,R.jsx)(`button`,{className:Q.deleteBtn,disabled:!!f,title:`Delete this entry`,onClick:()=>ae(`wl-${e.id}`,{action:`delete`,type:`waitlist`,id:e.id}),children:f===`wl-${e.id}`?`â¦`:`delete`})})]},e.id))})]})})]}),(0,R.jsxs)(`section`,{className:Q.section,children:[(0,R.jsxs)(`div`,{className:Q.sectionHead,children:[(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`h2`,{className:Q.sectionTitle,children:`Accounts`}),(0,R.jsxs)(`p`,{className:Q.sectionSub,children:[P.signupCount,` `,P.signupCount===1?`account`:`accounts`]})]}),(0,R.jsx)(`button`,{className:Q.ghostBtn,onClick:()=>uC([[`name`,`email`,`joined`],...P.signups.map(e=>[e.name??``,e.email,e.created_at.slice(0,10)])],`accounts-${new Date().toISOString().slice(0,10)}.csv`),children:`export CSV`})]}),P.signups.length===0?(0,R.jsx)(`div`,{className:Q.empty,children:`no accounts yet`}):(0,R.jsx)(`div`,{className:Q.tableWrap,children:(0,R.jsxs)(`table`,{className:Q.table,children:[(0,R.jsx)(`thead`,{children:(0,R.jsxs)(`tr`,{children:[(0,R.jsx)(`th`,{className:Q.thNum,children:`#`}),(0,R.jsx)(`th`,{children:`name`}),(0,R.jsx)(`th`,{children:`email`}),(0,R.jsx)(`th`,{children:`plan`}),(0,R.jsx)(`th`,{className:Q.thNum,children:`completion`}),(0,R.jsx)(`th`,{className:Q.thNum,children:`streak`}),(0,R.jsx)(`th`,{className:Q.thNum,title:`how steady day-to-day, not just the average â 100 = same rate every day`,children:`consistency`}),(0,R.jsx)(`th`,{className:Q.thNum,children:`messages`}),(0,R.jsx)(`th`,{className:Q.thNum,children:`sessions`}),(0,R.jsx)(`th`,{children:`last active`}),(0,R.jsx)(`th`,{children:`joined`}),(0,R.jsx)(`th`,{})]})}),(0,R.jsx)(`tbody`,{children:P.signups.map((e,t)=>(0,R.jsxs)(`tr`,{children:[(0,R.jsx)(`td`,{className:Q.numCell,children:P.signups.length-t}),(0,R.jsx)(`td`,{children:(0,R.jsx)(`button`,{className:Q.linkBtn,onClick:()=>re(e.id),title:`View full activity`,children:e.name??`â`})}),(0,R.jsx)(`td`,{className:Q.emailCell,children:e.email}),(0,R.jsx)(`td`,{children:(0,R.jsxs)(`select`,{className:Q.select,value:e.plan,disabled:!!f,title:`Set plan (free comp â no charge)`,onChange:t=>ae(`plan-${e.id}`,{action:`set_plan`,id:e.id,plan:t.target.value}),children:[(0,R.jsx)(`option`,{value:`trial`,children:`trial`}),(0,R.jsx)(`option`,{value:`solo`,children:`solo`}),(0,R.jsx)(`option`,{value:`founder`,children:`founder`})]})}),(0,R.jsxs)(`td`,{className:Q.numCell,children:[e.completionRate,`% `,(0,R.jsxs)(`span`,{className:Q.numSub,children:[`(`,e.tasksDone,`)`]})]}),(0,R.jsxs)(`td`,{className:Q.numCell,children:[e.streak,`d `,(0,R.jsxs)(`span`,{className:Q.numSub,children:[`/ `,e.longestStreak,`d`]})]}),(0,R.jsx)(`td`,{className:Q.numCell,children:e.consistency}),(0,R.jsx)(`td`,{className:Q.numCell,children:e.totalMessages}),(0,R.jsx)(`td`,{className:Q.numCell,children:e.sessionCount}),(0,R.jsx)(`td`,{className:Q.dateCell,children:dC(e.lastActive??e.last_sign_in_at)}),(0,R.jsx)(`td`,{className:Q.dateCell,children:new Date(e.created_at).toLocaleDateString(`en-US`,{month:`short`,day:`numeric`,year:`numeric`})}),(0,R.jsx)(`td`,{children:(0,R.jsx)(`button`,{className:Q.deleteBtn,disabled:!!f,title:`Delete account permanently`,onClick:()=>confirm(`Delete account for ${e.email}? This cannot be undone.`)&&ae(`acc-${e.id}`,{action:`delete`,type:`profile`,id:e.id}),children:f===`acc-${e.id}`?`â¦`:`delete`})})]},e.id))})]})})]}),P.stripeSubscriptions.length>0&&(0,R.jsxs)(`section`,{className:Q.section,children:[(0,R.jsx)(`div`,{className:Q.sectionHead,children:(0,R.jsxs)(`div`,{children:[(0,R.jsx)(`h2`,{className:Q.sectionTitle,children:`Subscriptions`}),(0,R.jsxs)(`p`,{className:Q.sectionSub,children:[P.stripeSubscriptions.length,` total, live from Stripe`]})]})}),(0,R.jsx)(`div`,{className:Q.tableWrap,children:(0,R.jsxs)(`table`,{className:Q.table,children:[(0,R.jsx)(`thead`,{children:(0,R.jsxs)(`tr`,{children:[(0,R.jsx)(`th`,{children:`id`}),(0,R.jsx)(`th`,{children:`customer`}),(0,R.jsx)(`th`,{children:`status`}),(0,R.jsx)(`th`,{className:Q.thNum,children:`amount`}),(0,R.jsx)(`th`,{children:`renews / trial ends`}),(0,R.jsx)(`th`,{})]})}),(0,R.jsx)(`tbody`,{children:P.stripeSubscriptions.map(e=>(0,R.jsxs)(`tr`,{children:[(0,R.jsxs)(`td`,{className:Q.subtleCell,children:[e.id.slice(0,14),`â¦`]}),(0,R.jsx)(`td`,{className:Q.emailCell,children:e.customer_email}),(0,R.jsx)(`td`,{children:(0,R.jsx)(WS,{label:e.status,tone:e.status===`trialing`?`warn`:`good`})}),(0,R.jsxs)(`td`,{className:Q.numCell,children:[`$`,e.amount,`/`,e.interval===`year`?`yr`:`mo`]}),(0,R.jsx)(`td`,{className:Q.dateCell,children:e.status===`trialing`&&e.trial_end?`trial ends ${new Date(e.trial_end*1e3).toLocaleDateString(`en-US`,{month:`short`,day:`numeric`})}`:new Date(e.current_period_end*1e3).toLocaleDateString(`en-US`,{month:`short`,day:`numeric`,year:`numeric`})}),(0,R.jsx)(`td`,{children:(0,R.jsx)(`button`,{className:Q.deleteBtn,disabled:!!f,title:`Cancel subscription`,onClick:()=>confirm(`Cancel ${e.id} for ${e.customer_email}?`)&&ae(`sub-${e.id}`,{action:`cancel_subscription`,sub_id:e.id}),children:f===`sub-${e.id}`?`â¦`:`cancel`})})]},e.id))})]})})]})]})]}),e===`verification`&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(R
69x,{inline:!0,label:`Judge calibration`,children:(0,R.jsx)(mC,{})}),(0,R.jsx)(Rx,{inline:!0,label:`Verification records`,children:(0,R.jsx)(wC,{onSelectUser:re})})]}),e===`content`&&(0,R.jsx)(Rx,{inline:!0,label:`Blog`,children:(0,R.jsx)(rS,{})}),e===`signals`&&(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(Rx,{inline:!0,label:`Proactive`,children:(0,R.jsx)(oS,{onSelectUser:re})}),(0,R.jsx)(Rx,{inline:!0,label:`Feedback`,children:(0,R.jsx)(OC,{onSelectUser:re})}),(0,R.jsx)(Rx,{inline:!0,label:`Audit log`,children:(0,R.jsx)(AC,{onSelectUser:re})})]}),e===`me`&&(0,R.jsx)(Rx,{inline:!0,label:`My history`,children:(0,R.jsx)(LC,{})}),ne&&(0,R.jsx)(Rx,{inline:!0,label:`Account detail`,children:(0,R.jsx)(xC,{userId:ne,onClose:()=>re(null)})})]})}function HC(){let{session:e,loading:t}=ll();return Gx=e?.access_token??``,e?e.user.email===zx?(0,R.jsx)(VC,{}):(0,R.jsx)(bS,{status:`wrong_account`}):t?(0,R.jsx)(bS,{status:`loading`}):(0,R.jsx)(bS,{status:`signed_out`})}var UC=(0,_.lazy)(()=>S(()=>import(`./NcLanding-DmmPSCay.js`),__vite__mapDeps([0,1,2,3,4,5,6]))),WC=(0,_.lazy)(()=>S(()=>import(`./NcApp-C0NDJ1do.js`),__vite__mapDeps([7,1,2,8,4,9,10,3,5,11,12]))),GC=(0,_.lazy)(()=>S(()=>import(`./NcProfile-D6gGc6j7.js`),__vite__mapDeps([13,8,4,9,10,3,11,14]))),KC=(0,_.lazy)(()=>S(()=>import(`./NcAdmin-K4DPP3x5.js`),__vite__mapDeps([15,3,4,5,11,9,16]))),qC=(0,_.lazy)(()=>S(()=>import(`./NcLegal-D6WvNLwu.js`).then(e=>({default:e.NcPrivacy})),__vite__mapDeps([17,3,4,18]))),JC=(0,_.lazy)(()=>S(()=>import(`./NcLegal-D6WvNLwu.js`).then(e=>({default:e.NcTerms})),__vite__mapDeps([17,3,4,18]))),YC=(0,_.lazy)(()=>S(()=>import(`./NcDemo-CncGyNBs.js`),__vite__mapDeps([19,4,9,20]))),XC=(0,_.lazy)(()=>S(()=>import(`./NcDemo-CncGyNBs.js`).then(e=>({default:e.NcDemoHome})),__vite__mapDeps([19,4,9,20])));function ZC(){let{session:e,loading:t}=ll();if(e)return(0,R.jsx)(Ut,{});if(t)return null;let n=window.location.search+window.location.hash;return(0,R.jsx)(Ht,{to:/[?#&]error(_description)?=/.test(n)?`/auth${window.location.search}${window.location.hash}`:`/auth`,replace:!0})}function QC(){let{session:e,loading:t}=ll(),n=ul();return t?null:e?(0,R.jsx)(Ht,{to:n?`/app`:`/onboarding`,replace:!0}):(0,R.jsx)(Ut,{})}function $C(){let{loading:e}=ll(),t=ul();return e?null:t?(0,R.jsx)(Ut,{}):(0,R.jsx)(Ht,{to:`/onboarding`,replace:!0})}function ew(){let{loading:e}=ll(),t=ul();return e?null:t?(0,R.jsx)(Ht,{to:`/app`,replace:!0}):(0,R.jsx)(Ut,{})}function tw(){return(0,R.jsx)(pl,{children:(0,R.jsxs)(cl,{children:[(0,R.jsx)(hl,{}),(0,R.jsx)(Cl,{children:(0,R.jsxs)(Kt,{children:[(0,R.jsx)(Wt,{path:`/`,element:(0,R.jsx)(gd,{})}
69),(0,R.jsx)(Wt,{path:`/admin`,element:(0,R.jsx)(Rx,{label:`The admin console`,children:(0,R.jsx)(HC,{})})}),(0,R.jsx)(Wt,{path:`/loop`,element:(0,R.jsx)(Rm,{})}),(0,R.jsx)(Wt,{path:`/privacy`,element:(0,R.jsx)(Vp,{})}),(0,R.jsx)(Wt,{path:`/subprocessors`,element:(0,R.jsx)(Kp,{})}),(0,R.jsx)(Wt,{path:`/compliance`,element:(0,R.jsx)(qp,{})}),(0,R.jsx)(Wt,{path:`/oauth/authorize`,element:(0,R.jsx)(yd,{})}),(0,R.jsx)(Wt,{path:`/connect`,element:(0,R.jsx)(Dd,{})}),(0,R.jsx)(Wt,{path:kd,element:(0,R.jsx)(Vd,{children:(0,R.jsx)(_.Suspense,{fallback:null,children:(0,R.jsx)(UC,{})})})}),(0,R.jsx)(Wt,{path:`${kd}/app`,element:(0,R.jsx)(Vd,{children:(0,R.jsx)(_.Suspense,{fallback:null,children:(0,R.jsx)(WC,{})})})}),(0,R.jsx)(Wt,{path:`${kd}/admin`,element:(0,R.jsx)(Vd,{children:(0,R.jsx)(_.Suspense,{fallback:null,children:(0,R.jsx)(KC,{})})})}),(0,R.jsx)(Wt,{path:`${kd}/u/:handle`,element:(0,R.jsx)(Vd,{children:(0,R.jsx)(_.Suspense,{fallback:null,children:(0,R.jsx)(GC,{})})})}),(0,R.jsx)(Wt,{path:`${kd}/privacy`,element:(0,R.jsx)(Vd,{children:(0,R.jsx)(_.Suspense,{fallback:null,children:(0,R.jsx)(qC,{})})})}),(0,R.jsx)(Wt,{path:`${kd}/terms`,element:(0,R.jsx)(Vd,{children:(0,R.jsx)(_.Suspense,{fallback:null,children:(0,R.jsx)(JC,{})})})}),(0,R.jsxs)(Wt,{path:`${kd}/demo`,element:(0,R.jsx)(Vd,{children:(0,R.jsx)(_.Suspense,{fallback:null,children:(0,R.jsx)(YC,{})})}),children:[(0,R.jsx)(Wt,{index:!0,element:(0,R.jsx)(_.Suspense,{fallback:null,children:(0,R.jsx)(XC,{})})}),(0,R.jsx)(Wt,{path:`app`,element:(0,R.jsx)(_.Suspense,{fallback:null,children:(0,R.jsx)(WC,{})})}),(0,R.jsx)(Wt,{path:`admin`,element:(0,R.jsx)(_.Suspense,{fallback:null,children:(0,R.jsx)(KC,{})})}),(0,R.jsx)(Wt,{path:`u/:handle`,element:(0,R.jsx)(_.Suspense,{fallback:null,children:(0,R.jsx)(GC,{})})}),(0,R.jsx)(Wt,{path:`privacy`,element:(0,R.jsx)(_.Suspense,{fallback:null,children:(0,R.jsx)(qC,{})})}),(0,R.jsx)(Wt,{path:`terms`,element:(0,R.jsx)(_.Suspense,{fallback:null,children:(0,R.jsx)(JC,{})})})]}),(0,R.jsx)(Wt,{path:`/demo`,element:(0,R.jsx)($p,{})}),(0,R.jsx)(Wt,{path:`/retro`,element:(0,R.jsx)(im,{})}),(0,R.jsx)(Wt,{path:`/terms`,element:(0,R.jsx)(sm,{})}),(0,R.jsx)(Wt,{path:`/extension`,element:(0,R.jsx)(Jm,{})}),(0,R.jsx)(Wt,{path:`/s/:token`,element:(0,R.jsx)(Bp,{})}),(0,R.jsx)(Wt,{element:(0,R.jsx)(QC,{}),children:(0,R.jsx)(Wt,{path:`/auth`,element:(0,R.jsx)(I_,{})})}),(0,R.jsxs)(Wt,{element:(0,R.jsx)(ZC,{}),children:[(0,R.jsx)(Wt,{element:(0,R.jsx)(ew,{}),children:(0,R.jsx)(Wt,{path:`/onboarding`,element:(0,R.jsx)(q_,{})})}),(0,R.jsxs)(Wt,{element:(0,R.jsx)($C,{}),children:[(0,R.jsx)(Wt,{path:`/today`,element:(0,R.jsx)(C_,{})}),(0,R.jsxs)(Wt,{path:`/app`,element:(0,R.jsx)(Sv,{}),children:[(0,R.jsx)(Wt,{index:!0,element:(0,R.jsx)(Ht,{to:`dashboard`,replace:!0})}),(0,R.jsx)(Wt,{path:`dashboard`,element:(0,R.jsx)(Xv,{})}),(0,R.jsx)(Wt,{path:`momentum`,element:(0,R.jsx)(Ht,{to:`/app/dashboard`,replace:!0})}),(0,R.jsx)(Wt,{path:`patterns`,element:(0,R.jsx)(Ht,{to:`/app/dashboard`,replace:!0})}),(0,R.jsx)(Wt,{path:`goals`,element:(0,R.jsx)(sy,{})}),(0,R.jsx)(Wt,{path:`review`,element:(0,R.jsx)(jy,{})}),(0,R.jsx)(Wt,{path:`streak`,element:(0,R.jsx)(Ky,{})}),(0,R.jsx)(Wt,{path:`chat`,element:(0,R.jsx)(ub,{})}),(0,R.jsx)(Wt,{path:`crew`,element:(0,R.jsx)(pb,{})}),(0,R.jsx)(Wt,{path:`calendar`,element:(0,R.jsx)(Lx,{})}),(0,R.jsx)(Wt,{path:`feedback`,element:(0,R.jsx)(Cx,{})}),(0,R.jsx)(Wt,{path:`settings`,element:(0,R.jsx)(_x,{})})]})]})]}),(0,R.jsx)(Wt,{path:`*`,element:(0,R.jsx)(Ht,{to:`/`,replace:!0})})]})})]})})}Dr();try{let e=new URLSearchParams(window.location.search).get(`join`);e&&localStorage.setItem(`crew.pendingJoin`,e.trim().toUpperCase())}catch{}(0,v.createRoot)(document.getElementById(`root`)).render((0,R.jsx)(_.StrictMode,{children:(0,R.jsxs)(In,{children:[(0,R.jsx)(tw,{}),(0,R.jsx)(vr,{})]})}));export{kd as a,L as c,ut as d,pt as f,c as g,u as h,jd as i,Rn as l,vt as m,zd as n,Od as o,gt as p,Id as r,ol as s,Ld as t,Ut as u};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.