@mychoice/mychoice-sdk-modules 2.1.54 → 2.1.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/esm/index.js CHANGED
@@ -184,15 +184,19 @@ const NoQuotesMessage = ({ type }) => {
184
184
  const usePathGroups = (insuranceType) => {
185
185
  const { appConfigState } = useStoreAppConfig();
186
186
  const insurancePathGroup = {
187
- [`${InsuranceTypes.Car}`]: [{ name: 'Car', link: `/${appConfigState.localIndex}/car` }],
188
- [`${InsuranceTypes.Home}`]: [{ name: 'Home', link: `/${appConfigState.localIndex}/home` }],
187
+ [`${InsuranceTypes.Car}`]: [
188
+ { name: 'Car', link: `/${appConfigState.localIndex}/car` },
189
+ ],
190
+ [`${InsuranceTypes.Home}`]: [
191
+ { name: 'Home', link: `/${appConfigState.localIndex}/home` },
192
+ ],
189
193
  // @todo: will be used in future
190
194
  // [`${InsuranceTypes.Life}`]: [{ name: 'Life', link: `/${appConfigState.localIndex}/life` }],
191
195
  };
192
196
  const externalPathGroup = [
193
197
  { name: 'Car', link: 'https://quote.mychoice.ca/insurance/car' },
194
198
  { name: 'Home', link: 'https://quote.mychoice.ca/insurance/home' },
195
- { name: 'Life', link: 'https://quote.mychoice.ca/insurance/life' },
199
+ { name: 'Life', link: 'https://staging.new.mychoice.ca/insurance/life' },
196
200
  { name: 'Learn', link: 'https://www.mychoice.ca/blog/' },
197
201
  ];
198
202
  // @todo: use in future.
@@ -215,10 +219,13 @@ const usePathGroups = (insuranceType) => {
215
219
  };
216
220
 
217
221
  const HeaderMyChoice = ({ className, }) => {
218
- const { appConfigState: { insuranceType } } = useStoreAppConfig();
219
- const insuranceTypeCls = ((insuranceType !== InsuranceTypes.Car) && (insuranceType !== InsuranceTypes.Life)) ? InsuranceTypes.Home : insuranceType;
222
+ const { appConfigState: { insuranceType }, } = useStoreAppConfig();
223
+ const insuranceTypeCls = insuranceType !== InsuranceTypes.Car &&
224
+ insuranceType !== InsuranceTypes.Life
225
+ ? InsuranceTypes.Home
226
+ : insuranceType;
220
227
  const { externalPathGroup } = usePathGroups(insuranceTypeCls);
221
- return (jsx("div", { className: `${className} primary-header`, children: jsxs("div", { className: "content", children: [jsx("div", { className: "logo", children: jsx("a", { href: "https://www.mychoice.ca/", rel: "noreferrer", children: jsx("img", { src: logo, alt: "logotype" }) }) }), jsx("div", { className: "nav-links", children: jsx(HeaderNavGroup, { className: insuranceTypeCls, navItems: externalPathGroup, isExternal: true }) }), jsx("div", { className: "empty-box" })] }) }));
228
+ return (jsx("div", { className: `${className} primary-header`, children: jsxs("div", { className: "content", children: [jsx("div", { className: "logo", children: jsx("a", { href: "https://www.mychoice.ca/", rel: "noreferrer", children: jsx("img", { src: logo, alt: "logotype" }) }) }), jsx("div", { className: "nav-links", children: jsx(HeaderNavGroup, { className: insuranceTypeCls, navItems: externalPathGroup }) }), jsx("div", { className: "empty-box" })] }) }));
222
229
  };
223
230
  HeaderMyChoice.defaultProps = {
224
231
  className: '',