diff --git a/packages/i18nify-playground/src/constants/geo/index.js b/packages/i18nify-playground/src/constants/geo/index.js index cb2acf6d..d892060e 100644 --- a/packages/i18nify-playground/src/constants/geo/index.js +++ b/packages/i18nify-playground/src/constants/geo/index.js @@ -1 +1,4 @@ export const ALLOWED_COUNTRIES = ['IN', 'MY', 'FR', 'DE', 'US']; + +export const FLAG_4X3_BASE_PATH = + 'https://unpkg.com/@razorpay/i18nify-js/lib/assets/flags'; diff --git a/packages/i18nify-playground/src/sections/phoneNumber/phoneNumber-form.jsx b/packages/i18nify-playground/src/sections/phoneNumber/phoneNumber-form.jsx index 91c2cfae..66cee10d 100644 --- a/packages/i18nify-playground/src/sections/phoneNumber/phoneNumber-form.jsx +++ b/packages/i18nify-playground/src/sections/phoneNumber/phoneNumber-form.jsx @@ -19,6 +19,10 @@ import { localPhoneNumbersByDialCodeMap, } from './data/phoneNumber'; +import { + FLAG_4X3_BASE_PATH +} from '../../constants/geo'; + const PhoneNumberForm = ({ inpValue, onInpChange, @@ -88,7 +92,7 @@ const PhoneNumberForm = ({ marginRight: 8, }} loading="lazy" - src={`/assets/flags/${dialCodeCountryCodeMap[ + src={`${FLAG_4X3_BASE_PATH}/${dialCodeCountryCodeMap[ code ][0].toLocaleLowerCase()}.svg`} />