@salesforcedevs/dx-components 1.3.245-alpha3 → 1.3.245-dc-alpha3
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 +1 -0
- package/package.json +1 -1
- package/src/modules/dx/button/button.html +2 -2
- package/src/modules/dx/button/button.ts +1 -1
- package/src/modules/dx/cardBlogPost/cardBlogPost.ts +0 -5
- package/src/modules/dx/coveoRecommendations/coveoRecommendations.html +0 -1
- package/src/modules/dx/coveoRecommendations/coveoRecommendations.ts +3 -58
- package/src/modules/dx/dropdownOption/dropdownOption.css +5 -3
- package/src/modules/dx/headerNav/headerNav.css +8 -0
- package/src/modules/dx/mainContentHeader/mainContentHeader.css +74 -2
- package/src/modules/dx/mainContentHeader/mainContentHeader.html +48 -23
- package/src/modules/dx/mainContentHeader/mainContentHeader.ts +20 -5
- package/src/modules/dx/popover/popover.css +2 -2
- package/src/modules/dx/sidebar/sidebar.css +9 -5
- package/src/modules/dx/sidebar/sidebar.html +32 -16
- package/src/modules/dx/sidebar/sidebar.ts +2 -42
- package/src/modules/dx/sidebarFooterNav/sidebarFooterNav.css +49 -0
- package/src/modules/dx/sidebarFooterNav/sidebarFooterNav.html +55 -0
- package/src/modules/dx/sidebarFooterNav/sidebarFooterNav.ts +106 -0
- package/src/modules/dx/sidebarOld/sidebarOld.css +1 -0
- package/src/modules/dx/sidebarOld/sidebarOld.html +31 -14
- package/src/modules/dx/sidebarOld/sidebarOld.ts +4 -38
- package/src/modules/dx/sidebarSearchResult/sidebarSearchResult.css +35 -4
- package/src/modules/dx/sidebarSearchResult/sidebarSearchResult.html +16 -10
- package/src/modules/dx/tab/tab.css +48 -19
- package/src/modules/dx/treeItem/treeItem.css +2 -2
- package/src/modules/dx/treeTile/treeTile.css +39 -28
- package/src/modules/dx/treeTile/treeTile.html +6 -6
- package/src/modules/dx/treeTile/treeTile.ts +2 -1
- package/src/modules/dxBaseElements/sidebarBase/sidebarBase.ts +100 -1
- package/src/modules/dxHelpers/commonHeader/commonHeader.css +4 -2
- package/src/modules/dxHelpers/commonSidebar/commonSidebar.css +38 -16
- package/src/modules/dxHelpers/commonTreeItem/commonTreeItem.css +26 -3
- package/logs_4_17.txt +0 -100
package/lwc.config.json
CHANGED
package/package.json
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
aria-label={ariaLabel}
|
|
8
8
|
part="container"
|
|
9
9
|
>
|
|
10
|
-
<span if:false={loading}>
|
|
10
|
+
<span if:false={loading} part="content">
|
|
11
11
|
<slot onslotchange={onSlotChange}></slot>
|
|
12
12
|
</span>
|
|
13
13
|
<dx-icon
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
aria-label={ariaLabel}
|
|
30
30
|
part="container"
|
|
31
31
|
>
|
|
32
|
-
<span if:false={loading}>
|
|
32
|
+
<span if:false={loading} part="content">
|
|
33
33
|
<slot onslotchange={onSlotChange}></slot>
|
|
34
34
|
</span>
|
|
35
35
|
<dx-icon
|
|
@@ -14,7 +14,6 @@ export default class CardBlogPost extends LightningElement {
|
|
|
14
14
|
@api title!: string;
|
|
15
15
|
@api authors?: Array<any> | null = null;
|
|
16
16
|
@api origin?: string = "wordpress";
|
|
17
|
-
@api clickEvent?: () => void;
|
|
18
17
|
|
|
19
18
|
// LWC is being compiled so that datetime is being interpreted as date-time
|
|
20
19
|
// ONLY from from the implementation in dx-card-blog-post-provider
|
|
@@ -23,10 +22,6 @@ export default class CardBlogPost extends LightningElement {
|
|
|
23
22
|
}
|
|
24
23
|
|
|
25
24
|
private onLinkClick(event: Event) {
|
|
26
|
-
if (this.clickEvent) {
|
|
27
|
-
this.clickEvent();
|
|
28
|
-
}
|
|
29
|
-
|
|
30
25
|
const payload = {
|
|
31
26
|
click_text: this.title,
|
|
32
27
|
click_url: `${window.location.origin}${this.href}`,
|
|
@@ -1,25 +1,11 @@
|
|
|
1
1
|
import { LightningElement, api } from "lwc";
|
|
2
2
|
|
|
3
3
|
const SEARCH_HUB = "developerWebsiteBlogs";
|
|
4
|
-
|
|
5
|
-
interface Recommendation {
|
|
6
|
-
originalCoveoData: {
|
|
7
|
-
uri: string;
|
|
8
|
-
title: string;
|
|
9
|
-
searchUid: string;
|
|
10
|
-
raw: {
|
|
11
|
-
permanentId: string;
|
|
12
|
-
};
|
|
13
|
-
"@source": string;
|
|
14
|
-
};
|
|
15
|
-
clickEvent: () => void;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
4
|
export default class CoveoRecommendations extends LightningElement {
|
|
19
5
|
@api coveoAuthToken!: string;
|
|
20
6
|
@api coveoOrganizationId!: string;
|
|
21
7
|
|
|
22
|
-
_recommendations = [] as
|
|
8
|
+
_recommendations = [] as any[];
|
|
23
9
|
|
|
24
10
|
private get recommendations(): any[] {
|
|
25
11
|
return this._recommendations || [];
|
|
@@ -60,17 +46,10 @@ export default class CoveoRecommendations extends LightningElement {
|
|
|
60
46
|
|
|
61
47
|
const blogDataLoadTasks = results
|
|
62
48
|
.slice(0, 3)
|
|
63
|
-
.map(async (rec: any
|
|
49
|
+
.map(async (rec: any) => {
|
|
64
50
|
const slug = rec.uri.split("/").pop();
|
|
65
51
|
const blogDataUrl = `https://developer.salesforce.com/blogs/wp-json/wp/v2/posts?slug=${slug}&state=publish&_embed=wp:featuredmedia`;
|
|
66
|
-
|
|
67
|
-
await (await fetch(blogDataUrl)).json()
|
|
68
|
-
)[0];
|
|
69
|
-
wordPressData.originalCoveoData = rec;
|
|
70
|
-
wordPressData.originalCoveoData.searchUid =
|
|
71
|
-
json.searchUid;
|
|
72
|
-
wordPressData.clickEvent =
|
|
73
|
-
this.buildClickAnalyticsLogger(index);
|
|
52
|
+
return (await (await fetch(blogDataUrl)).json())[0];
|
|
74
53
|
});
|
|
75
54
|
this._recommendations = await Promise.all(
|
|
76
55
|
blogDataLoadTasks
|
|
@@ -113,38 +92,4 @@ export default class CoveoRecommendations extends LightningElement {
|
|
|
113
92
|
}
|
|
114
93
|
);
|
|
115
94
|
};
|
|
116
|
-
|
|
117
|
-
buildClickAnalyticsLogger = (index: number) => () => {
|
|
118
|
-
const payload = {
|
|
119
|
-
anonymous: true,
|
|
120
|
-
documentPosition: index,
|
|
121
|
-
documentTitle: this._recommendations[index].originalCoveoData.title,
|
|
122
|
-
documentUrl: this._recommendations[index].originalCoveoData.uri,
|
|
123
|
-
language: "en",
|
|
124
|
-
originLevel1: SEARCH_HUB,
|
|
125
|
-
originLevel2: SEARCH_HUB,
|
|
126
|
-
actionCause: "recommendationOpen",
|
|
127
|
-
queryText: "", // This has to be included, but is empty, because recommendations use the 'search' endpoint with an empty query string
|
|
128
|
-
searchQueryUid: this._recommendations[index].originalCoveoData.uri,
|
|
129
|
-
sourceName:
|
|
130
|
-
this._recommendations[index].originalCoveoData["@source"],
|
|
131
|
-
customData: {
|
|
132
|
-
contentIDKey: "permanentId",
|
|
133
|
-
contentIDValue:
|
|
134
|
-
this._recommendations[index].originalCoveoData.raw
|
|
135
|
-
.permanentId
|
|
136
|
-
}
|
|
137
|
-
};
|
|
138
|
-
fetch(
|
|
139
|
-
`https://${this.coveoOrganizationId}.analytics.org.coveo.com/rest/ua/v15/analytics/click`,
|
|
140
|
-
{
|
|
141
|
-
headers: {
|
|
142
|
-
Authorization: `Bearer ${this.coveoAuthToken}`,
|
|
143
|
-
"Content-Type": "application/json"
|
|
144
|
-
},
|
|
145
|
-
method: "POST",
|
|
146
|
-
body: JSON.stringify(payload)
|
|
147
|
-
}
|
|
148
|
-
);
|
|
149
|
-
};
|
|
150
95
|
}
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
}
|
|
39
39
|
|
|
40
40
|
.option:active {
|
|
41
|
-
background: var(--dx-g-blue-vibrant-95) !important;
|
|
41
|
+
background: var(--dx-g-cloud-blue-vibrant-95) !important;
|
|
42
42
|
}
|
|
43
43
|
|
|
44
44
|
.option:not(.option-active):hover {
|
|
@@ -46,7 +46,9 @@
|
|
|
46
46
|
}
|
|
47
47
|
|
|
48
48
|
.option-active {
|
|
49
|
-
|
|
49
|
+
--dx-c-dropdown-option-label-color: var(--dx-g-blue-vibrant-50);
|
|
50
|
+
|
|
51
|
+
background: var(--dx-g-cloud-blue-vibrant-95);
|
|
50
52
|
}
|
|
51
53
|
|
|
52
54
|
.option_details {
|
|
@@ -67,7 +69,7 @@
|
|
|
67
69
|
color: var(--dx-c-dropdown-option-label-color, var(--dx-g-blue-vibrant-50));
|
|
68
70
|
display: flex;
|
|
69
71
|
align-items: center;
|
|
70
|
-
font-weight: var(--dx-g-font-bold);
|
|
72
|
+
font-weight: var(--dx-c-dropdown-option-font-weight, var(--dx-g-font-bold));
|
|
71
73
|
font-size: var(--dx-c-dropdown-option-font-size, var(--dx-g-text-base));
|
|
72
74
|
}
|
|
73
75
|
|
|
@@ -16,11 +16,19 @@ nav {
|
|
|
16
16
|
position: relative;
|
|
17
17
|
}
|
|
18
18
|
|
|
19
|
+
.nav-list li:not(:last-child) {
|
|
20
|
+
margin-right: var(--dx-g-spacing-md);
|
|
21
|
+
}
|
|
22
|
+
|
|
19
23
|
.nav-list-item-nav-menu {
|
|
20
24
|
display: none;
|
|
21
25
|
}
|
|
22
26
|
|
|
23
27
|
@media (max-width: 768px) {
|
|
28
|
+
.nav-list {
|
|
29
|
+
margin-top: 0;
|
|
30
|
+
}
|
|
31
|
+
|
|
24
32
|
.nav-list-item-nav-menu {
|
|
25
33
|
display: flex;
|
|
26
34
|
}
|
|
@@ -1,10 +1,25 @@
|
|
|
1
1
|
@import "dxHelpers/reset";
|
|
2
2
|
@import "dxHelpers/text";
|
|
3
3
|
|
|
4
|
+
:host {
|
|
5
|
+
--dx-c-padding: 0 var(--dx-g-page-padding-horizontal);
|
|
6
|
+
--dx-c-container-justify-content: left;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
dx-formatted-rich-text {
|
|
10
|
+
--dx-c-formatted-rich-text-inline-link-color: var(
|
|
11
|
+
--dx-g-cloud-blue-vibrant-95
|
|
12
|
+
);
|
|
13
|
+
--dx-c-formatted-rich-text-inline-link-color-hover: var(
|
|
14
|
+
--dx-g-blue-vibrant-70
|
|
15
|
+
);
|
|
16
|
+
}
|
|
17
|
+
|
|
4
18
|
.container {
|
|
5
19
|
display: flex;
|
|
6
20
|
flex-direction: row;
|
|
7
|
-
padding:
|
|
21
|
+
padding: var(--dx-c-padding);
|
|
22
|
+
justify-content: var(--dx-c-container-justify-content);
|
|
8
23
|
overflow: hidden;
|
|
9
24
|
}
|
|
10
25
|
|
|
@@ -62,6 +77,29 @@ img.mobile {
|
|
|
62
77
|
min-width: 1024px;
|
|
63
78
|
}
|
|
64
79
|
|
|
80
|
+
.multiple-image-container {
|
|
81
|
+
position: relative;
|
|
82
|
+
max-width: 646px;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
.image-one {
|
|
86
|
+
display: block;
|
|
87
|
+
position: absolute;
|
|
88
|
+
left: 0;
|
|
89
|
+
bottom: 0;
|
|
90
|
+
width: 418px;
|
|
91
|
+
height: 515px;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
.image-two {
|
|
95
|
+
display: block;
|
|
96
|
+
position: absolute;
|
|
97
|
+
right: 0;
|
|
98
|
+
bottom: 0;
|
|
99
|
+
width: 341px;
|
|
100
|
+
height: 339px;
|
|
101
|
+
}
|
|
102
|
+
|
|
65
103
|
.text-container > *:not(:last-child) {
|
|
66
104
|
margin-bottom: var(--dx-g-spacing-smd);
|
|
67
105
|
}
|
|
@@ -76,6 +114,16 @@ svg {
|
|
|
76
114
|
bottom: 60px;
|
|
77
115
|
}
|
|
78
116
|
|
|
117
|
+
.foot-note-container {
|
|
118
|
+
display: flex;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
@media screen and (min-width: 1024px) {
|
|
122
|
+
.text-container {
|
|
123
|
+
text-align: left;
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
|
|
79
127
|
@media screen and (max-width: 1024px) {
|
|
80
128
|
.container {
|
|
81
129
|
flex-direction: column;
|
|
@@ -87,12 +135,15 @@ svg {
|
|
|
87
135
|
|
|
88
136
|
.text-container {
|
|
89
137
|
align-items: center;
|
|
90
|
-
text-align: center;
|
|
91
138
|
padding-top: var(--dx-g-spacing-4xl);
|
|
92
139
|
padding-bottom: 0;
|
|
93
140
|
min-height: unset;
|
|
94
141
|
}
|
|
95
142
|
|
|
143
|
+
.button-container {
|
|
144
|
+
justify-content: center;
|
|
145
|
+
}
|
|
146
|
+
|
|
96
147
|
.text-container > * {
|
|
97
148
|
max-width: 700px;
|
|
98
149
|
}
|
|
@@ -109,6 +160,10 @@ svg {
|
|
|
109
160
|
display: block;
|
|
110
161
|
margin-top: var(--dx-g-spacing-3xl);
|
|
111
162
|
}
|
|
163
|
+
|
|
164
|
+
.multiple-image-container {
|
|
165
|
+
display: none;
|
|
166
|
+
}
|
|
112
167
|
}
|
|
113
168
|
|
|
114
169
|
@media screen and (max-width: 768px) {
|
|
@@ -123,3 +178,20 @@ svg {
|
|
|
123
178
|
line-height: var(--dx-g-text-4xl);
|
|
124
179
|
}
|
|
125
180
|
}
|
|
181
|
+
@media screen and (min-width: 479px) and (max-width: 1024px) {
|
|
182
|
+
.text-container {
|
|
183
|
+
text-align: center;
|
|
184
|
+
}
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
@media screen and (min-width: 479px) {
|
|
188
|
+
.foot-note-image {
|
|
189
|
+
display: none;
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
@media screen and (max-width: 479px) {
|
|
194
|
+
.foot-note-image {
|
|
195
|
+
object-fit: contain;
|
|
196
|
+
}
|
|
197
|
+
}
|
|
@@ -3,37 +3,62 @@
|
|
|
3
3
|
<div class={textStyle}>
|
|
4
4
|
<h1 class="heading dx-text-display-2">{title}</h1>
|
|
5
5
|
<span class="body dx-text-body-1">{body}</span>
|
|
6
|
-
<span if
|
|
6
|
+
<span lwc:if={subtitle} class="subtitle dx-text-display-7">
|
|
7
7
|
{subtitle}
|
|
8
8
|
</span>
|
|
9
|
-
<div class="
|
|
10
|
-
<
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
9
|
+
<div class="foot-note-container">
|
|
10
|
+
<div class="foot-note-text-button-container">
|
|
11
|
+
<span
|
|
12
|
+
lwc:if={footNote}
|
|
13
|
+
class="dx-text-body-4"
|
|
14
|
+
style={footNoteStyle}
|
|
15
|
+
>
|
|
16
|
+
<dx-formatted-rich-text
|
|
17
|
+
value={footNote}
|
|
18
|
+
></dx-formatted-rich-text>
|
|
19
|
+
</span>
|
|
20
|
+
<div class="button-container">
|
|
21
|
+
<dx-button
|
|
22
|
+
onclick={onCtaClick}
|
|
23
|
+
href={ctaHref}
|
|
24
|
+
target={ctaTarget}
|
|
25
|
+
size="large"
|
|
26
|
+
>
|
|
27
|
+
{ctaLabel}
|
|
28
|
+
</dx-button>
|
|
29
|
+
<dx-button
|
|
30
|
+
class="secondary-button"
|
|
31
|
+
lwc:if={ctaLabelSecondary}
|
|
32
|
+
onclick={onCtaClickSecondary}
|
|
33
|
+
href={ctaHrefSecondary}
|
|
34
|
+
target={ctaTargetSecondary}
|
|
35
|
+
size="large"
|
|
36
|
+
variant="secondary"
|
|
37
|
+
>
|
|
38
|
+
{ctaLabelSecondary}
|
|
39
|
+
</dx-button>
|
|
40
|
+
</div>
|
|
41
|
+
</div>
|
|
42
|
+
<img
|
|
43
|
+
lwc:if={footNoteImage}
|
|
44
|
+
class="foot-note-image"
|
|
45
|
+
src={footNoteImage}
|
|
46
|
+
alt={footNoteImageAlt}
|
|
47
|
+
width={footNoteImageWidth}
|
|
48
|
+
height={footNoteImageHeight}
|
|
49
|
+
/>
|
|
29
50
|
</div>
|
|
30
51
|
</div>
|
|
31
|
-
<div class="image-container">
|
|
52
|
+
<div lwc:if={multipleImages} class="multiple-image-container">
|
|
53
|
+
<img class="image-one" src={imgSrcOne} alt="" />
|
|
54
|
+
<img class="image-two" src={imgSrcTwo} alt="" />
|
|
55
|
+
</div>
|
|
56
|
+
<div lwc:else class="image-container">
|
|
32
57
|
<img class="desktop" src={imgSrc} alt="" />
|
|
33
58
|
<img class="mobile" src={imgSrcMobile} alt="" />
|
|
34
59
|
</div>
|
|
35
60
|
</div>
|
|
36
|
-
<template if
|
|
61
|
+
<template lwc:if={hasSwoop}>
|
|
37
62
|
<svg
|
|
38
63
|
width="500"
|
|
39
64
|
height="80"
|
|
@@ -6,17 +6,26 @@ export default class MainContentHeader extends LightningElement {
|
|
|
6
6
|
@api title!: string;
|
|
7
7
|
@api subtitle?: string;
|
|
8
8
|
@api body!: string;
|
|
9
|
+
@api footNote?: string;
|
|
10
|
+
@api footNoteImage?: string;
|
|
11
|
+
@api footNoteImageAlt?: string;
|
|
12
|
+
@api footNoteImageHeight?: string;
|
|
13
|
+
@api footNoteImageWidth?: string;
|
|
9
14
|
@api ctaLabel!: string;
|
|
10
15
|
@api ctaLabelSecondary?: string;
|
|
11
16
|
@api ctaHref!: string;
|
|
12
17
|
@api ctaHrefSecondary?: string;
|
|
13
|
-
@api imgSrc
|
|
14
|
-
@api imgSrcMobile
|
|
18
|
+
@api imgSrc?: string;
|
|
19
|
+
@api imgSrcMobile?: string;
|
|
15
20
|
@api ctaTarget?: string | null = null;
|
|
16
21
|
@api ctaTargetSecondary?: string | null = null;
|
|
17
22
|
@api backgroundGradientColor?: string;
|
|
18
|
-
@api
|
|
19
|
-
@api
|
|
23
|
+
@api backgroundImage?: string;
|
|
24
|
+
@api backgroundGradientDark = false;
|
|
25
|
+
@api hasSwoop = false;
|
|
26
|
+
@api multipleImages = false;
|
|
27
|
+
@api imgSrcOne?: string;
|
|
28
|
+
@api imgSrcTwo?: string;
|
|
20
29
|
|
|
21
30
|
private get style() {
|
|
22
31
|
return cx(
|
|
@@ -24,7 +33,9 @@ export default class MainContentHeader extends LightningElement {
|
|
|
24
33
|
!this.backgroundGradientDark &&
|
|
25
34
|
`background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, #ffff 100%), var(--dx-g-${this.backgroundGradientColor});`,
|
|
26
35
|
this.backgroundGradientDark &&
|
|
27
|
-
`background: linear-gradient(90deg, var(--dx-g-indigo-vibrant-20) 0%, var(--dx-g-indigo-vibrant-30) 100%)
|
|
36
|
+
`background: linear-gradient(90deg, var(--dx-g-indigo-vibrant-20) 0%, var(--dx-g-indigo-vibrant-30) 100%);`,
|
|
37
|
+
this.backgroundImage &&
|
|
38
|
+
`background: #260F8F url('${this.backgroundImage}') no-repeat bottom; background-size: cover;`
|
|
28
39
|
);
|
|
29
40
|
}
|
|
30
41
|
|
|
@@ -35,6 +46,10 @@ export default class MainContentHeader extends LightningElement {
|
|
|
35
46
|
);
|
|
36
47
|
}
|
|
37
48
|
|
|
49
|
+
private get footNoteStyle() {
|
|
50
|
+
return cx(this.backgroundGradientDark && "color: white;");
|
|
51
|
+
}
|
|
52
|
+
|
|
38
53
|
private onCtaClick(e: Event) {
|
|
39
54
|
if (e.currentTarget) {
|
|
40
55
|
track(e.currentTarget, "custEv_ctaButtonClick", {
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
max-height: 65vh;
|
|
29
29
|
padding: var(--popover-padding);
|
|
30
30
|
overflow-y: auto;
|
|
31
|
-
transition:
|
|
31
|
+
transition: var(--popover-transition);
|
|
32
32
|
transition-delay: 0.02s;
|
|
33
33
|
transform: translateY(var(--dx-g-spacing-xs));
|
|
34
34
|
opacity: 0;
|
|
@@ -41,7 +41,7 @@
|
|
|
41
41
|
|
|
42
42
|
.popover-container_open .popover {
|
|
43
43
|
opacity: 1;
|
|
44
|
-
transform:
|
|
44
|
+
transform: var(--popover-container-open-transform);
|
|
45
45
|
}
|
|
46
46
|
|
|
47
47
|
.popover-overridewidth {
|
|
@@ -15,7 +15,7 @@ dx-empty-state {
|
|
|
15
15
|
|
|
16
16
|
.sidebar-content {
|
|
17
17
|
overflow-y: auto;
|
|
18
|
-
padding
|
|
18
|
+
padding: var(--dx-g-spacing-sm) 0 var(--dx-g-spacing-2xl);
|
|
19
19
|
}
|
|
20
20
|
|
|
21
21
|
.loading-skeleton {
|
|
@@ -53,6 +53,14 @@ dx-empty-state {
|
|
|
53
53
|
--dx-c-button-secondary-color-hover: var(--dx-g-gray-80);
|
|
54
54
|
}
|
|
55
55
|
|
|
56
|
+
.results-heading {
|
|
57
|
+
--dx-g-text-body-color: var(--sds-g-gray-14);
|
|
58
|
+
|
|
59
|
+
margin-bottom: var(--dx-g-spacing-sm);
|
|
60
|
+
padding-top: var(--dx-g-spacing-smd);
|
|
61
|
+
font-weight: var(--dx-g-font-bold);
|
|
62
|
+
}
|
|
63
|
+
|
|
56
64
|
@media (max-width: 768px) {
|
|
57
65
|
:host {
|
|
58
66
|
width: 100%;
|
|
@@ -61,8 +69,4 @@ dx-empty-state {
|
|
|
61
69
|
.loading-skeleton {
|
|
62
70
|
width: 100%;
|
|
63
71
|
}
|
|
64
|
-
|
|
65
|
-
.sidebar-content-tree {
|
|
66
|
-
padding: 0 var(--dx-g-spacing-sm);
|
|
67
|
-
}
|
|
68
72
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div class={containerClass} part="container">
|
|
3
3
|
<div
|
|
4
|
-
if
|
|
4
|
+
lwc:if={mobile}
|
|
5
5
|
class="header padding-horizontal"
|
|
6
6
|
onclick={onToggleClick}
|
|
7
7
|
>
|
|
@@ -16,22 +16,17 @@
|
|
|
16
16
|
<dx-icon
|
|
17
17
|
sprite="utility"
|
|
18
18
|
symbol={menuSymbol}
|
|
19
|
-
color="blue-vibrant-
|
|
19
|
+
color="blue-vibrant-50"
|
|
20
|
+
size="medium"
|
|
20
21
|
></dx-icon>
|
|
21
22
|
</dx-button>
|
|
22
23
|
</div>
|
|
23
24
|
</div>
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
<div class="header" if:false={mobile}>
|
|
25
|
+
<div class="sidebar-header" show-shadow={showBoxShadow}>
|
|
26
|
+
<div class="header padding-horizontal" lwc:if={isDesktop}>
|
|
27
27
|
<h2 class="dx-text-display-6 header-title">{header}</h2>
|
|
28
|
-
<slot name="header"></slot>
|
|
29
28
|
</div>
|
|
30
|
-
<div class="
|
|
31
|
-
<h2 class="dx-text-display-6">{header}</h2>
|
|
32
|
-
<slot name="header"></slot>
|
|
33
|
-
</div>
|
|
34
|
-
<div class="search">
|
|
29
|
+
<div class="search padding-horizontal">
|
|
35
30
|
<dx-sidebar-search
|
|
36
31
|
onchange={onSearchChange}
|
|
37
32
|
onloading={onSearchLoading}
|
|
@@ -41,9 +36,10 @@
|
|
|
41
36
|
coveo-advanced-query-config={coveoAdvancedQueryConfig}
|
|
42
37
|
></dx-sidebar-search>
|
|
43
38
|
</div>
|
|
39
|
+
<slot name="version-picker"></slot>
|
|
44
40
|
<h2
|
|
45
|
-
class="results-heading dx-text-
|
|
46
|
-
if
|
|
41
|
+
class="results-heading dx-text-body-3 padding-horizontal"
|
|
42
|
+
lwc:if={showResultsHeading}
|
|
47
43
|
>
|
|
48
44
|
Results
|
|
49
45
|
</h2>
|
|
@@ -53,13 +49,13 @@
|
|
|
53
49
|
onscroll={onSidebarSearchContentScroll}
|
|
54
50
|
>
|
|
55
51
|
<img
|
|
56
|
-
if
|
|
52
|
+
lwc:if={isSearchLoading}
|
|
57
53
|
class="loading-skeleton padding-horizontal"
|
|
58
54
|
src="https://a.sfdcstatic.com/developer-website/images/sidebar-loading.svg"
|
|
59
55
|
alt="loading"
|
|
60
56
|
/>
|
|
61
57
|
<template
|
|
62
|
-
if
|
|
58
|
+
lwc:if={showSearchResults}
|
|
63
59
|
for:each={searchResults}
|
|
64
60
|
for:item="result"
|
|
65
61
|
>
|
|
@@ -83,7 +79,7 @@
|
|
|
83
79
|
size="small"
|
|
84
80
|
></dx-empty-state>
|
|
85
81
|
</div>
|
|
86
|
-
<div class=
|
|
82
|
+
<div class={sidebarContentClass} onscroll={handleScroll}>
|
|
87
83
|
<dx-tree
|
|
88
84
|
for:each={trees}
|
|
89
85
|
for:item="tree"
|
|
@@ -95,5 +91,25 @@
|
|
|
95
91
|
onselecteditemrendered={onSelectedItemRendered}
|
|
96
92
|
></dx-tree>
|
|
97
93
|
</div>
|
|
94
|
+
<template lwc:if={mobile}>
|
|
95
|
+
<div lwc:if={hasMobileSidebarFooter} class="footer-nav">
|
|
96
|
+
<dx-sidebar-footer-nav
|
|
97
|
+
lang-value-path={langValuePath}
|
|
98
|
+
language={language}
|
|
99
|
+
languages={languages}
|
|
100
|
+
></dx-sidebar-footer-nav>
|
|
101
|
+
</div>
|
|
102
|
+
</template>
|
|
103
|
+
<template lwc:else>
|
|
104
|
+
<div lwc:if={hasSidebarFooter} class="footer-nav">
|
|
105
|
+
<dx-sidebar-footer-nav
|
|
106
|
+
lang-value-path={langValuePath}
|
|
107
|
+
language={language}
|
|
108
|
+
languages={languages}
|
|
109
|
+
bail-href={bailHref}
|
|
110
|
+
bail-label={bailLabel}
|
|
111
|
+
></dx-sidebar-footer-nav>
|
|
112
|
+
</div>
|
|
113
|
+
</template>
|
|
98
114
|
</div>
|
|
99
115
|
</template>
|