Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Multiple free-space tiles can render an incomplete card

オープン
#13 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
68/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
活発
技術スタック
typescript
領域
full-stack

調査の方向性

src/lib/bingo.ts と src/lib/server/cardShuffle.ts にある effectivePoolSize、getCardSize、pickCardWithFreeSpace の処理の流れから始め、その後、影響を受ける bingo および tile-admin の server ルートを調べます。2 つの free-space タイルを含む 25 タイルのプールを再現し、raw と effective のカウントを比較します。無効な設定が防止または正規化され、/bingo が 25 セル未満をレンダリングしなくなれば完了です。

索引モデルが issue の本文から書いたものです。

説明

Problem

The admin UI permits multiple isFreeSpace tiles. effectivePoolSize subtracts every free space after the first, but getCardSize still returns the minimum size of 5. pickCardWithFreeSpace then drops all but one free-space tile and can return fewer than 25 cells. tooFewTiles uses the raw tile count, so it does not prevent rendering.

Reproduction

  1. Create a 25-tile pool with two tiles marked Free.
  2. Open /bingo.

The effective pool is 24, the selected card has 23 regular tiles plus one centered free space (24 total), and the UI renders only 24 cells in a 5-column grid. The core calculation reproduces as { effectivePoolSize: 24, cardSize: 5, renderedTiles: 24 }.

Suggested fix

Validate or enforce exactly zero or one free-space tile, or base the availability check on the effective pool and require cardSize ** 2 selected tiles before showing the board. The tile admin should prevent the invalid configuration or clearly normalize extra free spaces.

Affected code

  • src/lib/bingo.ts
  • src/lib/server/cardShuffle.ts
  • src/routes/bingo/+page.server.ts
  • src/routes/admin/tiles/+page.server.ts
主要言語
TypeScript
スター
0
フォーク
0
PR マージ指標
30日以内にマージされた PR はありません

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

hacksu/bingo のほかの issue

hacksu/bingo の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。