# 最近的更新破坏了我的顶部导航栏

**URL:** <https://meta.discourse.org/t/recent-update-broke-my-top-navigation-bar/168702>\
**Category:** Support\
**Created:** [2020 年10 月 30 日 02:27 UTC](https://meta.discourse.org/t/recent-update-broke-my-top-navigation-bar/168702 "2020-10-30T02:27:21Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

作者： ![tophee](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/tophee/32/73406_2.png) [@tophee](https://meta.discourse.org/u/tophee)\
发布日期： [2020 年10 月 30 日 02:27 UTC](https://meta.discourse.org/t/recent-update-broke-my-top-navigation-bar/168702/1 "2020-10-30T02:27:21Z")

</div>

最近的一次升级破坏了我的顶部导航栏——更具体地说，导航栏会加载（仅闪现一瞬间），但随后标准的 Discourse 页头会覆盖在上面并将其隐藏。

我正试图弄清楚究竟发生了什么，以及如何修复它。能否有人给我指个方向？

通过在浏览器中检查页面，我发现设置

```plaintext
.d-header-wrap {
    margin-top: 48px;
}

```

可以将页头向下移动以露出导航栏（高度为 48px），这似乎解决了问题。

但我不确定这是否是可持续的修复方式，同时也很好奇究竟发生了什么。

我还不得不从我的组件中移除

```plaintext
#main-outlet { margin-top: 48px; padding-top: 75px;}

```

以消除页头下方出现的额外空白空间。这段代码多年来一直运行正常，所以我很想知道是什么导致了它失效……

我还移除了其他一些内容，例如

```plaintext
#main-outlet.docked {
    margin-top: 0px;
    padding-top: 123px
}

```

因为它似乎没有产生任何影响。

编辑：上述情况适用于桌面端 CSS。在移动端，我不需要增加导航栏的 Z 值。

---

_[View the full topic](https://meta.discourse.org/t/recent-update-broke-my-top-navigation-bar/168702)._
