@bahmni/registration-app 0.0.1-dev.55 → 0.0.1-dev.56
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/{LNWAZHJI-PDMf8SeE.js → LNWAZHJI-Bb6b_O-6.js} +2 -2
- package/dist/{MWZ6AO7Z-KR_mzJIH.js → MWZ6AO7Z-bPyoI3VW.js} +2 -2
- package/dist/{YPM2AS64-BK4Wyh7T.js → YPM2AS64-D2d9XEXk.js} +1 -1
- package/dist/components/forms/patientRelationships/PatientRelationships.d.ts +23 -0
- package/dist/components/forms/patientRelationships/PatientRelationships.d.ts.map +1 -0
- package/dist/components/forms/patientRelationships/RelationshipRow.d.ts +33 -0
- package/dist/components/forms/patientRelationships/RelationshipRow.d.ts.map +1 -0
- package/dist/components/forms/patientRelationships/index.d.ts +3 -0
- package/dist/components/forms/patientRelationships/index.d.ts.map +1 -0
- package/dist/hooks/useCreatePatient.d.ts +2 -0
- package/dist/hooks/useCreatePatient.d.ts.map +1 -1
- package/dist/hooks/usePatientSearch.d.ts +15 -0
- package/dist/hooks/usePatientSearch.d.ts.map +1 -0
- package/dist/hooks/useRelationshipValidation.d.ts +20 -0
- package/dist/hooks/useRelationshipValidation.d.ts.map +1 -0
- package/dist/{index-Cr-CZlWD.js → index-Cq8OB9iL.js} +36823 -36464
- package/dist/index.css +1 -1
- package/dist/index.js +1 -1
- package/dist/locales/locale_en.json +16 -0
- package/dist/locales/locale_es.json +17 -1
- package/dist/pages/createPatientPage/CreatePatient.d.ts.map +1 -1
- package/dist/pages/createPatientPage/patientFormService.d.ts +3 -0
- package/dist/pages/createPatientPage/patientFormService.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { c, T as l, P as m, a as u, D as v, Q as i } from "./YPM2AS64-
|
|
2
|
-
import { g as d, c as f, a as e } from "./index-
|
|
1
|
+
import { c, T as l, P as m, a as u, D as v, Q as i } from "./YPM2AS64-D2d9XEXk.js";
|
|
2
|
+
import { g as d, c as f, a as e } from "./index-Cq8OB9iL.js";
|
|
3
3
|
var p = (a) => {
|
|
4
4
|
const [r, t] = c({
|
|
5
5
|
prefix: "TanstackQueryDevtools"
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { c as s, T as c, P as u, a as i, b as m, C as P, Q as d } from "./YPM2AS64-
|
|
2
|
-
import { g as v, c as C, a as e } from "./index-
|
|
1
|
+
import { c as s, T as c, P as u, a as i, b as m, C as P, Q as d } from "./YPM2AS64-D2d9XEXk.js";
|
|
2
|
+
import { g as v, c as C, a as e } from "./index-Cq8OB9iL.js";
|
|
3
3
|
var h = (t) => {
|
|
4
4
|
const [r, o] = s({
|
|
5
5
|
prefix: "TanstackQueryDevtools"
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
var ws = Object.defineProperty;
|
|
2
2
|
var xs = (e, t, n) => t in e ? ws(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
|
|
3
3
|
var _e = (e, t, n) => xs(e, typeof t != "symbol" ? t + "" : t, n);
|
|
4
|
-
import { b as $e, d as K, o as xt, e as H, c as L, a as v, P as zo, m as ye, S as z, t as q, i as k, f as G, h as T, j as $s, k as sr, u as Ce, l as V, s as Vn, n as jn, p as ft, q as A, r as Cs, v as cn, w as He, x as Ss, y as _t, z as Kt, A as ks, B as Es, C as Cn, F as Ds, D as Hr, E as Nt, $ as Ko, G as Ms, H as As, I as W, J as Ur, K as Ts, L as Fs, M as lr, N as Is, O as Os, Q as Kn, R as Ls, T as Ps, U as oe, V as qs, W as _s } from "./index-
|
|
4
|
+
import { b as $e, d as K, o as xt, e as H, c as L, a as v, P as zo, m as ye, S as z, t as q, i as k, f as G, h as T, j as $s, k as sr, u as Ce, l as V, s as Vn, n as jn, p as ft, q as A, r as Cs, v as cn, w as He, x as Ss, y as _t, z as Kt, A as ks, B as Es, C as Cn, F as Ds, D as Hr, E as Nt, $ as Ko, G as Ms, H as As, I as W, J as Ur, K as Ts, L as Fs, M as lr, N as Is, O as Os, Q as Kn, R as Ls, T as Ps, U as oe, V as qs, W as _s } from "./index-Cq8OB9iL.js";
|
|
5
5
|
var Rs = (e) => e != null, zs = (e) => e.filter(Rs);
|
|
6
6
|
function Ks(e) {
|
|
7
7
|
return (...t) => {
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export interface RelationshipData {
|
|
2
|
+
id: string;
|
|
3
|
+
relationshipType: string;
|
|
4
|
+
patientId: string;
|
|
5
|
+
patientUuid?: string;
|
|
6
|
+
patientName?: string;
|
|
7
|
+
tillDate: string;
|
|
8
|
+
}
|
|
9
|
+
export interface PatientRelationshipsRef {
|
|
10
|
+
getData: () => RelationshipData[];
|
|
11
|
+
validate: () => boolean;
|
|
12
|
+
clearData: () => void;
|
|
13
|
+
}
|
|
14
|
+
interface PatientRelationshipsProps {
|
|
15
|
+
initialData?: RelationshipData[];
|
|
16
|
+
ref?: React.Ref<PatientRelationshipsRef>;
|
|
17
|
+
}
|
|
18
|
+
export declare const PatientRelationships: {
|
|
19
|
+
({ initialData, ref, }: PatientRelationshipsProps): import("react/jsx-runtime").JSX.Element;
|
|
20
|
+
displayName: string;
|
|
21
|
+
};
|
|
22
|
+
export default PatientRelationships;
|
|
23
|
+
//# sourceMappingURL=PatientRelationships.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"PatientRelationships.d.ts","sourceRoot":"","sources":["../../../../src/components/forms/patientRelationships/PatientRelationships.tsx"],"names":[],"mappings":"AAgBA,MAAM,WAAW,gBAAgB;IAC/B,EAAE,EAAE,MAAM,CAAC;IACX,gBAAgB,EAAE,MAAM,CAAC;IACzB,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,WAAW,uBAAuB;IACtC,OAAO,EAAE,MAAM,gBAAgB,EAAE,CAAC;IAClC,QAAQ,EAAE,MAAM,OAAO,CAAC;IACxB,SAAS,EAAE,MAAM,IAAI,CAAC;CACvB;AAED,UAAU,yBAAyB;IACjC,WAAW,CAAC,EAAE,gBAAgB,EAAE,CAAC;IACjC,GAAG,CAAC,EAAE,KAAK,CAAC,GAAG,CAAC,uBAAuB,CAAC,CAAC;CAC1C;AAED,eAAO,MAAM,oBAAoB;4BAG9B,yBAAyB;;CA2L3B,CAAC;AAIF,eAAe,oBAAoB,CAAC"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { PatientSuggestion } from '../../../hooks/usePatientSearch';
|
|
2
|
+
import { RelationshipData } from './PatientRelationships';
|
|
3
|
+
export interface RelationshipType {
|
|
4
|
+
uuid: string;
|
|
5
|
+
aIsToB: string;
|
|
6
|
+
bIsToA: string;
|
|
7
|
+
}
|
|
8
|
+
interface RelationshipRowProps {
|
|
9
|
+
relationship: RelationshipData;
|
|
10
|
+
relationshipTypes: RelationshipType[];
|
|
11
|
+
suggestions: PatientSuggestion[];
|
|
12
|
+
errors: {
|
|
13
|
+
relationshipType?: string;
|
|
14
|
+
patientId?: string;
|
|
15
|
+
};
|
|
16
|
+
onUpdateRelationship: (id: string, field: keyof RelationshipData, value: string) => void;
|
|
17
|
+
onPatientSearch: (id: string, value: string) => void;
|
|
18
|
+
onPatientSelect: (id: string, patient: PatientSuggestion | null) => void;
|
|
19
|
+
onRemove: (id: string) => void;
|
|
20
|
+
t: (key: string) => string;
|
|
21
|
+
}
|
|
22
|
+
export declare const RelationshipRow: {
|
|
23
|
+
({ relationship, relationshipTypes, suggestions, errors, onUpdateRelationship, onPatientSearch, onPatientSelect, onRemove, t, }: RelationshipRowProps): {
|
|
24
|
+
id: string;
|
|
25
|
+
relationshipType: import("react/jsx-runtime").JSX.Element;
|
|
26
|
+
patientId: import("react/jsx-runtime").JSX.Element;
|
|
27
|
+
tillDate: import("react/jsx-runtime").JSX.Element;
|
|
28
|
+
actions: import("react/jsx-runtime").JSX.Element;
|
|
29
|
+
};
|
|
30
|
+
displayName: string;
|
|
31
|
+
};
|
|
32
|
+
export {};
|
|
33
|
+
//# sourceMappingURL=RelationshipRow.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"RelationshipRow.d.ts","sourceRoot":"","sources":["../../../../src/components/forms/patientRelationships/RelationshipRow.tsx"],"names":[],"mappings":"AAQA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,iCAAiC,CAAC;AACzE,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,wBAAwB,CAAC;AAS/D,MAAM,WAAW,gBAAgB;IAC/B,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,UAAU,oBAAoB;IAC5B,YAAY,EAAE,gBAAgB,CAAC;IAC/B,iBAAiB,EAAE,gBAAgB,EAAE,CAAC;IACtC,WAAW,EAAE,iBAAiB,EAAE,CAAC;IACjC,MAAM,EAAE;QACN,gBAAgB,CAAC,EAAE,MAAM,CAAC;QAC1B,SAAS,CAAC,EAAE,MAAM,CAAC;KACpB,CAAC;IACF,oBAAoB,EAAE,CACpB,EAAE,EAAE,MAAM,EACV,KAAK,EAAE,MAAM,gBAAgB,EAC7B,KAAK,EAAE,MAAM,KACV,IAAI,CAAC;IACV,eAAe,EAAE,CAAC,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACrD,eAAe,EAAE,CAAC,EAAE,EAAE,MAAM,EAAE,OAAO,EAAE,iBAAiB,GAAG,IAAI,KAAK,IAAI,CAAC;IACzE,QAAQ,EAAE,CAAC,EAAE,EAAE,MAAM,KAAK,IAAI,CAAC;IAC/B,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAAC;CAC5B;AAED,eAAO,MAAM,eAAe;qIAUzB,oBAAoB;;;;;;;;CAmFtB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/forms/patientRelationships/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AAC9D,YAAY,EACV,uBAAuB,EACvB,gBAAgB,GACjB,MAAM,wBAAwB,CAAC"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { PatientIdentifier, PatientAddress } from '@bahmni/services';
|
|
2
|
+
import { RelationshipData } from '../components/forms/patientRelationships/PatientRelationships';
|
|
2
3
|
import { BasicInfoData, ContactData, AdditionalData } from '../models/patient';
|
|
3
4
|
interface CreatePatientFormData {
|
|
4
5
|
profile: BasicInfoData & {
|
|
@@ -9,6 +10,7 @@ interface CreatePatientFormData {
|
|
|
9
10
|
address: PatientAddress;
|
|
10
11
|
contact: ContactData;
|
|
11
12
|
additional: AdditionalData;
|
|
13
|
+
relationships: RelationshipData[];
|
|
12
14
|
}
|
|
13
15
|
export declare const useCreatePatient: () => import('@tanstack/react-query').UseMutationResult<import('@bahmni/services').CreatePatientResponse, Error, CreatePatientFormData, unknown>;
|
|
14
16
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useCreatePatient.d.ts","sourceRoot":"","sources":["../../src/hooks/useCreatePatient.ts"],"names":[],"mappings":"AAAA,OAAO,EAKL,iBAAiB,EACjB,cAAc,EAMf,MAAM,kBAAkB,CAAC;
|
|
1
|
+
{"version":3,"file":"useCreatePatient.d.ts","sourceRoot":"","sources":["../../src/hooks/useCreatePatient.ts"],"names":[],"mappings":"AAAA,OAAO,EAKL,iBAAiB,EACjB,cAAc,EAMf,MAAM,kBAAkB,CAAC;AAG1B,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,+DAA+D,CAAC;AAEtG,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAI/E,UAAU,qBAAqB;IAC7B,OAAO,EAAE,aAAa,GAAG;QACvB,YAAY,EAAE,OAAO,CAAC;QACtB,iBAAiB,EAAE,iBAAiB,CAAC;QACrC,KAAK,CAAC,EAAE,MAAM,CAAC;KAChB,CAAC;IACF,OAAO,EAAE,cAAc,CAAC;IACxB,OAAO,EAAE,WAAW,CAAC;IACrB,UAAU,EAAE,cAAc,CAAC;IAC3B,aAAa,EAAE,gBAAgB,EAAE,CAAC;CACnC;AAED,eAAO,MAAM,gBAAgB,kJA0C5B,CAAC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export interface PatientSuggestion {
|
|
2
|
+
id: string;
|
|
3
|
+
text: string;
|
|
4
|
+
identifier: string;
|
|
5
|
+
name: string;
|
|
6
|
+
}
|
|
7
|
+
export declare const usePatientSearch: () => {
|
|
8
|
+
searchTerms: Record<string, string>;
|
|
9
|
+
getPatientSuggestions: (rowId: string) => PatientSuggestion[];
|
|
10
|
+
handleSearch: (rowId: string, searchValue: string) => void;
|
|
11
|
+
clearSearch: (rowId: string) => void;
|
|
12
|
+
clearAllSearches: () => void;
|
|
13
|
+
setSearchTerms: import('react').Dispatch<import('react').SetStateAction<Record<string, string>>>;
|
|
14
|
+
};
|
|
15
|
+
//# sourceMappingURL=usePatientSearch.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"usePatientSearch.d.ts","sourceRoot":"","sources":["../../src/hooks/usePatientSearch.ts"],"names":[],"mappings":"AAIA,MAAM,WAAW,iBAAiB;IAChC,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,UAAU,EAAE,MAAM,CAAC;IACnB,IAAI,EAAE,MAAM,CAAC;CACd;AAUD,eAAO,MAAM,gBAAgB;;mCAeW,MAAM,KAAG,iBAAiB,EAAE;0BAiBrC,MAAM,eAAe,MAAM;yBAK5B,MAAM;;;CAqBnC,CAAC"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { RelationshipData } from '../components/forms/patientRelationships/PatientRelationships';
|
|
2
|
+
interface ValidationErrors {
|
|
3
|
+
[key: string]: {
|
|
4
|
+
relationshipType?: string;
|
|
5
|
+
patientId?: string;
|
|
6
|
+
};
|
|
7
|
+
}
|
|
8
|
+
export declare const useRelationshipValidation: () => {
|
|
9
|
+
relationshipTypes: {
|
|
10
|
+
uuid: string;
|
|
11
|
+
aIsToB: string;
|
|
12
|
+
bIsToA: string;
|
|
13
|
+
}[];
|
|
14
|
+
validationErrors: ValidationErrors;
|
|
15
|
+
validateRelationships: (relationships: RelationshipData[]) => boolean;
|
|
16
|
+
clearFieldError: (id: string, field: "relationshipType" | "patientId") => void;
|
|
17
|
+
clearAllErrors: () => void;
|
|
18
|
+
};
|
|
19
|
+
export {};
|
|
20
|
+
//# sourceMappingURL=useRelationshipValidation.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useRelationshipValidation.d.ts","sourceRoot":"","sources":["../../src/hooks/useRelationshipValidation.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,+DAA+D,CAAC;AAEtG,UAAU,gBAAgB;IACxB,CAAC,GAAG,EAAE,MAAM,GAAG;QACb,gBAAgB,CAAC,EAAE,MAAM,CAAC;QAC1B,SAAS,CAAC,EAAE,MAAM,CAAC;KACpB,CAAC;CACH;AAED,eAAO,MAAM,yBAAyB;;;;;;;2CAoCU,gBAAgB,EAAE;0BA0C1D,MAAM,SACH,kBAAkB,GAAG,WAAW;;CAsB1C,CAAC"}
|