Mark Hebrew locale as RTL

This commit is contained in:
Mike Cao committed 2026-07-24 14:36:54 -07:00
1 parent 65e810ec79
commit 0b31d3a274
2 files changed
+2 -9

No files matched your search

+1 -8
View File
@@ -20,17 +20,10 @@ describe('getTextDirection', () => {
test('returns rtl for right-to-left languages', () => {
expect(getTextDirection('ar-SA')).toBe('rtl');
expect(getTextDirection('fa-IR')).toBe('rtl');
expect(getTextDirection('he-IL')).toBe('rtl');
expect(getTextDirection('ur-PK')).toBe('rtl');
});
// NOTE: Hebrew (he-IL) is a right-to-left language but is NOT marked with
// `dir: 'rtl'` in `languages`, so getTextDirection returns 'ltr'. This asserts
// the current (suspected buggy) behavior. If the source is fixed to add
// `dir: 'rtl'` for he-IL, update this expectation to 'rtl'.
test('does not mark Hebrew as rtl (suspected source bug)', () => {
expect(getTextDirection('he-IL')).toBe('ltr');
});
test('returns ltr for left-to-right languages', () => {
expect(getTextDirection('en-US')).toBe('ltr');
expect(getTextDirection('fr-FR')).toBe('ltr');