From 7559982b0505f5154628b1ff20bae8df563a119d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Torkel=20=C3=96degaard?= Date: Wed, 25 Oct 2017 12:37:34 +0200 Subject: [PATCH] grid: minor changes --- .../dashboard/dashgrid/DashboardRow.tsx | 3 +- .../features/dashboard/dashnav/dashnav.html | 11 +- .../dashboard/partials/row_options.html | 28 +- .../dashboard/specs/dashboard_model.jest.ts | 339 ++++++------------ .../features/dashboard/specs/repeat.jest.ts | 206 +++++++++++ .../app/features/panel/metrics_panel_ctrl.ts | 2 +- public/app/features/panel/panel_directive.ts | 1 - public/sass/components/_navbar.scss | 24 +- 8 files changed, 341 insertions(+), 273 deletions(-) create mode 100644 public/app/features/dashboard/specs/repeat.jest.ts diff --git a/public/app/features/dashboard/dashgrid/DashboardRow.tsx b/public/app/features/dashboard/dashgrid/DashboardRow.tsx index 74dedc6e8b8..00999e4005e 100644 --- a/public/app/features/dashboard/dashgrid/DashboardRow.tsx +++ b/public/app/features/dashboard/dashgrid/DashboardRow.tsx @@ -48,7 +48,7 @@ export class DashboardRow extends React.Component { let text2 = ''; if (this.props.panel.panels.length) { - text2 = `This will also remove row's ${this.props.panel.panels.length} hidden panels`; + text2 = `This will also remove the row's ${this.props.panel.panels.length} panels`; } appEvents.emit('confirm-modal', { @@ -71,6 +71,7 @@ export class DashboardRow extends React.Component { 'fa-chevron-down': !this.state.collapsed, 'fa-chevron-right': this.state.collapsed, }); + const hiddenPanels = this.props.panel.panels ? this.props.panel.panels.length : 0; return ( diff --git a/public/app/features/dashboard/dashnav/dashnav.html b/public/app/features/dashboard/dashnav/dashnav.html index aef4bb7484e..c23a15aa208 100644 --- a/public/app/features/dashboard/dashnav/dashnav.html +++ b/public/app/features/dashboard/dashnav/dashnav.html @@ -1,11 +1,7 @@