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
c8beaa7b
Commit
c8beaa7b
authored
Jan 19, 2017
by
qingwei.li
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Steps: space prop support percentage
parent
20fabc7b
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
7 additions
and
5 deletions
+7
-5
examples/docs/en-US/steps.md
examples/docs/en-US/steps.md
+1
-1
examples/docs/zh-CN/steps.md
examples/docs/zh-CN/steps.md
+1
-1
packages/steps/src/step.vue
packages/steps/src/step.vue
+4
-2
packages/steps/src/steps.vue
packages/steps/src/steps.vue
+1
-1
No files found.
examples/docs/en-US/steps.md
View file @
c8beaa7b
...
@@ -114,7 +114,7 @@ Vertical step bars.
...
@@ -114,7 +114,7 @@ Vertical step bars.
| Attribute | Description | Type | Accepted Values | Default |
| Attribute | Description | Type | Accepted Values | Default |
|---------- |-------- |---------- |------------- |-------- |
|---------- |-------- |---------- |------------- |-------- |
| space | the spacing of each step, will be responsive if omitted
| Number
| — | — |
| space | the spacing of each step, will be responsive if omitted
. Support percentage. | Number,String
| — | — |
| direction | display direction | string | vertical/horizontal | horizontal |
| direction | display direction | string | vertical/horizontal | horizontal |
| active | current activation step | number | — | 0 |
| active | current activation step | number | — | 0 |
| process-status | status of current step | string | wait/process/finish/error/success | process |
| process-status | status of current step | string | wait/process/finish/error/success | process |
...
...
examples/docs/zh-CN/steps.md
View file @
c8beaa7b
...
@@ -108,7 +108,7 @@
...
@@ -108,7 +108,7 @@
| 参数 | 说明 | 类型 | 可选值 | 默认值 |
| 参数 | 说明 | 类型 | 可选值 | 默认值 |
|---------- |-------- |---------- |------------- |-------- |
|---------- |-------- |---------- |------------- |-------- |
| space | 每个 step 的间距,不填写将自适应间距
| Number
| — | — |
| space | 每个 step 的间距,不填写将自适应间距
。支持百分比。 | Number,String
| — | — |
| direction | 显示方向 | string | vertical/horizontal | horizontal |
| direction | 显示方向 | string | vertical/horizontal | horizontal |
| active | 设置当前激活步骤 | number | — | 0 |
| active | 设置当前激活步骤 | number | — | 0 |
| process-status | 设置当前步骤的状态 | string | wait/process/finish/error/success | process |
| process-status | 设置当前步骤的状态 | string | wait/process/finish/error/success | process |
...
...
packages/steps/src/step.vue
View file @
c8beaa7b
...
@@ -118,9 +118,11 @@ export default {
...
@@ -118,9 +118,11 @@ export default {
const
isCenter
=
parent
.
center
;
const
isCenter
=
parent
.
center
;
const
len
=
parent
.
steps
.
length
;
const
len
=
parent
.
steps
.
length
;
const
isLast
=
this
.
isLast
=
parent
.
steps
[
parent
.
steps
.
length
-
1
]
===
this
;
const
isLast
=
this
.
isLast
=
parent
.
steps
[
parent
.
steps
.
length
-
1
]
===
this
;
const
space
=
parent
.
space
const
space
=
typeof
parent
.
space
===
'
number
'
?
parent
.
space
+
'
px
'
?
parent
.
space
+
'
px
'
:
100
/
(
isCenter
?
len
-
1
:
len
)
+
'
%
'
;
:
parent
.
space
?
parent
.
space
:
100
/
(
isCenter
?
len
-
1
:
len
)
+
'
%
'
;
if
(
parent
.
direction
===
'
horizontal
'
)
{
if
(
parent
.
direction
===
'
horizontal
'
)
{
this
.
style
=
{
width
:
space
};
this
.
style
=
{
width
:
space
};
...
...
packages/steps/src/steps.vue
View file @
c8beaa7b
...
@@ -11,7 +11,7 @@ export default {
...
@@ -11,7 +11,7 @@ export default {
name
:
'
ElSteps
'
,
name
:
'
ElSteps
'
,
props
:
{
props
:
{
space
:
Number
,
space
:
[
Number
,
String
]
,
active
:
Number
,
active
:
Number
,
direction
:
{
direction
:
{
type
:
String
,
type
:
String
,
...
...
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