@transfergratis/react-native-sdk 0.1.2
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/README.md +539 -0
- package/android/.gradle/8.9/checksums/checksums.lock +0 -0
- package/android/.gradle/8.9/dependencies-accessors/gc.properties +0 -0
- package/android/.gradle/8.9/fileChanges/last-build.bin +0 -0
- package/android/.gradle/8.9/fileHashes/fileHashes.lock +0 -0
- package/android/.gradle/8.9/gc.properties +0 -0
- package/android/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
- package/android/.gradle/buildOutputCleanup/cache.properties +2 -0
- package/android/.gradle/config.properties +2 -0
- package/android/.gradle/vcs-1/gc.properties +0 -0
- package/android/.idea/gradle.xml +14 -0
- package/android/.idea/migrations.xml +10 -0
- package/android/.idea/misc.xml +9 -0
- package/android/.idea/runConfigurations.xml +17 -0
- package/android/.idea/vcs.xml +6 -0
- package/android/build/.transforms/7ec900c0f64f5f1a7c88998dd44001b8/results.bin +1 -0
- package/android/build/.transforms/7ec900c0f64f5f1a7c88998dd44001b8/transformed/classes/classes_dex/classes.dex +0 -0
- package/android/build/.transforms/d6df0e53bfc3165a876965af720f910a/results.bin +1 -0
- package/android/build/.transforms/d6df0e53bfc3165a876965af720f910a/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/kyc/transfergratis/com/BuildConfig.dex +0 -0
- package/android/build/.transforms/d6df0e53bfc3165a876965af720f910a/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/kyc/transfergratis/com/TransfergratisSdkModule$definition$1$5$1.dex +0 -0
- package/android/build/.transforms/d6df0e53bfc3165a876965af720f910a/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/kyc/transfergratis/com/TransfergratisSdkModule$definition$1$5$2.dex +0 -0
- package/android/build/.transforms/d6df0e53bfc3165a876965af720f910a/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunction$1.dex +0 -0
- package/android/build/.transforms/d6df0e53bfc3165a876965af720f910a/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunction$2.dex +0 -0
- package/android/build/.transforms/d6df0e53bfc3165a876965af720f910a/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunction$3.dex +0 -0
- package/android/build/.transforms/d6df0e53bfc3165a876965af720f910a/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunction$4.dex +0 -0
- package/android/build/.transforms/d6df0e53bfc3165a876965af720f910a/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunction$5.dex +0 -0
- package/android/build/.transforms/d6df0e53bfc3165a876965af720f910a/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunction$6.dex +0 -0
- package/android/build/.transforms/d6df0e53bfc3165a876965af720f910a/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunctionWithPromise$1.dex +0 -0
- package/android/build/.transforms/d6df0e53bfc3165a876965af720f910a/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunctionWithPromise$2.dex +0 -0
- package/android/build/.transforms/d6df0e53bfc3165a876965af720f910a/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunctionWithPromise$3.dex +0 -0
- package/android/build/.transforms/d6df0e53bfc3165a876965af720f910a/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunctionWithPromise$4.dex +0 -0
- package/android/build/.transforms/d6df0e53bfc3165a876965af720f910a/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$View$1.dex +0 -0
- package/android/build/.transforms/d6df0e53bfc3165a876965af720f910a/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$lambda$4$$inlined$Prop$1.dex +0 -0
- package/android/build/.transforms/d6df0e53bfc3165a876965af720f910a/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$lambda$4$$inlined$Prop$2.dex +0 -0
- package/android/build/.transforms/d6df0e53bfc3165a876965af720f910a/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/kyc/transfergratis/com/TransfergratisSdkModule.dex +0 -0
- package/android/build/.transforms/d6df0e53bfc3165a876965af720f910a/transformed/bundleLibRuntimeToDirDebug/bundleLibRuntimeToDirDebug_dex/kyc/transfergratis/com/TransfergratisSdkView.dex +0 -0
- package/android/build/.transforms/d6df0e53bfc3165a876965af720f910a/transformed/bundleLibRuntimeToDirDebug/desugar_graph.bin +0 -0
- package/android/build/generated/source/buildConfig/debug/kyc/transfergratis/com/BuildConfig.java +10 -0
- package/android/build/intermediates/aapt_friendly_merged_manifests/debug/processDebugManifest/aapt/AndroidManifest.xml +35 -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 +1 -0
- package/android/build/intermediates/compiled_local_resources/debug/compileDebugLibraryResources/out/xml_file_paths.xml.flat +0 -0
- package/android/build/intermediates/incremental/debug/packageDebugResources/compile-file-map.properties +2 -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/transfergratis-sdk_debug.kotlin_module +0 -0
- package/android/build/intermediates/javac/debug/compileDebugJavaWithJavac/classes/kyc/transfergratis/com/BuildConfig.class +0 -0
- package/android/build/intermediates/local_only_symbol_list/debug/parseDebugLocalResources/R-def.txt +3 -0
- package/android/build/intermediates/manifest_merge_blame_file/debug/processDebugManifest/manifest-merger-blame-debug-report.txt +58 -0
- package/android/build/intermediates/merged_manifest/debug/processDebugManifest/AndroidManifest.xml +35 -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/packaged_res/debug/packageDebugResources/xml/file_paths.xml +15 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/META-INF/transfergratis-sdk_debug.kotlin_module +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/kyc/transfergratis/com/BuildConfig.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/kyc/transfergratis/com/TransfergratisSdkModule$definition$1$5$1.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/kyc/transfergratis/com/TransfergratisSdkModule$definition$1$5$2.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunction$1.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunction$2.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunction$3.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunction$4.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunction$5.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunction$6.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunctionWithPromise$1.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunctionWithPromise$2.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunctionWithPromise$3.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunctionWithPromise$4.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$View$1.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$lambda$4$$inlined$Prop$1.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$lambda$4$$inlined$Prop$2.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/kyc/transfergratis/com/TransfergratisSdkModule.class +0 -0
- package/android/build/intermediates/runtime_library_classes_dir/debug/bundleLibRuntimeToDirDebug/kyc/transfergratis/com/TransfergratisSdkView.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 +2 -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/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 +63 -0
- package/android/build/tmp/compileDebugJavaWithJavac/previous-compilation-data.bin +0 -0
- package/android/build/tmp/kotlin-classes/debug/META-INF/transfergratis-sdk_debug.kotlin_module +0 -0
- package/android/build/tmp/kotlin-classes/debug/kyc/transfergratis/com/TransfergratisSdkModule$definition$1$5$1.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kyc/transfergratis/com/TransfergratisSdkModule$definition$1$5$2.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunction$1.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunction$2.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunction$3.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunction$4.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunction$5.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunction$6.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunctionWithPromise$1.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunctionWithPromise$2.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunctionWithPromise$3.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$AsyncFunctionWithPromise$4.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$$inlined$View$1.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$lambda$4$$inlined$Prop$1.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kyc/transfergratis/com/TransfergratisSdkModule$definition$lambda$5$lambda$4$$inlined$Prop$2.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kyc/transfergratis/com/TransfergratisSdkModule.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kyc/transfergratis/com/TransfergratisSdkView.class +0 -0
- package/android/build.gradle +47 -0
- package/android/local.properties +8 -0
- package/android/src/main/AndroidManifest.xml +28 -0
- package/android/src/main/java/kyc/transfergratis/com/TransfergratisSdkModule.kt +131 -0
- package/android/src/main/java/kyc/transfergratis/com/TransfergratisSdkView.kt +161 -0
- package/android/src/main/res/xml/file_paths.xml +15 -0
- package/build/App.d.ts +3 -0
- package/build/App.d.ts.map +1 -0
- package/build/App.js +9 -0
- package/build/App.js.map +1 -0
- package/build/TransfergratisSdk.types.d.ts +32 -0
- package/build/TransfergratisSdk.types.d.ts.map +1 -0
- package/build/TransfergratisSdk.types.js +2 -0
- package/build/TransfergratisSdk.types.js.map +1 -0
- package/build/TransfergratisSdkModule.d.ts +21 -0
- package/build/TransfergratisSdkModule.d.ts.map +1 -0
- package/build/TransfergratisSdkModule.js +4 -0
- package/build/TransfergratisSdkModule.js.map +1 -0
- package/build/TransfergratisSdkModule.web.d.ts +20 -0
- package/build/TransfergratisSdkModule.web.d.ts.map +1 -0
- package/build/TransfergratisSdkModule.web.js +25 -0
- package/build/TransfergratisSdkModule.web.js.map +1 -0
- package/build/TransfergratisSdkView.d.ts +4 -0
- package/build/TransfergratisSdkView.d.ts.map +1 -0
- package/build/TransfergratisSdkView.js +7 -0
- package/build/TransfergratisSdkView.js.map +1 -0
- package/build/TransfergratisSdkView.web.d.ts +4 -0
- package/build/TransfergratisSdkView.web.d.ts.map +1 -0
- package/build/TransfergratisSdkView.web.js +11 -0
- package/build/TransfergratisSdkView.web.js.map +1 -0
- package/build/components/Camera/index.d.ts +2 -0
- package/build/components/Camera/index.d.ts.map +1 -0
- package/build/components/Camera/index.js +2 -0
- package/build/components/Camera/index.js.map +1 -0
- package/build/components/Camera/index.web.d.ts +2 -0
- package/build/components/Camera/index.web.d.ts.map +1 -0
- package/build/components/Camera/index.web.js +2 -0
- package/build/components/Camera/index.web.js.map +1 -0
- package/build/components/Camera/types.d.ts +2 -0
- package/build/components/Camera/types.d.ts.map +1 -0
- package/build/components/Camera/types.js +2 -0
- package/build/components/Camera/types.js.map +1 -0
- package/build/components/ConfigurableKYCFlow.d.ts +11 -0
- package/build/components/ConfigurableKYCFlow.d.ts.map +1 -0
- package/build/components/ConfigurableKYCFlow.js +257 -0
- package/build/components/ConfigurableKYCFlow.js.map +1 -0
- package/build/components/CustomCameraExample.d.ts +10 -0
- package/build/components/CustomCameraExample.d.ts.map +1 -0
- package/build/components/CustomCameraExample.js +232 -0
- package/build/components/CustomCameraExample.js.map +1 -0
- package/build/components/EnhancedCameraView.d.ts +44 -0
- package/build/components/EnhancedCameraView.d.ts.map +1 -0
- package/build/components/EnhancedCameraView.js +316 -0
- package/build/components/EnhancedCameraView.js.map +1 -0
- package/build/components/EnhancedCameraView.web.d.ts +44 -0
- package/build/components/EnhancedCameraView.web.d.ts.map +1 -0
- package/build/components/EnhancedCameraView.web.js +399 -0
- package/build/components/EnhancedCameraView.web.js.map +1 -0
- package/build/components/FileUpload.d.ts +13 -0
- package/build/components/FileUpload.d.ts.map +1 -0
- package/build/components/FileUpload.js +216 -0
- package/build/components/FileUpload.js.map +1 -0
- package/build/components/KYCElementRenderer.d.ts +14 -0
- package/build/components/KYCElementRenderer.d.ts.map +1 -0
- package/build/components/KYCElementRenderer.js +31 -0
- package/build/components/KYCElementRenderer.js.map +1 -0
- package/build/components/KYCElements/CameraCapture.d.ts +11 -0
- package/build/components/KYCElements/CameraCapture.d.ts.map +1 -0
- package/build/components/KYCElements/CameraCapture.js +218 -0
- package/build/components/KYCElements/CameraCapture.js.map +1 -0
- package/build/components/KYCElements/CompletionStep.d.ts +10 -0
- package/build/components/KYCElements/CompletionStep.d.ts.map +1 -0
- package/build/components/KYCElements/CompletionStep.js +147 -0
- package/build/components/KYCElements/CompletionStep.js.map +1 -0
- package/build/components/KYCElements/CountrySelection.d.ts +11 -0
- package/build/components/KYCElements/CountrySelection.d.ts.map +1 -0
- package/build/components/KYCElements/CountrySelection.js +147 -0
- package/build/components/KYCElements/CountrySelection.js.map +1 -0
- package/build/components/KYCElements/CountrySelectionTemplate.d.ts +12 -0
- package/build/components/KYCElements/CountrySelectionTemplate.d.ts.map +1 -0
- package/build/components/KYCElements/CountrySelectionTemplate.js +245 -0
- package/build/components/KYCElements/CountrySelectionTemplate.js.map +1 -0
- package/build/components/KYCElements/DocumentTypeSelection.d.ts +11 -0
- package/build/components/KYCElements/DocumentTypeSelection.d.ts.map +1 -0
- package/build/components/KYCElements/DocumentTypeSelection.js +143 -0
- package/build/components/KYCElements/DocumentTypeSelection.js.map +1 -0
- package/build/components/KYCElements/FileUpload.d.ts +11 -0
- package/build/components/KYCElements/FileUpload.d.ts.map +1 -0
- package/build/components/KYCElements/FileUpload.js +267 -0
- package/build/components/KYCElements/FileUpload.js.map +1 -0
- package/build/components/KYCElements/FileUploadTemplate.d.ts +12 -0
- package/build/components/KYCElements/FileUploadTemplate.d.ts.map +1 -0
- package/build/components/KYCElements/FileUploadTemplate.js +326 -0
- package/build/components/KYCElements/FileUploadTemplate.js.map +1 -0
- package/build/components/KYCElements/IDCardCapture.d.ts +13 -0
- package/build/components/KYCElements/IDCardCapture.d.ts.map +1 -0
- package/build/components/KYCElements/IDCardCapture.js +421 -0
- package/build/components/KYCElements/IDCardCapture.js.map +1 -0
- package/build/components/KYCElements/LocationCaptureTemplate.d.ts +20 -0
- package/build/components/KYCElements/LocationCaptureTemplate.d.ts.map +1 -0
- package/build/components/KYCElements/LocationCaptureTemplate.js +275 -0
- package/build/components/KYCElements/LocationCaptureTemplate.js.map +1 -0
- package/build/components/KYCElements/OrientationVideoCapture.d.ts +12 -0
- package/build/components/KYCElements/OrientationVideoCapture.d.ts.map +1 -0
- package/build/components/KYCElements/OrientationVideoCapture.js +533 -0
- package/build/components/KYCElements/OrientationVideoCapture.js.map +1 -0
- package/build/components/KYCElements/OrientationVideoCaptureEnhanced.d.ts +12 -0
- package/build/components/KYCElements/OrientationVideoCaptureEnhanced.d.ts.map +1 -0
- package/build/components/KYCElements/OrientationVideoCaptureEnhanced.js +503 -0
- package/build/components/KYCElements/OrientationVideoCaptureEnhanced.js.map +1 -0
- package/build/components/KYCElements/OrientationVideoCaptureFinal.d.ts +12 -0
- package/build/components/KYCElements/OrientationVideoCaptureFinal.d.ts.map +1 -0
- package/build/components/KYCElements/OrientationVideoCaptureFinal.js +429 -0
- package/build/components/KYCElements/OrientationVideoCaptureFinal.js.map +1 -0
- package/build/components/KYCElements/SelfieCapture.d.ts +11 -0
- package/build/components/KYCElements/SelfieCapture.d.ts.map +1 -0
- package/build/components/KYCElements/SelfieCapture.js +235 -0
- package/build/components/KYCElements/SelfieCapture.js.map +1 -0
- package/build/components/KYCElements/SelfieCaptureTemplate.d.ts +12 -0
- package/build/components/KYCElements/SelfieCaptureTemplate.d.ts.map +1 -0
- package/build/components/KYCElements/SelfieCaptureTemplate.js +321 -0
- package/build/components/KYCElements/SelfieCaptureTemplate.js.map +1 -0
- package/build/components/KYCElements/VerificationStep.d.ts +10 -0
- package/build/components/KYCElements/VerificationStep.d.ts.map +1 -0
- package/build/components/KYCElements/VerificationStep.js +199 -0
- package/build/components/KYCElements/VerificationStep.js.map +1 -0
- package/build/components/KYCExample.d.ts +3 -0
- package/build/components/KYCExample.d.ts.map +1 -0
- package/build/components/KYCExample.js +247 -0
- package/build/components/KYCExample.js.map +1 -0
- package/build/components/KYCFlow.d.ts +3 -0
- package/build/components/KYCFlow.d.ts.map +1 -0
- package/build/components/KYCFlow.js +308 -0
- package/build/components/KYCFlow.js.map +1 -0
- package/build/components/NativeCameraView.d.ts +11 -0
- package/build/components/NativeCameraView.d.ts.map +1 -0
- package/build/components/NativeCameraView.js +27 -0
- package/build/components/NativeCameraView.js.map +1 -0
- package/build/components/OverLay/IdCard.d.ts +4 -0
- package/build/components/OverLay/IdCard.d.ts.map +1 -0
- package/build/components/OverLay/IdCard.js +181 -0
- package/build/components/OverLay/IdCard.js.map +1 -0
- package/build/components/OverLay/SelfieOverlay.d.ts +4 -0
- package/build/components/OverLay/SelfieOverlay.d.ts.map +1 -0
- package/build/components/OverLay/SelfieOverlay.js +168 -0
- package/build/components/OverLay/SelfieOverlay.js.map +1 -0
- package/build/components/OverLay/StepOverlay.d.ts +9 -0
- package/build/components/OverLay/StepOverlay.d.ts.map +1 -0
- package/build/components/OverLay/StepOverlay.js +51 -0
- package/build/components/OverLay/StepOverlay.js.map +1 -0
- package/build/components/OverLay/type.d.ts +21 -0
- package/build/components/OverLay/type.d.ts.map +1 -0
- package/build/components/OverLay/type.js +2 -0
- package/build/components/OverLay/type.js.map +1 -0
- package/build/components/ProgressIndicator.d.ts +8 -0
- package/build/components/ProgressIndicator.d.ts.map +1 -0
- package/build/components/ProgressIndicator.js +48 -0
- package/build/components/ProgressIndicator.js.map +1 -0
- package/build/components/SelfieCapture.d.ts +3 -0
- package/build/components/SelfieCapture.d.ts.map +1 -0
- package/build/components/SelfieCapture.js +197 -0
- package/build/components/SelfieCapture.js.map +1 -0
- package/build/components/SimpleExample.d.ts +3 -0
- package/build/components/SimpleExample.d.ts.map +1 -0
- package/build/components/SimpleExample.js +89 -0
- package/build/components/SimpleExample.js.map +1 -0
- package/build/components/Svgs/GpsIcon.d.ts +3 -0
- package/build/components/Svgs/GpsIcon.d.ts.map +1 -0
- package/build/components/Svgs/GpsIcon.js +9 -0
- package/build/components/Svgs/GpsIcon.js.map +1 -0
- package/build/components/Svgs/Schield.d.ts +3 -0
- package/build/components/Svgs/Schield.d.ts.map +1 -0
- package/build/components/Svgs/Schield.js +22 -0
- package/build/components/Svgs/Schield.js.map +1 -0
- package/build/components/Svgs/frontSelfieIcon.d.ts +3 -0
- package/build/components/Svgs/frontSelfieIcon.d.ts.map +1 -0
- package/build/components/Svgs/frontSelfieIcon.js +11 -0
- package/build/components/Svgs/frontSelfieIcon.js.map +1 -0
- package/build/components/Svgs/scanningLine.d.ts +9 -0
- package/build/components/Svgs/scanningLine.d.ts.map +1 -0
- package/build/components/Svgs/scanningLine.js +61 -0
- package/build/components/Svgs/scanningLine.js.map +1 -0
- package/build/components/Svgs/sideSelfieIcon.d.ts +3 -0
- package/build/components/Svgs/sideSelfieIcon.d.ts.map +1 -0
- package/build/components/Svgs/sideSelfieIcon.js +9 -0
- package/build/components/Svgs/sideSelfieIcon.js.map +1 -0
- package/build/components/TemplateKYCExample.d.ts +7 -0
- package/build/components/TemplateKYCExample.d.ts.map +1 -0
- package/build/components/TemplateKYCExample.js +433 -0
- package/build/components/TemplateKYCExample.js.map +1 -0
- package/build/components/TemplateKYCFlowRefactored.d.ts +12 -0
- package/build/components/TemplateKYCFlowRefactored.d.ts.map +1 -0
- package/build/components/TemplateKYCFlowRefactored.js +210 -0
- package/build/components/TemplateKYCFlowRefactored.js.map +1 -0
- package/build/components/VisionCameraView.d.ts +22 -0
- package/build/components/VisionCameraView.d.ts.map +1 -0
- package/build/components/VisionCameraView.js +142 -0
- package/build/components/VisionCameraView.js.map +1 -0
- package/build/components/example/CameraCaptureEx.d.ts +4 -0
- package/build/components/example/CameraCaptureEx.d.ts.map +1 -0
- package/build/components/example/CameraCaptureEx.js +219 -0
- package/build/components/example/CameraCaptureEx.js.map +1 -0
- package/build/components/example/CameraCaptureExAdvanced.d.ts +3 -0
- package/build/components/example/CameraCaptureExAdvanced.d.ts.map +1 -0
- package/build/components/example/CameraCaptureExAdvanced.js +229 -0
- package/build/components/example/CameraCaptureExAdvanced.js.map +1 -0
- package/build/components/example/CameraCaptureExScan.d.ts +3 -0
- package/build/components/example/CameraCaptureExScan.d.ts.map +1 -0
- package/build/components/example/CameraCaptureExScan.js +213 -0
- package/build/components/example/CameraCaptureExScan.js.map +1 -0
- package/build/components/example/CameraCaptureExSimple.d.ts +3 -0
- package/build/components/example/CameraCaptureExSimple.d.ts.map +1 -0
- package/build/components/example/CameraCaptureExSimple.js +138 -0
- package/build/components/example/CameraCaptureExSimple.js.map +1 -0
- package/build/components/example/OrientationVideoExample.d.ts +4 -0
- package/build/components/example/OrientationVideoExample.d.ts.map +1 -0
- package/build/components/example/OrientationVideoExample.js +329 -0
- package/build/components/example/OrientationVideoExample.js.map +1 -0
- package/build/components/example/SelfieCaptureEx.d.ts +4 -0
- package/build/components/example/SelfieCaptureEx.d.ts.map +1 -0
- package/build/components/example/SelfieCaptureEx.js +238 -0
- package/build/components/example/SelfieCaptureEx.js.map +1 -0
- package/build/components/ui/Button.d.ts +37 -0
- package/build/components/ui/Button.d.ts.map +1 -0
- package/build/components/ui/Button.js +194 -0
- package/build/components/ui/Button.js.map +1 -0
- package/build/components/ui/ButtonExample.d.ts +4 -0
- package/build/components/ui/ButtonExample.d.ts.map +1 -0
- package/build/components/ui/ButtonExample.js +209 -0
- package/build/components/ui/ButtonExample.js.map +1 -0
- package/build/components/ui/ButtonStyles.d.ts +521 -0
- package/build/components/ui/ButtonStyles.d.ts.map +1 -0
- package/build/components/ui/ButtonStyles.js +429 -0
- package/build/components/ui/ButtonStyles.js.map +1 -0
- package/build/config/KYCConfigs.d.ts +7 -0
- package/build/config/KYCConfigs.d.ts.map +1 -0
- package/build/config/KYCConfigs.js +516 -0
- package/build/config/KYCConfigs.js.map +1 -0
- package/build/hooks/useKYC.d.ts +15 -0
- package/build/hooks/useKYC.d.ts.map +1 -0
- package/build/hooks/useKYC.js +103 -0
- package/build/hooks/useKYC.js.map +1 -0
- package/build/hooks/useKYCFlow.d.ts +3 -0
- package/build/hooks/useKYCFlow.d.ts.map +1 -0
- package/build/hooks/useKYCFlow.js +221 -0
- package/build/hooks/useKYCFlow.js.map +1 -0
- package/build/hooks/useLocation.d.ts +32 -0
- package/build/hooks/useLocation.d.ts.map +1 -0
- package/build/hooks/useLocation.js +165 -0
- package/build/hooks/useLocation.js.map +1 -0
- package/build/hooks/useOrientationVideo.d.ts +10 -0
- package/build/hooks/useOrientationVideo.d.ts.map +1 -0
- package/build/hooks/useOrientationVideo.js +117 -0
- package/build/hooks/useOrientationVideo.js.map +1 -0
- package/build/hooks/useTemplateKYCFlow.d.ts +28 -0
- package/build/hooks/useTemplateKYCFlow.d.ts.map +1 -0
- package/build/hooks/useTemplateKYCFlow.js +221 -0
- package/build/hooks/useTemplateKYCFlow.js.map +1 -0
- package/build/index.d.ts +34 -0
- package/build/index.d.ts.map +1 -0
- package/build/index.js +45 -0
- package/build/index.js.map +1 -0
- package/build/modules/api/KYCService.d.ts +35 -0
- package/build/modules/api/KYCService.d.ts.map +1 -0
- package/build/modules/api/KYCService.js +119 -0
- package/build/modules/api/KYCService.js.map +1 -0
- package/build/modules/camera/NativeCameraModule.d.ts +52 -0
- package/build/modules/camera/NativeCameraModule.d.ts.map +1 -0
- package/build/modules/camera/NativeCameraModule.js +149 -0
- package/build/modules/camera/NativeCameraModule.js.map +1 -0
- package/build/modules/camera/UnifiedCameraModule.d.ts +70 -0
- package/build/modules/camera/UnifiedCameraModule.d.ts.map +1 -0
- package/build/modules/camera/UnifiedCameraModule.js +125 -0
- package/build/modules/camera/UnifiedCameraModule.js.map +1 -0
- package/build/modules/camera/VisionCameraModule.d.ts +62 -0
- package/build/modules/camera/VisionCameraModule.d.ts.map +1 -0
- package/build/modules/camera/VisionCameraModule.js +198 -0
- package/build/modules/camera/VisionCameraModule.js.map +1 -0
- package/build/modules/camera/VisionCameraModule.web.d.ts +145 -0
- package/build/modules/camera/VisionCameraModule.web.d.ts.map +1 -0
- package/build/modules/camera/VisionCameraModule.web.js +570 -0
- package/build/modules/camera/VisionCameraModule.web.js.map +1 -0
- package/build/modules/camera/index.d.ts +5 -0
- package/build/modules/camera/index.d.ts.map +1 -0
- package/build/modules/camera/index.js +4 -0
- package/build/modules/camera/index.js.map +1 -0
- package/build/stores/kycStore.d.ts +55 -0
- package/build/stores/kycStore.d.ts.map +1 -0
- package/build/stores/kycStore.js +98 -0
- package/build/stores/kycStore.js.map +1 -0
- package/build/types/KYC.types.d.ts +326 -0
- package/build/types/KYC.types.d.ts.map +1 -0
- package/build/types/KYC.types.js +2 -0
- package/build/types/KYC.types.js.map +1 -0
- package/expo-module.config.json +9 -0
- package/ios/TransfergratisSdk.podspec +31 -0
- package/ios/TransfergratisSdkModule.swift +409 -0
- package/package.json +67 -0
- package/plugin/build/index.d.ts +4 -0
- package/plugin/build/index.js +10 -0
- package/plugin/build/withLocation.d.ts +9 -0
- package/plugin/build/withLocation.js +77 -0
- package/plugin/build/withVisionCamera.d.ts +8 -0
- package/plugin/build/withVisionCamera.js +69 -0
- package/plugin/src/index.ts +4 -0
- package/plugin/src/withLocation.ts +109 -0
- package/plugin/src/withVisionCamera.js +89 -0
- package/plugin/src/withVisionCamera.ts +98 -0
- package/plugin/tsconfig.json +17 -0
- package/plugin/tsconfig.tsbuildinfo +1 -0
- package/plugin.js +14 -0
- package/src/App.tsx +9 -0
- package/src/TransfergratisSdk.types.ts +30 -0
- package/src/TransfergratisSdkModule.ts +16 -0
- package/src/TransfergratisSdkModule.web.ts +31 -0
- package/src/TransfergratisSdkView.tsx +11 -0
- package/src/TransfergratisSdkView.web.tsx +15 -0
- package/src/components/Camera/index.tsx +0 -0
- package/src/components/Camera/index.web.tsx +0 -0
- package/src/components/Camera/types.ts +0 -0
- package/src/components/ConfigurableKYCFlow.tsx +334 -0
- package/src/components/CustomCameraExample.tsx +274 -0
- package/src/components/EnhancedCameraView.tsx +421 -0
- package/src/components/EnhancedCameraView.web.tsx +517 -0
- package/src/components/FileUpload.tsx +249 -0
- package/src/components/KYCElementRenderer.tsx +106 -0
- package/src/components/KYCElements/CameraCapture.tsx +267 -0
- package/src/components/KYCElements/CompletionStep.tsx +161 -0
- package/src/components/KYCElements/CountrySelection.tsx +177 -0
- package/src/components/KYCElements/CountrySelectionTemplate.tsx +282 -0
- package/src/components/KYCElements/DocumentTypeSelection.tsx +173 -0
- package/src/components/KYCElements/FileUpload.tsx +317 -0
- package/src/components/KYCElements/FileUploadTemplate.tsx +388 -0
- package/src/components/KYCElements/IDCardCapture.tsx +519 -0
- package/src/components/KYCElements/LocationCaptureTemplate.tsx +325 -0
- package/src/components/KYCElements/OrientationVideoCapture.tsx +646 -0
- package/src/components/KYCElements/OrientationVideoCaptureEnhanced.tsx +613 -0
- package/src/components/KYCElements/OrientationVideoCaptureFinal.tsx +531 -0
- package/src/components/KYCElements/SelfieCapture.tsx +283 -0
- package/src/components/KYCElements/SelfieCaptureTemplate.tsx +388 -0
- package/src/components/KYCElements/VerificationStep.tsx +234 -0
- package/src/components/KYCExample.tsx +297 -0
- package/src/components/KYCFlow.tsx +377 -0
- package/src/components/NativeCameraView.tsx +47 -0
- package/src/components/OverLay/IdCard.tsx +269 -0
- package/src/components/OverLay/SelfieOverlay.tsx +210 -0
- package/src/components/OverLay/StepOverlay.tsx +62 -0
- package/src/components/OverLay/type.ts +21 -0
- package/src/components/ProgressIndicator.tsx +62 -0
- package/src/components/SelfieCapture.tsx +244 -0
- package/src/components/SimpleExample.tsx +92 -0
- package/src/components/Svgs/GpsIcon.tsx +12 -0
- package/src/components/Svgs/Schield.tsx +26 -0
- package/src/components/Svgs/directionArrow.gif +0 -0
- package/src/components/Svgs/frontSelfieIcon.tsx +13 -0
- package/src/components/Svgs/scanningLine.tsx +88 -0
- package/src/components/Svgs/sideSelfieIcon.tsx +10 -0
- package/src/components/TemplateKYCExample.tsx +447 -0
- package/src/components/TemplateKYCFlowRefactored.tsx +263 -0
- package/src/components/VisionCameraView.tsx +197 -0
- package/src/components/example/CameraCaptureEx.tsx +335 -0
- package/src/components/example/CameraCaptureExAdvanced.tsx +357 -0
- package/src/components/example/CameraCaptureExScan.tsx +336 -0
- package/src/components/example/CameraCaptureExSimple.tsx +215 -0
- package/src/components/example/OrientationVideoExample.tsx +384 -0
- package/src/components/example/SelfieCaptureEx.tsx +358 -0
- package/src/components/ui/Button.tsx +328 -0
- package/src/components/ui/ButtonExample.tsx +318 -0
- package/src/components/ui/ButtonStyles.ts +465 -0
- package/src/config/KYCConfigs.ts +528 -0
- package/src/hooks/useKYC.ts +131 -0
- package/src/hooks/useKYCFlow.ts +248 -0
- package/src/hooks/useLocation.ts +221 -0
- package/src/hooks/useOrientationVideo.ts +148 -0
- package/src/hooks/useTemplateKYCFlow.tsx +292 -0
- package/src/index.ts +72 -0
- package/src/modules/api/KYCService.ts +171 -0
- package/src/modules/camera/NativeCameraModule.ts +170 -0
- package/src/modules/camera/UnifiedCameraModule.ts +160 -0
- package/src/modules/camera/VisionCameraModule.ts +217 -0
- package/src/modules/camera/VisionCameraModule.web.ts +661 -0
- package/src/modules/camera/index.ts +6 -0
- package/src/stores/kycStore.ts +161 -0
- package/src/types/KYC.types.ts +434 -0
- package/src/types/nativewind.d.ts +2 -0
|
@@ -0,0 +1,570 @@
|
|
|
1
|
+
import { Platform } from 'react-native';
|
|
2
|
+
export class VisionCameraModule {
|
|
3
|
+
static instance;
|
|
4
|
+
videoElement = null;
|
|
5
|
+
canvasElement = null;
|
|
6
|
+
stream = null;
|
|
7
|
+
isCameraActive = false;
|
|
8
|
+
static getInstance() {
|
|
9
|
+
if (!VisionCameraModule.instance) {
|
|
10
|
+
VisionCameraModule.instance = new VisionCameraModule();
|
|
11
|
+
}
|
|
12
|
+
return VisionCameraModule.instance;
|
|
13
|
+
}
|
|
14
|
+
constructor() {
|
|
15
|
+
console.log('VisionCameraModule.web constructor called');
|
|
16
|
+
console.log('Platform:', Platform.OS);
|
|
17
|
+
// Créer les éléments DOM nécessaires
|
|
18
|
+
this.createVideoElements();
|
|
19
|
+
}
|
|
20
|
+
createVideoElements() {
|
|
21
|
+
// Créer un élément vidéo caché pour la capture
|
|
22
|
+
this.videoElement = document.createElement('video');
|
|
23
|
+
this.videoElement.style.position = 'absolute';
|
|
24
|
+
this.videoElement.style.left = '-9999px';
|
|
25
|
+
this.videoElement.style.top = '-9999px';
|
|
26
|
+
this.videoElement.autoplay = true;
|
|
27
|
+
this.videoElement.muted = true;
|
|
28
|
+
this.videoElement.playsInline = true;
|
|
29
|
+
// Créer un canvas caché pour la capture d'image
|
|
30
|
+
this.canvasElement = document.createElement('canvas');
|
|
31
|
+
this.canvasElement.style.position = 'absolute';
|
|
32
|
+
this.canvasElement.style.left = '-9999px';
|
|
33
|
+
this.canvasElement.style.top = '-9999px';
|
|
34
|
+
// Ajouter les éléments au DOM
|
|
35
|
+
document.body.appendChild(this.videoElement);
|
|
36
|
+
document.body.appendChild(this.canvasElement);
|
|
37
|
+
}
|
|
38
|
+
/**
|
|
39
|
+
* Get available camera devices (web simulation)
|
|
40
|
+
*/
|
|
41
|
+
async getCameraDevices() {
|
|
42
|
+
try {
|
|
43
|
+
if (!navigator.mediaDevices || !navigator.mediaDevices.enumerateDevices) {
|
|
44
|
+
return [];
|
|
45
|
+
}
|
|
46
|
+
const devices = await navigator.mediaDevices.enumerateDevices();
|
|
47
|
+
const videoDevices = devices.filter(device => device.kind === 'videoinput');
|
|
48
|
+
return videoDevices.map((device, index) => ({
|
|
49
|
+
id: device.deviceId || `web_camera_${index}`,
|
|
50
|
+
name: device.label || `Camera ${index + 1}`,
|
|
51
|
+
position: index === 0 ? 'front' : 'back', // Première caméra = front, autres = back
|
|
52
|
+
hasFlash: false,
|
|
53
|
+
hasTorch: false,
|
|
54
|
+
supportsLowLightBoost: false,
|
|
55
|
+
supportsFocus: true,
|
|
56
|
+
supportsVideoStabilization: false,
|
|
57
|
+
supportsVideoHDR: false,
|
|
58
|
+
supportsPhotoHDR: false,
|
|
59
|
+
supportsDepthCapture: false,
|
|
60
|
+
supportsPortraitEffectsMatteDelivery: false,
|
|
61
|
+
supportsRawCapture: false,
|
|
62
|
+
supportsZoom: true,
|
|
63
|
+
}));
|
|
64
|
+
}
|
|
65
|
+
catch (error) {
|
|
66
|
+
console.error('Error getting camera devices:', error);
|
|
67
|
+
return [];
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
/**
|
|
71
|
+
* Get the best available device for selfies (front camera)
|
|
72
|
+
*/
|
|
73
|
+
async getFrontCameraDevice() {
|
|
74
|
+
try {
|
|
75
|
+
const devices = await this.getCameraDevices();
|
|
76
|
+
const frontCamera = devices.find(device => device.position === 'front');
|
|
77
|
+
return frontCamera || null;
|
|
78
|
+
}
|
|
79
|
+
catch (error) {
|
|
80
|
+
console.error('Error getting front camera:', error);
|
|
81
|
+
return null;
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
/**
|
|
85
|
+
* Get the best available device for document capture (back camera)
|
|
86
|
+
*/
|
|
87
|
+
async getBackCameraDevice() {
|
|
88
|
+
try {
|
|
89
|
+
const devices = await this.getCameraDevices();
|
|
90
|
+
const backCamera = devices.find(device => device.position === 'back');
|
|
91
|
+
return backCamera || null;
|
|
92
|
+
}
|
|
93
|
+
catch (error) {
|
|
94
|
+
console.error('Error getting back camera:', error);
|
|
95
|
+
return null;
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
/**
|
|
99
|
+
* Request camera permissions
|
|
100
|
+
*/
|
|
101
|
+
async requestCameraPermission() {
|
|
102
|
+
try {
|
|
103
|
+
if (!navigator.mediaDevices || !navigator.mediaDevices.getUserMedia) {
|
|
104
|
+
console.warn('getUserMedia not supported');
|
|
105
|
+
return false;
|
|
106
|
+
}
|
|
107
|
+
const stream = await navigator.mediaDevices.getUserMedia({
|
|
108
|
+
video: {
|
|
109
|
+
facingMode: 'user',
|
|
110
|
+
width: { ideal: 1280 },
|
|
111
|
+
height: { ideal: 720 }
|
|
112
|
+
}
|
|
113
|
+
});
|
|
114
|
+
// Libérer le stream de test
|
|
115
|
+
stream.getTracks().forEach(track => track.stop());
|
|
116
|
+
return true;
|
|
117
|
+
}
|
|
118
|
+
catch (error) {
|
|
119
|
+
console.error('Error requesting camera permission:', error);
|
|
120
|
+
return false;
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
/**
|
|
124
|
+
* Request microphone permissions
|
|
125
|
+
*/
|
|
126
|
+
async requestMicrophonePermission() {
|
|
127
|
+
try {
|
|
128
|
+
if (!navigator.mediaDevices || !navigator.mediaDevices.getUserMedia) {
|
|
129
|
+
console.warn('getUserMedia not supported');
|
|
130
|
+
return false;
|
|
131
|
+
}
|
|
132
|
+
const stream = await navigator.mediaDevices.getUserMedia({ audio: true });
|
|
133
|
+
// Libérer le stream de test
|
|
134
|
+
stream.getTracks().forEach(track => track.stop());
|
|
135
|
+
return true;
|
|
136
|
+
}
|
|
137
|
+
catch (error) {
|
|
138
|
+
console.error('Error requesting microphone permission:', error);
|
|
139
|
+
return false;
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
/**
|
|
143
|
+
* Get current permission status
|
|
144
|
+
*/
|
|
145
|
+
async getPermissionStatus() {
|
|
146
|
+
try {
|
|
147
|
+
const cameraGranted = await this.requestCameraPermission();
|
|
148
|
+
const microphoneGranted = await this.requestMicrophonePermission();
|
|
149
|
+
return {
|
|
150
|
+
camera: cameraGranted ? 'granted' : 'denied',
|
|
151
|
+
microphone: microphoneGranted ? 'granted' : 'denied',
|
|
152
|
+
};
|
|
153
|
+
}
|
|
154
|
+
catch (error) {
|
|
155
|
+
console.error('Error getting permission status:', error);
|
|
156
|
+
return {
|
|
157
|
+
camera: 'denied',
|
|
158
|
+
microphone: 'denied',
|
|
159
|
+
};
|
|
160
|
+
}
|
|
161
|
+
}
|
|
162
|
+
/**
|
|
163
|
+
* Check if all required permissions are granted
|
|
164
|
+
*/
|
|
165
|
+
async hasAllPermissions() {
|
|
166
|
+
try {
|
|
167
|
+
const status = await this.getPermissionStatus();
|
|
168
|
+
return status.camera === 'granted' && status.microphone === 'granted';
|
|
169
|
+
}
|
|
170
|
+
catch (error) {
|
|
171
|
+
console.error('Error checking permissions:', error);
|
|
172
|
+
return false;
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
/**
|
|
176
|
+
* Request all required permissions
|
|
177
|
+
*/
|
|
178
|
+
async requestAllPermissions() {
|
|
179
|
+
try {
|
|
180
|
+
const [cameraGranted, microphoneGranted] = await Promise.all([
|
|
181
|
+
this.requestCameraPermission(),
|
|
182
|
+
this.requestMicrophonePermission(),
|
|
183
|
+
]);
|
|
184
|
+
return cameraGranted && microphoneGranted;
|
|
185
|
+
}
|
|
186
|
+
catch (error) {
|
|
187
|
+
console.error('Error requesting permissions:', error);
|
|
188
|
+
return false;
|
|
189
|
+
}
|
|
190
|
+
}
|
|
191
|
+
/**
|
|
192
|
+
* Check if camera is available
|
|
193
|
+
*/
|
|
194
|
+
async isCameraAvailable() {
|
|
195
|
+
try {
|
|
196
|
+
if (Platform.OS === 'web') {
|
|
197
|
+
const devices = await this.getCameraDevices();
|
|
198
|
+
return devices.length > 0;
|
|
199
|
+
}
|
|
200
|
+
return false; // Sur le web, on utilise notre implémentation
|
|
201
|
+
}
|
|
202
|
+
catch (error) {
|
|
203
|
+
console.error('Error checking camera availability:', error);
|
|
204
|
+
return false;
|
|
205
|
+
}
|
|
206
|
+
}
|
|
207
|
+
/**
|
|
208
|
+
* Process photo capture result
|
|
209
|
+
*/
|
|
210
|
+
processPhotoResult(photo) {
|
|
211
|
+
try {
|
|
212
|
+
return {
|
|
213
|
+
success: true,
|
|
214
|
+
path: photo.path,
|
|
215
|
+
};
|
|
216
|
+
}
|
|
217
|
+
catch (error) {
|
|
218
|
+
console.error('Error processing photo result:', error);
|
|
219
|
+
return {
|
|
220
|
+
success: false,
|
|
221
|
+
error: error instanceof Error ? error.message : 'Unknown error processing photo',
|
|
222
|
+
};
|
|
223
|
+
}
|
|
224
|
+
}
|
|
225
|
+
/**
|
|
226
|
+
* Legacy method for backward compatibility
|
|
227
|
+
* @deprecated Use VisionCameraView component instead
|
|
228
|
+
*/
|
|
229
|
+
async openCameraWithInstructions(instructions) {
|
|
230
|
+
console.warn('openCameraWithInstructions is deprecated. Use VisionCameraView component instead.');
|
|
231
|
+
try {
|
|
232
|
+
const hasPermissions = await this.requestAllPermissions();
|
|
233
|
+
if (!hasPermissions) {
|
|
234
|
+
return {
|
|
235
|
+
success: false,
|
|
236
|
+
error: 'Camera permissions not granted',
|
|
237
|
+
};
|
|
238
|
+
}
|
|
239
|
+
const isAvailable = await this.isCameraAvailable();
|
|
240
|
+
if (!isAvailable) {
|
|
241
|
+
return {
|
|
242
|
+
success: false,
|
|
243
|
+
error: 'Camera not available',
|
|
244
|
+
};
|
|
245
|
+
}
|
|
246
|
+
// Démarrer la caméra
|
|
247
|
+
await this.startCamera();
|
|
248
|
+
// Créer une interface utilisateur pour la capture
|
|
249
|
+
const captureResult = await this.showCameraInterface(instructions);
|
|
250
|
+
// Arrêter la caméra
|
|
251
|
+
await this.stopCamera();
|
|
252
|
+
return captureResult;
|
|
253
|
+
}
|
|
254
|
+
catch (error) {
|
|
255
|
+
console.error('Error in openCameraWithInstructions:', error);
|
|
256
|
+
await this.stopCamera();
|
|
257
|
+
return {
|
|
258
|
+
success: false,
|
|
259
|
+
error: error instanceof Error ? error.message : 'Unknown error',
|
|
260
|
+
};
|
|
261
|
+
}
|
|
262
|
+
}
|
|
263
|
+
/**
|
|
264
|
+
* Démarre la caméra
|
|
265
|
+
*/
|
|
266
|
+
async startCamera() {
|
|
267
|
+
try {
|
|
268
|
+
if (this.isCameraActive) {
|
|
269
|
+
return;
|
|
270
|
+
}
|
|
271
|
+
this.stream = await navigator.mediaDevices.getUserMedia({
|
|
272
|
+
video: {
|
|
273
|
+
facingMode: 'user',
|
|
274
|
+
width: { ideal: 1280 },
|
|
275
|
+
height: { ideal: 720 }
|
|
276
|
+
}
|
|
277
|
+
});
|
|
278
|
+
if (this.videoElement) {
|
|
279
|
+
this.videoElement.srcObject = this.stream;
|
|
280
|
+
await this.videoElement.play();
|
|
281
|
+
this.isCameraActive = true;
|
|
282
|
+
}
|
|
283
|
+
}
|
|
284
|
+
catch (error) {
|
|
285
|
+
console.error('Error starting camera:', error);
|
|
286
|
+
throw error;
|
|
287
|
+
}
|
|
288
|
+
}
|
|
289
|
+
/**
|
|
290
|
+
* Arrête la caméra
|
|
291
|
+
*/
|
|
292
|
+
async stopCamera() {
|
|
293
|
+
try {
|
|
294
|
+
if (this.stream) {
|
|
295
|
+
this.stream.getTracks().forEach(track => track.stop());
|
|
296
|
+
this.stream = null;
|
|
297
|
+
}
|
|
298
|
+
if (this.videoElement) {
|
|
299
|
+
this.videoElement.srcObject = null;
|
|
300
|
+
}
|
|
301
|
+
this.isCameraActive = false;
|
|
302
|
+
}
|
|
303
|
+
catch (error) {
|
|
304
|
+
console.error('Error stopping camera:', error);
|
|
305
|
+
}
|
|
306
|
+
}
|
|
307
|
+
/**
|
|
308
|
+
* Affiche l'interface de la caméra
|
|
309
|
+
*/
|
|
310
|
+
async showCameraInterface(instructions) {
|
|
311
|
+
return new Promise((resolve) => {
|
|
312
|
+
// Créer l'interface utilisateur
|
|
313
|
+
const overlay = this.createCameraOverlay(instructions);
|
|
314
|
+
// Ajouter au DOM
|
|
315
|
+
document.body.appendChild(overlay);
|
|
316
|
+
// Gérer la capture
|
|
317
|
+
const captureButton = overlay.querySelector('.capture-btn');
|
|
318
|
+
const cancelButton = overlay.querySelector('.cancel-btn');
|
|
319
|
+
captureButton.addEventListener('click', async () => {
|
|
320
|
+
const result = await this.captureImage();
|
|
321
|
+
document.body.removeChild(overlay);
|
|
322
|
+
resolve(result);
|
|
323
|
+
});
|
|
324
|
+
cancelButton.addEventListener('click', () => {
|
|
325
|
+
document.body.removeChild(overlay);
|
|
326
|
+
resolve({
|
|
327
|
+
success: false,
|
|
328
|
+
error: 'Capture cancelled by user'
|
|
329
|
+
});
|
|
330
|
+
});
|
|
331
|
+
});
|
|
332
|
+
}
|
|
333
|
+
/**
|
|
334
|
+
* Crée l'overlay de la caméra
|
|
335
|
+
*/
|
|
336
|
+
createCameraOverlay(instructions) {
|
|
337
|
+
const overlay = document.createElement('div');
|
|
338
|
+
overlay.style.cssText = `
|
|
339
|
+
position: fixed;
|
|
340
|
+
top: 0;
|
|
341
|
+
left: 0;
|
|
342
|
+
width: 100vw;
|
|
343
|
+
height: 100vh;
|
|
344
|
+
background: rgba(0, 0, 0, 0.9);
|
|
345
|
+
z-index: 10000;
|
|
346
|
+
display: flex;
|
|
347
|
+
flex-direction: column;
|
|
348
|
+
align-items: center;
|
|
349
|
+
justify-content: center;
|
|
350
|
+
font-family: Arial, sans-serif;
|
|
351
|
+
color: white;
|
|
352
|
+
`;
|
|
353
|
+
// Instructions
|
|
354
|
+
const instructionsDiv = document.createElement('div');
|
|
355
|
+
instructionsDiv.style.cssText = `
|
|
356
|
+
text-align: center;
|
|
357
|
+
margin-bottom: 20px;
|
|
358
|
+
padding: 20px;
|
|
359
|
+
background: rgba(255, 255, 255, 0.1);
|
|
360
|
+
border-radius: 10px;
|
|
361
|
+
max-width: 400px;
|
|
362
|
+
`;
|
|
363
|
+
instructionsDiv.innerHTML = `
|
|
364
|
+
<h3 style="margin: 0 0 10px 0;">Instructions</h3>
|
|
365
|
+
<p style="margin: 0;">${instructions}</p>
|
|
366
|
+
`;
|
|
367
|
+
// Aperçu vidéo
|
|
368
|
+
const videoPreview = document.createElement('div');
|
|
369
|
+
videoPreview.style.cssText = `
|
|
370
|
+
width: 400px;
|
|
371
|
+
height: 300px;
|
|
372
|
+
background: #000;
|
|
373
|
+
border-radius: 10px;
|
|
374
|
+
margin-bottom: 20px;
|
|
375
|
+
overflow: hidden;
|
|
376
|
+
position: relative;
|
|
377
|
+
`;
|
|
378
|
+
if (this.videoElement) {
|
|
379
|
+
this.videoElement.style.cssText = `
|
|
380
|
+
position: relative;
|
|
381
|
+
width: 100%;
|
|
382
|
+
height: 100%;
|
|
383
|
+
object-fit: cover;
|
|
384
|
+
`;
|
|
385
|
+
videoPreview.appendChild(this.videoElement);
|
|
386
|
+
}
|
|
387
|
+
// Boutons
|
|
388
|
+
const buttonContainer = document.createElement('div');
|
|
389
|
+
buttonContainer.style.cssText = `
|
|
390
|
+
display: flex;
|
|
391
|
+
gap: 20px;
|
|
392
|
+
`;
|
|
393
|
+
const captureBtn = document.createElement('button');
|
|
394
|
+
captureBtn.className = 'capture-btn';
|
|
395
|
+
captureBtn.textContent = '📸 Capturer';
|
|
396
|
+
captureBtn.style.cssText = `
|
|
397
|
+
padding: 15px 30px;
|
|
398
|
+
font-size: 16px;
|
|
399
|
+
background: #007AFF;
|
|
400
|
+
color: white;
|
|
401
|
+
border: none;
|
|
402
|
+
border-radius: 25px;
|
|
403
|
+
cursor: pointer;
|
|
404
|
+
font-weight: bold;
|
|
405
|
+
`;
|
|
406
|
+
const cancelBtn = document.createElement('button');
|
|
407
|
+
cancelBtn.className = 'cancel-btn';
|
|
408
|
+
cancelBtn.textContent = '❌ Annuler';
|
|
409
|
+
cancelBtn.style.cssText = `
|
|
410
|
+
padding: 15px 30px;
|
|
411
|
+
font-size: 16px;
|
|
412
|
+
background: #FF3B30;
|
|
413
|
+
color: white;
|
|
414
|
+
border: none;
|
|
415
|
+
border-radius: 25px;
|
|
416
|
+
cursor: pointer;
|
|
417
|
+
font-weight: bold;
|
|
418
|
+
`;
|
|
419
|
+
buttonContainer.appendChild(captureBtn);
|
|
420
|
+
buttonContainer.appendChild(cancelBtn);
|
|
421
|
+
overlay.appendChild(instructionsDiv);
|
|
422
|
+
overlay.appendChild(videoPreview);
|
|
423
|
+
overlay.appendChild(buttonContainer);
|
|
424
|
+
return overlay;
|
|
425
|
+
}
|
|
426
|
+
/**
|
|
427
|
+
* Capture une image depuis la vidéo
|
|
428
|
+
*/
|
|
429
|
+
async captureImage() {
|
|
430
|
+
try {
|
|
431
|
+
if (!this.videoElement || !this.canvasElement) {
|
|
432
|
+
return {
|
|
433
|
+
success: false,
|
|
434
|
+
error: 'Video or canvas element not available'
|
|
435
|
+
};
|
|
436
|
+
}
|
|
437
|
+
// Configurer le canvas
|
|
438
|
+
this.canvasElement.width = this.videoElement.videoWidth;
|
|
439
|
+
this.canvasElement.height = this.videoElement.videoHeight;
|
|
440
|
+
// Dessiner la frame actuelle sur le canvas
|
|
441
|
+
const context = this.canvasElement.getContext('2d');
|
|
442
|
+
if (!context) {
|
|
443
|
+
return {
|
|
444
|
+
success: false,
|
|
445
|
+
error: 'Canvas context not available'
|
|
446
|
+
};
|
|
447
|
+
}
|
|
448
|
+
context.drawImage(this.videoElement, 0, 0);
|
|
449
|
+
// Convertir en base64
|
|
450
|
+
const imageDataUrl = this.canvasElement.toDataURL('image/jpeg', 0.8);
|
|
451
|
+
// Créer un nom de fichier unique
|
|
452
|
+
const timestamp = new Date().getTime();
|
|
453
|
+
const filename = `web_capture_${timestamp}.jpg`;
|
|
454
|
+
console.log('imageDataUrl', imageDataUrl, filename);
|
|
455
|
+
return {
|
|
456
|
+
success: true,
|
|
457
|
+
path: imageDataUrl,
|
|
458
|
+
};
|
|
459
|
+
}
|
|
460
|
+
catch (error) {
|
|
461
|
+
console.error('Error capturing image:', error);
|
|
462
|
+
return {
|
|
463
|
+
success: false,
|
|
464
|
+
error: error instanceof Error ? error.message : 'Unknown error'
|
|
465
|
+
};
|
|
466
|
+
}
|
|
467
|
+
}
|
|
468
|
+
/**
|
|
469
|
+
* Test simple du module web
|
|
470
|
+
*/
|
|
471
|
+
async testModule() {
|
|
472
|
+
try {
|
|
473
|
+
const hasCamera = await this.isCameraAvailable();
|
|
474
|
+
if (hasCamera) {
|
|
475
|
+
return 'Web VisionCameraModule working';
|
|
476
|
+
}
|
|
477
|
+
else {
|
|
478
|
+
return 'No camera available';
|
|
479
|
+
}
|
|
480
|
+
}
|
|
481
|
+
catch (error) {
|
|
482
|
+
console.error('Error testing web module:', error);
|
|
483
|
+
return 'Test failed';
|
|
484
|
+
}
|
|
485
|
+
}
|
|
486
|
+
/**
|
|
487
|
+
* Ouvre le sélecteur de fichiers
|
|
488
|
+
*/
|
|
489
|
+
async openFilePicker(allowedTypes = ['*/*']) {
|
|
490
|
+
try {
|
|
491
|
+
// Créer un input file caché
|
|
492
|
+
const input = document.createElement('input');
|
|
493
|
+
input.type = 'file';
|
|
494
|
+
input.accept = allowedTypes.join(',');
|
|
495
|
+
input.style.position = 'absolute';
|
|
496
|
+
input.style.left = '-9999px';
|
|
497
|
+
input.style.top = '-9999px';
|
|
498
|
+
document.body.appendChild(input);
|
|
499
|
+
return new Promise((resolve) => {
|
|
500
|
+
input.onchange = (event) => {
|
|
501
|
+
const target = event.target;
|
|
502
|
+
const file = target.files?.[0];
|
|
503
|
+
if (file) {
|
|
504
|
+
const reader = new FileReader();
|
|
505
|
+
reader.onload = () => {
|
|
506
|
+
const result = reader.result;
|
|
507
|
+
document.body.removeChild(input);
|
|
508
|
+
resolve({
|
|
509
|
+
success: true,
|
|
510
|
+
uri: result,
|
|
511
|
+
path: result
|
|
512
|
+
});
|
|
513
|
+
};
|
|
514
|
+
reader.readAsDataURL(file);
|
|
515
|
+
}
|
|
516
|
+
else {
|
|
517
|
+
document.body.removeChild(input);
|
|
518
|
+
resolve({
|
|
519
|
+
success: false,
|
|
520
|
+
error: 'No file selected'
|
|
521
|
+
});
|
|
522
|
+
}
|
|
523
|
+
};
|
|
524
|
+
input.click();
|
|
525
|
+
});
|
|
526
|
+
}
|
|
527
|
+
catch (error) {
|
|
528
|
+
console.error('Error opening file picker:', error);
|
|
529
|
+
return {
|
|
530
|
+
success: false,
|
|
531
|
+
error: error instanceof Error ? error.message : 'Unknown error'
|
|
532
|
+
};
|
|
533
|
+
}
|
|
534
|
+
}
|
|
535
|
+
/**
|
|
536
|
+
* Écoute les événements de la caméra (simulation pour le web)
|
|
537
|
+
*/
|
|
538
|
+
onCameraCapture(callback) {
|
|
539
|
+
console.log('onCameraCapture listener added (web simulation)');
|
|
540
|
+
return { remove: () => { } };
|
|
541
|
+
}
|
|
542
|
+
/**
|
|
543
|
+
* Écoute les événements de sélection de fichiers (simulation pour le web)
|
|
544
|
+
*/
|
|
545
|
+
onFileSelected(callback) {
|
|
546
|
+
console.log('onFileSelected listener added (web simulation)');
|
|
547
|
+
return { remove: () => { } };
|
|
548
|
+
}
|
|
549
|
+
/**
|
|
550
|
+
* Écoute les erreurs (simulation pour le web)
|
|
551
|
+
*/
|
|
552
|
+
onError(callback) {
|
|
553
|
+
console.log('onError listener added (web simulation)');
|
|
554
|
+
return { remove: () => { } };
|
|
555
|
+
}
|
|
556
|
+
/**
|
|
557
|
+
* Nettoyage des ressources
|
|
558
|
+
*/
|
|
559
|
+
destroy() {
|
|
560
|
+
this.stopCamera();
|
|
561
|
+
if (this.videoElement && this.videoElement.parentNode) {
|
|
562
|
+
this.videoElement.parentNode.removeChild(this.videoElement);
|
|
563
|
+
}
|
|
564
|
+
if (this.canvasElement && this.canvasElement.parentNode) {
|
|
565
|
+
this.canvasElement.parentNode.removeChild(this.canvasElement);
|
|
566
|
+
}
|
|
567
|
+
}
|
|
568
|
+
}
|
|
569
|
+
export default VisionCameraModule.getInstance();
|
|
570
|
+
//# sourceMappingURL=VisionCameraModule.web.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"VisionCameraModule.web.js","sourceRoot":"","sources":["../../../src/modules/camera/VisionCameraModule.web.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAA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UAAU,CAAC,WAAW,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC;QAC9D,CAAC;QACD,IAAI,IAAI,CAAC,aAAa,IAAI,IAAI,CAAC,aAAa,CAAC,UAAU,EAAE,CAAC;YACxD,IAAI,CAAC,aAAa,CAAC,UAAU,CAAC,WAAW,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC;QAChE,CAAC;IACH,CAAC;CACF;AAED,eAAe,kBAAkB,CAAC,WAAW,EAAE,CAAC","sourcesContent":["import { Platform } from 'react-native';\n\nexport interface CameraCaptureResult {\n success: boolean;\n path?: string;\n error?: string;\n}\n\nexport interface CameraPermissions {\n camera: 'granted' | 'denied' | 'restricted' | 'not-determined';\n microphone: 'granted' | 'denied' | 'restricted' | 'not-determined';\n}\n\nexport interface CameraDevice {\n id: string;\n name: string;\n position: 'front' | 'back';\n hasFlash: boolean;\n hasTorch: boolean;\n supportsLowLightBoost: boolean;\n supportsFocus: boolean;\n supportsVideoStabilization: boolean;\n supportsVideoHDR: boolean;\n supportsPhotoHDR: boolean;\n supportsDepthCapture: boolean;\n supportsPortraitEffectsMatteDelivery: boolean;\n supportsRawCapture: boolean;\n supportsZoom: boolean;\n}\n\nexport interface PhotoFile {\n path: string;\n width: number;\n height: number;\n isRawPhoto: boolean;\n metadata?: any;\n}\n\nexport class VisionCameraModule {\n private static instance: VisionCameraModule;\n private videoElement: HTMLVideoElement | null = null;\n private canvasElement: HTMLCanvasElement | null = null;\n private stream: MediaStream | null = null;\n private isCameraActive = false;\n \n public static getInstance(): VisionCameraModule {\n if (!VisionCameraModule.instance) {\n VisionCameraModule.instance = new VisionCameraModule();\n }\n return VisionCameraModule.instance;\n }\n\n constructor() {\n console.log('VisionCameraModule.web constructor called');\n console.log('Platform:', Platform.OS);\n \n // Créer les éléments DOM nécessaires\n this.createVideoElements();\n }\n\n private createVideoElements() {\n // Créer un élément vidéo caché pour la capture\n this.videoElement = document.createElement('video');\n this.videoElement.style.position = 'absolute';\n this.videoElement.style.left = '-9999px';\n this.videoElement.style.top = '-9999px';\n this.videoElement.autoplay = true;\n this.videoElement.muted = true;\n this.videoElement.playsInline = true;\n\n // Créer un canvas caché pour la capture d'image\n this.canvasElement = document.createElement('canvas');\n this.canvasElement.style.position = 'absolute';\n this.canvasElement.style.left = '-9999px';\n this.canvasElement.style.top = '-9999px';\n\n // Ajouter les éléments au DOM\n document.body.appendChild(this.videoElement);\n document.body.appendChild(this.canvasElement);\n }\n\n /**\n * Get available camera devices (web simulation)\n */\n async getCameraDevices(): Promise<CameraDevice[]> {\n try {\n if (!navigator.mediaDevices || !navigator.mediaDevices.enumerateDevices) {\n return [];\n }\n\n const devices = await navigator.mediaDevices.enumerateDevices();\n const videoDevices = devices.filter(device => device.kind === 'videoinput');\n \n return videoDevices.map((device, index) => ({\n id: device.deviceId || `web_camera_${index}`,\n name: device.label || `Camera ${index + 1}`,\n position: index === 0 ? 'front' : 'back', // Première caméra = front, autres = back\n hasFlash: false,\n hasTorch: false,\n supportsLowLightBoost: false,\n supportsFocus: true,\n supportsVideoStabilization: false,\n supportsVideoHDR: false,\n supportsPhotoHDR: false,\n supportsDepthCapture: false,\n supportsPortraitEffectsMatteDelivery: false,\n supportsRawCapture: false,\n supportsZoom: true,\n }));\n } catch (error) {\n console.error('Error getting camera devices:', error);\n return [];\n }\n }\n\n /**\n * Get the best available device for selfies (front camera)\n */\n async getFrontCameraDevice(): Promise<CameraDevice | null> {\n try {\n const devices = await this.getCameraDevices();\n const frontCamera = devices.find(device => device.position === 'front');\n return frontCamera || null;\n } catch (error) {\n console.error('Error getting front camera:', error);\n return null;\n }\n }\n\n /**\n * Get the best available device for document capture (back camera)\n */\n async getBackCameraDevice(): Promise<CameraDevice | null> {\n try {\n const devices = await this.getCameraDevices();\n const backCamera = devices.find(device => device.position === 'back');\n return backCamera || null;\n } catch (error) {\n console.error('Error getting back camera:', error);\n return null;\n }\n }\n\n /**\n * Request camera permissions\n */\n async requestCameraPermission(): Promise<boolean> {\n try {\n if (!navigator.mediaDevices || !navigator.mediaDevices.getUserMedia) {\n console.warn('getUserMedia not supported');\n return false;\n }\n\n const stream = await navigator.mediaDevices.getUserMedia({ \n video: { \n facingMode: 'user',\n width: { ideal: 1280 },\n height: { ideal: 720 }\n } \n });\n \n // Libérer le stream de test\n stream.getTracks().forEach(track => track.stop());\n \n return true;\n } catch (error) {\n console.error('Error requesting camera permission:', error);\n return false;\n }\n }\n\n /**\n * Request microphone permissions\n */\n async requestMicrophonePermission(): Promise<boolean> {\n try {\n if (!navigator.mediaDevices || !navigator.mediaDevices.getUserMedia) {\n console.warn('getUserMedia not supported');\n return false;\n }\n\n const stream = await navigator.mediaDevices.getUserMedia({ audio: true });\n \n // Libérer le stream de test\n stream.getTracks().forEach(track => track.stop());\n \n return true;\n } catch (error) {\n console.error('Error requesting microphone permission:', error);\n return false;\n }\n }\n\n /**\n * Get current permission status\n */\n async getPermissionStatus(): Promise<CameraPermissions> {\n try {\n const cameraGranted = await this.requestCameraPermission();\n const microphoneGranted = await this.requestMicrophonePermission();\n \n return {\n camera: cameraGranted ? 'granted' : 'denied',\n microphone: microphoneGranted ? 'granted' : 'denied',\n };\n } catch (error) {\n console.error('Error getting permission status:', error);\n return {\n camera: 'denied',\n microphone: 'denied',\n };\n }\n }\n\n /**\n * Check if all required permissions are granted\n */\n async hasAllPermissions(): Promise<boolean> {\n try {\n const status = await this.getPermissionStatus();\n return status.camera === 'granted' && status.microphone === 'granted';\n } catch (error) {\n console.error('Error checking permissions:', error);\n return false;\n }\n }\n\n /**\n * Request all required permissions\n */\n async requestAllPermissions(): Promise<boolean> {\n try {\n const [cameraGranted, microphoneGranted] = await Promise.all([\n this.requestCameraPermission(),\n this.requestMicrophonePermission(),\n ]);\n \n return cameraGranted && microphoneGranted;\n } catch (error) {\n console.error('Error requesting permissions:', error);\n return false;\n }\n }\n\n /**\n * Check if camera is available\n */\n async isCameraAvailable(): Promise<boolean> {\n try {\n if (Platform.OS === 'web') {\n const devices = await this.getCameraDevices();\n return devices.length > 0;\n }\n \n return false; // Sur le web, on utilise notre implémentation\n } catch (error) {\n console.error('Error checking camera availability:', error);\n return false;\n }\n }\n\n /**\n * Process photo capture result\n */\n processPhotoResult(photo: PhotoFile): CameraCaptureResult {\n try {\n return {\n success: true,\n path: photo.path,\n };\n } catch (error) {\n console.error('Error processing photo result:', error);\n return {\n success: false,\n error: error instanceof Error ? error.message : 'Unknown error processing photo',\n };\n }\n }\n\n /**\n * Legacy method for backward compatibility\n * @deprecated Use VisionCameraView component instead\n */\n async openCameraWithInstructions(instructions: string): Promise<CameraCaptureResult> {\n console.warn('openCameraWithInstructions is deprecated. Use VisionCameraView component instead.');\n \n try {\n const hasPermissions = await this.requestAllPermissions();\n if (!hasPermissions) {\n return {\n success: false,\n error: 'Camera permissions not granted',\n };\n }\n\n const isAvailable = await this.isCameraAvailable();\n if (!isAvailable) {\n return {\n success: false,\n error: 'Camera not available',\n };\n }\n\n // Démarrer la caméra\n await this.startCamera();\n\n // Créer une interface utilisateur pour la capture\n const captureResult = await this.showCameraInterface(instructions);\n \n // Arrêter la caméra\n await this.stopCamera();\n\n return captureResult;\n } catch (error) {\n console.error('Error in openCameraWithInstructions:', error);\n await this.stopCamera();\n return {\n success: false,\n error: error instanceof Error ? error.message : 'Unknown error',\n };\n }\n }\n\n /**\n * Démarre la caméra\n */\n private async startCamera(): Promise<void> {\n try {\n if (this.isCameraActive) {\n return;\n }\n\n this.stream = await navigator.mediaDevices.getUserMedia({\n video: {\n facingMode: 'user',\n width: { ideal: 1280 },\n height: { ideal: 720 }\n }\n });\n\n if (this.videoElement) {\n this.videoElement.srcObject = this.stream;\n await this.videoElement.play();\n this.isCameraActive = true;\n }\n } catch (error) {\n console.error('Error starting camera:', error);\n throw error;\n }\n }\n\n /**\n * Arrête la caméra\n */\n private async stopCamera(): Promise<void> {\n try {\n if (this.stream) {\n this.stream.getTracks().forEach(track => track.stop());\n this.stream = null;\n }\n \n if (this.videoElement) {\n this.videoElement.srcObject = null;\n }\n \n this.isCameraActive = false;\n } catch (error) {\n console.error('Error stopping camera:', error);\n }\n }\n\n /**\n * Affiche l'interface de la caméra\n */\n private async showCameraInterface(instructions: string): Promise<CameraCaptureResult> {\n return new Promise((resolve) => {\n // Créer l'interface utilisateur\n const overlay = this.createCameraOverlay(instructions);\n \n // Ajouter au DOM\n document.body.appendChild(overlay);\n\n // Gérer la capture\n const captureButton = overlay.querySelector('.capture-btn') as HTMLButtonElement;\n const cancelButton = overlay.querySelector('.cancel-btn') as HTMLButtonElement;\n\n captureButton.addEventListener('click', async () => {\n const result = await this.captureImage();\n document.body.removeChild(overlay);\n resolve(result);\n });\n\n cancelButton.addEventListener('click', () => {\n document.body.removeChild(overlay);\n resolve({\n success: false,\n error: 'Capture cancelled by user'\n });\n });\n });\n }\n\n /**\n * Crée l'overlay de la caméra\n */\n private createCameraOverlay(instructions: string): HTMLElement {\n const overlay = document.createElement('div');\n overlay.style.cssText = `\n position: fixed;\n top: 0;\n left: 0;\n width: 100vw;\n height: 100vh;\n background: rgba(0, 0, 0, 0.9);\n z-index: 10000;\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n font-family: Arial, sans-serif;\n color: white;\n `;\n\n // Instructions\n const instructionsDiv = document.createElement('div');\n instructionsDiv.style.cssText = `\n text-align: center;\n margin-bottom: 20px;\n padding: 20px;\n background: rgba(255, 255, 255, 0.1);\n border-radius: 10px;\n max-width: 400px;\n `;\n instructionsDiv.innerHTML = `\n <h3 style=\"margin: 0 0 10px 0;\">Instructions</h3>\n <p style=\"margin: 0;\">${instructions}</p>\n `;\n\n // Aperçu vidéo\n const videoPreview = document.createElement('div');\n videoPreview.style.cssText = `\n width: 400px;\n height: 300px;\n background: #000;\n border-radius: 10px;\n margin-bottom: 20px;\n overflow: hidden;\n position: relative;\n `;\n\n if (this.videoElement) {\n this.videoElement.style.cssText = `\n position: relative;\n width: 100%;\n height: 100%;\n object-fit: cover;\n `;\n videoPreview.appendChild(this.videoElement);\n }\n\n // Boutons\n const buttonContainer = document.createElement('div');\n buttonContainer.style.cssText = `\n display: flex;\n gap: 20px;\n `;\n\n const captureBtn = document.createElement('button');\n captureBtn.className = 'capture-btn';\n captureBtn.textContent = '📸 Capturer';\n captureBtn.style.cssText = `\n padding: 15px 30px;\n font-size: 16px;\n background: #007AFF;\n color: white;\n border: none;\n border-radius: 25px;\n cursor: pointer;\n font-weight: bold;\n `;\n\n const cancelBtn = document.createElement('button');\n cancelBtn.className = 'cancel-btn';\n cancelBtn.textContent = '❌ Annuler';\n cancelBtn.style.cssText = `\n padding: 15px 30px;\n font-size: 16px;\n background: #FF3B30;\n color: white;\n border: none;\n border-radius: 25px;\n cursor: pointer;\n font-weight: bold;\n `;\n\n buttonContainer.appendChild(captureBtn);\n buttonContainer.appendChild(cancelBtn);\n\n overlay.appendChild(instructionsDiv);\n overlay.appendChild(videoPreview);\n overlay.appendChild(buttonContainer);\n\n return overlay;\n }\n\n /**\n * Capture une image depuis la vidéo\n */\n private async captureImage(): Promise<CameraCaptureResult> {\n try {\n if (!this.videoElement || !this.canvasElement) {\n return {\n success: false,\n error: 'Video or canvas element not available'\n };\n }\n\n // Configurer le canvas\n this.canvasElement.width = this.videoElement.videoWidth;\n this.canvasElement.height = this.videoElement.videoHeight;\n\n // Dessiner la frame actuelle sur le canvas\n const context = this.canvasElement.getContext('2d');\n if (!context) {\n return {\n success: false,\n error: 'Canvas context not available'\n };\n }\n\n context.drawImage(this.videoElement, 0, 0);\n\n // Convertir en base64\n const imageDataUrl = this.canvasElement.toDataURL('image/jpeg', 0.8);\n \n // Créer un nom de fichier unique\n const timestamp = new Date().getTime();\n const filename = `web_capture_${timestamp}.jpg`;\n console.log('imageDataUrl', imageDataUrl, filename);\n\n return {\n success: true,\n path: imageDataUrl,\n };\n } catch (error) {\n console.error('Error capturing image:', error);\n return {\n success: false,\n error: error instanceof Error ? error.message : 'Unknown error'\n };\n }\n }\n\n /**\n * Test simple du module web\n */\n async testModule(): Promise<string> {\n try {\n const hasCamera = await this.isCameraAvailable();\n if (hasCamera) {\n return 'Web VisionCameraModule working';\n } else {\n return 'No camera available';\n }\n } catch (error) {\n console.error('Error testing web module:', error);\n return 'Test failed';\n }\n }\n\n /**\n * Ouvre le sélecteur de fichiers\n */\n async openFilePicker(allowedTypes: string[] = ['*/*']): Promise<{ success: boolean; uri?: string; path?: string; error?: string }> {\n try {\n // Créer un input file caché\n const input = document.createElement('input');\n input.type = 'file';\n input.accept = allowedTypes.join(',');\n input.style.position = 'absolute';\n input.style.left = '-9999px';\n input.style.top = '-9999px';\n\n document.body.appendChild(input);\n\n return new Promise((resolve) => {\n input.onchange = (event) => {\n const target = event.target as HTMLInputElement;\n const file = target.files?.[0];\n\n if (file) {\n const reader = new FileReader();\n reader.onload = () => {\n const result = reader.result as string;\n document.body.removeChild(input);\n resolve({\n success: true,\n uri: result,\n path: result\n });\n };\n reader.readAsDataURL(file);\n } else {\n document.body.removeChild(input);\n resolve({\n success: false,\n error: 'No file selected'\n });\n }\n };\n\n input.click();\n });\n } catch (error) {\n console.error('Error opening file picker:', error);\n return {\n success: false,\n error: error instanceof Error ? error.message : 'Unknown error'\n };\n }\n }\n\n /**\n * Écoute les événements de la caméra (simulation pour le web)\n */\n onCameraCapture(callback: (event: any) => void) {\n console.log('onCameraCapture listener added (web simulation)');\n return { remove: () => {} };\n }\n\n /**\n * Écoute les événements de sélection de fichiers (simulation pour le web)\n */\n onFileSelected(callback: (event: any) => void) {\n console.log('onFileSelected listener added (web simulation)');\n return { remove: () => {} };\n }\n\n /**\n * Écoute les erreurs (simulation pour le web)\n */\n onError(callback: (event: any) => void) {\n console.log('onError listener added (web simulation)');\n return { remove: () => {} };\n }\n\n /**\n * Nettoyage des ressources\n */\n destroy() {\n this.stopCamera();\n if (this.videoElement && this.videoElement.parentNode) {\n this.videoElement.parentNode.removeChild(this.videoElement);\n }\n if (this.canvasElement && this.canvasElement.parentNode) {\n this.canvasElement.parentNode.removeChild(this.canvasElement);\n }\n }\n}\n\nexport default VisionCameraModule.getInstance();"]}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export { default as NativeCameraModule } from './NativeCameraModule';
|
|
2
|
+
export { default as VisionCameraModule } from './VisionCameraModule';
|
|
3
|
+
export { default as UnifiedCameraModule } from './UnifiedCameraModule';
|
|
4
|
+
export type { CameraCaptureResult, FilePickerResult } from './UnifiedCameraModule';
|
|
5
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/modules/camera/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AACrE,OAAO,EAAE,OAAO,IAAI,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AACrE,OAAO,EAAE,OAAO,IAAI,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAGvE,YAAY,EAAE,mBAAmB,EAAE,gBAAgB,EAAE,MAAM,uBAAuB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/modules/camera/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AACrE,OAAO,EAAE,OAAO,IAAI,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AACrE,OAAO,EAAE,OAAO,IAAI,mBAAmB,EAAE,MAAM,uBAAuB,CAAC","sourcesContent":["export { default as NativeCameraModule } from './NativeCameraModule';\nexport { default as VisionCameraModule } from './VisionCameraModule';\nexport { default as UnifiedCameraModule } from './UnifiedCameraModule';\n\n// Types communs\nexport type { CameraCaptureResult, FilePickerResult } from './UnifiedCameraModule'; "]}
|