[PR #8573] [MERGED] feat(mari): Not this one rejects only that field of a held change #8683

Closed
opened 2026-11-07 17:38:53 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Pasta-Devs/Marinara-Engine/pull/8573
Author: @Gunterlie
Created: 10/30/2026
Status: ✅ Merged
Merged: 10/30/2026
Merged by: @Gunterlie

Base: staging ← Head: feat/mari-decline-one-field


📝 Commits (7)

  • bf6ec20 feat(mari): Not this one rejects only that field of a held change
  • ba82cc8 fix(mari): keep unreviewed fields when declining one, scope declined line per editor
  • 873c618 Merge origin/staging into feat/mari-decline-one-field
  • 9a85d14 fix(mari): settle ignores declined fields, accept guards for declined fields
  • e640a1e Merge origin/staging into feat/mari-decline-one-field
  • 00a5428 Merge origin/staging into feat/mari-decline-one-field
  • 02b7e78 fix(mari): apply declined fields to every held call instead of refusing large changes

📊 Changes

11 files changed (+458 additions, -251 deletions)

View changed files

📝 packages/client/src/components/characters/MariFieldReview.tsx (+48 -18)
📝 packages/client/src/components/chat/HomeProfessorMariChat.tsx (+15 -8)
📝 packages/client/src/lib/mari-editor-fields.ts (+42 -221)
📝 packages/client/src/localization/locales/en.json (+1 -1)
📝 packages/client/src/stores/ui.store.ts (+5 -0)
📝 packages/server/src/routes/professor-mari-workspace.routes.ts (+4 -0)
📝 packages/server/src/services/professor-mari/workspace-agent.service.ts (+10 -3)
📝 packages/shared/src/index.ts (+1 -0)
📝 packages/shared/src/types/professor-mari-workspace.ts (+2 -0)
➕ packages/shared/src/utils/mari-editor-fields.ts (+270 -0)
📝 scripts/regressions/mari-editor-fields.regression.ts (+60 -0)

📄 Description

Linked issue

No issue: planned work on Prof. Mari's in-field review.

Why this change

In Prof. Mari's in-field review, "Not this one" declined the whole held change and asked Mari to propose it again. A user who disliked one field lost the good fields too and waited for a new reply.

What changed

  • "Not this one" now rejects only that field. The field keeps its old text, and Keep applies the rest of the held change.
  • The declined fields (record id and field id) are kept in the UI store. Every Accept sends them: the field's Keep, the card's Accept, the chip, and a typed accept. The server drops those fields from the stored held calls before it applies them. A call left with no editor field is dropped.
  • When the last field is declined and no other record is held, the whole change is rejected, as before.
  • The field-id logic (MARI_EDITOR_KINDS, mariPatchFieldId, mariFieldPath, mariUpdateCall) moved from the client to packages/shared/src/utils/mari-editor-fields.ts, so client and server use the same ids. The client file re-exports it. New: withoutDeclinedMariFields.
  • Esc on a field review still answers that field, now as "Not this one" for the field.
  • New route field: context.declinedFields on the workspace prompt request.

Validation

  • pnpm check passes locally
  • Container (Docker / Podman) built and ran without issue
  • Ran the app, clicked through the changes manually
  • Checked edge cases (light + dark mode, mobile viewport, empty states, error paths)
  • Above manual verification completed (describe below)
  • Read and followed CONTRIBUTING.md

Manual verification notes

Agent-run (not manual): client and server tsc, ESLint on client files (one pre-existing warning, serverRun), Prettier, localization:check, regressions mari-editor-fields (new cases for declined fields, another record's call, and the Accept paths), mari-hold, mari-ask-latch, review-cards. Playwright on a throwaway data dir with a seeded held change (no model): decline one of two fields, Keep, only the other field is saved; at 1440 and 390, 10/10. Full pnpm check not run locally. Only the English string changed.

To verify manually:

  1. Ask Prof. Mari to change two fields of a character in Manual mode. Press "Not this one" on one field. It keeps its old text.
  2. Press Keep on the other field. Only that field changes.
  3. Repeat, but press Accept on her card instead of Keep. The declined field stays unchanged.
  4. Press "Not this one" on every field. The whole change is rejected.

Docs and release impact

  • No docs changes needed
  • Updated docs (README / CONTRIBUTING / android/README) as needed
  • Translated docs on the docs-i18n branch updated to match, or a [docs-i18n] follow-up issue opened (see CONTRIBUTING.md § Translated documentation)
  • Version/release files updated (only if this PR includes a version bump)

UI evidence (if applicable)

Screenshots are local; attach on request.


🔄 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/8573 **Author:** [@Gunterlie](https://github.com/Gunterlie) **Created:** 10/30/2026 **Status:** ✅ Merged **Merged:** 10/30/2026 **Merged by:** [@Gunterlie](https://github.com/Gunterlie) **Base:** `staging` ← **Head:** `feat/mari-decline-one-field` --- ### 📝 Commits (7) - [`bf6ec20`](https://github.com/Pasta-Devs/Marinara-Engine/commit/bf6ec201e8e6e12fb2a4f5d04f583e779fbf14d8) feat(mari): Not this one rejects only that field of a held change - [`ba82cc8`](https://github.com/Pasta-Devs/Marinara-Engine/commit/ba82cc8b7c579e1adcaa395298b7f02525c7e8e1) fix(mari): keep unreviewed fields when declining one, scope declined line per editor - [`873c618`](https://github.com/Pasta-Devs/Marinara-Engine/commit/873c61893b52f8d92255d1ca8bef5ec03ea93e46) Merge origin/staging into feat/mari-decline-one-field - [`9a85d14`](https://github.com/Pasta-Devs/Marinara-Engine/commit/9a85d14f57ab9582f0104ca01841200d6636b60c) fix(mari): settle ignores declined fields, accept guards for declined fields - [`e640a1e`](https://github.com/Pasta-Devs/Marinara-Engine/commit/e640a1ead7d14be2d1b0d6a8b928fb24eacce68e) Merge origin/staging into feat/mari-decline-one-field - [`00a5428`](https://github.com/Pasta-Devs/Marinara-Engine/commit/00a5428e6ecbaf0297e8b17a90a458df8116c161) Merge origin/staging into feat/mari-decline-one-field - [`02b7e78`](https://github.com/Pasta-Devs/Marinara-Engine/commit/02b7e78f36ae3ec506d0482a23d3d9272530193d) fix(mari): apply declined fields to every held call instead of refusing large changes ### 📊 Changes **11 files changed** (+458 additions, -251 deletions) <details> <summary>View changed files</summary> 📝 `packages/client/src/components/characters/MariFieldReview.tsx` (+48 -18) 📝 `packages/client/src/components/chat/HomeProfessorMariChat.tsx` (+15 -8) 📝 `packages/client/src/lib/mari-editor-fields.ts` (+42 -221) 📝 `packages/client/src/localization/locales/en.json` (+1 -1) 📝 `packages/client/src/stores/ui.store.ts` (+5 -0) 📝 `packages/server/src/routes/professor-mari-workspace.routes.ts` (+4 -0) 📝 `packages/server/src/services/professor-mari/workspace-agent.service.ts` (+10 -3) 📝 `packages/shared/src/index.ts` (+1 -0) 📝 `packages/shared/src/types/professor-mari-workspace.ts` (+2 -0) ➕ `packages/shared/src/utils/mari-editor-fields.ts` (+270 -0) 📝 `scripts/regressions/mari-editor-fields.regression.ts` (+60 -0) </details> ### 📄 Description ## Linked issue No issue: planned work on Prof. Mari's in-field review. ## Why this change In Prof. Mari's in-field review, "Not this one" declined the whole held change and asked Mari to propose it again. A user who disliked one field lost the good fields too and waited for a new reply. ## What changed - "Not this one" now rejects only that field. The field keeps its old text, and Keep applies the rest of the held change. - The declined fields (record id and field id) are kept in the UI store. Every Accept sends them: the field's Keep, the card's Accept, the chip, and a typed accept. The server drops those fields from the stored held calls before it applies them. A call left with no editor field is dropped. - When the last field is declined and no other record is held, the whole change is rejected, as before. - The field-id logic (`MARI_EDITOR_KINDS`, `mariPatchFieldId`, `mariFieldPath`, `mariUpdateCall`) moved from the client to `packages/shared/src/utils/mari-editor-fields.ts`, so client and server use the same ids. The client file re-exports it. New: `withoutDeclinedMariFields`. - Esc on a field review still answers that field, now as "Not this one" for the field. - New route field: `context.declinedFields` on the workspace prompt request. ## Validation - [ ] `pnpm check` passes locally - [ ] Container (Docker / Podman) built and ran without issue - [ ] Ran the app, clicked through the changes manually - [ ] Checked edge cases (light + dark mode, mobile viewport, empty states, error paths) - [ ] Above manual verification completed (describe below) - [ ] Read and followed `CONTRIBUTING.md` ### Manual verification notes Agent-run (not manual): client and server `tsc`, ESLint on client files (one pre-existing warning, `serverRun`), Prettier, `localization:check`, regressions `mari-editor-fields` (new cases for declined fields, another record's call, and the Accept paths), `mari-hold`, `mari-ask-latch`, `review-cards`. Playwright on a throwaway data dir with a seeded held change (no model): decline one of two fields, Keep, only the other field is saved; at 1440 and 390, 10/10. Full `pnpm check` not run locally. Only the English string changed. To verify manually: 1. Ask Prof. Mari to change two fields of a character in Manual mode. Press "Not this one" on one field. It keeps its old text. 2. Press Keep on the other field. Only that field changes. 3. Repeat, but press Accept on her card instead of Keep. The declined field stays unchanged. 4. Press "Not this one" on every field. The whole change is rejected. ## Docs and release impact - [ ] No docs changes needed - [ ] Updated docs (README / CONTRIBUTING / android/README) as needed - [ ] Translated docs on the `docs-i18n` branch updated to match, or a `[docs-i18n]` follow-up issue opened (see CONTRIBUTING.md § Translated documentation) - [ ] Version/release files updated (only if this PR includes a version bump) ## UI evidence (if applicable) Screenshots are local; attach on request. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-07 17:38:53 +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#8683
No description provided.