uniapp css实现吸顶

给需要吸顶的部分添加sticky样式

.sticky{
	/* #ifndef APP-PLUS-NVUE */
	display: flex;
	position: -webkit-sticky;
	/* #endif */
	position: sticky;
	top: var(--window-top);
	z-index: 99;
}
发布了12 篇原创文章 · 获赞 2 · 访问量 389

猜你喜欢

转载自blog.csdn.net/qq_42739199/article/details/105164284