Skip to content

Commit 9980f5c

Browse files
committed
docs: site updated
1 parent 0ff561d commit 9980f5c

File tree

2 files changed

+17
-14
lines changed

2 files changed

+17
-14
lines changed

site/pages/documents/Header.vue

+16-13
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
<li><a href="https://zarm.design">首页</a></li>
2626
<li><a href="https://zarm.design/#/components/quick-start">React 组件</a></li>
2727
<li><a href="#/documents/quick-start" class="active">Vue 组件</a></li>
28+
<li><a href="https://zarm.design/#/design/download">设计</a></li>
2829
<li><a href="https://github.com/ZhonganTechENG/zarm-vue" target="_blank" rel="noopener noreferrer">Github</a></li>
2930
</ul>
3031
</nav>
@@ -34,15 +35,16 @@
3435

3536
<script>
3637
import Format from '../../utils/format';
37-
import Demo from '../../demos';
38+
import Demo from '../../demos';
39+
3840
export default {
3941
data() {
4042
return {
4143
Demo,
4244
componentList: [],
4345
componentName: '',
4446
options: [],
45-
value: ''
47+
value: '',
4648
};
4749
},
4850
created() {
@@ -53,39 +55,39 @@ export default {
5355
},
5456
mounted() {
5557
docsearch({
56-
apiKey: '59f746e0b69134f4afaece614544e197',
57-
indexName: 'zarm-vue',
58+
apiKey: '59f746e0b69134f4afaece614544e197',
59+
indexName: 'zarm-vue',
5860
inputSelector: '.search input',
5961
debug: false,
6062
});
6163
},
6264
watch: {
63-
"$route"(val) {
65+
$route(val) {
6466
const { path } = this.$route;
65-
this.activeName = path.replace('/documents/', '')
66-
}
67+
this.activeName = path.replace('/documents/', '');
68+
},
6769
},
6870
methods: {
6971
initComponentList() {
7072
const { components } = this.Demo;
7173
const List = [...components.form, ...components.feedback, ...components.view, ...components.navigation, ...components.other];
7274
this.componentList = List.map(i => (
73-
{ label: i.name + ' ' + i.description, value: Format.camel2Dash(i.name) }
75+
{ label: `${i.name} ${i.description}`, value: Format.camel2Dash(i.name) }
7476
));
7577
},
7678
handleChange(val) {
7779
console.log(val);
7880
const v = this.$store.state.version;
7981
this.$router.push({
8082
path: `${Format.camel2Dash(val)}`,
81-
query: { v }
83+
query: { v },
8284
});
8385
this.componentName = '';
8486
},
8587
handleVerChange(val) {
8688
window.location = this.options.find(i => i.value === val).path;
87-
}
88-
}
89+
},
90+
},
8991
};
9092
</script>
9193

@@ -128,6 +130,7 @@ export default {
128130
float: left;
129131
margin-top: 16px;
130132
margin-left: 50px;
133+
font-size: 14px;
131134
132135
input {
133136
display: inline-block;
@@ -165,8 +168,8 @@ export default {
165168
166169
.version {
167170
float: right;
168-
margin-top: 15px;
169-
margin-right: 30px;
171+
margin: 15px 30px 0 80px;
172+
width: 130px;
170173
171174
.tag-input-box {
172175
width: 130px;

site/styles/index.scss

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
}
1010

1111
body {
12-
font-family: PingFang SC, Helvetica Neue, Hiragino Sans GB, Helvetica, Microsoft YaHei, Arial;
12+
font-family: PingFang SC, Helvetica Neue,Helvetica,Arial,Microsoft Yahei,Hiragino Sans GB,WenQuanYi Micro Hei,sans-serif;
1313
line-height: 1.42857143;
1414
color: #383838;
1515
-webkit-font-smoothing: subpixel-antialiased;

0 commit comments

Comments
 (0)