Skip to content

Commit 07b7f52

Browse files
committed
[Changelog] Metadata values
1 parent 2bc533b commit 07b7f52

File tree

3 files changed

+12
-1
lines changed

3 files changed

+12
-1
lines changed

src/components/overrides/Head.astro

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,14 @@ const shouldChatbotDeprioritize =
3030
frontmatter.chatbot_deprioritize;
3131
3232
if (currentSection) {
33-
const product = await getEntry("products", currentSection);
33+
let product = await getEntry("products", currentSection);
34+
35+
if (currentSection === "changelog") {
36+
const products = frontmatter.products
37+
if (products) {
38+
product = await getEntry("products", products[0]);
39+
}
40+
}
3441
3542
if (product) {
3643
if (product.data.meta.title) {
@@ -209,6 +216,7 @@ metaTags.map((attrs) => {
209216
attrs,
210217
});
211218
});
219+
212220
---
213221

214222
<script src="src/scripts/footnotes.ts"></script>

src/pages/changelog/[...slug].astro

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,8 @@ const props = {
3535
template: "splash",
3636
noindex: note.data.hidden,
3737
chatbot_deprioritize: true,
38+
pcx_content_type: "changelog-entry",
39+
products: note.data.products.map(a => a.id),
3840
},
3941
headings,
4042
hideTitle: true,

src/schemas/base.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ export const baseSchema = ({ image }: SchemaContext) =>
2525
.union([
2626
z.literal("api"),
2727
z.literal("changelog"),
28+
z.literal("changelog-entry"),
2829
z.literal("configuration"),
2930
z.literal("concept"),
3031
z.literal("design-guide"),

0 commit comments

Comments
 (0)