litian
2024-06-26 ccda9ec2fe70d8f51ef184eafc04b78d22dfbabd
pages/home/home.wxml
@@ -1,5 +1,5 @@
<view class="container">
  <t-pull-down-refresh value="{{baseRefresh.value}}" loadingTexts="{{['下拉刷新', '松手刷新', '正在刷新', '刷新完成']}}" bind:refresh="onPullDownRefresh" bind:scroll="onScroll">
  <t-pull-down-refresh value="{{baseRefresh.value}}" loadingTexts="{{['下拉刷新', '松手刷新', '正在刷新', '刷新完成']}}" bind:refresh="onPullDownRefresh" wx:if="{{!loading}}" bind:scroll="onScroll">
    <view class="background {{ isWhite ? 'white':''}}" style="padding-top: {{barHeight}}px">
      <text class="text">京师E课</text>
    </view>
@@ -8,12 +8,20 @@
        <image src="/static/images/home/home-bg.png" mode="heightFix" class="image" />
      </view>
      <view class="search">
        <image class="icon" src="/static/images/home/nav_icon_scan.png" bindtap="onIconScanTap" />
        <t-search t-class-input="t-search__input" t-class-input-container="t-search__input-container" placeholder="请输入关键词/书名/ISBN/作者" leftIcon="" bind:submit="onRetrievalPage" model:value="{{searchVal}}">
          <t-icon slot="left-icon" prefix="wr" name="search" size="40rpx" color="#bbb" bind:tap="navToSearchPage" />
        </t-search>
      </view>
      <view class="swiper-wrap">
        <t-swiper wx:if="{{bannerList.length > 0}}" list="{{bannerList}}" autoplay="{{autoplay}}" duration="{{duration}}" interval="{{interval}}" navigation="{{navigation}}" height="380rpx" bind:click="navToActivityDetail" />
        <!-- <t-swiper wx:if="{{bannerList.length > 0}}" list="{{bannerList}}" autoplay="{{autoplay}}" duration="{{duration}}" interval="{{interval}}" navigation="{{ { type: 'dots' } }}" height="380rpx" bind:click="navToActivityDetail" /> -->
        <swiper interval="5000" indicator-dots="true" autoplay="true" circular="true" class="swiper">
          <swiper-item wx:for="{{bannerList}}" wx:for-index="index" wx:key="index" data-info="{{item}}" bindtap="navToActivityDetail">
            <view class="swiperItem">
              <image src="{{item.value}}" mode="widthFix" class="img" />
            </view>
          </swiper-item>
        </swiper>
      </view>
    </view>
    <view class="home-page-menu">
@@ -27,7 +35,7 @@
          <view class="icon">
            <image src="/static/images/home/zhuantitaolun2.png" mode="aspectFit" class="iconImage" />
          </view>
          <view data-info="{{'zhuantitaolun'}}" bindtap="onMoreGuide" class="flex">
          <view data-info="{{'zhuantitaolun'}}" bindtap="onMoreGuide" class="flex" style="align-items: center">
            <text class="more">更多</text>
            <t-icon name="chevron-right" size="32rpx" color="#ff6d00" />
          </view>
@@ -111,7 +119,7 @@
            <view wx:for="{{booksList}}" wx:for-item="item" wx:for-index="index" wx:key="index" class="booksListItemBox">
              <view class="listItem" bind:tap="goDetail" data-book="{{item}}">
                <view class="specialSubject-img">
                  <image src="{{item.icon}}" mode="aspectFit" class="img" />
                  <image src="{{item.icon ? item.icon : '/static/images/default-book-img.png'}}" mode="aspectFit" class="img" aria-label="{{item.name}}" />
                </view>
                <view class="body-info">
                  <view class="name">{{item.name}}</view>
@@ -185,7 +193,7 @@
          </view>
        </view>
        <view class="rankingList">
          <scroll-view class="srcolbox" scroll-x scroll-with-animation='true'>
          <scroll-view class="srcolbox" scroll-x scroll-with-animation="true">
            <view class="booksListBox">
              <view wx:for="{{rankingList}}" wx:for-item="item" wx:for-index="index" wx:key="index" class="booksListItemBox">
                <view class="listItem" bind:tap="goDetail" data-book="{{item}}">
@@ -205,4 +213,6 @@
      </view>
    </view>
  </t-pull-down-refresh>
</view>
</view>
<import src="home.skeleton.wxml" />
<template is="skeleton" wx:if="{{loading}}" />