From cf3365e77861d6bf40055dac69db30f4220542f1 Mon Sep 17 00:00:00 2001 From: Kamran Ahmed Date: Fri, 24 Apr 2020 22:45:23 +0400 Subject: [PATCH] feat: add carbon --- components/page-footer/carbon.scss | 62 ++++++++++++++++++++++++++++++ components/page-footer/index.js | 12 +++--- pages/guides/index.js | 4 +- public/sitemap.xml | 12 ++++++ 4 files changed, 83 insertions(+), 7 deletions(-) create mode 100644 components/page-footer/carbon.scss diff --git a/components/page-footer/carbon.scss b/components/page-footer/carbon.scss new file mode 100644 index 000000000..7d886bc07 --- /dev/null +++ b/components/page-footer/carbon.scss @@ -0,0 +1,62 @@ +#carbonads { + font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, + Cantarell, "Helvetica Neue", Helvetica, Arial, sans-serif; + position: fixed; + bottom: 15px; + right: 20px; +} + +#carbonads { + display: flex; + max-width: 330px; + background-color: hsl(0, 0%, 98%); + box-shadow: 0 1px 4px 1px hsla(0, 0%, 0%, .1); +} + +#carbonads a { + color: inherit; + text-decoration: none; +} + +#carbonads a:hover { + color: inherit; +} + +#carbonads span { + position: relative; + display: block; + overflow: hidden; +} + +#carbonads .carbon-wrap { + display: flex; +} + +.carbon-img { + display: block; + margin: 0; + line-height: 1; +} + +.carbon-img img { + display: block; +} + +.carbon-text { + font-size: 13px; + padding: 10px; + line-height: 1.5; + text-align: left; +} + +.carbon-poweredby { + display: block; + padding: 8px 10px; + background: repeating-linear-gradient(-45deg, transparent, transparent 5px, hsla(0, 0%, 0%, .025) 5px, hsla(0, 0%, 0%, .025) 10px) hsla(203, 11%, 95%, .4); + text-align: center; + text-transform: uppercase; + letter-spacing: .5px; + font-weight: 600; + font-size: 9px; + line-height: 1; +} diff --git a/components/page-footer/index.js b/components/page-footer/index.js index 41ded572d..7df75ba63 100644 --- a/components/page-footer/index.js +++ b/components/page-footer/index.js @@ -1,6 +1,6 @@ -import Link from 'next/link'; -import siteConfig from "content/site"; -import { FooterWrap } from './style.js' +import siteConfig from 'content/site'; +import { FooterWrap } from './style.js'; +import './carbon.scss'; const PageFooter = () => ( @@ -53,11 +53,13 @@ const PageFooter = () => ( + {/* Do not show on local */} { process.env.GA_SECRET && ( <> -
- + + {/*
*/} + {/**/} ) }
diff --git a/pages/guides/index.js b/pages/guides/index.js index 7ac556a11..11609bd54 100644 --- a/pages/guides/index.js +++ b/pages/guides/index.js @@ -1,14 +1,14 @@ import { faCodeBranch, faEnvelope } from '@fortawesome/free-solid-svg-icons/index'; import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'; import { BadgeLink, BadgesList, PrimaryBadge, SecondaryBadge } from 'components/badges'; -import FeaturedGuide from 'components/featured-guide'; import DefaultLayout from 'layouts/default/index'; import PageHeader from 'components/page-header'; import PageFooter from 'components/page-footer'; import SiteNav from 'components/site-nav'; -import { getAllGuides } from 'lib/guide'; import siteConfig from 'content/site'; import Helmet from 'components/helmet'; +import { getAllGuides } from '../../lib/guide'; +import FeaturedGuide from '../../components/featured-guide'; const PageTitle = "Programming Guides"; const PageDescription = "Easy to follow guides on complex topics written and maintained by the community"; diff --git a/public/sitemap.xml b/public/sitemap.xml index f7cef8eb7..d9cc6c305 100644 --- a/public/sitemap.xml +++ b/public/sitemap.xml @@ -30,6 +30,12 @@ 2020-01-29T07:49:29.706Z 1.0 + + https://roadmap.sh/guides/ssl-tls-https-ssh + monthly + 2020-04-22T15:48:21.191Z + 1.0 + https://roadmap.sh/guides/asymptotic-notation monthly @@ -48,6 +54,12 @@ 2020-03-14T15:48:21.191Z 1.0 + + https://roadmap.sh/guides/scaling-databases + monthly + 2020-02-18T15:48:21.191Z + 1.0 + https://roadmap.sh/guides/what-is-internet monthly