diff --git a/README.md b/README.md index cd3f5813..ee912fef 100644 --- a/README.md +++ b/README.md @@ -6,295 +6,24 @@ # Anyline React-Native Plugin -[Anyline](https://www.anyline.io) is mobile OCR SDK, which can be configured by yourself to scan all kinds of numbers, characters, text and codes. +[Anyline](https://anyline.com) is mobile OCR SDK, which can be configured by yourself to scan all kinds of numbers, characters, text and codes. The plugin enables the connection to the SDK via React-Native. - -## Update to >= 5.0 +## File summary +* `example` - Example app source code +* `plugin` - Anyline React Native plugin +* `README.md` - This readme. +* `LICENSE.md` - The license file. -If you use this plugin with a equal or greater version then 5.0, you can use our new Anyline structure, which will provide the whole configuration of every SDK Feature through the config file. If you use the the 'scan' call in your Javascript files, you have to use a new config style. -The old calls with the old configurations will still work. +## Getting Started +Check out our getting-started section here: https://documentation-preview.anyline.com/react-native-plugin-component/43.0.0/getting-started.html -## Requirements: - -### iOS - -Platform >= 12 - - -### Android - -minSDK >= 21 - -## Example - -Take a look into [example/RNExampleApp/src/Result.js](https://github.com/Anyline/anyline-ocr-react-native-module/tree/master/example/RNExampleApp/src/Result.js) to see the implementation. - -## Quick Start Guide - -### 1. Get a License -Get your [trial license](https://anyline.com/free-demos/) to try Anyline inside your app. -Reach out to our sales team to get a [commercial license](https://anyline.com/contact-sales/). - -### 2. Get the Anyline react-native plugin - -Via npm: - -```bash - npm i anyline-ocr-react-native-module -``` - -or download / clone this repository and copy the content of the `plugin` folder into `node_modules` inside a new folder named `anyline-ocr-react-native-module`: - -```bash -project -│ android -│ ios -└─── node_modules - │ ... - └─── anyline-ocr-react-native-module -``` - -Install react-native-cli - - ```bash -npm i -g react-native-cli - ``` - -Link the project. Run as root inside your project root: - - ```bash -react-native link - ``` - -### 3. Get the native Dependencies - -#### Android - -##### Setup Packages - -The package name must match with the bundleID from your Anyline license. - -##### Add the Anyline package - -Open `MainApplication.java` inside your native Android folder of your project: - -Import `AnylinePackage` - -```Java -import com.anyline.reactnative.AnylinePackage; -``` -and add the package to your `getPackages` method - -```Java -@Override - protected List getPackages() { - return Arrays.asList( - new MainReactPackage(), - new AnylinePackage() - ); - } -``` - -##### Add repositories to your app - -You need to add the Anyline and the google repository to your `build.gradle`, so gradle does know, where to find these. - -To do this open `yourApp/android/build.gradle` and add this to allprojects: - -``` -allprojects { - repositories { - ... - google() - maven { - url 'https://anylinesdk.blob.core.windows.net/maven/' - } - } -} -``` - -#### Issues -Strict mode does not allow function declarations in a lexically nested statement. - - http://stackoverflow.com/a/41076153/2157717 - -duplicate files during packaging of APK -``` -packagingOptions { - pickFirst 'lib/armeabi-v7a/libgnustl_shared.so' - pickFirst 'lib/x86/libgnustl_shared.so' -} -``` -#### iOS - -##### Podfile -- Copy the [Podfile](https://github.com/Anyline/anyline-ocr-react-native-module/blob/master/example/RNExampleApp/ios/Podfile) -from our example Project into your native iOS root folder. -- Change the target and project of the Podfile to your project name. -- ```pod update``` - - if you get an error about `node_modules` dependencies initialize your project with `npm install` first. - -##### Permissions -Add camera permissions to `Info.plist` -``` -Privacy - Camera Usage Description -``` -Add also every other permission you want to configure in your `config.js` (vibrate, sound). - -##### Anyline License -Your BundleIdentifier of your app has to match with your bundleID from your Anyline License. - -### 4. Import the plugin into your JavaScript file -```JavaScript -import AnylineOCR from 'anyline-ocr-react-native-module'; -``` -### 5. Import the config file -```JavaScript -import config from './config.js'; -``` -Add and import a JSON file with the proper structure and elements. The JSON config contains: - -1. The license key - -2. Options field with -- AnylineSDK config parameter -- “segment”: which contains the scanModes for the UI Segment (e.g. switch between Analog and Digital) - optional -3. OCR field with (Only if you want to use the OCR module) -- your custom training data -- RegEx validation - -If you want to get detailed information about the config JSON, check out the official [documentation](https://documentation.anyline.io/toc/view_configuration/index.html). - -### 6. Call the Anyline component - -#### Callbacks - -```JavaScript -AnylineOCR.setup( - JSON.stringify(config), - 'scan', - this.onResult, - this.onError - ); -``` - -#### Promise -```JavaScript -const openAnyline = async () => { - ... - - try { - const result = await AnylineOCR.setupPromise(JSON.stringify(config), 'scan'); - } catch(error) { - console.error(error); - } - - ... -} -``` - -##### Deprecated -```JavaScript -AnylineOCR.setupScanViewWithConfigJson( - JSON.stringify(config), - 'scan', - this.onResult, - this.onError - ); -``` - - - -### 7. Add TrainData to the OCR Module -If you are using the `ANYLINE_OCR` module, you'll have to add some `traineddata`. There are some predefined `traineddata` which -you can find in the example app. Also the OCR Config has to reflect the path. Check the VoucherConfig.js in the [example/RNExampleApp/config](https://github.com/Anyline/anyline-ocr-react-native-module/tree/master/example/RNExampleApp/config) folder. - -> __IMPORTANT:__ The trainedFiles have to be directly in the Asset folder in Android. - -#### iOS -``` -ios - └─── myTrainedData.traineddata -``` - -#### Android -``` -android - └─── app - └─── src - └─── main - └─── assets - └─── myTrainedData.traineddata || myTrainedData.any -``` - - -## Props - -| Key | Type | Default | Description | -| --- | --- | --- | --- | -| config | string | \*required | config (JSON String)| -| scanMode | string | \*required | In the new Version, this is always 'scan', and the scanMode is declared through the configuration | -| onResult | function | \*required | The function you pass will be the onResult callback. Use this callback to handle the found scan results. | -| onError | function | \*required | The onError function will be called when the AnylinePlugin encounters an error. Handle the error messages in this method. | - -### config -Stringified JSON with all the configurations, detailed information [here](https://documentation.anyline.io/toc/view_configuration/index.html). - -Keep in mind, that you have to add every permission to your project, you add in the config (vibrateOnResult -> vibration permission) - -### onResult Function -Callback -> Stringified JSON -```JavaScript -{ - reading : 'Result of the Scan', - imagePath : 'path to cropped image', - fullImagePath : 'path to full image', - barcode : 'result of the simultaneous barcode scanning', - scanMode : 'selected scanMode', - meterType : 'meter type' -} -``` -More information about the simultaneous barcode scanning [here](https://documentation.anyline.io/toc/modules/overview.html#anyline-modules-simultaneous-barcode-scanning). - -### onError Function -Callback -> String -- String errorMessage - -## Additional Functions - -#### getLicenseExpiryDate -Get the exparation date of the provided license. Returns a string. -```JavaScript -import AnylineOCR, { getLicenseExpiryDate } from 'anyline-ocr-react-native-module'; - -... - -console.log(getLicenseExpiryDate(myLicenseString)); // 'YYYY-MM-DD' -... -``` - - -## Images - -Keep in mind, all the images are saved in the cache directory of the app. For performance reasons, we only provide the -path as string, so we don't have to transfer the whole image through the bridge. Please be aware, that you should not -use the images in the cache directory for persistent storage, but store the images in a location of your choice for persistence. - -## Get Help (Support) - -We don't actively monitor the Github Issues, please raise a support request using the [Anyline Helpdesk](https://anyline.atlassian.net/servicedesk/customer/portal/2/group/6). -When raising a support request based on this Github Issue, please fill out and include the following information: - -``` -Support request concerning Anyline Github Repository: anyline-ocr-react-native-module -``` - -Thank you! +## Documentation +Check out our developer guide here: https://documentation-preview.anyline.com/react-native-plugin-component/43.0.0/index.html ## License diff --git a/example/RNExampleApp/android/app/.settings/org.eclipse.buildship.core.prefs b/example/RNExampleApp/android/app/.settings/org.eclipse.buildship.core.prefs deleted file mode 100644 index b1886adb..00000000 --- a/example/RNExampleApp/android/app/.settings/org.eclipse.buildship.core.prefs +++ /dev/null @@ -1,2 +0,0 @@ -connection.project.dir=.. -eclipse.preferences.version=1 diff --git a/example/RNExampleApp/android/app/build.gradle b/example/RNExampleApp/android/app/build.gradle index 1b9b5bc6..8802ede2 100644 --- a/example/RNExampleApp/android/app/build.gradle +++ b/example/RNExampleApp/android/app/build.gradle @@ -100,11 +100,11 @@ android { compileSdkVersion rootProject.ext.compileSdkVersion defaultConfig { - applicationId "com.anyline.example.reactnative" + applicationId "com.anyline.examples.reactnative" minSdkVersion rootProject.ext.minSdkVersion targetSdkVersion rootProject.ext.targetSdkVersion versionCode 5 - versionName "42.2.0" + versionName "43.0.0" multiDexEnabled true } diff --git a/example/RNExampleApp/android/app/src/main/AndroidManifest.xml b/example/RNExampleApp/android/app/src/main/AndroidManifest.xml index 8d5eb4a1..bdb3299f 100644 --- a/example/RNExampleApp/android/app/src/main/AndroidManifest.xml +++ b/example/RNExampleApp/android/app/src/main/AndroidManifest.xml @@ -1,30 +1,29 @@ + package="com.anyline.examples.reactnative"> - - + + - - - - - - - + android:roundIcon="@mipmap/ic_launcher_round" + android:theme="@style/AppTheme" + android:usesCleartextTraffic="true"> + + + + + + diff --git a/example/RNExampleApp/android/app/src/main/assets/cow_tag_scanner.ale b/example/RNExampleApp/android/app/src/main/assets/cow.ale similarity index 100% rename from example/RNExampleApp/android/app/src/main/assets/cow_tag_scanner.ale rename to example/RNExampleApp/android/app/src/main/assets/cow.ale diff --git a/example/RNExampleApp/android/app/src/main/java/com/anyline/example/reactnative/MainActivity.java b/example/RNExampleApp/android/app/src/main/java/com/anyline/examples/reactnative/MainActivity.java similarity index 89% rename from example/RNExampleApp/android/app/src/main/java/com/anyline/example/reactnative/MainActivity.java rename to example/RNExampleApp/android/app/src/main/java/com/anyline/examples/reactnative/MainActivity.java index 60c2d8a6..6565b5ab 100644 --- a/example/RNExampleApp/android/app/src/main/java/com/anyline/example/reactnative/MainActivity.java +++ b/example/RNExampleApp/android/app/src/main/java/com/anyline/examples/reactnative/MainActivity.java @@ -1,4 +1,4 @@ -package com.anyline.example.reactnative; +package com.anyline.examples.reactnative; import com.facebook.react.ReactActivity; diff --git a/example/RNExampleApp/android/app/src/main/java/com/anyline/example/reactnative/MainApplication.java b/example/RNExampleApp/android/app/src/main/java/com/anyline/examples/reactnative/MainApplication.java similarity index 96% rename from example/RNExampleApp/android/app/src/main/java/com/anyline/example/reactnative/MainApplication.java rename to example/RNExampleApp/android/app/src/main/java/com/anyline/examples/reactnative/MainApplication.java index d991e3f8..c3477390 100644 --- a/example/RNExampleApp/android/app/src/main/java/com/anyline/example/reactnative/MainApplication.java +++ b/example/RNExampleApp/android/app/src/main/java/com/anyline/examples/reactnative/MainApplication.java @@ -1,4 +1,4 @@ -package com.anyline.example.reactnative; +package com.anyline.examples.reactnative; import android.app.Application; diff --git a/example/RNExampleApp/android/gradle.properties b/example/RNExampleApp/android/gradle.properties index 3f123b00..19f9d1a3 100644 --- a/example/RNExampleApp/android/gradle.properties +++ b/example/RNExampleApp/android/gradle.properties @@ -25,4 +25,6 @@ RELEASE_STORE_PASSWORD=KEYSTORE_PASSWORD RELEASE_KEY_PASSWORD=KEYSTORE_PASSWORD # Version of flipper SDK to use with React Native -FLIPPER_VERSION=0.75.1 \ No newline at end of file +FLIPPER_VERSION=0.75.1 +android.jetifier.ignorelist=moshi-1.14.0 +android.jetifier.blacklist=moshi-1.14.0 \ No newline at end of file diff --git a/example/RNExampleApp/android/gradle/wrapper/gradle-wrapper.jar b/example/RNExampleApp/android/gradle/wrapper/gradle-wrapper.jar deleted file mode 100644 index 01b8bf6b..00000000 Binary files a/example/RNExampleApp/android/gradle/wrapper/gradle-wrapper.jar and /dev/null differ diff --git a/example/RNExampleApp/android/gradlew b/example/RNExampleApp/android/gradlew index cccdd3d5..65dcd68d 100755 --- a/example/RNExampleApp/android/gradlew +++ b/example/RNExampleApp/android/gradlew @@ -1,78 +1,129 @@ -#!/usr/bin/env sh +#!/bin/sh + +# +# Copyright © 2015-2021 the original authors. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# ############################################################################## -## -## Gradle start up script for UN*X -## +# +# Gradle start up script for POSIX generated by Gradle. +# +# Important for running: +# +# (1) You need a POSIX-compliant shell to run this script. If your /bin/sh is +# noncompliant, but you have some other compliant shell such as ksh or +# bash, then to run this script, type that shell name before the whole +# command line, like: +# +# ksh Gradle +# +# Busybox and similar reduced shells will NOT work, because this script +# requires all of these POSIX shell features: +# * functions; +# * expansions «$var», «${var}», «${var:-default}», «${var+SET}», +# «${var#prefix}», «${var%suffix}», and «$( cmd )»; +# * compound commands having a testable exit status, especially «case»; +# * various built-in commands including «command», «set», and «ulimit». +# +# Important for patching: +# +# (2) This script targets any POSIX shell, so it avoids extensions provided +# by Bash, Ksh, etc; in particular arrays are avoided. +# +# The "traditional" practice of packing multiple parameters into a +# space-separated string is a well documented source of bugs and security +# problems, so this is (mostly) avoided, by progressively accumulating +# options in "$@", and eventually passing that to Java. +# +# Where the inherited environment variables (DEFAULT_JVM_OPTS, JAVA_OPTS, +# and GRADLE_OPTS) rely on word-splitting, this is performed explicitly; +# see the in-line comments for details. +# +# There are tweaks for specific operating systems such as AIX, CygWin, +# Darwin, MinGW, and NonStop. +# +# (3) This script is generated from the Groovy template +# https://github.com/gradle/gradle/blob/HEAD/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt +# within the Gradle project. +# +# You can find Gradle at https://github.com/gradle/gradle/. +# ############################################################################## # Attempt to set APP_HOME + # Resolve links: $0 may be a link -PRG="$0" -# Need this for relative symlinks. -while [ -h "$PRG" ] ; do - ls=`ls -ld "$PRG"` - link=`expr "$ls" : '.*-> \(.*\)$'` - if expr "$link" : '/.*' > /dev/null; then - PRG="$link" - else - PRG=`dirname "$PRG"`"/$link" - fi +app_path=$0 + +# Need this for daisy-chained symlinks. +while + APP_HOME=${app_path%"${app_path##*/}"} # leaves a trailing /; empty if no leading path + [ -h "$app_path" ] +do + ls=$( ls -ld "$app_path" ) + link=${ls#*' -> '} + case $link in #( + /*) app_path=$link ;; #( + *) app_path=$APP_HOME$link ;; + esac done -SAVED="`pwd`" -cd "`dirname \"$PRG\"`/" >/dev/null -APP_HOME="`pwd -P`" -cd "$SAVED" >/dev/null -APP_NAME="Gradle" -APP_BASE_NAME=`basename "$0"` +# This is normally unused +# shellcheck disable=SC2034 +APP_BASE_NAME=${0##*/} +APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. -DEFAULT_JVM_OPTS="" +DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"' # Use the maximum available, or set MAX_FD != -1 to use that value. -MAX_FD="maximum" +MAX_FD=maximum warn () { echo "$*" -} +} >&2 die () { echo echo "$*" echo exit 1 -} +} >&2 # OS specific support (must be 'true' or 'false'). cygwin=false msys=false darwin=false nonstop=false -case "`uname`" in - CYGWIN* ) - cygwin=true - ;; - Darwin* ) - darwin=true - ;; - MINGW* ) - msys=true - ;; - NONSTOP* ) - nonstop=true - ;; +case "$( uname )" in #( + CYGWIN* ) cygwin=true ;; #( + Darwin* ) darwin=true ;; #( + MSYS* | MINGW* ) msys=true ;; #( + NONSTOP* ) nonstop=true ;; esac CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar + # Determine the Java command to use to start the JVM. if [ -n "$JAVA_HOME" ] ; then if [ -x "$JAVA_HOME/jre/sh/java" ] ; then # IBM's JDK on AIX uses strange locations for the executables - JAVACMD="$JAVA_HOME/jre/sh/java" + JAVACMD=$JAVA_HOME/jre/sh/java else - JAVACMD="$JAVA_HOME/bin/java" + JAVACMD=$JAVA_HOME/bin/java fi if [ ! -x "$JAVACMD" ] ; then die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME @@ -81,7 +132,7 @@ Please set the JAVA_HOME variable in your environment to match the location of your Java installation." fi else - JAVACMD="java" + JAVACMD=java which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. Please set the JAVA_HOME variable in your environment to match the @@ -89,84 +140,105 @@ location of your Java installation." fi # Increase the maximum file descriptors if we can. -if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then - MAX_FD_LIMIT=`ulimit -H -n` - if [ $? -eq 0 ] ; then - if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then - MAX_FD="$MAX_FD_LIMIT" - fi - ulimit -n $MAX_FD - if [ $? -ne 0 ] ; then - warn "Could not set maximum file descriptor limit: $MAX_FD" - fi - else - warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT" - fi +if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then + case $MAX_FD in #( + max*) + # In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked. + # shellcheck disable=SC3045 + MAX_FD=$( ulimit -H -n ) || + warn "Could not query maximum file descriptor limit" + esac + case $MAX_FD in #( + '' | soft) :;; #( + *) + # In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked. + # shellcheck disable=SC3045 + ulimit -n "$MAX_FD" || + warn "Could not set maximum file descriptor limit to $MAX_FD" + esac fi -# For Darwin, add options to specify how the application appears in the dock -if $darwin; then - GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\"" -fi +# Collect all arguments for the java command, stacking in reverse order: +# * args from the command line +# * the main class name +# * -classpath +# * -D...appname settings +# * --module-path (only if needed) +# * DEFAULT_JVM_OPTS, JAVA_OPTS, and GRADLE_OPTS environment variables. + +# For Cygwin or MSYS, switch paths to Windows format before running java +if "$cygwin" || "$msys" ; then + APP_HOME=$( cygpath --path --mixed "$APP_HOME" ) + CLASSPATH=$( cygpath --path --mixed "$CLASSPATH" ) + + JAVACMD=$( cygpath --unix "$JAVACMD" ) -# For Cygwin, switch paths to Windows format before running java -if $cygwin ; then - APP_HOME=`cygpath --path --mixed "$APP_HOME"` - CLASSPATH=`cygpath --path --mixed "$CLASSPATH"` - JAVACMD=`cygpath --unix "$JAVACMD"` - - # We build the pattern for arguments to be converted via cygpath - ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null` - SEP="" - for dir in $ROOTDIRSRAW ; do - ROOTDIRS="$ROOTDIRS$SEP$dir" - SEP="|" - done - OURCYGPATTERN="(^($ROOTDIRS))" - # Add a user-defined pattern to the cygpath arguments - if [ "$GRADLE_CYGPATTERN" != "" ] ; then - OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)" - fi # Now convert the arguments - kludge to limit ourselves to /bin/sh - i=0 - for arg in "$@" ; do - CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -` - CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option - - if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition - eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"` - else - eval `echo args$i`="\"$arg\"" + for arg do + if + case $arg in #( + -*) false ;; # don't mess with options #( + /?*) t=${arg#/} t=/${t%%/*} # looks like a POSIX filepath + [ -e "$t" ] ;; #( + *) false ;; + esac + then + arg=$( cygpath --path --ignore --mixed "$arg" ) fi - i=$((i+1)) + # Roll the args list around exactly as many times as the number of + # args, so each arg winds up back in the position where it started, but + # possibly modified. + # + # NB: a `for` loop captures its iteration list before it begins, so + # changing the positional parameters here affects neither the number of + # iterations, nor the values presented in `arg`. + shift # remove old arg + set -- "$@" "$arg" # push replacement arg done - case $i in - (0) set -- ;; - (1) set -- "$args0" ;; - (2) set -- "$args0" "$args1" ;; - (3) set -- "$args0" "$args1" "$args2" ;; - (4) set -- "$args0" "$args1" "$args2" "$args3" ;; - (5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;; - (6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;; - (7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;; - (8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;; - (9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;; - esac fi -# Escape application args -save () { - for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done - echo " " -} -APP_ARGS=$(save "$@") - -# Collect all arguments for the java command, following the shell quoting and substitution rules -eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS" - -# by default we should be in the correct project dir, but when run from Finder on Mac, the cwd is wrong -if [ "$(uname)" = "Darwin" ] && [ "$HOME" = "$PWD" ]; then - cd "$(dirname "$0")" +# Collect all arguments for the java command; +# * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of +# shell script including quotes and variable substitutions, so put them in +# double quotes to make sure that they get re-expanded; and +# * put everything else in single quotes, so that it's not re-expanded. + +set -- \ + "-Dorg.gradle.appname=$APP_BASE_NAME" \ + -classpath "$CLASSPATH" \ + org.gradle.wrapper.GradleWrapperMain \ + "$@" + +# Stop when "xargs" is not available. +if ! command -v xargs >/dev/null 2>&1 +then + die "xargs is not available" fi +# Use "xargs" to parse quoted args. +# +# With -n1 it outputs one arg per line, with the quotes and backslashes removed. +# +# In Bash we could simply go: +# +# readarray ARGS < <( xargs -n1 <<<"$var" ) && +# set -- "${ARGS[@]}" "$@" +# +# but POSIX shell has neither arrays nor command substitution, so instead we +# post-process each arg (as a line of input to sed) to backslash-escape any +# character that might be a shell metacharacter, then use eval to reverse +# that process (while maintaining the separation between arguments), and wrap +# the whole thing up as a single "set" statement. +# +# This will of course break if any of these variables contains a newline or +# an unmatched quote. +# + +eval "set -- $( + printf '%s\n' "$DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS" | + xargs -n1 | + sed ' s~[^-[:alnum:]+,./:=@_]~\\&~g; ' | + tr '\n' ' ' + )" '"$@"' + exec "$JAVACMD" "$@" diff --git a/example/RNExampleApp/android/gradlew.bat b/example/RNExampleApp/android/gradlew.bat index 28690fe0..6689b85b 100644 --- a/example/RNExampleApp/android/gradlew.bat +++ b/example/RNExampleApp/android/gradlew.bat @@ -14,7 +14,7 @@ @rem limitations under the License. @rem -@if "%DEBUG%" == "" @echo off +@if "%DEBUG%"=="" @echo off @rem ########################################################################## @rem @rem Gradle startup script for Windows @@ -25,7 +25,8 @@ if "%OS%"=="Windows_NT" setlocal set DIRNAME=%~dp0 -if "%DIRNAME%" == "" set DIRNAME=. +if "%DIRNAME%"=="" set DIRNAME=. +@rem This is normally unused set APP_BASE_NAME=%~n0 set APP_HOME=%DIRNAME% @@ -40,7 +41,7 @@ if defined JAVA_HOME goto findJavaFromJavaHome set JAVA_EXE=java.exe %JAVA_EXE% -version >NUL 2>&1 -if "%ERRORLEVEL%" == "0" goto execute +if %ERRORLEVEL% equ 0 goto execute echo. echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. @@ -75,15 +76,17 @@ set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar :end @rem End local scope for the variables with windows NT shell -if "%ERRORLEVEL%"=="0" goto mainEnd +if %ERRORLEVEL% equ 0 goto mainEnd :fail rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of rem the _cmd.exe /c_ return code! -if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 -exit /b 1 +set EXIT_CODE=%ERRORLEVEL% +if %EXIT_CODE% equ 0 set EXIT_CODE=1 +if not ""=="%GRADLE_EXIT_CONSOLE%" exit %EXIT_CODE% +exit /b %EXIT_CODE% :mainEnd if "%OS%"=="Windows_NT" endlocal -:omega \ No newline at end of file +:omega diff --git a/example/RNExampleApp/config/AnalogDigitalMeterConfig.js b/example/RNExampleApp/config/AnalogDigitalMeterConfig.js new file mode 100644 index 00000000..d6eea77c --- /dev/null +++ b/example/RNExampleApp/config/AnalogDigitalMeterConfig.js @@ -0,0 +1,67 @@ +export default { + license: 'ew0KICAibGljZW5zZUtleVZlcnNpb24iOiAiMy4wIiwNCiAgImRlYnVnUmVwb3J0aW5nIjogInBpbmciLA0KICAibWFqb3JWZXJzaW9uIjogIjM3IiwNCiAgInNjb3BlIjogWw0KICAgICJBTEwiLA0KICAgICJORkMiDQogIF0sDQogICJtYXhEYXlzTm90UmVwb3J0ZWQiOiA1LA0KICAiYWR2YW5jZWRCYXJjb2RlIjogdHJ1ZSwNCiAgIm11bHRpQmFyY29kZSI6IHRydWUsDQogICJzdXBwb3J0ZWRCYXJjb2RlRm9ybWF0cyI6IFsNCiAgICAiQUxMIg0KICBdLA0KICAicGxhdGZvcm0iOiBbDQogICAgImlPUyIsDQogICAgIkFuZHJvaWQiDQogIF0sDQogICJzaG93V2F0ZXJtYXJrIjogdHJ1ZSwNCiAgInRvbGVyYW5jZURheXMiOiAzMCwNCiAgInZhbGlkIjogIjIwMjMtMTItMzEiLA0KICAiaW9zSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0sDQogICJhbmRyb2lkSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0NCn0KSlhUTzVRSmZKa2FtUnR2VDc4QTFadGVhTXVzbmJlTW5HSHl0alZmczlxbUtIeDhCT3ltSGVXc2M2aXpjRExIenhtbklnU0JzS1RRNEdhSENsWCtvMEo2R3VtaFNUWHQrNVVuc1hVQVJ6aGhUdEhTa0l1ZVlRQ0p3dTI3bE9kWlBhNVoxSFNxN24weE9tek1jTjM3R1dsajVzVm9SY2pqaUswYVVnY0M5cDFRT0svK29ZejAvWlR2dXFGVjZUeHdiUHkyc3RqaDhLdS9NaXhtcFZFVmh0eWVzMEU2ZzhNVkdBNmNPU1h4NDVXVzgvR0NUWEpqdFJ6NnM2UFBDYzdYSXhQalFjOVAxdzBtblpFYTdjUHpMS3M0Y3hoYjQwSmluSU5qZXp6MDl1em9kbnZUR3VlSEIwcXIzUWNlVmdkS1JVQzhDc24zNmJLM2NLVmVpOVdTUlVRPT0=', + "options": { + "doneButtonConfig": { + "offset.y": -88 + }, + "segmentConfig": { + "titles": ["Auto", "Dial"], + "modes": ["auto_analog_digital_meter", "dial_meter"], + "offset.y": -24 + }, + "nativeBarcodeScanningFormats": [ + "CODE_128", + "CODE_39", + "QR_CODE", + "PDF_417" + ] + }, + "cameraConfig": { + "captureResolution": "1080p", + "pictureResolution": "1080p" + }, + "flashConfig": { + "mode": "manual_off", + "alignment": "top_left" + }, + "viewPluginConfig": { + "pluginConfig": { + "id": "com.anyline.configs.plugin.auto-meter", + "meterConfig": { + "scanMode": "auto_analog_digital_meter" + }, + "cancelOnResult": true + }, + "cutoutConfig": { + "style": "rect", + "maxWidthPercent": "100%", + "width": 768, + "alignment": "top_half", + "ratioFromSize": { + "width": 9, + "height": 4 + }, + "offset": { + "x": 0, + "y": 80 + }, + "strokeWidth": 2, + "cornerRadius": 4, + "strokeColor": "0099FF", + "outerColor": "000000", + "outerAlpha": 0.3 + }, + "scanFeedbackConfig": { + "style": "contour_rect", + "strokeWidth": 2, + "strokeColor": "0099FF", + "fillColor": "220099FF", + "cornerRadius": 2, + "beepOnResult": true, + "vibrateOnResult": true, + "blinkAnimationOnResult": true, + "redrawTimeout": 200, + "animationDuration": 75 + } + } +} diff --git a/example/RNExampleApp/config/AnalogMeterConfig.js b/example/RNExampleApp/config/AnalogMeterConfig.js deleted file mode 100644 index 8fa2cbe6..00000000 --- a/example/RNExampleApp/config/AnalogMeterConfig.js +++ /dev/null @@ -1,40 +0,0 @@ -export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "720p" - }, - "flash": { - "mode": "manual", - "alignment": "bottom_right", - }, - "viewPlugin": { - "plugin": { - "id": "Meter_ID", - "meterPlugin": { - "scanMode": "AUTO_ANALOG_DIGITAL_METER" - } - }, - "cutoutConfig": { - "style": "rect", - "alignment": "top_half", - "strokeWidth": 2, - "cornerRadius": 4, - "strokeColor": "FFFFFF", - "outerColor": "000000", - "outerAlpha": 0.3, - "feedbackStrokeColor": "0099FF" - }, - "scanFeedback": { - "style": "CONTOUR_RECT", - "strokeColor": "0099FF", - "fillColor": "220099FF", - "blinkOnResult": true, - "beepOnResult": true, - "vibrateOnResult": true - }, - "cancelOnResult": true - }, - "nativeBarcodeEnabled": true - } -} diff --git a/example/RNExampleApp/config/ArabicIdConfig.js b/example/RNExampleApp/config/ArabicIdConfig.js index c29e73c3..b4b6495c 100755 --- a/example/RNExampleApp/config/ArabicIdConfig.js +++ b/example/RNExampleApp/config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JPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera" : { - "captureResolution" : "1080p", - "zoomGesture": true - }, - "flash" : { - "mode": "manual", - "alignment": "bottom_right", - "imageOn": "flash_on", - "imageOff": "flash_off" - }, - "viewPlugin" : { - "plugin":{ - "id":"ID", - "idPlugin": { - "universalIdConfig": { - "alphabet" : "arabic", - "faceDetection": true, - "allowedLayouts": { - "mrz": [], - "idFront": [], - "drivingLicense": [] - }, - "idFront": { - "fullName": {"scanOption": 0, "minConfidence": 60}, - "dateOfBirth": {"scanOption": 0, "minConfidence": 60}, - "placeOfBirth": {"scanOption": 1, "minConfidence": 60}, - "dateOfExpiry": {"scanOption": 1, "minConfidence": 60}, - "documentNumber": {"scanOption": 0, "minConfidence": 60}, - "nationality": {"scanOption": 1, "minConfidence": 60} - }, - "drivingLicense": { - "fullName": {"scanOption": 0, "minConfidence": 60}, - "dateOfBirth": {"scanOption": 0, "minConfidence": 60}, - "placeOfBirth": {"scanOption": 1, "minConfidence": 60}, - "dateOfExpiry": {"scanOption": 1, "minConfidence": 60}, - "documentNumber": {"scanOption": 0, "minConfidence": 60}, - "nationality": {"scanOption": 0, "minConfidence": 60} - } + license: 'ew0KICAibGljZW5zZUtleVZlcnNpb24iOiAiMy4wIiwNCiAgImRlYnVnUmVwb3J0aW5nIjogInBpbmciLA0KICAibWFqb3JWZXJzaW9uIjogIjM3IiwNCiAgInNjb3BlIjogWw0KICAgICJBTEwiLA0KICAgICJORkMiDQogIF0sDQogICJtYXhEYXlzTm90UmVwb3J0ZWQiOiA1LA0KICAiYWR2YW5jZWRCYXJjb2RlIjogdHJ1ZSwNCiAgIm11bHRpQmFyY29kZSI6IHRydWUsDQogICJzdXBwb3J0ZWRCYXJjb2RlRm9ybWF0cyI6IFsNCiAgICAiQUxMIg0KICBdLA0KICAicGxhdGZvcm0iOiBbDQogICAgImlPUyIsDQogICAgIkFuZHJvaWQiDQogIF0sDQogICJzaG93V2F0ZXJtYXJrIjogdHJ1ZSwNCiAgInRvbGVyYW5jZURheXMiOiAzMCwNCiAgInZhbGlkIjogIjIwMjMtMTItMzEiLA0KICAiaW9zSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0sDQogICJhbmRyb2lkSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0NCn0KSlhUTzVRSmZKa2FtUnR2VDc4QTFadGVhTXVzbmJlTW5HSHl0alZmczlxbUtIeDhCT3ltSGVXc2M2aXpjRExIenhtbklnU0JzS1RRNEdhSENsWCtvMEo2R3VtaFNUWHQrNVVuc1hVQVJ6aGhUdEhTa0l1ZVlRQ0p3dTI3bE9kWlBhNVoxSFNxN24weE9tek1jTjM3R1dsajVzVm9SY2pqaUswYVVnY0M5cDFRT0svK29ZejAvWlR2dXFGVjZUeHdiUHkyc3RqaDhLdS9NaXhtcFZFVmh0eWVzMEU2ZzhNVkdBNmNPU1h4NDVXVzgvR0NUWEpqdFJ6NnM2UFBDYzdYSXhQalFjOVAxdzBtblpFYTdjUHpMS3M0Y3hoYjQwSmluSU5qZXp6MDl1em9kbnZUR3VlSEIwcXIzUWNlVmdkS1JVQzhDc24zNmJLM2NLVmVpOVdTUlVRPT0=', + "options": { + }, + "cameraConfig": { + "captureResolution": "1080p" + }, + "flashConfig": { + "mode": "manual", + "alignment": "bottom_left", + "offset": { + "x": 0, + "y": -40 + } + }, + "viewPluginConfig": { + "pluginConfig": { + "id": "com.anyline.configs.plugin.id_mrz_dl_arabic", + "universalIdConfig": { + "allowedLayouts": { + "mrz": [], + "drivingLicense": [], + "idFront": [] + }, + "alphabet": "arabic", + "drivingLicense": { + "surname": { + "scanOption": 0, + "minConfidence": 40 + }, + "givenNames": { + "scanOption": 0, + "minConfidence": 40 + }, + "dateOfBirth": { + "scanOption": 0, + "minConfidence": 50 + }, + "placeOfBirth": { + "scanOption": 1, + "minConfidence": 50 + }, + "dateOfIssue": { + "scanOption": 0, + "minConfidence": 50 + }, + "dateOfExpiry": { + "scanOption": 1, + "minConfidence": 50 + }, + "authority": { + "scanOption": 1, + "minConfidence": 30 + }, + "documentNumber": { + "scanOption": 0, + "minConfidence": 40 + }, + "categories": { + "scanOption": 1, + "minConfidence": 30 + }, + "address": { + "scanOption": 1 + } + }, + "idFront": { + "surname": { + "scanOption": 0, + "minConfidence": 60 + }, + "givenNames": { + "scanOption": 0, + "minConfidence": 60 + }, + "dateOfBirth": { + "scanOption": 0, + "minConfidence": 60 + }, + "placeOfBirth": { + "scanOption": 1, + "minConfidence": 60 + }, + "dateOfExpiry": { + "scanOption": 1, + "minConfidence": 60 + }, + "cardAccessNumber": { + "scanOption": 1, + "minConfidence": 60 + }, + "documentNumber": { + "scanOption": 0, + "minConfidence": 60 + }, + "nationality": { + "scanOption": 1, + "minConfidence": 60 } } }, - "cutoutConfig" : { - "style": "animated_rect", - "maxWidthPercent": "90%", - "maxHeightPercent": "90%", - "alignment": "center", - "strokeWidth": 3, - "cornerRadius": 8, - "strokeColor": "FFFFFF", - "outerColor": "000000", - "outerAlpha": 0.3, - "ratioFromSize" : { - "width": 50, - "height": 31 - }, - "cropPadding": { - "x": -50, - "y": -50 - }, - "cropOffset": { - "x": 0, - "y": 0 - }, - "feedbackStrokeColor": "0099FF" + "cancelOnResult": true + }, + "cutoutConfig": { + "animation": "fade", + "maxWidthPercent": "90%", + "maxHeightPercent": "90%", + "width": 0, + "alignment": "top_half", + "ratioFromSize": { + "width": 86, + "height": 54 }, - "scanFeedback" : { - "style": "CONTOUR_RECT", - "visualFeedbackRedrawTimeout": 100, - "strokeColor": "0099FF", - "fillColor" : "220099FF", - "beepOnResult": true, - "vibrateOnResult": true, - "strokeWidth": 2 + "offset": { + "x": 0, + "y": 60 }, - "cancelOnResult" : true + "cropOffset": { + "x": 0, + "y": 0 + }, + "cropPadding": { + "x": 0, + "y": 0 + }, + "cornerRadius": 4, + "strokeColor": "0099ff", + "strokeWidth": 2, + "outerColor": "000000", + "feedbackStrokeColor": "0099FF", + "outerAlpha": 0.3 + }, + "scanFeedbackConfig": { + "style": "animated_rect", + "strokeWidth": 2, + "strokeColor": "50fa7b", + "fillColor": "4050fa7b", + "cornerRadius": 2, + "beepOnResult": true, + "vibrateOnResult": true, + "blinkAnimationOnResult": true } } - } diff --git a/example/RNExampleApp/config/AutoEnergyConfig.js b/example/RNExampleApp/config/AutoEnergyConfig.js deleted file mode 100755 index f4c3cb15..00000000 --- a/example/RNExampleApp/config/AutoEnergyConfig.js +++ /dev/null @@ -1,39 +0,0 @@ -export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "720p" - }, - "flash": { - "mode": "manual", - "alignment": "bottom_right", - }, - "viewPlugin": { - "plugin": { - "id": "Meter_ID", - "meterPlugin": { - "scanMode": "AUTO_ANALOG_DIGITAL_METER" - } - }, - "cutoutConfig": { - "style": "rect", - "alignment": "top_half", - "strokeWidth": 2, - "cornerRadius": 4, - "strokeColor": "FFFFFF", - "outerColor": "000000", - "outerAlpha": 0.3, - "feedbackStrokeColor": "0099FF" - }, - "scanFeedback": { - "style": "CONTOUR_RECT", - "strokeColor": "0099FF", - "fillColor": "220099FF", - "blinkOnResult": true, - "beepOnResult": true, - "vibrateOnResult": true - }, - "cancelOnResult": true - } - } -} \ No newline at end of file diff --git a/example/RNExampleApp/config/BarcodeConfig.js b/example/RNExampleApp/config/BarcodeConfig.js index d6399d21..f2dcf5b7 100755 --- a/example/RNExampleApp/config/BarcodeConfig.js +++ b/example/RNExampleApp/config/BarcodeConfig.js @@ -1,63 +1,69 @@ export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAog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NsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "1080p" - }, - "flash": { - "mode": "auto", - "alignment": "bottom_right" + license: 'ew0KICAibGljZW5zZUtleVZlcnNpb24iOiAiMy4wIiwNCiAgImRlYnVnUmVwb3J0aW5nIjogInBpbmciLA0KICAibWFqb3JWZXJzaW9uIjogIjM3IiwNCiAgInNjb3BlIjogWw0KICAgICJBTEwiLA0KICAgICJORkMiDQogIF0sDQogICJtYXhEYXlzTm90UmVwb3J0ZWQiOiA1LA0KICAiYWR2YW5jZWRCYXJjb2RlIjogdHJ1ZSwNCiAgIm11bHRpQmFyY29kZSI6IHRydWUsDQogICJzdXBwb3J0ZWRCYXJjb2RlRm9ybWF0cyI6IFsNCiAgICAiQUxMIg0KICBdLA0KICAicGxhdGZvcm0iOiBbDQogICAgImlPUyIsDQogICAgIkFuZHJvaWQiDQogIF0sDQogICJzaG93V2F0ZXJtYXJrIjogdHJ1ZSwNCiAgInRvbGVyYW5jZURheXMiOiAzMCwNCiAgInZhbGlkIjogIjIwMjMtMTItMzEiLA0KICAiaW9zSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0sDQogICJhbmRyb2lkSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0NCn0KSlhUTzVRSmZKa2FtUnR2VDc4QTFadGVhTXVzbmJlTW5HSHl0alZmczlxbUtIeDhCT3ltSGVXc2M2aXpjRExIenhtbklnU0JzS1RRNEdhSENsWCtvMEo2R3VtaFNUWHQrNVVuc1hVQVJ6aGhUdEhTa0l1ZVlRQ0p3dTI3bE9kWlBhNVoxSFNxN24weE9tek1jTjM3R1dsajVzVm9SY2pqaUswYVVnY0M5cDFRT0svK29ZejAvWlR2dXFGVjZUeHdiUHkyc3RqaDhLdS9NaXhtcFZFVmh0eWVzMEU2ZzhNVkdBNmNPU1h4NDVXVzgvR0NUWEpqdFJ6NnM2UFBDYzdYSXhQalFjOVAxdzBtblpFYTdjUHpMS3M0Y3hoYjQwSmluSU5qZXp6MDl1em9kbnZUR3VlSEIwcXIzUWNlVmdkS1JVQzhDc24zNmJLM2NLVmVpOVdTUlVRPT0=', + "viewPluginConfig": { + "pluginConfig": { + "id": "com.anyline.configs.plugin.barcode", + "barcodeConfig": { + "parseAAMVA": false, + "barcodeFormats": [ + "ALL" + ] + }, + "cancelOnResult": true, + "startScanDelay": 1000 }, - "viewPlugin": { - "plugin": { - "id": "Barcode_ID", - "barcodePlugin": { - "barcodeFormatOptions": ["UPC_E", "EAN_13", "UPC_A", "EAN_8", "AZTEC", "CODABAR", "CODE_11", "CODE_32", "CODE_39", "CODE_93", "CODE_128", "DATABAR", "DATA_MATRIX", "GS1_QR_CODE", "GS1_128", "ITF", "ISBT_128", "MSI", "MICRO_QR", "MICRO_PDF", "PDF_417", "POST_UK", - "QR_CODE", "RSS_14", "RSS_EXPANDED", "TRIOPTIC", "USPS_4CB", "US_PLANET", "US_POSTNET"], - "enablePDF417Parsing": true - } + "cutoutConfig": { + "animation": "none", + "maxWidthPercent": "70%", + "maxHeightPercent": "70%", + "alignment": "center", + "ratioFromSize": { + "width": 3, + "height": 2 }, - "cutoutConfig": { - "style": "rect", - "maxWidthPercent": "80%", - "maxHeightPercent": "80%", - "alignment": "center", - "ratioFromSize": { - "width": 100, - "height": 80 - }, - "strokeWidth": 1, - "cornerRadius": 3, - "strokeColor": "FFFFFF", - "outerColor": "000000", - "outerAlpha": 0.3, - "feedbackStrokeColor": "0099FF" + "offset": { + "x": 0, + "y": 0 }, - "scanFeedback": { - "style": "rect", - "strokeColor": "0099FF", - "fillColor": "220099FF", - "animationDuration": 150, - "blinkOnResult": true, - "beepOnResult": true, - "vibrateOnResult": true + "cropOffset": { + "x": 0, + "y": 0 }, - "cancelOnResult": true + "cropPadding": { + "x": 0, + "y": 0 + }, + "cornerRadius": 4, + "strokeColor": "0099ff", + "strokeWidth": 2, + "outerColor": "000000", + "feedbackStrokeColor": "0099FF", + "outerAlpha": 0.3 }, - "doneButton": { // iOS only. Android uses hardware back button. + "scanFeedbackConfig": { + "style": "rect", + "strokeWidth": 0, + "strokeColor": "0099FF", + "fillColor": "330099FF", + "beepOnResult": false, + "vibrateOnResult": false, + "blinkAnimationOnResult": false + } + }, + "options": { + "doneButtonConfig": { "title": "OK", - "type": "rect", // fullwidth, rect + "type": "rect", "cornerRadius": 0, - //"backgroundColor":"#EEEEEE", // default clearcolor "textColor": "FFFFFF", "textColorHighlighted": "CCCCCC", "fontSize": 33, "fontName": "HelveticaNeue", - "positionXAlignment": "center", // left,right,center - no affect on fullwidth - "positionYAlignment": "bottom", // top, center, bottom + "positionXAlignment": "center", + "positionYAlignment": "bottom", "offset": { - "x": 0, // postive -> right - "y": -88, // postive -> down + "x": 0, + "y": -88 } } } diff --git a/example/RNExampleApp/config/Barcode_PDF417Config.js b/example/RNExampleApp/config/Barcode_PDF417Config.js index 4bbcc5c9..f3f23cd5 100644 --- a/example/RNExampleApp/config/Barcode_PDF417Config.js +++ b/example/RNExampleApp/config/Barcode_PDF417Config.js @@ -1,63 +1,70 @@ export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "1080p" - }, - "flash": { - "mode": "auto", - "alignment": "bottom_right" - }, - "viewPlugin": { - "plugin": { - "id": "Barcode_ID", - "barcodePlugin": { - "barcodeFormatOptions": ["PDF_417"], - "enablePDF417Parsing": true - } - }, - "cutoutConfig": { - "style": "rect", - "maxWidthPercent": "80%", - "maxHeightPercent": "80%", - "alignment": "center", - "ratioFromSize": { - "width": 100, - "height": 80 + license: 'ew0KICAibGljZW5zZUtleVZlcnNpb24iOiAiMy4wIiwNCiAgImRlYnVnUmVwb3J0aW5nIjogInBpbmciLA0KICAibWFqb3JWZXJzaW9uIjogIjM3I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configs.plugin.barcode-pdf417-aamva", + "barcodeConfig": { + "barcodeFormats": [ + "PDF_417" + ], + "parseAAMVA": true + }, + "cancelOnResult": true }, - "strokeWidth": 1, - "cornerRadius": 3, - "strokeColor": "FFFFFF", - "outerColor": "000000", - "outerAlpha": 0.3, - "feedbackStrokeColor": "0099FF" - }, - "scanFeedback": { - "style": "rect", - "strokeColor": "0099FF", - "fillColor": "220099FF", - "animationDuration": 150, - "blinkOnResult": true, - "beepOnResult": true, - "vibrateOnResult": true - }, - "cancelOnResult": true + "cutoutConfig": { + "animation": "none", + "maxWidthPercent": "75%", + "maxHeightPercent": "50%", + "width": 0, + "alignment": "center", + "ratioFromSize": { + "width": 4, + "height": 1 + }, + "offset": { + "x": 0, + "y": 0 + }, + "cropOffset": { + "x": 0, + "y": 0 + }, + "cropPadding": { + "x": 0, + "y": 0 + }, + "cornerRadius": 4, + "strokeColor": "0099ff", + "strokeWidth": 2, + "outerColor": "000000", + "feedbackStrokeColor": "0099FF", + "outerAlpha": 0.3 + }, + "scanFeedbackConfig": { + "style": "animated_rect", + "strokeWidth": 2, + "strokeColor": "000000", + "fillColor": "330099FF", + "beepOnResult": false, + "vibrateOnResult": false, + "blinkAnimationOnResult": false + } }, - "doneButton": { // iOS only. Android uses hardware back button. - "title": "OK", - "type": "rect", // fullwidth, rect - "cornerRadius": 0, - //"backgroundColor":"#EEEEEE", // default clearcolor - "textColor": "FFFFFF", - "textColorHighlighted": "CCCCCC", - "fontSize": 33, - "fontName": "HelveticaNeue", - "positionXAlignment": "center", // left,right,center - no affect on fullwidth - "positionYAlignment": "bottom", // top, center, bottom - "offset": { - "x": 0, // postive -> right - "y": -88, // postive -> down - } + "options": { + "doneButtonConfig": { + "title": "OK", + "type": "rect", + "cornerRadius": 0, + "textColor": "FFFFFF", + "textColorHighlighted": "CCCCCC", + "fontSize": 33, + "fontName": "HelveticaNeue", + "positionXAlignment": "center", + "positionYAlignment": "bottom", + "offset": { + "x": 0, + "y": -88 + } + } } - } } diff --git a/example/RNExampleApp/config/CattleTagConfig.js b/example/RNExampleApp/config/CattleTagConfig.js deleted file mode 100755 index b8d0f3f1..00000000 --- a/example/RNExampleApp/config/CattleTagConfig.js +++ /dev/null @@ -1,57 +0,0 @@ -export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "1080" - }, - "flash": { - "mode": "manual", - "alignment": "bottom_right" - }, - "viewPlugin": { - "plugin": { - "id": "OCR_COW", - "ocrPlugin": { - "cattleTagConfig":{ - } - } - }, - "cutoutConfig": { - "style": "rect", - "maxWidthPercent": "80%", - "maxHeightPercent": "80%", - "alignment": "center", - "width": 600, - "ratioFromSize": { - "width": 1, - "height": 1 - }, - "strokeWidth": 2, - "cornerRadius": 10, - "strokeColor": "FFFFFF", - "outerColor": "000000", - "outerAlpha": 0.3, - "feedbackStrokeColor": "0099FF", - "cropPadding": { - "x": 60, - "y": 60 - }, - "cropOffset": { - "x": 0, - "y": 0 - } - }, - "cancelOnResult": true, - "scanFeedback": { - "style": "rect", - "strokeWidth": 2, - "strokeColor": "0099FF", - "fillColor": "330099FF", - "cornerRadius": 0, - "beepOnResult": true, - "vibrateOnResult": true, - "blinkAnimationOnResult": true - } - } - } -} diff --git a/example/RNExampleApp/config/CommercialTireIdConfig.js b/example/RNExampleApp/config/CommercialTireIdConfig.js index c596a875..33588c86 100644 --- a/example/RNExampleApp/config/CommercialTireIdConfig.js +++ b/example/RNExampleApp/config/CommercialTireIdConfig.js @@ -1,48 +1,49 @@ export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "720p" - }, - "flash": { - "mode": "manual", - "alignment": "bottom_right" + license: 'ew0KICAibGljZW5zZUtleVZlcnNpb24iOiAiMy4wIiwNCiAgImRlYnVnUmVwb3J0aW5n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RPT0=', + "options": { + "doneButtonConfig": { + "offset.y": -88 + } + }, + "cameraConfig": { + "captureResolution": "1080p", + "zoomGesture": true + }, + "flashConfig": { + "mode": "manual", + "alignment": "top_left" + }, + "viewPluginConfig": { + "pluginConfig": { + "id": "TIRE", + "cancelOnResult": true, + "commercialTireIdConfig": {} }, - "viewPlugin" : { - "plugin": { - "id": "COMMERCIAL_TIRE_ID", - "tirePlugin": { - "commercialTireIdConfig":{ - } - } - }, - "cutoutConfig" : { - "style": "rect", + "cutoutConfig": { + "style": "animated_rect", + "maxWidthPercent": "80%", + "maxHeightPercent": "80%", + "alignment": "center", + "strokeWidth": 2, + "cornerRadius": 4, + "strokeColor": "0099FF", + "outerColor": "000000", + "outerAlpha": 0.3, + "width": 720, + "ratioFromSize": { "width": 720, - "alignment": "center", - "maxWidthPercent": "80%", - "ratioFromSize": { - "width": 720, - "height": 144 - }, - "outerColor": "000000", - "outerAlpha": 0.3, - "strokeWidth": 2, - "strokeColor": "FFFFFF", - "cornerRadius": 2, - "feedbackStrokeColor": "0099FF" + "height": 144 }, - "scanFeedback" : { - "animation": "traverse_multi", - "animationDuration" : 250, - "style": "contour_rect", - "strokeWidth": 2, - "strokeColor": "0099FF", - "beepOnResult": true, - "vibrateOnResult": true, - "blinkAnimationOnResult": true - }, - "cancelOnResult" : true + "feedbackStrokeColor": "0099FF" + }, + "scanFeedbackConfig": { + "animation": "traverse_multi", + "animationDuration": 250, + "style": "rect", + "strokeColor": "0099FF", + "beepOnResult": true, + "vibrateOnResult": false, + "strokeWidth": 2 } } } diff --git a/example/RNExampleApp/config/ContainerShipConfig.js b/example/RNExampleApp/config/ContainerShipConfig.js index bb3ccb88..5c53449b 100644 --- a/example/RNExampleApp/config/ContainerShipConfig.js +++ b/example/RNExampleApp/config/ContainerShipConfig.js @@ -1,50 +1,66 @@ export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5n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{ - "camera": { - "captureResolution": "1080p" - }, - "flash": { - "mode": "manual", - "alignment": "bottom_right" + license: 'ew0KICAibGljZW5zZUtleVZlcnNpb24iOiAiMy4wIiwNCiAgImRlYnVnUmVwb3J0aW5nIjogInBpbmciLA0KICAibWFqb3JWZXJzaW9uIjogIjM3IiwNCiAgInNjb3BlIjogWw0KICAgICJBTEwiLA0KICAgICJORkMiDQogIF0sDQogICJtYXhEYXlzTm90UmVwb3J0ZWQiOiA1LA0KICAiYWR2YW5jZWRCYXJjb2RlIjogdHJ1ZSwNCiAgIm11bHRpQmFyY29kZSI6IHRydWUsDQogICJzdXBwb3J0ZWRCYXJjb2RlRm9ybWF0cyI6IFsNCiAgICAiQUxMIg0KICBdLA0KICAicGxhdGZvcm0iOiBbDQogICAgImlPUyIsDQogICAgIkFuZHJvaWQiDQogIF0sDQogICJzaG93V2F0ZXJtYXJrIjogdHJ1ZSwNCiAgInRvbGVyYW5jZURheXMiOiAzMCwNCiAgInZhbGlkIjogIjIwMjMtMTItMzEiLA0KICAiaW9zSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0sDQogICJhbmRyb2lkSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0NCn0KSlhUTzVRSmZKa2FtUnR2VDc4QTFadGVhTXVzbmJlTW5HSHl0alZmczlxbUtIeDhCT3ltSGVXc2M2aXpjRExIenhtbklnU0JzS1RRNEdhSENsWCtvMEo2R3VtaFNUWHQrNVVuc1hVQVJ6aGhUdEhTa0l1ZVlRQ0p3dTI3bE9kWlBhNVoxSFNxN24weE9tek1jTjM3R1dsajVzVm9SY2pqaUswYVVnY0M5cDFRT0svK29ZejAvWlR2dXFGVjZUeHdiUHkyc3RqaDhLdS9NaXhtcFZFVmh0eWVzMEU2ZzhNVkdBNmNPU1h4NDVXVzgvR0NUWEpqdFJ6NnM2UFBDYzdYSXhQalFjOVAxdzBtblpFYTdjUHpMS3M0Y3hoYjQwSmluSU5qZXp6MDl1em9kbnZUR3VlSEIwcXIzUWNlVmdkS1JVQzhDc24zNmJLM2NLVmVpOVdTUlVRPT0=', + "options": { + "doneButtonConfig": { + "offset.y": -88 + } + }, + "cameraConfig": { + "captureResolution": "1080p", + "pictureResolution": "1080p", + "zoomGesture": true + }, + "flashConfig": { + "mode": "manual", + "alignment": "top_right" + }, + "viewPluginConfig": { + "pluginConfig": { + "id": "com.anyline.configs.plugin.horizontal-container", + "containerConfig": { + "scanMode": "HORIZONTAL" + }, + "cancelOnResult": true }, - "viewPlugin": { - "plugin": { - "id": "CONTAINER_ID", - "ocrPlugin": { - "containerConfig": { - } - } + "cutoutConfig": { + "style": "rect", + "animation": "none", + "maxWidthPercent": "70%", + "alignment": "top_half", + "ratioFromSize": { + "width": 62, + "height": 9 }, - "cutoutConfig": { - "style": "rect", - "width": 720, - "maxWidthPercent": "80%", - "alignment": "top_half", - "ratioFromSize": { - "width": 720, - "height": 144 - }, - "strokeWidth": 2, - "strokeColor": "FFFFFF", - "cornerRadius": 4, - "outerColor": "000000", - "outerAlpha": 0.5, - "feedbackStrokeColor": "0099FF", - "offset": { - "x": 0, - "y": -15 - } + "offset": { + "x": 0, + "y": 0 }, - "scanFeedback": { - "style": "CONTOUR_RECT", - "strokeColor": "0099FF", - "fillColor": "220099FF", - "blinkOnResult": true, - "beepOnResult": true, - "vibrateOnResult": true + "cropOffset": { + "x": 0, + "y": 0 }, - "cancelOnResult": true + "cropPadding": { + "x": 0, + "y": 0 + }, + "cornerRadius": 4, + "strokeColor": "0099ff", + "strokeWidth": 2, + "outerColor": "000000", + "feedbackStrokeColor": "0099FF", + "outerAlpha": 0.3 + }, + "scanFeedbackConfig": { + "style": "contour_rect", + "animation": "traverse_multi", + "animationDuration": 250, + "strokeWidth": 2, + "cornerRadius": 2, + "strokeColor": "0099FF", + "fillColor": "330099FF", + "beepOnResult": true, + "vibrateOnResult": true, + "blinkAnimationOnResult": true } } } diff --git a/example/RNExampleApp/config/CyrillicIdConfig.js b/example/RNExampleApp/config/CyrillicIdConfig.js index 8e3d6e5c..7351df86 100755 --- a/example/RNExampleApp/config/CyrillicIdConfig.js +++ b/example/RNExampleApp/config/CyrillicIdConfig.js @@ -1,98 +1,147 @@ export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera" : { - "captureResolution" : "1080p", - "zoomGesture": true - }, - "flash" : { - "mode": "manual", - "alignment": "bottom_right", - "imageOn": "flash_on", - "imageOff": "flash_off" - }, - "viewPlugin" : { - "plugin":{ - "id":"ID", - "idPlugin": { - "universalIdConfig": { - "alphabet" : "cyrillic", - "faceDetection": true, - "allowedLayouts": { - "mrz": [], - "drivingLicense": [], - "idFront": [] - }, - "drivingLicense": { - "lastName": {"scanOption": 0, "minConfidence": 40}, - "lastName@cyr": {"scanOption": 0, "minConfidence": 40}, - "firstName": {"scanOption": 0, "minConfidence": 40}, - "firstName@cyr": {"scanOption": 0, "minConfidence": 40}, - "dateOfBirth": {"scanOption": 0, "minConfidence": 50}, - "placeOfBirth": {"scanOption": 1, "minConfidence": 50}, - "dateOfIssue": {"scanOption": 0, "minConfidence": 50}, - "dateOfExpiry": {"scanOption": 1, "minConfidence": 50}, - "authority": {"scanOption": 1, "minConfidence": 30}, - "documentNumber": {"scanOption": 0, "minConfidence": 40}, - "address": {"scanOption": 1}, - "address@cyr": {"scanOption": 1}, - "nationality": {"scanOption": 1}, - "nationality@cyr": {"scanOption": 1} - }, - "idFront": { - "lastName": {"scanOption": 0, "minConfidence": 40}, - "lastName@cyr": {"scanOption": 0, "minConfidence": 40}, - "firstName": {"scanOption": 0, "minConfidence": 40}, - "firstName@cyr": {"scanOption": 0, "minConfidence": 40}, - "dateOfBirth": {"scanOption": 0, "minConfidence": 50}, - "placeOfBirth": {"scanOption": 1, "minConfidence": 50}, - "dateOfIssue": {"scanOption": 0, "minConfidence": 50}, - "dateOfExpiry": {"scanOption": 1, "minConfidence": 50}, - "authority": {"scanOption": 1, "minConfidence": 30}, - "documentNumber": {"scanOption": 0, "minConfidence": 40}, - "address": {"scanOption": 1}, - "address@cyr": {"scanOption": 1}, - "nationality": {"scanOption": 1}, - "nationality@cyr": {"scanOption": 1} - } + license: 'ew0KICAibGljZW5zZUtleVZlcnNpb24iOiAiMy4wIiwNCiAgImRlYnVnUmVwb3J0aW5nIjogInBpbmciLA0KICAibWFqb3JWZXJzaW9uIjogIjM3IiwNCiAgInNjb3BlIjogWw0KICAgICJBTEwiLA0KICAgICJORkMiDQogIF0sDQogICJtYXhEYXlzTm90UmVwb3J0ZWQiOiA1LA0KICAiYWR2YW5jZWRCYXJjb2RlIjogdHJ1ZSwNCiAgIm11bHRpQmFyY29kZSI6IHRydWUsDQogICJzdXBwb3J0ZWRCYXJjb2RlRm9ybWF0cyI6IFsNCiAgICAiQUxMIg0KICBdLA0KICAicGxhdGZvcm0iOiBbDQogICAgImlPUyIsDQogICAgIkFuZHJvaWQiDQogIF0sDQogICJzaG93V2F0ZXJtYXJrIjogdHJ1ZSwNCiAgInRvbGVyYW5jZURheXMiOiAzMCwNCiAgInZhbGlkIjogIjIwMjMtMTItMzEiLA0KICAiaW9zSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0sDQogICJhbmRyb2lkSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0NCn0KSlhUTzVRSmZKa2FtUnR2VDc4QTFadGVhTXVzbmJlTW5HSHl0alZmczlxbUtIeDhCT3ltSGVXc2M2aXpjRExIenhtbklnU0JzS1RRNEdhSENsWCtvMEo2R3VtaFNUWHQrNVVuc1hVQVJ6aGhUdEhTa0l1ZVlRQ0p3dTI3bE9kWlBhNVoxSFNxN24weE9tek1jTjM3R1dsajVzVm9SY2pqaUswYVVnY0M5cDFRT0svK29ZejAvWlR2dXFGVjZUeHdiUHkyc3RqaDhLdS9NaXhtcFZFVmh0eWVzMEU2ZzhNVkdBNmNPU1h4NDVXVzgvR0NUWEpqdFJ6NnM2UFBDYzdYSXhQalFjOVAxdzBtblpFYTdjUHpMS3M0Y3hoYjQwSmluSU5qZXp6MDl1em9kbnZUR3VlSEIwcXIzUWNlVmdkS1JVQzhDc24zNmJLM2NLVmVpOVdTUlVRPT0=', + "options": { + "doneButtonConfig": { + "offset.y": -88 + } + }, + "cameraConfig": { + "captureResolution": "1080p" + }, + "flashConfig": { + "mode": "manual", + "alignment": "bottom_left", + "offset": { + "x": 0, + "y": -40 + } + }, + "viewPluginConfig": { + "pluginConfig": { + "id": "com.anyline.configs.plugin.id_mrz_dl_cyrillic", + "universalIdConfig": { + "allowedLayouts": { + "mrz": [], + "drivingLicense": [], + "idFront": [] + }, + "alphabet": "cyrillic", + "drivingLicense": { + "surname": { + "scanOption": 0, + "minConfidence": 40 + }, + "givenNames": { + "scanOption": 0, + "minConfidence": 40 + }, + "dateOfBirth": { + "scanOption": 0, + "minConfidence": 50 + }, + "placeOfBirth": { + "scanOption": 1, + "minConfidence": 50 + }, + "dateOfIssue": { + "scanOption": 0, + "minConfidence": 50 + }, + "dateOfExpiry": { + "scanOption": 1, + "minConfidence": 50 + }, + "authority": { + "scanOption": 1, + "minConfidence": 30 + }, + "documentNumber": { + "scanOption": 0, + "minConfidence": 40 + }, + "categories": { + "scanOption": 1, + "minConfidence": 30 + }, + "address": { + "scanOption": 1 + } + }, + "idFront": { + "surname": { + "scanOption": 0, + "minConfidence": 60 + }, + "givenNames": { + "scanOption": 0, + "minConfidence": 60 + }, + "dateOfBirth": { + "scanOption": 0, + "minConfidence": 60 + }, + "placeOfBirth": { + "scanOption": 1, + "minConfidence": 60 + }, + "dateOfExpiry": { + "scanOption": 1, + "minConfidence": 60 + }, + "cardAccessNumber": { + "scanOption": 1, + "minConfidence": 60 + }, + "documentNumber": { + "scanOption": 0, + "minConfidence": 60 + }, + "nationality": { + "scanOption": 1, + "minConfidence": 60 } } }, - "cutoutConfig" : { - "style": "animated_rect", - "maxWidthPercent": "90%", - "maxHeightPercent": "90%", - "alignment": "center", - "strokeWidth": 3, - "cornerRadius": 8, - "strokeColor": "FFFFFF", - "outerColor": "000000", - "outerAlpha": 0.3, - "ratioFromSize" : { - "width": 50, - "height": 31 - }, - "cropPadding": { - "x": -50, - "y": -50 - }, - "cropOffset": { - "x": 0, - "y": 0 - }, - "feedbackStrokeColor": "0099FF" + "cancelOnResult": true + }, + "cutoutConfig": { + "animation": "fade", + "maxWidthPercent": "90%", + "maxHeightPercent": "90%", + "width": 0, + "alignment": "top_half", + "ratioFromSize": { + "width": 86, + "height": 54 }, - "scanFeedback" : { - "style": "CONTOUR_RECT", - "visualFeedbackRedrawTimeout": 100, - "strokeColor": "0099FF", - "fillColor" : "220099FF", - "beepOnResult": true, - "vibrateOnResult": true, - "strokeWidth": 2 + "offset": { + "x": 0, + "y": 60 }, - "cancelOnResult" : true + "cropOffset": { + "x": 0, + "y": 0 + }, + "cropPadding": { + "x": 0, + "y": 0 + }, + "cornerRadius": 4, + "strokeColor": "0099ff", + "strokeWidth": 2, + "outerColor": "000000", + "feedbackStrokeColor": "0099FF", + "outerAlpha": 0.3 + }, + "scanFeedbackConfig": { + "style": "animated_rect", + "strokeWidth": 2, + "strokeColor": "ff5555", + "fillColor": "40ff5555", + "cornerRadius": 4, + "beepOnResult": true, + "vibrateOnResult": true, + "blinkAnimationOnResult": true } } - } diff --git a/example/RNExampleApp/config/DialMeterConfig.js b/example/RNExampleApp/config/DialMeterConfig.js deleted file mode 100644 index d77d5b6f..00000000 --- a/example/RNExampleApp/config/DialMeterConfig.js +++ /dev/null @@ -1,58 +0,0 @@ -export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nI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- "camera": { - "captureResolution": "720p" - }, - "flash": { - "mode": "manual", - "alignment": "top_left", - }, - "viewPlugin": { - "plugin": { - "id": "DIAL_METER", - "meterPlugin": { - "scanMode": "DIAL_METER" - } - }, - "cutoutConfig": { - "style": "rect", - "maxWidthPercent": "90%", - "maxHeightPercent": "90%", - "alignment": "top_half", - "ratioFromSize": { - "width": 125, - "height": 85 - }, - "offset": { - "x": 0, - "y": 15 - }, - "cropPadding": { - "x": 0, - "y": 0 - }, - "cropOffset": { - "x": 0, - "y": 0 - }, - "strokeWidth": 2, - "cornerRadius": 4, - "strokeColor": "FFFFFF", - "outerColor": "000000", - "outerAlpha": 0.3, - "feedbackStrokeColor": "0099FF" - }, - "scanFeedback": { - "style": "CONTOUR_RECT", - "strokeColor": "0099FF", - "fillColor": "220099FF", - "blinkOnResult": true, - "beepOnResult": true, - "vibrateOnResult": true - }, - "cancelOnResult": true, - }, - "nativeBarcodeEnabled": true - }, -} diff --git a/example/RNExampleApp/config/DigitalMeterConfig.js b/example/RNExampleApp/config/DigitalMeterConfig.js deleted file mode 100644 index a9f09bfc..00000000 --- a/example/RNExampleApp/config/DigitalMeterConfig.js +++ /dev/null @@ -1,40 +0,0 @@ -export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "720p" - }, - "flash": { - "mode": "manual", - "alignment": "bottom_right", - }, - "viewPlugin": { - "plugin": { - "id": "DIGITAL_METER", - "meterPlugin": { - "scanMode": "AUTO_ANALOG_DIGITAL_METER" - } - }, - "cutoutConfig": { - "style": "rect", - "alignment": "top_half", - "strokeWidth": 2, - "cornerRadius": 4, - "strokeColor": "FFFFFF", - "outerColor": "000000", - "outerAlpha": 0.3, - "feedbackStrokeColor": "0099FF" - }, - "scanFeedback": { - "style": "CONTOUR_RECT", - "strokeColor": "0099FF", - "fillColor": "220099FF", - "blinkOnResult": true, - "beepOnResult": true, - "vibrateOnResult": true - }, - "cancelOnResult": true, - }, - "nativeBarcodeEnabled": true - } -} diff --git a/example/RNExampleApp/config/DocumentConfig.js b/example/RNExampleApp/config/DocumentConfig.js deleted file mode 100755 index 63103a30..00000000 --- a/example/RNExampleApp/config/DocumentConfig.js +++ /dev/null @@ -1,53 +0,0 @@ -export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "720p", - "pictureResolution": "1080p", - "pictureAspectRatios": ["16:9"] - }, - "flash": { - "mode": "manual", - "alignment": "bottom_left", - "offset": { - "x": 10, - "y": 0 - } - }, - - "viewPlugin": { - "plugin": { - "id": "DOCUMENT", - "documentPlugin": { - } - }, - "cutoutConfig": { - "style": "rect", - "maxWidthPercent": "100%", - "maxHeightPercent": "100%", - "widthPercent": "100%", - "width": 1080, - "ratioFromSize": { - "width": 10, - "height": 18 - }, - "alignment": "center", - "strokeWidth": 2, - "cornerRadius": 0, - "strokeColor": "00000000" - }, - "scanFeedback": { - "beepOnResult": true, - "vibrateOnResult": true, - "blinkAnimationOnResult": true - }, - "cancelOnResult": true - }, - "document": { - "manualCaptureButton": { - "buttonColor": "0099ff" - } - }, - quality: 90 - }, -} diff --git a/example/RNExampleApp/config/DocumentConfigUI.js b/example/RNExampleApp/config/DocumentConfigUI.js deleted file mode 100755 index 121a4c7a..00000000 --- a/example/RNExampleApp/config/DocumentConfigUI.js +++ /dev/null @@ -1,49 +0,0 @@ -export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "720p", - "pictureResolution": "1080p", - "pictureAspectRatios": ["16:9"] - }, - "flash": { - "mode": "manual", - "alignment": "bottom_left", - "offset": { - "x": 10, - "y": 0 - } - }, - - "viewPlugin": { - "plugin": { - "id": "DOCUMENT", - "documentPlugin": { - } - }, - "cutoutConfig": { - "style": "rect", - "maxWidthPercent": "100%", - "maxHeightPercent": "100%", - "widthPercent": "100%", - "width": 1080, - "ratioFromSize": { - "width": 10, - "height": 18 - }, - "alignment": "center", - "strokeWidth": 2, - "cornerRadius": 0, - "strokeColor": "00000000" - }, - "scanFeedback": { - "beepOnResult": true, - "vibrateOnResult": true, - "blinkAnimationOnResult": true - }, - "cancelOnResult": true - }, - "documentScannerUI": true, - quality: 90 - }, -} diff --git a/example/RNExampleApp/config/DotMatrixConfig.js b/example/RNExampleApp/config/DotMatrixConfig.js deleted file mode 100644 index 8fa2cbe6..00000000 --- a/example/RNExampleApp/config/DotMatrixConfig.js +++ /dev/null @@ -1,40 +0,0 @@ -export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "720p" - }, - "flash": { - "mode": "manual", - "alignment": "bottom_right", - }, - "viewPlugin": { - "plugin": { - "id": "Meter_ID", - "meterPlugin": { - "scanMode": "AUTO_ANALOG_DIGITAL_METER" - } - }, - "cutoutConfig": { - "style": "rect", - "alignment": "top_half", - "strokeWidth": 2, - "cornerRadius": 4, - "strokeColor": "FFFFFF", - "outerColor": "000000", - "outerAlpha": 0.3, - "feedbackStrokeColor": "0099FF" - }, - "scanFeedback": { - "style": "CONTOUR_RECT", - "strokeColor": "0099FF", - "fillColor": "220099FF", - "blinkOnResult": true, - "beepOnResult": true, - "vibrateOnResult": true - }, - "cancelOnResult": true - }, - "nativeBarcodeEnabled": true - } -} diff --git a/example/RNExampleApp/config/IbanConfig.js b/example/RNExampleApp/config/IbanConfig.js deleted file mode 100755 index 5bd02ba1..00000000 --- a/example/RNExampleApp/config/IbanConfig.js +++ /dev/null @@ -1,53 +0,0 @@ -export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nI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- "camera": { - "captureResolution": "1080" - }, - "flash": { - "mode": "manual", - "alignment": "bottom_right" - }, - "viewPlugin": { - "plugin": { - "id": "OCR_IBAN", - "ocrPlugin": { - "ocrConfig": { - "scanMode": "LINE", - "languages": ["USNr.any"], - "charWhitelist": "ABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890", - "minConfidence": 70, - "validationRegex": "^[A-Z]{2}([0-9A-Z]\\s*){13,32}$" - } - } - }, - "cutoutConfig": { - "style": "rect", - "maxWidthPercent": "80%", - "maxHeightPercent": "80%", - "alignment": "center", - "width": 900, - "ratioFromSize": { - "width": 10, - "height": 1 - }, - "strokeWidth": 2, - "cornerRadius": 10, - "strokeColor": "FFFFFF", - "outerColor": "000000", - "outerAlpha": 0.3, - "feedbackStrokeColor": "0099FF" - }, - "cancelOnResult": true, - "scanFeedback": { - "style": "contour_underline", - "strokeColor": "0099FF", - "strokeWidth": 2, - "fillColor": "110099FF", - "beepOnResult": true, - "vibrateOnResult": true, - "blinkAnimationOnResult": true - } - } - }, -} diff --git a/example/RNExampleApp/config/JapaneseLandingPermit.js b/example/RNExampleApp/config/JapaneseLandingPermit.js deleted file mode 100755 index a58bac19..00000000 --- a/example/RNExampleApp/config/JapaneseLandingPermit.js +++ /dev/null @@ -1,47 +0,0 @@ -export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "1080p", - "zoomGesture": "true" - }, - "flash": { - "mode": "manual", - "alignment": "bottom_right" - }, - "viewPlugin" : { - "plugin": { - "id": "ID", - "idPlugin": { - "japaneseLandingPermissionConfig": {} - } - }, - "cutoutConfig": { - "style": "rect", - "maxWidthPercent": "70%", - "maxHeightPercent": "70%", - "alignment": "center", - "strokeWidth": 2, - "cornerRadius": 4, - "strokeColor": "FFFFFF", - "outerColor": "000000", - "outerAlpha": 0.3, - "ratioFromSize": { - "width": 440, - "height": 615 - }, - "feedbackStrokeColor": "0099FF" - }, - "scanFeedback": { - "style": "CONTOUR_RECT", - "visualFeedbackRedrawTimeout": 100, - "strokeColor": "0099FF", - "fillColor": "220099FF", - "beepOnResult": "true", - "vibrateOnResult": "true", - "strokeWidth": 2 - }, - "cancelOnResult": "true" - } - } -} diff --git a/example/RNExampleApp/config/LicensePlateConfig.js b/example/RNExampleApp/config/LicensePlateConfig.js index 014c9177..e04a23c4 100644 --- a/example/RNExampleApp/config/LicensePlateConfig.js +++ b/example/RNExampleApp/config/LicensePlateConfig.js @@ -1,47 +1,68 @@ export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "1080p", - "zoomGesture": true + license: 'ew0KICAibGljZW5zZUtleVZlcnNpb24iOiAiMy4wIiwNCiAgImRlYnVnUmVwb3J0aW5nIjogInBpbmciLA0KICAibWFqb3JWZXJzaW9uIjogIjM3IiwNCiAgInNjb3BlIjogWw0KICAgICJBTEwiLA0KICAgICJORkMiDQogIF0sDQogICJtYXhEYXlzTm90UmVwb3J0ZWQiOiA1LA0KICAiYWR2YW5jZWRCYXJjb2RlIjogdHJ1ZSwNCiAgIm11bHRpQmFyY29kZSI6IHRydWUsDQogICJzdXBwb3J0ZWRCYXJjb2RlRm9ybWF0cyI6IFsNCiAgICAiQUxMIg0KICBdLA0KICAicGxhdGZvcm0iOiBbDQogICAgImlPUyIsDQogICAgIkFuZHJvaWQiDQogIF0sDQogICJzaG93V2F0ZXJtYXJrIjogdHJ1ZSwNCiAgInRvbGVyYW5jZURheXMiOiAzMCwNCiAgInZhbGlkIjogIjIwMjMtMTItMzEiLA0KICAiaW9zSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0sDQogICJhbmRyb2lkSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0NCn0KSlhUTzVRSmZKa2FtUnR2VDc4QTFadGVhTXVzbmJlTW5HSHl0alZmczlxbUtIeDhCT3ltSGVXc2M2aXpjRExIenhtbklnU0JzS1RRNEdhSENsWCtvMEo2R3VtaFNUWHQrNVVuc1hVQVJ6aGhUdEhTa0l1ZVlRQ0p3dTI3bE9kWlBhNVoxSFNxN24weE9tek1jTjM3R1dsajVzVm9SY2pqaUswYVVnY0M5cDFRT0svK29ZejAvWlR2dXFGVjZUeHdiUHkyc3RqaDhLdS9NaXhtcFZFVmh0eWVzMEU2ZzhNVkdBNmNPU1h4NDVXVzgvR0NUWEpqdFJ6NnM2UFBDYzdYSXhQalFjOVAxdzBtblpFYTdjUHpMS3M0Y3hoYjQwSmluSU5qZXp6MDl1em9kbnZUR3VlSEIwcXIzUWNlVmdkS1JVQzhDc24zNmJLM2NLVmVpOVdTUlVRPT0=', + "options": { + "doneButtonConfig": { + "offset.y": -88 }, - "flash": { - "mode": "manual", - "alignment": "top_left" + "segmentConfig": { + "titles": ["Auto", "US", "Africa"], + "modes": ["auto", "unitedstates", "africa"], + "offset.y": -24 + } + }, + "cameraConfig": { + "captureResolution": "1080p" + }, + "flashConfig": { + "mode": "manual", + "alignment": "top_left" + }, + "viewPluginConfig": { + "pluginConfig": { + "id": "license-plate-eu", + "licensePlateConfig": { + "scanMode": "auto" + }, + "cancelOnResult": true }, - "viewPlugin": { - "plugin": { - "id": "LicensePlate_ID", - "licensePlatePlugin": { - } + "cutoutConfig": { + "animation": "none", + "maxWidthPercent": "80%", + "maxHeightPercent": "80%", + "alignment": "top_half", + "ratioFromSize": { + "width": 4, + "height": 1 }, - "cutoutConfig": { - "style": "rect", - "maxWidthPercent": "80%", - "maxHeightPercent": "80%", - "alignment": "top_half", - "width": 720, - "ratioFromSize": { - "width": 2, - "height": 1 - }, - "strokeWidth": 2, - "cornerRadius": 10, - "strokeColor": "FFFFFF", - "outerColor": "000000", - "outerAlpha": 0.3, - "feedbackStrokeColor": "0099FF" + "offset": { + "x": 0, + "y": 40 }, - "scanFeedback": { - "animationDuration": 0, - "style": "RECT", - "strokeWidth": 2, - "strokeColor": "0099FF", - "blinkOnResult": true, - "beepOnResult": true, - "vibrateOnResult": true + "cropPadding": { + "x": 0, + "y": 0 }, - "cancelOnResult": true + "cropOffset": { + "x": 0, + "y": 0 + }, + "cornerRadius": 4, + "strokeColor": "0099ff", + "strokeWidth": 2, + "feedbackStrokeColor": "0099ff", + "outerColor": "000000", + "outerAlpha": 0.3 + }, + "scanFeedbackConfig": { + "style": "rect", + "strokeWidth": 2, + "animationDuration": 0, + "strokeColor": "0099ff", + "cornerRadius": 0, + "fillColor": "330099ff", + "beepOnResult": true, + "vibrateOnResult": true, + "blinkAnimationOnResult": true } - }, + } } diff --git a/example/RNExampleApp/config/LicensePlateUSConfig.js b/example/RNExampleApp/config/LicensePlateUSConfig.js deleted file mode 100644 index ccaface2..00000000 --- a/example/RNExampleApp/config/LicensePlateUSConfig.js +++ /dev/null @@ -1,48 +0,0 @@ -export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "1080p", - "zoomGesture": true - }, - "flash": { - "mode": "manual", - "alignment": "top_left" - }, - "viewPlugin": { - "plugin": { - "id": "LICENSE_PLATE_US", - "licensePlatePlugin": { - "scanMode": "unitedStates" - } - }, - "cutoutConfig": { - "style": "rect", - "maxWidthPercent": "80%", - "maxHeightPercent": "80%", - "alignment": "top_half", - "width": 720, - "ratioFromSize": { - "width": 2, - "height": 1 - }, - "strokeWidth": 2, - "cornerRadius": 10, - "strokeColor": "FFFFFF", - "outerColor": "000000", - "outerAlpha": 0.3, - "feedbackStrokeColor": "0099FF" - }, - "scanFeedback": { - "animationDuration": 0, - "style": "RECT", - "strokeWidth": 2, - "strokeColor": "0099FF", - "blinkOnResult": true, - "beepOnResult": true, - "vibrateOnResult": true - }, - "cancelOnResult": true - } - }, -} diff --git a/example/RNExampleApp/config/MRZConfig.js b/example/RNExampleApp/config/MRZConfig.js index 9bcd7880..e42d0779 100755 --- a/example/RNExampleApp/config/MRZConfig.js +++ b/example/RNExampleApp/config/MRZConfig.js @@ -1,70 +1,51 @@ export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "1080p" + license: 'ew0KICAibGljZW5zZUtleVZlcnNpb24iOiAiMy4wIiwNCiAgImRlYnVnUmVwb3J0aW5nIjogInBpbmciLA0KICAibWFqb3JWZXJzaW9uIjogIjM3IiwNCiAgInNjb3BlIjogWw0KICAgICJBTEwiLA0KICAgICJORkMiDQogIF0sDQogICJtYXhEYXlzTm90UmVwb3J0ZWQiOiA1LA0KICAiYWR2YW5jZWRCYXJjb2RlIjogdHJ1ZSwNCiAgIm11bHRpQmFyY29kZSI6IHRydWUsDQogICJzdXBwb3J0ZWRCYXJjb2RlRm9ybWF0cyI6IFsNCiAgICAiQUxMIg0KICBdLA0KICAicGxhdGZvcm0iOiBbDQogICAgImlPUyIsDQogICAgIkFuZHJvaWQiDQogIF0sDQogICJzaG93V2F0ZXJtYXJrIjogdHJ1ZSwNCiAgInRvbGVyYW5jZURheXMiOiAzMCwNCiAgInZhbGlkIjogIjIwMjMtMTItMzEiLA0KICAiaW9zSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0sDQogICJhbmRyb2lkSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0NCn0KSlhUTzVRSmZKa2FtUnR2VDc4QTFadGVhTXVzbmJlTW5HSHl0alZmczlxbUtIeDhCT3ltSGVXc2M2aXpjRExIenhtbklnU0JzS1RRNEdhSENsWCtvMEo2R3VtaFNUWHQrNVVuc1hVQVJ6aGhUdEhTa0l1ZVlRQ0p3dTI3bE9kWlBhNVoxSFNxN24weE9tek1jTjM3R1dsajVzVm9SY2pqaUswYVVnY0M5cDFRT0svK29ZejAvWlR2dXFGVjZUeHdiUHkyc3RqaDhLdS9NaXhtcFZFVmh0eWVzMEU2ZzhNVkdBNmNPU1h4NDVXVzgvR0NUWEpqdFJ6NnM2UFBDYzdYSXhQalFjOVAxdzBtblpFYTdjUHpMS3M0Y3hoYjQwSmluSU5qZXp6MDl1em9kbnZUR3VlSEIwcXIzUWNlVmdkS1JVQzhDc24zNmJLM2NLVmVpOVdTUlVRPT0=', + "options": { + "doneButtonConfig": { + "offset.y": -88 + } + }, + "viewPluginConfig": { + "pluginConfig": { + "id": "com.anyline.configs.plugin.mrz", + "mrzConfig": { + "strictMode": false, + "cropAndTransformID": false + } }, - "flash": { - "mode": "manual", - "alignment": "bottom_left" - }, - "viewPlugin" : { - "plugin" : { - "id" : "IDPlugin_ID", - "idPlugin" : { - "mrzConfig" : { - "strictMode" : false, - "cropAndTransformID" : false, - "mrzFieldScanOptions": { - "vizAddress" : "default", - "vizDateOfIssue" : "default", - "vizSurname" : "default", - "vizGivenNames" : "default", - "vizDateOfBirth" : "default", - "vizDateOfExpiry" : "default", - } - } - } + "cutoutConfig": { + "animation": "none", + "maxWidthPercent": "85%", + "maxHeightPercent": "70%", + "width": 0, + "alignment": "top_half", + "ratioFromSize": { + "width": 86, + "height": 54 }, - "cutoutConfig": { - "style": "rect", - "maxWidthPercent": "90%", - "maxHeightPercent": "90%", - "width" : 972, - "alignment": "center", - "ratioFromSize": { - "width": 125, - "height": 85 - }, - "strokeWidth": 2, - "cornerRadius": 4, - "strokeColor": "FFFFFF", - "outerColor": "000000", - "outerAlpha": 0.3, - "cropPadding": { - "x": -30, - "y": -90 - }, - "cropOffset": { - "x": 0, - "y": 90 - }, - "feedbackStrokeColor": "0099FF", - "offset": { - "x": 0, - "y": 30 - } + "offset": { + "x": 0, + "y": 25 }, - "scanFeedback": { - "style": "rect", - "strokeColor": "0099FF", - "strokeWidth": 2, - "blinkOnResult": true, - "beepOnResult": true, - "vibrateOnResult": true + "cropPadding": { + "x": 25, + "y": 25 }, - "cancelOnResult": true + "outerColor": "000000", + "outerAlpha": 0.3, + "strokeWidth": 2, + "strokeColor": "0099FF", + "cornerRadius": 2, + "feedbackStrokeColor": "0099FF" }, - "cropAndTransformErrorMessage": "Edges are not detected" + "scanFeedbackConfig": { + "style": "rect", + "strokeWidth": 2, + "strokeColor": "0099FF", + "fillColor": "220099FF", + "beepOnResult": false, + "vibrateOnResult": false, + "blinkAnimationOnResult": false + } } } diff --git a/example/RNExampleApp/config/NFCAndMRZConfig.js b/example/RNExampleApp/config/NFCAndMRZConfig.js deleted file mode 100755 index d95fb7cc..00000000 --- a/example/RNExampleApp/config/NFCAndMRZConfig.js +++ /dev/null @@ -1,63 +0,0 @@ -export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "1080p" - }, - "flash": { - "mode": "manual", - "alignment": "bottom_left" - }, - "viewPlugin" : { - "plugin": { - "id": "ID_NFC", - "nfcPlugin": { - "mrzConfig": { - "strictMode" : false, - "cropAndTransformID" : false, - "mrzFieldScanOptions": { - } - } - } - }, - "cutoutConfig": { - "style": "rect", - "maxWidthPercent": "90%", - "maxHeightPercent": "90%", - "alignment": "center", - "ratioFromSize": { - "width": 125, - "height": 85 - }, - "strokeWidth": 2, - "cornerRadius": 4, - "strokeColor": "FFFFFF", - "outerColor": "000000", - "outerAlpha": 0.3, - "cropPadding": { - "x": 0, - "y": 0 - }, - "cropOffset": { - "x": 0, - "y": 0 - }, - "feedbackStrokeColor": "0099FF", - "offset": { - "x": 0, - "y": 30 - } - }, - "scanFeedback": { - "style": "rect", - "strokeColor": "0099FF", - "strokeWidth": 2, - "blinkOnResult": true, - "beepOnResult": true, - "vibrateOnResult": true - }, - "cancelOnResult": true - }, - "cropAndTransformErrorMessage": "Edges are not detected" - } -} diff --git a/example/RNExampleApp/config/NFCMRZConfig.js b/example/RNExampleApp/config/NFCMRZConfig.js new file mode 100755 index 00000000..0f0b59db --- /dev/null +++ b/example/RNExampleApp/config/NFCMRZConfig.js @@ -0,0 +1,65 @@ +export default { + license: 'ew0KICAibGljZW5zZUtleVZlcnNpb24iOiAiMy4wIiwNCiAgImRlYnVnUmVwb3J0aW5nIjogInBpbmciLA0KICAibWFqb3JWZXJzaW9uIjogIjM3IiwNCiAgInNjb3BlIjogWw0KICAgICJBTEwiLA0KICAgICJORkMiDQogIF0sDQogICJtYXhEYXlzTm90UmVwb3J0ZWQiOiA1LA0KICAiYWR2YW5jZWRCYXJjb2RlIjogdHJ1ZSwNCiAgIm11bHRpQmFyY29kZSI6IHRydWUsDQogICJzdXBwb3J0ZWRCYXJjb2RlRm9ybWF0cyI6IFsNCiAgICAiQUxMIg0KICBdLA0KICAicGxhdGZvcm0iOiBbDQogICAgImlPUyIsDQogICAgIkFuZHJvaWQiDQogIF0sDQogICJzaG93V2F0ZXJtYXJrIjogdHJ1ZSwNCiAgInRvbGVyYW5jZURheXMiOiAzMCwNCiAgInZhbGlkIjogIjIwMjMtMTItMzEiLA0KICAiaW9zSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0sDQogICJhbmRyb2lkSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0NCn0KSlhUTzVRSmZKa2FtUnR2VDc4QTFadGVhTXVzbmJlTW5HSHl0alZmczlxbUtIeDhCT3ltSGVXc2M2aXpjRExIenhtbklnU0JzS1RRNEdhSENsWCtvMEo2R3VtaFNUWHQrNVVuc1hVQVJ6aGhUdEhTa0l1ZVlRQ0p3dTI3bE9kWlBhNVoxSFNxN24weE9tek1jTjM3R1dsajVzVm9SY2pqaUswYVVnY0M5cDFRT0svK29ZejAvWlR2dXFGVjZUeHdiUHkyc3RqaDhLdS9NaXhtcFZFVmh0eWVzMEU2ZzhNVkdBNmNPU1h4NDVXVzgvR0NUWEpqdFJ6NnM2UFBDYzdYSXhQalFjOVAxdzBtblpFYTdjUHpMS3M0Y3hoYjQwSmluSU5qZXp6MDl1em9kbnZUR3VlSEIwcXIzUWNlVmdkS1JVQzhDc24zNmJLM2NLVmVpOVdTUlVRPT0=', + "options": { + "enableNFCWithMRZ": true, + "labelConfig": { + "text": "Scan Passport", + "size": 22, + "offset.x": 0, + "offset.y": -10 + }, + "doneButtonConfig": { + "offset.y": -88 + } + }, + "cameraConfig": { + "captureResolution": "1080p" + }, + "flashConfig": { + "mode": "manual", + "alignment": "bottom_left" + }, + "viewPluginConfig": { + "pluginConfig": { + "id": "ID_NFC", + "mrzConfig": { + "strictMode": false, + "cropAndTransformID": false + } + }, + "cutoutConfig": { + "animation": "none", + "maxWidthPercent": "85%", + "maxHeightPercent": "70%", + "width": 0, + "alignment": "top_half", + "ratioFromSize": { + "width": 86, + "height": 54 + }, + "offset": { + "x": 0, + "y": 20 + }, + "cropPadding": { + "x": 25, + "y": 25 + }, + "outerColor": "000000", + "outerAlpha": 0.3, + "strokeWidth": 2, + "strokeColor": "0099FF", + "cornerRadius": 4, + "feedbackStrokeColor": "0099FF" + }, + "scanFeedbackConfig": { + "style": "rect", + "strokeWidth": 2, + "strokeColor": "0099FF", + "fillColor": "220099FF", + "beepOnResult": true, + "vibrateOnResult": true, + "blinkAnimationOnResult": false + } + } +} diff --git a/example/RNExampleApp/config/OtaConfig.js b/example/RNExampleApp/config/OtaConfig.js index 76ac41f5..04c14560 100644 --- a/example/RNExampleApp/config/OtaConfig.js +++ b/example/RNExampleApp/config/OtaConfig.js @@ -1,5 +1,5 @@ export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5n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Xp6MDl1em9kbnZUR3VlSEIwcXIzUWNlVmdkS1JVQzhDc24zNmJLM2NLVmVpOVdTUlVRPT0=', projectID: "ce25badf-1fb6-4bc4-9117-8d00d284a8b6", apiKey: "e88fa4a3-5377-49a1-8d56-538d137fb038", assetVersion: "1.0.0", diff --git a/example/RNExampleApp/config/ParallelScanningConfig.js b/example/RNExampleApp/config/ParallelScanningConfig.js index 5dd78b46..2eb68920 100644 --- a/example/RNExampleApp/config/ParallelScanningConfig.js +++ b/example/RNExampleApp/config/ParallelScanningConfig.js @@ -1,96 +1,105 @@ export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "1080p" + license: 'ew0KICAibGljZW5zZUtleVZlcnNpb24iOiAiMy4wIiwNCiAgImRlYnVnUmVwb3J0aW5nIjogInBpbmciLA0KICAibWFqb3JWZXJzaW9uIjogIjM3IiwNCiAgInNjb3BlIjogWw0KICAgICJBTEwiLA0KICAgICJORkMiDQogIF0sDQogICJtYXhEYXlzTm90UmVwb3J0ZWQiOiA1LA0KICAiYWR2YW5jZWRCYXJjb2RlIjogdHJ1ZSwNCiAgIm11bHRpQmFyY29kZSI6IHRydWUsDQogICJzdXBwb3J0ZWRCYXJjb2RlRm9ybWF0cyI6IFsNCiAgICAiQUxMIg0KICBdLA0KICAicGxhdGZvcm0iOiBbDQogICAgImlPUyIsDQogICAgIkFuZHJvaWQiDQogIF0sDQogICJzaG93V2F0ZXJtYXJrIjogdHJ1ZSwNCiAgInRvbGVyYW5jZURheXMiOiAzMCwNCiAgInZhbGlkIjogIjIwMjMtMTItMzEiLA0KICAiaW9zSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0sDQogICJhbmRyb2lkSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0NCn0KSlhUTzVRSmZKa2FtUnR2VDc4QTFadGVhTXVzbmJlTW5HSHl0alZmczlxbUtIeDhCT3ltSGVXc2M2aXpjRExIenhtbklnU0JzS1RRNEdhSENsWCtvMEo2R3VtaFNUWHQrNVVuc1hVQVJ6aGhUdEhTa0l1ZVlRQ0p3dTI3bE9kWlBhNVoxSFNxN24weE9tek1jTjM3R1dsajVzVm9SY2pqaUswYVVnY0M5cDFRT0svK29ZejAvWlR2dXFGVjZUeHdiUHkyc3RqaDhLdS9NaXhtcFZFVmh0eWVzMEU2ZzhNVkdBNmNPU1h4NDVXVzgvR0NUWEpqdFJ6NnM2UFBDYzdYSXhQalFjOVAxdzBtblpFYTdjUHpMS3M0Y3hoYjQwSmluSU5qZXp6MDl1em9kbnZUR3VlSEIwcXIzUWNlVmdkS1JVQzhDc24zNmJLM2NLVmVpOVdTUlVRPT0=', + "options": { + "doneButtonConfig": { + "offset.y": -88 + } }, - "flash": { - "mode": "manual", - "alignment": "top_right" - }, - "parallelViewPluginComposite": { - "id": "DOUBLE_TARIFF_SEQUENTIAL", - "cancelOnResult": true, + "viewPluginCompositeConfig": { + "id": "meter_barcode_parallel_scan", + "processingMode": "parallel", "viewPlugins": [ { - "viewPlugin": { - "plugin": { - "id": "METER_PLUGIN", - "meterPlugin": { - "scanMode": "AUTO_ANALOG_DIGITAL_METER" - } + "viewPluginConfig": { + "pluginConfig": { + "id": "meter", + "meterConfig": { + "scanMode": "auto_analog_digital_meter" + }, + "cancelOnResult": true, + "startScanDelay": 0 }, "cutoutConfig": { "style": "rect", - "alignment": "top", + "maxWidthPercent": "100%", + "width": 768, + "alignment": "top_half", + "ratioFromSize": { + "width": 9, + "height": 4 + }, + "offset": { + "x": 0, + "y": 80 + }, "strokeWidth": 2, - "strokeColor": "FFFFFF", "cornerRadius": 4, + "strokeColor": "0099FF", "outerColor": "000000", - "outerAlpha": 0.5, - "feedbackStrokeColor": "0099FF", - "offset": { - "x": 0, - "y": 120 - } + "outerAlpha": 0.3 }, - "scanFeedback": { - "style": "CONTOUR_RECT", - "strokeColor": "0099FF", + "scanFeedbackConfig": { + "style": "contour_rect", "strokeWidth": 2, + "strokeColor": "0099FF", "fillColor": "220099FF", "cornerRadius": 2, - "redrawTimeout": 200, - "animationDuration": 75, - "blinkOnResult": true, "beepOnResult": true, - "vibrateOnResult": true - }, - "cancelOnResult": true + "vibrateOnResult": true, + "blinkAnimationOnResult": true, + "redrawTimeout": 200, + "animationDuration": 75 + } } }, { - "viewPlugin": { - "plugin": { - "id": "USNR_ID", - "ocrPlugin": { - "ocrConfig": {} + "viewPluginConfig": { + "pluginConfig": { + "id": "com.anyline.configs.plugin.universal-serial-number", + "ocrConfig": { + "scanMode": "auto" }, - "delayStartScanTime": 1000 + "cancelOnResult": true }, "cutoutConfig": { - "style": "rect", - "width": 720, - "alignment": "center", + "animation": "none", "maxWidthPercent": "80%", + "alignment": "center", "ratioFromSize": { - "width": 720, - "height": 144 + "width": 5, + "height": 1 }, - "strokeWidth": 2, - "strokeColor": "FFFFFF", - "cornerRadius": 4, - "outerColor": "000000", - "outerAlpha": 0.5, - "feedbackStrokeColor": "0099FF", "offset": { "x": 0, "y": 0 - } + }, + "cropOffset": { + "x": 0, + "y": 0 + }, + "cropPadding": { + "x": 0, + "y": 0 + }, + "cornerRadius": 4, + "strokeColor": "0099ff", + "strokeWidth": 2, + "outerColor": "000000", + "feedbackStrokeColor": "0099FF", + "outerAlpha": 0.3 }, - "scanFeedback": { - "style": "CONTOUR_RECT", + "scanFeedbackConfig": { + "style": "rect", + "strokeWidth": 2, + "cornerRadius": 2, "strokeColor": "0099FF", - "fillColor": "220099FF", + "fillColor": "330099FF", "beepOnResult": true, "vibrateOnResult": true, - "blinkAnimationOnResult": true - }, - "cancelOnResult": true + "blinkAnimationOnResult": false + } } } ] } - -} } diff --git a/example/RNExampleApp/config/SerialNumber.js b/example/RNExampleApp/config/SerialNumber.js index 753c5746..7f67a966 100644 --- a/example/RNExampleApp/config/SerialNumber.js +++ b/example/RNExampleApp/config/SerialNumber.js @@ -1,41 +1,63 @@ export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "720p" - }, - "flash": { - "mode": "manual", - "alignment": "bottom_right", + license: 'ew0KICAibGljZW5zZUtleVZlcnNpb24iOiAiMy4wIiwNCiAgImRlYnVnUmVwb3J0aW5nIjogInBpbmciLA0KICAibWFqb3JWZXJzaW9uIjogIjM3IiwNCiAgInNjb3BlIjogWw0KICAgICJBTEwiLA0KICAgICJORkMiDQogIF0sDQogICJtYXhEYXlzTm90UmVwb3J0ZWQiOiA1LA0KICAiYWR2YW5jZWRCYXJjb2RlIjogdHJ1ZSwNCiAgIm11bHRpQmFyY29kZSI6IHRydWUsDQogICJzdXBwb3J0ZWRCYXJjb2RlRm9ybWF0cyI6IFsNCiAgICAiQUxMIg0KICBdLA0KICAicGxhdGZvcm0iOiBbDQogICAgImlPUyIsDQogICAgIkFuZHJvaWQiDQogIF0sDQogICJzaG93V2F0ZXJtYXJrIjogdHJ1ZSwNCiAgInRvbGVyYW5jZURheXMiOiAzMCwNCiAgInZhbGlkIjogIjIwMjMtMTItMzEiLA0KICAiaW9zSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0sDQogICJhbmRyb2lkSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0NCn0KSlhUTzVRSmZKa2FtUnR2VDc4QTFadGVhTXVzbmJlTW5HSHl0alZmczlxbUtIeDhCT3ltSGVXc2M2aXpjRExIenhtbklnU0JzS1RRNEdhSENsWCtvMEo2R3VtaFNUWHQrNVVuc1hVQVJ6aGhUdEhTa0l1ZVlRQ0p3dTI3bE9kWlBhNVoxSFNxN24weE9tek1jTjM3R1dsajVzVm9SY2pqaUswYVVnY0M5cDFRT0svK29ZejAvWlR2dXFGVjZUeHdiUHkyc3RqaDhLdS9NaXhtcFZFVmh0eWVzMEU2ZzhNVkdBNmNPU1h4NDVXVzgvR0NUWEpqdFJ6NnM2UFBDYzdYSXhQalFjOVAxdzBtblpFYTdjUHpMS3M0Y3hoYjQwSmluSU5qZXp6MDl1em9kbnZUR3VlSEIwcXIzUWNlVmdkS1JVQzhDc24zNmJLM2NLVmVpOVdTUlVRPT0=', + "options": { + "doneButtonConfig": { + "offset.y": -88 + } + }, + "cameraConfig": { + "captureResolution": "1080p", + "pictureResolution": "1080p", + "zoomGesture": true + }, + "flashConfig": { + "mode": "manual", + "alignment": "top_right" + }, + "viewPluginConfig": { + "pluginConfig": { + "id": "com.anyline.configs.plugin.universal-serial-number", + "ocrConfig": { + "scanMode": "auto" + }, + "cancelOnResult": true }, - "viewPlugin": { - "plugin": { - "id": "Meter_ID", - "meterPlugin": { - "scanMode": "SERIAL_NUMBER", - "serialNumberCharWhitelist" : '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ', - "serialNumberValidationRegex" : '^[0-9A-Z]{5,}$' - } + "cutoutConfig": { + "animation": "none", + "maxWidthPercent": "80%", + "alignment": "top_half", + "ratioFromSize": { + "width": 5, + "height": 1 }, - "cutoutConfig": { - "style": "rect", - "alignment": "top_half", - "strokeWidth": 2, - "cornerRadius": 4, - "strokeColor": "FFFFFF", - "outerColor": "000000", - "outerAlpha": 0.3, - "feedbackStrokeColor": "0099FF" + "offset": { + "x": 0, + "y": 0 }, - "scanFeedback": { - "style": "CONTOUR_RECT", - "strokeColor": "0099FF", - "fillColor": "220099FF", - "blinkOnResult": true, - "beepOnResult": true, - "vibrateOnResult": true + "cropOffset": { + "x": 0, + "y": 0 }, - "cancelOnResult": true + "cropPadding": { + "x": 0, + "y": 0 + }, + "cornerRadius": 4, + "strokeColor": "0099ff", + "strokeWidth": 2, + "outerColor": "000000", + "feedbackStrokeColor": "0099FF", + "outerAlpha": 0.3 + }, + "scanFeedbackConfig": { + "style": "rect", + "strokeWidth": 2, + "cornerRadius": 2, + "strokeColor": "0099FF", + "fillColor": "330099FF", + "beepOnResult": true, + "vibrateOnResult": true, + "blinkAnimationOnResult": false } } } \ No newline at end of file diff --git a/example/RNExampleApp/config/SerialScanningConfig.js b/example/RNExampleApp/config/SerialScanningConfig.js index c4954fc9..4f6fbf21 100644 --- a/example/RNExampleApp/config/SerialScanningConfig.js +++ b/example/RNExampleApp/config/SerialScanningConfig.js @@ -1,147 +1,155 @@ export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "1080p", - "pictureResolution": "1080p" - }, - "flash": { - "mode": "manual", - "alignment": "top_right" - }, - "serialViewPluginComposite": { - "id": "LP_DL_VIN", - "cancelOnResult": true, - "viewPlugins": [ - { - "viewPlugin": { - "plugin": { - "id": "LICENSE_PLATE", - "licensePlatePlugin": { - "scanMode": "AUTO" - } + license: 'ew0KICAibGljZW5zZUtleVZlcnNpb24iOiAiMy4wIiwNCiAgImRlYnVnUmVwb3J0aW5nIjogInBpbmciLA0KICAibWFqb3JWZXJzaW9uIjogIjM3IiwNCiAgInNjb3BlIjogWw0KICAgICJBTEwiLA0KICAgICJORkMiDQogIF0sDQogICJtYXhEYXlzTm90UmVwb3J0ZWQiOiA1LA0KICAiYWR2YW5jZWRCYXJjb2RlIjogdHJ1ZSwNCiAgIm11bHRpQmFyY29kZSI6IHRydWUsDQogICJzdXBwb3J0ZWRCYXJjb2RlRm9ybWF0cyI6IFsNCiAgICAiQUxMIg0KICBdLA0KICAicGxhdGZvcm0iOiBbDQogICAgImlPUyIsDQogICAgIkFuZHJvaWQiDQogIF0sDQogICJzaG93V2F0ZXJtYXJrIjogdHJ1ZSwNCiAgInRvbGVyYW5jZURheXMiOiAzMCwNCiAgInZhbGlkIjogIjIwMjMtMTItMzEiLA0KICAiaW9zSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0sDQogICJhbmRyb2lkSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0NCn0KSlhUTzVRSmZKa2FtUnR2VDc4QTFadGVhTXVzbmJlTW5HSHl0alZmczlxbUtIeDhCT3ltSGVXc2M2aXpjRExIenhtbklnU0JzS1RRNEdhSENsWCtvMEo2R3VtaFNUWHQrNVVuc1hVQVJ6aGhUdEhTa0l1ZVlRQ0p3dTI3bE9kWlBhNVoxSFNxN24weE9tek1jTjM3R1dsajVzVm9SY2pqaUswYVVnY0M5cDFRT0svK29ZejAvWlR2dXFGVjZUeHdiUHkyc3RqaDhLdS9NaXhtcFZFVmh0eWVzMEU2ZzhNVkdBNmNPU1h4NDVXVzgvR0NUWEpqdFJ6NnM2UFBDYzdYSXhQalFjOVAxdzBtblpFYTdjUHpMS3M0Y3hoYjQwSmluSU5qZXp6MDl1em9kbnZUR3VlSEIwcXIzUWNlVmdkS1JVQzhDc24zNmJLM2NLVmVpOVdTUlVRPT0=', + "options": { + "doneButtonConfig": { + "offset.y": -88 + } + }, + "cameraConfig": { + "captureResolution": "1080p" + }, + "flashConfig": { + "mode": "manual", + "alignment": "top_left" + }, + "viewPluginCompositeConfig": { + "id": "energy_process", + "processingMode": "sequential", + "viewPlugins": [ + { + "viewPluginConfig": { + "pluginConfig": { + "id": "license-plate-eu", + "licensePlateConfig": { + "scanMode": "auto" }, - "cutoutConfig": { - "style": "rect", - "maxWidthPercent": "80%", - "maxHeightPercent": "80%", - "alignment": "top_half", - "width": 720, - "ratioFromSize": { - "width": 2, - "height": 1 - }, - "strokeWidth": 2, - "cornerRadius": 10, - "strokeColor": "FFFFFF", - "outerColor": "000000", - "outerAlpha": 0.3, - "feedbackStrokeColor": "0099FF" + "cancelOnResult": true + }, + "cutoutConfig": { + "animation": "none", + "maxWidthPercent": "80%", + "maxHeightPercent": "80%", + "alignment": "top_half", + "ratioFromSize": { + "width": 4, + "height": 1 }, - "scanFeedback": { - "style": "rect", - "strokeWidth": 2, - "strokeColor": "0099FF", - "fillColor": "330099FF", - "cornerRadius": 0, - "beepOnResult": true, - "vibrateOnResult": true, - "blinkAnimationOnResult": true + "offset": { + "x": 0, + "y": 40 }, - "cancelOnResult": true - } - }, - { - "viewPlugin": { - "plugin": { - "id": "DRIVING_LICENSE", - "idPlugin": { - "universalIdConfig": { - "allowedLayouts": { - "drivingLicense": [] - }, - "drivingLicense": { - "surname": {"scanOption": 0, "minConfidence": 40}, - "givenNames": {"scanOption": 0, "minConfidence": 40}, - "dateOfBirth": {"scanOption": 0, "minConfidence": 50}, - "placeOfBirth": {"scanOption": 1, "minConfidence": 50}, - "dateOfIssue": {"scanOption": 0, "minConfidence": 50}, - "dateOfExpiry": {"scanOption": 1, "minConfidence": 50}, - "authority": {"scanOption": 1, "minConfidence": 30}, - "documentNumber": {"scanOption": 0, "minConfidence": 40}, - "categories": {"scanOption": 1, "minConfidence": 30}, - "address": {"scanOption": 1} - } - } - } + "cropPadding": { + "x": 0, + "y": 0 }, - "cutoutConfig" : { - "style": "rect", - "maxWidthPercent": "99%", - "maxHeightPercent": "100%", - "alignment": "center", - "ratioFromSize" : { - "width": 560, - "height": 354 - }, - "strokeWidth": 2, - "cornerRadius": 4, - "strokeColor": "FFFFFF", - "outerColor": "000000", - "outerAlpha": 0.3, - "feedbackStrokeColor": "0099FF" + "cropOffset": { + "x": 0, + "y": 0 }, - "scanFeedback" : { - "fillColor" : "220099FF", - "style": "CONTOUR_POINT", - "strokeColor": "0099FF", - "strokeWidth": 2, - "blinkOnResult": true, - "beepOnResult": true, - "vibrateOnResult": true + "cornerRadius": 4, + "strokeColor": "0099ff", + "strokeWidth": 2, + "feedbackStrokeColor": "0099ff", + "outerColor": "000000", + "outerAlpha": 0.3 + }, + "scanFeedbackConfig": { + "style": "rect", + "strokeWidth": 2, + "animationDuration": 0, + "strokeColor": "0099ff", + "cornerRadius": 0, + "fillColor": "330099ff", + "beepOnResult": true, + "vibrateOnResult": true + } + } + }, + { + "viewPluginConfig": { + "pluginConfig": { + "id": "driver-license-eu", + "universalIdConfig": { + "allowedLayouts": { + "drivingLicense": [] + }, + "alphabet": "latin" }, "cancelOnResult": true - } - }, - { - "viewPlugin": { - "plugin": { - "id": "VIN", - "ocrPlugin": { - "vinConfig": { - } - } + }, + "cutoutConfig": { + "style": "animated_rect", + "maxWidthPercent": "90%", + "maxHeightPercent": "90%", + "alignment": "center", + "strokeWidth": 2, + "cornerRadius": 4, + "strokeColor": "0099FF", + "outerColor": "000000", + "outerAlpha": 0.3, + "ratioFromSize": { + "width": 50, + "height": 31 }, - "cutoutConfig": { - "style": "rect", - "maxWidthPercent": "70%", - "alignment": "top_half", - "ratioFromSize": { - "width": 62, - "height": 9 - }, - "outerColor": "000000", - "outerAlpha": 0.3, - "strokeWidth": 2, - "strokeColor": "FFFFFF", - "cornerRadius": 4, - "feedbackStrokeColor": "0099FF" + "cropPadding": { + "x": 25, + "y": 25 }, - "scanFeedback": { - "animation": "traverse_multi", - "animationDuration": 250, - "style": "contour_rect", - "strokeWidth": 2, - "strokeColor": "0099FF", - "fillColor": "220099FF", - "beepOnResult": true, - "vibrateOnResult": true, - "blinkAnimationOnResult": true + "cropOffset": { + "x": 0, + "y": 0 }, + "feedbackStrokeColor": "0099FF" + }, + "scanFeedbackConfig": { + "style": "CONTOUR_RECT", + "visualFeedbackRedrawTimeout": 100, + "strokeColor": "0099FF", + "fillColor": "220099FF", + "beepOnResult": true, + "vibrateOnResult": true, + "strokeWidth": 2 + } + } + }, + { + "viewPluginConfig": { + "pluginConfig": { + "id": "vin", + "vinConfig": {}, "cancelOnResult": true + }, + "cutoutConfig": { + "animation": "none", + "maxWidthPercent": "90%", + "maxHeightPercent": "100%", + "width": 0, + "alignment": "top_half", + "ratioFromSize": { + "width": 11, + "height": 2 + }, + "offset": { "x": 0, "y": 0 }, + "cropOffset": { "x": 0, "y": 0 }, + "cropPadding": { "x": 0, "y": 0 }, + "cornerRadius": 2, + "strokeColor": "0099ff", + "strokeWidth": 2, + "outerColor": "000000", + "feedbackStrokeColor": "0099FF", + "outerAlpha": 0.3 + }, + "scanFeedbackConfig": { + "style": "contour_rect", + "strokeWidth": 2, + "cornerRadius": 2, + "strokeColor": "0099FF", + "fillColor": "330099FF", + "beepOnResult": true, + "vibrateOnResult": true } } - ] - } + } + ] } } diff --git a/example/RNExampleApp/config/TINConfig.js b/example/RNExampleApp/config/TINConfig.js index 0f111f2e..aa294aa8 100644 --- a/example/RNExampleApp/config/TINConfig.js +++ b/example/RNExampleApp/config/TINConfig.js @@ -1,49 +1,64 @@ export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "720p" + license: 'ew0KICAibGljZW5zZUtleVZlcnNpb24iOiAiMy4wIiwNCiAgImRlYnVnUmVwb3J0aW5nIjogInBpbmciLA0KICAibWFqb3JWZXJzaW9uIjogIjM3IiwNCiAgInNjb3BlIjogWw0KICAgICJBTEwiLA0KICAgICJORkMiDQogIF0sDQogICJtYXhEYXlzTm90UmVwb3J0ZWQiOiA1LA0KICAiYWR2YW5jZWRCYXJjb2RlIjogdHJ1ZSwNCiAgIm11bHRpQmFyY29kZSI6IHRydWUsDQogICJzdXBwb3J0ZWRCYXJjb2RlRm9ybWF0cyI6IFsNCiAgICAiQUxMIg0KICBdLA0KICAicGxhdGZvcm0iOiBbDQogICAgImlPUyIsDQogICAgIkFuZHJvaWQiDQogIF0sDQogICJzaG93V2F0ZXJtYXJrIjogdHJ1ZSwNCiAgInRvbGVyYW5jZURheXMiOiAzMCwNCiAgInZhbGlkIjogIjIwMjMtMTItMzEiLA0KICAiaW9zSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0sDQogICJhbmRyb2lkSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0NCn0KSlhUTzVRSmZKa2FtUnR2VDc4QTFadGVhTXVzbmJlTW5HSHl0alZmczlxbUtIeDhCT3ltSGVXc2M2aXpjRExIenhtbklnU0JzS1RRNEdhSENsWCtvMEo2R3VtaFNUWHQrNVVuc1hVQVJ6aGhUdEhTa0l1ZVlRQ0p3dTI3bE9kWlBhNVoxSFNxN24weE9tek1jTjM3R1dsajVzVm9SY2pqaUswYVVnY0M5cDFRT0svK29ZejAvWlR2dXFGVjZUeHdiUHkyc3RqaDhLdS9NaXhtcFZFVmh0eWVzMEU2ZzhNVkdBNmNPU1h4NDVXVzgvR0NUWEpqdFJ6NnM2UFBDYzdYSXhQalFjOVAxdzBtblpFYTdjUHpMS3M0Y3hoYjQwSmluSU5qZXp6MDl1em9kbnZUR3VlSEIwcXIzUWNlVmdkS1JVQzhDc24zNmJLM2NLVmVpOVdTUlVRPT0=', + "options": { + "doneButtonConfig": { + "offset.y": -88 }, - "flash": { - "mode": "manual", - "alignment": "bottom_right" + "segmentConfig": { + "titles": ["Universal", "DOT", "DOT-Strict"], + "modes": ["UNIVERSAL", "DOT", "DOT_STRICT"], + "offset.y": -24 }, - "viewPlugin" : { - "plugin": { - "id": "TIN", - "tirePlugin": { - "tinConfig":{ - "scanMode" : "UNIVERSAL" - } - } - }, - "cutoutConfig" : { - "style": "rect", + "rotateButton": { + "alignment": "top_right", + "offset": { + "x": 0, + "y": 0 + } + }, + "defaultOrientation": "landscape" + }, + "cameraConfig": { + "captureResolution": "1080p", + "zoomGesture": true + }, + "flashConfig": { + "mode": "manual", + "alignment": "top_left" + }, + "viewPluginConfig": { + "pluginConfig": { + "id": "TIRE", + "cancelOnResult": true, + "tinConfig": { + "scanMode": "UNIVERSAL" + } + }, + "cutoutConfig": { + "style": "animated_rect", + "maxWidthPercent": "80%", + "maxHeightPercent": "80%", + "alignment": "center", + "strokeWidth": 2, + "cornerRadius": 4, + "strokeColor": "0099FF", + "outerColor": "000000", + "outerAlpha": 0.3, + "width": 720, + "ratioFromSize": { "width": 720, - "alignment": "center", - "maxWidthPercent": "80%", - "ratioFromSize": { - "width": 720, - "height": 144 - }, - "outerColor": "000000", - "outerAlpha": 0.3, - "strokeWidth": 2, - "strokeColor": "FFFFFF", - "cornerRadius": 2, - "feedbackStrokeColor": "0099FF" + "height": 144 }, - "scanFeedback" : { - "animation": "traverse_multi", - "animationDuration" : 250, - "style": "contour_rect", - "strokeWidth": 2, - "strokeColor": "0099FF", - "beepOnResult": true, - "vibrateOnResult": true, - "blinkAnimationOnResult": true - }, - "cancelOnResult" : true + "feedbackStrokeColor": "0099FF" + }, + "scanFeedbackConfig": { + "animation": "traverse_multi", + "animationDuration": 250, + "style": "rect", + "strokeColor": "0099FF", + "beepOnResult": true, + "vibrateOnResult": false, + "strokeWidth": 2 } } } \ No newline at end of file diff --git a/example/RNExampleApp/config/TireSizeConfig.js b/example/RNExampleApp/config/TireSizeConfig.js index b48e1bd8..7f93ee50 100644 --- a/example/RNExampleApp/config/TireSizeConfig.js +++ b/example/RNExampleApp/config/TireSizeConfig.js @@ -1,48 +1,51 @@ export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "720p" - }, - "flash": { - "mode": "manual", - "alignment": "bottom_right" + license: 'ew0KICAibGljZW5zZUtleVZlcnNpb24iOiAiMy4wIiwNCiAgImRlYnVnUmVwb3J0aW5nIjogInBpbmciLA0KICAibWFqb3JWZXJzaW9uIjogIjM3IiwNCiAgInNjb3BlIjogWw0KICAgICJBTEwiLA0KICAgICJORkMiDQogIF0sDQogICJtYXhEYXlzTm90UmVwb3J0ZWQiOiA1LA0KICAiYWR2YW5jZWRCYXJjb2RlIjogdHJ1ZSwNCiAgIm11bHRpQmFyY29kZSI6IHRydWUsDQogICJzdXBwb3J0ZWRCYXJjb2RlRm9ybWF0cyI6IFsNCiAgICAiQUxMIg0KICBdLA0KICAicGxhdGZvcm0iOiBbDQogICAgImlPUyIsDQogICAgIkFuZHJvaWQiDQogIF0sDQogICJzaG93V2F0ZXJtYXJrIjogdHJ1ZSwNCiAgInRvbGVyYW5jZURheXMiOiAzMCwNCiAgInZhbGlkIjogIjIwMjMtMTItMzEiLA0KICAiaW9zSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0sDQogICJhbmRyb2lkSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0NCn0KSlhUTzVRSmZKa2FtUnR2VDc4QTFadGVhTXVzbmJlTW5HSHl0alZmczlxbUtIeDhCT3ltSGVXc2M2aXpjRExIenhtbklnU0JzS1RRNEdhSENsWCtvMEo2R3VtaFNUWHQrNVVuc1hVQVJ6aGhUdEhTa0l1ZVlRQ0p3dTI3bE9kWlBhNVoxSFNxN24weE9tek1jTjM3R1dsajVzVm9SY2pqaUswYVVnY0M5cDFRT0svK29ZejAvWlR2dXFGVjZUeHdiUHkyc3RqaDhLdS9NaXhtcFZFVmh0eWVzMEU2ZzhNVkdBNmNPU1h4NDVXVzgvR0NUWEpqdFJ6NnM2UFBDYzdYSXhQalFjOVAxdzBtblpFYTdjUHpMS3M0Y3hoYjQwSmluSU5qZXp6MDl1em9kbnZUR3VlSEIwcXIzUWNlVmdkS1JVQzhDc24zNmJLM2NLVmVpOVdTUlVRPT0=', + "options": { + "doneButtonConfig": { + "offset.y": -88 + } + }, + "cameraConfig": { + "captureResolution": "1080p", + "zoomGesture": true + }, + "flashConfig": { + "mode": "manual", + "alignment": "top_left" + }, + "viewPluginConfig": { + "pluginConfig": { + "id": "TIRE", + "cancelOnResult": true, + "tireSizeConfig": { + "upsideDownMode": "AUTO" + } }, - "viewPlugin" : { - "plugin": { - "id": "TIRE_SIZE", - "tirePlugin": { - "tireSizeConfig":{ - } - } - }, - "cutoutConfig" : { - "style": "rect", + "cutoutConfig": { + "style": "animated_rect", + "maxWidthPercent": "80%", + "maxHeightPercent": "80%", + "alignment": "center", + "strokeWidth": 2, + "cornerRadius": 4, + "strokeColor": "0099FF", + "outerColor": "000000", + "outerAlpha": 0.3, + "width": 720, + "ratioFromSize": { "width": 720, - "alignment": "center", - "maxWidthPercent": "80%", - "ratioFromSize": { - "width": 720, - "height": 144 - }, - "outerColor": "000000", - "outerAlpha": 0.3, - "strokeWidth": 2, - "strokeColor": "FFFFFF", - "cornerRadius": 2, - "feedbackStrokeColor": "0099FF" + "height": 144 }, - "scanFeedback" : { - "animation": "traverse_multi", - "animationDuration" : 250, - "style": "rect", - "strokeWidth": 2, - "strokeColor": "0099FF", - "beepOnResult": true, - "vibrateOnResult": true, - "blinkAnimationOnResult": true - }, - "cancelOnResult" : true + "feedbackStrokeColor": "0099FF" + }, + "scanFeedbackConfig": { + "animation": "traverse_multi", + "animationDuration": 250, + "style": "rect", + "strokeColor": "0099FF", + "beepOnResult": true, + "vibrateOnResult": false, + "strokeWidth": 2 } } } diff --git a/example/RNExampleApp/config/USNRConfig.js b/example/RNExampleApp/config/USNRConfig.js index 713ec51d..dc4fffd9 100644 --- a/example/RNExampleApp/config/USNRConfig.js +++ b/example/RNExampleApp/config/USNRConfig.js @@ -1,51 +1,63 @@ export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "720" - }, - "flash": { - "mode": "manual", - "alignment": "bottom_right" + license: 'ew0KICAibGljZW5zZUtleVZlcnNpb24iOiAiMy4wIiwNCiAgImRlYnVnUmVwb3J0aW5nIjogInBpbmciLA0KICAibWFqb3JWZXJzaW9uIjogIjM3IiwNCiAgInNjb3BlIjogWw0KICAgICJBTEwiLA0KICAgICJORkMiDQogIF0sDQogICJtYXhEYXlzTm90UmVwb3J0ZWQiOiA1LA0KICAiYWR2YW5jZWRCYXJjb2RlIjogdHJ1ZSwNCiAgIm11bHRpQmFyY29kZSI6IHRydWUsDQogICJzdXBwb3J0ZWRCYXJjb2RlRm9ybWF0cyI6IFsNCiAgICAiQUxMIg0KICBdLA0KICAicGxhdGZvcm0iOiBbDQogICAgImlPUyIsDQogICAgIkFuZHJvaWQiDQogIF0sDQogICJzaG93V2F0ZXJtYXJrIjogdHJ1ZSwNCiAgInRvbGVyYW5jZURheXMiOiAzMCwNCiAgInZhbGlkIjogIjIwMjMtMTItMzEiLA0KICAiaW9zSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0sDQogICJhbmRyb2lkSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0NCn0KSlhUTzVRSmZKa2FtUnR2VDc4QTFadGVhTXVzbmJlTW5HSHl0alZmczlxbUtIeDhCT3ltSGVXc2M2aXpjRExIenhtbklnU0JzS1RRNEdhSENsWCtvMEo2R3VtaFNUWHQrNVVuc1hVQVJ6aGhUdEhTa0l1ZVlRQ0p3dTI3bE9kWlBhNVoxSFNxN24weE9tek1jTjM3R1dsajVzVm9SY2pqaUswYVVnY0M5cDFRT0svK29ZejAvWlR2dXFGVjZUeHdiUHkyc3RqaDhLdS9NaXhtcFZFVmh0eWVzMEU2ZzhNVkdBNmNPU1h4NDVXVzgvR0NUWEpqdFJ6NnM2UFBDYzdYSXhQalFjOVAxdzBtblpFYTdjUHpMS3M0Y3hoYjQwSmluSU5qZXp6MDl1em9kbnZUR3VlSEIwcXIzUWNlVmdkS1JVQzhDc24zNmJLM2NLVmVpOVdTUlVRPT0=', + "options": { + "doneButtonConfig": { + "offset.y": -88 + } + }, + "cameraConfig": { + "captureResolution": "1080p", + "pictureResolution": "1080p", + "zoomGesture": true + }, + "flashConfig": { + "mode": "manual", + "alignment": "top_right" + }, + "viewPluginConfig": { + "pluginConfig": { + "id": "com.anyline.configs.plugin.universal-serial-number", + "ocrConfig": { + "scanMode": "auto" + }, + "cancelOnResult": true }, - "viewPlugin": { - "plugin": { - "id": "USNR_ID", - "ocrPlugin": { - "ocrConfig" : { - "scanMode" : "AUTO", - } - } + "cutoutConfig": { + "animation": "none", + "maxWidthPercent": "80%", + "alignment": "top_half", + "ratioFromSize": { + "width": 5, + "height": 1 }, - "cutoutConfig": { - "style": "rect", - "width": 720, - "alignment": "top_half", - "maxWidthPercent": "80%", - "ratioFromSize": { - "width": 720, - "height": 144 - }, - "strokeWidth": 2, - "strokeColor": "FFFFFF", - "cornerRadius": 4, - "outerColor": "000000", - "outerAlpha": 0.5, - "feedbackStrokeColor": "0099FF", - "offset": { - "x": 0, - "y": -15 - } + "offset": { + "x": 0, + "y": 0 }, - "scanFeedback": { - "style": "CONTOUR_RECT", - "strokeColor": "0099FF", - "fillColor": "220099FF", - "beepOnResult": true, - "vibrateOnResult": true, - "blinkAnimationOnResult": true + "cropOffset": { + "x": 0, + "y": 0 }, - "cancelOnResult": true + "cropPadding": { + "x": 0, + "y": 0 + }, + "cornerRadius": 4, + "strokeColor": "0099ff", + "strokeWidth": 2, + "outerColor": "000000", + "feedbackStrokeColor": "0099FF", + "outerAlpha": 0.3 + }, + "scanFeedbackConfig": { + "style": "rect", + "strokeWidth": 2, + "cornerRadius": 2, + "strokeColor": "0099FF", + "fillColor": "330099FF", + "beepOnResult": true, + "vibrateOnResult": true, + "blinkAnimationOnResult": false } } } diff --git a/example/RNExampleApp/config/UniversalIdConfig.js b/example/RNExampleApp/config/UniversalIdConfig.js index aede5d51..e1303d46 100755 --- a/example/RNExampleApp/config/UniversalIdConfig.js +++ b/example/RNExampleApp/config/UniversalIdConfig.js @@ -1,97 +1,152 @@ export default { - license: 'ewogICJsaWNlbnNlS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3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera" : { - "captureResolution" : "1080p", - "zoomGesture": true - }, - "flash" : { - "mode": "manual", - "alignment": "bottom_right", - "imageOn": "flash_on", - "imageOff": "flash_off" - }, - "viewPlugin" : { - "plugin":{ - "id":"ID", - "idPlugin": { - "universalIdConfig": { - "faceDetection": true, - "allowedLayouts": { - "mrz": [], - "drivingLicense": [], - "idFront": [], - "insuranceCard" : [] - }, - "drivingLicense": { - "surname": {"scanOption": 0, "minConfidence": 40}, - "givenNames": {"scanOption": 0, "minConfidence": 40}, - "dateOfBirth": {"scanOption": 0, "minConfidence": 50}, - "placeOfBirth": {"scanOption": 1, "minConfidence": 50}, - "dateOfIssue": {"scanOption": 0, "minConfidence": 50}, - "dateOfExpiry": {"scanOption": 1, "minConfidence": 50}, - "authority": {"scanOption": 1, "minConfidence": 30}, - "documentNumber": {"scanOption": 0, "minConfidence": 40}, - "categories": {"scanOption": 1, "minConfidence": 30}, - "address": {"scanOption": 1} - }, - "idFront": { - "surname": {"scanOption": 0, "minConfidence": 60}, - "givenNames": {"scanOption": 0, "minConfidence": 60}, - "dateOfBirth": {"scanOption": 0, "minConfidence": 60}, - "placeOfBirth": {"scanOption": 1, "minConfidence": 60}, - "dateOfExpiry": {"scanOption": 1, "minConfidence": 60}, - "cardAccessNumber": {"scanOption": 1, "minConfidence": 60}, - "documentNumber": {"scanOption": 0, "minConfidence": 60}, - "nationality": {"scanOption": 1, "minConfidence": 60} - }, - "insuranceCard": { - "nationality": {"scanOption": 0, "minConfidence": 50}, - "surname": {"scanOption": 0, "minConfidence": 50}, - "givenNames": {"scanOption": 0, "minConfidence": 50}, - "dateOfBirth": {"scanOption": 0, "minConfidence": 50}, - "personalNumber": {"scanOption": 0, "minConfidence": 50}, - "authority": {"scanOption": 0, "minConfidence": 50}, - "documentNumber": {"scanOption": 0, "minConfidence": 50}, - "dateOfExpiry": {"scanOption": 0, "minConf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jQwSmluSU5qZXp6MDl1em9kbnZUR3VlSEIwcXIzUWNlVmdkS1JVQzhDc24zNmJLM2NLVmVpOVdTUlVRPT0=', + "options": { + "doneButtonConfig": { + "offset.y": -88 + } + }, + "cameraConfig": { + "captureResolution": "1080p", + "pictureResolution": "1080p" + }, + "flashConfig": { + "mode": "manual", + "alignment": "top_left", + "offset": { + "x": 0, + "y": 0 + } + }, + "viewPluginConfig": { + "pluginConfig": { + "id": "com.anyline.configs.plugin.id", + "universalIdConfig": { + "allowedLayouts": { + "mrz": [], + "insuranceCard": [], + "drivingLicense": [], + "idFront": [] + }, + "alphabet": "latin", + "insuranceCard": { + "lastName": { + "scanOption": 0, + "minConfidence": 50 + }, + "firstName": { + "scanOption": 0, + "minConfidence": 50 + }, + "dateOfBirth": { + "scanOption": 0, + "minConfidence": 50 + }, + "personalNumber": { + "scanOption": 0, + "minConfidence": 50 + }, + "authority": { + "scanOption": 0, + "minConfidence": 50 + }, + "documentNumber": { + "scanOption": 0, + "minConfidence": 50 + }, + "dateOfExpiry": { + "scanOption": 0, + "minConfidence": 50 + }, + "nationality": { + "scanOption": 0, + "minConfidence": 50 + } + }, + "idFront": { + "lastName": { + "scanOption": 0, + "minConfidence": 60 + }, + "firstName": { + "scanOption": 0, + "minConfidence": 60 + }, + "fullName": { + "scanOption": 0, + "minConfidence": 60 + }, + "dateOfBirth": { + "scanOption": 0, + "minConfidence": 60 + }, + "placeOfBirth": { + "scanOption": 1, + "minConfidence": 60 + }, + "dateOfIssue": { + "scanOption": 0, + "minConfidence": 60 + }, + "dateOfExpiry": { + "scanOption": 1, + "minConfidence": 60 + }, + "cardAccessNumber": { + "scanOption": 1, + "minConfidence": 60 + }, + "documentNumber": { + "scanOption": 0, + "minConfidence": 60 + }, + "nationality": { + "scanOption": 1, + "minConfidence": 60 + }, + "sex": { + "scanOption": 1, + "minConfidence": 60 + }, + "personalNumber": { + "scanOption": 1, + "minConfidence": 60 } } }, - "cutoutConfig" : { - "style": "animated_rect", - "maxWidthPercent": "90%", - "maxHeightPercent": "90%", - "alignment": "center", - "strokeWidth": 3, - "cornerRadius": 8, - "strokeColor": "FFFFFF", - "outerColor": "000000", - "outerAlpha": 0.3, - "ratioFromSize" : { - "width": 50, - "height": 31 - }, - "cropPadding": { - "x": -50, - "y": -50 - }, - "cropOffset": { - "x": 0, - "y": 0 - }, - "feedbackStrokeColor": "0099FF" + "cancelOnResult": true + }, + "cutoutConfig": { + "style": "animated_rect", + "maxWidthPercent": "90%", + "maxHeightPercent": "90%", + "alignment": "center", + "strokeWidth": 2, + "cornerRadius": 4, + "strokeColor": "0099FF", + "outerColor": "000000", + "outerAlpha": 0.3, + "ratioFromSize": { + "width": 50, + "height": 31 + }, + "cropPadding": { + "x": 25, + "y": 25 }, - "scanFeedback" : { - "style": "CONTOUR_RECT", - "visualFeedbackRedrawTimeout": 100, - "strokeColor": "0099FF", - "fillColor" : "220099FF", - "beepOnResult": true, - "vibrateOnResult": true, - "strokeWidth": 2 + "cropOffset": { + "x": 0, + "y": 0 }, - "cancelOnResult" : true + "feedbackStrokeColor": "0099FF" + }, + "scanFeedbackConfig": { + "style": "CONTOUR_RECT", + "visualFeedbackRedrawTimeout": 100, + "strokeColor": "0099FF", + "fillColor": "220099FF", + "beepOnResult": true, + "vibrateOnResult": true, + "strokeWidth": 2 } - } + } } diff --git a/example/RNExampleApp/config/VINConfig.js b/example/RNExampleApp/config/VINConfig.js index d84371ef..e7ae6ac1 100644 --- a/example/RNExampleApp/config/VINConfig.js +++ b/example/RNExampleApp/config/VINConfig.js @@ -1,50 +1,50 @@ export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "720" - }, - "flash": { - "mode": "manual", - "alignment": "bottom_left", + license: 'ew0KICAibGljZW5zZUtleVZlcnNpb24iOiAiMy4wIiwNCiAgImRlYnVnUmVwb3J0aW5nIjogInBpbmciLA0KIC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neButtonConfig": { + "offset.y": -88 + } + }, + "cameraConfig": { + "captureResolution": "1080p", + "zoomGesture": true + }, + "flashConfig": { + "mode": "manual", + "alignment": "top_left" + }, + "viewPluginConfig": { + "pluginConfig": { + "id": "VIN", + "cancelOnResult": true, + "vinConfig": {} }, - "viewPlugin": { - "plugin": { - "id": "VIN_ID", - "ocrPlugin": { - "vinConfig":{ - } - } - }, - "cutoutConfig": { - "style": "rect", - "width": 720, - "alignment": "top_half", - "maxWidthPercent": "70%", - "ratioFromSize": { - "width": 62, - "height": 9 - }, - "strokeWidth": 1, - "strokeColor": "FFFFFF", - "cornerRadius": 2, - "outerColor": "000000", - "outerAlpha": 0.3, - "feedbackStrokeColor": "0099FF" + "cutoutConfig": { + "style": "animated_rect", + "maxWidthPercent": "70%", + "maxHeightPercent": "70%", + "alignment": "top_half", + "ratioFromSize": { + "width": 62, + "height": 9 }, - "scanFeedback": { - "animation": "traverse_multi", - "animationDuration": 250, - "style": "contour_rect", - "strokeWidth": 2, - "strokeColor": "0099FF", - "beepOnResult": false, - "vibrateOnResult": true, - "blinkAnimationOnResult": true, - "cancelOnResult": true - }, - "cancelOnResult": true, - "reportingEnabled": true + "outerColor": "000000", + "outerAlpha": 0.3, + "strokeWidth": 2, + "strokeColor": "0099FF", + "cornerRadius": 4, + "feedbackStrokeColor": "0099FF" + }, + "scanFeedbackConfig": { + "animation": "traverse_multi", + "animationDuration": 250, + "style": "contour_rect", + "strokeWidth": 2, + "strokeColor": "0099FF", + "fillColor": "220099FF", + "beepOnResult": true, + "vibrateOnResult": true, + "blinkAnimationOnResult": true } } } diff --git a/example/RNExampleApp/config/VRCConfig.js b/example/RNExampleApp/config/VRCConfig.js new file mode 100644 index 00000000..06675be0 --- /dev/null +++ b/example/RNExampleApp/config/VRCConfig.js @@ -0,0 +1,112 @@ +export default { + license: 'ew0KICAibGljZW5zZUtleVZlcnNpb24iOiAiMy4wIiwNCiAgImRlYnVnUmVwb3J0aW5nIjogInBpbmciLA0KICAibW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onConfig": { + "offset.y": -88 + } + }, + "flashConfig": { + "mode": "manual", + "alignment": "bottom_right" + }, + "viewPluginConfig": { + "pluginConfig": { + "id": "com.anyline.configs.plugin.vrc", + "vehicleRegistrationCertificateConfig": { + "vehicleRegistrationCertificate": { + "documentNumber": { + "scanOption": 1, + "minConfidence": 40 + }, + "licensePlate": { + "scanOption": 0, + "minConfidence": 40 + }, + "lastName": { + "scanOption": 0, + "minConfidence": 60 + }, + "firstName": { + "scanOption": 1, + "minConfidence": 40 + }, + "address": { + "scanOption": 0, + "minConfidence": 50 + }, + "firstIssued": { + "scanOption": 0, + "minConfidence": 60 + }, + "manufacturerCode": { + "scanOption": 0, + "minConfidence": 50 + }, + "vehicleTypeCode": { + "scanOption": 0, + "minConfidence": 50 + }, + "vehicleIdentificationNumber": { + "scanOption": 0, + "minConfidence": 60 + }, + "brand": { + "scanOption": 1, + "minConfidence": 40 + }, + "vehicleType": { + "scanOption": 1, + "minConfidence": 40 + }, + "displacement": { + "scanOption": 1, + "minConfidence": 40 + }, + "tire": { + "scanOption": 1, + "minConfidence": 50 + } + } + }, + "cancelOnResult": true + }, + "cutoutConfig": { + "animation": "none", + "maxWidthPercent": "90%", + "maxHeightPercent": "80%", + "alignment": "center", + "ratioFromSize": { + "width": 90, + "height": 46 + }, + "offset": { + "x": 0, + "y": 0 + }, + "cropOffset": { + "x": 0, + "y": 0 + }, + "cropPadding": { + "x": 50, + "y": 50 + }, + "cornerRadius": 4, + "strokeColor": "0099FF", + "strokeWidth": 2, + "outerColor": "000000", + "feedbackStrokeColor": "0099FF", + "outerAlpha": 0.3 + }, + "scanFeedbackConfig": { + "style": "animated_rect", + "strokeWidth": 0, + "strokeColor": "0099ff", + "fillColor": "000099ff", + "beepOnResult": true, + "vibrateOnResult": true, + "blinkAnimationOnResult": false + } + } + } + \ No newline at end of file diff --git a/example/RNExampleApp/config/VerticalContainerConfig.js b/example/RNExampleApp/config/VerticalContainerConfig.js index 556dd174..174700e9 100644 --- a/example/RNExampleApp/config/VerticalContainerConfig.js +++ b/example/RNExampleApp/config/VerticalContainerConfig.js @@ -1,48 +1,66 @@ export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "1080p" - }, - "flash": { - "mode": "manual", - "alignment": "bottom_right" + license: 'ew0KICAibGljZW5zZUtleVZlcnNpb24iOiAiMy4wIiwNCiAgImRlYnVnUmVwb3J0aW5nIjogInBpbmciLA0KICAibWFqb3JWZXJzaW9uIjogIjM3IiwNCiAgInNjb3BlIjogWw0KICAgICJBTEwiLA0KICAgICJORkMiDQogIF0sDQogICJtYXhEYXlzTm90UmVwb3J0ZWQiOiA1LA0KICAiYWR2YW5jZWRCYXJjb2RlIjogdHJ1ZSwNCiAgIm11bHRpQmFyY29kZSI6IHRydWUsDQogICJzdXBwb3J0ZWRCYXJjb2RlRm9ybWF0cyI6IFsNCiAgICAiQUxMIg0KICBdLA0KICAicGxhdGZvcm0iOiBbDQogICAgImlPUyIsDQogICAgIkFuZHJvaWQiDQogIF0sDQogICJzaG93V2F0ZXJtYXJrIjogdHJ1ZSwNCiAgInRvbGVyYW5jZURheXMiOiAzMCwNCiAgInZhbGlkIjogIjIwMjMtMTItMzEiLA0KICAiaW9zSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0sDQogICJhbmRyb2lkSWRlbnRpZmllciI6IFsNCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZXMucmVhY3RuYXRpdmUiDQogIF0NCn0KSlhUTzVRSmZKa2FtUnR2VDc4QTFadGVhTXVzbmJlTW5HSHl0alZmczlxbUtIeDhCT3ltSGVXc2M2aXpjRExIenhtbklnU0JzS1RRNEdhSENsWCtvMEo2R3VtaFNUWHQrNVVuc1hVQVJ6aGhUdEhTa0l1ZVlRQ0p3dTI3bE9kWlBhNVoxSFNxN24weE9tek1jTjM3R1dsajVzVm9SY2pqaUswYVVnY0M5cDFRT0svK29ZejAvWlR2dXFGVjZUeHdiUHkyc3RqaDhLdS9NaXhtcFZFVmh0eWVzMEU2ZzhNVkdBNmNPU1h4NDVXVzgvR0NUWEpqdFJ6NnM2UFBDYzdYSXhQalFjOVAxdzBtblpFYTdjUHpMS3M0Y3hoYjQwSmluSU5qZXp6MDl1em9kbnZUR3VlSEIwcXIzUWNlVmdkS1JVQzhDc24zNmJLM2NLVmVpOVdTUlVRPT0=', + "options": { + "doneButtonConfig": { + "offset.y": -88 + } + }, + "cameraConfig": { + "captureResolution": "1080p", + "pictureResolution": "1080p", + "zoomGesture": true + }, + "flashConfig": { + "mode": "manual", + "alignment": "top_right" + }, + "viewPluginConfig": { + "pluginConfig": { + "id": "com.anyline.configs.plugin.vertical-container", + "containerConfig": { + "scanMode": "VERTICAL" + }, + "cancelOnResult": true }, - "viewPlugin": { - "plugin": { - "id": "CONTAINER_ID", - "ocrPlugin": { - "containerConfig":{ - "scanMode": "vertical" - } - } + "cutoutConfig": { + "style": "rect", + "animation": "none", + "maxWidthPercent": "10%", + "alignment": "center", + "ratioFromSize": { + "width": 9, + "height": 62 }, - "cutoutConfig": { - "style": "rect", - "maxWidthPercent": "10%", - "alignment": "top_half", - "ratioFromSize": { - "width": 9, - "height": 62 - }, - "outerColor": "000000", - "outerAlpha": 0.3, - "strokeWidth": 1, - "strokeColor": "FFFFFF", - "cornerRadius": 2, - "feedbackStrokeColor": "0099FF", + "offset": { + "x": 0, + "y": 0 }, - "scanFeedback": { - "animation": "traverse_multi", - "animationDuration": 250, - "style": "contour_rect", - "strokeWidth": 2, - "strokeColor": "0099FF", - "beepOnResult": true, - "vibrateOnResult": true, - "blinkAnimationOnResult": true + "cropOffset": { + "x": 0, + "y": 0 }, - "cancelOnResult": true + "cropPadding": { + "x": 0, + "y": 0 + }, + "cornerRadius": 4, + "strokeColor": "0099ff", + "strokeWidth": 2, + "outerColor": "000000", + "feedbackStrokeColor": "0099FF", + "outerAlpha": 0.3 + }, + "scanFeedbackConfig": { + "style": "contour_rect", + "animation": "traverse_multi", + "animationDuration": 250, + "strokeWidth": 2, + "cornerRadius": 2, + "strokeColor": "0099FF", + "fillColor": "330099FF", + "beepOnResult": true, + "vibrateOnResult": true, + "blinkAnimationOnResult": true } } } diff --git a/example/RNExampleApp/config/VoucherConfig.js b/example/RNExampleApp/config/VoucherConfig.js deleted file mode 100644 index 677283f8..00000000 --- a/example/RNExampleApp/config/VoucherConfig.js +++ /dev/null @@ -1,52 +0,0 @@ -export default { - license: 'ewogICJsaWNlbnNlS2V5VmVyc2lvbiI6ICIzLjAiLAogICJkZWJ1Z1JlcG9ydGluZyI6ICJwaW5nIiwKICAibWFqb3JWZXJzaW9uIjogIjM3IiwKICAic2NvcGUiOiBbCiAgICAiQUxMIgogIF0sCiAgIm1heERheXNOb3RSZXBvcnRlZCI6IDUsCiAgImFkdmFuY2VkQmFyY29kZSI6IHRydWUsCiAgIm11bHRpQmFyY29kZSI6IHRydWUsCiAgInN1cHBvcnRlZEJhcmNvZGVGb3JtYXRzIjogWwogICAgIkFMTCIKICBdLAogICJwbGF0Zm9ybSI6IFsKICAgICJpT1MiLAogICAgIkFuZHJvaWQiCiAgXSwKICAic2hvd1dhdGVybWFyayI6IHRydWUsCiAgInRvbGVyYW5jZURheXMiOiAzMCwKICAidmFsaWQiOiAiMjAyMi0xMi0zMSIsCiAgImlvc0lkZW50aWZpZXIiOiBbCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZSIsCiAgICAiY29tLmFueWxpbmUuZXhhbXBsZS5yZWFjdG5hdGl2ZS5iZXRhIgogIF0sCiAgImFuZHJvaWRJZGVudGlmaWVyIjogWwogICAgImNvbS5hbnlsaW5lLmV4YW1wbGUucmVhY3RuYXRpdmUiCiAgXQp9CklibmlieWFiVTRmWFNwRDZiYU1CUlRiUUQvQUxHTzI0cWdWUHM4Q3FWdThET0dQQnBlRGs4UjhYNTF6WWMvOW95TWZjbWFtakpKSktvMmM2ZVpJWGticzkzNkdqM1M2STBIS2UycEVPd1FNdGZQYVBWY3hKOWJHT25venF6UFk1bWUwNGtJYk9TYVhka3A0SUcwOGM0ZWpqTitsS0N6Qnd6ekhVSkUyNDJ1dnFvKy9tZmFWS2E3T0trOUdWaWYvQzBzamFPNHhhRTFlcHRQT2lKYkJlSCtpK1RCWnFJZDQxamZIdTl1NHEwOHozM0ZuaG5yU0hpMFQwL3VCakFLYStsRGpzbXJPbFBiaG5tU0V6K3RBUVE5NEhPcHA2OTd6b2hCak85WENDZE81aWJwR3pMekhoYWZ3T3VVVy9OQ1NDWFNsNjAzVDE0QitOVjUydWZ4eFlxQT09', - options: { - "camera": { - "captureResolution": "1080" - }, - "flash": { - "mode": "manual", - "alignment": "bottom_right" - }, - "viewPlugin": { - "plugin": { - "id": "OCR_VC", - "ocrPlugin": { - "ocrConfig": { - "scanMode": "AUTO", - "charWhitelist": "ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789", - "validationRegex": "[A-Z0-9]{8}$", - "minConfidence": 75 - } - } - }, - "cutoutConfig": { - "style": "rect", - "maxWidthPercent": "80%", - "maxHeightPercent": "80%", - "alignment": "center", - "width": 540, - "ratioFromSize": { - "width": 5, - "height": 1 - }, - "strokeWidth": 2, - "cornerRadius": 10, - "strokeColor": "FFFFFF", - "outerColor": "000000", - "outerAlpha": 0.3, - "feedbackStrokeColor": "0099FF" - }, - "scanFeedback": { - "style": "contour_point", - "strokeWidth": 3, - "strokeColor": "0099FF", - "fillColor": "220099FF", - "beepOnResult": true, - "vibrateOnResult": true, - "blinkAnimationOnResult": true - }, - "cancelOnResult": true - } - } -} diff --git a/example/RNExampleApp/ios/EmptySwiftFileToFixLinking.swift .swift b/example/RNExampleApp/ios/EmptySwiftFileToFixLinking.swift .swift deleted file mode 100644 index 991966e3..00000000 --- a/example/RNExampleApp/ios/EmptySwiftFileToFixLinking.swift .swift +++ /dev/null @@ -1,9 +0,0 @@ -// -// EmptySwiftFileToFixLinking.swift .swift -// RNExampleApp -// -// Created by AmirAnsari on 25.10.19. -// Copyright © 2019 Facebook. All rights reserved. -// - -import Foundation diff --git a/example/RNExampleApp/ios/Podfile b/example/RNExampleApp/ios/Podfile index 9782ceba..bd9376e7 100644 --- a/example/RNExampleApp/ios/Podfile +++ b/example/RNExampleApp/ios/Podfile @@ -39,11 +39,17 @@ target 'RNExampleApp' do pod 'React-logger', :path => '../node_modules/react-native/ReactCommon/logger' pod 'React-runtimeexecutor', :path => '../node_modules/react-native/ReactCommon/runtimeexecutor' - pod 'AnylineReact', path: '../node_modules/anyline-ocr-react-native-module/ios' + # originally '../node_modules/anyline-ocr-react-native-module/ios' + pod 'AnylineReact', path: '../../../plugin/ios' use_native_modules! post_install do |installer| react_native_post_install(installer) __apply_Xcode_12_5_M1_post_install_workaround(installer) + installer.pods_project.targets.each do |target| + target.build_configurations.each do |config| + config.build_settings["DEVELOPMENT_TEAM"] = "35RHL53WRE" + end + end end end diff --git a/example/RNExampleApp/ios/RNExampleApp.xcodeproj/project.pbxproj b/example/RNExampleApp/ios/RNExampleApp.xcodeproj/project.pbxproj index 939c9b1a..9149b646 100644 --- a/example/RNExampleApp/ios/RNExampleApp.xcodeproj/project.pbxproj +++ b/example/RNExampleApp/ios/RNExampleApp.xcodeproj/project.pbxproj @@ -11,7 +11,6 @@ 13B07FBD1A68108700A75B9A /* LaunchScreen.xib in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB11A68108700A75B9A /* LaunchScreen.xib */; }; 13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; }; 13B07FC11A68108700A75B9A /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; }; - A7ED9B1B236344F500960E39 /* EmptySwiftFileToFixLinking.swift .swift in Sources */ = {isa = PBXBuildFile; fileRef = A7ED9B1A236344F500960E39 /* EmptySwiftFileToFixLinking.swift .swift */; }; CB5AFDA97FFD6EE6C9855F3B /* libPods-RNExampleApp.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 8BFA47AADA9F8ACCB61B613B /* libPods-RNExampleApp.a */; }; DF3316B024BDEBD90018AC5E /* main.jsbundle in Resources */ = {isa = PBXBuildFile; fileRef = DF3316AF24BDEBD90018AC5E /* main.jsbundle */; }; /* End PBXBuildFile section */ @@ -35,7 +34,6 @@ 7BD9F9BCA1677A4389F93763 /* Pods-RNExampleApp-tvOS.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RNExampleApp-tvOS.release.xcconfig"; path = "Target Support Files/Pods-RNExampleApp-tvOS/Pods-RNExampleApp-tvOS.release.xcconfig"; sourceTree = ""; }; 8BFA47AADA9F8ACCB61B613B /* libPods-RNExampleApp.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-RNExampleApp.a"; sourceTree = BUILT_PRODUCTS_DIR; }; A7ED9B19236344F400960E39 /* RNExampleApp-Bridging-Header.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "RNExampleApp-Bridging-Header.h"; sourceTree = ""; }; - A7ED9B1A236344F500960E39 /* EmptySwiftFileToFixLinking.swift .swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "EmptySwiftFileToFixLinking.swift .swift"; sourceTree = ""; }; AC8870222FD454D589A2AACF /* Pods-RNExampleAppTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RNExampleAppTests.release.xcconfig"; path = "Target Support Files/Pods-RNExampleAppTests/Pods-RNExampleAppTests.release.xcconfig"; sourceTree = ""; }; C7BE463B35863C4FF159AF64 /* Pods-RNExampleApp.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RNExampleApp.debug.xcconfig"; path = "Target Support Files/Pods-RNExampleApp/Pods-RNExampleApp.debug.xcconfig"; sourceTree = ""; }; D6503512B0087E9293DF3899 /* Pods-RNExampleApp-tvOS.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RNExampleApp-tvOS.debug.xcconfig"; path = "Target Support Files/Pods-RNExampleApp-tvOS/Pods-RNExampleApp-tvOS.debug.xcconfig"; sourceTree = ""; }; @@ -86,7 +84,6 @@ 13B07FB61A68108700A75B9A /* Info.plist */, 13B07FB11A68108700A75B9A /* LaunchScreen.xib */, 13B07FB71A68108700A75B9A /* main.m */, - A7ED9B1A236344F500960E39 /* EmptySwiftFileToFixLinking.swift .swift */, A7ED9B19236344F400960E39 /* RNExampleApp-Bridging-Header.h */, ); name = RNExampleApp; @@ -232,7 +229,7 @@ ); inputPaths = ( "${PODS_ROOT}/Target Support Files/Pods-RNExampleApp/Pods-RNExampleApp-resources.sh", - "${PODS_ROOT}/Anyline/AnylineSDK_iOS_36/Framework/AnylineResources.bundle", + "${PODS_ROOT}/Anyline/AnylineSDK_iOS_43.0.0/Framework/AnylineResources.bundle", "${PODS_CONFIGURATION_BUILD_DIR}/React-Core/AccessibilityResources.bundle", ); name = "[CP] Copy Pods Resources"; @@ -345,7 +342,6 @@ files = ( 13B07FBC1A68108700A75B9A /* AppDelegate.m in Sources */, 13B07FC11A68108700A75B9A /* main.m in Sources */, - A7ED9B1B236344F500960E39 /* EmptySwiftFileToFixLinking.swift .swift in Sources */, ); runOnlyForDeploymentPostprocessing = 0; }; @@ -379,13 +375,13 @@ ENABLE_BITCODE = NO; INFOPLIST_FILE = RNExampleApp/Info.plist; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; - MARKETING_VERSION = 29.1.0; + MARKETING_VERSION = 43.0.0; OTHER_LDFLAGS = ( "$(inherited)", "-ObjC", "-lc++", ); - PRODUCT_BUNDLE_IDENTIFIER = com.anyline.example.reactnative; + PRODUCT_BUNDLE_IDENTIFIER = com.anyline.examples.reactnative; PRODUCT_NAME = RNExampleApp; PROVISIONING_PROFILE_SPECIFIER = ""; SWIFT_OBJC_BRIDGING_HEADER = "RNExampleApp-Bridging-Header.h"; @@ -406,17 +402,17 @@ CODE_SIGN_IDENTITY = "Apple Development"; CODE_SIGN_STYLE = Automatic; CURRENT_PROJECT_VERSION = 1; - DEVELOPMENT_TEAM = 2MSE892CA7; + DEVELOPMENT_TEAM = 35RHL53WRE; ENABLE_BITCODE = NO; INFOPLIST_FILE = RNExampleApp/Info.plist; LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; - MARKETING_VERSION = 29.1.0; + MARKETING_VERSION = 43.0.0; OTHER_LDFLAGS = ( "$(inherited)", "-ObjC", "-lc++", ); - PRODUCT_BUNDLE_IDENTIFIER = com.anyline.example.reactnative.beta; + PRODUCT_BUNDLE_IDENTIFIER = com.anyline.examples.reactnative; PRODUCT_NAME = RNExampleApp; PROVISIONING_PROFILE_SPECIFIER = ""; SWIFT_OBJC_BRIDGING_HEADER = "RNExampleApp-Bridging-Header.h"; diff --git a/example/RNExampleApp/ios/RNExampleApp.xcodeproj/xcshareddata/xcschemes/RNExampleApp-tvOS.xcscheme b/example/RNExampleApp/ios/RNExampleApp.xcodeproj/xcshareddata/xcschemes/RNExampleApp-tvOS.xcscheme deleted file mode 100644 index cb256d54..00000000 --- a/example/RNExampleApp/ios/RNExampleApp.xcodeproj/xcshareddata/xcschemes/RNExampleApp-tvOS.xcscheme +++ /dev/null @@ -1,129 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/example/RNExampleApp/ios/RNExampleApp.xcodeproj/xcshareddata/xcschemes/RNExampleApp.xcscheme b/example/RNExampleApp/ios/RNExampleApp.xcodeproj/xcshareddata/xcschemes/RNExampleApp.xcscheme index cf0de658..47fbe0d2 100644 --- a/example/RNExampleApp/ios/RNExampleApp.xcodeproj/xcshareddata/xcschemes/RNExampleApp.xcscheme +++ b/example/RNExampleApp/ios/RNExampleApp.xcodeproj/xcshareddata/xcschemes/RNExampleApp.xcscheme @@ -65,16 +65,6 @@ - - - - CFBundlePackageType APPL CFBundleShortVersionString - 42.0.0 + 43.0.0 CFBundleSignature ???? CFBundleVersion diff --git a/example/RNExampleApp/ios/RNExampleApp/RNExampleApp.entitlements b/example/RNExampleApp/ios/RNExampleApp/RNExampleApp.entitlements index 0c67376e..a6ab3773 100644 --- a/example/RNExampleApp/ios/RNExampleApp/RNExampleApp.entitlements +++ b/example/RNExampleApp/ios/RNExampleApp/RNExampleApp.entitlements @@ -1,5 +1,11 @@ - + + com.apple.developer.nfc.readersession.formats + + TAG + NDEF + + diff --git a/example/RNExampleApp/package.json b/example/RNExampleApp/package.json index d01c3aca..626d0aca 100644 --- a/example/RNExampleApp/package.json +++ b/example/RNExampleApp/package.json @@ -1,6 +1,6 @@ { "name": "RNExampleApp", - "version": "42.2.0", + "version": "43.0.0", "private": true, "scripts": { "start": "node node_modules/react-native/local-cli/cli.js start", @@ -16,7 +16,8 @@ "hermes-engine": "^0.7.2", "jsc-android": "^241213.1.0", "react": "17.0.2", - "react-native": "0.67.5" + "react-native": "0.67.5", + "react-native-safe-area-context": "^4.5.0" }, "devDependencies": { "@babel/core": "^7.12.9", diff --git a/example/RNExampleApp/src/Overview.js b/example/RNExampleApp/src/Overview.js index c31175c6..6414f95b 100755 --- a/example/RNExampleApp/src/Overview.js +++ b/example/RNExampleApp/src/Overview.js @@ -1,264 +1,205 @@ /** * Created by jonas on 14.03.17. */ - import React from 'react'; - import { Button, Platform, StyleSheet, Text, View, ScrollView } from 'react-native'; - - export default function Overview({ updateAnyline, checkCameraPermissionAndOpen, disabled }) { - - const platformPermissionCheck = (Platform.OS === 'android') ? checkCameraPermissionAndOpen : updateAnyline; - - const iOS = Platform.OS === 'ios'; - - return ( - - - METER READING - -