scandoc-ai-components 0.0.50 → 0.0.51
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/dist/index.js +28 -25
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -11174,12 +11174,13 @@ class ExtractorVideo {
|
|
|
11174
11174
|
static VALIDATION_IMG_HEIGHT = 384;
|
|
11175
11175
|
static VIDEO_SETTINGS = Object.freeze({
|
|
11176
11176
|
width: {
|
|
11177
|
-
ideal:
|
|
11177
|
+
ideal: 1024
|
|
11178
11178
|
},
|
|
11179
11179
|
height: {
|
|
11180
|
-
ideal:
|
|
11180
|
+
ideal: 768
|
|
11181
11181
|
},
|
|
11182
|
-
|
|
11182
|
+
// 4:3
|
|
11183
|
+
facingMode: "user"
|
|
11183
11184
|
});
|
|
11184
11185
|
constructor(onExtractedResults) {
|
|
11185
11186
|
this.candidateImages = [];
|
|
@@ -11400,11 +11401,9 @@ class ExtractorVideo {
|
|
|
11400
11401
|
<div class="desktopFeedback" id="ScanDocAIMessage"></div>
|
|
11401
11402
|
<div class="desktopVideoArea">
|
|
11402
11403
|
<div class="desktopVideoHolder">
|
|
11403
|
-
<
|
|
11404
|
-
|
|
11405
|
-
|
|
11406
|
-
<div class="desktopRectangle dashedRectangle"></div>
|
|
11407
|
-
</div>
|
|
11404
|
+
<video id="ScanDocAIVideoElement" class="desktopVideo" autoPlay muted playsInline></video>
|
|
11405
|
+
<div class="backgroundOverlay"></div>
|
|
11406
|
+
<div class="desktopRectangle dashedRectangle"></div>
|
|
11408
11407
|
</div>
|
|
11409
11408
|
</div>
|
|
11410
11409
|
|
|
@@ -11427,30 +11426,25 @@ class ExtractorVideo {
|
|
|
11427
11426
|
overflow: hidden;
|
|
11428
11427
|
}
|
|
11429
11428
|
|
|
11430
|
-
.videoWrapper {
|
|
11431
|
-
position: relative;
|
|
11432
|
-
width: 100%;
|
|
11433
|
-
aspect-ratio: 16 / 9;
|
|
11434
|
-
}
|
|
11435
|
-
|
|
11436
11429
|
.desktopVideo {
|
|
11437
11430
|
width: 100%;
|
|
11438
|
-
height:
|
|
11439
|
-
|
|
11440
|
-
|
|
11431
|
+
height: auto;
|
|
11432
|
+
margin-left: auto;
|
|
11433
|
+
margin-right: auto;
|
|
11434
|
+
max-width: 100vw;
|
|
11435
|
+
max-height: 100vh;
|
|
11441
11436
|
}
|
|
11442
|
-
|
|
11437
|
+
|
|
11443
11438
|
.desktopRectangle {
|
|
11444
11439
|
position: absolute;
|
|
11445
|
-
top:
|
|
11446
|
-
|
|
11447
|
-
|
|
11448
|
-
|
|
11440
|
+
top: 32px;
|
|
11441
|
+
right: 32px;
|
|
11442
|
+
bottom: 32px;
|
|
11443
|
+
left: 28px;
|
|
11449
11444
|
border-radius: 30px;
|
|
11450
11445
|
display: flex;
|
|
11451
11446
|
justify-content: center;
|
|
11452
11447
|
align-items: center;
|
|
11453
|
-
z-index: 3;
|
|
11454
11448
|
}
|
|
11455
11449
|
|
|
11456
11450
|
.dashedRectangle {
|
|
@@ -11620,13 +11614,22 @@ let internalConfig = {
|
|
|
11620
11614
|
FACE_IMAGE_RESIZE: null,
|
|
11621
11615
|
// timeout settings:
|
|
11622
11616
|
MAX_SCAN_DURATION_MS: 10000,
|
|
11623
|
-
MAX_UNSUPPORTED_ATTEMPTS: 5
|
|
11617
|
+
MAX_UNSUPPORTED_ATTEMPTS: 5,
|
|
11618
|
+
// design settings
|
|
11619
|
+
VIDEO_COLORS: {
|
|
11620
|
+
borderColor: "#5078bb",
|
|
11621
|
+
messageColor: "#5078bb"
|
|
11622
|
+
}
|
|
11624
11623
|
};
|
|
11625
11624
|
//
|
|
11626
11625
|
function setScanDocAIConfig(newConfig = {}) {
|
|
11627
11626
|
internalConfig = {
|
|
11628
11627
|
...internalConfig,
|
|
11629
|
-
...newConfig
|
|
11628
|
+
...newConfig,
|
|
11629
|
+
COLORS: {
|
|
11630
|
+
...internalConfig.COLORS,
|
|
11631
|
+
...newConfig.COLORS
|
|
11632
|
+
}
|
|
11630
11633
|
};
|
|
11631
11634
|
}
|
|
11632
11635
|
function getScanDocAIConfigValues() {
|