[PR #4560] [MERGED] Fix inline HTML spacing and surface documentation #6422

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

📋 Pull Request Information

Original PR: https://github.com/Pasta-Devs/Marinara-Engine/pull/4560
Author: @SpicyMarinara
Created: 8/4/2026
Status: ✅ Merged
Merged: 8/4/2026
Merged by: @SpicyMarinara

Base: staging ← Head: agent/issue-sweep-4557-4559


📝 Commits (2)

  • fc4807d Highlight documentation in onboarding
  • fc2cede Preserve inline HTML message breaks

📊 Changes

7 files changed (+153 additions, -21 deletions)

View changed files

📝 package.json (+1 -1)
📝 packages/client/src/components/chat/ChatArea.tsx (+1 -0)
📝 packages/client/src/components/chat/ChatMessage.tsx (+2 -16)
📝 packages/client/src/components/onboarding/OnboardingTutorial.tsx (+16 -4)
➕ packages/client/src/lib/chat-html-newlines.ts (+85 -0)
📝 packages/client/src/localization/locales/en.json (+2 -0)
➕ scripts/regressions/chat-html-newlines.regression.ts (+46 -0)

📄 Description

Linked issues

Closes #4557
Closes #4559

Why this change

  • Intentional newlines between adjacent inline HTML elements were discarded, causing separately authored lines to run together.
  • The final onboarding slide discussed documentation without clearly pointing users to the Home Documentation control or giving mobile users a direct action.

What changed

  • Preserve authored line breaks between adjacent inline HTML siblings while retaining compact source formatting around block and nested tags.
  • Keep SVG content and multiline HTML attributes untouched by newline conversion.
  • Add focused regression coverage for inline, block, CRLF, SVG, attribute, image, and ordinary-text cases.
  • Highlight the Home Documentation control from the final onboarding step.
  • Add a prominent, mobile-safe, theme-token-based Documentation action to the final onboarding card.
  • Localize the final-step guidance through the canonical English catalog.

Automated evidence

  • pnpm --filter @marinara-engine/server exec tsx ../../scripts/regressions/chat-html-newlines.regression.ts
  • pnpm --filter @marinara-engine/client exec tsc -b --pretty false
  • Focused client ESLint on the changed UI and helper files
  • pnpm localization:check
  • pnpm impeccable:check
  • pnpm version:check
  • git diff --check origin/staging...HEAD

Manual validation

  • Manually verify adjacent inline HTML and block-formatted HTML in Roleplay mode
  • Manually verify the final onboarding step on desktop and mobile
  • Verify the Documentation action opens the in-app documentation above the tutorial

UI evidence

  • Attach screenshots of the final onboarding step on desktop and mobile

The in-app browser runtime was unavailable during implementation, so browser validation and screenshots remain explicitly unclaimed.

Summary by CodeRabbit

  • New Features

    • Enhanced onboarding experience with dedicated documentation language setting that highlights built-in guides
  • Improvements

    • Refined chat message formatting for improved readability and display consistency
    • Enhanced documentation button discoverability in the home screen interface
  • Tests

    • Added regression test coverage for chat message newline handling

🔄 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/4560 **Author:** [@SpicyMarinara](https://github.com/SpicyMarinara) **Created:** 8/4/2026 **Status:** ✅ Merged **Merged:** 8/4/2026 **Merged by:** [@SpicyMarinara](https://github.com/SpicyMarinara) **Base:** `staging` ← **Head:** `agent/issue-sweep-4557-4559` --- ### 📝 Commits (2) - [`fc4807d`](https://github.com/Pasta-Devs/Marinara-Engine/commit/fc4807d5209ac3dcfeda2c21675b2a4eb25150e0) Highlight documentation in onboarding - [`fc2cede`](https://github.com/Pasta-Devs/Marinara-Engine/commit/fc2cede9ea1923c3d5b2b7a5902308bc7a4ebd0d) Preserve inline HTML message breaks ### 📊 Changes **7 files changed** (+153 additions, -21 deletions) <details> <summary>View changed files</summary> 📝 `package.json` (+1 -1) 📝 `packages/client/src/components/chat/ChatArea.tsx` (+1 -0) 📝 `packages/client/src/components/chat/ChatMessage.tsx` (+2 -16) 📝 `packages/client/src/components/onboarding/OnboardingTutorial.tsx` (+16 -4) ➕ `packages/client/src/lib/chat-html-newlines.ts` (+85 -0) 📝 `packages/client/src/localization/locales/en.json` (+2 -0) ➕ `scripts/regressions/chat-html-newlines.regression.ts` (+46 -0) </details> ### 📄 Description ## Linked issues Closes #4557 Closes #4559 ## Why this change - Intentional newlines between adjacent inline HTML elements were discarded, causing separately authored lines to run together. - The final onboarding slide discussed documentation without clearly pointing users to the Home Documentation control or giving mobile users a direct action. ## What changed - Preserve authored line breaks between adjacent inline HTML siblings while retaining compact source formatting around block and nested tags. - Keep SVG content and multiline HTML attributes untouched by newline conversion. - Add focused regression coverage for inline, block, CRLF, SVG, attribute, image, and ordinary-text cases. - Highlight the Home Documentation control from the final onboarding step. - Add a prominent, mobile-safe, theme-token-based Documentation action to the final onboarding card. - Localize the final-step guidance through the canonical English catalog. ## Automated evidence - `pnpm --filter @marinara-engine/server exec tsx ../../scripts/regressions/chat-html-newlines.regression.ts` - `pnpm --filter @marinara-engine/client exec tsc -b --pretty false` - Focused client ESLint on the changed UI and helper files - `pnpm localization:check` - `pnpm impeccable:check` - `pnpm version:check` - `git diff --check origin/staging...HEAD` ## Manual validation - [ ] Manually verify adjacent inline HTML and block-formatted HTML in Roleplay mode - [ ] Manually verify the final onboarding step on desktop and mobile - [ ] Verify the Documentation action opens the in-app documentation above the tutorial ## UI evidence - [ ] Attach screenshots of the final onboarding step on desktop and mobile The in-app browser runtime was unavailable during implementation, so browser validation and screenshots remain explicitly unclaimed. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Enhanced onboarding experience with dedicated documentation language setting that highlights built-in guides * **Improvements** * Refined chat message formatting for improved readability and display consistency * Enhanced documentation button discoverability in the home screen interface * **Tests** * Added regression test coverage for chat message newline handling <!-- end of auto-generated comment: release notes by coderabbit.ai --> --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-23 04:10:16 +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#6422
No description provided.