Use real assets.

This commit is contained in:
Greyson Parrelli
2026-07-25 18:42:20 -04:00
parent 3598180ff1
commit e6c895d6b4
146 changed files with 205 additions and 70 deletions
+6 -2
View File
@@ -1,7 +1,7 @@
import { useLayoutEffect, useRef, useState } from 'react'
import { createPortal } from 'react-dom'
import type { Card } from '../types'
import { artFor } from '../petArt'
import { artFor, artUrlFor } from '../petArt'
// The suit's "hat" — the trade-in symbol printed on the real cards, tinted to
// the suit's colour. Drawn as a tiny sun-hat SVG so it scales crisply.
@@ -272,7 +272,11 @@ export function CardView({
)}
{damage > 0 && !dead && <span className="card-damage">{damage}</span>}
<div className="card-art" aria-hidden>
{artFor(card.name)}
{artUrlFor(card.name) ? (
<img className="card-art-img" src={artUrlFor(card.name)!} alt="" draggable={false} />
) : (
artFor(card.name)
)}
</div>
</div>
{/* Lower panel: the suit hat, name, and tier die on one row, the ability