Consider it done. The open-source AI agent that works out of the box · 想到,就能做到。开源、开箱即用的 AI Agent。
TypeScript agentai-agentai-assistantandroidclaude-codecodexelectroniosllmmacosreact-nativetypescriptwindows
fix(desktop): localize the Mivo reference directory label
shenjiacheng24b5efa04b06
diff --git a/apps/desktop/src/renderer/__tests__/extraDirsButtonPathOverlap.test.ts b/apps/desktop/src/renderer/__tests__/extraDirsButtonPathOverlap.test.tsindex 7880c899f3..8d2e0b87b7 100644--- a/apps/desktop/src/renderer/__tests__/extraDirsButtonPathOverlap.test.ts+++ b/apps/desktop/src/renderer/__tests__/extraDirsButtonPathOverlap.test.ts@@ -102,7 +102,7 @@ describe('pickAndAddExtraDir', () => {system: [library],user: userDirs,});- expect(extraDirDisplayLabel(library)).toBe('Mivo 作品库(只读)');+ expect(extraDirDisplayLabel(library, 'Localized library')).toBe('Localized library');vi.stubGlobal('window', {electronAPI: {diff --git a/apps/desktop/src/renderer/__tests__/extraDirsLibraryLabel.test.tsx b/apps/desktop/src/renderer/__tests__/extraDirsLibraryLabel.test.tsxnew file mode 100644index 0000000000..d4d4351153--- /dev/null+++ b/apps/desktop/src/renderer/__tests__/extraDirsLibraryLabel.test.tsx@@ -0,0 +1,105 @@+// @vitest-environment jsdom++import { act, cleanup, fireEvent, render, screen, within } from '@testing-library/react';+import { createInstance } from 'i18next';+import { I18nextProvider, initReactI18next } from 'react-i18next';+import { afterEach, beforeEach, describe, expect, it, vi } from 'vitest';++import { AtMentionPanel } from '../components/new-chat/AtMentionPanel';+import en from '../i18n/locales/en/common.json';+import ja from '../i18n/locales/ja/common.json';+import ko from '../i18n/locales/ko/common.json';+import zhCN from '../i18n/locales/zh-CN/common.json';+import zhTW from '../i18n/locales/zh-TW/common.json';++const translations = [+ ['en', 'Mivo Library (Read-Only)'],+ ['zh-TW', 'Mivo 作品庫(唯讀)'],+ ['ja', 'Mivo ライブラリ(読み取り専用)'],+ ['ko', 'Mivo 라이브러리(읽기 전용)'],+ ['zh-CN', 'Mivo 作品库(只读)'],+] as const;+const resources = {+ en: { common: en },+ ja: { common: ja },+ ko: { common: ko },+ 'zh-CN': { common: zhCN },+ 'zh-TW': { common: zhTW },+};++beforeEach(() => {+ vi.stubGlobal(+ 'ResizeObserver',+ class {+ observe() {}+ unobserve() {}+ disconnect() {}+ },+ );+ Element.prototype.scrollIntoView ??= () => {};+});+afterEach(() => {+ cleanup();+ vi.unstubAllGlobals();+});++/**+ * #5929: real AtMentionPanel + locale resources, without mocking translation or Tip.+ * Existing quota/path tests cannot observe localized rows or mounted language changes;+ * the menu highlight tests replace useTranslation. Unit/jsdom is needed for this DOM+ * behavior; the minimum failure is one library slot rendered in English.+ */+describe('library reference directory labels', () => {+ it.each([false, true])('updates row and tooltip language with embedded=%s', async (embedded) => {+ const i18n = createInstance();+ await i18n.use(initReactI18next).init({+ lng: 'en',+ fallbackLng: 'en',+ defaultNS: 'common',+ resources,+ interpolation: { escapeValue: false },+ });+ const onRemove = vi.fn();+ // Logical fixture paths: exercise both the system-slot marker and Windows basename.+ const ordinaryDir = 'D:\\reference\\reports\\';+ render(+ <I18nextProvider i18n={i18n}>+ <AtMentionPanel+ embedded={embedded}+ query=""+ state={{ kind: 'ready', items: [], truncated: false }}+ entries={[]}+ focusedIndex={-1}+ onFocusedIndexChange={() => {}}+ onSelect={() => {}}+ onClose={() => {}}+ onRetry={() => {}}+ referenceDirs={{ dirs: ['cindy-library:/fixture/mivo', ordinaryDir], onRemove }}+ />+ </I18nextProvider>,+ );++ for (const [locale, expected] of [...translations, translations[0]]) {+ await act(async () => {+ await i18n.changeLanguage(locale);+ });+ const label = screen.getByText(expected, { selector: 'span' });+ // Inspect each locale itself, so English fallback cannot hide a missing resource.+ expect(i18n.getResource(locale, 'common', 'extraDirs.libraryReadOnlyLabel')).toBe(expected);+ const row = label.closest<HTMLElement>('[data-menu-row]')!;+ expect(within(row).queryByRole('button')).toBeNull();+ fireEvent.focus(label);+ expect((await screen.findByRole('tooltip')).textContent).toBe(expected);+ fireEvent.blur(label);+ }++ const ordinaryLabel = screen.getByText('reports', { selector: 'span' });+ fireEvent.focus(ordinaryLabel);+ expect((await screen.findByRole('tooltip')).textContent).toBe(ordinaryDir);+ fireEvent.blur(ordinaryLabel);+ fireEvent.click(+ within(ordinaryLabel.closest<HTMLElement>('[data-menu-row]')!).getByRole('button'),+ );+ expect(onRemove).toHaveBeenCalledWith(ordinaryDir);+ });+});diff --git a/apps/desktop/src/renderer/components/new-chat/AtMentionPanel.tsx b/apps/desktop/src/renderer/components/new-chat/AtMentionPanel.tsxindex 036bdc88e4..63d11dae3b 100644--- a/apps/desktop/src/renderer/components/new-chat/AtMentionPanel.tsx+++ b/apps/desktop/src/renderer/components/new-chat/AtMentionPanel.tsx@@ -142,6 +142,7 @@ export function AtMentionPanel({maxHeight = 400,}: AtMentionPanelProps) {const { t } = useTranslation();+ const libraryReadOnlyLabel = t('extraDirs.libraryReadOnlyLabel');const rootRef = useRef<HTMLDivElement>(null);const focusedRef = useRef<HTMLButtonElement>(null);const panelRef = useRef<HTMLDivElement | null>(null);@@ -571,12 +572,12 @@ export function AtMentionPanel({className="shrink-0 text-[var(--cmd-palette-item-icon)] opacity-60"/><Tip- text={isLibraryExtraDirSlot(p) ? extraDirDisplayLabel(p) : p}+ text={isLibraryExtraDirSlot(p) ? extraDirDisplayLabel(p, libraryReadOnlyLabel) : p}mono={!isLibraryExtraDirSlot(p)}side="top"><span className="min-w-0 flex-1 truncate text-left">- {extraDirDisplayLabel(p)}+ {extraDirDisplayLabel(p, libraryReadOnlyLabel)}</span></Tip>{isLibraryExtraDirSlot(p) ? null : (diff --git a/apps/desktop/src/renderer/components/new-chat/extraDirsActions.ts b/apps/desktop/src/renderer/components/new-chat/extraDirsActions.tsindex 4bd82f960d..f245c7615f 100644--- a/apps/desktop/src/renderer/components/new-chat/extraDirsActions.ts+++ b/apps/desktop/src/renderer/components/new-chat/extraDirsActions.ts@@ -22,8 +22,8 @@ export function isLibraryExtraDirSlot(dir: string): boolean {return dir.startsWith(LIBRARY_EXTRA_DIR_SLOT_PREFIX);}-export function extraDirDisplayLabel(dir: string): string {- return isLibraryExtraDirSlot(dir) ? 'Mivo 作品库(只读)' : extraDirBasename(dir);+export function extraDirDisplayLabel(dir: string, libraryLabel: string): string {+ return isLibraryExtraDirSlot(dir) ? libraryLabel : extraDirBasename(dir);}export function partitionExtraDirs(dirs: readonly string[]): {diff --git a/apps/desktop/src/renderer/i18n/locales/en/common.json b/apps/desktop/src/renderer/i18n/locales/en/common.jsonindex 1cc77ab5a2..8297d1bc9e 100644--- a/apps/desktop/src/renderer/i18n/locales/en/common.json+++ b/apps/desktop/src/renderer/i18n/locales/en/common.json@@ -14833,6 +14833,7 @@"addUnavailable": "This session can’t be opened in the current split. Open a session in the main area and try again."},"extraDirs": {+ "libraryReadOnlyLabel": "Mivo Library (Read-Only)","retryRemotePlugins": "Remote plugins failed to load. Retry","menuAria": "Composer actions","tooltipEmpty": "More actions",diff --git a/apps/desktop/src/renderer/i18n/locales/ja/common.json b/apps/desktop/src/renderer/i18n/locales/ja/common.jsonindex c3e759b866..2b24da53c0 100644--- a/apps/desktop/src/renderer/i18n/locales/ja/common.json+++ b/apps/desktop/src/renderer/i18n/locales/ja/common.json@@ -14778,6 +14778,7 @@"addUnavailable": "このセッションは現在の分割で開けません。メイン領域でセッションを開いてから、もう一度お試しください。"},"extraDirs": {+ "libraryReadOnlyLabel": "Mivo ライブラリ(読み取り専用)","retryRemotePlugins": "リモートプラグインを読み込めませんでした。再試行","menuAria": "操作メニュー","tooltipEmpty": "その他の操作",diff --git a/apps/desktop/src/renderer/i18n/locales/ko/common.json b/apps/desktop/src/renderer/i18n/locales/ko/common.jsonindex 37776db4db..f0fbbe1704 100644--- a/apps/desktop/src/renderer/i18n/locales/ko/common.json+++ b/apps/desktop/src/renderer/i18n/locales/ko/common.json@@ -14778,6 +14778,7 @@"addUnavailable": "현재 분할 창에서 이 세션을 열 수 없습니다. 기본 영역에서 세션을 연 후 다시 시도하세요."},"extraDirs": {+ "libraryReadOnlyLabel": "Mivo 라이브러리(읽기 전용)","retryRemotePlugins": "원격 플러그인을 불러오지 못했습니다. 다시 시도","menuAria": "작업 메뉴","tooltipEmpty": "더 많은 작업",diff --git a/apps/desktop/src/renderer/i18n/locales/zh-CN/common.json b/apps/desktop/src/renderer/i18n/locales/zh-CN/common.jsonindex 19f0125717..5fde08a7ff 100644--- a/apps/desktop/src/renderer/i18n/locales/zh-CN/common.json+++ b/apps/desktop/src/renderer/i18n/locales/zh-CN/common.json@@ -14778,6 +14778,7 @@"addUnavailable": "当前无法在分栏中打开该任务,请先在主区域打开一个任务再重试"},"extraDirs": {+ "libraryReadOnlyLabel": "Mivo 作品库(只读)","retryRemotePlugins": "远程插件加载失败,点击重试","menuAria": "操作菜单","tooltipEmpty": "更多操作",diff --git a/apps/desktop/src/renderer/i18n/locales/zh-TW/common.json b/apps/desktop/src/renderer/i18n/locales/zh-TW/common.jsonindex 097e7685e9..2fa9356e1c 100644--- a/apps/desktop/src/renderer/i18n/locales/zh-TW/common.json+++ b/apps/desktop/src/renderer/i18n/locales/zh-TW/common.json@@ -14778,6 +14778,7 @@"addUnavailable": "當前無法在分欄中開啟該任務,請先在主區域開啟一個任務再重試"},"extraDirs": {+ "libraryReadOnlyLabel": "Mivo 作品庫(唯讀)","retryRemotePlugins": "遠端插件載入失敗,點擊重試","menuAria": "操作選單","tooltipEmpty": "更多操作",diff --git a/docs/design-previews/library-extradirs-quota/extract.mjs b/docs/design-previews/library-extradirs-quota/extract.mjsindex 217dc46c88..61116dfaef 100644--- a/docs/design-previews/library-extradirs-quota/extract.mjs+++ b/docs/design-previews/library-extradirs-quota/extract.mjs@@ -25,9 +25,6 @@ const truth = {slotPrefix: extractByPattern(actions, "export const LIBRARY_EXTRA_DIR_SLOT_PREFIX = '([^']+)'", {locator: 'extraDirsActions LIBRARY_EXTRA_DIR_SLOT_PREFIX',}),- systemLabel: extractByPattern(actions, "isLibraryExtraDirSlot\\(dir\\) \\? '([^']+)'", {- locator: 'extraDirsActions extraDirDisplayLabel 系统项文案',- }),},wiring: {chatInputQuotaSites: makeLeaf(@@ -41,9 +38,9 @@ const truth = {{ locator: 'ChatInput ExtraDirsButton extraDirsCount 公式次数' },),panelLabelSites: makeLeaf(- count(panelSrc, /extraDirDisplayLabel\(p\)/g),+ count(panelSrc, /extraDirDisplayLabel\(p, libraryReadOnlyLabel\)/g),panel,- { locator: 'AtMentionPanel extraDirDisplayLabel(p) 次数' },+ { locator: 'AtMentionPanel extraDirDisplayLabel(p, libraryReadOnlyLabel) 次数' },),panelNoRemoveSites: makeLeaf(count(panelSrc, /isLibraryExtraDirSlot\(p\) \? null/g),@@ -53,6 +50,7 @@ const truth = {},copy: {'zh-CN': {+ libraryReadOnlyLabel: makeLeaf(zhCopy.libraryReadOnlyLabel, zh, { locator: 'extraDirs.libraryReadOnlyLabel', keyPath: 'extraDirs.libraryReadOnlyLabel' }),sectionTitle: makeLeaf(zhCopy.sectionTitle, zh, { locator: 'extraDirs.sectionTitle', keyPath: 'extraDirs.sectionTitle' }),addReadOnly: makeLeaf(zhCopy.addReadOnly, zh, { locator: 'extraDirs.addReadOnly', keyPath: 'extraDirs.addReadOnly' }),atLimit: makeLeaf(zhCopy.atLimit, zh, { locator: 'extraDirs.atLimit', keyPath: 'extraDirs.atLimit' }),@@ -60,6 +58,7 @@ const truth = {empty: makeLeaf(zhCopy.empty, zh, { locator: 'extraDirs.empty', keyPath: 'extraDirs.empty' }),},en: {+ libraryReadOnlyLabel: makeLeaf(enCopy.libraryReadOnlyLabel, en, { locator: 'extraDirs.libraryReadOnlyLabel', keyPath: 'extraDirs.libraryReadOnlyLabel' }),sectionTitle: makeLeaf(enCopy.sectionTitle, en, { locator: 'extraDirs.sectionTitle', keyPath: 'extraDirs.sectionTitle' }),addReadOnly: makeLeaf(enCopy.addReadOnly, en, { locator: 'extraDirs.addReadOnly', keyPath: 'extraDirs.addReadOnly' }),atLimit: makeLeaf(enCopy.atLimit, en, { locator: 'extraDirs.atLimit', keyPath: 'extraDirs.atLimit' }),diff --git a/docs/design-previews/library-extradirs-quota/index.html b/docs/design-previews/library-extradirs-quota/index.htmlindex 247a911081..2f93060be0 100644--- a/docs/design-previews/library-extradirs-quota/index.html+++ b/docs/design-previews/library-extradirs-quota/index.html@@ -27,7 +27,7 @@ html.dark .dir-label { color: #ececec; }</head><body><!-- 真值块:由 `node <skill>/scripts/truth.mjs --demo <dir> --embed` 写入,禁止手抄 -->-<script id="qa-truth" type="application/json">{"copy":{"en":{"addReadOnly":{"provenance":{"hash":"2fa12aa8624821eb20f64306f27e407058634a5e90c53af3aa75c86d150c9c1b","locator":"extraDirs.addReadOnly","locatorKeyPath":"extraDirs.addReadOnly","source":"../../../apps/desktop/src/renderer/i18n/locales/en/common.json"},"value":"Add read-only directory…"},"atLimit":{"provenance":{"hash":"2fa12aa8624821eb20f64306f27e407058634a5e90c53af3aa75c86d150c9c1b","locator":"extraDirs.atLimit","locatorKeyPath":"extraDirs.atLimit","source":"../../../apps/desktop/src/renderer/i18n/locales/en/common.json"},"value":"Limit reached ({{max}})"},"empty":{"provenance":{"hash":"2fa12aa8624821eb20f64306f27e407058634a5e90c53af3aa75c86d150c9c1b","locator":"extraDirs.empty","locatorKeyPath":"extraDirs.empty","source":"../../../apps/desktop/src/renderer/i18n/locales/en/common.json"},"value":"No reference directories yet"},"sectionTitle":{"provenance":{"hash":"2fa12aa8624821eb20f64306f27e407058634a5e90c53af3aa75c86d150c9c1b","locator":"extraDirs.sectionTitle","locatorKeyPath":"extraDirs.sectionTitle","source":"../../../apps/desktop/src/renderer/i18n/locales/en/common.json"},"value":"Reference directories (read-only)"},"tooltipCount":{"provenance":{"hash":"2fa12aa8624821eb20f64306f27e407058634a5e90c53af3aa75c86d150c9c1b","locator":"extraDirs.tooltipCount","locatorKeyPath":"extraDirs.tooltipCount","source":"../../../apps/desktop/src/renderer/i18n/locales/en/common.json"},"value":"{{count}} additional directories"}},"zh-CN":{"addReadOnly":{"provenance":{"hash":"f62799baa971ce5f5b2f82a902344eb519040087ce7bcf8b5d153e57a8758364","locator":"extraDirs.addReadOnly","locatorKeyPath":"extraDirs.addReadOnly","source":"../../../apps/desktop/src/renderer/i18n/locales/zh-CN/common.json"},"value":"添加只读目录…"},"atLimit":{"provenance":{"hash":"f62799baa971ce5f5b2f82a902344eb519040087ce7bcf8b5d153e57a8758364","locator":"extraDirs.atLimit","locatorKeyPath":"extraDirs.atLimit","source":"../../../apps/desktop/src/renderer/i18n/locales/zh-CN/common.json"},"value":"已达上限 {{max}} 个"},"empty":{"provenance":{"hash":"f62799baa971ce5f5b2f82a902344eb519040087ce7bcf8b5d153e57a8758364","locator":"extraDirs.empty","locatorKeyPath":"extraDirs.empty","source":"../../../apps/desktop/src/renderer/i18n/locales/zh-CN/common.json"},"value":"还没有引用目录"},"sectionTitle":{"provenance":{"hash":"f62799baa971ce5f5b2f82a902344eb519040087ce7bcf8b5d153e57a8758364","locator":"extraDirs.sectionTitle","locatorKeyPath":"extraDirs.sectionTitle","source":"../../../apps/desktop/src/renderer/i18n/locales/zh-CN/common.json"},"value":"引用目录(只读)"},"tooltipCount":{"provenance":{"hash":"f62799baa971ce5f5b2f82a902344eb519040087ce7bcf8b5d153e57a8758364","locator":"extraDirs.tooltipCount","locatorKeyPath":"extraDirs.tooltipCount","source":"../../../apps/desktop/src/renderer/i18n/locales/zh-CN/common.json"},"value":"{{count}} 个附加目录"}}},"quota":{"max":{"provenance":{"hash":"bb3226c65b8c7fab2c3c4a1daf6daba7dc26d5f1464ed24769e8f852a13f4a39","locator":"extraDirsValidator EXTRA_DIRS_MAX","locatorPattern":"export const EXTRA_DIRS_MAX = (\\d+)","source":"../../../apps/desktop/src/main/maker-ipc/extraDirsValidator.ts"},"value":"10"},"slotPrefix":{"provenance":{"hash":"8d491fec6e76e07a6a3f001e572e5af94726a41b2d06b72c0c33aea83297f51c","locator":"extraDirsActions LIBRARY_EXTRA_DIR_SLOT_PREFIX","locatorPattern":"export const LIBRARY_EXTRA_DIR_SLOT_PREFIX = '([^']+)'","source":"../../../apps/desktop/src/renderer/components/new-chat/extraDirsActions.ts"},"value":"cindy-library:"},"systemLabel":{"provenance":{"hash":"8d491fec6e76e07a6a3f001e572e5af94726a41b2d06b72c0c33aea83297f51c","locator":"extraDirsActions extraDirDisplayLabel 系统项文案","locatorPattern":"isLibraryExtraDirSlot\\(dir\\) \\? '([^']+)'","source":"../../../apps/desktop/src/renderer/components/new-chat/extraDirsActions.ts"},"value":"Mivo 作品库(只读)"}},"wiring":{"chatInputBadgeSites":{"provenance":{"hash":"019cfe7d536522b125dfcf3ce774e17520a495a432c47c420a55b7ef3a032e51","locator":"ChatInput ExtraDirsButton extraDirsCount 公式次数","source":"../../../apps/desktop/src/renderer/components/new-chat/ChatInput.tsx"},"value":1},"chatInputQuotaSites":{"provenance":{"hash":"019cfe7d536522b125dfcf3ce774e17520a495a432c47c420a55b7ef3a032e51","locator":"ChatInput 加目录/可写目录两处配额公式次数","source":"../../../apps/desktop/src/renderer/components/new-chat/ChatInput.tsx"},"value":2},"panelLabelSites":{"provenance":{"hash":"8626dd9995da248787a2189a5726b7a955224c50cca2911b9729454c98376067","locator":"AtMentionPanel extraDirDisplayLabel(p) 次数","source":"../../../apps/desktop/src/renderer/components/new-chat/AtMentionPanel.tsx"},"value":2},"panelNoRemoveSites":{"provenance":{"hash":"8626dd9995da248787a2189a5726b7a955224c50cca2911b9729454c98376067","locator":"AtMentionPanel library 槽不画移除按钮","source":"../../../apps/desktop/src/renderer/components/new-chat/AtMentionPanel.tsx"},"value":1}}}</script>+<script id="qa-truth" type="application/json">{"copy":{"en":{"addReadOnly":{"provenance":{"hash":"01d196d1ba0bf8eed63c80e32bb9311afa1899896954e14a3437305b374ea153","locator":"extraDirs.addReadOnly","locatorKeyPath":"extraDirs.addReadOnly","source":"../../../apps/desktop/src/renderer/i18n/locales/en/common.json"},"value":"Add read-only directory…"},"atLimit":{"provenance":{"hash":"01d196d1ba0bf8eed63c80e32bb9311afa1899896954e14a3437305b374ea153","locator":"extraDirs.atLimit","locatorKeyPath":"extraDirs.atLimit","source":"../../../apps/desktop/src/renderer/i18n/locales/en/common.json"},"value":"Limit reached ({{max}})"},"empty":{"provenance":{"hash":"01d196d1ba0bf8eed63c80e32bb9311afa1899896954e14a3437305b374ea153","locator":"extraDirs.empty","locatorKeyPath":"extraDirs.empty","source":"../../../apps/desktop/src/renderer/i18n/locales/en/common.json"},"value":"No reference directories yet"},"libraryReadOnlyLabel":{"provenance":{"hash":"01d196d1ba0bf8eed63c80e32bb9311afa1899896954e14a3437305b374ea153","locator":"extraDirs.libraryReadOnlyLabel","locatorKeyPath":"extraDirs.libraryReadOnlyLabel","source":"../../../apps/desktop/src/renderer/i18n/locales/en/common.json"},"value":"Mivo Library (Read-Only)"},"sectionTitle":{"provenance":{"hash":"01d196d1ba0bf8eed63c80e32bb9311afa1899896954e14a3437305b374ea153","locator":"extraDirs.sectionTitle","locatorKeyPath":"extraDirs.sectionTitle","source":"../../../apps/desktop/src/renderer/i18n/locales/en/common.json"},"value":"Directories"},"tooltipCount":{"provenance":{"hash":"01d196d1ba0bf8eed63c80e32bb9311afa1899896954e14a3437305b374ea153","locator":"extraDirs.tooltipCount","locatorKeyPath":"extraDirs.tooltipCount","source":"../../../apps/desktop/src/renderer/i18n/locales/en/common.json"},"value":"{{count}} additional directories"}},"zh-CN":{"addReadOnly":{"provenance":{"hash":"a132ae2714e665285d533dc7420be5dddc3d5fe76a473c93c121ee8a8a81cf45","locator":"extraDirs.addReadOnly","locatorKeyPath":"extraDirs.addReadOnly","source":"../../../apps/desktop/src/renderer/i18n/locales/zh-CN/common.json"},"value":"添加只读目录…"},"atLimit":{"provenance":{"hash":"a132ae2714e665285d533dc7420be5dddc3d5fe76a473c93c121ee8a8a81cf45","locator":"extraDirs.atLimit","locatorKeyPath":"extraDirs.atLimit","source":"../../../apps/desktop/src/renderer/i18n/locales/zh-CN/common.json"},"value":"已达上限 {{max}} 个"},"empty":{"provenance":{"hash":"a132ae2714e665285d533dc7420be5dddc3d5fe76a473c93c121ee8a8a81cf45","locator":"extraDirs.empty","locatorKeyPath":"extraDirs.empty","source":"../../../apps/desktop/src/renderer/i18n/locales/zh-CN/common.json"},"value":"还没有引用目录"},"libraryReadOnlyLabel":{"provenance":{"hash":"a132ae2714e665285d533dc7420be5dddc3d5fe76a473c93c121ee8a8a81cf45","locator":"extraDirs.libraryReadOnlyLabel","locatorKeyPath":"extraDirs.libraryReadOnlyLabel","source":"../../../apps/desktop/src/renderer/i18n/locales/zh-CN/common.json"},"value":"Mivo 作品库(只读)"},"sectionTitle":{"provenance":{"hash":"a132ae2714e665285d533dc7420be5dddc3d5fe76a473c93c121ee8a8a81cf45","locator":"extraDirs.sectionTitle","locatorKeyPath":"extraDirs.sectionTitle","source":"../../../apps/desktop/src/renderer/i18n/locales/zh-CN/common.json"},"value":"目录"},"tooltipCount":{"provenance":{"hash":"a132ae2714e665285d533dc7420be5dddc3d5fe76a473c93c121ee8a8a81cf45","locator":"extraDirs.tooltipCount","locatorKeyPath":"extraDirs.tooltipCount","source":"../../../apps/desktop/src/renderer/i18n/locales/zh-CN/common.json"},"value":"{{count}} 个附加目录"}}},"quota":{"max":{"provenance":{"hash":"bb32200175be9d3e9b4e511035055527c9479fbf71991c971cc2abd62285afdf","locator":"extraDirsValidator EXTRA_DIRS_MAX","locatorPattern":"export const EXTRA_DIRS_MAX = (\\d+)","source":"../../../apps/desktop/src/main/maker-ipc/extraDirsValidator.ts"},"value":"10"},"slotPrefix":{"provenance":{"hash":"4e09c3991697512f0586c4086f8cf5fc6760b222db9757d69307dfc6e201ed53","locator":"extraDirsActions LIBRARY_EXTRA_DIR_SLOT_PREFIX","locatorPattern":"export const LIBRARY_EXTRA_DIR_SLOT_PREFIX = '([^']+)'","source":"../../../apps/desktop/src/renderer/components/new-chat/extraDirsActions.ts"},"value":"cindy-library:"}},"wiring":{"chatInputBadgeSites":{"provenance":{"hash":"986fbad8f0facaa5e51065df571cd66a2777550f0222b528b6562c2e3b7ee1f3","locator":"ChatInput ExtraDirsButton extraDirsCount 公式次数","source":"../../../apps/desktop/src/renderer/components/new-chat/ChatInput.tsx"},"value":1},"chatInputQuotaSites":{"provenance":{"hash":"986fbad8f0facaa5e51065df571cd66a2777550f0222b528b6562c2e3b7ee1f3","locator":"ChatInput 加目录/可写目录两处配额公式次数","source":"../../../apps/desktop/src/renderer/components/new-chat/ChatInput.tsx"},"value":1},"panelLabelSites":{"provenance":{"hash":"61f32f3cbe901707f4657a058298f1db960b737274067202f7ddb7b9ecaf0c84","locator":"AtMentionPanel extraDirDisplayLabel(p, libraryReadOnlyLabel) 次数","source":"../../../apps/desktop/src/renderer/components/new-chat/AtMentionPanel.tsx"},"value":2},"panelNoRemoveSites":{"provenance":{"hash":"61f32f3cbe901707f4657a058298f1db960b737274067202f7ddb7b9ecaf0c84","locator":"AtMentionPanel library 槽不画移除按钮","source":"../../../apps/desktop/src/renderer/components/new-chat/AtMentionPanel.tsx"},"value":1}}}</script><script>// ===== demo 配置(作者唯一要写的部分;字段说明见 qa-chrome 头注释) =====window.__qaDemo = {@@ -61,7 +61,7 @@ window.__qaDemo = {const copy = t.copy[lang];const max = Number(t.quota.max);const prefix = t.quota.slotPrefix;- const systemLabel = t.quota.systemLabel;+ const systemLabel = copy.libraryReadOnlyLabel;const userCount = ctx.state === 'full' ? max : 2;const atLimit = userCount >= max;const addLabel = atLimitdiff --git a/docs/design-previews/library-extradirs-quota/report.json b/docs/design-previews/library-extradirs-quota/report.jsonindex 4c3eada053..b7d39ce3be 100644--- a/docs/design-previews/library-extradirs-quota/report.json+++ b/docs/design-previews/library-extradirs-quota/report.json@@ -1,4 +1,10 @@{+ "stale": {+ "since": "2026-10-18",+ "reason": "#5929 将系统项接入五语资源并同步提取器和预览;原报告仍为 2026-09-01 快照,未对当前输入重跑 QA。",+ "warning": "下方 ok:true 仅对应原 inputHashes,不代表当前工件已通过门 A-F。",+ "howToClear": "在装有 qa-hifi-demo 工具链的环境跑 node <skill>/scripts/verify.mjs --demo docs/design-previews/library-extradirs-quota 并提交重新生成的 report.json。"+ },"ok": true,"partial": false,"toolVersion": "qa-hifi-demo@2026-07-30-component-mode-r14",diff --git a/docs/design-previews/library-extradirs-quota/truth.json b/docs/design-previews/library-extradirs-quota/truth.jsonindex 68fe92fe24..ef403d6601 100644--- a/docs/design-previews/library-extradirs-quota/truth.json+++ b/docs/design-previews/library-extradirs-quota/truth.json@@ -3,7 +3,7 @@"en": {"addReadOnly": {"provenance": {- "hash": "2fa12aa8624821eb20f64306f27e407058634a5e90c53af3aa75c86d150c9c1b",+ "hash": "01d196d1ba0bf8eed63c80e32bb9311afa1899896954e14a3437305b374ea153","locator": "extraDirs.addReadOnly","locatorKeyPath": "extraDirs.addReadOnly","source": "../../../apps/desktop/src/renderer/i18n/locales/en/common.json"@@ -12,7 +12,7 @@},"atLimit": {"provenance": {- "hash": "2fa12aa8624821eb20f64306f27e407058634a5e90c53af3aa75c86d150c9c1b",+ "hash": "01d196d1ba0bf8eed63c80e32bb9311afa1899896954e14a3437305b374ea153","locator": "extraDirs.atLimit","locatorKeyPath": "extraDirs.atLimit","source": "../../../apps/desktop/src/renderer/i18n/locales/en/common.json"@@ -21,25 +21,34 @@},"empty": {"provenance": {- "hash": "2fa12aa8624821eb20f64306f27e407058634a5e90c53af3aa75c86d150c9c1b",+ "hash": "01d196d1ba0bf8eed63c80e32bb9311afa1899896954e14a3437305b374ea153","locator": "extraDirs.empty","locatorKeyPath": "extraDirs.empty","source": "../../../apps/desktop/src/renderer/i18n/locales/en/common.json"},"value": "No reference directories yet"},+ "libraryReadOnlyLabel": {+ "provenance": {+ "hash": "01d196d1ba0bf8eed63c80e32bb9311afa1899896954e14a3437305b374ea153",+ "locator": "extraDirs.libraryReadOnlyLabel",+ "locatorKeyPath": "extraDirs.libraryReadOnlyLabel",+ "source": "../../../apps/desktop/src/renderer/i18n/locales/en/common.json"+ },+ "value": "Mivo Library (Read-Only)"+ },"sectionTitle": {"provenance": {- "hash": "2fa12aa8624821eb20f64306f27e407058634a5e90c53af3aa75c86d150c9c1b",+ "hash": "01d196d1ba0bf8eed63c80e32bb9311afa1899896954e14a3437305b374ea153","locator": "extraDirs.sectionTitle","locatorKeyPath": "extraDirs.sectionTitle","source": "../../../apps/desktop/src/renderer/i18n/locales/en/common.json"},- "value": "Reference directories (read-only)"+ "value": "Directories"},"tooltipCount": {"provenance": {- "hash": "2fa12aa8624821eb20f64306f27e407058634a5e90c53af3aa75c86d150c9c1b",+ "hash": "01d196d1ba0bf8eed63c80e32bb9311afa1899896954e14a3437305b374ea153","locator": "extraDirs.tooltipCount","locatorKeyPath": "extraDirs.tooltipCount","source": "../../../apps/desktop/src/renderer/i18n/locales/en/common.json"@@ -50,7 +59,7 @@"zh-CN": {"addReadOnly": {"provenance": {- "hash": "f62799baa971ce5f5b2f82a902344eb519040087ce7bcf8b5d153e57a8758364",+ "hash": "a132ae2714e665285d533dc7420be5dddc3d5fe76a473c93c121ee8a8a81cf45","locator": "extraDirs.addReadOnly","locatorKeyPath": "extraDirs.addReadOnly","source": "../../../apps/desktop/src/renderer/i18n/locales/zh-CN/common.json"@@ -59,7 +68,7 @@},"atLimit": {"provenance": {- "hash": "f62799baa971ce5f5b2f82a902344eb519040087ce7bcf8b5d153e57a8758364",+ "hash": "a132ae2714e665285d533dc7420be5dddc3d5fe76a473c93c121ee8a8a81cf45","locator": "extraDirs.atLimit","locatorKeyPath": "extraDirs.atLimit","source": "../../../apps/desktop/src/renderer/i18n/locales/zh-CN/common.json"@@ -68,25 +77,34 @@},"empty": {"provenance": {- "hash": "f62799baa971ce5f5b2f82a902344eb519040087ce7bcf8b5d153e57a8758364",+ "hash": "a132ae2714e665285d533dc7420be5dddc3d5fe76a473c93c121ee8a8a81cf45","locator": "extraDirs.empty","locatorKeyPath": "extraDirs.empty","source": "../../../apps/desktop/src/renderer/i18n/locales/zh-CN/common.json"},"value": "还没有引用目录"},+ "libraryReadOnlyLabel": {+ "provenance": {+ "hash": "a132ae2714e665285d533dc7420be5dddc3d5fe76a473c93c121ee8a8a81cf45",+ "locator": "extraDirs.libraryReadOnlyLabel",+ "locatorKeyPath": "extraDirs.libraryReadOnlyLabel",+ "source": "../../../apps/desktop/src/renderer/i18n/locales/zh-CN/common.json"+ },+ "value": "Mivo 作品库(只读)"+ },"sectionTitle": {"provenance": {- "hash": "f62799baa971ce5f5b2f82a902344eb519040087ce7bcf8b5d153e57a8758364",+ "hash": "a132ae2714e665285d533dc7420be5dddc3d5fe76a473c93c121ee8a8a81cf45","locator": "extraDirs.sectionTitle","locatorKeyPath": "extraDirs.sectionTitle","source": "../../../apps/desktop/src/renderer/i18n/locales/zh-CN/common.json"},- "value": "引用目录(只读)"+ "value": "目录"},"tooltipCount": {"provenance": {- "hash": "f62799baa971ce5f5b2f82a902344eb519040087ce7bcf8b5d153e57a8758364",+ "hash": "a132ae2714e665285d533dc7420be5dddc3d5fe76a473c93c121ee8a8a81cf45","locator": "extraDirs.tooltipCount","locatorKeyPath": "extraDirs.tooltipCount","source": "../../../apps/desktop/src/renderer/i18n/locales/zh-CN/common.json"@@ -98,7 +116,7 @@"quota": {"max": {"provenance": {- "hash": "bb3226c65b8c7fab2c3c4a1daf6daba7dc26d5f1464ed24769e8f852a13f4a39",+ "hash": "bb32200175be9d3e9b4e511035055527c9479fbf71991c971cc2abd62285afdf","locator": "extraDirsValidator EXTRA_DIRS_MAX","locatorPattern": "export const EXTRA_DIRS_MAX = (\\d+)","source": "../../../apps/desktop/src/main/maker-ipc/extraDirsValidator.ts"@@ -107,27 +125,18 @@},"slotPrefix": {"provenance": {- "hash": "8d491fec6e76e07a6a3f001e572e5af94726a41b2d06b72c0c33aea83297f51c",+ "hash": "4e09c3991697512f0586c4086f8cf5fc6760b222db9757d69307dfc6e201ed53","locator": "extraDirsActions LIBRARY_EXTRA_DIR_SLOT_PREFIX","locatorPattern": "export const LIBRARY_EXTRA_DIR_SLOT_PREFIX = '([^']+)'","source": "../../../apps/desktop/src/renderer/components/new-chat/extraDirsActions.ts"},"value": "cindy-library:"- },- "systemLabel": {- "provenance": {- "hash": "8d491fec6e76e07a6a3f001e572e5af94726a41b2d06b72c0c33aea83297f51c",- "locator": "extraDirsActions extraDirDisplayLabel 系统项文案",- "locatorPattern": "isLibraryExtraDirSlot\\(dir\\) \\? '([^']+)'",- "source": "../../../apps/desktop/src/renderer/components/new-chat/extraDirsActions.ts"- },- "value": "Mivo 作品库(只读)"}},"wiring": {"chatInputBadgeSites": {"provenance": {- "hash": "019cfe7d536522b125dfcf3ce774e17520a495a432c47c420a55b7ef3a032e51",+ "hash": "986fbad8f0facaa5e51065df571cd66a2777550f0222b528b6562c2e3b7ee1f3","locator": "ChatInput ExtraDirsButton extraDirsCount 公式次数","source": "../../../apps/desktop/src/renderer/components/new-chat/ChatInput.tsx"},@@ -135,23 +144,23 @@},"chatInputQuotaSites": {"provenance": {- "hash": "019cfe7d536522b125dfcf3ce774e17520a495a432c47c420a55b7ef3a032e51",+ "hash": "986fbad8f0facaa5e51065df571cd66a2777550f0222b528b6562c2e3b7ee1f3","locator": "ChatInput 加目录/可写目录两处配额公式次数","source": "../../../apps/desktop/src/renderer/components/new-chat/ChatInput.tsx"},- "value": 2+ "value": 1},"panelLabelSites": {"provenance": {- "hash": "8626dd9995da248787a2189a5726b7a955224c50cca2911b9729454c98376067",- "locator": "AtMentionPanel extraDirDisplayLabel(p) 次数",+ "hash": "61f32f3cbe901707f4657a058298f1db960b737274067202f7ddb7b9ecaf0c84",+ "locator": "AtMentionPanel extraDirDisplayLabel(p, libraryReadOnlyLabel) 次数","source": "../../../apps/desktop/src/renderer/components/new-chat/AtMentionPanel.tsx"},"value": 2},"panelNoRemoveSites": {"provenance": {- "hash": "8626dd9995da248787a2189a5726b7a955224c50cca2911b9729454c98376067",+ "hash": "61f32f3cbe901707f4657a058298f1db960b737274067202f7ddb7b9ecaf0c84","locator": "AtMentionPanel library 槽不画移除按钮","source": "../../../apps/desktop/src/renderer/components/new-chat/AtMentionPanel.tsx"},diff --git a/i18n/GLOSSARY.md b/i18n/GLOSSARY.mdindex 575fff082c..bbe73321d3 100644--- a/i18n/GLOSSARY.md+++ b/i18n/GLOSSARY.md@@ -391,6 +391,10 @@ Orca 协同角色名,与 Worker 成对。五语统一保留英文 Lead,不标准 MCP Apps 协议提供的交互应用;卡片标题与消息来源沿用协议名称,各语言保留 MCP App,待术语评审后固化。+### Mivo Library++#5929:引用目录系统项沿用 Mivo 品牌,仅本地化展示;通用 library 能力的品牌命名仍待维护者裁决。+### Audio GenerationV4 模型类型 audio_generation,包含通用声音生成;与 audio_speech 语音合成分别展示。diff --git a/i18n/glossary.json b/i18n/glossary.jsonindex 315d618df8..7769144c1e 100644--- a/i18n/glossary.json+++ b/i18n/glossary.json@@ -5,6 +5,7 @@"sourceLocale": "en","punctuationExempt": ["desktop:settings.help.qnaFeedbackBodyTemplate"],"terms": [+ {"id": "mivo-library", "status": "proposed", "en": "Mivo Library", "translations": {"zh-CN": "Mivo 作品库", "zh-TW": "Mivo 作品庫", "ja": "Mivo ライブラリ", "ko": "Mivo 라이브러리"}, "note": "#5929:引用目录系统项沿用 Mivo 品牌,仅本地化展示;通用 library 能力的品牌命名仍待维护者裁决。"},{"id": "mcp-app", "status": "proposed", "en": "MCP App", "translations": {"zh-CN": "MCP App", "zh-TW": "MCP App", "ja": "MCP App", "ko": "MCP App"}, "note": "标准 MCP Apps 协议提供的交互应用;卡片标题与消息来源沿用协议名称,各语言保留 MCP App,待术语评审后固化。"},{"id": "dissolve-group", "status": "proposed", "en": "Dissolve group", "translations": {"zh-CN": "解散群聊", "zh-TW": "解散群聊", "ja": "グループを解散", "ko": "그룹 해산"}, "checkCase": false, "note": "Irreversible group termination, distinct from archive, leave and personal list removal."},{"id": "input-handoff", "status": "proposed", "en": "Input Handoff", "translations": {"zh-CN": "代输入", "zh-TW": "代輸入", "ja": "代理入力", "ko": "대리 입력"}, "checkCase": false, "note": "Agent 遇到需要主人填写的界面(选择、文本、密码、验证码、授权)时,由宿主读出当前一步,主人在本机或远程设备上填写,值只交给宿主、不进模型与记录。不是远程控制。"},