[GH-ISSUE #6279] [Feature]: Add varied Roleplay document styles and inline animated dice rolls #3501

Closed
opened 2026-10-21 06:03:43 +07:00 by bsakaguchi · 2 comments
Owner

Originally created by @SpicyMarinara on GitHub (Sep 17, 2026).
Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/6279

Originally assigned to: @SpicyMarinara on GitHub.

What problem does this solve?

Roleplay Commands can produce documents, posters, and other in-world material, but their presentation feels too plain and repetitive. These outputs need more visual flair and variety to feel like part of the scene.

Dice rolls already have an animation and visual display elsewhere in the app. When the model uses a roll command in Roleplay mode, that same experience should appear inside the message, at the point where the command was used.

Both improvements must work in mobile view as well as on desktop.

Proposed solution

Document styling

  • Provide a few visually distinct, expressive styles for each supported document type: notes, letters, journals, reports, posters, terminals, and the generic document fallback.
  • Give each type appropriate typography, framing, spacing, and decorative treatment while keeping its title and contents readable.
  • Randomly select a style from the matching type's variants for each new document-command occurrence, including multiple documents in one message.
  • Keep the selected style stable for that occurrence when the message rerenders or the chat is reopened.

Inline dice rolls

  • Reuse the existing dice animation and result display for model-issued Roleplay roll commands.
  • Embed the dice directly in the message at the command's original position, preserving the surrounding narrative order.
  • Show the actual resolved dice values, modifiers, and total; displaying the animation must never trigger another roll or change the outcome.
  • Handle multiple roll commands in a message independently. New rolls should animate, while revisiting existing messages should preserve their results without restarting animations on ordinary rerenders.

Mobile and accessibility

  • Keep document variants and inline dice contained within the message at narrow widths, without clipped content or horizontal page overflow.
  • Support long document titles/content and multiple dice, with readable text and touch-friendly controls wherever controls are shown.
  • Preserve legibility in light and dark themes and respect reduced-motion preferences.

Alternatives considered

Keeping one presentation per document type does not provide the requested variety. Showing rolls only in a separate panel or command activity disclosure does not place the dice at the relevant moment in the narrative. Reusing the existing dice renderer keeps the interaction consistent with the rest of the app.

Additional context

Owner: @SpicyMarinara. This is an Engine UI/command-rendering enhancement; implementation should target staging.

Related completed work: #5969 and #5990.

Existing entry points include RoleplayDocument.tsx, styles/roleplay-documents.css, RoleplayCommandResults.tsx, and components/dice/AnimatedDiceRoll.tsx.

Acceptance and manual verification:

  • Manually verify several distinct variants for every supported document type and a valid fallback for unknown types.
  • Verify each new document occurrence receives a random variant that remains stable across rerenders, swipes, and reopening the chat.
  • Manually verify a message containing narrative before and after a roll renders animated dice at that exact position.
  • Verify multiple rolls retain their individual positions and match the command's resolved results without rerolling.
  • Manually verify documents and inline dice on desktop and mobile, including long content, light/dark themes, and reduced motion.
  • Preserve command activity and document editing/deletion behavior; localize any new user-facing copy.

These are requirements for the future implementation, not completed validation.

Template check

Please uncheck (untick) the box below before submitting so we know you read the template. It is intentionally pre-checked:

  • I DID NOT read this template and provide the requested details.
Originally created by @SpicyMarinara on GitHub (Sep 17, 2026). Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/6279 Originally assigned to: @SpicyMarinara on GitHub. ## What problem does this solve? Roleplay Commands can produce documents, posters, and other in-world material, but their presentation feels too plain and repetitive. These outputs need more visual flair and variety to feel like part of the scene. Dice rolls already have an animation and visual display elsewhere in the app. When the model uses a roll command in Roleplay mode, that same experience should appear inside the message, at the point where the command was used. Both improvements must work in mobile view as well as on desktop. ## Proposed solution **Document styling** - Provide a few visually distinct, expressive styles for each supported document type: notes, letters, journals, reports, posters, terminals, and the generic document fallback. - Give each type appropriate typography, framing, spacing, and decorative treatment while keeping its title and contents readable. - Randomly select a style from the matching type's variants for each new document-command occurrence, including multiple documents in one message. - Keep the selected style stable for that occurrence when the message rerenders or the chat is reopened. **Inline dice rolls** - Reuse the existing dice animation and result display for model-issued Roleplay roll commands. - Embed the dice directly in the message at the command's original position, preserving the surrounding narrative order. - Show the actual resolved dice values, modifiers, and total; displaying the animation must never trigger another roll or change the outcome. - Handle multiple roll commands in a message independently. New rolls should animate, while revisiting existing messages should preserve their results without restarting animations on ordinary rerenders. **Mobile and accessibility** - Keep document variants and inline dice contained within the message at narrow widths, without clipped content or horizontal page overflow. - Support long document titles/content and multiple dice, with readable text and touch-friendly controls wherever controls are shown. - Preserve legibility in light and dark themes and respect reduced-motion preferences. ## Alternatives considered Keeping one presentation per document type does not provide the requested variety. Showing rolls only in a separate panel or command activity disclosure does not place the dice at the relevant moment in the narrative. Reusing the existing dice renderer keeps the interaction consistent with the rest of the app. ## Additional context Owner: @SpicyMarinara. This is an Engine UI/command-rendering enhancement; implementation should target `staging`. Related completed work: #5969 and #5990. Existing entry points include `RoleplayDocument.tsx`, `styles/roleplay-documents.css`, `RoleplayCommandResults.tsx`, and `components/dice/AnimatedDiceRoll.tsx`. Acceptance and manual verification: - [ ] Manually verify several distinct variants for every supported document type and a valid fallback for unknown types. - [ ] Verify each new document occurrence receives a random variant that remains stable across rerenders, swipes, and reopening the chat. - [ ] Manually verify a message containing narrative before and after a roll renders animated dice at that exact position. - [ ] Verify multiple rolls retain their individual positions and match the command's resolved results without rerolling. - [ ] Manually verify documents and inline dice on desktop and mobile, including long content, light/dark themes, and reduced motion. - [ ] Preserve command activity and document editing/deletion behavior; localize any new user-facing copy. These are requirements for the future implementation, not completed validation. ## Template check Please **uncheck (untick)** the box below before submitting so we know you read the template. It is intentionally pre-checked: - [ ] I DID NOT read this template and provide the requested details.
Author
Owner

@SpicyMarinara commented on GitHub (Sep 17, 2026):

Owner: @SpicyMarinara. Codex is addressing this in draft PR #6282 as part of the requested issue sweep. Focused implementation and regression/browser verification are in progress.

<!-- gh-comment-id:5710998134 --> @SpicyMarinara commented on GitHub (Sep 17, 2026): Owner: @SpicyMarinara. Codex is addressing this in draft PR #6282 as part of the requested issue sweep. Focused implementation and regression/browser verification are in progress.
Author
Owner

@SpicyMarinara commented on GitHub (Sep 17, 2026):

Implemented in #6282, now merged to staging after the final CI and CodeRabbit gates passed.

<!-- gh-comment-id:5712578626 --> @SpicyMarinara commented on GitHub (Sep 17, 2026): Implemented in #6282, now merged to staging after the final CI and CodeRabbit gates passed.
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#3501
No description provided.