- workspace-nav-studio: return null while isLoading so the "工作室" group
no longer briefly mounts and then unmounts when getTokenByEmail returns
"用户不存在" (404). Skeleton branch became dead code, removed.
- studio/hooks: switch all three token queries from retry: 1 to false —
account-not-found is a permanent error; retry just doubled isError latency.
- env: drop VITE_STUDIO_ENABLED everywhere (env.ts + 7 env files +
workspace-nav-chat-list). Sidebar availability is now decided at runtime
by token success instead of a build-time flag.
- env: add VITE_AIPI_PRESENT_URL + VITE_AIPI_KNOWES_URL for the document
upload popup's A-system jump + B-system knowledge iframe; reuse the
existing VITE_AIPI_KNOWLEDGE_URL for the Y-system iframe.
- document-upload-popup: replace 8 hardcoded URLs (6 present, 1 knowes,
1 knowlibrary) with the corresponding env vars.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
- NotebookAIWritingPage reads `token` from URL, fetches space data from
notebook-token API (search_space_id, doc_ids, user_token) and space
name from searchspaces API; keep-alive ping every 50s resets Redis TTL
- Pass user_token as studioToken through AIWritingPage → AIWritingLayout
→ WritingFormPanel → AIWritingPanel → AIWritingForm to skip
getTokenByEmail when studio token is already available
- useStudioNotebooks accepts enabled flag; useNotebookSources accepts
overrideToken to bypass the internal token fetch
- AIWritingForm hides notebook selector when studioToken is provided
(notebook is pre-locked) and pre-selects initialDocumentIds
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- Add document-upload-popup.tsx with tabs for B系统/A系统/Y系统/XWT/upload
- Add network-actor.tsx for XWT search tab
- Add empty.tsx for empty state
- Refactor SourcesDialog: left panel becomes single "上传来源" button that opens new popup
- Wire DocumentUploadDialogProvider around StudioNotebookDetailPage
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>