hplx-feature-library 1.0.31 → 1.0.32

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.
@@ -10087,7 +10087,9 @@ const ej = /* @__PURE__ */ ou(Z1), Or = (t) => /^(\d+)?(\.)?(\d*)?$/.test(t), Xt
10087
10087
  options: o !== "prescription" ? S.map((M) => ({ label: M, value: M })) : void 0,
10088
10088
  onChangeHandler: o !== "prescription" ? (M) => v("pedia_dosage", M.value) : void 0,
10089
10089
  hideDropdownIcon: o === "prescription",
10090
- showEmptyDropdownPopup: o !== "prescription"
10090
+ showEmptyDropdownPopup: o !== "prescription",
10091
+ showErrorMsg: p.out_of_range || p.isDosageMismatch,
10092
+ errorMsg: p.out_of_range ? "Dosage Exceeds Safety Limits" : p.isDosageMismatch ? "Dosage is in mismatch with the selected frequency" : ""
10091
10093
  }
10092
10094
  );
10093
10095
  })() : /* @__PURE__ */ W.jsxs("div", { className: "hfl-flex hfl-flex-col hfl-h-full hfl-justify-between hfl-min-w-0", children: [
@@ -1,4 +1,4 @@
1
- const t = [
1
+ const l = [
2
2
  "Medicine Name",
3
3
  "Generic Name",
4
4
  "Type",
@@ -6,7 +6,7 @@ const t = [
6
6
  "Additional Information",
7
7
  "Dosage",
8
8
  "Options"
9
- ], l = [
9
+ ], p = [
10
10
  {
11
11
  type: "TAB.",
12
12
  val: 2
@@ -99,26 +99,28 @@ const t = [
99
99
  type: "SPR.",
100
100
  val: 24
101
101
  }
102
- ], p = ["1(OD)", "2(BD)", "3(TDS)", "4(QID)", "6(Q4H)"], y = {
102
+ ];
103
+ var a = /* @__PURE__ */ ((e) => (e["1(OD)"] = "1(OD)", e["2(BD)"] = "2(BD)", e["3(TDS)"] = "3(TDS)", e["4(QID)"] = "4(QID)", e["6(Q4H)"] = "6(Q4H)", e))(a || {});
104
+ const y = Object.values(a), s = {
103
105
  "1(OD)": ["X-0-0", "0-X-0", "0-0-X"],
104
106
  "2(BD)": ["X-X-0", "X-0-X", "0-X-X"],
105
107
  "3(TDS)": ["X-X-X"],
106
108
  "4(QID)": ["X-X-X-X"],
107
109
  "6(Q4H)": ["X-X-X-X-X-X"]
108
110
  };
109
- var a = /* @__PURE__ */ ((e) => (e.MgKgDose = "mg/kg/dose", e.MlKg = "mL/kg", e))(a || {});
110
- const o = [
111
+ var t = /* @__PURE__ */ ((e) => (e.MgKgDose = "mg/kg/dose", e.MlKg = "mL/kg", e))(t || {});
112
+ const v = [
111
113
  "mg/kg/dose",
112
114
  "mL/kg"
113
115
  /* MlKg */
114
- ], s = {
116
+ ], o = {
115
117
  drug_strength: "",
116
118
  dose_mg_kg: "",
117
119
  frequency: "",
118
120
  max_mg_dose: "",
119
121
  max_mg_day: "",
120
122
  pedia_dosage: ""
121
- }, v = {
123
+ }, g = {
122
124
  multiplier: "",
123
125
  dose_ml_kg: "",
124
126
  frequency: "",
@@ -127,12 +129,13 @@ const o = [
127
129
  pedia_dosage: ""
128
130
  };
129
131
  export {
130
- s as C_DefaultMgKgFields,
131
- v as C_DefaultMlKgFields,
132
- y as C_FrequencyDosageMap,
133
- o as C_MedicineCalculatorList,
134
- p as C_MedicineFrequencyList,
135
- l as C_MedicineTypeList,
136
- t as C_Table_Column_Name,
137
- a as E_CalculationType
132
+ o as C_DefaultMgKgFields,
133
+ g as C_DefaultMlKgFields,
134
+ s as C_FrequencyDosageMap,
135
+ v as C_MedicineCalculatorList,
136
+ y as C_MedicineFrequencyList,
137
+ p as C_MedicineTypeList,
138
+ l as C_Table_Column_Name,
139
+ t as E_CalculationType,
140
+ a as E_MEDICINE_FREQUENCY
138
141
  };
@@ -4,7 +4,14 @@ export declare const C_MedicineTypeList: {
4
4
  type: string;
5
5
  val: number;
6
6
  }[];
7
- export declare const C_MedicineFrequencyList: string[];
7
+ export declare enum E_MEDICINE_FREQUENCY {
8
+ '1(OD)' = "1(OD)",
9
+ '2(BD)' = "2(BD)",
10
+ '3(TDS)' = "3(TDS)",
11
+ '4(QID)' = "4(QID)",
12
+ '6(Q4H)' = "6(Q4H)"
13
+ }
14
+ export declare const C_MedicineFrequencyList: E_MEDICINE_FREQUENCY[];
8
15
  export declare const C_FrequencyDosageMap: Record<string, string[]>;
9
16
  export declare enum E_CalculationType {
10
17
  MgKgDose = "mg/kg/dose",
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import { P as o } from "./PediatricsCalculatorTable-kT0uGKWk.js";
1
+ import { P as o } from "./PediatricsCalculatorTable-DPoagS8l.js";
2
2
  export {
3
3
  o as PediatricsCalculator
4
4
  };
@@ -39,6 +39,7 @@ export interface IMedicineViewData extends I_Medicine {
39
39
  rowId: string;
40
40
  isSavedToLibrary?: boolean;
41
41
  isEditing?: boolean;
42
+ isDosageMismatch?: boolean;
42
43
  }
43
44
  export interface I_SelectOption<T> {
44
45
  label: string;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "hplx-feature-library",
3
3
  "private": false,
4
- "version": "1.0.31",
4
+ "version": "1.0.32",
5
5
  "type": "module",
6
6
  "scripts": {
7
7
  "dev": "vite",