mirror of
https://gitee.com/mateos/mateclaw.git
synced 2026-09-13 11:13:43 +08:00
Two compounding causes made the management view jump from the config tab back to 'raw' a few seconds after the user selected it: 1. The tab-snap watcher used a single getter returning a new array (`() => [currentKB?.id, workspaceMode]`). Vue compares the returned value with Object.is, so a fresh array reference reports a change on every re-evaluation — including background refreshCurrentKB() calls that reassign the KB object with the same id. That re-ran the snap and forced activeTab back to 'raw'. Switch to an array of getters so each source is compared individually and the callback fires only on a real id/mode change. 2. RawMaterialPanel's onBeforeUnmount cleared the SSE stream and the 60s fallback timer but not the per-raw jobPoller setTimeout chain. While a raw was still processing, leaving the sources tab left that 3s poller running, calling refreshCurrentKB() indefinitely. Clear jobPoller on unmount as well. |
||
|---|---|---|
| .. | ||
| public | ||
| src | ||
| test | ||
| .npmrc | ||
| index.html | ||
| package.json | ||
| pnpm-lock.yaml | ||
| TEST_CASES.md | ||
| tsconfig.json | ||
| vite.config.ts | ||
| vitest.config.ts | ||