已解决
uniapp的/绝对定位/相对定位/固定定位/粘滞定位
来自网友在路上 176876提问 提问时间:2023-11-20 14:24:09阅读次数: 76
最佳答案 问答题库768位专家为你答疑解惑
【[html5]你还分不清楚绝对定位和相对定位......】
相对定位一般配合绝对定位使用
<template><view class="content"><view style="background-color: black;width: 100%;height: 300px;position:relative;"><view class="one">1</view></view><view style="background-color:antiquewhite;width: 100%;height: 1000px;position:relative;"></view></view>
</template>
<script>export default {data() {return {}},onReady(res) {},created() {},methods: {}}
</script>
<style>.one{width: 100px;height: 100px;background: #0ff;position: sticky;left: 100px;top:100px;}
</style>
查看全文
99%的人还看了
猜你感兴趣
版权申明
本文"uniapp的/绝对定位/相对定位/固定定位/粘滞定位":http://eshow365.cn/6-40396-0.html 内容来自互联网,请自行判断内容的正确性。如有侵权请联系我们,立即删除!
- 上一篇: 【下载器】NDM和IDM介绍(含安装包和教程)
- 下一篇: markdown 公式编辑