diff --git a/.betterer.results b/.betterer.results index 659e04ad857..bc0bc0bc00e 100644 --- a/.betterer.results +++ b/.betterer.results @@ -6051,19 +6051,6 @@ exports[`better eslint`] = { "public/app/plugins/panel/geomap/utils/tooltip.ts:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"] ], - "public/app/plugins/panel/gettingstarted/GettingStarted.tsx:5381": [ - [0, 0, 0, "Styles should be written using objects.", "0"], - [0, 0, 0, "Styles should be written using objects.", "1"], - [0, 0, 0, "Styles should be written using objects.", "2"], - [0, 0, 0, "Styles should be written using objects.", "3"], - [0, 0, 0, "Styles should be written using objects.", "4"], - [0, 0, 0, "Styles should be written using objects.", "5"], - [0, 0, 0, "Styles should be written using objects.", "6"], - [0, 0, 0, "Styles should be written using objects.", "7"], - [0, 0, 0, "Styles should be written using objects.", "8"], - [0, 0, 0, "Styles should be written using objects.", "9"], - [0, 0, 0, "Styles should be written using objects.", "10"] - ], "public/app/plugins/panel/gettingstarted/components/DocsCard.tsx:5381": [ [0, 0, 0, "Styles should be written using objects.", "0"], [0, 0, 0, "Styles should be written using objects.", "1"], @@ -6086,8 +6073,7 @@ exports[`better eslint`] = { [0, 0, 0, "Styles should be written using objects.", "5"] ], "public/app/plugins/panel/gettingstarted/components/sharedStyles.ts:5381": [ - [0, 0, 0, "Styles should be written using objects.", "0"], - [0, 0, 0, "Styles should be written using objects.", "1"] + [0, 0, 0, "Styles should be written using objects.", "0"] ], "public/app/plugins/panel/heatmap/HeatmapPanel.tsx:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"], diff --git a/public/app/plugins/panel/gettingstarted/GettingStarted.tsx b/public/app/plugins/panel/gettingstarted/GettingStarted.tsx index 19753cabb63..88e16179335 100644 --- a/public/app/plugins/panel/gettingstarted/GettingStarted.tsx +++ b/public/app/plugins/panel/gettingstarted/GettingStarted.tsx @@ -3,7 +3,7 @@ import { css, cx } from '@emotion/css'; import React, { PureComponent } from 'react'; import { PanelProps } from '@grafana/data'; -import { config } from '@grafana/runtime'; +import { config, reportInteraction } from '@grafana/runtime'; import { Button, Spinner, stylesFactory } from '@grafana/ui'; import { contextSrv } from 'app/core/core'; import { backendSrv } from 'app/core/services/backend_srv'; @@ -53,12 +53,14 @@ export class GettingStarted extends PureComponent { } onForwardClick = () => { + reportInteraction('grafana_getting_started_button_to_advanced_tutorials'); this.setState((prevState) => ({ currentStep: prevState.currentStep + 1, })); }; onPreviousClick = () => { + reportInteraction('grafana_getting_started_button_to_basic_tutorials'); this.setState((prevState) => ({ currentStep: prevState.currentStep - 1, })); @@ -69,6 +71,8 @@ export class GettingStarted extends PureComponent { const dashboard = getDashboardSrv().getCurrent(); const panel = dashboard?.getPanelById(id); + reportInteraction('grafana_getting_started_remove_panel'); + dashboard?.removePanel(panel!); backendSrv.put('/api/user/helpflags/1', undefined, { showSuccessAlert: false }).then((res) => { @@ -97,7 +101,7 @@ export class GettingStarted extends PureComponent {