diff --git a/package.json b/package.json
index e96f9bd78a5..492bbf5359e 100644
--- a/package.json
+++ b/package.json
@@ -14,8 +14,8 @@
"@types/enzyme": "^2.8.9",
"@types/jest": "^21.1.4",
"@types/node": "^8.0.31",
- "@types/react": "^16.0.5",
- "@types/react-dom": "^15.5.4",
+ "@types/react": "^16.0.25",
+ "@types/react-dom": "^16.0.3",
"angular-mocks": "^1.6.6",
"autoprefixer": "^6.4.0",
"awesome-typescript-loader": "^3.2.3",
@@ -128,8 +128,8 @@
"ngreact": "^0.4.1",
"perfect-scrollbar": "^1.2.0",
"prop-types": "^15.6.0",
- "react": "^16.0.0",
- "react-dom": "^16.0.0",
+ "react": "^16.1.1",
+ "react-dom": "^16.1.1",
"react-grid-layout": "^0.16.0",
"react-sizeme": "^2.3.6",
"remarkable": "^1.7.1",
diff --git a/public/app/core/specs/backend_srv_specs.ts b/public/app/core/specs/backend_srv_specs.ts
index 0e78007f210..5e8cfa7b761 100644
--- a/public/app/core/specs/backend_srv_specs.ts
+++ b/public/app/core/specs/backend_srv_specs.ts
@@ -3,14 +3,12 @@ import 'app/core/services/backend_srv';
describe('backend_srv', function() {
var _backendSrv;
- var _http;
var _httpBackend;
beforeEach(angularMocks.module('grafana.core'));
beforeEach(angularMocks.module('grafana.services'));
beforeEach(angularMocks.inject(function ($httpBackend, $http, backendSrv) {
_httpBackend = $httpBackend;
- _http = $http;
_backendSrv = backendSrv;
}));
diff --git a/public/app/core/specs/datemath.jest.ts b/public/app/core/specs/datemath.jest.ts
index e2bdebcebce..54ef711bdcf 100644
--- a/public/app/core/specs/datemath.jest.ts
+++ b/public/app/core/specs/datemath.jest.ts
@@ -84,12 +84,10 @@ describe("DateMath", () => {
describe('rounding', () => {
var now;
- var anchored;
beforeEach(() => {
clock = sinon.useFakeTimers(unix);
now = moment();
- anchored = moment(anchor);
});
_.each(spans, (span) => {
diff --git a/public/app/features/alerting/alert_tab_ctrl.ts b/public/app/features/alerting/alert_tab_ctrl.ts
index b65a559e426..cc0b642fb3d 100644
--- a/public/app/features/alerting/alert_tab_ctrl.ts
+++ b/public/app/features/alerting/alert_tab_ctrl.ts
@@ -210,7 +210,6 @@ export class AlertTabCtrl {
}
let firstTarget;
- var fixed = false;
let foundTarget = null;
for (var condition of this.alert.conditions) {
@@ -232,7 +231,6 @@ export class AlertTabCtrl {
if (firstTarget) {
condition.query.params[0] = firstTarget.refId;
foundTarget = firstTarget;
- fixed = true;
} else {
this.error = "Could not find any metric queries";
}
diff --git a/public/app/features/dashboard/dashboard_list_ctrl.ts b/public/app/features/dashboard/dashboard_list_ctrl.ts
index ab62e3dfff6..08bba6450f9 100644
--- a/public/app/features/dashboard/dashboard_list_ctrl.ts
+++ b/public/app/features/dashboard/dashboard_list_ctrl.ts
@@ -10,6 +10,7 @@ export class DashboardListCtrl {
navModel: any;
canDelete = false;
canMove = false;
+ hasFilters = false;
selectAllChecked = false;
starredFilterOptions = [{text: 'Filter by Starred', disabled: true}, {text: 'Yes'}, {text: 'No'}];
selectedStarredFilter: any;
@@ -17,7 +18,7 @@ export class DashboardListCtrl {
/** @ngInject */
constructor(private backendSrv, navModelSrv, private $q, private searchSrv: SearchSrv) {
this.navModel = navModelSrv.getNav('dashboards', 'dashboards');
- this.query = {query: '', mode: 'tree', tag: []};
+ this.query = {query: '', mode: 'tree', tag: [], starred: false};
this.selectedStarredFilter = this.starredFilterOptions[0];
this.getDashboards().then(() => {
@@ -35,6 +36,7 @@ export class DashboardListCtrl {
this.canMove = false;
this.canDelete = false;
this.selectAllChecked = false;
+ this.hasFilters = this.query.query.length > 0 || this.query.tag.length > 0 || this.query.starred;
if (!result) {
this.sections = [];
@@ -194,4 +196,11 @@ export class DashboardListCtrl {
this.selectionChanged();
}
+
+ clearFilters() {
+ this.query.query = '';
+ this.query.tag = [];
+ this.query.starred = false;
+ this.getDashboards();
+ }
}
diff --git a/public/app/features/dashboard/folder_picker/picker.ts b/public/app/features/dashboard/folder_picker/picker.ts
index f32f3e5c856..97666365696 100644
--- a/public/app/features/dashboard/folder_picker/picker.ts
+++ b/public/app/features/dashboard/folder_picker/picker.ts
@@ -9,8 +9,7 @@ export class FolderPickerCtrl {
labelClass: string;
onChange: any;
rootName = 'Root';
-
- private folder: any;
+ folder: any;
/** @ngInject */
constructor(private backendSrv) {
diff --git a/public/app/features/dashboard/partials/dashboardList.html b/public/app/features/dashboard/partials/dashboardList.html
index 4c574c5a5ba..c9822efe561 100644
--- a/public/app/features/dashboard/partials/dashboardList.html
+++ b/public/app/features/dashboard/partials/dashboardList.html
@@ -32,6 +32,18 @@
+