Rename the pre-existing `.shinychat-*` CSS classes to the `.shiny-chat-*` prefix
needs clarificationPriority: Mediumai-triage:needs-review
shinychat renders two families of CSS class names with inconsistent prefixes:
- `.shiny-chat-*` — the older, dominant convention (`.shiny-chat-container`, `.shiny-chat-message`, `.shiny-chat-input`, …).
- `.shinychat-*` (no hyphen) — a scattering of newer classes.
They should be unified on `.shiny-chat-*`.
The condensed tool-view classes (`.shinychat-tool-group*`, `.shinychat-tool-call-row*`, `.shinychat-tool-loop`, `.shinychat-tool-row__intent`, `.shinychat-tool-custom-display`, `.shinychat-tool-glyph-dot`, `.shinychat-tool-spacer`) are being renamed in #283 as they are new there and carry no back-compat cost. **This issue covers the remaining `.shinychat-*` classes, which already ship on `main`:**
- **Thinking:** `.shinychat-thinking`, `-header`, `-label`, `-topic`, `-glyph`, `-dot`, `-disclosure`, `-content`, `-content-inner`
- **PDF attachment:** `.shinychat-pdf`, `__filename`, `__icon`
- **Buttons:** `.shinychat-btn-always`, `-cancel`, `-close`, `-proceed`
- **Misc:** `.shinychat-raw-html`, `.shinychat-browser-token`, `.shinychat-link`, `.shinychat-content-extra`, `.shinychat-current`, `.shinychat-external-link-dialog`, `.shinychat-tool-image`
## Notes
- **Higher risk than the custom-property rename (#285) and than #283's new classes.** These are shipped, rendered DOM class names: authors target them in custom CSS, and unlike custom properties they cannot be cheaply aliased for back-compat. Weigh a deprecation window vs a clean break.
- Spans TypeScript/TSX (class assignments) and SCSS (selectors) in `js/src`, plus any selectors in the R/Python packages that reference these classes. Rebuild and redistribute to both packages after the rename (`npm run build`, `make py-update-dist r-update-dist`).
- Related: #285 is the custom-property half of the same inconsistency; ideally land both under one convention decision.
0 条评论