File tree Expand file tree Collapse file tree 5 files changed +1970
-1026
lines changed Expand file tree Collapse file tree 5 files changed +1970
-1026
lines changed Original file line number Diff line number Diff line change
1
+ <script setup lang="ts">
2
+ import { reactive , onMounted } from ' vue'
3
+ import VPButton from ' vitepress/dist/client/theme-default/components/VPButton.vue'
4
+
5
+ const stats = reactive ({
6
+ github: ' --' ,
7
+ packagist: ' --' ,
8
+ });
9
+
10
+ onMounted (() => {
11
+ fetch (" https://packagist.org/packages/makinacorpus/db-tools-bundle.json" )
12
+ .then (raw => raw .json ())
13
+ .then (data => {
14
+ stats .packagist = data .package .downloads .monthly
15
+ stats .github = data .package .github_stars
16
+ });
17
+ });
18
+
19
+ </script >
20
+
21
+ <template >
22
+ <div class =" actions" >
23
+ <div class =" action" >
24
+ <VPButton
25
+ tag =" a"
26
+ size =" medium"
27
+ theme =" brand"
28
+ text =" Get Started"
29
+ href =" ./getting-started/introduction"
30
+ />
31
+ </div >
32
+ <div class =" action" >
33
+ <VPButton
34
+ tag =" a"
35
+ size =" medium"
36
+ theme =" alt"
37
+ text =" View on GitHub"
38
+ href =" https://github.com/makinacorpus/DbToolsBundle"
39
+ />
40
+ <small >{{ stats.github }} ⭐</small >
41
+
42
+ </div >
43
+ <div class =" action" >
44
+ <VPButton
45
+ tag =" a"
46
+ size =" medium"
47
+ theme =" alt"
48
+ text =" View on packagist"
49
+ href =" https://packagist.org/packages/makinacorpus/db-tools-bundle"
50
+ />
51
+ <small >{{ stats.packagist }} installs/month</small >
52
+ </div >
53
+ </div >
54
+ </template >
55
+
56
+ <style scoped>
57
+ .actions {
58
+ display : flex ;
59
+ flex-wrap : wrap ;
60
+ margin : -6px ;
61
+ padding-top : 24px ;
62
+ }
63
+
64
+ .actions small {
65
+ margin-top : -5px ;
66
+ }
67
+
68
+ @media (min-width : 640px ) {
69
+ .actions {
70
+ padding-top : 32px ;
71
+ }
72
+ }
73
+
74
+ @media (min-width : 960px ) {
75
+ .VPHero.has-image .actions {
76
+ justify-content : flex-start ;
77
+ }
78
+ }
79
+
80
+ .action {
81
+ flex-shrink : 0 ;
82
+ padding : 6px ;
83
+ display : flex ;
84
+ flex-direction : column ;
85
+ justify-content : start ;
86
+ align-items : center ;
87
+ gap : 0.4rem ;
88
+ }
89
+ </style >
Original file line number Diff line number Diff line change 7
7
--vp-c-brand-lighter : # a279e0 ;
8
8
--vp-c-brand-dark : # 221157 ;
9
9
--vp-c-brand-darker : # 221157 ;
10
+ --vp-button-brand-bg : var (--vp-c-brand );
11
+ --vp-button-brand-hover-bg : var (--vp-c-brand-dark );
10
12
--vp-c-text-code : # 221157 ;
11
13
--vp-button-brand-border : transparent;
12
14
--vp-button-brand-hover-border : transparent;
Original file line number Diff line number Diff line change @@ -4,13 +4,16 @@ import './custom.css'
4
4
import MakinaCorpusHorizontal from './MakinaCorpusHorizontal.vue'
5
5
import MakinaCorpusSquare from './MakinaCorpusSquare.vue'
6
6
import { h } from 'vue'
7
+ import DbToolsBundleActions from './DbToolsBundleActions.vue'
7
8
8
9
export default {
9
- ... DefaultTheme ,
10
+ extends : DefaultTheme ,
10
11
Layout ( ) {
11
12
return h ( DefaultTheme . Layout , null , {
12
13
'aside-bottom' : ( ) => h ( MakinaCorpusSquare ) ,
13
14
'home-features-after' : ( ) => h ( MakinaCorpusHorizontal ) ,
15
+ 'home-hero-actions-after' : ( ) => h ( DbToolsBundleActions )
14
16
} )
15
- }
17
+ } ,
18
+ VPHomeHero : DbToolsBundleActions ,
16
19
}
Original file line number Diff line number Diff line change 8
8
light : ./logo.svg
9
9
dark : ./logo-d.svg
10
10
alt : DbToolsBundle by Makina Corpus
11
- actions :
12
- - theme : brand
13
- text : Get Started
14
- link : ./getting-started/introduction
15
- - theme : alt
16
- text : View on GitHub
17
- link : https://github.com/makinacorpus/DbToolsBundle
18
- - theme : alt
19
- text : View on Packagist
20
- link : https://packagist.org/packages/makinacorpus/db-tools-bundle
21
11
22
12
features :
23
13
- icon :
You can’t perform that action at this time.
0 commit comments