@salesforcedevs/docs-components 1.3.139-coveo-fix-test6 → 1.3.139-coveo-fix-test8
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/package.json
CHANGED
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
coveo-public-access-token={coveoPublicAccessToken}
|
|
7
7
|
coveo-search-hub={coveoSearchHub}
|
|
8
8
|
coveo-advanced-query-config={coveoAdvancedQueryConfig}
|
|
9
|
+
version={selectedVersion.id}
|
|
9
10
|
breadcrumbs={breadcrumbs}
|
|
10
11
|
sidebar-header={sidebarHeader}
|
|
11
12
|
sidebar-value={selectedSidebarValue}
|
|
@@ -14,7 +15,7 @@
|
|
|
14
15
|
onexpandcollapse={onExpandCollapse}
|
|
15
16
|
toc-title={tocTitle}
|
|
16
17
|
toc-options={tocOptions}
|
|
17
|
-
|
|
18
|
+
current-version={currentVersion}
|
|
18
19
|
enable-slot-change="true"
|
|
19
20
|
>
|
|
20
21
|
<doc-phase
|
|
@@ -110,7 +110,6 @@ export default class AmfReference extends LightningElement {
|
|
|
110
110
|
this.oldVersionInfo
|
|
111
111
|
) {
|
|
112
112
|
this.showVersionBanner = true;
|
|
113
|
-
this.setCurrentSelectedVersion();
|
|
114
113
|
}
|
|
115
114
|
}
|
|
116
115
|
|
|
@@ -156,7 +155,6 @@ export default class AmfReference extends LightningElement {
|
|
|
156
155
|
protected metadata: { [key: string]: AmfMetadataTopic } = {};
|
|
157
156
|
protected selectedTopic?: AmfMetaTopicType = undefined;
|
|
158
157
|
protected selectedSidebarValue = undefined;
|
|
159
|
-
protected curSelectedVersion = "latest";
|
|
160
158
|
|
|
161
159
|
protected selectedVersion: ReferenceVersion | null = null;
|
|
162
160
|
|
|
@@ -343,12 +341,6 @@ export default class AmfReference extends LightningElement {
|
|
|
343
341
|
return selectedVersion || (versions.length && versions[0]);
|
|
344
342
|
}
|
|
345
343
|
|
|
346
|
-
private setCurrentSelectedVersion() {
|
|
347
|
-
if (this.showVersionBanner) {
|
|
348
|
-
this.curSelectedVersion = this.getSelectedVersion().id;
|
|
349
|
-
}
|
|
350
|
-
}
|
|
351
|
-
|
|
352
344
|
private updateAmfConfigInView(): void {
|
|
353
345
|
if (this._amfConfigList && this._amfConfigList.length) {
|
|
354
346
|
// fetch AMF Json as soon as config is set
|
|
@@ -1265,7 +1257,6 @@ export default class AmfReference extends LightningElement {
|
|
|
1265
1257
|
this.versions = this.getVersions();
|
|
1266
1258
|
if (this.oldVersionInfo) {
|
|
1267
1259
|
this.showVersionBanner = true;
|
|
1268
|
-
this.setCurrentSelectedVersion();
|
|
1269
1260
|
}
|
|
1270
1261
|
this.updateDocPhase();
|
|
1271
1262
|
this.selectedSidebarValue = window.location.pathname;
|
|
@@ -17,12 +17,13 @@
|
|
|
17
17
|
trees={sidebarContent}
|
|
18
18
|
value={sidebarValue}
|
|
19
19
|
header={sidebarHeader}
|
|
20
|
+
version={version}
|
|
20
21
|
coveo-organization-id={coveoOrganizationId}
|
|
21
22
|
coveo-public-access-token={coveoPublicAccessToken}
|
|
22
23
|
coveo-search-hub={coveoSearchHub}
|
|
23
24
|
coveo-advanced-query-config={coveoAdvancedQueryConfig}
|
|
24
25
|
ontogglesidebar={onToggleSidebar}
|
|
25
|
-
|
|
26
|
+
current-version={currentVersion}
|
|
26
27
|
>
|
|
27
28
|
<slot name="sidebar-header" slot="header"></slot>
|
|
28
29
|
</dx-sidebar>
|
|
@@ -35,7 +35,17 @@ export default class ContentLayout extends LightningElement {
|
|
|
35
35
|
@api coveoSearchHub!: string;
|
|
36
36
|
@api coveoAdvancedQueryConfig!: string;
|
|
37
37
|
@api useOldSidebar?: boolean = false;
|
|
38
|
-
@api
|
|
38
|
+
@api
|
|
39
|
+
get version(): string {
|
|
40
|
+
return this._newVersion;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
set version(val) {
|
|
44
|
+
if (val) {
|
|
45
|
+
this._newVersion = val;
|
|
46
|
+
}
|
|
47
|
+
console.log("Content Layout: " + this._newVersion);
|
|
48
|
+
}
|
|
39
49
|
|
|
40
50
|
@api
|
|
41
51
|
get breadcrumbs() {
|
|
@@ -75,6 +85,7 @@ export default class ContentLayout extends LightningElement {
|
|
|
75
85
|
private _sidebarContent: unknown;
|
|
76
86
|
|
|
77
87
|
private _breadcrumbs = null;
|
|
88
|
+
protected _newVersion = "latest";
|
|
78
89
|
|
|
79
90
|
@track
|
|
80
91
|
private _tocOptions: Array<unknown>;
|