feat: migrate static pages to native tabbar
This commit is contained in:
50
packages/tcm/pages/search-books/index.wxml
Normal file
50
packages/tcm/pages/search-books/index.wxml
Normal file
@@ -0,0 +1,50 @@
|
||||
<view class="search-books-page">
|
||||
<view class="hero-card">
|
||||
<text class="hero-card__title">{{title}}</text>
|
||||
<text class="hero-card__description">{{summary}}</text>
|
||||
|
||||
<view class="search-row">
|
||||
<input
|
||||
class="search-row__input"
|
||||
value="{{draftKeyword}}"
|
||||
placeholder="{{placeholder}}"
|
||||
bindinput="handleKeywordInput"
|
||||
/>
|
||||
<view class="search-row__button" bindtap="handleSearchTap">搜索</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="section-card">
|
||||
<text class="section-card__title">{{historyTitle}}</text>
|
||||
<view class="history-list">
|
||||
<view
|
||||
class="history-chip"
|
||||
wx:for="{{history}}"
|
||||
wx:key="key"
|
||||
data-keyword="{{item.label}}"
|
||||
bindtap="handleHistoryTap"
|
||||
>
|
||||
{{item.label}}
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view wx:if="{{results.length}}" class="section-card">
|
||||
<text class="section-card__title">搜索结果</text>
|
||||
<view
|
||||
class="result-card"
|
||||
wx:for="{{results}}"
|
||||
wx:key="key"
|
||||
data-route="{{item.route}}"
|
||||
bindtap="handleResultTap"
|
||||
>
|
||||
<text class="result-card__title">{{item.title}}</text>
|
||||
<text class="result-card__subtitle">{{item.subtitle}}</text>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view wx:elif="{{searched}}" class="section-card">
|
||||
<text class="section-card__title">没有找到相关典籍</text>
|
||||
<text class="section-card__description">换一个书名或常见别名再试试。</text>
|
||||
</view>
|
||||
</view>
|
||||
Reference in New Issue
Block a user