From 38537a39671abd23e12a4fce3ce1759e8f9f9f20 Mon Sep 17 00:00:00 2001 From: Hanch Han <51526347+hanchchch@users.noreply.github.com> Date: Tue, 18 Jun 2024 18:14:31 +0900 Subject: [PATCH] Add South Korean won to currency codes (#5914) Greetings from Seoul! I found this amazing project a few days ago, and trying to introduce it to my team. However there is a tiny but significant problem, that South Korean won is not available in twenty. So I added `KRW` to the enum `CurrencyCode` and the constant `SETTINGS_FIELD_CURRENCY_CODES`. I tested it locally and apparently works fine. --- .../modules/object-record/record-field/types/CurrencyCode.ts | 1 + .../data-model/constants/SettingsFieldCurrencyCodes.ts | 5 +++++ .../twenty-ui/src/display/icon/components/TablerIcons.ts | 1 + 3 files changed, 7 insertions(+) diff --git a/packages/twenty-front/src/modules/object-record/record-field/types/CurrencyCode.ts b/packages/twenty-front/src/modules/object-record/record-field/types/CurrencyCode.ts index e039734d7..673b6b7cb 100644 --- a/packages/twenty-front/src/modules/object-record/record-field/types/CurrencyCode.ts +++ b/packages/twenty-front/src/modules/object-record/record-field/types/CurrencyCode.ts @@ -14,4 +14,5 @@ export enum CurrencyCode { MAD = 'MAD', QAR = 'QAR', AED = 'AED', + KRW = 'KRW', } diff --git a/packages/twenty-front/src/modules/settings/data-model/constants/SettingsFieldCurrencyCodes.ts b/packages/twenty-front/src/modules/settings/data-model/constants/SettingsFieldCurrencyCodes.ts index 87729dd43..da235b110 100644 --- a/packages/twenty-front/src/modules/settings/data-model/constants/SettingsFieldCurrencyCodes.ts +++ b/packages/twenty-front/src/modules/settings/data-model/constants/SettingsFieldCurrencyCodes.ts @@ -9,6 +9,7 @@ import { IconCurrencyKroneSwedish, IconCurrencyPound, IconCurrencyRiyal, + IconCurrencyWon, IconCurrencyYen, IconCurrencyYuan, } from 'twenty-ui'; @@ -79,4 +80,8 @@ export const SETTINGS_FIELD_CURRENCY_CODES: Record< label: 'UAE dirham', Icon: IconCurrencyDirham, }, + KRW: { + label: 'South Korean won', + Icon: IconCurrencyWon, + }, }; diff --git a/packages/twenty-ui/src/display/icon/components/TablerIcons.ts b/packages/twenty-ui/src/display/icon/components/TablerIcons.ts index fe3ee7759..c4262154c 100644 --- a/packages/twenty-ui/src/display/icon/components/TablerIcons.ts +++ b/packages/twenty-ui/src/display/icon/components/TablerIcons.ts @@ -61,6 +61,7 @@ export { IconCurrencyKroneSwedish, IconCurrencyPound, IconCurrencyRiyal, + IconCurrencyWon, IconCurrencyYen, IconCurrencyYuan, IconDatabase,