@salesforcedevs/dx-components 1.3.222-alpha13 → 1.3.222-alpha15
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
|
@@ -5,17 +5,24 @@
|
|
|
5
5
|
<dx-spinner size="large" variant="brand"></dx-spinner>
|
|
6
6
|
</div>
|
|
7
7
|
</dx-spinner>
|
|
8
|
-
<
|
|
9
|
-
<
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
8
|
+
<dx-grid columns="three" class="recent-posts">
|
|
9
|
+
<template for:each={recommendations} for:item="recommendation">
|
|
10
|
+
<dx-card-blog-post
|
|
11
|
+
authors={recommendation.authors}
|
|
12
|
+
body={recommendation.yoast_head_json.description}
|
|
13
|
+
datetime={recommendation.yoast_head_json.article_published_time}
|
|
14
|
+
href={recommendation.yoast_head_json.canonical}
|
|
15
|
+
img-alt={recommendation.yoast_head_json.title}
|
|
16
|
+
img-src={recommendation.featured_image}
|
|
17
|
+
key={recommendation.id}
|
|
18
|
+
title={recommendation.yoast_head_json.title}
|
|
19
|
+
></dx-card-blog-post>
|
|
20
|
+
<dx-hr
|
|
21
|
+
class="mobile-divider_posts"
|
|
22
|
+
spacing="2xs"
|
|
23
|
+
key="{recommendation.id}"
|
|
24
|
+
></dx-hr>
|
|
25
|
+
</template>
|
|
26
|
+
</dx-grid>
|
|
20
27
|
</dx-section>
|
|
21
28
|
</template>
|
|
@@ -44,7 +44,6 @@ export default class CoveoRecommendations extends LightningElement {
|
|
|
44
44
|
const blogDataUrl = `https://developer.salesforce.com/blogs/wp-json/wp/v2/posts?slug=${slug}&state=publish&_embed=wp:featuredmedia`;
|
|
45
45
|
const blogData = (await (await fetch(blogDataUrl)).json())[0];
|
|
46
46
|
this._recommendations = [...this._recommendations, blogData];
|
|
47
|
-
console.log(this._recommendations);
|
|
48
47
|
});
|
|
49
48
|
this.recommendationsLoaded = true;
|
|
50
49
|
});
|