mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-05 19:04:02 +00:00
fix(hud): catch the UNAVAILABLE word flush against Han and keep multi-word names whole
Han and kana have no word edges, so a CJK forbidden word now counts anywhere
in the reply. The proxy no longer counts words: the model reads Rue de Rivoli
as one, so only the 80-character word-boundary cap remains.
Also restore src/voice/gevActions.test.mjs, reformatted by mistake in 818d2c82.
This commit is contained in:
1 parent
818d2c8295
commit
645e13aeaa
5 files changed
+645
-2164
No files matched your search
@@ -258,6 +258,22 @@ test('with every feed healthy a reply calling one unavailable falls back', async
|
||||
assert.equal(shown(), hud._composeSummary());
|
||||
});
|
||||
|
||||
for (const [locale, place, summary] of [
|
||||
['zh-CN', '北京', '北京航班不可用'],
|
||||
['zh-Hant', '北京', '北京航班不可用'],
|
||||
['ja', '東京', '東京航空便利用不可'],
|
||||
]) {
|
||||
test(`a ${locale} reply calling a feed unavailable flush against Han falls back`, async (t) => {
|
||||
const { hud, shown } = createHud(
|
||||
t,
|
||||
{ summary, feedState: null },
|
||||
{ locale, places: [place], layers: () => [] },
|
||||
);
|
||||
await hud._updateSummary(false, true);
|
||||
assert.equal(shown(), hud._composeSummary());
|
||||
});
|
||||
}
|
||||
|
||||
test('an ar reply opening with a Latin name keeps reading right to left', async (t) => {
|
||||
const { hud, shown } = createHud(
|
||||
t,
|
||||
|
||||
Reference in new issue
Block a user