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

Merge/menu header #110

Merged
merged 3 commits into from
Aug 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions themes/osi/assets/css/editor-style.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion themes/osi/assets/css/editor-style.css.map

Large diffs are not rendered by default.

288 changes: 134 additions & 154 deletions themes/osi/assets/scss/_6_components.header.scss
Original file line number Diff line number Diff line change
Expand Up @@ -11,105 +11,131 @@
}
.admin-bar {
.header-main.header-main-small {
top: 46px;
top: 32px;
@media only screen and (max-width: 782px) {
top: 46px;
}
}

}
.header--inner {
padding: 0;
position: static;
opacity: 1;
transition: all .3s;
z-index:999;

@media only screen and ( max-width: 1200px ) {
background: #fff;
}
}

.header--quicklinks {
padding: .5em;
background: $Ndarkest;
position: relative;
overflow: auto;
.header-main {
.header--inner {
position: static;
opacity: 1;
transition: all .3s;
z-index:1000;
}

.header--quicklinks-inner {
position: relative;
}
z-index:999;
height: 125px;
display: flex;
align-items: center;

@media only screen and ( max-width: 1200px ) {
background: #fff;
padding: 16px;
}
@media only screen and (max-width: #{$break-small}) {
padding: 8px 16px;
}

.header--blog-name {
box-sizing: border-box;
height: 100%;
// margin: .3em;
// transition: all .3s;
// width: 80%;

a {
color: $Ndarkest;
display: inline-block;
font-weight: bold;
line-height: 1;
text-decoration: none;
.header--blog-name {
box-sizing: border-box;
max-width: calc(100% - 130px);
max-height: 110px;
height: 100%;
transition: none;

&:hover, &:focus {
display: flex;
align-items: center;

a {
color: $Ndarkest;
display: block;
font-weight: bold;
line-height: 1;
text-decoration: none;
transition: none;

&:hover,
&:focus {
text-decoration: none;
}
}
}

img { // all logos
max-height: 5.4em;
width: auto;
margin: 0 10px 0 auto;
transform: translateZ(0); // chrome blurry fix
}
img {
// all logos
max-width: 300px;
height: auto;
width: 100%;
transform: translateZ(0); // chrome blurry fix
transition: all .3s;
}

.hide-mobile {
display: none;
}
.hide-mobile {
display: none;
}

.header-logo-mobile {
display: block;
.header-logo-mobile {
display: block;
}
}
}

.header--extra-text {
clear: both;
padding: 0 1rem;
&.header-main-small {
.header--inner {
padding-top: 16px;
padding-bottom: 16px;
max-height: 100px;

.header--blog-name {
a {
img {
max-height: 60px;
}
}
}
}
}

.header-main-small {

}

.header--quicklinks {
padding-top: 0;
padding-bottom: 0;
overflow: hidden;
transition: all .3s;
}
.header--quicklinks {
padding: .5em;
background: $Ndarkest;
position: relative;
overflow: auto;
transition: all .3s;
z-index: 1000;
}

.header--inner {
// opacity: 0;
overflow: hidden;
transition: all .3s;
}
.header--quicklinks-inner {
position: relative;
}

.header--blog-name {
.header--extra-text {
clear: both;
padding: 0 1rem;
}

}
.header-main-small {

.header--extra-text {
display: none;
}
.header--quicklinks {
padding-top: 0;
padding-bottom: 0;
overflow: hidden;
transition: all .3s;
}

.header--inner {
// opacity: 0;
overflow: hidden;
transition: all .3s;
}

.header--blog-name {

@media only screen and (min-width: #{$break-small}) {
}

.header--extra-text {
display: none;
}
}

@media only screen and (max-width: #{$break-nav}) {
Expand All @@ -121,102 +147,56 @@
}

@media only screen and (min-width: #{$break-nav}) {
.header-main {
.header--inner, .header--quicklinks-inner {
// @include clearfix();
padding-left: $maxPadding;
padding-right: $maxPadding;
padding-top: 1em;
}

.header--inner, .header--quicklinks-inner {
@include clearfix();
padding-left: $maxPadding;
padding-right: $maxPadding;
padding-top: 1em;
.header--inner {
border: 0;
position: relative;
}
.header--blog-name {
.hide-mobile {
display: inline-block;
}

.header--inner {
border: 0;
position: relative;
.header-logo-mobile {
display: none;
}
.header--blog-name {
// float: left;
// font-size: 1.2em;
// margin: 0;
// padding-left: 0;
// text-align: left;
// width: inherit;

.header-logo {
display: inline-block;
}

.hide-mobile {
display: inline-block;
}

.header-logo-mobile {
display: none;
}

img {
margin-top: -16px;
}
}

.header--extra-text {
text-align: right;
float: right;
clear: right;
padding: 0;
}

.header-main-small {
background-color: $Nwhite;

.header--inner {
// height: 2.2em;
// overflow: visible;
// top: 0;
// opacity: 1;
}
}

.header--blog-name {
display: none;
opacity: 0;
}
.header--extra-text {
text-align: right;
float: right;
clear: right;
padding: 0;
}

.nav-main {
height: auto;
top: 0;
// transition: all .2s;
margin-top: 0;

.nav-main--menu > .menu-item > a {
padding-top: 0.6em;
padding-bottom: 0.5em;
transition: all .3s;
}
.header-main-small {
background-color: $Nwhite;

.nav-main {
height: auto;
top: 0;
// transition: all .2s;
margin-top: 0;

.nav-main--menu > .menu-item > a {
padding-top: 0.6em;
padding-bottom: 0.5em;
transition: all .3s;
}
}
}
}



@media only screen and (min-width: #{$break-wide}) {
.header--inner, .header--quicklinks-inner {
// @include center-block;
display: flex;
align-items: center;

}

.header-main-small {

.header--blog-name {
// display: inline-block;

img {
margin-top: -16px;
}

}

}
}
24 changes: 16 additions & 8 deletions themes/osi/assets/scss/_6_components.mobile-menu.scss
Original file line number Diff line number Diff line change
@@ -1,9 +1,17 @@
.open-button-wrapper {
position: absolute;
// top: $quicklinksTop; // height of quicklinks
// top: 0;
top: 7px;
width: 100%;
.site-header {
.open-button-wrapper {
position: absolute;
// top: $quicklinksTop; // height of quicklinks
// top: 0;
top: 35px;
right: 16px;
}

&.header-main-small {
.open-button-wrapper {
top: 25px;
}
}
}

.open-the-menu {
Expand All @@ -23,12 +31,12 @@
border: 0;
border-radius: 0 !important;
font-size: 1em;
height: 2.8em;
height: 48px;
overflow: hidden;
padding: .4em;
position: absolute;
top: 0;
width: 2.5em;
width: 44px;
z-index: 1000;

&:active,
Expand Down
Loading
Loading