feat: 数感启蒙、专注力页面重构、首页入口开发

This commit is contained in:
R524809
2026-04-21 17:51:16 +08:00
parent b2f5b203f8
commit 28151018ee
212 changed files with 2722 additions and 5207 deletions
@@ -0,0 +1,86 @@
<nav-bar title="{{pageTitle}}" />
<view class="fd-page">
<view class="fd-main">
<!-- 打印预览卡 -->
<view class="fd-preview-wrap">
<view class="fd-preview-card">
<text class="fd-preview-kicker">打印预览</text>
<view id="canvasWrapper" class="fd-canvas-wrap">
<canvas
type="2d"
id="canvasContent"
class="fd-canvas"
style="width:{{boxWidth}}px;height:{{boxHeight}}px" />
</view>
</view>
</view>
<!-- 练习类型选择(2列卡片网格) -->
<view class="fd-section">
<text class="fd-section-title">练习类型</text>
<view class="fd-type-grid">
<view
wx:for="{{typeList}}"
wx:key="id"
class="fd-type-card {{selectedTypeId === item.id ? 'fd-type-card--active' : ''}}"
data-id="{{item.id}}"
hover-class="fd-type-card--pressed"
hover-start-time="0"
hover-stay-time="70"
bindtap="onSelectType">
<text class="fd-type-card__icon">{{item.icon}}</text>
<text class="fd-type-card__label">{{item.title}}</text>
</view>
</view>
</view>
<!-- 子选项(当前类型有模式切换时显示) -->
<view wx:if="{{showActions}}" class="fd-section">
<text class="fd-section-title">{{actionsTitle}}</text>
<view class="fd-chip-row">
<view
wx:for="{{currentActions}}"
wx:key="value"
class="fd-chip {{currentMode === item.value ? 'fd-chip--active' : ''}}"
data-value="{{item.value}}"
hover-class="fd-chip--pressed"
hover-start-time="0"
hover-stay-time="70"
bindtap="onSelectMode">
{{item.label}}
</view>
</view>
</view>
<!-- 随机生成按钮 -->
<view
class="fd-shuffle-btn"
hover-class="fd-shuffle-btn--hover"
hover-start-time="0"
hover-stay-time="70"
bindtap="onRandom">
<toy-icon
name="refresh"
size="40rpx"
color="#605b50"
custom-class="fd-shuffle-btn__icon" />
<text class="fd-shuffle-btn__text">随机生成</text>
</view>
<!-- 广告位 -->
<draw-ad type="focusDraw"></draw-ad>
</view>
</view>
<!-- 底部操作栏 -->
<preview-footer-actions
disabled="{{!hasContent}}"
bind:primary="exportToPrint"
bind:secondary="onShare" />
<!-- 分享引导弹窗 -->
<share-guide-popup
show="{{showShareDialog}}"
bind:onClose="onCloseShareDialog"
bind:onShareSuccess="onShareSuccess" />