scroll-view 滑动组织整体页面滑动问题
发布于 6 年前 作者 xiuyingliang 11819 次浏览 来自 问答

scroll-view 滑动组织整体页面滑动问题,苹果手机正常,安卓手机整个页面滑动

代码如下:

<view class=“content-tuijian”>

    <view class=“tuijian-title”>{{content.cat_name}}</view>

    <view>

        <scroll-view class=“recommend_scroll_x_box” scroll-x=“true”>

            <view class=“recommend_hot_box” wx:for="{{tuijian}}" bindtap=“goContent” data-id="{{item.id}}">

                <image src="{{item.thumb}}" class=“recommend_hot_image”></image>

                <view style=‘margin-top: 30rpx;’></view>

                <view class=“re-title”>{{item.title}}</view>

            </view>

        </scroll-view>

    </view>

</view>

.content-tuijian {

margin-left: 0rpx;

margin-top: 0rpx;

}

.tuijian-title {

margin-bottom: 30rpx;

margin-top: 30rpx;

}

.recommend_scroll_x_box {

white-space: nowrap;

display: flex;

}

.recommend_hot_box {

position: relative;

/* width: 750rpx;  */

width: 100%;

height: 400rpx;

margin-right: 0rpx;

margin-left: 0rpx;

display: inline-block;

}

.recommend_hot_image {

margin-left: 25rpx;

width: 700rpx;

height: 380rpx;

border-radius: 10rpx;

margin-bottom: 70rpx;

}

.re-title {

height: 0rpx;

line-height: 0rpx;

white-space: pre-line;

position: absolute;

bottom: -26rpx;

font-size: 34rpx;

font-weight: bold;

padding-top: 50rpx;

margin-top: 30rpx;

margin-left: 30rpx;

}

1 回复

恕我直言,您好像没设置的 recommend_scroll_x_box 高度和宽度吧?

回到顶部