@npm_leadtech/legal-lib-components 7.17.4 → 7.17.23
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/images/componentsSvg/InfoLocationSvg.d.ts +2 -0
- package/dist/images/componentsSvg/InfoLocationSvg.js +4 -0
- package/dist/images/componentsSvg/InfoLocationSvg.tsx +14 -0
- package/dist/images/componentsSvg/InfoMailSvg.d.ts +2 -0
- package/dist/images/componentsSvg/InfoMailSvg.js +4 -0
- package/dist/images/componentsSvg/InfoMailSvg.tsx +12 -0
- package/dist/images/componentsSvg/InfoPhoneSvg.d.ts +2 -0
- package/dist/images/componentsSvg/InfoPhoneSvg.js +4 -0
- package/dist/images/componentsSvg/InfoPhoneSvg.tsx +12 -0
- package/dist/src/components/atoms/SearchSelect/SearchSelect.styled.js +1 -1
- package/dist/src/components/atoms/SearchSelect/SearchSelect.styled.ts +1 -1
- package/dist/src/components/molecules/ContactInfoBox/ContactInfoBox.d.ts +3 -0
- package/dist/src/components/molecules/ContactInfoBox/ContactInfoBox.js +6 -0
- package/dist/src/components/molecules/ContactInfoBox/ContactInfoBox.styled.d.ts +1 -0
- package/dist/src/components/molecules/ContactInfoBox/ContactInfoBox.styled.js +23 -0
- package/dist/src/components/molecules/ContactInfoBox/ContactInfoBox.styled.ts +24 -0
- package/dist/src/components/molecules/ContactInfoBox/ContactInfoBox.tsx +15 -0
- package/dist/src/components/molecules/ContactInfoBox/ContactInfoBoxProps.types.d.ts +4 -0
- package/dist/src/components/molecules/ContactInfoBox/ContactInfoBoxProps.types.js +1 -0
- package/dist/src/components/molecules/ContactInfoBox/ContactInfoBoxProps.types.ts +4 -0
- package/dist/src/components/molecules/ContactInfoBox/index.d.ts +2 -0
- package/dist/src/components/molecules/ContactInfoBox/index.js +1 -0
- package/dist/src/components/molecules/ContactInfoBox/index.ts +2 -0
- package/dist/src/components/molecules/ContactInfoBoxMobile/ContactInfoBoxMobile.d.ts +3 -0
- package/dist/src/components/molecules/ContactInfoBoxMobile/ContactInfoBoxMobile.js +6 -0
- package/dist/src/components/molecules/ContactInfoBoxMobile/ContactInfoBoxMobile.styled.d.ts +1 -0
- package/dist/src/components/molecules/ContactInfoBoxMobile/ContactInfoBoxMobile.styled.js +23 -0
- package/dist/src/components/molecules/ContactInfoBoxMobile/ContactInfoBoxMobile.styled.ts +24 -0
- package/dist/src/components/molecules/ContactInfoBoxMobile/ContactInfoBoxMobile.tsx +15 -0
- package/dist/src/components/molecules/ContactInfoBoxMobile/ContactInfoBoxMobileProps.types.d.ts +4 -0
- package/dist/src/components/molecules/ContactInfoBoxMobile/ContactInfoBoxMobileProps.types.js +1 -0
- package/dist/src/components/molecules/ContactInfoBoxMobile/ContactInfoBoxMobileProps.types.ts +4 -0
- package/dist/src/components/molecules/ContactInfoBoxMobile/index.d.ts +2 -0
- package/dist/src/components/molecules/ContactInfoBoxMobile/index.js +1 -0
- package/dist/src/components/molecules/ContactInfoBoxMobile/index.ts +2 -0
- package/dist/src/components/molecules/ContactInfoCard/ContactInfoCard.d.ts +3 -0
- package/dist/src/components/molecules/ContactInfoCard/ContactInfoCard.js +19 -0
- package/dist/src/components/molecules/ContactInfoCard/ContactInfoCard.styled.d.ts +1 -0
- package/dist/src/components/molecules/ContactInfoCard/ContactInfoCard.styled.js +77 -0
- package/dist/src/components/molecules/ContactInfoCard/ContactInfoCard.styled.ts +78 -0
- package/dist/src/components/molecules/ContactInfoCard/ContactInfoCard.tsx +58 -0
- package/dist/src/components/molecules/ContactInfoCard/ContactInfoCardProps.d.ts +7 -0
- package/dist/src/components/molecules/ContactInfoCard/ContactInfoCardProps.js +1 -0
- package/dist/src/components/molecules/ContactInfoCard/ContactInfoCardProps.ts +8 -0
- package/dist/src/components/molecules/ContactInfoCard/index.d.ts +2 -0
- package/dist/src/components/molecules/ContactInfoCard/index.js +2 -0
- package/dist/src/components/molecules/ContactInfoCard/index.ts +2 -0
- package/dist/src/components/molecules/NavBarDropDown/NavBarDropDown.tsx +1 -1
- package/dist/src/components/molecules/SocialLinks/SocialLinks.js +1 -5
- package/dist/src/components/molecules/SocialLinks/SocialLinks.tsx +7 -11
- package/dist/src/components/molecules/index.d.ts +2 -0
- package/dist/src/components/molecules/index.js +2 -0
- package/dist/src/components/molecules/index.ts +2 -0
- package/dist/src/components/organisms/ContactJumbotron/ContactJumbotron.js +3 -3
- package/dist/src/components/organisms/ContactJumbotron/ContactJumbotron.styled.js +0 -1
- package/dist/src/components/organisms/ContactJumbotron/ContactJumbotron.styled.ts +0 -1
- package/dist/src/components/organisms/ContactJumbotron/ContactJumbotron.tsx +4 -6
- package/dist/src/components/organisms/ContactJumbotron/ContactJumbotronProps.types.d.ts +2 -3
- package/dist/src/components/organisms/ContactJumbotron/ContactJumbotronProps.types.ts +2 -4
- package/dist/src/components/pages/ContactUsPage/ContactUsPage.js +3 -3
- package/dist/src/components/pages/ContactUsPage/ContactUsPage.tsx +3 -3
- package/dist/src/components/pages/ContactUsPage/ContactUsPageProps.d.ts +2 -2
- package/dist/src/components/pages/ContactUsPage/ContactUsPageProps.ts +2 -2
- package/dist/src/components/sections/ContactSection/ContactSection.styled.js +2 -0
- package/dist/src/components/sections/ContactSection/ContactSection.styled.ts +2 -0
- package/dist/src/hooks/useIntersectionObserver.d.ts +5 -7
- package/dist/src/hooks/useIntersectionObserver.js +7 -5
- package/dist/src/hooks/useIntersectionObserver.tsx +10 -12
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +1 -1
|
@@ -1,21 +1,17 @@
|
|
|
1
1
|
import React from 'react'
|
|
2
2
|
import { SocialLinksProps } from './SocialLinksProps.types'
|
|
3
3
|
import { SocialList } from './SocialLinks.styled'
|
|
4
|
-
import { useIntersectionObserver } from '../../../hooks'
|
|
5
4
|
|
|
6
5
|
export const SocialLinks: React.FC<SocialLinksProps> = ({ links }) => {
|
|
7
6
|
return (
|
|
8
7
|
<SocialList>
|
|
9
|
-
{links.map((social) =>
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
</li>
|
|
17
|
-
)
|
|
18
|
-
})}
|
|
8
|
+
{links.map((social) => (
|
|
9
|
+
<li key={social.url}>
|
|
10
|
+
<a href={social.url} rel='noopener noreferrer' target='_blank'>
|
|
11
|
+
<img src={social.iconSrc} alt={social.alt} width='20' height='20' />
|
|
12
|
+
</a>
|
|
13
|
+
</li>
|
|
14
|
+
))}
|
|
19
15
|
</SocialList>
|
|
20
16
|
)
|
|
21
17
|
}
|
|
@@ -12,6 +12,8 @@ export * from './Breadcrumb';
|
|
|
12
12
|
export * from './ContactBox';
|
|
13
13
|
export * from './ContactCardList';
|
|
14
14
|
export * from './ContactInfo';
|
|
15
|
+
export * from './ContactInfoBox';
|
|
16
|
+
export * from './ContactInfoBoxMobile';
|
|
15
17
|
export * from './ContinueEditingBanner';
|
|
16
18
|
export * from './CountDownMessage';
|
|
17
19
|
export * from './DocumentListMenuSection';
|
|
@@ -12,6 +12,8 @@ export * from './Breadcrumb';
|
|
|
12
12
|
export * from './ContactBox';
|
|
13
13
|
export * from './ContactCardList';
|
|
14
14
|
export * from './ContactInfo';
|
|
15
|
+
export * from './ContactInfoBox';
|
|
16
|
+
export * from './ContactInfoBoxMobile';
|
|
15
17
|
export * from './ContinueEditingBanner';
|
|
16
18
|
export * from './CountDownMessage';
|
|
17
19
|
export * from './DocumentListMenuSection';
|
|
@@ -12,6 +12,8 @@ export * from './Breadcrumb'
|
|
|
12
12
|
export * from './ContactBox'
|
|
13
13
|
export * from './ContactCardList'
|
|
14
14
|
export * from './ContactInfo'
|
|
15
|
+
export * from './ContactInfoBox'
|
|
16
|
+
export * from './ContactInfoBoxMobile'
|
|
15
17
|
export * from './ContinueEditingBanner'
|
|
16
18
|
export * from './CountDownMessage'
|
|
17
19
|
export * from './DocumentListMenuSection'
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { EmailContactBox, PhoneContactBoxDesktop } from '../../molecules';
|
|
3
2
|
import { Button } from '../../atoms';
|
|
3
|
+
import { ContactInfoBox } from '../../molecules/ContactInfoBox';
|
|
4
4
|
import { ContactJumbotronStyled } from './ContactJumbotron.styled';
|
|
5
|
-
export const ContactJumbotron = ({
|
|
6
|
-
return (_jsxs(ContactJumbotronStyled, { children: [
|
|
5
|
+
export const ContactJumbotron = ({ faqsTitle, visitFaqPageLabel, children, isJonSnow = false, items }) => {
|
|
6
|
+
return (_jsxs(ContactJumbotronStyled, { children: [_jsx(ContactInfoBox, { items: items }), _jsx("h2", { className: 'contact__text__title sans-serif', children: faqsTitle }), _jsx("div", { className: 'contact__text__subtitle sans-serif', children: children }), !isJonSnow && (_jsx(Button, { givenClass: 'faq-button', color: 'secondary', label: visitFaqPageLabel, link: '/faqs/', dataQa: 'visitFaq' }))] }));
|
|
7
7
|
};
|
|
@@ -1,21 +1,20 @@
|
|
|
1
1
|
import React from 'react'
|
|
2
2
|
|
|
3
|
-
import { EmailContactBox, PhoneContactBoxDesktop } from '../../molecules'
|
|
4
3
|
import { Button } from '../../atoms'
|
|
4
|
+
import { ContactInfoBox } from '../../molecules/ContactInfoBox'
|
|
5
5
|
import { type ContactJumbotronProps } from './ContactJumbotronProps.types'
|
|
6
6
|
import { ContactJumbotronStyled } from './ContactJumbotron.styled'
|
|
7
7
|
|
|
8
8
|
export const ContactJumbotron: React.FC<ContactJumbotronProps> = ({
|
|
9
|
-
phoneBoxDesktopProps,
|
|
10
|
-
emailContactBoxProps,
|
|
11
9
|
faqsTitle,
|
|
12
10
|
visitFaqPageLabel,
|
|
13
11
|
children,
|
|
14
|
-
isJonSnow = false
|
|
12
|
+
isJonSnow = false,
|
|
13
|
+
items
|
|
15
14
|
}) => {
|
|
16
15
|
return (
|
|
17
16
|
<ContactJumbotronStyled>
|
|
18
|
-
|
|
17
|
+
<ContactInfoBox items={items} />
|
|
19
18
|
<h2 className='contact__text__title sans-serif'>{faqsTitle}</h2>
|
|
20
19
|
<div className='contact__text__subtitle sans-serif'>{children}</div>
|
|
21
20
|
{!isJonSnow && (
|
|
@@ -27,7 +26,6 @@ export const ContactJumbotron: React.FC<ContactJumbotronProps> = ({
|
|
|
27
26
|
dataQa={'visitFaq'}
|
|
28
27
|
/>
|
|
29
28
|
)}
|
|
30
|
-
<EmailContactBox {...emailContactBoxProps} />
|
|
31
29
|
</ContactJumbotronStyled>
|
|
32
30
|
)
|
|
33
31
|
}
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
+
import { ContactInfoCardProps } from 'src/components/molecules/ContactInfoCard';
|
|
1
2
|
import type React from 'react';
|
|
2
|
-
import { type EmailContactBoxProps, type PhoneContactBoxDesktopProps } from '../../molecules';
|
|
3
3
|
export interface ContactJumbotronProps {
|
|
4
|
-
phoneBoxDesktopProps: PhoneContactBoxDesktopProps;
|
|
5
|
-
emailContactBoxProps: EmailContactBoxProps;
|
|
6
4
|
faqsTitle: string;
|
|
7
5
|
visitFaqPageLabel: string;
|
|
8
6
|
children: React.ReactNode;
|
|
9
7
|
isJonSnow?: boolean;
|
|
8
|
+
items: ContactInfoCardProps[];
|
|
10
9
|
}
|
|
@@ -1,12 +1,10 @@
|
|
|
1
|
+
import { ContactInfoCardProps } from 'src/components/molecules/ContactInfoCard'
|
|
1
2
|
import type React from 'react'
|
|
2
3
|
|
|
3
|
-
import { type EmailContactBoxProps, type PhoneContactBoxDesktopProps } from '../../molecules'
|
|
4
|
-
|
|
5
4
|
export interface ContactJumbotronProps {
|
|
6
|
-
phoneBoxDesktopProps: PhoneContactBoxDesktopProps
|
|
7
|
-
emailContactBoxProps: EmailContactBoxProps
|
|
8
5
|
faqsTitle: string
|
|
9
6
|
visitFaqPageLabel: string
|
|
10
7
|
children: React.ReactNode
|
|
11
8
|
isJonSnow?: boolean
|
|
9
|
+
items: ContactInfoCardProps[]
|
|
12
10
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { ContactSection, JumbotronSimplifiedSection } from '../../sections';
|
|
3
|
-
import {
|
|
4
|
-
export const ContactUsPage = ({ jumbotronSimplifiedSectionProps,
|
|
5
|
-
return (_jsxs(_Fragment, { children: [_jsx(JumbotronSimplifiedSection, { ...jumbotronSimplifiedSectionProps }), !isJonSnow && _jsx(
|
|
3
|
+
import { ContactInfoBoxMobile } from '../../molecules';
|
|
4
|
+
export const ContactUsPage = ({ jumbotronSimplifiedSectionProps, contactInfoBoxMobileProps, contactProps, isJonSnow = false }) => {
|
|
5
|
+
return (_jsxs(_Fragment, { children: [_jsx(JumbotronSimplifiedSection, { ...jumbotronSimplifiedSectionProps }), !isJonSnow && _jsx(ContactInfoBoxMobile, { ...contactInfoBoxMobileProps }), _jsx(ContactSection, { ...contactProps })] }));
|
|
6
6
|
};
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import React from 'react'
|
|
2
2
|
|
|
3
3
|
import { ContactSection, JumbotronSimplifiedSection } from '../../sections'
|
|
4
|
+
import { ContactInfoBoxMobile } from '../../molecules'
|
|
4
5
|
import { type ContactUsPageProps } from './ContactUsPageProps'
|
|
5
|
-
import { PhoneContactBoxMobile } from '../../molecules'
|
|
6
6
|
|
|
7
7
|
export const ContactUsPage: React.FC<ContactUsPageProps> = ({
|
|
8
8
|
jumbotronSimplifiedSectionProps,
|
|
9
|
-
|
|
9
|
+
contactInfoBoxMobileProps,
|
|
10
10
|
contactProps,
|
|
11
11
|
isJonSnow = false
|
|
12
12
|
}) => {
|
|
13
13
|
return (
|
|
14
14
|
<>
|
|
15
15
|
<JumbotronSimplifiedSection {...jumbotronSimplifiedSectionProps} />
|
|
16
|
-
{!isJonSnow && <
|
|
16
|
+
{!isJonSnow && <ContactInfoBoxMobile {...contactInfoBoxMobileProps} />}
|
|
17
17
|
<ContactSection {...contactProps} />
|
|
18
18
|
</>
|
|
19
19
|
)
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { type ContactSectionProps, type JumbotronSimplifiedSectionProps } from '../../sections';
|
|
2
|
-
import {
|
|
2
|
+
import { ContactInfoBoxMobileProps } from 'src/components/molecules/ContactInfoBoxMobile/ContactInfoBoxMobileProps.types';
|
|
3
3
|
export interface ContactUsPageProps {
|
|
4
4
|
jumbotronSimplifiedSectionProps: JumbotronSimplifiedSectionProps;
|
|
5
|
-
|
|
5
|
+
contactInfoBoxMobileProps: ContactInfoBoxMobileProps;
|
|
6
6
|
contactProps: ContactSectionProps;
|
|
7
7
|
isJonSnow?: boolean;
|
|
8
8
|
}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { type ContactSectionProps, type JumbotronSimplifiedSectionProps } from '../../sections'
|
|
2
|
-
import {
|
|
2
|
+
import { ContactInfoBoxMobileProps } from 'src/components/molecules/ContactInfoBoxMobile/ContactInfoBoxMobileProps.types'
|
|
3
3
|
|
|
4
4
|
export interface ContactUsPageProps {
|
|
5
5
|
jumbotronSimplifiedSectionProps: JumbotronSimplifiedSectionProps
|
|
6
|
-
|
|
6
|
+
contactInfoBoxMobileProps: ContactInfoBoxMobileProps
|
|
7
7
|
contactProps: ContactSectionProps
|
|
8
8
|
isJonSnow?: boolean
|
|
9
9
|
}
|
|
@@ -30,10 +30,12 @@ export const ContactSectionStyled = styled.section `
|
|
|
30
30
|
.contact-left-container {
|
|
31
31
|
padding-left: 1.5rem;
|
|
32
32
|
padding-right: 1.5rem;
|
|
33
|
+
margin-bottom: 2.5rem;
|
|
33
34
|
|
|
34
35
|
@media ${device['portrait-tablets']} {
|
|
35
36
|
padding-left: 0;
|
|
36
37
|
padding-right: 0;
|
|
38
|
+
margin-bottom: 1.5rem;
|
|
37
39
|
width: 45%;
|
|
38
40
|
}
|
|
39
41
|
}
|
|
@@ -31,10 +31,12 @@ export const ContactSectionStyled = styled.section`
|
|
|
31
31
|
.contact-left-container {
|
|
32
32
|
padding-left: 1.5rem;
|
|
33
33
|
padding-right: 1.5rem;
|
|
34
|
+
margin-bottom: 2.5rem;
|
|
34
35
|
|
|
35
36
|
@media ${device['portrait-tablets']} {
|
|
36
37
|
padding-left: 0;
|
|
37
38
|
padding-right: 0;
|
|
39
|
+
margin-bottom: 1.5rem;
|
|
38
40
|
width: 45%;
|
|
39
41
|
}
|
|
40
42
|
}
|
|
@@ -1,7 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
options?:
|
|
4
|
-
defaultIntersecting?: boolean;
|
|
5
|
-
}
|
|
6
|
-
export declare function useIntersectionObserver<T extends HTMLElement>({ options, defaultIntersecting }?: UseIntersectionObserverParams): [RefObject<T | null>, boolean];
|
|
7
|
-
export {};
|
|
1
|
+
import { type LegacyRef } from 'react';
|
|
2
|
+
export declare function useIntersectionObserver({ options, defaultIntersecting }: {
|
|
3
|
+
options?: {} | undefined;
|
|
4
|
+
defaultIntersecting?: boolean | undefined;
|
|
5
|
+
}): [LegacyRef<HTMLDivElement> | undefined, boolean];
|
|
@@ -1,19 +1,21 @@
|
|
|
1
1
|
import { useEffect, useRef, useState } from 'react';
|
|
2
|
-
export function useIntersectionObserver({ options = {}, defaultIntersecting = false }
|
|
2
|
+
export function useIntersectionObserver({ options = {}, defaultIntersecting = false }) {
|
|
3
3
|
const [isIntersecting, setIsIntersecting] = useState(defaultIntersecting);
|
|
4
4
|
const elementRef = useRef(null);
|
|
5
5
|
useEffect(() => {
|
|
6
6
|
const currentElement = elementRef.current;
|
|
7
|
-
if (!currentElement)
|
|
8
|
-
return;
|
|
9
7
|
const observer = new IntersectionObserver((entries) => {
|
|
10
8
|
entries.forEach((entry) => {
|
|
11
9
|
setIsIntersecting(entry.isIntersecting);
|
|
12
10
|
});
|
|
13
11
|
}, options);
|
|
14
|
-
|
|
12
|
+
if (currentElement != null) {
|
|
13
|
+
observer.observe(currentElement);
|
|
14
|
+
}
|
|
15
15
|
return () => {
|
|
16
|
-
|
|
16
|
+
if (currentElement != null) {
|
|
17
|
+
observer.unobserve(currentElement);
|
|
18
|
+
}
|
|
17
19
|
};
|
|
18
20
|
}, [options]);
|
|
19
21
|
return [elementRef, isIntersecting];
|
|
@@ -1,20 +1,14 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { type LegacyRef, useEffect, useRef, useState } from 'react'
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
options?: IntersectionObserverInit
|
|
5
|
-
defaultIntersecting?: boolean
|
|
6
|
-
}
|
|
7
|
-
|
|
8
|
-
export function useIntersectionObserver<T extends HTMLElement>({
|
|
3
|
+
export function useIntersectionObserver({
|
|
9
4
|
options = {},
|
|
10
5
|
defaultIntersecting = false
|
|
11
|
-
}
|
|
6
|
+
}): [LegacyRef<HTMLDivElement> | undefined, boolean] {
|
|
12
7
|
const [isIntersecting, setIsIntersecting] = useState(defaultIntersecting)
|
|
13
|
-
const elementRef = useRef<
|
|
8
|
+
const elementRef = useRef<HTMLDivElement>(null)
|
|
14
9
|
|
|
15
10
|
useEffect(() => {
|
|
16
11
|
const currentElement = elementRef.current
|
|
17
|
-
if (!currentElement) return
|
|
18
12
|
|
|
19
13
|
const observer = new IntersectionObserver((entries) => {
|
|
20
14
|
entries.forEach((entry) => {
|
|
@@ -22,10 +16,14 @@ export function useIntersectionObserver<T extends HTMLElement>({
|
|
|
22
16
|
})
|
|
23
17
|
}, options)
|
|
24
18
|
|
|
25
|
-
|
|
19
|
+
if (currentElement != null) {
|
|
20
|
+
observer.observe(currentElement)
|
|
21
|
+
}
|
|
26
22
|
|
|
27
23
|
return () => {
|
|
28
|
-
|
|
24
|
+
if (currentElement != null) {
|
|
25
|
+
observer.unobserve(currentElement)
|
|
26
|
+
}
|
|
29
27
|
}
|
|
30
28
|
}, [options])
|
|
31
29
|
|