findme-miniprogram-frontend/subpackages/realname/camera-verify.wxml
2025-12-27 17:16:03 +08:00

38 lines
1.7 KiB
Text

<view class="camera-verify-container">
<view class="header">
<text class="title">摄像头实名认证</text>
<text class="desc">请正对镜头,确保光线充足,按提示完成拍摄</text>
</view>
<!-- 顶部动作说明(始终显示当前动作,强调眨眨眼) -->
<view class="top-hint">
<text class="top-hint-text">动作说明:{{livenessSteps[stepIndex] || '请眨眨眼'}}</text>
</view>
<view class="camera-box">
<camera device-position="front" flash="off" class="camera" mode="normal" frame-size="medium" binderror="onCameraError"></camera>
<view class="liveness-hint">
<text class="hint-text">{{livenessSteps[stepIndex]}}</text>
<view class="hint-actions">
<button class="hint-btn" bindtap="onNextAction">我已完成</button>
</view>
<view class="hint-dots">
<block wx:for="{{livenessSteps}}" wx:key="index">
<view class="dot {{index <= stepIndex-1 ? 'done' : ''}}"></view>
</block>
</view>
</view>
</view>
<view class="actions">
<button class="btn capture {{stepIndex >= livenessSteps.length && !isCapturing ? 'enabled' : 'disabled'}}" bindtap="onCapture" disabled="{{isCapturing}}">{{isCapturing ? '拍照中...' : '拍照'}}</button>
<button class="btn retake" wx:if="{{photoPath}}" bindtap="onRetake" disabled="{{isUploading}}">重拍</button>
<button class="btn submit {{photoPath && !isUploading ? 'enabled' : 'disabled'}}" bindtap="onSubmit" disabled="{{isUploading}}">{{isUploading ? '提交中...' : '提交认证'}}</button>
</view>
<view class="preview" wx:if="{{photoPath}}">
<image class="preview-image" src="{{photoPath}}" mode="aspectFit" />
</view>
</view>