beast-agent 1.2.0 → 1.2.2
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/package.json +1 -1
- package/scripts/release.js +11 -1
- package/src/renderer/index.html +1 -1
- package/src/renderer/renderer.js +28 -4
- package/src/renderer/style.css +29 -11
package/package.json
CHANGED
package/scripts/release.js
CHANGED
|
@@ -108,7 +108,17 @@ step('5/5 OneDrive yedek (beast-v' + next + ')');
|
|
|
108
108
|
try {
|
|
109
109
|
const dest = path.join(ONE_DRIVE_DIR, 'beast-v' + next);
|
|
110
110
|
fs.mkdirSync(dest, { recursive: true });
|
|
111
|
-
|
|
111
|
+
/* robocopy 0-7 arası TÜM çıkış kodları başarıdır (1 = dosya kopyalandı);
|
|
112
|
+
execSync 0 dışını hata sanır — kodu burada yut, gerçek hatada (>7) dur */
|
|
113
|
+
try {
|
|
114
|
+
execSync(
|
|
115
|
+
`robocopy "${ROOT}" "${dest}" /E /XD node_modules dist "beast agent web" .git /NFL /NDL /NJH`,
|
|
116
|
+
{ cwd: ROOT, stdio: 'pipe' }
|
|
117
|
+
);
|
|
118
|
+
} catch (e) {
|
|
119
|
+
const code = e && e.status;
|
|
120
|
+
if (!(typeof code === 'number' && code < 8)) throw e;
|
|
121
|
+
}
|
|
112
122
|
const info = path.join(dest, `YEDEK-BILGI-v${next}.txt`);
|
|
113
123
|
fs.writeFileSync(info, `BEAST AGENT v${next} — ${new Date().toLocaleString('tr-TR')}\nKaynak: ${ROOT}\nGitHub: https://github.com/algokodcom/beast-agent/releases/tag/${tag}\nnpm: https://www.npmjs.com/package/beast-agent\n`);
|
|
114
124
|
ok(dest);
|
package/src/renderer/index.html
CHANGED
|
@@ -133,7 +133,7 @@
|
|
|
133
133
|
<div id="bcStatus" hidden></div>
|
|
134
134
|
<div id="bcInputRow">
|
|
135
135
|
<span id="bcPrompt">code></span>
|
|
136
|
-
<
|
|
136
|
+
<textarea id="bcInput" rows="1" spellcheck="false" autocomplete="off" placeholder="Beast Code mesajı yaz — Enter ile gönder…" data-i18n-ph="bc_ph"></textarea>
|
|
137
137
|
<button id="bcStop" title="Çalışan mesajı durdur" hidden data-i18n-title="bc_stop">■︎</button>
|
|
138
138
|
</div>
|
|
139
139
|
</div>
|
package/src/renderer/renderer.js
CHANGED
|
@@ -3845,12 +3845,18 @@ function renderAgentRail() {
|
|
|
3845
3845
|
const when = j.startedAt
|
|
3846
3846
|
? new Date(j.startedAt).toLocaleTimeString('tr-TR', { hour: '2-digit', minute: '2-digit' })
|
|
3847
3847
|
: '';
|
|
3848
|
+
/* iptal sebebi LİSTEDE yazmaz (yatay scroll çıkarır) — tooltip + açınca
|
|
3849
|
+
detaydaki .ag-err satırında görünür */
|
|
3850
|
+
const abortTip =
|
|
3851
|
+
j.status === 'aborted' && j.error
|
|
3852
|
+
? ` title="İptal sebebi: ${escapeHtml(String(j.error).slice(0, 200))}"`
|
|
3853
|
+
: '';
|
|
3848
3854
|
row.innerHTML =
|
|
3849
3855
|
`<div class="rj-head">` +
|
|
3850
3856
|
`<span class="ag-dot"></span>` +
|
|
3851
3857
|
`<span class="sess-title">${escapeHtml(j.title)}</span>` +
|
|
3852
3858
|
(j.code ? `<span class="sess-code" title="Oturum kodu">${escapeHtml(j.code)}</span>` : ``) +
|
|
3853
|
-
`<span class="rj-time">${j.status === 'running' ? when + ' · ' + agentTimerHtml(j.startedAt) + ' · ' + _t('ag_working') : (agStText(j.status) === _t('ag_st_done') ? '\u2713' : (agStText(j.status) || j.status)
|
|
3859
|
+
`<span class="rj-time"${abortTip}>${j.status === 'running' ? when + ' · ' + agentTimerHtml(j.startedAt) + ' · ' + _t('ag_working') : (agStText(j.status) === _t('ag_st_done') ? '\u2713' : (agStText(j.status) || j.status))}</span>` +
|
|
3854
3860
|
(j.status === 'running'
|
|
3855
3861
|
? `<button class="rj-cancel" title="${_t('ag_cancel')}">×</button>`
|
|
3856
3862
|
: `<button class="rj-cancel" title="${_t('ag_delete')}"><svg viewBox="0 0 24 24" width="12" height="12" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M3 6h18"/><path d="M8 6V4a1 1 0 0 1 1-1h6a1 1 0 0 1 1 1v2"/><path d="M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6"/><path d="M10 11v6M14 11v6"/></svg></button>`) +
|
|
@@ -6794,10 +6800,24 @@ function bcIngest(ev) {
|
|
|
6794
6800
|
}
|
|
6795
6801
|
}
|
|
6796
6802
|
|
|
6803
|
+
/* Beast Code input otomatik büyür: textarea'da satır sonuna gelince alan
|
|
6804
|
+
aşağı açılır; 140px (≈6 satır) tavanını aşarsa iç scroll'a döner */
|
|
6805
|
+
function bcInputResize() {
|
|
6806
|
+
const ta = els.bcInput;
|
|
6807
|
+
if (!ta) return;
|
|
6808
|
+
ta.style.height = 'auto';
|
|
6809
|
+
const max = 140;
|
|
6810
|
+
const h = Math.min(ta.scrollHeight, max);
|
|
6811
|
+
ta.style.height = h + 'px';
|
|
6812
|
+
ta.classList.toggle('expand', ta.scrollHeight > max);
|
|
6813
|
+
}
|
|
6814
|
+
|
|
6797
6815
|
function bcRunCurrent() {
|
|
6798
6816
|
const msg = els.bcInput.value.trim();
|
|
6799
6817
|
if (!msg) return;
|
|
6800
6818
|
els.bcInput.value = '';
|
|
6819
|
+
bcInputResize();
|
|
6820
|
+
els.bcInput.focus();
|
|
6801
6821
|
bcLine('t-cmd', 'code> ' + msg);
|
|
6802
6822
|
bcHideTodos(); /* yeni sorgu = eski todo list temizlenir; agent yeniden basacak */
|
|
6803
6823
|
bcSetBusy(true);
|
|
@@ -6824,9 +6844,13 @@ function bcRunCurrent() {
|
|
|
6824
6844
|
});
|
|
6825
6845
|
}
|
|
6826
6846
|
|
|
6827
|
-
if (els.bcInput)
|
|
6828
|
-
|
|
6829
|
-
|
|
6847
|
+
if (els.bcInput) {
|
|
6848
|
+
els.bcInput.addEventListener('input', bcInputResize);
|
|
6849
|
+
els.bcInput.addEventListener('keydown', (e) => {
|
|
6850
|
+
/* Enter gönderir, Shift+Enter alt satıra iner (klasik chat input'u) */
|
|
6851
|
+
if (e.key === 'Enter' && !e.shiftKey) { e.preventDefault(); bcRunCurrent(); }
|
|
6852
|
+
});
|
|
6853
|
+
}
|
|
6830
6854
|
if (els.bcStop) els.bcStop.addEventListener('click', () => beast.beastcodeStop().catch(() => {}));
|
|
6831
6855
|
if (els.bcClear) els.bcClear.addEventListener('click', () => {
|
|
6832
6856
|
els.bcOut.innerHTML = '';
|
package/src/renderer/style.css
CHANGED
|
@@ -974,13 +974,12 @@ body.term-open #settingsOverlay { right: var(--tw, 520px); }
|
|
|
974
974
|
user-select: none;
|
|
975
975
|
}
|
|
976
976
|
.diff-code { flex: 1; padding-right: 10px; }
|
|
977
|
-
/* kırmızı: silinen/eski (sol) — yeşil: eklenen/yeni (sağ)
|
|
978
|
-
|
|
979
|
-
.diff-line.del
|
|
980
|
-
.diff-line.del .diff-num { color:
|
|
981
|
-
.diff-line.add { background: rgba(34, 197, 94, 0.
|
|
982
|
-
.diff-line.add .diff-code { color:
|
|
983
|
-
.diff-line.add .diff-num { color: #4ade80; opacity: 0.8; }
|
|
977
|
+
/* kırmızı: silinen/eski (sol) — yeşil: eklenen/yeni (sağ)
|
|
978
|
+
YAZI rengi normal kalır (siyah) — yalnız ARKA PLAN renkli */
|
|
979
|
+
.diff-line.del { background: rgba(239, 68, 68, 0.18); }
|
|
980
|
+
.diff-line.del .diff-code, .diff-line.del .diff-num { color: var(--text); }
|
|
981
|
+
.diff-line.add { background: rgba(34, 197, 94, 0.2); }
|
|
982
|
+
.diff-line.add .diff-code, .diff-line.add .diff-num { color: var(--text); }
|
|
984
983
|
.diff-line.ctx .diff-code { color: var(--muted); }
|
|
985
984
|
.diff-line.space { background: rgba(128, 128, 128, 0.06); }
|
|
986
985
|
.diff-more {
|
|
@@ -1770,7 +1769,7 @@ body.browser-open #settingsDialog { width: min(70vw, calc(100vw - var(--bw, 480p
|
|
|
1770
1769
|
#railClear svg { display: block; }
|
|
1771
1770
|
}
|
|
1772
1771
|
|
|
1773
|
-
#railList { flex: 1; overflow-y: auto; padding: 4px 8px; }
|
|
1772
|
+
#railList { flex: 1; overflow-y: auto; overflow-x: hidden; padding: 4px 8px; }
|
|
1774
1773
|
|
|
1775
1774
|
.rail-empty {
|
|
1776
1775
|
color: var(--muted);
|
|
@@ -1788,13 +1787,23 @@ body.browser-open #settingsDialog { width: min(70vw, calc(100vw - var(--bw, 480p
|
|
|
1788
1787
|
border-radius: 7px;
|
|
1789
1788
|
cursor: pointer;
|
|
1790
1789
|
color: var(--muted);
|
|
1790
|
+
min-width: 0;
|
|
1791
|
+
overflow: hidden;
|
|
1791
1792
|
margin-bottom: 2px;
|
|
1792
1793
|
}
|
|
1793
1794
|
.rj:hover { background: var(--panel2); color: var(--text); }
|
|
1794
1795
|
.rj.open { background: var(--panel2); color: var(--text); }
|
|
1795
1796
|
.rj-head { display: flex; align-items: center; gap: 6px; min-width: 0; }
|
|
1796
1797
|
.rj .sess-title { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 13px; }
|
|
1797
|
-
.rj-time {
|
|
1798
|
+
.rj-time {
|
|
1799
|
+
font-size: 10.5px;
|
|
1800
|
+
color: var(--muted);
|
|
1801
|
+
flex: 0 1 auto;
|
|
1802
|
+
min-width: 0;
|
|
1803
|
+
white-space: nowrap;
|
|
1804
|
+
overflow: hidden;
|
|
1805
|
+
text-overflow: ellipsis;
|
|
1806
|
+
}
|
|
1798
1807
|
.rj.st-done .rj-time { color: #43c463; font-weight: 700; }
|
|
1799
1808
|
.rj-cancel {
|
|
1800
1809
|
visibility: hidden;
|
|
@@ -2208,13 +2217,15 @@ body.ide-mode #bcPanel { display: flex; }
|
|
|
2208
2217
|
#bcInputRow {
|
|
2209
2218
|
flex: none;
|
|
2210
2219
|
display: flex;
|
|
2211
|
-
align-items:
|
|
2220
|
+
align-items: flex-end;
|
|
2212
2221
|
gap: 6px;
|
|
2213
2222
|
padding: 10px 12px;
|
|
2214
2223
|
border-top: 1px solid var(--border);
|
|
2215
2224
|
background: var(--panel);
|
|
2216
2225
|
}
|
|
2217
|
-
#bcPrompt { color: var(--accent); font-family: Consolas, monospace; font-size: 12px; font-weight: 700; flex: none; }
|
|
2226
|
+
#bcPrompt { color: var(--accent); font-family: Consolas, monospace; font-size: 12px; font-weight: 700; flex: none; padding-bottom: 7px; }
|
|
2227
|
+
/* otomatik büyüyen chat input'u: satır sonunda alt satıra iner, alan açılır;
|
|
2228
|
+
tavanı (140px ≈ 6 satır) aşarsa kendi içinde scroll'a döner */
|
|
2218
2229
|
#bcInput {
|
|
2219
2230
|
flex: 1;
|
|
2220
2231
|
min-width: 0;
|
|
@@ -2226,7 +2237,13 @@ body.ide-mode #bcPanel { display: flex; }
|
|
|
2226
2237
|
font-family: Consolas, monospace;
|
|
2227
2238
|
font-size: 12.5px;
|
|
2228
2239
|
outline: none;
|
|
2240
|
+
resize: none;
|
|
2241
|
+
overflow-y: hidden;
|
|
2242
|
+
max-height: 140px;
|
|
2243
|
+
line-height: 1.45;
|
|
2244
|
+
display: block;
|
|
2229
2245
|
}
|
|
2246
|
+
#bcInput.expand { overflow-y: auto; }
|
|
2230
2247
|
#bcInput:focus { border-color: var(--accent); }
|
|
2231
2248
|
#bcStop {
|
|
2232
2249
|
flex: none;
|
|
@@ -2238,6 +2255,7 @@ body.ide-mode #bcPanel { display: flex; }
|
|
|
2238
2255
|
font-size: 11px;
|
|
2239
2256
|
padding: 4px 8px;
|
|
2240
2257
|
line-height: 1;
|
|
2258
|
+
margin-bottom: 3px;
|
|
2241
2259
|
}
|
|
2242
2260
|
#bcStop[hidden] { display: none; }
|
|
2243
2261
|
#bcStop:hover { border-color: var(--err); }
|