仿互站小程序

This commit is contained in:
Drawfans
2020-06-09 16:17:23 +08:00
commit 7bfd53851e
321 changed files with 22890 additions and 0 deletions

42
vant/switch-cell/index.js Normal file
View File

@@ -0,0 +1,42 @@
(0, require("../common/component").VantComponent)({
field: !0,
props: {
value: null,
title: String,
border: Boolean,
checked: Boolean,
loading: Boolean,
disabled: Boolean,
activeColor: String,
inactiveColor: String,
size: {
type: String,
value: "24px"
},
activeValue: {
type: null,
value: !0
},
inactiveValue: {
type: null,
value: !1
}
},
watch: {
checked: function(e) {
this.set({
value: e
});
}
},
created: function() {
this.set({
value: this.data.checked
});
},
methods: {
onChange: function(e) {
this.$emit("change", e.detail);
}
}
});