From 7b4a1895882bc382b8924c8511d6c7765c3185cb Mon Sep 17 00:00:00 2001 From: Shekar Siri Date: Thu, 23 Jun 2022 16:26:01 +0200 Subject: [PATCH] change(ui) - sessions and errors count --- .../Dashboard/components/WidgetForm/WidgetForm.tsx | 3 --- .../Dashboard/components/WidgetPreview/WidgetPreview.tsx | 8 ++++---- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/frontend/app/components/Dashboard/components/WidgetForm/WidgetForm.tsx b/frontend/app/components/Dashboard/components/WidgetForm/WidgetForm.tsx index af09c030a..d2635f24a 100644 --- a/frontend/app/components/Dashboard/components/WidgetForm/WidgetForm.tsx +++ b/frontend/app/components/Dashboard/components/WidgetForm/WidgetForm.tsx @@ -28,9 +28,6 @@ function WidgetForm(props: Props) { const tableOptions = metricOf.filter(i => i.type === 'table'); const isTable = metric.metricType === 'table'; const isFunnel = metric.metricType === 'funnel'; - const isErrors = metric.metricType === 'errors'; - const isSessions = metric.metricType === 'sessions'; - const _issueOptions = [{ label: 'All', value: 'all' }].concat(issueOptions); const canAddToDashboard = metric.exists() && dashboards.length > 0; const canAddSeries = metric.series.length < 3; diff --git a/frontend/app/components/Dashboard/components/WidgetPreview/WidgetPreview.tsx b/frontend/app/components/Dashboard/components/WidgetPreview/WidgetPreview.tsx index 49a1f752d..bde05f398 100644 --- a/frontend/app/components/Dashboard/components/WidgetPreview/WidgetPreview.tsx +++ b/frontend/app/components/Dashboard/components/WidgetPreview/WidgetPreview.tsx @@ -40,11 +40,11 @@ function WidgetPreview(props: Props) { return 'Time Series'; } else if (isTable) { if (metric.metricOf === FilterKey.SESSIONS) { - return 'Table of Sessions'; - // return
Sessions {metric.data.total}
; + // return 'Table of Sessions'; + return
Sessions {metric.data.total}
; } else if (metric.metricOf === FilterKey.ERRORS) { - return 'Table of Errors'; - // return
Errors {metric.data.total}
; + // return 'Table of Errors'; + return
Errors {metric.data.total}
; } else { return 'Table'; }