제작된 퀴즈 1~3단계: 관리자 → 퀴즈(목록·추가·곡 목록: 서버 DB/유튜브 검색·주소로 추가, 끌어서·▲▼·번호로 순서, 복수정답은 연결된 DB 곡 별칭에도, 영상 바꾸기 / 설정: 설명·공개방식(비공개·일부공개·전체공개)·문제 순서·재생위치 기본·방 규칙). 저장은 버튼·Ctrl+S로만, 안 저장 시 탭 제목·표시·나가기 확인. 곡마다 처음·하이라이트 위치 편집기(영상+큰 재생바, 끌기·지금 위치로·여기서 듣기·±1초, 자동=0초+DB 하이라이트, 연령제한은 받아 둔 음원). 방 설정 '직접 선택 / 제작된 퀴즈'(검색·비공개/일부공개 먼저), 고르면 퀴즈 설정이 방 설정으로, 듣고맞추기·곡 전부, 곡별 위치로 재생, 플레이 수. 퀴즈당 곡 수·계정당 퀴즈 수 제한(사이트 설정, 기본 무제한). '퀴즈 저장·불러오기'는 '진행 저장·불러오기'로 이름 변경

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
EJClaw
2026-10-22 08:36:40 +09:00
parent e3cb623773
commit b56d1a8d0e
29 changed files with 2366 additions and 111 deletions

View File

@@ -49,6 +49,10 @@ export interface RoomConfig {
nextVotes: VoteRule;
count: (typeof COUNTS)[number];
visibility: 'public' | 'private' | 'password';
/** 제작된 퀴즈: the chosen quiz (listen mode only, every song of it); null = 직접 선택 (장르·연도·난이도). */
quizId: number | null;
/** Name of that quiz, filled in by the server for room cards. */
quizName: string;
}
export const DEFAULT_ROOM_CONFIG: RoomConfig = {
@@ -72,6 +76,8 @@ export const DEFAULT_ROOM_CONFIG: RoomConfig = {
nextVotes: '1/3',
count: 30,
visibility: 'public',
quizId: null,
quizName: '',
};
/** Level names (docs/04 난이도). */
@@ -107,6 +113,12 @@ export function listenLabel(s: number): string {
/** One-line summary for room cards (docs/03 열린 방 목록). */
export function configSummary(c: RoomConfig, genreName: (id: string) => string = (x) => x): string[] {
const out: string[] = [];
if (c.quizId) {
out.push(`📋 ${c.quizName || '제작된 퀴즈'}`, `🎧 ${listenLabel(c.listenSec)}${c.startAt === 'highlight' ? ' · 하이라이트' : ''}`);
if (c.answer !== 'title') out.push(c.answer === 'both' ? '제목+가수' : '가수만');
out.push(`공개 ${c.revealSec}초`);
return out;
}
if (c.mode === 'lyrics') out.push(`📜 가사 ${c.lyricsSec ? `${c.lyricsSec}초` : '무제한'}`);
else out.push(`${c.mode === 'artist' ? '🎤' : '🎧'} ${listenLabel(c.listenSec)}${c.startAt === 'highlight' ? ' · 하이라이트' : ''}`);
out.push(c.yearFrom || c.yearTo ? `${c.yearFrom ?? '처음'}~${c.yearTo ?? '지금'}` : '전체 연도');