Merge branch 'master' of gitlab.qima-inc.com:fe/zanui-vue

This commit is contained in:
niunai
2017-03-02 15:53:34 +08:00
135 changed files with 54327 additions and 11654 deletions

View File

@@ -1,5 +1,5 @@
{
"name": "@youzan/z-button",
"name": "@youzan/zan-button",
"version": "0.0.1",
"description": "button component",
"main": "./index.js",

View File

@@ -8,14 +8,14 @@
* @param {slot} - 显示文本
*
* @example
* <z-button size="large" type="primary">按钮</z-button>
* <zan-button size="large" type="primary">按钮</zan-button>
*/
const allowedSize = ['mini', 'small', 'normal', 'large'];
const allowedType = ['default', 'danger', 'primary'];
export default {
name: 'z-button',
name: 'zan-button',
props: {
disabled: Boolean,
@@ -57,9 +57,9 @@ export default {
type={nativeType}
disabled={disabled}
class={[
'z-button',
'z-button--' + type,
'z-button--' + size,
'zan-button',
'zan-button--' + type,
'zan-button--' + size,
{
'z-button--disabled': disabled,
'z-button--loading': loading,
@@ -69,9 +69,9 @@ export default {
onClick={this.handleClick}
>
{
loading ? <i class="z-icon-loading"></i> : null
loading ? <i class="zan-icon-loading"></i> : null
}
<span class="z-button-text">{this.$slots.default}</span>
<span class="zan-button-text">{this.$slots.default}</span>
</Tag>
);
}