@mychoice/mychoice-sdk-store 2.2.11 → 2.2.14

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.
@@ -1,3 +1,6 @@
1
1
  import { FormCarConfigHookInterface, ProvinceHookInterface } from './interfaces';
2
2
  export declare const useStoreFormCarConfig: () => FormCarConfigHookInterface;
3
3
  export declare const useProvince: () => ProvinceHookInterface;
4
+ export declare const useAbReform: () => {
5
+ isAbReformActive: boolean;
6
+ };
@@ -6,6 +6,7 @@ export interface DiscountQuoterInfoInterface {
6
6
  lastName: string;
7
7
  phone: string;
8
8
  recalculate: boolean;
9
+ accidentBenefitsChanged?: boolean;
9
10
  utmSource?: string;
10
11
  utmCampaign?: string;
11
12
  brokerInfo?: {
@@ -30,5 +30,9 @@ export declare enum StoreFormCarVehicleActionTypes {
30
30
  FormCarVehicleValidateSet = "FormCarVehicleValidateSet",
31
31
  FormCarLossOfUseCoverageSelect = "FormCarLossOfUseCoverageSelect",
32
32
  FormCarLiabilityForDamageCoverageSelect = "FormCarLiabilityForDamageCoverageSelect",
33
- FormCarLimitedWaiverOfDepreciationCoverageSelect = "FormCarLimitedWaiverOfDepreciationCoverageSelect"
33
+ FormCarLimitedWaiverOfDepreciationCoverageSelect = "FormCarLimitedWaiverOfDepreciationCoverageSelect",
34
+ FormCarAccidentBenefitsBaseCoverageSelect = "FormCarAccidentBenefitsBaseCoverageSelect",
35
+ FormCarAccidentBenefitsAdditionalCoveragesSet = "FormCarAccidentBenefitsAdditionalCoveragesSet",
36
+ FormCarAccidentBenefitsAdditionalCoverageRemove = "FormCarAccidentBenefitsAdditionalCoverageRemove",
37
+ FormCarAccidentBenefitsAcknowledge = "FormCarAccidentBenefitsAcknowledge"
34
38
  }
@@ -1,10 +1,10 @@
1
1
  import { VehicleConditionTypes } from '@mychoice/mychoice-sdk-components';
2
- import { FormCarVehicleStateInterface } from './interfaces';
2
+ import { VehicleAccidentBenefitsInterface, FormCarVehicleStateInterface } from './interfaces';
3
3
  export declare const removeVehicleItem: (state: FormCarVehicleStateInterface, vehicleIndex: number) => FormCarVehicleStateInterface;
4
4
  export declare const createVehicleItem: (state: FormCarVehicleStateInterface) => FormCarVehicleStateInterface;
5
5
  export declare const setVehicleProperty: (state: FormCarVehicleStateInterface, name: string, value: boolean) => FormCarVehicleStateInterface;
6
6
  export declare const setVehicleYear: (state: FormCarVehicleStateInterface, vehicleYear: string) => FormCarVehicleStateInterface;
7
7
  export declare const setVehicleMake: (state: FormCarVehicleStateInterface, vehicleMake: string) => FormCarVehicleStateInterface;
8
8
  export declare const setVehicleModel: (state: FormCarVehicleStateInterface, vehicleModel: string) => FormCarVehicleStateInterface;
9
- export declare const setItemProperty: (state: FormCarVehicleStateInterface, name: string, value: string | boolean | VehicleConditionTypes) => FormCarVehicleStateInterface;
9
+ export declare const setItemProperty: (state: FormCarVehicleStateInterface, name: string, value: string | string[] | boolean | VehicleConditionTypes | VehicleAccidentBenefitsInterface) => FormCarVehicleStateInterface;
10
10
  export declare const setCarCoverageProperty: (state: FormCarVehicleStateInterface, name: string, coverage: boolean, value: number) => FormCarVehicleStateInterface;
@@ -23,5 +23,10 @@ export declare const limitedWaiverOfDepreciationInitialState: {
23
23
  coverage: boolean;
24
24
  limit: number;
25
25
  };
26
+ export declare const vehicleAccidentBenefitsInitialState: {
27
+ baseCoverage: string;
28
+ additionalCoverages: never[];
29
+ abAcknowledged: boolean;
30
+ };
26
31
  export declare const vehicleItemInitialState: VehicleItemInterface;
27
32
  export declare const carFormVehicleInitialState: FormCarVehicleStateInterface;
@@ -25,6 +25,11 @@ export interface VehicleLimitedWaiverOfDepreciationInterface {
25
25
  coverage: boolean;
26
26
  limit: number;
27
27
  }
28
+ export interface VehicleAccidentBenefitsInterface {
29
+ baseCoverage: string;
30
+ additionalCoverages: string[];
31
+ abAcknowledged?: boolean;
32
+ }
28
33
  export interface VehicleItemInterface {
29
34
  year: string | undefined;
30
35
  make: string | undefined;
@@ -46,6 +51,7 @@ export interface VehicleItemInterface {
46
51
  lossofuse: VehicleLossOfUseInterface;
47
52
  liabilityfordamage: VehicleLiabilityForDamageInterface;
48
53
  limitedwaiverofdepreciation: VehicleLimitedWaiverOfDepreciationInterface;
54
+ accidentbenefits: VehicleAccidentBenefitsInterface;
49
55
  postalCode: string;
50
56
  locationIndex: string;
51
57
  city: string;
@@ -224,6 +230,28 @@ export type FormCarVehicleStateActionType = {
224
230
  limit: number;
225
231
  };
226
232
  localIndex?: string;
233
+ } | {
234
+ type: StoreFormCarVehicleActionTypes.FormCarAccidentBenefitsBaseCoverageSelect;
235
+ payload: {
236
+ baseCoverage: string;
237
+ };
238
+ localIndex?: string;
239
+ } | {
240
+ type: StoreFormCarVehicleActionTypes.FormCarAccidentBenefitsAdditionalCoveragesSet;
241
+ payload: {
242
+ additionalCoverages: string[];
243
+ };
244
+ localIndex?: string;
245
+ } | {
246
+ type: StoreFormCarVehicleActionTypes.FormCarAccidentBenefitsAdditionalCoverageRemove;
247
+ payload: {
248
+ coverageValue: string;
249
+ };
250
+ localIndex?: string;
251
+ } | {
252
+ type: StoreFormCarVehicleActionTypes.FormCarAccidentBenefitsAcknowledge;
253
+ payload?: null;
254
+ localIndex?: string;
227
255
  };
228
256
  export type FormCarVehicleStateReducerInterface = (state: FormCarVehicleStateInterface, action: FormCarVehicleStateActionType) => void;
229
257
  export interface ClientHookInterface {
package/dist/index.d.ts CHANGED
@@ -312,7 +312,11 @@ declare enum StoreFormCarVehicleActionTypes {
312
312
  FormCarVehicleValidateSet = "FormCarVehicleValidateSet",
313
313
  FormCarLossOfUseCoverageSelect = "FormCarLossOfUseCoverageSelect",
314
314
  FormCarLiabilityForDamageCoverageSelect = "FormCarLiabilityForDamageCoverageSelect",
315
- FormCarLimitedWaiverOfDepreciationCoverageSelect = "FormCarLimitedWaiverOfDepreciationCoverageSelect"
315
+ FormCarLimitedWaiverOfDepreciationCoverageSelect = "FormCarLimitedWaiverOfDepreciationCoverageSelect",
316
+ FormCarAccidentBenefitsBaseCoverageSelect = "FormCarAccidentBenefitsBaseCoverageSelect",
317
+ FormCarAccidentBenefitsAdditionalCoveragesSet = "FormCarAccidentBenefitsAdditionalCoveragesSet",
318
+ FormCarAccidentBenefitsAdditionalCoverageRemove = "FormCarAccidentBenefitsAdditionalCoverageRemove",
319
+ FormCarAccidentBenefitsAcknowledge = "FormCarAccidentBenefitsAcknowledge"
316
320
  }
317
321
 
318
322
  interface PostalStateSharedInterface {
@@ -360,6 +364,11 @@ interface VehicleLimitedWaiverOfDepreciationInterface {
360
364
  coverage: boolean;
361
365
  limit: number;
362
366
  }
367
+ interface VehicleAccidentBenefitsInterface {
368
+ baseCoverage: string;
369
+ additionalCoverages: string[];
370
+ abAcknowledged?: boolean;
371
+ }
363
372
  interface VehicleItemInterface {
364
373
  year: string | undefined;
365
374
  make: string | undefined;
@@ -381,6 +390,7 @@ interface VehicleItemInterface {
381
390
  lossofuse: VehicleLossOfUseInterface;
382
391
  liabilityfordamage: VehicleLiabilityForDamageInterface;
383
392
  limitedwaiverofdepreciation: VehicleLimitedWaiverOfDepreciationInterface;
393
+ accidentbenefits: VehicleAccidentBenefitsInterface;
384
394
  postalCode: string;
385
395
  locationIndex: string;
386
396
  city: string;
@@ -559,6 +569,28 @@ type FormCarVehicleStateActionType = {
559
569
  limit: number;
560
570
  };
561
571
  localIndex?: string;
572
+ } | {
573
+ type: StoreFormCarVehicleActionTypes.FormCarAccidentBenefitsBaseCoverageSelect;
574
+ payload: {
575
+ baseCoverage: string;
576
+ };
577
+ localIndex?: string;
578
+ } | {
579
+ type: StoreFormCarVehicleActionTypes.FormCarAccidentBenefitsAdditionalCoveragesSet;
580
+ payload: {
581
+ additionalCoverages: string[];
582
+ };
583
+ localIndex?: string;
584
+ } | {
585
+ type: StoreFormCarVehicleActionTypes.FormCarAccidentBenefitsAdditionalCoverageRemove;
586
+ payload: {
587
+ coverageValue: string;
588
+ };
589
+ localIndex?: string;
590
+ } | {
591
+ type: StoreFormCarVehicleActionTypes.FormCarAccidentBenefitsAcknowledge;
592
+ payload?: null;
593
+ localIndex?: string;
562
594
  };
563
595
  interface FormCarVehicleHookInterface {
564
596
  vehicleState: FormCarVehicleStateInterface;
@@ -1286,6 +1318,7 @@ interface DiscountQuoterInfoInterface {
1286
1318
  lastName: string;
1287
1319
  phone: string;
1288
1320
  recalculate: boolean;
1321
+ accidentBenefitsChanged?: boolean;
1289
1322
  utmSource?: string;
1290
1323
  utmCampaign?: string;
1291
1324
  brokerInfo?: {
@@ -1504,6 +1537,9 @@ declare const useStoreFormCarPostal: () => FormCarPostalHookInterface;
1504
1537
 
1505
1538
  declare const useStoreFormCarConfig: () => FormCarConfigHookInterface;
1506
1539
  declare const useProvince: () => ProvinceHookInterface;
1540
+ declare const useAbReform: () => {
1541
+ isAbReformActive: boolean;
1542
+ };
1507
1543
 
1508
1544
  declare enum StoreFormCarQuoteActionTypes {
1509
1545
  UpdateCarQuoteResponse = "UpdateCarQuoteResponse",
@@ -3296,4 +3332,4 @@ interface AutofillOptions {
3296
3332
  */
3297
3333
  declare const useAutofillLifeForm: (options?: AutofillOptions) => void;
3298
3334
 
3299
- export { AccidentItemInterface, AppConfigStateInterface, AppLoaderStateInterface, AppModalStateInterface, ApplicantCancellationItemInterface, ApplicantClaimItemInterface, ApplicantInsuredInterface, AutofillData, AutofillDriver, AutofillVehLink, AutofillVehicle, AutofillVehicleCoverage, BirthDatePayloadType, CarBrokerIntegrationInterface, CarBrokerTypeEnum, CarQuoteCoverageInterface, CarQuoteDataHandler, CarQuoteItemInterface, ClearFormDataHandler, ClientStateInterface, DiscountQuoterInfoInterface, DiscountVehLinkInterface, DriverCancellationItemInterface, DriverItemInterface, DriverLicenceInterface, DriverMinMaxDates, FormCarConfigStateInterface, FormCarDiscountStateInterface, FormCarDriverStateInterface, FormCarPostalStateInterface, FormCarQuoteStateInterface, FormCarQuoteStateReducerInterface, FormCarVehicleStateInterface, FormHomeApplicantStateInterface, FormHomeDiscountStateInterface, FormHomeDwellingStateInterface, FormHomePostalStateInterface, FormHomeQuoteStateInterface, FormHomeQuoteStateReducerInterface, FormLifeApplicantStateInterface, FormLifeCoverageStateInterface, FormLifePostalStateInterface, FormLifeQuoteStateInterface, FormLifeQuoteStateReducerInterface, HomeBrokerIntegrationInterface, HomeBrokerTypeEnum, HomeQuoteDataHandler, HomeQuoteItemInterface, LicenceAgePayloadType, LicenceConfigInterface, LifeAutofillData, LifeAutofillQuoterInfo, LifeBrokerIntegrationInterface, LifeQuoteDataHandler, LifeQuoteItemInterface, MappedAutofillData, PartnerStateInterface, ProvinceHookInterface, QuoterInfoInterface, StoreClientActionTypes, StoreConfigAppConfigActionTypes, StoreConfigAppDeviceActionTypes, StoreConfigAppLoaderActionTypes, StoreConfigAppModalActionTypes, StoreFormCarConfigActionTypes, StoreFormCarDiscountActionTypes, StoreFormCarDriverAccidentActionTypes, StoreFormCarDriverBaseActionTypes, StoreFormCarDriverCancellationActionTypes, StoreFormCarDriverInfoActionTypes, StoreFormCarDriverInsuranceActionTypes, StoreFormCarDriverLicenceActionTypes, StoreFormCarDriverSuspensionActionTypes, StoreFormCarDriverTicketActionTypes, StoreFormCarPostalActionTypes, StoreFormCarQuoteActionTypes, StoreFormCarVehicleActionTypes, StoreFormHomeApplicantBaseActionTypes, StoreFormHomeApplicantCancellationActionTypes, StoreFormHomeApplicantClaimActionTypes, StoreFormHomeApplicantInfoActionTypes, StoreFormHomeApplicantInsuranceActionTypes, StoreFormHomeDiscountActionTypes, StoreFormHomeDwellingActionTypes, StoreFormHomePostalActionTypes, StoreFormHomeQuoteActionTypes, StoreFormLifeApplicantActionTypes, StoreFormLifeCoverageActionTypes, StoreFormLifePostalActionTypes, StoreFormLifeQuoteActionTypes, StorePartnerActionTypes, StoreProvider, SuspensionItemInterface, TicketItemInterface, addDayToDate, configStateReducer, differenceInHoursFromNow, formCarReducer, formCondoDwellingInitialState, formHomeDwellingInitialState, formHomeReducer, formLifeReducer, formTenantDwellingInitialState, getDwellingInitialState, getProvinceCodeFromState, getProvinceName, globalStateReducer, initHttpResponse, mapToConfigState, mapToDriverState, mapToLifeApplicantState, mapToLifeCoverageState, mapToLifePostalState, mapToPostalState, mapToVehicleState, parseAutofillParam, parseLifeAutofillParam, reducers, export_default as token, useAutofillCarForm, useAutofillLifeForm, useHandlerAuth, useHandlerCarMake, useHandlerCarModel, useHandlerCarQuoterEmail, useHandlerHomeQuoterEmail, useHandlerLifeQuoterEmail, useHandlerPartner, useHandlerPostal, useProvince, useStoreAppConfig, useStoreAppDevice, useStoreAppLoader, useStoreAppModal, useStoreClient, useStoreClientLoggedIn, useStoreClientProfile, useStoreClientToken, useStoreDeviceBP, useStoreDeviceType, useStoreFormCarConfig, useStoreFormCarDiscount, useStoreFormCarDriverAccident, useStoreFormCarDriverBase, useStoreFormCarDriverCancellation, useStoreFormCarDriverInfo, useStoreFormCarDriverInsurance, useStoreFormCarDriverLicence, useStoreFormCarDriverSuspension, useStoreFormCarDriverTicket, useStoreFormCarPostal, useStoreFormCarQuote, useStoreFormCarVehicle, useStoreFormHomeApplicantBase, useStoreFormHomeApplicantCancellation, useStoreFormHomeApplicantClaim, useStoreFormHomeApplicantInfo, useStoreFormHomeApplicantInsurance, useStoreFormHomeDiscount, useStoreFormHomeDwelling, useStoreFormHomePostal, useStoreFormHomeQuote, useStoreFormLifeApplicant, useStoreFormLifeCoverage, useStoreFormLifePostal, useStoreFormLifeQuote, useStorePartner, useValidationAddress, useValidationApplicant, useValidationCarDiscount, useValidationCoverage, useValidationDriver, useValidationDwelling, useValidationHomeDiscount, useValidationLifeApplicant, useValidationVehicle };
3335
+ export { AccidentItemInterface, AppConfigStateInterface, AppLoaderStateInterface, AppModalStateInterface, ApplicantCancellationItemInterface, ApplicantClaimItemInterface, ApplicantInsuredInterface, AutofillData, AutofillDriver, AutofillVehLink, AutofillVehicle, AutofillVehicleCoverage, BirthDatePayloadType, CarBrokerIntegrationInterface, CarBrokerTypeEnum, CarQuoteCoverageInterface, CarQuoteDataHandler, CarQuoteItemInterface, ClearFormDataHandler, ClientStateInterface, DiscountQuoterInfoInterface, DiscountVehLinkInterface, DriverCancellationItemInterface, DriverItemInterface, DriverLicenceInterface, DriverMinMaxDates, FormCarConfigStateInterface, FormCarDiscountStateInterface, FormCarDriverStateInterface, FormCarPostalStateInterface, FormCarQuoteStateInterface, FormCarQuoteStateReducerInterface, FormCarVehicleStateInterface, FormHomeApplicantStateInterface, FormHomeDiscountStateInterface, FormHomeDwellingStateInterface, FormHomePostalStateInterface, FormHomeQuoteStateInterface, FormHomeQuoteStateReducerInterface, FormLifeApplicantStateInterface, FormLifeCoverageStateInterface, FormLifePostalStateInterface, FormLifeQuoteStateInterface, FormLifeQuoteStateReducerInterface, HomeBrokerIntegrationInterface, HomeBrokerTypeEnum, HomeQuoteDataHandler, HomeQuoteItemInterface, LicenceAgePayloadType, LicenceConfigInterface, LifeAutofillData, LifeAutofillQuoterInfo, LifeBrokerIntegrationInterface, LifeQuoteDataHandler, LifeQuoteItemInterface, MappedAutofillData, PartnerStateInterface, ProvinceHookInterface, QuoterInfoInterface, StoreClientActionTypes, StoreConfigAppConfigActionTypes, StoreConfigAppDeviceActionTypes, StoreConfigAppLoaderActionTypes, StoreConfigAppModalActionTypes, StoreFormCarConfigActionTypes, StoreFormCarDiscountActionTypes, StoreFormCarDriverAccidentActionTypes, StoreFormCarDriverBaseActionTypes, StoreFormCarDriverCancellationActionTypes, StoreFormCarDriverInfoActionTypes, StoreFormCarDriverInsuranceActionTypes, StoreFormCarDriverLicenceActionTypes, StoreFormCarDriverSuspensionActionTypes, StoreFormCarDriverTicketActionTypes, StoreFormCarPostalActionTypes, StoreFormCarQuoteActionTypes, StoreFormCarVehicleActionTypes, StoreFormHomeApplicantBaseActionTypes, StoreFormHomeApplicantCancellationActionTypes, StoreFormHomeApplicantClaimActionTypes, StoreFormHomeApplicantInfoActionTypes, StoreFormHomeApplicantInsuranceActionTypes, StoreFormHomeDiscountActionTypes, StoreFormHomeDwellingActionTypes, StoreFormHomePostalActionTypes, StoreFormHomeQuoteActionTypes, StoreFormLifeApplicantActionTypes, StoreFormLifeCoverageActionTypes, StoreFormLifePostalActionTypes, StoreFormLifeQuoteActionTypes, StorePartnerActionTypes, StoreProvider, SuspensionItemInterface, TicketItemInterface, addDayToDate, configStateReducer, differenceInHoursFromNow, formCarReducer, formCondoDwellingInitialState, formHomeDwellingInitialState, formHomeReducer, formLifeReducer, formTenantDwellingInitialState, getDwellingInitialState, getProvinceCodeFromState, getProvinceName, globalStateReducer, initHttpResponse, mapToConfigState, mapToDriverState, mapToLifeApplicantState, mapToLifeCoverageState, mapToLifePostalState, mapToPostalState, mapToVehicleState, parseAutofillParam, parseLifeAutofillParam, reducers, export_default as token, useAbReform, useAutofillCarForm, useAutofillLifeForm, useHandlerAuth, useHandlerCarMake, useHandlerCarModel, useHandlerCarQuoterEmail, useHandlerHomeQuoterEmail, useHandlerLifeQuoterEmail, useHandlerPartner, useHandlerPostal, useProvince, useStoreAppConfig, useStoreAppDevice, useStoreAppLoader, useStoreAppModal, useStoreClient, useStoreClientLoggedIn, useStoreClientProfile, useStoreClientToken, useStoreDeviceBP, useStoreDeviceType, useStoreFormCarConfig, useStoreFormCarDiscount, useStoreFormCarDriverAccident, useStoreFormCarDriverBase, useStoreFormCarDriverCancellation, useStoreFormCarDriverInfo, useStoreFormCarDriverInsurance, useStoreFormCarDriverLicence, useStoreFormCarDriverSuspension, useStoreFormCarDriverTicket, useStoreFormCarPostal, useStoreFormCarQuote, useStoreFormCarVehicle, useStoreFormHomeApplicantBase, useStoreFormHomeApplicantCancellation, useStoreFormHomeApplicantClaim, useStoreFormHomeApplicantInfo, useStoreFormHomeApplicantInsurance, useStoreFormHomeDiscount, useStoreFormHomeDwelling, useStoreFormHomePostal, useStoreFormHomeQuote, useStoreFormLifeApplicant, useStoreFormLifeCoverage, useStoreFormLifePostal, useStoreFormLifeQuote, useStorePartner, useValidationAddress, useValidationApplicant, useValidationCarDiscount, useValidationCoverage, useValidationDriver, useValidationDwelling, useValidationHomeDiscount, useValidationLifeApplicant, useValidationVehicle };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mychoice/mychoice-sdk-store",
3
- "version": "2.2.11",
3
+ "version": "2.2.14",
4
4
  "description": "> TODO: description",
5
5
  "homepage": "https://github.com/hexdivision/mychoice-sdk#readme",
6
6
  "author": "GogMes",
@@ -29,7 +29,7 @@
29
29
  "url": "https://github.com/hexdivision/mychoice-sdk/issues"
30
30
  },
31
31
  "dependencies": {
32
- "@mychoice/mychoice-sdk-components": "^2.2.0",
32
+ "@mychoice/mychoice-sdk-components": "^2.2.14",
33
33
  "@redux-devtools/extension": "^3.2.2",
34
34
  "axios": "^0.27.2",
35
35
  "humps": "^2.0.1",
@@ -37,5 +37,5 @@
37
37
  "redux": "^4.2.0",
38
38
  "redux-thunk": "^2.4.1"
39
39
  },
40
- "gitHead": "2bd60b0b6dd2b96d370025085756e213fdb51fd4"
40
+ "gitHead": "cc0ad353a328188d1259ec1cb95333dd5ceb4b8f"
41
41
  }