DiamondLightSource / DiamondLightSource/sci-react-ui

Investigate transition suppression for nested `data-mode`

Aperta
#258 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub
Lingua principale
TypeScript
Stelle
8
Fork
3
Merge medio
3g 15h
PR unite (30g)
5

Descrizione

Based on changes in #220, `data-mode` could be applied to any container, not just the document root. However, the `ThemeProvider` transition suppression currently only watches `document.documentElement`.

This works for our current Storybook use case, where nested themes are static, but it may not be sufficient if we later support components that switch between light and dark mode independently (for example, code editors or previews).

**Task**

- Review whether transition suppression should also support nested `data-mode` containers.
- Decide whether the current behaviour is sufficient or should be extended.

Guida per i contributori

Apri la guida per i contributori

Direzione di ricerca

Start by reviewing the ThemeProvider transition-suppression behavior and the changes in issue #220, focusing on how document.documentElement is observed today. Compare that behavior with nested data-mode containers, then document whether the current behavior is sufficient or define the scope needed to support independently switching nested themes.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
typescript
Ambito
frontend
Tipo di issue
Funzionalità
Difficoltà
4/5
Tempo stimato
3-5 giorni
Stato di attività
Tranquilla
Chiarezza
Abbastanza chiara
Idoneità per principianti
45/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.