Skip to content

Commit 2032b45

Browse files
committed
首页速度优化
1 parent b82827b commit 2032b45

4 files changed

Lines changed: 9 additions & 12 deletions

File tree

packages/pure/components/basic/Footer.astro

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@
22
import { Icon as DevIcon } from 'astro-icon/components'
33
import config from 'virtual:config'
44
5+
import { getPlatformLabel, hasIcon } from '../../libs/social'
56
import { Icon } from '../user'
6-
import { hasIcon, getPlatformLabel } from '../../libs/social'
77
88
const footerConf = config.footer
99
const footerLink1 = footerConf.links?.filter(({ pos }) => pos === 1) || []
@@ -101,15 +101,12 @@ const socialLinks = normalizeSocialLinks(footerConf.social)
101101
<a
102102
href='https://github.com/cworld1/astro-theme-pure'
103103
target='_blank'
104-
class='hover:text-primary external-link'
104+
class='hover:text-primary external-link italic'
105105
>
106106
<DevIcon name='devicon:astro' class='size-4' />
107107
Astro & Pure theme
108108
</a>
109-
<span class='inline-flex items-center gap-x-1'>
110-
<Icon name='heart' class='size-4' />
111-
powered
112-
</span>
109+
<span class='inline-flex items-center gap-x-1'>powered</span>
113110
</span>
114111
)
115112
}

src/layouts/BaseLayout.astro

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
import { Footer, Header, ThemeProvider } from '@/custom/components/basic'
2+
import { Footer, Header } from '@/custom/components/basic'
33
44
import type { SiteMeta } from 'astro-pure/types'
55
import BaseHead from '@/components/BaseHead.astro'
@@ -33,7 +33,7 @@ const {
3333
<html lang={config.locale.lang}>
3434
<head>
3535
<BaseHead {articleDate} {description} {ogImage} {title} />
36-
<ThemeProvider />
36+
<!-- <ThemeProvider /> -->
3737
</head>
3838

3939
<body class:list={['flex justify-center bg-background text-foreground', bodyClass]} {...props}>

src/layouts/GalleryLayout.astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ const { title, description = config.description } = Astro.props
1919
<html lang={config.locale.lang}>
2020
<head>
2121
<BaseHead description={description} title={title} />
22-
<ThemeProvider />
22+
<!-- <ThemeProvider /> -->
2323
</head>
2424

2525
<body class="bg-background text-foreground">

src/pages/index.astro

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ const highlightColor = getHighlightColor()
3535
<div
3636
class='w-32 h-32 md:w-48 md:h-48 lg:w-56 lg:h-56 overflow-hidden rounded-lg'
3737
>
38-
<Image src={avatarImage} alt='Avatar' class='w-full h-full object-contain block' />
38+
<Image src={avatarImage} alt='Avatar' class='object-contain block' />
3939
</div>
4040
</div>
4141

@@ -51,7 +51,7 @@ const highlightColor = getHighlightColor()
5151
{/* 格言 */}
5252
<div class='pt-2 md:pt-4 border-t border-border'>
5353
<div
54-
class='text-sm md:text-base font-serif italic text-foreground/80 leading-relaxed max-w-xl'
54+
class='text-sm md:text-base font-serif text-foreground/80 leading-relaxed max-w-xl'
5555
>
5656
<span class='text-primary/50 text-lg md:text-xl leading-none mr-2'>"</span>
5757
{config.description}
@@ -84,7 +84,7 @@ const highlightColor = getHighlightColor()
8484
class='inline-flex inner-link items-center gap-1 text-muted-foreground hover:text-primary transition-colors'
8585
>
8686
<Image
87-
src='/favicon/android-chrome-512x512.png'
87+
src='/favicon/favicon-32x32.png'
8888
alt='Cat'
8989
width={16}
9090
height={16}

0 commit comments

Comments
 (0)