Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: update #2073

Merged
merged 6 commits into from
Oct 24, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions build/build-docs.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ const aliasMap = {

let tMaps = {
'组件列表': 'Components',
'该组件已经停止维护。': 'This Component is Deprecated.',
'该组件已经停止维护。': 'This Component is Deprecated. ',
'名字': 'name',
'类型': 'type',
'参数': 'params',
Expand Down Expand Up @@ -832,4 +832,4 @@ nav: ${lang}
str += '\n'

fs.writeFileSync(getPath(`../docs/${lang}/changes.md`), str)
}
}
38 changes: 14 additions & 24 deletions src/components/actionsheet/metas.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,19 +10,14 @@ tags:
- 提示
after_extra:
en: |

From `v2.1.0`, `menus` supports type: Array.

`label`: label name,you can use simple text or `html`

`value`: event name,if not specified, no `on-click-menu` will be emitted

`theme`:

- `ios` ios theme
- `android` android theme

`type`:
`type`:

- `primary` primary color
- `warn` warn color
Expand Down Expand Up @@ -56,11 +51,6 @@ after_extra:

`value`: 英文字符,表示触发事件的名字,如果不设置不会触发`on-click-menu`事件。

`theme`: 菜单风格,可选值如下

- `ios` ios风格
- `android` android风格

`type`: 类型,可选值如下

- `primary` 主色
Expand Down Expand Up @@ -90,28 +80,28 @@ props:
value:
type: Boolean
default: false
en: if showing the component, use v-model for binding
en: if showing the component; use v-model for binding
zh-CN: 是否显示, 使用 v-model 绑定变量
show-cancel:
type: Boolean
default: false
en: if showing the cancel menu
zh-CN: 是否显示取消菜单
en: if showing the cancel menu; invalid for android theme
zh-CN: 是否显示取消菜单,对安卓风格无效
cancel-text:
type: String
default: 'cancel(取消)'
en: text of cancel menu
zh-CN: 取消菜单文字
zh-CN: 取消菜单的显示文字
theme:
type: String
default: 'ios'
en: theme of menus
zh-CN: 菜单风格
en: "theme of menus, can be in ['ios', 'android']"
zh-CN: "菜单风格,可选值为['ios','android']"
menus:
type: Object,Array
default: '{}'
en: "menu items, for example: `{menu1: 'some text'}`, menu name with `.noop` will not trigger click events"
zh-CN: "菜单项列表,举例:`{menu1: '删除'}`,如果名字上带有`.noop`表明这是纯文本(HTML)展示,不会触发事件,用于展示描述或者提醒。<br>从`v2.1.0`开始支持数组类型的菜单,见下面说明。"
en: "menu items, for example: `{menu1: 'some text'}`, menu name with `.noop` will not trigger click events. <br>`Menus` supports array since `v2.1.0`. Keys can be customized. More details below."
zh-CN: "菜单项列表,举例:`{menu1: '删除'}`,如果名字上带有`.noop`表明这是纯文本(HTML)展示,不会触发事件,用于展示描述或者提醒。<br>从`v2.1.0`开始支持数组类型的菜单,可自定义键值,见下面说明。"
close-on-clicking-mask:
type: Boolean
default: true
Expand All @@ -122,7 +112,7 @@ props:
type: Boolean
default: true
version: v2.3.8
en: if auto hide when clicking on menus
en: if hide automatically when clicking on menus
zh-CN: 点击菜单时是否自动隐藏
events:
on-click-menu:
Expand All @@ -131,8 +121,8 @@ events:
zh-CN: 点击菜单时触发
on-click-menu-{menuKey}:
params: (menuKey)
en: shortcut event for easier listening, you can listen on `on-click-menu-delete` if you have a menu named `delete`
zh-CN: 点击事件的快捷方式, 如果你有一个菜单名字为`delete`, 那么你可以监听 `on-click-menu-delete`
en: shortcut event for easier listening, `menuKey` is related to `label`. For exapmple, you can listen on `on-click-menu-delete` if you have a menu named `delete`
zh-CN: 点击事件的快捷方式, `menuKey`与`label`的值有关。举例:如果你有一个菜单名字为`delete`, 那么你可以监听 `on-click-menu-delete`
on-click-menu-cancel:
en: triggers when clicking on the cancel menu
zh-CN: 点击取消菜单时触发
Expand Down Expand Up @@ -182,4 +172,4 @@ changes:
- '[feature] add prop close-on-clicking-mask'
zh-CN:
- '[change] 更新到 vue@2.0,使用 `v-model` 而不是`:show.sync`进行显示属性绑定'
- '[feature] 添加属性 `close-on-clicking-mask`, 适用于强制选择的场景'
- '[feature] 添加属性 `close-on-clicking-mask`, 适用于强制选择的场景'
2 changes: 1 addition & 1 deletion src/components/button-tab/metas.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ button-tab-item:
events:
on-item-click:
params: (index)
en: emits when item being clicked
en: emits when item is clicked
zh-CN: 当前按钮点击时触发
changes:
v2.2.0:
Expand Down
12 changes: 6 additions & 6 deletions src/components/calendar/metas.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ extra:
<br>
除了`title`和 `value`, 其他`props`和`inline-calendar`完全一致。
</p>

<p class="tip">当绑定值为数组时,日历将为多选模式</p>

en: |
Expand All @@ -38,13 +38,13 @@ extends:
- cell
intro:
zh-CN: 扩展自inline-calendar, 相关属性可查看inline-calendar文档
en: extends from inline-calendar, Related props can be found in the document of inline-calendar
en: extends from inline-calendar. Related props can be found in the document of inline-calendar
props:
value:
type: String
default: ''
zh-CN: 表单值, v-model 绑定
en: form value, binding by v-model
zh-CN: "表单值, v-model 绑定。当值为空时,为单选;当值为[]时,为多选;设置值为'TODAY'可快捷选取当前日期。`placeholder`只有在值为空或[]时显示。"
en: form value, binding by v-model. Empty means single seleciton; [] means multiple selection. When the value is "TODAY", can quick pick current date. `placeholder` is valid only when the value is empty or [].
title:
type: String
default: ''
Expand All @@ -57,8 +57,8 @@ props:
show-popup-header:
version: v2.6.0
type: Boolean
en: whether show popup header
zh-CN: 是否显示弹窗头部,当为多选时强制显示
en: whether show popup header. Show under multiple selection mode; hide under single selection mode.
zh-CN: 是否显示弹窗头部,当为多选时强制显示,单选时默认不显示
popup-header-title:
version: v2.6.0
type: String
Expand Down
10 changes: 5 additions & 5 deletions src/components/cell-box/metas.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ extra:
</cell-box>
</group>
```

<p class="tip">与`cell`相比,`cell-box`更自由和灵活,只提供`is-link`和`link`属性,内容直接使用默认slot定义。
<br>
`cell-box`同样只能在`Group`中使用</p>
Expand All @@ -19,17 +19,17 @@ props:
is-link:
type: Boolean
default: false
en: if this is a link, if true, there will be an arrow on the right
en: if this is a link; if true, there will be an arrow on the right
zh-CN: 是否为链接,如果是,右侧将会出现指引点击的右箭头
link:
type: String, Object
en: redirect link when being clicked
en: redirect link. Can be http(s) protocol; can also be vue-router format
zh-CN: 点击链接,可以为http(s)协议,也可以是 vue-router 支持的地址形式
border-intent:
version: v2.2.1-rc.1
type: Boolean
default: true
en: if set border intent
en: if set border intent on the left side
zh-CN: 是否显示边框与左边的间隙
align-items:
version: v2.6.5
Expand Down Expand Up @@ -61,4 +61,4 @@ changes:
en:
- '[feature] new component'
zh-CN:
- '[feature] 新组件'
- '[feature] 新组件'
8 changes: 4 additions & 4 deletions src/components/cell-form-preview/metas.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ tags:
- 表单
- 预览
extra: |

<p class="warning">
`CellFormPreview` 需要在 `Group` 组件中使用。
</p>
Expand Down Expand Up @@ -52,12 +52,12 @@ props:
version: v2.2.0
type: Array
en: label and value list
zh-CN: 内容列表
zh-CN: 内容列表,键值包括`label`和`value`,可缺值
border-intent:
version: v2.2.1-rc.1
type: Boolean
default: true
en: if set border intent
en: if set border intent on the left side
zh-CN: 是否显示边框与左边的间隙
changes:
v2.2.1-rc.1:
Expand All @@ -69,4 +69,4 @@ changes:
en:
- '[feature] new component'
zh-CN:
- '[feature] 新组件'
- '[feature] 新组件'
21 changes: 11 additions & 10 deletions src/components/cell/metas.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ extra:
<cell title="title" value="value"></cell>
</group>
```

<p class="tip">cell只能在`Group`中使用</p>
tags:
en:
Expand All @@ -19,7 +19,7 @@ props:
title:
type: String
default: ''
en: label text
en: label text on the left
zh-CN: 左边标题文字
value:
type: String
Expand All @@ -33,12 +33,12 @@ props:
zh-CN: 标题下面文字,一般为说明文字
link:
type: String, Object
en: redirect link when being clicked
en: redirect link. Can be http(s) protocol; can also be vue-router format
zh-CN: 点击链接,可以为http(s)协议,也可以是 vue-router 支持的地址形式
is-link:
type: Boolean
default: false
en: if this is a link, if true, there will be an arrow on the right
en: if this is a link; if true, there will be an arrow on the right
zh-CN: 是否为链接,如果是,右侧将会出现指引点击的右箭头
primary:
type: String
Expand All @@ -49,7 +49,7 @@ props:
version: v2.2.0
type: Boolean
default: false
en: if show loading icon
en: if show loading icon, good for asynchronous loading
zh-CN: 是否显示加载图标,适用于异步加载数据的场景
value-align:
version: v2.2.0
Expand All @@ -60,7 +60,7 @@ props:
version: v2.2.1-rc.1
type: Boolean
default: true
en: if set border intent
en: if set border intent on the left side
zh-CN: 是否显示边框与左边的间隙
arrow-direction:
version: v2.2.1-rc.1
Expand All @@ -70,16 +70,17 @@ props:
disabled:
version: v2.2.2
type: Boolean
en: set disabled style for label and arrow(if is-link is true)
zh-CN: 对 label 和箭头(如果使用 is-link)显示不可操作样式
en: set disabled style for label and arrow (if is-link is true)
zh-CN: 对 label 和箭头(如果使用 is-link )显示不可操作样式
align-items:
version: v2.6.4
type: String
default: center
en: align-items value
zh-CN: align-items 样式值
slots:
default:
en: "right area, you can use default slot instead of prop:value so you can use complexed layout"
en: "right area, you can use default slot instead of prop:value so you can use complicated layout"
zh-CN: 右侧内容,相比于value的优点是可以用复杂的样式或者调用组件
value:
en: "[deprecated] the same as default slot"
Expand Down Expand Up @@ -156,4 +157,4 @@ changes:
- '[feature] 支持字体变量 #990 @wg5945'
v2.1.0-rc.47:
zh-CN:
- '[enhance] 修复内容多时的箭头位置 #715 @greedying '
- '[enhance] 修复内容多时的箭头位置 #715 @greedying '
10 changes: 8 additions & 2 deletions src/components/check-icon/metas.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,11 @@ props:
value:
type: Boolean
version: v2.3.8
en: selected value, use :value.sync
zh-CN: 是否选中的值,使用 :value.sync 双向绑定
default: false
en: if selected, use :value.sync for two-way data binding
zh-CN: 是否选中,使用 :value.sync 双向绑定
type:
type: String
default: unknown
en: "style of check icon, can be ['plain']"
zh-CN: "check icon 样式,可选值为['plain']"
8 changes: 4 additions & 4 deletions src/components/checker/metas.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
icon: '&#xe655;'
extra:
en: |

`Checker` is a more flexible component than `Radio` and `Checklist`.

zh-CN: |
Expand Down Expand Up @@ -36,7 +36,7 @@ checker:
zh-CN: 类型,单选为`radio`, 多选为`checkbox`
value:
type: String,Array
en: selected value ,use `v-model` for binding
en: selected value, use `v-model` for binding
zh-CN: 表单值,使用`v-model`绑定
max:
type: Number
Expand All @@ -46,7 +46,7 @@ checker:
version: v2.6.3
type: Boolean
default: false
en: whether value is required in radio mode
en: whether value is required in radio mode. if true, current selected item will always be selected even after clicking
zh-CN: 在单选模式下是否必选一个值。设为 true 后点击当前选中项不会取消选中。
events:
on-change:
Expand Down Expand Up @@ -98,4 +98,4 @@ changes:
en:
- '[feature] Support Object value #705'
zh-CN:
- '[feature] 支持Object类型的值 #705'
- '[feature] 支持Object类型的值 #705'
5 changes: 4 additions & 1 deletion src/components/checklist/index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,10 @@ export default {
type: Boolean,
default: true
},
labelPosition: String,
labelPosition: {
type: String,
default: 'right'
},
disabled: Boolean
},
data () {
Expand Down
Loading