games: add a shared catalogue and session lifecycle

未關閉
#58 0 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視

維護者通常 1 天內回覆

還沒有人認領這個 Issue。

評估

難度
5/5
預估耗時
一週以上
新手友好度
35/100
Issue 類型
功能
描述清晰度
基本清楚
活躍度
活躍

研究方向

Start by reading the existing Pattern Sprint and Digit Recall implementations under src/app/games/, then inspect the related work in #24. Map their routes and behavior against the proposed src/features/games/ boundary and identify the relevant checks for lifecycle, deterministic generation, and keyboard and mobile use. Done means both games use the shared catalogue and lifecycle, retain their URLs and behavior, and have the contributor guide and coverage described in the issue.

由索引模型根據 Issue 內容生成。

描述

enhancement games help wanted

Part of #24. Build this before the new game implementations.

Student problem

Every placement game needs clear instructions, predictable controls, timing and useful results. Separate implementations make the experience inconsistent and make new games harder to contribute.

Scope

  • Add a documented src/features/games/ boundary: pure rules and generators separate from React, browser storage, authentication and payments. Keep src/app/games/ routes thin.
  • Define a typed catalogue with stable game ID, skill, original instructions, difficulty options, supported modes and rules version.
  • Share the lifecycle: instructions, running, feedback/results and restart. Define a result contract for history and mixed sessions; scoring remains explicit per game.
  • Support untimed learning and clearly labelled timed practice where appropriate. Start only after an explicit action; use an injected clock/random source and document deadline/background-tab behavior.
  • Move Pattern Sprint and Digit Recall onto these boundaries, preserving their URLs and existing behavior.
  • Keep practice free, available without login or backend configuration, usable by keyboard and touch, and respectful of reduced motion. Do not rely on color alone.
  • Use original code, puzzle content and assets. State that exercises are independent practice rather than official employer assessments.

Done when

  • Tests cover start, completion, timeout, restart, duplicate input and deterministic generation.
  • Browser checks complete both existing games on desktop/mobile and exercise keyboard controls.
  • A contributor guide explains how to register a game, define its rules/scoring and run relevant checks.

Saved history, cloud synchronization, billing and leaderboards are separate work.

主要語言
TypeScript
星號
1
分支
1
平均合併
8 小時 58 分鐘
30 天內合併 PR
37

環境準備

從這裡開始

  1. 先讀完整個 Issue,再讀專案的貢獻指南。
  2. 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
  3. Fork 儲存庫,在一個分支上完成修改。
  4. 送出 Pull Request,並在描述裡引用這個 Issue 編號。

procoderji-com/procoderji 的其他 Issue

查看 procoderji-com/procoderji 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。