fix(character-dictionary): source name parts from alias, not blank nativ

- test: exercise the case where nativeName is empty and parts must come from alternativeNames' space split instead
This commit is contained in:
2026-08-04 17:58:39 -07:00
parent d878d8bf4f
commit 3c24597724
@@ -56,12 +56,15 @@ test('buildNameTerms drops the disambiguator letter of a mob character name', ()
});
test('buildNameTerms keeps a single-kanji name part', () => {
// The name is an alias, not the native name, so the parts come from the
// space split rather than from the native-name split.
const terms = buildNameTerms(
characterRecord({
firstNameHint: 'Sora',
lastNameHint: 'Yamada',
fullName: 'Sora Yamada',
nativeName: '山田 空',
nativeName: '',
alternativeNames: ['山田 空'],
}),
);