wormclaude 1.0.221 → 1.0.223
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/i18n.js +2 -0
- package/dist/theme.js +1 -1
- package/dist/tui.js +26 -2
- package/package.json +1 -1
package/dist/i18n.js
CHANGED
|
@@ -95,6 +95,7 @@ const STR = {
|
|
|
95
95
|
'tui.mcpConnected': '🔌 {0} MCP sunucusu bağlandı',
|
|
96
96
|
'tui.autoCompacted': '✎ bağlam otomatik özetlendi',
|
|
97
97
|
'tui.loopStop': 'Aynı adım tekrarlandı, döngü önlemek için durduruldu.',
|
|
98
|
+
'tui.userStopped': '■ durduruldu (Esc).',
|
|
98
99
|
'tui.connErr': '[bağlantı hatası: {0}]',
|
|
99
100
|
'tui.learned': '✎ eğitim datasına eklendi',
|
|
100
101
|
'tui.userCancel': 'kullanıcı iptal etti',
|
|
@@ -162,6 +163,7 @@ const STR = {
|
|
|
162
163
|
'tui.mcpConnected': '🔌 {0} MCP server(s) connected',
|
|
163
164
|
'tui.autoCompacted': '✎ context auto-summarized',
|
|
164
165
|
'tui.loopStop': 'Same step repeated, stopped to avoid a loop.',
|
|
166
|
+
'tui.userStopped': '■ stopped (Esc).',
|
|
165
167
|
'tui.connErr': '[connection error: {0}]',
|
|
166
168
|
'tui.learned': '',
|
|
167
169
|
'tui.userCancel': 'user cancelled',
|
package/dist/theme.js
CHANGED
package/dist/tui.js
CHANGED
|
@@ -506,8 +506,18 @@ export async function runTui() {
|
|
|
506
506
|
}
|
|
507
507
|
}
|
|
508
508
|
flushStream(true); // kalan yarım satırı bas
|
|
509
|
-
if (turnAbort?.signal.aborted)
|
|
510
|
-
|
|
509
|
+
if (turnAbort?.signal.aborted) {
|
|
510
|
+
// Blackbox gibi: iptal edilince modelin ürettiği KISMİ yanıtı transcript'e koru.
|
|
511
|
+
// (Ekranda akmıştı ama history/displayItems'a girmemişti → resize/redraw'da kaybolur
|
|
512
|
+
// ve sonraki tur model bu bağlamı göremez.) Araçları çalıştırma, turu bitir.
|
|
513
|
+
const partial = stripEchoBlocks(stripInlineToolCalls(cleanModelText(answer))).trim();
|
|
514
|
+
if (partial) {
|
|
515
|
+
history.push({ role: 'assistant', content: partial });
|
|
516
|
+
displayItems.push({ kind: 'assistant', text: partial });
|
|
517
|
+
lastAnswer = partial;
|
|
518
|
+
}
|
|
519
|
+
break;
|
|
520
|
+
}
|
|
511
521
|
// Reactive compact: bağlam taştıysa bir kez özetle ve turu tekrarla → "token bitti, yazılmıyor" olmaz.
|
|
512
522
|
if (gotCtxErr && !reactiveRetried) {
|
|
513
523
|
reactiveRetried = true;
|
|
@@ -795,6 +805,14 @@ export async function runTui() {
|
|
|
795
805
|
} // Hayır / No
|
|
796
806
|
return;
|
|
797
807
|
}
|
|
808
|
+
// ÇALIŞAN TURU DURDUR: perm/ask dialogu YOKKEN Esc → uçuştaki isteği kes (app'i kapatma).
|
|
809
|
+
// Altyapı (turnAbort→signal→api.ts reader.cancel + loop break) hazırdı ama bu dal eksikti:
|
|
810
|
+
// model çok dosya okuyup takıldığında Esc'in hiçbir etkisi olmuyordu.
|
|
811
|
+
if (busy && turnAbort && key && key.name === 'escape') {
|
|
812
|
+
turnAbort.abort();
|
|
813
|
+
printItem({ kind: 'note', text: t('tui.userStopped') });
|
|
814
|
+
return;
|
|
815
|
+
}
|
|
798
816
|
if (key && key.ctrl && key.name === 'c') {
|
|
799
817
|
if (inputBuf) {
|
|
800
818
|
inputBuf = '';
|
|
@@ -802,6 +820,12 @@ export async function runTui() {
|
|
|
802
820
|
refresh();
|
|
803
821
|
return;
|
|
804
822
|
}
|
|
823
|
+
// Tur çalışıyorsa ilk Ctrl+C turu durdurur (app'i kapatmaz); boştayken çift-C çıkış.
|
|
824
|
+
if (busy && turnAbort) {
|
|
825
|
+
turnAbort.abort();
|
|
826
|
+
printItem({ kind: 'note', text: t('tui.userStopped') });
|
|
827
|
+
return;
|
|
828
|
+
}
|
|
805
829
|
const now = Date.now();
|
|
806
830
|
if (now - ctrlcAt < 2000) {
|
|
807
831
|
quit();
|