Custom time controls
維護者通常 1 天內回覆
還沒有人認領這個 Issue。
評估
- 難度
- 4/5
- 預估耗時
- 3-5 天
- 新手友好度
- 56/100
- Issue 類型
- 功能
- 描述清晰度
- 基本清楚
- 活躍度
- 活躍
- 技術堆疊
- javascript
研究方向
Start with js/config.js and index.html to see how the existing presets populate #clock-select, then follow the selection handling in js/main.js and clock startup in js/clock.js. Read tests/unit/clock.test.js and run npm ci && npm test to understand current validation. Done when custom controls persist across reloads, invalid values cannot start the clock, and the tests cover the new behavior; bounds and PGN formatting still need decisions.
由索引模型根據 Issue 內容生成。
描述
Summary
The clock offers only five fixed presets (1+0, 3+2, 5+0, 10+0, 15+10). Common controls such as 3+0, 5+3 or 30+0, and odds games, cannot be chosen.
Where
js/config.js:18-25(TIME_CONTROLS)index.html:166(#clock-select)
Proposal
Add a "Custom..." option to #clock-select that shows two number inputs (minutes, increment seconds), validated and stored as custom:M+I in the time-control setting. Optionally, a per-side minutes field for odds games.
Who benefits
Players who want a longer game, or an odds game against a stronger friend.
Open questions
- Bounds (e.g. 1 to 180 minutes, 0 to 60 seconds increment).
- How a custom control is written to the PGN
TimeControltag.
Acceptance criteria
- A custom control is kept across reloads and validated by
validateSavedGame - Invalid input cannot start a clock
- Tests in
tests/unit/clock.test.js
Getting started
- Relevant files:
js/config.js,js/main.js,js/clock.js,index.html - How to run tests:
npm ci && npm test
Filed by repo-audit/full-audit at 73cd279. Severity: low. Effort: M. audit-key: enhancement|js/config.js|TIME_CONTROLS
- 主要語言
- JavaScript
- 星號
- 4
- 分支
- 2
- 平均合併
- 22 小時 16 分鐘
- 30 天內合併 PR
- 9
環境準備
- 沒有 Dockerfile 或 Docker Compose 檔案
- 有 Pull Request 範本
- 閱讀貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
TMHSDigital/Static_Chess 的其他 Issue
-
enhancement help wanted severity: low
難度 4/5 3-5 天 新手友好度 55/100
TMHSDigital/Static_Chess#184 ·
維護者通常 1 天內回覆
-
enhancement help wanted severity: low
難度 4/5 3-5 天 新手友好度 58/100
TMHSDigital/Static_Chess#182 ·
維護者通常 1 天內回覆
-
help wanted severity: medium tech-debt
難度 4/5 3-5 天 新手友好度 45/100
TMHSDigital/Static_Chess#173 ·
維護者通常 1 天內回覆
-
severity: medium tech-debt
難度 5/5 一週以上 新手友好度 35/100
TMHSDigital/Static_Chess#171 ·
維護者通常 1 天內回覆
-
help wanted performance severity: medium
難度 5/5 一週以上 新手友好度 38/100
TMHSDigital/Static_Chess#168 · 1 則留言 ·
維護者通常 1 天內回覆
查看 TMHSDigital/Static_Chess 的全部 Issue
相似的 Issue
-
priority: low server testing
難度 1/5 1 小時以內 新手友好度 88/100
blamechris/chroxy#9277 ·
維護者通常 1 天內回覆
-
[MCP]: page snapshots in .playwright-mcp/ are not git-ignored (.playwright-cli/ is, since #42318)未關閉
難度 2/5 1-3 小時 新手友好度 62/100
microsoft/playwright#44289 ·
維護者通常 1 天內回覆
-
Bug
難度 2/5 1-3 小時 新手友好度 75/100
Ionaru/easy-markdown-editor#657 ·
-
難度 2/5 1-3 小時 新手友好度 66/100
TMHSDigital/Free-Game-Dev-Assets#320 ·
維護者通常 1 天內回覆
-
area:webapp bug finding
難度 2/5 1-3 小時 新手友好度 72/100
維護者通常 1 天內回覆