@authme/util 2.8.54 → 2.8.55
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/index.cjs.js +12 -2
- package/index.esm.js +12 -2
- package/package.json +1 -1
package/index.cjs.js
CHANGED
|
@@ -33200,6 +33200,16 @@ async function _requestCamera(video, facingMode, translate) {
|
|
|
33200
33200
|
const aScore = a.device.label.includes(samsungCamera) ? 1 : 0;
|
|
33201
33201
|
samsungCondition = bScore - aScore;
|
|
33202
33202
|
}
|
|
33203
|
+
// 後鏡頭模式下,超廣角鏡頭 (zoom.min < 1) 排後面
|
|
33204
|
+
let ultraWideCondition = 0;
|
|
33205
|
+
if (facingMode === 'back') {
|
|
33206
|
+
var _a$capabilities$zoom$, _a$capabilities, _b$capabilities$zoom$, _b$capabilities;
|
|
33207
|
+
const aZoomMin = (_a$capabilities$zoom$ = (_a$capabilities = a.capabilities) == null || (_a$capabilities = _a$capabilities.zoom) == null ? void 0 : _a$capabilities.min) != null ? _a$capabilities$zoom$ : 1;
|
|
33208
|
+
const bZoomMin = (_b$capabilities$zoom$ = (_b$capabilities = b.capabilities) == null || (_b$capabilities = _b$capabilities.zoom) == null ? void 0 : _b$capabilities.min) != null ? _b$capabilities$zoom$ : 1;
|
|
33209
|
+
const aIsUltraWide = aZoomMin < 1 ? 1 : 0;
|
|
33210
|
+
const bIsUltraWide = bZoomMin < 1 ? 1 : 0;
|
|
33211
|
+
ultraWideCondition = aIsUltraWide - bIsUltraWide;
|
|
33212
|
+
}
|
|
33203
33213
|
let cameraFacingCondition = 0;
|
|
33204
33214
|
{
|
|
33205
33215
|
const aFacingMode = a.meta.facingMode;
|
|
@@ -33209,7 +33219,7 @@ async function _requestCamera(video, facingMode, translate) {
|
|
|
33209
33219
|
cameraFacingCondition = bScore - aScore;
|
|
33210
33220
|
}
|
|
33211
33221
|
const resolutionCondition = b.meta.resolution - a.meta.resolution;
|
|
33212
|
-
return samsungCondition || cameraFacingCondition || resolutionCondition;
|
|
33222
|
+
return samsungCondition || cameraFacingCondition || ultraWideCondition || resolutionCondition;
|
|
33213
33223
|
});
|
|
33214
33224
|
const cameraIndex = window.localStorage.getItem('camera') || '0';
|
|
33215
33225
|
const firstDevice = devices[parseInt(cameraIndex, 10)];
|
|
@@ -34901,7 +34911,7 @@ const themeConfigDefault = {
|
|
|
34901
34911
|
};
|
|
34902
34912
|
|
|
34903
34913
|
var name = "authme/sdk";
|
|
34904
|
-
var version$1 = "2.8.
|
|
34914
|
+
var version$1 = "2.8.55";
|
|
34905
34915
|
var packageInfo = {
|
|
34906
34916
|
name: name,
|
|
34907
34917
|
version: version$1};
|
package/index.esm.js
CHANGED
|
@@ -33198,6 +33198,16 @@ async function _requestCamera(video, facingMode, translate) {
|
|
|
33198
33198
|
const aScore = a.device.label.includes(samsungCamera) ? 1 : 0;
|
|
33199
33199
|
samsungCondition = bScore - aScore;
|
|
33200
33200
|
}
|
|
33201
|
+
// 後鏡頭模式下,超廣角鏡頭 (zoom.min < 1) 排後面
|
|
33202
|
+
let ultraWideCondition = 0;
|
|
33203
|
+
if (facingMode === 'back') {
|
|
33204
|
+
var _a$capabilities$zoom$, _a$capabilities, _b$capabilities$zoom$, _b$capabilities;
|
|
33205
|
+
const aZoomMin = (_a$capabilities$zoom$ = (_a$capabilities = a.capabilities) == null || (_a$capabilities = _a$capabilities.zoom) == null ? void 0 : _a$capabilities.min) != null ? _a$capabilities$zoom$ : 1;
|
|
33206
|
+
const bZoomMin = (_b$capabilities$zoom$ = (_b$capabilities = b.capabilities) == null || (_b$capabilities = _b$capabilities.zoom) == null ? void 0 : _b$capabilities.min) != null ? _b$capabilities$zoom$ : 1;
|
|
33207
|
+
const aIsUltraWide = aZoomMin < 1 ? 1 : 0;
|
|
33208
|
+
const bIsUltraWide = bZoomMin < 1 ? 1 : 0;
|
|
33209
|
+
ultraWideCondition = aIsUltraWide - bIsUltraWide;
|
|
33210
|
+
}
|
|
33201
33211
|
let cameraFacingCondition = 0;
|
|
33202
33212
|
{
|
|
33203
33213
|
const aFacingMode = a.meta.facingMode;
|
|
@@ -33207,7 +33217,7 @@ async function _requestCamera(video, facingMode, translate) {
|
|
|
33207
33217
|
cameraFacingCondition = bScore - aScore;
|
|
33208
33218
|
}
|
|
33209
33219
|
const resolutionCondition = b.meta.resolution - a.meta.resolution;
|
|
33210
|
-
return samsungCondition || cameraFacingCondition || resolutionCondition;
|
|
33220
|
+
return samsungCondition || cameraFacingCondition || ultraWideCondition || resolutionCondition;
|
|
33211
33221
|
});
|
|
33212
33222
|
const cameraIndex = window.localStorage.getItem('camera') || '0';
|
|
33213
33223
|
const firstDevice = devices[parseInt(cameraIndex, 10)];
|
|
@@ -34899,7 +34909,7 @@ const themeConfigDefault = {
|
|
|
34899
34909
|
};
|
|
34900
34910
|
|
|
34901
34911
|
var name = "authme/sdk";
|
|
34902
|
-
var version$1 = "2.8.
|
|
34912
|
+
var version$1 = "2.8.55";
|
|
34903
34913
|
var packageInfo = {
|
|
34904
34914
|
name: name,
|
|
34905
34915
|
version: version$1};
|