-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcomponent---src-templates-author-tsx-305cb173b97977126fde.js.map
1 lines (1 loc) · 23.9 KB
/
component---src-templates-author-tsx-305cb173b97977126fde.js.map
1
{"version":3,"sources":["webpack:///./src/components/icons/website.tsx","webpack:///./src/templates/author.tsx","webpack:///./src/components/PostCard.tsx"],"names":["Website","Object","core_browser_esm","xmlns","viewBox","style","height","d","stroke","strokeLinejoin","strokeMiterlimit","fill","HiddenMobile","name","styles","AuthorMeta","styled_base_browser_esm","target","AuthorBio","Bull","AuthorProfileBioImage","pageQuery","Author","props","author","data","authorYaml","edges","allMarkdownRemark","filter","edge","node","frontmatter","draft","id","totalCount","length","layouts","Helmet_default","a","lang","config","title","content","bio","property","siteUrl","pathContext","slug","twitter","split","Wrapper","className","css","css_browser_esm","outer","SiteHeader","backgroundImage","profile_image","childImageSharp","fluid","src","inner","SiteNav","isHome","shared","AuthorProfileImage","avatar","alt","location","website","SocialLink","href","rel","facebook","SiteMain","PostFeed","PostFeedRaise","map","_ref","PostCard","key","fields","post","Footer","PostCardStyles","PostCardImageLink","PostCardImage","_emotion_styled_base__WEBPACK_IMPORTED_MODULE_1__","colors","lightgrey","PostCardContent","PostCardContentLink","darkgrey","PostCardTags","midgrey","PostCardTitle","PostCardExcerpt","PostCardMeta","AuthorList","AuthorListItem","AuthorNameTooltip","StaticAvatar","lighten","ReadingTime","_emotion_core__WEBPACK_IMPORTED_MODULE_2__","image","gatsby__WEBPACK_IMPORTED_MODULE_3__","to","gatsby_image__WEBPACK_IMPORTED_MODULE_4___default","tags","excerpt","_","children","fixed","timeToRead"],"mappings":"wOAceA,EAXW,kBACxBC,OAAAC,EAAA,EAAAD,CAAA,OAAKE,MAAM,6BAA6BC,QAAQ,YAAYC,MAAO,CAAEC,OAAQ,WAC3EL,OAAAC,EAAA,EAAAD,CAAA,QACEM,EAAE,wQACFC,OAAO,OACPC,eAAe,QACfC,iBAAiB,KACjBC,KAAK,4DCmBX,IAAM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OAAOlC,MACjF/C,OAAAwG,EAAA,EAAAxG,CAAA,UAAQmD,UAAU,oBACf+B,EAAKnD,YAAY8E,MAAQ7G,OAAAwG,EAAA,EAAAxG,CAAC6F,EAAD,KAAeX,EAAKnD,YAAY8E,KAAK,IAC/D7G,OAAAwG,EAAA,EAAAxG,CAAC+F,EAAD,KAAgBb,EAAKnD,YAAYU,QAEnCzC,OAAAwG,EAAA,EAAAxG,CAACgG,EAAD,KACEhG,OAAAwG,EAAA,EAAAxG,CAAA,SAAIkF,EAAK4B,WAGb9G,OAAAwG,EAAA,EAAAxG,CAACiG,EAAD,CAAc9C,UAAU,kBACtBnD,OAAAwG,EAAA,EAAAxG,CAACkG,EAAD,KACElG,OAAAwG,EAAA,EAAAxG,CAACmG,EAAD,KACEnG,OAAAwG,EAAA,EAAAxG,CAACoG,EAAD,CAAmBjD,UAAU,uBAC1B+B,EAAKnD,YAAYR,OAAOU,IAE3BjC,OAAAwG,EAAA,EAAAxG,CAAC0G,EAAA,EAAD,CAAMtD,IAAKiD,EAAcM,GAAE,WAAaI,YAAY7B,EAAKnD,YAAYR,OAAOU,IAAjD,KACzBjC,OAAAwG,EAAA,EAAAxG,CAACiE,EAAD,CACEL,IAAKsB,EAAKnD,YAAYR,OAAO2C,OAAO8C,SAAS,GAAGC,MAAMrD,IACtDO,IAAKe,EAAKnD,YAAYR,OAAOU,QAKrCjC,OAAAwG,EAAA,EAAAxG,CAACuG,EAAD,KAAcrB,EAAKgC,WAAnB","file":"component---src-templates-author-tsx-305cb173b97977126fde.js","sourcesContent":["// tslint:disable:no-http-string\nimport * as React from 'react';\n\nconst Website: React.FC = () => (\n <svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" style={{ height: '1.6rem' }}>\n <path\n d=\"M23.5 11.957c0 6.375-5.163 11.544-11.532 11.544C5.599 23.5.5 18.125.5 11.75.5 5.542 5.37.758 11.505.511l.5-.011C18.374.5 23.5 5.582 23.5 11.957zM11.505.511c-6 6.5-6 14.98 0 22.98m1-22.98c6 6.5 6 14.977 0 22.977M2 17.479h20.063m-19.657-12h19.062m-20.968 6h22.938\"\n stroke=\"#fff\"\n strokeLinejoin=\"round\"\n strokeMiterlimit=\"10\"\n fill=\"none\"\n />\n </svg>\n);\nexport default Website;\n","import { graphql } from 'gatsby';\nimport React from 'react';\nimport styled from '@emotion/styled';\nimport { css } from '@emotion/core';\n\nimport Footer from '../components/Footer';\nimport SiteNav from '../components/header/SiteNav';\nimport PostCard from '../components/PostCard';\nimport Wrapper from '../components/Wrapper';\nimport IndexLayout from '../layouts';\nimport {\n AuthorProfileImage,\n inner,\n outer,\n PostFeed,\n PostFeedRaise,\n SiteHeader,\n SiteHeaderContent,\n SiteTitle,\n SiteMain,\n SocialLink,\n} from '../styles/shared';\nimport { PageContext } from './post';\nimport Facebook from '../components/icons/facebook';\nimport Helmet from 'react-helmet';\nimport config from '../website-config';\nimport Website from '../components/icons/website';\nimport Twitter from '../components/icons/twitter';\n\nconst HiddenMobile = css`\n @media (max-width: 500px) {\n display: none;\n }\n`;\n\nconst AuthorMeta = styled.div`\n z-index: 10;\n flex-shrink: 0;\n display: flex;\n justify-content: center;\n align-items: center;\n margin: 0 0 10px 0;\n font-family: Georgia, serif;\n font-style: italic;\n`;\n\nconst AuthorBio = styled.h2`\n z-index: 10;\n flex-shrink: 0;\n margin: 5px 0 10px 0;\n max-width: 600px;\n font-size: 2rem;\n line-height: 1.3em;\n font-weight: 300;\n letter-spacing: 0.5px;\n opacity: 0.8;\n`;\n\nconst Bull = styled.span`\n display: inline-block;\n margin: 0 12px;\n opacity: 0.5;\n`;\n\nconst AuthorProfileBioImage = css`\n z-index: 10;\n flex-shrink: 0;\n margin: 0 0 20px 0;\n width: 100px;\n height: 100px;\n box-shadow: rgba(255, 255, 255, 0.1) 0 0 0 6px;\n`;\n\ninterface AuthorTemplateProps {\n pathContext: {\n slug: string;\n };\n pageContext: {\n author: string;\n };\n data: {\n logo: {\n childImageSharp: {\n fluid: any;\n };\n };\n allMarkdownRemark: {\n totalCount: number;\n edges: Array<{\n node: PageContext;\n }>;\n };\n authorYaml: {\n id: string;\n website?: string;\n twitter?: string;\n facebook?: string;\n location?: string;\n // eslint-disable-next-line @typescript-eslint/camelcase\n profile_image?: {\n childImageSharp: {\n fluid: any;\n };\n };\n bio?: string;\n avatar: {\n childImageSharp: {\n fluid: any;\n };\n };\n };\n };\n}\n\nconst Author: React.FC<AuthorTemplateProps> = props => {\n const author = props.data.authorYaml;\n\n const edges = props.data.allMarkdownRemark.edges.filter(\n edge => {\n const isDraft = (edge.node.frontmatter.draft !== true ||\n process.env.NODE_ENV === 'development');\n return isDraft && edge.node.frontmatter.author && edge.node.frontmatter.author.id === author.id;\n }\n );\n const totalCount = edges.length;\n\n return (\n <IndexLayout>\n <Helmet>\n <html lang={config.lang} />\n <title>\n {author.id} - {config.title}\n </title>\n <meta name=\"description\" content={author.bio} />\n <meta property=\"og:site_name\" content={config.title} />\n <meta property=\"og:type\" content=\"profile\" />\n <meta property=\"og:title\" content={`${author.id} - ${config.title}`} />\n <meta property=\"og:url\" content={config.siteUrl + props.pathContext.slug} />\n <meta property=\"article:publisher\" content=\"https://www.facebook.com/ghost\" />\n <meta property=\"article:author\" content=\"https://www.facebook.com/ghost\" />\n <meta name=\"twitter:card\" content=\"summary\" />\n <meta name=\"twitter:title\" content={`${author.id} - ${config.title}`} />\n <meta name=\"twitter:url\" content={config.siteUrl + props.pathContext.slug} />\n {config.twitter && (\n <meta\n name=\"twitter:site\"\n content={`@${config.twitter.split('https://twitter.com/')[1]}`}\n />\n )}\n {config.twitter && (\n <meta\n name=\"twitter:creator\"\n content={`@${config.twitter.split('https://twitter.com/')[1]}`}\n />\n )}\n </Helmet>\n <Wrapper>\n <header\n className=\"no-cover\"\n css={[outer, SiteHeader]}\n style={{\n // eslint-disable-next-line @typescript-eslint/camelcase\n backgroundImage: author.profile_image ?\n `url(${author.profile_image.childImageSharp.fluid.src})` :\n '',\n }}\n >\n <div css={inner}>\n <SiteNav isHome={false} />\n <SiteHeaderContent>\n <img\n css={[AuthorProfileImage, AuthorProfileBioImage]}\n src={props.data.authorYaml.avatar.childImageSharp.fluid.src}\n alt={author.id}\n />\n <SiteTitle>{author.id}</SiteTitle>\n {author.bio && <AuthorBio>{author.bio}</AuthorBio>}\n <AuthorMeta>\n {author.location && (\n <div css={HiddenMobile}>\n {author.location} <Bull>•</Bull>\n </div>\n )}\n <div css={HiddenMobile}>\n {totalCount > 1 && `${totalCount} posts`}\n {totalCount === 1 && '1 post'}\n {totalCount === 0 && 'No posts'} <Bull>•</Bull>\n </div>\n {author.website && (\n <div>\n <a\n className=\"social-link-wb\"\n css={SocialLink}\n href={author.website}\n title=\"Website\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n >\n <Website />\n </a>\n </div>\n )}\n {author.twitter && (\n <a\n className=\"social-link-tw\"\n css={SocialLink}\n href={`https://twitter.com/${author.twitter}`}\n title=\"Twitter\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n >\n <Twitter />\n </a>\n )}\n {author.facebook && (\n <a\n className=\"social-link-fb\"\n css={SocialLink}\n href={`https://www.facebook.com/${author.facebook}`}\n title=\"Facebook\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n >\n <Facebook />\n </a>\n )}\n {/* TODO: RSS for author */}\n {/* <a\n css={SocialLink} className=\"social-link-rss\"\n href=\"https://feedly.com/i/subscription/feed/https://demo.ghost.io/author/ghost/rss/\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n >\n <svg\n xmlns=\"http://www.w3.org/2000/svg\"\n viewBox=\"0 0 24 24\"\n style={{ height: '1.9rem' }}\n >\n <circle cx=\"6.18\" cy=\"17.82\" r=\"2.18\" />\n <path d=\"M4 4.44v2.83c7.03 0 12.73 5.7 12.73 12.73h2.83c0-8.59-6.97-15.56-15.56-15.56zm0 5.66v2.83c3.9 0 7.07 3.17 7.07 7.07h2.83c0-5.47-4.43-9.9-9.9-9.9z\" />\n </svg>\n </a> */}\n </AuthorMeta>\n </SiteHeaderContent>\n </div>\n </header>\n <main id=\"site-main\" css={[SiteMain, outer]}>\n <div css={inner}>\n <div css={[PostFeed, PostFeedRaise]}>\n {edges.map(({ node }) => {\n return <PostCard key={node.fields.slug} post={node} />;\n })}\n </div>\n </div>\n </main>\n <Footer />\n </Wrapper>\n </IndexLayout>\n );\n};\n\nexport default Author;\n\nexport const pageQuery = graphql`\n query($author: String) {\n authorYaml(id: { eq: $author }) {\n id\n website\n twitter\n bio\n facebook\n location\n profile_image {\n childImageSharp {\n fluid(maxWidth: 3720) {\n ...GatsbyImageSharpFluid\n }\n }\n }\n avatar {\n childImageSharp {\n fluid(maxWidth: 200) {\n ...GatsbyImageSharpFluid\n }\n }\n }\n }\n allMarkdownRemark(\n filter: { frontmatter: { draft: { ne: true } } },\n sort: { fields: [frontmatter___date], order: DESC },\n limit: 2000,\n ) {\n edges {\n node {\n excerpt\n timeToRead\n frontmatter {\n title\n tags\n date\n draft\n image {\n childImageSharp {\n fluid(maxWidth: 3720) {\n ...GatsbyImageSharpFluid\n }\n }\n }\n author {\n id\n bio\n avatar {\n children {\n ... on ImageSharp {\n fixed(quality: 90) {\n src\n }\n }\n }\n }\n }\n }\n fields {\n layout\n slug\n }\n }\n }\n }\n }\n`;\n","import { Link } from 'gatsby';\nimport Img from 'gatsby-image';\nimport * as _ from 'lodash';\nimport { lighten } from 'polished';\nimport * as React from 'react';\nimport styled from '@emotion/styled';\nimport { css } from '@emotion/core';\n\nimport { colors } from '../styles/colors';\nimport { PageContext } from '../templates/post';\n\nconst PostCardStyles = css`\n flex: 1 1 300px;\n display: flex;\n flex-direction: column;\n overflow: hidden;\n margin: 0 20px 40px;\n min-height: 300px;\n background: #fff center center;\n background-size: cover;\n border-radius: 5px;\n box-shadow: rgba(39, 44, 49, 0.06) 8px 14px 38px, rgba(39, 44, 49, 0.03) 1px 3px 8px;\n transition: all 0.5s ease;\n\n :hover {\n box-shadow: rgba(39, 44, 49, 0.07) 8px 28px 50px, rgba(39, 44, 49, 0.04) 1px 6px 12px;\n transition: all 0.4s ease;\n transform: translate3D(0, -1px, 0) scale(1.02);\n }\n`;\n\nconst PostCardImageLink = css`\n position: relative;\n display: block;\n overflow: hidden;\n border-radius: 5px 5px 0 0;\n`;\n\nconst PostCardImage = styled.div`\n width: auto;\n height: 200px;\n background: ${colors.lightgrey} no-repeat center center;\n background-size: cover;\n`;\n\nconst PostCardContent = styled.div`\n flex-grow: 1;\n display: flex;\n flex-direction: column;\n justify-content: space-between;\n`;\n\nconst PostCardContentLink = css`\n position: relative;\n flex-grow: 1;\n display: block;\n padding: 25px 25px 0;\n color: ${colors.darkgrey};\n\n :hover {\n text-decoration: none;\n }\n`;\n\nconst PostCardTags = styled.span`\n display: block;\n margin-bottom: 4px;\n color: ${colors.midgrey};\n font-size: 1.2rem;\n line-height: 1.15em;\n font-weight: 500;\n letter-spacing: 0.5px;\n text-transform: uppercase;\n`;\n\nconst PostCardTitle = styled.h2`\n margin-top: 0;\n`;\n\nconst PostCardExcerpt = styled.section`\n font-family: Georgia, serif;\n`;\n\nconst PostCardMeta = styled.footer`\n display: flex;\n justify-content: space-between;\n align-items: flex-end;\n padding: 0 25px 25px;\n`;\n\nconst AuthorList = styled.ul`\n display: flex;\n flex-wrap: wrap-reverse;\n margin: 0;\n padding: 0;\n list-style: none;\n`;\n\nconst AuthorListItem = styled.li`\n position: relative;\n flex-shrink: 0;\n margin: 0;\n padding: 0;\n\n :nth-of-type(1) {\n z-index: 10;\n }\n :nth-of-type(2) {\n z-index: 9;\n }\n :nth-of-type(3) {\n z-index: 8;\n }\n :nth-of-type(4) {\n z-index: 7;\n }\n :nth-of-type(5) {\n z-index: 6;\n }\n :nth-of-type(6) {\n z-index: 5;\n }\n :nth-of-type(7) {\n z-index: 4;\n }\n :nth-of-type(8) {\n z-index: 3;\n }\n :nth-of-type(9) {\n z-index: 2;\n }\n :nth-of-type(10) {\n z-index: 1;\n }\n :hover .author-name-tooltip {\n opacity: 1;\n transform: translateY(0px);\n }\n`;\n\nconst AuthorNameTooltip = styled.div`\n position: absolute;\n bottom: 105%;\n z-index: 999;\n display: block;\n padding: 2px 8px;\n color: white;\n font-size: 1.2rem;\n letter-spacing: 0.2px;\n white-space: nowrap;\n background: ${colors.darkgrey};\n border-radius: 3px;\n box-shadow: rgba(39, 44, 49, 0.08) 0 12px 26px, rgba(39, 44, 49, 0.03) 1px 3px 8px;\n opacity: 0;\n transition: all 0.3s cubic-bezier(0.4, 0.01, 0.165, 0.99);\n transform: translateY(6px);\n pointer-events: none;\n\n @media (max-width: 650px) {\n display: none;\n }\n`;\n\nconst StaticAvatar = css`\n display: block;\n overflow: hidden;\n margin: 0 -5px;\n width: 34px;\n height: 34px;\n border: #fff 2px solid;\n border-radius: 100%;\n`;\n\nconst AuthorProfileImage = styled.img`\n display: block;\n width: 100%;\n height: 100%;\n /* background: color(var(--lightgrey) l(+10%)); */\n background: ${lighten('0.1', colors.lightgrey)};\n border-radius: 100%;\n object-fit: cover;\n`;\n\nconst ReadingTime = styled.span`\n flex-shrink: 0;\n margin-left: 20px;\n color: ${colors.midgrey};\n font-size: 1.2rem;\n line-height: 33px;\n font-weight: 500;\n letter-spacing: 0.5px;\n text-transform: uppercase;\n`;\n\nexport interface PostCardProps {\n post: PageContext;\n}\n\nconst PostCard: React.FC<PostCardProps> = ({ post }) => {\n return (\n <article\n className={`post-card ${post.frontmatter.image ? '' : 'no-image'}`}\n css={PostCardStyles}\n >\n {post.frontmatter.image && (\n <Link className=\"post-card-image-link\" css={PostCardImageLink} to={post.fields.slug}>\n <PostCardImage className=\"post-card-image\">\n {post.frontmatter.image &&\n post.frontmatter.image.childImageSharp &&\n post.frontmatter.image.childImageSharp.fluid && (\n <Img\n alt={`${post.frontmatter.title} cover image`}\n style={{ height: '100%' }}\n fluid={post.frontmatter.image.childImageSharp.fluid}\n />\n )}\n </PostCardImage>\n </Link>\n )}\n <PostCardContent className=\"post-card-content\">\n <Link className=\"post-card-content-link\" css={PostCardContentLink} to={post.fields.slug}>\n <header className=\"post-card-header\">\n {post.frontmatter.tags && <PostCardTags>{post.frontmatter.tags[0]}</PostCardTags>}\n <PostCardTitle>{post.frontmatter.title}</PostCardTitle>\n </header>\n <PostCardExcerpt>\n <p>{post.excerpt}</p>\n </PostCardExcerpt>\n </Link>\n <PostCardMeta className=\"post-card-meta\">\n <AuthorList>\n <AuthorListItem>\n <AuthorNameTooltip className=\"author-name-tooltip\">\n {post.frontmatter.author.id}\n </AuthorNameTooltip>\n <Link css={StaticAvatar} to={`/author/${_.kebabCase(post.frontmatter.author.id)}/`}>\n <AuthorProfileImage\n src={post.frontmatter.author.avatar.children[0].fixed.src}\n alt={post.frontmatter.author.id}\n />\n </Link>\n </AuthorListItem>\n </AuthorList>\n <ReadingTime>{post.timeToRead} min read</ReadingTime>\n </PostCardMeta>\n </PostCardContent>\n </article>\n );\n};\n\nexport default PostCard;\n"],"sourceRoot":""}