浏览代码

粘性布局

xiaohaizhao 1 年之前
父节点
当前提交
d74fc43522
共有 1 个文件被更改,包括 3 次插入2 次删除
  1. 3 2
      packageA/options/index.wxml

+ 3 - 2
packageA/options/index.wxml

@@ -1,5 +1,6 @@
-<van-search custom-class='search' value="{{ paging.where.condition }}" shape="round" background="#fff" placeholder="请输入搜索关键字" bind:search='onSearch' bind:clear='onClear' />
-<view style="height: 20rpx;" />
+<view style="position: sticky; top: 0px; z-index: 999; background-color: #F4F5F7; padding-bottom: 20rpx;">
+    <van-search custom-class='search' value="{{ paging.where.condition }}" shape="round" background="#fff" placeholder="请输入搜索关键字" bind:search='onSearch' bind:clear='onClear' />
+</view>
 <van-checkbox-group value="{{ result }}" bind:change="onChange">
     <van-cell-group>
         <van-cell wx:for="{{ list }}" wx:key="value" title="{{ item.value }}" label="{{item.remarks}}" value-class="value-class" clickable data-item="{{ item }}" bind:click="toggle">