idmission-web-sdk 2.3.32 → 2.3.34

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.
@@ -1,16 +1,12 @@
1
- import React, { ReactElement, ReactNode, RefCallback, SyntheticEvent } from 'react';
1
+ import React, { ReactElement, ReactNode, RefCallback } from 'react';
2
2
  export type GuideOrientationState = {
3
3
  orientation: 'portrait' | 'landscape';
4
4
  wrapperWidth: number;
5
5
  wrapperHeight: number;
6
6
  wrapperAspectRatio: number;
7
7
  imageAspectRatio: number;
8
+ setImageAspectRatio: (n: number) => void;
8
9
  wrapperRef: RefCallback<HTMLDivElement>;
9
- setDimensions: (dimensions: {
10
- width: number;
11
- height: number;
12
- }) => void;
13
- onImageLoaded: (e: SyntheticEvent) => void;
14
10
  };
15
11
  export declare const GuideOrientationContext: React.Context<GuideOrientationState>;
16
12
  export default function GuideOrientationContextProvider({ children, }: {
@@ -1 +1 @@
1
- {"version":3,"file":"GuideOrientationContextProvider.d.ts","sourceRoot":"","sources":["../../src/components/GuideOrientationContextProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAEZ,YAAY,EACZ,SAAS,EACT,WAAW,EACX,cAAc,EAKf,MAAM,OAAO,CAAA;AAGd,MAAM,MAAM,qBAAqB,GAAG;IAClC,WAAW,EAAE,UAAU,GAAG,WAAW,CAAA;IACrC,YAAY,EAAE,MAAM,CAAA;IACpB,aAAa,EAAE,MAAM,CAAA;IACrB,kBAAkB,EAAE,MAAM,CAAA;IAC1B,gBAAgB,EAAE,MAAM,CAAA;IACxB,UAAU,EAAE,WAAW,CAAC,cAAc,CAAC,CAAA;IACvC,aAAa,EAAE,CAAC,UAAU,EAAE;QAAE,KAAK,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAE,KAAK,IAAI,CAAA;IACtE,aAAa,EAAE,CAAC,CAAC,EAAE,cAAc,KAAK,IAAI,CAAA;CAC3C,CAAA;AAED,eAAO,MAAM,uBAAuB,sCASlC,CAAA;AAEF,MAAM,CAAC,OAAO,UAAU,+BAA+B,CAAC,EACtD,QAAQ,GACT,EAAE;IACD,QAAQ,EAAE,SAAS,CAAA;CACpB,GAAG,YAAY,CA+Cf;AAED,wBAAgB,0BAA0B,IAAI,qBAAqB,CAOlE"}
1
+ {"version":3,"file":"GuideOrientationContextProvider.d.ts","sourceRoot":"","sources":["../../src/components/GuideOrientationContextProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAEZ,YAAY,EACZ,SAAS,EACT,WAAW,EAIZ,MAAM,OAAO,CAAA;AAGd,MAAM,MAAM,qBAAqB,GAAG;IAClC,WAAW,EAAE,UAAU,GAAG,WAAW,CAAA;IACrC,YAAY,EAAE,MAAM,CAAA;IACpB,aAAa,EAAE,MAAM,CAAA;IACrB,kBAAkB,EAAE,MAAM,CAAA;IAC1B,gBAAgB,EAAE,MAAM,CAAA;IACxB,mBAAmB,EAAE,CAAC,CAAC,EAAE,MAAM,KAAK,IAAI,CAAA;IACxC,UAAU,EAAE,WAAW,CAAC,cAAc,CAAC,CAAA;CACxC,CAAA;AAED,eAAO,MAAM,uBAAuB,sCAQlC,CAAA;AAEF,MAAM,CAAC,OAAO,UAAU,+BAA+B,CAAC,EACtD,QAAQ,GACT,EAAE;IACD,QAAQ,EAAE,SAAS,CAAA;CACpB,GAAG,YAAY,CAsCf;AAED,wBAAgB,0BAA0B,IAAI,qBAAqB,CAOlE"}
@@ -15,7 +15,7 @@ export type FlipIdPromptProps = {
15
15
  width?: number;
16
16
  height?: number;
17
17
  padding?: number;
18
- imagePadding?: number | string;
18
+ imagePadding?: number;
19
19
  borderWidth?: number | string;
20
20
  borderColor?: string;
21
21
  borderRadius?: number;
@@ -1 +1 @@
1
- {"version":3,"file":"FlipIdPrompt.d.ts","sourceRoot":"","sources":["../../../src/components/id_capture/FlipIdPrompt.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAE,YAAY,EAAuB,MAAM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B,MAAM,MAAM,sBAAsB,GAAG;IACnC,mBAAmB,CAAC,EAAE,MAAM,CAAA;IAC5B,kBAAkB,CAAC,EAAE,MAAM,CAAA;IAC3B,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB,CAAA;AAED,MAAM,MAAM,oBAAoB,GAAG;IACjC,eAAe,CAAC,EAAE,wBAAwB,CAAA;CAC3C,CAAA;AAED,MAAM,MAAM,iBAAiB,GAAG;IAC9B,MAAM,CAAC,EAAE,oBAAoB,CAAA;IAC7B,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,WAAW,CAAC,EAAE,MAAM,GAAG,MAAM,CAAA;IAC7B,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB,sBAAsB,CAAC,EAAE,OAAO,CAAA;IAChC,UAAU,CAAC,EAAE,sBAAsB,CAAA;IACnC,QAAQ,CAAC,EAAE,oBAAoB,CAAA;CAChC,CAAA;AAED,eAAO,MAAM,YAAY,uHAUtB,iBAAiB,KAAG,YAyEtB,CAAA"}
@@ -22,7 +22,7 @@ export type IdCaptureGuideOverlayProps = {
22
22
  classNames?: IdCaptureGuideOverlayClassNames;
23
23
  images?: IdCaptureGuideImages;
24
24
  padding?: number;
25
- imagePadding?: number | string;
25
+ imagePadding?: number;
26
26
  imageVisible?: boolean;
27
27
  borderWidth?: number;
28
28
  borderColor?: string;
@@ -64,5 +64,7 @@ export declare const GuideCenterBorder: import("styled-components/dist/types").I
64
64
  $padding?: number;
65
65
  }>> & string;
66
66
  export declare const GuideText: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, never>> & string;
67
- export declare const GuideCenterInner: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
67
+ export declare const GuideCenterInner: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {
68
+ $isLandscape?: boolean;
69
+ }>> & string;
68
70
  //# sourceMappingURL=IdCaptureGuideOverlay.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"IdCaptureGuideOverlay.d.ts","sourceRoot":"","sources":["../../../src/components/id_capture/IdCaptureGuideOverlay.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EACZ,YAAY,EAIb,MAAM,OAAO,CAAA;AAOd,OAAO,EAGL,iBAAiB,EAClB,MAAM,yBAAyB,CAAA;AAChC,OAAO,EAAgB,sBAAsB,EAAE,MAAM,gBAAgB,CAAA;AAErE,OAAO,EAGL,oBAAoB,EAGrB,MAAM,iBAAiB,CAAA;AAExB,MAAM,MAAM,+BAA+B,GAAG;IAC5C,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,gBAAgB,CAAC,EAAE,MAAM,CAAA;IACzB,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B,kBAAkB,CAAC,EAAE,MAAM,CAAA;IAC3B,mBAAmB,CAAC,EAAE,MAAM,CAAA;IAC5B,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,kBAAkB,CAAC,EAAE,MAAM,CAAA;IAC3B,iBAAiB,CAAC,EAAE,MAAM,CAAA;IAC1B,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,YAAY,CAA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number;
9
9
  }, {
10
10
  $isVisible?: boolean;
11
- $aspectRatio?: string;
11
+ aspectRatio?: number | string;
12
12
  }>> & string & Omit<typeof IdCardBorder, keyof React.Component<any, {}, any>>;
13
13
  export declare const IdCardGuideImage: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<React.DetailedHTMLProps<React.ImgHTMLAttributes<HTMLImageElement>, HTMLImageElement>, {
14
14
  $isMirrored?: boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"IdCaptureGuidesCommon.d.ts","sourceRoot":"","sources":["../../../src/components/id_capture/IdCaptureGuidesCommon.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAwC,MAAM,OAAO,CAAA;AAM5D,eAAO,MAAM,yBAAyB;aAkC3B,iBAAiB;kBACZ,MAAM,GAAG,MAAM;mBACd,MAAM;kBACP,MAAM;kBACN,MAAM;eACT,MAAM;;iBAtCJ,OAAO;mBACL,MAAM;6EAOtB,CAAA;AAED,eAAO,MAAM,gBAAgB;kBACb,OAAO;mBACN,OAAO;YAOvB,CAAA;AAED,MAAM,MAAM,iBAAiB,GAAG,UAAU,GAAG,OAAO,GAAG,WAAW,CAAA;AAElE,iBAAS,YAAY,CAAC,EACpB,QAAQ,EACR,MAAgB,EAChB,WAAgB,EAChB,YAAiB,EACjB,WAAqB,EACrB,WAAW,EACX,QAAY,EACZ,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC,GAAG;IACxC,MAAM,CAAC,EAAE,iBAAiB,CAAA;IAC1B,WAAW,CAAC,EAAE,MAAM,GAAG,MAAM,CAAA;IAC7B,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB,qBAoFA"}
1
+ {"version":3,"file":"IdCaptureGuidesCommon.d.ts","sourceRoot":"","sources":["../../../src/components/id_capture/IdCaptureGuidesCommon.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAwC,MAAM,OAAO,CAAA;AAM5D,eAAO,MAAM,yBAAyB;aA+B3B,iBAAiB;kBACZ,MAAM,GAAG,MAAM;mBACd,MAAM;kBACP,MAAM;kBACN,MAAM;eACT,MAAM;;iBAnCJ,OAAO;kBACN,MAAM,GAAG,MAAM;6EAK9B,CAAA;AAED,eAAO,MAAM,gBAAgB;kBACb,OAAO;mBACN,OAAO;YAMvB,CAAA;AAED,MAAM,MAAM,iBAAiB,GAAG,UAAU,GAAG,OAAO,GAAG,WAAW,CAAA;AAElE,iBAAS,YAAY,CAAC,EACpB,QAAQ,EACR,MAAgB,EAChB,WAAgB,EAChB,YAAiB,EACjB,WAAqB,EACrB,WAAe,EACf,QAAY,EACZ,GAAG,KAAK,EACT,EAAE,KAAK,CAAC,cAAc,CAAC,cAAc,CAAC,GAAG;IACxC,MAAM,CAAC,EAAE,iBAAiB,CAAA;IAC1B,WAAW,CAAC,EAAE,MAAM,GAAG,MAAM,CAAA;IAC7B,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB,qBA6FA"}
@@ -22,9 +22,9 @@ export declare const FlipImageContainer: import("styled-components/dist/types").
22
22
  borderColor?: string;
23
23
  aspectRatio?: number;
24
24
  progress?: number;
25
- }, "$isVisible" | "$aspectRatio"> & {
25
+ }, "aspectRatio" | "$isVisible"> & {
26
26
  $isVisible?: boolean;
27
- $aspectRatio?: string;
27
+ aspectRatio?: number | string;
28
28
  }, {
29
29
  $transforms: string;
30
30
  $transitionTime: number;
@@ -235,7 +235,7 @@ typeof SuppressedError === "function" ? SuppressedError : function (error, suppr
235
235
  return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
236
236
  };
237
237
 
238
- var webSdkVersion = '2.3.32';
238
+ var webSdkVersion = '2.3.34';
239
239
 
240
240
  function getPlatform() {
241
241
  // eslint-disable-next-line @typescript-eslint/ban-ts-comment
@@ -7947,12 +7947,10 @@ function resetCanvasDimensions(canvas) {
7947
7947
  canvas.style.height = '0';
7948
7948
  }
7949
7949
 
7950
- var IdCardGuideImageContainer = styled__default.default(IdCardBorder)(templateObject_1$A || (templateObject_1$A = __makeTemplateObject(["\n position: relative;\n ", "\n box-sizing: border-box;\n aspect-ratio: ", ";\n display: flex;\n"], ["\n position: relative;\n ", "\n box-sizing: border-box;\n aspect-ratio: ", ";\n display: flex;\n"])), function (props) {
7950
+ var IdCardGuideImageContainer = styled__default.default(IdCardBorder)(templateObject_1$A || (templateObject_1$A = __makeTemplateObject(["\n position: relative;\n ", "\n box-sizing: border-box;\n"], ["\n position: relative;\n ", "\n box-sizing: border-box;\n"])), function (props) {
7951
7951
  return props.$isVisible ? '' : 'opacity: 0;';
7952
- }, function (props) {
7953
- return props.$aspectRatio;
7954
7952
  });
7955
- var IdCardGuideImage = styled__default.default.img(templateObject_2$t || (templateObject_2$t = __makeTemplateObject(["\n transform-style: preserve-3d;\n ", "\n ", "\n max-width: 100%;\n max-height: 100%;\n"], ["\n transform-style: preserve-3d;\n ", "\n ", "\n max-width: 100%;\n max-height: 100%;\n"])), function (props) {
7953
+ var IdCardGuideImage = styled__default.default.img(templateObject_2$t || (templateObject_2$t = __makeTemplateObject(["\n max-height: 100%;\n transform-style: preserve-3d;\n ", "\n ", "\n"], ["\n max-height: 100%;\n transform-style: preserve-3d;\n ", "\n ", "\n"])), function (props) {
7956
7954
  return props.$isMirrored ? 'transform: scaleX(-1);' : '';
7957
7955
  }, function (props) {
7958
7956
  return props.$isInvisible ? 'opacity: 0;' : '';
@@ -7968,19 +7966,20 @@ function IdCardBorder(_a) {
7968
7966
  borderRadius = _u === void 0 ? 25 : _u,
7969
7967
  _v = _a.borderColor,
7970
7968
  borderColor = _v === void 0 ? 'white' : _v,
7971
- aspectRatio = _a.aspectRatio,
7972
- _w = _a.progress,
7973
- progress = _w === void 0 ? 0 : _w,
7969
+ _w = _a.aspectRatio,
7970
+ aspectRatio = _w === void 0 ? 1 : _w,
7971
+ _x = _a.progress,
7972
+ progress = _x === void 0 ? 0 : _x,
7974
7973
  props = __rest(_a, ["children", "status", "borderWidth", "borderRadius", "borderColor", "aspectRatio", "progress"]);
7975
- var _x = useResizeObserver(),
7976
- ref = _x.ref,
7977
- _y = _x.width,
7978
- width = _y === void 0 ? 0 : _y,
7979
- _z = _x.height,
7980
- height = _z === void 0 ? 0 : _z;
7981
- var _0 = React.useState(0),
7982
- progressResets = _0[0],
7983
- setProgressResets = _0[1];
7974
+ var _y = useResizeObserver(),
7975
+ ref = _y.ref,
7976
+ _z = _y.width,
7977
+ width = _z === void 0 ? 0 : _z,
7978
+ _0 = _y.height,
7979
+ height = _0 === void 0 ? 0 : _0;
7980
+ var _1 = React.useState(0),
7981
+ progressResets = _1[0],
7982
+ setProgressResets = _1[1];
7984
7983
  React.useEffect(function () {
7985
7984
  if (progress === 0 && status === 'capturing') {
7986
7985
  setProgressResets(function (n) {
@@ -7994,11 +7993,17 @@ function IdCardBorder(_a) {
7994
7993
  var progressBarColor = (_k = (_j = (_h = theme.idCapture) === null || _h === void 0 ? void 0 : _h.guideBox) === null || _j === void 0 ? void 0 : _j.progressBarColor) !== null && _k !== void 0 ? _k : borderColor;
7995
7994
  var progressBarIndicatorColor = (_o = (_m = (_l = theme.idCapture) === null || _l === void 0 ? void 0 : _l.guideBox) === null || _m === void 0 ? void 0 : _m.progressBarIndicatorColor) !== null && _o !== void 0 ? _o : '#287ec6';
7996
7995
  var progressBarWidth = (_r = (_q = (_p = theme.idCapture) === null || _p === void 0 ? void 0 : _p.guideBox) === null || _q === void 0 ? void 0 : _q.progressBarWidth) !== null && _r !== void 0 ? _r : borderWidth;
7997
- return /*#__PURE__*/React__namespace.default.createElement(IdCardBorderContainer, _assign({}, props), /*#__PURE__*/React__namespace.default.createElement("div", {
7996
+ return /*#__PURE__*/React__namespace.default.createElement(IdCardBorderContainer, _assign({}, props, {
7997
+ style: {
7998
+ aspectRatio: aspectRatio
7999
+ }
8000
+ }), /*#__PURE__*/React__namespace.default.createElement("div", {
7998
8001
  ref: ref,
7999
8002
  style: {
8000
- aspectRatio: aspectRatio,
8001
- flex: 1
8003
+ maxHeight: '100%',
8004
+ maxWidth: '100%',
8005
+ display: 'flex',
8006
+ aspectRatio: aspectRatio
8002
8007
  }
8003
8008
  }, children), status === 'ready' && !wavesDisabled && ( /*#__PURE__*/React__namespace.default.createElement(React__namespace.default.Fragment, null, /*#__PURE__*/React__namespace.default.createElement(IdCardBorderSvg, {
8004
8009
  width: width,
@@ -8097,7 +8102,7 @@ function IdCardBorderSvg(_a) {
8097
8102
  className: isProgressBar ? "idmSdkProgressBorder ".concat(progressPaused ? 'idmSdkProgressPaused' : '') : ''
8098
8103
  }));
8099
8104
  }
8100
- var IdCardBorderContainer = styled__default.default.div(templateObject_3$k || (templateObject_3$k = __makeTemplateObject(["\n & > .idmSdkWaves {\n position: absolute;\n animation: ", " 2s ease-out infinite;\n transform-style: preserve-3d;\n\n &:nth-child(2) {\n animation-delay: 0.66s;\n }\n\n &:nth-child(3) {\n animation-delay: 1.33s;\n }\n }\n"], ["\n & > .idmSdkWaves {\n position: absolute;\n animation: ", " 2s ease-out infinite;\n transform-style: preserve-3d;\n\n &:nth-child(2) {\n animation-delay: 0.66s;\n }\n\n &:nth-child(3) {\n animation-delay: 1.33s;\n }\n }\n"])), wavesAnimation);
8105
+ var IdCardBorderContainer = styled__default.default.div(templateObject_3$k || (templateObject_3$k = __makeTemplateObject(["\n max-width: 100%;\n max-height: 100%;\n\n & > .idmSdkWaves {\n position: absolute;\n animation: ", " 2s ease-out infinite;\n transform-style: preserve-3d;\n\n &:nth-child(2) {\n animation-delay: 0.66s;\n }\n\n &:nth-child(3) {\n animation-delay: 1.33s;\n }\n }\n"], ["\n max-width: 100%;\n max-height: 100%;\n\n & > .idmSdkWaves {\n position: absolute;\n animation: ", " 2s ease-out infinite;\n transform-style: preserve-3d;\n\n &:nth-child(2) {\n animation-delay: 0.66s;\n }\n\n &:nth-child(3) {\n animation-delay: 1.33s;\n }\n }\n"])), wavesAnimation);
8101
8106
  var SvgOverlay = styled__default.default.svg(templateObject_4$e || (templateObject_4$e = __makeTemplateObject(["\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n pointer-events: none;\n"], ["\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n pointer-events: none;\n"])));
8102
8107
  var IdCardBorderRect = styled__default.default.rect(templateObject_5$a || (templateObject_5$a = __makeTemplateObject(["\n &.idmSdkProgressBorder {\n animation: ", " ", "\n ", ";\n }\n\n &.idmSdkProgressPaused {\n animation-play-state: paused;\n }\n"], ["\n &.idmSdkProgressBorder {\n animation: ", " ", "\n ", ";\n }\n\n &.idmSdkProgressPaused {\n animation-play-state: paused;\n }\n"])), progressBorderAnimation, function (props) {
8103
8108
  var _a;
@@ -8289,65 +8294,6 @@ var FlipImageContainer = styled__default.default(IdCardGuideImageContainer)(temp
8289
8294
  });
8290
8295
  var templateObject_1$z;
8291
8296
 
8292
- var GuideOrientationContext = /*#__PURE__*/React.createContext({
8293
- orientation: 'landscape',
8294
- wrapperWidth: 1,
8295
- wrapperHeight: 1,
8296
- wrapperAspectRatio: 0,
8297
- imageAspectRatio: 0,
8298
- wrapperRef: null,
8299
- setDimensions: function setDimensions() {
8300
- return null;
8301
- },
8302
- onImageLoaded: function onImageLoaded() {
8303
- return null;
8304
- }
8305
- });
8306
- function GuideOrientationContextProvider(_a) {
8307
- var children = _a.children;
8308
- var setDimensions = React.useState({
8309
- width: 1,
8310
- height: 1
8311
- })[1];
8312
- var _b = React.useState(1),
8313
- imageAspectRatio = _b[0],
8314
- setImageAspectRatio = _b[1];
8315
- var _c = useResizeObserver(),
8316
- wrapperRef = _c.ref,
8317
- _d = _c.width,
8318
- wrapperWidth = _d === void 0 ? 1 : _d,
8319
- _e = _c.height,
8320
- wrapperHeight = _e === void 0 ? 1 : _e;
8321
- var wrapperAspectRatio = React.useMemo(function () {
8322
- return wrapperWidth / wrapperHeight;
8323
- }, [wrapperHeight, wrapperWidth]);
8324
- var onImageLoaded = React.useCallback(function (e) {
8325
- var img = e.target;
8326
- setImageAspectRatio(img.naturalWidth / img.naturalHeight);
8327
- }, []);
8328
- var orientation = 'landscape'; //width > height ? 'landscape' : 'portrait'
8329
- var value = React.useMemo(function () {
8330
- return {
8331
- orientation: orientation,
8332
- wrapperWidth: wrapperWidth,
8333
- wrapperHeight: wrapperHeight,
8334
- wrapperAspectRatio: wrapperAspectRatio,
8335
- imageAspectRatio: imageAspectRatio,
8336
- setDimensions: setDimensions,
8337
- wrapperRef: wrapperRef,
8338
- onImageLoaded: onImageLoaded
8339
- };
8340
- }, [imageAspectRatio, onImageLoaded, setDimensions, wrapperAspectRatio, wrapperHeight, wrapperRef, wrapperWidth]);
8341
- return /*#__PURE__*/React__namespace.default.createElement(GuideOrientationContext.Provider, {
8342
- value: value
8343
- }, children);
8344
- }
8345
- function useGuideOrientationContext() {
8346
- var ctx = React.useContext(GuideOrientationContext);
8347
- if (!ctx) throw new Error('useGuideOrientationContext cannot be used without GuideOrientationContextProvider');
8348
- return ctx;
8349
- }
8350
-
8351
8297
  var FlipIdPrompt = function FlipIdPrompt(_a) {
8352
8298
  var _b = _a.images,
8353
8299
  images = _b === void 0 ? defaultIdCaptureGuideImages : _b,
@@ -8365,7 +8311,6 @@ var FlipIdPrompt = function FlipIdPrompt(_a) {
8365
8311
  portraitGuidesOnMobile = _g === void 0 ? true : _g,
8366
8312
  _h = _a.classNames,
8367
8313
  classNames = _h === void 0 ? {} : _h;
8368
- var onImageLoaded = useGuideOrientationContext().onImageLoaded;
8369
8314
  var orientation = getOrientation(portraitGuidesOnMobile);
8370
8315
  var _j = React.useState(1),
8371
8316
  transitionTime = _j[0],
@@ -8407,7 +8352,6 @@ var FlipIdPrompt = function FlipIdPrompt(_a) {
8407
8352
  alt: "",
8408
8353
  src: images[orientation].SHOW_ID_FRONT.url,
8409
8354
  className: classNames.frontImage,
8410
- onLoad: onImageLoaded,
8411
8355
  width: width,
8412
8356
  height: height
8413
8357
  })), /*#__PURE__*/React__namespace.default.createElement(FlipImageContainer, {
@@ -8428,86 +8372,114 @@ var FlipIdPrompt = function FlipIdPrompt(_a) {
8428
8372
  })));
8429
8373
  };
8430
8374
 
8375
+ var GuideOrientationContext = /*#__PURE__*/React.createContext({
8376
+ orientation: 'landscape',
8377
+ wrapperWidth: 1,
8378
+ wrapperHeight: 1,
8379
+ wrapperAspectRatio: 0,
8380
+ imageAspectRatio: 0,
8381
+ wrapperRef: null,
8382
+ setImageAspectRatio: function setImageAspectRatio() {
8383
+ return null;
8384
+ }
8385
+ });
8386
+ function GuideOrientationContextProvider(_a) {
8387
+ var children = _a.children;
8388
+ var _b = React.useState(1),
8389
+ imageAspectRatio = _b[0],
8390
+ setImageAspectRatio = _b[1];
8391
+ var _c = useResizeObserver(),
8392
+ wrapperRef = _c.ref,
8393
+ _d = _c.width,
8394
+ wrapperWidth = _d === void 0 ? 1 : _d,
8395
+ _e = _c.height,
8396
+ wrapperHeight = _e === void 0 ? 1 : _e;
8397
+ var wrapperAspectRatio = React.useMemo(function () {
8398
+ return wrapperWidth / wrapperHeight;
8399
+ }, [wrapperHeight, wrapperWidth]);
8400
+ var orientation = 'landscape'; //width > height ? 'landscape' : 'portrait'
8401
+ var value = React.useMemo(function () {
8402
+ return {
8403
+ orientation: orientation,
8404
+ wrapperWidth: wrapperWidth,
8405
+ wrapperHeight: wrapperHeight,
8406
+ wrapperAspectRatio: wrapperAspectRatio,
8407
+ imageAspectRatio: imageAspectRatio,
8408
+ setImageAspectRatio: setImageAspectRatio,
8409
+ wrapperRef: wrapperRef
8410
+ };
8411
+ }, [imageAspectRatio, wrapperAspectRatio, wrapperHeight, wrapperRef, wrapperWidth]);
8412
+ return /*#__PURE__*/React__namespace.default.createElement(GuideOrientationContext.Provider, {
8413
+ value: value
8414
+ }, children);
8415
+ }
8416
+ function useGuideOrientationContext() {
8417
+ var ctx = React.useContext(GuideOrientationContext);
8418
+ if (!ctx) throw new Error('useGuideOrientationContext cannot be used without GuideOrientationContextProvider');
8419
+ return ctx;
8420
+ }
8421
+
8431
8422
  var IdCaptureGuideOverlay = function IdCaptureGuideOverlay(_a) {
8432
- var _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;
8433
- var _p = _a.classNames,
8434
- classNames = _p === void 0 ? {} : _p,
8435
- _q = _a.images,
8436
- userSuppliedImages = _q === void 0 ? defaultIdCaptureGuideImages : _q,
8423
+ var _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r;
8424
+ var _s = _a.classNames,
8425
+ classNames = _s === void 0 ? {} : _s,
8426
+ _t = _a.images,
8427
+ userSuppliedImages = _t === void 0 ? defaultIdCaptureGuideImages : _t,
8437
8428
  userSuppliedPadding = _a.padding,
8438
8429
  userSuppliedImagePadding = _a.imagePadding,
8439
- _r = _a.imageVisible,
8440
- imageVisible = _r === void 0 ? true : _r,
8430
+ _u = _a.imageVisible,
8431
+ imageVisible = _u === void 0 ? true : _u,
8441
8432
  borderWidth = _a.borderWidth,
8442
8433
  borderColor = _a.borderColor,
8443
- _s = _a.idCardBorderWidth,
8444
- idCardBorderWidth = _s === void 0 ? '2.5%' : _s,
8445
- _t = _a.idCardBorderColor,
8446
- idCardBorderColor = _t === void 0 ? 'white' : _t,
8434
+ _v = _a.idCardBorderWidth,
8435
+ idCardBorderWidth = _v === void 0 ? '2.5%' : _v,
8436
+ _w = _a.idCardBorderColor,
8437
+ idCardBorderColor = _w === void 0 ? 'white' : _w,
8447
8438
  maskColor = _a.maskColor,
8448
- _u = _a.isMirrored,
8449
- isMirrored = _u === void 0 ? false : _u,
8450
- _v = _a.isBackToFront,
8451
- isBackToFront = _v === void 0 ? false : _v,
8452
- _w = _a.portraitGuidesOnMobile,
8453
- portraitGuidesOnMobile = _w === void 0 ? true : _w,
8454
- _x = _a.instruction,
8455
- instruction = _x === void 0 ? '' : _x,
8456
- _y = _a.requestedAction,
8457
- requestedAction = _y === void 0 ? 'SHOW_ID_FRONT' : _y,
8458
- _z = _a.progress,
8459
- progress = _z === void 0 ? 0 : _z,
8460
- _0 = _a.status,
8461
- status = _0 === void 0 ? 'ready' : _0,
8439
+ _x = _a.isMirrored,
8440
+ isMirrored = _x === void 0 ? false : _x,
8441
+ _y = _a.isBackToFront,
8442
+ isBackToFront = _y === void 0 ? false : _y,
8443
+ _z = _a.portraitGuidesOnMobile,
8444
+ portraitGuidesOnMobile = _z === void 0 ? true : _z,
8445
+ _0 = _a.instruction,
8446
+ instruction = _0 === void 0 ? '' : _0,
8447
+ _1 = _a.requestedAction,
8448
+ requestedAction = _1 === void 0 ? 'SHOW_ID_FRONT' : _1,
8449
+ _2 = _a.progress,
8450
+ progress = _2 === void 0 ? 0 : _2,
8451
+ _3 = _a.status,
8452
+ status = _3 === void 0 ? 'ready' : _3,
8462
8453
  onClick = _a.onClick;
8463
- var _1 = useGuideOrientationContext(),
8464
- wrapperRef = _1.wrapperRef,
8465
- wrapperWidth = _1.wrapperWidth,
8466
- wrapperHeight = _1.wrapperHeight,
8467
- imageAspectRatio = _1.imageAspectRatio,
8468
- wrapperAspectRatio = _1.wrapperAspectRatio,
8469
- guideOrientationOnImageLoaded = _1.onImageLoaded,
8470
- setDimensions = _1.setDimensions;
8471
- var state = useIdCaptureStore();
8454
+ var _4 = useGuideOrientationContext(),
8455
+ wrapperRef = _4.wrapperRef,
8456
+ wrapperWidth = _4.wrapperWidth,
8457
+ imageAspectRatio = _4.imageAspectRatio,
8458
+ wrapperAspectRatio = _4.wrapperAspectRatio,
8459
+ setImageAspectRatio = _4.setImageAspectRatio;
8460
+ var _5 = useResizeObserver(),
8461
+ innerRef = _5.ref,
8462
+ innerWidth = _5.width,
8463
+ innerHeight = _5.height;
8472
8464
  var theme = styled.useTheme();
8473
8465
  if (borderWidth === undefined) borderWidth = (_d = (_c = (_b = theme.idCapture) === null || _b === void 0 ? void 0 : _b.guideBox) === null || _c === void 0 ? void 0 : _c.borderWidth) !== null && _d !== void 0 ? _d : 4;
8474
- React.useEffect(function () {
8475
- setDimensions({
8476
- width: wrapperWidth,
8477
- height: wrapperHeight
8478
- });
8479
- }, [setDimensions, wrapperHeight, wrapperWidth]);
8480
8466
  var padding = userSuppliedPadding !== null && userSuppliedPadding !== void 0 ? userSuppliedPadding : isMobile() ? (_g = (_f = (_e = theme.idCapture) === null || _e === void 0 ? void 0 : _e.guideBox) === null || _f === void 0 ? void 0 : _f.mobilePadding) !== null && _g !== void 0 ? _g : 0 : (_k = (_j = (_h = theme.idCapture) === null || _h === void 0 ? void 0 : _h.guideBox) === null || _j === void 0 ? void 0 : _j.desktopPadding) !== null && _k !== void 0 ? _k : 50;
8481
8467
  var paddingAndBorderPx = padding * 2 + (borderWidth !== null && borderWidth !== void 0 ? borderWidth : 0) * 2;
8482
8468
  var images = useImagesWithBackToFront(userSuppliedImages, isBackToFront);
8483
- var imagesByUrl = useGuideImagesByUrl(images);
8484
8469
  var orientation = getOrientation(portraitGuidesOnMobile);
8485
8470
  var currentImage = images[orientation][requestedAction === 'FLIP_ID' ? 'SHOW_ID_FRONT' : requestedAction];
8486
- var imagePadding = (_o = userSuppliedImagePadding !== null && userSuppliedImagePadding !== void 0 ? userSuppliedImagePadding : (_m = (_l = theme.idCapture) === null || _l === void 0 ? void 0 : _l.guideBox) === null || _m === void 0 ? void 0 : _m.imagePadding) !== null && _o !== void 0 ? _o : '0 50px';
8487
- if (typeof imagePadding === 'number') {
8488
- imagePadding = "".concat(imagePadding, "px");
8489
- }
8490
- var paddingForMath = imagePadding.replace(/[^0-9\s]/g, '').split(' ').map(Number);
8491
- var paddingForMathMax = Math.max.apply(Math, paddingForMath);
8492
- var imageWidth = state.guideRectWidth - paddingForMathMax * 2;
8493
- var imageHeight = state.guideRectHeight - paddingForMathMax * 2;
8471
+ var imagePadding = userSuppliedImagePadding !== null && userSuppliedImagePadding !== void 0 ? userSuppliedImagePadding : isMobile() ? (_o = (_m = (_l = theme.idCapture) === null || _l === void 0 ? void 0 : _l.guideBox) === null || _m === void 0 ? void 0 : _m.mobileImagePadding) !== null && _o !== void 0 ? _o : 0 : (_r = (_q = (_p = theme.idCapture) === null || _p === void 0 ? void 0 : _p.guideBox) === null || _q === void 0 ? void 0 : _q.imagePadding) !== null && _r !== void 0 ? _r : 50;
8494
8472
  var centerRegionMinWidth = imageAspectRatio >= wrapperAspectRatio ? wrapperWidth - paddingAndBorderPx : undefined;
8495
- var cardAspectRatio = imageAspectRatio > 1 ? '1.6' : '0.625';
8496
- var onImageLoaded = React.useCallback(function (e) {
8497
- var _a, _b;
8498
- guideOrientationOnImageLoaded(e);
8499
- var img = e.currentTarget;
8500
- var imageByUrl = imagesByUrl[img.src];
8501
- var width = (_a = imageByUrl === null || imageByUrl === void 0 ? void 0 : imageByUrl.width) !== null && _a !== void 0 ? _a : img.naturalWidth;
8502
- var height = (_b = imageByUrl === null || imageByUrl === void 0 ? void 0 : imageByUrl.height) !== null && _b !== void 0 ? _b : img.naturalHeight;
8473
+ function onImageLoaded() {
8474
+ setImageAspectRatio(currentImage.width / currentImage.height);
8503
8475
  dispatchIdCaptureAction({
8504
8476
  type: 'guideImageLoaded',
8505
8477
  payload: {
8506
- width: width,
8507
- height: height
8478
+ width: currentImage.width,
8479
+ height: currentImage.height
8508
8480
  }
8509
8481
  });
8510
- }, [guideOrientationOnImageLoaded, imagesByUrl]);
8482
+ }
8511
8483
  return /*#__PURE__*/React__namespace.default.createElement(StyledPageContainer, {
8512
8484
  ref: wrapperRef,
8513
8485
  onClick: onClick,
@@ -8536,14 +8508,19 @@ var IdCaptureGuideOverlay = function IdCaptureGuideOverlay(_a) {
8536
8508
  "$padding": imagePadding,
8537
8509
  className: classNames.centerRegionBorder
8538
8510
  }, /*#__PURE__*/React__namespace.default.createElement(GuideCenterInner, {
8539
- className: classNames.centerRegionInner
8511
+ "$isLandscape": orientation === 'landscape',
8512
+ ref: innerRef,
8513
+ className: classNames.centerRegionInner,
8514
+ style: {
8515
+ aspectRatio: imageAspectRatio
8516
+ }
8540
8517
  }, /*#__PURE__*/React__namespace.default.createElement(IdCardGuideImageContainer, {
8541
8518
  status: status,
8542
8519
  progress: progress,
8543
8520
  borderWidth: idCardBorderWidth,
8544
8521
  borderColor: idCardBorderColor,
8545
8522
  "$isVisible": requestedAction !== 'FLIP_ID',
8546
- "$aspectRatio": cardAspectRatio
8523
+ aspectRatio: imageAspectRatio
8547
8524
  }, /*#__PURE__*/React__namespace.default.createElement(IdCardGuideImage, {
8548
8525
  alt: "",
8549
8526
  src: currentImage.url,
@@ -8551,8 +8528,8 @@ var IdCaptureGuideOverlay = function IdCaptureGuideOverlay(_a) {
8551
8528
  className: classNames.image,
8552
8529
  "$isInvisible": !imageVisible,
8553
8530
  "$isMirrored": isMirrored,
8554
- width: imageWidth,
8555
- height: imageHeight
8531
+ width: innerWidth || currentImage.width,
8532
+ height: innerHeight || currentImage.height
8556
8533
  })), requestedAction === 'FLIP_ID' && ( /*#__PURE__*/React__namespace.default.createElement(FlipIdPrompt, {
8557
8534
  images: images,
8558
8535
  borderWidth: idCardBorderWidth,
@@ -8560,8 +8537,8 @@ var IdCaptureGuideOverlay = function IdCaptureGuideOverlay(_a) {
8560
8537
  portraitGuidesOnMobile: portraitGuidesOnMobile,
8561
8538
  isMirrored: isMirrored,
8562
8539
  classNames: classNames.flipIdPrompt,
8563
- width: imageWidth,
8564
- height: imageHeight
8540
+ width: currentImage.width,
8541
+ height: currentImage.height
8565
8542
  }))))), /*#__PURE__*/React__namespace.default.createElement(Spacer, {
8566
8543
  "$maskColor": maskColor,
8567
8544
  "$minWidth": padding,
@@ -8601,14 +8578,16 @@ var GuideCenterRegion = styled__default.default.div(templateObject_6$6 || (templ
8601
8578
  }, function (props) {
8602
8579
  return props.$isMirrored ? 'transform: scaleX(-1);' : '';
8603
8580
  });
8604
- var GuideCenterBorder = styled__default.default.div(templateObject_7$4 || (templateObject_7$4 = __makeTemplateObject(["\n box-sizing: border-box;\n border: ", ";\n display: flex;\n flex: 1;\n justify-content: center;\n max-height: 100%;\n min-height: 0;\n position: relative;\n ", "\n"], ["\n box-sizing: border-box;\n border: ", ";\n display: flex;\n flex: 1;\n justify-content: center;\n max-height: 100%;\n min-height: 0;\n position: relative;\n ", "\n"])), function (props) {
8581
+ var GuideCenterBorder = styled__default.default.div(templateObject_7$4 || (templateObject_7$4 = __makeTemplateObject(["\n box-sizing: border-box;\n border: ", ";\n display: flex;\n flex: 1;\n justify-content: center;\n max-height: 100%;\n min-height: 0;\n max-width: 100%;\n position: relative;\n ", "\n"], ["\n box-sizing: border-box;\n border: ", ";\n display: flex;\n flex: 1;\n justify-content: center;\n max-height: 100%;\n min-height: 0;\n max-width: 100%;\n position: relative;\n ", "\n"])), function (props) {
8605
8582
  var _a, _b;
8606
8583
  return "".concat((_a = props.$borderWidth) !== null && _a !== void 0 ? _a : 4, "px solid ").concat((_b = props.$borderColor) !== null && _b !== void 0 ? _b : 'white');
8607
8584
  }, function (props) {
8608
- return props.$padding ? "padding: ".concat(props.$padding, ";") : '';
8585
+ return props.$padding ? "padding: ".concat(props.$padding, "px;") : '';
8609
8586
  });
8610
8587
  var GuideText = styled__default.default.span(templateObject_8$2 || (templateObject_8$2 = __makeTemplateObject(["\n align-content: center;\n margin-top: 12px;\n margin-bottom: 12px;\n"], ["\n align-content: center;\n margin-top: 12px;\n margin-bottom: 12px;\n"])));
8611
- var GuideCenterInner = styled__default.default.div(templateObject_9$2 || (templateObject_9$2 = __makeTemplateObject(["\n position: relative;\n margin: auto;\n"], ["\n position: relative;\n margin: auto;\n"])));
8588
+ var GuideCenterInner = styled__default.default.div(templateObject_9$2 || (templateObject_9$2 = __makeTemplateObject(["\n position: relative;\n margin: auto;\n ", "\n max-height: 100%;\n max-width: 100%;\n display: flex;\n align-items: center;\n justify-content: center;\n"], ["\n position: relative;\n margin: auto;\n ", "\n max-height: 100%;\n max-width: 100%;\n display: flex;\n align-items: center;\n justify-content: center;\n"])), function (props) {
8589
+ return props.$isLandscape ? 'height: 100%;' : 'width: 90%;';
8590
+ });
8612
8591
  var templateObject_1$y, templateObject_2$s, templateObject_3$j, templateObject_4$d, templateObject_5$9, templateObject_6$6, templateObject_7$4, templateObject_8$2, templateObject_9$2;
8613
8592
 
8614
8593
  var IdCaptureFitGuide = function IdCaptureFitGuide(_a) {
@@ -15741,7 +15720,8 @@ var defaultTheme = {
15741
15720
  borderWidth: 4,
15742
15721
  desktopPadding: 50,
15743
15722
  mobilePadding: 0,
15744
- imagePadding: '0 50px',
15723
+ imagePadding: 50,
15724
+ mobileImagePadding: 0,
15745
15725
  wavesDisabled: false,
15746
15726
  wavesColor: '#287ec6',
15747
15727
  progressBarColor: 'white',