112 lines
4.0 KiB
Plaintext
112 lines
4.0 KiB
Plaintext
|
|
<view class="search-bar">
|
||
|
|
<view class="search-input">
|
||
|
|
<icon type="search" size="16" color="#999"></icon>
|
||
|
|
<input placeholder="搜索聊天记录" placeholder-class="placeholder-style"/>
|
||
|
|
</view>
|
||
|
|
</view>
|
||
|
|
<view style="width: 100vw;display: flex;justify-content: center;">
|
||
|
|
|
||
|
|
<view class="voting-card">
|
||
|
|
<!-- 卡片头部 -->
|
||
|
|
<view class="card-header">
|
||
|
|
<view class="user-info">
|
||
|
|
<image src="https://picsum.photos/id/64/200/200" mode="widthFix" class="avatar" alt="发起者头像"></image>
|
||
|
|
<view class="user-details">
|
||
|
|
<text class="username">张小萌</text>
|
||
|
|
<text class="user-status">需要你的帮助</text>
|
||
|
|
</view>
|
||
|
|
</view>
|
||
|
|
<view class="vote-status">进行中</view>
|
||
|
|
</view>
|
||
|
|
|
||
|
|
<view class="divider"></view>
|
||
|
|
|
||
|
|
<view class="vote-title-section">
|
||
|
|
<text class="vote-title">午餐该选哪个?好纠结啊!</text>
|
||
|
|
<text class="vote-desc">大家帮我投个票吧,选择困难症又犯了...</text>
|
||
|
|
</view>
|
||
|
|
|
||
|
|
<!-- 选项区域 -->
|
||
|
|
<view class="options-container">
|
||
|
|
<!-- 选项1 -->
|
||
|
|
<view class="option-item {{selectedOption === '1' ? 'selected' : ''}}" bindtap="selectOption" data-id="1">
|
||
|
|
<view class="option-info">
|
||
|
|
<view class="option-icon bg-red">
|
||
|
|
<text class="iconfont icon-cutlery"></text>
|
||
|
|
</view>
|
||
|
|
<view class="option-details">
|
||
|
|
<text class="option-name">麻辣烫</text>
|
||
|
|
<text class="option-desc">鲜香麻辣,越吃越开胃</text>
|
||
|
|
</view>
|
||
|
|
</view>
|
||
|
|
<text class="option-percent">42%</text>
|
||
|
|
|
||
|
|
<view class="progress-bar">
|
||
|
|
<view class="progress-value" style="width: 42%"></view>
|
||
|
|
</view>
|
||
|
|
|
||
|
|
<view class="vote-indicator {{selectedOption === '1' ? 'show' : ''}}">
|
||
|
|
<text class="iconfont icon-check-circle"></text>
|
||
|
|
</view>
|
||
|
|
</view>
|
||
|
|
|
||
|
|
<!-- 选项2 -->
|
||
|
|
<view class="option-item {{selectedOption === '2' ? 'selected' : ''}}" bindtap="selectOption" data-id="2">
|
||
|
|
<view class="option-info">
|
||
|
|
<view class="option-icon bg-yellow">
|
||
|
|
<text class="iconfont icon-coffee"></text>
|
||
|
|
</view>
|
||
|
|
<view class="option-details">
|
||
|
|
<text class="option-name">汉堡套餐</text>
|
||
|
|
<text class="option-desc">快捷方便,配冰可乐</text>
|
||
|
|
</view>
|
||
|
|
</view>
|
||
|
|
<text class="option-percent">28%</text>
|
||
|
|
|
||
|
|
<view class="progress-bar">
|
||
|
|
<view class="progress-value" style="width: 28%"></view>
|
||
|
|
</view>
|
||
|
|
|
||
|
|
<view class="vote-indicator {{selectedOption === '2' ? 'show' : ''}}">
|
||
|
|
<text class="iconfont icon-check-circle"></text>
|
||
|
|
</view>
|
||
|
|
</view>
|
||
|
|
|
||
|
|
<!-- 选项3 -->
|
||
|
|
<view class="option-item {{selectedOption === '3' ? 'selected' : ''}}" bindtap="selectOption" data-id="3">
|
||
|
|
<view class="option-info">
|
||
|
|
<view class="option-icon bg-green">
|
||
|
|
<text class="iconfont icon-leaf"></text>
|
||
|
|
</view>
|
||
|
|
<view class="option-details">
|
||
|
|
<text class="option-name">沙拉轻食</text>
|
||
|
|
<text class="option-desc">健康低卡,适合减脂</text>
|
||
|
|
</view>
|
||
|
|
</view>
|
||
|
|
<text class="option-percent">30%</text>
|
||
|
|
|
||
|
|
<view class="progress-bar">
|
||
|
|
<view class="progress-value" style="width: 30%"></view>
|
||
|
|
</view>
|
||
|
|
|
||
|
|
<view class="vote-indicator {{selectedOption === '3' ? 'show' : ''}}">
|
||
|
|
<text class="iconfont icon-check-circle"></text>
|
||
|
|
</view>
|
||
|
|
</view>
|
||
|
|
</view>
|
||
|
|
|
||
|
|
<view class="vote-stats">
|
||
|
|
<text class="stats-text">已有 126 人参与投票</text>
|
||
|
|
<text class="stats-text">剩余 23 小时结束</text>
|
||
|
|
</view>
|
||
|
|
|
||
|
|
<!-- 投票按钮 -->
|
||
|
|
<button class="vote-btn" bindtap="submitVote">
|
||
|
|
<text class="iconfont icon-thumbs-up"></text>
|
||
|
|
<text class="btn-text">投我一票</text>
|
||
|
|
</button>
|
||
|
|
</view>
|
||
|
|
</view>
|
||
|
|
|
||
|
|
|
||
|
|
|