diff --git a/app/assets/stylesheets/my_modules.scss b/app/assets/stylesheets/my_modules.scss index bbb0172b8..cb5c1af77 100644 --- a/app/assets/stylesheets/my_modules.scss +++ b/app/assets/stylesheets/my_modules.scss @@ -1,6 +1,8 @@ // Place all the styles related to the MyModules controller here. // They will automatically be included in application.css. // You can use Sass (SCSS) here: http://sass-lang.com/ +// scss-lint:disable SelectorDepth SelectorFormat +// scss-lint:disable NestingDepth QualifyingElement @import "constants"; @@ -113,3 +115,80 @@ } } } + +// Mobile view +@media (max-width: 700px) { + .task-section { + border-left: 0; + padding-left: 0; + + .task-section-header { + .actions-block { + flex-wrap: wrap; + justify-content: flex-start; + margin-bottom: 5px; + width: 100%; + + .dropdown { + margin-bottom: 5px; + min-width: 100%; + } + } + } + } + + .task-details { + .module-tags { + .dropdown-selector-container { + .input-field { + padding-right: 36px; + } + } + } + + .datetime-container { + .date-text { + margin-right: 0; + } + + .dropdown-menu { + left: -50px !important; + } + } + } + + #steps { + .panel-heading { + flex-wrap: wrap; + } + + .panel-options { + display: flex; + flex-wrap: wrap; + max-width: 100%; + + .complete-step-btn { + width: 100%; + } + } + } + + .attachments { + grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)) !important; + + .attachment-placeholder { + margin: 4px 0 16px; + width: 200px; + } + } + + #filePreviewModal { + .modal-body { + width: 100%; + + .file-preview-container { + width: 90%; + } + } + } +} diff --git a/app/assets/stylesheets/my_modules/protocols/index.scss b/app/assets/stylesheets/my_modules/protocols/index.scss index 214b6a3a5..cd48c65bb 100644 --- a/app/assets/stylesheets/my_modules/protocols/index.scss +++ b/app/assets/stylesheets/my_modules/protocols/index.scss @@ -104,8 +104,8 @@ } } - [data-action="new-step"] { - margin-left: 5px; + .dropdown { + margin-right: 5px; } } } @@ -268,7 +268,7 @@ flex-basis: 100px; flex-grow: 1; flex-shrink: 1; - max-width: calc(100% - 65px); + max-width: 100%; position: relative; z-index: 110; diff --git a/app/assets/stylesheets/steps.scss b/app/assets/stylesheets/steps.scss index ae169f905..8f66e9bb9 100644 --- a/app/assets/stylesheets/steps.scss +++ b/app/assets/stylesheets/steps.scss @@ -46,13 +46,17 @@ .panel-heading { border: 0; - height: 46px; + display: flex; + min-height: 46px; padding-bottom: 0; padding-top: 0; .panel-options { bottom: 0; + flex-grow: 1; + flex-shrink: 0; line-height: 46px; + text-align: right; } span.step-number { @@ -65,7 +69,9 @@ .left-floats { align-items: center; display: flex; - height: 100%; + max-width: 100%; + min-height: inherit; + overflow: hidden; padding-right: 15px; .step-name-link { @@ -299,9 +305,11 @@ .attachments-actions { align-items: center; display: flex; + flex-wrap: wrap; .title { flex-grow: 1; + flex-shrink: 0; } .attachments-order { diff --git a/app/views/my_module_tags/_index_edit.html.erb b/app/views/my_module_tags/_index_edit.html.erb index acb7c1e48..d871f2f71 100644 --- a/app/views/my_module_tags/_index_edit.html.erb +++ b/app/views/my_module_tags/_index_edit.html.erb @@ -7,7 +7,7 @@