Initial commit

This commit is contained in:
sjk
2025-11-17 13:32:54 +08:00
commit e788eab6eb
1659 changed files with 171560 additions and 0 deletions

View File

@@ -0,0 +1,22 @@
Component({
properties: {
imgUrl: {
type: String,
value: 'https://tdesign.gtimg.com/miniprogram/template/retail/template/empty-cart.png',
},
tip: {
type: String,
value: '购物车是空的',
},
btnText: {
type: String,
value: '去首页',
},
},
data: {},
methods: {
handleClick() {
this.triggerEvent('handleClick');
},
},
});

View File

@@ -0,0 +1,6 @@
{
"component": true,
"usingComponents": {
"t-image": "/components/webp-image/index"
}
}

View File

@@ -0,0 +1,6 @@
<view class="cart-empty">
<t-image t-class="cart-img" src="{{imgUrl}}" />
<view class="tip">{{tip}}</view>
<view class="btn" bind:tap="handleClick">{{btnText}}</view>
</view>

View File

@@ -0,0 +1,33 @@
.cart-empty {
padding: 64rpx 0rpx;
display: flex;
flex-direction: column;
align-items: center;
box-sizing: border-box;
height: calc(100vh - 100rpx);
background-color: #f5f5f5;
}
.cart-empty .cart-img {
width: 160rpx;
height: 160rpx;
margin-bottom: 24rpx;
}
.cart-empty .tip {
font-size: 28rpx;
line-height: 40rpx;
color: #999;
margin-bottom: 24rpx;
}
.cart-empty .btn {
width: 240rpx;
height: 72rpx;
border-radius: 36rpx;
text-align: center;
line-height: 72rpx;
border: 2rpx solid #fa4126;
color: #fa4126;
background-color: transparent;
font-size: 28rpx;
font-weight: bold;
}