From 14b4e5aeec1792b58d093a3a732968bcbc22b26a Mon Sep 17 00:00:00 2001 From: Benjamin Gamard Date: Fri, 3 Nov 2017 00:10:17 +0100 Subject: [PATCH] design refresh --- .../docs/rest/resource/ThemeResource.java | 4 +-- docs-web/src/main/webapp/src/index.html | 2 +- .../webapp/src/partial/docs/document.html | 2 +- .../src/partial/docs/settings.group.html | 2 +- .../webapp/src/partial/docs/settings.log.html | 2 +- .../src/partial/docs/settings.session.html | 2 +- .../src/partial/docs/settings.user.html | 2 +- .../src/partial/docs/settings.vocabulary.html | 2 +- .../src/main/webapp/src/partial/docs/tag.html | 2 +- .../webapp/src/partial/docs/usergroup.html | 4 +-- .../src/main/webapp/src/style/bootstrap.css | 27 ++++++++++--------- docs-web/src/main/webapp/src/style/main.less | 3 ++- .../sismics/docs/rest/TestThemeResource.java | 4 +-- 13 files changed, 30 insertions(+), 28 deletions(-) diff --git a/docs-web/src/main/java/com/sismics/docs/rest/resource/ThemeResource.java b/docs-web/src/main/java/com/sismics/docs/rest/resource/ThemeResource.java index dbd7bd15..66f2c620 100644 --- a/docs-web/src/main/java/com/sismics/docs/rest/resource/ThemeResource.java +++ b/docs-web/src/main/java/com/sismics/docs/rest/resource/ThemeResource.java @@ -58,7 +58,7 @@ public class ThemeResource extends BaseResource { // Build the stylesheet StringBuilder sb = new StringBuilder(); sb.append(new Selector(".navbar") - .rule("background-color", themeConfig.getString("color", "#263238"))); + .rule("background-color", themeConfig.getString("color", "#24292e"))); sb.append(themeConfig.getString("css", "")); return Response.ok().entity(sb.toString()).build(); @@ -83,7 +83,7 @@ public class ThemeResource extends BaseResource { JsonObject themeConfig = getThemeConfig(); JsonObjectBuilder json = Json.createObjectBuilder(); json.add("name", themeConfig.getString("name", "Sismics Docs")); - json.add("color", themeConfig.getString("color", "#263238")); + json.add("color", themeConfig.getString("color", "#24292e")); json.add("css", themeConfig.getString("css", "")); return Response.ok().entity(json.build()).build(); } diff --git a/docs-web/src/main/webapp/src/index.html b/docs-web/src/main/webapp/src/index.html index 85dc910a..1c4cc18a 100644 --- a/docs-web/src/main/webapp/src/index.html +++ b/docs-web/src/main/webapp/src/index.html @@ -114,7 +114,7 @@
  • {{ 'index.nav_tags' | translate }}
  • -
  • +
  • {{ 'index.nav_users_groups' | translate }}
  • diff --git a/docs-web/src/main/webapp/src/partial/docs/document.html b/docs-web/src/main/webapp/src/partial/docs/document.html index a02c7c0a..f102a0e2 100644 --- a/docs-web/src/main/webapp/src/partial/docs/document.html +++ b/docs-web/src/main/webapp/src/partial/docs/document.html @@ -37,7 +37,7 @@ - +
    diff --git a/docs-web/src/main/webapp/src/partial/docs/settings.group.html b/docs-web/src/main/webapp/src/partial/docs/settings.group.html index 89d85927..8d324be2 100644 --- a/docs-web/src/main/webapp/src/partial/docs/settings.group.html +++ b/docs-web/src/main/webapp/src/partial/docs/settings.group.html @@ -5,7 +5,7 @@
    -
    {{ 'document.title' | translate }}
    +
    diff --git a/docs-web/src/main/webapp/src/partial/docs/settings.log.html b/docs-web/src/main/webapp/src/partial/docs/settings.log.html index f6843bed..a417918f 100644 --- a/docs-web/src/main/webapp/src/partial/docs/settings.log.html +++ b/docs-web/src/main/webapp/src/partial/docs/settings.log.html @@ -1,5 +1,5 @@

    -
    {{ 'settings.group.name' | translate }}
    +
    diff --git a/docs-web/src/main/webapp/src/partial/docs/settings.session.html b/docs-web/src/main/webapp/src/partial/docs/settings.session.html index e7da00d7..9790506d 100644 --- a/docs-web/src/main/webapp/src/partial/docs/settings.session.html +++ b/docs-web/src/main/webapp/src/partial/docs/settings.session.html @@ -1,5 +1,5 @@

    -
    {{ 'settings.log.date' | translate }}
    +
    diff --git a/docs-web/src/main/webapp/src/partial/docs/settings.user.html b/docs-web/src/main/webapp/src/partial/docs/settings.user.html index e0a9fb64..7a90def5 100644 --- a/docs-web/src/main/webapp/src/partial/docs/settings.user.html +++ b/docs-web/src/main/webapp/src/partial/docs/settings.user.html @@ -5,7 +5,7 @@
    -
    {{ 'settings.session.created_date' | translate }}
    +
    diff --git a/docs-web/src/main/webapp/src/partial/docs/settings.vocabulary.html b/docs-web/src/main/webapp/src/partial/docs/settings.vocabulary.html index 9bc60aa1..17f0e6a3 100644 --- a/docs-web/src/main/webapp/src/partial/docs/settings.vocabulary.html +++ b/docs-web/src/main/webapp/src/partial/docs/settings.vocabulary.html @@ -12,7 +12,7 @@ -
    {{ 'settings.user.username' | translate }}
    +
    diff --git a/docs-web/src/main/webapp/src/partial/docs/tag.html b/docs-web/src/main/webapp/src/partial/docs/tag.html index 17c2f6b3..f6968136 100644 --- a/docs-web/src/main/webapp/src/partial/docs/tag.html +++ b/docs-web/src/main/webapp/src/partial/docs/tag.html @@ -16,7 +16,7 @@

    -
    {{ 'settings.vocabulary.value' | translate }}
    +
    diff --git a/docs-web/src/main/webapp/src/partial/docs/usergroup.html b/docs-web/src/main/webapp/src/partial/docs/usergroup.html index 1f169664..7d0865f6 100644 --- a/docs-web/src/main/webapp/src/partial/docs/usergroup.html +++ b/docs-web/src/main/webapp/src/partial/docs/usergroup.html @@ -6,7 +6,7 @@

    -
    +
    @@ -24,7 +24,7 @@

    -
    +
    diff --git a/docs-web/src/main/webapp/src/style/bootstrap.css b/docs-web/src/main/webapp/src/style/bootstrap.css index f70c302e..9197e2c0 100644 --- a/docs-web/src/main/webapp/src/style/bootstrap.css +++ b/docs-web/src/main/webapp/src/style/bootstrap.css @@ -1082,7 +1082,7 @@ html { -webkit-tap-highlight-color: rgba(0, 0, 0, 0); } body { - font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; + font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol"; font-size: 14px; line-height: 1.42857143; color: #333; @@ -1181,7 +1181,7 @@ h6, .h5, .h6 { font-family: inherit; - font-weight: 500; + font-weight: normal; line-height: 1.1; color: inherit; } @@ -1209,9 +1209,9 @@ h6 .small, .h4 .small, .h5 .small, .h6 .small { - font-weight: normal; + font-weight: 300; line-height: 1; - color: #777; + color: #a3aab1; } h1, .h1, @@ -2558,6 +2558,7 @@ output { .form-control:focus { border-color: #66afe9; outline: 0; + box-shadow: inset 0 1px 2px rgba(27,31,35,0.075), 0 0 0 0.2em rgba(3,102,214,0.3); } .form-control::-moz-placeholder { color: #999; @@ -2874,8 +2875,7 @@ select[multiple].input-lg { } .has-error .form-control:focus { border-color: #843534; - -webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075), 0 0 6px #ce8483; - box-shadow: inset 0 1px 1px rgba(0, 0, 0, .075), 0 0 6px #ce8483; + box-shadow: inset 0 1px 2px rgba(27,31,35,0.075), 0 0 0 0.2em #ce8483; } .has-error .input-group-addon { color: #a94442; @@ -3946,7 +3946,6 @@ select[multiple].input-group-sm > .input-group-btn > .btn { .nav > li > a:hover, .nav > li > a:focus { text-decoration: none; - background-color: #eee; } .nav > li.disabled > a { color: #777; @@ -3984,18 +3983,20 @@ select[multiple].input-group-sm > .input-group-btn > .btn { margin-right: 2px; line-height: 1.42857143; border: 1px solid transparent; + color: #586069; } .nav-tabs > li > a:hover { - border-color: #eee #eee #ddd; + color: #24292e; } .nav-tabs > li.active > a, .nav-tabs > li.active > a:hover, .nav-tabs > li.active > a:focus { - color: #555; + color: #24292e; cursor: default; background-color: #fff; border: 1px solid #ddd; border-bottom-color: transparent; + border-top: 3px solid #e36209; } .nav-tabs.nav-justified { width: 100%; @@ -4535,7 +4536,8 @@ fieldset[disabled] .navbar-default .btn-link:focus { color: #9d9d9d; } .navbar-inverse .navbar-nav > li > a { - color: #9d9d9d; + color: rgba(255,255,255,0.75); + font-weight: bold; } .navbar-inverse .navbar-nav > li > a:hover, .navbar-inverse .navbar-nav > li > a:focus { @@ -4546,7 +4548,6 @@ fieldset[disabled] .navbar-default .btn-link:focus { .navbar-inverse .navbar-nav > .active > a:hover, .navbar-inverse .navbar-nav > .active > a:focus { color: #fff; - background-color: #080808; } .navbar-inverse .navbar-nav > .disabled > a, .navbar-inverse .navbar-nav > .disabled > a:hover, @@ -5897,7 +5898,7 @@ button.close { position: absolute; z-index: 1070; display: block; - font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; + font-family: inherit; font-size: 12px; font-style: normal; font-weight: normal; @@ -6015,7 +6016,7 @@ button.close { display: none; max-width: 276px; padding: 1px; - font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; + font-family: inherit; font-size: 14px; font-style: normal; font-weight: normal; diff --git a/docs-web/src/main/webapp/src/style/main.less b/docs-web/src/main/webapp/src/style/main.less index 652397f6..4a8c7a7e 100644 --- a/docs-web/src/main/webapp/src/style/main.less +++ b/docs-web/src/main/webapp/src/style/main.less @@ -9,7 +9,7 @@ // Navbar color .navbar { - background-color: #263238; + background-color: #24292e; } // Selected table line @@ -309,3 +309,4 @@ input[readonly].share-link { right: 0; z-index: 99999; } + diff --git a/docs-web/src/test/java/com/sismics/docs/rest/TestThemeResource.java b/docs-web/src/test/java/com/sismics/docs/rest/TestThemeResource.java index 25e47a14..ba4a5908 100644 --- a/docs-web/src/test/java/com/sismics/docs/rest/TestThemeResource.java +++ b/docs-web/src/test/java/com/sismics/docs/rest/TestThemeResource.java @@ -32,13 +32,13 @@ public class TestThemeResource extends BaseJerseyTest { // Get the stylesheet anonymously String stylesheet = target().path("/theme/stylesheet").request() .get(String.class); - Assert.assertTrue(stylesheet.contains("background-color: #263238;")); + Assert.assertTrue(stylesheet.contains("background-color: #24292e;")); // Get the theme configuration anonymously JsonObject json = target().path("/theme").request() .get(JsonObject.class); Assert.assertEquals("Sismics Docs", json.getString("name")); - Assert.assertEquals("#263238", json.getString("color")); + Assert.assertEquals("#24292e", json.getString("color")); Assert.assertEquals("", json.getString("css")); // Update the main color as admin