diff --git a/public/ayoayco-avatar.jpg b/public/ayoayco-avatar.jpg new file mode 100644 index 0000000..5ac6c29 Binary files /dev/null and b/public/ayoayco-avatar.jpg differ diff --git a/src/components/blog/BaseHead.astro b/src/components/blog/BaseHead.astro index 02ea55d..1af1815 100644 --- a/src/components/blog/BaseHead.astro +++ b/src/components/blog/BaseHead.astro @@ -21,7 +21,7 @@ description = title === SITE_TITLE - + diff --git a/src/consts.ts b/src/consts.ts index 1628819..efa8b59 100644 --- a/src/consts.ts +++ b/src/consts.ts @@ -1,5 +1,6 @@ export const SITE_TITLE = 'Cozy Blog'; export const SITE_AUTHOR = 'Ayo Ayco'; +export const SITE_AUTHOR_URL = 'https://ayo.ayco.io'; export const SITE_AUTHOR_MASTODON = 'https://social.ayco.io/@ayo'; export const SITE_PROJECT_REPO = 'https://github.com/ayoayco/Cozy'; export const SITE_DESCRIPTION = 'The Web is Yours.'; diff --git a/src/content/blog/building-a-cozy-web.md b/src/content/blog/building-a-cozy-web.md index da57784..038b3b2 100644 --- a/src/content/blog/building-a-cozy-web.md +++ b/src/content/blog/building-a-cozy-web.md @@ -5,7 +5,7 @@ pubDate: 'Aug 14 2024' heroImage: '/cozy.jpg' --- -> This was originally posted on [Ayo's Blog](https://ayos.blog/building-a-cozy-web). +> This was originally posted on [Ayo's Blog](https://ayos.blog/building-a-cozy-web) last Jun 1, 2023. Have you ever clicked a link to an article, all hyped up to read the content, only to be slapped in the face with popups over popups of requests to subscribe and asking consent to track you with cookies? diff --git a/src/layouts/BlogPost.astro b/src/layouts/BlogPost.astro index 5555d42..5fc4831 100644 --- a/src/layouts/BlogPost.astro +++ b/src/layouts/BlogPost.astro @@ -4,6 +4,7 @@ import Header from "../components/blog/Header.astro"; import Footer from "../components/blog/Footer.astro"; import FormattedDate from "../components/blog/FormattedDate.astro"; import type { CollectionEntry } from "astro:content"; +import { SITE_AUTHOR, SITE_AUTHOR_URL } from "../consts"; type Props = CollectionEntry<"blog">["data"]; @@ -17,8 +18,30 @@ const { title, description, pubDate, updatedDate, heroImage } = Astro.props; main { width: calc(100% - 2em); max-width: 100%; - margin: 0; + margin: 0 auto; } + + & .cta-wrapper { + width: 100%; + text-align: center; + padding: 1em 0; + } + + & span.primary-btn { + background-color: rgba(var(--black), 95%); + box-shadow: 0 2px 8px rgba(var(--black), 5%); + color: white; + border-radius: 5px; + display: inline-block; + text-align: center; + padding: 0 0.5em; + } + + & span.primary-btn:hover { + background-color: var(--accent); + box-shadow: 0 2px 8px var(--accent); + } + .hero-image { width: 100%; } @@ -26,13 +49,12 @@ const { title, description, pubDate, updatedDate, heroImage } = Astro.props; display: block; margin: 0 auto; border-radius: 12px; - box-shadow: var(--box-shadow); } .prose { width: 720px; max-width: calc(100% - 2em); margin: auto; - padding: 1em; + padding: 0 1em; color: rgb(var(--gray-dark)); } .title { @@ -40,9 +62,23 @@ const { title, description, pubDate, updatedDate, heroImage } = Astro.props; padding: 1em 0; text-align: center; line-height: 1; - } - .title h1 { - margin: 0 0 0.5em 0; + + & .avatar { + width: 32px; + height: 32px; + border-radius: 50%; + display: inline; + /* height: calc(1rem + 6px); */ + margin: 0 0.5rem; + margin-bottom: -10px; + } + + & a[rel='author'] { + color: rgb(var(--black)); + } + & a[rel='author']:hover { + color: var(--accent); + } } .date { margin-bottom: 0.5em; @@ -93,11 +129,19 @@ const { title, description, pubDate, updatedDate, heroImage } = Astro.props; }

{title}

-
+
+ By Ayo Ayco's Avatar +
+
+
+ + Get Cozy! + +