Opening admin and settings header turns white


(Mike) #1

Opening admin or settings through right click/new tab or /new window the header does’ttake on the code written in the custom header and therefore turns white.
Is this a bug or something I have done wrong in CSS/HTML?


Custom header elements fail to load
(Rafael dos Santos Silva) #2

Are you on the latest version of Discourse?


(Mike) #3

I’m on "v1.9.0.beta1 +43"
Seems like it does not load the costum css class I assigned for the header.
For example one of the classes I set up was “.forum-header” and I can’t located it when it has loaded in the new tab.


(Mike) #4

Code I used for the header

HTML

    <div class="forum-header">
<img class="forum-logo" src="https://community.mikes.cafe/uploads/default/original/1X/b6880c253d6fe557f3c9a4a37daca94457b5eeee.png" alt="Mike's Café">
<div class="dropdown">
  <a href="https://community.mikes.cafe/" class="community-header">#community</a>
    <div class="dropdown-content-last">
    <ul>
    <a href="https://community.mikes.cafe/">forum öffne dich</a>
    <a href="https://mikes.cafe/community-rules/">community spielregeln</a>
    <button id="feedback-form">Feedback</button>
    </ul>
</div>
</div>
<div class="dropdown">
  <a href="https://mikes.cafe/blog/" class="community-header">#blog</a>
  <div class="dropdown-content">
       <ul>
    <a href="https://mikes.cafe/blog/">blog: article</a>
    <a href="https://mikes.cafe/blog-wer-wie-was/">blog: wer? wie? was?</a>
    <a href="https://mikes.cafe/guest-author/">blog: gastbeiträge</a>
    <a href="https://mikes.cafe/favorite-recipes/">favorite: recipes</a>
    <a href="https://mikes.cafe/favorite-books/">favorite: books</a>
    <a href="https://mikes.cafe/favorite-links/">favorite: links</a>
</ul> 
  </div>
</div>

<div class="dropdown">
  <a href="https://mikes.cafe/world-of-hospitality/" class="community-header">#hospitality</a>
  <div class="dropdown-content">
      <ul>
    <a href="https://mikes.cafe/world-of-hospitality/">world of hospitality</a>
    <a href="https://mikes.cafe/inspiration/">time for inspiration</a>
    <a href="https://mikes.cafe/">back to start</a>
</ul>
  </div>
  </div>
  </div>

CSS

.forum-logo {
   padding: 21px 0 21px 57px;
   background-color: #000;
   width: 150px;
   height: 100%;
}

.forum-header {
    padding: 0;
    background-color: #000;
    width: 100%;
    z-index: 1200;
    position: fixed;
}

.community-header {
    color: #FFF !important;
    font-size: 0.8em;
    letter-spacing: 2px;
	border: none;
    cursor: pointer;
    line-height: 88px;
}

.dropdown {
    position: relative;
    display: inline-block;
    float: right;
    padding: 0 60px 0 0;
    z-index: 1300;
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: #000;
    min-width: 200px;
    z-index: 100;
    font-size: 0.8em;
    letter-spacing: 1px;
    border-top: 1px solid #FFF;
}


.dropdown-content-last {
    display: none;
    position: absolute;
    background-color: #000;
    min-width: 200px;
    z-index: 100;
    font-size: 0.8em;
    letter-spacing: 1px;
    border-top: 1px solid #FFF;
    left: auto;
    right: 0;
    margin-right: 53px;
}

.dropdown-content-last ul,
.dropdown-content ul{
    margin: 10px 0;
}

.dropdown-content-last a,
.dropdown-content a {
    color: #FFF;
    padding: 5px 0 5px 23px;
    display: block;
    letter-spacing: 0px !important;
}

.dropdown-content-last a:hover,
.dropdown-content a:hover {
    font-style: italic;
}

.dropdown:hover .dropdown-content-last,
.dropdown:hover .dropdown-content {
    display: block;
}

.d-header {
    padding-top: 88px !important;
}

(Mike) #5

Any help on this topic?


(Felix Freiberger) #6

This is intentional: Discourse does not load customizations in the admin area to ensure that you can always undo your changes even if a customization breaks the interface.


Custom header elements fail to load