作者:韩韩韩韩韩海 | 来源:互联网 | 2023-09-02 17:01
please check out this code in jsfiddle
请在jsfiddle中查看此代码
HTML:
HTML:
CSS:
CSS:
#main
{
width: 64em;
height: 25em;
}
#menu
{
background-color: #00b875;
height: 3em;
}
.buttons
{
text-decoration: none;
color: #ffffff;
line-height: 3em;
display: inline-block;
padding-left: 10px;
padding-right: 10px;
font-family: courier new;
-moz-transition: 1s linear;
-ms-transition: 1s linear;
-o-transition: 1s linear;
-webkit-transition: 1s linear;
transition: 1s linear;
}
.buttons:hover
{
background-color: #0d96d6;
}
when switching from one button to another very quickly, you'll notice that there is actually some gap in between two buttons. i want to get rid of this space. any ideas? if you do answer the question, please also explain why a certain property will fix this.
当从一个按钮快速切换到另一个按钮时,您会注意到两个按钮之间实际上存在一些间隙。我想摆脱这个空间。有任何想法吗?如果您确实回答了这个问题,请解释为什么某个财产会解决这个问题。
i know that it is tweakable using padding and margin, but the result is likely to get distorted upon zoom. please point out a stable way of solving the problem.
我知道它可以使用填充和边距进行调整,但结果可能会在缩放时失真。请指出解决问题的稳定方法。
thanks
谢谢
9 个解决方案