Skip to content

Commit 9139607

Browse files
authored
docs: improve image assets (vitejs#20578)
1 parent 2770478 commit 9139607

File tree

68 files changed

+56
-85
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

68 files changed

+56
-85
lines changed

docs/.vitepress/buildEnd.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ export const buildEnd = async (config: SiteConfig): Promise<void> => {
1414
id: blogUrl,
1515
link: blogUrl,
1616
language: 'en',
17-
image: 'https://vite.dev/og-image.png',
17+
image: 'https://vite.dev/og-image.jpg',
1818
favicon: 'https://vite.dev/logo.svg',
1919
copyright: 'Copyright © 2019-present VoidZero Inc. & Vite Contributors',
2020
})

docs/.vitepress/theme/components/AsideSponsors.vue

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,12 @@ const sponsors = computed(() => {
2424
href="https://viteconf.org/?utm=vite-sidebar"
2525
target="_blank"
2626
>
27-
<img width="22" height="22" src="/viteconf.svg" alt="ViteConf Logo" />
27+
<img
28+
width="22"
29+
height="22"
30+
src="../../../images/viteconf.svg"
31+
alt="ViteConf Logo"
32+
/>
2833
<span>
2934
<p class="extra-info">Building Together</p>
3035
<p class="heading">ViteConf 2025</p>

docs/.vitepress/theme/components/landing/1. hero-section/HeroDiagram.vue

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -470,7 +470,7 @@ onMounted(() => {
470470
</div>
471471
<div class="vite-chip__filter" />
472472
<img
473-
:src="isUwu ? '/logo-uwu.png' : '/logo.svg'"
473+
:src="isUwu ? '/logo-uwu.webp' : '/logo.svg'"
474474
:alt="isUwu ? 'Vite Kawaii Logo by @icarusgkx' : 'Vite Logo'"
475475
class="vite-chip__logo"
476476
:class="{ uwu: isUwu }"
@@ -715,7 +715,7 @@ onMounted(() => {
715715
}
716716
717717
background:
718-
url('/noise.png'),
718+
url('../common/noise.webp'),
719719
radial-gradient(
720720
circle at right center,
721721
rgb(86, 50, 119) 0%,
@@ -732,7 +732,7 @@ onMounted(() => {
732732
733733
@media (min-width: 1024px) {
734734
background:
735-
url('/noise.png'),
735+
url('../common/noise.webp'),
736736
radial-gradient(
737737
circle at right center,
738738
rgba(75, 41, 105, 0.5) 0%,
@@ -751,7 +751,7 @@ onMounted(() => {
751751
752752
@media (min-width: 1500px) {
753753
background:
754-
url('/noise.png'),
754+
url('../common/noise.webp'),
755755
radial-gradient(
756756
circle at right center,
757757
rgba(75, 41, 105, 0.5) 0%,
@@ -770,7 +770,7 @@ onMounted(() => {
770770
771771
@media (min-width: 1800px) {
772772
background:
773-
url('/noise.png'),
773+
url('../common/noise.webp'),
774774
radial-gradient(
775775
circle at right center,
776776
rgba(75, 41, 105, 0.5) 0%,

docs/.vitepress/theme/components/landing/1. hero-section/HeroSection.vue

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,12 @@ import HeroDiagram from './HeroDiagram.vue'
1111
class="hero__pill"
1212
target="_blank"
1313
>
14-
<img src="/viteconf.svg" alt="Viteconf logo" width="20" height="20" />
14+
<img
15+
src="../../../../../images/viteconf.svg"
16+
alt="Viteconf logo"
17+
width="20"
18+
height="20"
19+
/>
1520
<span>ViteConf 2025</span>
1621
</a>
1722

@@ -31,7 +36,7 @@ import HeroDiagram from './HeroDiagram.vue'
3136
target="_blank"
3237
class="btn btn--outline"
3338
>
34-
<img src="/github.svg" alt="GitHub logo" width="20" height="20" />
39+
<img src="./github.svg" alt="GitHub logo" width="20" height="20" />
3540
GitHub
3641
</a>
3742
</div>

docs/.vitepress/theme/components/landing/2. feature-section/FeatureInstantServerStart.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -344,7 +344,7 @@ onUnmounted(() => {
344344
height: 100%;
345345
border-radius: 12px 0 0 12px;
346346
background:
347-
url('/noise.png'),
347+
url('../common/noise.webp'),
348348
radial-gradient(
349349
ellipse 140% 80% at 96% bottom,
350350
#13b351 0%,
@@ -381,7 +381,7 @@ onUnmounted(() => {
381381
right: 40px;
382382
width: 1px;
383383
height: calc(100% - 170px - 33px);
384-
background: url('/noise.png'), #13b351;
384+
background: url('../common/noise.webp'), #13b351;
385385
box-shadow: 0 0 10px 0 #13b351;
386386
transition: all 0.5s ease-in;
387387
will-change: transform, opacity;

docs/.vitepress/theme/components/landing/5. sponsor-section/SponsorSection.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ const { data } = useSponsor()
4141
<!-- Title Section -->
4242
<img
4343
class="icon-heart"
44-
src="/heart.svg"
44+
src="./heart.svg"
4545
alt="Vite is made possible by our contributors, partner companies, and sponsors"
4646
width="58"
4747
height="55"
Binary file not shown.

0 commit comments

Comments
 (0)