[PR #3431] [MERGED] Fix custom preset choice confirmation #5931

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

📋 Pull Request Information

Original PR: https://github.com/Pasta-Devs/Marinara-Engine/pull/3431
Author: @SpicyMarinara
Created: 7/10/2026
Status: ✅ Merged
Merged: 7/10/2026
Merged by: @SpicyMarinara

Base: staging ← Head: agent/fix-preset-choice-confirm-3429


📝 Commits (2)

  • 7cd0fe3 chore: claim preset choice confirmation issue
  • 6e3a246 fix: allow blank preset choices

📊 Changes

4 files changed (+69 additions, -7 deletions)

View changed files

📝 CHANGELOG.md (+1 -0)
📝 packages/client/src/components/presets/ChoiceSelectionModal.tsx (+2 -7)
➕ packages/client/src/lib/preset-choice-selection.ts (+30 -0)
📝 scripts/regressions/open-issues.regression.ts (+36 -0)

📄 Description

Linked issue

Closes #3429

Why

Custom and imported presets may intentionally use a blank option value to mean “insert nothing.” The choice modal treated that valid value as an incomplete selection, so choosing it disabled Confirm Choices and trapped the user in the editor.

What changed

  • Validate single-select choices by membership in the preset options instead of string truthiness.
  • Keep blank-valued options, Boolean-off states, and empty multi-select arrays confirmable.
  • Reject stale single-select values that are not present in the current preset.
  • Add focused regression coverage and an Unreleased changelog entry.

Validation performed

  • pnpm check
  • pnpm test
  • pnpm regression:issues

Manual verification requested

  • Manually verify a custom/imported Roleplay preset can confirm a blank-valued option.
  • Manually verify normal radio, Boolean, and multi-select preset choices still save correctly.

🔄 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/3431 **Author:** [@SpicyMarinara](https://github.com/SpicyMarinara) **Created:** 7/10/2026 **Status:** ✅ Merged **Merged:** 7/10/2026 **Merged by:** [@SpicyMarinara](https://github.com/SpicyMarinara) **Base:** `staging` ← **Head:** `agent/fix-preset-choice-confirm-3429` --- ### 📝 Commits (2) - [`7cd0fe3`](https://github.com/Pasta-Devs/Marinara-Engine/commit/7cd0fe344186a4a5d19db3e820bd373c45344e2b) chore: claim preset choice confirmation issue - [`6e3a246`](https://github.com/Pasta-Devs/Marinara-Engine/commit/6e3a24680432f5b5f281103163443f3d49f86bea) fix: allow blank preset choices ### 📊 Changes **4 files changed** (+69 additions, -7 deletions) <details> <summary>View changed files</summary> 📝 `CHANGELOG.md` (+1 -0) 📝 `packages/client/src/components/presets/ChoiceSelectionModal.tsx` (+2 -7) ➕ `packages/client/src/lib/preset-choice-selection.ts` (+30 -0) 📝 `scripts/regressions/open-issues.regression.ts` (+36 -0) </details> ### 📄 Description ## Linked issue Closes #3429 ## Why Custom and imported presets may intentionally use a blank option value to mean “insert nothing.” The choice modal treated that valid value as an incomplete selection, so choosing it disabled **Confirm Choices** and trapped the user in the editor. ## What changed - Validate single-select choices by membership in the preset options instead of string truthiness. - Keep blank-valued options, Boolean-off states, and empty multi-select arrays confirmable. - Reject stale single-select values that are not present in the current preset. - Add focused regression coverage and an Unreleased changelog entry. ## Validation performed - `pnpm check` - `pnpm test` - `pnpm regression:issues` ## Manual verification requested - Manually verify a custom/imported Roleplay preset can confirm a blank-valued option. - Manually verify normal radio, Boolean, and multi-select preset choices still save correctly. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-23 04:05:18 +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#5931
No description provided.