@regulaforensics/vp-frontend-document-components 7.5.1931-nightly → 7.5.1932-rc

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -268,7 +268,6 @@ After adding `DocumentReaderService` to the global variable, you can change the
268
268
  | **scenario** | Recognition scenario. | string | 'MrzAndLocate' | 'MrzAndLocate', 'MrzOrLocate', 'Mrz', 'Locate' |
269
269
  | **multipageProcessing** | Whether to enable multi-page document processing mode. | boolean | `true` | `true`, `false` |
270
270
  | **timeout** | Recognition timeout in milliseconds. After this time process will be finished. | number | 2000 | numbers > 0 |
271
- | **timeoutFromFirstDetect** | Start the countdown from the moment the document is detected. | number | 5000 | numbers > 0 |
272
271
  | **resultTypeOutput** | Types of results to return in response. [] - all available types. | number[] | [] | `1` - DocumentImageResult, `3` - TextDataResult, `5` - DocBarCodeInfo, `6` - GraphicsResult, `8` - DocumentTypesCandidatesResult, `9` - ChosenDocumentTypeResult, `20` - AuthenticityResult, `15` - LexicalAnalysisResult, `17` - TextDataResult, `18` - TextDataResult, `19` - GraphicsResult, `30` - ImageQualityResult, `33` - StatusResult, `36` - TextResult, `37` - ImagesResult, `85` - DocumentPositionResult, `102` - TextDataResult, `103` - GraphicsResult, `50` - LicenseResult, `49` - EncryptedRCLResult |
273
272
  | **returnPackageForReprocess** | When enabled, returns the package for reprocessing on the backend. | boolean | `false` | `true`, `false` |
274
273
  | **imageQa** | When enabled, image quality checks status affects document optical and overall status. | | | |
@@ -426,7 +425,6 @@ Available fields of `event.detail.data` object:
426
425
  | `NO_CAMERA` | There is no camera available |
427
426
  | `INCORRECT_CAMERA_ID` | Camera with this ID was not found |
428
427
  | `CONNECTION_ERROR` | Connection errors |
429
- | `BAD_CONFIGURATION` | Incompatible component settings are installed |
430
428
 
431
429
  #### Remote action data
432
430
 
@@ -1063,7 +1061,6 @@ You can send the results to the backend for further processing:
1063
1061
  ```javascript
1064
1062
  window.RegulaDocumentSDK.recognizerProcessParam = {
1065
1063
  processParam: {
1066
- scenario: InternalScenarios.MrzAndLocate,
1067
1064
  backendProcessing: {
1068
1065
  serviceURL: 'YOUR_SERVICE_URL',
1069
1066
  httpHeaders: { // you can set http headers if necessary
@@ -1093,19 +1090,11 @@ For cases when user's main device lacks camera or does not succeed to scan with
1093
1090
  you have an option to delegate scanning to another available device (i.e. phone).
1094
1091
 
1095
1092
  #### 1. "From other phone" action may be configured on the start screen:
1096
- - add 'delegateProcessing' and 'tag':
1093
+ - configure [backend reprocessing](#backend-reprocessing)
1094
+ - add 'delegateURL' and 'tag':
1097
1095
  ```javascript
1098
1096
  processor.recognizerProcessParam = {
1099
- processParam: {
1100
- scenario: InternalScenarios.MrzAndLocate,
1101
- },
1102
- delegateProcessing: {
1103
- delegateURL: 'https://your-page.com?tag={tag}', // the page which will be used by other device
1104
- serviceURL: 'https://my-service.com', // your backend service
1105
- httpHeaders: { // http headers if needed
1106
- header: 'value'
1107
- }
1108
- },
1097
+ delegateURL: 'https://your-page.com?tag={tag}', // the page which will be used by other device
1109
1098
  tag: 123 // your session id, will be added to delegateURL in place of {tag} substring
1110
1099
  }
1111
1100
  ```
@@ -1118,22 +1107,19 @@ you have an option to delegate scanning to another available device (i.e. phone)
1118
1107
 
1119
1108
  #### 2. Configure Delegate page component on delegateURL:
1120
1109
  - configure [backend reprocessing](#backend-reprocessing)
1121
- - backendProcessing setting for the device and delegateProcessing setting for the main page must match
1122
- - set transaction tag
1123
- ```javascript
1124
- processor.recognizerProcessParam = {
1125
- tag: new URL(window.location.href).searchParams.get('tag') // assume session Id tag was added to URL params
1126
- }
1127
- ```
1128
1110
  - use the same tag as on the main page
1129
1111
  ```javascript
1130
- element.settings = {
1131
- startScreen: false, // From camera recognition is expected
1132
- mobileDelegate: true
1133
- }
1112
+ window.RegulaDocumentSDK.recognizerProcessParam = {
1113
+ tag: 123 // your session id, i.e. it can be extracted from your delegate page URL
1114
+ };
1115
+
1116
+ element.settings = {
1117
+ startScreen: false, // From camera recognition is expected
1118
+ }
1134
1119
  ```
1135
1120
  - use finalizePackage() to send the data for further reprocessing
1136
1121
 
1122
+
1137
1123
  ### Appearance Customization
1138
1124
 
1139
1125
  #### Font and Colors
@@ -1247,8 +1233,6 @@ See the following table with localized labels, used in the components.
1247
1233
  | **fromFilesDesktop** | Pick a document from the files and upload it | `document-reader` |
1248
1234
  | **fromMobileDesktop** | Use your mobile camera to capture a document | `document-reader` |
1249
1235
  | **fromGalleryMobile** | Pick a document from the gallery and upload it | `document-reader` |
1250
- | **returnToComputer** | Return to the computer | `document-reader` |
1251
- | **documentCaptured** | Your document has been captured | `document-reader` |
1252
1236
 
1253
1237
  ## Document Reader Processor
1254
1238
 
package/dist/index.d.ts CHANGED
@@ -231,7 +231,6 @@ export declare class DocumentReaderService {
231
231
  private _initializeListener;
232
232
  private _processingListener;
233
233
  private _queueService;
234
- onFinalize: TOnFinalize | null;
235
234
  isAutoPrepare: boolean;
236
235
  isPrepared: boolean;
237
236
  isInitialized: boolean;
@@ -384,8 +383,7 @@ export declare enum ErrorTypes {
384
383
  INCORRECT_CAMERA_ID = "INCORRECT_CAMERA_ID",
385
384
  CONNECTION_ERROR = "CONNECTION_ERROR",
386
385
  HTTP_NOT_SUPPORTED = "HTTP_NOT_SUPPORTED",
387
- INSECURE_PAGE_CONTEXT = "INSECURE_PAGE_CONTEXT",
388
- BAD_CONFIGURATION = "BAD_CONFIGURATION"
386
+ INSECURE_PAGE_CONTEXT = "INSECURE_PAGE_CONTEXT"
389
387
  }
390
388
 
391
389
  export declare enum EventActions {
@@ -522,11 +520,7 @@ export declare interface PackageParams {
522
520
 
523
521
  export declare interface ProcessingRequest extends BaseRequest {
524
522
  metadata?: Record<string, any>;
525
- delegateProcessing?: {
526
- serviceURL: string;
527
- delegateURL: string;
528
- httpHeaders?: Record<string, string>;
529
- };
523
+ delegateURL?: string;
530
524
  processParam: DocumentReaderProcessParam;
531
525
  imagesList?: Array<DocumentReaderImage>;
532
526
  imageInputParam?: ImageInputParamType;
@@ -555,8 +549,6 @@ declare type TInitializeListener = ({ isInitialized }: {
555
549
  isInitialized: boolean;
556
550
  }) => void;
557
551
 
558
- declare type TOnFinalize = (transaction: TransactionInfo) => void;
559
-
560
552
  declare type TPrepareListener = ({ isPrepared }: {
561
553
  isPrepared: boolean;
562
554
  }) => void;