1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283 |
- <view class="container">
- <!-- 海报预览区域 -->
- <view class="poster-preview">
- <view class="preview-title">海报预览</view>
- <view class="preview-area">
- <image class="poster-image" src="{{currentPoster.url}}" mode="widthFix"></image>
- </view>
- </view>
- <!-- 海报模板选择 -->
- <view class="template-select">
- <view class="section-title">选择模板</view>
- <scroll-view class="template-list" scroll-x="true">
- <view
- class="template-item {{currentPoster.id === item.id ? 'active' : ''}}"
- wx:for="{{posterList}}"
- wx:key="id"
- bindtap="selectTemplate"
- data-id="{{item.id}}"
- >
- <image class="template-image" src="{{item.url}}" mode="aspectFill"></image>
- </view>
- </scroll-view>
- </view>
- <!-- 商品选择 -->
- <view class="goods-select" wx:if="{{showGoodsSelect}}">
- <view class="section-title">选择商品</view>
- <scroll-view class="goods-list" scroll-x="true">
- <view
- class="goods-item {{currentGoods.id === item.id ? 'active' : ''}}"
- wx:for="{{goodsList}}"
- wx:key="id"
- bindtap="selectGoods"
- data-id="{{item.id}}"
- >
- <image class="goods-image" src="{{item.image}}" mode="aspectFill"></image>
- <view class="goods-info">
- <view class="goods-name">{{item.name}}</view>
- <view class="goods-price">¥{{item.price}}</view>
- </view>
- </view>
- </scroll-view>
- </view>
- <!-- 自定义文案 -->
- <view class="custom-text" wx:if="{{showCustomText}}">
- <view class="section-title">自定义文案</view>
- <view class="text-input">
- <textarea
- value="{{customText}}"
- placeholder="请输入自定义文案"
- maxlength="100"
- bindinput="onTextChange"
- ></textarea>
- <view class="text-counter">{{customText.length}}/100</view>
- </view>
- </view>
- <!-- 操作按钮 -->
- <view class="action-buttons">
- <button class="btn btn-preview" bindtap="previewPoster">
- <text class="iconfont icon-preview"></text>
- <text>预览</text>
- </button>
- <button class="btn btn-save" bindtap="savePoster">
- <text class="iconfont icon-save"></text>
- <text>保存到相册</text>
- </button>
- <button class="btn btn-share" open-type="share">
- <text class="iconfont icon-share"></text>
- <text>分享</text>
- </button>
- </view>
- <!-- 生成中遮罩 -->
- <view class="generating-mask" wx:if="{{generating}}">
- <view class="generating-content">
- <view class="loading-icon"></view>
- <text>海报生成中...</text>
- </view>
- </view>
- </view>
|