@openmrs/esm-patient-orders-app 9.0.1-pre.6550 → 9.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (102) hide show
  1. package/.turbo/turbo-build.log +18 -18
  2. package/dist/1197.js +1 -1
  3. package/dist/2128.js +1 -1
  4. package/dist/2146.js +1 -1
  5. package/dist/2433.js +1 -1
  6. package/dist/2433.js.map +1 -1
  7. package/dist/2667.js +1 -1
  8. package/dist/2690.js +1 -1
  9. package/dist/2879.js +1 -1
  10. package/dist/2879.js.map +1 -1
  11. package/dist/3099.js +1 -1
  12. package/dist/3584.js +1 -1
  13. package/dist/367.js +1 -1
  14. package/dist/367.js.map +1 -1
  15. package/dist/4055.js +1 -1
  16. package/dist/4132.js +1 -1
  17. package/dist/4300.js +1 -1
  18. package/dist/4335.js +1 -1
  19. package/dist/4618.js +1 -1
  20. package/dist/4652.js +1 -1
  21. package/dist/4944.js +1 -1
  22. package/dist/4974.js +1 -1
  23. package/dist/5173.js +1 -1
  24. package/dist/5241.js +1 -1
  25. package/dist/5442.js +1 -1
  26. package/dist/5661.js +1 -1
  27. package/dist/5909.js +1 -1
  28. package/dist/5912.js +2 -0
  29. package/dist/5912.js.map +1 -0
  30. package/dist/6468.js +1 -1
  31. package/dist/6679.js +1 -1
  32. package/dist/6840.js +1 -1
  33. package/dist/6859.js +1 -1
  34. package/dist/7159.js +1 -1
  35. package/dist/723.js +1 -1
  36. package/dist/7493.js +1 -1
  37. package/dist/7493.js.map +1 -1
  38. package/dist/7673.js +1 -1
  39. package/dist/7673.js.map +1 -1
  40. package/dist/7920.js +2 -1
  41. package/dist/7920.js.LICENSE.txt +5 -0
  42. package/dist/7920.js.map +1 -1
  43. package/dist/8618.js +1 -1
  44. package/dist/9214.js +1 -1
  45. package/dist/9538.js +1 -1
  46. package/dist/986.js +1 -1
  47. package/dist/9879.js +1 -1
  48. package/dist/9900.js +1 -1
  49. package/dist/9913.js +1 -1
  50. package/dist/main.js +1 -1
  51. package/dist/main.js.map +1 -1
  52. package/dist/openmrs-esm-patient-orders-app.js +1 -1
  53. package/dist/openmrs-esm-patient-orders-app.js.buildmanifest.json +136 -160
  54. package/dist/openmrs-esm-patient-orders-app.js.map +1 -1
  55. package/dist/routes.json +1 -1
  56. package/package.json +4 -5
  57. package/src/components/orders-details-table.component.tsx +10 -16
  58. package/src/lab-results/lab-results-form-field.component.tsx +31 -14
  59. package/src/lab-results/lab-results-form.component.tsx +21 -9
  60. package/src/lab-results/lab-results-form.test.tsx +10 -4
  61. package/src/order-basket/general-order-type/general-order-form/general-order-form.component.tsx +87 -41
  62. package/src/order-basket/general-order-type/general-order-panel.scss +2 -2
  63. package/src/order-basket/general-order-type/general-order-type.component.tsx +2 -0
  64. package/src/order-basket/general-order-type/orderable-concept-search/orderable-concept-search.workspace.tsx +1 -0
  65. package/src/order-basket/general-order-type/orderable-concept-search/search-results.component.tsx +1 -0
  66. package/src/order-basket/general-order-type/resources.ts +10 -1
  67. package/src/routes.json +2 -3
  68. package/src/utils/index.ts +2 -0
  69. package/translations/am.json +3 -0
  70. package/translations/ar.json +3 -0
  71. package/translations/bn.json +3 -0
  72. package/translations/de.json +3 -0
  73. package/translations/en.json +2 -0
  74. package/translations/es.json +3 -0
  75. package/translations/fr.json +3 -0
  76. package/translations/he.json +3 -0
  77. package/translations/hi.json +3 -0
  78. package/translations/hi_IN.json +3 -0
  79. package/translations/id.json +3 -0
  80. package/translations/it.json +3 -0
  81. package/translations/km.json +3 -0
  82. package/translations/lg.json +3 -0
  83. package/translations/ne.json +3 -0
  84. package/translations/pt.json +3 -0
  85. package/translations/pt_BR.json +3 -0
  86. package/translations/qu.json +3 -0
  87. package/translations/ru_RU.json +3 -0
  88. package/translations/si.json +3 -0
  89. package/translations/sw.json +3 -0
  90. package/translations/sw_KE.json +3 -0
  91. package/translations/tr.json +3 -0
  92. package/translations/tr_TR.json +3 -0
  93. package/translations/uk.json +3 -0
  94. package/translations/uz.json +3 -0
  95. package/translations/vi.json +3 -0
  96. package/translations/zh.json +3 -0
  97. package/translations/zh_CN.json +3 -0
  98. package/dist/3878.js +0 -2
  99. package/dist/3878.js.map +0 -1
  100. package/dist/5050.js +0 -1
  101. package/dist/5050.js.map +0 -1
  102. /package/dist/{3878.js.LICENSE.txt → 5912.js.LICENSE.txt} +0 -0
@@ -1,25 +1,25 @@
1
1
  Browserslist: caniuse-lite is outdated. Please run:
2
2
  npx update-browserslist-db@latest
3
3
  Why you should do it regularly: https://github.com/browserslist/update-db#readme
4
- assets by path *.js 3.54 MiB
5
- assets by chunk 2 MiB (id hint: vendors)
6
- assets by status 1.85 MiB [big]
4
+ assets by path *.js 3.5 MiB
5
+ assets by chunk 1.98 MiB (id hint: vendors)
6
+ assets by status 1.83 MiB [big]
7
7
  asset 367.js 1.38 MiB [emitted] [minimized] [big] (id hint: vendors) 2 related assets
8
- asset 3878.js 479 KiB [emitted] [minimized] [big] (id hint: vendors) 2 related assets
8
+ asset 5912.js 456 KiB [emitted] [minimized] [big] (id hint: vendors) 2 related assets
9
9
  asset 7038.js 75.5 KiB [emitted] [minimized] (id hint: vendors) 1 related asset
10
10
  asset 2913.js 67.8 KiB [emitted] [minimized] (id hint: vendors) 2 related assets
11
11
  asset 9074.js 6.06 KiB [emitted] [minimized] (id hint: vendors) 1 related asset
12
12
  asset 8917.js 5.59 KiB [emitted] [minimized] (id hint: vendors) 2 related assets
13
- + 47 assets
14
- assets by path *.json 27.4 KiB
15
- asset openmrs-esm-patient-orders-app.js.buildmanifest.json 25.8 KiB [emitted]
16
- asset routes.json 1.63 KiB [emitted] [from: src/routes.json] [copied]
17
- orphan modules 4.7 MiB [orphan] 1058 modules
18
- runtime modules 41.5 KiB 28 modules
19
- built modules 8.8 MiB (javascript) 336 bytes (share-init) 336 bytes (consume-shared) [built]
20
- javascript modules 8.68 MiB 156 modules
21
- optional modules 123 KiB [optional]
22
- ./translations/am.json 4.22 KiB [optional] [built] [code generated]
13
+ + 46 assets
14
+ assets by path *.json 27 KiB
15
+ asset openmrs-esm-patient-orders-app.js.buildmanifest.json 25.3 KiB [emitted]
16
+ asset routes.json 1.61 KiB [emitted] [from: src/routes.json] [copied]
17
+ orphan modules 4.71 MiB [orphan] 1060 modules
18
+ runtime modules 41.4 KiB 28 modules
19
+ built modules 8.79 MiB (javascript) 336 bytes (share-init) 336 bytes (consume-shared) [built]
20
+ javascript modules 8.66 MiB 154 modules
21
+ optional modules 127 KiB [optional]
22
+ ./translations/am.json 4.36 KiB [optional] [built] [code generated]
23
23
  + 28 modules
24
24
  provide-module modules 336 bytes
25
25
  modules by path provide shared module (default) @openmrs/ 84 bytes 2 modules
@@ -33,14 +33,14 @@ built modules 8.8 MiB (javascript) 336 bytes (share-init) 336 bytes (consume-sha
33
33
  WARNING in asset size limit: The following asset(s) exceed the recommended size limit (244 KiB).
34
34
  This can impact web performance.
35
35
  Assets:
36
- main.js (699 KiB)
36
+ main.js (677 KiB)
37
37
  367.js (1.38 MiB)
38
- 3878.js (479 KiB)
38
+ 5912.js (456 KiB)
39
39
 
40
40
  WARNING in entrypoint size limit: The following entrypoint(s) combined asset size exceeds the recommended limit (244 KiB). This can impact web performance.
41
41
  Entrypoints:
42
- main (699 KiB)
42
+ main (677 KiB)
43
43
  main.js
44
44
  
45
45
 
46
- webpack 5.94.0 compiled with 2 warnings in 149012 ms
46
+ webpack 5.94.0 compiled with 2 warnings in 63493 ms
package/dist/1197.js CHANGED
@@ -1 +1 @@
1
- "use strict";(globalThis.webpackChunk_openmrs_esm_patient_orders_app=globalThis.webpackChunk_openmrs_esm_patient_orders_app||[]).push([[1197],{1197:e=>{e.exports=JSON.parse('{"actionsMenu":"Actions menu","activeVisitRequired":"An active visit is required to make orders","add":"Add","additionalInstructions":"Additional instructions","addResults":"Add results","allOrders":"All orders","backToOrderBasket":"Back to order basket","cancel":"Cancel","cancellationDate":"Cancellation date","cancellationDateRequired":"Cancellation date is required","cancelOrder":"Cancel order","checkFilters":"Check the filters above","chooseAnOption":"Choose an option","clearSearchResults":"Clear results","dateCannotBeBeforeToday":"Date cannot be before today","dateOfOrder":"Date of order","dateRange":"Date range","directlyAddToBasket":"Add to basket","discard":"Discard","discontinued":"Discontinued","dosage":"Dosage","dose":"Dose","editResults":"Edit results","endDate":"End date","enterTestResults":"Enter test results","error":"Error","errorCancellingOrder":"Error cancelling order","errorFetchingTestTypes":"Error fetching results for \\"{{searchTerm}}\\"","errorSavingLabResults":"Error saving lab results","goToDrugOrderForm":"Order form","indication":"Indication","inStock":"In stock","instructions":"Instructions","labResultError":"Error loading lab results","launchOrderBasket":"Launch order basket","loading":"Loading","loadingInitialValues":"Loading initial values","loadinglabresults":"Loading lab results","loadingTestDetails":"Loading test details","medicationDurationAndUnit":"for {{duration}} {{durationUnit}}","medicationIndefiniteDuration":"Indefinite duration","medications":"Medications","modifyOrder":"Modify order","noMatchingOrdersToDisplay":"No matching orders to display","noResultsForTestTypeSearch":"No results to display for \\"{{searchTerm}}\\"","normalRange":"Normal range","onDate":"on","or":"or","order":"Order","orderableConceptRequired":"Orderable concept is required","orderActionDiscontinue":"Discontinue","orderActionIncomplete":"Incomplete","orderActionNew":"New","orderActionRenew":"Renew","orderActionRevise":"Modify","orderBasket":"Order basket","orderBasketWorkspaceTitle":"Order basket","orderCancellation":"Order cancellation","orderCancelled":"Order cancelled","orderCompleted":"Placed orders","orderDetails":"Order details","ordered":"Placed order for","orderedBy":"Ordered by","ordererInformation":"Orderer information","orderNumber":"Order number","orders":"Orders","Orders":"Orders","orderType":"Order type","outOfStock":"Out of stock","pleaseFillField":"Please fill at least one field","pleaseFillRequiredFields":"Please fill all the required fields","pleaseRequiredFields":"Please fill all required fields","price":"Price","priceDisclaimer":"This price is indicative and may not reflect final costs, which could vary due to discounts, insurance coverage, or other pricing rules","print":"Print","printedBy":"Printed by","printOrder":"Print order","priority":"Priority","priorityRequired":"Priority is required","quantity":"Quantity","reasonForCancellation":"Reason for cancellation","reasonForCancellationRequired":"Reason for cancellation is required","referenceNumber":"Reference number","referenceNumberTableHeader":"{{orderType}} reference number","refills":"Refills","removeFromBasket":"Remove from basket","result":"Result","returnToOrderBasket":"Return to order basket","saveAndClose":"Save and close","saveDrugOrderFailed":"Error ordering {{orderName}}","saveLabResults":"Save lab results","saveOrder":"Save order","saving":"Saving","searchAgain":"search again","searchFieldOrder":"Search for {{orderType}} order","searchOrderables":"Search orderables","searchResultsMatchesForTerm_one":"{{count}} results for \\"{{searchTerm}}\\"","searchResultsMatchesForTerm_other":"{{count}} results for \\"{{searchTerm}}\\"","searchTable":"Search table","selectOrderType":"Select order type","signAndClose":"Sign and close","startAVisitToRecordOrders":"Start a visit to order","startVisit":"Start visit","status":"Status","successfullyCancelledOrder":"Order {{orderNumber}} has been cancelled successfully","successfullySavedLabResults":"Lab results for {{orderNumber}} have been successfully updated","Test Order_few":"Test orders","testType":"Test type","tryReopeningTheWorkspaceAgain":"Please try launching the workspace again","trySearchingAgain":"Please try searching again","tryTo":"Try to","updated":"Updated","usingADifferentTerm":"using a different term"}')}}]);
1
+ "use strict";(globalThis.webpackChunk_openmrs_esm_patient_orders_app=globalThis.webpackChunk_openmrs_esm_patient_orders_app||[]).push([[1197],{1197:e=>{e.exports=JSON.parse('{"actionsMenu":"Actions menu","activeVisitRequired":"An active visit is required to make orders","add":"Add","additionalInstructions":"Additional instructions","addOrderableForOrderType":"Add {{orderTypeDisplay}}","addResults":"Add results","allOrders":"All orders","backToOrderBasket":"Back to order basket","cancel":"Cancel","cancellationDate":"Cancellation date","cancellationDateRequired":"Cancellation date is required","cancelOrder":"Cancel order","checkFilters":"Check the filters above","chooseAnOption":"Choose an option","clearSearchResults":"Clear results","dateCannotBeBeforeToday":"Date cannot be before today","dateOfOrder":"Date of order","dateRange":"Date range","directlyAddToBasket":"Add to basket","discard":"Discard","discontinued":"Discontinued","dosage":"Dosage","dose":"Dose","editResults":"Edit results","endDate":"End date","enterTestResults":"Enter test results","error":"Error","errorCancellingOrder":"Error cancelling order","errorFetchingTestTypes":"Error fetching results for \\"{{searchTerm}}\\"","errorSavingLabResults":"Error saving lab results","goToDrugOrderForm":"Order form","indication":"Indication","inStock":"In stock","instructions":"Instructions","labResultError":"Error loading lab results","launchOrderBasket":"Launch order basket","loading":"Loading","loadingInitialValues":"Loading initial values","loadinglabresults":"Loading lab results","loadingTestDetails":"Loading test details","medicationDurationAndUnit":"for {{duration}} {{durationUnit}}","medicationIndefiniteDuration":"Indefinite duration","medications":"Medications","modifyOrder":"Modify order","noMatchingOrdersToDisplay":"No matching orders to display","noResultsForTestTypeSearch":"No results to display for \\"{{searchTerm}}\\"","normalRange":"Normal range","onDate":"on","or":"or","order":"Order","orderableConceptRequired":"Orderable concept is required","orderActionDiscontinue":"Discontinue","orderActionIncomplete":"Incomplete","orderActionNew":"New","orderActionRenew":"Renew","orderActionRevise":"Modify","orderBasket":"Order basket","orderBasketWorkspaceTitle":"Order basket","orderCancellation":"Order cancellation","orderCancelled":"Order cancelled","orderCompleted":"Placed orders","orderDetails":"Order details","ordered":"Placed order for","orderedBy":"Ordered by","ordererInformation":"Orderer information","orderNumber":"Order number","orders":"Orders","Orders":"Orders","orderType":"Order type","outOfStock":"Out of stock","pleaseFillField":"Please fill at least one field","pleaseFillRequiredFields":"Please fill all the required fields","pleaseRequiredFields":"Please fill all required fields","price":"Price","priceDisclaimer":"This price is indicative and may not reflect final costs, which could vary due to discounts, insurance coverage, or other pricing rules","print":"Print","printedBy":"Printed by","printOrder":"Print order","priority":"Priority","priorityRequired":"Priority is required","quantity":"Quantity","reasonForCancellation":"Reason for cancellation","reasonForCancellationRequired":"Reason for cancellation is required","referenceNumber":"Reference number","referenceNumberTableHeader":"{{orderType}} reference number","refills":"Refills","removeFromBasket":"Remove from basket","result":"Result","returnToOrderBasket":"Return to order basket","saveAndClose":"Save and close","saveDrugOrderFailed":"Error ordering {{orderName}}","saveLabResults":"Save lab results","saveOrder":"Save order","saving":"Saving","scheduledDate":"Scheduled date","scheduledDateRequired":"Scheduled date is required","searchAgain":"search again","searchFieldOrder":"Search for {{orderType}} order","searchOrderables":"Search orderables","searchResultsMatchesForTerm_one":"{{count}} results for \\"{{searchTerm}}\\"","searchResultsMatchesForTerm_other":"{{count}} results for \\"{{searchTerm}}\\"","searchTable":"Search table","selectOrderType":"Select order type","signAndClose":"Sign and close","startAVisitToRecordOrders":"Start a visit to order","startVisit":"Start visit","status":"Status","successfullyCancelledOrder":"Order {{orderNumber}} has been cancelled successfully","successfullySavedLabResults":"Lab results for {{orderNumber}} have been successfully updated","Test Order_few":"Test orders","testType":"Test type","tryReopeningTheWorkspaceAgain":"Please try launching the workspace again","trySearchingAgain":"Please try searching again","tryTo":"Try to","updated":"Updated","usingADifferentTerm":"using a different term"}')}}]);
package/dist/2128.js CHANGED
@@ -1 +1 @@
1
- "use strict";(globalThis.webpackChunk_openmrs_esm_patient_orders_app=globalThis.webpackChunk_openmrs_esm_patient_orders_app||[]).push([[2128],{2295:(e,n,t)=>{t.d(n,{A:()=>l});var a=t(5836),i=t.n(a),r=t(8023),o=t.n(r)()(i());o.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-orders__cancel-order-form__productiveHeading03___k\\+Vts,.-esm-patient-orders__cancel-order-form__title___TOkA-{font-size:var(--cds-heading-03-font-size, 1.25rem);font-weight:var(--cds-heading-03-font-weight, 400);line-height:var(--cds-heading-03-line-height, 1.4);letter-spacing:var(--cds-heading-03-letter-spacing, 0)}.-esm-patient-orders__cancel-order-form__title___TOkA-{margin:0 .5rem .5rem 0}.-esm-patient-orders__cancel-order-form__orderDisplay___ZQie-{margin-bottom:1rem}.-esm-patient-orders__cancel-order-form__danger___VGCx8{color:#da1e28}.-esm-patient-orders__cancel-order-form__button___xVUqX{height:4rem;display:flex;align-content:flex-start;align-items:baseline;min-width:50%}.-esm-patient-orders__cancel-order-form__button___xVUqX .cds--inline-loading{min-height:1rem !important}.-esm-patient-orders__cancel-order-form__button___xVUqX .cds--inline-loading__text{font-size:unset !important}.-esm-patient-orders__cancel-order-form__tablet___wLQCv{padding:1.5rem 1rem;background-color:#fff}.-esm-patient-orders__cancel-order-form__desktop___Jq1HN{padding:0}.-esm-patient-orders__cancel-order-form__form___7NxDA{display:flex;flex-direction:column;justify-content:space-between;height:100%}.omrs-breakpoint-lt-desktop .-esm-patient-orders__cancel-order-form__form___7NxDA{background-color:#ededed}.omrs-breakpoint-gt-tablet .-esm-patient-orders__cancel-order-form__form___7NxDA{background-color:#fff}.-esm-patient-orders__cancel-order-form__grid___wg6M-{margin:1rem}.-esm-patient-orders__cancel-order-form__row___Afnej{margin:.5rem 0 0;display:flex;flex-flow:row wrap;gap:1rem}.-esm-patient-orders__cancel-order-form__spacer___FvOBN{margin-top:1rem}.-esm-patient-orders__cancel-order-form__noteInput___9GsI7{width:100%}.-esm-patient-orders__cancel-order-form__errorNotification___PgCii{margin:.5rem 0}.-esm-patient-orders__cancel-order-form__errorContainer___COfpy{margin:1rem}","",{version:3,sources:["webpack://./../../node_modules/@openmrs/esm-styleguide/src/_vars.scss","webpack://./src/order-cancellation-form/cancel-order-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,6HC81BI,kDAAA,CAAA,kDAAA,CAAA,kDAAA,CAAA,sDAAA,CD11BJ,uDAEE,sBAAA,CAGF,8DACE,kBEiBW,CFdb,wDACE,aDEO,CCCT,wDACE,WEkCW,CFjCX,YAAA,CACA,wBAAA,CACA,oBAAA,CACA,aAAA,CAEA,6EACE,0BAAA,CAGF,mFACE,0BAAA,CAIJ,wDACE,mBAAA,CACA,qBDtCM,CCyCR,yDACE,SAAA,CAGF,sDACE,YAAA,CACA,qBAAA,CACA,6BAAA,CACA,WAAA,CAGF,kFACE,wBAAA,CAGF,iFACE,qBDzDM,CC4DR,sDACE,WE/BW,CFkCb,qDACE,gBAAA,CACA,YAAA,CACA,kBAAA,CACA,QEtCW,CFyCb,wDACE,eE1CW,CF6Cb,2DACE,UAAA,CAGF,mEACE,cAAA,CAGF,gEACE,WEtDW",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/layout';\n@use '@carbon/type';\n@use '@openmrs/esm-styleguide/src/vars' as *;\n\n.productiveHeading03 {\n @include type.type-style('heading-03');\n}\n\n.title {\n @extend .productiveHeading03;\n margin: 0 layout.$spacing-03 layout.$spacing-03 0;\n}\n\n.orderDisplay {\n margin-bottom: layout.$spacing-05;\n}\n\n.danger {\n color: $danger;\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) {\n min-height: layout.$spacing-05 !important;\n }\n\n :global(.cds--inline-loading__text) {\n font-size: unset !important;\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.form {\n display: flex;\n flex-direction: column;\n justify-content: space-between;\n height: 100%;\n}\n\n:global(.omrs-breakpoint-lt-desktop) .form {\n background-color: #ededed;\n}\n\n:global(.omrs-breakpoint-gt-tablet) .form {\n background-color: $ui-02;\n}\n\n.grid {\n margin: layout.$spacing-05;\n}\n\n.row {\n margin: layout.$spacing-03 0 0;\n display: flex;\n flex-flow: row wrap;\n gap: layout.$spacing-05;\n}\n\n.spacer {\n margin-top: layout.$spacing-05;\n}\n\n.noteInput {\n width: 100%;\n}\n\n.errorNotification {\n margin: layout.$spacing-03 0;\n}\n\n.errorContainer {\n margin: layout.$spacing-05;\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:""}]),o.locals={productiveHeading03:"-esm-patient-orders__cancel-order-form__productiveHeading03___k+Vts",title:"-esm-patient-orders__cancel-order-form__title___TOkA-",orderDisplay:"-esm-patient-orders__cancel-order-form__orderDisplay___ZQie-",danger:"-esm-patient-orders__cancel-order-form__danger___VGCx8",button:"-esm-patient-orders__cancel-order-form__button___xVUqX",tablet:"-esm-patient-orders__cancel-order-form__tablet___wLQCv",desktop:"-esm-patient-orders__cancel-order-form__desktop___Jq1HN",form:"-esm-patient-orders__cancel-order-form__form___7NxDA",grid:"-esm-patient-orders__cancel-order-form__grid___wg6M-",row:"-esm-patient-orders__cancel-order-form__row___Afnej",spacer:"-esm-patient-orders__cancel-order-form__spacer___FvOBN",noteInput:"-esm-patient-orders__cancel-order-form__noteInput___9GsI7",errorNotification:"-esm-patient-orders__cancel-order-form__errorNotification___PgCii",errorContainer:"-esm-patient-orders__cancel-order-form__errorContainer___COfpy"};const l=o},2128:(e,n,t)=>{t.r(n),t.d(n,{default:()=>N});var a=t(1343),i=t.n(a),r=t(6372),o=t.n(r),l=t(824),s=t(3150),p=t(6195),c=t(1160),d=t(3506),u=t(8254),g=t(7223),f=t(111),h=t.n(f),y=t(5660),m=t.n(y),b=t(3824),$=t.n(b),_=t(8823),v=t.n(_),A=t(6747),k=t.n(A),w=t(4072),x=t.n(w),C=t(2295),z={};z.styleTagTransform=x(),z.setAttributes=v(),z.insert=$().bind(null,"head"),z.domAPI=m(),z.insertStyleElement=k(),h()(C.A,z);const M=C.A&&C.A.locals?C.A.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){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,r=[],o=!0,l=!1;try{for(t=t.call(e);!(o=(a=t.next()).done)&&(r.push(a.value),!n||r.length!==n);o=!0);}catch(e){l=!0,i=e}finally{try{o||null==t.return||t.return()}finally{if(l)throw i}}return r}}(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 N=function(e){var n=e.order,t=e.patientUuid,r=e.closeWorkspace,f=e.promptBeforeClosing,h=(0,s.useTranslation)().t,y="tablet"===(0,u.useLayoutType)(),m=D((0,a.useState)(!1),2),b=m[0],$=m[1],_=(0,g.usePatientOrders)(t).mutate,v=(0,a.useMemo)((function(){return p.z.object({cancellationDate:p.z.date({required_error:h("cancellationDateRequired","Cancellation date is required")}).refine((function(e){return e>=o()().startOf("day").toDate()}),{message:h("dateCannotBeBeforeToday","Date cannot be before today")}),reasonForCancellation:p.z.string({required_error:h("reasonForCancellationRequired","Reason for cancellation is required")})})}),[h]),A=(0,l.mN)({mode:"all",resolver:(0,c.u)(v)}),k=A.control,w=A.handleSubmit,x=A.formState,C=x.errors,z=x.isDirty,E=x.isSubmitting;(0,a.useEffect)((function(){f((function(){return z}))}),[z,f]);var N=(0,a.useCallback)((function(e){var t=e;$(!1);var a={fulfillerStatus:"DECLINED",fulfillerComment:t.reasonForCancellation};(function(e,n){var t=new AbortController;return(0,u.openmrsFetch)("".concat(u.restBaseUrl,"/order/").concat(e.uuid,"/fulfillerdetails/"),{method:"POST",headers:{"Content-Type":"application/json"},body:n,signal:t.signal})})(n,a).then((function(e){r(),_(),(0,u.showSnackbar)({title:h("orderCancelled","Order cancelled"),kind:"success",subtitle:h("successfullyCancelledOrder","Order {{orderNumber}} has been cancelled successfully",{orderNumber:null==n?void 0:n.orderNumber})})}),(function(e){(0,u.showSnackbar)({isLowContrast:!0,title:h("errorCancellingOrder","Error cancelling order"),kind:"error",subtitle:null==e?void 0:e.message})}))}),[r,_,n,h]);return i().createElement(d.lVW,{className:M.form},i().createElement("div",{className:M.grid},i().createElement(d.BJc,null,i().createElement("section",null,i().createElement("h4",{className:M.orderDisplay},null==n?void 0:n.display)),i().createElement("section",null,i().createElement(l.xI,{name:"cancellationDate",control:k,render:function(e){var n=e.field,t=n.onChange,a=n.value;return i().createElement("div",{className:M.row},i().createElement(d.lrV,{id:"cancellationDate",minDate:o()().startOf("day"),dateFormat:"d/m/Y",datePickerType:"single",value:a,onChange:function(e){var n=D(e,1)[0];return t(n)},autocomplete:"off"},i().createElement(d.tKA,{id:"date-picker-calendar-id",placeholder:"dd/mm/yyyy",labelText:h("cancellationDate","Cancellation date"),type:"text",invalid:!!C.cancellationDate,invalidText:!!C.cancellationDate&&C.cancellationDate.message})))}})),i().createElement("section",null,i().createElement(l.xI,{name:"reasonForCancellation",control:k,render:function(e){var n=e.field,t=n.onChange,a=n.value;return i().createElement("div",{className:M.row},i().createElement(d.fs1,{type:"text",id:"reasonForCancellation",labelText:h("reasonForCancellation","Reason for cancellation"),value:a,onChange:function(e){return t(e.target.value)},invalid:!!C.reasonForCancellation,invalidText:!!C.reasonForCancellation&&C.reasonForCancellation.message}))}})))),b&&i().createElement(d.VPZ,{className:M.errorContainer},i().createElement(d.jeF,{lowContrast:!0,title:h("error","Error"),subtitle:h("pleaseFillRequiredFields","Please fill all the required fields")+".",onClose:function(){return $(!1)}})),i().createElement(d.Te$,{className:y?M.tablet:M.desktop},i().createElement(d.$nd,{className:M.button,kind:"secondary",onClick:r},h("discard","Discard")),i().createElement(d.$nd,{className:M.button,kind:"primary",onClick:w(N,(function(e){(null==e?void 0:e.oneFieldRequired)&&$(!0)})),disabled:E,type:"submit"},E?i().createElement(d.OuH,{description:h("saving","Saving")+"..."}):h("saveAndClose","Save and close"))))}}}]);
1
+ "use strict";(globalThis.webpackChunk_openmrs_esm_patient_orders_app=globalThis.webpackChunk_openmrs_esm_patient_orders_app||[]).push([[2128],{2295:(e,n,t)=>{t.d(n,{A:()=>l});var a=t(5836),i=t.n(a),r=t(8023),o=t.n(r)()(i());o.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-orders__cancel-order-form__productiveHeading03___k\\+Vts,.-esm-patient-orders__cancel-order-form__title___TOkA-{font-size:var(--cds-heading-03-font-size, 1.25rem);font-weight:var(--cds-heading-03-font-weight, 400);line-height:var(--cds-heading-03-line-height, 1.4);letter-spacing:var(--cds-heading-03-letter-spacing, 0)}.-esm-patient-orders__cancel-order-form__title___TOkA-{margin:0 .5rem .5rem 0}.-esm-patient-orders__cancel-order-form__orderDisplay___ZQie-{margin-bottom:1rem}.-esm-patient-orders__cancel-order-form__danger___VGCx8{color:#da1e28}.-esm-patient-orders__cancel-order-form__button___xVUqX{height:4rem;display:flex;align-content:flex-start;align-items:baseline;min-width:50%}.-esm-patient-orders__cancel-order-form__button___xVUqX .cds--inline-loading{min-height:1rem !important}.-esm-patient-orders__cancel-order-form__button___xVUqX .cds--inline-loading__text{font-size:unset !important}.-esm-patient-orders__cancel-order-form__tablet___wLQCv{padding:1.5rem 1rem;background-color:#fff}.-esm-patient-orders__cancel-order-form__desktop___Jq1HN{padding:0}.-esm-patient-orders__cancel-order-form__form___7NxDA{display:flex;flex-direction:column;justify-content:space-between;height:100%}.omrs-breakpoint-lt-desktop .-esm-patient-orders__cancel-order-form__form___7NxDA{background-color:#ededed}.omrs-breakpoint-gt-tablet .-esm-patient-orders__cancel-order-form__form___7NxDA{background-color:#fff}.-esm-patient-orders__cancel-order-form__grid___wg6M-{margin:1rem}.-esm-patient-orders__cancel-order-form__row___Afnej{margin:.5rem 0 0;display:flex;flex-flow:row wrap;gap:1rem}.-esm-patient-orders__cancel-order-form__spacer___FvOBN{margin-top:1rem}.-esm-patient-orders__cancel-order-form__noteInput___9GsI7{width:100%}.-esm-patient-orders__cancel-order-form__errorNotification___PgCii{margin:.5rem 0}.-esm-patient-orders__cancel-order-form__errorContainer___COfpy{margin:1rem}","",{version:3,sources:["webpack://./../../node_modules/@openmrs/esm-styleguide/src/_vars.scss","webpack://./src/order-cancellation-form/cancel-order-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,6HC81BI,kDAAA,CAAA,kDAAA,CAAA,kDAAA,CAAA,sDAAA,CD11BJ,uDAEE,sBAAA,CAGF,8DACE,kBEiBW,CFdb,wDACE,aDEO,CCCT,wDACE,WEkCW,CFjCX,YAAA,CACA,wBAAA,CACA,oBAAA,CACA,aAAA,CAEA,6EACE,0BAAA,CAGF,mFACE,0BAAA,CAIJ,wDACE,mBAAA,CACA,qBDtCM,CCyCR,yDACE,SAAA,CAGF,sDACE,YAAA,CACA,qBAAA,CACA,6BAAA,CACA,WAAA,CAGF,kFACE,wBAAA,CAGF,iFACE,qBDzDM,CC4DR,sDACE,WE/BW,CFkCb,qDACE,gBAAA,CACA,YAAA,CACA,kBAAA,CACA,QEtCW,CFyCb,wDACE,eE1CW,CF6Cb,2DACE,UAAA,CAGF,mEACE,cAAA,CAGF,gEACE,WEtDW",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/layout';\n@use '@carbon/type';\n@use '@openmrs/esm-styleguide/src/vars' as *;\n\n.productiveHeading03 {\n @include type.type-style('heading-03');\n}\n\n.title {\n @extend .productiveHeading03;\n margin: 0 layout.$spacing-03 layout.$spacing-03 0;\n}\n\n.orderDisplay {\n margin-bottom: layout.$spacing-05;\n}\n\n.danger {\n color: $danger;\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) {\n min-height: layout.$spacing-05 !important;\n }\n\n :global(.cds--inline-loading__text) {\n font-size: unset !important;\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.form {\n display: flex;\n flex-direction: column;\n justify-content: space-between;\n height: 100%;\n}\n\n:global(.omrs-breakpoint-lt-desktop) .form {\n background-color: #ededed;\n}\n\n:global(.omrs-breakpoint-gt-tablet) .form {\n background-color: $ui-02;\n}\n\n.grid {\n margin: layout.$spacing-05;\n}\n\n.row {\n margin: layout.$spacing-03 0 0;\n display: flex;\n flex-flow: row wrap;\n gap: layout.$spacing-05;\n}\n\n.spacer {\n margin-top: layout.$spacing-05;\n}\n\n.noteInput {\n width: 100%;\n}\n\n.errorNotification {\n margin: layout.$spacing-03 0;\n}\n\n.errorContainer {\n margin: layout.$spacing-05;\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:""}]),o.locals={productiveHeading03:"-esm-patient-orders__cancel-order-form__productiveHeading03___k+Vts",title:"-esm-patient-orders__cancel-order-form__title___TOkA-",orderDisplay:"-esm-patient-orders__cancel-order-form__orderDisplay___ZQie-",danger:"-esm-patient-orders__cancel-order-form__danger___VGCx8",button:"-esm-patient-orders__cancel-order-form__button___xVUqX",tablet:"-esm-patient-orders__cancel-order-form__tablet___wLQCv",desktop:"-esm-patient-orders__cancel-order-form__desktop___Jq1HN",form:"-esm-patient-orders__cancel-order-form__form___7NxDA",grid:"-esm-patient-orders__cancel-order-form__grid___wg6M-",row:"-esm-patient-orders__cancel-order-form__row___Afnej",spacer:"-esm-patient-orders__cancel-order-form__spacer___FvOBN",noteInput:"-esm-patient-orders__cancel-order-form__noteInput___9GsI7",errorNotification:"-esm-patient-orders__cancel-order-form__errorNotification___PgCii",errorContainer:"-esm-patient-orders__cancel-order-form__errorContainer___COfpy"};const l=o},2128:(e,n,t)=>{t.r(n),t.d(n,{default:()=>N});var a=t(1343),i=t.n(a),r=t(6372),o=t.n(r),l=t(824),s=t(3150),p=t(6195),c=t(1160),d=t(2304),u=t(8254),g=t(7223),f=t(111),h=t.n(f),y=t(5660),m=t.n(y),b=t(3824),$=t.n(b),_=t(8823),v=t.n(_),A=t(6747),k=t.n(A),w=t(4072),x=t.n(w),C=t(2295),z={};z.styleTagTransform=x(),z.setAttributes=v(),z.insert=$().bind(null,"head"),z.domAPI=m(),z.insertStyleElement=k(),h()(C.A,z);const M=C.A&&C.A.locals?C.A.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){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,r=[],o=!0,l=!1;try{for(t=t.call(e);!(o=(a=t.next()).done)&&(r.push(a.value),!n||r.length!==n);o=!0);}catch(e){l=!0,i=e}finally{try{o||null==t.return||t.return()}finally{if(l)throw i}}return r}}(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 N=function(e){var n=e.order,t=e.patientUuid,r=e.closeWorkspace,f=e.promptBeforeClosing,h=(0,s.useTranslation)().t,y="tablet"===(0,u.useLayoutType)(),m=D((0,a.useState)(!1),2),b=m[0],$=m[1],_=(0,g.usePatientOrders)(t).mutate,v=(0,a.useMemo)((function(){return p.z.object({cancellationDate:p.z.date({required_error:h("cancellationDateRequired","Cancellation date is required")}).refine((function(e){return e>=o()().startOf("day").toDate()}),{message:h("dateCannotBeBeforeToday","Date cannot be before today")}),reasonForCancellation:p.z.string({required_error:h("reasonForCancellationRequired","Reason for cancellation is required")})})}),[h]),A=(0,l.mN)({mode:"all",resolver:(0,c.u)(v)}),k=A.control,w=A.handleSubmit,x=A.formState,C=x.errors,z=x.isDirty,E=x.isSubmitting;(0,a.useEffect)((function(){f((function(){return z}))}),[z,f]);var N=(0,a.useCallback)((function(e){var t=e;$(!1);var a={fulfillerStatus:"DECLINED",fulfillerComment:t.reasonForCancellation};(function(e,n){var t=new AbortController;return(0,u.openmrsFetch)("".concat(u.restBaseUrl,"/order/").concat(e.uuid,"/fulfillerdetails/"),{method:"POST",headers:{"Content-Type":"application/json"},body:n,signal:t.signal})})(n,a).then((function(e){r(),_(),(0,u.showSnackbar)({title:h("orderCancelled","Order cancelled"),kind:"success",subtitle:h("successfullyCancelledOrder","Order {{orderNumber}} has been cancelled successfully",{orderNumber:null==n?void 0:n.orderNumber})})}),(function(e){(0,u.showSnackbar)({isLowContrast:!0,title:h("errorCancellingOrder","Error cancelling order"),kind:"error",subtitle:null==e?void 0:e.message})}))}),[r,_,n,h]);return i().createElement(d.lVW,{className:M.form},i().createElement("div",{className:M.grid},i().createElement(d.BJc,null,i().createElement("section",null,i().createElement("h4",{className:M.orderDisplay},null==n?void 0:n.display)),i().createElement("section",null,i().createElement(l.xI,{name:"cancellationDate",control:k,render:function(e){var n=e.field,t=n.onChange,a=n.value;return i().createElement("div",{className:M.row},i().createElement(d.lrV,{id:"cancellationDate",minDate:o()().startOf("day"),dateFormat:"d/m/Y",datePickerType:"single",value:a,onChange:function(e){var n=D(e,1)[0];return t(n)},autocomplete:"off"},i().createElement(d.tKA,{id:"date-picker-calendar-id",placeholder:"dd/mm/yyyy",labelText:h("cancellationDate","Cancellation date"),type:"text",invalid:!!C.cancellationDate,invalidText:!!C.cancellationDate&&C.cancellationDate.message})))}})),i().createElement("section",null,i().createElement(l.xI,{name:"reasonForCancellation",control:k,render:function(e){var n=e.field,t=n.onChange,a=n.value;return i().createElement("div",{className:M.row},i().createElement(d.fs1,{type:"text",id:"reasonForCancellation",labelText:h("reasonForCancellation","Reason for cancellation"),value:a,onChange:function(e){return t(e.target.value)},invalid:!!C.reasonForCancellation,invalidText:!!C.reasonForCancellation&&C.reasonForCancellation.message}))}})))),b&&i().createElement(d.VPZ,{className:M.errorContainer},i().createElement(d.jeF,{lowContrast:!0,title:h("error","Error"),subtitle:h("pleaseFillRequiredFields","Please fill all the required fields")+".",onClose:function(){return $(!1)}})),i().createElement(d.Te$,{className:y?M.tablet:M.desktop},i().createElement(d.$nd,{className:M.button,kind:"secondary",onClick:r},h("discard","Discard")),i().createElement(d.$nd,{className:M.button,kind:"primary",onClick:w(N,(function(e){(null==e?void 0:e.oneFieldRequired)&&$(!0)})),disabled:E,type:"submit"},E?i().createElement(d.OuH,{description:h("saving","Saving")+"..."}):h("saveAndClose","Save and close"))))}}}]);
package/dist/2146.js CHANGED
@@ -1 +1 @@
1
- "use strict";(globalThis.webpackChunk_openmrs_esm_patient_orders_app=globalThis.webpackChunk_openmrs_esm_patient_orders_app||[]).push([[2146],{2146:e=>{e.exports=JSON.parse('{"actionsMenu":"Actions menu","activeVisitRequired":"An active visit is required to make orders","add":"Add","additionalInstructions":"Additional instructions","addResults":"Add results","allOrders":"All orders","backToOrderBasket":"Back to order basket","cancel":"Cancel","cancellationDate":"Cancellation date","cancellationDateRequired":"Cancellation date is required","cancelOrder":"Cancel order","checkFilters":"Check the filters above","chooseAnOption":"Choose an option","clearSearchResults":"Clear results","dateCannotBeBeforeToday":"Date cannot be before today","dateOfOrder":"Date of order","dateRange":"Date range","directlyAddToBasket":"Add to basket","discard":"Discard","discontinued":"Discontinued","dosage":"Dosage","dose":"Dose","editResults":"Edit results","endDate":"End date","enterTestResults":"Enter test results","error":"Error","errorCancellingOrder":"Error cancelling order","errorFetchingTestTypes":"Error fetching results for \\"{{searchTerm}}\\"","errorSavingLabResults":"Error saving lab results","goToDrugOrderForm":"Order form","indication":"Indication","inStock":"In stock","instructions":"Instructions","labResultError":"Error loading lab results","launchOrderBasket":"Launch order basket","loading":"Loading","loadingInitialValues":"Loading initial values","loadinglabresults":"Loading lab results","loadingTestDetails":"Loading test details","medicationDurationAndUnit":"for {{duration}} {{durationUnit}}","medicationIndefiniteDuration":"Indefinite duration","medications":"Medications","modifyOrder":"Modify order","noMatchingOrdersToDisplay":"No matching orders to display","noResultsForTestTypeSearch":"No results to display for \\"{{searchTerm}}\\"","normalRange":"Normal range","onDate":"on","or":"or","order":"Order","orderableConceptRequired":"Orderable concept is required","orderActionDiscontinue":"Discontinue","orderActionIncomplete":"Incomplete","orderActionNew":"New","orderActionRenew":"Renew","orderActionRevise":"Modify","orderBasket":"Order basket","orderBasketWorkspaceTitle":"Order basket","orderCancellation":"Order cancellation","orderCancelled":"Order cancelled","orderCompleted":"Placed orders","orderDetails":"Order details","ordered":"Placed order for","orderedBy":"Ordered by","ordererInformation":"Orderer information","orderNumber":"Order number","orders":"Orders","Orders":"Orders","orderType":"Order type","outOfStock":"Out of stock","pleaseFillField":"Please fill at least one field","pleaseFillRequiredFields":"Please fill all the required fields","pleaseRequiredFields":"Please fill all required fields","price":"Price","priceDisclaimer":"This price is indicative and may not reflect final costs, which could vary due to discounts, insurance coverage, or other pricing rules","print":"Print","printedBy":"Printed by","printOrder":"Print order","priority":"Priority","priorityRequired":"Priority is required","quantity":"Quantity","reasonForCancellation":"Reason for cancellation","reasonForCancellationRequired":"Reason for cancellation is required","referenceNumber":"Reference number","referenceNumberTableHeader":"{{orderType}} reference number","refills":"Refills","removeFromBasket":"Remove from basket","result":"Result","returnToOrderBasket":"Return to order basket","saveAndClose":"Save and close","saveDrugOrderFailed":"Error ordering {{orderName}}","saveLabResults":"Save lab results","saveOrder":"Save order","saving":"Saving","searchAgain":"search again","searchFieldOrder":"Search for {{orderType}} order","searchOrderables":"Search orderables","searchResultsMatchesForTerm_one":"{{count}} results for \\"{{searchTerm}}\\"","searchResultsMatchesForTerm_other":"{{count}} results for \\"{{searchTerm}}\\"","searchTable":"Search table","selectOrderType":"Select order type","signAndClose":"Sign and close","startAVisitToRecordOrders":"Start a visit to order","startVisit":"Start visit","status":"Status","successfullyCancelledOrder":"Order {{orderNumber}} has been cancelled successfully","successfullySavedLabResults":"Lab results for {{orderNumber}} have been successfully updated","Test Order_few":"Test orders","testType":"Test type","tryReopeningTheWorkspaceAgain":"Please try launching the workspace again","trySearchingAgain":"Please try searching again","tryTo":"Try to","updated":"Updated","usingADifferentTerm":"using a different term"}')}}]);
1
+ "use strict";(globalThis.webpackChunk_openmrs_esm_patient_orders_app=globalThis.webpackChunk_openmrs_esm_patient_orders_app||[]).push([[2146],{2146:e=>{e.exports=JSON.parse('{"actionsMenu":"Actions menu","activeVisitRequired":"An active visit is required to make orders","add":"Add","additionalInstructions":"Additional instructions","addOrderableForOrderType":"Add {{orderTypeDisplay}}","addResults":"Add results","allOrders":"All orders","backToOrderBasket":"Back to order basket","cancel":"Cancel","cancellationDate":"Cancellation date","cancellationDateRequired":"Cancellation date is required","cancelOrder":"Cancel order","checkFilters":"Check the filters above","chooseAnOption":"Choose an option","clearSearchResults":"Clear results","dateCannotBeBeforeToday":"Date cannot be before today","dateOfOrder":"Date of order","dateRange":"Date range","directlyAddToBasket":"Add to basket","discard":"Discard","discontinued":"Discontinued","dosage":"Dosage","dose":"Dose","editResults":"Edit results","endDate":"End date","enterTestResults":"Enter test results","error":"Error","errorCancellingOrder":"Error cancelling order","errorFetchingTestTypes":"Error fetching results for \\"{{searchTerm}}\\"","errorSavingLabResults":"Error saving lab results","goToDrugOrderForm":"Order form","indication":"Indication","inStock":"In stock","instructions":"Instructions","labResultError":"Error loading lab results","launchOrderBasket":"Launch order basket","loading":"Loading","loadingInitialValues":"Loading initial values","loadinglabresults":"Loading lab results","loadingTestDetails":"Loading test details","medicationDurationAndUnit":"for {{duration}} {{durationUnit}}","medicationIndefiniteDuration":"Indefinite duration","medications":"Medications","modifyOrder":"Modify order","noMatchingOrdersToDisplay":"No matching orders to display","noResultsForTestTypeSearch":"No results to display for \\"{{searchTerm}}\\"","normalRange":"Normal range","onDate":"on","or":"or","order":"Order","orderableConceptRequired":"Orderable concept is required","orderActionDiscontinue":"Discontinue","orderActionIncomplete":"Incomplete","orderActionNew":"New","orderActionRenew":"Renew","orderActionRevise":"Modify","orderBasket":"Order basket","orderBasketWorkspaceTitle":"Order basket","orderCancellation":"Order cancellation","orderCancelled":"Order cancelled","orderCompleted":"Placed orders","orderDetails":"Order details","ordered":"Placed order for","orderedBy":"Ordered by","ordererInformation":"Orderer information","orderNumber":"Order number","orders":"Orders","Orders":"Orders","orderType":"Order type","outOfStock":"Out of stock","pleaseFillField":"Please fill at least one field","pleaseFillRequiredFields":"Please fill all the required fields","pleaseRequiredFields":"Please fill all required fields","price":"Price","priceDisclaimer":"This price is indicative and may not reflect final costs, which could vary due to discounts, insurance coverage, or other pricing rules","print":"Print","printedBy":"Printed by","printOrder":"Print order","priority":"Priority","priorityRequired":"Priority is required","quantity":"Quantity","reasonForCancellation":"Reason for cancellation","reasonForCancellationRequired":"Reason for cancellation is required","referenceNumber":"Reference number","referenceNumberTableHeader":"{{orderType}} reference number","refills":"Refills","removeFromBasket":"Remove from basket","result":"Result","returnToOrderBasket":"Return to order basket","saveAndClose":"Save and close","saveDrugOrderFailed":"Error ordering {{orderName}}","saveLabResults":"Save lab results","saveOrder":"Save order","saving":"Saving","scheduledDate":"Scheduled date","scheduledDateRequired":"Scheduled date is required","searchAgain":"search again","searchFieldOrder":"Search for {{orderType}} order","searchOrderables":"Search orderables","searchResultsMatchesForTerm_one":"{{count}} results for \\"{{searchTerm}}\\"","searchResultsMatchesForTerm_other":"{{count}} results for \\"{{searchTerm}}\\"","searchTable":"Search table","selectOrderType":"Select order type","signAndClose":"Sign and close","startAVisitToRecordOrders":"Start a visit to order","startVisit":"Start visit","status":"Status","successfullyCancelledOrder":"Order {{orderNumber}} has been cancelled successfully","successfullySavedLabResults":"Lab results for {{orderNumber}} have been successfully updated","Test Order_few":"Test orders","testType":"Test type","tryReopeningTheWorkspaceAgain":"Please try launching the workspace again","trySearchingAgain":"Please try searching again","tryTo":"Try to","updated":"Updated","usingADifferentTerm":"using a different term"}')}}]);