feat: json rich text editor, blocks, asides, general structure
This commit is contained in:
@@ -28,6 +28,7 @@ fragment ListItemInternalLink on CurrentBlocksPageBlocksListBlockListItemsListIt
|
||||
totalCount
|
||||
edges {
|
||||
node {
|
||||
__typename
|
||||
...CurrentBlocksPageLink
|
||||
...TempPageLink
|
||||
}
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
#import "../Image.graphql"
|
||||
#import "../PageLinks.graphql"
|
||||
|
||||
fragment TextBlock on CurrentBlocksPageBlocksText {
|
||||
@@ -7,12 +8,10 @@ fragment TextBlock on CurrentBlocksPageBlocksText {
|
||||
totalCount
|
||||
edges {
|
||||
node {
|
||||
__typename
|
||||
...CurrentBlocksPageLink
|
||||
...Image
|
||||
...TempPageLink
|
||||
... on SysAsset {
|
||||
title
|
||||
url
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
25
lib/graphql/Fragments/Breadcrumbs.graphql
Normal file
25
lib/graphql/Fragments/Breadcrumbs.graphql
Normal file
@@ -0,0 +1,25 @@
|
||||
fragment Breadcrumbs on CurrentBlocksPage {
|
||||
breadcrumbs {
|
||||
title
|
||||
parentsConnection {
|
||||
edges {
|
||||
node {
|
||||
... on CurrentBlocksPage {
|
||||
breadcrumbs {
|
||||
title
|
||||
}
|
||||
title
|
||||
url
|
||||
}
|
||||
... on TempPage {
|
||||
breadcrumbs {
|
||||
title
|
||||
}
|
||||
title
|
||||
url
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,3 +1,4 @@
|
||||
#import "./Image.graphql"
|
||||
#import "./PageLinks.graphql"
|
||||
|
||||
fragment Hero on Hero {
|
||||
@@ -5,12 +6,7 @@ fragment Hero on Hero {
|
||||
totalCount
|
||||
edges {
|
||||
node {
|
||||
dimension {
|
||||
height
|
||||
width
|
||||
}
|
||||
title
|
||||
url
|
||||
...Image
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5,9 +5,9 @@ fragment Image on SysAsset {
|
||||
width
|
||||
}
|
||||
metadata
|
||||
title
|
||||
url
|
||||
system {
|
||||
uid
|
||||
}
|
||||
title
|
||||
url
|
||||
}
|
||||
|
||||
@@ -1,9 +1,15 @@
|
||||
fragment CurrentBlocksPageLink on CurrentBlocksPage {
|
||||
system {
|
||||
uid
|
||||
}
|
||||
title
|
||||
url
|
||||
}
|
||||
|
||||
fragment TempPageLink on TempPage {
|
||||
system {
|
||||
uid
|
||||
}
|
||||
title
|
||||
url
|
||||
}
|
||||
|
||||
@@ -1,18 +1,17 @@
|
||||
#import "../PageLinks.graphql"
|
||||
#import "./Image.graphql"
|
||||
#import "./PageLinks.graphql"
|
||||
|
||||
fragment PreambleBlock on CurrentBlocksPageBlocksPreamble {
|
||||
fragment Preamble on CurrentBlocksPage {
|
||||
preamble {
|
||||
text {
|
||||
json
|
||||
embedded_itemsConnection(limit: 30) {
|
||||
edges {
|
||||
node {
|
||||
__typename
|
||||
...CurrentBlocksPageLink
|
||||
...Image
|
||||
...TempPageLink
|
||||
... on SysAsset {
|
||||
title
|
||||
url
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,11 +1,11 @@
|
||||
#import "./Image.graphql"
|
||||
#import "./PageLinks.graphql"
|
||||
|
||||
fragment Puff on Puff {
|
||||
imageConnection {
|
||||
edges {
|
||||
node {
|
||||
title
|
||||
url
|
||||
...Image
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -24,6 +24,9 @@ fragment Puff on Puff {
|
||||
}
|
||||
}
|
||||
}
|
||||
system {
|
||||
uid
|
||||
}
|
||||
text {
|
||||
json
|
||||
embedded_itemsConnection {
|
||||
@@ -31,10 +34,7 @@ fragment Puff on Puff {
|
||||
edges {
|
||||
node {
|
||||
__typename
|
||||
... on SysAsset {
|
||||
title
|
||||
url
|
||||
}
|
||||
...Image
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,10 +1,11 @@
|
||||
#import "../Fragments/Aside/Contact.graphql"
|
||||
#import "../Fragments/Aside/Puff.graphql"
|
||||
#import "../Fragments/Blocks/List.graphql"
|
||||
#import "../Fragments/Blocks/Preamble.graphql"
|
||||
#import "../Fragments/Blocks/Puff.graphql"
|
||||
#import "../Fragments/Blocks/Text.graphql"
|
||||
#import "../Fragments/Breadcrumbs.graphql"
|
||||
#import "../Fragments/Hero.graphql"
|
||||
#import "../Fragments/Preamble.graphql"
|
||||
|
||||
query GetCurrentBlockPage($locale: String!, $url: String!) {
|
||||
all_current_blocks_page(limit: 1, locale: $locale, where: { url: $url }) {
|
||||
@@ -17,13 +18,14 @@ query GetCurrentBlockPage($locale: String!, $url: String!) {
|
||||
blocks {
|
||||
__typename
|
||||
...ListBlock
|
||||
...PreambleBlock
|
||||
...PuffBlock
|
||||
...TextBlock
|
||||
}
|
||||
...Breadcrumbs
|
||||
hero {
|
||||
...Hero
|
||||
}
|
||||
...Preamble
|
||||
title
|
||||
url
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user