docs: update vitepress and add active match to nav (#8376)

This commit is contained in:
Kia King Ishii 2022-05-29 15:27:09 +09:00 committed by GitHub
parent 37eb5b3efd
commit 4b1a22cc49
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
11 changed files with 31 additions and 27 deletions

View File

@ -53,9 +53,9 @@ export default defineConfig({
},
nav: [
{ text: 'Guide', link: '/guide/' },
{ text: 'Config', link: '/config/' },
{ text: 'Plugins', link: '/plugins/' },
{ text: 'Guide', link: '/guide/', activeMatch: '/guide/' },
{ text: 'Config', link: '/config/', activeMatch: '/config/' },
{ text: 'Plugins', link: '/plugins/', activeMatch: '/plugins/' },
{
text: 'Links',
items: [

View File

@ -9,6 +9,7 @@ const { data } = useSponsor()
<VPHomeSponsors
v-if="data"
message="Vite is free and open source, made possible by wonderful sponsors."
action-text="Become a sponsor"
action-link="https://github.com/sponsors/yyx990803"
:data="data"
/>

View File

@ -1,7 +1,6 @@
import { h } from 'vue'
import Theme from 'vitepress/theme'
import './styles/vars.css'
import './styles/custom.css'
import HomeSponsors from './components/HomeSponsors.vue'
import AsideSponsors from './components/AsideSponsors.vue'
@ -10,7 +9,7 @@ export default {
Layout() {
return h(Theme.Layout, null, {
'home-features-after': () => h(HomeSponsors),
'aside-outline-after': () => h(AsideSponsors)
'aside-ads-before': () => h(AsideSponsors)
})
}
}

View File

@ -1,15 +0,0 @@
@media (min-width: 640px) {
.VPHero .text {
max-width: 592px;
}
.VPHero .tagline {
max-width: 440px;
}
}
@media (min-width: 960px) {
.VPHero .tagline {
max-width: 480px;
}
}

View File

@ -38,6 +38,25 @@
#bd34fe 30%,
#41d1ff
);
--vp-home-hero-image-background-image: linear-gradient(
-45deg,
#bd34fe 50%,
#47caff 50%
);
--vp-home-hero-image-filter: blur(40px);
}
@media (min-width: 640px) {
:root {
--vp-home-hero-image-filter: blur(56px);
}
}
@media (min-width: 960px) {
:root {
--vp-home-hero-image-filter: blur(72px);
}
}
/**

View File

@ -9,8 +9,8 @@ hero:
text: Next Generation Frontend Tooling
tagline: Get ready for a development environment that can finally catch up with you.
image:
light: /vite-splash-light.jpg
dark: /vite-splash-dark.jpg
src: /logo-with-shadow.png
alt: Vite
actions:
- theme: brand
text: Get Started

Binary file not shown.

After

Width:  |  Height:  |  Size: 66 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 61 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 62 KiB

View File

@ -88,7 +88,7 @@
"typescript": "^4.6.4",
"unbuild": "^0.7.4",
"vite": "workspace:*",
"vitepress": "1.0.0-draft.6",
"vitepress": "1.0.0-draft.8",
"vitest": "^0.12.9",
"vue": "^3.2.35"
},

View File

@ -64,7 +64,7 @@ importers:
typescript: ^4.6.4
unbuild: ^0.7.4
vite: workspace:*
vitepress: 1.0.0-draft.6
vitepress: 1.0.0-draft.8
vitest: ^0.12.9
vue: ^3.2.35
devDependencies:
@ -122,7 +122,7 @@ importers:
typescript: 4.6.4
unbuild: 0.7.4
vite: link:packages/vite
vitepress: 1.0.0-draft.6
vitepress: 1.0.0-draft.8
vitest: 0.12.9
vue: 3.2.36
@ -8466,8 +8466,8 @@ packages:
engines: {node: '>= 0.8'}
dev: true
/vitepress/1.0.0-draft.6:
resolution: {integrity: sha512-l5V9Z31+D9EBFy4na7aNhAQ4MKRGVuwjBlFKDkY4kSRHPDPUC9XcNbH1mbWepeYaauJc9IDniWj7uVU6ZqJ53g==}
/vitepress/1.0.0-draft.8:
resolution: {integrity: sha512-r1cphHgtJ/KFwtph3cyusGWjRyX0NHvwfBboKnG5mRJpOP/JyvX5q5+NIiRYElPgdFXU7Roxkl8BcJbxWht56Q==}
engines: {node: '>=14.6.0'}
hasBin: true
dependencies: