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AAf,YAA8B,4BAAOV,EAAKkB,WAK3D","sources":["webpack://landbay/./src/components/CategoryList.js","webpack://landbay/./src/components/PostPreview.js","webpack://landbay/./src/templates/page-blog.js"],"sourcesContent":["import React from \"react\";\nimport { useStaticQuery, graphql, Link } from \"gatsby\"\n\n/**\n * Category list. Appears on blog homepage and blog category archives.\n */\nexport default function CategoryList({activeCategory}) {\n\n //query for blog categories\n const query = useStaticQuery(graphql`\n query {\n allWpCategory(\n sort: {fields: category___order}\n ) {\n nodes {\n name\n\t\t uri\n }\n }\n\t wpPage(isPostsPage: {eq: true}) {\n\t uri\n\t }\n }\n `)\n\n return(\n\t\n )\n}\n\n","import React from 'react';\nimport { graphql, Link } from \"gatsby\"\nimport { GatsbyImage, getImage } from \"gatsby-plugin-image\"\n\nexport default function PostPreview({post}) {\n\t\n return (\n\t
\n\t\t\n\t\t {\n\t\t\tpost.featuredImage?.node\n\t\t\t? \n\t\t\t: null\n\t\t }\n\n\t\t
\n\t\t\t {\n\t\t\t\tpost.categories?.nodes?.length\n\t\t\t\t?

{Array.prototype.map.call(post.categories.nodes, function(item) { return item.name; }).join(\", \")}

\n\t\t\t\t: null\n\t\t\t }\t\t\t\t\t\n\t\t\t

{post.title}

\n\t\t\t

{post.date}

\n\t\t
\n\t\t\n\t
\n );\n}\n\nexport const PostFragment = graphql`\n\tfragment PostFragment on WpPost {\n\t categories {\n nodes {\n name\n }\n }\n title\n link\n date(formatString: \"D MMMM YYYY\")\n featuredImage {\n node {\n localFile {\n\t\t childImageSharp {\n\t gatsbyImageData(\n\t\t\t\tsizes: \"(min-width: 1280px) 405px, (min-width: 768px) 360px, calc(100vw - 64)\",\n\t\t\t\tbreakpoints: [622, 720, 810, 1232]\n\t )\n\t }\n }\n }\n }\n\t}\n`","import * as React from \"react\"\nimport { graphql, Link } from \"gatsby\"\nimport Layout from '../components/Layout' \nimport Hero from '../components/widgets/Hero' \nimport PostPreview from '../components/PostPreview'\nimport CategoryList from '../components/CategoryList'\nimport Seo from 'gatsby-plugin-wpgraphql-seo';\n\n// markup\nexport default function ContentHub({ data }) {\n\t\n const page = data.allWpPage.nodes[0];\n const posts = data.allWpPost?.nodes;\n\n const printFilteredArticles = (category, posts, limit=3) => {\n\t\n\treturn posts.reduce((result, post, i) => {\n\t const exists = post.categories?.nodes?.length && post.categories.nodes.some(c => (c.name === category));\n if (exists && result.length < limit) {\n result.push();\n }\n return result;\n }, []);\n }\n\n const otherCategories = [\n\t{title: 'Documents', link: '/category/documents/'}, \n\t{title: 'Guides', link: '/category/guides/'}, \n\t{title: 'Case Studies', link: '/category/case-studies/'},\n\t{title: 'Webinars', link: '/category/webinars/'}\n ];\n\n return (\n \t\n \n\t
\n\t \n\t
\n\t \n\t
\n\t\t
\n\t\t

Featured Articles

\n\t\t
\n\t\t\t\n\t\t
\n\t\t
\n\t\t

Blog

\n\t\t\t\t\t\n\t\t\t
\n\t\t\t\t\t\t\n\t\t\t {printFilteredArticles('Blog', posts, 4)}\n\t\t\t\t\t\t\n\t\t\t
\n\t\t
\n\t\t
\n\t\t\t\n\t\t{otherCategories.map((item, i) => {\n\t\t\tconst articles = printFilteredArticles(item.title, posts);\n\t\t\tif (articles.length) {\n\t\t\t\treturn(\n\t\t\t\t\t
\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t

{item.title}

\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t
\t\t\t\t\t\t\t\t\n\t\t\t\t\t \t{articles}\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t
\n\t\t\t\t\t\t\t

See more {item.title}

\n\t\t\t\t\t
\t\t\t\t\t\t\t\n\t\t\t\t\t
\n\t\t\t\t);\n\t\t\t}\n\t\t\treturn null;\n\t\t})}\n\t\t\t\n\t
\n
\n )\n}\n\nexport const pageQuery = graphql`\n query($id: String!) {\n allWpPage(filter: { id: { eq: $id } }) {\n nodes {\n ...PageSEOFragment\n }\n }\n allWpPost(sort: { fields: [date], order: DESC }) {\n nodes {\n ...PostFragment\n }\n }\n }\n`\n"],"names":["CategoryList","activeCategory","query","useStaticQuery","className","allWpCategory","nodes","length","map","item","i","wpPage","key","Link","to","uri","name","PostPreview","post","link","featuredImage","node","G","image","getImage","localFile","alt","title","categories","Array","prototype","call","join","date","ContentHub","data","page","allWpPage","posts","allWpPost","printFilteredArticles","category","limit","reduce","result","some","c","push","widget","layout","articles"],"sourceRoot":""}