@regulaforensics/vp-frontend-document-components 7.2.1592-nightly → 7.2.1595-nightly
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 +34 -2
- package/dist/main.js +1 -1
- package/esm/main.js +1 -1
- package/lib/index.d.ts +6 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -259,7 +259,7 @@ After adding `DocumentReaderService` to the global variable, you can change the
|
|
|
259
259
|
| **respectImageQuality** | When enabled, image quality checks status affects document optical and overall status. | boolean | `false` | `true`, `false` |
|
|
260
260
|
| **forceDocFormat** | Force use of specified document format when locating and recognizing document to reduce the number of candidates. | number | | `0` - ID1 document format, `1` - ID2 document format, `2` - ID3 document format, `3` - Undefined document format, `4` - A4 document format, `5` - ID3 double document format, `10` - ID1 format document rotated 90°, `11` - ID1 format document rotated 180°, `12` - ID1 format document rotated 270°, `13` - ID2 format document rotated 90°, `14` - ID3 format document rotated 180°, `1000` - Arbitrary format, `1002` - Flexible format. Standard formats can be resized during cropping, depending on various factors: light, background... |
|
|
261
261
|
| **noGraphics** | When enabled, no graphic fields will be cropped from document image. | boolean | `false` | `true`, `false` |
|
|
262
|
-
| **documentAreaMin** | Specifies minimal area of the image that document should cover to be treated as candidate when locating. Value should be in range from 0 to
|
|
262
|
+
| **documentAreaMin** | Specifies minimal area of the image that document should cover to be treated as candidate when locating. Value should be in range from 0 to 100, where 100 is when document should fully cover the image. | number | 0 | 0 - 100 |
|
|
263
263
|
| **depersonalizeLog** | When enabled, all personal data will be forcibly removed from the logs. | boolean | `false` | `true`, `false` |
|
|
264
264
|
| **multiDocOnImage** | This option allows locating and cropping multiple documents from one image if enabled. | boolean | `false` | `true`, `false` |
|
|
265
265
|
| **shiftExpiryDate** | This option allows shifting the date of expiry into the future or past for number of months specified. This is useful, for example, in some cases when document might be still valid for some period after original expiration date to prevent negative validity status for such documents. Or by shifting the date to the past will set negative validity for the documents that is about to expire in a specified number of months. | number | 0 | numbers > 0 |
|
|
@@ -1405,6 +1405,10 @@ The Document Reader web components are also available on <a href="https://storyb
|
|
|
1405
1405
|
Logging can be helpful when you run into any issues.
|
|
1406
1406
|
Logs contain information about how you use our products. That data helps Regula stuff to analyze and troubleshoot the cases you may experience.
|
|
1407
1407
|
|
|
1408
|
+
There are two ways to output logs: console or function callback.
|
|
1409
|
+
|
|
1410
|
+
#### Console
|
|
1411
|
+
|
|
1408
1412
|
To initiate the process of logs collecting:
|
|
1409
1413
|
|
|
1410
1414
|
**1.** Open the Developer menu in your browser.
|
|
@@ -1419,7 +1423,7 @@ localStorage.logger = 'main,wasm>console'
|
|
|
1419
1423
|
|
|
1420
1424
|
**4.** Reload the page.
|
|
1421
1425
|
|
|
1422
|
-
**5.** Add the `log` setting to the `processParam
|
|
1426
|
+
**5.** Add the `log` setting to the `processParam` if you want to see logs from WASM:
|
|
1423
1427
|
|
|
1424
1428
|
```json
|
|
1425
1429
|
{
|
|
@@ -1430,3 +1434,31 @@ localStorage.logger = 'main,wasm>console'
|
|
|
1430
1434
|
```
|
|
1431
1435
|
|
|
1432
1436
|
**6.** Start image processing. Logs will be displayed in Console.
|
|
1437
|
+
|
|
1438
|
+
#### Function callback
|
|
1439
|
+
|
|
1440
|
+
**1.** Import logging service from library.
|
|
1441
|
+
|
|
1442
|
+
```javascript
|
|
1443
|
+
import { Logger } from '@regulaforensics/vp-frontend-document-components';
|
|
1444
|
+
```
|
|
1445
|
+
|
|
1446
|
+
**2.** Set the callback function.
|
|
1447
|
+
|
|
1448
|
+
```javascript
|
|
1449
|
+
Logger.logListener = (log) => {
|
|
1450
|
+
// ...
|
|
1451
|
+
// do something with log
|
|
1452
|
+
// ...
|
|
1453
|
+
};
|
|
1454
|
+
```
|
|
1455
|
+
|
|
1456
|
+
**3.** Add the `log` setting to the `processParam` if you want to see logs from WASM:
|
|
1457
|
+
|
|
1458
|
+
```json
|
|
1459
|
+
{
|
|
1460
|
+
"processParam": {
|
|
1461
|
+
"log": true
|
|
1462
|
+
}
|
|
1463
|
+
}
|
|
1464
|
+
```
|