import { formatCoin, formatPercent } from "../utils/format.js";
import { FourMetricRow } from "./MiniStat.jsx";
import { Panel } from "./Panel.jsx";
export function GameEconomyPanel({ gameMetrics, gameRanking }) {
return (
);
}
function GameRankTable({ items }) {
const max = Math.max(...items.map((item) => item.turnover_coin), 1);
const total = items.reduce((sum, item) => sum + item.turnover_coin, 0) || 1;
return (
游戏流水排行
流水 (USD)
占比
{items.map((item, index) => (
{index + 1}
{item.game_id || "-"}
{formatCoin(item.turnover_coin)}
{formatPercent(item.turnover_coin / total)}
))}
);
}