From 680b896e5890cee2be2e07a1394a1ef81b5c051e Mon Sep 17 00:00:00 2001 From: Somrat <58769763+tfsomrat@users.noreply.github.com> Date: Mon, 17 Feb 2025 11:52:56 +0600 Subject: [PATCH] update theme variable --- src/config/theme.json | 25 ++++++++++++++++------- src/layouts/PostSingle.astro | 4 ++-- src/layouts/components/AuthorCard.astro | 4 +--- src/layouts/components/Breadcrumbs.astro | 4 +++- src/layouts/components/Pagination.astro | 12 +++++------ src/layouts/partials/CallToAction.astro | 2 +- src/layouts/partials/Footer.astro | 6 ++++-- src/layouts/partials/Header.astro | 4 ++-- src/layouts/partials/PageHeader.astro | 2 +- src/layouts/partials/PostSidebar.astro | 6 +++--- src/layouts/partials/Testimonial.astro | 10 ++++----- src/pages/404.astro | 2 +- src/pages/categories/index.astro | 2 +- src/pages/tags/index.astro | 2 +- src/styles/base.css | 2 +- src/styles/buttons.css | 4 ++-- src/styles/components.css | 26 ++++++++++++------------ src/styles/navigation.css | 6 +++--- src/styles/safe.css | 2 +- src/styles/search.css | 12 +++++------ src/styles/utilities.css | 6 +++--- 21 files changed, 78 insertions(+), 65 deletions(-) diff --git a/src/config/theme.json b/src/config/theme.json index 0352ca2..4924af2 100755 --- a/src/config/theme.json +++ b/src/config/theme.json @@ -5,20 +5,28 @@ "primary": "#121212", "body": "#fff", "border": "#eaeaea", - "theme_light": "#f6f6f6", - "theme_dark": "" + "light": "#f6f6f6", + "dark": "#040404" }, - "text_color": { "text": "#444444", "dark": "#040404", "light": "#717171" } + "text_color": { + "text": "#444444", + "text-dark": "#040404", + "text-light": "#717171" + } }, "darkmode": { "theme_color": { "primary": "#fff", "body": "#1c1c1c", "border": "#3E3E3E", - "theme_light": "#222222", - "theme_dark": "" + "light": "#222222", + "dark": "#fff" }, - "text_color": { "text": "#B4AFB6", "dark": "#fff", "light": "#B4AFB6" } + "text_color": { + "text": "#B4AFB6", + "text-dark": "#fff", + "text-light": "#B4AFB6" + } } }, "fonts": { @@ -28,6 +36,9 @@ "secondary": "Signika:wght@500;700", "secondary_type": "sans-serif" }, - "font_size": { "base": "16", "scale": "1.2" } + "font_size": { + "base": "16", + "scale": "1.2" + } } } diff --git a/src/layouts/PostSingle.astro b/src/layouts/PostSingle.astro index 607be15..8af526e 100755 --- a/src/layouts/PostSingle.astro +++ b/src/layouts/PostSingle.astro @@ -6,9 +6,9 @@ import { getSinglePage } from "@/lib/contentParser.astro"; import dateFormat from "@/lib/utils/dateFormat"; import similarItems from "@/lib/utils/similarItems"; import { humanize, markdownify, slugify } from "@/lib/utils/textConverter"; +import { render } from "astro:content"; import { FaRegClock, FaRegFolder, FaRegUserCircle } from "react-icons/fa"; import ImageMod from "./components/ImageMod.astro"; -import { render } from "astro:content"; const COLLECTION_FOLDER = "blog"; const { post } = Astro.props; @@ -72,7 +72,7 @@ const { title, description, author, categories, image, date, tags } = post.data; tags.map((tag: string) => (