@pareto-engineering/design-system 0.0.1-alpha.60 → 0.0.1-alpha.64
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/cjs/a/TeamInfo/TeamInfo.js +1 -1
- package/dist/cjs/a/TeamInfo/styles.scss +3 -2
- package/dist/cjs/b/QuestionDropdown/QuestionDropdown.js +11 -4
- package/dist/cjs/c/index.js +1 -125
- package/dist/cjs/f/fields/SelectInput/styles.scss +7 -3
- package/dist/es/a/TeamInfo/TeamInfo.js +1 -1
- package/dist/es/a/TeamInfo/styles.scss +3 -2
- package/dist/es/b/QuestionDropdown/QuestionDropdown.js +11 -4
- package/dist/es/c/index.js +1 -15
- package/dist/es/f/fields/SelectInput/styles.scss +7 -3
- package/package.json +3 -3
- package/src/__snapshots__/Storyshots.test.js.snap +251 -1831
- package/src/stories/b/QuestionDropdown.stories.jsx +15 -0
- package/src/stories/colors.js +1 -1
- package/src/stories/f/SelectInput.stories.jsx +3 -7
- package/src/ui/a/TeamInfo/TeamInfo.jsx +1 -1
- package/src/ui/a/TeamInfo/styles.scss +3 -2
- package/src/ui/b/QuestionDropdown/QuestionDropdown.jsx +8 -3
- package/src/ui/c/index.js +0 -18
- package/src/ui/f/fields/SelectInput/styles.scss +7 -3
- package/dist/cjs/a/RatingsInput/RatingsInput.js +0 -88
- package/dist/cjs/a/RatingsInput/common/Rating/Rating.js +0 -120
- package/dist/cjs/a/RatingsInput/common/Rating/index.js +0 -15
- package/dist/cjs/a/RatingsInput/common/index.js +0 -13
- package/dist/cjs/a/RatingsInput/index.js +0 -15
- package/dist/cjs/a/RatingsInput/styles.scss +0 -35
- package/dist/es/a/RatingsInput/RatingsInput.js +0 -72
- package/dist/es/a/RatingsInput/common/Rating/Rating.js +0 -102
- package/dist/es/a/RatingsInput/common/Rating/index.js +0 -2
- package/dist/es/a/RatingsInput/common/index.js +0 -1
- package/dist/es/a/RatingsInput/index.js +0 -2
- package/dist/es/a/RatingsInput/styles.scss +0 -35
- package/src/stories/c/AcceptCookies.stories.jsx +0 -27
- package/src/stories/c/BlogCategoryButton.stories.jsx +0 -33
- package/src/stories/c/BlogPost.stories.jsx +0 -68
- package/src/stories/c/BlogPostsList.stories.jsx +0 -91
- package/src/stories/c/SiteFooter.stories.jsx +0 -33
- package/src/stories/c/SiteHeaderCTA.stories.jsx +0 -28
- package/src/stories/c/SiteMission.stories.jsx +0 -78
- package/src/stories/c/SiteNavigation.stories.jsx +0 -79
- package/src/stories/c/SiteOnboardingStep.stories.jsx +0 -46
- package/src/stories/c/SitePricing.stories.jsx +0 -48
- package/src/stories/c/SiteServices.stories.jsx +0 -170
- package/src/stories/c/TeamGallery.stories.jsx +0 -52
- package/src/stories/c/Testimonials.stories.jsx +0 -43
- package/src/stories/c/blogUrlMap.js +0 -13
- package/src/ui/c/AcceptCookies/AcceptCookies.jsx +0 -133
- package/src/ui/c/AcceptCookies/index.js +0 -2
- package/src/ui/c/AcceptCookies/styles.scss +0 -49
- package/src/ui/c/BlogCategoryButton/BlogCategoryButton.jsx +0 -96
- package/src/ui/c/BlogCategoryButton/index.js +0 -2
- package/src/ui/c/BlogContext/BlogContextProvider.jsx +0 -60
- package/src/ui/c/BlogContext/Context.js +0 -3
- package/src/ui/c/BlogContext/ContextProvider.jsx +0 -60
- package/src/ui/c/BlogContext/index.js +0 -4
- package/src/ui/c/BlogContext/useBlog.js +0 -4
- package/src/ui/c/BlogPost/BlogPost.jsx +0 -161
- package/src/ui/c/BlogPost/index.js +0 -2
- package/src/ui/c/BlogPost/styles.scss +0 -33
- package/src/ui/c/BlogPostsList/BlogPostsList.jsx +0 -81
- package/src/ui/c/BlogPostsList/common/Card/Card.jsx +0 -195
- package/src/ui/c/BlogPostsList/common/Card/index.js +0 -2
- package/src/ui/c/BlogPostsList/common/index.js +0 -1
- package/src/ui/c/BlogPostsList/index.js +0 -2
- package/src/ui/c/BlogPostsList/styles.scss +0 -72
- package/src/ui/c/SiteFooter/SiteFooter.jsx +0 -79
- package/src/ui/c/SiteFooter/common/Section/Section.jsx +0 -95
- package/src/ui/c/SiteFooter/common/Section/index.js +0 -2
- package/src/ui/c/SiteFooter/common/index.js +0 -1
- package/src/ui/c/SiteFooter/index.js +0 -2
- package/src/ui/c/SiteFooter/styles.scss +0 -34
- package/src/ui/c/SiteHeaderCTA/SiteHeaderCTA.jsx +0 -107
- package/src/ui/c/SiteHeaderCTA/index.js +0 -2
- package/src/ui/c/SiteHeaderCTA/styles.scss +0 -44
- package/src/ui/c/SiteMission/SiteMission.jsx +0 -114
- package/src/ui/c/SiteMission/index.js +0 -2
- package/src/ui/c/SiteMission/styles.scss +0 -30
- package/src/ui/c/SiteNavigation/SiteNavigation.jsx +0 -142
- package/src/ui/c/SiteNavigation/index.js +0 -2
- package/src/ui/c/SiteNavigation/styles.scss +0 -118
- package/src/ui/c/SiteOnboardingStep/SiteOnboardingStep.jsx +0 -107
- package/src/ui/c/SiteOnboardingStep/index.js +0 -2
- package/src/ui/c/SiteOnboardingStep/styles.scss +0 -51
- package/src/ui/c/SitePricing/SitePricing.jsx +0 -120
- package/src/ui/c/SitePricing/index.js +0 -2
- package/src/ui/c/SitePricing/styles.scss +0 -73
- package/src/ui/c/SiteServices/SiteServices.jsx +0 -222
- package/src/ui/c/SiteServices/index.js +0 -2
- package/src/ui/c/SiteServices/styles.scss +0 -138
- package/src/ui/c/TeamGallery/TeamGallery.jsx +0 -87
- package/src/ui/c/TeamGallery/common/PersonCard/PersonCard.jsx +0 -86
- package/src/ui/c/TeamGallery/common/PersonCard/index.js +0 -2
- package/src/ui/c/TeamGallery/common/index.js +0 -1
- package/src/ui/c/TeamGallery/index.js +0 -2
- package/src/ui/c/TeamGallery/styles.scss +0 -100
- package/src/ui/c/Testimonials/Testimonials.jsx +0 -124
- package/src/ui/c/Testimonials/index.js +0 -2
- package/src/ui/c/Testimonials/styles.scss +0 -112
|
@@ -1,138 +0,0 @@
|
|
|
1
|
-
/* @pareto-engineering/generator-front 1.0.12 */
|
|
2
|
-
|
|
3
|
-
@use "@pareto-engineering/bem";
|
|
4
|
-
@use "@aztlan/stylebook/src/mixins";
|
|
5
|
-
@use "@aztlan/stylebook/src/globals" as *;
|
|
6
|
-
|
|
7
|
-
$service-btn-color:var(--on-y);
|
|
8
|
-
$tasks-btn-width: 12em;
|
|
9
|
-
$tasks-btn-height: 6em;
|
|
10
|
-
$gap:2em;
|
|
11
|
-
$active-btn-border-v:5px solid transparent;
|
|
12
|
-
$active-btn-border-top:5px solid var(--on-y);
|
|
13
|
-
$active-task-bg:var(--dark-y);
|
|
14
|
-
$email-content-border-bottom:1px solid var(-metadata);
|
|
15
|
-
$btn-content-width:75%;
|
|
16
|
-
$tasks-and-content-sm-width:100%;
|
|
17
|
-
$btn-content-sm-width:100%;
|
|
18
|
-
$tasks-and-content-width:80%;
|
|
19
|
-
$active-btn-left:48%;
|
|
20
|
-
$active-btn-top:100%;
|
|
21
|
-
$box-shadow:0 2px 2px 0 var(--background2);
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
.#{bem.$base}.services {
|
|
25
|
-
@mixin common-button-styles {
|
|
26
|
-
border: 0;
|
|
27
|
-
cursor: pointer;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
.btn-content {
|
|
31
|
-
column-gap: $gap;
|
|
32
|
-
display: grid;
|
|
33
|
-
grid-template-columns: repeat(4, 1fr);
|
|
34
|
-
margin: var(--v) auto;
|
|
35
|
-
width: $btn-content-width;
|
|
36
|
-
|
|
37
|
-
button {
|
|
38
|
-
@include common-button-styles;
|
|
39
|
-
background: none;
|
|
40
|
-
color: $service-btn-color;
|
|
41
|
-
text-transform: capitalize;
|
|
42
|
-
transition: all .1s;
|
|
43
|
-
|
|
44
|
-
&:hover {
|
|
45
|
-
transform: scale(1.1);
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
.active-service-btn {
|
|
52
|
-
transform: scale(1.1);
|
|
53
|
-
|
|
54
|
-
&::after {
|
|
55
|
-
border-left: $active-btn-border-v;
|
|
56
|
-
border-right: $active-btn-border-v;
|
|
57
|
-
border-top: $active-btn-border-top;
|
|
58
|
-
color: $service-btn-color;
|
|
59
|
-
content: "";
|
|
60
|
-
left: $active-btn-left;
|
|
61
|
-
position: absolute;
|
|
62
|
-
top: $active-btn-top;
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
.tasks-and-content {
|
|
68
|
-
column-gap: $gap;
|
|
69
|
-
display: grid;
|
|
70
|
-
grid-template-columns: 1fr 4fr;
|
|
71
|
-
margin: 0 auto;
|
|
72
|
-
width: $tasks-and-content-width;
|
|
73
|
-
}
|
|
74
|
-
|
|
75
|
-
.tasks {
|
|
76
|
-
align-items: center;
|
|
77
|
-
display: flex;
|
|
78
|
-
flex-direction: column;
|
|
79
|
-
justify-content: space-between;
|
|
80
|
-
|
|
81
|
-
button {
|
|
82
|
-
@include common-button-styles;
|
|
83
|
-
align-items: center;
|
|
84
|
-
border-radius: var(--theme-border-radius);
|
|
85
|
-
display: flex;
|
|
86
|
-
height: $tasks-btn-height;
|
|
87
|
-
width: $tasks-btn-width;
|
|
88
|
-
transition: background-color 0.5s ease-out;
|
|
89
|
-
p {
|
|
90
|
-
color: inherit;
|
|
91
|
-
}
|
|
92
|
-
}
|
|
93
|
-
}
|
|
94
|
-
|
|
95
|
-
.task-email {
|
|
96
|
-
//box-shadow: $box-shadow;
|
|
97
|
-
display: flex;
|
|
98
|
-
flex-direction: column;
|
|
99
|
-
justify-content: space-between;
|
|
100
|
-
|
|
101
|
-
.email-content {
|
|
102
|
-
border-bottom: $email-content-border-bottom;
|
|
103
|
-
color: var(--black);
|
|
104
|
-
}
|
|
105
|
-
|
|
106
|
-
.task-email-footer {
|
|
107
|
-
align-items: center;
|
|
108
|
-
display: flex;
|
|
109
|
-
justify-content: space-between;
|
|
110
|
-
}
|
|
111
|
-
}
|
|
112
|
-
|
|
113
|
-
@include mixins.media($to:$sm-md) {
|
|
114
|
-
padding: var(--v);
|
|
115
|
-
|
|
116
|
-
.tasks-and-content {
|
|
117
|
-
grid-template-columns: 1fr;
|
|
118
|
-
margin: 0 auto;
|
|
119
|
-
width: $tasks-and-content-sm-width;
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
.btn-content {
|
|
123
|
-
column-gap: var(--v);
|
|
124
|
-
width: $btn-content-sm-width;
|
|
125
|
-
}
|
|
126
|
-
|
|
127
|
-
.tasks {
|
|
128
|
-
display: none;
|
|
129
|
-
}
|
|
130
|
-
|
|
131
|
-
.task-email-footer {
|
|
132
|
-
display: flex;
|
|
133
|
-
flex-direction: column;
|
|
134
|
-
}
|
|
135
|
-
}
|
|
136
|
-
}
|
|
137
|
-
|
|
138
|
-
|
|
@@ -1,87 +0,0 @@
|
|
|
1
|
-
/* @pareto-engineering/generator-front 1.0.2 */
|
|
2
|
-
import * as React from 'react'
|
|
3
|
-
import { useLayoutEffect } from 'react'
|
|
4
|
-
import PropTypes from 'prop-types'
|
|
5
|
-
|
|
6
|
-
import styleNames from '@pareto-engineering/bem'
|
|
7
|
-
|
|
8
|
-
// Imports from the component folder
|
|
9
|
-
import { PersonCard } from './common'
|
|
10
|
-
|
|
11
|
-
// Local Definitions
|
|
12
|
-
|
|
13
|
-
// import('./styles.scss')
|
|
14
|
-
|
|
15
|
-
const baseClassName = styleNames.base
|
|
16
|
-
|
|
17
|
-
const componentClassName = 'team-gallery'
|
|
18
|
-
|
|
19
|
-
const TeamGallery = ({
|
|
20
|
-
id,
|
|
21
|
-
className:userClassName,
|
|
22
|
-
style,
|
|
23
|
-
children,
|
|
24
|
-
title,
|
|
25
|
-
// ...otherProps
|
|
26
|
-
}) => {
|
|
27
|
-
useLayoutEffect(() => {
|
|
28
|
-
import('./styles.scss')
|
|
29
|
-
}, [])
|
|
30
|
-
return (
|
|
31
|
-
<div
|
|
32
|
-
id={id}
|
|
33
|
-
className={[
|
|
34
|
-
|
|
35
|
-
baseClassName,
|
|
36
|
-
|
|
37
|
-
componentClassName,
|
|
38
|
-
userClassName,
|
|
39
|
-
]
|
|
40
|
-
.filter((e) => e)
|
|
41
|
-
.join(' ')}
|
|
42
|
-
style={style}
|
|
43
|
-
>
|
|
44
|
-
<div className="title">
|
|
45
|
-
{title}
|
|
46
|
-
</div>
|
|
47
|
-
<div className="content">
|
|
48
|
-
{children}
|
|
49
|
-
</div>
|
|
50
|
-
</div>
|
|
51
|
-
)
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
TeamGallery.propTypes = {
|
|
55
|
-
/**
|
|
56
|
-
* The HTML id for this element
|
|
57
|
-
*/
|
|
58
|
-
id:PropTypes.string,
|
|
59
|
-
|
|
60
|
-
/**
|
|
61
|
-
* The HTML class names for this element
|
|
62
|
-
*/
|
|
63
|
-
className:PropTypes.string,
|
|
64
|
-
|
|
65
|
-
/**
|
|
66
|
-
* The React-written, css properties for this element.
|
|
67
|
-
*/
|
|
68
|
-
style:PropTypes.objectOf(PropTypes.string),
|
|
69
|
-
|
|
70
|
-
/**
|
|
71
|
-
* The children JSX
|
|
72
|
-
*/
|
|
73
|
-
children:PropTypes.node.isRequired,
|
|
74
|
-
|
|
75
|
-
/**
|
|
76
|
-
* Title of gallery
|
|
77
|
-
*/
|
|
78
|
-
title:PropTypes.string.isRequired,
|
|
79
|
-
}
|
|
80
|
-
|
|
81
|
-
TeamGallery.defaultProps = {
|
|
82
|
-
// someProp:false
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
TeamGallery.PersonCard = PersonCard
|
|
86
|
-
|
|
87
|
-
export default TeamGallery
|
|
@@ -1,86 +0,0 @@
|
|
|
1
|
-
/* @pareto-engineering/generator-front 1.0.2 */
|
|
2
|
-
import * as React from 'react'
|
|
3
|
-
import PropTypes from 'prop-types'
|
|
4
|
-
|
|
5
|
-
import styleNames from '@pareto-engineering/bem'
|
|
6
|
-
|
|
7
|
-
// Imports from the component folder
|
|
8
|
-
|
|
9
|
-
// Local Definitions
|
|
10
|
-
|
|
11
|
-
const baseClassName = styleNames.base
|
|
12
|
-
|
|
13
|
-
const componentClassName = 'person-card'
|
|
14
|
-
|
|
15
|
-
const PersonCard = ({
|
|
16
|
-
id,
|
|
17
|
-
className:userClassName,
|
|
18
|
-
style,
|
|
19
|
-
|
|
20
|
-
name,
|
|
21
|
-
position,
|
|
22
|
-
picture,
|
|
23
|
-
|
|
24
|
-
// ...otherProps
|
|
25
|
-
}) => (
|
|
26
|
-
<div
|
|
27
|
-
id={id}
|
|
28
|
-
className={[
|
|
29
|
-
|
|
30
|
-
baseClassName,
|
|
31
|
-
|
|
32
|
-
componentClassName,
|
|
33
|
-
userClassName,
|
|
34
|
-
]
|
|
35
|
-
.filter((e) => e)
|
|
36
|
-
.join(' ')}
|
|
37
|
-
style={style}
|
|
38
|
-
>
|
|
39
|
-
<header>
|
|
40
|
-
<img src={picture} alt="" />
|
|
41
|
-
</header>
|
|
42
|
-
<main>
|
|
43
|
-
<p className="name"><strong>{ name }</strong></p>
|
|
44
|
-
<p className="position">{ position }</p>
|
|
45
|
-
</main>
|
|
46
|
-
</div>
|
|
47
|
-
)
|
|
48
|
-
|
|
49
|
-
PersonCard.propTypes = {
|
|
50
|
-
/**
|
|
51
|
-
* The HTML id for this element
|
|
52
|
-
*/
|
|
53
|
-
id:PropTypes.string,
|
|
54
|
-
|
|
55
|
-
/**
|
|
56
|
-
* The HTML class names for this element
|
|
57
|
-
*/
|
|
58
|
-
className:PropTypes.string,
|
|
59
|
-
|
|
60
|
-
/**
|
|
61
|
-
* The React-written, css properties for this element.
|
|
62
|
-
*/
|
|
63
|
-
style:PropTypes.objectOf(PropTypes.string),
|
|
64
|
-
|
|
65
|
-
/**
|
|
66
|
-
* The name of the person.
|
|
67
|
-
*/
|
|
68
|
-
name:PropTypes.string.isRequired,
|
|
69
|
-
|
|
70
|
-
/**
|
|
71
|
-
* The position of the person.
|
|
72
|
-
*/
|
|
73
|
-
position:PropTypes.string.isRequired,
|
|
74
|
-
|
|
75
|
-
/**
|
|
76
|
-
* The picture of the person.
|
|
77
|
-
*/
|
|
78
|
-
picture:PropTypes.string.isRequired,
|
|
79
|
-
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
PersonCard.defaultProps = {
|
|
83
|
-
// someProp:false
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
export default PersonCard
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { PersonCard } from './PersonCard'
|
|
@@ -1,100 +0,0 @@
|
|
|
1
|
-
/* @pareto-engineering/generator-front 1.0.2 */
|
|
2
|
-
|
|
3
|
-
@use "@pareto-engineering/bem";
|
|
4
|
-
@use "@aztlan/stylebook/src/mixins";
|
|
5
|
-
@use "@aztlan/stylebook/src/globals" as *;
|
|
6
|
-
|
|
7
|
-
$base-padding:1em;
|
|
8
|
-
|
|
9
|
-
$column-title-width-md:200px;
|
|
10
|
-
$content-grid-gap:$base-padding;
|
|
11
|
-
$content-padding:$base-padding;
|
|
12
|
-
$image-height-sm: 10em;
|
|
13
|
-
$image-height-md: 11em;
|
|
14
|
-
$picture-border-radius:.5em;
|
|
15
|
-
|
|
16
|
-
.#{bem.$base}.team-gallery {
|
|
17
|
-
display: grid;
|
|
18
|
-
|
|
19
|
-
@include mixins.media($to:$sm-md) {
|
|
20
|
-
grid-template-columns: 1fr;
|
|
21
|
-
|
|
22
|
-
.title {
|
|
23
|
-
text-align: center;
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
@include mixins.media($from:$sm-md) {
|
|
28
|
-
grid-template-columns: [title] $column-title-width-md [content] 1fr;
|
|
29
|
-
|
|
30
|
-
.title {
|
|
31
|
-
grid-column-start: title;
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
.content {
|
|
35
|
-
grid-column-start: content;
|
|
36
|
-
}
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
.title {
|
|
40
|
-
padding: $base-padding;
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
.content {
|
|
44
|
-
display: grid;
|
|
45
|
-
grid-gap: $content-grid-gap;
|
|
46
|
-
padding: $content-padding;
|
|
47
|
-
@include mixins.media($to:$sm-md) {
|
|
48
|
-
grid-template-columns: repeat(auto-fill, minmax(125px, 1fr));
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
@include mixins.media($from:$sm-md) {
|
|
52
|
-
grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
.#{bem.$base}.team-gallery .#{bem.$base}.person-card {
|
|
58
|
-
background: transparent;
|
|
59
|
-
|
|
60
|
-
> header {
|
|
61
|
-
img {
|
|
62
|
-
border-radius: $picture-border-radius;
|
|
63
|
-
filter: grayscale(100%);
|
|
64
|
-
object-fit: cover;
|
|
65
|
-
width: 100%;
|
|
66
|
-
}
|
|
67
|
-
}
|
|
68
|
-
|
|
69
|
-
> main {
|
|
70
|
-
padding: $base-padding;
|
|
71
|
-
text-align: center;
|
|
72
|
-
|
|
73
|
-
.name {
|
|
74
|
-
font-size: calc(var(--s0) * 1rem);
|
|
75
|
-
margin: 0 0 $base-padding/2 0;
|
|
76
|
-
}
|
|
77
|
-
|
|
78
|
-
.position {
|
|
79
|
-
color: var(--light-paragraph);
|
|
80
|
-
font-family: var(--font-paragraph);
|
|
81
|
-
margin: 0 0 0 0;
|
|
82
|
-
}
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
@include mixins.media($to:$sm-md) {
|
|
86
|
-
> header {
|
|
87
|
-
img {
|
|
88
|
-
height: $image-height-sm;
|
|
89
|
-
}
|
|
90
|
-
}
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
@include mixins.media($from:$sm-md) {
|
|
94
|
-
> header {
|
|
95
|
-
img {
|
|
96
|
-
height: $image-height-md;
|
|
97
|
-
}
|
|
98
|
-
}
|
|
99
|
-
}
|
|
100
|
-
}
|
|
@@ -1,124 +0,0 @@
|
|
|
1
|
-
/* @pareto-engineering/generator-front 1.0.12 */
|
|
2
|
-
import * as React from 'react'
|
|
3
|
-
|
|
4
|
-
import { useLayoutEffect } from 'react'
|
|
5
|
-
|
|
6
|
-
import { Swiper, SwiperSlide } from 'swiper/react'
|
|
7
|
-
|
|
8
|
-
import SwiperCore, { Navigation, Pagination, Autoplay } from 'swiper'
|
|
9
|
-
|
|
10
|
-
import PropTypes from 'prop-types'
|
|
11
|
-
|
|
12
|
-
import styleNames from '@pareto-engineering/bem'
|
|
13
|
-
|
|
14
|
-
// import 'swiper/swiper-bundle.css'
|
|
15
|
-
|
|
16
|
-
// Local Definitions
|
|
17
|
-
|
|
18
|
-
const baseClassName = styleNames.base
|
|
19
|
-
|
|
20
|
-
const componentClassName = 'testimonials'
|
|
21
|
-
|
|
22
|
-
SwiperCore.use([Navigation, Pagination, Autoplay])
|
|
23
|
-
/**
|
|
24
|
-
* This is the component description.
|
|
25
|
-
*/
|
|
26
|
-
const Testimonials = ({
|
|
27
|
-
id,
|
|
28
|
-
className:userClassName,
|
|
29
|
-
style,
|
|
30
|
-
// children,
|
|
31
|
-
contentMap,
|
|
32
|
-
color,
|
|
33
|
-
// ...otherProps
|
|
34
|
-
}) => {
|
|
35
|
-
useLayoutEffect(() => {
|
|
36
|
-
import('./styles.scss')
|
|
37
|
-
}, [])
|
|
38
|
-
|
|
39
|
-
return (
|
|
40
|
-
<div
|
|
41
|
-
id={id}
|
|
42
|
-
className={[
|
|
43
|
-
baseClassName,
|
|
44
|
-
componentClassName,
|
|
45
|
-
userClassName,
|
|
46
|
-
'u3',
|
|
47
|
-
`x-${color}`,
|
|
48
|
-
]
|
|
49
|
-
.filter((e) => e)
|
|
50
|
-
.join(' ')}
|
|
51
|
-
style={style}
|
|
52
|
-
// {...otherProps}
|
|
53
|
-
>
|
|
54
|
-
|
|
55
|
-
<Swiper
|
|
56
|
-
loop
|
|
57
|
-
navigation
|
|
58
|
-
pagination
|
|
59
|
-
spaceBetween={0}
|
|
60
|
-
slidesPerView={1}
|
|
61
|
-
autoplay={{ delay: 5000 }}
|
|
62
|
-
>
|
|
63
|
-
{contentMap.map((slide) => (
|
|
64
|
-
<SwiperSlide key={`${slide.firstName}${slide.lastName}`}>
|
|
65
|
-
<div className="slide s-1 md-s0 u4 md-u3 md-v3 v1 pv-u ph-v">
|
|
66
|
-
<span className="openning-quote">
|
|
67
|
-
“
|
|
68
|
-
</span>
|
|
69
|
-
<img className="img" src={slide.picture} alt="" />
|
|
70
|
-
<span className="name v50 mt-v">{`${slide.firstName} ${slide.lastName}`}</span>
|
|
71
|
-
<span className="company v50 mb-v s-1">{slide.company}</span>
|
|
72
|
-
<p className="uc s1 testimonial-content">{slide.testimonial}</p>
|
|
73
|
-
<span className="closing-quote">
|
|
74
|
-
”
|
|
75
|
-
</span>
|
|
76
|
-
</div>
|
|
77
|
-
</SwiperSlide>
|
|
78
|
-
))}
|
|
79
|
-
</Swiper>
|
|
80
|
-
</div>
|
|
81
|
-
|
|
82
|
-
)
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
Testimonials.propTypes = {
|
|
86
|
-
/**
|
|
87
|
-
* The HTML id for this element
|
|
88
|
-
*/
|
|
89
|
-
id:PropTypes.string,
|
|
90
|
-
|
|
91
|
-
/**
|
|
92
|
-
* The HTML class names for this element
|
|
93
|
-
*/
|
|
94
|
-
className:PropTypes.string,
|
|
95
|
-
|
|
96
|
-
/**
|
|
97
|
-
* The React-written, css properties for this element.
|
|
98
|
-
*/
|
|
99
|
-
style:PropTypes.objectOf(PropTypes.string),
|
|
100
|
-
|
|
101
|
-
/**
|
|
102
|
-
* The testimonial color
|
|
103
|
-
*/
|
|
104
|
-
color:PropTypes.string,
|
|
105
|
-
|
|
106
|
-
/**
|
|
107
|
-
* The testimonial map
|
|
108
|
-
*/
|
|
109
|
-
contentMap:PropTypes.arrayOf(
|
|
110
|
-
PropTypes.shape({
|
|
111
|
-
firstName :PropTypes.string.isRequired,
|
|
112
|
-
lastName :PropTypes.string.isRequired,
|
|
113
|
-
picture :PropTypes.string.isRequired,
|
|
114
|
-
company :PropTypes.string.isRequired,
|
|
115
|
-
testimonial:PropTypes.string.isRequired,
|
|
116
|
-
}),
|
|
117
|
-
).isRequired,
|
|
118
|
-
}
|
|
119
|
-
|
|
120
|
-
Testimonials.defaultProps = {
|
|
121
|
-
color:'main1',
|
|
122
|
-
}
|
|
123
|
-
|
|
124
|
-
export default Testimonials
|