@bahmni/registration-app 0.0.1-dev.13
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/LICENSE +9 -0
- package/README.md +7 -0
- package/dist/App.d.ts +4 -0
- package/dist/App.d.ts.map +1 -0
- package/dist/LNWAZHJI-Bw_4ID3r.js +33 -0
- package/dist/MWZ6AO7Z-CaqB01sB.js +42 -0
- package/dist/YPM2AS64-Ck9T4Pfw.js +9159 -0
- package/dist/components/Header/Header.d.ts +18 -0
- package/dist/components/Header/Header.d.ts.map +1 -0
- package/dist/components/Header/index.d.ts +3 -0
- package/dist/components/Header/index.d.ts.map +1 -0
- package/dist/components/forms/additionalInfo/AdditionalInfo.d.ts +15 -0
- package/dist/components/forms/additionalInfo/AdditionalInfo.d.ts.map +1 -0
- package/dist/components/forms/addressInfo/AddressInfo.d.ts +14 -0
- package/dist/components/forms/addressInfo/AddressInfo.d.ts.map +1 -0
- package/dist/components/forms/contactInfo/ContactInfo.d.ts +15 -0
- package/dist/components/forms/contactInfo/ContactInfo.d.ts.map +1 -0
- package/dist/components/forms/profile/Profile.d.ts +22 -0
- package/dist/components/forms/profile/Profile.d.ts.map +1 -0
- package/dist/components/forms/profile/dateAgeUtils.d.ts +44 -0
- package/dist/components/forms/profile/dateAgeUtils.d.ts.map +1 -0
- package/dist/config/tanstackQuery.d.ts +3 -0
- package/dist/config/tanstackQuery.d.ts.map +1 -0
- package/dist/constants/app.d.ts +2 -0
- package/dist/constants/app.d.ts.map +1 -0
- package/dist/contexts/RegistrationConfigContext.d.ts +3 -0
- package/dist/contexts/RegistrationConfigContext.d.ts.map +1 -0
- package/dist/hooks/useCreatePatient.d.ts +26 -0
- package/dist/hooks/useCreatePatient.d.ts.map +1 -0
- package/dist/hooks/useRegistrationConfig.d.ts +8 -0
- package/dist/hooks/useRegistrationConfig.d.ts.map +1 -0
- package/dist/index-Ce5nX17l.js +153910 -0
- package/dist/index.css +1 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +4 -0
- package/dist/locales/locale_en.json +88 -0
- package/dist/locales/locale_es.json +88 -0
- package/dist/models/patient.d.ts +41 -0
- package/dist/models/patient.d.ts.map +1 -0
- package/dist/models/registrationConfig.d.ts +15 -0
- package/dist/models/registrationConfig.d.ts.map +1 -0
- package/dist/models/validation.d.ts +72 -0
- package/dist/models/validation.d.ts.map +1 -0
- package/dist/pages/createPatientPage/CreatePatient.d.ts +3 -0
- package/dist/pages/createPatientPage/CreatePatient.d.ts.map +1 -0
- package/dist/pages/createPatientPage/patientFormService.d.ts +36 -0
- package/dist/pages/createPatientPage/patientFormService.d.ts.map +1 -0
- package/dist/pages/createPatientPage/visitTypeSelector.d.ts +7 -0
- package/dist/pages/createPatientPage/visitTypeSelector.d.ts.map +1 -0
- package/dist/pages/patientSearchPage/appointmentSearchResultActionHandler.d.ts +13 -0
- package/dist/pages/patientSearchPage/appointmentSearchResultActionHandler.d.ts.map +1 -0
- package/dist/pages/patientSearchPage/index.d.ts +8 -0
- package/dist/pages/patientSearchPage/index.d.ts.map +1 -0
- package/dist/pages/patientSearchPage/utils.d.ts +15 -0
- package/dist/pages/patientSearchPage/utils.d.ts.map +1 -0
- package/dist/providers/RegistrationConfigProvider.d.ts +9 -0
- package/dist/providers/RegistrationConfigProvider.d.ts.map +1 -0
- package/dist/utils/ageUtils.d.ts +36 -0
- package/dist/utils/ageUtils.d.ts.map +1 -0
- package/dist/utils/identifierGenderUtils.d.ts +9 -0
- package/dist/utils/identifierGenderUtils.d.ts.map +1 -0
- package/package.json +31 -0
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
export interface BreadcrumbItem {
|
|
3
|
+
label: string;
|
|
4
|
+
href?: string;
|
|
5
|
+
onClick?: () => void;
|
|
6
|
+
}
|
|
7
|
+
export interface HeaderProps {
|
|
8
|
+
breadcrumbs: BreadcrumbItem[];
|
|
9
|
+
showButton?: boolean;
|
|
10
|
+
buttonText?: string;
|
|
11
|
+
buttonDisabled?: boolean;
|
|
12
|
+
onButtonClick?: () => void;
|
|
13
|
+
buttonTestId?: string;
|
|
14
|
+
className?: string;
|
|
15
|
+
}
|
|
16
|
+
declare const Header: React.FC<HeaderProps>;
|
|
17
|
+
export default Header;
|
|
18
|
+
//# sourceMappingURL=Header.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Header.d.ts","sourceRoot":"","sources":["../../../src/components/Header/Header.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,MAAM,WAAW,cAAc;IAC7B,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;CACtB;AAED,MAAM,WAAW,WAAW;IAC1B,WAAW,EAAE,cAAc,EAAE,CAAC;IAC9B,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,aAAa,CAAC,EAAE,MAAM,IAAI,CAAC;IAC3B,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,QAAA,MAAM,MAAM,EAAE,KAAK,CAAC,EAAE,CAAC,WAAW,CAyCjC,CAAC;AAEF,eAAe,MAAM,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/Header/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,UAAU,CAAC;AAC7C,YAAY,EAAE,WAAW,EAAE,cAAc,EAAE,MAAM,UAAU,CAAC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { AdditionalData } from '../../../models/patient';
|
|
2
|
+
export interface AdditionalInfoRef {
|
|
3
|
+
validate: () => boolean;
|
|
4
|
+
getData: () => AdditionalData;
|
|
5
|
+
}
|
|
6
|
+
interface AdditionalInfoProps {
|
|
7
|
+
initialData?: AdditionalData;
|
|
8
|
+
ref?: React.Ref<AdditionalInfoRef>;
|
|
9
|
+
}
|
|
10
|
+
export declare const AdditionalInfo: {
|
|
11
|
+
({ initialData, ref }: AdditionalInfoProps): import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
displayName: string;
|
|
13
|
+
};
|
|
14
|
+
export default AdditionalInfo;
|
|
15
|
+
//# sourceMappingURL=AdditionalInfo.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AdditionalInfo.d.ts","sourceRoot":"","sources":["../../../../src/components/forms/additionalInfo/AdditionalInfo.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AAG9D,MAAM,WAAW,iBAAiB;IAChC,QAAQ,EAAE,MAAM,OAAO,CAAC;IACxB,OAAO,EAAE,MAAM,cAAc,CAAC;CAC/B;AAED,UAAU,mBAAmB;IAC3B,WAAW,CAAC,EAAE,cAAc,CAAC;IAC7B,GAAG,CAAC,EAAE,KAAK,CAAC,GAAG,CAAC,iBAAiB,CAAC,CAAC;CACpC;AAED,eAAO,MAAM,cAAc;2BAA0B,mBAAmB;;CAkEvE,CAAC;AAIF,eAAe,cAAc,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { PatientAddress } from '@bahmni/services';
|
|
2
|
+
export type AddressInfoRef = {
|
|
3
|
+
validate: () => boolean;
|
|
4
|
+
getData: () => PatientAddress;
|
|
5
|
+
};
|
|
6
|
+
interface AddressInfoProps {
|
|
7
|
+
ref?: React.Ref<AddressInfoRef>;
|
|
8
|
+
}
|
|
9
|
+
export declare const AddressInfo: {
|
|
10
|
+
({ ref }: AddressInfoProps): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
displayName: string;
|
|
12
|
+
};
|
|
13
|
+
export default AddressInfo;
|
|
14
|
+
//# sourceMappingURL=AddressInfo.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AddressInfo.d.ts","sourceRoot":"","sources":["../../../../src/components/forms/addressInfo/AddressInfo.tsx"],"names":[],"mappings":"AACA,OAAO,EAIL,KAAK,cAAc,EACpB,MAAM,kBAAkB,CAAC;AAa1B,MAAM,MAAM,cAAc,GAAG;IAC3B,QAAQ,EAAE,MAAM,OAAO,CAAC;IACxB,OAAO,EAAE,MAAM,cAAc,CAAC;CAC/B,CAAC;AAoBF,UAAU,gBAAgB;IACxB,GAAG,CAAC,EAAE,KAAK,CAAC,GAAG,CAAC,cAAc,CAAC,CAAC;CACjC;AAED,eAAO,MAAM,WAAW;cAAa,gBAAgB;;CAqcpD,CAAC;AAIF,eAAe,WAAW,CAAC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { ContactData } from '../../../models/patient';
|
|
2
|
+
export interface ContactInfoRef {
|
|
3
|
+
validate: () => boolean;
|
|
4
|
+
getData: () => ContactData;
|
|
5
|
+
}
|
|
6
|
+
interface ContactInfoProps {
|
|
7
|
+
initialData?: ContactData;
|
|
8
|
+
ref?: React.Ref<ContactInfoRef>;
|
|
9
|
+
}
|
|
10
|
+
export declare const ContactInfo: {
|
|
11
|
+
({ initialData, ref }: ContactInfoProps): import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
displayName: string;
|
|
13
|
+
};
|
|
14
|
+
export default ContactInfo;
|
|
15
|
+
//# sourceMappingURL=ContactInfo.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ContactInfo.d.ts","sourceRoot":"","sources":["../../../../src/components/forms/contactInfo/ContactInfo.tsx"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAG3D,MAAM,WAAW,cAAc;IAC7B,QAAQ,EAAE,MAAM,OAAO,CAAC;IACxB,OAAO,EAAE,MAAM,WAAW,CAAC;CAC5B;AAED,UAAU,gBAAgB;IACxB,WAAW,CAAC,EAAE,WAAW,CAAC;IAC1B,GAAG,CAAC,EAAE,KAAK,CAAC,GAAG,CAAC,cAAc,CAAC,CAAC;CACjC;AAED,eAAO,MAAM,WAAW;2BAA0B,gBAAgB;;CA4DjE,CAAC;AAIF,eAAe,WAAW,CAAC"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { PatientIdentifier } from '@bahmni/services';
|
|
2
|
+
import { BasicInfoData } from '../../../models/patient';
|
|
3
|
+
export interface ProfileRef {
|
|
4
|
+
getData: () => BasicInfoData & {
|
|
5
|
+
dobEstimated: boolean;
|
|
6
|
+
patientIdentifier: PatientIdentifier;
|
|
7
|
+
};
|
|
8
|
+
validate: () => boolean;
|
|
9
|
+
clearData: () => void;
|
|
10
|
+
setCustomError: (field: keyof BasicInfoData, message: string) => void;
|
|
11
|
+
}
|
|
12
|
+
interface ProfileProps {
|
|
13
|
+
initialData?: BasicInfoData;
|
|
14
|
+
initialDobEstimated?: boolean;
|
|
15
|
+
ref?: React.Ref<ProfileRef>;
|
|
16
|
+
}
|
|
17
|
+
export declare const Profile: {
|
|
18
|
+
({ initialData, initialDobEstimated, ref, }: ProfileProps): import("react/jsx-runtime").JSX.Element;
|
|
19
|
+
displayName: string;
|
|
20
|
+
};
|
|
21
|
+
export default Profile;
|
|
22
|
+
//# sourceMappingURL=Profile.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Profile.d.ts","sourceRoot":"","sources":["../../../../src/components/forms/profile/Profile.tsx"],"names":[],"mappings":"AASA,OAAO,EAGL,iBAAiB,EAClB,MAAM,kBAAkB,CAAC;AAE1B,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAc7D,MAAM,WAAW,UAAU;IACzB,OAAO,EAAE,MAAM,aAAa,GAAG;QAC7B,YAAY,EAAE,OAAO,CAAC;QACtB,iBAAiB,EAAE,iBAAiB,CAAC;KACtC,CAAC;IACF,QAAQ,EAAE,MAAM,OAAO,CAAC;IACxB,SAAS,EAAE,MAAM,IAAI,CAAC;IACtB,cAAc,EAAE,CAAC,KAAK,EAAE,MAAM,aAAa,EAAE,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;CACvE;AAED,UAAU,YAAY;IACpB,WAAW,CAAC,EAAE,aAAa,CAAC;IAC5B,mBAAmB,CAAC,EAAE,OAAO,CAAC;IAC9B,GAAG,CAAC,EAAE,KAAK,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC;CAC7B;AAED,eAAO,MAAM,OAAO;iDAIjB,YAAY;;CA8Zd,CAAC;AAIF,eAAe,OAAO,CAAC"}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { formatToDisplay, formatToISO } from '../../../utils/ageUtils';
|
|
2
|
+
export interface DateErrors {
|
|
3
|
+
dateOfBirth: string;
|
|
4
|
+
}
|
|
5
|
+
export interface AgeErrors {
|
|
6
|
+
ageYears: string;
|
|
7
|
+
ageMonths: string;
|
|
8
|
+
ageDays: string;
|
|
9
|
+
}
|
|
10
|
+
interface DateAgeHandlers {
|
|
11
|
+
clearAllErrors: () => void;
|
|
12
|
+
clearAgeData: () => void;
|
|
13
|
+
updateFormWithAge: (date: Date) => void;
|
|
14
|
+
handleDateInputChange: (e: React.ChangeEvent<HTMLInputElement>) => void;
|
|
15
|
+
handleDateOfBirthChange: (selectedDates: Date[]) => void;
|
|
16
|
+
handleAgeChange: (field: 'ageYears' | 'ageMonths' | 'ageDays', value: string) => void;
|
|
17
|
+
}
|
|
18
|
+
interface CreateDateAgeHandlersParams<T extends {
|
|
19
|
+
dateOfBirth: string;
|
|
20
|
+
ageYears: string;
|
|
21
|
+
ageMonths: string;
|
|
22
|
+
ageDays: string;
|
|
23
|
+
}> {
|
|
24
|
+
setDateErrors: React.Dispatch<React.SetStateAction<DateErrors>>;
|
|
25
|
+
setValidationErrors: React.Dispatch<React.SetStateAction<{
|
|
26
|
+
firstName: string;
|
|
27
|
+
lastName: string;
|
|
28
|
+
gender: string;
|
|
29
|
+
dateOfBirth: string;
|
|
30
|
+
}>>;
|
|
31
|
+
setAgeErrors: React.Dispatch<React.SetStateAction<AgeErrors>>;
|
|
32
|
+
setFormData: React.Dispatch<React.SetStateAction<T>>;
|
|
33
|
+
setDobEstimated: React.Dispatch<React.SetStateAction<boolean>>;
|
|
34
|
+
t: (key: string) => string;
|
|
35
|
+
}
|
|
36
|
+
export declare const createDateAgeHandlers: <T extends {
|
|
37
|
+
dateOfBirth: string;
|
|
38
|
+
ageYears: string;
|
|
39
|
+
ageMonths: string;
|
|
40
|
+
ageDays: string;
|
|
41
|
+
}>({ setDateErrors, setValidationErrors, setAgeErrors, setFormData, setDobEstimated, t, }: CreateDateAgeHandlersParams<T>) => DateAgeHandlers;
|
|
42
|
+
export declare const convertTimeToISODateTime: (dateString: string, timeString: string | null) => string | null;
|
|
43
|
+
export { formatToDisplay, formatToISO };
|
|
44
|
+
//# sourceMappingURL=dateAgeUtils.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dateAgeUtils.d.ts","sourceRoot":"","sources":["../../../../src/components/forms/profile/dateAgeUtils.ts"],"names":[],"mappings":"AACA,OAAO,EAEL,eAAe,EACf,WAAW,EACZ,MAAM,yBAAyB,CAAC;AAEjC,MAAM,WAAW,UAAU;IACzB,WAAW,EAAE,MAAM,CAAC;CACrB;AAED,MAAM,WAAW,SAAS;IACxB,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,UAAU,eAAe;IACvB,cAAc,EAAE,MAAM,IAAI,CAAC;IAC3B,YAAY,EAAE,MAAM,IAAI,CAAC;IACzB,iBAAiB,EAAE,CAAC,IAAI,EAAE,IAAI,KAAK,IAAI,CAAC;IACxC,qBAAqB,EAAE,CAAC,CAAC,EAAE,KAAK,CAAC,WAAW,CAAC,gBAAgB,CAAC,KAAK,IAAI,CAAC;IACxE,uBAAuB,EAAE,CAAC,aAAa,EAAE,IAAI,EAAE,KAAK,IAAI,CAAC;IACzD,eAAe,EAAE,CACf,KAAK,EAAE,UAAU,GAAG,WAAW,GAAG,SAAS,EAC3C,KAAK,EAAE,MAAM,KACV,IAAI,CAAC;CACX;AAED,UAAU,2BAA2B,CACnC,CAAC,SAAS;IACR,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,EAAE,MAAM,CAAC;CACjB;IAED,aAAa,EAAE,KAAK,CAAC,QAAQ,CAAC,KAAK,CAAC,cAAc,CAAC,UAAU,CAAC,CAAC,CAAC;IAChE,mBAAmB,EAAE,KAAK,CAAC,QAAQ,CACjC,KAAK,CAAC,cAAc,CAAC;QACnB,SAAS,EAAE,MAAM,CAAC;QAClB,QAAQ,EAAE,MAAM,CAAC;QACjB,MAAM,EAAE,MAAM,CAAC;QACf,WAAW,EAAE,MAAM,CAAC;KACrB,CAAC,CACH,CAAC;IACF,YAAY,EAAE,KAAK,CAAC,QAAQ,CAAC,KAAK,CAAC,cAAc,CAAC,SAAS,CAAC,CAAC,CAAC;IAC9D,WAAW,EAAE,KAAK,CAAC,QAAQ,CAAC,KAAK,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC,CAAC;IACrD,eAAe,EAAE,KAAK,CAAC,QAAQ,CAAC,KAAK,CAAC,cAAc,CAAC,OAAO,CAAC,CAAC,CAAC;IAC/D,CAAC,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,MAAM,CAAC;CAC5B;AAED,eAAO,MAAM,qBAAqB,GAChC,CAAC,SAAS;IACR,WAAW,EAAE,MAAM,CAAC;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,EAAE,MAAM,CAAC;CACjB,EACD,wFAOC,2BAA2B,CAAC,CAAC,CAAC,KAAG,eAwLnC,CAAC;AACF,eAAO,MAAM,wBAAwB,GACnC,YAAY,MAAM,EAClB,YAAY,MAAM,GAAG,IAAI,KACxB,MAAM,GAAG,IAYX,CAAC;AAEF,OAAO,EAAE,eAAe,EAAE,WAAW,EAAE,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tanstackQuery.d.ts","sourceRoot":"","sources":["../../src/config/tanstackQuery.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,uBAAuB,CAAC;AAE1D,eAAO,MAAM,iBAAiB,EAAE,iBAU/B,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"app.d.ts","sourceRoot":"","sources":["../../src/constants/app.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,sBAAsB,iBAAiB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"RegistrationConfigContext.d.ts","sourceRoot":"","sources":["../../src/contexts/RegistrationConfigContext.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,6BAA6B,EAAE,MAAM,8BAA8B,CAAC;AAE7E,eAAO,MAAM,yBAAyB,oEAE1B,CAAC"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { PatientIdentifier, PatientAddress } from '@bahmni/services';
|
|
2
|
+
import { BasicInfoData, ContactData, AdditionalData } from '../models/patient';
|
|
3
|
+
/**
|
|
4
|
+
* Form data structure representing all collected patient information
|
|
5
|
+
*/
|
|
6
|
+
interface CreatePatientFormData {
|
|
7
|
+
profile: BasicInfoData & {
|
|
8
|
+
dobEstimated: boolean;
|
|
9
|
+
patientIdentifier: PatientIdentifier;
|
|
10
|
+
};
|
|
11
|
+
address: PatientAddress;
|
|
12
|
+
contact: ContactData;
|
|
13
|
+
additional: AdditionalData;
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* Custom hook for creating a patient with React Query
|
|
17
|
+
*
|
|
18
|
+
* Handles:
|
|
19
|
+
* - Data transformation from form data to API payload
|
|
20
|
+
* - Mutation execution
|
|
21
|
+
* - Success/error notifications
|
|
22
|
+
* - Navigation after success
|
|
23
|
+
*/
|
|
24
|
+
export declare const useCreatePatient: () => import('@tanstack/react-query').UseMutationResult<import('@bahmni/services').CreatePatientResponse, Error, CreatePatientFormData, unknown>;
|
|
25
|
+
export {};
|
|
26
|
+
//# sourceMappingURL=useCreatePatient.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useCreatePatient.d.ts","sourceRoot":"","sources":["../../src/hooks/useCreatePatient.ts"],"names":[],"mappings":"AAAA,OAAO,EAKL,iBAAiB,EACjB,cAAc,EAIf,MAAM,kBAAkB,CAAC;AAI1B,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAE/E;;GAEG;AACH,UAAU,qBAAqB;IAC7B,OAAO,EAAE,aAAa,GAAG;QACvB,YAAY,EAAE,OAAO,CAAC;QACtB,iBAAiB,EAAE,iBAAiB,CAAC;KACtC,CAAC;IACF,OAAO,EAAE,cAAc,CAAC;IACxB,OAAO,EAAE,WAAW,CAAC;IACrB,UAAU,EAAE,cAAc,CAAC;CAC5B;AAED;;;;;;;;GAQG;AACH,eAAO,MAAM,gBAAgB,kJA2C5B,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { RegistrationConfigContextType } from '../models/registrationConfig';
|
|
2
|
+
/**
|
|
3
|
+
* Custom hook to access the registration config context
|
|
4
|
+
* @returns The registration config context values including config, loading state, error, and refetch
|
|
5
|
+
* @throws Error if used outside RegistrationConfigProvider
|
|
6
|
+
*/
|
|
7
|
+
export declare const useRegistrationConfig: () => RegistrationConfigContextType;
|
|
8
|
+
//# sourceMappingURL=useRegistrationConfig.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useRegistrationConfig.d.ts","sourceRoot":"","sources":["../../src/hooks/useRegistrationConfig.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,6BAA6B,EAAE,MAAM,8BAA8B,CAAC;AAE7E;;;;GAIG;AACH,eAAO,MAAM,qBAAqB,QAAO,6BAUxC,CAAC"}
|