Skip to content

A team of long-lived bots for DeepSeek Harness, with main bots, bot-to-bot messages and group chats.

Merge remote-tracking branch 'origin/dev' into feat/handoff-card

Fei241180ea5228725f
diff --cc ds-bot/client.js
index 6b946e41,c2312a5f..00524466
--- a/ds-bot/client.js
+++ b/ds-bot/client.js
@@@ -5590,15 -5444,15 +5594,15 @@@ var cssValue = (value) => String(value)
function frameDocument(html, vars = {}) {
const root = Object.entries(vars).map(([name, value]) => `${name}:${cssValue(value)}`).join(";");
const report = `(()=>{const send=()=>parent.postMessage({type:${JSON.stringify(HEIGHT)},height:Math.ceil(document.documentElement.getBoundingClientRect().height)},'*');new ResizeObserver(send).observe(document.documentElement);addEventListener('load',send);addEventListener('message',e=>{if(e.source!==parent||!e.data||e.data.type!==${JSON.stringify(THEME)})return;for(const[k,v]of Object.entries(e.data.vars||{}))document.documentElement.style.setProperty(k,String(v))})})()`;
- return `<!doctype html><html><head><meta charset="utf-8"><meta http-equiv="Content-Security-Policy" content="${FRAME_POLICY}"><style>:root{${root}}html,body{margin:0;padding:0;background:transparent;color:var(--bt-ink);font:14px/22px -apple-system,BlinkMacSystemFont,"Segoe UI",system-ui,sans-serif}*{box-sizing:border-box}</style><script>${report}<\/script></head><body>${html}</body></html>`;
+ return `<!doctype html><html><head><meta charset="utf-8"><meta http-equiv="Content-Security-Policy" content="${FRAME_POLICY}"><style>:root{${root}}html,body{margin:0;padding:0;background:transparent;color:var(--bt-ink);font:14px/22px -apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif}*{box-sizing:border-box}</style><script>${report}<\/script></head><body>${html}</body></html>`;
}
function HtmlFrame({ node }) {
- const frame = (0, import_react7.useRef)(null);
- const loads = (0, import_react7.useRef)(0);
- const [height, setHeight] = (0, import_react7.useState)(Number.isFinite(node.height) ? node.height : 120);
- const [stopped, setStopped] = (0, import_react7.useState)(false);
- const doc = (0, import_react7.useMemo)(() => frameDocument(String(node.html ?? ""), themeVars2()), [node.html]);
- (0, import_react7.useEffect)(() => {
+ const frame = (0, import_react8.useRef)(null);
+ const loads = (0, import_react8.useRef)(0);
+ const [height, setHeight] = (0, import_react8.useState)(Number.isFinite(node.height) ? node.height : 120);
+ const [stopped, setStopped] = (0, import_react8.useState)(false);
+ const doc = (0, import_react8.useMemo)(() => frameDocument(String(node.html ?? ""), themeVars2()), [node.html]);
+ (0, import_react8.useEffect)(() => {
const onMessage = (event) => {
if (event.source !== frame.current?.contentWindow || event.data?.type !== HEIGHT) return;
const next = Number(event.data.height);