claude-code-session-manager 0.142.0 → 0.143.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude-plugin/marketplace.json +1 -1
- package/README.md +20 -107
- package/dist/assets/{AppSettings-BcZgIvvY.js → AppSettings-BO4jDVGO.js} +1 -1
- package/dist/assets/{History-DpZuJXi1.js → History-DTttbvPb.js} +1 -1
- package/dist/assets/{HomeClaudeConfig-D32ZJtU-.js → HomeClaudeConfig-DADP5bfn.js} +2 -2
- package/dist/assets/{Panel-BjdJjhqt.js → Panel-B_D4Bg7L.js} +1 -1
- package/dist/assets/{ProjectClaudeConfig-BTClYV6i.js → ProjectClaudeConfig-DPnDJKcr.js} +1 -1
- package/dist/assets/{Scheduler-DPobKx1Z.js → Scheduler-CNLjn90m.js} +8 -8
- package/dist/assets/{SkillReferenceGraph-Cqyu4mef.js → SkillReferenceGraph-D1b2aiol.js} +1 -1
- package/dist/assets/{Skills-vv0noNVI.js → Skills-cfV7sgk6.js} +1 -1
- package/dist/assets/{TiptapBody-CXi8Pvut.js → TiptapBody-DVXtEIVy.js} +1 -1
- package/dist/assets/{Toggle-CiYCWLjh.js → Toggle-CYajnSdx.js} +1 -1
- package/dist/assets/{VoiceButton-4NKKd1sC.js → VoiceButton-DJ4gGRuE.js} +1 -1
- package/dist/assets/{historyTotals-DDunb8Ch.js → historyTotals-D3MoHY2U.js} +1 -1
- package/dist/assets/{index-Cn5E9958.js → index-CdTppjKR.js} +436 -436
- package/dist/index.html +1 -1
- package/dist-web/app.js +356 -356
- package/package.json +3 -3
- package/plugins/session-manager-dev/.claude-plugin/plugin.json +1 -1
- package/plugins/session-manager-dev/skills/builder/SKILL.md +5 -0
- package/plugins/session-manager-dev/skills/develop/SKILL.md +9 -3
- package/scripts/README.md +1 -0
- package/scripts/scheduler-mcp-server.cjs +304 -6
- package/src/main/adminRouteRegistry.cjs +10 -0
- package/src/main/build-info.json +4 -4
- package/src/main/chatRunner.cjs +105 -7
- package/src/main/config.cjs +5 -1
- package/src/main/health.cjs +38 -2
- package/src/main/index.cjs +12 -4
- package/src/main/ipcSchemas.cjs +11 -0
- package/src/main/lib/demo-video-kit/cast.md +10 -1
- package/src/main/lib/demo-video-kit/character.cjs +77 -21
- package/src/main/lib/demo-video-kit/kind-tiktok.md +5 -1
- package/src/main/lib/demo-video-kit/projectSounds.cjs +191 -0
- package/src/main/lib/demo-video-kit/seedKit.cjs +3 -3
- package/src/main/lib/demo-video-kit/sound.cjs +166 -9
- package/src/main/lib/demo-video-kit/standalone.cjs +231 -0
- package/src/main/lib/epic/activeIndexMerge.cjs +5 -0
- package/src/main/lib/epic/artifactRetention.cjs +55 -9
- package/src/main/lib/epic/artifactStore.cjs +78 -35
- package/src/main/lib/epic/delegationReadiness.cjs +10 -3
- package/src/main/lib/epic/epicEventLog.cjs +45 -1
- package/src/main/lib/epic/epicStateEmitter.cjs +248 -0
- package/src/main/lib/epic/epicValidationHook.cjs +13 -2
- package/src/main/lib/externalContract.cjs +12 -1
- package/src/main/lib/feedback-remote/autoStartedSession.cjs +1 -1
- package/src/main/lib/feedback-remote/crossProjectReply.cjs +96 -8
- package/src/main/lib/feedback-remote/macroAdminRoutes.cjs +30 -0
- package/src/main/lib/feedback-remote/pendingReplies.cjs +18 -0
- package/src/main/lib/feedback-remote/projectHomeAdminRoutes.cjs +94 -4
- package/src/main/lib/feedback-remote/replyClaims.cjs +159 -0
- package/src/main/lib/git/gitWorktree.cjs +8 -0
- package/src/main/lib/git/runtimeStateUntrack.cjs +15 -1
- package/src/main/lib/git/worktreeDeps.cjs +113 -10
- package/src/main/lib/mcpToolCatalog.cjs +102 -8
- package/src/main/lib/opsOwnership.cjs +113 -28
- package/src/main/lib/persona-macro/shippedPersonaSeeds.cjs +46 -0
- package/src/main/lib/prd/prdCreate.cjs +350 -227
- package/src/main/lib/prd/prdCriteria.cjs +7 -4
- package/src/main/lib/project-pages/videoPressLines.cjs +145 -0
- package/src/main/lib/project-pages/videoScriptPress.cjs +260 -0
- package/src/main/lib/project-pages/videoScriptRunRoute.cjs +351 -0
- package/src/main/lib/project-pages/videoScriptSwitchIpc.cjs +49 -0
- package/src/main/lib/project-pages/videoScriptSwitchRoute.cjs +173 -0
- package/src/main/lib/scheduler/criteriaChecks.cjs +164 -20
- package/src/main/lib/scheduler/heldSchedulerTurns.cjs +238 -0
- package/src/main/lib/scheduler/jobMemoryStats.cjs +13 -2
- package/src/main/lib/scheduler/planRecordHarvest.cjs +120 -52
- package/src/main/lib/scheduler/prdOutcomeRecord.cjs +60 -2
- package/src/main/lib/scheduler/queueStore.cjs +16 -0
- package/src/main/lib/scheduler/rcaReport.cjs +79 -15
- package/src/main/lib/scheduler/scheduleJobSchema.cjs +13 -0
- package/src/main/lib/scheduler/schedulerPaths.cjs +9 -0
- package/src/main/lib/scheduler/slotsRoute.cjs +101 -87
- package/src/main/lib/scheduler/usageHoldRoute.cjs +97 -0
- package/src/main/lib/scheduler/validatorVerdictSchema.cjs +16 -5
- package/src/main/lib/tasks/memoryConsolidation.cjs +14 -2
- package/src/main/lib/tasks/mitigationReview.cjs +21 -1
- package/src/main/lib/tasks/taskAdminRoutes.cjs +78 -3
- package/src/main/lib/tasks/taskLedger.cjs +2 -2
- package/src/main/lib/telemetry/auditEvents.cjs +21 -24
- package/src/main/lib/telemetry/auditLog.cjs +6 -2
- package/src/main/lib/util/atomicFs.cjs +2 -2
- package/src/main/promptSessionEvents.cjs +16 -1
- package/src/main/pty.cjs +11 -2
- package/src/main/queueOps.cjs +1 -1
- package/src/main/runVerify.cjs +1 -1
- package/src/main/scheduler/utilizationHold.cjs +96 -6
- package/src/main/scheduler.cjs +533 -39
- package/src/main/templates/PRD_AUTHORING.md +7 -2
- package/src/preload/api.d.ts +47 -1
- package/src/preload/apiSurface.json +14 -0
- package/src/preload/index.cjs +2 -0
- package/src/seed/agents/demo-video-builder.md +15 -8
- package/src/seed/agents/validator.md +20 -19
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{aS as Z,R as wo,az as ko,aC as tr}from"./index-
|
|
1
|
+
import{aS as Z,R as wo,az as ko,aC as tr}from"./index-CdTppjKR.js";import"./monaco-editor-BsIlgG7c.js";function Ao(e,n){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var i,o,a,s,u=[],l=!0,f=!1;try{if(a=(r=r.call(e)).next,n===0){if(Object(r)!==r)return;l=!1}else for(;!(l=(i=a.call(r)).done)&&(u.push(i.value),u.length!==n);l=!0);}catch(h){f=!0,o=h}finally{try{if(!l&&r.return!=null&&(s=r.return(),Object(s)!==s))return}finally{if(f)throw o}}return u}}function Co(e,n,r){return n=zo(n),n in e?Object.defineProperty(e,n,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[n]=r,e}function er(e,n){return To(e)||Ao(e,n)||ci(e,n)||Eo()}function So(e){return Mo(e)||Po(e)||ci(e)||Oo()}function Mo(e){if(Array.isArray(e))return gn(e)}function To(e){if(Array.isArray(e))return e}function Po(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function ci(e,n){if(e){if(typeof e=="string")return gn(e,n);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return gn(e,n)}}function gn(e,n){(n==null||n>e.length)&&(n=e.length);for(var r=0,i=new Array(n);r<n;r++)i[r]=e[r];return i}function Oo(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
2
2
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Eo(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
3
3
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ro(e,n){if(typeof e!="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var i=r.call(e,n);if(typeof i!="object")return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return(n==="string"?String:Number)(e)}function zo(e){var n=Ro(e,"string");return typeof n=="symbol"?n:String(n)}var No=function(n,r){var i=new Set(r);return Object.assign.apply(Object,[{}].concat(So(Object.entries(n).filter(function(o){var a=er(o,1),s=a[0];return!i.has(s)}).map(function(o){var a=er(o,2),s=a[0],u=a[1];return Co({},s,u)}))))};function yn(e,n){(n==null||n>e.length)&&(n=e.length);for(var r=0,i=Array(n);r<n;r++)i[r]=e[r];return i}function Io(e){if(Array.isArray(e))return e}function $o(e){if(Array.isArray(e))return yn(e)}function Do(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function jo(e,n){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var i,o,a,s,u=[],l=!0,f=!1;try{if(a=(r=r.call(e)).next,n!==0)for(;!(l=(i=a.call(r)).done)&&(u.push(i.value),u.length!==n);l=!0);}catch(h){f=!0,o=h}finally{try{if(!l&&r.return!=null&&(s=r.return(),Object(s)!==s))return}finally{if(f)throw o}}return u}}function Fo(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
4
4
|
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Lo(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{ad as Ae,aS as u,bb as W,aC as e,b as Ie,aa as Pe,ai as Kt,bl as Rn,aB as In,g as Mn,t as Un,u as $n,W as Bn,j as Fn,k as Hn,an as Gn,bg as G,m as K,am as ss,ak as Wn,b2 as ns,av as qn,a7 as Fs,bm as Oe,c as ye,aD as Vt,ah as Hs,bc as Et,bo as Gs,bv as zt,y as Kn,a9 as Ws,B as Vn,V as qs,x as zn,bz as Ks,U as ze,bx as os,br as Yn,aG as Xn,aK as Jn,b1 as Qn,ay as Vs,J as Zn,at as eo,ao as zs,a_ as to,bh as Ys}from"./index-
|
|
1
|
+
import{ad as Ae,aS as u,bb as W,aC as e,b as Ie,aa as Pe,ai as Kt,bl as Rn,aB as In,g as Mn,t as Un,u as $n,W as Bn,j as Fn,k as Hn,an as Gn,bg as G,m as K,am as ss,ak as Wn,b2 as ns,av as qn,a7 as Fs,bm as Oe,c as ye,aD as Vt,ah as Hs,bc as Et,bo as Gs,bv as zt,y as Kn,a9 as Ws,B as Vn,V as qs,x as zn,bz as Ks,U as ze,bx as os,br as Yn,aG as Xn,aK as Jn,b1 as Qn,ay as Vs,J as Zn,at as eo,ao as zs,a_ as to,bh as Ys}from"./index-CdTppjKR.js";import{s as is,T as Me,S as Xs}from"./Toggle-CYajnSdx.js";import{P as qe}from"./Panel-B_D4Bg7L.js";import{b as so,c as no,T as oo}from"./TiptapBody-DVXtEIVy.js";const bt=[{id:"permissions",label:"Permissions",tab:"permissions",keys:["permissions"]},{id:"hooks",label:"Hooks",tab:"hooks",keys:["hooks","disableAllHooks","allowedHttpHookUrls","httpHookAllowedEnvVars"]},{id:"mcp",label:"MCP Servers",tab:null,keys:["enabledMcpjsonServers","disabledMcpjsonServers","enableAllProjectMcpServers"]},{id:"plugins",label:"Plugins",tab:null,keys:["enabledPlugins"]}],rs=new Set(bt.flatMap(t=>t.keys)),Js=[{id:"essentials",title:"Essentials",summary:"The knobs you reach for first.",keys:["model","language","outputStyle"]},{id:"git",title:"Git & Commits",summary:"How Claude writes commits and pull requests on your behalf.",keys:["attribution","includeGitInstructions","includeCoAuthoredBy"]},{id:"memory",title:"Memory & Plans",summary:"Context Claude keeps between sessions and where it files plans.",keys:["autoMemoryEnabled","plansDirectory","claudeMdExcludes","respectGitignore"]},{id:"model",title:"Model & Reasoning",summary:"Model allow/override lists, reasoning depth, and fast-mode toggles — machine-wide, with no per-Epic override yet. An Epic's Agent persona model (Agent Library) still wins over Essentials' plain model default.",advanced:!0,keys:["availableModels","modelOverrides","effortLevel","fastMode","fastModePerSessionOptIn","alwaysThinkingEnabled","fallbackModel","enforceAvailableModels","teammateDefaultModel","advisorModel"]},{id:"interface",title:"Interface",summary:"Visual polish — spinners, progress bars, motion.",keys:["spinnerTipsEnabled","spinnerTipsOverride","spinnerVerbs","terminalProgressBarEnabled","showTurnDuration","prefersReducedMotion","companyAnnouncements","statusLine","teammateMode"]},{id:"updates",title:"Updates & Cleanup",summary:"Release channel and how long transcripts stick around.",keys:["autoUpdatesChannel","cleanupPeriodDays"]},{id:"env",title:"Environment & Auth",summary:"Environment variables and auth-helper scripts.",keys:["env","apiKeyHelper","awsCredentialExport","awsAuthRefresh"]},{id:"hooks",title:"Hooks",summary:"Scripts Claude runs before/after tool use.",keys:["hooks","disableAllHooks","allowedHttpHookUrls","httpHookAllowedEnvVars"]},{id:"mcp",title:"MCP Servers",summary:"External tool providers Claude can talk to.",keys:["enableAllProjectMcpServers","enabledMcpjsonServers","disabledMcpjsonServers"]},{id:"plugins",title:"Plugins",summary:"Installed plugins, marketplaces, and per-plugin configuration.",keys:["enabledPlugins","extraKnownMarketplaces","skippedPlugins","skippedMarketplaces","pluginConfigs"]},{id:"filesystem",title:"File Picker & Sandbox",summary:"How Claude browses files and the sandbox it runs in.",keys:["fileSuggestion","sandbox","worktree"]},{id:"login",title:"Login",summary:"Which login method to force on startup.",keys:["forceLoginMethod","forceLoginOrgUUID"]},{id:"feedback",title:"Feedback",summary:"Session-quality surveys.",keys:["feedbackSurveyRate"]},{id:"advanced",title:"Advanced / Enterprise",summary:"Managed-settings-only keys and enterprise allow/denylists.",advanced:!0,keys:["allowedMcpServers","deniedMcpServers","allowManagedHooksOnly","allowManagedPermissionRulesOnly","allowManagedMcpServersOnly","strictKnownMarketplaces","blockedMarketplaces","pluginTrustMessage","otelHeadersHelper","skipWebFetchPreflight"]}],io={mcp:"MCP",url:"URL",urls:"URLs",http:"HTTP",ui:"UI",id:"ID",uuid:"UUID",api:"API",aws:"AWS",otel:"OTel",json:"JSON"};function Ye(t){return t.replace(/^\$/,"").replace(/([a-z])([A-Z])/g,"$1 $2").replace(/([A-Z]+)([A-Z][a-z])/g,"$1 $2").toLowerCase().split(/\s+/).filter(Boolean).map((o,i)=>{const a=io[o];return a||(i===0?o.charAt(0).toUpperCase()+o.slice(1):o)}).join(" ")}function Qs(t){const s=new Set,n=[];for(const i of Js){const a=i.keys.filter(r=>t.has(r)&&!rs.has(r));a.forEach(r=>s.add(r)),a.length!==0&&n.push({id:i.id,title:i.title,summary:i.summary,advanced:!!i.advanced,keys:a})}const o=Array.from(t).filter(i=>!s.has(i)&&i!=="$schema"&&!rs.has(i)).sort();return o.length>0&&n.push({id:"other",title:"Other",summary:"Keys not yet grouped.",advanced:!1,keys:o}),n}function ro(t,s){return Qs(t).map(n=>({id:n.id,title:n.title,advanced:n.advanced,total:n.keys.length,setCount:n.keys.filter(o=>s.has(o)).length}))}const Yt=/^---\r?\n([\s\S]*?)\r?\n---\r?\n?([\s\S]*)$/,At="disable-model-invocation",Zs=/^\s*disable-model-invocation\s*:/;function ao(t){const s=t.match(Yt);if(!s)return!1;for(const n of s[1].split(/\r?\n/)){if(!Zs.test(n))continue;const o=n.slice(n.indexOf(":")+1).trim().toLowerCase();return o==="true"||o==="yes"}return!1}function lo(t){const s=t.trim();return s.length>=2&&(s[0]==='"'&&s[s.length-1]==='"'||s[0]==="'"&&s[s.length-1]==="'")?s.slice(1,-1):s}function He(t){return t.length-t.trimStart().length}function it(t){const s=t.match(Yt);if(!s)return{name:null,description:null,body:t};const n=s[1].split(/\r?\n/),o=s[2]??"";let i=null,a=null;for(let r=0;r<n.length;r++){const l=n[r],d=l.match(/^(\s*)(name|description)\s*:(.*)$/);if(!d)continue;const[,,c,p]=d,m=p.trim(),g=He(l);let h;if(m===""||m===">-"||m===">"||m==="|-"||m==="|"){const f=[];let b=r+1;for(;b<n.length&&n[b].trim()!==""&&He(n[b])>g;)f.push(n[b].trim()),b++;h=f.join(" ")}else h=lo(m);c==="name"?i=h:a=h}return{name:i,description:a,body:o}}function co(t,s){const n=t.match(Yt);if(!n){if(!s)return t;const r=t.startsWith(`
|
|
2
2
|
`)?"":`
|
|
3
3
|
`;return`---
|
|
4
4
|
${At}: true
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{aY as ba,aS as H,R as Pt,aC as N,S as Wf,az as Uf,aa as ka}from"./index-
|
|
1
|
+
import{aY as ba,aS as H,R as Pt,aC as N,S as Wf,az as Uf,aa as ka}from"./index-CdTppjKR.js";var zi={exports:{}},$i={};/**
|
|
2
2
|
* @license React
|
|
3
3
|
* use-sync-external-store-shim.production.js
|
|
4
4
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{bm as g,aS as d,at as p,aC as s,bk as b}from"./index-
|
|
1
|
+
import{bm as g,aS as d,at as p,aC as s,bk as b}from"./index-CdTppjKR.js";function h(e,t){return t&&(e===t||e.startsWith(t+"/"))?"~"+e.slice(t.length):e}function v({path:e,keyPath:t,note:i}){const n=g(),[a,l]=d.useState(void 0);d.useEffect(()=>{let r=!0;const u=()=>{window.api.config.readText(e,{maxBytes:1}).then(o=>{r&&l(o.exists?o.mtimeMs:null)}).catch(()=>{r&&l(void 0)})};u();const x=window.api.config.onChanged(o=>{o.path===e&&u()});return()=>{r=!1,x()}},[e]);const f=h(e,n)+(t&&t.length?` › ${t.join(".")}`:""),c=a===void 0?"":a===null?"created on first save":p(a),m=()=>{b.getState().openFile(e),window.dispatchEvent(new CustomEvent("sm:open-editor"))};return s.jsxs("button",{type:"button","data-testid":"source-chip",title:i??`Open ${e} in the editor`,onClick:m,className:"inline-flex items-center gap-1.5 max-w-full text-[11px] px-2 py-0.5 rounded border border-line bg-bg-elev text-fg-dim hover:bg-bg-hi",children:[s.jsx("span",{className:"font-mono truncate","data-testid":"source-chip-path",children:f}),c&&s.jsxs("span",{className:"text-fg-dim/70 shrink-0","data-testid":"source-chip-age",children:["· ",c]})]})}function j({checked:e,onChange:t,label:i,disabled:n}){return s.jsxs("label",{className:`inline-flex items-center gap-2 text-xs ${n?"opacity-50 cursor-not-allowed":"cursor-pointer"}`,children:[s.jsx("button",{type:"button",role:"switch","aria-checked":e,disabled:n,onClick:()=>!n&&t(!e),className:`relative inline-flex shrink-0 items-center w-8 h-[18px] rounded-full transition-colors focus-visible:outline focus-visible:outline-2 focus-visible:outline-accent ${e?"bg-accent":"bg-line"}`,children:s.jsx("span",{"data-testid":"toggle-thumb","aria-hidden":!0,className:`absolute left-0.5 top-0.5 w-3.5 h-3.5 rounded-full bg-bg-hi shadow-sm transition-transform ${e?"translate-x-3.5":"translate-x-0"}`})}),i&&s.jsx("span",{"data-testid":"toggle-label",className:"whitespace-nowrap text-fg-dim",children:i})]})}export{v as S,j as T,h as s};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{bA as o,by as m,ag as j,aC as e,b3 as l,bx as b,aF as R}from"./index-
|
|
1
|
+
import{bA as o,by as m,ag as j,aC as e,b3 as l,bx as b,aF as R}from"./index-CdTppjKR.js";let u=0;const T=1e3;function y(n){const s=performance.now();s-u<T||(u=s,R.debug("voice","mic.gate.click_rejected",{reason:n}))}function k(){const n=o(t=>t.isRecording),s=o(t=>t.error),i=o(t=>t.loadingProgress),r=o(m(l)),x=()=>{const t=o.getState(),{canRecord:h,reason:a}=l(t);if(t.isRecording)return t.stopRecording();if(t.wizardArmed&&!t.wizardOpen){t.openWizard();return}if(a==="error"||a==="load-timeout"){t.resetAndRetryModel();return}if(!h)return y(a);const c=b.getState().activeTabId;c&&t.startRecording(c)},d=j(r.reason,{loadingPct:i,errorMessage:s,isRecording:n}),g=r.reason==="unsupported",p=!r.canRecord,f=r.reason==="loading"?"text-fg-faint animate-pulse cursor-wait":r.reason==="error"||r.reason==="load-timeout"?"text-red-400 cursor-pointer":r.reason==="permission-denied"?"text-amber-400 cursor-pointer":r.reason==="idle"?"text-fg-faint cursor-pointer":r.reason==="unsupported"?"text-fg-faint cursor-not-allowed":n?"text-red-400 ring-2 ring-red-400 animate-pulse":"text-fg-dim hover:text-fg";return e.jsx("button",{onClick:x,disabled:g,"aria-disabled":p,"aria-label":d,title:d,"data-testid":"mic-button","data-state":r.reason,className:`p-1.5 rounded transition-colors ${f}`,children:e.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[e.jsx("rect",{x:"9",y:"1",width:"6",height:"12",rx:"3"}),e.jsx("path",{d:"M5 10a7 7 0 0 0 14 0"}),e.jsx("line",{x1:"12",y1:"17",x2:"12",y2:"21"}),e.jsx("line",{x1:"8",y1:"21",x2:"16",y2:"21"})]})})}function v(){const n=o(i=>i.ttsEnabled),s=o(i=>i.toggleTTS);return e.jsxs("button",{onClick:s,title:n?"Read Claude replies aloud: ON":"Read Claude replies aloud: OFF",className:`px-1.5 py-1 rounded transition-colors flex items-center gap-1 ${n?"text-accent":"text-fg-dim hover:text-fg"}`,children:[e.jsxs("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:[e.jsx("polygon",{points:"11 5 6 9 2 9 2 15 6 15 11 19 11 5"}),n?e.jsxs(e.Fragment,{children:[e.jsx("path",{d:"M15.54 8.46a5 5 0 0 1 0 7.07"}),e.jsx("path",{d:"M19.07 4.93a10 10 0 0 1 0 14.14"})]}):e.jsxs(e.Fragment,{children:[e.jsx("line",{x1:"23",y1:"9",x2:"17",y2:"15"}),e.jsx("line",{x1:"17",y1:"9",x2:"23",y2:"15"})]})]}),e.jsx("span",{className:"text-[10px] font-medium tracking-wide",children:"TTS"})]})}export{v as T,k as V};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{bD as s}from"./index-
|
|
1
|
+
import{bD as s}from"./index-CdTppjKR.js";function a(t){const e=Number.isFinite(t)?t:0,r=Math.abs(e)<1?4:2;return`$${e.toFixed(r)}`}function u(t){const e=Number.isFinite(t)?t:0,r=Math.abs(e);return r>=1e9?`${(e/1e9).toFixed(1)}B`:r>=1e6?`${(e/1e6).toFixed(1)}M`:r>=1e3?`${(e/1e3).toFixed(1)}K`:`${Math.round(e)}`}function f(t){const e=Number.isFinite(t)?t:0;return Math.round(e).toLocaleString("en-US")}function m(t){const e=Math.max(0,Math.round(Number.isFinite(t)?t:0));if(e<60)return`${e}m`;const r=Math.floor(e/60),n=e%60;return n===0?`${r}h`:`${r}h ${n}m`}function h(t){return Number.isFinite(t)?t>0&&t<1?"<1%":`${t.toFixed(1)}%`:"0.0%"}async function l(t,e=5e3){try{return{ok:!0,data:await s(Promise.resolve().then(()=>window.api.history.dashboard({rangeDays:t})),e,"history.dashboard")}}catch(r){return{ok:!1,error:r instanceof Error?r.message:String(r)}}}function c(t){return`${a(t.costUsd)} · ${u(t.tokens)} tok`}function b(t,e){const r=e!=null&&e.day?t.days.filter(o=>o.date===e.day).flatMap(o=>Object.values(o.byProject)):[t.totals];let n=0,i=0;for(const o of r)n+=o.estimatedCostUsd,i+=o.inputTokens+o.outputTokens+o.cacheReadTokens+o.cacheCreationTokens;return{costUsd:n,tokens:i,label:c({costUsd:n,tokens:i})}}export{c as a,l as f,f as i,m,h as p,b as s,u as t,a as u};
|