Amended page save button layout to fix z-index issues

- Added a new mobile save button instead of trying to reposition the
original.
- Also recuced the point where the editor top toolbar will collapse to
become x-scrollable.

Fixes #1424
This commit is contained in:
Dan Brown 2019-05-19 15:30:58 +01:00
parent 0c3dc50cd9
commit e1e1ea6099
No known key found for this signature in database
GPG Key ID: 46D9F943C24A2EF9
3 changed files with 22 additions and 24 deletions

View File

@ -59,7 +59,7 @@
}
@include smaller-than($m) {
.grid.third {
.grid.third:not(.no-break) {
grid-template-columns: 1fr 1fr;
}
.grid.half:not(.no-break), .grid.left-focus:not(.no-break), .grid.right-focus:not(.no-break) {
@ -81,7 +81,7 @@
}
@include smaller-than($s) {
.grid.third {
.grid.third:not(.no-break) {
grid-template-columns: 1fr;
}
}

View File

@ -20,11 +20,10 @@
}
}
@include smaller-than($m) {
@include smaller-than($s) {
.page-edit-toolbar {
overflow-x: scroll;
overflow-y: visible;
z-index: 12;
}
.page-edit-toolbar .grid.third {
display: block;
@ -35,24 +34,21 @@
}
}
@include smaller-than($m) {
.page-edit-toolbar #save-button {
position: fixed;
z-index: 30;
border-radius: 50%;
width: 56px;
height: 56px;
font-size: 24px;
right: $-m;
bottom: $-s;
box-shadow: $bs-hover;
background-color: currentColor;
svg {
fill: #FFF;
}
span {
display: none;
}
.page-save-mobile-button {
position: fixed;
z-index: 30;
border-radius: 50%;
width: 56px;
height: 56px;
font-size: 24px;
right: $-m;
bottom: $-s;
box-shadow: $bs-hover;
background-color: currentColor;
text-align: center;
svg {
fill: #FFF;
margin-right: 0;
}
}

View File

@ -12,7 +12,7 @@
{{--Header Bar--}}
<div class="primary-background-light toolbar page-edit-toolbar">
<div class="grid third v-center">
<div class="grid third no-break v-center">
<div class="action-buttons text-left px-m py-xs">
<a href="{{ back()->getTargetUrl() }}" class="text-button text-primary">@icon('back')<span class="hide-under-l">{{ trans('common.back') }}</span></a>
@ -49,7 +49,7 @@
<span>{{-- Prevents button jumping on menu show --}}</span>
</div>
<button type="submit" id="save-button" class="float-left text-primary text-button text-pos-hover">@icon('save')<span>{{ trans('entities.pages_save') }}</span></button>
<button type="submit" id="save-button" class="float-left text-primary text-button text-pos-hover hide-under-m">@icon('save')<span>{{ trans('entities.pages_save') }}</span></button>
</div>
</div>
</div>
@ -120,4 +120,6 @@
@endif
</div>
<button type="submit" id="save-button-mobile" title="{{ trans('entities.pages_save') }}" class="text-primary text-button hide-over-m page-save-mobile-button">@icon('save')</button>
</div>