The Guild administration now has a tab per quest. The expedition settings sit behind a status band (open or close, today's activity) and four themed tabs, with units inside the fields, the default value shown, and one sticky apply bar that lists every change before confirming. The Pont des Veilleurs leaves the expedition page and becomes the « Éclats d’étoile » shop item, priced from Administration › Boutique. Openings and Éclats are bought by quantity: a number field capped by the stardust the player actually has, and a full-width button that shows the total cost. Stardust and Éclats get their own SVG icons, aligned with the text around them. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
23 lines
1.3 KiB
JavaScript
23 lines
1.3 KiB
JavaScript
// Rôle : affiche les deux monnaies de Sokko TCG, la poussière d'étoiles et les Éclats d'étoile, avec leur icône.
|
||
// Les icônes sont des images (static/icons) : leurs dégradés SVG ne peuvent pas entrer en conflit avec la page.
|
||
import { formatEclats } from "./expeditionFormat.js";
|
||
import { formatStardust } from "./stardustFormat.js";
|
||
|
||
const ICONS = { stardust: "/static/icons/stardust.svg", eclats: "/static/icons/eclat.svg" };
|
||
|
||
export function CurrencyIcon({ kind }) {
|
||
return <img className="nebula-currency-icon" data-currency={kind} src={ICONS[kind]} alt="" aria-hidden="true" />;
|
||
}
|
||
|
||
// Icône suivie d'un texte libre (« 70 Éclats ») dans un bouton ou un badge : un seul bloc en ligne, aligné sur le texte.
|
||
export function CurrencyAmount({ kind, children }) {
|
||
return <span className="nebula-currency-amount"><CurrencyIcon kind={kind} />{children}</span>;
|
||
}
|
||
|
||
export function StardustBalance({ value }) {
|
||
return <span className="nebula-stardust" aria-label={`${formatStardust(value)} d’étoiles`}><CurrencyIcon kind="stardust" />{value.toLocaleString("fr-FR")}</span>;
|
||
}
|
||
|
||
export function EclatsBalance({ value }) {
|
||
return <span className="nebula-eclats" aria-label={`${formatEclats(value)} Éclats d’étoile`}><CurrencyIcon kind="eclats" />{formatEclats(value)}</span>;
|
||
}
|