/** * @file Une carte jouable dans la préparation d'une expédition ou l'inscription à une expédition ouverte : la * carte, sa Puissance en haut à droite, ses stats en icônes (nom au survol) et ses étiquettes : celles * utiles à la destination en pastilles (condition, dangers parés, Affinité), toutes au survol de * l'icône d'étiquette. */ import { Tooltip } from "../../components/Tooltip.jsx"; import { fillTemplate } from "./dailyShare.js"; import { cardHelps, editionEntry, formatDecimal, STAT_BY_PLAN, STAT_IDS, tagLabel } from "./expeditionFormat.js"; import { MaskIcon } from "./ExpeditionLabels.jsx"; import { NebulaCard } from "./NebulaCard.jsx"; export function ExpeditionCardTile({ catalog, card, destination, content, selected, sortKey = null, onSelect }) { const entry = editionEntry(catalog, card.editionId); if (!entry) return null; const vocation = STAT_BY_PLAN[card.plan]; const helps = cardHelps(card, destination); const tags = (card.tags || []).map((tag) => tagLabel(catalog, tag)); const powerLabel = vocation ? fillTemplate(content.powerVocation, { power: card.power, stat: content.stats[vocation] }) : fillTemplate(content.power, { power: card.power }); return
  • {vocation && } {card.busy && {content.busy}}
    {STAT_IDS.map((stat) => { const label = `${content.stats[stat]} : ${formatDecimal(card.stats[stat])}`; return ; })} {helps.condition && {content.tagCondition}} {helps.dangers.map((danger) => {fillTemplate(content.tagParry, { label: danger.label })})} {helps.affinity && {content.tagAffinity}}
  • ; }