From 6b148795075a2db0438b58662941838d391a7474 Mon Sep 17 00:00:00 2001 From: prototypa Date: Fri, 29 Mar 2024 00:49:47 -0400 Subject: [PATCH] Refactor tu use astrowind:config virtual import --- src/components/Logo.astro | 2 +- src/components/blog/GridItem.astro | 2 +- src/components/blog/ListItem.astro | 2 +- src/components/blog/RelatedPosts.astro | 2 +- src/components/blog/Tags.astro | 2 +- src/components/blog/ToBlogLink.astro | 2 +- src/components/common/Analytics.astro | 2 +- src/components/common/ApplyColorMode.astro | 2 +- src/components/common/BasicScripts.astro | 2 +- src/components/common/Metadata.astro | 2 +- src/components/common/SiteVerification.astro | 2 +- src/components/common/ToggleTheme.astro | 2 +- .../widgets/BlogHighlightedPosts.astro | 2 +- src/components/widgets/BlogLatestPosts.astro | 2 +- src/components/widgets/Footer.astro | 2 +- src/layouts/LandingLayout.astro | 2 +- src/layouts/Layout.astro | 2 +- src/layouts/PageLayout.astro | 2 +- src/pages/rss.xml.ts | 2 +- src/utils/blog.ts | 2 +- src/utils/permalinks.ts | 2 +- src/utils/utils.ts | 16 +++++++--------- 22 files changed, 28 insertions(+), 30 deletions(-) diff --git a/src/components/Logo.astro b/src/components/Logo.astro index f196575..ae9b9fd 100644 --- a/src/components/Logo.astro +++ b/src/components/Logo.astro @@ -1,5 +1,5 @@ --- -import { SITE } from '~/utils/config'; +import { SITE } from 'astrowind:config'; --- diff --git a/src/components/blog/GridItem.astro b/src/components/blog/GridItem.astro index 360de3d..3625a68 100644 --- a/src/components/blog/GridItem.astro +++ b/src/components/blog/GridItem.astro @@ -1,5 +1,5 @@ --- -import { APP_BLOG } from '~/utils/config'; +import { APP_BLOG } from 'astrowind:config'; import type { Post } from '~/types'; import Image from '~/components/common/Image.astro'; diff --git a/src/components/blog/ListItem.astro b/src/components/blog/ListItem.astro index dff647f..3945062 100644 --- a/src/components/blog/ListItem.astro +++ b/src/components/blog/ListItem.astro @@ -4,7 +4,7 @@ import { Icon } from 'astro-icon/components'; import Image from '~/components/common/Image.astro'; import PostTags from '~/components/blog/Tags.astro'; -import { APP_BLOG } from '~/utils/config'; +import { APP_BLOG } from 'astrowind:config'; import type { Post } from '~/types'; import { getPermalink } from '~/utils/permalinks'; diff --git a/src/components/blog/RelatedPosts.astro b/src/components/blog/RelatedPosts.astro index e193baf..65f3b40 100644 --- a/src/components/blog/RelatedPosts.astro +++ b/src/components/blog/RelatedPosts.astro @@ -1,5 +1,5 @@ --- -import { APP_BLOG } from "~/utils/config"; +import { APP_BLOG } from "astrowind:config"; import { fetchPosts, getRelatedPosts } from "~/utils/blog"; import BlogHighlightedPosts from "../widgets/BlogHighlightedPosts.astro"; diff --git a/src/components/blog/Tags.astro b/src/components/blog/Tags.astro index 04e2a01..9dc1dc1 100644 --- a/src/components/blog/Tags.astro +++ b/src/components/blog/Tags.astro @@ -1,7 +1,7 @@ --- import { getPermalink } from '~/utils/permalinks'; -import { APP_BLOG } from '~/utils/config'; +import { APP_BLOG } from 'astrowind:config'; import type { Post } from '~/types'; export interface Props { diff --git a/src/components/blog/ToBlogLink.astro b/src/components/blog/ToBlogLink.astro index e3e28ef..7fb7a49 100644 --- a/src/components/blog/ToBlogLink.astro +++ b/src/components/blog/ToBlogLink.astro @@ -1,7 +1,7 @@ --- import { Icon } from 'astro-icon/components'; import { getBlogPermalink } from '~/utils/permalinks'; -import { I18N } from '~/utils/config'; +import { I18N } from 'astrowind:config'; import Button from '~/components/ui/Button.astro'; const { textDirection } = I18N; diff --git a/src/components/common/Analytics.astro b/src/components/common/Analytics.astro index 8bf883a..78b74e4 100644 --- a/src/components/common/Analytics.astro +++ b/src/components/common/Analytics.astro @@ -1,6 +1,6 @@ --- import { GoogleAnalytics } from '@astrolib/analytics'; -import { ANALYTICS } from '~/utils/config'; +import { ANALYTICS } from 'astrowind:config'; --- { diff --git a/src/components/common/ApplyColorMode.astro b/src/components/common/ApplyColorMode.astro index f7e2b54..f19505d 100644 --- a/src/components/common/ApplyColorMode.astro +++ b/src/components/common/ApplyColorMode.astro @@ -1,5 +1,5 @@ --- -import { UI } from "~/utils/config"; +import { UI } from "astrowind:config"; // TODO: This code is temporary --- diff --git a/src/components/common/BasicScripts.astro b/src/components/common/BasicScripts.astro index a2f9c29..33df4b4 100644 --- a/src/components/common/BasicScripts.astro +++ b/src/components/common/BasicScripts.astro @@ -1,5 +1,5 @@ --- -import { UI } from '~/utils/config'; +import { UI } from 'astrowind:config'; ---