Files
neuf-www/web/src/lib/common.ts
2024-05-23 00:42:08 +02:00

69 lines
1.1 KiB
TypeScript

import { graphql } from "@/gql";
const BlockFragmentDefinition = graphql(`
fragment Blocks on StreamFieldInterface {
id
blockType
field
... on RichTextBlock {
rawValue
value
}
... on ImageWithTextBlock {
image {
...Image
}
imageFormat
text
}
... on ImageSliderBlock {
images {
... on ImageSliderItemBlock {
image {
...Image
}
text
}
}
}
... on HorizontalRuleBlock {
color
}
... on FeaturedBlock {
title
featuredBlockText: text
linkText
imagePosition
featuredPage {
contentType
pageType
url
... on EventPage {
featuredImage {
...Image
}
}
... on NewsPage {
featuredImage {
...Image
}
}
}
featuredImageOverride {
...Image
}
}
}
`);
const ImageFragmentDefinition = graphql(`
fragment Image on CustomImage {
id
url
width
height
alt
attribution
}
`);