react-native-inapp-inspector 2.3.18 → 2.3.20
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/android/src/main/java/com/inappinspector/NetworkInspectorModule.kt +57 -0
- package/dist/commonjs/analytics.js +1 -24
- package/dist/commonjs/bundle.js +1 -16
- package/dist/commonjs/capture.d.ts +2 -0
- package/dist/commonjs/capture.js +1 -32
- package/dist/commonjs/components/AnalyticsDetail.js +92 -623
- package/dist/commonjs/components/AnalyticsEventCard.js +54 -350
- package/dist/commonjs/components/AnalyticsGraph.js +70 -370
- package/dist/commonjs/components/AnimatedEntrance.js +1 -11
- package/dist/commonjs/components/AppHeaderLogo.js +7 -134
- package/dist/commonjs/components/BrandCircleIcon.js +73 -118
- package/dist/commonjs/components/BrandSquareIcon.js +63 -108
- package/dist/commonjs/components/CodeSnippet.js +48 -623
- package/dist/commonjs/components/ConsoleLogCard.js +63 -537
- package/dist/commonjs/components/CopyButton.js +3 -89
- package/dist/commonjs/components/DiffViewer.js +19 -83
- package/dist/commonjs/components/DomainHeader.js +27 -127
- package/dist/commonjs/components/EmptyState.d.ts +1 -0
- package/dist/commonjs/components/EmptyState.js +10 -87
- package/dist/commonjs/components/EndOfListFooter.js +7 -81
- package/dist/commonjs/components/ErrorBoundary.js +72 -566
- package/dist/commonjs/components/HeadersSection.js +31 -110
- package/dist/commonjs/components/HighlightText.js +17 -58
- package/dist/commonjs/components/Inspector/AboutModal.d.ts +6 -0
- package/dist/commonjs/components/Inspector/AboutModal.js +351 -0
- package/dist/commonjs/components/Inspector/AnalyticsFilterModal.js +98 -797
- package/dist/commonjs/components/Inspector/AnalyticsTab.js +284 -930
- package/dist/commonjs/components/Inspector/BundleTab.js +551 -2918
- package/dist/commonjs/components/Inspector/ConsoleTab.js +79 -492
- package/dist/commonjs/components/Inspector/CrashDetail.js +123 -672
- package/dist/commonjs/components/Inspector/CrashFilterModal.js +66 -498
- package/dist/commonjs/components/Inspector/CrashTab.js +98 -670
- package/dist/commonjs/components/Inspector/DebuggingTab.js +64 -871
- package/dist/commonjs/components/Inspector/DeviceInfoTab.js +143 -907
- package/dist/commonjs/components/Inspector/FabLauncher.js +85 -54
- package/dist/commonjs/components/Inspector/FeatureUnderDevNotice.js +6 -99
- package/dist/commonjs/components/Inspector/FeedbackModal.d.ts +9 -0
- package/dist/commonjs/components/Inspector/FeedbackModal.js +167 -521
- package/dist/commonjs/components/Inspector/InspectorContext.js +1 -21
- package/dist/commonjs/components/Inspector/InspectorHeader.js +219 -1093
- package/dist/commonjs/components/Inspector/LogDetail.js +168 -994
- package/dist/commonjs/components/Inspector/MainScreen.js +60 -332
- package/dist/commonjs/components/Inspector/MediaGalleryTab.js +136 -278
- package/dist/commonjs/components/Inspector/MediaPreviewModal.js +134 -361
- package/dist/commonjs/components/Inspector/NavigationTracker.js +1 -12
- package/dist/commonjs/components/Inspector/NetworkDetail.js +96 -432
- package/dist/commonjs/components/Inspector/NetworkFilterModal.js +60 -576
- package/dist/commonjs/components/Inspector/NetworkTab.js +84 -514
- package/dist/commonjs/components/Inspector/NpmStarPrompt.js +17 -433
- package/dist/commonjs/components/Inspector/NpmUpdateToast.js +25 -298
- package/dist/commonjs/components/Inspector/PerformanceTab.js +182 -1397
- package/dist/commonjs/components/Inspector/ReduxDetail.js +188 -1089
- package/dist/commonjs/components/Inspector/ReduxTab.js +85 -701
- package/dist/commonjs/components/Inspector/SettingsPanel.js +431 -3431
- package/dist/commonjs/components/Inspector/SkeletonPlaceholder.js +11 -180
- package/dist/commonjs/components/Inspector/StorageTab.js +93 -826
- package/dist/commonjs/components/Inspector/TabBar.js +47 -183
- package/dist/commonjs/components/Inspector/UpdateAvailableModal.js +34 -408
- package/dist/commonjs/components/JsonViewer.js +168 -380
- package/dist/commonjs/components/LogCard.js +57 -567
- package/dist/commonjs/components/LogSyntaxHighlighter.js +11 -130
- package/dist/commonjs/components/MetaAccordion.js +69 -238
- package/dist/commonjs/components/MiniBarChart.js +3 -56
- package/dist/commonjs/components/MiniLineChart.js +3 -58
- package/dist/commonjs/components/NetworkIcons.d.ts +7 -0
- package/dist/commonjs/components/NetworkIcons.js +479 -997
- package/dist/commonjs/components/QRCodeView.js +5 -79
- package/dist/commonjs/components/SectionHeader.js +15 -37
- package/dist/commonjs/components/SegmentedTabs.js +7 -61
- package/dist/commonjs/components/SkeletonPlaceholder.js +11 -180
- package/dist/commonjs/components/Slider.js +15 -243
- package/dist/commonjs/components/SourcePageCard.js +30 -89
- package/dist/commonjs/components/Toast.js +5 -147
- package/dist/commonjs/components/TouchableScale.js +3 -24
- package/dist/commonjs/components/TreeNode.js +55 -130
- package/dist/commonjs/console.js +1 -16
- package/dist/commonjs/constants/index.js +1 -32
- package/dist/commonjs/constants/telemetryConfig.js +1 -6
- package/dist/commonjs/constants/version.d.ts +1 -1
- package/dist/commonjs/constants/version.js +1 -4
- package/dist/commonjs/crash.js +1 -23
- package/dist/commonjs/customHooks/analyticsLogger.js +1 -250
- package/dist/commonjs/customHooks/bundleAnalyzer.js +1 -957
- package/dist/commonjs/customHooks/consoleLogger.js +6 -445
- package/dist/commonjs/customHooks/crashHandler.js +7 -656
- package/dist/commonjs/customHooks/logFilters.js +1 -23
- package/dist/commonjs/customHooks/networkLogger.js +2 -536
- package/dist/commonjs/customHooks/performanceTracker.js +63 -750
- package/dist/commonjs/customHooks/reduxLogger.js +2 -313
- package/dist/commonjs/customHooks/storageInspector.js +1 -435
- package/dist/commonjs/customHooks/useAccordion.js +1 -18
- package/dist/commonjs/decorators/index.js +1 -100
- package/dist/commonjs/helpers/gaAnalyticsRegistry.js +1 -148
- package/dist/commonjs/helpers/index.js +8 -921
- package/dist/commonjs/helpers/memoryManager.js +1 -99
- package/dist/commonjs/helpers/qrGenerator.js +1 -367
- package/dist/commonjs/helpers/remoteConfig.js +1 -165
- package/dist/commonjs/helpers/searchQueryParser.js +1 -62
- package/dist/commonjs/helpers/settingsStore.js +1 -144
- package/dist/commonjs/helpers/telemetry.js +1 -501
- package/dist/commonjs/helpers/toast.js +1 -20
- package/dist/commonjs/i18n/index.js +1 -90
- package/dist/commonjs/i18n/locales/en.json +1 -1122
- package/dist/commonjs/index.js +5 -2153
- package/dist/commonjs/metro.js +6 -468
- package/dist/commonjs/native/NativeInspector.d.ts +3 -0
- package/dist/commonjs/native/NativeInspector.js +1 -402
- package/dist/commonjs/native/NativeNetworkInspector.d.ts +1 -0
- package/dist/commonjs/native/NativeNetworkInspector.js +1 -4
- package/dist/commonjs/network.js +1 -13
- package/dist/commonjs/performance.js +1 -29
- package/dist/commonjs/redux.js +1 -20
- package/dist/commonjs/storage.js +1 -14
- package/dist/commonjs/styles/AppColors.js +1 -423
- package/dist/commonjs/styles/AppFonts.js +1 -17
- package/dist/commonjs/styles/common.js +1 -190
- package/dist/commonjs/styles/index.d.ts +6 -0
- package/dist/commonjs/styles/index.js +1 -1589
- package/dist/commonjs/types/enums.d.ts +2 -1
- package/dist/commonjs/types/enums.js +1 -150
- package/dist/commonjs/types/index.js +1 -18
- package/dist/commonjs/types/interfaces.d.ts +7 -0
- package/dist/commonjs/types/interfaces.js +1 -2
- package/dist/esm/analytics.js +1 -2
- package/dist/esm/bundle.js +1 -2
- package/dist/esm/capture.d.ts +2 -0
- package/dist/esm/capture.js +1 -29
- package/dist/esm/components/AnalyticsDetail.js +171 -664
- package/dist/esm/components/AnalyticsEventCard.js +77 -335
- package/dist/esm/components/AnalyticsGraph.js +95 -357
- package/dist/esm/components/AnimatedEntrance.js +1 -6
- package/dist/esm/components/AppHeaderLogo.js +7 -94
- package/dist/esm/components/BrandCircleIcon.js +114 -119
- package/dist/esm/components/BrandSquareIcon.js +73 -78
- package/dist/esm/components/CodeSnippet.js +58 -595
- package/dist/esm/components/ConsoleLogCard.js +91 -526
- package/dist/esm/components/CopyButton.js +3 -51
- package/dist/esm/components/DiffViewer.js +22 -48
- package/dist/esm/components/DomainHeader.js +43 -138
- package/dist/esm/components/EmptyState.d.ts +1 -0
- package/dist/esm/components/EmptyState.js +17 -56
- package/dist/esm/components/EndOfListFooter.js +15 -83
- package/dist/esm/components/ErrorBoundary.js +125 -582
- package/dist/esm/components/HeadersSection.js +52 -93
- package/dist/esm/components/HighlightText.js +17 -53
- package/dist/esm/components/Inspector/AboutModal.d.ts +6 -0
- package/dist/esm/components/Inspector/AboutModal.js +351 -0
- package/dist/esm/components/Inspector/AnalyticsFilterModal.js +225 -886
- package/dist/esm/components/Inspector/AnalyticsTab.js +296 -904
- package/dist/esm/components/Inspector/BundleTab.js +1175 -3502
- package/dist/esm/components/Inspector/ConsoleTab.js +113 -488
- package/dist/esm/components/Inspector/CrashDetail.js +236 -747
- package/dist/esm/components/Inspector/CrashFilterModal.js +149 -541
- package/dist/esm/components/Inspector/CrashTab.js +177 -711
- package/dist/esm/components/Inspector/DebuggingTab.js +156 -923
- package/dist/esm/components/Inspector/DeviceInfoTab.js +199 -924
- package/dist/esm/components/Inspector/FabLauncher.js +85 -49
- package/dist/esm/components/Inspector/FeatureUnderDevNotice.js +14 -70
- package/dist/esm/components/Inspector/FeedbackModal.d.ts +9 -0
- package/dist/esm/components/Inspector/FeedbackModal.js +182 -499
- package/dist/esm/components/Inspector/InspectorContext.js +1 -12
- package/dist/esm/components/Inspector/InspectorHeader.js +309 -1145
- package/dist/esm/components/Inspector/LogDetail.js +235 -1023
- package/dist/esm/components/Inspector/MainScreen.js +86 -320
- package/dist/esm/components/Inspector/MediaGalleryTab.js +157 -259
- package/dist/esm/components/Inspector/MediaPreviewModal.js +153 -340
- package/dist/esm/components/Inspector/NavigationTracker.js +1 -10
- package/dist/esm/components/Inspector/NetworkDetail.js +141 -472
- package/dist/esm/components/Inspector/NetworkFilterModal.js +122 -597
- package/dist/esm/components/Inspector/NetworkTab.js +125 -517
- package/dist/esm/components/Inspector/NpmStarPrompt.js +58 -434
- package/dist/esm/components/Inspector/NpmUpdateToast.js +45 -281
- package/dist/esm/components/Inspector/PerformanceTab.js +393 -1570
- package/dist/esm/components/Inspector/ReduxDetail.js +307 -1170
- package/dist/esm/components/Inspector/ReduxTab.js +144 -722
- package/dist/esm/components/Inspector/SettingsPanel.js +647 -3609
- package/dist/esm/components/Inspector/SkeletonPlaceholder.js +30 -163
- package/dist/esm/components/Inspector/StorageTab.js +172 -866
- package/dist/esm/components/Inspector/TabBar.js +52 -183
- package/dist/esm/components/Inspector/UpdateAvailableModal.js +79 -416
- package/dist/esm/components/JsonViewer.js +179 -353
- package/dist/esm/components/LogCard.js +93 -565
- package/dist/esm/components/LogSyntaxHighlighter.js +11 -123
- package/dist/esm/components/MetaAccordion.js +136 -267
- package/dist/esm/components/MiniBarChart.js +3 -18
- package/dist/esm/components/MiniLineChart.js +3 -20
- package/dist/esm/components/NetworkIcons.d.ts +7 -0
- package/dist/esm/components/NetworkIcons.js +481 -817
- package/dist/esm/components/QRCodeView.js +8 -45
- package/dist/esm/components/SectionHeader.js +22 -39
- package/dist/esm/components/SegmentedTabs.js +8 -57
- package/dist/esm/components/SkeletonPlaceholder.js +30 -163
- package/dist/esm/components/Slider.js +24 -213
- package/dist/esm/components/SourcePageCard.js +65 -86
- package/dist/esm/components/Toast.js +10 -117
- package/dist/esm/components/TouchableScale.js +3 -19
- package/dist/esm/components/TreeNode.js +58 -95
- package/dist/esm/console.js +1 -2
- package/dist/esm/constants/index.js +1 -28
- package/dist/esm/constants/telemetryConfig.js +1 -3
- package/dist/esm/constants/version.d.ts +1 -1
- package/dist/esm/constants/version.js +1 -1
- package/dist/esm/crash.js +1 -2
- package/dist/esm/customHooks/analyticsLogger.js +1 -230
- package/dist/esm/customHooks/bundleAnalyzer.js +1 -944
- package/dist/esm/customHooks/consoleLogger.js +6 -432
- package/dist/esm/customHooks/crashHandler.js +7 -630
- package/dist/esm/customHooks/logFilters.js +1 -20
- package/dist/esm/customHooks/networkLogger.js +2 -519
- package/dist/esm/customHooks/performanceTracker.js +63 -723
- package/dist/esm/customHooks/reduxLogger.js +2 -293
- package/dist/esm/customHooks/storageInspector.js +1 -418
- package/dist/esm/customHooks/useAccordion.js +1 -16
- package/dist/esm/decorators/index.js +1 -95
- package/dist/esm/helpers/gaAnalyticsRegistry.js +1 -143
- package/dist/esm/helpers/index.js +8 -861
- package/dist/esm/helpers/memoryManager.js +1 -91
- package/dist/esm/helpers/qrGenerator.js +1 -364
- package/dist/esm/helpers/remoteConfig.js +1 -160
- package/dist/esm/helpers/searchQueryParser.js +1 -59
- package/dist/esm/helpers/settingsStore.js +1 -134
- package/dist/esm/helpers/telemetry.js +1 -489
- package/dist/esm/helpers/toast.js +1 -15
- package/dist/esm/i18n/index.js +1 -78
- package/dist/esm/i18n/locales/en.json +1 -1122
- package/dist/esm/index.js +7 -1967
- package/dist/esm/metro.js +6 -459
- package/dist/esm/native/NativeInspector.d.ts +3 -0
- package/dist/esm/native/NativeInspector.js +1 -370
- package/dist/esm/native/NativeNetworkInspector.d.ts +1 -0
- package/dist/esm/native/NativeNetworkInspector.js +1 -2
- package/dist/esm/network.js +1 -1
- package/dist/esm/performance.js +1 -2
- package/dist/esm/redux.js +1 -1
- package/dist/esm/storage.js +1 -1
- package/dist/esm/styles/AppColors.js +1 -417
- package/dist/esm/styles/AppFonts.js +1 -13
- package/dist/esm/styles/common.js +1 -186
- package/dist/esm/styles/index.d.ts +6 -0
- package/dist/esm/styles/index.js +1 -1551
- package/dist/esm/types/enums.d.ts +2 -1
- package/dist/esm/types/enums.js +1 -147
- package/dist/esm/types/index.js +1 -2
- package/dist/esm/types/interfaces.d.ts +7 -0
- package/dist/esm/types/interfaces.js +1 -1
- package/ios/NetworkInspectorModule.mm +253 -136
- package/package.json +5 -3
- package/react-native-inapp-inspector.podspec +1 -1
- package/src/native/NativeInspector.ts +17 -0
- package/src/native/NativeNetworkInspector.ts +1 -0
- package/src/analytics.ts +0 -35
- package/src/bundle.ts +0 -25
- package/src/capture.ts +0 -101
- package/src/components/AnalyticsDetail.tsx +0 -870
- package/src/components/AnalyticsEventCard.tsx +0 -444
- package/src/components/AnalyticsGraph.tsx +0 -583
- package/src/components/AnimatedEntrance.tsx +0 -20
- package/src/components/AppHeaderLogo.tsx +0 -143
- package/src/components/BrandCircleIcon.tsx +0 -144
- package/src/components/BrandSquareIcon.tsx +0 -184
- package/src/components/CodeSnippet.tsx +0 -725
- package/src/components/ConsoleLogCard.tsx +0 -679
- package/src/components/CopyButton.tsx +0 -87
- package/src/components/DiffViewer.tsx +0 -82
- package/src/components/DomainHeader.tsx +0 -224
- package/src/components/EmptyState.tsx +0 -95
- package/src/components/EndOfListFooter.tsx +0 -100
- package/src/components/ErrorBoundary.tsx +0 -688
- package/src/components/HeadersSection.tsx +0 -172
- package/src/components/HighlightText.tsx +0 -100
- package/src/components/Inspector/AnalyticsFilterModal.tsx +0 -1250
- package/src/components/Inspector/AnalyticsTab.tsx +0 -1362
- package/src/components/Inspector/BundleTab.tsx +0 -4768
- package/src/components/Inspector/ConsoleTab.tsx +0 -726
- package/src/components/Inspector/CrashDetail.tsx +0 -997
- package/src/components/Inspector/CrashFilterModal.tsx +0 -721
- package/src/components/Inspector/CrashTab.tsx +0 -933
- package/src/components/Inspector/DebuggingTab.tsx +0 -1103
- package/src/components/Inspector/DeviceInfoTab.tsx +0 -1397
- package/src/components/Inspector/FabLauncher.tsx +0 -80
- package/src/components/Inspector/FeatureUnderDevNotice.tsx +0 -94
- package/src/components/Inspector/FeedbackModal.tsx +0 -626
- package/src/components/Inspector/InspectorContext.tsx +0 -28
- package/src/components/Inspector/InspectorHeader.tsx +0 -1545
- package/src/components/Inspector/LogDetail.tsx +0 -1431
- package/src/components/Inspector/MainScreen.tsx +0 -459
- package/src/components/Inspector/MediaGalleryTab.tsx +0 -355
- package/src/components/Inspector/MediaPreviewModal.tsx +0 -435
- package/src/components/Inspector/NavigationTracker.tsx +0 -13
- package/src/components/Inspector/NetworkDetail.tsx +0 -795
- package/src/components/Inspector/NetworkFilterModal.tsx +0 -730
- package/src/components/Inspector/NetworkTab.tsx +0 -820
- package/src/components/Inspector/NpmStarPrompt.tsx +0 -532
- package/src/components/Inspector/NpmUpdateToast.tsx +0 -387
- package/src/components/Inspector/PerformanceTab.tsx +0 -1967
- package/src/components/Inspector/ReduxDetail.tsx +0 -1651
- package/src/components/Inspector/ReduxTab.tsx +0 -987
- package/src/components/Inspector/SettingsPanel.tsx +0 -4580
- package/src/components/Inspector/SkeletonPlaceholder.tsx +0 -206
- package/src/components/Inspector/StorageTab.tsx +0 -1159
- package/src/components/Inspector/TabBar.tsx +0 -263
- package/src/components/Inspector/UpdateAvailableModal.tsx +0 -555
- package/src/components/JsonViewer.tsx +0 -547
- package/src/components/LogCard.tsx +0 -694
- package/src/components/LogSyntaxHighlighter.tsx +0 -178
- package/src/components/MetaAccordion.tsx +0 -355
- package/src/components/MiniBarChart.tsx +0 -42
- package/src/components/MiniLineChart.tsx +0 -33
- package/src/components/NetworkIcons.tsx +0 -2599
- package/src/components/QRCodeView.tsx +0 -75
- package/src/components/SectionHeader.tsx +0 -101
- package/src/components/SegmentedTabs.tsx +0 -83
- package/src/components/SkeletonPlaceholder.tsx +0 -206
- package/src/components/Slider.tsx +0 -300
- package/src/components/SourcePageCard.tsx +0 -150
- package/src/components/Toast.tsx +0 -131
- package/src/components/TouchableScale.tsx +0 -61
- package/src/components/TreeNode.tsx +0 -171
- package/src/console.ts +0 -24
- package/src/constants/index.ts +0 -41
- package/src/constants/telemetryConfig.ts +0 -4
- package/src/constants/version.ts +0 -3
- package/src/crash.ts +0 -32
- package/src/customHooks/analyticsLogger.ts +0 -336
- package/src/customHooks/bundleAnalyzer.ts +0 -1256
- package/src/customHooks/consoleLogger.ts +0 -530
- package/src/customHooks/crashHandler.ts +0 -944
- package/src/customHooks/logFilters.ts +0 -32
- package/src/customHooks/networkLogger.ts +0 -624
- package/src/customHooks/performanceTracker.ts +0 -1014
- package/src/customHooks/reduxLogger.ts +0 -406
- package/src/customHooks/storageInspector.ts +0 -513
- package/src/customHooks/useAccordion.tsx +0 -27
- package/src/decorators/index.ts +0 -184
- package/src/helpers/gaAnalyticsRegistry.ts +0 -204
- package/src/helpers/index.ts +0 -1092
- package/src/helpers/memoryManager.ts +0 -138
- package/src/helpers/qrGenerator.ts +0 -430
- package/src/helpers/remoteConfig.ts +0 -212
- package/src/helpers/searchQueryParser.ts +0 -84
- package/src/helpers/settingsStore.ts +0 -171
- package/src/helpers/telemetry.ts +0 -568
- package/src/helpers/toast.ts +0 -17
- package/src/i18n/index.ts +0 -104
- package/src/i18n/locales/en.json +0 -1125
- package/src/index.tsx +0 -2635
- package/src/metro.ts +0 -598
- package/src/network.ts +0 -22
- package/src/performance.ts +0 -38
- package/src/redux.ts +0 -23
- package/src/storage.ts +0 -18
- package/src/styles/AppColors.ts +0 -455
- package/src/styles/AppFonts.ts +0 -26
- package/src/styles/common.ts +0 -209
- package/src/styles/index.ts +0 -1606
- package/src/types/enums.ts +0 -208
- package/src/types/index.ts +0 -34
- package/src/types/interfaces.ts +0 -530
|
@@ -1,978 +1,332 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
-
var ownKeys = function(o) {
|
|
20
|
-
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
-
var ar = [];
|
|
22
|
-
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
-
return ar;
|
|
24
|
-
};
|
|
25
|
-
return ownKeys(o);
|
|
26
|
-
};
|
|
27
|
-
return function (mod) {
|
|
28
|
-
if (mod && mod.__esModule) return mod;
|
|
29
|
-
var result = {};
|
|
30
|
-
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
-
__setModuleDefault(result, mod);
|
|
32
|
-
return result;
|
|
33
|
-
};
|
|
34
|
-
})();
|
|
35
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
36
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
37
|
-
};
|
|
38
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
-
const react_1 = __importStar(require("react"));
|
|
40
|
-
const react_native_1 = require("react-native");
|
|
41
|
-
const InspectorContext_1 = require("./InspectorContext");
|
|
42
|
-
const AnalyticsEventCard_1 = __importDefault(require("../AnalyticsEventCard"));
|
|
43
|
-
const AnalyticsFilterModal_1 = __importDefault(require("./AnalyticsFilterModal"));
|
|
44
|
-
const EndOfListFooter_1 = __importDefault(require("../EndOfListFooter"));
|
|
45
|
-
const EmptyState_1 = __importDefault(require("../EmptyState"));
|
|
46
|
-
const styles_1 = __importDefault(require("../../styles"));
|
|
47
|
-
const AppColors_1 = require("../../styles/AppColors");
|
|
48
|
-
const AppFonts_1 = require("../../styles/AppFonts");
|
|
49
|
-
const i18n_1 = require("../../i18n");
|
|
50
|
-
const react_native_svg_1 = __importStar(require("react-native-svg"));
|
|
51
|
-
const TouchableScale_1 = __importDefault(require("../TouchableScale"));
|
|
52
|
-
const analyticsLogger_1 = require("../../customHooks/analyticsLogger");
|
|
53
|
-
const helpers_1 = require("../../helpers");
|
|
54
|
-
const NetworkIcons_1 = require("../NetworkIcons");
|
|
55
|
-
const AnalyticsHeader = react_1.default.memo(() => {
|
|
56
|
-
const { t } = (0, i18n_1.useTranslation)();
|
|
57
|
-
const { analyticsEvents, filteredAnalyticsEvents, analyticsFilters, setAnalyticsFilters, analyticsHeaderExpanded, setAnalyticsHeaderExpanded, } = (0, InspectorContext_1.useInspector)();
|
|
58
|
-
const userId = (0, analyticsLogger_1.getCurrentUserId)();
|
|
59
|
-
const userProperties = (0, analyticsLogger_1.getCurrentUserProperties)();
|
|
60
|
-
const defaultParams = (0, analyticsLogger_1.getDefaultEventParameters)();
|
|
61
|
-
const isTrackingEnabled = (0, analyticsLogger_1.getCollectionEnabled)();
|
|
62
|
-
if (analyticsEvents.length === 0) {
|
|
63
|
-
return null;
|
|
64
|
-
}
|
|
65
|
-
const hasUserProps = Object.keys(userProperties).length > 0;
|
|
66
|
-
const hasDefaultParams = Object.keys(defaultParams).length > 0;
|
|
67
|
-
const totalEvents = filteredAnalyticsEvents.length;
|
|
68
|
-
const categoryStats = (0, react_1.useMemo)(() => {
|
|
69
|
-
let ecommerce = 0;
|
|
70
|
-
let page_view = 0;
|
|
71
|
-
let system = 0;
|
|
72
|
-
let custom = 0;
|
|
73
|
-
let totalRevenue = 0;
|
|
74
|
-
for (const e of analyticsEvents) {
|
|
75
|
-
const cat = (0, helpers_1.getEventCategory)(e.name);
|
|
76
|
-
const c = e.count || 1;
|
|
77
|
-
if (cat === 'ecommerce') {
|
|
78
|
-
ecommerce += c;
|
|
79
|
-
const val = e.params?.value ?? e.params?.price;
|
|
80
|
-
if (val && !isNaN(Number(val))) {
|
|
81
|
-
totalRevenue += Number(val);
|
|
82
|
-
}
|
|
83
|
-
}
|
|
84
|
-
else if (cat === 'page_view') {
|
|
85
|
-
page_view += c;
|
|
86
|
-
}
|
|
87
|
-
else if (cat === 'system') {
|
|
88
|
-
system += c;
|
|
89
|
-
}
|
|
90
|
-
else {
|
|
91
|
-
custom += c;
|
|
92
|
-
}
|
|
93
|
-
}
|
|
94
|
-
const total = ecommerce + page_view + system + custom || 1;
|
|
95
|
-
return {
|
|
96
|
-
ecommerce,
|
|
97
|
-
page_view,
|
|
98
|
-
system,
|
|
99
|
-
custom,
|
|
100
|
-
totalRevenue,
|
|
101
|
-
ecommercePct: Math.round((ecommerce / total) * 100),
|
|
102
|
-
page_viewPct: Math.round((page_view / total) * 100),
|
|
103
|
-
systemPct: Math.round((system / total) * 100),
|
|
104
|
-
customPct: Math.round((custom / total) * 100),
|
|
105
|
-
totalCount: total,
|
|
106
|
-
};
|
|
107
|
-
}, [analyticsEvents]);
|
|
108
|
-
const topScreens = (0, react_1.useMemo)(() => {
|
|
109
|
-
const screenMap = new Map();
|
|
110
|
-
for (const e of filteredAnalyticsEvents) {
|
|
111
|
-
const scr = e.screenName ||
|
|
112
|
-
e.params?.firebase_screen ||
|
|
113
|
-
e.params?.screen_name ||
|
|
114
|
-
e.params?.firebase_screen_class ||
|
|
115
|
-
e.screenClass;
|
|
116
|
-
if (scr && typeof scr === 'string' && scr.trim() !== '') {
|
|
117
|
-
screenMap.set(scr, (screenMap.get(scr) || 0) + (e.count || 1));
|
|
118
|
-
}
|
|
119
|
-
}
|
|
120
|
-
const arr = Array.from(screenMap.entries()).sort((a, b) => b[1] - a[1]);
|
|
121
|
-
const maxVal = arr.length > 0 ? arr[0][1] : 1;
|
|
122
|
-
return arr.slice(0, 3).map(([name, count]) => ({
|
|
123
|
-
name,
|
|
124
|
-
count,
|
|
125
|
-
pct: Math.round((count / (filteredAnalyticsEvents.length || 1)) * 100),
|
|
126
|
-
barWidthPct: Math.round((count / maxVal) * 100),
|
|
127
|
-
}));
|
|
128
|
-
}, [filteredAnalyticsEvents]);
|
|
129
|
-
const toggleCategoryFilter = (cat) => {
|
|
130
|
-
(0, InspectorContext_1.animateNextLayout)();
|
|
131
|
-
setAnalyticsFilters(prev => {
|
|
132
|
-
if (cat === 'all') {
|
|
133
|
-
return { ...prev, categories: new Set(['all']) };
|
|
134
|
-
}
|
|
135
|
-
const nextCategories = new Set(prev.categories);
|
|
136
|
-
if (nextCategories.has('all')) {
|
|
137
|
-
nextCategories.delete('all');
|
|
138
|
-
nextCategories.add(cat);
|
|
139
|
-
}
|
|
140
|
-
else {
|
|
141
|
-
if (nextCategories.has(cat)) {
|
|
142
|
-
nextCategories.delete(cat);
|
|
143
|
-
if (nextCategories.size === 0) {
|
|
144
|
-
nextCategories.add('all');
|
|
145
|
-
}
|
|
146
|
-
}
|
|
147
|
-
else {
|
|
148
|
-
nextCategories.add(cat);
|
|
149
|
-
if (nextCategories.has('ecommerce') &&
|
|
150
|
-
nextCategories.has('page_view') &&
|
|
151
|
-
nextCategories.has('system') &&
|
|
152
|
-
nextCategories.has('custom')) {
|
|
153
|
-
return { ...prev, categories: new Set(['all']) };
|
|
154
|
-
}
|
|
155
|
-
}
|
|
156
|
-
}
|
|
157
|
-
return { ...prev, categories: nextCategories };
|
|
158
|
-
});
|
|
159
|
-
};
|
|
160
|
-
const BUCKET_COUNT = 12;
|
|
161
|
-
const chartHeight = 64;
|
|
162
|
-
const svgWidth = 320;
|
|
163
|
-
const [selectedBucketIdx, setSelectedBucketIdx] = (0, react_1.useState)(null);
|
|
164
|
-
const [liveTick, setLiveTick] = (0, react_1.useState)(0);
|
|
165
|
-
(0, react_1.useEffect)(() => {
|
|
166
|
-
if (!isTrackingEnabled)
|
|
167
|
-
return;
|
|
168
|
-
const interval = setInterval(() => {
|
|
169
|
-
setLiveTick(t => (t + 1) % 100000);
|
|
170
|
-
}, 1000);
|
|
171
|
-
return () => clearInterval(interval);
|
|
172
|
-
}, [isTrackingEnabled]);
|
|
173
|
-
const histogramData = (0, react_1.useMemo)(() => {
|
|
174
|
-
const buckets = [];
|
|
175
|
-
const now = Date.now();
|
|
176
|
-
const windowMs = 60000;
|
|
177
|
-
const bucketDuration = windowMs / BUCKET_COUNT;
|
|
178
|
-
for (let i = 0; i < BUCKET_COUNT; i++) {
|
|
179
|
-
const bucketAgeSec = Math.round(((BUCKET_COUNT - 1 - i) * bucketDuration) / 1000);
|
|
180
|
-
buckets.push({
|
|
181
|
-
index: i,
|
|
182
|
-
ecommerce: 0,
|
|
183
|
-
page_view: 0,
|
|
184
|
-
system: 0,
|
|
185
|
-
custom: 0,
|
|
186
|
-
total: 0,
|
|
187
|
-
x: (i / (BUCKET_COUNT - 1)) * (svgWidth - 24) + 12,
|
|
188
|
-
y: chartHeight - 12,
|
|
189
|
-
isLatest: i === BUCKET_COUNT - 1,
|
|
190
|
-
ageLabel: i === BUCKET_COUNT - 1 ? t('analytics.timeNow') : `-${bucketAgeSec}s`,
|
|
191
|
-
});
|
|
192
|
-
}
|
|
193
|
-
for (const e of filteredAnalyticsEvents) {
|
|
194
|
-
const age = now - e.timestamp;
|
|
195
|
-
if (age >= 0 && age < windowMs) {
|
|
196
|
-
const bucketIdx = Math.floor((windowMs - 1 - age) / bucketDuration);
|
|
197
|
-
if (bucketIdx >= 0 && bucketIdx < BUCKET_COUNT) {
|
|
198
|
-
const cat = (0, helpers_1.getEventCategory)(e.name);
|
|
199
|
-
const c = e.count || 1;
|
|
200
|
-
buckets[bucketIdx].total += c;
|
|
201
|
-
if (cat === 'ecommerce')
|
|
202
|
-
buckets[bucketIdx].ecommerce += c;
|
|
203
|
-
else if (cat === 'page_view')
|
|
204
|
-
buckets[bucketIdx].page_view += c;
|
|
205
|
-
else if (cat === 'system')
|
|
206
|
-
buckets[bucketIdx].system += c;
|
|
207
|
-
else
|
|
208
|
-
buckets[bucketIdx].custom += c;
|
|
209
|
-
}
|
|
210
|
-
}
|
|
211
|
-
}
|
|
212
|
-
const maxVal = Math.max(...buckets.map(b => b.total), 4);
|
|
213
|
-
buckets.forEach(b => {
|
|
214
|
-
const normalizedH = (b.total / maxVal) * (chartHeight - 22);
|
|
215
|
-
b.y = chartHeight - 10 - normalizedH;
|
|
216
|
-
});
|
|
217
|
-
let linePath = `M ${buckets[0].x.toFixed(1)} ${buckets[0].y.toFixed(1)}`;
|
|
218
|
-
for (let i = 0; i < buckets.length - 1; i++) {
|
|
219
|
-
const p0 = buckets[Math.max(0, i - 1)];
|
|
220
|
-
const p1 = buckets[i];
|
|
221
|
-
const p2 = buckets[i + 1];
|
|
222
|
-
const p3 = buckets[Math.min(buckets.length - 1, i + 2)];
|
|
223
|
-
const cp1x = p1.x + (p2.x - p0.x) / 6;
|
|
224
|
-
const cp1y = p1.y + (p2.y - p0.y) / 6;
|
|
225
|
-
const cp2x = p2.x - (p3.x - p1.x) / 6;
|
|
226
|
-
const cp2y = p2.y - (p3.y - p1.y) / 6;
|
|
227
|
-
linePath += ` C ${cp1x.toFixed(1)} ${cp1y.toFixed(1)}, ${cp2x.toFixed(1)} ${cp2y.toFixed(1)}, ${p2.x.toFixed(1)} ${p2.y.toFixed(1)}`;
|
|
228
|
-
}
|
|
229
|
-
const lastB = buckets[buckets.length - 1];
|
|
230
|
-
const firstB = buckets[0];
|
|
231
|
-
const areaPath = `${linePath} L ${lastB.x.toFixed(1)} ${chartHeight - 4} L ${firstB.x.toFixed(1)} ${chartHeight - 4} Z`;
|
|
232
|
-
const peakVal = Math.max(...buckets.map(b => b.total), 0);
|
|
233
|
-
const eventRate = Math.round(buckets.reduce((a, b) => a + b.total, 0));
|
|
234
|
-
return {
|
|
235
|
-
buckets,
|
|
236
|
-
linePath,
|
|
237
|
-
areaPath,
|
|
238
|
-
peakVal,
|
|
239
|
-
eventRate,
|
|
240
|
-
};
|
|
241
|
-
}, [filteredAnalyticsEvents, chartHeight, svgWidth, liveTick, t]);
|
|
242
|
-
const selectedBucket = selectedBucketIdx != null ? histogramData.buckets[selectedBucketIdx] : null;
|
|
243
|
-
return (<react_native_1.View style={styles_1.default.analyticsHeaderCard}>
|
|
1
|
+
"use strict";var __createBinding=this&&this.__createBinding||(Object.create?(function(a,l,r,s){s===void 0&&(s=r);var p=Object.getOwnPropertyDescriptor(l,r);(!p||("get"in p?!l.__esModule:p.writable||p.configurable))&&(p={enumerable:!0,get:function(){return l[r]}}),Object.defineProperty(a,s,p)}):(function(a,l,r,s){s===void 0&&(s=r),a[s]=l[r]})),__setModuleDefault=this&&this.__setModuleDefault||(Object.create?(function(a,l){Object.defineProperty(a,"default",{enumerable:!0,value:l})}):function(a,l){a.default=l}),__importStar=this&&this.__importStar||(function(){var a=function(l){return a=Object.getOwnPropertyNames||function(r){var s=[];for(var p in r)Object.prototype.hasOwnProperty.call(r,p)&&(s[s.length]=p);return s},a(l)};return function(l){if(l&&l.__esModule)return l;var r={};if(l!=null)for(var s=a(l),p=0;p<s.length;p++)s[p]!=="default"&&__createBinding(r,l,s[p]);return __setModuleDefault(r,l),r}})(),__importDefault=this&&this.__importDefault||function(a){return a&&a.__esModule?a:{default:a}};Object.defineProperty(exports,"__esModule",{value:!0});const react_1=__importStar(require("react")),react_native_1=require("react-native"),InspectorContext_1=require("./InspectorContext"),AnalyticsEventCard_1=__importDefault(require("../AnalyticsEventCard")),AnalyticsFilterModal_1=__importDefault(require("./AnalyticsFilterModal")),EndOfListFooter_1=__importDefault(require("../EndOfListFooter")),EmptyState_1=__importDefault(require("../EmptyState")),styles_1=__importDefault(require("../../styles")),AppColors_1=require("../../styles/AppColors"),AppFonts_1=require("../../styles/AppFonts"),i18n_1=require("../../i18n"),react_native_svg_1=__importStar(require("react-native-svg")),TouchableScale_1=__importDefault(require("../TouchableScale")),analyticsLogger_1=require("../../customHooks/analyticsLogger"),helpers_1=require("../../helpers"),NetworkIcons_1=require("../NetworkIcons"),AnalyticsHeader=react_1.default.memo(()=>{const{t:a}=(0,i18n_1.useTranslation)(),{analyticsEvents:l,filteredAnalyticsEvents:r,analyticsHeaderExpanded:s,setAnalyticsHeaderExpanded:p}=(0,InspectorContext_1.useInspector)(),[f,R]=(0,react_1.useState)(!1),L=(0,analyticsLogger_1.getCurrentUserId)(),B=(0,analyticsLogger_1.getCurrentUserProperties)(),S=(0,analyticsLogger_1.getDefaultEventParameters)(),v=(0,analyticsLogger_1.getCollectionEnabled)();if(l.length===0)return null;const I=Object.keys(B).length>0,D=Object.keys(S).length>0,b=r.length,k=(0,react_1.useMemo)(()=>{let e=0,o=0;for(const d of l){const n=(0,helpers_1.getEventCategory)(d.name),c=d.count||1;if(n==="ecommerce"){e+=c;const _=d.params?.value??d.params?.price;_&&!isNaN(Number(_))&&(o+=Number(_))}}return{ecommerce:e,totalRevenue:o}},[l]),E=(0,react_1.useMemo)(()=>{const e=new Map;for(const n of r){const c=n.screenName||n.params?.firebase_screen||n.params?.screen_name||n.params?.firebase_screen_class||n.screenClass;c&&typeof c=="string"&&c.trim()!==""&&e.set(c,(e.get(c)||0)+(n.count||1))}const o=Array.from(e.entries()).sort((n,c)=>c[1]-n[1]),d=o.length>0?o[0][1]:1;return o.slice(0,3).map(([n,c])=>({name:n,count:c,pct:Math.round(c/(r.length||1)*100),barWidthPct:Math.round(c/d*100)}))},[r]),h=12,u=64,A=320,[T,V]=(0,react_1.useState)(null),[F,$]=(0,react_1.useState)(0);(0,react_1.useEffect)(()=>{if(!v)return;const e=setInterval(()=>{$(o=>(o+1)%1e5)},1e3);return()=>clearInterval(e)},[v]);const y=(0,react_1.useMemo)(()=>{const e=[],o=Date.now(),d=6e4,n=d/h;for(let i=0;i<h;i++){const g=Math.round((h-1-i)*n/1e3);e.push({index:i,ecommerce:0,page_view:0,system:0,custom:0,total:0,x:i/(h-1)*(A-24)+12,y:u-12,isLatest:i===h-1,ageLabel:i===h-1?a("analytics.timeNow"):`-${g}s`})}for(const i of r){const g=o-i.timestamp;if(g>=0&&g<d){const m=Math.floor((d-1-g)/n);if(m>=0&&m<h){const C=(0,helpers_1.getEventCategory)(i.name),x=i.count||1;e[m].total+=x,C==="ecommerce"?e[m].ecommerce+=x:C==="page_view"?e[m].page_view+=x:C==="system"?e[m].system+=x:e[m].custom+=x}}}const c=Math.max(...e.map(i=>i.total),4);e.forEach(i=>{const g=i.total/c*(u-22);i.y=u-10-g});let _=`M ${e[0].x.toFixed(1)} ${e[0].y.toFixed(1)}`;for(let i=0;i<e.length-1;i++){const g=e[Math.max(0,i-1)],m=e[i],C=e[i+1],x=e[Math.min(e.length-1,i+2)],H=m.x+(C.x-g.x)/6,W=m.y+(C.y-g.y)/6,N=C.x-(x.x-m.x)/6,j=C.y-(x.y-m.y)/6;_+=` C ${H.toFixed(1)} ${W.toFixed(1)}, ${N.toFixed(1)} ${j.toFixed(1)}, ${C.x.toFixed(1)} ${C.y.toFixed(1)}`}const w=e[e.length-1],O=e[0],P=`${_} L ${w.x.toFixed(1)} ${u-4} L ${O.x.toFixed(1)} ${u-4} Z`,z=Math.max(...e.map(i=>i.total),0),M=Math.round(e.reduce((i,g)=>i+g.total,0));return{buckets:e,linePath:_,areaPath:P,peakVal:z,eventRate:M}},[r,u,A,F,a]),t=T!=null?y.buckets[T]:null;return<react_native_1.View style={styles_1.default.analyticsHeaderCard}>
|
|
244
2
|
|
|
245
|
-
<react_native_1.
|
|
246
|
-
<react_native_1.View style={{
|
|
247
|
-
<react_native_1.View style={{
|
|
248
|
-
<react_native_1.Text style={styles_1.default.analyticsHeaderTitle}>{
|
|
249
|
-
<react_native_1.View style={[
|
|
250
|
-
styles_1.default.
|
|
251
|
-
|
|
252
|
-
backgroundColor: isTrackingEnabled
|
|
253
|
-
? AppColors_1.AppColors.greenColor
|
|
254
|
-
: AppColors_1.AppColors.errorColor,
|
|
255
|
-
},
|
|
256
|
-
]}/>
|
|
257
|
-
<react_native_1.Text style={[
|
|
258
|
-
styles_1.default.statusText,
|
|
259
|
-
{
|
|
260
|
-
color: isTrackingEnabled
|
|
261
|
-
? AppColors_1.AppColors.greenColor
|
|
262
|
-
: AppColors_1.AppColors.errorColor,
|
|
263
|
-
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
264
|
-
},
|
|
265
|
-
]}>
|
|
266
|
-
{isTrackingEnabled ? t('performance.live') : t('common.pause')}
|
|
3
|
+
<react_native_1.TouchableOpacity activeOpacity={.7}onPress={()=>{(0,InspectorContext_1.animateNextLayout)(),R(e=>!e)}}style={{flexDirection:"row",justifyContent:"space-between",alignItems:"center",paddingVertical:2}}>
|
|
4
|
+
<react_native_1.View style={{flex:1}}>
|
|
5
|
+
<react_native_1.View style={{flexDirection:"row",alignItems:"center",gap:6}}>
|
|
6
|
+
<react_native_1.Text style={styles_1.default.analyticsHeaderTitle}>{a("analytics.realtimeStream")}</react_native_1.Text>
|
|
7
|
+
<react_native_1.View style={[styles_1.default.statusDot,{backgroundColor:v?AppColors_1.AppColors.greenColor:AppColors_1.AppColors.errorColor}]}/>
|
|
8
|
+
<react_native_1.Text style={[styles_1.default.statusText,{color:v?AppColors_1.AppColors.greenColor:AppColors_1.AppColors.errorColor,fontFamily:AppFonts_1.AppFonts.interBold}]}>
|
|
9
|
+
{a(v?"performance.live":"common.pause")}
|
|
267
10
|
</react_native_1.Text>
|
|
268
11
|
</react_native_1.View>
|
|
269
|
-
<react_native_1.Text style={styles_1.default.analyticsHeaderSubtitle}
|
|
270
|
-
{
|
|
12
|
+
<react_native_1.Text style={styles_1.default.analyticsHeaderSubtitle}numberOfLines={1}>
|
|
13
|
+
{L?`${a("analytics.userId")}: ${L}`:a("analytics.emptySubtitle")}
|
|
271
14
|
</react_native_1.Text>
|
|
272
15
|
</react_native_1.View>
|
|
273
16
|
|
|
274
|
-
<react_native_1.
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
<react_native_1.View style={{ marginTop: 10, marginBottom: 8 }}>
|
|
286
|
-
|
|
287
|
-
<react_native_1.View style={{
|
|
288
|
-
height: 4.5,
|
|
289
|
-
borderRadius: 2.5,
|
|
290
|
-
backgroundColor: `${AppColors_1.AppColors.grayBorderSecondary}40`,
|
|
291
|
-
flexDirection: 'row',
|
|
292
|
-
overflow: 'hidden',
|
|
293
|
-
marginBottom: 8,
|
|
294
|
-
}}>
|
|
295
|
-
{categoryStats.ecommerce > 0 && (<react_native_1.View style={{
|
|
296
|
-
flex: categoryStats.ecommerce,
|
|
297
|
-
backgroundColor: AppColors_1.AppColors.amber500,
|
|
298
|
-
}}/>)}
|
|
299
|
-
{categoryStats.page_view > 0 && (<react_native_1.View style={{
|
|
300
|
-
flex: categoryStats.page_view,
|
|
301
|
-
backgroundColor: AppColors_1.AppColors.sky500,
|
|
302
|
-
}}/>)}
|
|
303
|
-
{categoryStats.system > 0 && (<react_native_1.View style={{
|
|
304
|
-
flex: categoryStats.system,
|
|
305
|
-
backgroundColor: AppColors_1.AppColors.purple,
|
|
306
|
-
}}/>)}
|
|
307
|
-
{categoryStats.custom > 0 && (<react_native_1.View style={{
|
|
308
|
-
flex: categoryStats.custom,
|
|
309
|
-
backgroundColor: AppColors_1.AppColors.brandPurple,
|
|
310
|
-
}}/>)}
|
|
311
|
-
</react_native_1.View>
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
<react_native_1.View style={{
|
|
315
|
-
flexDirection: 'row',
|
|
316
|
-
flexWrap: 'wrap',
|
|
317
|
-
gap: 6,
|
|
318
|
-
}}>
|
|
319
|
-
|
|
320
|
-
{(() => {
|
|
321
|
-
const isAllSelected = analyticsFilters.categories.has('all');
|
|
322
|
-
return (<TouchableScale_1.default onPress={() => toggleCategoryFilter('all')} style={[
|
|
323
|
-
{
|
|
324
|
-
flexDirection: 'row',
|
|
325
|
-
alignItems: 'center',
|
|
326
|
-
gap: 5,
|
|
327
|
-
backgroundColor: isAllSelected ? AppColors_1.AppColors.indigo600Alt : AppColors_1.AppColors.indigo50,
|
|
328
|
-
paddingHorizontal: 8,
|
|
329
|
-
paddingVertical: 5,
|
|
330
|
-
borderRadius: 7,
|
|
331
|
-
borderWidth: 1,
|
|
332
|
-
borderColor: isAllSelected ? AppColors_1.AppColors.indigo600 : AppColors_1.AppColors.indigo400,
|
|
333
|
-
},
|
|
334
|
-
isAllSelected && {
|
|
335
|
-
shadowColor: AppColors_1.AppColors.indigo600Alt,
|
|
336
|
-
shadowOffset: { width: 0, height: 1 },
|
|
337
|
-
shadowOpacity: 0.28,
|
|
338
|
-
shadowRadius: 2.5,
|
|
339
|
-
elevation: 2,
|
|
340
|
-
},
|
|
341
|
-
]}>
|
|
342
|
-
<NetworkIcons_1.LayersIcon color={isAllSelected ? AppColors_1.AppColors.white : AppColors_1.AppColors.indigo600Alt} size={11}/>
|
|
343
|
-
<react_native_1.Text style={{
|
|
344
|
-
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
345
|
-
fontSize: 10,
|
|
346
|
-
color: isAllSelected ? AppColors_1.AppColors.white : AppColors_1.AppColors.indigo600Alt,
|
|
347
|
-
}}>
|
|
348
|
-
{t('analytics.allCategory')}: {categoryStats.totalCount}
|
|
349
|
-
</react_native_1.Text>
|
|
350
|
-
</TouchableScale_1.default>);
|
|
351
|
-
})()}
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
{(() => {
|
|
355
|
-
const isSelected = !analyticsFilters.categories.has('all') &&
|
|
356
|
-
analyticsFilters.categories.has('ecommerce');
|
|
357
|
-
return (<TouchableScale_1.default onPress={() => toggleCategoryFilter('ecommerce')} style={[
|
|
358
|
-
{
|
|
359
|
-
flexDirection: 'row',
|
|
360
|
-
alignItems: 'center',
|
|
361
|
-
gap: 5,
|
|
362
|
-
backgroundColor: isSelected ? AppColors_1.AppColors.amber600 : AppColors_1.AppColors.amber100,
|
|
363
|
-
paddingHorizontal: 8,
|
|
364
|
-
paddingVertical: 5,
|
|
365
|
-
borderRadius: 7,
|
|
366
|
-
borderWidth: 1,
|
|
367
|
-
borderColor: isSelected ? AppColors_1.AppColors.amber700 : AppColors_1.AppColors.amber200,
|
|
368
|
-
},
|
|
369
|
-
isSelected && {
|
|
370
|
-
shadowColor: AppColors_1.AppColors.amber600,
|
|
371
|
-
shadowOffset: { width: 0, height: 1 },
|
|
372
|
-
shadowOpacity: 0.28,
|
|
373
|
-
shadowRadius: 2.5,
|
|
374
|
-
elevation: 2,
|
|
375
|
-
},
|
|
376
|
-
]}>
|
|
377
|
-
<NetworkIcons_1.CartIcon color={isSelected ? AppColors_1.AppColors.white : AppColors_1.AppColors.amber700} size={11}/>
|
|
378
|
-
<react_native_1.Text style={{
|
|
379
|
-
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
380
|
-
fontSize: 10,
|
|
381
|
-
color: isSelected ? AppColors_1.AppColors.white : AppColors_1.AppColors.amber800Warm,
|
|
382
|
-
}}>
|
|
383
|
-
{t('analytics.ecommerceCategory')}: {categoryStats.ecommerce} ({categoryStats.ecommercePct}%)
|
|
384
|
-
</react_native_1.Text>
|
|
385
|
-
</TouchableScale_1.default>);
|
|
386
|
-
})()}
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
{(() => {
|
|
390
|
-
const isSelected = !analyticsFilters.categories.has('all') &&
|
|
391
|
-
analyticsFilters.categories.has('page_view');
|
|
392
|
-
return (<TouchableScale_1.default onPress={() => toggleCategoryFilter('page_view')} style={[
|
|
393
|
-
{
|
|
394
|
-
flexDirection: 'row',
|
|
395
|
-
alignItems: 'center',
|
|
396
|
-
gap: 5,
|
|
397
|
-
backgroundColor: isSelected ? AppColors_1.AppColors.sky600 : AppColors_1.AppColors.sky100,
|
|
398
|
-
paddingHorizontal: 8,
|
|
399
|
-
paddingVertical: 5,
|
|
400
|
-
borderRadius: 7,
|
|
401
|
-
borderWidth: 1,
|
|
402
|
-
borderColor: isSelected ? AppColors_1.AppColors.blue700 : AppColors_1.AppColors.sky400,
|
|
403
|
-
},
|
|
404
|
-
isSelected && {
|
|
405
|
-
shadowColor: AppColors_1.AppColors.sky600,
|
|
406
|
-
shadowOffset: { width: 0, height: 1 },
|
|
407
|
-
shadowOpacity: 0.28,
|
|
408
|
-
shadowRadius: 2.5,
|
|
409
|
-
elevation: 2,
|
|
410
|
-
},
|
|
411
|
-
]}>
|
|
412
|
-
<NetworkIcons_1.GlobeIcon color={isSelected ? AppColors_1.AppColors.white : AppColors_1.AppColors.sky600} size={11}/>
|
|
413
|
-
<react_native_1.Text style={{
|
|
414
|
-
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
415
|
-
fontSize: 10,
|
|
416
|
-
color: isSelected ? AppColors_1.AppColors.white : AppColors_1.AppColors.sky600,
|
|
417
|
-
}}>
|
|
418
|
-
{t('analytics.screensCategory')}: {categoryStats.page_view} ({categoryStats.page_viewPct}%)
|
|
419
|
-
</react_native_1.Text>
|
|
420
|
-
</TouchableScale_1.default>);
|
|
421
|
-
})()}
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
{(() => {
|
|
425
|
-
const isSelected = !analyticsFilters.categories.has('all') &&
|
|
426
|
-
analyticsFilters.categories.has('system');
|
|
427
|
-
return (<TouchableScale_1.default onPress={() => toggleCategoryFilter('system')} style={[
|
|
428
|
-
{
|
|
429
|
-
flexDirection: 'row',
|
|
430
|
-
alignItems: 'center',
|
|
431
|
-
gap: 5,
|
|
432
|
-
backgroundColor: isSelected ? AppColors_1.AppColors.violet600 : AppColors_1.AppColors.purple100,
|
|
433
|
-
paddingHorizontal: 8,
|
|
434
|
-
paddingVertical: 5,
|
|
435
|
-
borderRadius: 7,
|
|
436
|
-
borderWidth: 1,
|
|
437
|
-
borderColor: isSelected ? AppColors_1.AppColors.purpleShade700 : AppColors_1.AppColors.purple200,
|
|
438
|
-
},
|
|
439
|
-
isSelected && {
|
|
440
|
-
shadowColor: AppColors_1.AppColors.violet600,
|
|
441
|
-
shadowOffset: { width: 0, height: 1 },
|
|
442
|
-
shadowOpacity: 0.28,
|
|
443
|
-
shadowRadius: 2.5,
|
|
444
|
-
elevation: 2,
|
|
445
|
-
},
|
|
446
|
-
]}>
|
|
447
|
-
<NetworkIcons_1.BoltIcon color={isSelected ? AppColors_1.AppColors.white : AppColors_1.AppColors.purple} size={11}/>
|
|
448
|
-
<react_native_1.Text style={{
|
|
449
|
-
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
450
|
-
fontSize: 10,
|
|
451
|
-
color: isSelected ? AppColors_1.AppColors.white : AppColors_1.AppColors.brandPurple,
|
|
452
|
-
}}>
|
|
453
|
-
{t('analytics.systemCategory')}: {categoryStats.system} ({categoryStats.systemPct}%)
|
|
454
|
-
</react_native_1.Text>
|
|
455
|
-
</TouchableScale_1.default>);
|
|
456
|
-
})()}
|
|
17
|
+
<react_native_1.View style={{flexDirection:"row",alignItems:"center",gap:8}}>
|
|
18
|
+
{f?<react_native_1.TouchableOpacity style={styles_1.default.analyticsHeaderToggle}activeOpacity={.7}onPress={e=>{e.stopPropagation(),(0,InspectorContext_1.animateNextLayout)(),p(!s)}}>
|
|
19
|
+
<react_native_1.Text style={styles_1.default.analyticsHeaderToggleText}>
|
|
20
|
+
{a(s?"common.close":"analytics.eventDetails")}
|
|
21
|
+
</react_native_1.Text>
|
|
22
|
+
</react_native_1.TouchableOpacity>:<react_native_1.View style={{flexDirection:"row",alignItems:"center",gap:4,backgroundColor:`${AppColors_1.AppColors.purple}14`,paddingHorizontal:7,paddingVertical:3,borderRadius:6,borderWidth:1,borderColor:`${AppColors_1.AppColors.purple}25`}}>
|
|
23
|
+
<react_native_1.Text style={{fontFamily:AppFonts_1.AppFonts.interBold,fontSize:10,color:AppColors_1.AppColors.purple}}>
|
|
24
|
+
{b} {b===1?"event":"events"}
|
|
25
|
+
</react_native_1.Text>
|
|
26
|
+
</react_native_1.View>}
|
|
457
27
|
|
|
458
|
-
|
|
459
|
-
{(() => {
|
|
460
|
-
const isSelected = !analyticsFilters.categories.has('all') &&
|
|
461
|
-
analyticsFilters.categories.has('custom');
|
|
462
|
-
return (<TouchableScale_1.default onPress={() => toggleCategoryFilter('custom')} style={[
|
|
463
|
-
{
|
|
464
|
-
flexDirection: 'row',
|
|
465
|
-
alignItems: 'center',
|
|
466
|
-
gap: 5,
|
|
467
|
-
backgroundColor: isSelected ? AppColors_1.AppColors.pink600 : AppColors_1.AppColors.pink100,
|
|
468
|
-
paddingHorizontal: 8,
|
|
469
|
-
paddingVertical: 5,
|
|
470
|
-
borderRadius: 7,
|
|
471
|
-
borderWidth: 1,
|
|
472
|
-
borderColor: isSelected ? AppColors_1.AppColors.rose700 : AppColors_1.AppColors.roseBorder,
|
|
473
|
-
},
|
|
474
|
-
isSelected && {
|
|
475
|
-
shadowColor: AppColors_1.AppColors.pink600,
|
|
476
|
-
shadowOffset: { width: 0, height: 1 },
|
|
477
|
-
shadowOpacity: 0.28,
|
|
478
|
-
shadowRadius: 2.5,
|
|
479
|
-
elevation: 2,
|
|
480
|
-
},
|
|
481
|
-
]}>
|
|
482
|
-
<NetworkIcons_1.SparkleIcon color={isSelected ? AppColors_1.AppColors.white : AppColors_1.AppColors.brandPurple} size={11}/>
|
|
483
|
-
<react_native_1.Text style={{
|
|
484
|
-
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
485
|
-
fontSize: 10,
|
|
486
|
-
color: isSelected ? AppColors_1.AppColors.white : AppColors_1.AppColors.pink600,
|
|
487
|
-
}}>
|
|
488
|
-
{t('analytics.customCategory')}: {categoryStats.custom} ({categoryStats.customPct}%)
|
|
489
|
-
</react_native_1.Text>
|
|
490
|
-
</TouchableScale_1.default>);
|
|
491
|
-
})()}
|
|
28
|
+
<NetworkIcons_1.ChevronIcon direction={f?"up":"down"}size={16}color={AppColors_1.AppColors.grayTextWeak}/>
|
|
492
29
|
</react_native_1.View>
|
|
493
|
-
</react_native_1.
|
|
30
|
+
</react_native_1.TouchableOpacity>
|
|
494
31
|
|
|
495
32
|
|
|
496
|
-
|
|
497
|
-
marginTop: 2,
|
|
498
|
-
marginBottom: 8,
|
|
499
|
-
backgroundColor: AppColors_1.AppColors.grayBackground,
|
|
500
|
-
borderRadius: 10,
|
|
501
|
-
borderWidth: 1,
|
|
502
|
-
borderColor: AppColors_1.AppColors.dividerColor,
|
|
503
|
-
padding: 10,
|
|
504
|
-
}}>
|
|
505
|
-
|
|
506
|
-
<react_native_1.View style={{
|
|
507
|
-
flexDirection: 'row',
|
|
508
|
-
justifyContent: 'space-between',
|
|
509
|
-
alignItems: 'flex-start',
|
|
510
|
-
marginBottom: 6,
|
|
511
|
-
}}>
|
|
512
|
-
<react_native_1.View>
|
|
513
|
-
<react_native_1.View style={{ flexDirection: 'row', alignItems: 'baseline', gap: 6 }}>
|
|
514
|
-
<react_native_1.Text style={{
|
|
515
|
-
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
516
|
-
fontSize: 22,
|
|
517
|
-
color: AppColors_1.AppColors.primaryBlack,
|
|
518
|
-
lineHeight: 26,
|
|
519
|
-
}}>
|
|
520
|
-
{totalEvents}
|
|
521
|
-
</react_native_1.Text>
|
|
522
|
-
<react_native_1.Text style={{
|
|
523
|
-
fontFamily: AppFonts_1.AppFonts.interMedium,
|
|
524
|
-
fontSize: 10.5,
|
|
525
|
-
color: AppColors_1.AppColors.grayTextWeak,
|
|
526
|
-
}}>
|
|
527
|
-
{t('analytics.eventsInWindow')}
|
|
528
|
-
</react_native_1.Text>
|
|
529
|
-
</react_native_1.View>
|
|
530
|
-
</react_native_1.View>
|
|
531
|
-
|
|
33
|
+
{f&&<react_native_1.View style={{marginTop:10}}>
|
|
532
34
|
|
|
533
|
-
<react_native_1.View style={{
|
|
534
|
-
|
|
535
|
-
flexDirection:
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
547
|
-
fontSize: 9.5,
|
|
548
|
-
color: AppColors_1.AppColors.purple,
|
|
549
|
-
}}>
|
|
550
|
-
{t('analytics.eventVelocity', { rate: histogramData.eventRate })}
|
|
551
|
-
</react_native_1.Text>
|
|
552
|
-
</react_native_1.View>
|
|
35
|
+
<react_native_1.View style={{marginBottom:8,backgroundColor:AppColors_1.AppColors.grayBackground,borderRadius:10,borderWidth:1,borderColor:AppColors_1.AppColors.dividerColor,padding:10}}>
|
|
36
|
+
|
|
37
|
+
<react_native_1.View style={{flexDirection:"row",justifyContent:"space-between",alignItems:"flex-start",marginBottom:6}}>
|
|
38
|
+
<react_native_1.View>
|
|
39
|
+
<react_native_1.View style={{flexDirection:"row",alignItems:"baseline",gap:6}}>
|
|
40
|
+
<react_native_1.Text style={{fontFamily:AppFonts_1.AppFonts.interBold,fontSize:22,color:AppColors_1.AppColors.primaryBlack,lineHeight:26}}>
|
|
41
|
+
{b}
|
|
42
|
+
</react_native_1.Text>
|
|
43
|
+
<react_native_1.Text style={{fontFamily:AppFonts_1.AppFonts.interMedium,fontSize:10.5,color:AppColors_1.AppColors.grayTextWeak}}>
|
|
44
|
+
{a("analytics.eventsInWindow")}
|
|
45
|
+
</react_native_1.Text>
|
|
46
|
+
</react_native_1.View>
|
|
47
|
+
</react_native_1.View>
|
|
553
48
|
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
alignItems:
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
borderRadius: 4,
|
|
562
|
-
borderWidth: 1,
|
|
563
|
-
borderColor: `${AppColors_1.AppColors.emerald600}30`,
|
|
564
|
-
}}>
|
|
565
|
-
<NetworkIcons_1.MoneyIcon color={AppColors_1.AppColors.emerald600} size={10}/>
|
|
566
|
-
<react_native_1.Text style={{
|
|
567
|
-
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
568
|
-
fontSize: 9.5,
|
|
569
|
-
color: AppColors_1.AppColors.emerald600,
|
|
570
|
-
}}>
|
|
571
|
-
${categoryStats.totalRevenue.toFixed(2)}
|
|
572
|
-
</react_native_1.Text>
|
|
573
|
-
</react_native_1.View>)}
|
|
574
|
-
</react_native_1.View>
|
|
575
|
-
</react_native_1.View>
|
|
49
|
+
|
|
50
|
+
<react_native_1.View style={{flexDirection:"row",alignItems:"center",gap:5}}>
|
|
51
|
+
<react_native_1.View style={{flexDirection:"row",alignItems:"center",gap:3,backgroundColor:`${AppColors_1.AppColors.purple}14`,paddingHorizontal:6,paddingVertical:2.5,borderRadius:4,borderWidth:1,borderColor:`${AppColors_1.AppColors.purple}2E`}}>
|
|
52
|
+
<react_native_1.Text style={{fontFamily:AppFonts_1.AppFonts.interBold,fontSize:9.5,color:AppColors_1.AppColors.purple}}>
|
|
53
|
+
{a("analytics.eventVelocity",{rate:y.eventRate})}
|
|
54
|
+
</react_native_1.Text>
|
|
55
|
+
</react_native_1.View>
|
|
576
56
|
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
<react_native_svg_1.LinearGradient id="crashlyticsAreaGrad" x1="0" y1="0" x2="0" y2="1">
|
|
586
|
-
<react_native_svg_1.Stop offset="0%" stopColor="#8B5CF6" stopOpacity="0.25"/>
|
|
587
|
-
<react_native_svg_1.Stop offset="80%" stopColor="#8B5CF6" stopOpacity="0.04"/>
|
|
588
|
-
<react_native_svg_1.Stop offset="100%" stopColor="#8B5CF6" stopOpacity="0.0"/>
|
|
589
|
-
</react_native_svg_1.LinearGradient>
|
|
590
|
-
</react_native_svg_1.Defs>
|
|
57
|
+
{k.totalRevenue>0&&<react_native_1.View style={{flexDirection:"row",alignItems:"center",gap:3,backgroundColor:`${AppColors_1.AppColors.emerald600}15`,paddingHorizontal:6,paddingVertical:2.5,borderRadius:4,borderWidth:1,borderColor:`${AppColors_1.AppColors.emerald600}30`}}>
|
|
58
|
+
<NetworkIcons_1.MoneyIcon color={AppColors_1.AppColors.emerald600}size={10}/>
|
|
59
|
+
<react_native_1.Text style={{fontFamily:AppFonts_1.AppFonts.interBold,fontSize:9.5,color:AppColors_1.AppColors.emerald600}}>
|
|
60
|
+
${k.totalRevenue.toFixed(2)}
|
|
61
|
+
</react_native_1.Text>
|
|
62
|
+
</react_native_1.View>}
|
|
63
|
+
</react_native_1.View>
|
|
64
|
+
</react_native_1.View>
|
|
591
65
|
|
|
592
66
|
|
|
593
|
-
<
|
|
594
|
-
|
|
67
|
+
<react_native_1.View style={{height:u,position:"relative",overflow:"hidden",borderRadius:8}}>
|
|
68
|
+
<react_native_svg_1.default width="100%"height={u}viewBox={`0 0 ${A} ${u}`}preserveAspectRatio="none">
|
|
69
|
+
<react_native_svg_1.Defs>
|
|
70
|
+
<react_native_svg_1.LinearGradient id="crashlyticsBarGrad"x1="0"y1="0"x2="0"y2="1">
|
|
71
|
+
<react_native_svg_1.Stop offset="0%"stopColor="#8B5CF6"stopOpacity="0.9"/>
|
|
72
|
+
<react_native_svg_1.Stop offset="100%"stopColor="#6366F1"stopOpacity="0.6"/>
|
|
73
|
+
</react_native_svg_1.LinearGradient>
|
|
74
|
+
<react_native_svg_1.LinearGradient id="crashlyticsAreaGrad"x1="0"y1="0"x2="0"y2="1">
|
|
75
|
+
<react_native_svg_1.Stop offset="0%"stopColor="#8B5CF6"stopOpacity="0.25"/>
|
|
76
|
+
<react_native_svg_1.Stop offset="80%"stopColor="#8B5CF6"stopOpacity="0.04"/>
|
|
77
|
+
<react_native_svg_1.Stop offset="100%"stopColor="#8B5CF6"stopOpacity="0.0"/>
|
|
78
|
+
</react_native_svg_1.LinearGradient>
|
|
79
|
+
</react_native_svg_1.Defs>
|
|
595
80
|
|
|
596
|
-
|
|
597
|
-
|
|
81
|
+
|
|
82
|
+
<react_native_svg_1.Line x1="6"y1={u-6}x2={A-6}y2={u-6}stroke="#E2E8F0"strokeWidth="1"/>
|
|
83
|
+
<react_native_svg_1.Line x1="6"y1={u/2}x2={A-6}y2={u/2}stroke="#F1F5F9"strokeWidth="1"strokeDasharray="4,4"/>
|
|
598
84
|
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
const isSelected = selectedBucketIdx === idx;
|
|
602
|
-
const barWidth = 10;
|
|
603
|
-
const barX = b.x - barWidth / 2;
|
|
604
|
-
const barHeight = Math.max(3, chartHeight - 8 - b.y);
|
|
605
|
-
const barY = chartHeight - 8 - barHeight;
|
|
606
|
-
return (<react_native_svg_1.G key={`bar-${b.index}`}>
|
|
607
|
-
|
|
608
|
-
<react_native_svg_1.Rect x={barX} y={6} width={barWidth} height={chartHeight - 14} rx={3} fill={isSelected ? '#EDE9FE' : '#F8FAFC'}/>
|
|
85
|
+
|
|
86
|
+
<react_native_svg_1.Path d={y.areaPath}fill="url(#crashlyticsAreaGrad)"/>
|
|
609
87
|
|
|
610
|
-
|
|
611
|
-
|
|
88
|
+
|
|
89
|
+
{y.buckets.map((e,o)=>{const d=T===o,n=10,c=e.x-n/2,_=Math.max(3,u-8-e.y),w=u-8-_;return<react_native_svg_1.G key={`bar-${e.index}`}>
|
|
90
|
+
|
|
91
|
+
<react_native_svg_1.Rect x={c}y={6}width={n}height={u-14}rx={3}fill={d?"#EDE9FE":"#F8FAFC"}/>
|
|
612
92
|
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
</react_native_svg_1.G>);
|
|
616
|
-
})}
|
|
93
|
+
|
|
94
|
+
{e.total>0&&<react_native_svg_1.Rect x={c}y={w}width={n}height={_}rx={3}fill="url(#crashlyticsBarGrad)"/>}
|
|
617
95
|
|
|
618
|
-
|
|
619
|
-
|
|
96
|
+
|
|
97
|
+
{d&&<react_native_svg_1.Line x1={e.x}y1={4}x2={e.x}y2={u-6}stroke="#8B5CF6"strokeWidth="1.5"strokeDasharray="2,2"/>}
|
|
98
|
+
</react_native_svg_1.G>})}
|
|
620
99
|
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
<react_native_svg_1.Circle cx={histogramData.buckets[histogramData.buckets.length - 1].x} cy={histogramData.buckets[histogramData.buckets.length - 1].y} r="5.5" fill="#8B5CF6" opacity="0.25"/>
|
|
624
|
-
<react_native_svg_1.Circle cx={histogramData.buckets[histogramData.buckets.length - 1].x} cy={histogramData.buckets[histogramData.buckets.length - 1].y} r="3" fill="#7C3AED"/>
|
|
625
|
-
</react_native_svg_1.G>)}
|
|
626
|
-
</react_native_svg_1.default>
|
|
100
|
+
|
|
101
|
+
<react_native_svg_1.Path d={y.linePath}fill="none"stroke="#8B5CF6"strokeWidth="2"strokeLinecap="round"strokeLinejoin="round"/>
|
|
627
102
|
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
bottom: 0,
|
|
635
|
-
flexDirection: 'row',
|
|
636
|
-
}}>
|
|
637
|
-
{histogramData.buckets.map((b, idx) => (<react_native_1.TouchableOpacity key={b.index} style={{ flex: 1, height: '100%' }} activeOpacity={0.8} onPress={() => setSelectedBucketIdx(selectedBucketIdx === idx ? null : idx)}/>))}
|
|
638
|
-
</react_native_1.View>
|
|
639
|
-
</react_native_1.View>
|
|
103
|
+
|
|
104
|
+
{y.buckets.length>0&&<react_native_svg_1.G>
|
|
105
|
+
<react_native_svg_1.Circle cx={y.buckets[y.buckets.length-1].x}cy={y.buckets[y.buckets.length-1].y}r="5.5"fill="#8B5CF6"opacity="0.25"/>
|
|
106
|
+
<react_native_svg_1.Circle cx={y.buckets[y.buckets.length-1].x}cy={y.buckets[y.buckets.length-1].y}r="3"fill="#7C3AED"/>
|
|
107
|
+
</react_native_svg_1.G>}
|
|
108
|
+
</react_native_svg_1.default>
|
|
640
109
|
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
justifyContent: 'space-between',
|
|
646
|
-
backgroundColor: AppColors_1.AppColors.white,
|
|
647
|
-
borderRadius: 6,
|
|
648
|
-
paddingHorizontal: 8,
|
|
649
|
-
paddingVertical: 4,
|
|
650
|
-
marginTop: 4,
|
|
651
|
-
borderWidth: 1,
|
|
652
|
-
borderColor: AppColors_1.AppColors.brandPurple,
|
|
653
|
-
}}>
|
|
654
|
-
<react_native_1.Text style={{
|
|
655
|
-
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
656
|
-
fontSize: 10,
|
|
657
|
-
color: AppColors_1.AppColors.primaryBlack,
|
|
658
|
-
}}>
|
|
659
|
-
{t('analytics.selectedBucket', {
|
|
660
|
-
time: selectedBucket.ageLabel,
|
|
661
|
-
count: selectedBucket.total,
|
|
662
|
-
})}
|
|
663
|
-
</react_native_1.Text>
|
|
664
|
-
<react_native_1.View style={{ flexDirection: 'row', alignItems: 'center', gap: 6 }}>
|
|
665
|
-
{selectedBucket.ecommerce > 0 && (<react_native_1.Text style={{ fontSize: 9, fontFamily: AppFonts_1.AppFonts.interBold, color: AppColors_1.AppColors.amber700 }}>
|
|
666
|
-
Ecom: {selectedBucket.ecommerce}
|
|
667
|
-
</react_native_1.Text>)}
|
|
668
|
-
{selectedBucket.page_view > 0 && (<react_native_1.Text style={{ fontSize: 9, fontFamily: AppFonts_1.AppFonts.interBold, color: AppColors_1.AppColors.sky500 }}>
|
|
669
|
-
Screen: {selectedBucket.page_view}
|
|
670
|
-
</react_native_1.Text>)}
|
|
671
|
-
{selectedBucket.custom > 0 && (<react_native_1.Text style={{ fontSize: 9, fontFamily: AppFonts_1.AppFonts.interBold, color: AppColors_1.AppColors.brandPurple }}>
|
|
672
|
-
Custom: {selectedBucket.custom}
|
|
673
|
-
</react_native_1.Text>)}
|
|
110
|
+
|
|
111
|
+
<react_native_1.View style={{position:"absolute",top:0,left:0,right:0,bottom:0,flexDirection:"row"}}>
|
|
112
|
+
{y.buckets.map((e,o)=><react_native_1.TouchableOpacity key={e.index}style={{flex:1,height:"100%"}}activeOpacity={.8}onPress={()=>V(T===o?null:o)}/>)}
|
|
113
|
+
</react_native_1.View>
|
|
674
114
|
</react_native_1.View>
|
|
675
|
-
</react_native_1.View>)}
|
|
676
115
|
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
color: AppColors_1.AppColors.grayTextWeak,
|
|
695
|
-
}}>
|
|
696
|
-
-40s
|
|
697
|
-
</react_native_1.Text>
|
|
698
|
-
<react_native_1.Text style={{
|
|
699
|
-
fontFamily: AppFonts_1.AppFonts.interMedium,
|
|
700
|
-
fontSize: 8.5,
|
|
701
|
-
color: AppColors_1.AppColors.grayTextWeak,
|
|
702
|
-
}}>
|
|
703
|
-
-20s
|
|
704
|
-
</react_native_1.Text>
|
|
705
|
-
<react_native_1.Text style={{
|
|
706
|
-
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
707
|
-
fontSize: 8.5,
|
|
708
|
-
color: AppColors_1.AppColors.brandPurple,
|
|
709
|
-
}}>
|
|
710
|
-
{t('analytics.timeNow')}
|
|
711
|
-
</react_native_1.Text>
|
|
712
|
-
</react_native_1.View>
|
|
713
|
-
</react_native_1.View>
|
|
116
|
+
|
|
117
|
+
{t&&<react_native_1.View style={{flexDirection:"row",alignItems:"center",justifyContent:"space-between",backgroundColor:AppColors_1.AppColors.white,borderRadius:6,paddingHorizontal:8,paddingVertical:4,marginTop:4,borderWidth:1,borderColor:AppColors_1.AppColors.brandPurple}}>
|
|
118
|
+
<react_native_1.Text style={{fontFamily:AppFonts_1.AppFonts.interBold,fontSize:10,color:AppColors_1.AppColors.primaryBlack}}>
|
|
119
|
+
{a("analytics.selectedBucket",{time:t.ageLabel,count:t.total})}
|
|
120
|
+
</react_native_1.Text>
|
|
121
|
+
<react_native_1.View style={{flexDirection:"row",alignItems:"center",gap:6}}>
|
|
122
|
+
{t.ecommerce>0&&<react_native_1.Text style={{fontSize:9,fontFamily:AppFonts_1.AppFonts.interBold,color:AppColors_1.AppColors.amber700}}>
|
|
123
|
+
Ecom: {t.ecommerce}
|
|
124
|
+
</react_native_1.Text>}
|
|
125
|
+
{t.page_view>0&&<react_native_1.Text style={{fontSize:9,fontFamily:AppFonts_1.AppFonts.interBold,color:AppColors_1.AppColors.sky500}}>
|
|
126
|
+
Screen: {t.page_view}
|
|
127
|
+
</react_native_1.Text>}
|
|
128
|
+
{t.custom>0&&<react_native_1.Text style={{fontSize:9,fontFamily:AppFonts_1.AppFonts.interBold,color:AppColors_1.AppColors.brandPurple}}>
|
|
129
|
+
Custom: {t.custom}
|
|
130
|
+
</react_native_1.Text>}
|
|
131
|
+
</react_native_1.View>
|
|
132
|
+
</react_native_1.View>}
|
|
714
133
|
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
marginBottom: 6,
|
|
729
|
-
}}>
|
|
730
|
-
<react_native_1.View style={{ flexDirection: 'row', alignItems: 'center', gap: 4 }}>
|
|
731
|
-
<NetworkIcons_1.PinIcon color={AppColors_1.AppColors.sky600} size={11}/>
|
|
732
|
-
<react_native_1.Text style={{
|
|
733
|
-
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
734
|
-
fontSize: 9.5,
|
|
735
|
-
color: AppColors_1.AppColors.sky600,
|
|
736
|
-
letterSpacing: 0.3,
|
|
737
|
-
}}>
|
|
738
|
-
TOP SCREENS (REALTIME)
|
|
134
|
+
|
|
135
|
+
<react_native_1.View style={{flexDirection:"row",justifyContent:"space-between",marginTop:4,paddingHorizontal:4}}>
|
|
136
|
+
<react_native_1.Text style={{fontFamily:AppFonts_1.AppFonts.interMedium,fontSize:8.5,color:AppColors_1.AppColors.grayTextWeak}}>
|
|
137
|
+
-60s
|
|
138
|
+
</react_native_1.Text>
|
|
139
|
+
<react_native_1.Text style={{fontFamily:AppFonts_1.AppFonts.interMedium,fontSize:8.5,color:AppColors_1.AppColors.grayTextWeak}}>
|
|
140
|
+
-40s
|
|
141
|
+
</react_native_1.Text>
|
|
142
|
+
<react_native_1.Text style={{fontFamily:AppFonts_1.AppFonts.interMedium,fontSize:8.5,color:AppColors_1.AppColors.grayTextWeak}}>
|
|
143
|
+
-20s
|
|
144
|
+
</react_native_1.Text>
|
|
145
|
+
<react_native_1.Text style={{fontFamily:AppFonts_1.AppFonts.interBold,fontSize:8.5,color:AppColors_1.AppColors.brandPurple}}>
|
|
146
|
+
{a("analytics.timeNow")}
|
|
739
147
|
</react_native_1.Text>
|
|
740
148
|
</react_native_1.View>
|
|
741
|
-
<react_native_1.Text style={{
|
|
742
|
-
fontFamily: AppFonts_1.AppFonts.interMedium,
|
|
743
|
-
fontSize: 9,
|
|
744
|
-
color: AppColors_1.AppColors.grayTextWeak,
|
|
745
|
-
}}>
|
|
746
|
-
Views
|
|
747
|
-
</react_native_1.Text>
|
|
748
149
|
</react_native_1.View>
|
|
749
150
|
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
}}>
|
|
758
|
-
<react_native_1.Text style={{
|
|
759
|
-
fontFamily: AppFonts_1.AppFonts.interMedium,
|
|
760
|
-
fontSize: 10,
|
|
761
|
-
color: AppColors_1.AppColors.primaryBlack,
|
|
762
|
-
}} numberOfLines={1}>
|
|
763
|
-
{scr.name}
|
|
151
|
+
|
|
152
|
+
{E.length>0&&<react_native_1.View style={{marginTop:4,backgroundColor:`${AppColors_1.AppColors.sky500}0A`,borderRadius:8,borderWidth:1,borderColor:`${AppColors_1.AppColors.sky500}22`,padding:8}}>
|
|
153
|
+
<react_native_1.View style={{flexDirection:"row",justifyContent:"space-between",alignItems:"center",marginBottom:6}}>
|
|
154
|
+
<react_native_1.View style={{flexDirection:"row",alignItems:"center",gap:4}}>
|
|
155
|
+
<NetworkIcons_1.PinIcon color={AppColors_1.AppColors.sky600}size={11}/>
|
|
156
|
+
<react_native_1.Text style={{fontFamily:AppFonts_1.AppFonts.interBold,fontSize:9.5,color:AppColors_1.AppColors.sky600,letterSpacing:.3}}>
|
|
157
|
+
TOP SCREENS (REALTIME)
|
|
764
158
|
</react_native_1.Text>
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
159
|
+
</react_native_1.View>
|
|
160
|
+
<react_native_1.Text style={{fontFamily:AppFonts_1.AppFonts.interMedium,fontSize:9,color:AppColors_1.AppColors.grayTextWeak}}>
|
|
161
|
+
Views
|
|
162
|
+
</react_native_1.Text>
|
|
163
|
+
</react_native_1.View>
|
|
164
|
+
|
|
165
|
+
<react_native_1.View style={{gap:4}}>
|
|
166
|
+
{E.map(e=><react_native_1.View key={e.name}>
|
|
167
|
+
<react_native_1.View style={{flexDirection:"row",justifyContent:"space-between",alignItems:"center",marginBottom:2}}>
|
|
168
|
+
<react_native_1.Text style={{fontFamily:AppFonts_1.AppFonts.interMedium,fontSize:10,color:AppColors_1.AppColors.primaryBlack}}numberOfLines={1}>
|
|
169
|
+
{e.name}
|
|
170
|
+
</react_native_1.Text>
|
|
171
|
+
<react_native_1.Text style={{fontFamily:AppFonts_1.AppFonts.interBold,fontSize:9.5,color:AppColors_1.AppColors.sky600}}>
|
|
172
|
+
{e.count} ({e.pct}%)
|
|
173
|
+
</react_native_1.Text>
|
|
174
|
+
</react_native_1.View>
|
|
175
|
+
|
|
176
|
+
<react_native_1.View style={{height:3,borderRadius:1.5,backgroundColor:`${AppColors_1.AppColors.sky500}22`,overflow:"hidden"}}>
|
|
177
|
+
<react_native_1.View style={{height:"100%",width:`${e.barWidthPct}%`,backgroundColor:AppColors_1.AppColors.sky500}}/>
|
|
178
|
+
</react_native_1.View>
|
|
179
|
+
</react_native_1.View>)}
|
|
180
|
+
</react_native_1.View>
|
|
181
|
+
</react_native_1.View>}
|
|
182
|
+
|
|
183
|
+
|
|
184
|
+
{s&&<>
|
|
185
|
+
|
|
186
|
+
<react_native_1.View style={styles_1.default.analyticsStatsRow}>
|
|
187
|
+
<react_native_1.View style={styles_1.default.analyticsStatBox}>
|
|
188
|
+
<react_native_1.Text style={styles_1.default.analyticsStatValue}>{b}</react_native_1.Text>
|
|
189
|
+
<react_native_1.Text style={styles_1.default.analyticsStatLabel}>{a("analytics.eventCount",{count:b})}</react_native_1.Text>
|
|
190
|
+
</react_native_1.View>
|
|
191
|
+
<react_native_1.View style={styles_1.default.analyticsStatBox}>
|
|
192
|
+
<react_native_1.Text style={styles_1.default.analyticsStatValue}>
|
|
193
|
+
{Object.keys(B).length}
|
|
771
194
|
</react_native_1.Text>
|
|
195
|
+
<react_native_1.Text style={styles_1.default.analyticsStatLabel}>{a("analytics.props")}</react_native_1.Text>
|
|
772
196
|
</react_native_1.View>
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
overflow: 'hidden',
|
|
779
|
-
}}>
|
|
780
|
-
<react_native_1.View style={{
|
|
781
|
-
height: '100%',
|
|
782
|
-
width: `${scr.barWidthPct}%`,
|
|
783
|
-
backgroundColor: AppColors_1.AppColors.sky500,
|
|
784
|
-
}}/>
|
|
197
|
+
<react_native_1.View style={styles_1.default.analyticsStatBox}>
|
|
198
|
+
<react_native_1.Text style={styles_1.default.analyticsStatValue}>
|
|
199
|
+
{Object.keys(S).length}
|
|
200
|
+
</react_native_1.Text>
|
|
201
|
+
<react_native_1.Text style={styles_1.default.analyticsStatLabel}>{a("analytics.defaultParameters")}</react_native_1.Text>
|
|
785
202
|
</react_native_1.View>
|
|
786
|
-
</react_native_1.View>
|
|
787
|
-
|
|
788
|
-
|
|
203
|
+
</react_native_1.View>
|
|
204
|
+
|
|
205
|
+
|
|
206
|
+
{(I||D)&&<react_native_1.View style={styles_1.default.analyticsHeaderDetails}>
|
|
207
|
+
{I&&<react_native_1.View style={{marginBottom:10}}>
|
|
208
|
+
<react_native_1.Text style={styles_1.default.detailsGroupTitle}>{a("analytics.userProperties")}</react_native_1.Text>
|
|
209
|
+
{Object.entries(B).map(([e,o])=><react_native_1.View key={e}style={styles_1.default.detailsRow}>
|
|
210
|
+
<react_native_1.Text style={styles_1.default.detailsKey}selectable={!0}>{e}</react_native_1.Text>
|
|
211
|
+
<react_native_1.Text style={styles_1.default.detailsValue}selectable={!0}>{String(o)}</react_native_1.Text>
|
|
212
|
+
</react_native_1.View>)}
|
|
213
|
+
</react_native_1.View>}
|
|
789
214
|
|
|
215
|
+
{D&&<react_native_1.View>
|
|
216
|
+
<react_native_1.Text style={styles_1.default.detailsGroupTitle}>{a("analytics.defaultParameters")}</react_native_1.Text>
|
|
217
|
+
{Object.entries(S).map(([e,o])=><react_native_1.View key={e}style={styles_1.default.detailsRow}>
|
|
218
|
+
<react_native_1.Text style={styles_1.default.detailsKey}selectable={!0}>{e}</react_native_1.Text>
|
|
219
|
+
<react_native_1.Text style={styles_1.default.detailsValue}selectable={!0}>{String(o)}</react_native_1.Text>
|
|
220
|
+
</react_native_1.View>)}
|
|
221
|
+
</react_native_1.View>}
|
|
222
|
+
</react_native_1.View>}
|
|
223
|
+
</>}
|
|
224
|
+
</react_native_1.View>}
|
|
225
|
+
</react_native_1.View>}),AnalyticsTab=react_1.default.memo(()=>{const{t:a}=(0,i18n_1.useTranslation)(),{analyticsEvents:l,filteredAnalyticsEvents:r,analyticsSearch:s,setAnalyticsSearch:p,analyticsFilters:f,setAnalyticsFilters:R,handleDelete:L,selectedEvent:B,setSelectedEvent:S,newEventIds:v,logRouteMapRef:I,isAnalyticsLayoutReady:D,setIsAnalyticsLayoutReady:b,isAnalyticsPaused:k,setIsAnalyticsPaused:E,isAnalyticsFilterApplied:h}=(0,InspectorContext_1.useInspector)(),u=(0,react_1.useRef)(null),[A,T]=(0,react_1.useState)(!1),V=(0,react_1.useMemo)(()=>{let t=0,e=0,o=0,d=0;for(const c of l){const _=(0,helpers_1.getEventCategory)(c.name),w=c.count||1;_==="ecommerce"?t+=w:_==="page_view"?e+=w:_==="system"?o+=w:d+=w}const n=t+e+o+d;return{ecommerce:t,page_view:e,system:o,custom:d,totalCount:n}},[l]),F=(0,react_1.useCallback)(t=>{(0,InspectorContext_1.animateNextLayout)(),R(e=>{if(t==="all")return{...e,categories:new Set(["all"])};const o=new Set(e.categories);if(o.has("all"))o.delete("all"),o.add(t);else if(o.has(t))o.delete(t),o.size===0&&o.add("all");else if(o.add(t),o.has("ecommerce")&&o.has("page_view")&&o.has("system")&&o.has("custom"))return{...e,categories:new Set(["all"])};return{...e,categories:o}})},[R]),$=(0,react_1.useCallback)((t,e)=>t?.id?.toString()??e.toString(),[]),y=(0,react_1.useCallback)(({item:t,index:e})=>{const o=r[e+1],d=r[e-1],n=o?t.timestamp-o.timestamp:void 0,c=Math.floor(t.timestamp/6e4),_=d?Math.floor(d.timestamp/6e4):-1,w=e===0||c!==_;return<AnalyticsEventCard_1.default event={t}onPress={()=>{S(t)}}isNew={v.has(t.id)}searchStr={s}isFirst={e===0}isLast={e===r.length-1}msSincePrev={n}showTimestamp={w}computedScreenName={(()=>{if(!t)return"";const O=t.screenName||t.screenClass||t.pageTitle||t.pageLocation||t.params?.firebase_screen||t.params?.screen_name||t.params?.firebase_screen_class||t.params?.screen_class;let P=typeof O=="string"?O:O?JSON.stringify(O):"";const z=I.current.get(t.id+1e6);if(!P&&z&&z.path!=="Navigators"){const M=z.path.split(" \u2794 ");P=M[M.length-1]}return P})()}/>},[r,s,v,S,I]);return<>
|
|
790
226
|
|
|
791
|
-
{
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
<react_native_1.
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
227
|
+
{B==null&&<react_native_1.View style={{backgroundColor:AppColors_1.AppColors.white,borderBottomWidth:1,borderBottomColor:AppColors_1.AppColors.dividerColor,paddingBottom:6}}>
|
|
228
|
+
<react_native_1.View style={[styles_1.default.toolbarRow,{marginTop:12,marginBottom:8}]}>
|
|
229
|
+
<react_native_1.View style={styles_1.default.searchContainer}>
|
|
230
|
+
<NetworkIcons_1.SearchIcon color={AppColors_1.AppColors.grayTextWeak}size={16}/>
|
|
231
|
+
<react_native_1.TextInput placeholder="Search events..."placeholderTextColor={AppColors_1.AppColors.grayTextWeak}value={s}onChangeText={p}style={styles_1.default.searchInput}autoCorrect={!1}autoCapitalize="none"/>
|
|
232
|
+
{s.length>0&&<react_native_1.View style={{flexDirection:"row",alignItems:"center",gap:4}}>
|
|
233
|
+
<react_native_1.View style={{backgroundColor:`${AppColors_1.AppColors.purple}20`,borderRadius:10,paddingHorizontal:6,paddingVertical:1.5}}>
|
|
234
|
+
<react_native_1.Text style={{color:AppColors_1.AppColors.purple,fontSize:9.5,fontFamily:AppFonts_1.AppFonts.interBold}}>
|
|
235
|
+
{r.length}
|
|
236
|
+
</react_native_1.Text>
|
|
237
|
+
</react_native_1.View>
|
|
238
|
+
<react_native_1.Pressable onPress={()=>p("")}hitSlop={10}style={styles_1.default.clearBtn}>
|
|
239
|
+
<NetworkIcons_1.ClearIcon color={AppColors_1.AppColors.grayTextWeak}size={13}/>
|
|
240
|
+
</react_native_1.Pressable>
|
|
241
|
+
</react_native_1.View>}
|
|
803
242
|
</react_native_1.View>
|
|
804
|
-
<react_native_1.View style={styles_1.default.
|
|
805
|
-
<react_native_1.
|
|
806
|
-
{
|
|
807
|
-
</react_native_1.
|
|
808
|
-
|
|
243
|
+
<react_native_1.View style={styles_1.default.toolbarRight}>
|
|
244
|
+
<react_native_1.TouchableOpacity style={[styles_1.default.toolbarBtn,k&&{borderColor:`${AppColors_1.AppColors.darkOrange}50`,backgroundColor:`${AppColors_1.AppColors.darkOrange}18`}]}onPress={()=>E(t=>!t)}hitSlop={6}>
|
|
245
|
+
<NetworkIcons_1.HeaderPauseIcon isPaused={k}color={k?AppColors_1.AppColors.darkOrange:AppColors_1.AppColors.grayTextStrong}size={16}/>
|
|
246
|
+
</react_native_1.TouchableOpacity>
|
|
247
|
+
|
|
248
|
+
|
|
249
|
+
<react_native_1.TouchableOpacity style={[styles_1.default.toolbarBtn,h&&{borderColor:`${AppColors_1.AppColors.brandPurple}60`,backgroundColor:`${AppColors_1.AppColors.brandPurple}15`}]}onPress={()=>T(!0)}hitSlop={6}>
|
|
250
|
+
<NetworkIcons_1.FilterIcon color={h?AppColors_1.AppColors.brandPurple:AppColors_1.AppColors.grayTextStrong}size={15}/>
|
|
251
|
+
{h&&<react_native_1.View style={{position:"absolute",top:2,right:2,width:7,height:7,borderRadius:3.5,backgroundColor:AppColors_1.AppColors.darkOrange,borderWidth:1,borderColor:AppColors_1.AppColors.white}}/>}
|
|
252
|
+
</react_native_1.TouchableOpacity>
|
|
253
|
+
|
|
254
|
+
<react_native_1.TouchableOpacity style={[styles_1.default.toolbarBtn,{borderColor:`${AppColors_1.AppColors.errorColor}38`,backgroundColor:`${AppColors_1.AppColors.errorColor}0F`}]}onPress={L}hitSlop={6}>
|
|
255
|
+
<NetworkIcons_1.TrashIcon color={AppColors_1.AppColors.errorColor}size={15}/>
|
|
256
|
+
</react_native_1.TouchableOpacity>
|
|
809
257
|
</react_native_1.View>
|
|
810
258
|
</react_native_1.View>
|
|
811
259
|
|
|
812
260
|
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
<
|
|
819
|
-
|
|
820
|
-
|
|
261
|
+
<react_native_1.ScrollView horizontal showsHorizontalScrollIndicator={!1}style={{marginVertical:4,maxHeight:46}}contentContainerStyle={{paddingHorizontal:16,paddingBottom:4,flexDirection:"row",alignItems:"center",gap:8}}>
|
|
262
|
+
|
|
263
|
+
{(()=>{const t=f.categories.has("all");return<TouchableScale_1.default onPress={()=>F("all")}>
|
|
264
|
+
<react_native_1.View style={[styles_1.default.statusFilterChip,{backgroundColor:t?AppColors_1.AppColors.indigo600Alt:AppColors_1.AppColors.indigo50,borderColor:t?AppColors_1.AppColors.indigo600:AppColors_1.AppColors.indigo400,borderRadius:8,paddingHorizontal:10,paddingVertical:6},t&&{shadowColor:AppColors_1.AppColors.indigo600Alt,shadowOffset:{width:0,height:1},shadowOpacity:.28,shadowRadius:2.5,elevation:2}]}>
|
|
265
|
+
<react_native_1.View style={{flexDirection:"row",alignItems:"center",gap:6}}>
|
|
266
|
+
<NetworkIcons_1.LayersIcon size={13}color={t?AppColors_1.AppColors.white:AppColors_1.AppColors.indigo600Alt}/>
|
|
267
|
+
<react_native_1.Text numberOfLines={1}style={[styles_1.default.statusFilterText,{color:t?AppColors_1.AppColors.white:AppColors_1.AppColors.indigo600Alt,fontFamily:AppFonts_1.AppFonts.interBold}]}>
|
|
268
|
+
{a("common.all","All")} ({V.totalCount})
|
|
269
|
+
</react_native_1.Text>
|
|
270
|
+
</react_native_1.View>
|
|
271
|
+
</react_native_1.View>
|
|
272
|
+
</TouchableScale_1.default>})()}
|
|
821
273
|
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
<
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
})
|
|
833
|
-
const AnalyticsTab = react_1.default.memo(() => {
|
|
834
|
-
const { t } = (0, i18n_1.useTranslation)();
|
|
835
|
-
const { filteredAnalyticsEvents, analyticsSearch, setAnalyticsSearch, handleDelete, selectedEvent, setSelectedEvent, newEventIds, logRouteMapRef, isAnalyticsLayoutReady, setIsAnalyticsLayoutReady, isAnalyticsPaused, setIsAnalyticsPaused, isAnalyticsFilterApplied, } = (0, InspectorContext_1.useInspector)();
|
|
836
|
-
const listRef = (0, react_1.useRef)(null);
|
|
837
|
-
const [isFilterModalOpen, setIsFilterModalOpen] = (0, react_1.useState)(false);
|
|
838
|
-
const keyExtractor = (0, react_1.useCallback)((item, index) => item?.id?.toString() ?? index.toString(), []);
|
|
839
|
-
const renderItem = (0, react_1.useCallback)(({ item, index }) => {
|
|
840
|
-
const prev = filteredAnalyticsEvents[index + 1];
|
|
841
|
-
const next = filteredAnalyticsEvents[index - 1];
|
|
842
|
-
const msSincePrev = prev
|
|
843
|
-
? item.timestamp - prev.timestamp
|
|
844
|
-
: undefined;
|
|
845
|
-
const thisMin = Math.floor(item.timestamp / 60000);
|
|
846
|
-
const nextMin = next
|
|
847
|
-
? Math.floor(next.timestamp / 60000)
|
|
848
|
-
: -1;
|
|
849
|
-
const showTimestamp = index === 0 || thisMin !== nextMin;
|
|
850
|
-
return (<AnalyticsEventCard_1.default event={item} onPress={() => {
|
|
851
|
-
setSelectedEvent(item);
|
|
852
|
-
}} isNew={newEventIds.has(item.id)} searchStr={analyticsSearch} isFirst={index === 0} isLast={index === filteredAnalyticsEvents.length - 1} msSincePrev={msSincePrev} showTimestamp={showTimestamp} computedScreenName={(() => {
|
|
853
|
-
if (!item)
|
|
854
|
-
return '';
|
|
855
|
-
const rawScreenName = item.screenName ||
|
|
856
|
-
item.screenClass ||
|
|
857
|
-
item.pageTitle ||
|
|
858
|
-
item.pageLocation ||
|
|
859
|
-
item.params?.firebase_screen ||
|
|
860
|
-
item.params?.screen_name ||
|
|
861
|
-
item.params?.firebase_screen_class ||
|
|
862
|
-
item.params?.screen_class;
|
|
863
|
-
let screenName = typeof rawScreenName === 'string'
|
|
864
|
-
? rawScreenName
|
|
865
|
-
: (rawScreenName ? JSON.stringify(rawScreenName) : '');
|
|
866
|
-
const routeInfo = logRouteMapRef.current.get(item.id + 1000000);
|
|
867
|
-
if (!screenName) {
|
|
868
|
-
if (routeInfo &&
|
|
869
|
-
routeInfo.path !== 'Navigators') {
|
|
870
|
-
const parts = routeInfo.path.split(' ➔ ');
|
|
871
|
-
screenName = parts[parts.length - 1];
|
|
872
|
-
}
|
|
873
|
-
}
|
|
874
|
-
return screenName;
|
|
875
|
-
})()}/>);
|
|
876
|
-
}, [filteredAnalyticsEvents, analyticsSearch, newEventIds, setSelectedEvent, logRouteMapRef]);
|
|
877
|
-
return (<>
|
|
878
|
-
|
|
879
|
-
{selectedEvent == null && (<react_native_1.View style={[
|
|
880
|
-
styles_1.default.toolbarRow,
|
|
881
|
-
{ marginTop: 12, marginBottom: 8 },
|
|
882
|
-
]}>
|
|
883
|
-
<react_native_1.View style={styles_1.default.searchContainer}>
|
|
884
|
-
<NetworkIcons_1.SearchIcon color={AppColors_1.AppColors.grayTextWeak} size={16}/>
|
|
885
|
-
<react_native_1.TextInput placeholder="Search events..." placeholderTextColor={AppColors_1.AppColors.grayTextWeak} value={analyticsSearch} onChangeText={setAnalyticsSearch} style={styles_1.default.searchInput} autoCorrect={false} autoCapitalize="none"/>
|
|
886
|
-
{analyticsSearch.length > 0 && (<react_native_1.View style={{
|
|
887
|
-
flexDirection: 'row',
|
|
888
|
-
alignItems: 'center',
|
|
889
|
-
gap: 4,
|
|
890
|
-
}}>
|
|
891
|
-
<react_native_1.View style={{
|
|
892
|
-
backgroundColor: `${AppColors_1.AppColors.purple}20`,
|
|
893
|
-
borderRadius: 10,
|
|
894
|
-
paddingHorizontal: 6,
|
|
895
|
-
paddingVertical: 1.5,
|
|
896
|
-
}}>
|
|
897
|
-
<react_native_1.Text style={{
|
|
898
|
-
color: AppColors_1.AppColors.purple,
|
|
899
|
-
fontSize: 9.5,
|
|
900
|
-
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
901
|
-
}}>
|
|
902
|
-
{filteredAnalyticsEvents.length}
|
|
903
|
-
</react_native_1.Text>
|
|
904
|
-
</react_native_1.View>
|
|
905
|
-
<react_native_1.Pressable onPress={() => setAnalyticsSearch('')} hitSlop={10} style={styles_1.default.clearBtn}>
|
|
906
|
-
<NetworkIcons_1.ClearIcon color={AppColors_1.AppColors.grayTextWeak} size={13}/>
|
|
907
|
-
</react_native_1.Pressable>
|
|
908
|
-
</react_native_1.View>)}
|
|
909
|
-
</react_native_1.View>
|
|
910
|
-
<react_native_1.View style={styles_1.default.toolbarRight}>
|
|
911
|
-
<react_native_1.TouchableOpacity style={[
|
|
912
|
-
styles_1.default.toolbarBtn,
|
|
913
|
-
isAnalyticsPaused && {
|
|
914
|
-
borderColor: `${AppColors_1.AppColors.darkOrange}50`,
|
|
915
|
-
backgroundColor: `${AppColors_1.AppColors.darkOrange}18`,
|
|
916
|
-
},
|
|
917
|
-
]} onPress={() => setIsAnalyticsPaused(p => !p)} hitSlop={6}>
|
|
918
|
-
<NetworkIcons_1.HeaderPauseIcon isPaused={isAnalyticsPaused} color={isAnalyticsPaused
|
|
919
|
-
? AppColors_1.AppColors.darkOrange
|
|
920
|
-
: AppColors_1.AppColors.grayTextStrong} size={16}/>
|
|
921
|
-
</react_native_1.TouchableOpacity>
|
|
274
|
+
|
|
275
|
+
{(()=>{const t=!f.categories.has("all")&&f.categories.has("ecommerce");return<TouchableScale_1.default onPress={()=>F("ecommerce")}>
|
|
276
|
+
<react_native_1.View style={[styles_1.default.statusFilterChip,{backgroundColor:t?AppColors_1.AppColors.amber600:AppColors_1.AppColors.amber100,borderColor:t?AppColors_1.AppColors.amber700:AppColors_1.AppColors.amber200,borderRadius:8,paddingHorizontal:10,paddingVertical:6},t&&{shadowColor:AppColors_1.AppColors.amber600,shadowOffset:{width:0,height:1},shadowOpacity:.28,shadowRadius:2.5,elevation:2}]}>
|
|
277
|
+
<react_native_1.View style={{flexDirection:"row",alignItems:"center",gap:6}}>
|
|
278
|
+
<NetworkIcons_1.CartIcon size={13}color={t?AppColors_1.AppColors.white:AppColors_1.AppColors.amber700}/>
|
|
279
|
+
<react_native_1.Text numberOfLines={1}style={[styles_1.default.statusFilterText,{color:t?AppColors_1.AppColors.white:AppColors_1.AppColors.amber800Warm,fontFamily:AppFonts_1.AppFonts.interBold}]}>
|
|
280
|
+
Ecommerce ({V.ecommerce})
|
|
281
|
+
</react_native_1.Text>
|
|
282
|
+
</react_native_1.View>
|
|
283
|
+
</react_native_1.View>
|
|
284
|
+
</TouchableScale_1.default>})()}
|
|
922
285
|
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
{isAnalyticsFilterApplied && (<react_native_1.View style={{
|
|
935
|
-
position: 'absolute',
|
|
936
|
-
top: 2,
|
|
937
|
-
right: 2,
|
|
938
|
-
width: 7,
|
|
939
|
-
height: 7,
|
|
940
|
-
borderRadius: 3.5,
|
|
941
|
-
backgroundColor: AppColors_1.AppColors.darkOrange,
|
|
942
|
-
borderWidth: 1,
|
|
943
|
-
borderColor: AppColors_1.AppColors.white,
|
|
944
|
-
}}/>)}
|
|
945
|
-
</react_native_1.TouchableOpacity>
|
|
286
|
+
|
|
287
|
+
{(()=>{const t=!f.categories.has("all")&&f.categories.has("page_view");return<TouchableScale_1.default onPress={()=>F("page_view")}>
|
|
288
|
+
<react_native_1.View style={[styles_1.default.statusFilterChip,{backgroundColor:t?AppColors_1.AppColors.sky600:AppColors_1.AppColors.sky100,borderColor:t?AppColors_1.AppColors.blue700:AppColors_1.AppColors.sky400,borderRadius:8,paddingHorizontal:10,paddingVertical:6},t&&{shadowColor:AppColors_1.AppColors.sky600,shadowOffset:{width:0,height:1},shadowOpacity:.28,shadowRadius:2.5,elevation:2}]}>
|
|
289
|
+
<react_native_1.View style={{flexDirection:"row",alignItems:"center",gap:6}}>
|
|
290
|
+
<NetworkIcons_1.GlobeIcon size={13}color={t?AppColors_1.AppColors.white:AppColors_1.AppColors.sky600}/>
|
|
291
|
+
<react_native_1.Text numberOfLines={1}style={[styles_1.default.statusFilterText,{color:t?AppColors_1.AppColors.white:AppColors_1.AppColors.sky600,fontFamily:AppFonts_1.AppFonts.interBold}]}>
|
|
292
|
+
Screens ({V.page_view})
|
|
293
|
+
</react_native_1.Text>
|
|
294
|
+
</react_native_1.View>
|
|
295
|
+
</react_native_1.View>
|
|
296
|
+
</TouchableScale_1.default>})()}
|
|
946
297
|
|
|
947
|
-
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
298
|
+
|
|
299
|
+
{(()=>{const t=!f.categories.has("all")&&f.categories.has("system");return<TouchableScale_1.default onPress={()=>F("system")}>
|
|
300
|
+
<react_native_1.View style={[styles_1.default.statusFilterChip,{backgroundColor:t?AppColors_1.AppColors.violet600:AppColors_1.AppColors.purple100,borderColor:t?AppColors_1.AppColors.purpleShade700:AppColors_1.AppColors.purple200,borderRadius:8,paddingHorizontal:10,paddingVertical:6},t&&{shadowColor:AppColors_1.AppColors.violet600,shadowOffset:{width:0,height:1},shadowOpacity:.28,shadowRadius:2.5,elevation:2}]}>
|
|
301
|
+
<react_native_1.View style={{flexDirection:"row",alignItems:"center",gap:6}}>
|
|
302
|
+
<NetworkIcons_1.BoltIcon size={13}color={t?AppColors_1.AppColors.white:AppColors_1.AppColors.purple}/>
|
|
303
|
+
<react_native_1.Text numberOfLines={1}style={[styles_1.default.statusFilterText,{color:t?AppColors_1.AppColors.white:AppColors_1.AppColors.brandPurple,fontFamily:AppFonts_1.AppFonts.interBold}]}>
|
|
304
|
+
System ({V.system})
|
|
305
|
+
</react_native_1.Text>
|
|
306
|
+
</react_native_1.View>
|
|
307
|
+
</react_native_1.View>
|
|
308
|
+
</TouchableScale_1.default>})()}
|
|
309
|
+
|
|
310
|
+
|
|
311
|
+
{(()=>{const t=!f.categories.has("all")&&f.categories.has("custom");return<TouchableScale_1.default onPress={()=>F("custom")}>
|
|
312
|
+
<react_native_1.View style={[styles_1.default.statusFilterChip,{backgroundColor:t?AppColors_1.AppColors.pink600:AppColors_1.AppColors.pink100,borderColor:t?AppColors_1.AppColors.rose700:AppColors_1.AppColors.roseBorder,borderRadius:8,paddingHorizontal:10,paddingVertical:6},t&&{shadowColor:AppColors_1.AppColors.pink600,shadowOffset:{width:0,height:1},shadowOpacity:.28,shadowRadius:2.5,elevation:2}]}>
|
|
313
|
+
<react_native_1.View style={{flexDirection:"row",alignItems:"center",gap:6}}>
|
|
314
|
+
<NetworkIcons_1.SparkleIcon size={13}color={t?AppColors_1.AppColors.white:AppColors_1.AppColors.brandPurple}/>
|
|
315
|
+
<react_native_1.Text numberOfLines={1}style={[styles_1.default.statusFilterText,{color:t?AppColors_1.AppColors.white:AppColors_1.AppColors.pink600,fontFamily:AppFonts_1.AppFonts.interBold}]}>
|
|
316
|
+
Custom ({V.custom})
|
|
317
|
+
</react_native_1.Text>
|
|
318
|
+
</react_native_1.View>
|
|
319
|
+
</react_native_1.View>
|
|
320
|
+
</TouchableScale_1.default>})()}
|
|
321
|
+
</react_native_1.ScrollView>
|
|
322
|
+
</react_native_1.View>}
|
|
958
323
|
|
|
959
324
|
|
|
960
|
-
<AnalyticsFilterModal_1.default visible={
|
|
325
|
+
<AnalyticsFilterModal_1.default visible={A}onClose={()=>T(!1)}/>
|
|
961
326
|
|
|
962
|
-
<react_native_1.View style={{
|
|
963
|
-
{
|
|
964
|
-
<react_native_1.FlatList ref={
|
|
965
|
-
|
|
966
|
-
: 'No analytics events yet'} customSub={analyticsSearch.length > 0
|
|
967
|
-
? `No events matched "${analyticsSearch}"`
|
|
968
|
-
: 'Call setupAnalyticsLogger(analytics()) at app start.'} onClearSearch={() => setAnalyticsSearch('')}/>} ListFooterComponent={filteredAnalyticsEvents.length > 0 ? (<EndOfListFooter_1.default count={filteredAnalyticsEvents.length} label="events"/>) : null} contentContainerStyle={[
|
|
969
|
-
styles_1.default.listContent,
|
|
970
|
-
filteredAnalyticsEvents.length === 0 && {
|
|
971
|
-
flexGrow: 1,
|
|
972
|
-
},
|
|
973
|
-
]} keyboardShouldPersistTaps="handled"/>
|
|
974
|
-
</>) : null}
|
|
327
|
+
<react_native_1.View style={{flex:1}}onLayout={()=>b(!0)}>
|
|
328
|
+
{D?<>
|
|
329
|
+
<react_native_1.FlatList ref={u}data={r}keyExtractor={$}ListHeaderComponent={AnalyticsHeader}renderItem={y}initialNumToRender={12}maxToRenderPerBatch={8}windowSize={5}removeClippedSubviews={react_native_1.Platform.OS==="android"}renderToHardwareTextureAndroid={!0}ListEmptyComponent={<EmptyState_1.default isSearch={s.length>0}searchQuery={s}customTitle={s.length>0?"No matching analytics events":"No analytics events yet"}customSub={s.length>0?`No events matched "${s}"`:"Call setupAnalyticsLogger(analytics()) at app start."}onClearSearch={()=>p("")}/>}ListFooterComponent={r.length>0?<EndOfListFooter_1.default count={r.length}label="events"/>:null}contentContainerStyle={[styles_1.default.listContent,r.length===0&&{flexGrow:1}]}keyboardShouldPersistTaps="handled"/>
|
|
330
|
+
</>:null}
|
|
975
331
|
</react_native_1.View>
|
|
976
|
-
</>);
|
|
977
|
-
});
|
|
978
|
-
exports.default = AnalyticsTab;
|
|
332
|
+
</>});exports.default=AnalyticsTab;
|