open-agents-ai 0.187.215 → 0.187.216
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/dist/index.js +69 -12
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -316896,17 +316896,16 @@ body {
|
|
|
316896
316896
|
|
|
316897
316897
|
/* WO-TASK-02 — task progress strip (shares processes-row styling) */
|
|
316898
316898
|
#tasks-row {
|
|
316899
|
-
display: none; /* hidden until tasks exist */
|
|
316899
|
+
display: none; /* hidden until tasks exist; flipped to flex when populated */
|
|
316900
|
+
flex-flow: row wrap; /* wrap items onto multiple lines for long lists */
|
|
316900
316901
|
align-items: center;
|
|
316901
|
-
gap: 6px;
|
|
316902
|
+
gap: 6px 6px; /* row gap + column gap once wrapping kicks in */
|
|
316902
316903
|
padding: 4px 16px;
|
|
316903
316904
|
min-height: 22px;
|
|
316904
316905
|
background: #17171a;
|
|
316905
316906
|
border-bottom: 1px solid #2a2a30;
|
|
316906
|
-
|
|
316907
|
-
scrollbar-width: none;
|
|
316907
|
+
/* Wrap instead of horizontal scroll so all tasks are visible */
|
|
316908
316908
|
}
|
|
316909
|
-
#tasks-row::-webkit-scrollbar { display: none; }
|
|
316910
316909
|
#tasks-row .tasks-label {
|
|
316911
316910
|
color: #444;
|
|
316912
316911
|
font-size: 0.55rem;
|
|
@@ -317707,17 +317706,75 @@ async function sendMessage() {
|
|
|
317707
317706
|
details.style.cssText = 'background:#1e1e22;border-left:2px solid #b2920a;margin:2px 0;font-size:0.7rem';
|
|
317708
317707
|
const summary = document.createElement('summary');
|
|
317709
317708
|
summary.style.cssText = 'padding:4px 8px;color:#b2920a;cursor:pointer';
|
|
317710
|
-
|
|
317709
|
+
|
|
317710
|
+
// Build a compact one-line label so the user sees what the tool
|
|
317711
|
+
// is actually doing without expanding. todo_write gets a special
|
|
317712
|
+
// status-counter summary; everything else gets a short args
|
|
317713
|
+
// preview that JSON-stringifies arrays/objects so they don't
|
|
317714
|
+
// render as "[object Object],[object Object],...".
|
|
317715
|
+
const toolName = chunk.tool || 'tool';
|
|
317716
|
+
const a = (chunk.args && typeof chunk.args === 'object') ? chunk.args : {};
|
|
317717
|
+
let inlineSummary = '';
|
|
317718
|
+
if (toolName === 'todo_write' && Array.isArray(a.todos)) {
|
|
317719
|
+
const todos = a.todos;
|
|
317720
|
+
let p = 0, ip = 0, c = 0, b = 0;
|
|
317721
|
+
for (const t of todos) {
|
|
317722
|
+
const s = (t && typeof t === 'object') ? t.status : '';
|
|
317723
|
+
if (s === 'completed') c++;
|
|
317724
|
+
else if (s === 'in_progress') ip++;
|
|
317725
|
+
else if (s === 'blocked') b++;
|
|
317726
|
+
else p++;
|
|
317727
|
+
}
|
|
317728
|
+
inlineSummary = ' — ' + todos.length + ' items (' + c + '◉ ' + ip + '◐ ' + p + '〇' + (b > 0 ? ' ' + b + '◍' : '') + ')';
|
|
317729
|
+
} else {
|
|
317730
|
+
const previewParts = [];
|
|
317731
|
+
for (const [k, v] of Object.entries(a)) {
|
|
317732
|
+
let vs;
|
|
317733
|
+
if (v === null || v === undefined) vs = String(v);
|
|
317734
|
+
else if (typeof v === 'string') vs = v;
|
|
317735
|
+
else if (typeof v === 'number' || typeof v === 'boolean') vs = String(v);
|
|
317736
|
+
else { try { vs = JSON.stringify(v); } catch { vs = '[object]'; } }
|
|
317737
|
+
if (vs.length > 60) vs = vs.slice(0, 57) + '…';
|
|
317738
|
+
previewParts.push(k + '=' + vs);
|
|
317739
|
+
if (previewParts.length >= 3) break;
|
|
317740
|
+
}
|
|
317741
|
+
if (previewParts.length) inlineSummary = ' — ' + previewParts.join(', ');
|
|
317742
|
+
}
|
|
317743
|
+
summary.textContent = '▸ ' + toolName + inlineSummary;
|
|
317711
317744
|
details.appendChild(summary);
|
|
317712
|
-
|
|
317745
|
+
|
|
317746
|
+
// Expandable args — unpack all key-value pairs. CRITICAL: stringify
|
|
317747
|
+
// arrays/objects so they don't show as "[object Object]". For
|
|
317748
|
+
// todo_write specifically render a checklist instead of a blob.
|
|
317713
317749
|
if (chunk.args && typeof chunk.args === 'object') {
|
|
317714
317750
|
const argsDiv = document.createElement('div');
|
|
317715
317751
|
argsDiv.style.cssText = 'padding:4px 8px 6px 16px;color:#888;font-size:0.65rem;border-top:1px solid #2a2a30';
|
|
317716
|
-
|
|
317717
|
-
const
|
|
317718
|
-
|
|
317719
|
-
|
|
317720
|
-
|
|
317752
|
+
if (toolName === 'todo_write' && Array.isArray(a.todos)) {
|
|
317753
|
+
for (const t of a.todos) {
|
|
317754
|
+
if (!t || typeof t !== 'object') continue;
|
|
317755
|
+
const row = document.createElement('div');
|
|
317756
|
+
row.style.cssText = 'padding:2px 0';
|
|
317757
|
+
let mark = '〇';
|
|
317758
|
+
let color = '#666';
|
|
317759
|
+
if (t.status === 'completed') { mark = '◉'; color = '#4a7a4a'; }
|
|
317760
|
+
else if (t.status === 'in_progress') { mark = '◐'; color = '#b2920a'; }
|
|
317761
|
+
else if (t.status === 'blocked') { mark = '◍'; color = '#b25f5f'; }
|
|
317762
|
+
row.innerHTML = '<span style="color:' + color + '">' + mark + '</span> <span style="color:#b0b0b0">' + escHtml(String(t.content || '').slice(0, 300)) + '</span>' + (t.blocker ? ' <span style="color:#b25f5f">(blocked: ' + escHtml(String(t.blocker).slice(0, 100)) + ')</span>' : '');
|
|
317763
|
+
argsDiv.appendChild(row);
|
|
317764
|
+
}
|
|
317765
|
+
} else {
|
|
317766
|
+
for (const [k, v] of Object.entries(chunk.args)) {
|
|
317767
|
+
const row = document.createElement('div');
|
|
317768
|
+
row.style.cssText = 'padding:2px 0;display:flex;gap:8px';
|
|
317769
|
+
let vs;
|
|
317770
|
+
if (v === null || v === undefined) vs = String(v);
|
|
317771
|
+
else if (typeof v === 'string') vs = v;
|
|
317772
|
+
else if (typeof v === 'number' || typeof v === 'boolean') vs = String(v);
|
|
317773
|
+
else { try { vs = JSON.stringify(v, null, 2); } catch { vs = '[object]'; } }
|
|
317774
|
+
if (vs.length > 500) vs = vs.slice(0, 497) + '…';
|
|
317775
|
+
row.innerHTML = '<span style="color:#b2920a;min-width:60px">' + k + '</span><span style="color:#b0b0b0;word-break:break-all;white-space:pre-wrap">' + escHtml(vs) + '</span>';
|
|
317776
|
+
argsDiv.appendChild(row);
|
|
317777
|
+
}
|
|
317721
317778
|
}
|
|
317722
317779
|
details.appendChild(argsDiv);
|
|
317723
317780
|
}
|
package/package.json
CHANGED