[GH-ISSUE #2579] Port creator-notes card-CSS injection (tri-state mode) to staging (from refactor #1748) #1272

Closed
opened 2026-10-21 05:30:28 +07:00 by bsakaguchi · 0 comments
Owner

Originally created by @kolacheee on GitHub (Jun 15, 2026).
Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/2579

Summary

Port creator-notes card-CSS injection with tri-state mode to staging. Shipped to refactor in #1748. staging currently has only a narrow inline-<style> sanitizer, not the full card-CSS system.

Why

Character creators embed CSS in creator notes to theme their cards. This feature injects that CSS in a scoped, sanitized way with a tri-state mode controlling how/where card CSS applies (off / scoped / exclusive), giving users control over creator styling without it leaking app-wide.

Scope (Node re-implementation)

  • client: a card-CSS injector component, [data-card-css] scoping, the tri-state cardCssMode setting + persistence, and wiring into chat rendering.
  • shared: any shared sanitizer/scoping helpers (should reuse the hardened sanitizer from the #2020 port).
  • Note: re-implementation on the Node stack.

Dependencies

Should build on the sanitizer hardening port (source: refactor #2020). Blocks the card-CSS theming port (source: refactor #1812).

Reference

  • Source: refactor #1748 — "feat: creator notes CSS injection with tri-state mode"
Originally created by @kolacheee on GitHub (Jun 15, 2026). Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/2579 ## Summary Port **creator-notes card-CSS injection with tri-state mode** to `staging`. Shipped to `refactor` in #1748. `staging` currently has only a narrow inline-`<style>` sanitizer, not the full card-CSS system. ## Why Character creators embed CSS in creator notes to theme their cards. This feature injects that CSS in a scoped, sanitized way with a **tri-state mode** controlling how/where card CSS applies (off / scoped / exclusive), giving users control over creator styling without it leaking app-wide. ## Scope (Node re-implementation) - **client**: a card-CSS injector component, `[data-card-css]` scoping, the tri-state `cardCssMode` setting + persistence, and wiring into chat rendering. - **shared**: any shared sanitizer/scoping helpers (should reuse the hardened sanitizer from the #2020 port). - Note: re-implementation on the Node stack. ## Dependencies Should build on the **sanitizer hardening** port (source: refactor #2020). Blocks the card-CSS theming port (source: refactor #1812). ## Reference - Source: refactor #1748 — "feat: creator notes CSS injection with tri-state mode"
bsakaguchi 2026-10-21 05:30:28 +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#1272
No description provided.