Skip to content

Commit bf19ddd

Browse files
committed
Fix PageTitle for other pages than function & event
1 parent b7b822e commit bf19ddd

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

web/src/overrides/PageTitle.astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
import { functionTypePrettyName } from "@src/utils/functions";
3-
const funcType = (Astro.locals.side ?? 'shared');
3+
const funcType = Astro.locals.side;
44
---
55

66
<div class={`page-title-container type-${funcType}`}>

web/src/pages/reference/[event].astro

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import {
1111
import { Icon } from "@astrojs/starlight/components";
1212
1313
import NoteBox from "@src/components/NoteBox.astro";
14-
import type { NotesType } from "@src/utils/types";
14+
import type { MetaItem, NotesType } from "@src/utils/types";
1515
1616
import SeeAlsoSection from "@src/components/SeeAlsoSection.astro";
1717
import CodeExamplesSection from "@src/components/CodeExamplesSection.astro";
@@ -70,9 +70,9 @@ if (Array.isArray(event.data.notes) && event.data.notes.length > 0) {
7070
}
7171
7272
const eventMeta = event.data.meta || [];
73-
const changelogEntries = eventMeta.find((m) => m.changelog)?.changelog ?? [];
73+
const changelogEntries = eventMeta.find((m:MetaItem) => m.changelog)?.changelog ?? [];
7474
const needsChecking =
75-
eventMeta.find((m) => m.needs_checking)?.needs_checking ?? undefined;
75+
eventMeta.find((m:MetaItem) => m.needs_checking)?.needs_checking ?? undefined;
7676
---
7777

7878
<StarlightPage

0 commit comments

Comments
 (0)