@nightkatana/kronosys-app 1.0.0-beta.37 → 1.0.0-beta.39

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (58) hide show
  1. package/.next/BUILD_ID +1 -1
  2. package/.next/standalone/.next/BUILD_ID +1 -1
  3. package/.next/standalone/.next/build-manifest.json +2 -2
  4. package/.next/standalone/.next/server/app/_global-error/page_client-reference-manifest.js +1 -1
  5. package/.next/standalone/.next/server/app/_global-error.html +1 -1
  6. package/.next/standalone/.next/server/app/_global-error.rsc +1 -1
  7. package/.next/standalone/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
  8. package/.next/standalone/.next/server/app/_global-error.segments/_global-error/__PAGE__.segment.rsc +1 -1
  9. package/.next/standalone/.next/server/app/_global-error.segments/_global-error.segment.rsc +1 -1
  10. package/.next/standalone/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
  11. package/.next/standalone/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
  12. package/.next/standalone/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  13. package/.next/standalone/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
  14. package/.next/standalone/.next/server/app/api/action/route.js +1 -1
  15. package/.next/standalone/.next/server/app/changelog/page_client-reference-manifest.js +1 -1
  16. package/.next/standalone/.next/server/app/guide/page_client-reference-manifest.js +1 -1
  17. package/.next/standalone/.next/server/app/implementation/page_client-reference-manifest.js +1 -1
  18. package/.next/standalone/.next/server/app/licenses/page_client-reference-manifest.js +1 -1
  19. package/.next/standalone/.next/server/app/logs/page_client-reference-manifest.js +1 -1
  20. package/.next/standalone/.next/server/app/page.js +3 -3
  21. package/.next/standalone/.next/server/app/page_client-reference-manifest.js +1 -1
  22. package/.next/standalone/.next/server/app/reporting/page.js +1 -1
  23. package/.next/standalone/.next/server/app/reporting/page_client-reference-manifest.js +1 -1
  24. package/.next/standalone/.next/server/app/settings/page.js +1 -1
  25. package/.next/standalone/.next/server/app/settings/page_client-reference-manifest.js +1 -1
  26. package/.next/standalone/.next/server/chunks/23.js +1 -1
  27. package/.next/standalone/.next/server/chunks/277.js +1 -1
  28. package/.next/standalone/.next/server/chunks/642.js +1 -1
  29. package/.next/standalone/.next/server/chunks/740.js +1 -1
  30. package/.next/standalone/.next/server/chunks/752.js +3 -3
  31. package/.next/standalone/.next/server/middleware-build-manifest.js +1 -1
  32. package/.next/standalone/.next/server/pages/500.html +1 -1
  33. package/.next/standalone/.next/static/chunks/{227-36e1856ef492dee1.js → 227-ac9bbcd07955fca9.js} +1 -1
  34. package/.next/standalone/.next/static/chunks/400-cbb295eb4a4632f3.js +1 -0
  35. package/.next/standalone/.next/static/chunks/569-aafda3bfeb1cb4e5.js +1 -0
  36. package/.next/standalone/.next/static/chunks/702-033cf3571bb1add5.js +3 -0
  37. package/.next/standalone/.next/static/chunks/840-83aa65cc3eee5ac5.js +1 -0
  38. package/.next/standalone/.next/static/chunks/918-30897bc0b3f88e97.js +1 -0
  39. package/.next/standalone/.next/static/chunks/952-4037952633818146.js +1 -0
  40. package/.next/standalone/.next/static/chunks/app/page-74a25ca62ff92f6d.js +25 -0
  41. package/.next/standalone/.next/static/chunks/app/reporting/page-8e6695901d8adc26.js +1 -0
  42. package/.next/standalone/.next/static/chunks/app/settings/page-2881390ef5c8c138.js +1 -0
  43. package/.next/standalone/.next/static/css/2cef87557f7a0efb.css +1 -0
  44. package/.next/standalone/kronosys-package-meta.json +1 -1
  45. package/.next/standalone/package.json +1 -1
  46. package/package.json +1 -1
  47. package/.next/standalone/.next/static/chunks/400-61f952b1ee828fea.js +0 -1
  48. package/.next/standalone/.next/static/chunks/569-87eaac9eac7c21d8.js +0 -1
  49. package/.next/standalone/.next/static/chunks/702-8aac482ad91ed5d5.js +0 -3
  50. package/.next/standalone/.next/static/chunks/840-81defb97b2783f89.js +0 -1
  51. package/.next/standalone/.next/static/chunks/918-6b01bbc7d03b08e7.js +0 -1
  52. package/.next/standalone/.next/static/chunks/952-150a5b20c9255b4a.js +0 -1
  53. package/.next/standalone/.next/static/chunks/app/page-f90f10d17428272f.js +0 -25
  54. package/.next/standalone/.next/static/chunks/app/reporting/page-eb784ca2579dab1f.js +0 -1
  55. package/.next/standalone/.next/static/chunks/app/settings/page-e32584d89b43e548.js +0 -1
  56. package/.next/standalone/.next/static/css/bda87aa373a08430.css +0 -1
  57. /package/.next/standalone/.next/static/{U4YV5CT2J48wEvakHC8wa → 6ttfOnXHYUIE_dlJ927gI}/_buildManifest.js +0 -0
  58. /package/.next/standalone/.next/static/{U4YV5CT2J48wEvakHC8wa → 6ttfOnXHYUIE_dlJ927gI}/_ssgManifest.js +0 -0
@@ -1 +0,0 @@
1
- (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[662],{434:(e,t,a)=>{Promise.resolve().then(a.bind(a,3700))},2047:(e,t,a)=>{"use strict";a.d(t,{BO:()=>n,QF:()=>o,SD:()=>l,TK:()=>r,_U:()=>s,rv:()=>i});let s=30,n=15,r=480;function i(e){let t=e?.taskMinimumDurationMinutes;return Math.min(Math.max(Math.round("number"==typeof t&&Number.isFinite(t)?t:s),n),r)}function l(e){let t=new Date(e),a=t.getMinutes();return t.setMinutes(a<30?0:30,0,0),t}function o(e,t){return e+6e4*t}},2194:(e,t,a)=>{"use strict";a.d(t,{F7:()=>d,I2:()=>o,dM:()=>l});var s=a(5112);let n="dashboardCalendarWeekStartsOn",r={sunday:0,monday:1,saturday:6};function i(e){return"monday"===e||"sunday"===e||"saturday"===e}function l(e){let t=e?.[n];return i(t)?t:"sunday"}function o(e){let t=e?.[n];return i(t)?t:(0,s.EU)()}function d(e){return r[e]}},2725:(e,t,a)=>{"use strict";a.d(t,{p:()=>p});var s=a(5155),n=a(2115),r=a(3321),i=a(8428),l=a(3098),o=a(8646),d=a(6383),c=a(3666),m=a(9137),x=a(3996),u=a(2635);function h(e,t){let a=e?.current,s=e?.historyArchived||[],n=e?(0,x.t)(e.history||[],a):[],r=e?.inspectingSessionId,i=(0,u.k)(t,e,a,n,s),l="ok"===i.mode,o="string"==typeof a?.sessionId?a.sessionId.trim():"",d="ok"===i.mode?i.id.trim():"",c=l&&d!==o?d:"string"==typeof r&&""!==r.trim()?r.trim():null,m=(c?n.find(e=>e.sessionId===c)||s.find(e=>e.sessionId===c):void 0)??a;return{live:a,history:n,historyArchived:s,sessionCurrent:m}}var b=a(3228),g=a(4695);function p({dt:e,lang:t,dashboardSessionNavId:a,onManualRefresh:x,toolbarDomId:u}){let v=(0,r.useRouter)(),{payload:f,refresh:k}=(0,i.y)(),j="string"==typeof a?a.trim():"",y=(0,n.useCallback)(e=>{v.push((0,m.c)("/","string"==typeof e&&""!==e.trim()?e.trim():void 0))},[v]),N=(0,n.useCallback)(async e=>{await (0,l.$)(e),await k({routerInvalidate:!0})},[k]),z=(0,n.useCallback)(async e=>{let{live:t}=h(f,j),a=e===("string"==typeof t?.sessionId?t.sessionId.trim():"");a?(await (0,l.$)({type:"inspectSession",sessionId:null}),await (0,l.$)({type:"setPaused",paused:!1})):await (0,l.$)({type:"inspectSession",sessionId:e}),await k({routerInvalidate:!0}),y(a?null:e)},[j,f,y,k]),w=(0,n.useMemo)(()=>({newSession:()=>{(0,b.IX)(),y(""!==j?j:null)},refresh:()=>void x(),openReporting:()=>void v.push((0,m.c)("/reporting",j||void 0)),openSettings:()=>void v.push((0,m.c)("/settings",j||void 0)),openUserGuide:()=>void v.push((0,m.c)("/guide",j||void 0)),focusSessions:()=>{(0,b.Bj)("sessions"),y(""!==j?j:null)},focusTasks:()=>{(0,b.Bj)("tasks"),y(""!==j?j:null)},focusTags:()=>{(0,b.Bj)("tags"),y(""!==j?j:null)},toggleLang:()=>void N({type:"setLanguage",lang:"fr"===t?"en":"fr"}),toggleFocusMode:()=>{g.Z.getState().toggleFocusMode(),y(""!==j?j:null)}}),[t,j,x,N,y,v]),{history:S,historyArchived:T,sessionCurrent:C,live:D}=(0,n.useMemo)(()=>h(f,j),[j,f]),E=D&&"string"==typeof D.sessionId&&""!==D.sessionId.trim()?{sessionId:D.sessionId.trim(),sessionPaused:!0===D.isPaused}:null,P=(0,n.useMemo)(()=>(0,c.EW)(f?.taskTemplates),[f]),L=(0,n.useMemo)(()=>(0,d.g)({history:S,historyArchived:T,sessionCurrent:C,dt:e,liveSearchContext:E,taskTemplates:P,onSelectTaskTemplate:e=>{(0,b.Ef)(e),(0,b.Bj)("tasks");let t="string"==typeof C?.sessionId?C.sessionId.trim():"string"==typeof D?.sessionId?D.sessionId.trim():""!==j?j:"";y(""!==t?t:null)},onSelectSession:e=>{z(e)},scrollToSession:e=>{(0,b.YG)(e),z(e)},focusTasksColumn:()=>{(0,b.Bj)("tasks"),y(""!==j?j:null)},scrollToTask:e=>{(0,b.Tr)(e),(0,b.Bj)("tasks");let t="string"==typeof C?.sessionId?C.sessionId.trim():"string"==typeof D?.sessionId?D.sessionId.trim():""!==j?j:"";y(""!==t?t:null)}}),[e,S,T,D,E,j,y,z,C,P]);return(0,s.jsx)(o.L,{dt:e,handlers:w,searchItems:L,toolbarDomId:u})}},3030:(e,t,a)=>{"use strict";a.d(t,{n:()=>i});var s=a(5155),n=a(9921),r=a(2115);function i({ariaLabel:e}){let[t,a]=(0,r.useState)(!1);(0,r.useEffect)(()=>{let e=()=>{a(globalThis.scrollY>320)};return e(),globalThis.addEventListener("scroll",e,{passive:!0}),()=>globalThis.removeEventListener("scroll",e)},[]);let l=(0,r.useCallback)(()=>{globalThis.scrollTo({top:0,behavior:"function"==typeof globalThis.matchMedia&&globalThis.matchMedia("(prefers-reduced-motion: reduce)").matches?"auto":"smooth"})},[]);return t?(0,s.jsx)("button",{type:"button",onClick:l,"aria-label":e,className:"fixed bottom-6 right-4 z-40 flex h-11 w-11 items-center justify-center rounded-full border border-zinc-300 bg-white/95 text-zinc-700 shadow-lg shadow-zinc-900/10 backdrop-blur-sm transition-colors hover:border-violet-500/60 hover:bg-violet-50 hover:text-violet-800 focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-violet-500 dark:border-zinc-600 dark:bg-zinc-900/95 dark:text-zinc-200 dark:shadow-black/40 dark:hover:border-violet-500/70 dark:hover:bg-zinc-800 dark:hover:text-violet-100 sm:right-6",children:(0,s.jsx)(n.A,{className:"h-6 w-6",strokeWidth:2.25,"aria-hidden":!0})}):null}},3700:(e,t,a)=>{"use strict";a.r(t),a.d(t,{default:()=>eb});var s=a(5155),n=a(2115),r=a(8500),i=a.n(r),l=a(3321),o=a(3098),d=a(8428),c=a(8090),m=a(4562),x=a(21),u=a(7856);function h({t:e,sync:t,mongoEnabled:a}){if(!a||!t||"disabled"===t.status)return null;let n=null===t.mongoDocumentCount?"—":String(t.mongoDocumentCount),r="aligned"===t.status?e.mongoSyncStatusAligned:"unknown"===t.status?e.mongoSyncStatusUnknown:"localAhead"===t.status?e.mongoSyncStatusLocalAhead:e.mongoSyncStatusMongoAhead,i="aligned"===t.status?"text-emerald-400/90":"text-amber-400/90";return(0,s.jsxs)("div",{className:"mt-1.5 flex flex-wrap items-center gap-x-2 gap-y-1 text-[11px] text-zinc-400",role:"status","aria-live":"polite",children:[(0,s.jsxs)("span",{children:[(0,s.jsxs)("span",{className:"text-zinc-500",children:[e.mongoSyncLocalLabel,":"]})," ",t.localPersistedCount,(0,s.jsx)("span",{className:"mx-1.5 text-zinc-600","aria-hidden":!0,children:"\xb7"}),(0,s.jsxs)("span",{className:"text-zinc-500",children:[e.mongoSyncMongoLabel,":"]})," ",n]}),(0,s.jsx)("span",{className:`font-medium ${i}`,children:r}),(0,s.jsx)(u.p,{ariaLabel:e.mongoSyncHelpAriaLabel,body:e.mongoSyncHelpBody})]})}var b=a(8783),g=a(8578),p=a(9840),v=a(8778),f=a(7634),k=a(2725),j=a(6664),y=a(2094),N=a(6830),z=a(7792),w=a(6032),S=a(1996),T=a(1773),C=a(2194),D=a(1555);let E=["node_modules",".git","dist","out","build",".next","coverage","target","__pycache__",".venv","venv","vendor",".turbo",".cache",".idea"];var P=a(9281),L=a(3030),A=a(1913),M=a(6523),I=a(7262),H=a(2047),R=a(3478),B=a(7650),F=a(4747);let U=["#settings-tour-anchor-intro","#settings-usage-profile","#settings-history","#settings-git","#settings-workspace-loc","#settings-schedule"];function W({open:e,onOpenChange:t,dt:a}){var r;let[i,l]=(0,n.useState)(0),[d,c]=(0,n.useState)(null),[m,x]=(0,n.useState)({}),u=(0,n.useRef)(null),h=(0,n.useRef)(null),b=(0,n.useMemo)(()=>[{title:a.settingsTourStep1Title,body:a.settingsTourStep1Body},{title:a.settingsTourStep2Title,body:a.settingsTourStep2Body},{title:a.settingsTourStep3Title,body:a.settingsTourStep3Body},{title:a.settingsTourStep4Title,body:a.settingsTourStep4Body},{title:a.settingsTourStep5Title,body:a.settingsTourStep5Body},{title:a.settingsTourStep6Title,body:a.settingsTourStep6Body}],[a]),g=b.length,p=i>=g-1,v=b[i]??b[0],f=U[Math.min(i,U.length-1)];(0,n.useEffect)(()=>{e&&l(0)},[e]);let k=(0,n.useCallback)(e=>{(0,o.$)({type:"tourInteraction",tour:"settings_spotlight",action:e,stepIndex:i,stepTotal:g}).catch(()=>void 0),F.r.getState().markSettingsCompleted(),t(!1)},[t,i,g]);r=()=>k("escape"),(0,n.useEffect)(()=>{if(!e)return;let t=e=>{"Escape"===e.key&&(e.preventDefault(),r())};return document.addEventListener("keydown",t),()=>document.removeEventListener("keydown",t)},[e,r]);let j=(0,n.useCallback)(()=>{var t;if(!e)return void c(null);let a=document.querySelector(f);a&&a instanceof HTMLElement?c({top:(t=a.getBoundingClientRect()).top-10,left:t.left-10,width:t.width+20,height:t.height+20}):c(null)},[e,f]);if((0,n.useLayoutEffect)(()=>{if(!e)return void c(null);let t=document.querySelector(f);t instanceof HTMLElement&&t.scrollIntoView({block:"center",inline:"nearest",behavior:"auto"}),j();let a=requestAnimationFrame(j);window.addEventListener("scroll",j,!0),window.addEventListener("resize",j);let s=t instanceof HTMLElement?t:null,n=s&&"u">typeof ResizeObserver?new ResizeObserver(()=>j()):null;return s&&n&&n.observe(s),()=>{cancelAnimationFrame(a),window.removeEventListener("scroll",j,!0),window.removeEventListener("resize",j),n?.disconnect()}},[e,f,i,j]),(0,n.useLayoutEffect)(()=>{if(!e)return;let t=window.innerWidth,a=window.innerHeight,s=Math.min(360,t-24);if(!d)return void x({position:"fixed",top:"50%",left:"50%",transform:"translate(-50%, -50%)",width:s,maxWidth:"calc(100vw - 2rem)",zIndex:212});let n=u.current,r=n?.getBoundingClientRect().height??220,i=d.top+d.height+12;i+r>a-12&&d.top-12-r>=12&&(i=d.top-12-r),i=Math.max(12,Math.min(i,a-r-12));let l=d.left+d.width/2-s/2;x({position:"fixed",top:i,left:l=Math.max(12,Math.min(l,t-s-12)),transform:void 0,width:s,maxWidth:void 0,zIndex:212})},[e,d,i,v.title,v.body]),(0,n.useEffect)(()=>{if(!e)return;let t=window.setTimeout(()=>h.current?.focus(),80);return()=>window.clearTimeout(t)},[e,i]),!e)return null;let y=a.settingsTourProgressLabel.replace("{n}",String(i+1)).replace("{total}",String(g)),N="rounded-lg bg-violet-600 px-4 py-2 text-sm font-medium text-white transition hover:bg-violet-700 focus:outline-none focus:ring-2 focus:ring-violet-500 focus:ring-offset-2 dark:bg-violet-500 dark:hover:bg-violet-600 dark:focus:ring-offset-zinc-900",z=window.innerWidth,w=window.innerHeight,S=d?null:(0,s.jsx)("div",{className:"fixed inset-0 z-[210] bg-black/55","aria-hidden":!0}),T=d&&z>0&&w>0?(()=>{let{top:e,left:t,width:a,height:n}=d,r=Math.max(0,e),i=e+n,l=Math.max(0,w-i),o=Math.max(0,t),c=t+a,m=Math.max(0,z-c);return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("div",{className:"fixed bg-black/55",style:{top:0,left:0,width:z,height:r,zIndex:210},"aria-hidden":!0}),(0,s.jsx)("div",{className:"fixed bg-black/55",style:{top:i,left:0,width:z,height:l,zIndex:210},"aria-hidden":!0}),(0,s.jsx)("div",{className:"fixed bg-black/55",style:{top:e,left:0,width:o,height:n,zIndex:210},"aria-hidden":!0}),(0,s.jsx)("div",{className:"fixed bg-black/55",style:{top:e,left:c,width:m,height:n,zIndex:210},"aria-hidden":!0}),(0,s.jsx)("div",{className:"pointer-events-none fixed rounded-xl border-2 border-violet-500 shadow-[0_0_0_1px_rgba(139,92,246,0.35)] dark:border-violet-400 dark:shadow-[0_0_0_1px_rgba(167,139,250,0.35)]",style:{top:e,left:t,width:a,height:n,zIndex:211},"aria-hidden":!0})]})})():null;return(0,B.createPortal)((0,s.jsxs)(s.Fragment,{children:[S,T,(0,s.jsxs)("div",{ref:u,role:"dialog","aria-modal":"true","aria-labelledby":"settings-tour-title","aria-describedby":"settings-tour-body",className:"rounded-xl border border-zinc-300 bg-white shadow-2xl dark:border-zinc-600 dark:bg-zinc-900",style:m,onMouseDown:e=>e.stopPropagation(),children:[(0,s.jsxs)("div",{className:"border-b border-zinc-200 px-4 py-3 dark:border-zinc-700",children:[(0,s.jsx)("p",{className:"text-xs font-medium uppercase tracking-wide text-violet-600 dark:text-violet-300",children:y}),(0,s.jsx)("h2",{id:"settings-tour-title",className:"mt-1 text-base font-semibold text-zinc-900 dark:text-zinc-100",children:v.title})]}),(0,s.jsx)("div",{id:"settings-tour-body",className:"max-h-[min(42vh,18rem)] overflow-y-auto px-4 py-3",children:(0,s.jsx)("p",{className:"whitespace-pre-wrap text-sm leading-relaxed text-zinc-700 dark:text-zinc-300",children:v.body})}),(0,s.jsxs)("div",{className:"flex flex-wrap items-center justify-between gap-2 border-t border-zinc-200 px-4 py-3 dark:border-zinc-700",children:[(0,s.jsx)("div",{className:"flex gap-1.5",role:"presentation","aria-hidden":!0,children:b.map((e,t)=>(0,s.jsx)("span",{className:`h-2 w-2 rounded-full ${t===i?"bg-violet-500 dark:bg-violet-400":"bg-zinc-300 dark:bg-zinc-600"}`},t))}),(0,s.jsxs)("div",{className:"flex flex-wrap items-center justify-end gap-2",children:[(0,s.jsx)("button",{type:"button",className:"text-sm text-zinc-500 underline-offset-2 hover:text-zinc-800 hover:underline dark:text-zinc-400 dark:hover:text-zinc-200",onClick:()=>k("skip"),children:a.settingsTourSkipBtn}),i>0?(0,s.jsx)("button",{type:"button",className:"rounded-lg border border-zinc-300 bg-white px-4 py-2 text-sm font-medium text-zinc-800 transition hover:bg-zinc-50 dark:border-zinc-600 dark:bg-zinc-800 dark:text-zinc-200 dark:hover:bg-zinc-700",onClick:()=>l(e=>Math.max(0,e-1)),children:a.settingsTourBackBtn}):null,p?(0,s.jsx)("button",{ref:h,type:"button",className:N,onClick:()=>k("done"),children:a.settingsTourDoneBtn}):(0,s.jsx)("button",{ref:h,type:"button",className:N,onClick:()=>l(e=>Math.min(g-1,e+1)),children:a.settingsTourNextBtn})]})]})]})]}),document.body)}var $=a(4548),O=a(3173),q=a(7134),G=a(1909),V=a(3847),_=a(6813),K=a(4514),Z=a(4980);let J=/^([01]?\d|2[0-3]):([0-5]\d)$/;function Y(e){return String(e).padStart(2,"0")}function Q(e){let t=e.trim(),a=J.exec(t);return a?{h:Number(a[1]),m:Number(a[2])}:{h:9,m:0}}function X(e,t){return`${Y((e%24+24)%24)}:${Y((t%60+60)%60)}`}function ee({value:e,onChange:t,disabled:a,className:r="","aria-label":i,lang:l,use24HourClock:o=!0,t:d}){let c,[m,x]=(0,n.useState)(!1),[u,h]=(0,n.useState)({top:0,left:0,maxW:280}),b=(0,n.useRef)(null),g=(0,n.useRef)(null),p=Q(e),[v,f]=(0,n.useState)(p.h),[k,j]=(0,n.useState)(p.m);(0,n.useEffect)(()=>{let{h:t,m:a}=Q(e);f(t),j(a)},[e]);let y=(0,n.useCallback)((e,a)=>{t(X(e,a))},[t]),N=X(v,k),z=((c=new Date).setHours(v,k,0,0),new Intl.DateTimeFormat("fr"===l?"fr-CA":"en-CA",{timeStyle:"short",hour12:!o}).format(c)),w=(0,n.useCallback)(()=>{let e=b.current;if(!e)return;let t=e.getBoundingClientRect(),a=window.innerWidth,s=window.innerHeight,n=Math.min(280,a-16),r=t.bottom+8,i=t.left+t.width/2-n/2;i=Math.max(8,Math.min(i,a-n-8)),r+200>s-8&&(r=Math.max(8,t.top-8-200)),h({top:r,left:i,maxW:n})},[]);(0,n.useLayoutEffect)(()=>{if(!m||a)return;w();let e=()=>w();return window.addEventListener("resize",e),window.addEventListener("scroll",e,!0),()=>{window.removeEventListener("resize",e),window.removeEventListener("scroll",e,!0)}},[m,a,w]),(0,n.useEffect)(()=>{if(!m||a)return;let e=e=>{let t=e.target;g.current?.contains(t)||b.current?.contains(t)||x(!1)},t=e=>{"Escape"===e.key&&x(!1)};return document.addEventListener("mousedown",e),document.addEventListener("keydown",t),()=>{document.removeEventListener("mousedown",e),document.removeEventListener("keydown",t)}},[m,a]);let S=Array.from({length:24},(e,t)=>t),T=Array.from({length:60},(e,t)=>t),C=m&&!a&&"u">typeof document?(0,B.createPortal)((0,s.jsxs)("div",{ref:g,role:"dialog","aria-modal":"true","aria-label":i,className:"kronosys-time-popover fixed z-[200] rounded-xl border border-violet-500/45 bg-zinc-50 p-3 shadow-2xl dark:border-violet-400/45 dark:bg-zinc-900",style:{top:u.top,left:u.left,width:u.maxW,maxHeight:200},children:[(0,s.jsxs)("div",{className:"flex flex-wrap items-center justify-center gap-2",children:[(0,s.jsx)("span",{className:"text-xs font-medium text-zinc-600 dark:text-zinc-400",children:d.timePickerPopoverTimeLabel}),(0,s.jsxs)("div",{className:"inline-flex items-center gap-1.5",children:[(0,s.jsx)("select",{className:"h-9 rounded-lg border border-violet-500/45 bg-white px-2.5 text-sm font-mono text-zinc-900 outline-none dark:border-violet-400/50 dark:bg-zinc-800 dark:text-zinc-100",value:v,onChange:e=>{let t=Number(e.target.value);f(t),y(t,k)},"aria-label":d.timePickerPopoverHourAria,children:S.map(e=>(0,s.jsx)("option",{value:e,children:Y(e)},e))}),(0,s.jsx)("span",{className:"font-mono text-zinc-500",children:":"}),(0,s.jsx)("select",{className:"h-9 rounded-lg border border-violet-500/45 bg-white px-2.5 text-sm font-mono text-zinc-900 outline-none dark:border-violet-400/50 dark:bg-zinc-800 dark:text-zinc-100",value:k,onChange:e=>{let t=Number(e.target.value);j(t),y(v,t)},"aria-label":d.timePickerPopoverMinuteAria,children:T.map(e=>(0,s.jsx)("option",{value:e,children:Y(e)},e))})]}),(0,s.jsx)("button",{type:"button",className:"inline-flex h-9 w-9 items-center justify-center rounded-lg border border-emerald-500/50 bg-emerald-50 text-emerald-700 hover:bg-emerald-100 dark:border-emerald-400/60 dark:bg-emerald-950/35 dark:text-emerald-200 dark:hover:bg-emerald-900/40","aria-label":"fr"===l?"Accepter l'heure":"Accept time",onClick:()=>{y(v,k),x(!1)},children:(0,s.jsx)(K.A,{className:"h-4 w-4",strokeWidth:2.5,"aria-hidden":!0})})]}),(0,s.jsxs)("p",{className:"mt-2 text-center text-xs text-zinc-500 dark:text-zinc-400","aria-hidden":!0,children:[N," \xb7 ",z]})]}),document.body):null;return(0,s.jsxs)("div",{className:`inline-flex min-w-0 max-w-full ${r}`,children:[(0,s.jsxs)("button",{ref:b,type:"button",disabled:a,className:"inline-flex w-full max-w-md items-center justify-between gap-2 rounded-lg border border-zinc-300 bg-white px-3 py-2 text-left text-sm outline-none ring-violet-500/30 focus:ring-2 dark:border-zinc-700 dark:bg-zinc-950 "+(a?"cursor-not-allowed opacity-50":"cursor-pointer hover:border-zinc-400 dark:hover:border-zinc-600"),"aria-label":i,"aria-expanded":m,"aria-haspopup":"dialog",onClick:()=>{a||x(e=>!e)},children:[(0,s.jsx)("span",{className:"min-w-0 flex-1 truncate font-mono text-sm tabular-nums text-zinc-900 dark:text-zinc-100",children:N}),(0,s.jsx)(Z.A,{className:"h-4 w-4 shrink-0 opacity-70",strokeWidth:2,"aria-hidden":!0})]}),C]})}var et=a(1878),ea=a(8368),es=a(9137);function en(e,t){return"qa"===e?t.dataEnvActiveQa:t.dataEnvActiveProduction}function er(e,t){return e.replace(/\{(\w+)\}/g,(e,a)=>t[a]??`{${a}}`)}function ei(e){let t,a,s=(e,t)=>"number"==typeof e&&Number.isFinite(e)?e:t,n=(e,t)=>"boolean"==typeof e?e:t,r=(e,t)=>"string"==typeof e?e:t,i=r(e?.historyPartition,"daily"),l=["daily","weekly","monthly"].includes(i)?i:"daily",o=r(e?.sessionExportFormat,"json"),d=["json","csv","jiraTable","sap"].includes(o)?o:"json",c=r(e?.sessionStartMode,"continue"),m=["continue","new"].includes(c)?c:"continue",x=r(e?.usageProfile,"manager"),u=Array.isArray(t=e?.workspaceLocExcludedDirectoryNames)?t.map(e=>String(e).trim()).filter(Boolean).join("\n"):[...E].join("\n"),h=Array.isArray(a=e?.workspaceLocExcludedPathPatterns)?a.map(e=>String(e).trim()).filter(Boolean).join("\n"):"",b=e?.scheduleDays,g=Array.isArray(b)?b.filter(e=>"number"==typeof e):[1,2,3,4,5],p=(Array.isArray(e?.plannedSessions)?e.plannedSessions:[]).map(e=>{let t="object"==typeof e&&null!==e?e:{};return{id:r(t.id,Math.random().toString(36).slice(2,11)),name:r(t.name,""),days:Array.isArray(t.days)?t.days.filter(e=>"number"==typeof e):[],startTime:r(t.startTime,"10:00"),endTime:r(t.endTime,"11:00"),createSession:n(t.createSession,!0),transferTasks:n(t.transferTasks,!0),pauseTasks:n(t.pauseTasks,!0),tagsText:Array.isArray(t.tags)?t.tags.join(", "):"",project:r(t.project,"")}});return{usageProfile:"developer"===x?"developer":"manager",enabled:n(e?.enabled,!0),autoStart:n(e?.autoStart,!0),showWelcomeOnStartup:n(e?.showWelcomeOnStartup,!0),anonymizePaths:n(e?.anonymizePaths,!1),flushIntervalSeconds:s(e?.flushIntervalSeconds,15),heartbeatIntervalSeconds:s(e?.heartbeatIntervalSeconds,120),maxBufferedEvents:s(e?.maxBufferedEvents,500),historyStoragePath:r(e?.historyStoragePath,""),localPersistenceDriver:"json"===r(e?.localPersistenceDriver,"sqlite")?"json":"sqlite",historyPartition:l,sessionExportFormat:d,csvDelimiter:r(e?.csvDelimiter,","),sessionStartMode:m,autoGitSync:n(e?.autoGitSync,!1),gitRemoteUrl:r(e?.gitRemoteUrl,""),gitlabApiBaseUrl:r(e?.gitlabApiBaseUrl,""),mongodbEnabled:n(e?.mongodbEnabled,!1),mongodbDatabaseName:r(e?.mongodbDatabaseName,"kronosys"),mongodbCollectionName:r(e?.mongodbCollectionName,"sessions"),mongodbHost:r(e?.mongodbHost,"127.0.0.1"),mongodbPort:s(e?.mongodbPort,27017),mongodbUsername:r(e?.mongodbUsername,""),mongodbAuthSource:r(e?.mongodbAuthSource,"admin"),localApiPort:s(e?.localApiPort,5566),dashboardWebUrl:r(e?.dashboardWebUrl,"http://kronosys:5555"),dashboardDisplayTimeZone:(0,D.g8)(e),dashboardUse24HourClock:(0,T.m)(e),dashboardCalendarWeekStartsOn:(0,C.dM)(e),dashboardLightThemeVariant:(0,q.bb)(e)??q.dO,dashboardSemanticChipAccessibleMode:n(e?.dashboardSemanticChipAccessibleMode,!1),dashboardDefaultSessionNameTemplate:r(e?.dashboardDefaultSessionNameTemplate,"").slice(0,400),dashboardSessionDurationAlertHours:Math.min(Math.max(s(e?.dashboardSessionDurationAlertHours,24),1),8760),dashboardShowKronoFocusInHeader:n(e?.dashboardShowKronoFocusInHeader,!0),dashboardShowKronoFocusInTaskOps:n(e?.dashboardShowKronoFocusInTaskOps,!0),taskDefaultTagBucketEnabled:n(e?.taskDefaultTagBucketEnabled,!0),taskStripDefaultTagWhenExplicitTags:n(e?.taskStripDefaultTagWhenExplicitTags,!0),taskMinimumDurationMinutes:Math.min(Math.max(s(e?.taskMinimumDurationMinutes,H._U),H.BO),H.TK),dashboardAllowTaskStartTimeEdit:n(e?.dashboardAllowTaskStartTimeEdit,!0),dashboardAllowSessionStartTimeEdit:n(e?.dashboardAllowSessionStartTimeEdit,!0),dashboardAllowTaskEndTimeEdit:n(e?.dashboardAllowTaskEndTimeEdit,!0),dashboardAllowSessionEndTimeEdit:n(e?.dashboardAllowSessionEndTimeEdit,!0),developmentUseProductionData:n(e?.developmentUseProductionData,!1),dualDataEnvironmentEnabled:n(e?.dualDataEnvironmentEnabled,!1),activeDataEnvironment:e?.activeDataEnvironment==="qa"?"qa":"production",workspaceLocExcludedDirsText:u,workspaceLocExcludedPathPatternsText:h,scheduleEnabled:n(e?.scheduleEnabled,!1),scheduleDays:g,scheduleStartTime:r(e?.scheduleStartTime,"09:00"),scheduleEndTime:r(e?.scheduleEndTime,"17:00"),scheduleCreateDailySession:n(e?.scheduleCreateDailySession,!0),scheduleTransferTasks:n(e?.scheduleTransferTasks,!0),schedulePauseTasks:n(e?.schedulePauseTasks,!0),plannedSessions:p}}function el(e){return`w-full max-w-md rounded-lg border border-zinc-300 bg-white px-3 py-2 text-sm text-zinc-900 outline-none ring-violet-500/30 focus:ring-2 dark:border-zinc-700 dark:bg-zinc-950 dark:text-zinc-100 ${e?"opacity-50":""}`}function eo(e){return`w-full max-w-xl min-h-[9rem] rounded-lg border border-zinc-300 bg-white px-3 py-2 font-mono text-xs leading-relaxed text-zinc-900 outline-none ring-violet-500/30 focus:ring-2 dark:border-zinc-700 dark:bg-zinc-950 dark:text-zinc-100 ${e?"opacity-50":""}`}function ed({label:e,description:t,children:a}){let r=(0,n.useId)(),i=`${r}-label`,l=`${r}-desc`;return(0,s.jsxs)("div",{role:"group","aria-labelledby":i,"aria-describedby":l,className:"flex flex-col gap-1.5 sm:flex-row sm:items-start sm:gap-6",children:[(0,s.jsxs)("div",{className:"min-w-0 shrink-0 sm:w-52",children:[(0,s.jsx)("div",{id:i,className:"text-sm font-medium text-zinc-800 dark:text-zinc-200",children:e}),(0,s.jsx)("p",{id:l,className:"mt-0.5 text-xs leading-snug text-zinc-600 dark:text-zinc-500",children:t})]}),(0,s.jsx)("div",{className:"min-w-0 flex-1",children:a})]})}function ec({checked:e,onChange:t,disabled:a,ariaLabel:n}){return(0,s.jsx)("button",{type:"button",role:"switch","aria-checked":e?"true":"false","aria-label":n,disabled:a,className:`relative h-7 w-12 shrink-0 rounded-full transition ${e?"bg-violet-600":"bg-zinc-700"} ${a?"opacity-50":""}`,onClick:()=>t(!e),children:(0,s.jsx)("span",{className:`absolute top-0.5 left-0.5 h-6 w-6 rounded-full bg-white transition ${e?"translate-x-5":"translate-x-0"}`})})}function em({checked:e,onChange:t,disabled:a,ariaLabel:n}){return(0,s.jsx)("input",{type:"checkbox",checked:e,disabled:a,onChange:e=>t(e.target.checked),"aria-label":n,className:`h-4 w-4 shrink-0 rounded border border-zinc-400 bg-white text-violet-600 accent-violet-600 focus:outline-none focus-visible:ring-2 focus-visible:ring-violet-500/70 focus-visible:ring-offset-2 focus-visible:ring-offset-white dark:border-zinc-600 dark:bg-zinc-950 dark:focus-visible:ring-offset-zinc-950 ${a?"cursor-not-allowed opacity-50":"cursor-pointer"}`})}let ex="scroll-mt-24 space-y-6 border-b border-zinc-200 pb-10 last:border-b-0 last:pb-4 dark:border-zinc-800";function eu({s:e,filter:t,showDevDataInGeneral:a}){let n="rounded text-zinc-700 underline-offset-2 hover:text-violet-700 hover:underline focus:outline-none focus-visible:ring-2 focus-visible:ring-violet-500/80 focus-visible:ring-offset-2 focus-visible:ring-offset-white dark:text-zinc-300 dark:hover:text-violet-300 dark:focus-visible:ring-offset-zinc-950",r=(...e)=>(function(e,...t){let a=e.trim().toLowerCase();return!a||t.join(" ").toLowerCase().includes(a)})(t,...e),l=r(e.sectionUsageProfile,"settings-usage-profile"),o=r(e.sectionGeneral,"settings-general","g\xe9n\xe9ral","general","v4","v4-dev","next","dev","sqlite","donn\xe9es","data","d\xe9veloppement","development"),d=r(e.sectionSchedule,"settings-schedule","schedule","horaire","travail","weekday","automatique"),c=r(e.sectionPlannedSessions,"settings-planned-sessions","planned","planifi","r\xe9current","recurring"),m=r(e.sectionPrivacy,"settings-privacy"),x=r(e.sectionKronoFocus,"settings-kronoFocus","kronoFocus"),u=r(e.sectionTaskTags,"settings-task-tags","task","tag","\xe9tiquette","default","d\xe9faut","bucket"),h=r(e.sectionCollection,"settings-collection","buffer"),b=r(e.sectionHistory,"settings-history"),g=r(e.sectionTagsProjects,"settings-tags-projects")||r(e.tocSubTagsGlobal,"settings-tags-global"),p=r(e.sectionTagsProjects,"settings-tags-projects")||r(e.tocSubTagsProjects,"settings-tags-saved-projects"),v=r(e.sectionTagsProjects,"settings-tags-projects")||r(e.tocSubTagsByProject,"settings-tags-by-project"),f=g||p||v,k=r(e.sectionTaskTemplates,"settings-task-templates","template","mod\xe8le","task template","gabarit"),j=r(e.sectionDangerZone,"settings-danger-zone"),y=r(e.sectionArchivedSessions,"settings-archived-sessions","archived"),N=r(e.sectionExport,"settings-export"),z=r(e.sectionGit,"settings-git","gitlab")||r(e.tocSubGitIdentity,"settings-git-identity","author","identity","forge"),w=r(e.sectionMongo,"settings-mongo","mongodb")||r(e.sectionMongoConnection,"settings-mongo-connection"),S=r(e.sectionWorkspaceLoc,"settings-workspace-loc","snapshot","reporting"),T=r(e.sectionWeb,"settings-web","dashboard","api")||r(e.tocSubDashboardTour,"settings-dashboard-tour")||r(e.tocSubReportingTour,"settings-reporting-tour")||r(e.tocSubDashboardColumnHints,"settings-dashboard-column-hints","column","colonnes","three","trois")||r(e.dashboardDisplayTimeZone,"fuseau","timezone","time zone","iana","horaire")||r(e.dashboardClockFormat,"12h","12 h","24h","24 h","am/pm","horloge","clock format","heure"),C=r(e.sectionWeb,"settings-web","dashboard","api")||r(e.tocSubSessionDurationAlert,"settings-session-duration-alert","duration"),D=r(e.sectionWeb,"settings-web","dashboard","api")||r(e.tocSubDefaultSessionNameTemplate,"settings-default-session-name","default session","session name","%UUID","strftime","gabarit","nom de session")||r(e.dashboardDefaultSessionNameTemplate,"template","uuid"),E=T||C||D,P=r(e.licensesPageLink,"/licenses","license","licence","third-party","notices","logiciels"),L=l||o||d||c||m||x||u||h||b||f||k||j||y||N||z||w||S||E||P,A="mt-1.5 ml-2 space-y-1 border-l border-zinc-700 pl-3 dark:border-zinc-600";return(0,s.jsxs)("nav",{"aria-label":e.tocNavAriaLabel,className:"rounded-xl border border-zinc-200 bg-zinc-50/90 p-4 lg:max-h-[calc(100dvh-14rem)] lg:overflow-y-scroll lg:overscroll-contain dark:border-zinc-800 dark:bg-zinc-900/40",children:[(0,s.jsx)("p",{className:"mb-3 text-xs font-semibold uppercase tracking-wide text-zinc-500 dark:text-zinc-500",children:e.tocHeading}),t.trim()&&!L?(0,s.jsx)("p",{className:"text-sm text-zinc-600 dark:text-zinc-400",role:"status",children:e.tocSearchNoResults}):(0,s.jsxs)("ul",{className:"space-y-2 text-sm",children:[l?(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-usage-profile",className:n,children:e.sectionUsageProfile})}):null,o?(0,s.jsxs)("li",{children:[(0,s.jsx)("a",{href:"#settings-general",className:n,children:e.sectionGeneral}),a?(0,s.jsx)("ul",{className:A,children:(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-dev-data",className:n,children:e.devDataBlockTitle})})}):null]}):null,d?(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-schedule",className:n,children:e.sectionSchedule})}):null,c?(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-planned-sessions",className:n,children:e.sectionPlannedSessions})}):null,m?(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-privacy",className:n,children:e.sectionPrivacy})}):null,x?(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-kronoFocus",className:n,children:e.sectionKronoFocus})}):null,u?(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-task-tags",className:n,children:e.sectionTaskTags})}):null,h?(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-collection",className:n,children:e.sectionCollection})}):null,b?(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-history",className:n,children:e.sectionHistory})}):null,N?(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-export",className:n,children:e.sectionExport})}):null,f?(0,s.jsxs)("li",{children:[(0,s.jsx)("a",{href:"#settings-tags-projects",className:n,children:e.sectionTagsProjects}),g||p||v?(0,s.jsxs)("ul",{className:A,children:[g?(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-tags-global",className:n,children:e.tocSubTagsGlobal})}):null,p?(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-tags-saved-projects",className:n,children:e.tocSubTagsProjects})}):null,v?(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-tags-by-project",className:n,children:e.tocSubTagsByProject})}):null]}):null]}):null,k?(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-task-templates",className:n,children:e.sectionTaskTemplates})}):null,z?(0,s.jsxs)("li",{children:[(0,s.jsx)("a",{href:"#settings-git",className:n,children:e.sectionGit}),(0,s.jsx)("ul",{className:"mt-1.5 ml-2 space-y-1 border-l border-zinc-700 pl-3",children:(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-git-identity",className:n,children:e.tocSubGitIdentity})})})]}):null,w?(0,s.jsxs)("li",{children:[(0,s.jsx)("a",{href:"#settings-mongo",className:n,children:e.sectionMongo}),w?(0,s.jsx)("ul",{className:"mt-1.5 ml-2 space-y-1 border-l border-zinc-700 pl-3",children:(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-mongo-connection",className:n,children:e.sectionMongoConnection})})}):null]}):null,S?(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-workspace-loc",className:n,children:e.sectionWorkspaceLoc})}):null,E?(0,s.jsxs)("li",{children:[(0,s.jsx)("a",{href:"#settings-web",className:n,children:e.sectionWeb}),T||C||D?(0,s.jsxs)("ul",{className:A,children:[T?(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-dashboard-tour",className:n,children:e.tocSubDashboardTour})}),(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-dashboard-column-hints",className:n,children:e.tocSubDashboardColumnHints})}),(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-reporting-tour",className:n,children:e.tocSubReportingTour})})]}):null,D?(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-default-session-name",className:n,children:e.tocSubDefaultSessionNameTemplate})}):null,C?(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-session-duration-alert",className:n,children:e.tocSubSessionDurationAlert})}):null]}):null]}):null,y?(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-archived-sessions",className:n,children:e.sectionArchivedSessions})}):null,j?(0,s.jsx)("li",{children:(0,s.jsx)("a",{href:"#settings-danger-zone",className:n,children:e.sectionDangerZone})}):null,P?(0,s.jsx)("li",{children:(0,s.jsx)(i(),{href:"/licenses",className:n,children:e.licensesPageLink})}):null]})]})}function eh(){let e=(0,n.useId)(),t=(0,n.useId)(),{payload:a,error:r,refresh:u,getLatestPayload:T,connectionPhase:C}=(0,d.y)(),[E,B]=(0,n.useState)(!1),[U,K]=(0,n.useState)(null),[Z,J]=(0,n.useState)(!1),[Y,Q]=(0,n.useState)(null),[X,eh]=(0,n.useState)(!1),[eb,eg]=(0,n.useState)(!1),[ep,ev]=(0,n.useState)(""),[ef,ek]=(0,n.useState)(!1),[ej,ey]=(0,n.useState)(""),[eN,ez]=(0,n.useState)(!1),[ew,eS]=(0,n.useState)(!1),[eT,eC]=(0,n.useState)(!1),[eD,eE]=(0,n.useState)(""),[eP,eL]=(0,n.useState)(!1),[eA,eM]=(0,n.useState)(!1),[eI,eH]=(0,n.useState)(null),[eR,eB]=(0,n.useState)(""),[eF,eU]=(0,n.useState)(""),[eW,e$]=(0,n.useState)(""),[eO,eq]=(0,n.useState)(!1),[eG,eV]=(0,n.useState)(!1),[e_,eK]=(0,n.useState)(!1),[eZ,eJ]=(0,n.useState)(null),[eY,eQ]=(0,n.useState)(!1),[eX,e0]=(0,n.useState)(null),[e5,e2]=(0,n.useState)(!1),[e1,e4]=(0,n.useState)(0),[e3,e6]=(0,n.useState)(null),[e8,e9]=(0,n.useState)(!1),[e7,te]=(0,n.useState)(!1),[tt,ta]=(0,n.useState)(!1),[ts,tn]=(0,n.useState)(!1),[tr,ti]=(0,n.useState)(null),tl=(0,n.useRef)(null),[to,td]=(0,n.useState)(""),[tc,tm]=(0,n.useState)(!1);(0,n.useEffect)(()=>{a&&!F.r.getState().settings&&tm(!0)},[a]);let tx=(0,l.useRouter)(),tu=(0,l.useSearchParams)().get("session"),th=(0,n.useCallback)(async e=>{let t=await u({routerInvalidate:e?.routerInvalidate===!0,resetBootstrapFailures:e?.resetBootstrapFailures===!0});if(t&&e?.preserveForm!==!0){let e=T();e&&K(ei(e.cfg))}return t},[T,u]),tb=(0,n.useRef)(!1);(0,n.useEffect)(()=>{a&&!tb.current&&(tb.current=!0,K(ei(a.cfg)))},[a]),(0,n.useEffect)(()=>{if(eO)return;let e=a?.gitIdentity;eB("string"==typeof e?.gitUserName?e.gitUserName:""),eU("string"==typeof e?.gitUserEmail?e.gitUserEmail:""),e$("string"==typeof e?.gitAccountLogin?e.gitAccountLogin:"")},[a?.gitIdentity,eO]);let tg=(0,n.useCallback)(async()=>{eq(!0);try{await (0,o.$)({type:"setGitIdentity",gitUserName:eR,gitUserEmail:eF,gitAccountLogin:eW}),await th({preserveForm:!0}),eV(!0),window.setTimeout(()=>eV(!1),3500)}catch(e){e0(e instanceof Error?e.message:String(e))}finally{eq(!1)}},[eF,eW,eR,th]),tp=a?.current,tv=tp?.language==="fr"?"fr":"en",tf=(0,g.C)(tv),tk=(0,p.J)(tv),tj=a?.devDataRuntime,ty=a?.dataEnvironmentRuntime,tN=tj?.isNextDevelopment===!0,tz=Z||eb,tw=(0,x.z)(tv),tS=(0,n.useCallback)(async()=>await th({routerInvalidate:!0,preserveForm:!0}),[th]),tT=(0,n.useCallback)(async e=>{await (0,o.$)(e),await th({routerInvalidate:!0,preserveForm:!0})},[th]),tC=(0,n.useCallback)(()=>{_.P.getState().reset(),eK(!0),window.setTimeout(()=>eK(!1),3500)},[]),tD=(0,n.useMemo)(()=>(function(e,t,a,s){let n=a?.traceDataDirOverride===!0?a.activeDataDirectory:s?.traceDataDirOverride===!0?s.activeDataDirectory:null;if(n)return{title:t.dangerClearHistoryVaultTargetTitle,environmentLabel:"TRACE_DATA_DIR",body:er(t.dangerClearHistoryVaultTargetTrace,{path:n}),dataDirectory:n,mismatchWarning:null,accent:"neutral"};let r=a?.dualDataEnvironmentEnabled===!0,i=a?.activeDataDirectory?.trim()||s?.activeDataDirectory?.trim()||"",l=a?.effectiveActiveDataEnvironment==="qa"?"qa":"production";if(r&&a){let e=en(l,t),s="qa"===l?en("production",t):en("qa",t),n="qa"===l?a.productionDataDirectory:a.qaDataDirectory,r=!0===a.dataDirectoryResolutionMismatch?er(t.dangerClearHistoryVaultMismatch,{preferredEnv:en(a.preferredActiveDataEnvironment,t),preferredPath:a.preferredDataDirectory,activePath:a.activeDataDirectory}):null;return{title:t.dangerClearHistoryVaultTargetTitle,environmentLabel:e,body:er(t.dangerClearHistoryVaultTargetDual,{env:e,path:a.activeDataDirectory,otherEnv:s,otherPath:n}),dataDirectory:i,mismatchWarning:r,accent:"qa"===l?"qa":"production"}}if(s?.isNextDevelopment===!0&&!r){let a=!0===s.dataDirectoryResolutionMismatch?er(t.dangerClearHistoryVaultMismatch,{preferredEnv:"fr"===e?"pr\xe9f\xe9rence enregistr\xe9e":"saved preference",preferredPath:s.preferredDataDirectory,activePath:s.activeDataDirectory}):null;return{title:t.dangerClearHistoryVaultTargetTitle,environmentLabel:"fr"===e?"D\xe9veloppement (next dev)":"Development (next dev)",body:er(t.dangerClearHistoryVaultTargetDev,{path:s.activeDataDirectory}),dataDirectory:s.activeDataDirectory,mismatchWarning:a,accent:"neutral"}}let o=a?.dataDirectoryResolutionMismatch===!0?er(t.dangerClearHistoryVaultMismatch,{preferredEnv:en(a.preferredActiveDataEnvironment,t),preferredPath:a.preferredDataDirectory,activePath:a.activeDataDirectory}):null;return{title:t.dangerClearHistoryVaultTargetTitle,environmentLabel:en(l,t),body:er(t.dangerClearHistoryVaultTargetSingle,{path:i||(a?.activeDataDirectory??"")}),dataDirectory:i||(a?.activeDataDirectory??""),mismatchWarning:o,accent:"qa"===l?"qa":"production"}})(tv,tk,ty,tj),[tv,tk,ty,tj]),tE=(0,n.useMemo)(()=>{let e="qa"===tD.accent?"border-violet-400/70 bg-violet-50/95 text-violet-950 dark:border-violet-600/50 dark:bg-violet-950/40 dark:text-violet-100":"production"===tD.accent?"border-zinc-300 bg-zinc-50/95 text-zinc-900 dark:border-zinc-600 dark:bg-zinc-900/55 dark:text-zinc-100":"border-zinc-200 bg-zinc-50/90 text-zinc-800 dark:border-zinc-600 dark:bg-zinc-900/50 dark:text-zinc-200";return(0,s.jsxs)("div",{className:`space-y-3 ${e7?"pointer-events-none opacity-50":""}`,children:[(0,s.jsxs)("div",{className:`rounded-lg border p-3 ${e}`,role:"note",children:[(0,s.jsx)("p",{className:"text-xs font-semibold uppercase tracking-wide",children:tD.title}),(0,s.jsx)("p",{className:"mt-1.5 text-sm font-medium leading-snug",children:tD.environmentLabel}),(0,s.jsx)("p",{className:"mt-1 text-xs leading-relaxed",children:tD.body}),tD.mismatchWarning?(0,s.jsx)("p",{className:"mt-2 text-xs leading-relaxed text-amber-900 dark:text-amber-200",children:tD.mismatchWarning}):null]}),(0,s.jsxs)("div",{className:"rounded-lg border border-zinc-200 bg-zinc-50/90 p-3 text-zinc-800 dark:border-zinc-600 dark:bg-zinc-900/50 dark:text-zinc-200",children:[(0,s.jsx)("p",{className:"text-xs font-medium leading-snug",children:tk.dangerClearHistoryBackupIntro}),(0,s.jsxs)("ul",{className:"mt-2 space-y-2.5 text-sm",children:[(0,s.jsxs)("li",{children:[(0,s.jsx)("a",{href:"/api/backup?format=json",download:!0,className:"font-medium text-violet-700 underline decoration-violet-400 underline-offset-2 hover:text-violet-600 dark:text-violet-300 dark:hover:text-violet-200",children:tk.dangerClearHistoryBackupJson}),(0,s.jsx)("p",{className:"mt-0.5 text-[11px] leading-relaxed text-zinc-500 dark:text-zinc-400",children:tk.dangerClearHistoryBackupJsonHint})]}),(0,s.jsxs)("li",{children:[(0,s.jsx)("a",{href:"/api/backup?format=csv",download:!0,className:"font-medium text-violet-700 underline decoration-violet-400 underline-offset-2 hover:text-violet-600 dark:text-violet-300 dark:hover:text-violet-200",children:tk.dangerClearHistoryBackupCsvZip}),(0,s.jsx)("p",{className:"mt-0.5 text-[11px] leading-relaxed text-zinc-500 dark:text-zinc-400",children:tk.dangerClearHistoryBackupCsvZipHint})]}),(0,s.jsxs)("li",{children:[(0,s.jsx)("a",{href:"/api/backup?format=sqlite",download:!0,className:"font-medium text-violet-700 underline decoration-violet-400 underline-offset-2 hover:text-violet-600 dark:text-violet-300 dark:hover:text-violet-200",children:tk.dangerClearHistoryBackupSqlite}),(0,s.jsx)("p",{className:"mt-0.5 text-[11px] leading-relaxed text-zinc-500 dark:text-zinc-400",children:tk.dangerClearHistoryBackupSqliteHint})]})]})]})]})},[tD,tk,e7]),tP=(0,n.useMemo)(()=>[...a?.historyArchived||[]].sort((e,t)=>{let a=Date.parse(e.savedAt||e.startAt||"")||0;return(Date.parse(t.savedAt||t.startAt||"")||0)-a}),[a?.historyArchived]),tL=tP.length,tA=Math.max(0,Math.ceil(tL/10)-1),tM=Math.min(e1,tA),tI=10*tM,tH=tP.slice(tI,tI+10),tR=0===tL?0:Math.min(tI+tH.length,tL);(0,n.useEffect)(()=>{e4(e=>Math.min(e,tA))},[tA]),(0,n.useEffect)(()=>{if(!U||!a||"#settings-archived-sessions"!==window.location.hash)return;let e=document.getElementById("settings-archived-sessions");if(!e)return;let t=window.setTimeout(()=>{e.scrollIntoView({behavior:"smooth",block:"start"})},80);return()=>window.clearTimeout(t)},[U,a]);let tB=a?.cfg,tF=tB?.mongodbUriConfigured===!0,tU=tB?.mongodbManualUriConfigured===!0,tW=tB?.mongodbPasswordConfigured===!0,t$=a?.remoteStatus,tO=tB?.mongodbEnabled===!0,tq=(0,n.useMemo)(()=>{let e=(0,w.Vc)(a);if(e.length>0)return e;let t=a?.cfg,s=(0,w.Vc)(t);if(s.length>0)return s;let n=a?.workspaceCodeSnapshot;if(n?.ok===!0){let e=n.workspaceFolder?.trim();if(e)return[e]}return[]},[a]),tG=(0,S.Me)(a,tq.length),tV=tB?.suggestGlabRemoteRepo===!0,t_=tB?.gitlabTokenStored===!0,tK=tB?.gitlabTokenFromEnv===!0,tZ=tB?.gitlabApiVerified===!0,tJ=eD.trim().length>0||tK,tY=t_?tk.gitlabTokenStoredYes:tK?tk.gitlabTokenFromEnvYes:tk.gitlabTokenNone,tQ=async e=>{await (0,o.$)({type:"setLanguage",lang:e}),await th()},tX=async()=>{if(U){J(!0),Q(null);try{let e=ep.trim();if(e.length>0){let t=await (0,o.$)({type:"setMongoDbConnectionUri",uri:e}),a=t.result?.settingsError;if(a)return void e0("string"==typeof a?a:String(a))}let t=ej.trim();if(t.length>0){let e=await (0,o.$)({type:"setMongoDbPassword",password:t}),a=e.result?.settingsError;if(a)return void e0("string"==typeof a?a:String(a))}let a=eD.trim();if(a.length>0){let e=await (0,o.$)({type:"setGitlabToken",token:a}),t=e.result?.settingsError;if(t)return void e0("string"==typeof t?t:String(t))}let{workspaceLocExcludedDirsText:s,workspaceLocExcludedPathPatternsText:n,plannedSessions:r,...i}=U,l=await (0,o.$)({type:"updateKronosysSettings",settings:{...i,dashboardShowKronoFocusInHeader:!0,workspaceLocExcludedDirectoryNames:[...new Set(s.split("\n").map(e=>e.trim()).filter(e=>e.length>0&&e.length<=256&&!e.includes("/")&&!e.includes("\\")))].slice(0,500),workspaceLocExcludedPathPatterns:[...new Set(n.split("\n").map(e=>e.trim().replace(/\\/g,"/")).filter(e=>e.length>0&&e.length<=512))].slice(0,200),plannedSessions:r.map(e=>{let{tagsText:t,...a}=e;return{...a,tags:t.split(",").map(e=>e.trim()).filter(Boolean)}})}}),d=l.result?.settingsError;if(d)return void e0("string"==typeof d?d:String(d));ev(""),ey(""),eE(""),Q("save"),await th(),setTimeout(()=>Q(null),4e3)}finally{J(!1)}}},t0=async()=>{await (0,o.$)({type:"pickStoragePath"}),await th()},t5=async e=>{let t=e.trim();if(0!==t.length){eL(!0);try{let e=await (0,o.$)({type:"setGitlabToken",token:t}),a=e.result?.settingsError;if(a)return void e0("string"==typeof a?a:String(a));eE(""),eH(null),await th({preserveForm:!0})}finally{eL(!1)}}},t2=async()=>{eL(!0);try{let e=await (0,o.$)({type:"setGitlabToken",token:""}),t=e.result?.settingsError;if(t)return void e0("string"==typeof t?t:String(t));eE(""),eH(null),await th({preserveForm:!0})}finally{eL(!1)}},t1=async e=>{eM(!0),eH(null);try{let t=await (0,o.$)({type:"testGitlabConnection",token:eD.trim(),lang:tv,gitlabApiBaseUrl:U?.gitlabApiBaseUrl?.trim()??""}),a=t.result?.gitlabConnectionTest;if(await th({preserveForm:!0}),a?.outcome==="connected")eH({tone:"ok",text:e.gitlabTestOk});else if(a?.outcome==="failed")if("no_token"===a.reason)eH({tone:"bad",text:e.gitlabTestNoToken});else{let t="string"==typeof a.message&&a.message.trim()?` (${a.message.trim()})`:"";eH({tone:"bad",text:`${e.gitlabTestFail}${t}`})}else eH({tone:"bad",text:e.gitlabTestErrorGeneric})}catch{eH({tone:"bad",text:e.gitlabTestErrorGeneric})}finally{eM(!1)}},t4=async()=>{eC(!0);try{let e=await (0,o.$)({type:"createGlabRemoteRepo"}),t=e.result?.glabRepoCreate;if(t&&!1===t.ok&&t.error)return void e0(t.error);await th()}finally{eC(!1)}},t3=async e=>{ek(!0);try{let t=await (0,o.$)({type:"setMongoDbConnectionUri",uri:e}),a=t.result?.settingsError;if(a)return void e0("string"==typeof a?a:String(a));ev(""),await th({preserveForm:!0})}finally{ek(!1)}},t6=async e=>{ez(!0);try{let t=await (0,o.$)({type:"setMongoDbPassword",password:e}),a=t.result?.settingsError;if(a)return void e0("string"==typeof a?a:String(a));ey(""),await th({preserveForm:!0})}finally{ez(!1)}},t8=async(e,t)=>{eS(!0),eJ(null);try{let a=await (0,o.$)({type:"testMongoDbConnection",settings:{mongodbEnabled:t.mongodbEnabled,mongodbDatabaseName:t.mongodbDatabaseName,mongodbCollectionName:t.mongodbCollectionName,mongodbHost:t.mongodbHost,mongodbPort:t.mongodbPort,mongodbUsername:t.mongodbUsername,mongodbAuthSource:t.mongodbAuthSource}}),s=a.result?.mongoConnectionTest?.outcome;await th({preserveForm:!0}),"connected"===s?eJ({tone:"ok",text:e.mongoTestOk}):"failed"===s?eJ({tone:"bad",text:e.mongoTestFail}):"disabled"===s&&eJ({tone:"warn",text:e.mongoTestDisabled})}catch{eJ({tone:"bad",text:e.mongoTestErrorGeneric})}finally{eS(!1)}},t9=(0,n.useCallback)(()=>{e2(!0)},[]),t7=(0,n.useCallback)(async()=>{e2(!1);let e=(0,p.J)(tv);eQ(!0);try{let t=await (0,o.$)({type:"resyncMongoMirror"}),a=t.result?.mongoResync;await th({preserveForm:!0}),a&&!0===a.ok?e0(e.mongoResyncDone.replace("{upserted}",String(a.upserted)).replace("{failed}",String(a.failed))):a&&!1===a.ok?"disabled"===a.reason?e0(e.mongoResyncDisabled):"unsupported"===a.reason?e0(e.mongoResyncUnsupported):"failed"===a.reason?e0(e.mongoResyncErrorDetail.replace("{detail}",String(a.message))):e0(e.mongoResyncErrorGeneric):e0(e.mongoResyncErrorGeneric)}catch(a){let t=a instanceof Error?a.message:String(a);e0(e.mongoResyncErrorDetail.replace("{detail}",t))}finally{eQ(!1)}},[tv,th]),ae=(e,t)=>{K(a=>a?{...a,[e]:t}:a)},at=async e=>{e6(e);try{let t=await (0,o.$)({type:"archiveSession",sessionId:e,archived:!1}),a=t.result?.sessionOp;a&&!a.ok&&a.message&&e0("string"==typeof a.message?a.message:String(a.message)),await th({preserveForm:!0})}finally{e6(null)}},aa=(0,n.useCallback)(async()=>{te(!0);try{await (0,o.$)({type:"clearHistory"}),F.r.getState().resetDashboard(),O.h.getState().reset(),G.e.getState().resetLightThemeVariant(),$.B.getState().resetGitIdentityBannerDismissed(),await th({preserveForm:!0}),e9(!1),tx.push("/?tour=replay")}catch(e){e0(e instanceof Error?e.message:String(e))}finally{te(!1)}},[th,tx]),as=(0,n.useCallback)(async()=>{if(!tr)return void e0(tk.dangerRestoreNoFile);tn(!0);try{let e=new FormData;e.set("file",tr);let t=tr.name.toLowerCase().endsWith(".json")?"json":"sqlite";e.set("format",t);let a=await fetch("/api/restore",{method:"POST",body:e}),s=await a.text(),n={};try{n=s?JSON.parse(s):{}}catch{n={}}if(!a.ok||!0!==n.ok){let e="string"==typeof n.detail?n.detail:"string"==typeof n.error?n.error:s||`HTTP ${a.status}`;e0(`${tk.dangerRestoreFailed.replace("{detail}",e)}`);return}ta(!1),ti(null),tl.current&&(tl.current.value=""),await th({preserveForm:!1,routerInvalidate:!0}),e0("json"===t?tk.dangerRestoreDoneJson:tk.dangerRestoreDoneSqlite)}finally{tn(!1)}},[th,tr,tk]),an=(0,n.useCallback)(async()=>{eg(!0),Q(null);try{await (0,o.$)({type:"resetKronosysSettings"}),$.B.getState().resetGitIdentityBannerDismissed(),ev(""),ey(""),eE(""),Q("reset"),await th(),setTimeout(()=>Q(null),4e3)}catch(e){e0(e instanceof Error?e.message:String(e))}finally{eg(!1)}},[th]);return(0,s.jsxs)("div",{className:"min-h-screen bg-zinc-100 text-zinc-900 dark:bg-zinc-900 dark:text-zinc-100",children:[(0,s.jsxs)("header",{className:v.cI,children:[(0,s.jsxs)("div",{className:v.hu,children:[(0,s.jsxs)("div",{className:"flex min-w-0 flex-col gap-1",children:[(0,s.jsx)(i(),{href:(0,es.c)("/",tu),className:"w-fit text-xl font-semibold tracking-tight text-zinc-900 hover:text-violet-700 dark:text-zinc-100 dark:hover:text-violet-300",children:"Kronosys"}),(0,s.jsxs)("p",{className:"flex flex-wrap items-center gap-x-2 text-xs font-medium leading-snug text-zinc-500 dark:text-zinc-400",children:[(0,s.jsx)("span",{children:tw.brandTagline}),(0,s.jsx)("span",{className:"text-zinc-400/70 dark:text-zinc-600","aria-hidden":!0,children:"\xb7"}),(0,s.jsx)(m.h,{ariaLabelTemplate:tw.appVersionAriaLabel})]})]}),(0,s.jsx)(j._,{payload:a,dt:tw})]}),(0,s.jsx)(f.u,{leading:(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(y.x,{lang:tv,dt:tw}),(0,s.jsx)(N.a,{payload:a,dt:tw,post:tT}),(0,s.jsx)(k.p,{dt:tw,lang:tv,dashboardSessionNavId:tu,onManualRefresh:tS})]}),nav:(0,s.jsx)(I.b,{current:"settings",labels:tf,navAriaLabel:tw.appShellRouteNavAria,dashboardSessionId:tu,lang:tv,dt:tw}),trailing:(0,s.jsxs)(z.b,{ariaLabel:tw.appShellUtilityToolbarGroupAria,children:[(0,s.jsx)(A.U,{lang:tv}),(0,s.jsx)(M.r,{title:tw.pageRefreshTitle,ariaLabel:tw.pageRefreshAriaLabel,inlineMessages:{loading:tw.pageRefreshProgressLabel,success:tw.pageRefreshDoneToast,error:tw.pageRefreshFailedToast},onRefresh:tS}),(0,s.jsx)(P.o,{lang:tv,menuHeading:"fr"===tv?"Langue":"Language",triggerAriaLabel:"fr"===tv?"Langue de l’interface":"Interface language",onSelect:e=>void tQ(e)})]})})]}),(0,s.jsxs)("main",{className:"mx-auto w-full max-w-[1920px] px-5 py-8 sm:px-8 lg:px-10 xl:px-12 2xl:px-14",children:[(0,s.jsxs)("div",{id:"settings-tour-anchor-intro",className:"scroll-mt-32",children:[(0,s.jsx)("h1",{className:"text-2xl font-semibold text-zinc-900 dark:text-zinc-50",children:tk.title}),(0,s.jsx)("p",{className:"mt-2 text-sm text-zinc-600 dark:text-zinc-400",children:tk.subtitle})]}),(0,s.jsx)("p",{className:"mt-2 text-xs text-zinc-500 dark:text-zinc-500",children:tk.openIdeSettings}),r&&"ready"===C?(0,s.jsx)("div",{className:"mt-6 rounded-lg border border-amber-300/80 bg-amber-50/90 px-4 py-3 text-sm text-amber-950 dark:border-amber-800/50 dark:bg-amber-950/35 dark:text-amber-100",role:"status",children:tw.dashboardSyncErrorBanner}):null,"ready"!==C?(0,s.jsx)(c.v,{phase:"unavailable"===C?"unavailable":"loading",dt:tw,lang:tv,technicalDetail:r,retryBusy:E,onRetry:"unavailable"===C?()=>{B(!0),th({resetBootstrapFailures:!0}).finally(()=>{B(!1)})}:void 0}):null,U?(0,s.jsxs)("div",{className:"mt-8 lg:grid lg:grid-cols-[minmax(0,13rem)_minmax(0,1fr)] lg:items-start lg:gap-10",children:[(0,s.jsxs)("aside",{className:"mb-8 lg:sticky lg:top-6 lg:mb-0 lg:self-start",children:[(0,s.jsxs)("div",{className:"mb-4",children:[(0,s.jsx)("label",{htmlFor:t,className:"sr-only",children:tk.tocSearchAriaLabel}),(0,s.jsxs)("div",{className:"relative",children:[(0,s.jsx)(et.A,{className:"pointer-events-none absolute left-2.5 top-1/2 size-4 -translate-y-1/2 text-zinc-400 dark:text-zinc-500","aria-hidden":!0}),(0,s.jsx)("input",{id:t,type:"search",value:to,onChange:e=>td(e.target.value),placeholder:tk.tocSearchPlaceholder,className:"w-full rounded-lg border border-zinc-300 bg-white py-2 pl-9 pr-3 text-sm text-zinc-900 outline-none ring-violet-500/30 placeholder:text-zinc-400 focus:ring-2 dark:border-zinc-600 dark:bg-zinc-950 dark:text-zinc-100 dark:placeholder:text-zinc-500"})]})]}),(0,s.jsx)(eu,{s:tk,filter:to,showDevDataInGeneral:tN})]}),(0,s.jsxs)("div",{className:"min-w-0 space-y-10",children:[(0,s.jsxs)("div",{className:"flex flex-wrap items-center gap-3",children:[(0,s.jsx)("button",{type:"button",disabled:tz,className:"rounded-lg bg-violet-600 px-4 py-2 text-sm font-medium text-white hover:bg-violet-500 disabled:opacity-50",onClick:()=>void tX(),children:Z?tk.saving:tk.save}),(0,s.jsx)("button",{type:"button",disabled:tz,className:"rounded-lg border border-zinc-600 px-4 py-2 text-sm text-zinc-300 hover:bg-zinc-800 disabled:opacity-50",onClick:()=>void th(),children:tk.reload}),(0,s.jsx)("button",{type:"button",disabled:tz,className:"rounded-lg border border-zinc-500 px-4 py-2 text-sm text-zinc-700 hover:bg-zinc-200 disabled:opacity-50 dark:border-zinc-600 dark:text-zinc-200 dark:hover:bg-zinc-800",onClick:()=>eh(!0),children:eb?tk.resettingDefaults:tk.resetToDefaults}),"save"===Y?(0,s.jsx)("span",{className:"text-sm text-emerald-400",children:tk.savedOk}):"reset"===Y?(0,s.jsx)("span",{className:"text-sm text-emerald-400",children:tk.resetDefaultsDone}):null]}),(0,s.jsxs)("section",{id:"settings-usage-profile",className:ex,children:[(0,s.jsx)("h2",{className:"text-xs font-semibold uppercase tracking-wide text-zinc-500",children:tk.sectionUsageProfile}),(0,s.jsx)(ed,{label:tk.usageProfile,description:tk.usageProfileDesc,children:(0,s.jsxs)("select",{className:el(tz),value:U.usageProfile,onChange:e=>ae("usageProfile",e.target.value),disabled:tz,"aria-label":tk.usageProfile,children:[(0,s.jsxs)("option",{value:"developer",disabled:!0,children:[tk.profileDeveloper," ","fr"===tv?"(D\xe9sactiv\xe9)":"(Disabled)"]}),(0,s.jsx)("option",{value:"manager",children:tk.profileManager})]})})]}),(0,s.jsxs)("section",{id:"settings-general",className:ex,children:[(0,s.jsx)("h2",{className:"text-xs font-semibold uppercase tracking-wide text-zinc-500",children:tk.sectionGeneral}),(0,s.jsx)(ed,{label:tk.enabled,description:tk.enabledDesc,children:(0,s.jsx)(ec,{checked:U.enabled,onChange:e=>ae("enabled",e),disabled:tz,ariaLabel:tk.enabled})}),(0,s.jsx)(ed,{label:tk.autoStart,description:tk.autoStartDesc,children:(0,s.jsx)(ec,{checked:U.autoStart,onChange:e=>ae("autoStart",e),disabled:tz,ariaLabel:tk.autoStart})}),(0,s.jsx)(ed,{label:tk.showWelcome,description:tk.showWelcomeDesc,children:(0,s.jsx)(ec,{checked:U.showWelcomeOnStartup,onChange:e=>ae("showWelcomeOnStartup",e),disabled:tz,ariaLabel:tk.showWelcome})}),ty?(0,s.jsxs)("div",{id:"settings-data-environment",className:"scroll-mt-24 space-y-4 border-t border-zinc-200 pt-6 dark:border-zinc-800",children:[(0,s.jsx)("h3",{className:"text-sm font-semibold text-zinc-800 dark:text-zinc-200",children:tk.dataEnvBlockTitle}),(0,s.jsx)("p",{className:"text-sm leading-relaxed text-zinc-600 dark:text-zinc-400",children:tk.dataEnvIntro}),ty.traceDataDirOverride?(0,s.jsx)("p",{className:"text-sm text-amber-700 dark:text-amber-300/90",role:"status",children:tk.dataEnvTraceOverride}):null,ty.dataDirectoryResolutionMismatch?(0,s.jsx)("p",{className:"text-sm text-amber-700 dark:text-amber-300/90",role:"status",children:tk.dataEnvRestartHint}):null,(0,s.jsxs)("div",{className:"flex flex-col gap-2 sm:flex-row sm:items-center sm:justify-between sm:gap-6",children:[(0,s.jsxs)("div",{className:"min-w-0 sm:max-w-md",children:[(0,s.jsx)("div",{className:"text-sm font-medium text-zinc-800 dark:text-zinc-200",children:tk.dataEnvDualLabel}),(0,s.jsx)("p",{className:"mt-0.5 text-xs leading-snug text-zinc-600 dark:text-zinc-500",children:tk.dataEnvDualDesc})]}),(0,s.jsx)(ec,{checked:U.dualDataEnvironmentEnabled,onChange:e=>{ae("dualDataEnvironmentEnabled",e),e||ae("activeDataEnvironment","production")},disabled:tz||ty.traceDataDirOverride,ariaLabel:tk.dataEnvDualLabel})]}),U.dualDataEnvironmentEnabled?(0,s.jsx)(ed,{label:tk.dataEnvActiveLabel,description:tk.dataEnvActiveDesc,children:(0,s.jsxs)("select",{className:el(tz||ty.traceDataDirOverride),value:U.activeDataEnvironment,disabled:tz||ty.traceDataDirOverride,onChange:e=>ae("activeDataEnvironment","qa"===e.target.value?"qa":"production"),"aria-label":tk.dataEnvActiveLabel,children:[(0,s.jsx)("option",{value:"production",children:tk.dataEnvActiveProduction}),(0,s.jsx)("option",{value:"qa",children:tk.dataEnvActiveQa})]})}):null,(0,s.jsxs)("div",{className:"space-y-2 rounded-lg border border-zinc-200 bg-zinc-50/80 p-3 text-xs text-zinc-700 dark:border-zinc-700 dark:bg-zinc-900/50 dark:text-zinc-300",children:[(0,s.jsxs)("div",{children:[(0,s.jsx)("div",{className:"mb-0.5 font-medium text-zinc-500 dark:text-zinc-500",children:tk.dataEnvActivePath}),(0,s.jsx)("div",{className:"break-all font-mono text-[0.7rem] leading-relaxed",children:ty.activeDataDirectory})]}),(0,s.jsxs)("div",{children:[(0,s.jsx)("div",{className:"mb-0.5 font-medium text-zinc-500 dark:text-zinc-500",children:tk.dataEnvPreferredPath}),(0,s.jsx)("div",{className:"break-all font-mono text-[0.7rem] leading-relaxed",children:ty.preferredDataDirectory})]}),(0,s.jsxs)("div",{children:[(0,s.jsx)("div",{className:"mb-0.5 font-medium text-zinc-500 dark:text-zinc-500",children:tk.dataEnvProdPath}),(0,s.jsx)("div",{className:"break-all font-mono text-[0.7rem] leading-relaxed",children:ty.productionDataDirectory})]}),(0,s.jsxs)("div",{children:[(0,s.jsx)("div",{className:"mb-0.5 font-medium text-zinc-500 dark:text-zinc-500",children:tk.dataEnvQaPath}),(0,s.jsx)("div",{className:"break-all font-mono text-[0.7rem] leading-relaxed",children:ty.qaDataDirectory})]}),(0,s.jsxs)("div",{children:[(0,s.jsx)("div",{className:"mb-0.5 font-medium text-zinc-500 dark:text-zinc-500",children:tk.dataEnvPrefsFile}),(0,s.jsx)("div",{className:"break-all font-mono text-[0.7rem] leading-relaxed",children:ty.preferencesFilePath})]})]})]}):null,tN&&tj?(0,s.jsxs)("div",{id:"settings-dev-data",className:"scroll-mt-24 space-y-4 border-t border-zinc-200 pt-6 dark:border-zinc-800",children:[(0,s.jsx)("h3",{className:"text-sm font-semibold text-zinc-800 dark:text-zinc-200",children:tk.devDataBlockTitle}),(0,s.jsx)("p",{className:"text-sm leading-relaxed text-zinc-600 dark:text-zinc-400",children:tk.devDataIntro}),tj.traceDataDirOverride?(0,s.jsx)("p",{className:"text-sm text-amber-700 dark:text-amber-300/90",role:"status",children:tk.devDataTraceOverride}):null,tj.envForcesProductionData&&!tj.traceDataDirOverride?(0,s.jsx)("p",{className:"text-sm text-amber-700 dark:text-amber-300/90",role:"status",children:tk.devDataEnvOverride}):null,tj.dataDirectoryResolutionMismatch?(0,s.jsx)("p",{className:"text-sm text-amber-700 dark:text-amber-300/90",role:"status",children:tk.devDataRestartHint}):null,(0,s.jsxs)("div",{className:"flex flex-col gap-2 sm:flex-row sm:items-center sm:justify-between sm:gap-6",children:[(0,s.jsxs)("div",{className:"min-w-0 sm:max-w-md",children:[(0,s.jsx)("div",{className:"text-sm font-medium text-zinc-800 dark:text-zinc-200",children:tk.devDataUseProdLabel}),(0,s.jsx)("p",{className:"mt-0.5 text-xs leading-snug text-zinc-600 dark:text-zinc-500",children:tk.devDataUseProdDesc})]}),(0,s.jsx)(ec,{checked:tj.envForcesProductionData||U.developmentUseProductionData,onChange:e=>ae("developmentUseProductionData",e),disabled:tz||tj.traceDataDirOverride||tj.envForcesProductionData,ariaLabel:tk.devDataUseProdLabel})]}),(0,s.jsxs)("div",{className:"space-y-2 rounded-lg border border-zinc-200 bg-zinc-50/80 p-3 text-xs text-zinc-700 dark:border-zinc-700 dark:bg-zinc-900/50 dark:text-zinc-300",children:[(0,s.jsxs)("div",{children:[(0,s.jsx)("div",{className:"mb-0.5 font-medium text-zinc-500 dark:text-zinc-500",children:tk.devDataActivePath}),(0,s.jsx)("div",{className:"break-all font-mono text-[0.7rem] leading-relaxed",children:tj.activeDataDirectory})]}),(0,s.jsxs)("div",{children:[(0,s.jsx)("div",{className:"mb-0.5 font-medium text-zinc-500 dark:text-zinc-500",children:tk.devDataPreferredPath}),(0,s.jsx)("div",{className:"break-all font-mono text-[0.7rem] leading-relaxed",children:tj.preferredDataDirectory})]}),(0,s.jsxs)("div",{children:[(0,s.jsx)("div",{className:"mb-0.5 font-medium text-zinc-500 dark:text-zinc-500",children:tk.devDataProdPath}),(0,s.jsx)("div",{className:"break-all font-mono text-[0.7rem] leading-relaxed",children:tj.productionDataDirectory})]}),(0,s.jsxs)("div",{children:[(0,s.jsx)("div",{className:"mb-0.5 font-medium text-zinc-500 dark:text-zinc-500",children:tk.devDataPrefsFile}),(0,s.jsx)("div",{className:"break-all font-mono text-[0.7rem] leading-relaxed",children:tj.preferencesFilePath})]})]})]}):null]}),(0,s.jsxs)("section",{id:"settings-schedule",className:ex,children:[(0,s.jsx)("h2",{className:"text-xs font-semibold uppercase tracking-wide text-zinc-500",children:tk.sectionSchedule}),(0,s.jsx)(ed,{label:tk.scheduleEnabled,description:tk.scheduleEnabledDesc,children:(0,s.jsx)(ec,{checked:U.scheduleEnabled,onChange:e=>ae("scheduleEnabled",e),disabled:tz,ariaLabel:tk.scheduleEnabled})}),U.scheduleEnabled&&(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(ed,{label:tk.scheduleDays,description:tk.scheduleDaysDesc,children:(0,s.jsx)("div",{className:"flex flex-wrap items-center gap-2",children:[1,2,3,4,5,6,7].map(e=>{let t=U.scheduleDays.includes(e),a="fr"===tv?["L","M","M","J","V","S","D"][e-1]:["M","T","W","T","F","S","S"][e-1];return(0,s.jsx)("button",{type:"button",disabled:tz,onClick:()=>{ae("scheduleDays",t?U.scheduleDays.filter(t=>t!==e):[...U.scheduleDays,e].sort((e,t)=>e-t))},className:`flex h-8 w-8 items-center justify-center rounded-md border text-sm font-medium transition-colors ${t?"border-violet-600 bg-violet-600 text-white hover:bg-violet-500":"border-zinc-300 bg-white text-zinc-700 hover:bg-zinc-50 dark:border-zinc-700 dark:bg-zinc-900 dark:text-zinc-300 dark:hover:bg-zinc-800"}`,children:a},e)})})}),(0,s.jsxs)("div",{className:"grid grid-cols-1 gap-6 sm:grid-cols-2",children:[(0,s.jsx)(ed,{label:tk.scheduleStartTime,description:"",children:(0,s.jsx)(ee,{value:U.scheduleStartTime,onChange:e=>ae("scheduleStartTime",e),disabled:tz,"aria-label":tk.scheduleStartTime,lang:tv,use24HourClock:U.dashboardUse24HourClock,t:tk})}),(0,s.jsx)(ed,{label:tk.scheduleEndTime,description:"",children:(0,s.jsx)(ee,{value:U.scheduleEndTime,onChange:e=>ae("scheduleEndTime",e),disabled:tz,"aria-label":tk.scheduleEndTime,lang:tv,use24HourClock:U.dashboardUse24HourClock,t:tk})})]}),(0,s.jsx)(ed,{label:tk.scheduleCreateDailySession,description:tk.scheduleCreateDailySessionDesc,children:(0,s.jsx)(ec,{checked:U.scheduleCreateDailySession,onChange:e=>ae("scheduleCreateDailySession",e),disabled:tz,ariaLabel:tk.scheduleCreateDailySession})}),(0,s.jsx)(ed,{label:tk.scheduleTransferTasks,description:tk.scheduleTransferTasksDesc,children:(0,s.jsx)(ec,{checked:U.scheduleTransferTasks,onChange:e=>ae("scheduleTransferTasks",e),disabled:tz,ariaLabel:tk.scheduleTransferTasks})}),(0,s.jsx)(ed,{label:tk.schedulePauseTasks,description:tk.schedulePauseTasksDesc,children:(0,s.jsx)(ec,{checked:U.schedulePauseTasks,onChange:e=>ae("schedulePauseTasks",e),disabled:tz,ariaLabel:tk.schedulePauseTasks})})]})]}),(0,s.jsxs)("section",{id:"settings-planned-sessions",className:ex,children:[(0,s.jsx)("h2",{className:"text-xs font-semibold uppercase tracking-wide text-zinc-500",children:tk.sectionPlannedSessions}),(0,s.jsx)("p",{className:"mt-1 text-xs leading-relaxed text-zinc-500",children:tk.plannedSessionsIntro}),(0,s.jsxs)("div",{className:"mt-6 flex flex-col gap-4",children:[U.plannedSessions.map((e,t)=>(0,s.jsxs)("div",{className:"rounded-lg border border-zinc-200 bg-white p-4 shadow-sm dark:border-zinc-800 dark:bg-zinc-900",children:[(0,s.jsxs)("div",{className:"mb-4 flex items-center justify-between",children:[(0,s.jsxs)("h3",{className:"text-sm font-medium text-zinc-900 dark:text-zinc-100",children:[tk.plannedSessionName," ",t+1]}),(0,s.jsx)("button",{type:"button",disabled:tz,onClick:()=>{ae("plannedSessions",U.plannedSessions.filter((e,a)=>a!==t))},className:"text-xs text-red-600 hover:text-red-500 disabled:opacity-50 dark:text-red-400",children:tk.plannedSessionRemove})]}),(0,s.jsxs)("div",{className:"grid grid-cols-1 gap-6 sm:grid-cols-2",children:[(0,s.jsx)(ed,{label:tk.plannedSessionName,description:"",children:(0,s.jsx)("input",{type:"text",className:el(tz),value:e.name,onChange:e=>{let a=[...U.plannedSessions];a[t]={...a[t],name:e.target.value},ae("plannedSessions",a)},disabled:tz})}),(0,s.jsx)(ed,{label:tk.scheduleDays,description:"",children:(0,s.jsx)("div",{className:"flex flex-wrap items-center gap-2",children:[1,2,3,4,5,6,7].map(a=>{let n=e.days.includes(a),r="fr"===tv?["L","M","M","J","V","S","D"][a-1]:["M","T","W","T","F","S","S"][a-1];return(0,s.jsx)("button",{type:"button",disabled:tz,onClick:()=>{let s=n?e.days.filter(e=>e!==a):[...e.days,a].sort((e,t)=>e-t),r=[...U.plannedSessions];r[t]={...r[t],days:s},ae("plannedSessions",r)},className:`flex h-7 w-7 items-center justify-center rounded border text-xs font-medium transition-colors ${n?"border-violet-600 bg-violet-600 text-white hover:bg-violet-500":"border-zinc-300 bg-white text-zinc-700 hover:bg-zinc-50 dark:border-zinc-700 dark:bg-zinc-900 dark:text-zinc-300 dark:hover:bg-zinc-800"}`,children:r},a)})})}),(0,s.jsx)(ed,{label:tk.scheduleStartTime,description:"",children:(0,s.jsx)(ee,{value:e.startTime,onChange:e=>{let a=[...U.plannedSessions];a[t]={...a[t],startTime:e},ae("plannedSessions",a)},disabled:tz,"aria-label":tk.scheduleStartTime,lang:tv,use24HourClock:U.dashboardUse24HourClock,t:tk})}),(0,s.jsx)(ed,{label:tk.scheduleEndTime,description:"",children:(0,s.jsx)(ee,{value:e.endTime,onChange:e=>{let a=[...U.plannedSessions];a[t]={...a[t],endTime:e},ae("plannedSessions",a)},disabled:tz,"aria-label":tk.scheduleEndTime,lang:tv,use24HourClock:U.dashboardUse24HourClock,t:tk})}),(0,s.jsx)(ed,{label:tk.plannedSessionProject,description:"",children:(0,s.jsx)("input",{type:"text",className:el(tz),value:e.project,onChange:e=>{let a=[...U.plannedSessions];a[t]={...a[t],project:e.target.value},ae("plannedSessions",a)},disabled:tz,placeholder:"e.g. Deep work"})}),(0,s.jsx)(ed,{label:tk.plannedSessionTags,description:"",children:(0,s.jsx)("input",{type:"text",className:el(tz),value:e.tagsText,onChange:e=>{let a=[...U.plannedSessions];a[t]={...a[t],tagsText:e.target.value},ae("plannedSessions",a)},disabled:tz,placeholder:"e.g. meeting, frontend"})})]}),(0,s.jsxs)("div",{className:"mt-6 flex flex-col gap-4 border-t border-zinc-100 pt-4 dark:border-zinc-800",children:[(0,s.jsx)(ed,{label:tk.scheduleCreateDailySession,description:"",children:(0,s.jsx)(ec,{checked:e.createSession,onChange:e=>{let a=[...U.plannedSessions];a[t]={...a[t],createSession:e},ae("plannedSessions",a)},disabled:tz,ariaLabel:tk.scheduleCreateDailySession})}),(0,s.jsx)(ed,{label:tk.scheduleTransferTasks,description:"",children:(0,s.jsx)(ec,{checked:e.transferTasks,onChange:e=>{let a=[...U.plannedSessions];a[t]={...a[t],transferTasks:e},ae("plannedSessions",a)},disabled:tz,ariaLabel:tk.scheduleTransferTasks})}),(0,s.jsx)(ed,{label:tk.schedulePauseTasks,description:"",children:(0,s.jsx)(ec,{checked:e.pauseTasks,onChange:e=>{let a=[...U.plannedSessions];a[t]={...a[t],pauseTasks:e},ae("plannedSessions",a)},disabled:tz,ariaLabel:tk.schedulePauseTasks})})]})]},e.id)),(0,s.jsxs)("button",{type:"button",onClick:()=>{ae("plannedSessions",[...U.plannedSessions,{id:Math.random().toString(36).slice(2,11),name:"",days:[1,2,3,4,5],startTime:"10:00",endTime:"11:00",createSession:!0,transferTasks:!0,pauseTasks:!0,tagsText:"",project:""}])},disabled:tz,className:"w-fit rounded-lg border border-dashed border-zinc-300 px-4 py-2 text-sm font-medium text-zinc-600 hover:border-violet-500 hover:text-violet-600 disabled:opacity-50 dark:border-zinc-700 dark:text-zinc-400 dark:hover:border-violet-500 dark:hover:text-violet-400",children:["+ ",tk.plannedSessionAdd]})]})]}),(0,s.jsxs)("section",{id:"settings-privacy",className:ex,children:[(0,s.jsx)("h2",{className:"text-xs font-semibold uppercase tracking-wide text-zinc-500",children:tk.sectionPrivacy}),(0,s.jsx)(ed,{label:tk.anonymizePaths,description:tk.anonymizePathsDesc,children:(0,s.jsx)(ec,{checked:U.anonymizePaths,onChange:e=>ae("anonymizePaths",e),disabled:tz,ariaLabel:tk.anonymizePaths})})]}),(0,s.jsxs)("section",{id:"settings-kronoFocus",className:ex,children:[(0,s.jsx)("h2",{className:"text-xs font-semibold uppercase tracking-wide text-zinc-500",children:tk.sectionKronoFocus}),(0,s.jsx)("p",{className:"mb-4 text-sm leading-relaxed text-zinc-600 dark:text-zinc-400",children:tk.kronoFocusHeaderPinnedNote}),(0,s.jsx)(ed,{label:tk.kronoFocusShowInTaskOps,description:tk.kronoFocusShowInTaskOpsDesc,children:(0,s.jsx)(em,{checked:U.dashboardShowKronoFocusInTaskOps,onChange:e=>ae("dashboardShowKronoFocusInTaskOps",e),disabled:tz,ariaLabel:tk.kronoFocusShowInTaskOps})})]}),(0,s.jsxs)("section",{id:"settings-task-tags",className:ex,children:[(0,s.jsx)("h2",{className:"text-xs font-semibold uppercase tracking-wide text-zinc-500",children:tk.sectionTaskTags}),(0,s.jsx)(ed,{label:tk.taskDefaultTagBucketEnabled,description:tk.taskDefaultTagBucketEnabledDesc,children:(0,s.jsx)(em,{checked:U.taskDefaultTagBucketEnabled,onChange:e=>ae("taskDefaultTagBucketEnabled",e),disabled:tz,ariaLabel:tk.taskDefaultTagBucketEnabled})}),(0,s.jsx)(ed,{label:tk.taskStripDefaultTagWhenExplicitTags,description:tk.taskStripDefaultTagWhenExplicitTagsDesc,children:(0,s.jsx)(em,{checked:U.taskStripDefaultTagWhenExplicitTags,onChange:e=>ae("taskStripDefaultTagWhenExplicitTags",e),disabled:tz,ariaLabel:tk.taskStripDefaultTagWhenExplicitTags})}),(0,s.jsx)(ed,{label:tk.taskMinimumDurationMinutes,description:tk.taskMinimumDurationMinutesDesc,children:(0,s.jsx)("input",{type:"number",min:H.BO,max:H.TK,step:15,className:el(tz),value:U.taskMinimumDurationMinutes,onChange:e=>ae("taskMinimumDurationMinutes",Number(e.target.value)),disabled:tz,"aria-label":tk.taskMinimumDurationMinutes})}),(0,s.jsx)(ed,{label:tk.dashboardAllowTaskStartTimeEdit,description:tk.dashboardAllowTaskStartTimeEditDesc,children:(0,s.jsx)(em,{checked:U.dashboardAllowTaskStartTimeEdit,onChange:e=>ae("dashboardAllowTaskStartTimeEdit",e),disabled:tz,ariaLabel:tk.dashboardAllowTaskStartTimeEdit})}),(0,s.jsx)(ed,{label:tk.dashboardAllowSessionStartTimeEdit,description:tk.dashboardAllowSessionStartTimeEditDesc,children:(0,s.jsx)(em,{checked:U.dashboardAllowSessionStartTimeEdit,onChange:e=>ae("dashboardAllowSessionStartTimeEdit",e),disabled:tz,ariaLabel:tk.dashboardAllowSessionStartTimeEdit})}),(0,s.jsx)(ed,{label:tk.dashboardAllowTaskEndTimeEdit,description:tk.dashboardAllowTaskEndTimeEditDesc,children:(0,s.jsx)(em,{checked:U.dashboardAllowTaskEndTimeEdit,onChange:e=>ae("dashboardAllowTaskEndTimeEdit",e),disabled:tz,ariaLabel:tk.dashboardAllowTaskEndTimeEdit})}),(0,s.jsx)(ed,{label:tk.dashboardAllowSessionEndTimeEdit,description:tk.dashboardAllowSessionEndTimeEditDesc,children:(0,s.jsx)(em,{checked:U.dashboardAllowSessionEndTimeEdit,onChange:e=>ae("dashboardAllowSessionEndTimeEdit",e),disabled:tz,ariaLabel:tk.dashboardAllowSessionEndTimeEdit})})]}),(0,s.jsxs)("section",{id:"settings-collection",className:ex,children:[(0,s.jsx)("h2",{className:"text-xs font-semibold uppercase tracking-wide text-zinc-500",children:tk.sectionCollection}),(0,s.jsx)(ed,{label:tk.flushInterval,description:tk.flushIntervalDesc,children:(0,s.jsx)("input",{type:"number",min:5,max:3600,className:el(tz),value:U.flushIntervalSeconds,onChange:e=>ae("flushIntervalSeconds",Number(e.target.value)),disabled:tz})}),(0,s.jsx)(ed,{label:tk.heartbeatInterval,description:tk.heartbeatIntervalDesc,children:(0,s.jsx)("input",{type:"number",min:30,max:86400,className:el(tz),value:U.heartbeatIntervalSeconds,onChange:e=>ae("heartbeatIntervalSeconds",Number(e.target.value)),disabled:tz})}),(0,s.jsx)(ed,{label:tk.maxBuffered,description:tk.maxBufferedDesc,children:(0,s.jsx)("input",{type:"number",min:100,max:1e5,className:el(tz),value:U.maxBufferedEvents,onChange:e=>ae("maxBufferedEvents",Number(e.target.value)),disabled:tz})})]}),(0,s.jsxs)("section",{id:"settings-history",className:ex,children:[(0,s.jsx)("h2",{className:"text-xs font-semibold uppercase tracking-wide text-zinc-500",children:tk.sectionHistory}),(0,s.jsx)("p",{className:"text-xs leading-relaxed text-zinc-500",children:tk.historyLocalFirstHint}),(0,s.jsx)(ed,{label:tk.historyPath,description:tk.historyPathDesc,children:(0,s.jsxs)("div",{className:"flex flex-wrap items-center gap-2",children:[(0,s.jsx)("input",{type:"text",className:`${el(tz)} max-w-xl flex-1`,value:U.historyStoragePath,onChange:e=>ae("historyStoragePath",e.target.value),disabled:tz,autoComplete:"off"}),(0,s.jsx)("button",{type:"button",className:"shrink-0 rounded-lg border border-zinc-600 px-3 py-2 text-sm text-zinc-300 hover:bg-zinc-800 disabled:opacity-50",disabled:tz,onClick:()=>void t0(),children:tk.pickStorageFolder})]})}),(0,s.jsxs)(ed,{label:tk.localPersistenceDriver,description:tk.localPersistenceDriverDesc,children:[(0,s.jsxs)("select",{className:el(tz),value:U.localPersistenceDriver,onChange:e=>ae("localPersistenceDriver",e.target.value),disabled:tz,"aria-label":tk.localPersistenceDriver,children:[(0,s.jsx)("option",{value:"json",children:tk.persistenceDriverJson}),(0,s.jsx)("option",{value:"sqlite",children:tk.persistenceDriverSqlite})]}),(0,s.jsx)("p",{className:"mt-2 max-w-xl text-xs text-zinc-500 dark:text-zinc-400",children:tk.localPersistenceReloadHint})]}),(0,s.jsx)(ed,{label:tk.historyPartition,description:tk.historyPartitionDesc,children:(0,s.jsxs)("select",{className:el(tz),value:U.historyPartition,onChange:e=>ae("historyPartition",e.target.value),disabled:tz,children:[(0,s.jsx)("option",{value:"daily",children:tk.partitionDaily}),(0,s.jsx)("option",{value:"weekly",children:tk.partitionWeekly}),(0,s.jsx)("option",{value:"monthly",children:tk.partitionMonthly})]})}),(0,s.jsx)(ed,{label:tk.sessionStartMode,description:tk.sessionStartModeDesc,children:(0,s.jsxs)("select",{className:el(tz),value:U.sessionStartMode,onChange:e=>ae("sessionStartMode",e.target.value),disabled:tz,children:[(0,s.jsx)("option",{value:"continue",children:tk.modeContinue}),(0,s.jsx)("option",{value:"new",children:tk.modeNew})]})})]}),(0,s.jsxs)("section",{id:"settings-export",className:ex,children:[(0,s.jsx)("h2",{className:"text-xs font-semibold uppercase tracking-wide text-zinc-500",children:tk.sectionExport}),(0,s.jsx)(ed,{label:tk.exportFormat,description:tk.exportFormatDesc,children:(0,s.jsxs)("select",{className:el(tz),value:U.sessionExportFormat,onChange:e=>ae("sessionExportFormat",e.target.value),disabled:tz,children:[(0,s.jsx)("option",{value:"json",children:tk.fmtJson}),(0,s.jsx)("option",{value:"csv",children:tk.fmtCsv}),(0,s.jsx)("option",{value:"jiraTable",children:tk.fmtJira}),(0,s.jsx)("option",{value:"sap",children:tk.fmtSap})]})}),(0,s.jsx)(ed,{label:tk.csvDelimiter,description:tk.csvDelimiterDesc,children:(0,s.jsx)("input",{type:"text",maxLength:4,className:el(tz),value:U.csvDelimiter,onChange:e=>ae("csvDelimiter",e.target.value),disabled:tz})})]}),a?(0,s.jsx)(R.u,{s:tk,lang:tv,payload:a,saving:tz,refresh:th}):null,(0,s.jsxs)("section",{id:"settings-git",className:ex,children:[(0,s.jsx)("h2",{className:"text-xs font-semibold uppercase tracking-wide text-zinc-500",children:tk.sectionGit}),(0,s.jsxs)("div",{id:"settings-git-identity",className:"scroll-mt-24 space-y-4 rounded-lg border border-zinc-200 bg-zinc-50/80 p-4 dark:border-zinc-700/80 dark:bg-zinc-950/40",children:[(0,s.jsxs)("div",{children:[(0,s.jsx)("h3",{className:"text-sm font-medium text-zinc-900 dark:text-zinc-100",children:tk.gitIdentitySubheading}),(0,s.jsx)("p",{className:"mt-1 text-xs text-zinc-600 dark:text-zinc-400",children:tk.gitIdentityIntro})]}),(0,s.jsx)(ed,{label:tk.gitIdentityNameLabel,description:tk.gitIdentityNameDesc,children:(0,s.jsx)("input",{type:"text",className:el(tz||eO),value:eR,onChange:e=>eB(e.target.value),disabled:tz||eO,autoComplete:"name",spellCheck:!1})}),(0,s.jsx)(ed,{label:tk.gitIdentityEmailLabel,description:tk.gitIdentityEmailDesc,children:(0,s.jsx)("input",{type:"email",className:el(tz||eO),value:eF,onChange:e=>eU(e.target.value),disabled:tz||eO,autoComplete:"email",spellCheck:!1})}),(0,s.jsx)(ed,{label:tk.gitIdentityLoginLabel,description:tk.gitIdentityLoginDesc,children:(0,s.jsx)("input",{type:"text",className:el(tz||eO),value:eW,onChange:e=>e$(e.target.value),disabled:tz||eO,autoComplete:"username",spellCheck:!1})}),(0,s.jsxs)("div",{className:"flex flex-wrap items-center gap-3",children:[(0,s.jsx)("button",{type:"button",className:"rounded-lg bg-violet-600 px-3 py-1.5 text-sm font-medium text-white hover:bg-violet-500 disabled:opacity-50",disabled:tz||eO,onClick:()=>void tg(),children:eO?tk.gitIdentitySaving:tk.gitIdentitySave}),eG?(0,s.jsx)("span",{className:"text-sm text-emerald-600 dark:text-emerald-400",children:tk.gitIdentitySavedFlash}):null]})]}),(0,s.jsx)(ed,{label:tk.autoGitSync,description:tk.autoGitSyncDesc,children:(0,s.jsx)(ec,{checked:U.autoGitSync,onChange:e=>ae("autoGitSync",e),disabled:tz,ariaLabel:tk.autoGitSync})}),(0,s.jsxs)(ed,{label:tk.gitlabInstanceUrl,description:tk.gitlabInstanceUrlDesc,children:[(0,s.jsx)("input",{type:"url",className:el(tz),value:U.gitlabApiBaseUrl,onChange:e=>ae("gitlabApiBaseUrl",e.target.value),disabled:tz,autoComplete:"off",spellCheck:!1,placeholder:"https://gitlab.com","aria-label":tk.gitlabInstanceUrl}),(0,s.jsx)("p",{className:"mt-1.5 text-xs leading-relaxed text-zinc-500 dark:text-zinc-400",children:tk.gitlabTest401Help})]}),(0,s.jsxs)(ed,{label:tk.gitlabToken,description:tk.gitlabTokenDesc,children:[(0,s.jsx)("p",{className:"mb-2 text-xs text-zinc-400",children:tY}),(0,s.jsx)("input",{type:"password",className:el(tz||eP||eT),value:eD,onChange:e=>eE(e.target.value),disabled:tz||eP||eT,autoComplete:"off",spellCheck:!1,placeholder:t_?"••••••••":"","aria-label":tk.gitlabToken}),(0,s.jsxs)("div",{className:"mt-2 flex flex-wrap gap-2",children:[(0,s.jsx)("button",{type:"button",className:"rounded-lg bg-violet-600 px-3 py-1.5 text-sm font-medium text-white hover:bg-violet-500 disabled:opacity-50",disabled:tz||eP||eT||0===eD.trim().length,title:0===eD.trim().length?tk.gitlabTokenSaveNeedValue:void 0,onClick:()=>void t5(eD),children:eP?tk.saving:tk.gitlabTokenSave}),(0,s.jsx)("button",{type:"button",className:"rounded-lg border border-zinc-600 px-3 py-1.5 text-sm text-zinc-300 hover:bg-zinc-800 disabled:opacity-50",disabled:tz||eP||eT||!t_,onClick:()=>void t2(),children:tk.gitlabTokenClear})]}),t_&&""===eD.trim()&&!tK?(0,s.jsx)("p",{className:"mt-2 text-xs leading-relaxed text-zinc-500 dark:text-zinc-400",children:tk.gitlabTestPasteStoredHint}):null,(0,s.jsx)("div",{className:"mt-3 flex flex-wrap items-center gap-2",children:(0,s.jsx)("button",{type:"button",className:"rounded-lg border border-zinc-600 px-3 py-1.5 text-sm text-zinc-300 hover:bg-zinc-800 disabled:opacity-50",disabled:tz||eP||eT||eA||!tJ,"aria-label":tk.gitlabTestConnectionAria,onClick:()=>void t1(tk),children:eA?tk.gitlabTestRunning:tk.gitlabTestConnection})}),eI?(0,s.jsx)("p",{className:"ok"===eI.tone?"mt-2 text-sm text-emerald-600 dark:text-emerald-400":"warn"===eI.tone?"mt-2 text-sm text-amber-600 dark:text-amber-400":"mt-2 text-sm text-red-600 dark:text-red-400",children:eI.text}):null,t_||tK?(0,s.jsx)("p",{className:tZ?"mt-2 text-xs text-emerald-600 dark:text-emerald-400":"mt-2 text-xs text-zinc-500 dark:text-zinc-400",children:tZ?tk.gitlabApiVerifiedYes:tk.gitlabApiVerifiedNo}):null]}),tV?(0,s.jsxs)("div",{className:"max-w-md rounded-lg border border-violet-500/35 bg-violet-950/25 px-3 py-3 text-sm text-zinc-200",children:[(0,s.jsx)("p",{id:e,className:"leading-snug text-zinc-300",children:tk.glabRemoteSuggest}),(0,s.jsx)("button",{type:"button",className:"mt-3 w-fit rounded-lg border border-violet-500/60 bg-violet-600/20 px-3 py-1.5 text-sm text-violet-100 hover:bg-violet-600/35 disabled:opacity-50",disabled:tz||eT||eP,"aria-label":tk.glabRemoteCreate,"aria-describedby":e,onClick:()=>void t4(),children:eT?tk.glabRemoteCreating:tk.glabRemoteCreate})]}):null,(0,s.jsx)(ed,{label:tk.gitRemoteUrl,description:tk.gitRemoteUrlDesc,children:(0,s.jsx)("input",{type:"text",className:el(tz),value:U.gitRemoteUrl,onChange:e=>ae("gitRemoteUrl",e.target.value),disabled:tz,autoComplete:"off"})})]}),(0,s.jsxs)("section",{id:"settings-mongo",className:ex,children:[(0,s.jsx)("h2",{className:"text-xs font-semibold uppercase tracking-wide text-zinc-500",children:tk.sectionMongo}),(0,s.jsx)(ed,{label:tk.mongoEnabled,description:tk.mongoEnabledDesc,children:(0,s.jsx)(ec,{checked:U.mongodbEnabled,onChange:e=>ae("mongodbEnabled",e),disabled:tz,ariaLabel:tk.mongoEnabled})}),(0,s.jsx)(ed,{label:tk.mongoDatabase,description:tk.mongoDatabaseDesc,children:(0,s.jsx)("input",{type:"text",className:el(tz||!U.mongodbEnabled),value:U.mongodbDatabaseName,onChange:e=>ae("mongodbDatabaseName",e.target.value),disabled:tz||!U.mongodbEnabled,autoComplete:"off",spellCheck:!1,"aria-label":tk.mongoDatabase})}),(0,s.jsx)(ed,{label:tk.mongoCollection,description:tk.mongoCollectionDesc,children:(0,s.jsx)("input",{type:"text",className:el(tz||!U.mongodbEnabled),value:U.mongodbCollectionName,onChange:e=>ae("mongodbCollectionName",e.target.value),disabled:tz||!U.mongodbEnabled,autoComplete:"off",spellCheck:!1,"aria-label":tk.mongoCollection})}),(0,s.jsxs)("div",{id:"settings-mongo-connection",className:"scroll-mt-24 border-t border-zinc-800 pt-6",children:[(0,s.jsx)("h3",{className:"text-sm font-medium text-zinc-200",children:tk.sectionMongoConnection}),(0,s.jsx)("p",{className:"mt-1 text-xs leading-relaxed text-zinc-500",children:tk.mongoConnectionIntro}),U.mongodbEnabled?(0,s.jsxs)(s.Fragment,{children:[(0,s.jsxs)("p",{className:"mt-3 text-xs text-zinc-500",children:[tk.mongoRemoteStatus,":"," ","connected"===t$?tk.mongoStatusConnected:"failed"===t$?tk.mongoStatusFailed:tk.mongoStatusPending," \xb7 ",tF?(0,s.jsx)("span",{className:"text-emerald-400/90",children:tk.mongoConnectionResolvableYes}):(0,s.jsx)("span",{className:"text-amber-400/90",children:tk.mongoConnectionResolvableNo})]}),(0,s.jsxs)("div",{className:"mt-3 flex flex-col gap-2 sm:flex-row sm:flex-wrap sm:items-center",children:[(0,s.jsx)("button",{type:"button",className:"w-fit rounded-lg border border-zinc-600 px-3 py-1.5 text-sm text-zinc-200 hover:bg-zinc-800 disabled:opacity-50",disabled:tz||ew||ef||eN,"aria-label":tk.mongoTestConnectionAria,onClick:()=>void t8(tk,U),children:ew?tk.mongoTestRunning:tk.mongoTestConnection}),eZ?(0,s.jsx)("p",{role:"status",className:`text-sm ${"ok"===eZ.tone?"text-emerald-400":"warn"===eZ.tone?"text-amber-400":"text-red-300"}`,children:eZ.text}):null]}),(0,s.jsx)("p",{className:"mt-2 max-w-xl text-xs text-zinc-500",children:tk.mongoTestUsesSavedConfigHint}),(0,s.jsxs)("div",{className:"mt-4 border-t border-zinc-800 pt-4",children:[(0,s.jsx)("h4",{className:"text-xs font-semibold uppercase tracking-wide text-zinc-500",children:tk.mongoSyncSectionTitle}),(0,s.jsx)(h,{t:tw,sync:a?.mongoMirrorSync,mongoEnabled:tO}),(0,s.jsxs)("section",{className:"mt-2 space-y-1 border-t border-zinc-800/80 pt-2","aria-labelledby":"settings-kronosys-workspace-paths",children:[(0,s.jsx)("p",{id:"settings-kronosys-workspace-paths",className:"text-[11px] font-medium text-zinc-500",children:tk.workspaceFoldersLabel}),tG?(0,s.jsx)("p",{className:"text-[11px] text-zinc-500",children:tk.workspaceFoldersEmpty}):tq.length>0?(0,s.jsx)("ul",{className:"list-none space-y-1 font-mono text-[11px] leading-snug text-zinc-400",children:tq.map(e=>(0,s.jsx)("li",{className:"break-all",children:e},e))}):null]}),(0,s.jsx)("button",{type:"button",className:"mt-3 rounded-lg border border-zinc-600 px-3 py-1.5 text-sm text-zinc-200 hover:bg-zinc-800 disabled:opacity-50",disabled:tz||eY||ew||ef||eN||!tO,"aria-label":tk.mongoResyncAriaLabel,onClick:()=>t9(),children:eY?tk.mongoResyncRunning:tk.mongoResyncButton}),(0,s.jsx)("p",{className:"mt-2 max-w-xl text-xs text-zinc-500",children:tk.mongoResyncHint})]})]}):null]}),(0,s.jsx)(ed,{label:tk.mongoHost,description:tk.mongoHostDesc,children:(0,s.jsx)("input",{type:"text",className:el(tz||!U.mongodbEnabled),value:U.mongodbHost,onChange:e=>ae("mongodbHost",e.target.value),disabled:tz||!U.mongodbEnabled,autoComplete:"off",spellCheck:!1,"aria-label":tk.mongoHost})}),(0,s.jsx)(ed,{label:tk.mongoPort,description:tk.mongoPortDesc,children:(0,s.jsx)("input",{type:"number",min:1,max:65535,className:el(tz||!U.mongodbEnabled),value:U.mongodbPort,onChange:e=>ae("mongodbPort",Number(e.target.value)),disabled:tz||!U.mongodbEnabled,"aria-label":tk.mongoPort})}),(0,s.jsx)(ed,{label:tk.mongoUser,description:tk.mongoUserDesc,children:(0,s.jsx)("input",{type:"text",className:el(tz||!U.mongodbEnabled),value:U.mongodbUsername,onChange:e=>ae("mongodbUsername",e.target.value),disabled:tz||!U.mongodbEnabled,autoComplete:"off",spellCheck:!1,"aria-label":tk.mongoUser})}),(0,s.jsx)(ed,{label:tk.mongoAuthSource,description:tk.mongoAuthSourceDesc,children:(0,s.jsx)("input",{type:"text",className:el(tz||!U.mongodbEnabled),value:U.mongodbAuthSource,onChange:e=>ae("mongodbAuthSource",e.target.value),disabled:tz||!U.mongodbEnabled,autoComplete:"off",spellCheck:!1,"aria-label":tk.mongoAuthSource})}),(0,s.jsxs)(ed,{label:tk.mongoPassword,description:tk.mongoPasswordDesc,children:[(0,s.jsx)("p",{className:"mb-2 text-xs text-zinc-400",children:tW?tk.mongoPasswordConfiguredYes:tk.mongoPasswordConfiguredNo}),(0,s.jsx)("input",{type:"password",className:el(tz||eN||ef||!U.mongodbEnabled),value:ej,onChange:e=>ey(e.target.value),disabled:tz||eN||ef||!U.mongodbEnabled,autoComplete:"new-password",placeholder:tW?"••••••••":"","aria-label":tk.mongoPassword}),(0,s.jsxs)("div",{className:"mt-2 flex flex-wrap gap-2",children:[(0,s.jsx)("button",{type:"button",className:"rounded-lg bg-violet-600 px-3 py-1.5 text-sm font-medium text-white hover:bg-violet-500 disabled:opacity-50",disabled:tz||eN||ef||!U.mongodbEnabled,onClick:()=>void t6(ej),children:eN?tk.saving:tk.mongoPasswordSave}),(0,s.jsx)("button",{type:"button",className:"rounded-lg border border-zinc-600 px-3 py-1.5 text-sm text-zinc-300 hover:bg-zinc-800 disabled:opacity-50",disabled:tz||eN||ef||!U.mongodbEnabled,onClick:()=>void t6(""),children:tk.mongoPasswordClear})]})]}),(0,s.jsxs)(ed,{label:tk.mongoManualUri,description:tk.mongoManualUriDesc,children:[(0,s.jsx)("p",{className:"mb-2 text-xs text-zinc-400",children:tU?tk.mongoUriConfiguredYes:tk.mongoUriConfiguredNo}),(0,s.jsx)("input",{type:"password",className:el(tz||ef||eN||!U.mongodbEnabled),value:ep,onChange:e=>ev(e.target.value),disabled:tz||ef||eN||!U.mongodbEnabled,autoComplete:"off",placeholder:tU?"••••••••":"","aria-label":tk.mongoUri}),(0,s.jsx)("p",{className:"mt-1 text-xs text-zinc-500",children:tk.mongoUriDesc}),(0,s.jsxs)("div",{className:"mt-2 flex flex-wrap gap-2",children:[(0,s.jsx)("button",{type:"button",className:"rounded-lg bg-violet-600 px-3 py-1.5 text-sm font-medium text-white hover:bg-violet-500 disabled:opacity-50",disabled:tz||ef||eN||!U.mongodbEnabled,onClick:()=>void t3(ep),children:ef?tk.saving:tk.mongoUriSave}),(0,s.jsx)("button",{type:"button",className:"rounded-lg border border-zinc-600 px-3 py-1.5 text-sm text-zinc-300 hover:bg-zinc-800 disabled:opacity-50",disabled:tz||ef||eN||!U.mongodbEnabled,onClick:()=>void t3(""),children:tk.mongoUriClear})]})]})]}),(0,s.jsxs)("section",{id:"settings-workspace-loc",className:ex,children:[(0,s.jsx)("h2",{className:"text-xs font-semibold uppercase tracking-wide text-zinc-500",children:tk.sectionWorkspaceLoc}),"manager"===U.usageProfile?(0,s.jsx)("p",{className:"mt-2 text-sm text-zinc-500",children:tk.workspaceLocSectionHiddenManager}):(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(ed,{label:tk.workspaceLocExcludedDirs,description:tk.workspaceLocExcludedDirsDesc,children:(0,s.jsx)("textarea",{className:eo(tz),value:U.workspaceLocExcludedDirsText,onChange:e=>ae("workspaceLocExcludedDirsText",e.target.value),disabled:tz,spellCheck:!1,"aria-label":tk.workspaceLocExcludedDirs})}),(0,s.jsx)(ed,{label:tk.workspaceLocExcludedPatterns,description:tk.workspaceLocExcludedPatternsDesc,children:(0,s.jsx)("textarea",{className:eo(tz),value:U.workspaceLocExcludedPathPatternsText,onChange:e=>ae("workspaceLocExcludedPathPatternsText",e.target.value),disabled:tz,spellCheck:!1,"aria-label":tk.workspaceLocExcludedPatterns})})]})]}),(0,s.jsxs)("section",{id:"settings-web",className:ex,children:[(0,s.jsx)("h2",{className:"text-xs font-semibold uppercase tracking-wide text-zinc-500",children:tk.sectionWeb}),(0,s.jsxs)("div",{className:"flex flex-col gap-8 mb-10",children:[(0,s.jsx)(ed,{label:tk.dashboardDisplayTimeZone,description:tk.dashboardDisplayTimeZoneDesc,children:(0,s.jsx)("select",{className:el(tz),value:U.dashboardDisplayTimeZone,onChange:e=>ae("dashboardDisplayTimeZone",e.target.value),disabled:tz,children:D.U$.map(e=>(0,s.jsx)("option",{value:e.id,children:"fr"===tv?e.labelFr:e.labelEn},e.id))})}),(0,s.jsx)(ed,{label:tk.dashboardClockFormat,description:tk.dashboardClockFormatDesc,children:(0,s.jsxs)("div",{className:"flex flex-wrap items-center gap-4",children:[(0,s.jsxs)("label",{className:"flex items-center gap-2 text-sm text-zinc-700 dark:text-zinc-300",children:[(0,s.jsx)("input",{type:"radio",name:"dashboardUse24HourClock",checked:!1===U.dashboardUse24HourClock,onChange:()=>ae("dashboardUse24HourClock",!1),disabled:tz,className:"h-4 w-4 accent-violet-600"}),tk.dashboardClock12hOption]}),(0,s.jsxs)("label",{className:"flex items-center gap-2 text-sm text-zinc-700 dark:text-zinc-300",children:[(0,s.jsx)("input",{type:"radio",name:"dashboardUse24HourClock",checked:!0===U.dashboardUse24HourClock,onChange:()=>ae("dashboardUse24HourClock",!0),disabled:tz,className:"h-4 w-4 accent-violet-600"}),tk.dashboardClock24hOption]})]})}),(0,s.jsx)(ed,{label:tk.dashboardLightThemeVariant,description:tk.dashboardLightThemeVariantDesc,children:(0,s.jsx)("div",{className:"flex flex-wrap gap-2",role:"radiogroup","aria-label":tk.dashboardLightThemeVariant,children:[["warm",tk.dashboardLightThemeWarm],["soft",tk.dashboardLightThemeSoft],["contrast",tk.dashboardLightThemeContrast]].map(([e,t])=>(0,s.jsxs)("label",{className:"flex cursor-pointer items-center gap-2 rounded-lg border border-zinc-300 px-3 py-2 text-sm text-zinc-700 has-[:checked]:border-violet-500/60 has-[:checked]:bg-violet-50 dark:border-zinc-600 dark:text-zinc-300 dark:has-[:checked]:border-violet-500/60 dark:has-[:checked]:bg-violet-950/35",children:[(0,s.jsx)("input",{type:"radio",name:"dashboardLightThemeVariant",value:e,checked:U.dashboardLightThemeVariant===e,onChange:()=>{ae("dashboardLightThemeVariant",e),G.e.getState().setLightThemeVariant(e),(0,q.jW)(e)},disabled:tz,className:"h-4 w-4 accent-violet-600"}),t]},e))})}),(0,s.jsx)(ed,{label:tk.dashboardSemanticChipAccessibleMode,description:tk.dashboardSemanticChipAccessibleModeDesc,children:(0,s.jsx)(em,{checked:U.dashboardSemanticChipAccessibleMode,onChange:e=>{ae("dashboardSemanticChipAccessibleMode",e),G.e.getState().setSemanticChipAccessible(e),(0,V._u)(e)},disabled:tz,ariaLabel:tk.dashboardSemanticChipAccessibleMode})}),(0,s.jsx)(ed,{label:tk.dashboardCalendarWeekStartsOn,description:tk.dashboardCalendarWeekStartsOnDesc,children:(0,s.jsx)("div",{className:"flex flex-wrap gap-2",role:"radiogroup","aria-label":tk.dashboardCalendarWeekStartsOn,children:[["sunday",tk.calendarWeekStartsSunday],["monday",tk.calendarWeekStartsMonday],["saturday",tk.calendarWeekStartsSaturday]].map(([e,t])=>(0,s.jsxs)("label",{className:"flex cursor-pointer items-center gap-2 rounded-lg border border-zinc-300 px-3 py-2 text-sm text-zinc-700 has-[:checked]:border-violet-500/60 has-[:checked]:bg-violet-50 dark:border-zinc-600 dark:text-zinc-300 dark:has-[:checked]:border-violet-500/60 dark:has-[:checked]:bg-violet-950/35",children:[(0,s.jsx)("input",{type:"radio",name:"dashboardCalendarWeekStartsOn",value:e,checked:U.dashboardCalendarWeekStartsOn===e,onChange:()=>ae("dashboardCalendarWeekStartsOn",e),disabled:tz,className:"h-4 w-4 accent-violet-600"}),t]},e))})}),(0,s.jsx)("div",{id:"settings-default-session-name",className:"scroll-mt-24",children:(0,s.jsx)(ed,{label:tk.dashboardDefaultSessionNameTemplate,description:tk.dashboardDefaultSessionNameTemplateDesc,children:(0,s.jsx)("input",{type:"text",className:el(tz),value:U.dashboardDefaultSessionNameTemplate,onChange:e=>ae("dashboardDefaultSessionNameTemplate",e.target.value.slice(0,400)),disabled:tz,spellCheck:!1,autoComplete:"off",placeholder:"Session %F %UUID","aria-label":tk.dashboardDefaultSessionNameTemplate})})})]}),(0,s.jsxs)("div",{id:"settings-dashboard-tour",className:"scroll-mt-24 mb-8 rounded-xl border border-zinc-200 bg-zinc-50/80 p-4 dark:border-zinc-700 dark:bg-zinc-900/50",children:[(0,s.jsx)("h3",{className:"text-sm font-semibold text-zinc-900 dark:text-zinc-100",children:tk.dashboardTourBlockTitle}),(0,s.jsx)("p",{className:"mt-2 text-sm leading-relaxed text-zinc-600 dark:text-zinc-400",children:tk.dashboardTourBlockIntro}),(0,s.jsx)(i(),{href:"/?tour=replay",className:"mt-4 inline-flex items-center justify-center rounded-lg border border-violet-500/50 bg-violet-500/10 px-4 py-2 text-sm font-medium text-violet-800 transition hover:border-violet-500/75 hover:bg-violet-500/18 dark:border-violet-400/45 dark:bg-violet-600/20 dark:text-violet-100 dark:hover:border-violet-400/60 dark:hover:bg-violet-600/30",children:tk.dashboardTourReplayLinkLabel}),(0,s.jsx)("button",{type:"button",className:"mt-4 ml-3 inline-flex items-center justify-center rounded-lg border border-zinc-500/50 bg-zinc-500/10 px-4 py-2 text-sm font-medium text-zinc-800 transition hover:border-zinc-500/75 hover:bg-zinc-500/18 dark:border-zinc-400/45 dark:bg-zinc-600/20 dark:text-zinc-100 dark:hover:border-zinc-400/60 dark:hover:bg-zinc-600/30",onClick:()=>{F.r.getState().resetDashboard(),F.r.getState().resetSettings(),tm(!0)},children:tw.tourUndismissBtn})]}),(0,s.jsxs)("div",{id:"settings-dashboard-column-hints",className:"scroll-mt-24 mb-8 rounded-xl border border-zinc-200 bg-zinc-50/80 p-4 dark:border-zinc-700 dark:bg-zinc-900/50",children:[(0,s.jsx)("h3",{className:"text-sm font-semibold text-zinc-900 dark:text-zinc-100",children:tk.dashboardColumnHintsBlockTitle}),(0,s.jsx)("p",{className:"mt-2 text-sm leading-relaxed text-zinc-600 dark:text-zinc-400",children:tk.dashboardColumnHintsBlockIntro}),(0,s.jsxs)("div",{className:"mt-4 flex flex-wrap items-center gap-x-3 gap-y-2",children:[(0,s.jsx)("button",{type:"button",className:"inline-flex items-center justify-center rounded-lg border border-zinc-500/50 bg-zinc-500/10 px-4 py-2 text-sm font-medium text-zinc-800 transition hover:border-zinc-500/75 hover:bg-zinc-500/18 dark:border-zinc-400/45 dark:bg-zinc-600/20 dark:text-zinc-100 dark:hover:border-zinc-400/60 dark:hover:bg-zinc-600/30",onClick:tC,children:tk.dashboardColumnHintsRestoreBtn}),e_?(0,s.jsx)("span",{className:"text-sm text-emerald-600 dark:text-emerald-400",role:"status",children:tk.dashboardColumnHintsRestoreDone}):null]})]}),(0,s.jsxs)("div",{id:"settings-reporting-tour",className:"scroll-mt-24 mb-8 rounded-xl border border-zinc-200 bg-zinc-50/80 p-4 dark:border-zinc-700 dark:bg-zinc-900/50",children:[(0,s.jsx)("h3",{className:"text-sm font-semibold text-zinc-900 dark:text-zinc-100",children:tk.reportingTourBlockTitle}),(0,s.jsx)("p",{className:"mt-2 text-sm leading-relaxed text-zinc-600 dark:text-zinc-400",children:tk.reportingTourBlockIntro}),(0,s.jsx)(i(),{href:"/reporting?tour=replay",className:"mt-4 inline-flex items-center justify-center rounded-lg border border-violet-500/50 bg-violet-500/10 px-4 py-2 text-sm font-medium text-violet-800 transition hover:border-violet-500/75 hover:bg-violet-500/18 dark:border-violet-400/45 dark:bg-violet-600/20 dark:text-violet-100 dark:hover:border-violet-400/60 dark:hover:bg-violet-600/30",children:tk.reportingTourReplayLinkLabel})]}),(0,s.jsxs)(ed,{label:tk.localApiPort,description:tk.localApiPortDesc,children:[(0,s.jsx)("input",{type:"number",min:1024,max:65535,className:el(tz),value:U.localApiPort,onChange:e=>ae("localApiPort",Number(e.target.value)),disabled:tz}),(0,s.jsx)("p",{className:"mt-2 text-xs text-amber-200/80",children:tk.hintPortRestart})]}),(0,s.jsxs)(ed,{label:tk.dashboardWebUrl,description:tk.dashboardWebUrlDesc,children:[(0,s.jsx)("input",{type:"url",className:el(tz),value:U.dashboardWebUrl,onChange:e=>ae("dashboardWebUrl",e.target.value),disabled:tz}),(0,s.jsx)("p",{className:"mt-2 text-xs text-zinc-500",children:tk.hintDashboardUrl})]}),(0,s.jsx)("div",{id:"settings-session-duration-alert",className:"scroll-mt-24",children:(0,s.jsx)(ed,{label:tk.dashboardSessionDurationAlertHours,description:tk.dashboardSessionDurationAlertHoursDesc,children:(0,s.jsx)("input",{type:"number",min:1,max:8760,className:el(tz),value:U.dashboardSessionDurationAlertHours,onChange:e=>ae("dashboardSessionDurationAlertHours",Number(e.target.value)),disabled:tz,"aria-label":tk.dashboardSessionDurationAlertHours})})})]}),(0,s.jsxs)("section",{id:"settings-archived-sessions",className:ex,children:[(0,s.jsx)("h2",{className:"text-xs font-semibold uppercase tracking-wide text-zinc-500",children:tk.sectionArchivedSessions}),(0,s.jsx)("p",{className:"text-xs leading-relaxed text-zinc-500",children:tk.archivedSessionsIntro}),(0,s.jsx)("ul",{className:"mt-4 divide-y divide-zinc-800 rounded-lg border border-zinc-800",children:0===tL?(0,s.jsx)("li",{className:"px-3 py-8 text-center text-sm text-zinc-500",children:tw.archivesEmpty}):tH.map(e=>{let t=e.sessionName?.trim()||e.sessionId.slice(0,8),a=("string"==typeof e.sessionNote?e.sessionNote.trim():"").replaceAll(/\s+/g," "),n=a.length>0,r=(e.tasks?.length??0)+(Array.isArray(e.activeTasks)&&e.activeTasks.length>0?e.activeTasks.length:+!!e.activeTask),i=e3===e.sessionId;return(0,s.jsxs)("li",{className:"flex items-center justify-between gap-2 px-3 py-2.5 hover:bg-zinc-800/40",children:[(0,s.jsxs)("div",{className:"min-w-0 flex-1",children:[(0,s.jsx)("div",{className:"truncate font-medium text-zinc-200",children:t}),(0,s.jsxs)("div",{className:"text-[0.7rem] text-zinc-500",children:[r," ",(0,x.r)(r,tw,tv)]}),n?(0,s.jsxs)("div",{className:"mt-1 inline-flex min-w-0 max-w-full items-center gap-1 text-[0.7rem] text-zinc-500",title:a,children:[(0,s.jsx)(ea.A,{size:12,className:"shrink-0","aria-hidden":!0}),(0,s.jsx)("span",{className:"truncate",children:a})]}):null]}),(0,s.jsx)("button",{type:"button",disabled:i||tz,className:"shrink-0 rounded-lg border border-violet-600/50 px-3 py-1.5 text-sm text-violet-200 hover:bg-violet-950/40 disabled:cursor-not-allowed disabled:opacity-50",onClick:()=>void at(e.sessionId),children:tw.sessionRestoreBtn})]},e.sessionId)})}),tL>10?(0,s.jsxs)("nav",{className:"mt-3 flex flex-wrap items-center justify-between gap-2","aria-label":tk.archivesPaginationNavAria,children:[(0,s.jsx)("button",{type:"button",disabled:tM<=0||tz,className:"rounded-lg border border-zinc-600 px-3 py-1.5 text-sm text-zinc-300 hover:bg-zinc-800 disabled:cursor-not-allowed disabled:opacity-40",onClick:()=>e4(e=>Math.max(0,e-1)),children:tk.archivesPaginationPrev}),(0,s.jsx)("span",{className:"text-xs tabular-nums text-zinc-500",children:tk.archivesPaginationRange.replace("{from}",String(0===tL?0:tI+1)).replace("{to}",String(tR)).replace("{total}",String(tL))}),(0,s.jsx)("button",{type:"button",disabled:tM>=tA||tz,className:"rounded-lg border border-zinc-600 px-3 py-1.5 text-sm text-zinc-300 hover:bg-zinc-800 disabled:cursor-not-allowed disabled:opacity-40",onClick:()=>e4(e=>Math.min(tA,e+1)),children:tk.archivesPaginationNext})]}):tL>0?(0,s.jsx)("p",{className:"mt-2 text-xs tabular-nums text-zinc-500",children:tk.archivesPaginationRange.replace("{from}",String(tI+1)).replace("{to}",String(tR)).replace("{total}",String(tL))}):null]}),(0,s.jsxs)("section",{id:"settings-danger-zone",className:ex,children:[(0,s.jsx)("h2",{className:"text-xs font-semibold uppercase tracking-wide text-red-700 dark:text-red-400/95",children:tk.sectionDangerZone}),(0,s.jsxs)("div",{className:"max-w-xl rounded-xl border border-red-300/90 bg-red-50/80 p-4 dark:border-red-900/55 dark:bg-red-950/30",children:[(0,s.jsx)("h3",{className:"text-sm font-semibold text-red-900 dark:text-red-200",children:tk.dangerBackupRestoreTitle}),(0,s.jsx)("p",{className:"mt-2 text-xs leading-relaxed text-red-900/85 dark:text-red-200/85",children:tk.dangerBackupRestoreIntro}),(0,s.jsxs)("div",{className:"mt-3 flex flex-wrap gap-2",children:[(0,s.jsx)("a",{href:"/api/backup?format=json",download:!0,className:"rounded-lg border border-red-500/70 px-3 py-1.5 text-xs font-medium text-red-900 hover:bg-red-100 dark:text-red-200 dark:hover:bg-red-900/40",children:tk.dangerClearHistoryBackupJson}),(0,s.jsx)("a",{href:"/api/backup?format=csv-zip",download:!0,className:"rounded-lg border border-red-500/70 px-3 py-1.5 text-xs font-medium text-red-900 hover:bg-red-100 dark:text-red-200 dark:hover:bg-red-900/40",children:tk.dangerClearHistoryBackupCsvZip}),(0,s.jsx)("a",{href:"/api/backup?format=sqlite",download:!0,className:"rounded-lg border border-red-500/70 px-3 py-1.5 text-xs font-medium text-red-900 hover:bg-red-100 dark:text-red-200 dark:hover:bg-red-900/40",children:tk.dangerClearHistoryBackupSqlite})]}),(0,s.jsxs)("div",{className:"mt-4 space-y-2",children:[(0,s.jsx)("label",{className:"block text-xs font-medium text-red-900/90 dark:text-red-200/90",children:tk.dangerRestorePickFile}),(0,s.jsx)("input",{ref:tl,type:"file",accept:".json,.sqlite,.db,application/json,application/vnd.sqlite3",disabled:ts||e7,className:"block w-full rounded-lg border border-red-300 bg-white px-3 py-2 text-xs text-zinc-800 file:mr-3 file:rounded file:border-0 file:bg-red-100 file:px-2.5 file:py-1 file:text-xs file:font-medium file:text-red-900 dark:border-red-900/60 dark:bg-zinc-950 dark:text-zinc-200 dark:file:bg-red-900/35 dark:file:text-red-200",onChange:e=>{ti(e.target.files?.[0]??null)}}),(0,s.jsx)("p",{className:"text-[11px] leading-relaxed text-red-900/80 dark:text-red-300/80",children:tk.dangerRestoreHint}),(0,s.jsx)("button",{type:"button",disabled:!tr||ts||e7,className:"rounded-lg border border-red-600/80 bg-red-700 px-3 py-1.5 text-xs font-medium text-white hover:bg-red-600 disabled:cursor-not-allowed disabled:opacity-50 dark:border-red-500 dark:bg-red-800/90 dark:hover:bg-red-700",onClick:()=>ta(!0),children:ts?tk.dangerRestoreBusy:tk.dangerRestoreButton})]}),(0,s.jsx)("h3",{className:"text-sm font-semibold text-red-900 dark:text-red-200",children:tk.dangerClearHistoryTitle}),(0,s.jsx)("p",{className:"mt-2 text-xs leading-relaxed text-red-900/85 dark:text-red-200/85",children:tk.dangerClearHistoryBodyIntro}),(0,s.jsx)("ul",{className:"mt-2 list-disc space-y-1.5 pl-5 text-xs leading-relaxed text-red-900/85 dark:text-red-200/85",children:tk.dangerClearHistoryBodyBullets.map(e=>(0,s.jsx)("li",{children:e},e))}),(0,s.jsx)("p",{className:"mt-2 text-xs leading-relaxed text-red-900/85 dark:text-red-200/85",children:tk.dangerClearHistoryBodyAfterList1}),(0,s.jsx)("p",{className:"mt-2 text-xs leading-relaxed text-red-900/85 dark:text-red-200/85",children:tk.dangerClearHistoryBodyAfterList2}),(0,s.jsx)("button",{type:"button",className:"mt-4 rounded-lg border border-red-600/80 bg-red-600 px-4 py-2 text-sm font-medium text-white hover:bg-red-500 dark:border-red-500 dark:bg-red-800/90 dark:hover:bg-red-700",onClick:()=>e9(!0),children:tk.dangerClearHistoryButton})]})]})]})]}):null]}),(0,s.jsx)(b.qS,{open:null!==eX,message:eX??"",okLabel:tk.dialogOkBtn,onClose:()=>e0(null)}),(0,s.jsx)(b.qR,{open:e5,message:tk.mongoResyncConfirm,cancelLabel:tk.dialogCancelBtn,confirmLabel:tk.dialogConfirmBtn,onCancel:()=>e2(!1),onConfirm:()=>void t7()}),(0,s.jsx)(b.qR,{open:tt,title:tk.dangerRestoreButton,message:tk.dangerRestoreConfirm,cancelLabel:tk.dialogCancelBtn,confirmLabel:tk.dialogConfirmBtn,confirmVariant:"danger",pending:ts,onCancel:()=>{ts||ta(!1)},onConfirm:()=>{as()}}),(0,s.jsx)(b.qR,{open:e8,title:tk.dangerClearHistoryTitle,message:tk.dangerClearHistoryConfirm,cancelLabel:tk.dialogCancelBtn,confirmLabel:tk.dialogConfirmBtn,confirmVariant:"danger",extra:tE,pending:e7,typeToConfirm:{expected:tk.dangerClearHistoryConfirmPhrase,instruction:tk.dangerClearHistoryTypeInstruction.replace("{phrase}",tk.dangerClearHistoryConfirmPhrase),label:tk.dangerClearHistoryTypeFieldLabel,inputAriaLabel:tk.dangerClearHistoryTypeInputAria},onCancel:()=>{e7||e9(!1)},onConfirm:()=>{aa()}}),(0,s.jsx)(b.qR,{open:X,title:tk.resetToDefaults,message:tk.resetToDefaultsConfirm,cancelLabel:tk.dialogCancelBtn,confirmLabel:tk.dialogConfirmBtn,onCancel:()=>{eb||eh(!1)},onConfirm:()=>{eh(!1),an()}}),(0,s.jsx)(L.n,{ariaLabel:tk.scrollToTopAria}),(0,s.jsx)(W,{open:tc,onOpenChange:tm,dt:tw})]})}function eb(){return(0,s.jsx)(n.Suspense,{fallback:(0,s.jsx)("div",{className:"min-h-screen bg-zinc-100 px-6 py-10 text-sm text-zinc-500 dark:bg-zinc-900",children:"Kronosys…"}),children:(0,s.jsx)(eh,{})})}},4747:(e,t,a)=>{"use strict";a.d(t,{r:()=>l});var s=a(1934),n=a(9311);let r={dashboard:"kronosys.dashboard.tour.completed.v1",settings:"kronosys.settings.tour.completed.v1",reporting:"kronosys.reporting.tour.completed.v1"},i="kronosys.dashboard.tours.v2";!function(){if(window.localStorage.getItem(i))return;let e={},t=!1;for(let[a,s]of Object.entries(r))if("1"===window.localStorage.getItem(s)){e[a]=!0,t=!0;try{window.localStorage.removeItem(s)}catch{}}if(t)try{window.localStorage.setItem(i,JSON.stringify({state:e,version:0}))}catch{}}();let l=(0,s.v)()((0,n.Zr)(e=>({dashboard:!1,settings:!1,reporting:!1,markDashboardCompleted:()=>e({dashboard:!0}),markSettingsCompleted:()=>e({settings:!0}),markReportingCompleted:()=>e({reporting:!0}),resetDashboard:()=>e({dashboard:!1}),resetSettings:()=>e({settings:!1}),resetReporting:()=>e({reporting:!1})}),{name:i,partialize:e=>({dashboard:e.dashboard,settings:e.settings,reporting:e.reporting})}))},7856:(e,t,a)=>{"use strict";a.d(t,{p:()=>d});var s=a(5155),n=a(2115),r=a(7650),i=a(4961),l=a(1908);let o={position:"fixed",top:0,left:0,width:288,zIndex:80,visibility:"hidden",pointerEvents:"none"};function d({ariaLabel:e,body:t,align:a="start",preserveLineBreaks:c=!1,panelClassName:m}){let[x,u]=(0,n.useState)(!1),h=(0,n.useRef)(null),b=(0,n.useRef)(null),g=(0,n.useId)(),p=(0,l.l)(x,h,b,{align:a,maxWidthRem:m?24:18});(0,n.useEffect)(()=>{if(!x)return;let e=e=>{let t=e.target;h.current?.contains(t)||b.current?.contains(t)||u(!1)};return document.addEventListener("mousedown",e),()=>document.removeEventListener("mousedown",e)},[x]);let v=p??(x?o:void 0),f=x&&"u">typeof document&&v?(0,r.createPortal)((0,s.jsx)("div",{ref:b,id:`${g}-metric-help`,style:v,className:`rounded-lg border border-zinc-200 bg-white p-2.5 text-left shadow-lg normal-case dark:border-zinc-600 dark:bg-zinc-900${m?` ${m}`:""}`,role:"region","aria-label":e,children:(0,s.jsx)("p",{className:`text-[0.7rem] leading-snug text-zinc-700 dark:text-zinc-300${c?" whitespace-pre-line":""} ${!m?"max-w-full":""}`,children:t})}),document.body):null;return(0,s.jsxs)("div",{className:"relative inline-flex shrink-0",ref:h,children:[(0,s.jsx)("button",{type:"button",className:"rounded p-0.5 text-zinc-500 hover:bg-zinc-200/90 hover:text-zinc-800 dark:hover:bg-zinc-800 dark:hover:text-zinc-300","aria-label":e,"aria-expanded":x?"true":"false","aria-controls":`${g}-metric-help`,onClick:()=>u(e=>!e),children:(0,s.jsx)(i.A,{size:13,strokeWidth:1.75,"aria-hidden":!0})}),f]})}},8090:(e,t,a)=>{"use strict";a.d(t,{v:()=>o});var s=a(5155),n=a(6296),r=a(4755),i=a(1958),l=a(4897);function o({phase:e,dt:t,lang:a,technicalDetail:d,onRetry:c,retryBusy:m}){let x="loading"===e,u=(0,l.iM)(d,a),h="string"==typeof d?d.trim():"",b=h.length>0&&"string"==typeof u&&h!==u;return(0,s.jsx)("div",{className:"fixed inset-0 z-[60] flex items-center justify-center bg-zinc-200/55 backdrop-blur-sm dark:bg-black/45",role:"status","aria-live":"polite","aria-busy":x?"true":"false","aria-label":x?t.dashboardLoadingAriaLabel:t.dashboardConnectionErrorAriaLabel,children:(0,s.jsxs)("div",{className:"flex min-h-[10.5rem] max-w-sm flex-col items-center justify-center gap-4 rounded-2xl border border-zinc-200/90 bg-white/95 px-10 py-9 shadow-2xl dark:border-zinc-600/60 dark:bg-zinc-900/95",children:[x?(0,s.jsx)(n.A,{className:"size-12 shrink-0 animate-spin text-violet-600 dark:text-violet-400",strokeWidth:2,"aria-hidden":!0}):(0,s.jsx)(r.A,{className:"size-12 shrink-0 text-amber-600 dark:text-amber-400",strokeWidth:2,"aria-hidden":!0}),(0,s.jsxs)("div",{className:"flex min-h-[2.75rem] flex-col items-center justify-center gap-2 text-center",children:[(0,s.jsx)("p",{className:"text-sm font-medium leading-snug text-zinc-800 dark:text-zinc-100",children:x?t.dashboardLoadingMessage:t.dashboardConnectionErrorTitle}),x?null:(0,s.jsx)("p",{className:"max-w-[22rem] text-sm leading-snug text-zinc-600 dark:text-zinc-300",children:t.dashboardConnectionErrorBody}),!x&&u?(0,s.jsx)("p",{className:"max-w-[22rem] text-xs leading-snug text-zinc-500 dark:text-zinc-400",children:u}):null]}),!x&&c?(0,s.jsxs)("button",{type:"button",className:"mt-1 inline-flex items-center justify-center gap-2 rounded-lg bg-violet-600 px-4 py-2 text-sm font-medium text-white hover:bg-violet-500 focus:outline-none focus-visible:ring-2 focus-visible:ring-violet-400 focus-visible:ring-offset-2 focus-visible:ring-offset-white disabled:cursor-wait disabled:opacity-70 dark:focus-visible:ring-offset-zinc-900",onClick:c,disabled:!0===m,children:[(0,s.jsx)(i.A,{className:`size-4 shrink-0 ${m?"animate-spin":""}`,"aria-hidden":!0}),t.dashboardConnectionRetryLabel]}):null,!x&&b?(0,s.jsxs)("details",{className:"mt-2 max-w-sm text-left",children:[(0,s.jsx)("summary",{className:"cursor-pointer text-xs text-zinc-500 hover:text-zinc-700 dark:text-zinc-400 dark:hover:text-zinc-200",children:t.dashboardConnectionTechnicalDetailsLabel}),(0,s.jsx)("pre",{className:"mt-2 max-h-32 overflow-auto rounded-md border border-zinc-200/80 bg-zinc-50/90 px-3 py-2 text-[0.65rem] leading-relaxed text-zinc-700 dark:border-zinc-600/50 dark:bg-zinc-950/80 dark:text-zinc-300",children:d})]}):null]})})}}},e=>{e.O(0,[555,558,227,569,840,702,441,794,358],()=>e(e.s=434)),_N_E=e.O()}]);