feat(ui): drop the one-word status-bar badge
CI / changes (pull_request) Successful in 2s
CI / unit (pull_request) Successful in 10s
CI / integration (pull_request) Successful in 17s
CI / ui (pull_request) Successful in 57s
CI / conformance (pull_request) Successful in 9s
CI / gate (pull_request) Successful in 0s
CI / deploy (pull_request) Successful in 1m19s
CI / changes (pull_request) Successful in 2s
CI / unit (pull_request) Successful in 10s
CI / integration (pull_request) Successful in 17s
CI / ui (pull_request) Successful in 57s
CI / conformance (pull_request) Successful in 9s
CI / gate (pull_request) Successful in 0s
CI / deploy (pull_request) Successful in 1m19s
The small 1️⃣ in the status bar's score-preview slot read as noise; the
single-word rule keeps its spelled-out label in the history header and
the lobby invitation card.
This commit is contained in:
+1
-2
@@ -214,8 +214,7 @@ e2e and the screenshots.
|
||||
**Drop game** (or 📤 **Export GCG** on a finished game) at the left and the comms 💬
|
||||
(badged with unread chat) at the right, icon-only. A **single-word-rule** game (a Russian
|
||||
game with "multiple words per turn" off) centres a **"One word per turn"** label between
|
||||
those two icons, and the status bar shows a small **1️⃣** in the score-preview slot that
|
||||
yields to the live word/score preview while tiles are pending; standard games show neither. Each **opponent**'s card also gains two
|
||||
those two icons; standard games show no label. Each **opponent**'s card also gains two
|
||||
edge-pinned controls (non-guests): a 🤝 **add-friend** on the right (hidden once a friend,
|
||||
disabled once requested) and a ✖️ **block** on the left. Each confirms via the fading-✅ tap,
|
||||
swapping the card's score for "Add friend?" — or **"Block?" in the danger colour** — while
|
||||
|
||||
+4
-4
@@ -90,16 +90,16 @@ test('new game: auto-match shows the off-by-default rule toggle from the start (
|
||||
await expect(toggle).not.toBeChecked();
|
||||
});
|
||||
|
||||
test('single-word game shows the one-word indicator in the status bar and the history header', async ({ page }) => {
|
||||
test('single-word game shows the one-word rule label in the history header', async ({ page }) => {
|
||||
await page.goto('/');
|
||||
await page.getByRole('button', { name: /guest/i }).click();
|
||||
// g3 is a finished Russian single-word game (vs Rick); open it from the lobby.
|
||||
await page.getByRole('button', { name: /Rick/ }).click();
|
||||
await expect(page.locator('[data-cell]').first()).toBeVisible();
|
||||
await expect(page.locator('.pane')).toHaveCount(1);
|
||||
// The status bar carries the small "1️⃣" indicator (single-word, nothing pending).
|
||||
await expect(page.locator('.oneword')).toBeVisible();
|
||||
// Tapping the scoreboard opens the history, whose header shows the spelled-out rule label.
|
||||
// The status bar no longer carries a "1️⃣" badge (dropped as noise); the rule surfaces in the
|
||||
// history header instead. Tapping the scoreboard opens the history with the spelled-out label.
|
||||
await expect(page.locator('.oneword')).toHaveCount(0);
|
||||
await page.locator('.scoreboard').click();
|
||||
await expect(page.locator('.oneword-label')).toBeVisible();
|
||||
});
|
||||
|
||||
@@ -1354,7 +1354,7 @@
|
||||
<span class="turn-ind">{isMyTurn ? t('game.yourTurn') : turnLabel()}</span>
|
||||
{/if}
|
||||
<span class="scores">
|
||||
{#if recallOverRack}{:else if preview}{preview.legal ? t('game.previewWords', { words: preview.words.join(', '), n: preview.score }) : t('game.previewIllegal')}{:else if !view.game.multipleWordsPerTurn}<span class="oneword" title={t('game.oneWordRule')}>1️⃣</span>{/if}
|
||||
{#if recallOverRack}{:else if preview}{preview.legal ? t('game.previewWords', { words: preview.words.join(', '), n: preview.score }) : t('game.previewIllegal')}{/if}
|
||||
</span>
|
||||
</div>
|
||||
{/if}
|
||||
@@ -1609,9 +1609,6 @@
|
||||
min-width: 64px;
|
||||
text-align: right;
|
||||
}
|
||||
.oneword {
|
||||
font-size: 0.95rem;
|
||||
}
|
||||
/* The single-word-rule label centred in the history header between its two icons. */
|
||||
.oneword-label {
|
||||
flex: 1;
|
||||
|
||||
Reference in New Issue
Block a user