feat(variants): default a registered account to Erudit + Russian Scrabble
CI / changes (pull_request) Successful in 3s
CI / unit (pull_request) Successful in 11s
CI / integration (pull_request) Successful in 22s
CI / ui (pull_request) Successful in 1m16s
CI / conformance (pull_request) Successful in 10s
CI / gate (pull_request) Successful in 0s
CI / deploy (pull_request) Successful in 1m53s

New Game opened on a single variant for everyone, which reads poorly on VK
where Russian Scrabble is the familiar game. A registered account now starts
with both Russian-alphabet games, so the picker offers a real choice with no
pre-selection.

A guest stays on Erudit alone and is invited to register for the rest: the
device-local guest has no profile at all, so the client-side fallback has to
keep matching the server. Registering promotes the set, but only while the
guest still carries the untouched guest default. Existing accounts are not
backfilled — the set they carry may be a deliberate choice.

The Telegram promo start-param becomes additive rather than a replacement,
with English Scrabble withheld from a Russian-speaking arrival; otherwise the
English campaign link would have taken Russian Scrabble away from every
account it onboarded.
This commit is contained in:
Ilia Denisov
2026-07-27 20:38:09 +02:00
parent 69b1a50644
commit b6d88da78c
19 changed files with 338 additions and 56 deletions
+13
View File
@@ -4,6 +4,7 @@ import {
ALL_VARIANTS,
DEFAULT_VARIANTS,
availableVariants,
showRegisterHint,
supportsMultipleWordsToggle,
multipleWordsForRequest,
usesStarBlank,
@@ -38,6 +39,18 @@ describe('availableVariants', () => {
});
});
describe('showRegisterHint', () => {
it('invites only an online guest holding a single variant', () => {
expect(showRegisterHint(true, 1, false)).toBe(true);
});
it('stays hidden for a registered player, offline, or when several variants are offered', () => {
expect(showRegisterHint(false, 1, false)).toBe(false);
expect(showRegisterHint(true, 1, true)).toBe(false);
expect(showRegisterHint(true, 2, false)).toBe(false);
});
});
describe('supportsMultipleWordsToggle', () => {
it('is true for Russian variants only', () => {
expect(supportsMultipleWordsToggle('scrabble_ru')).toBe(true);