Skip to content

Commit

Permalink
Get rid of computed property names on object literals
Browse files Browse the repository at this point in the history
  • Loading branch information
wojtekmaj committed Jun 26, 2024
1 parent 96ec191 commit fdcb470
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions packages/react-calendar/src/shared/const.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
import type { CalendarType } from './types.js';

export const CALENDAR_TYPES = {
GREGORY: 'gregory',
HEBREW: 'hebrew',
ISLAMIC: 'islamic',
ISO_8601: 'iso8601',
} as const;

export const CALENDAR_TYPE_LOCALES = {
[CALENDAR_TYPES.GREGORY]: [
export const CALENDAR_TYPE_LOCALES: Partial<Record<CalendarType, string[]>> = {
gregory: [
'en-CA',
'en-US',
'es-AR',
Expand All @@ -27,8 +29,8 @@ export const CALENDAR_TYPE_LOCALES = {
'es-VE',
'pt-BR',
],
[CALENDAR_TYPES.HEBREW]: ['he', 'he-IL'],
[CALENDAR_TYPES.ISLAMIC]: [
hebrew: ['he', 'he-IL'],
islamic: [
// ar-LB, ar-MA intentionally missing
'ar',
'ar-AE',
Expand Down

0 comments on commit fdcb470

Please sign in to comment.