feat(web): refresh the app with Astryx and coral branding

This commit is contained in:
dahyeon committed 2026-11-10 13:35:11 +09:00
1 parent f649490cd2
commit da7b502936
140 files changed
+4531 -2368

No files matched your search

+33 -39
View File
@@ -16,6 +16,8 @@ import {
import type { MatchMutationRequest } from '../../api/types';
import { DEFAULT_COMMUNITY_ID } from '../../config';
import { Btn } from "../../ui/Btn";
import { AdminNotice, AdminPage } from '../../components/AdminPage';
const DEFAULT_FORM: MatchMutationRequest = {
title: '',
description: '',
@@ -246,30 +248,24 @@ export default function MatchAdminPage() {
if (!canManage && !meQuery.isPending) {
return (
<main className="max-w-5xl mx-auto px-4 py-20 text-center">
<h1 className="text-lg font-bold">권한이 필요합니다</h1>
<AdminNotice title="권한이 필요합니다">
<p className="mt-2 text-sm text-base-content/40">
내전 관리는 owner/admin만 사용할 수 있습니다.
</p>
</main>
</AdminNotice>
);
}
return (
<main className="max-w-6xl mx-auto px-4 sm:px-6 py-6">
<Link to="/" className="inline-flex text-xs text-base-content/40 hover:text-base-content mb-5">
← 목록으로
</Link>
<div className="mb-6 flex flex-col sm:flex-row sm:items-end sm:justify-between gap-3">
<div>
<h1 className="text-2xl font-black text-base-content">내전 관리</h1>
<p className="mt-1 text-sm text-base-content/45">
내전 생성, 모집 정원, 게임 모드와 공지 내용을 관리합니다.
</p>
</div>
<button type="button" className="btn btn-primary btn-sm px-5 text-xs" onClick={openCreate}>
<AdminPage
communityId={communityId}
title="내전 관리"
description="내전 생성, 모집 정원, 게임 모드와 공지 내용을 관리합니다."
>
<div className="mb-4 flex flex-wrap items-center justify-end gap-2">
<Btn variant="primary" onClick={openCreate}>
새 내전 만들기
</button>
</Btn>
</div>
{message && (
@@ -301,7 +297,7 @@ export default function MatchAdminPage() {
required
value={form.title}
onChange={(event) => setForm((current) => ({ ...current, title: event.target.value }))}
className="mt-1 w-full border border-base-content/10 bg-transparent px-3 py-2 text-sm"
className="lts-input mt-1 w-full"
/>
</label>
<label className="text-xs text-base-content/45 md:col-span-2">
@@ -311,7 +307,7 @@ export default function MatchAdminPage() {
value={form.description}
onChange={(event) => setForm((current) => ({ ...current, description: event.target.value }))}
rows={3}
className="mt-1 w-full border border-base-content/10 bg-transparent px-3 py-2 text-sm"
className="lts-textarea mt-1 w-full"
/>
</label>
<label className="text-xs text-base-content/45">
@@ -322,7 +318,7 @@ export default function MatchAdminPage() {
type="datetime-local"
value={form.scheduledAt}
onChange={(event) => setForm((current) => ({ ...current, scheduledAt: event.target.value }))}
className="mt-1 w-full border border-base-content/10 bg-transparent px-3 py-2 text-sm"
className="lts-input mt-1 w-full"
/>
</label>
<label className="text-xs text-base-content/45">
@@ -340,7 +336,7 @@ export default function MatchAdminPage() {
),
}));
}}
className="mt-1 w-full border border-base-content/10 bg-transparent px-3 py-2 text-sm"
className="lts-select mt-1 w-full"
>
{(form.gameMode === 'double-elimination'
? [20, 40]
@@ -358,7 +354,7 @@ export default function MatchAdminPage() {
step={form.gameMode === 'double-elimination' ? 2 : 1}
value={form.gameCount}
onChange={(event) => setForm((current) => ({ ...current, gameCount: Number(event.target.value) }))}
className="mt-1 w-full border border-base-content/10 bg-transparent px-3 py-2 text-sm"
className="lts-input mt-1 w-full"
/>
{form.gameMode === 'double-elimination' && (
<span className="mt-1 block text-xs text-base-content/30">
@@ -388,13 +384,13 @@ export default function MatchAdminPage() {
: current.gameCount,
}));
}}
className="mt-1 w-full border border-base-content/10 bg-transparent px-3 py-2 text-sm"
className="lts-select mt-1 w-full"
>
{Object.entries(GAME_MODE_LABEL).map(([value, label]) => (
<option key={value} value={value}>{label}</option>
))}
</select>
<span className="mt-1 block text-xs text-amber-500/80">
<span className="mt-1 block text-xs text-gold">
현재 경매/코드 연결은 페어 방식 기준으로 동작합니다.
</span>
</label>
@@ -417,7 +413,7 @@ export default function MatchAdminPage() {
: Number(event.target.value),
}))
}
className="mt-1 w-full border border-base-content/10 bg-transparent px-3 py-2 text-sm"
className="lts-input mt-1 w-full"
/>
<span className="mt-1 block text-xs text-base-content/30">
비워두면 전체 {roundRobinFullRoundCount}라운드로 생성됩니다.
@@ -446,7 +442,7 @@ export default function MatchAdminPage() {
value={form.prizesText}
onChange={(event) => setForm((current) => ({ ...current, prizesText: event.target.value }))}
rows={4}
className="mt-1 w-full border border-base-content/10 bg-transparent px-3 py-2 text-sm"
className="lts-textarea mt-1 w-full"
/>
</label>
<label className="text-xs text-base-content/45">
@@ -455,7 +451,7 @@ export default function MatchAdminPage() {
value={form.noticesText}
onChange={(event) => setForm((current) => ({ ...current, noticesText: event.target.value }))}
rows={4}
className="mt-1 w-full border border-base-content/10 bg-transparent px-3 py-2 text-sm"
className="lts-textarea mt-1 w-full"
/>
</label>
<label className="text-xs text-base-content/45 md:col-span-2">
@@ -465,34 +461,32 @@ export default function MatchAdminPage() {
onChange={(event) => setForm((current) => ({ ...current, scheduleText: event.target.value }))}
rows={3}
placeholder="20:50|로비 오픈"
className="mt-1 w-full border border-base-content/10 bg-transparent px-3 py-2 text-sm font-mono"
className="lts-textarea mt-1 w-full font-mono"
/>
</label>
</div>
<div className="mt-4 flex gap-2">
<button
type="button"
className="btn btn-primary btn-sm px-5 text-xs"
<Btn
variant="primary"
disabled={createMutation.isPending || updateMutation.isPending}
onClick={submit}
>
{editing ? '수정 저장' : '생성'}
</button>
<button
type="button"
className="btn btn-ghost btn-sm px-5 text-xs"
</Btn>
<Btn
variant="ghost"
onClick={() => setShowForm(false)}
>
취소
</button>
</Btn>
</div>
</section>
)}
<section className="border border-base-content/10 bg-base-100 overflow-hidden">
<section className="lts-panel overflow-hidden">
<div className="overflow-x-auto">
<table className="w-full min-w-[900px] text-left">
<table className="lts-table min-w-[900px]">
<thead>
<tr className="bg-base-200/40 border-b border-base-content/10 text-xs uppercase tracking-wider text-base-content/35">
<th className="px-3 py-2">시간</th>
@@ -549,7 +543,7 @@ export default function MatchAdminPage() {
</button>
<button
type="button"
className="text-xs px-2 py-1 border border-red-500/20 text-red-400 hover:bg-red-500/10"
className="text-xs px-2 py-1 border border-loss-line text-loss hover:bg-loss-tint"
disabled={
deleteMutation.isPending ||
match.status !== 'recruiting'
@@ -585,6 +579,6 @@ export default function MatchAdminPage() {
</table>
</div>
</section>
</main>
</AdminPage>
);
}