e32823d389
Project CI / AI game creator shell Rust lane 1/2 (pull_request) Successful in 6m35s
Project CI / AI game creator shell Rust lane 2/2 (pull_request) Successful in 5m10s
Project CI / AI game creator shell Rust crates (pull_request) Successful in 4m29s
Project CI / Frontend tests (pull_request) Failing after 55s
Project CI / Backend tests (pull_request) Successful in 8m13s
Project CI / AI game creator shell web tests (pull_request) Successful in 5m37s
Project CI / Repository checks (pull_request) Successful in 7m5s
Project CI / Native shell tests (pull_request) Successful in 9m2s
新增创作者公开主页、第四导航入口、详情作者跳转及关注按钮 实现关注与粉丝列表、取消后重新关注、回关及移除粉丝交互 新增私有关注关系表、类型契约、受信过程和站内查询写入接口 按作者过滤公开游戏并保持既有四十八项读取边界 复用共享用户行、关注按钮及游戏卡,接入移动布局和页面深链 补充定向测试、隔离数据库及浏览器验收脚本并归并工程验证文档
39 lines
1.1 KiB
TypeScript
39 lines
1.1 KiB
TypeScript
import './style.css';
|
|
|
|
import type { ReactNode } from 'react';
|
|
|
|
import type { GameDistributionGame } from '../../contracts/gameDistribution';
|
|
import { GameRatingSummaryText } from '../GameRatingSummaryText';
|
|
export function GameCard({
|
|
game,
|
|
cover,
|
|
onOpen,
|
|
}: {
|
|
game: GameDistributionGame;
|
|
cover: ReactNode;
|
|
onOpen: () => void;
|
|
}) {
|
|
return (
|
|
<button type="button" className="game-card" onClick={onOpen}>
|
|
{cover}
|
|
<span className="game-card__body">
|
|
<span className="game-card__title-row">
|
|
<strong>{game.title}</strong>
|
|
<span className="game-card__play-count">
|
|
{game.playCount.toLocaleString()} 次游玩
|
|
</span>
|
|
</span>
|
|
<span className="game-card__summary">{game.summary}</span>
|
|
<span className="game-card__rating">
|
|
<GameRatingSummaryText summary={game.ratingSummary} />
|
|
</span>
|
|
<span className="game-card__meta">
|
|
<span>{game.category}</span>
|
|
<span>·</span>
|
|
<span>{game.author.name}</span>
|
|
</span>
|
|
</span>
|
|
</button>
|
|
);
|
|
}
|