ロイヤリティ要約カードLoyaltySummaryCardExperimental

The points/balance/tier hero every consumer loyalty screen opens with: a prominent balance, a tier/rank badge, optional secondary values (IC残高/当年実績), a higher-is-better progress-to-next-tier with a remaining label (『プラチナまであと ¥13,800』 — never auto-reds like a capacity Meter), an expiry-warning slot and a primary action. The brand tone is a filled gradient surface so the hero has shine without reaching for arbitrary brand-token classes. For airline マイル, 鉄道 IC/ポイント, retail/EC rewards, membership tiers. For the back-office KPI strip use StatGroup; for a money breakdown use AmountBreakdown; for the points/coupon/history list under the hero use ListCard. Presentational (the action slot owns interactivity) — RSC-safe.

プレビュー

ハッピーズドラッグ メンバーズ
ゴールド会員
ポイント残高
3,480P
今月の獲得
+312 P
当年購入額
¥86,200
プラチナ会員まで あと ¥13,800¥86,200 / ¥100,000
200 P が 2026/06/30 に失効予定です

Props

表は横にスクロールできます
プロパティ初期値説明
balanceReactNode-ヒーローの残高(大きな数字)。
balanceLabelReactNode-残高の上の小ラベル(ポイント残高 など)。
unitReactNode-残高の後ろの単位(P / マイル / 円)。
metaReactNode-プログラム名 / 会員名 / 番号(左上)。
tierReactNode-ランクバッジ(右上)。Badge 等を渡す。
secondary{ label, value }[]-ヒーロー下の副次値(IC残高 / 当年実績 など)。
progress{ value, max, label?, caption? }-次ランクまでの進捗(higher-is-better・容量Meterのように赤反転しない)。label は残り(『あと ¥13,800』)。
alertReactNode-失効予定などの警告行。
actionReactNode-主アクション(Button ノード)。
tone"brand" | "default""brand"brand = 塗りつぶしグラデーションのヒーロー、default = 素のカード。

Usage

import { LoyaltySummaryCard, Badge, Button } from "@gunjo/ui"

<LoyaltySummaryCard
  tone="brand"                       // filled gradient hero (or "default" card)
  meta="ハッピーズドラッグ メンバーズ"
  tier={<Badge variant="outline">ゴールド会員</Badge>}
  balanceLabel="ポイント残高"
  balance="3,480"
  unit="P"
  secondary={[{ label: "当年購入額", value: "¥86,200" }]}
  progress={{ value: 86200, max: 100000,
    label: "プラチナ会員まで あと ¥13,800", caption: "¥86,200 / ¥100,000" }}
  alert="200 P が 2026/06/30 に失効予定です"
  action={<Button size="lg" variant="secondary" className="w-full">会員バーコードを表示</Button>}
/>

使用コンポーネント