web: fix missing content for accordion blocks inside page section blocks

This commit is contained in:
2026-02-04 20:44:39 +01:00
parent 978aae4fc3
commit bba98fe868
3 changed files with 696 additions and 76 deletions
+22 -2
View File
@@ -91,8 +91,8 @@ export function formatHumanReadableList(array: (string | number)[]): string {
return array.slice(0, -1).join(", ") + " og " + array[length - 1];
}
const OneLevelOfBlocksFragmentDefinition = graphql(`
fragment OneLevelOfBlocks on StreamFieldInterface {
const LeafBlocksFragmentDefinition = graphql(`
fragment LeafBlocks on StreamFieldInterface {
id
blockType
field
@@ -167,6 +167,26 @@ const OneLevelOfBlocksFragmentDefinition = graphql(`
}
`);
const OneLevelOfBlocksFragmentDefinition = graphql(`
fragment OneLevelOfBlocks on StreamFieldInterface {
...LeafBlocks
... on AccordionBlock {
heading
body {
...LeafBlocks
}
}
... on PageSectionBlock {
title
backgroundColor
icon
body {
...LeafBlocks
}
}
}
`);
const BlockFragmentDefinition = graphql(`
fragment Blocks on StreamFieldInterface {
... on AccordionBlock {