Fix styling app and user menu on mobile device
All checks were successful
FarmMaps.Develop/FarmMapsLib/pipeline/head This commit looks good

This commit is contained in:
Willem Dantuma 2021-01-27 10:33:01 +01:00
parent a7402438a0
commit 669c724e3a
3 changed files with 56 additions and 9 deletions

View File

@ -14,16 +14,22 @@ div.menu-button > span {
}
.menu {
max-height: 100vh;
max-height: calc( 100vh - 4rem);
//transition: max-height 0.2s;
overflow: hidden;
box-shadow: 0 0 20px rgba(0,0,0,.3);
position: absolute;
top: 3rem;
right:0;
position: fixed;
top: 3.4rem;
right:0.5rem;
left:0.5rem;
background-color: #fff;
border-radius: 0.25rem;
padding: 0.5rem;
z-index: 3;
}
:host-context(.fullscreen) .menu {
top:4em;
}
.card {
@ -45,4 +51,19 @@ div.menu-button > span {
.menu-button.hidden {
overflow: hidden;
}
}
@media screen and (min-width: 44rem) {
.menu {
position: absolute;
top: 3rem;
right:0;
left: unset;
max-width: 30em;
}
:host-context(.fullscreen) .menu {
top: 3rem;
}
}

View File

@ -18,14 +18,21 @@ div.menu-button > span {
//transition: max-height 0.2s;
overflow: hidden;
box-shadow: 0 0 20px rgba(0,0,0,.3);
position: absolute;
top: 3rem;
right:0;
position: fixed;
top: 3.4rem;
right:0.5rem;
left:0.5rem;
background-color: #fff;
border-radius: 0.25rem;
padding: 0.5rem;
z-index: 3;
}
:host-context(.fullscreen) .menu {
top:4em;
}
.card {
padding:0.5rem;
min-width: 10rem;
@ -52,4 +59,18 @@ div.menu-button > span {
.menu-button.hidden {
overflow: hidden;
}
}
@media screen and (min-width: 44rem) {
.menu {
position: absolute;
top: 3rem;
right:0;
left: unset;
max-width: 30em;
}
:host-context(.fullscreen) .menu {
top: 3rem;
}
}

View File

@ -28,6 +28,11 @@ const routes = [
component: LogoComponent,
outlet: 'header-logo'
},
{
path: '',
component: TestComponent,
outlet: 'app-menu'
},
{
path: '',
component: LogoComponent,