gpt4 book ai didi

html - 当边框不在 ul 元素上时如何覆盖事件选项卡上的边框

转载 作者:太空宇宙 更新时间:2023-11-04 02:40:00 26 4
gpt4 key购买 nike

我知道如何在 ul 元素上设置边框时删除(覆盖)事件选项卡上的边框,例如 this ,通过在选项卡元素上设置 margin-right: -1px

但是,当边框在另一个面板上时,我该怎么办呢?我设置了margin-right: -1px,但是没有意义......

Here is the demo , 我想打破事件选项卡和右侧面板之间的边界。

最佳答案

您需要设置position: relative 和一个z-index 将li 放在面板上方

li {
color: #999;
border: 1px solid #999;
border-right-color: transparent;
margin-bottom: 20px;
/* add these two rules */
position: relative;
z-index: 2;
}

关于html - 当边框不在 ul 元素上时如何覆盖事件选项卡上的边框,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/34938046/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com