@levi-gemcommerce/analytics 3.0.1-dev.3 → 3.0.1-dev.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +38 -15
- package/src/api/graphql/fragments/pathAnalytic.generated.ts +0 -26
- package/src/assets/img/all-sessions.png +0 -0
- package/src/assets/img/analytic-empty.png +0 -0
- package/src/assets/img/first-session.png +0 -0
- package/src/assets/img/page-only.png +0 -0
- package/src/assets/svg/gemx-skeleton.svg +0 -12
- package/src/assets/svg/product.svg +0 -18
- package/src/components/AnalyticMode/AnalyticModeSelector.tsx +0 -50
- package/src/components/AnalyticMode/index.ts +0 -2
- package/src/components/CardPathAnalysis/CardJourneyAnalysis.tsx +0 -33
- package/src/components/CardPathAnalysis/assets/img/analytic-gemx.png +0 -0
- package/src/components/CardPathAnalysis/assets/styles/PathAnalysis.scss +0 -60
- package/src/components/CardPathAnalysis/components/CardPathAnalysis/CardAnalyticEmpty.tsx +0 -45
- package/src/components/CardPathAnalysis/components/CardPathAnalysis/CardPathAnalysis.tsx +0 -53
- package/src/components/CardPathAnalysis/components/CardPathAnalysis/CardPathAnalysisContent.tsx +0 -65
- package/src/components/CardPathAnalysis/components/CardPathAnalysis/CardPathAnalysisEmpty.tsx +0 -29
- package/src/components/CardPathAnalysis/components/CardPathAnalysis/CardPathAnalysisSkeleton.tsx +0 -12
- package/src/components/CardPathAnalysis/components/CardPathAnalysis/CardPathAnalysisWrapper.tsx +0 -43
- package/src/components/CardPathAnalysis/components/CardPathAnalysis/index.ts +0 -1
- package/src/components/CardPathAnalysis/components/PathAnalysisChart.tsx +0 -55
- package/src/components/CardPathAnalysis/components/index.ts +0 -1
- package/src/components/CardPathAnalysis/configs/index.ts +0 -2
- package/src/components/CardPathAnalysis/constants/index.ts +0 -1
- package/src/components/CardPathAnalysis/constants/path-analysis.ts +0 -162
- package/src/components/CardPathAnalysis/contexts/PathAnalysisConfigProvider.tsx +0 -66
- package/src/components/CardPathAnalysis/contexts/PathAnalysisProvider.tsx +0 -130
- package/src/components/CardPathAnalysis/contexts/index.ts +0 -2
- package/src/components/CardPathAnalysis/helpers/index.ts +0 -2
- package/src/components/CardPathAnalysis/helpers/metricHelpers.ts +0 -13
- package/src/components/CardPathAnalysis/helpers/pathAnalysis.ts +0 -96
- package/src/components/CardPathAnalysis/helpers/pathAnalysisChart.ts +0 -128
- package/src/components/CardPathAnalysis/helpers/treeUtils.ts +0 -38
- package/src/components/CardPathAnalysis/hooks/usePathAnalysisChart.tsx +0 -292
- package/src/components/CardPathAnalysis/hooks/usePathAnalysisFunnel.ts +0 -206
- package/src/components/CardPathAnalysis/hooks/usePathAnalyticsMerger.ts +0 -43
- package/src/components/CardPathAnalysis/index.ts +0 -5
- package/src/components/CardPathAnalysis/stores/funnel-chart.ts +0 -30
- package/src/components/CardPathAnalysis/stores/index.ts +0 -3
- package/src/components/CardPathAnalysis/stores/path-analysis-campaign.ts +0 -16
- package/src/components/CardPathAnalysis/stores/path-analysis.ts +0 -11
- package/src/components/CardPathAnalysis/types/index.ts +0 -1
- package/src/components/CardPathAnalysis/types/path-analysis.ts +0 -10
- package/src/components/CurrencySelector/CurrencySelector.tsx +0 -127
- package/src/components/CurrencySelector/index.ts +0 -2
- package/src/components/GModalOrderJourney/GModalOrderJourney.tsx +0 -131
- package/src/components/GModalOrderJourney/components/OrderJourneySkeleton.tsx +0 -93
- package/src/components/GModalOrderJourney/components/index.ts +0 -1
- package/src/components/GModalOrderJourney/context/OrderJourneyContext.tsx +0 -17
- package/src/components/GModalOrderJourney/context/index.ts +0 -1
- package/src/components/GModalOrderJourney/hooks/index.ts +0 -1
- package/src/components/GModalOrderJourney/hooks/useGModalOrderJourney.ts +0 -25
- package/src/components/GModalOrderJourney/index.ts +0 -5
- package/src/components/GModalOrderJourney/types/index.ts +0 -4
- package/src/components/GModalOrderJourney/utils/index.ts +0 -75
- package/src/components/GSelectableMetricChartCard/GSelectableMetricChartCard.tsx +0 -83
- package/src/components/GSelectableMetricChartCard/MetricChartTab.tsx +0 -56
- package/src/components/GSelectableMetricChartCard/index.ts +0 -2
- package/src/components/GTimePicker/GTimePicker.tsx +0 -31
- package/src/components/GTimePicker/components/BaseTimePicker.tsx +0 -249
- package/src/components/GTimePicker/components/CompareTimePicker.tsx +0 -41
- package/src/components/GTimePicker/components/DateTimeFilterAddition.tsx +0 -84
- package/src/components/GTimePicker/components/DateTimeFilterInputs.tsx +0 -124
- package/src/components/GTimePicker/components/DateTimeFilters.tsx +0 -86
- package/src/components/GTimePicker/components/MainTimePicker.tsx +0 -47
- package/src/components/GTimePicker/components/index.ts +0 -2
- package/src/components/GTimePicker/constants/compareDateTimePicker.ts +0 -68
- package/src/components/GTimePicker/constants/datePicker.ts +0 -14
- package/src/components/GTimePicker/constants/index.ts +0 -2
- package/src/components/GTimePicker/constants/mainDataTimePicker.ts +0 -88
- package/src/components/GTimePicker/contexts/DateTimePickerProvider.tsx +0 -125
- package/src/components/GTimePicker/contexts/index.ts +0 -1
- package/src/components/GTimePicker/helpers/date-range-info.ts +0 -84
- package/src/components/GTimePicker/helpers/index.ts +0 -4
- package/src/components/GTimePicker/helpers/parse-date.ts +0 -127
- package/src/components/GTimePicker/helpers/time-picker.ts +0 -123
- package/src/components/GTimePicker/helpers/version.ts +0 -36
- package/src/components/GTimePicker/hooks/index.ts +0 -3
- package/src/components/GTimePicker/hooks/useCompareDateTimePicker.tsx +0 -79
- package/src/components/GTimePicker/hooks/useDateTimeFilter.ts +0 -83
- package/src/components/GTimePicker/hooks/useDateTimePicker.tsx +0 -99
- package/src/components/GTimePicker/hooks/useVersionDateTimeFilters.ts +0 -30
- package/src/components/GTimePicker/index.ts +0 -7
- package/src/components/GTimePicker/types/index.ts +0 -43
- package/src/components/MetricDonutChartCard/MetricDonutChartCard.tsx +0 -121
- package/src/components/MetricDonutChartCard/index.ts +0 -2
- package/src/components/MetricDonutChartCard/utils/donut-chart.ts +0 -75
- package/src/components/MetricDonutChartCard/utils/index.ts +0 -1
- package/src/components/OrderAnalytic/OrderListingLatestTable.tsx +0 -111
- package/src/components/OrderAnalytic/components/OrderListing/OrderListingSkeleton/OrderListingTableSkeleton.tsx +0 -40
- package/src/components/OrderAnalytic/components/OrderListing/OrderListingSkeleton/SkeletonCellContent.tsx +0 -77
- package/src/components/OrderAnalytic/components/OrderListing/OrderListingSkeleton/SkeletonHeader.tsx +0 -35
- package/src/components/OrderAnalytic/components/OrderListing/OrderListingSkeleton/SkeletonRow.tsx +0 -35
- package/src/components/OrderAnalytic/components/OrderListing/OrderListingSkeleton/SkeletonSummaryRow.tsx +0 -36
- package/src/components/OrderAnalytic/components/OrderListing/OrderListingSkeleton/constants.ts +0 -11
- package/src/components/OrderAnalytic/components/OrderListing/OrderListingSkeleton/index.ts +0 -1
- package/src/components/OrderAnalytic/components/OrderListing/OrderListingTable.tsx +0 -159
- package/src/components/OrderAnalytic/components/OrderListing/OrderListingTableEmpty.tsx +0 -29
- package/src/components/OrderAnalytic/components/OrderListing/index.ts +0 -2
- package/src/components/OrderAnalytic/components/index.ts +0 -1
- package/src/components/OrderAnalytic/constants/index.ts +0 -2
- package/src/components/OrderAnalytic/constants/order-columns.ts +0 -51
- package/src/components/OrderAnalytic/constants/order-listing.ts +0 -199
- package/src/components/OrderAnalytic/helpers/index.ts +0 -1
- package/src/components/OrderAnalytic/helpers/order-listing.ts +0 -48
- package/src/components/OrderAnalytic/hooks/index.ts +0 -1
- package/src/components/OrderAnalytic/hooks/useOrderListingData.ts +0 -55
- package/src/components/OrderAnalytic/index.ts +0 -5
- package/src/components/OrderAnalytic/stores/index.ts +0 -2
- package/src/components/OrderAnalytic/stores/order-columns-selector.ts +0 -24
- package/src/components/OrderAnalytic/stores/order-control.ts +0 -15
- package/src/components/OrderAnalytic/types/index.ts +0 -3
- package/src/components/OrderAnalytic/types/order.ts +0 -89
- package/src/components/OrderAnalytic/types/orderListing.ts +0 -4
- package/src/components/OrderAnalytic/types/report.ts +0 -14
- package/src/components/SingleMetricChartCard/SingleMetricChartCard.tsx +0 -56
- package/src/components/SingleMetricChartCard/index.tsx +0 -2
- package/src/components/common/chart/GChartSkeleton.tsx +0 -5
- package/src/components/common/chart/MetricChart.tsx +0 -62
- package/src/components/common/chart/MetricChartEmpty.tsx +0 -35
- package/src/components/common/chart/MetricChartTooltip.tsx +0 -74
- package/src/components/common/chart/MetricDonutChartSkeleton.tsx +0 -14
- package/src/components/common/chart/MetricInfoBlock.tsx +0 -66
- package/src/components/common/chart/MetricInfoSkeleton.tsx +0 -25
- package/src/components/common/chart/MetricValueSummary.tsx +0 -23
- package/src/components/common/chart/index.ts +0 -8
- package/src/components/common/icons/DownIcon8px.tsx +0 -14
- package/src/components/common/icons/UpIcon8px.tsx +0 -14
- package/src/components/common/icons/index.ts +0 -2
- package/src/components/common/percent/MetricPercentage.tsx +0 -42
- package/src/components/common/percent/index.ts +0 -1
- package/src/components/index.ts +0 -9
- package/src/constants/analytic-metric-tooltip.tsx +0 -164
- package/src/constants/breakdown-targets.ts +0 -25
- package/src/constants/campaign.ts +0 -4
- package/src/constants/chart.ts +0 -17
- package/src/constants/currency.ts +0 -3
- package/src/constants/index.ts +0 -6
- package/src/constants/thumbnail.ts +0 -3
- package/src/core/gemxql/api/index.ts +0 -2
- package/src/core/gemxql/api/useCustomGemXQlQuery.ts +0 -35
- package/src/core/gemxql/api/useGemxQlNamedQuery.ts +0 -34
- package/src/core/gemxql/builder/build-gemxql-query.ts +0 -81
- package/src/core/gemxql/builder/clauses/condition-query.ts +0 -74
- package/src/core/gemxql/builder/clauses/from-query.ts +0 -18
- package/src/core/gemxql/builder/clauses/group-query.ts +0 -43
- package/src/core/gemxql/builder/clauses/index.ts +0 -11
- package/src/core/gemxql/builder/clauses/limit-query.ts +0 -15
- package/src/core/gemxql/builder/clauses/mode-query.ts +0 -14
- package/src/core/gemxql/builder/clauses/offset-query.ts +0 -15
- package/src/core/gemxql/builder/clauses/order-by-query.ts +0 -37
- package/src/core/gemxql/builder/clauses/show-query.ts +0 -18
- package/src/core/gemxql/builder/clauses/time-query.ts +0 -67
- package/src/core/gemxql/builder/clauses/time-series-query.ts +0 -15
- package/src/core/gemxql/builder/clauses/timezone-query.ts +0 -17
- package/src/core/gemxql/builder/configs/date-formats.ts +0 -1
- package/src/core/gemxql/builder/configs/index.ts +0 -3
- package/src/core/gemxql/builder/configs/keywords.ts +0 -16
- package/src/core/gemxql/builder/configs/query-defaults.ts +0 -1
- package/src/core/gemxql/builder/filters/build-extra-conditions.ts +0 -69
- package/src/core/gemxql/builder/filters/build-filter-conditions.ts +0 -161
- package/src/core/gemxql/builder/filters/index.ts +0 -2
- package/src/core/gemxql/builder/helpers/date-query-helpers.ts +0 -41
- package/src/core/gemxql/builder/helpers/index.ts +0 -1
- package/src/core/gemxql/builder/helpers/is-valid-query-input.ts +0 -8
- package/src/core/gemxql/builder/index.ts +0 -6
- package/src/core/gemxql/builder/parse-gemxql-query.ts +0 -43
- package/src/core/gemxql/constants/analytic-data.ts +0 -2
- package/src/core/gemxql/constants/column-keys.ts +0 -4
- package/src/core/gemxql/constants/index.ts +0 -4
- package/src/core/gemxql/constants/operators.ts +0 -2
- package/src/core/gemxql/constants/row-reader-mode.ts +0 -9
- package/src/core/gemxql/graphql/fragments/gemxql.generated.ts +0 -80
- package/src/core/gemxql/graphql/fragments/gemxql.gql +0 -18
- package/src/core/gemxql/graphql/index.ts +0 -2
- package/src/core/gemxql/graphql/queries/gemxql.generated.ts +0 -26
- package/src/core/gemxql/graphql/queries/gemxql.gql +0 -5
- package/src/core/gemxql/helpers/columnKeys.ts +0 -8
- package/src/core/gemxql/helpers/extractQueryData.ts +0 -18
- package/src/core/gemxql/helpers/formatAnalyticData.ts +0 -92
- package/src/core/gemxql/helpers/formatAnalyticDate.ts +0 -29
- package/src/core/gemxql/helpers/getTimeDimension.ts +0 -11
- package/src/core/gemxql/helpers/hasMetricData.ts +0 -6
- package/src/core/gemxql/helpers/index.ts +0 -8
- package/src/core/gemxql/helpers/parseJsonFields.ts +0 -36
- package/src/core/gemxql/helpers/readNumeric.ts +0 -25
- package/src/core/gemxql/hooks/index.ts +0 -2
- package/src/core/gemxql/hooks/useAnalyticData.ts +0 -67
- package/src/core/gemxql/hooks/useGemXQlPagination.ts +0 -79
- package/src/core/gemxql/index.ts +0 -8
- package/src/core/gemxql/types/analytic-data.ts +0 -26
- package/src/core/gemxql/types/analytic-source.ts +0 -4
- package/src/core/gemxql/types/extra-condition.ts +0 -40
- package/src/core/gemxql/types/field-filters.ts +0 -18
- package/src/core/gemxql/types/field-operators.ts +0 -8
- package/src/core/gemxql/types/filter-types.ts +0 -33
- package/src/core/gemxql/types/group-with-clause.ts +0 -12
- package/src/core/gemxql/types/index.ts +0 -11
- package/src/core/gemxql/types/order-by.ts +0 -13
- package/src/core/gemxql/types/page-fields.ts +0 -25
- package/src/core/gemxql/types/row-reader-mode.ts +0 -6
- package/src/core/gemxql/types/time-dimension.ts +0 -8
- package/src/global.d.ts +0 -38
- package/src/hooks/index.ts +0 -7
- package/src/hooks/publish/index.ts +0 -2
- package/src/hooks/publish/useStickyDetectById.ts +0 -39
- package/src/hooks/publish/useStickyFilterBoxProps.ts +0 -26
- package/src/hooks/publish/useWindowSize.ts +0 -54
- package/src/hooks/useEnhancedEffect.ts +0 -3
- package/src/hooks/useFetchCurrencyRates.ts +0 -48
- package/src/hooks/useFormatLineChartData.ts +0 -28
- package/src/hooks/usePopoverResizeObserver.ts +0 -43
- package/src/hooks/usePreventBodyScroll.ts +0 -15
- package/src/hooks/useSearchParams.ts +0 -7
- package/src/hooks/useToggle.ts +0 -23
- package/src/index.ts +0 -10
- package/src/modules/analytics/constants/index.ts +0 -124
- package/src/modules/analytics/index.ts +0 -3
- package/src/modules/analytics/types/index.ts +0 -43
- package/src/modules/analytics/utils/formatMetric.ts +0 -42
- package/src/modules/analytics/utils/getPAMetricValue.ts +0 -11
- package/src/modules/analytics/utils/index.ts +0 -3
- package/src/modules/analytics/utils/metric.ts +0 -172
- package/src/providers/ConvertMoneyProvider.tsx +0 -68
- package/src/providers/MetricChartProvider.tsx +0 -50
- package/src/providers/TimezoneProvider.tsx +0 -31
- package/src/providers/index.ts +0 -5
- package/src/shared/charts/components/ComboChart.tsx +0 -108
- package/src/shared/charts/components/GBarChart.tsx +0 -96
- package/src/shared/charts/components/GComboChart.tsx +0 -15
- package/src/shared/charts/components/GDonutChart.tsx +0 -25
- package/src/shared/charts/components/GFunnelChart/GFunnelChart.tsx +0 -34
- package/src/shared/charts/components/GFunnelChart/components/FunnelChartAction.tsx +0 -67
- package/src/shared/charts/components/GFunnelChart/components/FunnelChartActionIcon.tsx +0 -60
- package/src/shared/charts/components/GFunnelChart/components/FunnelChartActionWrapper.tsx +0 -100
- package/src/shared/charts/components/GFunnelChart/components/FunnelSelection/FunnelSelectionContent.tsx +0 -92
- package/src/shared/charts/components/GFunnelChart/components/FunnelSelection/FunnelSelectionHeader.tsx +0 -54
- package/src/shared/charts/components/GFunnelChart/components/FunnelSelection/FunnelSelectionItem.tsx +0 -51
- package/src/shared/charts/components/GFunnelChart/components/FunnelSelection/FunnelSelectionPopover.tsx +0 -95
- package/src/shared/charts/components/GFunnelChart/components/FunnelSelection/index.ts +0 -1
- package/src/shared/charts/components/GFunnelChart/components/FunnelSelection/type.ts +0 -7
- package/src/shared/charts/components/GFunnelChart/components/types.ts +0 -24
- package/src/shared/charts/components/GFunnelChart/index.ts +0 -4
- package/src/shared/charts/components/GFunnelChart/types.ts +0 -11
- package/src/shared/charts/components/GPolarisViz/components/Arc/Arc.module.scss +0 -7
- package/src/shared/charts/components/GPolarisViz/components/Arc/Arc.tsx +0 -135
- package/src/shared/charts/components/GPolarisViz/components/Arc/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/ChartContainer/ChartContainer.module.scss +0 -39
- package/src/shared/charts/components/GPolarisViz/components/ChartContainer/ChartContainer.tsx +0 -150
- package/src/shared/charts/components/GPolarisViz/components/ChartContainer/hooks/useContainerBounds.ts +0 -113
- package/src/shared/charts/components/GPolarisViz/components/ChartContainer/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/ChartElements/ChartDiv.tsx +0 -18
- package/src/shared/charts/components/GPolarisViz/components/ChartElements/ChartElements.module.scss +0 -21
- package/src/shared/charts/components/GPolarisViz/components/ChartElements/ChartSVG.tsx +0 -40
- package/src/shared/charts/components/GPolarisViz/components/ChartElements/index.ts +0 -7
- package/src/shared/charts/components/GPolarisViz/components/ChartErrorBoundary/ChartErrorBoundary.tsx +0 -56
- package/src/shared/charts/components/GPolarisViz/components/ChartErrorBoundary/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/ChartErrorBoundary/utilities/checkForMismatchedData.ts +0 -34
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/ChartSkeleton.module.scss +0 -6
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/ChartSkeleton.tsx +0 -96
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/components/DonutSkeleton/DonutSkeleton.module.scss +0 -41
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/components/DonutSkeleton/DonutSkeleton.tsx +0 -193
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/components/DonutSkeleton/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/components/ErrorText/ErrorText.tsx +0 -40
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/components/ErrorText/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/components/FunnelSkeleton/FunnelSkeleton.tsx +0 -69
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/components/FunnelSkeleton/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/components/GridSkeleton/GridSkeleton.tsx +0 -155
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/components/GridSkeleton/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/components/Shimmer/Shimmer.module.scss +0 -33
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/components/Shimmer/Shimmer.tsx +0 -34
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/components/Shimmer/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/components/SimpleBarSkeleton/SimpleBarSkeleton.module.scss +0 -15
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/components/SimpleBarSkeleton/SimpleBarSkeleton.tsx +0 -53
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/components/SimpleBarSkeleton/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/components/SimpleNormalizedSkeleton/SimpleNormalizedSkeleton.module.scss +0 -35
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/components/SimpleNormalizedSkeleton/SimpleNormalizedSkeleton.tsx +0 -75
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/components/SimpleNormalizedSkeleton/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/components/SparkSkeleton/SparkSkeleton.tsx +0 -27
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/components/SparkSkeleton/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/components/index.ts +0 -8
- package/src/shared/charts/components/GPolarisViz/components/ChartSkeleton/index.ts +0 -9
- package/src/shared/charts/components/GPolarisViz/components/ConicGradientWithStops/ConicGradientWithStops.tsx +0 -27
- package/src/shared/charts/components/GPolarisViz/components/ConicGradientWithStops/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/DefaultPreview/DefaultPreview.module.scss +0 -8
- package/src/shared/charts/components/GPolarisViz/components/DefaultPreview/DefaultPreview.tsx +0 -25
- package/src/shared/charts/components/GPolarisViz/components/DefaultPreview/index.ts +0 -2
- package/src/shared/charts/components/GPolarisViz/components/FunnelChart/Chart.tsx +0 -209
- package/src/shared/charts/components/GPolarisViz/components/FunnelChart/FunnelChart.tsx +0 -72
- package/src/shared/charts/components/GPolarisViz/components/FunnelChart/components/FunnelChartXAxisArrows.tsx +0 -52
- package/src/shared/charts/components/GPolarisViz/components/FunnelChart/components/FunnelChartXAxisLabels.tsx +0 -66
- package/src/shared/charts/components/GPolarisViz/components/FunnelChart/components/FunnelSegment.tsx +0 -121
- package/src/shared/charts/components/GPolarisViz/components/FunnelChart/components/Label.module.scss +0 -23
- package/src/shared/charts/components/GPolarisViz/components/FunnelChart/components/Label.tsx +0 -67
- package/src/shared/charts/components/GPolarisViz/components/FunnelChart/components/index.ts +0 -4
- package/src/shared/charts/components/GPolarisViz/components/FunnelChart/index.ts +0 -2
- package/src/shared/charts/components/GPolarisViz/components/FunnelChartNext/Chart.tsx +0 -259
- package/src/shared/charts/components/GPolarisViz/components/FunnelChartNext/FunnelChartNext.tsx +0 -104
- package/src/shared/charts/components/GPolarisViz/components/FunnelChartNext/components/FunnelChartLabels/FunnelChartLabels.tsx +0 -387
- package/src/shared/charts/components/GPolarisViz/components/FunnelChartNext/components/FunnelChartLabels/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/FunnelChartNext/components/FunnelTooltip/FunnelTooltip.scss +0 -8
- package/src/shared/charts/components/GPolarisViz/components/FunnelChartNext/components/FunnelTooltip/FunnelTooltip.tsx +0 -37
- package/src/shared/charts/components/GPolarisViz/components/FunnelChartNext/components/FunnelTooltip/index.ts +0 -3
- package/src/shared/charts/components/GPolarisViz/components/FunnelChartNext/components/ScaleIcon.tsx +0 -20
- package/src/shared/charts/components/GPolarisViz/components/FunnelChartNext/components/ScaleIconTooltip.tsx +0 -31
- package/src/shared/charts/components/GPolarisViz/components/FunnelChartNext/components/Tooltip/CustomTooltip.tsx +0 -68
- package/src/shared/charts/components/GPolarisViz/components/FunnelChartNext/components/Tooltip/Tooltip.scss +0 -52
- package/src/shared/charts/components/GPolarisViz/components/FunnelChartNext/components/Tooltip/Tooltip.tsx +0 -149
- package/src/shared/charts/components/GPolarisViz/components/FunnelChartNext/components/Tooltip/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/FunnelChartNext/components/TooltipOverlay.tsx +0 -117
- package/src/shared/charts/components/GPolarisViz/components/FunnelChartNext/components/TooltipWithPortal.tsx +0 -12
- package/src/shared/charts/components/GPolarisViz/components/FunnelChartNext/components/index.ts +0 -8
- package/src/shared/charts/components/GPolarisViz/components/FunnelChartNext/constants.ts +0 -28
- package/src/shared/charts/components/GPolarisViz/components/FunnelChartNext/hooks/useTooltipInteraction.ts +0 -59
- package/src/shared/charts/components/GPolarisViz/components/FunnelChartNext/hooks/useTooltipPlacement.ts +0 -113
- package/src/shared/charts/components/GPolarisViz/components/FunnelChartNext/index.ts +0 -6
- package/src/shared/charts/components/GPolarisViz/components/FunnelChartNext/types.ts +0 -13
- package/src/shared/charts/components/GPolarisViz/components/FunnelChartNext/utilities/calculate-dropoff.ts +0 -4
- package/src/shared/charts/components/GPolarisViz/components/FunnelChartNext/utilities/useBuildFunnelTrends.ts +0 -108
- package/src/shared/charts/components/GPolarisViz/components/HorizontalGridLines/HorizontalGridLines.tsx +0 -27
- package/src/shared/charts/components/GPolarisViz/components/HorizontalGridLines/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/Labels/SingleTextLine.tsx +0 -64
- package/src/shared/charts/components/GPolarisViz/components/Labels/hooks/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/Labels/hooks/useLabels.tsx +0 -131
- package/src/shared/charts/components/GPolarisViz/components/Labels/index.ts +0 -3
- package/src/shared/charts/components/GPolarisViz/components/Labels/utilities/endLineTruncate.ts +0 -23
- package/src/shared/charts/components/GPolarisViz/components/Labels/utilities/endWordTruncate.ts +0 -34
- package/src/shared/charts/components/GPolarisViz/components/Labels/utilities/estimateTextHeight.ts +0 -31
- package/src/shared/charts/components/GPolarisViz/components/Labels/utilities/formatAndAddEllipsis.ts +0 -12
- package/src/shared/charts/components/GPolarisViz/components/Labels/utilities/getDiagonalLabels.ts +0 -70
- package/src/shared/charts/components/GPolarisViz/components/Labels/utilities/getHorizontalLabels.ts +0 -90
- package/src/shared/charts/components/GPolarisViz/components/Labels/utilities/getVerticalLabels.ts +0 -58
- package/src/shared/charts/components/GPolarisViz/components/Labels/utilities/getWidestLabel.ts +0 -15
- package/src/shared/charts/components/GPolarisViz/components/Labels/utilities/shouldSkipLabel.ts +0 -11
- package/src/shared/charts/components/GPolarisViz/components/Labels/utilities/tests/endWordTruncate.test.ts +0 -16
- package/src/shared/charts/components/GPolarisViz/components/Labels/utilities/tests/estimateTextHeight.test.ts +0 -19
- package/src/shared/charts/components/GPolarisViz/components/Labels/utilities/tests/formatAndAddEllipsis.test.ts +0 -9
- package/src/shared/charts/components/GPolarisViz/components/Labels/utilities/tests/truncateLastLine.test.ts +0 -22
- package/src/shared/charts/components/GPolarisViz/components/Labels/utilities/tests/truncateSingleLine.test.ts +0 -15
- package/src/shared/charts/components/GPolarisViz/components/Labels/utilities/truncateLabels.ts +0 -75
- package/src/shared/charts/components/GPolarisViz/components/Labels/utilities/truncateLastLine.ts +0 -61
- package/src/shared/charts/components/GPolarisViz/components/Labels/utilities/truncateSingleLine.ts +0 -39
- package/src/shared/charts/components/GPolarisViz/components/LinePreview/LinePreview.module.scss +0 -8
- package/src/shared/charts/components/GPolarisViz/components/LinePreview/LinePreview.tsx +0 -105
- package/src/shared/charts/components/GPolarisViz/components/LinePreview/constants.ts +0 -3
- package/src/shared/charts/components/GPolarisViz/components/LinePreview/index.ts +0 -2
- package/src/shared/charts/components/GPolarisViz/components/SwallowErrors/SwallowErrors.tsx +0 -32
- package/src/shared/charts/components/GPolarisViz/components/SwallowErrors/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/TextLine/TextLine.tsx +0 -88
- package/src/shared/charts/components/GPolarisViz/components/TextLine/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/TooltipContent/TooltipContent.tsx +0 -109
- package/src/shared/charts/components/GPolarisViz/components/TooltipContent/components/TooltipContentContainer/TooltipContentContainer.module.scss +0 -10
- package/src/shared/charts/components/GPolarisViz/components/TooltipContent/components/TooltipContentContainer/TooltipContentContainer.tsx +0 -67
- package/src/shared/charts/components/GPolarisViz/components/TooltipContent/components/TooltipContentContainer/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/TooltipContent/components/TooltipRow/TooltipRow.module.scss +0 -26
- package/src/shared/charts/components/GPolarisViz/components/TooltipContent/components/TooltipRow/TooltipRow.tsx +0 -57
- package/src/shared/charts/components/GPolarisViz/components/TooltipContent/components/TooltipRow/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/TooltipContent/components/TooltipSeries/TooltipSeries.module.scss +0 -4
- package/src/shared/charts/components/GPolarisViz/components/TooltipContent/components/TooltipSeries/TooltipSeries.tsx +0 -26
- package/src/shared/charts/components/GPolarisViz/components/TooltipContent/components/TooltipSeries/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/TooltipContent/components/TooltipSeriesName/TooltipSeriesName.module.scss +0 -4
- package/src/shared/charts/components/GPolarisViz/components/TooltipContent/components/TooltipSeriesName/TooltipSeriesName.tsx +0 -20
- package/src/shared/charts/components/GPolarisViz/components/TooltipContent/components/TooltipSeriesName/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/TooltipContent/components/TooltipTitle/TooltipTitle.module.scss +0 -7
- package/src/shared/charts/components/GPolarisViz/components/TooltipContent/components/TooltipTitle/TooltipTitle.tsx +0 -15
- package/src/shared/charts/components/GPolarisViz/components/TooltipContent/components/TooltipTitle/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/TooltipContent/components/index.ts +0 -5
- package/src/shared/charts/components/GPolarisViz/components/TooltipContent/constants.ts +0 -2
- package/src/shared/charts/components/GPolarisViz/components/TooltipContent/hooks/useGetLongestLabelFromData.ts +0 -56
- package/src/shared/charts/components/GPolarisViz/components/TooltipContent/index.ts +0 -4
- package/src/shared/charts/components/GPolarisViz/components/TooltipContent/utilities/get-tooltip-template-content-column-count.ts +0 -10
- package/src/shared/charts/components/GPolarisViz/components/TooltipContent/utilities/tests/get-tooltip-template-content-column-count.test.ts +0 -48
- package/src/shared/charts/components/GPolarisViz/components/TooltipWrapper/TooltipWrapper.tsx +0 -338
- package/src/shared/charts/components/GPolarisViz/components/TooltipWrapper/components/TooltipAnimatedContainer.module.scss +0 -6
- package/src/shared/charts/components/GPolarisViz/components/TooltipWrapper/components/TooltipAnimatedContainer.tsx +0 -139
- package/src/shared/charts/components/GPolarisViz/components/TooltipWrapper/constants.ts +0 -18
- package/src/shared/charts/components/GPolarisViz/components/TooltipWrapper/index.ts +0 -5
- package/src/shared/charts/components/GPolarisViz/components/TooltipWrapper/types.ts +0 -62
- package/src/shared/charts/components/GPolarisViz/components/TooltipWrapper/utilities/eventPoint.ts +0 -84
- package/src/shared/charts/components/GPolarisViz/components/TooltipWrapper/utilities/getAlteredHorizontalBarPosition.ts +0 -110
- package/src/shared/charts/components/GPolarisViz/components/TooltipWrapper/utilities/getAlteredLineChartPosition.ts +0 -115
- package/src/shared/charts/components/GPolarisViz/components/TooltipWrapper/utilities/getAlteredVerticalBarPosition.ts +0 -105
- package/src/shared/charts/components/GPolarisViz/components/TooltipWrapper/utilities/getDonutChartTooltipPosition.ts +0 -64
- package/src/shared/charts/components/GPolarisViz/components/TooltipWrapper/utilities/getHorizontalBarChartTooltipPosition.ts +0 -79
- package/src/shared/charts/components/GPolarisViz/components/TooltipWrapper/utilities/getLineChartTooltipPosition.ts +0 -68
- package/src/shared/charts/components/GPolarisViz/components/TooltipWrapper/utilities/getVerticalBarChartTooltipPosition.ts +0 -123
- package/src/shared/charts/components/GPolarisViz/components/TooltipWrapper/utilities/shouldBlockTooltipEvents.ts +0 -6
- package/src/shared/charts/components/GPolarisViz/components/TooltipWrapper/utilities.ts +0 -162
- package/src/shared/charts/components/GPolarisViz/components/TrendIndicator/TrendIndicator.tsx +0 -72
- package/src/shared/charts/components/GPolarisViz/components/TrendIndicator/components/Arrows/ArrowDown.tsx +0 -12
- package/src/shared/charts/components/GPolarisViz/components/TrendIndicator/components/Arrows/ArrowUp.tsx +0 -12
- package/src/shared/charts/components/GPolarisViz/components/TrendIndicator/components/Arrows/index.ts +0 -2
- package/src/shared/charts/components/GPolarisViz/components/TrendIndicator/components/Svg/Svg.scss +0 -7
- package/src/shared/charts/components/GPolarisViz/components/TrendIndicator/components/Svg/Svg.tsx +0 -27
- package/src/shared/charts/components/GPolarisViz/components/TrendIndicator/components/Svg/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/TrendIndicator/components/index.ts +0 -2
- package/src/shared/charts/components/GPolarisViz/components/TrendIndicator/constants.ts +0 -12
- package/src/shared/charts/components/GPolarisViz/components/TrendIndicator/index.ts +0 -6
- package/src/shared/charts/components/GPolarisViz/components/TrendIndicator/utilities/estimateTrendIndicatorWidth.ts +0 -9
- package/src/shared/charts/components/GPolarisViz/components/VerticalBarChart/utilities/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/VerticalBarChart/utilities/sortBarChartData.ts +0 -20
- package/src/shared/charts/components/GPolarisViz/components/VerticalGridLines/VerticalGridLines.tsx +0 -32
- package/src/shared/charts/components/GPolarisViz/components/VerticalGridLines/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/components/index.ts +0 -6
- package/src/shared/charts/components/GPolarisViz/constants.ts +0 -72
- package/src/shared/charts/components/GPolarisViz/data/character-width-offsets.json +0 -65
- package/src/shared/charts/components/GPolarisViz/data/character-widths.json +0 -1
- package/src/shared/charts/components/GPolarisViz/hooks/index.ts +0 -5
- package/src/shared/charts/components/GPolarisViz/hooks/useBarSpringConfig.ts +0 -21
- package/src/shared/charts/components/GPolarisViz/hooks/useBrowserCheck.ts +0 -13
- package/src/shared/charts/components/GPolarisViz/hooks/useCallbackRef.tsx +0 -39
- package/src/shared/charts/components/GPolarisViz/hooks/useDataForHorizontalChart.ts +0 -69
- package/src/shared/charts/components/GPolarisViz/hooks/useDebouncedCallback.ts +0 -197
- package/src/shared/charts/components/GPolarisViz/hooks/useFormattedLabels.ts +0 -31
- package/src/shared/charts/components/GPolarisViz/hooks/useFunnelBarScaling.ts +0 -53
- package/src/shared/charts/components/GPolarisViz/hooks/useHorizontalBarSizes.ts +0 -70
- package/src/shared/charts/components/GPolarisViz/hooks/useHorizontalStackedValues.ts +0 -34
- package/src/shared/charts/components/GPolarisViz/hooks/useHorizontalTicksAndScale.ts +0 -67
- package/src/shared/charts/components/GPolarisViz/hooks/useHorizontalXScale.ts +0 -48
- package/src/shared/charts/components/GPolarisViz/hooks/useIndexForLabels.ts +0 -16
- package/src/shared/charts/components/GPolarisViz/hooks/usePrefersReducedMotion.ts +0 -6
- package/src/shared/charts/components/GPolarisViz/hooks/usePrintResizing.ts +0 -94
- package/src/shared/charts/components/GPolarisViz/hooks/useReducedLabelIndexes.ts +0 -21
- package/src/shared/charts/components/GPolarisViz/hooks/useResizeObserver.ts +0 -39
- package/src/shared/charts/components/GPolarisViz/hooks/useRootContainer.ts +0 -20
- package/src/shared/charts/components/GPolarisViz/hooks/useWatchColorVisionEvents.tsx +0 -35
- package/src/shared/charts/components/GPolarisViz/index.ts +0 -10
- package/src/shared/charts/components/GPolarisViz/shared/Bar/Bar.tsx +0 -89
- package/src/shared/charts/components/GPolarisViz/shared/Bar/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/shared/FunnelChartConnector/FunnelChartConnector.tsx +0 -46
- package/src/shared/charts/components/GPolarisViz/shared/FunnelChartConnector/FunnelChartConnectorGradient.tsx +0 -21
- package/src/shared/charts/components/GPolarisViz/shared/FunnelChartConnector/constants.ts +0 -11
- package/src/shared/charts/components/GPolarisViz/shared/FunnelChartConnector/index.ts +0 -3
- package/src/shared/charts/components/GPolarisViz/shared/FunnelChartSegment/FunnelChartSegment.tsx +0 -100
- package/src/shared/charts/components/GPolarisViz/shared/FunnelChartSegment/components/AnimatedSegment.tsx +0 -50
- package/src/shared/charts/components/GPolarisViz/shared/FunnelChartSegment/components/InteractiveOverlay.tsx +0 -34
- package/src/shared/charts/components/GPolarisViz/shared/FunnelChartSegment/components/ScaledSegment.tsx +0 -218
- package/src/shared/charts/components/GPolarisViz/shared/FunnelChartSegment/constants.ts +0 -4
- package/src/shared/charts/components/GPolarisViz/shared/FunnelChartSegment/index.ts +0 -2
- package/src/shared/charts/components/GPolarisViz/shared/SeriesIcon/SeriesIcon.tsx +0 -22
- package/src/shared/charts/components/GPolarisViz/shared/SeriesIcon/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/shared/ZeroValueLine/ZeroValueLine.tsx +0 -45
- package/src/shared/charts/components/GPolarisViz/shared/ZeroValueLine/index.ts +0 -1
- package/src/shared/charts/components/GPolarisViz/shared/index.ts +0 -3
- package/src/shared/charts/components/GPolarisViz/styles/_common.scss +0 -15
- package/src/shared/charts/components/GPolarisViz/styles/shared/_accessibility.scss +0 -41
- package/src/shared/charts/components/GPolarisViz/styles/shared/_chart-container.scss +0 -8
- package/src/shared/charts/components/GPolarisViz/styles/shared/_variables.scss +0 -322
- package/src/shared/charts/components/GPolarisViz/types.ts +0 -261
- package/src/shared/charts/components/GPolarisViz/utilities/base.ts +0 -13
- package/src/shared/charts/components/GPolarisViz/utilities/classnames.ts +0 -3
- package/src/shared/charts/components/GPolarisViz/utilities/createCssConicGradient.ts +0 -12
- package/src/shared/charts/components/GPolarisViz/utilities/createCssGradient.ts +0 -7
- package/src/shared/charts/components/GPolarisViz/utilities/estimateStringWidthWithOffset.ts +0 -15
- package/src/shared/charts/components/GPolarisViz/utilities/getAxisOptions.ts +0 -26
- package/src/shared/charts/components/GPolarisViz/utilities/getCSSBackgroundFromColor.ts +0 -8
- package/src/shared/charts/components/GPolarisViz/utilities/getChartId.ts +0 -3
- package/src/shared/charts/components/GPolarisViz/utilities/getFontSize.ts +0 -7
- package/src/shared/charts/components/GPolarisViz/utilities/getStackedMinMax.ts +0 -43
- package/src/shared/charts/components/GPolarisViz/utilities/getStackedValues.ts +0 -35
- package/src/shared/charts/components/GPolarisViz/utilities/getStackedValuesFromDataSeries.tsx +0 -30
- package/src/shared/charts/components/GPolarisViz/utilities/getTrendIndicatorData.ts +0 -22
- package/src/shared/charts/components/GPolarisViz/utilities/hasHiddenComparisonSeries.ts +0 -26
- package/src/shared/charts/components/GPolarisViz/utilities/index.ts +0 -6
- package/src/shared/charts/components/GSimpleBarChart.tsx +0 -32
- package/src/shared/charts/components/index.ts +0 -7
- package/src/shared/charts/constants/chart.ts +0 -14
- package/src/shared/charts/constants/index.ts +0 -1
- package/src/shared/charts/contexts/GChartProvider.tsx +0 -48
- package/src/shared/charts/contexts/index.ts +0 -1
- package/src/shared/charts/index.ts +0 -4
- package/src/shared/charts/types/chart.ts +0 -36
- package/src/shared/charts/types/index.ts +0 -1
- package/src/shared/components/GActivatorPopover/GActivatorPopover.tsx +0 -107
- package/src/shared/components/GActivatorPopover/index.ts +0 -1
- package/src/shared/components/GBlockCenter/GBlockCenter.scss +0 -19
- package/src/shared/components/GBlockCenter/GBlockCenter.tsx +0 -72
- package/src/shared/components/GBlockCenter/index.ts +0 -1
- package/src/shared/components/GBox/GBox.scss +0 -25
- package/src/shared/components/GBox/GBox.tsx +0 -15
- package/src/shared/components/GBox/index.ts +0 -1
- package/src/shared/components/GBoxCard/GBoxCard.tsx +0 -27
- package/src/shared/components/GBoxCard/index.ts +0 -1
- package/src/shared/components/GButton/GButton.scss +0 -41
- package/src/shared/components/GButton/GButton.tsx +0 -73
- package/src/shared/components/GButton/index.ts +0 -1
- package/src/shared/components/GCheckbox/GCheckbox.tsx +0 -176
- package/src/shared/components/GCheckbox/index.ts +0 -1
- package/src/shared/components/GChoice/ChoiceHelpText.tsx +0 -25
- package/src/shared/components/GChoice/GChoice.scss +0 -14
- package/src/shared/components/GChoice/GChoice.tsx +0 -165
- package/src/shared/components/GChoice/index.ts +0 -2
- package/src/shared/components/GClickable/GClickable.tsx +0 -43
- package/src/shared/components/GClickable/index.ts +0 -1
- package/src/shared/components/GDiv/GDiv.tsx +0 -27
- package/src/shared/components/GDiv/index.ts +0 -1
- package/src/shared/components/GDotInline/GDotInline.tsx +0 -20
- package/src/shared/components/GDotInline/index.ts +0 -1
- package/src/shared/components/GFeatureLocked/GFeatureLocked.tsx +0 -85
- package/src/shared/components/GFeatureLocked/assets/images/empty-analytics.png +0 -0
- package/src/shared/components/GFeatureLocked/assets/images/empty-campaign-group-template-illustration.png +0 -0
- package/src/shared/components/GFeatureLocked/assets/images/empty-campaign-group-template.png +0 -0
- package/src/shared/components/GFeatureLocked/assets/images/empty-page-listing-illustration.png +0 -0
- package/src/shared/components/GFeatureLocked/assets/images/empty-page-listing.png +0 -0
- package/src/shared/components/GFeatureLocked/constants.ts +0 -33
- package/src/shared/components/GFeatureLocked/index.ts +0 -2
- package/src/shared/components/GFeatureLocked/types.ts +0 -16
- package/src/shared/components/GI18NText/GI18NText.tsx +0 -37
- package/src/shared/components/GI18NText/index.ts +0 -2
- package/src/shared/components/GI18NText/types.ts +0 -7
- package/src/shared/components/GInlineCenter/GInlineCenter.scss +0 -17
- package/src/shared/components/GInlineCenter/GInlineCenter.tsx +0 -39
- package/src/shared/components/GInlineCenter/index.ts +0 -1
- package/src/shared/components/GMockDataTooltip/GMockDataTooltip.tsx +0 -30
- package/src/shared/components/GMockDataTooltip/index.ts +0 -1
- package/src/shared/components/GModal/GModal.tsx +0 -49
- package/src/shared/components/GModal/index.ts +0 -1
- package/src/shared/components/GOptionList/GOptionList.tsx +0 -63
- package/src/shared/components/GOptionList/index.ts +0 -1
- package/src/shared/components/GPagination/GPagination.tsx +0 -44
- package/src/shared/components/GPagination/hooks/useGPagination.ts +0 -42
- package/src/shared/components/GPagination/index.ts +0 -2
- package/src/shared/components/GSelector/GSelector.tsx +0 -198
- package/src/shared/components/GSelector/index.ts +0 -1
- package/src/shared/components/GSkeletonDisplayText/GSkeletonDisplayText.tsx +0 -14
- package/src/shared/components/GSkeletonDisplayText/index.ts +0 -1
- package/src/shared/components/GSpinner/GSpinner.tsx +0 -16
- package/src/shared/components/GSpinner/index.ts +0 -1
- package/src/shared/components/GTextLink/GTextLink.tsx +0 -26
- package/src/shared/components/GTextLink/index.ts +0 -1
- package/src/shared/components/GTextTooltip/GTextTooltip.tsx +0 -18
- package/src/shared/components/GTextTooltip/index.ts +0 -1
- package/src/shared/components/GTextTruncated/GTextTruncated.tsx +0 -80
- package/src/shared/components/GTextTruncated/index.ts +0 -1
- package/src/shared/components/GThumbnail/GThumbnail.scss +0 -5
- package/src/shared/components/GThumbnail/GThumbnail.tsx +0 -69
- package/src/shared/components/GThumbnail/index.ts +0 -1
- package/src/shared/components/GTooltip/GTooltip.tsx +0 -34
- package/src/shared/components/GTooltip/components/GTooltipCard.tsx +0 -164
- package/src/shared/components/GTooltip/index.ts +0 -3
- package/src/shared/components/GTooltipCard/GTooltipCard.tsx +0 -161
- package/src/shared/components/GTooltipCard/index.ts +0 -7
- package/src/shared/components/GVariantBadge/GVariant.tsx +0 -55
- package/src/shared/components/GVariantBadge/GVariantBadge.scss +0 -10
- package/src/shared/components/GVariantBadge/GVariantBadge.tsx +0 -82
- package/src/shared/components/GVariantBadge/index.ts +0 -4
- package/src/shared/components/GVariantBadge/types.ts +0 -20
- package/src/shared/components/GViewBySelector/GViewBySelector.tsx +0 -114
- package/src/shared/components/GViewBySelector/index.ts +0 -1
- package/src/shared/components/index.ts +0 -26
- package/src/shared/index.ts +0 -1
- package/src/shared/journey/common/JourneyContainer/components/JourneyContainer.tsx +0 -140
- package/src/shared/journey/common/JourneyContainer/components/JourneyTimeline.tsx +0 -18
- package/src/shared/journey/common/JourneyContainer/components/index.ts +0 -2
- package/src/shared/journey/common/JourneyContainer/index.ts +0 -1
- package/src/shared/journey/common/index.ts +0 -1
- package/src/shared/journey/index.ts +0 -2
- package/src/shared/journey/ui/JourneyEvents/components/AcceptedPostPurchaseOffer/AcceptedPostPurchaseOffer.tsx +0 -24
- package/src/shared/journey/ui/JourneyEvents/components/AcceptedPostPurchaseOffer/index.ts +0 -1
- package/src/shared/journey/ui/JourneyEvents/components/CheckoutCompleted/CheckoutCompleted.tsx +0 -64
- package/src/shared/journey/ui/JourneyEvents/components/CheckoutCompleted/index.ts +0 -1
- package/src/shared/journey/ui/JourneyEvents/components/CheckoutItems.tsx +0 -27
- package/src/shared/journey/ui/JourneyEvents/components/CheckoutStarted/CheckoutStarted.tsx +0 -25
- package/src/shared/journey/ui/JourneyEvents/components/CheckoutStarted/CheckoutStartedDetail.tsx +0 -79
- package/src/shared/journey/ui/JourneyEvents/components/CheckoutStarted/index.ts +0 -2
- package/src/shared/journey/ui/JourneyEvents/components/PageViewed/PageViewed.tsx +0 -116
- package/src/shared/journey/ui/JourneyEvents/components/PageViewed/index.ts +0 -1
- package/src/shared/journey/ui/JourneyEvents/components/ProductAddedToCart/ProductAddedToCart.tsx +0 -24
- package/src/shared/journey/ui/JourneyEvents/components/ProductAddedToCart/index.ts +0 -1
- package/src/shared/journey/ui/JourneyEvents/components/ProductQuantity/ProductQuantity.tsx +0 -33
- package/src/shared/journey/ui/JourneyEvents/components/ProductQuantity/index.ts +0 -1
- package/src/shared/journey/ui/JourneyEvents/components/ProductRemovedFromCart/ProductRemovedFromCart.tsx +0 -24
- package/src/shared/journey/ui/JourneyEvents/components/ProductRemovedFromCart/index.ts +0 -1
- package/src/shared/journey/ui/JourneyEvents/components/index.ts +0 -6
- package/src/shared/journey/ui/JourneyEvents/constants/event.ts +0 -38
- package/src/shared/journey/ui/JourneyEvents/constants/index.ts +0 -1
- package/src/shared/journey/ui/JourneyEvents/index.ts +0 -2
- package/src/shared/journey/ui/JourneyEvents/types.ts +0 -2
- package/src/shared/journey/ui/JourneyGroup/JourneyGroup.tsx +0 -41
- package/src/shared/journey/ui/JourneyGroup/index.ts +0 -1
- package/src/shared/journey/ui/JourneyItem/components/EventMarkerIcon.tsx +0 -28
- package/src/shared/journey/ui/JourneyItem/components/JourneyDetail.tsx +0 -24
- package/src/shared/journey/ui/JourneyItem/components/JourneyItem.tsx +0 -27
- package/src/shared/journey/ui/JourneyItem/components/JourneyTime.tsx +0 -33
- package/src/shared/journey/ui/JourneyItem/components/QuantityWrapper.tsx +0 -17
- package/src/shared/journey/ui/JourneyItem/components/index.ts +0 -3
- package/src/shared/journey/ui/JourneyItem/index.ts +0 -2
- package/src/shared/journey/ui/JourneyItem/types/events.ts +0 -33
- package/src/shared/journey/ui/JourneyItem/types/index.ts +0 -1
- package/src/shared/journey/ui/JourneyTitle/components/GemxIdBadge.tsx +0 -38
- package/src/shared/journey/ui/JourneyTitle/components/JourneyDateBadge.tsx +0 -18
- package/src/shared/journey/ui/JourneyTitle/components/JourneyIdBadge.tsx +0 -65
- package/src/shared/journey/ui/JourneyTitle/components/JourneyLoadMore.tsx +0 -43
- package/src/shared/journey/ui/JourneyTitle/components/JourneyTitle.tsx +0 -42
- package/src/shared/journey/ui/JourneyTitle/components/index.ts +0 -2
- package/src/shared/journey/ui/JourneyTitle/constants/idBadge.ts +0 -1
- package/src/shared/journey/ui/JourneyTitle/constants/index.ts +0 -1
- package/src/shared/journey/ui/JourneyTitle/index.ts +0 -1
- package/src/shared/journey/ui/index.ts +0 -3
- package/src/shared/journey/ui/type.ts +0 -2
- package/src/shared/reports/common/Visualization/constants/columns.ts +0 -6
- package/src/shared/reports/common/Visualization/constants/index.ts +0 -2
- package/src/shared/reports/common/Visualization/constants/version.ts +0 -8
- package/src/shared/reports/common/Visualization/index.ts +0 -2
- package/src/shared/reports/common/Visualization/types/chart.ts +0 -5
- package/src/shared/reports/common/Visualization/types/index.ts +0 -3
- package/src/shared/reports/common/Visualization/types/report-metric.ts +0 -21
- package/src/shared/reports/common/Visualization/types/report.ts +0 -42
- package/src/shared/reports/common/Visualization/utils/index.ts +0 -2
- package/src/shared/reports/common/Visualization/utils/version.ts +0 -9
- package/src/shared/reports/common/Visualization/utils/visualization.ts +0 -58
- package/src/shared/reports/common/index.ts +0 -1
- package/src/shared/reports/ui/ReportTable/ReportTable.tsx +0 -194
- package/src/shared/reports/ui/ReportTable/ReportTableSkeleton.tsx +0 -73
- package/src/shared/reports/ui/ReportTable/assets/styles/ReportTable.scss +0 -288
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/CampaignsCell/CampaignsCell.tsx +0 -102
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/CampaignsCell/CampaignsCellVersion.tsx +0 -11
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/CampaignsCell/index.ts +0 -1
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/Cell.tsx +0 -93
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/CellRenderers.tsx +0 -72
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/DateCell.tsx +0 -9
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/DefaultCell.tsx +0 -32
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/GemxIdCell.tsx +0 -18
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/ItemsCell/CheckoutStartedDetail.tsx +0 -79
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/ItemsCell/ItemsCell.tsx +0 -56
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/ItemsCell/index.ts +0 -1
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/NoneCell.tsx +0 -11
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/OrderCell/LoadingData.tsx +0 -10
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/OrderCell/NoData.tsx +0 -13
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/OrderCell/OrderCell.tsx +0 -78
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/OrderCell/OrderCellBase.tsx +0 -55
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/OrderCell/OrderCellContainer.tsx +0 -43
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/OrderCell/OrderItem.tsx +0 -79
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/OrderCell/index.ts +0 -2
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/OrderIdCell.tsx +0 -70
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/PreviousCell.tsx +0 -17
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/TotalCell.tsx +0 -14
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/VersionCell.tsx +0 -31
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/WrapperCell.tsx +0 -31
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/index.ts +0 -1
- package/src/shared/reports/ui/ReportTable/components/Body/Cell/type.ts +0 -18
- package/src/shared/reports/ui/ReportTable/components/Body/Row.tsx +0 -85
- package/src/shared/reports/ui/ReportTable/components/Body/index.ts +0 -2
- package/src/shared/reports/ui/ReportTable/components/Footer/Pagination.tsx +0 -76
- package/src/shared/reports/ui/ReportTable/components/Footer/ScrollBar.tsx +0 -19
- package/src/shared/reports/ui/ReportTable/components/Footer/WrapperFooter.tsx +0 -39
- package/src/shared/reports/ui/ReportTable/components/Footer/index.ts +0 -1
- package/src/shared/reports/ui/ReportTable/components/Header/Header.tsx +0 -68
- package/src/shared/reports/ui/ReportTable/components/Header/SortableHeader.tsx +0 -49
- package/src/shared/reports/ui/ReportTable/components/Header/SortableHeaderWithTooltip.tsx +0 -60
- package/src/shared/reports/ui/ReportTable/components/Header/SummaryCell.tsx +0 -26
- package/src/shared/reports/ui/ReportTable/components/Header/SummaryRow.tsx +0 -69
- package/src/shared/reports/ui/ReportTable/components/Header/WrapperHeader.tsx +0 -54
- package/src/shared/reports/ui/ReportTable/components/Header/index.ts +0 -1
- package/src/shared/reports/ui/ReportTable/components/index.ts +0 -2
- package/src/shared/reports/ui/ReportTable/constants/index.ts +0 -2
- package/src/shared/reports/ui/ReportTable/constants/order.ts +0 -30
- package/src/shared/reports/ui/ReportTable/constants/table.ts +0 -17
- package/src/shared/reports/ui/ReportTable/context/ReportTableActionsContext.tsx +0 -28
- package/src/shared/reports/ui/ReportTable/helpers/format.ts +0 -29
- package/src/shared/reports/ui/ReportTable/helpers/index.ts +0 -2
- package/src/shared/reports/ui/ReportTable/helpers/report.ts +0 -7
- package/src/shared/reports/ui/ReportTable/hooks/index.ts +0 -3
- package/src/shared/reports/ui/ReportTable/hooks/useReportTable.ts +0 -172
- package/src/shared/reports/ui/ReportTable/hooks/useReportTableCell.tsx +0 -28
- package/src/shared/reports/ui/ReportTable/hooks/useSyncedScroll.ts +0 -81
- package/src/shared/reports/ui/ReportTable/index.ts +0 -4
- package/src/shared/reports/ui/ReportTable/types/dimension.ts +0 -8
- package/src/shared/reports/ui/ReportTable/types/index.ts +0 -43
- package/src/shared/reports/ui/ReportTable/types/order.ts +0 -15
- package/src/shared/reports/ui/ReportTable/types/report-columns.ts +0 -11
- package/src/shared/reports/ui/ReportTable/utils/format.ts +0 -100
- package/src/shared/reports/ui/ReportTable/utils/index.ts +0 -2
- package/src/shared/reports/ui/ReportTable/utils/order.ts +0 -8
- package/src/shared/reports/ui/ReportTable/utils/table.ts +0 -19
- package/src/shared/reports/ui/ReportTable/utils/visualization.ts +0 -56
- package/src/shared/reports/ui/index.ts +0 -0
- package/src/stores/currencyRatesStore.ts +0 -13
- package/src/stores/index.ts +0 -2
- package/src/styles/index.scss +0 -9
- package/src/types/analytic-mode.ts +0 -5
- package/src/types/breakdown-items.ts +0 -21
- package/src/types/campaign.ts +0 -13
- package/src/types/chart.ts +0 -42
- package/src/types/currency.ts +0 -329
- package/src/types/index.ts +0 -8
- package/src/types/metric.ts +0 -81
- package/src/types/pricing.ts +0 -38
- package/src/types/report-columns.ts +0 -1
- package/src/types/template.ts +0 -19
- package/src/utils/analytics.ts +0 -75
- package/src/utils/array.ts +0 -13
- package/src/utils/cls.ts +0 -18
- package/src/utils/currency.ts +0 -42
- package/src/utils/date-time.ts +0 -7
- package/src/utils/dayjs.ts +0 -52
- package/src/utils/deep-copy.ts +0 -4
- package/src/utils/index.ts +0 -12
- package/src/utils/is-browser.ts +0 -3
- package/src/utils/number.ts +0 -19
- package/src/utils/percentage.ts +0 -40
- package/src/utils/sort.ts +0 -87
- package/src/utils/string.ts +0 -20
- package/src/utils/template-type.ts +0 -30
|
@@ -1,127 +0,0 @@
|
|
|
1
|
-
import type { GSelectorOption, GSelectorProps } from '@/shared';
|
|
2
|
-
import type { CurrencyCode } from '@/types';
|
|
3
|
-
|
|
4
|
-
import { GI18NText, GSelector, GTextLink } from '@/shared';
|
|
5
|
-
import { useCallback, useEffect, useMemo, useRef } from 'react';
|
|
6
|
-
import { DEFAULT_CURRENCY_ANALYTIC } from '@/constants';
|
|
7
|
-
import { CheckIcon } from '@shopify/polaris-icons';
|
|
8
|
-
import { Box, Icon, Text } from '@shopify/polaris';
|
|
9
|
-
import { useTranslation } from 'react-i18next';
|
|
10
|
-
import { sortByConditions } from '@/utils';
|
|
11
|
-
|
|
12
|
-
const EXCHANGE_RATE_HELP_URL =
|
|
13
|
-
'https://help.shopify.com/en/manual/international/pricing/exchange-rates#auto-convert';
|
|
14
|
-
|
|
15
|
-
export interface CurrencySelectorProps {
|
|
16
|
-
currencies?: CurrencyCode[];
|
|
17
|
-
selected?: CurrencyCode;
|
|
18
|
-
preferredAlignment?: GSelectorProps['preferredAlignment'];
|
|
19
|
-
activatorText?: string;
|
|
20
|
-
onSelect?: (value: CurrencyCode) => void;
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
export const CurrencySelector = ({
|
|
24
|
-
currencies,
|
|
25
|
-
selected,
|
|
26
|
-
preferredAlignment = 'left',
|
|
27
|
-
activatorText,
|
|
28
|
-
onSelect,
|
|
29
|
-
}: CurrencySelectorProps) => {
|
|
30
|
-
const { t } = useTranslation();
|
|
31
|
-
|
|
32
|
-
const onSelectRef = useRef(onSelect);
|
|
33
|
-
|
|
34
|
-
const handleSelection = useCallback((value: CurrencyCode) => {
|
|
35
|
-
onSelectRef.current?.(value);
|
|
36
|
-
}, []);
|
|
37
|
-
|
|
38
|
-
const actionItems = useMemo(() => {
|
|
39
|
-
if (!currencies) return [];
|
|
40
|
-
|
|
41
|
-
const formattedCurrencies = currencies.map((currency) => ({
|
|
42
|
-
content: currency,
|
|
43
|
-
id: currency,
|
|
44
|
-
}));
|
|
45
|
-
|
|
46
|
-
const hasCurrencyDefault = formattedCurrencies.some((item) => item.id === DEFAULT_CURRENCY_ANALYTIC);
|
|
47
|
-
if (!hasCurrencyDefault) {
|
|
48
|
-
formattedCurrencies.push({
|
|
49
|
-
content: DEFAULT_CURRENCY_ANALYTIC,
|
|
50
|
-
id: DEFAULT_CURRENCY_ANALYTIC,
|
|
51
|
-
});
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
return sortByConditions(formattedCurrencies, [
|
|
55
|
-
{ attr: 'content', order: 'asc', preferredValue: DEFAULT_CURRENCY_ANALYTIC },
|
|
56
|
-
]);
|
|
57
|
-
}, [currencies]);
|
|
58
|
-
|
|
59
|
-
const actionListItems: GSelectorOption[] = useMemo(() => {
|
|
60
|
-
return actionItems.map((option) => ({
|
|
61
|
-
id: option.id,
|
|
62
|
-
content: option.content,
|
|
63
|
-
onAction: () => handleSelection(option.id),
|
|
64
|
-
active: option.id === selected,
|
|
65
|
-
suffix: option.id === selected && <Icon source={CheckIcon} tone="success" />,
|
|
66
|
-
helpText: option.id === DEFAULT_CURRENCY_ANALYTIC && (
|
|
67
|
-
<Text as="p" fontWeight="semibold">
|
|
68
|
-
{t('Default')}
|
|
69
|
-
</Text>
|
|
70
|
-
),
|
|
71
|
-
}));
|
|
72
|
-
}, [actionItems, selected, handleSelection, t]);
|
|
73
|
-
|
|
74
|
-
const isHidden = useMemo(() => {
|
|
75
|
-
if (!actionItems?.length) return true;
|
|
76
|
-
|
|
77
|
-
return actionItems.length === 1 && actionItems[0]?.id === DEFAULT_CURRENCY_ANALYTIC;
|
|
78
|
-
}, [actionItems]);
|
|
79
|
-
|
|
80
|
-
useEffect(() => {
|
|
81
|
-
onSelectRef.current = onSelect;
|
|
82
|
-
});
|
|
83
|
-
|
|
84
|
-
if (isHidden) return null;
|
|
85
|
-
|
|
86
|
-
return (
|
|
87
|
-
<GSelector
|
|
88
|
-
options={actionListItems}
|
|
89
|
-
selected={selected}
|
|
90
|
-
variant="action-list"
|
|
91
|
-
// value originates from our CurrencyCode option ids, so the widen-to-string round trip is safe
|
|
92
|
-
onSelect={(value) => handleSelection(value as CurrencyCode)}
|
|
93
|
-
activatorText={activatorText ?? t('Currency')}
|
|
94
|
-
maxWidth="225px"
|
|
95
|
-
preferredAlignment={preferredAlignment}
|
|
96
|
-
helpText={
|
|
97
|
-
<Box
|
|
98
|
-
padding="200"
|
|
99
|
-
paddingBlockStart="300"
|
|
100
|
-
paddingBlockEnd="300"
|
|
101
|
-
borderColor="border-tertiary"
|
|
102
|
-
background={'bg'}
|
|
103
|
-
>
|
|
104
|
-
<GI18NText
|
|
105
|
-
as="p"
|
|
106
|
-
variant="bodyMd"
|
|
107
|
-
transformers={{
|
|
108
|
-
1: (text) => (
|
|
109
|
-
<GTextLink
|
|
110
|
-
key={text + 'text-link'}
|
|
111
|
-
linkAction={{
|
|
112
|
-
url: EXCHANGE_RATE_HELP_URL,
|
|
113
|
-
target: '_blank',
|
|
114
|
-
}}
|
|
115
|
-
>
|
|
116
|
-
{text}
|
|
117
|
-
</GTextLink>
|
|
118
|
-
),
|
|
119
|
-
}}
|
|
120
|
-
>
|
|
121
|
-
{t("This will follow Shopify's current exchange rate. [1]Read more[]")}
|
|
122
|
-
</GI18NText>
|
|
123
|
-
</Box>
|
|
124
|
-
}
|
|
125
|
-
></GSelector>
|
|
126
|
-
);
|
|
127
|
-
};
|
|
@@ -1,131 +0,0 @@
|
|
|
1
|
-
import type { IOrderJourneyItem, IOrderPageAnalytic, IReportCampaign } from '@/components/OrderAnalytic/types';
|
|
2
|
-
import type { IEventsByDate, IJourneyEvent } from '@/shared/journey/ui/type';
|
|
3
|
-
import type { EAnalyticMode } from '@/types';
|
|
4
|
-
|
|
5
|
-
import { EReportSource } from '@/components/OrderAnalytic/types';
|
|
6
|
-
import { usePreventBodyScroll } from '@/hooks';
|
|
7
|
-
import { GModal } from '@/shared';
|
|
8
|
-
import { JourneyContainer } from '@/shared/journey/common';
|
|
9
|
-
import { formatDateBy } from '@/utils';
|
|
10
|
-
import { useCallback, useEffect, useMemo, useState } from 'react';
|
|
11
|
-
import { OrderJourneySkeleton } from './components';
|
|
12
|
-
import { OrderJourneyProvider } from './context';
|
|
13
|
-
import { sliceJourneyItems } from './utils';
|
|
14
|
-
|
|
15
|
-
export interface GModalOrderJourneyProps {
|
|
16
|
-
open: boolean;
|
|
17
|
-
onClose: () => void;
|
|
18
|
-
title: string;
|
|
19
|
-
orderId: string;
|
|
20
|
-
gxId?: string;
|
|
21
|
-
journeyItems: IOrderJourneyItem[];
|
|
22
|
-
isLoading?: boolean;
|
|
23
|
-
hasNextPage?: boolean;
|
|
24
|
-
isFetchingNextPage?: boolean;
|
|
25
|
-
fetchNextPage?: () => void;
|
|
26
|
-
reportCampaign?: IReportCampaign;
|
|
27
|
-
pageAnalytic?: IOrderPageAnalytic;
|
|
28
|
-
mode: EAnalyticMode;
|
|
29
|
-
journeySource?: EReportSource;
|
|
30
|
-
onViewOrderDetails?: (orderId: string) => void;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
export const GModalOrderJourney = ({
|
|
34
|
-
open,
|
|
35
|
-
onClose,
|
|
36
|
-
title,
|
|
37
|
-
orderId,
|
|
38
|
-
gxId,
|
|
39
|
-
journeyItems,
|
|
40
|
-
isLoading = false,
|
|
41
|
-
hasNextPage = false,
|
|
42
|
-
isFetchingNextPage = false,
|
|
43
|
-
fetchNextPage,
|
|
44
|
-
reportCampaign,
|
|
45
|
-
pageAnalytic,
|
|
46
|
-
mode,
|
|
47
|
-
journeySource,
|
|
48
|
-
onViewOrderDetails,
|
|
49
|
-
}: GModalOrderJourneyProps) => {
|
|
50
|
-
const [isExpanded, setIsExpanded] = useState(false);
|
|
51
|
-
|
|
52
|
-
usePreventBodyScroll({ enable: open });
|
|
53
|
-
|
|
54
|
-
const source = useMemo(() => {
|
|
55
|
-
if (journeySource) return journeySource;
|
|
56
|
-
if (reportCampaign) return EReportSource.CAMPAIGN;
|
|
57
|
-
if (pageAnalytic) return EReportSource.PAGE;
|
|
58
|
-
}, [reportCampaign, pageAnalytic, journeySource]);
|
|
59
|
-
|
|
60
|
-
const filteredCampaignId = reportCampaign?.id;
|
|
61
|
-
|
|
62
|
-
const slicedJourneyItems = useMemo(() => {
|
|
63
|
-
if (!source) return journeyItems;
|
|
64
|
-
|
|
65
|
-
return sliceJourneyItems({
|
|
66
|
-
journeyItems,
|
|
67
|
-
mode,
|
|
68
|
-
source,
|
|
69
|
-
pageAnalytic,
|
|
70
|
-
filteredCampaignId,
|
|
71
|
-
});
|
|
72
|
-
}, [journeyItems, mode, source, pageAnalytic, filteredCampaignId]);
|
|
73
|
-
|
|
74
|
-
const isSliced = slicedJourneyItems.length < journeyItems.length;
|
|
75
|
-
const displayedItems = isExpanded ? journeyItems : slicedJourneyItems;
|
|
76
|
-
const hasMoreSteps = (!isExpanded && isSliced) || hasNextPage;
|
|
77
|
-
|
|
78
|
-
const handleLoadMore = useCallback(() => {
|
|
79
|
-
if (!isExpanded && isSliced) {
|
|
80
|
-
setIsExpanded(true);
|
|
81
|
-
return;
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
if (hasNextPage) {
|
|
85
|
-
// Stay expanded so fetched earlier steps aren't re-hidden by the slice
|
|
86
|
-
setIsExpanded(true);
|
|
87
|
-
fetchNextPage?.();
|
|
88
|
-
}
|
|
89
|
-
}, [isExpanded, isSliced, hasNextPage, fetchNextPage]);
|
|
90
|
-
|
|
91
|
-
const eventsByDate: IEventsByDate[] = useMemo(() => {
|
|
92
|
-
const grouped = new Map<string, IJourneyEvent[]>();
|
|
93
|
-
|
|
94
|
-
displayedItems?.forEach((journeyItem) => {
|
|
95
|
-
const dateKey = formatDateBy('MMMM D', journeyItem.date);
|
|
96
|
-
|
|
97
|
-
if (!grouped.has(dateKey)) grouped.set(dateKey, []);
|
|
98
|
-
grouped.get(dateKey)?.push(journeyItem as IJourneyEvent);
|
|
99
|
-
});
|
|
100
|
-
|
|
101
|
-
return Array.from(grouped.entries()).map(([date, events]) => ({
|
|
102
|
-
date,
|
|
103
|
-
dateKey: date,
|
|
104
|
-
events: events.map((event) => ({ ...event, filteredCampaignId })),
|
|
105
|
-
}));
|
|
106
|
-
}, [displayedItems, filteredCampaignId]);
|
|
107
|
-
|
|
108
|
-
useEffect(() => {
|
|
109
|
-
if (!open) setIsExpanded(false);
|
|
110
|
-
}, [open]);
|
|
111
|
-
|
|
112
|
-
if (!orderId) return null;
|
|
113
|
-
|
|
114
|
-
return (
|
|
115
|
-
<GModal open={open} title={title} onClose={onClose}>
|
|
116
|
-
<OrderJourneyProvider value={{ orderId, gxId, onViewOrderDetails }}>
|
|
117
|
-
{isLoading ? (
|
|
118
|
-
<OrderJourneySkeleton />
|
|
119
|
-
) : (
|
|
120
|
-
<JourneyContainer
|
|
121
|
-
orderId={orderId}
|
|
122
|
-
eventsByDate={eventsByDate}
|
|
123
|
-
hasMoreSteps={hasMoreSteps}
|
|
124
|
-
isFetchingMoreSteps={isFetchingNextPage}
|
|
125
|
-
onLoadMore={handleLoadMore}
|
|
126
|
-
/>
|
|
127
|
-
)}
|
|
128
|
-
</OrderJourneyProvider>
|
|
129
|
-
</GModal>
|
|
130
|
-
);
|
|
131
|
-
};
|
|
@@ -1,93 +0,0 @@
|
|
|
1
|
-
import { Box, InlineStack, Scrollable, SkeletonBodyText, SkeletonDisplayText } from '@shopify/polaris';
|
|
2
|
-
import { useWindowSize } from '@/hooks';
|
|
3
|
-
import { GBox } from '@/shared';
|
|
4
|
-
|
|
5
|
-
export const OrderJourneySkeleton = () => {
|
|
6
|
-
const { isMobileView } = useWindowSize();
|
|
7
|
-
|
|
8
|
-
return (
|
|
9
|
-
<Scrollable
|
|
10
|
-
scrollbarWidth="thin"
|
|
11
|
-
vertical
|
|
12
|
-
horizontal
|
|
13
|
-
className="pb-5"
|
|
14
|
-
style={{ height: isMobileView ? '100vh' : 'calc(100vh - 120px)' }}
|
|
15
|
-
>
|
|
16
|
-
{/* Sticky Header */}
|
|
17
|
-
<GBox position="sticky" insetBlockStart="0" zIndex="10" background="bg-fill">
|
|
18
|
-
<Box paddingBlock="300" paddingInline="400" position="relative">
|
|
19
|
-
<InlineStack align="space-between" gap="100">
|
|
20
|
-
<InlineStack gap="400">
|
|
21
|
-
{/* Date Badge Skeleton */}
|
|
22
|
-
<div className="bg-surface-secondary rounded-md px-3 py-1.5">
|
|
23
|
-
<div className="w-24">
|
|
24
|
-
<SkeletonBodyText lines={1} />
|
|
25
|
-
</div>
|
|
26
|
-
</div>
|
|
27
|
-
|
|
28
|
-
{/* Order ID Badge Skeleton */}
|
|
29
|
-
<div className="bg-surface-secondary rounded-md px-3 py-1.5">
|
|
30
|
-
<div className="w-40">
|
|
31
|
-
<SkeletonBodyText lines={1} />
|
|
32
|
-
</div>
|
|
33
|
-
</div>
|
|
34
|
-
</InlineStack>
|
|
35
|
-
</InlineStack>
|
|
36
|
-
|
|
37
|
-
{/* Title Line */}
|
|
38
|
-
<div className="absolute top-[50%] right-0 left-0 translate-y-[-50%] h-[1px] bg-border -z-[1]" />
|
|
39
|
-
</Box>
|
|
40
|
-
</GBox>
|
|
41
|
-
|
|
42
|
-
{/* Journey Events */}
|
|
43
|
-
<div className="relative mt-4">
|
|
44
|
-
{/* Timeline vertical line */}
|
|
45
|
-
<div className="w-[2px] absolute top-4 bottom-4 bg-[#F3F3F3] -z-[1]" style={{ left: 110 }} />
|
|
46
|
-
|
|
47
|
-
{/* Event Items */}
|
|
48
|
-
{Array.from({ length: 8 }).map((_, index) => (
|
|
49
|
-
<JourneyEventSkeleton key={index} isLast={index === 7} />
|
|
50
|
-
))}
|
|
51
|
-
</div>
|
|
52
|
-
</Scrollable>
|
|
53
|
-
);
|
|
54
|
-
};
|
|
55
|
-
|
|
56
|
-
const JourneyEventSkeleton = ({ isLast }: { isLast?: boolean }) => {
|
|
57
|
-
return (
|
|
58
|
-
<Box paddingInlineStart="600">
|
|
59
|
-
<InlineStack blockAlign="start" gap="400" wrap={false}>
|
|
60
|
-
{/* Time Skeleton */}
|
|
61
|
-
<div className="w-12 pt-1">
|
|
62
|
-
<SkeletonBodyText lines={1} />
|
|
63
|
-
</div>
|
|
64
|
-
|
|
65
|
-
{/* Event Marker Icon Skeleton */}
|
|
66
|
-
<div className="shrink-0 mt-0.5">
|
|
67
|
-
<div className="w-7 h-7 bg-border-secondary rounded-full animate-pulse" />
|
|
68
|
-
</div>
|
|
69
|
-
|
|
70
|
-
{/* Event Details Skeleton */}
|
|
71
|
-
<Box paddingBlockEnd="400" width="100%">
|
|
72
|
-
{/* Title Skeleton */}
|
|
73
|
-
<div className="mb-2">
|
|
74
|
-
<SkeletonDisplayText size="small" />
|
|
75
|
-
</div>
|
|
76
|
-
|
|
77
|
-
{/* Subtitle/Details Skeleton - Random variations for more realistic look */}
|
|
78
|
-
{/* TODO: switch to deterministic lines (e.g. index % 2) to fix SSR hydration mismatch / layout flicker.
|
|
79
|
-
Hold off until gemx app is synced to this SDK version, otherwise skeleton UI diverges between gemx app and GP. */}
|
|
80
|
-
{!isLast ? (
|
|
81
|
-
<div className="max-w-[70%]">
|
|
82
|
-
<SkeletonBodyText lines={Math.random() > 0.5 ? 1 : 2} />
|
|
83
|
-
</div>
|
|
84
|
-
) : (
|
|
85
|
-
<div className="max-w-[40%]">
|
|
86
|
-
<SkeletonBodyText lines={1} />
|
|
87
|
-
</div>
|
|
88
|
-
)}
|
|
89
|
-
</Box>
|
|
90
|
-
</InlineStack>
|
|
91
|
-
</Box>
|
|
92
|
-
);
|
|
93
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './OrderJourneySkeleton';
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { createContext, useContext } from 'react';
|
|
2
|
-
|
|
3
|
-
export interface OrderJourneyContextValue {
|
|
4
|
-
orderId: string;
|
|
5
|
-
gxId?: string;
|
|
6
|
-
onViewOrderDetails?: (orderId: string) => void;
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
const OrderJourneyContext = createContext<OrderJourneyContextValue | undefined>(undefined);
|
|
10
|
-
|
|
11
|
-
export const OrderJourneyProvider = OrderJourneyContext.Provider;
|
|
12
|
-
|
|
13
|
-
export const useOrderJourneyContext = (): OrderJourneyContextValue => {
|
|
14
|
-
const context = useContext(OrderJourneyContext);
|
|
15
|
-
if (!context) throw new Error('useOrderJourneyContext must be used within OrderJourneyProvider');
|
|
16
|
-
return context;
|
|
17
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './OrderJourneyContext';
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './useGModalOrderJourney';
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import type { GModalOrderJourneyInitialValues } from '../types';
|
|
2
|
-
|
|
3
|
-
import { useCallback, useState } from 'react';
|
|
4
|
-
|
|
5
|
-
export const useGModalOrderJourney = () => {
|
|
6
|
-
const [isOpen, setIsOpen] = useState(false);
|
|
7
|
-
const [initialValues, setInitialValues] = useState<GModalOrderJourneyInitialValues | null>(null);
|
|
8
|
-
|
|
9
|
-
const handleOpenModalOrderJourney = useCallback((data: GModalOrderJourneyInitialValues) => {
|
|
10
|
-
setInitialValues(data);
|
|
11
|
-
setIsOpen(true);
|
|
12
|
-
}, []);
|
|
13
|
-
|
|
14
|
-
const handleCloseModalOrderJourney = useCallback(() => {
|
|
15
|
-
setIsOpen(false);
|
|
16
|
-
setInitialValues(null);
|
|
17
|
-
}, []);
|
|
18
|
-
|
|
19
|
-
return {
|
|
20
|
-
isOpen,
|
|
21
|
-
initialValues,
|
|
22
|
-
handleOpenModalOrderJourney,
|
|
23
|
-
handleCloseModalOrderJourney,
|
|
24
|
-
};
|
|
25
|
-
};
|
|
@@ -1,75 +0,0 @@
|
|
|
1
|
-
import type { IOrderJourneyItem, IOrderPageAnalytic } from '@/components/OrderAnalytic/types';
|
|
2
|
-
|
|
3
|
-
import { EReportSource } from '@/components/OrderAnalytic/types';
|
|
4
|
-
import { findLastIndex } from '@/utils';
|
|
5
|
-
import { EAnalyticMode } from '@/types';
|
|
6
|
-
|
|
7
|
-
interface SliceJourneyItemsParams {
|
|
8
|
-
journeyItems: IOrderJourneyItem[];
|
|
9
|
-
mode: EAnalyticMode;
|
|
10
|
-
source: EReportSource;
|
|
11
|
-
filteredCampaignId?: string;
|
|
12
|
-
pageAnalytic?: IOrderPageAnalytic;
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
/**
|
|
16
|
-
* Slices journey items based on the analytic metric mode.
|
|
17
|
-
*
|
|
18
|
-
* - FIRST_SESSION: Returns all items (no slicing)
|
|
19
|
-
* - PAGE_ONLY: Slices from the LAST matching event (most recent relevant interaction)
|
|
20
|
-
* - ALL_SESSION: Slices from the FIRST matching event (entire journey from first interaction)
|
|
21
|
-
*/
|
|
22
|
-
export const sliceJourneyItems = ({
|
|
23
|
-
journeyItems,
|
|
24
|
-
mode,
|
|
25
|
-
source,
|
|
26
|
-
filteredCampaignId,
|
|
27
|
-
pageAnalytic,
|
|
28
|
-
}: SliceJourneyItemsParams): IOrderJourneyItem[] => {
|
|
29
|
-
if (mode === EAnalyticMode.FIRST_SESSION) return journeyItems;
|
|
30
|
-
|
|
31
|
-
const isCampaignVariant = ({ campaignGroupID = '', campaignID = '' }: IOrderJourneyItem) =>
|
|
32
|
-
!isCampaignOfAnother({ campaignGroupID: campaignGroupID ?? '', campaignID: campaignID ?? '', filteredCampaignId });
|
|
33
|
-
const isMatchingPage = ({ locationPath = '' }: IOrderJourneyItem) => locationPath === pageAnalytic?.path;
|
|
34
|
-
|
|
35
|
-
const sliceFromIndex = (index: number) => (index !== -1 ? journeyItems.slice(index) : journeyItems);
|
|
36
|
-
|
|
37
|
-
const predicate = source === EReportSource.CAMPAIGN ? isCampaignVariant : isMatchingPage;
|
|
38
|
-
|
|
39
|
-
// PAGE_ONLY: slice from LAST matching event (most recent relevant interaction)
|
|
40
|
-
if (mode === EAnalyticMode.PAGE_ONLY) {
|
|
41
|
-
return sliceFromIndex(findLastIndex(journeyItems, predicate));
|
|
42
|
-
}
|
|
43
|
-
|
|
44
|
-
// ALL_SESSION: slice from FIRST matching event (entire journey from first interaction)
|
|
45
|
-
if (mode === EAnalyticMode.ALL_SESSION) {
|
|
46
|
-
return sliceFromIndex(journeyItems.findIndex(predicate));
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
return journeyItems;
|
|
50
|
-
};
|
|
51
|
-
|
|
52
|
-
export const getEventCampaignIdByType = ({
|
|
53
|
-
campaignGroupID,
|
|
54
|
-
campaignID,
|
|
55
|
-
}: {
|
|
56
|
-
campaignGroupID: string;
|
|
57
|
-
campaignID: string;
|
|
58
|
-
}) => {
|
|
59
|
-
return campaignGroupID !== '0' ? campaignGroupID : campaignID;
|
|
60
|
-
};
|
|
61
|
-
|
|
62
|
-
export const isCampaignOfAnother = ({
|
|
63
|
-
campaignGroupID,
|
|
64
|
-
campaignID,
|
|
65
|
-
filteredCampaignId,
|
|
66
|
-
}: {
|
|
67
|
-
campaignGroupID: string;
|
|
68
|
-
campaignID: string;
|
|
69
|
-
filteredCampaignId?: string;
|
|
70
|
-
}) => {
|
|
71
|
-
const eventCampaignIdByType = getEventCampaignIdByType({ campaignGroupID, campaignID });
|
|
72
|
-
const isEventOfAnotherCampaign = filteredCampaignId && eventCampaignIdByType !== filteredCampaignId;
|
|
73
|
-
|
|
74
|
-
return isEventOfAnotherCampaign;
|
|
75
|
-
};
|
|
@@ -1,83 +0,0 @@
|
|
|
1
|
-
import type { ColumnTypesMap } from '@/core/gemxql';
|
|
2
|
-
import type { AllChartsDataMap, EMetricKey, IMetricCardItem } from '@/types';
|
|
3
|
-
import type { ReactElement } from 'react';
|
|
4
|
-
|
|
5
|
-
import { DEFAULT_CURRENT_PERIOD_LABEL, DEFAULT_PREVIOUS_PERIOD_LABEL } from '@/constants';
|
|
6
|
-
import { Card } from '@shopify/polaris';
|
|
7
|
-
import { useMemo, useState } from 'react';
|
|
8
|
-
import { MetricChart } from '../common/chart';
|
|
9
|
-
import { MetricChartTab } from './MetricChartTab';
|
|
10
|
-
|
|
11
|
-
export interface IProps {
|
|
12
|
-
metricInfo: IMetricCardItem[];
|
|
13
|
-
dataChart: AllChartsDataMap;
|
|
14
|
-
defaultActiveTab?: EMetricKey;
|
|
15
|
-
isLoading?: boolean;
|
|
16
|
-
isEmptyMetricData?: boolean;
|
|
17
|
-
hideComparison?: boolean;
|
|
18
|
-
currentPeriodLabel?: string;
|
|
19
|
-
previousPeriodLabel?: string;
|
|
20
|
-
columnTypes?: ColumnTypesMap;
|
|
21
|
-
isMockData?: boolean;
|
|
22
|
-
onclickMetric?: (key: string) => void;
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
export const GSelectableMetricChartCard = ({
|
|
26
|
-
metricInfo,
|
|
27
|
-
dataChart,
|
|
28
|
-
defaultActiveTab,
|
|
29
|
-
isLoading,
|
|
30
|
-
isEmptyMetricData,
|
|
31
|
-
hideComparison,
|
|
32
|
-
currentPeriodLabel = DEFAULT_CURRENT_PERIOD_LABEL,
|
|
33
|
-
previousPeriodLabel = DEFAULT_PREVIOUS_PERIOD_LABEL,
|
|
34
|
-
columnTypes,
|
|
35
|
-
isMockData,
|
|
36
|
-
onclickMetric,
|
|
37
|
-
}: IProps): ReactElement => {
|
|
38
|
-
const [activeTab, setActiveTab] = useState<EMetricKey | undefined>(defaultActiveTab);
|
|
39
|
-
|
|
40
|
-
const lineChartData = useMemo(() => {
|
|
41
|
-
const chartData = activeTab ? dataChart[activeTab] : undefined;
|
|
42
|
-
if (!chartData) return [];
|
|
43
|
-
|
|
44
|
-
const currentSeries = { name: currentPeriodLabel, data: chartData.current };
|
|
45
|
-
if (hideComparison) return [currentSeries];
|
|
46
|
-
|
|
47
|
-
return [currentSeries, { name: previousPeriodLabel, data: chartData.previous, isComparison: true }];
|
|
48
|
-
}, [activeTab, dataChart, hideComparison, currentPeriodLabel, previousPeriodLabel]);
|
|
49
|
-
|
|
50
|
-
return (
|
|
51
|
-
<Card>
|
|
52
|
-
<div
|
|
53
|
-
style={{
|
|
54
|
-
display: 'grid',
|
|
55
|
-
gridTemplateColumns: `repeat(${metricInfo.length}, 1fr)`,
|
|
56
|
-
gap: '16px',
|
|
57
|
-
marginBottom: '16px',
|
|
58
|
-
}}
|
|
59
|
-
>
|
|
60
|
-
{metricInfo.map((item) => (
|
|
61
|
-
<MetricChartTab
|
|
62
|
-
key={item.key}
|
|
63
|
-
item={item}
|
|
64
|
-
isActive={activeTab === item.key}
|
|
65
|
-
isLoading={isLoading}
|
|
66
|
-
hideComparison={hideComparison}
|
|
67
|
-
isMockData={isMockData}
|
|
68
|
-
onSelect={setActiveTab}
|
|
69
|
-
onClickTitle={onclickMetric}
|
|
70
|
-
/>
|
|
71
|
-
))}
|
|
72
|
-
</div>
|
|
73
|
-
|
|
74
|
-
<MetricChart
|
|
75
|
-
lineChartData={lineChartData}
|
|
76
|
-
isLoading={isLoading}
|
|
77
|
-
isEmptyMetricData={isEmptyMetricData}
|
|
78
|
-
metricKey={activeTab}
|
|
79
|
-
columnTypes={columnTypes}
|
|
80
|
-
/>
|
|
81
|
-
</Card>
|
|
82
|
-
);
|
|
83
|
-
};
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
import type { ReactElement } from 'react';
|
|
2
|
-
import type { EMetricKey, IMetricCardItem } from '../../types';
|
|
3
|
-
|
|
4
|
-
import { Box } from '@shopify/polaris';
|
|
5
|
-
import { useState } from 'react';
|
|
6
|
-
import { MetricInfoBlock } from '../common/chart';
|
|
7
|
-
|
|
8
|
-
export interface IProps {
|
|
9
|
-
item: IMetricCardItem;
|
|
10
|
-
isActive: boolean;
|
|
11
|
-
isLoading?: boolean;
|
|
12
|
-
hideComparison?: boolean;
|
|
13
|
-
isMockData?: boolean;
|
|
14
|
-
onSelect: (key: EMetricKey) => void;
|
|
15
|
-
onClickTitle?: (key: string) => void;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
export const MetricChartTab = ({
|
|
19
|
-
item,
|
|
20
|
-
isActive,
|
|
21
|
-
isLoading,
|
|
22
|
-
hideComparison,
|
|
23
|
-
isMockData,
|
|
24
|
-
onSelect,
|
|
25
|
-
onClickTitle,
|
|
26
|
-
}: IProps): ReactElement => {
|
|
27
|
-
const [isHovered, setIsHovered] = useState(false);
|
|
28
|
-
const isHighlighted = isActive || isHovered;
|
|
29
|
-
|
|
30
|
-
return (
|
|
31
|
-
<div
|
|
32
|
-
className="w-full cursor-pointer overflow-hidden"
|
|
33
|
-
onMouseEnter={() => setIsHovered(true)}
|
|
34
|
-
onMouseLeave={() => setIsHovered(false)}
|
|
35
|
-
onClick={() => onSelect(item.key)}
|
|
36
|
-
>
|
|
37
|
-
<Box
|
|
38
|
-
paddingBlock="150"
|
|
39
|
-
paddingInline="300"
|
|
40
|
-
borderRadius="200"
|
|
41
|
-
background={isHighlighted ? 'bg-surface-active' : undefined}
|
|
42
|
-
>
|
|
43
|
-
<MetricInfoBlock
|
|
44
|
-
item={item}
|
|
45
|
-
isHovered={isHovered}
|
|
46
|
-
isLoading={isLoading}
|
|
47
|
-
hideComparison={hideComparison}
|
|
48
|
-
titleVariant="headingSm"
|
|
49
|
-
titleFontWeight="semibold"
|
|
50
|
-
isMockData={isMockData}
|
|
51
|
-
onClickTitle={onClickTitle}
|
|
52
|
-
/>
|
|
53
|
-
</Box>
|
|
54
|
-
</div>
|
|
55
|
-
);
|
|
56
|
-
};
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
import type { GButtonProps } from '@/shared/components/GButton';
|
|
2
|
-
import type { ButtonProps, PopoverProps } from '@shopify/polaris';
|
|
3
|
-
import type { IDateTimeFilterAddition } from './components';
|
|
4
|
-
import type { DateTimeFilter } from './types';
|
|
5
|
-
|
|
6
|
-
import { CompareTimePicker } from './components/CompareTimePicker';
|
|
7
|
-
import { MainTimePicker } from './components/MainTimePicker';
|
|
8
|
-
import { InlineStack } from '@shopify/polaris';
|
|
9
|
-
|
|
10
|
-
export interface GTimePickerProps {
|
|
11
|
-
rangeAddition?: IDateTimeFilterAddition;
|
|
12
|
-
popoverProps?: Partial<PopoverProps>;
|
|
13
|
-
isCompare?: boolean;
|
|
14
|
-
activator?: (props: { onClick: () => void; value?: string }) => React.ReactElement;
|
|
15
|
-
onApply?: (value: DateTimeFilter) => void;
|
|
16
|
-
activatorProps?: Pick<ButtonProps, 'disabled' | 'loading' | 'size'>;
|
|
17
|
-
actionProps?: GButtonProps;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
export const GTimePicker: React.FC<GTimePickerProps> = (props) => {
|
|
21
|
-
const { isCompare, ...timePickerProps } = props;
|
|
22
|
-
|
|
23
|
-
return (
|
|
24
|
-
<InlineStack gap="200">
|
|
25
|
-
<MainTimePicker {...timePickerProps} />
|
|
26
|
-
{isCompare && (
|
|
27
|
-
<CompareTimePicker rangeAddition={timePickerProps.rangeAddition} popoverProps={timePickerProps.popoverProps} />
|
|
28
|
-
)}
|
|
29
|
-
</InlineStack>
|
|
30
|
-
);
|
|
31
|
-
};
|