@salesforcedevs/dw-components 1.28.2-action-link-1 → 1.28.2-lwr

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/LICENSE ADDED
@@ -0,0 +1,12 @@
1
+ Copyright (c) 2020, Salesforce.com, Inc.
2
+ All rights reserved.
3
+
4
+ Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
5
+
6
+ * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
7
+
8
+ * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
9
+
10
+ * Neither the name of Salesforce.com nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
11
+
12
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
package/package.json CHANGED
@@ -1,30 +1,30 @@
1
1
  {
2
- "name": "@salesforcedevs/dw-components",
3
- "version": "1.28.2-action-link-1",
4
- "description": "Lightning web components for https://developer.salesforce.com",
5
- "license": "MIT",
6
- "engines": {
7
- "node": "22.x"
8
- },
9
- "publishConfig": {
10
- "access": "public"
11
- },
12
- "dependencies": {
13
- "@types/youtube-player": "5.5.11",
14
- "classnames": "2.5.1",
15
- "lodash.clonedeep": "4.5.0",
16
- "lodash.orderby": "4.6.0",
17
- "lodash.uniqby": "4.7.0",
18
- "query-string": "7.1.3",
19
- "youtube-player": "5.6.0"
20
- },
21
- "devDependencies": {
22
- "@types/classnames": "2.3.1",
23
- "@types/lodash.clonedeep": "4.5.9",
24
- "@types/lodash.orderby": "4.6.9",
25
- "@types/lodash.uniqby": "4.7.9",
26
- "@types/setimmediate": "1.0.4",
27
- "setimmediate": "1.0.5"
28
- },
29
- "stableVersion": "1.28.2"
30
- }
2
+ "name": "@salesforcedevs/dw-components",
3
+ "version": "1.28.2-lwr",
4
+ "description": "Lightning web components for https://developer.salesforce.com",
5
+ "license": "MIT",
6
+ "engines": {
7
+ "node": "22.x"
8
+ },
9
+ "publishConfig": {
10
+ "access": "public"
11
+ },
12
+ "dependencies": {
13
+ "@types/youtube-player": "5.5.11",
14
+ "classnames": "2.5.1",
15
+ "lodash.clonedeep": "4.5.0",
16
+ "lodash.orderby": "4.6.0",
17
+ "lodash.uniqby": "4.7.0",
18
+ "query-string": "7.1.3",
19
+ "youtube-player": "5.6.0"
20
+ },
21
+ "devDependencies": {
22
+ "@types/classnames": "2.3.1",
23
+ "@types/lodash.clonedeep": "4.5.9",
24
+ "@types/lodash.orderby": "4.6.9",
25
+ "@types/lodash.uniqby": "4.7.9",
26
+ "@types/setimmediate": "1.0.4",
27
+ "setimmediate": "1.0.5"
28
+ },
29
+ "gitHead": "956930d90ebb6b2cc4fcc2c33b11199a28f1407a"
30
+ }
@@ -1,6 +1,6 @@
1
1
  import { api, LightningElement } from "lwc";
2
2
  import { normalizeBoolean, toJson } from "dxUtils/normalizers";
3
- import { DocsLink, DocsTile, DropdownItem, Language } from "typings/custom";
3
+ import { DocsTile, DropdownItem, Language } from "typings/custom";
4
4
  import qs from "query-string";
5
5
  import uniqBy from "lodash.uniqby";
6
6
  import orderBy from "lodash.orderby";
@@ -16,7 +16,6 @@ const DSC_API_URL = {
16
16
  const PRODUCT_FILTER_ALL_SERVICES = "all services";
17
17
  const LANGUAGE_FILTER_LABEL = "Language";
18
18
  const WAIT_TIME = 500;
19
- const DOCS_CONTENT_TYPE = "docs";
20
19
 
21
20
  type Filter = {
22
21
  label: string;
@@ -184,15 +183,12 @@ export default class DocsGrid extends LightningElement {
184
183
  for (const docs of allDocs) {
185
184
  for (const project of docs.projects) {
186
185
  const firstLink = project.contentTypes[0].href;
187
- const links = this.isDocsContentType(project)
188
- ? []
189
- : project.contentTypes;
190
186
 
191
187
  transformed.push({
192
188
  id: project.id,
193
189
  title: project.title,
194
190
  description: project.description,
195
- links,
191
+ links: project.contentTypes,
196
192
  service: project.meta.brand,
197
193
  guidesHref: firstLink,
198
194
  locale: docs.locale || "en-us"
@@ -203,13 +199,6 @@ export default class DocsGrid extends LightningElement {
203
199
  return transformed;
204
200
  }
205
201
 
206
- private isDocsContentType(project: any): boolean {
207
- return !!project.contentTypes?.some(
208
- (contentType: DocsLink) =>
209
- contentType.contentType === DOCS_CONTENT_TYPE
210
- );
211
- }
212
-
213
202
  async fetchOtherDocsFromSitemetadata(): Promise<void> {
214
203
  if (this._isFetchingOtherDocs) {
215
204
  return;