@salesforcedevs/mrkt-components 1.3.393 → 1.4.0
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/lwc.config.json
CHANGED
package/package.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@salesforcedevs/mrkt-components",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.4.0",
|
|
4
4
|
"description": "Marketing Lightning web components for DSC",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"engines": {
|
|
7
|
-
"node": "18.
|
|
7
|
+
"node": "18.x"
|
|
8
8
|
},
|
|
9
9
|
"publishConfig": {
|
|
10
10
|
"access": "public"
|
|
@@ -15,5 +15,5 @@
|
|
|
15
15
|
"devDependencies": {
|
|
16
16
|
"@types/classnames": "2.3.1"
|
|
17
17
|
},
|
|
18
|
-
"gitHead": "
|
|
18
|
+
"gitHead": "052e1a61657dec2c9299570814e2d7c561517fe2"
|
|
19
19
|
}
|
|
@@ -0,0 +1,188 @@
|
|
|
1
|
+
@import "dxHelpers/reset";
|
|
2
|
+
@import "dxHelpers/text";
|
|
3
|
+
|
|
4
|
+
:host {
|
|
5
|
+
--padding-vertical: 108px;
|
|
6
|
+
--mrkt-c-two-col-list-section-padding-top: var(--padding-vertical);
|
|
7
|
+
--mrkt-c-two-col-list-section-padding-bottom: var(--padding-vertical);
|
|
8
|
+
--mrkt-c-two-col-list-section-align-items: center;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
.two-col-card-section {
|
|
12
|
+
width: 100%;
|
|
13
|
+
position: relative;
|
|
14
|
+
z-index: 12;
|
|
15
|
+
padding: var(--mrkt-c-two-col-list-section-padding-top)
|
|
16
|
+
var(--dx-g-page-padding-horizontal)
|
|
17
|
+
var(--mrkt-c-two-col-list-section-padding-bottom)
|
|
18
|
+
var(--dx-g-page-padding-horizontal);
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.large-card {
|
|
22
|
+
position: relative;
|
|
23
|
+
margin: 0 auto;
|
|
24
|
+
display: flex;
|
|
25
|
+
justify-content: space-between;
|
|
26
|
+
background: white;
|
|
27
|
+
box-shadow: var(--dx-g-box-shadow-sm);
|
|
28
|
+
border-radius: 16px;
|
|
29
|
+
max-width: 1140px;
|
|
30
|
+
width: 100%;
|
|
31
|
+
padding: 40px 100px;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.label {
|
|
35
|
+
color: var(--dx-g-gray-30);
|
|
36
|
+
margin-bottom: var(--dx-g-spacing-md);
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.subtitle {
|
|
40
|
+
font-size: 16px;
|
|
41
|
+
font-family: var(--dx-g-font-display);
|
|
42
|
+
line-height: 24px;
|
|
43
|
+
font-weight: 600;
|
|
44
|
+
letter-spacing: 0.5;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
.text-container {
|
|
48
|
+
display: flex;
|
|
49
|
+
flex-direction: column;
|
|
50
|
+
padding-right: 80px;
|
|
51
|
+
width: 50%;
|
|
52
|
+
z-index: 1;
|
|
53
|
+
margin-top: var(--dx-g-spacing-md);
|
|
54
|
+
padding-bottom: var(--dx-g-spacing-md);
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
.text-container > * {
|
|
58
|
+
max-width: 500px;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
.text-container > *:not(:last-child) {
|
|
62
|
+
margin-bottom: var(--dx-g-spacing-lg);
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
.title {
|
|
66
|
+
margin-bottom: var(--dx-g-spacing-xs) !important;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
.cta-group {
|
|
70
|
+
width: fit-content;
|
|
71
|
+
flex-direction: column;
|
|
72
|
+
gap: var(--dx-g-spacing-md);
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
.main-cta {
|
|
76
|
+
--dx-c-button-font-weight: var(--dx-g-font-bold);
|
|
77
|
+
--dx-c-button-font-size: var(--dx-g-text-base);
|
|
78
|
+
--dx-c-button-horizontal-spacing: var(--dx-g-spacing-xl);
|
|
79
|
+
|
|
80
|
+
margin-top: var(--dx-g-spacing-sm);
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
.modal-cta {
|
|
84
|
+
--dx-c-button-font-size: var(--dx-g-text-sm);
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
img {
|
|
88
|
+
position: absolute;
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
.graphic-1 {
|
|
92
|
+
width: 306px;
|
|
93
|
+
bottom: 50px;
|
|
94
|
+
left: -50px;
|
|
95
|
+
z-index: -1;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
.graphic-2 {
|
|
99
|
+
width: 150px;
|
|
100
|
+
top: 0;
|
|
101
|
+
left: calc(100% - 110px);
|
|
102
|
+
z-index: -1;
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
.graphic-3 {
|
|
106
|
+
width: 142px;
|
|
107
|
+
right: 50px;
|
|
108
|
+
bottom: -73px;
|
|
109
|
+
z-index: -1;
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
.graphic-swoop {
|
|
113
|
+
position: relative;
|
|
114
|
+
width: 100%;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
.mobile-button {
|
|
118
|
+
display: none;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
.desktop-button {
|
|
122
|
+
display: flex;
|
|
123
|
+
align-items: center;
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
@media (max-width: 1024px) {
|
|
127
|
+
:host {
|
|
128
|
+
--padding-vertical: var(--dx-g-spacing-3xl);
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
.title {
|
|
132
|
+
font-size: var(--dx-g-text-2xl);
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
.body {
|
|
136
|
+
font-size: var(--dx-g-text-base);
|
|
137
|
+
line-height: 20px;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
.text-container {
|
|
141
|
+
width: 100%;
|
|
142
|
+
text-align: left;
|
|
143
|
+
justify-content: center;
|
|
144
|
+
align-items: left;
|
|
145
|
+
padding-right: unset;
|
|
146
|
+
max-width: 380px;
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
.graphic-1,
|
|
150
|
+
.graphic-2,
|
|
151
|
+
.graphic-3 {
|
|
152
|
+
display: none;
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
.large-card {
|
|
156
|
+
display: flex;
|
|
157
|
+
flex-direction: column;
|
|
158
|
+
width: 100%;
|
|
159
|
+
max-width: 500px;
|
|
160
|
+
align-items: center;
|
|
161
|
+
padding-left: 20px;
|
|
162
|
+
padding-right: 20px;
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
.card-container {
|
|
166
|
+
max-width: 380px;
|
|
167
|
+
margin-bottom: var(--dx-g-spacing-md);
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
.main-cta {
|
|
171
|
+
height: 52px;
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
.cta-group {
|
|
175
|
+
align-items: left;
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
.mobile-button {
|
|
179
|
+
display: flex;
|
|
180
|
+
align-items: left;
|
|
181
|
+
width: 100%;
|
|
182
|
+
max-width: 380px;
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
.desktop-button {
|
|
186
|
+
display: none;
|
|
187
|
+
}
|
|
188
|
+
}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div class="two-col-card-section">
|
|
3
|
+
<div class="large-card">
|
|
4
|
+
<div class="text-container">
|
|
5
|
+
<span class="subtitle">{subtitle}</span>
|
|
6
|
+
<h2 class="title dx-text-display-4">{header}</h2>
|
|
7
|
+
<span class="label dx-text-body-3">{label}</span>
|
|
8
|
+
<p class="body dx-text-body-2">{body}</p>
|
|
9
|
+
<div class="cta-group desktop-button">
|
|
10
|
+
<dx-button
|
|
11
|
+
class="main-cta"
|
|
12
|
+
size="large"
|
|
13
|
+
font="sans"
|
|
14
|
+
href={buttonHref}
|
|
15
|
+
onclick={handleSignUpClick}
|
|
16
|
+
>
|
|
17
|
+
{buttonText}
|
|
18
|
+
</dx-button>
|
|
19
|
+
</div>
|
|
20
|
+
</div>
|
|
21
|
+
<div class="card-container">
|
|
22
|
+
<slot></slot>
|
|
23
|
+
</div>
|
|
24
|
+
<img
|
|
25
|
+
class="graphic-1"
|
|
26
|
+
src="/assets/svg/mrkt-two-col-panel-section-graphic-1-light.svg"
|
|
27
|
+
alt=""
|
|
28
|
+
/>
|
|
29
|
+
<img
|
|
30
|
+
class="graphic-2"
|
|
31
|
+
src="/assets/svg/mrkt-two-col-panel-section-graphic-2-light.svg"
|
|
32
|
+
alt=""
|
|
33
|
+
/>
|
|
34
|
+
<img
|
|
35
|
+
class="graphic-3"
|
|
36
|
+
src="/assets/svg/mrkt-two-col-panel-section-graphic-3-light.svg"
|
|
37
|
+
alt=""
|
|
38
|
+
/>
|
|
39
|
+
<div class="cta-group mobile-button">
|
|
40
|
+
<dx-button
|
|
41
|
+
class="main-cta"
|
|
42
|
+
size="large"
|
|
43
|
+
font="sans"
|
|
44
|
+
href={buttonHref}
|
|
45
|
+
onclick={handleSignUpClick}
|
|
46
|
+
>
|
|
47
|
+
{buttonText}
|
|
48
|
+
</dx-button>
|
|
49
|
+
</div>
|
|
50
|
+
</div>
|
|
51
|
+
</div>
|
|
52
|
+
</template>
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { api, LightningElement } from "lwc";
|
|
2
|
+
import { track } from "dxUtils/analytics";
|
|
3
|
+
|
|
4
|
+
export default class TwoColPanelSection extends LightningElement {
|
|
5
|
+
@api body!: string;
|
|
6
|
+
@api buttonHref!: string;
|
|
7
|
+
@api buttonText!: string;
|
|
8
|
+
@api subtitle!: string;
|
|
9
|
+
@api header!: string;
|
|
10
|
+
@api label?: string;
|
|
11
|
+
|
|
12
|
+
private handleSignUpClick(e: PointerEvent) {
|
|
13
|
+
if (this.buttonHref.includes("signup")) {
|
|
14
|
+
const payload = {
|
|
15
|
+
click_text: this.buttonText,
|
|
16
|
+
element_title: this.header,
|
|
17
|
+
element_type: "card",
|
|
18
|
+
click_url: `${window.location.origin}${this.buttonHref}`,
|
|
19
|
+
content_category: "cta"
|
|
20
|
+
};
|
|
21
|
+
track(e.currentTarget!, "custEv_signupStart", payload);
|
|
22
|
+
track(e.currentTarget!, "custEv_linkClick", payload);
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
}
|