[PR #1835] [MERGED] Fix shared mode parity gaps #5305

Closed
opened 2026-10-22 04:15:05 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Pasta-Devs/Marinara-Engine/pull/1835
Author: @cha1latte
Created: 6/1/2026
Status: ✅ Merged
Merged: 6/1/2026
Merged by: @cha1latte

Base: refactor ← Head: fix/issue-1798-shared-mode-parity


📝 Commits (3)

  • 67a6194 Fix shared mode parity gaps
  • 198e7ba Rerun checks after PR body update
  • 2afb453 Address summary template button labels

📊 Changes

6 files changed (+400 additions, -34 deletions)

View changed files

📝 src/engine/shared/text/chat-summary-entries.ts (+1 -1)
📝 src/features/catalog/chats/hooks/use-chats.test.tsx (+43 -1)
📝 src/features/catalog/chats/hooks/use-chats.ts (+38 -3)
📝 src/features/modes/shared/chat-ui/components/ChatSettingsDrawer.tsx (+1 -1)
📝 src/features/modes/shared/chat-ui/components/SummaryPopover.tsx (+296 -28)
➕ src/shared/stores/gallery.store.test.ts (+21 -0)

📄 Description

Linked issue

Closes #1798

Why this change

  • Restores shared-mode parity gaps from the refactor audit: guarded Memory Recall file intake, richer rolling-summary controls, and durable gallery illustration pending-state proof.

What changed

  • Re-added client-side Memory Recall file validation for the Marinara envelope, invalid JSON, wrong-file imports, and files over 25 MB before invoking the import command.
  • Allowed .marinara files in the Memory Recall picker again.
  • Extended the shared summary popover with enabled-token totals, disabled-entry counts, token warning display, and chat-scoped summary prompt template create/edit/duplicate/delete controls.
  • Added focused tests for Memory Recall file validation and the store-backed gallery illustration in-flight state.

Refactor impact

Primary owner:

Shared mode UI and catalog chat hooks.

Impact areas reviewed:

  • SummaryPopover metadata reads and useUpdateChatMetadata writes.
  • Memory Recall import path in useImportChatMemories and the settings drawer file picker.
  • Gallery illustration pending state in ChatGallery and gallery.store.

Boundary notes:

  • Engine code remains React-free. The only engine change exports the existing summary token estimator for UI reuse.
  • Feature code continues through focused catalog hooks and shared API wrappers.
  • No Rust, schema, dependency, release, auth, provider, or prompt-pipeline changes.

Pressure points touched:

  • Shared mode UI SummaryPopover.
  • Shared chat settings drawer Memory Recall modal.
  • Catalog chat hooks.
  • Shared gallery store test coverage.

Validation

  • Matching validation command passes locally (for example pnpm typecheck, pnpm build, pnpm check:architecture, pnpm check:docs, or full pnpm check when warranted)
  • Full pnpm check passes before PR push/handoff
  • Human/manual validation completed by contributor or reviewer

Manual verification notes

  • Codex proof run:
  • pnpm exec vitest run src/features/catalog/chats/hooks/use-chats.test.tsx src/shared/stores/gallery.store.test.ts
  • pnpm typecheck
  • pnpm check
  • node C:\Users\celia\.codex\tools\marinara-proof-gate.mjs scratch\bugfix-verification.json
  • Bunny draft gate passed with the visual limitation below.

Feature Discoverability

Check exactly one:

  • Updated src/features/shell/discovery/ because this PR adds or materially changes a user-discoverable feature, workflow, setting, mode, panel, import path, agent, media capability, or advanced tool.
  • N/A because this PR is only a bugfix, refactor, test, docs, internal wiring, visual polish, copy edit, or compatibility fix and does not add a new thing users need to find.

Reason:

  • This restores existing shared-mode behavior rather than adding a new discoverable workflow.

Docs and release impact

  • No docs changes needed
  • Updated README.md
  • Updated CONTRIBUTING.md
  • Updated docs/developer/
  • Updated repo skills or AGENTS.md
  • Confirmed this PR does not restore old staging/package-workspace/release claims

UI evidence

  • Draft limitation: no live browser screenshot was captured for the expanded summary prompt-template editor. The PR is intentionally left draft for visual review if maintainers want UI evidence before ready-for-review.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/Pasta-Devs/Marinara-Engine/pull/1835 **Author:** [@cha1latte](https://github.com/cha1latte) **Created:** 6/1/2026 **Status:** ✅ Merged **Merged:** 6/1/2026 **Merged by:** [@cha1latte](https://github.com/cha1latte) **Base:** `refactor` ← **Head:** `fix/issue-1798-shared-mode-parity` --- ### 📝 Commits (3) - [`67a6194`](https://github.com/Pasta-Devs/Marinara-Engine/commit/67a6194308b01f3642dfef0f79c395f8e3d91d45) Fix shared mode parity gaps - [`198e7ba`](https://github.com/Pasta-Devs/Marinara-Engine/commit/198e7badb3d0fa7e6a2072e4d6d7569a3816e8a0) Rerun checks after PR body update - [`2afb453`](https://github.com/Pasta-Devs/Marinara-Engine/commit/2afb45351223f99826821d97ce5eddb55901cf25) Address summary template button labels ### 📊 Changes **6 files changed** (+400 additions, -34 deletions) <details> <summary>View changed files</summary> 📝 `src/engine/shared/text/chat-summary-entries.ts` (+1 -1) 📝 `src/features/catalog/chats/hooks/use-chats.test.tsx` (+43 -1) 📝 `src/features/catalog/chats/hooks/use-chats.ts` (+38 -3) 📝 `src/features/modes/shared/chat-ui/components/ChatSettingsDrawer.tsx` (+1 -1) 📝 `src/features/modes/shared/chat-ui/components/SummaryPopover.tsx` (+296 -28) ➕ `src/shared/stores/gallery.store.test.ts` (+21 -0) </details> ### 📄 Description <!-- Target branch: `refactor`. Change the base to `refactor` before submitting unless a maintainer explicitly asked for another base. --> <!-- Keep all checkboxes unchecked until a human has actually verified them. --> ## Linked issue Closes #1798 ## Why this change - Restores shared-mode parity gaps from the refactor audit: guarded Memory Recall file intake, richer rolling-summary controls, and durable gallery illustration pending-state proof. ## What changed - Re-added client-side Memory Recall file validation for the Marinara envelope, invalid JSON, wrong-file imports, and files over 25 MB before invoking the import command. - Allowed `.marinara` files in the Memory Recall picker again. - Extended the shared summary popover with enabled-token totals, disabled-entry counts, token warning display, and chat-scoped summary prompt template create/edit/duplicate/delete controls. - Added focused tests for Memory Recall file validation and the store-backed gallery illustration in-flight state. ## Refactor impact Primary owner: Shared mode UI and catalog chat hooks. Impact areas reviewed: - `SummaryPopover` metadata reads and `useUpdateChatMetadata` writes. - Memory Recall import path in `useImportChatMemories` and the settings drawer file picker. - Gallery illustration pending state in `ChatGallery` and `gallery.store`. Boundary notes: - Engine code remains React-free. The only engine change exports the existing summary token estimator for UI reuse. - Feature code continues through focused catalog hooks and shared API wrappers. - No Rust, schema, dependency, release, auth, provider, or prompt-pipeline changes. Pressure points touched: - Shared mode UI `SummaryPopover`. - Shared chat settings drawer Memory Recall modal. - Catalog chat hooks. - Shared gallery store test coverage. ## Validation <!-- Check only what you personally ran or manually verified. Treat unchecked items as explicit TODOs. --> <!-- Do not submit *.test.ts or *.test.tsx files as PR proof; cite existing checks, command output, app/browser/Tauri verification, or manual notes instead. --> - [ ] Matching validation command passes locally (for example `pnpm typecheck`, `pnpm build`, `pnpm check:architecture`, `pnpm check:docs`, or full `pnpm check` when warranted) - [ ] Full `pnpm check` passes before PR push/handoff - [ ] Human/manual validation completed by contributor or reviewer ### Manual verification notes - Codex proof run: - `pnpm exec vitest run src/features/catalog/chats/hooks/use-chats.test.tsx src/shared/stores/gallery.store.test.ts` - `pnpm typecheck` - `pnpm check` - `node C:\Users\celia\.codex\tools\marinara-proof-gate.mjs scratch\bugfix-verification.json` - Bunny draft gate passed with the visual limitation below. ## Feature Discoverability Check exactly one: - [ ] Updated `src/features/shell/discovery/` because this PR adds or materially changes a user-discoverable feature, workflow, setting, mode, panel, import path, agent, media capability, or advanced tool. - [x] N/A because this PR is only a bugfix, refactor, test, docs, internal wiring, visual polish, copy edit, or compatibility fix and does not add a new thing users need to find. Reason: - This restores existing shared-mode behavior rather than adding a new discoverable workflow. ## Docs and release impact - [ ] No docs changes needed - [ ] Updated `README.md` - [ ] Updated `CONTRIBUTING.md` - [ ] Updated `docs/developer/` - [ ] Updated repo skills or `AGENTS.md` - [ ] Confirmed this PR does not restore old staging/package-workspace/release claims ## UI evidence - Draft limitation: no live browser screenshot was captured for the expanded summary prompt-template editor. The PR is intentionally left draft for visual review if maintainers want UI evidence before ready-for-review. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-22 04:15:05 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Pasta-Devs/Marinara-Engine#5305
No description provided.