botmux 3.14.0 → 3.15.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.
Files changed (121) hide show
  1. package/dist/.runtime-build-id +1 -1
  2. package/dist/adapters/backend/tmux-pipe-backend.d.ts +30 -0
  3. package/dist/adapters/backend/tmux-pipe-backend.d.ts.map +1 -1
  4. package/dist/adapters/backend/tmux-pipe-backend.js +60 -0
  5. package/dist/adapters/backend/tmux-pipe-backend.js.map +1 -1
  6. package/dist/adapters/backend/types.d.ts +7 -0
  7. package/dist/adapters/backend/types.d.ts.map +1 -1
  8. package/dist/adapters/backend/types.js.map +1 -1
  9. package/dist/adapters/cli/cursor.d.ts.map +1 -1
  10. package/dist/adapters/cli/cursor.js +13 -1
  11. package/dist/adapters/cli/cursor.js.map +1 -1
  12. package/dist/adapters/cli/dsh.d.ts.map +1 -1
  13. package/dist/adapters/cli/dsh.js +5 -1
  14. package/dist/adapters/cli/dsh.js.map +1 -1
  15. package/dist/adapters/cli/pi.d.ts +14 -1
  16. package/dist/adapters/cli/pi.d.ts.map +1 -1
  17. package/dist/adapters/cli/pi.js +21 -1
  18. package/dist/adapters/cli/pi.js.map +1 -1
  19. package/dist/adapters/cli/shared-hints.d.ts.map +1 -1
  20. package/dist/adapters/cli/shared-hints.js +29 -24
  21. package/dist/adapters/cli/shared-hints.js.map +1 -1
  22. package/dist/adapters/cli/types.d.ts +4 -0
  23. package/dist/adapters/cli/types.d.ts.map +1 -1
  24. package/dist/bot-registry.d.ts +22 -0
  25. package/dist/bot-registry.d.ts.map +1 -1
  26. package/dist/bot-registry.js +24 -0
  27. package/dist/bot-registry.js.map +1 -1
  28. package/dist/cli.d.ts.map +1 -1
  29. package/dist/cli.js +8 -3
  30. package/dist/cli.js.map +1 -1
  31. package/dist/core/command-discovery.d.ts.map +1 -1
  32. package/dist/core/command-discovery.js +4 -1
  33. package/dist/core/command-discovery.js.map +1 -1
  34. package/dist/core/dashboard-ipc-server.d.ts.map +1 -1
  35. package/dist/core/dashboard-ipc-server.js +42 -1
  36. package/dist/core/dashboard-ipc-server.js.map +1 -1
  37. package/dist/core/skills/frontmatter.d.ts.map +1 -1
  38. package/dist/core/skills/frontmatter.js +6 -1
  39. package/dist/core/skills/frontmatter.js.map +1 -1
  40. package/dist/core/worker-pool.d.ts.map +1 -1
  41. package/dist/core/worker-pool.js +21 -8
  42. package/dist/core/worker-pool.js.map +1 -1
  43. package/dist/daemon.d.ts.map +1 -1
  44. package/dist/daemon.js +4 -10
  45. package/dist/daemon.js.map +1 -1
  46. package/dist/dashboard/bot-payload.d.ts +4 -0
  47. package/dist/dashboard/bot-payload.d.ts.map +1 -1
  48. package/dist/dashboard/bot-payload.js +1 -0
  49. package/dist/dashboard/bot-payload.js.map +1 -1
  50. package/dist/dashboard/web/bot-defaults-page.d.ts +7 -0
  51. package/dist/dashboard/web/bot-defaults-page.d.ts.map +1 -1
  52. package/dist/dashboard/web/bot-defaults-page.js +96 -1
  53. package/dist/dashboard/web/bot-defaults-page.js.map +1 -1
  54. package/dist/dashboard/web/bot-defaults.d.ts +2 -0
  55. package/dist/dashboard/web/bot-defaults.d.ts.map +1 -1
  56. package/dist/dashboard/web/bot-defaults.js.map +1 -1
  57. package/dist/dashboard/web/i18n.d.ts.map +1 -1
  58. package/dist/dashboard/web/i18n.js +8 -0
  59. package/dist/dashboard/web/i18n.js.map +1 -1
  60. package/dist/dashboard/web/skills-page.d.ts.map +1 -1
  61. package/dist/dashboard/web/skills-page.js +4 -2
  62. package/dist/dashboard/web/skills-page.js.map +1 -1
  63. package/dist/dashboard-web/app.js +1 -1
  64. package/dist/dashboard-web/chunks/bot-defaults-page-65SMZ4QY.js +10 -0
  65. package/dist/dashboard-web/chunks/{chunk-2WQDS65D.js → chunk-IKN6WURK.js} +1 -1
  66. package/dist/dashboard-web/chunks/{chunk-Q2MT4VWH.js → chunk-VMWNR3SV.js} +4 -4
  67. package/dist/dashboard-web/chunks/{chunk-6O7KXFD2.js → chunk-Z7B3E3US.js} +1 -1
  68. package/dist/dashboard-web/chunks/{chunk-U3ZFSO7E.js → chunk-Z7DO42GJ.js} +1 -1
  69. package/dist/dashboard-web/chunks/{connectors-page-2KZO5KSJ.js → connectors-page-CPH6VVFY.js} +1 -1
  70. package/dist/dashboard-web/chunks/{feedback-page-CLVTOLLO.js → feedback-page-J2FKQ3LK.js} +1 -1
  71. package/dist/dashboard-web/chunks/{groups-page-HLASRTSY.js → groups-page-VDOOLS4M.js} +1 -1
  72. package/dist/dashboard-web/chunks/{insights-page-4RPU2CRU.js → insights-page-A2LWTKJD.js} +1 -1
  73. package/dist/dashboard-web/chunks/{monitor-room-OTKQ2CXK.js → monitor-room-2YR752E3.js} +1 -1
  74. package/dist/dashboard-web/chunks/{monitoring-page-IJPUB6JT.js → monitoring-page-BGYSKZGM.js} +1 -1
  75. package/dist/dashboard-web/chunks/{office-page-QSR3J44Y.js → office-page-ZZHTEAE4.js} +1 -1
  76. package/dist/dashboard-web/chunks/{overview-page-6OK63V4V.js → overview-page-7NYPKQSB.js} +1 -1
  77. package/dist/dashboard-web/chunks/{roles-page-6NWJMOB5.js → roles-page-YUC4YLJG.js} +1 -1
  78. package/dist/dashboard-web/chunks/{schedules-page-6I3LNXD4.js → schedules-page-2L2NKTDJ.js} +1 -1
  79. package/dist/dashboard-web/chunks/{sessions-page-B2TXGJDO.js → sessions-page-DYZZMKFL.js} +1 -1
  80. package/dist/dashboard-web/chunks/{settings-page-6KJADSC6.js → settings-page-LIULUSMH.js} +1 -1
  81. package/dist/dashboard-web/chunks/{skills-page-M2Q6L5CB.js → skills-page-DQPBBI3T.js} +2 -2
  82. package/dist/dashboard-web/chunks/{team-federation-page-7I7FDE3B.js → team-federation-page-LQKLDV4K.js} +1 -1
  83. package/dist/dashboard-web/chunks/{v3-page-HQXRL65L.js → v3-page-RVKQIMAP.js} +1 -1
  84. package/dist/dashboard-web/chunks/{whiteboards-page-LQKC4TAZ.js → whiteboards-page-S5K55HRZ.js} +1 -1
  85. package/dist/dashboard.js +11 -1
  86. package/dist/dashboard.js.map +1 -1
  87. package/dist/dsh-runner.js +8 -1
  88. package/dist/dsh-runner.js.map +1 -1
  89. package/dist/i18n/en.d.ts.map +1 -1
  90. package/dist/i18n/en.js +15 -26
  91. package/dist/i18n/en.js.map +1 -1
  92. package/dist/i18n/zh.d.ts.map +1 -1
  93. package/dist/i18n/zh.js +15 -26
  94. package/dist/i18n/zh.js.map +1 -1
  95. package/dist/im/lark/event-dispatcher.d.ts.map +1 -1
  96. package/dist/im/lark/event-dispatcher.js +5 -19
  97. package/dist/im/lark/event-dispatcher.js.map +1 -1
  98. package/dist/services/bridge-fallback-gate.d.ts +15 -7
  99. package/dist/services/bridge-fallback-gate.d.ts.map +1 -1
  100. package/dist/services/bridge-fallback-gate.js +43 -16
  101. package/dist/services/bridge-fallback-gate.js.map +1 -1
  102. package/dist/services/peer-cross-ref-store.d.ts +8 -0
  103. package/dist/services/peer-cross-ref-store.d.ts.map +1 -0
  104. package/dist/services/peer-cross-ref-store.js +95 -0
  105. package/dist/services/peer-cross-ref-store.js.map +1 -0
  106. package/dist/services/pi-transcript.d.ts.map +1 -1
  107. package/dist/services/pi-transcript.js +10 -6
  108. package/dist/services/pi-transcript.js.map +1 -1
  109. package/dist/services/structured-bridge-clis.d.ts +13 -4
  110. package/dist/services/structured-bridge-clis.d.ts.map +1 -1
  111. package/dist/services/structured-bridge-clis.js +13 -3
  112. package/dist/services/structured-bridge-clis.js.map +1 -1
  113. package/dist/types.d.ts +1 -0
  114. package/dist/types.d.ts.map +1 -1
  115. package/dist/utils/bot-routing.d.ts +1 -1
  116. package/dist/utils/bot-routing.d.ts.map +1 -1
  117. package/dist/utils/bot-routing.js.map +1 -1
  118. package/dist/worker.js +233 -11
  119. package/dist/worker.js.map +1 -1
  120. package/package.json +5 -1
  121. package/dist/dashboard-web/chunks/bot-defaults-page-4RENHE7J.js +0 -10
@@ -1 +1 @@
1
- import{c as B}from"./chunk-2WQDS65D.js";import{c as W,k as C}from"./chunk-5CJMHTT4.js";import"./chunk-G5XGBCM6.js";import"./chunk-Q2MT4VWH.js";import{a as P}from"./chunk-SYC6D5XU.js";import{a as O,d as T}from"./chunk-5THX4DI2.js";import{c as R}from"./chunk-7SZRL6FY.js";var r=R(O(),1);var e=R(T(),1);function x(t){let a=Date.parse(t);if(!a)return t||"-";let o=Math.max(0,Math.floor((Date.now()-a)/1e3));if(o<60)return`${o}s ago`;let i=Math.floor(o/60);if(i<60)return`${i}m ago`;let n=Math.floor(i/60);return n<24?`${n}h ago`:`${Math.floor(n/24)}d ago`}function F(t){return t.chatId?.trim()||"__local__"}function G(t,a){if(t==="__local__")return"\u672A\u7ED1\u5B9A\u7FA4 / \u672C\u5730\u767D\u677F";let o=a.get(t);return o&&o!==t?`${o} (${t})`:t}function K(t,a){let o=new Map;for(let i of t){let n=F(i),c=o.get(n)??[];c.push(i),o.set(n,c)}return[...o.entries()].map(([i,n])=>({chatId:i,label:G(i,a),rows:[...n].sort((c,b)=>b.updatedAt.localeCompare(c.updatedAt))})).sort((i,n)=>i.label.localeCompare(n.label))}function z(){return decodeURIComponent((location.hash.match(/^#\/whiteboards\/([^/]+)/)?.[1]??"").trim())}async function E(t,a){let o=await fetch(`/api/whiteboards/${encodeURIComponent(t)}`),i=await o.json().catch(()=>({}));if(o.ok)return{id:t,content:String(i.content??""),row:a.find(n=>n.id===t)}}async function J(t){let a=new Map;if(!t?.ok)return a;let o=await t.json().catch(()=>({})),i=Array.isArray(o.chats)?o.chats:[];for(let n of i)n.chatId&&a.set(String(n.chatId),String(n.name||n.chatId));return a}function Q(t){let a=t.row,o=a.title||a.id;return(0,e.jsxs)("a",{className:`wb-item${t.active?" active":""}`,"data-whiteboard-id":a.id,href:`#/whiteboards/${encodeURIComponent(a.id)}`,onClick:i=>{i.preventDefault(),t.onSelect(a.id)},children:[(0,e.jsx)("div",{className:"wb-item-head",children:(0,e.jsxs)("div",{className:"wb-item-main",children:[(0,e.jsx)("strong",{children:(0,e.jsx)(C,{text:o,textClassName:"wb-title-scroll"})}),(0,e.jsx)("span",{className:"wb-id-text",title:a.id,children:a.id})]})}),(0,e.jsxs)("div",{className:"wb-item-foot",children:[(0,e.jsxs)("div",{className:"wb-item-meta",children:[(0,e.jsx)("span",{children:x(a.updatedAt)}),(0,e.jsx)("span",{children:"\xB7"}),(0,e.jsxs)("span",{children:["log ",a.logCount]})]}),(0,e.jsx)("span",{className:"wb-scope",title:a.scope,children:a.scope})]})]})}function p(t){let a=t.value||"-";return(0,e.jsxs)("div",{className:"wb-meta-card",title:a,children:[(0,e.jsx)("span",{children:t.label}),(0,e.jsx)("strong",{children:a})]})}function V(t){let a=t.selected;if(!a)return(0,e.jsx)("p",{className:"empty",children:"\u9009\u62E9\u5DE6\u4FA7\u767D\u677F\u67E5\u770B meta \u548C board.md\u3002"});let o=a.row,i=o?.chatId?G(o.chatId,t.groupNames):"\u672A\u7ED1\u5B9A\u7FA4 / \u672C\u5730\u767D\u677F",n=o?.title||a.id;return(0,e.jsxs)(e.Fragment,{children:[(0,e.jsxs)("div",{className:"wb-detail-head",children:[(0,e.jsxs)("div",{className:"wb-detail-title",children:[(0,e.jsx)("p",{className:"eyebrow",children:"WHITEBOARD"}),(0,e.jsx)("h2",{title:n,children:n}),(0,e.jsx)("code",{title:a.id,children:a.id})]}),(0,e.jsx)("button",{type:"button",className:"danger","data-delete-whiteboard":!0,onClick:t.onDelete,children:"\u5220\u9664\u767D\u677F"})]}),(0,e.jsxs)("div",{className:"wb-meta-grid",children:[(0,e.jsx)(p,{label:"\u6240\u5C5E\u7FA4",value:i}),(0,e.jsx)(p,{label:"\u8303\u56F4",value:o?.scope??"-"}),(0,e.jsx)(p,{label:"\u6700\u8FD1\u66F4\u65B0",value:o?.updatedAt?x(o.updatedAt):"-"}),(0,e.jsx)(p,{label:"\u6765\u6E90\u76EE\u5F55",value:o?.workingDir??"-"})]}),(0,e.jsxs)("details",{className:"wb-admin-info",children:[(0,e.jsx)("summary",{children:"\u7BA1\u7406\u4FE1\u606F / \u6587\u4EF6\u8DEF\u5F84"}),(0,e.jsx)("code",{children:o?.path??""})]}),(0,e.jsxs)("section",{className:"wb-board-panel",children:[(0,e.jsxs)("div",{className:"wb-board-panel-head",children:[(0,e.jsx)("strong",{children:"board.md"}),(0,e.jsx)("span",{children:"\u53EA\u8BFB\u9884\u89C8"})]}),(0,e.jsx)("pre",{children:a.content||"\uFF08\u6682\u65E0\u5185\u5BB9\uFF09"})]})]})}function X(t){let a=t.selected.row?.title||t.selected.id;return(0,e.jsx)("div",{className:"wb-delete-backdrop","data-delete-modal":!0,onClick:o=>{o.target===o.currentTarget&&t.onCancel()},children:(0,e.jsxs)("div",{className:"wb-delete-dialog",role:"dialog","aria-modal":"true","aria-labelledby":"wb-delete-title",children:[(0,e.jsxs)("div",{className:"wb-delete-body",children:[(0,e.jsx)("div",{className:"wb-delete-mark","aria-hidden":"true",children:"!"}),(0,e.jsxs)("div",{children:[(0,e.jsx)("h3",{id:"wb-delete-title",children:"\u5220\u9664\u767D\u677F\uFF1F"}),(0,e.jsxs)("p",{children:["\u5C06\u5220\u9664 ",(0,e.jsx)("strong",{children:a}),"\uFF08",(0,e.jsx)("code",{children:t.selected.id}),"\uFF09\u7684 board\u3001log\u3001meta\uFF0C\u5E76\u6E05\u7406\u9ED8\u8BA4\u7ED1\u5B9A\u548C\u4F1A\u8BDD\u5F15\u7528\u3002\u6B64\u64CD\u4F5C\u4E0D\u53EF\u6062\u590D\u3002"]})]})]}),(0,e.jsxs)("div",{className:"actions wb-delete-actions",children:[(0,e.jsx)("button",{type:"button","data-delete-cancel":!0,onClick:t.onCancel,disabled:t.deleting,children:"\u53D6\u6D88"}),(0,e.jsx)("button",{type:"button",className:"danger","data-delete-confirm":!0,onClick:t.onConfirm,disabled:t.deleting,children:t.deleting?"\u5220\u9664\u4E2D...":"\u786E\u8BA4\u5220\u9664"})]})]})})}function Y(){let t=B(),a=(0,r.useRef)(!1),o=(0,r.useRef)(0),[i,n]=(0,r.useState)(!1),[c,b]=(0,r.useState)([]),[g,_]=(0,r.useState)(()=>new Map),[m,f]=(0,r.useState)(),[H,S]=(0,r.useState)(!0),[k,M]=(0,r.useState)(null),[u,h]=(0,r.useState)(null),[L,D]=(0,r.useState)(!1),I=(0,r.useMemo)(()=>K(c,g),[c,g]);(0,r.useEffect)(()=>{a.current=!0;let s=z();async function d(){S(!0);try{let[l,y]=await Promise.all([fetch("/api/whiteboards"),fetch("/api/groups").catch(()=>null)]),w=await l.json().catch(()=>({}));if(!l.ok)throw new Error(w?.error??`HTTP ${l.status}`);let q=await J(y),$=Array.isArray(w.whiteboards)?w.whiteboards:[],A;if(s&&(A=await E(s,$)),!a.current)return;n(w.enabled===!0),b($),_(q),f(A),M(null)}catch(l){a.current&&M(l instanceof Error?l.message:String(l))}finally{a.current&&S(!1)}}return d(),()=>{a.current=!1,o.current+=1}},[]);async function U(s){let d=o.current+1;o.current=d;let l=await E(s,c);!a.current||o.current!==d||!l||(f(l),window.history.replaceState(null,"",`#/whiteboards/${encodeURIComponent(s)}`))}async function j(){if(u){D(!0);try{let s=await fetch(`/api/whiteboards/${encodeURIComponent(u.id)}`,{method:"DELETE"}),d=await s.json().catch(()=>({}));if(!s.ok||d.ok===!1)throw new Error(d?.error??`HTTP ${s.status}`);if(!a.current)return;b(l=>l.filter(y=>y.id!==u.id)),m?.id===u.id&&(f(void 0),window.history.replaceState(null,"","#/whiteboards")),h(null)}catch(s){a.current&&window.alert(`\u5220\u9664\u5931\u8D25\uFF1A${s instanceof Error?s.message:String(s)}`)}finally{a.current&&D(!1)}}}let v="\u767D\u677F\u80FD\u529B\u5F53\u524D\u5173\u95ED\uFF1A\u4E0D\u4F1A\u81EA\u52A8\u521B\u5EFA/\u7ED1\u5B9A\u767D\u677F\uFF0C\u4E5F\u4E0D\u4F1A\u6CE8\u5165\u5230 agent prompt\u3002\u5386\u53F2\u767D\u677F\u4EC5\u5728 dashboard \u4E2D\u53EA\u8BFB\u53EF\u89C1\uFF0C\u53EF\u5728\u6B64\u6E05\u7406\u3002",N=(s=!1)=>(0,e.jsx)("div",{className:"page-heading",children:(0,e.jsxs)("div",{children:[(0,e.jsx)("p",{className:"eyebrow",children:t("nav.whiteboards")}),(0,e.jsx)("h1",{children:t("nav.whiteboards")}),s?(0,e.jsx)("span",{className:"wb-disabled-pill",title:v,"aria-label":v,children:v}):null]})});return k?(0,e.jsxs)("section",{className:"page whiteboards-page",children:[N(),(0,e.jsxs)("p",{className:"hint-warn",children:["\u52A0\u8F7D\u767D\u677F\u5931\u8D25\uFF1A",k]})]}):H?(0,e.jsxs)("section",{className:"page whiteboards-page","data-whiteboards-host":!0,children:[N(),(0,e.jsx)(W,{label:t("common.loading")})]}):(0,e.jsxs)("section",{className:"page whiteboards-page",children:[N(!i),(0,e.jsxs)("div",{className:"wb-split",children:[(0,e.jsx)("section",{className:"overview-block wb-list-block",children:(0,e.jsx)("div",{className:"wb-list-panel",children:I.length===0?(0,e.jsx)("p",{className:"empty wb-empty",children:"\u6682\u65E0\u767D\u677F\u3002\u6253\u5F00\u80FD\u529B\u540E\uFF0C\u6BCF\u4E2A\u7FA4\u9996\u6B21\u9700\u8981\u767D\u677F\u65F6\u624D\u4F1A\u521B\u5EFA\u9ED8\u8BA4\u767D\u677F\u3002"}):I.map(s=>(0,e.jsxs)("details",{className:"wb-group",open:!0,children:[(0,e.jsxs)("summary",{children:[(0,e.jsx)("span",{className:"wb-group-title",children:(0,e.jsx)(C,{text:s.label,textClassName:"wb-group-title-scroll"})}),(0,e.jsx)("small",{children:s.rows.length})]}),(0,e.jsx)("div",{className:"wb-group-items",children:s.rows.map(d=>(0,e.jsx)(Q,{row:d,active:m?.id===d.id,onSelect:l=>{U(l)}},d.id))})]},s.chatId))})}),(0,e.jsx)("section",{className:"overview-block wb-detail-block",children:(0,e.jsx)("div",{className:"wb-detail-panel",id:"whiteboard-detail",children:(0,e.jsx)(V,{selected:m,groupNames:g,onDelete:()=>{m&&h(m)}})})})]}),u?(0,e.jsx)(X,{selected:u,deleting:L,onCancel:()=>h(null),onConfirm:()=>{j()}}):null]})}function ae(t){return P(t,(0,e.jsx)(Y,{}))}export{ae as renderWhiteboardsPage};
1
+ import{c as B}from"./chunk-IKN6WURK.js";import{c as W,k as C}from"./chunk-5CJMHTT4.js";import"./chunk-G5XGBCM6.js";import"./chunk-VMWNR3SV.js";import{a as P}from"./chunk-SYC6D5XU.js";import{a as O,d as T}from"./chunk-5THX4DI2.js";import{c as R}from"./chunk-7SZRL6FY.js";var r=R(O(),1);var e=R(T(),1);function x(t){let a=Date.parse(t);if(!a)return t||"-";let o=Math.max(0,Math.floor((Date.now()-a)/1e3));if(o<60)return`${o}s ago`;let i=Math.floor(o/60);if(i<60)return`${i}m ago`;let n=Math.floor(i/60);return n<24?`${n}h ago`:`${Math.floor(n/24)}d ago`}function F(t){return t.chatId?.trim()||"__local__"}function G(t,a){if(t==="__local__")return"\u672A\u7ED1\u5B9A\u7FA4 / \u672C\u5730\u767D\u677F";let o=a.get(t);return o&&o!==t?`${o} (${t})`:t}function K(t,a){let o=new Map;for(let i of t){let n=F(i),c=o.get(n)??[];c.push(i),o.set(n,c)}return[...o.entries()].map(([i,n])=>({chatId:i,label:G(i,a),rows:[...n].sort((c,b)=>b.updatedAt.localeCompare(c.updatedAt))})).sort((i,n)=>i.label.localeCompare(n.label))}function z(){return decodeURIComponent((location.hash.match(/^#\/whiteboards\/([^/]+)/)?.[1]??"").trim())}async function E(t,a){let o=await fetch(`/api/whiteboards/${encodeURIComponent(t)}`),i=await o.json().catch(()=>({}));if(o.ok)return{id:t,content:String(i.content??""),row:a.find(n=>n.id===t)}}async function J(t){let a=new Map;if(!t?.ok)return a;let o=await t.json().catch(()=>({})),i=Array.isArray(o.chats)?o.chats:[];for(let n of i)n.chatId&&a.set(String(n.chatId),String(n.name||n.chatId));return a}function Q(t){let a=t.row,o=a.title||a.id;return(0,e.jsxs)("a",{className:`wb-item${t.active?" active":""}`,"data-whiteboard-id":a.id,href:`#/whiteboards/${encodeURIComponent(a.id)}`,onClick:i=>{i.preventDefault(),t.onSelect(a.id)},children:[(0,e.jsx)("div",{className:"wb-item-head",children:(0,e.jsxs)("div",{className:"wb-item-main",children:[(0,e.jsx)("strong",{children:(0,e.jsx)(C,{text:o,textClassName:"wb-title-scroll"})}),(0,e.jsx)("span",{className:"wb-id-text",title:a.id,children:a.id})]})}),(0,e.jsxs)("div",{className:"wb-item-foot",children:[(0,e.jsxs)("div",{className:"wb-item-meta",children:[(0,e.jsx)("span",{children:x(a.updatedAt)}),(0,e.jsx)("span",{children:"\xB7"}),(0,e.jsxs)("span",{children:["log ",a.logCount]})]}),(0,e.jsx)("span",{className:"wb-scope",title:a.scope,children:a.scope})]})]})}function p(t){let a=t.value||"-";return(0,e.jsxs)("div",{className:"wb-meta-card",title:a,children:[(0,e.jsx)("span",{children:t.label}),(0,e.jsx)("strong",{children:a})]})}function V(t){let a=t.selected;if(!a)return(0,e.jsx)("p",{className:"empty",children:"\u9009\u62E9\u5DE6\u4FA7\u767D\u677F\u67E5\u770B meta \u548C board.md\u3002"});let o=a.row,i=o?.chatId?G(o.chatId,t.groupNames):"\u672A\u7ED1\u5B9A\u7FA4 / \u672C\u5730\u767D\u677F",n=o?.title||a.id;return(0,e.jsxs)(e.Fragment,{children:[(0,e.jsxs)("div",{className:"wb-detail-head",children:[(0,e.jsxs)("div",{className:"wb-detail-title",children:[(0,e.jsx)("p",{className:"eyebrow",children:"WHITEBOARD"}),(0,e.jsx)("h2",{title:n,children:n}),(0,e.jsx)("code",{title:a.id,children:a.id})]}),(0,e.jsx)("button",{type:"button",className:"danger","data-delete-whiteboard":!0,onClick:t.onDelete,children:"\u5220\u9664\u767D\u677F"})]}),(0,e.jsxs)("div",{className:"wb-meta-grid",children:[(0,e.jsx)(p,{label:"\u6240\u5C5E\u7FA4",value:i}),(0,e.jsx)(p,{label:"\u8303\u56F4",value:o?.scope??"-"}),(0,e.jsx)(p,{label:"\u6700\u8FD1\u66F4\u65B0",value:o?.updatedAt?x(o.updatedAt):"-"}),(0,e.jsx)(p,{label:"\u6765\u6E90\u76EE\u5F55",value:o?.workingDir??"-"})]}),(0,e.jsxs)("details",{className:"wb-admin-info",children:[(0,e.jsx)("summary",{children:"\u7BA1\u7406\u4FE1\u606F / \u6587\u4EF6\u8DEF\u5F84"}),(0,e.jsx)("code",{children:o?.path??""})]}),(0,e.jsxs)("section",{className:"wb-board-panel",children:[(0,e.jsxs)("div",{className:"wb-board-panel-head",children:[(0,e.jsx)("strong",{children:"board.md"}),(0,e.jsx)("span",{children:"\u53EA\u8BFB\u9884\u89C8"})]}),(0,e.jsx)("pre",{children:a.content||"\uFF08\u6682\u65E0\u5185\u5BB9\uFF09"})]})]})}function X(t){let a=t.selected.row?.title||t.selected.id;return(0,e.jsx)("div",{className:"wb-delete-backdrop","data-delete-modal":!0,onClick:o=>{o.target===o.currentTarget&&t.onCancel()},children:(0,e.jsxs)("div",{className:"wb-delete-dialog",role:"dialog","aria-modal":"true","aria-labelledby":"wb-delete-title",children:[(0,e.jsxs)("div",{className:"wb-delete-body",children:[(0,e.jsx)("div",{className:"wb-delete-mark","aria-hidden":"true",children:"!"}),(0,e.jsxs)("div",{children:[(0,e.jsx)("h3",{id:"wb-delete-title",children:"\u5220\u9664\u767D\u677F\uFF1F"}),(0,e.jsxs)("p",{children:["\u5C06\u5220\u9664 ",(0,e.jsx)("strong",{children:a}),"\uFF08",(0,e.jsx)("code",{children:t.selected.id}),"\uFF09\u7684 board\u3001log\u3001meta\uFF0C\u5E76\u6E05\u7406\u9ED8\u8BA4\u7ED1\u5B9A\u548C\u4F1A\u8BDD\u5F15\u7528\u3002\u6B64\u64CD\u4F5C\u4E0D\u53EF\u6062\u590D\u3002"]})]})]}),(0,e.jsxs)("div",{className:"actions wb-delete-actions",children:[(0,e.jsx)("button",{type:"button","data-delete-cancel":!0,onClick:t.onCancel,disabled:t.deleting,children:"\u53D6\u6D88"}),(0,e.jsx)("button",{type:"button",className:"danger","data-delete-confirm":!0,onClick:t.onConfirm,disabled:t.deleting,children:t.deleting?"\u5220\u9664\u4E2D...":"\u786E\u8BA4\u5220\u9664"})]})]})})}function Y(){let t=B(),a=(0,r.useRef)(!1),o=(0,r.useRef)(0),[i,n]=(0,r.useState)(!1),[c,b]=(0,r.useState)([]),[g,_]=(0,r.useState)(()=>new Map),[m,f]=(0,r.useState)(),[H,S]=(0,r.useState)(!0),[k,M]=(0,r.useState)(null),[u,h]=(0,r.useState)(null),[L,D]=(0,r.useState)(!1),I=(0,r.useMemo)(()=>K(c,g),[c,g]);(0,r.useEffect)(()=>{a.current=!0;let s=z();async function d(){S(!0);try{let[l,y]=await Promise.all([fetch("/api/whiteboards"),fetch("/api/groups").catch(()=>null)]),w=await l.json().catch(()=>({}));if(!l.ok)throw new Error(w?.error??`HTTP ${l.status}`);let q=await J(y),$=Array.isArray(w.whiteboards)?w.whiteboards:[],A;if(s&&(A=await E(s,$)),!a.current)return;n(w.enabled===!0),b($),_(q),f(A),M(null)}catch(l){a.current&&M(l instanceof Error?l.message:String(l))}finally{a.current&&S(!1)}}return d(),()=>{a.current=!1,o.current+=1}},[]);async function U(s){let d=o.current+1;o.current=d;let l=await E(s,c);!a.current||o.current!==d||!l||(f(l),window.history.replaceState(null,"",`#/whiteboards/${encodeURIComponent(s)}`))}async function j(){if(u){D(!0);try{let s=await fetch(`/api/whiteboards/${encodeURIComponent(u.id)}`,{method:"DELETE"}),d=await s.json().catch(()=>({}));if(!s.ok||d.ok===!1)throw new Error(d?.error??`HTTP ${s.status}`);if(!a.current)return;b(l=>l.filter(y=>y.id!==u.id)),m?.id===u.id&&(f(void 0),window.history.replaceState(null,"","#/whiteboards")),h(null)}catch(s){a.current&&window.alert(`\u5220\u9664\u5931\u8D25\uFF1A${s instanceof Error?s.message:String(s)}`)}finally{a.current&&D(!1)}}}let v="\u767D\u677F\u80FD\u529B\u5F53\u524D\u5173\u95ED\uFF1A\u4E0D\u4F1A\u81EA\u52A8\u521B\u5EFA/\u7ED1\u5B9A\u767D\u677F\uFF0C\u4E5F\u4E0D\u4F1A\u6CE8\u5165\u5230 agent prompt\u3002\u5386\u53F2\u767D\u677F\u4EC5\u5728 dashboard \u4E2D\u53EA\u8BFB\u53EF\u89C1\uFF0C\u53EF\u5728\u6B64\u6E05\u7406\u3002",N=(s=!1)=>(0,e.jsx)("div",{className:"page-heading",children:(0,e.jsxs)("div",{children:[(0,e.jsx)("p",{className:"eyebrow",children:t("nav.whiteboards")}),(0,e.jsx)("h1",{children:t("nav.whiteboards")}),s?(0,e.jsx)("span",{className:"wb-disabled-pill",title:v,"aria-label":v,children:v}):null]})});return k?(0,e.jsxs)("section",{className:"page whiteboards-page",children:[N(),(0,e.jsxs)("p",{className:"hint-warn",children:["\u52A0\u8F7D\u767D\u677F\u5931\u8D25\uFF1A",k]})]}):H?(0,e.jsxs)("section",{className:"page whiteboards-page","data-whiteboards-host":!0,children:[N(),(0,e.jsx)(W,{label:t("common.loading")})]}):(0,e.jsxs)("section",{className:"page whiteboards-page",children:[N(!i),(0,e.jsxs)("div",{className:"wb-split",children:[(0,e.jsx)("section",{className:"overview-block wb-list-block",children:(0,e.jsx)("div",{className:"wb-list-panel",children:I.length===0?(0,e.jsx)("p",{className:"empty wb-empty",children:"\u6682\u65E0\u767D\u677F\u3002\u6253\u5F00\u80FD\u529B\u540E\uFF0C\u6BCF\u4E2A\u7FA4\u9996\u6B21\u9700\u8981\u767D\u677F\u65F6\u624D\u4F1A\u521B\u5EFA\u9ED8\u8BA4\u767D\u677F\u3002"}):I.map(s=>(0,e.jsxs)("details",{className:"wb-group",open:!0,children:[(0,e.jsxs)("summary",{children:[(0,e.jsx)("span",{className:"wb-group-title",children:(0,e.jsx)(C,{text:s.label,textClassName:"wb-group-title-scroll"})}),(0,e.jsx)("small",{children:s.rows.length})]}),(0,e.jsx)("div",{className:"wb-group-items",children:s.rows.map(d=>(0,e.jsx)(Q,{row:d,active:m?.id===d.id,onSelect:l=>{U(l)}},d.id))})]},s.chatId))})}),(0,e.jsx)("section",{className:"overview-block wb-detail-block",children:(0,e.jsx)("div",{className:"wb-detail-panel",id:"whiteboard-detail",children:(0,e.jsx)(V,{selected:m,groupNames:g,onDelete:()=>{m&&h(m)}})})})]}),u?(0,e.jsx)(X,{selected:u,deleting:L,onCancel:()=>h(null),onConfirm:()=>{j()}}):null]})}function ae(t){return P(t,(0,e.jsx)(Y,{}))}export{ae as renderWhiteboardsPage};
package/dist/dashboard.js CHANGED
@@ -1911,6 +1911,7 @@ function configuredBotAgentFields() {
1911
1911
  wrapperCli: b.wrapperCli,
1912
1912
  model: b.model,
1913
1913
  reasoningEffort: b.reasoningEffort,
1914
+ turnTimeoutMs: b.turnTimeoutMs,
1914
1915
  }]));
1915
1916
  }
1916
1917
  catch {
@@ -1928,6 +1929,7 @@ function withConfiguredCliId(bot, ids) {
1928
1929
  wrapperCli: bot.wrapperCli || fallback?.wrapperCli,
1929
1930
  model: bot.model || fallback?.model,
1930
1931
  reasoningEffort: bot.reasoningEffort || fallback?.reasoningEffort,
1932
+ turnTimeoutMs: bot.turnTimeoutMs ?? fallback?.turnTimeoutMs,
1931
1933
  };
1932
1934
  }
1933
1935
  function liveBots() {
@@ -3484,7 +3486,14 @@ const server = createServer(async (req, res) => {
3484
3486
  if (req.method === 'GET' && url.pathname === '/api/skills') {
3485
3487
  return jsonRes(res, 200, dashboardSkillsPayload());
3486
3488
  }
3487
- if (req.method === 'DELETE' && url.pathname === '/api/skills') {
3489
+ // Batch skill removal. POST /api/skills/remove is the canonical route the
3490
+ // dashboard UI calls: the payload (names[], force) must travel in the body,
3491
+ // and DELETE bodies are dropped by the platform dashboard proxy (it assumes
3492
+ // DELETE carries no body, forwards content-length but never pipes the bytes,
3493
+ // so readJsonBody hangs until the outer gateway returns 504). DELETE
3494
+ // /api/skills stays as an alias for direct/scripted callers.
3495
+ if ((req.method === 'DELETE' && url.pathname === '/api/skills')
3496
+ || (req.method === 'POST' && url.pathname === '/api/skills/remove')) {
3488
3497
  let parsed;
3489
3498
  try {
3490
3499
  parsed = await readJsonBody(req);
@@ -4735,6 +4744,7 @@ const server = createServer(async (req, res) => {
4735
4744
  wrapperCli: j.wrapperCli || d.wrapperCli,
4736
4745
  model: j.model || d.model,
4737
4746
  reasoningEffort: j.reasoningEffort || d.reasoningEffort,
4747
+ turnTimeoutMs: typeof j.turnTimeoutMs === 'number' ? j.turnTimeoutMs : d.turnTimeoutMs,
4738
4748
  }, j);
4739
4749
  }
4740
4750
  catch (e) {