@salesforcedevs/dx-components 1.3.242-alpha2 → 1.3.243-newdocux-alpha5
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/codeBlock/codeBlock.html +1 -1
- package/src/modules/dx/codeBlock/codeBlock.ts +6 -60
- package/src/modules/dx/coveoRecommendations/coveoRecommendations.html +20 -22
- package/src/modules/dx/dropdownOption/dropdownOption.css +5 -3
- package/src/modules/dx/headerNav/headerNav.css +9 -0
- package/src/modules/dx/popover/popover.css +2 -2
- package/src/modules/dx/searchResults/coveo.css +1 -1
- 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 +37 -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 +6 -2
- package/src/modules/dxHelpers/commonSidebar/commonSidebar.css +38 -16
- package/src/modules/dxHelpers/commonTreeItem/commonTreeItem.css +26 -3
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
|
|
@@ -44,12 +44,11 @@ export default class CodeBlock extends LightningElement {
|
|
|
44
44
|
@api language: string = "";
|
|
45
45
|
// if it is true, it renders code as is coming instead of wrapping it into html/xml comments tags.
|
|
46
46
|
@api isEncoded = false;
|
|
47
|
-
@api showLanguageDropdown!: boolean;
|
|
48
|
-
private codeWithLanguages: { id: string; value: string }[] = [];
|
|
49
47
|
|
|
50
48
|
private markupLangs = ["visualforce", "html", "xml"];
|
|
51
49
|
private _codeBlockRendered: boolean = false;
|
|
52
50
|
private componentLoaded: boolean = false;
|
|
51
|
+
private showLanguageDropdown: boolean = false;
|
|
53
52
|
private copyBtnText: string = "Click to copy";
|
|
54
53
|
private selectedLanguageLabel: string = "";
|
|
55
54
|
private selectedLanguageId: string = "";
|
|
@@ -99,62 +98,17 @@ export default class CodeBlock extends LightningElement {
|
|
|
99
98
|
set codeBlock(value: string) {
|
|
100
99
|
this._codeBlockRendered = false;
|
|
101
100
|
let match;
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
if (typeof parsedValue === "object" && parsedValue !== null) {
|
|
108
|
-
this.selectedLanguageId = this.language;
|
|
109
|
-
if (this.selectedLanguageId) {
|
|
110
|
-
const selectedCode = this.codeWithLanguages.filter(
|
|
111
|
-
(obj) => obj.id === this.selectedLanguageId
|
|
112
|
-
);
|
|
113
|
-
if (selectedCode.length > 0) {
|
|
114
|
-
selectedLangBasedCode = selectedCode[0].value;
|
|
115
|
-
}
|
|
116
|
-
}
|
|
117
|
-
const supportedLanguages = parsedValue.map(
|
|
118
|
-
(obj: { id: string }) => obj.id
|
|
119
|
-
);
|
|
120
|
-
this._supportedLanguages = this.allLanguages.filter(
|
|
121
|
-
(lang) => supportedLanguages.includes(lang.id)
|
|
122
|
-
);
|
|
123
|
-
}
|
|
124
|
-
} catch (error) {
|
|
125
|
-
//console.log('Value is not a valid JSON string:', value);
|
|
126
|
-
}
|
|
127
|
-
this._codeBlock = (
|
|
128
|
-
(match = preTagRegexp.exec(selectedLangBasedCode.trim())) ===
|
|
129
|
-
null
|
|
130
|
-
? selectedLangBasedCode.trim()
|
|
131
|
-
: match[1]
|
|
132
|
-
).trim();
|
|
133
|
-
} else {
|
|
134
|
-
this._codeBlock = (
|
|
135
|
-
(match = preTagRegexp.exec(value.trim())) === null
|
|
136
|
-
? value.trim()
|
|
137
|
-
: match[1]
|
|
138
|
-
).trim();
|
|
139
|
-
}
|
|
101
|
+
this._codeBlock = (
|
|
102
|
+
(match = preTagRegexp.exec(value.trim())) === null
|
|
103
|
+
? value.trim()
|
|
104
|
+
: match[1]
|
|
105
|
+
).trim();
|
|
140
106
|
}
|
|
141
107
|
|
|
142
108
|
get codeBlock(): string {
|
|
143
109
|
return this._codeBlock;
|
|
144
110
|
}
|
|
145
111
|
|
|
146
|
-
_supportedLanguages: CodeBlockLanguage[] = [];
|
|
147
|
-
@api
|
|
148
|
-
get supportedLanguages(): CodeBlockLanguage[] {
|
|
149
|
-
return this._supportedLanguages;
|
|
150
|
-
}
|
|
151
|
-
set supportedLanguages(value: string) {
|
|
152
|
-
const codeblockSupportedLanguages = JSON.parse(value);
|
|
153
|
-
this._supportedLanguages = this.allLanguages.filter((lang) =>
|
|
154
|
-
codeblockSupportedLanguages.includes(lang.id)
|
|
155
|
-
);
|
|
156
|
-
}
|
|
157
|
-
|
|
158
112
|
@track private theme: CodeBlockTheme | null = null;
|
|
159
113
|
|
|
160
114
|
@wire(getLocalStorageData, { key: "dx-codeblock-theme" })
|
|
@@ -269,14 +223,6 @@ export default class CodeBlock extends LightningElement {
|
|
|
269
223
|
) || this.allLanguages[0];
|
|
270
224
|
this.selectedLanguageLabel = this.selectedLanguage.label;
|
|
271
225
|
this.selectedLanguageId = this.selectedLanguage.id;
|
|
272
|
-
if (this.showLanguageDropdown) {
|
|
273
|
-
const selectedCode = this.codeWithLanguages.filter(
|
|
274
|
-
(codeObj) => codeObj.id === this.selectedLanguageId
|
|
275
|
-
);
|
|
276
|
-
if (selectedCode.length > 0) {
|
|
277
|
-
this._codeBlock = selectedCode[0].value;
|
|
278
|
-
}
|
|
279
|
-
}
|
|
280
226
|
this.formatCodeBlock();
|
|
281
227
|
|
|
282
228
|
gtmTrack(newLang, "custEv_ctaLinkClick", {
|
|
@@ -6,27 +6,25 @@
|
|
|
6
6
|
></dx-hr>
|
|
7
7
|
|
|
8
8
|
<dx-section lwc:if={showRecommendations} class="section-reduced-padding">
|
|
9
|
-
<dx-
|
|
10
|
-
<
|
|
11
|
-
<
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
<
|
|
16
|
-
<
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
</dx-grid>
|
|
30
|
-
</dx-section>
|
|
9
|
+
<dx-spinner lwc:if={recommendationsLoading}>
|
|
10
|
+
<div class="spinner-container">
|
|
11
|
+
<dx-spinner size="large" variant="brand"></dx-spinner>
|
|
12
|
+
</div>
|
|
13
|
+
</dx-spinner>
|
|
14
|
+
<dx-grid columns="three" class="recent-posts">
|
|
15
|
+
<template for:each={recommendations} for:item="recommendation">
|
|
16
|
+
<dx-card-blog-post
|
|
17
|
+
authors={recommendation.authors}
|
|
18
|
+
body={recommendation.yoast_head_json.description}
|
|
19
|
+
datetime={recommendation.yoast_head_json.article_published_time}
|
|
20
|
+
href={recommendation.yoast_head_json.canonical}
|
|
21
|
+
img-alt={recommendation.yoast_head_json.title}
|
|
22
|
+
img-src={recommendation.featured_image}
|
|
23
|
+
key={recommendation.id}
|
|
24
|
+
title={recommendation.yoast_head_json.title}
|
|
25
|
+
origin="coveo"
|
|
26
|
+
></dx-card-blog-post>
|
|
27
|
+
</template>
|
|
28
|
+
</dx-grid>
|
|
31
29
|
</dx-section>
|
|
32
30
|
</template>
|
|
@@ -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
|
|
|
@@ -10,17 +10,26 @@ nav {
|
|
|
10
10
|
|
|
11
11
|
.nav-list {
|
|
12
12
|
display: flex;
|
|
13
|
+
margin-top: calc(var(--dx-g-spacing-2xs) + 1px);
|
|
13
14
|
}
|
|
14
15
|
|
|
15
16
|
.nav-list li {
|
|
16
17
|
position: relative;
|
|
17
18
|
}
|
|
18
19
|
|
|
20
|
+
.nav-list li:not(:last-child) {
|
|
21
|
+
margin-right: var(--dx-g-spacing-md);
|
|
22
|
+
}
|
|
23
|
+
|
|
19
24
|
.nav-list-item-nav-menu {
|
|
20
25
|
display: none;
|
|
21
26
|
}
|
|
22
27
|
|
|
23
28
|
@media (max-width: 768px) {
|
|
29
|
+
.nav-list {
|
|
30
|
+
margin-top: 0;
|
|
31
|
+
}
|
|
32
|
+
|
|
24
33
|
.nav-list-item-nav-menu {
|
|
25
34
|
display: flex;
|
|
26
35
|
}
|
|
@@ -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 {
|
|
@@ -7944,7 +7944,7 @@ select.coveo-dropdown::-ms-expand {
|
|
|
7944
7944
|
|
|
7945
7945
|
@font-face {
|
|
7946
7946
|
font-family: "Lato";
|
|
7947
|
-
src: url('https://static.cloud.coveo.com/searchui/v2.
|
|
7947
|
+
src: url('https://static.cloud.coveo.com/searchui/v2.10113/0/fonts/lato.woff2'), url('https://staticdev.cloud.coveo.com/searchui/v2.10113/0/fonts/lato.woff2'), url('../fonts/lato.woff2'), url('https://static.cloud.coveo.com/searchui/v2.10113/0/fonts/lato.woff'), url('https://staticdev.cloud.coveo.com/searchui/v2.10113/0/fonts/lato.woff'), url('../fonts/lato.woff');
|
|
7948
7948
|
font-weight: normal;
|
|
7949
7949
|
font-style: normal;
|
|
7950
7950
|
}
|
|
@@ -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>
|
|
@@ -15,15 +15,6 @@ export default class Sidebar extends SidebarBase {
|
|
|
15
15
|
@api coveoAdvancedQueryConfig!: string;
|
|
16
16
|
@api header: string = "";
|
|
17
17
|
|
|
18
|
-
@api
|
|
19
|
-
get value() {
|
|
20
|
-
return this._value;
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
set value(value) {
|
|
24
|
-
this._value = value;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
18
|
@api
|
|
28
19
|
get trees() {
|
|
29
20
|
return this._trees;
|
|
@@ -52,16 +43,10 @@ export default class Sidebar extends SidebarBase {
|
|
|
52
43
|
)?.setInputValue(searchTerm);
|
|
53
44
|
}
|
|
54
45
|
|
|
55
|
-
private expanded: boolean = true;
|
|
56
|
-
private _value?: string = undefined;
|
|
57
|
-
|
|
58
46
|
@track
|
|
59
47
|
private _trees!: Array<TreeNode>;
|
|
60
|
-
|
|
61
|
-
private mobile: boolean = true;
|
|
62
48
|
private matchMedia!: MediaQueryList;
|
|
63
49
|
private valueToLabel: { [key: string]: string } = {};
|
|
64
|
-
|
|
65
50
|
private isSearchLoading: boolean = false;
|
|
66
51
|
private searchValue: string | null = null;
|
|
67
52
|
private searchResults: SidebarSearchResult[] = [];
|
|
@@ -171,32 +156,6 @@ export default class Sidebar extends SidebarBase {
|
|
|
171
156
|
this.matchMedia.removeEventListener("change", this.onMediaChange);
|
|
172
157
|
}
|
|
173
158
|
|
|
174
|
-
private onMediaChange = (event: MediaQueryListEvent | MediaQueryList) => {
|
|
175
|
-
this.mobile = event.matches;
|
|
176
|
-
this.expanded = !this.mobile;
|
|
177
|
-
};
|
|
178
|
-
|
|
179
|
-
private onSelect(event: CustomEvent) {
|
|
180
|
-
this._value = event.detail.name;
|
|
181
|
-
|
|
182
|
-
if (this.mobile) {
|
|
183
|
-
this.onToggleClick();
|
|
184
|
-
}
|
|
185
|
-
}
|
|
186
|
-
|
|
187
|
-
private onToggleClick() {
|
|
188
|
-
this.expanded = !this.expanded;
|
|
189
|
-
this.dispatchEvent(
|
|
190
|
-
new CustomEvent("togglesidebar", {
|
|
191
|
-
detail: {
|
|
192
|
-
open: this.expanded,
|
|
193
|
-
bubbles: true,
|
|
194
|
-
composed: true
|
|
195
|
-
}
|
|
196
|
-
})
|
|
197
|
-
);
|
|
198
|
-
}
|
|
199
|
-
|
|
200
159
|
private makeKey(): string {
|
|
201
160
|
return Math.random().toString(36).substring(7);
|
|
202
161
|
}
|
|
@@ -216,7 +175,7 @@ export default class Sidebar extends SidebarBase {
|
|
|
216
175
|
this.isSearchLoading = e.detail;
|
|
217
176
|
}
|
|
218
177
|
|
|
219
|
-
private onSidebarSearchContentScroll() {
|
|
178
|
+
private onSidebarSearchContentScroll(scrollEvent) {
|
|
220
179
|
if (this.isSearchLoading) {
|
|
221
180
|
return;
|
|
222
181
|
}
|
|
@@ -233,6 +192,7 @@ export default class Sidebar extends SidebarBase {
|
|
|
233
192
|
this.requestedFetchMoreResults = true;
|
|
234
193
|
search.fetchMoreResults();
|
|
235
194
|
}
|
|
195
|
+
this.handleScroll(scrollEvent);
|
|
236
196
|
}
|
|
237
197
|
|
|
238
198
|
private initializeSearchScrollPosition() {
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
@import "dxHelpers/reset";
|
|
2
|
+
|
|
3
|
+
:host {
|
|
4
|
+
--button-primary-color: var(--dx-g-blue-vibrant-50);
|
|
5
|
+
--button-primary-color-hover: var(--dx-g-cloud-blue-vibrant-95);
|
|
6
|
+
--popover-container-open-transform: translateX(-4px) translateY(-8px);
|
|
7
|
+
--popover-transition: none;
|
|
8
|
+
--dx-c-dropdown-option-font-weight: normal;
|
|
9
|
+
--dx-c-dropdown-option-label-color: var(--dx-g-gray-10);
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
.footer-item {
|
|
13
|
+
display: flex;
|
|
14
|
+
height: var(--dx-g-spacing-xl);
|
|
15
|
+
align-items: center;
|
|
16
|
+
border-radius: var(--dx-g-spacing-xs);
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
.footer-display {
|
|
20
|
+
display: flex;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.footer_lang-dropdown {
|
|
24
|
+
--dx-c-button-primary-color: var(--button-primary-color);
|
|
25
|
+
--dx-c-button-secondary-color-hover: var(--button-primary-color-hover);
|
|
26
|
+
--border-color: var(--button-primary-color);
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
.footer_lang-dropdown[aria-expanded="true"] {
|
|
30
|
+
--dx-c-button-secondary-color-hover: var(--dx-g-cloud-blue-vibrant-95);
|
|
31
|
+
--dx-c-button-primary-color: var(--dx-g-blue-vibrant-40);
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.footer_lang-dropdown:hover,
|
|
35
|
+
.footer_lang-dropdown:active,
|
|
36
|
+
.pdf_bail-link:hover {
|
|
37
|
+
/* background-color: var(--button-primary-color-hover);
|
|
38
|
+
|
|
39
|
+
--border-color: var(--button-primary-color-hover); */
|
|
40
|
+
--dx-c-button-secondary-color-hover: var(--dx-g-cloud-blue-vibrant-95);
|
|
41
|
+
--dx-c-button-primary-color: var(--dx-g-blue-vibrant-40);
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
.pdf_bail-link {
|
|
45
|
+
--dx-c-button-secondary-color-hover: var(--button-primary-color-hover);
|
|
46
|
+
--dx-c-button-primary-color: var(--button-primary-color);
|
|
47
|
+
|
|
48
|
+
margin-right: var(--dx-g-spacing-sm);
|
|
49
|
+
}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div lwc:if={mobile} class="footer-display">
|
|
3
|
+
<dx-dropdown
|
|
4
|
+
lwc:if={hasLanguages}
|
|
5
|
+
options={languages}
|
|
6
|
+
small
|
|
7
|
+
value-path={langValuePath}
|
|
8
|
+
value={language}
|
|
9
|
+
onchange={onLangChange}
|
|
10
|
+
>
|
|
11
|
+
<dx-button
|
|
12
|
+
class="footer-item footer_lang-dropdown"
|
|
13
|
+
aria-label="Select Language"
|
|
14
|
+
variant="tertiary"
|
|
15
|
+
icon-size="small"
|
|
16
|
+
icon-symbol="world"
|
|
17
|
+
>
|
|
18
|
+
{languageLabel}
|
|
19
|
+
</dx-button>
|
|
20
|
+
</dx-dropdown>
|
|
21
|
+
</div>
|
|
22
|
+
<div lwc:else class="footer-display">
|
|
23
|
+
<dx-button
|
|
24
|
+
lwc:if={hasBailLink}
|
|
25
|
+
aria-label={bailLabel}
|
|
26
|
+
class="footer-item pdf_bail-link"
|
|
27
|
+
href={bailHref}
|
|
28
|
+
onclick={handleBailClick}
|
|
29
|
+
variant="tertiary"
|
|
30
|
+
icon-size="medium"
|
|
31
|
+
icon-symbol="new_window"
|
|
32
|
+
target="_blank"
|
|
33
|
+
>
|
|
34
|
+
{bailLabel}
|
|
35
|
+
</dx-button>
|
|
36
|
+
<dx-dropdown
|
|
37
|
+
lwc:if={hasLanguages}
|
|
38
|
+
options={languages}
|
|
39
|
+
small
|
|
40
|
+
value-path={langValuePath}
|
|
41
|
+
value={language}
|
|
42
|
+
onchange={onLangChange}
|
|
43
|
+
>
|
|
44
|
+
<dx-button
|
|
45
|
+
class="footer-item footer_lang-dropdown"
|
|
46
|
+
aria-label="Select Language"
|
|
47
|
+
variant="tertiary"
|
|
48
|
+
icon-size="medium"
|
|
49
|
+
icon-symbol="world"
|
|
50
|
+
>
|
|
51
|
+
{languageLabel}
|
|
52
|
+
</dx-button>
|
|
53
|
+
</dx-dropdown>
|
|
54
|
+
</div>
|
|
55
|
+
</template>
|