仿互站小程序

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

View File

@@ -0,0 +1,35 @@
(0, require("../common/component").VantComponent)({
field: !0,
relation: {
name: "checkbox",
type: "descendant",
linked: function(e) {
var a = this.data, n = a.value, d = a.disabled;
e.set({
value: -1 !== n.indexOf(e.data.name),
disabled: d || e.data.disabled
});
}
},
props: {
max: Number,
value: Array,
disabled: Boolean
},
watch: {
value: function(e) {
this.getRelationNodes("../checkbox/index").forEach(function(a) {
a.set({
value: -1 !== e.indexOf(a.data.name)
});
});
},
disabled: function(e) {
this.getRelationNodes("../checkbox/index").forEach(function(a) {
a.set({
disabled: e || a.data.disabled
});
});
}
}
});

View File

@@ -0,0 +1,13 @@
{
"component": true,
"usingComponents": {
"van-icon": "../icon/index",
"forview": "/utils/forview/index",
"van-loading": "/vant/loading/index",
"van-dialog": "/vant/dialog/index",
"van-button": "/vant/button/index",
"van-popup": "/vant/popup/index",
"van-tab": "/vant/tab/index",
"van-tabs": "/vant/tabs/index"
}
}

View File

@@ -0,0 +1 @@
<slot></slot>

View File

@@ -0,0 +1 @@
@import "../area/index.wxss";