Files
past-go/weapp/pages/pet/achievements.wxml
Blizzard b854d2873e feat: require couple binding and refine miniapp settings
Gate record features and storage entry points with invitation guidance; enforce record access in the backend. Add homepage greetings, right-swipe profile dismissal, and move the smoking switch to settings. Simplify API base configuration and remove the unused legacy tab bar component.
2026-11-04 21:27:03 +08:00

44 lines
1.9 KiB
Plaintext

<view wx:if="{{!recordAccessBlocked}}" capture-bind:tap="onLoginSubscribeTap" class="app-shell app-shell--secondary" style="{{layoutStyle}}">
<launch-transition />
<!-- pages/pet/achievements.wxml -->
<app-nav title="宠物成就" back="{{true}}" />
<scroll-view class="page-bg" scroll-y show-scrollbar="{{false}}" bounces="{{true}}">
<view class="container">
<page-state wx:if="{{loading}}" kind="loading" title="正在加载" /><page-state wx:elif="{{loadError}}" kind="error" title="加载失败" action="重试" bind:action="loadAchievements" /><block wx:else>
<!-- 成就概览 -->
<view class="ach-summary">
<view class="ach-deco ach-deco-1">🌟</view>
<view class="ach-deco ach-deco-2">🏅</view>
<text class="ach-count">{{unlockedCount}}<text class="ach-total">/{{totalCount}}</text></text>
<text class="ach-progress-text">已解锁成就</text>
<view class="ach-progress-track">
<view class="ach-progress-fill" style="width:{{progressPercent}}%;"></view>
</view>
<text class="ach-percent">{{progressPercent}}%</text>
</view>
<!-- 成就列表 -->
<view class="ach-list">
<view wx:for="{{achievements}}" wx:key="key" class="ach-card {{item.unlocked?'':'locked'}}">
<view class="ach-card-icon">
<text>{{item.unlocked ? item.icon : '🔒'}}</text>
</view>
<view class="ach-card-info">
<view class="ach-card-name-row">
<text class="ach-card-name">{{item.name}}</text>
<text class="ach-card-status {{item.unlocked?'unlocked':'locked-badge'}}">{{item.unlocked ? '已解锁' : '未解锁'}}</text>
</view>
<text class="ach-card-desc">{{item.desc}}</text>
<text wx:if="{{item.unlocked && item.unlocked_at}}" class="ach-card-time">🏅 {{item.unlocked_at}}</text>
</view>
</view>
</view>
</block>
</view>
</scroll-view>
</view>