mirror of
https://github.com/reonokiy/blog.nokiy.net.git
synced 2025-06-17 03:56:19 +02:00
chore: delete Open Graph configuration and change favicon format
This commit is contained in:
parent
a556a622ab
commit
db1bffb4c2
6 changed files with 9 additions and 19 deletions
|
@ -1,4 +1,3 @@
|
|||
import { themeConfig } from '@/config'
|
||||
import { generateDescription } from '@/utils/description'
|
||||
import { OGImageRoute } from 'astro-og-canvas'
|
||||
import { getCollection } from 'astro:content'
|
||||
|
@ -6,11 +5,6 @@ import { getCollection } from 'astro:content'
|
|||
// eslint-disable-next-line antfu/no-top-level-await
|
||||
const blogEntries = await getCollection('posts')
|
||||
|
||||
// 确定favicon路径是完整URL还是相对路径
|
||||
const logoPath = themeConfig.site.favicon.startsWith('http')
|
||||
? themeConfig.site.favicon
|
||||
: `./public${themeConfig.site.favicon}`
|
||||
|
||||
// Convert to page data objects
|
||||
const pages = Object.fromEntries(
|
||||
blogEntries.map(post => [
|
||||
|
@ -30,7 +24,7 @@ export const { getStaticPaths, GET } = OGImageRoute({
|
|||
title: page.title,
|
||||
description: page.description,
|
||||
logo: {
|
||||
path: logoPath,
|
||||
path: './public/image/Astro-Icon-Dark.png',
|
||||
size: [80],
|
||||
},
|
||||
font: {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue