@sekyro/web 0.1.0-rc.2 → 0.1.0-rc.3

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.d.cts CHANGED
@@ -1,6 +1,6 @@
1
- export { C as CaptureChannel, a as CaptureError, b as CaptureErrorKind, c as CaptureState, d as CapturedArtifacts, D as DEFAULT_API_ORIGIN, G as GateHint, e as GateUpdate, L as LivenessCaptureEvents, f as LivenessCaptureHandle, g as LivenessCaptureOptions, R as ReasonCode, S as SdkFailureReason, V as Verification, h as VerificationEvents, i as VerificationLocale, j as VerificationOptions, k as VerificationResult, l as VerificationStatus, m as createLivenessCapture, n as createVerification } from './create-verification-EnZ13uY4.cjs';
1
+ export { C as CaptureChannel, a as CaptureError, b as CaptureErrorKind, c as CaptureState, d as CapturedArtifacts, D as DEFAULT_API_ORIGIN, G as GateHint, e as GateUpdate, L as LivenessCaptureEvents, f as LivenessCaptureHandle, g as LivenessCaptureOptions, R as ReasonCode, S as SdkFailureReason, V as Verification, h as VerificationEvents, i as VerificationLocale, j as VerificationOptions, k as VerificationResult, l as VerificationStatus, m as createLivenessCapture, n as createVerification } from './create-verification-CP18eq1Q.cjs';
2
2
  export { OpenHostedOptions, PopupBlocked, PopupHandle, SEKYRO_EVENTS, SekyroEvent, SekyroEventName, openHosted } from './popup/index.cjs';
3
3
  export { HostedApiError, KNOWN_CODES, KnownCode, isKnownCode } from './client/index.cjs';
4
4
  export { C as CheckReason, a as CheckState, b as CheckType, D as DocReason, F as FaceMatchReason, H as HostedOtpView, c as HostedSessionView, d as HostedStepView, L as LivenessReason, P as PhoneOtpReason, e as PopulationReason, S as SessionOutcome, f as SessionStatus } from './hosted-client-BpvBqu9f.cjs';
5
- import './capture-session-v3-CAoWM8iT.cjs';
5
+ import './capture-session-v3-COIO_F2w.cjs';
6
6
  import './detect-worker-CKXHlXx9.cjs';
package/dist/index.d.ts CHANGED
@@ -1,6 +1,6 @@
1
- export { C as CaptureChannel, a as CaptureError, b as CaptureErrorKind, c as CaptureState, d as CapturedArtifacts, D as DEFAULT_API_ORIGIN, G as GateHint, e as GateUpdate, L as LivenessCaptureEvents, f as LivenessCaptureHandle, g as LivenessCaptureOptions, R as ReasonCode, S as SdkFailureReason, V as Verification, h as VerificationEvents, i as VerificationLocale, j as VerificationOptions, k as VerificationResult, l as VerificationStatus, m as createLivenessCapture, n as createVerification } from './create-verification-CjLnJ0w6.js';
1
+ export { C as CaptureChannel, a as CaptureError, b as CaptureErrorKind, c as CaptureState, d as CapturedArtifacts, D as DEFAULT_API_ORIGIN, G as GateHint, e as GateUpdate, L as LivenessCaptureEvents, f as LivenessCaptureHandle, g as LivenessCaptureOptions, R as ReasonCode, S as SdkFailureReason, V as Verification, h as VerificationEvents, i as VerificationLocale, j as VerificationOptions, k as VerificationResult, l as VerificationStatus, m as createLivenessCapture, n as createVerification } from './create-verification-CswF2As-.js';
2
2
  export { OpenHostedOptions, PopupBlocked, PopupHandle, SEKYRO_EVENTS, SekyroEvent, SekyroEventName, openHosted } from './popup/index.js';
3
3
  export { HostedApiError, KNOWN_CODES, KnownCode, isKnownCode } from './client/index.js';
4
4
  export { C as CheckReason, a as CheckState, b as CheckType, D as DocReason, F as FaceMatchReason, H as HostedOtpView, c as HostedSessionView, d as HostedStepView, L as LivenessReason, P as PhoneOtpReason, e as PopulationReason, S as SessionOutcome, f as SessionStatus } from './hosted-client-BpvBqu9f.js';
5
- import './capture-session-v3-BJ8ciaWl.js';
5
+ import './capture-session-v3-CvIfcwST.js';
6
6
  import './detect-worker-CKXHlXx9.js';
package/dist/index.js CHANGED
@@ -6,8 +6,8 @@ import {
6
6
  DEFAULT_API_ORIGIN,
7
7
  createLivenessCapture,
8
8
  createVerification
9
- } from "./chunk-BPYVZUJA.js";
10
- import "./chunk-LOTAJDRE.js";
9
+ } from "./chunk-FIXX2AXC.js";
10
+ import "./chunk-7TC6TOZ4.js";
11
11
  import {
12
12
  HostedApiError,
13
13
  KNOWN_CODES,
@@ -2466,10 +2466,12 @@ var V3_GATE_DEFAULTS = Object.freeze({
2466
2466
  MOTION_TAU_S: 0.4,
2467
2467
  MOTION_DEADBAND_IOD_PER_S: 0.1,
2468
2468
  READY_WINDOW_MS: 500,
2469
- // 0.7→0.75 with the trimmed window: trimming forgives exactly ONE flaky
2470
- // tick; the raised mean keeps a SECOND bad tick (a real sustained wobble)
2471
- // from diluting through at 10 Hz cadences.
2472
- READY_MEAN_Q: 0.75,
2469
+ // (READY_MEAN_Q, the former 0.75 window MEAN, is gone — 2026-10-17 field
2470
+ // bug: a steady q anywhere in [Q_GOOD, 0.75) saturated p at 1, passed every
2471
+ // guide ("hold still") and could never reach the mean, so the ring sat full
2472
+ // and green with nothing recording. Readiness now checks the window against
2473
+ // Q_GOOD, which keeps the one-flaky-tick forgiveness and the second-bad-tick
2474
+ // block without a dead band above the rise threshold.)
2473
2475
  GUIDE_SIZE: 0.6,
2474
2476
  GUIDE_CENTERING: 0.6,
2475
2477
  GUIDE_POSE: 0.6,
@@ -2547,8 +2549,7 @@ var FaceGateV3 = class {
2547
2549
  const worstIndex = windowSamples.indexOf(worst);
2548
2550
  windowSamples = windowSamples.filter((_2, index) => index !== worstIndex);
2549
2551
  }
2550
- const windowMean = windowSamples.reduce((sum, value) => sum + value, 0) / Math.max(1, windowSamples.length);
2551
- const ready = this.p >= 1 && windowMean >= this.t.READY_MEAN_Q;
2552
+ const ready = this.p >= 1 && windowSamples.every((sample) => sample >= this.t.Q_GOOD);
2552
2553
  return {
2553
2554
  at: timestampMs,
2554
2555
  q,
@@ -3167,6 +3168,14 @@ function createLivenessCaptureInternal(options, internals = {}) {
3167
3168
  let animations = "full";
3168
3169
  let recordingStartedAt = null;
3169
3170
  let frozenAt = null;
3171
+ let frameWidth = 0;
3172
+ let frameHeight = 0;
3173
+ const latchFrameSize = () => {
3174
+ if (options.video.videoWidth > 0 && options.video.videoHeight > 0) {
3175
+ frameWidth = options.video.videoWidth;
3176
+ frameHeight = options.video.videoHeight;
3177
+ }
3178
+ };
3170
3179
  const setState = (next) => {
3171
3180
  state = next;
3172
3181
  emitter.emit("state", next);
@@ -3187,10 +3196,13 @@ function createLivenessCaptureInternal(options, internals = {}) {
3187
3196
  faceDetected = false;
3188
3197
  recordingStartedAt = null;
3189
3198
  frozenAt = null;
3199
+ frameWidth = 0;
3200
+ frameHeight = 0;
3190
3201
  }
3191
3202
  setState(next);
3192
3203
  syncProfile();
3193
3204
  if (next === "recording") {
3205
+ latchFrameSize();
3194
3206
  recordingStartedAt = now();
3195
3207
  hint = "hold";
3196
3208
  progress = 1;
@@ -3198,6 +3210,7 @@ function createLivenessCaptureInternal(options, internals = {}) {
3198
3210
  }
3199
3211
  }),
3200
3212
  engine.on("checks", (payload) => {
3213
+ latchFrameSize();
3201
3214
  progress = payload.progress;
3202
3215
  faceDetected = payload.factors.presence > 0;
3203
3216
  emitGate();
@@ -3217,8 +3230,8 @@ function createLivenessCaptureInternal(options, internals = {}) {
3217
3230
  keyframe: artifacts.keyframe,
3218
3231
  ...artifacts.clip !== void 0 ? { clip: artifacts.clip } : {},
3219
3232
  ...artifacts.clipMimeType !== void 0 ? { clipMime: artifacts.clipMimeType } : {},
3220
- width: options.video.videoWidth,
3221
- height: options.video.videoHeight,
3233
+ width: options.video.videoWidth || frameWidth,
3234
+ height: options.video.videoHeight || frameHeight,
3222
3235
  ...clipMs !== void 0 ? { clipMs } : {},
3223
3236
  captureChannel: detectIsMobile() ? "mobile" : "desktop",
3224
3237
  ...degraded ? { degraded: "NO_RECORDER" } : {}