From 884e4e80574371568b3efdfaeb5178c1a314676c Mon Sep 17 00:00:00 2001 From: Chris Heathcote Date: Fri, 8 Jan 2016 15:53:57 +0000 Subject: [PATCH 1/8] Added in bar containing service name, user name/link to profile and sign out --- .../stylesheets/components/navigation.scss | 2 +- .../stylesheets/components/switcher.scss | 43 +++++++++++++++++++ app/assets/stylesheets/main.scss | 1 + app/templates/admin_template.html | 10 ++--- app/templates/main_nav.html | 7 ++- 5 files changed, 51 insertions(+), 12 deletions(-) create mode 100644 app/assets/stylesheets/components/switcher.scss diff --git a/app/assets/stylesheets/components/navigation.scss b/app/assets/stylesheets/components/navigation.scss index 5e462cd03..427eb85d7 100644 --- a/app/assets/stylesheets/components/navigation.scss +++ b/app/assets/stylesheets/components/navigation.scss @@ -1,6 +1,6 @@ .navigation { - padding: $gutter 0 0 0; + padding: $gutter-half 0 0 0; li { @include core-16(); diff --git a/app/assets/stylesheets/components/switcher.scss b/app/assets/stylesheets/components/switcher.scss new file mode 100644 index 000000000..9ee6dc26d --- /dev/null +++ b/app/assets/stylesheets/components/switcher.scss @@ -0,0 +1,43 @@ + +#user-bar { + border-bottom: 1px solid #bfc1c3; + max-width: 960px; + margin: 0 15px; + @include core-19(); + padding: 10px 0 8px 0; + + a:link, + a:visited { + text-decoration: none; + } + + span a:hover { + color: $link-hover-colour; + } + + } + @media (min-width: 641px) { + #user-bar { + margin: 0 30px; + line-height: 1.25; } } + @media (min-width: 1020px) { + #user-bar { + margin: 0 auto; } } + + +#service-switcher { +} + +#user-name { + + margin: 0 20px 0 0; +} + +#user-admin { + +} +@media (min-width: 641px) { + #user-admin { + display: block; + float: right; + } } \ No newline at end of file diff --git a/app/assets/stylesheets/main.scss b/app/assets/stylesheets/main.scss index bcd47c542..22f9f2f0e 100644 --- a/app/assets/stylesheets/main.scss +++ b/app/assets/stylesheets/main.scss @@ -42,6 +42,7 @@ @import 'components/banner'; @import 'components/textbox'; @import 'components/browse-list'; +@import 'components/switcher'; @import 'views/job'; diff --git a/app/templates/admin_template.html b/app/templates/admin_template.html index c127da3f7..7681d9d47 100644 --- a/app/templates/admin_template.html +++ b/app/templates/admin_template.html @@ -31,13 +31,6 @@
BETA
- {% if current_user.is_authenticated() %} - - {% endif %} {% endblock %} @@ -53,6 +46,9 @@ {% endif %} {% block content %} +{% if current_user.is_authenticated() %} + +{% endif %}
{% with messages = get_flashed_messages() %} {% if messages %} diff --git a/app/templates/main_nav.html b/app/templates/main_nav.html index 3fab88acb..feb59a310 100644 --- a/app/templates/main_nav.html +++ b/app/templates/main_nav.html @@ -1,5 +1,7 @@ From 6645f23def8e37a1e47bbe741946e3569e182f22 Mon Sep 17 00:00:00 2001 From: Chris Heathcote Date: Fri, 8 Jan 2016 15:57:07 +0000 Subject: [PATCH 2/8] Remove dashboard title --- app/assets/stylesheets/views/job.scss | 1 + app/templates/views/dashboard.html | 2 -- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/app/assets/stylesheets/views/job.scss b/app/assets/stylesheets/views/job.scss index 35d54e57d..b2984e864 100644 --- a/app/assets/stylesheets/views/job.scss +++ b/app/assets/stylesheets/views/job.scss @@ -1,3 +1,4 @@ .job-totals { + margin-top: $gutter; margin-bottom: $gutter; } diff --git a/app/templates/views/dashboard.html b/app/templates/views/dashboard.html index 4049689e4..ba22e7414 100644 --- a/app/templates/views/dashboard.html +++ b/app/templates/views/dashboard.html @@ -8,8 +8,6 @@ {% block maincolumn_content %} -

Service name

-
  • {{ big_number( From 8dbf266e87b803cfe54bcf06bc74b9bab218aa41 Mon Sep 17 00:00:00 2001 From: Chris Heathcote Date: Mon, 11 Jan 2016 15:53:50 +0000 Subject: [PATCH 3/8] Design showing opened service switcher --- .../stylesheets/components/navigation.scss | 2 +- .../stylesheets/components/switcher.scss | 30 +++++++++++++++++-- app/templates/admin_template.html | 17 ++++++++++- 3 files changed, 44 insertions(+), 5 deletions(-) diff --git a/app/assets/stylesheets/components/navigation.scss b/app/assets/stylesheets/components/navigation.scss index 427eb85d7..da8defe3f 100644 --- a/app/assets/stylesheets/components/navigation.scss +++ b/app/assets/stylesheets/components/navigation.scss @@ -1,6 +1,6 @@ .navigation { - padding: $gutter-half 0 0 0; + padding: 3px 0 0 0; li { @include core-16(); diff --git a/app/assets/stylesheets/components/switcher.scss b/app/assets/stylesheets/components/switcher.scss index 9ee6dc26d..89399c34d 100644 --- a/app/assets/stylesheets/components/switcher.scss +++ b/app/assets/stylesheets/components/switcher.scss @@ -29,15 +29,39 @@ } #user-name { - margin: 0 20px 0 0; } #user-admin { - } @media (min-width: 641px) { #user-admin { display: block; float: right; - } } \ No newline at end of file + } } + + +#service-nav { + // display: none; + @include core-19(); + list-style: none; + ul li { + display: block;position: relative;float: left; + } + +} + +#service-arrow-right { + display:none; +} + + + + + + + + + + + diff --git a/app/templates/admin_template.html b/app/templates/admin_template.html index 7681d9d47..0d51ea891 100644 --- a/app/templates/admin_template.html +++ b/app/templates/admin_template.html @@ -47,7 +47,22 @@ {% block content %} {% if current_user.is_authenticated() %} - +
+ + + + + {% endif %}
{% with messages = get_flashed_messages() %} From 7be32be70d8480eb4dafdd8c0f853f997240f87a Mon Sep 17 00:00:00 2001 From: Chris Hill-Scott Date: Mon, 11 Jan 2016 16:01:39 +0000 Subject: [PATCH 4/8] Fix code whitespace As a separate commit for easier diffing --- app/templates/admin_template.html | 51 ++++++++++++++++--------------- 1 file changed, 27 insertions(+), 24 deletions(-) diff --git a/app/templates/admin_template.html b/app/templates/admin_template.html index 0d51ea891..ed9d4f00e 100644 --- a/app/templates/admin_template.html +++ b/app/templates/admin_template.html @@ -46,38 +46,41 @@ {% endif %} {% block content %} -{% if current_user.is_authenticated() %} + + {% if current_user.is_authenticated() %} +
  • Switch to A N Other service
  • +
  • Add a new service to Notify
  • + + + {% endif %} -{% endif %} -
    - {% with messages = get_flashed_messages() %} - {% if messages %} -
    -
      - {% for message in messages %} -
    • {{ message }}
    • - {% endfor %} -
    -
    - {% endif %} - {% endwith %} - {% block fullwidth_content %}{% endblock %} -
    +
    + {% with messages = get_flashed_messages() %} + {% if messages %} +
    +
      + {% for message in messages %} +
    • {{ message }}
    • + {% endfor %} +
    +
    + {% endif %} + {% endwith %} + {% block fullwidth_content %}{% endblock %} +
    {% endblock %} {% block body_end %} From 934ce51f2c8ad7747479c68035b4493d2e97f7d3 Mon Sep 17 00:00:00 2001 From: Chris Hill-Scott Date: Mon, 11 Jan 2016 16:02:39 +0000 Subject: [PATCH 5/8] =?UTF-8?q?Use=20user=E2=80=99s=20real=20name,=20not?= =?UTF-8?q?=20a=20placeholder?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/templates/admin_template.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/templates/admin_template.html b/app/templates/admin_template.html index ed9d4f00e..c7149bb59 100644 --- a/app/templates/admin_template.html +++ b/app/templates/admin_template.html @@ -53,11 +53,11 @@ - Service name goes here + Service name
      From 732efd25c7a1ff3ecb41ae3c0059a75a75c476c1 Mon Sep 17 00:00:00 2001 From: Chris Hill-Scott Date: Mon, 11 Jan 2016 16:20:32 +0000 Subject: [PATCH 6/8] Refactor markup MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Strips it down to only what’s necessary As a separate commit for easier diffing. --- .../stylesheets/components/switcher.scss | 70 ++++--------------- app/templates/admin_template.html | 24 +++---- 2 files changed, 25 insertions(+), 69 deletions(-) diff --git a/app/assets/stylesheets/components/switcher.scss b/app/assets/stylesheets/components/switcher.scss index 89399c34d..72817edff 100644 --- a/app/assets/stylesheets/components/switcher.scss +++ b/app/assets/stylesheets/components/switcher.scss @@ -1,67 +1,27 @@ +.management-navigation { -#user-bar { - border-bottom: 1px solid #bfc1c3; - max-width: 960px; - margin: 0 15px; + @extend %site-width-container; @include core-19(); - padding: 10px 0 8px 0; + border-bottom: 1px solid $border-colour; + padding: 10px 0 8px; a:link, a:visited { text-decoration: none; } - span a:hover { - color: $link-hover-colour; - } + &-account { + + @include media(tablet) { + + text-align: right; + + a { + margin-left: 20px; + } + + } } - @media (min-width: 641px) { - #user-bar { - margin: 0 30px; - line-height: 1.25; } } - @media (min-width: 1020px) { - #user-bar { - margin: 0 auto; } } - - -#service-switcher { -} - -#user-name { - margin: 0 20px 0 0; -} - -#user-admin { -} -@media (min-width: 641px) { - #user-admin { - display: block; - float: right; - } } - - -#service-nav { - // display: none; - @include core-19(); - list-style: none; - ul li { - display: block;position: relative;float: left; - } } - -#service-arrow-right { - display:none; -} - - - - - - - - - - - diff --git a/app/templates/admin_template.html b/app/templates/admin_template.html index c7149bb59..5e91e6cb1 100644 --- a/app/templates/admin_template.html +++ b/app/templates/admin_template.html @@ -48,22 +48,18 @@ {% block content %} {% if current_user.is_authenticated() %} -