sokko-g/website/src/styles
Shinuwa ac81b5e22f
All checks were successful
Validate and deploy Sokko G / validate (push) Successful in 25m18s
Validate and deploy Sokko G / deploy (push) Successful in 16s
Move TCG gauges, badges and tooltips onto the NDS
- nds-progress tint variant, nds-badge sm size and tint variant
- --color-scrim and --color-bg-inset tokens
- native title attributes replaced by Tooltip
- TCG colors equal to a token now reference it

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-05 19:44:00 +01:00
..
design-system Move TCG gauges, badges and tooltips onto the NDS 2026-12-05 19:44:00 +01:00
games Let a guide checklist update from its page filters without losing checks, and optionally limit the page to what the checklist contains 2026-12-01 17:39:00 +01:00
home fix add tools button from catalog position 2026-10-22 23:40:03 +02:00
icons Use the share icon and space the share dialog footer 2026-11-11 17:11:14 +01:00
overlays Open any toolbox from a list in Sokko TCG's toolbox drawer 2026-11-30 14:31:53 +01:00
toolboxes Add quantitative tasks with checklist controls to the planner 2026-10-24 15:02:33 +02:00
_aniimo.scss Add Aniimo elemental matchup calculator 2026-10-31 09:43:04 +01:00
_base.scss Migrate site controls to Nebula design system 2026-08-29 09:16:58 +02:00
_cards.scss Refine toolbox navigation and local data controls 2026-10-15 10:52:34 +02:00
_components.scss Add responsive game filters and hybrid toolbox drawer 2026-09-27 18:00:49 +02:00
_design-system.scss Add responsive game filters and hybrid toolbox drawer 2026-09-27 18:00:49 +02:00
_diablo4.scss Add goal tree toolbox module 2026-08-22 18:15:39 +02:00
_games.scss Split large Sass files into focused partials 2026-08-25 08:48:47 +02:00
_home.scss Split large Sass modules by feature area 2026-08-24 20:07:24 +02:00
_icons.scss Split remaining large Sass files by responsibility 2026-08-25 09:45:59 +02:00
_mhwilds.scss Refocus responsive layouts on compact desktop use 2026-10-05 15:47:46 +02:00
_mixins.scss Document every Sass mixin and function with SassDoc and drop the unused ones 2026-12-01 16:22:36 +01:00
_nebula-admin-guild.scss Move TCG gauges, badges and tooltips onto the NDS 2026-12-05 19:44:00 +01:00
_nebula-cards-nav.scss Load the Sokko TCG styles with the cards route 2026-11-21 17:23:14 +01:00
_nebula-cards.scss Move TCG gauges, badges and tooltips onto the NDS 2026-12-05 19:44:00 +01:00
_nebula-daily.scss Move TCG gauges, badges and tooltips onto the NDS 2026-12-05 19:44:00 +01:00
_nebula-expedition-bag.scss Move TCG gauges, badges and tooltips onto the NDS 2026-12-05 19:44:00 +01:00
_nebula-expedition-destinations.scss Move TCG gauges, badges and tooltips onto the NDS 2026-12-05 19:44:00 +01:00
_nebula-expedition-journey.scss Move TCG gauges, badges and tooltips onto the NDS 2026-12-05 19:44:00 +01:00
_nebula-expedition-loadout.scss Move TCG gauges, badges and tooltips onto the NDS 2026-12-05 19:44:00 +01:00
_nebula-expedition-sets.scss Move TCG gauges, badges and tooltips onto the NDS 2026-12-05 19:44:00 +01:00
_nebula-expeditions.scss Move TCG gauges, badges and tooltips onto the NDS 2026-12-05 19:44:00 +01:00
_nebula-mirror.scss Move TCG gauges, badges and tooltips onto the NDS 2026-12-05 19:44:00 +01:00
_nebula-mobile-sections.scss Move TCG gauges, badges and tooltips onto the NDS 2026-12-05 19:44:00 +01:00
_nebula-mobile.scss Move TCG gauges, badges and tooltips onto the NDS 2026-12-05 19:44:00 +01:00
_nebula-race.scss Move TCG gauges, badges and tooltips onto the NDS 2026-12-05 19:44:00 +01:00
_nebula-team.scss Move TCG gauges, badges and tooltips onto the NDS 2026-12-05 19:44:00 +01:00
_nebula.scss Move TCG gauges, badges and tooltips onto the NDS 2026-12-05 19:44:00 +01:00
_overlays.scss Send a toolbox through an encrypted link 2026-11-11 16:26:05 +01:00
_responsive.scss Add quantitative tasks with checklist controls to the planner 2026-10-24 15:02:33 +02:00
_shell.scss Show a full reserve count on the Sokko TCG menu icon and remaining openings while opening a pack 2026-11-07 23:16:47 +01:00
_tokens.scss Move TCG gauges, badges and tooltips onto the NDS 2026-12-05 19:44:00 +01:00
_toolboxes.scss Improve toolbox architecture and initial bundle loading 2026-08-14 09:13:53 +02:00
AGENTS.md Stop new code from skipping its JSDoc or SassDoc, and tell agents to fix old gaps as they go 2026-12-01 16:34:47 +01:00
cards-mobile-route.scss Let players use Sokko TCG from a phone through a mobile fallback mode 2026-12-03 23:55:35 +01:00
cards-route.scss Add an expedition set workshop to build sets without equipping 2026-12-05 15:40:19 +01:00
main.scss Load the Sokko TCG styles with the cards route 2026-11-21 17:23:14 +01:00
README.md Let players use Sokko TCG from a phone through a mobile fallback mode 2026-12-03 23:55:35 +01:00

Styles (Sass)

Tout le style du site, écrit en Sass (syntaxe SCSS) et compilé par Vite. Il repose sur le Nebula Design System (NDS) : des tokens (couleurs, espaces, rayons), des classes publiques nds-* et des mixins. La référence visuelle est DESIGN_SYSTEM.md ; la page #/design-system (en développement seulement) montre tous les contrôles.

Comment les feuilles sont chargées

Point d'entrée Chargé par Contenu
main.scss main.jsx, sur toutes les pages Tokens, fond, shell, accueil, composants, jeux, toolboxes, overlays, design system, adaptations responsive
cards-route.scss features/cards/CardsPage.jsx, seulement sur la route #/cards Toutes les feuilles _nebula-*.scss de Sokko TCG
cards-mobile-route.scss features/cards/mobile/MobileCardsApp.jsx, seulement en mode mobile (#/mobile/cards), après cards-route.scss _nebula-mobile.scss (cadre) et _nebula-mobile-sections.scss (adaptations des sections), tout sous .nebula-mobile (body.nebula-mobile-body pour les fenêtres)

L'ordre des @use compte : à spécificité égale, la dernière règle gagne. cards-route.scss ré-émet à la fin les feuilles qui suivaient les cartes dans main.scss, pour garder la même priorité. tests/static-styles.test.mjs vérifie que les deux listes restent alignées.

Organisation

Chemin Contenu
_tokens.scss Variables CSS du thème (--color-*, --space-*, raretés…)
_mixins.scss Mixins partagés du thème
design-system/ Le NDS : controls/ (mixins des contrôles), attributes/ (classes publiques nds-* et attributs data-*), _surfaces.scss
_base.scss, _shell.scss, _nebula.scss Bases HTML, mise en page générale et menu, fond étoilé
_cards.scss Cartes et panneaux génériques du site (pas Sokko TCG)
_components.scss, overlays/, icons/ Composants partagés ; modales, tiroirs, notifications ; icônes SVG en masque
home/ Accueil, Librairie, À propos
games/, _games.scss, _mhwilds.scss, _diablo4.scss, _aniimo.scss Pages de jeux : communs, puis un fichier par jeu
toolboxes/, _toolboxes.scss Toolboxes : cadre des outils, contrôles partagés, un fichier ou dossier par outil
_nebula-*.scss Sokko TCG (ancien nom de code « nebula cards ») : un fichier par mécanique (-daily, -expeditions, -team, -race, -mirror…)
_responsive.scss Adaptations aux largeurs (validées à partir de 768 px) et préférences d'accessibilité

Règles

  • Réutiliser les tokens, les classes nds-* et les mixins existants avant d'écrire un style propre à un écran.
  • Un nouveau motif visuel réutilisable se documente dans DESIGN_SYSTEM.md.
  • Une nouvelle feuille de Sokko TCG s'ajoute à cards-route.scss, pas à main.scss.
  • Chaque fichier commence par // Rôle : …, et chaque mixin ou fonction a un bloc SassDoc /// au-dessus (vérifiés par tests/static-styles.test.mjs ; gabarit dans website/AGENTS.md). Survoler un @include dans VS Code affiche sa description, avec l'extension « SCSS IntelliSense ».

Vérifier

npm run check                          # compile tout le Sass via le build
npx playwright test e2e/style-layouts.spec.js e2e/nds-controls.spec.js
npm run test:assets                    # poids du CSS initial (après un build)