gbc-kyc-kit 2.3.2 → 2.3.4
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/gbc-kyc-kit.es.js +14 -7
- package/dist/gbc-kyc-kit.umd.js +1034 -1034
- package/package.json +1 -1
package/dist/gbc-kyc-kit.es.js
CHANGED
|
@@ -102028,10 +102028,10 @@ const DocumentReaderController = (dataDocument, clientId, authorize, eventId, so
|
|
|
102028
102028
|
const isPortrait = usePortrait();
|
|
102029
102029
|
const videoConstraints = useMemo(() => ({
|
|
102030
102030
|
width: {
|
|
102031
|
-
ideal: isPortrait ?
|
|
102031
|
+
ideal: isPortrait ? 400 : 640
|
|
102032
102032
|
},
|
|
102033
102033
|
height: {
|
|
102034
|
-
ideal: isPortrait ?
|
|
102034
|
+
ideal: isPortrait ? 640 : 400
|
|
102035
102035
|
},
|
|
102036
102036
|
aspectRatio: {
|
|
102037
102037
|
ideal: isPortrait ? 16 / 9 : 9 / 16
|
|
@@ -102040,7 +102040,7 @@ const DocumentReaderController = (dataDocument, clientId, authorize, eventId, so
|
|
|
102040
102040
|
ideal: 30
|
|
102041
102041
|
},
|
|
102042
102042
|
advanced: [{
|
|
102043
|
-
focusMode: "
|
|
102043
|
+
focusMode: "continuous"
|
|
102044
102044
|
}],
|
|
102045
102045
|
facingMode: "environment"
|
|
102046
102046
|
}), [isPortrait]);
|
|
@@ -102273,6 +102273,13 @@ function fileToBase64(file) {
|
|
|
102273
102273
|
reader.onerror = (error) => rej(error);
|
|
102274
102274
|
});
|
|
102275
102275
|
}
|
|
102276
|
+
const isLowEndDevice = () => {
|
|
102277
|
+
const cores = navigator.hardwareConcurrency || 2;
|
|
102278
|
+
const memory2 = navigator.deviceMemory || 2;
|
|
102279
|
+
const isHardwareLow = cores <= 4 || memory2 <= 3;
|
|
102280
|
+
console.log(cores, memory2);
|
|
102281
|
+
return isHardwareLow;
|
|
102282
|
+
};
|
|
102276
102283
|
function CustomTabPanel(props) {
|
|
102277
102284
|
const {
|
|
102278
102285
|
children,
|
|
@@ -102427,7 +102434,7 @@ function SideDocsSelector({
|
|
|
102427
102434
|
},
|
|
102428
102435
|
advanced: [{
|
|
102429
102436
|
focusMode: "manual",
|
|
102430
|
-
focusDistance:
|
|
102437
|
+
focusDistance: 1
|
|
102431
102438
|
}]
|
|
102432
102439
|
});
|
|
102433
102440
|
} else {
|
|
@@ -102561,11 +102568,11 @@ function SideDocsSelector({
|
|
|
102561
102568
|
})
|
|
102562
102569
|
})]
|
|
102563
102570
|
})]
|
|
102564
|
-
}) : uploadDocumentByPhone || uploadByGallery ? /* @__PURE__ */ jsx$1(UploadByGallery, {
|
|
102571
|
+
}) : uploadDocumentByPhone || uploadByGallery || isLowEndDevice() ? /* @__PURE__ */ jsx$1(UploadByGallery, {
|
|
102565
102572
|
handleFileChange,
|
|
102566
102573
|
side: "firstImage",
|
|
102567
102574
|
fileInputRef,
|
|
102568
|
-
title: "
|
|
102575
|
+
title: "Cargar documeto",
|
|
102569
102576
|
subtitle: "Vamos a cargar el documento desde tu dispositivo. \xA1Ten en cuenta lo siguiente!",
|
|
102570
102577
|
onClickToContinue,
|
|
102571
102578
|
startUpload
|
|
@@ -102678,7 +102685,7 @@ function SideDocsSelector({
|
|
|
102678
102685
|
})
|
|
102679
102686
|
})]
|
|
102680
102687
|
})]
|
|
102681
|
-
}) : uploadDocumentByPhone || uploadByGallery ? /* @__PURE__ */ jsx$1(UploadByGallery, {
|
|
102688
|
+
}) : uploadDocumentByPhone || uploadByGallery || isLowEndDevice() ? /* @__PURE__ */ jsx$1(UploadByGallery, {
|
|
102682
102689
|
handleFileChange,
|
|
102683
102690
|
side: "secondImage",
|
|
102684
102691
|
fileInputRef,
|