@openmrs/esm-patient-programs-app 8.1.1-pre.5162 → 8.1.1-pre.5169
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.
- package/.turbo/turbo-build.log +4 -4
- package/dist/577.js +1 -1
- package/dist/577.js.map +1 -1
- package/dist/81.js +1 -1
- package/dist/81.js.map +1 -1
- package/dist/951.js +1 -1
- package/dist/951.js.map +1 -1
- package/dist/main.js +1 -1
- package/dist/main.js.map +1 -1
- package/dist/openmrs-esm-patient-programs-app.js +1 -1
- package/dist/openmrs-esm-patient-programs-app.js.buildmanifest.json +13 -13
- package/dist/routes.json +1 -1
- package/package.json +3 -3
- package/src/programs/programs-detailed-summary.component.tsx +1 -1
- package/src/programs/programs-form.scss +8 -8
- package/src/programs/programs-overview.component.tsx +1 -1
package/.turbo/turbo-build.log
CHANGED
|
@@ -19,14 +19,14 @@ orphan modules 3.98 MiB [1m[33m[orphan][39m[22m 580 modules
|
|
|
19
19
|
runtime modules 41.2 KiB 28 modules
|
|
20
20
|
built modules 6.21 MiB (javascript) 336 bytes (share-init) 336 bytes (consume-shared) [1m[33m[built][39m[22m
|
|
21
21
|
modules by path [1m../../node_modules/[39m[22m 5.89 MiB 119 modules
|
|
22
|
-
modules by path [1m./[39m[22m
|
|
22
|
+
modules by path [1m./[39m[22m 116 KiB
|
|
23
23
|
modules by path [1m./translations/[39m[22m 10.6 KiB 10 modules
|
|
24
24
|
modules by path [1m./src/[39m[22m 105 KiB 6 modules
|
|
25
25
|
provide-module modules 336 bytes 8 modules
|
|
26
26
|
consume-shared-module modules 336 bytes 8 modules
|
|
27
|
-
modules by path [1m../esm-patient-common-lib/src/[39m[22m
|
|
27
|
+
modules by path [1m../esm-patient-common-lib/src/[39m[22m 211 KiB
|
|
28
28
|
[1m../esm-patient-common-lib/src/index.ts + 40 modules[39m[22m 82.8 KiB [1m[33m[built][39m[22m [1m[33m[code generated][39m[22m
|
|
29
|
-
../../node_modules/@openmrs/webpack-config/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[2].use[1]!../../node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[2].use[2]![1m../esm-patient-common-lib/src/cards/card-header.scss[39m[22m
|
|
29
|
+
../../node_modules/@openmrs/webpack-config/node_modules/css-loader/dist/cjs.js??ruleSet[1].rules[2].use[1]!../../node_modules/sass-loader/dist/cjs.js??ruleSet[1].rules[2].use[2]![1m../esm-patient-common-lib/src/cards/card-header.scss[39m[22m 31.3 KiB [1m[33m[built][39m[22m [1m[33m[code generated][39m[22m
|
|
30
30
|
+ 3 modules
|
|
31
31
|
[1mcontainer entry[39m[22m 42 bytes [1m[33m[built][39m[22m [1m[33m[code generated][39m[22m
|
|
32
32
|
|
|
@@ -43,4 +43,4 @@ Entrypoints:
|
|
|
43
43
|
main.js
|
|
44
44
|
[39m[22m
|
|
45
45
|
|
|
46
|
-
webpack 5.89.0 compiled with [1m[33m2 warnings[39m[22m in
|
|
46
|
+
webpack 5.89.0 compiled with [1m[33m2 warnings[39m[22m in 107262 ms
|
package/dist/577.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(globalThis.webpackChunk_openmrs_esm_patient_programs_app=globalThis.webpackChunk_openmrs_esm_patient_programs_app||[]).push([[577],{9015:(e,n,t)=>{t.d(n,{Z:()=>l});var a=t(5698),i=t.n(a),o=t(9613),r=t.n(o)()(i());r.push([e.id,":root{--brand-01: #005d5d;--brand-02: #004144;--brand-03: #007d79;--bottom-nav-height: 4rem;--workspace-header-height: 3rem;--tablet-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--bottom-nav-height));--desktop-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--workspace-header-height))}.-esm-patient-programs__programs-form__loading___Udyd1{margin-left:1rem;width:2rem;min-height:2.5rem}.-esm-patient-programs__programs-form__button___\\+EibT{height:4rem;display:flex;align-content:flex-start;align-items:baseline;min-width:50%}.-esm-patient-programs__programs-form__button___\\+EibT .cds--inline-loading__text{font-size:var(--cds-body-01-font-size, 0.875rem);font-weight:var(--cds-body-01-font-weight, 400);line-height:var(--cds-body-01-line-height, 1.42857);letter-spacing:var(--cds-body-01-letter-spacing, 0.16px)}.-esm-patient-programs__programs-form__tablet___F8bMH{padding:1.5rem 1rem;background-color:#fff}.-esm-patient-programs__programs-form__desktop___Xlimz{padding:0rem}.-esm-patient-programs__programs-form__formContainer___0TBLb{margin:1rem}.-esm-patient-programs__programs-form__form___AHDMX{display:flex;flex-direction:column;justify-content:space-between;height:100%}.-esm-patient-programs__programs-form__errorMessage___JQ2u-{font-size:var(--cds-label-02-font-size, 0.875rem);font-weight:var(--cds-label-02-font-weight, 400);line-height:var(--cds-label-02-line-height, 1.28572);letter-spacing:var(--cds-label-02-letter-spacing, 0.16px);margin-top:.5rem;color:#da1e28}.-esm-patient-programs__programs-form__notification___9QK0m{margin:0;min-width:100%;padding:0}","",{version:3,sources:["webpack://./../../node_modules/@openmrs/esm-styleguide/src/_vars.scss","webpack://./src/programs/programs-form.scss","webpack://./../../node_modules/@carbon/type/scss/_styles.scss","webpack://./../../node_modules/@carbon/layout/scss/generated/_spacing.scss"],names:[],mappings:"AAoDA,MACE,mBAAA,CACA,mBAAA,CACA,mBAAA,CACA,yBAAA,CACA,+BAAA,CACA,oGAAA,CACA,2GAAA,CCvDF,uDACE,gBAAA,CACA,UAAA,CACA,iBAAA,CAGF,uDACE,WAAA,CACA,YAAA,CACA,wBAAA,CACA,oBAAA,CACA,aAAA,CAEA,kFCi1BE,gDAAA,CAAA,+CAAA,CAAA,mDAAA,CAAA,wDAAA,CD50BJ,sDACE,mBAAA,CACA,qBDvBM,CC0BR,uDACE,YAAA,CAGF,6DACE,WAAA,CAGF,oDACE,YAAA,CACA,qBAAA,CACA,6BAAA,CACA,WAAA,CAGF,4DCwzBI,iDAAA,CAAA,gDAAA,CAAA,oDAAA,CAAA,yDAAA,CDtzBF,gBEvBW,CFwBX,aDzBO,CC4BT,4DACE,QAAA,CACA,cAAA,CACA,SAAA",sourcesContent:["$ui-01: #f4f4f4;\n$ui-02: #ffffff;\n$ui-03: #e0e0e0;\n$ui-04: #8d8d8d;\n$ui-05: #161616;\n$text-02: #525252;\n$text-03: #a8a8a8;\n$ui-background: #ffffff;\n$color-gray-30: #c6c6c6;\n$color-gray-70: #525252;\n$color-gray-100: #161616;\n$color-blue-60-2: #0f62fe;\n$color-blue-10: #edf5ff;\n$color-yellow-50: #feecae;\n$carbon--red-50: #fa4d56;\n$inverse-link: #78a9ff;\n$support-02: #24a148;\n$inverse-support-03: #f1c21b;\n$warning-background: #fff8e1;\n$openmrs-background-grey: #f4f4f4;\n$danger: #da1e28;\n$interactive-01: #0f62fe;\n$field-01: #f4f4f4;\n$grey-2: #e0e0e0;\n$labeldropdown: #c6c6c6;\n\n$brand-primary-10: #d9fbfb;\n$brand-primary-20: #9ef0f0;\n$brand-primary-30: #3ddbd9;\n$brand-primary-40: #08bdba;\n$brand-primary-50: #009d9a;\n\n/* 60,70 and 80 are already declared as brand-01, 02 and 03 respectively */\n\n$brand-primary-90: #022b30;\n$brand-primary-100: #081a1c;\n\n@mixin brand-01($property) {\n #{$property}: #005d5d;\n #{$property}: var(--brand-01);\n}\n\n@mixin brand-02($property) {\n #{$property}: #004144;\n #{$property}: var(--brand-02);\n}\n\n@mixin brand-03($property) {\n #{$property}: #007d79;\n #{$property}: var(--brand-03);\n}\n\n:root {\n --brand-01: #005d5d;\n --brand-02: #004144;\n --brand-03: #007d79;\n --bottom-nav-height: 4rem;\n --workspace-header-height: 3rem;\n --tablet-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--bottom-nav-height));\n --desktop-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--workspace-header-height));\n}\n\n$breakpoint-phone-min: 0px;\n$breakpoint-phone-max: 600px;\n$breakpoint-tablet-min: 601px;\n$breakpoint-tablet-max: 1023px;\n$breakpoint-small-desktop-min: 1024px;\n$breakpoint-small-desktop-max: 1439px;\n$breakpoint-large-desktop-min: 1440px;\n$breakpoint-large-desktop-max: 99999999px;\n\n/* These color variables will be removed in a future release */\n$brand-teal-01: #007d79;\n$brand-01: #005d5d;\n$brand-02: #004144;\n","@use '@carbon/type';\n@use '@carbon/layout';\n@use '@openmrs/esm-styleguide/src/vars' as *;\n\n.loading {\n margin-left: 1rem;\n width: 2rem;\n min-height: 2.5rem;\n}\n\n.button {\n height: 4rem;\n display: flex;\n align-content: flex-start;\n align-items: baseline;\n min-width: 50%;\n\n :global(.cds--inline-loading__text) {\n @include type.type-style('body-01');\n }\n}\n\n.tablet {\n padding: 1.5rem 1rem;\n background-color: $ui-02;\n}\n\n.desktop {\n padding: 0rem;\n}\n\n.formContainer {\n margin: 1rem;\n}\n\n.form {\n display: flex;\n flex-direction: column;\n justify-content: space-between;\n height: 100%;\n}\n\n.errorMessage {\n @include type.type-style(\"label-02\");\n margin-top: layout.$spacing-03;\n color: $danger;\n}\n\n.notification {\n margin: 0;\n min-width: 100%;\n padding: 0;\n}\n","//\n// Copyright IBM Corp. 2018, 2023\n//\n// This source code is licensed under the Apache-2.0 license found in the\n// LICENSE file in the root directory of this source tree.\n//\n\n// stylelint-disable number-max-precision\n\n@use 'sass:map';\n@use 'sass:math';\n@use '@carbon/grid/scss/config' as gridconfig;\n@use '@carbon/grid/scss/breakpoint' as grid;\n@use 'prefix' as *;\n@use 'font-family';\n@use 'scale';\n\n/// @type Map\n/// @access public\n/// @deprecated\n/// @group @carbon/type\n$caption-01: (\n font-size: scale.type-scale(1),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.33333,\n letter-spacing: 0.32px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @deprecated\n/// @group @carbon/type\n$caption-02: (\n font-size: scale.type-scale(2),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.28572,\n letter-spacing: 0.32px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$label-01: (\n font-size: scale.type-scale(1),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.33333,\n letter-spacing: 0.32px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$label-02: (\n font-size: scale.type-scale(2),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.28572,\n letter-spacing: 0.16px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$legal-01: (\n font-size: scale.type-scale(1),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.33333,\n letter-spacing: 0.32px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$legal-02: (\n font-size: scale.type-scale(2),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.28572,\n letter-spacing: 0.16px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @deprecated\n/// @group @carbon/type\n$helper-text-01: (\n font-size: scale.type-scale(1),\n line-height: 1.33333,\n letter-spacing: 0.32px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @deprecated\n/// @group @carbon/type\n$helper-text-02: (\n font-size: scale.type-scale(2),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.28572,\n letter-spacing: 0.16px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$body-short-01: (\n font-size: scale.type-scale(2),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.28572,\n letter-spacing: 0.16px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$body-compact-01: $body-short-01 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$body-long-01: (\n font-size: scale.type-scale(2),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.42857,\n letter-spacing: 0.16px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$body-01: $body-long-01 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$body-short-02: (\n font-size: scale.type-scale(3),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.375,\n letter-spacing: 0,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$body-compact-02: $body-short-02 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$body-long-02: (\n font-size: scale.type-scale(3),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.5,\n letter-spacing: 0,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$body-02: $body-long-02 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$code-01: (\n font-family: font-family.font-family('mono'),\n font-size: scale.type-scale(1),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.33333,\n letter-spacing: 0.32px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$code-02: (\n font-family: font-family.font-family('mono'),\n font-size: scale.type-scale(2),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.42857,\n letter-spacing: 0.32px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$heading-01: (\n font-size: scale.type-scale(2),\n font-weight: font-family.font-weight('semibold'),\n line-height: 1.42857,\n letter-spacing: 0.16px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$productive-heading-01: (\n font-size: scale.type-scale(2),\n font-weight: font-family.font-weight('semibold'),\n line-height: 1.28572,\n letter-spacing: 0.16px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$heading-compact-01: $productive-heading-01 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$heading-02: (\n font-size: scale.type-scale(3),\n font-weight: font-family.font-weight('semibold'),\n line-height: 1.5,\n letter-spacing: 0,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$productive-heading-02: (\n font-size: scale.type-scale(3),\n font-weight: font-family.font-weight('semibold'),\n line-height: 1.375,\n letter-spacing: 0,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$heading-compact-02: $productive-heading-02 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$productive-heading-03: (\n font-size: scale.type-scale(5),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.4,\n letter-spacing: 0,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$heading-03: $productive-heading-03 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$productive-heading-04: (\n font-size: scale.type-scale(7),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.28572,\n letter-spacing: 0,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$heading-04: $productive-heading-04 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$productive-heading-05: (\n font-size: scale.type-scale(8),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.25,\n letter-spacing: 0,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$heading-05: $productive-heading-05 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$productive-heading-06: (\n font-size: scale.type-scale(10),\n font-weight: font-family.font-weight('light'),\n // Extra digit needed for precision in Chrome\n line-height: 1.199,\n letter-spacing: 0,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$heading-06: $productive-heading-06 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$productive-heading-07: (\n font-size: scale.type-scale(12),\n font-weight: font-family.font-weight('light'),\n line-height: 1.19,\n letter-spacing: 0,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$heading-07: $productive-heading-07 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$expressive-heading-01: $heading-01 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$expressive-heading-02: $heading-02 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$expressive-heading-03: (\n font-size: scale.type-scale(5),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.4,\n letter-spacing: 0,\n breakpoints: (\n xlg: (\n font-size: scale.type-scale(5),\n line-height: 1.4,\n ),\n max: (\n font-size: scale.type-scale(6),\n line-height: 1.334,\n ),\n ),\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$fluid-heading-03: $expressive-heading-03 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$expressive-heading-04: (\n font-size: scale.type-scale(7),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.28572,\n letter-spacing: 0,\n breakpoints: (\n xlg: (\n font-size: scale.type-scale(8),\n line-height: 1.25,\n font-weight: font-family.font-weight('regular'),\n ),\n max: (\n font-size: scale.type-scale(8),\n font-weight: font-family.font-weight('regular'),\n ),\n ),\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$fluid-heading-04: $expressive-heading-04 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$expressive-heading-05: (\n font-size: scale.type-scale(8),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.25,\n letter-spacing: 0,\n breakpoints: (\n md: (\n font-size: scale.type-scale(9),\n font-weight: font-family.font-weight('light'),\n line-height: 1.22,\n ),\n lg: (\n font-size: scale.type-scale(10),\n line-height: 1.19,\n ),\n xlg: (\n font-size: scale.type-scale(11),\n line-height: 1.17,\n ),\n max: (\n font-size: scale.type-scale(13),\n ),\n ),\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$fluid-heading-05: $expressive-heading-05 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$expressive-heading-06: (\n font-size: scale.type-scale(8),\n font-weight: font-family.font-weight('semibold'),\n line-height: 1.25,\n letter-spacing: 0,\n breakpoints: (\n md: (\n font-size: scale.type-scale(9),\n line-height: 1.22,\n ),\n lg: (\n font-size: scale.type-scale(10),\n line-height: 1.19,\n ),\n xlg: (\n font-size: scale.type-scale(11),\n line-height: 1.17,\n ),\n max: (\n font-size: scale.type-scale(13),\n ),\n ),\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$fluid-heading-06: $expressive-heading-06 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$expressive-paragraph-01: (\n font-size: scale.type-scale(6),\n font-weight: font-family.font-weight('light'),\n line-height: 1.334,\n letter-spacing: 0,\n breakpoints: (\n lg: (\n font-size: scale.type-scale(7),\n line-height: 1.28572,\n ),\n max: (\n font-size: scale.type-scale(8),\n line-height: 1.25,\n ),\n ),\n);\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$fluid-paragraph-01: $expressive-paragraph-01 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$quotation-01: (\n font-family: font-family.font-family('serif'),\n font-size: scale.type-scale(5),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.3,\n letter-spacing: 0,\n breakpoints: (\n md: (\n font-size: scale.type-scale(5),\n ),\n lg: (\n font-size: scale.type-scale(6),\n line-height: 1.334,\n ),\n xlg: (\n font-size: scale.type-scale(7),\n line-height: 1.28572,\n ),\n max: (\n font-size: scale.type-scale(8),\n line-height: 1.25,\n ),\n ),\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$fluid-quotation-01: $quotation-01 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$quotation-02: (\n font-family: font-family.font-family('serif'),\n font-size: scale.type-scale(8),\n font-weight: font-family.font-weight('light'),\n line-height: 1.25,\n letter-spacing: 0,\n breakpoints: (\n md: (\n font-size: scale.type-scale(9),\n line-height: 1.22,\n ),\n lg: (\n font-size: scale.type-scale(10),\n line-height: 1.19,\n ),\n xlg: (\n font-size: scale.type-scale(11),\n line-height: 1.17,\n ),\n max: (\n font-size: scale.type-scale(13),\n ),\n ),\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$fluid-quotation-02: $quotation-02 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$display-01: (\n font-size: scale.type-scale(10),\n font-weight: font-family.font-weight('light'),\n line-height: 1.19,\n letter-spacing: 0,\n breakpoints: (\n md: (\n font-size: scale.type-scale(10),\n ),\n lg: (\n font-size: scale.type-scale(12),\n ),\n xlg: (\n font-size: scale.type-scale(13),\n line-height: 1.17,\n ),\n max: (\n font-size: scale.type-scale(15),\n line-height: 1.13,\n ),\n ),\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$fluid-display-01: $display-01 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$display-02: (\n font-size: scale.type-scale(10),\n font-weight: font-family.font-weight('semibold'),\n line-height: 1.19,\n letter-spacing: 0,\n breakpoints: (\n md: (\n font-size: scale.type-scale(10),\n ),\n lg: (\n font-size: scale.type-scale(12),\n ),\n xlg: (\n font-size: scale.type-scale(13),\n line-height: 1.16,\n ),\n max: (\n font-size: scale.type-scale(15),\n line-height: 1.13,\n ),\n ),\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$fluid-display-02: $display-02 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$display-03: (\n font-size: scale.type-scale(10),\n font-weight: font-family.font-weight('light'),\n line-height: 1.19,\n letter-spacing: 0,\n breakpoints: (\n md: (\n font-size: scale.type-scale(12),\n line-height: 1.18,\n ),\n lg: (\n font-size: scale.type-scale(13),\n line-height: 1.16,\n letter-spacing: -0.64px,\n ),\n xlg: (\n font-size: scale.type-scale(15),\n line-height: 1.13,\n letter-spacing: -0.64px,\n ),\n max: (\n font-size: scale.type-scale(16),\n line-height: 1.11,\n letter-spacing: -0.96px,\n ),\n ),\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$fluid-display-03: $display-03 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$display-04: (\n font-size: scale.type-scale(10),\n font-weight: font-family.font-weight('light'),\n line-height: 1.19,\n letter-spacing: 0,\n breakpoints: (\n md: (\n font-size: scale.type-scale(14),\n line-height: 1.15,\n ),\n lg: (\n font-size: scale.type-scale(17),\n line-height: 1.11,\n letter-spacing: -0.64px,\n ),\n xlg: (\n font-size: scale.type-scale(20),\n line-height: 1.07,\n letter-spacing: -0.64px,\n ),\n max: (\n font-size: scale.type-scale(23),\n line-height: 1.05,\n letter-spacing: -0.96px,\n ),\n ),\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$fluid-display-04: $display-04 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$tokens: (\n caption-01: $caption-01,\n caption-02: $caption-02,\n label-01: $label-01,\n label-02: $label-02,\n helper-text-01: $helper-text-01,\n helper-text-02: $helper-text-02,\n body-short-01: $body-short-01,\n body-short-02: $body-short-02,\n body-long-01: $body-long-01,\n body-long-02: $body-long-02,\n code-01: $code-01,\n code-02: $code-02,\n heading-01: $heading-01,\n heading-02: $heading-02,\n productive-heading-01: $productive-heading-01,\n productive-heading-02: $productive-heading-02,\n productive-heading-03: $productive-heading-03,\n productive-heading-04: $productive-heading-04,\n productive-heading-05: $productive-heading-05,\n productive-heading-06: $productive-heading-06,\n productive-heading-07: $productive-heading-07,\n expressive-paragraph-01: $expressive-paragraph-01,\n expressive-heading-01: $expressive-heading-01,\n expressive-heading-02: $expressive-heading-02,\n expressive-heading-03: $expressive-heading-03,\n expressive-heading-04: $expressive-heading-04,\n expressive-heading-05: $expressive-heading-05,\n expressive-heading-06: $expressive-heading-06,\n quotation-01: $quotation-01,\n quotation-02: $quotation-02,\n display-01: $display-01,\n display-02: $display-02,\n display-03: $display-03,\n display-04: $display-04,\n // V11 Tokens\n legal-01: $legal-01,\n legal-02: $legal-02,\n body-compact-01: $body-compact-01,\n body-compact-02: $body-compact-02,\n heading-compact-01: $heading-compact-01,\n heading-compact-02: $heading-compact-02,\n body-01: $body-01,\n body-02: $body-02,\n heading-03: $heading-03,\n heading-04: $heading-04,\n heading-05: $heading-05,\n heading-06: $heading-06,\n heading-07: $heading-07,\n fluid-heading-03: $fluid-heading-03,\n fluid-heading-04: $fluid-heading-04,\n fluid-heading-05: $fluid-heading-05,\n fluid-heading-06: $fluid-heading-06,\n fluid-paragraph-01: $fluid-paragraph-01,\n fluid-quotation-01: $fluid-quotation-01,\n fluid-quotation-02: $fluid-quotation-02,\n fluid-display-01: $fluid-display-01,\n fluid-display-02: $fluid-display-02,\n fluid-display-03: $fluid-display-03,\n fluid-display-04: $fluid-display-04,\n) !default;\n\n/// @param {Map} $map\n/// @access public\n/// @group @carbon/type\n@mixin properties($map) {\n @each $name, $value in $map {\n #{$name}: $value;\n }\n}\n\n/// @param {Number} $value - Number with units\n/// @return {Number} Without units\n/// @access public\n/// @group @carbon/type\n@function strip-unit($value) {\n @return math.div($value, $value * 0 + 1);\n}\n\n/// This helper includes fluid type styles for the given token value. Fluid type\n/// means that the `font-size` is computed using `calc()` in order to be\n/// determined by the screen size instead of a breakpoint. As a result, fluid\n/// styles should be used with caution in fixed width contexts.\n///\n/// In addition, we make use of %-based line-heights so that the line-height of\n/// each type style is computed correctly due to the dynamic nature of the\n/// `font-size`.\n///\n/// Most of the logic for this work comes from CSS Tricks:\n/// https://css-tricks.com/snippets/css/fluid-typography/\n///\n/// @param {Map} $type-styles - The value of a given type token\n/// @param {Map} $breakpoints [$grid-breakpoints] - Custom breakpoints to use\n/// @access public\n/// @group @carbon/type\n@mixin fluid-type($type-styles, $breakpoints: gridconfig.$grid-breakpoints) {\n // Include the initial styles for the given token by default without any\n // media query guard. This includes `font-size` as a fallback in the case\n // that a browser does not support `calc()`\n @include properties(map.remove($type-styles, breakpoints));\n // We also need to include the `sm` styles by default since they don't\n // appear in the fluid styles for tokens\n @include fluid-type-size($type-styles, sm, $breakpoints);\n\n // Finally, we need to go through all the breakpoints defined in the type\n // token and apply the properties and fluid type size for that given\n // breakpoint\n @each $name, $values in map.get($type-styles, breakpoints) {\n @include grid.breakpoint($name) {\n @include properties($values);\n @include fluid-type-size($type-styles, $name, $breakpoints);\n }\n }\n}\n\n/// Computes the fluid `font-size` for a given type style and breakpoint\n/// @param {Map} $type-styles - The styles for a given token\n/// @param {String} $name - The name of the breakpoint to which we apply the fluid\n/// @param {Map} $breakpoints [$grid-breakpoints] - The breakpoints for the grid system\n/// @access public\n/// @group @carbon/type\n@mixin fluid-type-size(\n $type-styles,\n $name,\n $breakpoints: gridconfig.$grid-breakpoints\n) {\n // Get the information about the breakpoint we're currently working in. Useful\n // for getting initial width information\n $breakpoint: map.get($breakpoints, $name);\n\n // Our fluid styles are captured under the 'breakpoints' property in our type\n // styles map. These define what values to treat as `max-` variables below\n $fluid-sizes: map.get($type-styles, breakpoints);\n $fluid-breakpoint: ();\n // Special case for `sm` because the styles for small are on the type style\n // directly\n @if $name == sm {\n $fluid-breakpoint: map.remove($type-styles, breakpoints);\n } @else {\n $fluid-breakpoint: map.get($fluid-sizes, $name);\n }\n\n // Initialize our font-sizes to the default size for the type style\n $max-font-size: map.get($type-styles, font-size);\n $min-font-size: map.get($type-styles, font-size);\n @if map.has-key($fluid-breakpoint, font-size) {\n $min-font-size: map.get($fluid-breakpoint, font-size);\n }\n\n // Initialize our min and max width to the width of the current breakpoint\n $max-vw: map.get($breakpoint, width);\n $min-vw: map.get($breakpoint, width);\n\n // We can use `breakpoint-next` to see if there is another breakpoint we can\n // use to update `max-font-size` and `max-vw` with larger values\n $next-breakpoint-available: grid.breakpoint-next($name, $breakpoints);\n $next-fluid-breakpoint-name: null;\n\n // We need to figure out what the next available fluid breakpoint is for our\n // given $type-styles. In this loop we try and iterate through breakpoints\n // until we either manually set $next-breakpoint-available to null or\n // `breakpoint-next` returns null.\n @while $next-breakpoint-available {\n @if map.has-key($fluid-sizes, $next-breakpoint-available) {\n $next-fluid-breakpoint-name: $next-breakpoint-available;\n $next-breakpoint-available: null;\n } @else {\n $next-breakpoint-available: grid.breakpoint-next(\n $next-breakpoint-available,\n $breakpoints\n );\n }\n }\n\n // If we have found the next available fluid breakpoint name, then we know\n // that we have values that we can use to set max-font-size and max-vw as both\n // values derive from the next breakpoint\n @if $next-fluid-breakpoint-name {\n $next-fluid-breakpoint: map.get($breakpoints, $next-fluid-breakpoint-name);\n $max-font-size: map.get(\n map.get($fluid-sizes, $next-fluid-breakpoint-name),\n font-size\n );\n $max-vw: map.get($next-fluid-breakpoint, width);\n\n // prettier-ignore\n font-size: calc(#{$min-font-size} +\n #{strip-unit($max-font-size - $min-font-size)} *\n ((100vw - #{$min-vw}) / #{strip-unit($max-vw - $min-vw)})\n );\n } @else {\n // Otherwise, just default to setting the font size found from the type\n // style or the given fluid breakpoint in the type style\n font-size: $min-font-size;\n }\n}\n\n// TODO move following variable and `custom-property` mixin into shared file for\n// both `@carbon/type` and `@carbon/themes`\n\n/// @access private\n/// @group @carbon/type\n@mixin custom-properties($name, $value) {\n @each $property, $value in $value {\n #{$property}: var(\n --#{$custom-property-prefix}-#{$name}-#{$property},\n #{$value}\n );\n }\n}\n\n/// Helper mixin to include the styles for a given token in any selector in your\n/// project. Also includes an optional fluid option that will enable fluid\n/// styles for the token if they are defined. Fluid styles will cause the\n/// token's font-size to be computed based on the viewport size. As a result, use\n/// with caution in fixed contexts.\n/// @param {String} $name - The name of the token to get the styles for\n/// @param {Boolean} $fluid [false] - Specify whether to include fluid styles for the\n/// @param {Map} $breakpoints [$grid-breakpoints] - Provide a custom breakpoint map to use\n/// @access public\n/// @group @carbon/type\n@mixin type-style(\n $name,\n $fluid: false,\n $breakpoints: gridconfig.$grid-breakpoints\n) {\n @if not map.has-key($tokens, $name) {\n @error 'Unable to find a token with the name: `#{$name}`';\n }\n\n $token: map.get($tokens, $name);\n\n // If $fluid is set to true and the token has breakpoints defined for fluid\n // styles, delegate to the fluid-type helper for the given token\n @if $fluid == true and map.has-key($token, 'breakpoints') {\n @include fluid-type($token, $breakpoints);\n } @else {\n @include custom-properties($name, $token);\n }\n}\n","// Code generated by @carbon/layout. DO NOT EDIT.\n//\n// Copyright IBM Corp. 2018, 2023\n//\n// This source code is licensed under the Apache-2.0 license found in the\n// LICENSE file in the root directory of this source tree.\n//\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-01: 0.125rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-02: 0.25rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-03: 0.5rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-04: 0.75rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-05: 1rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-06: 1.5rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-07: 2rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-08: 2.5rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-09: 3rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-10: 4rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-11: 5rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-12: 6rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-13: 10rem !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/layout\n$spacing: (\n spacing-01: $spacing-01,\n spacing-02: $spacing-02,\n spacing-03: $spacing-03,\n spacing-04: $spacing-04,\n spacing-05: $spacing-05,\n spacing-06: $spacing-06,\n spacing-07: $spacing-07,\n spacing-08: $spacing-08,\n spacing-09: $spacing-09,\n spacing-10: $spacing-10,\n spacing-11: $spacing-11,\n spacing-12: $spacing-12,\n spacing-13: $spacing-13,\n);\n"],sourceRoot:""}]),r.locals={loading:"-esm-patient-programs__programs-form__loading___Udyd1",button:"-esm-patient-programs__programs-form__button___+EibT",tablet:"-esm-patient-programs__programs-form__tablet___F8bMH",desktop:"-esm-patient-programs__programs-form__desktop___Xlimz",formContainer:"-esm-patient-programs__programs-form__formContainer___0TBLb",form:"-esm-patient-programs__programs-form__form___AHDMX",errorMessage:"-esm-patient-programs__programs-form__errorMessage___JQ2u-",notification:"-esm-patient-programs__programs-form__notification___9QK0m"};const l=r},1577:(e,n,t)=>{t.r(n),t.d(n,{default:()=>B});var a=t(268),i=t.n(a),o=t(4924),r=t(3565),l=t.n(r),s=t(8219),p=t(195),c=t(3955),u=t(8883),d=t(2870),g=t(8101),f=t(321),h=t.n(f),m=t(1195),y=t.n(m),b=t(3275),$=t.n(b),v=t(7162),w=t.n(v),A=t(2094),k=t.n(A),x=t(757),_=t.n(x),z=t(9015),C={};C.styleTagTransform=_(),C.setAttributes=w(),C.insert=$().bind(null,"head"),C.domAPI=y(),C.insertStyleElement=k(),h()(z.Z,C);const M=z.Z&&z.Z.locals?z.Z.locals:void 0;function E(e,n){(null==n||n>e.length)&&(n=e.length);for(var t=0,a=new Array(n);t<n;t++)a[t]=e[t];return a}function D(e,n,t,a,i,o,r){try{var l=e[o](r),s=l.value}catch(e){return void t(e)}l.done?n(s):Promise.resolve(s).then(a,i)}function S(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function T(e,n){return function(e){if(Array.isArray(e))return e}(e)||function(e,n){var t=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=t){var a,i,o=[],r=!0,l=!1;try{for(t=t.call(e);!(r=(a=t.next()).done)&&(o.push(a.value),!n||o.length!==n);r=!0);}catch(e){l=!0,i=e}finally{try{r||null==t.return||t.return()}finally{if(l)throw i}}return o}}(e,n)||function(e,n){if(e){if("string"==typeof e)return E(e,n);var t=Object.prototype.toString.call(e).slice(8,-1);return"Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t?Array.from(t):"Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?E(e,n):void 0}}(e,n)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}const B=function(e){var n,t,r,f,h,m=e.closeWorkspace,y=e.closeWorkspaceWithSavedChanges,b=e.patientUuid,$=e.programEnrollmentId,v=e.promptBeforeClosing,w=(0,o.useTranslation)().t,A="tablet"===(0,d.useLayoutType)(),k=(0,d.useSession)(),x=(0,d.useLocations)(),_=(0,g.oI)().data,z=(0,g.Bw)(b),C=z.data,E=z.mutateEnrollments,B=T((0,a.useState)(!1),2),N=B[0],I=B[1],P=(0,a.useMemo)((function(){return function(e){return p.z.object({selectedProgram:p.z.string().refine((function(e){return!!e}),e("programRequired","Program is required")),enrollmentDate:p.z.date(),completionDate:p.z.date().nullable(),enrollmentLocation:p.z.string()})}(w)}),[w]),F=$&&C.filter((function(e){return e.uuid===$}))[0],q=F?function(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{},a=Object.keys(t);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(t).filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})))),a.forEach((function(n){S(e,n,t[n])}))}return e}({display:F.program.name},F.program):null,O=q?[q]:_.filter((function(e){var n=C.find((function(n){return n.program.uuid===e.uuid}));return!n||null!==n.dateCompleted})),j=(0,c.cI)({mode:"all",resolver:(0,u.F)(P),defaultValues:{selectedProgram:null!==(n=null==F?void 0:F.program.uuid)&&void 0!==n?n:"",enrollmentDate:(null==F?void 0:F.dateEnrolled)?(0,d.parseDate)(F.dateEnrolled):new Date,completionDate:(null==F?void 0:F.dateCompleted)?(0,d.parseDate)(F.dateCompleted):null,enrollmentLocation:null!==(t=!(null==F?void 0:F.location.uuid)&&(null==k||null===(r=k.sessionLocation)||void 0===r?void 0:r.uuid)?null==k||null===(f=k.sessionLocation)||void 0===f?void 0:f.uuid:null!==(h=null==F?void 0:F.location.uuid)&&void 0!==h?h:null)&&void 0!==t?t:""}}),L=j.control,W=j.handleSubmit,Q=j.watch,U=j.formState.isDirty;(0,a.useEffect)((function(){v((function(){return U}))}),[U,v]);var G,H,X=(0,a.useCallback)((G=function(e){var n,t,a,i,o,r,s;return function(e,n){var t,a,i,o,r={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function l(o){return function(l){return function(o){if(t)throw new TypeError("Generator is already executing.");for(;r;)try{if(t=1,a&&(i=2&o[0]?a.return:o[0]?a.throw||((i=a.return)&&i.call(a),0):a.next)&&!(i=i.call(a,o[1])).done)return i;switch(a=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return r.label++,{value:o[1],done:!1};case 5:r.label++,a=o[1],o=[0];continue;case 7:o=r.ops.pop(),r.trys.pop();continue;default:if(!((i=(i=r.trys).length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){r=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){r.label=o[1];break}if(6===o[0]&&r.label<i[1]){r.label=i[1],i=o;break}if(i&&r.label<i[2]){r.label=i[2],r.ops.push(o);break}i[2]&&r.ops.pop(),r.trys.pop();continue}o=n.call(e,r)}catch(e){o=[6,e],a=0}finally{t=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,l])}}}(this,(function(p){switch(p.label){case 0:n=e.selectedProgram,t=e.enrollmentDate,a=e.completionDate,i=e.enrollmentLocation,o={patient:b,program:n,dateEnrolled:t?l()(t).format():null,dateCompleted:a?l()(a).format():null,location:i},p.label=1;case 1:return p.trys.push([1,7,,8]),r=new AbortController,F?[4,(0,g.YX)(F.uuid,o,r)]:[3,3];case 2:return p.sent(),[3,5];case 3:return[4,(0,g.df)(o,r)];case 4:p.sent(),p.label=5;case 5:return[4,E()];case 6:return p.sent(),y(),(0,d.showSnackbar)({kind:"success",title:F?w("enrollmentUpdated","Program enrollment updated"):w("enrollmentSaved","Program enrollment saved"),subtitle:F?w("enrollmentUpdatesNowVisible","Changes to the program are now visible in the Programs table"):w("enrollmentNowVisible","It is now visible in the Programs table")}),[3,8];case 7:return s=p.sent(),(0,d.showSnackbar)({kind:"error",title:w("programEnrollmentSaveError","Error saving program enrollment"),subtitle:(c=s,u=Error,(null!=u&&"undefined"!=typeof Symbol&&u[Symbol.hasInstance]?u[Symbol.hasInstance](c):c instanceof u)?s.message:"An unknown error occurred")}),[3,8];case 8:return I(!1),[2]}var c,u}))},H=function(){var e=this,n=arguments;return new Promise((function(t,a){var i=G.apply(e,n);function o(e){D(i,t,a,o,r,"next",e)}function r(e){D(i,t,a,o,r,"throw",e)}o(void 0)}))},function(e){return H.apply(this,arguments)}),[y,F,E,b,w]),Y=i().createElement(c.Qr,{name:"selectedProgram",control:L,render:function(e){var n,t=e.fieldState,a=e.field,o=a.onChange,r=a.value;return i().createElement(i().Fragment,null,i().createElement(s.PhF,{"aria-label":"program name",id:"program",invalid:!!(null==t?void 0:t.error),labelText:w("programName","Program name"),onChange:function(e){return o(e.target.value)},value:r},i().createElement(s.QlF,{text:w("chooseProgram","Choose a program"),value:""}),(null==O?void 0:O.length)>0&&O.map((function(e){return i().createElement(s.QlF,{key:e.uuid,text:e.display,value:e.uuid},e.display)}))),i().createElement("p",{className:M.errorMessage},null==t||null===(n=t.error)||void 0===n?void 0:n.message))}}),V=i().createElement(c.Qr,{name:"enrollmentDate",control:L,render:function(e){var n=e.field,t=n.onChange,a=n.value;return i().createElement(s.Mtg,{"aria-label":"enrollment date",id:"enrollmentDate",datePickerType:"single",dateFormat:"d/m/Y",maxDate:(new Date).toISOString(),placeholder:"dd/mm/yyyy",onChange:function(e){var n=T(e,1)[0];return t(n)},value:a},i().createElement(s.aj6,{id:"enrollmentDateInput",labelText:w("dateEnrolled","Date enrolled")}))}}),Z=i().createElement(c.Qr,{name:"completionDate",control:L,render:function(e){var n=e.field,t=n.onChange,a=n.value;return i().createElement(s.Mtg,{"aria-label":"completion date",id:"completionDate",datePickerType:"single",dateFormat:"d/m/Y",minDate:new Date(Q("enrollmentDate")).toISOString(),maxDate:(new Date).toISOString(),placeholder:"dd/mm/yyyy",onChange:function(e){var n=T(e,1)[0];return t(n)},value:a},i().createElement(s.aj6,{id:"completionDateInput",labelText:w("dateCompleted","Date completed")}))}}),K=i().createElement(c.Qr,{name:"enrollmentLocation",control:L,render:function(e){var n=e.field,t=n.onChange,a=n.value;return i().createElement(s.PhF,{"aria-label":"enrollment location",id:"location",labelText:w("enrollmentLocation","Enrollment location"),onChange:function(e){return t(e.target.value)},value:a},(null==x?void 0:x.length)>0&&x.map((function(e){return i().createElement(s.QlF,{key:e.uuid,text:e.display,value:e.uuid},e.display)})))}}),J=[{style:{maxWidth:A&&"50%"},legendText:"",value:Y},{style:{maxWidth:"50%"},legendText:"",value:V},{style:{width:"50%"},legendText:"",value:Z},{style:{width:"50%"},legendText:"",value:K}];return i().createElement(s.l09,{className:M.form,onSubmit:W(X)},i().createElement(s.Kqy,{className:M.formContainer,gap:7},!_.length&&i().createElement(s.K0D,{className:M.notification,kind:"error",lowContrast:!0,subtitle:w("configurePrograms","Please configure programs to continue."),title:w("noProgramsConfigured","No programs configured")}),J.map((function(e,n){return i().createElement(s.cwH,{style:e.style,legendText:e.legendText,key:n},i().createElement("div",{className:M.selectContainer},A?i().createElement(s.mh4,null,e.value):e.value))}))),i().createElement(s.uVA,{className:A?M.tablet:M.desktop},i().createElement(s.zxk,{className:M.button,kind:"secondary",onClick:m},w("cancel","Cancel")),i().createElement(s.zxk,{className:M.button,kind:"primary",type:"submit"},N?i().createElement(s.lSo,{description:w("saving","Saving")+"..."}):i().createElement("span",null,w("saveAndClose","Save and close")))))}}}]);
|
|
1
|
+
"use strict";(globalThis.webpackChunk_openmrs_esm_patient_programs_app=globalThis.webpackChunk_openmrs_esm_patient_programs_app||[]).push([[577],{9015:(e,n,t)=>{t.d(n,{Z:()=>l});var a=t(5698),i=t.n(a),o=t(9613),r=t.n(o)()(i());r.push([e.id,":root{--brand-01: #005d5d;--brand-02: #004144;--brand-03: #007d79;--bottom-nav-height: 4rem;--workspace-header-height: 3rem;--tablet-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--bottom-nav-height));--desktop-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--workspace-header-height))}.-esm-patient-programs__programs-form__loading___Udyd1{margin-left:1rem;width:2rem;min-height:2.5rem}.-esm-patient-programs__programs-form__button___\\+EibT{height:4rem;display:flex;align-content:flex-start;align-items:baseline;min-width:50%}.-esm-patient-programs__programs-form__button___\\+EibT .cds--inline-loading__text{font-size:var(--cds-body-01-font-size, 0.875rem);font-weight:var(--cds-body-01-font-weight, 400);line-height:var(--cds-body-01-line-height, 1.42857);letter-spacing:var(--cds-body-01-letter-spacing, 0.16px)}.-esm-patient-programs__programs-form__tablet___F8bMH{padding:1.5rem 1rem;background-color:#fff}.-esm-patient-programs__programs-form__desktop___Xlimz{padding:0}.-esm-patient-programs__programs-form__formContainer___0TBLb{margin:1rem}.-esm-patient-programs__programs-form__form___AHDMX{display:flex;flex-direction:column;justify-content:space-between;height:100%}.-esm-patient-programs__programs-form__errorMessage___JQ2u-{font-size:var(--cds-label-02-font-size, 0.875rem);font-weight:var(--cds-label-02-font-weight, 400);line-height:var(--cds-label-02-line-height, 1.28572);letter-spacing:var(--cds-label-02-letter-spacing, 0.16px);margin-top:.5rem;color:#da1e28}.-esm-patient-programs__programs-form__notification___9QK0m{margin:0;min-width:100%;padding:0}","",{version:3,sources:["webpack://./../../node_modules/@openmrs/esm-styleguide/src/_vars.scss","webpack://./src/programs/programs-form.scss","webpack://./../../node_modules/@carbon/layout/scss/generated/_spacing.scss","webpack://./../../node_modules/@carbon/type/scss/_styles.scss"],names:[],mappings:"AAoDA,MACE,mBAAA,CACA,mBAAA,CACA,mBAAA,CACA,yBAAA,CACA,+BAAA,CACA,oGAAA,CACA,2GAAA,CCvDF,uDACE,gBC0BW,CDzBX,UCmCW,CDlCX,iBCuCW,CDpCb,uDACE,WC6CW,CD5CX,YAAA,CACA,wBAAA,CACA,oBAAA,CACA,aAAA,CAEA,kFEi1BE,gDAAA,CAAA,+CAAA,CAAA,mDAAA,CAAA,wDAAA,CF50BJ,sDACE,mBAAA,CACA,qBDvBM,CC0BR,uDACE,SAAA,CAGF,6DACE,WCDW,CDIb,oDACE,YAAA,CACA,qBAAA,CACA,6BAAA,CACA,WAAA,CAGF,4DEwzBI,iDAAA,CAAA,gDAAA,CAAA,oDAAA,CAAA,yDAAA,CFtzBF,gBCvBW,CDwBX,aDzBO,CC4BT,4DACE,QAAA,CACA,cAAA,CACA,SAAA",sourcesContent:["$ui-01: #f4f4f4;\n$ui-02: #ffffff;\n$ui-03: #e0e0e0;\n$ui-04: #8d8d8d;\n$ui-05: #161616;\n$text-02: #525252;\n$text-03: #a8a8a8;\n$ui-background: #ffffff;\n$color-gray-30: #c6c6c6;\n$color-gray-70: #525252;\n$color-gray-100: #161616;\n$color-blue-60-2: #0f62fe;\n$color-blue-10: #edf5ff;\n$color-yellow-50: #feecae;\n$carbon--red-50: #fa4d56;\n$inverse-link: #78a9ff;\n$support-02: #24a148;\n$inverse-support-03: #f1c21b;\n$warning-background: #fff8e1;\n$openmrs-background-grey: #f4f4f4;\n$danger: #da1e28;\n$interactive-01: #0f62fe;\n$field-01: #f4f4f4;\n$grey-2: #e0e0e0;\n$labeldropdown: #c6c6c6;\n\n$brand-primary-10: #d9fbfb;\n$brand-primary-20: #9ef0f0;\n$brand-primary-30: #3ddbd9;\n$brand-primary-40: #08bdba;\n$brand-primary-50: #009d9a;\n\n/* 60,70 and 80 are already declared as brand-01, 02 and 03 respectively */\n\n$brand-primary-90: #022b30;\n$brand-primary-100: #081a1c;\n\n@mixin brand-01($property) {\n #{$property}: #005d5d;\n #{$property}: var(--brand-01);\n}\n\n@mixin brand-02($property) {\n #{$property}: #004144;\n #{$property}: var(--brand-02);\n}\n\n@mixin brand-03($property) {\n #{$property}: #007d79;\n #{$property}: var(--brand-03);\n}\n\n:root {\n --brand-01: #005d5d;\n --brand-02: #004144;\n --brand-03: #007d79;\n --bottom-nav-height: 4rem;\n --workspace-header-height: 3rem;\n --tablet-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--bottom-nav-height));\n --desktop-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--workspace-header-height));\n}\n\n$breakpoint-phone-min: 0px;\n$breakpoint-phone-max: 600px;\n$breakpoint-tablet-min: 601px;\n$breakpoint-tablet-max: 1023px;\n$breakpoint-small-desktop-min: 1024px;\n$breakpoint-small-desktop-max: 1439px;\n$breakpoint-large-desktop-min: 1440px;\n$breakpoint-large-desktop-max: 99999999px;\n\n/* These color variables will be removed in a future release */\n$brand-teal-01: #007d79;\n$brand-01: #005d5d;\n$brand-02: #004144;\n","@use '@carbon/type';\n@use '@carbon/layout';\n@use '@openmrs/esm-styleguide/src/vars' as *;\n\n.loading {\n margin-left: layout.$spacing-05;\n width: layout.$spacing-07;\n min-height: layout.$spacing-08;\n}\n\n.button {\n height: layout.$spacing-10;\n display: flex;\n align-content: flex-start;\n align-items: baseline;\n min-width: 50%;\n\n :global(.cds--inline-loading__text) {\n @include type.type-style('body-01');\n }\n}\n\n.tablet {\n padding: layout.$spacing-06 layout.$spacing-05;\n background-color: $ui-02;\n}\n\n.desktop {\n padding: 0;\n}\n\n.formContainer {\n margin: layout.$spacing-05;\n}\n\n.form {\n display: flex;\n flex-direction: column;\n justify-content: space-between;\n height: 100%;\n}\n\n.errorMessage {\n @include type.type-style('label-02');\n margin-top: layout.$spacing-03;\n color: $danger;\n}\n\n.notification {\n margin: 0;\n min-width: 100%;\n padding: 0;\n}\n","// Code generated by @carbon/layout. DO NOT EDIT.\n//\n// Copyright IBM Corp. 2018, 2023\n//\n// This source code is licensed under the Apache-2.0 license found in the\n// LICENSE file in the root directory of this source tree.\n//\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-01: 0.125rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-02: 0.25rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-03: 0.5rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-04: 0.75rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-05: 1rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-06: 1.5rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-07: 2rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-08: 2.5rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-09: 3rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-10: 4rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-11: 5rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-12: 6rem !default;\n\n/// @type Number\n/// @access public\n/// @group @carbon/layout\n$spacing-13: 10rem !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/layout\n$spacing: (\n spacing-01: $spacing-01,\n spacing-02: $spacing-02,\n spacing-03: $spacing-03,\n spacing-04: $spacing-04,\n spacing-05: $spacing-05,\n spacing-06: $spacing-06,\n spacing-07: $spacing-07,\n spacing-08: $spacing-08,\n spacing-09: $spacing-09,\n spacing-10: $spacing-10,\n spacing-11: $spacing-11,\n spacing-12: $spacing-12,\n spacing-13: $spacing-13,\n);\n","//\n// Copyright IBM Corp. 2018, 2023\n//\n// This source code is licensed under the Apache-2.0 license found in the\n// LICENSE file in the root directory of this source tree.\n//\n\n// stylelint-disable number-max-precision\n\n@use 'sass:map';\n@use 'sass:math';\n@use '@carbon/grid/scss/config' as gridconfig;\n@use '@carbon/grid/scss/breakpoint' as grid;\n@use 'prefix' as *;\n@use 'font-family';\n@use 'scale';\n\n/// @type Map\n/// @access public\n/// @deprecated\n/// @group @carbon/type\n$caption-01: (\n font-size: scale.type-scale(1),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.33333,\n letter-spacing: 0.32px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @deprecated\n/// @group @carbon/type\n$caption-02: (\n font-size: scale.type-scale(2),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.28572,\n letter-spacing: 0.32px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$label-01: (\n font-size: scale.type-scale(1),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.33333,\n letter-spacing: 0.32px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$label-02: (\n font-size: scale.type-scale(2),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.28572,\n letter-spacing: 0.16px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$legal-01: (\n font-size: scale.type-scale(1),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.33333,\n letter-spacing: 0.32px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$legal-02: (\n font-size: scale.type-scale(2),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.28572,\n letter-spacing: 0.16px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @deprecated\n/// @group @carbon/type\n$helper-text-01: (\n font-size: scale.type-scale(1),\n line-height: 1.33333,\n letter-spacing: 0.32px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @deprecated\n/// @group @carbon/type\n$helper-text-02: (\n font-size: scale.type-scale(2),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.28572,\n letter-spacing: 0.16px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$body-short-01: (\n font-size: scale.type-scale(2),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.28572,\n letter-spacing: 0.16px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$body-compact-01: $body-short-01 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$body-long-01: (\n font-size: scale.type-scale(2),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.42857,\n letter-spacing: 0.16px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$body-01: $body-long-01 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$body-short-02: (\n font-size: scale.type-scale(3),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.375,\n letter-spacing: 0,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$body-compact-02: $body-short-02 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$body-long-02: (\n font-size: scale.type-scale(3),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.5,\n letter-spacing: 0,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$body-02: $body-long-02 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$code-01: (\n font-family: font-family.font-family('mono'),\n font-size: scale.type-scale(1),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.33333,\n letter-spacing: 0.32px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$code-02: (\n font-family: font-family.font-family('mono'),\n font-size: scale.type-scale(2),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.42857,\n letter-spacing: 0.32px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$heading-01: (\n font-size: scale.type-scale(2),\n font-weight: font-family.font-weight('semibold'),\n line-height: 1.42857,\n letter-spacing: 0.16px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$productive-heading-01: (\n font-size: scale.type-scale(2),\n font-weight: font-family.font-weight('semibold'),\n line-height: 1.28572,\n letter-spacing: 0.16px,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$heading-compact-01: $productive-heading-01 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$heading-02: (\n font-size: scale.type-scale(3),\n font-weight: font-family.font-weight('semibold'),\n line-height: 1.5,\n letter-spacing: 0,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$productive-heading-02: (\n font-size: scale.type-scale(3),\n font-weight: font-family.font-weight('semibold'),\n line-height: 1.375,\n letter-spacing: 0,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$heading-compact-02: $productive-heading-02 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$productive-heading-03: (\n font-size: scale.type-scale(5),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.4,\n letter-spacing: 0,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$heading-03: $productive-heading-03 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$productive-heading-04: (\n font-size: scale.type-scale(7),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.28572,\n letter-spacing: 0,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$heading-04: $productive-heading-04 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$productive-heading-05: (\n font-size: scale.type-scale(8),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.25,\n letter-spacing: 0,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$heading-05: $productive-heading-05 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$productive-heading-06: (\n font-size: scale.type-scale(10),\n font-weight: font-family.font-weight('light'),\n // Extra digit needed for precision in Chrome\n line-height: 1.199,\n letter-spacing: 0,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$heading-06: $productive-heading-06 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$productive-heading-07: (\n font-size: scale.type-scale(12),\n font-weight: font-family.font-weight('light'),\n line-height: 1.19,\n letter-spacing: 0,\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$heading-07: $productive-heading-07 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$expressive-heading-01: $heading-01 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$expressive-heading-02: $heading-02 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$expressive-heading-03: (\n font-size: scale.type-scale(5),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.4,\n letter-spacing: 0,\n breakpoints: (\n xlg: (\n font-size: scale.type-scale(5),\n line-height: 1.4,\n ),\n max: (\n font-size: scale.type-scale(6),\n line-height: 1.334,\n ),\n ),\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$fluid-heading-03: $expressive-heading-03 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$expressive-heading-04: (\n font-size: scale.type-scale(7),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.28572,\n letter-spacing: 0,\n breakpoints: (\n xlg: (\n font-size: scale.type-scale(8),\n line-height: 1.25,\n font-weight: font-family.font-weight('regular'),\n ),\n max: (\n font-size: scale.type-scale(8),\n font-weight: font-family.font-weight('regular'),\n ),\n ),\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$fluid-heading-04: $expressive-heading-04 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$expressive-heading-05: (\n font-size: scale.type-scale(8),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.25,\n letter-spacing: 0,\n breakpoints: (\n md: (\n font-size: scale.type-scale(9),\n font-weight: font-family.font-weight('light'),\n line-height: 1.22,\n ),\n lg: (\n font-size: scale.type-scale(10),\n line-height: 1.19,\n ),\n xlg: (\n font-size: scale.type-scale(11),\n line-height: 1.17,\n ),\n max: (\n font-size: scale.type-scale(13),\n ),\n ),\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$fluid-heading-05: $expressive-heading-05 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$expressive-heading-06: (\n font-size: scale.type-scale(8),\n font-weight: font-family.font-weight('semibold'),\n line-height: 1.25,\n letter-spacing: 0,\n breakpoints: (\n md: (\n font-size: scale.type-scale(9),\n line-height: 1.22,\n ),\n lg: (\n font-size: scale.type-scale(10),\n line-height: 1.19,\n ),\n xlg: (\n font-size: scale.type-scale(11),\n line-height: 1.17,\n ),\n max: (\n font-size: scale.type-scale(13),\n ),\n ),\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$fluid-heading-06: $expressive-heading-06 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$expressive-paragraph-01: (\n font-size: scale.type-scale(6),\n font-weight: font-family.font-weight('light'),\n line-height: 1.334,\n letter-spacing: 0,\n breakpoints: (\n lg: (\n font-size: scale.type-scale(7),\n line-height: 1.28572,\n ),\n max: (\n font-size: scale.type-scale(8),\n line-height: 1.25,\n ),\n ),\n);\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$fluid-paragraph-01: $expressive-paragraph-01 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$quotation-01: (\n font-family: font-family.font-family('serif'),\n font-size: scale.type-scale(5),\n font-weight: font-family.font-weight('regular'),\n line-height: 1.3,\n letter-spacing: 0,\n breakpoints: (\n md: (\n font-size: scale.type-scale(5),\n ),\n lg: (\n font-size: scale.type-scale(6),\n line-height: 1.334,\n ),\n xlg: (\n font-size: scale.type-scale(7),\n line-height: 1.28572,\n ),\n max: (\n font-size: scale.type-scale(8),\n line-height: 1.25,\n ),\n ),\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$fluid-quotation-01: $quotation-01 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$quotation-02: (\n font-family: font-family.font-family('serif'),\n font-size: scale.type-scale(8),\n font-weight: font-family.font-weight('light'),\n line-height: 1.25,\n letter-spacing: 0,\n breakpoints: (\n md: (\n font-size: scale.type-scale(9),\n line-height: 1.22,\n ),\n lg: (\n font-size: scale.type-scale(10),\n line-height: 1.19,\n ),\n xlg: (\n font-size: scale.type-scale(11),\n line-height: 1.17,\n ),\n max: (\n font-size: scale.type-scale(13),\n ),\n ),\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$fluid-quotation-02: $quotation-02 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$display-01: (\n font-size: scale.type-scale(10),\n font-weight: font-family.font-weight('light'),\n line-height: 1.19,\n letter-spacing: 0,\n breakpoints: (\n md: (\n font-size: scale.type-scale(10),\n ),\n lg: (\n font-size: scale.type-scale(12),\n ),\n xlg: (\n font-size: scale.type-scale(13),\n line-height: 1.17,\n ),\n max: (\n font-size: scale.type-scale(15),\n line-height: 1.13,\n ),\n ),\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$fluid-display-01: $display-01 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$display-02: (\n font-size: scale.type-scale(10),\n font-weight: font-family.font-weight('semibold'),\n line-height: 1.19,\n letter-spacing: 0,\n breakpoints: (\n md: (\n font-size: scale.type-scale(10),\n ),\n lg: (\n font-size: scale.type-scale(12),\n ),\n xlg: (\n font-size: scale.type-scale(13),\n line-height: 1.16,\n ),\n max: (\n font-size: scale.type-scale(15),\n line-height: 1.13,\n ),\n ),\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$fluid-display-02: $display-02 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$display-03: (\n font-size: scale.type-scale(10),\n font-weight: font-family.font-weight('light'),\n line-height: 1.19,\n letter-spacing: 0,\n breakpoints: (\n md: (\n font-size: scale.type-scale(12),\n line-height: 1.18,\n ),\n lg: (\n font-size: scale.type-scale(13),\n line-height: 1.16,\n letter-spacing: -0.64px,\n ),\n xlg: (\n font-size: scale.type-scale(15),\n line-height: 1.13,\n letter-spacing: -0.64px,\n ),\n max: (\n font-size: scale.type-scale(16),\n line-height: 1.11,\n letter-spacing: -0.96px,\n ),\n ),\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$fluid-display-03: $display-03 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$display-04: (\n font-size: scale.type-scale(10),\n font-weight: font-family.font-weight('light'),\n line-height: 1.19,\n letter-spacing: 0,\n breakpoints: (\n md: (\n font-size: scale.type-scale(14),\n line-height: 1.15,\n ),\n lg: (\n font-size: scale.type-scale(17),\n line-height: 1.11,\n letter-spacing: -0.64px,\n ),\n xlg: (\n font-size: scale.type-scale(20),\n line-height: 1.07,\n letter-spacing: -0.64px,\n ),\n max: (\n font-size: scale.type-scale(23),\n line-height: 1.05,\n letter-spacing: -0.96px,\n ),\n ),\n) !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$fluid-display-04: $display-04 !default;\n\n/// @type Map\n/// @access public\n/// @group @carbon/type\n$tokens: (\n caption-01: $caption-01,\n caption-02: $caption-02,\n label-01: $label-01,\n label-02: $label-02,\n helper-text-01: $helper-text-01,\n helper-text-02: $helper-text-02,\n body-short-01: $body-short-01,\n body-short-02: $body-short-02,\n body-long-01: $body-long-01,\n body-long-02: $body-long-02,\n code-01: $code-01,\n code-02: $code-02,\n heading-01: $heading-01,\n heading-02: $heading-02,\n productive-heading-01: $productive-heading-01,\n productive-heading-02: $productive-heading-02,\n productive-heading-03: $productive-heading-03,\n productive-heading-04: $productive-heading-04,\n productive-heading-05: $productive-heading-05,\n productive-heading-06: $productive-heading-06,\n productive-heading-07: $productive-heading-07,\n expressive-paragraph-01: $expressive-paragraph-01,\n expressive-heading-01: $expressive-heading-01,\n expressive-heading-02: $expressive-heading-02,\n expressive-heading-03: $expressive-heading-03,\n expressive-heading-04: $expressive-heading-04,\n expressive-heading-05: $expressive-heading-05,\n expressive-heading-06: $expressive-heading-06,\n quotation-01: $quotation-01,\n quotation-02: $quotation-02,\n display-01: $display-01,\n display-02: $display-02,\n display-03: $display-03,\n display-04: $display-04,\n // V11 Tokens\n legal-01: $legal-01,\n legal-02: $legal-02,\n body-compact-01: $body-compact-01,\n body-compact-02: $body-compact-02,\n heading-compact-01: $heading-compact-01,\n heading-compact-02: $heading-compact-02,\n body-01: $body-01,\n body-02: $body-02,\n heading-03: $heading-03,\n heading-04: $heading-04,\n heading-05: $heading-05,\n heading-06: $heading-06,\n heading-07: $heading-07,\n fluid-heading-03: $fluid-heading-03,\n fluid-heading-04: $fluid-heading-04,\n fluid-heading-05: $fluid-heading-05,\n fluid-heading-06: $fluid-heading-06,\n fluid-paragraph-01: $fluid-paragraph-01,\n fluid-quotation-01: $fluid-quotation-01,\n fluid-quotation-02: $fluid-quotation-02,\n fluid-display-01: $fluid-display-01,\n fluid-display-02: $fluid-display-02,\n fluid-display-03: $fluid-display-03,\n fluid-display-04: $fluid-display-04,\n) !default;\n\n/// @param {Map} $map\n/// @access public\n/// @group @carbon/type\n@mixin properties($map) {\n @each $name, $value in $map {\n #{$name}: $value;\n }\n}\n\n/// @param {Number} $value - Number with units\n/// @return {Number} Without units\n/// @access public\n/// @group @carbon/type\n@function strip-unit($value) {\n @return math.div($value, $value * 0 + 1);\n}\n\n/// This helper includes fluid type styles for the given token value. Fluid type\n/// means that the `font-size` is computed using `calc()` in order to be\n/// determined by the screen size instead of a breakpoint. As a result, fluid\n/// styles should be used with caution in fixed width contexts.\n///\n/// In addition, we make use of %-based line-heights so that the line-height of\n/// each type style is computed correctly due to the dynamic nature of the\n/// `font-size`.\n///\n/// Most of the logic for this work comes from CSS Tricks:\n/// https://css-tricks.com/snippets/css/fluid-typography/\n///\n/// @param {Map} $type-styles - The value of a given type token\n/// @param {Map} $breakpoints [$grid-breakpoints] - Custom breakpoints to use\n/// @access public\n/// @group @carbon/type\n@mixin fluid-type($type-styles, $breakpoints: gridconfig.$grid-breakpoints) {\n // Include the initial styles for the given token by default without any\n // media query guard. This includes `font-size` as a fallback in the case\n // that a browser does not support `calc()`\n @include properties(map.remove($type-styles, breakpoints));\n // We also need to include the `sm` styles by default since they don't\n // appear in the fluid styles for tokens\n @include fluid-type-size($type-styles, sm, $breakpoints);\n\n // Finally, we need to go through all the breakpoints defined in the type\n // token and apply the properties and fluid type size for that given\n // breakpoint\n @each $name, $values in map.get($type-styles, breakpoints) {\n @include grid.breakpoint($name) {\n @include properties($values);\n @include fluid-type-size($type-styles, $name, $breakpoints);\n }\n }\n}\n\n/// Computes the fluid `font-size` for a given type style and breakpoint\n/// @param {Map} $type-styles - The styles for a given token\n/// @param {String} $name - The name of the breakpoint to which we apply the fluid\n/// @param {Map} $breakpoints [$grid-breakpoints] - The breakpoints for the grid system\n/// @access public\n/// @group @carbon/type\n@mixin fluid-type-size(\n $type-styles,\n $name,\n $breakpoints: gridconfig.$grid-breakpoints\n) {\n // Get the information about the breakpoint we're currently working in. Useful\n // for getting initial width information\n $breakpoint: map.get($breakpoints, $name);\n\n // Our fluid styles are captured under the 'breakpoints' property in our type\n // styles map. These define what values to treat as `max-` variables below\n $fluid-sizes: map.get($type-styles, breakpoints);\n $fluid-breakpoint: ();\n // Special case for `sm` because the styles for small are on the type style\n // directly\n @if $name == sm {\n $fluid-breakpoint: map.remove($type-styles, breakpoints);\n } @else {\n $fluid-breakpoint: map.get($fluid-sizes, $name);\n }\n\n // Initialize our font-sizes to the default size for the type style\n $max-font-size: map.get($type-styles, font-size);\n $min-font-size: map.get($type-styles, font-size);\n @if map.has-key($fluid-breakpoint, font-size) {\n $min-font-size: map.get($fluid-breakpoint, font-size);\n }\n\n // Initialize our min and max width to the width of the current breakpoint\n $max-vw: map.get($breakpoint, width);\n $min-vw: map.get($breakpoint, width);\n\n // We can use `breakpoint-next` to see if there is another breakpoint we can\n // use to update `max-font-size` and `max-vw` with larger values\n $next-breakpoint-available: grid.breakpoint-next($name, $breakpoints);\n $next-fluid-breakpoint-name: null;\n\n // We need to figure out what the next available fluid breakpoint is for our\n // given $type-styles. In this loop we try and iterate through breakpoints\n // until we either manually set $next-breakpoint-available to null or\n // `breakpoint-next` returns null.\n @while $next-breakpoint-available {\n @if map.has-key($fluid-sizes, $next-breakpoint-available) {\n $next-fluid-breakpoint-name: $next-breakpoint-available;\n $next-breakpoint-available: null;\n } @else {\n $next-breakpoint-available: grid.breakpoint-next(\n $next-breakpoint-available,\n $breakpoints\n );\n }\n }\n\n // If we have found the next available fluid breakpoint name, then we know\n // that we have values that we can use to set max-font-size and max-vw as both\n // values derive from the next breakpoint\n @if $next-fluid-breakpoint-name {\n $next-fluid-breakpoint: map.get($breakpoints, $next-fluid-breakpoint-name);\n $max-font-size: map.get(\n map.get($fluid-sizes, $next-fluid-breakpoint-name),\n font-size\n );\n $max-vw: map.get($next-fluid-breakpoint, width);\n\n // prettier-ignore\n font-size: calc(#{$min-font-size} +\n #{strip-unit($max-font-size - $min-font-size)} *\n ((100vw - #{$min-vw}) / #{strip-unit($max-vw - $min-vw)})\n );\n } @else {\n // Otherwise, just default to setting the font size found from the type\n // style or the given fluid breakpoint in the type style\n font-size: $min-font-size;\n }\n}\n\n// TODO move following variable and `custom-property` mixin into shared file for\n// both `@carbon/type` and `@carbon/themes`\n\n/// @access private\n/// @group @carbon/type\n@mixin custom-properties($name, $value) {\n @each $property, $value in $value {\n #{$property}: var(\n --#{$custom-property-prefix}-#{$name}-#{$property},\n #{$value}\n );\n }\n}\n\n/// Helper mixin to include the styles for a given token in any selector in your\n/// project. Also includes an optional fluid option that will enable fluid\n/// styles for the token if they are defined. Fluid styles will cause the\n/// token's font-size to be computed based on the viewport size. As a result, use\n/// with caution in fixed contexts.\n/// @param {String} $name - The name of the token to get the styles for\n/// @param {Boolean} $fluid [false] - Specify whether to include fluid styles for the\n/// @param {Map} $breakpoints [$grid-breakpoints] - Provide a custom breakpoint map to use\n/// @access public\n/// @group @carbon/type\n@mixin type-style(\n $name,\n $fluid: false,\n $breakpoints: gridconfig.$grid-breakpoints\n) {\n @if not map.has-key($tokens, $name) {\n @error 'Unable to find a token with the name: `#{$name}`';\n }\n\n $token: map.get($tokens, $name);\n\n // If $fluid is set to true and the token has breakpoints defined for fluid\n // styles, delegate to the fluid-type helper for the given token\n @if $fluid == true and map.has-key($token, 'breakpoints') {\n @include fluid-type($token, $breakpoints);\n } @else {\n @include custom-properties($name, $token);\n }\n}\n"],sourceRoot:""}]),r.locals={loading:"-esm-patient-programs__programs-form__loading___Udyd1",button:"-esm-patient-programs__programs-form__button___+EibT",tablet:"-esm-patient-programs__programs-form__tablet___F8bMH",desktop:"-esm-patient-programs__programs-form__desktop___Xlimz",formContainer:"-esm-patient-programs__programs-form__formContainer___0TBLb",form:"-esm-patient-programs__programs-form__form___AHDMX",errorMessage:"-esm-patient-programs__programs-form__errorMessage___JQ2u-",notification:"-esm-patient-programs__programs-form__notification___9QK0m"};const l=r},1577:(e,n,t)=>{t.r(n),t.d(n,{default:()=>B});var a=t(268),i=t.n(a),o=t(4924),r=t(3565),l=t.n(r),s=t(8219),p=t(195),c=t(3955),u=t(8883),d=t(2870),g=t(8101),f=t(321),h=t.n(f),m=t(1195),y=t.n(m),b=t(3275),$=t.n(b),v=t(7162),w=t.n(v),k=t(2094),x=t.n(k),A=t(757),_=t.n(A),z=t(9015),C={};C.styleTagTransform=_(),C.setAttributes=w(),C.insert=$().bind(null,"head"),C.domAPI=y(),C.insertStyleElement=x(),h()(z.Z,C);const M=z.Z&&z.Z.locals?z.Z.locals:void 0;function E(e,n){(null==n||n>e.length)&&(n=e.length);for(var t=0,a=new Array(n);t<n;t++)a[t]=e[t];return a}function D(e,n,t,a,i,o,r){try{var l=e[o](r),s=l.value}catch(e){return void t(e)}l.done?n(s):Promise.resolve(s).then(a,i)}function S(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function T(e,n){return function(e){if(Array.isArray(e))return e}(e)||function(e,n){var t=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=t){var a,i,o=[],r=!0,l=!1;try{for(t=t.call(e);!(r=(a=t.next()).done)&&(o.push(a.value),!n||o.length!==n);r=!0);}catch(e){l=!0,i=e}finally{try{r||null==t.return||t.return()}finally{if(l)throw i}}return o}}(e,n)||function(e,n){if(e){if("string"==typeof e)return E(e,n);var t=Object.prototype.toString.call(e).slice(8,-1);return"Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t?Array.from(t):"Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?E(e,n):void 0}}(e,n)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}const B=function(e){var n,t,r,f,h,m=e.closeWorkspace,y=e.closeWorkspaceWithSavedChanges,b=e.patientUuid,$=e.programEnrollmentId,v=e.promptBeforeClosing,w=(0,o.useTranslation)().t,k="tablet"===(0,d.useLayoutType)(),x=(0,d.useSession)(),A=(0,d.useLocations)(),_=(0,g.oI)().data,z=(0,g.Bw)(b),C=z.data,E=z.mutateEnrollments,B=T((0,a.useState)(!1),2),N=B[0],I=B[1],P=(0,a.useMemo)((function(){return function(e){return p.z.object({selectedProgram:p.z.string().refine((function(e){return!!e}),e("programRequired","Program is required")),enrollmentDate:p.z.date(),completionDate:p.z.date().nullable(),enrollmentLocation:p.z.string()})}(w)}),[w]),F=$&&C.filter((function(e){return e.uuid===$}))[0],q=F?function(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{},a=Object.keys(t);"function"==typeof Object.getOwnPropertySymbols&&(a=a.concat(Object.getOwnPropertySymbols(t).filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})))),a.forEach((function(n){S(e,n,t[n])}))}return e}({display:F.program.name},F.program):null,O=q?[q]:_.filter((function(e){var n=C.find((function(n){return n.program.uuid===e.uuid}));return!n||null!==n.dateCompleted})),W=(0,c.cI)({mode:"all",resolver:(0,u.F)(P),defaultValues:{selectedProgram:null!==(n=null==F?void 0:F.program.uuid)&&void 0!==n?n:"",enrollmentDate:(null==F?void 0:F.dateEnrolled)?(0,d.parseDate)(F.dateEnrolled):new Date,completionDate:(null==F?void 0:F.dateCompleted)?(0,d.parseDate)(F.dateCompleted):null,enrollmentLocation:null!==(t=!(null==F?void 0:F.location.uuid)&&(null==x||null===(r=x.sessionLocation)||void 0===r?void 0:r.uuid)?null==x||null===(f=x.sessionLocation)||void 0===f?void 0:f.uuid:null!==(h=null==F?void 0:F.location.uuid)&&void 0!==h?h:null)&&void 0!==t?t:""}}),j=W.control,L=W.handleSubmit,Q=W.watch,U=W.formState.isDirty;(0,a.useEffect)((function(){v((function(){return U}))}),[U,v]);var X,G,H=(0,a.useCallback)((X=function(e){var n,t,a,i,o,r,s;return function(e,n){var t,a,i,o,r={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return o={next:l(0),throw:l(1),return:l(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function l(o){return function(l){return function(o){if(t)throw new TypeError("Generator is already executing.");for(;r;)try{if(t=1,a&&(i=2&o[0]?a.return:o[0]?a.throw||((i=a.return)&&i.call(a),0):a.next)&&!(i=i.call(a,o[1])).done)return i;switch(a=0,i&&(o=[2&o[0],i.value]),o[0]){case 0:case 1:i=o;break;case 4:return r.label++,{value:o[1],done:!1};case 5:r.label++,a=o[1],o=[0];continue;case 7:o=r.ops.pop(),r.trys.pop();continue;default:if(!((i=(i=r.trys).length>0&&i[i.length-1])||6!==o[0]&&2!==o[0])){r=0;continue}if(3===o[0]&&(!i||o[1]>i[0]&&o[1]<i[3])){r.label=o[1];break}if(6===o[0]&&r.label<i[1]){r.label=i[1],i=o;break}if(i&&r.label<i[2]){r.label=i[2],r.ops.push(o);break}i[2]&&r.ops.pop(),r.trys.pop();continue}o=n.call(e,r)}catch(e){o=[6,e],a=0}finally{t=i=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,l])}}}(this,(function(p){switch(p.label){case 0:n=e.selectedProgram,t=e.enrollmentDate,a=e.completionDate,i=e.enrollmentLocation,o={patient:b,program:n,dateEnrolled:t?l()(t).format():null,dateCompleted:a?l()(a).format():null,location:i},p.label=1;case 1:return p.trys.push([1,7,,8]),r=new AbortController,F?[4,(0,g.YX)(F.uuid,o,r)]:[3,3];case 2:return p.sent(),[3,5];case 3:return[4,(0,g.df)(o,r)];case 4:p.sent(),p.label=5;case 5:return[4,E()];case 6:return p.sent(),y(),(0,d.showSnackbar)({kind:"success",title:F?w("enrollmentUpdated","Program enrollment updated"):w("enrollmentSaved","Program enrollment saved"),subtitle:F?w("enrollmentUpdatesNowVisible","Changes to the program are now visible in the Programs table"):w("enrollmentNowVisible","It is now visible in the Programs table")}),[3,8];case 7:return s=p.sent(),(0,d.showSnackbar)({kind:"error",title:w("programEnrollmentSaveError","Error saving program enrollment"),subtitle:(c=s,u=Error,(null!=u&&"undefined"!=typeof Symbol&&u[Symbol.hasInstance]?u[Symbol.hasInstance](c):c instanceof u)?s.message:"An unknown error occurred")}),[3,8];case 8:return I(!1),[2]}var c,u}))},G=function(){var e=this,n=arguments;return new Promise((function(t,a){var i=X.apply(e,n);function o(e){D(i,t,a,o,r,"next",e)}function r(e){D(i,t,a,o,r,"throw",e)}o(void 0)}))},function(e){return G.apply(this,arguments)}),[y,F,E,b,w]),V=i().createElement(c.Qr,{name:"selectedProgram",control:j,render:function(e){var n,t=e.fieldState,a=e.field,o=a.onChange,r=a.value;return i().createElement(i().Fragment,null,i().createElement(s.PhF,{"aria-label":"program name",id:"program",invalid:!!(null==t?void 0:t.error),labelText:w("programName","Program name"),onChange:function(e){return o(e.target.value)},value:r},i().createElement(s.QlF,{text:w("chooseProgram","Choose a program"),value:""}),(null==O?void 0:O.length)>0&&O.map((function(e){return i().createElement(s.QlF,{key:e.uuid,text:e.display,value:e.uuid},e.display)}))),i().createElement("p",{className:M.errorMessage},null==t||null===(n=t.error)||void 0===n?void 0:n.message))}}),Y=i().createElement(c.Qr,{name:"enrollmentDate",control:j,render:function(e){var n=e.field,t=n.onChange,a=n.value;return i().createElement(s.Mtg,{"aria-label":"enrollment date",id:"enrollmentDate",datePickerType:"single",dateFormat:"d/m/Y",maxDate:(new Date).toISOString(),placeholder:"dd/mm/yyyy",onChange:function(e){var n=T(e,1)[0];return t(n)},value:a},i().createElement(s.aj6,{id:"enrollmentDateInput",labelText:w("dateEnrolled","Date enrolled")}))}}),Z=i().createElement(c.Qr,{name:"completionDate",control:j,render:function(e){var n=e.field,t=n.onChange,a=n.value;return i().createElement(s.Mtg,{"aria-label":"completion date",id:"completionDate",datePickerType:"single",dateFormat:"d/m/Y",minDate:new Date(Q("enrollmentDate")).toISOString(),maxDate:(new Date).toISOString(),placeholder:"dd/mm/yyyy",onChange:function(e){var n=T(e,1)[0];return t(n)},value:a},i().createElement(s.aj6,{id:"completionDateInput",labelText:w("dateCompleted","Date completed")}))}}),K=i().createElement(c.Qr,{name:"enrollmentLocation",control:j,render:function(e){var n=e.field,t=n.onChange,a=n.value;return i().createElement(s.PhF,{"aria-label":"enrollment location",id:"location",labelText:w("enrollmentLocation","Enrollment location"),onChange:function(e){return t(e.target.value)},value:a},(null==A?void 0:A.length)>0&&A.map((function(e){return i().createElement(s.QlF,{key:e.uuid,text:e.display,value:e.uuid},e.display)})))}}),J=[{style:{maxWidth:k&&"50%"},legendText:"",value:V},{style:{maxWidth:"50%"},legendText:"",value:Y},{style:{width:"50%"},legendText:"",value:Z},{style:{width:"50%"},legendText:"",value:K}];return i().createElement(s.l09,{className:M.form,onSubmit:L(H)},i().createElement(s.Kqy,{className:M.formContainer,gap:7},!_.length&&i().createElement(s.K0D,{className:M.notification,kind:"error",lowContrast:!0,subtitle:w("configurePrograms","Please configure programs to continue."),title:w("noProgramsConfigured","No programs configured")}),J.map((function(e,n){return i().createElement(s.cwH,{style:e.style,legendText:e.legendText,key:n},i().createElement("div",{className:M.selectContainer},k?i().createElement(s.mh4,null,e.value):e.value))}))),i().createElement(s.uVA,{className:k?M.tablet:M.desktop},i().createElement(s.zxk,{className:M.button,kind:"secondary",onClick:m},w("cancel","Cancel")),i().createElement(s.zxk,{className:M.button,kind:"primary",type:"submit"},N?i().createElement(s.lSo,{description:w("saving","Saving")+"..."}):i().createElement("span",null,w("saveAndClose","Save and close")))))}}}]);
|
package/dist/577.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"577.js","mappings":"mNAGIA,E,MAA0B,GAA4B,KAE1DA,EAAwBC,KAAK,CAACC,EAAOC,GAAI,
|
|
1
|
+
{"version":3,"file":"577.js","mappings":"mNAGIA,E,MAA0B,GAA4B,KAE1DA,EAAwBC,KAAK,CAACC,EAAOC,GA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ACjBrB,UAAWC,EAAOqB,aAClB7C,KAAK,QACL8C,aAAAA,EACA5C,SAAUtE,EAAE,oBAAqB,0CACjCqE,MAAOrE,EAAE,uBAAwB,4BAGpCsG,EAAWd,KAAI,SAAC2B,EAAOC,G,OACtB,kBAACC,EAAAA,IAASA,CAACd,MAAOY,EAAMZ,MAAOE,WAAYU,EAAMV,WAAYhB,IAAK2B,GAChE,kBAACE,MAAAA,CAAI3B,UAAWC,EAAO2B,iBAAkBtH,EAAW,kBAACuH,EAAAA,IAAKA,KAAEL,EAAM/F,OAAiB+F,EAAM/F,O,KAI/F,kBAACqG,EAAAA,IAASA,CAAC9B,UAAW1F,EAAW2F,EAAO8B,OAAS9B,EAAO+B,SACtD,kBAACC,EAAAA,IAAMA,CAACjC,UAAWC,EAAOiC,OAAQzD,KAAK,YAAY0D,QAASpI,GACzDM,EAAE,SAAU,WAEf,kBAAC4H,EAAAA,IAAMA,CAACjC,UAAWC,EAAOiC,OAAQzD,KAAK,UAAU2D,KAAK,UACnDpH,EACC,kBAACqH,EAAAA,IAAaA,CAACC,YAAajI,EAAE,SAAU,UAAY,QAEpD,kBAACkI,OAAAA,KAAMlI,EAAE,eAAgB,qBAMrC,C","sources":["webpack://@openmrs/esm-patient-programs-app/./src/programs/programs-form.scss","webpack://@openmrs/esm-patient-programs-app/./src/programs/programs-form.scss?b5c0","webpack://@openmrs/esm-patient-programs-app/./src/programs/programs-form.workspace.tsx"],"names":["___CSS_LOADER_EXPORT___","push","module","id","locals","options","styleTagTransform","setAttributes","insert","domAPI","insertStyleElement","undefined","currentEnrollment","getLocationUuid","session","closeWorkspace","closeWorkspaceWithSavedChanges","patientUuid","programEnrollmentId","promptBeforeClosing","useTranslation","t","isTablet","useLayoutType","useSession","availableLocations","useLocations","data","useAvailablePrograms","useEnrollments","mutateEnrollments","useState","isSubmittingForm","setIsSubmittingForm","programsFormSchema","useMemo","z","object","selectedProgram","string","refine","value","enrollmentDate","date","completionDate","nullable","enrollmentLocation","createProgramsFormSchema","enrollments","filter","e","uuid","currentProgram","display","program","name","eligiblePrograms","availablePrograms","enrollment","find","dateCompleted","useForm","mode","resolver","zodResolver","defaultValues","dateEnrolled","parseDate","Date","location","sessionLocation","control","handleSubmit","watch","formState","isDirty","useEffect","onSubmit","useCallback","payload","abortController","error","patient","dayjs","format","AbortController","updateProgramEnrollment","createProgramEnrollment","showSnackbar","kind","title","subtitle","Error","message","programSelect","Controller","render","fieldState","field","onChange","Select","aria-label","invalid","labelText","event","target","SelectItem","text","length","map","key","p","className","styles","errorMessage","DatePicker","datePickerType","dateFormat","maxDate","toISOString","placeholder","DatePickerInput","minDate","formGroups","style","maxWidth","legendText","width","Form","form","Stack","formContainer","gap","InlineNotification","notification","lowContrast","group","i","FormGroup","div","selectContainer","Layer","ButtonSet","tablet","desktop","Button","button","onClick","type","InlineLoading","description","span"],"sourceRoot":""}
|
package/dist/81.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(globalThis.webpackChunk_openmrs_esm_patient_programs_app=globalThis.webpackChunk_openmrs_esm_patient_programs_app||[]).push([[81],{3922:(e,r,n)=>{"use strict";n.d(r,{Z:()=>i});var t=n(5698),a=n.n(t),o=n(9613),l=n.n(o)()(a());l.push([e.id,":root{--brand-01: #005d5d;--brand-02: #004144;--brand-03: #007d79;--bottom-nav-height: 4rem;--workspace-header-height: 3rem;--tablet-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--bottom-nav-height));--desktop-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--workspace-header-height))}.-esm-patient-programs__programs-detailed-summary__widgetCard___Qfbyc{border:1px solid #e0e0e0;border-bottom:none}","",{version:3,sources:["webpack://./../../node_modules/@openmrs/esm-styleguide/src/_vars.scss","webpack://./src/programs/programs-detailed-summary.scss"],names:[],mappings:"AAoDA,MACE,mBAAA,CACA,mBAAA,CACA,mBAAA,CACA,yBAAA,CACA,+BAAA,CACA,oGAAA,CACA,2GAAA,CCzDF,sEACE,wBAAA,CACA,kBAAA",sourcesContent:["$ui-01: #f4f4f4;\n$ui-02: #ffffff;\n$ui-03: #e0e0e0;\n$ui-04: #8d8d8d;\n$ui-05: #161616;\n$text-02: #525252;\n$text-03: #a8a8a8;\n$ui-background: #ffffff;\n$color-gray-30: #c6c6c6;\n$color-gray-70: #525252;\n$color-gray-100: #161616;\n$color-blue-60-2: #0f62fe;\n$color-blue-10: #edf5ff;\n$color-yellow-50: #feecae;\n$carbon--red-50: #fa4d56;\n$inverse-link: #78a9ff;\n$support-02: #24a148;\n$inverse-support-03: #f1c21b;\n$warning-background: #fff8e1;\n$openmrs-background-grey: #f4f4f4;\n$danger: #da1e28;\n$interactive-01: #0f62fe;\n$field-01: #f4f4f4;\n$grey-2: #e0e0e0;\n$labeldropdown: #c6c6c6;\n\n$brand-primary-10: #d9fbfb;\n$brand-primary-20: #9ef0f0;\n$brand-primary-30: #3ddbd9;\n$brand-primary-40: #08bdba;\n$brand-primary-50: #009d9a;\n\n/* 60,70 and 80 are already declared as brand-01, 02 and 03 respectively */\n\n$brand-primary-90: #022b30;\n$brand-primary-100: #081a1c;\n\n@mixin brand-01($property) {\n #{$property}: #005d5d;\n #{$property}: var(--brand-01);\n}\n\n@mixin brand-02($property) {\n #{$property}: #004144;\n #{$property}: var(--brand-02);\n}\n\n@mixin brand-03($property) {\n #{$property}: #007d79;\n #{$property}: var(--brand-03);\n}\n\n:root {\n --brand-01: #005d5d;\n --brand-02: #004144;\n --brand-03: #007d79;\n --bottom-nav-height: 4rem;\n --workspace-header-height: 3rem;\n --tablet-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--bottom-nav-height));\n --desktop-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--workspace-header-height));\n}\n\n$breakpoint-phone-min: 0px;\n$breakpoint-phone-max: 600px;\n$breakpoint-tablet-min: 601px;\n$breakpoint-tablet-max: 1023px;\n$breakpoint-small-desktop-min: 1024px;\n$breakpoint-small-desktop-max: 1439px;\n$breakpoint-large-desktop-min: 1440px;\n$breakpoint-large-desktop-max: 99999999px;\n\n/* These color variables will be removed in a future release */\n$brand-teal-01: #007d79;\n$brand-01: #005d5d;\n$brand-02: #004144;\n","@use '@openmrs/esm-styleguide/src/vars' as *;\n\n.widgetCard {\n border: 1px solid $ui-03;\n border-bottom: none;\n}\n"],sourceRoot:""}]),l.locals={widgetCard:"-esm-patient-programs__programs-detailed-summary__widgetCard___Qfbyc"};const i=l},8972:(e,r,n)=>{"use strict";n.d(r,{Z:()=>i});var t=n(5698),a=n.n(t),o=n(9613),l=n.n(o)()(a());l.push([e.id,":root{--brand-01: #005d5d;--brand-02: #004144;--brand-03: #007d79;--bottom-nav-height: 4rem;--workspace-header-height: 3rem;--tablet-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--bottom-nav-height));--desktop-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--workspace-header-height))}.-esm-patient-programs__programs-overview__widgetCard___9hNqv{border:1px solid #e0e0e0}","",{version:3,sources:["webpack://./../../node_modules/@openmrs/esm-styleguide/src/_vars.scss","webpack://./src/programs/programs-overview.scss"],names:[],mappings:"AAoDA,MACE,mBAAA,CACA,mBAAA,CACA,mBAAA,CACA,yBAAA,CACA,+BAAA,CACA,oGAAA,CACA,2GAAA,CCzDF,8DACE,wBAAA",sourcesContent:["$ui-01: #f4f4f4;\n$ui-02: #ffffff;\n$ui-03: #e0e0e0;\n$ui-04: #8d8d8d;\n$ui-05: #161616;\n$text-02: #525252;\n$text-03: #a8a8a8;\n$ui-background: #ffffff;\n$color-gray-30: #c6c6c6;\n$color-gray-70: #525252;\n$color-gray-100: #161616;\n$color-blue-60-2: #0f62fe;\n$color-blue-10: #edf5ff;\n$color-yellow-50: #feecae;\n$carbon--red-50: #fa4d56;\n$inverse-link: #78a9ff;\n$support-02: #24a148;\n$inverse-support-03: #f1c21b;\n$warning-background: #fff8e1;\n$openmrs-background-grey: #f4f4f4;\n$danger: #da1e28;\n$interactive-01: #0f62fe;\n$field-01: #f4f4f4;\n$grey-2: #e0e0e0;\n$labeldropdown: #c6c6c6;\n\n$brand-primary-10: #d9fbfb;\n$brand-primary-20: #9ef0f0;\n$brand-primary-30: #3ddbd9;\n$brand-primary-40: #08bdba;\n$brand-primary-50: #009d9a;\n\n/* 60,70 and 80 are already declared as brand-01, 02 and 03 respectively */\n\n$brand-primary-90: #022b30;\n$brand-primary-100: #081a1c;\n\n@mixin brand-01($property) {\n #{$property}: #005d5d;\n #{$property}: var(--brand-01);\n}\n\n@mixin brand-02($property) {\n #{$property}: #004144;\n #{$property}: var(--brand-02);\n}\n\n@mixin brand-03($property) {\n #{$property}: #007d79;\n #{$property}: var(--brand-03);\n}\n\n:root {\n --brand-01: #005d5d;\n --brand-02: #004144;\n --brand-03: #007d79;\n --bottom-nav-height: 4rem;\n --workspace-header-height: 3rem;\n --tablet-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--bottom-nav-height));\n --desktop-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--workspace-header-height));\n}\n\n$breakpoint-phone-min: 0px;\n$breakpoint-phone-max: 600px;\n$breakpoint-tablet-min: 601px;\n$breakpoint-tablet-max: 1023px;\n$breakpoint-small-desktop-min: 1024px;\n$breakpoint-small-desktop-max: 1439px;\n$breakpoint-large-desktop-min: 1440px;\n$breakpoint-large-desktop-max: 99999999px;\n\n/* These color variables will be removed in a future release */\n$brand-teal-01: #007d79;\n$brand-01: #005d5d;\n$brand-02: #004144;\n","@use '@openmrs/esm-styleguide/src/vars' as *;\n\n.widgetCard {\n border: 1px solid $ui-03;\n}\n"],sourceRoot:""}]),l.locals={widgetCard:"-esm-patient-programs__programs-overview__widgetCard___9hNqv"};const i=l},6081:(e,r,n)=>{"use strict";n.r(r),n.d(r,{importTranslation:()=>H,programsDashboardLink:()=>G,programsDetailedSummary:()=>q,programsFormWorkspace:()=>Q,programsOverview:()=>V,startupApp:()=>M});var t=n(2870),a=n(884),o={hideAddProgramButton:{_type:t.Type.Boolean,_default:!1}},l=n(268),i=n.n(l),s=n(2524),d=n.n(s),c=n(4924),u=n(8219),p=n(6759),m=n(8101),b=n(321),g=n.n(b),f=n(1195),v=n.n(f),h=n(3275),y=n.n(h),k=n(7162),$=n.n(k),A=n(2094),w=n.n(A),E=n(757),C=n.n(E),P=n(8972),O={};O.styleTagTransform=C(),O.setAttributes=$(),O.insert=y().bind(null,"head"),O.domAPI=v(),O.insertStyleElement=w(),g()(P.Z,O);const j=P.Z&&P.Z.locals?P.Z.locals:void 0;function x(e,r,n){return r in e?Object.defineProperty(e,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[r]=n,e}function _(e){for(var r=1;r<arguments.length;r++){var n=null!=arguments[r]?arguments[r]:{},t=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(t=t.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),t.forEach((function(r){x(e,r,n[r])}))}return e}var S=n(7631),D=n(3922),Z={};Z.styleTagTransform=C(),Z.setAttributes=$(),Z.insert=y().bind(null,"head"),Z.domAPI=v(),Z.insertStyleElement=w(),g()(D.Z,Z);const T=D.Z&&D.Z.locals?D.Z.locals:void 0;function B(e,r,n){return r in e?Object.defineProperty(e,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[r]=n,e}function L(e){for(var r=1;r<arguments.length;r++){var n=null!=arguments[r]?arguments[r]:{},t=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(t=t.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),t.forEach((function(r){B(e,r,n[r])}))}return e}function z(e){var r=e.programEnrollmentId,n=e.t,o="tablet"===(0,t.useLayoutType)(),s=(0,l.useCallback)((function(){return(0,a.launchPatientWorkspace)("programs-form-workspace",{programEnrollmentId:r})}),[r]);return i().createElement(u.zxk,{"aria-label":"edit program",kind:"ghost",renderIcon:function(e){return i().createElement(S.I8,L({size:16},e))},iconDescription:n("editProgram","Edit Program"),onClick:s,hasIconOnly:!0,tooltipPosition:"left",size:o?"lg":"sm"})}function I(e,r,n){return r in e?Object.defineProperty(e,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[r]=n,e}var N="@openmrs/esm-patient-programs-app",F={featureName:"patient-programs",moduleName:N},H=n(3979);function M(){(0,t.defineConfigSchema)(N,o)}var U,W,V=(0,t.getSyncLifecycle)((function(e){e.basePath;var r=e.patientUuid,n=(0,c.useTranslation)().t,o=(0,t.useConfig)(),l=n("programs","Program enrollments"),s=n("carePrograms","Care Programs"),b=n("seeAll","See all"),g="${openmrsSpaBase}/patient/".concat(r,"/chart/Programs"),f=(0,t.useLayoutType)(),v="tablet"===f,h=(0,t.isDesktop)(f),y=(0,m.b$)(r),k=y.activeEnrollments,$=y.availablePrograms,A=y.eligiblePrograms,w=y.enrollments,E=y.error,C=y.isLoading,P=y.isValidating,O=(0,t.usePagination)(null!=w?w:[],5),x=O.results,S=O.goTo,D=O.currentPage,Z=i().useCallback((function(){return(0,a.launchPatientWorkspace)("programs-form-workspace")}),[]),T=[{key:"display",header:n("activePrograms","Active programs")},{key:"location",header:n("location","Location")},{key:"dateEnrolled",header:n("dateEnrolled","Date enrolled")},{key:"status",header:n("status","Status")},{key:"actions",header:n("actions","Actions")}],B=i().useMemo((function(){return null==x?void 0:x.map((function(e){var r,a;return{id:e.uuid,display:e.display,location:null!==(a=null===(r=e.location)||void 0===r?void 0:r.display)&&void 0!==a?a:"--",dateEnrolled:e.dateEnrolled?(0,t.formatDatetime)(new Date(e.dateEnrolled)):"--",status:e.dateCompleted?"".concat(n("completedOn","Completed On")," ").concat((0,t.formatDate)(new Date(e.dateCompleted))):n("active","Active")}}))}),[x,n]);return C?i().createElement(u.gqd,{role:"progressbar",compact:h,zebra:!0}):E?i().createElement(a.ErrorState,{error:E,headerTitle:s}):(null==k?void 0:k.length)?i().createElement("div",{className:j.widgetCard},i().createElement(a.CardHeader,{title:s},i().createElement("span",null,P?i().createElement(u.lSo,null):null),o.hideAddProgramButton?null:i().createElement(u.zxk,{kind:"ghost",renderIcon:function(e){return i().createElement(p.mm,_({size:16},e))},iconDescription:"Add programs",onClick:Z,disabled:(null==$?void 0:$.length)&&0===(null==A?void 0:A.length)},n("add","Add"))),(null==$?void 0:$.length)&&0===(null==A?void 0:A.length)&&i().createElement(u.K0D,{style:{minWidth:"100%",margin:"0rem",padding:"0rem"},kind:"info",lowContrast:!0,subtitle:n("noEligibleEnrollments","There are no more programs left to enroll this patient in"),title:n("fullyEnrolled","Enrolled in all programs")}),i().createElement(u.wQF,{rows:B,headers:T,isSortable:!0,size:v?"lg":"sm",useZebraStyles:!0},(function(e){var r=e.rows,n=e.headers,t=e.getHeaderProps,a=e.getTableProps;return i().createElement(u.xJi,null,i().createElement(u.iA_,_({"aria-label":"programs overview"},a()),i().createElement(u.ssF,null,i().createElement(u.SCH,null,n.map((function(e){var r,n;return i().createElement(u.xDH,_({className:d()(j.productiveHeading01,j.text02)},t({header:e,isSortable:e.isSortable})),null!==(n=null===(r=e.header)||void 0===r?void 0:r.content)&&void 0!==n?n:e.header)})))),i().createElement(u.RMI,null,r.map((function(e){return i().createElement(u.SCH,{key:e.id},e.cells.map((function(e){var r,n;return i().createElement(u.pj1,{key:e.id},null!==(n=null===(r=e.value)||void 0===r?void 0:r.content)&&void 0!==n?n:e.value)})))})))))})),i().createElement(a.PatientChartPagination,{currentItems:x.length,onPageNumberChange:function(e){var r=e.page;return S(r)},pageNumber:D,pageSize:5,totalItems:null==w?void 0:w.length,dashboardLinkUrl:g,dashboardLinkLabel:b})):i().createElement(a.EmptyState,{displayText:l,headerTitle:s,launchForm:Z})}),F),q=(0,t.getSyncLifecycle)((function(e){var r=e.patientUuid,n=(0,c.useTranslation)().t,o=(0,t.useConfig)().hideAddProgramButton,s=(0,t.useLayoutType)(),b="tablet"===s,g=(0,t.isDesktop)(s),f=n("programEnrollments","Program enrollments"),v=n("carePrograms","Care Programs"),h=(0,m.b$)(r),y=h.enrollments,k=h.isLoading,$=h.error,A=h.isValidating,w=h.availablePrograms,E=(0,l.useMemo)((function(){return[{key:"display",header:n("activePrograms","Active programs")},{key:"location",header:n("location","Location")},{key:"dateEnrolled",header:n("dateEnrolled","Date enrolled")},{key:"status",header:n("status","Status")}]}),[n]),C=(0,l.useMemo)((function(){return null==y?void 0:y.map((function(e){var r,a;return{id:e.uuid,display:e.display,location:null!==(a=null===(r=e.location)||void 0===r?void 0:r.display)&&void 0!==a?a:"--",dateEnrolled:(0,t.formatDatetime)(new Date(e.dateEnrolled)),status:e.dateCompleted?"".concat(n("completedOn","Completed On")," ").concat((0,t.formatDate)(new Date(e.dateCompleted))):n("active","Active")}}))}),[y,n]),P=(0,l.useCallback)((function(){return(0,a.launchPatientWorkspace)("programs-form-workspace")}),[]),O=(0,l.useMemo)((function(){return!(!(null==w?void 0:w.length)||!(null==y?void 0:y.length))&&y.filter((function(e){return!e.dateCompleted})).length===w.length}),[w,y]);return k?i().createElement(u.gqd,{role:"progressbar",compact:g,zebra:!0}):$?i().createElement(a.ErrorState,{error:$,headerTitle:v}):(null==y?void 0:y.length)?i().createElement("div",{className:T.widgetCard},i().createElement(a.CardHeader,{title:v},i().createElement("span",null,A?i().createElement(u.lSo,null):null),o?null:i().createElement(u.zxk,{disabled:O,kind:"ghost",renderIcon:function(e){return i().createElement(p.mm,L({size:16},e))},iconDescription:n("addPrograms","Add programs"),onClick:P},n("add","Add"))),O&&i().createElement(u.K0D,{style:{minWidth:"100%",margin:"0rem",padding:"0rem"},lowContrast:!0,subtitle:n("noEligibleEnrollments","There are no more programs left to enroll this patient in"),title:n("fullyEnrolled","Enrolled in all programs")}),i().createElement(u.wQF,{rows:C,headers:E,isSortable:!0,size:b?"lg":"sm",useZebraStyles:!0},(function(e){var r=e.rows,t=e.headers,a=e.getHeaderProps,o=e.getTableProps;return i().createElement(u.xJi,null,i().createElement(u.iA_,L({"aria-label":"program enrollments"},o()),i().createElement(u.ssF,null,i().createElement(u.SCH,null,t.map((function(e){var r,n;return i().createElement(u.xDH,L({className:d()(T.productiveHeading01,T.text02)},a({header:e,isSortable:e.isSortable})),null!==(n=null===(r=e.header)||void 0===r?void 0:r.content)&&void 0!==n?n:e.header)})),i().createElement(u.xDH,null))),i().createElement(u.RMI,null,r.map((function(e,r){var t;return i().createElement(u.SCH,{key:e.id},e.cells.map((function(e){var r,n;return i().createElement(u.pj1,{key:e.id},null!==(n=null===(r=e.value)||void 0===r?void 0:r.content)&&void 0!==n?n:e.value)})),i().createElement(u.pj1,{className:"cds--table-column-menu"},i().createElement(z,{programEnrollmentId:null===(t=y[r])||void 0===t?void 0:t.uuid,t:n})))})))))}))):i().createElement(a.EmptyState,{displayText:f,headerTitle:v,launchForm:P})}),F),G=(0,t.getSyncLifecycle)((0,a.createDashboardLink)((U=function(e){for(var r=1;r<arguments.length;r++){var n=null!=arguments[r]?arguments[r]:{},t=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(t=t.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),t.forEach((function(r){I(e,r,n[r])}))}return e}({},{slot:"patient-chart-programs-dashboard-slot",path:"Programs",title:"Programs"}),W=null!=(W={moduleName:N})?W:{},Object.getOwnPropertyDescriptors?Object.defineProperties(U,Object.getOwnPropertyDescriptors(W)):function(e,r){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);n.push.apply(n,t)}return n}(Object(W)).forEach((function(e){Object.defineProperty(U,e,Object.getOwnPropertyDescriptor(W,e))})),U)),F),Q=(0,t.getAsyncLifecycle)((function(){return Promise.all([n.e(940),n.e(577)]).then(n.bind(n,1577))}),F)},8101:(e,r,n)=>{"use strict";n.d(r,{df:()=>_,YX:()=>S,oI:()=>x,Bw:()=>j,b$:()=>D});var t=n(3255),a=n(2870),o=n(4221),l=n(2300);const i=function(e,r,n){for(var t=-1,a=Object(e),o=n(e),l=o.length;l--;){var i=o[++t];if(!1===r(a[i],i,a))break}return e};var s=n(649);var d=n(3282);const c=(u=function(e,r){return e&&i(e,r,s.Z)},function(e,r){if(null==e)return e;if(!(0,d.Z)(e))return u(e,r);for(var n=e.length,t=-1,a=Object(e);++t<n&&!1!==r(a[t],t,a););return e});var u;const p=function(e,r){var n=[];return c(e,(function(e,t,a){r(e,t,a)&&n.push(e)})),n};var m=n(2448),b=n(7885);const g=function(e,r){return((0,b.Z)(e)?l.Z:p)(e,(0,m.Z)(r,3))};var f=n(7626),v=n(8147),h=n(3391);var y=n(5385),k=n(5598);const $=function(e){return null==e?[]:function(e,r){return(0,k.Z)(r,(function(r){return e[r]}))}(e,(0,s.Z)(e))};var A=Math.max;const w=function(e,r,n,t){e=(0,d.Z)(e)?e:$(e),n=n&&!t?(0,y.Z)(n):0;var a=e.length;return n<0&&(n=A(a+n,0)),function(e){return"string"==typeof e||!(0,b.Z)(e)&&(0,h.Z)(e)&&"[object String]"==(0,v.Z)(e)}(e)?n<=a&&e.indexOf(r,n)>-1:!!a&&(0,f.Z)(e,r,n)>-1},E=function(e,r){var n=-1,t=(0,d.Z)(e)?Array(e.length):[];return c(e,(function(e,a,o){t[++n]=r(e,a,o)})),t},C=function(e,r){return((0,b.Z)(e)?k.Z:E)(e,(0,m.Z)(r,3))};function P(e,r,n){return r in e?Object.defineProperty(e,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[r]=n,e}var O="custom:(uuid,display,program,dateEnrolled,dateCompleted,location:(uuid,display))";function j(e){var r,n="".concat(a.restBaseUrl,"/programenrollment?patient=").concat(e,"&v=").concat(O),l=(0,t.ZP)(e?n:null,a.openmrsFetch),i=l.data,s=l.error,d=l.isLoading,c=l.isValidating,u=l.mutate,p=(null==i||null===(r=i.data)||void 0===r?void 0:r.results.length)>0?null==i?void 0:i.data.results.sort((function(e,r){return r.dateEnrolled>e.dateEnrolled?1:-1})):null,m=null==p?void 0:p.filter((function(e){return!e.dateCompleted}));return{data:i?(0,o.Z)(p,(function(e){var r;return null==e||null===(r=e.program)||void 0===r?void 0:r.uuid})):null,error:s,isLoading:d,isValidating:c,activeEnrollments:m,mutateEnrollments:u}}function x(e){var r,n,o=(0,t.ZP)("".concat(a.restBaseUrl,"/program?v=custom:(uuid,display,allWorkflows,concept:(uuid,display))"),a.openmrsFetch),l=o.data,i=o.error,s=o.isLoading,d=null!==(n=null==l||null===(r=l.data)||void 0===r?void 0:r.results)&&void 0!==n?n:null;return{data:d,error:i,isLoading:s,eligiblePrograms:g(d,(function(r){return!w(C(e,"program.uuid"),r.uuid)}))}}function _(e,r){if(!e)return null;var n=e.program,t=e.patient,o=e.dateEnrolled,l=e.dateCompleted,i=e.location;return(0,a.openmrsFetch)("".concat(a.restBaseUrl,"/programenrollment"),{method:"POST",headers:{"Content-Type":"application/json"},body:{program:n,patient:t,dateEnrolled:o,dateCompleted:l,location:i},signal:r.signal})}function S(e,r,n){if(!r&&!r.program)return null;var t=r.dateEnrolled,o=r.dateCompleted,l=r.location;return(0,a.openmrsFetch)("".concat(a.restBaseUrl,"/programenrollment/").concat(e),{method:"POST",headers:{"Content-Type":"application/json"},body:{dateEnrolled:t,dateCompleted:o,location:l},signal:n.signal})}var D=function(e){var r,n,t=j(e),a=t.data,o=t.error,l=t.isLoading,i=t.isValidating,s=t.activeEnrollments,d=x(a),c=d.data,u=d.eligiblePrograms;return r=function(e){for(var r=1;r<arguments.length;r++){var n=null!=arguments[r]?arguments[r]:{},t=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(t=t.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),t.forEach((function(r){P(e,r,n[r])}))}return e}({enrollments:a},{isLoading:l,error:o}),n=null!=(n={isValidating:i,activeEnrollments:s,availablePrograms:c,eligiblePrograms:u})?n:{},Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(n)):function(e,r){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);n.push.apply(n,t)}return n}(Object(n)).forEach((function(e){Object.defineProperty(r,e,Object.getOwnPropertyDescriptor(n,e))})),r}},3979:(e,r,n)=>{var t={"./am.json":[8788,788],"./ar.json":[4460,460],"./en.json":[3574,574],"./es.json":[8319,319],"./fr.json":[2757,757],"./he.json":[5833,833],"./km.json":[7807,807],"./zh.json":[8271,271],"./zh_CN.json":[1644,644]};function a(e){if(!n.o(t,e))return Promise.resolve().then((()=>{var r=new Error("Cannot find module '"+e+"'");throw r.code="MODULE_NOT_FOUND",r}));var r=t[e],a=r[0];return n.e(r[1]).then((()=>n(a)))}a.keys=()=>Object.keys(t),a.id=3979,e.exports=a}}]);
|
|
1
|
+
(globalThis.webpackChunk_openmrs_esm_patient_programs_app=globalThis.webpackChunk_openmrs_esm_patient_programs_app||[]).push([[81],{3922:(e,r,n)=>{"use strict";n.d(r,{Z:()=>i});var t=n(5698),a=n.n(t),o=n(9613),l=n.n(o)()(a());l.push([e.id,":root{--brand-01: #005d5d;--brand-02: #004144;--brand-03: #007d79;--bottom-nav-height: 4rem;--workspace-header-height: 3rem;--tablet-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--bottom-nav-height));--desktop-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--workspace-header-height))}.-esm-patient-programs__programs-detailed-summary__widgetCard___Qfbyc{border:1px solid #e0e0e0;border-bottom:none}","",{version:3,sources:["webpack://./../../node_modules/@openmrs/esm-styleguide/src/_vars.scss","webpack://./src/programs/programs-detailed-summary.scss"],names:[],mappings:"AAoDA,MACE,mBAAA,CACA,mBAAA,CACA,mBAAA,CACA,yBAAA,CACA,+BAAA,CACA,oGAAA,CACA,2GAAA,CCzDF,sEACE,wBAAA,CACA,kBAAA",sourcesContent:["$ui-01: #f4f4f4;\n$ui-02: #ffffff;\n$ui-03: #e0e0e0;\n$ui-04: #8d8d8d;\n$ui-05: #161616;\n$text-02: #525252;\n$text-03: #a8a8a8;\n$ui-background: #ffffff;\n$color-gray-30: #c6c6c6;\n$color-gray-70: #525252;\n$color-gray-100: #161616;\n$color-blue-60-2: #0f62fe;\n$color-blue-10: #edf5ff;\n$color-yellow-50: #feecae;\n$carbon--red-50: #fa4d56;\n$inverse-link: #78a9ff;\n$support-02: #24a148;\n$inverse-support-03: #f1c21b;\n$warning-background: #fff8e1;\n$openmrs-background-grey: #f4f4f4;\n$danger: #da1e28;\n$interactive-01: #0f62fe;\n$field-01: #f4f4f4;\n$grey-2: #e0e0e0;\n$labeldropdown: #c6c6c6;\n\n$brand-primary-10: #d9fbfb;\n$brand-primary-20: #9ef0f0;\n$brand-primary-30: #3ddbd9;\n$brand-primary-40: #08bdba;\n$brand-primary-50: #009d9a;\n\n/* 60,70 and 80 are already declared as brand-01, 02 and 03 respectively */\n\n$brand-primary-90: #022b30;\n$brand-primary-100: #081a1c;\n\n@mixin brand-01($property) {\n #{$property}: #005d5d;\n #{$property}: var(--brand-01);\n}\n\n@mixin brand-02($property) {\n #{$property}: #004144;\n #{$property}: var(--brand-02);\n}\n\n@mixin brand-03($property) {\n #{$property}: #007d79;\n #{$property}: var(--brand-03);\n}\n\n:root {\n --brand-01: #005d5d;\n --brand-02: #004144;\n --brand-03: #007d79;\n --bottom-nav-height: 4rem;\n --workspace-header-height: 3rem;\n --tablet-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--bottom-nav-height));\n --desktop-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--workspace-header-height));\n}\n\n$breakpoint-phone-min: 0px;\n$breakpoint-phone-max: 600px;\n$breakpoint-tablet-min: 601px;\n$breakpoint-tablet-max: 1023px;\n$breakpoint-small-desktop-min: 1024px;\n$breakpoint-small-desktop-max: 1439px;\n$breakpoint-large-desktop-min: 1440px;\n$breakpoint-large-desktop-max: 99999999px;\n\n/* These color variables will be removed in a future release */\n$brand-teal-01: #007d79;\n$brand-01: #005d5d;\n$brand-02: #004144;\n","@use '@openmrs/esm-styleguide/src/vars' as *;\n\n.widgetCard {\n border: 1px solid $ui-03;\n border-bottom: none;\n}\n"],sourceRoot:""}]),l.locals={widgetCard:"-esm-patient-programs__programs-detailed-summary__widgetCard___Qfbyc"};const i=l},8972:(e,r,n)=>{"use strict";n.d(r,{Z:()=>i});var t=n(5698),a=n.n(t),o=n(9613),l=n.n(o)()(a());l.push([e.id,":root{--brand-01: #005d5d;--brand-02: #004144;--brand-03: #007d79;--bottom-nav-height: 4rem;--workspace-header-height: 3rem;--tablet-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--bottom-nav-height));--desktop-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--workspace-header-height))}.-esm-patient-programs__programs-overview__widgetCard___9hNqv{border:1px solid #e0e0e0}","",{version:3,sources:["webpack://./../../node_modules/@openmrs/esm-styleguide/src/_vars.scss","webpack://./src/programs/programs-overview.scss"],names:[],mappings:"AAoDA,MACE,mBAAA,CACA,mBAAA,CACA,mBAAA,CACA,yBAAA,CACA,+BAAA,CACA,oGAAA,CACA,2GAAA,CCzDF,8DACE,wBAAA",sourcesContent:["$ui-01: #f4f4f4;\n$ui-02: #ffffff;\n$ui-03: #e0e0e0;\n$ui-04: #8d8d8d;\n$ui-05: #161616;\n$text-02: #525252;\n$text-03: #a8a8a8;\n$ui-background: #ffffff;\n$color-gray-30: #c6c6c6;\n$color-gray-70: #525252;\n$color-gray-100: #161616;\n$color-blue-60-2: #0f62fe;\n$color-blue-10: #edf5ff;\n$color-yellow-50: #feecae;\n$carbon--red-50: #fa4d56;\n$inverse-link: #78a9ff;\n$support-02: #24a148;\n$inverse-support-03: #f1c21b;\n$warning-background: #fff8e1;\n$openmrs-background-grey: #f4f4f4;\n$danger: #da1e28;\n$interactive-01: #0f62fe;\n$field-01: #f4f4f4;\n$grey-2: #e0e0e0;\n$labeldropdown: #c6c6c6;\n\n$brand-primary-10: #d9fbfb;\n$brand-primary-20: #9ef0f0;\n$brand-primary-30: #3ddbd9;\n$brand-primary-40: #08bdba;\n$brand-primary-50: #009d9a;\n\n/* 60,70 and 80 are already declared as brand-01, 02 and 03 respectively */\n\n$brand-primary-90: #022b30;\n$brand-primary-100: #081a1c;\n\n@mixin brand-01($property) {\n #{$property}: #005d5d;\n #{$property}: var(--brand-01);\n}\n\n@mixin brand-02($property) {\n #{$property}: #004144;\n #{$property}: var(--brand-02);\n}\n\n@mixin brand-03($property) {\n #{$property}: #007d79;\n #{$property}: var(--brand-03);\n}\n\n:root {\n --brand-01: #005d5d;\n --brand-02: #004144;\n --brand-03: #007d79;\n --bottom-nav-height: 4rem;\n --workspace-header-height: 3rem;\n --tablet-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--bottom-nav-height));\n --desktop-workspace-window-height: calc(100vh - var(--omrs-navbar-height) - var(--workspace-header-height));\n}\n\n$breakpoint-phone-min: 0px;\n$breakpoint-phone-max: 600px;\n$breakpoint-tablet-min: 601px;\n$breakpoint-tablet-max: 1023px;\n$breakpoint-small-desktop-min: 1024px;\n$breakpoint-small-desktop-max: 1439px;\n$breakpoint-large-desktop-min: 1440px;\n$breakpoint-large-desktop-max: 99999999px;\n\n/* These color variables will be removed in a future release */\n$brand-teal-01: #007d79;\n$brand-01: #005d5d;\n$brand-02: #004144;\n","@use '@openmrs/esm-styleguide/src/vars' as *;\n\n.widgetCard {\n border: 1px solid $ui-03;\n}\n"],sourceRoot:""}]),l.locals={widgetCard:"-esm-patient-programs__programs-overview__widgetCard___9hNqv"};const i=l},6081:(e,r,n)=>{"use strict";n.r(r),n.d(r,{importTranslation:()=>H,programsDashboardLink:()=>G,programsDetailedSummary:()=>q,programsFormWorkspace:()=>Q,programsOverview:()=>V,startupApp:()=>M});var t=n(2870),a=n(884),o={hideAddProgramButton:{_type:t.Type.Boolean,_default:!1}},l=n(268),i=n.n(l),s=n(2524),d=n.n(s),c=n(4924),u=n(8219),p=n(6759),m=n(8101),b=n(321),g=n.n(b),f=n(1195),v=n.n(f),h=n(3275),y=n.n(h),k=n(7162),$=n.n(k),A=n(2094),w=n.n(A),E=n(757),C=n.n(E),P=n(8972),O={};O.styleTagTransform=C(),O.setAttributes=$(),O.insert=y().bind(null,"head"),O.domAPI=v(),O.insertStyleElement=w(),g()(P.Z,O);const j=P.Z&&P.Z.locals?P.Z.locals:void 0;function x(e,r,n){return r in e?Object.defineProperty(e,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[r]=n,e}function _(e){for(var r=1;r<arguments.length;r++){var n=null!=arguments[r]?arguments[r]:{},t=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(t=t.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),t.forEach((function(r){x(e,r,n[r])}))}return e}var S=n(7631),D=n(3922),Z={};Z.styleTagTransform=C(),Z.setAttributes=$(),Z.insert=y().bind(null,"head"),Z.domAPI=v(),Z.insertStyleElement=w(),g()(D.Z,Z);const T=D.Z&&D.Z.locals?D.Z.locals:void 0;function B(e,r,n){return r in e?Object.defineProperty(e,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[r]=n,e}function L(e){for(var r=1;r<arguments.length;r++){var n=null!=arguments[r]?arguments[r]:{},t=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(t=t.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),t.forEach((function(r){B(e,r,n[r])}))}return e}function z(e){var r=e.programEnrollmentId,n=e.t,o="tablet"===(0,t.useLayoutType)(),s=(0,l.useCallback)((function(){return(0,a.launchPatientWorkspace)("programs-form-workspace",{programEnrollmentId:r})}),[r]);return i().createElement(u.zxk,{"aria-label":"edit program",kind:"ghost",renderIcon:function(e){return i().createElement(S.I8,L({size:16},e))},iconDescription:n("editProgram","Edit Program"),onClick:s,hasIconOnly:!0,tooltipPosition:"left",size:o?"lg":"sm"})}function I(e,r,n){return r in e?Object.defineProperty(e,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[r]=n,e}var N="@openmrs/esm-patient-programs-app",F={featureName:"patient-programs",moduleName:N},H=n(3979);function M(){(0,t.defineConfigSchema)(N,o)}var U,W,V=(0,t.getSyncLifecycle)((function(e){e.basePath;var r=e.patientUuid,n=(0,c.useTranslation)().t,o=(0,t.useConfig)(),l=n("programs","Program enrollments"),s=n("carePrograms","Care Programs"),b=n("seeAll","See all"),g="${openmrsSpaBase}/patient/".concat(r,"/chart/Programs"),f=(0,t.useLayoutType)(),v="tablet"===f,h=(0,t.isDesktop)(f),y=(0,m.b$)(r),k=y.activeEnrollments,$=y.availablePrograms,A=y.eligiblePrograms,w=y.enrollments,E=y.error,C=y.isLoading,P=y.isValidating,O=(0,t.usePagination)(null!=w?w:[],5),x=O.results,S=O.goTo,D=O.currentPage,Z=i().useCallback((function(){return(0,a.launchPatientWorkspace)("programs-form-workspace")}),[]),T=[{key:"display",header:n("activePrograms","Active programs")},{key:"location",header:n("location","Location")},{key:"dateEnrolled",header:n("dateEnrolled","Date enrolled")},{key:"status",header:n("status","Status")},{key:"actions",header:n("actions","Actions")}],B=i().useMemo((function(){return null==x?void 0:x.map((function(e){var r,a;return{id:e.uuid,display:e.display,location:null!==(a=null===(r=e.location)||void 0===r?void 0:r.display)&&void 0!==a?a:"--",dateEnrolled:e.dateEnrolled?(0,t.formatDatetime)(new Date(e.dateEnrolled)):"--",status:e.dateCompleted?"".concat(n("completedOn","Completed On")," ").concat((0,t.formatDate)(new Date(e.dateCompleted))):n("active","Active")}}))}),[x,n]);return C?i().createElement(u.gqd,{role:"progressbar",compact:h,zebra:!0}):E?i().createElement(a.ErrorState,{error:E,headerTitle:s}):(null==k?void 0:k.length)?i().createElement("div",{className:j.widgetCard},i().createElement(a.CardHeader,{title:s},i().createElement("span",null,P?i().createElement(u.lSo,null):null),o.hideAddProgramButton?null:i().createElement(u.zxk,{kind:"ghost",renderIcon:function(e){return i().createElement(p.mm,_({size:16},e))},iconDescription:"Add programs",onClick:Z,disabled:(null==$?void 0:$.length)&&0===(null==A?void 0:A.length)},n("add","Add"))),(null==$?void 0:$.length)&&0===(null==A?void 0:A.length)&&i().createElement(u.K0D,{style:{minWidth:"100%",margin:"0",padding:"0"},kind:"info",lowContrast:!0,subtitle:n("noEligibleEnrollments","There are no more programs left to enroll this patient in"),title:n("fullyEnrolled","Enrolled in all programs")}),i().createElement(u.wQF,{rows:B,headers:T,isSortable:!0,size:v?"lg":"sm",useZebraStyles:!0},(function(e){var r=e.rows,n=e.headers,t=e.getHeaderProps,a=e.getTableProps;return i().createElement(u.xJi,null,i().createElement(u.iA_,_({"aria-label":"programs overview"},a()),i().createElement(u.ssF,null,i().createElement(u.SCH,null,n.map((function(e){var r,n;return i().createElement(u.xDH,_({className:d()(j.productiveHeading01,j.text02)},t({header:e,isSortable:e.isSortable})),null!==(n=null===(r=e.header)||void 0===r?void 0:r.content)&&void 0!==n?n:e.header)})))),i().createElement(u.RMI,null,r.map((function(e){return i().createElement(u.SCH,{key:e.id},e.cells.map((function(e){var r,n;return i().createElement(u.pj1,{key:e.id},null!==(n=null===(r=e.value)||void 0===r?void 0:r.content)&&void 0!==n?n:e.value)})))})))))})),i().createElement(a.PatientChartPagination,{currentItems:x.length,onPageNumberChange:function(e){var r=e.page;return S(r)},pageNumber:D,pageSize:5,totalItems:null==w?void 0:w.length,dashboardLinkUrl:g,dashboardLinkLabel:b})):i().createElement(a.EmptyState,{displayText:l,headerTitle:s,launchForm:Z})}),F),q=(0,t.getSyncLifecycle)((function(e){var r=e.patientUuid,n=(0,c.useTranslation)().t,o=(0,t.useConfig)().hideAddProgramButton,s=(0,t.useLayoutType)(),b="tablet"===s,g=(0,t.isDesktop)(s),f=n("programEnrollments","Program enrollments"),v=n("carePrograms","Care Programs"),h=(0,m.b$)(r),y=h.enrollments,k=h.isLoading,$=h.error,A=h.isValidating,w=h.availablePrograms,E=(0,l.useMemo)((function(){return[{key:"display",header:n("activePrograms","Active programs")},{key:"location",header:n("location","Location")},{key:"dateEnrolled",header:n("dateEnrolled","Date enrolled")},{key:"status",header:n("status","Status")}]}),[n]),C=(0,l.useMemo)((function(){return null==y?void 0:y.map((function(e){var r,a;return{id:e.uuid,display:e.display,location:null!==(a=null===(r=e.location)||void 0===r?void 0:r.display)&&void 0!==a?a:"--",dateEnrolled:(0,t.formatDatetime)(new Date(e.dateEnrolled)),status:e.dateCompleted?"".concat(n("completedOn","Completed On")," ").concat((0,t.formatDate)(new Date(e.dateCompleted))):n("active","Active")}}))}),[y,n]),P=(0,l.useCallback)((function(){return(0,a.launchPatientWorkspace)("programs-form-workspace")}),[]),O=(0,l.useMemo)((function(){return!(!(null==w?void 0:w.length)||!(null==y?void 0:y.length))&&y.filter((function(e){return!e.dateCompleted})).length===w.length}),[w,y]);return k?i().createElement(u.gqd,{role:"progressbar",compact:g,zebra:!0}):$?i().createElement(a.ErrorState,{error:$,headerTitle:v}):(null==y?void 0:y.length)?i().createElement("div",{className:T.widgetCard},i().createElement(a.CardHeader,{title:v},i().createElement("span",null,A?i().createElement(u.lSo,null):null),o?null:i().createElement(u.zxk,{disabled:O,kind:"ghost",renderIcon:function(e){return i().createElement(p.mm,L({size:16},e))},iconDescription:n("addPrograms","Add programs"),onClick:P},n("add","Add"))),O&&i().createElement(u.K0D,{style:{minWidth:"100%",margin:"0",padding:"0"},lowContrast:!0,subtitle:n("noEligibleEnrollments","There are no more programs left to enroll this patient in"),title:n("fullyEnrolled","Enrolled in all programs")}),i().createElement(u.wQF,{rows:C,headers:E,isSortable:!0,size:b?"lg":"sm",useZebraStyles:!0},(function(e){var r=e.rows,t=e.headers,a=e.getHeaderProps,o=e.getTableProps;return i().createElement(u.xJi,null,i().createElement(u.iA_,L({"aria-label":"program enrollments"},o()),i().createElement(u.ssF,null,i().createElement(u.SCH,null,t.map((function(e){var r,n;return i().createElement(u.xDH,L({className:d()(T.productiveHeading01,T.text02)},a({header:e,isSortable:e.isSortable})),null!==(n=null===(r=e.header)||void 0===r?void 0:r.content)&&void 0!==n?n:e.header)})),i().createElement(u.xDH,null))),i().createElement(u.RMI,null,r.map((function(e,r){var t;return i().createElement(u.SCH,{key:e.id},e.cells.map((function(e){var r,n;return i().createElement(u.pj1,{key:e.id},null!==(n=null===(r=e.value)||void 0===r?void 0:r.content)&&void 0!==n?n:e.value)})),i().createElement(u.pj1,{className:"cds--table-column-menu"},i().createElement(z,{programEnrollmentId:null===(t=y[r])||void 0===t?void 0:t.uuid,t:n})))})))))}))):i().createElement(a.EmptyState,{displayText:f,headerTitle:v,launchForm:P})}),F),G=(0,t.getSyncLifecycle)((0,a.createDashboardLink)((U=function(e){for(var r=1;r<arguments.length;r++){var n=null!=arguments[r]?arguments[r]:{},t=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(t=t.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),t.forEach((function(r){I(e,r,n[r])}))}return e}({},{slot:"patient-chart-programs-dashboard-slot",path:"Programs",title:"Programs"}),W=null!=(W={moduleName:N})?W:{},Object.getOwnPropertyDescriptors?Object.defineProperties(U,Object.getOwnPropertyDescriptors(W)):function(e,r){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);n.push.apply(n,t)}return n}(Object(W)).forEach((function(e){Object.defineProperty(U,e,Object.getOwnPropertyDescriptor(W,e))})),U)),F),Q=(0,t.getAsyncLifecycle)((function(){return Promise.all([n.e(940),n.e(577)]).then(n.bind(n,1577))}),F)},8101:(e,r,n)=>{"use strict";n.d(r,{df:()=>_,YX:()=>S,oI:()=>x,Bw:()=>j,b$:()=>D});var t=n(3255),a=n(2870),o=n(4221),l=n(2300);const i=function(e,r,n){for(var t=-1,a=Object(e),o=n(e),l=o.length;l--;){var i=o[++t];if(!1===r(a[i],i,a))break}return e};var s=n(649);var d=n(3282);const c=(u=function(e,r){return e&&i(e,r,s.Z)},function(e,r){if(null==e)return e;if(!(0,d.Z)(e))return u(e,r);for(var n=e.length,t=-1,a=Object(e);++t<n&&!1!==r(a[t],t,a););return e});var u;const p=function(e,r){var n=[];return c(e,(function(e,t,a){r(e,t,a)&&n.push(e)})),n};var m=n(2448),b=n(7885);const g=function(e,r){return((0,b.Z)(e)?l.Z:p)(e,(0,m.Z)(r,3))};var f=n(7626),v=n(8147),h=n(3391);var y=n(5385),k=n(5598);const $=function(e){return null==e?[]:function(e,r){return(0,k.Z)(r,(function(r){return e[r]}))}(e,(0,s.Z)(e))};var A=Math.max;const w=function(e,r,n,t){e=(0,d.Z)(e)?e:$(e),n=n&&!t?(0,y.Z)(n):0;var a=e.length;return n<0&&(n=A(a+n,0)),function(e){return"string"==typeof e||!(0,b.Z)(e)&&(0,h.Z)(e)&&"[object String]"==(0,v.Z)(e)}(e)?n<=a&&e.indexOf(r,n)>-1:!!a&&(0,f.Z)(e,r,n)>-1},E=function(e,r){var n=-1,t=(0,d.Z)(e)?Array(e.length):[];return c(e,(function(e,a,o){t[++n]=r(e,a,o)})),t},C=function(e,r){return((0,b.Z)(e)?k.Z:E)(e,(0,m.Z)(r,3))};function P(e,r,n){return r in e?Object.defineProperty(e,r,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[r]=n,e}var O="custom:(uuid,display,program,dateEnrolled,dateCompleted,location:(uuid,display))";function j(e){var r,n="".concat(a.restBaseUrl,"/programenrollment?patient=").concat(e,"&v=").concat(O),l=(0,t.ZP)(e?n:null,a.openmrsFetch),i=l.data,s=l.error,d=l.isLoading,c=l.isValidating,u=l.mutate,p=(null==i||null===(r=i.data)||void 0===r?void 0:r.results.length)>0?null==i?void 0:i.data.results.sort((function(e,r){return r.dateEnrolled>e.dateEnrolled?1:-1})):null,m=null==p?void 0:p.filter((function(e){return!e.dateCompleted}));return{data:i?(0,o.Z)(p,(function(e){var r;return null==e||null===(r=e.program)||void 0===r?void 0:r.uuid})):null,error:s,isLoading:d,isValidating:c,activeEnrollments:m,mutateEnrollments:u}}function x(e){var r,n,o=(0,t.ZP)("".concat(a.restBaseUrl,"/program?v=custom:(uuid,display,allWorkflows,concept:(uuid,display))"),a.openmrsFetch),l=o.data,i=o.error,s=o.isLoading,d=null!==(n=null==l||null===(r=l.data)||void 0===r?void 0:r.results)&&void 0!==n?n:null;return{data:d,error:i,isLoading:s,eligiblePrograms:g(d,(function(r){return!w(C(e,"program.uuid"),r.uuid)}))}}function _(e,r){if(!e)return null;var n=e.program,t=e.patient,o=e.dateEnrolled,l=e.dateCompleted,i=e.location;return(0,a.openmrsFetch)("".concat(a.restBaseUrl,"/programenrollment"),{method:"POST",headers:{"Content-Type":"application/json"},body:{program:n,patient:t,dateEnrolled:o,dateCompleted:l,location:i},signal:r.signal})}function S(e,r,n){if(!r&&!r.program)return null;var t=r.dateEnrolled,o=r.dateCompleted,l=r.location;return(0,a.openmrsFetch)("".concat(a.restBaseUrl,"/programenrollment/").concat(e),{method:"POST",headers:{"Content-Type":"application/json"},body:{dateEnrolled:t,dateCompleted:o,location:l},signal:n.signal})}var D=function(e){var r,n,t=j(e),a=t.data,o=t.error,l=t.isLoading,i=t.isValidating,s=t.activeEnrollments,d=x(a),c=d.data,u=d.eligiblePrograms;return r=function(e){for(var r=1;r<arguments.length;r++){var n=null!=arguments[r]?arguments[r]:{},t=Object.keys(n);"function"==typeof Object.getOwnPropertySymbols&&(t=t.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),t.forEach((function(r){P(e,r,n[r])}))}return e}({enrollments:a},{isLoading:l,error:o}),n=null!=(n={isValidating:i,activeEnrollments:s,availablePrograms:c,eligiblePrograms:u})?n:{},Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(n)):function(e,r){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(e);n.push.apply(n,t)}return n}(Object(n)).forEach((function(e){Object.defineProperty(r,e,Object.getOwnPropertyDescriptor(n,e))})),r}},3979:(e,r,n)=>{var t={"./am.json":[8788,788],"./ar.json":[4460,460],"./en.json":[3574,574],"./es.json":[8319,319],"./fr.json":[2757,757],"./he.json":[5833,833],"./km.json":[7807,807],"./zh.json":[8271,271],"./zh_CN.json":[1644,644]};function a(e){if(!n.o(t,e))return Promise.resolve().then((()=>{var r=new Error("Cannot find module '"+e+"'");throw r.code="MODULE_NOT_FOUND",r}));var r=t[e],a=r[0];return n.e(r[1]).then((()=>n(a)))}a.keys=()=>Object.keys(t),a.id=3979,e.exports=a}}]);
|
package/dist/81.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"81.js","mappings":"kNAGIA,E,MAA0B,GAA4B,KAE1DA,EAAwBC,KAAK,CAACC,EAAOC,GAAI,kcAAmc,GAAG,CAAC,QAAU,EAAE,QAAU,CAAC,wEAAwE,2DAA2D,MAAQ,GAAG,SAAW,kHAAkH,eAAiB,CAAC,o7DAAo7D,4HAA4H,WAAa,MAEj2FH,EAAwBI,OAAS,CAChC,WAAc,wEAEf,S,gFCPIJ,E,MAA0B,GAA4B,KAE1DA,EAAwBC,KAAK,CAACC,EAAOC,GAAI,uaAAwa,GAAG,CAAC,QAAU,EAAE,QAAU,CAAC,wEAAwE,mDAAmD,MAAQ,GAAG,SAAW,uGAAuG,eAAiB,CAAC,o7DAAo7D,oGAAoG,WAAa,MAE3xFH,EAAwBI,OAAS,CAChC,WAAc,gEAEf,S,2NCRaC,EAAe,CAC1BC,qBAAsB,CACpBC,MAAOC,EAAAA,KAAKC,QACZC,UAAU,I,uMCMVC,EAAU,CAAC,EAEfA,EAAQC,kBAAoB,IAC5BD,EAAQE,cAAgB,IAElBF,EAAQG,OAAS,SAAc,KAAM,QAE3CH,EAAQI,OAAS,IACjBJ,EAAQK,mBAAqB,IAEhB,IAAI,IAASL,GAKnB,QAAe,KAAW,IAAQP,OAAS,IAAQA,YAASa,E,wdCf/D,EAAU,CAAC,EAEf,EAAQL,kBAAoB,IAC5B,EAAQC,cAAgB,IAElB,EAAQC,OAAS,SAAc,KAAM,QAE3C,EAAQC,OAAS,IACjB,EAAQC,mBAAqB,IAEhB,IAAI,IAAS,GAKnB,QAAe,KA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E5B,CAEO,IAAM/I,EAAc,SAACX,GAC1B,I,IAMIqI,EAAAA,EAAerI,GALjBsI,EAKED,EALFC,KACAtH,EAIEqH,EAJFrH,MACAC,EAGEoH,EAHFpH,UACAC,EAEEmH,EAFFnH,aACAN,EACEyH,EADFzH,kBAEoDsI,EAAAA,EAAqBnI,GAAnEuH,EAA8CY,EAA9CZ,KAAyBxH,EAAqBoI,EAArBpI,iBAGjC,O,wUAAO,EACLC,YAAAA,GAFa,CAAEE,UAAW4I,EAAc7I,MAAO8I,I,WAG5CxH,CACHpB,aAAAA,EACAN,kBAAAA,EACAC,kBAAAA,EACAC,iBAAAA,I,+UAEJ,C,iBCxGA,IAAIgB,EAAM,CACT,YAAa,CACZ,KACA,KAED,YAAa,CACZ,KACA,KAED,YAAa,CACZ,KACA,KAED,YAAa,CACZ,KACA,KAED,YAAa,CACZ,KACA,KAED,YAAa,CACZ,KACA,KAED,YAAa,CACZ,KACA,KAED,YAAa,CACZ,KACA,KAED,eAAgB,CACf,KACA,MAGF,SAASiI,EAAoBC,GAC5B,IAAIC,EAAoBC,EAAEpI,EAAKkI,GAC9B,OAAOG,QAAQC,UAAUC,MAAK,KAC7B,IAAIC,EAAI,IAAIC,MAAM,uBAAyBP,EAAM,KAEjD,MADAM,EAAEE,KAAO,mBACHF,CAAC,IAIT,IAAIG,EAAM3I,EAAIkI,GAAM3M,EAAKoN,EAAI,GAC7B,OAAOR,EAAoBK,EAAEG,EAAI,IAAIJ,MAAK,IAClCJ,EAAoB5M,IAE7B,CACA0M,EAAoB1C,KAAO,IAAOF,OAAOE,KAAKvF,GAC9CiI,EAAoB1M,GAAK,KACzBD,EAAOsN,QAAUX,C","sources":["webpack://@openmrs/esm-patient-programs-app/./src/programs/programs-detailed-summary.scss","webpack://@openmrs/esm-patient-programs-app/./src/programs/programs-overview.scss","webpack://@openmrs/esm-patient-programs-app/./src/config-schema.ts","webpack://@openmrs/esm-patient-programs-app/./src/programs/programs-overview.scss?5254","webpack://@openmrs/esm-patient-programs-app/./src/programs/programs-detailed-summary.scss?6404","webpack://@openmrs/esm-patient-programs-app/./src/programs/programs-detailed-summary.component.tsx","webpack://@openmrs/esm-patient-programs-app/./src/index.ts","webpack://@openmrs/esm-patient-programs-app/./src/programs/programs-overview.component.tsx","webpack://@openmrs/esm-patient-programs-app/./src/dashboard.meta.ts","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/_baseFor.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/_createBaseFor.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/_baseEach.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/_createBaseEach.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/_baseForOwn.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/_baseFilter.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/filter.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/_baseValues.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/values.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/includes.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/isString.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/_baseMap.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/map.js","webpack://@openmrs/esm-patient-programs-app/./src/programs/programs.resource.tsx","webpack://@openmrs/esm-patient-programs-app/./translations/ lazy nonrecursive .json$"],"names":["___CSS_LOADER_EXPORT___","push","module","id","locals","configSchema","hideAddProgramButton","_type","Type","Boolean","_default","options","styleTagTransform","setAttributes","insert","domAPI","insertStyleElement","undefined","ProgramEditButton","programEnrollmentId","t","isTablet","useLayoutType","launchEditProgramsForm","useCallback","launchPatientWorkspace","Button","aria-label","kind","renderIcon","props","Edit","size","iconDescription","onClick","hasIconOnly","tooltipPosition","moduleName","featureName","importTranslation","require","startupApp","defineConfigSchema","programsOverview","getSyncLifecycle","basePath","patientUuid","useTranslation","config","useConfig","displayText","headerTitle","urlLabel","pageUrl","layout","isDesktop","desktopLayout","usePrograms","activeEnrollments","availablePrograms","eligiblePrograms","enrollments","error","isLoading","isValidating","usePagination","results","goTo","currentPage","launchProgramsForm","React","tableHeaders","key","header","tableRows","paginatedEnrollments","map","enrollment","uuid","display","location","dateEnrolled","formatDatetime","Date","status","dateCompleted","formatDate","DataTableSkeleton","role","compact","zebra","ErrorState","length","div","className","styles","widgetCard","CardHeader","title","span","InlineLoading","Add","disabled","InlineNotification","style","minWidth","margin","padding","lowContrast","subtitle","DataTable","rows","headers","isSortable","useZebraStyles","getHeaderProps","getTableProps","TableContainer","Table","TableHead","TableRow","TableHeader","classNames","productiveHeading01","text02","content","TableBody","row","cells","cell","TableCell","value","PatientChartPagination","currentItems","onPageNumberChange","page","pageNumber","pageSize","totalItems","dashboardLinkUrl","dashboardLinkLabel","EmptyState","launchForm","programsDetailedSummary","useMemo","program","isEnrolledInAllPrograms","filter","i","programsDashboardLink","createDashboardLink","slot","path","dashboardMeta","programsFormWorkspace","getAsyncLifecycle","object","iteratee","keysFunc","index","iterable","Object","eachFunc","keys","collection","isArrayLike","predicate","result","isArray","nativeMax","Math","max","fromIndex","guard","toInteger","isObjectLike","indexOf","Array","customRepresentation","useEnrollments","data","enrollmentsUrl","restBaseUrl","useSWR","openmrsFetch","mutate","formattedEnrollments","sort","a","b","uniqBy","mutateEnrollments","useAvailablePrograms","includes","createProgramEnrollment","payload","abortController","patient","method","body","signal","updateProgramEnrollment","programEnrollmentUuid","enrolLoading","enrollError","webpackAsyncContext","req","__webpack_require__","o","Promise","resolve","then","e","Error","code","ids","exports"],"sourceRoot":""}
|
|
1
|
+
{"version":3,"file":"81.js","mappings":"kNAGIA,E,MAA0B,GAA4B,KAE1DA,EAAwBC,KAAK,CAACC,EAAOC,GAAI,kcAAmc,GAAG,CAAC,QAAU,EAAE,QAAU,CAAC,wEAAwE,2DAA2D,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AAIgB,EAAM,CACT,YAAa,CACZ,KACA,KAED,YAAa,CACZ,KACA,KAED,YAAa,CACZ,KACA,KAED,YAAa,CACZ,KACA,KAED,YAAa,CACZ,KACA,KAED,YAAa,CACZ,KACA,KAED,YAAa,CACZ,KACA,KAED,YAAa,CACZ,KACA,KAED,eAAgB,CACf,KACA,MAGF,SAASiI,EAAoBC,GAC5B,IAAIC,EAAoBC,EAAEpI,EAAKkI,GAC9B,OAAOG,QAAQC,UAAUC,MAAK,KAC7B,IAAIC,EAAI,IAAIC,MAAM,uBAAyBP,EAAM,KAEjD,MADAM,EAAEE,KAAO,mBACHF,CAAC,IAIT,IAAIG,EAAM3I,EAAIkI,GAAM3M,EAAKoN,EAAI,GAC7B,OAAOR,EAAoBK,EAAEG,EAAI,IAAIJ,MAAK,IAClCJ,EAAoB5M,IAE7B,CACA0M,EAAoB1C,KAAO,IAAOF,OAAOE,KAAKvF,GAC9CiI,EAAoB1M,GAAK,KACzBD,EAAOsN,QAAUX,C","sources":["webpack://@openmrs/esm-patient-programs-app/./src/programs/programs-detailed-summary.scss","webpack://@openmrs/esm-patient-programs-app/./src/programs/programs-overview.scss","webpack://@openmrs/esm-patient-programs-app/./src/config-schema.ts","webpack://@openmrs/esm-patient-programs-app/./src/programs/programs-overview.scss?5254","webpack://@openmrs/esm-patient-programs-app/./src/programs/programs-detailed-summary.scss?6404","webpack://@openmrs/esm-patient-programs-app/./src/programs/programs-detailed-summary.component.tsx","webpack://@openmrs/esm-patient-programs-app/./src/index.ts","webpack://@openmrs/esm-patient-programs-app/./src/programs/programs-overview.component.tsx","webpack://@openmrs/esm-patient-programs-app/./src/dashboard.meta.ts","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/_baseFor.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/_createBaseFor.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/_baseEach.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/_createBaseEach.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/_baseForOwn.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/_baseFilter.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/filter.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/_baseValues.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/values.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/includes.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/isString.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/_baseMap.js","webpack://@openmrs/esm-patient-programs-app/../../node_modules/lodash-es/map.js","webpack://@openmrs/esm-patient-programs-app/./src/programs/programs.resource.tsx","webpack://@openmrs/esm-patient-programs-app/./translations/ lazy nonrecursive .json$"],"names":["___CSS_LOADER_EXPORT___","push","module","id","locals","configSchema","hideAddProgramButton","_type","Type","Boolean","_default","options","styleTagTransform","setAttributes","insert","domAPI","insertStyleElement","undefined","ProgramEditButton","programEnrollmentId","t","isTablet","useLayoutType","launchEditProgramsForm","useCallback","launchPatientWorkspace","Button","aria-label","kind","renderIcon","props","Edit","size","iconDescription","onClick","hasIconOnly","tooltipPosition","moduleName","featureName","importTranslation","require","startupApp","defineConfigSchema","programsOverview","getSyncLifecycle","basePath","patientUuid","useTranslation","config","useConfig","displayText","headerTitle","urlLabel","pageUrl","layout","isDesktop","desktopLayout","usePrograms","activeEnrollments","availablePrograms","eligiblePrograms","enrollments","error","isLoading","isValidating","usePagination","results","goTo","currentPage","launchProgramsForm","React","tableHeaders","key","header","tableRows","paginatedEnrollments","map","enrollment","uuid","display","location","dateEnrolled","formatDatetime","Date","status","dateCompleted","formatDate","DataTableSkeleton","role","compact","zebra","ErrorState","length","div","className","styles","widgetCard","CardHeader","title","span","InlineLoading","Add","disabled","InlineNotification","style","minWidth","margin","padding","lowContrast","subtitle","DataTable","rows","headers","isSortable","useZebraStyles","getHeaderProps","getTableProps","TableContainer","Table","TableHead","TableRow","TableHeader","classNames","productiveHeading01","text02","content","TableBody","row","cells","cell","TableCell","value","PatientChartPagination","currentItems","onPageNumberChange","page","pageNumber","pageSize","totalItems","dashboardLinkUrl","dashboardLinkLabel","EmptyState","launchForm","programsDetailedSummary","useMemo","program","isEnrolledInAllPrograms","filter","i","programsDashboardLink","createDashboardLink","slot","path","dashboardMeta","programsFormWorkspace","getAsyncLifecycle","object","iteratee","keysFunc","index","iterable","Object","eachFunc","keys","collection","isArrayLike","predicate","result","isArray","nativeMax","Math","max","fromIndex","guard","toInteger","isObjectLike","indexOf","Array","customRepresentation","useEnrollments","data","enrollmentsUrl","restBaseUrl","useSWR","openmrsFetch","mutate","formattedEnrollments","sort","a","b","uniqBy","mutateEnrollments","useAvailablePrograms","includes","createProgramEnrollment","payload","abortController","patient","method","body","signal","updateProgramEnrollment","programEnrollmentUuid","enrolLoading","enrollError","webpackAsyncContext","req","__webpack_require__","o","Promise","resolve","then","e","Error","code","ids","exports"],"sourceRoot":""}
|