@kenyaemr/esm-care-panel-app 5.4.4-pre.98 → 5.4.5-pre.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (232) hide show
  1. package/currentProphylaxisUsed/fr.json +1 -0
  2. package/hivStatus/fr.json +1 -0
  3. package/package.json +3 -3
  4. package/src/care-panel/care-panel.component.tsx +1 -1
  5. package/src/care-panel-dashboard/care-panel-dashboard.component.tsx +1 -1
  6. package/src/care-programs/care-program-form-translation-keys.ts +121 -0
  7. package/src/care-programs/care-programs.component.tsx +27 -7
  8. package/src/care-programs/program-form-overflow-menu-item.component.tsx +7 -9
  9. package/src/config-schema.ts +89 -1
  10. package/src/iit-risk-score/iit-risk-score-plot.tsx +5 -4
  11. package/src/program-enrollment/program-enrollment.component.tsx +30 -26
  12. package/translations/am.json +136 -0
  13. package/translations/en.json +136 -0
  14. package/translations/fr.json +138 -0
  15. package/translations/sw.json +272 -136
  16. package/treatmentNumber/fr.json +1 -0
  17. package/.turbo/turbo-build.log +0 -8
  18. package/dist/1074.js +0 -1
  19. package/dist/1074.js.map +0 -1
  20. package/dist/1086.js +0 -1
  21. package/dist/1086.js.map +0 -1
  22. package/dist/12.js +0 -17
  23. package/dist/12.js.map +0 -1
  24. package/dist/1311.js +0 -1
  25. package/dist/1311.js.map +0 -1
  26. package/dist/1462.js +0 -1
  27. package/dist/1462.js.map +0 -1
  28. package/dist/1469.js +0 -1
  29. package/dist/1469.js.map +0 -1
  30. package/dist/1506.js +0 -13
  31. package/dist/1506.js.map +0 -1
  32. package/dist/1718.js +0 -1
  33. package/dist/1718.js.map +0 -1
  34. package/dist/1772.js +0 -1
  35. package/dist/1772.js.map +0 -1
  36. package/dist/1889.js +0 -1
  37. package/dist/1889.js.map +0 -1
  38. package/dist/1972.js +0 -1
  39. package/dist/1972.js.map +0 -1
  40. package/dist/1990.js +0 -1
  41. package/dist/1990.js.map +0 -1
  42. package/dist/2078.js +0 -1
  43. package/dist/2078.js.map +0 -1
  44. package/dist/2153.js +0 -1
  45. package/dist/2153.js.map +0 -1
  46. package/dist/216.js +0 -1
  47. package/dist/216.js.map +0 -1
  48. package/dist/2270.js +0 -1
  49. package/dist/2270.js.map +0 -1
  50. package/dist/2294.js +0 -1
  51. package/dist/2294.js.map +0 -1
  52. package/dist/2345.js +0 -1
  53. package/dist/2345.js.map +0 -1
  54. package/dist/2396.js +0 -1
  55. package/dist/2396.js.map +0 -1
  56. package/dist/2500.js +0 -1
  57. package/dist/2500.js.map +0 -1
  58. package/dist/251.js +0 -1
  59. package/dist/251.js.map +0 -1
  60. package/dist/257.js +0 -1
  61. package/dist/257.js.map +0 -1
  62. package/dist/2586.js +0 -1
  63. package/dist/2586.js.map +0 -1
  64. package/dist/2625.js +0 -1
  65. package/dist/2625.js.map +0 -1
  66. package/dist/2685.js +0 -1
  67. package/dist/2685.js.map +0 -1
  68. package/dist/2712.js +0 -1
  69. package/dist/2712.js.map +0 -1
  70. package/dist/2788.js +0 -1
  71. package/dist/2788.js.map +0 -1
  72. package/dist/2948.js +0 -1
  73. package/dist/2948.js.map +0 -1
  74. package/dist/2998.js +0 -1
  75. package/dist/2998.js.map +0 -1
  76. package/dist/3089.js +0 -1
  77. package/dist/3089.js.map +0 -1
  78. package/dist/3189.js +0 -1
  79. package/dist/3189.js.map +0 -1
  80. package/dist/3190.js +0 -1
  81. package/dist/3190.js.map +0 -1
  82. package/dist/3547.js +0 -1
  83. package/dist/3547.js.map +0 -1
  84. package/dist/3548.js +0 -1
  85. package/dist/3548.js.map +0 -1
  86. package/dist/3571.js +0 -1
  87. package/dist/3571.js.map +0 -1
  88. package/dist/3691.js +0 -1
  89. package/dist/3691.js.map +0 -1
  90. package/dist/3798.js +0 -1
  91. package/dist/3798.js.map +0 -1
  92. package/dist/3816.js +0 -1
  93. package/dist/3816.js.map +0 -1
  94. package/dist/3906.js +0 -1
  95. package/dist/3906.js.map +0 -1
  96. package/dist/3921.js +0 -1
  97. package/dist/3921.js.map +0 -1
  98. package/dist/3963.js +0 -1
  99. package/dist/3963.js.map +0 -1
  100. package/dist/405.js +0 -1
  101. package/dist/405.js.map +0 -1
  102. package/dist/4269.js +0 -1
  103. package/dist/4269.js.map +0 -1
  104. package/dist/4296.js +0 -1
  105. package/dist/4296.js.map +0 -1
  106. package/dist/4326.js +0 -1
  107. package/dist/4326.js.map +0 -1
  108. package/dist/4337.js +0 -1
  109. package/dist/4337.js.map +0 -1
  110. package/dist/4423.js +0 -1
  111. package/dist/4423.js.map +0 -1
  112. package/dist/4535.js +0 -1
  113. package/dist/4535.js.map +0 -1
  114. package/dist/4735.js +0 -1
  115. package/dist/4735.js.map +0 -1
  116. package/dist/4744.js +0 -1
  117. package/dist/4744.js.map +0 -1
  118. package/dist/4813.js +0 -2
  119. package/dist/4813.js.map +0 -1
  120. package/dist/4858.js +0 -1
  121. package/dist/4858.js.map +0 -1
  122. package/dist/487.js +0 -1
  123. package/dist/487.js.map +0 -1
  124. package/dist/4970.js +0 -1
  125. package/dist/4970.js.map +0 -1
  126. package/dist/5202.js +0 -1
  127. package/dist/5202.js.map +0 -1
  128. package/dist/5592.js +0 -1
  129. package/dist/5592.js.map +0 -1
  130. package/dist/5669.js +0 -1
  131. package/dist/5669.js.map +0 -1
  132. package/dist/5932.js +0 -1
  133. package/dist/5932.js.map +0 -1
  134. package/dist/6178.js +0 -1
  135. package/dist/6178.js.map +0 -1
  136. package/dist/618.js +0 -1
  137. package/dist/618.js.map +0 -1
  138. package/dist/6355.js +0 -1
  139. package/dist/6355.js.map +0 -1
  140. package/dist/6455.js +0 -1
  141. package/dist/6455.js.map +0 -1
  142. package/dist/6456.js +0 -1
  143. package/dist/6466.js +0 -3
  144. package/dist/6466.js.map +0 -1
  145. package/dist/6492.js +0 -1
  146. package/dist/6492.js.map +0 -1
  147. package/dist/6495.js +0 -1
  148. package/dist/6495.js.map +0 -1
  149. package/dist/6798.js +0 -66
  150. package/dist/6798.js.map +0 -1
  151. package/dist/6800.js +0 -1
  152. package/dist/6800.js.map +0 -1
  153. package/dist/6925.js +0 -1
  154. package/dist/6925.js.map +0 -1
  155. package/dist/7005.js +0 -1
  156. package/dist/7005.js.map +0 -1
  157. package/dist/7201.js +0 -1
  158. package/dist/7201.js.map +0 -1
  159. package/dist/7234.js +0 -1
  160. package/dist/7234.js.map +0 -1
  161. package/dist/7261.js +0 -1
  162. package/dist/7261.js.map +0 -1
  163. package/dist/7326.js +0 -1
  164. package/dist/7358.js +0 -1
  165. package/dist/7358.js.map +0 -1
  166. package/dist/7394.js +0 -1
  167. package/dist/7394.js.map +0 -1
  168. package/dist/7463.js +0 -1
  169. package/dist/7463.js.map +0 -1
  170. package/dist/7527.js +0 -1
  171. package/dist/7527.js.map +0 -1
  172. package/dist/7584.js +0 -1
  173. package/dist/7584.js.map +0 -1
  174. package/dist/7607.js +0 -1
  175. package/dist/770.js +0 -1
  176. package/dist/770.js.map +0 -1
  177. package/dist/7717.js +0 -1
  178. package/dist/7717.js.map +0 -1
  179. package/dist/7739.js +0 -1
  180. package/dist/7739.js.map +0 -1
  181. package/dist/7765.js +0 -1
  182. package/dist/7765.js.map +0 -1
  183. package/dist/7971.js +0 -1
  184. package/dist/7971.js.map +0 -1
  185. package/dist/8159.js +0 -7
  186. package/dist/8159.js.map +0 -1
  187. package/dist/8244.js +0 -1
  188. package/dist/8244.js.map +0 -1
  189. package/dist/845.js +0 -1
  190. package/dist/845.js.map +0 -1
  191. package/dist/8570.js +0 -1
  192. package/dist/8570.js.map +0 -1
  193. package/dist/8603.js +0 -1
  194. package/dist/8603.js.map +0 -1
  195. package/dist/87.js +0 -1
  196. package/dist/87.js.map +0 -1
  197. package/dist/8727.js +0 -1
  198. package/dist/8828.js +0 -1
  199. package/dist/8828.js.map +0 -1
  200. package/dist/8860.js +0 -1
  201. package/dist/8860.js.map +0 -1
  202. package/dist/9124.js +0 -1
  203. package/dist/9124.js.map +0 -1
  204. package/dist/9182.js +0 -1
  205. package/dist/921.js +0 -1
  206. package/dist/921.js.map +0 -1
  207. package/dist/9255.js +0 -1
  208. package/dist/9255.js.map +0 -1
  209. package/dist/9404.js +0 -1
  210. package/dist/9404.js.map +0 -1
  211. package/dist/9446.js +0 -1
  212. package/dist/9446.js.map +0 -1
  213. package/dist/9449.js +0 -1
  214. package/dist/9449.js.map +0 -1
  215. package/dist/9566.js +0 -5
  216. package/dist/9566.js.map +0 -1
  217. package/dist/9641.js +0 -1
  218. package/dist/9641.js.map +0 -1
  219. package/dist/973.js +0 -1
  220. package/dist/973.js.map +0 -1
  221. package/dist/9730.js +0 -1
  222. package/dist/9730.js.map +0 -1
  223. package/dist/9801.js +0 -1
  224. package/dist/9801.js.map +0 -1
  225. package/dist/9835.js +0 -11
  226. package/dist/9835.js.map +0 -1
  227. package/dist/kenyaemr-esm-care-panel-app.js +0 -5
  228. package/dist/kenyaemr-esm-care-panel-app.js.buildmanifest.json +0 -2988
  229. package/dist/kenyaemr-esm-care-panel-app.js.map +0 -1
  230. package/dist/main.js +0 -5
  231. package/dist/main.js.map +0 -1
  232. package/dist/routes.json +0 -1
@@ -0,0 +1 @@
1
+ {}
@@ -0,0 +1 @@
1
+ {}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kenyaemr/esm-care-panel-app",
3
- "version": "5.4.4-pre.98",
3
+ "version": "5.4.5-pre.16",
4
4
  "description": "Patient care panels microfrontend for the OpenMRS SPA",
5
5
  "keywords": [
6
6
  "openmrs"
@@ -22,7 +22,7 @@
22
22
  "build": "rspack --mode=production",
23
23
  "coverage": "echo \"Jest has been removed; no unit test runner is configured\" && exit 0",
24
24
  "debug": "npm run serve",
25
- "extract-translations": "i18next 'src/**/*.component.tsx' 'src/index.ts' --config ../../tools/i18next-parser.config.js",
25
+ "extract-translations": "i18next 'src/**/*.{ts,tsx}' --config ../../tools/i18next-parser.config.js",
26
26
  "lint": "eslint src --ext ts,tsx",
27
27
  "serve": "rspack serve --mode=development",
28
28
  "start": "openmrs develop",
@@ -46,5 +46,5 @@
46
46
  "publishConfig": {
47
47
  "access": "public"
48
48
  },
49
- "stableVersion": "5.4.3"
49
+ "stableVersion": "5.4.4"
50
50
  }
@@ -53,7 +53,7 @@ const CarePanel: React.FC<CarePanelProps> = ({ patientUuid, formEntrySub }) => {
53
53
  <div className={styles.contextSwitcherContainer}>
54
54
  <ContentSwitcher size="md" selectedIndex={switchItem?.index} onChange={(params) => setSwitcherItem(params)}>
55
55
  {switcherHeaders?.map((enrollment) => (
56
- <Switch key={enrollment} name={enrollment} text={enrollment} />
56
+ <Switch key={enrollment} name={enrollment} text={t(enrollment)} />
57
57
  ))}
58
58
  </ContentSwitcher>
59
59
  </div>
@@ -7,7 +7,7 @@ import CarePrograms from '../care-programs/care-programs.component';
7
7
 
8
8
  import CarePanelMachineLearning from '../machine-learning/machine-learning.component';
9
9
  import styles from './care-panel-dashboard.scss';
10
- import { DefaultWorkspaceProps } from '@openmrs/esm-framework/src';
10
+ import { DefaultWorkspaceProps } from '@openmrs/esm-framework';
11
11
 
12
12
  type CarePanelDashboardProps = {
13
13
  patientUuid: string;
@@ -0,0 +1,121 @@
1
+ /**
2
+ * This file exists solely to register care program form translation keys for i18next-parser extraction.
3
+ * The keys are used dynamically via `formTranslationKey` in the careProgramForms config — the parser
4
+ * cannot detect dynamic keys, so they are listed here as static t() calls.
5
+ *
6
+ * Do not remove or call this function at runtime.
7
+ */
8
+ export function registerCareProgramFormTranslationKeys(t: (key: string, defaultValue: string) => string) {
9
+ // VMMC
10
+ t('vmmcEnrollment', 'VMMC Enrollment');
11
+ t('vmmcInitial', 'VMMC Initial');
12
+ t('vmmcClientFollowUp', 'VMMC Client Follow-Up');
13
+ t('vmmcCircumcisionProcedure', 'VMMC Circumcision Procedure');
14
+ t('vmmcImmediatePostOperationAssessment', 'VMMC Immediate Post-Operation Assessment');
15
+ t('vmmcMedicalExamination', 'VMMC Medical Examination');
16
+ t('vmmcDiscontinuation', 'VMMC Discontinuation');
17
+
18
+ // CPM
19
+ t('cpmEnrollment', 'CPM Enrollment');
20
+ t('cpmInitial', 'CPM Initial');
21
+ t('cpmReferral', 'CPM Referral');
22
+ t('cpmScreening', 'CPM Screening');
23
+ t('cpmDiscontinuation', 'CPM Discontinuation');
24
+
25
+ // PNC
26
+ t('pncEnrollment', 'PNC Enrollment');
27
+ t('mchPncVisit', 'MCH PNC Visit');
28
+ t('pncDiscontinuation', 'PNC Discontinuation');
29
+
30
+ // ANC
31
+ t('ancEnrollment', 'ANC Enrollment');
32
+ t('mchAntenatalVisit', 'MCH Antenatal Visit');
33
+ t('ancFollowUpForm', 'ANC Follow Up form');
34
+ t('ancDiscontinuation', 'ANC Discontinuation');
35
+
36
+ // MCH - Child Services (CWC)
37
+ t('cwcEnrolment', 'CWC Enrolment');
38
+ t('cwcInitial', 'Initial CWC');
39
+ t('cwcFollowup', 'CWC Followup');
40
+ t('cwcDiscontinuation', 'CWC Discontinuation');
41
+
42
+ // Nutrition
43
+ t('nutritionEnrollment', 'Nutrition Enrollment');
44
+ t('nutritionForm', 'Nutrition form');
45
+ t('nutritionDiscontinuation', 'Nutrition Discontinuation');
46
+
47
+ // Family Planning
48
+ t('familyPlanningEnrollment', 'Family Planning Enrollment');
49
+ t('familyPlanningForm', 'Family Planning Form');
50
+ t('familyPlanningDiscontinuation', 'Family Planning Discontinuation');
51
+
52
+ // TB
53
+ t('tbEnrollment', 'TB Enrollment');
54
+ t('tbInitial', 'TB Initial');
55
+ t('tbFollowUp', 'TB FollowUp');
56
+ t('tbDiscontinuation', 'TB Discontinuation');
57
+
58
+ // Violence screening
59
+ t('violenceEnrollment', 'Violence enrollment');
60
+ t('violenceScreening', 'Violence Screening');
61
+ t('violenceInitialForm', 'Violence Initial Form');
62
+ t('violenceConsentForm', 'Violence Consent Form');
63
+ t('sexualViolencePostRapeCare363A', 'Sexual Violence post rape care 363A');
64
+ t('sexualViolencePrcPsychologicalAssessment363B', 'Sexual Violence PRC Psychological Assessment 363B');
65
+ t('physicalAndEmotionalViolenceForm', 'Physical and Emotional Violence Form');
66
+ t('violenceTraumaCounselling', 'Violence Trauma Counselling');
67
+ t('violenceReportingForm', 'Violence Reporting Form');
68
+ t('violenceCommunityLinkageForm', 'Violence Community Linkage Form');
69
+ t('violenceLegalForm', 'Violence Legal Form');
70
+ t('violencePerpetratorDetails', 'Violence Perpetrator Details');
71
+ t('pepFollowupForm', 'PEP FOLLOWUP Form');
72
+ t('violenceDiscontinuationForm', 'Violence Discontinuation Form');
73
+
74
+ // TPT
75
+ t('tptInitiation', 'TPT Initiation');
76
+ t('tptInitial', 'TPT Initial');
77
+ t('tptFollowUp', 'TPT FollowUp');
78
+ t('tptOutcomeDiscontinuation', 'TPT Outcome/Discontinuation');
79
+
80
+ // PrEP
81
+ t('prepEnrollment', 'PrEP Enrollment');
82
+ t('prepInitiation', 'PrEP Initiation');
83
+ t('prepClinicalForm', 'PrEP Clinical Form');
84
+ t('prepDiscontinuation', 'PrEP Discontinuation');
85
+
86
+ // NCD
87
+ t('ncdEnrollment', 'NCD Enrollment');
88
+ t('ncdInitial', 'NCD Initial');
89
+ t('ncdFollowUp', 'NCD Follow Up');
90
+ t('ncdDiscontinuation', 'NCD Discontinuation');
91
+
92
+ // KVP
93
+ t('kvpEnrollmentForm', 'KVP Enrollment Form');
94
+ t('kvpContactForm', 'KVP Contact Form');
95
+ t('kvpClinicalEnrollment', 'KVP Clinical Enrollment');
96
+ t('kvpPeerEducatorOutreachCalendar', 'KVP Peer Educator Outreach Calendar');
97
+ t('kvpClinicalEncounterForm', 'KVP Clinical Encounter form');
98
+ t('kvpClientDiscontinuation', 'KVP Client Discontinuation');
99
+
100
+ // HIV Program
101
+ t('hivEnrollment', 'HIV Enrollment');
102
+ t('hivInitialForm', 'HIV Initial form');
103
+ t('artReadiness', 'ART Readyness');
104
+ t('hivGreenCard', 'HIV Green Card');
105
+ t('hivDiscontinuation', 'HIV Discontinuation');
106
+
107
+ // Pre-Conception care program
108
+ t('preConceptionCareEnrollmentForm', 'Pre-Conception Care Enrollment Form');
109
+ t('preConceptionCare', 'Pre-Conception Care');
110
+ t('preConceptionDiscontinuation', 'Pre-Conception Discontinuation');
111
+
112
+ // MAT
113
+ t('matClinicalEligibilityAssessmentAndReferralForm', 'MAT Clinical Eligibility Assessment & Referral Form');
114
+ t('matInitialRegistrationForm', 'MAT Initial Registration Form');
115
+ t('matPsychoSocialIntakeAndFollowUpForm', 'MAT Psycho-social Intake & Follow-up Form');
116
+ t('matClinicalEncounterForm', 'MAT Clinical Encounter Form');
117
+ t('matPsychiatricIntakeAndFollowUpForm', 'MAT Psychiatric Intake and Follow up Form');
118
+ t('matTransitReferralForm', 'MAT Transit/Referral Form');
119
+ t('matCessationForm', 'MAT Cessation Form');
120
+ t('matDiscontinuationForm', 'MAT Discontinuation Form');
121
+ }
@@ -90,7 +90,7 @@ const CarePrograms: React.FC<CareProgramsProps> = ({ patientUuid, patient }) =>
90
90
 
91
91
  return {
92
92
  id: enrollment.program.uuid,
93
- programName: enrollment.program.name,
93
+ programName: t(enrollment.program.name),
94
94
  status: (
95
95
  <div className={styles.careProgramButtonContainer}>
96
96
  <Tag type="green">{t('enrolled', 'Enrolled')}</Tag>
@@ -123,15 +123,35 @@ const CarePrograms: React.FC<CareProgramsProps> = ({ patientUuid, patient }) =>
123
123
  }),
124
124
  ...eligibleCarePrograms.map((careProgram) => {
125
125
  const enrollmentForm = getProgramEnrollmentForm(careProgram.uuid);
126
-
127
126
  return {
128
127
  id: `${careProgram.uuid}`,
129
- programName: careProgram.display,
128
+ // t('HIV', 'HIV')
129
+ // t('Child Welfare Clinic', 'Child Welfare Clinic')
130
+ // t('SMNI - Services maternels', 'SMNI - Services maternels')
131
+ // t('TB', 'TB')
132
+ // t('TPT', 'TPT')
133
+ // t('PrEP', 'PrEP')
134
+ // t('OVC', 'OVC')
135
+ // t('OTZ', 'OTZ')
136
+ // t('KVP', 'KVP')
137
+ // t('NimeCONFIRM', 'NimeCONFIRM')
138
+ // t('VMMC', 'VMMC')
139
+ // t('MAT', 'MAT')
140
+ // t('NCD', 'NCD')
141
+ // t('Violence screening', 'Violence screening')
142
+ // t('CPM', 'CPM')
143
+ // t('Nutrition', 'Nutrition')
144
+ // t('Antenatal Care', 'Antenatal Care')
145
+ // t('Postnatal Care', 'Postnatal Care')
146
+ // t('Family Planning', 'Family Planning')
147
+ // t('Pre-Conception Care', 'Pre-Conception Care')
148
+ programName: t(careProgram.display),
130
149
  status: (
131
150
  <div className={styles.careProgramButtonContainer}>
132
151
  <span>
133
152
  {capitalize(
134
- `${careProgram.enrollmentStatus} ${
153
+ // t('eligible', 'Eligible')
154
+ `${t(careProgram.enrollmentStatus)} ${
135
155
  careProgram.enrollmentDetails?.dateEnrolled && careProgram.enrollmentStatus === 'active'
136
156
  ? `Since (${formatDate(new Date(careProgram.enrollmentDetails.dateEnrolled))})`
137
157
  : ''
@@ -161,7 +181,7 @@ const CarePrograms: React.FC<CareProgramsProps> = ({ patientUuid, patient }) =>
161
181
  );
162
182
  }}
163
183
  renderIcon={careProgram.enrollmentStatus == 'active' ? Close : DocumentAdd}>
164
- {careProgram.enrollmentStatus == 'active' ? 'Discontinue' : 'Enroll'}
184
+ {careProgram.enrollmentStatus == 'active' ? t('discontinue', 'Discontinue') : t('enroll', 'Enroll')}
165
185
  </Button>
166
186
  </div>
167
187
  ),
@@ -186,11 +206,11 @@ const CarePrograms: React.FC<CareProgramsProps> = ({ patientUuid, patient }) =>
186
206
  const headers = [
187
207
  {
188
208
  key: 'programName',
189
- header: 'Program name',
209
+ header: t('programName', 'Program Name'),
190
210
  },
191
211
  {
192
212
  key: 'status',
193
- header: 'Status',
213
+ header: t('status', 'Status'),
194
214
  },
195
215
  ];
196
216
 
@@ -1,10 +1,6 @@
1
1
  import { InlineLoading, OverflowMenuItem } from '@carbon/react';
2
- import { launchWorkspace, showSnackbar, useConfig, Visit } from '@openmrs/esm-framework';
3
- import {
4
- launchStartVisitPrompt,
5
- useLaunchWorkspaceRequiringVisit,
6
- usePatientChartStore,
7
- } from '@openmrs/esm-patient-common-lib';
2
+ import { showSnackbar, useConfig } from '@openmrs/esm-framework';
3
+ import { useLaunchWorkspaceRequiringVisit, usePatientChartStore } from '@openmrs/esm-patient-common-lib';
8
4
  import React, { FC, useEffect, useMemo } from 'react';
9
5
  import { useTranslation } from 'react-i18next';
10
6
  import { CarePanelConfig } from '../config-schema';
@@ -105,14 +101,16 @@ const ProgramFormOverflowMenuItem: FC<ProgramFormOverflowMenuItemProps> = ({
105
101
  );
106
102
  }
107
103
 
104
+ const formLabel = t(form.formTranslationKey ?? form.formName, { defaultValue: form.formName });
105
+
108
106
  return (
109
107
  <OverflowMenuItem
110
108
  key={form.formUuId}
111
- itemText={form.formName}
109
+ itemText={formLabel}
112
110
  onClick={() => {
113
111
  /**
114
112
  launchWorkspace('patient-form-entry-workspace', {
115
- workspaceTitle: form.formName,
113
+ workspaceTitle: formLabel,
116
114
  mutateForm: () => {
117
115
  mutate?.();
118
116
  mutateDependancyStatus();
@@ -129,7 +127,7 @@ const ProgramFormOverflowMenuItem: FC<ProgramFormOverflowMenuItemProps> = ({
129
127
  */
130
128
  return launchFormEntryWorkspace(
131
129
  {
132
- workspaceTitle: form.formName,
130
+ workspaceTitle: formLabel,
133
131
  form: {
134
132
  uuid: form.formUuId,
135
133
  },