@kenyaemr/esm-ward-app 8.5.4-pre.1 → 8.5.4-pre.100

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 (96) hide show
  1. package/.turbo/turbo-build.log +2 -2
  2. package/README.md +31 -0
  3. package/dist/2089.js +1 -0
  4. package/dist/2089.js.map +1 -0
  5. package/dist/2512.js +1 -0
  6. package/dist/2512.js.map +1 -0
  7. package/dist/400.js +1 -0
  8. package/dist/400.js.map +1 -0
  9. package/dist/5090.js +1 -1
  10. package/dist/5090.js.map +1 -1
  11. package/dist/5463.js +1 -0
  12. package/dist/5463.js.map +1 -0
  13. package/dist/5930.js +1 -0
  14. package/dist/5930.js.map +1 -0
  15. package/dist/6456.js +1 -1
  16. package/dist/7607.js +1 -1
  17. package/dist/775.js +1 -1
  18. package/dist/775.js.map +1 -1
  19. package/dist/7783.js +1 -0
  20. package/dist/7783.js.map +1 -0
  21. package/dist/7844.js +1 -0
  22. package/dist/7844.js.map +1 -0
  23. package/dist/7965.js +1 -0
  24. package/dist/7965.js.map +1 -0
  25. package/dist/8660.js +1 -0
  26. package/dist/8660.js.map +1 -0
  27. package/dist/kenyaemr-esm-ward-app.js.buildmanifest.json +212 -89
  28. package/dist/main.js +2 -2
  29. package/dist/main.js.map +1 -1
  30. package/dist/routes.json +1 -1
  31. package/package.json +1 -1
  32. package/src/config-schema.ts +21 -1
  33. package/src/in-patient/labourCareGuide/alert-rules.ts +97 -4
  34. package/src/in-patient/labourCareGuide/components/lcg-correction-audit-banner.component.tsx +42 -0
  35. package/src/in-patient/labourCareGuide/components/summary-of-labour-section.component.tsx +408 -0
  36. package/src/in-patient/labourCareGuide/constants/admission-form.constants.ts +22 -0
  37. package/src/in-patient/labourCareGuide/constants/summary-of-labour.constants.ts +102 -0
  38. package/src/in-patient/labourCareGuide/context/lcg-section-state.context.tsx +252 -0
  39. package/src/in-patient/labourCareGuide/forms/admission-details-form.component.tsx +28 -14
  40. package/src/in-patient/labourCareGuide/forms/baby-form.component.tsx +55 -179
  41. package/src/in-patient/labourCareGuide/forms/index.ts +1 -0
  42. package/src/in-patient/labourCareGuide/forms/labour-care-guide-forms.component.tsx +108 -31
  43. package/src/in-patient/labourCareGuide/forms/labour-progress-form.component.tsx +163 -216
  44. package/src/in-patient/labourCareGuide/forms/lcg-session-correction-wizard.component.tsx +261 -0
  45. package/src/in-patient/labourCareGuide/forms/medication-form.component.tsx +598 -220
  46. package/src/in-patient/labourCareGuide/forms/shared-decision-assessment-field.component.tsx +109 -0
  47. package/src/in-patient/labourCareGuide/forms/shared-decision-making-form.component.tsx +354 -353
  48. package/src/in-patient/labourCareGuide/forms/summary-of-labour-form.component.tsx +887 -0
  49. package/src/in-patient/labourCareGuide/forms/supportive-care-form.component.tsx +33 -90
  50. package/src/in-patient/labourCareGuide/forms/time-form.component.tsx +12 -4
  51. package/src/in-patient/labourCareGuide/forms/time-picker-dropdown.component.tsx +162 -62
  52. package/src/in-patient/labourCareGuide/forms/woman-form.component.tsx +51 -79
  53. package/src/in-patient/labourCareGuide/global-cds-alerts/global-cds-alert-context.tsx +2 -2
  54. package/src/in-patient/labourCareGuide/graphs/labour-progress.component.tsx +188 -86
  55. package/src/in-patient/labourCareGuide/graphs/medication.component.tsx +15 -23
  56. package/src/in-patient/labourCareGuide/graphs/shared-decision-making.component.tsx +157 -44
  57. package/src/in-patient/labourCareGuide/graphs/supportive-care.component.tsx +4 -1
  58. package/src/in-patient/labourCareGuide/graphs/woman.component.tsx +3 -39
  59. package/src/in-patient/labourCareGuide/hooks/use-lcg-data.ts +497 -229
  60. package/src/in-patient/labourCareGuide/hooks/use-lcg-debounced-value.ts +17 -0
  61. package/src/in-patient/labourCareGuide/hooks/use-lcg-form-clock.ts +36 -0
  62. package/src/in-patient/labourCareGuide/hooks/use-lcg-section-autosave.ts +33 -0
  63. package/src/in-patient/labourCareGuide/labour-care-guide.component.tsx +664 -57
  64. package/src/in-patient/labourCareGuide/labour-care-guide.scss +256 -0
  65. package/src/in-patient/labourCareGuide/labour-care-guide.utils.ts +146 -7
  66. package/src/in-patient/labourCareGuide/lcg-alert-lifecycle.ts +161 -0
  67. package/src/in-patient/labourCareGuide/partography-data-form.scss +204 -3
  68. package/src/in-patient/labourCareGuide/partography.resource.ts +15 -27
  69. package/src/in-patient/labourCareGuide/resources/admission-details.resource.ts +26 -25
  70. package/src/in-patient/labourCareGuide/resources/drug-stock.resource.ts +98 -0
  71. package/src/in-patient/labourCareGuide/resources/labour-progress.resource.ts +37 -2
  72. package/src/in-patient/labourCareGuide/resources/lcg-session-correction.resource.ts +1027 -0
  73. package/src/in-patient/labourCareGuide/resources/medication.resource.ts +241 -37
  74. package/src/in-patient/labourCareGuide/resources/shared-decision-making.resource.ts +37 -3
  75. package/src/in-patient/labourCareGuide/resources/summary-of-labour.resource.ts +472 -0
  76. package/src/in-patient/labourCareGuide/resources/supportive-care.resource.ts +56 -5
  77. package/src/in-patient/labourCareGuide/storage/lcg-local-storage.ts +374 -0
  78. package/src/in-patient/labourCareGuide/summary-of-labour-prefill.utils.ts +436 -0
  79. package/src/in-patient/labourCareGuide/time-slot-utils.ts +211 -28
  80. package/src/in-patient/labourCareGuide/types/concept-uuids.constants.ts +21 -0
  81. package/src/in-patient/labourCareGuide/types/index.ts +31 -7
  82. package/src/index.ts +17 -0
  83. package/src/routes.json +20 -0
  84. package/src/ward-patients/ward-patients-slots.ts +21 -0
  85. package/src/ward-patients/ward-patients-table.test.tsx +58 -0
  86. package/src/ward-patients/ward-patients-table.tsx +25 -8
  87. package/translations/en.json +121 -15
  88. package/translations/fr.json +123 -15
  89. package/dist/4032.js +0 -1
  90. package/dist/4032.js.map +0 -1
  91. package/dist/6381.js +0 -1
  92. package/dist/6381.js.map +0 -1
  93. package/dist/762.js +0 -1
  94. package/dist/762.js.map +0 -1
  95. package/dist/9465.js +0 -1
  96. package/dist/9465.js.map +0 -1
@@ -1,8 +1,8 @@
1
1
  WARNING in âš  asset size limit: The following asset(s) exceed the recommended size limit (244.141 KiB). This can impact web performance.
2
2
  │ Assets:
3
3
  │ 9535.js (1.920 MiB)
4
- │ 4032.js (598.415 KiB)
4
+ │ 2089.js (755.103 KiB)
5
5
  │ 2823.js (479.797 KiB)
6
6
  
7
7
 
8
- Rspack compiled with 1 warning in 37.90 s
8
+ Rspack compiled with 1 warning in 36.26 s
package/README.md CHANGED
@@ -22,6 +22,37 @@ Please see the [EMR API README](https://github.com/openmrs/openmrs-module-emrapi
22
22
 
23
23
  See the [config-schema](./src/config-schema.ts) for details on the configuration options available to the ward app.
24
24
 
25
+ ## Ward Patient Table Tab Extension Slots
26
+
27
+ The default ward table view renders four fixed tabs (Awaiting Admission, Admitted, Discharge In, Discharged). Each tab panel is backed by an extension slot so implementers can replace the default table UI without forking the ward app.
28
+
29
+ | Tab | Slot name | Default extension name |
30
+ |-----|-----------|------------------------|
31
+ | Awaiting Admission | `ward-patients-awaiting-admission-slot` | `ward-patients-awaiting-admission` |
32
+ | Admitted | `ward-patients-admitted-slot` | `ward-patients-admitted` |
33
+ | Discharge In | `ward-patients-discharge-in-slot` | `ward-patients-discharge-in` |
34
+ | Discharged | `ward-patients-discharged-slot` | `ward-patients-discharged` |
35
+
36
+ ### Custom component requirements
37
+
38
+ - Render under `DefaultWardView` so `useAppContext('ward-view-context')` provides ward patient data.
39
+ - Reuse types from [`src/types/index.ts`](./src/types/index.ts): `WardViewContext`, `WardPatient`, etc.
40
+ - Optional shared UI helpers: `HyperLinkPatientCell`, `EmptyState`, `ErrorState`, `getOpenmrsId`.
41
+
42
+ ### Replacing a default table
43
+
44
+ In your module's `routes.json`, register the replacement extension:
45
+
46
+ ```json
47
+ {
48
+ "name": "my-custom-awaiting-admission",
49
+ "component": "myAwaitingAdmissionTable",
50
+ "slot": "ward-patients-awaiting-admission-slot"
51
+ }
52
+ ```
53
+
54
+ The default table components are exported from this module (`wardPatientsAwaitingAdmissionTable`, `wardPatientsAdmittedTable`, `wardPatientsDischargeInTable`, `wardPatientsDischargedTable`) if you need to wrap or extend them.
55
+
25
56
  ## Bed Management
26
57
 
27
58
  The ward app is designed to support patient bed assignments and to be used in conjunction with the bedmanagement module and the bed-management-app ESM. However, bed management is entirely optional. Patients will appear on a ward if they: