From d90533399d6edca2e73161642cd090d37c7ac9bf Mon Sep 17 00:00:00 2001 From: Francis Lachapelle Date: Wed, 1 Feb 2017 21:32:16 -0500 Subject: [PATCH] (css) Keep the fab button visible --- NEWS | 1 + .../ContactsUI/UIxContactFoldersView.wox | 50 +++++------ .../MailerUI/UIxMailFolderTemplate.wox | 51 ++++++------ UI/Templates/SchedulerUI/UIxCalMainView.wox | 47 ++++++----- .../scss/components/button/button.scss | 83 +++++++++++++++++-- UI/WebServerResources/scss/core/layout.scss | 22 +++-- .../scss/core/variables.scss | 20 ++--- .../scss/views/SchedulerUI.scss | 37 ++++++++- UI/WebServerResources/scss/views/_view.scss | 12 ++- 9 files changed, 217 insertions(+), 106 deletions(-) diff --git a/NEWS b/NEWS index 8466a96ed..ef3b7e4e3 100644 --- a/NEWS +++ b/NEWS @@ -9,6 +9,7 @@ Bug fixes - [web] ignore mouse events in scrollbars of Month view (#3990) - [web] fixed public URL with special characters (#3993) - [eas] improved EAS parameters parsing (#4003) + - [web] keep the fab button visible when the center list is hidden 3.2.6a (2017-01-26) ------------------- diff --git a/UI/Templates/ContactsUI/UIxContactFoldersView.wox b/UI/Templates/ContactsUI/UIxContactFoldersView.wox index 6b0bad543..37d575156 100644 --- a/UI/Templates/ContactsUI/UIxContactFoldersView.wox +++ b/UI/Templates/ContactsUI/UIxContactFoldersView.wox @@ -501,33 +501,35 @@ md-mode="indeterminate" md-diameter="32"> - - - - add - - - - - - person - - - - group - - - + + + + add + + + + + + person + + + + group + + + +
- - edit - - - - - edit - - - - - - open_in_browser - - - - open_in_new - - - + + + + edit + + + + + + open_in_browser + + + + open_in_new + + + +
- - - - add - - - - - - event - - - - assignment_turned_in - - - + + + + + add + + + + + + event + + + + assignment_turned_in + + + +
- * Slice : xs · sm · md · lg . xl + * |----------------------|----------|----------|-------------|----------> + * Slice : . xs · sm · md · lg . xl * · · · · · * · · · at(md) · · - * · · ├─────────┤ · + * · · |----------| · * · · · · · * · · · from(md) · · - * · · ├───────────────────────────────> - * · · · · - * · · to(md) · · - * ├─────────────────────────────────────────┤ · - * · · - * · between(sm, lg) · - * ├───────────────────────────────┤ + * · · |-----------------------------------> + * · · . · · + * · · . to(md) · · + * |--------------------------------------------| · + * . · . . · + * . · between(sm, lg) · + * . |-----------------------------------| */ $layout-breakpoint-xs: 600px !default; diff --git a/UI/WebServerResources/scss/views/SchedulerUI.scss b/UI/WebServerResources/scss/views/SchedulerUI.scss index f5baeec13..4a4637afa 100644 --- a/UI/WebServerResources/scss/views/SchedulerUI.scss +++ b/UI/WebServerResources/scss/views/SchedulerUI.scss @@ -16,7 +16,8 @@ $quarter_height: 10px; [ui-view=calendars] { // Decrease width of middle column (list of events and tasks) - $listView-width: grid-step(4) !global; + //$listView-width: grid-step(4) !global; + $listView-width: grid-step(4); //$detailView-width: grid-step(10) !global; .view-list { @@ -39,9 +40,37 @@ $quarter_height: 10px; .view-list--close { @include from(md) { - $cols: map-get($base-grid-total-columns, md); - $colWidth: ((100 / $cols) * -5vw); - margin-right: $colWidth; + $colWidth: col-width($breakpoint: md, $nb: 5); + margin-right: $colWidth * -1; + } + } + + /** + * Redefine fab button since center column width is different. + * See button.scss + */ + md-fab-speed-dial.sg-fab-bottom-center { + @include at(md) { + // sidenav is hidden, center list can be closed + right: col-width($breakpoint: md, $nb: 15) + 2vw; + &.sg-center-close { + left: ($button-fab-width - $button-fab-padding)/2; + right: auto; + } + } + @include from(lg) { + // both sidenav and center list can be closed + right: col-width($breakpoint: lg, $nb: 11) + 2vw; + &.sg-sidenav-close { + right: col-width($breakpoint: lg, $nb: 15) + 2vw; + } + &.sg-center-close { + right: col-width($breakpoint: lg, $nb: 14) + 2vw; + } + &.sg-sidenav-close.sg-center-close { + left: ($button-fab-width - $button-fab-padding)/2; + right: auto; + } } } diff --git a/UI/WebServerResources/scss/views/_view.scss b/UI/WebServerResources/scss/views/_view.scss index 312d476ca..4df3a03dc 100644 --- a/UI/WebServerResources/scss/views/_view.scss +++ b/UI/WebServerResources/scss/views/_view.scss @@ -45,7 +45,7 @@ body { // ---------------------------------------------------------------------------- // Variables -$listView-width: grid-step(6) !global; +//$listView-width: grid-step(6) !global; //$detailView-width: grid-step(8) !global; [class|="view"] { @@ -93,14 +93,12 @@ $listView-width: grid-step(6) !global; transform: translateX(-100%); @include at(sm) { - $cols: map-get($base-grid-total-columns, sm); - $colWidth: ((100 / $cols) * -6vw); - margin-right: $colWidth; + $colWidth: col-width($breakpoint: sm, $nb: 6); + margin-right: $colWidth * -1; } @include from(md) { - $cols: map-get($base-grid-total-columns, md); - $colWidth: ((100 / $cols) * -6vw); - margin-right: $colWidth; + $colWidth: col-width($breakpoint: md, $nb: 6); + margin-right: $colWidth * -1; } }