feat(SW-187): Footer data from contentstack
This commit is contained in:
12
lib/graphql/Fragments/Footer/AppDownloads.graphql
Normal file
12
lib/graphql/Fragments/Footer/AppDownloads.graphql
Normal file
@@ -0,0 +1,12 @@
|
||||
fragment AppDownloads on Footer {
|
||||
app_downloads {
|
||||
title
|
||||
links {
|
||||
type
|
||||
href {
|
||||
href
|
||||
title
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
29
lib/graphql/Fragments/Footer/MainLinks.graphql
Normal file
29
lib/graphql/Fragments/Footer/MainLinks.graphql
Normal file
@@ -0,0 +1,29 @@
|
||||
fragment MainLinks on Footer {
|
||||
main_links {
|
||||
title
|
||||
open_in_new_tab
|
||||
link {
|
||||
href
|
||||
title
|
||||
}
|
||||
pageConnection {
|
||||
edges {
|
||||
node {
|
||||
__typename
|
||||
... on AccountPage {
|
||||
title
|
||||
url
|
||||
}
|
||||
... on LoyaltyPage {
|
||||
title
|
||||
url
|
||||
}
|
||||
... on ContentPage {
|
||||
title
|
||||
url
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
18
lib/graphql/Fragments/Footer/Refs/MainLinks.graphql
Normal file
18
lib/graphql/Fragments/Footer/Refs/MainLinks.graphql
Normal file
@@ -0,0 +1,18 @@
|
||||
fragment MainLinksRef on Footer {
|
||||
__typename
|
||||
main_links {
|
||||
pageConnection {
|
||||
edges {
|
||||
node {
|
||||
__typename
|
||||
...LoyaltyPageRef
|
||||
...ContentPageRef
|
||||
...AccountPageRef
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
system {
|
||||
...System
|
||||
}
|
||||
}
|
||||
20
lib/graphql/Fragments/Footer/Refs/SecondaryLinks.graphql
Normal file
20
lib/graphql/Fragments/Footer/Refs/SecondaryLinks.graphql
Normal file
@@ -0,0 +1,20 @@
|
||||
fragment SecondaryLinksRef on Footer {
|
||||
__typename
|
||||
secondary_links {
|
||||
links {
|
||||
pageConnection {
|
||||
edges {
|
||||
node {
|
||||
__typename
|
||||
...LoyaltyPageRef
|
||||
...ContentPageRef
|
||||
...AccountPageRef
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
system {
|
||||
...System
|
||||
}
|
||||
}
|
||||
24
lib/graphql/Fragments/Footer/SecondaryLinks.graphql
Normal file
24
lib/graphql/Fragments/Footer/SecondaryLinks.graphql
Normal file
@@ -0,0 +1,24 @@
|
||||
#import "../Refs/MyPages/AccountPage.graphql"
|
||||
#import "../Refs/ContentPage/ContentPage.graphql"
|
||||
#import "../Refs/LoyaltyPage/LoyaltyPage.graphql"
|
||||
|
||||
fragment SecondaryLinks on Footer {
|
||||
secondary_links {
|
||||
title
|
||||
links {
|
||||
title
|
||||
open_in_new_tab
|
||||
pageConnection {
|
||||
edges {
|
||||
node {
|
||||
__typename
|
||||
}
|
||||
}
|
||||
}
|
||||
link {
|
||||
href
|
||||
title
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
28
lib/graphql/Query/Footer.graphql
Normal file
28
lib/graphql/Query/Footer.graphql
Normal file
@@ -0,0 +1,28 @@
|
||||
#import "../Fragments/Footer/AppDownloads.graphql"
|
||||
#import "../Fragments/Footer/MainLinks.graphql"
|
||||
#import "../Fragments/Footer/SecondaryLinks.graphql"
|
||||
#import "../Fragments/Footer/Refs/MainLinks.graphql"
|
||||
#import "../Fragments/Footer/Refs/SecondaryLinks.graphql"
|
||||
#import "../Fragments/Refs/System.graphql"
|
||||
|
||||
query GetFooter($locale: String!) {
|
||||
all_footer(limit: 1, locale: $locale) {
|
||||
items {
|
||||
...MainLinks
|
||||
...SecondaryLinks
|
||||
...AppDownloads
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
query GetFooterRef($locale: String!) {
|
||||
all_footer(limit: 1, locale: $locale) {
|
||||
items {
|
||||
...MainLinksRef
|
||||
...SecondaryLinksRef
|
||||
system {
|
||||
...System
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user