agentroam-runtime-darwin-arm64 0.2.0-preview.63 → 0.2.0-preview.64
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/manifest.json +2 -2
- package/package.json +1 -1
- package/runtime/.next/BUILD_ID +1 -1
- package/runtime/.next/app-build-manifest.json +8 -8
- package/runtime/.next/app-path-routes-manifest.json +1 -1
- package/runtime/.next/build-manifest.json +3 -3
- package/runtime/.next/prerender-manifest.json +1 -1
- package/runtime/.next/required-server-files.json +1 -1
- package/runtime/.next/server/app/_not-found/page.js +1 -1
- package/runtime/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
- package/runtime/.next/server/app/_not-found.html +1 -1
- package/runtime/.next/server/app/_not-found.rsc +1 -1
- package/runtime/.next/server/app/api/agent/abort/route.js +1 -1
- package/runtime/.next/server/app/api/agent/answer/route.js +1 -1
- package/runtime/.next/server/app/api/agent/codex-sharing/route.js +1 -1
- package/runtime/.next/server/app/api/agent/harness/status/route.js +1 -1
- package/runtime/.next/server/app/api/agent/model/route.js +1 -1
- package/runtime/.next/server/app/api/agent/models/route.js +1 -1
- package/runtime/.next/server/app/api/agent/run/route.js +2 -2
- package/runtime/.next/server/app/api/agent/runtime-health/route.js +1 -1
- package/runtime/.next/server/app/api/agent/steer/route.js +1 -1
- package/runtime/.next/server/app/api/agent/stream/route.js +3 -3
- package/runtime/.next/server/app/api/agent-workspaces/[workspaceId]/sessions/route.js +1 -1
- package/runtime/.next/server/app/api/agent-workspaces/route.js +1 -1
- package/runtime/.next/server/app/api/auth/verify/route.js +1 -1
- package/runtime/.next/server/app/api/business/route.js +1 -1
- package/runtime/.next/server/app/api/client-logs/route.js +1 -1
- package/runtime/.next/server/app/api/collaboration/route.js +1 -1
- package/runtime/.next/server/app/api/flow/v1/catalog/route.js +1 -1
- package/runtime/.next/server/app/api/flow/v1/runs/[runId]/cancel/route.js +1 -1
- package/runtime/.next/server/app/api/flow/v1/runs/[runId]/events/route.js +3 -3
- package/runtime/.next/server/app/api/flow/v1/runs/route.js +1 -1
- package/runtime/.next/server/app/api/flow-studio/config/route.js +1 -1
- package/runtime/.next/server/app/api/mcp/connect/route.js +1 -1
- package/runtime/.next/server/app/api/mcp/disconnect/route.js +1 -1
- package/runtime/.next/server/app/api/mcp/servers/route.js +1 -1
- package/runtime/.next/server/app/api/memory/[key]/route.js +1 -1
- package/runtime/.next/server/app/api/memory/route.js +1 -1
- package/runtime/.next/server/app/api/plugins/load/route.js +1 -1
- package/runtime/.next/server/app/api/projects/[id]/route.js +1 -1
- package/runtime/.next/server/app/api/projects/check/route.js +1 -1
- package/runtime/.next/server/app/api/projects/directories/route.js +1 -1
- package/runtime/.next/server/app/api/projects/roots/route.js +1 -1
- package/runtime/.next/server/app/api/projects/route.js +1 -1
- package/runtime/.next/server/app/api/push/subscribe/route.js +2 -2
- package/runtime/.next/server/app/api/push/unsubscribe/route.js +2 -2
- package/runtime/.next/server/app/api/push/vapid/route.js +2 -2
- package/runtime/.next/server/app/api/push/vapid.body +1 -1
- package/runtime/.next/server/app/api/remote-tools/register/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/[id]/changes/route.js +2 -2
- package/runtime/.next/server/app/api/sessions/[id]/fork/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/[id]/fork-at/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/[id]/goals/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/[id]/handoff/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/[id]/native-goal/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/[id]/query-index/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/[id]/release/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/[id]/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/[id]/thread-goal/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/[id]/tool-result/route.js +1 -1
- package/runtime/.next/server/app/api/sessions/route.js +1 -1
- package/runtime/.next/server/app/api/settings/route.js +1 -1
- package/runtime/.next/server/app/api/skills/route.js +1 -1
- package/runtime/.next/server/app/api/tool-policies/[policyId]/route.js +1 -1
- package/runtime/.next/server/app/api/tool-policies/route.js +1 -1
- package/runtime/.next/server/app/api/tools/route.js +1 -1
- package/runtime/.next/server/app/api/update/check/route.js +1 -1
- package/runtime/.next/server/app/api/update/install/route.js +1 -1
- package/runtime/.next/server/app/api/update/status/route.js +1 -1
- package/runtime/.next/server/app/api/web-auth/login/route.js +1 -1
- package/runtime/.next/server/app/api/web-auth/logout/route.js +1 -1
- package/runtime/.next/server/app/api/web-auth/revoke-all/route.js +1 -1
- package/runtime/.next/server/app/api/web-auth/setup/route.js +1 -1
- package/runtime/.next/server/app/api/web-auth/status/route.js +1 -1
- package/runtime/.next/server/app/api/web-console/bootstrap/route.js +1 -1
- package/runtime/.next/server/app/api/web-console/computer-settings/route.js +1 -1
- package/runtime/.next/server/app/api/web-console/computers/route.js +1 -1
- package/runtime/.next/server/app/api/web-console/device-state/route.js +1 -1
- package/runtime/.next/server/app/api/web-console/history/route.js +1 -1
- package/runtime/.next/server/app/api/web-console/preferences/route.js +1 -1
- package/runtime/.next/server/app/web/page.js +4 -4
- package/runtime/.next/server/app/web/page_client-reference-manifest.js +1 -1
- package/runtime/.next/server/app-paths-manifest.json +33 -33
- package/runtime/.next/server/chunks/5303.js +1 -1
- package/runtime/.next/server/middleware-build-manifest.js +1 -1
- package/runtime/.next/server/pages/404.html +1 -1
- package/runtime/.next/server/pages/500.html +1 -1
- package/runtime/.next/server/server-reference-manifest.json +1 -1
- package/runtime/.next/static/chunks/app/web/{error-7ac82267d3330344.js → error-4d3646f97c1344d3.js} +1 -1
- package/runtime/.next/static/chunks/app/web/layout-c8709c08fb7ad857.js +1 -0
- package/runtime/.next/static/chunks/app/web/page-b876912c109021db.js +1 -0
- package/runtime/.next/static/chunks/{main-app-51ee029f2d3c9d9e.js → main-app-00dfdb2d5c09719c.js} +1 -1
- package/runtime/native/Support.noindex/AgentRoam Remote Desktop.app/Contents/MacOS/agentroam-remote-desktop +0 -0
- package/runtime/native/Support.noindex/AgentRoam Remote Desktop.app/Contents/Resources/agentroam-component.json +1 -1
- package/runtime/native/Support.noindex/AgentRoam Remote Desktop.app/Contents/_CodeSignature/CodeResources +2 -2
- package/runtime/node_modules/.package-lock.json +19 -14
- package/runtime/node_modules/@agent/native-runtime/dist/index.js +572 -93
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/bridge.mjs +71 -71
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/browser-sdk.js +37 -37
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/core-36zyfan5.mjs +52 -0
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/{core-p79weg14.mjs → core-5682eevd.mjs} +4 -4
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/core-nne0e2ds.mjs +40 -0
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/{core-mh5qmqqf.mjs → core-xpxe8nzb.mjs} +1 -1
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/core.mjs +10 -10
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/manifest.json +19 -20
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/manifest.zst.json +23 -24
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/package.json +14 -14
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/sdk.mjs +74 -74
- package/runtime/node_modules/caniuse-lite/data/agents.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/browserVersions.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/aac.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/abortcontroller.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/ac3-ec3.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/accelerometer.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/addeventlistener.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/alternate-stylesheet.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/ambient-light.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/apng.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/array-find-index.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/array-find.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/array-flat.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/array-includes.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/arrow-functions.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/asmjs.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/async-clipboard.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/async-functions.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/atob-btoa.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/audio-api.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/audio.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/audiotracks.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/autofocus.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/auxclick.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/av1.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/avif.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/background-attachment.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/background-clip-text.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/background-img-opts.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/background-position-x-y.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/background-repeat-round-space.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/background-sync.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/battery-status.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/beacon.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/beforeafterprint.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/bigint.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/blobbuilder.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/bloburls.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/border-image.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/border-radius.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/broadcastchannel.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/brotli.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/calc.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/canvas-blending.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/canvas-text.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/canvas.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/ch-unit.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/chacha20-poly1305.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/channel-messaging.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/childnode-remove.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/classlist.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/client-hints-dpr-width-viewport.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/clipboard.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/colr-v1.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/colr.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/comparedocumentposition.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/console-basic.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/console-time.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/const.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/constraint-validation.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/contenteditable.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/contentsecuritypolicy.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/contentsecuritypolicy2.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/cookie-store-api.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/cors.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/createimagebitmap.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/credential-management.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/cross-document-view-transitions.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/cryptography.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-all.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-anchor-positioning.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-animation.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-any-link.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-appearance.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-at-counter-style.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-autofill.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-backdrop-filter.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-background-offsets.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-backgroundblendmode.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-boxdecorationbreak.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-boxshadow.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-canvas.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-caret-color.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-cascade-layers.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-cascade-scope.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-case-insensitive.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-clip-path.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-color-adjust.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-color-function.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-conic-gradients.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-container-queries-style.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-container-queries.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-container-query-units.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-containment.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-content-visibility.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-counters.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-crisp-edges.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-cross-fade.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-default-pseudo.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-descendant-gtgt.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-deviceadaptation.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-dir-pseudo.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-display-contents.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-element-function.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-env-function.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-exclusions.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-featurequeries.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-file-selector-button.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-filter-function.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-filters.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-first-letter.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-first-line.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-fixed.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-focus-visible.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-focus-within.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-font-palette.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-font-rendering-controls.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-font-stretch.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-gencontent.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-gradients.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-grid-animation.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-grid-lanes.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-grid.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-hanging-punctuation.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-has.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-hyphens.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-if.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-image-orientation.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-image-set.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-in-out-of-range.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-indeterminate-pseudo.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-initial-letter.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-initial-value.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-lch-lab.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-letter-spacing.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-line-clamp.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-logical-props.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-marker-pseudo.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-masks.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-matches-pseudo.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-math-functions.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-media-interaction.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-media-range-syntax.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-media-resolution.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-media-scripting.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-mediaqueries.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-mixblendmode.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-module-scripts.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-motion-paths.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-namespaces.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-nesting.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-not-sel-list.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-nth-child-of.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-opacity.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-optional-pseudo.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-overflow-anchor.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-overflow-overlay.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-overflow.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-overscroll-behavior.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-page-break.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-paged-media.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-paint-api.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-placeholder-shown.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-placeholder.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-print-color-adjust.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-read-only-write.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-rebeccapurple.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-reflections.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-regions.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-relative-colors.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-repeating-gradients.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-resize.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-revert-value.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-rrggbbaa.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-scroll-behavior.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-scrollbar.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-sel2.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-sel3.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-selection.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-shapes.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-snappoints.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-sticky.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-subgrid.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-supports-api.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-table.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-text-align-last.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-text-box-trim.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-text-indent.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-text-justify.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-text-orientation.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-text-spacing.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-text-wrap-balance.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-textshadow.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-touch-action.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-transitions.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-unicode-bidi.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-unset-value.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-variables.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-when-else.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-widows-orphans.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-width-stretch.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-writing-mode.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css-zoom.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css3-attr.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css3-boxsizing.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css3-colors.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css3-cursors-grab.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css3-cursors-newer.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css3-cursors.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/css3-tabsize.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/currentcolor.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/custom-elements.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/custom-elementsv1.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/customevent.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/customizable-select.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/datalist.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/dataset.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/datauri.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/date-tolocaledatestring.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/declarative-shadow-dom.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/decorators.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/details.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/deviceorientation.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/devicepixelratio.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/dialog.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/dispatchevent.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/dnssec.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/do-not-track.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/document-currentscript.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/document-evaluate-xpath.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/document-execcommand.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/document-policy.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/document-scrollingelement.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/documenthead.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/dom-manip-convenience.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/dom-range.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/domcontentloaded.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/dommatrix.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/download.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/dragndrop.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/element-closest.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/element-from-point.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/element-scroll-methods.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/eme.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/eot.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/es5.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/es6-class.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/es6-generators.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/es6-module-dynamic-import.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/es6-module.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/es6-number.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/es6-string-includes.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/es6.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/eventsource.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/extended-system-fonts.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/feature-policy.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/fetch.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/fieldset-disabled.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/fileapi.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/filereader.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/filereadersync.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/filesystem.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/flac.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/flexbox-gap.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/flexbox.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/flow-root.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/focusin-focusout-events.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/font-family-system-ui.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/font-feature.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/font-kerning.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/font-loading.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/font-size-adjust.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/font-smooth.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/font-unicode-range.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/font-variant-alternates.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/font-variant-numeric.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/fontface.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/form-attribute.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/form-submit-attributes.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/form-validation.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/forms.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/fullscreen.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/gamepad.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/geolocation.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/getboundingclientrect.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/getcomputedstyle.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/getelementsbyclassname.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/getrandomvalues.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/gyroscope.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/hardwareconcurrency.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/hashchange.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/heif.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/hevc.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/hidden.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/high-resolution-time.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/history.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/html-media-capture.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/html5semantic.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/http-live-streaming.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/http2.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/http3.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/iframe-sandbox.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/iframe-seamless.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/iframe-srcdoc.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/imagecapture.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/ime.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/img-naturalwidth-naturalheight.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/import-maps.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/imports.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/indeterminate-checkbox.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/indexeddb.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/indexeddb2.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/inline-block.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/innertext.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/input-autocomplete-onoff.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/input-color.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/input-datetime.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/input-email-tel-url.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/input-event.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/input-file-accept.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/input-file-directory.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/input-file-multiple.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/input-inputmode.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/input-minlength.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/input-number.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/input-pattern.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/input-placeholder.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/input-range.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/input-search.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/input-selection.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/insert-adjacent.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/insertadjacenthtml.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/internationalization.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/intersectionobserver-v2.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/intersectionobserver.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/intl-pluralrules.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/intrinsic-width.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/jpeg2000.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/jpegxl.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/jpegxr.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/js-regexp-lookbehind.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/json.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/justify-content-space-evenly.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/kerning-pairs-ligatures.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/keyboardevent-charcode.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/keyboardevent-code.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/keyboardevent-getmodifierstate.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/keyboardevent-key.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/keyboardevent-location.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/keyboardevent-which.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/lazyload.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/let.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/link-icon-png.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/link-icon-svg.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/link-rel-dns-prefetch.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/link-rel-modulepreload.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/link-rel-preconnect.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/link-rel-prefetch.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/link-rel-preload.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/link-rel-prerender.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/loading-lazy-attr.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/loading-lazy-media.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/localecompare.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/magnetometer.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/matchesselector.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/matchmedia.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/mathml.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/maxlength.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/mdn-css-backdrop-pseudo-element.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/mdn-css-unicode-bidi-isolate-override.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/mdn-css-unicode-bidi-isolate.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/mdn-css-unicode-bidi-plaintext.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/mdn-text-decoration-color.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/mdn-text-decoration-line.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/mdn-text-decoration-shorthand.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/mdn-text-decoration-style.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/media-fragments.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/mediacapture-fromelement.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/mediarecorder.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/mediasource.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/menu.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/meta-theme-color.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/meter.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/midi.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/minmaxwh.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/mp3.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/mpeg-dash.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/mpeg4.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/multibackgrounds.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/multicolumn.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/mutation-events.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/mutationobserver.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/namevalue-storage.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/native-filesystem-api.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/nav-timing.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/netinfo.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/notifications.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/object-entries.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/object-fit.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/object-observe.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/object-values.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/objectrtc.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/offline-apps.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/offscreencanvas.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/ogg-vorbis.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/ogv.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/ol-reversed.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/once-event-listener.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/online-status.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/opus.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/orientation-sensor.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/outline.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/pad-start-end.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/page-transition-events.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/pagevisibility.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/passive-event-listener.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/passkeys.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/passwordrules.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/path2d.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/payment-request.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/pdf-viewer.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/permissions-api.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/permissions-policy.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/picture-in-picture.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/picture.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/ping.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/png-alpha.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/pointer-events.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/pointer.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/pointerlock.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/portals.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/prefers-color-scheme.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/prefers-reduced-motion.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/progress.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/promise-finally.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/promises.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/proximity.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/proxy.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/publickeypinning.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/push-api.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/queryselector.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/readonly-attr.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/referrer-policy.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/registerprotocolhandler.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/rel-noopener.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/rel-noreferrer.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/rellist.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/rem.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/requestanimationframe.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/requestidlecallback.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/resizeobserver.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/resource-timing.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/rest-parameters.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/rtcpeerconnection.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/ruby.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/run-in.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/same-site-cookie-attribute.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/screen-orientation.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/script-async.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/script-defer.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/scrollintoview.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/scrollintoviewifneeded.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/sdch.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/selection-api.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/server-timing.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/serviceworkers.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/setimmediate.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/shadowdom.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/shadowdomv1.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/sharedarraybuffer.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/sharedworkers.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/sni.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/spdy.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/speech-recognition.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/speech-synthesis.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/spellcheck-attribute.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/sql-storage.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/srcset.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/stream.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/streams.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/stricttransportsecurity.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/style-scoped.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/subresource-bundling.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/subresource-integrity.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/svg-css.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/svg-filters.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/svg-fonts.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/svg-fragment.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/svg-html.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/svg-html5.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/svg-img.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/svg-smil.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/svg.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/sxg.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/tabindex-attr.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/template-literals.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/template.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/temporal.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/testfeat.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/text-decoration.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/text-emphasis.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/text-overflow.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/text-size-adjust.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/text-stroke.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/textcontent.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/textencoder.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/tls1-1.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/tls1-2.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/tls1-3.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/touch.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/transforms2d.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/transforms3d.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/trusted-types.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/ttf.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/typedarrays.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/u2f.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/unhandledrejection.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/upgradeinsecurerequests.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/url-scroll-to-text-fragment.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/url.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/urlsearchparams.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/use-strict.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/user-select-none.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/user-timing.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/variable-fonts.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/vector-effect.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/vibration.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/video.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/videotracks.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/view-transitions.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/viewport-unit-variants.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/viewport-units.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/wai-aria.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/wake-lock.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/wasm-bigint.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/wasm-bulk-memory.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/wasm-extended-const.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/wasm-gc.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/wasm-multi-memory.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/wasm-multi-value.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/wasm-mutable-globals.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/wasm-nontrapping-fptoint.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/wasm-reference-types.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/wasm-relaxed-simd.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/wasm-signext.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/wasm-simd.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/wasm-tail-calls.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/wasm-threads.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/wasm.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/wav.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/wbr-element.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/web-animation.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/web-app-manifest.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/web-bluetooth.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/web-serial.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/web-share.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/webauthn.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/webcodecs.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/webgl.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/webgl2.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/webgpu.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/webhid.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/webkit-user-drag.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/webm.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/webnfc.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/webp.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/websockets.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/webtransport.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/webusb.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/webvr.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/webvtt.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/webworkers.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/webxr.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/will-change.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/woff.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/woff2.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/word-break.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/wordwrap.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/x-doc-messaging.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/x-frame-options.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/xhr2.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/xhtml.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/xhtmlsmil.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/xml-serializer.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/features/zstd.js +1 -1
- package/runtime/node_modules/caniuse-lite/data/versionGroups.js +1 -1
- package/runtime/node_modules/caniuse-lite/package.json +1 -1
- package/runtime/package-lock.json +43 -38
- package/runtime/server.js +1 -1
- package/runtime/webapp/dist/assets/{AiHubPane-D3O__UGN.js → AiHubPane-D1SGdI6y.js} +1 -1
- package/runtime/webapp/dist/assets/{App-DJXr24vO.js → App-Y_UUrP8i.js} +57 -57
- package/runtime/webapp/dist/assets/{BrowserLivePanel-DEl_6FZj.js → BrowserLivePanel-CapyOwFL.js} +2 -2
- package/runtime/webapp/dist/assets/{CollaborationDashboard-DhLKl7mR.js → CollaborationDashboard-CEF41i5J.js} +1 -1
- package/runtime/webapp/dist/assets/CollaborationPage-C8PN5oNe.js +16 -0
- package/runtime/webapp/dist/assets/{FilePreview-BQBYZYpb.js → FilePreview-BdB8syBQ.js} +3 -3
- package/runtime/webapp/dist/assets/{FileTree-CXiXQO4N.js → FileTree-Cf8wDAVy.js} +1 -1
- package/runtime/webapp/dist/assets/{FlowStudioPane-DUjBX_7t.js → FlowStudioPane-DuUmV_ki.js} +1 -1
- package/runtime/webapp/dist/assets/{RemoteDesktopPage-BDK0Mq5I.js → RemoteDesktopPage-DBoSlmlh.js} +1 -1
- package/runtime/webapp/dist/assets/{TerminalPane-L6DN1Y0T.js → TerminalPane-B2s2ff23.js} +1 -1
- package/runtime/webapp/dist/assets/{abnfDiagram-VCTEODGH-Dloq4lbc.js → abnfDiagram-VCTEODGH-CQ78RP8v.js} +1 -1
- package/runtime/webapp/dist/assets/{arc-DdmNhDp9.js → arc-B4CNFgtV.js} +1 -1
- package/runtime/webapp/dist/assets/{architectureDiagram-5GKGNRK7-BTqm_9oY.js → architectureDiagram-5GKGNRK7-B-pYUJdJ.js} +1 -1
- package/runtime/webapp/dist/assets/{artifact-links-BI9xeGhs.js → artifact-links-DrWFmMXT.js} +1 -1
- package/runtime/webapp/dist/assets/{blockDiagram-I7D4REHJ-jT-ztA_A.js → blockDiagram-I7D4REHJ-CEEpSPhh.js} +1 -1
- package/runtime/webapp/dist/assets/{c4Diagram-7LVT6UL2-DxX89YpZ.js → c4Diagram-7LVT6UL2-Bq7l-OxC.js} +1 -1
- package/runtime/webapp/dist/assets/channel-B0Az_kl0.js +1 -0
- package/runtime/webapp/dist/assets/{chunk-2Q5K7J3B-BgXNuFPn.js → chunk-2Q5K7J3B-B2yw0jQL.js} +1 -1
- package/runtime/webapp/dist/assets/{chunk-5VM5RSS4-Bv7-4JNt.js → chunk-5VM5RSS4-D7AIGjlP.js} +1 -1
- package/runtime/webapp/dist/assets/{chunk-F27PBJKO-BNSskrgg.js → chunk-F27PBJKO-_wNxBMaG.js} +1 -1
- package/runtime/webapp/dist/assets/{chunk-IMKFNOWR-C166MQKM.js → chunk-IMKFNOWR-bMSiSCLu.js} +1 -1
- package/runtime/webapp/dist/assets/{chunk-JWPE2WC7-Bl1a_rZ8.js → chunk-JWPE2WC7-Zu8gSQip.js} +1 -1
- package/runtime/webapp/dist/assets/{chunk-POPQ4Y6H-Ck6xvnVw.js → chunk-POPQ4Y6H-8G7L6RqL.js} +1 -1
- package/runtime/webapp/dist/assets/{chunk-SVP7TREG-h6j1DDv5.js → chunk-SVP7TREG-a6VVTk08.js} +1 -1
- package/runtime/webapp/dist/assets/{chunk-TICWLB2K-BFafTq0K.js → chunk-TICWLB2K-ddeHMudM.js} +1 -1
- package/runtime/webapp/dist/assets/{chunk-XXDRQBXY-BQPWRmrg.js → chunk-XXDRQBXY-DSuvta0Q.js} +1 -1
- package/runtime/webapp/dist/assets/classDiagram-ZZMXUADV-HNxe_TWF.js +1 -0
- package/runtime/webapp/dist/assets/classDiagram-v2-VYDZK3BY-HNxe_TWF.js +1 -0
- package/runtime/webapp/dist/assets/{clipboard-B2fwlVD5.js → clipboard-DS4Pu9OB.js} +1 -1
- package/runtime/webapp/dist/assets/{codeSyntax-VUYFxRDg.js → codeSyntax-BWSPpoSH.js} +1 -1
- package/runtime/webapp/dist/assets/{collaboration-CalhGKdD.js → collaboration-D7MlFa87.js} +1 -1
- package/runtime/webapp/dist/assets/{cose-bilkent-JH36ORCC-IgwThNmP.js → cose-bilkent-JH36ORCC-D1TkGbTC.js} +1 -1
- package/runtime/webapp/dist/assets/{cynefin-OW5HDTMX-kfamOzdb.js → cynefin-OW5HDTMX-CYPV2qwK.js} +1 -1
- package/runtime/webapp/dist/assets/{cynefinDiagram-5FMLGOSQ-TVskTO_2.js → cynefinDiagram-5FMLGOSQ-DH8spH6U.js} +1 -1
- package/runtime/webapp/dist/assets/{dagre-GXQ25YYZ-DA85rDs9.js → dagre-GXQ25YYZ-Dkv69aQ5.js} +1 -1
- package/runtime/webapp/dist/assets/{diagram-S7CK7UJ4-CK0LkDfU.js → diagram-S7CK7UJ4-Gl094s_z.js} +1 -1
- package/runtime/webapp/dist/assets/{diagram-UQ7AKVKN-Bkskt6g2.js → diagram-UQ7AKVKN-DKzCe2K6.js} +1 -1
- package/runtime/webapp/dist/assets/{diagram-VSXAHHWV-DN2UO2Hh.js → diagram-VSXAHHWV-Dq1LtLSa.js} +1 -1
- package/runtime/webapp/dist/assets/{diagram-VX7I27RA-BLSOCEKl.js → diagram-VX7I27RA-CN9QKehv.js} +1 -1
- package/runtime/webapp/dist/assets/{diagram-Z3DM3KII-DNr6MVnd.js → diagram-Z3DM3KII-1J67VxEA.js} +1 -1
- package/runtime/webapp/dist/assets/{ebnfDiagram-PWID7BFC-CRASUUeC.js → ebnfDiagram-PWID7BFC-CRyJYtkK.js} +1 -1
- package/runtime/webapp/dist/assets/{erDiagram-RLTQ6QDP-1VwQNW79.js → erDiagram-RLTQ6QDP-C0jVGZ7x.js} +1 -1
- package/runtime/webapp/dist/assets/{file-types-MDD5RUla.js → file-types-Bi7YTERW.js} +1 -1
- package/runtime/webapp/dist/assets/{flowDiagram-HODETNUW-DzhiH-fC.js → flowDiagram-HODETNUW-wm5Kefw0.js} +1 -1
- package/runtime/webapp/dist/assets/{ganttDiagram-EL5Y4UJY-DH8HcfJq.js → ganttDiagram-EL5Y4UJY-DN5F7ix3.js} +1 -1
- package/runtime/webapp/dist/assets/{gitGraphDiagram-WWUBYQGX-DYOG2d-R.js → gitGraphDiagram-WWUBYQGX-DcpXNY21.js} +1 -1
- package/runtime/webapp/dist/assets/{index-Bqpz5--c.js → index-Ddj6oQ7t.js} +3 -3
- package/runtime/webapp/dist/assets/index-hju2LxNM.css +1 -0
- package/runtime/webapp/dist/assets/{infoDiagram-27XIBGKW-DOjkALCi.js → infoDiagram-27XIBGKW-B1iXrK9c.js} +1 -1
- package/runtime/webapp/dist/assets/{ishikawaDiagram-5VMMS53U-DBXZxz82.js → ishikawaDiagram-5VMMS53U-C1jZv655.js} +1 -1
- package/runtime/webapp/dist/assets/{journeyDiagram-3NMN7TZE-DEpi9Fbd.js → journeyDiagram-3NMN7TZE-BRSFQ0r1.js} +1 -1
- package/runtime/webapp/dist/assets/{kanban-definition-UXKFOSKX-Chbcb2nn.js → kanban-definition-UXKFOSKX-Cl9je8cc.js} +1 -1
- package/runtime/webapp/dist/assets/{layout-0ld5oekM.js → layout-CKkSxSc4.js} +1 -1
- package/runtime/webapp/dist/assets/{linear-BCRtBckJ.js → linear-CC85eD8_.js} +1 -1
- package/runtime/webapp/dist/assets/{loader-circle-DGJsEr0r.js → loader-circle-C63zcjMg.js} +1 -1
- package/runtime/webapp/dist/assets/{mermaid.core-ByBSaE2T.js → mermaid.core-DIjc2ZR6.js} +5 -5
- package/runtime/webapp/dist/assets/{mindmap-definition-YA3MSWOX-BW9I4Kuv.js → mindmap-definition-YA3MSWOX-mJUtqDVt.js} +1 -1
- package/runtime/webapp/dist/assets/{page-DVdz2jp6.js → page-bnT1btVj.js} +6 -6
- package/runtime/webapp/dist/assets/{pegDiagram-XKGWAZYB-D9oxCTQA.js → pegDiagram-XKGWAZYB-Dt3xAyl2.js} +1 -1
- package/runtime/webapp/dist/assets/{pieDiagram-E7YTZNPT-Ca4vPJj3.js → pieDiagram-E7YTZNPT-DleFmb0m.js} +1 -1
- package/runtime/webapp/dist/assets/{quadrantDiagram-AXDQQJYC-DM9Go2ES.js → quadrantDiagram-AXDQQJYC-BpeD8UfU.js} +1 -1
- package/runtime/webapp/dist/assets/{railroadDiagram-O6MQD6OU-BinalW7_.js → railroadDiagram-O6MQD6OU-BBQ5ixic.js} +1 -1
- package/runtime/webapp/dist/assets/{requirementDiagram-BXWQKSXE-C4KXL_m1.js → requirementDiagram-BXWQKSXE-xO5TSQS3.js} +1 -1
- package/runtime/webapp/dist/assets/{rotate-ccw-DrBaBbCR.js → rotate-ccw-AmWkL3kV.js} +1 -1
- package/runtime/webapp/dist/assets/{rotate-cw-Ccsl7hB3.js → rotate-cw-DrY9cGmB.js} +1 -1
- package/runtime/webapp/dist/assets/{sankeyDiagram-P5KCCOFB-Ba3vi6ln.js → sankeyDiagram-P5KCCOFB-Fyt0-RhU.js} +1 -1
- package/runtime/webapp/dist/assets/{send-OgOSXSRs.js → send-ATfKaKHb.js} +1 -1
- package/runtime/webapp/dist/assets/{sequenceDiagram-WJ2MYXX4-DJzCQdxN.js → sequenceDiagram-WJ2MYXX4-xkFumv3g.js} +1 -1
- package/runtime/webapp/dist/assets/{sizeCapture-INFHLROL-DYsPME1d.js → sizeCapture-INFHLROL-Ch5NIy5j.js} +1 -1
- package/runtime/webapp/dist/assets/{smartphone-BaeWE4n-.js → smartphone-BL3ONtnq.js} +1 -1
- package/runtime/webapp/dist/assets/{stateDiagram-D77RDMKH-D2prIqK-.js → stateDiagram-D77RDMKH-BYyhiW6f.js} +1 -1
- package/runtime/webapp/dist/assets/stateDiagram-v2-MP3YSRHH-BbZH2Sb9.js +1 -0
- package/runtime/webapp/dist/assets/{swimlanes-42K2YHIH-NODzX6Rz.js → swimlanes-42K2YHIH-Da71LrsA.js} +1 -1
- package/runtime/webapp/dist/assets/swimlanesDiagram-VR7AAH4N-CxBioyEE.js +8 -0
- package/runtime/webapp/dist/assets/{timeline-definition-24CTP7MA-CTh1zdtP.js → timeline-definition-24CTP7MA-BaXSS2__.js} +1 -1
- package/runtime/webapp/dist/assets/{trash-2-DoqYR_LW.js → trash-2-DBC-hIuM.js} +1 -1
- package/runtime/webapp/dist/assets/{vennDiagram-4TSXK5OY-DyjbbvAr.js → vennDiagram-4TSXK5OY-D_V4cbSG.js} +1 -1
- package/runtime/webapp/dist/assets/{wardleyDiagram-VM6X3IG4-BFWVhSKh.js → wardleyDiagram-VM6X3IG4-C-31z3KF.js} +1 -1
- package/runtime/webapp/dist/assets/{web-W_qr76-r.js → web-C3itPQLn.js} +1 -1
- package/runtime/webapp/dist/assets/{web-BeDKAt7R.js → web-Co-fisS2.js} +1 -1
- package/runtime/webapp/dist/assets/{x-Dp1u7spG.js → x-qYJy8CK-.js} +1 -1
- package/runtime/webapp/dist/assets/{xychartDiagram-S5SC5T6Z-CkRP6Drf.js → xychartDiagram-S5SC5T6Z-DKF--ymA.js} +1 -1
- package/runtime/webapp/dist/index.html +2 -2
- package/runtime/.next/static/chunks/app/web/layout-4e2120c7c4a57f7c.js +0 -1
- package/runtime/.next/static/chunks/app/web/page-aa406cbaa5109651.js +0 -1
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/core-50f20fv8.mjs +0 -40
- package/runtime/node_modules/@anthropic-ai/claude-agent-sdk/core-x5tcx9zy.mjs +0 -52
- package/runtime/webapp/dist/assets/CollaborationPage-BCzxWWHA.js +0 -16
- package/runtime/webapp/dist/assets/channel-9wfiqrt1.js +0 -1
- package/runtime/webapp/dist/assets/classDiagram-ZZMXUADV-CTD9Lt2V.js +0 -1
- package/runtime/webapp/dist/assets/classDiagram-v2-VYDZK3BY-CTD9Lt2V.js +0 -1
- package/runtime/webapp/dist/assets/index-WGJ3Mevp.css +0 -1
- package/runtime/webapp/dist/assets/stateDiagram-v2-MP3YSRHH-tpTQhbGu.js +0 -1
- package/runtime/webapp/dist/assets/swimlanesDiagram-VR7AAH4N-CUH3ZqiP.js +0 -8
- /package/runtime/.next/static/{wybbbDbeFWOi1186WVCZe → 4yVGaJwabJff1LDiyzYia}/_buildManifest.js +0 -0
- /package/runtime/.next/static/{wybbbDbeFWOi1186WVCZe → 4yVGaJwabJff1LDiyzYia}/_ssgManifest.js +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./page-
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./page-bnT1btVj.js","./smartphone-BL3ONtnq.js","./x-qYJy8CK-.js","./artifact-links-DrWFmMXT.js","./trash-2-DBC-hIuM.js","./clipboard-DS4Pu9OB.js","./CollaborationTabBridge-Dqnn1SXm.js","./RemoteDesktopTabBridge-Cp9mLtcY.js","./CollaborationPage-C8PN5oNe.js","./collaboration-D7MlFa87.js","./collaboration-CXGccxVl.css","./loader-circle-C63zcjMg.js","./CollaborationDashboard-CEF41i5J.js","./file-types-Bi7YTERW.js","./CollaborationDashboard-CCXC6JuQ.css","./RemoteDesktopPage-DBoSlmlh.js","./BrowserLivePanel-CapyOwFL.js","./rotate-ccw-AmWkL3kV.js","./App-Y_UUrP8i.js","./FilePreview-BdB8syBQ.js","./FilePreview-Zls_kcY7.css","./send-ATfKaKHb.js","./rotate-cw-DrY9cGmB.js","./FileTree-Cf8wDAVy.js","./App-CMOzoP5A.css"])))=>i.map(i=>d[i]);
|
|
2
2
|
(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const c of document.querySelectorAll('link[rel="modulepreload"]'))o(c);new MutationObserver(c=>{for(const f of c)if(f.type==="childList")for(const g of f.addedNodes)g.tagName==="LINK"&&g.rel==="modulepreload"&&o(g)}).observe(document,{childList:!0,subtree:!0});function n(c){const f={};return c.integrity&&(f.integrity=c.integrity),c.referrerPolicy&&(f.referrerPolicy=c.referrerPolicy),c.crossOrigin==="use-credentials"?f.credentials="include":c.crossOrigin==="anonymous"?f.credentials="omit":f.credentials="same-origin",f}function o(c){if(c.ep)return;c.ep=!0;const f=n(c);fetch(c.href,f)}})();const A3="modulepreload",S3=function(e,t){return new URL(e,t).href},oh={},mi=function(t,n,o){let c=Promise.resolve();if(n&&n.length>0){const g=document.getElementsByTagName("link"),x=document.querySelector("meta[property=csp-nonce]"),w=(x==null?void 0:x.nonce)||(x==null?void 0:x.getAttribute("nonce"));c=Promise.allSettled(n.map(m=>{if(m=S3(m,o),m in oh)return;oh[m]=!0;const b=m.endsWith(".css"),E=b?'[rel="stylesheet"]':"";if(o)for(let R=g.length-1;R>=0;R--){const k=g[R];if(k.href===m&&(!b||k.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${m}"]${E}`))return;const S=document.createElement("link");if(S.rel=b?"stylesheet":A3,b||(S.as="script"),S.crossOrigin="",S.href=m,w&&S.setAttribute("nonce",w),document.head.appendChild(S),b)return new Promise((R,k)=>{S.addEventListener("load",R),S.addEventListener("error",()=>k(Error(`Unable to preload CSS for ${m}`)))})}))}function f(g){const x=new Event("vite:preloadError",{cancelable:!0});if(x.payload=g,window.dispatchEvent(x),!x.defaultPrevented)throw g}return c.then(g=>{for(const x of g||[])x.status==="rejected"&&f(x.reason);return t().catch(f)})};var mn=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function v2(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var y2={exports:{}},pc={},E2={exports:{}},Ae={};/**
|
|
3
3
|
* @license React
|
|
4
4
|
* react.production.min.js
|
|
@@ -468,7 +468,7 @@ Error generating stack: `+f.message+`
|
|
|
468
468
|
`),r.append(`>>
|
|
469
469
|
`),r.toString()}setMode(r){this.mode=r}setECLevel(r){this.ecLevel=r}setVersion(r){this.version=r}setMaskPattern(r){this.maskPattern=r}setMatrix(r){this.matrix=r}static isValidMaskPattern(r){return r>=0&&r<ui.NUM_MASK_PATTERNS}}ui.NUM_MASK_PATTERNS=8;class Ue extends m{}Ue.kind="WriterException";class he{constructor(){}static clearMatrix(r){r.clear(255)}static buildMatrix(r,i,s,a,l){he.clearMatrix(l),he.embedBasicPatterns(s,l),he.embedTypeInfo(i,a,l),he.maybeEmbedVersionInfo(s,l),he.embedDataBits(r,a,l)}static embedBasicPatterns(r,i){he.embedPositionDetectionPatternsAndSeparators(i),he.embedDarkDotAtLeftBottomCorner(i),he.maybeEmbedPositionAdjustmentPatterns(r,i),he.embedTimingPatterns(i)}static embedTypeInfo(r,i,s){const a=new W;he.makeTypeInfoBits(r,i,a);for(let l=0,u=a.getSize();l<u;++l){const d=a.get(a.getSize()-1-l),h=he.TYPE_INFO_COORDINATES[l],p=h[0],v=h[1];if(s.setBoolean(p,v,d),l<8){const C=s.getWidth()-l-1;s.setBoolean(C,8,d)}else{const A=s.getHeight()-7+(l-8);s.setBoolean(8,A,d)}}}static maybeEmbedVersionInfo(r,i){if(r.getVersionNumber()<7)return;const s=new W;he.makeVersionInfoBits(r,s);let a=6*3-1;for(let l=0;l<6;++l)for(let u=0;u<3;++u){const d=s.get(a);a--,i.setBoolean(l,i.getHeight()-11+u,d),i.setBoolean(i.getHeight()-11+u,l,d)}}static embedDataBits(r,i,s){let a=0,l=-1,u=s.getWidth()-1,d=s.getHeight()-1;for(;u>0;){for(u===6&&(u-=1);d>=0&&d<s.getHeight();){for(let h=0;h<2;++h){const p=u-h;if(!he.isEmpty(s.get(p,d)))continue;let v;a<r.getSize()?(v=r.get(a),++a):v=!1,i!==255&&ot.getDataMaskBit(i,p,d)&&(v=!v),s.setBoolean(p,d,v)}d+=l}l=-l,d+=l,u-=2}if(a!==r.getSize())throw new Ue("Not all bits consumed: "+a+"/"+r.getSize())}static findMSBSet(r){return 32-O.numberOfLeadingZeros(r)}static calculateBCHCode(r,i){if(i===0)throw new E("0 polynomial");const s=he.findMSBSet(i);for(r<<=s-1;he.findMSBSet(r)>=s;)r^=i<<he.findMSBSet(r)-s;return r}static makeTypeInfoBits(r,i,s){if(!ui.isValidMaskPattern(i))throw new Ue("Invalid mask pattern");const a=r.getBits()<<3|i;s.appendBits(a,5);const l=he.calculateBCHCode(a,he.TYPE_INFO_POLY);s.appendBits(l,10);const u=new W;if(u.appendBits(he.TYPE_INFO_MASK_PATTERN,15),s.xor(u),s.getSize()!==15)throw new Ue("should not happen but we got: "+s.getSize())}static makeVersionInfoBits(r,i){i.appendBits(r.getVersionNumber(),6);const s=he.calculateBCHCode(r.getVersionNumber(),he.VERSION_INFO_POLY);if(i.appendBits(s,12),i.getSize()!==18)throw new Ue("should not happen but we got: "+i.getSize())}static isEmpty(r){return r===255}static embedTimingPatterns(r){for(let i=8;i<r.getWidth()-8;++i){const s=(i+1)%2;he.isEmpty(r.get(i,6))&&r.setNumber(i,6,s),he.isEmpty(r.get(6,i))&&r.setNumber(6,i,s)}}static embedDarkDotAtLeftBottomCorner(r){if(r.get(8,r.getHeight()-8)===0)throw new Ue;r.setNumber(8,r.getHeight()-8,1)}static embedHorizontalSeparationPattern(r,i,s){for(let a=0;a<8;++a){if(!he.isEmpty(s.get(r+a,i)))throw new Ue;s.setNumber(r+a,i,0)}}static embedVerticalSeparationPattern(r,i,s){for(let a=0;a<7;++a){if(!he.isEmpty(s.get(r,i+a)))throw new Ue;s.setNumber(r,i+a,0)}}static embedPositionAdjustmentPattern(r,i,s){for(let a=0;a<5;++a){const l=he.POSITION_ADJUSTMENT_PATTERN[a];for(let u=0;u<5;++u)s.setNumber(r+u,i+a,l[u])}}static embedPositionDetectionPattern(r,i,s){for(let a=0;a<7;++a){const l=he.POSITION_DETECTION_PATTERN[a];for(let u=0;u<7;++u)s.setNumber(r+u,i+a,l[u])}}static embedPositionDetectionPatternsAndSeparators(r){const i=he.POSITION_DETECTION_PATTERN[0].length;he.embedPositionDetectionPattern(0,0,r),he.embedPositionDetectionPattern(r.getWidth()-i,0,r),he.embedPositionDetectionPattern(0,r.getWidth()-i,r);const s=8;he.embedHorizontalSeparationPattern(0,s-1,r),he.embedHorizontalSeparationPattern(r.getWidth()-s,s-1,r),he.embedHorizontalSeparationPattern(0,r.getWidth()-s,r);const a=7;he.embedVerticalSeparationPattern(a,0,r),he.embedVerticalSeparationPattern(r.getHeight()-a-1,0,r),he.embedVerticalSeparationPattern(a,r.getHeight()-a,r)}static maybeEmbedPositionAdjustmentPatterns(r,i){if(r.getVersionNumber()<2)return;const s=r.getVersionNumber()-1,a=he.POSITION_ADJUSTMENT_PATTERN_COORDINATE_TABLE[s];for(let l=0,u=a.length;l!==u;l++){const d=a[l];if(d>=0)for(let h=0;h!==u;h++){const p=a[h];p>=0&&he.isEmpty(i.get(p,d))&&he.embedPositionAdjustmentPattern(p-2,d-2,i)}}}}he.POSITION_DETECTION_PATTERN=Array.from([Int32Array.from([1,1,1,1,1,1,1]),Int32Array.from([1,0,0,0,0,0,1]),Int32Array.from([1,0,1,1,1,0,1]),Int32Array.from([1,0,1,1,1,0,1]),Int32Array.from([1,0,1,1,1,0,1]),Int32Array.from([1,0,0,0,0,0,1]),Int32Array.from([1,1,1,1,1,1,1])]),he.POSITION_ADJUSTMENT_PATTERN=Array.from([Int32Array.from([1,1,1,1,1]),Int32Array.from([1,0,0,0,1]),Int32Array.from([1,0,1,0,1]),Int32Array.from([1,0,0,0,1]),Int32Array.from([1,1,1,1,1])]),he.POSITION_ADJUSTMENT_PATTERN_COORDINATE_TABLE=Array.from([Int32Array.from([-1,-1,-1,-1,-1,-1,-1]),Int32Array.from([6,18,-1,-1,-1,-1,-1]),Int32Array.from([6,22,-1,-1,-1,-1,-1]),Int32Array.from([6,26,-1,-1,-1,-1,-1]),Int32Array.from([6,30,-1,-1,-1,-1,-1]),Int32Array.from([6,34,-1,-1,-1,-1,-1]),Int32Array.from([6,22,38,-1,-1,-1,-1]),Int32Array.from([6,24,42,-1,-1,-1,-1]),Int32Array.from([6,26,46,-1,-1,-1,-1]),Int32Array.from([6,28,50,-1,-1,-1,-1]),Int32Array.from([6,30,54,-1,-1,-1,-1]),Int32Array.from([6,32,58,-1,-1,-1,-1]),Int32Array.from([6,34,62,-1,-1,-1,-1]),Int32Array.from([6,26,46,66,-1,-1,-1]),Int32Array.from([6,26,48,70,-1,-1,-1]),Int32Array.from([6,26,50,74,-1,-1,-1]),Int32Array.from([6,30,54,78,-1,-1,-1]),Int32Array.from([6,30,56,82,-1,-1,-1]),Int32Array.from([6,30,58,86,-1,-1,-1]),Int32Array.from([6,34,62,90,-1,-1,-1]),Int32Array.from([6,28,50,72,94,-1,-1]),Int32Array.from([6,26,50,74,98,-1,-1]),Int32Array.from([6,30,54,78,102,-1,-1]),Int32Array.from([6,28,54,80,106,-1,-1]),Int32Array.from([6,32,58,84,110,-1,-1]),Int32Array.from([6,30,58,86,114,-1,-1]),Int32Array.from([6,34,62,90,118,-1,-1]),Int32Array.from([6,26,50,74,98,122,-1]),Int32Array.from([6,30,54,78,102,126,-1]),Int32Array.from([6,26,52,78,104,130,-1]),Int32Array.from([6,30,56,82,108,134,-1]),Int32Array.from([6,34,60,86,112,138,-1]),Int32Array.from([6,30,58,86,114,142,-1]),Int32Array.from([6,34,62,90,118,146,-1]),Int32Array.from([6,30,54,78,102,126,150]),Int32Array.from([6,24,50,76,102,128,154]),Int32Array.from([6,28,54,80,106,132,158]),Int32Array.from([6,32,58,84,110,136,162]),Int32Array.from([6,26,54,82,110,138,166]),Int32Array.from([6,30,58,86,114,142,170])]),he.TYPE_INFO_COORDINATES=Array.from([Int32Array.from([8,0]),Int32Array.from([8,1]),Int32Array.from([8,2]),Int32Array.from([8,3]),Int32Array.from([8,4]),Int32Array.from([8,5]),Int32Array.from([8,7]),Int32Array.from([8,8]),Int32Array.from([7,8]),Int32Array.from([5,8]),Int32Array.from([4,8]),Int32Array.from([3,8]),Int32Array.from([2,8]),Int32Array.from([1,8]),Int32Array.from([0,8])]),he.VERSION_INFO_POLY=7973,he.TYPE_INFO_POLY=1335,he.TYPE_INFO_MASK_PATTERN=21522;class g3{constructor(r,i){this.dataBytes=r,this.errorCorrectionBytes=i}getDataBytes(){return this.dataBytes}getErrorCorrectionBytes(){return this.errorCorrectionBytes}}class Ge{constructor(){}static calculateMaskPenalty(r){return ot.applyMaskPenaltyRule1(r)+ot.applyMaskPenaltyRule2(r)+ot.applyMaskPenaltyRule3(r)+ot.applyMaskPenaltyRule4(r)}static encode(r,i,s=null){let a=Ge.DEFAULT_BYTE_MODE_ENCODING;const l=s!==null&&s.get(vt.CHARACTER_SET)!==void 0;l&&(a=s.get(vt.CHARACTER_SET).toString());const u=this.chooseMode(r,a),d=new W;if(u===fe.BYTE&&(l||Ge.DEFAULT_BYTE_MODE_ENCODING!==a)){const J=z.getCharacterSetECIByName(a);J!==void 0&&this.appendECI(J,d)}this.appendModeInfo(u,d);const h=new W;this.appendBytes(r,u,h,a);let p;if(s!==null&&s.get(vt.QR_VERSION)!==void 0){const J=Number.parseInt(s.get(vt.QR_VERSION).toString(),10);p=ce.getVersionForNumber(J);const Z=this.calculateBitsNeeded(u,d,h,p);if(!this.willFit(Z,p,i))throw new Ue("Data too big for requested version")}else p=this.recommendVersion(i,u,d,h);const v=new W;v.appendBitArray(d);const C=u===fe.BYTE?h.getSizeInBytes():r.length;this.appendLengthInfo(C,p,u,v),v.appendBitArray(h);const A=p.getECBlocksForLevel(i),_=p.getTotalCodewords()-A.getTotalECCodewords();this.terminateBits(_,v);const M=this.interleaveWithECBytes(v,p.getTotalCodewords(),_,A.getNumBlocks()),P=new ui;P.setECLevel(i),P.setMode(u),P.setVersion(p);const U=p.getDimensionForVersion(),H=new ba(U,U),q=this.chooseMaskPattern(M,i,p,H);return P.setMaskPattern(q),he.buildMatrix(M,i,p,q,H),P.setMatrix(H),P}static recommendVersion(r,i,s,a){const l=this.calculateBitsNeeded(i,s,a,ce.getVersionForNumber(1)),u=this.chooseVersion(l,r),d=this.calculateBitsNeeded(i,s,a,u);return this.chooseVersion(d,r)}static calculateBitsNeeded(r,i,s,a){return i.getSize()+r.getCharacterCountBits(a)+s.getSize()}static getAlphanumericCode(r){return r<Ge.ALPHANUMERIC_TABLE.length?Ge.ALPHANUMERIC_TABLE[r]:-1}static chooseMode(r,i=null){if(z.SJIS.getName()===i&&this.isOnlyDoubleByteKanji(r))return fe.KANJI;let s=!1,a=!1;for(let l=0,u=r.length;l<u;++l){const d=r.charAt(l);if(Ge.isDigit(d))s=!0;else if(this.getAlphanumericCode(d.charCodeAt(0))!==-1)a=!0;else return fe.BYTE}return a?fe.ALPHANUMERIC:s?fe.NUMERIC:fe.BYTE}static isOnlyDoubleByteKanji(r){let i;try{i=we.encode(r,z.SJIS)}catch{return!1}const s=i.length;if(s%2!==0)return!1;for(let a=0;a<s;a+=2){const l=i[a]&255;if((l<129||l>159)&&(l<224||l>235))return!1}return!0}static chooseMaskPattern(r,i,s,a){let l=Number.MAX_SAFE_INTEGER,u=-1;for(let d=0;d<ui.NUM_MASK_PATTERNS;d++){he.buildMatrix(r,i,s,d,a);let h=this.calculateMaskPenalty(a);h<l&&(l=h,u=d)}return u}static chooseVersion(r,i){for(let s=1;s<=40;s++){const a=ce.getVersionForNumber(s);if(Ge.willFit(r,a,i))return a}throw new Ue("Data too big")}static willFit(r,i,s){const a=i.getTotalCodewords(),u=i.getECBlocksForLevel(s).getTotalECCodewords(),d=a-u,h=(r+7)/8;return d>=h}static terminateBits(r,i){const s=r*8;if(i.getSize()>s)throw new Ue("data bits cannot fit in the QR Code"+i.getSize()+" > "+s);for(let u=0;u<4&&i.getSize()<s;++u)i.appendBit(!1);const a=i.getSize()&7;if(a>0)for(let u=a;u<8;u++)i.appendBit(!1);const l=r-i.getSizeInBytes();for(let u=0;u<l;++u)i.appendBits(u&1?17:236,8);if(i.getSize()!==s)throw new Ue("Bits size does not equal capacity")}static getNumDataBytesAndNumECBytesForBlockID(r,i,s,a,l,u){if(a>=s)throw new Ue("Block ID too large");const d=r%s,h=s-d,p=Math.floor(r/s),v=p+1,C=Math.floor(i/s),A=C+1,_=p-C,M=v-A;if(_!==M)throw new Ue("EC bytes mismatch");if(s!==h+d)throw new Ue("RS blocks mismatch");if(r!==(C+_)*h+(A+M)*d)throw new Ue("Total bytes mismatch");a<h?(l[0]=C,u[0]=_):(l[0]=A,u[0]=M)}static interleaveWithECBytes(r,i,s,a){if(r.getSizeInBytes()!==s)throw new Ue("Number of bits and data bytes does not match");let l=0,u=0,d=0;const h=new Array;for(let v=0;v<a;++v){const C=new Int32Array(1),A=new Int32Array(1);Ge.getNumDataBytesAndNumECBytesForBlockID(i,s,a,v,C,A);const _=C[0],M=new Uint8Array(_);r.toBytes(8*l,M,0,_);const P=Ge.generateECBytes(M,A[0]);h.push(new g3(M,P)),u=Math.max(u,_),d=Math.max(d,P.length),l+=C[0]}if(s!==l)throw new Ue("Data bytes does not match offset");const p=new W;for(let v=0;v<u;++v)for(const C of h){const A=C.getDataBytes();v<A.length&&p.appendBits(A[v],8)}for(let v=0;v<d;++v)for(const C of h){const A=C.getErrorCorrectionBytes();v<A.length&&p.appendBits(A[v],8)}if(i!==p.getSizeInBytes())throw new Ue("Interleaving error: "+i+" and "+p.getSizeInBytes()+" differ.");return p}static generateECBytes(r,i){const s=r.length,a=new Int32Array(s+i);for(let u=0;u<s;u++)a[u]=r[u]&255;new du(Ne.QR_CODE_FIELD_256).encode(a,i);const l=new Uint8Array(i);for(let u=0;u<i;u++)l[u]=a[s+u];return l}static appendModeInfo(r,i){i.appendBits(r.getBits(),4)}static appendLengthInfo(r,i,s,a){const l=s.getCharacterCountBits(i);if(r>=1<<l)throw new Ue(r+" is bigger than "+((1<<l)-1));a.appendBits(r,l)}static appendBytes(r,i,s,a){switch(i){case fe.NUMERIC:Ge.appendNumericBytes(r,s);break;case fe.ALPHANUMERIC:Ge.appendAlphanumericBytes(r,s);break;case fe.BYTE:Ge.append8BitBytes(r,s,a);break;case fe.KANJI:Ge.appendKanjiBytes(r,s);break;default:throw new Ue("Invalid mode: "+i)}}static getDigit(r){return r.charCodeAt(0)-48}static isDigit(r){const i=Ge.getDigit(r);return i>=0&&i<=9}static appendNumericBytes(r,i){const s=r.length;let a=0;for(;a<s;){const l=Ge.getDigit(r.charAt(a));if(a+2<s){const u=Ge.getDigit(r.charAt(a+1)),d=Ge.getDigit(r.charAt(a+2));i.appendBits(l*100+u*10+d,10),a+=3}else if(a+1<s){const u=Ge.getDigit(r.charAt(a+1));i.appendBits(l*10+u,7),a+=2}else i.appendBits(l,4),a++}}static appendAlphanumericBytes(r,i){const s=r.length;let a=0;for(;a<s;){const l=Ge.getAlphanumericCode(r.charCodeAt(a));if(l===-1)throw new Ue;if(a+1<s){const u=Ge.getAlphanumericCode(r.charCodeAt(a+1));if(u===-1)throw new Ue;i.appendBits(l*45+u,11),a+=2}else i.appendBits(l,6),a++}}static append8BitBytes(r,i,s){let a;try{a=we.encode(r,s)}catch(l){throw new Ue(l)}for(let l=0,u=a.length;l!==u;l++){const d=a[l];i.appendBits(d,8)}}static appendKanjiBytes(r,i){let s;try{s=we.encode(r,z.SJIS)}catch(l){throw new Ue(l)}const a=s.length;for(let l=0;l<a;l+=2){const u=s[l]&255,d=s[l+1]&255,h=u<<8&4294967295|d;let p=-1;if(h>=33088&&h<=40956?p=h-33088:h>=57408&&h<=60351&&(p=h-49472),p===-1)throw new Ue("Invalid byte sequence");const v=(p>>8)*192+(p&255);i.appendBits(v,13)}}static appendECI(r,i){i.appendBits(fe.ECI.getBits(),4),i.appendBits(r.getValue(),8)}}Ge.ALPHANUMERIC_TABLE=Int32Array.from([-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,36,-1,-1,-1,37,38,-1,-1,-1,-1,39,40,-1,41,42,43,0,1,2,3,4,5,6,7,8,9,44,-1,-1,-1,-1,-1,-1,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,-1,-1,-1,-1,-1]),Ge.DEFAULT_BYTE_MODE_ENCODING=z.UTF8.getName();class fi{write(r,i,s,a=null){if(r.length===0)throw new E("Found empty contents");if(i<0||s<0)throw new E("Requested dimensions are too small: "+i+"x"+s);let l=Ve.L,u=fi.QUIET_ZONE_SIZE;a!==null&&(a.get(vt.ERROR_CORRECTION)!==void 0&&(l=Ve.fromString(a.get(vt.ERROR_CORRECTION).toString())),a.get(vt.MARGIN)!==void 0&&(u=Number.parseInt(a.get(vt.MARGIN).toString(),10)));const d=Ge.encode(r,l,a);return this.renderResult(d,i,s,u)}writeToDom(r,i,s,a,l=null){typeof r=="string"&&(r=document.querySelector(r));const u=this.write(i,s,a,l);r&&r.appendChild(u)}renderResult(r,i,s,a){const l=r.getMatrix();if(l===null)throw new Yr;const u=l.getWidth(),d=l.getHeight(),h=u+a*2,p=d+a*2,v=Math.max(i,h),C=Math.max(s,p),A=Math.min(Math.floor(v/h),Math.floor(C/p)),_=Math.floor((v-u*A)/2),M=Math.floor((C-d*A)/2),P=this.createSVGElement(v,C);for(let U=0,H=M;U<d;U++,H+=A)for(let q=0,J=_;q<u;q++,J+=A)if(l.get(q,U)===1){const Z=this.createSvgRectElement(J,H,A,A);P.appendChild(Z)}return P}createSVGElement(r,i){const s=document.createElementNS(fi.SVG_NS,"svg");return s.setAttributeNS(null,"height",r.toString()),s.setAttributeNS(null,"width",i.toString()),s}createSvgRectElement(r,i,s,a){const l=document.createElementNS(fi.SVG_NS,"rect");return l.setAttributeNS(null,"x",r.toString()),l.setAttributeNS(null,"y",i.toString()),l.setAttributeNS(null,"height",s.toString()),l.setAttributeNS(null,"width",a.toString()),l.setAttributeNS(null,"fill","#000000"),l}}fi.QUIET_ZONE_SIZE=4,fi.SVG_NS="http://www.w3.org/2000/svg";class ji{encode(r,i,s,a,l){if(r.length===0)throw new E("Found empty contents");if(i!==ae.QR_CODE)throw new E("Can only encode QR_CODE, but got "+i);if(s<0||a<0)throw new E(`Requested dimensions are too small: ${s}x${a}`);let u=Ve.L,d=ji.QUIET_ZONE_SIZE;l!==null&&(l.get(vt.ERROR_CORRECTION)!==void 0&&(u=Ve.fromString(l.get(vt.ERROR_CORRECTION).toString())),l.get(vt.MARGIN)!==void 0&&(d=Number.parseInt(l.get(vt.MARGIN).toString(),10)));const h=Ge.encode(r,u,l);return ji.renderResult(h,s,a,d)}static renderResult(r,i,s,a){const l=r.getMatrix();if(l===null)throw new Yr;const u=l.getWidth(),d=l.getHeight(),h=u+a*2,p=d+a*2,v=Math.max(i,h),C=Math.max(s,p),A=Math.min(Math.floor(v/h),Math.floor(C/p)),_=Math.floor((v-u*A)/2),M=Math.floor((C-d*A)/2),P=new Se(v,C);for(let U=0,H=M;U<d;U++,H+=A)for(let q=0,J=_;q<u;q++,J+=A)l.get(q,U)===1&&P.setRegion(J,H,A,A);return P}}ji.QUIET_ZONE_SIZE=4;class p3{encode(r,i,s,a,l){let u;switch(i){case ae.QR_CODE:u=new ji;break;default:throw new E("No encoder available for format "+i)}return u.encode(r,i,s,a,l)}}class qr extends te{constructor(r,i,s,a,l,u,d,h){if(super(u,d),this.yuvData=r,this.dataWidth=i,this.dataHeight=s,this.left=a,this.top=l,a+u>i||l+d>s)throw new E("Crop rectangle does not fit within image data.");h&&this.reverseHorizontal(u,d)}getRow(r,i){if(r<0||r>=this.getHeight())throw new E("Requested row is outside the image: "+r);const s=this.getWidth();(i==null||i.length<s)&&(i=new Uint8ClampedArray(s));const a=(r+this.top)*this.dataWidth+this.left;return D.arraycopy(this.yuvData,a,i,0,s),i}getMatrix(){const r=this.getWidth(),i=this.getHeight();if(r===this.dataWidth&&i===this.dataHeight)return this.yuvData;const s=r*i,a=new Uint8ClampedArray(s);let l=this.top*this.dataWidth+this.left;if(r===this.dataWidth)return D.arraycopy(this.yuvData,l,a,0,s),a;for(let u=0;u<i;u++){const d=u*r;D.arraycopy(this.yuvData,l,a,d,r),l+=this.dataWidth}return a}isCropSupported(){return!0}crop(r,i,s,a){return new qr(this.yuvData,this.dataWidth,this.dataHeight,this.left+r,this.top+i,s,a,!1)}renderThumbnail(){const r=this.getWidth()/qr.THUMBNAIL_SCALE_FACTOR,i=this.getHeight()/qr.THUMBNAIL_SCALE_FACTOR,s=new Int32Array(r*i),a=this.yuvData;let l=this.top*this.dataWidth+this.left;for(let u=0;u<i;u++){const d=u*r;for(let h=0;h<r;h++){const p=a[l+h*qr.THUMBNAIL_SCALE_FACTOR]&255;s[d+h]=4278190080|p*65793}l+=this.dataWidth*qr.THUMBNAIL_SCALE_FACTOR}return s}getThumbnailWidth(){return this.getWidth()/qr.THUMBNAIL_SCALE_FACTOR}getThumbnailHeight(){return this.getHeight()/qr.THUMBNAIL_SCALE_FACTOR}reverseHorizontal(r,i){const s=this.yuvData;for(let a=0,l=this.top*this.dataWidth+this.left;a<i;a++,l+=this.dataWidth){const u=l+r/2;for(let d=l,h=l+r-1;d<u;d++,h--){const p=s[d];s[d]=s[h],s[h]=p}}}invert(){return new ue(this)}}qr.THUMBNAIL_SCALE_FACTOR=2;class hu extends te{constructor(r,i,s,a,l,u,d){if(super(i,s),this.dataWidth=a,this.dataHeight=l,this.left=u,this.top=d,r.BYTES_PER_ELEMENT===4){const h=i*s,p=new Uint8ClampedArray(h);for(let v=0;v<h;v++){const C=r[v],A=C>>16&255,_=C>>7&510,M=C&255;p[v]=(A+_+M)/4&255}this.luminances=p}else this.luminances=r;if(a===void 0&&(this.dataWidth=i),l===void 0&&(this.dataHeight=s),u===void 0&&(this.left=0),d===void 0&&(this.top=0),this.left+i>this.dataWidth||this.top+s>this.dataHeight)throw new E("Crop rectangle does not fit within image data.")}getRow(r,i){if(r<0||r>=this.getHeight())throw new E("Requested row is outside the image: "+r);const s=this.getWidth();(i==null||i.length<s)&&(i=new Uint8ClampedArray(s));const a=(r+this.top)*this.dataWidth+this.left;return D.arraycopy(this.luminances,a,i,0,s),i}getMatrix(){const r=this.getWidth(),i=this.getHeight();if(r===this.dataWidth&&i===this.dataHeight)return this.luminances;const s=r*i,a=new Uint8ClampedArray(s);let l=this.top*this.dataWidth+this.left;if(r===this.dataWidth)return D.arraycopy(this.luminances,l,a,0,s),a;for(let u=0;u<i;u++){const d=u*r;D.arraycopy(this.luminances,l,a,d,r),l+=this.dataWidth}return a}isCropSupported(){return!0}crop(r,i,s,a){return new hu(this.luminances,s,a,this.dataWidth,this.dataHeight,this.left+r,this.top+i)}invert(){return new ue(this)}}class th extends z{static forName(r){return this.getCharacterSetECIByName(r)}}class gu{}gu.ISO_8859_1=z.ISO8859_1;class rh{isCompact(){return this.compact}setCompact(r){this.compact=r}getSize(){return this.size}setSize(r){this.size=r}getLayers(){return this.layers}setLayers(r){this.layers=r}getCodeWords(){return this.codeWords}setCodeWords(r){this.codeWords=r}getMatrix(){return this.matrix}setMatrix(r){this.matrix=r}}class nh{static singletonList(r){return[r]}static min(r,i){return r.sort(i)[0]}}class m3{constructor(r){this.previous=r}getPrevious(){return this.previous}}class Wi extends m3{constructor(r,i,s){super(r),this.value=i,this.bitCount=s}appendTo(r,i){r.appendBits(this.value,this.bitCount)}add(r,i){return new Wi(this,r,i)}addBinaryShift(r,i){return console.warn("addBinaryShift on SimpleToken, this simply returns a copy of this token"),new Wi(this,r,i)}toString(){let r=this.value&(1<<this.bitCount)-1;return r|=1<<this.bitCount,"<"+O.toBinaryString(r|1<<this.bitCount).substring(1)+">"}}class pu extends Wi{constructor(r,i,s){super(r,0,0),this.binaryShiftStart=i,this.binaryShiftByteCount=s}appendTo(r,i){for(let s=0;s<this.binaryShiftByteCount;s++)(s===0||s===31&&this.binaryShiftByteCount<=62)&&(r.appendBits(31,5),this.binaryShiftByteCount>62?r.appendBits(this.binaryShiftByteCount-31,16):s===0?r.appendBits(Math.min(this.binaryShiftByteCount,31),5):r.appendBits(this.binaryShiftByteCount-31,5)),r.appendBits(i[this.binaryShiftStart+s],8)}addBinaryShift(r,i){return new pu(this,r,i)}toString(){return"<"+this.binaryShiftStart+"::"+(this.binaryShiftStart+this.binaryShiftByteCount-1)+">"}}function x3(y,r,i){return new pu(y,r,i)}function Gs(y,r,i){return new Wi(y,r,i)}const w3=["UPPER","LOWER","DIGIT","MIXED","PUNCT"],Pn=0,Aa=1,Ir=2,ih=3,Jr=4,v3=new Wi(null,0,0),mu=[Int32Array.from([0,(5<<16)+28,(5<<16)+30,(5<<16)+29,656318]),Int32Array.from([(9<<16)+480+14,0,(5<<16)+30,(5<<16)+29,656318]),Int32Array.from([(4<<16)+14,(9<<16)+448+28,0,(9<<16)+448+29,932798]),Int32Array.from([(5<<16)+29,(5<<16)+28,656318,0,(5<<16)+30]),Int32Array.from([(5<<16)+31,656380,656382,656381,0])];function y3(y){for(let r of y)I.fill(r,-1);return y[Pn][Jr]=0,y[Aa][Jr]=0,y[Aa][Pn]=28,y[ih][Jr]=0,y[Ir][Jr]=0,y[Ir][Pn]=15,y}const sh=y3(I.createInt32Array(6,6));class en{constructor(r,i,s,a){this.token=r,this.mode=i,this.binaryShiftByteCount=s,this.bitCount=a}getMode(){return this.mode}getToken(){return this.token}getBinaryShiftByteCount(){return this.binaryShiftByteCount}getBitCount(){return this.bitCount}latchAndAppend(r,i){let s=this.bitCount,a=this.token;if(r!==this.mode){let u=mu[this.mode][r];a=Gs(a,u&65535,u>>16),s+=u>>16}let l=r===Ir?4:5;return a=Gs(a,i,l),new en(a,r,0,s+l)}shiftAndAppend(r,i){let s=this.token,a=this.mode===Ir?4:5;return s=Gs(s,sh[this.mode][r],a),s=Gs(s,i,5),new en(s,this.mode,0,this.bitCount+a+5)}addBinaryShiftChar(r){let i=this.token,s=this.mode,a=this.bitCount;if(this.mode===Jr||this.mode===Ir){let d=mu[s][Pn];i=Gs(i,d&65535,d>>16),a+=d>>16,s=Pn}let l=this.binaryShiftByteCount===0||this.binaryShiftByteCount===31?18:this.binaryShiftByteCount===62?9:8,u=new en(i,s,this.binaryShiftByteCount+1,a+l);return u.binaryShiftByteCount===2078&&(u=u.endBinaryShift(r+1)),u}endBinaryShift(r){if(this.binaryShiftByteCount===0)return this;let i=this.token;return i=x3(i,r-this.binaryShiftByteCount,this.binaryShiftByteCount),new en(i,this.mode,0,this.bitCount)}isBetterThanOrEqualTo(r){let i=this.bitCount+(mu[this.mode][r.mode]>>16);return this.binaryShiftByteCount<r.binaryShiftByteCount?i+=en.calculateBinaryShiftCost(r)-en.calculateBinaryShiftCost(this):this.binaryShiftByteCount>r.binaryShiftByteCount&&r.binaryShiftByteCount>0&&(i+=10),i<=r.bitCount}toBitArray(r){let i=[];for(let a=this.endBinaryShift(r.length).token;a!==null;a=a.getPrevious())i.unshift(a);let s=new W;for(const a of i)a.appendTo(s,r);return s}toString(){return ne.format("%s bits=%d bytes=%d",w3[this.mode],this.bitCount,this.binaryShiftByteCount)}static calculateBinaryShiftCost(r){return r.binaryShiftByteCount>62?21:r.binaryShiftByteCount>31?20:r.binaryShiftByteCount>0?10:0}}en.INITIAL_STATE=new en(v3,Pn,0,0);function E3(y){const r=ne.getCharCode(" "),i=ne.getCharCode("."),s=ne.getCharCode(",");y[Pn][r]=1;const a=ne.getCharCode("Z"),l=ne.getCharCode("A");for(let A=l;A<=a;A++)y[Pn][A]=A-l+2;y[Aa][r]=1;const u=ne.getCharCode("z"),d=ne.getCharCode("a");for(let A=d;A<=u;A++)y[Aa][A]=A-d+2;y[Ir][r]=1;const h=ne.getCharCode("9"),p=ne.getCharCode("0");for(let A=p;A<=h;A++)y[Ir][A]=A-p+2;y[Ir][s]=12,y[Ir][i]=13;const v=["\0"," ","","","","","","","\x07","\b"," ",`
|
|
470
470
|
`,"\v","\f","\r","\x1B","","","","","@","\\","^","_","`","|","~",""];for(let A=0;A<v.length;A++)y[ih][ne.getCharCode(v[A])]=A;const C=["\0","\r","\0","\0","\0","\0","!","'","#","$","%","&","'","(",")","*","+",",","-",".","/",":",";","<","=",">","?","[","]","{","}"];for(let A=0;A<C.length;A++)ne.getCharCode(C[A])>0&&(y[Jr][ne.getCharCode(C[A])]=A);return y}const xu=E3(I.createInt32Array(5,256));class Xs{constructor(r){this.text=r}encode(){const r=ne.getCharCode(" "),i=ne.getCharCode(`
|
|
471
|
-
`);let s=nh.singletonList(en.INITIAL_STATE);for(let l=0;l<this.text.length;l++){let u,d=l+1<this.text.length?this.text[l+1]:0;switch(this.text[l]){case ne.getCharCode("\r"):u=d===i?2:0;break;case ne.getCharCode("."):u=d===r?3:0;break;case ne.getCharCode(","):u=d===r?4:0;break;case ne.getCharCode(":"):u=d===r?5:0;break;default:u=0}u>0?(s=Xs.updateStateListForPair(s,l,u),l++):s=this.updateStateListForChar(s,l)}return nh.min(s,(l,u)=>l.getBitCount()-u.getBitCount()).toBitArray(this.text)}updateStateListForChar(r,i){const s=[];for(let a of r)this.updateStateForChar(a,i,s);return Xs.simplifyStates(s)}updateStateForChar(r,i,s){let a=this.text[i]&255,l=xu[r.getMode()][a]>0,u=null;for(let d=0;d<=Jr;d++){let h=xu[d][a];if(h>0){if(u==null&&(u=r.endBinaryShift(i)),!l||d===r.getMode()||d===Ir){const p=u.latchAndAppend(d,h);s.push(p)}if(!l&&sh[r.getMode()][d]>=0){const p=u.shiftAndAppend(d,h);s.push(p)}}}if(r.getBinaryShiftByteCount()>0||xu[r.getMode()][a]===0){let d=r.addBinaryShiftChar(i);s.push(d)}}static updateStateListForPair(r,i,s){const a=[];for(let l of r)this.updateStateForPair(l,i,s,a);return this.simplifyStates(a)}static updateStateForPair(r,i,s,a){let l=r.endBinaryShift(i);if(a.push(l.latchAndAppend(Jr,s)),r.getMode()!==Jr&&a.push(l.shiftAndAppend(Jr,s)),s===3||s===4){let u=l.latchAndAppend(Ir,16-s).latchAndAppend(Ir,1);a.push(u)}if(r.getBinaryShiftByteCount()>0){let u=r.addBinaryShiftChar(i).addBinaryShiftChar(i+1);a.push(u)}}static simplifyStates(r){let i=[];for(const s of r){let a=!0;for(const l of i){if(l.isBetterThanOrEqualTo(s)){a=!1;break}s.isBetterThanOrEqualTo(l)&&(i=i.filter(u=>u!==l))}a&&i.push(s)}return i}}class _e{constructor(){}static encodeBytes(r){return _e.encode(r,_e.DEFAULT_EC_PERCENT,_e.DEFAULT_AZTEC_LAYERS)}static encode(r,i,s){let a=new Xs(r).encode(),l=O.truncDivision(a.getSize()*i,100)+11,u=a.getSize()+l,d,h,p,v,C;if(s!==_e.DEFAULT_AZTEC_LAYERS){if(d=s<0,h=Math.abs(s),h>(d?_e.MAX_NB_BITS_COMPACT:_e.MAX_NB_BITS))throw new E(ne.format("Illegal value %s for layers",s));p=_e.totalBitsInLayer(h,d),v=_e.WORD_SIZE[h];let Z=p-p%v;if(C=_e.stuffBits(a,v),C.getSize()+l>Z)throw new E("Data to large for user specified layer");if(d&&C.getSize()>v*64)throw new E("Data to large for user specified layer")}else{v=0,C=null;for(let Z=0;;Z++){if(Z>_e.MAX_NB_BITS)throw new E("Data too large for an Aztec code");if(d=Z<=3,h=d?Z+1:Z,p=_e.totalBitsInLayer(h,d),u>p)continue;(C==null||v!==_e.WORD_SIZE[h])&&(v=_e.WORD_SIZE[h],C=_e.stuffBits(a,v));let Ie=p-p%v;if(!(d&&C.getSize()>v*64)&&C.getSize()+l<=Ie)break}}let A=_e.generateCheckWords(C,p,v),_=C.getSize()/v,M=_e.generateModeMessage(d,h,_),P=(d?11:14)+h*4,U=new Int32Array(P),H;if(d){H=P;for(let Z=0;Z<U.length;Z++)U[Z]=Z}else{H=P+1+2*O.truncDivision(O.truncDivision(P,2)-1,15);let Z=O.truncDivision(P,2),Ie=O.truncDivision(H,2);for(let ve=0;ve<Z;ve++){let nr=ve+O.truncDivision(ve,15);U[Z-ve-1]=Ie-nr-1,U[Z+ve]=Ie+nr+1}}let q=new Se(H);for(let Z=0,Ie=0;Z<h;Z++){let ve=(h-Z)*4+(d?9:12);for(let nr=0;nr<ve;nr++){let Pr=nr*2;for(let ir=0;ir<2;ir++)A.get(Ie+Pr+ir)&&q.set(U[Z*2+ir],U[Z*2+nr]),A.get(Ie+ve*2+Pr+ir)&&q.set(U[Z*2+nr],U[P-1-Z*2-ir]),A.get(Ie+ve*4+Pr+ir)&&q.set(U[P-1-Z*2-ir],U[P-1-Z*2-nr]),A.get(Ie+ve*6+Pr+ir)&&q.set(U[P-1-Z*2-nr],U[Z*2+ir])}Ie+=ve*8}if(_e.drawModeMessage(q,d,H,M),d)_e.drawBullsEye(q,O.truncDivision(H,2),5);else{_e.drawBullsEye(q,O.truncDivision(H,2),7);for(let Z=0,Ie=0;Z<O.truncDivision(P,2)-1;Z+=15,Ie+=16)for(let ve=O.truncDivision(H,2)&1;ve<H;ve+=2)q.set(O.truncDivision(H,2)-Ie,ve),q.set(O.truncDivision(H,2)+Ie,ve),q.set(ve,O.truncDivision(H,2)-Ie),q.set(ve,O.truncDivision(H,2)+Ie)}let J=new rh;return J.setCompact(d),J.setSize(H),J.setLayers(h),J.setCodeWords(_),J.setMatrix(q),J}static drawBullsEye(r,i,s){for(let a=0;a<s;a+=2)for(let l=i-a;l<=i+a;l++)r.set(l,i-a),r.set(l,i+a),r.set(i-a,l),r.set(i+a,l);r.set(i-s,i-s),r.set(i-s+1,i-s),r.set(i-s,i-s+1),r.set(i+s,i-s),r.set(i+s,i-s+1),r.set(i+s,i+s-1)}static generateModeMessage(r,i,s){let a=new W;return r?(a.appendBits(i-1,2),a.appendBits(s-1,6),a=_e.generateCheckWords(a,28,4)):(a.appendBits(i-1,5),a.appendBits(s-1,11),a=_e.generateCheckWords(a,40,4)),a}static drawModeMessage(r,i,s,a){let l=O.truncDivision(s,2);if(i)for(let u=0;u<7;u++){let d=l-3+u;a.get(u)&&r.set(d,l-5),a.get(u+7)&&r.set(l+5,d),a.get(20-u)&&r.set(d,l+5),a.get(27-u)&&r.set(l-5,d)}else for(let u=0;u<10;u++){let d=l-5+u+O.truncDivision(u,5);a.get(u)&&r.set(d,l-7),a.get(u+10)&&r.set(l+7,d),a.get(29-u)&&r.set(d,l+7),a.get(39-u)&&r.set(l-7,d)}}static generateCheckWords(r,i,s){let a=r.getSize()/s,l=new du(_e.getGF(s)),u=O.truncDivision(i,s),d=_e.bitsToWords(r,s,u);l.encode(d,u-a);let h=i%s,p=new W;p.appendBits(0,h);for(const v of Array.from(d))p.appendBits(v,s);return p}static bitsToWords(r,i,s){let a=new Int32Array(s),l,u;for(l=0,u=r.getSize()/i;l<u;l++){let d=0;for(let h=0;h<i;h++)d|=r.get(l*i+h)?1<<i-h-1:0;a[l]=d}return a}static getGF(r){switch(r){case 4:return Ne.AZTEC_PARAM;case 6:return Ne.AZTEC_DATA_6;case 8:return Ne.AZTEC_DATA_8;case 10:return Ne.AZTEC_DATA_10;case 12:return Ne.AZTEC_DATA_12;default:throw new E("Unsupported word size "+r)}}static stuffBits(r,i){let s=new W,a=r.getSize(),l=(1<<i)-2;for(let u=0;u<a;u+=i){let d=0;for(let h=0;h<i;h++)(u+h>=a||r.get(u+h))&&(d|=1<<i-1-h);(d&l)===l?(s.appendBits(d&l,i),u--):d&l?s.appendBits(d,i):(s.appendBits(d|1,i),u--)}return s}static totalBitsInLayer(r,i){return((i?88:112)+16*r)*r}}_e.DEFAULT_EC_PERCENT=33,_e.DEFAULT_AZTEC_LAYERS=0,_e.MAX_NB_BITS=32,_e.MAX_NB_BITS_COMPACT=4,_e.WORD_SIZE=Int32Array.from([4,6,6,8,8,8,8,8,8,10,10,10,10,10,10,10,10,10,10,10,10,10,10,12,12,12,12,12,12,12,12,12,12]);class Sa{encode(r,i,s,a){return this.encodeWithHints(r,i,s,a,null)}encodeWithHints(r,i,s,a,l){let u=gu.ISO_8859_1,d=_e.DEFAULT_EC_PERCENT,h=_e.DEFAULT_AZTEC_LAYERS;return l!=null&&(l.has(vt.CHARACTER_SET)&&(u=th.forName(l.get(vt.CHARACTER_SET).toString())),l.has(vt.ERROR_CORRECTION)&&(d=O.parseInt(l.get(vt.ERROR_CORRECTION).toString())),l.has(vt.AZTEC_LAYERS)&&(h=O.parseInt(l.get(vt.AZTEC_LAYERS).toString()))),Sa.encodeLayers(r,i,s,a,u,d,h)}static encodeLayers(r,i,s,a,l,u,d){if(i!==ae.AZTEC)throw new E("Can only encode AZTEC, but got "+i);let h=_e.encode(ne.getBytes(r,l),u,d);return Sa.renderResult(h,s,a)}static renderResult(r,i,s){let a=r.getMatrix();if(a==null)throw new Yr;let l=a.getWidth(),u=a.getHeight(),d=Math.max(i,l),h=Math.max(s,u),p=Math.min(d/l,h/u),v=(d-l*p)/2,C=(h-u*p)/2,A=new Se(d,h);for(let _=0,M=C;_<u;_++,M+=p)for(let P=0,U=v;P<l;P++,U+=p)a.get(P,_)&&A.setRegion(U,M,p,p);return A}}n.AbstractExpandedDecoder=ru,n.ArgumentException=b,n.ArithmeticException=ha,n.AztecCode=rh,n.AztecCodeReader=ma,n.AztecCodeWriter=Sa,n.AztecDecoder=$e,n.AztecDetector=z0,n.AztecDetectorResult=j0,n.AztecEncoder=_e,n.AztecHighLevelEncoder=Xs,n.AztecPoint=Gt,n.BarcodeFormat=ae,n.Binarizer=k,n.BinaryBitmap=S,n.BitArray=W,n.BitMatrix=Se,n.BitSource=ou,n.BrowserAztecCodeReader=Xv,n.BrowserBarcodeReader=qv,n.BrowserCodeReader=_t,n.BrowserDatamatrixCodeReader=e3,n.BrowserMultiFormatReader=f3,n.BrowserPDF417Reader=d3,n.BrowserQRCodeReader=h3,n.BrowserQRCodeSvgWriter=fi,n.CharacterSetECI=z,n.ChecksumException=R,n.Code128Reader=ee,n.Code39Reader=xt,n.DataMatrixDecodedBitStreamParser=Nn,n.DataMatrixReader=kn,n.DecodeHintType=L,n.DecoderResult=Bs,n.DefaultGridSampler=W0,n.DetectorResult=pa,n.EAN13Reader=oi,n.EncodeHintType=vt,n.Exception=m,n.FormatException=B,n.GenericGF=Ne,n.GenericGFPoly=Jt,n.GlobalHistogramBinarizer=Pe,n.GridSampler=qc,n.GridSamplerInstance=_n,n.HTMLCanvasElementLuminanceSource=ge,n.HybridBinarizer=xe,n.ITFReader=Fe,n.IllegalArgumentException=E,n.IllegalStateException=Yr,n.InvertedLuminanceSource=ue,n.LuminanceSource=te,n.MathUtils=Re,n.MultiFormatOneDReader=Fi,n.MultiFormatReader=eh,n.MultiFormatWriter=p3,n.NotFoundException=G,n.OneDReader=gt,n.PDF417DecodedBitStreamParser=$,n.PDF417DecoderErrorCorrection=Y0,n.PDF417Reader=kt,n.PDF417ResultMetadata=Z0,n.PerspectiveTransform=Dr,n.PlanarYUVLuminanceSource=qr,n.QRCodeByteMatrix=ba,n.QRCodeDataMask=Ar,n.QRCodeDecodedBitStreamParser=Je,n.QRCodeDecoderErrorCorrectionLevel=Ve,n.QRCodeDecoderFormatInformation=jt,n.QRCodeEncoder=Ge,n.QRCodeEncoderQRCode=ui,n.QRCodeMaskUtil=ot,n.QRCodeMatrixUtil=he,n.QRCodeMode=fe,n.QRCodeReader=Dn,n.QRCodeVersion=ce,n.QRCodeWriter=ji,n.RGBLuminanceSource=hu,n.RSS14Reader=st,n.RSSExpandedReader=K,n.ReaderException=Ca,n.ReedSolomonDecoder=Fs,n.ReedSolomonEncoder=du,n.ReedSolomonException=Mi,n.Result=ze,n.ResultMetadataType=qe,n.ResultPoint=le,n.StringUtils=ne,n.UnsupportedOperationException=re,n.VideoInputDevice=We,n.WhiteRectangleDetector=fn,n.WriterException=Ue,n.ZXingArrays=I,n.ZXingCharset=th,n.ZXingInteger=O,n.ZXingStandardCharsets=gu,n.ZXingStringBuilder=de,n.ZXingStringEncoding=we,n.ZXingSystem=D,n.createAbstractExpandedDecoder=G0,Object.defineProperty(n,"__esModule",{value:!0})})})(G1,G1.exports);var et=G1.exports;const cR=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"}));var t2=function(){function e(t,n,o){if(this.formatMap=new Map([[ie.QR_CODE,et.BarcodeFormat.QR_CODE],[ie.AZTEC,et.BarcodeFormat.AZTEC],[ie.CODABAR,et.BarcodeFormat.CODABAR],[ie.CODE_39,et.BarcodeFormat.CODE_39],[ie.CODE_93,et.BarcodeFormat.CODE_93],[ie.CODE_128,et.BarcodeFormat.CODE_128],[ie.DATA_MATRIX,et.BarcodeFormat.DATA_MATRIX],[ie.MAXICODE,et.BarcodeFormat.MAXICODE],[ie.ITF,et.BarcodeFormat.ITF],[ie.EAN_13,et.BarcodeFormat.EAN_13],[ie.EAN_8,et.BarcodeFormat.EAN_8],[ie.PDF_417,et.BarcodeFormat.PDF_417],[ie.RSS_14,et.BarcodeFormat.RSS_14],[ie.RSS_EXPANDED,et.BarcodeFormat.RSS_EXPANDED],[ie.UPC_A,et.BarcodeFormat.UPC_A],[ie.UPC_E,et.BarcodeFormat.UPC_E],[ie.UPC_EAN_EXTENSION,et.BarcodeFormat.UPC_EAN_EXTENSION]]),this.reverseFormatMap=this.createReverseFormatMap(),!cR)throw"Use html5qrcode.min.js without edit, ZXing not found.";this.verbose=n,this.logger=o;var c=this.createZXingFormats(t),f=new Map;f.set(et.DecodeHintType.POSSIBLE_FORMATS,c),f.set(et.DecodeHintType.TRY_HARDER,!1),this.hints=f}return e.prototype.decodeAsync=function(t){var n=this;return new Promise(function(o,c){try{o(n.decode(t))}catch(f){c(f)}})},e.prototype.decode=function(t){var n=new et.MultiFormatReader(this.verbose,this.hints),o=new et.HTMLCanvasElementLuminanceSource(t),c=new et.BinaryBitmap(new et.HybridBinarizer(o)),f=n.decode(c);return{text:f.text,format:Lv.create(this.toHtml5QrcodeSupportedFormats(f.format)),debugData:this.createDebugData()}},e.prototype.createReverseFormatMap=function(){var t=new Map;return this.formatMap.forEach(function(n,o,c){t.set(n,o)}),t},e.prototype.toHtml5QrcodeSupportedFormats=function(t){if(!this.reverseFormatMap.has(t))throw"reverseFormatMap doesn't have ".concat(t);return this.reverseFormatMap.get(t)},e.prototype.createZXingFormats=function(t){for(var n=[],o=0,c=t;o<c.length;o++){var f=c[o];this.formatMap.has(f)?n.push(this.formatMap.get(f)):this.logger.logError("".concat(f," is not supported by")+"ZXingHtml5QrcodeShim")}return n},e.prototype.createDebugData=function(){return{decoderName:"zxing-js"}},e}(),uR=function(e,t,n,o){function c(f){return f instanceof n?f:new n(function(g){g(f)})}return new(n||(n=Promise))(function(f,g){function x(b){try{m(o.next(b))}catch(E){g(E)}}function w(b){try{m(o.throw(b))}catch(E){g(E)}}function m(b){b.done?f(b.value):c(b.value).then(x,w)}m((o=o.apply(e,t||[])).next())})},fR=function(e,t){var n={label:0,sent:function(){if(f[0]&1)throw f[1];return f[1]},trys:[],ops:[]},o,c,f,g;return g={next:x(0),throw:x(1),return:x(2)},typeof Symbol=="function"&&(g[Symbol.iterator]=function(){return this}),g;function x(m){return function(b){return w([m,b])}}function w(m){if(o)throw new TypeError("Generator is already executing.");for(;g&&(g=0,m[0]&&(n=0)),n;)try{if(o=1,c&&(f=m[0]&2?c.return:m[0]?c.throw||((f=c.return)&&f.call(c),0):c.next)&&!(f=f.call(c,m[1])).done)return f;switch(c=0,f&&(m=[m[0]&2,f.value]),m[0]){case 0:case 1:f=m;break;case 4:return n.label++,{value:m[1],done:!1};case 5:n.label++,c=m[1],m=[0];continue;case 7:m=n.ops.pop(),n.trys.pop();continue;default:if(f=n.trys,!(f=f.length>0&&f[f.length-1])&&(m[0]===6||m[0]===2)){n=0;continue}if(m[0]===3&&(!f||m[1]>f[0]&&m[1]<f[3])){n.label=m[1];break}if(m[0]===6&&n.label<f[1]){n.label=f[1],f=m;break}if(f&&n.label<f[2]){n.label=f[2],n.ops.push(m);break}f[2]&&n.ops.pop(),n.trys.pop();continue}m=t.call(e,n)}catch(b){m=[6,b],c=0}finally{o=f=0}if(m[0]&5)throw m[1];return{value:m[0]?m[1]:void 0,done:!0}}},r2=function(){function e(t,n,o){if(this.formatMap=new Map([[ie.QR_CODE,"qr_code"],[ie.AZTEC,"aztec"],[ie.CODABAR,"codabar"],[ie.CODE_39,"code_39"],[ie.CODE_93,"code_93"],[ie.CODE_128,"code_128"],[ie.DATA_MATRIX,"data_matrix"],[ie.ITF,"itf"],[ie.EAN_13,"ean_13"],[ie.EAN_8,"ean_8"],[ie.PDF_417,"pdf417"],[ie.UPC_A,"upc_a"],[ie.UPC_E,"upc_e"]]),this.reverseFormatMap=this.createReverseFormatMap(),!e.isSupported())throw"Use html5qrcode.min.js without edit, Use BarcodeDetectorDelegate only if it isSupported();";this.verbose=n,this.logger=o;var c=this.createBarcodeDetectorFormats(t);if(this.detector=new BarcodeDetector(c),!this.detector)throw"BarcodeDetector detector not supported"}return e.isSupported=function(){if(!("BarcodeDetector"in window))return!1;var t=new BarcodeDetector({formats:["qr_code"]});return typeof t<"u"},e.prototype.decodeAsync=function(t){return uR(this,void 0,void 0,function(){var n,o;return fR(this,function(c){switch(c.label){case 0:return[4,this.detector.detect(t)];case 1:if(n=c.sent(),!n||n.length===0)throw"No barcode or QR code detected.";return o=this.selectLargestBarcode(n),[2,{text:o.rawValue,format:Lv.create(this.toHtml5QrcodeSupportedFormats(o.format)),debugData:this.createDebugData()}]}})})},e.prototype.selectLargestBarcode=function(t){for(var n=null,o=0,c=0,f=t;c<f.length;c++){var g=f[c],x=g.boundingBox.width*g.boundingBox.height;x>o&&(o=x,n=g)}if(!n)throw"No largest barcode found";return n},e.prototype.createBarcodeDetectorFormats=function(t){for(var n=[],o=0,c=t;o<c.length;o++){var f=c[o];this.formatMap.has(f)?n.push(this.formatMap.get(f)):this.logger.warn("".concat(f," is not supported by")+"BarcodeDetectorDelegate")}return{formats:n}},e.prototype.toHtml5QrcodeSupportedFormats=function(t){if(!this.reverseFormatMap.has(t))throw"reverseFormatMap doesn't have ".concat(t);return this.reverseFormatMap.get(t)},e.prototype.createReverseFormatMap=function(){var t=new Map;return this.formatMap.forEach(function(n,o,c){t.set(n,o)}),t},e.prototype.createDebugData=function(){return{decoderName:"BarcodeDetector"}},e}(),n2=function(e,t,n,o){function c(f){return f instanceof n?f:new n(function(g){g(f)})}return new(n||(n=Promise))(function(f,g){function x(b){try{m(o.next(b))}catch(E){g(E)}}function w(b){try{m(o.throw(b))}catch(E){g(E)}}function m(b){b.done?f(b.value):c(b.value).then(x,w)}m((o=o.apply(e,t||[])).next())})},i2=function(e,t){var n={label:0,sent:function(){if(f[0]&1)throw f[1];return f[1]},trys:[],ops:[]},o,c,f,g;return g={next:x(0),throw:x(1),return:x(2)},typeof Symbol=="function"&&(g[Symbol.iterator]=function(){return this}),g;function x(m){return function(b){return w([m,b])}}function w(m){if(o)throw new TypeError("Generator is already executing.");for(;g&&(g=0,m[0]&&(n=0)),n;)try{if(o=1,c&&(f=m[0]&2?c.return:m[0]?c.throw||((f=c.return)&&f.call(c),0):c.next)&&!(f=f.call(c,m[1])).done)return f;switch(c=0,f&&(m=[m[0]&2,f.value]),m[0]){case 0:case 1:f=m;break;case 4:return n.label++,{value:m[1],done:!1};case 5:n.label++,c=m[1],m=[0];continue;case 7:m=n.ops.pop(),n.trys.pop();continue;default:if(f=n.trys,!(f=f.length>0&&f[f.length-1])&&(m[0]===6||m[0]===2)){n=0;continue}if(m[0]===3&&(!f||m[1]>f[0]&&m[1]<f[3])){n.label=m[1];break}if(m[0]===6&&n.label<f[1]){n.label=f[1],f=m;break}if(f&&n.label<f[2]){n.label=f[2],n.ops.push(m);break}f[2]&&n.ops.pop(),n.trys.pop();continue}m=t.call(e,n)}catch(b){m=[6,b],c=0}finally{o=f=0}if(m[0]&5)throw m[1];return{value:m[0]?m[1]:void 0,done:!0}}},dR=function(){function e(t,n,o,c){this.EXECUTIONS_TO_REPORT_PERFORMANCE=100,this.executions=0,this.executionResults=[],this.wasPrimaryDecoderUsedInLastDecode=!1,this.verbose=o,n&&r2.isSupported()?(this.primaryDecoder=new r2(t,o,c),this.secondaryDecoder=new t2(t,o,c)):this.primaryDecoder=new t2(t,o,c)}return e.prototype.decodeAsync=function(t){return n2(this,void 0,void 0,function(){var n;return i2(this,function(o){switch(o.label){case 0:n=performance.now(),o.label=1;case 1:return o.trys.push([1,,3,4]),[4,this.getDecoder().decodeAsync(t)];case 2:return[2,o.sent()];case 3:return this.possiblyLogPerformance(n),[7];case 4:return[2]}})})},e.prototype.decodeRobustlyAsync=function(t){return n2(this,void 0,void 0,function(){var n,o;return i2(this,function(c){switch(c.label){case 0:n=performance.now(),c.label=1;case 1:return c.trys.push([1,3,4,5]),[4,this.primaryDecoder.decodeAsync(t)];case 2:return[2,c.sent()];case 3:if(o=c.sent(),this.secondaryDecoder)return[2,this.secondaryDecoder.decodeAsync(t)];throw o;case 4:return this.possiblyLogPerformance(n),[7];case 5:return[2]}})})},e.prototype.getDecoder=function(){return this.secondaryDecoder?this.wasPrimaryDecoderUsedInLastDecode===!1?(this.wasPrimaryDecoderUsedInLastDecode=!0,this.primaryDecoder):(this.wasPrimaryDecoderUsedInLastDecode=!1,this.secondaryDecoder):this.primaryDecoder},e.prototype.possiblyLogPerformance=function(t){if(this.verbose){var n=performance.now()-t;this.executionResults.push(n),this.executions++,this.possiblyFlushPerformanceReport()}},e.prototype.possiblyFlushPerformanceReport=function(){if(!(this.executions<this.EXECUTIONS_TO_REPORT_PERFORMANCE)){for(var t=0,n=0,o=this.executionResults;n<o.length;n++){var c=o[n];t+=c}var f=t/this.executionResults.length;console.log("".concat(f," ms for ").concat(this.executionResults.length," last runs.")),this.executions=0,this.executionResults=[]}},e}(),F0=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,c){o.__proto__=c}||function(o,c){for(var f in c)Object.prototype.hasOwnProperty.call(c,f)&&(o[f]=c[f])},e(t,n)};return function(t,n){if(typeof n!="function"&&n!==null)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");e(t,n);function o(){this.constructor=t}t.prototype=n===null?Object.create(n):(o.prototype=n.prototype,new o)}}(),uc=function(e,t,n,o){function c(f){return f instanceof n?f:new n(function(g){g(f)})}return new(n||(n=Promise))(function(f,g){function x(b){try{m(o.next(b))}catch(E){g(E)}}function w(b){try{m(o.throw(b))}catch(E){g(E)}}function m(b){b.done?f(b.value):c(b.value).then(x,w)}m((o=o.apply(e,t||[])).next())})},fc=function(e,t){var n={label:0,sent:function(){if(f[0]&1)throw f[1];return f[1]},trys:[],ops:[]},o,c,f,g;return g={next:x(0),throw:x(1),return:x(2)},typeof Symbol=="function"&&(g[Symbol.iterator]=function(){return this}),g;function x(m){return function(b){return w([m,b])}}function w(m){if(o)throw new TypeError("Generator is already executing.");for(;g&&(g=0,m[0]&&(n=0)),n;)try{if(o=1,c&&(f=m[0]&2?c.return:m[0]?c.throw||((f=c.return)&&f.call(c),0):c.next)&&!(f=f.call(c,m[1])).done)return f;switch(c=0,f&&(m=[m[0]&2,f.value]),m[0]){case 0:case 1:f=m;break;case 4:return n.label++,{value:m[1],done:!1};case 5:n.label++,c=m[1],m=[0];continue;case 7:m=n.ops.pop(),n.trys.pop();continue;default:if(f=n.trys,!(f=f.length>0&&f[f.length-1])&&(m[0]===6||m[0]===2)){n=0;continue}if(m[0]===3&&(!f||m[1]>f[0]&&m[1]<f[3])){n.label=m[1];break}if(m[0]===6&&n.label<f[1]){n.label=f[1],f=m;break}if(f&&n.label<f[2]){n.label=f[2],n.ops.push(m);break}f[2]&&n.ops.pop(),n.trys.pop();continue}m=t.call(e,n)}catch(b){m=[6,b],c=0}finally{o=f=0}if(m[0]&5)throw m[1];return{value:m[0]?m[1]:void 0,done:!0}}},Uv=function(){function e(t,n){this.name=t,this.track=n}return e.prototype.isSupported=function(){return this.track.getCapabilities?this.name in this.track.getCapabilities():!1},e.prototype.apply=function(t){var n={};n[this.name]=t;var o={advanced:[n]};return this.track.applyConstraints(o)},e.prototype.value=function(){var t=this.track.getSettings();if(this.name in t){var n=t[this.name];return n}return null},e}(),hR=function(e){F0(t,e);function t(n,o){return e.call(this,n,o)||this}return t.prototype.min=function(){return this.getCapabilities().min},t.prototype.max=function(){return this.getCapabilities().max},t.prototype.step=function(){return this.getCapabilities().step},t.prototype.apply=function(n){var o={};o[this.name]=n;var c={advanced:[o]};return this.track.applyConstraints(c)},t.prototype.getCapabilities=function(){this.failIfNotSupported();var n=this.track.getCapabilities(),o=n[this.name];return{min:o.min,max:o.max,step:o.step}},t.prototype.failIfNotSupported=function(){if(!this.isSupported())throw new Error("".concat(this.name," capability not supported"))},t}(Uv),gR=function(e){F0(t,e);function t(n){return e.call(this,"zoom",n)||this}return t}(hR),pR=function(e){F0(t,e);function t(n){return e.call(this,"torch",n)||this}return t}(Uv),mR=function(){function e(t){this.track=t}return e.prototype.zoomFeature=function(){return new gR(this.track)},e.prototype.torchFeature=function(){return new pR(this.track)},e}(),xR=function(){function e(t,n,o){this.isClosed=!1,this.parentElement=t,this.mediaStream=n,this.callbacks=o,this.surface=this.createVideoElement(this.parentElement.clientWidth),t.append(this.surface)}return e.prototype.createVideoElement=function(t){var n=document.createElement("video");return n.style.width="".concat(t,"px"),n.style.display="block",n.muted=!0,n.setAttribute("muted","true"),n.playsInline=!0,n},e.prototype.setupSurface=function(){var t=this;this.surface.onabort=function(){throw"RenderedCameraImpl video surface onabort() called"},this.surface.onerror=function(){throw"RenderedCameraImpl video surface onerror() called"};var n=function(){var o=t.surface.clientWidth,c=t.surface.clientHeight;t.callbacks.onRenderSurfaceReady(o,c),t.surface.removeEventListener("playing",n)};this.surface.addEventListener("playing",n),this.surface.srcObject=this.mediaStream,this.surface.play()},e.create=function(t,n,o,c){return uc(this,void 0,void 0,function(){var f,g;return fc(this,function(x){switch(x.label){case 0:return f=new e(t,n,c),o.aspectRatio?(g={aspectRatio:o.aspectRatio},[4,f.getFirstTrackOrFail().applyConstraints(g)]):[3,2];case 1:x.sent(),x.label=2;case 2:return f.setupSurface(),[2,f]}})})},e.prototype.failIfClosed=function(){if(this.isClosed)throw"The RenderedCamera has already been closed."},e.prototype.getFirstTrackOrFail=function(){if(this.failIfClosed(),this.mediaStream.getVideoTracks().length===0)throw"No video tracks found";return this.mediaStream.getVideoTracks()[0]},e.prototype.pause=function(){this.failIfClosed(),this.surface.pause()},e.prototype.resume=function(t){this.failIfClosed();var n=this,o=function(){setTimeout(t,200),n.surface.removeEventListener("playing",o)};this.surface.addEventListener("playing",o),this.surface.play()},e.prototype.isPaused=function(){return this.failIfClosed(),this.surface.paused},e.prototype.getSurface=function(){return this.failIfClosed(),this.surface},e.prototype.getRunningTrackCapabilities=function(){return this.getFirstTrackOrFail().getCapabilities()},e.prototype.getRunningTrackSettings=function(){return this.getFirstTrackOrFail().getSettings()},e.prototype.applyVideoConstraints=function(t){return uc(this,void 0,void 0,function(){return fc(this,function(n){if("aspectRatio"in t)throw"Changing 'aspectRatio' in run-time is not yet supported.";return[2,this.getFirstTrackOrFail().applyConstraints(t)]})})},e.prototype.close=function(){if(this.isClosed)return Promise.resolve();var t=this;return new Promise(function(n,o){var c=t.mediaStream.getVideoTracks(),f=c.length,g=0;t.mediaStream.getVideoTracks().forEach(function(x){t.mediaStream.removeTrack(x),x.stop(),++g,g>=f&&(t.isClosed=!0,t.parentElement.removeChild(t.surface),n())})})},e.prototype.getCapabilities=function(){return new mR(this.getFirstTrackOrFail())},e}(),wR=function(){function e(t){this.mediaStream=t}return e.prototype.render=function(t,n,o){return uc(this,void 0,void 0,function(){return fc(this,function(c){return[2,xR.create(t,this.mediaStream,n,o)]})})},e.create=function(t){return uc(this,void 0,void 0,function(){var n,o;return fc(this,function(c){switch(c.label){case 0:if(!navigator.mediaDevices)throw"navigator.mediaDevices not supported";return n={audio:!1,video:t},[4,navigator.mediaDevices.getUserMedia(n)];case 1:return o=c.sent(),[2,new e(o)]}})})},e}(),s2=function(e,t,n,o){function c(f){return f instanceof n?f:new n(function(g){g(f)})}return new(n||(n=Promise))(function(f,g){function x(b){try{m(o.next(b))}catch(E){g(E)}}function w(b){try{m(o.throw(b))}catch(E){g(E)}}function m(b){b.done?f(b.value):c(b.value).then(x,w)}m((o=o.apply(e,t||[])).next())})},o2=function(e,t){var n={label:0,sent:function(){if(f[0]&1)throw f[1];return f[1]},trys:[],ops:[]},o,c,f,g;return g={next:x(0),throw:x(1),return:x(2)},typeof Symbol=="function"&&(g[Symbol.iterator]=function(){return this}),g;function x(m){return function(b){return w([m,b])}}function w(m){if(o)throw new TypeError("Generator is already executing.");for(;g&&(g=0,m[0]&&(n=0)),n;)try{if(o=1,c&&(f=m[0]&2?c.return:m[0]?c.throw||((f=c.return)&&f.call(c),0):c.next)&&!(f=f.call(c,m[1])).done)return f;switch(c=0,f&&(m=[m[0]&2,f.value]),m[0]){case 0:case 1:f=m;break;case 4:return n.label++,{value:m[1],done:!1};case 5:n.label++,c=m[1],m=[0];continue;case 7:m=n.ops.pop(),n.trys.pop();continue;default:if(f=n.trys,!(f=f.length>0&&f[f.length-1])&&(m[0]===6||m[0]===2)){n=0;continue}if(m[0]===3&&(!f||m[1]>f[0]&&m[1]<f[3])){n.label=m[1];break}if(m[0]===6&&n.label<f[1]){n.label=f[1],f=m;break}if(f&&n.label<f[2]){n.label=f[2],n.ops.push(m);break}f[2]&&n.ops.pop(),n.trys.pop();continue}m=t.call(e,n)}catch(b){m=[6,b],c=0}finally{o=f=0}if(m[0]&5)throw m[1];return{value:m[0]?m[1]:void 0,done:!0}}},vR=function(){function e(){}return e.failIfNotSupported=function(){return s2(this,void 0,void 0,function(){return o2(this,function(t){if(!navigator.mediaDevices)throw"navigator.mediaDevices not supported";return[2,new e]})})},e.prototype.create=function(t){return s2(this,void 0,void 0,function(){return o2(this,function(n){return[2,wR.create(t)]})})},e}(),yR=function(e,t,n,o){function c(f){return f instanceof n?f:new n(function(g){g(f)})}return new(n||(n=Promise))(function(f,g){function x(b){try{m(o.next(b))}catch(E){g(E)}}function w(b){try{m(o.throw(b))}catch(E){g(E)}}function m(b){b.done?f(b.value):c(b.value).then(x,w)}m((o=o.apply(e,t||[])).next())})},ER=function(e,t){var n={label:0,sent:function(){if(f[0]&1)throw f[1];return f[1]},trys:[],ops:[]},o,c,f,g;return g={next:x(0),throw:x(1),return:x(2)},typeof Symbol=="function"&&(g[Symbol.iterator]=function(){return this}),g;function x(m){return function(b){return w([m,b])}}function w(m){if(o)throw new TypeError("Generator is already executing.");for(;g&&(g=0,m[0]&&(n=0)),n;)try{if(o=1,c&&(f=m[0]&2?c.return:m[0]?c.throw||((f=c.return)&&f.call(c),0):c.next)&&!(f=f.call(c,m[1])).done)return f;switch(c=0,f&&(m=[m[0]&2,f.value]),m[0]){case 0:case 1:f=m;break;case 4:return n.label++,{value:m[1],done:!1};case 5:n.label++,c=m[1],m=[0];continue;case 7:m=n.ops.pop(),n.trys.pop();continue;default:if(f=n.trys,!(f=f.length>0&&f[f.length-1])&&(m[0]===6||m[0]===2)){n=0;continue}if(m[0]===3&&(!f||m[1]>f[0]&&m[1]<f[3])){n.label=m[1];break}if(m[0]===6&&n.label<f[1]){n.label=f[1],f=m;break}if(f&&n.label<f[2]){n.label=f[2],n.ops.push(m);break}f[2]&&n.ops.pop(),n.trys.pop();continue}m=t.call(e,n)}catch(b){m=[6,b],c=0}finally{o=f=0}if(m[0]&5)throw m[1];return{value:m[0]?m[1]:void 0,done:!0}}},CR=function(){function e(){}return e.retrieve=function(){if(navigator.mediaDevices)return e.getCamerasFromMediaDevices();var t=MediaStreamTrack;return MediaStreamTrack&&t.getSources?e.getCamerasFromMediaStreamTrack():e.rejectWithError()},e.rejectWithError=function(){var t=cs.unableToQuerySupportedDevices();return e.isHttpsOrLocalhost()||(t=cs.insecureContextCameraQueryError()),Promise.reject(t)},e.isHttpsOrLocalhost=function(){if(location.protocol==="https:")return!0;var t=location.host.split(":")[0];return t==="127.0.0.1"||t==="localhost"},e.getCamerasFromMediaDevices=function(){return yR(this,void 0,void 0,function(){var t,n,o,c,f,g,x;return ER(this,function(w){switch(w.label){case 0:return t=function(m){for(var b=m.getVideoTracks(),E=0,S=b;E<S.length;E++){var R=S[E];R.enabled=!1,R.stop(),m.removeTrack(R)}},[4,navigator.mediaDevices.getUserMedia({audio:!1,video:!0})];case 1:return n=w.sent(),[4,navigator.mediaDevices.enumerateDevices()];case 2:for(o=w.sent(),c=[],f=0,g=o;f<g.length;f++)x=g[f],x.kind==="videoinput"&&c.push({id:x.deviceId,label:x.label});return t(n),[2,c]}})})},e.getCamerasFromMediaStreamTrack=function(){return new Promise(function(t,n){var o=function(f){for(var g=[],x=0,w=f;x<w.length;x++){var m=w[x];m.kind==="video"&&g.push({id:m.id,label:m.label})}t(g)},c=MediaStreamTrack;c.getSources(o)})},e}(),at;(function(e){e[e.UNKNOWN=0]="UNKNOWN",e[e.NOT_STARTED=1]="NOT_STARTED",e[e.SCANNING=2]="SCANNING",e[e.PAUSED=3]="PAUSED"})(at||(at={}));var bR=function(){function e(){this.state=at.NOT_STARTED,this.onGoingTransactionNewState=at.UNKNOWN}return e.prototype.directTransition=function(t){this.failIfTransitionOngoing(),this.validateTransition(t),this.state=t},e.prototype.startTransition=function(t){return this.failIfTransitionOngoing(),this.validateTransition(t),this.onGoingTransactionNewState=t,this},e.prototype.execute=function(){if(this.onGoingTransactionNewState===at.UNKNOWN)throw"Transaction is already cancelled, cannot execute().";var t=this.onGoingTransactionNewState;this.onGoingTransactionNewState=at.UNKNOWN,this.directTransition(t)},e.prototype.cancel=function(){if(this.onGoingTransactionNewState===at.UNKNOWN)throw"Transaction is already cancelled, cannot cancel().";this.onGoingTransactionNewState=at.UNKNOWN},e.prototype.getState=function(){return this.state},e.prototype.failIfTransitionOngoing=function(){if(this.onGoingTransactionNewState!==at.UNKNOWN)throw"Cannot transition to a new state, already under transition"},e.prototype.validateTransition=function(t){switch(this.state){case at.UNKNOWN:throw"Transition from unknown is not allowed";case at.NOT_STARTED:this.failIfNewStateIs(t,[at.PAUSED]);break;case at.SCANNING:break;case at.PAUSED:break}},e.prototype.failIfNewStateIs=function(t,n){for(var o=0,c=n;o<c.length;o++){var f=c[o];if(t===f)throw"Cannot transition from ".concat(this.state," to ").concat(t)}},e}(),AR=function(){function e(t){this.stateManager=t}return e.prototype.startTransition=function(t){return this.stateManager.startTransition(t)},e.prototype.directTransition=function(t){this.stateManager.directTransition(t)},e.prototype.getState=function(){return this.stateManager.getState()},e.prototype.canScanFile=function(){return this.stateManager.getState()===at.NOT_STARTED},e.prototype.isScanning=function(){return this.stateManager.getState()!==at.NOT_STARTED},e.prototype.isStrictlyScanning=function(){return this.stateManager.getState()===at.SCANNING},e.prototype.isPaused=function(){return this.stateManager.getState()===at.PAUSED},e}(),SR=function(){function e(){}return e.create=function(){return new AR(new bR)},e}(),IR=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,c){o.__proto__=c}||function(o,c){for(var f in c)Object.prototype.hasOwnProperty.call(c,f)&&(o[f]=c[f])},e(t,n)};return function(t,n){if(typeof n!="function"&&n!==null)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");e(t,n);function o(){this.constructor=t}t.prototype=n===null?Object.create(n):(o.prototype=n.prototype,new o)}}(),gr=function(e){IR(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.DEFAULT_WIDTH=300,t.DEFAULT_WIDTH_OFFSET=2,t.FILE_SCAN_MIN_HEIGHT=300,t.FILE_SCAN_HIDDEN_CANVAS_PADDING=100,t.MIN_QR_BOX_SIZE=50,t.SHADED_LEFT=1,t.SHADED_RIGHT=2,t.SHADED_TOP=3,t.SHADED_BOTTOM=4,t.SHADED_REGION_ELEMENT_ID="qr-shaded-region",t.VERBOSE=!1,t.BORDER_SHADER_DEFAULT_COLOR="#ffffff",t.BORDER_SHADER_MATCH_COLOR="rgb(90, 193, 56)",t}(oR),TR=function(){function e(t,n){this.logger=n,this.fps=gr.SCAN_DEFAULT_FPS,t?(t.fps&&(this.fps=t.fps),this.disableFlip=t.disableFlip===!0,this.qrbox=t.qrbox,this.aspectRatio=t.aspectRatio,this.videoConstraints=t.videoConstraints):this.disableFlip=gr.DEFAULT_DISABLE_FLIP}return e.prototype.isMediaStreamConstraintsValid=function(){return this.videoConstraints?Fv.isMediaStreamConstraintsValid(this.videoConstraints,this.logger):(this.logger.logError("Empty videoConstraints",!0),!1)},e.prototype.isShadedBoxEnabled=function(){return!dn(this.qrbox)},e.create=function(t,n){return new e(t,n)},e}(),u_=function(){function e(t,n){if(this.element=null,this.canvasElement=null,this.scannerPausedUiElement=null,this.hasBorderShaders=null,this.borderShaders=null,this.qrMatch=null,this.renderedCamera=null,this.qrRegion=null,this.context=null,this.lastScanImageFile=null,this.isScanning=!1,!document.getElementById(t))throw"HTML Element with id=".concat(t," not found");this.elementId=t,this.verbose=!1;var o;typeof n=="boolean"?this.verbose=n===!0:n&&(o=n,this.verbose=o.verbose===!0,o.experimentalFeatures),this.logger=new lR(this.verbose),this.qrcode=new dR(this.getSupportedFormats(n),this.getUseBarCodeDetectorIfSupported(o),this.verbose,this.logger),this.foreverScanTimeout,this.shouldScan=!0,this.stateManagerProxy=SR.create()}return e.prototype.start=function(t,n,o,c){var f=this;if(!t)throw"cameraIdOrConfig is required";if(!o||typeof o!="function")throw"qrCodeSuccessCallback is required and should be a function.";var g;c?g=c:g=this.verbose?this.logger.log:function(){};var x=TR.create(n,this.logger);this.clearElement();var w=!1;x.videoConstraints&&(x.isMediaStreamConstraintsValid()?w=!0:this.logger.logError("'videoConstraints' is not valid 'MediaStreamConstraints, it will be ignored.'",!0));var m=w,b=document.getElementById(this.elementId);b.clientWidth?b.clientWidth:gr.DEFAULT_WIDTH,b.style.position="relative",this.shouldScan=!0,this.element=b;var E=this,S=this.stateManagerProxy.startTransition(at.SCANNING);return new Promise(function(R,k){var D=m?x.videoConstraints:E.createVideoConstraints(t);if(!D){S.cancel(),k("videoConstraints should be defined");return}var Y={};(!m||x.aspectRatio)&&(Y.aspectRatio=x.aspectRatio);var N={onRenderSurfaceReady:function(I,O){E.setupUi(I,O,x),E.isScanning=!0,E.foreverScan(x,o,g)}};vR.failIfNotSupported().then(function(I){I.create(D).then(function(O){return O.render(f.element,Y,N).then(function(W){E.renderedCamera=W,S.execute(),R(null)}).catch(function(W){S.cancel(),k(W)})}).catch(function(O){S.cancel(),k(cs.errorGettingUserMedia(O))})}).catch(function(I){S.cancel(),k(cs.cameraStreamingNotSupported())})})},e.prototype.pause=function(t){if(!this.stateManagerProxy.isStrictlyScanning())throw"Cannot pause, scanner is not scanning.";this.stateManagerProxy.directTransition(at.PAUSED),this.showPausedState(),(dn(t)||t!==!0)&&(t=!1),t&&this.renderedCamera&&this.renderedCamera.pause()},e.prototype.resume=function(){if(!this.stateManagerProxy.isPaused())throw"Cannot result, scanner is not paused.";if(!this.renderedCamera)throw"renderedCamera doesn't exist while trying resume()";var t=this,n=function(){t.stateManagerProxy.directTransition(at.SCANNING),t.hidePausedState()};if(!this.renderedCamera.isPaused()){n();return}this.renderedCamera.resume(function(){n()})},e.prototype.getState=function(){return this.stateManagerProxy.getState()},e.prototype.stop=function(){var t=this;if(!this.stateManagerProxy.isScanning())throw"Cannot stop, scanner is not running or paused.";var n=this.stateManagerProxy.startTransition(at.NOT_STARTED);this.shouldScan=!1,this.foreverScanTimeout&&clearTimeout(this.foreverScanTimeout);var o=function(){if(t.element){var f=document.getElementById(gr.SHADED_REGION_ELEMENT_ID);f&&t.element.removeChild(f)}},c=this;return this.renderedCamera.close().then(function(){return c.renderedCamera=null,c.element&&(c.element.removeChild(c.canvasElement),c.canvasElement=null),o(),c.qrRegion&&(c.qrRegion=null),c.context&&(c.context=null),n.execute(),c.hidePausedState(),c.isScanning=!1,Promise.resolve()})},e.prototype.scanFile=function(t,n){return this.scanFileV2(t,n).then(function(o){return o.decodedText})},e.prototype.scanFileV2=function(t,n){var o=this;if(!t||!(t instanceof File))throw"imageFile argument is mandatory and should be instance of File. Use 'event.target.files[0]'.";if(dn(n)&&(n=!0),!this.stateManagerProxy.canScanFile())throw"Cannot start file scan - ongoing camera scan";return new Promise(function(c,f){o.possiblyCloseLastScanImageFile(),o.clearElement(),o.lastScanImageFile=URL.createObjectURL(t);var g=new Image;g.onload=function(){var x=g.width,w=g.height,m=document.getElementById(o.elementId),b=m.clientWidth?m.clientWidth:gr.DEFAULT_WIDTH,E=Math.max(m.clientHeight?m.clientHeight:w,gr.FILE_SCAN_MIN_HEIGHT),S=o.computeCanvasDrawConfig(x,w,b,E);if(n){var R=o.createCanvasElement(b,E,"qr-canvas-visible");R.style.display="inline-block",m.appendChild(R);var k=R.getContext("2d");if(!k)throw"Unable to get 2d context from canvas";k.canvas.width=b,k.canvas.height=E,k.drawImage(g,0,0,x,w,S.x,S.y,S.width,S.height)}var D=gr.FILE_SCAN_HIDDEN_CANVAS_PADDING,Y=Math.max(g.width,S.width),N=Math.max(g.height,S.height),I=Y+2*D,O=N+2*D,W=o.createCanvasElement(I,O);m.appendChild(W);var V=W.getContext("2d");if(!V)throw"Unable to get 2d context from canvas";V.canvas.width=I,V.canvas.height=O,V.drawImage(g,0,0,x,w,D,D,Y,N);try{o.qrcode.decodeRobustlyAsync(W).then(function(L){c(e2.createFromQrcodeResult(L))}).catch(f)}catch(L){f("QR code parse error, error = ".concat(L))}},g.onerror=f,g.onabort=f,g.onstalled=f,g.onsuspend=f,g.src=URL.createObjectURL(t)})},e.prototype.clear=function(){this.clearElement()},e.getCameras=function(){return CR.retrieve()},e.prototype.getRunningTrackCapabilities=function(){return this.getRenderedCameraOrFail().getRunningTrackCapabilities()},e.prototype.getRunningTrackSettings=function(){return this.getRenderedCameraOrFail().getRunningTrackSettings()},e.prototype.getRunningTrackCameraCapabilities=function(){return this.getRenderedCameraOrFail().getCapabilities()},e.prototype.applyVideoConstraints=function(t){if(t){if(!Fv.isMediaStreamConstraintsValid(t,this.logger))throw"invalid videoConstaints passed, check logs for more details"}else throw"videoConstaints is required argument.";return this.getRenderedCameraOrFail().applyVideoConstraints(t)},e.prototype.getRenderedCameraOrFail=function(){if(this.renderedCamera==null)throw"Scanning is not in running state, call this API only when QR code scanning using camera is in running state.";return this.renderedCamera},e.prototype.getSupportedFormats=function(t){var n=[ie.QR_CODE,ie.AZTEC,ie.CODABAR,ie.CODE_39,ie.CODE_93,ie.CODE_128,ie.DATA_MATRIX,ie.MAXICODE,ie.ITF,ie.EAN_13,ie.EAN_8,ie.PDF_417,ie.RSS_14,ie.RSS_EXPANDED,ie.UPC_A,ie.UPC_E,ie.UPC_EAN_EXTENSION];if(!t||typeof t=="boolean"||!t.formatsToSupport)return n;if(!Array.isArray(t.formatsToSupport))throw"configOrVerbosityFlag.formatsToSupport should be undefined or an array.";if(t.formatsToSupport.length===0)throw"Atleast 1 formatsToSupport is needed.";for(var o=[],c=0,f=t.formatsToSupport;c<f.length;c++){var g=f[c];sR(g)?o.push(g):this.logger.warn("Invalid format: ".concat(g," passed in config, ignoring."))}if(o.length===0)throw"None of formatsToSupport match supported values.";return o},e.prototype.getUseBarCodeDetectorIfSupported=function(t){if(dn(t))return!0;if(!dn(t.useBarCodeDetectorIfSupported))return t.useBarCodeDetectorIfSupported!==!1;if(dn(t.experimentalFeatures))return!0;var n=t.experimentalFeatures;return dn(n.useBarCodeDetectorIfSupported)?!0:n.useBarCodeDetectorIfSupported!==!1},e.prototype.validateQrboxSize=function(t,n,o){var c=this,f=o.qrbox;this.validateQrboxConfig(f);var g=this.toQrdimensions(t,n,f),x=function(m){if(m<gr.MIN_QR_BOX_SIZE)throw"minimum size of 'config.qrbox' dimension value is"+" ".concat(gr.MIN_QR_BOX_SIZE,"px.")},w=function(m){return m>t&&(c.logger.warn("`qrbox.width` or `qrbox` is larger than the width of the root element. The width will be truncated to the width of root element."),m=t),m};x(g.width),x(g.height),g.width=w(g.width)},e.prototype.validateQrboxConfig=function(t){if(typeof t!="number"&&typeof t!="function"&&(t.width===void 0||t.height===void 0))throw"Invalid instance of QrDimensions passed for 'config.qrbox'. Both 'width' and 'height' should be set."},e.prototype.toQrdimensions=function(t,n,o){if(typeof o=="number")return{width:o,height:o};if(typeof o=="function")try{return o(t,n)}catch(c){throw new Error("qrbox config was passed as a function but it failed with unknown error"+c)}return o},e.prototype.setupUi=function(t,n,o){o.isShadedBoxEnabled()&&this.validateQrboxSize(t,n,o);var c=dn(o.qrbox)?{width:t,height:n}:o.qrbox;this.validateQrboxConfig(c);var f=this.toQrdimensions(t,n,c);f.height>n&&this.logger.warn("[Html5Qrcode] config.qrbox has height that isgreater than the height of the video stream. Shading will be ignored");var g=o.isShadedBoxEnabled()&&f.height<=n,x={x:0,y:0,width:t,height:n},w=g?this.getShadedRegionBounds(t,n,f):x,m=this.createCanvasElement(w.width,w.height),b={willReadFrequently:!0},E=m.getContext("2d",b);E.canvas.width=w.width,E.canvas.height=w.height,this.element.append(m),g&&this.possiblyInsertShadingElement(this.element,t,n,f),this.createScannerPausedUiElement(this.element),this.qrRegion=w,this.context=E,this.canvasElement=m},e.prototype.createScannerPausedUiElement=function(t){var n=document.createElement("div");n.innerText=cs.scannerPaused(),n.style.display="none",n.style.position="absolute",n.style.top="0px",n.style.zIndex="1",n.style.background="rgba(9, 9, 9, 0.46)",n.style.color="#FFECEC",n.style.textAlign="center",n.style.width="100%",t.appendChild(n),this.scannerPausedUiElement=n},e.prototype.scanContext=function(t,n){var o=this;return this.stateManagerProxy.isPaused()?Promise.resolve(!1):this.qrcode.decodeAsync(this.canvasElement).then(function(c){return t(c.text,e2.createFromQrcodeResult(c)),o.possiblyUpdateShaders(!0),!0}).catch(function(c){o.possiblyUpdateShaders(!1);var f=cs.codeParseError(c);return n(f,aR.createFrom(f)),!1})},e.prototype.foreverScan=function(t,n,o){var c=this;if(this.shouldScan&&this.renderedCamera){var f=this.renderedCamera.getSurface(),g=f.videoWidth/f.clientWidth,x=f.videoHeight/f.clientHeight;if(!this.qrRegion)throw"qrRegion undefined when localMediaStream is ready.";var w=this.qrRegion.width*g,m=this.qrRegion.height*x,b=this.qrRegion.x*g,E=this.qrRegion.y*x;this.context.drawImage(f,b,E,w,m,0,0,this.qrRegion.width,this.qrRegion.height);var S=function(){c.foreverScanTimeout=setTimeout(function(){c.foreverScan(t,n,o)},c.getTimeoutFps(t.fps))};this.scanContext(n,o).then(function(R){!R&&t.disableFlip!==!0?(c.context.translate(c.context.canvas.width,0),c.context.scale(-1,1),c.scanContext(n,o).finally(function(){S()})):S()}).catch(function(R){c.logger.logError("Error happend while scanning context",R),S()})}},e.prototype.createVideoConstraints=function(t){if(typeof t=="string")return{deviceId:{exact:t}};if(typeof t=="object"){var n="facingMode",o="deviceId",c={user:!0,environment:!0},f="exact",g=function(k){if(k in c)return!0;throw"config has invalid 'facingMode' value = "+"'".concat(k,"'")},x=Object.keys(t);if(x.length!==1)throw"'cameraIdOrConfig' object should have exactly 1 key,"+" if passed as an object, found ".concat(x.length," keys");var w=Object.keys(t)[0];if(w!==n&&w!==o)throw"Only '".concat(n,"' and '").concat(o,"' ")+" are supported for 'cameraIdOrConfig'";if(w===n){var m=t.facingMode;if(typeof m=="string"){if(g(m))return{facingMode:m}}else if(typeof m=="object")if(f in m){if(g(m["".concat(f)]))return{facingMode:{exact:m["".concat(f)]}}}else throw"'facingMode' should be string or object with"+" ".concat(f," as key.");else{var b=typeof m;throw"Invalid type of 'facingMode' = ".concat(b)}}else{var E=t.deviceId;if(typeof E=="string")return{deviceId:E};if(typeof E=="object"){if(f in E)return{deviceId:{exact:E["".concat(f)]}};throw"'deviceId' should be string or object with"+" ".concat(f," as key.")}else{var S=typeof E;throw"Invalid type of 'deviceId' = ".concat(S)}}}var R=typeof t;throw"Invalid type of 'cameraIdOrConfig' = ".concat(R)},e.prototype.computeCanvasDrawConfig=function(t,n,o,c){if(t<=o&&n<=c){var f=(o-t)/2,g=(c-n)/2;return{x:f,y:g,width:t,height:n}}else{var x=t,w=n;return t>o&&(n=o/t*n,t=o),n>c&&(t=c/n*t,n=c),this.logger.log("Image downsampled from "+"".concat(x,"X").concat(w)+" to ".concat(t,"X").concat(n,".")),this.computeCanvasDrawConfig(t,n,o,c)}},e.prototype.clearElement=function(){if(this.stateManagerProxy.isScanning())throw"Cannot clear while scan is ongoing, close it first.";var t=document.getElementById(this.elementId);t&&(t.innerHTML="")},e.prototype.possiblyUpdateShaders=function(t){this.qrMatch!==t&&(this.hasBorderShaders&&this.borderShaders&&this.borderShaders.length&&this.borderShaders.forEach(function(n){n.style.backgroundColor=t?gr.BORDER_SHADER_MATCH_COLOR:gr.BORDER_SHADER_DEFAULT_COLOR}),this.qrMatch=t)},e.prototype.possiblyCloseLastScanImageFile=function(){this.lastScanImageFile&&(URL.revokeObjectURL(this.lastScanImageFile),this.lastScanImageFile=null)},e.prototype.createCanvasElement=function(t,n,o){var c=t,f=n,g=document.createElement("canvas");return g.style.width="".concat(c,"px"),g.style.height="".concat(f,"px"),g.style.display="none",g.id=dn(o)?"qr-canvas":o,g},e.prototype.getShadedRegionBounds=function(t,n,o){if(o.width>t||o.height>n)throw"'config.qrbox' dimensions should not be greater than the dimensions of the root HTML element.";return{x:(t-o.width)/2,y:(n-o.height)/2,width:o.width,height:o.height}},e.prototype.possiblyInsertShadingElement=function(t,n,o,c){if(!(n-c.width<1||o-c.height<1)){var f=document.createElement("div");f.style.position="absolute";var g=(n-c.width)/2,x=(o-c.height)/2;if(f.style.borderLeft="".concat(g,"px solid rgba(0, 0, 0, 0.48)"),f.style.borderRight="".concat(g,"px solid rgba(0, 0, 0, 0.48)"),f.style.borderTop="".concat(x,"px solid rgba(0, 0, 0, 0.48)"),f.style.borderBottom="".concat(x,"px solid rgba(0, 0, 0, 0.48)"),f.style.boxSizing="border-box",f.style.top="0px",f.style.bottom="0px",f.style.left="0px",f.style.right="0px",f.id="".concat(gr.SHADED_REGION_ELEMENT_ID),n-c.width<11||o-c.height<11)this.hasBorderShaders=!1;else{var w=5,m=40;this.insertShaderBorders(f,m,w,-w,null,0,!0),this.insertShaderBorders(f,m,w,-w,null,0,!1),this.insertShaderBorders(f,m,w,null,-w,0,!0),this.insertShaderBorders(f,m,w,null,-w,0,!1),this.insertShaderBorders(f,w,m+w,-w,null,-w,!0),this.insertShaderBorders(f,w,m+w,null,-w,-w,!0),this.insertShaderBorders(f,w,m+w,-w,null,-w,!1),this.insertShaderBorders(f,w,m+w,null,-w,-w,!1),this.hasBorderShaders=!0}t.append(f)}},e.prototype.insertShaderBorders=function(t,n,o,c,f,g,x){var w=document.createElement("div");w.style.position="absolute",w.style.backgroundColor=gr.BORDER_SHADER_DEFAULT_COLOR,w.style.width="".concat(n,"px"),w.style.height="".concat(o,"px"),c!==null&&(w.style.top="".concat(c,"px")),f!==null&&(w.style.bottom="".concat(f,"px")),x?w.style.left="".concat(g,"px"):w.style.right="".concat(g,"px"),this.borderShaders||(this.borderShaders=[]),this.borderShaders.push(w),t.appendChild(w)},e.prototype.showPausedState=function(){if(!this.scannerPausedUiElement)throw"[internal error] scanner paused UI element not found";this.scannerPausedUiElement.style.display="block"},e.prototype.hidePausedState=function(){if(!this.scannerPausedUiElement)throw"[internal error] scanner paused UI element not found";this.scannerPausedUiElement.style.display="none"},e.prototype.getTimeoutFps=function(t){return 1e3/t},e}(),a2;(function(e){e[e.STATUS_DEFAULT=0]="STATUS_DEFAULT",e[e.STATUS_SUCCESS=1]="STATUS_SUCCESS",e[e.STATUS_WARNING=2]="STATUS_WARNING",e[e.STATUS_REQUESTING_PERMISSION=3]="STATUS_REQUESTING_PERMISSION"})(a2||(a2={}));var X1;(function(e){e[e.BACK=1]="BACK",e[e.FRONT=2]="FRONT"})(X1||(X1={}));var Y1;(function(e){e[e.PORTRAIT=1]="PORTRAIT",e[e.LANDSCAPE=2]="LANDSCAPE",e[e.ADAPTIVE=3]="ADAPTIVE"})(Y1||(Y1={}));var K1;(function(e){e[e.ALL=17]="ALL"})(K1||(K1={}));const RR=Object.assign(Object.assign({},ie),K1);var l2;(function(e){e.ZXING="zxing",e.MLKIT="mlkit"})(l2||(l2={}));const _R=[{selector:".scanner-container-display",css:"display: block;"},{selector:".scanner-dialog",css:"display: none; position: fixed; z-index: 999; left: 0; top: 0; width: 100%; height: 100%; overflow: auto; background-color: rgba(0,0,0,0.4);"},{selector:".scanner-dialog-inner",css:"background-color: #fefefe; margin: 2% auto; padding: 20px; border: 1px solid #888; width: 96%;"},{selector:".close-button",css:"color: #aaa; float: right; font-size: 28px; font-weight: bold; cursor: pointer;"},{selector:".close-button:hover",css:"color: #222;"},{selector:".scanner-container-full-width",css:"width: 100%;"}];function OR(e){const t="custom-style-os-cap-barcode";let n=document.getElementById(t);if(n||(n=document.createElement("style"),n.type="text/css",n.id=t,document.head.appendChild(n)),n.sheet){for(;n.sheet.cssRules.length;)n.sheet.deleteRule(0);for(const{selector:o,css:c}of e)n.sheet.insertRule(`${o} { ${c} }`)}else{n.textContent="";for(const{selector:o,css:c}of e)n.textContent+=`${o} { ${c} }`}}const NR=da("CapacitorBarcodeScanner",{web:()=>(OR(_R),mi(()=>import("./web-W_qr76-r.js"),[],import.meta.url).then(e=>new e.CapacitorBarcodeScannerWeb))});class kR{static async scanBarcode(t){return t.scanInstructions=t.scanInstructions||" ",t.scanButton=t.scanButton||!1,t.scanText=t.scanText||" ",t.cameraDirection=t.cameraDirection||X1.BACK,t.scanOrientation=t.scanOrientation||Y1.ADAPTIVE,NR.scanBarcode(t)}}const Of=da("SecureStoragePlugin",{web:()=>mi(()=>import("./web-BeDKAt7R.js"),[],import.meta.url).then(e=>new e.SecureStoragePluginWeb)});function DR(e){try{if(e.length>2048)throw new Error;if(!e.startsWith("{")){const c=new URL(e);if(!["http:","https:"].includes(c.protocol)||c.username||c.password||c.pathname!=="/pair"||c.search||!/^#pair=[A-Za-z0-9_-]{43}$/.test(c.hash))throw new Error;const f=cn.parse(c.origin);if(!f)throw new Error;return{endpoint:f,grant:c.hash.slice(6)}}const t=JSON.parse(e);if(t.type!=="agentroam-pair"||t.version!==1||typeof t.server!="string"||typeof t.grant!="string"||!/^[A-Za-z0-9_-]{43}$/.test(t.grant))throw new Error;const n=new URL(t.server);if(n.username||n.password||n.search||n.hash||n.pathname!=="/")throw new Error;const o=cn.parse(t.server);if(!o)throw new Error;return{endpoint:o,grant:t.grant}}catch{throw new Error("这不是 AgentRoam 授权二维码,请扫描电脑终端上新生成的二维码。")}}class jv{ready(){if(!Os.isNativePlatform())throw new Error("请在 AgentRoam App 中扫码连接。")}async get(t){this.ready();try{return(await Of.get({key:`agentroam-device:${t}`})).value}catch(n){if(String(n).includes("does not exist"))return null;throw new Error("无法读取设备凭证,请重试。")}}async set(t,n){this.ready(),await Of.set({key:`agentroam-device:${t}`,value:n})}async remove(t){this.ready();try{await Of.remove({key:`agentroam-device:${t}`})}catch(n){if(!String(n).includes("does not exist"))throw n}}}async function Wv(){if(!Os.isNativePlatform())throw new Error("请在 AgentRoam App 中使用相机扫码。");try{return(await kR.scanBarcode({hint:RR.QR_CODE,scanInstructions:"扫描电脑上的 AgentRoam 授权二维码",cameraDirection:1})).ScanResult||null}catch(e){if(/cancel/i.test(String(e)))return null;throw new Error("无法打开相机,请在系统设置中允许 AgentRoam 使用相机后重试。")}}class zv{constructor(t,n=(...c)=>fetch(...c),o=()=>window.dispatchEvent(new CustomEvent("webapp:unauthorized"))){this.storage=t,this.transport=n,this.onRevoked=o,this.session=null,this.fetch=async(c,f={})=>{const g=this.session,x=new URL(typeof c=="string"?c:c instanceof URL?c.href:c.url),w=new Headers(f.headers??(c instanceof Request?c.headers:void 0));g&&x.origin===g.origin&&w.set("authorization",`Bearer ${g.token}`);const m=await this.transport(c,{...f,headers:w,credentials:"omit",redirect:"error"});if(g&&this.session===g&&x.origin===g.origin&&(m.status===401||m.status===423)){this.session=null;try{await this.storage.remove(g.origin)}finally{this.onRevoked()}}return m}}async resume(t){const n=await this.storage.get(t.url);this.session=n?{origin:t.url,token:n}:null}async pair(t){const{endpoint:n,grant:o}=DR(t),c=await this.transport(n.api("/api/pairing/qr-exchange"),{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify({grant:o,name:"我的 App"}),credentials:"omit",redirect:"error",signal:AbortSignal.timeout(1e4)});if(!c.ok)throw new Error(c.status===423?"电脑已锁定远程访问,请先在电脑上解锁。":c.status===410?"二维码已使用或已过期,请在电脑上重新生成。":"扫码连接失败,请检查服务器地址和网络后重试。");const f=await c.json();if(typeof f.token!="string"||!/^[A-Za-z0-9_-]{43}$/.test(f.token))throw new Error("服务器返回了无效的设备凭证。");try{await this.storage.set(n.url,f.token)}catch{throw await this.transport(n.api("/api/pairing/logout"),{method:"POST",headers:{authorization:`Bearer ${f.token}`},credentials:"omit",redirect:"error",signal:AbortSignal.timeout(5e3)}).catch(()=>{}),new Error("无法安全保存设备凭证,请在电脑上重新生成二维码后重试。")}return this.session={origin:n.url,token:f.token},n}async checkAuthorization(){const t=this.session;if(!t)return;const n=await this.fetch(`${t.origin}/api/web-auth/status`,{signal:AbortSignal.timeout(5e3)});if(!n.ok)return;const o=await n.json();if(this.session===t&&(o.locked||o.authenticated===!1)){this.session=null;try{await this.storage.remove(t.origin)}finally{this.onRevoked()}}}}function $v(e,t,n,o){const c=new URL(t);return(f,g)=>{const x=typeof f=="string"?f:f instanceof URL?f.href:f.url,w=new URL(x,c),m=w.protocol===c.protocol&&w.host===c.host;if(w.pathname.startsWith("/api/")&&(m||w.origin===e)){const b=new URL(w.pathname+w.search,e);return n.fetch(f instanceof Request?new Request(b,f):b,g)}return o(f,g)}}function MR(e,t){const n=new URL(e,"https://agentroam.local");if(n.pathname!=="/app/")throw new Error("Invalid workspace frame path");const o=new URL(t);return o.search=n.search,o.searchParams.set("workspace","1"),o.hash="",o.href}function Z1(e){XT(YT(e.url,void 0,Mv())),new Sv().save(e)}async function PR(e,t,n,o){e.render(F.jsx(L0,{})),window.__agentroamNativeFrame={origin:t.url,fetch:n.fetch},globalThis.fetch=$v(t.url,location.href,n,o);const c=async g=>{const x=await n.pair(g);Z1(x),location.reload()};zT({origin:t.url,frameUrl:g=>MR(g,location.href),pair:c,scan:async()=>{const g=await Wv();g&&await c(g)},switchComputer:async g=>{const x=cn.parse(g);if(!x)throw new Error("电脑地址无效,请重新扫码。");const w=new zv(new jv,o,()=>{});await w.resume(x);const m=await w.fetch(x.api("/api/web-auth/status"),{signal:AbortSignal.timeout(5e3)}),b=m.ok?await m.json():null;if(!(b!=null&&b.authenticated)||b.locked)throw new Error("这台电脑需要重新授权,请点击扫码添加电脑。");Z1(x),location.reload()}});const{default:f}=await mi(async()=>{const{default:g}=await import("./page-DVdz2jp6.js").then(x=>x.p);return{default:g}},__vite__mapDeps([0,1,2,3,4,5,6,7]),import.meta.url);e.render(F.jsx(me.StrictMode,{children:F.jsx(f,{})}))}function BR(){if(window.parent===window||new URLSearchParams(location.search).get("workspace")!=="1")return null;try{const e=new URL(window.parent.location.href);return e.protocol!==location.protocol||e.host!==location.host?null:window.parent.__agentroamNativeFrame??null}catch{return null}}function LR(e){return async(t,n)=>{const o=new Request(t,n);return e.fetch(o.url,{method:o.method,headers:Object.fromEntries(o.headers),body:o.method==="GET"||o.method==="HEAD"?void 0:await o.arrayBuffer(),signal:o.signal,cache:o.cache})}}var dc;(function(e){e.Dark="DARK",e.Light="LIGHT",e.Default="DEFAULT"})(dc||(dc={}));var c2;(function(e){e.None="NONE",e.Slide="SLIDE",e.Fade="FADE"})(c2||(c2={}));const Nf=da("StatusBar");function FR(e){const t=/^#([a-f\d]{6})$/i.exec(e.trim());if(!t)return null;const n=[0,2,4].map(c=>{const f=parseInt(t[1].slice(c,c+2),16)/255;return f<=.04045?f/12.92:((f+.055)/1.055)**2.4}),o=.2126*n[0]+.7152*n[1]+.0722*n[2];return{color:`#${t[1]}`,style:o>.179?dc.Light:dc.Dark}}function UR(){if(Os.getPlatform()!=="android")return()=>{};const e=document.documentElement;e.dataset.skin=Fl.getState().skin;let t=!1,n=Nf.setOverlaysWebView({overlay:!1}).catch(()=>{});const o=()=>{const g=FR(getComputedStyle(e).getPropertyValue("--bg-deepest"));g&&(n=n.then(async()=>{t||(await Nf.setBackgroundColor({color:g.color}),await Nf.setStyle({style:g.style}))}).catch(()=>{console.warn("Unable to update the Android status bar.")}))},c=new MutationObserver(o);c.observe(e,{attributes:!0,attributeFilter:["data-skin"]});const f=()=>{document.hidden||o()};return document.addEventListener("visibilitychange",f),window.addEventListener("focus",o),o(),()=>{t=!0,c.disconnect(),document.removeEventListener("visibilitychange",f),window.removeEventListener("focus",o)}}const jR="/service-worker.js";function WR(){return typeof window<"u"&&window.isSecureContext===!0&&"serviceWorker"in navigator&&"PushManager"in window&&"Notification"in window}function zR(e){const t="=".repeat((4-e.length%4)%4),n=`${e}${t}`.replace(/-/g,"+").replace(/_/g,"/"),o=atob(n),c=new Uint8Array(new ArrayBuffer(o.length));for(let f=0;f<o.length;f+=1)c[f]=o.charCodeAt(f);return c}async function u2(e){const{publicKey:t}=await e.get("/api/push/vapid");if(!t)return;const n=await navigator.serviceWorker.register(jR),c=await n.pushManager.getSubscription()??await n.pushManager.subscribe({userVisibleOnly:!0,applicationServerKey:zR(t)});await e.post("/api/push/subscribe",c.toJSON())}function $R(e){WR()&&(async()=>{try{if(Notification.permission==="granted"){await u2(e);return}if(Notification.permission!=="default")return;const t=()=>{(async()=>{try{await Notification.requestPermission()==="granted"&&await u2(e)}catch{}})()};document.addEventListener("pointerdown",t,{once:!0})}catch{}})()}class kf extends Error{constructor(t,n){super(t),this.name="ParseError",this.type=n.type,this.field=n.field,this.value=n.value,this.line=n.line}}const f2=10,VR=13,di=32;function Df(e){}function HR(e){if(typeof e=="function")throw new TypeError("`config` must be an object, got a function instead. Did you mean `createParser({onEvent: fn})`?");const{onEvent:t=Df,onError:n=Df,onRetry:o=Df,onComment:c,maxBufferSize:f}=e,g=[];let x=0,w=!0,m,b="",E=0,S,R=!1;function k(V){if(R)throw new Error("Cannot feed parser: it was terminated after exceeding the configured max buffer size. Call `reset()` to resume parsing.");if(w&&(w=!1,V.charCodeAt(0)===239&&V.charCodeAt(1)===187&&V.charCodeAt(2)===191&&(V=V.slice(3))),g.length===0){const X=Y(V);X!==""&&(g.push(X),x=X.length),D();return}if(V.indexOf(`
|
|
471
|
+
`);let s=nh.singletonList(en.INITIAL_STATE);for(let l=0;l<this.text.length;l++){let u,d=l+1<this.text.length?this.text[l+1]:0;switch(this.text[l]){case ne.getCharCode("\r"):u=d===i?2:0;break;case ne.getCharCode("."):u=d===r?3:0;break;case ne.getCharCode(","):u=d===r?4:0;break;case ne.getCharCode(":"):u=d===r?5:0;break;default:u=0}u>0?(s=Xs.updateStateListForPair(s,l,u),l++):s=this.updateStateListForChar(s,l)}return nh.min(s,(l,u)=>l.getBitCount()-u.getBitCount()).toBitArray(this.text)}updateStateListForChar(r,i){const s=[];for(let a of r)this.updateStateForChar(a,i,s);return Xs.simplifyStates(s)}updateStateForChar(r,i,s){let a=this.text[i]&255,l=xu[r.getMode()][a]>0,u=null;for(let d=0;d<=Jr;d++){let h=xu[d][a];if(h>0){if(u==null&&(u=r.endBinaryShift(i)),!l||d===r.getMode()||d===Ir){const p=u.latchAndAppend(d,h);s.push(p)}if(!l&&sh[r.getMode()][d]>=0){const p=u.shiftAndAppend(d,h);s.push(p)}}}if(r.getBinaryShiftByteCount()>0||xu[r.getMode()][a]===0){let d=r.addBinaryShiftChar(i);s.push(d)}}static updateStateListForPair(r,i,s){const a=[];for(let l of r)this.updateStateForPair(l,i,s,a);return this.simplifyStates(a)}static updateStateForPair(r,i,s,a){let l=r.endBinaryShift(i);if(a.push(l.latchAndAppend(Jr,s)),r.getMode()!==Jr&&a.push(l.shiftAndAppend(Jr,s)),s===3||s===4){let u=l.latchAndAppend(Ir,16-s).latchAndAppend(Ir,1);a.push(u)}if(r.getBinaryShiftByteCount()>0){let u=r.addBinaryShiftChar(i).addBinaryShiftChar(i+1);a.push(u)}}static simplifyStates(r){let i=[];for(const s of r){let a=!0;for(const l of i){if(l.isBetterThanOrEqualTo(s)){a=!1;break}s.isBetterThanOrEqualTo(l)&&(i=i.filter(u=>u!==l))}a&&i.push(s)}return i}}class _e{constructor(){}static encodeBytes(r){return _e.encode(r,_e.DEFAULT_EC_PERCENT,_e.DEFAULT_AZTEC_LAYERS)}static encode(r,i,s){let a=new Xs(r).encode(),l=O.truncDivision(a.getSize()*i,100)+11,u=a.getSize()+l,d,h,p,v,C;if(s!==_e.DEFAULT_AZTEC_LAYERS){if(d=s<0,h=Math.abs(s),h>(d?_e.MAX_NB_BITS_COMPACT:_e.MAX_NB_BITS))throw new E(ne.format("Illegal value %s for layers",s));p=_e.totalBitsInLayer(h,d),v=_e.WORD_SIZE[h];let Z=p-p%v;if(C=_e.stuffBits(a,v),C.getSize()+l>Z)throw new E("Data to large for user specified layer");if(d&&C.getSize()>v*64)throw new E("Data to large for user specified layer")}else{v=0,C=null;for(let Z=0;;Z++){if(Z>_e.MAX_NB_BITS)throw new E("Data too large for an Aztec code");if(d=Z<=3,h=d?Z+1:Z,p=_e.totalBitsInLayer(h,d),u>p)continue;(C==null||v!==_e.WORD_SIZE[h])&&(v=_e.WORD_SIZE[h],C=_e.stuffBits(a,v));let Ie=p-p%v;if(!(d&&C.getSize()>v*64)&&C.getSize()+l<=Ie)break}}let A=_e.generateCheckWords(C,p,v),_=C.getSize()/v,M=_e.generateModeMessage(d,h,_),P=(d?11:14)+h*4,U=new Int32Array(P),H;if(d){H=P;for(let Z=0;Z<U.length;Z++)U[Z]=Z}else{H=P+1+2*O.truncDivision(O.truncDivision(P,2)-1,15);let Z=O.truncDivision(P,2),Ie=O.truncDivision(H,2);for(let ve=0;ve<Z;ve++){let nr=ve+O.truncDivision(ve,15);U[Z-ve-1]=Ie-nr-1,U[Z+ve]=Ie+nr+1}}let q=new Se(H);for(let Z=0,Ie=0;Z<h;Z++){let ve=(h-Z)*4+(d?9:12);for(let nr=0;nr<ve;nr++){let Pr=nr*2;for(let ir=0;ir<2;ir++)A.get(Ie+Pr+ir)&&q.set(U[Z*2+ir],U[Z*2+nr]),A.get(Ie+ve*2+Pr+ir)&&q.set(U[Z*2+nr],U[P-1-Z*2-ir]),A.get(Ie+ve*4+Pr+ir)&&q.set(U[P-1-Z*2-ir],U[P-1-Z*2-nr]),A.get(Ie+ve*6+Pr+ir)&&q.set(U[P-1-Z*2-nr],U[Z*2+ir])}Ie+=ve*8}if(_e.drawModeMessage(q,d,H,M),d)_e.drawBullsEye(q,O.truncDivision(H,2),5);else{_e.drawBullsEye(q,O.truncDivision(H,2),7);for(let Z=0,Ie=0;Z<O.truncDivision(P,2)-1;Z+=15,Ie+=16)for(let ve=O.truncDivision(H,2)&1;ve<H;ve+=2)q.set(O.truncDivision(H,2)-Ie,ve),q.set(O.truncDivision(H,2)+Ie,ve),q.set(ve,O.truncDivision(H,2)-Ie),q.set(ve,O.truncDivision(H,2)+Ie)}let J=new rh;return J.setCompact(d),J.setSize(H),J.setLayers(h),J.setCodeWords(_),J.setMatrix(q),J}static drawBullsEye(r,i,s){for(let a=0;a<s;a+=2)for(let l=i-a;l<=i+a;l++)r.set(l,i-a),r.set(l,i+a),r.set(i-a,l),r.set(i+a,l);r.set(i-s,i-s),r.set(i-s+1,i-s),r.set(i-s,i-s+1),r.set(i+s,i-s),r.set(i+s,i-s+1),r.set(i+s,i+s-1)}static generateModeMessage(r,i,s){let a=new W;return r?(a.appendBits(i-1,2),a.appendBits(s-1,6),a=_e.generateCheckWords(a,28,4)):(a.appendBits(i-1,5),a.appendBits(s-1,11),a=_e.generateCheckWords(a,40,4)),a}static drawModeMessage(r,i,s,a){let l=O.truncDivision(s,2);if(i)for(let u=0;u<7;u++){let d=l-3+u;a.get(u)&&r.set(d,l-5),a.get(u+7)&&r.set(l+5,d),a.get(20-u)&&r.set(d,l+5),a.get(27-u)&&r.set(l-5,d)}else for(let u=0;u<10;u++){let d=l-5+u+O.truncDivision(u,5);a.get(u)&&r.set(d,l-7),a.get(u+10)&&r.set(l+7,d),a.get(29-u)&&r.set(d,l+7),a.get(39-u)&&r.set(l-7,d)}}static generateCheckWords(r,i,s){let a=r.getSize()/s,l=new du(_e.getGF(s)),u=O.truncDivision(i,s),d=_e.bitsToWords(r,s,u);l.encode(d,u-a);let h=i%s,p=new W;p.appendBits(0,h);for(const v of Array.from(d))p.appendBits(v,s);return p}static bitsToWords(r,i,s){let a=new Int32Array(s),l,u;for(l=0,u=r.getSize()/i;l<u;l++){let d=0;for(let h=0;h<i;h++)d|=r.get(l*i+h)?1<<i-h-1:0;a[l]=d}return a}static getGF(r){switch(r){case 4:return Ne.AZTEC_PARAM;case 6:return Ne.AZTEC_DATA_6;case 8:return Ne.AZTEC_DATA_8;case 10:return Ne.AZTEC_DATA_10;case 12:return Ne.AZTEC_DATA_12;default:throw new E("Unsupported word size "+r)}}static stuffBits(r,i){let s=new W,a=r.getSize(),l=(1<<i)-2;for(let u=0;u<a;u+=i){let d=0;for(let h=0;h<i;h++)(u+h>=a||r.get(u+h))&&(d|=1<<i-1-h);(d&l)===l?(s.appendBits(d&l,i),u--):d&l?s.appendBits(d,i):(s.appendBits(d|1,i),u--)}return s}static totalBitsInLayer(r,i){return((i?88:112)+16*r)*r}}_e.DEFAULT_EC_PERCENT=33,_e.DEFAULT_AZTEC_LAYERS=0,_e.MAX_NB_BITS=32,_e.MAX_NB_BITS_COMPACT=4,_e.WORD_SIZE=Int32Array.from([4,6,6,8,8,8,8,8,8,10,10,10,10,10,10,10,10,10,10,10,10,10,10,12,12,12,12,12,12,12,12,12,12]);class Sa{encode(r,i,s,a){return this.encodeWithHints(r,i,s,a,null)}encodeWithHints(r,i,s,a,l){let u=gu.ISO_8859_1,d=_e.DEFAULT_EC_PERCENT,h=_e.DEFAULT_AZTEC_LAYERS;return l!=null&&(l.has(vt.CHARACTER_SET)&&(u=th.forName(l.get(vt.CHARACTER_SET).toString())),l.has(vt.ERROR_CORRECTION)&&(d=O.parseInt(l.get(vt.ERROR_CORRECTION).toString())),l.has(vt.AZTEC_LAYERS)&&(h=O.parseInt(l.get(vt.AZTEC_LAYERS).toString()))),Sa.encodeLayers(r,i,s,a,u,d,h)}static encodeLayers(r,i,s,a,l,u,d){if(i!==ae.AZTEC)throw new E("Can only encode AZTEC, but got "+i);let h=_e.encode(ne.getBytes(r,l),u,d);return Sa.renderResult(h,s,a)}static renderResult(r,i,s){let a=r.getMatrix();if(a==null)throw new Yr;let l=a.getWidth(),u=a.getHeight(),d=Math.max(i,l),h=Math.max(s,u),p=Math.min(d/l,h/u),v=(d-l*p)/2,C=(h-u*p)/2,A=new Se(d,h);for(let _=0,M=C;_<u;_++,M+=p)for(let P=0,U=v;P<l;P++,U+=p)a.get(P,_)&&A.setRegion(U,M,p,p);return A}}n.AbstractExpandedDecoder=ru,n.ArgumentException=b,n.ArithmeticException=ha,n.AztecCode=rh,n.AztecCodeReader=ma,n.AztecCodeWriter=Sa,n.AztecDecoder=$e,n.AztecDetector=z0,n.AztecDetectorResult=j0,n.AztecEncoder=_e,n.AztecHighLevelEncoder=Xs,n.AztecPoint=Gt,n.BarcodeFormat=ae,n.Binarizer=k,n.BinaryBitmap=S,n.BitArray=W,n.BitMatrix=Se,n.BitSource=ou,n.BrowserAztecCodeReader=Xv,n.BrowserBarcodeReader=qv,n.BrowserCodeReader=_t,n.BrowserDatamatrixCodeReader=e3,n.BrowserMultiFormatReader=f3,n.BrowserPDF417Reader=d3,n.BrowserQRCodeReader=h3,n.BrowserQRCodeSvgWriter=fi,n.CharacterSetECI=z,n.ChecksumException=R,n.Code128Reader=ee,n.Code39Reader=xt,n.DataMatrixDecodedBitStreamParser=Nn,n.DataMatrixReader=kn,n.DecodeHintType=L,n.DecoderResult=Bs,n.DefaultGridSampler=W0,n.DetectorResult=pa,n.EAN13Reader=oi,n.EncodeHintType=vt,n.Exception=m,n.FormatException=B,n.GenericGF=Ne,n.GenericGFPoly=Jt,n.GlobalHistogramBinarizer=Pe,n.GridSampler=qc,n.GridSamplerInstance=_n,n.HTMLCanvasElementLuminanceSource=ge,n.HybridBinarizer=xe,n.ITFReader=Fe,n.IllegalArgumentException=E,n.IllegalStateException=Yr,n.InvertedLuminanceSource=ue,n.LuminanceSource=te,n.MathUtils=Re,n.MultiFormatOneDReader=Fi,n.MultiFormatReader=eh,n.MultiFormatWriter=p3,n.NotFoundException=G,n.OneDReader=gt,n.PDF417DecodedBitStreamParser=$,n.PDF417DecoderErrorCorrection=Y0,n.PDF417Reader=kt,n.PDF417ResultMetadata=Z0,n.PerspectiveTransform=Dr,n.PlanarYUVLuminanceSource=qr,n.QRCodeByteMatrix=ba,n.QRCodeDataMask=Ar,n.QRCodeDecodedBitStreamParser=Je,n.QRCodeDecoderErrorCorrectionLevel=Ve,n.QRCodeDecoderFormatInformation=jt,n.QRCodeEncoder=Ge,n.QRCodeEncoderQRCode=ui,n.QRCodeMaskUtil=ot,n.QRCodeMatrixUtil=he,n.QRCodeMode=fe,n.QRCodeReader=Dn,n.QRCodeVersion=ce,n.QRCodeWriter=ji,n.RGBLuminanceSource=hu,n.RSS14Reader=st,n.RSSExpandedReader=K,n.ReaderException=Ca,n.ReedSolomonDecoder=Fs,n.ReedSolomonEncoder=du,n.ReedSolomonException=Mi,n.Result=ze,n.ResultMetadataType=qe,n.ResultPoint=le,n.StringUtils=ne,n.UnsupportedOperationException=re,n.VideoInputDevice=We,n.WhiteRectangleDetector=fn,n.WriterException=Ue,n.ZXingArrays=I,n.ZXingCharset=th,n.ZXingInteger=O,n.ZXingStandardCharsets=gu,n.ZXingStringBuilder=de,n.ZXingStringEncoding=we,n.ZXingSystem=D,n.createAbstractExpandedDecoder=G0,Object.defineProperty(n,"__esModule",{value:!0})})})(G1,G1.exports);var et=G1.exports;const cR=Object.freeze(Object.defineProperty({__proto__:null},Symbol.toStringTag,{value:"Module"}));var t2=function(){function e(t,n,o){if(this.formatMap=new Map([[ie.QR_CODE,et.BarcodeFormat.QR_CODE],[ie.AZTEC,et.BarcodeFormat.AZTEC],[ie.CODABAR,et.BarcodeFormat.CODABAR],[ie.CODE_39,et.BarcodeFormat.CODE_39],[ie.CODE_93,et.BarcodeFormat.CODE_93],[ie.CODE_128,et.BarcodeFormat.CODE_128],[ie.DATA_MATRIX,et.BarcodeFormat.DATA_MATRIX],[ie.MAXICODE,et.BarcodeFormat.MAXICODE],[ie.ITF,et.BarcodeFormat.ITF],[ie.EAN_13,et.BarcodeFormat.EAN_13],[ie.EAN_8,et.BarcodeFormat.EAN_8],[ie.PDF_417,et.BarcodeFormat.PDF_417],[ie.RSS_14,et.BarcodeFormat.RSS_14],[ie.RSS_EXPANDED,et.BarcodeFormat.RSS_EXPANDED],[ie.UPC_A,et.BarcodeFormat.UPC_A],[ie.UPC_E,et.BarcodeFormat.UPC_E],[ie.UPC_EAN_EXTENSION,et.BarcodeFormat.UPC_EAN_EXTENSION]]),this.reverseFormatMap=this.createReverseFormatMap(),!cR)throw"Use html5qrcode.min.js without edit, ZXing not found.";this.verbose=n,this.logger=o;var c=this.createZXingFormats(t),f=new Map;f.set(et.DecodeHintType.POSSIBLE_FORMATS,c),f.set(et.DecodeHintType.TRY_HARDER,!1),this.hints=f}return e.prototype.decodeAsync=function(t){var n=this;return new Promise(function(o,c){try{o(n.decode(t))}catch(f){c(f)}})},e.prototype.decode=function(t){var n=new et.MultiFormatReader(this.verbose,this.hints),o=new et.HTMLCanvasElementLuminanceSource(t),c=new et.BinaryBitmap(new et.HybridBinarizer(o)),f=n.decode(c);return{text:f.text,format:Lv.create(this.toHtml5QrcodeSupportedFormats(f.format)),debugData:this.createDebugData()}},e.prototype.createReverseFormatMap=function(){var t=new Map;return this.formatMap.forEach(function(n,o,c){t.set(n,o)}),t},e.prototype.toHtml5QrcodeSupportedFormats=function(t){if(!this.reverseFormatMap.has(t))throw"reverseFormatMap doesn't have ".concat(t);return this.reverseFormatMap.get(t)},e.prototype.createZXingFormats=function(t){for(var n=[],o=0,c=t;o<c.length;o++){var f=c[o];this.formatMap.has(f)?n.push(this.formatMap.get(f)):this.logger.logError("".concat(f," is not supported by")+"ZXingHtml5QrcodeShim")}return n},e.prototype.createDebugData=function(){return{decoderName:"zxing-js"}},e}(),uR=function(e,t,n,o){function c(f){return f instanceof n?f:new n(function(g){g(f)})}return new(n||(n=Promise))(function(f,g){function x(b){try{m(o.next(b))}catch(E){g(E)}}function w(b){try{m(o.throw(b))}catch(E){g(E)}}function m(b){b.done?f(b.value):c(b.value).then(x,w)}m((o=o.apply(e,t||[])).next())})},fR=function(e,t){var n={label:0,sent:function(){if(f[0]&1)throw f[1];return f[1]},trys:[],ops:[]},o,c,f,g;return g={next:x(0),throw:x(1),return:x(2)},typeof Symbol=="function"&&(g[Symbol.iterator]=function(){return this}),g;function x(m){return function(b){return w([m,b])}}function w(m){if(o)throw new TypeError("Generator is already executing.");for(;g&&(g=0,m[0]&&(n=0)),n;)try{if(o=1,c&&(f=m[0]&2?c.return:m[0]?c.throw||((f=c.return)&&f.call(c),0):c.next)&&!(f=f.call(c,m[1])).done)return f;switch(c=0,f&&(m=[m[0]&2,f.value]),m[0]){case 0:case 1:f=m;break;case 4:return n.label++,{value:m[1],done:!1};case 5:n.label++,c=m[1],m=[0];continue;case 7:m=n.ops.pop(),n.trys.pop();continue;default:if(f=n.trys,!(f=f.length>0&&f[f.length-1])&&(m[0]===6||m[0]===2)){n=0;continue}if(m[0]===3&&(!f||m[1]>f[0]&&m[1]<f[3])){n.label=m[1];break}if(m[0]===6&&n.label<f[1]){n.label=f[1],f=m;break}if(f&&n.label<f[2]){n.label=f[2],n.ops.push(m);break}f[2]&&n.ops.pop(),n.trys.pop();continue}m=t.call(e,n)}catch(b){m=[6,b],c=0}finally{o=f=0}if(m[0]&5)throw m[1];return{value:m[0]?m[1]:void 0,done:!0}}},r2=function(){function e(t,n,o){if(this.formatMap=new Map([[ie.QR_CODE,"qr_code"],[ie.AZTEC,"aztec"],[ie.CODABAR,"codabar"],[ie.CODE_39,"code_39"],[ie.CODE_93,"code_93"],[ie.CODE_128,"code_128"],[ie.DATA_MATRIX,"data_matrix"],[ie.ITF,"itf"],[ie.EAN_13,"ean_13"],[ie.EAN_8,"ean_8"],[ie.PDF_417,"pdf417"],[ie.UPC_A,"upc_a"],[ie.UPC_E,"upc_e"]]),this.reverseFormatMap=this.createReverseFormatMap(),!e.isSupported())throw"Use html5qrcode.min.js without edit, Use BarcodeDetectorDelegate only if it isSupported();";this.verbose=n,this.logger=o;var c=this.createBarcodeDetectorFormats(t);if(this.detector=new BarcodeDetector(c),!this.detector)throw"BarcodeDetector detector not supported"}return e.isSupported=function(){if(!("BarcodeDetector"in window))return!1;var t=new BarcodeDetector({formats:["qr_code"]});return typeof t<"u"},e.prototype.decodeAsync=function(t){return uR(this,void 0,void 0,function(){var n,o;return fR(this,function(c){switch(c.label){case 0:return[4,this.detector.detect(t)];case 1:if(n=c.sent(),!n||n.length===0)throw"No barcode or QR code detected.";return o=this.selectLargestBarcode(n),[2,{text:o.rawValue,format:Lv.create(this.toHtml5QrcodeSupportedFormats(o.format)),debugData:this.createDebugData()}]}})})},e.prototype.selectLargestBarcode=function(t){for(var n=null,o=0,c=0,f=t;c<f.length;c++){var g=f[c],x=g.boundingBox.width*g.boundingBox.height;x>o&&(o=x,n=g)}if(!n)throw"No largest barcode found";return n},e.prototype.createBarcodeDetectorFormats=function(t){for(var n=[],o=0,c=t;o<c.length;o++){var f=c[o];this.formatMap.has(f)?n.push(this.formatMap.get(f)):this.logger.warn("".concat(f," is not supported by")+"BarcodeDetectorDelegate")}return{formats:n}},e.prototype.toHtml5QrcodeSupportedFormats=function(t){if(!this.reverseFormatMap.has(t))throw"reverseFormatMap doesn't have ".concat(t);return this.reverseFormatMap.get(t)},e.prototype.createReverseFormatMap=function(){var t=new Map;return this.formatMap.forEach(function(n,o,c){t.set(n,o)}),t},e.prototype.createDebugData=function(){return{decoderName:"BarcodeDetector"}},e}(),n2=function(e,t,n,o){function c(f){return f instanceof n?f:new n(function(g){g(f)})}return new(n||(n=Promise))(function(f,g){function x(b){try{m(o.next(b))}catch(E){g(E)}}function w(b){try{m(o.throw(b))}catch(E){g(E)}}function m(b){b.done?f(b.value):c(b.value).then(x,w)}m((o=o.apply(e,t||[])).next())})},i2=function(e,t){var n={label:0,sent:function(){if(f[0]&1)throw f[1];return f[1]},trys:[],ops:[]},o,c,f,g;return g={next:x(0),throw:x(1),return:x(2)},typeof Symbol=="function"&&(g[Symbol.iterator]=function(){return this}),g;function x(m){return function(b){return w([m,b])}}function w(m){if(o)throw new TypeError("Generator is already executing.");for(;g&&(g=0,m[0]&&(n=0)),n;)try{if(o=1,c&&(f=m[0]&2?c.return:m[0]?c.throw||((f=c.return)&&f.call(c),0):c.next)&&!(f=f.call(c,m[1])).done)return f;switch(c=0,f&&(m=[m[0]&2,f.value]),m[0]){case 0:case 1:f=m;break;case 4:return n.label++,{value:m[1],done:!1};case 5:n.label++,c=m[1],m=[0];continue;case 7:m=n.ops.pop(),n.trys.pop();continue;default:if(f=n.trys,!(f=f.length>0&&f[f.length-1])&&(m[0]===6||m[0]===2)){n=0;continue}if(m[0]===3&&(!f||m[1]>f[0]&&m[1]<f[3])){n.label=m[1];break}if(m[0]===6&&n.label<f[1]){n.label=f[1],f=m;break}if(f&&n.label<f[2]){n.label=f[2],n.ops.push(m);break}f[2]&&n.ops.pop(),n.trys.pop();continue}m=t.call(e,n)}catch(b){m=[6,b],c=0}finally{o=f=0}if(m[0]&5)throw m[1];return{value:m[0]?m[1]:void 0,done:!0}}},dR=function(){function e(t,n,o,c){this.EXECUTIONS_TO_REPORT_PERFORMANCE=100,this.executions=0,this.executionResults=[],this.wasPrimaryDecoderUsedInLastDecode=!1,this.verbose=o,n&&r2.isSupported()?(this.primaryDecoder=new r2(t,o,c),this.secondaryDecoder=new t2(t,o,c)):this.primaryDecoder=new t2(t,o,c)}return e.prototype.decodeAsync=function(t){return n2(this,void 0,void 0,function(){var n;return i2(this,function(o){switch(o.label){case 0:n=performance.now(),o.label=1;case 1:return o.trys.push([1,,3,4]),[4,this.getDecoder().decodeAsync(t)];case 2:return[2,o.sent()];case 3:return this.possiblyLogPerformance(n),[7];case 4:return[2]}})})},e.prototype.decodeRobustlyAsync=function(t){return n2(this,void 0,void 0,function(){var n,o;return i2(this,function(c){switch(c.label){case 0:n=performance.now(),c.label=1;case 1:return c.trys.push([1,3,4,5]),[4,this.primaryDecoder.decodeAsync(t)];case 2:return[2,c.sent()];case 3:if(o=c.sent(),this.secondaryDecoder)return[2,this.secondaryDecoder.decodeAsync(t)];throw o;case 4:return this.possiblyLogPerformance(n),[7];case 5:return[2]}})})},e.prototype.getDecoder=function(){return this.secondaryDecoder?this.wasPrimaryDecoderUsedInLastDecode===!1?(this.wasPrimaryDecoderUsedInLastDecode=!0,this.primaryDecoder):(this.wasPrimaryDecoderUsedInLastDecode=!1,this.secondaryDecoder):this.primaryDecoder},e.prototype.possiblyLogPerformance=function(t){if(this.verbose){var n=performance.now()-t;this.executionResults.push(n),this.executions++,this.possiblyFlushPerformanceReport()}},e.prototype.possiblyFlushPerformanceReport=function(){if(!(this.executions<this.EXECUTIONS_TO_REPORT_PERFORMANCE)){for(var t=0,n=0,o=this.executionResults;n<o.length;n++){var c=o[n];t+=c}var f=t/this.executionResults.length;console.log("".concat(f," ms for ").concat(this.executionResults.length," last runs.")),this.executions=0,this.executionResults=[]}},e}(),F0=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,c){o.__proto__=c}||function(o,c){for(var f in c)Object.prototype.hasOwnProperty.call(c,f)&&(o[f]=c[f])},e(t,n)};return function(t,n){if(typeof n!="function"&&n!==null)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");e(t,n);function o(){this.constructor=t}t.prototype=n===null?Object.create(n):(o.prototype=n.prototype,new o)}}(),uc=function(e,t,n,o){function c(f){return f instanceof n?f:new n(function(g){g(f)})}return new(n||(n=Promise))(function(f,g){function x(b){try{m(o.next(b))}catch(E){g(E)}}function w(b){try{m(o.throw(b))}catch(E){g(E)}}function m(b){b.done?f(b.value):c(b.value).then(x,w)}m((o=o.apply(e,t||[])).next())})},fc=function(e,t){var n={label:0,sent:function(){if(f[0]&1)throw f[1];return f[1]},trys:[],ops:[]},o,c,f,g;return g={next:x(0),throw:x(1),return:x(2)},typeof Symbol=="function"&&(g[Symbol.iterator]=function(){return this}),g;function x(m){return function(b){return w([m,b])}}function w(m){if(o)throw new TypeError("Generator is already executing.");for(;g&&(g=0,m[0]&&(n=0)),n;)try{if(o=1,c&&(f=m[0]&2?c.return:m[0]?c.throw||((f=c.return)&&f.call(c),0):c.next)&&!(f=f.call(c,m[1])).done)return f;switch(c=0,f&&(m=[m[0]&2,f.value]),m[0]){case 0:case 1:f=m;break;case 4:return n.label++,{value:m[1],done:!1};case 5:n.label++,c=m[1],m=[0];continue;case 7:m=n.ops.pop(),n.trys.pop();continue;default:if(f=n.trys,!(f=f.length>0&&f[f.length-1])&&(m[0]===6||m[0]===2)){n=0;continue}if(m[0]===3&&(!f||m[1]>f[0]&&m[1]<f[3])){n.label=m[1];break}if(m[0]===6&&n.label<f[1]){n.label=f[1],f=m;break}if(f&&n.label<f[2]){n.label=f[2],n.ops.push(m);break}f[2]&&n.ops.pop(),n.trys.pop();continue}m=t.call(e,n)}catch(b){m=[6,b],c=0}finally{o=f=0}if(m[0]&5)throw m[1];return{value:m[0]?m[1]:void 0,done:!0}}},Uv=function(){function e(t,n){this.name=t,this.track=n}return e.prototype.isSupported=function(){return this.track.getCapabilities?this.name in this.track.getCapabilities():!1},e.prototype.apply=function(t){var n={};n[this.name]=t;var o={advanced:[n]};return this.track.applyConstraints(o)},e.prototype.value=function(){var t=this.track.getSettings();if(this.name in t){var n=t[this.name];return n}return null},e}(),hR=function(e){F0(t,e);function t(n,o){return e.call(this,n,o)||this}return t.prototype.min=function(){return this.getCapabilities().min},t.prototype.max=function(){return this.getCapabilities().max},t.prototype.step=function(){return this.getCapabilities().step},t.prototype.apply=function(n){var o={};o[this.name]=n;var c={advanced:[o]};return this.track.applyConstraints(c)},t.prototype.getCapabilities=function(){this.failIfNotSupported();var n=this.track.getCapabilities(),o=n[this.name];return{min:o.min,max:o.max,step:o.step}},t.prototype.failIfNotSupported=function(){if(!this.isSupported())throw new Error("".concat(this.name," capability not supported"))},t}(Uv),gR=function(e){F0(t,e);function t(n){return e.call(this,"zoom",n)||this}return t}(hR),pR=function(e){F0(t,e);function t(n){return e.call(this,"torch",n)||this}return t}(Uv),mR=function(){function e(t){this.track=t}return e.prototype.zoomFeature=function(){return new gR(this.track)},e.prototype.torchFeature=function(){return new pR(this.track)},e}(),xR=function(){function e(t,n,o){this.isClosed=!1,this.parentElement=t,this.mediaStream=n,this.callbacks=o,this.surface=this.createVideoElement(this.parentElement.clientWidth),t.append(this.surface)}return e.prototype.createVideoElement=function(t){var n=document.createElement("video");return n.style.width="".concat(t,"px"),n.style.display="block",n.muted=!0,n.setAttribute("muted","true"),n.playsInline=!0,n},e.prototype.setupSurface=function(){var t=this;this.surface.onabort=function(){throw"RenderedCameraImpl video surface onabort() called"},this.surface.onerror=function(){throw"RenderedCameraImpl video surface onerror() called"};var n=function(){var o=t.surface.clientWidth,c=t.surface.clientHeight;t.callbacks.onRenderSurfaceReady(o,c),t.surface.removeEventListener("playing",n)};this.surface.addEventListener("playing",n),this.surface.srcObject=this.mediaStream,this.surface.play()},e.create=function(t,n,o,c){return uc(this,void 0,void 0,function(){var f,g;return fc(this,function(x){switch(x.label){case 0:return f=new e(t,n,c),o.aspectRatio?(g={aspectRatio:o.aspectRatio},[4,f.getFirstTrackOrFail().applyConstraints(g)]):[3,2];case 1:x.sent(),x.label=2;case 2:return f.setupSurface(),[2,f]}})})},e.prototype.failIfClosed=function(){if(this.isClosed)throw"The RenderedCamera has already been closed."},e.prototype.getFirstTrackOrFail=function(){if(this.failIfClosed(),this.mediaStream.getVideoTracks().length===0)throw"No video tracks found";return this.mediaStream.getVideoTracks()[0]},e.prototype.pause=function(){this.failIfClosed(),this.surface.pause()},e.prototype.resume=function(t){this.failIfClosed();var n=this,o=function(){setTimeout(t,200),n.surface.removeEventListener("playing",o)};this.surface.addEventListener("playing",o),this.surface.play()},e.prototype.isPaused=function(){return this.failIfClosed(),this.surface.paused},e.prototype.getSurface=function(){return this.failIfClosed(),this.surface},e.prototype.getRunningTrackCapabilities=function(){return this.getFirstTrackOrFail().getCapabilities()},e.prototype.getRunningTrackSettings=function(){return this.getFirstTrackOrFail().getSettings()},e.prototype.applyVideoConstraints=function(t){return uc(this,void 0,void 0,function(){return fc(this,function(n){if("aspectRatio"in t)throw"Changing 'aspectRatio' in run-time is not yet supported.";return[2,this.getFirstTrackOrFail().applyConstraints(t)]})})},e.prototype.close=function(){if(this.isClosed)return Promise.resolve();var t=this;return new Promise(function(n,o){var c=t.mediaStream.getVideoTracks(),f=c.length,g=0;t.mediaStream.getVideoTracks().forEach(function(x){t.mediaStream.removeTrack(x),x.stop(),++g,g>=f&&(t.isClosed=!0,t.parentElement.removeChild(t.surface),n())})})},e.prototype.getCapabilities=function(){return new mR(this.getFirstTrackOrFail())},e}(),wR=function(){function e(t){this.mediaStream=t}return e.prototype.render=function(t,n,o){return uc(this,void 0,void 0,function(){return fc(this,function(c){return[2,xR.create(t,this.mediaStream,n,o)]})})},e.create=function(t){return uc(this,void 0,void 0,function(){var n,o;return fc(this,function(c){switch(c.label){case 0:if(!navigator.mediaDevices)throw"navigator.mediaDevices not supported";return n={audio:!1,video:t},[4,navigator.mediaDevices.getUserMedia(n)];case 1:return o=c.sent(),[2,new e(o)]}})})},e}(),s2=function(e,t,n,o){function c(f){return f instanceof n?f:new n(function(g){g(f)})}return new(n||(n=Promise))(function(f,g){function x(b){try{m(o.next(b))}catch(E){g(E)}}function w(b){try{m(o.throw(b))}catch(E){g(E)}}function m(b){b.done?f(b.value):c(b.value).then(x,w)}m((o=o.apply(e,t||[])).next())})},o2=function(e,t){var n={label:0,sent:function(){if(f[0]&1)throw f[1];return f[1]},trys:[],ops:[]},o,c,f,g;return g={next:x(0),throw:x(1),return:x(2)},typeof Symbol=="function"&&(g[Symbol.iterator]=function(){return this}),g;function x(m){return function(b){return w([m,b])}}function w(m){if(o)throw new TypeError("Generator is already executing.");for(;g&&(g=0,m[0]&&(n=0)),n;)try{if(o=1,c&&(f=m[0]&2?c.return:m[0]?c.throw||((f=c.return)&&f.call(c),0):c.next)&&!(f=f.call(c,m[1])).done)return f;switch(c=0,f&&(m=[m[0]&2,f.value]),m[0]){case 0:case 1:f=m;break;case 4:return n.label++,{value:m[1],done:!1};case 5:n.label++,c=m[1],m=[0];continue;case 7:m=n.ops.pop(),n.trys.pop();continue;default:if(f=n.trys,!(f=f.length>0&&f[f.length-1])&&(m[0]===6||m[0]===2)){n=0;continue}if(m[0]===3&&(!f||m[1]>f[0]&&m[1]<f[3])){n.label=m[1];break}if(m[0]===6&&n.label<f[1]){n.label=f[1],f=m;break}if(f&&n.label<f[2]){n.label=f[2],n.ops.push(m);break}f[2]&&n.ops.pop(),n.trys.pop();continue}m=t.call(e,n)}catch(b){m=[6,b],c=0}finally{o=f=0}if(m[0]&5)throw m[1];return{value:m[0]?m[1]:void 0,done:!0}}},vR=function(){function e(){}return e.failIfNotSupported=function(){return s2(this,void 0,void 0,function(){return o2(this,function(t){if(!navigator.mediaDevices)throw"navigator.mediaDevices not supported";return[2,new e]})})},e.prototype.create=function(t){return s2(this,void 0,void 0,function(){return o2(this,function(n){return[2,wR.create(t)]})})},e}(),yR=function(e,t,n,o){function c(f){return f instanceof n?f:new n(function(g){g(f)})}return new(n||(n=Promise))(function(f,g){function x(b){try{m(o.next(b))}catch(E){g(E)}}function w(b){try{m(o.throw(b))}catch(E){g(E)}}function m(b){b.done?f(b.value):c(b.value).then(x,w)}m((o=o.apply(e,t||[])).next())})},ER=function(e,t){var n={label:0,sent:function(){if(f[0]&1)throw f[1];return f[1]},trys:[],ops:[]},o,c,f,g;return g={next:x(0),throw:x(1),return:x(2)},typeof Symbol=="function"&&(g[Symbol.iterator]=function(){return this}),g;function x(m){return function(b){return w([m,b])}}function w(m){if(o)throw new TypeError("Generator is already executing.");for(;g&&(g=0,m[0]&&(n=0)),n;)try{if(o=1,c&&(f=m[0]&2?c.return:m[0]?c.throw||((f=c.return)&&f.call(c),0):c.next)&&!(f=f.call(c,m[1])).done)return f;switch(c=0,f&&(m=[m[0]&2,f.value]),m[0]){case 0:case 1:f=m;break;case 4:return n.label++,{value:m[1],done:!1};case 5:n.label++,c=m[1],m=[0];continue;case 7:m=n.ops.pop(),n.trys.pop();continue;default:if(f=n.trys,!(f=f.length>0&&f[f.length-1])&&(m[0]===6||m[0]===2)){n=0;continue}if(m[0]===3&&(!f||m[1]>f[0]&&m[1]<f[3])){n.label=m[1];break}if(m[0]===6&&n.label<f[1]){n.label=f[1],f=m;break}if(f&&n.label<f[2]){n.label=f[2],n.ops.push(m);break}f[2]&&n.ops.pop(),n.trys.pop();continue}m=t.call(e,n)}catch(b){m=[6,b],c=0}finally{o=f=0}if(m[0]&5)throw m[1];return{value:m[0]?m[1]:void 0,done:!0}}},CR=function(){function e(){}return e.retrieve=function(){if(navigator.mediaDevices)return e.getCamerasFromMediaDevices();var t=MediaStreamTrack;return MediaStreamTrack&&t.getSources?e.getCamerasFromMediaStreamTrack():e.rejectWithError()},e.rejectWithError=function(){var t=cs.unableToQuerySupportedDevices();return e.isHttpsOrLocalhost()||(t=cs.insecureContextCameraQueryError()),Promise.reject(t)},e.isHttpsOrLocalhost=function(){if(location.protocol==="https:")return!0;var t=location.host.split(":")[0];return t==="127.0.0.1"||t==="localhost"},e.getCamerasFromMediaDevices=function(){return yR(this,void 0,void 0,function(){var t,n,o,c,f,g,x;return ER(this,function(w){switch(w.label){case 0:return t=function(m){for(var b=m.getVideoTracks(),E=0,S=b;E<S.length;E++){var R=S[E];R.enabled=!1,R.stop(),m.removeTrack(R)}},[4,navigator.mediaDevices.getUserMedia({audio:!1,video:!0})];case 1:return n=w.sent(),[4,navigator.mediaDevices.enumerateDevices()];case 2:for(o=w.sent(),c=[],f=0,g=o;f<g.length;f++)x=g[f],x.kind==="videoinput"&&c.push({id:x.deviceId,label:x.label});return t(n),[2,c]}})})},e.getCamerasFromMediaStreamTrack=function(){return new Promise(function(t,n){var o=function(f){for(var g=[],x=0,w=f;x<w.length;x++){var m=w[x];m.kind==="video"&&g.push({id:m.id,label:m.label})}t(g)},c=MediaStreamTrack;c.getSources(o)})},e}(),at;(function(e){e[e.UNKNOWN=0]="UNKNOWN",e[e.NOT_STARTED=1]="NOT_STARTED",e[e.SCANNING=2]="SCANNING",e[e.PAUSED=3]="PAUSED"})(at||(at={}));var bR=function(){function e(){this.state=at.NOT_STARTED,this.onGoingTransactionNewState=at.UNKNOWN}return e.prototype.directTransition=function(t){this.failIfTransitionOngoing(),this.validateTransition(t),this.state=t},e.prototype.startTransition=function(t){return this.failIfTransitionOngoing(),this.validateTransition(t),this.onGoingTransactionNewState=t,this},e.prototype.execute=function(){if(this.onGoingTransactionNewState===at.UNKNOWN)throw"Transaction is already cancelled, cannot execute().";var t=this.onGoingTransactionNewState;this.onGoingTransactionNewState=at.UNKNOWN,this.directTransition(t)},e.prototype.cancel=function(){if(this.onGoingTransactionNewState===at.UNKNOWN)throw"Transaction is already cancelled, cannot cancel().";this.onGoingTransactionNewState=at.UNKNOWN},e.prototype.getState=function(){return this.state},e.prototype.failIfTransitionOngoing=function(){if(this.onGoingTransactionNewState!==at.UNKNOWN)throw"Cannot transition to a new state, already under transition"},e.prototype.validateTransition=function(t){switch(this.state){case at.UNKNOWN:throw"Transition from unknown is not allowed";case at.NOT_STARTED:this.failIfNewStateIs(t,[at.PAUSED]);break;case at.SCANNING:break;case at.PAUSED:break}},e.prototype.failIfNewStateIs=function(t,n){for(var o=0,c=n;o<c.length;o++){var f=c[o];if(t===f)throw"Cannot transition from ".concat(this.state," to ").concat(t)}},e}(),AR=function(){function e(t){this.stateManager=t}return e.prototype.startTransition=function(t){return this.stateManager.startTransition(t)},e.prototype.directTransition=function(t){this.stateManager.directTransition(t)},e.prototype.getState=function(){return this.stateManager.getState()},e.prototype.canScanFile=function(){return this.stateManager.getState()===at.NOT_STARTED},e.prototype.isScanning=function(){return this.stateManager.getState()!==at.NOT_STARTED},e.prototype.isStrictlyScanning=function(){return this.stateManager.getState()===at.SCANNING},e.prototype.isPaused=function(){return this.stateManager.getState()===at.PAUSED},e}(),SR=function(){function e(){}return e.create=function(){return new AR(new bR)},e}(),IR=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(o,c){o.__proto__=c}||function(o,c){for(var f in c)Object.prototype.hasOwnProperty.call(c,f)&&(o[f]=c[f])},e(t,n)};return function(t,n){if(typeof n!="function"&&n!==null)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");e(t,n);function o(){this.constructor=t}t.prototype=n===null?Object.create(n):(o.prototype=n.prototype,new o)}}(),gr=function(e){IR(t,e);function t(){return e!==null&&e.apply(this,arguments)||this}return t.DEFAULT_WIDTH=300,t.DEFAULT_WIDTH_OFFSET=2,t.FILE_SCAN_MIN_HEIGHT=300,t.FILE_SCAN_HIDDEN_CANVAS_PADDING=100,t.MIN_QR_BOX_SIZE=50,t.SHADED_LEFT=1,t.SHADED_RIGHT=2,t.SHADED_TOP=3,t.SHADED_BOTTOM=4,t.SHADED_REGION_ELEMENT_ID="qr-shaded-region",t.VERBOSE=!1,t.BORDER_SHADER_DEFAULT_COLOR="#ffffff",t.BORDER_SHADER_MATCH_COLOR="rgb(90, 193, 56)",t}(oR),TR=function(){function e(t,n){this.logger=n,this.fps=gr.SCAN_DEFAULT_FPS,t?(t.fps&&(this.fps=t.fps),this.disableFlip=t.disableFlip===!0,this.qrbox=t.qrbox,this.aspectRatio=t.aspectRatio,this.videoConstraints=t.videoConstraints):this.disableFlip=gr.DEFAULT_DISABLE_FLIP}return e.prototype.isMediaStreamConstraintsValid=function(){return this.videoConstraints?Fv.isMediaStreamConstraintsValid(this.videoConstraints,this.logger):(this.logger.logError("Empty videoConstraints",!0),!1)},e.prototype.isShadedBoxEnabled=function(){return!dn(this.qrbox)},e.create=function(t,n){return new e(t,n)},e}(),u_=function(){function e(t,n){if(this.element=null,this.canvasElement=null,this.scannerPausedUiElement=null,this.hasBorderShaders=null,this.borderShaders=null,this.qrMatch=null,this.renderedCamera=null,this.qrRegion=null,this.context=null,this.lastScanImageFile=null,this.isScanning=!1,!document.getElementById(t))throw"HTML Element with id=".concat(t," not found");this.elementId=t,this.verbose=!1;var o;typeof n=="boolean"?this.verbose=n===!0:n&&(o=n,this.verbose=o.verbose===!0,o.experimentalFeatures),this.logger=new lR(this.verbose),this.qrcode=new dR(this.getSupportedFormats(n),this.getUseBarCodeDetectorIfSupported(o),this.verbose,this.logger),this.foreverScanTimeout,this.shouldScan=!0,this.stateManagerProxy=SR.create()}return e.prototype.start=function(t,n,o,c){var f=this;if(!t)throw"cameraIdOrConfig is required";if(!o||typeof o!="function")throw"qrCodeSuccessCallback is required and should be a function.";var g;c?g=c:g=this.verbose?this.logger.log:function(){};var x=TR.create(n,this.logger);this.clearElement();var w=!1;x.videoConstraints&&(x.isMediaStreamConstraintsValid()?w=!0:this.logger.logError("'videoConstraints' is not valid 'MediaStreamConstraints, it will be ignored.'",!0));var m=w,b=document.getElementById(this.elementId);b.clientWidth?b.clientWidth:gr.DEFAULT_WIDTH,b.style.position="relative",this.shouldScan=!0,this.element=b;var E=this,S=this.stateManagerProxy.startTransition(at.SCANNING);return new Promise(function(R,k){var D=m?x.videoConstraints:E.createVideoConstraints(t);if(!D){S.cancel(),k("videoConstraints should be defined");return}var Y={};(!m||x.aspectRatio)&&(Y.aspectRatio=x.aspectRatio);var N={onRenderSurfaceReady:function(I,O){E.setupUi(I,O,x),E.isScanning=!0,E.foreverScan(x,o,g)}};vR.failIfNotSupported().then(function(I){I.create(D).then(function(O){return O.render(f.element,Y,N).then(function(W){E.renderedCamera=W,S.execute(),R(null)}).catch(function(W){S.cancel(),k(W)})}).catch(function(O){S.cancel(),k(cs.errorGettingUserMedia(O))})}).catch(function(I){S.cancel(),k(cs.cameraStreamingNotSupported())})})},e.prototype.pause=function(t){if(!this.stateManagerProxy.isStrictlyScanning())throw"Cannot pause, scanner is not scanning.";this.stateManagerProxy.directTransition(at.PAUSED),this.showPausedState(),(dn(t)||t!==!0)&&(t=!1),t&&this.renderedCamera&&this.renderedCamera.pause()},e.prototype.resume=function(){if(!this.stateManagerProxy.isPaused())throw"Cannot result, scanner is not paused.";if(!this.renderedCamera)throw"renderedCamera doesn't exist while trying resume()";var t=this,n=function(){t.stateManagerProxy.directTransition(at.SCANNING),t.hidePausedState()};if(!this.renderedCamera.isPaused()){n();return}this.renderedCamera.resume(function(){n()})},e.prototype.getState=function(){return this.stateManagerProxy.getState()},e.prototype.stop=function(){var t=this;if(!this.stateManagerProxy.isScanning())throw"Cannot stop, scanner is not running or paused.";var n=this.stateManagerProxy.startTransition(at.NOT_STARTED);this.shouldScan=!1,this.foreverScanTimeout&&clearTimeout(this.foreverScanTimeout);var o=function(){if(t.element){var f=document.getElementById(gr.SHADED_REGION_ELEMENT_ID);f&&t.element.removeChild(f)}},c=this;return this.renderedCamera.close().then(function(){return c.renderedCamera=null,c.element&&(c.element.removeChild(c.canvasElement),c.canvasElement=null),o(),c.qrRegion&&(c.qrRegion=null),c.context&&(c.context=null),n.execute(),c.hidePausedState(),c.isScanning=!1,Promise.resolve()})},e.prototype.scanFile=function(t,n){return this.scanFileV2(t,n).then(function(o){return o.decodedText})},e.prototype.scanFileV2=function(t,n){var o=this;if(!t||!(t instanceof File))throw"imageFile argument is mandatory and should be instance of File. Use 'event.target.files[0]'.";if(dn(n)&&(n=!0),!this.stateManagerProxy.canScanFile())throw"Cannot start file scan - ongoing camera scan";return new Promise(function(c,f){o.possiblyCloseLastScanImageFile(),o.clearElement(),o.lastScanImageFile=URL.createObjectURL(t);var g=new Image;g.onload=function(){var x=g.width,w=g.height,m=document.getElementById(o.elementId),b=m.clientWidth?m.clientWidth:gr.DEFAULT_WIDTH,E=Math.max(m.clientHeight?m.clientHeight:w,gr.FILE_SCAN_MIN_HEIGHT),S=o.computeCanvasDrawConfig(x,w,b,E);if(n){var R=o.createCanvasElement(b,E,"qr-canvas-visible");R.style.display="inline-block",m.appendChild(R);var k=R.getContext("2d");if(!k)throw"Unable to get 2d context from canvas";k.canvas.width=b,k.canvas.height=E,k.drawImage(g,0,0,x,w,S.x,S.y,S.width,S.height)}var D=gr.FILE_SCAN_HIDDEN_CANVAS_PADDING,Y=Math.max(g.width,S.width),N=Math.max(g.height,S.height),I=Y+2*D,O=N+2*D,W=o.createCanvasElement(I,O);m.appendChild(W);var V=W.getContext("2d");if(!V)throw"Unable to get 2d context from canvas";V.canvas.width=I,V.canvas.height=O,V.drawImage(g,0,0,x,w,D,D,Y,N);try{o.qrcode.decodeRobustlyAsync(W).then(function(L){c(e2.createFromQrcodeResult(L))}).catch(f)}catch(L){f("QR code parse error, error = ".concat(L))}},g.onerror=f,g.onabort=f,g.onstalled=f,g.onsuspend=f,g.src=URL.createObjectURL(t)})},e.prototype.clear=function(){this.clearElement()},e.getCameras=function(){return CR.retrieve()},e.prototype.getRunningTrackCapabilities=function(){return this.getRenderedCameraOrFail().getRunningTrackCapabilities()},e.prototype.getRunningTrackSettings=function(){return this.getRenderedCameraOrFail().getRunningTrackSettings()},e.prototype.getRunningTrackCameraCapabilities=function(){return this.getRenderedCameraOrFail().getCapabilities()},e.prototype.applyVideoConstraints=function(t){if(t){if(!Fv.isMediaStreamConstraintsValid(t,this.logger))throw"invalid videoConstaints passed, check logs for more details"}else throw"videoConstaints is required argument.";return this.getRenderedCameraOrFail().applyVideoConstraints(t)},e.prototype.getRenderedCameraOrFail=function(){if(this.renderedCamera==null)throw"Scanning is not in running state, call this API only when QR code scanning using camera is in running state.";return this.renderedCamera},e.prototype.getSupportedFormats=function(t){var n=[ie.QR_CODE,ie.AZTEC,ie.CODABAR,ie.CODE_39,ie.CODE_93,ie.CODE_128,ie.DATA_MATRIX,ie.MAXICODE,ie.ITF,ie.EAN_13,ie.EAN_8,ie.PDF_417,ie.RSS_14,ie.RSS_EXPANDED,ie.UPC_A,ie.UPC_E,ie.UPC_EAN_EXTENSION];if(!t||typeof t=="boolean"||!t.formatsToSupport)return n;if(!Array.isArray(t.formatsToSupport))throw"configOrVerbosityFlag.formatsToSupport should be undefined or an array.";if(t.formatsToSupport.length===0)throw"Atleast 1 formatsToSupport is needed.";for(var o=[],c=0,f=t.formatsToSupport;c<f.length;c++){var g=f[c];sR(g)?o.push(g):this.logger.warn("Invalid format: ".concat(g," passed in config, ignoring."))}if(o.length===0)throw"None of formatsToSupport match supported values.";return o},e.prototype.getUseBarCodeDetectorIfSupported=function(t){if(dn(t))return!0;if(!dn(t.useBarCodeDetectorIfSupported))return t.useBarCodeDetectorIfSupported!==!1;if(dn(t.experimentalFeatures))return!0;var n=t.experimentalFeatures;return dn(n.useBarCodeDetectorIfSupported)?!0:n.useBarCodeDetectorIfSupported!==!1},e.prototype.validateQrboxSize=function(t,n,o){var c=this,f=o.qrbox;this.validateQrboxConfig(f);var g=this.toQrdimensions(t,n,f),x=function(m){if(m<gr.MIN_QR_BOX_SIZE)throw"minimum size of 'config.qrbox' dimension value is"+" ".concat(gr.MIN_QR_BOX_SIZE,"px.")},w=function(m){return m>t&&(c.logger.warn("`qrbox.width` or `qrbox` is larger than the width of the root element. The width will be truncated to the width of root element."),m=t),m};x(g.width),x(g.height),g.width=w(g.width)},e.prototype.validateQrboxConfig=function(t){if(typeof t!="number"&&typeof t!="function"&&(t.width===void 0||t.height===void 0))throw"Invalid instance of QrDimensions passed for 'config.qrbox'. Both 'width' and 'height' should be set."},e.prototype.toQrdimensions=function(t,n,o){if(typeof o=="number")return{width:o,height:o};if(typeof o=="function")try{return o(t,n)}catch(c){throw new Error("qrbox config was passed as a function but it failed with unknown error"+c)}return o},e.prototype.setupUi=function(t,n,o){o.isShadedBoxEnabled()&&this.validateQrboxSize(t,n,o);var c=dn(o.qrbox)?{width:t,height:n}:o.qrbox;this.validateQrboxConfig(c);var f=this.toQrdimensions(t,n,c);f.height>n&&this.logger.warn("[Html5Qrcode] config.qrbox has height that isgreater than the height of the video stream. Shading will be ignored");var g=o.isShadedBoxEnabled()&&f.height<=n,x={x:0,y:0,width:t,height:n},w=g?this.getShadedRegionBounds(t,n,f):x,m=this.createCanvasElement(w.width,w.height),b={willReadFrequently:!0},E=m.getContext("2d",b);E.canvas.width=w.width,E.canvas.height=w.height,this.element.append(m),g&&this.possiblyInsertShadingElement(this.element,t,n,f),this.createScannerPausedUiElement(this.element),this.qrRegion=w,this.context=E,this.canvasElement=m},e.prototype.createScannerPausedUiElement=function(t){var n=document.createElement("div");n.innerText=cs.scannerPaused(),n.style.display="none",n.style.position="absolute",n.style.top="0px",n.style.zIndex="1",n.style.background="rgba(9, 9, 9, 0.46)",n.style.color="#FFECEC",n.style.textAlign="center",n.style.width="100%",t.appendChild(n),this.scannerPausedUiElement=n},e.prototype.scanContext=function(t,n){var o=this;return this.stateManagerProxy.isPaused()?Promise.resolve(!1):this.qrcode.decodeAsync(this.canvasElement).then(function(c){return t(c.text,e2.createFromQrcodeResult(c)),o.possiblyUpdateShaders(!0),!0}).catch(function(c){o.possiblyUpdateShaders(!1);var f=cs.codeParseError(c);return n(f,aR.createFrom(f)),!1})},e.prototype.foreverScan=function(t,n,o){var c=this;if(this.shouldScan&&this.renderedCamera){var f=this.renderedCamera.getSurface(),g=f.videoWidth/f.clientWidth,x=f.videoHeight/f.clientHeight;if(!this.qrRegion)throw"qrRegion undefined when localMediaStream is ready.";var w=this.qrRegion.width*g,m=this.qrRegion.height*x,b=this.qrRegion.x*g,E=this.qrRegion.y*x;this.context.drawImage(f,b,E,w,m,0,0,this.qrRegion.width,this.qrRegion.height);var S=function(){c.foreverScanTimeout=setTimeout(function(){c.foreverScan(t,n,o)},c.getTimeoutFps(t.fps))};this.scanContext(n,o).then(function(R){!R&&t.disableFlip!==!0?(c.context.translate(c.context.canvas.width,0),c.context.scale(-1,1),c.scanContext(n,o).finally(function(){S()})):S()}).catch(function(R){c.logger.logError("Error happend while scanning context",R),S()})}},e.prototype.createVideoConstraints=function(t){if(typeof t=="string")return{deviceId:{exact:t}};if(typeof t=="object"){var n="facingMode",o="deviceId",c={user:!0,environment:!0},f="exact",g=function(k){if(k in c)return!0;throw"config has invalid 'facingMode' value = "+"'".concat(k,"'")},x=Object.keys(t);if(x.length!==1)throw"'cameraIdOrConfig' object should have exactly 1 key,"+" if passed as an object, found ".concat(x.length," keys");var w=Object.keys(t)[0];if(w!==n&&w!==o)throw"Only '".concat(n,"' and '").concat(o,"' ")+" are supported for 'cameraIdOrConfig'";if(w===n){var m=t.facingMode;if(typeof m=="string"){if(g(m))return{facingMode:m}}else if(typeof m=="object")if(f in m){if(g(m["".concat(f)]))return{facingMode:{exact:m["".concat(f)]}}}else throw"'facingMode' should be string or object with"+" ".concat(f," as key.");else{var b=typeof m;throw"Invalid type of 'facingMode' = ".concat(b)}}else{var E=t.deviceId;if(typeof E=="string")return{deviceId:E};if(typeof E=="object"){if(f in E)return{deviceId:{exact:E["".concat(f)]}};throw"'deviceId' should be string or object with"+" ".concat(f," as key.")}else{var S=typeof E;throw"Invalid type of 'deviceId' = ".concat(S)}}}var R=typeof t;throw"Invalid type of 'cameraIdOrConfig' = ".concat(R)},e.prototype.computeCanvasDrawConfig=function(t,n,o,c){if(t<=o&&n<=c){var f=(o-t)/2,g=(c-n)/2;return{x:f,y:g,width:t,height:n}}else{var x=t,w=n;return t>o&&(n=o/t*n,t=o),n>c&&(t=c/n*t,n=c),this.logger.log("Image downsampled from "+"".concat(x,"X").concat(w)+" to ".concat(t,"X").concat(n,".")),this.computeCanvasDrawConfig(t,n,o,c)}},e.prototype.clearElement=function(){if(this.stateManagerProxy.isScanning())throw"Cannot clear while scan is ongoing, close it first.";var t=document.getElementById(this.elementId);t&&(t.innerHTML="")},e.prototype.possiblyUpdateShaders=function(t){this.qrMatch!==t&&(this.hasBorderShaders&&this.borderShaders&&this.borderShaders.length&&this.borderShaders.forEach(function(n){n.style.backgroundColor=t?gr.BORDER_SHADER_MATCH_COLOR:gr.BORDER_SHADER_DEFAULT_COLOR}),this.qrMatch=t)},e.prototype.possiblyCloseLastScanImageFile=function(){this.lastScanImageFile&&(URL.revokeObjectURL(this.lastScanImageFile),this.lastScanImageFile=null)},e.prototype.createCanvasElement=function(t,n,o){var c=t,f=n,g=document.createElement("canvas");return g.style.width="".concat(c,"px"),g.style.height="".concat(f,"px"),g.style.display="none",g.id=dn(o)?"qr-canvas":o,g},e.prototype.getShadedRegionBounds=function(t,n,o){if(o.width>t||o.height>n)throw"'config.qrbox' dimensions should not be greater than the dimensions of the root HTML element.";return{x:(t-o.width)/2,y:(n-o.height)/2,width:o.width,height:o.height}},e.prototype.possiblyInsertShadingElement=function(t,n,o,c){if(!(n-c.width<1||o-c.height<1)){var f=document.createElement("div");f.style.position="absolute";var g=(n-c.width)/2,x=(o-c.height)/2;if(f.style.borderLeft="".concat(g,"px solid rgba(0, 0, 0, 0.48)"),f.style.borderRight="".concat(g,"px solid rgba(0, 0, 0, 0.48)"),f.style.borderTop="".concat(x,"px solid rgba(0, 0, 0, 0.48)"),f.style.borderBottom="".concat(x,"px solid rgba(0, 0, 0, 0.48)"),f.style.boxSizing="border-box",f.style.top="0px",f.style.bottom="0px",f.style.left="0px",f.style.right="0px",f.id="".concat(gr.SHADED_REGION_ELEMENT_ID),n-c.width<11||o-c.height<11)this.hasBorderShaders=!1;else{var w=5,m=40;this.insertShaderBorders(f,m,w,-w,null,0,!0),this.insertShaderBorders(f,m,w,-w,null,0,!1),this.insertShaderBorders(f,m,w,null,-w,0,!0),this.insertShaderBorders(f,m,w,null,-w,0,!1),this.insertShaderBorders(f,w,m+w,-w,null,-w,!0),this.insertShaderBorders(f,w,m+w,null,-w,-w,!0),this.insertShaderBorders(f,w,m+w,-w,null,-w,!1),this.insertShaderBorders(f,w,m+w,null,-w,-w,!1),this.hasBorderShaders=!0}t.append(f)}},e.prototype.insertShaderBorders=function(t,n,o,c,f,g,x){var w=document.createElement("div");w.style.position="absolute",w.style.backgroundColor=gr.BORDER_SHADER_DEFAULT_COLOR,w.style.width="".concat(n,"px"),w.style.height="".concat(o,"px"),c!==null&&(w.style.top="".concat(c,"px")),f!==null&&(w.style.bottom="".concat(f,"px")),x?w.style.left="".concat(g,"px"):w.style.right="".concat(g,"px"),this.borderShaders||(this.borderShaders=[]),this.borderShaders.push(w),t.appendChild(w)},e.prototype.showPausedState=function(){if(!this.scannerPausedUiElement)throw"[internal error] scanner paused UI element not found";this.scannerPausedUiElement.style.display="block"},e.prototype.hidePausedState=function(){if(!this.scannerPausedUiElement)throw"[internal error] scanner paused UI element not found";this.scannerPausedUiElement.style.display="none"},e.prototype.getTimeoutFps=function(t){return 1e3/t},e}(),a2;(function(e){e[e.STATUS_DEFAULT=0]="STATUS_DEFAULT",e[e.STATUS_SUCCESS=1]="STATUS_SUCCESS",e[e.STATUS_WARNING=2]="STATUS_WARNING",e[e.STATUS_REQUESTING_PERMISSION=3]="STATUS_REQUESTING_PERMISSION"})(a2||(a2={}));var X1;(function(e){e[e.BACK=1]="BACK",e[e.FRONT=2]="FRONT"})(X1||(X1={}));var Y1;(function(e){e[e.PORTRAIT=1]="PORTRAIT",e[e.LANDSCAPE=2]="LANDSCAPE",e[e.ADAPTIVE=3]="ADAPTIVE"})(Y1||(Y1={}));var K1;(function(e){e[e.ALL=17]="ALL"})(K1||(K1={}));const RR=Object.assign(Object.assign({},ie),K1);var l2;(function(e){e.ZXING="zxing",e.MLKIT="mlkit"})(l2||(l2={}));const _R=[{selector:".scanner-container-display",css:"display: block;"},{selector:".scanner-dialog",css:"display: none; position: fixed; z-index: 999; left: 0; top: 0; width: 100%; height: 100%; overflow: auto; background-color: rgba(0,0,0,0.4);"},{selector:".scanner-dialog-inner",css:"background-color: #fefefe; margin: 2% auto; padding: 20px; border: 1px solid #888; width: 96%;"},{selector:".close-button",css:"color: #aaa; float: right; font-size: 28px; font-weight: bold; cursor: pointer;"},{selector:".close-button:hover",css:"color: #222;"},{selector:".scanner-container-full-width",css:"width: 100%;"}];function OR(e){const t="custom-style-os-cap-barcode";let n=document.getElementById(t);if(n||(n=document.createElement("style"),n.type="text/css",n.id=t,document.head.appendChild(n)),n.sheet){for(;n.sheet.cssRules.length;)n.sheet.deleteRule(0);for(const{selector:o,css:c}of e)n.sheet.insertRule(`${o} { ${c} }`)}else{n.textContent="";for(const{selector:o,css:c}of e)n.textContent+=`${o} { ${c} }`}}const NR=da("CapacitorBarcodeScanner",{web:()=>(OR(_R),mi(()=>import("./web-C3itPQLn.js"),[],import.meta.url).then(e=>new e.CapacitorBarcodeScannerWeb))});class kR{static async scanBarcode(t){return t.scanInstructions=t.scanInstructions||" ",t.scanButton=t.scanButton||!1,t.scanText=t.scanText||" ",t.cameraDirection=t.cameraDirection||X1.BACK,t.scanOrientation=t.scanOrientation||Y1.ADAPTIVE,NR.scanBarcode(t)}}const Of=da("SecureStoragePlugin",{web:()=>mi(()=>import("./web-Co-fisS2.js"),[],import.meta.url).then(e=>new e.SecureStoragePluginWeb)});function DR(e){try{if(e.length>2048)throw new Error;if(!e.startsWith("{")){const c=new URL(e);if(!["http:","https:"].includes(c.protocol)||c.username||c.password||c.pathname!=="/pair"||c.search||!/^#pair=[A-Za-z0-9_-]{43}$/.test(c.hash))throw new Error;const f=cn.parse(c.origin);if(!f)throw new Error;return{endpoint:f,grant:c.hash.slice(6)}}const t=JSON.parse(e);if(t.type!=="agentroam-pair"||t.version!==1||typeof t.server!="string"||typeof t.grant!="string"||!/^[A-Za-z0-9_-]{43}$/.test(t.grant))throw new Error;const n=new URL(t.server);if(n.username||n.password||n.search||n.hash||n.pathname!=="/")throw new Error;const o=cn.parse(t.server);if(!o)throw new Error;return{endpoint:o,grant:t.grant}}catch{throw new Error("这不是 AgentRoam 授权二维码,请扫描电脑终端上新生成的二维码。")}}class jv{ready(){if(!Os.isNativePlatform())throw new Error("请在 AgentRoam App 中扫码连接。")}async get(t){this.ready();try{return(await Of.get({key:`agentroam-device:${t}`})).value}catch(n){if(String(n).includes("does not exist"))return null;throw new Error("无法读取设备凭证,请重试。")}}async set(t,n){this.ready(),await Of.set({key:`agentroam-device:${t}`,value:n})}async remove(t){this.ready();try{await Of.remove({key:`agentroam-device:${t}`})}catch(n){if(!String(n).includes("does not exist"))throw n}}}async function Wv(){if(!Os.isNativePlatform())throw new Error("请在 AgentRoam App 中使用相机扫码。");try{return(await kR.scanBarcode({hint:RR.QR_CODE,scanInstructions:"扫描电脑上的 AgentRoam 授权二维码",cameraDirection:1})).ScanResult||null}catch(e){if(/cancel/i.test(String(e)))return null;throw new Error("无法打开相机,请在系统设置中允许 AgentRoam 使用相机后重试。")}}class zv{constructor(t,n=(...c)=>fetch(...c),o=()=>window.dispatchEvent(new CustomEvent("webapp:unauthorized"))){this.storage=t,this.transport=n,this.onRevoked=o,this.session=null,this.fetch=async(c,f={})=>{const g=this.session,x=new URL(typeof c=="string"?c:c instanceof URL?c.href:c.url),w=new Headers(f.headers??(c instanceof Request?c.headers:void 0));g&&x.origin===g.origin&&w.set("authorization",`Bearer ${g.token}`);const m=await this.transport(c,{...f,headers:w,credentials:"omit",redirect:"error"});if(g&&this.session===g&&x.origin===g.origin&&(m.status===401||m.status===423)){this.session=null;try{await this.storage.remove(g.origin)}finally{this.onRevoked()}}return m}}async resume(t){const n=await this.storage.get(t.url);this.session=n?{origin:t.url,token:n}:null}async pair(t){const{endpoint:n,grant:o}=DR(t),c=await this.transport(n.api("/api/pairing/qr-exchange"),{method:"POST",headers:{"content-type":"application/json"},body:JSON.stringify({grant:o,name:"我的 App"}),credentials:"omit",redirect:"error",signal:AbortSignal.timeout(1e4)});if(!c.ok)throw new Error(c.status===423?"电脑已锁定远程访问,请先在电脑上解锁。":c.status===410?"二维码已使用或已过期,请在电脑上重新生成。":"扫码连接失败,请检查服务器地址和网络后重试。");const f=await c.json();if(typeof f.token!="string"||!/^[A-Za-z0-9_-]{43}$/.test(f.token))throw new Error("服务器返回了无效的设备凭证。");try{await this.storage.set(n.url,f.token)}catch{throw await this.transport(n.api("/api/pairing/logout"),{method:"POST",headers:{authorization:`Bearer ${f.token}`},credentials:"omit",redirect:"error",signal:AbortSignal.timeout(5e3)}).catch(()=>{}),new Error("无法安全保存设备凭证,请在电脑上重新生成二维码后重试。")}return this.session={origin:n.url,token:f.token},n}async checkAuthorization(){const t=this.session;if(!t)return;const n=await this.fetch(`${t.origin}/api/web-auth/status`,{signal:AbortSignal.timeout(5e3)});if(!n.ok)return;const o=await n.json();if(this.session===t&&(o.locked||o.authenticated===!1)){this.session=null;try{await this.storage.remove(t.origin)}finally{this.onRevoked()}}}}function $v(e,t,n,o){const c=new URL(t);return(f,g)=>{const x=typeof f=="string"?f:f instanceof URL?f.href:f.url,w=new URL(x,c),m=w.protocol===c.protocol&&w.host===c.host;if(w.pathname.startsWith("/api/")&&(m||w.origin===e)){const b=new URL(w.pathname+w.search,e);return n.fetch(f instanceof Request?new Request(b,f):b,g)}return o(f,g)}}function MR(e,t){const n=new URL(e,"https://agentroam.local");if(n.pathname!=="/app/")throw new Error("Invalid workspace frame path");const o=new URL(t);return o.search=n.search,o.searchParams.set("workspace","1"),o.hash="",o.href}function Z1(e){XT(YT(e.url,void 0,Mv())),new Sv().save(e)}async function PR(e,t,n,o){e.render(F.jsx(L0,{})),window.__agentroamNativeFrame={origin:t.url,fetch:n.fetch},globalThis.fetch=$v(t.url,location.href,n,o);const c=async g=>{const x=await n.pair(g);Z1(x),location.reload()};zT({origin:t.url,frameUrl:g=>MR(g,location.href),pair:c,scan:async()=>{const g=await Wv();g&&await c(g)},switchComputer:async g=>{const x=cn.parse(g);if(!x)throw new Error("电脑地址无效,请重新扫码。");const w=new zv(new jv,o,()=>{});await w.resume(x);const m=await w.fetch(x.api("/api/web-auth/status"),{signal:AbortSignal.timeout(5e3)}),b=m.ok?await m.json():null;if(!(b!=null&&b.authenticated)||b.locked)throw new Error("这台电脑需要重新授权,请点击扫码添加电脑。");Z1(x),location.reload()}});const{default:f}=await mi(async()=>{const{default:g}=await import("./page-bnT1btVj.js").then(x=>x.p);return{default:g}},__vite__mapDeps([0,1,2,3,4,5,6,7]),import.meta.url);e.render(F.jsx(me.StrictMode,{children:F.jsx(f,{})}))}function BR(){if(window.parent===window||new URLSearchParams(location.search).get("workspace")!=="1")return null;try{const e=new URL(window.parent.location.href);return e.protocol!==location.protocol||e.host!==location.host?null:window.parent.__agentroamNativeFrame??null}catch{return null}}function LR(e){return async(t,n)=>{const o=new Request(t,n);return e.fetch(o.url,{method:o.method,headers:Object.fromEntries(o.headers),body:o.method==="GET"||o.method==="HEAD"?void 0:await o.arrayBuffer(),signal:o.signal,cache:o.cache})}}var dc;(function(e){e.Dark="DARK",e.Light="LIGHT",e.Default="DEFAULT"})(dc||(dc={}));var c2;(function(e){e.None="NONE",e.Slide="SLIDE",e.Fade="FADE"})(c2||(c2={}));const Nf=da("StatusBar");function FR(e){const t=/^#([a-f\d]{6})$/i.exec(e.trim());if(!t)return null;const n=[0,2,4].map(c=>{const f=parseInt(t[1].slice(c,c+2),16)/255;return f<=.04045?f/12.92:((f+.055)/1.055)**2.4}),o=.2126*n[0]+.7152*n[1]+.0722*n[2];return{color:`#${t[1]}`,style:o>.179?dc.Light:dc.Dark}}function UR(){if(Os.getPlatform()!=="android")return()=>{};const e=document.documentElement;e.dataset.skin=Fl.getState().skin;let t=!1,n=Nf.setOverlaysWebView({overlay:!1}).catch(()=>{});const o=()=>{const g=FR(getComputedStyle(e).getPropertyValue("--bg-deepest"));g&&(n=n.then(async()=>{t||(await Nf.setBackgroundColor({color:g.color}),await Nf.setStyle({style:g.style}))}).catch(()=>{console.warn("Unable to update the Android status bar.")}))},c=new MutationObserver(o);c.observe(e,{attributes:!0,attributeFilter:["data-skin"]});const f=()=>{document.hidden||o()};return document.addEventListener("visibilitychange",f),window.addEventListener("focus",o),o(),()=>{t=!0,c.disconnect(),document.removeEventListener("visibilitychange",f),window.removeEventListener("focus",o)}}const jR="/service-worker.js";function WR(){return typeof window<"u"&&window.isSecureContext===!0&&"serviceWorker"in navigator&&"PushManager"in window&&"Notification"in window}function zR(e){const t="=".repeat((4-e.length%4)%4),n=`${e}${t}`.replace(/-/g,"+").replace(/_/g,"/"),o=atob(n),c=new Uint8Array(new ArrayBuffer(o.length));for(let f=0;f<o.length;f+=1)c[f]=o.charCodeAt(f);return c}async function u2(e){const{publicKey:t}=await e.get("/api/push/vapid");if(!t)return;const n=await navigator.serviceWorker.register(jR),c=await n.pushManager.getSubscription()??await n.pushManager.subscribe({userVisibleOnly:!0,applicationServerKey:zR(t)});await e.post("/api/push/subscribe",c.toJSON())}function $R(e){WR()&&(async()=>{try{if(Notification.permission==="granted"){await u2(e);return}if(Notification.permission!=="default")return;const t=()=>{(async()=>{try{await Notification.requestPermission()==="granted"&&await u2(e)}catch{}})()};document.addEventListener("pointerdown",t,{once:!0})}catch{}})()}class kf extends Error{constructor(t,n){super(t),this.name="ParseError",this.type=n.type,this.field=n.field,this.value=n.value,this.line=n.line}}const f2=10,VR=13,di=32;function Df(e){}function HR(e){if(typeof e=="function")throw new TypeError("`config` must be an object, got a function instead. Did you mean `createParser({onEvent: fn})`?");const{onEvent:t=Df,onError:n=Df,onRetry:o=Df,onComment:c,maxBufferSize:f}=e,g=[];let x=0,w=!0,m,b="",E=0,S,R=!1;function k(V){if(R)throw new Error("Cannot feed parser: it was terminated after exceeding the configured max buffer size. Call `reset()` to resume parsing.");if(w&&(w=!1,V.charCodeAt(0)===239&&V.charCodeAt(1)===187&&V.charCodeAt(2)===191&&(V=V.slice(3))),g.length===0){const X=Y(V);X!==""&&(g.push(X),x=X.length),D();return}if(V.indexOf(`
|
|
472
472
|
`)===-1&&V.indexOf("\r")===-1){g.push(V),x+=V.length,D();return}g.push(V);const L=g.join("");g.length=0,x=0;const B=Y(L);B!==""&&(g.push(B),x=B.length),D()}function D(){f!==void 0&&(x+b.length<=f||(R=!0,g.length=0,x=0,m=void 0,b="",E=0,S=void 0,n(new kf(`Buffered data exceeded max buffer size of ${f} characters`,{type:"max-buffer-size-exceeded"}))))}function Y(V){let L=0;if(V.indexOf("\r")===-1){let B=V.indexOf(`
|
|
473
473
|
`,L);for(;B!==-1;){if(L===B){E>0&&t({id:m,event:S,data:b}),m=void 0,b="",E=0,S=void 0,L=B+1,B=V.indexOf(`
|
|
474
474
|
`,L);continue}const X=V.charCodeAt(L);if(d2(V,L,X)){const z=V.charCodeAt(L+5)===di?L+6:L+5,re=V.slice(z,B);if(E===0&&V.charCodeAt(B+1)===f2){t({id:m,event:S,data:re}),m=void 0,b="",S=void 0,L=B+2,B=V.indexOf(`
|
|
@@ -477,4 +477,4 @@ ${re}`,E++}else h2(V,L,X)?S=V.slice(V.charCodeAt(L+6)===di?L+7:L+6,B)||void 0:N(
|
|
|
477
477
|
`,L)}return V.slice(L)}for(;L<V.length;){const B=V.indexOf("\r",L),X=V.indexOf(`
|
|
478
478
|
`,L);let z=-1;if(B!==-1&&X!==-1?z=B<X?B:X:B!==-1?B===V.length-1?z=-1:z=B:X!==-1&&(z=X),z===-1)break;N(V,L,z),L=z+1,V.charCodeAt(L-1)===VR&&V.charCodeAt(L)===f2&&L++}return V.slice(L)}function N(V,L,B){if(L===B){O();return}const X=V.charCodeAt(L);if(d2(V,L,X)){const Se=V.charCodeAt(L+5)===di?L+6:L+5,G=V.slice(Se,B);b=E===0?G:`${b}
|
|
479
479
|
${G}`,E++;return}if(h2(V,L,X)){S=V.slice(V.charCodeAt(L+6)===di?L+7:L+6,B)||void 0;return}if(X===105&&V.charCodeAt(L+1)===100&&V.charCodeAt(L+2)===58){const Se=V.slice(V.charCodeAt(L+3)===di?L+4:L+3,B);Se.includes("\0")||(m=Se);return}if(X===58){if(c){const Se=V.slice(L,B);c(Se.slice(V.charCodeAt(L+1)===di?2:1))}return}const z=V.slice(L,B),re=z.indexOf(":");if(re===-1){I(z,"",z);return}const we=z.slice(0,re),ne=z.charCodeAt(re+1)===di?2:1,de=z.slice(re+ne);I(we,de,z)}function I(V,L,B){switch(V){case"event":S=L||void 0;break;case"data":b=E===0?L:`${b}
|
|
480
|
-
${L}`,E++;break;case"id":L.includes("\0")||(m=L);break;case"retry":/^\d+$/.test(L)?o(parseInt(L,10)):n(new kf(`Invalid \`retry\` value: "${L}"`,{type:"invalid-retry",value:L,line:B}));break;default:n(new kf(`Unknown field "${V.length>20?`${V.slice(0,20)}…`:V}"`,{type:"unknown-field",field:V,value:L,line:B}));break}}function O(){E>0&&t({id:m,event:S,data:b}),m=void 0,b="",E=0,S=void 0}function W(V={}){if(V.consume&&g.length>0){const L=g.join("");N(L,0,L.length)}w=!0,m=void 0,b="",E=0,S=void 0,g.length=0,x=0,R=!1}return{feed:k,reset:W}}function d2(e,t,n){return n===100&&e.charCodeAt(t+1)===97&&e.charCodeAt(t+2)===116&&e.charCodeAt(t+3)===97&&e.charCodeAt(t+4)===58}function h2(e,t,n){return n===101&&e.charCodeAt(t+1)===118&&e.charCodeAt(t+2)===101&&e.charCodeAt(t+3)===110&&e.charCodeAt(t+4)===116&&e.charCodeAt(t+5)===58}class g2 extends Event{constructor(t,n){var o,c;super(t),this.code=(o=n==null?void 0:n.code)!=null?o:void 0,this.message=(c=n==null?void 0:n.message)!=null?c:void 0}[Symbol.for("nodejs.util.inspect.custom")](t,n,o){return o(p2(this),n)}[Symbol.for("Deno.customInspect")](t,n){return t(p2(this),n)}}function GR(e){const t=globalThis.DOMException;return typeof t=="function"?new t(e,"SyntaxError"):new SyntaxError(e)}function Q1(e){return e instanceof Error?"errors"in e&&Array.isArray(e.errors)?e.errors.map(Q1).join(", "):"cause"in e&&e.cause instanceof Error?`${e}: ${Q1(e.cause)}`:e.message:`${e}`}function p2(e){return{type:e.type,message:e.message,code:e.code,defaultPrevented:e.defaultPrevented,cancelable:e.cancelable,timeStamp:e.timeStamp}}var Vv=e=>{throw TypeError(e)},U0=(e,t,n)=>t.has(e)||Vv("Cannot "+n),be=(e,t,n)=>(U0(e,t,"read from private field"),n?n.call(e):t.get(e)),yt=(e,t,n)=>t.has(e)?Vv("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),Ze=(e,t,n,o)=>(U0(e,t,"write to private field"),t.set(e,n),n),hn=(e,t,n)=>(U0(e,t,"access private method"),n),sr,pi,Xi,Rl,hc,_o,us,Oo,Wn,Yi,ws,Ki,mo,Lr,q1,J1,ed,m2,td,rd,xo,nd,id;let _l=class extends EventTarget{constructor(t,n){var o,c;super(),yt(this,Lr),this.CONNECTING=0,this.OPEN=1,this.CLOSED=2,yt(this,sr),yt(this,pi),yt(this,Xi),yt(this,Rl),yt(this,hc),yt(this,_o),yt(this,us),yt(this,Oo,null),yt(this,Wn),yt(this,Yi),yt(this,ws,null),yt(this,Ki,null),yt(this,mo,null),yt(this,J1,async f=>{var g;be(this,Yi).reset();const{body:x,redirected:w,status:m,headers:b}=f;if(m===204){hn(this,Lr,xo).call(this,"Server sent HTTP 204, not reconnecting",204),this.close();return}if(w?Ze(this,Xi,new URL(f.url)):Ze(this,Xi,void 0),m!==200){hn(this,Lr,xo).call(this,`Non-200 status code (${m})`,m);return}if(!(b.get("content-type")||"").startsWith("text/event-stream")){hn(this,Lr,xo).call(this,'Invalid content type, expected "text/event-stream"',m);return}if(be(this,sr)===this.CLOSED)return;Ze(this,sr,this.OPEN);const E=new Event("open");if((g=be(this,mo))==null||g.call(this,E),this.dispatchEvent(E),typeof x!="object"||!x||!("getReader"in x)){hn(this,Lr,xo).call(this,"Invalid response body, expected a web ReadableStream",m),this.close();return}const S=new TextDecoder,R=x.getReader();let k=!0;do{const{done:D,value:Y}=await R.read();Y&&be(this,Yi).feed(S.decode(Y,{stream:!D})),D&&(k=!1,be(this,Yi).reset(),hn(this,Lr,nd).call(this))}while(k)}),yt(this,ed,f=>{Ze(this,Wn,void 0),!(f.name==="AbortError"||f.type==="aborted")&&hn(this,Lr,nd).call(this,Q1(f))}),yt(this,td,f=>{typeof f.id=="string"&&Ze(this,Oo,f.id);const g=new MessageEvent(f.event||"message",{data:f.data,origin:be(this,Xi)?be(this,Xi).origin:be(this,pi).origin,lastEventId:f.id||""});be(this,Ki)&&(!f.event||f.event==="message")&&be(this,Ki).call(this,g),this.dispatchEvent(g)}),yt(this,rd,f=>{Ze(this,_o,f)}),yt(this,id,()=>{Ze(this,us,void 0),be(this,sr)===this.CONNECTING&&hn(this,Lr,q1).call(this)});try{if(t instanceof URL)Ze(this,pi,t);else if(typeof t=="string")Ze(this,pi,new URL(t,XR()));else throw new Error("Invalid URL")}catch{throw GR("An invalid or illegal string was specified")}Ze(this,Yi,HR({onEvent:be(this,td),onRetry:be(this,rd)})),Ze(this,sr,this.CONNECTING),Ze(this,_o,3e3),Ze(this,hc,(o=n==null?void 0:n.fetch)!=null?o:globalThis.fetch),Ze(this,Rl,(c=n==null?void 0:n.withCredentials)!=null?c:!1),hn(this,Lr,q1).call(this)}get readyState(){return be(this,sr)}get url(){return be(this,pi).href}get withCredentials(){return be(this,Rl)}get onerror(){return be(this,ws)}set onerror(t){Ze(this,ws,t)}get onmessage(){return be(this,Ki)}set onmessage(t){Ze(this,Ki,t)}get onopen(){return be(this,mo)}set onopen(t){Ze(this,mo,t)}addEventListener(t,n,o){const c=n;super.addEventListener(t,c,o)}removeEventListener(t,n,o){const c=n;super.removeEventListener(t,c,o)}close(){be(this,us)&&clearTimeout(be(this,us)),be(this,sr)!==this.CLOSED&&(be(this,Wn)&&be(this,Wn).abort(),Ze(this,sr,this.CLOSED),Ze(this,Wn,void 0))}};sr=new WeakMap,pi=new WeakMap,Xi=new WeakMap,Rl=new WeakMap,hc=new WeakMap,_o=new WeakMap,us=new WeakMap,Oo=new WeakMap,Wn=new WeakMap,Yi=new WeakMap,ws=new WeakMap,Ki=new WeakMap,mo=new WeakMap,Lr=new WeakSet,q1=function(){Ze(this,sr,this.CONNECTING),Ze(this,Wn,new AbortController),be(this,hc)(be(this,pi),hn(this,Lr,m2).call(this)).then(be(this,J1)).catch(be(this,ed))},J1=new WeakMap,ed=new WeakMap,m2=function(){var e;const t={mode:"cors",redirect:"follow",headers:{Accept:"text/event-stream",...be(this,Oo)?{"Last-Event-ID":be(this,Oo)}:void 0},cache:"no-store",signal:(e=be(this,Wn))==null?void 0:e.signal};return"window"in globalThis&&(t.credentials=this.withCredentials?"include":"same-origin"),t},td=new WeakMap,rd=new WeakMap,xo=function(e,t){var n;be(this,sr)!==this.CLOSED&&Ze(this,sr,this.CLOSED);const o=new g2("error",{code:t,message:e});(n=be(this,ws))==null||n.call(this,o),this.dispatchEvent(o)},nd=function(e,t){var n;if(be(this,sr)===this.CLOSED)return;Ze(this,sr,this.CONNECTING);const o=new g2("error",{code:t,message:e});(n=be(this,ws))==null||n.call(this,o),this.dispatchEvent(o),Ze(this,us,setTimeout(be(this,id),be(this,_o)))},id=new WeakMap,_l.CONNECTING=0,_l.OPEN=1,_l.CLOSED=2;function XR(){const e="document"in globalThis?globalThis.document:void 0;return e&&typeof e=="object"&&"baseURI"in e&&typeof e.baseURI=="string"?e.baseURI:void 0}mI();S9();_9();k9();P9();d9({baseUrl:()=>ea,source:"webapp"});document.body.dataset.webShell="1";const Zc=new tT,ti=BR(),Hv=Zc.isNativeApp()||!!ti;Hv&&(document.body.dataset.nativeApp="1");UR();if(!Zc.isNativeApp()&&window.parent===window){const e=document.createElement("link");e.rel="manifest",e.href="/manifest.webmanifest",document.head.append(e);const t=document.querySelector('link[rel="apple-touch-icon"]');t&&(t.href="/pwa/icon-192.png");const n=document.createElement("script");n.src="/pwa/install.js",document.head.append(n)}if(window.parent===window){const e=()=>{const t=Fg.find(o=>o.id===Fl.getState().skin)??Fg[0];document.body.style.background=t.preview[0];let n=document.querySelector('meta[name="theme-color"]');n||(n=document.createElement("meta"),n.name="theme-color",document.head.append(n)),n.content=t.preview[0]};e(),Fl.subscribe(e)}const Qc=globalThis.fetch.bind(globalThis),pt=Zc.isNativeApp()&&!ti?new zv(new jv,Qc):null,Jo=ti?LR(ti):pt==null?void 0:pt.fetch;ti&&Jo&&(globalThis.fetch=$v(ti.origin,location.href,{fetch:Jo},Qc));const gc=new l9(Jo),YR=window.parent===window?void 0:new $9,KR=window.parent===window?void 0:new J9;let ea="";async function x2(e){const{wsNonce:t}=await gc.get("/api/web-console/bootstrap"),n=new URL(e,ea||location.href);return n.protocol=n.protocol==="https:"?"wss:":"ws:",n.searchParams.set("nonce",t),new WebSocket(n)}const w2=new w9(gc,new C9,YR,e=>Jo?new _l(ea+e,{fetch:Jo}):new EventSource(ea+e),new y9({openSocket:()=>x2("/ws/voice")}),new E9(()=>x2("/ws/voice/tts")));window.browserLiveApi=KR;const Gv=document.getElementById("root");if(!Gv)throw new Error("#root missing");const No=Cv(Gv);pt&&window.parent===window&&No.render(F.jsx(L0,{}));function ZR(){return me.useEffect(()=>{L9()},[]),null}(async()=>{pt&&window.addEventListener("webapp:unauthorized",()=>location.reload());const e=new eT(Zc,new Sv,new nT(pt?async(n,o)=>{const c=cn.parse(String(n));return c&&await pt.resume(c),pt.fetch(n,o)}:void 0));if(ti){await od(cn.parse(ti.origin));return}const t=await e.planStartup();if(t.mode==="setup"){sd(t.failure);return}await od(t.mode==="ready"?t.endpoint:null)})().catch(e=>{pt&&sd(e instanceof Error?e.message:"连接失败,请重新扫码。")});function sd(e=""){globalThis.fetch=Qc,delete window.__agentroamNativeFrame,No.render(F.jsx(WT,{initialFailure:e,onScan:async()=>{const t=await Wv();if(!t||!pt)return;const n=await pt.pair(t);Z1(n),await od(n)}}))}async function od(e){try{if(e&&(await(pt==null?void 0:pt.resume(e)),gc.setBaseUrl(e.url),ea=e.url),pt&&e&&window.parent===window){await PR(No,e,pt,Qc),setInterval(()=>{pt.checkAuthorization().catch(()=>{})},1e4);return}window.agentApi=w2,await w2.refreshServerModel(),!Hv&&window.parent===window&&$R(gc);const t=new URLSearchParams(location.search).get("view"),{default:n}=t==="collaboration"?await mi(()=>import("./CollaborationPage-BCzxWWHA.js").then(o=>o.a),__vite__mapDeps([8,3,9,10,6,11,2]),import.meta.url):t==="collaboration-dashboard"?await mi(()=>import("./CollaborationDashboard-DhLKl7mR.js").then(o=>o.b),__vite__mapDeps([12,6,13,2,4,9,10,14]),import.meta.url):t==="remote-desktop"?await mi(()=>import("./RemoteDesktopPage-BDK0Mq5I.js"),__vite__mapDeps([15,16,11,5,17,2,7]),import.meta.url):await mi(()=>import("./App-DJXr24vO.js"),__vite__mapDeps([18,5,2,3,1,8,9,10,6,11,16,17,19,4,20,13,12,14,21,22,23,24]),import.meta.url);No.render(F.jsxs(me.StrictMode,{children:[F.jsx(xI.Provider,{value:F.jsx(s9,{}),children:F.jsx(n,{})}),F.jsx(ZR,{})]})),pt&&setInterval(()=>{pt.checkAuthorization().catch(()=>{})},1e4),e||(window.addEventListener("webapp:unauthorized",()=>location.reload()),QR())}catch(t){if(pt&&window.parent===window){sd(t instanceof Error?t.message:"连接失败,请重新扫码。");return}No.render(F.jsx("div",{style:{minHeight:"100dvh",display:"flex",alignItems:"center",justifyContent:"center",padding:24,background:"#f5f6fa",boxSizing:"border-box"},children:F.jsxs("div",{style:{maxWidth:560,background:"#fff",borderRadius:12,padding:20,boxShadow:"0 4px 16px rgba(0,0,0,0.08)"},children:[F.jsx("h2",{style:{margin:"0 0 8px",fontSize:16,color:"#dc2626"},children:"界面启动失败"}),F.jsx("p",{style:{margin:"0 0 12px",fontSize:13,color:"#374151",wordBreak:"break-all"},children:t instanceof Error?`${t.name}: ${t.message}`:String(t)}),F.jsx("button",{type:"button",onClick:()=>location.reload(),style:{padding:"8px 20px",fontSize:14,borderRadius:8,border:"1px solid #d6d9e0",background:"#fff",cursor:"pointer"},children:"重试"})]})}))}}function QR(){const e=[...document.scripts].map(n=>n.src).join(",").match(/index-([^/]+)\.js/),t=e?e[1]:null;t&&setInterval(async()=>{try{const n=await fetch("/api/agent/model",{credentials:"same-origin",cache:"no-store"});if(n.status===401||n.status===423){location.reload();return}const c=((await n.json()).buildId||"").replace(/^index-|\.js$/g,"");c&&c!==t&&location.reload()}catch{}},6e4)}export{V9 as $,BT as A,xI as B,Y1 as C,Tv as D,uT as E,t_ as F,F9 as G,u_ as H,s_ as I,o_ as J,L0 as K,hT as L,pT as M,IT as N,i_ as O,vT as P,G9 as Q,Ov as R,_T as S,H9 as T,yT as U,ST as V,Bv as W,bT as X,TT as Y,e_ as Z,r_ as _,RR as a,mi as a0,W3 as a1,VI as a2,ET as a3,D9 as a4,DT as a5,V1 as a6,FT as a7,qR as a8,Fg as a9,JR as aa,$T as b,Rt as c,fT as d,lT as e,B0 as f,xT as g,mn as h,QI as i,F as j,v2 as k,mT as l,a_ as m,Dv as n,Mv as o,YT as p,n_ as q,me as r,XT as s,KT as t,Fl as u,l_ as v,GT as w,dT as x,c_ as y,wT as z};
|
|
480
|
+
${L}`,E++;break;case"id":L.includes("\0")||(m=L);break;case"retry":/^\d+$/.test(L)?o(parseInt(L,10)):n(new kf(`Invalid \`retry\` value: "${L}"`,{type:"invalid-retry",value:L,line:B}));break;default:n(new kf(`Unknown field "${V.length>20?`${V.slice(0,20)}…`:V}"`,{type:"unknown-field",field:V,value:L,line:B}));break}}function O(){E>0&&t({id:m,event:S,data:b}),m=void 0,b="",E=0,S=void 0}function W(V={}){if(V.consume&&g.length>0){const L=g.join("");N(L,0,L.length)}w=!0,m=void 0,b="",E=0,S=void 0,g.length=0,x=0,R=!1}return{feed:k,reset:W}}function d2(e,t,n){return n===100&&e.charCodeAt(t+1)===97&&e.charCodeAt(t+2)===116&&e.charCodeAt(t+3)===97&&e.charCodeAt(t+4)===58}function h2(e,t,n){return n===101&&e.charCodeAt(t+1)===118&&e.charCodeAt(t+2)===101&&e.charCodeAt(t+3)===110&&e.charCodeAt(t+4)===116&&e.charCodeAt(t+5)===58}class g2 extends Event{constructor(t,n){var o,c;super(t),this.code=(o=n==null?void 0:n.code)!=null?o:void 0,this.message=(c=n==null?void 0:n.message)!=null?c:void 0}[Symbol.for("nodejs.util.inspect.custom")](t,n,o){return o(p2(this),n)}[Symbol.for("Deno.customInspect")](t,n){return t(p2(this),n)}}function GR(e){const t=globalThis.DOMException;return typeof t=="function"?new t(e,"SyntaxError"):new SyntaxError(e)}function Q1(e){return e instanceof Error?"errors"in e&&Array.isArray(e.errors)?e.errors.map(Q1).join(", "):"cause"in e&&e.cause instanceof Error?`${e}: ${Q1(e.cause)}`:e.message:`${e}`}function p2(e){return{type:e.type,message:e.message,code:e.code,defaultPrevented:e.defaultPrevented,cancelable:e.cancelable,timeStamp:e.timeStamp}}var Vv=e=>{throw TypeError(e)},U0=(e,t,n)=>t.has(e)||Vv("Cannot "+n),be=(e,t,n)=>(U0(e,t,"read from private field"),n?n.call(e):t.get(e)),yt=(e,t,n)=>t.has(e)?Vv("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),Ze=(e,t,n,o)=>(U0(e,t,"write to private field"),t.set(e,n),n),hn=(e,t,n)=>(U0(e,t,"access private method"),n),sr,pi,Xi,Rl,hc,_o,us,Oo,Wn,Yi,ws,Ki,mo,Lr,q1,J1,ed,m2,td,rd,xo,nd,id;let _l=class extends EventTarget{constructor(t,n){var o,c;super(),yt(this,Lr),this.CONNECTING=0,this.OPEN=1,this.CLOSED=2,yt(this,sr),yt(this,pi),yt(this,Xi),yt(this,Rl),yt(this,hc),yt(this,_o),yt(this,us),yt(this,Oo,null),yt(this,Wn),yt(this,Yi),yt(this,ws,null),yt(this,Ki,null),yt(this,mo,null),yt(this,J1,async f=>{var g;be(this,Yi).reset();const{body:x,redirected:w,status:m,headers:b}=f;if(m===204){hn(this,Lr,xo).call(this,"Server sent HTTP 204, not reconnecting",204),this.close();return}if(w?Ze(this,Xi,new URL(f.url)):Ze(this,Xi,void 0),m!==200){hn(this,Lr,xo).call(this,`Non-200 status code (${m})`,m);return}if(!(b.get("content-type")||"").startsWith("text/event-stream")){hn(this,Lr,xo).call(this,'Invalid content type, expected "text/event-stream"',m);return}if(be(this,sr)===this.CLOSED)return;Ze(this,sr,this.OPEN);const E=new Event("open");if((g=be(this,mo))==null||g.call(this,E),this.dispatchEvent(E),typeof x!="object"||!x||!("getReader"in x)){hn(this,Lr,xo).call(this,"Invalid response body, expected a web ReadableStream",m),this.close();return}const S=new TextDecoder,R=x.getReader();let k=!0;do{const{done:D,value:Y}=await R.read();Y&&be(this,Yi).feed(S.decode(Y,{stream:!D})),D&&(k=!1,be(this,Yi).reset(),hn(this,Lr,nd).call(this))}while(k)}),yt(this,ed,f=>{Ze(this,Wn,void 0),!(f.name==="AbortError"||f.type==="aborted")&&hn(this,Lr,nd).call(this,Q1(f))}),yt(this,td,f=>{typeof f.id=="string"&&Ze(this,Oo,f.id);const g=new MessageEvent(f.event||"message",{data:f.data,origin:be(this,Xi)?be(this,Xi).origin:be(this,pi).origin,lastEventId:f.id||""});be(this,Ki)&&(!f.event||f.event==="message")&&be(this,Ki).call(this,g),this.dispatchEvent(g)}),yt(this,rd,f=>{Ze(this,_o,f)}),yt(this,id,()=>{Ze(this,us,void 0),be(this,sr)===this.CONNECTING&&hn(this,Lr,q1).call(this)});try{if(t instanceof URL)Ze(this,pi,t);else if(typeof t=="string")Ze(this,pi,new URL(t,XR()));else throw new Error("Invalid URL")}catch{throw GR("An invalid or illegal string was specified")}Ze(this,Yi,HR({onEvent:be(this,td),onRetry:be(this,rd)})),Ze(this,sr,this.CONNECTING),Ze(this,_o,3e3),Ze(this,hc,(o=n==null?void 0:n.fetch)!=null?o:globalThis.fetch),Ze(this,Rl,(c=n==null?void 0:n.withCredentials)!=null?c:!1),hn(this,Lr,q1).call(this)}get readyState(){return be(this,sr)}get url(){return be(this,pi).href}get withCredentials(){return be(this,Rl)}get onerror(){return be(this,ws)}set onerror(t){Ze(this,ws,t)}get onmessage(){return be(this,Ki)}set onmessage(t){Ze(this,Ki,t)}get onopen(){return be(this,mo)}set onopen(t){Ze(this,mo,t)}addEventListener(t,n,o){const c=n;super.addEventListener(t,c,o)}removeEventListener(t,n,o){const c=n;super.removeEventListener(t,c,o)}close(){be(this,us)&&clearTimeout(be(this,us)),be(this,sr)!==this.CLOSED&&(be(this,Wn)&&be(this,Wn).abort(),Ze(this,sr,this.CLOSED),Ze(this,Wn,void 0))}};sr=new WeakMap,pi=new WeakMap,Xi=new WeakMap,Rl=new WeakMap,hc=new WeakMap,_o=new WeakMap,us=new WeakMap,Oo=new WeakMap,Wn=new WeakMap,Yi=new WeakMap,ws=new WeakMap,Ki=new WeakMap,mo=new WeakMap,Lr=new WeakSet,q1=function(){Ze(this,sr,this.CONNECTING),Ze(this,Wn,new AbortController),be(this,hc)(be(this,pi),hn(this,Lr,m2).call(this)).then(be(this,J1)).catch(be(this,ed))},J1=new WeakMap,ed=new WeakMap,m2=function(){var e;const t={mode:"cors",redirect:"follow",headers:{Accept:"text/event-stream",...be(this,Oo)?{"Last-Event-ID":be(this,Oo)}:void 0},cache:"no-store",signal:(e=be(this,Wn))==null?void 0:e.signal};return"window"in globalThis&&(t.credentials=this.withCredentials?"include":"same-origin"),t},td=new WeakMap,rd=new WeakMap,xo=function(e,t){var n;be(this,sr)!==this.CLOSED&&Ze(this,sr,this.CLOSED);const o=new g2("error",{code:t,message:e});(n=be(this,ws))==null||n.call(this,o),this.dispatchEvent(o)},nd=function(e,t){var n;if(be(this,sr)===this.CLOSED)return;Ze(this,sr,this.CONNECTING);const o=new g2("error",{code:t,message:e});(n=be(this,ws))==null||n.call(this,o),this.dispatchEvent(o),Ze(this,us,setTimeout(be(this,id),be(this,_o)))},id=new WeakMap,_l.CONNECTING=0,_l.OPEN=1,_l.CLOSED=2;function XR(){const e="document"in globalThis?globalThis.document:void 0;return e&&typeof e=="object"&&"baseURI"in e&&typeof e.baseURI=="string"?e.baseURI:void 0}mI();S9();_9();k9();P9();d9({baseUrl:()=>ea,source:"webapp"});document.body.dataset.webShell="1";const Zc=new tT,ti=BR(),Hv=Zc.isNativeApp()||!!ti;Hv&&(document.body.dataset.nativeApp="1");UR();if(!Zc.isNativeApp()&&window.parent===window){const e=document.createElement("link");e.rel="manifest",e.href="/manifest.webmanifest",document.head.append(e);const t=document.querySelector('link[rel="apple-touch-icon"]');t&&(t.href="/pwa/icon-192.png");const n=document.createElement("script");n.src="/pwa/install.js",document.head.append(n)}if(window.parent===window){const e=()=>{const t=Fg.find(o=>o.id===Fl.getState().skin)??Fg[0];document.body.style.background=t.preview[0];let n=document.querySelector('meta[name="theme-color"]');n||(n=document.createElement("meta"),n.name="theme-color",document.head.append(n)),n.content=t.preview[0]};e(),Fl.subscribe(e)}const Qc=globalThis.fetch.bind(globalThis),pt=Zc.isNativeApp()&&!ti?new zv(new jv,Qc):null,Jo=ti?LR(ti):pt==null?void 0:pt.fetch;ti&&Jo&&(globalThis.fetch=$v(ti.origin,location.href,{fetch:Jo},Qc));const gc=new l9(Jo),YR=window.parent===window?void 0:new $9,KR=window.parent===window?void 0:new J9;let ea="";async function x2(e){const{wsNonce:t}=await gc.get("/api/web-console/bootstrap"),n=new URL(e,ea||location.href);return n.protocol=n.protocol==="https:"?"wss:":"ws:",n.searchParams.set("nonce",t),new WebSocket(n)}const w2=new w9(gc,new C9,YR,e=>Jo?new _l(ea+e,{fetch:Jo}):new EventSource(ea+e),new y9({openSocket:()=>x2("/ws/voice")}),new E9(()=>x2("/ws/voice/tts")));window.browserLiveApi=KR;const Gv=document.getElementById("root");if(!Gv)throw new Error("#root missing");const No=Cv(Gv);pt&&window.parent===window&&No.render(F.jsx(L0,{}));function ZR(){return me.useEffect(()=>{L9()},[]),null}(async()=>{pt&&window.addEventListener("webapp:unauthorized",()=>location.reload());const e=new eT(Zc,new Sv,new nT(pt?async(n,o)=>{const c=cn.parse(String(n));return c&&await pt.resume(c),pt.fetch(n,o)}:void 0));if(ti){await od(cn.parse(ti.origin));return}const t=await e.planStartup();if(t.mode==="setup"){sd(t.failure);return}await od(t.mode==="ready"?t.endpoint:null)})().catch(e=>{pt&&sd(e instanceof Error?e.message:"连接失败,请重新扫码。")});function sd(e=""){globalThis.fetch=Qc,delete window.__agentroamNativeFrame,No.render(F.jsx(WT,{initialFailure:e,onScan:async()=>{const t=await Wv();if(!t||!pt)return;const n=await pt.pair(t);Z1(n),await od(n)}}))}async function od(e){try{if(e&&(await(pt==null?void 0:pt.resume(e)),gc.setBaseUrl(e.url),ea=e.url),pt&&e&&window.parent===window){await PR(No,e,pt,Qc),setInterval(()=>{pt.checkAuthorization().catch(()=>{})},1e4);return}window.agentApi=w2,await w2.refreshServerModel(),!Hv&&window.parent===window&&$R(gc);const t=new URLSearchParams(location.search).get("view"),{default:n}=t==="collaboration"?await mi(()=>import("./CollaborationPage-C8PN5oNe.js").then(o=>o.a),__vite__mapDeps([8,3,9,10,6,11,2]),import.meta.url):t==="collaboration-dashboard"?await mi(()=>import("./CollaborationDashboard-CEF41i5J.js").then(o=>o.b),__vite__mapDeps([12,6,13,2,4,9,10,14]),import.meta.url):t==="remote-desktop"?await mi(()=>import("./RemoteDesktopPage-DBoSlmlh.js"),__vite__mapDeps([15,16,11,5,17,2,7]),import.meta.url):await mi(()=>import("./App-Y_UUrP8i.js"),__vite__mapDeps([18,5,2,3,1,8,9,10,6,11,16,17,19,4,20,13,12,14,21,22,23,24]),import.meta.url);No.render(F.jsxs(me.StrictMode,{children:[F.jsx(xI.Provider,{value:F.jsx(s9,{}),children:F.jsx(n,{})}),F.jsx(ZR,{})]})),pt&&setInterval(()=>{pt.checkAuthorization().catch(()=>{})},1e4),e||(window.addEventListener("webapp:unauthorized",()=>location.reload()),QR())}catch(t){if(pt&&window.parent===window){sd(t instanceof Error?t.message:"连接失败,请重新扫码。");return}No.render(F.jsx("div",{style:{minHeight:"100dvh",display:"flex",alignItems:"center",justifyContent:"center",padding:24,background:"#f5f6fa",boxSizing:"border-box"},children:F.jsxs("div",{style:{maxWidth:560,background:"#fff",borderRadius:12,padding:20,boxShadow:"0 4px 16px rgba(0,0,0,0.08)"},children:[F.jsx("h2",{style:{margin:"0 0 8px",fontSize:16,color:"#dc2626"},children:"界面启动失败"}),F.jsx("p",{style:{margin:"0 0 12px",fontSize:13,color:"#374151",wordBreak:"break-all"},children:t instanceof Error?`${t.name}: ${t.message}`:String(t)}),F.jsx("button",{type:"button",onClick:()=>location.reload(),style:{padding:"8px 20px",fontSize:14,borderRadius:8,border:"1px solid #d6d9e0",background:"#fff",cursor:"pointer"},children:"重试"})]})}))}}function QR(){const e=[...document.scripts].map(n=>n.src).join(",").match(/index-([^/]+)\.js/),t=e?e[1]:null;t&&setInterval(async()=>{try{const n=await fetch("/api/agent/model",{credentials:"same-origin",cache:"no-store"});if(n.status===401||n.status===423){location.reload();return}const c=((await n.json()).buildId||"").replace(/^index-|\.js$/g,"");c&&c!==t&&location.reload()}catch{}},6e4)}export{V9 as $,BT as A,xI as B,Y1 as C,Tv as D,uT as E,t_ as F,F9 as G,u_ as H,s_ as I,o_ as J,L0 as K,hT as L,pT as M,IT as N,i_ as O,vT as P,G9 as Q,Ov as R,_T as S,H9 as T,yT as U,ST as V,Bv as W,bT as X,TT as Y,e_ as Z,r_ as _,RR as a,mi as a0,W3 as a1,VI as a2,ET as a3,D9 as a4,DT as a5,V1 as a6,FT as a7,qR as a8,Fg as a9,JR as aa,$T as b,Rt as c,fT as d,lT as e,B0 as f,xT as g,mn as h,QI as i,F as j,v2 as k,mT as l,a_ as m,Dv as n,Mv as o,YT as p,n_ as q,me as r,XT as s,KT as t,Fl as u,l_ as v,GT as w,dT as x,c_ as y,wT as z};
|