hplx-feature-library 1.0.243 → 1.0.245
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{APIAction-DB6Ulkss.cjs → APIAction-BgDEMmVd.cjs} +1 -1
- package/dist/{APIAction-CTNOzVOC.js → APIAction-DT8TOViB.js} +1 -1
- package/dist/PatientAddEdit/index.js +1 -1
- package/dist/{PatientAddEdit-9W7ONHSd.js → PatientAddEdit-C5MnysOS.js} +2 -2
- package/dist/{PatientAddEdit-DmpV8z5a.cjs → PatientAddEdit-CuYCmfEb.cjs} +1 -1
- package/dist/PatientPopup/index.js +1 -1
- package/dist/{PatientPopupContainer-BKp26JM0.js → PatientPopupContainer-C0v485Yp.js} +1223 -1220
- package/dist/{PatientPopupContainer-KVBjrO76.cjs → PatientPopupContainer-Ce2JXK2B.cjs} +8 -8
- package/dist/{PrintModal-ojUmGPqg.cjs → PrintModal-BVSbnJC6.cjs} +6 -5
- package/dist/{PrintModal-BOpFTYfb.js → PrintModal-CdiyWYuT.js} +121 -96
- package/dist/SearchPatients/index.js +1 -1
- package/dist/{SearchPatients-BsO-G0KT.js → SearchPatients-B91CFBhq.js} +2 -2
- package/dist/{SearchPatients-C0MLXdT-.cjs → SearchPatients-BjIvDU18.cjs} +1 -1
- package/dist/UserProfile/index.js +1 -1
- package/dist/{UserProfile-DRf9rznF.js → UserProfile-1Pll0yKL.js} +1 -1
- package/dist/{UserProfile-BqDIctDl.cjs → UserProfile-C47Wg1As.cjs} +1 -1
- package/dist/common/utils/common-utils.d.ts +1 -0
- package/dist/{common-utils-DrDXKNhv.cjs → common-utils-Cw6aYEiU.cjs} +5 -5
- package/dist/{common-utils-CprPMjtz.js → common-utils-DOjdqsiU.js} +106 -105
- package/dist/hplx-feature-library.css +1 -1
- package/dist/index.js +5 -5
- package/dist/print-pdf/index.js +1 -1
- package/dist/types/ApiResponseTypes.d.ts +8 -0
- package/package.json +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { j as jsxRuntimeExports, K as Ku, A as Ap, P as Ps, g as getDefaultExportFromCjs$2, f as getAugmentedNamespace$2, d as commonjsGlobal$1, l as requireObjectAssign, m as PropTypes, b as bs } from "./index-Bd0CDVpH.js";
|
|
2
2
|
import React__default, { useState, useEffect, useRef, useCallback, Fragment, memo, createContext, useReducer, forwardRef, useImperativeHandle, useMemo, useContext, useLayoutEffect } from "react";
|
|
3
|
-
import { h as hplxAPI, n as E_ENVIRONMENT,
|
|
3
|
+
import { h as hplxAPI, n as E_ENVIRONMENT, q as getDurationFormat, j as isValidDate, m as capitalizeFirstLetter, i as isJson, d as debounceFn } from "./common-utils-DOjdqsiU.js";
|
|
4
4
|
import { d as dayjs } from "./dayjs.min-D52_GdfV.js";
|
|
5
5
|
import { g as genderList, D as DefinedLanguages } from "./CommonConstant-Bj7SvPfU.js";
|
|
6
6
|
import { c as create$6 } from "./index.esm-Bn1Rklqj.js";
|
|
@@ -96459,19 +96459,26 @@ const events = {}, pdf$2 = (N) => {
|
|
|
96459
96459
|
className: Y,
|
|
96460
96460
|
...x
|
|
96461
96461
|
});
|
|
96462
|
-
}, Header = ({ preferences: N,
|
|
96463
|
-
const [
|
|
96464
|
-
|
|
96465
|
-
|
|
96466
|
-
|
|
96467
|
-
|
|
96468
|
-
|
|
96469
|
-
|
|
96470
|
-
|
|
96471
|
-
|
|
96472
|
-
|
|
96462
|
+
}, Header = ({ preferences: N, labPreferences: W, printEmailClick: M }) => {
|
|
96463
|
+
const [Y, X] = useState(), I = "https://media.healthplix.com/imgrep/";
|
|
96464
|
+
let w, x, D = "30", R = "30", C = !1;
|
|
96465
|
+
if (W)
|
|
96466
|
+
w = M ? W.lab_pdf_header_height : W.lab_header_height, x = W.lab_logo_header ? `${I}${W.lab_logo_header}` : void 0;
|
|
96467
|
+
else if (N) {
|
|
96468
|
+
const { visit_pad_json: H, org_person_logo_header_url: Q } = N, {
|
|
96469
|
+
headerHeight: $,
|
|
96470
|
+
print_on_letter: _,
|
|
96471
|
+
leftMargin: ee,
|
|
96472
|
+
rightMargin: ae,
|
|
96473
|
+
pdf_margin_left_V2: ne,
|
|
96474
|
+
pdf_margin_right_V2: ce,
|
|
96475
|
+
pdf_header_height_V2: te
|
|
96476
|
+
} = typeof H == "string" && H && JSON.parse(H) || {}, de = M && te?.rows?.trim() ? te : $, ue = M && ne?.rows?.trim() ? ne : ee, re = M && ce?.rows?.trim() ? ce : ae;
|
|
96477
|
+
w = de?.rows, x = Q, D = ue?.rows, R = re?.rows, C = _?.print === "1";
|
|
96478
|
+
}
|
|
96479
|
+
const J = StyleSheet.create({
|
|
96473
96480
|
header: {
|
|
96474
|
-
height: `${parseInt(
|
|
96481
|
+
height: `${parseInt(w || "65")}px`,
|
|
96475
96482
|
width: "100%"
|
|
96476
96483
|
},
|
|
96477
96484
|
image: {
|
|
@@ -96480,43 +96487,49 @@ const events = {}, pdf$2 = (N) => {
|
|
|
96480
96487
|
objectPosition: "top"
|
|
96481
96488
|
},
|
|
96482
96489
|
margin_container: {
|
|
96483
|
-
marginLeft: `${
|
|
96484
|
-
marginRight: `${
|
|
96490
|
+
marginLeft: `${D || 30}`,
|
|
96491
|
+
marginRight: `${R || 30}`,
|
|
96485
96492
|
overflow: "hidden"
|
|
96486
96493
|
}
|
|
96487
96494
|
});
|
|
96488
|
-
|
|
96489
|
-
(
|
|
96490
|
-
|
|
96491
|
-
|
|
96492
|
-
|
|
96493
|
-
}, Footer = ({ preferences: N,
|
|
96494
|
-
const [
|
|
96495
|
-
|
|
96496
|
-
|
|
96497
|
-
|
|
96498
|
-
|
|
96499
|
-
|
|
96500
|
-
|
|
96501
|
-
|
|
96502
|
-
|
|
96503
|
-
|
|
96495
|
+
useEffect(() => {
|
|
96496
|
+
X(x ? `${x}?not-from-cache-please` : void 0);
|
|
96497
|
+
}, [x]);
|
|
96498
|
+
const B = N?.visit_pad_json ? JSON.parse(N.visit_pad_json).pdf_print_header_first?.print !== "1" : !0;
|
|
96499
|
+
return !!Y && /* @__PURE__ */ jsxRuntimeExports.jsx(View, { fixed: B, style: J.header, id: "header", children: /* @__PURE__ */ jsxRuntimeExports.jsx(View, { style: J.margin_container, children: (M || !C) && /* @__PURE__ */ jsxRuntimeExports.jsx(Image$1, { style: J.image, src: Y, cache: !0 }) }) });
|
|
96500
|
+
}, Footer = ({ preferences: N, labPreferences: W, setPrintPageCount: M, printEmailClick: Y }) => {
|
|
96501
|
+
const [X, I] = useState(), w = "https://media.healthplix.com/imgrep/";
|
|
96502
|
+
let x, D, R = "30", C = "30", J = !1, B = !0;
|
|
96503
|
+
if (W)
|
|
96504
|
+
x = Y ? W.lab_pdf_footer_height : W.lab_footer_height, D = W.lab_logo_footer ? `${w}${W.lab_logo_footer}` : void 0, J = !1, B = !0;
|
|
96505
|
+
else if (N) {
|
|
96506
|
+
const { visit_pad_json: Q, org_person_logo_footer_url: $ } = N, {
|
|
96507
|
+
footerHeight: _,
|
|
96508
|
+
print_on_letter: ee,
|
|
96509
|
+
leftMargin: ae,
|
|
96510
|
+
rightMargin: ne,
|
|
96511
|
+
print_watermark_text: ce,
|
|
96512
|
+
pdf_margin_right_V2: te,
|
|
96513
|
+
pdf_margin_left_V2: de,
|
|
96514
|
+
pdf_footer_height_V2: ue
|
|
96515
|
+
} = typeof Q == "string" && Q && JSON.parse(Q) || {}, re = Y && ue?.rows?.trim() ? ue : _, me = Y && de?.rows?.trim() ? de : ae, he = Y && te?.rows?.trim() ? te : ne;
|
|
96516
|
+
x = re?.rows, D = $, R = me?.rows, C = he?.rows, J = ee?.print === "1", B = !ce || ce?.print == "1";
|
|
96517
|
+
}
|
|
96518
|
+
const H = StyleSheet.create({
|
|
96504
96519
|
footer: {
|
|
96505
96520
|
position: "absolute",
|
|
96506
|
-
// bottom: 60, // TODO: 60px added extra for padding bottom to match implementation of EMR 2.0- ACTUAL VALUE- bottom: 0
|
|
96507
96521
|
bottom: 0,
|
|
96508
|
-
// TODO: 60px added extra for padding bottom to match implementation of EMR 2.0- ACTUAL VALUE- bottom: 0. NEW COMMENT - WEPI-3396- 1STAUG2024-SETTING IT BACK TO 0
|
|
96509
96522
|
height: "auto",
|
|
96510
96523
|
width: "100%"
|
|
96511
96524
|
},
|
|
96512
96525
|
image: {
|
|
96513
|
-
height: `${parseInt(
|
|
96526
|
+
height: `${parseInt(x || "65")}px`,
|
|
96514
96527
|
width: "100%",
|
|
96515
96528
|
objectFit: "fill"
|
|
96516
96529
|
},
|
|
96517
96530
|
margin_container: {
|
|
96518
|
-
marginLeft: `${
|
|
96519
|
-
marginRight: `${
|
|
96531
|
+
marginLeft: `${R || 30}`,
|
|
96532
|
+
marginRight: `${C || 30}`
|
|
96520
96533
|
},
|
|
96521
96534
|
footerText: {
|
|
96522
96535
|
textAlign: "center",
|
|
@@ -96524,12 +96537,6 @@ const events = {}, pdf$2 = (N) => {
|
|
|
96524
96537
|
fontSize: "12px",
|
|
96525
96538
|
marginBottom: 3
|
|
96526
96539
|
},
|
|
96527
|
-
offlinefooterText: {
|
|
96528
|
-
textAlign: "center",
|
|
96529
|
-
width: "100%",
|
|
96530
|
-
fontSize: "12px",
|
|
96531
|
-
marginBottom: 2
|
|
96532
|
-
},
|
|
96533
96540
|
pageNumber: {
|
|
96534
96541
|
position: "absolute",
|
|
96535
96542
|
right: 0,
|
|
@@ -96538,19 +96545,17 @@ const events = {}, pdf$2 = (N) => {
|
|
|
96538
96545
|
}
|
|
96539
96546
|
});
|
|
96540
96547
|
return useEffect(() => {
|
|
96541
|
-
(
|
|
96542
|
-
|
|
96543
|
-
})
|
|
96544
|
-
}, [w]), /* @__PURE__ */ jsxRuntimeExports.jsx(View, { fixed: !0, style: ae.footer, id: "footer", children: /* @__PURE__ */ jsxRuntimeExports.jsxs(View, { style: ae.margin_container, children: [
|
|
96545
|
-
!J || J?.print == "1" ? /* @__PURE__ */ jsxRuntimeExports.jsx(Text, { style: ae.footerText, children: "Powered by HealthPlix EMR. www.healthplix.com " }) : null,
|
|
96548
|
+
I(D ? `${D}?not-from-cache-please` : void 0);
|
|
96549
|
+
}, [D]), /* @__PURE__ */ jsxRuntimeExports.jsx(View, { fixed: !0, style: H.footer, id: "footer", children: /* @__PURE__ */ jsxRuntimeExports.jsxs(View, { style: H.margin_container, children: [
|
|
96550
|
+
B && /* @__PURE__ */ jsxRuntimeExports.jsx(Text, { style: H.footerText, children: "Powered by HealthPlix EMR. www.healthplix.com" }),
|
|
96546
96551
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
96547
96552
|
Text,
|
|
96548
96553
|
{
|
|
96549
|
-
style:
|
|
96550
|
-
render: ({ pageNumber:
|
|
96554
|
+
style: H.pageNumber,
|
|
96555
|
+
render: ({ pageNumber: Q, totalPages: $ }) => (M($), $ > 1 ? `${Q} / ${$} ${Q === $ ? "" : "PTO"}` : "")
|
|
96551
96556
|
}
|
|
96552
96557
|
),
|
|
96553
|
-
|
|
96558
|
+
X && (Y || !J) ? /* @__PURE__ */ jsxRuntimeExports.jsx(Image$1, { style: H.image, src: X, cache: !0 }) : /* @__PURE__ */ jsxRuntimeExports.jsx(View, { style: H.image })
|
|
96554
96559
|
] }) });
|
|
96555
96560
|
}, patientMode = {
|
|
96556
96561
|
PRINT_ALL_DETAILS: "0",
|
|
@@ -120197,14 +120202,14 @@ const PrintPediaChartsPdf = memo(
|
|
|
120197
120202
|
regular: "Helvetica",
|
|
120198
120203
|
bold: "Helvetica-Bold"
|
|
120199
120204
|
}
|
|
120200
|
-
},
|
|
120205
|
+
}, formatText = (N) => typeof N != "string" ? N : N.replace(/<br\s*\/?>/gi, `
|
|
120206
|
+
`), TableCell = ({
|
|
120201
120207
|
text: N,
|
|
120202
120208
|
width: W,
|
|
120203
120209
|
isHeader: M = !1,
|
|
120204
120210
|
align: Y = "left",
|
|
120205
120211
|
fontSize: X,
|
|
120206
120212
|
isBold: I = !1
|
|
120207
|
-
// Add a prop for bolding regular text
|
|
120208
120213
|
}) => /* @__PURE__ */ jsxRuntimeExports.jsx(View, { style: { width: W, padding: "8px 5px" }, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
120209
120214
|
Text,
|
|
120210
120215
|
{
|
|
@@ -120212,8 +120217,9 @@ const PrintPediaChartsPdf = memo(
|
|
|
120212
120217
|
fontFamily: M || I ? FontFamily.Helvetica.bold : FontFamily.Helvetica.regular,
|
|
120213
120218
|
fontSize: X,
|
|
120214
120219
|
textAlign: Y
|
|
120220
|
+
// whiteSpace: 'pre-line', // ✅ ensures \n creates new lines
|
|
120215
120221
|
},
|
|
120216
|
-
children: N
|
|
120222
|
+
children: formatText(N)
|
|
120217
120223
|
}
|
|
120218
120224
|
) }), LabTestResultTable = ({ testTemplates: N, colors: W, fontSize: M }) => {
|
|
120219
120225
|
const Y = ["TEST PARAMETER", "RESULT", "BIOLOGICAL REF. INTERVAL"], X = ["45%", "25%", "30%"], I = StyleSheet.create({
|
|
@@ -120224,7 +120230,6 @@ const PrintPediaChartsPdf = memo(
|
|
|
120224
120230
|
tableRow: {
|
|
120225
120231
|
flexDirection: "row",
|
|
120226
120232
|
alignItems: "center"
|
|
120227
|
-
// borderBottom: `1px solid ${colors.borderColor}`,
|
|
120228
120233
|
},
|
|
120229
120234
|
headerRow: {
|
|
120230
120235
|
borderTop: `1px solid ${W.borderColor}`
|
|
@@ -120236,12 +120241,13 @@ const PrintPediaChartsPdf = memo(
|
|
|
120236
120241
|
},
|
|
120237
120242
|
templateHeaderText: {
|
|
120238
120243
|
fontFamily: FontFamily.Helvetica.bold,
|
|
120239
|
-
fontSize: M
|
|
120244
|
+
fontSize: M,
|
|
120245
|
+
whiteSpace: "pre-line"
|
|
120240
120246
|
}
|
|
120241
120247
|
});
|
|
120242
120248
|
return /* @__PURE__ */ jsxRuntimeExports.jsxs(View, { style: I.table, children: [
|
|
120243
120249
|
/* @__PURE__ */ jsxRuntimeExports.jsx(View, { style: { ...I.tableRow, ...I.headerRow }, fixed: !0, children: Y.map((w, x) => /* @__PURE__ */ jsxRuntimeExports.jsx(TableCell, { text: w, width: X[x], isHeader: !0, fontSize: M }, w)) }),
|
|
120244
|
-
N
|
|
120250
|
+
N?.map((w) => /* @__PURE__ */ jsxRuntimeExports.jsxs(React__default.Fragment, { children: [
|
|
120245
120251
|
/* @__PURE__ */ jsxRuntimeExports.jsx(View, { style: I.templateHeaderRow, wrap: !1, children: /* @__PURE__ */ jsxRuntimeExports.jsx(Text, { style: I.templateHeaderText, children: w.template_name }) }),
|
|
120246
120252
|
w.tests.map((x) => /* @__PURE__ */ jsxRuntimeExports.jsxs(View, { style: I.tableRow, wrap: !1, children: [
|
|
120247
120253
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
@@ -120256,7 +120262,7 @@ const PrintPediaChartsPdf = memo(
|
|
|
120256
120262
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
120257
120263
|
TableCell,
|
|
120258
120264
|
{
|
|
120259
|
-
text: `${x.test_value} ${x.test_units || ""}`,
|
|
120265
|
+
text: `${x.test_value} ${formatText(x.test_units) || ""}`,
|
|
120260
120266
|
width: X[1],
|
|
120261
120267
|
fontSize: M,
|
|
120262
120268
|
isBold: !!x.out_of_range
|
|
@@ -120268,17 +120274,18 @@ const PrintPediaChartsPdf = memo(
|
|
|
120268
120274
|
] });
|
|
120269
120275
|
}, PrintLabReport = ({
|
|
120270
120276
|
preferences: N,
|
|
120271
|
-
|
|
120272
|
-
|
|
120273
|
-
|
|
120274
|
-
|
|
120275
|
-
|
|
120277
|
+
branch_preference: W,
|
|
120278
|
+
labReportData: M,
|
|
120279
|
+
labOrderData: Y,
|
|
120280
|
+
onRenderCallback: X,
|
|
120281
|
+
setPrintPageCount: I,
|
|
120282
|
+
printEmailClick: w
|
|
120276
120283
|
}) => {
|
|
120277
|
-
const
|
|
120284
|
+
const x = {
|
|
120278
120285
|
borderColor: "#EAECF0",
|
|
120279
120286
|
headerTextColor: "#101828",
|
|
120280
120287
|
textColor: "#1D2939"
|
|
120281
|
-
},
|
|
120288
|
+
}, D = StyleSheet.create({
|
|
120282
120289
|
page: {
|
|
120283
120290
|
position: "relative",
|
|
120284
120291
|
paddingBottom: 60,
|
|
@@ -120310,21 +120317,36 @@ const PrintPediaChartsPdf = memo(
|
|
|
120310
120317
|
textAlign: "right",
|
|
120311
120318
|
flexShrink: 0
|
|
120312
120319
|
}
|
|
120313
|
-
}),
|
|
120314
|
-
|
|
120320
|
+
}), R = (C) => {
|
|
120321
|
+
X && C?.blob && X(C.blob);
|
|
120315
120322
|
};
|
|
120316
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx(Document$1, { style: { width: 970 }, onRender:
|
|
120317
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
120318
|
-
|
|
120319
|
-
|
|
120320
|
-
|
|
120321
|
-
|
|
120322
|
-
|
|
120323
|
-
|
|
120324
|
-
|
|
120323
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(Document$1, { style: { width: 970 }, onRender: R, children: /* @__PURE__ */ jsxRuntimeExports.jsxs(Page$1, { style: D.page, size: { width: 970 * 72 / 75, height: 1300 }, children: [
|
|
120324
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
120325
|
+
Header,
|
|
120326
|
+
{
|
|
120327
|
+
preferences: N,
|
|
120328
|
+
labPreferences: W.print.lab,
|
|
120329
|
+
printEmailClick: w
|
|
120330
|
+
}
|
|
120331
|
+
),
|
|
120332
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs(View, { style: D.marginContainer, children: [
|
|
120333
|
+
M && /* @__PURE__ */ jsxRuntimeExports.jsx(LabReportPatientHeader, { labReportData: M, labOrderData: Y }),
|
|
120334
|
+
M?.test_templates && /* @__PURE__ */ jsxRuntimeExports.jsx(LabTestResultTable, { testTemplates: M?.test_templates || [], colors: x, fontSize: 16 }),
|
|
120335
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(Text, { style: D.endOfReportText, children: "---- END OF REPORT ----" }),
|
|
120336
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs(View, { style: D.signatureSection, children: [
|
|
120337
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(Text, { style: D.signatureLabel, children: "Signature 1" }),
|
|
120338
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(Text, { style: D.signatureLabel, children: "Signature 2" })
|
|
120325
120339
|
] })
|
|
120326
120340
|
] }),
|
|
120327
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
120341
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
120342
|
+
Footer,
|
|
120343
|
+
{
|
|
120344
|
+
printEmailClick: w,
|
|
120345
|
+
labPreferences: W.print.lab,
|
|
120346
|
+
preferences: N,
|
|
120347
|
+
setPrintPageCount: I
|
|
120348
|
+
}
|
|
120349
|
+
)
|
|
120328
120350
|
] }) });
|
|
120329
120351
|
}, PrintLabReportPDF = memo(
|
|
120330
120352
|
({
|
|
@@ -120337,17 +120359,19 @@ const PrintPediaChartsPdf = memo(
|
|
|
120337
120359
|
setPrintPageCount: w,
|
|
120338
120360
|
printEmailClick: x
|
|
120339
120361
|
}) => {
|
|
120340
|
-
const D =
|
|
120341
|
-
|
|
120342
|
-
|
|
120343
|
-
|
|
120344
|
-
|
|
120345
|
-
|
|
120346
|
-
|
|
120347
|
-
|
|
120348
|
-
|
|
120362
|
+
const D = (C, J) => {
|
|
120363
|
+
const B = document.createElement("a");
|
|
120364
|
+
B.href = URL.createObjectURL(C), B.download = J, document.body.appendChild(B), B.click(), document.body.removeChild(B), URL.revokeObjectURL(B.href), I(void 0);
|
|
120365
|
+
}, R = (C) => {
|
|
120366
|
+
if (C)
|
|
120367
|
+
if (X())
|
|
120368
|
+
W || M(C);
|
|
120369
|
+
else {
|
|
120370
|
+
const J = N?.patientDetails?.name || "patient", B = N?.labOrderData?.lab_id || Date.now(), H = `Lab-Report-${J.replace(/\s+/g, "_")}-${B}.pdf`;
|
|
120371
|
+
D(C, H);
|
|
120349
120372
|
}
|
|
120350
|
-
}
|
|
120373
|
+
};
|
|
120374
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment, { children: N && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { className: "hfl-h-[85vh] hfl-w-[210mm] xxs:max-md:hfl-h-[70vh] xxs:max-sm:hfl-w-[150mm] md:hfl-w-[180mm]", children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
120351
120375
|
PDFViewer,
|
|
120352
120376
|
{
|
|
120353
120377
|
className: "hfl-h-[85vh] hfl-w-[210mm] xxs:max-md:hfl-h-[70vh] xxs:max-sm:hfl-w-[150mm] md:hfl-w-[180mm]",
|
|
@@ -120357,9 +120381,10 @@ const PrintPediaChartsPdf = memo(
|
|
|
120357
120381
|
PrintLabReport,
|
|
120358
120382
|
{
|
|
120359
120383
|
preferences: N?.preferences,
|
|
120384
|
+
branch_preference: N?.branch_preference,
|
|
120360
120385
|
labReportData: N?.labReportData,
|
|
120361
120386
|
labOrderData: N?.labOrderData,
|
|
120362
|
-
onRenderCallback:
|
|
120387
|
+
onRenderCallback: R,
|
|
120363
120388
|
setPrintPageCount: w,
|
|
120364
120389
|
printEmailClick: x
|
|
120365
120390
|
}
|
|
@@ -121005,14 +121030,14 @@ export {
|
|
|
121005
121030
|
GET_BILL_ITEM as n,
|
|
121006
121031
|
GET_REFERRAL as o,
|
|
121007
121032
|
GET_IPD_CASE as p,
|
|
121008
|
-
|
|
121009
|
-
|
|
121010
|
-
|
|
121011
|
-
|
|
121012
|
-
|
|
121013
|
-
|
|
121014
|
-
|
|
121015
|
-
|
|
121016
|
-
|
|
121033
|
+
GET_INSURANCE_LIST as q,
|
|
121034
|
+
UPDATE_PATIENT_DETAIL as r,
|
|
121035
|
+
PUT_APPOINTMENTS as s,
|
|
121036
|
+
POST_PAYMENT as t,
|
|
121037
|
+
PUT_BILLS as u,
|
|
121038
|
+
GET_BILLS_PAYMENTS_BILL_ID as v,
|
|
121039
|
+
PUT_BILL_ITEM as w,
|
|
121040
|
+
DELETE_TRANSACTION as x,
|
|
121041
|
+
GET_PATIENT_POPUP_HPLXLAB as y,
|
|
121017
121042
|
VERIFY_ABHA_OTP as z
|
|
121018
121043
|
};
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { j as t, b as r, q as Y, K as Z } from "./index-Bd0CDVpH.js";
|
|
2
2
|
import { useState as o, useRef as C, useCallback as y, useMemo as ee, useEffect as D } from "react";
|
|
3
|
-
import { g as te } from "./APIAction-
|
|
3
|
+
import { g as te } from "./APIAction-DT8TOViB.js";
|
|
4
4
|
import { u as ne } from "./useMediaQuery-CZAbdJzN.js";
|
|
5
|
-
import { d as re, g as le, a as G, E as se } from "./common-utils-
|
|
5
|
+
import { d as re, g as le, a as G, E as se } from "./common-utils-DOjdqsiU.js";
|
|
6
6
|
const oe = Math.abs(window.orientation || 0) === 90, de = (T) => {
|
|
7
7
|
const {
|
|
8
8
|
addPatientHandler: R,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const t=require("./index-DQlbIHh3.cjs"),n=require("react"),W=require("./APIAction-
|
|
1
|
+
"use strict";const t=require("./index-DQlbIHh3.cjs"),n=require("react"),W=require("./APIAction-BgDEMmVd.cjs"),J=require("./useMediaQuery-D4SIgdMW.cjs"),f=require("./common-utils-Cw6aYEiU.cjs"),V=Math.abs(window.orientation||0)===90,X=P=>{const{addPatientHandler:k,disabled:x,manipulateExistingDOM:C,onPatientSelect:w,showSearchBar:D,setShowSearchBar:a,variable:T}=P,{window_var:o,token:y,envName:v}=T,[h,p]=n.useState(!1),d=n.useRef(null),u=n.useRef(null),[A,G]=n.useState(0),[L,l]=n.useState([]),U=6,[E,b]=n.useState(""),[F,B]=n.useState([]),[O,R]=n.useState(!0),[$,S]=n.useState([]),c=J.useMediaQuery("(max-width: 1024px)"),m=(e,s,r,i)=>{B([{id:1,title:e,description:s,type:r,duration:i}])},_=n.useCallback(async e=>{try{const s={branch_id:o?.org_branch_id_for_seg||"",doctor_id:o?.person_id_for_seg||"",doctor_role_id:o?.doctor_role_id_for_seg||"",term:encodeURIComponent(e),limit:30},r=await W.getPatientList(s,{envName:v,token:y});if(!r){l([]),m("Error","No response received from server","Error",3e3);return}const i=r,N=window.filteredUpcomingAppts||[];if(i.apiError){l([]),m("Error",i.apiError,"Error",3e3);return}i?.persons?.length?(l(i.persons),p(!0),G(Number(i.total_persons))):l([]),N?.length?(R(!1),S(N.slice(0,5))):(R(!0),S([]))}catch(s){console.error(s),m("Error","Something went wrong while fetching patients","Error",3e3)}},[v,y,o?.doctor_role_id_for_seg,o?.org_branch_id_for_seg,o?.person_id_for_seg]),q=n.useMemo(()=>f.debounceFn(e=>{_(e)},500),[_]),z=e=>{const s=e.currentTarget.value.trim();(!isNaN(Number(s.charAt(0)))||s.length>=2)&&q(s)},H=()=>{h||_(E)},M=()=>{x||p(e=>!e)},g=n.useCallback(e=>{u.current&&h&&!u.current.contains(e.target)&&(p(!1),l([]))},[h]);n.useEffect(()=>(document.addEventListener("mousedown",g),()=>document.removeEventListener("mousedown",g)),[g,h]);const Q=e=>{window.location.href.indexOf("/frontdesk")!==-1?window.patientPopupHandlerFromFD(e.patient_role_id,e.patient_person_id):f.goToPage(`viewPatientDashboard.php?pid=${e.patient_role_id}`)},I=async e=>{let s=!0;if(typeof window.beforePatientChange=="function"&&window.location.pathname==f.EAPP_ROUTES.visitpad&&(s=window.beforePatientChange()),p(!1),l([]),!s)return;if(w){w(e);return}window.patient_role_id=e.person_role_id!=="0"?e.person_role_id.toString():"0",window.patient_person_id=e.person_id!=="0"?e.person_id.toString():"0";const r=(e.person_role_id==="0",e.person_role_id);if(r&&(C?.(),window.location.href.indexOf("/frontdesk")!==-1)){window.patientPopupHandlerFromFD(r,e.person_id);return}f.goToPage(`viewPatientDashboard.php?pid=${r}`)},K=()=>{M(),k(),b("")},j=n.useCallback(e=>{d.current&&!d.current.contains(e.target)&&c&&a(!1)},[c,a]);return n.useEffect(()=>(document.addEventListener("mousedown",j),()=>document.removeEventListener("mousedown",j)),[j]),t.jsxRuntimeExports.jsxs(t.jsxRuntimeExports.Fragment,{children:[D?t.jsxRuntimeExports.jsxs("div",{className:`hfl-flex hfl-items-center hfl-justify-center hfl-rounded-full hfl-bg-Blue-900 hfl-text-1 hfl-text-White ${x?"hfl-pointer-events-none hfl-opacity-60":""}`,title:x?"Low internet speed. Feature available only in online mode":"Search Patient",children:[t.jsxRuntimeExports.jsx("input",{ref:d,type:"text",placeholder:"Search Patient 🔍",className:`hfl-rounded-full hfl-border-none hfl-bg-Blue-900 hfl-py-2 hfl-pl-4 ${c&&!V?"xxs:hfl-w-[400px]":"hfl-min-w-[150px]"} sm:hfl-w-full`,"data-qa":"testid_patientSearch",value:E,onKeyUp:z,onChange:e=>b(e.target.value),onClick:H,onBlur:()=>c&&a(!1)}),c&&t.jsxRuntimeExports.jsx("div",{className:"hx_close hfl-cursor-pointer hfl-pr-4",onClick:()=>a(e=>!e)})]}):t.jsxRuntimeExports.jsxs("div",{onClick:()=>a(e=>!e),className:"hfl-flex hfl-cursor-pointer hfl-flex-col hfl-items-center xs:hfl-mr-1 md:hfl-mr-0",children:[t.jsxRuntimeExports.jsx("i",{className:"hx_search",style:{fontSize:"18px"}}),t.jsxRuntimeExports.jsx(t.bs,{variant:"Regular",type:"Text md",children:"Search"})]}),t.jsxRuntimeExports.jsx(t.qh,{toastList:F}),t.jsxRuntimeExports.jsxs("div",{ref:u,className:`hfl-absolute hfl-right-[255px] hfl-top-[50px] hfl-max-h-[400px] hfl-w-[430px] hfl-min-w-[430px] hfl-overflow-y-auto hfl-rounded-lg hfl-border hfl-border-Gray-300 hfl-bg-White hfl-text-Gray-700 hfl-shadow-md ${h?"hfl-block":"hfl-hidden"}`,children:[!O&&t.jsxRuntimeExports.jsxs("div",{className:"hfl-flex hfl-flex-col",children:[t.jsxRuntimeExports.jsxs("div",{className:"hfl-flex hfl-items-center hfl-py-[10px] ",children:[t.jsxRuntimeExports.jsx(t.bs,{className:"hfl-px-[12px] hfl-text-Gray-400",variant:"Semibold",type:"Text xs",children:"Upcoming Appointments"}),t.jsxRuntimeExports.jsx("a",{href:"viewPatientAppointments.php",children:t.jsxRuntimeExports.jsx("i",{className:"hx_r-open hfl-text-Primary-700"})})]}),$?.map((e,s)=>t.jsxRuntimeExports.jsxs("div",{className:`hfl-flex hfl-cursor-pointer hfl-justify-between hfl-px-[12px] hfl-py-[4px] hover:hfl-bg-Blue_gray-200 ${s%2===1?"":"hfl-bg-Gray-100"}`,onClick:()=>Q(e),children:[t.jsxRuntimeExports.jsx("div",{className:"hfl-flex hfl-min-w-[92px] hfl-items-center hfl-justify-center hfl-rounded-lg hfl-border hfl-border-Gray-100 hfl-bg-White_20 hfl-p-2",children:t.jsxRuntimeExports.jsx(t.bs,{className:"hfl-whitespace-nowrap hfl-text-Gray-500",variant:"Regular",type:"Text lg",children:e.appnt_time})}),t.jsxRuntimeExports.jsxs("div",{className:"hfl-flex hfl-w-full hfl-flex-col hfl-px-3",children:[t.jsxRuntimeExports.jsx(t.bs,{variant:"Regular",type:"Text md",className:"hfl-text-Gray-700",children:e.org_person_name}),t.jsxRuntimeExports.jsx(t.bs,{variant:"Regular",type:"Text sm",className:"hfl-text-Gray-500",children:e.org_person_phone})]}),t.jsxRuntimeExports.jsx("div",{className:"hfl-flex hfl-items-center",children:t.jsxRuntimeExports.jsx("i",{className:"hx_play-filled hfl-text-Gray-300"})})]},e.patient_role_id))]}),t.jsxRuntimeExports.jsxs("div",{className:"hfl-flex hfl-flex-col",children:[t.jsxRuntimeExports.jsx(t.bs,{style:{fontSize:"14px"},variant:"Semibold",type:"Text sm",className:"hfl-px-[12px] hfl-py-[8px] hfl-text-Primary-600",children:"Patients List"}),t.jsxRuntimeExports.jsx("div",{className:"hfl-max-h-[40vh] hfl-overflow-y-auto hfl-overflow hfl-scrollbar-hide",children:L?.map((e,s)=>t.jsxRuntimeExports.jsxs("div",{className:`hfl-cursor-pointer hfl-px-[11px] hfl-py-[12px] hfl-leading-9 hover:hfl-bg-Blue_gray-200 ${s%2===1?"":"hfl-bg-Gray-100"}`,onClick:()=>I(e),children:[t.jsxRuntimeExports.jsx(t.bs,{variant:"Regular",type:"Text sm",className:"hfl-inline hfl-uppercase hfl-text-Gray-700",style:{fontSize:"14px"},children:e.org_person_bid_str?e.org_person_bid_str+": ":""}),t.jsxRuntimeExports.jsxs(t.bs,{variant:"Medium",type:"Text sm",className:" hfl-inline hfl-capitalize hfl-text-Gray-700",style:{fontSize:"14px"},children:[e.org_person_name," ",t.jsxRuntimeExports.jsxs("div",{className:"hfl-inline-block",children:["(",e.ageStr.split(" ")[0],", ",f.getGender(Number(e.org_person_gender)),")"]})," "]}),t.jsxRuntimeExports.jsx(t.bs,{variant:"Regular",type:"Text sm",className:"hfl-inline-block hfl-text-Gray-700",style:{fontSize:"14px"},children:e.org_person_phone?`Ph: ${e.org_person_phone}`:""})]},e.person_role_id))})]}),A<U&&t.jsxRuntimeExports.jsx("div",{className:"hfl-flex hfl-justify-center",id:"newPatientAdd",children:t.jsxRuntimeExports.jsx(t.Ku,{hierarchy:"Secondary",icon:"Left",iconFile:"hx_add",onClick:K,size:"lg",textField:"Create New Patient",className:"hfl-flex hfl-w-full hfl-justify-center"})})]})]})};exports.SearchPatients=X;
|
|
@@ -2,7 +2,7 @@ import { j as i, b as U, P as _, K as l, t as TA } from "./index-Bd0CDVpH.js";
|
|
|
2
2
|
import * as Q from "react";
|
|
3
3
|
import { useState as K, useEffect as r, useMemo as xA, useRef as PA, useCallback as nA } from "react";
|
|
4
4
|
import { M as LA } from "./index-T1lUjzhG.js";
|
|
5
|
-
import { h as sA, m as NA, r as SA, R as lA, E as $ } from "./common-utils-
|
|
5
|
+
import { h as sA, m as NA, r as SA, R as lA, E as $ } from "./common-utils-DOjdqsiU.js";
|
|
6
6
|
import { d as XA } from "./dayjs.min-D52_GdfV.js";
|
|
7
7
|
import { E as uA } from "./CommonConstant-Bj7SvPfU.js";
|
|
8
8
|
const fA = "../modelChangePassword.php", qA = async (A, E) => {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const c=require("./index-DQlbIHh3.cjs"),F=require("react"),UA=require("./index-DkA8S5IK.cjs"),L=require("./common-utils-
|
|
1
|
+
"use strict";const c=require("./index-DQlbIHh3.cjs"),F=require("react"),UA=require("./index-DkA8S5IK.cjs"),L=require("./common-utils-Cw6aYEiU.cjs"),KA=require("./dayjs.min-DXp74Ozx.cjs"),oA=require("./CommonConstant-COHqiSWL.cjs");function zA(A){const E=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(A){for(const I in A)if(I!=="default"){const g=Object.getOwnPropertyDescriptor(A,I);Object.defineProperty(E,I,g.get?g:{enumerable:!0,get:()=>A[I]})}}return E.default=A,Object.freeze(E)}const Q=zA(F),eA="../modelChangePassword.php",TA=async(A,E)=>{try{return(await L.hplxAPI(E.token,E.env).post(eA,A))?.data}catch(I){return console.error(I),Promise.reject(I)}},PA=A=>{const{closeModel:E,modalIsOpen:I,showToast:g,variable:B}=A,[M,C]=F.useState(""),[D,w]=F.useState(""),[G,x]=F.useState(""),[Y,j]=F.useState({password:"",confirmPassword:"",oldPassword:""}),[H,J]=F.useState(!1),R=()=>{w(""),C(""),x(""),j({password:"",confirmPassword:"",oldPassword:""})},O=async()=>{const i=new FormData;i.append("oldPassword",Y.oldPassword),i.append("pass1",Y.password),i.append("pass2",Y.confirmPassword),i.append("recaptcha-token","");const k=await TA(i,B),{apierror:m}=k||{};m?(g?.("Change Password",m,"Error",1500),C(m)):(g?.("Password Changed","Password Changed Successfully","Success",1500),R(),E())},h=(i,k)=>{const m=i.target.value.trim(),T={...Y,[k]:m};j(T)};return F.useEffect(()=>{const i=/(?=.*?[A-Z])/,k=/(?=.*?[a-z])/,m=/(?=.*?[0-9])/,Z=/(?=.*?[#?!@$%^&*-])/,T=/.{8,}/,P=Y.password.length,S=i.test(Y.password),U=k.test(Y.password),n=m.test(Y.password),f=Z.test(Y.password),ZA=T.test(Y.password);let d="";P===0||!S||!U||!n||!f||!ZA?d="Password must be 8-20 characters and must contains uppercase, lowercase and numerals!":(d="",J(Y.password===Y.confirmPassword)),w(P>0?d:""),Y.confirmPassword.length>0&&(Y.confirmPassword!==Y.password?x("Confirm password is not matched"):x(""))},[Y]),c.jsxRuntimeExports.jsx("div",{children:c.jsxRuntimeExports.jsx(UA.Modal,{isOpen:I,shouldCloseOnOverlayClick:!0,style:{overlay:{backgroundColor:"rgba(52, 64, 84, 0.5)",position:"fixed",alignContent:"center",justifyContent:"center",zIndex:1060},content:{zIndex:10,boxShadow:"0px 8px 8px -4px #101828",padding:"24px",width:"400px",height:"500px",margin:"auto",borderRadius:"12px"}},children:c.jsxRuntimeExports.jsxs("div",{children:[c.jsxRuntimeExports.jsxs("div",{className:"hfl-mb-4 hfl-flex hfl-flex-col hfl-items-center hfl-justify-items-center",children:[c.jsxRuntimeExports.jsx("div",{className:"hx_lock-closed hfl-mb-4 hfl-flex hfl-h-10 hfl-w-10 hfl-items-center hfl-justify-center hfl-rounded-full hfl-border-8 hfl-border-Blue-50 hfl-bg-Blue-100 hfl-text-4 hfl-text-Blue-600"}),c.jsxRuntimeExports.jsx(c.bs,{variant:"Medium",type:"Text lg",className:"hfl-text-Gray-900",children:"Change Login Password"}),c.jsxRuntimeExports.jsx(c.bs,{variant:"Regular",type:"Text sm",className:"hfl-text-center hfl-text-Gray-500",children:"When you login next time, please enter the new password you saved."})]}),c.jsxRuntimeExports.jsxs("div",{children:[c.jsxRuntimeExports.jsx("div",{className:"hfl-my-2",children:c.jsxRuntimeExports.jsx(c.Ps,{width:"11em",height:"hfl-h-10",label:"Old Password",labelColor:"hfl-text-Gray-700",labelSize:"Text sm",errorMsg:M,inputProps:{type:"password",placeholder:"Old Password",value:Y.oldPassword,autoComplete:"new-password",name:"OldUserPassword",onChange:i=>{h(i,"oldPassword")}}})}),c.jsxRuntimeExports.jsx("div",{className:"hfl-my-2",children:c.jsxRuntimeExports.jsx(c.Ps,{width:"11em",height:"hfl-h-10",label:"New Password",labelColor:"hfl-text-Gray-700",labelSize:"Text sm",errorMsg:D,inputProps:{type:"password",placeholder:"New Password",value:Y.password,autoComplete:"off",onChange:i=>{h(i,"password")}}})}),c.jsxRuntimeExports.jsx("div",{className:"hfl-my-2",children:c.jsxRuntimeExports.jsx(c.Ps,{width:"11em",height:"hfl-h-10",label:"Confirm New Password",labelColor:"hfl-text-Gray-700",labelSize:"Text sm",errorMsg:G,inputProps:{type:"password",placeholder:"Confirm New Password",value:Y.confirmPassword,autoComplete:"off",onChange:i=>{h(i,"confirmPassword")}}})})]}),c.jsxRuntimeExports.jsxs("div",{className:"hfl-mt-[30px] hfl-flex hfl-justify-center hfl-gap-[15px] ",children:[c.jsxRuntimeExports.jsx(c.Ku,{hierarchy:"Secondary-Grey",size:"xl",textField:"Cancel",onClick:()=>{R(),E()},className:"hfl-px-[61.5px] hfl-py-[10px]"}),c.jsxRuntimeExports.jsx(c.Ku,{hierarchy:"Primary",className:"hfl-bg-Primary-600 hfl-px-[57px] hfl-py-[10px] hover:hfl-bg-Primary-700",size:"xl",textField:"Confirm",onClick:()=>{H&&O()}})]})]})})})};/**
|
|
2
2
|
* react-router v7.9.4
|
|
3
3
|
*
|
|
4
4
|
* Copyright (c) Remix Software Inc.
|