【问题标题】:items not aligning correctly in safari在 Safari 中未正确对齐的项目
【发布时间】:2015-11-28 00:16:17
【问题描述】:

我的操作栏中的元素不会留在 Safari 和 ipad 中。它甚至不规则地上下移动(如您在下面的两个不同图像中所见)。由于 ipad 上的 chrome 是基于 safari webkit 引擎构建的,因此应该可以使用它。

我似乎找不到解决方案。

在下图中,您可以看到它以div.profile 开头。

nav .profile {
    height: 100%;
    margin: 0;
    padding: 0;
    position: relative;
    top: 0;
}

还有更多代码,但我输入了JSfiddle。 使用了 Bootstrap 3,我使用的是 flexbox,可能值得一提。

谁知道更多


http://jsfiddle.net/ynwvvzt0/

【问题讨论】:

    标签: html css twitter-bootstrap safari flexbox


    【解决方案1】:

    将此添加到您的 CSS 中。

    nav a.icon, nav .profile, nav .profile div {
        display: inline-block;
        vertical-align: top;
    }
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2010-12-15
      • 1970-01-01
      • 2018-12-17
      • 2018-06-06
      • 1970-01-01
      • 1970-01-01
      • 2016-02-21
      • 2023-03-06
      相关资源
      最近更新 更多