奇怪的样式应用于Firefox v60中的按钮

时间:2019-03-26 14:40:43

标签: css firefox

在Firefox中,<button>元素已应用了我不太理解的默认浏览器样式。检查员说它的左右边界为17px。

检查时的外观如下:

enter image description here enter image description here enter image description here

,并在过滤时也显示浏览器样式:

enter image description here

有趣的是它显示为border-right-width 17px,但是折叠规则会从浏览器默认样式button > 2px中显示forms.css:611。样式表的该行明确指出边框应为2px:

/* Non text-related properties for buttons: these ones are shared with
input[type="color"] */
button,
input[type="color"],
input[type="reset"],
input[type="button"],
input[type="submit"] {
  -moz-appearance: button;
  /* The sum of border and padding on block-start and block-end
     must be the same here, for text inputs, and for <select>.
     Note -moz-focus-inner padding does not affect button size. */
  padding-block-start: 0px;
  padding-inline-end: 8px;
  padding-block-end: 0px;
  padding-inline-start: 8px;
  border: 2px outset ThreeDLightShadow;
  background-color: ButtonFace;
  cursor: default;
  box-sizing: border-box;
  -moz-user-select: none;
  -moz-binding: none;
}

那么这是怎么回事?我缺少明显的东西吗?

同样,这是Debian上的Firefox v60.0.2。

0 个答案:

没有答案