Migration Guide: From 7.7 to 8.1
Web Service
Logging Configuration
Changed the configuration logic for processing results logs. Previously, the logs have been collected if the processing section existed in the config.yaml with any number of subsidiary fields. Now, to log the Web Service processing results, you need to explicitly set the enabled = true field. See the example.
| config.yaml | |
|---|---|
1 2 3 4 5 6 7 8 9 10 11 | |
| config.yaml | |
|---|---|
1 2 3 4 5 6 7 8 9 10 | |
For more details, see the Web Service Logging Configuration page.
Database Configuration
Changed the Oracle Database driver used for the setup of the Complete Server-Side Verification from cx_Oracle to oracledb. See the example connection string:
service:
database:
connectionString: "oracle+oracledb://system:admin@(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=127.0.0.1)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=FREE)))
service:
database:
connectionString: "oracle+cx_oracle://system:admin@(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=127.0.0.1)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=FREE)))
For more details, see the Connect Database instructions.
Mobile
General Changes
RFID Processing
The RFIDScenario.readingBuffer property has taken an integer value, that defined the buffer size (see the details in the Document Reader SDK Programmers Guide). Now, it takes one of the values of the RFIDReadingBufferSize enumeration. See the examples on the RFID Configuration page.
If you use only the RFID chip reading (without optical processing beforehand), now you need to set the new dedicated scenario—RFID. See the example.
DocReader.shared.processParams.scenario = RGL_SCENARIO_RFID;
RGLDocReader.shared.processParams.scenario = RGL_SCENARIO_RFID;
DocumentReader.Instance().processParams().scenario = Scenario.SCENARIO_RFID
DocumentReader.Instance().processParams().scenario = Scenario.SCENARIO_RFID;
DocumentReader.instance.processParams.scenario = Scenario.RFID;
DocumentReader.setProcessParams({
scenario: ScenarioIdentifier.SCENARIO_RFID
}, (str) => { console.log(str) }, (error) => { console.log(error) });
DocumentReader.setProcessParams({
scenario: ScenarioIdentifier.SCENARIO_RFID
});
DocumentReader.setProcessParams({
scenario: ScenarioIdentifier.SCENARIO_RFID
}, function (m) { }, function (e) { console.log(e); });
// Android
DocumentReader.Instance().ProcessParams().Scenario = Scenario.ScenarioRFID;
// iOS
RGLDocReader.Shared.ProcessParams.Scenario = Constants.RGL_SCENARIO_RFID;
Also, you need to manually set the access key.
Info
If the RFID chip processing follows the optical processing, there is no need to set the scenario before starting the RFID chip processing.
New UI
Mobile SDK introduces the new UI for the document scanning process. For now, you will be able to select either the old UI or the new one, and it's recommended to migrate to the new UI. To compare the appearance, explore the Customize User Interface pages.
To switch between the UIs, when launching the document scanning, run the Document Reader methods starting from showScanner (for the old UI) or from startScanner (for the new UI).
For more details, see the Document Processing instructions and explore the sections below.
iOS
- Deprecated method
showScannerFromPresenter()inRGLDocReader. You can still use it to launch the document scanning process in the old UI. UsestartScannerFromPresenter()instead to run document scanning in new UI. - Deprecated method
prepareCameraViewController()inRGLDocReader. You can still use it to get the view controller with old UI. UseprepareCameraViewControllerForStart()instead to get the view controller with new UI. - Deprecated the following old UI properties in
RGLCustomization:resultStatusresultStatusPositionMultiplierresultStatusTextColorresultStatusTextFontresultStatusBackgroundColor
- Deprecated the property
showChangeFrameButtoninRGLFunctionality. - Changed the default value for the
backgroundMaskAlphainRGLCustomizationto1.0. - Changed the type of the
cameraViewControllerproperty inRGLFunctionalityfromRGLDocumentReaderCameraViewControllertoRGLDocumentReaderBaseCameraViewController. - Changed the type of the
readingBufferproperty inRFIDScenariofrom integer toRGLRFIDReadingBufferSizeenumeration.
For the information about the most current functionality, see iOS API Reference Documentation.
Android
- Deprecated method
showScanner()inDocumentReader. You can still use it to launch the document scanning process in the old UI. UsestartScanner()instead to run document scanning in new UI. - Deprecated the method
setShowChangeFrameButton()inFunctionality. - Deprecated the following old UI methods in
ParamsCustomization:setResultStatusPositionMultiplier(Float resultStatusPositionMultiplier)setResultStatusBackgroundColor(String resultStatusBackgroundColor)setResultStatusTextColor(String resultStatusTextColor)setResultStatusTextSize(Integer resultStatusTextSize)setResultStatusTextFont(Typeface resultStatusTextFont)setShowResultStatusMessages(boolean showResultStatusMessages)setResultStatus(String status)setChangeFrameCollapseButtonImage(Drawable changeFrameButtonCollapseImage)setChangeFrameExpandButtonImage(Drawable changeFrameButtonExpandImage)
- Changed the type of the
readingBufferproperty inRFIDScenariofrom integer toRFIDReadingBufferSizeenumeration.
For the information about the most current functionality, see Android API Reference Documentation.
Web Component
Warning
All items that were marked as deprecated by the time of release 8.1 are now removed. This applies to CSS variables, components' settings, parameters, attributes, methods, etc. If you're still using any of them, consider the current alternatives. See details below.
Obsolete Settings and Methods
The following parameters and methods are now obsolete, they are deleted from source code and should not be used anymore:
- Deleted
--font-familyand--font-sizeCSS variables. Use the properties of the corresponding part CSS elements instead. - Deleted
flipFrontIconandflipBackIconsettings. Use the part CSS elements with the prefixeshint-next-page-front-andhint-next-page-back-instead. - Deleted the
prepare()method andprepareListenerfield fromDocumentReaderService. - Deleted the
licenseattribute and thedevLicensesetting. Use theRegulaDocumentSDK.initialize()method instead. - Deleted the
regulaLogosetting. Use thecopyrightsetting instead. - Deleted the
respectImageQualityparameter. UsestrictImageQualityinstead. - Deleted settings:
statusBackgroundColor,statusTextColor,backgroundMaskAlpha. Use the properties of the corresponding part CSS elements instead.
For the information about the most current functionality, see Web Component documentation.
UI and UX Changes
In the release 8.1 the component's UI has changed.
Starting from release 8.1, the ::part() elements' icons are now set with the ::before pseudo-element.
The list of part CSS pseudo-elements has been updated to support the effective icons' customization.
Deleted part elements:
hint-next-page-front-imghint-next-page-back-img
Added part elements:
hint-status-processing-error-iconhint-status-search-iconhint-status-square-iconhint-holo-id-front-iconhint-holo-passport-single-iconhint-holo-passport-both-pages-iconhint-holo-id-front-iconhint-holo-id-mrz-front-iconhint-holo-id-back-iconhint-holo-id-mrz-back-iconhint-holo-id-barcode-back-iconhint-holo-id-mrz-barcode-back-iconhint-holo-bank-card-front-iconhint-holo-bank-card-back-iconhint-holo-document-front-iconhint-holo-document-back-iconhint-next-page-front-id-front-iconhint-next-page-front-passport-single-iconhint-next-page-front-passport-both-pages-iconhint-next-page-front-id-front-iconhint-next-page-front-id-mrz-front-iconhint-next-page-front-id-back-iconhint-next-page-front-id-mrz-back-iconhint-next-page-front-id-barcode-back-iconhint-next-page-front-id-mrz-barcode-back-iconhint-next-page-front-bank-card-front-iconhint-next-page-front-bank-card-back-iconhint-next-page-front-document-front-iconhint-next-page-front-document-back-iconhint-next-page-back-id-front-iconhint-next-page-back-passport-single-iconhint-next-page-back-passport-both-pages-iconhint-next-page-back-id-front-iconhint-next-page-back-id-mrz-front-iconhint-next-page-back-id-back-iconhint-next-page-back-id-mrz-back-iconhint-next-page-back-id-barcode-back-iconhint-next-page-back-id-mrz-barcode-back-iconhint-next-page-back-bank-card-front-iconhint-next-page-back-bank-card-back-iconhint-next-page-back-document-front-iconhint-next-page-back-document-back-icon
To change the default element's icon, use the named part attribute with the before pseudo-element and change the background-image property appropriately. See CSS examples further.
Icon replacement
Using image in Base64 format:
document-reader::part(hint-next-page-back-passport-single-icon)::before {
background-image: url("data:image/svg+xml;base64,<BASE64_IMAGE_STRING>");
}
Define the absolute or relative path to image:
document-reader::part(hint-next-page-back-passport-single-icon)::before {
background-image: url("https://pictures.com/some_image.png");
}
Icon resizing
document-reader::part(hint-status-search-icon)::before {
width: 30px;
height: 30px;
}
For more details, see the Customize Icons instructions.