Skip to content

Commit

Permalink
Merge pull request #6 from blinkcard/release/v2.6.0
Browse files Browse the repository at this point in the history
Release/v2.6.0
  • Loading branch information
krizaa authored Jul 13, 2022
2 parents 845b1f1 + 1243281 commit 59a7e15
Show file tree
Hide file tree
Showing 33 changed files with 179 additions and 257 deletions.
4 changes: 2 additions & 2 deletions BlinkCard/blinkcard-react-native.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ Pod::Spec.new do |s|
s.authors = package['author']
s.homepage = package['homepage']
s.license = package['license']
s.platform = :ios, "9.0"
s.platform = :ios, "12.0"
s.source = { :git => "https://github.com/BlinkCard/blinkcard-react-native.git", :tag => "v#{s.version}" }
s.source_files = "src/ios", "src/ios/**/*.{h,m}"
s.dependency 'React'
s.dependency 'MBBlinkCard', '~> 2.4.0'
s.dependency 'MBBlinkCard', '~> 2.6.0'
s.frameworks = 'UIKit'
end
2 changes: 1 addition & 1 deletion BlinkCard/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@microblink/blinkcard-react-native",
"version": "2.4.1",
"version": "2.6.0",
"description": "AI-driven credit card scanning for cross-platform apps built with ReactNative.",
"main": "index.js",
"repository": {
Expand Down
17 changes: 0 additions & 17 deletions BlinkCard/recognizers/blinkCardRecognizer.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,16 +42,6 @@ export class BlinkCardRecognizerResult extends RecognizerResult {
*/
this.cvv = nativeResult.cvv;

/**
* Digital signature of the recognition result. Available only if enabled with signResult property.
*/
this.digitalSignature = nativeResult.digitalSignature;

/**
* Version of the digital signature. Available only if enabled with signResult property.
*/
this.digitalSignatureVersion = nativeResult.digitalSignatureVersion;

/**
* The payment card's expiry date.
*/
Expand Down Expand Up @@ -187,13 +177,6 @@ export class BlinkCardRecognizer extends Recognizer {
*/
this.returnFullDocumentImage = false;

/**
* Whether or not recognition result should be signed.
*
*
*/
this.signResult = false;

this.createResultFromNative = function (nativeResult) { return new BlinkCardRecognizerResult(nativeResult); }
}
}
17 changes: 0 additions & 17 deletions BlinkCard/recognizers/legacyBlinkCardEliteRecognizer.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,16 +32,6 @@ export class LegacyBlinkCardEliteRecognizerResult extends RecognizerResult {
*/
this.cvv = nativeResult.cvv;

/**
* Digital signature of the recognition result. Available only if enabled with signResult property.
*/
this.digitalSignature = nativeResult.digitalSignature;

/**
* Version of the digital signature. Available only if enabled with signResult property.
*/
this.digitalSignatureVersion = nativeResult.digitalSignatureVersion;

/**
* Returns CDataMatchResultSuccess if data from scanned parts/sides of the document match,
* CDataMatchResultFailed otherwise. For example if date of expiry is scanned from the front and back side
Expand Down Expand Up @@ -163,13 +153,6 @@ export class LegacyBlinkCardEliteRecognizer extends Recognizer {
*/
this.returnFullDocumentImage = false;

/**
* Whether or not recognition result should be signed.
*
*
*/
this.signResult = false;

this.createResultFromNative = function (nativeResult) { return new LegacyBlinkCardEliteRecognizerResult(nativeResult); }
}
}
17 changes: 0 additions & 17 deletions BlinkCard/recognizers/legacyBlinkCardRecognizer.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,16 +32,6 @@ export class LegacyBlinkCardRecognizerResult extends RecognizerResult {
*/
this.cvv = nativeResult.cvv;

/**
* Digital signature of the recognition result. Available only if enabled with signResult property.
*/
this.digitalSignature = nativeResult.digitalSignature;

/**
* Version of the digital signature. Available only if enabled with signResult property.
*/
this.digitalSignatureVersion = nativeResult.digitalSignatureVersion;

/**
* Returns CDataMatchResultSuccess if data from scanned parts/sides of the document match,
* CDataMatchResultFailed otherwise. For example if date of expiry is scanned from the front and back side
Expand Down Expand Up @@ -194,13 +184,6 @@ export class LegacyBlinkCardRecognizer extends Recognizer {
*/
this.returnFullDocumentImage = false;

/**
* Whether or not recognition result should be signed.
*
*
*/
this.signResult = false;

this.createResultFromNative = function (nativeResult) { return new LegacyBlinkCardRecognizerResult(nativeResult); }
}
}
2 changes: 1 addition & 1 deletion BlinkCard/src/android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ android {

dependencies {
implementation 'com.facebook.react:react-native:+'
implementation('com.microblink:blinkcard:2.4.0@aar') {
implementation('com.microblink:blinkcard:2.6.0@aar') {
transitive = true
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,6 @@ public Recognizer<?> createRecognizer(ReadableMap jsonMap) {
if (jsonMap.hasKey("returnFullDocumentImage")) {
recognizer.setReturnFullDocumentImage(jsonMap.getBoolean("returnFullDocumentImage"));
}
if (jsonMap.hasKey("signResult")) {
recognizer.setSignResult(jsonMap.getBoolean("signResult"));
}
return recognizer;
}

Expand All @@ -56,8 +53,6 @@ public WritableMap serializeResult(Recognizer<?> recognizer) {
jsonResult.putString("cardNumberPrefix", result.getCardNumberPrefix());
jsonResult.putBoolean("cardNumberValid", result.isCardNumberValid());
jsonResult.putString("cvv", result.getCvv());
jsonResult.putString("digitalSignature", SerializationUtils.encodeByteArrayToBase64(result.getDigitalSignature()));
jsonResult.putInt("digitalSignatureVersion", (int)result.getDigitalSignatureVersion());
jsonResult.putMap("expiryDate", SerializationUtils.serializeDate(result.getExpiryDate()));
jsonResult.putBoolean("firstSideBlurred", result.isFirstSideBlurred());
jsonResult.putString("firstSideFullDocumentImage", SerializationUtils.encodeImageBase64(result.getFirstSideFullDocumentImage()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,6 @@ public Recognizer<?> createRecognizer(ReadableMap jsonMap) {
if (jsonMap.hasKey("returnFullDocumentImage")) {
recognizer.setReturnFullDocumentImage(jsonMap.getBoolean("returnFullDocumentImage"));
}
if (jsonMap.hasKey("signResult")) {
recognizer.setSignResult(jsonMap.getBoolean("signResult"));
}
return recognizer;
}

Expand All @@ -54,8 +51,6 @@ public WritableMap serializeResult(Recognizer<?> recognizer) {
SerializationUtils.addCommonRecognizerResultData(jsonResult, result);
jsonResult.putString("cardNumber", result.getCardNumber());
jsonResult.putString("cvv", result.getCvv());
jsonResult.putString("digitalSignature", SerializationUtils.encodeByteArrayToBase64(result.getDigitalSignature()));
jsonResult.putInt("digitalSignatureVersion", (int)result.getDigitalSignatureVersion());
jsonResult.putInt("documentDataMatch", SerializationUtils.serializeEnum(result.getDocumentDataMatch()));
jsonResult.putString("fullDocumentBackImage", SerializationUtils.encodeImageBase64(result.getFullDocumentBackImage()));
jsonResult.putString("fullDocumentFrontImage", SerializationUtils.encodeImageBase64(result.getFullDocumentFrontImage()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,6 @@ public Recognizer<?> createRecognizer(ReadableMap jsonMap) {
if (jsonMap.hasKey("returnFullDocumentImage")) {
recognizer.setReturnFullDocumentImage(jsonMap.getBoolean("returnFullDocumentImage"));
}
if (jsonMap.hasKey("signResult")) {
recognizer.setSignResult(jsonMap.getBoolean("signResult"));
}
return recognizer;
}

Expand All @@ -63,8 +60,6 @@ public WritableMap serializeResult(Recognizer<?> recognizer) {
SerializationUtils.addCommonRecognizerResultData(jsonResult, result);
jsonResult.putString("cardNumber", result.getCardNumber());
jsonResult.putString("cvv", result.getCvv());
jsonResult.putString("digitalSignature", SerializationUtils.encodeByteArrayToBase64(result.getDigitalSignature()));
jsonResult.putInt("digitalSignatureVersion", (int)result.getDigitalSignatureVersion());
jsonResult.putInt("documentDataMatch", SerializationUtils.serializeEnum(result.getDocumentDataMatch()));
jsonResult.putString("fullDocumentBackImage", SerializationUtils.encodeImageBase64(result.getFullDocumentBackImage()));
jsonResult.putString("fullDocumentFrontImage", SerializationUtils.encodeImageBase64(result.getFullDocumentFrontImage()));
Expand Down
Loading

0 comments on commit 59a7e15

Please sign in to comment.