refactor(ui): 首页添加回到最顶端按钮

This commit is contained in:
2025-10-27 17:43:43 +08:00
parent 6632080b83
commit ca310d6c02
2 changed files with 18 additions and 5 deletions

View File

@@ -126,7 +126,7 @@
<!-- 小程序隐私协议 -->
<privacy-popup ref="privacyPopup"></privacy-popup>
<!-- #endif -->
<to-top class="mescroll-totop" v-if="showTop" @toTop="scrollToTopNative()"></to-top>
</view>
</template>
@@ -135,13 +135,22 @@
import nsNavbar from '@/components/ns-navbar/ns-navbar.vue';
import diyJs from '@/common/js/diy.js';
import indexJs from './public/js/index.js';
import toTop from '@/components/toTop/toTop.vue';
import scroll from '@/common/js/scroll-view.js';
export default {
data() {
return {
minScrollTop: 200,
}
},
components: {
uniPopup,
nsNavbar
nsNavbar,
toTop
},
mixins: [diyJs, indexJs]
mixins: [diyJs, indexJs, scroll]
};
</script>
@@ -190,6 +199,9 @@
font-size: 60rpx;
}
.mescroll-totop {
bottom: 100px !important;
}
</style>
<style scoped>