Skip to content

Commit

Permalink
added horizontal transition on mobile @media-query
Browse files Browse the repository at this point in the history
  • Loading branch information
ganesh-deshmukh committed Aug 7, 2018
1 parent 0252748 commit db74046
Show file tree
Hide file tree
Showing 10 changed files with 263 additions and 164 deletions.
Binary file not shown.
Binary file not shown.
Binary file modified .sass-cache/8a167a46b14e7f5344346ab0bec9947b8bba6506/main.scssc
Binary file not shown.
367 changes: 232 additions & 135 deletions dist/css/main.css

Large diffs are not rendered by default.

8 changes: 1 addition & 7 deletions dist/css/main.css.map

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

Binary file added dist/images/portrait-small.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion scss/_config.scss
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ $background-opacity: 0.8;
@content;
}
}
@mixin mediaXL {
@mixin mediaXl {
@media screen and (min-width: 1171px) {
@content;
}
Expand Down
1 change: 1 addition & 0 deletions scss/_menu.scss
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,7 @@
color: $secondary-color;
}
}

.nav-link {
display: inline-block;
position: relative;
Expand Down
48 changes: 27 additions & 21 deletions scss/_mobile.scss
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
// WideScreens
@include mediaXL {
@include mediaXl {
}

// Desktops & Laptops
@include mediaLg {
}
// Tablets and Netbooks

// Tablets & Small Laptops
@include mediaMd {
main {
align-items: center;
Expand All @@ -15,32 +15,38 @@
line-height: 1;
margin-bottom: 1rem;
}
ul.menu-nav,
div.menu-branding {
float: none;
width: 100%;
min-height: 0;

&.show {
transform: translate3d(0, 0, 0);
}
}
}

.menu-nav {
height: 75vh;
transform: translate3d(-100%, 0, 0);
font-size: 24px;
ul.menu-nav,
div.menu-branding {
float: none;
width: 100%;
min-height: 0;

&.show {
transform: translate3d(0, 0, 0);
}
.menu-branding {
height: 25vh;
transform: translate3d(100%, 0, 0);
}

background: url(../dist/images/background.jpg);
.menu-nav {
height: 75vh;
transform: translate3d(-100%, 0, 0);
font-size: 24px;
}

.menu-branding {
height: 25vh;
transform: translate3d(100%, 0, 0);

.portrait {
background: url("../images/portrait-small.jpg");
width: 150px;
height: 150px;
padding: 50px;
}
}
}

// Smartphones
@include mediaSm {
main#home h1 {
Expand Down
1 change: 1 addition & 0 deletions scss/main.scss
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
@import "config";
@import "menu";
@import "mobile";
@import "_mobile.scss";

* {
box-sizing: border-box;
Expand Down

0 comments on commit db74046

Please sign in to comment.