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
71df9f86
Commit
71df9f86
authored
Sep 12, 2016
by
SkyAo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update document of layout/message
parent
c9773b22
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
4 deletions
+7
-4
examples/docs/layout.md
examples/docs/layout.md
+1
-1
examples/docs/message.md
examples/docs/message.md
+6
-3
No files found.
examples/docs/layout.md
View file @
71df9f86
...
...
@@ -107,7 +107,7 @@
### 分栏偏移
分栏支持按一定的栏数进行偏移
。
支持偏移指定的栏数
。
::: demo 通过制定 col 组件的
`offset`
属性可以指定分栏偏移的栏数。
```
html
...
...
examples/docs/message.md
View file @
71df9f86
...
...
@@ -70,10 +70,12 @@
## Message 消息提示
反馈提示,比 Notification 更为小巧
。
常用于主动操作后的反馈提示。与 Notification 的区别是后者更多用于系统级通知的被动提醒
。
### 基础用法
从顶部出现,3 秒后自动消失。
:::demo Message 在配置上与 Notification 非常类似,所以部分 options 在此不做详尽解释,文末有 options 列表,可以结合 Notification 的文档理解它们。Element 注册了一个
`$message`
方法用于调用,Message 可以接收一个字符串作为参数,它会被显示为正文内容。
```
html
...
...
@@ -95,13 +97,14 @@
### 不同状态
Message 提供了四种类型:
`success`
,
`info`
,
`warning`
,
`error`
,由不同图标表示
。
用来显示「成功、警告、消息、错误」类的操作反馈
。
:::demo 当需要自定义更多属性时,Message 也可以接收一个对象为参数。比如,设置
`type`
字段可以定义不同的状态,默认为
`info`
。此时正文内容以
`message`
的值传入。
```
html
<template>
<el-button
:plain=
"true"
@
click.native=
"open2"
>
成功
</el-button>
<el-button
:plain=
"true"
@
click.native=
"open3"
>
警告
</el-button>
<el-button
:plain=
"true"
@
click.native=
"open"
>
消息
</el-button>
<el-button
:plain=
"true"
@
click.native=
"open4"
>
错误
</el-button>
</template>
...
...
@@ -136,7 +139,7 @@ Message 提供了四种类型:`success`,`info`,`warning`,`error`,由
### 可关闭
可以
设置为手动关闭的 Message
。
可以
添加关闭按钮
。
:::demo 默认的 Message 是不可以被人工关闭的,如果需要可手动关闭的 Message,可以使用
`showClose`
字段。此外,和 Notification 一样,Message 拥有可控的
`duration`
,设置
`0`
为不会被自动关闭,默认为 3000 毫秒。
```
html
...
...
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