@yemi33/minions 0.1.271 → 0.1.272

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/CHANGELOG.md CHANGED
@@ -1,8 +1,9 @@
1
1
  # Changelog
2
2
 
3
- ## 0.1.271 (2026-04-03)
3
+ ## 0.1.272 (2026-04-03)
4
4
 
5
5
  ### Features
6
+ - sending a new CC message aborts the current request instead of queuing
6
7
  - CC streaming shows cumulative tool list with loading dots
7
8
 
8
9
  ### Fixes
@@ -5,6 +5,7 @@ let _ccMessages = JSON.parse(localStorage.getItem('cc-messages') || '[]');
5
5
  let _ccOpen = false;
6
6
  let _ccSending = false;
7
7
  let _ccQueue = [];
8
+ let _ccAbortController = null;
8
9
  // Clear stale sending state on page load — SSE streams don't survive refresh
9
10
  try { localStorage.removeItem('cc-sending'); } catch {}
10
11
 
@@ -109,13 +110,18 @@ async function ccSend() {
109
110
  if (!message) return;
110
111
  input.value = '';
111
112
 
112
- // If already processing, queue the message and show it it'll send when current finishes
113
+ // If already processing, abort current and send the new one immediately
113
114
  if (_ccSending) {
114
- _ccQueue.push(message);
115
- ccAddMessage('user', escHtml(message));
116
- const preview = message.split(/\s+/).slice(0, 6).join(' ') + (message.split(/\s+/).length > 6 ? '...' : '');
117
- ccAddMessage('assistant', '<span class="cc-queued-pill" style="color:var(--muted);font-size:10px">Queued: "' + escHtml(preview) + '" — will send after current request</span>');
118
- return;
115
+ if (_ccAbortController) {
116
+ _ccAbortController.abort();
117
+ _ccAbortController = null;
118
+ }
119
+ _ccSending = false;
120
+ // Mark current streaming message as interrupted
121
+ var lastEl = document.getElementById('cc-messages').lastElementChild;
122
+ if (lastEl && (lastEl.innerHTML.includes('Thinking') || lastEl.innerHTML.includes('\uD83D\uDD27'))) {
123
+ lastEl.innerHTML += '<div style="font-size:9px;color:var(--muted);margin-top:4px;font-style:italic">(interrupted)</div>';
124
+ }
119
125
  }
120
126
  await _ccDoSend(message);
121
127
 
@@ -134,6 +140,7 @@ async function ccSend() {
134
140
 
135
141
  async function _ccDoSend(message, skipUserMsg) {
136
142
  _ccSending = true;
143
+ _ccAbortController = new AbortController();
137
144
  try { localStorage.setItem('cc-sending', JSON.stringify({ sending: true, startedAt: Date.now() })); } catch {}
138
145
 
139
146
  if (!skipUserMsg) ccAddMessage('user', escHtml(message));
@@ -178,7 +185,7 @@ async function _ccDoSend(message, skipUserMsg) {
178
185
  const res = await fetch('/api/command-center/stream', {
179
186
  method: 'POST', headers: { 'Content-Type': 'application/json' },
180
187
  body: JSON.stringify({ message }),
181
- signal: AbortSignal.timeout(960000)
188
+ signal: _ccAbortController ? _ccAbortController.signal : AbortSignal.timeout(960000)
182
189
  });
183
190
 
184
191
  if (!res.ok) {
@@ -297,6 +304,7 @@ async function _ccDoSend(message, skipUserMsg) {
297
304
  '<button id="' + retryId + '" onclick="ccRetryLast()" style="margin-top:6px;padding:4px 12px;background:var(--surface2);border:1px solid var(--border);border-radius:4px;color:var(--blue);cursor:pointer;font-size:11px">Retry</button>');
298
305
  } finally {
299
306
  _ccSending = false;
307
+ _ccAbortController = null;
300
308
  try { localStorage.removeItem('cc-sending'); } catch {}
301
309
  // Show notification badge on CC button if drawer is closed
302
310
  if (!_ccOpen) showNotifBadge(document.getElementById('cc-toggle-btn'));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yemi33/minions",
3
- "version": "0.1.271",
3
+ "version": "0.1.272",
4
4
  "description": "Multi-agent AI dev team that runs from ~/.minions/ — five autonomous agents share a single engine, dashboard, and knowledge base",
5
5
  "bin": {
6
6
  "minions": "bin/minions.js"