From 24e7ea1994454842ce4aec19fae2a3e9f40dc516 Mon Sep 17 00:00:00 2001 From: Arc676/Alessandro Vinciguerra Date: Sun, 1 Nov 2026 10:54:26 +0100 Subject: [PATCH] kinship: use nibling Signed-off-by: Arc676/Alessandro Vinciguerra --- frontend/src/utils/kinship/en.js | 4 ++-- frontend/src/utils/kinship/kinship.test.js | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/frontend/src/utils/kinship/en.js b/frontend/src/utils/kinship/en.js index 17d01db..148b27f 100644 --- a/frontend/src/utils/kinship/en.js +++ b/frontend/src/utils/kinship/en.js @@ -57,8 +57,8 @@ export default function nameEn(path) { } else if (ups === 1 && downs === 1) label = g(sex, 'Brother', 'Sister', 'Sibling') else if (ups === 2 && downs === 1) label = g(sex, 'Uncle', 'Aunt', 'Uncle/Aunt') else if (ups === 3 && downs === 1) label = g(sex, 'Great-uncle', 'Great-aunt', 'Great-uncle/aunt') - else if (ups === 1 && downs === 2) label = g(sex, 'Nephew', 'Niece', 'Nephew/Niece') - else if (ups === 1 && downs === 3) label = g(sex, 'Grandnephew', 'Grandniece', 'Grandnephew/niece') + else if (ups === 1 && downs === 2) label = g(sex, 'Nephew', 'Niece', 'Nibling') + else if (ups === 1 && downs === 3) label = g(sex, 'Grandnephew', 'Grandniece', 'Grandnibling') else if (ups >= 2 && downs >= 2) { const degree = Math.min(ups, downs) - 1 const removed = Math.abs(ups - downs) diff --git a/frontend/src/utils/kinship/kinship.test.js b/frontend/src/utils/kinship/kinship.test.js index e093005..f052bee 100644 --- a/frontend/src/utils/kinship/kinship.test.js +++ b/frontend/src/utils/kinship/kinship.test.js @@ -59,7 +59,7 @@ describe('nommage anglais', () => { expect(bothEn(['down', 'down'])).toEqual(['Grandson', 'Granddaughter', 'Grandchild']) expect(bothEn(['sibling'])).toEqual(['Brother', 'Sister', 'Sibling']) expect(bothEn(['up', 'sibling'])).toEqual(['Uncle', 'Aunt', 'Uncle/Aunt']) - expect(bothEn(['sibling', 'down'])).toEqual(['Nephew', 'Niece', 'Nephew/Niece']) + expect(bothEn(['sibling', 'down'])).toEqual(['Nephew', 'Niece', 'Nibling']) expect(bothEn(['spouse', 'up'])).toEqual(['Father-in-law', 'Mother-in-law', 'Parent-in-law']) expect(bothEn(['up', 'spouse'])).toEqual(['Stepfather', 'Stepmother', 'Stepparent']) expect(bothEn(['spouse', 'down'])).toEqual(['Stepson', 'Stepdaughter', 'Stepchild'])