This commit is contained in:
zhuxiang 2017-03-01 15:51:31 +08:00
parent dc2d685a34
commit a9b4b6a27b
5 changed files with 22 additions and 20 deletions

View File

@ -11,7 +11,7 @@
],
"scripts": {
"bootstrap": "npm i --registry=http://registry.npm.qima-inc.com",
"dev": "npm run bootstrap && npm run build:file && webpack-dev-server --port 8282 --inline --hot --config build/webpack.config.js",
"dev": "npm run build:file && webpack-dev-server --port 8282 --inline --hot --config build/webpack.config.js",
"build:file": "node build/bin/build-entry.js",
"build:utils": "cross-env BABEL_ENV=utils babel src --out-dir lib --ignore src/index.js",
"build:zanui-css": "gulp build --gulpfile packages/zanui-css/gulpfile.js && cp-cli packages/zanui-css/lib lib/zanui-css",

View File

@ -5,19 +5,21 @@
</template>
<script>
export default {
name: 'zan-badge-group',
props: {
// tab key
activeKey: {
type: [Number, String],
default: 0
export default {
name: 'zan-badge-group',
props: {
// tab key
activeKey: {
type: [Number, String],
default: 0
}
},
data() {
return {
computedActiveKey: this.activeKey
};
}
},
data () {
return {
computedActiveKey: this.activeKey
}
}
};
};
</script>

View File

@ -30,10 +30,10 @@ export default {
}
},
computed: {
classNames () {
classNames() {
return {
'is-select': this.mark == this.$parent.computedActiveKey ? true : false
}
'is-select': this.mark === this.$parent.computedActiveKey
};
}
}
};

View File

@ -49,7 +49,7 @@ export default {
set(val) {
if (this.isGroup && this.parentGroup) {
this.parentGroup.$emit('input', val);
this.parentGroup.$emit('input', val);
} else {
this.$emit('input', val);
}

View File

@ -48,7 +48,7 @@
},
handleSearch() {
// input
this.$emit('search', this.value)
this.$emit('search', this.value);
}
}
};