仿互站小程序

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,23 @@
(0, require("../common/component").VantComponent)({
relation: {
type: "descendant",
name: "goods-action-button",
linked: function(n) {
this.children.push(n);
},
unlinked: function(n) {
this.children = this.children.filter(function(e) {
return e !== n;
});
}
},
beforeCreate: function() {
this.children = [];
},
props: {
safeAreaInsetBottom: {
type: Boolean,
value: !0
}
}
});

View File

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

View File

@@ -0,0 +1,4 @@
<view class="custom-class {{utils.bem( 'goods-action',{safe:safeAreaInsetBottom} )}}">
<slot></slot>
</view>
<wxs module="utils" src="../wxs/utils.wxs" />

View File

@@ -0,0 +1,17 @@
@import "../area/index.wxss";
.van-goods-action {
z-index: 999;
position: fixed;
right: 0;
bottom: 0;
left: 0;
display: flex;
align-items: center;
background-color: #fff;
background-color: var(--goods-action-background-color,#fff);
}
.van-goods-action--safe {
padding-bottom: env(safe-area-inset-bottom);
}