- 보석 상인 → 스플렌더, 벽 쌓기 길찾기 → 쿼리도, 숫자 타일 → 루미큐브, 주사위 땅따먹기 → 부루마불 - deploy/docker-compose.proxy.yml: Caddy 없이 앱만(.5:2970), HTTPS·헤더는 NPMplus - deploy/npmplus-advanced.conf: Caddyfile과 같은 보안 헤더 - 문서: 2026-10-06 결정, 배포 7절 (e2e 구십구 0 카드 방향 버튼 반영 포함) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
102 lines
4.3 KiB
TypeScript
102 lines
4.3 KiB
TypeScript
/** 루미큐브 30초 규칙 요약 (docs/07 §5). Tiles are redrawn here as simple SVG (the screen's Tile lives in index.tsx). */
|
|
import type { ReactNode } from 'react';
|
|
import type { QuickCard } from '../types';
|
|
|
|
type C = 'K' | 'R' | 'B' | 'O' | 'J';
|
|
const INK: Record<C, string> = { K: '#111827', R: '#c62828', B: '#1d4ed8', O: '#a14a00', J: '#111827' };
|
|
const MARK: Record<C, string> = { K: '●', R: '♥', B: '◆', O: '★', J: '' };
|
|
|
|
/** One tile at (x, y), 28 x 40. `n` 0 = joker. */
|
|
function T({ x, y, c, n, fresh }: { x: number; y: number; c: C; n: number; fresh?: boolean }) {
|
|
return (
|
|
<g transform={`translate(${x} ${y})`}>
|
|
<rect width={28} height={40} rx={5} fill="#fffdf7" stroke={fresh ? '#7c3aed' : '#c9b98f'} strokeWidth={fresh ? 2.5 : 1} />
|
|
{c === 'J' ? (
|
|
<g transform="translate(14 18)">
|
|
<path d="M0 0 L0 -10 A10 10 0 0 1 10 0 Z" fill="#c62828" />
|
|
<path d="M0 0 L10 0 A10 10 0 0 1 0 10 Z" fill="#1d4ed8" />
|
|
<path d="M0 0 L0 10 A10 10 0 0 1 -10 0 Z" fill="#a14a00" />
|
|
<path d="M0 0 L-10 0 A10 10 0 0 1 0 -10 Z" fill="#111827" />
|
|
<circle r={5} fill="#fffdf7" />
|
|
<text y={3} textAnchor="middle" fontSize={7} fontWeight={900} fill="#111827">
|
|
J
|
|
</text>
|
|
</g>
|
|
) : (
|
|
<>
|
|
<text x={14} y={22} textAnchor="middle" fontSize={17} fontWeight={900} fill={INK[c]}>
|
|
{n}
|
|
</text>
|
|
<text x={14} y={35} textAnchor="middle" fontSize={8} fill={INK[c]}>
|
|
{MARK[c]}
|
|
</text>
|
|
</>
|
|
)}
|
|
</g>
|
|
);
|
|
}
|
|
|
|
/** A row of tiles starting at x; returns the tiles for one set (gap 2). */
|
|
const row = (x: number, y: number, tiles: [C, number][], fresh: number[] = []) =>
|
|
tiles.map(([c, n], i) => <T key={`${x}-${y}-${i}`} x={x + i * 30} y={y} c={c} n={n} fresh={fresh.includes(i)} />);
|
|
|
|
function Felt({ children, h = 150 }: { children: ReactNode; h?: number }) {
|
|
return (
|
|
<svg viewBox={`0 0 250 ${h}`} width={250} height={h} aria-hidden>
|
|
<rect width={250} height={h} rx={12} fill="#1f6f4a" />
|
|
{children}
|
|
</svg>
|
|
);
|
|
}
|
|
|
|
const label = (x: number, y: number, s: string) => (
|
|
<text x={x} y={y} textAnchor="middle" fontSize={12} fontWeight={800} fill="#fff">
|
|
{s}
|
|
</text>
|
|
);
|
|
|
|
export const quickStart: QuickCard[] = [
|
|
{
|
|
pic: (
|
|
<Felt>
|
|
{label(48, 22, '같은 숫자')}
|
|
{row(5, 30, [['K', 7], ['R', 7], ['B', 7]])}
|
|
{label(185, 22, '이어진 숫자')}
|
|
{row(126, 30, [['B', 3], ['B', 4], ['B', 5], ['B', 6]])}
|
|
<rect x={20} y={88} width={210} height={52} rx={8} fill="#b07a3c" />
|
|
{row(35, 94, [['O', 2], ['K', 9], ['R', 12], ['J', 0], ['B', 1], ['O', 13]])}
|
|
</Felt>
|
|
),
|
|
alt: '바닥에 같은 숫자 7 세 장과 파란 3·4·5·6이 놓여 있고, 아래 받침대에 내 타일이 있어요',
|
|
title: '묶음을 만들어 내요',
|
|
text: '같은 숫자 다른 색 3~4장, 또는 같은 색 이어진 숫자 3장 이상을 바닥에 내요. 낼 게 없으면 한 장 가져와요.',
|
|
},
|
|
{
|
|
pic: (
|
|
<Felt h={130}>
|
|
{row(80, 22, [['R', 10], ['R', 11], ['R', 12]])}
|
|
{label(125, 88, '10 + 11 + 12 = 33점')}
|
|
{label(125, 110, '첫 등록 30점 넘었어요!')}
|
|
</Felt>
|
|
),
|
|
alt: '빨간 10, 11, 12 타일 세 장, 합이 33점이라 첫 등록 30점을 넘었어요',
|
|
title: '첫 등록은 점수가 필요해요',
|
|
text: '처음 낼 때는 내 타일만으로 만든 묶음의 숫자 합이 방에서 정한 점수(보통 30점) 이상이어야 해요.',
|
|
},
|
|
{
|
|
pic: (
|
|
<Felt h={150}>
|
|
{row(50, 10, [['R', 4], ['R', 5], ['R', 6], ['R', 7], ['R', 8]])}
|
|
<text x={125} y={72} textAnchor="middle" fontSize={13} fontWeight={800} fill="#fde047">
|
|
▼ 내 빨강 6을 넣어 나눠요
|
|
</text>
|
|
{row(10, 90, [['R', 4], ['R', 5], ['R', 6]], [2])}
|
|
{row(150, 90, [['R', 6], ['R', 7], ['R', 8]])}
|
|
</Felt>
|
|
),
|
|
alt: '빨간 4부터 8까지 묶음에 내 빨강 6을 넣어 4·5·6과 6·7·8 두 묶음으로 나눈 모습',
|
|
title: '바닥을 고쳐서 끼워요',
|
|
text: '첫 등록 뒤에는 바닥 묶음을 쪼개고 합쳐 내 타일을 끼울 수 있어요. 조커는 아무 타일이나 대신해요. 받침대를 먼저 비우면 이겨요.',
|
|
},
|
|
];
|