WORK-078
ID:WORK-078Status:done

BEM Modifier Hygiene for Storytelling Runes

Priority:mediumComplexity:trivialSource:SPEC-028
changeset-release/main View source

Criteria completion

No incremental history — criteria tracking started on Apr 19.

Branches 2
changeset-release/main current done
main doneclaude/file-naming-convention-LJdwR done
History 5
  1. f2b3512
    Content editedby Claude
    Add {ID}-{slug}.md filename convention + migrate filenames subcommand
  2. 59ded4a
    Content editedby Claude
    Implement SPEC-037 plan package hardening: all 7 work items
  3. f262d7b
    Content editedby Claude
    Backfill source attributes on all 123 work items
  4. bfa195e
    Content editedby Claude
    Mark WORK-076, WORK-077, WORK-078 as done
  5. 9aff526
    Created (done)by Claude
    Add work items WORK-076 through WORK-082 for SPEC-028

Summary

Several storytelling rune configs emit BEM modifier classes for free-form string attributes (aliases, tags, parent, scale, factionType, id, track, follows). These produce unusable CSS selectors like .rf-character--"Gandalf the Grey,Mithrandir". Add noBemClass: true to these modifiers so only data-* attributes are emitted.

Acceptance Criteria

  • character config: aliases and tags modifiers have noBemClass: true
  • realm config: scale, tags, and parent modifiers have noBemClass: true
  • faction config: factionType and tags modifiers have noBemClass: true
  • lore config: tags modifier has noBemClass: true
  • plot config: tags modifier has noBemClass: true
  • beat config: id, track, and follows modifiers have noBemClass: true
  • Data attributes still emitted for all modified fields (verified via refrakt inspect)
  • CSS coverage tests still pass (no selectors should depend on these classes)

Approach

Config-only changes in runes/storytelling/src/config.ts. Add noBemClass: true to each identified modifier. Run tests to verify data attributes are preserved and no CSS breaks.

References

  • SPEC-028 (Standard 1 — BEM Modifier Classes for Enumerable Values Only)