Skip to content

Commit 7bbefe6

Browse files
committed
fix: 修复 code 展示样式
1 parent e199506 commit 7bbefe6

File tree

4 files changed

+15
-9
lines changed

4 files changed

+15
-9
lines changed

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@
7878
"svg-sprite-loader": "^4.2.1",
7979
"svgo": "^1.3.2",
8080
"svgo-loader": "^2.2.1",
81-
"vuepress": "^1.3.0",
81+
"vuepress": "^1.3.1",
8282
"vuepress-plugin-flowchart": "^1.4.3",
8383
"vuepress-plugin-redirect": "^1.2.2"
8484
}

theme/mixins/index.js

-7
Original file line numberDiff line numberDiff line change
@@ -64,10 +64,3 @@ export default {
6464
},
6565
},
6666
};
67-
68-
function getMetaDescription(meta) {
69-
if (meta) {
70-
const descriptionMeta = meta.filter(item => item.name === 'description')[0];
71-
if (descriptionMeta) return descriptionMeta.content;
72-
}
73-
}

theme/styles/code.styl

+12
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,15 @@
88

99
.custom-style-wrapper.window-controls
1010
padding: 10px 0 0 10px;
11+
12+
div[class*="language-"].line-numbers-mode {
13+
.line-numbers-wrapper {
14+
top: 28px;
15+
margin: 0.85rem 0;
16+
}
17+
18+
&:after {
19+
top: 34px;
20+
bottom: 34px;
21+
}
22+
}

theme/styles/palette.styl

+2-1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ $borderColor = rgba(#888888, 0.25)
88
$codeBgColor = #282c34
99
$borderRadius = 2px;
1010
$backgroundColor = #ffffff
11-
$boxShadow = 0 1px 6px 0 rgba(0, 0, 0, 0.2)
11+
// $boxShadow = 0 1px 6px 0 rgba(0, 0, 0, 0.2)
12+
$boxShadow = rgba(0, 0, 0, 0.02) 0px 0px 6px 0px, rgba(0, 0, 0, 0.1) 0px 6px 12px -6px, rgba(0, 0, 0, 0.2) 0px -6px 26px -12px;
1213
$boxShadowHover = 0 2px 16px 0 rgba(0, 0, 0, 0.2)
1314

0 commit comments

Comments
 (0)