fix: stabilize local folder AI document workflow

- scope local-folder PageTree revision and document sidebar rendering to fileTreeScope

- preserve projected table/image attrs for local Markdown aggregate fallback

- avoid FileTree restore forced layouts on cold design open

- add API ChatOnly provider runtime and local OCR task handling regressions
This commit is contained in:
lix-2026
2026-06-02 17:17:49 +08:00
parent 610b23d3a5
commit 9f4b5c4d48
27 changed files with 3825 additions and 229 deletions
@@ -265,7 +265,9 @@ export function createSidebarPageAiRenderRuntime(context) {
var chatOnlyOptions = pageAiChatOnlyProfileEntries().map(function(profile) {
var spec = pageAiChatOnlyProfileSpec(profile);
var label = profile.menuLabel || (spec && spec.label) || pageAiProfileDisplayLabel(profile, '');
return pageAiRenderAgentProfileOption('chat_only', profile, label, '网页问答 · 不申请文件写权限');
var providerKind = String(profile.providerKind || (spec && spec.providerKind) || '').trim();
var detail = providerKind === 'api-chat' ? 'API 聊天 · 不申请文件写权限' : '网页问答 · 不申请文件写权限';
return pageAiRenderAgentProfileOption('chat_only', profile, label, detail);
}).join('');
var hermesOptions = pageAiHermesProfileEntries().map(function(profile) {
var profileId = pageAiProfileValue(profile);