From 43a8cfe3809350fa0e5d371def375b7a6dab7891 Mon Sep 17 00:00:00 2001 From: Joshua Li Date: Thu, 8 Dec 2022 13:45:44 -0800 Subject: [PATCH] Add more metrics to frontend (#1326) Signed-off-by: Joshua Li --- .../components/common/search/search.tsx | 1 + .../__snapshots__/data_grid.test.tsx.snap | 4 ++ .../doc_viewer_row.test.tsx.snap | 2 + .../explorer/events_views/docViewRow.tsx | 1 + .../components/event_analytics/home/home.tsx | 7 ++- .../server/common/metrics/constants.ts | 45 +++++++++---------- .../server/common/metrics/metrics_helper.ts | 22 ++++----- .../server/common/metrics/types.ts | 8 ++-- .../app_analytics_router.ts | 13 ++++++ .../routes/custom_panels/panels_router.ts | 19 ++++++++ .../custom_panels/visualizations_router.ts | 3 ++ .../event_analytics/event_analytics_router.ts | 21 +++++++++ .../server/routes/notebooks/noteRouter.ts | 15 +++++++ .../server/routes/notebooks/sqlRouter.ts | 3 ++ .../server/routes/notebooks/vizRouter.ts | 3 ++ 15 files changed, 128 insertions(+), 39 deletions(-) diff --git a/dashboards-observability/public/components/common/search/search.tsx b/dashboards-observability/public/components/common/search/search.tsx index f6d30725a..989912f33 100644 --- a/dashboards-observability/public/components/common/search/search.tsx +++ b/dashboards-observability/public/components/common/search/search.tsx @@ -163,6 +163,7 @@ export const Search = (props: any) => { className={`ppl-link ${ uiSettingsService.get('theme:darkMode') ? 'ppl-link-dark' : 'ppl-link-light' }`} + data-click-metric-element="common.search.ppl_reference" color="hollow" onClick={() => showFlyout()} onClickAriaLabel={'pplLinkShowFlyout'} diff --git a/dashboards-observability/public/components/event_analytics/explorer/__tests__/__snapshots__/data_grid.test.tsx.snap b/dashboards-observability/public/components/event_analytics/explorer/__tests__/__snapshots__/data_grid.test.tsx.snap index df40c845c..0f9d221db 100644 --- a/dashboards-observability/public/components/event_analytics/explorer/__tests__/__snapshots__/data_grid.test.tsx.snap +++ b/dashboards-observability/public/components/event_analytics/explorer/__tests__/__snapshots__/data_grid.test.tsx.snap @@ -414,11 +414,13 @@ exports[`Datagrid component Renders data grid component 1`] = ` >