Tagged: x
-
AuthorPosts
-
July 14, 2016 at 9:22 am #1086848
3b1a2f46-a516-40cf-beba-b611930e4819ParticipantHi guys,
I have a transparent header which is fixed top.
The problem is once we scroll down the page the navigation cannot be seen unless the background is dark. This is not the case with parts of the pages.
So I was wondering if it can change from transparent to #292929 when we start scrolling down?
It is also a problem on mobile menu so the dropdown would need the same background colour also.
Login to follow..
July 14, 2016 at 9:23 am #1086849
3b1a2f46-a516-40cf-beba-b611930e4819ParticipantThis reply has been marked as private.July 14, 2016 at 11:11 am #1087008
RupokMemberHi there,
Thanks for writing in! You can add this under Custom > CSS in the Customizer.
.x-navbar.x-navbar-fixed-top { background: #292929; } @media only screen and (max-width: 979px) { .x-navbar { background: #292929; } }Hope this helps.
Cheers!
July 15, 2016 at 3:46 am #1088214
3b1a2f46-a516-40cf-beba-b611930e4819ParticipantThat’s great, is it possible to add some transparency? Say 80%?
thanks
July 15, 2016 at 7:56 am #1088430
JoaoModeratorHi There,
Change the color from #292929; to rgba(41,41,41,0.8);
Hope that helps
Joao
July 20, 2016 at 11:03 am #1095471
3b1a2f46-a516-40cf-beba-b611930e4819ParticipantThis is great – but can it stay transparent on tablet (and smaller) until the burger menu icon is pressed to open the menu?
thanks
July 20, 2016 at 1:36 pm #1095731
RupokMemberHi there,
Thanks for writing back. Yes if you add the transparent background within media query :
.x-navbar.x-navbar-fixed-top { background: #292929; } @media only screen and (max-width: 979px) { .x-navbar { background: rgba(41,41,41,0.8); } }Hope this helps.
July 21, 2016 at 5:04 am #1096782
3b1a2f46-a516-40cf-beba-b611930e4819ParticipantSorry that doesn’t seem to have done anything – I have left the code in
thanks
July 21, 2016 at 6:06 am #1096854
Paul RModeratorHi,
Kindly replace the code provided above with this
.x-navbar.x-navbar-fixed-top { background: #292929; } @media only screen and (max-width: 979px) { body .x-navbar { background:transparent; } body .x-navbar.x-navbar-solid { background: rgba(41,41,41,0.8); } }Then add this in Custom > Edit Global Javascript in the customizer
jQuery(function($) { $('.x-navbar').toggleClass('x-navbar-solid'); });Hope that helps.
July 21, 2016 at 8:57 am #1097034
3b1a2f46-a516-40cf-beba-b611930e4819ParticipantHi,
The custom CSS made it transparent and then the javascript turned it back again?
I have left the code in
thanks
July 21, 2016 at 11:00 am #1097201
Nabeel AModeratorHi again,
Try adding the following code in Custom > Edit Global CSS
@media only screen and (max-width: 979px) { body .x-navbar.x-navbar-solid { background: transparent; } } .x-navbar-bg-color { background: rgba(41,41,41,0.8) !important; }Then add this in Custom > Edit Global Javascript in the Customizer
jQuery(function($) { $('.x-btn-navbar').click(function(){ $('.x-navbar').toggleClass('x-navbar-bg-color'); }); });Don’t forget to clear your browser’s cache after adding the code. Let us know how this goes!
-
AuthorPosts
- <script> jQuery(function($){ $("#no-reply-1086848 .bbp-template-notice, .bbp-no-topic .bbp-template-notice").removeClass('bbp-template-notice'); }); </script>
