diff --git a/src/i18n/langs/en.ts b/src/i18n/langs/en.ts index 65ffbab..3fc7a25 100644 --- a/src/i18n/langs/en.ts +++ b/src/i18n/langs/en.ts @@ -286,6 +286,17 @@ const enTranslation = { }, }, }, + qrcode: { + title: 'Getting started with the app', + step1: 'Step 1', + step1description: 'Open the app', + step2: 'Step 2', + step2description: 'Scan the QR Code', + step3: 'Step 3', + step3description: 'Select school, profile and start coaching', + print: 'Print this page', + close: 'Close', + }, }; export default enTranslation; diff --git a/src/i18n/langs/np.ts b/src/i18n/langs/np.ts index 7564d60..8efd111 100644 --- a/src/i18n/langs/np.ts +++ b/src/i18n/langs/np.ts @@ -281,6 +281,17 @@ const npTranslation = { }, }, }, + qrcode: { + title: 'अनुप्रयोगसँग सुरु गर्नुहोस्', + step1: 'चरण १', + step1description: 'अनुप्रयोग खोल्नुहोस्', + step2: 'चरण २', + step2description: 'क्यूआर कोड स्क्यान गर्नुहोस्', + step3: 'चरण ३', + step3description: 'विद्यालय, प्रोफाइल चयन गर्नुहोस् र कोचिंग सुरु गर्नुहोस्', + print: 'यो पृष्ठ प्रिन्ट गर्नुहोस्', + close: 'बन्द गर्नुहोस्', + }, }; export default npTranslation; diff --git a/src/pages/Schools/SchoolList/QRCodeModal/index.tsx b/src/pages/Schools/SchoolList/QRCodeModal/index.tsx index f94afe7..80a18b7 100644 --- a/src/pages/Schools/SchoolList/QRCodeModal/index.tsx +++ b/src/pages/Schools/SchoolList/QRCodeModal/index.tsx @@ -16,6 +16,7 @@ import QRCode from 'qrcode.react'; import React from 'react'; import { Props } from './types'; import { QROpenApp, QRScan, QRSelectSchool } from '@/assets/images/qrcode'; +import { useTranslation } from 'react-i18next'; const QRSteps = [ { @@ -33,6 +34,8 @@ const QRSteps = [ ]; const QRCodeModal: React.FC = ({ handleClose, school, schoolKey }) => { + const { t } = useTranslation(); + return ( @@ -42,7 +45,7 @@ const QRCodeModal: React.FC = ({ handleClose, school, schoolKey }) => { {school && schoolKey ? ( - Getting started with the app + {t('qrcode.title')} @@ -50,10 +53,10 @@ const QRCodeModal: React.FC = ({ handleClose, school, schoolKey }) => { {step.description} - Step {index + 1} + {t(`qrcode.step${index + 1}`)} - {step.description} + {t(`qrcode.step${index + 1}description`)} ))} @@ -78,10 +81,10 @@ const QRCodeModal: React.FC = ({ handleClose, school, schoolKey }) => {