medos-sdk 1.1.11 → 1.1.12
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/client/MedosClient.js +1 -1
- package/dist/components/appointment-booking/AppointmentCalender.js +10 -72
- package/dist/components/appointment-booking/appointment-modal-styles.d.ts +272 -0
- package/dist/components/appointment-booking/appointment-modal-styles.js +419 -0
- package/dist/components/appointment-booking/components/AppointmentConfirmationStep.d.ts +28 -0
- package/dist/components/appointment-booking/components/AppointmentConfirmationStep.js +107 -0
- package/dist/components/appointment-booking/components/AppointmentDateTimeModal.d.ts +18 -0
- package/dist/components/appointment-booking/components/AppointmentDateTimeModal.js +306 -0
- package/dist/components/appointment-booking/components/AppointmentSummaryStep.d.ts +12 -0
- package/dist/components/appointment-booking/components/AppointmentSummaryStep.js +194 -0
- package/dist/components/appointment-booking/components/BookingOptionStep.d.ts +14 -0
- package/dist/components/appointment-booking/components/BookingOptionStep.js +350 -0
- package/dist/components/appointment-booking/components/DoctorSelectModal.d.ts +14 -0
- package/dist/components/appointment-booking/components/DoctorSelectModal.js +213 -0
- package/dist/components/appointment-booking/components/PatientDetailsStep.d.ts +3 -0
- package/dist/components/appointment-booking/components/PatientDetailsStep.js +96 -0
- package/dist/components/appointment-booking/components/PatientSelectionStep.d.ts +12 -0
- package/dist/components/appointment-booking/components/PatientSelectionStep.js +254 -0
- package/dist/components/appointment-booking/components/PhoneVerificationStep.d.ts +3 -0
- package/dist/components/appointment-booking/components/PhoneVerificationStep.js +49 -0
- package/dist/components/appointment-booking/components/SuccessStep.d.ts +5 -0
- package/dist/components/appointment-booking/components/SuccessStep.js +9 -0
- package/dist/components/appointment-booking/components/index.d.ts +9 -0
- package/dist/components/appointment-booking/components/index.js +9 -0
- package/dist/components/appointment-booking/hooks/useAppointmentFlow.js +1 -0
- package/dist/components/appointment-booking/index.d.ts +2 -4
- package/dist/components/appointment-booking/index.js +2 -2
- package/dist/components/appointment-booking/types.d.ts +4 -0
- package/dist/components/constants/constant.d.ts +2 -0
- package/dist/components/constants/constant.js +15 -0
- package/dist/components/constants/index.d.ts +3 -0
- package/dist/components/constants/index.js +24 -0
- package/dist/components/constants/options.d.ts +13 -0
- package/dist/components/constants/options.js +35 -0
- package/dist/components/constants/validation.d.ts +6 -0
- package/dist/components/constants/validation.js +16 -0
- package/dist/components/enquiry-form/EnquiryForm.d.ts +7 -0
- package/dist/components/enquiry-form/EnquiryForm.js +238 -0
- package/dist/components/enquiry-form/components/ContactInformationStep.d.ts +13 -0
- package/dist/components/enquiry-form/components/ContactInformationStep.js +21 -0
- package/dist/components/enquiry-form/components/ContactPreferenceStep.d.ts +9 -0
- package/dist/components/enquiry-form/components/ContactPreferenceStep.js +20 -0
- package/dist/components/enquiry-form/components/InquiryDetailsStep.d.ts +10 -0
- package/dist/components/enquiry-form/components/InquiryDetailsStep.js +20 -0
- package/dist/components/enquiry-form/components/index.d.ts +3 -0
- package/dist/components/enquiry-form/components/index.js +3 -0
- package/dist/components/enquiry-form/index.d.ts +2 -0
- package/dist/components/enquiry-form/index.js +2 -0
- package/dist/components/index.d.ts +7 -0
- package/dist/components/index.js +7 -0
- package/dist/components/shared/icons/Check.d.ts +6 -0
- package/dist/components/shared/icons/Check.js +2 -0
- package/dist/components/shared/icons/ChevronDownIcon.d.ts +4 -0
- package/dist/components/shared/icons/ChevronDownIcon.js +2 -0
- package/dist/components/shared/icons/ChevronLeft.d.ts +3 -0
- package/dist/components/shared/icons/ChevronLeft.js +3 -0
- package/dist/components/shared/icons/ChevronRight.d.ts +3 -0
- package/dist/components/shared/icons/ChevronRight.js +3 -0
- package/dist/components/shared/icons/CloseIcon.d.ts +9 -0
- package/dist/components/shared/icons/CloseIcon.js +5 -0
- package/dist/components/shared/icons/ConfirmationCheck.d.ts +1 -0
- package/dist/components/shared/icons/ConfirmationCheck.js +9 -0
- package/dist/components/shared/icons/ConsultationType.d.ts +1 -0
- package/dist/components/shared/icons/ConsultationType.js +2 -0
- package/dist/components/shared/icons/Date&TimeIcon.d.ts +1 -0
- package/dist/components/shared/icons/Date&TimeIcon.js +2 -0
- package/dist/components/shared/icons/MapIcon.d.ts +1 -0
- package/dist/components/shared/icons/MapIcon.js +2 -0
- package/dist/components/shared/icons/MedosLogo.d.ts +3 -0
- package/dist/components/shared/icons/MedosLogo.js +3 -0
- package/dist/components/shared/icons/PaymentMethodIcon.d.ts +1 -0
- package/dist/components/shared/icons/PaymentMethodIcon.js +2 -0
- package/dist/components/shared/icons/SuccessIcon.d.ts +8 -0
- package/dist/components/shared/icons/SuccessIcon.js +14 -0
- package/dist/components/shared/icons/UserIcon.d.ts +1 -0
- package/dist/components/shared/icons/UserIcon.js +2 -0
- package/dist/components/shared/icons/index.d.ts +13 -0
- package/dist/components/shared/icons/index.js +13 -0
- package/dist/components/shared/index.d.ts +2 -0
- package/dist/components/shared/index.js +2 -0
- package/dist/components/shared/ui/Calendar.d.ts +5 -0
- package/dist/components/shared/ui/Calendar.js +167 -0
- package/dist/components/shared/ui/SelectDropdown.d.ts +41 -0
- package/dist/components/shared/ui/SelectDropdown.js +301 -0
- package/dist/components/shared/ui/index.d.ts +2 -0
- package/dist/components/shared/ui/index.js +2 -0
- package/dist/components/styles/appointment.d.ts +4 -0
- package/dist/components/styles/appointment.js +220 -0
- package/dist/components/styles/enquiry.d.ts +2 -0
- package/dist/components/styles/enquiry.js +3 -0
- package/dist/components/styles/index.d.ts +2 -0
- package/dist/components/styles/index.js +2 -0
- package/dist/components/styles/shared.d.ts +3 -0
- package/dist/components/styles/shared.js +78 -0
- package/dist/components/styles.d.ts +1 -6
- package/dist/components/styles.js +1 -298
- package/dist/components/theme-styles.js +18 -0
- package/dist/components/types/appointment.d.ts +42 -0
- package/dist/components/types/appointment.js +1 -0
- package/dist/components/types/common.d.ts +24 -0
- package/dist/components/types/common.js +1 -0
- package/dist/components/types/enquiry.d.ts +59 -0
- package/dist/components/types/enquiry.js +1 -0
- package/dist/components/types/index.d.ts +4 -0
- package/dist/components/types/index.js +4 -0
- package/dist/components/types.d.ts +1 -54
- package/dist/components/types.js +1 -38
- package/dist/components/utils/date.d.ts +4 -0
- package/dist/components/utils/date.js +65 -0
- package/dist/components/utils/formatting.d.ts +4 -0
- package/dist/components/utils/formatting.js +9 -0
- package/dist/components/utils/index.d.ts +3 -0
- package/dist/components/utils/index.js +3 -0
- package/dist/components/utils/validation.d.ts +4 -0
- package/dist/components/utils/validation.js +37 -0
- package/dist/components/utils.d.ts +1 -8
- package/dist/components/utils.js +1 -74
- package/dist/components/validation.d.ts +1 -4
- package/dist/components/validation.js +1 -48
- package/dist/constants/index.d.ts +1 -1
- package/dist/constants/index.js +1 -1
- package/dist/index.d.ts +2 -2
- package/dist/index.js +1 -1
- package/dist/react/index.d.ts +3 -3
- package/dist/react/index.js +1 -1
- package/dist/services/AppointmentService.js +26 -9
- package/dist/services/AuthService.js +1 -1
- package/dist/vanilla/AppointmentCalendarWidget.d.ts +8 -0
- package/dist/vanilla/AppointmentCalendarWidget.js +598 -20
- package/dist/vanilla/components/appointment-booking/appointment-modal-styles.d.ts +272 -0
- package/dist/vanilla/components/appointment-booking/components/AppointmentConfirmationStep.d.ts +28 -0
- package/dist/vanilla/components/appointment-booking/components/AppointmentDateTimeModal.d.ts +18 -0
- package/dist/vanilla/components/appointment-booking/components/AppointmentSummaryStep.d.ts +12 -0
- package/dist/vanilla/components/appointment-booking/components/BookingOptionStep.d.ts +14 -0
- package/dist/vanilla/components/appointment-booking/components/DoctorSelectModal.d.ts +14 -0
- package/dist/vanilla/components/appointment-booking/components/PatientDetailsStep.d.ts +3 -0
- package/dist/vanilla/components/appointment-booking/components/PatientSelectionStep.d.ts +12 -0
- package/dist/vanilla/components/appointment-booking/components/PhoneVerificationStep.d.ts +3 -0
- package/dist/vanilla/components/appointment-booking/components/SuccessStep.d.ts +5 -0
- package/dist/vanilla/components/appointment-booking/components/index.d.ts +9 -0
- package/dist/vanilla/components/appointment-booking/index.d.ts +2 -4
- package/dist/vanilla/components/appointment-booking/types.d.ts +4 -0
- package/dist/vanilla/components/constants/constant.d.ts +2 -0
- package/dist/vanilla/components/constants/index.d.ts +3 -0
- package/dist/vanilla/components/constants/options.d.ts +13 -0
- package/dist/vanilla/components/constants/validation.d.ts +6 -0
- package/dist/vanilla/components/enquiry-form/EnquiryForm.d.ts +7 -0
- package/dist/vanilla/components/enquiry-form/components/ContactInformationStep.d.ts +13 -0
- package/dist/vanilla/components/enquiry-form/components/ContactPreferenceStep.d.ts +9 -0
- package/dist/vanilla/components/enquiry-form/components/InquiryDetailsStep.d.ts +10 -0
- package/dist/vanilla/components/enquiry-form/components/index.d.ts +3 -0
- package/dist/vanilla/components/enquiry-form/index.d.ts +2 -0
- package/dist/vanilla/components/index.d.ts +7 -3
- package/dist/vanilla/components/shared/icons/Check.d.ts +6 -0
- package/dist/vanilla/components/shared/icons/ChevronDownIcon.d.ts +4 -0
- package/dist/vanilla/components/shared/icons/ChevronLeft.d.ts +3 -0
- package/dist/vanilla/components/shared/icons/ChevronRight.d.ts +3 -0
- package/dist/vanilla/components/shared/icons/CloseIcon.d.ts +9 -0
- package/dist/vanilla/components/shared/icons/ConfirmationCheck.d.ts +1 -0
- package/dist/vanilla/components/shared/icons/ConsultationType.d.ts +1 -0
- package/dist/vanilla/components/shared/icons/Date&TimeIcon.d.ts +1 -0
- package/dist/vanilla/components/shared/icons/MapIcon.d.ts +1 -0
- package/dist/vanilla/components/shared/icons/MedosLogo.d.ts +3 -0
- package/dist/vanilla/components/shared/icons/PaymentMethodIcon.d.ts +1 -0
- package/dist/vanilla/components/shared/icons/SuccessIcon.d.ts +8 -0
- package/dist/vanilla/components/shared/icons/UserIcon.d.ts +1 -0
- package/dist/vanilla/components/shared/icons/index.d.ts +13 -0
- package/dist/vanilla/components/shared/index.d.ts +2 -0
- package/dist/vanilla/components/shared/ui/Calendar.d.ts +5 -0
- package/dist/vanilla/components/shared/ui/SelectDropdown.d.ts +41 -0
- package/dist/vanilla/components/shared/ui/index.d.ts +2 -0
- package/dist/vanilla/components/styles/appointment.d.ts +4 -0
- package/dist/vanilla/components/styles/enquiry.d.ts +2 -0
- package/dist/vanilla/components/styles/index.d.ts +2 -0
- package/dist/vanilla/components/styles/shared.d.ts +3 -0
- package/dist/vanilla/components/styles.d.ts +1 -6
- package/dist/vanilla/components/types/appointment.d.ts +42 -0
- package/dist/vanilla/components/types/common.d.ts +24 -0
- package/dist/vanilla/components/types/enquiry.d.ts +59 -0
- package/dist/vanilla/components/types/index.d.ts +4 -0
- package/dist/vanilla/components/types.d.ts +1 -54
- package/dist/vanilla/components/utils/date.d.ts +4 -0
- package/dist/vanilla/components/utils/formatting.d.ts +4 -0
- package/dist/vanilla/components/utils/index.d.ts +3 -0
- package/dist/vanilla/components/utils/validation.d.ts +4 -0
- package/dist/vanilla/components/utils.d.ts +1 -8
- package/dist/vanilla/components/validation.d.ts +1 -4
- package/dist/vanilla/constants/index.d.ts +1 -1
- package/dist/vanilla/enquiry-widget.js +3277 -56
- package/dist/vanilla/index.d.ts +2 -2
- package/dist/vanilla/react/index.d.ts +3 -3
- package/dist/vanilla/vanilla/AppointmentCalendarWidget.d.ts +8 -0
- package/dist/vanilla/widget.css +214 -0
- package/dist/vanilla/widget.js +4047 -187
- package/package.json +2 -2
|
@@ -2,7 +2,7 @@ import axios from "axios";
|
|
|
2
2
|
import { AuthService } from "../services/AuthService";
|
|
3
3
|
import { AppointmentService, } from "../services/AppointmentService";
|
|
4
4
|
import { PatientService, } from "../services/PatientService";
|
|
5
|
-
import { API_BASE_URL } from "../constants";
|
|
5
|
+
import { API_BASE_URL } from "../components/constants";
|
|
6
6
|
class MedosClient {
|
|
7
7
|
static async init({ apiKey }) {
|
|
8
8
|
if (!apiKey) {
|
|
@@ -1,17 +1,11 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { AppointmentDateTimeModal } from "
|
|
3
|
-
import { DoctorSelectModal } from "../DoctorSelectModal";
|
|
4
|
-
import { PhoneVerificationStep } from "../PhoneVerificationStep";
|
|
5
|
-
import { PatientSelectionStep } from "../PatientSelectionStep";
|
|
6
|
-
import { PatientDetailsStep } from "../PatientDetailsStep";
|
|
7
|
-
import AppointmentConfirmationStep from "../AppointmentConfirmationStep";
|
|
8
|
-
import { BookingOptionStep } from "../BookingOptionStep";
|
|
9
|
-
import { AppointmentSummaryStep } from "../AppointmentSummaryStep";
|
|
2
|
+
import { AppointmentDateTimeModal, DoctorSelectModal, PhoneVerificationStep, PatientSelectionStep, PatientDetailsStep, AppointmentConfirmationStep, BookingOptionStep, AppointmentSummaryStep, } from "./components";
|
|
10
3
|
import { useTheme } from "../../react/hooks/useTheme";
|
|
11
4
|
import { useBreakpoint } from "../../core/theme/responsive";
|
|
12
|
-
import MedosLogo from "../
|
|
5
|
+
import { MedosLogo } from "../shared/icons";
|
|
13
6
|
import { useAppointmentState, useAppointmentFlow, useInitializeAddresses, } from "./hooks";
|
|
14
|
-
import { formatDateToISO } from "../utils";
|
|
7
|
+
import { formatDateToISO } from "../utils/date";
|
|
8
|
+
import { getContainerStyles } from "../theme-styles";
|
|
15
9
|
export const AppointmentCalender = ({ onError, }) => {
|
|
16
10
|
const { state, dispatch, setStep, resetForm } = useAppointmentState();
|
|
17
11
|
const { goBack, handleDateChange, sendOtp, verifyOtp, submitAppointment } = useAppointmentFlow(state, dispatch, onError);
|
|
@@ -51,7 +45,11 @@ export const AppointmentCalender = ({ onError, }) => {
|
|
|
51
45
|
};
|
|
52
46
|
const handlePackageSelect = (pkg) => {
|
|
53
47
|
dispatch({ type: "SET_SELECTED_NEW_PACKAGE", payload: pkg });
|
|
48
|
+
dispatch({ type: "SET_PACKAGE_CONFIG_ID", payload: pkg.id });
|
|
49
|
+
const packageAmount = pkg.discountedPrice || pkg.price;
|
|
50
|
+
dispatch({ type: "SET_PACKAGE_AMOUNT", payload: packageAmount });
|
|
54
51
|
dispatch({ type: "SET_BOOKING_TYPE", payload: "PACKAGE_PURCHASE" });
|
|
52
|
+
dispatch({ type: "SET_CONSULTATION_CHARGE", payload: "0" });
|
|
55
53
|
dispatch({ type: "SET_SHOW_PACKAGE_EXPLORER", payload: false });
|
|
56
54
|
setStep(2);
|
|
57
55
|
};
|
|
@@ -155,8 +153,8 @@ export const AppointmentCalender = ({ onError, }) => {
|
|
|
155
153
|
};
|
|
156
154
|
const theme = useTheme();
|
|
157
155
|
const breakpoint = useBreakpoint(theme);
|
|
158
|
-
const styles =
|
|
159
|
-
return (_jsx("div", { style: styles.container, children: _jsxs("div", { style: styles.card, children: [_jsx("div", { style: styles.header, children: _jsx("h2", { style: styles.title, children: "Book Appointment" }) }), _jsx("hr", {}), _jsxs("div", { style: styles.content, children: [state.loading && _jsx("div", { style: { marginBottom: 12 }, children: "Loading..." }), state.error && _jsx("div", { style: styles.errorMessage, children: state.error }), state.step === 0 && (_jsx(PhoneVerificationStep, { state: state, dispatch: dispatch, onSendOtp: sendOtp, onVerifyOtp: verifyOtp, onBack: () => { }, onContinue: handlePhoneVerificationContinue })), state.step === 1 && (_jsx(BookingOptionStep, { userSessionPacks: state.userSessionPacks || [], availablePackages: state.availablePackages || [], showPackageExplorer: state.showPackageExplorer || false, selectedSessionPack: state.selectedSessionPack, selectedNewPackage: state.selectedNewPackage, onSelectOption: handleBookingOptionSelect, onSelectPackage: handlePackageSelect, onBack: handleGoBack })), state.step === 2 && (_jsx(DoctorSelectModal, { addresses: state.addresses, addressDoctorsMap: state.addressDoctorsMap, selectedAddressId: state.selectedAddress, selectedDoctorId: state.selectedDoctor, onCancel: handleGoBack, onContinue: handleDoctorSelect })), state.step === 3 && (_jsx(AppointmentDateTimeModal, { onlineFee: 500, offlineFee: 300, slots: state.slots, selectedDate: state.selectedDate, selectedSlot: state.selectedSlot, consultationMode: state.consultationMode, onCancel: handleGoBack, onDateChange: handleDateChange, onContinue: handleDateTimeModalContinue, initialStep: "consultation" })), state.step === 4 && (_jsx(PatientSelectionStep, { verifiedPatients: state.verifiedPatients, selectedPatient: state.selectedPatient, onSelectPatient: handleSelectExistingPatient, onProceedAsNewPatient: handleProceedAsNewPatient, onBack: handleGoBack })), state.step === 5 && (_jsx(PatientDetailsStep, { state: state, dispatch: dispatch, onBack: handleGoBack, onSubmit: handlePatientDetailsSubmit })), state.step === 6 && (_jsx(AppointmentSummaryStep, { state: state, selectedDoctor: state.selectedAddress && state.selectedDoctor
|
|
156
|
+
const styles = getContainerStyles(theme, "medos", breakpoint);
|
|
157
|
+
return (_jsx("div", { style: styles.container, children: _jsxs("div", { style: styles.card, children: [_jsx("div", { style: styles.header, children: _jsx("h2", { style: styles.title, children: "Book Appointment" }) }), _jsx("hr", {}), _jsxs("div", { style: styles.content, children: [state.loading && _jsx("div", { style: { marginBottom: 12 }, children: "Loading..." }), state.error && _jsx("div", { style: styles.errorMessage, children: state.error }), state.step === 0 && (_jsx(PhoneVerificationStep, { state: state, dispatch: dispatch, onSendOtp: sendOtp, onVerifyOtp: verifyOtp, onBack: () => { }, onContinue: handlePhoneVerificationContinue })), state.step === 1 && (_jsx(BookingOptionStep, { userSessionPacks: state.userSessionPacks || [], availablePackages: state.availablePackages || [], showPackageExplorer: state.showPackageExplorer || false, selectedSessionPack: state.selectedSessionPack, selectedNewPackage: state.selectedNewPackage, onSelectOption: handleBookingOptionSelect, onSelectPackage: handlePackageSelect, onBack: handleGoBack })), state.step === 2 && (_jsx(DoctorSelectModal, { addresses: state.addresses, addressDoctorsMap: state.addressDoctorsMap, selectedAddressId: state.selectedAddress, selectedDoctorId: state.selectedDoctor, selectedNewPackage: state.selectedNewPackage, onCancel: handleGoBack, onContinue: handleDoctorSelect })), state.step === 3 && (_jsx(AppointmentDateTimeModal, { onlineFee: 500, offlineFee: 300, slots: state.slots, selectedDate: state.selectedDate, selectedSlot: state.selectedSlot, consultationMode: state.consultationMode, onCancel: handleGoBack, onDateChange: handleDateChange, onContinue: handleDateTimeModalContinue, initialStep: "consultation" })), state.step === 4 && (_jsx(PatientSelectionStep, { verifiedPatients: state.verifiedPatients, selectedPatient: state.selectedPatient, onSelectPatient: handleSelectExistingPatient, onProceedAsNewPatient: handleProceedAsNewPatient, onBack: handleGoBack })), state.step === 5 && (_jsx(PatientDetailsStep, { state: state, dispatch: dispatch, onBack: handleGoBack, onSubmit: handlePatientDetailsSubmit })), state.step === 6 && (_jsx(AppointmentSummaryStep, { state: state, selectedDoctor: state.selectedAddress && state.selectedDoctor
|
|
160
158
|
? state.addressDoctorsMap[state.selectedAddress]?.find((doc) => doc.id === state.selectedDoctor) || null
|
|
161
159
|
: null, selectedAddress: state.selectedAddress
|
|
162
160
|
? state.addresses.find((addr) => addr.id === state.selectedAddress) || null
|
|
@@ -185,63 +183,3 @@ export const AppointmentCalender = ({ onError, }) => {
|
|
|
185
183
|
? state.addresses.find((addr) => addr.id === state.selectedAddress) || null
|
|
186
184
|
: null, onClose: resetForm, onGoBackToSlots: () => setStep(3) })), _jsxs("div", { style: styles.branding, children: [_jsx("span", { style: styles.poweredBy, children: "Powered by" }), _jsx("a", { href: "https://medos.one", target: "_blank", rel: "noopener noreferrer", children: _jsx(MedosLogo, { style: { height: 50, width: "auto" } }) })] })] })] }) }));
|
|
187
185
|
};
|
|
188
|
-
const getStyles = (theme, breakpoint) => {
|
|
189
|
-
const isMobile = breakpoint === "mobile";
|
|
190
|
-
const isTablet = breakpoint === "tablet";
|
|
191
|
-
return {
|
|
192
|
-
container: {
|
|
193
|
-
display: "flex",
|
|
194
|
-
justifyContent: "center",
|
|
195
|
-
padding: isMobile ? 12 : 20,
|
|
196
|
-
fontFamily: theme.typography.fontFamily,
|
|
197
|
-
background: theme.colors.background,
|
|
198
|
-
},
|
|
199
|
-
card: {
|
|
200
|
-
width: "100%",
|
|
201
|
-
maxWidth: isMobile || isTablet ? "100%" : 840,
|
|
202
|
-
background: theme.colors.surface,
|
|
203
|
-
borderRadius: isMobile ? theme.radii.md : theme.radii.lg,
|
|
204
|
-
boxShadow: isMobile ? theme.shadows.md : theme.shadows.lg,
|
|
205
|
-
overflow: "hidden",
|
|
206
|
-
boxSizing: "border-box",
|
|
207
|
-
},
|
|
208
|
-
header: {
|
|
209
|
-
padding: isMobile ? "16px 16px" : "20px 24px",
|
|
210
|
-
},
|
|
211
|
-
title: {
|
|
212
|
-
margin: 0,
|
|
213
|
-
fontSize: isMobile
|
|
214
|
-
? theme.typography.fontSizeLg
|
|
215
|
-
: theme.typography.fontSizeXl,
|
|
216
|
-
fontWeight: theme.typography.fontWeightSemibold,
|
|
217
|
-
},
|
|
218
|
-
content: {
|
|
219
|
-
padding: isMobile ? 16 : 24,
|
|
220
|
-
},
|
|
221
|
-
errorMessage: {
|
|
222
|
-
marginBottom: 12,
|
|
223
|
-
color: theme.colors.error,
|
|
224
|
-
fontWeight: 600,
|
|
225
|
-
padding: isMobile ? "10px" : "12px",
|
|
226
|
-
background: theme.colors.errorBackground,
|
|
227
|
-
borderRadius: theme.radii.md,
|
|
228
|
-
border: `1px solid ${theme.colors.errorBorder}`,
|
|
229
|
-
fontSize: theme.typography.fontSizeSm,
|
|
230
|
-
},
|
|
231
|
-
branding: {
|
|
232
|
-
display: "flex",
|
|
233
|
-
alignItems: "center",
|
|
234
|
-
justifyContent: "center",
|
|
235
|
-
gap: 8,
|
|
236
|
-
marginTop: isMobile ? 16 : 24,
|
|
237
|
-
paddingTop: isMobile ? 12 : 16,
|
|
238
|
-
borderTop: `1px solid ${theme.colors.border}`,
|
|
239
|
-
opacity: 0.8,
|
|
240
|
-
},
|
|
241
|
-
poweredBy: {
|
|
242
|
-
fontSize: 12,
|
|
243
|
-
color: theme.colors.textSecondary,
|
|
244
|
-
fontWeight: 500,
|
|
245
|
-
},
|
|
246
|
-
};
|
|
247
|
-
};
|
|
@@ -0,0 +1,272 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
export declare const getMobileStyles: (theme: any, breakpoint: string) => {
|
|
3
|
+
container: {
|
|
4
|
+
backgroundColor: any;
|
|
5
|
+
padding: string;
|
|
6
|
+
maxWidth: string;
|
|
7
|
+
fontFamily: any;
|
|
8
|
+
color: any;
|
|
9
|
+
minHeight: string;
|
|
10
|
+
boxSizing: "border-box";
|
|
11
|
+
};
|
|
12
|
+
header: {
|
|
13
|
+
marginBottom: number;
|
|
14
|
+
};
|
|
15
|
+
title: {
|
|
16
|
+
fontSize: number;
|
|
17
|
+
fontWeight: number;
|
|
18
|
+
margin: number;
|
|
19
|
+
color: any;
|
|
20
|
+
};
|
|
21
|
+
section: {
|
|
22
|
+
marginBottom: number;
|
|
23
|
+
};
|
|
24
|
+
sectionTitle: {
|
|
25
|
+
fontSize: number;
|
|
26
|
+
fontWeight: number;
|
|
27
|
+
marginBottom: number;
|
|
28
|
+
color: any;
|
|
29
|
+
};
|
|
30
|
+
required: {
|
|
31
|
+
color: any;
|
|
32
|
+
marginLeft: number;
|
|
33
|
+
};
|
|
34
|
+
modeContainer: {
|
|
35
|
+
display: string;
|
|
36
|
+
flexDirection: "column";
|
|
37
|
+
gap: number;
|
|
38
|
+
};
|
|
39
|
+
modeOption: {
|
|
40
|
+
display: string;
|
|
41
|
+
alignItems: string;
|
|
42
|
+
gap: number;
|
|
43
|
+
padding: string;
|
|
44
|
+
border: string;
|
|
45
|
+
borderRadius: string;
|
|
46
|
+
cursor: string;
|
|
47
|
+
fontSize: number;
|
|
48
|
+
transition: string;
|
|
49
|
+
backgroundColor: any;
|
|
50
|
+
};
|
|
51
|
+
radioInput: {
|
|
52
|
+
width: number;
|
|
53
|
+
height: number;
|
|
54
|
+
accentColor: any;
|
|
55
|
+
};
|
|
56
|
+
chargeAmount: {
|
|
57
|
+
fontSize: number;
|
|
58
|
+
fontWeight: number;
|
|
59
|
+
color: any;
|
|
60
|
+
};
|
|
61
|
+
paymentOption: {
|
|
62
|
+
padding: string;
|
|
63
|
+
border: string;
|
|
64
|
+
borderRadius: string;
|
|
65
|
+
fontSize: number;
|
|
66
|
+
color: any;
|
|
67
|
+
backgroundColor: any;
|
|
68
|
+
};
|
|
69
|
+
dateSection: {
|
|
70
|
+
marginBottom: number;
|
|
71
|
+
padding: string;
|
|
72
|
+
backgroundColor: any;
|
|
73
|
+
borderRadius: string;
|
|
74
|
+
border: string;
|
|
75
|
+
};
|
|
76
|
+
dateSectionHeader: {
|
|
77
|
+
marginBottom: number;
|
|
78
|
+
};
|
|
79
|
+
dateSectionTitle: {
|
|
80
|
+
fontSize: number;
|
|
81
|
+
fontWeight: number;
|
|
82
|
+
color: any;
|
|
83
|
+
margin: number;
|
|
84
|
+
letterSpacing: string;
|
|
85
|
+
textTransform: "uppercase";
|
|
86
|
+
};
|
|
87
|
+
monthNavigationContainer: {
|
|
88
|
+
display: string;
|
|
89
|
+
alignItems: string;
|
|
90
|
+
justifyContent: string;
|
|
91
|
+
marginBottom: number;
|
|
92
|
+
position: "relative";
|
|
93
|
+
};
|
|
94
|
+
monthYearDisplay: {
|
|
95
|
+
fontSize: number;
|
|
96
|
+
fontWeight: number;
|
|
97
|
+
color: any;
|
|
98
|
+
textAlign: "center";
|
|
99
|
+
flex: number;
|
|
100
|
+
};
|
|
101
|
+
navButton: {
|
|
102
|
+
background: string;
|
|
103
|
+
border: string;
|
|
104
|
+
color: any;
|
|
105
|
+
cursor: string;
|
|
106
|
+
padding: number;
|
|
107
|
+
borderRadius: string;
|
|
108
|
+
display: string;
|
|
109
|
+
alignItems: string;
|
|
110
|
+
justifyContent: string;
|
|
111
|
+
transition: string;
|
|
112
|
+
minWidth: number;
|
|
113
|
+
minHeight: number;
|
|
114
|
+
flexShrink: number;
|
|
115
|
+
};
|
|
116
|
+
dateCardsContainer: {
|
|
117
|
+
display: string;
|
|
118
|
+
justifyContent: string;
|
|
119
|
+
alignItems: string;
|
|
120
|
+
gap: number;
|
|
121
|
+
width: string;
|
|
122
|
+
maxWidth: string;
|
|
123
|
+
overflow: string;
|
|
124
|
+
};
|
|
125
|
+
dateCard: {
|
|
126
|
+
width: number;
|
|
127
|
+
height: number;
|
|
128
|
+
border: string;
|
|
129
|
+
borderRadius: string;
|
|
130
|
+
display: string;
|
|
131
|
+
flexDirection: "column";
|
|
132
|
+
alignItems: string;
|
|
133
|
+
justifyContent: string;
|
|
134
|
+
cursor: string;
|
|
135
|
+
transition: string;
|
|
136
|
+
backgroundColor: any;
|
|
137
|
+
position: "relative";
|
|
138
|
+
flex: string;
|
|
139
|
+
};
|
|
140
|
+
dateCardSelected: {
|
|
141
|
+
borderColor: any;
|
|
142
|
+
backgroundColor: any;
|
|
143
|
+
color: any;
|
|
144
|
+
};
|
|
145
|
+
dateCardWeekday: {
|
|
146
|
+
fontSize: number;
|
|
147
|
+
fontWeight: number;
|
|
148
|
+
textTransform: "uppercase";
|
|
149
|
+
marginBottom: number;
|
|
150
|
+
letterSpacing: string;
|
|
151
|
+
lineHeight: number;
|
|
152
|
+
};
|
|
153
|
+
dateCardDay: {
|
|
154
|
+
fontSize: number;
|
|
155
|
+
fontWeight: number;
|
|
156
|
+
lineHeight: number;
|
|
157
|
+
};
|
|
158
|
+
slotsContainer: {
|
|
159
|
+
marginBottom: number;
|
|
160
|
+
width: string;
|
|
161
|
+
boxSizing: "border-box";
|
|
162
|
+
};
|
|
163
|
+
slotGrid: {
|
|
164
|
+
display: string;
|
|
165
|
+
gridTemplateColumns: string;
|
|
166
|
+
gap: number;
|
|
167
|
+
marginTop: number;
|
|
168
|
+
maxHeight: string;
|
|
169
|
+
overflowY: "auto";
|
|
170
|
+
paddingRight: string;
|
|
171
|
+
paddingBottom: string;
|
|
172
|
+
scrollbarWidth: "thin";
|
|
173
|
+
scrollbarColor: string;
|
|
174
|
+
width: string;
|
|
175
|
+
boxSizing: "border-box";
|
|
176
|
+
};
|
|
177
|
+
slotButton: {
|
|
178
|
+
padding: string;
|
|
179
|
+
border: string;
|
|
180
|
+
borderRadius: string;
|
|
181
|
+
backgroundColor: any;
|
|
182
|
+
color: any;
|
|
183
|
+
fontSize: number;
|
|
184
|
+
fontWeight: number;
|
|
185
|
+
cursor: string;
|
|
186
|
+
transition: string;
|
|
187
|
+
minHeight: number;
|
|
188
|
+
boxShadow: string;
|
|
189
|
+
position: "relative";
|
|
190
|
+
letterSpacing: string;
|
|
191
|
+
width: string;
|
|
192
|
+
boxSizing: "border-box";
|
|
193
|
+
textAlign: "center";
|
|
194
|
+
display: string;
|
|
195
|
+
alignItems: string;
|
|
196
|
+
justifyContent: string;
|
|
197
|
+
whiteSpace: "nowrap";
|
|
198
|
+
overflow: string;
|
|
199
|
+
textOverflow: string;
|
|
200
|
+
};
|
|
201
|
+
slotButtonSelected: {
|
|
202
|
+
borderColor: any;
|
|
203
|
+
backgroundColor: any;
|
|
204
|
+
color: any;
|
|
205
|
+
boxShadow: string;
|
|
206
|
+
transform: string;
|
|
207
|
+
};
|
|
208
|
+
noSlots: {
|
|
209
|
+
textAlign: "center";
|
|
210
|
+
color: any;
|
|
211
|
+
fontSize: number;
|
|
212
|
+
marginTop: number;
|
|
213
|
+
padding: string;
|
|
214
|
+
};
|
|
215
|
+
footer: {
|
|
216
|
+
display: string;
|
|
217
|
+
gap: number;
|
|
218
|
+
marginTop: string;
|
|
219
|
+
paddingTop: number;
|
|
220
|
+
borderTop: string;
|
|
221
|
+
};
|
|
222
|
+
backButton: {
|
|
223
|
+
flex: number;
|
|
224
|
+
padding: string;
|
|
225
|
+
border: string;
|
|
226
|
+
borderRadius: string;
|
|
227
|
+
backgroundColor: any;
|
|
228
|
+
color: any;
|
|
229
|
+
fontSize: number;
|
|
230
|
+
fontWeight: number;
|
|
231
|
+
cursor: string;
|
|
232
|
+
transition: string;
|
|
233
|
+
minHeight: number;
|
|
234
|
+
};
|
|
235
|
+
nextButton: {
|
|
236
|
+
flex: number;
|
|
237
|
+
padding: string;
|
|
238
|
+
border: string;
|
|
239
|
+
borderRadius: string;
|
|
240
|
+
backgroundColor: any;
|
|
241
|
+
color: any;
|
|
242
|
+
fontSize: number;
|
|
243
|
+
fontWeight: number;
|
|
244
|
+
cursor: string;
|
|
245
|
+
transition: string;
|
|
246
|
+
minHeight: number;
|
|
247
|
+
boxShadow: string;
|
|
248
|
+
};
|
|
249
|
+
};
|
|
250
|
+
export declare const getDesktopStyles: (theme: any, breakpoint: string) => {
|
|
251
|
+
modalWrapper: React.CSSProperties;
|
|
252
|
+
sectionCard: React.CSSProperties;
|
|
253
|
+
sectionHeader: React.CSSProperties;
|
|
254
|
+
sectionTitle: React.CSSProperties;
|
|
255
|
+
sectionBody: React.CSSProperties;
|
|
256
|
+
label: React.CSSProperties;
|
|
257
|
+
modeContainer: React.CSSProperties;
|
|
258
|
+
radioLabel: React.CSSProperties;
|
|
259
|
+
radioInput: React.CSSProperties;
|
|
260
|
+
rupee: React.CSSProperties;
|
|
261
|
+
dateTimeContainer: React.CSSProperties;
|
|
262
|
+
calendarBox: React.CSSProperties;
|
|
263
|
+
timesContainer: React.CSSProperties;
|
|
264
|
+
timesLabel: React.CSSProperties;
|
|
265
|
+
dateLabel: React.CSSProperties;
|
|
266
|
+
noSlots: React.CSSProperties;
|
|
267
|
+
slotGrid: React.CSSProperties;
|
|
268
|
+
slotButton: React.CSSProperties;
|
|
269
|
+
footer: React.CSSProperties;
|
|
270
|
+
backBtn: React.CSSProperties;
|
|
271
|
+
continueBtn: React.CSSProperties;
|
|
272
|
+
};
|