@infosoftas/s4-orders-js-sdk 0.1.19 → 0.1.21-0

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.
Files changed (62) hide show
  1. package/README.md +471 -426
  2. package/build/postcss-scope-tailwind.cjs +66 -0
  3. package/components.json +21 -0
  4. package/package.json +59 -43
  5. package/src/App.css +409 -0
  6. package/src/App.tsx +639 -569
  7. package/src/api/OrdersApi.ts +2 -2
  8. package/src/components/Alert/Alert.tsx +23 -22
  9. package/src/components/Button/Button.tsx +18 -22
  10. package/src/components/EHFForm/EHFForm.tsx +253 -235
  11. package/src/components/FormFields/AddressField.tsx +55 -62
  12. package/src/components/FormFields/EmailField.tsx +53 -58
  13. package/src/components/FormFields/InputField.tsx +52 -53
  14. package/src/components/FormFields/NameField.tsx +52 -53
  15. package/src/components/FormFields/PhoneField.tsx +53 -58
  16. package/src/components/FormFields/TermsCheckbox.tsx +70 -58
  17. package/src/components/FormFields/ToggleFiled.tsx +52 -63
  18. package/src/components/FormFields/fieldValidators.ts +71 -0
  19. package/src/components/OIOForm/OIOForm.tsx +132 -71
  20. package/src/components/OrderDenialModal/OrderDenialModal.tsx +102 -89
  21. package/src/components/OrderForm/ContactDetailsSection.tsx +71 -0
  22. package/src/components/OrderForm/OrderForm.tsx +177 -224
  23. package/src/components/OrderForm/PaymentMethodContent.tsx +62 -0
  24. package/src/components/OrderForm/PaymentMethodSection.tsx +79 -0
  25. package/src/components/OrderForm/SubmitConfirmationDialog.tsx +55 -0
  26. package/src/components/OrderForm/orderFormState.ts +171 -0
  27. package/src/components/OrderForm/useSlotElement.tsx +89 -0
  28. package/src/components/ui/alert-dialog.tsx +185 -0
  29. package/src/components/ui/alert.tsx +75 -0
  30. package/src/components/ui/button.tsx +55 -0
  31. package/src/components/ui/card.tsx +99 -0
  32. package/src/components/ui/checkbox.tsx +28 -0
  33. package/src/components/ui/field.tsx +238 -0
  34. package/src/components/ui/input.tsx +19 -0
  35. package/src/components/ui/label.tsx +19 -0
  36. package/src/components/ui/radio-group.tsx +37 -0
  37. package/src/components/ui/separator.tsx +24 -0
  38. package/src/components/ui/skeleton.tsx +13 -0
  39. package/src/components/ui/spinner.tsx +10 -0
  40. package/src/components/ui/switch.tsx +29 -0
  41. package/src/components/ui/textarea.tsx +17 -0
  42. package/src/constants/index.ts +0 -2
  43. package/src/custom.d.ts +4 -4
  44. package/src/enums/general.ts +1 -0
  45. package/src/hooks/useMessageEvent.tsx +54 -3
  46. package/src/hooks/useOrderForm.tsx +9 -2
  47. package/src/index.tsx +2 -0
  48. package/src/lib/utils.ts +1 -0
  49. package/src/types/general.ts +136 -111
  50. package/src/types/order.ts +8 -0
  51. package/src/utils/order.helper.ts +14 -3
  52. package/tsconfig.json +37 -38
  53. package/src/App.scss +0 -23
  54. package/src/assets/styles/forms.scss +0 -164
  55. package/src/assets/styles/general.scss +0 -46
  56. package/src/assets/styles/variables.scss +0 -29
  57. package/src/components/Alert/alert.scss +0 -21
  58. package/src/components/Button/button.scss +0 -48
  59. package/src/components/Loader/Loader.tsx +0 -22
  60. package/src/components/Loader/loader.scss +0 -37
  61. package/src/components/OrderDenialModal/orderDenialModal.scss +0 -42
  62. package/src/components/OrderForm/orderForm.scss +0 -10
@@ -19,8 +19,8 @@ type OrderCompleteRequestType = {
19
19
  };
20
20
 
21
21
  type OrderResponseType = {
22
- terminalRedirectUrl: string;
23
- id: string;
22
+ terminalRedirectUrl: string | null;
23
+ id: string | null;
24
24
  };
25
25
 
26
26
  export const orderStart = (
@@ -1,22 +1,23 @@
1
- import { FC } from 'react';
2
-
3
- import './alert.scss';
4
-
5
- type Props = {
6
- msg?: string;
7
- type?: 'danger' | 'success';
8
- className?: string;
9
- };
10
-
11
- const Alert: FC<Props> = ({ msg, type = 'danger', className = '' }) => {
12
- return msg ? (
13
- <div
14
- className={`sdk-alert ${type} ${className}`}
15
- data-testid="sdk-alert-id"
16
- >
17
- {msg}
18
- </div>
19
- ) : null;
20
- };
21
-
22
- export default Alert;
1
+ import { FC } from 'react';
2
+
3
+ import { Alert as UIAlert, AlertDescription } from '../ui/alert';
4
+
5
+ type Props = {
6
+ msg?: string;
7
+ type?: 'danger' | 'success';
8
+ className?: string;
9
+ };
10
+
11
+ const Alert: FC<Props> = ({ msg, type = 'danger', className }) => {
12
+ return msg ? (
13
+ <UIAlert
14
+ variant={type === 'danger' ? 'destructive' : 'default'}
15
+ className={className}
16
+ data-testid="sdk-alert-id"
17
+ >
18
+ <AlertDescription>{msg}</AlertDescription>
19
+ </UIAlert>
20
+ ) : null;
21
+ };
22
+
23
+ export default Alert;
@@ -1,8 +1,7 @@
1
1
  import { FC, MouseEvent } from 'react';
2
2
 
3
- import Loader from '../Loader/Loader';
4
-
5
- import './button.scss';
3
+ import { Button as UIButton } from '../ui/button';
4
+ import { Spinner } from '../ui/spinner';
6
5
 
7
6
  type Props = {
8
7
  onClick?: (e: MouseEvent<HTMLButtonElement>) => void;
@@ -11,6 +10,7 @@ type Props = {
11
10
  buttonText?: string;
12
11
  loading?: boolean;
13
12
  disable?: boolean;
13
+ className?: string;
14
14
  };
15
15
 
16
16
  const Button: FC<Props> = ({
@@ -20,24 +20,20 @@ const Button: FC<Props> = ({
20
20
  buttonText = 'Start',
21
21
  loading = false,
22
22
  disable = false,
23
- }) => {
24
- const handleClick = (e: MouseEvent<HTMLButtonElement>) => {
25
- onClick?.(e);
26
- };
27
-
28
- return (
29
- <button
30
- data-testid="sdk-button-id"
31
- type={type}
32
- disabled={loading || disable}
33
- className={`sdk-btn ${btnType ? `${btnType}-btn` : ''} ${
34
- loading ? 'loading' : ''
35
- } ${disable ? 'disabled' : ''}`}
36
- onClick={handleClick}
37
- >
38
- {loading ? <Loader className="btn-loader" /> : buttonText}
39
- </button>
40
- );
41
- };
23
+ className,
24
+ }) => (
25
+ <UIButton
26
+ data-testid="sdk-button-id"
27
+ type={type}
28
+ variant={btnType === 'primary' ? 'default' : 'ghost'}
29
+ disabled={loading || disable}
30
+ aria-busy={loading || undefined}
31
+ className={className}
32
+ onClick={onClick}
33
+ >
34
+ {loading && <Spinner data-icon="inline-start" />}
35
+ {buttonText}
36
+ </UIButton>
37
+ );
42
38
 
43
39
  export default Button;
@@ -1,235 +1,253 @@
1
- import { FC } from 'react';
2
- import { FormProvider, useForm, SubmitHandler } from 'react-hook-form';
3
-
4
- import Alert from '../Alert/Alert';
5
- import Button from '../Button/Button';
6
- import OrderDenialModal from '../OrderDenialModal/OrderDenialModal';
7
- import InputField from '../FormFields/InputField';
8
- import { PaymentMethodEnum, UserActionEnum } from '../../enums/general';
9
- import {
10
- OrderFormFieldType,
11
- PaymentMethodOptionsType,
12
- ContactRequestType,
13
- OrderDenialFallbackOfferType,
14
- } from '../../types/general';
15
- import { OrderFormInputsType, OrderInfoType } from '../../types/order';
16
- import { orderInvoiceContactFields } from '../../utils/order.helper';
17
- import useOrderForm from '../../hooks/useOrderForm';
18
- import { DEFAULT_ORDER_FORM_FIELDS } from '../FormFields/FormFields.helper';
19
-
20
- type Props = {
21
- callback: (url: string | null, orderInfo?: OrderInfoType | null) => void;
22
- onBack: () => void;
23
- submitStartCallback?: (id: string) => void;
24
- userActionCallback?: (
25
- action: UserActionEnum,
26
- args: object | null | undefined
27
- ) => void;
28
- setContactCallback?: (contactInfo: ContactRequestType) => void;
29
- className?: string;
30
- backButtonText?: string;
31
- verifyButtonText?: string;
32
- orderDenialCloseButtonText?: string;
33
- orderDenialContinueButtonText?: string;
34
- organizationNumberLabel?: string;
35
- organizationNumber?: string;
36
- glnLabel?: string;
37
- templatePackageId: string;
38
- subscriberId?: string;
39
- userId?: string;
40
- identityProviderId?: string;
41
- organizationId: string;
42
- redirectUrl?: string;
43
- showIframe?: boolean;
44
- language: string;
45
- merchantAgreementUrl: string;
46
- orderValues?: OrderFormInputsType;
47
- paymentMethodsOptions?: PaymentMethodOptionsType;
48
- invoiceAddressSelection?: {
49
- enabled?: boolean;
50
- label?: string;
51
- fields?: OrderFormFieldType[];
52
- paymentMethods?: PaymentMethodEnum[];
53
- };
54
- invoiceLookupNotFoundText?: string;
55
- errorValidationTitleMsg?: string;
56
- errorValidationDenialOrderBlockingMsg?: string;
57
- errorValidationBlockingOffersMsg?: string;
58
- orderDenialOfferBaseText?: string;
59
- orderDenialOfferWithFallbackText?: string;
60
- orderDenialAmountText?: string;
61
- fetchDenialFallbackOffer?: (organizationId: string) => Promise<OrderDenialFallbackOfferType | undefined>;
62
- };
63
-
64
- type EHFFormInputsType = {
65
- organizationNumber: string;
66
- };
67
-
68
- const initialData = {
69
- organizationNumber: '',
70
- };
71
-
72
- const EHFForm: FC<Props> = ({
73
- callback,
74
- onBack,
75
- submitStartCallback,
76
- userActionCallback,
77
- setContactCallback,
78
- className = '',
79
- backButtonText = '',
80
- verifyButtonText = '',
81
- orderDenialCloseButtonText = 'Close',
82
- orderDenialContinueButtonText = 'Continue',
83
- organizationNumberLabel = '',
84
- organizationNumber = '',
85
- templatePackageId,
86
- subscriberId,
87
- userId,
88
- identityProviderId,
89
- organizationId,
90
- redirectUrl,
91
- showIframe,
92
- language,
93
- merchantAgreementUrl,
94
- orderValues,
95
- paymentMethodsOptions,
96
- invoiceAddressSelection,
97
- invoiceLookupNotFoundText,
98
- errorValidationTitleMsg,
99
- errorValidationDenialOrderBlockingMsg,
100
- errorValidationBlockingOffersMsg,
101
- orderDenialOfferBaseText,
102
- orderDenialOfferWithFallbackText,
103
- orderDenialAmountText,
104
- fetchDenialFallbackOffer,
105
- }) => {
106
- const methods = useForm<EHFFormInputsType>({
107
- defaultValues: {
108
- ...initialData,
109
- organizationNumber,
110
- },
111
- });
112
-
113
- const {
114
- handleSubmit,
115
- formState: { errors },
116
- } = methods;
117
-
118
- const invoiceOrderFields =
119
- invoiceAddressSelection?.fields || orderInvoiceContactFields;
120
-
121
- const orderFields =
122
- paymentMethodsOptions?.[orderValues?.paymentMethod as PaymentMethodEnum]
123
- ?.orderFormFields ?? DEFAULT_ORDER_FORM_FIELDS;
124
-
125
- const {
126
- orderSubmit,
127
- continueWithFallbackOffer,
128
- loading,
129
- apiErrorMsg,
130
- errorsMsg,
131
- orderDenialType,
132
- orderDenialMessage,
133
- orderDenialFallbackOffer,
134
- dismissOrderDenial,
135
- } = useOrderForm({
136
- callback,
137
- submitStartCallback,
138
- userActionCallback,
139
- setContactCallback,
140
- organizationId,
141
- subscriberId,
142
- userId,
143
- identityProviderId,
144
- orderFields,
145
- redirectUrl,
146
- showIframe,
147
- language,
148
- merchantAgreementUrl,
149
- paymentMethodsOptions,
150
- templatePackageId,
151
- invoiceAddressToggle: orderValues?.invoiceAddressSelection,
152
- invoiceOrderFields,
153
- invoiceLookupNotFoundText,
154
- errorValidationTitleMsg,
155
- errorValidationDenialOrderBlockingMsg,
156
- errorValidationBlockingOffersMsg,
157
- orderDenialOfferBaseText,
158
- orderDenialOfferWithFallbackText,
159
- orderDenialAmountText,
160
- fetchDenialFallbackOffer,
161
- });
162
-
163
- const onSubmit: SubmitHandler<EHFFormInputsType> = async (
164
- data
165
- ): Promise<void> => {
166
- orderSubmit({
167
- ...orderValues,
168
- organizationNumber: data.organizationNumber,
169
- });
170
- };
171
-
172
- const handleBack = () => {
173
- userActionCallback?.(UserActionEnum.RETURN_TO_MAIN, null);
174
- onBack?.();
175
- };
176
-
177
- return (
178
- <FormProvider {...methods}>
179
- <form
180
- className={`${className}`}
181
- onSubmit={handleSubmit(onSubmit)}
182
- data-testid="ehf-form-id"
183
- >
184
- <InputField
185
- name="organizationNumber"
186
- label={organizationNumberLabel}
187
- required
188
- readOnly={false}
189
- errors={errors}
190
- />
191
- <div className="d-flex justify-center flex-wrap gap-2">
192
- <Button
193
- type="button"
194
- btnType="default"
195
- disable={loading}
196
- buttonText={backButtonText}
197
- onClick={handleBack}
198
- />
199
-
200
- <Button
201
- type="submit"
202
- loading={loading}
203
- buttonText={verifyButtonText}
204
- />
205
- </div>
206
-
207
- {apiErrorMsg && <Alert className="mt-2" msg={apiErrorMsg} />}
208
- {errorsMsg?.length > 0 &&
209
- errorsMsg.map((i, index) => (
210
- <Alert key={index} className="mt-2" msg={i} />
211
- ))}
212
- <OrderDenialModal
213
- isOpen={!!orderDenialType}
214
- message={orderDenialMessage}
215
- closeButtonText={orderDenialCloseButtonText}
216
- continueButtonText={orderDenialContinueButtonText}
217
- canContinue={
218
- orderDenialType === 'offer' &&
219
- !!orderDenialFallbackOffer?.templatePackageId
220
- }
221
- offer={
222
- orderDenialType === 'offer' &&
223
- !!orderDenialFallbackOffer?.templatePackageId
224
- ? orderDenialFallbackOffer
225
- : undefined
226
- }
227
- onClose={dismissOrderDenial}
228
- onContinue={continueWithFallbackOffer}
229
- />
230
- </form>
231
- </FormProvider>
232
- );
233
- };
234
-
235
- export default EHFForm;
1
+ import { FC, useMemo } from 'react';
2
+ import { FormProvider, useForm, SubmitHandler } from 'react-hook-form';
3
+ import { zodResolver } from '@hookform/resolvers/zod';
4
+ import z from 'zod';
5
+
6
+ import Alert from '../Alert/Alert';
7
+ import Button from '../Button/Button';
8
+ import OrderDenialModal from '../OrderDenialModal/OrderDenialModal';
9
+ import InputField from '../FormFields/InputField';
10
+ import { FieldGroup } from '../ui/field';
11
+ import { PaymentMethodEnum, UserActionEnum } from '../../enums/general';
12
+ import {
13
+ OrderFormFieldType,
14
+ PaymentMethodSettingsType,
15
+ ContactRequestType,
16
+ OrderDenialFallbackOfferType,
17
+ } from '../../types/general';
18
+ import { OrderFormInputsType, OrderInfoType } from '../../types/order';
19
+ import { orderInvoiceContactFields } from '../../utils/order.helper';
20
+ import useOrderForm from '../../hooks/useOrderForm';
21
+ import { DEFAULT_ORDER_FORM_FIELDS } from '../FormFields/FormFields.helper';
22
+
23
+ type Props = {
24
+ callback: (url: string | null, orderInfo?: OrderInfoType | null) => void;
25
+ onBack: () => void;
26
+ submitStartCallback?: (id: string) => void;
27
+ userActionCallback?: (
28
+ action: UserActionEnum,
29
+ args: object | null | undefined
30
+ ) => void;
31
+ setContactCallback?: (contactInfo: ContactRequestType) => void;
32
+ className?: string;
33
+ backButtonText?: string;
34
+ verifyButtonText?: string;
35
+ orderDenialCloseButtonText?: string;
36
+ orderDenialContinueButtonText?: string;
37
+ organizationNumberLabel?: string;
38
+ organizationNumber?: string;
39
+ glnLabel?: string;
40
+ templatePackageId: string;
41
+ subscriberId?: string;
42
+ userId?: string;
43
+ identityProviderId?: string;
44
+ organizationId: string;
45
+ redirectUrl?: string;
46
+ showIframe?: boolean;
47
+ language: string;
48
+ merchantAgreementUrl: string;
49
+ orderValues?: OrderFormInputsType;
50
+ paymentMethodsOptions?: PaymentMethodSettingsType;
51
+ invoiceAddressSelection?: {
52
+ enabled?: boolean;
53
+ label?: string;
54
+ fields?: OrderFormFieldType[];
55
+ paymentMethods?: PaymentMethodEnum[];
56
+ };
57
+ invoiceLookupNotFoundText?: string;
58
+ errorReqMsg?: string;
59
+ errorValidationTitleMsg?: string;
60
+ errorValidationDenialOrderBlockingMsg?: string;
61
+ errorValidationBlockingOffersMsg?: string;
62
+ orderDenialOfferBaseText?: string;
63
+ orderDenialOfferWithFallbackText?: string;
64
+ orderDenialAmountText?: string;
65
+ fetchDenialFallbackOffer?: (
66
+ organizationId: string
67
+ ) => Promise<OrderDenialFallbackOfferType | undefined>;
68
+ };
69
+
70
+ const buildFormSchema = (errorReqMsg?: string) => {
71
+ const message = errorReqMsg || 'This field is required!';
72
+
73
+ return z.object({
74
+ organizationNumber: z.string().min(1, message).regex(/\S/, message),
75
+ });
76
+ };
77
+
78
+ type EHFFormInputsType = { organizationNumber: string };
79
+
80
+ const initialData = {
81
+ organizationNumber: '',
82
+ };
83
+
84
+ const EHFForm: FC<Props> = ({
85
+ callback,
86
+ onBack,
87
+ submitStartCallback,
88
+ userActionCallback,
89
+ setContactCallback,
90
+ className = '',
91
+ backButtonText = '',
92
+ verifyButtonText = '',
93
+ orderDenialCloseButtonText = 'Close',
94
+ orderDenialContinueButtonText = 'Continue',
95
+ organizationNumberLabel = '',
96
+ organizationNumber = '',
97
+ templatePackageId,
98
+ subscriberId,
99
+ userId,
100
+ identityProviderId,
101
+ organizationId,
102
+ redirectUrl,
103
+ showIframe,
104
+ language,
105
+ merchantAgreementUrl,
106
+ orderValues,
107
+ paymentMethodsOptions,
108
+ invoiceAddressSelection,
109
+ invoiceLookupNotFoundText,
110
+ errorReqMsg,
111
+ errorValidationTitleMsg,
112
+ errorValidationDenialOrderBlockingMsg,
113
+ errorValidationBlockingOffersMsg,
114
+ orderDenialOfferBaseText,
115
+ orderDenialOfferWithFallbackText,
116
+ orderDenialAmountText,
117
+ fetchDenialFallbackOffer,
118
+ }) => {
119
+ const formSchema = useMemo(
120
+ () => buildFormSchema(errorReqMsg),
121
+ [errorReqMsg]
122
+ );
123
+
124
+ const methods = useForm<EHFFormInputsType>({
125
+ resolver: zodResolver(formSchema),
126
+ defaultValues: {
127
+ ...initialData,
128
+ organizationNumber,
129
+ },
130
+ });
131
+
132
+ const { handleSubmit } = methods;
133
+
134
+ const invoiceOrderFields =
135
+ invoiceAddressSelection?.fields || orderInvoiceContactFields;
136
+
137
+ const orderFields =
138
+ paymentMethodsOptions?.[orderValues?.paymentMethod as PaymentMethodEnum]
139
+ ?.orderFormFields ?? DEFAULT_ORDER_FORM_FIELDS;
140
+
141
+ const {
142
+ orderSubmit,
143
+ continueWithFallbackOffer,
144
+ loading,
145
+ apiErrorMsg,
146
+ errorsMsg,
147
+ orderDenialType,
148
+ orderDenialMessage,
149
+ orderDenialFallbackOffer,
150
+ dismissOrderDenial,
151
+ } = useOrderForm({
152
+ callback,
153
+ submitStartCallback,
154
+ userActionCallback,
155
+ setContactCallback,
156
+ organizationId,
157
+ subscriberId,
158
+ userId,
159
+ identityProviderId,
160
+ orderFields,
161
+ redirectUrl,
162
+ showIframe,
163
+ language,
164
+ merchantAgreementUrl,
165
+ paymentMethodsOptions,
166
+ templatePackageId,
167
+ invoiceAddressToggle: orderValues?.invoiceAddressSelection,
168
+ invoiceOrderFields,
169
+ invoiceLookupNotFoundText,
170
+ errorValidationTitleMsg,
171
+ errorValidationDenialOrderBlockingMsg,
172
+ errorValidationBlockingOffersMsg,
173
+ orderDenialOfferBaseText,
174
+ orderDenialOfferWithFallbackText,
175
+ orderDenialAmountText,
176
+ fetchDenialFallbackOffer,
177
+ });
178
+
179
+ const onSubmit: SubmitHandler<EHFFormInputsType> = async (
180
+ data
181
+ ): Promise<void> => {
182
+ orderSubmit({
183
+ ...orderValues,
184
+ organizationNumber: data.organizationNumber,
185
+ });
186
+ };
187
+
188
+ const handleBack = () => {
189
+ userActionCallback?.(UserActionEnum.RETURN_TO_MAIN, null);
190
+ onBack?.();
191
+ };
192
+
193
+ return (
194
+ <FormProvider {...methods}>
195
+ <form
196
+ className={`${className}`}
197
+ noValidate
198
+ onSubmit={handleSubmit(onSubmit)}
199
+ data-testid="ehf-form-id"
200
+ >
201
+ <FieldGroup className="mb-5">
202
+ <InputField
203
+ name="organizationNumber"
204
+ label={organizationNumberLabel}
205
+ required
206
+ readOnly={false}
207
+ />
208
+ </FieldGroup>
209
+ <div className="flex justify-center flex-wrap gap-2">
210
+ <Button
211
+ type="button"
212
+ btnType="default"
213
+ disable={loading}
214
+ buttonText={backButtonText}
215
+ onClick={handleBack}
216
+ />
217
+
218
+ <Button
219
+ type="submit"
220
+ loading={loading}
221
+ buttonText={verifyButtonText}
222
+ />
223
+ </div>
224
+
225
+ {apiErrorMsg && <Alert className="mt-2" msg={apiErrorMsg} />}
226
+ {errorsMsg?.length > 0 &&
227
+ errorsMsg.map((i, index) => (
228
+ <Alert key={index} className="mt-2" msg={i} />
229
+ ))}
230
+ <OrderDenialModal
231
+ isOpen={!!orderDenialType}
232
+ message={orderDenialMessage}
233
+ closeButtonText={orderDenialCloseButtonText}
234
+ continueButtonText={orderDenialContinueButtonText}
235
+ canContinue={
236
+ orderDenialType === 'offer' &&
237
+ !!orderDenialFallbackOffer?.templatePackageId
238
+ }
239
+ offer={
240
+ orderDenialType === 'offer' &&
241
+ !!orderDenialFallbackOffer?.templatePackageId
242
+ ? orderDenialFallbackOffer
243
+ : undefined
244
+ }
245
+ onClose={dismissOrderDenial}
246
+ onContinue={continueWithFallbackOffer}
247
+ />
248
+ </form>
249
+ </FormProvider>
250
+ );
251
+ };
252
+
253
+ export default EHFForm;