Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
E
Element
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
CI / CD Analytics
Repository Analytics
Value Stream Analytics
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
林焕东
Element
Commits
d0a29752
Commit
d0a29752
authored
Sep 14, 2016
by
cinwell.li
Committed by
GitHub
Sep 14, 2016
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #68 from Leopoldthecoder/master
misc visual updates
parents
3d229c41
33a551d7
Changes
18
Show whitespace changes
Inline
Side-by-side
Showing
18 changed files
with
149 additions
and
121 deletions
+149
-121
CHANGELOG.md
CHANGELOG.md
+2
-2
examples/app.vue
examples/app.vue
+1
-1
examples/assets/images/stars.png
examples/assets/images/stars.png
+0
-0
examples/components/demo-block.vue
examples/components/demo-block.vue
+14
-9
examples/components/footer-nav.vue
examples/components/footer-nav.vue
+2
-2
examples/components/footer.vue
examples/components/footer.vue
+9
-18
examples/components/header.vue
examples/components/header.vue
+29
-12
examples/components/side-nav.vue
examples/components/side-nav.vue
+13
-23
examples/docs/dialog.md
examples/docs/dialog.md
+5
-2
examples/index.template.html
examples/index.template.html
+1
-1
examples/nav.config.json
examples/nav.config.json
+14
-10
examples/pages/changelog.vue
examples/pages/changelog.vue
+16
-26
examples/pages/component.vue
examples/pages/component.vue
+0
-2
examples/pages/index.vue
examples/pages/index.vue
+21
-4
examples/pages/nav.vue
examples/pages/nav.vue
+4
-2
examples/route.config.js
examples/route.config.js
+13
-6
packages/theme-default/src/dialog.css
packages/theme-default/src/dialog.css
+1
-1
packages/theme-default/src/message-box.css
packages/theme-default/src/message-box.css
+4
-0
No files found.
CHANGELOG.md
View file @
d0a29752
...
...
@@ -5,8 +5,8 @@
*2016-XX-XX*
-
修复 Select 多选时选项变为空数组后 placeholder 不出现的问题
-
修复 TimePicker 时间选择可滚动
-
修复 Tooltip
会有出现错位的情况
-
修复 Time
Picker 时间选择可滚动
-
修复 Tooltip
有时会错位的问题
#### 非兼容性更新
-
Select 组件样式的
`display`
属性默认值修改为
`block`
...
...
examples/app.vue
View file @
d0a29752
...
...
@@ -40,7 +40,7 @@
.container
,
.page-container
{
width
:
96
0px
;
width
:
114
0px
;
margin
:
0
auto
;
}
...
...
examples/assets/images/stars.png
0 → 100644
View file @
d0a29752
4.24 KB
examples/components/demo-block.vue
View file @
d0a29752
...
...
@@ -19,7 +19,11 @@
transition
:
.2s
;
&.hover
{
box-shadow
:
0
6px
18px
0
rgba
(
232
,
237
,
250
,
.5
);
box-shadow
:
0
0
8px
0
rgba
(
232
,
237
,
250
,
.6
),
0
2px
4px
0
rgba
(
232
,
237
,
250
,
.5
);
}
code
{
font-family
:
Menlo
,
Monaco
,
Consolas
,
Courier
,
monospace
;
}
.source
{
...
...
@@ -27,7 +31,7 @@
}
.meta
{
background-color
:
#f
bfcfd
;
background-color
:
#f
9fafc
;
border-top
:
solid
1px
#eaeefb
;
clear
:
both
;
overflow
:
hidden
;
...
...
@@ -42,7 +46,7 @@
border-left
:
solid
1px
#eaeefb
;
float
:
right
;
font-size
:
14px
;
line-height
:
1.
5
;
line-height
:
1.
8
;
color
:
#5e6d82
;
word-break
:
break-word
;
...
...
@@ -51,10 +55,10 @@
}
code
{
background-color
:
#f4faff
;
b
order
:
solid
1px
#eaee
fb
;
color
:
#5e6d82
;
b
ackground-color
:
#e6ef
fb
;
margin
:
0
4px
;
padding
:
0
4
px
;
padding
:
4px
8
px
;
font-size
:
12px
;
}
}
...
...
@@ -68,10 +72,11 @@
}
code
.hljs
{
font-size
:
12px
;
padding
:
18px
24px
;
margin
:
0
;
line-height
:
1.
4
;
background-color
:
#f
bfcfd
;
line-height
:
1.
8
;
background-color
:
#f
9fafc
;
border
:
none
;
max-height
:
none
;
border-radius
:
0
;
...
...
@@ -107,7 +112,7 @@
&
:hover
{
color
:
#20a0ff
;
background-color
:
rgba
(
32
,
159
,
255
,
.05
)
;
background-color
:
#f9fafc
;
}
}
}
...
...
examples/components/footer-nav.vue
View file @
d0a29752
...
...
@@ -97,10 +97,10 @@
},
created
()
{
navConfig
[
0
].
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
.
nav
=
this
.
nav
.
concat
(
navConfig
[
1
].
children
);
this
.
updateNav
();
}
};
...
...
examples/components/footer.vue
View file @
d0a29752
...
...
@@ -29,7 +29,7 @@
.footer
{
height
:
120px
;
background-color
:
#324057
;
color
:
#
fff
;
color
:
#
a4aebd
;
width
:
100%
;
z-index
:
1000
;
margin-top
:
-120px
;
...
...
@@ -58,10 +58,10 @@
margin
:
12px
18px
0
0
;
line-height
:
1
;
font-size
:
12px
;
color
:
#
8492a6
;
color
:
#
768193
;
a
{
color
:
#
8492a6
;
color
:
#
768193
;
text-decoration
:
none
;
}
}
...
...
@@ -99,13 +99,12 @@
display
:
inline-block
;
line-height
:
32px
;
text-align
:
center
;
color
:
#
324057
;
background-color
:
#fff
;
color
:
#
8D99AB
;
background-color
:
transparent
;
size
:
32px
;
border-radius
:
50%
;
font-size
:
22px
;
font-size
:
32px
;
vertical-align
:
middle
;
&:hover
{
color
:
#fff
;
transform
:
scale
(
1.2
);
}
}
...
...
@@ -113,22 +112,14 @@
.doc-icon-weixin
{
margin-right
:
36px
;
&:hover
{
background-color
:
#26CB72
;
color
:
#fff
;
}
}
.doc-icon-github
{
margin-right
:
0
;
transform
:
translateY
(
8px
);
position
:
relative
;
&::before
{
position
:
absolute
;
left
:
4px
;
bottom
:
-6px
;
}
&:hover
{
transform
:
translateY
(
8px
)
scale
(
1.2
);
background-color
:
#437AC0
;
color
:
#fff
;
}
}
}
...
...
examples/components/header.vue
View file @
d0a29752
...
...
@@ -4,12 +4,11 @@
}
.header
{
height
:
80px
;
background-color
:
#20a0ff
;
background-color
:
rgba
(
32
,
160
,
255
,
1
)
;
color
:
#fff
;
top
:
0
;
left
:
0
;
width
:
100%
;
z-index
:
1000
;
line-height
:
@
height
;
z-index
:
100
;
position
:
relative
;
...
...
@@ -35,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
;
...
...
@@ -58,6 +57,7 @@
list-style
:
none
;
position
:
relative
;
cursor
:
pointer
;
margin-left
:
20px
;
a
{
text-decoration
:
none
;
...
...
@@ -77,42 +77,44 @@
}
}
}
/*.el-menu-item__bar {
background-color: #99d2fc;
}*/
}
.header-fixed
{
position
:
fixed
;
top
:
-80px
;
box-shadow
:
0
px
2px
8px
0px
rgba
(
50
,
63
,
87
,
0.4
5
);
box-shadow
:
0
2px
6px
0
rgba
(
50
,
63
,
87
,
0.2
5
);
}
.header-hangUp
{
top
:
0
;
}
.header-home
{
position
:
fixed
;
top
:
0
;
background-color
:
rgba
(
32
,
160
,
255
,
0
);
}
</
style
>
<
template
>
<div
class=
"headerWrapper"
>
<header
class=
"header"
ref=
"header"
:style=
"headerStyle"
:class=
"
{
'header-home': isHome,
'header-fixed': isFixed,
'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"
>
...
...
@@ -133,13 +135,19 @@
return
{
active
:
''
,
isFixed
:
false
,
isHome
:
false
,
headerStyle
:
{},
hangUp
:
false
};
},
watch
:
{
'
$route.path
'
(
val
)
{
this
.
isHome
=
val
===
'
/
'
;
this
.
headerStyle
.
backgroundColor
=
`rgba(32, 160, 255,
${
this
.
isHome
?
'
0
'
:
'
1
'
}
)`
;
}
},
mounted
()
{
this
.
isHome
=
this
.
$route
.
path
===
'
/
'
;
function
scroll
(
fn
)
{
var
beforeScrollTop
=
document
.
body
.
scrollTop
;
...
...
@@ -154,6 +162,15 @@
},
false
);
}
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
}
)`
;
return
;
}
this
.
headerStyle
.
backgroundColor
=
'
rgba(32, 160, 255, 1)
'
;
const
bounding
=
this
.
$el
.
getBoundingClientRect
();
if
(
bounding
.
bottom
<
0
)
{
this
.
isFixed
=
true
;
...
...
examples/components/side-nav.vue
View file @
d0a29752
...
...
@@ -2,7 +2,6 @@
.side-nav
{
width
:
100%
;
box-sizing
:
border-box
;
border-right
:
1px
solid
#eaeefa
;
li
{
list-style
:
none
;
...
...
@@ -15,12 +14,12 @@
.nav-item
{
a
{
font-size
:
18
px
;
color
:
#5e6d82
;
line-height
:
4
2
px
;
height
:
4
2
px
;
font-size
:
16
px
;
color
:
#5e6d82
;
line-height
:
4
0
px
;
height
:
4
0
px
;
margin
:
0
;
padding
:
0
0
0
12px
;
padding
:
0
;
text-decoration
:
none
;
display
:
block
;
position
:
relative
;
...
...
@@ -28,26 +27,15 @@
&.active
{
color
:
#20a0ff
;
&:after
{
content
:
''
;
width
:
2px
;
background-color
:
#20a0ff
;
height
:
32px
;
border-radius
:
2px
;
left
:
0
;
position
:
absolute
;
top
:
5px
;
}
}
}
.nav-item
{
a
{
display
:
block
;
height
:
4
2
px
;
line-height
:
4
2
px
;
font-size
:
1
4
px
;
padding-left
:
2
2
px
;
height
:
4
0
px
;
line-height
:
4
0
px
;
font-size
:
1
3
px
;
padding-left
:
2
4
px
;
&:hover
{
...
...
@@ -57,9 +45,11 @@
}
}
.nav-group__title
{
font-size
:
12px
;
color
:
#99a9bf
;
padding-left
:
15px
;
line-height
:
34px
;
padding-left
:
8px
;
line-height
:
26px
;
margin-top
:
10px
;
}
}
</
style
>
...
...
examples/docs/dialog.md
View file @
d0a29752
...
...
@@ -58,6 +58,9 @@
.el-dialog__wrapper {
margin: 0;
}
.el-select {
width: 300px;
}
.el-input {
width: 300px;
}
...
...
@@ -75,8 +78,8 @@ Dialog 弹出一个对话框,适合需要定制性更大的场景。
```
html
<el-button
type=
"text"
@
click.native=
"dialogVisible = true"
>
点击打开 Dialog
</el-button>
<el-dialog
title=
"提示"
v-model=
"dialogVisible"
>
<span>
这是一段信息
,这是一段信息,这是一段信息,这是一段信息,这是一段信息,这是一段信息,这是一段信息,这是一段信息
</span>
<el-dialog
title=
"提示"
v-model=
"dialogVisible"
size=
"tiny"
>
<span>
这是一段信息
</span>
<span
slot=
"footer"
class=
"dialog-footer"
>
<el-button
@
click.native=
"dialogVisible = false"
>
取 消
</el-button>
<el-button
type=
"primary"
@
click.native=
"dialogVisible = false"
>
确 定
</el-button>
...
...
examples/index.template.html
View file @
d0a29752
...
...
@@ -2,7 +2,7 @@
<html
lang=
"en"
>
<head>
<meta
charset=
"utf-8"
>
<link
rel=
"stylesheet"
href=
"//at.alicdn.com/t/font_147
1936010_8874195
.css"
>
<link
rel=
"stylesheet"
href=
"//at.alicdn.com/t/font_147
3762766_7074292
.css"
>
<title>
Element
</title>
</head>
<body>
...
...
examples/nav.config.json
View file @
d0a29752
[
{
"name"
:
"安装指南"
,
"children"
:
[{
"path"
:
"/quickstart"
,
"name"
:
"快速上手"
},
{
"path"
:
"/development"
,
"name"
:
"开发指南"
}]
},
{
"name"
:
"更新日志"
,
"path"
:
"/changelog"
},
{
"name"
:
"基础组件"
,
"groups"
:
[{
...
...
@@ -242,15 +256,5 @@
}
]
}]
},
{
"name"
:
"安装指南"
,
"children"
:
[{
"path"
:
"/quickstart"
,
"name"
:
"快速上手"
},
{
"path"
:
"/development"
,
"name"
:
"开发指南"
}]
}
]
examples/pages/changelog.vue
View file @
d0a29752
...
...
@@ -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
>
...
...
examples/pages/component.vue
View file @
d0a29752
...
...
@@ -7,8 +7,6 @@
}
.page-component
{
.content
{
padding-left
:
25px
;
border-left
:
1px
solid
#eaeefa
;
margin-left
:
-1px
;
>
{
...
...
examples/pages/index.vue
View file @
d0a29752
...
...
@@ -6,8 +6,8 @@
}
}
.banner
{
position
:
relative
;
height
:
420px
;
background-color
:
#20a0ff
;
color
:
#fff
;
margin-bottom
:
130px
;
...
...
@@ -18,8 +18,23 @@
img
{
position
:
absolute
;
top
:
15px
;
right
:
-105px
;
right
:
-10px
;
}
}
.banner-sky
{
position
:
absolute
;
top
:
-150px
;
bottom
:
-15px
;
width
:
100%
;
margin-top
:
-140px
;
transform
:
skewY
(
-5deg
);
transform-origin
:
center
;
background-image
:
linear-gradient
(
180deg
,
#0d1a44
13%
,
#3c4f91
56%
,
#5fc1e4
100%
);
}
img
.banner-stars
{
top
:
-10px
;
left
:
50%
;
transform
:
translateX
(
-50%
);
}
.banner-desc
{
padding-top
:
80px
;
...
...
@@ -34,7 +49,7 @@
}
.cards
{
margin
:
0
auto
110px
;
width
:
96
0px
;
width
:
114
0px
;
.container
{
@utils-clearfix;
...
...
@@ -45,7 +60,7 @@
li
{
width
:
33.33333%
;
padding
:
0
1
1
px
;
padding
:
0
1
9
px
;
box-sizing
:
border-box
;
float
:
left
;
list-style
:
none
;
...
...
@@ -116,6 +131,8 @@
<
template
>
<div>
<div
class=
"banner"
>
<div
class=
"banner-sky"
></div>
<img
class=
"banner-stars"
src=
"~examples/assets/images/stars.png"
alt=
"Element"
>
<div
class=
"container"
>
<div
class=
"banner-desc"
>
<h2>
Element
</h2>
...
...
examples/pages/nav.vue
View file @
d0a29752
...
...
@@ -16,6 +16,8 @@
margin
:
0
;
}
img
{
padding
:
15px
;
background-color
:
#F9FAFC
;
width
:
100%
;
margin-bottom
:
15px
;
cursor
:
pointer
;
...
...
@@ -68,11 +70,11 @@
<div>
<h2>
导航
</h2>
<div
class=
"block"
>
<p>
导航可以解决用户在访问页面时:在哪里,去哪里,怎样去的问题。一般导航会有「侧栏导航」和「顶部导航」2种类型。
</p>
<p>
导航可以解决用户在访问页面时:在哪里,去哪里,怎样去的问题。一般导航会有「侧栏导航」和「顶部导航」2
种类型。
</p>
</div>
<div
class=
"block"
>
<h3>
选择合适的导航
</h3>
<p>
选择合适的导航可以让用户在产品的使用过程中非常流畅,相反若是不合适就会引起用户操作不适
(方向不明确)
,以下是「侧栏导航」和 「顶部导航」的区别。
</p>
<p>
选择合适的导航可以让用户在产品的使用过程中非常流畅,相反若是不合适就会引起用户操作不适
(方向不明确)
,以下是「侧栏导航」和 「顶部导航」的区别。
</p>
</div>
<div
class=
"block"
>
<h3>
侧栏导航
</h3>
...
...
examples/route.config.js
View file @
d0a29752
...
...
@@ -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
'
,
...
...
packages/theme-default/src/dialog.css
View file @
d0a29752
...
...
@@ -47,7 +47,7 @@
color
:
#C0CCDA
;
&:hover
{
color
:
var
(
--
dialog-background-color
);
color
:
var
(
--
color-primary
);
}
}
...
...
packages/theme-default/src/message-box.css
View file @
d0a29752
...
...
@@ -36,6 +36,10 @@
cursor
:
pointer
;
line-height
:
20px
;
text-align
:
center
;
&:hover
{
color
:
var
(
--color-primary
);
}
}
@e
input
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment