Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix the Communities menu CSS positioning in the plugin #218

Open
tanius opened this issue Oct 2, 2019 · 0 comments
Open

Fix the Communities menu CSS positioning in the plugin #218

tanius opened this issue Oct 2, 2019 · 0 comments
Assignees

Comments

@tanius
Copy link
Member

tanius commented Oct 2, 2019

The recent version of Discourse that we installed on our multisite Discourse instance on 2019-09-30 introduced some template change that makes our current Communities menu CSS (and similarly, that of all menu items in our custom menu bar) no longer applicable. Namely, these menu items will take space away from the main content width, which is mostly noticeable in mobile mode (and only when directly visiting a topic or reloading after visiting a topic).

The best fix seems to be position: absolute on the whole menu bar, taking it out of the usual HTML content flow:

.edgeryders_communities_navigation {
    position: absolute;
    width: 100%;
}

#main-outlet {
    /* Move all page content down by the 30px that an absolutely positioned 
       navbar takes up at the top. */
    padding-top: calc(5.8572em + 30px);
}

nav#bar .wrap {
    position: initial;
}

That fix has been applied on all our sites (multisite instance sites plus edgeryders.eu) via the theme customization admin backend feature already. It now has to be moved to our Communities Navigation plugin. Doing so only needs the first two CSS rule from above, plus removing nav#bar .wrap { position: relative; } which is defined in the plugin right now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants