diff --git a/src/definitions/modules/modal.less b/src/definitions/modules/modal.less index 7f89684ca..8a913abeb 100755 --- a/src/definitions/modules/modal.less +++ b/src/definitions/modules/modal.less @@ -214,6 +214,9 @@ } /* Tablet and Mobile */ @media only screen and (max-width : @computerBreakpoint) { + .ui.modal > .header { + padding-right: @closeHitbox; + } .ui.modal > .close { top: @innerCloseTop; right: @innerCloseRight; @@ -256,15 +259,23 @@ } .ui.scrolling.dimmable.dimmed > .dimmer { overflow: auto; + -webkit-overflow-scrolling: touch; } .ui.scrolling.dimmable > .dimmer { position: fixed; } -.ui.modal.scrolling { +.ui.scrolling.modal { position: static; margin: @scrollingMargin auto; } +@media only screen and (max-width : @computerBreakpoint) { + .ui.scrolling.modal { + margin-top: @mobileScrollingMargin; + margin-bottom: @mobileScrollingMargin; + } +} + /******************************* States *******************************/ @@ -285,11 +296,24 @@ width: @fullScreenWidth !important; margin: @fullScreenMargin; } +.ui.fullscreen.modal > .header { + padding-right: @closeHitbox; +} .ui.fullscreen.modal > .close { top: @innerCloseTop; right: @innerCloseRight; color: @innerCloseColor; } + +@media only screen and (max-width : (@tabletBreakpoint - 1px)) { + .ui.fullscreen.modal { + width: auto !important; + margin: @fullScreenMobileMargin !important; + top: 0% !important; + left: 0% !important; + } +} + /*-------------- Size ---------------*/ diff --git a/src/themes/packages/default/modules/modal.variables b/src/themes/packages/default/modules/modal.variables index ae4c1dea0..8c3729b98 100755 --- a/src/themes/packages/default/modules/modal.variables +++ b/src/themes/packages/default/modules/modal.variables @@ -78,8 +78,8 @@ @widescreenMonitorMargin: 0em 0em 0em -(@widescreenMonitorWidth / 2); @fullScreenWidth: 95%; -@fullScreenMargin: @scrollingMargin 0em @scrollingMargin -(@fullScreenWidth / 2); - +@fullScreenMargin: 1em 0em 1em -(@fullScreenWidth / 2); +@fullScreenMobileMargin: 1em; /*------------------- Types @@ -92,14 +92,15 @@ @basicModalCloseRight: 1rem; /* Scrolling Margin */ -@scrollingMargin: 3rem; +@scrollingMargin: 3.5rem; +@mobileScrollingMargin: 1rem; /*------------------- Variations --------------------*/ -/* Sizes */ +/* Size Widths */ @smallRatio: 0.6; @largeRatio: 1.2;