Skip to content

feat(ui): load right panel plugin manifests - #617

Merged
shantur merged 8 commits into
devfrom
feat/right-panel-plugin-manifest
Aug 3, 2026
Merged

feat(ui): load right panel plugin manifests#617
shantur merged 8 commits into
devfrom
feat/right-panel-plugin-manifest

Conversation

@pascalandr

Copy link
Copy Markdown
Contributor

Summary

  • Add a typed right-panel plugin manifest loader.
  • Let bundled plugin manifests contribute right-panel tabs and Status sections through the existing registry.
  • Run onLoad/onUnload lifecycle hooks when the RightPanel mounts/unmounts.
  • Keep the manifest list explicit and empty by default; no arbitrary external code loading in this PR.

Stacking

Validation

  • npm exec --no -- tsx --test packages/ui/src/components/instance/shell/right-panel/plugin-manifest.test.ts packages/ui/src/components/instance/shell/right-panel/registry.test.ts
  • npm run typecheck --workspace @codenomad/ui
  • git diff --check
  • npm run build --workspace @codenomad/ui
  • final gatekeeper pass: no findings

@pascalandr

Copy link
Copy Markdown
Contributor Author

Stack note: this is intentionally based on feat/right-panel-customization so the diff only contains the manifest/lifecycle loader. The repository restrict-non-dev-prs workflow currently blocks non-dev base branches for authors outside ALLOWED_NON_DEV_PR_ACTORS, so CI is skipped until #615 merges and this PR is retargeted to dev, or the allowlist includes this author.

@pascalandr
pascalandr force-pushed the feat/right-panel-plugin-manifest branch from 1d1da61 to a082456 Compare July 25, 2026 10:43
@pascalandr

pascalandr commented Jul 25, 2026

Copy link
Copy Markdown
Contributor Author

Rebased on the updated #615 branch after the right-panel customization popover UX change. Manifest loader diff remains stacked and clean.

Validation after rebase:

  • npm exec --no -- tsx --test packages/ui/src/components/instance/shell/right-panel/plugin-manifest.test.ts packages/ui/src/components/instance/shell/right-panel/registry.test.ts
  • npm run typecheck --workspace @codenomad/ui
  • git diff --check
  • npm run build --workspace @codenomad/ui
  • final gatekeeper pass: no findings

@pascalandr
pascalandr force-pushed the feat/right-panel-plugin-manifest branch from a082456 to a7eee0e Compare July 25, 2026 11:06
@pascalandr

Copy link
Copy Markdown
Contributor Author

Update: rebased this stacked branch on the latest feat/right-panel-customization and force-with-lease pushed a7eee0e.
Validation passed after rebase:

  • npm exec --no -- tsx --test packages/ui/src/components/instance/shell/right-panel/plugin-manifest.test.ts
  • npm exec --no -- tsx --test packages/ui/src/components/instance/shell/right-panel/registry.test.ts
  • npm run typecheck --workspace @codenomad/ui
  • npm run build --workspace @codenomad/ui
  • git diff --check
    Expected CI note: restrict-non-dev-prs still blocks this stacked PR while its base is not dev.

Add a typed manifest loader for right-panel plugins so bundled modules can contribute tabs and Status sections through the registry introduced by the stacked customization PR.

The loader runs deterministic onLoad/onUnload lifecycle hooks, skips duplicate or failed manifests without blocking other plugins, and keeps the plugin list explicit for now to avoid arbitrary code loading or marketplace behavior in this step.

Validated with focused manifest and registry tests, UI typecheck, whitespace check, UI build, and a final gatekeeper pass.
@pascalandr
pascalandr force-pushed the feat/right-panel-plugin-manifest branch from a7eee0e to 6f93f79 Compare July 28, 2026 11:32
@pascalandr
pascalandr changed the base branch from feat/right-panel-customization to dev July 28, 2026 11:32
@pascalandr

Copy link
Copy Markdown
Contributor Author

Update: #617 is now rebased directly on dev after #615 was merged.
Branch force-with-lease pushed: 6f93f79.
PR base changed from feat/right-panel-customization to dev.
Local validation passed:

  • npm exec --no -- tsx --test packages/ui/src/components/instance/shell/right-panel/plugin-manifest.test.ts
  • npm exec --no -- tsx --test packages/ui/src/components/instance/shell/right-panel/registry.test.ts
  • npm run typecheck --workspace @codenomad/ui
  • npm run build --workspace @codenomad/ui
  • git diff --check upstream/dev...HEAD
    Diff is now plugin-manifest only: RightPanel integration plus plugin-manifest files.

Route the built-in Git Changes, Files, Status tab definitions and native Status sections through core manifest factories. The render functions still close over the existing RightPanel and StatusTab state, so this proves the manifest contract without widening plugin access to private panel internals or changing user-visible behavior.

Validation: npm exec --no -- tsx --test packages/ui/src/components/instance/shell/right-panel/plugin-manifest.test.ts; npm exec --no -- tsx --test packages/ui/src/components/instance/shell/right-panel/registry.test.ts; npm run typecheck --workspace @codenomad/ui; npm run build --workspace @codenomad/ui; git diff --check.
@pascalandr

Copy link
Copy Markdown
Contributor Author

Update: pushed e50cf17 to make #617 useful without broadening scope.
What changed:

  • built-in Git Changes, Files, and Status tabs now come from a core right-panel manifest
  • built-in Status sections now come from a core status-section manifest
  • renderers still live in their existing RightPanel/StatusTab scopes, so private state and handlers are not exposed to future non-native plugins
  • no user-visible UX change intended
    Validation passed:
  • npm exec --no -- tsx --test packages/ui/src/components/instance/shell/right-panel/plugin-manifest.test.ts
  • npm exec --no -- tsx --test packages/ui/src/components/instance/shell/right-panel/registry.test.ts
  • npm run typecheck --workspace @codenomad/ui
  • npm run build --workspace @codenomad/ui
  • git diff --check
    Build still only reports the known large chunk warning.

Derive the native Status tab manifest from CORE_STATUS_SECTION_ITEMS instead of duplicating ids, labels, tooltips, and ordering in core-plugin.tsx.

This keeps the customization defaults and plugin manifest source aligned. Missing renderers now fail when building the core manifest so future section additions are caught by the existing manifest test.

Validation: npm exec --no -- tsx --test packages/ui/src/components/instance/shell/right-panel/plugin-manifest.test.ts; npm exec --no -- tsx --test packages/ui/src/components/instance/shell/right-panel/registry.test.ts; npm run typecheck --workspace @codenomad/ui; npm run build --workspace @codenomad/ui; git diff --check

@pascalandr pascalandr left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Gatekeeper review complete for d74be3e.

Findings: none remaining.

Fixed during review:

  • Reused CORE_STATUS_SECTION_ITEMS from the core Status section manifest instead of duplicating section ids, labels, tooltips, and order in core-plugin.tsx. This keeps customization defaults and manifest metadata aligned, and missing renderers now fail in the manifest path.

Validated locally:

  • npm exec --no -- tsx --test packages/ui/src/components/instance/shell/right-panel/plugin-manifest.test.ts
  • npm exec --no -- tsx --test packages/ui/src/components/instance/shell/right-panel/registry.test.ts
  • npm run typecheck --workspace @codenomad/ui
  • npm run build --workspace @codenomad/ui
  • git diff --check

Remote checks at review time:

  • authorize: pass
  • tests-tauri-windows: pass
  • restrict-non-dev-prs: skipped as expected for dev base
  • tests: still in progress after watcher timeout
  • comment artifact job: still in progress

Residual risk: I did not do a manual visual drag/drop pass in the running app; coverage here is code review plus local build/typecheck/tests.

Turn RightPanel.tsx back into the shell for tab chrome, customization, drag ordering, and active manifest rendering. Native Git, Files, and Status wiring now lives in core-runtime.tsx, with Files state and split resizing isolated in focused runtime helpers.

This makes the manifest extraction real instead of wrapping a monolith: plugin loading stays in the shell while native tab state is kept behind internal runtime modules, preserving persisted tab, word-wrap, list-open, section-open, and split-width behavior.

Validation: npm run typecheck --workspace @codenomad/ui; npm exec --no -- tsx --test packages/ui/src/components/instance/shell/right-panel/plugin-manifest.test.ts; npm exec --no -- tsx --test packages/ui/src/components/instance/shell/right-panel/registry.test.ts; npm run build --workspace @codenomad/ui; git diff --check
@pascalandr

Copy link
Copy Markdown
Contributor Author

Follow-up after scope correction:

  • RightPanel.tsx is now the shell only: tab chrome, customization popover, drag ordering, manifest loading, active tab rendering.
  • Native Git/Files/Status wiring moved to core-runtime.tsx.
  • Files-specific state/loading/save/conflict handling moved to tabs/files-runtime.tsx.
  • Shared split resize persistence moved to tabs/split-resize.ts.
  • RightPanel.tsx dropped from about 1031 lines to 360 lines.

Validated locally:

  • npm run typecheck --workspace @codenomad/ui
  • npm exec --no -- tsx --test packages/ui/src/components/instance/shell/right-panel/plugin-manifest.test.ts
  • npm exec --no -- tsx --test packages/ui/src/components/instance/shell/right-panel/registry.test.ts
  • npm run build --workspace @codenomad/ui
  • git diff --check

Known build note: existing Vite chunk-size warning remains unchanged in nature.

@github-actions

Copy link
Copy Markdown

PR builds are available as GitHub Actions artifacts:

https://github.com/NeuralNomadsAI/CodeNomad/actions/runs/30365369176

Artifacts expire in 7 days.
Artifacts:

  • pr-617-4aa93a4099319b940a5d9b59d376b40bc62a1aa2-tauri-linux
  • pr-617-4aa93a4099319b940a5d9b59d376b40bc62a1aa2-tauri-macos
  • pr-617-4aa93a4099319b940a5d9b59d376b40bc62a1aa2-tauri-windows
  • pr-617-4aa93a4099319b940a5d9b59d376b40bc62a1aa2-electron-macos
  • pr-617-4aa93a4099319b940a5d9b59d376b40bc62a1aa2-tauri-macos-arm64
  • pr-617-4aa93a4099319b940a5d9b59d376b40bc62a1aa2-electron-linux
  • pr-617-4aa93a4099319b940a5d9b59d376b40bc62a1aa2-electron-windows

Replace static right panel plugin declarations with first-party manifest factories that receive a small host context for instance, session, i18n, tab activation, tab opening, and future attention reporting.

Restore the tab accessibility behavior needed by the Workflows follow-up by wiring tab ids, aria-controls, tab panels, roving tabIndex, and Arrow/Home/End keyboard navigation into the extracted right panel shell.

Keep Status as a special always-visible tab, move status section customization into StatusTab itself, and surface module identity plus create failures in the customization UI so bundled modules do not disappear silently.

Validated with UI typecheck, targeted right-panel tests, git diff --check, and the UI build. The build still emits the existing large chunk warning.

@pascalandr pascalandr left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Gatekeeper review: no findings.

I cannot approve this PR through GitHub because it is authored by the same account, but I completed the gatekeeper pass on HEAD 1db1bce.

Checked:

  • #618 tab accessibility expectations are preserved: tab ids, aria-controls, tabpanel, roving tabIndex, Arrow/Home/End navigation.
  • Manifest API is now a first-party factory with host context for instanceId, t, activeSessionId, isTabActive, openTab, and future attention reporting.
  • Panel-mounted lifecycle hooks were removed.
  • Status is always visible and status-section customization moved into StatusTab.
  • Module identity and create failures are visible in customization instead of disappearing silently.
  • Workflows can now be a follow-up bundled module without importing Git/Files/Status internals.

Verified locally:

  • npm run typecheck --workspace @codenomad/ui
  • npm exec --no -- tsx --test packages/ui/src/components/instance/shell/right-panel/plugin-manifest.test.ts
  • npm exec --no -- tsx --test packages/ui/src/components/instance/shell/right-panel/registry.test.ts
  • npm run build --workspace @codenomad/ui
  • git diff --check

Remote checks at review time: authorize and tests passed; tests-tauri-windows and comment were still in progress after waiting.

@github-actions

Copy link
Copy Markdown

PR builds are available as GitHub Actions artifacts:

https://github.com/NeuralNomadsAI/CodeNomad/actions/runs/30671004616

Artifacts expire in 7 days.
Artifacts:

  • pr-617-d463b1ea271db3c8ec304ebfa73342082c5b6025-tauri-macos
  • pr-617-d463b1ea271db3c8ec304ebfa73342082c5b6025-tauri-windows
  • pr-617-d463b1ea271db3c8ec304ebfa73342082c5b6025-electron-macos
  • pr-617-d463b1ea271db3c8ec304ebfa73342082c5b6025-tauri-macos-arm64
  • pr-617-d463b1ea271db3c8ec304ebfa73342082c5b6025-tauri-linux
  • pr-617-d463b1ea271db3c8ec304ebfa73342082c5b6025-electron-linux
  • pr-617-d463b1ea271db3c8ec304ebfa73342082c5b6025-electron-windows

@pascalandr
pascalandr marked this pull request as draft August 1, 2026 00:14
Remove helper and description copy from the right panel customization surfaces so the popovers only show the controls users need.

Move Status section customization behind a compact settings icon in the token counter header, matching the general panel customization affordance while keeping Status itself always available.

Validated with UI typecheck, targeted right-panel tests, git diff --check, and the UI build. The build still emits the existing large chunk warning.
@pascalandr
pascalandr marked this pull request as ready for review August 1, 2026 00:53
@github-actions

github-actions Bot commented Aug 1, 2026

Copy link
Copy Markdown

PR builds are available as GitHub Actions artifacts:

https://github.com/NeuralNomadsAI/CodeNomad/actions/runs/30676632787

Artifacts expire in 7 days.
Artifacts:

  • pr-617-942f68d1c1956c83c2deaf0cddf8a5008fad0058-tauri-macos
  • pr-617-942f68d1c1956c83c2deaf0cddf8a5008fad0058-electron-macos
  • pr-617-942f68d1c1956c83c2deaf0cddf8a5008fad0058-tauri-windows
  • pr-617-942f68d1c1956c83c2deaf0cddf8a5008fad0058-tauri-linux
  • pr-617-942f68d1c1956c83c2deaf0cddf8a5008fad0058-tauri-macos-arm64
  • pr-617-942f68d1c1956c83c2deaf0cddf8a5008fad0058-electron-linux
  • pr-617-942f68d1c1956c83c2deaf0cddf8a5008fad0058-electron-windows

Collapse tab and Status section customization into one minimal right panel popover. Status remains checked and disabled, with its sections shown directly underneath as indented rows.

Remove the separate Status customization trigger and obsolete styling so the panel has one settings affordance and a single reset action at the bottom.

Validated with UI typecheck, targeted right-panel tests, git diff --check, and the UI build. The build still emits the existing large chunk warning.
@github-actions

github-actions Bot commented Aug 1, 2026

Copy link
Copy Markdown

PR builds are available as GitHub Actions artifacts:

https://github.com/NeuralNomadsAI/CodeNomad/actions/runs/30678480088

Artifacts expire in 7 days.
Artifacts:

  • pr-617-65e06c1c8e5396f4600ea6b3c94854fc38d62beb-tauri-macos
  • pr-617-65e06c1c8e5396f4600ea6b3c94854fc38d62beb-tauri-windows
  • pr-617-65e06c1c8e5396f4600ea6b3c94854fc38d62beb-electron-macos
  • pr-617-65e06c1c8e5396f4600ea6b3c94854fc38d62beb-tauri-linux
  • pr-617-65e06c1c8e5396f4600ea6b3c94854fc38d62beb-electron-linux
  • pr-617-65e06c1c8e5396f4600ea6b3c94854fc38d62beb-tauri-macos-arm64
  • pr-617-65e06c1c8e5396f4600ea6b3c94854fc38d62beb-electron-windows

@pascalandr

Copy link
Copy Markdown
Contributor Author

@shantur LGTM

@shantur
shantur merged commit 946bd8e into dev Aug 3, 2026
16 of 18 checks passed
@shantur
shantur deleted the feat/right-panel-plugin-manifest branch August 3, 2026 08:50
pascalandr added a commit to pascalandr/CodeNomad that referenced this pull request Aug 3, 2026
Merge upstream/dev at c16cc00 into the workflow host branch. This adopts the first-party right-panel manifest runtime from NeuralNomadsAI#617 and registers Workflows through that contract while preserving stable tab IDs, keyboard navigation, localization, and existing customization behavior.

The merge also carries the latest invalid OpenCode configuration diagnostics and retains both workspace lifecycle test paths. Resolutions were validated with server and UI typechecks, the UI production build, the full server suite, focused right-panel/workflow/workspace tests, and an independent regression review.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants