Repository navigation
feat(studio): draw the nav entries, fields and flows other packages contribute to a base greyed, with the package - #29847
Conversation
…ed, with the contributing package Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01QsR2jQkUExPHsEsPoX99Uf
Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01QsR2jQkUExPHsEsPoX99Uf
A contributed field card drops only its drag listener, so it is not announced as disabled while a click still selects it. A contributed rail row draws the id over the package label, so a narrow rail shows both. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01QsR2jQkUExPHsEsPoX99Uf
Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01QsR2jQkUExPHsEsPoX99Uf
|
domain:ui#4 · zhuangjianguo · session_01QsR2jR7ZFkpqmm4U8S1f9y 席位核对 · ACCEPT · 2026-11-03T07:40ZHead-sha:
Generated by Claude Code |
Fixes #29786
Clause-②: no
Metadata-protocol: none
维护者速读
ui/packages/app-shell/src/views/studio-design/contributionRows.ts(放置规则,纯函数),再看StudioDesignSurface.tsx三个 pillar 的接入。pnpm --dir ui exec vitest run packages/app-shell/src/views/studio-design/contributionRows.test.ts packages/app-shell/src/views/studio-design/StudioDesignSurface.oneSurface-28572.test.tsx(27 项全绿);对照截图见下方 Verification。What changes
On a read-only base, Studio draws the items other installed packages contribute to it, from the
contributionsof the base's one customization read (GET /api/v1/packages/:id/customizations). That is the read the rails' marks already make, so no request is added and nothing is joined on names in the browser. Each item is greyed, read-only, labelled "from PACKAGE", and a click opens the contributing package (through the shell's unsaved-edits seam).usePackageCustomizationsnow also names each contributing package from the package list, by id, as it already names the base.contributionRows.ts(new, pure) splits the read by kind and holds the placement rules.naventry for the open app draws under the group it names when the app declares atype: 'group'item of that id at any depth (the question the server's navigation fold asks), and at the top level otherwise. An entry naming an undeclared group says so in its tooltip. A declared group holding only contributed rows no longer says "No items in this package". The row reads the item's id (the served entry carries no label). The row is never in the nav edit buffer, so it cannot be dragged, renamed or deleted.flowdraws in its object's rail group. An object with no flow of the base's gets a group of its own, before "No object".enandzh(engine.studio.contributed.*).Tests
contributionRows.test.ts(new, 9): split by kind and package naming, declared group at depth, top level and undeclared group, other app left out, a non-group item sharing the id is no container, fields per object, flow groups joined or added before "No object".StudioDesignSurface.oneSurface-28572.test.tsx(+6): Interfaces group, top-level and undeclared placement; a nav row opens the contributor; CONTROL: an empty declared group still says "No items" when nothing is contributed; Data card marked once, notaria-disabled, inspector read-only while the base's own field is not; Automations group placement, a new group, no empty message, opens the contributor; no request to the contributing package.findDeclaredNavGroup, thecontributedFieldsprop, the rail read-only, flow rows, anduseSortabledisabledon a contributed card.Acceptance notes
naventry carries no label. Measured: the app list read the pillar already makes (GET /meta/app?package=) carries the folded navigation with labels. Using it would need a ruling on reading the fold, so no label is joined here.manifest.navigationContributions(a declaration, not the fold). Left as is and reported (seat ruling).plugin-grid, outside this surface.enandzhonly. The studio namespace lives inui/packages/i18n/src/namespaces/studio/, not in the ten locale packs the claim names; other languages fall back toenas the whole namespace does.examples/app-multi-packageplus a temporary third package (a nav entry under an undeclared group, a field and a flow oncrm_account). That package was never committed; the pins carry their own fixtures.Verification
turbo type-checkapp-shell + i18n), eslint on touched files: 0 errors.dispatch-gates --commands): all exit 0; see the os-dev-report on the card.objectstack devonapp-multi-packageplus the temporary package, Console via Vite. The base read lists 4 contributions (fieldacme_score, flowcrm_acme_account_sync, navnav_acme_portalunder undeclaredghost_group, navnav_ordersundersales_groupfrom the orders package). After:nav_ordersunder SALES andnav_acme_portalat the top level with the undeclared-group tooltip; the Acme score card marked once with the inspector read-only;crm_acme_account_syncin the ACCOUNT group. Before (601832b): none of the nav or flow rows, and the field card unmarked.🤖 Generated with Claude Code
https://claude.ai/code/session_01QsR2jQkUExPHsEsPoX99Uf
Generated by Claude Code