react-native-inapp-inspector 1.1.24 → 1.1.26
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/build.gradle +36 -0
- package/android/src/main/AndroidManifest.xml +3 -0
- package/android/src/main/java/com/inappinspector/NetworkInspectorModule.java +114 -0
- package/android/src/main/java/com/inappinspector/NetworkInspectorPackage.java +28 -0
- package/dist/commonjs/components/AnalyticsEventCard.js +94 -88
- package/dist/commonjs/components/ConsoleLogCard.js +49 -25
- package/dist/commonjs/components/ErrorBoundary.d.ts +1 -1
- package/dist/commonjs/components/ErrorBoundary.js +9 -145
- package/dist/commonjs/components/Inspector/AnalyticsFilterModal.d.ts +7 -0
- package/dist/commonjs/components/Inspector/AnalyticsFilterModal.js +1002 -0
- package/dist/commonjs/components/Inspector/AnalyticsTab.js +637 -10
- package/dist/commonjs/components/Inspector/BundleTab.d.ts +1 -1
- package/dist/commonjs/components/Inspector/BundleTab.js +826 -406
- package/dist/commonjs/components/Inspector/CrashDetail.d.ts +3 -0
- package/dist/commonjs/components/Inspector/CrashDetail.js +796 -0
- package/dist/commonjs/components/Inspector/CrashFilterModal.d.ts +20 -0
- package/dist/commonjs/components/Inspector/CrashFilterModal.js +597 -0
- package/dist/commonjs/components/Inspector/CrashTab.d.ts +3 -0
- package/dist/commonjs/components/Inspector/CrashTab.js +727 -0
- package/dist/commonjs/components/Inspector/InspectorContext.js +6 -1
- package/dist/commonjs/components/Inspector/InspectorHeader.js +65 -28
- package/dist/commonjs/components/Inspector/LogDetail.js +227 -114
- package/dist/commonjs/components/Inspector/MainScreen.js +13 -4
- package/dist/commonjs/components/Inspector/NetworkDetail.js +131 -81
- package/dist/commonjs/components/Inspector/PerformanceTab.js +20 -10
- package/dist/commonjs/components/Inspector/SettingsPanel.js +90 -1
- package/dist/commonjs/components/Inspector/TabBar.js +15 -3
- package/dist/commonjs/components/NetworkIcons.d.ts +25 -0
- package/dist/commonjs/components/NetworkIcons.js +188 -1
- package/dist/commonjs/components/SegmentedTabs.js +33 -23
- package/dist/commonjs/components/TreeNode.js +13 -12
- package/dist/commonjs/constants/version.d.ts +1 -1
- package/dist/commonjs/constants/version.js +1 -1
- package/dist/commonjs/customHooks/analyticsLogger.js +70 -44
- package/dist/commonjs/customHooks/bundleAnalyzer.d.ts +5 -1
- package/dist/commonjs/customHooks/bundleAnalyzer.js +497 -126
- package/dist/commonjs/customHooks/consoleLogger.d.ts +1 -0
- package/dist/commonjs/customHooks/consoleLogger.js +153 -51
- package/dist/commonjs/customHooks/crashHandler.d.ts +64 -0
- package/dist/commonjs/customHooks/crashHandler.js +681 -0
- package/dist/commonjs/customHooks/networkLogger.js +74 -49
- package/dist/commonjs/customHooks/performanceTracker.d.ts +8 -0
- package/dist/commonjs/customHooks/performanceTracker.js +44 -3
- package/dist/commonjs/decorators/index.d.ts +49 -0
- package/dist/commonjs/decorators/index.js +142 -0
- package/dist/commonjs/helpers/gaAnalyticsRegistry.d.ts +18 -0
- package/dist/commonjs/helpers/gaAnalyticsRegistry.js +174 -0
- package/dist/commonjs/helpers/index.d.ts +7 -4
- package/dist/commonjs/helpers/index.js +102 -64
- package/dist/commonjs/i18n/locales/en.json +182 -4
- package/dist/commonjs/index.d.ts +6 -0
- package/dist/commonjs/index.js +310 -8
- package/dist/commonjs/styles/index.d.ts +4 -1
- package/dist/commonjs/styles/index.js +22 -19
- package/dist/commonjs/types/enums.d.ts +156 -9
- package/dist/commonjs/types/enums.js +139 -2
- package/dist/commonjs/types/interfaces.d.ts +70 -1
- package/dist/esm/components/AnalyticsEventCard.js +95 -89
- package/dist/esm/components/ConsoleLogCard.js +49 -25
- package/dist/esm/components/ErrorBoundary.d.ts +1 -1
- package/dist/esm/components/ErrorBoundary.js +10 -113
- package/dist/esm/components/Inspector/AnalyticsFilterModal.d.ts +7 -0
- package/dist/esm/components/Inspector/AnalyticsFilterModal.js +964 -0
- package/dist/esm/components/Inspector/AnalyticsTab.js +639 -12
- package/dist/esm/components/Inspector/BundleTab.d.ts +1 -1
- package/dist/esm/components/Inspector/BundleTab.js +827 -407
- package/dist/esm/components/Inspector/CrashDetail.d.ts +3 -0
- package/dist/esm/components/Inspector/CrashDetail.js +758 -0
- package/dist/esm/components/Inspector/CrashFilterModal.d.ts +20 -0
- package/dist/esm/components/Inspector/CrashFilterModal.js +557 -0
- package/dist/esm/components/Inspector/CrashTab.d.ts +3 -0
- package/dist/esm/components/Inspector/CrashTab.js +689 -0
- package/dist/esm/components/Inspector/InspectorContext.js +1 -0
- package/dist/esm/components/Inspector/InspectorHeader.js +66 -29
- package/dist/esm/components/Inspector/LogDetail.js +227 -114
- package/dist/esm/components/Inspector/MainScreen.js +14 -5
- package/dist/esm/components/Inspector/NetworkDetail.js +132 -49
- package/dist/esm/components/Inspector/PerformanceTab.js +20 -10
- package/dist/esm/components/Inspector/SettingsPanel.js +91 -2
- package/dist/esm/components/Inspector/TabBar.js +16 -4
- package/dist/esm/components/NetworkIcons.d.ts +25 -0
- package/dist/esm/components/NetworkIcons.js +161 -0
- package/dist/esm/components/SegmentedTabs.js +33 -23
- package/dist/esm/components/TreeNode.js +13 -12
- package/dist/esm/constants/version.d.ts +1 -1
- package/dist/esm/constants/version.js +1 -1
- package/dist/esm/customHooks/analyticsLogger.js +70 -44
- package/dist/esm/customHooks/bundleAnalyzer.d.ts +5 -1
- package/dist/esm/customHooks/bundleAnalyzer.js +493 -125
- package/dist/esm/customHooks/consoleLogger.d.ts +1 -0
- package/dist/esm/customHooks/consoleLogger.js +151 -50
- package/dist/esm/customHooks/crashHandler.d.ts +64 -0
- package/dist/esm/customHooks/crashHandler.js +659 -0
- package/dist/esm/customHooks/networkLogger.js +74 -49
- package/dist/esm/customHooks/performanceTracker.d.ts +8 -0
- package/dist/esm/customHooks/performanceTracker.js +38 -1
- package/dist/esm/decorators/index.d.ts +49 -0
- package/dist/esm/decorators/index.js +137 -0
- package/dist/esm/helpers/gaAnalyticsRegistry.d.ts +18 -0
- package/dist/esm/helpers/gaAnalyticsRegistry.js +169 -0
- package/dist/esm/helpers/index.d.ts +7 -4
- package/dist/esm/helpers/index.js +100 -63
- package/dist/esm/i18n/locales/en.json +182 -4
- package/dist/esm/index.d.ts +6 -0
- package/dist/esm/index.js +262 -8
- package/dist/esm/styles/index.d.ts +4 -1
- package/dist/esm/styles/index.js +22 -19
- package/dist/esm/types/enums.d.ts +156 -9
- package/dist/esm/types/enums.js +138 -3
- package/dist/esm/types/interfaces.d.ts +70 -1
- package/ios/NetworkInspectorModule.h +6 -0
- package/ios/NetworkInspectorModule.m +125 -0
- package/package.json +5 -2
- package/react-native-inapp-inspector.podspec +18 -0
|
@@ -37,7 +37,8 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
37
37
|
};
|
|
38
38
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
39
|
exports.InfoCircleIcon = exports.UserIcon = exports.LayersIcon = exports.WipeIcon = exports.FolderIcon = exports.SettingsIcon = exports.EyeIcon = exports.JsIcon = exports.CssIcon = exports.HtmlIcon = exports.BrandSquareIcon = exports.BrandCircleIcon = exports.MoonIcon = exports.SunIcon = exports.DebugIcon = exports.InsightsIcon = exports.AnalyticsIcon = exports.WhiteBackNavigation = exports.CloseWhite = exports.DownloadIcon = exports.FilterIcon = exports.ChevronIcon = exports.SortArrowIcon = exports.GlobeIcon = exports.DiffIcon = exports.SignalIcon = exports.ExportIcon = exports.HeaderPauseIcon = exports.TrashIcon = exports.FailIcon = exports.CircleAlertIcon = exports.CircleXIcon = exports.CircleCheckIcon = exports.CheckIcon = exports.TerminalIcon = exports.FetchIcon = exports.CopyIcon = exports.HeadersIcon = exports.ResponseIcon = exports.RequestIcon = exports.SizeIcon = exports.StatusIcon = exports.CalendarIcon = exports.ClockIcon = exports.ClearIcon = exports.SearchIcon = exports.ExpandCollapseIcon = exports.ScreenIcon = exports.MapPinIcon = exports.EmptyRadarIcon = void 0;
|
|
40
|
-
exports.MoneyIcon = exports.CartIcon = exports.TextAaIcon = exports.BrainIcon = exports.AtomIcon = exports.MapIcon = exports.SparkleIcon = exports.LightbulbIcon = exports.DocIcon = exports.FolderOpenIcon = exports.BanIcon = exports.BoltIcon = exports.PerformanceIcon = exports.ReduxIcon = exports.MetadataIcon = exports.StorageIcon = exports.TimelineIcon = exports.LiveStateIcon = exports.BundleIcon = exports.ForwardChevronIcon = exports.PackageIcon = exports.TableIcon = exports.RawIcon = exports.PrettyIcon = exports.SortIcon = exports.MotionIcon = exports.TrendingUpIcon = exports.ErrorCircleIcon = exports.WarningTriangleIcon = void 0;
|
|
40
|
+
exports.DiagnosticsIcon = exports.StackTraceIcon = exports.LayoutIcon = exports.ChipIcon = exports.SkullIcon = exports.ShieldAlertIcon = exports.CrashIcon = exports.UserCheckIcon = exports.TargetGoalIcon = exports.RepeatIcon = exports.PinIcon = exports.HourglassIcon = exports.FlameIcon = exports.CodeBracketsIcon = exports.AndroidIcon = exports.AppleIcon = exports.LinkChainIcon = exports.GitHubIcon = exports.PackageBoxIcon = exports.ExternalLinkIcon = exports.MoneyIcon = exports.CartIcon = exports.TextAaIcon = exports.BrainIcon = exports.AtomIcon = exports.MapIcon = exports.SparkleIcon = exports.LightbulbIcon = exports.DocIcon = exports.FolderOpenIcon = exports.BanIcon = exports.BoltIcon = exports.PerformanceIcon = exports.ReduxIcon = exports.MetadataIcon = exports.StorageIcon = exports.RefreshCcwIcon = exports.TimelineIcon = exports.LiveStateIcon = exports.BundleIcon = exports.ForwardChevronIcon = exports.PackageIcon = exports.TableIcon = exports.RawIcon = exports.PrettyIcon = exports.SortIcon = exports.MotionIcon = exports.TrendingUpIcon = exports.ErrorCircleIcon = exports.WarningTriangleIcon = void 0;
|
|
41
|
+
exports.AllFramesIcon = exports.AppFramesIcon = exports.RawJsonIcon = exports.TrailIcon = void 0;
|
|
41
42
|
const react_1 = __importDefault(require("react"));
|
|
42
43
|
const react_native_svg_1 = __importStar(require("react-native-svg"));
|
|
43
44
|
// Stylesheet
|
|
@@ -475,6 +476,12 @@ const TimelineIcon = ({ color = AppColors_1.AppColors.purple, size = 14, }) => {
|
|
|
475
476
|
</react_native_svg_1.default>);
|
|
476
477
|
};
|
|
477
478
|
exports.TimelineIcon = TimelineIcon;
|
|
479
|
+
const RefreshCcwIcon = ({ color = AppColors_1.AppColors.grayTextWeak, size = 14, }) => {
|
|
480
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
481
|
+
<react_native_svg_1.Path d="M3 12a9 9 0 0 1 15-6.7L21 8M21 3v5h-5M21 12a9 9 0 0 1-15 6.7L3 16M3 21v-5h5" stroke={color} strokeWidth="2" strokeLinecap="round" strokeLinejoin="round"/>
|
|
482
|
+
</react_native_svg_1.default>);
|
|
483
|
+
};
|
|
484
|
+
exports.RefreshCcwIcon = RefreshCcwIcon;
|
|
478
485
|
const StorageIcon = ({ color = AppColors_1.AppColors.purple, size = 14, }) => {
|
|
479
486
|
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
480
487
|
<react_native_svg_1.Ellipse cx="12" cy="6" rx="8" ry="2.8" stroke={color} strokeWidth="1.8"/>
|
|
@@ -599,3 +606,183 @@ const MoneyIcon = ({ color = AppColors_1.AppColors.emerald500, size = 14 }) => {
|
|
|
599
606
|
</react_native_svg_1.default>);
|
|
600
607
|
};
|
|
601
608
|
exports.MoneyIcon = MoneyIcon;
|
|
609
|
+
const ExternalLinkIcon = ({ color = AppColors_1.AppColors.grayTextWeak, size = 14, }) => {
|
|
610
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
611
|
+
<react_native_svg_1.Path d="M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6" stroke={color} strokeWidth="2" strokeLinecap="round" strokeLinejoin="round"/>
|
|
612
|
+
<react_native_svg_1.Path d="M15 3h6v6M10 14L21 3" stroke={color} strokeWidth="2" strokeLinecap="round" strokeLinejoin="round"/>
|
|
613
|
+
</react_native_svg_1.default>);
|
|
614
|
+
};
|
|
615
|
+
exports.ExternalLinkIcon = ExternalLinkIcon;
|
|
616
|
+
const PackageBoxIcon = ({ color = AppColors_1.AppColors.grayTextWeak, size = 14, }) => {
|
|
617
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
618
|
+
<react_native_svg_1.Path d="M21 16V8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16z" stroke={color} strokeWidth="1.8" strokeLinecap="round" strokeLinejoin="round"/>
|
|
619
|
+
<react_native_svg_1.Path d="M3.27 6.96L12 12.01l8.73-5.05M12 22.08V12" stroke={color} strokeWidth="1.8" strokeLinecap="round" strokeLinejoin="round"/>
|
|
620
|
+
</react_native_svg_1.default>);
|
|
621
|
+
};
|
|
622
|
+
exports.PackageBoxIcon = PackageBoxIcon;
|
|
623
|
+
const GitHubIcon = ({ color = AppColors_1.AppColors.grayTextWeak, size = 14, }) => {
|
|
624
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
625
|
+
<react_native_svg_1.Path d="M9 19c-5 1.5-5-2.5-7-3m14 6v-3.87a3.37 3.37 0 0 0-.94-2.61c3.14-.35 6.44-1.54 6.44-7A5.44 5.44 0 0 0 20 4.77 5.07 5.07 0 0 0 19.91 1S18.73.65 16 2.48a13.38 13.38 0 0 0-7 0C6.27.65 5.09 1 5.09 1A5.07 5.07 0 0 0 5 4.77a5.44 5.44 0 0 0-1.5 3.78c0 5.42 3.3 6.61 6.44 7A3.37 3.37 0 0 0 9 18.13V22" stroke={color} strokeWidth="1.8" strokeLinecap="round" strokeLinejoin="round"/>
|
|
626
|
+
</react_native_svg_1.default>);
|
|
627
|
+
};
|
|
628
|
+
exports.GitHubIcon = GitHubIcon;
|
|
629
|
+
const LinkChainIcon = ({ color = AppColors_1.AppColors.grayTextWeak, size = 14, }) => {
|
|
630
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
631
|
+
<react_native_svg_1.Path d="M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71" stroke={color} strokeWidth="2" strokeLinecap="round" strokeLinejoin="round"/>
|
|
632
|
+
<react_native_svg_1.Path d="M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71" stroke={color} strokeWidth="2" strokeLinecap="round" strokeLinejoin="round"/>
|
|
633
|
+
</react_native_svg_1.default>);
|
|
634
|
+
};
|
|
635
|
+
exports.LinkChainIcon = LinkChainIcon;
|
|
636
|
+
const AppleIcon = ({ color = AppColors_1.AppColors.white, size = 12, }) => {
|
|
637
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill={color}>
|
|
638
|
+
<react_native_svg_1.Path d="M18.71 19.5c-.83 1.24-1.71 2.45-3.05 2.47-1.34.03-1.77-.79-3.29-.79-1.53 0-2 .77-3.27.82-1.31.05-2.3-1.32-3.14-2.53C4.25 17 2.94 12.45 4.7 9.39c.87-1.52 2.43-2.48 4.12-2.51 1.28-.02 2.5.87 3.29.87.78 0 2.26-1.07 3.81-.91.65.03 2.47.26 3.64 1.98-.09.06-2.17 1.28-2.15 3.81.03 3.02 2.65 4.03 2.68 4.04-.03.07-.42 1.44-1.38 2.83M15.97 6.37c.61-.75 1.04-1.8 0.92-2.87-.9.04-1.99.6-2.63 1.35-.56.65-1.06 1.71-.93 2.74 1.01.08 2.03-.47 2.64-1.22z"/>
|
|
639
|
+
</react_native_svg_1.default>);
|
|
640
|
+
};
|
|
641
|
+
exports.AppleIcon = AppleIcon;
|
|
642
|
+
const AndroidIcon = ({ color = AppColors_1.AppColors.white, size = 12, }) => {
|
|
643
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill={color}>
|
|
644
|
+
<react_native_svg_1.Path d="M6 18c0 .55.45 1 1 1h1v3.5c0 .83.67 1.5 1.5 1.5s1.5-.67 1.5-1.5V19h2v3.5c0 .83.67 1.5 1.5 1.5s1.5-.67 1.5-1.5V19h1c.55 0 1-.45 1-1V8H6v10zM3.5 8C2.67 8 2 8.67 2 9.5v6c0 .83.67 1.5 1.5 1.5S5 16.33 5 15.5v-6C5 8.67 4.33 8 3.5 8zm17 0c-.83 0-1.5.67-1.5 1.5v6c0 .83.67 1.5 1.5 1.5s1.5-.67 1.5-1.5v-6c0-.83-.67-1.5-1.5-1.5zm-4.97-4.84l1.3-1.3c.2-.2.2-.51 0-.71-.2-.2-.51-.2-.71 0l-1.48 1.48C13.85 2.23 12.95 2 12 2c-.96 0-1.86.23-2.66.63L7.85 1.15c-.2-.2-.51-.2-.71 0-.2.2-.2.51 0 .71l1.31 1.31C6.73 4.26 5.54 6 5.16 8h13.68c-.38-2-1.57-3.74-3.31-4.84zM9 6c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm6 0c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1z"/>
|
|
645
|
+
</react_native_svg_1.default>);
|
|
646
|
+
};
|
|
647
|
+
exports.AndroidIcon = AndroidIcon;
|
|
648
|
+
const CodeBracketsIcon = ({ color = AppColors_1.AppColors.grayTextWeak, size = 14, }) => {
|
|
649
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
650
|
+
<react_native_svg_1.Path d="M16 18l6-6-6-6M8 6l-6 6 6 6" stroke={color} strokeWidth="2" strokeLinecap="round" strokeLinejoin="round"/>
|
|
651
|
+
</react_native_svg_1.default>);
|
|
652
|
+
};
|
|
653
|
+
exports.CodeBracketsIcon = CodeBracketsIcon;
|
|
654
|
+
const FlameIcon = ({ color = AppColors_1.AppColors.darkOrange, size = 14, }) => {
|
|
655
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
656
|
+
<react_native_svg_1.Path d="M8.5 14.5A2.5 2.5 0 0 0 11 12c0-1.38-.5-2-1-3-1.072-2.143-.224-4.054 2-6 .5 2.5 2 4.9 4 6.5 2 1.6 3 3.5 3 5.5a7 7 0 1 1-14 0c0-1.153.433-2.294 1-3a2.5 2.5 0 0 0 2.5 3z" stroke={color} strokeWidth="1.8" strokeLinecap="round" strokeLinejoin="round"/>
|
|
657
|
+
</react_native_svg_1.default>);
|
|
658
|
+
};
|
|
659
|
+
exports.FlameIcon = FlameIcon;
|
|
660
|
+
const HourglassIcon = ({ color = AppColors_1.AppColors.grayTextWeak, size = 14, }) => {
|
|
661
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
662
|
+
<react_native_svg_1.Path d="M5 22h14M5 2h14M17 22v-4.172a2 2 0 0 0-.586-1.414L12 12l-4.414 4.414A2 2 0 0 0 7 17.828V22M7 2v4.172a2 2 0 0 0 .586 1.414L12 12l4.414-4.414A2 2 0 0 0 17 6.172V2" stroke={color} strokeWidth="1.8" strokeLinecap="round" strokeLinejoin="round"/>
|
|
663
|
+
</react_native_svg_1.default>);
|
|
664
|
+
};
|
|
665
|
+
exports.HourglassIcon = HourglassIcon;
|
|
666
|
+
const PinIcon = ({ color = AppColors_1.AppColors.grayTextWeak, size = 14, }) => {
|
|
667
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
668
|
+
<react_native_svg_1.Path d="M12 21s-6-5.333-6-10a6 6 0 0 1 12 0c0 4.667-6 10-6 10z" stroke={color} strokeWidth="1.8" strokeLinecap="round" strokeLinejoin="round"/>
|
|
669
|
+
<react_native_svg_1.Circle cx="12" cy="11" r="2" fill={color}/>
|
|
670
|
+
</react_native_svg_1.default>);
|
|
671
|
+
};
|
|
672
|
+
exports.PinIcon = PinIcon;
|
|
673
|
+
const RepeatIcon = ({ color = AppColors_1.AppColors.grayTextWeak, size = 14, }) => {
|
|
674
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
675
|
+
<react_native_svg_1.Path d="M17 2l4 4-4 4M3 11v-1a4 4 0 0 1 4-4h14M7 22l-4-4 4-4M21 13v1a4 4 0 0 1-4 4H3" stroke={color} strokeWidth="1.8" strokeLinecap="round" strokeLinejoin="round"/>
|
|
676
|
+
</react_native_svg_1.default>);
|
|
677
|
+
};
|
|
678
|
+
exports.RepeatIcon = RepeatIcon;
|
|
679
|
+
const TargetGoalIcon = ({ color = AppColors_1.AppColors.brandPurple, size = 14, }) => {
|
|
680
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
681
|
+
<react_native_svg_1.Circle cx="12" cy="12" r="10" stroke={color} strokeWidth="1.8"/>
|
|
682
|
+
<react_native_svg_1.Circle cx="12" cy="12" r="6" stroke={color} strokeWidth="1.8"/>
|
|
683
|
+
<react_native_svg_1.Circle cx="12" cy="12" r="2" fill={color}/>
|
|
684
|
+
</react_native_svg_1.default>);
|
|
685
|
+
};
|
|
686
|
+
exports.TargetGoalIcon = TargetGoalIcon;
|
|
687
|
+
const UserCheckIcon = ({ color = AppColors_1.AppColors.grayTextWeak, size = 14, }) => {
|
|
688
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
689
|
+
<react_native_svg_1.Path d="M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2" stroke={color} strokeWidth="1.8" strokeLinecap="round" strokeLinejoin="round"/>
|
|
690
|
+
<react_native_svg_1.Circle cx="9" cy="7" r="4" stroke={color} strokeWidth="1.8"/>
|
|
691
|
+
<react_native_svg_1.Path d="M16 11l2 2 4-4" stroke={color} strokeWidth="1.8" strokeLinecap="round" strokeLinejoin="round"/>
|
|
692
|
+
</react_native_svg_1.default>);
|
|
693
|
+
};
|
|
694
|
+
exports.UserCheckIcon = UserCheckIcon;
|
|
695
|
+
const CrashIcon = ({ color = AppColors_1.AppColors.errorColor, size = 14, }) => {
|
|
696
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
697
|
+
{/* Bug / Crash Hybrid Icon */}
|
|
698
|
+
<react_native_svg_1.Path d="M12 2v3M4.93 4.93l2.12 2.12M19.07 4.93l-2.12 2.12M9 10h6M8 14h8M9 18h6" stroke={color} strokeWidth="1.8" strokeLinecap="round"/>
|
|
699
|
+
<react_native_svg_1.Path d="M12 8a6 6 0 0 1 6 6v3a6 6 0 0 1-12 0v-3a6 6 0 0 1 6-6z" stroke={color} strokeWidth="1.8" strokeLinecap="round" strokeLinejoin="round"/>
|
|
700
|
+
<react_native_svg_1.Path d="M3 13h3M18 13h3M4 19l2.5-1.5M20 19l-2.5-1.5M4 9l2.5 1.5M20 9l-2.5 1.5" stroke={color} strokeWidth="1.8" strokeLinecap="round"/>
|
|
701
|
+
</react_native_svg_1.default>);
|
|
702
|
+
};
|
|
703
|
+
exports.CrashIcon = CrashIcon;
|
|
704
|
+
const ShieldAlertIcon = ({ color = AppColors_1.AppColors.errorColor, size = 14, }) => {
|
|
705
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
706
|
+
<react_native_svg_1.Path d="M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10z" stroke={color} strokeWidth="1.8" strokeLinecap="round" strokeLinejoin="round"/>
|
|
707
|
+
<react_native_svg_1.Line x1="12" y1="8" x2="12" y2="12" stroke={color} strokeWidth="2" strokeLinecap="round"/>
|
|
708
|
+
<react_native_svg_1.Circle cx="12" cy="16" r="1" fill={color}/>
|
|
709
|
+
</react_native_svg_1.default>);
|
|
710
|
+
};
|
|
711
|
+
exports.ShieldAlertIcon = ShieldAlertIcon;
|
|
712
|
+
const SkullIcon = ({ color = AppColors_1.AppColors.errorColor, size = 14, }) => {
|
|
713
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
714
|
+
<react_native_svg_1.Circle cx="12" cy="12" r="9" stroke={color} strokeWidth="1.8"/>
|
|
715
|
+
<react_native_svg_1.Circle cx="9" cy="11" r="1.6" fill={color}/>
|
|
716
|
+
<react_native_svg_1.Circle cx="15" cy="11" r="1.6" fill={color}/>
|
|
717
|
+
<react_native_svg_1.Path d="M8 16c1.2 1 3.2 1.2 4 1.2.8 0 2.8-.2 4-1.2" stroke={color} strokeWidth="1.8" strokeLinecap="round"/>
|
|
718
|
+
<react_native_svg_1.Line x1="12" y1="16" x2="12" y2="18" stroke={color} strokeWidth="1.8" strokeLinecap="round"/>
|
|
719
|
+
</react_native_svg_1.default>);
|
|
720
|
+
};
|
|
721
|
+
exports.SkullIcon = SkullIcon;
|
|
722
|
+
const ChipIcon = ({ color = AppColors_1.AppColors.grayTextWeak, size = 14, }) => {
|
|
723
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
724
|
+
<react_native_svg_1.Rect x="7" y="7" width="10" height="10" rx="2" stroke={color} strokeWidth="1.8"/>
|
|
725
|
+
<react_native_svg_1.Rect x="10" y="10" width="4" height="4" fill={color}/>
|
|
726
|
+
<react_native_svg_1.Line x1="9" y1="3" x2="9" y2="7" stroke={color} strokeWidth="1.6" strokeLinecap="round"/>
|
|
727
|
+
<react_native_svg_1.Line x1="15" y1="3" x2="15" y2="7" stroke={color} strokeWidth="1.6" strokeLinecap="round"/>
|
|
728
|
+
<react_native_svg_1.Line x1="9" y1="17" x2="9" y2="21" stroke={color} strokeWidth="1.6" strokeLinecap="round"/>
|
|
729
|
+
<react_native_svg_1.Line x1="15" y1="17" x2="15" y2="21" stroke={color} strokeWidth="1.6" strokeLinecap="round"/>
|
|
730
|
+
<react_native_svg_1.Line x1="3" y1="9" x2="7" y2="9" stroke={color} strokeWidth="1.6" strokeLinecap="round"/>
|
|
731
|
+
<react_native_svg_1.Line x1="3" y1="15" x2="7" y2="15" stroke={color} strokeWidth="1.6" strokeLinecap="round"/>
|
|
732
|
+
<react_native_svg_1.Line x1="17" y1="9" x2="21" y2="9" stroke={color} strokeWidth="1.6" strokeLinecap="round"/>
|
|
733
|
+
<react_native_svg_1.Line x1="17" y1="15" x2="21" y2="15" stroke={color} strokeWidth="1.6" strokeLinecap="round"/>
|
|
734
|
+
</react_native_svg_1.default>);
|
|
735
|
+
};
|
|
736
|
+
exports.ChipIcon = ChipIcon;
|
|
737
|
+
const LayoutIcon = ({ color = AppColors_1.AppColors.grayTextWeak, size = 14, }) => {
|
|
738
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
739
|
+
<react_native_svg_1.Rect x="3" y="3" width="18" height="18" rx="2" stroke={color} strokeWidth="1.8"/>
|
|
740
|
+
<react_native_svg_1.Line x1="3" y1="9" x2="21" y2="9" stroke={color} strokeWidth="1.8"/>
|
|
741
|
+
<react_native_svg_1.Line x1="9" y1="9" x2="9" y2="21" stroke={color} strokeWidth="1.8"/>
|
|
742
|
+
<react_native_svg_1.Rect x="12" y="12" width="6" height="6" fill={color}/>
|
|
743
|
+
</react_native_svg_1.default>);
|
|
744
|
+
};
|
|
745
|
+
exports.LayoutIcon = LayoutIcon;
|
|
746
|
+
const StackTraceIcon = ({ color = AppColors_1.AppColors.grayTextWeak, size = 14, }) => {
|
|
747
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
748
|
+
<react_native_svg_1.Path d="M4 6h16M4 10h11M4 14h16M4 18h9" stroke={color} strokeWidth="2" strokeLinecap="round"/>
|
|
749
|
+
<react_native_svg_1.Path d="M7.5 12.5 4 14l3.5 1.5" stroke={color} strokeWidth="1.4" strokeLinecap="round" strokeLinejoin="round"/>
|
|
750
|
+
</react_native_svg_1.default>);
|
|
751
|
+
};
|
|
752
|
+
exports.StackTraceIcon = StackTraceIcon;
|
|
753
|
+
const DiagnosticsIcon = ({ color = AppColors_1.AppColors.grayTextWeak, size = 14, }) => {
|
|
754
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
755
|
+
<react_native_svg_1.Path d="M3 12h3l2-5 3 9 2-6 1.5 2H21" stroke={color} strokeWidth="2" strokeLinecap="round" strokeLinejoin="round"/>
|
|
756
|
+
<react_native_svg_1.Line x1="4" y1="19" x2="20" y2="19" stroke={color} strokeWidth="1.6" strokeLinecap="round"/>
|
|
757
|
+
</react_native_svg_1.default>);
|
|
758
|
+
};
|
|
759
|
+
exports.DiagnosticsIcon = DiagnosticsIcon;
|
|
760
|
+
const TrailIcon = ({ color = AppColors_1.AppColors.grayTextWeak, size = 14, }) => {
|
|
761
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
762
|
+
<react_native_svg_1.Circle cx="5" cy="18" r="2" fill={color}/>
|
|
763
|
+
<react_native_svg_1.Circle cx="12" cy="12" r="2" fill={color}/>
|
|
764
|
+
<react_native_svg_1.Circle cx="19" cy="6" r="2" fill={color}/>
|
|
765
|
+
<react_native_svg_1.Path d="M6.5 16.5 10.5 13.5M13.5 10.5 17.5 7.5" stroke={color} strokeWidth="1.6" strokeLinecap="round"/>
|
|
766
|
+
</react_native_svg_1.default>);
|
|
767
|
+
};
|
|
768
|
+
exports.TrailIcon = TrailIcon;
|
|
769
|
+
const RawJsonIcon = ({ color = AppColors_1.AppColors.grayTextWeak, size = 14, }) => {
|
|
770
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
771
|
+
<react_native_svg_1.Path d="M8 3c-2 1-3 2.5-3 5 0 2-1 3.5-2 4 1 .5 2 2 2 4 0 2.5 1 4 3 5M16 3c2 1 3 2.5 3 5 0 2 1 3.5 2 4-1 .5-2 2-2 4 0 2.5-1 4-3 5" stroke={color} strokeWidth="1.8" strokeLinecap="round" strokeLinejoin="round"/>
|
|
772
|
+
</react_native_svg_1.default>);
|
|
773
|
+
};
|
|
774
|
+
exports.RawJsonIcon = RawJsonIcon;
|
|
775
|
+
const AppFramesIcon = ({ color = AppColors_1.AppColors.grayTextWeak, size = 14, }) => {
|
|
776
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
777
|
+
<react_native_svg_1.Path d="M4 6h16M4 10h11M4 14h16M4 18h9" stroke={color} strokeWidth="2" strokeLinecap="round"/>
|
|
778
|
+
<react_native_svg_1.Path d="M18 12.5l2 2 3-3.5" stroke="#059669" strokeWidth="1.8" strokeLinecap="round" strokeLinejoin="round"/>
|
|
779
|
+
</react_native_svg_1.default>);
|
|
780
|
+
};
|
|
781
|
+
exports.AppFramesIcon = AppFramesIcon;
|
|
782
|
+
const AllFramesIcon = ({ color = AppColors_1.AppColors.grayTextWeak, size = 14, }) => {
|
|
783
|
+
return (<react_native_svg_1.default width={size} height={size} viewBox="0 0 24 24" fill="none">
|
|
784
|
+
<react_native_svg_1.Path d="M4 4h16M4 8h16M4 12h16M4 16h16M4 20h10" stroke={color} strokeWidth="1.8" strokeLinecap="round"/>
|
|
785
|
+
<react_native_svg_1.Rect x="16" y="16" width="4" height="4" rx="1" fill={color}/>
|
|
786
|
+
</react_native_svg_1.default>);
|
|
787
|
+
};
|
|
788
|
+
exports.AllFramesIcon = AllFramesIcon;
|
|
@@ -10,39 +10,49 @@ const AppFonts_1 = require("../styles/AppFonts");
|
|
|
10
10
|
const SegmentedTabs = react_1.default.memo(({ tabs, activeKey, onChange, style }) => (<react_native_1.View style={[
|
|
11
11
|
{
|
|
12
12
|
flexDirection: 'row',
|
|
13
|
-
borderRadius:
|
|
14
|
-
|
|
13
|
+
borderRadius: 10,
|
|
14
|
+
backgroundColor: `${AppColors_1.AppColors.slate200}80`,
|
|
15
|
+
padding: 3,
|
|
15
16
|
borderWidth: 1,
|
|
16
17
|
borderColor: AppColors_1.AppColors.dividerColor,
|
|
17
|
-
|
|
18
|
+
gap: 3,
|
|
18
19
|
},
|
|
19
20
|
style,
|
|
20
21
|
]}>
|
|
21
|
-
{tabs.map((tab
|
|
22
|
+
{tabs.map((tab) => {
|
|
22
23
|
const isActive = activeKey === tab.key;
|
|
23
|
-
return (<react_native_1.Pressable key={tab.key} onPress={() => onChange(tab.key)} style={{
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
:
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
24
|
+
return (<react_native_1.Pressable key={tab.key} onPress={() => onChange(tab.key)} style={({ pressed }) => [
|
|
25
|
+
{
|
|
26
|
+
flex: 1,
|
|
27
|
+
paddingVertical: 7,
|
|
28
|
+
paddingHorizontal: 6,
|
|
29
|
+
borderRadius: 7,
|
|
30
|
+
backgroundColor: isActive
|
|
31
|
+
? AppColors_1.AppColors.brandPurple
|
|
32
|
+
: 'transparent',
|
|
33
|
+
alignItems: 'center',
|
|
34
|
+
justifyContent: 'center',
|
|
35
|
+
gap: 4.5,
|
|
36
|
+
flexDirection: 'row',
|
|
37
|
+
opacity: pressed ? 0.8 : 1,
|
|
38
|
+
},
|
|
39
|
+
isActive && {
|
|
40
|
+
shadowColor: AppColors_1.AppColors.brandPurple,
|
|
41
|
+
shadowOffset: { width: 0, height: 1 },
|
|
42
|
+
shadowOpacity: 0.25,
|
|
43
|
+
shadowRadius: 3,
|
|
44
|
+
elevation: 2,
|
|
45
|
+
},
|
|
46
|
+
]}>
|
|
37
47
|
{tab.icon ? tab.icon(isActive) : null}
|
|
38
|
-
<react_native_1.Text style={{
|
|
48
|
+
<react_native_1.Text numberOfLines={1} ellipsizeMode="tail" style={{
|
|
49
|
+
flexShrink: 1,
|
|
39
50
|
fontFamily: AppFonts_1.AppFonts.interBold,
|
|
40
|
-
fontSize: 10,
|
|
51
|
+
fontSize: 10.5,
|
|
41
52
|
color: isActive
|
|
42
53
|
? AppColors_1.AppColors.white
|
|
43
|
-
: AppColors_1.AppColors.
|
|
44
|
-
|
|
45
|
-
letterSpacing: 0.3,
|
|
54
|
+
: AppColors_1.AppColors.grayText,
|
|
55
|
+
letterSpacing: 0.2,
|
|
46
56
|
}}>
|
|
47
57
|
{tab.label}
|
|
48
58
|
</react_native_1.Text>
|
|
@@ -50,6 +50,19 @@ const TreeNode = react_1.default.memo(function TreeNode({ data, name, level = 0,
|
|
|
50
50
|
const open = localOpen;
|
|
51
51
|
const isObject = typeof data === 'object' && data !== null;
|
|
52
52
|
const isArray = Array.isArray(data);
|
|
53
|
+
// Declare all hooks at the top unconditionally (prevents "Rendered fewer hooks than expected" error)
|
|
54
|
+
const treeChevronAnim = (0, react_1.useRef)(new react_native_1.Animated.Value(open ? 1 : 0)).current;
|
|
55
|
+
(0, react_1.useEffect)(() => {
|
|
56
|
+
react_native_1.Animated.timing(treeChevronAnim, {
|
|
57
|
+
toValue: open ? 1 : 0,
|
|
58
|
+
duration: 160,
|
|
59
|
+
useNativeDriver: true,
|
|
60
|
+
}).start();
|
|
61
|
+
}, [open]);
|
|
62
|
+
const treeChevronRotate = treeChevronAnim.interpolate({
|
|
63
|
+
inputRange: [0, 1],
|
|
64
|
+
outputRange: ['0deg', '180deg'],
|
|
65
|
+
});
|
|
53
66
|
function renderHighlighted(text) {
|
|
54
67
|
if (text === 'null' || text === 'undefined') {
|
|
55
68
|
return [
|
|
@@ -106,18 +119,6 @@ const TreeNode = react_1.default.memo(function TreeNode({ data, name, level = 0,
|
|
|
106
119
|
? data.map((v, i) => [i, v])
|
|
107
120
|
: Object.entries(data);
|
|
108
121
|
const countLabel = isArray ? `[${entries.length}]` : `{${entries.length}}`;
|
|
109
|
-
const treeChevronAnim = (0, react_1.useRef)(new react_native_1.Animated.Value(open ? 1 : 0)).current;
|
|
110
|
-
(0, react_1.useEffect)(() => {
|
|
111
|
-
react_native_1.Animated.timing(treeChevronAnim, {
|
|
112
|
-
toValue: open ? 1 : 0,
|
|
113
|
-
duration: 160,
|
|
114
|
-
useNativeDriver: true,
|
|
115
|
-
}).start();
|
|
116
|
-
}, [open]);
|
|
117
|
-
const treeChevronRotate = treeChevronAnim.interpolate({
|
|
118
|
-
inputRange: [0, 1],
|
|
119
|
-
outputRange: ['0deg', '180deg'],
|
|
120
|
-
});
|
|
121
122
|
return (<react_native_1.View style={indentStyle}>
|
|
122
123
|
<react_native_1.Pressable style={styles_1.default.treeRow} onPress={() => setLocalOpen(v => !v)} hitSlop={{ top: 10, bottom: 10, left: 10, right: 10 }}>
|
|
123
124
|
<react_native_1.Animated.View style={{ transform: [{ rotate: treeChevronRotate }], marginRight: 6 }}>
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const LIB_VERSION = "1.1.
|
|
1
|
+
export declare const LIB_VERSION = "1.1.26";
|
|
@@ -3,4 +3,4 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.LIB_VERSION = void 0;
|
|
4
4
|
// AUTO-GENERATED FILE — do not edit by hand.
|
|
5
5
|
// Regenerated from package.json on every build by scripts/gen-version.js.
|
|
6
|
-
exports.LIB_VERSION = '1.1.
|
|
6
|
+
exports.LIB_VERSION = '1.1.26';
|
|
@@ -109,70 +109,90 @@ const setupAnalyticsLogger = (analyticsInstance) => {
|
|
|
109
109
|
// ── logEvent ──────────────────────────────────────────────────────────────
|
|
110
110
|
const originalLogEvent = analyticsInstance.logEvent.bind(analyticsInstance);
|
|
111
111
|
analyticsInstance.logEvent = async (name, params) => {
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
112
|
+
try {
|
|
113
|
+
addEvent({
|
|
114
|
+
id: counter++,
|
|
115
|
+
name,
|
|
116
|
+
params: params ?? {},
|
|
117
|
+
userProperties: { ...currentUserProperties },
|
|
118
|
+
timestamp: Date.now(),
|
|
119
|
+
source: 'firebase',
|
|
120
|
+
userId: currentUserId ?? '',
|
|
121
|
+
screenName: '',
|
|
122
|
+
screenClass: '',
|
|
123
|
+
});
|
|
124
|
+
}
|
|
125
|
+
catch { }
|
|
123
126
|
return originalLogEvent(name, params);
|
|
124
127
|
};
|
|
125
128
|
// ── logScreenView ─────────────────────────────────────────────────────────
|
|
126
129
|
const originalLogScreenView = analyticsInstance.logScreenView.bind(analyticsInstance);
|
|
127
130
|
analyticsInstance.logScreenView = async (params) => {
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
131
|
+
try {
|
|
132
|
+
addEvent({
|
|
133
|
+
id: counter++,
|
|
134
|
+
name: 'screen_view',
|
|
135
|
+
params: params ?? {},
|
|
136
|
+
userProperties: { ...currentUserProperties },
|
|
137
|
+
timestamp: Date.now(),
|
|
138
|
+
source: 'firebase',
|
|
139
|
+
screenName: params?.screen_name ?? '',
|
|
140
|
+
screenClass: params?.screen_class ?? '',
|
|
141
|
+
userId: currentUserId ?? '',
|
|
142
|
+
});
|
|
143
|
+
}
|
|
144
|
+
catch { }
|
|
139
145
|
return originalLogScreenView(params);
|
|
140
146
|
};
|
|
141
147
|
// ── setUserProperty ───────────────────────────────────────────────────────
|
|
142
148
|
const originalSetUserProperty = analyticsInstance.setUserProperty.bind(analyticsInstance);
|
|
143
149
|
analyticsInstance.setUserProperty = async (name, value) => {
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
150
|
+
try {
|
|
151
|
+
if (value === null) {
|
|
152
|
+
delete currentUserProperties[name];
|
|
153
|
+
}
|
|
154
|
+
else {
|
|
155
|
+
currentUserProperties[name] = value;
|
|
156
|
+
}
|
|
149
157
|
}
|
|
158
|
+
catch { }
|
|
150
159
|
return originalSetUserProperty(name, value);
|
|
151
160
|
};
|
|
152
161
|
// ── setUserProperties ─────────────────────────────────────────────────────
|
|
153
162
|
const originalSetUserProperties = analyticsInstance.setUserProperties.bind(analyticsInstance);
|
|
154
163
|
analyticsInstance.setUserProperties = async (properties) => {
|
|
155
|
-
|
|
156
|
-
if (
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
164
|
+
try {
|
|
165
|
+
if (properties && typeof properties === 'object') {
|
|
166
|
+
Object.entries(properties).forEach(([k, v]) => {
|
|
167
|
+
if (v === null)
|
|
168
|
+
delete currentUserProperties[k];
|
|
169
|
+
else
|
|
170
|
+
currentUserProperties[k] = v;
|
|
171
|
+
});
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
catch { }
|
|
161
175
|
return originalSetUserProperties(properties);
|
|
162
176
|
};
|
|
163
177
|
// ── setUserId ─────────────────────────────────────────────────────────────
|
|
164
178
|
const originalSetUserId = analyticsInstance.setUserId.bind(analyticsInstance);
|
|
165
179
|
analyticsInstance.setUserId = async (id) => {
|
|
166
|
-
|
|
167
|
-
|
|
180
|
+
try {
|
|
181
|
+
currentUserId = id ?? undefined;
|
|
182
|
+
notify();
|
|
183
|
+
}
|
|
184
|
+
catch { }
|
|
168
185
|
return originalSetUserId(id);
|
|
169
186
|
};
|
|
170
187
|
// ── setDefaultEventParameters ──────────────────────────────────────────────
|
|
171
188
|
if (typeof analyticsInstance.setDefaultEventParameters === 'function') {
|
|
172
189
|
const originalSetDefaultEventParameters = analyticsInstance.setDefaultEventParameters.bind(analyticsInstance);
|
|
173
190
|
analyticsInstance.setDefaultEventParameters = async (params) => {
|
|
174
|
-
|
|
175
|
-
|
|
191
|
+
try {
|
|
192
|
+
currentDefaultEventParameters = params ?? {};
|
|
193
|
+
notify();
|
|
194
|
+
}
|
|
195
|
+
catch { }
|
|
176
196
|
return originalSetDefaultEventParameters(params);
|
|
177
197
|
};
|
|
178
198
|
}
|
|
@@ -180,8 +200,11 @@ const setupAnalyticsLogger = (analyticsInstance) => {
|
|
|
180
200
|
if (typeof analyticsInstance.setAnalyticsCollectionEnabled === 'function') {
|
|
181
201
|
const originalSetAnalyticsCollectionEnabled = analyticsInstance.setAnalyticsCollectionEnabled.bind(analyticsInstance);
|
|
182
202
|
analyticsInstance.setAnalyticsCollectionEnabled = async (enabled) => {
|
|
183
|
-
|
|
184
|
-
|
|
203
|
+
try {
|
|
204
|
+
isCollectionEnabled = enabled;
|
|
205
|
+
notify();
|
|
206
|
+
}
|
|
207
|
+
catch { }
|
|
185
208
|
return originalSetAnalyticsCollectionEnabled(enabled);
|
|
186
209
|
};
|
|
187
210
|
}
|
|
@@ -189,11 +212,14 @@ const setupAnalyticsLogger = (analyticsInstance) => {
|
|
|
189
212
|
if (typeof analyticsInstance.resetAnalyticsData === 'function') {
|
|
190
213
|
const originalResetAnalyticsData = analyticsInstance.resetAnalyticsData.bind(analyticsInstance);
|
|
191
214
|
analyticsInstance.resetAnalyticsData = async () => {
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
215
|
+
try {
|
|
216
|
+
(0, exports.clearAnalyticsEvents)();
|
|
217
|
+
currentUserProperties = {};
|
|
218
|
+
currentUserId = undefined;
|
|
219
|
+
currentDefaultEventParameters = {};
|
|
220
|
+
notify();
|
|
221
|
+
}
|
|
222
|
+
catch { }
|
|
197
223
|
return originalResetAnalyticsData();
|
|
198
224
|
};
|
|
199
225
|
}
|
|
@@ -104,12 +104,16 @@ export interface HostBundleAnalysisResult {
|
|
|
104
104
|
};
|
|
105
105
|
}
|
|
106
106
|
export declare const getHostScriptURL: () => string;
|
|
107
|
+
export declare const trackRuntimeModuleExecution: () => void;
|
|
108
|
+
export declare const trackRuntimeDefine: () => void;
|
|
107
109
|
/**
|
|
108
110
|
* Parses raw Metro bundle source code to discover real modules and packages in the host app.
|
|
109
111
|
*/
|
|
110
112
|
export declare const parseBundleSource: (bundleText: string, totalBytes: number, scriptURL: string, isLive?: boolean) => HostBundleAnalysisResult;
|
|
111
113
|
/**
|
|
112
114
|
* Automatically fetch and analyze the real running bundle for the host app.
|
|
115
|
+
* Supports dynamic port detection (8081, 8082, 8083, etc.) and parallel dev server probing.
|
|
113
116
|
*/
|
|
114
|
-
export declare const analyzeHostAppBundle: () => Promise<HostBundleAnalysisResult>;
|
|
117
|
+
export declare const analyzeHostAppBundle: (forceRefresh?: boolean) => Promise<HostBundleAnalysisResult>;
|
|
118
|
+
export declare const clearCachedBundleAnalysis: () => void;
|
|
115
119
|
export declare const getCachedBundleAnalysis: () => HostBundleAnalysisResult | null;
|