Skip to content

Commit 7ed003d

Browse files
authored
docs: Add links for Mastering Pinia and Vue Certificate (#2036)
1 parent 679d99c commit 7ed003d

File tree

4 files changed

+113
-7
lines changed

4 files changed

+113
-7
lines changed
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
<script setup>
2+
const banners = [
3+
{
4+
id: 1,
5+
name: 'Vue.js Certification',
6+
link: 'https://certificates.dev/vuejs?friend=VUEROUTER',
7+
image: '/banners/vuejs-certification.svg',
8+
},
9+
{
10+
id: 2,
11+
name: 'Mastering Pinia',
12+
link: 'https://masteringpinia.com',
13+
image: '/banners/mastering-pinia.png',
14+
},
15+
]
16+
</script>
17+
18+
<template>
19+
<a
20+
v-for="banner in banners"
21+
:key="banner.id"
22+
:href="banner.link"
23+
target="_blank"
24+
:class="`banner_image_${banner.id}`"
25+
>
26+
<img :src="banner.image" :alt="banner.name" />
27+
</a>
28+
</template>
29+
30+
<style scoped>
31+
.banner_image_1 {
32+
padding: 25px 10px 0px 0px;
33+
}
34+
35+
.banner_image_2 {
36+
padding: 15px 10px 15px 0px;
37+
}
38+
</style>

packages/docs/.vitepress/theme/index.ts

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
1+
import { h } from 'vue'
12
import { Theme, useData } from 'vitepress'
23
import DefaultTheme from 'vitepress/theme'
3-
// import AsideSponsors from './components/AsideSponsors.vue'
4+
import AsideSponsors from './components/AsideSponsors.vue'
45
// import HomeSponsors from './components/HomeSponsors.vue'
56
import './styles/vars.css'
67
import './styles/sponsors.css'
@@ -9,12 +10,12 @@ import VueMasteryLogoLink from './components/VueMasteryLogoLink.vue'
910

1011
const theme: Theme = {
1112
...DefaultTheme,
12-
// Layout() {
13-
// return h(DefaultTheme.Layout, null, {
14-
// 'home-features-after': () => h(HomeSponsors),
15-
// 'aside-ads-before': () => h(AsideSponsors),
16-
// })
17-
// },
13+
Layout() {
14+
return h(DefaultTheme.Layout, null, {
15+
// 'home-features-after': () => h(HomeSponsors),
16+
'aside-ads-before': () => h(AsideSponsors),
17+
})
18+
},
1819

1920
enhanceApp({ app }) {
2021
app.component('VueSchoolLink', VueSchoolLink)
28.4 KB
Loading

0 commit comments

Comments
 (0)