feat(ui): Erudit blank tiles carry the star (✻) mark
CI / changes (pull_request) Successful in 2s
CI / unit (pull_request) Has been skipped
CI / integration (pull_request) Has been skipped
CI / ui (pull_request) Successful in 54s
CI / gate (pull_request) Successful in 0s
CI / deploy (pull_request) Successful in 1m17s
CI / changes (pull_request) Successful in 2s
CI / unit (pull_request) Has been skipped
CI / integration (pull_request) Has been skipped
CI / ui (pull_request) Successful in 54s
CI / gate (pull_request) Successful in 0s
CI / deploy (pull_request) Successful in 1m17s
The Erudit variant's blank is the "звёздочка", so render it with a star. An empty rack blank (and its drag ghost) shows ✻ centred; a placed blank keeps its designated letter and carries ✻ where the (absent) point value sits — on the board and in the Stats best-move tiles. The Scrabble variants are unchanged. Gated by usesStarBlank() in lib/variants.ts.
This commit is contained in:
@@ -5,6 +5,8 @@ import {
|
||||
availableVariants,
|
||||
supportsMultipleWordsToggle,
|
||||
multipleWordsForRequest,
|
||||
usesStarBlank,
|
||||
BLANK_STAR,
|
||||
} from './variants';
|
||||
|
||||
describe('ALL_VARIANTS', () => {
|
||||
@@ -53,3 +55,16 @@ describe('multipleWordsForRequest', () => {
|
||||
expect(multipleWordsForRequest('scrabble_en', true)).toBe(true);
|
||||
});
|
||||
});
|
||||
|
||||
describe('usesStarBlank', () => {
|
||||
it('marks the blank with a star for Erudit only', () => {
|
||||
expect(usesStarBlank('erudit_ru')).toBe(true);
|
||||
expect(usesStarBlank('scrabble_ru')).toBe(false);
|
||||
expect(usesStarBlank('scrabble_en')).toBe(false);
|
||||
});
|
||||
|
||||
it('BLANK_STAR is the heavy teardrop-spoked asterisk (U+273B)', () => {
|
||||
expect(BLANK_STAR).toBe('✻');
|
||||
expect(BLANK_STAR.codePointAt(0)).toBe(0x273b);
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user