uniapp 盒子内部滑动

<template>
    <view>
        <!--  -->
        <view style=" 100%;height: 400rpx;background-color: #007AFF;"></view>
        <view class="wrapperVue">
            
            
            <view class="sroll">
                <scroll-view scroll-y class="list-scroll">
                    <view>
                        <view class="demoa" v-for="item,index in 50">
                            {{item}}
                        </view>
                            
                    </view>
                </scroll-view>
            </view>
            
            
            
        </view>
        <!--  -->
    </view>
</template>

<script>
    export default {
        data() {
            return {
            }
        },
        created() {
            // console.log('create----------home')
            // this._created()
        },
        onLoad(options) {
            console.log('home:onLoad');
        }
    }
</script>

<style lang="scss">
    .wrapperVue{
         100%;
        display: flex;
        flex-direction: column;
        border: 10rpx red solid;
        height: 700rpx;
        .sroll{
             100%;
            overflow: hidden;
            box-sizing: border-box;
            .list-scroll{
                 100%;
                height: 100%;
                // display: flex;
                // flex-direction: column;
                .demoa{
                     100%;
                    height: 30rpx;
                    background-color: pink;
                    margin-top: 5rpx;
                }
            }
        }
    }
</style>
原文地址:https://www.cnblogs.com/vip-deng-vip/p/12890071.html