youverify-liveness-web 1.0.7 → 1.0.8
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 +716 -713
- package/dist/index.umd.cjs +2 -2
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
(function(){"use strict";try{if(typeof document<"u"){var t=document.createElement("style");t.appendChild(document.createTextNode('@import"https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,100..1000;1,9..40,100..1000&display=swap";*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }.yvlw-absolute{position:absolute}.yvlw-m-0{margin:0}.yvlw-mx-auto{margin-left:auto;margin-right:auto}.yvlw-mb-12{margin-bottom:3rem}.yvlw-mt-12{margin-top:3rem}.yvlw-mt-3{margin-top:.75rem}.yvlw-flex{display:flex}.yvlw-hidden{display:none}.yvlw-h-10{height:2.5rem}.yvlw-h-20{height:5rem}.yvlw-h-4{height:1rem}.yvlw-h-5{height:1.25rem}.yvlw-h-6{height:1.5rem}.yvlw-h-7{height:1.75rem}.yvlw-h-full{height:100%}.yvlw-w-10{width:2.5rem}.yvlw-w-4{width:1rem}.yvlw-w-5{width:1.25rem}.yvlw-w-7{width:1.75rem}.yvlw-w-full{width:100%}.yvlw-flex-1{flex:1 1 0%}.yvlw--translate-x-full{--tw-translate-x: -100%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.yvlw--translate-y-full{--tw-translate-y: -100%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.yvlw-translate-x-0{--tw-translate-x: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.yvlw-translate-x-full{--tw-translate-x: 100%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.yvlw-translate-y-0{--tw-translate-y: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.yvlw-translate-y-full{--tw-translate-y: 100%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.yvlw-scale-100{--tw-scale-x: 1;--tw-scale-y: 1;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.yvlw-scale-125{--tw-scale-x: 1.25;--tw-scale-y: 1.25;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.yvlw-scale-75{--tw-scale-x: .75;--tw-scale-y: .75;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.yvlw-transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.yvlw-flex-col{flex-direction:column}.yvlw-items-center{align-items:center}.yvlw-justify-center{justify-content:center}.yvlw-gap-1{gap:.25rem}.yvlw-space-x-1>:not([hidden])~:not([hidden]){--tw-space-x-reverse: 0;margin-right:calc(.25rem * var(--tw-space-x-reverse));margin-left:calc(.25rem * calc(1 - var(--tw-space-x-reverse)))}.yvlw-space-x-3>:not([hidden])~:not([hidden]){--tw-space-x-reverse: 0;margin-right:calc(.75rem * var(--tw-space-x-reverse));margin-left:calc(.75rem * calc(1 - var(--tw-space-x-reverse)))}.yvlw-rounded{border-radius:.25rem}.yvlw-border{border-width:1px}.yvlw-border-t{border-top-width:1px}.yvlw-border-gray-200{--tw-border-opacity: 1;border-color:rgb(229 231 235 / var(--tw-border-opacity))}.yvlw-border-gray-300{--tw-border-opacity: 1;border-color:rgb(209 213 219 / var(--tw-border-opacity))}.yvlw-bg-black\\/20{background-color:#0003}.yvlw-p-0{padding:0}.yvlw-px-3{padding-left:.75rem;padding-right:.75rem}.yvlw-px-4{padding-left:1rem;padding-right:1rem}.yvlw-py-2{padding-top:.5rem;padding-bottom:.5rem}.yvlw-pb-6{padding-bottom:1.5rem}.yvlw-pt-4{padding-top:1rem}.yvlw-text-center{text-align:center}.yvlw-text-sm{font-size:.875rem;line-height:1.25rem}.yvlw-text-xs{font-size:.75rem;line-height:1rem}.yvlw-text-white{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity))}.yvlw-opacity-0{opacity:0}.yvlw-opacity-100{opacity:1}.yvlw-transition{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,-webkit-backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter,-webkit-backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.yvlw-duration-200{transition-duration:.2s}.yvlw-duration-300{transition-duration:.3s}.yvlw-ease-in{transition-timing-function:cubic-bezier(.4,0,1,1)}.subtext{--tw-text-opacity: 1;color:rgb(100 116 139 / var(--tw-text-opacity))}.subtext:where([liveness-web-sdk-color-scheme=dark],[liveness-web-sdk-color-scheme=dark] *){--tw-text-opacity: 1;color:rgb(148 163 184 / var(--tw-text-opacity))}.divider{--tw-border-opacity: 1;border-color:rgb(229 231 235 / var(--tw-border-opacity))}.divider:where([liveness-web-sdk-color-scheme=dark],[liveness-web-sdk-color-scheme=dark] *){--tw-border-opacity: 1;border-color:rgb(31 41 55 / var(--tw-border-opacity))}.dark\\:yvlw-block:where([liveness-web-sdk-color-scheme=dark],[liveness-web-sdk-color-scheme=dark] *){display:block}.dark\\:yvlw-hidden:where([liveness-web-sdk-color-scheme=dark],[liveness-web-sdk-color-scheme=dark] *){display:none}.dark\\:yvlw-border-gray-700:where([liveness-web-sdk-color-scheme=dark],[liveness-web-sdk-color-scheme=dark] *){--tw-border-opacity: 1;border-color:rgb(55 65 81 / var(--tw-border-opacity))}.dark\\:yvlw-border-gray-800:where([liveness-web-sdk-color-scheme=dark],[liveness-web-sdk-color-scheme=dark] *){--tw-border-opacity: 1;border-color:rgb(31 41 55 / var(--tw-border-opacity))}._root_1duny_1{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-family:DM Sans,sans-serif;position:fixed;top:0;right:0;bottom:0;left:0;z-index:50;display:flex;min-height:100vh;min-height:-webkit-fill-available;align-items:center;justify-content:center;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,-webkit-backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter;transition-property:color,background-color,border-color,text-decoration-color,fill,stroke,opacity,box-shadow,transform,filter,backdrop-filter,-webkit-backdrop-filter;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.3s;transition-timing-function:cubic-bezier(0,0,.2,1)}._root_1duny_1[data-closed]{opacity:0}._root_1duny_1._modal_1duny_10{background-color:#0000004d}@media (min-width: 768px){._root_1duny_1._modal_1duny_10{padding:1rem}._root_1duny_1._modal_1duny_10 ._container_1duny_13{border-radius:.75rem}}._root_1duny_1._modal_1duny_10 ._container_1duny_13{max-width:1500px;max-height:700px}@media (min-width: 768px){._root_1duny_1._page_1duny_18{padding:0}}._root_1duny_1 ._close_1duny_21{position:absolute;top:.5rem;left:.5rem;display:flex;align-items:center;justify-content:center;z-index:20;height:1.5rem;width:1.5rem;border-radius:9999px;background-color:#00000080}._root_1duny_1 ._close_1duny_21 svg{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}._root_1duny_1 ._close_1duny_21 svg:hover{--tw-rotate: 90deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}._root_1duny_1 ._container_1duny_13{height:100%;width:100%;--tw-bg-opacity: 1;background-color:rgb(255 255 255 / var(--tw-bg-opacity));--tw-text-opacity: 1;color:rgb(55 65 81 / var(--tw-text-opacity))}._root_1duny_1 ._container_1duny_13:where([liveness-web-sdk-color-scheme=dark],[liveness-web-sdk-color-scheme=dark] *){--tw-bg-opacity: 1;background-color:rgb(0 0 0 / var(--tw-bg-opacity));--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity))}._root_1h6qm_1 *,._root_1h6qm_1 :before,._root_1h6qm_1 :after{box-sizing:border-box;border-width:0;border-style:solid}._root_1h6qm_1 :before,._root_1h6qm_1 :after{--tw-content: ""}._root_1h6qm_1 html,._root_1h6qm_1 :host{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";-webkit-tap-highlight-color:transparent}._root_1h6qm_1 body{margin:0;line-height:inherit}._root_1h6qm_1 hr{height:0;color:inherit;border-top-width:1px}._root_1h6qm_1 abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}._root_1h6qm_1 h1,._root_1h6qm_1 h2,._root_1h6qm_1 h3,._root_1h6qm_1 h4,._root_1h6qm_1 h5,._root_1h6qm_1 h6{font-size:inherit;font-weight:inherit}._root_1h6qm_1 a{color:inherit;text-decoration:inherit}._root_1h6qm_1 b,._root_1h6qm_1 strong{font-weight:bolder}._root_1h6qm_1 code,._root_1h6qm_1 kbd,._root_1h6qm_1 samp,._root_1h6qm_1 pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-size:1em}._root_1h6qm_1 small{font-size:80%}._root_1h6qm_1 sub,._root_1h6qm_1 sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}._root_1h6qm_1 sub{bottom:-.25em}._root_1h6qm_1 sup{top:-.5em}._root_1h6qm_1 table{text-indent:0;border-color:inherit;border-collapse:collapse}._root_1h6qm_1 button,._root_1h6qm_1 input,._root_1h6qm_1 optgroup,._root_1h6qm_1 select,._root_1h6qm_1 textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;letter-spacing:inherit;color:inherit;margin:0;padding:0}._root_1h6qm_1 button,._root_1h6qm_1 select{text-transform:none}._root_1h6qm_1 button,._root_1h6qm_1 input:where([type=button]),._root_1h6qm_1 input:where([type=reset]),._root_1h6qm_1 input:where([type=submit]){-moz-appearance:button;appearance:button;-webkit-appearance:button;background-color:transparent;background-image:none}._root_1h6qm_1 :-moz-focusring{outline:auto}._root_1h6qm_1 :-moz-ui-invalid{box-shadow:none}._root_1h6qm_1 progress{vertical-align:baseline}._root_1h6qm_1 ::-webkit-inner-spin-button,._root_1h6qm_1 ::-webkit-outer-spin-button{height:auto}._root_1h6qm_1 [type=search]{-moz-appearance:textfield;appearance:textfield;-webkit-appearance:textfield;outline-offset:-2px}._root_1h6qm_1 ::-webkit-search-decoration{-webkit-appearance:none}._root_1h6qm_1 ::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}._root_1h6qm_1 summary{display:list-item}._root_1h6qm_1 blockquote,._root_1h6qm_1 dl,._root_1h6qm_1 dd,._root_1h6qm_1 h1,._root_1h6qm_1 h2,._root_1h6qm_1 h3,._root_1h6qm_1 h4,._root_1h6qm_1 h5,._root_1h6qm_1 h6,._root_1h6qm_1 hr,._root_1h6qm_1 figure,._root_1h6qm_1 p,._root_1h6qm_1 pre{margin:0}._root_1h6qm_1 fieldset{margin:0;padding:0}._root_1h6qm_1 legend{padding:0}._root_1h6qm_1 ol,._root_1h6qm_1 ul,._root_1h6qm_1 menu{list-style:none;margin:0;padding:0}._root_1h6qm_1 dialog{padding:0}._root_1h6qm_1 textarea{resize:vertical}._root_1h6qm_1 input::-moz-placeholder,._root_1h6qm_1 textarea::-moz-placeholder{opacity:1;color:#9ca3af}._root_1h6qm_1 input::placeholder,._root_1h6qm_1 textarea::placeholder{opacity:1;color:#9ca3af}._root_1h6qm_1 button,._root_1h6qm_1 [role=button]{cursor:pointer}._root_1h6qm_1 :disabled{cursor:default}._root_1h6qm_1 img,._root_1h6qm_1 svg,._root_1h6qm_1 video,._root_1h6qm_1 canvas,._root_1h6qm_1 audio,._root_1h6qm_1 iframe,._root_1h6qm_1 embed,._root_1h6qm_1 object{display:block}._root_1h6qm_1 [hidden]{display:none}._root_vqy7d_1{height:100%}._root_vqy7d_1 ._container_vqy7d_4{display:flex;height:100%}._root_vqy7d_1 ._container_vqy7d_4 ._lhs_vqy7d_7{display:none;width:20%;flex-direction:column;justify-content:space-between}@media (min-width: 1280px){._root_vqy7d_1 ._container_vqy7d_4 ._lhs_vqy7d_7{display:flex}}._root_vqy7d_1 ._container_vqy7d_4 ._lhs_vqy7d_7{padding-top:.75rem;padding-bottom:.75rem}._root_vqy7d_1 ._container_vqy7d_4 ._lhs_vqy7d_7 ._info_vqy7d_11>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(2rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(2rem * var(--tw-space-y-reverse))}._root_vqy7d_1 ._container_vqy7d_4 ._lhs_vqy7d_7 ._info_vqy7d_11{padding-left:1.5rem;padding-right:1.5rem}._root_vqy7d_1 ._container_vqy7d_4 ._lhs_vqy7d_7 ._info_vqy7d_11 ol{position:relative;margin:0;list-style-type:none;padding:0}._root_vqy7d_1 ._container_vqy7d_4 ._lhs_vqy7d_7 ._info_vqy7d_11 ol li{counter-increment:item;margin-bottom:24px;position:relative;font-size:.875rem;line-height:1.25rem;display:flex;align-items:center}._root_vqy7d_1 ._container_vqy7d_4 ._lhs_vqy7d_7 ._info_vqy7d_11 ol li:before{width:28px;height:28px;border-radius:9999px;border-width:2px;--tw-border-opacity: 1;border-color:rgb(107 114 128 / var(--tw-border-opacity));--tw-bg-opacity: 1;background-color:rgb(75 85 99 / var(--tw-bg-opacity))}._root_vqy7d_1 ._container_vqy7d_4 ._lhs_vqy7d_7 ._info_vqy7d_11 ol li:where([liveness-web-sdk-color-scheme=dark],[liveness-web-sdk-color-scheme=dark] *):before{--tw-border-opacity: 1;border-color:rgb(55 65 81 / var(--tw-border-opacity));--tw-bg-opacity: 1;background-color:rgb(31 41 55 / var(--tw-bg-opacity))}._root_vqy7d_1 ._container_vqy7d_4 ._lhs_vqy7d_7 ._info_vqy7d_11 ol li:before{margin-right:1rem;display:flex;align-items:center;justify-content:center;font-size:.75rem;line-height:1rem;--tw-text-opacity: 1;color:rgb(209 213 219 / var(--tw-text-opacity))}._root_vqy7d_1 ._container_vqy7d_4 ._lhs_vqy7d_7 ._info_vqy7d_11 ol li:where([liveness-web-sdk-color-scheme=dark],[liveness-web-sdk-color-scheme=dark] *):before{--tw-text-opacity: 1;color:rgb(156 163 175 / var(--tw-text-opacity))}._root_vqy7d_1 ._container_vqy7d_4 ._lhs_vqy7d_7 ._info_vqy7d_11 ol li:before{content:counter(item);flex-shrink:0}._root_vqy7d_1 ._container_vqy7d_4 ._lhs_vqy7d_7 ._info_vqy7d_11 ol li._active_vqy7d_32{font-weight:500}._root_vqy7d_1 ._container_vqy7d_4 ._lhs_vqy7d_7 ._info_vqy7d_11 ol li._active_vqy7d_32:where([liveness-web-sdk-color-scheme=dark],[liveness-web-sdk-color-scheme=dark] *){--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity))}._root_vqy7d_1 ._container_vqy7d_4 ._lhs_vqy7d_7 ._info_vqy7d_11 ol li._active_vqy7d_32:before{background-color:var(--branding-color);border-style:none;--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity))}._root_vqy7d_1 ._container_vqy7d_4 ._lhs_vqy7d_7 ._info_vqy7d_11 ol li._completed_vqy7d_39{font-weight:500;text-decoration-line:line-through}._root_vqy7d_1 ._container_vqy7d_4 ._lhs_vqy7d_7 ._info_vqy7d_11 ol li._completed_vqy7d_39:where([liveness-web-sdk-color-scheme=dark],[liveness-web-sdk-color-scheme=dark] *){--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity))}._root_vqy7d_1 ._container_vqy7d_4 ._lhs_vqy7d_7 ._info_vqy7d_11 ol li._completed_vqy7d_39:before{background-color:var(--branding-color);border-style:none;--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity))}._root_vqy7d_1 ._container_vqy7d_4 ._lhs_vqy7d_7 ._info_vqy7d_11 ol li:after{--tw-bg-opacity: 1;background-color:rgb(229 231 235 / var(--tw-bg-opacity))}._root_vqy7d_1 ._container_vqy7d_4 ._lhs_vqy7d_7 ._info_vqy7d_11 ol li:where([liveness-web-sdk-color-scheme=dark],[liveness-web-sdk-color-scheme=dark] *):after{--tw-bg-opacity: 1;background-color:rgb(31 41 55 / var(--tw-bg-opacity))}._root_vqy7d_1 ._container_vqy7d_4 ._lhs_vqy7d_7 ._info_vqy7d_11 ol li:after{top:28px;bottom:-24px;left:14px;content:"";position:absolute;width:1px}._root_vqy7d_1 ._container_vqy7d_4 ._lhs_vqy7d_7 ._info_vqy7d_11 ol li:last-child:after{content:none}._root_vqy7d_1 ._container_vqy7d_4 ._lhs_vqy7d_7 footer{display:flex;align-items:center;justify-content:space-between;padding:.75rem 1.5rem}._root_vqy7d_1 ._container_vqy7d_4 ._rhs_vqy7d_62{display:none;width:20%}._root_vqy7d_1 ._container_vqy7d_4 ._rhs_vqy7d_62>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1rem * var(--tw-space-y-reverse))}._root_vqy7d_1 ._container_vqy7d_4 ._rhs_vqy7d_62{padding-top:.75rem;padding-bottom:.75rem}@media (min-width: 1280px){._root_vqy7d_1 ._container_vqy7d_4 ._rhs_vqy7d_62{display:block}}._root_vqy7d_1 ._container_vqy7d_4 ._rhs_vqy7d_62 ._profile_vqy7d_65{display:flex;align-items:center;gap:.5rem;padding:1rem 1.5rem}._root_vqy7d_1 ._container_vqy7d_4 ._rhs_vqy7d_62 ._profile_vqy7d_65 ._avatar_vqy7d_68{height:2.5rem;width:2.5rem;border-radius:9999px;--tw-bg-opacity: 1;background-color:rgb(209 213 219 / var(--tw-bg-opacity))}._root_vqy7d_1 ._container_vqy7d_4 ._rhs_vqy7d_62 ._profile_vqy7d_65 ._avatar_vqy7d_68:where([liveness-web-sdk-color-scheme=dark],[liveness-web-sdk-color-scheme=dark] *){--tw-bg-opacity: 1;background-color:rgb(107 114 128 / var(--tw-bg-opacity))}._root_vqy7d_1 ._container_vqy7d_4 ._rhs_vqy7d_62 ._profile_vqy7d_65 ._avatar_vqy7d_68{display:flex;align-items:center;justify-content:center;font-size:1.125rem;line-height:1.75rem;font-weight:500}._root_vqy7d_1 ._container_vqy7d_4 ._rhs_vqy7d_62 ._profile_vqy7d_65 h4{margin-bottom:-.25rem;text-overflow:ellipsis;font-weight:600;--tw-text-opacity: 1;color:rgb(75 85 99 / var(--tw-text-opacity))}._root_vqy7d_1 ._container_vqy7d_4 ._rhs_vqy7d_62 ._profile_vqy7d_65 h4:where([liveness-web-sdk-color-scheme=dark],[liveness-web-sdk-color-scheme=dark] *){--tw-text-opacity: 1;color:rgb(243 244 246 / var(--tw-text-opacity))}._root_vqy7d_1 ._container_vqy7d_4 ._rhs_vqy7d_62 ._profile_vqy7d_65 p{margin-top:0;margin-bottom:0;font-size:.75rem;line-height:1rem}._root_vqy7d_1 ._container_vqy7d_4 ._rhs_vqy7d_62 footer>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.25rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.25rem * var(--tw-space-y-reverse))}._root_vqy7d_1 ._container_vqy7d_4 ._rhs_vqy7d_62 footer{padding-left:1.5rem;padding-right:1.5rem;font-size:.75rem;line-height:1rem;--tw-text-opacity: 1;color:rgb(107 114 128 / var(--tw-text-opacity))}._root_vqy7d_1 ._container_vqy7d_4 ._main_vqy7d_81{flex:1 1 0%}@media (min-width: 768px){._root_vqy7d_1 ._container_vqy7d_4 ._main_vqy7d_81{padding-top:1rem;padding-bottom:1rem}}._root_vqy7d_1 ._container_vqy7d_4 ._main_vqy7d_81 ._content_vqy7d_84{margin-left:auto;margin-right:auto;height:100%;width:100%;overflow:hidden;border-radius:1rem;border-width:1px;--tw-border-opacity: 1;border-color:rgb(229 231 235 / var(--tw-border-opacity))}._root_vqy7d_1 ._container_vqy7d_4 ._main_vqy7d_81 ._content_vqy7d_84:where([liveness-web-sdk-color-scheme=dark],[liveness-web-sdk-color-scheme=dark] *){--tw-border-opacity: 1;border-color:rgb(31 41 55 / var(--tw-border-opacity))}._root_vqy7d_1 ._container_vqy7d_4 ._main_vqy7d_81 ._content_vqy7d_84{max-width:500px}._root_vqy7d_1 ._container_vqy7d_4 ._main_vqy7d_81 ._completed_vqy7d_39{display:flex;height:100%;width:100%;align-items:center;justify-content:center}._root_lryhb_1 ._container_lryhb_1{display:flex;align-items:center;justify-content:space-between}._root_lryhb_1 ._container_lryhb_1 ._brand_lryhb_6{display:flex;align-items:center;gap:7px;font-weight:600}._root_bcsvc_1{position:relative;height:100%;width:100%}._root_bcsvc_1 video{height:100%;width:100%;-o-object-fit:cover;object-fit:cover;transform:scaleX(-1)}._container_mcmsr_1{position:absolute;top:0;right:0;bottom:0;left:0;display:flex;align-items:center;justify-content:center;background-image:radial-gradient(circle at 50% 50%,transparent 1400px,rgba(255,255,255,0) 100%)}._container_mcmsr_1:where([liveness-web-sdk-color-scheme=dark],[liveness-web-sdk-color-scheme=dark] *){background-image:radial-gradient(circle at 50% 50%,transparent 1400px,rgba(0,0,0,0) 100%)}._container_mcmsr_1{z-index:1}._container_mcmsr_1:before{content:"";position:absolute;top:0;right:0;bottom:0;left:0;opacity:0;background-image:radial-gradient(circle at 50% 50%,transparent 140px,rgba(255,255,255,.5) 101px)}._container_mcmsr_1:where([liveness-web-sdk-color-scheme=dark],[liveness-web-sdk-color-scheme=dark] *):before{background-image:radial-gradient(circle at 50% 50%,transparent 140px,rgba(0,0,0,.8) 101px)}._container_mcmsr_1:before{transition:opacity .3s linear}._container_mcmsr_1._focused_mcmsr_12:before{opacity:1}._container_mcmsr_1 ._progress_mcmsr_15{position:relative;height:280px;width:280px;border-radius:50%;display:flex;align-items:center;justify-content:center;border:1px solid gray}._container_mcmsr_1 ._progress_mcmsr_15 div{position:absolute;height:3px;transform-origin:50%;border-radius:2px;width:5px;background-color:gray;transition-property:background-color,transform,width;transition-duration:.3s;transition-timing-function:ease-in-out}._container_mcmsr_1 ._progress_mcmsr_15 div._completed_mcmsr_36{width:20px;background-color:#07da63}._container_mcmsr_1 ._marker_mcmsr_40{position:relative;width:280px;height:280px}._container_mcmsr_1 ._marker_mcmsr_40>div{position:absolute;height:1.75rem;width:1.75rem;border-width:2px;--tw-border-opacity: 1;border-color:rgb(255 255 255 / var(--tw-border-opacity))}._container_mcmsr_1 ._marker_mcmsr_40>div:first-child{top:-.25rem;left:-.25rem;border-top-left-radius:50%;border-bottom-width:0px;border-right-width:0px}._container_mcmsr_1 ._marker_mcmsr_40>div:nth-child(2){top:-.25rem;right:-.25rem;border-top-right-radius:50%;border-bottom-width:0px;border-left-width:0px}._container_mcmsr_1 ._marker_mcmsr_40>div:nth-child(3){bottom:-.25rem;left:-.25rem;border-bottom-left-radius:50%;border-top-width:0px;border-right-width:0px}._container_mcmsr_1 ._marker_mcmsr_40>div:last-child{bottom:-.25rem;right:-.25rem;border-bottom-right-radius:50%;border-top-width:0px;border-left-width:0px}._root_5hgaj_1{height:100%;text-align:center}._root_5hgaj_1 ._container_5hgaj_4{position:relative;height:100%}._root_5hgaj_1 ._container_5hgaj_4 ._progress_5hgaj_7{background-color:var(--branding-color);position:absolute;top:0;left:0;height:4px;border-radius:.5rem;z-index:2}._root_5hgaj_1 ._container_5hgaj_4 ._intro_5hgaj_12{display:flex;height:100%;flex-direction:column;align-items:center;justify-content:center;padding:1.5rem 1rem}._root_5hgaj_1 ._container_5hgaj_4 ._content_5hgaj_15{height:70%;width:100%}._root_5hgaj_1 ._container_5hgaj_4 ._branding_5hgaj_18{position:absolute;left:0;right:0;bottom:1.5rem;text-align:center;font-size:.75rem;line-height:1rem;font-weight:500;display:flex;align-items:center;justify-content:center}._root_5hgaj_1 ._container_5hgaj_4 ._branding_5hgaj_18>:not([hidden])~:not([hidden]){--tw-space-x-reverse: 0;margin-right:calc(.25rem * var(--tw-space-x-reverse));margin-left:calc(.25rem * calc(1 - var(--tw-space-x-reverse)))}._root_5hgaj_1 ._container_5hgaj_4 ._instructionsContainer_5hgaj_22{border-top-width:1px;--tw-border-opacity: 1;border-color:rgb(229 231 235 / var(--tw-border-opacity))}._root_5hgaj_1 ._container_5hgaj_4 ._instructionsContainer_5hgaj_22:where([liveness-web-sdk-color-scheme=dark],[liveness-web-sdk-color-scheme=dark] *){--tw-border-opacity: 1;border-color:rgb(31 41 55 / var(--tw-border-opacity))}._root_5hgaj_1 ._container_5hgaj_4 ._instructions_5hgaj_22{margin-left:auto;margin-right:auto;padding:1rem 1rem 1.5rem;text-align:center;max-width:400px}._root_5hgaj_1 ._container_5hgaj_4 h2{margin-top:.5rem;margin-bottom:.5rem;font-size:1.5rem;line-height:2rem;font-weight:900}._root_5hgaj_1 ._container_5hgaj_4 h2:where([liveness-web-sdk-color-scheme=dark],[liveness-web-sdk-color-scheme=dark] *){--tw-text-opacity: 1;color:rgb(248 250 252 / var(--tw-text-opacity))}._root_5hgaj_1 ._container_5hgaj_4 p{font-size:.875rem;line-height:1.25rem;font-weight:300;max-width:400px}._root_5hgaj_1 ._container_5hgaj_4 button{color:var(--branding-color);border-color:var(--branding-color);border-radius:9999px;border-width:2px;padding:.5rem 2rem;font-weight:500}._root_5hgaj_1 ._container_5hgaj_4 button:hover{background-color:var(--branding-color);--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity))}._root_h5elg_1{text-align:center;display:flex;height:100%;flex-direction:column;align-items:center;justify-content:center;padding:1.5rem .75rem}._root_h5elg_1 h2{margin-top:.5rem;margin-bottom:.5rem;font-size:1.5rem;line-height:2rem;font-weight:900}._root_h5elg_1 h2:where([liveness-web-sdk-color-scheme=dark],[liveness-web-sdk-color-scheme=dark] *){--tw-text-opacity: 1;color:rgb(248 250 252 / var(--tw-text-opacity))}._root_h5elg_1 p{font-size:.875rem;line-height:1.25rem;font-weight:300;max-width:400px}._root_h5elg_1 button{color:var(--branding-color);border-color:var(--branding-color);border-radius:9999px;border-width:2px;padding:.5rem 2rem;font-weight:500}._root_h5elg_1 button:hover{background-color:var(--branding-color);--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity))}._root_h5elg_1 button:hover ._spinner_h5elg_22{--tw-border-opacity: 1;border-color:rgb(255 255 255 / var(--tw-border-opacity));border-left-color:transparent}._container_1vep2_1{height:100%;width:100%;border-radius:50%;border-width:2px;border-color:var(--branding-color);border-left-color:transparent;animation:_spin_1vep2_1 .7s linear infinite}._container_1vep2_1._md_1vep2_7{height:1rem;width:1rem}._container_1vep2_1._lg_1vep2_10{height:1.75rem;width:1.75rem}@keyframes _spin_1vep2_1{0%{transform:rotate(0)}to{transform:rotate(360deg)}}._root_thujo_1{position:absolute;top:0;right:0;bottom:0;left:0}._root_thujo_1 ._sticker_thujo_4{position:absolute}._root_thujo_1 ._sticker_thujo_4._no_thujo_7{top:2.5rem;left:1.5rem;border-width:4px;--tw-border-opacity: 1;border-color:rgb(248 113 113 / var(--tw-border-opacity));padding:.5rem 1rem;--tw-drop-shadow: drop-shadow(0 1px 1px rgb(0 0 0 / .05));filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow);stroke:#fff;font-size:2.25rem;line-height:2.5rem;font-weight:900;letter-spacing:.1em;--tw-text-opacity: 1;color:rgb(248 113 113 / var(--tw-text-opacity));transform:rotate(335deg)}._root_thujo_1 ._sticker_thujo_4._yes_thujo_12{top:2.5rem;right:1.5rem;border-width:4px;--tw-border-opacity: 1;border-color:rgb(74 222 128 / var(--tw-border-opacity));padding:.5rem 1rem;--tw-drop-shadow: drop-shadow(0 1px 1px rgb(0 0 0 / .05));filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow);stroke:#fff;font-size:2.25rem;line-height:2.5rem;font-weight:900;letter-spacing:.1em;--tw-text-opacity: 1;color:rgb(74 222 128 / var(--tw-text-opacity));transform:rotate(45deg)}._container_1ej18_1{position:absolute;top:0;right:0;bottom:0;left:0;display:flex;align-items:center;justify-content:center;background-image:radial-gradient(circle at 50% 50%,transparent 1400px,rgba(255,255,255,0) 100%)}._container_1ej18_1:where([liveness-web-sdk-color-scheme=dark],[liveness-web-sdk-color-scheme=dark] *){background-image:radial-gradient(circle at 50% 50%,transparent 1400px,rgba(0,0,0,0) 100%)}._container_1ej18_1{z-index:1}._container_1ej18_1:before{content:"";position:absolute;top:0;right:0;bottom:0;left:0;opacity:0;background-image:radial-gradient(circle at 50% 50%,transparent 140px,rgba(255,255,255,.5) 101px)}._container_1ej18_1:where([liveness-web-sdk-color-scheme=dark],[liveness-web-sdk-color-scheme=dark] *):before{background-image:radial-gradient(circle at 50% 50%,transparent 140px,rgba(0,0,0,.8) 101px)}._container_1ej18_1:before{transition:opacity .3s linear}._container_1ej18_1 ._progress_1ej18_12{position:relative;height:240px;width:240px;border-radius:50%;display:flex;align-items:center;justify-content:center;border:1px solid gray}._container_1ej18_1 ._progress_1ej18_12 div{position:absolute;height:3px;transform-origin:50%;border-radius:2px;width:5px;background-color:gray;transition-property:background-color,transform,width;transition-duration:.3s;transition-timing-function:ease-in-out}._container_1ej18_1 ._progress_1ej18_12 div._completed_1ej18_33{width:20px;background-color:#07da63}._container_1ej18_1 ._marker_1ej18_37{position:relative;width:240px;height:240px}._container_1ej18_1 ._marker_1ej18_37>div{position:absolute;height:1.75rem;width:1.75rem;border-width:4px;--tw-border-opacity: 1;border-color:rgb(255 255 255 / var(--tw-border-opacity))}._container_1ej18_1 ._marker_1ej18_37>div:first-child{top:-.25rem;left:-.25rem;border-top-left-radius:50%;border-bottom-width:0px;border-right-width:0px}._container_1ej18_1 ._marker_1ej18_37>div:nth-child(2){top:-.25rem;right:-.25rem;border-top-right-radius:50%;border-bottom-width:0px;border-left-width:0px}._container_1ej18_1 ._marker_1ej18_37>div:nth-child(3){bottom:-.25rem;left:-.25rem;border-bottom-left-radius:50%;border-top-width:0px;border-right-width:0px}._container_1ej18_1 ._marker_1ej18_37>div:last-child{bottom:-.25rem;right:-.25rem;border-bottom-right-radius:50%;border-top-width:0px;border-left-width:0px}')),document.head.appendChild(t)}}catch(r){console.error("vite-plugin-css-injected-by-js",r)}})();
|
|
2
|
-
var ot,
|
|
3
|
-
function
|
|
2
|
+
var ot, H, xr, xe, On, Mr, Xt, mn, Zt, Jt, Pr, rt = {}, Nr = [], Ko = /acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i, Tt = Array.isArray;
|
|
3
|
+
function ve(e, t) {
|
|
4
4
|
for (var n in t) e[n] = t[n];
|
|
5
5
|
return e;
|
|
6
6
|
}
|
|
@@ -16,12 +16,12 @@ function de(e, t, n) {
|
|
|
16
16
|
}
|
|
17
17
|
function Je(e, t, n, r, o) {
|
|
18
18
|
var i = { type: e, props: t, key: n, ref: r, __k: null, __: null, __b: 0, __e: null, __d: void 0, __c: null, constructor: void 0, __v: o ?? ++xr, __i: -1, __u: 0 };
|
|
19
|
-
return o == null &&
|
|
19
|
+
return o == null && H.vnode != null && H.vnode(i), i;
|
|
20
20
|
}
|
|
21
|
-
function
|
|
21
|
+
function vn() {
|
|
22
22
|
return { current: null };
|
|
23
23
|
}
|
|
24
|
-
function
|
|
24
|
+
function G(e) {
|
|
25
25
|
return e.children;
|
|
26
26
|
}
|
|
27
27
|
function ue(e, t) {
|
|
@@ -43,21 +43,21 @@ function Ar(e) {
|
|
|
43
43
|
}
|
|
44
44
|
}
|
|
45
45
|
function Qt(e) {
|
|
46
|
-
(!e.__d && (e.__d = !0) && xe.push(e) && !_t.__r++ || On !==
|
|
46
|
+
(!e.__d && (e.__d = !0) && xe.push(e) && !_t.__r++ || On !== H.debounceRendering) && ((On = H.debounceRendering) || Mr)(_t);
|
|
47
47
|
}
|
|
48
48
|
function _t() {
|
|
49
49
|
var e, t, n, r, o, i, s, a;
|
|
50
|
-
for (xe.sort(Xt); e = xe.shift(); ) e.__d && (t = xe.length, r = void 0, i = (o = (n = e).__v).__e, s = [], a = [], n.__P && ((r =
|
|
50
|
+
for (xe.sort(Xt); e = xe.shift(); ) e.__d && (t = xe.length, r = void 0, i = (o = (n = e).__v).__e, s = [], a = [], n.__P && ((r = ve({}, o)).__v = o.__v + 1, H.vnode && H.vnode(r), _n(n.__P, r, o, n.__n, n.__P.namespaceURI, 32 & o.__u ? [i] : null, s, i ?? Ae(o), !!(32 & o.__u), a), r.__v = o.__v, r.__.__k[r.__i] = r, Dr(s, r, a), r.__e != i && Ar(r)), xe.length > t && xe.sort(Xt));
|
|
51
51
|
_t.__r = 0;
|
|
52
52
|
}
|
|
53
53
|
function Rr(e, t, n, r, o, i, s, a, l, u, d) {
|
|
54
|
-
var c, f, p, _, y,
|
|
55
|
-
for (n.__d = l, Xo(n, t,
|
|
54
|
+
var c, f, p, _, y, v = r && r.__k || Nr, m = t.length;
|
|
55
|
+
for (n.__d = l, Xo(n, t, v), l = n.__d, c = 0; c < m; c++) (p = n.__k[c]) != null && typeof p != "boolean" && typeof p != "function" && (f = p.__i === -1 ? rt : v[p.__i] || rt, p.__i = c, _n(e, p, f, o, i, s, a, l, u, d), _ = p.__e, p.ref && f.ref != p.ref && (f.ref && yn(f.ref, null, p), d.push(p.ref, p.__c || _, p)), y == null && _ != null && (y = _), 65536 & p.__u || f.__k === p.__k ? l = Ir(p, l, e) : typeof p.type == "function" && p.__d !== void 0 ? l = p.__d : _ && (l = _.nextSibling), p.__d = void 0, p.__u &= -196609);
|
|
56
56
|
n.__d = l, n.__e = y;
|
|
57
57
|
}
|
|
58
58
|
function Xo(e, t, n) {
|
|
59
59
|
var r, o, i, s, a, l = t.length, u = n.length, d = u, c = 0;
|
|
60
|
-
for (e.__k = [], r = 0; r < l; r++) s = r + c, (o = e.__k[r] = (o = t[r]) == null || typeof o == "boolean" || typeof o == "function" ? null : typeof o == "string" || typeof o == "number" || typeof o == "bigint" || o.constructor == String ? Je(null, o, null, null, null) : Tt(o) ? Je(
|
|
60
|
+
for (e.__k = [], r = 0; r < l; r++) s = r + c, (o = e.__k[r] = (o = t[r]) == null || typeof o == "boolean" || typeof o == "function" ? null : typeof o == "string" || typeof o == "number" || typeof o == "bigint" || o.constructor == String ? Je(null, o, null, null, null) : Tt(o) ? Je(G, { children: o }, null, null, null) : o.constructor === void 0 && o.__b > 0 ? Je(o.type, o.props, o.key, o.ref ? o.ref : null, o.__v) : o) != null ? (o.__ = e, o.__b = e.__b + 1, a = Zo(o, n, s, d), o.__i = a, i = null, a !== -1 && (d--, (i = n[a]) && (i.__u |= 131072)), i == null || i.__v === null ? (a == -1 && c--, typeof o.type != "function" && (o.__u |= 65536)) : a !== s && (a == s - 1 ? c = a - s : a == s + 1 ? c++ : a > s ? d > l - s ? c += a - s : c-- : a < s && c++, a !== r + c && (o.__u |= 65536))) : (i = n[s]) && i.key == null && i.__e && !(131072 & i.__u) && (i.__e == e.__d && (e.__d = Ae(i)), en(i, i, !1), n[s] = null, d--);
|
|
61
61
|
if (d) for (r = 0; r < u; r++) (i = n[r]) != null && !(131072 & i.__u) && (i.__e == e.__d && (e.__d = Ae(i)), en(i, i));
|
|
62
62
|
}
|
|
63
63
|
function Ir(e, t, n) {
|
|
@@ -102,7 +102,7 @@ function ft(e, t, n, r, o) {
|
|
|
102
102
|
if (typeof r == "string" && (e.style.cssText = r = ""), r) for (t in r) n && t in n || Hn(e.style, t, "");
|
|
103
103
|
if (n) for (t in n) r && n[t] === r[t] || Hn(e.style, t, n[t]);
|
|
104
104
|
}
|
|
105
|
-
else if (t[0] === "o" && t[1] === "n") i = t !== (t = t.replace(/(PointerCapture)$|Capture$/i, "$1")), t = t.toLowerCase() in e || t === "onFocusOut" || t === "onFocusIn" ? t.toLowerCase().slice(2) : t.slice(2), e.l || (e.l = {}), e.l[t + i] = n, n ? r ? n.u = r.u : (n.u =
|
|
105
|
+
else if (t[0] === "o" && t[1] === "n") i = t !== (t = t.replace(/(PointerCapture)$|Capture$/i, "$1")), t = t.toLowerCase() in e || t === "onFocusOut" || t === "onFocusIn" ? t.toLowerCase().slice(2) : t.slice(2), e.l || (e.l = {}), e.l[t + i] = n, n ? r ? n.u = r.u : (n.u = mn, e.addEventListener(t, i ? Jt : Zt, i)) : e.removeEventListener(t, i ? Jt : Zt, i);
|
|
106
106
|
else {
|
|
107
107
|
if (o == "http://www.w3.org/2000/svg") t = t.replace(/xlink(H|:h)/, "h").replace(/sName$/, "s");
|
|
108
108
|
else if (t != "width" && t != "height" && t != "href" && t != "list" && t != "form" && t != "tabIndex" && t != "download" && t != "rowSpan" && t != "colSpan" && t != "role" && t != "popover" && t in e) try {
|
|
@@ -117,62 +117,62 @@ function Wn(e) {
|
|
|
117
117
|
return function(t) {
|
|
118
118
|
if (this.l) {
|
|
119
119
|
var n = this.l[t.type + e];
|
|
120
|
-
if (t.t == null) t.t =
|
|
120
|
+
if (t.t == null) t.t = mn++;
|
|
121
121
|
else if (t.t < n.u) return;
|
|
122
|
-
return n(
|
|
122
|
+
return n(H.event ? H.event(t) : t);
|
|
123
123
|
}
|
|
124
124
|
};
|
|
125
125
|
}
|
|
126
126
|
function _n(e, t, n, r, o, i, s, a, l, u) {
|
|
127
|
-
var d, c, f, p, _, y,
|
|
127
|
+
var d, c, f, p, _, y, v, m, g, E, $, S, M, R, U, F, b = t.type;
|
|
128
128
|
if (t.constructor !== void 0) return null;
|
|
129
|
-
128 & n.__u && (l = !!(32 & n.__u), i = [a = t.__e = n.__e]), (d =
|
|
130
|
-
e: if (typeof
|
|
131
|
-
if (
|
|
129
|
+
128 & n.__u && (l = !!(32 & n.__u), i = [a = t.__e = n.__e]), (d = H.__b) && d(t);
|
|
130
|
+
e: if (typeof b == "function") try {
|
|
131
|
+
if (m = t.props, g = "prototype" in b && b.prototype.render, E = (d = b.contextType) && r[d.__c], $ = d ? E ? E.props.value : d.__ : r, n.__c ? v = (c = t.__c = n.__c).__ = c.__E : (g ? t.__c = c = new b(m, $) : (t.__c = c = new ue(m, $), c.constructor = b, c.render = Qo), E && E.sub(c), c.props = m, c.state || (c.state = {}), c.context = $, c.__n = r, f = c.__d = !0, c.__h = [], c._sb = []), g && c.__s == null && (c.__s = c.state), g && b.getDerivedStateFromProps != null && (c.__s == c.state && (c.__s = ve({}, c.__s)), ve(c.__s, b.getDerivedStateFromProps(m, c.__s))), p = c.props, _ = c.state, c.__v = t, f) g && b.getDerivedStateFromProps == null && c.componentWillMount != null && c.componentWillMount(), g && c.componentDidMount != null && c.__h.push(c.componentDidMount);
|
|
132
132
|
else {
|
|
133
|
-
if (g &&
|
|
134
|
-
for (t.__v !== n.__v && (c.props =
|
|
133
|
+
if (g && b.getDerivedStateFromProps == null && m !== p && c.componentWillReceiveProps != null && c.componentWillReceiveProps(m, $), !c.__e && (c.shouldComponentUpdate != null && c.shouldComponentUpdate(m, c.__s, $) === !1 || t.__v === n.__v)) {
|
|
134
|
+
for (t.__v !== n.__v && (c.props = m, c.state = c.__s, c.__d = !1), t.__e = n.__e, t.__k = n.__k, t.__k.forEach(function(I) {
|
|
135
135
|
I && (I.__ = t);
|
|
136
136
|
}), S = 0; S < c._sb.length; S++) c.__h.push(c._sb[S]);
|
|
137
137
|
c._sb = [], c.__h.length && s.push(c);
|
|
138
138
|
break e;
|
|
139
139
|
}
|
|
140
|
-
c.componentWillUpdate != null && c.componentWillUpdate(
|
|
140
|
+
c.componentWillUpdate != null && c.componentWillUpdate(m, c.__s, $), g && c.componentDidUpdate != null && c.__h.push(function() {
|
|
141
141
|
c.componentDidUpdate(p, _, y);
|
|
142
142
|
});
|
|
143
143
|
}
|
|
144
|
-
if (c.context =
|
|
145
|
-
for (c.state = c.__s, c.__d = !1, M && M(t), d = c.render(c.props, c.state, c.context),
|
|
144
|
+
if (c.context = $, c.props = m, c.__P = e, c.__e = !1, M = H.__r, R = 0, g) {
|
|
145
|
+
for (c.state = c.__s, c.__d = !1, M && M(t), d = c.render(c.props, c.state, c.context), U = 0; U < c._sb.length; U++) c.__h.push(c._sb[U]);
|
|
146
146
|
c._sb = [];
|
|
147
147
|
} else do
|
|
148
148
|
c.__d = !1, M && M(t), d = c.render(c.props, c.state, c.context), c.state = c.__s;
|
|
149
149
|
while (c.__d && ++R < 25);
|
|
150
|
-
c.state = c.__s, c.getChildContext != null && (r =
|
|
150
|
+
c.state = c.__s, c.getChildContext != null && (r = ve(ve({}, r), c.getChildContext())), g && !f && c.getSnapshotBeforeUpdate != null && (y = c.getSnapshotBeforeUpdate(p, _)), Rr(e, Tt(F = d != null && d.type === G && d.key == null ? d.props.children : d) ? F : [F], t, n, r, o, i, s, a, l, u), c.base = t.__e, t.__u &= -161, c.__h.length && s.push(c), v && (c.__E = c.__ = null);
|
|
151
151
|
} catch (I) {
|
|
152
152
|
if (t.__v = null, l || i != null) {
|
|
153
153
|
for (t.__u |= l ? 160 : 32; a && a.nodeType === 8 && a.nextSibling; ) a = a.nextSibling;
|
|
154
154
|
i[i.indexOf(a)] = null, t.__e = a;
|
|
155
155
|
} else t.__e = n.__e, t.__k = n.__k;
|
|
156
|
-
|
|
156
|
+
H.__e(I, t, n);
|
|
157
157
|
}
|
|
158
158
|
else i == null && t.__v === n.__v ? (t.__k = n.__k, t.__e = n.__e) : t.__e = Jo(n.__e, t, n, r, o, i, s, l, u);
|
|
159
|
-
(d =
|
|
159
|
+
(d = H.diffed) && d(t);
|
|
160
160
|
}
|
|
161
161
|
function Dr(e, t, n) {
|
|
162
162
|
t.__d = void 0;
|
|
163
163
|
for (var r = 0; r < n.length; r++) yn(n[r], n[++r], n[++r]);
|
|
164
|
-
|
|
164
|
+
H.__c && H.__c(t, e), e.some(function(o) {
|
|
165
165
|
try {
|
|
166
166
|
e = o.__h, o.__h = [], e.some(function(i) {
|
|
167
167
|
i.call(o);
|
|
168
168
|
});
|
|
169
169
|
} catch (i) {
|
|
170
|
-
|
|
170
|
+
H.__e(i, o.__v);
|
|
171
171
|
}
|
|
172
172
|
});
|
|
173
173
|
}
|
|
174
174
|
function Jo(e, t, n, r, o, i, s, a, l) {
|
|
175
|
-
var u, d, c, f, p, _, y,
|
|
175
|
+
var u, d, c, f, p, _, y, v = n.props, m = t.props, g = t.type;
|
|
176
176
|
if (g === "svg" ? o = "http://www.w3.org/2000/svg" : g === "math" ? o = "http://www.w3.org/1998/Math/MathML" : o || (o = "http://www.w3.org/1999/xhtml"), i != null) {
|
|
177
177
|
for (u = 0; u < i.length; u++) if ((p = i[u]) && "setAttribute" in p == !!g && (g ? p.localName === g : p.nodeType === 3)) {
|
|
178
178
|
e = p, i[u] = null;
|
|
@@ -180,23 +180,23 @@ function Jo(e, t, n, r, o, i, s, a, l) {
|
|
|
180
180
|
}
|
|
181
181
|
}
|
|
182
182
|
if (e == null) {
|
|
183
|
-
if (g === null) return document.createTextNode(
|
|
184
|
-
e = document.createElementNS(o, g,
|
|
183
|
+
if (g === null) return document.createTextNode(m);
|
|
184
|
+
e = document.createElementNS(o, g, m.is && m), i = null, a = !1;
|
|
185
185
|
}
|
|
186
|
-
if (g === null)
|
|
186
|
+
if (g === null) v === m || a && e.data === m || (e.data = m);
|
|
187
187
|
else {
|
|
188
|
-
if (i = i && ot.call(e.childNodes),
|
|
189
|
-
for (u in
|
|
188
|
+
if (i = i && ot.call(e.childNodes), v = n.props || rt, !a && i != null) for (v = {}, u = 0; u < e.attributes.length; u++) v[(p = e.attributes[u]).name] = p.value;
|
|
189
|
+
for (u in v) if (p = v[u], u != "children") {
|
|
190
190
|
if (u == "dangerouslySetInnerHTML") c = p;
|
|
191
|
-
else if (u !== "key" && !(u in
|
|
192
|
-
if (u == "value" && "defaultValue" in
|
|
191
|
+
else if (u !== "key" && !(u in m)) {
|
|
192
|
+
if (u == "value" && "defaultValue" in m || u == "checked" && "defaultChecked" in m) continue;
|
|
193
193
|
ft(e, u, null, p, o);
|
|
194
194
|
}
|
|
195
195
|
}
|
|
196
|
-
for (u in
|
|
196
|
+
for (u in m) p = m[u], u == "children" ? f = p : u == "dangerouslySetInnerHTML" ? d = p : u == "value" ? _ = p : u == "checked" ? y = p : u === "key" || a && typeof p != "function" || v[u] === p || ft(e, u, p, v[u], o);
|
|
197
197
|
if (d) a || c && (d.__html === c.__html || d.__html === e.innerHTML) || (e.innerHTML = d.__html), t.__k = [];
|
|
198
198
|
else if (c && (e.innerHTML = ""), Rr(e, Tt(f) ? f : [f], t, n, r, g === "foreignObject" ? "http://www.w3.org/1999/xhtml" : o, i, s, i ? i[0] : n.__k && Ae(n, 0), a, l), i != null) for (u = i.length; u--; ) i[u] != null && Lr(i[u]);
|
|
199
|
-
a || (u = "value", _ !== void 0 && (_ !== e[u] || g === "progress" && !_ || g === "option" && _ !==
|
|
199
|
+
a || (u = "value", _ !== void 0 && (_ !== e[u] || g === "progress" && !_ || g === "option" && _ !== v[u]) && ft(e, u, _, v[u], o), u = "checked", y !== void 0 && y !== e[u] && ft(e, u, y, v[u], o));
|
|
200
200
|
}
|
|
201
201
|
return e;
|
|
202
202
|
}
|
|
@@ -207,16 +207,16 @@ function yn(e, t, n) {
|
|
|
207
207
|
r && e.__u(), r && t == null || (e.__u = e(t));
|
|
208
208
|
} else e.current = t;
|
|
209
209
|
} catch (o) {
|
|
210
|
-
|
|
210
|
+
H.__e(o, n);
|
|
211
211
|
}
|
|
212
212
|
}
|
|
213
213
|
function en(e, t, n) {
|
|
214
214
|
var r, o;
|
|
215
|
-
if (
|
|
215
|
+
if (H.unmount && H.unmount(e), (r = e.ref) && (r.current && r.current !== e.__e || yn(r, null, t)), (r = e.__c) != null) {
|
|
216
216
|
if (r.componentWillUnmount) try {
|
|
217
217
|
r.componentWillUnmount();
|
|
218
218
|
} catch (i) {
|
|
219
|
-
|
|
219
|
+
H.__e(i, t);
|
|
220
220
|
}
|
|
221
221
|
r.base = r.__P = null;
|
|
222
222
|
}
|
|
@@ -228,13 +228,13 @@ function Qo(e, t, n) {
|
|
|
228
228
|
}
|
|
229
229
|
function Ue(e, t, n) {
|
|
230
230
|
var r, o, i, s;
|
|
231
|
-
|
|
231
|
+
H.__ && H.__(e, t), o = (r = typeof n == "function") ? null : n && n.__k || t.__k, i = [], s = [], _n(t, e = (!r && n || t).__k = de(G, null, [e]), o || rt, rt, t.namespaceURI, !r && n ? [n] : o ? null : t.firstChild ? ot.call(t.childNodes) : null, i, !r && n ? n : o ? o.__e : t.firstChild, r, s), Dr(i, e, s);
|
|
232
232
|
}
|
|
233
233
|
function Or(e, t) {
|
|
234
234
|
Ue(e, t, Or);
|
|
235
235
|
}
|
|
236
236
|
function ei(e, t, n) {
|
|
237
|
-
var r, o, i, s, a =
|
|
237
|
+
var r, o, i, s, a = ve({}, e.props);
|
|
238
238
|
for (i in e.type && e.type.defaultProps && (s = e.type.defaultProps), t) i == "key" ? r = t[i] : i == "ref" ? o = t[i] : a[i] = t[i] === void 0 && s !== void 0 ? s[i] : t[i];
|
|
239
239
|
return arguments.length > 2 && (a.children = arguments.length > 3 ? ot.call(arguments, 2) : n), Je(e.type, a, r || e.key, o || e.ref, null);
|
|
240
240
|
}
|
|
@@ -261,7 +261,7 @@ function ie(e, t) {
|
|
|
261
261
|
} };
|
|
262
262
|
return n.Provider.__ = n.Consumer.contextType = n;
|
|
263
263
|
}
|
|
264
|
-
ot = Nr.slice,
|
|
264
|
+
ot = Nr.slice, H = { __e: function(e, t, n, r) {
|
|
265
265
|
for (var o, i, s; t = t.__; ) if ((o = t.__c) && !o.__) try {
|
|
266
266
|
if ((i = o.constructor) && i.getDerivedStateFromError != null && (o.setState(i.getDerivedStateFromError(e)), s = o.__d), o.componentDidCatch != null && (o.componentDidCatch(e, r || {}), s = o.__d), s) return o.__E = o;
|
|
267
267
|
} catch (a) {
|
|
@@ -270,12 +270,12 @@ ot = Nr.slice, O = { __e: function(e, t, n, r) {
|
|
|
270
270
|
throw e;
|
|
271
271
|
} }, xr = 0, ue.prototype.setState = function(e, t) {
|
|
272
272
|
var n;
|
|
273
|
-
n = this.__s != null && this.__s !== this.state ? this.__s : this.__s =
|
|
273
|
+
n = this.__s != null && this.__s !== this.state ? this.__s : this.__s = ve({}, this.state), typeof e == "function" && (e = e(ve({}, n), this.props)), e && ve(n, e), e != null && this.__v && (t && this._sb.push(t), Qt(this));
|
|
274
274
|
}, ue.prototype.forceUpdate = function(e) {
|
|
275
275
|
this.__v && (this.__e = !0, e && this.__h.push(e), Qt(this));
|
|
276
|
-
}, ue.prototype.render =
|
|
276
|
+
}, ue.prototype.render = G, xe = [], Mr = typeof Promise == "function" ? Promise.prototype.then.bind(Promise.resolve()) : setTimeout, Xt = function(e, t) {
|
|
277
277
|
return e.__v.__b - t.__v.__b;
|
|
278
|
-
}, _t.__r = 0,
|
|
278
|
+
}, _t.__r = 0, mn = 0, Zt = Wn(!1), Jt = Wn(!0), Pr = 0;
|
|
279
279
|
var ti = 0;
|
|
280
280
|
function h(e, t, n, r, o, i) {
|
|
281
281
|
t || (t = {});
|
|
@@ -283,12 +283,12 @@ function h(e, t, n, r, o, i) {
|
|
|
283
283
|
if ("ref" in l) for (a in l = {}, t) a == "ref" ? s = t[a] : l[a] = t[a];
|
|
284
284
|
var u = { type: e, props: l, key: n, ref: s, __k: null, __: null, __b: 0, __e: null, __d: void 0, __c: null, constructor: void 0, __v: --ti, __i: -1, __u: 0, __source: o, __self: i };
|
|
285
285
|
if (typeof e == "function" && (s = e.defaultProps)) for (a in s) l[a] === void 0 && (l[a] = s[a]);
|
|
286
|
-
return
|
|
286
|
+
return H.vnode && H.vnode(u), u;
|
|
287
287
|
}
|
|
288
|
-
var ge,
|
|
288
|
+
var ge, Y, Ht, Un, ze = 0, Hr = [], J = H, zn = J.__b, Vn = J.__r, jn = J.diffed, Bn = J.__c, qn = J.unmount, Yn = J.__;
|
|
289
289
|
function Ie(e, t) {
|
|
290
|
-
|
|
291
|
-
var n =
|
|
290
|
+
J.__h && J.__h(Y, e, ze || t), ze = 0;
|
|
291
|
+
var n = Y.__H || (Y.__H = { __: [], __h: [] });
|
|
292
292
|
return e >= n.__.length && n.__.push({}), n.__[e];
|
|
293
293
|
}
|
|
294
294
|
function x(e) {
|
|
@@ -299,7 +299,7 @@ function it(e, t, n) {
|
|
|
299
299
|
if (r.t = e, !r.__c && (r.__ = [n ? n(t) : Wr(void 0, t), function(a) {
|
|
300
300
|
var l = r.__N ? r.__N[0] : r.__[0], u = r.t(l, a);
|
|
301
301
|
l !== u && (r.__N = [u, r.__[1]], r.__c.setState({}));
|
|
302
|
-
}], r.__c =
|
|
302
|
+
}], r.__c = Y, !Y.u)) {
|
|
303
303
|
var o = function(a, l, u) {
|
|
304
304
|
if (!r.__c.__H) return !0;
|
|
305
305
|
var d = r.__c.__H.__.filter(function(f) {
|
|
@@ -316,28 +316,28 @@ function it(e, t, n) {
|
|
|
316
316
|
}
|
|
317
317
|
}), !(!c && r.__c.props === a) && (!i || i.call(this, a, l, u));
|
|
318
318
|
};
|
|
319
|
-
|
|
320
|
-
var i =
|
|
321
|
-
|
|
319
|
+
Y.u = !0;
|
|
320
|
+
var i = Y.shouldComponentUpdate, s = Y.componentWillUpdate;
|
|
321
|
+
Y.componentWillUpdate = function(a, l, u) {
|
|
322
322
|
if (this.__e) {
|
|
323
323
|
var d = i;
|
|
324
324
|
i = void 0, o(a, l, u), i = d;
|
|
325
325
|
}
|
|
326
326
|
s && s.call(this, a, l, u);
|
|
327
|
-
},
|
|
327
|
+
}, Y.shouldComponentUpdate = o;
|
|
328
328
|
}
|
|
329
329
|
return r.__N || r.__;
|
|
330
330
|
}
|
|
331
|
-
function
|
|
331
|
+
function W(e, t) {
|
|
332
332
|
var n = Ie(ge++, 3);
|
|
333
|
-
!
|
|
333
|
+
!J.__s && bn(n.__H, t) && (n.__ = e, n.i = t, Y.__H.__h.push(n));
|
|
334
334
|
}
|
|
335
335
|
function De(e, t) {
|
|
336
336
|
var n = Ie(ge++, 4);
|
|
337
|
-
!
|
|
337
|
+
!J.__s && bn(n.__H, t) && (n.__ = e, n.i = t, Y.__h.push(n));
|
|
338
338
|
}
|
|
339
|
-
function
|
|
340
|
-
return ze = 5,
|
|
339
|
+
function w(e) {
|
|
340
|
+
return ze = 5, j(function() {
|
|
341
341
|
return { current: e };
|
|
342
342
|
}, []);
|
|
343
343
|
}
|
|
@@ -350,25 +350,25 @@ function gn(e, t, n) {
|
|
|
350
350
|
}) : void 0;
|
|
351
351
|
}, n == null ? n : n.concat(e));
|
|
352
352
|
}
|
|
353
|
-
function
|
|
353
|
+
function j(e, t) {
|
|
354
354
|
var n = Ie(ge++, 7);
|
|
355
355
|
return bn(n.__H, t) && (n.__ = e(), n.__H = t, n.__h = e), n.__;
|
|
356
356
|
}
|
|
357
|
-
function
|
|
358
|
-
return ze = 8,
|
|
357
|
+
function V(e, t) {
|
|
358
|
+
return ze = 8, j(function() {
|
|
359
359
|
return e;
|
|
360
360
|
}, t);
|
|
361
361
|
}
|
|
362
362
|
function te(e) {
|
|
363
|
-
var t =
|
|
364
|
-
return n.c = e, t ? (n.__ == null && (n.__ = !0, t.sub(
|
|
363
|
+
var t = Y.context[e.__c], n = Ie(ge++, 9);
|
|
364
|
+
return n.c = e, t ? (n.__ == null && (n.__ = !0, t.sub(Y)), t.props.value) : e.__;
|
|
365
365
|
}
|
|
366
366
|
function wn(e, t) {
|
|
367
|
-
|
|
367
|
+
J.useDebugValue && J.useDebugValue(t ? t(e) : e);
|
|
368
368
|
}
|
|
369
369
|
function ni(e) {
|
|
370
370
|
var t = Ie(ge++, 10), n = x();
|
|
371
|
-
return t.__ = e,
|
|
371
|
+
return t.__ = e, Y.componentDidCatch || (Y.componentDidCatch = function(r, o) {
|
|
372
372
|
t.__ && t.__(r, o), n[1](r);
|
|
373
373
|
}), [n[0], function() {
|
|
374
374
|
n[1](void 0);
|
|
@@ -377,7 +377,7 @@ function ni(e) {
|
|
|
377
377
|
function ke() {
|
|
378
378
|
var e = Ie(ge++, 11);
|
|
379
379
|
if (!e.__) {
|
|
380
|
-
for (var t =
|
|
380
|
+
for (var t = Y.__v; t !== null && !t.__m && t.__ !== null; ) t = t.__;
|
|
381
381
|
var n = t.__m || (t.__m = [0, 0]);
|
|
382
382
|
e.__ = "P" + n[0] + "-" + n[1]++;
|
|
383
383
|
}
|
|
@@ -385,49 +385,49 @@ function ke() {
|
|
|
385
385
|
}
|
|
386
386
|
function ri() {
|
|
387
387
|
for (var e; e = Hr.shift(); ) if (e.__P && e.__H) try {
|
|
388
|
-
e.__H.__h.forEach(
|
|
388
|
+
e.__H.__h.forEach(mt), e.__H.__h.forEach(tn), e.__H.__h = [];
|
|
389
389
|
} catch (t) {
|
|
390
|
-
e.__H.__h = [],
|
|
390
|
+
e.__H.__h = [], J.__e(t, e.__v);
|
|
391
391
|
}
|
|
392
392
|
}
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
},
|
|
393
|
+
J.__b = function(e) {
|
|
394
|
+
Y = null, zn && zn(e);
|
|
395
|
+
}, J.__ = function(e, t) {
|
|
396
396
|
e && t.__k && t.__k.__m && (e.__m = t.__k.__m), Yn && Yn(e, t);
|
|
397
|
-
},
|
|
397
|
+
}, J.__r = function(e) {
|
|
398
398
|
Vn && Vn(e), ge = 0;
|
|
399
|
-
var t = (
|
|
400
|
-
t && (Ht ===
|
|
399
|
+
var t = (Y = e.__c).__H;
|
|
400
|
+
t && (Ht === Y ? (t.__h = [], Y.__h = [], t.__.forEach(function(n) {
|
|
401
401
|
n.__N && (n.__ = n.__N), n.i = n.__N = void 0;
|
|
402
|
-
})) : (t.__h.forEach(
|
|
403
|
-
},
|
|
402
|
+
})) : (t.__h.forEach(mt), t.__h.forEach(tn), t.__h = [], ge = 0)), Ht = Y;
|
|
403
|
+
}, J.diffed = function(e) {
|
|
404
404
|
jn && jn(e);
|
|
405
405
|
var t = e.__c;
|
|
406
|
-
t && t.__H && (t.__H.__h.length && (Hr.push(t) !== 1 && Un ===
|
|
406
|
+
t && t.__H && (t.__H.__h.length && (Hr.push(t) !== 1 && Un === J.requestAnimationFrame || ((Un = J.requestAnimationFrame) || oi)(ri)), t.__H.__.forEach(function(n) {
|
|
407
407
|
n.i && (n.__H = n.i), n.i = void 0;
|
|
408
|
-
})), Ht =
|
|
409
|
-
},
|
|
408
|
+
})), Ht = Y = null;
|
|
409
|
+
}, J.__c = function(e, t) {
|
|
410
410
|
t.some(function(n) {
|
|
411
411
|
try {
|
|
412
|
-
n.__h.forEach(
|
|
412
|
+
n.__h.forEach(mt), n.__h = n.__h.filter(function(r) {
|
|
413
413
|
return !r.__ || tn(r);
|
|
414
414
|
});
|
|
415
415
|
} catch (r) {
|
|
416
416
|
t.some(function(o) {
|
|
417
417
|
o.__h && (o.__h = []);
|
|
418
|
-
}), t = [],
|
|
418
|
+
}), t = [], J.__e(r, n.__v);
|
|
419
419
|
}
|
|
420
420
|
}), Bn && Bn(e, t);
|
|
421
|
-
},
|
|
421
|
+
}, J.unmount = function(e) {
|
|
422
422
|
qn && qn(e);
|
|
423
423
|
var t, n = e.__c;
|
|
424
424
|
n && n.__H && (n.__H.__.forEach(function(r) {
|
|
425
425
|
try {
|
|
426
|
-
|
|
426
|
+
mt(r);
|
|
427
427
|
} catch (o) {
|
|
428
428
|
t = o;
|
|
429
429
|
}
|
|
430
|
-
}), n.__H = void 0, t &&
|
|
430
|
+
}), n.__H = void 0, t && J.__e(t, n.__v));
|
|
431
431
|
};
|
|
432
432
|
var Gn = typeof requestAnimationFrame == "function";
|
|
433
433
|
function oi(e) {
|
|
@@ -436,13 +436,13 @@ function oi(e) {
|
|
|
436
436
|
}, r = setTimeout(n, 100);
|
|
437
437
|
Gn && (t = requestAnimationFrame(n));
|
|
438
438
|
}
|
|
439
|
-
function
|
|
440
|
-
var t =
|
|
441
|
-
typeof n == "function" && (e.__c = void 0, n()),
|
|
439
|
+
function mt(e) {
|
|
440
|
+
var t = Y, n = e.__c;
|
|
441
|
+
typeof n == "function" && (e.__c = void 0, n()), Y = t;
|
|
442
442
|
}
|
|
443
443
|
function tn(e) {
|
|
444
|
-
var t =
|
|
445
|
-
e.__c = e.__(),
|
|
444
|
+
var t = Y;
|
|
445
|
+
e.__c = e.__(), Y = t;
|
|
446
446
|
}
|
|
447
447
|
function bn(e, t) {
|
|
448
448
|
return !e || e.length !== t.length || t.some(function(n, r) {
|
|
@@ -477,8 +477,8 @@ function zr(e, t) {
|
|
|
477
477
|
(yt.prototype = new ue()).isPureReactComponent = !0, yt.prototype.shouldComponentUpdate = function(e, t) {
|
|
478
478
|
return nn(this.props, e) || nn(this.state, t);
|
|
479
479
|
};
|
|
480
|
-
var Kn =
|
|
481
|
-
|
|
480
|
+
var Kn = H.__b;
|
|
481
|
+
H.__b = function(e) {
|
|
482
482
|
e.type && e.type.__f && e.ref && (e.props.ref = e.ref, e.ref = null), Kn && Kn(e);
|
|
483
483
|
};
|
|
484
484
|
var ii = typeof Symbol < "u" && Symbol.for && Symbol.for("react.forward_ref") || 3911;
|
|
@@ -497,14 +497,14 @@ var Xn = function(e, t) {
|
|
|
497
497
|
var t = _e(e);
|
|
498
498
|
if (t.length !== 1) throw "Children.only";
|
|
499
499
|
return t[0];
|
|
500
|
-
}, toArray: _e }, si =
|
|
501
|
-
|
|
500
|
+
}, toArray: _e }, si = H.__e;
|
|
501
|
+
H.__e = function(e, t, n, r) {
|
|
502
502
|
if (e.then) {
|
|
503
503
|
for (var o, i = t; i = i.__; ) if ((o = i.__c) && o.__c) return t.__e == null && (t.__e = n.__e, t.__k = n.__k), o.__c(e, t);
|
|
504
504
|
}
|
|
505
505
|
si(e, t, n, r);
|
|
506
506
|
};
|
|
507
|
-
var Zn =
|
|
507
|
+
var Zn = H.unmount;
|
|
508
508
|
function jr(e, t, n) {
|
|
509
509
|
return e && (e.__c && e.__c.__H && (e.__c.__H.__.forEach(function(r) {
|
|
510
510
|
typeof r.__c == "function" && r.__c();
|
|
@@ -540,7 +540,7 @@ function Yr(e) {
|
|
|
540
540
|
function We() {
|
|
541
541
|
this.u = null, this.o = null;
|
|
542
542
|
}
|
|
543
|
-
|
|
543
|
+
H.unmount = function(e) {
|
|
544
544
|
var t = e.__c;
|
|
545
545
|
t && t.__R && t.__R(), t && 32 & e.__u && (e.type = null), Zn && Zn(e);
|
|
546
546
|
}, (Qe.prototype = new ue()).__c = function(e, t) {
|
|
@@ -571,8 +571,8 @@ O.unmount = function(e) {
|
|
|
571
571
|
}
|
|
572
572
|
this.__b = null;
|
|
573
573
|
}
|
|
574
|
-
var o = t.__a && de(
|
|
575
|
-
return o && (o.__u &= -33), [de(
|
|
574
|
+
var o = t.__a && de(G, null, e.fallback);
|
|
575
|
+
return o && (o.__u &= -33), [de(G, null, t.__a ? null : e.children), o];
|
|
576
576
|
};
|
|
577
577
|
var Jn = function(e, t, n) {
|
|
578
578
|
if (++n[1] === n[0] && e.o.delete(t), e.props.revealOrder && (e.props.revealOrder[0] !== "t" || !e.o.size)) for (n = e.u; n; ) {
|
|
@@ -640,22 +640,22 @@ ue.prototype.isReactComponent = {}, ["componentWillMount", "componentWillReceive
|
|
|
640
640
|
Object.defineProperty(this, e, { configurable: !0, writable: !0, value: t });
|
|
641
641
|
} });
|
|
642
642
|
});
|
|
643
|
-
var Qn =
|
|
643
|
+
var Qn = H.event;
|
|
644
644
|
function hi() {
|
|
645
645
|
}
|
|
646
|
-
function
|
|
646
|
+
function mi() {
|
|
647
647
|
return this.cancelBubble;
|
|
648
648
|
}
|
|
649
|
-
function
|
|
649
|
+
function vi() {
|
|
650
650
|
return this.defaultPrevented;
|
|
651
651
|
}
|
|
652
|
-
|
|
653
|
-
return Qn && (e = Qn(e)), e.persist = hi, e.isPropagationStopped =
|
|
652
|
+
H.event = function(e) {
|
|
653
|
+
return Qn && (e = Qn(e)), e.persist = hi, e.isPropagationStopped = mi, e.isDefaultPrevented = vi, e.nativeEvent = e;
|
|
654
654
|
};
|
|
655
655
|
var $n, _i = { enumerable: !1, configurable: !0, get: function() {
|
|
656
656
|
return this.class;
|
|
657
|
-
} }, er =
|
|
658
|
-
|
|
657
|
+
} }, er = H.vnode;
|
|
658
|
+
H.vnode = function(e) {
|
|
659
659
|
typeof e.type == "string" && function(t) {
|
|
660
660
|
var n = t.props, r = t.type, o = {};
|
|
661
661
|
for (var i in n) {
|
|
@@ -672,19 +672,19 @@ O.vnode = function(e) {
|
|
|
672
672
|
})), n.class && !n.className ? (o.class = n.class, Object.defineProperty(o, "className", _i)) : (n.className && !n.class || n.class && n.className) && (o.class = o.className = n.className), t.props = o;
|
|
673
673
|
}(e), e.$$typeof = Gr, er && er(e);
|
|
674
674
|
};
|
|
675
|
-
var tr =
|
|
676
|
-
|
|
675
|
+
var tr = H.__r;
|
|
676
|
+
H.__r = function(e) {
|
|
677
677
|
tr && tr(e), $n = e.__c;
|
|
678
678
|
};
|
|
679
|
-
var nr =
|
|
680
|
-
|
|
679
|
+
var nr = H.diffed;
|
|
680
|
+
H.diffed = function(e) {
|
|
681
681
|
nr && nr(e);
|
|
682
682
|
var t = e.props, n = e.__e;
|
|
683
683
|
n != null && e.type === "textarea" && "value" in t && t.value !== n.value && (n.value = t.value == null ? "" : t.value), $n = null;
|
|
684
684
|
};
|
|
685
685
|
var Zr = { ReactCurrentDispatcher: { current: { readContext: function(e) {
|
|
686
686
|
return $n.__n[e.__c].props.value;
|
|
687
|
-
}, useCallback:
|
|
687
|
+
}, useCallback: V, useContext: te, useDebugValue: wn, useDeferredValue: Sn, useEffect: W, useId: ke, useImperativeHandle: gn, useInsertionEffect: Fn, useLayoutEffect: De, useMemo: j, useReducer: it, useRef: w, useState: x, useSyncExternalStore: St, useTransition: Cn } } }, yi = "17.0.2";
|
|
688
688
|
function Jr(e) {
|
|
689
689
|
return de.bind(null, e);
|
|
690
690
|
}
|
|
@@ -692,7 +692,7 @@ function je(e) {
|
|
|
692
692
|
return !!e && e.$$typeof === Gr;
|
|
693
693
|
}
|
|
694
694
|
function Qr(e) {
|
|
695
|
-
return je(e) && e.type ===
|
|
695
|
+
return je(e) && e.type === G;
|
|
696
696
|
}
|
|
697
697
|
function eo(e) {
|
|
698
698
|
return !!e && !!e.displayName && (typeof e.displayName == "string" || e.displayName instanceof String) && e.displayName.startsWith("Memo(");
|
|
@@ -710,7 +710,7 @@ var ro = function(e, t) {
|
|
|
710
710
|
return e(t);
|
|
711
711
|
}, oo = function(e, t) {
|
|
712
712
|
return e(t);
|
|
713
|
-
}, io =
|
|
713
|
+
}, io = G;
|
|
714
714
|
function kn(e) {
|
|
715
715
|
e();
|
|
716
716
|
}
|
|
@@ -725,7 +725,7 @@ function St(e, t) {
|
|
|
725
725
|
var n = t(), r = x({ h: { __: n, v: t } }), o = r[0].h, i = r[1];
|
|
726
726
|
return De(function() {
|
|
727
727
|
o.__ = n, o.v = t, Wt(o) && i({ h: o });
|
|
728
|
-
}, [e, n, t]),
|
|
728
|
+
}, [e, n, t]), W(function() {
|
|
729
729
|
return Wt(o) && i({ h: o }), e(function() {
|
|
730
730
|
Wt(o) && i({ h: o });
|
|
731
731
|
});
|
|
@@ -740,12 +740,12 @@ function Wt(e) {
|
|
|
740
740
|
return !0;
|
|
741
741
|
}
|
|
742
742
|
}
|
|
743
|
-
var A = { useState: x, useId: ke, useReducer: it, useEffect:
|
|
743
|
+
var A = { useState: x, useId: ke, useReducer: it, useEffect: W, useLayoutEffect: De, useInsertionEffect: Fn, useTransition: Cn, useDeferredValue: Sn, useSyncExternalStore: St, startTransition: kn, useRef: w, useImperativeHandle: gn, useMemo: j, useCallback: V, useContext: te, useDebugValue: wn, version: "17.0.2", Children: Vr, render: Kr, hydrate: Xr, unmountComponentAtNode: to, createPortal: kt, createElement: de, createContext: ie, createFactory: Jr, cloneElement: Tn, createRef: vn, Fragment: G, isValidElement: je, isElement: so, isFragment: Qr, isMemo: eo, findDOMNode: no, Component: ue, PureComponent: yt, memo: zr, forwardRef: En, flushSync: oo, unstable_batchedUpdates: ro, StrictMode: io, Suspense: Qe, SuspenseList: We, lazy: Yr, __SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED: Zr };
|
|
744
744
|
const rr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
745
745
|
__proto__: null,
|
|
746
746
|
Children: Vr,
|
|
747
747
|
Component: ue,
|
|
748
|
-
Fragment:
|
|
748
|
+
Fragment: G,
|
|
749
749
|
PureComponent: yt,
|
|
750
750
|
StrictMode: io,
|
|
751
751
|
Suspense: Qe,
|
|
@@ -756,7 +756,7 @@ const rr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
756
756
|
createElement: de,
|
|
757
757
|
createFactory: Jr,
|
|
758
758
|
createPortal: kt,
|
|
759
|
-
createRef:
|
|
759
|
+
createRef: vn,
|
|
760
760
|
default: A,
|
|
761
761
|
findDOMNode: no,
|
|
762
762
|
flushSync: oo,
|
|
@@ -772,19 +772,19 @@ const rr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
772
772
|
startTransition: kn,
|
|
773
773
|
unmountComponentAtNode: to,
|
|
774
774
|
unstable_batchedUpdates: ro,
|
|
775
|
-
useCallback:
|
|
775
|
+
useCallback: V,
|
|
776
776
|
useContext: te,
|
|
777
777
|
useDebugValue: wn,
|
|
778
778
|
useDeferredValue: Sn,
|
|
779
|
-
useEffect:
|
|
779
|
+
useEffect: W,
|
|
780
780
|
useErrorBoundary: ni,
|
|
781
781
|
useId: ke,
|
|
782
782
|
useImperativeHandle: gn,
|
|
783
783
|
useInsertionEffect: Fn,
|
|
784
784
|
useLayoutEffect: De,
|
|
785
|
-
useMemo:
|
|
785
|
+
useMemo: j,
|
|
786
786
|
useReducer: it,
|
|
787
|
-
useRef:
|
|
787
|
+
useRef: w,
|
|
788
788
|
useState: x,
|
|
789
789
|
useSyncExternalStore: St,
|
|
790
790
|
useTransition: Cn,
|
|
@@ -792,12 +792,12 @@ const rr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
792
792
|
}, Symbol.toStringTag, { value: "Module" })), ao = typeof document < "u" ? A.useLayoutEffect : () => {
|
|
793
793
|
};
|
|
794
794
|
function gi(e) {
|
|
795
|
-
const t =
|
|
795
|
+
const t = w(null);
|
|
796
796
|
return ao(() => {
|
|
797
797
|
t.current = e;
|
|
798
798
|
}, [
|
|
799
799
|
e
|
|
800
|
-
]),
|
|
800
|
+
]), V((...n) => {
|
|
801
801
|
const r = t.current;
|
|
802
802
|
return r == null ? void 0 : r(...n);
|
|
803
803
|
}, []);
|
|
@@ -843,7 +843,7 @@ class ki {
|
|
|
843
843
|
}
|
|
844
844
|
}
|
|
845
845
|
function lo(e) {
|
|
846
|
-
let t =
|
|
846
|
+
let t = w({
|
|
847
847
|
isFocused: !1,
|
|
848
848
|
observer: null
|
|
849
849
|
});
|
|
@@ -856,7 +856,7 @@ function lo(e) {
|
|
|
856
856
|
let n = gi((r) => {
|
|
857
857
|
e == null || e(r);
|
|
858
858
|
});
|
|
859
|
-
return
|
|
859
|
+
return V((r) => {
|
|
860
860
|
if (r.target instanceof HTMLButtonElement || r.target instanceof HTMLInputElement || r.target instanceof HTMLTextAreaElement || r.target instanceof HTMLSelectElement) {
|
|
861
861
|
t.current.isFocused = !0;
|
|
862
862
|
let o = r.target, i = (s) => {
|
|
@@ -889,13 +889,13 @@ function lo(e) {
|
|
|
889
889
|
}
|
|
890
890
|
function Si(e) {
|
|
891
891
|
let { isDisabled: t, onFocus: n, onBlur: r, onFocusChange: o } = e;
|
|
892
|
-
const i =
|
|
892
|
+
const i = V((l) => {
|
|
893
893
|
if (l.target === l.currentTarget)
|
|
894
894
|
return r && r(l), o && o(!1), !0;
|
|
895
895
|
}, [
|
|
896
896
|
r,
|
|
897
897
|
o
|
|
898
|
-
]), s = lo(i), a =
|
|
898
|
+
]), s = lo(i), a = V((l) => {
|
|
899
899
|
const u = st(l.target);
|
|
900
900
|
l.target === l.currentTarget && u.activeElement === l.target && (n && n(l), o && o(!0), s(l));
|
|
901
901
|
}, [
|
|
@@ -982,7 +982,7 @@ function Pi(e, t, n) {
|
|
|
982
982
|
return e = e || (n == null ? void 0 : n.target) instanceof o && !Mi.has(n == null || (r = n.target) === null || r === void 0 ? void 0 : r.type) || (n == null ? void 0 : n.target) instanceof i || (n == null ? void 0 : n.target) instanceof s && (n == null ? void 0 : n.target.isContentEditable), !(e && t === "keyboard" && n instanceof a && !Ci[n.key]);
|
|
983
983
|
}
|
|
984
984
|
function Ni(e, t, n) {
|
|
985
|
-
sn(),
|
|
985
|
+
sn(), W(() => {
|
|
986
986
|
let r = (o, i) => {
|
|
987
987
|
Pi(!!(n != null && n.isTextInput), o, i) && e(ho());
|
|
988
988
|
};
|
|
@@ -992,15 +992,15 @@ function Ni(e, t, n) {
|
|
|
992
992
|
}, t);
|
|
993
993
|
}
|
|
994
994
|
function Li(e) {
|
|
995
|
-
let { isDisabled: t, onBlurWithin: n, onFocusWithin: r, onFocusWithinChange: o } = e, i =
|
|
995
|
+
let { isDisabled: t, onBlurWithin: n, onFocusWithin: r, onFocusWithinChange: o } = e, i = w({
|
|
996
996
|
isFocusWithin: !1
|
|
997
|
-
}), s =
|
|
997
|
+
}), s = V((u) => {
|
|
998
998
|
i.current.isFocusWithin && !u.currentTarget.contains(u.relatedTarget) && (i.current.isFocusWithin = !1, n && n(u), o && o(!1));
|
|
999
999
|
}, [
|
|
1000
1000
|
n,
|
|
1001
1001
|
o,
|
|
1002
1002
|
i
|
|
1003
|
-
]), a = lo(s), l =
|
|
1003
|
+
]), a = lo(s), l = V((u) => {
|
|
1004
1004
|
!i.current.isFocusWithin && document.activeElement === u.target && (r && r(u), o && o(!0), i.current.isFocusWithin = !0, a(u));
|
|
1005
1005
|
}, [
|
|
1006
1006
|
r,
|
|
@@ -1036,14 +1036,14 @@ function Ai() {
|
|
|
1036
1036
|
};
|
|
1037
1037
|
}
|
|
1038
1038
|
function Ri(e) {
|
|
1039
|
-
let { onHoverStart: t, onHoverChange: n, onHoverEnd: r, isDisabled: o } = e, [i, s] = x(!1), a =
|
|
1039
|
+
let { onHoverStart: t, onHoverChange: n, onHoverEnd: r, isDisabled: o } = e, [i, s] = x(!1), a = w({
|
|
1040
1040
|
isHovered: !1,
|
|
1041
1041
|
ignoreEmulatedMouseEvents: !1,
|
|
1042
1042
|
pointerType: "",
|
|
1043
1043
|
target: null
|
|
1044
1044
|
}).current;
|
|
1045
|
-
|
|
1046
|
-
let { hoverProps: l, triggerHoverEnd: u } =
|
|
1045
|
+
W(Ai, []);
|
|
1046
|
+
let { hoverProps: l, triggerHoverEnd: u } = j(() => {
|
|
1047
1047
|
let d = (p, _) => {
|
|
1048
1048
|
if (a.pointerType = _, o || _ === "touch" || a.isHovered || !p.currentTarget.contains(p.target)) return;
|
|
1049
1049
|
a.isHovered = !0;
|
|
@@ -1084,7 +1084,7 @@ function Ri(e) {
|
|
|
1084
1084
|
o,
|
|
1085
1085
|
a
|
|
1086
1086
|
]);
|
|
1087
|
-
return
|
|
1087
|
+
return W(() => {
|
|
1088
1088
|
o && u({
|
|
1089
1089
|
currentTarget: a.target
|
|
1090
1090
|
}, a.pointerType);
|
|
@@ -1096,10 +1096,10 @@ function Ri(e) {
|
|
|
1096
1096
|
};
|
|
1097
1097
|
}
|
|
1098
1098
|
function Ii(e = {}) {
|
|
1099
|
-
let { autoFocus: t = !1, isTextInput: n, within: r } = e, o =
|
|
1099
|
+
let { autoFocus: t = !1, isTextInput: n, within: r } = e, o = w({
|
|
1100
1100
|
isFocused: !1,
|
|
1101
1101
|
isFocusVisible: t || ho()
|
|
1102
|
-
}), [i, s] = x(!1), [a, l] = x(() => o.current.isFocused && o.current.isFocusVisible), u =
|
|
1102
|
+
}), [i, s] = x(!1), [a, l] = x(() => o.current.isFocused && o.current.isFocusVisible), u = V(() => l(o.current.isFocused && o.current.isFocusVisible), []), d = V((p) => {
|
|
1103
1103
|
o.current.isFocused = p, s(p), u();
|
|
1104
1104
|
}, [
|
|
1105
1105
|
u
|
|
@@ -1198,18 +1198,18 @@ function Se() {
|
|
|
1198
1198
|
}
|
|
1199
1199
|
function xt() {
|
|
1200
1200
|
let [e] = x(Se);
|
|
1201
|
-
return
|
|
1201
|
+
return W(() => () => e.dispose(), [e]), e;
|
|
1202
1202
|
}
|
|
1203
1203
|
let re = (e, t) => {
|
|
1204
|
-
Le.isServer ?
|
|
1204
|
+
Le.isServer ? W(e, t) : De(e, t);
|
|
1205
1205
|
};
|
|
1206
1206
|
function Oe(e) {
|
|
1207
|
-
let t =
|
|
1207
|
+
let t = w(e);
|
|
1208
1208
|
return re(() => {
|
|
1209
1209
|
t.current = e;
|
|
1210
1210
|
}, [e]), t;
|
|
1211
1211
|
}
|
|
1212
|
-
let
|
|
1212
|
+
let X = function(e) {
|
|
1213
1213
|
let t = Oe(e);
|
|
1214
1214
|
return A.useCallback((...n) => t.current(...n), [t]);
|
|
1215
1215
|
};
|
|
@@ -1221,9 +1221,9 @@ function Ui(e, t) {
|
|
|
1221
1221
|
return !(!e || !t || e.right < t.left || e.left > t.right || e.bottom < t.top || e.top > t.bottom);
|
|
1222
1222
|
}
|
|
1223
1223
|
function zi({ disabled: e = !1 } = {}) {
|
|
1224
|
-
let t =
|
|
1224
|
+
let t = w(null), [n, r] = x(!1), o = xt(), i = X(() => {
|
|
1225
1225
|
t.current = null, r(!1), o.dispose();
|
|
1226
|
-
}), s =
|
|
1226
|
+
}), s = X((a) => {
|
|
1227
1227
|
if (o.dispose(), t.current === null) {
|
|
1228
1228
|
t.current = a.currentTarget, r(!0);
|
|
1229
1229
|
{
|
|
@@ -1240,7 +1240,7 @@ function zi({ disabled: e = !1 } = {}) {
|
|
|
1240
1240
|
return { pressed: n, pressProps: e ? {} : { onPointerDown: s, onPointerUp: i, onClick: i } };
|
|
1241
1241
|
}
|
|
1242
1242
|
let Vi = ie(void 0);
|
|
1243
|
-
function
|
|
1243
|
+
function mo() {
|
|
1244
1244
|
return te(Vi);
|
|
1245
1245
|
}
|
|
1246
1246
|
function ln(...e) {
|
|
@@ -1257,7 +1257,7 @@ function Te(e, t, ...n) {
|
|
|
1257
1257
|
var bt = ((e) => (e[e.None = 0] = "None", e[e.RenderStrategy = 1] = "RenderStrategy", e[e.Static = 2] = "Static", e))(bt || {}), Ee = ((e) => (e[e.Unmount = 0] = "Unmount", e[e.Hidden = 1] = "Hidden", e))(Ee || {});
|
|
1258
1258
|
function ae({ ourProps: e, theirProps: t, slot: n, defaultTag: r, features: o, visible: i = !0, name: s, mergeRefs: a }) {
|
|
1259
1259
|
a = a ?? ji;
|
|
1260
|
-
let l =
|
|
1260
|
+
let l = vo(t, e);
|
|
1261
1261
|
if (i) return pt(l, n, r, s, a);
|
|
1262
1262
|
let u = o ?? 0;
|
|
1263
1263
|
if (u & 2) {
|
|
@@ -1280,30 +1280,30 @@ function pt(e, t = {}, n, r, o) {
|
|
|
1280
1280
|
let c = {};
|
|
1281
1281
|
if (t) {
|
|
1282
1282
|
let f = !1, p = [];
|
|
1283
|
-
for (let [_, y] of Object.entries(t)) typeof y == "boolean" && (f = !0), y === !0 && p.push(_.replace(/([A-Z])/g, (
|
|
1283
|
+
for (let [_, y] of Object.entries(t)) typeof y == "boolean" && (f = !0), y === !0 && p.push(_.replace(/([A-Z])/g, (v) => `-${v.toLowerCase()}`));
|
|
1284
1284
|
if (f) {
|
|
1285
1285
|
c["data-headlessui-state"] = p.join(" ");
|
|
1286
1286
|
for (let _ of p) c[`data-${_}`] = "";
|
|
1287
1287
|
}
|
|
1288
1288
|
}
|
|
1289
|
-
if (i ===
|
|
1289
|
+
if (i === G && (Object.keys(Fe(l)).length > 0 || Object.keys(Fe(c)).length > 0)) if (!je(d) || Array.isArray(d) && d.length > 1) {
|
|
1290
1290
|
if (Object.keys(Fe(l)).length > 0) throw new Error(['Passing props on "Fragment"!', "", `The current component <${r} /> is rendering a "Fragment".`, "However we need to passthrough the following props:", Object.keys(Fe(l)).concat(Object.keys(Fe(c))).map((f) => ` - ${f}`).join(`
|
|
1291
1291
|
`), "", "You can apply a few solutions:", ['Add an `as="..."` prop, to ensure that we render an actual element instead of a "Fragment".', "Render a single element as the child so that we can forward the props onto that element."].map((f) => ` - ${f}`).join(`
|
|
1292
1292
|
`)].join(`
|
|
1293
1293
|
`));
|
|
1294
1294
|
} else {
|
|
1295
|
-
let f = d.props, p = f == null ? void 0 : f.className, _ = typeof p == "function" ? (...
|
|
1296
|
-
for (let
|
|
1297
|
-
return Tn(d, Object.assign({},
|
|
1295
|
+
let f = d.props, p = f == null ? void 0 : f.className, _ = typeof p == "function" ? (...m) => ln(p(...m), l.className) : ln(p, l.className), y = _ ? { className: _ } : {}, v = vo(d.props, Fe(Vt(l, ["ref"])));
|
|
1296
|
+
for (let m in c) m in v && delete c[m];
|
|
1297
|
+
return Tn(d, Object.assign({}, v, c, u, { ref: o(d.ref, u.ref) }, y));
|
|
1298
1298
|
}
|
|
1299
|
-
return de(i, Object.assign({}, Vt(l, ["ref"]), i !==
|
|
1299
|
+
return de(i, Object.assign({}, Vt(l, ["ref"]), i !== G && u, i !== G && c), d);
|
|
1300
1300
|
}
|
|
1301
1301
|
function ji(...e) {
|
|
1302
1302
|
return e.every((t) => t == null) ? void 0 : (t) => {
|
|
1303
1303
|
for (let n of e) n != null && (typeof n == "function" ? n(t) : n.current = t);
|
|
1304
1304
|
};
|
|
1305
1305
|
}
|
|
1306
|
-
function
|
|
1306
|
+
function vo(...e) {
|
|
1307
1307
|
if (e.length === 0) return {};
|
|
1308
1308
|
if (e.length === 1) return e[0];
|
|
1309
1309
|
let t = {}, n = {};
|
|
@@ -1349,7 +1349,7 @@ function Vt(e, t = []) {
|
|
|
1349
1349
|
let qi = "button";
|
|
1350
1350
|
function Yi(e, t) {
|
|
1351
1351
|
var n;
|
|
1352
|
-
let r =
|
|
1352
|
+
let r = mo(), { disabled: o = r || !1, autoFocus: i = !1, ...s } = e, { isFocusVisible: a, focusProps: l } = Ii({ autoFocus: i }), { isHovered: u, hoverProps: d } = Ri({ isDisabled: o }), { pressed: c, pressProps: f } = zi({ disabled: o }), p = Bi({ ref: t, type: (n = s.type) != null ? n : "button", disabled: o || void 0, autoFocus: i }, l, d, f), _ = j(() => ({ disabled: o, hover: u, focus: a, active: c, autofocus: i }), [o, u, a, c, i]);
|
|
1353
1353
|
return ae({ ourProps: p, theirProps: s, slot: _, defaultTag: qi, name: "Button" });
|
|
1354
1354
|
}
|
|
1355
1355
|
let Gi = oe(Yi), Ki = "div";
|
|
@@ -1371,11 +1371,11 @@ function Qi(e, t = !0) {
|
|
|
1371
1371
|
return Object.assign(e, { [_o]: t });
|
|
1372
1372
|
}
|
|
1373
1373
|
function he(...e) {
|
|
1374
|
-
let t =
|
|
1375
|
-
|
|
1374
|
+
let t = w(e);
|
|
1375
|
+
W(() => {
|
|
1376
1376
|
t.current = e;
|
|
1377
1377
|
}, [e]);
|
|
1378
|
-
let n =
|
|
1378
|
+
let n = X((r) => {
|
|
1379
1379
|
for (let o of t.current) o != null && (typeof o == "function" ? o(r) : o.current = r);
|
|
1380
1380
|
});
|
|
1381
1381
|
return e.every((r) => r == null || (r == null ? void 0 : r[_o])) ? void 0 : n;
|
|
@@ -1392,19 +1392,19 @@ function yo() {
|
|
|
1392
1392
|
}
|
|
1393
1393
|
function es() {
|
|
1394
1394
|
let [e, t] = x([]);
|
|
1395
|
-
return [e.length > 0 ? e.join(" ") : void 0,
|
|
1396
|
-
let r =
|
|
1395
|
+
return [e.length > 0 ? e.join(" ") : void 0, j(() => function(n) {
|
|
1396
|
+
let r = X((i) => (t((s) => [...s, i]), () => t((s) => {
|
|
1397
1397
|
let a = s.slice(), l = a.indexOf(i);
|
|
1398
1398
|
return l !== -1 && a.splice(l, 1), a;
|
|
1399
|
-
}))), o =
|
|
1399
|
+
}))), o = j(() => ({ register: r, slot: n.slot, name: n.name, props: n.props, value: n.value }), [r, n.slot, n.name, n.props, n.value]);
|
|
1400
1400
|
return A.createElement(Mn.Provider, { value: o }, n.children);
|
|
1401
1401
|
}, [t])];
|
|
1402
1402
|
}
|
|
1403
1403
|
let ts = "p";
|
|
1404
1404
|
function ns(e, t) {
|
|
1405
|
-
let n = ke(), r =
|
|
1405
|
+
let n = ke(), r = mo(), { id: o = `headlessui-description-${n}`, ...i } = e, s = yo(), a = he(t);
|
|
1406
1406
|
re(() => s.register(o), [o, s.register]);
|
|
1407
|
-
let l = r || !1, u =
|
|
1407
|
+
let l = r || !1, u = j(() => ({ ...s.slot, disabled: l }), [s.slot, l]), d = { ref: a, ...s.props, id: o };
|
|
1408
1408
|
return ae({ ourProps: d, theirProps: i, slot: u, defaultTag: ts, name: s.name || "Description" });
|
|
1409
1409
|
}
|
|
1410
1410
|
let rs = oe(ns), os = Object.assign(rs, {});
|
|
@@ -1492,7 +1492,7 @@ function Eo(e, t, n) {
|
|
|
1492
1492
|
let i = o.getBoundingClientRect();
|
|
1493
1493
|
i.x === 0 && i.y === 0 && i.width === 0 && i.height === 0 && n();
|
|
1494
1494
|
});
|
|
1495
|
-
|
|
1495
|
+
W(() => {
|
|
1496
1496
|
if (!e) return;
|
|
1497
1497
|
let o = t === null ? null : t instanceof HTMLElement ? t : t.current;
|
|
1498
1498
|
if (!o) return;
|
|
@@ -1509,7 +1509,7 @@ function Eo(e, t, n) {
|
|
|
1509
1509
|
}, [t, r, e]);
|
|
1510
1510
|
}
|
|
1511
1511
|
let dn = ["[contentEditable=true]", "[tabindex]", "a[href]", "area[href]", "button:not([disabled])", "iframe", "input:not([disabled])", "select:not([disabled])", "textarea:not([disabled])"].map((e) => `${e}:not([tabindex='-1'])`).join(","), us = ["[data-autofocus]"].map((e) => `${e}:not([tabindex='-1'])`).join(",");
|
|
1512
|
-
var
|
|
1512
|
+
var me = ((e) => (e[e.First = 1] = "First", e[e.Previous = 2] = "Previous", e[e.Next = 4] = "Next", e[e.Last = 8] = "Last", e[e.WrapAround = 16] = "WrapAround", e[e.NoScroll = 32] = "NoScroll", e[e.AutoFocus = 64] = "AutoFocus", e))(me || {}), fn = ((e) => (e[e.Error = 0] = "Error", e[e.Overflow = 1] = "Overflow", e[e.Success = 2] = "Success", e[e.Underflow = 3] = "Underflow", e))(fn || {}), ds = ((e) => (e[e.Previous = -1] = "Previous", e[e.Next = 1] = "Next", e))(ds || {});
|
|
1513
1513
|
function fs(e = document.body) {
|
|
1514
1514
|
return e == null ? [] : Array.from(e.querySelectorAll(dn)).sort((t, n) => Math.sign((t.tabIndex || Number.MAX_SAFE_INTEGER) - (n.tabIndex || Number.MAX_SAFE_INTEGER)));
|
|
1515
1515
|
}
|
|
@@ -1530,7 +1530,7 @@ function hs(e, t = 0) {
|
|
|
1530
1530
|
return !1;
|
|
1531
1531
|
} });
|
|
1532
1532
|
}
|
|
1533
|
-
var
|
|
1533
|
+
var ms = ((e) => (e[e.Keyboard = 0] = "Keyboard", e[e.Mouse = 1] = "Mouse", e))(ms || {});
|
|
1534
1534
|
typeof window < "u" && typeof document < "u" && (document.addEventListener("keydown", (e) => {
|
|
1535
1535
|
e.metaKey || e.altKey || e.ctrlKey || (document.documentElement.dataset.headlessuiFocusVisible = "");
|
|
1536
1536
|
}, !0), document.addEventListener("click", (e) => {
|
|
@@ -1539,10 +1539,10 @@ typeof window < "u" && typeof document < "u" && (document.addEventListener("keyd
|
|
|
1539
1539
|
function ye(e) {
|
|
1540
1540
|
e == null || e.focus({ preventScroll: !0 });
|
|
1541
1541
|
}
|
|
1542
|
-
let
|
|
1542
|
+
let vs = ["textarea", "input"].join(",");
|
|
1543
1543
|
function _s(e) {
|
|
1544
1544
|
var t, n;
|
|
1545
|
-
return (n = (t = e == null ? void 0 : e.matches) == null ? void 0 : t.call(e,
|
|
1545
|
+
return (n = (t = e == null ? void 0 : e.matches) == null ? void 0 : t.call(e, vs)) != null ? n : !1;
|
|
1546
1546
|
}
|
|
1547
1547
|
function ys(e, t = (n) => n) {
|
|
1548
1548
|
return e.slice().sort((n, r) => {
|
|
@@ -1589,7 +1589,7 @@ function ws() {
|
|
|
1589
1589
|
}
|
|
1590
1590
|
function Ye(e, t, n, r) {
|
|
1591
1591
|
let o = Oe(n);
|
|
1592
|
-
|
|
1592
|
+
W(() => {
|
|
1593
1593
|
if (!e) return;
|
|
1594
1594
|
function i(s) {
|
|
1595
1595
|
o.current(s);
|
|
@@ -1599,7 +1599,7 @@ function Ye(e, t, n, r) {
|
|
|
1599
1599
|
}
|
|
1600
1600
|
function ko(e, t, n, r) {
|
|
1601
1601
|
let o = Oe(n);
|
|
1602
|
-
|
|
1602
|
+
W(() => {
|
|
1603
1603
|
if (!e) return;
|
|
1604
1604
|
function i(s) {
|
|
1605
1605
|
o.current(s);
|
|
@@ -1609,7 +1609,7 @@ function ko(e, t, n, r) {
|
|
|
1609
1609
|
}
|
|
1610
1610
|
const ar = 30;
|
|
1611
1611
|
function bs(e, t, n) {
|
|
1612
|
-
let r = Be(e, "outside-click"), o = Oe(n), i =
|
|
1612
|
+
let r = Be(e, "outside-click"), o = Oe(n), i = V(function(l, u) {
|
|
1613
1613
|
if (l.defaultPrevented) return;
|
|
1614
1614
|
let d = u(l);
|
|
1615
1615
|
if (d === null || !d.getRootNode().contains(d) || !d.isConnected) return;
|
|
@@ -1622,7 +1622,7 @@ function bs(e, t, n) {
|
|
|
1622
1622
|
if (p != null && p.contains(d) || l.composed && l.composedPath().includes(p)) return;
|
|
1623
1623
|
}
|
|
1624
1624
|
return !hs(d, $o.Loose) && d.tabIndex !== -1 && l.preventDefault(), o.current(l, d);
|
|
1625
|
-
}, [o]), s =
|
|
1625
|
+
}, [o]), s = w(null);
|
|
1626
1626
|
Ye(r, "pointerdown", (l) => {
|
|
1627
1627
|
var u, d;
|
|
1628
1628
|
s.current = ((d = (u = l.composedPath) == null ? void 0 : u.call(l)) == null ? void 0 : d[0]) || l.target;
|
|
@@ -1632,7 +1632,7 @@ function bs(e, t, n) {
|
|
|
1632
1632
|
}, !0), Ye(r, "click", (l) => {
|
|
1633
1633
|
ws() || s.current && (i(l, () => s.current), s.current = null);
|
|
1634
1634
|
}, !0);
|
|
1635
|
-
let a =
|
|
1635
|
+
let a = w({ x: 0, y: 0 });
|
|
1636
1636
|
Ye(r, "touchstart", (l) => {
|
|
1637
1637
|
a.current.x = l.touches[0].clientX, a.current.y = l.touches[0].clientY;
|
|
1638
1638
|
}, !0), Ye(r, "touchend", (l) => {
|
|
@@ -1641,11 +1641,11 @@ function bs(e, t, n) {
|
|
|
1641
1641
|
}, !0), ko(r, "blur", (l) => i(l, () => window.document.activeElement instanceof HTMLIFrameElement ? window.document.activeElement : null), !0);
|
|
1642
1642
|
}
|
|
1643
1643
|
function lt(...e) {
|
|
1644
|
-
return
|
|
1644
|
+
return j(() => Ct(...e), [...e]);
|
|
1645
1645
|
}
|
|
1646
1646
|
function So(e, t, n, r) {
|
|
1647
1647
|
let o = Oe(n);
|
|
1648
|
-
|
|
1648
|
+
W(() => {
|
|
1649
1649
|
e = e ?? window;
|
|
1650
1650
|
function i(s) {
|
|
1651
1651
|
o.current(s);
|
|
@@ -1760,7 +1760,7 @@ function Fs(e) {
|
|
|
1760
1760
|
};
|
|
1761
1761
|
}
|
|
1762
1762
|
function xs(e = 0) {
|
|
1763
|
-
let [t, n] = x(e), r =
|
|
1763
|
+
let [t, n] = x(e), r = V((l) => n(l), [t]), o = V((l) => n((u) => u | l), [t]), i = V((l) => (t & l) === l, [t]), s = V((l) => n((u) => u & ~l), [n]), a = V((l) => n((u) => u ^ l), [n]);
|
|
1764
1764
|
return { flags: t, setFlag: r, addFlag: o, hasFlag: i, removeFlag: s, toggleFlag: a };
|
|
1765
1765
|
}
|
|
1766
1766
|
var Ms = ((e) => (e[e.None = 0] = "None", e[e.Closed = 1] = "Closed", e[e.Enter = 2] = "Enter", e[e.Leave = 4] = "Leave", e))(Ms || {});
|
|
@@ -1770,7 +1770,7 @@ function Ps(e) {
|
|
|
1770
1770
|
return t;
|
|
1771
1771
|
}
|
|
1772
1772
|
function Ns(e, t, n, r) {
|
|
1773
|
-
let [o, i] = x(n), { hasFlag: s, addFlag: a, removeFlag: l } = xs(e && o ? 3 : 0), u =
|
|
1773
|
+
let [o, i] = x(n), { hasFlag: s, addFlag: a, removeFlag: l } = xs(e && o ? 3 : 0), u = w(!1), d = w(!1), c = xt();
|
|
1774
1774
|
return re(function f() {
|
|
1775
1775
|
var p;
|
|
1776
1776
|
if (!e) return;
|
|
@@ -1825,8 +1825,8 @@ function Rs(e, { inFlight: t, prepare: n }) {
|
|
|
1825
1825
|
e.style.transition = "none", n(), e.offsetHeight, e.style.transition = r;
|
|
1826
1826
|
}
|
|
1827
1827
|
function Pn(e, t) {
|
|
1828
|
-
let n =
|
|
1829
|
-
|
|
1828
|
+
let n = w([]), r = X(e);
|
|
1829
|
+
W(() => {
|
|
1830
1830
|
let o = [...n.current];
|
|
1831
1831
|
for (let [i, s] of t.entries()) if (n.current[i] !== s) {
|
|
1832
1832
|
let a = r(t, o);
|
|
@@ -1860,8 +1860,8 @@ Os(() => {
|
|
|
1860
1860
|
window.addEventListener("click", e, { capture: !0 }), window.addEventListener("mousedown", e, { capture: !0 }), window.addEventListener("focus", e, { capture: !0 }), document.body.addEventListener("click", e, { capture: !0 }), document.body.addEventListener("mousedown", e, { capture: !0 }), document.body.addEventListener("focus", e, { capture: !0 });
|
|
1861
1861
|
});
|
|
1862
1862
|
function Co(e) {
|
|
1863
|
-
let t =
|
|
1864
|
-
|
|
1863
|
+
let t = X(e), n = w(!1);
|
|
1864
|
+
W(() => (n.current = !1, () => {
|
|
1865
1865
|
n.current = !0, Ft(() => {
|
|
1866
1866
|
n.current && t();
|
|
1867
1867
|
});
|
|
@@ -1874,9 +1874,9 @@ function Hs() {
|
|
|
1874
1874
|
}
|
|
1875
1875
|
function ct() {
|
|
1876
1876
|
let e = Hs(), [t, n] = x(Le.isHandoffComplete);
|
|
1877
|
-
return t && Le.isHandoffComplete === !1 && n(!1),
|
|
1877
|
+
return t && Le.isHandoffComplete === !1 && n(!1), W(() => {
|
|
1878
1878
|
t !== !0 && n(!0);
|
|
1879
|
-
}, [t]),
|
|
1879
|
+
}, [t]), W(() => Le.handoff(), []), e ? !1 : t;
|
|
1880
1880
|
}
|
|
1881
1881
|
let Fo = ie(!1);
|
|
1882
1882
|
function Ws() {
|
|
@@ -1896,14 +1896,14 @@ function Us(e) {
|
|
|
1896
1896
|
let l = r.createElement("div");
|
|
1897
1897
|
return l.setAttribute("id", "headlessui-portal-root"), r.body.appendChild(l);
|
|
1898
1898
|
});
|
|
1899
|
-
return
|
|
1899
|
+
return W(() => {
|
|
1900
1900
|
o !== null && (r != null && r.body.contains(o) || r == null || r.body.appendChild(o));
|
|
1901
|
-
}, [o, r]),
|
|
1901
|
+
}, [o, r]), W(() => {
|
|
1902
1902
|
t || n !== null && i(n.current);
|
|
1903
1903
|
}, [n, i, t]), o;
|
|
1904
1904
|
}
|
|
1905
|
-
let xo =
|
|
1906
|
-
let n = e, r =
|
|
1905
|
+
let xo = G, zs = oe(function(e, t) {
|
|
1906
|
+
let n = e, r = w(null), o = he(Qi((d) => {
|
|
1907
1907
|
r.current = d;
|
|
1908
1908
|
}), t), i = lt(r), s = Us(r), [a] = x(() => {
|
|
1909
1909
|
var d;
|
|
@@ -1922,18 +1922,18 @@ function Vs(e, t) {
|
|
|
1922
1922
|
let n = he(t), { enabled: r = !0, ...o } = e;
|
|
1923
1923
|
return r ? A.createElement(zs, { ...o, ref: n }) : ae({ ourProps: { ref: n }, theirProps: o, slot: {}, defaultTag: xo, name: "Portal" });
|
|
1924
1924
|
}
|
|
1925
|
-
let js =
|
|
1925
|
+
let js = G, Mo = ie(null);
|
|
1926
1926
|
function Bs(e, t) {
|
|
1927
1927
|
let { target: n, ...r } = e, o = { ref: he(t) };
|
|
1928
1928
|
return A.createElement(Mo.Provider, { value: n }, ae({ ourProps: o, theirProps: r, defaultTag: js, name: "Popover.Group" }));
|
|
1929
1929
|
}
|
|
1930
1930
|
let pn = ie(null);
|
|
1931
1931
|
function qs() {
|
|
1932
|
-
let e = te(pn), t =
|
|
1932
|
+
let e = te(pn), t = w([]), n = X((i) => (t.current.push(i), e && e.register(i), () => r(i))), r = X((i) => {
|
|
1933
1933
|
let s = t.current.indexOf(i);
|
|
1934
1934
|
s !== -1 && t.current.splice(s, 1), e && e.unregister(i);
|
|
1935
|
-
}), o =
|
|
1936
|
-
return [t,
|
|
1935
|
+
}), o = j(() => ({ register: n, unregister: r, portals: t }), [n, r, t]);
|
|
1936
|
+
return [t, j(() => function({ children: i }) {
|
|
1937
1937
|
return A.createElement(pn.Provider, { value: o }, i);
|
|
1938
1938
|
}, [o])];
|
|
1939
1939
|
}
|
|
@@ -1957,7 +1957,7 @@ function Xs() {
|
|
|
1957
1957
|
}
|
|
1958
1958
|
function Zs({ defaultContainers: e = [], portals: t, mainTreeNodeRef: n } = {}) {
|
|
1959
1959
|
var r;
|
|
1960
|
-
let o =
|
|
1960
|
+
let o = w((r = n == null ? void 0 : n.current) != null ? r : null), i = lt(o), s = X(() => {
|
|
1961
1961
|
var a, l, u;
|
|
1962
1962
|
let d = [];
|
|
1963
1963
|
for (let c of e) c !== null && (c instanceof HTMLElement ? d.push(c) : "current" in c && c.current instanceof HTMLElement && d.push(c.current));
|
|
@@ -1965,19 +1965,19 @@ function Zs({ defaultContainers: e = [], portals: t, mainTreeNodeRef: n } = {})
|
|
|
1965
1965
|
for (let c of (a = i == null ? void 0 : i.querySelectorAll("html > *, body > *")) != null ? a : []) c !== document.body && c !== document.head && c instanceof HTMLElement && c.id !== "headlessui-portal-root" && (c.contains(o.current) || c.contains((u = (l = o.current) == null ? void 0 : l.getRootNode()) == null ? void 0 : u.host) || d.some((f) => c.contains(f)) || d.push(c));
|
|
1966
1966
|
return d;
|
|
1967
1967
|
});
|
|
1968
|
-
return { resolveContainers: s, contains:
|
|
1968
|
+
return { resolveContainers: s, contains: X((a) => s().some((l) => l.contains(a))), mainTreeNodeRef: o, MainTreeNode: j(() => function() {
|
|
1969
1969
|
return n != null ? null : A.createElement(cn, { features: Et.Hidden, ref: o });
|
|
1970
1970
|
}, [o, n]) };
|
|
1971
1971
|
}
|
|
1972
1972
|
function Nn() {
|
|
1973
|
-
let e =
|
|
1973
|
+
let e = w(!1);
|
|
1974
1974
|
return re(() => (e.current = !0, () => {
|
|
1975
1975
|
e.current = !1;
|
|
1976
1976
|
}), []), e;
|
|
1977
1977
|
}
|
|
1978
1978
|
var Ze = ((e) => (e[e.Forwards = 0] = "Forwards", e[e.Backwards = 1] = "Backwards", e))(Ze || {});
|
|
1979
1979
|
function Js() {
|
|
1980
|
-
let e =
|
|
1980
|
+
let e = w(0);
|
|
1981
1981
|
return ko(!0, "keydown", (t) => {
|
|
1982
1982
|
t.key === "Tab" && (e.current = t.shiftKey ? 1 : 0);
|
|
1983
1983
|
}, !0), e;
|
|
@@ -1992,42 +1992,42 @@ function No(e) {
|
|
|
1992
1992
|
let Qs = "div";
|
|
1993
1993
|
var Me = ((e) => (e[e.None = 0] = "None", e[e.InitialFocus = 1] = "InitialFocus", e[e.TabLock = 2] = "TabLock", e[e.FocusLock = 4] = "FocusLock", e[e.RestoreFocus = 8] = "RestoreFocus", e[e.AutoFocus = 16] = "AutoFocus", e))(Me || {});
|
|
1994
1994
|
function ea(e, t) {
|
|
1995
|
-
let n =
|
|
1995
|
+
let n = w(null), r = he(n, t), { initialFocus: o, initialFocusFallback: i, containers: s, features: a = 15, ...l } = e;
|
|
1996
1996
|
ct() || (a = 0);
|
|
1997
1997
|
let u = lt(n);
|
|
1998
1998
|
oa(a, { ownerDocument: u });
|
|
1999
1999
|
let d = ia(a, { ownerDocument: u, container: n, initialFocus: o, initialFocusFallback: i });
|
|
2000
2000
|
sa(a, { ownerDocument: u, container: n, containers: s, previousActiveElement: d });
|
|
2001
|
-
let c = Js(), f =
|
|
2001
|
+
let c = Js(), f = X((m) => {
|
|
2002
2002
|
let g = n.current;
|
|
2003
|
-
g && ((
|
|
2003
|
+
g && ((E) => E())(() => {
|
|
2004
2004
|
Te(c.current, { [Ze.Forwards]: () => {
|
|
2005
|
-
nt(g,
|
|
2005
|
+
nt(g, me.First, { skipElements: [m.relatedTarget, i] });
|
|
2006
2006
|
}, [Ze.Backwards]: () => {
|
|
2007
|
-
nt(g,
|
|
2007
|
+
nt(g, me.Last, { skipElements: [m.relatedTarget, i] });
|
|
2008
2008
|
} });
|
|
2009
2009
|
});
|
|
2010
|
-
}), p = Be(!!(a & 2), "focus-trap#tab-lock"), _ = xt(), y =
|
|
2011
|
-
|
|
2010
|
+
}), p = Be(!!(a & 2), "focus-trap#tab-lock"), _ = xt(), y = w(!1), v = { ref: r, onKeyDown(m) {
|
|
2011
|
+
m.key == "Tab" && (y.current = !0, _.requestAnimationFrame(() => {
|
|
2012
2012
|
y.current = !1;
|
|
2013
2013
|
}));
|
|
2014
|
-
}, onBlur(
|
|
2014
|
+
}, onBlur(m) {
|
|
2015
2015
|
if (!(a & 4)) return;
|
|
2016
2016
|
let g = No(s);
|
|
2017
2017
|
n.current instanceof HTMLElement && g.add(n.current);
|
|
2018
|
-
let
|
|
2019
|
-
|
|
2018
|
+
let E = m.relatedTarget;
|
|
2019
|
+
E instanceof HTMLElement && E.dataset.headlessuiFocusGuard !== "true" && (Lo(g, E) || (y.current ? nt(n.current, Te(c.current, { [Ze.Forwards]: () => me.Next, [Ze.Backwards]: () => me.Previous }) | me.WrapAround, { relativeTo: m.target }) : m.target instanceof HTMLElement && ye(m.target)));
|
|
2020
2020
|
} };
|
|
2021
|
-
return A.createElement(A.Fragment, null, p && A.createElement(cn, { as: "button", type: "button", "data-headlessui-focus-guard": !0, onFocus: f, features: Et.Focusable }), ae({ ourProps:
|
|
2021
|
+
return A.createElement(A.Fragment, null, p && A.createElement(cn, { as: "button", type: "button", "data-headlessui-focus-guard": !0, onFocus: f, features: Et.Focusable }), ae({ ourProps: v, theirProps: l, defaultTag: Qs, name: "FocusTrap" }), p && A.createElement(cn, { as: "button", type: "button", "data-headlessui-focus-guard": !0, onFocus: f, features: Et.Focusable }));
|
|
2022
2022
|
}
|
|
2023
2023
|
let ta = oe(ea), na = Object.assign(ta, { features: Me });
|
|
2024
2024
|
function ra(e = !0) {
|
|
2025
|
-
let t =
|
|
2025
|
+
let t = w(be.slice());
|
|
2026
2026
|
return Pn(([n], [r]) => {
|
|
2027
2027
|
r === !0 && n === !1 && Ft(() => {
|
|
2028
2028
|
t.current.splice(0);
|
|
2029
2029
|
}), r === !1 && n === !0 && (t.current = be.slice());
|
|
2030
|
-
}, [e, be, t]),
|
|
2030
|
+
}, [e, be, t]), X(() => {
|
|
2031
2031
|
var n;
|
|
2032
2032
|
return (n = t.current.find((r) => r != null && r.isConnected)) != null ? n : null;
|
|
2033
2033
|
});
|
|
@@ -2041,7 +2041,7 @@ function oa(e, { ownerDocument: t }) {
|
|
|
2041
2041
|
});
|
|
2042
2042
|
}
|
|
2043
2043
|
function ia(e, { ownerDocument: t, container: n, initialFocus: r, initialFocusFallback: o }) {
|
|
2044
|
-
let i =
|
|
2044
|
+
let i = w(null), s = Be(!!(e & 1), "focus-trap#initial-focus"), a = Nn();
|
|
2045
2045
|
return Pn(() => {
|
|
2046
2046
|
if (e === 0) return;
|
|
2047
2047
|
if (!s) {
|
|
@@ -2064,8 +2064,8 @@ function ia(e, { ownerDocument: t, container: n, initialFocus: r, initialFocusFa
|
|
|
2064
2064
|
if (r != null && r.current) ye(r.current);
|
|
2065
2065
|
else {
|
|
2066
2066
|
if (e & 16) {
|
|
2067
|
-
if (nt(l,
|
|
2068
|
-
} else if (nt(l,
|
|
2067
|
+
if (nt(l, me.First | me.AutoFocus) !== fn.Error) return;
|
|
2068
|
+
} else if (nt(l, me.First) !== fn.Error) return;
|
|
2069
2069
|
if (o != null && o.current && (ye(o.current), (t == null ? void 0 : t.activeElement) === o.current)) return;
|
|
2070
2070
|
console.warn("There are no focusable elements inside the <FocusTrap />");
|
|
2071
2071
|
}
|
|
@@ -2091,7 +2091,7 @@ function Lo(e, t) {
|
|
|
2091
2091
|
}
|
|
2092
2092
|
function Ao(e) {
|
|
2093
2093
|
var t;
|
|
2094
|
-
return !!(e.enter || e.enterFrom || e.enterTo || e.leave || e.leaveFrom || e.leaveTo) || ((t = e.as) != null ? t : Io) !==
|
|
2094
|
+
return !!(e.enter || e.enterFrom || e.enterTo || e.leave || e.leaveFrom || e.leaveTo) || ((t = e.as) != null ? t : Io) !== G || A.Children.count(e.children) === 1;
|
|
2095
2095
|
}
|
|
2096
2096
|
let Nt = ie(null);
|
|
2097
2097
|
Nt.displayName = "TransitionContext";
|
|
@@ -2112,93 +2112,93 @@ function At(e) {
|
|
|
2112
2112
|
return "children" in e ? At(e.children) : e.current.filter(({ el: t }) => t.current !== null).filter(({ state: t }) => t === "visible").length > 0;
|
|
2113
2113
|
}
|
|
2114
2114
|
function Ro(e, t) {
|
|
2115
|
-
let n = Oe(e), r =
|
|
2116
|
-
let y = r.current.findIndex(({ el:
|
|
2115
|
+
let n = Oe(e), r = w([]), o = Nn(), i = xt(), s = X((p, _ = Ee.Hidden) => {
|
|
2116
|
+
let y = r.current.findIndex(({ el: v }) => v === p);
|
|
2117
2117
|
y !== -1 && (Te(_, { [Ee.Unmount]() {
|
|
2118
2118
|
r.current.splice(y, 1);
|
|
2119
2119
|
}, [Ee.Hidden]() {
|
|
2120
2120
|
r.current[y].state = "hidden";
|
|
2121
2121
|
} }), i.microTask(() => {
|
|
2122
|
-
var
|
|
2123
|
-
!At(r) && o.current && ((
|
|
2122
|
+
var v;
|
|
2123
|
+
!At(r) && o.current && ((v = n.current) == null || v.call(n));
|
|
2124
2124
|
}));
|
|
2125
|
-
}), a =
|
|
2125
|
+
}), a = X((p) => {
|
|
2126
2126
|
let _ = r.current.find(({ el: y }) => y === p);
|
|
2127
2127
|
return _ ? _.state !== "visible" && (_.state = "visible") : r.current.push({ el: p, state: "visible" }), () => s(p, Ee.Unmount);
|
|
2128
|
-
}), l =
|
|
2129
|
-
l.current.splice(0), t && (t.chains.current[_] = t.chains.current[_].filter(([
|
|
2130
|
-
l.current.push(
|
|
2131
|
-
})]), t == null || t.chains.current[_].push([p, new Promise((
|
|
2132
|
-
Promise.all(d.current[_].map(([
|
|
2128
|
+
}), l = w([]), u = w(Promise.resolve()), d = w({ enter: [], leave: [] }), c = X((p, _, y) => {
|
|
2129
|
+
l.current.splice(0), t && (t.chains.current[_] = t.chains.current[_].filter(([v]) => v !== p)), t == null || t.chains.current[_].push([p, new Promise((v) => {
|
|
2130
|
+
l.current.push(v);
|
|
2131
|
+
})]), t == null || t.chains.current[_].push([p, new Promise((v) => {
|
|
2132
|
+
Promise.all(d.current[_].map(([m, g]) => g)).then(() => v());
|
|
2133
2133
|
})]), _ === "enter" ? u.current = u.current.then(() => t == null ? void 0 : t.wait.current).then(() => y(_)) : y(_);
|
|
2134
|
-
}), f =
|
|
2135
|
-
Promise.all(d.current[_].splice(0).map(([
|
|
2136
|
-
var
|
|
2137
|
-
(
|
|
2134
|
+
}), f = X((p, _, y) => {
|
|
2135
|
+
Promise.all(d.current[_].splice(0).map(([v, m]) => m)).then(() => {
|
|
2136
|
+
var v;
|
|
2137
|
+
(v = l.current.shift()) == null || v();
|
|
2138
2138
|
}).then(() => y(_));
|
|
2139
2139
|
});
|
|
2140
|
-
return
|
|
2140
|
+
return j(() => ({ children: r, register: a, unregister: s, onStart: c, onStop: f, wait: u, chains: d }), [a, s, r, c, f, d, u]);
|
|
2141
2141
|
}
|
|
2142
|
-
let Io =
|
|
2142
|
+
let Io = G, Do = bt.RenderStrategy;
|
|
2143
2143
|
function ua(e, t) {
|
|
2144
2144
|
var n, r;
|
|
2145
|
-
let { transition: o = !0, beforeEnter: i, afterEnter: s, beforeLeave: a, afterLeave: l, enter: u, enterFrom: d, enterTo: c, entered: f, leave: p, leaveFrom: _, leaveTo: y, ...
|
|
2146
|
-
re(() => I(
|
|
2147
|
-
if (
|
|
2148
|
-
if (S &&
|
|
2145
|
+
let { transition: o = !0, beforeEnter: i, afterEnter: s, beforeLeave: a, afterLeave: l, enter: u, enterFrom: d, enterTo: c, entered: f, leave: p, leaveFrom: _, leaveTo: y, ...v } = e, m = w(null), g = Ao(e), E = he(...g ? [m, t] : t === null ? [] : [t]), $ = (n = v.unmount) == null || n ? Ee.Unmount : Ee.Hidden, { show: S, appear: M, initial: R } = la(), [U, F] = x(S ? "visible" : "hidden"), b = ca(), { register: I, unregister: B } = b;
|
|
2146
|
+
re(() => I(m), [I, m]), re(() => {
|
|
2147
|
+
if ($ === Ee.Hidden && m.current) {
|
|
2148
|
+
if (S && U !== "visible") {
|
|
2149
2149
|
F("visible");
|
|
2150
2150
|
return;
|
|
2151
2151
|
}
|
|
2152
|
-
return Te(
|
|
2152
|
+
return Te(U, { hidden: () => B(m), visible: () => I(m) });
|
|
2153
2153
|
}
|
|
2154
|
-
}, [
|
|
2154
|
+
}, [U, m, I, B, S, $]);
|
|
2155
2155
|
let D = ct();
|
|
2156
2156
|
re(() => {
|
|
2157
|
-
if (g && D &&
|
|
2158
|
-
}, [
|
|
2159
|
-
let
|
|
2160
|
-
Z.current || (F("hidden"), B(
|
|
2161
|
-
},
|
|
2157
|
+
if (g && D && U === "visible" && m.current === null) throw new Error("Did you forget to passthrough the `ref` to the actual DOM node?");
|
|
2158
|
+
}, [m, U, D, g]);
|
|
2159
|
+
let K = R && !M, Q = M && S && R, Z = w(!1), k = Ro(() => {
|
|
2160
|
+
Z.current || (F("hidden"), B(m));
|
|
2161
|
+
}, b), C = X((q) => {
|
|
2162
2162
|
Z.current = !0;
|
|
2163
|
-
let
|
|
2164
|
-
k.onStart(
|
|
2163
|
+
let z = q ? "enter" : "leave";
|
|
2164
|
+
k.onStart(m, z, (ee) => {
|
|
2165
2165
|
ee === "enter" ? i == null || i() : ee === "leave" && (a == null || a());
|
|
2166
2166
|
});
|
|
2167
|
-
}), L =
|
|
2168
|
-
let
|
|
2169
|
-
Z.current = !1, k.onStop(
|
|
2167
|
+
}), L = X((q) => {
|
|
2168
|
+
let z = q ? "enter" : "leave";
|
|
2169
|
+
Z.current = !1, k.onStop(m, z, (ee) => {
|
|
2170
2170
|
ee === "enter" ? s == null || s() : ee === "leave" && (l == null || l());
|
|
2171
|
-
}),
|
|
2171
|
+
}), z === "leave" && !At(k) && (F("hidden"), B(m));
|
|
2172
2172
|
});
|
|
2173
|
-
|
|
2173
|
+
W(() => {
|
|
2174
2174
|
g && o || (C(S), L(S));
|
|
2175
2175
|
}, [S, g, o]);
|
|
2176
|
-
let
|
|
2177
|
-
return
|
|
2176
|
+
let N = !(!o || !g || !D || K), [, T] = Ns(N, m, S, { start: C, end: L }), P = Fe({ ref: E, className: ((r = ln(v.className, Q && u, Q && d, T.enter && u, T.enter && T.closed && d, T.enter && !T.closed && c, T.leave && p, T.leave && !T.closed && _, T.leave && T.closed && y, !T.transition && S && f)) == null ? void 0 : r.trim()) || void 0, ...Ps(T) }), O = 0;
|
|
2177
|
+
return U === "visible" && (O |= ce.Open), U === "hidden" && (O |= ce.Closed), T.enter && (O |= ce.Opening), T.leave && (O |= ce.Closing), A.createElement(Lt.Provider, { value: k }, A.createElement(Is, { value: O }, ae({ ourProps: P, theirProps: v, defaultTag: Io, features: Do, visible: U === "visible", name: "Transition.Child" })));
|
|
2178
2178
|
}
|
|
2179
2179
|
function da(e, t) {
|
|
2180
|
-
let { show: n, appear: r = !1, unmount: o = !0, ...i } = e, s =
|
|
2180
|
+
let { show: n, appear: r = !1, unmount: o = !0, ...i } = e, s = w(null), a = Ao(e), l = he(...a ? [s, t] : t === null ? [] : [t]);
|
|
2181
2181
|
ct();
|
|
2182
2182
|
let u = Pt();
|
|
2183
2183
|
if (n === void 0 && u !== null && (n = (u & ce.Open) === ce.Open), n === void 0) throw new Error("A <Transition /> is used but it is missing a `show={true | false}` prop.");
|
|
2184
2184
|
let [d, c] = x(n ? "visible" : "hidden"), f = Ro(() => {
|
|
2185
2185
|
n || c("hidden");
|
|
2186
|
-
}), [p, _] = x(!0), y =
|
|
2186
|
+
}), [p, _] = x(!0), y = w([n]);
|
|
2187
2187
|
re(() => {
|
|
2188
2188
|
p !== !1 && y.current[y.current.length - 1] !== n && (y.current.push(n), _(!1));
|
|
2189
2189
|
}, [y, n]);
|
|
2190
|
-
let
|
|
2190
|
+
let v = j(() => ({ show: n, appear: r, initial: p }), [n, r, p]);
|
|
2191
2191
|
Eo(n, s, () => c("hidden")), re(() => {
|
|
2192
2192
|
n ? c("visible") : !At(f) && s.current !== null && c("hidden");
|
|
2193
2193
|
}, [n, f]);
|
|
2194
|
-
let
|
|
2195
|
-
var
|
|
2196
|
-
p && _(!1), (
|
|
2197
|
-
}),
|
|
2198
|
-
var
|
|
2199
|
-
p && _(!1), (
|
|
2194
|
+
let m = { unmount: o }, g = X(() => {
|
|
2195
|
+
var $;
|
|
2196
|
+
p && _(!1), ($ = e.beforeEnter) == null || $.call(e);
|
|
2197
|
+
}), E = X(() => {
|
|
2198
|
+
var $;
|
|
2199
|
+
p && _(!1), ($ = e.beforeLeave) == null || $.call(e);
|
|
2200
2200
|
});
|
|
2201
|
-
return A.createElement(Lt.Provider, { value: f }, A.createElement(Nt.Provider, { value:
|
|
2201
|
+
return A.createElement(Lt.Provider, { value: f }, A.createElement(Nt.Provider, { value: v }, ae({ ourProps: { ...m, as: G, children: A.createElement(Oo, { ref: l, ...m, ...i, beforeEnter: g, beforeLeave: E }) }, theirProps: {}, defaultTag: G, features: Do, visible: d === "visible", name: "Transition" })));
|
|
2202
2202
|
}
|
|
2203
2203
|
function fa(e, t) {
|
|
2204
2204
|
let n = te(Nt) !== null, r = Pt() !== null;
|
|
@@ -2206,7 +2206,7 @@ function fa(e, t) {
|
|
|
2206
2206
|
}
|
|
2207
2207
|
let hn = oe(da), Oo = oe(ua), Ln = oe(fa), pe = Object.assign(hn, { Child: Ln, Root: hn });
|
|
2208
2208
|
var pa = ((e) => (e[e.Open = 0] = "Open", e[e.Closed = 1] = "Closed", e))(pa || {}), ha = ((e) => (e[e.SetTitleId = 0] = "SetTitleId", e))(ha || {});
|
|
2209
|
-
let
|
|
2209
|
+
let ma = { 0(e, t) {
|
|
2210
2210
|
return e.titleId === t.id ? e : { ...e, titleId: t.id };
|
|
2211
2211
|
} }, An = ie(null);
|
|
2212
2212
|
An.displayName = "DialogContext";
|
|
@@ -2218,33 +2218,33 @@ function Rt(e) {
|
|
|
2218
2218
|
}
|
|
2219
2219
|
return t;
|
|
2220
2220
|
}
|
|
2221
|
-
function
|
|
2222
|
-
return Te(t.type,
|
|
2221
|
+
function va(e, t) {
|
|
2222
|
+
return Te(t.type, ma, e, t);
|
|
2223
2223
|
}
|
|
2224
2224
|
let cr = oe(function(e, t) {
|
|
2225
|
-
let n = ke(), { id: r = `headlessui-dialog-${n}`, open: o, onClose: i, initialFocus: s, role: a = "dialog", autoFocus: l = !0, __demoMode: u = !1, ...d } = e, c =
|
|
2225
|
+
let n = ke(), { id: r = `headlessui-dialog-${n}`, open: o, onClose: i, initialFocus: s, role: a = "dialog", autoFocus: l = !0, __demoMode: u = !1, ...d } = e, c = w(!1);
|
|
2226
2226
|
a = function() {
|
|
2227
2227
|
return a === "dialog" || a === "alertdialog" ? a : (c.current || (c.current = !0, console.warn(`Invalid role [${a}] passed to <Dialog />. Only \`dialog\` and and \`alertdialog\` are supported. Using \`dialog\` instead.`)), "dialog");
|
|
2228
2228
|
}();
|
|
2229
2229
|
let f = Pt();
|
|
2230
2230
|
o === void 0 && f !== null && (o = (f & ce.Open) === ce.Open);
|
|
2231
|
-
let p =
|
|
2232
|
-
var
|
|
2233
|
-
return (
|
|
2234
|
-
} }, { resolveContainers: F, mainTreeNodeRef:
|
|
2235
|
-
cs(u || B ? !1 : S, { allowed:
|
|
2236
|
-
var
|
|
2237
|
-
return [(
|
|
2238
|
-
}), disallowed:
|
|
2239
|
-
var
|
|
2240
|
-
return [(
|
|
2241
|
-
}) }), bs(S, F, (
|
|
2242
|
-
|
|
2243
|
-
}), Ks(S, y == null ? void 0 : y.defaultView, (
|
|
2244
|
-
|
|
2245
|
-
}), Cs(u || B ? !1 : S, y, F), Eo(S, p,
|
|
2246
|
-
let [D,
|
|
2247
|
-
return S && !u && (L |= Me.RestoreFocus, L |= Me.TabLock, l && (L |= Me.AutoFocus), C && (L |= Me.InitialFocus)), A.createElement(Ds, null, A.createElement(lr, { force: !0 }, A.createElement(Gs, null, A.createElement(An.Provider, { value: Q }, A.createElement(Po, { target: p }, A.createElement(lr, { force: !1 }, A.createElement(
|
|
2231
|
+
let p = w(null), _ = he(p, t), y = lt(p), v = o ? 0 : 1, [m, g] = it(va, { titleId: null, descriptionId: null, panelRef: vn() }), E = X(() => i(!1)), $ = X((N) => g({ type: 0, id: N })), S = ct() ? v === 0 : !1, [M, R] = qs(), U = { get current() {
|
|
2232
|
+
var N;
|
|
2233
|
+
return (N = m.panelRef.current) != null ? N : p.current;
|
|
2234
|
+
} }, { resolveContainers: F, mainTreeNodeRef: b, MainTreeNode: I } = Zs({ portals: M, defaultContainers: [U] }), B = f !== null ? (f & ce.Closing) === ce.Closing : !1;
|
|
2235
|
+
cs(u || B ? !1 : S, { allowed: X(() => {
|
|
2236
|
+
var N, T;
|
|
2237
|
+
return [(T = (N = p.current) == null ? void 0 : N.closest("[data-headlessui-portal]")) != null ? T : null];
|
|
2238
|
+
}), disallowed: X(() => {
|
|
2239
|
+
var N, T;
|
|
2240
|
+
return [(T = (N = b.current) == null ? void 0 : N.closest("body > *:not(#headlessui-portal-root)")) != null ? T : null];
|
|
2241
|
+
}) }), bs(S, F, (N) => {
|
|
2242
|
+
N.preventDefault(), E();
|
|
2243
|
+
}), Ks(S, y == null ? void 0 : y.defaultView, (N) => {
|
|
2244
|
+
N.preventDefault(), N.stopPropagation(), document.activeElement && "blur" in document.activeElement && typeof document.activeElement.blur == "function" && document.activeElement.blur(), E();
|
|
2245
|
+
}), Cs(u || B ? !1 : S, y, F), Eo(S, p, E);
|
|
2246
|
+
let [D, K] = es(), Q = j(() => [{ dialogState: v, close: E, setTitleId: $ }, m], [v, m, E, $]), Z = j(() => ({ open: v === 0 }), [v]), k = { ref: _, id: r, role: a, tabIndex: -1, "aria-modal": u ? void 0 : v === 0 ? !0 : void 0, "aria-labelledby": m.titleId, "aria-describedby": D }, C = !Xs(), L = Me.None;
|
|
2247
|
+
return S && !u && (L |= Me.RestoreFocus, L |= Me.TabLock, l && (L |= Me.AutoFocus), C && (L |= Me.InitialFocus)), A.createElement(Ds, null, A.createElement(lr, { force: !0 }, A.createElement(Gs, null, A.createElement(An.Provider, { value: Q }, A.createElement(Po, { target: p }, A.createElement(lr, { force: !1 }, A.createElement(K, { slot: Z }, A.createElement(R, null, A.createElement(na, { initialFocus: s, initialFocusFallback: p, containers: F, features: L }, A.createElement(ss, { value: E }, ae({ ourProps: k, theirProps: d, slot: Z, defaultTag: _a, features: ya, visible: v === 0, name: "Dialog" })))))))))), A.createElement(Ji, null, A.createElement(I, null)));
|
|
2248
2248
|
}), _a = "div", ya = bt.RenderStrategy | bt.Static;
|
|
2249
2249
|
function ga(e, t) {
|
|
2250
2250
|
let { transition: n = !1, open: r, ...o } = e, i = Pt(), s = e.hasOwnProperty("open") || i !== null, a = e.hasOwnProperty("onClose");
|
|
@@ -2257,21 +2257,21 @@ function ga(e, t) {
|
|
|
2257
2257
|
}
|
|
2258
2258
|
let wa = "div";
|
|
2259
2259
|
function ba(e, t) {
|
|
2260
|
-
let n = ke(), { id: r = `headlessui-dialog-panel-${n}`, transition: o = !1, ...i } = e, [{ dialogState: s }, a] = Rt("Dialog.Panel"), l = he(t, a.panelRef), u =
|
|
2260
|
+
let n = ke(), { id: r = `headlessui-dialog-panel-${n}`, transition: o = !1, ...i } = e, [{ dialogState: s }, a] = Rt("Dialog.Panel"), l = he(t, a.panelRef), u = j(() => ({ open: s === 0 }), [s]), d = X((c) => {
|
|
2261
2261
|
c.stopPropagation();
|
|
2262
2262
|
});
|
|
2263
|
-
return A.createElement(o ? Ln :
|
|
2263
|
+
return A.createElement(o ? Ln : G, null, ae({ ourProps: { ref: l, id: r, onClick: d }, theirProps: i, slot: u, defaultTag: wa, name: "Dialog.Panel" }));
|
|
2264
2264
|
}
|
|
2265
2265
|
let Ea = "div";
|
|
2266
2266
|
function $a(e, t) {
|
|
2267
|
-
let { transition: n = !1, ...r } = e, [{ dialogState: o }] = Rt("Dialog.Backdrop"), i =
|
|
2268
|
-
return A.createElement(n ? Ln :
|
|
2267
|
+
let { transition: n = !1, ...r } = e, [{ dialogState: o }] = Rt("Dialog.Backdrop"), i = j(() => ({ open: o === 0 }), [o]);
|
|
2268
|
+
return A.createElement(n ? Ln : G, null, ae({ ourProps: { ref: t, "aria-hidden": !0 }, theirProps: r, slot: i, defaultTag: Ea, name: "Dialog.Backdrop" }));
|
|
2269
2269
|
}
|
|
2270
2270
|
let Ta = "h2";
|
|
2271
2271
|
function ka(e, t) {
|
|
2272
2272
|
let n = ke(), { id: r = `headlessui-dialog-title-${n}`, ...o } = e, [{ dialogState: i, setTitleId: s }] = Rt("Dialog.Title"), a = he(t);
|
|
2273
|
-
|
|
2274
|
-
let l =
|
|
2273
|
+
W(() => (s(r), () => s(null)), [r, s]);
|
|
2274
|
+
let l = j(() => ({ open: i === 0 }), [i]);
|
|
2275
2275
|
return ae({ ourProps: { ref: a, id: r }, theirProps: o, slot: l, defaultTag: Ta, name: "Dialog.Title" });
|
|
2276
2276
|
}
|
|
2277
2277
|
let Sa = oe(ga), Ho = oe(ba);
|
|
@@ -2294,7 +2294,7 @@ const xa = "_root_1duny_1", Ma = "_modal_1duny_10", Pa = "_container_1duny_13",
|
|
|
2294
2294
|
strokeWidth: i,
|
|
2295
2295
|
className: s = "",
|
|
2296
2296
|
viewBox: a = "0 0 20 20"
|
|
2297
|
-
} = e, l =
|
|
2297
|
+
} = e, l = j(() => {
|
|
2298
2298
|
switch (n) {
|
|
2299
2299
|
case "sm":
|
|
2300
2300
|
return "yvlw-w-4 yvlw-h-4";
|
|
@@ -2448,13 +2448,13 @@ function ja(e) {
|
|
|
2448
2448
|
for (let d = 1; d < n - 1; d++)
|
|
2449
2449
|
for (let c = 1; c < t - 1; c++) {
|
|
2450
2450
|
let f = 0, p = 0, _ = 0, y = 0;
|
|
2451
|
-
for (let
|
|
2451
|
+
for (let m = -1; m <= 1; m++)
|
|
2452
2452
|
for (let g = -1; g <= 1; g++) {
|
|
2453
|
-
const
|
|
2454
|
-
f += r[
|
|
2453
|
+
const E = ((d + m) * t + (c + g)) * 4, $ = s[y++];
|
|
2454
|
+
f += r[E] * $, p += r[E + 1] * $, _ += r[E + 2] * $;
|
|
2455
2455
|
}
|
|
2456
|
-
const
|
|
2457
|
-
o +=
|
|
2456
|
+
const v = 0.299 * f + 0.587 * p + 0.114 * _;
|
|
2457
|
+
o += v, i += v * v;
|
|
2458
2458
|
}
|
|
2459
2459
|
const a = (t - 2) * (n - 2);
|
|
2460
2460
|
if (a === 0) return 0;
|
|
@@ -2472,9 +2472,9 @@ function Ba() {
|
|
|
2472
2472
|
function zo(e = {}) {
|
|
2473
2473
|
const { onRecord: t = () => {
|
|
2474
2474
|
}, onStop: n = () => {
|
|
2475
|
-
} } = e, r =
|
|
2475
|
+
} } = e, r = w([]), o = w(null), i = w(null), s = V((f) => {
|
|
2476
2476
|
r.current.push(f);
|
|
2477
|
-
}, []), a =
|
|
2477
|
+
}, []), a = V(
|
|
2478
2478
|
async (f) => {
|
|
2479
2479
|
if (o.current)
|
|
2480
2480
|
return;
|
|
@@ -2482,10 +2482,10 @@ function zo(e = {}) {
|
|
|
2482
2482
|
f instanceof ImageData ? p = await new Promise((_) => {
|
|
2483
2483
|
const y = document.createElement("canvas");
|
|
2484
2484
|
y.width = f.width, y.height = f.height;
|
|
2485
|
-
const
|
|
2486
|
-
|
|
2487
|
-
(
|
|
2488
|
-
_(
|
|
2485
|
+
const v = y.getContext("2d");
|
|
2486
|
+
v ? (v.putImageData(f, 0, 0), y.toBlob(
|
|
2487
|
+
(m) => {
|
|
2488
|
+
_(m);
|
|
2489
2489
|
},
|
|
2490
2490
|
"image/jpeg",
|
|
2491
2491
|
0.95
|
|
@@ -2493,13 +2493,13 @@ function zo(e = {}) {
|
|
|
2493
2493
|
}) : p = await Va(f), p && (o.current = p);
|
|
2494
2494
|
},
|
|
2495
2495
|
[]
|
|
2496
|
-
), l =
|
|
2496
|
+
), l = V(() => {
|
|
2497
2497
|
o.current = null;
|
|
2498
|
-
}, []), u =
|
|
2498
|
+
}, []), u = V((f) => {
|
|
2499
2499
|
f.data.size > 0 && t(f.data);
|
|
2500
|
-
}, []), d =
|
|
2500
|
+
}, []), d = V(() => {
|
|
2501
2501
|
!i.current || i.current.state === "inactive" || (i.current.stop(), i.current.stream.getTracks().forEach((f) => f.stop()), n());
|
|
2502
|
-
}, []), c =
|
|
2502
|
+
}, []), c = V((f) => {
|
|
2503
2503
|
i.current || (i.current = new MediaRecorder(
|
|
2504
2504
|
f,
|
|
2505
2505
|
Ba()
|
|
@@ -2556,7 +2556,7 @@ function Ka(e, t, n, r) {
|
|
|
2556
2556
|
sessionId: _
|
|
2557
2557
|
} = l, y = new FormData();
|
|
2558
2558
|
y.append("files", u), y.append("files", p);
|
|
2559
|
-
const
|
|
2559
|
+
const v = await fetch(
|
|
2560
2560
|
`${qa}/v1/uploads/media`,
|
|
2561
2561
|
{
|
|
2562
2562
|
method: "POST",
|
|
@@ -2566,27 +2566,27 @@ function Ka(e, t, n, r) {
|
|
|
2566
2566
|
body: y
|
|
2567
2567
|
}
|
|
2568
2568
|
);
|
|
2569
|
-
if (!
|
|
2570
|
-
throw
|
|
2571
|
-
const
|
|
2569
|
+
if (!v.ok)
|
|
2570
|
+
throw v;
|
|
2571
|
+
const m = (await v.json()).data, g = {
|
|
2572
2572
|
sessionId: _,
|
|
2573
2573
|
components: ["liveness"],
|
|
2574
|
-
faceImage:
|
|
2575
|
-
livenessClip:
|
|
2574
|
+
faceImage: m[0].cachedLocation,
|
|
2575
|
+
livenessClip: m[1].cachedLocation,
|
|
2576
2576
|
passed: c,
|
|
2577
2577
|
metadata: f
|
|
2578
2578
|
};
|
|
2579
2579
|
d && (g.publicMerchantID = d);
|
|
2580
|
-
const
|
|
2580
|
+
const E = await fetch(`${o}/v1/sdk/identity/liveness/`, {
|
|
2581
2581
|
method: "POST",
|
|
2582
2582
|
headers: {
|
|
2583
2583
|
"Content-Type": "application/json"
|
|
2584
2584
|
},
|
|
2585
2585
|
body: JSON.stringify(g)
|
|
2586
2586
|
});
|
|
2587
|
-
if (
|
|
2588
|
-
throw
|
|
2589
|
-
return (await
|
|
2587
|
+
if (!E.ok)
|
|
2588
|
+
throw E;
|
|
2589
|
+
return (await E.json()).data;
|
|
2590
2590
|
}, fetchSessionToken: async () => {
|
|
2591
2591
|
throw new Error(
|
|
2592
2592
|
"fetchSessionToken is deprecated. Provide sessionToken from your backend."
|
|
@@ -2729,24 +2729,24 @@ function tl(e) {
|
|
|
2729
2729
|
isMobileAppWebView: p = !1,
|
|
2730
2730
|
sessionId: _,
|
|
2731
2731
|
sessionToken: y,
|
|
2732
|
-
forceDevUrl:
|
|
2733
|
-
} = e, [
|
|
2732
|
+
forceDevUrl: v
|
|
2733
|
+
} = e, [m, g] = x(0), [E, $] = x(0), [S, M] = x(null), [R, U] = x(!1), { saveStream: F, savePhoto: b, savedPhoto: I, clearSavedPhoto: B, savedStreams: D } = zo(), { postData: K, validateSessionId: Q } = Ka(
|
|
2734
2734
|
f,
|
|
2735
|
-
|
|
2735
|
+
v,
|
|
2736
2736
|
t,
|
|
2737
2737
|
u
|
|
2738
|
-
), Z =
|
|
2739
|
-
() =>
|
|
2740
|
-
[n,
|
|
2741
|
-
),
|
|
2742
|
-
|
|
2743
|
-
},
|
|
2744
|
-
const
|
|
2745
|
-
|
|
2746
|
-
const
|
|
2747
|
-
$e.detectFaces(
|
|
2738
|
+
), Z = w(!1), k = j(
|
|
2739
|
+
() => E === n.length,
|
|
2740
|
+
[n, E]
|
|
2741
|
+
), C = () => {
|
|
2742
|
+
$((P) => P + 1), g((P) => P + 1);
|
|
2743
|
+
}, L = (P) => {
|
|
2744
|
+
const O = new Image();
|
|
2745
|
+
O.crossOrigin = "Anonymous", O.src = Ja, O.onload = () => {
|
|
2746
|
+
const q = Rn(O, O.width, O.height);
|
|
2747
|
+
$e.detectFaces(P, q);
|
|
2748
2748
|
};
|
|
2749
|
-
},
|
|
2749
|
+
}, N = async () => {
|
|
2750
2750
|
if (!I.current) {
|
|
2751
2751
|
u({
|
|
2752
2752
|
faceImage: "",
|
|
@@ -2759,44 +2759,47 @@ function tl(e) {
|
|
|
2759
2759
|
}), a();
|
|
2760
2760
|
return;
|
|
2761
2761
|
}
|
|
2762
|
-
|
|
2763
|
-
|
|
2764
|
-
|
|
2765
|
-
|
|
2766
|
-
|
|
2767
|
-
|
|
2768
|
-
|
|
2769
|
-
|
|
2770
|
-
|
|
2771
|
-
|
|
2772
|
-
|
|
2773
|
-
|
|
2774
|
-
|
|
2775
|
-
|
|
2776
|
-
|
|
2777
|
-
|
|
2778
|
-
|
|
2779
|
-
|
|
2780
|
-
|
|
2781
|
-
|
|
2782
|
-
|
|
2783
|
-
|
|
2784
|
-
|
|
2785
|
-
|
|
2786
|
-
|
|
2787
|
-
|
|
2788
|
-
|
|
2789
|
-
|
|
2790
|
-
|
|
2791
|
-
|
|
2792
|
-
|
|
2793
|
-
|
|
2794
|
-
|
|
2795
|
-
|
|
2796
|
-
|
|
2797
|
-
|
|
2762
|
+
if (!Z.current) {
|
|
2763
|
+
Z.current = !0;
|
|
2764
|
+
try {
|
|
2765
|
+
const P = await K({
|
|
2766
|
+
faceImage: I.current,
|
|
2767
|
+
video: new Blob(D.current, { type: "video/mp4" }),
|
|
2768
|
+
publicKey: t,
|
|
2769
|
+
passed: !0,
|
|
2770
|
+
metadata: d,
|
|
2771
|
+
sessionId: _
|
|
2772
|
+
});
|
|
2773
|
+
l(P), a();
|
|
2774
|
+
} catch (P) {
|
|
2775
|
+
let O = {
|
|
2776
|
+
key: "API_ERROR",
|
|
2777
|
+
message: "Failed to process liveness check. Please try again."
|
|
2778
|
+
};
|
|
2779
|
+
if (P instanceof Response)
|
|
2780
|
+
try {
|
|
2781
|
+
const z = await P.json();
|
|
2782
|
+
O = {
|
|
2783
|
+
key: z.name || "API_ERROR",
|
|
2784
|
+
message: z.message || "Failed to process liveness check. Please try again.",
|
|
2785
|
+
statusCode: z.statusCode || P.status,
|
|
2786
|
+
name: z.name,
|
|
2787
|
+
success: z.success,
|
|
2788
|
+
data: z.data
|
|
2789
|
+
};
|
|
2790
|
+
} catch {
|
|
2791
|
+
O.message = P.statusText || O.message, O.statusCode = P.status;
|
|
2792
|
+
}
|
|
2793
|
+
else P instanceof Error && (O.message = P.message);
|
|
2794
|
+
throw u({
|
|
2795
|
+
faceImage: "",
|
|
2796
|
+
passed: !1,
|
|
2797
|
+
metadata: d,
|
|
2798
|
+
error: O
|
|
2799
|
+
}), a(), new Error(O.message);
|
|
2800
|
+
}
|
|
2798
2801
|
}
|
|
2799
|
-
},
|
|
2802
|
+
}, T = async () => {
|
|
2800
2803
|
try {
|
|
2801
2804
|
if (!_)
|
|
2802
2805
|
throw new Error("sessionId is required. Provide it from your backend.");
|
|
@@ -2805,28 +2808,28 @@ function tl(e) {
|
|
|
2805
2808
|
"sessionToken is required. Provide it from your backend."
|
|
2806
2809
|
);
|
|
2807
2810
|
await Q(_);
|
|
2808
|
-
} catch (
|
|
2809
|
-
const
|
|
2811
|
+
} catch (O) {
|
|
2812
|
+
const q = O instanceof Error ? O.message : "Invalid or expired sessionId";
|
|
2810
2813
|
u({
|
|
2811
2814
|
faceImage: "",
|
|
2812
2815
|
passed: !1,
|
|
2813
2816
|
metadata: d,
|
|
2814
2817
|
error: {
|
|
2815
2818
|
key: "invalid_or_expired_session",
|
|
2816
|
-
message:
|
|
2819
|
+
message: q
|
|
2817
2820
|
}
|
|
2818
2821
|
});
|
|
2819
2822
|
return;
|
|
2820
2823
|
}
|
|
2821
|
-
const
|
|
2822
|
-
pr =
|
|
2824
|
+
const P = await $e.loadDetector();
|
|
2825
|
+
pr = P, L(P), M(P);
|
|
2823
2826
|
};
|
|
2824
|
-
return
|
|
2827
|
+
return W(() => {
|
|
2825
2828
|
if (hr) {
|
|
2826
2829
|
M(pr);
|
|
2827
2830
|
return;
|
|
2828
2831
|
}
|
|
2829
|
-
|
|
2832
|
+
T(), hr = !0;
|
|
2830
2833
|
}, []), /* @__PURE__ */ h(
|
|
2831
2834
|
Vo.Provider,
|
|
2832
2835
|
{
|
|
@@ -2834,10 +2837,10 @@ function tl(e) {
|
|
|
2834
2837
|
tasks: n,
|
|
2835
2838
|
namespace: o,
|
|
2836
2839
|
user: i,
|
|
2837
|
-
currentTaskIndex:
|
|
2838
|
-
completed:
|
|
2839
|
-
completedCount:
|
|
2840
|
-
nextTask:
|
|
2840
|
+
currentTaskIndex: m,
|
|
2841
|
+
completed: k,
|
|
2842
|
+
completedCount: E,
|
|
2843
|
+
nextTask: C,
|
|
2841
2844
|
branding: {
|
|
2842
2845
|
name: (s == null ? void 0 : s.name) ?? "Youverify",
|
|
2843
2846
|
color: (s == null ? void 0 : s.color) ?? void 0,
|
|
@@ -2851,13 +2854,13 @@ function tl(e) {
|
|
|
2851
2854
|
onRequestClose: a,
|
|
2852
2855
|
faceDetector: S,
|
|
2853
2856
|
saveStream: F,
|
|
2854
|
-
savePhoto:
|
|
2857
|
+
savePhoto: b,
|
|
2855
2858
|
clearSavedPhoto: B,
|
|
2856
|
-
onComplete:
|
|
2859
|
+
onComplete: N,
|
|
2857
2860
|
onFailure: u,
|
|
2858
2861
|
presentation: c,
|
|
2859
2862
|
imageCaptured: R,
|
|
2860
|
-
setImageCaptured:
|
|
2863
|
+
setImageCaptured: U,
|
|
2861
2864
|
sandboxEnvironment: f,
|
|
2862
2865
|
publicKey: t,
|
|
2863
2866
|
isMobileAppWebView: p,
|
|
@@ -2883,12 +2886,12 @@ const nl = "_root_vqy7d_1", rl = "_container_vqy7d_4", ol = "_lhs_vqy7d_7", il =
|
|
|
2883
2886
|
avatar: ul,
|
|
2884
2887
|
main: dl,
|
|
2885
2888
|
content: fl
|
|
2886
|
-
}, pl = "_root_lryhb_1", hl = "_container_lryhb_1",
|
|
2889
|
+
}, pl = "_root_lryhb_1", hl = "_container_lryhb_1", ml = "_brand_lryhb_6", jt = {
|
|
2887
2890
|
root: pl,
|
|
2888
2891
|
container: hl,
|
|
2889
|
-
brand:
|
|
2892
|
+
brand: ml
|
|
2890
2893
|
};
|
|
2891
|
-
function
|
|
2894
|
+
function vl() {
|
|
2892
2895
|
const { branding: e, isMobileAppWebView: t, onRequestClose: n, presentation: r } = fe();
|
|
2893
2896
|
return /* @__PURE__ */ h("div", { className: jt.root, children: /* @__PURE__ */ h("div", { className: jt.container, children: [
|
|
2894
2897
|
/* @__PURE__ */ h("div", { className: jt.brand, children: (e == null ? void 0 : e.logo) && !(e.hideLogoOnMobile && t) && /* @__PURE__ */ h(
|
|
@@ -2910,10 +2913,10 @@ function ml() {
|
|
|
2910
2913
|
)
|
|
2911
2914
|
] }) });
|
|
2912
2915
|
}
|
|
2913
|
-
const
|
|
2916
|
+
const mr = "colorScheme";
|
|
2914
2917
|
function jo() {
|
|
2915
|
-
const { namespace: e } = fe(), t = () => localStorage.getItem(
|
|
2916
|
-
o && localStorage.setItem(
|
|
2918
|
+
const { namespace: e } = fe(), t = () => localStorage.getItem(mr), n = (o = null) => {
|
|
2919
|
+
o && localStorage.setItem(mr, o);
|
|
2917
2920
|
const i = `${e}-color-scheme`, s = document.documentElement;
|
|
2918
2921
|
o && o === "dark" ? s == null || s.setAttribute(i, "dark") : s == null || s.removeAttribute(i);
|
|
2919
2922
|
};
|
|
@@ -2932,7 +2935,7 @@ function gl() {
|
|
|
2932
2935
|
function ut(e) {
|
|
2933
2936
|
const { children: t, onStream: n = () => {
|
|
2934
2937
|
}, onRecord: r = () => {
|
|
2935
|
-
} } = e, o =
|
|
2938
|
+
} } = e, o = w(null), i = w(0), s = w(null), { start: a, stop: l } = zo({
|
|
2936
2939
|
onRecord: r
|
|
2937
2940
|
}), u = async () => {
|
|
2938
2941
|
try {
|
|
@@ -2947,7 +2950,7 @@ function ut(e) {
|
|
|
2947
2950
|
}, c = () => {
|
|
2948
2951
|
n(o), i.current = requestAnimationFrame(c);
|
|
2949
2952
|
};
|
|
2950
|
-
return
|
|
2953
|
+
return W(() => {
|
|
2951
2954
|
const f = o.current;
|
|
2952
2955
|
if (!f)
|
|
2953
2956
|
return;
|
|
@@ -2968,14 +2971,14 @@ const wl = "_container_mcmsr_1", bl = "_focused_mcmsr_12", El = "_progress_mcmsr
|
|
|
2968
2971
|
progress: El,
|
|
2969
2972
|
completed: $l,
|
|
2970
2973
|
marker: Tl
|
|
2971
|
-
},
|
|
2974
|
+
}, vr = 360, kl = 50;
|
|
2972
2975
|
function Sl(e) {
|
|
2973
2976
|
const {
|
|
2974
2977
|
visitedSections: t,
|
|
2975
2978
|
sectionsCount: n,
|
|
2976
2979
|
faceDetected: r,
|
|
2977
2980
|
divisions: o = kl
|
|
2978
|
-
} = e, i =
|
|
2981
|
+
} = e, i = j(() => {
|
|
2979
2982
|
const s = [Ke.container];
|
|
2980
2983
|
return r && s.push(Ke.focused), s.join(" ");
|
|
2981
2984
|
}, [r]);
|
|
@@ -2993,8 +2996,8 @@ function Sl(e) {
|
|
|
2993
2996
|
enterTo: "yvlw-scale-100 yvlw-opacity-100",
|
|
2994
2997
|
className: "yvlw-absolute",
|
|
2995
2998
|
children: /* @__PURE__ */ h("div", { className: Ke.progress, children: Array.from(Array(o).keys()).map((s) => {
|
|
2996
|
-
const a = s *
|
|
2997
|
-
(a + 1) * n /
|
|
2999
|
+
const a = s * vr / o, l = Math.ceil(
|
|
3000
|
+
(a + 1) * n / vr
|
|
2998
3001
|
), u = t.includes(l), d = u ? s - (l - 1) * (o / n) : 0, c = [];
|
|
2999
3002
|
u && c.push(Ke.completed);
|
|
3000
3003
|
const f = u ? "translateX(158px)" : "translateX(150px)";
|
|
@@ -3056,7 +3059,7 @@ function It(e = {}) {
|
|
|
3056
3059
|
},
|
|
3057
3060
|
onError: o = () => {
|
|
3058
3061
|
}
|
|
3059
|
-
} = e, { faceDetector: i } = fe(), { checkFacialFeatures: s, checkZoomLevel: a, checkInFrame: l } = Bo(), u =
|
|
3062
|
+
} = e, { faceDetector: i } = fe(), { checkFacialFeatures: s, checkZoomLevel: a, checkInFrame: l } = Bo(), u = w(null), d = (f) => {
|
|
3060
3063
|
var p;
|
|
3061
3064
|
try {
|
|
3062
3065
|
if (f.length === 0)
|
|
@@ -3066,18 +3069,18 @@ function It(e = {}) {
|
|
|
3066
3069
|
const _ = u.current, y = (p = u.current) == null ? void 0 : p.parentElement;
|
|
3067
3070
|
if (!_ || !y)
|
|
3068
3071
|
return;
|
|
3069
|
-
const
|
|
3070
|
-
for (const
|
|
3071
|
-
switch (
|
|
3072
|
+
const v = f[0];
|
|
3073
|
+
for (const m of t)
|
|
3074
|
+
switch (m) {
|
|
3072
3075
|
case "zoom":
|
|
3073
3076
|
a(
|
|
3074
|
-
|
|
3077
|
+
v,
|
|
3075
3078
|
Math.min(y.clientHeight, y.clientWidth)
|
|
3076
3079
|
);
|
|
3077
3080
|
break;
|
|
3078
3081
|
case "features":
|
|
3079
3082
|
s(
|
|
3080
|
-
|
|
3083
|
+
v,
|
|
3081
3084
|
Math.min(y.clientHeight, y.clientWidth)
|
|
3082
3085
|
);
|
|
3083
3086
|
break;
|
|
@@ -3087,7 +3090,7 @@ function It(e = {}) {
|
|
|
3087
3090
|
"Frame size is required to check if face is in frame"
|
|
3088
3091
|
);
|
|
3089
3092
|
const g = n + 200;
|
|
3090
|
-
l(
|
|
3093
|
+
l(v, {
|
|
3091
3094
|
x: (y.clientWidth - g) / 2,
|
|
3092
3095
|
y: (y.clientHeight - g) / 2,
|
|
3093
3096
|
width: g,
|
|
@@ -3099,7 +3102,7 @@ function It(e = {}) {
|
|
|
3099
3102
|
default:
|
|
3100
3103
|
break;
|
|
3101
3104
|
}
|
|
3102
|
-
r(
|
|
3105
|
+
r(v);
|
|
3103
3106
|
} catch (_) {
|
|
3104
3107
|
const { message: y } = _;
|
|
3105
3108
|
o(y);
|
|
@@ -3113,15 +3116,15 @@ function It(e = {}) {
|
|
|
3113
3116
|
const _ = u.current;
|
|
3114
3117
|
if (!_)
|
|
3115
3118
|
throw new Error("No Video Source detected");
|
|
3116
|
-
const { videoWidth: y, videoHeight:
|
|
3117
|
-
if (y === 0 ||
|
|
3119
|
+
const { videoWidth: y, videoHeight: v } = _;
|
|
3120
|
+
if (y === 0 || v === 0)
|
|
3118
3121
|
return;
|
|
3119
|
-
const
|
|
3122
|
+
const m = Rn(
|
|
3120
3123
|
_,
|
|
3121
3124
|
y,
|
|
3122
|
-
|
|
3125
|
+
v
|
|
3123
3126
|
// frameSize,
|
|
3124
|
-
), g = await $e.detectFaces(i,
|
|
3127
|
+
), g = await $e.detectFaces(i, m);
|
|
3125
3128
|
d(g.faces);
|
|
3126
3129
|
} };
|
|
3127
3130
|
}
|
|
@@ -3190,15 +3193,15 @@ function Dt(e) {
|
|
|
3190
3193
|
},
|
|
3191
3194
|
onReset: s = () => {
|
|
3192
3195
|
}
|
|
3193
|
-
} = e, [a, l] = x(!1), { completedCount: u, tasks: d, nextTask: c, branding: f, isMobileAppWebView: p } = fe(), _ =
|
|
3196
|
+
} = e, [a, l] = x(!1), { completedCount: u, tasks: d, nextTask: c, branding: f, isMobileAppWebView: p } = fe(), _ = j(
|
|
3194
3197
|
() => u * 100 / d.length,
|
|
3195
3198
|
[u, d.length]
|
|
3196
3199
|
);
|
|
3197
|
-
return
|
|
3200
|
+
return W(() => {
|
|
3198
3201
|
!r && !o && (async () => {
|
|
3199
3202
|
await i(), l(!0);
|
|
3200
3203
|
})();
|
|
3201
|
-
}, []),
|
|
3204
|
+
}, []), W(() => {
|
|
3202
3205
|
r && (() => {
|
|
3203
3206
|
c();
|
|
3204
3207
|
})();
|
|
@@ -3272,16 +3275,16 @@ function Dt(e) {
|
|
|
3272
3275
|
}
|
|
3273
3276
|
function Ot(e = {}) {
|
|
3274
3277
|
const { timeout: t, onTimeout: n = () => {
|
|
3275
|
-
} } = e, [r, o] = x(!1), i =
|
|
3278
|
+
} } = e, [r, o] = x(!1), i = w(null), s = V(() => {
|
|
3276
3279
|
t && i.current && clearTimeout(i.current);
|
|
3277
|
-
}, []), a =
|
|
3280
|
+
}, []), a = V(() => {
|
|
3278
3281
|
t && (i.current = setTimeout(() => {
|
|
3279
3282
|
o(!0), n();
|
|
3280
3283
|
}, t));
|
|
3281
|
-
}, []), l =
|
|
3284
|
+
}, []), l = V(() => {
|
|
3282
3285
|
o(!1), a();
|
|
3283
3286
|
}, []);
|
|
3284
|
-
return
|
|
3287
|
+
return W(() => s, []), {
|
|
3285
3288
|
timedOut: r,
|
|
3286
3289
|
reset: l,
|
|
3287
3290
|
start: a,
|
|
@@ -3290,22 +3293,22 @@ function Ot(e = {}) {
|
|
|
3290
3293
|
}
|
|
3291
3294
|
const Ul = 1, Bt = 8, Er = "Place face in frame";
|
|
3292
3295
|
function zl(e) {
|
|
3293
|
-
const { difficulty: t, timeout: n } = e, { saveStream: r } = fe(), [o, i] = x([]), [s, a] = x(Er), [l, u] = x(!1), [d, c] = x(!1), f =
|
|
3296
|
+
const { difficulty: t, timeout: n } = e, { saveStream: r } = fe(), [o, i] = x([]), [s, a] = x(Er), [l, u] = x(!1), [d, c] = x(!1), f = w(/* @__PURE__ */ new Set()), p = w(!1), _ = w(null), {
|
|
3294
3297
|
reset: y,
|
|
3295
|
-
start:
|
|
3296
|
-
stop:
|
|
3298
|
+
start: v,
|
|
3299
|
+
stop: m,
|
|
3297
3300
|
timedOut: g
|
|
3298
|
-
} = Ot({ timeout: n }),
|
|
3301
|
+
} = Ot({ timeout: n }), E = () => {
|
|
3299
3302
|
i([]), a(Er), u(!1), c(!1), f.current = /* @__PURE__ */ new Set(), p.current = !1, _.current = null, y();
|
|
3300
|
-
},
|
|
3301
|
-
const I =
|
|
3302
|
-
f.current.has(B) || (f.current.add(B), i(Array.from(f.current))), f.current.size >= Bt && (
|
|
3303
|
+
}, $ = (b) => {
|
|
3304
|
+
const I = b * Bt, B = Math.ceil((I + 1) / Xa);
|
|
3305
|
+
f.current.has(B) || (f.current.add(B), i(Array.from(f.current))), f.current.size >= Bt && (m(), setTimeout(() => {
|
|
3303
3306
|
c(!0);
|
|
3304
3307
|
}, 1e3));
|
|
3305
|
-
}, S = (
|
|
3306
|
-
let D = Math.atan2(I,
|
|
3308
|
+
}, S = (b, I) => {
|
|
3309
|
+
let D = Math.atan2(I, b) * (180 / Math.PI);
|
|
3307
3310
|
return D < 0 && (D += 360), D;
|
|
3308
|
-
}, M =
|
|
3311
|
+
}, M = V(() => {
|
|
3309
3312
|
if (f.current.size === 0)
|
|
3310
3313
|
return 25;
|
|
3311
3314
|
switch (t) {
|
|
@@ -3316,22 +3319,22 @@ function zl(e) {
|
|
|
3316
3319
|
default:
|
|
3317
3320
|
return 10;
|
|
3318
3321
|
}
|
|
3319
|
-
}, []), R = (
|
|
3320
|
-
const { keypoints: I, box: B } =
|
|
3322
|
+
}, []), R = (b) => {
|
|
3323
|
+
const { keypoints: I, box: B } = b, D = { x: B.width * 0.5, y: B.height * 0.5 }, K = I[Ul], Q = { y: K.y - B.yMin, x: K.x - B.xMin }, Z = D.x - Q.x, k = Q.y - D.y, C = M();
|
|
3321
3324
|
return Math.abs(Z) < C && Math.abs(k) < C ? null : S(Z, k);
|
|
3322
|
-
}, { detectFaces:
|
|
3325
|
+
}, { detectFaces: U } = It({
|
|
3323
3326
|
frameSize: 280,
|
|
3324
3327
|
validations: ["zoom", "in-frame"],
|
|
3325
|
-
onFace: (
|
|
3328
|
+
onFace: (b) => {
|
|
3326
3329
|
u(!0), a("Slowly move head around to complete circle");
|
|
3327
|
-
const I = R(
|
|
3328
|
-
I &&
|
|
3330
|
+
const I = R(b);
|
|
3331
|
+
I && $(I);
|
|
3329
3332
|
},
|
|
3330
|
-
onError: (
|
|
3331
|
-
a(
|
|
3333
|
+
onError: (b) => {
|
|
3334
|
+
a(b), i([]), f.current.clear(), _.current = null, p.current = !1;
|
|
3332
3335
|
}
|
|
3333
3336
|
});
|
|
3334
|
-
return /* @__PURE__ */ h(
|
|
3337
|
+
return /* @__PURE__ */ h(G, { children: /* @__PURE__ */ h(
|
|
3335
3338
|
Dt,
|
|
3336
3339
|
{
|
|
3337
3340
|
instruction: {
|
|
@@ -3341,14 +3344,14 @@ function zl(e) {
|
|
|
3341
3344
|
name: "complete-the-circle",
|
|
3342
3345
|
completed: d,
|
|
3343
3346
|
failed: g,
|
|
3344
|
-
onReset:
|
|
3345
|
-
onStart:
|
|
3346
|
-
children: /* @__PURE__ */ h(ut, { onStream: (
|
|
3347
|
+
onReset: E,
|
|
3348
|
+
onStart: v,
|
|
3349
|
+
children: /* @__PURE__ */ h(ut, { onStream: (b) => {
|
|
3347
3350
|
try {
|
|
3348
|
-
if (!
|
|
3351
|
+
if (!b.current || d)
|
|
3349
3352
|
return;
|
|
3350
|
-
const { videoWidth: I } =
|
|
3351
|
-
|
|
3353
|
+
const { videoWidth: I } = b.current;
|
|
3354
|
+
U({ ref: b, frameSize: I });
|
|
3352
3355
|
} catch {
|
|
3353
3356
|
}
|
|
3354
3357
|
}, onRecord: r, children: /* @__PURE__ */ h(
|
|
@@ -3370,7 +3373,7 @@ const Vl = "_root_thujo_1", jl = "_sticker_thujo_4", Bl = "_no_thujo_7", ql = "_
|
|
|
3370
3373
|
};
|
|
3371
3374
|
function Yl(e) {
|
|
3372
3375
|
const { show: t, stickers: n } = e;
|
|
3373
|
-
return /* @__PURE__ */ h(
|
|
3376
|
+
return /* @__PURE__ */ h(G, { children: t && /* @__PURE__ */ h("div", { className: qt.root, children: n.map((r) => /* @__PURE__ */ h(
|
|
3374
3377
|
"div",
|
|
3375
3378
|
{
|
|
3376
3379
|
className: `${qt.sticker} ${qt[r]}`,
|
|
@@ -3385,26 +3388,26 @@ const Gl = {
|
|
|
3385
3388
|
answer: !0
|
|
3386
3389
|
}, Kl = "Wrong answer. Try again", $r = "Keep face in camera";
|
|
3387
3390
|
function Xl(e) {
|
|
3388
|
-
const { difficulty: t, questions: n = [Gl], timeout: r } = e, [o, i] = x($r), [s, a] = x(!1), [l, u] = x(!1), { saveStream: d } = fe(), c =
|
|
3391
|
+
const { difficulty: t, questions: n = [Gl], timeout: r } = e, [o, i] = x($r), [s, a] = x(!1), [l, u] = x(!1), { saveStream: d } = fe(), c = w("inactive"), f = w(0), p = w(!1), _ = w(null), y = w(null), v = w(null), m = () => {
|
|
3389
3392
|
_.current && clearTimeout(_.current), y.current && clearTimeout(y.current);
|
|
3390
3393
|
}, {
|
|
3391
3394
|
reset: g,
|
|
3392
|
-
start:
|
|
3393
|
-
stop:
|
|
3395
|
+
start: E,
|
|
3396
|
+
stop: $,
|
|
3394
3397
|
timedOut: S
|
|
3395
3398
|
} = Ot({
|
|
3396
3399
|
timeout: r,
|
|
3397
|
-
onTimeout:
|
|
3400
|
+
onTimeout: m
|
|
3398
3401
|
}), M = () => {
|
|
3399
3402
|
i($r), a(!1), u(!1), c.current = "inactive", f.current = 0, p.current = !1, g();
|
|
3400
3403
|
}, R = (D) => {
|
|
3401
|
-
const { keypoints:
|
|
3404
|
+
const { keypoints: K } = D, Q = K[1], Z = K[9], k = Q.x - Z.x, C = Q.y - Z.y;
|
|
3402
3405
|
return 90 - Math.atan2(C, k) * (180 / Math.PI);
|
|
3403
|
-
},
|
|
3406
|
+
}, U = (D) => {
|
|
3404
3407
|
c.current = "inactive", i(n[D].question), _.current = setTimeout(() => {
|
|
3405
3408
|
c.current = "active";
|
|
3406
3409
|
}, 2e3);
|
|
3407
|
-
}, F =
|
|
3410
|
+
}, F = j(() => {
|
|
3408
3411
|
switch (t) {
|
|
3409
3412
|
case "easy":
|
|
3410
3413
|
return 2;
|
|
@@ -3413,28 +3416,28 @@ function Xl(e) {
|
|
|
3413
3416
|
default:
|
|
3414
3417
|
return 4;
|
|
3415
3418
|
}
|
|
3416
|
-
}, []),
|
|
3419
|
+
}, []), b = (D) => {
|
|
3417
3420
|
try {
|
|
3418
3421
|
if (c.current = "inactive", Math.abs(D) < F)
|
|
3419
3422
|
throw new Error("Tilt head further to answer");
|
|
3420
|
-
const
|
|
3421
|
-
if (
|
|
3422
|
-
f.current += 1, f.current === n.length ? (u(!0),
|
|
3423
|
+
const K = D > 0, Q = n[f.current].answer;
|
|
3424
|
+
if (K === Q)
|
|
3425
|
+
f.current += 1, f.current === n.length ? (u(!0), $()) : U(f.current);
|
|
3423
3426
|
else
|
|
3424
3427
|
throw new Error(
|
|
3425
3428
|
n[f.current].errorMessage || Kl
|
|
3426
3429
|
);
|
|
3427
|
-
} catch (
|
|
3428
|
-
i(
|
|
3429
|
-
|
|
3430
|
+
} catch (K) {
|
|
3431
|
+
i(K.message), y.current = setTimeout(() => {
|
|
3432
|
+
U(f.current);
|
|
3430
3433
|
}, 2e3);
|
|
3431
3434
|
}
|
|
3432
3435
|
}, { detectFaces: I } = It({
|
|
3433
3436
|
onFace: (D) => {
|
|
3434
|
-
if (p.current || (a(!0), p.current = !0,
|
|
3437
|
+
if (p.current || (a(!0), p.current = !0, U(f.current)), c.current === "inactive")
|
|
3435
3438
|
return;
|
|
3436
|
-
const
|
|
3437
|
-
|
|
3439
|
+
const K = R(D);
|
|
3440
|
+
b(K);
|
|
3438
3441
|
},
|
|
3439
3442
|
onError: (D) => {
|
|
3440
3443
|
i(D);
|
|
@@ -3443,13 +3446,13 @@ function Xl(e) {
|
|
|
3443
3446
|
try {
|
|
3444
3447
|
if (!D.current || l)
|
|
3445
3448
|
return;
|
|
3446
|
-
|
|
3447
|
-
const { videoWidth:
|
|
3448
|
-
I({ ref: D, frameSize:
|
|
3449
|
+
v.current = D.current;
|
|
3450
|
+
const { videoWidth: K } = D.current;
|
|
3451
|
+
I({ ref: D, frameSize: K });
|
|
3449
3452
|
} catch {
|
|
3450
3453
|
}
|
|
3451
3454
|
};
|
|
3452
|
-
return
|
|
3455
|
+
return W(() => m, []), /* @__PURE__ */ h(
|
|
3453
3456
|
Dt,
|
|
3454
3457
|
{
|
|
3455
3458
|
instruction: {
|
|
@@ -3459,7 +3462,7 @@ function Xl(e) {
|
|
|
3459
3462
|
name: "yes-or-no",
|
|
3460
3463
|
failed: S,
|
|
3461
3464
|
onReset: M,
|
|
3462
|
-
onStart:
|
|
3465
|
+
onStart: E,
|
|
3463
3466
|
completed: l,
|
|
3464
3467
|
children: /* @__PURE__ */ h(ut, { onStream: B, onRecord: d, children: /* @__PURE__ */ h(Yl, { show: s, stickers: ["yes", "no"] }) })
|
|
3465
3468
|
}
|
|
@@ -3474,7 +3477,7 @@ function Zl(e = {}) {
|
|
|
3474
3477
|
gamma: o.gamma
|
|
3475
3478
|
});
|
|
3476
3479
|
};
|
|
3477
|
-
return
|
|
3480
|
+
return W(() => (window.addEventListener("deviceorientation", r), () => {
|
|
3478
3481
|
window.removeEventListener("deviceorientation", r);
|
|
3479
3482
|
}), []), {
|
|
3480
3483
|
canUse: n
|
|
@@ -3506,7 +3509,7 @@ const Ce = (e, t) => {
|
|
|
3506
3509
|
};
|
|
3507
3510
|
};
|
|
3508
3511
|
function ec(e) {
|
|
3509
|
-
const { total: t, onMessage: n, onComplete: r, difficulty: o } = e, i =
|
|
3512
|
+
const { total: t, onMessage: n, onComplete: r, difficulty: o } = e, i = w(null), s = w(!0), a = w(null), l = w(null), u = w(0), d = w(!1), c = j(() => {
|
|
3510
3513
|
switch (o) {
|
|
3511
3514
|
case "easy":
|
|
3512
3515
|
return 6;
|
|
@@ -3517,20 +3520,20 @@ function ec(e) {
|
|
|
3517
3520
|
}
|
|
3518
3521
|
}, []), f = () => {
|
|
3519
3522
|
if (u.current < t) {
|
|
3520
|
-
const
|
|
3521
|
-
let
|
|
3522
|
-
|
|
3523
|
+
const v = t - u.current;
|
|
3524
|
+
let m = `Nod head ${v} `;
|
|
3525
|
+
v < t && (m += "more "), m += v > 1 ? "times" : "time", n(m);
|
|
3523
3526
|
return;
|
|
3524
3527
|
}
|
|
3525
3528
|
d.current = !0, n("Great, hang on..."), setTimeout(() => {
|
|
3526
3529
|
r();
|
|
3527
3530
|
}, 500);
|
|
3528
3531
|
}, { canUse: p } = Zl({
|
|
3529
|
-
onChange: (
|
|
3530
|
-
l.current =
|
|
3532
|
+
onChange: (v) => {
|
|
3533
|
+
l.current = v;
|
|
3531
3534
|
}
|
|
3532
3535
|
});
|
|
3533
|
-
return { evaluate: (
|
|
3536
|
+
return { evaluate: (v) => {
|
|
3534
3537
|
if (!p) {
|
|
3535
3538
|
n("Cannot perform task. Transfer to mobile device to complete");
|
|
3536
3539
|
return;
|
|
@@ -3545,28 +3548,28 @@ function ec(e) {
|
|
|
3545
3548
|
}
|
|
3546
3549
|
if (d.current)
|
|
3547
3550
|
return;
|
|
3548
|
-
const { keypoints:
|
|
3549
|
-
|
|
3550
|
-
|
|
3551
|
-
),
|
|
3552
|
-
|
|
3553
|
-
|
|
3551
|
+
const { keypoints: m } = v, g = Ve(
|
|
3552
|
+
m[6].x - m[8].x,
|
|
3553
|
+
m[6].y - m[8].y
|
|
3554
|
+
), $ = Ve(
|
|
3555
|
+
m[2].x - m[1].x,
|
|
3556
|
+
m[2].y - m[1].y
|
|
3554
3557
|
) / g * 10;
|
|
3555
|
-
if (
|
|
3558
|
+
if ($ > c) {
|
|
3556
3559
|
if (i.current || !s.current)
|
|
3557
3560
|
return;
|
|
3558
|
-
i.current =
|
|
3561
|
+
i.current = $, s.current = !1, a.current = setTimeout(() => {
|
|
3559
3562
|
i.current = null;
|
|
3560
3563
|
}, 3e3);
|
|
3561
3564
|
} else
|
|
3562
|
-
i.current && i.current -
|
|
3565
|
+
i.current && i.current - $ > c / 2 && (u.current += 1, i.current = null, a.current && clearTimeout(a.current)), s.current = !0;
|
|
3563
3566
|
f();
|
|
3564
3567
|
}, reset: () => {
|
|
3565
3568
|
i.current = null, s.current = !0, a.current = null, l.current = null, u.current = 0, d.current = !1;
|
|
3566
3569
|
} };
|
|
3567
3570
|
}
|
|
3568
3571
|
function tc(e) {
|
|
3569
|
-
const { onMessage: t, onComplete: n, difficulty: r } = e, o =
|
|
3572
|
+
const { onMessage: t, onComplete: n, difficulty: r } = e, o = w(!1), i = j(() => {
|
|
3570
3573
|
switch (r) {
|
|
3571
3574
|
case "easy":
|
|
3572
3575
|
return 80;
|
|
@@ -3598,7 +3601,7 @@ function tc(e) {
|
|
|
3598
3601
|
} };
|
|
3599
3602
|
}
|
|
3600
3603
|
function Yo(e) {
|
|
3601
|
-
const { total: t, onMessage: n, onComplete: r, difficulty: o } = e, i =
|
|
3604
|
+
const { total: t, onMessage: n, onComplete: r, difficulty: o } = e, i = w(!0), s = w(!1), a = w(null), l = w(0), u = j(() => {
|
|
3602
3605
|
switch (o) {
|
|
3603
3606
|
case "easy":
|
|
3604
3607
|
return {
|
|
@@ -3620,14 +3623,14 @@ function Yo(e) {
|
|
|
3620
3623
|
i.current && (y >= u.closed || (i.current = !1, a.current = Date.now()));
|
|
3621
3624
|
}, c = (y) => {
|
|
3622
3625
|
if (!i.current && !(y < u.open) && (i.current = !0, a.current)) {
|
|
3623
|
-
const
|
|
3624
|
-
(
|
|
3626
|
+
const v = Date.now(), m = a.current;
|
|
3627
|
+
(v - m) / 1e3 <= 2 && (l.current += 1);
|
|
3625
3628
|
}
|
|
3626
3629
|
}, f = () => {
|
|
3627
3630
|
if (l.current < t) {
|
|
3628
3631
|
const y = t - l.current;
|
|
3629
|
-
let
|
|
3630
|
-
y < t && (
|
|
3632
|
+
let v = `Blink right eye ${y} `;
|
|
3633
|
+
y < t && (v += "more "), v += y > 1 ? "times" : "time", n(v);
|
|
3631
3634
|
return;
|
|
3632
3635
|
}
|
|
3633
3636
|
s.current = !0, n("Great, hang on..."), setTimeout(() => {
|
|
@@ -3637,14 +3640,14 @@ function Yo(e) {
|
|
|
3637
3640
|
return { evaluate: (y) => {
|
|
3638
3641
|
if (s.current)
|
|
3639
3642
|
return;
|
|
3640
|
-
const { keypoints:
|
|
3641
|
-
|
|
3642
|
-
|
|
3643
|
-
),
|
|
3644
|
-
|
|
3645
|
-
|
|
3646
|
-
) /
|
|
3647
|
-
d(
|
|
3643
|
+
const { keypoints: v } = y, m = Ve(
|
|
3644
|
+
v[6].x - v[8].x,
|
|
3645
|
+
v[6].y - v[8].y
|
|
3646
|
+
), E = Ve(
|
|
3647
|
+
v[145].x - v[159].x,
|
|
3648
|
+
v[145].y - v[159].y
|
|
3649
|
+
) / m * 100;
|
|
3650
|
+
d(E), c(E), f();
|
|
3648
3651
|
}, reset: () => {
|
|
3649
3652
|
i.current = !0, s.current = !1, a.current = null, l.current = 0;
|
|
3650
3653
|
} };
|
|
@@ -3652,53 +3655,53 @@ function Yo(e) {
|
|
|
3652
3655
|
var Go = /* @__PURE__ */ ((e) => (e.open_mouth = "open_mouth", e.blink = "blink", e))(Go || {});
|
|
3653
3656
|
const Tr = Jl(Object.keys(Go)), kr = "Keep face in camera";
|
|
3654
3657
|
function nc(e) {
|
|
3655
|
-
const { difficulty: t, maxBlinks: n = 3, maxNods: r = 3, timeout: o } = e, i =
|
|
3658
|
+
const { difficulty: t, maxBlinks: n = 3, maxNods: r = 3, timeout: o } = e, i = w(0), [s, a] = x(kr), [l, u] = x(!1), [d, c] = x(null), f = w(!1), { saveStream: p } = fe(), {
|
|
3656
3659
|
reset: _,
|
|
3657
3660
|
start: y,
|
|
3658
|
-
stop:
|
|
3659
|
-
timedOut:
|
|
3661
|
+
stop: v,
|
|
3662
|
+
timedOut: m
|
|
3660
3663
|
} = Ot({ timeout: o }), g = () => {
|
|
3661
3664
|
if (i.current === Tr.length - 1) {
|
|
3662
|
-
u(!0),
|
|
3665
|
+
u(!0), v();
|
|
3663
3666
|
return;
|
|
3664
3667
|
}
|
|
3665
3668
|
i.current += 1;
|
|
3666
|
-
},
|
|
3669
|
+
}, E = ec({
|
|
3667
3670
|
total: Math.floor(Math.random() * r + 1),
|
|
3668
3671
|
difficulty: t,
|
|
3669
|
-
onMessage: (
|
|
3672
|
+
onMessage: (b) => a(b),
|
|
3670
3673
|
onComplete: g
|
|
3671
|
-
}),
|
|
3674
|
+
}), $ = tc({
|
|
3672
3675
|
difficulty: t,
|
|
3673
|
-
onMessage: (
|
|
3676
|
+
onMessage: (b) => a(b),
|
|
3674
3677
|
onComplete: g
|
|
3675
3678
|
}), S = Yo({
|
|
3676
3679
|
total: Math.floor(Math.random() * n + 1),
|
|
3677
3680
|
difficulty: t,
|
|
3678
|
-
onMessage: (
|
|
3681
|
+
onMessage: (b) => a(b),
|
|
3679
3682
|
onComplete: g
|
|
3680
3683
|
}), { detectFaces: M } = It({
|
|
3681
|
-
onFace: (
|
|
3684
|
+
onFace: (b) => {
|
|
3682
3685
|
switch (f.current || (f.current = !0), Tr[i.current]) {
|
|
3683
3686
|
case "open_mouth":
|
|
3684
|
-
|
|
3687
|
+
$.evaluate(b);
|
|
3685
3688
|
break;
|
|
3686
3689
|
case "blink":
|
|
3687
|
-
S.evaluate(
|
|
3690
|
+
S.evaluate(b);
|
|
3688
3691
|
break;
|
|
3689
3692
|
}
|
|
3690
3693
|
},
|
|
3691
|
-
onError: (
|
|
3692
|
-
a(
|
|
3694
|
+
onError: (b) => {
|
|
3695
|
+
a(b);
|
|
3693
3696
|
}
|
|
3694
3697
|
}), R = () => {
|
|
3695
|
-
i.current = 0, a(kr), u(!1), f.current = !1, S.reset(),
|
|
3696
|
-
},
|
|
3698
|
+
i.current = 0, a(kr), u(!1), f.current = !1, S.reset(), E.reset(), $.reset(), _();
|
|
3699
|
+
}, U = async (b) => {
|
|
3697
3700
|
try {
|
|
3698
|
-
if (!
|
|
3701
|
+
if (!b.current || l)
|
|
3699
3702
|
return;
|
|
3700
|
-
const { videoWidth: I } =
|
|
3701
|
-
await M({ ref:
|
|
3703
|
+
const { videoWidth: I } = b.current;
|
|
3704
|
+
await M({ ref: b, frameSize: I, throttleInterval: 500 });
|
|
3702
3705
|
} catch {
|
|
3703
3706
|
}
|
|
3704
3707
|
}, F = async () => {
|
|
@@ -3711,40 +3714,40 @@ function nc(e) {
|
|
|
3711
3714
|
description: "Follow the directives as instructed"
|
|
3712
3715
|
},
|
|
3713
3716
|
name: "motions",
|
|
3714
|
-
failed:
|
|
3717
|
+
failed: m,
|
|
3715
3718
|
onReset: R,
|
|
3716
3719
|
completed: l,
|
|
3717
3720
|
onStart: async () => {
|
|
3718
3721
|
await F(), y();
|
|
3719
3722
|
},
|
|
3720
|
-
children: d ? /* @__PURE__ */ h(
|
|
3723
|
+
children: d ? /* @__PURE__ */ h(G, {}) : /* @__PURE__ */ h(ut, { onStream: U, onRecord: p })
|
|
3721
3724
|
}
|
|
3722
3725
|
);
|
|
3723
3726
|
}
|
|
3724
3727
|
const Sr = "Keep face in camera";
|
|
3725
3728
|
function rc(e) {
|
|
3726
|
-
const { difficulty: t, maxBlinks: n = 3, timeout: r } = e, [o, i] = x(Sr), [s, a] = x(!1), [l, u] = x(null), d =
|
|
3729
|
+
const { difficulty: t, maxBlinks: n = 3, timeout: r } = e, [o, i] = x(Sr), [s, a] = x(!1), [l, u] = x(null), d = w(!1), { saveStream: c } = fe(), {
|
|
3727
3730
|
reset: f,
|
|
3728
3731
|
start: p,
|
|
3729
3732
|
stop: _,
|
|
3730
3733
|
timedOut: y
|
|
3731
|
-
} = Ot({ timeout: r }),
|
|
3734
|
+
} = Ot({ timeout: r }), v = () => {
|
|
3732
3735
|
a(!0), _();
|
|
3733
|
-
},
|
|
3736
|
+
}, m = Yo({
|
|
3734
3737
|
total: Math.floor(Math.random() * n + 1),
|
|
3735
3738
|
difficulty: t,
|
|
3736
3739
|
onMessage: (M) => i(M),
|
|
3737
|
-
onComplete:
|
|
3740
|
+
onComplete: v
|
|
3738
3741
|
}), { detectFaces: g } = It({
|
|
3739
3742
|
onFace: (M) => {
|
|
3740
|
-
d.current || (d.current = !0),
|
|
3743
|
+
d.current || (d.current = !0), m.evaluate(M);
|
|
3741
3744
|
},
|
|
3742
3745
|
onError: (M) => {
|
|
3743
3746
|
i(M);
|
|
3744
3747
|
}
|
|
3745
|
-
}),
|
|
3746
|
-
i(Sr), a(!1), d.current = !1,
|
|
3747
|
-
},
|
|
3748
|
+
}), E = () => {
|
|
3749
|
+
i(Sr), a(!1), d.current = !1, m.reset(), f();
|
|
3750
|
+
}, $ = async (M) => {
|
|
3748
3751
|
try {
|
|
3749
3752
|
if (!M.current || s)
|
|
3750
3753
|
return;
|
|
@@ -3763,12 +3766,12 @@ function rc(e) {
|
|
|
3763
3766
|
},
|
|
3764
3767
|
name: "blink",
|
|
3765
3768
|
failed: y,
|
|
3766
|
-
onReset:
|
|
3769
|
+
onReset: E,
|
|
3767
3770
|
completed: s,
|
|
3768
3771
|
onStart: async () => {
|
|
3769
3772
|
await S(), p();
|
|
3770
3773
|
},
|
|
3771
|
-
children: l ? /* @__PURE__ */ h(
|
|
3774
|
+
children: l ? /* @__PURE__ */ h(G, {}) : /* @__PURE__ */ h(ut, { onStream: $, onRecord: c })
|
|
3772
3775
|
}
|
|
3773
3776
|
);
|
|
3774
3777
|
}
|
|
@@ -3776,24 +3779,24 @@ const Yt = {
|
|
|
3776
3779
|
LEFT_EYE: [36, 37, 38, 39, 40, 41],
|
|
3777
3780
|
RIGHT_EYE: [42, 43, 44, 45, 46, 47],
|
|
3778
3781
|
MOUTH: [48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59]
|
|
3779
|
-
},
|
|
3782
|
+
}, vt = (e, t) => Math.sqrt((e.x - t.x) ** 2 + (e.y - t.y) ** 2), Cr = (e) => {
|
|
3780
3783
|
if (e.length !== 6) return 0;
|
|
3781
|
-
const t =
|
|
3784
|
+
const t = vt(e[1], e[5]), n = vt(e[2], e[4]), r = vt(e[0], e[3]);
|
|
3782
3785
|
return (t + n) / (2 * r);
|
|
3783
3786
|
}, oc = (e) => {
|
|
3784
3787
|
if (e.length < 12) return 0;
|
|
3785
3788
|
const t = e[9], n = e[3];
|
|
3786
|
-
return
|
|
3789
|
+
return vt(t, n);
|
|
3787
3790
|
}, ic = (e, t, n, r) => {
|
|
3788
3791
|
var c, f, p;
|
|
3789
3792
|
let o = !0, i = !0;
|
|
3790
3793
|
if (!r) {
|
|
3791
|
-
const
|
|
3794
|
+
const v = Yt.LEFT_EYE.map(
|
|
3792
3795
|
(R) => e[R]
|
|
3793
|
-
),
|
|
3796
|
+
), m = Yt.RIGHT_EYE.map(
|
|
3794
3797
|
(R) => e[R]
|
|
3795
|
-
), g = Yt.MOUTH.map((R) => e[R]),
|
|
3796
|
-
o = (
|
|
3798
|
+
), g = Yt.MOUTH.map((R) => e[R]), E = Cr(v), $ = Cr(m), S = oc(g);
|
|
3799
|
+
o = (E + $) / 2 > 1, i = S < 73.24, o || t("Please look at the camera!"), i || t("Please close your mouth!");
|
|
3797
3800
|
}
|
|
3798
3801
|
const s = 0.5, a = 0.12, l = ((c = r == null ? void 0 : r.find((_) => _.categoryName === "eyeBlinkLeft")) == null ? void 0 : c.score) ?? 0, u = ((f = r == null ? void 0 : r.find((_) => _.categoryName === "eyeBlinkRight")) == null ? void 0 : f.score) ?? 0, d = ((p = r == null ? void 0 : r.find((_) => _.categoryName === "jawOpen")) == null ? void 0 : p.score) ?? 0;
|
|
3799
3802
|
return o = l < s && u < s, o || t("Please look at the camera!"), i = d < a, i || t("Please close your mouth!"), {
|
|
@@ -3812,51 +3815,51 @@ function sc(e = {}) {
|
|
|
3812
3815
|
onMessage: i = () => {
|
|
3813
3816
|
},
|
|
3814
3817
|
livenessTimeout: s
|
|
3815
|
-
} = e, { faceDetector: a, savePhoto: l } = fe(), { checkFacialFeatures: u, checkZoomLevel: d, checkInFrame: c } = Bo(), f =
|
|
3816
|
-
p.current && clearTimeout(p.current), y.current && clearTimeout(y.current),
|
|
3817
|
-
}, []),
|
|
3818
|
+
} = e, { faceDetector: a, savePhoto: l } = fe(), { checkFacialFeatures: u, checkZoomLevel: d, checkInFrame: c } = Bo(), f = w(null), p = w(null), _ = w(!1), y = w(null), v = w(!1), m = w([]), g = V(() => {
|
|
3819
|
+
p.current && clearTimeout(p.current), y.current && clearTimeout(y.current), m.current.forEach(clearTimeout), v.current = !1, _.current = !0;
|
|
3820
|
+
}, []), E = w(null), $ = w(null), S = w([]), M = 10, R = 7.5, U = 2, F = w({
|
|
3818
3821
|
sharpness: 0,
|
|
3819
3822
|
data: null
|
|
3820
|
-
}),
|
|
3823
|
+
}), b = (k, C) => {
|
|
3821
3824
|
const L = k.getContext("2d");
|
|
3822
3825
|
if (!L || C.width === 0 || C.height === 0 || !L || C.width === 0 || C.height === 0)
|
|
3823
3826
|
return !1;
|
|
3824
|
-
const
|
|
3827
|
+
const N = L.getImageData(
|
|
3825
3828
|
C.xMin,
|
|
3826
3829
|
C.yMin,
|
|
3827
3830
|
C.width,
|
|
3828
3831
|
C.height
|
|
3829
|
-
), { data:
|
|
3830
|
-
let
|
|
3831
|
-
for (let
|
|
3832
|
-
0.299 *
|
|
3833
|
-
const
|
|
3834
|
-
return
|
|
3835
|
-
}, I = (k, C, L,
|
|
3836
|
-
const
|
|
3837
|
-
if (!(!
|
|
3838
|
-
for (const
|
|
3839
|
-
switch (
|
|
3832
|
+
), { data: T } = N;
|
|
3833
|
+
let P = 0, O = 0;
|
|
3834
|
+
for (let z = 0; z < T.length; z += 4)
|
|
3835
|
+
0.299 * T[z] + 0.587 * T[z + 1] + 0.114 * T[z + 2] > 250 && O++;
|
|
3836
|
+
const q = T.length / 4;
|
|
3837
|
+
return P = O / q, P > 0.01;
|
|
3838
|
+
}, I = (k, C, L, N) => {
|
|
3839
|
+
const T = C.current, P = T == null ? void 0 : T.parentElement;
|
|
3840
|
+
if (!(!T || !P))
|
|
3841
|
+
for (const O of N)
|
|
3842
|
+
switch (O) {
|
|
3840
3843
|
case "zoom":
|
|
3841
|
-
d(k, Math.min(
|
|
3844
|
+
d(k, Math.min(P.clientHeight, P.clientWidth));
|
|
3842
3845
|
break;
|
|
3843
3846
|
case "features":
|
|
3844
3847
|
u(
|
|
3845
3848
|
k,
|
|
3846
|
-
Math.min(
|
|
3849
|
+
Math.min(P.clientHeight, P.clientWidth)
|
|
3847
3850
|
);
|
|
3848
3851
|
break;
|
|
3849
3852
|
case "in-frame":
|
|
3850
|
-
let
|
|
3851
|
-
|
|
3852
|
-
const
|
|
3853
|
+
let q = L;
|
|
3854
|
+
q || (q = Math.min(P.clientHeight, P.clientWidth) * 0.7);
|
|
3855
|
+
const z = q + 200;
|
|
3853
3856
|
c(k, {
|
|
3854
|
-
x: (
|
|
3855
|
-
y: (
|
|
3856
|
-
width:
|
|
3857
|
-
height:
|
|
3858
|
-
offsetX: (
|
|
3859
|
-
offsetY: (
|
|
3857
|
+
x: (P.clientWidth - z) / 2,
|
|
3858
|
+
y: (P.clientHeight - z) / 2,
|
|
3859
|
+
width: z,
|
|
3860
|
+
height: z,
|
|
3861
|
+
offsetX: (T.videoWidth - P.clientWidth) / 2,
|
|
3862
|
+
offsetY: (T.videoHeight - P.clientHeight) / 2
|
|
3860
3863
|
});
|
|
3861
3864
|
break;
|
|
3862
3865
|
}
|
|
@@ -3875,9 +3878,9 @@ function sc(e = {}) {
|
|
|
3875
3878
|
386
|
|
3876
3879
|
// Right eye pupil area
|
|
3877
3880
|
], L = 0.5;
|
|
3878
|
-
for (const
|
|
3879
|
-
const
|
|
3880
|
-
if (!
|
|
3881
|
+
for (const N of C) {
|
|
3882
|
+
const T = k[N];
|
|
3883
|
+
if (!T || T.score && T.score < L)
|
|
3881
3884
|
return !1;
|
|
3882
3885
|
}
|
|
3883
3886
|
return !0;
|
|
@@ -3885,32 +3888,32 @@ function sc(e = {}) {
|
|
|
3885
3888
|
const L = k.getContext("2d");
|
|
3886
3889
|
if (!L || C.width === 0 || C.height === 0)
|
|
3887
3890
|
return !1;
|
|
3888
|
-
const
|
|
3891
|
+
const N = L.getImageData(
|
|
3889
3892
|
C.xMin,
|
|
3890
3893
|
C.yMin,
|
|
3891
3894
|
C.width,
|
|
3892
3895
|
C.height
|
|
3893
|
-
), { data:
|
|
3894
|
-
let
|
|
3895
|
-
for (let
|
|
3896
|
-
const
|
|
3897
|
-
|
|
3896
|
+
), { data: T } = N;
|
|
3897
|
+
let P = 0;
|
|
3898
|
+
for (let q = 0; q < T.length; q += 4) {
|
|
3899
|
+
const z = T[q], ee = T[q + 1], He = T[q + 2], dt = 0.299 * z + 0.587 * ee + 0.114 * He;
|
|
3900
|
+
P += dt;
|
|
3898
3901
|
}
|
|
3899
|
-
return
|
|
3900
|
-
},
|
|
3902
|
+
return P / (T.length / 4) < 60;
|
|
3903
|
+
}, K = (k) => {
|
|
3901
3904
|
const C = {
|
|
3902
3905
|
x: k.box.xMin + (k.box.width ?? 0) / 2,
|
|
3903
3906
|
y: k.box.yMin + (k.box.height ?? 0) / 2
|
|
3904
3907
|
};
|
|
3905
3908
|
if (S.current.push(C), S.current.length > M && S.current.shift(), S.current.length < M) return !1;
|
|
3906
|
-
let L = 0,
|
|
3909
|
+
let L = 0, N = 0, T = 0;
|
|
3907
3910
|
for (let ee = 1; ee < S.current.length; ee++) {
|
|
3908
3911
|
const He = S.current[ee - 1], dt = S.current[ee], qe = dt.x - He.x, In = dt.y - He.y, Dn = Math.sqrt(qe * qe + In * In);
|
|
3909
|
-
Dn >= 2 && (L += Dn, ee > 1 && Math.sign(qe) !== Math.sign(
|
|
3912
|
+
Dn >= 2 && (L += Dn, ee > 1 && Math.sign(qe) !== Math.sign(T) && Math.abs(qe) > 3 && N++, T = qe);
|
|
3910
3913
|
}
|
|
3911
|
-
const
|
|
3912
|
-
return
|
|
3913
|
-
}, Q = (k, C, L,
|
|
3914
|
+
const O = L / (M - 1) > R, q = N >= U, z = O || q;
|
|
3915
|
+
return z && i("🚨 Head shake detected!"), z;
|
|
3916
|
+
}, Q = (k, C, L, N) => {
|
|
3914
3917
|
try {
|
|
3915
3918
|
if (k.length === 0 || k.length > 1) {
|
|
3916
3919
|
p.current && (clearTimeout(p.current), p.current = null), i(
|
|
@@ -3918,41 +3921,41 @@ function sc(e = {}) {
|
|
|
3918
3921
|
);
|
|
3919
3922
|
return;
|
|
3920
3923
|
}
|
|
3921
|
-
const
|
|
3922
|
-
let
|
|
3924
|
+
const T = k[0];
|
|
3925
|
+
let P = "", O = !0;
|
|
3923
3926
|
try {
|
|
3924
|
-
I(
|
|
3927
|
+
I(T, f, n, t);
|
|
3925
3928
|
} catch (ee) {
|
|
3926
|
-
|
|
3929
|
+
P = ee.message, O = !1;
|
|
3927
3930
|
}
|
|
3928
|
-
|
|
3929
|
-
const { eyesOpen:
|
|
3930
|
-
|
|
3931
|
+
K(T) && (P = "Please hold your head steady", O = !1), N || (P = "Center your face in the frame", O = !1), B(T.keypoints) || (P = "Please ensure your eyes are clearly visible. Remove glasses if necessary.", O = !1);
|
|
3932
|
+
const { eyesOpen: q, mouthClosed: z } = ic(
|
|
3933
|
+
T.keypoints,
|
|
3931
3934
|
// onError,
|
|
3932
3935
|
i,
|
|
3933
3936
|
!1,
|
|
3934
3937
|
L
|
|
3935
3938
|
);
|
|
3936
|
-
if (
|
|
3937
|
-
p.current && (clearTimeout(p.current), p.current = null,
|
|
3939
|
+
if (q ? z || (P = "Please close your mouth", O = !1) : (p.current && (clearTimeout(p.current), p.current = null), O = !1), !O) {
|
|
3940
|
+
p.current && (clearTimeout(p.current), p.current = null, m.current.forEach(clearTimeout)), i(P), r(T, !1, L, !1);
|
|
3938
3941
|
return;
|
|
3939
3942
|
}
|
|
3940
3943
|
if (!p.current) {
|
|
3941
|
-
if (D(
|
|
3944
|
+
if (D(E.current, T.box)) {
|
|
3942
3945
|
i("Too dark – move to a well-lit area");
|
|
3943
3946
|
return;
|
|
3944
3947
|
}
|
|
3945
|
-
if (E
|
|
3948
|
+
if (b(E.current, T.box)) {
|
|
3946
3949
|
i("Too much glare. Please avoid direct light on your face.");
|
|
3947
3950
|
return;
|
|
3948
3951
|
}
|
|
3949
|
-
i("Hold still..."), F.current = { sharpness: 0, data: null },
|
|
3952
|
+
i("Hold still..."), F.current = { sharpness: 0, data: null }, m.current.forEach(clearTimeout);
|
|
3950
3953
|
const ee = setTimeout(() => i("Almost there..."), 400), He = setTimeout(
|
|
3951
3954
|
() => i("Detecting liveness..."),
|
|
3952
3955
|
700
|
|
3953
3956
|
);
|
|
3954
|
-
|
|
3955
|
-
F.current.data ? (l(F.current.data), r(
|
|
3957
|
+
m.current = [ee, He], p.current = setTimeout(() => {
|
|
3958
|
+
F.current.data ? (l(F.current.data), r(T, !0, L, !0)) : o("Could not capture a clear photo. Please try again.");
|
|
3956
3959
|
}, 1e3);
|
|
3957
3960
|
}
|
|
3958
3961
|
if (p.current) {
|
|
@@ -3962,8 +3965,8 @@ function sc(e = {}) {
|
|
|
3962
3965
|
data: C
|
|
3963
3966
|
});
|
|
3964
3967
|
}
|
|
3965
|
-
} catch (
|
|
3966
|
-
o(
|
|
3968
|
+
} catch (T) {
|
|
3969
|
+
o(T.message), k.length > 0 && r(k[0], !1, L, !1);
|
|
3967
3970
|
}
|
|
3968
3971
|
};
|
|
3969
3972
|
return { detectFaces: async (k) => {
|
|
@@ -3971,21 +3974,21 @@ function sc(e = {}) {
|
|
|
3971
3974
|
f.current = k.ref.current;
|
|
3972
3975
|
const C = f.current;
|
|
3973
3976
|
if (!C || C.videoWidth === 0) return;
|
|
3974
|
-
|
|
3977
|
+
E.current || (E.current = document.createElement("canvas"), $.current = E.current.getContext("2d", {
|
|
3975
3978
|
willReadFrequently: !0
|
|
3976
3979
|
}));
|
|
3977
|
-
const L =
|
|
3978
|
-
if (!L || !
|
|
3979
|
-
L.width = C.videoWidth, L.height = C.videoHeight,
|
|
3980
|
-
const
|
|
3981
|
-
!
|
|
3980
|
+
const L = E.current, N = $.current;
|
|
3981
|
+
if (!L || !N) return;
|
|
3982
|
+
L.width = C.videoWidth, L.height = C.videoHeight, N.drawImage(C, 0, 0, L.width, L.height);
|
|
3983
|
+
const T = N.getImageData(0, 0, L.width, L.height);
|
|
3984
|
+
!v.current && C.readyState >= 2 && !_.current && (v.current = !0, y.current = setTimeout(() => {
|
|
3982
3985
|
o("Liveness check TIMED OUT. Please try again."), g();
|
|
3983
3986
|
}, s));
|
|
3984
|
-
const { faces:
|
|
3987
|
+
const { faces: P, blendShapes: O, inBox: q } = await $e.detectFaces(
|
|
3985
3988
|
a,
|
|
3986
|
-
|
|
3989
|
+
T
|
|
3987
3990
|
);
|
|
3988
|
-
Q(
|
|
3991
|
+
Q(P, T, O, q);
|
|
3989
3992
|
}, cleanup: g };
|
|
3990
3993
|
}
|
|
3991
3994
|
const ac = "_container_1ej18_1", lc = "_progress_1ej18_12", cc = "_completed_1ej18_33", uc = "_marker_1ej18_37", Gt = {
|
|
@@ -3995,7 +3998,7 @@ const ac = "_container_1ej18_1", lc = "_progress_1ej18_12", cc = "_completed_1ej
|
|
|
3995
3998
|
marker: uc
|
|
3996
3999
|
};
|
|
3997
4000
|
function dc(e) {
|
|
3998
|
-
const { faceDetected: t } = e, n =
|
|
4001
|
+
const { faceDetected: t } = e, n = j(() => {
|
|
3999
4002
|
const r = [Gt.container];
|
|
4000
4003
|
return t && r.push(Gt.focused), r.join(" ");
|
|
4001
4004
|
}, [t]);
|
|
@@ -4040,55 +4043,55 @@ function pc(e) {
|
|
|
4040
4043
|
onError: r = () => {
|
|
4041
4044
|
}
|
|
4042
4045
|
// onPictureReady = () => {},
|
|
4043
|
-
} = e, { setColorScheme: o, getColorScheme: i } = jo(), s =
|
|
4046
|
+
} = e, { setColorScheme: o, getColorScheme: i } = jo(), s = w(null), a = w(!1), l = () => {
|
|
4044
4047
|
s.current && (s.current.callAttemptEnd(), s.current.delete(), s.current = null);
|
|
4045
|
-
}, u =
|
|
4048
|
+
}, u = V(() => {
|
|
4046
4049
|
l();
|
|
4047
4050
|
}, []), d = () => {
|
|
4048
4051
|
s.current && l(), s.current = null, a.current = !1;
|
|
4049
|
-
}, c = (
|
|
4050
|
-
var R,
|
|
4051
|
-
const
|
|
4052
|
+
}, c = (v) => {
|
|
4053
|
+
var R, U;
|
|
4054
|
+
const m = v.split(".");
|
|
4052
4055
|
let g = !1;
|
|
4053
|
-
s.current.setToken(
|
|
4054
|
-
let
|
|
4055
|
-
if (
|
|
4056
|
-
const F = JSON.parse(atob(
|
|
4056
|
+
s.current.setToken(v);
|
|
4057
|
+
let E = "", $ = "", S, M = 0;
|
|
4058
|
+
if (m.length === 3) {
|
|
4059
|
+
const F = JSON.parse(atob(m[1]));
|
|
4057
4060
|
if (F.face) {
|
|
4058
|
-
const
|
|
4059
|
-
if (
|
|
4060
|
-
s.current.setEndpoint(
|
|
4061
|
+
const b = JSON.parse(F.face), I = /^https:\/\/[^/:]+\.(api\.cognitive\.microsoft|cognitiveservices\.azure)\.com$/;
|
|
4062
|
+
if (b.endpoint && (I.test(b.endpoint) || b.endpoint === "https://virginia.api.cognitive.microsoft.us")) {
|
|
4063
|
+
s.current.setEndpoint(b.endpoint);
|
|
4061
4064
|
const D = JSON.parse(F["allowed-paths"]);
|
|
4062
4065
|
if (D) {
|
|
4063
|
-
const
|
|
4064
|
-
(
|
|
4066
|
+
const K = (R = D.find(
|
|
4067
|
+
(N) => N.path.toLocaleLowerCase().endsWith("/session/start")
|
|
4065
4068
|
)) == null ? void 0 : R.path;
|
|
4066
|
-
s.current.setSessionStartPath(
|
|
4067
|
-
const Q = (
|
|
4068
|
-
(
|
|
4069
|
-
)) == null ? void 0 :
|
|
4069
|
+
s.current.setSessionStartPath(K);
|
|
4070
|
+
const Q = (U = D.find(
|
|
4071
|
+
(N) => N.path.toLocaleLowerCase().endsWith("/session/attempt/end")
|
|
4072
|
+
)) == null ? void 0 : U.path;
|
|
4070
4073
|
s.current.setAttemptEndPath(Q);
|
|
4071
4074
|
const Z = D.find(
|
|
4072
|
-
(
|
|
4075
|
+
(N) => N.path.endsWith("/detectLiveness/singleModal")
|
|
4073
4076
|
);
|
|
4074
|
-
Z && ({ path:
|
|
4077
|
+
Z && ({ path: E, quota: M } = Z, s.current.setLivenessPath(E));
|
|
4075
4078
|
const k = D.find(
|
|
4076
|
-
(
|
|
4079
|
+
(N) => N.path.endsWith("/detectLivenessWithVerify/singleModal")
|
|
4077
4080
|
);
|
|
4078
|
-
k && ({ path:
|
|
4079
|
-
|
|
4081
|
+
k && ({ path: $, quota: M } = k, s.current.setLivenessWithVerifyPath(
|
|
4082
|
+
$
|
|
4080
4083
|
));
|
|
4081
4084
|
const C = new Set(
|
|
4082
4085
|
D.map(
|
|
4083
|
-
(
|
|
4084
|
-
var
|
|
4085
|
-
return (
|
|
4086
|
+
(N) => {
|
|
4087
|
+
var T;
|
|
4088
|
+
return (T = N.path) == null ? void 0 : T.split("/")[1];
|
|
4086
4089
|
}
|
|
4087
4090
|
)
|
|
4088
4091
|
);
|
|
4089
4092
|
if (C.size === 1 && (Z || k)) {
|
|
4090
|
-
const
|
|
4091
|
-
s.current.setApiVersion(
|
|
4093
|
+
const N = C.values().next().value;
|
|
4094
|
+
s.current.setApiVersion(N), g = !0, S = b.clientClaims.livenessOperationMode;
|
|
4092
4095
|
}
|
|
4093
4096
|
}
|
|
4094
4097
|
}
|
|
@@ -4114,16 +4117,16 @@ function pc(e) {
|
|
|
4114
4117
|
F.livenessError ? Kt[F.livenessError] || F.livenessError : "Something went wrong"
|
|
4115
4118
|
), u();
|
|
4116
4119
|
}
|
|
4117
|
-
}, f = (
|
|
4120
|
+
}, f = (v) => {
|
|
4118
4121
|
try {
|
|
4119
|
-
o("light"), s.current = new window.Module.FaceRecoEngineAdapter(), c(
|
|
4120
|
-
} catch (
|
|
4121
|
-
r(`Could not start liveness test: ${
|
|
4122
|
+
o("light"), s.current = new window.Module.FaceRecoEngineAdapter(), c(v);
|
|
4123
|
+
} catch (m) {
|
|
4124
|
+
r(`Could not start liveness test: ${m.message}`), l();
|
|
4122
4125
|
}
|
|
4123
|
-
}, p = (
|
|
4124
|
-
const { isActionValid:
|
|
4125
|
-
if (
|
|
4126
|
-
switch (
|
|
4126
|
+
}, p = (v) => {
|
|
4127
|
+
const { isActionValid: m, isFeedbackValid: g, feedback: E } = v;
|
|
4128
|
+
if (m)
|
|
4129
|
+
switch (v.action) {
|
|
4127
4130
|
case window.Module.ActionRequiredFromApplication.BrightenDisplay:
|
|
4128
4131
|
o("light");
|
|
4129
4132
|
break;
|
|
@@ -4134,45 +4137,45 @@ function pc(e) {
|
|
|
4134
4137
|
break;
|
|
4135
4138
|
}
|
|
4136
4139
|
if (!a.current && g) {
|
|
4137
|
-
const
|
|
4140
|
+
const $ = Ce(
|
|
4138
4141
|
window.Module.FeedbackForFace,
|
|
4139
|
-
|
|
4142
|
+
E
|
|
4140
4143
|
);
|
|
4141
4144
|
n(
|
|
4142
|
-
|
|
4145
|
+
$ && (fc[$] || "")
|
|
4143
4146
|
);
|
|
4144
4147
|
}
|
|
4145
|
-
if (
|
|
4148
|
+
if (E === window.Module.FeedbackForFace.AttentionNotNeeded) {
|
|
4146
4149
|
a.current = !0;
|
|
4147
|
-
const
|
|
4148
|
-
o(
|
|
4150
|
+
const $ = i();
|
|
4151
|
+
o($);
|
|
4149
4152
|
}
|
|
4150
|
-
}, _ = (
|
|
4153
|
+
}, _ = (v) => {
|
|
4151
4154
|
var S, M;
|
|
4152
|
-
const { livenessResult:
|
|
4155
|
+
const { livenessResult: m, recognitionResult: g } = v, E = ((S = m.failureReason) == null ? void 0 : S.value) !== 0 || ((M = g.failureReason) == null ? void 0 : M.value) !== 0, $ = /* @__PURE__ */ new Set([
|
|
4153
4156
|
"EnvironmentNotSupported",
|
|
4154
4157
|
"ExcessiveFaceBrightnessDetected",
|
|
4155
4158
|
"FaceEyeRegionNotVisible"
|
|
4156
4159
|
]);
|
|
4157
|
-
if (
|
|
4160
|
+
if (E) {
|
|
4158
4161
|
const R = {
|
|
4159
4162
|
livenessError: Ce(
|
|
4160
4163
|
window.Module.LivenessFailureReason,
|
|
4161
|
-
|
|
4164
|
+
m.failureReason
|
|
4162
4165
|
),
|
|
4163
4166
|
recognitionError: Ce(
|
|
4164
4167
|
window.Module.RecognitionFailureReason,
|
|
4165
4168
|
g.failureReason
|
|
4166
4169
|
)
|
|
4167
4170
|
};
|
|
4168
|
-
R.livenessError &&
|
|
4171
|
+
R.livenessError && $.has(R.livenessError) ? t() : r(
|
|
4169
4172
|
R.livenessError ? Kt[R.livenessError] || R.livenessError : "Something went wrong"
|
|
4170
4173
|
);
|
|
4171
4174
|
} else {
|
|
4172
4175
|
const R = {
|
|
4173
4176
|
livenessStatus: Ce(
|
|
4174
4177
|
window.Module.LivenessStatus,
|
|
4175
|
-
|
|
4178
|
+
m.status
|
|
4176
4179
|
),
|
|
4177
4180
|
recognitionResult: {
|
|
4178
4181
|
status: Ce(
|
|
@@ -4181,8 +4184,8 @@ function pc(e) {
|
|
|
4181
4184
|
),
|
|
4182
4185
|
matchConfidence: g.confidence
|
|
4183
4186
|
},
|
|
4184
|
-
resultId:
|
|
4185
|
-
digest:
|
|
4187
|
+
resultId: m.resultId,
|
|
4188
|
+
digest: m.digest
|
|
4186
4189
|
};
|
|
4187
4190
|
R.livenessStatus === "RealFace" ? t() : R.livenessStatus === "SpoofFace" ? r(Kt[R.livenessStatus]) : r("Could not validate request");
|
|
4188
4191
|
}
|
|
@@ -4191,28 +4194,28 @@ function pc(e) {
|
|
|
4191
4194
|
return {
|
|
4192
4195
|
start: f,
|
|
4193
4196
|
analyze: p,
|
|
4194
|
-
processFrame: (
|
|
4195
|
-
let
|
|
4197
|
+
processFrame: (v) => {
|
|
4198
|
+
let m = !1;
|
|
4196
4199
|
if (a.current)
|
|
4197
|
-
|
|
4200
|
+
m = s.current.generatePayloadAndResult();
|
|
4198
4201
|
else {
|
|
4199
|
-
const { videoWidth: g, videoHeight:
|
|
4202
|
+
const { videoWidth: g, videoHeight: E } = v, $ = Rn(v, g, E, void 0, {
|
|
4200
4203
|
willReadFrequently: !0
|
|
4201
|
-
}), S = window.Module._malloc(
|
|
4204
|
+
}), S = window.Module._malloc($.data.byteLength);
|
|
4202
4205
|
try {
|
|
4203
|
-
window.Module.HEAPU8.set(
|
|
4206
|
+
window.Module.HEAPU8.set($.data, S);
|
|
4204
4207
|
const M = s.current.processFrame(
|
|
4205
4208
|
g,
|
|
4206
|
-
|
|
4207
|
-
|
|
4209
|
+
E,
|
|
4210
|
+
$.data.byteLength,
|
|
4208
4211
|
S
|
|
4209
4212
|
);
|
|
4210
|
-
M.terminate ?
|
|
4213
|
+
M.terminate ? m = !0 : M.isValid && p(M);
|
|
4211
4214
|
} finally {
|
|
4212
4215
|
window.Module._free(S);
|
|
4213
4216
|
}
|
|
4214
4217
|
}
|
|
4215
|
-
|
|
4218
|
+
m && _(s.current.getFaceAnalyzerResult());
|
|
4216
4219
|
},
|
|
4217
4220
|
reset: d,
|
|
4218
4221
|
destroy: u
|
|
@@ -4227,13 +4230,13 @@ function hc({
|
|
|
4227
4230
|
onReset: o,
|
|
4228
4231
|
onFailure: i
|
|
4229
4232
|
}) {
|
|
4230
|
-
const [s, a] = x(Fr), [l, u] = x(!1), d =
|
|
4231
|
-
|
|
4233
|
+
const [s, a] = x(Fr), [l, u] = x(!1), d = w("findingFace"), c = w(null), f = w(), p = w(!1), [_, y] = x(0), v = w(!1), [m, g] = x(!1);
|
|
4234
|
+
W(() => {
|
|
4232
4235
|
y(Math.min(window.innerWidth, window.innerHeight) * 0.6);
|
|
4233
|
-
}, []),
|
|
4236
|
+
}, []), W(() => {
|
|
4234
4237
|
n(), t();
|
|
4235
4238
|
}, []);
|
|
4236
|
-
const
|
|
4239
|
+
const E = pc({
|
|
4237
4240
|
onMessage: (F) => {
|
|
4238
4241
|
d.current === "analyzingLiveness" && a(F);
|
|
4239
4242
|
},
|
|
@@ -4241,22 +4244,22 @@ function hc({
|
|
|
4241
4244
|
d.current = "done", e(!0);
|
|
4242
4245
|
},
|
|
4243
4246
|
onError: (F) => {
|
|
4244
|
-
const
|
|
4245
|
-
a(
|
|
4247
|
+
const b = Ql(F);
|
|
4248
|
+
a(b.message), d.current = "done", u(!0), r && r(F), i({
|
|
4246
4249
|
faceImage: "",
|
|
4247
4250
|
passed: !1,
|
|
4248
4251
|
metadata: {},
|
|
4249
|
-
error:
|
|
4252
|
+
error: b
|
|
4250
4253
|
});
|
|
4251
4254
|
}
|
|
4252
|
-
}),
|
|
4253
|
-
|
|
4255
|
+
}), $ = () => {
|
|
4256
|
+
v.current = !1, a(Fr), d.current = "findingFace", c.current = null, E.reset(), f.current && cancelAnimationFrame(f.current), u(!1), o();
|
|
4254
4257
|
}, { detectFaces: S, cleanup: M } = sc({
|
|
4255
4258
|
validations: ["zoom", "features"],
|
|
4256
4259
|
frameSize: _,
|
|
4257
4260
|
livenessTimeout: 1e4,
|
|
4258
|
-
onFace: async (F,
|
|
4259
|
-
p.current =
|
|
4261
|
+
onFace: async (F, b, I) => {
|
|
4262
|
+
p.current = b, b && d.current === "findingFace" && !v.current && I && (v.current = !0, g(!0));
|
|
4260
4263
|
},
|
|
4261
4264
|
onPhotoSaved: () => {
|
|
4262
4265
|
},
|
|
@@ -4267,28 +4270,28 @@ function hc({
|
|
|
4267
4270
|
a(F), u(!0), r && r(F);
|
|
4268
4271
|
}
|
|
4269
4272
|
});
|
|
4270
|
-
|
|
4273
|
+
W(
|
|
4271
4274
|
() => () => {
|
|
4272
4275
|
M();
|
|
4273
4276
|
},
|
|
4274
4277
|
[]
|
|
4275
4278
|
);
|
|
4276
4279
|
const R = () => {
|
|
4277
|
-
!c.current || c.current.paused || c.current.ended || (d.current === "findingFace" ? S({ ref: c }) : d.current === "analyzingLiveness" &&
|
|
4280
|
+
!c.current || c.current.paused || c.current.ended || (d.current === "findingFace" ? S({ ref: c }) : d.current === "analyzingLiveness" && E.processFrame(c.current), d.current !== "done" && (f.current = requestAnimationFrame(R)));
|
|
4278
4281
|
};
|
|
4279
|
-
|
|
4282
|
+
W(() => {
|
|
4280
4283
|
(async () => {
|
|
4281
|
-
if (
|
|
4284
|
+
if (m) {
|
|
4282
4285
|
g(!1), M();
|
|
4283
4286
|
try {
|
|
4284
4287
|
await n();
|
|
4285
|
-
const
|
|
4286
|
-
if (
|
|
4287
|
-
|
|
4288
|
+
const b = await t();
|
|
4289
|
+
if (b)
|
|
4290
|
+
E.start(b), d.current = "analyzingLiveness";
|
|
4288
4291
|
else
|
|
4289
4292
|
throw new Error("Session token could not be retrieved.");
|
|
4290
|
-
} catch (
|
|
4291
|
-
const I =
|
|
4293
|
+
} catch (b) {
|
|
4294
|
+
const I = b instanceof Error ? b.message : "Failed to start liveness check.";
|
|
4292
4295
|
r && r(I), i({
|
|
4293
4296
|
faceImage: "",
|
|
4294
4297
|
passed: !1,
|
|
@@ -4301,11 +4304,11 @@ function hc({
|
|
|
4301
4304
|
}
|
|
4302
4305
|
}
|
|
4303
4306
|
})();
|
|
4304
|
-
}, [
|
|
4305
|
-
const
|
|
4307
|
+
}, [m]);
|
|
4308
|
+
const U = (F) => {
|
|
4306
4309
|
F.current && (c.current = F.current, R());
|
|
4307
4310
|
};
|
|
4308
|
-
return
|
|
4311
|
+
return W(
|
|
4309
4312
|
() => () => {
|
|
4310
4313
|
f.current && cancelAnimationFrame(f.current);
|
|
4311
4314
|
},
|
|
@@ -4316,11 +4319,11 @@ function hc({
|
|
|
4316
4319
|
Icon: Uo,
|
|
4317
4320
|
title: "Oops, task failed!",
|
|
4318
4321
|
description: s,
|
|
4319
|
-
onActionClick:
|
|
4322
|
+
onActionClick: $,
|
|
4320
4323
|
actionText: "Try Again"
|
|
4321
4324
|
}
|
|
4322
4325
|
) }) : /* @__PURE__ */ h("div", { className: se.root, children: /* @__PURE__ */ h("div", { className: `${se.container} view`, children: /* @__PURE__ */ h("div", { className: "yvlw-h-full yvlw-flex yvlw-flex-col", children: [
|
|
4323
|
-
/* @__PURE__ */ h("div", { children: /* @__PURE__ */ h(ut, { onStream:
|
|
4326
|
+
/* @__PURE__ */ h("div", { children: /* @__PURE__ */ h(ut, { onStream: U, children: /* @__PURE__ */ h(G, { children: [
|
|
4324
4327
|
/* @__PURE__ */ h(dc, { faceDetected: p.current }),
|
|
4325
4328
|
d.current === "analyzingLiveness" && /* @__PURE__ */ h("div", { className: "yvlw-bg-black/20 yvlw-z-5" })
|
|
4326
4329
|
] }) }) }),
|
|
@@ -4333,7 +4336,7 @@ function hc({
|
|
|
4333
4336
|
] }) })
|
|
4334
4337
|
] }) }) }) });
|
|
4335
4338
|
}
|
|
4336
|
-
const
|
|
4339
|
+
const mc = () => {
|
|
4337
4340
|
if (window.isAzureSdkLoading)
|
|
4338
4341
|
return window.azureSdkLoadPromise;
|
|
4339
4342
|
window.isAzureSdkLoading = !0;
|
|
@@ -4363,7 +4366,7 @@ const vc = () => {
|
|
|
4363
4366
|
return window.azureSdkLoadPromise = e, e;
|
|
4364
4367
|
};
|
|
4365
4368
|
let Xe = null;
|
|
4366
|
-
function
|
|
4369
|
+
function vc() {
|
|
4367
4370
|
var Z;
|
|
4368
4371
|
const { toggleColorScheme: e, getColorScheme: t, setColorScheme: n } = jo(), {
|
|
4369
4372
|
user: r,
|
|
@@ -4377,26 +4380,26 @@ function mc() {
|
|
|
4377
4380
|
clearSavedPhoto: c,
|
|
4378
4381
|
branding: f,
|
|
4379
4382
|
isMobileAppWebView: p
|
|
4380
|
-
} = fe(), [_, y] = x(!1), [
|
|
4381
|
-
|
|
4383
|
+
} = fe(), [_, y] = x(!1), [v, m] = x(!1), [g, E] = x(null), [$, S] = x(!1), [M, R] = x(!1), [U, F] = x(0), [b, I] = x(null);
|
|
4384
|
+
W(() => {
|
|
4382
4385
|
const k = t();
|
|
4383
4386
|
n(k);
|
|
4384
|
-
}, []),
|
|
4385
|
-
s &&
|
|
4386
|
-
}, [s,
|
|
4387
|
-
const B =
|
|
4387
|
+
}, []), W(() => {
|
|
4388
|
+
s && !$ && b === null && I(5);
|
|
4389
|
+
}, [s, $, b]);
|
|
4390
|
+
const B = V(async () => {
|
|
4388
4391
|
try {
|
|
4389
|
-
y(!0),
|
|
4392
|
+
y(!0), E(null), await a(), Xe = null, d === "page" && S(!0);
|
|
4390
4393
|
} catch (k) {
|
|
4391
|
-
|
|
4394
|
+
E(k.message);
|
|
4392
4395
|
} finally {
|
|
4393
4396
|
y(!1);
|
|
4394
4397
|
}
|
|
4395
4398
|
}, [a, d]);
|
|
4396
|
-
|
|
4397
|
-
if (
|
|
4399
|
+
W(() => {
|
|
4400
|
+
if (b === null || $)
|
|
4398
4401
|
return;
|
|
4399
|
-
if (
|
|
4402
|
+
if (b === 0) {
|
|
4400
4403
|
B();
|
|
4401
4404
|
return;
|
|
4402
4405
|
}
|
|
@@ -4406,19 +4409,19 @@ function mc() {
|
|
|
4406
4409
|
return () => {
|
|
4407
4410
|
clearTimeout(k);
|
|
4408
4411
|
};
|
|
4409
|
-
}, [
|
|
4410
|
-
const { sessionToken: D } = fe(),
|
|
4412
|
+
}, [b, $]);
|
|
4413
|
+
const { sessionToken: D } = fe(), K = async () => (!D && !Xe && (Xe = Promise.reject(
|
|
4411
4414
|
new Error(
|
|
4412
4415
|
"sessionToken not provided. Generate a sessionToken on your backend and pass it to the SDK."
|
|
4413
4416
|
)
|
|
4414
|
-
)), D ?? Xe), Q =
|
|
4417
|
+
)), D ?? Xe), Q = V(
|
|
4415
4418
|
(k) => k === i ? ne.active : i > k ? ne.completed : "subtext",
|
|
4416
4419
|
[i]
|
|
4417
4420
|
);
|
|
4418
4421
|
return /* @__PURE__ */ h("div", { className: ne.root, children: /* @__PURE__ */ h("div", { className: ne.container, children: [
|
|
4419
4422
|
/* @__PURE__ */ h("div", { className: `${ne.lhs} divider`, children: [
|
|
4420
4423
|
/* @__PURE__ */ h("div", { className: ne.info, children: [
|
|
4421
|
-
/* @__PURE__ */ h(
|
|
4424
|
+
/* @__PURE__ */ h(vl, {}),
|
|
4422
4425
|
/* @__PURE__ */ h("div", { children: /* @__PURE__ */ h("p", { className: "yvlw-text-xs yvlw-m-0 yvlw-p-0 subtext", children: "You have been given this set of tasks to complete. They are pretty easy to do but we will be guiding you every step of the way." }) }),
|
|
4423
4426
|
/* @__PURE__ */ h("ol", { children: [
|
|
4424
4427
|
o.map((k, C) => /* @__PURE__ */ h("li", { className: Q(C), children: el[k.id].name }, `task-${C}`)),
|
|
@@ -4447,7 +4450,7 @@ function mc() {
|
|
|
4447
4450
|
/* @__PURE__ */ h(
|
|
4448
4451
|
pe,
|
|
4449
4452
|
{
|
|
4450
|
-
show: !
|
|
4453
|
+
show: !v,
|
|
4451
4454
|
as: "div",
|
|
4452
4455
|
leave: "yvlw-transform yvlw-transition yvlw-duration-300",
|
|
4453
4456
|
leaveFrom: "yvlw-translate-y-0 yvlw-opacity-100",
|
|
@@ -4462,7 +4465,7 @@ function mc() {
|
|
|
4462
4465
|
title: "Liveness Check",
|
|
4463
4466
|
description: "To ensure the security of your identity, we conduct a liveness check to verify that you are a real person actively engaging with the process. Please ensure to stay in a well lit area.",
|
|
4464
4467
|
actionText: "Start Liveness Test",
|
|
4465
|
-
onActionClick: () =>
|
|
4468
|
+
onActionClick: () => m(!0)
|
|
4466
4469
|
}
|
|
4467
4470
|
) : /* @__PURE__ */ h(qo, { size: "lg" }) })
|
|
4468
4471
|
}
|
|
@@ -4470,7 +4473,7 @@ function mc() {
|
|
|
4470
4473
|
/* @__PURE__ */ h(
|
|
4471
4474
|
pe,
|
|
4472
4475
|
{
|
|
4473
|
-
show:
|
|
4476
|
+
show: v && !M,
|
|
4474
4477
|
as: "div",
|
|
4475
4478
|
leave: "yvlw-transform yvlw-transition yvlw-duration-300",
|
|
4476
4479
|
leaveFrom: "yvlw-translate-y-0 yvlw-opacity-100",
|
|
@@ -4481,18 +4484,18 @@ function mc() {
|
|
|
4481
4484
|
children: /* @__PURE__ */ h("div", { className: ne.completed, children: /* @__PURE__ */ h(
|
|
4482
4485
|
hc,
|
|
4483
4486
|
{
|
|
4484
|
-
fetchAzureSessionToken:
|
|
4485
|
-
loadAzureSdk:
|
|
4487
|
+
fetchAzureSessionToken: K,
|
|
4488
|
+
loadAzureSdk: mc,
|
|
4486
4489
|
onImageCaptured: (k) => {
|
|
4487
|
-
|
|
4490
|
+
E(null), k && R(!0);
|
|
4488
4491
|
},
|
|
4489
|
-
onError: (k) =>
|
|
4492
|
+
onError: (k) => E(k),
|
|
4490
4493
|
onReset: () => {
|
|
4491
4494
|
Xe = null, R(!1), F((k) => k + 1), c();
|
|
4492
4495
|
},
|
|
4493
4496
|
onFailure: l
|
|
4494
4497
|
},
|
|
4495
|
-
|
|
4498
|
+
U
|
|
4496
4499
|
) })
|
|
4497
4500
|
}
|
|
4498
4501
|
),
|
|
@@ -4512,13 +4515,13 @@ function mc() {
|
|
|
4512
4515
|
L = /* @__PURE__ */ h(rc, { ...k });
|
|
4513
4516
|
break;
|
|
4514
4517
|
default:
|
|
4515
|
-
L = /* @__PURE__ */ h(
|
|
4518
|
+
L = /* @__PURE__ */ h(G, {});
|
|
4516
4519
|
break;
|
|
4517
4520
|
}
|
|
4518
4521
|
return /* @__PURE__ */ h(
|
|
4519
4522
|
pe,
|
|
4520
4523
|
{
|
|
4521
|
-
show:
|
|
4524
|
+
show: v && M && !s && i === C,
|
|
4522
4525
|
appear: !0,
|
|
4523
4526
|
as: "div",
|
|
4524
4527
|
leave: "yvlw-transform yvlw-transition yvlw-duration-300",
|
|
@@ -4535,7 +4538,7 @@ function mc() {
|
|
|
4535
4538
|
/* @__PURE__ */ h(
|
|
4536
4539
|
pe,
|
|
4537
4540
|
{
|
|
4538
|
-
show:
|
|
4541
|
+
show: v && s,
|
|
4539
4542
|
as: "div",
|
|
4540
4543
|
leave: "yvlw-transform yvlw-transition yvlw-duration-300",
|
|
4541
4544
|
leaveFrom: "yvlw-translate-y-0 yvlw-opacity-100",
|
|
@@ -4547,12 +4550,12 @@ function mc() {
|
|
|
4547
4550
|
$t,
|
|
4548
4551
|
{
|
|
4549
4552
|
Icon: Wa,
|
|
4550
|
-
title:
|
|
4551
|
-
description:
|
|
4552
|
-
actionText:
|
|
4553
|
+
title: $ ? "All Set!" : "Please click the button below to complete your verification",
|
|
4554
|
+
description: $ ? "You can now close or exit the window" : "Your identity has been verified. You must click the button below to submit and finalize the process.",
|
|
4555
|
+
actionText: b !== null && b > 0 ? `Finish in (${b}s)` : "Finish",
|
|
4553
4556
|
loading: _,
|
|
4554
4557
|
onActionClick: B,
|
|
4555
|
-
hideButton:
|
|
4558
|
+
hideButton: $,
|
|
4556
4559
|
children: g && /* @__PURE__ */ h("div", { className: "yvlw-mt-3", children: g })
|
|
4557
4560
|
}
|
|
4558
4561
|
) })
|
|
@@ -4593,8 +4596,8 @@ function _c(e) {
|
|
|
4593
4596
|
sessionId: p,
|
|
4594
4597
|
sessionToken: _,
|
|
4595
4598
|
forceDevUrl: y
|
|
4596
|
-
} = e, [
|
|
4597
|
-
|
|
4599
|
+
} = e, [v, m] = x(e.show), g = () => {
|
|
4600
|
+
m(!1), s();
|
|
4598
4601
|
};
|
|
4599
4602
|
return /* @__PURE__ */ h(
|
|
4600
4603
|
tl,
|
|
@@ -4618,7 +4621,7 @@ function _c(e) {
|
|
|
4618
4621
|
Fa,
|
|
4619
4622
|
{
|
|
4620
4623
|
id: n,
|
|
4621
|
-
open: u === "page" ? !0 :
|
|
4624
|
+
open: u === "page" ? !0 : v,
|
|
4622
4625
|
onClose: g,
|
|
4623
4626
|
transition: !0,
|
|
4624
4627
|
className: `${Ra.root} ${ht.root} ${ht[u]}`,
|
|
@@ -4628,7 +4631,7 @@ function _c(e) {
|
|
|
4628
4631
|
},
|
|
4629
4632
|
children: [
|
|
4630
4633
|
u === "modal" && /* @__PURE__ */ h("div", { onClick: g, role: "button", className: ht.close, children: /* @__PURE__ */ h(Ua, { className: "yvlw-text-white" }) }),
|
|
4631
|
-
/* @__PURE__ */ h(Ho, { className: `${ht.container}`, children: /* @__PURE__ */ h(
|
|
4634
|
+
/* @__PURE__ */ h(Ho, { className: `${ht.container}`, children: /* @__PURE__ */ h(vc, {}) })
|
|
4632
4635
|
]
|
|
4633
4636
|
}
|
|
4634
4637
|
)
|