@comicrelief/component-library 8.49.1 → 8.50.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.
- package/dist/components/Molecules/Accordion/Accordion.js +8 -1
- package/dist/components/Molecules/Accordion/__snapshots__/Accordion.test.js.snap +60 -21
- package/dist/components/Molecules/ArticleTeaser/ArticleTeaser.js +1 -6
- package/dist/components/Molecules/ArticleTeaser/ArticleTeaser.test.js +0 -16
- package/dist/components/Molecules/CTA/CTAMultiCard/CTAMultiCard.js +59 -0
- package/{src/components/Molecules → dist/components/Molecules/CTA}/CTAMultiCard/CTAMultiCard.md +4 -4
- package/dist/components/Molecules/CTA/CTAMultiCard/CTAMultiCard.style.js +55 -0
- package/dist/components/Molecules/CTA/CTAMultiCard/CTAMultiCard.test.js +91 -0
- package/dist/components/Molecules/CTA/CTAMultiCard/__snapshots__/CTAMultiCard.test.js.snap +2931 -0
- package/dist/components/Molecules/CTA/CTAMultiCard/example_data.json +107 -0
- package/dist/components/Molecules/CTA/CTASingleCard/CTASingleCard.js +44 -0
- package/dist/components/Molecules/CTA/CTASingleCard/CTASingleCard.md +124 -0
- package/dist/components/Molecules/CTA/CTASingleCard/CTASingleCard.style.js +23 -0
- package/dist/components/Molecules/CTA/CTASingleCard/CTASingleCard.test.js +96 -0
- package/dist/components/Molecules/CTA/CTASingleCard/__snapshots__/CTASingleCard.test.js.snap +903 -0
- package/dist/components/Molecules/CTA/shared/CTACard.js +67 -0
- package/dist/components/Molecules/CTA/shared/CTACard.style.js +269 -0
- package/dist/components/Molecules/{CTAMultiCard → CTA/shared}/_ArrowIcon.js +1 -1
- package/dist/components/Molecules/Descriptor/Descriptor.js +1 -5
- package/dist/components/Molecules/Descriptor/Descriptor.test.js +0 -8
- package/dist/components/Molecules/{CTAMultiCard → OLD_CTAMultiCard}/CTAMultiCard.style.js +11 -11
- package/dist/components/Molecules/OLD_CTAMultiCard/_ArrowIcon.js +29 -0
- package/dist/components/Molecules/{CTAMultiCard → OLD_CTAMultiCard}/__snapshots__/CTAMultiCard.test.js.snap +8 -0
- package/dist/index.js +8 -1
- package/package.json +1 -1
- package/src/components/Molecules/Accordion/Accordion.js +8 -1
- package/src/components/Molecules/Accordion/__snapshots__/Accordion.test.js.snap +60 -21
- package/src/components/Molecules/ArticleTeaser/ArticleTeaser.js +0 -6
- package/src/components/Molecules/ArticleTeaser/ArticleTeaser.test.js +0 -16
- package/src/components/Molecules/CTA/CTAMultiCard/CTAMultiCard.js +99 -0
- package/{dist/components/Molecules → src/components/Molecules/CTA}/CTAMultiCard/CTAMultiCard.md +4 -4
- package/src/components/Molecules/CTA/CTAMultiCard/CTAMultiCard.style.js +68 -0
- package/src/components/Molecules/CTA/CTAMultiCard/CTAMultiCard.test.js +107 -0
- package/src/components/Molecules/CTA/CTAMultiCard/__snapshots__/CTAMultiCard.test.js.snap +2931 -0
- package/src/components/Molecules/CTA/CTAMultiCard/example_data.json +107 -0
- package/src/components/Molecules/CTA/CTASingleCard/CTASingleCard.js +72 -0
- package/src/components/Molecules/CTA/CTASingleCard/CTASingleCard.md +124 -0
- package/src/components/Molecules/CTA/CTASingleCard/CTASingleCard.style.js +19 -0
- package/src/components/Molecules/CTA/CTASingleCard/CTASingleCard.test.js +96 -0
- package/src/components/Molecules/CTA/CTASingleCard/__snapshots__/CTASingleCard.test.js.snap +903 -0
- package/src/components/Molecules/CTA/shared/CTACard.js +115 -0
- package/src/components/Molecules/CTA/shared/CTACard.style.js +356 -0
- package/src/components/Molecules/Descriptor/Descriptor.js +0 -4
- package/src/components/Molecules/Descriptor/Descriptor.test.js +0 -8
- package/src/components/Molecules/{CTAMultiCard → OLD_CTAMultiCard}/CTAMultiCard.style.js +2 -0
- package/src/components/Molecules/OLD_CTAMultiCard/_ArrowIcon.js +22 -0
- package/src/components/Molecules/{CTAMultiCard → OLD_CTAMultiCard}/__snapshots__/CTAMultiCard.test.js.snap +8 -0
- package/src/index.js +2 -1
- /package/dist/components/Molecules/{CTAMultiCard → OLD_CTAMultiCard}/CTAMultiCard.js +0 -0
- /package/dist/components/Molecules/{CTAMultiCard → OLD_CTAMultiCard}/CTAMultiCard.test.js +0 -0
- /package/dist/components/Molecules/{CTAMultiCard → OLD_CTAMultiCard}/SingleCard.js +0 -0
- /package/dist/components/Molecules/{CTAMultiCard → OLD_CTAMultiCard}/example_data.json +0 -0
- /package/src/components/Molecules/{CTAMultiCard → CTA/shared}/_ArrowIcon.js +0 -0
- /package/src/components/Molecules/{CTAMultiCard → OLD_CTAMultiCard}/CTAMultiCard.js +0 -0
- /package/src/components/Molecules/{CTAMultiCard → OLD_CTAMultiCard}/CTAMultiCard.test.js +0 -0
- /package/src/components/Molecules/{CTAMultiCard → OLD_CTAMultiCard}/SingleCard.js +0 -0
- /package/src/components/Molecules/{CTAMultiCard → OLD_CTAMultiCard}/example_data.json +0 -0
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
|
|
4
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5
|
+
value: true
|
|
6
|
+
});
|
|
7
|
+
exports.default = void 0;
|
|
8
|
+
var _react = _interopRequireDefault(require("react"));
|
|
9
|
+
var _Picture = _interopRequireDefault(require("../../../Atoms/Picture/Picture"));
|
|
10
|
+
var _ArrowIcon = _interopRequireDefault(require("./_ArrowIcon"));
|
|
11
|
+
var _alt_cta_underline = _interopRequireDefault(require("../../../../theme/shared/assets/alt_cta_underline.svg"));
|
|
12
|
+
var _CTACard = require("./CTACard.style");
|
|
13
|
+
const CTACard = _ref => {
|
|
14
|
+
let {
|
|
15
|
+
card,
|
|
16
|
+
columns,
|
|
17
|
+
isCarousel,
|
|
18
|
+
isFullWidth,
|
|
19
|
+
isSingleCard
|
|
20
|
+
} = _ref;
|
|
21
|
+
// isSingleCard implies isFullWidth - single cards are always full width
|
|
22
|
+
const effectiveIsFullWidth = isSingleCard || isFullWidth;
|
|
23
|
+
const {
|
|
24
|
+
id,
|
|
25
|
+
body,
|
|
26
|
+
link,
|
|
27
|
+
linkLabel,
|
|
28
|
+
fallback,
|
|
29
|
+
imageLow,
|
|
30
|
+
images,
|
|
31
|
+
bgColour,
|
|
32
|
+
description,
|
|
33
|
+
target,
|
|
34
|
+
external
|
|
35
|
+
} = card;
|
|
36
|
+
return /*#__PURE__*/_react.default.createElement(_CTACard.CardWrapper, {
|
|
37
|
+
key: id,
|
|
38
|
+
isCarousel: isCarousel,
|
|
39
|
+
isFullWidth: effectiveIsFullWidth,
|
|
40
|
+
columns: columns
|
|
41
|
+
}, /*#__PURE__*/_react.default.createElement(_CTACard.CardLink, {
|
|
42
|
+
href: link,
|
|
43
|
+
target: target,
|
|
44
|
+
rel: external,
|
|
45
|
+
isCarousel: isCarousel,
|
|
46
|
+
isSingleCard: isSingleCard,
|
|
47
|
+
backgroundColor: bgColour
|
|
48
|
+
}, imageLow && /*#__PURE__*/_react.default.createElement(_CTACard.ImageWrapper, {
|
|
49
|
+
isSingleCard: isSingleCard
|
|
50
|
+
}, /*#__PURE__*/_react.default.createElement(_Picture.default, {
|
|
51
|
+
alt: description,
|
|
52
|
+
imageLow: imageLow,
|
|
53
|
+
images: images,
|
|
54
|
+
image: fallback,
|
|
55
|
+
objectFit: "cover",
|
|
56
|
+
width: "100%",
|
|
57
|
+
height: "100%"
|
|
58
|
+
})), /*#__PURE__*/_react.default.createElement(_CTACard.CopyAndLinkSection, {
|
|
59
|
+
backgroundColor: bgColour,
|
|
60
|
+
isSingleCard: isSingleCard
|
|
61
|
+
}, /*#__PURE__*/_react.default.createElement(_CTACard.Copy, null, body), linkLabel && /*#__PURE__*/_react.default.createElement(_CTACard.CTA, null, /*#__PURE__*/_react.default.createElement(_CTACard.CTAText, null, linkLabel, /*#__PURE__*/_react.default.createElement(_CTACard.CTATextUnderline, {
|
|
62
|
+
src: _alt_cta_underline.default,
|
|
63
|
+
alt: "",
|
|
64
|
+
"aria-hidden": "true"
|
|
65
|
+
})), /*#__PURE__*/_react.default.createElement(_CTACard.ArrowIconWrapper, null, /*#__PURE__*/_react.default.createElement(_ArrowIcon.default, null))))));
|
|
66
|
+
};
|
|
67
|
+
var _default = exports.default = CTACard;
|
|
@@ -0,0 +1,269 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
|
|
4
|
+
var _interopRequireWildcard = require("@babel/runtime/helpers/interopRequireWildcard").default;
|
|
5
|
+
Object.defineProperty(exports, "__esModule", {
|
|
6
|
+
value: true
|
|
7
|
+
});
|
|
8
|
+
exports.ImageWrapper = exports.CopyAndLinkSection = exports.Copy = exports.CardWrapper = exports.CardLink = exports.CTATextUnderline = exports.CTAText = exports.CTA = exports.ArrowIconWrapper = void 0;
|
|
9
|
+
var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
10
|
+
var _animations = require("../../../../theme/shared/animations");
|
|
11
|
+
var _allBreakpoints = require("../../../../theme/shared/allBreakpoints");
|
|
12
|
+
var _fontHelper = _interopRequireDefault(require("../../../../theme/crTheme/fontHelper"));
|
|
13
|
+
// const CardsContainer = styled.div`
|
|
14
|
+
// display: flex;
|
|
15
|
+
// flex-direction: column;
|
|
16
|
+
// width: 100%;
|
|
17
|
+
// background: ${({ theme, backgroundColor }) => theme.color(backgroundColor)};
|
|
18
|
+
// gap: 1rem;
|
|
19
|
+
|
|
20
|
+
// // Mobile carousel mode - horizontal scroll container (only on mobile, below M breakpoint)
|
|
21
|
+
// ${({ isCarousel }) => isCarousel && css`
|
|
22
|
+
// @media (max-width: ${breakpointValues.M - 1}px) {
|
|
23
|
+
// flex-direction: row;
|
|
24
|
+
// flex-wrap: nowrap;
|
|
25
|
+
// overflow-x: visible;
|
|
26
|
+
// overflow-y: scroll;
|
|
27
|
+
// -webkit-overflow-scrolling: touch;
|
|
28
|
+
// scroll-snap-type: x mandatory;
|
|
29
|
+
// padding: 0.75rem 0.5rem;
|
|
30
|
+
// margin-left: 0.5rem;
|
|
31
|
+
|
|
32
|
+
// scrollbar-width: none;
|
|
33
|
+
// -ms-overflow-style: none;
|
|
34
|
+
// &::-webkit-scrollbar {
|
|
35
|
+
// display: none;
|
|
36
|
+
// }
|
|
37
|
+
// }
|
|
38
|
+
// `}
|
|
39
|
+
|
|
40
|
+
// // Mobile stack mode - vertical layout (only on mobile, below M breakpoint)
|
|
41
|
+
// ${({ isCarousel }) => !isCarousel && css`
|
|
42
|
+
// @media (max-width: ${breakpointValues.M - 1}px) {
|
|
43
|
+
// flex-direction: column;
|
|
44
|
+
// background: transparent;
|
|
45
|
+
// }
|
|
46
|
+
// `}
|
|
47
|
+
|
|
48
|
+
// // Desktop flexbox layout - 2 columns with centered wrap
|
|
49
|
+
// @media ${({ theme }) => theme.allBreakpoints('M')} {
|
|
50
|
+
// flex-direction: row;
|
|
51
|
+
// flex-wrap: wrap;
|
|
52
|
+
// justify-content: center;
|
|
53
|
+
// align-items: stretch;
|
|
54
|
+
// width: fit-content;
|
|
55
|
+
// max-width: 100%;
|
|
56
|
+
// margin: 0 auto;
|
|
57
|
+
// }
|
|
58
|
+
|
|
59
|
+
// // Desktop grid layout for XL breakpoint - 3 columns
|
|
60
|
+
// @media ${({ theme }) => theme.allBreakpoints('XL')} {
|
|
61
|
+
// display: grid;
|
|
62
|
+
// justify-content: center;
|
|
63
|
+
// grid-template-columns: ${({ columns }) => `repeat(${columns}, 1fr)`};
|
|
64
|
+
// width: ${({ columns }) => (columns === 2 ? 'fit-content' : '100%')};
|
|
65
|
+
// margin: ${({ columns }) => (columns === 2 ? '0 auto' : '0')};
|
|
66
|
+
// max-width: 100%;
|
|
67
|
+
// }
|
|
68
|
+
// `;
|
|
69
|
+
const ImageWrapper = exports.ImageWrapper = _styledComponents.default.div.withConfig({
|
|
70
|
+
displayName: "CTACardstyle__ImageWrapper",
|
|
71
|
+
componentId: "sc-si8xx1-0"
|
|
72
|
+
})(["width:100%;overflow:hidden;flex-shrink:0;background:transparent;border-radius:1rem 1rem 0 0;", " img{width:100%;height:auto;object-fit:cover;display:block;", " @media ", "{", "}}"], _ref => {
|
|
73
|
+
let {
|
|
74
|
+
isSingleCard
|
|
75
|
+
} = _ref;
|
|
76
|
+
return isSingleCard && (0, _styledComponents.css)(["@media ", "{width:calc(100% / 3);min-width:292px;max-width:309px;flex-shrink:0;flex-grow:0;height:100%;border-radius:1rem 0 0 1rem;}@media ", "{min-width:355px;max-width:362px;}@media ", "{min-width:363px;max-width:363px;}"], _ref2 => {
|
|
77
|
+
let {
|
|
78
|
+
theme
|
|
79
|
+
} = _ref2;
|
|
80
|
+
return theme.breakpoints2026('M');
|
|
81
|
+
}, _ref3 => {
|
|
82
|
+
let {
|
|
83
|
+
theme
|
|
84
|
+
} = _ref3;
|
|
85
|
+
return theme.breakpoints2026('L');
|
|
86
|
+
}, _ref4 => {
|
|
87
|
+
let {
|
|
88
|
+
theme
|
|
89
|
+
} = _ref4;
|
|
90
|
+
return theme.breakpoints2026('XL');
|
|
91
|
+
});
|
|
92
|
+
}, _ref5 => {
|
|
93
|
+
let {
|
|
94
|
+
isSingleCard
|
|
95
|
+
} = _ref5;
|
|
96
|
+
return isSingleCard && (0, _styledComponents.css)(["@media ", "{height:100%;object-fit:cover;}"], _ref6 => {
|
|
97
|
+
let {
|
|
98
|
+
theme
|
|
99
|
+
} = _ref6;
|
|
100
|
+
return theme.breakpoints2026('M');
|
|
101
|
+
});
|
|
102
|
+
}, _ref7 => {
|
|
103
|
+
let {
|
|
104
|
+
theme
|
|
105
|
+
} = _ref7;
|
|
106
|
+
return theme.allBreakpoints('M');
|
|
107
|
+
}, (0, _animations.springScaleAnimation)(true));
|
|
108
|
+
const CTAText = exports.CTAText = _styledComponents.default.span.withConfig({
|
|
109
|
+
displayName: "CTACardstyle__CTAText",
|
|
110
|
+
componentId: "sc-si8xx1-1"
|
|
111
|
+
})(["", " color:", ";font-weight:bold;text-decoration:none;position:relative;display:inline-block;"], _ref8 => {
|
|
112
|
+
let {
|
|
113
|
+
theme
|
|
114
|
+
} = _ref8;
|
|
115
|
+
return (0, _fontHelper.default)(theme, 'span');
|
|
116
|
+
}, _ref9 => {
|
|
117
|
+
let {
|
|
118
|
+
theme
|
|
119
|
+
} = _ref9;
|
|
120
|
+
return theme.color('grey');
|
|
121
|
+
});
|
|
122
|
+
const CTATextUnderline = exports.CTATextUnderline = _styledComponents.default.img.withConfig({
|
|
123
|
+
displayName: "CTACardstyle__CTATextUnderline",
|
|
124
|
+
componentId: "sc-si8xx1-2"
|
|
125
|
+
})(["height:4px;width:100%;position:absolute;left:0;bottom:-5px;transition:opacity 0.15s 0.1s;opacity:0;pointer-events:none;"]);
|
|
126
|
+
const ArrowIconWrapper = exports.ArrowIconWrapper = _styledComponents.default.div.withConfig({
|
|
127
|
+
displayName: "CTACardstyle__ArrowIconWrapper",
|
|
128
|
+
componentId: "sc-si8xx1-3"
|
|
129
|
+
})(["width:32px;height:32px;border-radius:50%;background:", ";display:flex;align-items:center;justify-content:center;flex-shrink:0;"], _ref10 => {
|
|
130
|
+
let {
|
|
131
|
+
theme
|
|
132
|
+
} = _ref10;
|
|
133
|
+
return theme.color('grey');
|
|
134
|
+
});
|
|
135
|
+
|
|
136
|
+
// Card wrapper link - makes entire card clickable
|
|
137
|
+
const CardLink = exports.CardLink = _styledComponents.default.a.withConfig({
|
|
138
|
+
displayName: "CTACardstyle__CardLink",
|
|
139
|
+
componentId: "sc-si8xx1-4"
|
|
140
|
+
})(["display:flex;position:relative;flex-direction:column;width:100%;flex:1 1 auto;background:transparent;border-radius:1rem;box-shadow:0 0 1rem rgba(0,0,0,0.15);text-decoration:none;overflow:hidden;cursor:pointer;box-sizing:border-box;", " img{transform:scale(1.02);transition:transform ", "s cubic-bezier(0.68,", ",0.265,", ");}@media ", "{", ";&:hover{box-shadow:0 0 1.5rem rgba(0,0,0,0.25);", " img{transform:scale(1.1);}", "{color:", ";text-decoration:none;}", "{opacity:1;}", "{background:", ";}}}"], _ref11 => {
|
|
141
|
+
let {
|
|
142
|
+
isSingleCard
|
|
143
|
+
} = _ref11;
|
|
144
|
+
return isSingleCard && (0, _styledComponents.css)(["@media ", "{flex-direction:row;align-items:stretch;min-height:calc(219px - 4rem);}@media ", "{min-height:calc(272px - 4rem);}"], _ref12 => {
|
|
145
|
+
let {
|
|
146
|
+
theme
|
|
147
|
+
} = _ref12;
|
|
148
|
+
return theme.breakpoints2026('M');
|
|
149
|
+
}, _ref13 => {
|
|
150
|
+
let {
|
|
151
|
+
theme
|
|
152
|
+
} = _ref13;
|
|
153
|
+
return theme.breakpoints2026('L');
|
|
154
|
+
});
|
|
155
|
+
}, 0.4, -1.15, 2.35, _ref14 => {
|
|
156
|
+
let {
|
|
157
|
+
theme
|
|
158
|
+
} = _ref14;
|
|
159
|
+
return theme.allBreakpoints('M');
|
|
160
|
+
}, (0, _animations.bounceUpAnimation)(true, 0.02, 1), ImageWrapper, CTAText, _ref15 => {
|
|
161
|
+
let {
|
|
162
|
+
theme
|
|
163
|
+
} = _ref15;
|
|
164
|
+
return theme.color('red');
|
|
165
|
+
}, CTATextUnderline, ArrowIconWrapper, _ref16 => {
|
|
166
|
+
let {
|
|
167
|
+
theme
|
|
168
|
+
} = _ref16;
|
|
169
|
+
return theme.color('red');
|
|
170
|
+
});
|
|
171
|
+
const CardWrapper = exports.CardWrapper = _styledComponents.default.div.withConfig({
|
|
172
|
+
displayName: "CTACardstyle__CardWrapper",
|
|
173
|
+
componentId: "sc-si8xx1-5"
|
|
174
|
+
})(["width:100%;flex-shrink:0;display:flex;flex-direction:column;align-self:stretch;", " ", " ", " ", ""], _ref17 => {
|
|
175
|
+
let {
|
|
176
|
+
isFullWidth
|
|
177
|
+
} = _ref17;
|
|
178
|
+
return isFullWidth && (0, _styledComponents.css)(["width:100%;max-width:100%;@media ", "{flex-basis:100%;max-width:100%;height:auto;}@media ", "{flex-basis:100%;max-width:100%;height:auto;}"], _ref18 => {
|
|
179
|
+
let {
|
|
180
|
+
theme
|
|
181
|
+
} = _ref18;
|
|
182
|
+
return theme.allBreakpoints('M');
|
|
183
|
+
}, _ref19 => {
|
|
184
|
+
let {
|
|
185
|
+
theme
|
|
186
|
+
} = _ref19;
|
|
187
|
+
return theme.allBreakpoints('XL');
|
|
188
|
+
});
|
|
189
|
+
}, _ref20 => {
|
|
190
|
+
let {
|
|
191
|
+
isCarousel,
|
|
192
|
+
isFullWidth
|
|
193
|
+
} = _ref20;
|
|
194
|
+
return isCarousel && !isFullWidth && (0, _styledComponents.css)(["@media (max-width:", "px){scroll-snap-align:start;flex:0 0 309px;width:309px;flex-shrink:0;}"], _allBreakpoints.breakpointValues.L - 1);
|
|
195
|
+
}, _ref21 => {
|
|
196
|
+
let {
|
|
197
|
+
isCarousel,
|
|
198
|
+
isFullWidth
|
|
199
|
+
} = _ref21;
|
|
200
|
+
return !isCarousel && !isFullWidth && (0, _styledComponents.css)(["@media (max-width:", "px){max-width:", ";margin-left:auto;margin-right:auto;}@media (min-width:", "px) and (max-width:", "px){align-self:stretch;", "}"], _allBreakpoints.breakpointValues.M - 1, _ref22 => {
|
|
201
|
+
let {
|
|
202
|
+
columns
|
|
203
|
+
} = _ref22;
|
|
204
|
+
return columns === 3 ? '309px' : '345px';
|
|
205
|
+
}, _allBreakpoints.breakpointValues.M, _allBreakpoints.breakpointValues.L - 1, _ref23 => {
|
|
206
|
+
let {
|
|
207
|
+
columns
|
|
208
|
+
} = _ref23;
|
|
209
|
+
return columns === 3 ? (0, _styledComponents.css)(["flex:0 0 100%;max-width:309px;margin-left:auto;margin-right:auto;"]) : (0, _styledComponents.css)(["flex:0 0 345px;max-width:345px;margin-left:0;margin-right:0;"]);
|
|
210
|
+
});
|
|
211
|
+
}, _ref24 => {
|
|
212
|
+
let {
|
|
213
|
+
isFullWidth
|
|
214
|
+
} = _ref24;
|
|
215
|
+
return !isFullWidth && (0, _styledComponents.css)(["@media (min-width:", "px) and (max-width:", "px){", " align-self:stretch;}@media ", "{flex-basis:unset;width:", ";align-self:stretch;}"], _allBreakpoints.breakpointValues.L, _allBreakpoints.breakpointValues.XL - 1, _ref25 => {
|
|
216
|
+
let {
|
|
217
|
+
columns
|
|
218
|
+
} = _ref25;
|
|
219
|
+
return columns === 3 ? (0, _styledComponents.css)(["flex-basis:calc(33.333% - 1rem);min-width:286px;max-width:371px;"]) : (0, _styledComponents.css)(["flex-basis:calc(50% - 1rem);min-width:443px;max-width:564px;"]);
|
|
220
|
+
}, _ref26 => {
|
|
221
|
+
let {
|
|
222
|
+
theme
|
|
223
|
+
} = _ref26;
|
|
224
|
+
return theme.allBreakpoints('XL');
|
|
225
|
+
}, _ref27 => {
|
|
226
|
+
let {
|
|
227
|
+
columns
|
|
228
|
+
} = _ref27;
|
|
229
|
+
return columns === 3 ? '371px' : '564px';
|
|
230
|
+
});
|
|
231
|
+
});
|
|
232
|
+
const CopyAndLinkSection = exports.CopyAndLinkSection = _styledComponents.default.div.withConfig({
|
|
233
|
+
displayName: "CTACardstyle__CopyAndLinkSection",
|
|
234
|
+
componentId: "sc-si8xx1-6"
|
|
235
|
+
})(["width:100%;background:", ";display:flex;flex-direction:column;padding:2rem;flex:1;min-height:0;border-radius:0 0 1rem 1rem;", ""], _ref28 => {
|
|
236
|
+
let {
|
|
237
|
+
theme,
|
|
238
|
+
backgroundColor
|
|
239
|
+
} = _ref28;
|
|
240
|
+
return theme.color(backgroundColor);
|
|
241
|
+
}, _ref29 => {
|
|
242
|
+
let {
|
|
243
|
+
isSingleCard
|
|
244
|
+
} = _ref29;
|
|
245
|
+
return isSingleCard && (0, _styledComponents.css)(["@media ", "{width:calc(200% / 3);min-width:384px;max-width:650px;flex:1;border-radius:0 1rem 1rem 0;}@media ", "{min-width:541px;max-width:790px;}@media ", "{width:789px;}"], _ref30 => {
|
|
246
|
+
let {
|
|
247
|
+
theme
|
|
248
|
+
} = _ref30;
|
|
249
|
+
return theme.breakpoints2026('M');
|
|
250
|
+
}, _ref31 => {
|
|
251
|
+
let {
|
|
252
|
+
theme
|
|
253
|
+
} = _ref31;
|
|
254
|
+
return theme.breakpoints2026('L');
|
|
255
|
+
}, _ref32 => {
|
|
256
|
+
let {
|
|
257
|
+
theme
|
|
258
|
+
} = _ref32;
|
|
259
|
+
return theme.breakpoints2026('XL');
|
|
260
|
+
});
|
|
261
|
+
});
|
|
262
|
+
const Copy = exports.Copy = _styledComponents.default.div.withConfig({
|
|
263
|
+
displayName: "CTACardstyle__Copy",
|
|
264
|
+
componentId: "sc-si8xx1-7"
|
|
265
|
+
})(["flex:1;display:flex;flex-direction:column;min-height:0;"]);
|
|
266
|
+
const CTA = exports.CTA = _styledComponents.default.div.withConfig({
|
|
267
|
+
displayName: "CTACardstyle__CTA",
|
|
268
|
+
componentId: "sc-si8xx1-8"
|
|
269
|
+
})(["width:100%;display:flex;flex-direction:row;align-items:center;justify-content:space-between;margin-top:auto;padding-top:1rem;"]);
|
|
@@ -9,7 +9,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
9
9
|
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
10
10
|
const StyledArrowIcon = _styledComponents.default.svg.withConfig({
|
|
11
11
|
displayName: "_ArrowIcon__StyledArrowIcon",
|
|
12
|
-
componentId: "sc-
|
|
12
|
+
componentId: "sc-mqq2gw-0"
|
|
13
13
|
})(["display:inline-block;color:", ";fill:currentColor;"], _ref => {
|
|
14
14
|
let {
|
|
15
15
|
theme
|
|
@@ -141,11 +141,7 @@ const Descriptor = _ref3 => {
|
|
|
141
141
|
color: "grey_dark",
|
|
142
142
|
family: "Montserrat"
|
|
143
143
|
}, date), /*#__PURE__*/_react.default.createElement(IconWrapper, null, icons)), /*#__PURE__*/_react.default.createElement(Title, {
|
|
144
|
-
|
|
145
|
-
tag: "h3",
|
|
146
|
-
height: "2rem",
|
|
147
|
-
weight: "normal",
|
|
148
|
-
family: "Anton"
|
|
144
|
+
tag: "h3"
|
|
149
145
|
}, title), /*#__PURE__*/_react.default.createElement(TagWrapper, null, tagItems), /*#__PURE__*/_react.default.createElement(Description, null, children)));
|
|
150
146
|
};
|
|
151
147
|
var _default = exports.default = Descriptor;
|
|
@@ -52,14 +52,6 @@ it('renders article teaser correctly', () => {
|
|
|
52
52
|
line-height: 1.5rem;
|
|
53
53
|
}
|
|
54
54
|
|
|
55
|
-
.c7 {
|
|
56
|
-
font-size: 2rem;
|
|
57
|
-
line-height: normal;
|
|
58
|
-
font-family: 'Anton',Impact,sans-serif;
|
|
59
|
-
font-weight: normal;
|
|
60
|
-
line-height: 2rem;
|
|
61
|
-
}
|
|
62
|
-
|
|
63
55
|
.c7 span {
|
|
64
56
|
font-size: inherit;
|
|
65
57
|
line-height: inherit;
|
|
@@ -12,7 +12,7 @@ var _allBreakpoints = require("../../../theme/shared/allBreakpoints");
|
|
|
12
12
|
var _fontHelper = _interopRequireDefault(require("../../../theme/crTheme/fontHelper"));
|
|
13
13
|
const CardsContainer = exports.CardsContainer = _styledComponents.default.div.withConfig({
|
|
14
14
|
displayName: "CTAMultiCardstyle__CardsContainer",
|
|
15
|
-
componentId: "sc-
|
|
15
|
+
componentId: "sc-12iazzn-0"
|
|
16
16
|
})(["padding-top:", ";padding-bottom:", ";display:flex;flex-direction:column;width:100%;background:", ";gap:1rem;", " @media ", "{flex-direction:row;flex-wrap:wrap;justify-content:center;align-items:stretch;width:fit-content;max-width:100%;margin:0 auto;}", " @media ", "{", "}"], _ref => {
|
|
17
17
|
let {
|
|
18
18
|
paddingAbove
|
|
@@ -57,7 +57,7 @@ const CardsContainer = exports.CardsContainer = _styledComponents.default.div.wi
|
|
|
57
57
|
});
|
|
58
58
|
const ImageWrapper = exports.ImageWrapper = _styledComponents.default.div.withConfig({
|
|
59
59
|
displayName: "CTAMultiCardstyle__ImageWrapper",
|
|
60
|
-
componentId: "sc-
|
|
60
|
+
componentId: "sc-12iazzn-1"
|
|
61
61
|
})(["width:100%;overflow:hidden;flex-shrink:0;background:transparent;img{width:100%;height:auto;object-fit:cover;display:block;@media ", "{", "}}"], _ref9 => {
|
|
62
62
|
let {
|
|
63
63
|
theme
|
|
@@ -66,7 +66,7 @@ const ImageWrapper = exports.ImageWrapper = _styledComponents.default.div.withCo
|
|
|
66
66
|
}, (0, _animations.springScaleAnimation)(true));
|
|
67
67
|
const CTAText = exports.CTAText = _styledComponents.default.span.withConfig({
|
|
68
68
|
displayName: "CTAMultiCardstyle__CTAText",
|
|
69
|
-
componentId: "sc-
|
|
69
|
+
componentId: "sc-12iazzn-2"
|
|
70
70
|
})(["", " color:", ";font-weight:bold;text-decoration:none;position:relative;display:inline-block;"], _ref10 => {
|
|
71
71
|
let {
|
|
72
72
|
theme
|
|
@@ -80,11 +80,11 @@ const CTAText = exports.CTAText = _styledComponents.default.span.withConfig({
|
|
|
80
80
|
});
|
|
81
81
|
const CTATextUnderline = exports.CTATextUnderline = _styledComponents.default.img.withConfig({
|
|
82
82
|
displayName: "CTAMultiCardstyle__CTATextUnderline",
|
|
83
|
-
componentId: "sc-
|
|
83
|
+
componentId: "sc-12iazzn-3"
|
|
84
84
|
})(["height:4px;width:100%;position:absolute;left:0;bottom:-5px;transition:opacity 0.15s 0.1s;opacity:0;pointer-events:none;"]);
|
|
85
85
|
const ArrowIconWrapper = exports.ArrowIconWrapper = _styledComponents.default.div.withConfig({
|
|
86
86
|
displayName: "CTAMultiCardstyle__ArrowIconWrapper",
|
|
87
|
-
componentId: "sc-
|
|
87
|
+
componentId: "sc-12iazzn-4"
|
|
88
88
|
})(["width:32px;height:32px;border-radius:50%;background:", ";display:flex;align-items:center;justify-content:center;flex-shrink:0;"], _ref12 => {
|
|
89
89
|
let {
|
|
90
90
|
theme
|
|
@@ -95,7 +95,7 @@ const ArrowIconWrapper = exports.ArrowIconWrapper = _styledComponents.default.di
|
|
|
95
95
|
// Card wrapper link - makes entire card clickable
|
|
96
96
|
const CardLink = exports.CardLink = _styledComponents.default.a.withConfig({
|
|
97
97
|
displayName: "CTAMultiCardstyle__CardLink",
|
|
98
|
-
componentId: "sc-
|
|
98
|
+
componentId: "sc-12iazzn-5"
|
|
99
99
|
})(["display:flex;position:relative;flex-direction:column;width:100%;flex:1 1 auto;background:transparent;border-radius:1rem;box-shadow:0 0 1rem rgba(0,0,0,0.15);text-decoration:none;overflow:hidden;cursor:pointer;img{transform:scale(1.02);transition:transform ", "s cubic-bezier(0.68,", ",0.265,", ");}@media ", "{", ";&:hover{box-shadow:0 0 1.5rem rgba(0,0,0,0.25);", " img{transform:scale(1.1);}", "{color:", ";text-decoration:none;}", "{opacity:1;}", "{background:", ";}}}"], 0.4, -1.15, 2.35, _ref13 => {
|
|
100
100
|
let {
|
|
101
101
|
theme
|
|
@@ -114,8 +114,8 @@ const CardLink = exports.CardLink = _styledComponents.default.a.withConfig({
|
|
|
114
114
|
});
|
|
115
115
|
const CardWrapper = exports.CardWrapper = _styledComponents.default.div.withConfig({
|
|
116
116
|
displayName: "CTAMultiCardstyle__CardWrapper",
|
|
117
|
-
componentId: "sc-
|
|
118
|
-
})(["width:100%;flex-shrink:0;display:flex;flex-direction:column;align-self:stretch;", " ", " @media ", "{flex-basis:calc(50% - 1rem);max-width:564px;align-self:stretch;}@media ", "{flex-basis:unset;max-width:564px;align-self:stretch;}"], _ref16 => {
|
|
117
|
+
componentId: "sc-12iazzn-6"
|
|
118
|
+
})(["width:100%;flex-shrink:0;display:flex;flex-direction:column;align-self:stretch;", " ", " @media ", "{flex-basis:calc(50% - 1rem);max-width:564px;height:100%;align-self:stretch;}@media ", "{flex-basis:unset;max-width:564px;height:100%;align-self:stretch;}"], _ref16 => {
|
|
119
119
|
let {
|
|
120
120
|
isCarousel
|
|
121
121
|
} = _ref16;
|
|
@@ -139,7 +139,7 @@ const CardWrapper = exports.CardWrapper = _styledComponents.default.div.withConf
|
|
|
139
139
|
});
|
|
140
140
|
const CopyAndLinkSection = exports.CopyAndLinkSection = _styledComponents.default.div.withConfig({
|
|
141
141
|
displayName: "CTAMultiCardstyle__CopyAndLinkSection",
|
|
142
|
-
componentId: "sc-
|
|
142
|
+
componentId: "sc-12iazzn-7"
|
|
143
143
|
})(["width:100%;background:", ";display:flex;flex-direction:column;padding:2rem;flex:1;min-height:0;border-radius:0 0 1rem 1rem;"], _ref20 => {
|
|
144
144
|
let {
|
|
145
145
|
theme,
|
|
@@ -149,9 +149,9 @@ const CopyAndLinkSection = exports.CopyAndLinkSection = _styledComponents.defaul
|
|
|
149
149
|
});
|
|
150
150
|
const Copy = exports.Copy = _styledComponents.default.div.withConfig({
|
|
151
151
|
displayName: "CTAMultiCardstyle__Copy",
|
|
152
|
-
componentId: "sc-
|
|
152
|
+
componentId: "sc-12iazzn-8"
|
|
153
153
|
})(["flex:1;display:flex;flex-direction:column;min-height:0;"]);
|
|
154
154
|
const CTA = exports.CTA = _styledComponents.default.div.withConfig({
|
|
155
155
|
displayName: "CTAMultiCardstyle__CTA",
|
|
156
|
-
componentId: "sc-
|
|
156
|
+
componentId: "sc-12iazzn-9"
|
|
157
157
|
})(["width:100%;display:flex;flex-direction:row;align-items:center;justify-content:space-between;margin-top:auto;padding-top:1rem;"]);
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault").default;
|
|
4
|
+
Object.defineProperty(exports, "__esModule", {
|
|
5
|
+
value: true
|
|
6
|
+
});
|
|
7
|
+
exports.default = void 0;
|
|
8
|
+
var _react = _interopRequireDefault(require("react"));
|
|
9
|
+
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
10
|
+
const StyledArrowIcon = _styledComponents.default.svg.withConfig({
|
|
11
|
+
displayName: "_ArrowIcon__StyledArrowIcon",
|
|
12
|
+
componentId: "sc-181nxlj-0"
|
|
13
|
+
})(["display:inline-block;color:", ";fill:currentColor;"], _ref => {
|
|
14
|
+
let {
|
|
15
|
+
theme
|
|
16
|
+
} = _ref;
|
|
17
|
+
return theme.color('white');
|
|
18
|
+
});
|
|
19
|
+
const ArrowIcon = () => /*#__PURE__*/_react.default.createElement(StyledArrowIcon, {
|
|
20
|
+
width: "15",
|
|
21
|
+
height: "13",
|
|
22
|
+
viewBox: "0 0 15 13",
|
|
23
|
+
fill: "none",
|
|
24
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
25
|
+
}, /*#__PURE__*/_react.default.createElement("path", {
|
|
26
|
+
d: "M9.58496 0.349976C9.1395 -0.116662 8.40641 -0.116634 7.96094 0.349976C7.52803 0.803486 7.5281 1.53021 7.96094 1.98376L11.1582 5.33337H1.13672C0.48748 5.33337 0 5.87822 0 6.50037C2.15408e-05 7.1225 0.487494 7.66736 1.13672 7.66736H11.1582L7.96094 11.017C7.52806 11.4705 7.52899 12.1972 7.96191 12.6508C8.18163 12.8803 8.47556 13.0004 8.77344 13.0004C9.07114 13.0002 9.36533 12.8808 9.58496 12.6508L14.6758 7.31677L14.6748 7.3158L14.6875 7.3031L14.6865 7.30212C14.6954 7.29215 14.7044 7.28482 14.71 7.27771C14.7117 7.27545 14.7133 7.27285 14.7148 7.27087C14.7485 7.23203 14.7824 7.18925 14.8135 7.14099L14.8154 7.13806C14.8354 7.10658 14.8493 7.07842 14.8564 7.06384L14.8652 7.04626L14.8662 7.04431L14.8672 7.04333C14.8672 7.04333 14.868 7.04057 14.8691 7.03845C14.8709 7.03512 14.8758 7.02671 14.8799 7.01892L14.8802 7.01839C14.8888 7.002 14.9034 6.97423 14.917 6.93982V6.93787C14.9303 6.90375 14.9391 6.87285 14.9443 6.85388C14.9469 6.84458 14.9498 6.83567 14.9512 6.83044C14.9527 6.82454 14.9535 6.8228 14.9541 6.82068C14.9541 6.82068 14.9542 6.81753 14.9551 6.81482L14.958 6.80603L14.9586 6.80422C14.9631 6.78961 14.9718 6.76119 14.9785 6.72693V6.72498C15.0066 6.57705 15.0066 6.4246 14.9785 6.27673V6.27478L14.958 6.19568L14.9551 6.18591L14.9531 6.18005L14.9512 6.17224C14.9497 6.1664 14.9481 6.15677 14.9453 6.14685C14.9398 6.12695 14.9307 6.09654 14.917 6.06189C14.9032 6.02688 14.8885 5.99813 14.8799 5.98181C14.8758 5.97402 14.8709 5.96562 14.8691 5.96228L14.8564 5.93689C14.849 5.92177 14.8351 5.89372 14.8154 5.86267L14.8145 5.86072L14.7529 5.7738C14.7316 5.74659 14.7094 5.72129 14.6875 5.69763C14.6837 5.69341 14.6802 5.68854 14.6758 5.68396L9.58496 0.349976Z",
|
|
27
|
+
fill: "currentColor"
|
|
28
|
+
}));
|
|
29
|
+
var _default = exports.default = ArrowIcon;
|
|
@@ -317,6 +317,7 @@ exports[`handles data structure correctly 1`] = `
|
|
|
317
317
|
-ms-flex-preferred-size: calc(50% - 1rem);
|
|
318
318
|
flex-basis: calc(50% - 1rem);
|
|
319
319
|
max-width: 564px;
|
|
320
|
+
height: 100%;
|
|
320
321
|
-webkit-align-self: stretch;
|
|
321
322
|
-ms-flex-item-align: stretch;
|
|
322
323
|
align-self: stretch;
|
|
@@ -329,6 +330,7 @@ exports[`handles data structure correctly 1`] = `
|
|
|
329
330
|
-ms-flex-preferred-size: unset;
|
|
330
331
|
flex-basis: unset;
|
|
331
332
|
max-width: 564px;
|
|
333
|
+
height: 100%;
|
|
332
334
|
-webkit-align-self: stretch;
|
|
333
335
|
-ms-flex-item-align: stretch;
|
|
334
336
|
align-self: stretch;
|
|
@@ -869,6 +871,7 @@ exports[`renders 2 columns layout correctly 1`] = `
|
|
|
869
871
|
-ms-flex-preferred-size: calc(50% - 1rem);
|
|
870
872
|
flex-basis: calc(50% - 1rem);
|
|
871
873
|
max-width: 564px;
|
|
874
|
+
height: 100%;
|
|
872
875
|
-webkit-align-self: stretch;
|
|
873
876
|
-ms-flex-item-align: stretch;
|
|
874
877
|
align-self: stretch;
|
|
@@ -881,6 +884,7 @@ exports[`renders 2 columns layout correctly 1`] = `
|
|
|
881
884
|
-ms-flex-preferred-size: unset;
|
|
882
885
|
flex-basis: unset;
|
|
883
886
|
max-width: 564px;
|
|
887
|
+
height: 100%;
|
|
884
888
|
-webkit-align-self: stretch;
|
|
885
889
|
-ms-flex-item-align: stretch;
|
|
886
890
|
align-self: stretch;
|
|
@@ -1472,6 +1476,7 @@ exports[`renders carousel mode correctly 1`] = `
|
|
|
1472
1476
|
-ms-flex-preferred-size: calc(50% - 1rem);
|
|
1473
1477
|
flex-basis: calc(50% - 1rem);
|
|
1474
1478
|
max-width: 564px;
|
|
1479
|
+
height: 100%;
|
|
1475
1480
|
-webkit-align-self: stretch;
|
|
1476
1481
|
-ms-flex-item-align: stretch;
|
|
1477
1482
|
align-self: stretch;
|
|
@@ -1484,6 +1489,7 @@ exports[`renders carousel mode correctly 1`] = `
|
|
|
1484
1489
|
-ms-flex-preferred-size: unset;
|
|
1485
1490
|
flex-basis: unset;
|
|
1486
1491
|
max-width: 564px;
|
|
1492
|
+
height: 100%;
|
|
1487
1493
|
-webkit-align-self: stretch;
|
|
1488
1494
|
-ms-flex-item-align: stretch;
|
|
1489
1495
|
align-self: stretch;
|
|
@@ -2038,6 +2044,7 @@ exports[`renders correctly with data prop 1`] = `
|
|
|
2038
2044
|
-ms-flex-preferred-size: calc(50% - 1rem);
|
|
2039
2045
|
flex-basis: calc(50% - 1rem);
|
|
2040
2046
|
max-width: 564px;
|
|
2047
|
+
height: 100%;
|
|
2041
2048
|
-webkit-align-self: stretch;
|
|
2042
2049
|
-ms-flex-item-align: stretch;
|
|
2043
2050
|
align-self: stretch;
|
|
@@ -2050,6 +2057,7 @@ exports[`renders correctly with data prop 1`] = `
|
|
|
2050
2057
|
-ms-flex-preferred-size: unset;
|
|
2051
2058
|
flex-basis: unset;
|
|
2052
2059
|
max-width: 564px;
|
|
2060
|
+
height: 100%;
|
|
2053
2061
|
-webkit-align-self: stretch;
|
|
2054
2062
|
-ms-flex-item-align: stretch;
|
|
2055
2063
|
align-self: stretch;
|
package/dist/index.js
CHANGED
|
@@ -46,6 +46,12 @@ Object.defineProperty(exports, "CTAMultiCard", {
|
|
|
46
46
|
return _CTAMultiCard.default;
|
|
47
47
|
}
|
|
48
48
|
});
|
|
49
|
+
Object.defineProperty(exports, "CTASingleCard", {
|
|
50
|
+
enumerable: true,
|
|
51
|
+
get: function () {
|
|
52
|
+
return _CTASingleCard.default;
|
|
53
|
+
}
|
|
54
|
+
});
|
|
49
55
|
Object.defineProperty(exports, "Card", {
|
|
50
56
|
enumerable: true,
|
|
51
57
|
get: function () {
|
|
@@ -475,7 +481,8 @@ var _InfoBanner = _interopRequireDefault(require("./components/Molecules/InfoBan
|
|
|
475
481
|
var _SingleMessage = _interopRequireDefault(require("./components/Molecules/SingleMessage/SingleMessage"));
|
|
476
482
|
var _Card = _interopRequireDefault(require("./components/Molecules/Card/Card"));
|
|
477
483
|
var _CardDs = _interopRequireDefault(require("./components/Molecules/CardDs/CardDs"));
|
|
478
|
-
var _CTAMultiCard = _interopRequireDefault(require("./components/Molecules/CTAMultiCard/CTAMultiCard"));
|
|
484
|
+
var _CTAMultiCard = _interopRequireDefault(require("./components/Molecules/CTA/CTAMultiCard/CTAMultiCard"));
|
|
485
|
+
var _CTASingleCard = _interopRequireDefault(require("./components/Molecules/CTA/CTASingleCard/CTASingleCard"));
|
|
479
486
|
var _Box = _interopRequireDefault(require("./components/Molecules/Box/Box"));
|
|
480
487
|
var _ArticleTeaser = _interopRequireDefault(require("./components/Molecules/ArticleTeaser/ArticleTeaser"));
|
|
481
488
|
var _Header = _interopRequireDefault(require("./components/Organisms/Header/Header"));
|
package/package.json
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import React, { useState } from 'react';
|
|
2
2
|
import PropTypes from 'prop-types';
|
|
3
3
|
import styled, { css, keyframes } from 'styled-components';
|
|
4
|
+
import Text from '../../Atoms/Text/Text';
|
|
4
5
|
|
|
5
6
|
import spacing from '../../../theme/shared/spacing';
|
|
6
7
|
import { Chevron } from '../../Atoms/Icons/index';
|
|
@@ -72,6 +73,10 @@ const Copy = styled.div`
|
|
|
72
73
|
`)}
|
|
73
74
|
`;
|
|
74
75
|
|
|
76
|
+
const StyledText = styled(Text)`
|
|
77
|
+
margin-bottom: 0;
|
|
78
|
+
`;
|
|
79
|
+
|
|
75
80
|
const Accordion = ({
|
|
76
81
|
children, title, contentBottomPadding, ...rest
|
|
77
82
|
}) => {
|
|
@@ -84,7 +89,9 @@ const Accordion = ({
|
|
|
84
89
|
return (
|
|
85
90
|
<Container {...rest}>
|
|
86
91
|
<Button onClick={handleOpen} aria-expanded={isOpen ? 'true' : 'false'} ChevronKeyframes={ChevronKeyframes} type="button">
|
|
87
|
-
|
|
92
|
+
<StyledText tag="h3">
|
|
93
|
+
{title}
|
|
94
|
+
</StyledText>
|
|
88
95
|
<Icon>
|
|
89
96
|
<Chevron colour="black" direction={isOpen ? 'up' : 'down'} />
|
|
90
97
|
</Icon>
|