feat: 收口多品牌与模板构建基础
This commit is contained in:
1 parent
0425a1c672
commit
77224ea51f
317 files changed
+11290
-1158
No files matched your search
@@ -0,0 +1,15 @@
|
||||
Component({
|
||||
properties: {
|
||||
brand: { type: Object, value: {} },
|
||||
presentation: { type: Object, value: {} },
|
||||
offerings: { type: Array, value: [] },
|
||||
},
|
||||
methods: {
|
||||
open(e) {
|
||||
this.triggerEvent("open", { id: e.currentTarget.dataset.id });
|
||||
},
|
||||
inquire() {
|
||||
this.triggerEvent("inquire");
|
||||
},
|
||||
},
|
||||
});
|
||||
@@ -0,0 +1 @@
|
||||
{ "component": true }
|
||||
@@ -0,0 +1 @@
|
||||
<view class="page"><view class="head"><text class="eyebrow">{{brand.name}}</text><text class="title">{{presentation.title || '今日菜单'}}</text><text class="subtitle">{{presentation.subtitle || '现做现吃,支持提前预留和团体定制'}}</text></view><view class="tip">米饭免费续,口味和忌口都可以在预约时备注</view><view class="list"><view wx:for="{{offerings}}" wx:key="id" class="dish" data-id="{{item.id}}" bindtap="open"><image src="{{item.image}}" mode="aspectFill"/><view class="copy"><text class="name">{{item.name}}</text><text class="desc">{{item.desc}}</text><view class="bottom"><text class="price">{{item.priceRange}}</text><text class="action">查看详情 ›</text></view></view></view></view><button class="cta" bindtap="inquire">团体活动 / 定制餐咨询</button></view>
|
||||
@@ -0,0 +1,93 @@
|
||||
.page {
|
||||
min-height: 100vh;
|
||||
padding: 28rpx;
|
||||
background: #fff8f0;
|
||||
color: #29231f;
|
||||
}
|
||||
.eyebrow {
|
||||
display: block;
|
||||
color: #d2652b;
|
||||
font-size: 19rpx;
|
||||
letter-spacing: 2rpx;
|
||||
}
|
||||
.title {
|
||||
display: block;
|
||||
margin-top: 8rpx;
|
||||
font-size: 42rpx;
|
||||
font-weight: 700;
|
||||
}
|
||||
.subtitle {
|
||||
display: block;
|
||||
margin-top: 8rpx;
|
||||
color: #8c7b70;
|
||||
font-size: 22rpx;
|
||||
}
|
||||
.tip {
|
||||
margin-top: 22rpx;
|
||||
padding: 18rpx 20rpx;
|
||||
border: 1rpx solid #f8d7b4;
|
||||
border-radius: 18rpx;
|
||||
background: #fff7df;
|
||||
color: #8c5c39;
|
||||
font-size: 21rpx;
|
||||
}
|
||||
.list {
|
||||
margin-top: 18rpx;
|
||||
}
|
||||
.dish {
|
||||
display: flex;
|
||||
gap: 18rpx;
|
||||
margin-bottom: 16rpx;
|
||||
padding: 14rpx;
|
||||
border: 1rpx solid #f2e2d6;
|
||||
border-radius: 22rpx;
|
||||
background: #fff;
|
||||
}
|
||||
.dish image {
|
||||
width: 196rpx;
|
||||
height: 196rpx;
|
||||
flex: none;
|
||||
border-radius: 16rpx;
|
||||
background: #f3e7de;
|
||||
}
|
||||
.copy {
|
||||
display: flex;
|
||||
min-width: 0;
|
||||
flex: 1;
|
||||
flex-direction: column;
|
||||
}
|
||||
.name {
|
||||
font-size: 26rpx;
|
||||
font-weight: 700;
|
||||
line-height: 1.45;
|
||||
}
|
||||
.desc {
|
||||
margin-top: 10rpx;
|
||||
color: #8c7b70;
|
||||
font-size: 20rpx;
|
||||
line-height: 1.5;
|
||||
}
|
||||
.bottom {
|
||||
display: flex;
|
||||
align-items: end;
|
||||
justify-content: space-between;
|
||||
margin-top: auto;
|
||||
}
|
||||
.price {
|
||||
color: #dc6429;
|
||||
font-size: 25rpx;
|
||||
font-weight: 700;
|
||||
}
|
||||
.action {
|
||||
color: #d2652b;
|
||||
font-size: 20rpx;
|
||||
}
|
||||
.cta {
|
||||
margin: 22rpx 0 0;
|
||||
height: 76rpx;
|
||||
border-radius: 20rpx;
|
||||
background: #e87532;
|
||||
color: #fff;
|
||||
font-size: 24rpx;
|
||||
line-height: 76rpx;
|
||||
}
|
||||
Reference in new issue
Block a user