@npm_leadtech/legal-lib-components 7.43.3 → 7.44.1

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 (24) hide show
  1. package/dist/src/components/atoms/MenuItemsDeprecated/MenuItemsDeprecated.js +2 -3
  2. package/dist/src/components/atoms/MenuItemsDeprecated/MenuItemsDeprecated.styled.js +0 -11
  3. package/dist/src/components/atoms/MenuItemsDeprecated/MenuItemsDeprecated.styled.ts +0 -11
  4. package/dist/src/components/atoms/MenuItemsDeprecated/MenuItemsDeprecated.tsx +1 -3
  5. package/dist/src/components/atoms/MenuItemsDeprecated/MenuItemsDeprecatedProps.types.d.ts +0 -1
  6. package/dist/src/components/atoms/MenuItemsDeprecated/MenuItemsDeprecatedProps.types.ts +0 -1
  7. package/dist/src/components/atoms/TextArea/TextArea.js +2 -2
  8. package/dist/src/components/atoms/TextArea/TextArea.tsx +1 -3
  9. package/dist/src/components/atoms/TextArea/TextAreaProps.types.d.ts +0 -1
  10. package/dist/src/components/atoms/TextArea/TextAreaProps.types.ts +0 -1
  11. package/dist/src/components/molecules/NavBarDropDown/NavBarDropDown.js +2 -2
  12. package/dist/src/components/molecules/NavBarDropDown/NavBarDropDown.tsx +2 -8
  13. package/dist/src/components/molecules/NavBarDropDown/NavBarDropDownProps.types.d.ts +0 -1
  14. package/dist/src/components/molecules/NavBarDropDown/NavBarDropDownProps.types.ts +0 -1
  15. package/dist/src/components/molecules/SubtypeDocumentCard/SubtypeDocumentCard.js +2 -2
  16. package/dist/src/components/molecules/SubtypeDocumentCard/SubtypeDocumentCard.styled.d.ts +6 -1
  17. package/dist/src/components/molecules/SubtypeDocumentCard/SubtypeDocumentCard.styled.js +228 -120
  18. package/dist/src/components/molecules/SubtypeDocumentCard/SubtypeDocumentCard.styled.ts +236 -119
  19. package/dist/src/components/molecules/SubtypeDocumentCard/SubtypeDocumentCard.tsx +5 -5
  20. package/dist/src/components/molecules/SubtypeDocumentCard/SubtypeDocumentCardProps.types.d.ts +2 -0
  21. package/dist/src/components/molecules/SubtypeDocumentCard/SubtypeDocumentCardProps.types.ts +3 -0
  22. package/dist/src/components/molecules/SubtypeDocumentCard/index.d.ts +1 -1
  23. package/dist/src/components/molecules/SubtypeDocumentCard/index.ts +1 -1
  24. package/package.json +3 -1
@@ -7,7 +7,7 @@ import classNames from 'classnames';
7
7
  import { MenuItemsDeprecatedStyled } from './MenuItemsDeprecated.styled';
8
8
  import { stringSlugify } from '../../../utils/stringSlugify';
9
9
  // import './MenuItems.scss'
10
- const MenuItemsDeprecated = ({ spacing, list, hasBullets = false, initialActiveContent = '', isTestAB21644 = false, ...rest }) => {
10
+ const MenuItemsDeprecated = ({ spacing, list, hasBullets = false, initialActiveContent = '', ...rest }) => {
11
11
  const [contentListElement, setContentListElement] = useState(initialActiveContent);
12
12
  const filteredList = list?.filter((item) => item.content);
13
13
  if (filteredList.length === 0 || !filteredList[0].content) {
@@ -31,8 +31,7 @@ const MenuItemsDeprecated = ({ spacing, list, hasBullets = false, initialActiveC
31
31
  // eslint-disable-next-line jsx-a11y/no-noninteractive-element-interactions
32
32
  _jsx("li", { title: content, className: `menu-items__item ${className ?? ''}
33
33
  ${!href && onClick == null ? 'disabled' : ''}
34
- ${contentListElement === content ? 'active' : 'inactive'}
35
- ${isTestAB21644 ? 'menu-items__testab21644' : ''}`, onClick: () => {
34
+ ${contentListElement === content ? 'active' : 'inactive'}`, onClick: () => {
36
35
  if (onClick !== undefined) {
37
36
  onClick();
38
37
  }
@@ -8,17 +8,6 @@ export const MenuItemsDeprecatedStyled = styled.ul `
8
8
  }
9
9
  }
10
10
 
11
- &__testab21644 {
12
- &::before {
13
- content: '•';
14
- font-size: 1.2em;
15
- margin-right: 0.5rem;
16
- }
17
- &:hover::before {
18
- color: var(--primary-main-light-1);
19
- }
20
- }
21
-
22
11
  &__bullets {
23
12
  list-style-position: inside;
24
13
  list-style-type: disc;
@@ -9,17 +9,6 @@ export const MenuItemsDeprecatedStyled = styled.ul`
9
9
  }
10
10
  }
11
11
 
12
- &__testab21644 {
13
- &::before {
14
- content: '•';
15
- font-size: 1.2em;
16
- margin-right: 0.5rem;
17
- }
18
- &:hover::before {
19
- color: var(--primary-main-light-1);
20
- }
21
- }
22
-
23
12
  &__bullets {
24
13
  list-style-position: inside;
25
14
  list-style-type: disc;
@@ -14,7 +14,6 @@ const MenuItemsDeprecated: FC<MenuItemsDeprecatedProps> = ({
14
14
  list,
15
15
  hasBullets = false,
16
16
  initialActiveContent = '',
17
- isTestAB21644 = false,
18
17
  ...rest
19
18
  }) => {
20
19
  const [contentListElement, setContentListElement] = useState(initialActiveContent)
@@ -46,8 +45,7 @@ const MenuItemsDeprecated: FC<MenuItemsDeprecatedProps> = ({
46
45
  title={content}
47
46
  className={`menu-items__item ${className ?? ''}
48
47
  ${!href && onClick == null ? 'disabled' : ''}
49
- ${contentListElement === content ? 'active' : 'inactive'}
50
- ${isTestAB21644 ? 'menu-items__testab21644' : ''}`}
48
+ ${contentListElement === content ? 'active' : 'inactive'}`}
51
49
  onClick={() => {
52
50
  if (onClick !== undefined) {
53
51
  onClick()
@@ -4,7 +4,6 @@ export interface MenuItemsDeprecatedProps {
4
4
  hasBullets?: boolean;
5
5
  initialActiveContent?: string;
6
6
  list: MenuListItem[];
7
- isTestAB21644?: boolean;
8
7
  }
9
8
  export interface MenuListItem {
10
9
  className?: string;
@@ -5,7 +5,6 @@ export interface MenuItemsDeprecatedProps {
5
5
  hasBullets?: boolean
6
6
  initialActiveContent?: string
7
7
  list: MenuListItem[]
8
- isTestAB21644?: boolean
9
8
  }
10
9
 
11
10
  export interface MenuListItem {
@@ -1,9 +1,9 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { TextAreaStyled } from './TextArea.styled';
3
3
  import error from '../../../../images/svg/info-error_24px_outlined.svg';
4
- const TextArea = ({ customClass = '', disabled, errorMessage, label, name, onChange, placeholder, tooltip, validate = false, value, dataQa, maxLength }) => {
4
+ const TextArea = ({ customClass = '', disabled, errorMessage, label, name, onChange, placeholder, tooltip, validate = false, value, dataQa }) => {
5
5
  const classNames = `${validate ? 'e-textarea' : 'e-textarea --is-invalid'}
6
6
  ${customClass}`;
7
- return (_jsxs(TextAreaStyled, { className: classNames, children: [Boolean(tooltip) && _jsx("p", { className: 'tooltip-form sans-serif --small', children: tooltip }), Boolean(errorMessage) && !validate && (_jsxs("span", { className: 'e-text--error sans-serif --small', children: [_jsx("img", { src: error, alt: errorMessage }), errorMessage] })), _jsx("textarea", { id: name, name: name, placeholder: placeholder, onChange: onChange, value: value, disabled: disabled, "data-qa": dataQa, maxLength: maxLength }), Boolean(label) && (_jsx("div", { className: 'e-textarea__inner', children: _jsx("div", { className: 'inputLabel', children: label }) }))] }));
7
+ return (_jsxs(TextAreaStyled, { className: classNames, children: [Boolean(tooltip) && _jsx("p", { className: 'tooltip-form sans-serif --small', children: tooltip }), Boolean(errorMessage) && !validate && (_jsxs("span", { className: 'e-text--error sans-serif --small', children: [_jsx("img", { src: error, alt: errorMessage }), errorMessage] })), _jsx("textarea", { id: name, name: name, placeholder: placeholder, onChange: onChange, value: value, disabled: disabled, "data-qa": dataQa }), Boolean(label) && (_jsx("div", { className: 'e-textarea__inner', children: _jsx("div", { className: 'inputLabel', children: label }) }))] }));
8
8
  };
9
9
  export default TextArea;
@@ -15,8 +15,7 @@ const TextArea: FC<TextAreaProps> = ({
15
15
  tooltip,
16
16
  validate = false,
17
17
  value,
18
- dataQa,
19
- maxLength
18
+ dataQa
20
19
  }) => {
21
20
  const classNames = `${validate ? 'e-textarea' : 'e-textarea --is-invalid'}
22
21
  ${customClass}`
@@ -38,7 +37,6 @@ const TextArea: FC<TextAreaProps> = ({
38
37
  value={value}
39
38
  disabled={disabled}
40
39
  data-qa={dataQa}
41
- maxLength={maxLength}
42
40
  />
43
41
  {Boolean(label) && (
44
42
  <div className={'e-textarea__inner'}>
@@ -10,5 +10,4 @@ export interface TextAreaProps {
10
10
  validate?: boolean;
11
11
  disabled?: boolean;
12
12
  onChange?: (e: React.ChangeEvent<HTMLTextAreaElement>) => void;
13
- maxLength?: number;
14
13
  }
@@ -10,5 +10,4 @@ export interface TextAreaProps {
10
10
  validate?: boolean
11
11
  disabled?: boolean
12
12
  onChange?: (e: React.ChangeEvent<HTMLTextAreaElement>) => void
13
- maxLength?: number
14
13
  }
@@ -8,7 +8,7 @@ import { useIntersectionObserver } from '../../../hooks';
8
8
  let scrollPosition = 0;
9
9
  let touchStartPosY;
10
10
  let isDisabledScroll = false;
11
- export const NavBarDropDown = ({ isOpen, list, hasBullets = true, initialActiveContent, setEnableScrollbarOnClose, setIsOpen, isTestAB21644 = false }) => {
11
+ export const NavBarDropDown = ({ isOpen, list, hasBullets = true, initialActiveContent, setEnableScrollbarOnClose, setIsOpen }) => {
12
12
  const [ref, isIntersectingWithElement] = useIntersectionObserver({
13
13
  options: { threshold: 0.15 }
14
14
  });
@@ -63,5 +63,5 @@ export const NavBarDropDown = ({ isOpen, list, hasBullets = true, initialActiveC
63
63
  useEffect(() => {
64
64
  setEnableScrollbarOnClose(() => enableScrollbarOnClose);
65
65
  }, []);
66
- return (_jsx(_Fragment, { children: isOpen ? (_jsxs(NavBarDropDownStyled, { className: 'navbar-drop-down__container', children: [_jsx("div", { className: 'navbar-drop-down__container__menu_items', children: _jsx(MenuItemsDeprecated, { isTestAB21644: isTestAB21644, list: list, hasBullets: hasBullets, initialActiveContent: initialActiveContent }) }), _jsx("div", { ref: ref, className: 'navbar-drop-down__container__shadow', onClick: closeMenu })] })) : null }));
66
+ return (_jsx(_Fragment, { children: isOpen ? (_jsxs(NavBarDropDownStyled, { className: 'navbar-drop-down__container', children: [_jsx("div", { className: 'navbar-drop-down__container__menu_items', children: _jsx(MenuItemsDeprecated, { list: list, hasBullets: hasBullets, initialActiveContent: initialActiveContent }) }), _jsx("div", { ref: ref, className: 'navbar-drop-down__container__shadow', onClick: closeMenu })] })) : null }));
67
67
  };
@@ -16,8 +16,7 @@ export const NavBarDropDown: FC<NavBarDropDownProps> = ({
16
16
  hasBullets = true,
17
17
  initialActiveContent,
18
18
  setEnableScrollbarOnClose,
19
- setIsOpen,
20
- isTestAB21644 = false
19
+ setIsOpen
21
20
  }): React.ReactElement | null => {
22
21
  const [ref, isIntersectingWithElement] = useIntersectionObserver<HTMLDivElement>({
23
22
  options: { threshold: 0.15 }
@@ -88,12 +87,7 @@ export const NavBarDropDown: FC<NavBarDropDownProps> = ({
88
87
  {isOpen ? (
89
88
  <NavBarDropDownStyled className='navbar-drop-down__container'>
90
89
  <div className='navbar-drop-down__container__menu_items'>
91
- <MenuItemsDeprecated
92
- isTestAB21644={isTestAB21644}
93
- list={list}
94
- hasBullets={hasBullets}
95
- initialActiveContent={initialActiveContent}
96
- />
90
+ <MenuItemsDeprecated list={list} hasBullets={hasBullets} initialActiveContent={initialActiveContent} />
97
91
  </div>
98
92
  <div ref={ref} className='navbar-drop-down__container__shadow' onClick={closeMenu}></div>
99
93
  </NavBarDropDownStyled>
@@ -10,6 +10,5 @@ export interface NavBarDropDownProps {
10
10
  setEnableScrollbarOnClose: React.Dispatch<React.SetStateAction<(() => void) | undefined>>;
11
11
  setIsOpen: (open: boolean) => void;
12
12
  list: List[];
13
- isTestAB21644?: boolean;
14
13
  }
15
14
  export {};
@@ -10,5 +10,4 @@ export interface NavBarDropDownProps {
10
10
  setEnableScrollbarOnClose: React.Dispatch<React.SetStateAction<(() => void) | undefined>>
11
11
  setIsOpen: (open: boolean) => void
12
12
  list: List[]
13
- isTestAB21644?: boolean
14
13
  }
@@ -1,7 +1,7 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { Button } from '../../atoms';
3
3
  import { SubtypeDocumentCardStyled } from './SubtypeDocumentCard.styled';
4
- const SubtypeDocumentCard = ({ title, productUrl, description, children, pdfButton, wordButton, createDocButton }) => {
5
- return (_jsxs(SubtypeDocumentCardStyled, { className: 'subtype-document-card', children: [_jsx("div", { className: 'image-container', children: children }), _jsxs("div", { className: 'content', children: [_jsx("a", { href: productUrl, children: _jsx("h3", { className: 'title', children: title }) }), _jsx("p", { className: 'description', children: description }), _jsxs("div", { className: 'buttons-container', children: [_jsx(Button, { ...createDocButton }), _jsxs("div", { className: 'downloadable-buttons', children: [_jsx(Button, { ...pdfButton }), _jsx(Button, { ...wordButton })] })] })] })] }));
4
+ const SubtypeDocumentCard = ({ title, productUrl, description, children, pdfButton, wordButton, createDocButton, format = 'Default' }) => {
5
+ return (_jsxs(SubtypeDocumentCardStyled, { className: 'subtype-document-card', "$format": format, children: [_jsx("div", { className: 'image-container', children: children }), _jsxs("div", { className: 'content', children: [_jsx("a", { href: productUrl, children: _jsx("h3", { className: 'title', children: title }) }), format === 'Default' && _jsx("p", { className: 'description', children: description }), _jsxs("div", { className: 'buttons-container', children: [format === 'Default' && _jsx(Button, { ...createDocButton }), _jsxs("div", { className: 'downloadable-buttons', children: [_jsx(Button, { ...pdfButton }), _jsx(Button, { ...wordButton })] })] })] })] }));
6
6
  };
7
7
  export default SubtypeDocumentCard;
@@ -1 +1,6 @@
1
- export declare const SubtypeDocumentCardStyled: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
1
+ import { SubtypeDocumentCardFormat } from './SubtypeDocumentCardProps.types';
2
+ interface SubtypeDocumentCardStyledProps {
3
+ $format: SubtypeDocumentCardFormat;
4
+ }
5
+ export declare const SubtypeDocumentCardStyled: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, SubtypeDocumentCardStyledProps>> & string;
6
+ export {};
@@ -1,161 +1,269 @@
1
- import { device, size } from '../../../globalStyles/breakpoints';
2
1
  import styled from 'styled-components';
2
+ import { device, size } from '../../../globalStyles/breakpoints';
3
3
  export const SubtypeDocumentCardStyled = styled.div `
4
- display: flex;
5
- flex-direction: column;
6
- width: 100%;
7
- align-items: center;
8
- justify-content: center;
9
- width: 100%;
10
- max-width: 376px;
11
- min-height: 600px;
12
- padding: 2rem 1.5rem 2rem 1.5rem;
13
- gap: 24px;
14
- border-radius: var(--s-border-radius) 0 0 0;
15
- opacity: 0px;
16
- box-shadow: 0px 2px 6px 0px var(--neutral-neutral-3);
17
- background-color: var(--secondary-main-light-5);
18
- margin-bottom: 1.5rem;
19
-
20
- .image-container {
21
- width: 70%;
22
- }
23
-
24
- @media (min-width: ${size.xs}) {
25
- width: 400px;
26
- max-width: inherit;
27
- }
28
-
29
- @media (min-width: ${size.md}) {
30
- width: 543px;
31
- height: 364px;
32
- min-height: 380px;
33
- align-items: flex-start;
34
- flex-direction: row;
4
+ /* Default format styles (original styles) */
5
+ ${({ $format }) => $format === 'Default' &&
6
+ `
7
+ display: flex;
8
+ flex-direction: column;
9
+ width: 100%;
10
+ align-items: center;
11
+ justify-content: center;
12
+ width: 100%;
13
+ max-width: 376px;
14
+ min-height: 600px;
15
+ padding: 2rem 1.5rem 2rem 1.5rem;
16
+ gap: 24px;
17
+ border-radius: var(--s-border-radius) 0 0 0;
18
+ opacity: 0px;
19
+ box-shadow: 0px 2px 6px 0px var(--neutral-neutral-3);
20
+ background-color: var(--secondary-main-light-5);
21
+ margin-bottom: 1.5rem;
35
22
 
36
23
  .image-container {
37
- width: 40%;
24
+ width: 70%;
25
+ }
38
26
 
39
- @media (min-width: ${size.lg}) {
40
- width: 30%;
41
- }
27
+ @media (min-width: ${size.xs}) {
28
+ width: 400px;
29
+ max-width: inherit;
42
30
  }
43
- }
44
31
 
45
- @media (min-width: ${size.lg}) {
46
- width: 715px;
47
- height: 307px;
48
- min-height: 335px;
49
- }
32
+ @media (min-width: ${size.md}) {
33
+ width: 543px;
34
+ height: 364px;
35
+ min-height: 380px;
36
+ align-items: flex-start;
37
+ flex-direction: row;
50
38
 
51
- .content {
52
- display: flex;
53
- flex-direction: column;
54
- height: 100%;
55
- width: 100%;
56
- justify-content: flex-start;
39
+ .image-container {
40
+ width: 40%;
57
41
 
58
- @media ${device['landscape-tablets']} {
59
- margin-left: 1rem;
42
+ @media (min-width: ${size.lg}) {
43
+ width: 30%;
44
+ }
45
+ }
60
46
  }
61
47
 
62
- @media (min-width: ${size.md}) {
63
- width: 65%;
64
- }
65
- }
66
-
67
- .title {
68
- font-family: Inter;
69
- font-size: 18px;
70
- font-weight: 700;
71
- line-height: 24px;
72
- letter-spacing: -0.3px;
73
- text-align: left;
74
- text-decoration-line: underline;
75
- text-decoration-style: solid;
76
- text-underline-position: from-font;
77
- text-decoration-skip-ink: none;
78
- }
79
-
80
- .description {
81
- margin: 1rem 0;
82
- }
83
-
84
- .buttons-container {
85
- display: flex;
86
- justify-content: space-between;
87
- align-items: center;
88
- flex-direction: column;
89
-
90
- @media ${device.desktop} {
91
- flex-direction: row;
92
- align-self: flex-start;
93
- gap: var(--global-gap);
94
- align-items: center;
48
+ @media (min-width: ${size.lg}) {
49
+ width: 715px;
50
+ height: 307px;
51
+ min-height: 335px;
95
52
  }
96
53
 
97
- .create-doc-button {
54
+ .content {
55
+ display: flex;
56
+ flex-direction: column;
57
+ height: 100%;
98
58
  width: 100%;
59
+ justify-content: flex-start;
99
60
 
100
- @media ${device.laptop} {
101
- align-self: flex-start;
102
- width: auto;
103
- margin-top: 0.5rem;
61
+ @media ${device['landscape-tablets']} {
62
+ margin-left: 1rem;
104
63
  }
105
64
 
106
- @media ${device.desktop} {
107
- width: 100%;
108
- height: auto;
65
+ @media (min-width: ${size.md}) {
66
+ width: 65%;
109
67
  }
110
68
  }
111
69
 
112
- .downloadable-buttons {
70
+ .title {
71
+ font-family: Inter;
72
+ font-size: 18px;
73
+ font-weight: 700;
74
+ line-height: 24px;
75
+ letter-spacing: -0.3px;
76
+ text-align: left;
77
+ text-decoration-line: underline;
78
+ text-decoration-style: solid;
79
+ text-underline-position: from-font;
80
+ text-decoration-skip-ink: none;
81
+ }
82
+
83
+ .description {
84
+ margin: 1rem 0;
85
+ }
86
+
87
+ .buttons-container {
113
88
  display: flex;
114
- flex-wrap: wrap;
115
- gap: var(--global-gap);
116
- width: 100%;
117
89
  justify-content: space-between;
90
+ align-items: center;
91
+ flex-direction: column;
118
92
 
119
- a {
120
- min-width: 46.5%;
121
- max-width: 46.5%;
122
- margin-top: 0.75rem;
93
+ @media ${device.desktop} {
94
+ flex-direction: row;
95
+ align-self: flex-start;
96
+ gap: var(--global-gap);
97
+ align-items: center;
123
98
  }
124
99
 
125
- @media ${device.laptop} {
126
- justify-content: flex-start;
100
+ .create-doc-button {
127
101
  width: 100%;
128
102
 
129
- a {
130
- min-width: 46.5%;
131
- max-width: fit-content;
103
+ @media ${device.laptop} {
104
+ align-self: flex-start;
105
+ width: auto;
132
106
  margin-top: 0.5rem;
133
107
  }
108
+
109
+ @media ${device.desktop} {
110
+ width: 100%;
111
+ height: auto;
112
+ }
134
113
  }
135
114
 
136
- @media (min-width: ${size.lg}) {
115
+ .downloadable-buttons {
116
+ display: flex;
117
+ flex-wrap: wrap;
118
+ gap: var(--global-gap);
119
+ width: 100%;
120
+ justify-content: space-between;
121
+
137
122
  a {
138
- min-width: auto;
139
- max-width: fit-content;
123
+ min-width: 46.5%;
124
+ max-width: 46.5%;
125
+ margin-top: 0.75rem;
140
126
  }
127
+
128
+ @media ${device.laptop} {
129
+ justify-content: flex-start;
130
+ width: 100%;
131
+
132
+ a {
133
+ min-width: 46.5%;
134
+ max-width: fit-content;
135
+ margin-top: 0.5rem;
136
+ }
137
+ }
138
+
139
+ @media (min-width: ${size.lg}) {
140
+ a {
141
+ min-width: auto;
142
+ max-width: fit-content;
143
+ }
144
+ }
145
+
146
+ @media ${device.desktop} {
147
+ display: flex;
148
+ gap: var(--global-gap);
149
+ flex-wrap: nowrap;
150
+ margin-top: 0;
151
+ }
152
+ }
153
+ }
154
+
155
+ &.download-icon {
156
+ &::before {
157
+ content: '';
158
+ width: 1rem;
159
+ height: 1rem;
160
+ background-image: url('../../../assets/images/svg/icon-save-24-px.svg');
161
+ margin-right: 0.5rem;
141
162
  }
163
+ }
164
+ `}
165
+
166
+ /* Alternative format styles */
167
+ ${({ $format }) => $format === 'Alternative' &&
168
+ `
169
+ display: flex;
170
+ flex-direction: row;
171
+ width: 100%;
172
+ align-items: center;
173
+ justify-content: center;
174
+ padding: 2rem 1.5rem 2rem 1.5rem;
175
+ gap: 1rem;
176
+ border-radius: 1rem;
177
+ background-color: var(--neutral-neutral-6);
178
+ margin-bottom: 1.5rem;
179
+
180
+ .image-container {
181
+ width: 70%;
182
+ }
183
+
184
+ @media (min-width: ${size.xs}) {
185
+ width: 400px;
186
+ max-width: inherit;
187
+ }
188
+
189
+ @media (min-width: ${size.md}) {
190
+ align-items: center;
191
+ flex-direction: column;
192
+ width: 100%;
193
+ max-width: fit-content;
194
+ padding: 1.5rem;
195
+ }
196
+
197
+ @media (min-width: ${size.lg}) {
198
+ height: 310px;
199
+ }
200
+
201
+ .title {
202
+ font-family: Inter;
203
+ font-size: 18px;
204
+ font-weight: 700;
205
+ line-height: 24px;
206
+ margin-bottom: 24px;
207
+ letter-spacing: -0.3px;
208
+ text-align: left;
209
+ text-decoration-line: underline;
210
+ text-decoration-style: solid;
211
+ text-underline-position: from-font;
212
+ text-decoration-skip-ink: none;
213
+ }
214
+
215
+ .content {
216
+ width: 100%;
217
+ }
218
+
219
+ .buttons-container {
220
+ display: flex;
221
+ justify-content: space-between;
222
+ align-items: center;
223
+ flex-direction: column;
142
224
 
143
225
  @media ${device.desktop} {
144
- display: flex;
226
+ flex-direction: row;
227
+ align-self: flex-start;
145
228
  gap: var(--global-gap);
146
- flex-wrap: nowrap;
147
- margin-top: 0;
229
+ align-items: center;
148
230
  }
149
- }
150
- }
151
231
 
152
- &.download-icon {
153
- &::before {
154
- content: '';
155
- width: 1rem;
156
- height: 1rem;
157
- background-image: url('../../../assets/images/svg/icon-save-24-px.svg');
158
- margin-right: 0.5rem;
232
+ .downloadable-buttons {
233
+ display: flex;
234
+ flex-wrap: wrap;
235
+ width: 100%;
236
+ justify-content: space-between;
237
+
238
+ a {
239
+ margin-top: 0.75rem;
240
+ width: 100%;
241
+ }
242
+
243
+ @media ${device.laptop} {
244
+ justify-content: space-between;
245
+ width: 95%;
246
+ a {
247
+ min-width: 46.5%;
248
+ max-width: fit-content;
249
+ margin-top: 0.5rem;
250
+ }
251
+ }
252
+
253
+ @media (min-width: ${size.lg}) {
254
+ a {
255
+ min-width: auto;
256
+ max-width: fit-content;
257
+ }
258
+ }
259
+
260
+ @media ${device.desktop} {
261
+ display: flex;
262
+ gap: var(--global-gap);
263
+ flex-wrap: nowrap;
264
+ margin-top: 0;
265
+ }
266
+ }
159
267
  }
160
- }
268
+ `}
161
269
  `;
@@ -1,162 +1,279 @@
1
- import { device, size } from '../../../globalStyles/breakpoints'
2
1
  import styled from 'styled-components'
3
2
 
4
- export const SubtypeDocumentCardStyled = styled.div`
5
- display: flex;
6
- flex-direction: column;
7
- width: 100%;
8
- align-items: center;
9
- justify-content: center;
10
- width: 100%;
11
- max-width: 376px;
12
- min-height: 600px;
13
- padding: 2rem 1.5rem 2rem 1.5rem;
14
- gap: 24px;
15
- border-radius: var(--s-border-radius) 0 0 0;
16
- opacity: 0px;
17
- box-shadow: 0px 2px 6px 0px var(--neutral-neutral-3);
18
- background-color: var(--secondary-main-light-5);
19
- margin-bottom: 1.5rem;
20
-
21
- .image-container {
22
- width: 70%;
23
- }
24
-
25
- @media (min-width: ${size.xs}) {
26
- width: 400px;
27
- max-width: inherit;
28
- }
29
-
30
- @media (min-width: ${size.md}) {
31
- width: 543px;
32
- height: 364px;
33
- min-height: 380px;
34
- align-items: flex-start;
35
- flex-direction: row;
36
-
37
- .image-container {
38
- width: 40%;
3
+ import { device, size } from '../../../globalStyles/breakpoints'
39
4
 
40
- @media (min-width: ${size.lg}) {
41
- width: 30%;
42
- }
43
- }
44
- }
5
+ import { SubtypeDocumentCardFormat } from './SubtypeDocumentCardProps.types'
45
6
 
46
- @media (min-width: ${size.lg}) {
47
- width: 715px;
48
- height: 307px;
49
- min-height: 335px;
50
- }
7
+ interface SubtypeDocumentCardStyledProps {
8
+ $format: SubtypeDocumentCardFormat
9
+ }
51
10
 
52
- .content {
11
+ export const SubtypeDocumentCardStyled = styled.div<SubtypeDocumentCardStyledProps>`
12
+ /* Default format styles (original styles) */
13
+ ${({ $format }) =>
14
+ $format === 'Default' &&
15
+ `
53
16
  display: flex;
54
17
  flex-direction: column;
55
- height: 100%;
56
18
  width: 100%;
57
- justify-content: flex-start;
19
+ align-items: center;
20
+ justify-content: center;
21
+ width: 100%;
22
+ max-width: 376px;
23
+ min-height: 600px;
24
+ padding: 2rem 1.5rem 2rem 1.5rem;
25
+ gap: 24px;
26
+ border-radius: var(--s-border-radius) 0 0 0;
27
+ opacity: 0px;
28
+ box-shadow: 0px 2px 6px 0px var(--neutral-neutral-3);
29
+ background-color: var(--secondary-main-light-5);
30
+ margin-bottom: 1.5rem;
58
31
 
59
- @media ${device['landscape-tablets']} {
60
- margin-left: 1rem;
32
+ .image-container {
33
+ width: 70%;
61
34
  }
62
35
 
63
- @media (min-width: ${size.md}) {
64
- width: 65%;
65
- }
66
- }
67
-
68
- .title {
69
- font-family: Inter;
70
- font-size: 18px;
71
- font-weight: 700;
72
- line-height: 24px;
73
- letter-spacing: -0.3px;
74
- text-align: left;
75
- text-decoration-line: underline;
76
- text-decoration-style: solid;
77
- text-underline-position: from-font;
78
- text-decoration-skip-ink: none;
79
- }
80
-
81
- .description {
82
- margin: 1rem 0;
83
- }
84
-
85
- .buttons-container {
86
- display: flex;
87
- justify-content: space-between;
88
- align-items: center;
89
- flex-direction: column;
36
+ @media (min-width: ${size.xs}) {
37
+ width: 400px;
38
+ max-width: inherit;
39
+ }
90
40
 
91
- @media ${device.desktop} {
41
+ @media (min-width: ${size.md}) {
42
+ width: 543px;
43
+ height: 364px;
44
+ min-height: 380px;
45
+ align-items: flex-start;
92
46
  flex-direction: row;
93
- align-self: flex-start;
94
- gap: var(--global-gap);
95
- align-items: center;
47
+
48
+ .image-container {
49
+ width: 40%;
50
+
51
+ @media (min-width: ${size.lg}) {
52
+ width: 30%;
53
+ }
54
+ }
96
55
  }
97
56
 
98
- .create-doc-button {
57
+ @media (min-width: ${size.lg}) {
58
+ width: 715px;
59
+ height: 307px;
60
+ min-height: 335px;
61
+ }
62
+
63
+ .content {
64
+ display: flex;
65
+ flex-direction: column;
66
+ height: 100%;
99
67
  width: 100%;
68
+ justify-content: flex-start;
100
69
 
101
- @media ${device.laptop} {
102
- align-self: flex-start;
103
- width: auto;
104
- margin-top: 0.5rem;
70
+ @media ${device['landscape-tablets']} {
71
+ margin-left: 1rem;
105
72
  }
106
73
 
107
- @media ${device.desktop} {
108
- width: 100%;
109
- height: auto;
74
+ @media (min-width: ${size.md}) {
75
+ width: 65%;
110
76
  }
111
77
  }
112
78
 
113
- .downloadable-buttons {
79
+ .title {
80
+ font-family: Inter;
81
+ font-size: 18px;
82
+ font-weight: 700;
83
+ line-height: 24px;
84
+ letter-spacing: -0.3px;
85
+ text-align: left;
86
+ text-decoration-line: underline;
87
+ text-decoration-style: solid;
88
+ text-underline-position: from-font;
89
+ text-decoration-skip-ink: none;
90
+ }
91
+
92
+ .description {
93
+ margin: 1rem 0;
94
+ }
95
+
96
+ .buttons-container {
114
97
  display: flex;
115
- flex-wrap: wrap;
116
- gap: var(--global-gap);
117
- width: 100%;
118
98
  justify-content: space-between;
99
+ align-items: center;
100
+ flex-direction: column;
119
101
 
120
- a {
121
- min-width: 46.5%;
122
- max-width: 46.5%;
123
- margin-top: 0.75rem;
102
+ @media ${device.desktop} {
103
+ flex-direction: row;
104
+ align-self: flex-start;
105
+ gap: var(--global-gap);
106
+ align-items: center;
124
107
  }
125
108
 
126
- @media ${device.laptop} {
127
- justify-content: flex-start;
109
+ .create-doc-button {
128
110
  width: 100%;
129
111
 
130
- a {
131
- min-width: 46.5%;
132
- max-width: fit-content;
112
+ @media ${device.laptop} {
113
+ align-self: flex-start;
114
+ width: auto;
133
115
  margin-top: 0.5rem;
134
116
  }
117
+
118
+ @media ${device.desktop} {
119
+ width: 100%;
120
+ height: auto;
121
+ }
135
122
  }
136
123
 
137
- @media (min-width: ${size.lg}) {
124
+ .downloadable-buttons {
125
+ display: flex;
126
+ flex-wrap: wrap;
127
+ gap: var(--global-gap);
128
+ width: 100%;
129
+ justify-content: space-between;
130
+
138
131
  a {
139
- min-width: auto;
140
- max-width: fit-content;
132
+ min-width: 46.5%;
133
+ max-width: 46.5%;
134
+ margin-top: 0.75rem;
135
+ }
136
+
137
+ @media ${device.laptop} {
138
+ justify-content: flex-start;
139
+ width: 100%;
140
+
141
+ a {
142
+ min-width: 46.5%;
143
+ max-width: fit-content;
144
+ margin-top: 0.5rem;
145
+ }
146
+ }
147
+
148
+ @media (min-width: ${size.lg}) {
149
+ a {
150
+ min-width: auto;
151
+ max-width: fit-content;
152
+ }
141
153
  }
154
+
155
+ @media ${device.desktop} {
156
+ display: flex;
157
+ gap: var(--global-gap);
158
+ flex-wrap: nowrap;
159
+ margin-top: 0;
160
+ }
161
+ }
162
+ }
163
+
164
+ &.download-icon {
165
+ &::before {
166
+ content: '';
167
+ width: 1rem;
168
+ height: 1rem;
169
+ background-image: url('../../../assets/images/svg/icon-save-24-px.svg');
170
+ margin-right: 0.5rem;
142
171
  }
172
+ }
173
+ `}
174
+
175
+ /* Alternative format styles */
176
+ ${({ $format }) =>
177
+ $format === 'Alternative' &&
178
+ `
179
+ display: flex;
180
+ flex-direction: row;
181
+ width: 100%;
182
+ align-items: center;
183
+ justify-content: center;
184
+ padding: 2rem 1.5rem 2rem 1.5rem;
185
+ gap: 1rem;
186
+ border-radius: 1rem;
187
+ background-color: var(--neutral-neutral-6);
188
+ margin-bottom: 1.5rem;
189
+
190
+ .image-container {
191
+ width: 70%;
192
+ }
193
+
194
+ @media (min-width: ${size.xs}) {
195
+ width: 400px;
196
+ max-width: inherit;
197
+ }
198
+
199
+ @media (min-width: ${size.md}) {
200
+ align-items: center;
201
+ flex-direction: column;
202
+ width: 100%;
203
+ max-width: fit-content;
204
+ padding: 1.5rem;
205
+ }
206
+
207
+ @media (min-width: ${size.lg}) {
208
+ height: 310px;
209
+ }
210
+
211
+ .title {
212
+ font-family: Inter;
213
+ font-size: 18px;
214
+ font-weight: 700;
215
+ line-height: 24px;
216
+ margin-bottom: 24px;
217
+ letter-spacing: -0.3px;
218
+ text-align: left;
219
+ text-decoration-line: underline;
220
+ text-decoration-style: solid;
221
+ text-underline-position: from-font;
222
+ text-decoration-skip-ink: none;
223
+ }
224
+
225
+ .content {
226
+ width: 100%;
227
+ }
228
+
229
+ .buttons-container {
230
+ display: flex;
231
+ justify-content: space-between;
232
+ align-items: center;
233
+ flex-direction: column;
143
234
 
144
235
  @media ${device.desktop} {
145
- display: flex;
236
+ flex-direction: row;
237
+ align-self: flex-start;
146
238
  gap: var(--global-gap);
147
- flex-wrap: nowrap;
148
- margin-top: 0;
239
+ align-items: center;
149
240
  }
150
- }
151
- }
152
241
 
153
- &.download-icon {
154
- &::before {
155
- content: '';
156
- width: 1rem;
157
- height: 1rem;
158
- background-image: url('../../../assets/images/svg/icon-save-24-px.svg');
159
- margin-right: 0.5rem;
242
+ .downloadable-buttons {
243
+ display: flex;
244
+ flex-wrap: wrap;
245
+ width: 100%;
246
+ justify-content: space-between;
247
+
248
+ a {
249
+ margin-top: 0.75rem;
250
+ width: 100%;
251
+ }
252
+
253
+ @media ${device.laptop} {
254
+ justify-content: space-between;
255
+ width: 95%;
256
+ a {
257
+ min-width: 46.5%;
258
+ max-width: fit-content;
259
+ margin-top: 0.5rem;
260
+ }
261
+ }
262
+
263
+ @media (min-width: ${size.lg}) {
264
+ a {
265
+ min-width: auto;
266
+ max-width: fit-content;
267
+ }
268
+ }
269
+
270
+ @media ${device.desktop} {
271
+ display: flex;
272
+ gap: var(--global-gap);
273
+ flex-wrap: nowrap;
274
+ margin-top: 0;
275
+ }
276
+ }
160
277
  }
161
- }
278
+ `}
162
279
  `
@@ -1,4 +1,3 @@
1
- /* eslint-disable @typescript-eslint/no-unsafe-assignment */
2
1
  import React, { type FC } from 'react'
3
2
 
4
3
  import { Button } from '../../atoms'
@@ -12,18 +11,19 @@ const SubtypeDocumentCard: FC<SubtypeDocumentCardProps> = ({
12
11
  children,
13
12
  pdfButton,
14
13
  wordButton,
15
- createDocButton
14
+ createDocButton,
15
+ format = 'Default'
16
16
  }) => {
17
17
  return (
18
- <SubtypeDocumentCardStyled className='subtype-document-card'>
18
+ <SubtypeDocumentCardStyled className='subtype-document-card' $format={format}>
19
19
  <div className='image-container'>{children}</div>
20
20
  <div className='content'>
21
21
  <a href={productUrl}>
22
22
  <h3 className='title'>{title}</h3>
23
23
  </a>
24
- <p className='description'>{description}</p>
24
+ {format === 'Default' && <p className='description'>{description}</p>}
25
25
  <div className='buttons-container'>
26
- <Button {...createDocButton} />
26
+ {format === 'Default' && <Button {...createDocButton} />}
27
27
  <div className='downloadable-buttons'>
28
28
  <Button {...pdfButton} />
29
29
  <Button {...wordButton} />
@@ -1,4 +1,5 @@
1
1
  import { ButtonProps } from 'src/components/atoms';
2
+ export type SubtypeDocumentCardFormat = 'Default' | 'Alternative';
2
3
  export interface SubtypeDocumentCardProps {
3
4
  title: string;
4
5
  productUrl: string;
@@ -7,4 +8,5 @@ export interface SubtypeDocumentCardProps {
7
8
  pdfButton: ButtonProps;
8
9
  wordButton: ButtonProps;
9
10
  createDocButton: ButtonProps;
11
+ format?: SubtypeDocumentCardFormat;
10
12
  }
@@ -1,5 +1,7 @@
1
1
  import { ButtonProps } from 'src/components/atoms'
2
2
 
3
+ export type SubtypeDocumentCardFormat = 'Default' | 'Alternative'
4
+
3
5
  export interface SubtypeDocumentCardProps {
4
6
  title: string
5
7
  productUrl: string
@@ -8,4 +10,5 @@ export interface SubtypeDocumentCardProps {
8
10
  pdfButton: ButtonProps
9
11
  wordButton: ButtonProps
10
12
  createDocButton: ButtonProps
13
+ format?: SubtypeDocumentCardFormat
11
14
  }
@@ -1,2 +1,2 @@
1
1
  export { default as SubtypeDocumentCard } from './SubtypeDocumentCard';
2
- export { type SubtypeDocumentCardProps } from './SubtypeDocumentCardProps.types';
2
+ export { type SubtypeDocumentCardProps, type SubtypeDocumentCardFormat } from './SubtypeDocumentCardProps.types';
@@ -1,2 +1,2 @@
1
1
  export { default as SubtypeDocumentCard } from './SubtypeDocumentCard'
2
- export { type SubtypeDocumentCardProps } from './SubtypeDocumentCardProps.types'
2
+ export { type SubtypeDocumentCardProps, type SubtypeDocumentCardFormat } from './SubtypeDocumentCardProps.types'
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@npm_leadtech/legal-lib-components",
3
- "version": "7.43.3",
3
+ "version": "7.44.1",
4
4
  "license": "ISC",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -215,6 +215,8 @@
215
215
  "./BoxForm": "./dist/src/components/molecules/BoxForm/index.js",
216
216
  "./Breadcrumb": "./dist/src/components/molecules/Breadcrumb/index.js",
217
217
  "./ContactBox": "./dist/src/components/molecules/ContactBox/index.js",
218
+ "./ContactInfoBoxMobile": "./dist/src/components/molecules/ContactInfoBoxMobile/index.js",
219
+ "./ContactInfoCard": "./dist/src/components/molecules/ContactInfoCard/index.js",
218
220
  "./ContinueEditingBanner": "./dist/src/components/molecules/ContinueEditingBanner/index.js",
219
221
  "./CountDownMessage": "./dist/src/components/molecules/CountDownMessage/index.js",
220
222
  "./EmailContactBox": "./dist/src/components/molecules/EmailContactBox/index.js",