react-native-inapp-inspector 2.5.9 → 2.5.11
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/.gradle/9.2.0/fileHashes/fileHashes.bin +0 -0
- package/android/.gradle/9.2.0/fileHashes/fileHashes.lock +0 -0
- package/android/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
- package/android/.gradle/buildOutputCleanup/cache.properties +2 -2
- package/android/build/.transforms/ad628164ecef2a7cc593f0fd2f4050ce/results.bin +1 -0
- package/android/build/.transforms/ad628164ecef2a7cc593f0fd2f4050ce/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/com/inappinspector/BuildConfig.dex +0 -0
- package/android/build/.transforms/ad628164ecef2a7cc593f0fd2f4050ce/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/com/inappinspector/InAppInspectorFloatingView$iconView$1.dex +0 -0
- package/android/build/.transforms/ad628164ecef2a7cc593f0fd2f4050ce/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/com/inappinspector/InAppInspectorFloatingView.dex +0 -0
- package/android/build/.transforms/ad628164ecef2a7cc593f0fd2f4050ce/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/com/inappinspector/NativeNetworkInspectorSpec.dex +0 -0
- package/android/build/.transforms/ad628164ecef2a7cc593f0fd2f4050ce/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/com/inappinspector/NetworkInspectorModule$Companion.dex +0 -0
- package/android/build/.transforms/ad628164ecef2a7cc593f0fd2f4050ce/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/com/inappinspector/NetworkInspectorModule$activityEventListener$1.dex +0 -0
- package/android/build/.transforms/ad628164ecef2a7cc593f0fd2f4050ce/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/com/inappinspector/NetworkInspectorModule$frameCallback$1.dex +0 -0
- package/android/build/.transforms/ad628164ecef2a7cc593f0fd2f4050ce/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/com/inappinspector/NetworkInspectorModule$getCapturedMedia$lambda$57$$inlined$sortedByDescending$1.dex +0 -0
- package/android/build/.transforms/ad628164ecef2a7cc593f0fd2f4050ce/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/com/inappinspector/NetworkInspectorModule$shakeListener$1.dex +0 -0
- package/android/build/.transforms/ad628164ecef2a7cc593f0fd2f4050ce/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/com/inappinspector/NetworkInspectorModule$startVideoRecording$2$1.dex +0 -0
- package/android/build/.transforms/ad628164ecef2a7cc593f0fd2f4050ce/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/com/inappinspector/NetworkInspectorModule.dex +0 -0
- package/android/build/.transforms/ad628164ecef2a7cc593f0fd2f4050ce/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/com/inappinspector/NetworkInspectorPackage.dex +0 -0
- package/android/build/.transforms/ad628164ecef2a7cc593f0fd2f4050ce/transformed/bundleLibRuntimeToDirDebug/desugar_graph.bin +0 -0
- package/android/build/.transforms/c93e459e24d856bde563ebb048265732/results.bin +1 -0
- package/android/build/.transforms/c93e459e24d856bde563ebb048265732/transformed/classes/classes_dex/classes.dex +0 -0
- package/android/build/generated/source/buildConfig/debug/com/inappinspector/BuildConfig.java +10 -0
- package/android/build/generated/source/codegen/java/com/inappinspector/NativeNetworkInspectorSpec.java +160 -0
- package/android/build/generated/source/codegen/jni/CMakeLists.txt +28 -0
- package/android/build/generated/source/codegen/jni/RNInAppInspectorSpec-generated.cpp +212 -0
- package/android/build/generated/source/codegen/jni/RNInAppInspectorSpec.h +31 -0
- package/android/build/generated/source/codegen/jni/react/renderer/components/RNInAppInspectorSpec/ComponentDescriptors.cpp +22 -0
- package/android/build/generated/source/codegen/jni/react/renderer/components/RNInAppInspectorSpec/ComponentDescriptors.h +24 -0
- package/android/build/generated/source/codegen/jni/react/renderer/components/RNInAppInspectorSpec/EventEmitters.cpp +16 -0
- package/android/build/generated/source/codegen/jni/react/renderer/components/RNInAppInspectorSpec/EventEmitters.h +17 -0
- package/android/build/generated/source/codegen/jni/react/renderer/components/RNInAppInspectorSpec/Props.cpp +19 -0
- package/android/build/generated/source/codegen/jni/react/renderer/components/RNInAppInspectorSpec/Props.h +18 -0
- package/android/build/generated/source/codegen/jni/react/renderer/components/RNInAppInspectorSpec/RNInAppInspectorSpecJSI.h +300 -0
- package/android/build/generated/source/codegen/jni/react/renderer/components/RNInAppInspectorSpec/ShadowNodes.cpp +17 -0
- package/android/build/generated/source/codegen/jni/react/renderer/components/RNInAppInspectorSpec/ShadowNodes.h +23 -0
- package/android/build/generated/source/codegen/jni/react/renderer/components/RNInAppInspectorSpec/States.cpp +16 -0
- package/android/build/generated/source/codegen/jni/react/renderer/components/RNInAppInspectorSpec/States.h +20 -0
- package/android/build/generated/source/codegen/schema.json +1 -0
- package/android/build/intermediates/aapt_friendly_merged_manifests/debug/processDebugManifest/aapt/AndroidManifest.xml +7 -0
- package/android/build/intermediates/aapt_friendly_merged_manifests/debug/processDebugManifest/aapt/output-metadata.json +18 -0
- package/android/build/intermediates/aar_metadata/debug/writeDebugAarMetadata/aar-metadata.properties +6 -0
- package/android/build/intermediates/annotation_processor_list/debug/javaPreCompileDebug/annotationProcessors.json +1 -0
- package/android/build/intermediates/compile_library_classes_jar/debug/bundleLibCompileToJarDebug/classes.jar +0 -0
- package/android/build/intermediates/compile_r_class_jar/debug/generateDebugRFile/R.jar +0 -0
- package/android/build/intermediates/compile_symbol_list/debug/generateDebugRFile/R.txt +0 -0
- package/android/build/intermediates/incremental/debug/packageDebugResources/compile-file-map.properties +1 -0
- package/android/build/intermediates/incremental/debug/packageDebugResources/merger.xml +2 -0
- package/android/build/intermediates/incremental/mergeDebugJniLibFolders/merger.xml +2 -0
- package/android/build/intermediates/incremental/mergeDebugShaders/merger.xml +2 -0
- package/android/build/intermediates/incremental/packageDebugAssets/merger.xml +2 -0
- package/android/build/intermediates/java_res/debug/processDebugJavaRes/out/META-INF/react-native-inapp-inspector_debug.kotlin_module +0 -0
- package/android/build/intermediates/javac/debug/compileDebugJavaWithJavac/classes/com/inappinspector/BuildConfig.class +0 -0
- package/android/build/intermediates/javac/debug/compileDebugJavaWithJavac/classes/com/inappinspector/NativeNetworkInspectorSpec.class +0 -0
- package/android/build/intermediates/local_only_symbol_list/debug/parseDebugLocalResources/R-def.txt +2 -0
- package/android/build/intermediates/manifest_merge_blame_file/debug/processDebugManifest/manifest-merger-blame-debug-report.txt +7 -0
- package/android/build/intermediates/merged_manifest/debug/processDebugManifest/AndroidManifest.xml +7 -0
- package/android/build/intermediates/navigation_json/debug/extractDeepLinksDebug/navigation.json +1 -0
- package/android/build/intermediates/nested_resources_validation_report/debug/generateDebugResources/nestedResourcesValidationReport.txt +1 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/META-INF/react-native-inapp-inspector_debug.kotlin_module +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/inappinspector/BuildConfig.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/inappinspector/InAppInspectorFloatingView$iconView$1.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/inappinspector/InAppInspectorFloatingView.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/inappinspector/NativeNetworkInspectorSpec.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/inappinspector/NetworkInspectorModule$Companion.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/inappinspector/NetworkInspectorModule$activityEventListener$1.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/inappinspector/NetworkInspectorModule$frameCallback$1.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/inappinspector/NetworkInspectorModule$getCapturedMedia$lambda$57$$inlined$sortedByDescending$1.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/inappinspector/NetworkInspectorModule$shakeListener$1.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/inappinspector/NetworkInspectorModule$startVideoRecording$2$1.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/inappinspector/NetworkInspectorModule.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/com/inappinspector/NetworkInspectorPackage.class +0 -0
- package/android/build/intermediates/runtime_library_classes_jar/debug/bundleLibRuntimeToJarDebug/classes.jar +0 -0
- package/android/build/intermediates/symbol_list_with_package_name/debug/generateDebugRFile/package-aware-r.txt +1 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/inputs/source-to-output.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/inputs/source-to-output.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/inputs/source-to-output.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/inputs/source-to-output.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/inputs/source-to-output.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/inputs/source-to-output.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/inputs/source-to-output.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/class-attributes.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/class-attributes.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/class-attributes.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/class-attributes.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/class-attributes.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/class-attributes.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/class-attributes.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/class-fq-name-to-source.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/class-fq-name-to-source.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/class-fq-name-to-source.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/class-fq-name-to-source.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/class-fq-name-to-source.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/class-fq-name-to-source.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/class-fq-name-to-source.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/constants.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/constants.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/constants.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/constants.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/constants.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/constants.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/constants.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/internal-name-to-source.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/internal-name-to-source.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/internal-name-to-source.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/internal-name-to-source.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/internal-name-to-source.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/internal-name-to-source.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/internal-name-to-source.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/proto.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/proto.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/proto.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/proto.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/proto.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/proto.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/proto.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/source-to-classes.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/source-to-classes.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/source-to-classes.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/source-to-classes.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/source-to-classes.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/source-to-classes.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/source-to-classes.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/subtypes.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/subtypes.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/subtypes.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/subtypes.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/subtypes.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/subtypes.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/subtypes.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/supertypes.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/supertypes.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/supertypes.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/supertypes.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/supertypes.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/supertypes.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/jvm/kotlin/supertypes.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/lookups/counters.tab +2 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/lookups/file-to-id.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/lookups/file-to-id.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/lookups/file-to-id.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/lookups/file-to-id.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/lookups/file-to-id.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/lookups/file-to-id.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/lookups/file-to-id.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/lookups/id-to-file.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/lookups/id-to-file.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/lookups/id-to-file.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/lookups/id-to-file.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/lookups/id-to-file.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/lookups/id-to-file.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/lookups/id-to-file.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/lookups/lookups.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/lookups/lookups.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/lookups/lookups.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/lookups/lookups.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/lookups/lookups.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/lookups/lookups.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/caches-jvm/lookups/lookups.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/cacheable/last-build.bin +0 -0
- package/android/build/kotlin/compileDebugKotlin/classpath-snapshot/shrunk-classpath-snapshot.bin +0 -0
- package/android/build/kotlin/compileDebugKotlin/local-state/build-history.bin +0 -0
- package/android/build/outputs/logs/manifest-merger-debug-report.txt +17 -0
- package/android/build/tmp/compileDebugJavaWithJavac/previous-compilation-data.bin +0 -0
- package/android/build/tmp/kotlin-classes/debug/META-INF/react-native-inapp-inspector_debug.kotlin_module +0 -0
- package/android/build/tmp/kotlin-classes/debug/com/inappinspector/InAppInspectorFloatingView$iconView$1.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/com/inappinspector/InAppInspectorFloatingView.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/com/inappinspector/NetworkInspectorModule$Companion.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/com/inappinspector/NetworkInspectorModule$activityEventListener$1.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/com/inappinspector/NetworkInspectorModule$frameCallback$1.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/com/inappinspector/NetworkInspectorModule$getCapturedMedia$lambda$57$$inlined$sortedByDescending$1.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/com/inappinspector/NetworkInspectorModule$shakeListener$1.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/com/inappinspector/NetworkInspectorModule$startVideoRecording$2$1.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/com/inappinspector/NetworkInspectorModule.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/com/inappinspector/NetworkInspectorPackage.class +0 -0
- package/dist/commonjs/a11y.d.ts +2 -0
- package/dist/commonjs/a11y.js +1 -0
- package/dist/commonjs/components/ErrorBoundary.js +1 -1
- package/dist/commonjs/components/Inspector/A11yTab.d.ts +2 -0
- package/dist/commonjs/components/Inspector/A11yTab.js +268 -0
- package/dist/commonjs/components/Inspector/AboutModal.js +4 -1
- package/dist/commonjs/components/Inspector/ConsoleExportModal.d.ts +10 -0
- package/dist/commonjs/components/Inspector/ConsoleExportModal.js +317 -0
- package/dist/commonjs/components/Inspector/ConsoleTab.js +20 -15
- package/dist/commonjs/components/Inspector/DeveloperSponsorCard.d.ts +9 -0
- package/dist/commonjs/components/Inspector/DeveloperSponsorCard.js +52 -0
- package/dist/commonjs/components/Inspector/FloatingCaptureWidget.js +4 -4
- package/dist/commonjs/components/Inspector/InspectorHeader.js +74 -66
- package/dist/commonjs/components/Inspector/MediaGalleryTab.js +34 -20
- package/dist/commonjs/components/Inspector/MediaPreviewModal.js +49 -44
- package/dist/commonjs/components/Inspector/NetworkTab.js +10 -7
- package/dist/commonjs/components/Inspector/SettingsPanel.js +242 -148
- package/dist/commonjs/components/Inspector/SkeletonPlaceholder.js +3 -3
- package/dist/commonjs/components/ModuleErrorBoundary.js +1 -1
- package/dist/commonjs/components/NetworkIcons.d.ts +3 -0
- package/dist/commonjs/components/NetworkIcons.js +18 -5
- package/dist/commonjs/components/SkeletonPlaceholder.js +3 -3
- package/dist/commonjs/constants/version.d.ts +1 -1
- package/dist/commonjs/constants/version.js +1 -1
- package/dist/commonjs/customHooks/a11yAdapter.d.ts +11 -0
- package/dist/commonjs/customHooks/a11yAdapter.js +1 -0
- package/dist/commonjs/customHooks/crashHandler.d.ts +9 -1
- package/dist/commonjs/customHooks/crashHandler.js +4 -4
- package/dist/commonjs/helpers/remoteConfig.d.ts +8 -0
- package/dist/commonjs/helpers/remoteConfig.js +1 -1
- package/dist/commonjs/helpers/shareFormatter.d.ts +15 -0
- package/dist/commonjs/helpers/shareFormatter.js +15 -8
- package/dist/commonjs/helpers/sponsorService.d.ts +20 -0
- package/dist/commonjs/helpers/sponsorService.js +1 -0
- package/dist/commonjs/helpers/telemetry.js +1 -1
- package/dist/commonjs/i18n/locales/ar.json +1 -1
- package/dist/commonjs/i18n/locales/bn.json +1 -1
- package/dist/commonjs/i18n/locales/de.json +1 -1
- package/dist/commonjs/i18n/locales/en.json +1 -1
- package/dist/commonjs/i18n/locales/es.json +1 -1
- package/dist/commonjs/i18n/locales/fr.json +1 -1
- package/dist/commonjs/i18n/locales/gu.json +1 -1
- package/dist/commonjs/i18n/locales/hi.json +1 -1
- package/dist/commonjs/i18n/locales/id.json +1 -1
- package/dist/commonjs/i18n/locales/it.json +1 -1
- package/dist/commonjs/i18n/locales/ja.json +1 -1
- package/dist/commonjs/i18n/locales/kn.json +1 -1
- package/dist/commonjs/i18n/locales/ko.json +1 -1
- package/dist/commonjs/i18n/locales/ml.json +1 -1
- package/dist/commonjs/i18n/locales/mr.json +1 -1
- package/dist/commonjs/i18n/locales/nl.json +1 -1
- package/dist/commonjs/i18n/locales/pa.json +1 -1
- package/dist/commonjs/i18n/locales/pl.json +1 -1
- package/dist/commonjs/i18n/locales/pt.json +1 -1
- package/dist/commonjs/i18n/locales/ru.json +1 -1
- package/dist/commonjs/i18n/locales/ta.json +1 -1
- package/dist/commonjs/i18n/locales/te.json +1 -1
- package/dist/commonjs/i18n/locales/tr.json +1 -1
- package/dist/commonjs/i18n/locales/vi.json +1 -1
- package/dist/commonjs/i18n/locales/zh.json +1 -1
- package/dist/commonjs/index.d.ts +3 -1
- package/dist/commonjs/index.js +3 -3
- package/dist/commonjs/types/interfaces.d.ts +20 -0
- package/dist/esm/a11y.d.ts +2 -0
- package/dist/esm/a11y.js +1 -0
- package/dist/esm/components/ErrorBoundary.js +10 -10
- package/dist/esm/components/Inspector/A11yTab.d.ts +2 -0
- package/dist/esm/components/Inspector/A11yTab.js +268 -0
- package/dist/esm/components/Inspector/AboutModal.js +17 -14
- package/dist/esm/components/Inspector/ConsoleExportModal.d.ts +10 -0
- package/dist/esm/components/Inspector/ConsoleExportModal.js +317 -0
- package/dist/esm/components/Inspector/ConsoleTab.js +38 -33
- package/dist/esm/components/Inspector/DeveloperSponsorCard.d.ts +9 -0
- package/dist/esm/components/Inspector/DeveloperSponsorCard.js +52 -0
- package/dist/esm/components/Inspector/FloatingCaptureWidget.js +22 -22
- package/dist/esm/components/Inspector/InspectorHeader.js +195 -187
- package/dist/esm/components/Inspector/MediaGalleryTab.js +88 -74
- package/dist/esm/components/Inspector/MediaPreviewModal.js +178 -173
- package/dist/esm/components/Inspector/NetworkTab.js +86 -83
- package/dist/esm/components/Inspector/SettingsPanel.js +329 -235
- package/dist/esm/components/Inspector/SkeletonPlaceholder.js +11 -11
- package/dist/esm/components/ModuleErrorBoundary.js +1 -1
- package/dist/esm/components/NetworkIcons.d.ts +3 -0
- package/dist/esm/components/NetworkIcons.js +16 -3
- package/dist/esm/components/SkeletonPlaceholder.js +11 -11
- package/dist/esm/constants/version.d.ts +1 -1
- package/dist/esm/constants/version.js +1 -1
- package/dist/esm/customHooks/a11yAdapter.d.ts +11 -0
- package/dist/esm/customHooks/a11yAdapter.js +1 -0
- package/dist/esm/customHooks/crashHandler.d.ts +9 -1
- package/dist/esm/customHooks/crashHandler.js +6 -6
- package/dist/esm/helpers/remoteConfig.d.ts +8 -0
- package/dist/esm/helpers/remoteConfig.js +1 -1
- package/dist/esm/helpers/shareFormatter.d.ts +15 -0
- package/dist/esm/helpers/shareFormatter.js +15 -8
- package/dist/esm/helpers/sponsorService.d.ts +20 -0
- package/dist/esm/helpers/sponsorService.js +1 -0
- package/dist/esm/helpers/telemetry.js +1 -1
- package/dist/esm/i18n/locales/ar.json +1 -1
- package/dist/esm/i18n/locales/bn.json +1 -1
- package/dist/esm/i18n/locales/de.json +1 -1
- package/dist/esm/i18n/locales/en.json +1 -1
- package/dist/esm/i18n/locales/es.json +1 -1
- package/dist/esm/i18n/locales/fr.json +1 -1
- package/dist/esm/i18n/locales/gu.json +1 -1
- package/dist/esm/i18n/locales/hi.json +1 -1
- package/dist/esm/i18n/locales/id.json +1 -1
- package/dist/esm/i18n/locales/it.json +1 -1
- package/dist/esm/i18n/locales/ja.json +1 -1
- package/dist/esm/i18n/locales/kn.json +1 -1
- package/dist/esm/i18n/locales/ko.json +1 -1
- package/dist/esm/i18n/locales/ml.json +1 -1
- package/dist/esm/i18n/locales/mr.json +1 -1
- package/dist/esm/i18n/locales/nl.json +1 -1
- package/dist/esm/i18n/locales/pa.json +1 -1
- package/dist/esm/i18n/locales/pl.json +1 -1
- package/dist/esm/i18n/locales/pt.json +1 -1
- package/dist/esm/i18n/locales/ru.json +1 -1
- package/dist/esm/i18n/locales/ta.json +1 -1
- package/dist/esm/i18n/locales/te.json +1 -1
- package/dist/esm/i18n/locales/tr.json +1 -1
- package/dist/esm/i18n/locales/vi.json +1 -1
- package/dist/esm/i18n/locales/zh.json +1 -1
- package/dist/esm/index.d.ts +3 -1
- package/dist/esm/index.js +8 -8
- package/dist/esm/types/interfaces.d.ts +20 -0
- package/package.json +1 -1
|
@@ -1,23 +1,23 @@
|
|
|
1
|
-
import
|
|
1
|
+
import x,{useEffect as v,useRef as D}from"react";import{Animated as f,StyleSheet as L,View as S}from"react-native";import{AppColors as b}from"../../styles/AppColors";export const SkeletonPlaceholder=x.memo(function({cardCount:B=4}){const C=D(new f.Value(.45)).current;return v(()=>{const V=f.loop(f.sequence([f.timing(C,{toValue:.95,duration:750,useNativeDriver:!1}),f.timing(C,{toValue:.45,duration:750,useNativeDriver:!1})]));return V.start(),()=>V.stop()},[C]),<S style={e.container}>
|
|
2
2
|
|
|
3
3
|
<S style={e.toolbarSkeleton}>
|
|
4
|
-
<
|
|
4
|
+
<f.View style={[e.searchBarSkeleton,{opacity:C}]}/>
|
|
5
5
|
<S style={e.actionButtonsRow}>
|
|
6
|
-
<
|
|
7
|
-
<
|
|
6
|
+
<f.View style={[e.iconButtonSkeleton,{opacity:C}]}/>
|
|
7
|
+
<f.View style={[e.iconButtonSkeleton,{opacity:C}]}/>
|
|
8
8
|
</S>
|
|
9
9
|
</S>
|
|
10
10
|
|
|
11
11
|
|
|
12
12
|
<S style={e.chipStripSkeleton}>
|
|
13
|
-
<
|
|
14
|
-
<
|
|
15
|
-
<
|
|
16
|
-
<
|
|
13
|
+
<f.View style={[e.chipSkeleton,{width:48,opacity:C}]}/>
|
|
14
|
+
<f.View style={[e.chipSkeleton,{width:68,opacity:C}]}/>
|
|
15
|
+
<f.View style={[e.chipSkeleton,{width:76,opacity:C}]}/>
|
|
16
|
+
<f.View style={[e.chipSkeleton,{width:58,opacity:C}]}/>
|
|
17
17
|
</S>
|
|
18
18
|
|
|
19
19
|
|
|
20
|
-
{Array.from({length:
|
|
20
|
+
{Array.from({length:B}).map((V,R)=><f.View key={`skeleton_card_${R}`}style={[e.cardSkeleton,{opacity:C}]}>
|
|
21
21
|
|
|
22
22
|
<S style={e.cardTopRow}>
|
|
23
23
|
<S style={e.badgeGroup}>
|
|
@@ -36,5 +36,5 @@ import B,{useEffect as R,useRef as x}from"react";import{Animated as k,StyleSheet
|
|
|
36
36
|
<S style={e.metaPillSkeleton}/>
|
|
37
37
|
<S style={e.metaPillSkeleton}/>
|
|
38
38
|
</S>
|
|
39
|
-
</
|
|
40
|
-
</S>});const e=
|
|
39
|
+
</f.View>)}
|
|
40
|
+
</S>});const e=L.create({container:{flex:1,paddingHorizontal:12,paddingTop:8},toolbarSkeleton:{flexDirection:"row",alignItems:"center",gap:8,marginBottom:8},searchBarSkeleton:{flex:1,height:36,borderRadius:8,backgroundColor:b.graySurface,borderWidth:1,borderColor:b.dividerColor},actionButtonsRow:{flexDirection:"row",gap:6},iconButtonSkeleton:{width:36,height:36,borderRadius:8,backgroundColor:b.graySurface,borderWidth:1,borderColor:b.dividerColor},chipStripSkeleton:{flexDirection:"row",gap:6,marginBottom:10},chipSkeleton:{height:24,borderRadius:6,backgroundColor:b.graySurface,borderWidth:1,borderColor:b.dividerColor},cardSkeleton:{backgroundColor:b.primaryLight,borderRadius:10,padding:12,marginBottom:8,borderWidth:1,borderColor:b.dividerColor},cardTopRow:{flexDirection:"row",justifyContent:"space-between",alignItems:"center",marginBottom:8},badgeGroup:{flexDirection:"row",alignItems:"center",gap:6},statusBadgeSkeleton:{width:38,height:18,borderRadius:4,backgroundColor:b.slate200},methodBadgeSkeleton:{width:44,height:18,borderRadius:4,backgroundColor:b.slate200},timeSkeleton:{width:48,height:12,borderRadius:4,backgroundColor:b.slate200},urlLineLong:{height:13,borderRadius:4,backgroundColor:b.slate200,marginBottom:5,width:"90%"},urlLineShort:{height:11,borderRadius:4,backgroundColor:b.slate200,marginBottom:8,width:"55%"},cardBottomRow:{flexDirection:"row",gap:8,marginTop:2},metaPillSkeleton:{width:52,height:14,borderRadius:4,backgroundColor:b.slate200}});export default SkeletonPlaceholder;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import{Component as V}from"react";import{StyleSheet as D,Text as T,View as C,TouchableOpacity as I,Platform as B}from"react-native";import{AppFonts as S}from"../styles/AppFonts";import{AppColors as e}from"../styles/AppColors";import{copyToClipboard as F}from"../helpers";import{WarningTriangleIcon as M,RefreshCcwIcon as W,CopyIcon as A}from"./NetworkIcons";import{handleInterceptedCrash as v}from"../customHooks/crashHandler";import{CrashType as N}from"../types/enums";import{t as E}from"../i18n";export class ModuleErrorBoundary extends V{constructor(){super(...arguments),this.state={hasError:!1,error:null,copied:!1},this.handleRetry=()=>{this.setState({hasError:!1,error:null,copied:!1}),this.props.onRetry&&this.props.onRetry()},this.handleCopy=()=>{if(!this.state.error)return;const r=`[Module Error: ${this.props.moduleName||"Micro-Feature"}]
|
|
2
2
|
Message: ${this.state.error.message}
|
|
3
|
-
Stack: ${this.state.error.stack||"N/A"}`;F(r),this.setState({copied:!0}),setTimeout(()=>{this.setState({copied:!1})},2e3)}}static getDerivedStateFromError(r){return{hasError:!0,error:r}}componentDidCatch(r,R){try{v(r,r?.stack,!1,N.
|
|
3
|
+
Stack: ${this.state.error.stack||"N/A"}`;F(r),this.setState({copied:!0}),setTimeout(()=>{this.setState({copied:!1})},2e3)}}static getDerivedStateFromError(r){return{hasError:!0,error:r}}componentDidCatch(r,R){try{v(r,r?.stack,!1,N.Render,R.componentStack||void 0)}catch{}this.props.onError&&this.props.onError(r,R)}render(){if(this.state.hasError&&this.state.error){const{fallback:r,moduleName:R="UI Module",containerStyle:O}=this.props;return typeof r=="function"?r(this.state.error,this.handleRetry):r||<C style={[t.card,O]}>
|
|
4
4
|
<C style={t.headerRow}>
|
|
5
5
|
<C style={t.titleRow}>
|
|
6
6
|
<M color={e.red600}size={16}/>
|
|
@@ -229,3 +229,6 @@ export declare const WarmthIcon: ({ color, size }: IconProps) => React.JSX.Eleme
|
|
|
229
229
|
export declare const ExposureIcon: ({ color, size }: IconProps) => React.JSX.Element;
|
|
230
230
|
export declare const VignetteIcon: ({ color, size }: IconProps) => React.JSX.Element;
|
|
231
231
|
export declare const ArrowForwardIcon: ({ color, size }: IconProps) => React.JSX.Element;
|
|
232
|
+
export declare const ScaleBalanceIcon: ({ color, size }: IconProps) => React.JSX.Element;
|
|
233
|
+
export declare const VolumeMuteIcon: ({ color, size }: IconProps) => React.JSX.Element;
|
|
234
|
+
export declare const ShieldBanIcon: ({ color, size }: IconProps) => React.JSX.Element;
|
|
@@ -143,9 +143,9 @@ import"react";import W,{Circle as M,Ellipse as T,Line as S,Path as L,Polygon as
|
|
|
143
143
|
</W>,UserIcon=({color:e=p.grayTextWeak,size:t=12})=><W width={t}height={t}viewBox="0 0 24 24"fill="none">
|
|
144
144
|
<L d="M20 21v-2a4 4 0 0 0-4-4H8a4 4 0 0 0-4 4v2"stroke={e}strokeWidth="2"strokeLinecap="round"strokeLinejoin="round"/>
|
|
145
145
|
<M cx="12"cy="7"r="4"stroke={e}strokeWidth="2"/>
|
|
146
|
-
</W>,InfoCircleIcon=({color:e=p.grayTextWeak,size:t=
|
|
147
|
-
<M cx="12"cy="12"r="
|
|
148
|
-
<L d="M12 16v-4M12
|
|
146
|
+
</W>,InfoCircleIcon=({color:e=p.grayTextWeak,size:t=14})=><W width={t}height={t}viewBox="0 0 24 24"fill="none">
|
|
147
|
+
<M cx="12"cy="12"r="9"stroke={e}strokeWidth="2"/>
|
|
148
|
+
<L d="M12 16v-4M12 8.5h.01"stroke={e}strokeWidth="2.2"strokeLinecap="round"strokeLinejoin="round"/>
|
|
149
149
|
</W>,WarningTriangleIcon=({color:e=p.grayTextWeak,size:t=12})=><W width={t}height={t}viewBox="0 0 24 24"fill="none">
|
|
150
150
|
<L d="M10.29 3.86L1.82 18a2 2 0 0 0 1.71 3h16.94a2 2 0 0 0 1.71-3L13.71 3.86a2 2 0 0 0-3.42 0z"stroke={e}strokeWidth="2"strokeLinecap="round"strokeLinejoin="round"/>
|
|
151
151
|
<L d="M12 9v4M12 17h.01"stroke={e}strokeWidth="2"strokeLinecap="round"/>
|
|
@@ -754,4 +754,17 @@ import"react";import W,{Circle as M,Ellipse as T,Line as S,Path as L,Polygon as
|
|
|
754
754
|
<T cx="12"cy="12"rx="6"ry="4.5"stroke={e}strokeWidth="1.8"strokeDasharray="2,2"/>
|
|
755
755
|
</W>,ArrowForwardIcon=({color:e=p.white,size:t=16})=><W width={t}height={t}viewBox="0 0 24 24"fill="none">
|
|
756
756
|
<L d="M5 12h14M12 5l7 7-7 7"stroke={e}strokeWidth="2"strokeLinecap="round"strokeLinejoin="round"/>
|
|
757
|
+
</W>,ScaleBalanceIcon=({color:e=p.white,size:t=16})=><W width={t}height={t}viewBox="0 0 24 24"fill="none">
|
|
758
|
+
<L d="M12 3v18"stroke={e}strokeWidth="2"strokeLinecap="round"strokeLinejoin="round"/>
|
|
759
|
+
<L d="M4 6l8-3 8 3"stroke={e}strokeWidth="2"strokeLinecap="round"strokeLinejoin="round"/>
|
|
760
|
+
<L d="M4 10l4 8H0l4-8z"stroke={e}strokeWidth="1.5"strokeLinecap="round"strokeLinejoin="round"/>
|
|
761
|
+
<L d="M20 10l4 8h-8l4-8z"stroke={e}strokeWidth="1.5"strokeLinecap="round"strokeLinejoin="round"/>
|
|
762
|
+
<L d="M8 21h8"stroke={e}strokeWidth="2"strokeLinecap="round"/>
|
|
763
|
+
</W>,VolumeMuteIcon=({color:e=p.white,size:t=16})=><W width={t}height={t}viewBox="0 0 24 24"fill="none">
|
|
764
|
+
<H points="11 5 6 9 2 9 2 15 6 15 11 19 11 5"stroke={e}strokeWidth="2"strokeLinecap="round"strokeLinejoin="round"/>
|
|
765
|
+
<S x1="23"y1="9"x2="17"y2="15"stroke={e}strokeWidth="2"strokeLinecap="round"strokeLinejoin="round"/>
|
|
766
|
+
<S x1="17"y1="9"x2="23"y2="15"stroke={e}strokeWidth="2"strokeLinecap="round"strokeLinejoin="round"/>
|
|
767
|
+
</W>,ShieldBanIcon=({color:e=p.white,size:t=16})=><W width={t}height={t}viewBox="0 0 24 24"fill="none">
|
|
768
|
+
<L d="M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10z"stroke={e}strokeWidth="2"strokeLinecap="round"strokeLinejoin="round"/>
|
|
769
|
+
<S x1="4.5"y1="4.5"x2="19.5"y2="19.5"stroke={e}strokeWidth="2"strokeLinecap="round"/>
|
|
757
770
|
</W>;
|
|
@@ -1,23 +1,23 @@
|
|
|
1
|
-
import
|
|
1
|
+
import x,{useEffect as v,useRef as D}from"react";import{Animated as f,StyleSheet as L,View as S}from"react-native";import{AppColors as b}from"../styles/AppColors";export const SkeletonPlaceholder=x.memo(function({cardCount:B=4}){const C=D(new f.Value(.45)).current;return v(()=>{const V=f.loop(f.sequence([f.timing(C,{toValue:.95,duration:750,useNativeDriver:!1}),f.timing(C,{toValue:.45,duration:750,useNativeDriver:!1})]));return V.start(),()=>V.stop()},[C]),<S style={e.container}>
|
|
2
2
|
|
|
3
3
|
<S style={e.toolbarSkeleton}>
|
|
4
|
-
<
|
|
4
|
+
<f.View style={[e.searchBarSkeleton,{opacity:C}]}/>
|
|
5
5
|
<S style={e.actionButtonsRow}>
|
|
6
|
-
<
|
|
7
|
-
<
|
|
6
|
+
<f.View style={[e.iconButtonSkeleton,{opacity:C}]}/>
|
|
7
|
+
<f.View style={[e.iconButtonSkeleton,{opacity:C}]}/>
|
|
8
8
|
</S>
|
|
9
9
|
</S>
|
|
10
10
|
|
|
11
11
|
|
|
12
12
|
<S style={e.chipStripSkeleton}>
|
|
13
|
-
<
|
|
14
|
-
<
|
|
15
|
-
<
|
|
16
|
-
<
|
|
13
|
+
<f.View style={[e.chipSkeleton,{width:48,opacity:C}]}/>
|
|
14
|
+
<f.View style={[e.chipSkeleton,{width:68,opacity:C}]}/>
|
|
15
|
+
<f.View style={[e.chipSkeleton,{width:76,opacity:C}]}/>
|
|
16
|
+
<f.View style={[e.chipSkeleton,{width:58,opacity:C}]}/>
|
|
17
17
|
</S>
|
|
18
18
|
|
|
19
19
|
|
|
20
|
-
{Array.from({length:
|
|
20
|
+
{Array.from({length:B}).map((V,R)=><f.View key={`skeleton_card_${R}`}style={[e.cardSkeleton,{opacity:C}]}>
|
|
21
21
|
|
|
22
22
|
<S style={e.cardTopRow}>
|
|
23
23
|
<S style={e.badgeGroup}>
|
|
@@ -36,5 +36,5 @@ import B,{useEffect as R,useRef as x}from"react";import{Animated as k,StyleSheet
|
|
|
36
36
|
<S style={e.metaPillSkeleton}/>
|
|
37
37
|
<S style={e.metaPillSkeleton}/>
|
|
38
38
|
</S>
|
|
39
|
-
</
|
|
40
|
-
</S>});const e=
|
|
39
|
+
</f.View>)}
|
|
40
|
+
</S>});const e=L.create({container:{flex:1,paddingHorizontal:12,paddingTop:8},toolbarSkeleton:{flexDirection:"row",alignItems:"center",gap:8,marginBottom:8},searchBarSkeleton:{flex:1,height:36,borderRadius:8,backgroundColor:b.graySurface,borderWidth:1,borderColor:b.dividerColor},actionButtonsRow:{flexDirection:"row",gap:6},iconButtonSkeleton:{width:36,height:36,borderRadius:8,backgroundColor:b.graySurface,borderWidth:1,borderColor:b.dividerColor},chipStripSkeleton:{flexDirection:"row",gap:6,marginBottom:10},chipSkeleton:{height:24,borderRadius:6,backgroundColor:b.graySurface,borderWidth:1,borderColor:b.dividerColor},cardSkeleton:{backgroundColor:b.primaryLight,borderRadius:10,padding:12,marginBottom:8,borderWidth:1,borderColor:b.dividerColor},cardTopRow:{flexDirection:"row",justifyContent:"space-between",alignItems:"center",marginBottom:8},badgeGroup:{flexDirection:"row",alignItems:"center",gap:6},statusBadgeSkeleton:{width:38,height:18,borderRadius:4,backgroundColor:b.slate200},methodBadgeSkeleton:{width:44,height:18,borderRadius:4,backgroundColor:b.slate200},timeSkeleton:{width:48,height:12,borderRadius:4,backgroundColor:b.slate200},urlLineLong:{height:13,borderRadius:4,backgroundColor:b.slate200,marginBottom:5,width:"90%"},urlLineShort:{height:11,borderRadius:4,backgroundColor:b.slate200,marginBottom:8,width:"55%"},cardBottomRow:{flexDirection:"row",gap:8,marginTop:2},metaPillSkeleton:{width:52,height:14,borderRadius:4,backgroundColor:b.slate200}});export default SkeletonPlaceholder;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const LIB_VERSION = "2.5.
|
|
1
|
+
export declare const LIB_VERSION = "2.5.11";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export const LIB_VERSION="2.5.
|
|
1
|
+
export const LIB_VERSION="2.5.11";
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { A11yTelemetryState, ColorContrastResult, TouchTargetEvaluation, WcagRule } from '../types';
|
|
2
|
+
export declare const connectA11ySuite: (suiteInstance: any) => void;
|
|
3
|
+
export declare const getA11ySuiteInstance: () => any;
|
|
4
|
+
export declare const getA11yState: () => A11yTelemetryState;
|
|
5
|
+
export declare const subscribeA11yState: (listener: (state: A11yTelemetryState) => void) => (() => void);
|
|
6
|
+
export declare const syncA11yTelemetry: () => Promise<A11yTelemetryState>;
|
|
7
|
+
export declare const initA11yListeners: () => void;
|
|
8
|
+
export declare const announceA11y: (message: string) => boolean;
|
|
9
|
+
export declare const calculateContrastRatio: (fgHex: string, bgHex: string) => ColorContrastResult;
|
|
10
|
+
export declare const evaluateTouchTarget: (width: number, height: number) => TouchTargetEvaluation;
|
|
11
|
+
export declare const WCAG_RULES: WcagRule[];
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{AccessibilityInfo as a,PixelRatio as u}from"react-native";let h=null,s;export const connectA11ySuite=e=>{e&&(h=e,s=e,c())},getA11ySuiteInstance=()=>{if(h)return h;if(s!==void 0)return s;if(globalThis.A11ySuite)return s=globalThis.A11ySuite,s;if(globalThis.__A11Y_SUITE__)return s=globalThis.__A11Y_SUITE__,s;try{const e="react-native-a11y-suite",t=typeof require=="function"?require:null;if(t){const i=t(e);return s=i?.default||i||null,s}}catch{s=null}return s=null,null};let n={isScreenReaderEnabled:!1,isReduceMotionEnabled:!1,isBoldTextEnabled:!1,isGrayscaleEnabled:!1,isInvertColorsEnabled:!1,isHighContrastEnabled:!1,fontScale:u.getFontScale?u.getFontScale():1,nativeModuleAvailable:!1,lastUpdated:Date.now()};const b=new Set,c=()=>{b.forEach(e=>{try{e(n)}catch{}})};export const getA11yState=()=>({...n}),subscribeA11yState=e=>(b.add(e),e(n),()=>{b.delete(e)}),syncA11yTelemetry=async()=>{const e=getA11ySuiteInstance(),t=u.getFontScale?u.getFontScale():1;let i=!1,r=!1,o=!1,l=!1,g=!1,p=!1;try{i=await a.isScreenReaderEnabled()}catch{}try{r=await a.isReduceMotionEnabled()}catch{}try{a.isBoldTextEnabled&&(o=await a.isBoldTextEnabled())}catch{}try{a.isGrayscaleEnabled&&(l=await a.isGrayscaleEnabled())}catch{}try{a.isInvertColorsEnabled&&(g=await a.isInvertColorsEnabled())}catch{}try{a.isHighTextContrastEnabled&&(p=await a.isHighTextContrastEnabled())}catch{}return n={isScreenReaderEnabled:i,isReduceMotionEnabled:r,isBoldTextEnabled:o,isGrayscaleEnabled:l,isInvertColorsEnabled:g,isHighContrastEnabled:p,fontScale:Math.round(t*100)/100,nativeModuleAvailable:!!e,lastUpdated:Date.now()},c(),n};let m=!1;export const initA11yListeners=()=>{if(!m){m=!0,syncA11yTelemetry();try{a.addEventListener("screenReaderChanged",e=>{n={...n,isScreenReaderEnabled:!!e,lastUpdated:Date.now()},c()})}catch{}try{a.addEventListener("reduceMotionChanged",e=>{n={...n,isReduceMotionEnabled:!!e,lastUpdated:Date.now()},c()})}catch{}try{a.addEventListener("boldTextChanged",e=>{n={...n,isBoldTextEnabled:!!e,lastUpdated:Date.now()},c()})}catch{}try{a.addEventListener("grayscaleChanged",e=>{n={...n,isGrayscaleEnabled:!!e,lastUpdated:Date.now()},c()})}catch{}try{a.addEventListener("invertColorsChanged",e=>{n={...n,isInvertColorsEnabled:!!e,lastUpdated:Date.now()},c()})}catch{}try{a.addEventListener("highTextContrastChanged",e=>{n={...n,isHighContrastEnabled:!!e,lastUpdated:Date.now()},c()})}catch{}}},announceA11y=e=>{if(!e||!e.trim())return!1;try{const t=getA11ySuiteInstance();if(t&&typeof t.announce=="function")return t.announce(e),!0}catch{}try{return a.announceForAccessibility(e),!0}catch{return!1}};const w=e=>{let t=e.replace("#","").trim();if(t.length===3&&(t=t.split("").map(l=>l+l).join("")),t.length!==6)return null;const i=parseInt(t.substring(0,2),16),r=parseInt(t.substring(2,4),16),o=parseInt(t.substring(4,6),16);return isNaN(i)||isNaN(r)||isNaN(o)?null:[i,r,o]},A=(e,t,i)=>{const r=[e/255,t/255,i/255].map(o=>o<=.03928?o/12.92:Math.pow((o+.055)/1.055,2.4));return .2126*r[0]+.7152*r[1]+.0722*r[2]};export const calculateContrastRatio=(e,t)=>{const i=w(e),r=w(t);if(!i||!r)return{fgHex:e,bgHex:t,ratio:1,aaNormal:!1,aaLarge:!1,aaaNormal:!1,aaaLarge:!1};const o=A(i[0],i[1],i[2]),l=A(r[0],r[1],r[2]),g=Math.max(o,l),p=Math.min(o,l),y=(g+.05)/(p+.05),d=Math.round(y*100)/100;return{fgHex:e,bgHex:t,ratio:d,aaNormal:d>=4.5,aaLarge:d>=3,aaaNormal:d>=7,aaaLarge:d>=4.5}},evaluateTouchTarget=(e,t)=>({width:e,height:t,iosMinMet:e>=44&&t>=44,androidMinMet:e>=48&&t>=48}),WCAG_RULES=[{id:"1.1.1",title:"Non-text Content",level:"A",principle:"Perceivable",description:"All non-text content (icons, images, diagrams) must have a text alternative.",mobileRecommendation:"Provide accessibilityLabel or accessible={false} for purely decorative icons.",wcagUrl:"https://www.w3.org/WAI/WCAG22/Understanding/non-text-content"},{id:"1.3.1",title:"Info and Relationships",level:"A",principle:"Perceivable",description:"Information, structure, and relationships conveyed through presentation can be programmatically determined.",mobileRecommendation:'Use accessibilityRole="header", accessibilityRole="button", or AccessibleHeading.',wcagUrl:"https://www.w3.org/WAI/WCAG22/Understanding/info-and-relationships"},{id:"1.4.3",title:"Contrast (Minimum)",level:"AA",principle:"Perceivable",description:"Visual presentation of text must have a contrast ratio of at least 4.5:1 (3:1 for large text).",mobileRecommendation:"Ensure high contrast between text and background on both light and dark themes.",wcagUrl:"https://www.w3.org/WAI/WCAG22/Understanding/contrast-minimum"},{id:"1.4.4",title:"Resize Text",level:"AA",principle:"Perceivable",description:"Text can be resized without assistive technology up to 200 percent without loss of content or functionality.",mobileRecommendation:"Avoid fixed height containers with overflow: hidden on Text elements. Test with max font scale.",wcagUrl:"https://www.w3.org/WAI/WCAG22/Understanding/resize-text"},{id:"1.4.11",title:"Non-text Contrast",level:"AA",principle:"Perceivable",description:"The visual presentation of UI components and graphical objects has a contrast ratio of at least 3:1.",mobileRecommendation:"Ensure active borders, focus rings, and action icons meet 3:1 contrast against adjacent colors.",wcagUrl:"https://www.w3.org/WAI/WCAG22/Understanding/non-text-contrast"},{id:"2.1.1",title:"Keyboard / Hardware Navigation",level:"A",principle:"Operable",description:"All functionality is operable through a keyboard or switch access interface.",mobileRecommendation:"Support external Bluetooth keyboards and accessibilityActions for gestures.",wcagUrl:"https://www.w3.org/WAI/WCAG22/Understanding/keyboard"},{id:"2.4.3",title:"Focus Order",level:"A",principle:"Operable",description:"Components receive focus in an order that preserves meaning and operability.",mobileRecommendation:"Ensure modal dialogs trap focus and restore focus on dismissal.",wcagUrl:"https://www.w3.org/WAI/WCAG22/Understanding/focus-order"},{id:"2.4.7",title:"Focus Visible",level:"AA",principle:"Operable",description:"Any keyboard operable user interface has an indicator of focus.",mobileRecommendation:"Highlight active focused items when keyboard/TalkBack navigation is used.",wcagUrl:"https://www.w3.org/WAI/WCAG22/Understanding/focus-visible"},{id:"2.5.5",title:"Target Size (Enhanced)",level:"AAA",principle:"Operable",description:"The size of the target for pointer inputs is at least 44 by 44 CSS pixels.",mobileRecommendation:"Use AccessibleTouchTarget or hitSlop to ensure touch targets meet 44x44pt.",wcagUrl:"https://www.w3.org/WAI/WCAG22/Understanding/target-size-enhanced"},{id:"2.5.8",title:"Target Size (Minimum) - WCAG 2.2",level:"AA",principle:"Operable",description:"Targets have an area of at least 24 by 24 CSS pixels with sufficient spacing.",mobileRecommendation:"Ensure buttons are separated and have at least 24x24 minimum target size.",wcagUrl:"https://www.w3.org/WAI/WCAG22/Understanding/target-size-minimum"},{id:"3.3.1",title:"Error Identification",level:"A",principle:"Understandable",description:"If an input error is automatically detected, the item is identified and described in text.",mobileRecommendation:'Set accessibilityRole="alert" or accessibilityInvalid on form fields with error messages.',wcagUrl:"https://www.w3.org/WAI/WCAG22/Understanding/error-identification"},{id:"4.1.2",title:"Name, Role, Value",level:"A",principle:"Robust",description:"For all UI components, the name and role can be programmatically determined and state changes reported.",mobileRecommendation:"Use accessibilityRole, accessibilityState={{checked, disabled, selected}} on interactive elements.",wcagUrl:"https://www.w3.org/WAI/WCAG22/Understanding/name-role-value"},{id:"4.1.3",title:"Status Messages",level:"AA",principle:"Robust",description:"Status messages can be programmatically determined through role or properties without receiving focus.",mobileRecommendation:'Use LiveRegion, accessibilityLiveRegion="polite" or announceA11y for asynchronous alerts.',wcagUrl:"https://www.w3.org/WAI/WCAG22/Understanding/status-messages"}];
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { CrashRecord, ParsedStackFrame, CrashBreadcrumb } from '../types';
|
|
1
|
+
import { CrashRecord, ParsedStackFrame, CrashBreadcrumb, CrashIgnoredTypes, CrashModalTriggerPolicy } from '../types';
|
|
2
2
|
import { CrashExportFormat, CrashType } from '../types/enums';
|
|
3
3
|
export interface CrashEventPayload {
|
|
4
4
|
error: Error | any;
|
|
@@ -8,9 +8,17 @@ export interface CrashEventPayload {
|
|
|
8
8
|
timestamp: number;
|
|
9
9
|
logId?: number;
|
|
10
10
|
crashRecord?: CrashRecord;
|
|
11
|
+
shouldShowModal?: boolean;
|
|
11
12
|
}
|
|
12
13
|
export { CrashExportFormat };
|
|
14
|
+
export declare const DEFAULT_CRASH_IGNORED_TYPES: CrashIgnoredTypes;
|
|
13
15
|
type CrashListener = (payload: CrashEventPayload) => void;
|
|
16
|
+
export declare const setCrashIgnoredTypesConfig: (config: Partial<CrashIgnoredTypes>) => void;
|
|
17
|
+
export declare const getCrashIgnoredTypesConfig: () => CrashIgnoredTypes;
|
|
18
|
+
export declare const setCrashModalTriggerPolicyConfig: (policy: CrashModalTriggerPolicy) => void;
|
|
19
|
+
export declare const getCrashModalTriggerPolicyConfig: () => CrashModalTriggerPolicy;
|
|
20
|
+
export declare const setCrashThrottleDuplicatesConfig: (throttle: boolean) => void;
|
|
21
|
+
export declare const applyCrashPolicyPreset: (preset: "balanced" | "max_shield" | "silent") => CrashIgnoredTypes;
|
|
14
22
|
export declare const setCrashModuleEnabled: (enabled: boolean) => void;
|
|
15
23
|
export declare const getCrashModuleEnabled: () => boolean;
|
|
16
24
|
export declare const setMaxCrashLogsLimit: (max: number) => void;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import{LogBox as
|
|
2
|
-
`),n=[];for(const o of r){const t=o.trim();if(!t||t.includes("crashHandler.ts")||t.includes("handleInterceptedCrash")||t.includes("addLogFromCrash")||t.includes("setupGlobalCrashHandler"))continue;const a=t.match(/^([^@]+)@(.*):(\d+):(\d+)$/);if(a){const[,c,i,
|
|
3
|
-
`):d=a.stack||new Error().stack||"";let
|
|
1
|
+
import{LogBox as D,NativeModules as M,TurboModuleRegistry as U,NativeEventEmitter as P,Platform as x,AppState as J,Dimensions as z}from"react-native";import{CrashExportFormat as V,CrashType as f}from"../types/enums";import{addLogFromCrash as G}from"./consoleLogger";import{showNativeFloatingButton as W,setNativeFloatingButtonBadge as Y}from"../native/NativeInspector";import{t as s}from"../i18n";export{V as CrashExportFormat};export const DEFAULT_CRASH_IGNORED_TYPES={js:!0,native:!1,render:!0,promise:!1,custom:!1};let k=[],T=!1,N=0,L="",p=[],g=[];const F=50;let C=100;const Z=Date.now();let _=!1,b={...DEFAULT_CRASH_IGNORED_TYPES},w="fatal_only",B=!0;export const setCrashIgnoredTypesConfig=e=>{b={...b,...e}},getCrashIgnoredTypesConfig=()=>({...b}),setCrashModalTriggerPolicyConfig=e=>{w=e},getCrashModalTriggerPolicyConfig=()=>w,setCrashThrottleDuplicatesConfig=e=>{B=e},applyCrashPolicyPreset=e=>{switch(e){case"max_shield":b={js:!1,native:!1,render:!1,promise:!1,custom:!1};break;case"silent":b={js:!0,native:!0,render:!0,promise:!0,custom:!0};break;default:b={...DEFAULT_CRASH_IGNORED_TYPES};break}return{...b}},setCrashModuleEnabled=e=>{_=e},getCrashModuleEnabled=()=>_,setMaxCrashLogsLimit=e=>{C=Math.max(10,e),p.length>C&&(p=p.slice(0,C))},getMaxCrashLogsLimit=()=>C,pruneCrashRecords=e=>{const r=e!==void 0?Math.max(0,e):Math.floor(p.length/2),n=p.length-r;return n>0&&(p=p.slice(0,r)),g.length>20&&(g=g.slice(0,20)),Math.max(0,n)},addCrashBreadcrumb=(e,r,n)=>{if(_)try{const o={type:e,message:r,timestamp:Date.now(),data:n};g.unshift(o),g.length>F&&(g=g.slice(0,F))}catch{}},recordNavigationBreadcrumb=(e,r)=>{addCrashBreadcrumb("navigation",s("crash.breadcrumbNavigation",{from:e||"/",to:r||"/"}),{from:e,to:r})},recordNetworkBreadcrumb=(e,r,n,o)=>{const t=n!=null?` [${n}]`:"",a=o!=null?` (${Math.round(o)}ms)`:"";addCrashBreadcrumb("network",`${r.toUpperCase()} ${e}${t}${a}`,{url:e,method:r,status:n,duration:o})},recordReduxBreadcrumb=(e,r)=>{addCrashBreadcrumb("redux",s("crash.breadcrumbAction",{actionType:e}),{type:e,payloadSummary:typeof r=="object"&&r!==null?Object.keys(r):typeof r})},recordUserActionBreadcrumb=(e,r)=>{addCrashBreadcrumb("user",e,r)},clearCrashBreadcrumbs=()=>{g=[]},getCrashBreadcrumbs=()=>[...g],parseCrashStackTrace=e=>{if(!e||typeof e!="string")return[];const r=e.split(`
|
|
2
|
+
`),n=[];for(const o of r){const t=o.trim();if(!t||t.includes("crashHandler.ts")||t.includes("handleInterceptedCrash")||t.includes("addLogFromCrash")||t.includes("setupGlobalCrashHandler"))continue;const a=t.match(/^([^@]+)@(.*):(\d+):(\d+)$/);if(a){const[,c,i,h,$]=a,y=i.split("?")[0].split("/").pop()||i,S=!i.includes("node_modules")&&!i.includes("react-native")&&!i.includes("react-dom")&&!i.includes("hermes")&&!i.includes("internal");n.push({method:c.trim(),file:y,lineNumber:parseInt(h,10),column:parseInt($,10),raw:t,isAppCode:S});continue}const u=t.match(/^at\s+(.+)\s+\((.+):(\d+):(\d+)\)$/);if(u){const[,c,i,h,$]=u,y=i.split("?")[0].split("/").pop()||i,S=!i.includes("node_modules")&&!i.includes("react-native")&&!i.includes("react-dom")&&!i.includes("internal");n.push({method:c.trim(),file:y,lineNumber:parseInt(h,10),column:parseInt($,10),raw:t,isAppCode:S});continue}const d=t.match(/^at\s+(.+):(\d+):(\d+)$/);if(d){const[,c,i,h]=d,$=c.split("?")[0].split("/").pop()||c,y=!c.includes("node_modules")&&!c.includes("react-native");n.push({method:"<anonymous>",file:$,lineNumber:parseInt(i,10),column:parseInt(h,10),raw:t,isAppCode:y});continue}const m=t.match(/^at\s+([a-zA-Z0-9_$.]+)\(([a-zA-Z0-9_$]+\.java):(\d+)\)$/);if(m){const[,c,i,h]=m,$=!c.startsWith("com.facebook.react")&&!c.startsWith("android.");n.push({method:c,file:i,lineNumber:parseInt(h,10),column:0,raw:t,isAppCode:$});continue}const l=t.match(/^\d+\s+([^\s]+)\s+(0x[0-9a-fA-F]+)\s+(.+)$/);if(l){const[,c,,i]=l,h=!c.startsWith("lib")&&!c.startsWith("Core")&&!c.startsWith("React");n.push({method:i,file:c,lineNumber:0,column:0,raw:t,isAppCode:h});continue}n.push({method:t.startsWith("at ")?t.slice(3):t,file:"runtime",lineNumber:0,column:0,raw:t,isAppCode:!1})}return n};const q=()=>{try{const e=globalThis.performance;if(e&&e.memory)return{usedJSHeapSize:Math.round(e.memory.usedJSHeapSize/(1024*1024)),totalJSHeapSize:Math.round(e.memory.totalJSHeapSize/(1024*1024))}}catch{}},K=()=>{try{const e=z.get("window");return`${Math.round(e.width)}x${Math.round(e.height)} (${e.scale}x)`}catch{return s("crash.unknown")}};export const computeCrashFingerprint=e=>{const r=e.type||"js",n=e.name||"Error",o=e.parsedStack&&e.parsedStack.length>0?e.parsedStack[0]:null,t=o?`${o.file}:${o.lineNumber}`:"unknown";return`${r}_${n}_${t}`},getCrashRecords=()=>[...p],clearCrashRecords=()=>{p=[],emitCrashEvent({error:null,message:"__CLEARED__",timestamp:Date.now()})},subscribeCrashEvents=e=>(k.push(e),()=>{k=k.filter(r=>r!==e)}),emitCrashEvent=e=>{if(e.message!=="__CLEARED__"){const r=Date.now();if(r-N<250)return;N=r}k.forEach(r=>{try{r(e)}catch{}})},handleInterceptedCrash=(e,r,n=!1,o,t)=>{try{const a=e instanceof Error||typeof e=="object"&&e!==null?e:new Error(String(e||s("crash.runtimeException"))),u=a.message||(typeof e=="string"?e:s("crash.runtimeException"));let d="";typeof r=="string"?d=r:Array.isArray(r)?d=r.map(E=>`at ${E.methodName||"<anonymous>"} (${E.file||"unknown"}:${E.lineNumber||0}:${E.column||0})`).join(`
|
|
3
|
+
`):d=a.stack||new Error().stack||"";let m=o||f.Js;const l=u.toLowerCase();if(o||(l.includes("native")||l.includes("sigsegv")||l.includes("nsrange")||l.includes("nullpointerexception")||l.includes("fatal signal")?m=f.Native:l.includes("promise")||l.includes("unhandled rejection")||l.includes("unhandledrejection")?m=f.Promise:l.includes("render")||l.includes("errorboundary")||t?m=f.Render:m=f.Js),!!b[m])return{id:`crash_ignored_${Date.now()}`,isFatal:n,type:m,message:u,timestamp:Date.now(),dateStr:new Date().toLocaleDateString(),timeStr:new Date().toLocaleTimeString()};const i=new Date,h=i.toLocaleDateString(),$=i.toLocaleTimeString(),y=parseCrashStackTrace(d),S=`${m}_${u}_${d.slice(0,80)}`,R=Date.now();if(B&&S===L&&R-N<500)return p.length>0&&(p[0].duplicateCount=(p[0].duplicateCount||1)+1),p[0];L=S,N=R;const j=G(a,`[${n?s("crash.logFatalCrash"):s("crash.logUnhandledError")}] ${u}`,d,n),A=typeof globalThis.HermesInternal<"u",H=typeof globalThis.nativeFabricUIManager<"u",I={id:`crash_${Date.now()}_${Math.random().toString(36).substr(2,6)}`,error:a,isFatal:n,type:m,message:u,name:a.name||(n?s("crash.errorNameFatal"):s("crash.errorNameUnhandled")),stack:d,parsedStack:y,componentStack:t||void 0,timestamp:Date.now(),dateStr:h,timeStr:$,deviceInfo:{platform:x.OS,osVersion:String(x.Version),rnVersion:x.constants?.reactNativeVersion?`${x.constants.reactNativeVersion.major}.${x.constants.reactNativeVersion.minor}.${x.constants.reactNativeVersion.patch}`:s("crash.unknown"),isHermes:A,isFabric:H,appState:J.currentState||"active"},memoryInfo:q(),breadcrumbs:[...g],logId:j?.id};p.unshift(I),p.length>C&&(p=p.slice(0,C));let v=!1;w==="all_errors"?v=!0:w==="fatal_only"?v=n||m===f.Native:w==="silent_tab_only"&&(v=!1),emitCrashEvent({error:a,isFatal:n,message:`[${n?s("crash.logFatalCrash"):s("crash.logUnhandledError")}] ${u}`,stack:d,timestamp:Date.now(),logId:j?.id,crashRecord:I,shouldShowModal:v});try{W(),Y(!0)}catch{}return I}catch{return{id:`crash_${Date.now()}`,isFatal:!0,type:f.Js,message:String(e||s("crash.unknownException")),timestamp:Date.now(),dateStr:new Date().toLocaleDateString(),timeStr:new Date().toLocaleTimeString()}}},recordCustomCrash=(e,r)=>handleInterceptedCrash(e,typeof e=="object"?e.stack:void 0,r?.isFatal??!1,r?.type||f.Custom,r?.componentStack),triggerGlobalCrashScreen=e=>{emitCrashEvent({error:e.error||new Error(e.message),isFatal:!0,message:e.message,stack:e.stack,timestamp:e.timestamp||Date.now(),logId:e.logId,crashRecord:e})},simulateTestCrash=(e=f.Js,r,n,o=!0)=>{const t=new Error(r||X(e));return handleInterceptedCrash(e===f.Native?t.message:t,n||t.stack,o,e,e===f.Render?Q():void 0)};const X=e=>{switch(e){case"native":return s("crash.simNativeMessage");case"promise":return s("crash.simPromiseMessage");case"render":return s("crash.simRenderMessage");default:return s("crash.simJsMessage")}},Q=()=>{try{const e=new Error;if(e.stack)return e.stack.split(`
|
|
4
4
|
`).slice(1,6).map(r=>` ${r.trim()}`).join(`
|
|
5
|
-
`)}catch{}};export const exportCrashReport=(e,r="text")=>{if(r==="json")return JSON.stringify(e,null,2);const n=Math.round((e.timestamp-
|
|
6
|
-
`)}const o=[];return o.push("===================================================="),o.push(` ${s("crash.reportTitle")} `),o.push("===================================================="),o.push(`${s("crash.reportErrorName")} ${e.name||"Error"}`),o.push(`${s("crash.reportMessage")} ${e.message}`),o.push(`${s("crash.reportType")} ${e.type.toUpperCase()}`),o.push(`${s("crash.reportFatal")} ${e.isFatal?s("crash.reportFatalYes"):s("crash.reportFatalNo")}`),o.push(`${s("crash.reportTimestamp")} ${e.dateStr} ${e.timeStr} (${e.timestamp})`),o.push(`${s("crash.reportUptime")} ${s("crash.reportUptimeValue",{seconds:n})}`),o.push(`${s("crash.reportPlatform")} ${e.deviceInfo?.platform?.toUpperCase()} (v${e.deviceInfo?.osVersion})`),o.push(`${s("crash.reportReactNative")} ${e.deviceInfo?.rnVersion||"N/A"}`),o.push(`${s("crash.reportHermes")} ${e.deviceInfo?.isHermes?s("crash.reportEnabled"):s("crash.reportDisabled")}`),o.push(`${s("crash.reportArchitecture")} ${e.deviceInfo?.isFabric?s("crash.reportFabricNew"):s("crash.reportPaperLegacy")}`),o.push(`${s("crash.reportScreenSize")} ${
|
|
7
|
-
`)},setupGlobalCrashHandler=()=>{if(!
|
|
5
|
+
`)}catch{}};export const exportCrashReport=(e,r="text")=>{if(r==="json")return JSON.stringify(e,null,2);const n=Math.round((e.timestamp-Z)/1e3);if(r==="markdown"){const t=[];return t.push(`## ${s("crash.mdReportTitle",{name:e.name||"Error"})}`),t.push(`> **${e.message}**`),t.push(""),t.push(`- **${s("crash.reportType")}** \`${e.type.toUpperCase()}\``),t.push(`- **${s("crash.reportFatal")}** \`${e.isFatal?s("crash.mdSeverityFatal"):s("crash.mdSeverityHandled")}\``),t.push(`- **${s("crash.reportTimestamp")}** ${e.dateStr} ${e.timeStr}`),t.push(`- **${s("crash.reportUptime")}** ${n}s`),t.push(`- **${s("crash.reportPlatform")}** ${e.deviceInfo?.platform?.toUpperCase()} (v${e.deviceInfo?.osVersion})`),t.push(`- **${s("crash.reportReactNative")}** v${e.deviceInfo?.rnVersion||"N/A"}`),t.push(`- **${s("crash.jsEngine")}** ${e.deviceInfo?.isHermes?s("crash.hermesEngine"):s("crash.jsc")}`),t.push(`- **${s("crash.reportArchitecture")}** ${e.deviceInfo?.isFabric?s("crash.reportFabricNew"):s("crash.reportPaperLegacy")}`),e.memoryInfo&&t.push(`- **${s("crash.reportJsMemory")}** ${e.memoryInfo.usedJSHeapSize} MB / ${e.memoryInfo.totalJSHeapSize} MB`),t.push(""),t.push(`### ${s("crash.mdStackTrace")}`),t.push("```"),t.push(e.stack||s("crash.reportNoStackTrace")),t.push("```"),e.componentStack&&(t.push(""),t.push(`### ${s("crash.mdComponentHierarchy")}`),t.push("```"),t.push(e.componentStack),t.push("```")),e.breadcrumbs&&e.breadcrumbs.length>0&&(t.push(""),t.push(`### ${s("crash.mdRecentBreadcrumbs")}`),e.breadcrumbs.forEach(a=>{const u=new Date(a.timestamp).toLocaleTimeString();t.push(`- \`[${u}]\` **[${a.type.toUpperCase()}]** ${a.message}`)})),t.join(`
|
|
6
|
+
`)}const o=[];return o.push("===================================================="),o.push(` ${s("crash.reportTitle")} `),o.push("===================================================="),o.push(`${s("crash.reportErrorName")} ${e.name||"Error"}`),o.push(`${s("crash.reportMessage")} ${e.message}`),o.push(`${s("crash.reportType")} ${e.type.toUpperCase()}`),o.push(`${s("crash.reportFatal")} ${e.isFatal?s("crash.reportFatalYes"):s("crash.reportFatalNo")}`),o.push(`${s("crash.reportTimestamp")} ${e.dateStr} ${e.timeStr} (${e.timestamp})`),o.push(`${s("crash.reportUptime")} ${s("crash.reportUptimeValue",{seconds:n})}`),o.push(`${s("crash.reportPlatform")} ${e.deviceInfo?.platform?.toUpperCase()} (v${e.deviceInfo?.osVersion})`),o.push(`${s("crash.reportReactNative")} ${e.deviceInfo?.rnVersion||"N/A"}`),o.push(`${s("crash.reportHermes")} ${e.deviceInfo?.isHermes?s("crash.reportEnabled"):s("crash.reportDisabled")}`),o.push(`${s("crash.reportArchitecture")} ${e.deviceInfo?.isFabric?s("crash.reportFabricNew"):s("crash.reportPaperLegacy")}`),o.push(`${s("crash.reportScreenSize")} ${K()}`),o.push(`${s("crash.reportAppState")} ${e.deviceInfo?.appState||"active"}`),e.memoryInfo&&o.push(`${s("crash.reportJsMemory")} ${e.memoryInfo.usedJSHeapSize} MB / ${e.memoryInfo.totalJSHeapSize} MB`),o.push("----------------------------------------------------"),o.push(`${s("crash.reportStackTrace")}`),o.push(e.stack||s("crash.reportNoStackTrace")),e.componentStack&&(o.push("----------------------------------------------------"),o.push(`${s("crash.reportComponentHierarchy")}`),o.push(e.componentStack)),e.breadcrumbs&&e.breadcrumbs.length>0&&(o.push("----------------------------------------------------"),o.push(`${s("crash.reportRecentBreadcrumbs")}`),e.breadcrumbs.forEach(t=>{const a=new Date(t.timestamp).toLocaleTimeString();o.push(` [${a}] [${t.type.toUpperCase()}] ${t.message}`)})),o.push("===================================================="),o.join(`
|
|
7
|
+
`)},setupGlobalCrashHandler=()=>{if(!T){T=!0;try{D&&typeof D.ignoreAllLogs=="function"&&D.ignoreAllLogs(!0)}catch{}try{const e=require("react-native/Libraries/LogBox/Data/LogBoxData");e&&typeof e.setDisabled=="function"&&e.setDisabled(!0)}catch{}try{const e=M?.NetworkInspectorModule;e&&(typeof e.enableNativeCrashProtection=="function"&&e.enableNativeCrashProtection(),new P(e).addListener("onNativeCrash",n=>{const t=`[${(n?.platform||x.OS).toUpperCase()} ${s("crash.nativeCrashTitle")}] ${n?.message||s("crash.nativeUncaughtException")}`,a=n?.stack||"";handleInterceptedCrash(t,a,!0,"native")}))}catch{}try{const e=U||globalThis.__turboModuleProxy,r=M?.ExceptionsManager||(e?.get?e.get("ExceptionsManager"):null);if(r){r.reportFatalException=(o,t,a)=>{handleInterceptedCrash(o,t,!0,"native");try{typeof r.dismissRedbox=="function"&&r.dismissRedbox()}catch{}},r.reportSoftException=(o,t,a)=>{handleInterceptedCrash(o,t,!1,"js");try{typeof r.dismissRedbox=="function"&&r.dismissRedbox()}catch{}},r.reportException=o=>{const t=o?.message||o?.title||s("crash.nativeException"),a=o?.stack||o?.rawStack;handleInterceptedCrash(t,a,o?.isFatal??!0,"js");try{typeof r.dismissRedbox=="function"&&r.dismissRedbox()}catch{}},r.updateExceptionMessage=()=>{};try{typeof r.dismissRedbox=="function"&&r.dismissRedbox()}catch{}}const n=M?.RedBox||M?.RCTRedBox||(e?.get?e.get("RedBox")||e.get("RCTRedBox"):null);n&&(typeof n.showErrorMessage=="function"&&(n.showErrorMessage=()=>{}),typeof n.showUserError=="function"&&(n.showUserError=()=>{}),typeof n.dismiss=="function"&&n.dismiss())}catch{}try{const r=globalThis.ErrorUtils;r&&(typeof r.setGlobalHandler=="function"&&r.setGlobalHandler((n,o)=>{handleInterceptedCrash(n,n?.stack,o??!1,"js")}),typeof r.reportFatalError=="function"&&(r.reportFatalError=n=>{handleInterceptedCrash(n,n?.stack,!0,"js")}),typeof r.reportError=="function"&&(r.reportError=n=>{handleInterceptedCrash(n,n?.stack,!1,"js")}))}catch{}try{const e=globalThis,r=n=>{try{const o=n?.reason||n?.detail?.reason||n,t=o?.stack||(n?.stack??new Error().stack);handleInterceptedCrash(o,t,!1,"promise")}catch{}};typeof e.addEventListener=="function"&&e.addEventListener("unhandledrejection",r),typeof e.onunhandledrejection<"u"&&(e.onunhandledrejection=r)}catch{}}};
|
|
@@ -1,4 +1,12 @@
|
|
|
1
1
|
import { ActiveTab } from '../types';
|
|
2
|
+
export interface InspectorRemoteConfigResult {
|
|
3
|
+
modules?: Partial<Record<ActiveTab, boolean>>;
|
|
4
|
+
sponsorPublisherId?: string;
|
|
5
|
+
sponsorEndpoint?: string;
|
|
6
|
+
captureWidgetEnabled?: boolean;
|
|
7
|
+
enabled?: boolean;
|
|
8
|
+
}
|
|
2
9
|
export declare function getFirebaseRemoteConfig(customInstance?: any): any;
|
|
3
10
|
export declare function isFirebaseRemoteConfigAvailable(customInstance?: any): boolean;
|
|
11
|
+
export declare function fetchRemoteConfigSettings(customInstance?: any, fetchTimeoutMs?: number): Promise<InspectorRemoteConfigResult | null>;
|
|
4
12
|
export declare function fetchRemoteConfigModuleStatus(customInstance?: any, fetchTimeoutMs?: number): Promise<Partial<Record<ActiveTab, boolean>> | null>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
const l=["apis","logs","analytics","redux","storage","device","crash","debugging"];let u=null;export function getFirebaseRemoteConfig(
|
|
1
|
+
const l=["apis","logs","analytics","redux","storage","device","crash","debugging","media","socket"];let u=null;export function getFirebaseRemoteConfig(e){if(e&&typeof e=="object")return u=e,e;if(u)return u;try{const t=require("@react-native-firebase/remote-config"),n=typeof t.default=="function"?t.default():typeof t=="function"?t():t;return u=n,n}catch{return null}}export function isFirebaseRemoteConfigAvailable(e){return!!getFirebaseRemoteConfig(e)}function p(e){if(e!=null){if(typeof e=="boolean")return e;if(typeof e=="number")return e!==0;if(typeof e=="string"){const t=e.trim().toLowerCase();if(t==="true"||t==="1"||t==="enabled"||t==="on")return!0;if(t==="false"||t==="0"||t==="disabled"||t==="off")return!1;try{return JSON.parse(e)}catch{return}}if(typeof e.asBoolean=="function")return e.asBoolean();if(typeof e.asString=="function"){const t=e.asString(),n=t.trim().toLowerCase();if(n==="true"||n==="1"||n==="enabled"||n==="on")return!0;if(n==="false"||n==="0"||n==="disabled"||n==="off")return!1;try{return JSON.parse(t)}catch{return}}}}function _(e){if(e!=null){if(typeof e=="string"&&e.trim().length>0)return e.trim();if(typeof e.asString=="function"){const t=e.asString();if(typeof t=="string"&&t.trim().length>0)return t.trim()}}}export async function fetchRemoteConfigSettings(e,t=8e3){const n=getFirebaseRemoteConfig(e);if(!n)return null;try{const y=(async()=>{typeof n.fetchAndActivate=="function"?await n.fetchAndActivate():(typeof n.fetch=="function"&&await n.fetch(),typeof n.activate=="function"&&await n.activate())})(),b=new Promise((o,r)=>setTimeout(()=>r(new Error("Remote Config fetch timeout")),t));await Promise.race([y,b]).catch(()=>{});const s=o=>{if(typeof n.getValue=="function")try{return n.getValue(o)}catch{return}return n[o]},i={},c={},g=["inspector_modules","inapp_inspector_modules","react_native_inapp_inspector_modules"];for(const o of g){const r=s(o),f=p(r);if(f&&typeof f=="object")for(const a of l)typeof f[a]=="boolean"&&(c[a]=f[a])}for(const o of l){const r=[`inspector_module_${o}`,`inapp_inspector_${o}`,`inspector_${o}`,`inapp_inspector_module_${o}`,`rn_inspector_${o}`];for(const f of r){const a=s(f),d=p(a);if(typeof d=="boolean"){c[o]=d;break}}}Object.keys(c).length>0&&(c.apis===void 0&&(c.apis=!0),i.modules=c);const m=["inspector_sponsor_publisher_id","inapp_inspector_sponsor_publisher_id","inspector_publisher_id","ethicalads_publisher_id"];for(const o of m){const r=_(s(o));if(r){i.sponsorPublisherId=r;break}}const h=["inspector_sponsor_endpoint","inapp_inspector_sponsor_endpoint","inspector_custom_sponsor_endpoint"];for(const o of h){const r=_(s(o));if(r){i.sponsorEndpoint=r;break}}const w=["inspector_capture_widget_enabled","inapp_inspector_capture_widget","inspector_floating_capture_enabled"];for(const o of w){const r=p(s(o));if(typeof r=="boolean"){i.captureWidgetEnabled=r;break}}const K=["inspector_enabled","inapp_inspector_enabled"];for(const o of K){const r=p(s(o));if(typeof r=="boolean"){i.enabled=r;break}}return Object.keys(i).length>0?i:null}catch{return null}}export async function fetchRemoteConfigModuleStatus(e,t=8e3){return(await fetchRemoteConfigSettings(e,t))?.modules||null}
|
|
@@ -13,3 +13,18 @@ export declare function shareReduxReport(action: ReduxHistoryEntry): Promise<voi
|
|
|
13
13
|
export declare function shareLogReport(log: ConsoleLog): Promise<void>;
|
|
14
14
|
export declare function formatSocketReport(record: SocketConnectionRecord): string;
|
|
15
15
|
export declare function shareSocketReport(record: SocketConnectionRecord): Promise<void>;
|
|
16
|
+
export type ConsoleLogExportFormat = 'txt' | 'log' | 'json' | 'text' | 'markdown' | 'csv';
|
|
17
|
+
export interface ConsoleLogExportOptions {
|
|
18
|
+
includeStackTrace?: boolean;
|
|
19
|
+
includeArguments?: boolean;
|
|
20
|
+
includeCaller?: boolean;
|
|
21
|
+
includeTimestamps?: boolean;
|
|
22
|
+
includeAppInfo?: boolean;
|
|
23
|
+
includeDuplicates?: boolean;
|
|
24
|
+
ignorePattern?: string;
|
|
25
|
+
}
|
|
26
|
+
export declare const DEFAULT_CONSOLE_EXPORT_OPTIONS: ConsoleLogExportOptions;
|
|
27
|
+
export declare function generateConsoleLogsFilename(format?: ConsoleLogExportFormat): string;
|
|
28
|
+
export declare function formatConsoleLogsExport(logs: ConsoleLog[], format?: ConsoleLogExportFormat, options?: ConsoleLogExportOptions): string;
|
|
29
|
+
export declare function estimateConsoleLogsExportSize(logs: ConsoleLog[], format?: ConsoleLogExportFormat, options?: ConsoleLogExportOptions): number;
|
|
30
|
+
export declare function shareConsoleLogs(logs: ConsoleLog[], format?: ConsoleLogExportFormat, options?: ConsoleLogExportOptions, customTitle?: string): Promise<void>;
|
|
@@ -1,8 +1,15 @@
|
|
|
1
|
-
import{Alert as
|
|
2
|
-
`)}export function formatPushReport(e){const n=
|
|
3
|
-
`)}export function formatCrashReport(e){const n=`${e.dateStr||""} ${e.timeStr||""}`.trim()||
|
|
4
|
-
`)}export function formatAnalyticsReport(e){const n=
|
|
5
|
-
`)}export function formatReduxReport(e){const n=typeof e.timestamp=="number"?
|
|
6
|
-
`)}export function formatLogReport(e){const n=
|
|
7
|
-
`)}async function
|
|
8
|
-
`)}export async function shareSocketReport(e){const n=formatSocketReport(e),t=`Socket: ${e.client?.toUpperCase()||"WS"} ${e.url?.substring(0,35)||""}`;await
|
|
1
|
+
import{Alert as b,Share as x}from"react-native";import{formatDateTime as c,getCurlCommand as P}from"./index";function r(e){if(e===void 0)return"undefined";if(e===null)return"null";if(typeof e=="string")return e;try{return JSON.stringify(e,null,2)}catch{return String(e)}}export function formatApiReport(e){const n=(e.method||"GET").toUpperCase(),t=e.status===0?"Failed / Network Error":e.status!=null?`${e.status} ${e.status===200?"OK":""}`.trim():"Pending",i=e.duration!=null?`${e.duration}ms`:"N/A",o=c(e.startTime||Date.now()),s=P(e),a=["\u{1F680} API INSPECTION REPORT","\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501",`\u{1F4CC} Method: ${n}`,`\u{1F4CA} Status: ${t}`,`\u23F1\uFE0F Duration: ${i}`,`\u{1F552} Time: ${o}`];return e.client&&a.push(`\u{1F50C} Client: ${e.client.toUpperCase()}`),a.push(`\u{1F310} URL: ${e.url||"N/A"}`),a.push(""),e.requestHeaders&&Object.keys(e.requestHeaders).length>0&&(a.push("\u{1F4CB} Request Headers:"),a.push(r(e.requestHeaders)),a.push("")),e.request!=null&&e.request!==""&&(a.push("\u{1F4DD} Request Body:"),a.push(r(e.request)),a.push("")),e.responseHeaders&&Object.keys(e.responseHeaders).length>0&&(a.push("\u{1F4D1} Response Headers:"),a.push(r(e.responseHeaders)),a.push("")),e.response!=null&&e.response!==""&&(a.push("\u{1F4E5} Response Data:"),a.push(r(e.response)),a.push("")),s&&(a.push("\u{1F4BB} cURL Command:"),a.push(s),a.push("")),a.push("\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501"),a.push("Generated by React Native InApp Inspector"),a.join(`
|
|
2
|
+
`)}export function formatPushReport(e){const n=c(e.timestamp||Date.now()),t=(e.source||"push").toUpperCase(),i=(e.appState||"unknown").toUpperCase(),o=(e.action||"received").toUpperCase(),s=["\u{1F514} PUSH NOTIFICATION REPORT","\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501",`\u{1F4CC} Title: ${e.title||"(No Title)"}`,`\u{1F4DD} Body: ${e.body||"(No Body)"}`,`\u{1F3E2} Source: ${t}${e.domain?` (${e.domain})`:""}`,`\u{1F194} Message ID: ${e.id||"N/A"}`,`\u{1F4F1} App State: ${i}`,`\u{1F3AF} Action: ${o}`,`\u{1F552} Time: ${n}`];return e.subtitle&&s.push(`\u{1F4D1} Subtitle: ${e.subtitle}`),e.channelId&&s.push(`\u{1F3F7}\uFE0F Channel: ${e.channelId}`),e.priority&&s.push(`\u26A1 Priority: ${e.priority}`),e.badge!=null&&s.push(`\u{1F522} Badge: ${e.badge}`),e.sound&&s.push(`\u{1F50A} Sound: ${e.sound}`),e.imageUrl&&s.push(`\u{1F5BC}\uFE0F Image: ${e.imageUrl}`),s.push(""),e.data&&Object.keys(e.data).length>0&&(s.push("\u{1F4E6} Custom Data Payload:"),s.push(r(e.data)),s.push("")),e.customDomainAttributes&&Object.keys(e.customDomainAttributes).length>0&&(s.push("\u{1F3E2} Domain Attributes:"),s.push(r(e.customDomainAttributes)),s.push("")),e.rawPayload!=null&&(s.push("\u2699\uFE0F Raw Payload:"),s.push(r(e.rawPayload)),s.push("")),s.push("\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501"),s.push("Generated by React Native InApp Inspector"),s.join(`
|
|
3
|
+
`)}export function formatCrashReport(e){const n=`${e.dateStr||""} ${e.timeStr||""}`.trim()||c(e.timestamp),t=["\u{1F4A5} CRASH REPORT","\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501",`\u26A0\uFE0F Error: ${e.name||"Error"}: ${e.message||"Unknown error"}`,`\u{1F6A8} Fatal: ${e.isFatal?"YES (Fatal)":"NO (Caught)"}`,`\u{1F3F7}\uFE0F Type: ${(e.type||"js").toUpperCase()}`,`\u{1F552} Time: ${n}`];return e.deviceInfo&&t.push(`\u{1F4F1} Platform: ${e.deviceInfo.platform||"N/A"} (OS: ${e.deviceInfo.osVersion||"N/A"}, RN: ${e.deviceInfo.rnVersion||"N/A"})`),e.memoryInfo?.usedJSHeapSize&&t.push(`\u{1F4BE} Used Heap: ${Math.round(e.memoryInfo.usedJSHeapSize/(1024*1024))} MB`),t.push(""),e.stack&&(t.push("\u{1F4DC} Stack Trace:"),t.push(e.stack),t.push("")),e.breadcrumbs&&e.breadcrumbs.length>0&&(t.push(`\u{1F43E} Breadcrumbs (${e.breadcrumbs.length}):`),e.breadcrumbs.slice(-10).forEach(i=>{t.push(` \u2022 [${i.type}] ${i.message} (${c(i.timestamp)})`)}),t.push("")),t.push("\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501"),t.push("Generated by React Native InApp Inspector"),t.join(`
|
|
4
|
+
`)}export function formatAnalyticsReport(e){const n=c(e.timestamp),t=["\u{1F4CA} ANALYTICS EVENT REPORT","\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501",`\u{1F4CC} Event Name: ${e.name||"Unknown"}`,`\u{1F3E2} Source: ${(e.source||"manual").toUpperCase()}`,`\u{1F552} Timestamp: ${n}`];return e.screenName&&t.push(`\u{1F4F1} Screen Name: ${e.screenName}`),e.userId&&t.push(`\u{1F464} User ID: ${e.userId}`),e.trackingId&&t.push(`\u{1F194} Tracking ID: ${e.trackingId}`),t.push(""),e.params&&Object.keys(e.params).length>0&&(t.push("\u{1F4E6} Event Parameters:"),t.push(r(e.params)),t.push("")),e.userProperties&&Object.keys(e.userProperties).length>0&&(t.push("\u{1F464} User Properties:"),t.push(r(e.userProperties)),t.push("")),t.push("\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501"),t.push("Generated by React Native InApp Inspector"),t.join(`
|
|
5
|
+
`)}export function formatReduxReport(e){const n=typeof e.timestamp=="number"?c(e.timestamp):e.timestamp,t=["\u{1F504} REDUX ACTION REPORT","\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501",`\u{1F4CC} Action Type: ${e.type||"UNKNOWN"}`,`\u{1F552} Timestamp: ${n}`];return e.caller&&t.push(`\u{1F4CD} Caller: ${e.caller}`),e.originType&&t.push(`\u2699\uFE0F Origin: ${e.originType}`),e.affectedSlices&&e.affectedSlices.length>0&&t.push(`\u{1F370} Slices: ${e.affectedSlices.join(", ")}`),t.push(""),t.push("\u{1F4E6} Action Payload:"),t.push(r(e.payload)),t.push(""),e.prevState!==void 0&&(t.push("\u23EE\uFE0F Previous State:"),t.push(r(e.prevState)),t.push("")),e.nextState!==void 0&&(t.push("\u23ED\uFE0F Next State:"),t.push(r(e.nextState)),t.push("")),t.push("\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501"),t.push("Generated by React Native InApp Inspector"),t.join(`
|
|
6
|
+
`)}export function formatLogReport(e){const n=c(e.timestamp),t=["\u{1F4DC} CONSOLE LOG REPORT","\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501",`\u{1F4CC} Level: ${(e.type||"info").toUpperCase()}`,`\u{1F552} Timestamp: ${n}`,`\u{1F4AC} Message: ${e.message||""}`];return e.caller&&t.push(`\u{1F4CD} Caller: ${e.caller}`),t.push(""),e.rawArgs&&e.rawArgs.length>0&&(t.push("\u{1F4E6} Arguments:"),t.push(r(e.rawArgs)),t.push("")),(e.stack||e.errorStack)&&(t.push("\u{1F4DC} Stack Trace:"),t.push(e.stack||e.errorStack||""),t.push("")),t.push("\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501"),t.push("Generated by React Native InApp Inspector"),t.join(`
|
|
7
|
+
`)}async function m(e,n){try{await x.share({title:e,message:n},{dialogTitle:e})}catch(t){t?.message!=="User did not share"&&b.alert("Share Error",t?.message||"Failed to open share sheet")}}export async function shareApiReport(e){const n=formatApiReport(e),t=`API: ${e.method||"GET"} ${e.url?.substring(0,40)||""}`;await m(t,n)}export async function sharePushReport(e){const n=formatPushReport(e),t=`Push: ${e.title||e.id||"Notification"}`;await m(t,n)}export async function shareCrashReport(e){const n=formatCrashReport(e),t=`Crash: ${e.name||e.message||"Error"}`;await m(t,n)}export async function shareAnalyticsReport(e){const n=formatAnalyticsReport(e),t=`Analytics: ${e.name||"Event"}`;await m(t,n)}export async function shareReduxReport(e){const n=formatReduxReport(e),t=`Redux: ${e.type||"Action"}`;await m(t,n)}export async function shareLogReport(e){const n=formatLogReport(e),t=`Log: ${(e.type||"info").toUpperCase()} - ${e.message?.substring(0,30)||""}`;await m(t,n)}export function formatSocketReport(e){const n=(e.client||"websocket").toUpperCase(),t=(e.status||"open").toUpperCase(),i=e.duration!=null?`${e.duration}ms`:"Active / Open",o=c(e.startTime||Date.now()),s=["\u{1F50C} WEBSOCKET / SOCKET.IO REPORT","\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501",`\u{1F4E1} Client: ${n}`,`\u{1F310} URL: ${e.url||"N/A"}`,`\u26A1 Status: ${t}`,`\u23F1\uFE0F Connected: ${o}`,`\u23F3 Duration: ${i}`,`\u{1F4E6} Total Frames: ${e.frames?.length||0} (${e.sentCount||0} sent, ${e.receivedCount||0} recvd)`,`\u{1F4CA} Data Size: ${(e.totalBytesSent||0)+(e.totalBytesReceived||0)} bytes`];return e.protocols&&s.push(`\u{1F4DC} Protocols: ${Array.isArray(e.protocols)?e.protocols.join(", "):e.protocols}`),e.closeCode!=null&&s.push(`\u{1F6D1} Close Code: ${e.closeCode} (${e.closeReason||"N/A"})`),e.error&&s.push(`\u274C Error: ${e.error}`),e.caller&&s.push(`\u{1F4CD} Caller: ${e.caller}`),e.query&&Object.keys(e.query).length>0&&(s.push(""),s.push("\u{1F50D} Query Parameters:"),s.push(r(e.query))),e.frames&&e.frames.length>0&&(s.push(""),s.push("\u{1F4AC} Recent Message Frames:"),e.frames.slice(-10).forEach((a,$)=>{const g=a.direction==="send"?"\u2B06\uFE0F SEND":"\u2B07\uFE0F RECV",f=a.eventName?` [${a.eventName}]`:"";s.push(`--- Frame #${$+1} (${g}${f}, ${a.type}, ${a.size||0}B) ---`),s.push(r(a.data))})),s.push(""),s.push("\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501"),s.push("Generated by React Native InApp Inspector"),s.join(`
|
|
8
|
+
`)}export async function shareSocketReport(e){const n=formatSocketReport(e),t=`Socket: ${e.client?.toUpperCase()||"WS"} ${e.url?.substring(0,35)||""}`;await m(t,n)}export const DEFAULT_CONSOLE_EXPORT_OPTIONS={includeStackTrace:!1,includeArguments:!1,includeCaller:!1,includeTimestamps:!1,includeAppInfo:!1,includeDuplicates:!1,ignorePattern:""};export function generateConsoleLogsFilename(e="txt"){const n=new Date,t=String(n.getDate()).padStart(2,"0"),i=String(n.getMonth()+1).padStart(2,"0"),o=String(n.getFullYear()).slice(-2),s=Math.random().toString(36).substring(2,8).padEnd(6,"0");return`log_${t}${i}${o}_${s}.${e==="log"?"log":"txt"}`}export function formatConsoleLogsExport(e,n="txt",t=DEFAULT_CONSOLE_EXPORT_OPTIONS){if(!e||e.length===0)return"No console logs to export.";const{includeStackTrace:i=!1,includeArguments:o=!1,includeCaller:s=!1,includeTimestamps:a=!1,includeAppInfo:$=!1,includeDuplicates:g=!1,ignorePattern:f=""}=t;let C=e;if(f&&f.trim().length>0)try{const p=new RegExp(f.trim(),"i");C=e.filter(l=>{const S=l.message||"",d=l.rawArgs?r(l.rawArgs):"",y=l.caller||"";return!p.test(S)&&!p.test(d)&&!p.test(y)})}catch{}if(C.length===0)return"No console logs to export (all filtered out).";const R=new Date().toLocaleString(),h="********************************************************************************",A=[];$&&A.push(`/${h}`,` * \u{1F4DC} CONSOLE LOGS EXPORT (${n.toUpperCase()})`,` * \u{1F552} Exported At: ${R}`,` * \u{1F4CA} Total Logs: ${e.length}`," * \u2699\uFE0F Generator: React Native InApp Inspector",` ${h}/`,"");const N=e.map((p,l)=>{const S=l+1,d=c(p.timestamp),y=(p.type||"info").toUpperCase(),O=g&&p.duplicateCount&&p.duplicateCount>1?` [DUPLICATES: \xD7${p.duplicateCount}]`:"",u=[`/${h}`,` * \u{1F4CC} LOG #${S} Starts [${y}]${a?` - ${d}`:""}${O}`,` ${h}/`];if(s&&p.caller&&u.push(`\u{1F4CD} Caller: ${p.caller}`),a&&u.push(`\u{1F552} Time: ${d}`),u.push(`\u{1F3F7}\uFE0F Level: ${y}`),p.sourceMethod&&p.sourceMethod!==p.type&&u.push(`\u2699\uFE0F Method: console.${p.sourceMethod}()`),u.push(""),u.push("\u{1F4AC} Message:"),u.push(p.message||"(Empty message)"),o&&p.rawArgs&&p.rawArgs.length>0&&(u.push(""),u.push("\u{1F4E6} Arguments / Data:"),u.push(r(p.rawArgs))),i&&(p.stack||p.errorStack)){u.push(""),u.push("\u{1F4DC} Stack Trace & Frames:");const E=(p.stack||p.errorStack||"").split(`
|
|
9
|
+
`).map(I=>` ${I}`).join(`
|
|
10
|
+
`);u.push(E)}return u.push(""),u.push(`/${h}`),u.push(` * \u{1F3C1} LOG #${S} Ends`),u.push(` ${h}/`),u.join(`
|
|
11
|
+
`)}).join(`
|
|
12
|
+
|
|
13
|
+
`),T=$?["",`/${h}`," * \u{1F3C1} END OF CONSOLE LOGS EXPORT",` ${h}/`].join(`
|
|
14
|
+
`):"";return`${A.join(`
|
|
15
|
+
`)}${N}${T}`}export function estimateConsoleLogsExportSize(e,n="txt",t=DEFAULT_CONSOLE_EXPORT_OPTIONS){if(!e||e.length===0)return 0;const i=Math.min(e.length,20),o=e.slice(0,i),a=formatConsoleLogsExport(o,n,t).length/i;return Math.round(a*e.length)}export async function shareConsoleLogs(e,n="txt",t=DEFAULT_CONSOLE_EXPORT_OPTIONS,i){const o=formatConsoleLogsExport(e,n,t),s=generateConsoleLogsFilename(n);await m(i||s,o)}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export interface DeveloperSponsorAd {
|
|
2
|
+
id: string;
|
|
3
|
+
title: string;
|
|
4
|
+
description: string;
|
|
5
|
+
ctaText: string;
|
|
6
|
+
ctaUrl: string;
|
|
7
|
+
badgeText?: string;
|
|
8
|
+
sponsorName?: string;
|
|
9
|
+
logoUrl?: string;
|
|
10
|
+
accentColor?: string;
|
|
11
|
+
impressionUrl?: string;
|
|
12
|
+
clickUrl?: string;
|
|
13
|
+
type?: 'ethicalads' | 'affiliate' | 'custom';
|
|
14
|
+
}
|
|
15
|
+
export declare const DEFAULT_ETHICALADS_PUBLISHER_ID = "";
|
|
16
|
+
export declare function setSponsorPublisherId(publisherId: string): void;
|
|
17
|
+
export declare function setCustomSponsorEndpoint(endpointUrl: string): void;
|
|
18
|
+
export declare function fetchDeveloperSponsor(publisherId?: string, customEndpoint?: string): Promise<DeveloperSponsorAd>;
|
|
19
|
+
export declare function trackSponsorImpression(ad: DeveloperSponsorAd): void;
|
|
20
|
+
export declare function handleSponsorClick(ad: DeveloperSponsorAd): void;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{Linking as h}from"react-native";export const DEFAULT_ETHICALADS_PUBLISHER_ID="";let l=null,p=null;export function setSponsorPublisherId(o){l=o}export function setCustomSponsorEndpoint(o){p=o}const d=[{id:"sentry-dev-partner",sponsorName:"Sentry",badgeText:"FEATURED PARTNER",title:"Code breaks. Fix it faster with Sentry.",description:"Real-time crash tracking, performance monitoring, and session replay for React Native.",ctaText:"Try Sentry Free",ctaUrl:"https://sentry.io/welcome/?utm_source=react-native-inapp-inspector&utm_medium=partner&utm_campaign=dev-tools",accentColor:"#6C5FC7",type:"affiliate"},{id:"requestly-api-mock",sponsorName:"Requestly",badgeText:"DEV SPOTLIGHT",title:"Intercept & Mock APIs directly in Mobile Apps",description:"Modify HTTP headers, redirect API endpoints, and simulate 500 errors on iOS & Android.",ctaText:"Explore Requestly",ctaUrl:"https://requestly.com/?utm_source=react-native-inapp-inspector&utm_medium=devtools&utm_campaign=mobile-inspect",accentColor:"#2563EB",type:"affiliate"},{id:"supabase-cloud-db",sponsorName:"Supabase",badgeText:"DEVELOPER CLOUD",title:"The Open Source Firebase Alternative",description:"Postgres database, Authentication, Instant APIs, Realtime subscriptions, and Edge Functions.",ctaText:"Start Free Project",ctaUrl:"https://supabase.com/?utm_source=react-native-inapp-inspector&utm_medium=partner&utm_campaign=rn-inspect",accentColor:"#3ECF8E",type:"affiliate"},{id:"digitalocean-cloud",sponsorName:"DigitalOcean",badgeText:"$200 FREE CREDIT",title:"Deploy React Native Backend & Nodes in Seconds",description:"Simple, scalable cloud hosting with managed databases, App Platform, and 99.99% uptime.",ctaText:"Claim $200 Credit",ctaUrl:"https://m.do.co/c/react-native-inapp-inspector",accentColor:"#0080FF",type:"affiliate"}];let a=null,i=!1;export async function fetchDeveloperSponsor(o,m){const n=o||l||DEFAULT_ETHICALADS_PUBLISHER_ID,c=m||p;if(c)try{const r=await fetch(c,{headers:{Accept:"application/json"}});if(r.ok){const e=await r.json();if(e&&e.title&&e.ctaUrl)return a={id:e.id||"custom-sponsor",title:e.title,description:e.description||"",ctaText:e.ctaText||"Learn More",ctaUrl:e.ctaUrl,badgeText:e.badgeText||"SPONSORED",sponsorName:e.sponsorName||"Featured Partner",logoUrl:e.logoUrl,accentColor:e.accentColor||"#6366F1",impressionUrl:e.impressionUrl,clickUrl:e.clickUrl,type:"custom"},i=!1,a}}catch{}if(n)try{const r=encodeURIComponent("react-native|mobile|javascript|typescript|ios|android|developer-tools|cloud"),e=`https://server.ethicalads.io/api/v1/decision/?publisher=${encodeURIComponent(n)}&ad_types=image-and-text&format=json&keywords=${r}&placements=app-inspector`,s=await fetch(e,{headers:{Accept:"application/json"}});if(s.ok){const t=await s.json();if(t&&(t.text||t.heading)&&(t.link||t.click_url))return a={id:`ethicalads-${t.id||Date.now()}`,title:t.heading||t.company||"Developer Spotlight",description:t.text||"",ctaText:"Learn More",ctaUrl:t.link||t.click_url,badgeText:"ETHICAL ADS",sponsorName:t.company||"Sponsored Tool",logoUrl:t.image,accentColor:"#10B981",impressionUrl:t.view_url,clickUrl:t.click_url,type:"ethicalads"},i=!1,a}}catch{}const u=Math.floor(Math.random()*d.length);return a=d[u],i=!1,a}export function trackSponsorImpression(o){i||(i=!0,o.impressionUrl&&fetch(o.impressionUrl,{method:"GET"}).catch(()=>{}))}export function handleSponsorClick(o){o.clickUrl&&fetch(o.clickUrl,{method:"GET"}).catch(()=>{}),o.ctaUrl&&h.openURL(o.ctaUrl).catch(()=>{})}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import b from"react";import{Appearance as ae,Dimensions as re,PixelRatio as P,Platform as l,NativeModules as oe}from"react-native";import{LIB_VERSION as R}from"../constants/version";import{loadSettings as y,saveSettings as S}from"./settingsStore";import{isReduxConnected as ie}from"../customHooks/reduxLogger";import{isFirebaseAnalyticsPatched as se}from"../customHooks/analyticsLogger";import{getCrashRecords as ce}from"../customHooks/crashHandler";import{getNetworkLogs as le}from"../customHooks/networkLogger";import{isNativeModuleAvailable as de}from"../native/NativeInspector";import{getAppName as _e,getBundleIdentifier as ue,getAppVersionAndBuild as pe,isLocalDebugEnvironment as ve}from"./index";import{ENC_MID as $,ENC_SEC as j,TELEMETRY_SALT as v}from"../constants/telemetryConfig";const z="react-native-inapp-inspector",me=`${z}::${v}`;function fe(t,o){const i=[];let r=1518500249;for(let a=0;a<o;a++){const e=t.charCodeAt(a%t.length);r=(r*31+e*17+a*13^r>>>7)&4294967295,i.push(r>>>a%24&255)}return i}function H(t){if(!t)return"";const o=[];for(let a=0;a<t.length;a+=2)o.push(parseInt(t.substring(a,a+2),16));const i=fe(me,o.length),r=[];for(let a=0;a<o.length;a++){const e=i[a],d=v.charCodeAt(a%v.length),c=(o[a]^e^d)&255;r.push(String.fromCharCode(c))}return r.join("")}let u=null,p=null;function ge(){if(u!==null&&p!==null)return{measurementId:u,apiSecret:p};if(!$||!j||!v)return u="",p="",{measurementId:"",apiSecret:""};try{u=H($),p=H(j)}catch{u="",p=""}return{measurementId:u,apiSecret:p}}function K(){const{measurementId:t,apiSecret:o}=ge();return!t||!o?"":`https://www.google-analytics.com/mp/collect?measurement_id=${t}&api_secret=${o}`}const he=1440*60*1e3;let m=!0,U=!1;export function setTelemetryEnabled(t){m=t}export function markSearchFilterUsed(){U=!0}async function Z(){try{const t=await y();if(t.telemetryClientId||t.telemetryDeviceId){const e=t.telemetryClientId||t.telemetryDeviceId||"";return t.telemetryDeviceId||await S({...t,telemetryDeviceId:e}),e}const o=Math.floor(1e8+Math.random()*9e8),i=Math.floor(1e9+Math.random()*9e9),r=`${o}.${i}`,a=Date.now();return await S({...t,telemetryClientId:r,telemetryDeviceId:r,deviceFirstSeen:t.deviceFirstSeen||a}),r}catch{return`${Math.floor(1e8+Math.random()*9e8)}.${Math.floor(1e9+Math.random()*9e9)}`}}function be(){try{if(l.OS==="android"){const t=l.constants||{},o=String(t.Model||"").toLowerCase(),i=String(t.Brand||"").toLowerCase(),r=String(t.Fingerprint||"").toLowerCase(),a=String(t.Hardware||"").toLowerCase(),e=String(t.Manufacturer||"").toLowerCase();return o.includes("emulator")||o.includes("sdk")||o.includes("google_sdk")||o.includes("vbox")||i.includes("generic")||r.startsWith("generic")||a.includes("goldfish")||a.includes("ranchu")||e.includes("genymotion")}if(l.OS==="ios"){const t=l.constants||{};return String(t.Model||"").toLowerCase().includes("simulator")||!!t.isSimulator}}catch{return!1}return!1}function ye(){try{const t=typeof Intl<"u"&&Intl.DateTimeFormat?Intl.DateTimeFormat().resolvedOptions():{},o=t.timeZone||"unknown",i=t.locale||"unknown";let r="unknown";if(i&&i!=="unknown"){const a=i.split(/[-_]/);a.length>1&&(r=a[a.length-1].toUpperCase())}return{countryCode:r,locale:i,timeZone:o}}catch{return{countryCode:"unknown",locale:"unknown",timeZone:"unknown"}}}function G(t,o){const i=l.constants,r=i?.reactNativeVersion?`${i.reactNativeVersion.major}.${i.reactNativeVersion.minor}.${i.reactNativeVersion.patch}`:"unknown",a=typeof global.HermesInternal=="object"&&global.HermesInternal!==null,e=global?.nativeFabricUIManager!==void 0,d=!!(global?._rn_bridgeless||global?.RN$Bridgeless),c=!!(typeof __DEV__<"u"&&__DEV__),n=be(),{countryCode:_,locale:f,timeZone:J}=ye();let w="unknown",k=1,I=1,M="phone",C="portrait";try{const s=re.get("window");w=`${Math.round(s.width)}x${Math.round(s.height)}`,k=P.get(),I=P.getFontScale(),C=s.width>s.height?"landscape":"portrait",M=l.OS==="ios"&&!!l.isPad||Math.min(s.width,s.height)>=600?"tablet":"phone"}catch{}let x="unknown";try{x=ae?.getColorScheme?.()||"unknown"}catch{}const Y=!!(globalThis?.expo||globalThis?.__expo||globalThis?.__turboModuleProxy?.name==="Expo"||l.constants?.ExpoVersion);let g="non_hermes",h="jsc";if(a){h="hermes";try{const s=global.HermesInternal?.getRuntimeProperties?.()||{};g=s["OSS Release Version"]||(s["Bytecode Version"]?`bc_v${s["Bytecode Version"]}`:"hermes")}catch{g="hermes"}}else globalThis?._v8&&(h="v8");let T=!1;try{T=ie()}catch{}let E=!1;try{E=se()}catch{}const N=de(),W=!!(oe?.RNMMKV||globalThis?.MMKV);let D=0;try{D=ce().length}catch{}let V="0";try{const s=le().length;V=s===0?"0":s<=10?"1-10":s<=50?"11-50":s<=100?"51-100":"100+"}catch{}let A=!1;try{A=ve()}catch{}const q=o?.defaultTab||"apis",Q=N&&o?.useNativeFab!==!1?"native_ui_thread":"js_floating_button",X=String(i?.Brand||(l.OS==="ios"?"Apple":"unknown")),ee=String(i?.Model||i?.systemName||(l.OS==="ios"?"iPhone/iPad":"unknown")),te=String(i?.Manufacturer||(l.OS==="ios"?"Apple":"unknown"));let B="App",L="unknown",O="unknown",F="unknown";try{B=_e()||"App",L=ue()||"unknown";const s=pe();O=s.version||"unknown",F=s.build||"unknown"}catch{}const ne=typeof b<"u"&&b.version?b.version:"unknown";return{pkg_name:z,pkg_version:R,lib_version:R,install_type:c?"local_dev":"bundled_production",app_name:B,bundle_id:L,app_version:O,app_build:F,react_version:ne,platform:l.OS,os_version:String(l.Version||"unknown"),rn_version:r,country_code:_,device_locale:f,time_zone:J,device_brand:X,device_model:ee,device_manufacturer:te,device_form_factor:M,screen_resolution:w,screen_density:k,screen_orientation:C,font_scale:I,appearance_mode:x,is_expo:Y,js_engine:h,hermes_version:g,is_hermes:a,is_fabric:e,is_bridgeless:d,has_native_module:N,has_mmkv:W,fab_mode:Q,default_landing_tab:q,captured_crashes_count:D,captured_apis_bracket:V,search_filter_used:U,is_metro_connected:A,is_dev:c,is_emulator:n,device_type:n?"emulator":"real_device",app_mode:c?"local_mode":"bundled_application",redux_attached:T,analytics_attached:E,environment:t||(c?"DEV":"PROD"),engagement_time_msec:1e3}}export async function trackActiveTelemetryHeartbeat(t=!0,o){if(t===!1){m=!1;return}if(m=!0,process.env.NODE_ENV==="test"||typeof globalThis.jest<"u")return;const i=K();if(i)try{const r=await y(),a=r.telemetryLastPing||0,e=Date.now(),d=!r.deviceRegistered;if(!d&&e-a<he)return;const c=await Z(),n=G(o,r),_={...n,device_id:c,is_new_device:d,device_first_seen:r.deviceFirstSeen||e},f=d?[{name:"active_device",params:_},{name:"first_device_install",params:_},{name:"inspector_active_heartbeat",params:_}]:[{name:"active_device",params:_},{name:"inspector_active_heartbeat",params:_}];await fetch(i,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({client_id:c,user_id:c,non_personalized_ads:!0,user_properties:{device_id:{value:c},pkg_name:{value:n.pkg_name},pkg_version:{value:n.pkg_version},install_type:{value:n.install_type},app_name:{value:n.app_name},bundle_id:{value:n.bundle_id},app_version:{value:n.app_version},react_version:{value:n.react_version},country:{value:n.country_code},country_code:{value:n.country_code},locale:{value:n.device_locale},time_zone:{value:n.time_zone},device_brand:{value:n.device_brand},device_model:{value:n.device_model},device_form_factor:{value:n.device_form_factor},screen_resolution:{value:n.screen_resolution},appearance_mode:{value:n.appearance_mode},is_expo:{value:String(n.is_expo)},js_engine:{value:n.js_engine},is_fabric:{value:String(n.is_fabric)},is_bridgeless:{value:String(n.is_bridgeless)},has_native_module:{value:String(n.has_native_module)},has_mmkv:{value:String(n.has_mmkv)},fab_mode:{value:n.fab_mode},default_landing_tab:{value:n.default_landing_tab},captured_crashes_count:{value:String(n.captured_crashes_count)},captured_apis_bracket:{value:n.captured_apis_bracket},search_filter_used:{value:String(n.search_filter_used)},is_metro_connected:{value:String(n.is_metro_connected)},redux_attached:{value:String(n.redux_attached)},analytics_attached:{value:String(n.analytics_attached)},platform:{value:n.platform},rn_version:{value:n.rn_version},lib_version:{value:n.lib_version}},events:f})}),await S({...r,telemetryClientId:c,telemetryDeviceId:c,deviceRegistered:!0,deviceFirstSeen:r.deviceFirstSeen||e,telemetryLastPing:e,telemetryLastActive:e})}catch{}}export async function trackTelemetryEvent(t,o){if(!m)return;const i=K();if(i)try{const r=await Z(),a=await y().catch(()=>({})),e=G(void 0,a),d={...e,device_id:r,...o,engagement_time_msec:100};await fetch(i,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({client_id:r,user_id:r,non_personalized_ads:!0,user_properties:{device_id:{value:r},pkg_name:{value:e.pkg_name},pkg_version:{value:e.pkg_version},install_type:{value:e.install_type},app_name:{value:e.app_name},bundle_id:{value:e.bundle_id},app_version:{value:e.app_version},react_version:{value:e.react_version},country:{value:e.country_code},country_code:{value:e.country_code},locale:{value:e.device_locale},time_zone:{value:e.time_zone},device_brand:{value:e.device_brand},device_model:{value:e.device_model},device_form_factor:{value:e.device_form_factor},screen_resolution:{value:e.screen_resolution},appearance_mode:{value:e.appearance_mode},is_expo:{value:String(e.is_expo)},js_engine:{value:e.js_engine},is_fabric:{value:String(e.is_fabric)},is_bridgeless:{value:String(e.is_bridgeless)},has_native_module:{value:String(e.has_native_module)},has_mmkv:{value:String(e.has_mmkv)},fab_mode:{value:e.fab_mode},default_landing_tab:{value:e.default_landing_tab},captured_crashes_count:{value:String(e.captured_crashes_count)},captured_apis_bracket:{value:e.captured_apis_bracket},search_filter_used:{value:String(e.search_filter_used)},is_metro_connected:{value:String(e.is_metro_connected)},redux_attached:{value:String(e.redux_attached)},analytics_attached:{value:String(e.analytics_attached)},platform:{value:e.platform},rn_version:{value:e.rn_version},lib_version:{value:e.lib_version}},events:[{name:t,params:d}]})})}catch{}}export function trackInspectorTabView(t){trackTelemetryEvent("inspector_tab_view",{tab_name:t,screen_name:`tab_${t}`,screen_class:"NetworkInspector"})}export function trackInspectorScreenView(t){trackTelemetryEvent("screen_view",{screen_name:t,screen_class:"NetworkInspector"})}export function trackInspectorScreenRecord(t,o="screen"){trackTelemetryEvent("inspector_screen_record",{action:t,recording_type:o})}
|
|
1
|
+
import S from"react";import{Appearance as ie,Dimensions as se,PixelRatio as F,Platform as l,NativeModules as ce}from"react-native";import{LIB_VERSION as u}from"../constants/version";import{loadSettings as w,saveSettings as k}from"./settingsStore";import{isReduxConnected as le}from"../customHooks/reduxLogger";import{isFirebaseAnalyticsPatched as de}from"../customHooks/analyticsLogger";import{getCrashRecords as _e}from"../customHooks/crashHandler";import{getNetworkLogs as ue}from"../customHooks/networkLogger";import{isNativeModuleAvailable as pe}from"../native/NativeInspector";import{getAppName as ve,getBundleIdentifier as me,getAppVersionAndBuild as fe,isLocalDebugEnvironment as ge}from"./index";import{ENC_MID as j,ENC_SEC as U,TELEMETRY_SALT as f}from"../constants/telemetryConfig";const z="react-native-inapp-inspector",he=`${z}::${f}`;function be(e,n){const i=[];let o=1518500249;for(let r=0;r<n;r++){const t=e.charCodeAt(r%e.length);o=(o*31+t*17+r*13^o>>>7)&4294967295,i.push(o>>>r%24&255)}return i}function K(e){if(!e)return"";const n=[];for(let r=0;r<e.length;r+=2)n.push(parseInt(e.substring(r,r+2),16));const i=be(he,n.length),o=[];for(let r=0;r<n.length;r++){const t=i[r],d=f.charCodeAt(r%f.length),c=(n[r]^t^d)&255;o.push(String.fromCharCode(c))}return o.join("")}let p=null,v=null;function H(){if(p!==null&&v!==null)return{measurementId:p,apiSecret:v};if(!j||!U||!f)return p="",v="",{measurementId:"",apiSecret:""};try{p=K(j),v=K(U)}catch{p="",v=""}return{measurementId:p,apiSecret:v}}function G(){const{measurementId:e,apiSecret:n}=H();return!e||!n?"":`https://www.google-analytics.com/mp/collect?measurement_id=${e}&api_secret=${n}`}function Z(e){try{const n=l.OS,i=String(e.os_version||(n==="ios"?"17.0":"13.0")),o=(e.device_locale||"en_US").replace("_","-");if(n==="android"){const r=e.device_model||"Android";return`Mozilla/5.0 (Linux; U; Android ${i}; ${o}; ${r}) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/120.0.0.0 Mobile Safari/537.36 (react-native-inapp-inspector/${u})`}else if(n==="ios"){const r=i.replace(/\./g,"_");return`Mozilla/5.0 (${e.device_model||"iPhone"}; CPU iPhone OS ${r} like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/15E148 (react-native-inapp-inspector/${u})`}return`${e.app_name||"App"}/${e.app_version||"1.0"} (${n}; ${i}) react-native-inapp-inspector/${u}`}catch{return`react-native-inapp-inspector/${u}`}}function W(e,n,i){const{measurementId:o}=H();if(!o)return"";const r=String(Math.floor(Date.now()/1e3));return`https://www.google-analytics.com/g/collect?${new URLSearchParams({v:"2",tid:o,cid:i,en:e,_p:String(Math.floor(1e6+Math.random()*9e6)),ul:(n.device_locale||"en_US").toLowerCase().replace("_","-"),sr:n.screen_resolution||"1080x1920",_s:"1",_ee:"1",seg:"1",_et:"1000",sid:r,sct:"1",dl:`https://${n.bundle_id||"app.native"}/inspector`,dt:`${n.app_name||"App"} - Inspector`,"ep.country_code":n.country_code||"unknown","ep.app_name":n.app_name||"App","ep.platform":n.platform||l.OS,"ep.pkg_version":n.pkg_version||u,"ep.install_type":n.install_type||"local_dev","ep.js_engine":n.js_engine||"hermes","ep.rn_version":n.rn_version||"","ep.device_brand":n.device_brand||"","ep.device_model":n.device_model||""}).toString()}`}const ye=1440*60*1e3;let g=!0,q=!1;export function setTelemetryEnabled(e){g=e}export function markSearchFilterUsed(){q=!0}async function J(){try{const e=await w();if(e.telemetryClientId||e.telemetryDeviceId){const t=e.telemetryClientId||e.telemetryDeviceId||"";return e.telemetryDeviceId||await k({...e,telemetryDeviceId:t}),t}const n=Math.floor(1e8+Math.random()*9e8),i=Math.floor(1e9+Math.random()*9e9),o=`${n}.${i}`,r=Date.now();return await k({...e,telemetryClientId:o,telemetryDeviceId:o,deviceFirstSeen:e.deviceFirstSeen||r}),o}catch{return`${Math.floor(1e8+Math.random()*9e8)}.${Math.floor(1e9+Math.random()*9e9)}`}}function Se(){try{if(l.OS==="android"){const e=l.constants||{},n=String(e.Model||"").toLowerCase(),i=String(e.Brand||"").toLowerCase(),o=String(e.Fingerprint||"").toLowerCase(),r=String(e.Hardware||"").toLowerCase(),t=String(e.Manufacturer||"").toLowerCase();return n.includes("emulator")||n.includes("sdk")||n.includes("google_sdk")||n.includes("vbox")||i.includes("generic")||o.startsWith("generic")||r.includes("goldfish")||r.includes("ranchu")||t.includes("genymotion")}if(l.OS==="ios"){const e=l.constants||{};return String(e.Model||"").toLowerCase().includes("simulator")||!!e.isSimulator}}catch{return!1}return!1}function we(){try{const e=typeof Intl<"u"&&Intl.DateTimeFormat?Intl.DateTimeFormat().resolvedOptions():{},n=e.timeZone||"unknown",i=e.locale||"unknown";let o="unknown";if(i&&i!=="unknown"){const r=i.split(/[-_]/);r.length>1&&(o=r[r.length-1].toUpperCase())}return{countryCode:o,locale:i,timeZone:n}}catch{return{countryCode:"unknown",locale:"unknown",timeZone:"unknown"}}}function Y(e,n){const i=l.constants,o=i?.reactNativeVersion?`${i.reactNativeVersion.major}.${i.reactNativeVersion.minor}.${i.reactNativeVersion.patch}`:"unknown",r=typeof global.HermesInternal=="object"&&global.HermesInternal!==null,t=global?.nativeFabricUIManager!==void 0,d=!!(global?._rn_bridgeless||global?.RN$Bridgeless),c=!!(typeof __DEV__<"u"&&__DEV__),a=Se(),{countryCode:_,locale:h,timeZone:m}=we();let M="unknown",I=1,C=1,x="phone",A="portrait";try{const s=se.get("window");M=`${Math.round(s.width)}x${Math.round(s.height)}`,I=F.get(),C=F.getFontScale(),A=s.width>s.height?"landscape":"portrait",x=l.OS==="ios"&&!!l.isPad||Math.min(s.width,s.height)>=600?"tablet":"phone"}catch{}let $="unknown";try{$=ie?.getColorScheme?.()||"unknown"}catch{}const X=!!(globalThis?.expo||globalThis?.__expo||globalThis?.__turboModuleProxy?.name==="Expo"||l.constants?.ExpoVersion);let b="non_hermes",y="jsc";if(r){y="hermes";try{const s=global.HermesInternal?.getRuntimeProperties?.()||{};b=s["OSS Release Version"]||(s["Bytecode Version"]?`bc_v${s["Bytecode Version"]}`:"hermes")}catch{b="hermes"}}else globalThis?._v8&&(y="v8");let T=!1;try{T=le()}catch{}let E=!1;try{E=de()}catch{}const V=pe(),Q=!!(ce?.RNMMKV||globalThis?.MMKV);let P=0;try{P=_e().length}catch{}let D="0";try{const s=ue().length;D=s===0?"0":s<=10?"1-10":s<=50?"11-50":s<=100?"51-100":"100+"}catch{}let N=!1;try{N=ge()}catch{}const ee=n?.defaultTab||"apis",te=V&&n?.useNativeFab!==!1?"native_ui_thread":"js_floating_button",ne=String(i?.Brand||(l.OS==="ios"?"Apple":"unknown")),ae=String(i?.Model||i?.systemName||(l.OS==="ios"?"iPhone/iPad":"unknown")),re=String(i?.Manufacturer||(l.OS==="ios"?"Apple":"unknown"));let O="App",L="unknown",B="unknown",R="unknown";try{O=ve()||"App",L=me()||"unknown";const s=fe();B=s.version||"unknown",R=s.build||"unknown"}catch{}const oe=typeof S<"u"&&S.version?S.version:"unknown";return{pkg_name:z,pkg_version:u,lib_version:u,install_type:c?"local_dev":"bundled_production",app_name:O,bundle_id:L,app_version:B,app_build:R,react_version:oe,platform:l.OS,os_version:String(l.Version||"unknown"),rn_version:o,country_code:_,device_locale:h,time_zone:m,device_brand:ne,device_model:ae,device_manufacturer:re,device_form_factor:x,screen_resolution:M,screen_density:I,screen_orientation:A,font_scale:C,appearance_mode:$,is_expo:X,js_engine:y,hermes_version:b,is_hermes:r,is_fabric:t,is_bridgeless:d,has_native_module:V,has_mmkv:Q,fab_mode:te,default_landing_tab:ee,captured_crashes_count:P,captured_apis_bracket:D,search_filter_used:q,is_metro_connected:N,is_dev:c,is_emulator:a,device_type:a?"emulator":"real_device",app_mode:c?"local_mode":"bundled_application",redux_attached:T,analytics_attached:E,environment:e||(c?"DEV":"PROD"),engagement_time_msec:1e3}}export async function trackActiveTelemetryHeartbeat(e=!0,n){if(e===!1){g=!1;return}if(g=!0,process.env.NODE_ENV==="test"||typeof globalThis.jest<"u")return;const i=G();if(i)try{const o=await w(),r=o.telemetryLastPing||0,t=Date.now(),d=!o.deviceRegistered;if(!d&&t-r<ye)return;const c=await J(),a=Y(n,o),_={...a,device_id:c,is_new_device:d,device_first_seen:o.deviceFirstSeen||t},h=d?[{name:"first_open",params:_},{name:"first_device_install",params:_},{name:"session_start",params:_},{name:"active_device",params:_},{name:"inspector_active_heartbeat",params:_}]:[{name:"session_start",params:_},{name:"app_open",params:_},{name:"active_device",params:_},{name:"inspector_active_heartbeat",params:_}],m=W(d?"first_open":"session_start",a,c);m&&fetch(m,{method:"POST",headers:{"User-Agent":Z(a)}}).catch(()=>{}),await fetch(i,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({client_id:c,user_id:c,non_personalized_ads:!0,user_properties:{device_id:{value:c},pkg_name:{value:a.pkg_name},pkg_version:{value:a.pkg_version},install_type:{value:a.install_type},app_name:{value:a.app_name},bundle_id:{value:a.bundle_id},app_version:{value:a.app_version},react_version:{value:a.react_version},country:{value:a.country_code},country_code:{value:a.country_code},locale:{value:a.device_locale},time_zone:{value:a.time_zone},device_brand:{value:a.device_brand},device_model:{value:a.device_model},device_form_factor:{value:a.device_form_factor},screen_resolution:{value:a.screen_resolution},appearance_mode:{value:a.appearance_mode},is_expo:{value:String(a.is_expo)},js_engine:{value:a.js_engine},is_fabric:{value:String(a.is_fabric)},is_bridgeless:{value:String(a.is_bridgeless)},has_native_module:{value:String(a.has_native_module)},has_mmkv:{value:String(a.has_mmkv)},fab_mode:{value:a.fab_mode},default_landing_tab:{value:a.default_landing_tab},captured_crashes_count:{value:String(a.captured_crashes_count)},captured_apis_bracket:{value:a.captured_apis_bracket},search_filter_used:{value:String(a.search_filter_used)},is_metro_connected:{value:String(a.is_metro_connected)},redux_attached:{value:String(a.redux_attached)},analytics_attached:{value:String(a.analytics_attached)},platform:{value:a.platform},rn_version:{value:a.rn_version},lib_version:{value:a.lib_version}},events:h})}),await k({...o,telemetryClientId:c,telemetryDeviceId:c,deviceRegistered:!0,deviceFirstSeen:o.deviceFirstSeen||t,telemetryLastPing:t,telemetryLastActive:t})}catch{}}export async function trackTelemetryEvent(e,n){if(!g)return;const i=G();if(i)try{const o=await J(),r=await w().catch(()=>({})),t=Y(void 0,r),d={...t,device_id:o,...n,engagement_time_msec:100},c=W(e,d,o);c&&fetch(c,{method:"POST",headers:{"User-Agent":Z(t)}}).catch(()=>{}),await fetch(i,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({client_id:o,user_id:o,non_personalized_ads:!0,user_properties:{device_id:{value:o},pkg_name:{value:t.pkg_name},pkg_version:{value:t.pkg_version},install_type:{value:t.install_type},app_name:{value:t.app_name},bundle_id:{value:t.bundle_id},app_version:{value:t.app_version},react_version:{value:t.react_version},country:{value:t.country_code},country_code:{value:t.country_code},locale:{value:t.device_locale},time_zone:{value:t.time_zone},device_brand:{value:t.device_brand},device_model:{value:t.device_model},device_form_factor:{value:t.device_form_factor},screen_resolution:{value:t.screen_resolution},appearance_mode:{value:t.appearance_mode},is_expo:{value:String(t.is_expo)},js_engine:{value:t.js_engine},is_fabric:{value:String(t.is_fabric)},is_bridgeless:{value:String(t.is_bridgeless)},has_native_module:{value:String(t.has_native_module)},has_mmkv:{value:String(t.has_mmkv)},fab_mode:{value:t.fab_mode},default_landing_tab:{value:t.default_landing_tab},captured_crashes_count:{value:String(t.captured_crashes_count)},captured_apis_bracket:{value:t.captured_apis_bracket},search_filter_used:{value:String(t.search_filter_used)},is_metro_connected:{value:String(t.is_metro_connected)},redux_attached:{value:String(t.redux_attached)},analytics_attached:{value:String(t.analytics_attached)},platform:{value:t.platform},rn_version:{value:t.rn_version},lib_version:{value:t.lib_version}},events:[{name:e,params:d}]})})}catch{}}export function trackInspectorTabView(e){trackTelemetryEvent("inspector_tab_view",{tab_name:e,screen_name:`tab_${e}`,screen_class:"NetworkInspector"})}export function trackInspectorScreenView(e){trackTelemetryEvent("screen_view",{screen_name:e,screen_class:"NetworkInspector"})}export function trackInspectorScreenRecord(e,n="screen"){trackTelemetryEvent("inspector_screen_record",{action:e,recording_type:n})}
|