From d9892f852b247104f06fdf4b6b11a0f00a7ec209 Mon Sep 17 00:00:00 2001 From: Zsolt Kocsmarszky Date: Tue, 9 Jan 2018 21:35:28 +0100 Subject: [PATCH 01/17] add new widget to the bottom of the dashboard --- .../assets/less/redash/redash-newstyle.less | 8 +++++++ client/app/pages/dashboards/dashboard.html | 22 ++++++++++++++----- 2 files changed, 25 insertions(+), 5 deletions(-) diff --git a/client/app/assets/less/redash/redash-newstyle.less b/client/app/assets/less/redash/redash-newstyle.less index e74064f537..b3acbfc2f1 100644 --- a/client/app/assets/less/redash/redash-newstyle.less +++ b/client/app/assets/less/redash/redash-newstyle.less @@ -91,6 +91,14 @@ body { } } +.add-widget-container { + background: fade(@redash-gray, 10%); + border-radius: @redash-radius; + margin-top: 15px; + //box-shadow: fade(@redash-gray, 15%) 0px 4px 9px -3px; + border: 2px dashed fade(@redash-gray, 25%); +} + .database-source { display: inline-flex; flex-wrap: wrap; diff --git a/client/app/pages/dashboards/dashboard.html b/client/app/pages/dashboards/dashboard.html index 825d00bfcd..2c450d4e5c 100644 --- a/client/app/pages/dashboards/dashboard.html +++ b/client/app/pages/dashboards/dashboard.html @@ -1,17 +1,17 @@
-
+

{{$ctrl.dashboard.name}} Unpublished Archived

-
+
-
@@ -76,7 +76,7 @@

{{$ctrl.dashboard.name}}

-
+
{{$ctrl.dashboard.name}}
+ +
+
+
+
+

+

Widgets are individual query visualisations you can place on your dashboard in various arrangements.

+ Add Widget +

+
+
+
From 84532f84ac8661ae6aab33f7a3f8b829821fd44d Mon Sep 17 00:00:00 2001 From: Zsolt Kocsmarszky Date: Sun, 14 Jan 2018 23:29:05 +0100 Subject: [PATCH 02/17] Improve dashboard widget creation and publish process with multiple design improvements --- .../app/assets/less/redash/redash-newstyle.less | 5 +++++ client/app/pages/dashboards/dashboard.html | 15 +++++++++------ 2 files changed, 14 insertions(+), 6 deletions(-) diff --git a/client/app/assets/less/redash/redash-newstyle.less b/client/app/assets/less/redash/redash-newstyle.less index b3acbfc2f1..afc60b0aa4 100644 --- a/client/app/assets/less/redash/redash-newstyle.less +++ b/client/app/assets/less/redash/redash-newstyle.less @@ -293,6 +293,11 @@ page-header, .page-header--new { .label { border-radius: 2px; padding: 3px 6px 4px; + font-weight: 500; +} + +.label-default { + background: fade(@redash-gray, 85%); } .tab-nav > li > a { diff --git a/client/app/pages/dashboards/dashboard.html b/client/app/pages/dashboards/dashboard.html index 2c450d4e5c..52d790478d 100644 --- a/client/app/pages/dashboards/dashboard.html +++ b/client/app/pages/dashboards/dashboard.html @@ -1,13 +1,13 @@
-
+

{{$ctrl.dashboard.name}} Unpublished Archived

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

{{$ctrl.dashboard.name}}

-
+ + +
- - @@ -61,7 +65,6 @@

{{$ctrl.dashboard.name}}
  • Add Widget
  • Manage Permissions
  • Unpublish Dashboard
  • -
  • Publish Dashboard
  • Archive Dashboard
  • From d95c9565f31af40580bbd87e6a2f29faf849202a Mon Sep 17 00:00:00 2001 From: Zsolt Kocsmarszky Date: Mon, 15 Jan 2018 00:12:11 +0100 Subject: [PATCH 03/17] plenty of dashboard, filter and parameter fixes (still not the best, it's very messy here) --- client/app/assets/less/redash/query.less | 2 +- client/app/assets/less/redash/redash-newstyle.less | 6 ++++++ client/app/components/filters.html | 2 +- client/app/components/parameters.html | 2 +- client/app/pages/dashboards/dashboard.html | 7 ++++--- client/app/pages/queries/query.html | 4 +++- 6 files changed, 16 insertions(+), 7 deletions(-) diff --git a/client/app/assets/less/redash/query.less b/client/app/assets/less/redash/query.less index cc76d371d0..74c8ee73ce 100644 --- a/client/app/assets/less/redash/query.less +++ b/client/app/assets/less/redash/query.less @@ -79,7 +79,7 @@ edit-in-place p.editable:hover { } .filter-container { - margin-bottom: 5px; + margin-bottom: 10px; } .editor__control--right { diff --git a/client/app/assets/less/redash/redash-newstyle.less b/client/app/assets/less/redash/redash-newstyle.less index afc60b0aa4..210799514d 100644 --- a/client/app/assets/less/redash/redash-newstyle.less +++ b/client/app/assets/less/redash/redash-newstyle.less @@ -323,6 +323,12 @@ page-header, .page-header--new { } } +.widget-wrapper { + .parameter-container { + padding: 0 15px; + } +} + .bg-ace { background-color: fade(@redash-gray, 12%) !important; } diff --git a/client/app/components/filters.html b/client/app/components/filters.html index 8153b59516..e0a5ac54cd 100644 --- a/client/app/components/filters.html +++ b/client/app/components/filters.html @@ -1,4 +1,4 @@ -
    +
    diff --git a/client/app/components/parameters.html b/client/app/components/parameters.html index c33c20a1fb..d628d9ec09 100644 --- a/client/app/components/parameters.html +++ b/client/app/components/parameters.html @@ -1,4 +1,4 @@ -
    diff --git a/client/app/pages/dashboards/dashboard.html b/client/app/pages/dashboards/dashboard.html index 52d790478d..8a448cab1c 100644 --- a/client/app/pages/dashboards/dashboard.html +++ b/client/app/pages/dashboards/dashboard.html @@ -71,12 +71,13 @@

    {{$ctrl.dashboard.name}}

    -
    + +
    -
    - +
    +
    diff --git a/client/app/pages/queries/query.html b/client/app/pages/queries/query.html index 09c998189e..3c5102e8ae 100644 --- a/client/app/pages/queries/query.html +++ b/client/app/pages/queries/query.html @@ -186,7 +186,9 @@

    - +
    + +
    From 043a1eedcfddd546f997395bc9d79c3fac17c748 Mon Sep 17 00:00:00 2001 From: Zsolt Kocsmarszky Date: Mon, 15 Jan 2018 00:19:51 +0100 Subject: [PATCH 04/17] Add missing class for consistency --- client/app/components/filters.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/app/components/filters.html b/client/app/components/filters.html index e0a5ac54cd..d19f8d7a45 100644 --- a/client/app/components/filters.html +++ b/client/app/components/filters.html @@ -1,4 +1,4 @@ -
    +
    From 80e07c6cf9175bff6725261b7907d80ab6b29494 Mon Sep 17 00:00:00 2001 From: Zsolt Kocsmarszky Date: Mon, 15 Jan 2018 23:40:25 +0100 Subject: [PATCH 05/17] add ng-if to hide and show sections accordingly --- client/app/pages/dashboards/dashboard.html | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/client/app/pages/dashboards/dashboard.html b/client/app/pages/dashboards/dashboard.html index 8a448cab1c..90d2993353 100644 --- a/client/app/pages/dashboards/dashboard.html +++ b/client/app/pages/dashboards/dashboard.html @@ -71,8 +71,7 @@

    {{$ctrl.dashboard.name}}

    - -
    +
    @@ -80,7 +79,7 @@

    {{$ctrl.dashboard.name}}

    -
    +
    Date: Tue, 16 Jan 2018 00:37:53 +0100 Subject: [PATCH 06/17] Add extra header class and fixed styling --- client/app/assets/less/redash/redash-newstyle.less | 10 ++++++++++ client/app/pages/dashboards/dashboard.html | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/client/app/assets/less/redash/redash-newstyle.less b/client/app/assets/less/redash/redash-newstyle.less index 210799514d..8b509b518e 100644 --- a/client/app/assets/less/redash/redash-newstyle.less +++ b/client/app/assets/less/redash/redash-newstyle.less @@ -323,6 +323,16 @@ page-header, .page-header--new { } } +.dashboard-header.fixed { + position: fixed; + top: 0; + width: 100%; + background: #f6f7f9; + z-index: 9999; + left: 0; + padding: 5px 30px !important; +} + .widget-wrapper { .parameter-container { padding: 0 15px; diff --git a/client/app/pages/dashboards/dashboard.html b/client/app/pages/dashboards/dashboard.html index 90d2993353..76f55b3e2a 100644 --- a/client/app/pages/dashboards/dashboard.html +++ b/client/app/pages/dashboards/dashboard.html @@ -1,6 +1,6 @@
    -
    +

    {{$ctrl.dashboard.name}} Unpublished From 977608198e82990a9d7d3e9d9cb022d0921357f8 Mon Sep 17 00:00:00 2001 From: Zsolt Kocsmarszky Date: Tue, 16 Jan 2018 13:23:45 +0100 Subject: [PATCH 07/17] position: sticke for dashboard-header --- client/app/assets/less/redash/redash-newstyle.less | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/client/app/assets/less/redash/redash-newstyle.less b/client/app/assets/less/redash/redash-newstyle.less index 8b509b518e..bf283c7162 100644 --- a/client/app/assets/less/redash/redash-newstyle.less +++ b/client/app/assets/less/redash/redash-newstyle.less @@ -323,14 +323,13 @@ page-header, .page-header--new { } } -.dashboard-header.fixed { - position: fixed; - top: 0; - width: 100%; +.dashboard-header { + position: -webkit-sticky; // required for Safari + position: sticky; background: #f6f7f9; - z-index: 9999; - left: 0; - padding: 5px 30px !important; + z-index: 99; + width: 100%; + top: 0; } .widget-wrapper { From 4b74ab361a34663ef941db0d5cfefe22e9c25208 Mon Sep 17 00:00:00 2001 From: Zsolt Kocsmarszky Date: Thu, 18 Jan 2018 18:42:57 +0100 Subject: [PATCH 08/17] Styling improvements + show buttons in the right context --- .../app/assets/less/redash/redash-newstyle.less | 15 +++++++++++++++ client/app/pages/dashboards/dashboard.html | 10 +++++----- 2 files changed, 20 insertions(+), 5 deletions(-) diff --git a/client/app/assets/less/redash/redash-newstyle.less b/client/app/assets/less/redash/redash-newstyle.less index bf283c7162..7066cd47e3 100644 --- a/client/app/assets/less/redash/redash-newstyle.less +++ b/client/app/assets/less/redash/redash-newstyle.less @@ -308,6 +308,21 @@ page-header, .page-header--new { text-transform: none; } +.dashboard-header { + position: -webkit-sticky; // required for Safari + position: sticky; + background: #f6f7f9; + z-index: 99; + width: 100%; + top: 0; +} + +.widget-wrapper { + .parameter-container { + padding: 0 15px; + } +} + .dashboard__control { margin: 8px 0; } diff --git a/client/app/pages/dashboards/dashboard.html b/client/app/pages/dashboards/dashboard.html index 76f55b3e2a..a1042a011d 100644 --- a/client/app/pages/dashboards/dashboard.html +++ b/client/app/pages/dashboards/dashboard.html @@ -24,11 +24,11 @@

    {{$ctrl.dashboard.name}}

    - -
    +
    - - -
    +
    From cfb4a1c4f75ca7b143e5109e19ed37b797fa2970 Mon Sep 17 00:00:00 2001 From: Zsolt Kocsmarszky Date: Thu, 18 Jan 2018 19:23:44 +0100 Subject: [PATCH 09/17] Simplify markup and add more styling for add new widget box --- .../app/assets/less/redash/redash-newstyle.less | 16 ++++++++++++++++ client/app/pages/dashboards/dashboard.html | 14 ++++---------- 2 files changed, 20 insertions(+), 10 deletions(-) diff --git a/client/app/assets/less/redash/redash-newstyle.less b/client/app/assets/less/redash/redash-newstyle.less index 7066cd47e3..8083c355ad 100644 --- a/client/app/assets/less/redash/redash-newstyle.less +++ b/client/app/assets/less/redash/redash-newstyle.less @@ -73,6 +73,22 @@ body { } } +.add-widget-container { + background: #fff; + border-radius: @redash-radius; + padding: 20px; + position: fixed; + left: calc(~'50% - 200px'); + bottom: 25px; + width: 400px; + z-index: 99; + box-shadow: fade(@redash-gray, 50%) 0px 7px 29px -3px; + + h2 { + margin-top: 0; + } +} + body { .ace-tm .ace_gutter { background: #fff; diff --git a/client/app/pages/dashboards/dashboard.html b/client/app/pages/dashboards/dashboard.html index a1042a011d..5b8a6e4ea5 100644 --- a/client/app/pages/dashboards/dashboard.html +++ b/client/app/pages/dashboards/dashboard.html @@ -89,15 +89,9 @@

    {{$ctrl.dashboard.name}}

    -
    -
    -
    -
    -

    -

    Widgets are individual query visualisations you can place on your dashboard in various arrangements.

    - Add Widget -

    -
    -
    +
    +

    +

    Widgets are individual query visualisations you can place on your dashboard in various arrangements.

    + Add Widget
    From f7512f18f658c29a3f092087c15d10c06d898a6b Mon Sep 17 00:00:00 2001 From: Zsolt Kocsmarszky Date: Thu, 18 Jan 2018 20:52:13 +0100 Subject: [PATCH 10/17] Fix schema hover on sub-items --- client/app/assets/less/inc/schema-browser.less | 2 ++ 1 file changed, 2 insertions(+) diff --git a/client/app/assets/less/inc/schema-browser.less b/client/app/assets/less/inc/schema-browser.less index dc18c2343f..c077e7142c 100644 --- a/client/app/assets/less/inc/schema-browser.less +++ b/client/app/assets/less/inc/schema-browser.less @@ -62,6 +62,8 @@ div.table-name { } &:hover { + background: fade(@redash-gray, 10%); + .copy-to-editor { display: flex; } From dd3916672a085308777e5096f6b60462861ccf6c Mon Sep 17 00:00:00 2001 From: Zsolt Kocsmarszky Date: Thu, 18 Jan 2018 21:22:47 +0100 Subject: [PATCH 11/17] Wider add widget section for dashboards --- .../assets/less/redash/redash-newstyle.less | 31 ++++++++++++++++--- client/app/pages/dashboards/dashboard.html | 8 +++-- 2 files changed, 31 insertions(+), 8 deletions(-) diff --git a/client/app/assets/less/redash/redash-newstyle.less b/client/app/assets/less/redash/redash-newstyle.less index 8083c355ad..519616cead 100644 --- a/client/app/assets/less/redash/redash-newstyle.less +++ b/client/app/assets/less/redash/redash-newstyle.less @@ -76,16 +76,37 @@ body { .add-widget-container { background: #fff; border-radius: @redash-radius; - padding: 20px; + padding: 15px; position: fixed; - left: calc(~'50% - 200px'); - bottom: 25px; - width: 400px; + left: 15px; + bottom: 20px; + width: calc(~'100% - 30px'); z-index: 99; box-shadow: fade(@redash-gray, 50%) 0px 7px 29px -3px; + display: flex; + justify-content: space-between; h2 { - margin-top: 0; + margin: 0; + font-size: 14px; + line-height: 2.1; + font-weight: 400; + + .zmdi { + margin: 0; + margin-right: 5px; + font-size: 24px; + position: absolute; + bottom: 18px; + } + + span { + padding-left: 30px; + } + } + + .btn { + align-self: center; } } diff --git a/client/app/pages/dashboards/dashboard.html b/client/app/pages/dashboards/dashboard.html index 5b8a6e4ea5..f32c13930c 100644 --- a/client/app/pages/dashboards/dashboard.html +++ b/client/app/pages/dashboards/dashboard.html @@ -89,9 +89,11 @@

    {{$ctrl.dashboard.name}}

    -
    -

    -

    Widgets are individual query visualisations you can place on your dashboard in various arrangements.

    +
    +

    + + +

    Add Widget
    From b090b6b9dcde65db65b213ccdd82ed7ca432bc0b Mon Sep 17 00:00:00 2001 From: Zsolt Kocsmarszky Date: Fri, 19 Jan 2018 15:25:45 +0100 Subject: [PATCH 12/17] Only render parameters div if we have parameters --- client/app/pages/queries/query.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/app/pages/queries/query.html b/client/app/pages/queries/query.html index 3c5102e8ae..90ad973270 100644 --- a/client/app/pages/queries/query.html +++ b/client/app/pages/queries/query.html @@ -186,7 +186,7 @@

    -
    +
    From a98eff8901c08735bb783d5d6b800524caf3b9b9 Mon Sep 17 00:00:00 2001 From: Zsolt Kocsmarszky Date: Fri, 19 Jan 2018 21:48:19 +0100 Subject: [PATCH 13/17] improve widget description --- client/app/pages/dashboards/dashboard.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/client/app/pages/dashboards/dashboard.html b/client/app/pages/dashboards/dashboard.html index f32c13930c..8debcd8635 100644 --- a/client/app/pages/dashboards/dashboard.html +++ b/client/app/pages/dashboards/dashboard.html @@ -92,7 +92,7 @@

    {{$ctrl.dashboard.name}}

    - +

    Add Widget
    From c7dbe07b33bf3b31dad78440679f2c8caa0aba8b Mon Sep 17 00:00:00 2001 From: Arik Fraimovich Date: Sat, 20 Jan 2018 21:50:05 +0200 Subject: [PATCH 14/17] Single dashboard editing mode. --- .../dashboards/edit-dashboard-dialog.html | 7 - .../dashboards/edit-dashboard-dialog.js | 55 +---- client/app/pages/dashboards/dashboard.html | 17 +- client/app/pages/dashboards/dashboard.js | 223 +++++++++++------- 4 files changed, 160 insertions(+), 142 deletions(-) diff --git a/client/app/components/dashboards/edit-dashboard-dialog.html b/client/app/components/dashboards/edit-dashboard-dialog.html index ea54aceb27..e216d569a4 100644 --- a/client/app/components/dashboards/edit-dashboard-dialog.html +++ b/client/app/components/dashboards/edit-dashboard-dialog.html @@ -6,13 +6,6 @@

    - -

    - -