Vitepress关注微信公主号页面
效果
教程
这个页面非常的简单,只需要在任意位置创建一个.md
文件粘贴以下代码即可
提示
二维码可以在草料二维码-点击打开服务生成,其他图片素材可以访问关注微信公众号页面右击图片-保存 自行参考尺寸
Markdown
---
title: 关注微信
aside: false
sidebar: false
---
<br/>
# 关注微信公众号
<div class="qr-container">
<div class="qr-code-box">
<img src="/image/about/qrcode.png" alt="微信公众号二维码" data-fancybox="gallery" class="qr-code-image">
<p class="qr-code-text">扫描二维码关注微信公众号</p>
<div class="qr-info-box">
<div class="qr-avatar">
<img src="/image/about/logo.png" width="100%">
</div>
<div class="qr-info-text">
<div class="qr-info-name">
进函科技社
<a href="/image/about/wx.png" download="进函科技社.png">
<img src="/image/about/download.svg" alt="下载" title="点击下载二维码" class="qr-download-button">
</a>
</div>
<div class="qr-info-slogan">探索未来,连接无限</div>
</div>
</div>
</div>
</div>
<style>
/* 隐藏底部 Footer */
.VPDocFooter{
display: none;
}
.qr-container {
display: flex;
justify-content: center;
align-items: center;
height: 55vh;
padding: 20px;
box-sizing: border-box;
}
.qr-code-box {
padding: 25px;
border-radius: 15px;
max-width: 320px;
text-align: center;
background-color: var(--vp-c-bg-soft);
border: 1px solid #80808025;
}
.qr-code-image {
width: 100%;
border-radius: 10px;
border: 1px solid #80808025;
}
.qr-code-text {
margin-top: 15px;
font-size: 0.9em;
font-weight: bold;
color: var(--vp-c-text-1);
}
.qr-info-box {
width: 100%;
background: #80808020;
padding: 15px;
border-radius: 15px;
display: flex;
align-items: center;
color: var(--info-text-color);
margin-top: 15px;
}
.qr-avatar {
width: 80px;
height: 100%;
margin-right: 15px;
}
.qr-info-text {
text-align: left;
display: flex;
flex-direction: column;
justify-content: center;
width: 100%;
}
.qr-info-name {
font-size: 1.2em;
font-weight: bold;
display: flex;
align-items: center;
}
.qr-info-name a {
margin-left: auto; /* 将下载按钮推到右侧 */
}
.qr-download-button {
width: 20px;
height: 20px;
}
.qr-info-slogan {
font-size: 0.9em;
font-weight: 600;
margin-top: 5px;
}
/* 响应式设计:在较小屏幕上调整字体大小 */
@media (max-width: 600px) {
.qr-code-box {
padding: 20px;
}
.qr-code-text {
font-size: 1em;
}
.qr-info-name {
font-size: 1em;
}
.qr-info-slogan {
font-size: 0.8em;
}
.qr-download-button {
width: 18px;
height: 18px;
}
}
</style>
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139