feat(modal): open model metadata sidecar location from the model modal

Centralized sidecar storage moves .metadata.json into a mirror tree, so
the Location link in the model modal could no longer reveal a model's
sidecar. The Location row now shows an inline metadata icon button
(centralized mode only) that calls a new
POST /api/lm/models/open-sidecar-location endpoint: the backend resolves
the sidecar through py/utils/sidecar_paths, reveals the .metadata.json
selected in the file manager (falling back to the sidecar directory when
it has not been written yet), and returns the path for clipboard mode on
headless/Docker sessions. The platform reveal logic is factored into a
shared FileSystemHandler._reveal_file helper. All 9 locales translated.
This commit is contained in:
Will Miao
2026-10-10 07:41:48 +08:00
parent 7937aeaa04
commit af90fe873d
17 changed files with 622 additions and 58 deletions
+8
View File
@@ -195,6 +195,14 @@ Locales: `en`, `zh-CN`, `zh-TW`, `ja`, `ko`, `fr`, `de`, `es`, `ru`, `he` (RTL).
> root** noun while translating (`library root` → `model root`, R5); the count-bearing
> `successMulti` uses the singular `success` key when only one copy was removed.
> **Status (2026-10, model-modal sidecar location):** the model modal's Location row gained
> an inline "open metadata location" icon button (rendered only in centralized sidecar
> storage mode), adding 5 keys (`modals.model.actions.openSidecarLocation` and the 4
> `modals.model.openSidecarLocation.*` toasts). The renderings mirror each locale's sibling
> `openFileLocation` block verbatim with the §5 "metadata" noun swapped in, so no new
> terminology was introduced. All 9 locales are translated, so the "no remaining
> placeholders" claim holds again.
---
## 1. Hard rules (do not violate)