Archived topic
TopBar mofify width-content in tablet mode
10 replies · Started by cpalo on January 6, 2021
http://generatepress.simplepress.fr/
In tablet mode, I would like the two widgets to be also on the left and right edges and not centered.
/* Alignemement non centré en mode mobile */
@media (min-width: 397px) and (max-width: 768px) {
.top-bar .inside-top-bar {
justify-content: unset;
}
.top-bar.top-bar-align-right .widget:first-child {
margin-left: auto;
}
.top-bar.top-bar-align-left .widget:first-child {
margin-right: auto;
}
}
/* Inversion en mode tablette */
@media (min-width: 769px) and (max-width: 1024px) {
.top-bar .inside-top-bar {
flex-direction: row-reverse;
}
.top-bar.top-bar-align-left .widget:first-child {
margin-left: auto;
}
.top-bar.top-bar-align-left .widget:first-child {
margin-right: auto;
}
}
/* Inversion en mode tablette */
@media (min-width: 769px) and (max-width: 1024px) {
.top-bar .inside-top-bar {
flex-direction: row-reverse;
}
.top-bar.top-bar-align-left .widget:first-child {
margin-left: auto;
}
.top-bar.top-bar-align-right .widget:first-child {
margin-right: auto;
}
}
Hi there,
can you share a link to your site?
I put it at the beginning of the post.
Sorry i missed that - do you want the order of the widgets to change on tablet ?
do you want the order of the widgets to change on tablet ? It's was a test (another post) who sould used for another site.
It's OK now.
On the other hand, since the title is long, in mobile mode the hamburger menu goes below.
How to make it stay in its place, the logo on the right and the title centered below.
It would require some CSS like this:
@media(max-width: 768px) {
.site-branding-container {
flex-direction: column;
}
.main-title {
font-size: 12px;
margin-top: 10px;
}
.site-logo {
max-width: 120px;
align-self: flex-start;
}
}
And you can reduce the Mobile Padding for the Site Header in Customizer > Layout > Header.
It's OK. Thanks
Is it possible to change the size of logo on mobile mode?
Updated the CSS here:
https://generatepress.com/forums/topic/topbar-mofify-width-content-in-tablet-mode/#post-1608232
Now includes sizing for site logo
Thanks Good Evening
You're welcome