diff --git a/astro.config.ts b/astro.config.ts index 34f10ae..571dddc 100644 --- a/astro.config.ts +++ b/astro.config.ts @@ -1,12 +1,13 @@ +// Astro integrations import mdx from '@astrojs/mdx' import partytown from '@astrojs/partytown' import sitemap from '@astrojs/sitemap' import { transformerCopyButton } from '@rehype-pretty/transformers' import compress from 'astro-compress' import robotsTxt from 'astro-robots-txt' -import { defineConfig } from 'astro/config' -// Rehype plugins +// Rehype plugins (HTML processors) +import { defineConfig } from 'astro/config' import rehypeAutolinkHeadings from 'rehype-autolink-headings' import rehypeComponents from 'rehype-components' import rehypeExternalLinks from 'rehype-external-links' @@ -14,21 +15,21 @@ import rehypeKatex from 'rehype-katex' import rehypePrettyCode from 'rehype-pretty-code' import rehypeSlug from 'rehype-slug' -// Remark plugins +// Remark plugins (Markdown processors) import remarkDirective from 'remark-directive' import remarkGithubAdmonitionsToDirectives from 'remark-github-admonitions-to-directives' import remarkMath from 'remark-math' import remarkSectionize from 'remark-sectionize' -import UnoCSS from 'unocss/astro' -import { themeConfig } from './src/config.js' -// Local plugins -import { AdmonitionComponent } from './src/plugins/rehype-component-admonition.js' -import { GithubCardComponent } from './src/plugins/rehype-component-github-card.js' -import { parseDirectiveNode } from './src/plugins/remark-directive-rehype.js' -import { remarkExcerpt } from './src/plugins/remark-excerpt.js' -import { remarkReadingTime } from './src/plugins/remark-reading-time.js' -import { langMap } from './src/utils/i18n/ui.js' +// Project configuration and utilities +import UnoCSS from 'unocss/astro' +import { themeConfig } from './src/config' +import { langMap } from './src/i18n/ui' +import { AdmonitionComponent } from './src/plugins/rehype-component-admonition' +import { GithubCardComponent } from './src/plugins/rehype-component-github-card' +import { parseDirectiveNode } from './src/plugins/remark-directive-rehype' +import { remarkExcerpt } from './src/plugins/remark-excerpt' +import { remarkReadingTime } from './src/plugins/remark-reading-time' const url = themeConfig.site.url const { light, dark } = themeConfig.color diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index f3cc804..61cff07 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -1623,8 +1623,8 @@ packages: duplexer@0.1.2: resolution: {integrity: sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg==} - electron-to-chromium@1.5.117: - resolution: {integrity: sha512-G4+CYIJBiQ72N0gi868tmG4WsD8bwLE9XytBdfgXO5zdlTlvOP2ABzWYILYxCIHmsbm2HjBSgm/E/H/QfcnIyQ==} + electron-to-chromium@1.5.118: + resolution: {integrity: sha512-yNDUus0iultYyVoEFLnQeei7LOQkL8wg8GQpkPCRrOlJXlcCwa6eGKZkxQ9ciHsqZyYbj8Jd94X1CTPzGm+uIA==} emmet@2.4.11: resolution: {integrity: sha512-23QPJB3moh/U9sT4rQzGgeyyGIrcM+GH5uVYg2C6wZIxAIJq7Ng3QLT79tl8FUwDXhyq9SusfknOrofAKqvgyQ==} @@ -5221,7 +5221,7 @@ snapshots: browserslist@4.24.4: dependencies: caniuse-lite: 1.0.30001704 - electron-to-chromium: 1.5.117 + electron-to-chromium: 1.5.118 node-releases: 2.0.19 update-browserslist-db: 1.1.3(browserslist@4.24.4) @@ -5480,7 +5480,7 @@ snapshots: duplexer@0.1.2: {} - electron-to-chromium@1.5.117: {} + electron-to-chromium@1.5.118: {} emmet@2.4.11: dependencies: diff --git a/src/components/Comments/Waline.astro b/src/components/Comments/Waline.astro index e31c8cf..c68d0f4 100644 --- a/src/components/Comments/Waline.astro +++ b/src/components/Comments/Waline.astro @@ -1,6 +1,6 @@ --- import { themeConfig } from '@/config' -import { getWalineLang } from '@/utils/i18n/ui' +import { getWalineLang } from '@/i18n/ui' const { serverURL = '', @@ -33,8 +33,7 @@ const { > - - +