mirror of https://github.com/ElemeFE/element
update routes
parent
c02809c4af
commit
33a551d708
|
@ -5,8 +5,8 @@
|
|||
*2016-XX-XX*
|
||||
|
||||
- 修复 Select 多选时选项变为空数组后 placeholder 不出现的问题
|
||||
- 修复 TimePicker 时间选择可滚动
|
||||
- 修复 Tooltip 会有出现错位的情况
|
||||
- 修复 Time Picker 时间选择可滚动
|
||||
- 修复 Tooltip 有时会错位的问题
|
||||
|
||||
#### 非兼容性更新
|
||||
- Select 组件样式的 `display` 属性默认值修改为 `block`
|
||||
|
|
|
@ -97,8 +97,8 @@
|
|||
},
|
||||
|
||||
created() {
|
||||
this.nav = navConfig[0].children;
|
||||
navConfig[1].groups.map(group => group.list).forEach(list => {
|
||||
this.nav = navConfig[0].children.concat(navConfig[1]);
|
||||
navConfig[2].groups.map(group => group.list).forEach(list => {
|
||||
this.nav = this.nav.concat(list);
|
||||
});
|
||||
this.updateNav();
|
||||
|
|
|
@ -34,7 +34,7 @@
|
|||
display: inline-block;
|
||||
width: 34px;
|
||||
height: 18px;
|
||||
border: 1px solid #fff;
|
||||
border: 1px solid rgba(255, 255, 255, .5);
|
||||
text-align: center;
|
||||
line-height: 18px;
|
||||
vertical-align: middle;
|
||||
|
@ -103,20 +103,18 @@
|
|||
'header-hangUp': hangUp
|
||||
}">
|
||||
<div class="container">
|
||||
<h1><router-link to="/">Element</router-link></h1>
|
||||
<h1><router-link to="/">Element<span>Beta</span></router-link></h1>
|
||||
<ul class="nav">
|
||||
<li class="nav-item">
|
||||
<router-link
|
||||
active-class="active"
|
||||
to="/guide/design"
|
||||
exact>指南
|
||||
to="/guide">指南
|
||||
</router-link>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
<router-link
|
||||
active-class="active"
|
||||
to="/component/layout"
|
||||
exact>组件
|
||||
to="/component">组件
|
||||
</router-link>
|
||||
</li>
|
||||
<li class="nav-item">
|
||||
|
@ -165,6 +163,8 @@
|
|||
}
|
||||
scroll((direction) => {
|
||||
if (this.isHome) {
|
||||
this.hangUp = false;
|
||||
this.headerStyle.transition = '';
|
||||
const threshold = 200;
|
||||
let alpha = Math.min(document.body.scrollTop, threshold) / threshold;
|
||||
this.$refs.header.style.backgroundColor = `rgba(32, 160, 255, ${ alpha })`;
|
||||
|
|
|
@ -58,6 +58,9 @@
|
|||
.el-dialog__wrapper {
|
||||
margin: 0;
|
||||
}
|
||||
.el-select {
|
||||
width: 300px;
|
||||
}
|
||||
.el-input {
|
||||
width: 300px;
|
||||
}
|
||||
|
|
|
@ -9,6 +9,10 @@
|
|||
"name": "开发指南"
|
||||
}]
|
||||
},
|
||||
{
|
||||
"name": "更新日志",
|
||||
"path": "/changelog"
|
||||
},
|
||||
{
|
||||
"name": "基础组件",
|
||||
"groups": [{
|
||||
|
|
|
@ -4,6 +4,15 @@
|
|||
|
||||
.fr {
|
||||
float: right;
|
||||
padding: 0;
|
||||
a {
|
||||
display: block;
|
||||
padding: 10px 15px;
|
||||
color: #475669;
|
||||
}
|
||||
&:hover a {
|
||||
color: #20a0ff;
|
||||
}
|
||||
}
|
||||
h2 {
|
||||
margin-bottom: 40px;
|
||||
|
@ -76,6 +85,7 @@
|
|||
circle: 13px transparent;
|
||||
border: 2px solid #2ca2fc;
|
||||
box-sizing: border-box;
|
||||
background-color: #fff;
|
||||
}
|
||||
}
|
||||
h4 {
|
||||
|
@ -98,35 +108,15 @@
|
|||
</style>
|
||||
<template>
|
||||
<div class="page-container page-changelog">
|
||||
<h2><el-button class="fr">Github Releases</el-button>更新日志</h2>
|
||||
<h2>
|
||||
<el-button class="fr">
|
||||
<a href="https://github.com/ElemeFE/element/releases" target="_blank">Github Releases</a>
|
||||
</el-button>
|
||||
更新日志
|
||||
</h2>
|
||||
<ul class="timeline" ref="timeline">
|
||||
</ul>
|
||||
<change-log ref="changeLog"></change-log>
|
||||
<!-- <ul class="timeline">
|
||||
<li>
|
||||
<h3>2.0.0</h3>
|
||||
<em>2016.06.29</em>
|
||||
<p>很高兴的通知各位,经过四个月时间的紧密开发,Element v1.0.0 终于发布了。从去年 5 月 7 日提交第一行代码以来, 经过整整一年的开发迭代,Element 受到社区的大量关注,使用的公司和产品持续增加,已经日趋成熟。这个版本我们重构了底层代码和站点,持续完善现有组件功能和优化细节,其中很多都来自社区的贡献,无法一一感谢,欢迎各位持续关注和鞭策。在升级过程中遇到任何问题,请及时反馈给我们。</p>
|
||||
<h4>新增</h4>
|
||||
<ul>
|
||||
<li>支持按需加载。可参考 element-init 的模版代码, 需要配合 babel-plugin-antd 插件和 style 配置进行使用。#900</li>
|
||||
<li>结全新单页站点,使用 React 和 antd 进行了彻底重构,加载更快,访问更流畅。</li>
|
||||
</ul>
|
||||
<h4>优化</h4>
|
||||
<ul>
|
||||
<li>支持按需加载。可参考 element-init 的模版代码, 需要配合 babel-plugin-antd 插件和 style 配置进行使用。#900</li>
|
||||
<li>结全新单页站点,使用 React 和 antd 进行了彻底重构,加载更快,访问更流畅。</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li>
|
||||
<h3>1.6.1</h3>
|
||||
<em>2016.06.29</em>
|
||||
<ul>
|
||||
<li>支持按需加载。可参考 element-init 的模版代码, 需要配合 babel-plugin-antd 插件和 style 配置进行使用。#900</li>
|
||||
<li>结全新单页站点,使用 React 和 antd 进行了彻底重构,加载更快,访问更流畅。</li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul> -->
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
|
|
|
@ -16,6 +16,8 @@
|
|||
margin: 0;
|
||||
}
|
||||
img {
|
||||
padding: 15px;
|
||||
background-color: #F9FAFC;
|
||||
width: 100%;
|
||||
margin-bottom: 15px;
|
||||
cursor: pointer;
|
||||
|
|
|
@ -3,20 +3,25 @@ import navConfig from './nav.config.json';
|
|||
const registerRoute = (config) => {
|
||||
let route = [{
|
||||
path: '/component',
|
||||
redirect: '/component/quickstart',
|
||||
component: require('./pages/component.vue'),
|
||||
children: []
|
||||
}];
|
||||
function addRoute(page) {
|
||||
const component = require(`./docs${page.path}.md`);
|
||||
|
||||
route[0].children.push({
|
||||
const component = page.path === '/changelog' ? require('./pages/changelog.vue') : require(`./docs${page.path}.md`);
|
||||
let child = {
|
||||
path: page.path.slice(1),
|
||||
meta: {
|
||||
title: page.title || page.name,
|
||||
description: page.description
|
||||
},
|
||||
component: component.default || component
|
||||
});
|
||||
};
|
||||
if (page.path === '/changelog') {
|
||||
child.redirect = '/changelog';
|
||||
}
|
||||
|
||||
route[0].children.push(child);
|
||||
}
|
||||
config
|
||||
.map(nav => {
|
||||
|
@ -26,11 +31,12 @@ const registerRoute = (config) => {
|
|||
addRoute(page);
|
||||
});
|
||||
});
|
||||
}
|
||||
if (nav.children) {
|
||||
} else if (nav.children) {
|
||||
nav.children.map(page => {
|
||||
addRoute(page);
|
||||
});
|
||||
} else {
|
||||
addRoute(nav);
|
||||
}
|
||||
});
|
||||
|
||||
|
@ -42,6 +48,7 @@ const route = registerRoute(navConfig);
|
|||
let guideRoute = {
|
||||
path: '/guide',
|
||||
name: '指南',
|
||||
redirect: '/guide/design',
|
||||
component: require('./pages/guide.vue'),
|
||||
children: [{
|
||||
path: 'design',
|
||||
|
|
Loading…
Reference in New Issue